/* ============================================================
   Truffle Chat — design system
   Carried over from truffle.tech:
   crisp neutral surfaces, hairline borders, compact micro-labels,
   Geist typography and a restrained green signal.
   Light + dark with one self-hosted font family.
   ============================================================ */

/* ============================================================
   truffle brand kit — the one source of truth
   ─────────────────────────────────────────────────────────────
   MARK     mushroom silhouette: cap arc `M6 17 A 10 8 0 0 1 26 17 Z`
            + stem `rect x13 y17 w6 h8 rx1.5` inside a 32×32 rx6 tile.
            Every instance (favicon, nav, footer, app chrome, palette)
            MUST use this exact geometry at any size.
   COLOR    --bg light #F8F6F0 / dark #0C0B09 · --ink/--text #0A0A0A|dark
            brand green (single accent): --btn-bg #126B50 · signal #4ADE80
            green ≤5% of any viewport. Never green text on green.
   TYPE     Geist (100–900 var) — wordmark, display, body, controls, and data.
   MOTION   cubic-bezier(.16,1,.3,1) everywhere; 300-600ms; one signature
            per view (spore colony + wireframe mark are the signatures).
   ───────────────────────────────────────────────────────────── */


/* ---------- self-hosted fonts ---------- */
@font-face {
  font-family: "Geist";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("fonts/geist-latin.woff2") format("woff2");
}

/* ---------- tokens ---------- */
:root {
  color-scheme: light;

  /* Warm bone, carried over from the design running on truffle.tech: paper
     rather than screen-grey, near-black ink, and every neutral warm rather
     than green-shifted. --btn-bg is the one token that is NOT from there --
     it was #14120D, and green is what the buttons and the logo mark are
     asked to be. The mark is <rect fill="var(--btn-bg)">, so the button
     colour and the logo colour are the same decision, made once. */
  --bg: #F8F6F0;
  --bg-elev: #FEFDFA;
  --surface: #F2EFE7;
  --surface-press: #E8E4D9;
  --border: #DDD8CC;
  --ink: #14120D;
  --ink-hover: #2A261E;
  --btn-bg: #126B50;
  --btn-fg: #FBFAF6;
  --text-secondary: #55514A;
  --text-muted: #5F5B52;
  --text-faint: #6E6A60;
  --live: #047756;
  --danger: #B91C1C;
  --focus: #075FB2;
  --tint: #FDFCF8;
  --tint-2: #F8F6F0;
  --nav-bg: rgba(248, 246, 240, 0.58);
  --focus-ring: rgba(18, 107, 80, 0.22);

  --touch-target: 2.75rem;
  --safe-area-top: env(safe-area-inset-top, 0px);
  --safe-area-right: env(safe-area-inset-right, 0px);
  --safe-area-bottom: env(safe-area-inset-bottom, 0px);
  --safe-area-left: env(safe-area-inset-left, 0px);

  --shadow-pill: 0 1px 2px rgba(46, 40, 22, 0.14);
  --shadow-btn: 0 2px 8px rgba(46, 40, 22, 0.14);
  --shadow-card: 0 1px 2px rgba(46, 40, 22, 0.06), 0 12px 40px rgba(46, 40, 22, 0.09);
  --shadow-card-hover: 0 2px 4px rgba(46, 40, 22, 0.06), 0 20px 56px rgba(46, 40, 22, 0.12);

  --container: 1100px;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);

  --step--1: 0.875rem;
  --step-0: 1rem;
  --step-1: 1.25rem;
  --step-2: 1.5rem;
  --step-3: 1.875rem;
  --step-4: 2.25rem;
  --step-5: 3rem;
  --step-6: 2.5rem;
  --step-7: 3.5rem;
}

html.dark {
  color-scheme: dark;

  /* Same source, same single exception: warm near-black and bone ink, with
     --btn-bg green where the live design had it bone. */
  --bg: #0C0B09;
  --bg-elev: #16140F;
  --surface: #1B1813;
  --surface-press: #242017;
  --border: #353127;
  --ink: #F2EFE7;
  --ink-hover: #FBF9F3;
  --btn-bg: #57D3A8;
  --btn-fg: #0A1410;
  --text-secondary: #ABA69A;
  --text-muted: #8B877B;
  --text-faint: #837E72;
  --live: #34D399;
  --danger: #F87171;
  --focus: #8EC5FF;
  --tint: #1A1712;
  --tint-2: #14120F;
  --nav-bg: rgba(12, 11, 9, 0.5);
  --focus-ring: rgba(87, 211, 168, 0.24);

  --shadow-pill: 0 1px 2px rgba(0, 0, 0, 0.5);
  --shadow-btn: 0 2px 8px rgba(0, 0, 0, 0.5);
  --shadow-card: 0 1px 2px rgba(0, 0, 0, 0.4), 0 12px 40px rgba(0, 0, 0, 0.45);
  --shadow-card-hover: 0 2px 4px rgba(0, 0, 0, 0.4), 0 20px 56px rgba(0, 0, 0, 0.55);
}

@media (min-width: 700px) {
  :root {
    --step-6: 4rem;
    --step-7: 5.75rem;
  }
}

@media (min-width: 1200px) {
  :root {
    --step-6: 4.625rem;
    --step-7: 6.25rem;
  }
}

/* ---------- base ---------- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  letter-spacing: 0 !important;
}

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
section[id] { scroll-margin-top: 88px; }

.skip-link {
  position: fixed;
  top: max(12px, var(--safe-area-top));
  left: max(16px, var(--safe-area-left));
  z-index: 2000;
  padding: 10px 16px;
  border-radius: 8px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-size: 14px;
  text-decoration: none;
  transform: translateY(-72px);
  transition: transform 0.2s ease;
}
.skip-link:focus-visible { transform: translateY(0); }

body {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-size: var(--step-0);
  line-height: 1.6;
  transition: background-color 0.25s ease, color 0.25s ease;
  overflow-x: clip;
}

::selection { background: var(--ink); color: var(--bg); }

/* quiet custom scrollbar */
html { scrollbar-width: thin; scrollbar-color: var(--border) transparent; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 999px;
  border: 2px solid var(--bg);
}
::-webkit-scrollbar-thumb:hover { background: var(--text-faint); }

img, svg { display: block; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input { font: inherit; }
a { color: inherit; text-decoration: none; }

:where(a[href], button, input, select, textarea, summary, [role="button"], [role="option"]) {
  touch-action: manipulation;
}

:where(p, li, figcaption, blockquote) { overflow-wrap: anywhere; }
:where(img, video, canvas) { max-inline-size: 100%; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0);
}

.container {
  max-width: 1140px;
  margin-inline: auto;
  padding-inline: max(24px, var(--safe-area-left)) max(24px, var(--safe-area-right));
}
@media (min-width: 640px) {
  .container {
    padding-inline: max(32px, var(--safe-area-left)) max(32px, var(--safe-area-right));
  }
}

/* ---------- scroll progress ---------- */
.progress {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 2px;
  z-index: 60;
  pointer-events: none;
}
.progress__bar {
  height: 100%;
  width: 0;
  background: var(--ink);
  transition: width 0.1s linear;
}

/* ---------- micro label ---------- */
.eyebrow {
  margin-bottom: 40px;
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-faint);
  min-height: 14px;
}

/* ---------- notice strip ---------- */
.notice { background: var(--surface); border-bottom: 1px solid var(--border); }
.notice__inner {
  max-width: var(--container);
  margin-inline: auto;
  padding: 10px 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 12px;
  color: var(--text-secondary);
}
.notice__link {
  font-size: 12px;
  font-weight: 500;
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, var(--text-faint) 40%, transparent);
  text-underline-offset: 2px;
  white-space: nowrap;
  transition: text-decoration-color 0.15s ease;
}
.notice__link:hover { text-decoration-color: var(--ink); }

/* ---------- nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 40;
  height: calc(64px + var(--safe-area-top));
  padding-block-start: var(--safe-area-top);
  background: var(--nav-bg);
  backdrop-filter: blur(18px) saturate(1.5);
  -webkit-backdrop-filter: blur(18px) saturate(1.5);
  border-bottom: 1px solid var(--border);
  /* specular top edge — the pane reads as glass, not fog */
  box-shadow: inset 0 1px 0 color-mix(in srgb, white 22%, transparent);
}
.nav__inner {
  max-width: 1140px;
  margin-inline: auto;
  height: 64px;
  padding-inline: max(24px, var(--safe-area-left)) max(24px, var(--safe-area-right));
  display: flex;
  align-items: center;
  justify-content: space-between;
}
@media (min-width: 640px) {
  .nav__inner {
    padding-inline: max(32px, var(--safe-area-left)) max(32px, var(--safe-area-right));
  }
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: opacity 0.15s ease;
}
.wordmark:hover { opacity: 0.8; }
.wordmark span {
  /* Locked (owner order 2026-09-03): the wordmark is Geist, upright, permanently. */
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1;
  color: var(--ink);
}

.nav__links { display: flex; align-items: center; gap: 4px; }
@media (max-width: 900px) { .nav__links .nav__link { display: none; } .nav__links .btn-pill { display: none; } }

.nav__link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding-inline: 14px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color 0.15s ease, background-color 0.15s ease;
}
.nav__link:hover { color: var(--ink); background: var(--surface-press); }
.nav__link.is-active { color: var(--ink); background: var(--surface-press); }
.nav__link--quiet { color: var(--text-faint); }
.nav {
  transition: transform 0.4s var(--ease-out), background-color 0.25s ease;
}
.nav--hidden { transform: translateY(-100%); }

.palette-btn {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  height: 44px;
  padding-inline: 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--text-muted);
  transition: color 0.15s ease, border-color 0.15s ease, background-color 0.15s ease;
}
.palette-btn:hover { color: var(--ink); border-color: var(--text-faint); background: var(--surface-press); }
.palette-btn kbd {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 11px;
}
@media (max-width: 900px) { .palette-btn { display: none; } }

.theme-toggle {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  transition: color 0.15s ease, background-color 0.15s ease, transform 0.3s var(--ease-out);
}
.theme-toggle:hover { color: var(--ink); background: var(--surface-press); }
.theme-toggle:active { transform: scale(0.92); }
.theme-toggle .icon-sun { display: none; }
html.dark .theme-toggle .icon-sun { display: block; }
html.dark .theme-toggle .icon-moon { display: none; }

.btn-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 44px;
  padding-inline: 16px;
  border-radius: 999px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-size: 13px;
  font-weight: 500;
  box-shadow: var(--shadow-pill);
  transition: filter 0.15s ease, transform 0.2s var(--ease-out);
  will-change: transform;
}
.btn-pill:hover { filter: brightness(1.1); }
.btn-pill svg, .btn-primary svg, .btn-white svg { transition: transform 0.2s var(--ease-out); }
.btn-pill:hover svg, .btn-primary:hover svg, .btn-white:hover svg { transform: translateX(3px); }

/* ---------- hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  min-height: calc(88svh - 64px);
  display: flex;
  align-items: center;
}
.hero__spores {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}
@media (max-width: 480px) {
  .hero__form { flex-direction: column; align-items: stretch; }
  .hero__form .btn-primary { justify-content: center; }
}
.hero__inner {
  position: relative;
  z-index: 1;
  width: 100%;
  padding-block: 96px 64px;
}

/* one composition, not two columns: the mark is the hero, the type is set into it */
.hero__copy { position: relative; z-index: 2; max-width: 780px; pointer-events: none; }
.hero__copy a, .hero__copy form, .hero__copy button, .hero__copy input { pointer-events: auto; }

.hero__stage {
  position: absolute;
  top: 0;
  bottom: 0;
  right: max(24px, var(--safe-area-right));
  /* extra left-room so the mark sits closer to the copy: wider stage +
     size-aware fitScale grows the mark, offsetX keeps it off the text */
  width: min(56vw, 860px);
  z-index: 0;
  border: none !important;
  background: none !important;
  border-radius: 0 !important;
}
.hero__stage::before, .hero__stage::after { display: none !important; }
.hero__stage canvas { cursor: grab; }
.hero__stage.anim { filter: none; }
.hero__stage canvas:active { cursor: grabbing; }
@media (max-width: 1199px) {
  .hero { min-height: 0; display: flex; flex-direction: column; }
  .hero__inner { order: -1; }
  .hero__stage {
    position: relative;
    right: 0;
    width: 100%;
    height: clamp(400px, 58vw, 600px);
    margin-top: 40px;
  }
}
@media (max-width: 600px) {
  .hero__inner { padding-block: 40px 8px; }
  .hero .hero__note { display: none; }
  .hero__stage { height: 168px; margin-top: 8px; }
}

.status-line {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 28px;
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: var(--ink);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.35; }
}

h1 {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: var(--step-7);
  font-weight: 700;
  letter-spacing: 0;
  line-height: 0.98;
  overflow-wrap: anywhere;
  text-wrap: balance;
}

h1 em {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-style: normal;
  font-weight: 400;
  color: var(--text-secondary);
}

/* masked line reveal — desktop only; mobile headline is plain and wraps */
@media (min-width: 700px) {
  h1 .line { display: block; overflow: hidden; padding-bottom: 0.06em; margin-bottom: -0.06em; }
  h1 .line > span {
    display: inline-block;
    transform: translateY(115%);
    animation: lineUp 1s var(--ease-out) forwards;
  }
  h1 .line-1 > span { animation-delay: 0.1s; }
  h1 .line-2 > span { animation-delay: 0.24s; }
}
@keyframes lineUp { to { transform: none; } }

/* per-character rise (JS splits; .split disables the line-level anim) */
h1.split .line > span { transform: none; animation: none; }
h1 .ch {
  display: inline-block;
  transform: translateY(120%);
  animation: chUp 0.75s var(--ease-out) forwards;
}
@keyframes chUp { to { transform: none; } }

.hero__sub {
  margin-top: 32px;
  font-size: 18px;
  line-height: 1.6;
  color: var(--text-secondary);
  max-width: 460px;
}
@media (min-width: 640px) {
  .hero__sub { font-size: 19px; line-height: 1.55; }
}

/* hero form */
.hero__form {
  margin-top: 28px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 460px;
}
@media (min-width: 640px) {
  .hero__form { flex-direction: row; gap: 12px; }
}
.field {
  flex: 1 1 auto;
  height: 56px;
  min-height: 56px;
  padding-inline: 24px;
  border-radius: 8px;
  background: var(--bg-elev);
  border: 1px solid var(--border);
  font-size: 16px;
  color: var(--ink);
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.field::placeholder { color: var(--text-muted); }
.field:focus-visible {
  border-color: var(--ink);
  box-shadow: 0 0 0 4px var(--focus-ring);
}

.btn-primary {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 56px;
  padding-inline: 28px;
  border-radius: 8px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-size: 15px;
  font-weight: 500;
  white-space: nowrap;
  flex-shrink: 0;
  box-shadow: var(--shadow-btn);
  transition: filter 0.15s ease, transform 0.2s var(--ease-out);
  will-change: transform;
}
.btn-primary:hover { filter: brightness(1.1); }
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 56px;
  padding-inline: 24px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: color-mix(in srgb, var(--bg-elev) 72%, transparent);
  color: var(--ink);
  font-size: 15px;
  font-weight: 500;
  white-space: nowrap;
  transition: background-color 0.15s ease, border-color 0.15s ease, transform 0.2s var(--ease-out);
}
.btn-secondary:hover { background: var(--surface-press); border-color: var(--text-faint); }
.btn-secondary:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--btn-bg) 55%, transparent);
  outline-offset: 2px;
}
.btn-primary::after,
.btn-white::after {
  content: "";
  position: absolute;
  top: -10%;
  bottom: -10%;
  left: -80%;
  width: 45%;
  background: linear-gradient(105deg, transparent, rgba(242, 239, 231, 0.28), transparent);
  transform: skewX(-20deg);
  transition: left 0.65s var(--ease-out);
  pointer-events: none;
}
.btn-primary:hover::after,
.btn-white:hover::after { left: 135%; }

.hero__note {
  margin-top: 16px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-muted);
  transition: color 0.3s ease;
}

/* hero fold bar — scroll cue + a true fact about the mark */
.hero__foot {
  position: absolute;
  left: max(24px, calc((100vw - var(--container)) / 2));
  right: max(24px, calc((100vw - var(--container)) / 2));
  bottom: 26px;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  pointer-events: none;
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-faint);
}
.hero__scrollcue { display: inline-flex; align-items: center; gap: 12px; }
.hero__scrollcue i {
  display: block;
  width: 1px;
  height: 34px;
  background: var(--border);
  position: relative;
  overflow: hidden;
}
.hero__scrollcue i::after {
  content: "";
  position: absolute;
  left: 0;
  top: -40%;
  width: 100%;
  height: 40%;
  background: var(--ink);
  animation: cueDrop 2.2s var(--ease-out) infinite;
}
@keyframes cueDrop { 0% { top: -40%; } 60%, 100% { top: 110%; } }
@media (max-width: 1199px) { .hero__foot { display: none; } }
@media (prefers-reduced-motion: reduce) { .hero__scrollcue i::after { animation: none; } }

/* First-viewport content stays paintable without waiting on choreography. */
.anim {
  opacity: 1;
  transform: none;
  filter: none;
  animation: none;
}

/* scroll cue — removed */

/* ---------- live chat demo ---------- */

.chat-card {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow-card);
  overflow: hidden;
  transition: box-shadow 0.3s ease, transform 0.5s var(--ease-out);
  will-change: transform;
  transform-style: preserve-3d;
}
.chat-card:hover { box-shadow: var(--shadow-card-hover); }

.chat-card__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}
.chat-card__title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.chat-card__meta {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--text-faint);
}
.chat-card__body {
  padding: 24px 20px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-height: 320px;
  max-height: 400px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}
@media (min-width: 640px) { .chat-card__body { padding: 28px 24px; } }

.msg { display: flex; flex-direction: column; gap: 6px; max-width: 92%; flex-shrink: 0; }
.msg--user { align-self: flex-end; align-items: flex-end; }
.msg--service { align-self: flex-start; }

.msg__label {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-faint);
}
.msg__bubble {
  padding: 14px 18px;
  border-radius: 14px;
  font-size: 14px;
  line-height: 1.55;
  min-height: 1.55em;
}
.msg--user .msg__bubble {
  background: var(--btn-bg);
  color: var(--btn-fg);
  border-bottom-right-radius: 4px;
}
.msg--service .msg__bubble {
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--ink);
  border-bottom-left-radius: 4px;
}

.msg__bubble.is-typing span::after {
  content: "";
  display: inline-block;
  width: 7px;
  height: 14px;
  margin-left: 2px;
  vertical-align: -2px;
  background: currentColor;
  opacity: 0.85;
  animation: caret 0.8s steps(1) infinite;
}
@keyframes caret { 50% { opacity: 0; } }

.is-thinking .msg__bubble::before {
  content: "";
  display: inline-flex;
  width: 36px;
  height: 14px;
  background-image:
    radial-gradient(circle 2.5px, var(--text-faint) 2.4px, transparent 2.6px),
    radial-gradient(circle 2.5px, var(--text-faint) 2.4px, transparent 2.6px),
    radial-gradient(circle 2.5px, var(--text-faint) 2.4px, transparent 2.6px);
  background-size: 12px 5px;
  background-position: 0 center, 12px center, 24px center;
  background-repeat: no-repeat;
  animation: thinkdots 1.1s ease-in-out infinite;
}
@keyframes thinkdots {
  0%, 100% { opacity: 0.35; transform: translateY(0); }
  40% { opacity: 1; transform: translateY(-2px); }
}

.msg__sources {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.4s ease, transform 0.4s var(--ease-out);
}
.msg__sources.is-on { opacity: 1; transform: none; }
.src-chip {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--bg-elev);
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 10px;
  letter-spacing: 0.04em;
  color: var(--text-muted);
}

.chat-card__foot {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-top: 1px solid var(--border);
}
.chat-card__clip { color: var(--text-faint); flex-shrink: 0; }
.chat-card__form { display: flex; align-items: center; gap: 12px; flex: 1; min-width: 0; }
.chat-card__form:focus-within {
  border-radius: 6px;
  box-shadow: 0 0 0 3px var(--focus-ring);
}
.chat-card__input {
  flex: 1;
  min-width: 0;
  background: transparent;
  border: none;
  outline: none;
  font-size: 14px;
  color: var(--ink);
  height: 38px;
}
.chat-card__input::placeholder { color: var(--text-faint); }
.chat-card__send {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  flex-shrink: 0;
  transition: filter 0.15s ease, transform 0.2s var(--ease-out);
  will-change: transform;
}
.chat-card__send:hover { filter: brightness(1.1); }
.chat-card__input:disabled { opacity: 1; cursor: default; }
.chat-card__send:disabled { opacity: 0.55; cursor: default; }
.chat-card__send:disabled:hover { filter: none; }

/* ---------- ticker ---------- */
.ticker {
  border-block: 1px solid var(--border);
  overflow: hidden;
  padding-block: 14px;
  background: var(--bg);
}
.ticker__track {
  display: flex;
  align-items: center;
  gap: 32px;
  width: max-content;
  animation: marquee 36s linear infinite;
}
.ticker:hover .ticker__track { animation-play-state: paused; }
.ticker__item {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
  white-space: nowrap;
}
.ticker__dot {
  width: 4px;
  height: 4px;
  border-radius: 1px;
  background: var(--ink);
  opacity: 0.7;
  flex-shrink: 0;
}
/* ---------- sections ---------- */
.section { border-top: 1px solid var(--border); padding-block: 72px; }
.section--tight { padding-block: 64px; }
@media (min-width: 640px) { .section { padding-block: 96px; } .section--tight { padding-block: 80px; } }

h2 {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: var(--step-6);
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.02;
  max-width: 20ch;
  overflow-wrap: anywhere;
  text-wrap: balance;
}
h2 em {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-style: normal;
  font-weight: 400;
  color: var(--text-secondary);
}
.section-head p.lede {
  margin-top: 24px;
  font-size: var(--step-0);
  line-height: 1.6;
  color: var(--text-secondary);
  max-width: 560px;
}

/* masked line reveals — split headlines rise out of their own masks */
h2 .w { display: inline-block; }
h2 .w-br { display: block; width: 0; height: 0; }
.tl {
  display: block;
  overflow: hidden;
  padding-bottom: 0.12em; /* descenders survive the mask */
  margin-bottom: -0.12em;
}
.tl-in {
  display: block;
  transform: translateY(115%);
  transition: transform 0.9s cubic-bezier(0.19, 1, 0.22, 1);
  transition-delay: calc(var(--i, 0) * 90ms);
}
h2.is-inview .tl-in { transform: none; }
@media (prefers-reduced-motion: reduce) {
  .tl-in { transition: none; transform: none; }
}

.section-head--center { text-align: center; }
.section-head--center h2,
.section-head--center .lede { margin-inline: auto; }

/* ghost section numerals — retired */


/* ---------- method (sticky scene) ---------- */
.method { display: grid; grid-template-columns: 1fr; gap: 56px; }
.method__right { display: flex; flex-direction: column; gap: 48px; }
@media (min-width: 1024px) {
  .method { grid-template-columns: 5fr 7fr; gap: 80px; }
  .method__left { position: sticky; top: 128px; align-self: start; }
  .method__right {
    display: flex;
    flex-direction: column;
    gap: clamp(80px, 11vh, 132px);
    position: relative;
    padding-left: 36px;
    padding-block: 8px;
  }
}
.method__progress { display: none; }
@media (min-width: 1024px) {
  .method__progress {
    display: block;
    position: absolute;
    left: 0;
    top: 8px;
    bottom: 8px;
    width: 1px;
    background: var(--border);
  }
  .method__progress-fill {
    width: 100%;
    height: 0;
    background: var(--ink);
    transition: height 0.15s linear;
  }
}

.step__index {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-bottom: 24px;
  transition: color 0.4s ease;
}
.step__title {
  font-size: 19px;
  font-weight: 600;
  letter-spacing: 0;
  margin-bottom: 12px;
}
.step__desc { font-size: 14px; line-height: 1.55; color: var(--text-secondary); }

@media (min-width: 1024px) {
  .step-v { opacity: 0.3; transform: translateX(0); transition: opacity 0.5s ease; }
  .step-v.is-active { opacity: 1; }
  .step-v.is-active .step__index { color: var(--ink); }
  .step-v .step__title { font-size: 24px; }
  .step-v .step__desc { font-size: 15px; max-width: 46ch; }
}

/* ---------- stats band ---------- */
.stats-section {
  border-top: 1px solid var(--border);
  background-image: radial-gradient(circle, color-mix(in srgb, var(--ink) 4%, transparent) 1px, transparent 1px);
  background-size: 26px 26px;
  background-position: center;
}
.stats-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 40px; }
@media (min-width: 640px) { .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px; } }
@media (min-width: 1024px) { .stats-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 40px; } }
.stat { min-width: 0; }
.stat__label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-bottom: 16px;
}
.stat__value {
  font-size: 40px;
  font-weight: 600;
  letter-spacing: 0;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  white-space: normal;
  overflow-wrap: normal;
}
.stat__value em {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-style: normal;
  font-weight: 400;
  font-size: 0.38em;
  letter-spacing: 0;
  margin-left: 0.24em;
  color: var(--text-secondary);
}
.stat__desc { margin-top: 12px; font-size: 13px; line-height: 1.5; color: var(--text-secondary); }
@media (min-width: 640px) { .stat__value { font-size: 44px; } }
@media (min-width: 1024px) { .stat__value { font-size: 48px; } }
@media (max-width: 480px) {
  .stat__value { font-size: 32px; }
}

/* ---------- bento ---------- */
.bento {
  margin-top: 64px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}
@media (min-width: 700px) { .bento { grid-template-columns: repeat(2, 1fr); } }
.bento__cell { background: var(--bg); padding: 32px 28px; transition: opacity 0.3s ease; }
.bento__fig {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-bottom: 40px;
}
.bento__cell h3 { font-size: 17px; letter-spacing: 0; margin-bottom: 10px; }
.bento__cell p:last-child { font-size: 14px; line-height: 1.6; color: var(--text-muted); max-width: 34ch; }
.bento:hover .bento__cell:not(:hover) { opacity: 0.55; }

/* ---------- ask gallery ---------- */
.ask-grid {
  margin-top: 56px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}
[data-desktop-download][hidden] { display: none !important; }
@media (min-width: 768px) { .ask-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; } }
.ask-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
  padding: 26px 24px;
  text-align: left;
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  transition: border-color 0.25s ease, transform 0.35s var(--ease-out), box-shadow 0.35s ease;
}
.ask-card:hover { border-color: var(--text-faint); transform: translateY(-2px); box-shadow: var(--shadow-card); }
.ask-card__tag {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-faint);
}
.ask-card__q { font-size: 16px; line-height: 1.5; color: var(--ink); letter-spacing: 0; }
.ask-card__cta {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  transition: color 0.2s ease;
}
.ask-card:hover .ask-card__cta { color: var(--ink); }
/* Informational cards (and the post-install state) — no pointer, no lift. */
.ask-card--static { cursor: default; }
.ask-card--static:hover { border-color: var(--border); transform: none; box-shadow: none; }
.ask-card--static:hover .ask-card__cta { color: var(--text-muted); }
.apps__note {
  margin-top: 18px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-muted);
  max-width: 560px;
}
@media (min-width: 1000px) { .bento { grid-template-columns: repeat(3, 1fr); } }

.cell {
  background: var(--bg-elev);
  padding: 32px 28px;
  display: flex;
  flex-direction: column;
  transition: background-color 0.2s ease;
}
.cell:hover { background: var(--surface); }
@media (min-width: 1000px) {
  .cell--wide { grid-column: span 2; }
  .cell--full { grid-column: span 3; }
}
@media (min-width: 700px) and (max-width: 999px) {
  .cell--wide, .cell--full { grid-column: span 2; }
}

.cell__title {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0;
  margin-bottom: 8px;
}
.cell__desc {
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-secondary);
  max-width: 52ch;
}
.cell > .cell__desc { margin-bottom: 24px; }

/* widget: erase (zero retention) */
.widget-erase {
  margin-top: auto;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.erase-row { display: flex; align-items: center; gap: 10px; }
.erase-bar {
  height: 10px;
  width: var(--w);
  border-radius: 999px;
  background: var(--border);
  animation: eraseAway 7s var(--ease-out) infinite;
  animation-delay: var(--d);
}
.erase-x {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 11px;
  color: var(--text-faint);
}
.erase-note {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-top: 4px;
  animation: noteFlash 7s ease infinite;
}
@keyframes eraseAway {
  0%, 30% { width: var(--w); opacity: 1; }
  45%, 88% { width: 0; opacity: 0.25; }
  100% { width: var(--w); opacity: 1; }
}
@keyframes noteFlash {
  0%, 40% { opacity: 0; }
  50%, 85% { opacity: 1; color: var(--live); }
  100% { opacity: 0; }
}

/* widget: citation chips */
.widget-chips { margin-top: auto; display: flex; flex-wrap: wrap; gap: 6px; }

/* widget: latency equalizer */
.widget-eq {
  margin-top: auto;
  display: flex;
  align-items: flex-end;
  gap: 5px;
  height: 44px;
}
.widget-eq i {
  flex: 1;
  border-radius: 2px 2px 0 0;
  background: var(--ink);
  opacity: 0.85;
  animation: eqBar 1.3s ease-in-out infinite;
  transform-origin: bottom;
}
.widget-eq i:nth-child(1) { height: 35%; animation-delay: 0s; }
.widget-eq i:nth-child(2) { height: 60%; animation-delay: 0.12s; }
.widget-eq i:nth-child(3) { height: 45%; animation-delay: 0.24s; }
.widget-eq i:nth-child(4) { height: 90%; animation-delay: 0.06s; }
.widget-eq i:nth-child(5) { height: 55%; animation-delay: 0.3s; }
.widget-eq i:nth-child(6) { height: 70%; animation-delay: 0.18s; }
.widget-eq i:nth-child(7) { height: 40%; animation-delay: 0.36s; }
@keyframes eqBar {
  0%, 100% { transform: scaleY(0.5); }
  50% { transform: scaleY(1); }
}
.widget-note {
  margin-top: 10px;
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-faint);
}

/* widget: model carousel */
.widget-models {
  margin-top: auto;
  height: 34px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  padding: 6px 14px;
}
.widget-models ul {
  list-style: none;
  animation: modelCycle 6s var(--ease-out) infinite;
}
.widget-models li {
  height: 22px;
  line-height: 22px;
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--text-secondary);
  white-space: nowrap;
}
@keyframes modelCycle {
  0%, 28% { transform: translateY(0); }
  33%, 61% { transform: translateY(-22px); }
  66%, 94% { transform: translateY(-44px); }
  100% { transform: translateY(0); }
}

/* widget: export terminal */
.widget-export {
  margin-top: auto;
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 12px;
  color: var(--text-secondary);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 16px;
  overflow-x: auto;
  white-space: nowrap;
}
.caret-blink {
  display: inline-block;
  width: 7px;
  height: 13px;
  margin-left: 4px;
  vertical-align: -2px;
  background: var(--ink);
  animation: caret 0.9s steps(1) infinite;
}

/* widget: keyboard */
.widget-kbd {
  margin-top: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
}
.kbd-group { display: inline-flex; align-items: center; gap: 6px; }
.kbd-group kbd {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 12px;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--border);
  border-bottom-width: 2px;
  border-radius: 7px;
  padding: 4px 8px;
  min-width: 28px;
  text-align: center;
}
.kbd-label {
  font-size: 11px;
  color: var(--text-faint);
  margin-left: 6px;
}

/* ---------- volumetric specimen ---------- */
.specimen { }
.specimen__inner { display: flex; flex-direction: column; }
.specimen__stage {
  position: relative;
  margin: 8px auto 0;
  width: min(680px, 100%);
  height: clamp(400px, 40vw, 520px);
}
.specimen__stage canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.specimen__fallback {
  position: absolute;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  opacity: 0.85;
}
.specimen__fallback.is-on { display: flex; }
.specimen__stage .stage-note { bottom: -28px; }

/* ---------- pull quote ---------- */
.quote-band {
  position: relative;
  overflow: clip;
  border-top: 1px solid var(--border);
  background: var(--surface);
  padding-block: 104px;
}
/* living moiré — two offset concentric ring fields interfering */
.quote-band::before {
  content: "";
  position: absolute;
  inset: -4%;
  background-image:
    repeating-radial-gradient(circle at 50% 50%, transparent 0 5px, color-mix(in srgb, var(--ink) 6%, transparent) 5px 5.6px, transparent 5.6px 6.2px),
    repeating-radial-gradient(circle at 50.35% 50%, transparent 0 5px, color-mix(in srgb, var(--ink) 4.5%, transparent) 5px 5.6px, transparent 5.6px 6.2px);
  pointer-events: none;
  animation: moireDrift 46s ease-in-out infinite alternate;
}
@keyframes moireDrift {
  from { transform: rotate(-1.1deg) scale(1); }
  to { transform: rotate(1.1deg) scale(1.06); }
}
.quote-band .container { position: relative; }
@media (min-width: 640px) { .quote-band { padding-block: 136px; } }
.pullquote { text-align: center; }
.pullquote blockquote p {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-style: normal;
  font-weight: 500;
  font-size: 36px;
  line-height: 1.12;
  letter-spacing: 0;
  color: var(--ink);
  max-width: 24ch;
  margin-inline: auto;
}
@media (min-width: 640px) { .pullquote blockquote p { font-size: 52px; } }
@media (min-width: 1024px) { .pullquote blockquote p { font-size: 74px; } }

.pullquote blockquote em { color: var(--text-secondary); }
.pullquote figcaption {
  margin-top: 32px;
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* field notes strip */
.notes {
  margin-top: 72px;
  display: flex;
  gap: 16px;
  overflow-x: auto;
  scroll-snap-type: x proximity;
  padding-bottom: 8px;
  cursor: grab;
  scrollbar-width: none;
}
.notes::-webkit-scrollbar { display: none; }
.notes.is-drag { cursor: grabbing; scroll-snap-type: none; }
.note {
  flex: 0 0 auto;
  width: min(420px, 82vw);
  scroll-snap-align: start;
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px 28px;
  transition: transform 0.3s var(--ease-out), border-color 0.2s ease;
}
.note:hover { transform: translateY(-3px); border-color: var(--text-faint); }
.note__no {
  display: inline-block;
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  color: var(--text-faint);
  margin-bottom: 20px;
}
.note p {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-style: normal;
  font-size: 23px;
  line-height: 1.3;
  letter-spacing: 0;
  color: var(--ink);
}
.note p em { color: var(--text-secondary); }
.note--ghost { background: transparent; border-style: dashed; }
.note--ghost p { color: var(--text-faint); }
.note--ghost p em { color: var(--text-faint); }

/* ---------- comparison table ---------- */
.compare {
  margin-top: 64px;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow-x: auto;
  background: var(--bg-elev);
}
.compare__table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  font-size: 14px;
}
.compare__table thead th {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
  text-align: left;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}
.compare__brand { color: var(--ink) !important; }
.compare__brand svg { display: inline-block; vertical-align: -3px; margin-right: 6px; }
.compare__table tbody th {
  text-align: left;
  font-weight: 600;
  color: var(--ink);
  padding: 18px 24px;
  border-bottom: 1px solid var(--border);
  letter-spacing: 0;
  white-space: nowrap;
}
.compare__table tbody td {
  padding: 18px 24px;
  border-bottom: 1px solid var(--border);
  color: var(--ink);
}
.compare__table tbody tr:last-child th,
.compare__table tbody tr:last-child td { border-bottom: none; }
.compare__table tbody tr { transition: background-color 0.15s ease; }
.compare__table tbody tr:hover { background: var(--surface); }
.compare__muted { color: var(--text-faint); }
@media (max-width: 640px) {
  /* full-bleed on phones — a half-cut rounded card reads as broken */
  .compare { margin-inline: -24px; border-inline: none; border-radius: 0; }
  .compare__table { min-width: 0; font-size: 13px; }
  .compare__table thead th,
  .compare__table tbody th,
  .compare__table tbody td { padding: 14px 16px; }
  .compare__table tbody th { white-space: normal; }
}

/* ---------- FAQ ---------- */
.faq { margin-top: 56px; border-top: 1px solid var(--border); }
.faq__item { border-bottom: 1px solid var(--border); }
.faq__item summary {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 24px 4px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0;
  transition: color 0.15s ease;
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary:hover { color: var(--text-secondary); }
.faq__icon {
  position: relative;
  width: 28px;
  height: 28px;
  border: 1px solid var(--border);
  border-radius: 999px;
  flex-shrink: 0;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.3s var(--ease-out);
}
.faq__icon::before,
.faq__icon::after {
  content: "";
  position: absolute;
  top: 50%; left: 50%;
  width: 10px;
  height: 1.5px;
  background: var(--ink);
  transform: translate(-50%, -50%);
  transition: transform 0.3s var(--ease-out), background-color 0.2s ease;
}
.faq__icon::after { transform: translate(-50%, -50%) rotate(90deg); }
.faq__item[open] .faq__icon {
  background: var(--btn-bg);
  border-color: var(--btn-bg);
  transform: rotate(45deg);
}
.faq__item[open] .faq__icon::before,
.faq__item[open] .faq__icon::after { background: var(--btn-fg); }
.faq__item > p {
  padding: 0 4px 24px;
  max-width: 640px;
  font-size: 14px;
  line-height: 1.65;
  color: var(--text-secondary);
  animation: faqIn 0.4s var(--ease-out);
}
@keyframes faqIn {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: none; }
}

/* ---------- text-mode specimen ---------- */
.textmode {
  border-top: 1px solid var(--border);
  padding-block: 96px 104px;
}
.textmode__frame {
  position: relative;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg-elev);
  padding: 40px 24px 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.textmode__frame pre {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 11px;
  line-height: 1.05;
  letter-spacing: 0.04em;
  color: var(--ink);
  white-space: pre;
  user-select: none;
  opacity: 0.9;
}
.textmode__frame .stage-note { bottom: 18px; }

/* ---------- dark CTA band ---------- */
.dark-band {
  position: relative;
  overflow: hidden;
  background: #100F0C;
  color: #F2EFE7;
  border-top: 1px solid var(--border);
  padding-block: 80px;
}
html.dark .dark-band { background: #171512; border-top-color: #35312A; }
@media (min-width: 640px) { .dark-band { padding-block: 104px; } }
.dark-band .container { position: relative; }
.dark-band .eyebrow { color: rgba(242, 239, 231, 0.62); }
.dark-band .eyebrow::after { background: #4A463C; }
.dark-band h2 { color: #F2EFE7; }
.dark-band h2 em { color: rgba(242, 239, 231, 0.55); }
.dark-band p.lede {
  margin-top: 20px;
  font-size: 16px;
  line-height: 1.6;
  color: rgba(242, 239, 231, 0.6);
  max-width: 520px;
}
.dark-band__grid { display: grid; grid-template-columns: 1fr; gap: 64px; align-items: center; }
@media (min-width: 1024px) { .dark-band__grid { grid-template-columns: 1.1fr 0.9fr; gap: 80px; } }
.dark-band__stage {
  position: relative;
  height: clamp(340px, 40vw, 540px);
  border: 1px solid #262626;
  border-radius: 8px;
  background: radial-gradient(80% 80% at 50% 40%, #101010 0%, #060606 100%);
  overflow: hidden;
}
.dark-band__stage::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(45% 45% at 50% 45%, rgba(242, 239, 231, 0.05), transparent 70%);
  pointer-events: none;
}
.dark-band__stage.is-bloom { background: #0B0A08; }
.dark-band__stage.is-bloom::before { display: none; }
.dark-band__stage canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  cursor: grab;
  touch-action: none;
}
.dark-band__stage canvas:active { cursor: grabbing; }
.dark-band .stage-note { color: rgba(242, 239, 231, 0.62); }
.dark-band__actions { margin-top: 40px; display: flex; flex-direction: column; gap: 12px; }
@media (min-width: 640px) { .dark-band__actions { flex-direction: row; } }
.btn-white {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 56px;
  padding-inline: 28px;
  border-radius: 999px;
  background: #FBFAF6;
  color: #0a0a0a;
  font-size: 15px;
  font-weight: 500;
  transition: background-color 0.15s ease, transform 0.2s var(--ease-out);
  will-change: transform;
}
.btn-white:hover { background: #F2EFE7; }
.btn-white::after {
  background: linear-gradient(105deg, transparent, rgba(10, 10, 10, 0.09), transparent);
}
.btn-outline-dark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 56px;
  padding-inline: 28px;
  border-radius: 999px;
  border: 1px solid #404040;
  color: #fff;
  font-size: 15px;
  font-weight: 500;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}
.btn-outline-dark:hover { border-color: #F2EFE7; background: rgba(242, 239, 231, 0.05); }
.dark-band__note {
  margin-top: 24px;
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(242, 239, 231, 0.62);
}

/* ---------- footer ---------- */
.footer {
  background: var(--bg);
  border-top: 1px solid var(--border);
  overflow: hidden;
}
.footer__inner { padding-block: 56px 24px; }
.footer__top { display: flex; flex-direction: column; gap: 40px; margin-bottom: 48px; }
@media (min-width: 768px) { .footer__top { flex-direction: row; justify-content: space-between; } }
.footer__brand p {
  margin-top: 16px;
  font-size: 12px;
  line-height: 1.6;
  color: var(--text-faint);
  max-width: 320px;
}
.footer__status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.footer__cols { display: grid; grid-template-columns: minmax(0, 1fr); gap: 32px; }
@media (min-width: 440px) { .footer__cols { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px; } }
.footer__col-title {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin-bottom: 16px;
}
.footer__col ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer__col a { font-size: 12px; color: var(--text-secondary); transition: color 0.15s ease; }
.footer__col a:hover { color: var(--ink); }
.footer__legal {
  padding-top: 24px;
  border-top: 1px solid var(--border);
  font-size: 11px;
  line-height: 1.6;
  color: var(--text-faint);
  display: flex;
  flex-direction: column;
  gap: 8px;
}
@media (min-width: 640px) {
  .footer__legal { flex-direction: row; justify-content: space-between; align-items: center; }
}

/* giant wordmark — the wireframe lives inside the letterforms */
.footer-giant {
  position: relative;
  height: clamp(170px, 21vw, 310px);
  margin-top: 24px;
  user-select: none;
}
.footer-giant canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
/* ---------- footer as a fixed slab the page lifts off of (armed with the choreography) ---------- */
html.fx #page { position: relative; z-index: 2; background: var(--bg); }
html.fx .footer { position: fixed; bottom: 0; left: 0; width: 100%; z-index: 1; }
/* JS adds footer-flow whenever the footer is taller than the viewport — the
   slab would hang above the top edge, unreachable — and the footer returns
   to normal document flow instead. */
html.fx.footer-flow .footer { position: static; }
/* The renderer can measure a footer even when optional scroll choreography is
   unavailable. Without the fixed slab, that inline reserve is an empty page. */
html:not(.fx) #page { margin-bottom: 0 !important; }

.footer__colophon {
  margin-top: 20px;
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-faint);
}

/* GSAP-orchestrated entrance: CSS anims stand down when JS takes over.
   opacity/transform/filter stay non-important so gsap's inline styles win. */
html.js-gsap .anim,
html.js-gsap h1 .ch {
  animation: none !important;
  opacity: 0;
  filter: none;
  transform: none;
}

/* Deterministic settle: once the intro has finished (or provably cannot run),
   JS adds js-settled and every entrance-hidden element becomes visible.
   Non-important so gsap/ScrollTrigger inline styles still win. */
html.js-settled .anim,
html.js-settled h1 .ch,
html.js-settled h1 .line > span {
  animation: none;
  opacity: 1;
  transform: none;
  filter: none;
}

/* Content remains readable independent of scroll position or animation state. */
.reveal {
  opacity: 1;
  transform: none;
  transition: none;
}
.reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .anim { opacity: 1; transform: none; animation: none; filter: none; }
  h1 .line > span { transform: none; animation: none; }
  h1 .ch { transform: none; animation: none; }
  .status-dot, .is-thinking .msg__bubble::before { animation: none; }
  .quote-band::before { animation: none; }
  .msg__bubble.is-typing span::after { animation: none; }
  .progress__bar, .method__progress-fill { transition: none; }
  .step-v { opacity: 1; }
  .magnetic, .btn-primary, .btn-pill, .btn-white, .chat-card__send { transform: none !important; }
  .loader { display: none; }
  .pullquote .w { opacity: 1; }
  .pullquote blockquote p { animation: none !important; }
  .btn-primary::after, .btn-white::after { display: none; }
}

/* ---------- preloader ---------- */
html.is-loading, html.is-loading body { overflow: hidden; }
.loader {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  clip-path: inset(0 0 0 0); /* the sheet lifts via clip, hairline edge riding up */
  border-bottom: 1px solid var(--text-muted);
}
.loader__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}
.loader__stage {
  position: relative;
  width: 220px;
  height: 220px;
}
.loader__stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.loader__meta {
  display: flex;
  align-items: center;
  gap: 14px;
}
.loader__count {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
  min-width: 3ch;
  text-align: right;
}
.loader__track {
  width: 120px;
  height: 2px;
  border-radius: 2px;
  background: var(--border);
  overflow: hidden;
  position: relative;
}
.loader__bar {
  position: absolute;
  inset: 0;
  border-radius: 2px;
  background: var(--ink);
  transform-origin: left center;
  transform: scaleX(0);
}

/* ---------- film grain ---------- */
.grain {
  position: fixed;
  inset: 0;
  z-index: 90;
  pointer-events: none;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='240' height='240' filter='url(%23n)' opacity='0.55'/%3E%3C/svg%3E");
  background-size: 240px 240px;
  animation: grainShift 0.8s steps(1) infinite;
}
/* ambient colony layer — under the grain, above everything else */
.atmo {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}
/* living field — reaction-diffusion lichen growing under the colony */
.lichen {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 2.4s ease;
}
.lichen.is-live { opacity: 1; }
html.audit .lichen { transition: none; }
@keyframes grainShift {
  0% { background-position: 0 0; }
  16% { background-position: -62px 34px; }
  33% { background-position: 44px -52px; }
  50% { background-position: -30px -24px; }
  66% { background-position: 54px 42px; }
  83% { background-position: -44px 12px; }
  100% { background-position: 0 0; }
}
@media (prefers-reduced-motion: reduce) {
  .grain { animation: none; }
}

/* ---------- sheet-stack — each sheet is opaque with a hairline seam ---------- */
#product, #how, #privacy {
  position: relative;
  background: var(--bg);
  border-top: 1px solid var(--border);
}

/* ---------- lenis recommended rules ---------- */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-stopped { overflow: clip; }

/* ---------- control ledger ---------- */
.proof {
  list-style: none;
  max-width: 520px;
  margin: 44px auto 0;
  padding: 0 24px;
  text-align: left;
}
.proof li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 24px;
  padding: 13px 2px;
  border-top: 1px solid var(--border);
  font-size: 14px;
}
.proof li:last-child { border-bottom: 1px solid var(--border); }
.proof li span:last-child {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-faint);
  white-space: nowrap;
}

/* ---------- link grammar — hairline sweep ---------- */
.nav__link,
.footer__col a,
.mobile-menu nav a {
  background-image: linear-gradient(currentColor, currentColor);
  background-size: 0% 1px;
  background-repeat: no-repeat;
  background-position: left 100%;
  transition: background-size 0.45s var(--ease-out);
  padding-bottom: 2px;
}
.nav__link:hover,
.footer__col a:hover,
.mobile-menu nav a:hover { background-size: 100% 1px; }

/* CTA arrows lean into the promise */
.btn-primary svg, .btn-white svg, .btn-pill svg {
  transition: transform 0.35s var(--ease-out);
}
.btn-primary:hover svg, .btn-white:hover svg, .btn-pill:hover svg { transform: translateX(3px); }

/* ---------- no-JS: nothing stays hidden ---------- */
html.no-js .reveal,
html.no-js .anim { opacity: 1 !important; transform: none !important; animation: none !important; }
html.no-js h1 .ch { transform: none !important; animation: none !important; }
html.no-js .loader { display: none; }

/* ---------- inputs: caret matches the ink ---------- */
.field, .chat-card__input, #palette-input { caret-color: var(--ink); }

/* ---------- print: omit interactive and decorative elements ---------- */
@media print {
  .nav, .grain, .loader, .progress, .palette, .toast,
  .hero__spores, .mobile-menu, .atmo, .lichen { display: none !important; }
  .hero__stage, .specimen__stage, .dark-band__stage, .footer-giant { display: none !important; }
  html, body { background: #fff; color: #000; }
  .hero { min-height: 0; }
  .section, .dark-band { break-inside: avoid; }
  .dark-band { background: #fff; color: #000; border: 1px solid #000; }
  a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 10px; color: #555; }
}

/* ---------- audit mode — deterministic end-states for static captures ---------- */
html.audit *,
html.audit *::before,
html.audit *::after {
  animation-duration: 0s !important;
  animation-delay: 0s !important;
  transition-duration: 0s !important;
  transition-delay: 0s !important;
}
/* collapse viewport-height sections so a tall window captures the whole page */
html.audit .hero { height: auto !important; min-height: 0 !important; }
@media (min-width: 900px) {
  html.audit .hero { height: 836px !important; }
}
html.audit .section,
html.audit .dark-band { min-height: 0 !important; }
html.dark .grain { opacity: 0.07; }

/* ---------- spotlight card borders ---------- */
.spot { position: relative; }
.spot::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  padding: 1px;
  background: radial-gradient(
    260px circle at var(--mx, 50%) var(--my, 50%),
    color-mix(in srgb, var(--ink) 45%, transparent),
    transparent 70%
  );
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.35s ease;
  pointer-events: none;
  z-index: 2;
}
.spot:hover::before { opacity: 1; }

/* ---------- product surface (app window) ---------- */
.section--flush { border-top: 1px solid var(--border); padding-top: 20px; }
@media (min-width: 640px) { .section--flush { padding-bottom: 64px; } }
.app-wrap {
  max-width: 1140px;
  margin: 64px auto 0;
  padding-inline: max(24px, var(--safe-area-left)) max(24px, var(--safe-area-right));
}
@media (min-width: 640px) {
  .app-wrap {
    padding-inline: max(32px, var(--safe-area-left)) max(32px, var(--safe-area-right));
  }
}
.app {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: var(--shadow-card);
  overflow: hidden;
  will-change: transform, opacity;
}
.app__bar {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}
.app__mark { display: inline-flex; }
.app__title {
  flex: 1;
  min-width: 0;
  text-align: center;
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.app__key { display: inline-flex; gap: 4px; }
.app__key kbd {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 10px;
  color: var(--text-muted);
  border: 1px solid var(--border);
  border-bottom-width: 2px;
  border-radius: 6px;
  padding: 2px 6px;
  background: var(--bg-elev);
}
.app__shell { display: grid; grid-template-columns: 1fr; }
@media (min-width: 900px) { .app__shell { grid-template-columns: 250px 1fr; } }
.app__side {
  display: none;
  flex-direction: column;
  border-right: 1px solid var(--border);
  background: var(--surface);
  padding: 18px 12px;
  min-height: 340px;
}
@media (min-width: 900px) { .app__side { display: flex; } }
.app__side-title {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-faint);
  padding: 0 10px;
  margin-bottom: 12px;
}
.app__thread {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 9px 10px;
  border-radius: 9px;
}
.app__thread.is-active { background: var(--surface-press); }
.app__thread.is-active .app__thread-name {
  color: var(--ink);
  font-weight: 600;
}
.app__thread-name {
  font-size: 12.5px;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.app__thread-meta {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 10px;
  color: var(--text-faint);
  flex-shrink: 0;
}
.app__side-foot {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px;
  border-top: 1px solid var(--border);
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}
/* ---------- specimen stages ---------- */
.specimen-stage {
  position: relative;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  background: radial-gradient(80% 80% at 50% 40%, var(--surface) 0%, var(--bg) 100%);
}
.specimen-stage::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(45% 45% at 50% 45%, var(--tint) 0%, transparent 70%);
  opacity: 0.7;
  pointer-events: none;
}
.specimen-stage canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  cursor: grab;
  touch-action: none;
}
.specimen-stage canvas:active { cursor: grabbing; }
.stage-note {
  position: absolute;
  bottom: 16px;
  left: 0;
  right: 0;
  text-align: center;
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
  pointer-events: none;
}
html.dark .specimen-stage {
  background: radial-gradient(80% 80% at 50% 40%, #101010 0%, var(--bg) 100%);
}
html.dark .specimen-stage::before {
  background: radial-gradient(45% 45% at 50% 45%, rgba(242, 239, 231, 0.05), transparent 70%);
}

/* the cross-section floats — no contact shadow, it stood on nothing */
.specimen__stage canvas { z-index: 1; }

.app__main {
  padding: 28px 20px;
  display: flex;
  flex-direction: column;
  min-width: 0;
}
@media (min-width: 640px) { .app__main { padding: 36px 32px; } }
.app__view {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 20px;
  max-width: 640px;
  min-height: 300px;
  max-height: 520px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
  padding-right: 4px;
}
.app__composer {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 24px;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
}
.app__composer:focus-within {
  border-color: var(--ink);
  box-shadow: 0 0 0 4px var(--focus-ring);
}

/* ---------- quote word scrub ---------- */
.pullquote .w {
  opacity: 1;
}
.pullquote .w.on { opacity: 1; }

/* ---------- footer clock ---------- */
.footer__clock {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 10px;
  letter-spacing: 0.12em;
}

/* ---------- mobile menu ---------- */
.menu-btn {
  display: none;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  align-items: center;
  justify-content: center;
  color: var(--ink);
  transition: background-color 0.15s ease;
}
.menu-btn:hover { background: var(--surface-press); }
@media (max-width: 900px) { .menu-btn { display: inline-flex; } }
.mobile-menu {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 39;
  background: var(--bg);
  backdrop-filter: blur(18px) saturate(1.5);
  -webkit-backdrop-filter: blur(18px) saturate(1.5);
  border-bottom: 1px solid var(--border);
  padding: 12px max(24px, var(--safe-area-right)) max(20px, var(--safe-area-bottom)) max(24px, var(--safe-area-left));
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity 0.25s ease, transform 0.25s var(--ease-out);
}
.mobile-menu[hidden] { display: none; }
.mobile-menu.is-open { opacity: 1; transform: none; }
.mobile-menu nav { display: flex; flex-direction: column; }
.mobile-menu a {
  display: block;
  padding: 14px 4px;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: 0;
  border-bottom: 1px solid var(--border);
}
.mobile-menu a:last-child { border-bottom: none; }
.mobile-menu__cta { color: var(--text-secondary); }

/* ---------- command palette ---------- */
.palette {
  position: fixed;
  inset: 0;
  z-index: 150;
}
.palette[hidden] { display: none; }
.palette__backdrop {
  position: absolute;
  inset: 0;
  background: color-mix(in srgb, var(--bg) 55%, transparent);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.palette__panel {
  position: absolute;
  top: 18%;
  left: 50%;
  transform: translateX(-50%);
  width: min(560px, calc(100vw - 32px));
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.25);
  overflow: hidden;
  overscroll-behavior: contain;
  animation: paletteIn 0.22s var(--ease-out);
}
@keyframes paletteIn {
  from { opacity: 0; transform: translateX(-50%) translateY(-8px) scale(0.985); }
  to { opacity: 1; transform: translateX(-50%) translateY(0) scale(1); }
}
.palette__head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--border);
  color: var(--text-faint);
}
.palette__head:focus-within {
  border-bottom-color: var(--ink);
  box-shadow: inset 0 -2px 0 var(--focus-ring);
}
.palette__head input {
  flex: 1;
  border: none;
  background: transparent;
  outline: none;
  font-size: 15px;
  color: var(--ink);
  height: 28px;
}
.palette__close {
  display: inline-flex;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  color: var(--text-muted);
}
.palette__close:hover { background: var(--surface-press); color: var(--ink); }
.palette__head input::placeholder { color: var(--text-faint); }
.palette__head kbd {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 10px;
  color: var(--text-muted);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 3px 6px;
}
.palette__list {
  list-style: none;
  max-height: 320px;
  overflow-y: auto;
  padding: 8px;
}
.palette__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 11px 12px;
  border-radius: 8px;
  font-size: 14px;
  color: var(--ink);
  cursor: pointer;
}
.palette__item.is-active { background: var(--surface-press); }
.palette__hint {
  font-family: "Geist", -apple-system, "Segoe UI", sans-serif;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-faint);
}
.palette__empty {
  padding: 20px 12px;
  font-size: 13px;
  color: var(--text-faint);
  text-align: center;
}

/* ---------- toast ---------- */
.toast {
  position: fixed;
  bottom: max(28px, var(--safe-area-bottom));
  left: 50%;
  transform: translate(-50%, 12px);
  z-index: 160;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-size: 13px;
  font-weight: 500;
  padding: 11px 20px;
  border-radius: 999px;
  box-shadow: var(--shadow-btn);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s var(--ease-out);
}
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* ---------- theme view transition — the wipe itself is driven by WAAPI from JS ---------- */
::view-transition-old(root), ::view-transition-new(root) {
  animation: none;
  mix-blend-mode: normal;
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  ::view-transition-old(root), ::view-transition-new(root) { animation: none !important; }
}

/* focus visibility */
:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
  border-radius: 4px;
}

@media (pointer: coarse) {
  :where(
    a[href],
    button,
    input:not([type="hidden"]):not([type="checkbox"]):not([type="radio"]),
    select,
    textarea,
    summary,
    [role="button"],
    [role="option"]
  ) {
    min-block-size: var(--touch-target);
    min-inline-size: var(--touch-target);
  }
}

@media (pointer: coarse) and (max-width: 767px) {
  input,
  select,
  textarea {
    font-size: 16px;
  }
}

@media (forced-colors: active) {
  :focus-visible { outline-color: Highlight; }
  .palette__panel { border: 1px solid CanvasText; }
}

/* ---------- green accent layer ----------
   Green is spent on the two things it was asked for -- the buttons and the
   logo mark -- and both come from --btn-bg in the tokens above, not from
   here. What is left in this block is the two places green is carrying
   meaning rather than decoration: a presence dot, which is a status colour,
   and the selected channel, which is a filled control.

   Deliberately NOT here: the section eyebrows, the scroll progress bar, the
   step indices and the active nav link. Tinting those was the greener pass
   that went with the other palette; over bone it spends the accent on
   furniture and costs the restraint that makes this design read as paper.
   Each is one line if any of them is wanted back. */

/* the presence dot is the one place a status colour is the content --
   --live had been declared since the first commit and never once painted */
.status-dot {
  background: var(--live);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--live) 18%, transparent);
}

/* the selected channel, the way a channel list reads it */
.app__thread.is-active {
  background: var(--btn-bg);
}
.app__thread.is-active .app__thread-name,
.app__thread.is-active .app__thread-meta {
  color: var(--btn-fg);
}
.app__thread.is-active .app__thread-meta {
  opacity: 0.72;
}

@media (prefers-contrast: more) {
  .status-dot { box-shadow: none; }
}


/* ---------- liquid glass surfaces ----------------------------------------- */
/* Translucent panels that refract the living background: blur + saturate,
   a top specular highlight, and a hairline inner border. Motion-safe only
   effects stay cheap; blur is the whole effect and runs on the compositor. */
.hero__form input[type="email"],
.hero__form input[type="text"] {
  background: color-mix(in srgb, var(--btn-bg) 6%, transparent);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  border: 1px solid color-mix(in srgb, var(--btn-bg) 14%, transparent);
  box-shadow:
    inset 0 1px 0 color-mix(in srgb, #fff 55%, transparent),
    0 8px 32px color-mix(in srgb, var(--btn-bg) 10%, transparent);
}
.btn-primary,
.hero__form .btn-primary {
  position: relative;
  backdrop-filter: blur(10px) saturate(1.3);
  -webkit-backdrop-filter: blur(10px) saturate(1.3);
  box-shadow:
    inset 0 1px 0 color-mix(in srgb, #fff 35%, transparent),
    0 10px 30px color-mix(in srgb, var(--btn-bg) 22%, transparent);
  transition: transform .35s cubic-bezier(.16,1,.3,1), box-shadow .35s cubic-bezier(.16,1,.3,1);
}
.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow:
    inset 0 1px 0 color-mix(in srgb, #fff 45%, transparent),
    0 14px 40px color-mix(in srgb, var(--btn-bg) 28%, transparent);
}
.btn-primary:active { transform: translateY(0) scale(.98); }
.ask-card {
  backdrop-filter: blur(12px) saturate(1.35);
  -webkit-backdrop-filter: blur(12px) saturate(1.35);
  box-shadow:
    inset 0 1px 0 color-mix(in srgb, #fff 50%, transparent),
    0 6px 24px color-mix(in srgb, var(--btn-bg) 8%, transparent);
  transition: transform .4s cubic-bezier(.16,1,.3,1), box-shadow .4s cubic-bezier(.16,1,.3,1);
}
.ask-card:hover {
  transform: translateY(-2px);
}
/* the nav pill gets a faint liquid edge on scroll-heavy backgrounds */
.nav__inner { border-radius: 999px; }
@media (prefers-reduced-motion: reduce) {
  .btn-primary, .btn-secondary, .ask-card { transition: none; }
}

/* ---------- glass sheen sweep (liquid glass signature) ---------------------- */
/* A registered custom property drives a specular streak that sweeps across
   glass buttons on hover — the "liquid" in liquid glass. One composited
   gradient, no extra DOM. */
@property --sheen { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
.btn-primary::after,
.hero__form .btn-primary::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(var(--sheen),
    transparent 0%,
    color-mix(in srgb, #fff 26%, transparent) 12%,
    transparent 26%);
  opacity: 0;
  transition: opacity .45s cubic-bezier(.16,1,.3,1);
  pointer-events: none;
}
.btn-primary:hover::after { --sheen: 140deg; opacity: 1; }
.btn-primary:active::after { --sheen: 180deg; }

/* focus ring: consistent liquid-glass halo */
.btn-primary:focus-visible,
.ask-card:focus-visible,
.hero__form input:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--btn-bg) 55%, transparent);
  outline-offset: 2px;
}

/* mobile: drop heavy backdrop-filters where they cost the most (small GPUs),
   the translucent fill alone still reads as glass */
@media (max-width: 767px) {
  .hero__form input[type="email"],
  .hero__form input[type="text"],
  .btn-primary,
  .ask-card { backdrop-filter: none; -webkit-backdrop-filter: none; }
}

/* mobile: never split words in display headlines */
@media (max-width: 700px) {
  h1 { word-break: normal; overflow-wrap: normal; }
  h1 .line { display: block; }
  h1 .line, h1 .line > span, h1 .line em, h2 .line {
    word-break: normal;
    overflow-wrap: normal;
  }
  .hero__copy h1 { font-size: 42px; }
}

@media (max-width: 600px) and (max-height: 650px) {
  .hero__inner { padding-block: 14px 2px; }
  .status-line { margin-bottom: 8px; }
  .hero__copy h1 { font-size: 34px; }
  .hero__sub { margin-top: 12px; font-size: 14px; line-height: 1.4; }
  .hero__form { margin-top: 12px; gap: 8px; }
  .hero__form .btn-primary,
  .hero__form .btn-secondary { height: 44px; min-height: 44px; }
  .hero__stage { height: 110px; margin-top: 2px; }
}

/* ---------- rendering performance & modern CSS ----------------------------- */
/* Every section participates in initial layout. Placeholder section heights
   made the document shrink during ordinary scrolling and left full-page
   captures with empty, background-only viewports. */
main > section { content-visibility: visible; contain-intrinsic-size: none; }
/* anchored sections clear the sticky nav on hash jumps */
section[id] { scroll-margin-top: 84px; }
/* text-wrap: balance headlines automatically */
h1, h2 { text-wrap: balance; }

/* ---------- mobile polish (audit round 1) ---------------------------------- */
a, button, [role="button"], summary {
  -webkit-tap-highlight-color: rgba(18, 107, 80, 0.12);
}
/* vertical swipes scroll the page; horizontal drags rotate the mark */
.hero__stage canvas { touch-action: pan-y; }
/* copy selectable again — was pointer-events:none wholesale */
.hero__copy { pointer-events: auto; user-select: text; }
.hero__copy .hero__form { pointer-events: none; }
.hero__copy .hero__form a,
.hero__copy .hero__form button,
.hero__copy .hero__form input { pointer-events: auto; }

/* decorative fixed layers off on small screens — invisible detail at
   0.05 opacity there, and the dominant mobile GPU cost */
@media (max-width: 767px) {
  .grain, .atmo, .lichen, .hero__spores, .dark-band__stage, .footer-giant { display: none; }
  .nav { backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
}

@media (pointer: coarse) {
  input, select, textarea { font-size: 16px !important; }
  #page { padding-bottom: env(safe-area-inset-bottom, 0px); }
}

/* ---------- progressive enhancements --------------------------------------- */
/* cross-document view transitions: morphs between pages, one rule */
@view-transition { navigation: auto; }
::view-transition-old(root) { animation-duration: .2s; }
::view-transition-new(root) { animation-duration: .3s; }

/* dark mode: the glass input needs more presence to balance the solid
   mint button — the pair was visually lopsided (weight off) */
html.dark .hero__form input[type="email"],
html.dark .hero__form input[type="text"] {
  background: color-mix(in srgb, #F2EFE7 9%, transparent);
  border-color: color-mix(in srgb, #F2EFE7 22%, transparent);
}
/* even the vertical rhythm: description → form → fine print */
.hero__form { margin-top: 32px; }
.hero__note { margin-top: 18px; }

/* Keep both primary actions reachable on short landscape screens while the
   mushroom remains present as an unframed, non-blocking stage. */
@media (max-width: 900px) and (max-height: 520px) and (orientation: landscape) {
  .hero {
    min-height: calc(88svh - 64px);
    display: block;
  }
  .hero__inner { padding-block: 14px 10px; }
  .status-line { margin-bottom: 6px; }
  .hero__copy { max-width: min(58vw, 390px); }
  .hero__copy h1 { font-size: 32px; line-height: 1; }
  .hero__sub {
    margin-top: 8px;
    max-width: 390px;
    font-size: 14px;
    line-height: 1.35;
  }
  .hero__form {
    margin-top: 10px;
    max-width: 390px;
    gap: 8px;
  }
  .hero__form .btn-primary,
  .hero__form .btn-secondary {
    height: 44px;
    min-height: 44px;
    padding-inline: 14px;
    font-size: 13px;
  }
  .hero .hero__note { display: none; }
  .hero__stage {
    position: absolute;
    top: 0;
    bottom: 0;
    right: max(12px, var(--safe-area-right));
    width: clamp(180px, 32vw, 280px);
    height: auto;
    margin-top: 0;
  }
}

/* dark mode: the button joins the glass system — translucent mint instead
   of solid, so input and button are one material family */
html.dark .hero__form .btn-primary {
  background: color-mix(in srgb, #4ADE80 16%, transparent);
  color: #7EE2A8;
  backdrop-filter: blur(12px) saturate(1.5);
  -webkit-backdrop-filter: blur(12px) saturate(1.5);
  border: 1px solid color-mix(in srgb, #4ADE80 35%, transparent);
}
html.dark .hero__form .btn-primary:hover {
  background: color-mix(in srgb, #4ADE80 26%, transparent);
}

/* ---------- public trust pages --------------------------------------------- */
.trust-page {
  min-height: 100dvh;
  background: var(--bg);
}
.trust-page .nav { position: sticky; }
.trust-page .nav__links { gap: 8px; }
.trust-page .nav__link { white-space: nowrap; }
.trust-main {
  width: min(100%, 1140px);
  margin-inline: auto;
  padding: 88px max(24px, var(--safe-area-right)) 112px max(24px, var(--safe-area-left));
}
.trust-hero {
  padding-bottom: 64px;
  border-bottom: 1px solid var(--border);
}
.trust-hero .eyebrow { margin-bottom: 20px; }
.trust-hero h1 {
  max-width: 12ch;
  font-size: 6.25rem;
  line-height: 0.98;
}
.trust-intro {
  max-width: 720px;
  margin-top: 28px;
  color: var(--text-secondary);
  font-size: 1.25rem;
  line-height: 1.65;
  text-wrap: pretty;
}
.trust-meta {
  margin-top: 24px;
  color: var(--text-faint);
  font-size: 0.8125rem;
  font-weight: 600;
  text-transform: uppercase;
}
.trust-layout {
  display: grid;
  grid-template-columns: minmax(180px, 240px) minmax(0, 720px);
  gap: clamp(48px, 8vw, 112px);
  align-items: start;
  padding-top: 64px;
}
.trust-toc {
  position: sticky;
  top: calc(64px + var(--safe-area-top) + 32px);
}
.trust-toc p {
  margin-bottom: 12px;
  color: var(--text-faint);
  font-size: 0.75rem;
  font-weight: 650;
  text-transform: uppercase;
}
.trust-toc ul { list-style: none; }
.trust-toc a {
  display: flex;
  align-items: center;
  min-height: 40px;
  color: var(--text-secondary);
  font-size: 0.9375rem;
  transition: color 0.15s ease;
}
.trust-toc a:hover { color: var(--ink); }
.trust-content { min-width: 0; }
.trust-content section {
  padding-block: 0 56px;
  content-visibility: visible;
  contain-intrinsic-size: none;
}
.trust-content section + section {
  padding-top: 56px;
  border-top: 1px solid var(--border);
}
.trust-content h2 {
  max-width: none;
  margin-bottom: 20px;
  font-size: 2.5rem;
  line-height: 1.08;
}
.trust-content h3 {
  margin: 28px 0 8px;
  font-size: 1rem;
  font-weight: 650;
}
.trust-content p,
.trust-content li {
  color: var(--text-secondary);
  font-size: 1rem;
  line-height: 1.75;
  text-wrap: pretty;
}
.trust-content p + p { margin-top: 16px; }
.trust-content ul {
  margin-top: 16px;
  padding-left: 1.25rem;
}
.trust-content li + li { margin-top: 10px; }
.trust-content a,
.trust-footer a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, var(--ink) 35%, transparent);
  text-underline-offset: 3px;
}
.trust-content a:hover,
.trust-footer a:hover { text-decoration-color: var(--ink); }
.trust-content .btn-primary {
  color: var(--btn-fg);
  text-decoration: none;
}
.trust-note {
  margin-top: 8px;
  padding: 20px 0 20px 20px;
  border-left: 2px solid var(--btn-bg);
}
.trust-note p { color: var(--ink); }
.trust-footer {
  border-top: 1px solid var(--border);
  padding: 28px max(24px, var(--safe-area-right)) max(28px, var(--safe-area-bottom)) max(24px, var(--safe-area-left));
}
.trust-footer__inner {
  width: min(100%, 1140px);
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: var(--text-faint);
  font-size: 0.8125rem;
}
.trust-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}
@media (max-width: 720px) {
  .trust-main { padding-top: 56px; padding-bottom: 80px; }
  .trust-hero h1 { font-size: 3rem; }
  .trust-intro { font-size: 1.05rem; }
  .trust-layout { grid-template-columns: 1fr; gap: 48px; }
  .trust-toc { position: static; }
  .trust-toc ul { display: flex; flex-wrap: wrap; gap: 4px 16px; }
  .trust-toc a { min-height: 44px; }
  .trust-content h2 { font-size: 1.75rem; }
  .trust-footer__inner { align-items: flex-start; flex-direction: column; }
}
