/* ==========================================================================
   Solara — design system
   One stylesheet, one token layer. Every page pulls from here; nothing
   defines a raw colour, radius, or duration inline.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Tokens
   -------------------------------------------------------------------------- */
:root {
  /* --- surfaces (near-black, warm purple cast — never pure #000, it smears
         on OLED and kills the ambient glow) --- */
  --bg:            #030304;
  --bg-raised:     #08080A;
  --surface:       #0C0C0F;
  --surface-hover: #121216;

  --border:        #161619;
  --border-strong: #202027;

  /* --- text --- */
  --text:          #EDEAF0;  /* 18.5:1 on --bg */
  --dim:           #9A929F;  /*  7.1:1 — all secondary copy */
  --faint:         #6A6272;  /*  3.5:1 — decorative + large text only */

  /* --- brand --- */
  --accent:        #9667F4;  /* 5.5:1 on --bg — safe for text and icons */
  --accent-soft:   #BD9CFF;
  --accent-deep:   #5425B0;
  --accent-glow:   rgba(150, 103, 244, .28);

  /* --- semantic --- */
  --ok:            #6EE7A8;
  --danger:        #FF5C7A;

  /* --- type --- */
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, "SF Pro Text",
               "Segoe UI Variable Text", "Segoe UI", Roboto, "Helvetica Neue",
               Arial, sans-serif;
  --font-display: "Inter", -apple-system, BlinkMacSystemFont, "SF Pro Display",
               "Segoe UI Variable Display", "Segoe UI", Roboto, sans-serif;
  --font-mono: ui-monospace, "SF Mono", "JetBrains Mono", "Cascadia Code",
               Consolas, monospace;

  /* type scale — 1.25 minor third, clamped for fluid resize */
  --t-xs:   0.75rem;    /* 12 */
  --t-sm:   0.8125rem;  /* 13 */
  --t-base: 0.9375rem;  /* 15 */
  --t-md:   1.0625rem;  /* 17 */
  --t-lg:   clamp(1.0625rem, 1rem   + .35vw, 1.25rem);
  --t-xl:   clamp(1.35rem,  1.15rem + .9vw,  1.75rem);
  --t-2xl:  clamp(1.65rem,  1.3rem  + 1.6vw, 2.5rem);
  --t-3xl:  clamp(2rem,     1.55rem + 2vw,   3.25rem);

  /* --- spacing: 4px rhythm --- */
  --s-1: 4px;   --s-2: 8px;   --s-3: 12px;  --s-4: 16px;
  --s-5: 24px;  --s-6: 32px;  --s-7: 48px;  --s-8: 64px;
  --s-9: 96px;  --s-10: 128px;

  /* --- shape --- */
  --r-sm: 8px;  --r-md: 12px;  --r-lg: 16px;  --r-xl: 24px;  --r-full: 999px;

  /* --- elevation --- */
  --shadow-1: 0 1px 2px rgba(0,0,0,.4);
  --shadow-2: 0 8px 24px -8px rgba(0,0,0,.6);
  --shadow-3: 0 24px 64px -16px rgba(0,0,0,.75);

  /* --- motion --- */
  --ease-out:   cubic-bezier(.22, 1, .36, 1);
  --ease-sheet: cubic-bezier(.32, .72, 0, 1);
  --ease-in:    cubic-bezier(.4, 0, 1, 1);
  --d-fast:   140ms;
  --d-base:   240ms;
  --d-slow:   420ms;

  /* --- layout --- */
  --page:   1120px;
  --narrow: 720px;
  --gutter: clamp(20px, 5vw, 40px);
  --nav-h:  70px;

  /* --- layers --- */
  --z-base: 0;  --z-raised: 10;  --z-nav: 40;  --z-overlay: 100;
}

/* The site is dark by design — there is no light variant to swap into.
   Declared so form controls, scrollbars, and UA chrome match. */
:root { color-scheme: dark; }

/* --------------------------------------------------------------------------
   2. Reset
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + var(--s-5));
}

body {
  min-height: 100dvh;
  font-family: var(--font-sans);
  font-size: var(--t-base);
  line-height: 1.6;
  letter-spacing: -.006em;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}

img, svg, video { display: block; max-width: 100%; }
img { height: auto; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: none; cursor: pointer; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }

::selection { background: var(--accent-glow); color: #fff; }

:is(a, button, summary, [tabindex]):focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: var(--r-sm);
}
:focus:not(:focus-visible) { outline: none; }

.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip-path: inset(50%); white-space: nowrap;
}

.skip-link {
  position: absolute; top: var(--s-2); left: var(--s-2);
  z-index: var(--z-overlay);
  padding: var(--s-2) var(--s-4);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--r-sm);
  font-size: var(--t-sm);
  transform: translateY(-200%);
  transition: transform var(--d-base) var(--ease-out);
}
.skip-link:focus-visible { transform: none; }

/* --------------------------------------------------------------------------
   3. Layout primitives
   -------------------------------------------------------------------------- */
.wrap {
  width: 100%;
  max-width: var(--page);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.wrap--narrow { max-width: var(--narrow); }

.section { padding-block: clamp(var(--s-7), 7vw, var(--s-9)); }
.section--tight { padding-block: clamp(var(--s-6), 5vw, var(--s-8)); }

/* Hairline divider that reads in the dark without drawing a hard line */
.rule {
  height: 1px;
  border: 0;
  background: linear-gradient(90deg,
    transparent, var(--border-strong) 20%, var(--border-strong) 80%, transparent);
}

/* --------------------------------------------------------------------------
   4. Type
   -------------------------------------------------------------------------- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -.03em;
  text-wrap: balance;
}
h1 { font-size: var(--t-3xl); letter-spacing: -.035em; line-height: 1.16; }
h2 { font-size: var(--t-2xl); }
h3 { font-size: var(--t-lg); letter-spacing: -.02em; }
h4 { font-size: var(--t-md); letter-spacing: -.015em; }

p { text-wrap: pretty; }

.lede {
  font-size: var(--t-md);
  line-height: 1.65;
  color: var(--dim);
  max-width: 58ch;
}

.eyebrow {
  font-size: var(--t-xs);
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent-soft);
}

.muted { color: var(--dim); }
.fine  { font-size: var(--t-sm); color: var(--dim); }

/* Original Framer heading treatment: grey ramping to near-white across the
   line, clipped to the glyphs. Falls back to solid --text where unsupported. */
.grad {
  color: var(--text);
  background-image: linear-gradient(92deg, #C7C7CE, #F4F4F7 46%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Tabular figures so version/stat numbers don't jitter between renders */
.tnum { font-variant-numeric: tabular-nums; }

/* --------------------------------------------------------------------------
   5. Ambient background
   Pure CSS recreation of the Solara aurora — no 1.1 MB PNG, scales to any
   viewport, and costs nothing on the network.
   -------------------------------------------------------------------------- */
.aurora {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    /* one soft pool of light behind the hero — nothing else */
    radial-gradient(85% 50% at 50% -12%, rgba(120, 84, 200, .10), transparent 62%),
    radial-gradient(55% 35% at 50% -6%,  rgba(86, 58, 160, .07),  transparent 68%),
    var(--bg);
}

/* Loose line-work drifting behind everything. Deliberately near-invisible:
   you should register it as texture, not as a graphic. */
.noodles {
  position: absolute;
  inset: -10% -6%;
  width: 112%;
  height: 120%;
  max-width: none;
  overflow: visible;
}
.noodles path {
  fill: none;
  stroke: rgba(173, 150, 232, .07);
  stroke-width: 1.1;
  stroke-linecap: round;
  vector-effect: non-scaling-stroke;
}
.noodles__a { animation: noodle-a 64s ease-in-out infinite alternate; }
.noodles__b { animation: noodle-b 82s ease-in-out infinite alternate; }
@keyframes noodle-a {
  from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(-42px, 22px, 0); }
}
@keyframes noodle-b {
  from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(38px, -26px, 0); }
}

/* --------------------------------------------------------------------------
   5b. Hand-drawn accents
   A few deliberately imperfect marks — an underline, a bracket, a margin note.
   Every one is inline SVG so it inherits colour and scales with the type.
   -------------------------------------------------------------------------- */

/* Word with a rough stroke swept under it */
.mark-under { position: relative; white-space: nowrap; }
.mark-under svg {
  position: absolute;
  left: -1.5%; bottom: -.1em;
  width: 103%; height: .3em;
  max-width: none;
  overflow: visible;
  color: var(--accent);
  pointer-events: none;
}
.mark-under path {
  fill: none;
  stroke: currentColor;
  stroke-width: 4;
  stroke-linecap: round;
  opacity: .8;
}
/* draws itself once, on reveal */
.js .mark-under path {
  stroke-dasharray: 320;
  stroke-dashoffset: 320;
}
.js [data-reveal].is-in .mark-under path,
.js .hero .mark-under path {
  animation: draw 900ms var(--ease-out) 700ms forwards;
}
@keyframes draw { to { stroke-dashoffset: 0; } }

/* Rough ellipse lassoed around a word */
.mark-circle { position: relative; display: inline-block; }
.mark-circle svg {
  position: absolute;
  left: -17%; top: -22%;
  width: 134%; height: 138%;
  max-width: none;
  overflow: visible;
  color: var(--accent);
  pointer-events: none;
}
.mark-circle path {
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
  opacity: .6;
}
/* the lasso overhangs the text box, so give the line below it room */
.cell__num:has(.mark-circle) { margin-bottom: var(--s-2); }
.js .mark-circle path { stroke-dasharray: 460; stroke-dashoffset: 460; }
.js [data-reveal].is-in .mark-circle path { animation: draw 1100ms var(--ease-out) 380ms forwards; }

/* Marker swipe laid behind a word */
.mark-hl { position: relative; display: inline-block; isolation: isolate; }
.mark-hl svg {
  position: absolute;
  left: -7%; top: 16%;
  width: 114%; height: 78%;
  max-width: none;
  z-index: -1;
  overflow: visible;
  color: var(--accent);
  pointer-events: none;
}
.mark-hl path {
  fill: none;
  stroke: currentColor;
  stroke-width: 26;
  stroke-linecap: round;
  opacity: .34;
}
.js .mark-hl path { stroke-dasharray: 300; stroke-dashoffset: 300; }
.js [data-reveal].is-in .mark-hl path { animation: draw 820ms var(--ease-out) 220ms forwards; }

/* Small handwritten aside, pinned beside something */
.note-aside {
  display: inline-flex;
  align-items: center;
  gap: var(--s-3);
  font-size: var(--t-sm);
  color: var(--dim);
}
.note-aside svg { width: 26px; height: 16px; color: var(--faint); flex: none; }
.note-aside path { fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; }

/* Footnote star, for the honest caveats */
.ast {
  font-size: .78em;
  vertical-align: super;
  color: var(--accent-soft);
  margin-left: 1px;
}

/* --------------------------------------------------------------------------
   6. Buttons
   Sizes are token-driven so every CTA on the site is literally the same
   component. Min height 44px throughout for touch.
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--s-2);
  min-height: 44px;
  padding: 0 var(--s-5);
  font-size: var(--t-base);
  font-weight: 550;
  letter-spacing: -.012em;
  white-space: nowrap;
  border-radius: var(--r-full);
  border: 1px solid transparent;
  cursor: pointer;
  transform: translateZ(0);
  transition: background var(--d-base) var(--ease-out),
              border-color var(--d-base) var(--ease-out),
              color var(--d-base) var(--ease-out),
              transform var(--d-slow) var(--ease-sheet);
}
.btn:active { transform: scale(.97); transition-duration: var(--d-fast); }

/* Primary: near-white on near-black. 17:1 contrast, and it lets the purple
   stay an ambient/accent colour instead of fighting the CTA for attention. */
.btn--primary {
  color: #0A0610;
  background: var(--text);
}
.btn--primary:hover { background: #fff; }

.btn--ghost {
  color: var(--text);
  background: var(--surface);
  border-color: var(--border);
}
.btn--ghost:hover { background: var(--surface-hover); border-color: var(--border-strong); }

.btn--quiet {
  color: var(--dim);
  padding-inline: var(--s-3);
}
.btn--quiet:hover { color: var(--text); }

.btn--sm { min-height: 38px; padding: 0 var(--s-5); font-size: var(--t-base); }
.btn--lg { min-height: 52px; padding: 0 var(--s-6); font-size: var(--t-md); }

.btn .icon { width: 18px; height: 18px; flex: none; }

.btn-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-3);
}

/* --------------------------------------------------------------------------
   7. Badge / pill
   -------------------------------------------------------------------------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  padding: var(--s-1) var(--s-3) var(--s-1) var(--s-2);
  font-size: var(--t-xs);
  font-weight: 500;
  color: var(--dim);
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--r-full);
}
.badge b { color: var(--text); font-weight: 550; }
.badge .dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--ok);
  box-shadow: 0 0 0 3px rgba(110,231,168,.14);
  flex: none;
}

/* --------------------------------------------------------------------------
   8. Nav
   -------------------------------------------------------------------------- */
.nav {
  position: sticky;
  top: 0;
  z-index: var(--z-nav);
  height: var(--nav-h);
  display: flex;
  align-items: center;
  border-bottom: 1px solid transparent;
  transition: background var(--d-base) var(--ease-out),
              border-color var(--d-base) var(--ease-out);
}
/* .is-stuck is toggled by site.js past the first 8px of scroll */
.nav.is-stuck {
  background: rgba(5, 3, 8, .72);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border-bottom-color: var(--border);
}

.nav__inner {
  display: flex;
  align-items: center;
  gap: var(--s-5);
  width: 100%;
}

.nav__brand { display: flex; align-items: center; gap: var(--s-2); margin-right: auto; }
.nav__brand img { height: 24px; width: auto; }

.nav__links {
  display: flex;
  align-items: center;
  gap: var(--s-1);
}
.nav__links a {
  padding: var(--s-2) var(--s-4);
  font-size: var(--t-base);
  color: var(--dim);
  border-radius: var(--r-sm);
  transition: color var(--d-fast) var(--ease-out);
}
.nav__links a:hover { color: var(--text); }
.nav__links a[aria-current="page"] { color: var(--text); }

.nav__toggle { display: none; }

@media (max-width: 767px) {
  .nav__links { display: none; }
  .nav__links.is-open {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    position: absolute;
    top: var(--nav-h);
    left: var(--gutter);
    right: var(--gutter);
    padding: var(--s-2);
    background: var(--bg-raised);
    border: 1px solid var(--border);
    border-radius: var(--r-lg);
    box-shadow: var(--shadow-3);
  }
  .nav__links.is-open a { padding: var(--s-3) var(--s-4); }
  .nav__toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px; height: 44px;
    margin-right: calc(var(--s-3) * -1);
    color: var(--dim);
    border-radius: var(--r-sm);
  }
  .nav__cta { display: none; }
}

/* --------------------------------------------------------------------------
   9. Hero
   -------------------------------------------------------------------------- */
/* Entrance: gentle rise + focus pull — same curve and blur the download page
   has always used. Runs on load, staggered, once. */
@keyframes rise {
  from { opacity: 0; transform: translateY(16px); filter: blur(5px); }
  to   { opacity: 1; transform: none;             filter: none; }
}

.hero {
  padding-top: clamp(var(--s-8), 10vw, var(--s-10));
  padding-bottom: clamp(var(--s-7), 6vw, var(--s-9));
  text-align: center;
}
.hero__inner > * { animation: rise 800ms var(--ease-out) both; }

.hero .shot-frame {
  animation: rise 900ms var(--ease-out) 420ms both;
  perspective: 1400px;
}

/* The app sits on a slight resting tilt so it has some attitude before you
   touch it; site.js then drives --rx/--ry from the pointer. CSS owns the
   easing, so the JS side is just four number writes per frame. */
.hero .shot {
  transform: rotateX(var(--rx, 2.2deg)) rotateY(var(--ry, -1.4deg)) scale(var(--sc, 1));
  transform-origin: 50% 80%;
  transition: transform 900ms var(--ease-out);
  will-change: transform;
}
/* while the pointer is over it, track tightly instead of easing */
.hero .shot.is-live { transition: transform 90ms linear; }

/* a soft sheen that slides across the glass as it tips */
.hero .shot::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: radial-gradient(520px circle at var(--gx, 50%) var(--gy, -10%),
              rgba(255,255,255,.09), rgba(255,255,255,.02) 42%, transparent 68%);
  opacity: 0;
  transition: opacity 450ms var(--ease-out);
}
.hero .shot.is-live::after { opacity: 1; }
.hero__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-5);
}
/* align-items:center makes each child max-content wide; without this cap a
   long heading never gets the chance to wrap. */
.hero__inner > * { max-width: 100%; }
/* keep the CTAs centred once they wrap onto two lines */
.hero .btn-row { justify-content: center; }
.hero .lede { margin-inline: auto; text-align: center; }
.hero h1 { max-width: 16ch; }

/* Product shot. The glow lives on the wrapper, not the frame itself — the
   frame clips its own overflow, so a bloom drawn inside it would be cut off. */
.shot-frame { position: relative; margin-top: var(--s-7); }
/* The original hero card sat on a blurred #8759f2 ellipse peeking out from
   underneath — light source below the app, not behind it. */
.shot-frame::before {
  content: "";
  position: absolute;
  left: 18%; right: 18%; bottom: -10px;
  height: 30%;
  background: #7E57D6;
  border-radius: 100%;
  filter: blur(60px);
  opacity: .28;
  pointer-events: none;
}

/* aspect-ratio on the image reserves the box, so nothing shifts on load */
.shot {
  position: relative;
  border-radius: 18px;   /* a touch tighter than --r-xl; matches the app's own chrome */
  border: 1px solid var(--border-strong);
  background: var(--bg-raised);
  overflow: hidden;
  box-shadow: var(--shadow-3);
}
.shot img { width: 100%; height: auto; }

/* --------------------------------------------------------------------------
   11. Section headers
   -------------------------------------------------------------------------- */
.head {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  max-width: 44ch;
  margin-bottom: var(--s-6);
}
.head .label {
  font-size: var(--t-xs);
  font-weight: 500;
  color: var(--faint);
  letter-spacing: .01em;
}
.head h2 { font-size: var(--t-2xl); }
.head .lede { font-size: var(--t-base); }
.head--center { margin-inline: auto; text-align: center; align-items: center; }
.head--center h2 { max-width: 24ch; }
.head .lede { margin: 0; }
.head--center .lede { text-align: center; }

/* --------------------------------------------------------------------------
   12. Cards / feature grid
   -------------------------------------------------------------------------- */
.grid {
  display: grid;
  gap: var(--s-4);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
}
/* Exactly four items: pair up instead of orphaning the last card. */
.grid--four { grid-template-columns: 1fr; }
@media (min-width: 560px)  { .grid--four { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .grid--four { grid-template-columns: repeat(4, 1fr); } }

/* Numbers strip. Hairline rules only, no frame: it is a row of facts, not a
   set of panels. */
.stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
@media (min-width: 640px)  { .stats { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1040px) { .stats { grid-template-columns: repeat(5, 1fr); } }

.stat {
  padding: var(--s-5) var(--s-4);
  border-top: 1px solid var(--border);
}
.stat:nth-child(-n+2) { border-top: 0; }
@media (min-width: 640px) {
  .stat:nth-child(-n+3) { border-top: 0; }
  .stat + .stat { border-left: 1px solid var(--border); }
  .stat:nth-child(3n+1) { border-left: 0; }
}
@media (min-width: 1040px) {
  .stat { border-top: 0; }
  .stat + .stat { border-left: 1px solid var(--border); }
  .stat:nth-child(3n+1) { border-left: 1px solid var(--border); }
  .stat:first-child { border-left: 0; }
}
.stat dt {
  font-family: var(--font-display);
  font-size: var(--t-xl);
  font-weight: 600;
  letter-spacing: -.03em;
  font-variant-numeric: tabular-nums;
  margin-bottom: var(--s-1);
}
.stat dd { font-size: var(--t-sm); color: var(--dim); }

/* Bento panel: hairline cells inside one bordered frame, for the places that
   genuinely benefit from being grouped. */
.bento {
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  background: var(--bg-raised);
  overflow: hidden;
  display: grid;
  grid-template-columns: 1fr;
}
@media (min-width: 720px) { .bento { grid-template-columns: repeat(2, 1fr); } }
.bento > * { padding: var(--s-5); border-top: 1px solid var(--border); }
.bento > :first-child { border-top: 0; }
@media (min-width: 720px) {
  .bento > * { border-top: 1px solid var(--border); }
  .bento > :nth-child(-n+2) { border-top: 0; }
  .bento > :nth-child(2n) { border-left: 1px solid var(--border); }
}

.cell h3 {
  font-size: var(--t-base);
  font-weight: 590;
  letter-spacing: -.012em;
  margin-bottom: var(--s-2);
}
.cell p {
  font-size: var(--t-sm);
  line-height: 1.6;
  color: var(--dim);
}
.cell a {
  color: var(--accent-soft);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color var(--d-fast) var(--ease-out);
}
.cell a:hover { color: var(--text); }
.cell__num {
  display: block;
  font-family: var(--font-display);
  font-size: var(--t-xl);
  font-weight: 600;
  letter-spacing: -.03em;
  font-variant-numeric: tabular-nums;
  margin-bottom: var(--s-1);
}

/* --------------------------------------------------------------------------
   13. Split feature row
   -------------------------------------------------------------------------- */
.split {
  display: grid;
  gap: clamp(var(--s-6), 5vw, var(--s-8));
  align-items: center;
  grid-template-columns: 1fr;
}
@media (min-width: 900px) {
  .split { grid-template-columns: 1fr 1.1fr; }
  /* Flipped: the media moves left, so the wide column has to move with it. */
  .split--flip { grid-template-columns: 1.1fr 1fr; }
  .split--flip > *:first-child { order: 2; }
}

.checklist { display: flex; flex-direction: column; gap: var(--s-3); margin-top: var(--s-5); }
.checklist li {
  display: flex;
  gap: var(--s-3);
  align-items: flex-start;
  font-size: var(--t-base);
  color: var(--dim);
}
.checklist svg { width: 18px; height: 18px; flex: none; margin-top: 3px; color: var(--accent); }
.checklist b { color: var(--text); font-weight: 550; }

/* --------------------------------------------------------------------------
   13b. Theme carousel
   Horizontal scroll-snap rail. Native overflow scrolling does the work; the
   arrow buttons just call scrollBy, so it stays usable with JS off.
   -------------------------------------------------------------------------- */
.rail-head {
  display: flex;
  align-items: flex-end;
  gap: var(--s-4);
  margin-bottom: var(--s-5);
}
.rail-head .head { margin-bottom: 0; }
.rail-nav { display: flex; gap: var(--s-2); margin-left: auto; flex: none; }
.rail-btn {
  display: grid;
  place-items: center;
  width: 36px; height: 36px;
  color: var(--dim);
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: 50%;
  transition: color var(--d-base) var(--ease-out),
              border-color var(--d-base) var(--ease-out),
              background var(--d-base) var(--ease-out);
}
.rail-btn:hover { color: var(--text); border-color: var(--border-strong); background: var(--surface); }
.rail-btn svg { width: 16px; height: 16px; }

.rail {
  display: flex;
  gap: var(--s-4);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-left: var(--gutter);
  scrollbar-width: none;
  /* bleed to the viewport edge so tiles run off-screen like a real rail */
  margin-inline: calc(var(--gutter) * -1);
  padding-inline: var(--gutter);
  padding-bottom: var(--s-2);
}
.rail::-webkit-scrollbar { display: none; }

.tile {
  flex: 0 0 auto;
  width: min(78vw, 320px);
  scroll-snap-align: start;
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  background: var(--bg-raised);
  overflow: hidden;
  transition: border-color var(--d-base) var(--ease-out);
}
.tile:hover { border-color: var(--border-strong); }
.tile img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; display: block; }
.tile figcaption {
  display: flex;
  align-items: baseline;
  gap: var(--s-2);
  padding: var(--s-3) var(--s-4);
  border-top: 1px solid var(--border);
}
.tile .t-name { font-size: var(--t-sm); font-weight: 550; }
.tile .t-by { margin-left: auto; font-size: var(--t-xs); color: var(--faint); }

/* Built-in theme tiles carry real screenshots, so they follow the image's own
   aspect ratio rather than a fixed box. */
/* ---- focal rail: the centred theme is big and lit, neighbours recede ----
   JS writes --s/--b/--o from each tile's distance to the rail centre. The
   defaults below are the neutral state, so with JS off it is just a rail. */
.rail--focal {
  --tile-w: min(78vw, 540px);
  scroll-snap-type: x mandatory;
  align-items: center;
  gap: var(--s-5);
  padding-inline: calc(50% - (var(--tile-w) / 2));
  margin-inline: 0;
  padding-bottom: var(--s-4);
}
.rail--focal .tile {
  width: var(--tile-w);
  scroll-snap-align: center;
  transform: scale(var(--s, 1));
  filter: brightness(var(--b, 1));
  opacity: var(--o, 1);
  transition: transform 480ms var(--ease-out),
              filter 480ms var(--ease-out),
              opacity 480ms var(--ease-out),
              border-color var(--d-base) var(--ease-out);
  will-change: transform;
}
/* real screenshots, so follow the image's own ratio */
.rail--focal .tile img { aspect-ratio: 1000 / 566; object-fit: cover; }
.rail--focal .tile figcaption { padding: var(--s-4) var(--s-5); }
.rail--focal .t-name { font-size: var(--t-base); }

@media (prefers-reduced-motion: reduce) {
  .rail--focal .tile { transform: none; filter: none; opacity: 1; }
}

.tile--theme { width: min(64vw, 232px); }

/* --------------------------------------------------------------------------
   13d. ScriptHub providers
   -------------------------------------------------------------------------- */
.providers {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-3);
  margin-top: var(--s-5);
}
.provider {
  display: inline-flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-3) var(--s-4);
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  transition: border-color var(--d-base) var(--ease-out), background var(--d-base) var(--ease-out);
}
.provider:hover { border-color: var(--border-strong); background: var(--surface); }
.providers--grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-3);
}
@media (min-width: 640px) { .providers--grid { grid-template-columns: repeat(3, 1fr); } }
.providers--grid .provider { padding: var(--s-4); }
.provider img { width: 22px; height: 22px; border-radius: 5px; flex: none; }
.provider span { font-size: var(--t-sm); font-weight: 500; }
.provider small { font-size: var(--t-xs); color: var(--faint); }

/* --------------------------------------------------------------------------
   13c. Community showcase
   -------------------------------------------------------------------------- */
.showcase {
  display: grid;
  gap: var(--s-4);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
}
.vid {
  position: relative;
  display: block;
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  background: var(--bg-raised);
  overflow: hidden;
  transition: border-color var(--d-base) var(--ease-out);
}
.vid:hover { border-color: var(--border-strong); }
.vid img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; display: block; }
.vid__play {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  display: grid; place-items: center;
  width: 44px; height: 44px;
  border-radius: 50%;
  color: #fff;
  background: rgba(10,10,12,.7);
  border: 1px solid rgba(255,255,255,.18);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  transition: background var(--d-base) var(--ease-out), transform var(--d-slow) var(--ease-sheet);
}
.vid:hover .vid__play { background: rgba(126,87,214,.85); transform: translate(-50%,-50%) scale(1.06); }
.vid__play svg { width: 15px; height: 15px; margin-left: 2px; }
.vid figcaption { padding: var(--s-3) var(--s-4); border-top: 1px solid var(--border); }
.vid .v-title {
  display: block;
  font-size: var(--t-sm);
  font-weight: 550;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.vid .v-by { font-size: var(--t-xs); color: var(--faint); }

/* A human aside under the showcase grid. Deliberately unpolished. */
.plea {
  display: flex;
  gap: var(--s-3);
  max-width: 64ch;
  margin-top: var(--s-5);
  font-size: var(--t-sm);
  line-height: 1.65;
  color: var(--faint);
}
.plea__mark { flex: none; margin-top: 2px; }
.plea__mark svg { width: 34px; height: 20px; color: var(--border-strong); overflow: visible; }
.plea__mark path { fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; }

/* --------------------------------------------------------------------------
   14. FAQ
   Native <details>/<summary>: the answers ship in the HTML, so crawlers and
   screen readers get them with zero JavaScript.
   -------------------------------------------------------------------------- */
.faq { display: flex; flex-direction: column; border-top: 1px solid var(--border); }

.faq details {
  border-bottom: 1px solid var(--border);
  transition: border-color var(--d-base) var(--ease-out);
}
.faq details:hover { border-bottom-color: var(--border-strong); }

.faq summary {
  display: flex;
  align-items: center;
  gap: var(--s-4);
  min-height: 56px;
  padding: var(--s-4) var(--s-1);
  font-size: var(--t-base);
  font-weight: 550;
  letter-spacing: -.015em;
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }

.faq summary .chev {
  width: 18px; height: 18px;
  margin-left: auto;
  flex: none;
  color: var(--faint);
  transition: transform var(--d-base) var(--ease-out), color var(--d-base) var(--ease-out);
}
.faq details[open] summary .chev { transform: rotate(180deg); color: var(--accent-soft); }

.faq__body {
  padding: 0 var(--s-1) var(--s-5);
  font-size: var(--t-base);
  color: var(--dim);
  max-width: 68ch;
}
.faq__body p + p { margin-top: var(--s-3); }
.faq__body a { color: var(--accent-soft); text-decoration: underline; text-underline-offset: 3px; }
.faq__body a:hover { color: var(--text); }

/* --------------------------------------------------------------------------
   15. Closing CTA
   -------------------------------------------------------------------------- */
.cta {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-4);
  padding: clamp(var(--s-8), 9vw, var(--s-10)) var(--gutter) clamp(var(--s-7), 7vw, var(--s-9));
  text-align: center;
}
/* the light behind it does the work a border used to */
.cta::before {
  content: "";
  position: absolute;
  inset: -10% 0 auto;
  height: 130%;
  background: radial-gradient(42% 46% at 50% 42%, rgba(126,87,214,.20), transparent 70%);
  pointer-events: none;
}
.cta > * { position: relative; }
.cta h2 { font-size: var(--t-3xl); }
.cta__fine {
  margin-top: var(--s-1);
  font-size: var(--t-sm);
  color: var(--faint);
}

/* --------------------------------------------------------------------------
   16. Footer
   -------------------------------------------------------------------------- */
.footer {
  border-top: 1px solid var(--border);
  padding-block: var(--s-7) var(--s-6);
  margin-top: var(--s-8);
}
.footer__grid {
  display: grid;
  gap: var(--s-6);
  grid-template-columns: 1fr;
}
@media (min-width: 700px) {
  .footer__grid { grid-template-columns: 2fr 1fr 1fr 1fr; }
}
.footer__brand img { height: 20px; width: auto; margin-bottom: var(--s-3); }
.footer h4 {
  font-size: var(--t-xs);
  font-weight: 550;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--faint);
  margin-bottom: var(--s-3);
}
.footer nav { display: flex; flex-direction: column; gap: var(--s-2); align-items: flex-start; }
.footer nav a {
  font-size: var(--t-sm);
  color: var(--dim);
  transition: color var(--d-fast) var(--ease-out);
}
.footer nav a:hover { color: var(--text); }

/* socials carry their marks */
.footer nav.social a {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
}
.footer nav.social svg { width: 15px; height: 15px; flex: none; color: var(--faint); transition: color var(--d-fast) var(--ease-out); }
.footer nav.social a:hover svg { color: var(--text); }

.footer__mirrors {
  margin-top: var(--s-7);
  font-size: var(--t-xs);
  color: var(--faint);
}
.footer__mirrors b { color: var(--dim); font-weight: 550; }

.footer__base {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-3) var(--s-5);
  align-items: center;
  justify-content: space-between;
  margin-top: var(--s-7);
  padding-top: var(--s-5);
  border-top: 1px solid var(--border);
  font-size: var(--t-xs);
  color: var(--dim);
}

/* --------------------------------------------------------------------------
   16b. Legal pages
   -------------------------------------------------------------------------- */
.legal { padding-block: clamp(var(--s-7), 7vw, var(--s-9)); }
.legal__head { margin-bottom: var(--s-7); }
.legal__head h1 { font-size: var(--t-2xl); }
.legal__head p { margin-top: var(--s-3); color: var(--dim); font-size: var(--t-sm); }

.legal h2 {
  font-size: var(--t-lg);
  margin-top: var(--s-7);
  margin-bottom: var(--s-3);
  padding-top: var(--s-5);
  border-top: 1px solid var(--border);
}
.legal h2:first-of-type { border-top: 0; padding-top: 0; margin-top: 0; }
.legal h3 { font-size: var(--t-base); margin-top: var(--s-5); margin-bottom: var(--s-2); }
.legal p, .legal li { color: var(--dim); font-size: var(--t-base); line-height: 1.7; }
.legal p + p { margin-top: var(--s-3); }
.legal ul { margin: var(--s-3) 0 0; padding-left: var(--s-5); }
.legal li { list-style: disc; margin-bottom: var(--s-2); }
.legal li::marker { color: var(--faint); }
.legal strong { color: var(--text); font-weight: 550; }
.legal a { color: var(--accent-soft); text-decoration: underline; text-underline-offset: 3px; }
.legal a:hover { color: var(--text); }
.legal__foot {
  margin-top: var(--s-8);
  padding-top: var(--s-5);
  border-top: 1px solid var(--border);
  font-size: var(--t-sm);
  color: var(--faint);
}

/* --------------------------------------------------------------------------
   16c. Not found
   -------------------------------------------------------------------------- */
.nf {
  min-height: calc(100dvh - var(--nav-h));
  display: flex;
  align-items: center;
  padding-block: var(--s-8);
}
.nf__inner {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--s-4);
  max-width: 52ch;
}
.nf h1 { font-size: var(--t-2xl); }
.nf .lede { margin: 0; }
.nf .btn-row { margin-top: var(--s-2); }
.nf__fine {
  margin-top: var(--s-5);
  font-size: var(--t-xs);
  color: var(--faint);
}
.nf__fine b { color: var(--dim); font-weight: 550; }

/* --------------------------------------------------------------------------
   17. Aside
   A margin note, not a card. One hairline rule carries it; no fill, no border
   box, so it reads as commentary rather than another panel to parse.
   -------------------------------------------------------------------------- */
.aside {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-2);
  max-width: 62ch;
  margin-top: var(--s-6);
  padding-left: var(--s-5);
}
/* the rule is drawn, not ruled: it wobbles like it was done by hand */
.aside__rule {
  position: absolute;
  left: 2px; top: 2px;
  width: 8px;
  height: calc(100% - 4px);
  max-width: none;
  overflow: visible;
  color: var(--border-strong);
}
.aside__rule path {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
}
.js .aside__rule path { stroke-dasharray: 200; stroke-dashoffset: 200; }
.js [data-reveal].is-in .aside__rule path,
.js .aside.is-in .aside__rule path { animation: draw 900ms var(--ease-out) 120ms forwards; }

@media (min-width: 700px) {
  .aside {
    grid-template-columns: 8.5rem 1fr;
    gap: 0 var(--s-4);
    max-width: 72ch;
  }
}
.aside__label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: var(--t-xs);
  font-weight: 500;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--accent-soft);
  padding-top: 2px;
}
.aside__label::before {
  content: "";
  width: 5px; height: 5px;
  border-radius: 50%;
  background: currentColor;
  opacity: .55;
  flex: none;
}
.aside p {
  font-size: var(--t-sm);
  line-height: 1.7;
  color: var(--dim);
}
.aside a {
  color: var(--accent-soft);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color var(--d-fast) var(--ease-out);
}
.aside a:hover { color: var(--text); }

/* --------------------------------------------------------------------------
   18. Scroll reveal
   Opacity + transform only, so it never triggers layout. Elements are
   visible by default and only hidden once JS confirms it can reveal them,
   which keeps content readable with JS disabled.
   -------------------------------------------------------------------------- */
[data-reveal] { opacity: 1; }
.js [data-reveal] {
  opacity: 0;
  transform: translateY(16px);
  filter: blur(5px);
  transition: opacity 600ms var(--ease-out),
              transform 600ms var(--ease-out),
              filter 600ms var(--ease-out);
}
.js [data-reveal].is-in { opacity: 1; transform: none; filter: none; }

/* --------------------------------------------------------------------------
   19. Reduced motion
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .noodles__a, .noodles__b { animation: none !important; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
  .js [data-reveal] { opacity: 1; transform: none; }
}

/* --------------------------------------------------------------------------
   20. Print
   -------------------------------------------------------------------------- */
@media print {
  .aurora, .nav, .cta::before, .shot::before { display: none; }
  body { background: #fff; color: #000; }
  .faq details { border-color: #ccc; }
  .faq details:not([open]) > .faq__body { display: block; }
}
