/* ELVORA COLLECTION — Editorial Runway (shop — staggered lookbook, no sidebar grid) */

.page-shop .page-main {
  background: var(--surface-0);
  overflow-x: clip;
}

.esh-root {
  --esh-fluid-h1: clamp(2.2rem, 4.5vw + 0.5rem, 3.6rem);
  --esh-inset: clamp(1rem, 3vw, 2rem);
}

/* ══════════════════════════════════════
   MASTHEAD — split-screen editorial
   ══════════════════════════════════════ */
.esh-masthead {
  position: relative;
  padding: clamp(36px, 6vw, 64px) var(--esh-inset) clamp(28px, 4vw, 40px);
  overflow: hidden;
}

.esh-masthead-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.esh-masthead-sweep {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(118deg, var(--surface-1) 0%, var(--surface-1) 42%, transparent 42.5%),
    radial-gradient(ellipse 70% 50% at 95% 15%, rgba(212, 162, 76, 0.16), transparent 55%),
    radial-gradient(ellipse 50% 40% at 8% 90%, rgba(74, 28, 50, 0.08), transparent 50%);
}

.esh-masthead-grain {
  position: absolute;
  inset: 0;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.esh-masthead-split {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.95fr);
  gap: clamp(24px, 4vw, 48px);
  align-items: stretch;
  max-width: 1280px;
  margin: 0 auto;
}

.esh-crumb {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.esh-crumb a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.2s;
}

.esh-crumb a:hover { color: var(--vault); }
.esh-crumb [aria-current] { color: var(--vault-deep); font-weight: 700; }

.esh-kicker {
  margin: 0 0 10px;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ochre-deep);
}

.esh-masthead h1 {
  margin: 0 0 12px;
  font-family: var(--serif);
  font-size: var(--esh-fluid-h1);
  font-weight: 600;
  line-height: 1.02;
  letter-spacing: -0.03em;
  color: var(--vault-deep);
}

.esh-accent {
  background: linear-gradient(115deg, var(--vault) 0%, var(--ochre-deep) 55%, var(--moss) 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: eshAccentFlow 9s ease-in-out infinite alternate;
}

@keyframes eshAccentFlow {
  from { background-position: 0% center; }
  to { background-position: 100% center; }
}

.esh-lede,
.esh-query {
  margin: 0 0 20px;
  max-width: 40ch;
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--text-secondary);
}

.esh-query {
  font-style: italic;
  color: var(--vault);
}

.esh-tally {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 24px;
  padding: 0;
  list-style: none;
}

.esh-tally li {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 16px;
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.65);
  border: 1px solid var(--line-soft);
  backdrop-filter: blur(8px);
}

.esh-tally strong {
  font-family: var(--serif);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--vault-deep);
  line-height: 1;
}

.esh-tally span {
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.esh-search-track {
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 420px;
  padding: 6px 6px 6px 16px;
  border-radius: var(--radius-full);
  background: var(--surface-2);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  transition: border-color 0.3s, box-shadow 0.3s, transform 0.3s;
}

.esh-search-track:focus-within {
  border-color: var(--ochre);
  box-shadow: 0 0 0 4px rgba(212, 162, 76, 0.14);
  transform: translateY(-2px);
}

.esh-search-glyph {
  flex-shrink: 0;
  font-size: 1.1rem;
  color: var(--text-muted);
}

.esh-search-track input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  font-size: 0.92rem;
  color: var(--ink);
}

.esh-search-track button {
  flex-shrink: 0;
  padding: 10px 18px;
  border: 0;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg, var(--vault), var(--vault-deep));
  color: var(--on-dark);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.esh-search-track button:hover {
  transform: scale(1.04);
  box-shadow: 0 6px 18px rgba(74, 28, 50, 0.28);
}

/* Cover story panel */
.esh-cover {
  position: relative;
  display: block;
  min-height: clamp(320px, 42vw, 480px);
  border-radius: var(--radius-2xl);
  overflow: hidden;
  text-decoration: none;
  box-shadow: var(--shadow-xl);
  transform: rotate(1.2deg);
  transition: transform 0.45s var(--ease-out), box-shadow 0.45s;
}

.esh-cover:hover {
  transform: rotate(0deg) scale(1.01);
  box-shadow: 0 24px 56px rgba(46, 15, 31, 0.18);
}

.esh-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease-out);
}

.esh-cover:hover img { transform: scale(1.06); }

.esh-cover-tag {
  position: absolute;
  top: 18px;
  left: 18px;
  z-index: 2;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: var(--ochre);
  color: var(--vault-deep);
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.esh-cover-overlay {
  position: absolute;
  inset: auto 0 0 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: clamp(20px, 4vw, 32px);
  background: linear-gradient(180deg, transparent, rgba(18, 8, 24, 0.92));
  color: var(--on-dark);
}

.esh-cover-overlay em {
  font-style: normal;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--on-dark-muted);
}

.esh-cover-overlay strong {
  font-family: var(--serif);
  font-size: clamp(1.35rem, 2.5vw, 1.85rem);
  font-weight: 600;
  line-height: 1.1;
}

.esh-cover-meta {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-top: 4px;
}

.esh-cover-meta b {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--ochre);
}

.esh-cover-meta i {
  font-style: normal;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--on-dark-subtle);
}

.esh-cover-placeholder {
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, var(--vault-deep), var(--vault));
  transform: none;
  cursor: default;
}

.esh-cover-placeholder p {
  margin: 12px 0 0;
  font-family: var(--serif);
  font-size: 1.25rem;
  color: var(--on-dark-muted);
  text-align: center;
  padding: 0 24px;
}

/* ══════════════════════════════════════
   RUNWAY — horizontal aisle strip
   ══════════════════════════════════════ */
.esh-runway {
  position: sticky;
  top: calc(var(--loom-seal, 72px) + 8px);
  z-index: 15;
  padding: 0 var(--esh-inset) 20px;
  margin-top: -8px;
}

.esh-runway-inner {
  display: flex;
  align-items: center;
  gap: 14px;
  max-width: 1280px;
  margin: 0 auto;
  padding: 10px 14px;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid var(--line-soft);
  box-shadow: var(--shadow-md);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.esh-runway-label {
  flex-shrink: 0;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding-left: 6px;
}

.esh-runway-track {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
  scroll-snap-type: x proximity;
  padding: 2px 0;
}

.esh-runway-track::-webkit-scrollbar { display: none; }

.esh-runway-pill {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--radius-full);
  background: var(--surface-1);
  border: 1px solid var(--line-soft);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-secondary);
  text-decoration: none;
  scroll-snap-align: start;
  transition: transform 0.25s, border-color 0.25s, background 0.25s, box-shadow 0.25s, color 0.25s;
}

.esh-runway-pill span:first-child {
  font-size: 0.9rem;
  line-height: 1;
}

.esh-runway-pill:hover {
  transform: translateY(-3px);
  border-color: var(--ochre);
  color: var(--vault);
  box-shadow: var(--shadow-sm);
}

.esh-runway-pill.is-active {
  background: var(--vault);
  border-color: var(--vault);
  color: var(--on-dark);
  box-shadow: 0 6px 20px rgba(74, 28, 50, 0.25);
}

.esh-runway-pill.tone-moss.is-active { background: #2d5016; border-color: #2d5016; }
.esh-runway-pill.tone-rose.is-active { background: #9f1239; border-color: #9f1239; }
.esh-runway-pill.tone-field.is-active { background: #854d0e; border-color: #854d0e; }
.esh-runway-pill.tone-sun.is-active { background: #c2410c; border-color: #c2410c; }
.esh-runway-pill.tone-herb.is-active { background: #166534; border-color: #166534; }
.esh-runway-pill.tone-spice.is-active { background: #7c2d12; border-color: #7c2d12; }
.esh-runway-pill.tone-slate.is-active { background: #475569; border-color: #475569; }

/* ══════════════════════════════════════
   FLOOR — staggered lookbook grid
   ══════════════════════════════════════ */
.esh-floor {
  padding: 0 var(--esh-inset) clamp(64px, 9vw, 96px);
  max-width: 1280px;
  margin: 0 auto;
}

.esh-floor-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: clamp(24px, 4vw, 36px);
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line-soft);
}

.esh-floor-tags {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.esh-floor-pill {
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: rgba(74, 28, 50, 0.08);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--vault);
}

.esh-floor-clear {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.2s;
}

.esh-floor-clear:hover { color: var(--vault); }

.esh-floor-count {
  margin: 0;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
}

/* Lookbook asymmetric grid */
.esh-lookbook {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  grid-auto-rows: minmax(180px, auto);
  gap: clamp(14px, 2vw, 20px);
}

.esh-piece {
  position: relative;
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-xl);
  background: var(--surface-2);
  border: 1px solid var(--line-soft);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.4s var(--ease-out), box-shadow 0.4s;
  animation: eshPieceIn 0.55s var(--ease-out) both;
  animation-delay: calc(var(--piece-i) * 55ms);
}

@keyframes eshPieceIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.esh-piece.is-visible {
  animation: eshPieceIn 0.55s var(--ease-out) both;
}

.esh-piece.layout-wide { grid-column: span 8; grid-row: span 2; }
.esh-piece.layout-tall { grid-column: span 4; grid-row: span 2; }
.esh-piece.layout-compact { grid-column: span 4; }
.esh-piece.layout-panorama {
  grid-column: span 12;
  flex-direction: row;
  min-height: 200px;
}

.esh-piece::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--piece-tone, var(--vault));
  z-index: 2;
  opacity: 0;
  transition: opacity 0.3s;
}

.esh-piece.tone-moss { --piece-tone: #2d5016; }
.esh-piece.tone-rose { --piece-tone: #9f1239; }
.esh-piece.tone-field { --piece-tone: #854d0e; }
.esh-piece.tone-sun { --piece-tone: #c2410c; }
.esh-piece.tone-herb { --piece-tone: #166534; }
.esh-piece.tone-spice { --piece-tone: #7c2d12; }
.esh-piece.tone-slate { --piece-tone: #475569; }
.esh-piece.tone-vault { --piece-tone: var(--vault); }

.esh-piece:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.esh-piece:hover::before { opacity: 1; }

.esh-piece-media {
  position: relative;
  display: block;
  overflow: hidden;
  flex-shrink: 0;
}

.esh-piece:not(.layout-panorama) .esh-piece-media {
  aspect-ratio: 1;
}

.esh-piece.layout-wide .esh-piece-media { aspect-ratio: 4 / 3; }
.esh-piece.layout-tall .esh-piece-media { aspect-ratio: 3 / 4; min-height: 100%; flex: 1; }

.esh-piece.layout-panorama .esh-piece-media {
  flex: 0 0 min(42%, 320px);
  min-height: 200px;
}

.esh-piece-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.55s var(--ease-out), filter 0.4s;
}

.esh-piece:hover .esh-piece-media img {
  transform: scale(1.07);
  filter: saturate(1.08);
}

.esh-piece-shimmer {
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 40%, rgba(255, 255, 255, 0.35) 50%, transparent 60%);
  transform: translateX(-100%);
  transition: transform 0s;
  pointer-events: none;
}

.esh-piece:hover .esh-piece-shimmer {
  transform: translateX(100%);
  transition: transform 0.75s var(--ease-out);
}

.esh-piece-frame {
  position: absolute;
  inset: 12px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: calc(var(--radius-xl) - 8px);
  opacity: 0;
  transition: opacity 0.35s, inset 0.35s;
  pointer-events: none;
}

.esh-piece:hover .esh-piece-frame {
  opacity: 1;
  inset: 16px;
}

.esh-piece-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  background: var(--ochre);
  color: var(--vault-deep);
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.esh-piece-body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 16px 18px 18px;
  flex: 1;
}

.esh-piece.layout-panorama .esh-piece-body {
  justify-content: center;
  padding: 24px 28px;
}

.esh-piece-aisle {
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ochre-deep);
}

.esh-piece-body h3 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(1rem, 1.4vw, 1.15rem);
  font-weight: 600;
  line-height: 1.15;
}

.esh-piece.layout-wide .esh-piece-body h3,
.esh-piece.layout-panorama .esh-piece-body h3 {
  font-size: clamp(1.15rem, 1.8vw, 1.45rem);
}

.esh-piece-body h3 a {
  color: var(--vault-deep);
  text-decoration: none;
  transition: color 0.2s;
}

.esh-piece-body h3 a:hover { color: var(--vault); }

.esh-piece-tease {
  margin: 4px 0 0;
  font-size: 0.82rem;
  line-height: 1.55;
  color: var(--text-secondary);
  max-width: 48ch;
}

.esh-piece-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: auto;
  padding-top: 8px;
}

.esh-piece-price {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--vault);
  transition: transform 0.3s var(--ease-out);
}

.esh-piece:hover .esh-piece-price {
  transform: translateX(4px);
}

.esh-piece-sku {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  opacity: 0.7;
  transition: opacity 0.3s, color 0.3s;
}

.esh-piece:hover .esh-piece-sku {
  opacity: 1;
  color: var(--text-secondary);
}

.esh-piece-go {
  margin-left: auto;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ochre-deep);
  opacity: 0;
  transform: translateX(-8px);
  transition: opacity 0.3s, transform 0.3s;
}

.esh-piece:hover .esh-piece-go {
  opacity: 1;
  transform: translateX(0);
}

/* Empty + pagination */
.esh-empty {
  text-align: center;
  padding: clamp(48px, 8vw, 80px) 24px;
  border-radius: var(--radius-2xl);
  background: var(--surface-2);
  border: 2px dashed var(--line);
}

.esh-empty-orbit {
  width: 72px;
  height: 72px;
  margin: 0 auto 20px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 2px dashed var(--ochre);
  font-size: 1.5rem;
  color: var(--vault);
  animation: eshOrbitSpin 12s linear infinite;
}

@keyframes eshOrbitSpin {
  to { transform: rotate(360deg); }
}

.esh-empty h2 {
  margin: 0 0 8px;
  font-family: var(--serif);
  font-size: 1.75rem;
  color: var(--vault-deep);
}

.esh-empty p {
  margin: 0 0 24px;
  color: var(--text-secondary);
}

.esh-btn {
  display: inline-flex;
  padding: 14px 26px;
  border-radius: var(--radius-full);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  transition: transform 0.25s, box-shadow 0.25s;
}

.esh-btn-solid {
  background: linear-gradient(135deg, var(--vault), var(--vault-deep));
  color: var(--on-dark);
  box-shadow: 0 8px 24px rgba(74, 28, 50, 0.25);
}

.esh-btn-solid:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(74, 28, 50, 0.32);
}

.esh-pagination {
  margin-top: clamp(36px, 5vw, 52px);
}

.esh-pagination .catalog-pagination {
  justify-content: center;
}

.esh-pagination .pagination-inner {
  background: var(--surface-2);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-full);
  padding: 8px 12px;
  box-shadow: var(--shadow-sm);
}

/* ══════════════════════════════════════
   RESPONSIVE
   ══════════════════════════════════════ */
@media (max-width: 960px) {
  .esh-masthead-split {
    grid-template-columns: 1fr;
  }

  .esh-cover {
    transform: none;
    min-height: 280px;
  }

  .esh-cover:hover { transform: scale(1.01); }

  .esh-runway-inner {
    flex-direction: column;
    align-items: stretch;
    border-radius: var(--radius-xl);
  }

  .esh-runway-label { padding: 4px 4px 0; }

  .esh-piece.layout-wide,
  .esh-piece.layout-tall,
  .esh-piece.layout-compact,
  .esh-piece.layout-panorama {
    grid-column: span 6;
    grid-row: span 1;
    flex-direction: column;
  }

  .esh-piece.layout-panorama .esh-piece-media {
    flex: none;
    width: 100%;
    aspect-ratio: 16 / 10;
  }
}

@media (max-width: 640px) {
  .esh-piece.layout-wide,
  .esh-piece.layout-tall,
  .esh-piece.layout-compact,
  .esh-piece.layout-panorama {
    grid-column: span 12;
  }

  .esh-piece-go {
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .esh-accent,
  .esh-empty-orbit,
  .esh-piece {
    animation: none !important;
  }

  .esh-piece:hover,
  .esh-cover:hover,
  .esh-runway-pill:hover {
    transform: none;
  }

  .esh-piece-shimmer { display: none; }
}

@media (hover: hover) {
  .esh-piece {
    transform-style: preserve-3d;
  }

  .esh-piece:hover {
    transform: translateY(-8px) perspective(800px) rotateX(var(--tilt-x, 1deg)) rotateY(var(--tilt-y, 0deg));
  }
}
