/* KorvAI landing page
 * Theme: dark first (brand "Night"), one accent (Acid Lime #C8F23C), light variant uses the brand's olive and ink.
 * Shapes: interactive controls are full pills; cards are 24px; UI insets (app mockups) are 12px.
 * Type: Dongle Bold for display (the wordmark face), Geist for text, Geist Mono for UI labels.
 */

@font-face {
  font-family: "Dongle";
  src: url("../fonts/dongle-bold.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
  /* Dongle's capitals are 0.40em tall; scale it so 1em reads like a normal display face. */
  size-adjust: 175%;
  ascent-override: 92%;
  descent-override: 30%;
  line-gap-override: 0%;
}
@font-face {
  font-family: "Geist";
  src: url("../fonts/geist-var.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "Geist Mono";
  src: url("../fonts/geist-mono-var.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --font-display: "Dongle", "Geist", system-ui, sans-serif;
  --font-text: "Geist", -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, sans-serif;
  --font-mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --ease: cubic-bezier(0.32, 0.72, 0, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --spring: cubic-bezier(0.34, 1.56, 0.64, 1);

  --r-card: 24px;
  --r-inner: 18px;
  --r-ui: 12px;

  --container: 1240px;
  --gutter: clamp(20px, 4vw, 40px);
  --section: clamp(96px, 12vw, 168px);

  /* Product UI colors: the app is dark in both page themes. */
  --app-bg: #0c0e0a;
  --app-panel: #11140e;
  --app-line: rgba(237, 239, 232, 0.08);
  --app-text: #edefe8;
  --app-muted: #9ea392;
  --lime: #c8f23c;
  --ink: #13160f;
}

[data-theme="dark"] {
  --bg: #08090a;
  --bg-raise: #0d0f0b;
  --surface: #111410;
  --surface-2: #171b12;
  --line: rgba(237, 239, 232, 0.08);
  --line-2: rgba(237, 239, 232, 0.15);
  --text: #edefe8;
  --muted: #a6ab9e;
  --accent: #c8f23c;
  --accent-display: #c8f23c;
  --accent-text: #c8f23c;
  --on-accent: #13160f;
  --glow: rgba(200, 242, 60, 0.16);
  --shadow: rgba(0, 0, 0, 0.55);
  --nav-bg: rgba(13, 15, 11, 0.62);
  color-scheme: dark;
}

[data-theme="light"] {
  --bg: #f2f4ec;
  --bg-raise: #eaede1;
  --surface: #ffffff;
  --surface-2: #f7f8f2;
  --line: rgba(19, 22, 15, 0.09);
  --line-2: rgba(19, 22, 15, 0.17);
  --text: #13160f;
  --muted: #4c5345;
  --accent: #c8f23c;
  --accent-display: #4f8a00;
  --accent-text: #3f6e00;
  --on-accent: #13160f;
  --glow: rgba(111, 168, 0, 0.16);
  --shadow: rgba(40, 52, 18, 0.18);
  --nav-bg: rgba(255, 255, 255, 0.7);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 96px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-text);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  transition: background-color 0.5s var(--ease), color 0.5s var(--ease);
}
img, video, svg { display: block; max-width: 100%; }
img, video { height: auto; }
a { color: inherit; }
button { font: inherit; color: inherit; }
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
code { font-family: var(--font-mono); }
/* Translucent, so a tall display line's highlight never paints over the line above it. */
::selection { background: color-mix(in srgb, var(--accent) 38%, transparent); color: var(--text); }
:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 3px; border-radius: 6px; }

.i { width: 1.15em; height: 1.15em; flex: none; }
.skip {
  position: fixed; left: 16px; top: -60px; z-index: 100;
  padding: 10px 16px; border-radius: 999px; background: var(--accent); color: var(--on-accent);
  font-weight: 600; text-decoration: none; transition: top 0.3s var(--ease);
}
.skip:focus { top: 16px; }

.container { width: 100%; max-width: calc(var(--container) + var(--gutter) * 2); margin-inline: auto; padding-inline: var(--gutter); }
.center { text-align: center; }
.muted { color: var(--muted); }
.accent { color: var(--accent-display); }
.narrow { max-width: 60ch; }

/* ---------- Type ---------- */
.display, .display-2 { font-family: var(--font-display); font-weight: 700; letter-spacing: -0.005em; text-wrap: balance; padding-bottom: 0.08em; }
.display { font-size: clamp(50px, 4.9vw, 80px); line-height: 0.9; }
.display-2 { font-size: clamp(40px, 4.4vw, 64px); line-height: 0.94; }
.section-head { margin-bottom: clamp(40px, 6vw, 72px); }
.lede { font-size: clamp(17px, 1.45vw, 20px); line-height: 1.55; color: var(--muted); max-width: 46ch; }
.body-lg { font-size: clamp(17px, 1.35vw, 19px); line-height: 1.6; color: var(--muted); margin-top: 24px; max-width: 52ch; }
.body { margin-top: 14px; font-size: 15px; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--accent-text); margin-bottom: 18px;
}
.eyebrow::before { content: ""; width: 18px; height: 1.5px; background: currentColor; border-radius: 2px; }

/* ---------- Buttons ---------- */
.btn {
  --pad: 22px;
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  height: 52px; padding: 0 6px 0 var(--pad); border-radius: 999px; border: 1px solid transparent;
  font-weight: 600; font-size: 15.5px; letter-spacing: -0.01em; white-space: nowrap; text-decoration: none; cursor: pointer;
  transition: transform 0.35s var(--ease), background-color 0.35s var(--ease), border-color 0.35s var(--ease), box-shadow 0.35s var(--ease);
}
.btn:active { transform: scale(0.97); }
.btn-ico {
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 999px;
  transition: transform 0.45s var(--spring);
}
.btn:hover .btn-ico { transform: translate(2px, -1px) scale(1.06); }
.btn-primary { background: var(--accent); color: var(--on-accent); box-shadow: 0 10px 40px -12px var(--glow), inset 0 1px 0 rgba(255, 255, 255, 0.4); }
.btn-primary .btn-ico { background: rgba(19, 22, 15, 0.1); }
.btn-primary:hover { box-shadow: 0 16px 50px -10px var(--glow), inset 0 1px 0 rgba(255, 255, 255, 0.5); }
[data-theme="light"] .btn-primary { border-color: rgba(19, 22, 15, 0.14); }
.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--line-2); }
.btn-ghost .btn-ico { background: var(--surface-2); border: 1px solid var(--line); }
.btn-ghost:hover { border-color: var(--text); }
.btn-sm { height: 40px; padding: 0 18px; font-size: 14px; }
.btn-lg { height: 58px; --pad: 26px; font-size: 16.5px; }
.btn-lg .btn-ico { width: 46px; height: 46px; }
.btn-block { width: 100%; justify-content: space-between; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }
.cta-row.center { justify-content: center; }
.icon-btn {
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 999px;
  background: transparent; border: 1px solid var(--line-2); cursor: pointer; transition: border-color 0.3s var(--ease), transform 0.3s var(--ease);
}
.icon-btn:hover { border-color: var(--text); }
.icon-btn:active { transform: scale(0.94); }
.link-btn { background: none; border: 0; padding: 0; cursor: pointer; color: inherit; text-decoration: none; font-size: inherit; }

/* ---------- Scroll progress (a playhead along the top) ---------- */
.progress { position: fixed; inset: 0 0 auto 0; height: 2px; z-index: 60; pointer-events: none; display: none; }
@supports (animation-timeline: scroll()) {
  .progress { display: block; background: var(--accent); transform-origin: 0 50%; animation: progress linear both; animation-timeline: scroll(root); }
  @keyframes progress { from { transform: scaleX(0); } to { transform: scaleX(1); } }
}

/* ---------- Nav ---------- */
.nav-wrap { position: fixed; inset: 14px 0 auto 0; z-index: 50; padding-inline: 14px; pointer-events: none; }
.nav {
  pointer-events: auto; margin-inline: auto; max-width: 1120px; height: 62px;
  display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 0 10px 0 20px;
  border-radius: 999px; border: 1px solid var(--line); background: var(--nav-bg);
  -webkit-backdrop-filter: blur(18px) saturate(160%); backdrop-filter: blur(18px) saturate(160%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05), 0 12px 40px -18px var(--shadow);
  transition: background-color 0.5s var(--ease), border-color 0.5s var(--ease);
}
.nav-brand img { height: 30px; width: auto; }
.nav-links { display: flex; gap: 4px; }
.nav-links a { display: block; padding: 8px 14px; border-radius: 999px; font-size: 14.5px; color: var(--muted); text-decoration: none; transition: color 0.25s, background-color 0.25s; }
.nav-links a:hover { color: var(--text); background: var(--line); }
.nav-actions { display: flex; align-items: center; gap: 8px; }
.theme-toggle .i { width: 18px; height: 18px; }
[data-theme="dark"] .i-moon, [data-theme="light"] .i-sun { display: none; }
[data-theme="dark"] .logo-light, [data-theme="light"] .logo-dark { display: none; }
.menu-toggle { display: none; position: relative; }
.menu-toggle span { position: absolute; left: 12px; right: 12px; height: 1.5px; background: currentColor; border-radius: 2px; transition: transform 0.45s var(--ease), top 0.45s var(--ease); }
.menu-toggle span:first-child { top: 15px; }
.menu-toggle span:last-child { top: 23px; }
.menu-toggle[aria-expanded="true"] span:first-child { top: 19px; transform: rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:last-child { top: 19px; transform: rotate(-45deg); }
.mobile-menu {
  pointer-events: auto; margin: 10px auto 0; max-width: 1120px; padding: 18px; border-radius: var(--r-card);
  background: var(--nav-bg); border: 1px solid var(--line); -webkit-backdrop-filter: blur(24px); backdrop-filter: blur(24px);
}
.mobile-menu a { display: block; padding: 12px 8px; font-family: var(--font-display); font-size: 34px; line-height: 1; text-decoration: none; }
.mobile-menu li { opacity: 0; transform: translateY(16px); transition: opacity 0.5s var(--ease), transform 0.5s var(--ease); transition-delay: calc(var(--n, 0) * 60ms); }
.mobile-menu.open li { opacity: 1; transform: none; }

/* ---------- Reveal ---------- */
.js .reveal { opacity: 0; transform: translateY(28px); filter: blur(6px); transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out), filter 0.9s var(--ease-out); transition-delay: calc(var(--i, 0) * 90ms); }
.js .reveal.in { opacity: 1; transform: none; filter: none; }
.hero-in { animation: heroIn 1s var(--ease-out) both; animation-delay: calc(var(--d, 0) * 120ms + 100ms); }
@keyframes heroIn { from { opacity: 0; transform: translateY(24px); filter: blur(8px); } to { opacity: 1; transform: none; filter: none; } }

/* ---------- Hero: centered copy, the live editor under it ---------- */
.hero { position: relative; padding-top: clamp(112px, 11vw, 144px); padding-bottom: clamp(72px, 9vw, 120px); isolation: isolate; overflow-x: clip; }
.hero-glow {
  --orb-a: rgba(200, 242, 60, 0.15); --orb-b: rgba(226, 255, 140, 0.10);
  position: absolute; inset: 0; z-index: -1; pointer-events: none; overflow: hidden;
  background:
    radial-gradient(50% 36% at 50% 0%, rgba(200, 242, 60, 0.07), transparent 72%),
    radial-gradient(56% 40% at 50% 72%, var(--glow), transparent 72%);
}
/* Two soft lights drifting slowly on either side of the headline, out of step, so the background never sits still. */
.hero-glow::before, .hero-glow::after {
  content: ""; position: absolute; width: clamp(420px, 52vw, 820px); aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(circle at center, var(--orb-a), transparent 66%);
  will-change: transform;
}
.hero-glow::before { top: -14%; left: -16%; animation: hero-orb-a 22s ease-in-out infinite alternate; }
.hero-glow::after { top: 4%; right: -18%; background: radial-gradient(circle at center, var(--orb-b), transparent 66%); animation: hero-orb-b 28s ease-in-out infinite alternate; }
@keyframes hero-orb-a {
  0% { transform: translate3d(0, 0, 0) scale(1); opacity: 0.7; }
  50% { transform: translate3d(9vw, 7vh, 0) scale(1.12); opacity: 1; }
  100% { transform: translate3d(3vw, 16vh, 0) scale(0.94); opacity: 0.8; }
}
@keyframes hero-orb-b {
  0% { transform: translate3d(0, 0, 0) scale(1.06); opacity: 1; }
  50% { transform: translate3d(-8vw, 12vh, 0) scale(0.92); opacity: 0.7; }
  100% { transform: translate3d(-3vw, -4vh, 0) scale(1.14); opacity: 0.95; }
}
[data-theme="light"] .hero-glow { --orb-a: rgba(111, 168, 0, 0.12); --orb-b: rgba(200, 242, 60, 0.18); }
@media (prefers-reduced-motion: reduce) { .hero-glow::before, .hero-glow::after { animation: none; } }
.hero-copy { position: relative; z-index: 2; display: flex; flex-direction: column; align-items: center; text-align: center; }
.hero-copy h1 { margin-top: 2px; }
.hero-copy .lede { margin: 26px auto 0; max-width: 50ch; }
.hero-copy .eyebrow { display: inline-flex; align-items: center; gap: 9px; }
.hero-copy .cta-row { justify-content: center; }
/* Platforms under the CTAs: Mac ships now, Windows is on the way. */
.hero-platforms { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px 18px; margin-top: 22px; font-size: 14px; color: var(--muted); }
.hp-now, .hp-soon { display: inline-flex; align-items: center; gap: 8px; }
.hp-now { color: var(--text); }
.hp-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent-text); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent-text) 22%, transparent); }
.hp-soon em { font-style: normal; font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; padding: 3px 8px; border-radius: 999px; border: 1px dashed var(--line-2); color: var(--muted); }
.hero-eyebrow-icon { width: 18px; height: 18px; flex: none; opacity: 0.92; }
.hero-copy .eyebrow::before { display: none; }
@media (max-width: 480px) {
  /* The longer eyebrow wraps to two centered lines on phones instead of squeezing beside the icon. */
  .hero-copy .eyebrow { display: block; text-align: center; line-height: 1.8; text-wrap: balance; }
  .hero-eyebrow-icon { display: inline-block; margin-right: 8px; vertical-align: -3px; }
}
.hero .hero-studio { padding: 0; margin-top: clamp(52px, 5.5vw, 72px); }
/* Hint tab riding the editor's top border, so the editor reads as something to use, not a screenshot. */
.studio-live {
  position: absolute; z-index: 4; top: 0; left: 50%; transform: translate(-50%, -50%);
  display: inline-flex; align-items: center; gap: 10px; margin: 0; padding: 9px 18px 9px 14px; white-space: nowrap;
  border-radius: 999px; border: 1px solid color-mix(in srgb, var(--accent-text) 55%, transparent);
  background: color-mix(in srgb, var(--surface) 92%, var(--accent) 8%); color: var(--muted); font-size: 14px; line-height: 1;
  box-shadow: 0 0 0 4px var(--bg), 0 10px 36px -8px var(--glow);
}
.studio-live-dot { position: relative; width: 8px; height: 8px; border-radius: 50%; background: var(--accent-text); }
.studio-live-dot::after { content: ""; position: absolute; inset: 0; border-radius: inherit; background: inherit; animation: live-ping 1.8s var(--ease-out) infinite; }
@keyframes live-ping { from { transform: scale(1); opacity: 0.7; } to { transform: scale(2.8); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .studio-live-dot::after { animation: none; } }
/* The live editor's section around the editor itself (the editor's own styles are in editor.css, loaded at 768px+). */
.studio { position: relative; padding: clamp(56px, 7vw, 104px) 0 clamp(72px, 9vw, 128px); }
.studio-frame { width: min(1440px, calc(100vw - 2 * var(--gutter))); margin: 0 auto; }
.studio-tools { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-top: 18px; }
.studio-tries { display: flex; flex-wrap: wrap; gap: 8px; }
.studio-tries button, .studio-fs {
  display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 14px; border-radius: 999px;
  border: 1px solid var(--line-2); background: var(--surface); color: var(--text); font-size: 14px; cursor: pointer;
  transition: border-color 0.2s, background-color 0.2s, transform 0.2s var(--ease);
}
.studio-tries button:hover, .studio-fs:hover { border-color: var(--accent-text); }
.studio-tries button:active, .studio-fs:active { transform: scale(0.97); }
.studio-tries .i, .studio-fs .i { color: var(--accent-text); }
.studio-keys { color: var(--muted); font-size: 13.5px; }
.studio-keys kbd { font-family: var(--font-mono); font-size: 12px; padding: 1px 6px; border-radius: 5px; border: 1px solid var(--line-2); background: var(--surface); color: var(--text); }
.studio-small-note { display: none; margin-top: 12px; color: var(--muted); font-size: 14px; }
.studio-frame:has([data-live-editor].is-small) .studio-small-note { display: block; }

.studio-camera-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 20px; margin-bottom: 14px; }
.studio-cams { display: flex; flex-wrap: wrap; gap: 8px; }
.studio-cam {
  height: 34px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--surface);
  color: var(--muted); font-size: 13px; font-weight: 600; cursor: pointer; font-family: inherit;
  transition: border-color 0.2s, background-color 0.2s, color 0.2s, transform 0.2s var(--ease);
}
.studio-cam:hover { border-color: var(--accent-text); color: var(--text); }
.studio-cam:active { transform: scale(0.97); }
.studio-cam.on { border-color: var(--accent-text); background: color-mix(in srgb, var(--accent-text) 16%, var(--surface)); color: var(--text); }
.studio-cam-caption { flex: 1 1 260px; min-height: 20px; margin: 0; color: var(--muted); font-size: 14px; max-width: 56ch; text-align: right; transition: opacity 0.2s var(--ease); }

.studio-stage { position: relative; }
.studio-glow {
  position: absolute; left: 10%; right: 10%; bottom: -5%; height: 80px; z-index: 0; pointer-events: none;
  background: radial-gradient(ellipse at center, color-mix(in srgb, var(--accent-text) 55%, transparent) 0%, transparent 72%);
  filter: blur(20px); opacity: 0.32;
}
.studio-window { position: relative; z-index: 1; }
.studio-cam-clip { position: relative; overflow: hidden; border-radius: 13px; box-shadow: 0 0 0 1px color-mix(in srgb, var(--line-2) 70%, transparent); }
[data-live-editor] { position: relative; width: 100%; transform-origin: 0 0; transition: transform 0.7s var(--ease); }
/* Hold the editor's 1440×860 space before editor.js draws it, so nothing below jumps when it appears. */
@media (min-width: 768px) { [data-live-editor]:not(:fullscreen) { aspect-ratio: 1440 / 860; } }

/* Phones: a still of the editor window instead of the live copy (editor.js does not boot below 768px). */
.studio-still, .studio-still-note { display: none; }
@media (max-width: 767px) {
  .studio-camera-bar, .studio-window, .studio-tools, .studio-small-note { display: none; }
  .studio-still { display: block; position: relative; z-index: 1; width: 100%; height: auto; border-radius: 10px; box-shadow: 0 0 0 1px color-mix(in srgb, var(--line-2) 70%, transparent); }
  .studio-still-note { display: block; margin-top: 14px; color: var(--muted); font-size: 14px; }
}

.studio-callouts { position: absolute; inset: 0; z-index: 2; pointer-events: none; display: none; overflow: visible; }
.studio-callout {
  position: absolute; bottom: 100%; margin-bottom: 10px; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 5px; opacity: 0; transition: opacity 0.3s var(--ease);
}
.studio-callout-label {
  padding: 6px 11px; border-radius: 999px; background: var(--section); border: 1px solid var(--line-2); color: var(--text);
  font-size: 12px; font-weight: 600; white-space: nowrap; box-shadow: 0 10px 24px -14px rgba(0, 0, 0, 0.5);
}
.studio-callout-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent-text); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent-text) 22%, transparent); }
.studio-window.is-whole .studio-callout { opacity: 1; }
@media (min-width: 1040px) {
  .studio-callouts { display: block; }
  .studio-stage { margin-top: 54px; }
}

@media (max-width: 640px) {
  .studio-camera-bar { gap: 8px; }
  .studio-cam-caption { text-align: left; }
  .studio-cams { gap: 6px; }
  .studio-cam { height: 30px; padding: 0 11px; font-size: 12.5px; }
}

@media (prefers-reduced-motion: reduce) {
  [data-live-editor] { transition: none; }
}
/* In the hero the stage leads, the camera chips sit under it, and the region callouts stay off so the editor reads cleanly. */
.hero-studio .studio-stage { margin-top: 0; }
.hero-studio .studio-callouts { display: none; }
.hero-studio .studio-camera-bar { margin: 18px 0 0; }
.hero-studio .studio-cam-clip { box-shadow: 0 0 0 1px color-mix(in srgb, var(--line-2) 70%, transparent), 0 50px 160px -40px rgba(200, 242, 60, 0.38), 0 30px 80px -30px var(--shadow); }
@media (max-width: 767px) {
  /* Phones get a still image of the editor instead of the live copy, so the tab would promise something they can't do. */
  .studio-live { display: none; }
}

/* ---------- Engines ---------- */
.engines { position: relative; padding-block: var(--section); overflow: hidden; }
.engines-bg {
  position: absolute; inset: 0; pointer-events: none; z-index: 0;
  background:
    radial-gradient(44% 48% at 82% 18%, var(--glow), transparent 70%),
    radial-gradient(36% 42% at 6% 92%, rgba(200, 242, 60, 0.06), transparent 70%),
    repeating-linear-gradient(to right, var(--line) 0 1px, transparent 1px 64px),
    repeating-linear-gradient(to bottom, var(--line) 0 1px, transparent 1px 64px);
  -webkit-mask-image: radial-gradient(90% 90% at 50% 40%, #000, transparent 95%);
  mask-image: radial-gradient(90% 90% at 50% 40%, #000, transparent 95%);
  opacity: 0.6;
}
.engines .container { position: relative; z-index: 1; }
.engines-top { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
.engines-copy .body-lg { margin-top: 14px; max-width: 46ch; }
.engine-tabs { display: grid; grid-template-columns: repeat(2, max-content); gap: 10px; margin-top: clamp(28px, 4vw, 40px); }
.engine-tab {
  display: inline-flex; align-items: center; gap: 9px; padding: 11px 18px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--line-2); color: var(--text); font-weight: 600; font-size: 15px;
  cursor: pointer; transition: border-color 0.3s var(--ease), background-color 0.3s var(--ease), transform 0.3s var(--spring);
}
.engine-tab:hover { border-color: var(--accent-text); }
.engine-tab:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
/* Each tool's own logo sits on a small white disc, so every mark reads on dark, light and the lime selected tab. */
.engine-tab:has(.ai-logo) { padding-left: 7px; }
.ai-logo { display: grid; place-items: center; width: 28px; height: 28px; flex: none; border-radius: 50%; background: #fff; box-shadow: 0 0 0 1px rgba(19, 22, 15, 0.08); }
.ai-logo img { width: 18px; height: 18px; }
.engine-tab[aria-selected="true"] { background: var(--accent); border-color: var(--accent); color: var(--on-accent); transform: translateY(-1px); }
.engine-tab[aria-selected="true"] .ai-logo { box-shadow: 0 0 0 1px rgba(19, 22, 15, 0.12), 0 2px 8px rgba(19, 22, 15, 0.18); }
.engines-visual {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: clamp(20px, 3vw, 36px); align-items: center;
  padding: clamp(20px, 3vw, 32px); border-radius: var(--r-card); border: 1px solid var(--line); background: var(--surface);
}
.engine-connect { position: relative; width: 100%; aspect-ratio: 1; min-height: 300px; max-width: 320px; margin-inline: auto; }
.engine-lines { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.engine-lines path { fill: none; stroke: var(--line-2); stroke-width: 1.2; stroke-dasharray: 4 6; opacity: 0.45; vector-effect: non-scaling-stroke; transition: stroke 0.4s var(--ease), opacity 0.4s var(--ease), filter 0.4s var(--ease); }
.engine-lines path.on { stroke: var(--accent-display); opacity: 1; filter: drop-shadow(0 0 5px rgba(200, 242, 60, 0.6)); }
.js .engine-lines path.on { animation: dash 1.6s linear infinite; }
@keyframes dash { to { stroke-dashoffset: -20; } }
.engine-core {
  position: absolute; left: 50%; top: 50%; width: 34%; aspect-ratio: 1; transform: translate(-50%, -50%); z-index: 2;
  display: grid; place-items: center; border-radius: 30%;
  background: radial-gradient(circle at 30% 20%, #1d2312, #08090a 70%); border: 1px solid rgba(200, 242, 60, 0.25);
  box-shadow: 0 0 0 10px var(--bg), 0 0 0 11px var(--line), 0 30px 80px -20px rgba(200, 242, 60, 0.35);
  transition: box-shadow 0.5s var(--ease);
}
.engine-connect.on .engine-core { box-shadow: 0 0 0 10px var(--bg), 0 0 0 11px var(--line), 0 0 60px -6px rgba(200, 242, 60, 0.55); }
.engine-core img { width: 52%; height: auto; }
.engine-nodes { position: absolute; inset: 0; z-index: 3; }
.engine-node {
  position: absolute; display: inline-flex; align-items: center; gap: 6px; padding: 7px 13px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--line-2); color: var(--muted); font-weight: 600; font-size: 12.5px; white-space: nowrap;
  cursor: pointer; opacity: 0.55; transition: opacity 0.4s var(--ease), border-color 0.4s var(--ease), color 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.engine-node img { width: 16px; height: 16px; flex: none; }
.engine-node:nth-child(1) { left: 15%; top: 17.5%; translate: -50% -50%; }
.engine-node:nth-child(2) { left: 85%; top: 17.5%; translate: -50% -50%; }
.engine-node:nth-child(3) { left: 15%; top: 82.5%; translate: -50% -50%; }
.engine-node:nth-child(4) { left: 85%; top: 82.5%; translate: -50% -50%; }
.engine-node.on { opacity: 1; border-color: var(--accent); color: var(--text); box-shadow: 0 0 0 1px var(--accent), 0 0 16px rgba(200, 242, 60, 0.45); }
.engine-detail { min-width: 0; }
.ed-eyebrow { font-family: var(--font-mono); font-size: 12.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.engine-detail h3 { display: flex; align-items: center; gap: 12px; font-family: var(--font-display); font-weight: 700; font-size: clamp(26px, 2.4vw, 34px); line-height: 1; margin-bottom: 18px; }
.ed-logo { width: 28px; height: 28px; flex: none; }
.engine-detail dl { display: grid; gap: 14px; }
.engine-detail dl div { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 12px; align-items: baseline; }
.engine-detail dt { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.04em; text-transform: uppercase; color: var(--muted); }
.engine-detail dd { font-size: 15px; }
.engines-bottom { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: clamp(20px, 3vw, 32px); margin-top: clamp(28px, 4vw, 44px); }
/* The terminal and usage meter follow the page theme: app-dark on the dark page, light surfaces with olive accents on the light one. */
.engine-terminal, .engine-meter {
  --card-row: rgba(255, 255, 255, 0.04); --card-track: rgba(255, 255, 255, 0.07); --card-accent: var(--lime);
  border-radius: var(--r-card); background: var(--app-bg); color: var(--app-text); border: 1px solid var(--app-line);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05); overflow: hidden;
}
[data-theme="light"] :is(.engine-terminal, .engine-meter) {
  --app-bg: var(--surface); --app-text: var(--text); --app-muted: var(--muted); --app-line: var(--line-2);
  --card-row: var(--surface-2); --card-track: rgba(19, 22, 15, 0.08); --card-accent: var(--accent-text);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.8) inset, 0 18px 50px -30px var(--shadow);
}
.et-head { display: flex; align-items: center; gap: 8px; padding: 14px 18px; border-bottom: 1px solid var(--app-line); }
.et-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--app-line); }
.et-title { display: inline-flex; align-items: center; gap: 8px; margin-left: 8px; font-family: var(--font-mono); font-size: 13px; color: var(--app-muted); }
.et-title .i { width: 15px; height: 15px; color: var(--card-accent); }
.et-logo { width: 16px; height: 16px; flex: none; }
.um-engine { display: inline-flex; align-items: center; gap: 7px; }
.et-body { padding: 20px 22px 22px; }
.et-line { font-family: var(--font-mono); font-size: 15px; min-height: 1.4em; }
.et-prompt { color: var(--card-accent); margin-right: 10px; }
.et-caret { display: inline-block; width: 8px; height: 1.1em; margin-left: 3px; background: var(--card-accent); vertical-align: -0.18em; animation: et-blink 1s step-end infinite; }
@keyframes et-blink { 50% { opacity: 0; } }
.et-tools { display: flex; flex-direction: column; gap: 10px; margin-top: 20px; }
.et-tools span {
  display: flex; align-items: center; gap: 10px; padding: 13px 16px; border-radius: var(--r-ui);
  background: var(--card-row); border: 1px solid var(--app-line); font-weight: 600; font-size: 14.5px;
  opacity: 0; transform: translateY(6px); transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
}
.et-tools span.show { opacity: 1; transform: none; }
.et-tools .i { color: var(--card-accent); width: 16px; height: 16px; }
.et-tools code { margin-left: auto; font-weight: 400; font-size: 12px; color: var(--app-muted); }
.et-done {
  margin-top: 14px; font-family: var(--font-mono); font-size: 13px; color: var(--app-muted);
  opacity: 0; transition: opacity 0.5s var(--ease);
}
.et-done.show { opacity: 1; }
/* Usage meter: a second app panel beside the terminal, with flat lime bars like the app's own readouts. */
.engine-meter { display: flex; flex-direction: column; height: 100%; }
.um-body { flex: 1; display: flex; flex-direction: column; gap: 22px; padding: 20px 22px 22px; }
.um-label { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--app-muted); }
.um-value { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-top: 6px; }
.um-value strong { font-family: var(--font-display); font-weight: 700; font-size: clamp(56px, 6vw, 72px); line-height: 0.8; color: var(--app-text); font-variant-numeric: tabular-nums; }
.um-value span { font-family: var(--font-mono); font-size: 12.5px; color: var(--app-muted); }
.um-bar { position: relative; height: 6px; border-radius: 999px; background: var(--card-track); overflow: hidden; }
.um-bar-lg { height: 10px; margin-top: 16px; }
.um-bar i {
  position: absolute; inset: 0; border-radius: inherit; background: var(--lime); transform-origin: 0 50%;
  transform: scaleX(var(--p, 0)); transition: transform 1s var(--ease-out);
}
[data-theme="dark"] .um-bar-lg i { box-shadow: 0 0 14px rgba(200, 242, 60, 0.45); }
[data-theme="light"] .um-bar i { background: linear-gradient(90deg, var(--accent-display), var(--lime)); }
.um-rows { display: flex; flex-direction: column; gap: 10px; }
.um-row {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 10px 12px;
  padding: 13px 16px; border-radius: var(--r-ui); background: var(--card-row); border: 1px solid var(--app-line);
}
.um-row .um-bar { grid-column: 1 / -1; height: 4px; }
.um-row-label { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; font-size: 14.5px; }
.um-row-label .i { width: 16px; height: 16px; color: var(--card-accent); }
.um-row code { font-size: 12px; color: var(--app-muted); font-variant-numeric: tabular-nums; }
.um-note { margin-top: auto; font-size: 14px; line-height: 1.5; color: var(--app-muted); }
.um-note span { display: block; margin-top: 6px; font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.04em; text-transform: uppercase; opacity: 0.75; }
@media (max-width: 900px) {
  .engines-top { grid-template-columns: minmax(0, 1fr); }
  .engines-visual { grid-template-columns: minmax(0, 1fr); justify-items: center; text-align: center; }
  .engine-detail dl div { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .engines-bottom { grid-template-columns: minmax(0, 1fr); }
  .engine-meter { height: auto; }
}
@media (max-width: 640px) {
  .engine-tabs { gap: 8px; }
  .engine-tab { padding: 10px 14px; font-size: 14px; }
  .engine-node { padding: 6px 10px; font-size: 11.5px; }
}
@media (prefers-reduced-motion: reduce) {
  .et-caret { animation: none; opacity: 1; }
  .et-tools span { opacity: 1; transform: none; transition: none; }
  .et-done { opacity: 1; transition: none; }
  .um-bar i { transition: none; }
}

/* ---------- How it works ---------- */
.how { padding-block: var(--section); background: linear-gradient(var(--bg), var(--bg-raise) 30%, var(--bg-raise) 70%, var(--bg)); }
.how-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 6vw, 96px); }
.steps { display: flex; flex-direction: column; }
.step { min-height: 62vh; display: flex; flex-direction: column; justify-content: center; padding-block: 24px; opacity: 0.32; transition: opacity 0.6s var(--ease); }
.step.active { opacity: 1; }
.step-n {
  display: grid; place-items: center; width: 44px; height: 44px; border-radius: 999px; margin-bottom: 22px;
  font-family: var(--font-mono); font-size: 14px; border: 1px solid var(--line-2); transition: background-color 0.5s, color 0.5s, border-color 0.5s;
}
.step.active .step-n { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.step h3 { font-family: var(--font-display); font-weight: 700; font-size: clamp(27px, 2.6vw, 40px); line-height: 1; text-wrap: balance; padding-bottom: 0.08em; }
.step p { margin-top: 18px; color: var(--muted); font-size: 17px; max-width: 42ch; }
.how-visual {
  position: sticky; top: calc(50vh - 340px); height: 680px; align-self: start; margin-top: calc(31vh - 340px);
  border-radius: var(--r-card); padding: 10px; background: var(--line); border: 1px solid var(--line);
}
.panel {
  position: absolute; inset: 10px; border-radius: var(--r-inner); background: var(--app-bg); color: var(--app-text);
  border: 1px solid rgba(237, 239, 232, 0.08); padding: 30px; overflow: hidden;
  opacity: 0; transform: translateY(24px) scale(0.97); transition: opacity 0.6s var(--ease), transform 0.8s var(--ease);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}
.panel.active { opacity: 1; transform: none; }
.panel-title { font-family: var(--font-mono); font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--app-muted); margin: 4px 0 14px; }
.bin { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 26px; }
.bin figure, .looks-mini figure { border-radius: var(--r-ui); overflow: hidden; background: #000; border: 1px solid var(--app-line); }
.bin img { aspect-ratio: 16 / 10; width: 100%; object-fit: cover; }
.bin figcaption, .looks-mini figcaption { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; padding: 10px 12px; font-size: 13px; background: var(--app-panel); font-family: var(--font-mono); }
.bin figcaption span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.bin figcaption em { flex: none; font-style: normal; color: var(--app-muted); }
.looks-mini { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.looks-mini img { aspect-ratio: 3 / 2; width: 100%; object-fit: cover; }
.looks-mini figcaption { font-family: var(--font-text); }
.looks-mini .on { border-color: var(--lime); box-shadow: 0 0 0 1px var(--lime), 0 0 24px -6px rgba(200, 242, 60, 0.6); }
.refs { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.refs span { display: inline-flex; align-items: center; gap: 7px; padding: 8px 14px; border-radius: 999px; border: 1px dashed rgba(200, 242, 60, 0.5); font-size: 13.5px; color: var(--app-text); }
.refs .i { color: var(--lime); }
.bubble { margin-left: auto; max-width: 88%; padding: 16px 18px; border-radius: 16px 16px 4px 16px; background: rgba(200, 242, 60, 0.12); border: 1px solid rgba(200, 242, 60, 0.3); font-size: 17px; }
.mini-tools { display: flex; flex-direction: column; gap: 10px; margin-top: 26px; }
.mini-tools span { display: flex; align-items: center; gap: 10px; padding: 13px 16px; border-radius: var(--r-ui); background: rgba(255, 255, 255, 0.04); border: 1px solid var(--app-line); font-weight: 600; font-size: 15px; }
.mini-tools .i { color: var(--lime); }
.mini-tools code { margin-left: auto; font-weight: 400; font-size: 12.5px; color: var(--app-muted); }
.grid-check { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; align-items: center; margin-top: 26px; }
.frames { grid-template-columns: repeat(9, 1fr); gap: 3px; padding: 6px; border-radius: 10px; background: rgba(255, 255, 255, 0.035); border: 1px solid var(--app-line); }
.frames i { aspect-ratio: 9 / 16; border-radius: 3px; background: url("../img/interview-vertical-240.webp") center 30% / cover; filter: saturate(0.9); }
.frames i:nth-child(2n) { background-position: center 22%; }
.frames i:nth-child(3n) { background-size: 140%; }
.frames.static { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; }
.frames.static i { aspect-ratio: 1; }
.grid-check p { font-size: 15px; color: var(--app-muted); }
.checks { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 26px; }
.checks li { display: flex; align-items: center; gap: 8px; padding: 13px 16px; border-radius: var(--r-ui); background: rgba(255, 255, 255, 0.04); border: 1px solid var(--app-line); font-size: 15px; }
.checks .i { color: var(--lime); }
.formats { display: flex; align-items: flex-end; gap: 16px; margin-bottom: 20px; }
.formats span { display: grid; place-items: center; border-radius: 10px; border: 1px solid var(--app-line); font-family: var(--font-mono); font-size: 13px; color: var(--app-muted); background: rgba(255, 255, 255, 0.03); }
.f169 { width: 156px; height: 88px; } .f916 { width: 70px; height: 124px; } .f11 { width: 100px; height: 100px; }
.formats .on, .codecs .on { border-color: var(--lime); color: var(--lime); background: rgba(200, 242, 60, 0.08); }
.codecs { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 22px; }
.codecs span { padding: 8px 15px; border-radius: 999px; border: 1px solid var(--app-line); font-size: 13.5px; font-family: var(--font-mono); }
.publish { display: inline-flex; align-items: center; gap: 8px; padding: 13px 20px; border-radius: 999px; background: var(--lime); color: var(--ink); font-weight: 600; font-size: 15px; }
@media (max-width: 900px) {
  .how-grid { grid-template-columns: minmax(0, 1fr); gap: 48px; }
  .how-visual { position: sticky; top: 88px; height: 460px; margin-top: 0; order: -1; z-index: 2; background: var(--bg-raise); }
  .step { min-height: 52vh; }
}
@media (max-width: 640px) {
  .how-visual { height: 460px; }
  .panel { padding: 14px; }
  .panel-title { font-size: 11px; margin: 2px 0 8px; }
  .bin { gap: 8px; margin-bottom: 12px; }
  .bin figcaption, .looks-mini figcaption { padding: 6px 8px; font-size: 10.5px; }
  .looks-mini { gap: 8px; }
  .refs { gap: 6px; margin-top: 10px; }
  .refs span { padding: 5px 10px; font-size: 11px; }
  .bubble { padding: 10px 12px; max-width: 92%; font-size: 13.5px; border-radius: 12px 12px 4px 12px; }
  .mini-tools { gap: 6px; margin-top: 12px; }
  .mini-tools span { padding: 9px 11px; font-size: 12.5px; }
  .mini-tools code { font-size: 10.5px; }
  .grid-check { gap: 10px; margin-top: 12px; }
  .frames.static { gap: 3px; }
  .grid-check p { font-size: 11.5px; }
  .checks { grid-template-columns: 1fr; gap: 6px; margin-bottom: 12px; }
  .checks li { padding: 8px 10px; font-size: 11.5px; }
  .formats { gap: 8px; margin-bottom: 10px; }
  .f169 { width: 84px; height: 47px; } .f916 { width: 38px; height: 67px; } .f11 { width: 54px; height: 54px; }
  .codecs { gap: 6px; margin-bottom: 10px; }
  .codecs span { padding: 5px 10px; font-size: 11px; }
  .publish { padding: 9px 14px; font-size: 12.5px; }
}

/* ---------- Agents and skills (team-illo.js) ---------- */
.team { padding-block: var(--section); }
.team-head { margin-bottom: clamp(40px, 5vw, 64px); }
.team-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
/* Two rows per card through subgrid, so both illustrations and both captions line up. */
.team-card {
  position: relative; display: grid; grid-row: span 2; grid-template-rows: subgrid; row-gap: 0; align-content: start;
  padding: 10px 10px 28px; border-radius: var(--r-card);
  background: var(--surface); border: 1px solid var(--line); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}
.team-copy { margin: 24px 16px 0; }
.team-kicker { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent-text); }
.team-copy h3 { font-family: var(--font-display); font-weight: 700; font-size: clamp(30px, 2.6vw, 38px); line-height: 0.95; margin-top: 12px; text-wrap: balance; padding-bottom: 0.08em; }
.team-copy p:not(.team-kicker) { margin-top: 12px; color: var(--muted); font-size: 15.5px; max-width: 50ch; }

/* The illustrations follow the page theme: app-dark on the dark page; on the light page, pale panels with olive in place of
   lime wherever lime is text, an icon or an outline (lime fills stay lime). */
.team-art {
  --art-accent: var(--lime); --art-soft: rgba(200, 242, 60, 0.12); --art-glow: rgba(200, 242, 60, 0.6);
  --art-chip: rgba(237, 239, 232, 0.08); --art-dash: rgba(237, 239, 232, 0.18); --art-toggle: rgba(237, 239, 232, 0.14); --art-knob: var(--app-text); --art-file: #1b2015;
  position: relative; display: flex; flex-direction: column; gap: 12px; min-height: 430px; padding: 18px;
  border-radius: var(--r-inner); background: var(--app-bg); color: var(--app-text); border: 1px solid var(--app-line);
  font-size: 12px; line-height: 1.35; overflow: hidden; container-type: inline-size;
}
[data-theme="light"] .team-art {
  --app-bg: var(--bg); --app-panel: var(--surface); --app-text: var(--text); --app-muted: var(--muted); --app-line: var(--line-2);
  --art-accent: var(--accent-text); --art-soft: rgba(111, 168, 0, 0.12); --art-glow: rgba(79, 138, 0, 0.35);
  --art-chip: rgba(19, 22, 15, 0.06); --art-dash: rgba(19, 22, 15, 0.22); --art-toggle: rgba(19, 22, 15, 0.14); --art-knob: #fff; --art-file: var(--surface);
}
.team-art .i { width: 16px; height: 16px; }

/* Ours: prompt, roster, skills, report */
.to-prompt { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 8px 14px 8px 8px; border-radius: 999px; background: var(--app-panel); border: 1px solid var(--app-line); }
.to-you { flex: none; padding: 4px 10px; border-radius: 999px; background: var(--art-chip); font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--app-muted); }
.to-text { min-width: 0; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.to-typed .tag { color: var(--art-accent); font-family: var(--font-mono); font-size: 12px; }
.to-caret { display: inline-block; width: 1.5px; height: 1.05em; margin-left: 2px; vertical-align: -0.15em; background: var(--art-accent); animation: to-blink 1s steps(1) infinite; }
@keyframes to-blink { 50% { opacity: 0; } }

.to-roster { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.to-roster li {
  position: relative; display: flex; flex-direction: column; gap: 3px; padding: 11px 10px 10px; border-radius: var(--r-ui);
  background: var(--app-panel); border: 1px solid var(--app-line);
  transition: border-color 0.4s var(--ease), box-shadow 0.4s var(--ease), opacity 0.4s var(--ease), transform 0.5s var(--spring);
}
.to-roster .i { width: 18px; height: 18px; margin-bottom: 4px; color: var(--app-muted); transition: color 0.4s; }
.to-roster b { font-size: 12px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.to-roster small { font-size: 10.5px; color: var(--app-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.to-roster li::after {
  content: ""; position: absolute; top: 10px; right: 10px; width: 7px; height: 7px; border-radius: 50%;
  background: var(--lime); opacity: 0; transform: scale(0.4); transition: opacity 0.3s, transform 0.4s var(--spring);
}
.team-ours.has-focus .to-roster li { opacity: 0.42; }
.team-ours .to-roster li.is-on { opacity: 1; border-color: var(--art-accent); box-shadow: 0 0 0 3px var(--art-soft), 0 18px 40px -22px var(--art-glow); transform: translateY(-3px); }
.to-roster li.is-on .i { color: var(--art-accent); }
.to-roster li.is-on::after { opacity: 1; transform: none; animation: to-pulse 1.1s var(--ease) infinite; }
.to-roster li.is-done::after { animation: none; }
@keyframes to-pulse { 50% { box-shadow: 0 0 0 5px var(--art-soft); } }

.to-skills { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.to-label { margin-right: 4px; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--app-muted); }
.to-skills span[data-skill] {
  padding: 4px 9px; border-radius: 999px; border: 1px dashed var(--art-dash); color: var(--app-muted);
  font-family: var(--font-mono); font-size: 10.5px; transition: background-color 0.35s, border-color 0.35s, color 0.35s;
}
.to-skills span.is-on { border-style: solid; border-color: var(--art-accent); background: var(--art-soft); color: var(--art-accent); }

.to-report {
  display: flex; align-items: center; gap: 10px; margin-top: auto; min-height: 44px; padding: 10px 14px; border-radius: var(--r-ui);
  background: var(--app-panel); border: 1px solid var(--app-line); border-left: 2px solid var(--art-accent); font-size: 12.5px;
  opacity: 0; transform: translateY(8px); transition: opacity 0.45s var(--ease), transform 0.6s var(--ease);
}
.to-report .i { color: var(--art-accent); }
.to-report.is-in { opacity: 1; transform: none; }

/* Yours: sources, files dropping in, the team list, the toast */
.ty-sources { display: flex; gap: 8px; }
.ty-src {
  flex: 1 1 0; min-width: 0; display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 36px; padding: 0 10px;
  border-radius: 999px; background: var(--app-panel); border: 1px solid var(--app-line); color: var(--app-muted); font-size: 12px; font-weight: 500;
  white-space: nowrap; transition: border-color 0.35s, color 0.35s;
}
.ty-src.is-on { border-color: var(--art-accent); color: var(--app-text); }
.ty-src.is-on .i { color: var(--art-accent); }
.ty-logo { width: 15px; height: 15px; flex: none; }

.ty-stage { position: relative; height: 54px; }
.ty-file {
  position: absolute; top: 10px; left: calc(50% + var(--fx)); display: inline-flex; align-items: center; gap: 7px; max-width: 48%;
  padding: 7px 11px; border-radius: 10px; background: var(--art-file); border: 1px solid color-mix(in srgb, var(--art-accent) 45%, transparent);
  font-family: var(--font-mono); font-size: 11px; white-space: nowrap; box-shadow: 0 14px 30px -14px var(--shadow);
  opacity: 0; transform: translate(-50%, -14px) scale(0.92);
}
.ty-file .i { flex: none; color: var(--art-accent); }
.ty-file.is-out { opacity: 1; transform: translate(-50%, 0); transition: opacity 0.35s var(--ease), transform 0.5s var(--spring); }
.ty-file.is-drop { left: 50%; opacity: 0; transform: translate(-50%, 92px) scale(0.7); transition: left 0.6s var(--ease), opacity 0.5s 0.15s var(--ease), transform 0.65s var(--ease); }

.ty-drop {
  position: relative; display: flex; flex-direction: column; gap: 10px; padding: 14px; border-radius: 14px;
  border: 1.5px dashed var(--art-dash); transition: border-color 0.3s, background-color 0.3s;
}
.ty-drop.is-hot { border-color: var(--art-accent); background: color-mix(in srgb, var(--art-soft) 45%, transparent); }
.ty-drop-label { display: inline-flex; align-items: center; justify-content: center; gap: 7px; color: var(--app-muted); font-size: 12px; font-weight: 500; }
.ty-drop.is-hot .ty-drop-label { color: var(--art-accent); }
.ty-list { list-style: none; display: grid; gap: 8px; }
.ty-list li {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; grid-template-rows: auto auto; column-gap: 11px; align-items: center;
  padding: 10px 12px; border-radius: var(--r-ui); background: var(--app-panel); border: 1px solid var(--app-line);
  opacity: 0; transform: translateY(10px) scale(0.98); transition: opacity 0.4s var(--ease), transform 0.55s var(--spring);
}
.ty-list li.is-in { opacity: 1; transform: none; }
.ty-list .i { grid-row: 1 / 3; width: 18px; height: 18px; color: var(--art-accent); }
.ty-list b { font-size: 12.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ty-list em { grid-column: 2; font-style: normal; font-size: 10.5px; color: var(--app-muted); font-family: var(--font-mono); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ty-toggle { grid-column: 3; grid-row: 1 / 3; position: relative; width: 30px; height: 18px; border-radius: 999px; background: var(--art-toggle); transition: background-color 0.3s; }
.ty-toggle::after { content: ""; position: absolute; top: 2px; left: 2px; width: 14px; height: 14px; border-radius: 50%; background: var(--art-knob); transition: transform 0.35s var(--spring); }
.ty-list li.is-on .ty-toggle { background: var(--lime); }
.ty-list li.is-on .ty-toggle::after { transform: translateX(12px); background: var(--ink); }

.ty-toast {
  display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: auto; min-height: 40px; padding: 9px 14px; border-radius: 999px;
  background: var(--art-soft); border: 1px solid color-mix(in srgb, var(--art-accent) 35%, transparent); color: var(--art-accent); font-size: 12.5px; font-weight: 500;
  opacity: 0; transform: translateY(8px); transition: opacity 0.45s var(--ease), transform 0.6s var(--spring);
}
.ty-toast.is-in { opacity: 1; transform: none; }

/* Points and the provider note */
.team-points { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin-top: clamp(36px, 4vw, 56px); }
.team-points li { padding: 22px 24px; border-radius: var(--r-card); border: 1px solid var(--line); }
.team-points .i { width: 24px; height: 24px; color: var(--accent-text); }
.team-points h3 { margin-top: 14px; font-size: 17px; font-weight: 600; }
.team-points p { margin-top: 6px; color: var(--muted); font-size: 15px; }
.team-note { margin-top: 22px; color: var(--muted); font-size: 13.5px; }

@media (max-width: 980px) {
  .team-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 760px) {
  .team-points { grid-template-columns: minmax(0, 1fr); gap: 12px; }
}
@media (max-width: 560px) {
  .team-art { min-height: 0; padding: 14px; }
  .to-report { margin-top: 0; }
  .ty-src .i { display: none; }
  .ty-file { --fx: 0% !important; max-width: 80%; }
  .ty-toast { margin-top: 0; }
}
/* Too narrow for four tiles a row: two a row, names only. */
@container (max-width: 500px) {
  .to-roster { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .to-roster small { display: none; }
}

/* ---------- Features bento ---------- */
.features { padding-block: var(--section); }
.bento {
  display: grid; gap: 16px; grid-template-columns: repeat(12, minmax(0, 1fr));
  grid-template-areas:
    "words words words words words words words cap cap cap cap cap"
    "undo undo undo undo frame frame frame cap cap cap cap cap"
    "sound sound sound sound sound tl tl tl tl tl tl tl";
}
.c-words { grid-area: words; } .c-captions { grid-area: cap; } .c-undo { grid-area: undo; }
.c-reframe { grid-area: frame; } .c-sound { grid-area: sound; } .c-timeline { grid-area: tl; }
.cell {
  position: relative; display: flex; flex-direction: column; padding: 10px 10px 26px; border-radius: var(--r-card);
  background: var(--surface); border: 1px solid var(--line); overflow: hidden; isolation: isolate;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}
.cell::before {
  content: ""; position: absolute; inset: 0; z-index: -1; opacity: 0; transition: opacity 0.4s;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), var(--glow), transparent 60%);
}
.cell:hover::before { opacity: 1; }
.cell h3 { font-family: var(--font-display); font-weight: 700; font-size: clamp(30px, 2.6vw, 38px); line-height: 0.95; margin: 22px 16px 0; text-wrap: balance; padding-bottom: 0.08em; }
.cell > p { margin: 14px 16px 0; color: var(--muted); font-size: 15.5px; max-width: 48ch; }
.cell-art { position: relative; border-radius: var(--r-inner); overflow: hidden; background: var(--surface-2); border: 1px solid var(--line); min-height: 200px; }

/* Try-it hint, shared */
.try-hint {
  position: absolute; top: 10px; right: 10px; z-index: 3; display: inline-flex; align-items: center; gap: 5px;
  padding: 5px 10px; border-radius: 999px; background: color-mix(in srgb, var(--ink) 55%, transparent); color: #fff;
  font-size: 11px; font-weight: 600; letter-spacing: 0.02em; pointer-events: none; opacity: 0; transition: opacity 0.3s;
  backdrop-filter: blur(6px);
}
.try-hint .i { width: 12px; height: 12px; }
.cell-art:hover .try-hint, .cell-art:focus-within .try-hint { opacity: 1; }

/* Shared demo buttons */
.demo-btn {
  font: inherit; font-family: var(--font-mono); font-size: 12.5px; cursor: pointer; border-radius: 999px;
  padding: 8px 14px; color: var(--text); background: var(--surface); border: 1px solid var(--line-2);
  display: inline-flex; align-items: center; gap: 6px; transition: background 0.2s, border-color 0.2s, transform 0.15s, opacity 0.2s;
}
.demo-btn:hover { border-color: var(--accent-display); }
.demo-btn:active { transform: scale(0.95); }
.demo-btn.ghost { color: var(--accent-text); border-color: var(--accent-display); }
.demo-btn:focus-visible { outline: 2px solid var(--accent-display); outline-offset: 2px; }
.demo-btn[aria-pressed="true"] { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.demo-btn:disabled { opacity: 0.45; cursor: default; }

/* Words */
.words { padding: 26px 26px; display: flex; flex-direction: column; justify-content: center; gap: 16px; background: linear-gradient(135deg, var(--surface-2), var(--bg-raise)); }
.words-text { font-size: clamp(17px, 1.6vw, 22px); line-height: 1.55; letter-spacing: -0.01em; }
.filler {
  all: unset; display: inline-block; cursor: pointer; position: relative; font: inherit; color: var(--accent-text);
  line-height: inherit; vertical-align: baseline;
  max-width: 40ch; white-space: pre-wrap; overflow: hidden;
  background: color-mix(in srgb, var(--accent-display) 10%, transparent);
  border-radius: 4px; padding: 0 3px; margin: 0 -3px;
  text-decoration: underline dotted color-mix(in srgb, var(--accent-display) 70%, transparent) 1.5px;
  text-underline-offset: 3px;
  transition: max-width 0.45s var(--ease) 0.35s, opacity 0.3s var(--ease) 0.35s, margin 0.45s var(--ease) 0.35s, padding 0.45s var(--ease) 0.35s, background 0.2s var(--ease), color 0.2s var(--ease);
}
.filler::after { content: ""; position: absolute; left: -2px; right: -2px; top: 54%; height: 2px; border-radius: 2px; background: var(--accent-display); transform: scaleX(0); transform-origin: left; transition: transform 0.3s var(--ease); }
.filler:hover, .filler:focus-visible { background: color-mix(in srgb, var(--accent-display) 22%, transparent); }
.filler:hover::after, .filler:focus-visible::after { transform: scaleX(1); opacity: 0.7; }
.filler:focus-visible { outline: 2px solid var(--accent-display); outline-offset: 2px; border-radius: 3px; }
.filler.long { font-family: var(--font-mono); font-size: 0.7em; padding: 0 8px; margin: 0; border-radius: 999px; border: 1px dashed var(--accent-display); text-decoration: none; color: var(--accent-text); }
.filler.cutting::after { transform: scaleX(1); opacity: 1; }
.filler.cutting { opacity: 0.4; color: var(--muted); background: transparent; }
.filler.cut { max-width: 0 !important; margin: 0; padding: 0; border-width: 0; opacity: 0; }
.demo-row { display: flex; flex-wrap: wrap; gap: 8px; }

/* Captions */
.c-captions .cell-art { flex: 1; min-height: 420px; background: #000; }
.captions img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 25%; }
.cap-demo { position: absolute; left: 0; right: 0; bottom: 20%; text-align: center; font-weight: 800; font-size: clamp(20px, 2vw, 28px); color: #fff; text-shadow: 0 3px 16px rgba(0, 0, 0, 0.8); letter-spacing: 0.01em; }
.cap-demo span { display: inline-block; }
.cell.in .cap-demo span { animation: capWord 3.2s var(--ease) infinite both; }
.cap-demo span:nth-child(2) { animation-delay: 0.4s !important; } .cap-demo span:nth-child(3) { animation-delay: 0.8s !important; } .cap-demo span:nth-child(4) { animation-delay: 1.2s !important; }
@keyframes capWord {
  0% { opacity: 0; transform: scale(0.6) translateY(6px); color: #fff; }
  8% { opacity: 1; transform: scale(1.08); color: var(--lime); }
  20% { transform: none; color: var(--lime); }
  28%, 80% { opacity: 1; color: #fff; }
  92%, 100% { opacity: 0; color: #fff; }
}
.cap-demo[data-preset="box"] span { background: var(--lime); color: var(--ink); padding: 2px 8px; border-radius: 6px; margin: 0 2px; text-shadow: none; }
.cap-demo[data-preset="box"] span:nth-child(odd) { background: #fff; }
.cap-demo[data-preset="minimal"] { font-weight: 500; font-size: clamp(14px, 1.3vw, 18px); letter-spacing: 0.01em; text-shadow: 0 2px 8px rgba(0, 0, 0, 0.7); }
.cap-demo[data-preset="minimal"] span { opacity: 0.92; }
.cap-demo[data-preset="bold"] { font-weight: 900; font-size: clamp(26px, 2.6vw, 36px); text-transform: uppercase; -webkit-text-stroke: 1.5px var(--ink); text-shadow: 0 4px 0 var(--ink); }
.preset-switch { position: absolute; left: 10px; right: 10px; bottom: 12px; z-index: 3; display: flex; gap: 6px; flex-wrap: wrap; }
.preset-btn { font: inherit; font-family: var(--font-mono); font-size: 11.5px; cursor: pointer; padding: 6px 11px; border-radius: 999px; color: #fff; background: rgba(0, 0, 0, 0.45); border: 1px solid rgba(255, 255, 255, 0.25); backdrop-filter: blur(6px); transition: background 0.2s, border-color 0.2s; }
.preset-btn:hover { border-color: var(--lime); }
.preset-btn:focus-visible { outline: 2px solid var(--lime); outline-offset: 2px; }
.preset-btn.is-active { background: var(--lime); color: var(--ink); border-color: var(--lime); font-weight: 600; }

/* Undo */
.undo-art { padding: 22px; display: flex; flex-direction: column; justify-content: center; gap: 16px; }
.hist { display: flex; flex-direction: column; gap: 6px; }
.hist .h { display: flex; align-items: center; gap: 8px; padding: 9px 12px; border-radius: var(--r-ui); background: var(--surface); border: 1px solid var(--line); font-size: 13.5px; color: var(--muted); transition: opacity 0.5s var(--ease), transform 0.5s var(--ease), max-height 0.45s var(--ease), margin 0.45s var(--ease), padding 0.45s var(--ease); }
.hist .h.ai { color: var(--text); border-color: var(--accent-display); max-height: 60px; }
.hist .h.ai .i { color: var(--accent-display); }
.undo-art.rolled .hist .h.ai { opacity: 0; transform: translateX(-12px); max-height: 0; margin: 0; padding-block: 0; border-width: 0; overflow: hidden; }
:where(.undo-art) .turn button { display: inline-flex; align-items: center; gap: 5px; padding: 6px 12px; border-radius: 999px; font-size: 11.5px; font-weight: 600; cursor: default; border: 1px solid var(--app-line); background: rgba(255, 255, 255, 0.06); color: var(--app-text); transition: transform 0.2s var(--ease), background-color 0.2s; }
:where(.undo-art) .turn .undo { border-color: rgba(200, 242, 60, 0.35); color: var(--lime); }
.undo-art .turn { display: flex; gap: 8px; }
.undo-art .turn .demo-btn.undo { color: var(--accent-text); border-color: var(--accent-display); }
.undo-art.rolled .turn { display: none; }
.undo-art .replay { align-self: flex-start; }

/* Reframe */
.reframe { background: #000; }
.reframe img { width: 100%; height: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.crop {
  all: unset; position: absolute; top: 0; bottom: 0; left: 50%; aspect-ratio: 9 / 16; border: 2px solid var(--lime); border-radius: 6px;
  box-shadow: 0 0 0 999px rgba(0, 0, 0, 0.55); transform: translateX(-50%); cursor: grab; touch-action: none;
  transition: aspect-ratio 0.5s var(--ease), left 0.5s var(--ease), transform 0.5s var(--ease);
}
.crop.dragging { cursor: grabbing; transition: aspect-ratio 0.5s var(--ease); }
.crop:focus-visible { outline: 2px solid var(--lime); outline-offset: 2px; }
.crop span { position: absolute; top: 8px; left: 8px; font-family: var(--font-mono); font-size: 11px; color: var(--ink); background: var(--lime); padding: 2px 6px; border-radius: 4px; }
.crop[data-ratio="11"] { aspect-ratio: 1 / 1; }
.crop[data-ratio="45"] { aspect-ratio: 4 / 5; }
.crop[data-ratio="169"] { aspect-ratio: 16 / 9; }
.ratio-switch { position: absolute; left: 10px; bottom: 12px; z-index: 3; display: flex; gap: 6px; flex-wrap: wrap; }
.ratio-btn { font: inherit; font-family: var(--font-mono); font-size: 11.5px; cursor: pointer; padding: 6px 11px; border-radius: 999px; color: #fff; background: rgba(0, 0, 0, 0.45); border: 1px solid rgba(255, 255, 255, 0.25); backdrop-filter: blur(6px); transition: background 0.2s, border-color 0.2s; }
.ratio-btn:hover { border-color: var(--lime); }
.ratio-btn:focus-visible { outline: 2px solid var(--lime); outline-offset: 2px; }
.ratio-btn.is-active { background: var(--lime); color: var(--ink); border-color: var(--lime); font-weight: 600; }

/* Sound */
.sound { padding: 22px; display: flex; flex-direction: column; justify-content: center; gap: 18px; background: linear-gradient(160deg, var(--surface-2), var(--bg-raise)); }
.lanes { display: flex; flex-direction: column; gap: 10px; }
.lane-row { display: grid; grid-template-columns: 54px 1fr; align-items: center; gap: 10px; font-family: var(--font-mono); font-size: 11px; color: var(--muted); }
.lane-row i { height: 38px; border-radius: 8px; background-color: var(--surface); border: 1px solid var(--line); position: relative; overflow: hidden; transition: height 0.5s var(--ease), opacity 0.5s var(--ease); }
.lane-row i::after { content: ""; position: absolute; inset: 4px 0; background: repeating-linear-gradient(90deg, var(--accent-display) 0 2px, transparent 2px 5px); }
.voice i::after { -webkit-mask: radial-gradient(ellipse 18% 50% at 20% 50%, #000 60%, transparent 62%), radial-gradient(ellipse 24% 46% at 60% 50%, #000 60%, transparent 62%); mask: radial-gradient(ellipse 18% 50% at 20% 50%, #000 60%, transparent 62%), radial-gradient(ellipse 24% 46% at 60% 50%, #000 60%, transparent 62%); }
.music i::after { opacity: 0.6; -webkit-mask: linear-gradient(90deg, #000 0 4%, rgba(0,0,0,.25) 8% 36%, #000 42% 50%, rgba(0,0,0,.25) 54% 84%, #000 88%); mask: linear-gradient(90deg, #000 0 4%, rgba(0,0,0,.25) 8% 36%, #000 42% 50%, rgba(0,0,0,.25) 54% 84%, #000 88%); }
.cell.in .lane-row i::after { animation: bars 1.4s linear infinite; }
@keyframes bars { to { background-position: 10px 0; } }
.sound.ducked .lane-row.music i { height: 16px; opacity: 0.5; }
.lufs { font-family: var(--font-display); font-size: 44px; line-height: 0.8; }
.duck-btn { align-self: flex-start; }
.lufs-val { transition: color 0.2s var(--ease); }
.lufs-val.unleveled { color: var(--muted); font-family: var(--font-mono); font-size: 15px; font-weight: 600; letter-spacing: 0.01em; }
.lufs-val.leveled { color: var(--text); }
.lufs-val.leveled::after { content: " LUFS"; font-family: var(--font-mono); font-size: 13px; color: var(--muted); margin-left: 2px; }

/* Timeline */
.tl { padding: 18px 20px 22px; display: flex; flex-direction: column; justify-content: center; gap: 7px; background: linear-gradient(200deg, var(--surface-2), var(--bg-raise)); }
.c-timeline .cell-art { flex: 1; }
.tl-time { position: absolute; top: 10px; right: 10px; z-index: 3; font-family: var(--font-mono); font-size: 11px; padding: 5px 9px; border-radius: 6px; background: color-mix(in srgb, var(--ink) 55%, transparent); color: #fff; letter-spacing: 0.02em; backdrop-filter: blur(6px); }
.tl-ruler { display: flex; justify-content: space-between; font-family: var(--font-mono); font-size: 10px; color: var(--muted); padding: 0 2px 2px; }
.tl-row { position: relative; height: 34px; border-radius: 8px; background: var(--surface); border: 1px solid var(--line); }
.tl-row.t, .tl-row.a { height: 20px; }
.tl-row.v2 { height: 24px; }
.tl-row.v2 i { background: color-mix(in srgb, var(--lime) 20%, var(--surface-2)); border-color: color-mix(in srgb, var(--lime) 45%, transparent); }
.tl-row i { position: absolute; top: 3px; bottom: 3px; left: calc(var(--s) * 1%); width: calc(var(--l) * 1% - 4px); border-radius: 5px; background: color-mix(in srgb, var(--accent-display) 22%, var(--surface-2)); border: 1px solid color-mix(in srgb, var(--accent-display) 50%, transparent); }
.tl-row.t i { background: color-mix(in srgb, var(--text) 14%, var(--surface)); border-color: var(--line-2); }
.tl-row.a i { background: repeating-linear-gradient(90deg, color-mix(in srgb, var(--accent-display) 55%, transparent) 0 2px, transparent 2px 4px); border-color: transparent; }
.tl-row i.kf::before, .tl-row i.kf::after { content: ""; position: absolute; top: 50%; width: 7px; height: 7px; background: var(--accent-display); transform: translate(-50%, -50%) rotate(45deg); border-radius: 1px; }
.tl-row i.kf::before { left: 20%; } .tl-row i.kf::after { left: 80%; }
.tl-row i.cmp { border-style: dashed; background: color-mix(in srgb, var(--accent-display) 10%, var(--surface)); }
.tl-head {
  all: unset; position: absolute; top: 28px; bottom: 14px; left: 20px; width: 10px; margin-left: -4px; cursor: ew-resize; touch-action: none; z-index: 2;
}
.tl-head::before { content: ""; position: absolute; left: 4px; top: 0; bottom: 0; width: 2px; border-radius: 2px; background: var(--accent-display); box-shadow: 0 0 10px var(--glow); }
.tl-head:focus-visible::before { outline: 2px solid var(--accent-display); outline-offset: 2px; }
.tl { container-type: inline-size; }
.jkl { display: flex; gap: 6px; margin-top: 4px; }
.jkl-btn { min-width: 40px; justify-content: center; font-weight: 700; }

.also { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.also li { display: inline-flex; align-items: center; gap: 9px; padding: 10px 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 14.5px; }
.also .i { color: var(--accent-display); }

@media (max-width: 420px) {
  .cap-demo { font-size: 16px; }
  .cap-demo[data-preset="bold"] { font-size: 22px; }
  .preset-switch, .ratio-switch { gap: 5px; }
  .preset-btn, .ratio-btn { padding: 5px 9px; font-size: 10.5px; }
  .demo-btn { font-size: 11.5px; padding: 7px 11px; }
  .lufs { font-size: 42px; }
}
@media (prefers-reduced-motion: reduce) {
  .filler { transition: none; }
  .hist .h { transition: none; }
  .crop { transition: none; }
  .lane-row i { transition: none; }
}


/* ---------- Privacy ---------- */
.privacy { padding-block: var(--section); }
.privacy-copy { max-width: 640px; }
.privacy-copy .body-lg { margin-top: 14px; }
.privacy-visual { margin-top: clamp(40px, 5vw, 64px); }
.privacy-illo-scroll { width: 100%; }
.privacy-illo { width: 100%; }
.pi-svg { display: block; width: 100%; height: auto; overflow: visible; }
.pi-boundary { fill: none; stroke: var(--accent-display); stroke-width: 1.5; }
.pi-boundary-glow { fill: none; stroke: var(--accent-display); stroke-width: 14; filter: url(#pi-blur); opacity: 0.3; }
.pi-mac-label { color: var(--muted); fill: var(--muted); }
.pi-mac-label text { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.08em; }
.pi-badge rect { fill: color-mix(in srgb, var(--accent-display) 12%, var(--surface)); stroke: color-mix(in srgb, var(--accent-display) 40%, var(--line)); stroke-width: 1; }
.pi-badge use { color: var(--accent-display); }
.pi-badge text { fill: var(--accent-display); font-family: var(--font-mono); font-size: 9.5px; font-weight: 700; letter-spacing: 0.06em; }
.pi-screen { fill: var(--surface-2); stroke: var(--line-2); stroke-width: 1.3; }
.pi-notch { fill: var(--app-bg); }
.pi-chrome-dot { fill: var(--muted); opacity: 0.5; }
.pi-filename { fill: var(--muted); font-family: var(--font-mono); font-size: 9.5px; letter-spacing: 0.02em; }
.pi-mark { color: var(--accent-display); opacity: 0.6; }
.pi-titlebar-div { stroke: var(--line); stroke-width: 1; }
.pi-viewer { fill: none; stroke: var(--app-line); stroke-width: 1; }
.pi-viewer-icon { color: #fff; opacity: 0.8; filter: drop-shadow(0 1px 3px rgba(0,0,0,.5)); }
.pi-track { fill: var(--app-line); }
.pi-clip { opacity: 0.85; }
.pi-clip-a { fill: var(--accent-display); }
.pi-clip-b { fill: color-mix(in srgb, var(--accent-display) 60%, var(--app-text)); }
.pi-clip-c { fill: color-mix(in srgb, var(--accent-display) 35%, var(--app-text)); }
.pi-playhead { stroke: var(--accent-display); stroke-width: 2; }
.pi-hinge { stroke: var(--line-2); stroke-width: 3; }
.pi-deck { fill: var(--surface-2); stroke: var(--line); stroke-width: 1; }
.pi-trackpad { fill: none; stroke: var(--line-2); stroke-width: 1; }
.pi-chip rect:first-child { fill: var(--surface); stroke: var(--line); stroke-width: 1; }
.pi-chip-icon { color: var(--accent-display); }
.pi-chip-title { fill: var(--text); font-family: var(--font-text); font-size: 13.5px; font-weight: 600; }
.pi-chip-sub { fill: var(--muted); font-family: var(--font-mono); font-size: 10.5px; }
.pi-chip-thumb-frame { fill: none; stroke: var(--line); stroke-width: 1; }
.pi-chip-doc { fill: var(--surface-2); stroke: var(--line); stroke-width: 1; }
.pi-chip-line { fill: var(--muted); opacity: 0.55; }
.pi-chip-tag { fill: color-mix(in srgb, var(--accent-display) 20%, var(--surface)); stroke: color-mix(in srgb, var(--accent-display) 55%, var(--line)); stroke-width: 1.2; }
.pi-chip-tag-text { fill: var(--accent-display); font-family: var(--font-mono); font-size: 11px; font-weight: 700; text-anchor: middle; }
.pi-vault rect { fill: color-mix(in srgb, var(--accent-display) 7%, var(--surface-2)); stroke: color-mix(in srgb, var(--accent-display) 35%, var(--line)); stroke-width: 1.2; }
.pi-vault-icon { color: var(--accent-display); }
.pi-vault-title { fill: var(--text); font-family: var(--font-text); font-size: 14.5px; font-weight: 600; }
.pi-vault-key { color: var(--muted); }
.pi-vault-row { fill: var(--muted); font-family: var(--font-text); font-size: 11.5px; }
.pi-exit-dot { fill: var(--accent-display); }
.pi-beam { fill: none; stroke: var(--accent-display); stroke-width: 2; stroke-dasharray: 4 7; stroke-linecap: round; opacity: 0.85; }
.pi-sent rect { fill: var(--surface); stroke: var(--line); stroke-width: 1; }
.pi-sent-icon { color: var(--accent-display); }
.pi-sent-title { fill: var(--text); font-family: var(--font-text); font-size: 14px; font-weight: 600; dominant-baseline: central; }
.pi-sent-div { stroke: var(--line); stroke-width: 1; }
.pi-sent-dot { fill: var(--accent-display); }
.pi-sent-row { fill: var(--muted); font-family: var(--font-text); font-size: 12.5px; dominant-baseline: central; }
.pi-sent-tick { stroke: var(--line-2); stroke-width: 1.5; }
.pi-sent-joint { fill: var(--accent-display); }
.pi-packet { fill: var(--accent-display); offset-path: path('M784,254 L1000,254'); animation: pi-travel 3.8s linear infinite; animation-play-state: paused; opacity: 0.9; }
.pi-packet:nth-child(2) { animation-delay: -1.27s; }
.pi-packet:nth-child(3) { animation-delay: -2.54s; }
.privacy-illo.in .pi-packet, .privacy-illo.in .pi-boundary-glow { animation-play-state: running; }
.pi-boundary-glow { animation: pi-pulse 3.2s ease-in-out infinite; animation-play-state: paused; }
.pi-provider { fill: var(--surface-2); stroke: var(--accent-display); stroke-width: 1.4; }
.pi-provider-icon { color: var(--accent-display); }
.pi-provider-title { fill: var(--text); font-family: var(--font-text); font-size: 13px; font-weight: 600; dominant-baseline: central; }
.pi-provider-div { stroke: var(--line); stroke-width: 1; }
.pi-provider-row { fill: var(--muted); font-family: var(--font-text); font-size: 12px; dominant-baseline: central; }
.pi-note { fill: var(--muted); font-family: var(--font-text); font-size: 12.5px; text-anchor: middle; }
@keyframes pi-travel { 0% { offset-distance: 0%; opacity: 0; } 10% { opacity: 0.9; } 88% { opacity: 0.9; } 100% { offset-distance: 100%; opacity: 0; } }
@keyframes pi-pulse { 0%, 100% { opacity: 0.22; } 50% { opacity: 0.46; } }
.pd-facts { margin-top: clamp(32px, 4vw, 48px); display: grid; grid-template-columns: repeat(5, 1fr); gap: 24px 20px; }
.pd-facts li { display: flex; align-items: flex-start; gap: 10px; }
.pd-facts .i { width: 18px; height: 18px; margin-top: 2px; color: var(--accent-display); flex: none; }
.pd-facts li div { display: flex; flex-direction: column; gap: 3px; }
.pd-facts strong { font-size: 14.5px; font-weight: 600; }
.pd-facts span { font-size: 13px; color: var(--muted); line-height: 1.45; }
@media (max-width: 1000px) {
  .pd-facts { grid-template-columns: repeat(2, 1fr); gap: 20px 24px; }
}
@media (max-width: 640px) {
  .pd-facts { grid-template-columns: 1fr; }
  .privacy-illo-scroll { position: relative; overflow-x: auto; -webkit-overflow-scrolling: touch; border-radius: var(--r-inner); }
  .privacy-illo { min-width: 640px; }
  .privacy-illo-scroll::after {
    content: ""; position: absolute; top: 0; right: 0; bottom: 0; width: 36px;
    background: linear-gradient(to right, transparent, var(--bg)); pointer-events: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  .pi-packet { animation: none; opacity: 0; }
  .pi-boundary-glow { animation: none; opacity: 0.3; }
}

/* ---------- Roadmap ---------- */
.roadmap { padding-block: var(--section); }
.road { margin-top: clamp(40px, 5vw, 64px); }
.road-timeline { --head: 130px; --gap: 16px; position: relative; }
.road-ruler { position: relative; height: 26px; margin-left: calc(var(--head) + var(--gap)); border-bottom: 1px solid var(--line-2); }
.road-ruler span { position: absolute; bottom: 8px; left: calc(var(--p) * 1%); transform: translateX(-50%); font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.05em; text-transform: uppercase; color: var(--muted); white-space: nowrap; }
.road-ruler span:first-child { color: var(--accent-display); }
.road-playhead {
  position: absolute; top: 26px; bottom: 0;
  left: calc(var(--head) + var(--gap) + (100% - var(--head) - var(--gap)) * 0.27);
  width: 2px; background: var(--accent-display); box-shadow: 0 0 10px var(--glow); pointer-events: none;
}
.road.in .road-playhead { animation: drift 6s ease-in-out infinite; }
@keyframes drift {
  0%, 100% { left: calc(var(--head) + var(--gap) + (100% - var(--head) - var(--gap)) * 0.27); }
  50% { left: calc(var(--head) + var(--gap) + (100% - var(--head) - var(--gap)) * 0.27 + 6px); }
}
.road-lanes { display: flex; flex-direction: column; gap: 12px; margin-top: 14px; }
.road-lane { display: flex; align-items: stretch; gap: var(--gap); }
.road-lane-head { flex: 0 0 var(--head); display: flex; align-items: center; font-family: var(--font-mono); font-size: 12.5px; letter-spacing: 0.03em; color: var(--muted); }
.road-lane-track { position: relative; flex: 1; min-width: 0; }
.road-now-divider { display: none; }
.road-lane-row { display: flex; gap: 10px; padding-left: 30%; }
.road-lane-row .clip { flex: 1 1 0; min-width: 0; width: auto; margin-left: 0; }
.clip { position: relative; margin-left: calc(var(--s) * 1%); width: calc(var(--l) * 1% - 12px); padding: 18px 20px; border-radius: var(--r-inner); }
.clip .i { width: 22px; height: 22px; color: var(--accent-display); }
.clip h3 { margin-top: 12px; font-family: var(--font-display); font-size: 24px; line-height: 0.95; font-weight: 700; padding-bottom: 0.08em; }
.clip p { margin-top: 8px; color: var(--muted); font-size: 13px; line-height: 1.4; }
.clip-live { background: var(--surface); border: 1.5px solid color-mix(in srgb, var(--accent-display) 55%, var(--line)); }
.clip-next {
  border: 1.5px dashed color-mix(in srgb, var(--accent-display) 60%, transparent);
  background: repeating-linear-gradient(-45deg, transparent 0 14px, color-mix(in srgb, var(--accent-display) 6%, transparent) 14px 28px);
  background-size: 200% 200%;
}
.road.in .clip-next { animation: pending 8s linear infinite; }
@keyframes pending { to { background-position: 80px 0; } }
@media (max-width: 900px) {
  .road-ruler { display: none; }
  .road-playhead { display: none; }
  .road-lanes { gap: 16px; }
  .road-lane { flex-direction: column; gap: 6px; }
  .road-lane-head { flex: none; }
  .road-lane-track { min-height: 0; }
  .clip { position: static; width: auto; margin-left: 0; }
  .road-lane-row { flex-direction: column; gap: 10px; padding-left: 0; }
  .road-now-divider { display: flex; align-items: center; gap: 10px; margin: 4px 0; color: var(--accent-display); font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.05em; text-transform: uppercase; }
  .road-now-divider::after { content: ""; flex: 1; height: 1px; background: var(--accent-display); opacity: 0.5; }
}

/* ---------- Pricing ---------- */
.pricing { padding-block: var(--section); background: radial-gradient(50% 50% at 50% 60%, var(--glow), transparent 70%); }
.price-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; max-width: 880px; margin-inline: auto; align-items: stretch; }
.price { display: flex; flex-direction: column; padding: 32px; border-radius: var(--r-card); background: var(--surface); border: 1px solid var(--line); }
.price h3 { font-weight: 600; font-size: 17px; }
.price-amount { display: flex; flex-wrap: wrap; align-items: baseline; gap: 12px; margin-top: 18px; }
.price-amount .num { font-family: var(--font-display); font-size: clamp(72px, 7vw, 96px); line-height: 0.75; }
.price-amount .unit { color: var(--muted); font-size: 16px; }
.price .btn { margin-top: auto; }
.license {
  position: relative; border-color: color-mix(in srgb, var(--accent-display) 55%, transparent);
  box-shadow: 0 0 0 6px color-mix(in srgb, var(--accent-display) 8%, transparent), 0 40px 80px -40px var(--glow);
}
.price-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 28px; }
.price-head-icon { width: 40px; height: 40px; flex: none; }
.price-head h3 { margin-right: auto; }
.badge { padding: 5px 12px; border-radius: 999px; background: var(--accent); color: var(--on-accent); font-size: 12.5px; font-weight: 600; }
.was {
  position: relative; display: inline-block; padding-inline: 2px;
  font-family: var(--font-display); font-size: 28px; line-height: 0.8; color: var(--muted);
  text-decoration: none; align-self: baseline;
}
.was::after {
  content: ""; position: absolute; left: -4px; right: -4px; top: 44%; height: 3px;
  border-radius: 3px; background: var(--text); opacity: 0.85;
  transform: rotate(-9deg); transform-origin: center; pointer-events: none;
}
.price-list { display: flex; flex-direction: column; gap: 10px; margin: 26px 0 30px; flex: 1; }
.price-list li { display: flex; align-items: center; gap: 10px; font-size: 15px; }
.price-list .i { color: var(--accent-display); flex: none; }
.fine { margin-top: 24px; text-align: center; color: var(--muted); font-size: 14px; }
@media (max-width: 560px) {
  .price-amount .num { font-size: clamp(56px, 16vw, 72px); }
  .was { font-size: 22px; }
}

/* ---------- FAQ ---------- */
.faq { padding-block: var(--section); }
.faq-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px 40px; }
.faq-sub { color: var(--muted); font-size: 16px; max-width: 42ch; }
.reqs {
  margin-top: 36px; padding: 22px 26px; border-radius: var(--r-card); background: var(--surface); border: 1px solid var(--line);
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px 24px;
}
.reqs h3 { grid-column: 1 / -1; font-weight: 600; font-size: 16px; }
.reqs ul { display: contents; }
.reqs li { display: flex; gap: 12px; align-items: flex-start; font-size: 15px; }
.reqs .i { margin-top: 3px; color: var(--accent-display); flex: none; }
.qa-columns { margin-top: 48px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(24px, 3vw, 40px); align-items: start; }
.qa { display: flex; flex-direction: column; gap: 10px; }
.qa-group { font-weight: 600; font-size: 13px; letter-spacing: 0.04em; text-transform: uppercase; color: var(--muted); margin: 28px 0 2px; }
.qa-group:first-child { margin-top: 0; }
.qa details { border-radius: var(--r-inner); background: var(--surface); border: 1px solid var(--line); transition: border-color 0.3s; }
.qa details[open] { border-color: var(--line-2); }
.qa summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 20px 22px; font-weight: 600; font-size: 16.5px; line-height: 1.4; }
.qa summary::-webkit-details-marker { display: none; }
.qa summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.qa summary::after {
  content: ""; flex: none; width: 28px; height: 28px; border-radius: 999px; border: 1px solid var(--line-2);
  background: linear-gradient(currentColor, currentColor) center / 11px 1.5px no-repeat, linear-gradient(currentColor, currentColor) center / 1.5px 11px no-repeat;
  transition: transform 0.4s var(--ease);
}
.qa details[open] summary::after { transform: rotate(45deg); }
.qa .a { padding: 0 22px 22px; color: var(--muted); max-width: 62ch; }
.qa .a a { color: var(--accent-text); }
@supports (interpolate-size: allow-keywords) {
  .qa { interpolate-size: allow-keywords; }
  .qa details::details-content { height: 0; overflow: clip; transition: height 0.45s var(--ease), content-visibility 0.45s allow-discrete; }
  .qa details[open]::details-content { height: auto; }
}
@media (prefers-reduced-motion: reduce) {
  .qa summary::after { transition: none; }
  @supports (interpolate-size: allow-keywords) {
    .qa details::details-content { transition: none; }
  }
}
@media (max-width: 900px) {
  .reqs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .qa-columns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .faq-head { align-items: flex-start; }
  .reqs { grid-template-columns: minmax(0, 1fr); }
  .qa-columns { grid-template-columns: minmax(0, 1fr); }
}
@media (min-width: 641px) {
  .qa summary { min-height: calc(2 * 1.4em + 40px); }
}

/* ---------- Closing ---------- */
.closing { --ghost: color-mix(in srgb, var(--text) 13%, transparent); padding-block: clamp(120px, 14vw, 200px); position: relative; overflow: hidden; }
.closing::before { content: ""; position: absolute; inset: 0; background: radial-gradient(40% 60% at 50% 100%, var(--glow), transparent 70%); pointer-events: none; }
.closing-wrap { position: relative; }
.closing-mark { display: block; width: clamp(56px, 7vw, 68px); height: clamp(56px, 7vw, 68px); margin: 0 auto 36px; filter: drop-shadow(0 0 28px var(--glow)) drop-shadow(0 0 48px var(--glow)); }
/* The headline is a small timeline: a ruler, a clip bar under each phrase, and a playhead that renders each phrase as it passes. */
.closing-stage {
  --x: 0px; --pp: 0; position: relative; width: fit-content; max-width: 100%; margin-inline: auto; padding-top: 52px;
  touch-action: pan-y; -webkit-user-select: none; user-select: none;
}
.js .closing-stage { cursor: ew-resize; }
.closing-ruler {
  position: absolute; left: 0; right: 0; top: 24px; height: 28px; border-bottom: 1px solid var(--line-2);
  background:
    linear-gradient(to right, var(--line-2) 1px, transparent 1px) 0 100% / calc(100% / 3) 10px repeat-x,
    linear-gradient(to right, var(--line-2) 1px, transparent 1px) 0 100% / calc(100% / 24) 5px repeat-x;
}
.closing-ruler span {
  position: absolute; top: 0; left: calc(var(--at) * 100% / 3); transform: translateX(-50%);
  font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.05em; color: var(--muted);
}
.closing-ruler span:first-child { transform: none; }
.closing-ruler span:last-child { transform: translateX(-100%); }
.closing-title {
  display: flex; align-items: flex-start; justify-content: center; gap: clamp(20px, 3vw, 44px);
  margin-top: 26px; font-size: clamp(32px, 5.2vw, 72px); line-height: 0.95;
}
.closing-clip { --p: 1; --fill: var(--text); display: flex; flex-direction: column; gap: clamp(12px, 1.3vw, 18px); }
.closing-clip.accent { --fill: var(--accent-display); }
.js .closing-clip { --p: 0; }
.closing-clip .cw {
  display: block; padding: 0.06em 0.03em 0.2em; margin: -0.06em -0.03em -0.2em; white-space: nowrap;
  background: linear-gradient(90deg, var(--fill) calc(var(--p) * 100%), var(--ghost) 0);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  transition: filter 0.3s var(--ease);
}
.closing-clip.live .cw { filter: drop-shadow(0 0 24px var(--glow)); }
.cbar {
  position: relative; display: block; height: 10px; border-radius: 5px; overflow: hidden;
  background: repeating-linear-gradient(90deg, var(--line) 0 2px, transparent 2px 6px), var(--surface-2);
  box-shadow: inset 0 0 0 1px var(--line-2); transition: box-shadow 0.3s var(--ease);
}
.cbar::before { content: ""; position: absolute; inset: 0; width: calc(var(--p) * 100%); background: color-mix(in srgb, var(--accent-display) 78%, transparent); }
.closing-clip.live .cbar { box-shadow: inset 0 0 0 1px var(--accent-display), 0 0 18px -4px var(--glow); }
.closing-playhead { display: none; }
.js .closing-playhead {
  display: block; position: absolute; z-index: 2; top: 0; bottom: -6px; left: 0; width: 2px; margin-left: -1px;
  transform: translateX(var(--x)); cursor: ew-resize; outline: none; touch-action: none;
}
.closing-playhead::before { content: ""; position: absolute; top: 0; bottom: 0; left: -14px; width: 30px; }
.closing-playhead::after {
  content: ""; position: absolute; top: 22px; bottom: 0; left: 0; width: 2px; border-radius: 2px;
  background: var(--accent-display); box-shadow: 0 0 14px var(--glow);
}
/* The timecode slides from left-aligned to right-aligned so it never leaves the stage. */
.closing-tc {
  position: absolute; top: 0; left: 1px; height: 22px; padding: 0 9px; border-radius: 999px; transform: translateX(calc(var(--pp) * -100%));
  background: var(--accent); color: var(--on-accent); font-family: var(--font-mono); font-size: 11px; line-height: 22px;
  font-variant-numeric: tabular-nums; white-space: nowrap; box-shadow: 0 6px 18px -8px var(--glow);
}
.closing-playhead:focus-visible .closing-tc { outline: 2px solid var(--text); outline-offset: 2px; }
.closing-stage.is-scrubbing .closing-tc { box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 30%, transparent); }
.closing-sparks { position: absolute; inset: 0; z-index: 3; pointer-events: none; }
.closing-sparks i {
  position: absolute; width: 10px; height: 10px; margin: -5px 0 0 -5px; border-radius: 2px; background: var(--accent);
  box-shadow: 0 0 10px var(--glow); animation: closingSpark 1s var(--ease-out) forwards;
}
.closing-sparks i:nth-child(3n) { background: var(--accent-display); border-radius: 50%; }
.closing-sparks i:nth-child(3n + 1) { width: 6px; height: 15px; }
.closing-transport { display: none; }
.js .closing-transport { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 34px; color: var(--muted); font-size: 14px; }
.closing-play {
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--line-2); background: var(--surface); color: var(--text);
  transition: border-color 0.25s, transform 0.25s var(--ease);
}
.closing-play:hover { border-color: var(--accent-text); }
.closing-play:active { transform: scale(0.94); }
.closing-play .i { width: 16px; height: 16px; }
.closing-hint { transition: color 0.3s; }
.closing.is-shipped .closing-hint { color: var(--accent-text); font-weight: 600; }
.closing.is-shipped .closing-clip.accent .cw { animation: closingPop 0.65s var(--spring); }
.closing.is-shipped .closing-mark { animation: closingHop 0.7s var(--spring); }
.closing.is-shipped .cta-row .btn-primary { animation: closingNudge 1s var(--ease) 0.2s; }
.closing .cta-row { margin-top: 40px; }
@keyframes closingSpark { to { transform: translate(var(--dx), var(--dy)) rotate(var(--r)) scale(0.3); opacity: 0; } }
@keyframes closingPop { 40% { transform: scale(1.07) rotate(-2deg); } }
@keyframes closingHop { 35% { transform: translateY(-14px) rotate(-8deg); } 70% { transform: translateY(2px) rotate(3deg); } }
@keyframes closingNudge { 35% { transform: scale(1.05); box-shadow: 0 0 0 10px color-mix(in srgb, var(--accent) 22%, transparent); } }
@media (prefers-reduced-motion: reduce) {
  .closing.is-shipped :is(.closing-mark, .cw, .btn-primary) { animation: none; }
}
/* Phones: the phrases step down like clips on three tracks, so the playhead still crosses them in order. */
@media (max-width: 640px) {
  .closing-stage { width: 100%; }
  .closing-title { display: grid; grid-template-columns: minmax(0, 1fr); justify-items: start; gap: 22px; font-size: clamp(40px, 12vw, 56px); }
  .closing-clip:nth-child(2) { justify-self: center; }
  .closing-clip:nth-child(3) { justify-self: end; }
}

/* ---------- Footer ---------- */
.footer { position: relative; overflow: hidden; border-top: 1px solid var(--line); padding-top: 56px; padding-bottom: 120px; }
.footer-grid { position: relative; z-index: 1; display: grid; grid-template-columns: 1.6fr repeat(5, 1fr); gap: 32px; align-items: start; }
.footer-brand-top { display: flex; align-items: center; gap: 12px; }
.footer-brand img { height: 34px; width: auto; }
.footer-brand p { margin-top: 12px; color: var(--muted); font-size: 14.5px; max-width: 26ch; }
.footer-social { display: flex; gap: 8px; margin-top: 22px; }
.footer-social a { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 999px; border: 1px solid var(--line-2); transition: border-color 0.25s, transform 0.3s var(--ease); }
.footer-social a:hover { border-color: var(--text); transform: translateY(-2px); }
.footer-links { display: contents; }
.footer-col h3 { font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text); font-weight: 600; margin-bottom: 14px; }
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col a, .footer-col .link-btn { color: var(--muted); text-decoration: none; font-size: 14px; line-height: 1.4; transition: color 0.25s; }
.footer-col a:hover, .footer-col .link-btn:hover { color: var(--text); }
.footer-col .link-btn { background: none; border: 0; padding: 0; font-family: inherit; text-align: left; cursor: pointer; }
.footer-col li:has(> [data-cookie-settings][hidden]) { display: none; }
.footer-legal { position: relative; z-index: 1; margin-top: 44px; display: flex; flex-direction: column; gap: 6px; color: var(--muted); font-size: 12.5px; }
.footer-wordmark {
  position: absolute; left: 50%; bottom: -8%; width: min(1400px, 150%); max-width: none; height: auto;
  transform: translateX(-50%); opacity: 0.05; pointer-events: none; z-index: 0;
}
@media (max-width: 900px) {
  .footer-grid { grid-template-columns: repeat(3, 1fr); gap: 32px 24px; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  .footer-grid { grid-template-columns: repeat(2, 1fr); gap: 26px 18px; }
  .footer-col ul { gap: 8px; }
}

/* ---------- Toast + consent ---------- */
.toast {
  position: fixed; left: 50%; bottom: 24px; z-index: 80; transform: translateX(-50%); max-width: calc(100vw - 32px);
  padding: 12px 18px; border-radius: 999px; background: var(--text); color: var(--bg); font-size: 14px; font-weight: 500;
  box-shadow: 0 20px 50px -20px var(--shadow); animation: toastIn 0.5s var(--ease) both;
}
@keyframes toastIn { from { opacity: 0; transform: translate(-50%, 16px); } }
.consent {
  position: fixed; left: 16px; bottom: 16px; z-index: 70; max-width: 380px; padding: 18px; border-radius: var(--r-inner);
  background: var(--surface); border: 1px solid var(--line-2); box-shadow: 0 30px 60px -30px var(--shadow); animation: toastIn 0.5s var(--ease) both;
}
.consent p { font-size: 14px; color: var(--muted); }
.consent-actions { display: flex; gap: 8px; justify-content: flex-end; margin-top: 14px; }

/* ---------- Trial modal ---------- */
.trial-modal {
  position: fixed; inset: 0; z-index: 90; margin: auto; width: min(420px, calc(100vw - 32px));
  padding: 28px; border: 1px solid var(--line-2); border-radius: var(--r-card);
  background: var(--surface); color: var(--text); box-shadow: 0 40px 90px -30px var(--shadow);
  animation: toastIn 0.35s var(--ease) both;
}
.trial-modal::backdrop { background: color-mix(in srgb, var(--bg) 60%, transparent); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.trial-modal h3 { font-family: var(--font-display); font-weight: 700; font-size: 28px; line-height: 1; padding-bottom: 0.08em; margin-bottom: 10px; padding-right: 32px; }
.trial-modal .muted { font-size: 14px; line-height: 1.5; margin-bottom: 18px; }
.trial-close {
  position: absolute; top: 14px; right: 14px; width: 34px; height: 34px;
}
.trial-field { display: block; margin-bottom: 14px; }
.trial-field span { display: block; font-family: var(--font-mono); font-size: 11.5px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.trial-field input {
  width: 100%; height: 48px; padding: 0 14px; border-radius: var(--r-ui); border: 1px solid var(--line-2);
  background: var(--bg); color: var(--text); font: inherit; font-size: 15px;
  transition: border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.trial-field input:focus-visible { outline: none; border-color: var(--accent-text); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent-text) 24%, transparent); }
.trial-error { margin: -4px 0 14px; font-size: 13.5px; color: #e0554f; }
.trial-submit { width: 100%; margin-top: 4px; }
.trial-submit:disabled { opacity: 0.6; cursor: default; }
.trial-fine { margin-top: 14px; font-size: 12.5px; line-height: 1.5; color: var(--muted); }
.trial-fine a { color: var(--accent-text); }
.trial-success h3 { margin-bottom: 10px; }
.trial-success p { font-size: 14.5px; line-height: 1.55; color: var(--muted); margin-bottom: 20px; }
.trial-success-email { color: var(--text); }
.trial-success .btn { width: 100%; }
@media (max-width: 480px) {
  .trial-modal { padding: 22px; width: calc(100vw - 24px); }
}

/* ---------- Legal pages ---------- */
.legal { padding-top: 150px; padding-bottom: var(--section); }
.legal-body { max-width: 760px; }
.legal-body h1 { font-family: var(--font-display); font-size: clamp(56px, 7vw, 88px); line-height: 0.9; padding-bottom: 0.08em; }
.legal-body .updated { margin-top: 22px; color: var(--muted); font-size: 14px; }
.legal-body h2 { margin-top: 44px; font-size: 22px; font-weight: 600; letter-spacing: -0.01em; }
.legal-body p, .legal-body li { margin-top: 12px; color: var(--muted); font-size: 16px; }
.legal-body ul { list-style: disc; padding-left: 22px; }
.legal-body a { color: var(--accent-text); }
.legal-body strong { color: var(--text); font-weight: 600; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .bento {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-areas: "words words" "cap undo" "cap frame" "sound sound" "tl tl";
  }
  .privacy-grid { grid-template-columns: minmax(0, 1fr); }
  .privacy-copy { position: static; }
}
@media (max-width: 900px) {
  .nav-links { display: none; }
  .menu-toggle { display: grid; }
  .nav-actions .btn { display: none; }
  .engines-grid { grid-template-columns: minmax(0, 1fr); }
  .road-track { grid-template-columns: minmax(0, 1fr); }
  .price-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .plugs li:nth-child(odd) { left: 24%; }
  .plugs li:nth-child(even) { left: 76%; }
  .price { padding: 24px; }
  .bento { grid-template-columns: minmax(0, 1fr); grid-template-areas: "words" "cap" "undo" "frame" "sound" "tl"; }
  .c-captions .cell-art { min-height: 360px; }
  .pcol { grid-template-columns: 1fr; gap: 14px; padding: 22px; }
  .pcol p { grid-column: 1; margin-top: 0; }
  .plugs li { font-size: 13px; padding: 9px 12px; }
  .cta-row .btn { flex: 1 1 auto; }
  .consent { right: 16px; max-width: none; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; transition-delay: 0s !important; }
  .js .reveal { opacity: 1; transform: none; filter: none; }
  .to-caret { display: none; }
  .progress { display: none; }
}
@media (prefers-reduced-transparency: reduce) {
  .nav, .mobile-menu { background: var(--surface); -webkit-backdrop-filter: none; backdrop-filter: none; }
}
