/* base — resets, shell, nav, shared atoms */
* { box-sizing: border-box; }
html, body { margin: 0; }
html { scroll-behavior: auto; } /* Lenis owns smooth scroll */

body {
  font-family: var(--font-sans);
  background: radial-gradient(120% 85% at 50% 34%, #131E17 0%, #0A0F0C 46%, var(--void) 100%);
  background-color: var(--void);
  color: var(--bone);
  letter-spacing: var(--tracking-snug);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* fixed film vignette — multiplies darkness toward the frame edges */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: radial-gradient(140% 100% at 50% 45%, transparent 45%, rgba(0, 0, 0, 0.5) 100%);
  mix-blend-mode: multiply;
}

a { color: inherit; text-decoration: none; }
:focus-visible { outline: 2px solid var(--teal-bright); outline-offset: 3px; }

.wrap { max-width: 1160px; margin: 0 auto; padding: 0 var(--pad-gutter); }

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: -100px; left: 16px;
  z-index: 100;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--on-teal);
  background: var(--teal-bright);
  padding: 10px 16px;
  border-radius: 9px;
  transition: top var(--motion-fast) var(--easing-default);
}
.skip-link:focus-visible { top: 14px; }

.eyebrow {
  margin: 0 0 14px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--sun);
}

/* ── NAV — fixed; hidden until the sun lands as its logo at the hero finale.
   Near-opaque, no backdrop-filter (Chrome flickers blur layers). ── */
.topnav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 40;
  background: rgba(12, 22, 17, 0.97);
  border-bottom: 1px solid var(--hair-d);
  opacity: 0;
  will-change: opacity, transform;
}
.topnav .row { height: 66px; display: flex; align-items: center; justify-content: space-between; }

.lockup { display: inline-flex; align-items: center; gap: 11px; min-width: 0; }
.lockup .wm {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.045em;
  color: var(--bone);
  white-space: nowrap;
}

.topnav .logo-slot { position: relative; display: inline-block; width: 26px; height: 26px; flex: none; }
.topnav .logo-slot svg { position: absolute; inset: 0; opacity: 0; }
.topnav .logo-slot canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  pointer-events: none;
}

.topnav .links { display: flex; gap: 30px; }
.topnav .links a {
  font-size: 13.5px;
  color: var(--mist-2);
  transition: color var(--motion-fast) var(--easing-default);
}
.topnav .links a:hover { color: var(--bone); }

.topnav .right { display: flex; align-items: center; gap: 22px; }
.topnav .signin { font-size: 13.5px; color: var(--mist-2); transition: color var(--motion-fast) var(--easing-default); }
.topnav .signin:hover { color: var(--bone); }
.topnav .console {
  font-size: 13px;
  font-weight: 500;
  color: var(--on-teal);
  background: var(--teal);
  padding: 9px 17px;
  border-radius: 9px;
  transition: background var(--motion-fast) var(--easing-default), transform var(--motion-fast) var(--easing-default);
}
.topnav .console:hover { background: var(--teal-bright); transform: translateY(-1px); }
.topnav .console:active { transform: translateY(0); }

@media (max-width: 780px) {
  .topnav .links { display: none; }
  .topnav .signin { display: none; }
}

/* narrow phones: keep the lockup + "Join the waitlist" pill from forcing
   horizontal scroll at 320–414px. */
@media (max-width: 400px) {
  .topnav .wrap { padding: 0 14px; }
  .topnav .console { padding: 8px 12px; font-size: 12px; }
}

/* ── reduced-motion / fallback switches ── */
.is-reduced #flysun,
.is-reduced #scene-canvas,
.is-reduced .copy-layer,
.is-reduced .chip-layer,
.is-reduced #film,
.is-reduced .scrollcue { display: none !important; }
.is-reduced .sunstory { height: auto !important; min-height: 100vh; }
.is-reduced .sunstage { position: relative !important; }
.is-reduced #reduced-stack { display: block; }
.is-reduced .sub { opacity: 1 !important; } /* static hero shows both beats */
