/* ══════════════════════════════════════════════════════════════
   SOCIAL UGC — design system
   Static site: index.html / style.css / script.js
   ══════════════════════════════════════════════════════════════ */

/* ── Tokens ─────────────────────────────────────────────────── */
:root {
  --ink: #0B0D12;
  --charcoal: #151820;
  --ivory: #F6F5F0;
  --white: #FFFFFF;
  --cobalt: #5368FF; /* brand cobalt — fills, buttons, glows, borders (never small text) */
  /* Accent TEXT tiers, shared verbatim with the portal (frontend/src/app/globals.css):
     raw #5368FF measures 4.29:1 on --ink and 3.35:1 on --ivory — both under the
     WCAG AA 4.5 floor for small text. These two clear it on their surfaces. */
  --cobalt-text: #6478FF; /* accent text on dark surfaces (4.8:1+) */
  --cobalt-text-light: #3D4FD8; /* accent text on light surfaces (5.8:1) */
  --cobalt-soft: rgba(83, 104, 255, 0.16);
  --coral: #FF705D;
  --grey: #9298A5;
  --border: rgba(255, 255, 255, 0.12);
  --border-light: rgba(11, 13, 18, 0.10);

  --font-display: "Space Grotesk", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;

  --fs-hero: clamp(2.75rem, 8vw, 7.5rem);
  --fs-h2: clamp(2rem, 5vw, 4rem);
  --fs-h3: clamp(1.35rem, 2.4vw, 1.9rem);
  --fs-body: clamp(1rem, 1.1vw, 1.125rem);
  --fs-mono: 0.78rem;

  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 1.5rem;
  --space-4: 2.5rem;
  --space-5: 4rem;
  --space-6: 7rem;

  --radius-s: 8px;
  --radius-m: 14px;
  --radius-l: 22px;

  --shadow-frame: 0 30px 80px rgba(0, 0, 0, 0.45);
  --shadow-frame-light: 0 24px 60px rgba(11, 13, 18, 0.14);

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --dur: 0.8s;
  --width-max: 1280px;
  --width-text: 46rem;
}

/* ── Reset / base ───────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
html, body { overflow-x: clip; }
body {
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.6;
  background: var(--ink);
  color: var(--ivory);
  -webkit-font-smoothing: antialiased;
}
img, svg, video { max-width: 100%; display: block; }
img { height: auto; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 700; line-height: 1.12; letter-spacing: -0.015em; }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); }
::selection { background: var(--cobalt); color: var(--white); }

/* Film grain overlay */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  background: url("assets/textures/grain.svg");
  background-size: 300px;
  opacity: 0.05;
  pointer-events: none;
  z-index: 90;
  /* Own compositor layer — a fixed overlay without this repaints on every
     scrolled frame, which is exactly the jank it caused. */
  will-change: transform;
  transform: translateZ(0);
}

/* Focus */
:focus-visible { outline: 2px solid var(--cobalt); outline-offset: 3px; border-radius: 2px; }

.skip-link {
  position: absolute; top: -100px; left: var(--space-2); z-index: 300;
  background: var(--cobalt); color: var(--white);
  padding: 0.6rem 1rem; border-radius: var(--radius-s); text-decoration: none;
}
.skip-link:focus { top: var(--space-2); }

.scroll-progress {
  position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 250;
  background: var(--cobalt);
  transform: scaleX(0); transform-origin: 0 50%;
}

/* ── Reveal gate (JS-only hiding; failsafe restores) ────────── */
html.js body:not(.no-motion) [data-reveal] { opacity: 0; transform: translateY(26px); }
html.js body:not(.no-motion) [data-reveal].is-revealed { opacity: 1; transform: none; }
html.reveal-fallback [data-reveal],
html.no-motion [data-reveal] { opacity: 1 !important; transform: none !important; }

/* ── Utilities ──────────────────────────────────────────────── */
.mono-label {
  font-family: var(--font-mono);
  font-size: var(--fs-mono);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--grey);
}
.eyebrow {
  font-family: var(--font-mono);
  font-size: var(--fs-mono);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--cobalt-text);
  margin-bottom: var(--space-2);
}
.section--light .eyebrow { color: var(--cobalt-text-light); }

section { padding: var(--space-6) clamp(1.25rem, 5vw, 4rem); }
.section--dark { background: var(--ink); color: var(--ivory); }
.section--light { background: var(--ivory); color: var(--ink); }
.section--light h2, .section--light h3 { color: var(--ink); }
.section--light .mono-label { color: rgba(11, 13, 18, 0.55); }

.section-head { max-width: var(--width-max); margin: 0 auto var(--space-5); }
.section-head h2 { max-width: 20ch; }
.section-sub { max-width: var(--width-text); margin-top: var(--space-3); color: var(--grey); }
.section--light .section-sub { color: rgba(11, 13, 18, 0.65); }

/* Seams between dark and light zones */
.section--seam-light {
  background: linear-gradient(180deg, var(--ink) 0%, var(--ink) 72%, var(--ivory) 100%);
  padding-bottom: calc(var(--space-6) + 4rem);
}
.section--seam-dark {
  background: linear-gradient(180deg, var(--ivory) 0%, var(--ink) 26%, var(--ink) 100%);
  padding-top: calc(var(--space-6) + 4rem);
}

/* ── Buttons ────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-weight: 500;
  border-radius: 999px; text-decoration: none;
  min-height: 44px; padding: 0.65rem 1.5rem;
  transition: transform 0.25s var(--ease), background 0.25s, border-color 0.25s, filter 0.25s;
  white-space: nowrap;
}
.btn--primary { background: var(--cobalt); color: var(--white); }
.btn--primary:hover { filter: brightness(1.12); transform: translateY(-2px); }
.btn--primary:active { transform: translateY(0); filter: brightness(0.98); }
.btn--ghost { border: 1px solid var(--border); color: inherit; }
.section--light .btn--ghost, .footer .btn--ghost { border-color: var(--border-light); }
.btn--ghost:hover { border-color: var(--cobalt); color: var(--cobalt-text); }
.btn--sm { min-height: 40px; padding: 0.45rem 1.1rem; font-size: 0.9rem; }
.btn--lg { padding: 0.9rem 2rem; font-size: 1.05rem; }
.btn--xl { padding: 1.05rem 2.6rem; font-size: 1.15rem; }

.cta-line {
  display: inline-flex; gap: 0.5rem; align-items: center;
  font-family: var(--font-display); font-weight: 500; font-size: 1.05rem;
  color: var(--cobalt-text-light); text-decoration: none; margin-top: var(--space-3);
  min-height: 44px;
}
.cta-line:hover span { transform: translateX(4px); }
.cta-line span { transition: transform 0.25s var(--ease); }

/* ── Navigation ─────────────────────────────────────────────── */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  display: flex; align-items: center; gap: var(--space-4);
  padding: 0.8rem clamp(1.25rem, 4vw, 2.5rem);
  background: rgba(11, 13, 18, 0);
  border-bottom: 1px solid transparent;
  transition: background 0.4s, border-color 0.4s, backdrop-filter 0.4s;
}
.nav.is-scrolled {
  background: rgba(11, 13, 18, 0.78);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--border);
}
.nav__brand {
  display: inline-flex; align-items: center; gap: 0.6rem;
  font-family: var(--font-display); font-weight: 700; font-size: 1.1rem;
  text-decoration: none; letter-spacing: -0.01em;
}
/* The brand mark — the card-stack logo + wordmark, one identity everywhere. */
.brand-mark {
  display: inline-block; width: 1.9em; height: 1.9em; flex: none;
  background: url("assets/icons/favicon.svg") center / contain no-repeat;
}
.finale__brand {
  display: inline-flex; align-items: center; gap: 0.6rem;
  font-family: var(--font-display); font-weight: 700; font-size: 1.35rem;
}
.footer__wordmark { display: inline-flex; align-items: center; gap: 0.55rem; }
.nav__links { display: flex; gap: var(--space-3); margin-left: auto; }
.nav__links a {
  position: relative; text-decoration: none; font-size: 0.95rem; color: var(--grey);
  padding: 0.5rem 0.15rem; transition: color 0.25s;
}
.nav__links a::after {
  content: ""; position: absolute; left: 0; right: 100%; bottom: 0.2rem; height: 1.5px;
  background: var(--cobalt); transition: right 0.3s var(--ease);
}
.nav__links a:hover { color: var(--ivory); }
.nav__links a:hover::after { right: 0; }
.nav__actions { display: flex; align-items: center; gap: 0.75rem; }
.nav__burger {
  display: none; flex-direction: column; gap: 6px; padding: 12px; min-height: 44px; min-width: 44px;
  align-items: center; justify-content: center;
}
.nav__burger span { display: block; width: 22px; height: 2px; background: var(--ivory); }

/* Mobile menu */
.menu {
  border: none; width: 100vw; height: 100dvh; max-width: none; max-height: none;
  background: var(--ink); color: var(--ivory);
  padding: 5.5rem clamp(1.25rem, 6vw, 3rem) 3rem;
  display: none; flex-direction: column;
}
.menu[open] { display: flex; }
.menu::backdrop { background: rgba(11, 13, 18, 0.6); }
.menu__close { position: absolute; top: 1.1rem; right: 1.1rem; font-size: 1.3rem; padding: 12px; min-width: 44px; min-height: 44px; }
.menu__links { display: flex; flex-direction: column; gap: 0.4rem; margin-bottom: auto; }
.menu__links a {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(2rem, 9vw, 3rem); text-decoration: none; padding: 0.35rem 0;
}
.menu__links a:hover { color: var(--cobalt); }

/* ── The Lattice · chapters 00-02 ────────────────────────────
   One fixed canvas behind the first four sections. It sits under the grain
   overlay (z-index 90) deliberately: the grain is what marries the GL layer
   and the DOM into a single surface, and it hides the artifacts of the
   reduced internal render scale on tier B.

   Everything here is scoped to .journey-on, which journey.js sets only after
   a successful mount. Without it the page is byte-for-byte the site that was
   already live: opaque sections, CSS hero glows, DOM tool-card fields. */
/* z-index -1, not 0. A fixed element at z-index 0 paints ABOVE the background
   of every static, non-positioned block — so only sections explicitly given a
   z-index covered the canvas, and any other section that fell inside a window's
   scroll range had the world bleeding over it. Negative z puts the canvas under
   all content backgrounds and above the body's, so opaque sections occlude it
   for free and only the ones set to transparent reveal it. */
.journey {
  display: none;
  position: fixed; inset: 0; width: 100%; height: 100%;
  z-index: -1; pointer-events: none;
}
.journey-on .journey { display: block; }

/* The three dark runs the canvas shows through. Everything else on the page —
   the light sections, and the finale onward — keeps its opaque background and
   simply covers the canvas, which parks itself there. */
.journey-on .hero,
.journey-on .proof,
.journey-on .problem,
.journey-on .transform,
.journey-on .workflow,
.journey-on .midcta,
.journey-on .mission,
.journey-on .story,
.journey-on .rail,
.journey-on .finale { background: transparent; }

/* The finale's clip stops being a full-bleed backdrop and becomes a panel the
   world sits around — the brief's "scene-03 on the core face". Containing it
   rather than fading it is deliberate: commit 00ce9ac already established that
   dropping this footage's opacity averages the frame into a flat haze. It
   plays at full strength, just smaller. */
.journey-on .finale { min-height: 108svh; }
.journey-on .finale__scene {
  inset: auto; left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  width: min(880px, 84vw); aspect-ratio: 16 / 9;
  border-radius: var(--radius-l); overflow: hidden;
}
/* The GL core is the light source here now. */
.journey-on .finale__glow { display: none; }

/* Re-entering the dark from the light section above still has to happen; it
   just resolves to the canvas instead of to flat ink. */
.journey-on .mission {
  background: linear-gradient(180deg, var(--ivory) 0%, var(--ink) 22%, transparent 46%);
}

/* The seam into the light pillars section still has to happen — it just starts
   from the canvas instead of from flat ink.

   min-height buys the collapse its scroll distance. At the section's natural
   581px the entire lattice snapped shut in under 300px of scrolling, which read
   as a glitch rather than as the page's most important move. */
.journey-on .transform {
  min-height: 150vh;
  display: flex; flex-direction: column; justify-content: center;
  background: linear-gradient(180deg, transparent 0%, transparent 56%, var(--ink) 84%, var(--ivory) 100%);
}

/* The scrim was tuned to sit over a full-strength video. Over the GL field it
   was flattening the debris into near-invisibility, so it drops to the minimum
   the headline actually needs. */
.journey-on .hero__scene::after {
  background:
    radial-gradient(58% 46% at 50% 40%, rgba(11, 13, 18, 0.58) 0%, rgba(11, 13, 18, 0.26) 55%, transparent 100%),
    linear-gradient(180deg, rgba(11, 13, 18, 0.5) 0%, transparent 22%, transparent 62%, var(--ink) 98%);
}

/* The scatter and the convergence are the journey's job now. These DOM fields
   were the 2D version of the same gesture; running both plays it twice. */
.journey-on .problem__field,
.journey-on .transform__stage { display: none; }

/* ── S1 · Hero ──────────────────────────────────────────────── */
.hero {
  position: relative; min-height: 100svh;
  display: flex; flex-direction: column; align-items: center;
  padding-top: clamp(7rem, 14vh, 10rem);
  overflow: clip;
}
.hero__scene { position: absolute; inset: 0; pointer-events: none; }
/* The footage IS the hero background, so it plays at full strength. It was 0.55
   under two blurred glows and five decorative panels, which averaged the whole
   frame into a flat blue haze — present in the DOM, invisible to the eye. */
.hero__video {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; opacity: 1;
}
/* Legibility scrim: darken behind the copy and fade to ink at the seam, instead
   of dimming the whole clip. Two stops — a centre pool for the headline, a
   bottom ramp into the next section. */
.hero__scene::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(58% 46% at 50% 40%, rgba(11, 13, 18, 0.82) 0%, rgba(11, 13, 18, 0.45) 55%, transparent 100%),
    linear-gradient(180deg, rgba(11, 13, 18, 0.55) 0%, transparent 22%, transparent 58%, var(--ink) 97%);
}
/* blur() here is the most expensive paint on the page — keep the radius modest
   and rasterize each glow on its own layer so scrolling never re-blurs it. */
.hero__glow { position: absolute; border-radius: 50%; filter: blur(64px); transform: translateZ(0); }
.hero__glow--cobalt {
  width: 60vw; height: 60vw; max-width: 900px; max-height: 900px;
  background: radial-gradient(circle, rgba(83, 104, 255, 0.12), transparent 65%);
  top: -18%; right: -12%;
}
.hero__glow--coral {
  width: 34vw; height: 34vw; max-width: 480px; max-height: 480px;
  background: radial-gradient(circle, rgba(255, 112, 93, 0.07), transparent 65%);
  bottom: 8%; left: -8%;
}
/* Stand-ins from before Scene 01 existed: the clip has its own drifting panels,
   so these only muddied it. Kept for the poster-only path (no-motion/mobile). */
/* These are the hero background whenever the GL journey is not running. The
   rule used to be `body:not(.no-motion)`, but script.js puts .no-motion on
   <html>, so the selector never matched and the panels were hidden for
   everyone — invisible while the retired hero video covered them, a bare hero
   the moment it went away. Keyed to the journey now, which is the real
   condition: chapter 00 replaces them, nothing else does. */
.hero__panels { position: absolute; inset: 0; }
.journey-on .hero__panels { display: none; }
.hpanel {
  position: absolute; border-radius: var(--radius-m);
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.012));
  border: 1px solid var(--border);
  animation: drift 14s var(--ease) infinite alternate;
}
.hpanel--1 { width: 190px; height: 120px; top: 16%; left: 6%; rotate: -7deg; }
.hpanel--2 { width: 150px; height: 190px; top: 10%; right: 9%; rotate: 6deg; animation-delay: -3s; }
.hpanel--3 { width: 130px; height: 90px; top: 44%; left: 13%; rotate: 4deg; animation-delay: -6s; }
.hpanel--4 { width: 210px; height: 120px; top: 40%; right: 5%; rotate: -5deg; animation-delay: -9s; }
.hpanel--5 { width: 110px; height: 140px; top: 66%; left: 4%; rotate: 9deg; animation-delay: -11s; }
@keyframes drift {
  from { transform: translate(0, 0); }
  to { transform: translate(12px, -18px); }
}

.hero__inner { position: relative; text-align: center; max-width: 60rem; z-index: 2; }
.hero__title { font-size: var(--fs-hero); line-height: 1.02; letter-spacing: -0.03em; margin-bottom: var(--space-3); }
.hero__title .char { display: inline-block; }
.hero__sub { max-width: 40rem; margin: 0 auto var(--space-4); color: var(--grey); }
.hero__ctas { display: flex; gap: var(--space-2); justify-content: center; flex-wrap: wrap; margin-bottom: var(--space-4); }
.hero__platforms { display: flex; align-items: center; justify-content: center; gap: var(--space-2); flex-wrap: wrap; }
.platform-row { display: flex; gap: var(--space-3); list-style: none; }
.platform-row li { display: inline-flex; align-items: center; gap: 0.45rem; color: var(--grey); font-size: 0.9rem; }
.platform-row svg { width: 18px; height: 18px; }
.hero__trust { margin-top: var(--space-2); }

.hero__dash { position: relative; margin-top: var(--space-5); width: min(920px, 92vw); z-index: 2; }
.frame {
  position: relative; border-radius: var(--radius-m); overflow: hidden;
  border: 1px solid var(--border); background: var(--charcoal);
  box-shadow: var(--shadow-frame);
}
.section--light .frame { border-color: var(--border-light); box-shadow: var(--shadow-frame-light); }
.frame__bar {
  display: flex; align-items: center; gap: 6px;
  padding: 0.55rem 0.9rem; border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.03);
}
.frame__bar span { width: 9px; height: 9px; border-radius: 50%; background: rgba(255, 255, 255, 0.14); }
.frame__bar em { font-style: normal; margin-left: 0.6rem; }
.frame--back {
  position: absolute; width: 68%; right: -6%; top: 10%; rotate: 3deg;
  opacity: 0.5; filter: saturate(0.8);
}
.frame--front { width: 88%; }

.hero__cue {
  position: relative; z-index: 2; margin: var(--space-5) 0 var(--space-3);
  display: flex; flex-direction: column; align-items: center; gap: 0.6rem;
}
.hero__cue-line { width: 1.5px; height: 44px; background: linear-gradient(var(--cobalt), transparent); animation: cue 2.2s var(--ease) infinite; }
@keyframes cue { 0% { transform: scaleY(0); transform-origin: top; } 50% { transform: scaleY(1); } 100% { transform: scaleY(0); transform-origin: bottom; } }

/* ── S2 · Proof strip ───────────────────────────────────────── */
.proof { padding-top: var(--space-4); padding-bottom: var(--space-4); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.proof__strip {
  list-style: none; display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-4);
  justify-content: center; max-width: var(--width-max); margin: 0 auto;
  font-family: var(--font-mono); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.07em;
  color: var(--grey);
}
.proof__strip li { display: inline-flex; align-items: center; gap: 0.5rem; }
.proof__strip li::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--cobalt); }
.proof__num { color: var(--ivory); }
.proof__note { text-align: center; margin-top: var(--space-2); opacity: 0.65; font-size: 0.68rem; }

/* ── S3 · Problem ───────────────────────────────────────────── */
.problem__field { position: relative; height: 320px; max-width: var(--width-max); margin: 0 auto var(--space-4); }
.tool-card {
  position: absolute; display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.6rem 1rem; border-radius: var(--radius-s);
  border: 1px solid var(--border); background: var(--charcoal);
  font-family: var(--font-mono); font-size: 0.8rem; letter-spacing: 0.04em;
  color: var(--grey); white-space: nowrap;
}
.tool-card i { width: 8px; height: 8px; border-radius: 2px; background: var(--grey); opacity: 0.6; }
.tc-1 { top: 8%; left: 10%; rotate: -6deg; }
.tc-2 { top: 20%; left: 42%; rotate: 4deg; }
.tc-3 { top: 6%; right: 12%; rotate: -3deg; }
.tc-4 { top: 48%; left: 20%; rotate: 5deg; }
.tc-5 { top: 42%; right: 24%; rotate: -8deg; }
.tc-6 { top: 74%; left: 38%; rotate: 3deg; }
.tc-7 { top: 70%; right: 8%; rotate: 6deg; }
.tc-8 { top: 78%; left: 6%; rotate: -4deg; }
.problem__pains {
  list-style: none; max-width: var(--width-max); margin: 0 auto;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: var(--space-2) var(--space-4);
  color: var(--grey);
}
.problem__pains li { padding-left: 1.2rem; position: relative; }
.problem__pains li::before { content: ""; position: absolute; left: 0; top: 0.65em; width: 7px; height: 1.5px; background: var(--coral); }

/* ── S4 · Transformation ────────────────────────────────────── */
.transform__stage { position: relative; height: 480px; max-width: var(--width-max); margin: 0 auto; }
.transform__stage .ct-1 { top: 4%; left: 6%; rotate: -6deg; }
.transform__stage .ct-2 { top: 0%; right: 10%; rotate: 5deg; }
.transform__stage .ct-3 { top: 38%; left: 0%; rotate: 4deg; }
.transform__stage .ct-4 { top: 44%; right: 2%; rotate: -5deg; }
.transform__stage .ct-5 { top: 82%; left: 12%; rotate: 6deg; }
.transform__stage .ct-6 { top: 86%; right: 16%; rotate: -4deg; }
.transform__frame {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  width: min(560px, 84vw); padding: 1.2rem 1.4rem 1.4rem;
  border-radius: var(--radius-l); border: 1px solid rgba(83, 104, 255, 0.5);
  background: var(--charcoal);
  box-shadow: 0 0 80px rgba(83, 104, 255, 0.18), var(--shadow-frame);
}
.transform__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.7rem; margin-top: 1rem; }
.transform__grid span {
  height: 56px; border-radius: var(--radius-s);
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.015));
  border: 1px solid var(--border);
}

/* ── S5 · Pillars ───────────────────────────────────────────── */
.pillars .pillar {
  display: grid; grid-template-columns: 4rem 1.1fr 1fr; gap: var(--space-4);
  max-width: var(--width-max); margin: 0 auto; padding: var(--space-5) 0;
  border-top: 1px solid var(--border-light); align-items: center;
}
.pillar__num { font-size: 1rem; color: var(--cobalt-text-light); }
.pillar__outcome { font-size: 1.15rem; font-weight: 500; margin: var(--space-2) 0 var(--space-3); max-width: 34rem; }
.pillar__caps { list-style: none; display: flex; flex-wrap: wrap; gap: 0.5rem; }
.pillar__caps li {
  font-family: var(--font-mono); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.06em;
  padding: 0.4rem 0.75rem; border-radius: 999px; border: 1px solid var(--border-light);
  color: rgba(11, 13, 18, 0.6);
}
.pillar__visual img { width: 100%; }

/* ── S6 · Workflow (pinned) ─────────────────────────────────── */
.workflow { padding: 0; }
.workflow__pin {
  min-height: 100svh; display: flex; flex-direction: column; justify-content: center;
  padding: var(--space-6) clamp(1.25rem, 5vw, 4rem);
}
.workflow .section-head { margin-bottom: var(--space-4); }
.workflow__scene {
  position: relative; aspect-ratio: 16 / 9; max-height: 46vh; max-width: 900px; margin: 0 auto; width: 100%;
  border-radius: var(--radius-l); overflow: hidden;
}
/* Rendered scenes sit behind their section's HTML; the fade keeps copy legible. */
.scene-video { width: 100%; height: 100%; object-fit: cover; opacity: 1; }
.workflow__scene::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(11,13,18,0.45) 0%, transparent 28%, transparent 72%, rgba(11,13,18,0.65) 100%);
}
.finale__video {
  position: absolute; inset: 0; opacity: 0.9;
}
/* Same treatment as the hero: pool the darkness behind the words, not over the clip. */
.finale__scene::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(55% 50% at 50% 50%, rgba(11, 13, 18, 0.8) 0%, rgba(11, 13, 18, 0.4) 60%, transparent 100%);
}

.stage-rail {
  list-style: none; display: flex; flex-wrap: wrap; gap: 0.5rem;
  justify-content: center; margin: var(--space-4) auto 0; max-width: 900px;
  counter-reset: stage;
}
.stage-rail li {
  font-family: var(--font-mono); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em;
  padding: 0.55rem 1rem; border-radius: 999px; border: 1px solid var(--border); color: var(--grey);
  transition: color 0.3s, border-color 0.3s, background 0.3s;
}
.stage-rail li.is-active { color: var(--white); border-color: var(--cobalt); background: var(--cobalt-soft); }
.stage-rail li.is-done { color: var(--ivory); border-color: rgba(83, 104, 255, 0.35); }
.stage-rail li[data-stage-publish].is-active { border-color: var(--coral); background: rgba(255, 112, 93, 0.14); }
.workflow__caption { text-align: center; margin-top: var(--space-3); }

/* ── Mid CTA ────────────────────────────────────────────────── */
.midcta { text-align: center; padding-top: var(--space-5); padding-bottom: var(--space-5); }
.midcta p { font-family: var(--font-display); font-weight: 500; font-size: clamp(1.3rem, 2.6vw, 1.9rem); margin-bottom: var(--space-3); }

/* ── S7 · Showcase ──────────────────────────────────────────── */
.showcase__pin {
  display: grid; grid-template-columns: minmax(280px, 420px) 1fr; gap: var(--space-5);
  max-width: var(--width-max); margin: 0 auto; align-items: start;
}
.showcase__nav { display: flex; flex-direction: column; gap: var(--space-2); }
.showcase__tab {
  text-align: left; padding: 1rem 1.2rem; border-radius: var(--radius-m);
  border: 1px solid transparent; color: rgba(11, 13, 18, 0.55);
  display: flex; flex-direction: column; gap: 0.35rem;
  transition: border-color 0.3s, background 0.3s, color 0.3s;
}
.showcase__tab .mono-label { transition: color 0.3s; }
.showcase__tab.is-active {
  border-color: var(--border-light); background: var(--white); color: var(--ink);
  box-shadow: 0 10px 30px rgba(11, 13, 18, 0.07);
}
.showcase__tab.is-active .mono-label { color: var(--cobalt-text-light); }
.showcase__stage { position: relative; }
.showcase__panel { display: none; }
.showcase__panel.is-active { display: block; }
.showcase__stage .frame__bar { background: rgba(11, 13, 18, 0.04); border-color: var(--border-light); }
.showcase__stage .frame__bar span { background: rgba(11, 13, 18, 0.14); }

/* ── S8 · Distribution ──────────────────────────────────────── */
.distribution__grid {
  display: grid; grid-template-columns: minmax(260px, 380px) 1fr; gap: var(--space-5);
  max-width: var(--width-max); margin: 0 auto; align-items: start;
}
.dist-source {
  position: sticky; top: 7rem;
  padding: var(--space-3); border-radius: var(--radius-m);
  background: var(--ink); color: var(--ivory);
}
.dist-source h3 { margin: 0.6rem 0; color: var(--ivory); }
.dist-source .mono-label { color: var(--grey); }
.dist-source p { color: var(--grey); font-size: 0.95rem; }
.dist-cards { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-3); }
.dist-card {
  padding: var(--space-3); border-radius: var(--radius-m);
  background: var(--white); border: 1px solid var(--border-light);
  display: flex; flex-direction: column; gap: var(--space-2);
  box-shadow: 0 12px 34px rgba(11, 13, 18, 0.05);
}
.dist-card header { display: flex; align-items: center; gap: 0.6rem; }
.dist-card svg { width: 20px; height: 20px; color: var(--ink); }
.dist-card p { font-size: 0.95rem; color: rgba(11, 13, 18, 0.78); }
.dist-card--x { margin-top: var(--space-4); }
.dist-card--th { margin-top: calc(var(--space-4) * -1); }
.dist-card__visual {
  aspect-ratio: 1; border-radius: var(--radius-s);
  background: linear-gradient(150deg, var(--ink), #232840);
  display: flex; align-items: center; justify-content: center; text-align: center;
  color: var(--ivory); font-family: var(--font-display); font-weight: 700;
  font-size: 1.3rem; line-height: 1.3;
}
.distribution__note { text-align: center; margin-top: var(--space-5); }

/* ── S9 · Audiences ─────────────────────────────────────────── */
.audiences__tabs {
  display: flex; gap: 0.5rem; flex-wrap: wrap;
  max-width: var(--width-max); margin: 0 auto var(--space-4);
}
.audiences__tabs [role="tab"] {
  font-family: var(--font-display); font-weight: 500; font-size: 1rem;
  padding: 0.7rem 1.4rem; border-radius: 999px; border: 1px solid var(--border-light);
  color: rgba(11, 13, 18, 0.6); min-height: 44px;
  transition: background 0.25s, color 0.25s, border-color 0.25s;
}
.audiences__tabs [aria-selected="true"] { background: var(--ink); color: var(--ivory); border-color: var(--ink); }
.audiences__panels { max-width: var(--width-max); margin: 0 auto; }
.audiences__panels [role="tabpanel"] { max-width: var(--width-text); }
.audiences__panels h3 { margin-bottom: var(--space-2); }
.audiences__panels p { color: rgba(11, 13, 18, 0.65); }

/* ── S10 · Mission ──────────────────────────────────────────── */
.mission { text-align: center; }
.mission__statement {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(2.2rem, 6vw, 5rem); letter-spacing: -0.025em; line-height: 1.05;
  max-width: 16ch; margin: 0 auto var(--space-5);
}
.mission__quote { max-width: var(--width-text); margin: 0 auto; }
.mission__quote p { font-size: clamp(1.1rem, 1.8vw, 1.4rem); color: var(--grey); font-style: normal; }
.mission__quote cite { display: block; margin-top: var(--space-2); font-style: normal; }

/* ── S11 · Story ────────────────────────────────────────────── */
.story__grid {
  display: grid; grid-template-columns: 1.4fr 1fr; gap: var(--space-5);
  max-width: var(--width-max); margin: 0 auto; align-items: start;
}
.story__text p { color: var(--grey); margin-bottom: var(--space-3); max-width: 58ch; }
.story__chip {
  display: inline-flex; align-items: center; gap: 0.6rem;
  padding: 0.55rem 1rem; border: 1px solid var(--border); border-radius: 999px;
}
.story__chip .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--coral); animation: pulse 2.4s ease infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.35; } }
.story__photo-ph {
  aspect-ratio: 4 / 5; border-radius: var(--radius-m);
  border: 1px dashed var(--border); background: var(--charcoal);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1rem;
  color: var(--grey);
}

/* ── S12 · Workflow rail ────────────────────────────────────── */
.rail { overflow: clip; }
.rail__viewport { max-width: none; }
.rail__track { display: flex; gap: var(--space-3); padding: 0 clamp(1.25rem, 5vw, 4rem); width: max-content; }
.rail-card {
  width: 320px; flex-shrink: 0;
  padding: var(--space-3); border-radius: var(--radius-m);
  background: var(--charcoal); border: 1px solid var(--border);
  transition: border-color 0.3s, transform 0.3s var(--ease);
}
.rail-card:hover { border-color: rgba(83, 104, 255, 0.5); transform: translateY(-4px); }
.rail-card svg { width: 26px; height: 26px; color: var(--cobalt); margin-bottom: var(--space-2); }
.rail-card h3 { font-size: 1.15rem; margin-bottom: 0.5rem; }
.rail-card p { font-size: 0.92rem; color: var(--grey); }

/* S13 · Social proof — section cut 2026-08-06, styles removed with it. */

/* ── S14 · Finale ───────────────────────────────────────────── */
.finale { position: relative; min-height: 88svh; display: grid; place-items: center; overflow: clip; text-align: center; }
.finale__scene { position: absolute; inset: 0; pointer-events: none; }
.finale__glow {
  position: absolute; left: 50%; top: 60%; transform: translate(-50%, -50%) translateZ(0);
  width: 76vw; height: 76vw; max-width: 1000px; max-height: 1000px; border-radius: 50%;
  background: radial-gradient(circle, rgba(83, 104, 255, 0.16), rgba(255, 112, 93, 0.045) 45%, transparent 70%);
  filter: blur(44px);
  animation: breathe 9s var(--ease) infinite alternate;
}
@keyframes breathe { from { opacity: 0.7; } to { opacity: 1; } }
.finale__inner { position: relative; z-index: 2; display: flex; flex-direction: column; align-items: center; gap: var(--space-3); }
.finale__mark { border-radius: 14px; }
.finale h2 { font-size: clamp(2.2rem, 5.5vw, 4.5rem); letter-spacing: -0.025em; }
.finale__alt { color: var(--grey); text-decoration-color: var(--border); }
.finale__alt:hover { color: var(--ivory); }

/* ── Demo ───────────────────────────────────────────────────── */
.demo { text-align: left; border-top: 1px solid var(--border); }
.demo .section-head { margin-bottom: var(--space-3); }
.demo .btn { margin: 0 auto 0 0; }

/* ── Footer ─────────────────────────────────────────────────── */
.footer { background: var(--ink); color: var(--ivory); padding: var(--space-5) clamp(1.25rem, 5vw, 4rem) var(--space-3); border-top: 1px solid var(--border); }
.footer__top {
  display: grid; grid-template-columns: minmax(220px, 1fr) 2fr; gap: var(--space-5);
  max-width: var(--width-max); margin: 0 auto var(--space-4);
}
.footer__wordmark { font-family: var(--font-display); font-weight: 700; font-size: 1.3rem; }
.footer__brand p { color: var(--grey); margin-top: var(--space-2); max-width: 26rem; font-size: 0.95rem; }
.footer__cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: var(--space-3); }
.footer__cols div { display: flex; flex-direction: column; gap: 0.6rem; }
.footer__cols a { text-decoration: none; color: var(--grey); font-size: 0.95rem; padding: 0.15rem 0; }
.footer__cols a:hover { color: var(--ivory); }
.footer__cols a[aria-disabled="true"] { opacity: 0.5; pointer-events: none; }
.footer__legal { text-align: center; opacity: 0.6; }

/* ── Sticky mobile CTA ──────────────────────────────────────── */
.sticky-cta {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 180;
  padding: 0.7rem 1rem calc(0.7rem + env(safe-area-inset-bottom));
  background: rgba(11, 13, 18, 0.85); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--border);
  display: none; transform: translateY(110%); transition: transform 0.4s var(--ease);
}
.sticky-cta .btn { width: 100%; }
.sticky-cta.is-visible { transform: translateY(0); }

/* ── Request-access modal ───────────────────────────────────── */
.access {
  border: 1px solid var(--border); border-radius: var(--radius-l);
  background: var(--charcoal); color: var(--ivory);
  width: min(620px, calc(100vw - 2rem));
  max-height: calc(100dvh - 3rem);
  padding: clamp(1.5rem, 4vw, 2.6rem);
  margin: auto;
}
.access::backdrop { background: rgba(11, 13, 18, 0.75); backdrop-filter: blur(6px); }
.access__close { position: absolute; top: 0.9rem; right: 0.9rem; padding: 10px; min-width: 44px; min-height: 44px; color: var(--grey); }
.access__close:hover { color: var(--ivory); }
.access h2 { font-size: clamp(1.5rem, 3vw, 2rem); margin-bottom: 0.6rem; }
.access__sub { color: var(--grey); margin-bottom: var(--space-3); font-size: 0.95rem; }

.field { margin-bottom: var(--space-2); border: none; }
.field label, .field legend { display: block; font-size: 0.85rem; font-weight: 500; margin-bottom: 0.4rem; color: var(--ivory); }
.field input[type="text"], .field input[type="email"], .field select, .field textarea {
  width: 100%; padding: 0.7rem 0.9rem; border-radius: var(--radius-s);
  border: 1px solid var(--border); background: var(--ink); color: var(--ivory);
  font: inherit; font-size: 0.95rem;
}
.field select { appearance: none; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--cobalt); outline-offset: 1px; border-color: transparent; }
.field--row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-2); }
.field--row .field { margin-bottom: 0; }
.checks { display: flex; flex-wrap: wrap; gap: 0.5rem 1.2rem; }
.checks label { display: inline-flex; align-items: center; gap: 0.5rem; font-weight: 400; font-size: 0.95rem; margin: 0; min-height: 32px; }
.checks input, .field--check input { accent-color: var(--cobalt); width: 16px; height: 16px; }
.field--check { display: flex; align-items: center; gap: 0.6rem; font-size: 0.95rem; color: var(--grey); }
.field__error { display: block; min-height: 1.1em; font-size: 0.8rem; color: var(--coral); margin-top: 0.25rem; }
.field.is-invalid input, .field.is-invalid select, .field.is-invalid textarea { border-color: var(--coral); }
.access__submit { width: 100%; margin-top: var(--space-2); }
.access__fineprint { text-align: center; margin-top: var(--space-2); font-size: 0.68rem; }
.access__success { text-align: center; display: flex; flex-direction: column; align-items: center; gap: var(--space-2); padding: var(--space-4) 0; }
.access__success svg { color: var(--cobalt); }

/* ══ Responsive ═════════════════════════════════════════════ */
@media (max-width: 1199px) {
  .showcase__pin { grid-template-columns: 1fr; }
  .showcase__nav { flex-direction: row; overflow-x: auto; padding-bottom: 0.5rem; }
  .showcase__tab { min-width: 240px; }
}

@media (max-width: 900px) {
  .pillars .pillar { grid-template-columns: 1fr; gap: var(--space-3); }
  .pillar__num { order: -1; }
  .story__grid, .distribution__grid, .footer__top { grid-template-columns: 1fr; }
  .dist-source { position: static; }
  .dist-card--x, .dist-card--th { margin-top: 0; }
}

@media (max-width: 767px) {
  :root { --space-6: 4.5rem; --space-5: 3rem; }
  .nav__links, .nav__actions .btn { display: none; }
  .nav__burger { display: flex; }
  .hero { padding-top: 6.5rem; }
  .hero__title { font-size: clamp(2.75rem, 11vw, 3.4rem); }
  .hpanel { display: none; }
  .frame--back { display: none; }
  .frame--front { width: 100%; }
  .problem__field { height: 260px; }
  .tool-card { font-size: 0.7rem; padding: 0.45rem 0.7rem; }
  .transform__stage { height: 420px; }
  .dist-cards { grid-template-columns: 1fr; }
  .rail__viewport { overflow-x: auto; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch; }
  .rail-card { width: 280px; scroll-snap-align: start; }
  .sticky-cta { display: block; }
  .menu__links a, .btn { -webkit-tap-highlight-color: transparent; }
}

/* ══ Reduced motion ═════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  .hero__cue-line, .hpanel, .finale__glow, .story__chip .dot { animation: none !important; }
}
