/* ─────────────────────────────────────────
   ZENTO — style.css
   Dark mode. Cormorant Garamond + Space Mono.
   Pure black background, warm gold accents.
───────────────────────────────────────── */

:root {
  --bg:           #000000;
  --text:         #EDE8DF;
  --muted:        #4A4643;
  --accent:       #C4A46B;
  --accent-dim:   #7A6540;
  --zen-green:    #00311E;
  --taupet:       #887A65;
  --terra:        #A25835;
  --font-display: 'Cormorant Garamond', Georgia, serif;
  --font-mono:    'Space Mono', 'Courier New', monospace;
}

/* ── Reset ── */
*, *::before, *::after {
  margin: 0; padding: 0; box-sizing: border-box;
}

html {
  background: var(--bg);
  scroll-behavior: auto; /* Lenis handles this */
}

body {
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Film grain: barely-perceptible noise layer, editorial-luxury feel */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 500;
  pointer-events: none;
  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='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
  background-size: 180px 180px;
  opacity: 0.038;
  mix-blend-mode: overlay;
}

a { text-decoration: none; color: inherit; }

/* ── LOGO IMAGE ── */
/* logo.png: transparent-bg PNG, cream pixels — shows naturally on dark backgrounds */
.logo-img {
  display: block;
  max-width: 100%;
  height: auto;
}

/* ── LOADER ── */
#loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.8rem;
}

.loader-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.2rem;
}

.loader-logo {
  width: clamp(220px, 38vw, 360px);
}


.loader-bar-wrap {
  width: 220px;
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  position: relative;
  overflow: hidden;
}

#loader-bar {
  position: absolute;
  top: 0; left: 0;
  height: 100%;
  width: 0%;
  background: var(--accent);
  transition: width 0.15s linear;
}

#loader-percent {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--muted);
  letter-spacing: 0.12em;
}

/* ── HEADER ── */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 200;
  padding: 1.6rem 3.5rem;
  mix-blend-mode: difference;
  pointer-events: none;
}

.site-header nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-logo {
  pointer-events: auto;
  cursor: pointer;
}

.nav-logo-img {
  width: 7rem;
}

.nav-links {
  display: flex;
  gap: 2.8rem;
  pointer-events: auto;
}

.nav-links a {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  font-weight: 400;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #ffffff;
  opacity: 0.55;
  transition: opacity 0.3s ease;
}

.nav-links a:hover { opacity: 1; }

.nav-links a.is-active {
  opacity: 1;
  color: var(--accent);
}

/* ── HERO STANDALONE ── */
.hero-standalone {
  position: relative;
  height: 100vh;
  background-color: var(--bg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  z-index: 5;
}

/* Background layer — separate div so GSAP can parallax it independently */
.hero-bg {
  position: absolute;
  inset: -25% 0;
  background-image: url('../bg-hero.jpg');
  background-size: cover;
  background-position: 18% 50%;
  pointer-events: none;
  will-change: transform;
  z-index: 0;
}

/* Gradient overlay: sits between bg and text */
.hero-standalone::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    transparent 0%,
    transparent 65%,
    rgba(0, 0, 0, 0.6) 82%,
    #000000 96%
  );
  pointer-events: none;
  z-index: 1;
}

/* Text wrapper — parallaxes faster than bg */
.hero-parallax-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  z-index: 2;
  will-change: transform;
}

/* Text elements: soft shadow so they lift off the green bg */
.hero-label,
.hero-tagline,
.hero-sub {
  text-shadow: 0 2px 20px rgba(0,0,0,0.65), 0 1px 4px rgba(0,0,0,0.4);
}

/* Logo is an <img> — needs filter instead of text-shadow */
.hero-logo {
  filter: drop-shadow(0 2px 20px rgba(0,0,0,0.6)) drop-shadow(0 1px 5px rgba(0,0,0,0.35));
}

/* Scroll indicator above gradient */
.hero-standalone .scroll-indicator {
  position: absolute;
  z-index: 2;
}

.hero-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.22em;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 2.2rem;
}

.hero-heading {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 0;
}

.hero-logo {
  width: clamp(260px, 60vw, 800px);
  opacity: 0;
  transform: translateY(40px);
}

.hero-tagline {
  font-family: var(--font-display);
  font-size: clamp(1.1rem, 2.8vw, 1.9rem);
  font-weight: 300;
  font-style: italic;
  color: var(--accent);
  margin-top: 1.8rem;
  letter-spacing: 0.06em;
  opacity: 0;
}

.hero-sub {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--text);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-top: 0.9rem;
  opacity: 0;
}

/* Scroll indicator */
.scroll-indicator {
  position: absolute;
  bottom: 2.8rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  opacity: 0;
}

.scroll-label {
  font-family: var(--font-mono);
  font-size: 0.52rem;
  letter-spacing: 0.22em;
  color: var(--muted);
  text-transform: uppercase;
}

.scroll-arrow {
  width: 1px;
  height: 36px;
  background: linear-gradient(to bottom, var(--accent), transparent);
  animation: scroll-pulse 2s ease-in-out infinite;
}

@keyframes scroll-pulse {
  0%, 100% { opacity: 0.4; transform: scaleY(1); }
  50% { opacity: 1; transform: scaleY(1.3); }
}

/* ── CANVAS ── */
.canvas-wrap {
  position: fixed;
  inset: 0;
  z-index: 1;
  background: var(--bg);
  transition: opacity 0.12s linear;
}

#canvas {
  display: block;
  width: 100%;
  height: 100%;
}

/* Vignette: fades light product bg into pure black at edges */
.canvas-vignette {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(
      ellipse 58% 58% at 50% 50%,
      transparent 25%,
      rgba(0, 0, 0, 0.55) 60%,
      rgba(0, 0, 0, 0.92) 82%,
      #000000 100%
    );
}

/* ── DARK OVERLAY ── */
#dark-overlay {
  position: fixed;
  inset: 0;
  z-index: 2;
  background: rgba(0, 0, 0, 0.91);
  opacity: 0;
  pointer-events: none;
}

/* ── MARQUEE ── */
.marquee-wrap {
  position: fixed;
  top: 50%;
  left: 0;
  right: 0;
  z-index: 3;
  pointer-events: none;
  opacity: 0;
  transform: translateY(-50%);
  overflow: hidden;
  line-height: 1;
}

.marquee-text {
  font-family: var(--font-display);
  font-size: 13vw;
  font-weight: 300;
  color: var(--text);
  white-space: nowrap;
  letter-spacing: 0.02em;
  will-change: transform;
  opacity: 0.06;
}

/* ── SCROLL CONTAINER ── */
#scroll-container {
  position: relative;
  height: 850vh;
  z-index: 4;
}

/* ── SCROLL SECTIONS ── */
.scroll-section {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 100vh;
  display: flex;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  z-index: 10;
}

.scroll-section.is-visible {
  pointer-events: auto;
}

/* Content sections: text anchors to bottom of viewport */
.section-content {
  align-items: flex-end;
  padding-bottom: 9vh;
}

/* Side alignment — product lives in center, text in outer 42% */
.align-left  { padding-left: 5vw;  padding-right: 53vw; }
.align-right { padding-left: 53vw; padding-right: 5vw; }

.align-left  .section-inner,
.align-right .section-inner { max-width: 42vw; }

/* Directional gradient: darkens the text side so it's always readable */
.align-left::before,
.align-right::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.align-left::before {
  background: linear-gradient(
    to right,
    rgba(0, 0, 0, 0.92) 0%,
    rgba(0, 0, 0, 0.65) 36%,
    rgba(0, 0, 0, 0.15) 55%,
    transparent 70%
  );
}

.align-right::before {
  background: linear-gradient(
    to left,
    rgba(0, 0, 0, 0.92) 0%,
    rgba(0, 0, 0, 0.65) 36%,
    rgba(0, 0, 0, 0.15) 55%,
    transparent 70%
  );
}

/* Bottom gradient: extra darkness where text sits */
.section-content::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 52%;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.88) 0%, transparent 100%);
  pointer-events: none;
  z-index: 0;
}

/* Section inner sits above gradients */
.section-content .section-inner {
  position: relative;
  z-index: 1;
}

/* sec-003/004 have ::after at z-index:1 (above video) — raise inner above it */
.sec-003 .section-inner,
.sec-004 .section-inner {
  z-index: 2;
}

/* Brand ambient glow — deep forest green radiating from behind text block */
.section-ambience {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.align-left .section-ambience {
  background:
    radial-gradient(ellipse 55% 60% at 12% 85%, rgba(0, 49, 30, 0.38) 0%, transparent 65%),
    radial-gradient(ellipse 30% 40% at 5% 50%,  rgba(0, 49, 30, 0.12) 0%, transparent 60%);
}

.align-right .section-ambience {
  background:
    radial-gradient(ellipse 55% 60% at 88% 85%, rgba(0, 49, 30, 0.38) 0%, transparent 65%),
    radial-gradient(ellipse 30% 40% at 95% 50%, rgba(0, 49, 30, 0.12) 0%, transparent 60%);
}

.section-cta .section-ambience {
  background: radial-gradient(ellipse 70% 65% at 50% 55%, rgba(0, 49, 30, 0.3) 0%, transparent 65%);
}

/* Section number watermarks — large faint numbers on opposite side from text */
.section-bg-num {
  position: absolute;
  font-family: var(--font-display);
  font-size: clamp(20rem, 32vw, 40rem);
  font-weight: 300;
  line-height: 1;
  color: var(--text);
  opacity: 0.07;
  pointer-events: none;
  letter-spacing: -0.05em;
  user-select: none;
  z-index: 0;
  bottom: -0.22em;
}

.align-left  .section-bg-num { right: 0; }
.align-right .section-bg-num { left: 0; }

/* Gold accent rule above section label — animates scaleX 0→1 on enter */
.label-rule {
  display: block;
  width: 2.8rem;
  height: 1px;
  background: var(--accent);
  margin-bottom: 1.2rem;
  transform-origin: left;
  transform: scaleX(0);
}

/* Zen stone SVG watermark in CTA section */
.cta-bg-brand {
  position: absolute;
  width: clamp(18rem, 34vw, 30rem);
  height: auto;
  color: var(--text);
  opacity: 0.1;
  pointer-events: none;
  user-select: none;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -60%);
  z-index: 0;
}
.cta-bg-brand svg { display: block; width: 100%; height: auto; }

/* Corner bracket accent on section-inner — single L-bracket, top outer corner */
.section-content .section-inner::before {
  content: '';
  position: absolute;
  width: 20px;
  height: 20px;
  border-color: rgba(196, 164, 107, 0.55);
  border-style: solid;
}
.align-left  .section-inner::before { top: -1rem; left: -1.4rem; border-width: 1px 0 0 1px; }
.align-right .section-inner::before { top: -1rem; right: -1.4rem; border-width: 1px 1px 0 0; }

/* Section typography */
.section-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.22em;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 1.4rem;
}

.section-heading {
  font-family: var(--font-display);
  font-size: clamp(2.6rem, 4.5vw, 4.2rem);
  font-weight: 600;
  line-height: 1.0;
  color: var(--text);
  margin-bottom: 1.5rem;
  letter-spacing: -0.01em;
}

.section-body {
  font-family: var(--font-display);
  font-size: clamp(0.95rem, 1.4vw, 1.1rem);
  font-weight: 300;
  line-height: 1.75;
  color: var(--text);
  opacity: 0.72;
}


/* ── CTA ── */
.section-cta {
  justify-content: center;
  z-index: 10;
}

.cta-inner {
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
  padding: 0 2rem;
  position: relative;
  z-index: 1;
}

.cta-heading {
  font-size: clamp(3.5rem, 7.5vw, 7rem) !important;
  font-weight: 300 !important;
  letter-spacing: 0.08em;
  line-height: 0.9 !important;
  margin-bottom: 0.25em;
}

.cta-logo {
  width: clamp(200px, 44vw, 520px);
  margin: 0 auto;
}

.cta-tagline {
  font-style: italic;
  font-size: clamp(1rem, 1.8vw, 1.35rem) !important;
  margin-top: 1.2rem;
  color: var(--accent) !important;
  opacity: 1 !important;
}

.cta-button {
  display: inline-block;
  margin-top: 2.8rem;
  padding: 0.95rem 3.2rem;
  border: 1px solid var(--accent-dim);
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--text);
  transition: background 0.35s ease, border-color 0.35s ease, color 0.35s ease;
}

.cta-button:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #000;
}

/* ── MANIFESTO SECTION (replaces stats) ── */
.section-manifesto {
  justify-content: center;
  align-items: center;
  padding: 0 5vw;
  z-index: 10;
}

.manifesto-inner {
  max-width: 660px;
  width: 100%;
  text-align: center;
}

/* Override section-heading defaults for the manifesto headline */
.manifesto-headline {
  font-size: clamp(3rem, 5.8vw, 5rem) !important;
  font-weight: 300 !important;
  line-height: 1.0 !important;
  letter-spacing: -0.01em !important;
  margin-bottom: 0 !important;
}

.manifesto-headline em {
  display: block;
  font-style: italic;
}

.manifesto-sub {
  display: block;
  font-family: var(--font-mono);
  font-size: clamp(0.44rem, 0.66vw, 0.58rem);
  font-weight: 400;
  font-style: normal;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  margin-top: 1.3rem;
  opacity: 0.85;
}

/* Thin centered gold hairline between headline and body */
.manifesto-rule {
  width: clamp(80px, 12vw, 160px);
  height: 1px;
  background: linear-gradient(to right, transparent, var(--accent-dim), transparent);
  margin: 2.8rem auto;
}

.manifesto-inner .section-body {
  font-size: clamp(0.9rem, 1.22vw, 1.02rem);
  line-height: 1.92;
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

/* Second paragraph: subtle top border and spacing */
.manifesto-p2 {
  margin-top: 1.8rem;
  padding-top: 1.8rem;
  border-top: 1px solid rgba(196, 164, 107, 0.15);
}

/* ── WARM BACKGROUND SECTIONS (003 / 004) ── */

.sec-003 {
  /* background removed — scroll-scrubbed video handles the bg */
}

/* Full-cover scroll-scrubbed video inside a fixed section */
.sec-bg-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 58% center;
  z-index: 0;
  pointer-events: none;
}

/* Overlays must sit above the video */
.sec-003.align-left::before {
  z-index: 1;
}
.sec-003.section-content::after {
  z-index: 1;
}

.sec-004 {
  background-image: url('../bg4.png');
  background-size: cover;
  background-position: 38% center;
  background-repeat: no-repeat;
}

/* Override dark gradient with a warmer, less opaque version so image warmth shows through */
.sec-003.align-left::before {
  background: linear-gradient(
    to right,
    rgba(10, 5, 2, 0.86) 0%,
    rgba(10, 5, 2, 0.54) 36%,
    rgba(10, 5, 2, 0.12) 58%,
    transparent 74%
  );
}

.sec-004.align-right::before {
  background: linear-gradient(
    to left,
    rgba(10, 5, 2, 0.86) 0%,
    rgba(10, 5, 2, 0.54) 36%,
    rgba(10, 5, 2, 0.12) 58%,
    transparent 74%
  );
}

/* Warmer bottom vignette — blends image into the lower text zone */
.sec-003.section-content::after,
.sec-004.section-content::after {
  background: linear-gradient(
    to top,
    rgba(6, 3, 1, 0.92) 0%,
    rgba(6, 3, 1, 0.22) 46%,
    transparent 100%
  );
}

/* Hide green ambient glow — image already provides warmth */
.sec-003 .section-ambience,
.sec-004 .section-ambience {
  display: none;
}

/* ── MOBILE ── */
@media (max-width: 768px) {
  .hero-heading { font-size: clamp(5rem, 24vw, 8rem); }
  .hero-label { margin-bottom: 1.5rem; }

  .site-header { padding: 1.2rem 1.8rem; }
  .nav-links { display: none; }

  .align-left, .align-right {
    padding: 0 5vw;
    justify-content: center;
    align-items: flex-end;
    padding-bottom: 8vh;
  }

  .align-left .section-inner,
  .align-right .section-inner {
    max-width: 90vw;
    padding: 1.8rem 1.5rem;
    background: rgba(0, 0, 0, 0.78);
  }

  /* Sections with video/image backgrounds: lighter box than sec-001/002 so warmth shows through */
  .sec-003 .section-inner,
  .sec-004 .section-inner {
    background: rgba(0, 0, 0, 0.58);
  }

  /* Hero bg: remove extra inset so cover scale is based on actual viewport height */
  .hero-bg {
    inset: 0;
    background-position: 22% 50%;
  }

  .section-cta { align-items: center; }
  .cta-inner { padding: 1.8rem 1.5rem; background: rgba(0, 0, 0, 0.78); }

  #scroll-container { height: 600vh; }

  .marquee-text { font-size: 20vw; }

  /* CSS vignette: widen ellipse so it doesn't double up with the corrected JS vignette */
  .canvas-vignette {
    background: radial-gradient(
      ellipse 110% 95% at 50% 50%,
      transparent 28%,
      rgba(0,0,0,0.4) 62%,
      #000 100%
    );
  }

  /* Replace side gradient with radial vignette — matches canvas section smoothness */
  .sec-003.align-left::before,
  .sec-004.align-right::before {
    background: radial-gradient(
      ellipse 105% 90% at 50% 50%,
      transparent 18%,
      rgba(0, 0, 0, 0.28) 52%,
      rgba(0, 0, 0, 0.72) 100%
    );
    z-index: 1;
  }

  /* Mobile: hide scroll-scrubbed video, use static bg3.png instead (no jank) */
  #bg3-video {
    display: none;
  }

  .sec-003 {
    background-image: url('../bg3.png');
    background-size: cover;
    background-position: center center;
  }

  /* Stronger bottom gradient compensates for removed side gradient */
  .sec-003.section-content::after,
  .sec-004.section-content::after {
    background: linear-gradient(
      to top,
      rgba(0, 0, 0, 0.98) 0%,
      rgba(0, 0, 0, 0.88) 28%,
      rgba(0, 0, 0, 0.60) 50%,
      rgba(0, 0, 0, 0.18) 70%,
      transparent 100%
    );
    height: 78%;
  }

  /* Text-shadow backup for readability over bright video/image */
  .sec-003 .section-heading,
  .sec-003 .section-body,
  .sec-003 .section-label,
  .sec-004 .section-heading,
  .sec-004 .section-body,
  .sec-004 .section-label {
    text-shadow: 0 1px 16px rgba(0,0,0,0.9), 0 2px 4px rgba(0,0,0,0.7);
  }
}
