/* ============================================================
   TRACKEN — Landing v3 · section styles
   Page chrome = light editorial (Geist).  Product surfaces use the
   real product look via the .product scope (IBM Plex, cold-blue
   canvas, cyan accent, sharp corners) — faithful to the app.
   ============================================================ */

/* ---------------- NAV ---------------- */
.nav { position: fixed; inset: 0 0 auto 0; z-index: 50; border-bottom: 1px solid transparent; transition: background .3s var(--ease-out), border-color .3s var(--ease-out), backdrop-filter .3s; }
.nav.scrolled { background: color-mix(in oklab, var(--bg) 78%, transparent); backdrop-filter: blur(16px) saturate(150%); -webkit-backdrop-filter: blur(16px) saturate(150%); border-bottom-color: var(--hairline); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 70px; }
.brand { display: inline-flex; align-items: center; gap: 8px; color: var(--accent); }
/* Logo matched to the in-app sidebar lockup: bare bracket-dot mark
   (no box), 20px, 1.6 stroke, + "Tracken" wordmark at the app's sizing. */
.brand-mark { width: 20px; height: 20px; background: transparent; display: inline-flex; align-items: center; justify-content: center; color: var(--accent); }
.brand-mark svg { width: 100%; height: 100%; }
.brand-mark svg path { stroke-width: 1.6; }
.brand-word { font-size: 16px; font-weight: 600; letter-spacing: -0.015em; color: var(--accent); }
.nav-links { display: flex; gap: 32px; }
.nav-links a { font-size: 14.5px; color: var(--text-2); transition: color .18s; position: relative; }
.nav-links a:hover { color: var(--text-1); }
.nav-links a::after { content: ""; position: absolute; left: 0; bottom: -7px; height: 2px; width: 0; background: var(--accent); border-radius: 2px; transition: width .25s var(--ease-out); }
.nav-links a:hover::after { width: 100%; }
.nav-cta { display: flex; align-items: center; gap: 18px; }
.nav-signin { font-size: 14.5px; color: var(--text-2); transition: color .18s; }
.nav-signin:hover { color: var(--text-1); }
@media (max-width: 880px) { .nav-links { display: none; } }

/* ---------------- HERO ---------------- */
.hero { position: relative; padding-top: 70px; min-height: 100svh; display: flex; flex-direction: column; }
.statusbar { border-bottom: 1px solid var(--hairline); font-family: var(--mono); font-size: 11.5px; color: var(--text-3); height: 38px; display: flex; align-items: center; }
.statusbar-inner { display: flex; align-items: center; justify-content: space-between; width: 100%; }
.status-left { display: flex; align-items: center; gap: 10px; }
.status-live { color: var(--green); letter-spacing: 0.13em; font-weight: 600; }
.status-sep { color: var(--text-4); }
.status-stream { color: var(--text-2); }
.status-right { display: flex; align-items: center; gap: 22px; }
.status-right b { color: var(--text-2); font-weight: 500; }
@media (max-width: 760px) { .status-right span:nth-child(-n+2) { display: none; } }

.hero-inner { flex: 1; display: grid; grid-template-columns: 1.02fr 0.98fr; gap: clamp(32px,5vw,60px); align-items: center; padding-block: clamp(18px, 3vw, 44px); }
.hero-copy { max-width: 600px; }
.hero-copy .overline { margin-bottom: 24px; }
.hero-copy .display { margin-bottom: 24px; }
.hero-copy .lead { max-width: 510px; margin-bottom: 32px; }
.hero-actions { display: flex; gap: 13px; flex-wrap: wrap; align-items: center; }
.hero-actions-m { display: none; }
.play-glyph { width: 0; height: 0; border-left: 9px solid currentColor; border-top: 6px solid transparent; border-bottom: 6px solid transparent; margin-right: 1px; }
.hero-meta { display: flex; align-items: center; gap: 12px; margin-top: 32px; color: var(--text-3); font-size: 12px; flex-wrap: wrap; font-family: var(--mono); }
.dot-sep { width: 3px; height: 3px; border-radius: 999px; background: var(--text-4); }
@media (max-width: 920px) {
  .hero-inner { grid-template-columns: 1fr; gap: 16px; padding-block: 22px 8px; }
  .hero-viz { order: 2; }
  /* on mobile the CTA sits BELOW the animation, not above it */
  .hero-actions-d { display: none; }
  .hero-actions-m { display: flex; order: 3; }
}

.hero-scroll { display: flex; align-items: center; gap: 10px; color: var(--text-4); font-family: var(--mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; padding-bottom: 26px; justify-content: center; }
.hs-line { width: 1px; height: 30px; background: linear-gradient(180deg, transparent, var(--hairline-3)); animation: hsPulse 2.4s var(--ease-in-out) infinite; }
@keyframes hsPulse { 0%,100% { opacity: .4; transform: scaleY(.7); transform-origin: top; } 50% { opacity: 1; transform: scaleY(1);} }

/* ============================================================
   .product — faithful product surface (the real Tracken look)
   ============================================================ */
.product {
  /* Inherit the page's Stone/Ink tokens so demos match the scheme exactly. */
  --pb0: var(--bg-0); --pb1: var(--bg-1); --pb2: var(--bg-2); --pb3: var(--bg-3); --pb4: var(--bg-4);
  /* Stone PRESET (the product default) = borders:"dividers" + flat —
     outer card/panel frames hidden, only hairline internal row dividers
     (line-soft) remain, and no shadows. This is what makes Stone read as
     "clean black & white with hairline row dividers". */
  --pln: transparent; --plns: var(--line-soft); --plnh: transparent;
  --shadow-card: none;
  --pf0: var(--fg-0); --pf1: var(--fg-1); --pf2: var(--fg-2); --pf3: var(--fg-3); --pf4: var(--fg-4);
  --pac: var(--accent); --pach: var(--accent-hi); --pacb: var(--accent-bg);
  --pup: var(--up); --pupb: var(--up-bg); --pdn: var(--down); --pdnb: var(--down-bg);
  --pal: var(--alert); --palb: var(--alert-bg);
  font-family: 'IBM Plex Sans', system-ui, sans-serif;
  letter-spacing: -0.003em;
  background: var(--pb0); color: var(--pf0);
  border: 1px solid var(--plnh);
}
.product .pmono { font-family: 'IBM Plex Mono', ui-monospace, monospace; font-feature-settings: 'zero','ss01'; font-variant-numeric: tabular-nums; }
.product .plabel { font-family: 'IBM Plex Mono', monospace; font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--pf3); }
.pr-dot-live { width: 6px; height: 6px; display: inline-block; background: var(--pac); box-shadow: 0 0 0 0 var(--pacb); animation: prPulse 1.7s ease-in-out infinite; }
@keyframes prPulse { 0%,100% { box-shadow: 0 0 0 0 var(--pacb); } 50% { box-shadow: 0 0 0 4px transparent; } }

/* ---- HERO product demo (rotating tracker creation) — clean panel, no window chrome ---- */
.hero-viz { position: relative; min-width: 0; }
.hero-demo { display: flex; flex-direction: column; height: 648px; max-width: 100%; border-radius: var(--r-lg); border: 1px solid var(--plns); box-shadow: var(--shadow-pop); overflow: hidden; }
/* Keep the rotating chat + chart from inflating the hero column past the
   viewport on narrow screens (grid items default to min-width:auto), and let
   the chart FLEX to fill whatever vertical space the variable-length query
   leaves — long query => shorter chart, short query => taller chart — so the
   card never has to scroll. */
.hero-demo .pr-msg-user, .hero-demo .pr-msg-bot, .hero-demo .pr-bot-body { min-width: 0; }
.hero-demo .pr-chat { display: flex; flex-direction: column; }
.hero-demo .pr-msg-bot { flex: 1 1 auto; min-height: 0; align-items: stretch; }
.hero-demo .pr-bot-body { display: flex; flex-direction: column; min-height: 0; }
/* the pipeline always shows in full (never shrink/clip its steps); only the
   chart flexes to absorb the leftover space — its y-axis auto-scales to any
   height, so a shorter chart is fine. */
.hero-demo .pr-bot-body .pr-pipe { flex: 0 0 auto; }
.hero-demo .pr-bot-body .pr-result { max-width: 100%; min-width: 0; flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }
.hero-demo .pr-bot-body .pr-result-svg { max-width: 100%; min-width: 0; flex: 1 1 auto; min-height: 56px; height: auto; }
.hero-demo .pr-bot-body .pr-evlist { flex: 1 1 auto; }
.hero-demo-cap { display: flex; align-items: center; justify-content: space-between; padding: 13px 16px; border-bottom: 1px solid var(--plns); flex-shrink: 0; }
.hdc-label { font-size: 10px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--pf3); white-space: nowrap; }
.hdc-domain { font-size: 11px; color: var(--pf0); font-weight: 500; display: inline-flex; align-items: center; gap: 7px; }
.hdc-domain::before { content: ""; width: 6px; height: 6px; border-radius: 999px; background: var(--up); animation: breathe 2.4s var(--ease-in-out) infinite; }
.pr-domains { display: flex; flex-wrap: wrap; gap: 5px; padding: 12px 14px; border-bottom: 1px solid var(--plns); flex-shrink: 0; }
.pr-domain { font-family: 'IBM Plex Mono', monospace; font-size: 10px; letter-spacing: 0.04em; text-transform: uppercase; color: var(--pf3); border: 1px solid var(--pln); background: var(--pb1); padding: 3px 7px; transition: all .25s var(--ease-out); white-space: nowrap; cursor: pointer; }
.pr-domain:hover { color: var(--pf1); border-color: var(--plnh); }
.pr-domain.on { color: var(--on-accent); border-color: var(--accent); background: var(--accent); }
.pr-chat { flex: 1; padding: 16px; overflow-y: auto; position: relative; scrollbar-width: none; }
.pr-chat::-webkit-scrollbar { display: none; }

/* live result graph drawn after a tracker is created */
.pr-result { margin: 14px 0 2px 34px; border: 1px solid var(--pln); background: var(--pb1); border-radius: var(--r-sm); overflow: hidden; opacity: 0; transform: translateY(10px); transition: opacity .5s var(--ease-out), transform .5s var(--ease-out); }
.pr-result.draw { opacity: 1; transform: none; }
.pr-result-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 12px 7px; }
.pr-result-l { display: inline-flex; align-items: center; gap: 7px; font-family: 'IBM Plex Mono', monospace; font-size: 10px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--pf3); white-space: nowrap; }
.pr-result-live { width: 6px; height: 6px; border-radius: 999px; background: var(--accent); box-shadow: 0 0 0 0 var(--accent); animation: rcLive 1.8s var(--ease-in-out) infinite; flex-shrink: 0; }
@keyframes rcLive { 0%,100% { opacity: 1; } 50% { opacity: .35; } }
.pr-result-stat { font-family: 'IBM Plex Mono', monospace; font-size: 11px; color: var(--pf1); white-space: nowrap; }
.pr-result-delta { color: var(--accent); font-weight: 600; }
.pr-result-svg { width: 100%; max-width: 100%; height: 132px; display: block; --rc-soft: color-mix(in oklab, var(--accent) 28%, transparent); }
.pr-result-axis { display: flex; align-items: center; justify-content: space-between; padding: 6px 12px 9px; font-family: 'IBM Plex Mono', monospace; font-size: 9px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--pf4); }
/* event-tracker feed (events type) */
.pr-events .pr-result-stat { color: var(--pf3); }
.pr-evlist { list-style: none; margin: 0; padding: 4px 0 6px; }
.pr-evrow { display: grid; grid-template-columns: 8px 1fr auto; gap: 10px; align-items: start; padding: 9px 12px; border-top: 1px solid var(--plns); opacity: 0; transform: translateY(6px); }
.pr-result.draw .pr-evrow { animation: evRow .45s var(--ease-out) forwards; animation-delay: calc(var(--i) * 0.14s + 0.1s); }
@keyframes evRow { to { opacity: 1; transform: none; } }
.pr-evdot { width: 7px; height: 7px; border-radius: 999px; margin-top: 5px; }
.pr-evbody { min-width: 0; }
.pr-evt { display: block; font-size: 12.5px; color: var(--pf0); font-weight: 500; line-height: 1.3; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pr-evsrc { display: block; font-family: 'IBM Plex Mono', monospace; font-size: 10px; color: var(--pf3); margin-top: 3px; }
.pr-evtime { font-family: 'IBM Plex Mono', monospace; font-size: 10px; color: var(--pf4); white-space: nowrap; padding-top: 1px; }
html.reveal-instant .pr-evrow { opacity: 1; transform: none; animation: none; }
/* path-draw + bar-grow animations gated on .draw */
.pr-result .rc-line { stroke-dasharray: 600; stroke-dashoffset: 600; }
.pr-result.draw .rc-line { animation: rcDraw 1.3s var(--ease-out) forwards; }
@keyframes rcDraw { to { stroke-dashoffset: 0; } }
.pr-result .rc-area, .pr-result .rc-dot { opacity: 0; }
.pr-result.draw .rc-area { animation: rcFade .6s ease .7s forwards; }
.pr-result.draw .rc-dot { animation: rcFade .4s ease 1.2s forwards; }
@keyframes rcFade { to { opacity: 1; } }
.pr-result .rc-bar { transform: scaleY(0); transform-origin: bottom; transform-box: fill-box; }
.pr-result.draw .rc-bar { animation: rcBar .5s var(--ease-out) forwards; animation-delay: var(--d); }
@keyframes rcBar { to { transform: scaleY(1); } }
html.reveal-instant .pr-result { opacity: 1; transform: none; }
html.reveal-instant .pr-result .rc-line { stroke-dashoffset: 0; }
html.reveal-instant .pr-result .rc-area, html.reveal-instant .pr-result .rc-dot { opacity: 1; }
html.reveal-instant .pr-result .rc-bar { transform: scaleY(1); }

/* user message row (real product) */
.pr-msg-user { display: flex; gap: 10px; align-items: flex-start; padding: 10px 0 14px; border-bottom: 1px solid var(--plns); }
.pr-ava { width: 24px; height: 24px; background: var(--pb3); display: grid; place-items: center; font-size: 10.5px; font-weight: 600; flex-shrink: 0; color: var(--pf1); }
.pr-ava.bot { background: var(--pacb); color: var(--pac); }
.pr-msg-text { flex: 1; min-width: 0; font-size: 13.5px; color: var(--pf0); padding-top: 3px; line-height: 1.5; }
.pr-msg-text .pr-caret { display: inline-block; width: 2px; height: 14px; background: var(--pac); margin-left: 1px; vertical-align: -2px; animation: blink 1s step-end infinite; }
@keyframes blink { 50% { opacity: 0; } }

/* blueprint panel (real product Tracker Blueprint) */
.pr-bp { margin: 14px 0 0 34px; background: var(--pb1); border: 1px solid var(--pln); animation: bpIn .5s var(--ease-out); }
@keyframes bpIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.pr-bp-head { display: flex; align-items: center; justify-content: space-between; padding: 8px 12px; border-bottom: 1px solid var(--plns); background: var(--pb0); min-height: 34px; }
.pr-bp-head .pr-bp-title { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--pf1); white-space: nowrap; }
.pr-tgt { width: 13px; height: 13px; border: 1.5px solid var(--pac); border-radius: 50%; position: relative; flex-shrink: 0; }
.pr-tgt::after { content: ""; position: absolute; inset: 3.5px; border-radius: 50%; background: var(--pac); }
.pr-bp-conf { font-family: 'IBM Plex Mono', monospace; font-size: 10px; letter-spacing: 0.08em; color: var(--pac); opacity: 0; transition: opacity .3s; }
.pr-bp.confirmed .pr-bp-conf { opacity: 1; }
.pr-bp-body { padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; }
.pr-bp-row { display: grid; grid-template-columns: 88px 1fr; gap: 10px; align-items: start; }
.pr-bp-k { font-family: 'IBM Plex Mono', monospace; font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--pf3); padding-top: 2px; }
.pr-bp-val { font-size: 12.5px; color: var(--pf0); line-height: 1.45; }
.pr-bp-pills { display: flex; flex-wrap: wrap; gap: 5px; }
.pr-src { font-size: 11px; color: var(--pf1); background: var(--pb2); border: 1px solid var(--pln); padding: 1px 7px; white-space: nowrap; }
.pr-tag { font-family: 'IBM Plex Mono', monospace; font-size: 10.5px; color: var(--pf1); background: var(--pb2); border: 1px solid var(--pln); border-radius: 999px; padding: 1px 7px; white-space: nowrap; }
.pr-tag .h { opacity: .55; }
.pr-typetog { display: inline-flex; }
.pr-typetog b { font-size: 11px; font-weight: 500; padding: 2px 10px; border: 1px solid var(--pln); background: var(--pb2); color: var(--pf3); }
.pr-typetog b.on { background: var(--pacb); border-color: var(--pac); color: var(--pac); }
.pr-typetog b:first-child { border-right: none; }
.pr-bp-actions { display: flex; gap: 6px; padding: 0 12px 12px; }

/* DATA PIPELINE card — shown instead of a blueprint (how the data is
   acquired + transformed into signal). Frameless white in the Stone preset. */
.pr-pipe { margin: 14px 0 0 34px; background: var(--pb1); border: 1px solid var(--pln); border-radius: var(--r-md); overflow: hidden; }
/* non-animated (reduced-motion) insert gets a gentle fade; the animated
   ".gen" path is driven by JS (.shown + staggered stages) so it must NOT
   also run bpIn — that caused the card to flash before the message. */
.pr-pipe:not(.gen) { animation: bpIn .5s var(--ease-out); }
.hero-demo .pr-pipe, .pr-pipe.compact { margin: 12px 0 0; }
/* hero assistant message: bot logo + a content column holding the pipeline
   and the result chart so they align (same left edge, under the avatar). */
.pr-msg-bot { display: flex; gap: 10px; align-items: flex-start; padding: 14px 0 2px; }
.pr-bot-body { flex: 1; min-width: 0; }
.pr-bot-body .pr-pipe { margin: 0; }
.pr-bot-body .pr-result { margin: 12px 0 0; }
.pr-pipe-head { display: flex; align-items: center; gap: 8px; padding: 8px 12px; border-bottom: 1px solid var(--plns); font-size: 12px; color: var(--pf1); }
.pr-pipe-conf { margin-left: auto; font-family: 'IBM Plex Mono', monospace; font-size: 10px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--pac); }
.pr-pipe-body { position: relative; padding: 8px 12px 10px; }
.pp-rail { position: absolute; left: 23.5px; top: 24px; bottom: 24px; width: 1px; background: var(--plns); }
.pp-stage { position: relative; display: grid; grid-template-columns: 24px 1fr auto; gap: 10px; align-items: start; padding: 6px 0; }
.pp-ic { width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--plns); display: grid; place-items: center; color: var(--pf2); background: var(--pb1); position: relative; z-index: 1; }
.pp-stage:last-child .pp-ic { color: var(--pac); border-color: var(--pac); background: var(--pacb); }
.pp-main { min-width: 0; }
.pp-t { font-size: 12px; font-weight: 500; color: var(--pf0); line-height: 1.2; }
.pp-d { font-size: 11px; color: var(--pf2); line-height: 1.4; margin-top: 2px; }
.pp-tag { font-size: 9.5px; color: var(--pf3); align-self: center; white-space: nowrap; }
.pr-pipe.compact .pp-d { font-size: 10.5px; }
.pr-pipe.compact .pp-stage { padding: 5px 0; }
/* "generating" reveal — the card fades in after the bot replies, then its
   stages appear one-by-one, then the connector rail fades in. */
.pr-pipe.gen { opacity: 0; transform: translateY(8px); transition: opacity .35s var(--ease-out), transform .35s var(--ease-out); }
.pr-pipe.gen.shown { opacity: 1; transform: none; }
.pr-pipe.gen .pp-stage { opacity: 0; transform: translateY(6px); transition: opacity .35s var(--ease-out), transform .35s var(--ease-out); }
.pr-pipe.gen .pp-stage.in { opacity: 1; transform: none; }
.pr-pipe.gen .pp-rail { opacity: 0; transition: opacity .45s var(--ease-out); }
.pr-pipe.gen.railon .pp-rail { opacity: 1; }
html.reveal-instant .pr-pipe.gen, html.reveal-instant .pr-pipe.gen .pp-stage, html.reveal-instant .pr-pipe.gen .pp-rail { opacity: 1 !important; transform: none !important; }
@media (prefers-reduced-motion: reduce) { .pr-pipe.gen, .pr-pipe.gen .pp-stage, .pr-pipe.gen .pp-rail { opacity: 1; transform: none; } }
.pr-btn { display: inline-flex; align-items: center; gap: 5px; height: 26px; padding: 0 10px; font-size: 11.5px; font-weight: 500; border: 1px solid var(--pln); background: var(--pb1); color: var(--pf0); }
.pr-btn.primary { background: var(--pac); color: var(--pb0); border-color: var(--pac); font-weight: 600; }
.pr-btn.ghost { background: transparent; border-color: transparent; color: var(--pf2); }

/* ---------------- MARQUEE ---------------- */
.marquee-band { padding-block: 32px; border-block: 1px solid var(--hairline); overflow: hidden; background: var(--bg-2); }
.marq-label { display: block; text-align: center; margin-bottom: 22px; }
.marquee { position: relative; -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); }
.marquee-track { display: flex; gap: 54px; width: max-content; animation: marq 42s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marq { to { transform: translateX(-50%); } }
.marq-item { display: inline-flex; align-items: center; gap: 11px; font-size: 17px; font-weight: 500; color: var(--text-2); letter-spacing: -0.01em; white-space: nowrap; }
.marq-item .md { width: 5px; height: 5px; border-radius: 999px; background: var(--accent); opacity: .55; }

/* ---------------- SECTION HEADS ---------------- */
.sec-head { margin-bottom: clamp(40px, 5vw, 64px); }
.sec-head.center { text-align: center; }
.sec-head.center .overline { justify-content: center; }
.sec-head .overline { margin-bottom: 18px; }

/* ---------------- HOW IT WORKS (redesigned) ---------------- */
.how-intro { max-width: 560px; margin-top: 18px; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; align-items: stretch; }
.steps .step-arrow { align-self: center; display: grid; place-items: center; color: var(--fg-4); }
.steps .step-arrow svg { width: 22px; height: 22px; }
@media (max-width: 900px) {
  .steps { grid-template-columns: 1fr; gap: 14px; }
  .steps .step-arrow { transform: rotate(90deg); padding: 4px 0; }
}
.step { display: flex; flex-direction: column; min-width: 0; }
.step-head { display: flex; align-items: center; gap: 11px; margin-bottom: 12px; }
.step-num { font-family: var(--mono); font-size: 14px; font-weight: 600; color: var(--on-accent); background: var(--accent); letter-spacing: 0; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0; }
.step-title { font-size: 18px; font-weight: 600; letter-spacing: -0.02em; white-space: nowrap; }
/* min-height equalizes the (1–2 line) descriptions so every snippet box
   starts at the same Y — keeps the three captions in a clean row. */
.step-desc { color: var(--text-2); font-size: 14.5px; line-height: 1.55; margin-bottom: 18px; min-height: 45px; }
/* Snippet boxes share a min-height so the row aligns top AND bottom even
   though their content (composer / blueprint / alert) differs in size. */
.step-snip { flex: 1; margin-top: 0; min-height: 168px; border-radius: var(--r-md); padding: 12px; background: var(--pb1); border: 1px solid var(--plns); display: flex; flex-direction: column; }
.snip-caption { font-size: 9.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--pf3); margin-bottom: 9px; }

/* step 1 — composer snippet */
.snip-composer { flex: 1; display: flex; align-items: flex-start; gap: 8px; border: 1px solid var(--plns); background: var(--pb2); padding: 14px 14px; }
.snip-typed { flex: 1; font-size: 15.5px; color: var(--pf0); line-height: 1.5; }
.snip-caret { display: inline-block; width: 2px; height: 18px; margin-top: 2px; background: var(--pac); animation: blink 1s step-end infinite; flex-shrink: 0; }
.snip-send { width: 24px; height: 24px; display: grid; place-items: center; background: var(--pac); color: var(--pb0); flex-shrink: 0; }
.snip-hint { font-size: 10px; color: var(--pf3); margin-top: 8px; text-align: right; font-family: 'IBM Plex Mono', monospace; }

/* step 2 — blueprint snippet */
.snip-panel { border: 1px solid var(--plns); background: var(--pb1); }
.snip-panel-head { display: flex; align-items: center; gap: 7px; padding: 7px 11px; border-bottom: 1px solid var(--plns); background: var(--pb1); font-family: 'IBM Plex Mono', monospace; font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--pf2); }
.snip-tgt { width: 11px; height: 11px; border: 1.5px solid var(--pac); border-radius: 50%; position: relative; }
.snip-tgt::after { content: ""; position: absolute; inset: 3px; border-radius: 50%; background: var(--pac); }
.snip-rows { padding: 10px 11px; display: flex; flex-direction: column; gap: 7px; }
.snip-row { display: grid; grid-template-columns: 62px 1fr; gap: 8px; align-items: center; }
.snip-k { font-family: 'IBM Plex Mono', monospace; font-size: 9px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--pf3); }
.snip-v { font-size: 11.5px; color: var(--pf0); line-height: 1.3; }
.snip-pills { display: flex; gap: 4px; }
.snip-src { font-size: 10px; color: var(--pf1); background: var(--pb2); border: 1px solid var(--pln); padding: 1px 6px; white-space: nowrap; }
.snip-type { font-size: 10.5px; color: var(--pac); background: var(--pacb); border: 1px solid var(--pac); padding: 1px 8px; }

/* step 3 — alert snippet */
.snip-alert { display: grid; grid-template-columns: 8px 30px 1fr; gap: 9px; align-items: center; border: 1px solid var(--pln); background: var(--pb1); padding: 11px 12px; border-left: 2px solid var(--pal); }
.snip-adot { width: 6px; height: 6px; background: var(--pal); box-shadow: 0 0 0 3px var(--palb); }
.snip-asc { font-size: 11px; font-weight: 600; color: var(--pdn); font-family: 'IBM Plex Mono', monospace; }
.snip-abody { min-width: 0; }
.snip-at { font-size: 12px; color: var(--pf0); font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.snip-asrc { font-size: 10px; color: var(--pf3); margin-top: 2px; }
/* step 3 mini-chart filling the alert snippet space */
.snip-chart { margin-top: auto; padding-top: 11px; }
.snip-chart-cap { display: flex; justify-content: space-between; font-size: 9px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--pf3); margin-bottom: 7px; }
.snip-chart-thr { color: var(--pal); }
.snip-chart svg { display: block; }
.snip-outputs { display: flex; gap: 6px; margin-top: 10px; }
.snip-chip { font-size: 10.5px; color: var(--pf2); border: 1px solid var(--pln); padding: 4px 9px; font-family: 'IBM Plex Mono', monospace; letter-spacing: 0.04em; }

/* ============================================================
   PRODUCT DEMO WINDOW — real Tracken (sidebar + statusbar + scenes)
   ============================================================ */
.demo-wrap { margin-top: 8px; }
/* Breather + hairline between the trackers dashboard mock and the feature list. */
.cap-rule { height: 1px; background: var(--line-soft); margin: clamp(48px, 6vw, 84px) 0 clamp(40px, 5vw, 64px); }
.window { border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--plns); box-shadow: var(--shadow-pop); }
.win-bar { display: flex; align-items: center; gap: 14px; height: 42px; padding: 0 15px; background: var(--pb1); border-bottom: 1px solid var(--plns); }
.win-dots { display: flex; gap: 7px; }
.win-dots span { width: 11px; height: 11px; border-radius: 999px; background: var(--pb4); }
.win-spacer { width: 47px; flex-shrink: 0; }
.win-url { flex: 1; text-align: center; font-family: 'IBM Plex Mono', monospace; font-size: 12px; color: var(--pf3); display: flex; align-items: center; justify-content: center; gap: 7px; }
.win-lock { color: var(--pf4); font-size: 9px; }
.win-live { display: flex; align-items: center; gap: 7px; font-family: 'IBM Plex Mono', monospace; font-size: 10px; letter-spacing: 0.14em; color: var(--pf3); }
.win-body { display: grid; grid-template-columns: 208px 1fr; height: min(66vh, 600px); min-height: 480px; }
/* The Capabilities trackers dashboard runs sidebar-less — let the grid fill the frame. */
#trackersWin .win-body { grid-template-columns: 1fr; }

.pr-side { border-right: 1px solid var(--plns); background: color-mix(in oklab, var(--pb1), var(--pf0) 4%); display: flex; flex-direction: column; }
.pr-side-brand { display: flex; align-items: center; gap: 8px; padding: 14px 14px 12px; }
.pr-side-word { font-size: 16px; font-weight: 600; letter-spacing: -0.015em; }
.pr-side-new { margin: 0 10px 10px; display: flex; align-items: center; justify-content: space-between; border: 1px solid var(--pln); background: var(--pb1); padding: 6px 9px; font-size: 12.5px; color: var(--pf1); }
.pr-plus { color: var(--pf2); }
.pr-kbd { font-family: 'IBM Plex Mono', monospace; font-size: 10px; color: var(--pf2); background: var(--pb2); border: 1px solid var(--pln); padding: 0 5px; }
.pr-nav { padding: 0 8px; display: flex; flex-direction: column; gap: 1px; }
.pr-nav-item { display: flex; align-items: center; gap: 9px; padding: 6px 9px; font-size: 12.5px; color: var(--pf2); position: relative; }
.pr-nav-item.on { background: var(--pb2); color: var(--pf0); font-weight: 500; }
.pr-nav-item.on::before { content: ""; position: absolute; left: -8px; top: 6px; bottom: 6px; width: 2px; background: var(--pac); }
.pr-nav-item .pr-ni-label { flex: 1; }
.pr-nav-item .pr-ni-badge { font-family: 'IBM Plex Mono', monospace; font-size: 9.5px; color: var(--pf3); }
/* unread-alert badge — matches the app's alert-colored count on Trackers */
.pr-nav-item .pr-ni-badge.alert { color: var(--pal); background: var(--palb); border: 1px solid color-mix(in oklab, var(--pal) 40%, transparent); padding: 0 5px; min-width: 16px; text-align: center; }
.pr-nav-item .pr-kbd { font-size: 9px; }
.pr-nav-ic { width: 14px; height: 14px; flex-shrink: 0; }
.pr-side-hist { flex: 1; overflow: hidden; padding: 12px 8px 0; margin-top: 12px; border-top: 1px solid var(--pln); }
.pr-hist-label { font-family: 'IBM Plex Mono', monospace; font-size: 9.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--pf3); padding: 4px 9px; }
.pr-hist { font-size: 12px; color: var(--pf2); padding: 5px 9px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pr-side-user { display: flex; align-items: center; gap: 9px; padding: 8px 14px 12px; border-top: 1px solid var(--pln); }
.pr-avatar { width: 26px; height: 26px; background: var(--pb3); display: grid; place-items: center; font-size: 11px; font-weight: 600; color: var(--pf1); flex-shrink: 0; }
.pr-user-meta { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.pr-uname { font-size: 11.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--pf0); }
.pr-uorg { font-size: 10px; color: var(--pf3); }
@media (max-width: 760px) { .win-body { grid-template-columns: 1fr; } .pr-side { display: none; } }

.pr-main { display: flex; flex-direction: column; min-width: 0; background: var(--pb0); }
.pr-statusbar { display: flex; align-items: center; gap: 16px; height: 28px; padding: 0 16px; border-bottom: 1px solid var(--plns); font-size: 11px; flex-shrink: 0; }
.pr-sb-left { display: inline-flex; align-items: center; gap: 7px; }
.pr-sb-active { font-family: 'IBM Plex Mono', monospace; color: var(--pf2); }
.pr-sb-issues { font-family: 'IBM Plex Mono', monospace; color: var(--pf3); }
.pr-sb-right { margin-left: auto; display: inline-flex; align-items: center; gap: 16px; font-family: 'IBM Plex Mono', monospace; color: var(--pf2); }
.demo-stage { position: relative; flex: 1; overflow: hidden; }
.scene { position: absolute; inset: 0; opacity: 0; transition: opacity .45s var(--ease-out); pointer-events: none; overflow: auto; }
.scene.on { opacity: 1; }

/* DEMO scene: chat empty (real /chat) */
.dchat { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px; text-align: center; padding: 24px; }
.dchat-logo { color: var(--pac); }
.dchat-title { font-size: 22px; font-weight: 500; letter-spacing: -0.015em; color: var(--pf0); }
.dchat-sub { font-size: 13px; color: var(--pf2); margin-top: 6px; max-width: 460px; }
.dchat-composer { width: min(560px, 94%); border: 1px solid var(--plns); background: var(--pb2); padding: 10px 12px 8px; display: flex; flex-direction: column; }
.dchat-ta { min-height: 42px; font-size: 13px; color: var(--pf0); text-align: left; }
.dchat-typed { color: var(--pf0); }
.dchat-caret { display: inline-block; width: 2px; height: 16px; background: var(--pac); vertical-align: -3px; animation: blink 1s step-end infinite; }
.dchat-bar { display: flex; align-items: center; justify-content: flex-end; gap: 8px; margin-top: 6px; }
.dchat-hint { font-family: 'IBM Plex Mono', monospace; font-size: 10px; color: var(--pf3); }
.dchat-send { display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 10px; background: var(--pac); color: var(--pb0); font-size: 11.5px; font-weight: 600; }
.dchat-sugs { width: min(560px, 94%); display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.dchat-sug { display: flex; align-items: center; gap: 8px; text-align: left; padding: 9px 11px; background: var(--pb1); border: 1px solid var(--pln); color: var(--pf1); font-size: 12px; }
.dchat-sug .sg-ic { color: var(--pac); flex-shrink: 0; }

/* DEMO scene: blueprint conversation */
.dconv { padding: 20px 24px; max-width: 760px; margin: 0 auto; }

/* DEMO scene: dashboard (real DashboardView) */
.ddash { padding: 18px 22px 30px; }
.ddash-head { margin-bottom: 16px; }
.ddash-h1 { font-size: 22px; font-weight: 500; letter-spacing: -0.015em; color: var(--pf0); }
.ddash-counts { margin-top: 4px; font-size: 12.5px; color: var(--pf3); }
.pr-panel { background: var(--pb1); border: 1px solid var(--pln); margin-bottom: 16px; }
.pr-panel-head { display: flex; align-items: center; justify-content: space-between; padding: 8px 12px; border-bottom: 1px solid var(--plns); background: var(--pb1); font-family: 'IBM Plex Mono', monospace; font-size: 10.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--pf2); min-height: 34px; }
.pr-panel-head .pp-l { display: flex; align-items: center; gap: 8px; }
.pr-panel-head .pp-r { font-size: 10px; color: var(--pf3); display: flex; align-items: center; gap: 10px; }
.pr-ic { width: 12px; height: 12px; }
.pr-pill-alert { display: inline-flex; align-items: center; padding: 1px 6px; font-family: 'IBM Plex Mono', monospace; font-size: 10px; letter-spacing: 0.04em; color: var(--pal); background: var(--palb); border: 1px solid color-mix(in oklab, var(--pal) 40%, transparent); }
.pr-alert { display: grid; grid-template-columns: 10px 52px 150px 1fr 56px; gap: 10px; align-items: center; padding: 8px 14px; border-bottom: 1px solid var(--plns); font-size: 12px; }
.pr-alert:last-child { border-bottom: none; }
.pr-adot { width: 6px; height: 6px; background: var(--pal); box-shadow: 0 0 0 3px var(--palb); }
.pr-asc { font-family: 'IBM Plex Mono', monospace; font-size: 10.5px; }
.pr-atrk { font-size: 11.5px; color: var(--pf2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pr-atitle { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--pf0); font-weight: 500; }
.pr-atitle .pr-asum { color: var(--pf2); font-weight: 400; }
.pr-atime { font-family: 'IBM Plex Mono', monospace; font-size: 10px; color: var(--pf3); text-align: right; }
.pr-2col { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
@media (max-width: 720px) { .pr-2col { grid-template-columns: 1fr; } }
.pr-trow { display: grid; grid-template-columns: 1fr 70px; gap: 10px; align-items: center; padding: 10px 14px; border-bottom: 1px solid var(--plns); border-left: 2px solid var(--pac); }
.pr-trow:last-child { border-bottom: none; }
.pr-trow.err { border-left-color: var(--pdn); }
.pr-tname { font-size: 12.5px; color: var(--pf0); font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: flex; align-items: center; gap: 6px; }
.pr-tname .pr-undot { width: 6px; height: 6px; background: var(--pal); flex-shrink: 0; }
.pr-tval { font-family: 'IBM Plex Mono', monospace; font-size: 11px; color: var(--pf3); margin-top: 3px; display: flex; gap: 7px; align-items: center; }
.pr-tval .v { color: var(--pf1); }
.pr-tval .up { color: var(--pup); } .pr-tval .down { color: var(--pdn); }
.pr-tlast { font-size: 11px; color: var(--pf2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-top: 3px; }
.pr-spark svg { display: block; }
.pr-srow { display: block; padding: 10px 14px; border-bottom: 1px solid var(--plns); }
.pr-srow:last-child { border-bottom: none; }
.pr-srow.live { background: var(--pb2); }
.pr-srow-top { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; }
.pr-spill { font-family: 'IBM Plex Mono', monospace; font-size: 9.5px; letter-spacing: 0.06em; text-transform: uppercase; padding: 1px 6px; border: 1px solid var(--pln); color: var(--pf2); }
.pr-spill.done { color: var(--pup); background: var(--pupb); border-color: transparent; }
.pr-spill.run { color: var(--pac); background: var(--pacb); border-color: transparent; }
.pr-shyp { flex: 1; font-size: 12px; color: var(--pf0); font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pr-stime { font-family: 'IBM Plex Mono', monospace; font-size: 10px; color: var(--pf3); flex-shrink: 0; }
.pr-simpacts { display: flex; align-items: center; gap: 12px; font-size: 11px; }
.pr-simp { font-family: 'IBM Plex Mono', monospace; }
.pr-simp .a { color: var(--pf3); } .pr-simp .up { color: var(--pup); } .pr-simp .down { color: var(--pdn); }
.pr-sscen { font-family: 'IBM Plex Mono', monospace; font-size: 10px; color: var(--pf3); margin-left: auto; letter-spacing: 0.04em; }
.pr-panel-foot { padding: 8px 14px; border-top: 1px solid var(--plns); background: var(--pb1); font-family: 'IBM Plex Mono', monospace; font-size: 11px; color: var(--pac); }

/* DEMO scene: tracker detail (the metric tracker the query just created) */
.dtrk { padding: 16px 22px 26px; }
.dtrk-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 14px; }
.dtrk-badges { display: flex; align-items: center; gap: 10px; margin-bottom: 7px; }
.dtrk-badge { font-family: 'IBM Plex Mono', monospace; font-size: 9.5px; letter-spacing: 0.12em; padding: 2px 7px; background: var(--pacb); color: var(--pac); border: 1px solid color-mix(in oklab, var(--pac) 40%, transparent); }
.dtrk-status { display: inline-flex; align-items: center; gap: 6px; font-family: 'IBM Plex Mono', monospace; font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--pup); }
.dtrk-title { font-size: 21px; font-weight: 500; letter-spacing: -0.015em; color: var(--pf0); }
.dtrk-sub { font-size: 11px; color: var(--pf3); margin-top: 4px; letter-spacing: 0.01em; }
.dtrk-actions { display: flex; gap: 6px; flex-shrink: 0; }
.dtrk-act { font-size: 10.5px; color: var(--pf2); border: 1px solid var(--pln); padding: 4px 10px; font-family: 'IBM Plex Mono', monospace; letter-spacing: 0.04em; }
.dtrk-ranges { gap: 4px !important; }
.dtrk-range { font-family: 'IBM Plex Mono', monospace; font-size: 9.5px; letter-spacing: 0.04em; padding: 2px 6px; color: var(--pf3); border: 1px solid transparent; }
.dtrk-range.on { color: var(--pac); border-color: color-mix(in oklab, var(--pac) 35%, transparent); background: var(--pacb); }
.dtrk-chart { padding: 12px 12px 8px; }
.dtrk-svg { display: block; }
.dtrk-grid { display: grid; grid-template-columns: 256px 1fr; gap: 16px; align-items: start; }
@media (max-width: 720px) { .dtrk-grid { grid-template-columns: 1fr; } }
.dtrk-statpanel, .dtrk-evtpanel { margin-bottom: 0; }
.dtrk-stat-body { padding: 14px; }
.dtrk-cur { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.dtrk-cur-v { font-size: 34px; font-weight: 500; letter-spacing: -0.02em; color: var(--pf0); line-height: 1; font-variant-numeric: tabular-nums; }
.dtrk-cur-d { font-family: 'IBM Plex Mono', monospace; font-size: 12px; }
.dtrk-cur-d.up { color: var(--pup); } .dtrk-cur-d.down { color: var(--pdn); }
.dtrk-cur-ago { color: var(--pf3); }
.dtrk-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; margin-top: 16px; background: var(--plns); border: 1px solid var(--plns); }
.dtrk-stat { display: flex; align-items: baseline; justify-content: space-between; padding: 8px 10px; background: var(--pb1); }
.dtrk-stat .k { font-size: 9px; letter-spacing: 0.1em; color: var(--pf3); }
.dtrk-stat .v { font-size: 13px; color: var(--pf0); font-variant-numeric: tabular-nums; }
.dtrk-sched { margin-top: 10px; display: flex; align-items: baseline; justify-content: space-between; font-size: 11px; color: var(--pf2); }
.dtrk-sched:first-of-type { margin-top: 16px; padding-top: 13px; border-top: 1px solid var(--plns); }
.dtrk-sched-k { font-size: 9.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--pf3); }
.dtrk-rule { margin-top: 12px; display: flex; align-items: center; gap: 7px; font-size: 10px; letter-spacing: 0.04em; color: var(--pf3); }
.dtrk-rule-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--pal); flex-shrink: 0; }
.dtrk-evt { display: grid; grid-template-columns: 38px 1fr; gap: 10px; align-items: start; padding: 10px 14px; border-bottom: 1px solid var(--plns); border-left: 2px solid var(--pal); }
.dtrk-evt:last-of-type { border-bottom: none; }
.dtrk-evt.dim { border-left-color: var(--pln); opacity: .62; }
.dtrk-evt-sc { font-size: 11px; font-weight: 600; padding-top: 1px; }
.dtrk-evt-t { font-size: 12.5px; color: var(--pf0); font-weight: 500; line-height: 1.35; }
.dtrk-evt-sum { font-size: 10px; color: var(--pf3); margin-top: 3px; }
/* alerts pop in one-by-one */
.dtrk-evtpanel.evgen .dtrk-evt { opacity: 0; transform: translateY(6px); transition: opacity .35s var(--ease-out), transform .35s var(--ease-out); }
.dtrk-evtpanel.evgen .dtrk-evt.in { opacity: 1; transform: none; }
html.reveal-instant .dtrk-evtpanel.evgen .dtrk-evt { opacity: 1 !important; transform: none !important; }
@media (prefers-reduced-motion: reduce) { .dtrk-evtpanel.evgen .dtrk-evt { opacity: 1; transform: none; } }

/* TRACKERS page mockup — mirrors the app's MetricCard / TrackerCard exactly
   (Stone preset: frameless white cards, hairline internal dividers). */
.trk-page { padding: 16px 18px 24px; overflow: auto; }
.trk-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 14px; }
.trk-h1 { font-size: 22px; font-weight: 500; letter-spacing: -0.015em; color: var(--pf0); }
.trk-counts { font-size: 12.5px; color: var(--pf3); }
.trk-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 12px; }
.trk-card { display: flex; flex-direction: column; background: var(--pb1); border: 1px solid var(--pln); border-left: var(--pln); border-radius: var(--r-md); overflow: hidden; }
.trk-strip { display: flex; align-items: center; gap: 8px; padding: 7px 12px; }
.trk-strip-head { border-bottom: 1px solid var(--plns); }
.trk-strip-foot { justify-content: space-between; border-top: 1px solid var(--plns); font-size: 10px; color: var(--pf3); margin-top: auto; }
.trk-foot-l { flex-shrink: 0; white-space: nowrap; }
.trk-foot-r { display: inline-flex; align-items: center; gap: 5px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.trk-live-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--pac); flex-shrink: 0; }
.trk-kind { font-size: 9.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--pac); flex-shrink: 0; }
.trk-srcname { font-size: 9.5px; color: var(--pf3); letter-spacing: 0.06em; flex: 1; text-align: right; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.trk-pill-alert { font-size: 9px; color: var(--pal); background: var(--palb); border: 1px solid color-mix(in oklab, var(--pal) 40%, transparent); padding: 0 5px; letter-spacing: 0.06em; flex-shrink: 0; }
.trk-body { flex: 1; display: flex; flex-direction: column; gap: 14px; padding: 14px 12px; }
.trk-name { font-size: 13.5px; font-weight: 500; color: var(--pf0); line-height: 1.3; }
.trk-valrow { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; }
.trk-val { font-size: 30px; font-weight: 500; color: var(--pf0); line-height: 1; letter-spacing: -0.02em; display: flex; align-items: baseline; gap: 8px; }
.trk-unit { font-size: 13px; font-weight: 600; color: var(--pf3); letter-spacing: 0; }
.trk-delta-wrap { margin-top: 8px; }
.trk-delta { font-size: 12px; }
.trk-delta.up { color: var(--pup); } .trk-delta.down { color: var(--pdn); }
.trk-spark { flex-shrink: 0; }
.trk-spark svg { width: 140px; height: 52px; display: block; }
.trk-tags { display: flex; flex-wrap: wrap; gap: 4px; }
.trk-tag { font-size: 10px; color: var(--pf2); background: var(--pb2); border: 1px solid var(--pln); border-radius: 999px; padding: 1px 6px; line-height: 1.4; }
.trk-tag .h { opacity: 0.6; }
.trk-ehead { padding: 12px 12px; border-bottom: 1px solid var(--plns); display: flex; flex-direction: column; gap: 6px; }
.trk-erow { display: flex; align-items: center; gap: 8px; }
.trk-erow .trk-name { flex: 1; font-size: 13px; line-height: 1.25; }
.trk-status { display: inline-flex; align-items: center; gap: 4px; padding: 1px 6px; font-size: 9.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--pup); background: var(--pupb); border: 1px solid var(--pup); flex-shrink: 0; }
.trk-status-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--pup); }
.trk-goal { font-size: 11.5px; color: var(--pf2); line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.trk-ev { display: grid; grid-template-columns: 8px 1fr 50px; gap: 8px; align-items: start; padding: 7px 12px; border-bottom: 1px solid var(--plns); }
.trk-ev.last { border-bottom: none; }
.trk-ev-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--pac); margin-top: 5px; }
.trk-ev-dot.hi { background: var(--pal); }
.trk-ev-body { min-width: 0; }
.trk-ev-t { font-size: 11.5px; color: var(--pf0); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.trk-ev-s { font-size: 10.5px; color: var(--pf3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-top: 1px; }
.trk-ev-time { font-size: 9.5px; color: var(--pf3); text-align: right; }

/* Stone-default rounding (subtle radius) across the product mockup elements —
   pills/kbd → xs, buttons/inputs/avatars → sm, panels/cards → md.
   (.card / .cap-panel / .hero-demo / .window already round on their own.) */
.pr-panel, .pr-bp, .snip-panel { border-radius: var(--r-md); overflow: hidden; }
.dtrk-stats, .pr-typetog { border-radius: var(--r-sm); overflow: hidden; }
.pr-btn, .snip-send, .pr-side-new, .pr-nav-item, .dchat-composer, .snip-composer,
.dchat-sug, .dtrk-act, .snip-type, .snip-alert, .pr-avatar, .pr-ava { border-radius: var(--r-sm); }
.pr-src, .snip-src, .pr-kbd, .pr-spill, .dtrk-badge, .pr-ni-badge, .dtrk-range { border-radius: var(--r-xs); }

/* DEMO choreography — staged element reveal, typing dots, chart draw */
.d-rise { opacity: 0; transform: translateY(10px); transition: opacity .5s var(--ease-out), transform .5s var(--ease-out); }
.d-rise.in { opacity: 1; transform: none; }
.conv-think { display: inline-flex; gap: 4px; align-items: center; height: 18px; }
.conv-think i { width: 5px; height: 5px; border-radius: 50%; background: var(--pf3); animation: convDot 1.1s infinite ease-in-out; }
.conv-think i:nth-child(2) { animation-delay: .15s; }
.conv-think i:nth-child(3) { animation-delay: .3s; }
@keyframes convDot { 0%, 60%, 100% { transform: translateY(0); opacity: .35; } 30% { transform: translateY(-4px); opacity: .9; } }
.dtrk-dot { opacity: 0; transition: opacity .4s ease 1s; }
.dtrk-dot.in { opacity: 1; }
.pr-btn.primary.clicked { animation: btnPress .42s var(--ease-out); }
.dchat-send.ready { animation: btnPress .42s var(--ease-out); }
@keyframes btnPress { 40% { transform: scale(.95); } 100% { transform: scale(1); } }
html.reveal-instant .d-rise { opacity: 1 !important; transform: none !important; }
html.reveal-instant .dtrk-dot { opacity: 1 !important; }
html.reveal-instant .conv-think { display: none !important; }
@media (prefers-reduced-motion: reduce) { .d-rise { opacity: 1; transform: none; } .conv-think i { animation: none; } }

/* the 3 steps double as the demo scrubber — now ABOVE the window. Each step
   shows its number + title + description and a progress bar that fills over
   the scene's duration; clicking jumps to that scene. */
.demo-scrub { margin-bottom: 24px; }
.demo-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
@media (max-width: 760px) { .demo-steps { grid-template-columns: 1fr; gap: 16px; } }
.ds-step { display: flex; flex-direction: column; gap: 12px; padding-top: 13px; text-align: left; background: none; border: none; cursor: pointer; opacity: .5; transition: opacity .3s; }
.ds-step.active { opacity: 1; }
.ds-bar { display: block; height: 2px; border-radius: 2px; background: var(--line); position: relative; overflow: hidden; }
.ds-step.active .ds-bar::after { content: ""; position: absolute; inset: 0; background: var(--accent); animation: scrubFill var(--scene-dur, 4s) linear forwards; transform-origin: left; }
.ds-step.done .ds-bar { background: var(--accent-line); }
.ds-head { display: flex; align-items: center; gap: 11px; }
.ds-num { width: 26px; height: 26px; border-radius: 50%; background: var(--accent); color: var(--on-accent); font-family: var(--mono); font-size: 12.5px; font-weight: 600; display: grid; place-items: center; flex-shrink: 0; }
.ds-step b { font-size: 17px; font-weight: 600; letter-spacing: -0.02em; color: var(--fg-0); }
.ds-s { display: none; } /* short step label (Ask/Build/Track) — mobile only */
.ds-desc { font-size: 14px; line-height: 1.55; color: var(--text-2); }
@keyframes scrubFill { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* ---------------- CAPABILITIES (readable rows + animated demos) ---------------- */
.caps { display: flex; flex-direction: column; border-top: 1px solid var(--line); }
.cap {
  display: grid; grid-template-columns: 60px minmax(0, 1fr) minmax(0, 1.05fr);
  gap: clamp(20px, 4vw, 60px); align-items: center;
  padding: clamp(34px, 5vw, 56px) 0; border-bottom: 1px solid var(--line);
}
.cap-idx { font-family: var(--mono); font-size: 13px; color: var(--fg-3); font-variant-numeric: tabular-nums; padding-top: 4px; }
.cap-copy { max-width: 420px; }
.cap-tag { font-family: var(--mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--fg-3); display: block; margin-bottom: 14px; }
.cap-h { font-size: clamp(24px, 3vw, 34px); font-weight: 600; letter-spacing: -0.03em; line-height: 1.05; margin-bottom: 14px; }
.cap-desc { font-size: 16px; line-height: 1.6; color: var(--fg-2); }
.cap-demo { position: relative; }
@media (max-width: 860px) {
  .cap { grid-template-columns: 1fr; gap: 22px; }
  .cap-idx { display: none; }
}

/* the demo panel shell (product surface) */
/* the 4 Product-section demo panels render flat (Stone): no outer frame, no
   shadow — they separate by background lift + hairline internal dividers. */
.cap-panel { background: var(--bg-1); border-radius: var(--r-md); overflow: hidden; }
.cap-panel-head { display: flex; align-items: center; justify-content: space-between; padding: 9px 12px; border-bottom: 1px solid var(--line-soft); background: var(--bg-2); font-family: var(--mono); font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--fg-3); }
.cap-panel-head .cph-l { display: inline-flex; align-items: center; gap: 8px; }
.cap-panel-body { padding: 14px; }

/* event list demo */
.cap-evt { display: grid; grid-template-columns: 40px 1fr auto; gap: 11px; align-items: center; padding: 9px 4px; border-bottom: 1px solid var(--line-soft); opacity: 0; transform: translateY(8px); }
.cap-evt:last-child { border-bottom: none; }
.cap.in .cap-evt { animation: capItem .5s var(--ease-out) forwards; }
.cap.in .cap-evt:nth-child(1) { animation-delay: .1s; } .cap.in .cap-evt:nth-child(2) { animation-delay: .25s; } .cap.in .cap-evt:nth-child(3) { animation-delay: .4s; }
@keyframes capItem { to { opacity: 1; transform: none; } }
.cap-evt-sc { font-family: var(--mono); font-size: 12.5px; font-weight: 600; }
.cap-evt-t { font-size: 12.5px; color: var(--fg-0); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cap-evt-src { font-family: var(--mono); font-size: 10px; color: var(--fg-3); margin-top: 3px; display: flex; align-items: center; gap: 7px; }
.sig-chip { display: inline-flex; align-items: center; font-family: var(--mono); font-size: 9px; letter-spacing: 0.05em; text-transform: uppercase; padding: 1px 6px; border-radius: 3px; white-space: nowrap; }
.cap-evt-spark svg { display: block; }

/* brief list demo */
.cap-brief-row { display: flex; align-items: baseline; gap: 10px; padding: 8px 4px; border-bottom: 1px solid var(--line-soft); opacity: 0; transform: translateX(-8px); }
.cap-brief-row:last-child { border-bottom: none; }
.cap.in .cap-brief-row { animation: capSlide .5s var(--ease-out) forwards; }
.cap.in .cap-brief-row:nth-child(1){animation-delay:.1s}.cap.in .cap-brief-row:nth-child(2){animation-delay:.2s}.cap.in .cap-brief-row:nth-child(3){animation-delay:.3s}.cap.in .cap-brief-row:nth-child(4){animation-delay:.4s}
@keyframes capSlide { to { opacity: 1; transform: none; } }
.cap-brief-rank { font-family: var(--mono); font-size: 11px; color: var(--fg-3); width: 18px; flex-shrink: 0; }
.cap-brief-t { font-size: 12.5px; color: var(--fg-1); flex: 1; }
.cap-brief-d { font-family: var(--mono); font-size: 11px; }

/* simulation tree demo */
.cap-sim-hyp { font-size: 13px; color: var(--fg-0); line-height: 1.4; margin-bottom: 14px; }
.cap-sim-track { height: 8px; border-radius: 999px; overflow: hidden; display: flex; margin-bottom: 12px; background: var(--bg-3); }
.cap-sim-track i { height: 100%; width: 0; transition: width 1.1s var(--ease-out); }
.cap.in .cap-sim-track i { width: var(--w); }
.cap-sim-seg-b { background: var(--accent); } .cap-sim-seg-u { background: var(--up); } .cap-sim-seg-d { background: var(--down); }
.cap-sim-leg { display: flex; gap: 16px; font-family: var(--mono); font-size: 10.5px; color: var(--fg-3); }
.cap-sim-leg i { display: inline-block; width: 7px; height: 7px; border-radius: 2px; margin-right: 6px; }

/* risk dimension bars */
.cap-risk-row { display: grid; grid-template-columns: 84px 1fr 40px; gap: 12px; align-items: center; padding: 8px 4px; }
.cap-risk-k { font-family: var(--mono); font-size: 11px; color: var(--fg-2); }
.cap-risk-track { height: 10px; background: var(--bg-3); border-radius: 999px; overflow: hidden; }
.cap-risk-fill { display: block; height: 100%; background: linear-gradient(90deg, var(--accent-lo), var(--accent)); border-radius: 999px; transform-origin: left; }
.cap.in .cap-risk-fill { animation: riskGrow 1s var(--ease-out); }
@keyframes riskGrow { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.cap-risk-v { font-size: 11px; color: var(--fg-1); text-align: right; font-weight: 600; }

/* api code demo */
.cap-code { font-family: var(--mono); font-size: 12px; line-height: 1.75; padding: 14px; color: var(--fg-2); white-space: pre; overflow-x: auto; }
.cap-code .tok-k { color: var(--fg-0); font-weight: 600; } .cap-code .tok-s { color: var(--up); } .cap-code .tok-c { color: var(--fg-4); }
.cap-endpoints { display: flex; flex-wrap: wrap; gap: 7px; padding: 12px 14px 14px; border-top: 1px solid var(--line-soft); }
.cap-endpoints span { font-family: var(--mono); font-size: 11px; color: var(--fg-3); border: 1px solid var(--line); border-radius: var(--r-xs); padding: 4px 8px; }

/* ---------------- SIMS ---------------- */
.sims-inner { display: grid; grid-template-columns: 1fr 1.1fr; gap: 56px; align-items: center; }
@media (max-width: 900px) { .sims-inner { grid-template-columns: 1fr; gap: 36px; } }
.sims-copy .overline { margin-bottom: 18px; }
.sims-copy .h2 { margin-bottom: 22px; }
.sims-stages { display: flex; gap: 8px; margin-top: 28px; flex-wrap: wrap; }
.ss { font-family: var(--mono); font-size: 12px; color: var(--text-4); border: 1px solid var(--hairline-2); border-radius: var(--r-sm); padding: 6px 11px; transition: all .3s; }
.ss.s-on { color: var(--accent); border-color: var(--accent-line); background: var(--accent-soft); }
.ss.s-done { color: var(--text-2); }
.sim-card { padding: 24px; }
.sim-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.dimmer { color: var(--text-3); font-family: var(--mono); font-size: 11px; }
.sim-hyp { font-size: 16px; line-height: 1.4; letter-spacing: -0.01em; margin-bottom: 18px; }
.sim-bars { display: flex; flex-direction: column; gap: 9px; margin-bottom: 18px; }
.sb-row { display: grid; grid-template-columns: 46px 1fr 58px; align-items: center; gap: 12px; }
.sb-asset { font-family: var(--mono); font-size: 12px; color: var(--text-2); }
.sb-track { height: 6px; background: var(--surface-3); border-radius: 999px; position: relative; }
.sb-fill { position: absolute; top: 0; bottom: 0; border-radius: 999px; width: 0; transition: width 1s var(--ease-out); }
.sb-fill.neg { right: 50%; background: var(--red); }
.sb-fill.pos { left: 50%; background: var(--green); }
.sb-track::before { content: ""; position: absolute; left: 50%; top: -2px; bottom: -2px; width: 1px; background: var(--hairline-2); }
.sb-val { font-family: var(--mono); font-size: 12px; text-align: right; }
.sb-val.neg { color: var(--red); } .sb-val.pos { color: var(--green); }
.sim-scen { border-top: 1px solid var(--hairline); padding-top: 16px; }
.ss-track { height: 8px; border-radius: 999px; overflow: hidden; display: flex; margin-bottom: 12px; }
.ss-track i { height: 100%; width: 0; transition: width 1.1s var(--ease-out); }
.seg-base { background: var(--accent); } .seg-up { background: var(--green); } .seg-down { background: var(--red); }
.ss-legend { display: flex; gap: 18px; font-family: var(--mono); font-size: 11px; color: var(--text-3); }
.ss-legend .dot { display: inline-block; width: 7px; height: 7px; border-radius: 2px; margin-right: 6px; }
.dot-base { background: var(--accent); } .dot-up { background: var(--green); } .dot-down { background: var(--red); }

/* ---------------- DEVELOPERS ---------------- */
.dev-inner { display: grid; grid-template-columns: 1fr minmax(0, 1.15fr); gap: 56px; align-items: center; }
@media (max-width: 900px) { .dev-inner { grid-template-columns: 1fr; gap: 36px; } }
.dev-copy .overline { margin-bottom: 18px; }
.dev-copy .h2 { margin-bottom: 22px; }
.dev-points { list-style: none; display: flex; flex-direction: column; gap: 12px; margin-top: 28px; }
.dev-points li { display: flex; align-items: center; gap: 12px; font-size: 15px; color: var(--text-2); }
.dp-tick { color: var(--accent); font-size: 12px; }
.code-window { overflow: hidden; padding: 0; background: var(--bg-1); border-color: var(--line); }
.cw-tabs { display: flex; align-items: center; gap: 2px; padding: 8px 8px 0; border-bottom: 1px solid var(--line-soft); font-family: 'IBM Plex Mono', monospace; background: var(--bg-2); }
.cwt { font-size: 12.5px; color: var(--fg-3); padding: 9px 14px; transition: color .2s, background .2s; position: relative; }
.cwt:hover { color: var(--fg-1); }
.cwt.active { color: var(--fg-0); background: var(--bg-1); }
.cwt.active::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--accent); }
.cw-copy { margin-left: auto; font-family: 'IBM Plex Mono', monospace; font-size: 11px; color: var(--fg-3); padding: 6px 10px; border: 1px solid var(--line); cursor: pointer; transition: color .2s, border-color .2s; }
.cw-copy:hover { color: var(--fg-0); border-color: var(--line-hard); }
.cw-pre { padding: 20px; overflow-x: auto; font-family: 'IBM Plex Mono', monospace; font-size: 13px; line-height: 1.75; min-height: 320px; box-sizing: border-box; }
.cw-pre code { white-space: pre; color: var(--fg-2); }
/* Excel tab — a mini spreadsheet grid instead of formulas. Fixed table layout
   so the cells never widen the code card on this tab. */
.cw-pre code.is-sheet { white-space: normal; display: block; }
.xl { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: 12px; }
.xl td { border: 1px solid var(--line-soft); padding: 6px 9px; color: var(--fg-1); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.xl-corner, .xl-ch, .xl-rh { background: var(--bg-2); color: var(--fg-3); font-family: 'IBM Plex Mono', monospace; font-size: 10.5px; text-align: center; font-weight: 500; }
.xl-h { background: var(--bg-2); color: var(--fg-0); font-weight: 600; }
.xl-n { text-align: right; font-family: 'IBM Plex Mono', monospace; font-variant-numeric: tabular-nums; }
.xl-up { color: var(--up); }
.xl-dn { color: var(--down); }
.tok-key { color: var(--fg-0); font-weight: 600; } .tok-str { color: var(--up); } .tok-fn { color: var(--fg-0); } .tok-com { color: var(--fg-4); } .tok-num { color: var(--down); }

/* ---------------- STATS ---------------- */
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
@media (max-width: 760px) { .stat-grid { grid-template-columns: 1fr 1fr; gap: 32px; } }
.stat { text-align: left; border-left: 2px solid var(--accent-line); padding-left: 20px; }
.stat-num { font-family: var(--mono); font-size: clamp(38px, 5vw, 62px); font-weight: 600; letter-spacing: -0.04em; line-height: 1; color: var(--text-1); }
.stat-num span { color: var(--accent); }
.stat-label { color: var(--text-3); font-size: 14px; margin-top: 10px; max-width: 190px; }

/* ---------------- CTA ---------------- */
.cta-section { text-align: center; overflow: hidden; position: relative; }
.cta-section::before { content: ""; position: absolute; inset: 0; z-index: 0; pointer-events: none; background: radial-gradient(620px 360px at 50% 30%, var(--accent-soft), transparent 70%); }
.cta-inner { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; }
.cta-inner .overline { justify-content: center; margin-bottom: 22px; }
.cta-head { margin-bottom: 24px; }
.cta-inner .lead { max-width: 480px; margin-bottom: 34px; }
.cta-inner .hero-actions { justify-content: center; }

/* ---------------- FOOTER ---------------- */
.footer { border-top: 1px solid var(--hairline); padding-top: 62px; padding-bottom: 30px; background: var(--bg-2); }
.footer-inner { display: grid; grid-template-columns: 1.4fr 2fr; gap: 40px; padding-bottom: 48px; }
@media (max-width: 760px) { .footer-inner { grid-template-columns: 1fr; gap: 36px; } }
.foot-tag { margin-top: 16px; font-size: 14px; max-width: 270px; }
.foot-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.foot-col { display: flex; flex-direction: column; gap: 12px; }
.foot-col .overline { margin-bottom: 4px; }
.foot-col a { font-size: 14px; color: var(--text-2); transition: color .18s; }
.foot-col a:hover { color: var(--text-1); }
.foot-base { display: flex; justify-content: space-between; align-items: center; padding-top: 24px; border-top: 1px solid var(--hairline); font-family: var(--mono); font-size: 12px; color: var(--text-4); }
.foot-status { display: flex; align-items: center; gap: 9px; color: var(--text-3); }

/* ============================================================
   TWEAKS PANEL
   ============================================================ */
.tweaks { position: fixed; right: 18px; bottom: 18px; z-index: 100; width: 284px; background: var(--surface); border: 1px solid var(--hairline-2); border-radius: var(--r-xl); box-shadow: var(--shadow-pop); display: none; overflow: hidden; }
.tweaks.show { display: block; animation: twIn .3s var(--ease-out); }
@keyframes twIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.tweaks-head { display: flex; align-items: center; justify-content: space-between; padding: 13px 15px; border-bottom: 1px solid var(--hairline); cursor: grab; }
.tweaks-head .th-title { font-size: 13px; font-weight: 600; letter-spacing: -0.01em; }
.tweaks-close { width: 24px; height: 24px; border-radius: var(--r-sm); color: var(--text-3); display: flex; align-items: center; justify-content: center; font-size: 15px; transition: background .2s, color .2s; }
.tweaks-close:hover { background: var(--surface-2); color: var(--text-1); }
.tweaks-body { padding: 15px; display: flex; flex-direction: column; gap: 18px; max-height: min(72vh, 560px); overflow-y: auto; }
.tw-group .tw-label { font-family: var(--mono); font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-3); margin-bottom: 9px; }
/* palette candidate tiles — each shows the theme's own colour set */
.tw-pals { display: flex; flex-direction: column; gap: 7px; }
.tw-pal { display: flex; flex-direction: column; gap: 8px; padding: 9px 10px; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--bg-1); cursor: pointer; text-align: left; transition: border-color .18s, box-shadow .18s; }
.tw-pal:hover { border-color: var(--line-hard); }
.tw-pal.active { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.tw-pal-top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.tw-pal-name { font-size: 12.5px; color: var(--fg-0); font-weight: 600; letter-spacing: -0.01em; white-space: nowrap; }
.tw-pal-sub { font-size: 10px; color: var(--fg-3); white-space: nowrap; }
.tw-pal-strip { display: flex; height: 16px; border-radius: 3px; overflow: hidden; border: 1px solid var(--line); }
.tw-pal-strip i { flex: 1; }
.tw-swatches { display: flex; gap: 8px; }
.tw-sw { width: 30px; height: 30px; border-radius: 50%; border: 2px solid transparent; cursor: pointer; transition: transform .15s, box-shadow .15s; }
.tw-sw:hover { transform: scale(1.08); }
.tw-sw.active { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--text-1); }
.tw-seg { display: flex; gap: 4px; background: var(--surface-2); border: 1px solid var(--hairline); border-radius: var(--r-md); padding: 3px; }
.tw-seg button { flex: 1; font-size: 12px; font-weight: 500; color: var(--text-2); padding: 7px 8px; border-radius: var(--r-sm); transition: background .2s, color .2s; }
.tw-seg button.active { background: var(--accent); color: var(--accent-ink); }
.tw-opts { display: flex; flex-direction: column; gap: 6px; }
.tw-opt { text-align: left; font-size: 12.5px; color: var(--text-2); border: 1px solid var(--hairline-2); border-radius: var(--r-md); padding: 9px 11px; transition: border-color .2s, color .2s, background .2s; line-height: 1.25; }
.tw-opt:hover { border-color: var(--hairline-3); color: var(--text-1); }
.tw-opt.active { border-color: var(--accent); background: var(--accent-soft); color: var(--text-1); }
.tw-opt b { font-weight: 600; }

/* entrance-animation guard for background tabs */
html.reveal-instant .pr-bp,
html.reveal-instant .scene,
html.reveal-instant .pr-alert,
html.reveal-instant .pr-srow { animation: none !important; }
html.reveal-instant .scene { opacity: 1 !important; }
html.reveal-instant .cap-evt,
html.reveal-instant .cap-brief-row { opacity: 1 !important; transform: none !important; animation: none !important; }
html.reveal-instant .cap-risk-fill { animation: none !important; }
html.reveal-instant .cap-sim-track i { transition: none !important; }

/* ============================================================
   OPENING ANIMATION — kinetic "TRACK [anything]" → brand lockup
   ============================================================ */
.intro {
  position: fixed; inset: 0; z-index: 9999;
  background: var(--bg-0); color: var(--fg-0);
  overflow: hidden;
  transition: clip-path .9s var(--ease-in-out);
  clip-path: inset(0 0 0 0);
}
.intro.lift { clip-path: inset(0 0 100% 0); }
.intro.gone { display: none; }

/* drifting grid + center vignette for depth */
.intro-grid {
  position: absolute; inset: -40px; opacity: 0;
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 52px 52px;
  -webkit-mask-image: radial-gradient(circle at 50% 50%, #000 6%, transparent 64%);
          mask-image: radial-gradient(circle at 50% 50%, #000 6%, transparent 64%);
  animation: introGrid 3.4s var(--ease-out) forwards, introDrift 9s linear infinite;
}
@keyframes introGrid { 0% { opacity: 0; } 28% { opacity: .42; } 100% { opacity: .16; } }
@keyframes introDrift { from { background-position: 0 0; } to { background-position: 52px 52px; } }
.intro-vignette { position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(120% 90% at 50% 50%, transparent 50%, color-mix(in oklab, var(--bg-0), var(--fg-0) 6%) 100%); }

/* telemetry HUD in the four corners */
.intro-hud { position: absolute; z-index: 4; font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--fg-3); opacity: 0; animation: introFade .7s ease .25s forwards; display: inline-flex; align-items: center; gap: 7px; }
.intro-hud-tl { top: 22px; left: 24px; color: var(--accent); }
.intro-hud-tr { top: 22px; right: 24px; }
.intro-hud-bl { bottom: 20px; left: 24px; }
.intro-hud-br { bottom: 20px; right: 24px; }
.hud-cursor { width: 7px; height: 12px; background: var(--accent); animation: blink 1s step-end infinite; }

/* stage = phase 1 */
.intro-stage { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; z-index: 3;
  opacity: 0; animation: introFade .5s ease .35s forwards; }
.intro-stage.out { animation: stageCollapse .5s var(--ease-in-out) forwards; }
@keyframes stageCollapse { 0% { opacity: 1; transform: none; filter: blur(0); } 100% { opacity: 0; transform: scale(.18); filter: blur(4px); } }
.intro-line { display: flex; align-items: center; gap: clamp(14px, 2.5vw, 30px); padding-inline: 5vw; }
.intro-verb { font-size: clamp(34px, 6.4vw, 86px); font-weight: 600; letter-spacing: -0.04em; color: var(--fg-2);
  opacity: 0; transform: translateX(-14px); animation: verbIn .7s var(--ease-out) .45s forwards; }
@keyframes verbIn { to { opacity: 1; transform: none; } }

/* the slot — fixed scope; words stream through, reticle stays put */
.intro-slot { position: relative; display: inline-flex; align-items: center; justify-content: center; min-width: clamp(260px, 44vw, 600px); height: 1.2em; }
.slot-inner { position: relative; display: inline-flex; align-items: center; justify-content: center; padding: 0.06em 0.2em; min-width: 100%; }
.slot-word { font-size: clamp(30px, 5.6vw, 78px); font-weight: 600; letter-spacing: -0.04em; color: var(--accent); white-space: nowrap; line-height: 1; display: inline-block; will-change: transform, opacity, filter; }
.slot-word.swap { animation: slotSwap .22s var(--ease-out); }
@keyframes slotSwap { 0% { opacity: 0; transform: translateY(36%); filter: blur(7px); } 100% { opacity: 1; transform: none; filter: blur(0); } }
.slot-word.land { animation: slotLand .5s var(--ease-out); }
@keyframes slotLand { 0% { opacity: 0; transform: translateY(24%) scale(.9); filter: blur(10px); } 60% { opacity: 1; filter: blur(0); } 100% { transform: none; } }
/* terminal caret after the cycling word (replaces the corner reticle) */
.slot-caret { display: inline-block; width: clamp(9px, 1vw, 14px); height: clamp(28px, 5.2vw, 64px); margin-left: 0.12em; background: var(--accent); vertical-align: middle; transform: translateY(-0.04em); opacity: 0; }
.slot-inner.lit .slot-caret { animation: caretBlink 1.05s steps(1) infinite; }
@keyframes caretBlink { 0%, 50% { opacity: 1; } 50.01%, 100% { opacity: 0; } }
.slot-caret.pulse { animation: none; opacity: 1; }

/* lockup = phase 2 */
.intro-lock { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; z-index: 3;
  opacity: 0; pointer-events: none; }
.intro-lock.show { opacity: 1; animation: lockIn .6s var(--ease-out) forwards; }
@keyframes lockIn { from { opacity: 0; } to { opacity: 1; } }
.intro-mark { color: var(--accent); margin-bottom: 20px; }
.intro-lock.show .intro-mark { animation: markZoom .6s var(--ease-out); }
@keyframes markZoom { 0% { opacity: 0; transform: scale(.4); } 60% { opacity: 1; } 100% { opacity: 1; transform: none; } }
.intro-lock.show .im-bracket { stroke-dasharray: 150; stroke-dashoffset: 150; animation: introStroke .8s var(--ease-out) .05s forwards; }
@keyframes introStroke { to { stroke-dashoffset: 0; } }
.intro-lock.show .im-dot { transform-box: fill-box; transform-origin: center; transform: scale(0); animation: introDot .45s var(--ease-out) .5s forwards; }
@keyframes introDot { from { transform: scale(0); } to { transform: scale(1); } }
.intro-lock .im-ring { opacity: 0; transform-box: fill-box; transform-origin: center; }
.intro-lock.show .im-ring { animation: introRing 1.4s var(--ease-out) .6s forwards; }
@keyframes introRing { 0% { opacity: .9; transform: scale(.5); } 100% { opacity: 0; transform: scale(1.7); } }
.intro-word { overflow: visible; }
.intro-word span { display: inline-block; font-size: clamp(42px, 7vw, 80px); font-weight: 600; letter-spacing: -0.045em; color: var(--fg-0); opacity: 0; transform: translate3d(0, 0.28em, 0); will-change: transform, opacity; }
.intro-lock.show .intro-word span { animation: introRise .7s var(--ease-out) .35s forwards; }
@keyframes introRise { from { opacity: 0; transform: translate3d(0, 0.28em, 0); } to { opacity: 1; transform: translate3d(0, 0, 0); } }
.intro-tag { font-family: var(--mono); font-size: clamp(12px, 1.4vw, 15px); letter-spacing: 0.16em; text-transform: uppercase; color: var(--fg-2); margin-top: 16px; opacity: 0; }
.intro-lock.show .intro-tag { animation: introFade .7s ease .7s forwards; }
@keyframes introFade { to { opacity: 1; } }

.intro-skip {
  position: absolute; right: 22px; bottom: 20px; z-index: 5;
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--fg-3); padding: 8px 12px; border: 1px solid var(--line); border-radius: var(--r-sm);
  opacity: 0; animation: introFade .6s ease 1s forwards; transition: color .2s, border-color .2s; background: var(--bg-0); cursor: pointer;
}
.intro-hud-br { right: 92px; }
.intro-skip:hover { color: var(--fg-0); border-color: var(--line-hard); }

@media (prefers-reduced-motion: reduce) { .intro { display: none; } }

/* ============================================================
   MOBILE OVERRIDES — phone-friendly layer (append to end of file)
   Two breakpoints: 768px (tablet / large phone) and 480px (small phone).
   Additive only — does NOT restructure desktop. Keeps Stone language:
   hairlines, IBM Plex mono accents, sharp/subtle corners.
   ============================================================ */

/* ------------------------------------------------------------
   768px — TABLET / LARGE PHONE
   ------------------------------------------------------------ */
@media (max-width: 768px) {

  /* --- 0. GLOBAL OVERFLOW KILL ---------------------------------
     The real 156px page overflow is the unbreakable .cw-pre code
     block (Developers). We fix it at the source below, but also
     harden the document so no single section can ever widen the
     layout viewport and trigger the ~71% zoom-out. */
  html, body { max-width: 100%; overflow-x: hidden; }
  .section, .marquee-band, .footer { max-width: 100%; overflow-x: clip; }

  /* --- 1. HEADER NAV ------------------------------------------
     nav-links already hidden <880. Only the sign-in tap target
     and the right cluster spacing need help here. */
  .nav-cta { gap: 12px; }
  .nav-signin {
    display: inline-flex; align-items: center;
    min-height: 40px; padding: 9px 4px;   /* 22px -> 40px tap target */
  }

  /* --- 2. HERO + actions --------------------------------------
     Hero already single-column <920. Trim top padding, defang the
     fixed 596px demo height, and stack the two CTAs full-width so
     they read as a deliberate pair instead of mismatched pills. */
  .hero { padding-top: 56px; }
  .hero-inner { max-width: 100%; overflow-x: clip; }
  .hero-demo { height: auto; min-height: 420px; max-height: 70svh; }

  .hero-actions { flex-direction: column; align-items: stretch; gap: 12px; }
  .hero-actions .btn { width: 100%; justify-content: center; }

  /* --- 3. MARQUEE --------------------------------------------
     Track already clips. Tighten type/gap/padding so more items
     show per pass and the band isn't dead space on a phone. */
  .marquee-band { padding-block: 24px; }
  .marq-label { margin-bottom: 16px; }
  .marquee-track { gap: 36px; }
  .marq-item { font-size: 15px; }

  /* --- 4. HOW IT WORKS demo (#demo) ---------------------------
     Existing breakpoints stop at 760, so at 768 this is still the
     full desktop layout. Collapse the scrub steps + product body
     to one column and drop the sidebar at the tablet edge too. */
  .demo-steps { grid-template-columns: 1fr; gap: 16px; }
  #demoWindow .win-body { grid-template-columns: 1fr; }
  #demoWindow .pr-side { display: none; }
  /* keep the sidebar's "+ New query" hittable IF it's ever shown */
  #demo .pr-side-new { padding-top: 9px; padding-bottom: 9px; min-height: 40px; }

  /* --- 4b. TRACKERS dashboard (#trackersWin) -----------------
     The desktop "One terminal" window is a fixed-height scroll box
     (.win-body min(66vh,600px)/min-height 480px + .trk-page overflow
     auto). On a phone that hides 7 of the 9 example cards behind an
     internal scroll, so the section reads as just two trackers. Let
     the window grow to its content so every signal type is visible
     inline — no scroll-within-a-scroll on touch. */
  #trackersWin .win-body { height: auto; max-height: none; min-height: 0; }
  #trackersWin .trk-page { overflow: visible; }

  /* --- 5. STATS grid -----------------------------------------
     Only breakpoint was 760, so 4 cols survive at 768 and read
     cramped. Match the <=760 treatment one notch earlier. */
  .stat-grid { grid-template-columns: 1fr 1fr; gap: 32px; }

  /* --- 6. DEVELOPERS code block (ROOT overflow fix) -----------
     dev-inner stacks <900 already, but the 1fr track's min-content
     floor refuses to shrink because <pre> uses white-space:pre, so
     its overflow-x never engages and the column forces 524px.
     Pin min-width:0 everywhere in the chain so the inner scroll
     takes over and the card stays at viewport width. */
  .dev-inner { grid-template-columns: minmax(0, 1fr); }
  .dev-code, .code-window { min-width: 0; max-width: 100%; }
  .cw-pre {
    min-width: 0; max-width: 100%; overflow-x: auto;   /* scroll inside, not the page */
    font-size: 12px; line-height: 1.6;                 /* more chars before scroll */
    min-height: 200px; padding: 16px;                  /* kill the empty-box look */
  }
  /* code-window tab + copy tap targets (34px / 31px -> ~40px) */
  .cwt { padding-top: 12px; padding-bottom: 12px; }
  .cw-copy { padding: 9px 12px; }

  /* --- 7. FOOTER ---------------------------------------------
     footer-inner already stacks <760; foot-base / foot-cols / link
     tap targets have no mobile rule. Stack the base, widen hit
     areas, and give the link columns room. */
  .foot-cols { grid-template-columns: repeat(2, 1fr); gap: 20px 16px; }
  .foot-col a { display: inline-block; padding-block: 8px; min-height: 40px; }
  .foot-base { flex-direction: column; align-items: flex-start; gap: 12px; }
  .foot-status { width: 100%; }
}

/* ------------------------------------------------------------
   480px — SMALL PHONE
   Everything from the 768px layer still applies; these are the
   tighter, narrow-device-only refinements.
   ------------------------------------------------------------ */
@media (max-width: 480px) {

  /* --- 0. DEFENSIVE OVERFLOW GUARD ---------------------------- */
  html, body { max-width: 100%; overflow-x: hidden; }
  #trackersWin, .window, .hero-demo { max-width: 100%; }

  /* --- 1. TYPE / SECTION RHYTHM -------------------------------
     The clamp()s already shrink display/h2/lead toward their
     floors, but the section padding is heavy on a 390px phone.
     Trim vertical breathing room; never touch desktop. */
  .section { padding-block: 56px; }
  .sec-head { margin-bottom: 32px; }

  /* --- 2. HERO product demo interior -------------------------- */
  .hero-demo { min-height: 380px; }

  /* --- 3. HOW IT WORKS demo interior (#demo) ------------------
     Let the product body size to content (was fixed 480-600px,
     which clipped the composer to "Track cont…"). Single-column
     suggestions, tighter chat padding, denser status bar.
     NOTE: no max-height — the window has overflow:hidden, so any
     cap (the old 78vh) clipped the tallest scene (Build: reply +
     5-stage pipeline + Create/Cancel) on small phones. Only one
     scene is in the DOM at a time, so letting it flow is safe. */
  #demo #demoWindow .win-body { height: auto; min-height: 420px; max-height: none; }
  #demo .dchat { padding: 18px 14px; gap: 14px; }
  #demo .dchat-sugs { grid-template-columns: 1fr; gap: 8px; width: 94%; }
  #demo .pr-statusbar {
    gap: 10px; padding-left: 12px; padding-right: 12px; font-size: 10px;
  }
  /* Tab-2 (Build) chat: drop the Tracken bot bracket-logo — exactly like
     the hero — so the reply + blueprint run full width and reclaim the left
     gutter. The user's chevron avatar stays. */
  #demo .pr-ava.bot { display: none; }
  #demo .pr-msg-user:has(.pr-ava.bot) { gap: 0; }
  /* …and with the bot avatar gone, the blueprint's 34px left margin (which
     aligned it under that avatar) is orphaned whitespace that also squeezed
     the pipe into a right-edge clip on narrow phones. Run it flush. */
  #demo .pr-pipe { margin-left: 0; }

  /* --- 4. TRACKERS dashboard (#trackersWin) ------------------
     trk-grid already collapses to 1 col (minmax 300px). The only
     rigid element is the fixed-140px sparkline; let it scale with
     the card so any longer value can't push it to the edge. */
  #trackersWin .trk-spark svg { width: 100%; max-width: 140px; height: auto; }

  /* --- 5. CAPABILITIES + SIMULATIONS panels ------------------
     The demo-panel header (.cap-panel-head) is the real Sims /
     Capabilities header. Its two mono labels collide on one line
     at 390px and interleave — stack them. Bump the smallest mono
     labels just over the legibility floor (Stone aesthetic kept). */
  .cap-panel-head {
    flex-direction: column; align-items: flex-start;
    gap: 2px; line-height: 1.3;
    font-size: 11px; letter-spacing: 0.08em;
  }
  .cap-evt-src { font-size: 11px; }

  /* --- 6. STATS small-phone -----------------------------------
     2x2 can feel tight on 390px; go single column with the big
     numbers stacked for clean reading. */
  .stat-grid { grid-template-columns: 1fr; gap: 28px; }

  /* --- 7. FOOTER small-phone ---------------------------------- */
  .foot-cols { grid-template-columns: 1fr 1fr; gap: 18px 14px; }
}
/* HERO chat: keep the user's chevron, but drop the bot bracket-logo so
   the assistant's pipeline + result cards run full width — no wasted
   left gutter. (All widths.) */
.hero-demo .pr-msg-bot .pr-ava { display: none; }
.hero-demo .pr-msg-bot { gap: 0; }

/* ------------------------------------------------------------
   MOBILE: the 3 steps become compact TABS — all stay visible and
   tappable (number + title); only the ACTIVE step shows its blurb.
   The live window sits right beneath, and sizes to the active scene
   so the whole thing is visible without an inner scrollbar.
   ------------------------------------------------------------ */
@media (max-width: 768px) {
  /* 3 tabs stay side-by-side; flatten each step (display:contents) so its bar +
     head sit in the row and the ACTIVE blurb can span the full width beneath. */
  .demo-scrub.demo-steps { margin-bottom: 16px; grid-template-columns: repeat(3, 1fr); column-gap: 10px; row-gap: 6px; align-items: start; }
  .demo-steps .ds-step { display: contents; }
  .demo-steps .ds-bar { grid-row: 1; margin: 0; cursor: pointer; }
  .demo-steps .ds-head { grid-row: 2; gap: 7px; cursor: pointer; }
  .demo-steps .ds-head b { font-size: 13px; letter-spacing: -0.01em; }
  .demo-steps .ds-l { display: none; }
  .demo-steps .ds-s { display: inline; }
  .demo-steps .ds-num { width: 20px; height: 20px; font-size: 10.5px; }
  .demo-steps .ds-step:nth-of-type(1) .ds-bar, .demo-steps .ds-step:nth-of-type(1) .ds-head { grid-column: 1; }
  .demo-steps .ds-step:nth-of-type(2) .ds-bar, .demo-steps .ds-step:nth-of-type(2) .ds-head { grid-column: 2; }
  .demo-steps .ds-step:nth-of-type(3) .ds-bar, .demo-steps .ds-step:nth-of-type(3) .ds-head { grid-column: 3; }
  .demo-steps .ds-desc { grid-row: 3; grid-column: 1 / -1; display: none; margin-top: 6px; }
  .demo-steps .ds-step.active .ds-desc { display: block; }
  .demo-steps .ds-step:not(.active) .ds-num { background: var(--bg-3); color: var(--fg-2); }
  .demo-steps .ds-step:not(.active) .ds-head b { color: var(--text-2); }

  /* window grows to the current scene (only one scene is in the DOM at
     a time, so letting it flow drives the height — no inner scroll). */
  #demo .win-body { height: auto; max-height: none; min-height: 0; }
  #demo .pr-main { min-height: 0; }
  #demo .demo-stage { position: static; flex: 0 0 auto; overflow: visible; }
  #demo .scene { position: relative; inset: auto; }

  /* the subtitle is short now — keep it on phones for the positioning line,
     and drop its bottom margin so it sits close to the animation */
  .hero-copy .lead { font-size: 16px; margin-bottom: 0; }
}


/* === VERIFY-PASS DELTAS (remaining mobile polish) === */
@media (max-width: 768px) {

  /* --- HEADER NAV: brand tap target -------------------------
     .brand is a tappable anchor but only ~24px tall; Sign in /
     Request access already got 40px min-heights, brand did not. */
  .brand { min-height: 40px; }

  /* --- HERO demo pipeline: cadence-tag reflow ----------------
     Base .pp-stage is `24px 1fr auto`; the `auto` cadence-tag
     column ('Every 6 hours') starves the 1fr description and
     forces a colliding wrap on the Sources row. Drop the tag to
     its own line under the text. */
  .hero-demo .pp-stage { grid-template-columns: 24px 1fr; }
  .hero-demo .pp-tag { grid-column: 2; justify-self: start; align-self: start; margin-top: 2px; }

  /* --- HOW IT WORKS demo (#demo): structural overflow --------
     None of these have a mobile rule; at 768 they still render
     the desktop layout. */

  /* Step-1 chat title clipped under status bar: center-flex
     pushes 466px content above the scroll origin. Anchor to top. */
  #demo .dchat { justify-content: flex-start; padding-top: 28px; }

  /* Step-3 detail header overflows the card ('Export' clipped,
     title wraps to 2 lines). Stack header; wrap actions to full
     rows with comfortable tap size. */
  #demo .dtrk-head { flex-direction: column; align-items: stretch; gap: 12px; }
  #demo .dtrk-actions { flex-wrap: wrap; }
  #demo .dtrk-act {
    flex: 1 1 auto; text-align: center; min-height: 36px;
    display: inline-flex; align-items: center; justify-content: center;
  }

  /* Time-series chart header: label + 5 range pills on one
     space-between row force a ragged 3-line wrap. Stack them. */
  #demo .dtrk-chart .pr-panel-head { flex-direction: column; align-items: flex-start; gap: 8px; }
  #demo .dtrk-chart .pr-panel-head .pp-r.dtrk-ranges { width: 100%; justify-content: flex-start; }

  /* Range pills are ~26x20px — make them comfortably tappable. */
  #demo .dtrk-ranges .dtrk-range {
    padding-block: 7px; min-height: 32px;
    display: inline-flex; align-items: center;
  }

  /* --- DEVELOPERS code window: tab-row horizontal overflow ----
     .cw-tabs overflows its overflow:hidden container (353 > 318)
     with no scroll affordance, clipping the 'copy' button off
     the right edge. The existing 768 block only bumped vertical
     padding. Make the row scroll and tighten tab h-padding. */
  .cw-tabs {
    flex-wrap: nowrap; overflow-x: auto;
    -webkit-overflow-scrolling: touch; scrollbar-width: none;
  }
  .cw-tabs::-webkit-scrollbar { display: none; }
  .cwt { flex: 0 0 auto; padding-left: 10px; padding-right: 10px; }
  .cw-copy { flex: 0 0 auto; }
}

@media (max-width: 480px) {

  /* --- LEGIBILITY FLOOR: sub-12px mono metadata --------------
     The responsive pass bumped sibling mono labels (.cap-evt-src)
     to 11px but left these below the ~12px phone floor. Nudge
     them just over it; Stone aesthetic kept. */

  /* Hero pipeline compact description + cadence tag (10.5 / 9.5). */
  .hero-demo .pr-pipe.compact .pp-d { font-size: 12px; }
  .hero-demo .pp-tag { font-size: 11px; }

  /* Trackers card timestamps + footer strip + tags (9.5 / 10). */
  #trackersWin .trk-ev-time { font-size: 11px; }
  #trackersWin .trk-strip-foot { font-size: 10.5px; }
  #trackersWin .trk-tag { font-size: 10.5px; }

  /* Live-events signal chips (9px) — smallest text in the region. */
  .sig-chip { font-size: 10.5px; padding: 2px 6px; letter-spacing: 0.04em; }

  /* --- FOOTER: collapse lopsided 2-col link grid -------------
     The 480 block sets foot-cols to 1fr 1fr, which leaves
     'Company' alone in row 2 next to an empty cell. One column
     reads cleaner and removes the dead space. Overrides the
     earlier rule by source order. */
  .foot-cols { grid-template-columns: 1fr; gap: 24px; }
}

/* ============================================================
   REQUEST-ACCESS MODAL
   ============================================================ */
.rqa-backdrop { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 20px; background: color-mix(in oklab, var(--fg-0) 40%, transparent); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); animation: rqaFade .2s var(--ease-out); }
.rqa-backdrop[hidden] { display: none; }
.rqa { position: relative; width: 100%; max-width: 540px; max-height: calc(100svh - 40px); overflow: auto; background: var(--bg-1); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-pop); padding: clamp(22px, 4vw, 34px); animation: rqaPop .26s var(--ease-out); }
.rqa-close { position: absolute; top: 14px; right: 14px; width: 36px; height: 36px; display: grid; place-items: center; color: var(--fg-3); border-radius: var(--r-sm); }
.rqa-close:hover { color: var(--fg-0); background: var(--bg-2); }
.rqa-head { margin-bottom: 20px; padding-right: 30px; }
.rqa-head h3 { font-size: clamp(20px, 3vw, 26px); font-weight: 600; letter-spacing: -0.02em; margin: 12px 0 6px; color: var(--fg-0); line-height: 1.15; }
.rqa-head p { font-size: 14px; color: var(--text-2); line-height: 1.5; }
.rqa-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.rqa-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.rqa-field.rqa-span { grid-column: 1 / -1; }
.rqa-lbl { font-size: 12px; color: var(--text-2); font-weight: 500; display: flex; align-items: center; gap: 6px; }
.rqa-req { color: var(--down); font-style: normal; }
.rqa-opt { color: var(--fg-4); font-style: normal; font-size: 11px; font-family: var(--mono); }
.rqa-field input, .rqa-field textarea { font: inherit; font-size: 14px; color: var(--fg-0); background: var(--bg-0); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 10px 12px; width: 100%; transition: border-color .15s, background .15s; }
.rqa-field input::placeholder, .rqa-field textarea::placeholder { color: var(--fg-4); }
.rqa-field input:focus, .rqa-field textarea:focus { outline: none; border-color: var(--accent); background: var(--bg-1); }
.rqa-field textarea { resize: vertical; min-height: 72px; }
.rqa-err { margin-top: 14px; font-size: 13px; color: var(--down); }
.rqa-submit { width: 100%; justify-content: center; margin-top: 18px; height: 46px; }
.rqa-submit[disabled] { opacity: .6; pointer-events: none; }
.rqa-fine { margin-top: 12px; font-size: 11.5px; color: var(--fg-3); text-align: center; }
.rqa-done { text-align: center; padding: 16px 6px 8px; }
.rqa-done-mark { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; margin: 0 auto 16px; color: var(--up); background: var(--up-bg); }
.rqa-done h3 { font-size: 22px; font-weight: 600; letter-spacing: -0.02em; color: var(--fg-0); margin-bottom: 8px; }
.rqa-done p { font-size: 14px; color: var(--text-2); line-height: 1.5; margin-bottom: 20px; }
@keyframes rqaFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes rqaPop { from { opacity: 0; transform: translateY(10px) scale(.98); } to { opacity: 1; transform: none; } }
@media (max-width: 480px) { .rqa-grid { grid-template-columns: 1fr; } .rqa { border-radius: var(--r-md); padding: 22px 18px; } }
@media (prefers-reduced-motion: reduce) { .rqa-backdrop, .rqa { animation: none; } }

/* MOBILE hero: the result card replaces the pipeline in the same slot
   (JS locks the slot to the pipeline's height); fill it so chart/list
   match the pipeline's footprint exactly. */
@media (max-width: 768px) {
  .hero-demo .pr-bot-body.is-result { display: flex; }
  .hero-demo .pr-bot-body.is-result .pr-result { flex: 1; margin: 0; display: flex; flex-direction: column; min-height: 0; }
  .hero-demo .pr-bot-body.is-result .pr-result-svg { flex: 1; height: auto; min-height: 0; }
  .hero-demo .pr-bot-body.is-result .pr-evlist { flex: 1; }
}
