/* =============================================
   Shoppers Junction — Refined Premiere Theme
   ============================================= */

:root {
  --bg: #f3ece2;
  --bg-elevated: #faf6ef;
  --surface: #fffcf7;
  --text: #2d2924;
  --text-muted: #6f675c;
  --gold: #b38b3f;
  --gold-light: #d4af5a;
  --gold-deep: #8f6d2c;
  --gold-soft: rgba(179, 139, 63, 0.12);
  --gold-glow: rgba(212, 175, 90, 0.35);
  --champagne: #e6dcc8;
  --silver-muted: #a8a196;
  --line: rgba(45, 41, 36, 0.09);
  --line-strong: rgba(45, 41, 36, 0.15);
  --shadow-sm: 0 1px 2px rgba(45, 41, 36, 0.05), 0 4px 16px rgba(45, 41, 36, 0.07);
  --shadow-md: 0 8px 32px rgba(45, 41, 36, 0.09);
  --shadow-gold: 0 6px 24px rgba(179, 139, 63, 0.3);
  --header-bg: rgba(243, 236, 226, 0.86);
  --header-bg-scrolled: rgba(250, 246, 239, 0.95);
  --footer-bg: #2a2520;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 12px;
  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-body: "Outfit", system-ui, sans-serif;
  --header-h: 64px;
  --container: min(1200px, calc(100% - 32px));
  --section-y: clamp(36px, 5vw, 56px);
  --hero-pad-x: clamp(12px, 2vw, 20px);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  background:
    radial-gradient(ellipse 90% 55% at 50% -10%, rgba(212, 175, 90, 0.1), transparent 55%),
    radial-gradient(ellipse 45% 35% at 100% 40%, rgba(179, 139, 63, 0.06), transparent 50%),
    radial-gradient(ellipse 40% 30% at 0% 70%, rgba(230, 220, 200, 0.5), transparent 50%),
    var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, video {
  display: block;
  max-width: 100%;
  height: auto;
}

a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: none; background: none; }

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.container {
  width: var(--container);
  margin-inline: auto;
}

.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.02;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ========== Header ========== */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-inline: clamp(16px, 4vw, 40px);
  background: var(--header-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: background 0.3s var(--ease), border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.site-header.is-scrolled {
  background: var(--header-bg-scrolled);
  border-bottom-color: var(--line);
  box-shadow: var(--shadow-sm);
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 0.98rem;
  letter-spacing: -0.01em;
}

.logo-mark {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  background: var(--gold-soft);
  border-radius: var(--radius-sm);
  color: var(--gold);
}

.logo-mark svg { width: 16px; height: 16px; }

.logo-text em {
  font-style: normal;
  color: var(--gold);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(16px, 3vw, 28px);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-muted);
}

.site-nav a {
  position: relative;
  transition: color 0.25s;
}

.site-nav a:not(.nav-cta)::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 100%;
  height: 2px;
  background: var(--gold);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.3s var(--ease);
}

.site-nav a:not(.nav-cta):hover::after,
.site-nav a:not(.nav-cta).is-active::after {
  transform: scaleX(1);
  transform-origin: left;
}

.site-nav a.is-active:not(.nav-cta) {
  color: var(--text);
}

.site-nav a:hover { color: var(--text); }

.nav-cta {
  padding: 9px 18px;
  background: linear-gradient(135deg, var(--gold-deep), var(--gold));
  color: #fffdf8 !important;
  border-radius: var(--radius-sm);
  font-size: 0.8125rem;
  letter-spacing: 0.01em;
  transition: background 0.25s, transform 0.25s var(--ease), box-shadow 0.25s;
  box-shadow: var(--shadow-gold);
}

.nav-cta::after { display: none; }

.nav-cta:hover,
.nav-cta.is-active {
  background: linear-gradient(135deg, var(--gold), var(--gold-light));
  transform: translateY(-1px);
  box-shadow: 0 8px 28px var(--gold-glow);
}

.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  padding: 8px;
  border-radius: var(--radius-sm);
}

.menu-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--text);
  border-radius: 1px;
  transition: transform 0.25s, opacity 0.25s;
}

/* ========== Hero ========== */
.hero {
  box-sizing: border-box;
  width: 100%;
  padding:
    calc(var(--header-h) + 8px)
    var(--hero-pad-x)
    12px;
  background: var(--bg);
}

.hero-stage {
  width: 100%;
  max-width: 1320px;
  margin-inline: auto;
}

.hero-viewport {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  margin-inline: auto;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--champagne);
  border: 1px solid rgba(179, 139, 63, 0.22);
  box-shadow: var(--shadow-md), 0 0 0 1px rgba(212, 175, 90, 0.08);
  animation: heroEnter 0.9s var(--ease) both;
}

@keyframes heroEnter {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.hero-shine {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: linear-gradient(
    115deg,
    transparent 38%,
    rgba(255, 252, 247, 0.12) 48%,
    transparent 58%
  );
  background-size: 200% 100%;
  animation: heroShine 8s ease-in-out infinite;
}

@keyframes heroShine {
  0%, 100% { background-position: 200% 0; }
  50% { background-position: -100% 0; }
}

.hero-video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center center;
  display: block;
  position: relative;
  z-index: 1;
}

/* Scroll progress */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  z-index: 200;
  background: transparent;
  pointer-events: none;
}

.scroll-progress-bar {
  display: block;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--gold), var(--gold-light));
  transform-origin: left;
  transition: width 0.08s linear;
  box-shadow: 0 0 14px var(--gold-glow);
}

/* ========== Buttons ========== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  transition: background 0.2s, transform 0.2s var(--ease), box-shadow 0.2s;
}

.btn--primary {
  background: linear-gradient(135deg, var(--gold-deep), var(--gold));
  color: #fffdf8;
  box-shadow: var(--shadow-gold);
  position: relative;
  overflow: hidden;
}

.btn--primary::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent 30%, rgba(255, 255, 255, 0.15) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform 0.5s var(--ease);
}

.btn--primary:hover {
  background: linear-gradient(135deg, var(--gold), var(--gold-light));
  transform: translateY(-1px);
  box-shadow: 0 8px 28px var(--gold-glow);
}

.btn--primary:hover::after {
  transform: translateX(120%);
}

.btn--primary.is-success {
  background: linear-gradient(135deg, var(--gold), var(--gold-light));
  pointer-events: none;
}

/* ========== Value Strip ========== */
.value-strip {
  padding: var(--section-y) 0;
  background: var(--bg-elevated);
  border-block: 1px solid var(--line);
}

.value-strip-inner {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(20px, 3vw, 32px);
}

.value-item {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 16px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  transition:
    border-color 0.3s var(--ease),
    box-shadow 0.3s var(--ease),
    transform 0.3s var(--ease);
}

.value-item:hover {
  border-color: rgba(179, 139, 63, 0.3);
  box-shadow: 0 12px 32px rgba(45, 41, 36, 0.08), 0 0 0 1px rgba(212, 175, 90, 0.1);
  transform: translateY(-3px);
}

.value-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: var(--radius-sm);
  background: var(--gold-soft);
  color: var(--gold);
  transition: transform 0.35s var(--ease), background 0.35s;
}

.value-item:hover .value-icon {
  transform: scale(1.08) rotate(-3deg);
  background: rgba(179, 139, 63, 0.18);
}

.value-icon svg { width: 20px; height: 20px; }

.value-item h3 {
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 2px;
  letter-spacing: -0.01em;
}

.value-item p {
  font-size: 0.8125rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ========== Collections ========== */
.collections {
  position: relative;
  padding: var(--section-y) 0;
  overflow: hidden;
}

.collections-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 55% 45% at 50% 30%, rgba(212, 175, 90, 0.12), transparent 55%),
    radial-gradient(ellipse 60% 40% at 10% 20%, rgba(179, 139, 63, 0.07), transparent 50%),
    radial-gradient(ellipse 50% 35% at 90% 70%, rgba(230, 220, 200, 0.35), transparent 50%);
  pointer-events: none;
  animation: bgDrift 18s ease-in-out infinite alternate;
}

@keyframes bgDrift {
  from { transform: translateY(0) scale(1); }
  to { transform: translateY(-12px) scale(1.02); }
}

.collections-header {
  position: relative;
  z-index: 1;
  text-align: center;
  margin-bottom: clamp(28px, 4vw, 40px);
}

.section-eyebrow {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 12px;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4.5vw, 3rem);
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
  background: linear-gradient(135deg, var(--text) 20%, var(--silver-muted) 45%, var(--gold) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.section-lead {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 440px;
  margin-inline: auto;
  font-weight: 400;
  line-height: 1.65;
}

.chapter-list {
  position: relative;
  z-index: 1;
  width: var(--container);
  margin-inline: auto;
}

.chapter {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: clamp(20px, 3vw, 36px);
  align-items: center;
}

.chapter .chapter-visual,
.chapter .chapter-copy {
  transition:
    opacity 0.7s var(--ease),
    transform 0.7s var(--ease);
}

.chapter .chapter-visual {
  opacity: 0;
  transform: translateX(-28px) translateY(var(--parallax-y, 0));
}

.chapter .chapter-copy {
  opacity: 0;
  transform: translateY(20px);
}

.chapter--reverse .chapter-visual {
  transform: translateX(28px) translateY(var(--parallax-y, 0));
}

.chapter.is-visible .chapter-visual {
  opacity: 1;
  transform: translateX(0) translateY(var(--parallax-y, 0));
}

.chapter.is-visible .chapter-copy {
  opacity: 1;
  transform: translateY(0);
  transition-delay: 0.12s;
}

.chapter--reverse {
  grid-template-columns: 0.85fr 1.15fr;
}

.chapter--reverse .chapter-visual { order: 2; }
.chapter--reverse .chapter-copy { order: 1; text-align: right; }

.chapter-visual {
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--champagne);
  border: 1px solid rgba(179, 139, 63, 0.2);
  box-shadow: var(--shadow-sm);
  transition:
    box-shadow 0.4s var(--ease),
    border-color 0.4s var(--ease),
    transform 0.4s var(--ease);
  will-change: transform;
  transform: translateY(var(--parallax-y, 0));
}

@media (hover: hover) and (pointer: fine) {
  .chapter.is-visible .chapter-visual:hover {
    border-color: rgba(179, 139, 63, 0.38);
    box-shadow:
      0 16px 48px rgba(45, 41, 36, 0.1),
      0 0 0 1px rgba(212, 175, 90, 0.15);
    transform: translateX(0) translateY(calc(var(--parallax-y, 0px) - 4px));
  }
}

.chapter-visual img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
}

.chapter-copy {
  padding-block: 8px;
}

.chapter-tag {
  display: inline-block;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 10px;
  padding: 4px 10px;
  border: 1px solid rgba(179, 139, 63, 0.28);
  border-radius: var(--radius-sm);
  background: var(--gold-soft);
}

.chapter-copy h3 {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  font-weight: 600;
  margin-bottom: 10px;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.chapter-copy p {
  font-size: 0.9375rem;
  color: var(--text-muted);
  max-width: 340px;
  line-height: 1.65;
}

.chapter--reverse .chapter-copy p {
  margin-left: auto;
}

/* ========== Finale ========== */
.finale {
  position: relative;
  padding: var(--section-y) 0 calc(var(--section-y) + 8px);
  background:
    radial-gradient(ellipse 70% 50% at 50% 100%, rgba(212, 175, 90, 0.08), transparent 60%),
    var(--bg-elevated);
  border-top: 1px solid rgba(179, 139, 63, 0.12);
}

.finale-glow {
  position: absolute;
  top: 62%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(520px, 85vw);
  height: min(320px, 50vw);
  background: radial-gradient(circle, rgba(212, 175, 90, 0.1) 0%, rgba(179, 139, 63, 0.04) 45%, transparent 75%);
  pointer-events: none;
  animation: finalePulse 5s ease-in-out infinite;
}

@keyframes finalePulse {
  0%, 100% { opacity: 0.45; transform: translate(-50%, -50%) scale(1); }
  50% { opacity: 0.7; transform: translate(-50%, -50%) scale(1.04); }
}

.finale-title {
  display: inline-block;
  font-family: var(--font-display);
  font-size: clamp(2.25rem, 6vw, 3.75rem);
  font-weight: 600;
  font-style: italic;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
  line-height: 1.05;
  background: linear-gradient(135deg, var(--text) 8%, var(--gold-deep) 52%, var(--gold) 78%, var(--gold-light) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.notify-form input:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px var(--gold-soft);
  transform: translateY(-1px);
}

.notify-form input {
  transition: border-color 0.25s, box-shadow 0.25s, transform 0.25s var(--ease);
}

.finale-lead {
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 32px;
  line-height: 1.6;
}

.finale-lead strong {
  color: var(--gold);
  font-weight: 600;
}

.notify-form {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  max-width: 440px;
  margin: 0 auto 12px;
}

.notify-form input {
  flex: 1 1 220px;
  min-width: 0;
  height: 44px;
  padding: 0 16px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  font-family: var(--font-body);
  font-size: 0.875rem;
  line-height: 1.2;
  color: var(--text);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  -webkit-appearance: none;
  appearance: none;
}

.notify-form input::placeholder {
  color: #9a9186;
}

.finale-inner {
  text-align: center;
  position: relative;
  z-index: 1;
  padding: clamp(28px, 4vw, 44px) clamp(20px, 4vw, 36px);
  border-radius: var(--radius-lg);
  background: rgba(250, 246, 239, 0.55);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border: 1px solid rgba(179, 139, 63, 0.1);
  box-shadow: 0 10px 40px rgba(45, 41, 36, 0.05);
}

.notify-form .btn {
  flex-shrink: 0;
  min-width: 120px;
}

.finale-note {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

/* ========== Footer ========== */
.site-footer {
  padding: clamp(24px, 4vw, 36px) 0;
  background: var(--footer-bg);
  color: rgba(255, 252, 247, 0.74);
  text-align: center;
  border-top: 1px solid rgba(212, 175, 90, 0.15);
}

.footer-brand {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: #fffdf8;
  margin-bottom: 4px;
}

.footer-tagline {
  font-size: 0.8125rem;
  margin-bottom: 16px;
}

.footer-credit {
  font-size: 0.75rem;
  margin-bottom: 10px;
}

.footer-credit span {
  color: var(--gold-light);
  font-weight: 500;
}

.footer-copy {
  font-size: 0.6875rem;
  opacity: 0.55;
}

/* ========== Scroll Reveals ========== */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.chapter.reveal.is-visible {
  opacity: 1;
  transform: none;
}

.value-item.reveal:nth-child(1) { transition-delay: 0s; }
.value-item.reveal:nth-child(2) { transition-delay: 0.06s; }
.value-item.reveal:nth-child(3) { transition-delay: 0.12s; }
.value-item.reveal:nth-child(4) { transition-delay: 0.18s; }

/* ========== Responsive ========== */
@media (max-width: 1024px) {
  .value-strip-inner {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  :root {
    --header-h: 56px;
  }

  .chapter,
  .chapter--reverse {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .chapter--reverse .chapter-visual,
  .chapter--reverse .chapter-copy {
    order: unset;
    text-align: left;
  }

  .chapter--reverse .chapter-copy p {
    margin-left: 0;
  }

  .chapter-copy p {
    max-width: none;
  }

  .value-item {
    padding: 16px;
  }

  .chapter .chapter-visual,
  .chapter--reverse .chapter-visual {
    transform: translateY(20px);
  }

  .chapter.is-visible .chapter-visual {
    transform: translateY(0);
  }
}

@media (max-width: 640px) {
  .container {
    width: calc(100% - 32px);
  }

  .chapter {
    width: calc(100% - 32px);
  }

  .site-nav {
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--surface);
    padding: 8px;
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-md);
    transform: translateY(calc(-100% - var(--header-h)));
    opacity: 0;
    transition: transform 0.3s var(--ease), opacity 0.3s;
    pointer-events: none;
  }

  .site-nav.is-open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .site-nav a {
    padding: 12px 16px;
    text-align: center;
    border-radius: var(--radius-sm);
  }

  .site-nav a:not(.nav-cta):hover {
    background: var(--bg);
  }

  .nav-cta {
    margin-top: 4px;
    text-align: center;
  }

  .menu-toggle {
    display: flex;
  }

  .menu-toggle.is-active span:first-child {
    transform: translateY(3.5px) rotate(45deg);
  }

  .menu-toggle.is-active span:last-child {
    transform: translateY(-3.5px) rotate(-45deg);
  }

  .value-strip-inner {
    grid-template-columns: 1fr;
  }

  .notify-form {
    flex-direction: column;
    align-items: stretch;
  }

  .notify-form input {
    flex: 0 0 auto;
    width: 100%;
    height: 44px;
    min-height: 44px;
    max-height: 44px;
  }

  .notify-form .btn {
    width: 100%;
    height: 44px;
  }

  .finale-title {
    font-size: clamp(2rem, 10vw, 2.75rem);
  }
}

@media (max-width: 380px) {
  .logo-text {
    font-size: 0.9rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }

  .reveal,
  .chapter .chapter-visual,
  .chapter .chapter-copy {
    opacity: 1;
    transform: none;
  }

  .chapter-visual {
    will-change: auto;
  }
}
