/* QuantBase v6 · Ember Study. Source: sniff-app-prod/DESIGN-V6.md + src/styles.css;
 * website chrome: quant-release/site/static/ember.css. Shared by every Sniff page.
 * Dashboard layers: frame 2, header/rail 20, suggestions 50; content stays in flow.
 */
@font-face { font-family: 'Host Grotesk'; src: url('/static/fonts/host-grotesk.woff2') format('woff2'); font-weight: 300 800; font-style: normal; font-display: swap; }
@font-face { font-family: 'Geist Mono'; src: url('/static/fonts/geist-mono.woff2') format('woff2'); font-weight: 100 900; font-style: normal; font-display: swap; }
@font-face { font-family: 'Instrument Serif'; src: url('/static/fonts/instrument-serif-italic.ttf') format('truetype'); font-weight: 400; font-style: italic; font-display: swap; }
:root {
  color-scheme: dark;
  --canvas: #161316; --cocoa: #453027; --shell: rgba(48,36,31,.58); --panel-solid: #191719;
  --raised: #211E20; --raised-2: #292527; --raised-3: #332D2E; --sunk: #171416; --read: #191719;
  --ink: #FAF8F6; --ink-2: #E2DDDA; --ink-3: #BDB5B1; --ink-4: #ABA29D; --ink-5: #756B66;
  --line: rgba(255,255,255,.08); --line-2: rgba(255,255,255,.12); --line-3: #81756F; --line-glow: rgba(255,109,41,.34);
  --qb: #FF6D29; --qb-hi: #FFAE85; --qb-ink: #FFAA80; --qb-dim: rgba(255,109,41,.14);
  --live: #91C9A5; --neg: #F28C84; --warn: #E8C17C;
  --cta: #FAF8F6; --cta-hover: #F3EEEA; --cta-ink: #211A17;
  --glass-fill: rgba(255,244,236,.06); --glass-edge: rgba(255,236,222,.14);
  --glass-blur: blur(22px) saturate(1.25);
  --glass-shadow: inset 0 1px 0 rgba(255,255,255,.07), 0 18px 44px -24px rgba(0,0,0,.65);
  --lift: 0 1px 2px rgba(0,0,0,.35), 0 14px 30px -16px rgba(0,0,0,.7);
  --sans: 'Host Grotesk', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'Geist Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  --serif: 'Instrument Serif', Georgia, serif;
  --space-1: 4px; --space-2: 8px; --space-3: 12px; --space-4: 16px; --space-5: 20px; --space-6: 24px; --space-8: 32px; --space-10: 40px; --space-12: 48px;
  --rail-width: 80px; --header-height: 64px; --page-width: 1160px; --thread-width: 740px;
  --r-xs: 6px; --r-sm: 10px; --r-md: 14px; --r-lg: 18px; --r-xl: 24px; --r-pill: 999px;
  --ease: cubic-bezier(.16,1,.3,1); --press: 120ms; --hover: 180ms; --page: 280ms;
  /* Compatibility names keep existing graph, citation and state styles on these same tokens. */
  --color-paper: var(--canvas); --color-cocoa: var(--cocoa); --color-paper-2: var(--panel-solid);
  --color-raised: var(--raised); --color-hover: var(--raised-3); --color-well: var(--sunk);
  --color-ink: var(--ink); --color-ink-2: var(--ink-2); --color-muted: var(--ink-3); --color-muted-2: var(--ink-4);
  --color-accent: var(--qb); --color-accent-text: var(--qb-ink); --color-accent-ink: var(--canvas);
  --color-positive: var(--live); --color-error: var(--neg); --color-focus: var(--qb-hi);
  --color-rule: var(--line); --color-rule-2: var(--line-2); --color-control-edge: var(--line-3); --color-glass: var(--glass-fill);
  --font-display: var(--sans); --font-body: var(--sans); --font-mono: var(--mono); --font-outlier: var(--serif);
  --radius-tag: var(--r-xs); --radius-input: var(--r-sm); --radius-card: var(--r-md); --radius-pill: var(--r-pill);
  --dur-press: var(--press); --dur-short: var(--hover); --dur-medium: var(--page); --ease-out: var(--ease);
}
body { font-family: var(--sans); font-variant-numeric: tabular-nums; background: var(--canvas); color: var(--ink); }
button, input, select, textarea { font-family: inherit; letter-spacing: inherit; }
h1, h2, h3 { font-family: var(--sans); font-weight: 500; }
:focus-visible { outline: 2px solid var(--qb-hi); outline-offset: 3px; }
.button, .btn { min-height: 40px; padding: 0 18px; gap: 8px; border-radius: var(--r-pill); font: 600 13.5px/1.3 var(--sans); color: var(--ink); border: 1px solid var(--glass-edge); background: var(--glass-fill); box-shadow: inset 0 1px 0 rgba(255,255,255,.07); transition: background var(--hover) var(--ease), transform var(--press) var(--ease); }
.button.primary, .btn.solid { background: var(--cta); color: var(--cta-ink); border-color: transparent; box-shadow: none; }
.button:hover, .btn:hover { background: var(--raised-3); border-color: var(--line-3); }
.button.primary:hover, .btn.solid:hover { background: var(--cta-hover); }
.button:active, .btn:active { transform: translateY(.5px) scale(.985); }
.button:disabled, .btn:disabled { opacity: .5; transform: none; }
input[type='text'], input[type='password'], input:not([type]), textarea, select { background: var(--sunk); border-color: var(--line-3); border-radius: var(--r-sm); color: var(--ink); }
input::placeholder, textarea::placeholder { color: var(--ink-4); }
.glass { background: var(--raised); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: inset 0 1px 0 rgba(255,255,255,.035); backdrop-filter: none; -webkit-backdrop-filter: none; }
/* The dashboard room: one low ember light, a cocoa glass frame, a quiet reading surface. */
.qb-dashboard { background: radial-gradient(ellipse 65% 65% at -8% 105%, rgba(255,109,41,.28), transparent 70%), var(--canvas); font-size: 14px; line-height: 1.57; }
.qb-shell { width: calc(100% - 24px); max-width: none; min-height: calc(100dvh - 24px); margin: 12px; display: grid; grid-template-columns: var(--rail-width) minmax(0,1fr); grid-template-rows: var(--header-height) 1fr auto; align-content: start; border: 1px solid rgba(255,236,222,.17); border-radius: var(--r-xl); background: var(--shell); box-shadow: inset 0 1px 0 rgba(255,255,255,.04); backdrop-filter: var(--glass-blur); -webkit-backdrop-filter: var(--glass-blur); }
.qb-topbar { grid-column: 1 / -1; display: flex; align-items: center; gap: 20px; min-width: 0; height: var(--header-height); padding-right: 24px; }
.qb-home-mark { flex: 0 0 80px; align-self: stretch; display: grid; place-items: center; }
.qb-home-mark img { width: 30px; height: 30px; }
.qb-wordmark { font: 600 17px/1 var(--sans); letter-spacing: -.04em; color: var(--ink); text-decoration: none; white-space: nowrap; }
.qb-wordmark span { color: var(--ink-3); }
.qb-product { color: var(--ink-3); font-size: 13px; border-left: 1px solid var(--line-2); padding-left: 18px; }
.qb-topbar-right { display: flex; align-items: center; gap: 20px; margin-left: auto; }
.qb-modes { display: flex; gap: 2px; padding: 3px; border-radius: var(--r-pill); background: rgba(0,0,0,.24); box-shadow: inset 0 0 0 1px var(--line); }
.qb-modes a { display: flex; align-items: center; gap: 7px; min-height: 30px; padding: 0 12px; border-radius: var(--r-pill); color: var(--ink-3); text-decoration: none; font-size: 12px; }
.qb-modes svg { width: 14px; height: 14px; }
.qb-modes a[aria-current='page'] { background: var(--raised-3); color: var(--qb-ink); box-shadow: inset 0 0 0 1px var(--line-3); }
.qb-modes a:hover { color: var(--ink); }
.qb-status { min-height: 30px; display: inline-flex; align-items: center; gap: 8px; padding: 0 13px; border: 1px solid var(--line-2); border-radius: var(--r-pill); font: 400 10px/1.4 var(--mono); color: var(--ink-3); white-space: nowrap; }
.qb-rail { grid-column: 1; grid-row: 2 / -1; align-self: start; position: sticky; top: 12px; display: flex; flex-direction: column; gap: 6px; padding: 12px 8px; min-height: calc(100dvh - 102px); }
.qb-rail a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 7px; width: 64px; min-height: 60px; padding: 8px 2px; text-decoration: none; font: 400 10px/1.3 var(--sans); color: var(--ink-3); border: 1px solid transparent; border-radius: 12px; transition: color var(--hover) var(--ease), background var(--hover) var(--ease); }
.qb-rail svg { width: 20px; height: 20px; }
.qb-rail a[aria-current='page'] { background: rgba(255,109,41,.1); color: var(--qb-ink); border-color: rgba(255,109,41,.24); }
.qb-rail a:hover { background: rgba(255,255,255,.04); color: var(--ink); }
.qb-rail-home { margin-top: auto; border-top-color: var(--line) !important; border-radius: 0 !important; }
.qb-content { grid-column: 2; grid-row: 2; min-width: 0; width: auto; margin: 0 12px 12px 0; padding: 32px 36px; border: 1px solid var(--line); border-radius: 18px; background: var(--read); }
.qb-dashboard .workspace-footer { grid-column: 2; padding: 8px 24px 20px; margin: 0; border: 0; font-size: 10px; color: var(--ink-4); }
/* Investigate: the welcome and composer follow the dashboard's 740px reading measure. */
.qb-app #main { padding-top: 0; }
.qb-app .workspace-heading { width: min(var(--thread-width),100%); margin: 0 auto; padding: 110px 34px 64px; min-height: 640px; display: block; }
.qb-welcome-identity { display: flex; align-items: center; gap: 12px; margin-bottom: 28px; color: var(--ink); font-size: 13px; }
.qb-avatar { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 14px; color: var(--qb-ink); background: linear-gradient(135deg,rgba(255,154,107,.14),transparent),var(--raised); border: 1px solid rgba(255,154,107,.26); box-shadow: inset 0 1px 0 rgba(255,255,255,.07); }
.qb-avatar svg { width: 24px; height: 24px; }
.qb-identity-muted { color: var(--ink-3); margin-left: 5px; }
.qb-app .workspace-heading h1 { font: 500 48px/1.08 var(--sans); letter-spacing: -.04em; margin-bottom: 20px; }
.qb-app .workspace-heading p { font-size: 14px; line-height: 22px; color: var(--ink-3); }
.qb-app .workspace-snapshot { display: none; }
.qb-app .chips { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; margin-top: 32px; }
.qb-app .chip-intro { grid-column: 1 / -1; font: 400 11px/16px var(--mono); margin-bottom: 6px; }
.qb-app .chip { min-height: 80px; border-radius: 14px; border-color: var(--line-2); padding: 16px 20px; display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; justify-items: start; text-align: left; font-size: 12px; }
.qb-app .chip b { color: var(--ink); font-size: 13px; font-weight: 500; }
.qb-app .chip>span:first-of-type { grid-column: 1; color: var(--ink-3); }
.qb-app .chip>span:last-child { grid-column: 2; grid-row: 1 / 3; align-self: center; color: var(--ink-4); }
.qb-app .chip:hover { background: var(--raised); border-color: var(--line-3); }
.qb-app .ask { width: min(var(--thread-width),100%); margin: 0 auto 48px; padding: 18px 16px 12px; border-radius: var(--r-lg); border-color: var(--line-3); background: linear-gradient(180deg,rgba(255,244,236,.025),transparent),var(--raised); box-shadow: 0 14px 30px -24px rgba(0,0,0,.6); }
.qb-app .fields { grid-template-columns: minmax(0,1fr) minmax(0,.9fr) auto; gap: 14px; }
.qb-app .fields input { background: transparent; border-color: var(--line-3); min-height: 44px; font-size: 13px; padding: 10px 12px; }
.qb-app .fields .button { min-height: 44px; padding-inline: 16px; }
.composer-meta { display: flex; justify-content: space-between; align-items: center; margin-top: 16px; font: 400 10px/16px var(--mono); color: var(--ink-4); gap: 12px; }
.qb-research-tag { padding: 3px 8px; border: 1px solid var(--line-3); border-radius: 6px; text-transform: uppercase; letter-spacing: .04em; }
.qb-app .investigation { gap: 16px; margin-top: 0; grid-template-columns: minmax(0,1fr) minmax(300px,.49fr); }
.qb-app .map-column { top: 16px; }
.qb-app .map-panel, .qb-app .evidence-panel { background: var(--panel-solid); }
.qb-app .graphwrap { background: var(--sunk); }
.qb-app .graph-empty { background: none; }
.qb-app .panel-heading { padding: 16px 20px; }
.qb-app .panel-heading h2 { font-size: 14px; }
.qb-app .evidence-panel { min-height: 600px; }
.qb-app .answer-empty h3 { font-size: 28px; letter-spacing: -.035em; }
.qb-app .dossier { background: var(--raised); padding: 20px 24px; margin-bottom: 16px; }
.qb-app .dossier-facts .detail { min-height: 0; padding: 0; border: 0; border-radius: 0; background: none; }
.qb-app.has-investigation .workspace-heading { width: 100%; min-height: 0; padding: 24px 0 20px; }
.qb-app.has-investigation .workspace-heading h1 { font-size: 28px; line-height: 34px; margin: 0; }
.qb-app.has-investigation .workspace-heading h1 br { display: none; }
.qb-app.has-investigation .qb-welcome-identity { display: none; }
.qb-app.has-investigation .chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.qb-app.has-investigation .chip { display: inline-flex; min-height: 36px; padding: 6px 12px; border-radius: var(--r-pill); font-size: 11px; gap: 8px; }
.qb-app.has-investigation .chip b { font-size: 11px; }
.qb-app.has-investigation .chip-intro { display: none; }
.qb-app.has-investigation .ask { width: 100%; margin-bottom: 16px; padding: 16px; }
.qb-app.has-investigation .composer-meta { margin-top: 10px; }
/* Memory, brain and settings are workspaces, with the same page scale and opaque panels. */
.qb-dashboard .track-main, .qb-dashboard .settings-layout { padding: 32px 36px 40px; }
.qb-dashboard .track-heading { margin-bottom: 24px; gap: 48px; align-items: start; }
.qb-dashboard .track-heading h1, .qb-dashboard .settings-intro h1 { font-size: 32px; line-height: 38px; letter-spacing: -.035em; max-width: 25ch; margin-bottom: 12px; }
.qb-dashboard .intro, .qb-dashboard .settings-intro>p { font-size: 14px; line-height: 22px; max-width: 65ch; }
.qb-dashboard .eyebrow { font-size: 10px; letter-spacing: .04em; margin-bottom: 16px; }
.qb-dashboard .eyebrow::before { display: none; }
.qb-dashboard .track-context p { font-size: 12px; }
.qb-dashboard .track-context .text-link { font-size: 12px; }
.qb-dashboard .form { padding: 20px 24px; background: var(--raised); }
.qb-dashboard .input-row .button { min-height: 48px; }
.qb-dashboard .examples button { min-height: 36px; border-color: var(--line-2); color: var(--ink-3); }
.qb-dashboard .graph-panel { background: var(--panel-solid); padding: 20px; }
.qb-dashboard .graph-scroll { background: var(--sunk); }
.qb-dashboard .detail { border: 1px solid var(--line); border-radius: var(--r-md); padding: 20px; background: var(--raised); }
.qb-dashboard .track-main h2 { font-size: 16px; line-height: 22px; font-weight: 600; letter-spacing: -.015em; }
.qb-dashboard .graph-controls button { min-height: 36px; min-width: 36px; padding: 6px 12px; background: var(--raised); border-color: var(--line-3); }
.qb-dashboard .findings, .qb-dashboard .sources { margin-top: 32px; }
.qb-dashboard .privacy { font-size: 12px; line-height: 20px; }
.qb-dashboard .settings-layout { gap: 64px; grid-template-columns: minmax(0,.85fr) minmax(0,1fr); align-content: start; }
.qb-dashboard .settings-intro { padding-top: 12px; }
.qb-dashboard .settings-intro h1 br { display: none; }
.qb-dashboard .settings-intro h1 em { font: inherit; color: inherit; letter-spacing: inherit; }
.qb-dashboard .settings-intro>p { margin-bottom: 32px; }
.qb-dashboard .key-principles h2 { font-size: 16px; }
.qb-dashboard .settings-panel { background: var(--raised); padding: 24px; }
.qb-dashboard .settings-panel h2 { font-size: 24px; line-height: 30px; letter-spacing: -.025em; }
.qb-dashboard .settings-panel input { min-height: 48px; height: 48px; border-color: var(--line-3); }
/* Website chrome, copied in proportion from ember.css: floating pill and generous footer. */
.qb-website { background: radial-gradient(ellipse 60% 35% at -8% 100%,rgba(255,109,41,.16),transparent 70%),var(--canvas); }
.qb-website .container { width: min(1080px,calc(100% - 64px)); }
.qb-website .site-header { position: sticky; top: 14px; min-height: 56px; margin-top: 14px; padding: 0 8px 0 20px; border: 0; border-radius: var(--r-pill); background: rgba(29,22,23,.65); box-shadow: inset 0 0 0 1px rgba(255,255,255,.09),0 10px 40px -20px rgba(0,0,0,.7); backdrop-filter: blur(18px) saturate(1.2); -webkit-backdrop-filter: blur(18px) saturate(1.2); }
.qb-website .wordmark { font: 600 19px/1 var(--sans); letter-spacing: -.035em; gap: 10px; white-space: nowrap; }
.qb-brand-name i { font: inherit; color: var(--qb); }
.qb-website .wordmark .brand-mark { width: 24px; height: 24px; }
.qb-website .site-nav { gap: 4px; }
.qb-website .site-nav>.desktop-link { padding: 10px 12px; font-size: 13px; min-height: 40px; }
.qb-website .site-nav .button { min-height: 40px; font-size: 13px; padding-inline: 18px; margin-left: 6px; }
.qb-website .nav-menu { position: relative; }
.qb-website .nav-menu summary { padding-inline: 12px; }
.qb-website .nav-menu-links { top: 48px; width: 300px; max-width: calc(100vw - 32px); }
.qb-website .site-footer { padding-block: 64px 32px; gap: 64px; background: none; }
.qb-website .footer-brand p { font-size: 13px; }
.qb-website .footer-links { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 8px 24px; max-width: none; }
.qb-website .footer-links a { font-size: 13px; }
.qb-website .landing-ambient { position: absolute; height: 1100px; background: radial-gradient(ellipse 65% 50% at 50% 0%,rgba(69,48,39,.65),transparent 80%); }
.qb-reading .blog-hero { padding-block: 96px 64px; gap: 32px 48px; }
.qb-reading .blog-hero h1 { font-size: clamp(36px,4vw,56px); font-weight: 500; line-height: 1.08; letter-spacing: -.04em; }
.qb-reading .blog-hero>img { height: 440px; border-radius: 18px; }
.qb-reading .lede { font-size: 16px; line-height: 26px; }
.qb-reading .blog-story { width: min(720px,calc(100% - 40px)); font-size: 16px; line-height: 1.8; }
.qb-reading .blog-story h2 { font-size: 32px; line-height: 1.2; letter-spacing: -.03em; }
@media (max-width: 1200px) {
  .qb-topbar { gap: 14px; padding-right: 16px; }
  .qb-topbar-right { gap: 12px; }
  .qb-status { display: none; }
  .qb-content, .qb-dashboard .track-main, .qb-dashboard .settings-layout { padding-inline: 24px; }
  .qb-app .investigation { grid-template-columns: minmax(0,1fr) 300px; }
  .qb-website .site-nav>.desktop-link { padding-inline: 8px; }
}
@media (max-width: 1000px) {
  .qb-app .investigation { grid-template-columns: minmax(0,1fr); }
  .qb-app .map-column { position: relative; top: 0; }
  .qb-app .evidence-panel { min-height: 0; }
  .qb-dashboard .track-heading { grid-template-columns: minmax(0,1fr); gap: 20px; }
  .qb-dashboard .track-context { max-width: 65ch; }
  .qb-dashboard .settings-layout { gap: 32px; }
}
@media (max-width: 768px) {
  .qb-dashboard { background: var(--canvas); }
  .qb-shell { width: 100%; min-height: 100dvh; margin: 0; border: 0; border-radius: 0; grid-template-columns: minmax(0,1fr); grid-template-rows: 56px auto; padding-bottom: calc(72px + env(safe-area-inset-bottom)); backdrop-filter: none; -webkit-backdrop-filter: none; }
  .qb-topbar { height: 56px; padding: 0 16px; gap: 12px; }
  .qb-home-mark { flex-basis: 24px; }
  .qb-home-mark img { width: 24px; height: 24px; }
  .qb-wordmark { font-size: 16px; }
  .qb-product { font-size: 12px; padding-left: 12px; }
  .qb-topbar-right { display: none; }
  .qb-rail { position: fixed; z-index: 40; inset: auto 0 0; grid-column: auto; min-height: 0; flex-direction: row; justify-content: space-around; align-items: center; padding: 6px 8px calc(6px + env(safe-area-inset-bottom)); gap: 0; background: rgba(33,27,27,.97); border-top: 1px solid var(--line-2); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); }
  .qb-rail a { width: 64px; min-height: 54px; gap: 5px; padding: 6px 2px; font-size: 10px; border-radius: 10px; }
  .qb-rail .qb-rail-home { display: none; }
  .qb-content { grid-column: 1; grid-row: 2; margin: 0; padding: 24px 16px; border: 0; border-radius: 0; }
  .qb-dashboard .workspace-footer { grid-column: 1; padding: 20px 16px; }
  .qb-app #main { padding: 0 16px 24px; }
  .qb-app .workspace-heading { min-height: 0; padding: 60px 4px 32px; }
  .qb-welcome-identity { font-size: 12px; margin-bottom: 24px; gap: 10px; }
  .qb-avatar { width: 36px; height: 36px; border-radius: 12px; flex: none; }
  .qb-avatar svg { width: 21px; height: 21px; }
  .qb-identity-muted { font-size: 11px; margin-left: 3px; }
  .qb-app .workspace-heading h1 { font-size: 34px; line-height: 37px; letter-spacing: -.04em; margin-bottom: 16px; }
  .qb-app .workspace-heading p { font-size: 13px; max-width: 35ch; }
  .qb-app .chips { gap: 8px; margin-top: 28px; }
  .qb-app .chip { min-height: 76px; padding: 12px; gap: 6px; font-size: 11px; }
  .qb-app .chip b { font-size: 12px; }
  .qb-app .chip>span:last-child { display: none; }
  .qb-app .ask { padding: 16px; margin-bottom: 40px; }
  .qb-app .fields { grid-template-columns: minmax(0,1fr); gap: 12px; }
  .qb-app .fields .button { width: 100%; min-height: 44px; justify-content: space-between; }
  .qb-app .fields input { min-height: 46px; font-size: 14px; }
  .qb-app .composer-meta { font-size: 9px; }
  .qb-app .investigation { gap: 16px; }
  .qb-app #graph { height: 390px; }
  .qb-app .dossier { padding: 16px; }
  .qb-app .panel-heading { padding: 16px; }
  .qb-app .panel-heading h2 { font-size: 13px; }
  .qb-app.has-investigation .workspace-heading { padding: 24px 0 16px; }
  .qb-app.has-investigation .workspace-heading h1 { font-size: 28px; line-height: 34px; }
  .qb-app.has-investigation .chips { gap: 6px; margin-top: 12px; }
  .qb-app.has-investigation .chip { min-height: 44px; padding: 6px 10px; }
  .qb-app.has-investigation .chip>span:first-of-type { display: none; }
  .qb-dashboard .track-main, .qb-dashboard .settings-layout { padding: 28px 16px 40px; }
  .qb-dashboard .track-heading h1, .qb-dashboard .settings-intro h1 { font-size: 28px; line-height: 34px; }
  .qb-dashboard .track-heading { margin-bottom: 24px; gap: 16px; }
  .qb-dashboard .track-context { padding-left: 16px; }
  .qb-dashboard .form, .qb-dashboard .graph-panel, .qb-dashboard .detail { padding: 16px; }
  .qb-dashboard .graph-controls button { min-height: 44px; min-width: 44px; }
  .qb-dashboard .examples button { white-space: normal; min-height: 44px; }
  .qb-dashboard .settings-layout { grid-template-columns: minmax(0,1fr); gap: 16px; }
  .qb-dashboard .settings-intro { padding-top: 0; }
  .qb-dashboard .settings-intro>p { margin-bottom: 8px; }
  .qb-dashboard .settings-panel { padding: 20px; }
  .qb-dashboard .button, .qb-dashboard .btn { min-height: 44px; }
  .qb-website .container { width: calc(100% - 40px); }
  .qb-website .site-header { width: calc(100% - 20px); top: 10px; margin-top: 10px; padding: 0 6px 0 14px; min-height: 52px; gap: 4px; }
  .qb-website .wordmark { font-size: 16px; gap: 8px; }
  .qb-website .wordmark .brand-mark { width: 22px; height: 22px; }
  .qb-website .site-nav { gap: 0; }
  .qb-website .site-nav .button { padding-inline: 12px; min-height: 40px; font-size: 12px; gap: 6px; margin-left: 0; }
  .qb-website .nav-menu summary { padding-inline: 8px; font-size: 12px; }
  .qb-website .site-footer { gap: 32px; padding-block: 48px 24px; }
  .qb-website .footer-links { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 4px 24px; width: 100%; }
  .qb-reading .blog-hero { padding-block: 56px 32px; gap: 24px; }
  .qb-reading .blog-hero h1 { font-size: 40px; line-height: 1.09; }
  .qb-reading .blog-hero>img { height: auto; aspect-ratio: 3/2; }
  .qb-reading .blog-story h2 { font-size: 28px; }
}
@media (max-width: 360px) {
  .qb-website .wordmark { font-size: 14px; gap: 5px; }
  .qb-website .wordmark .brand-mark { width: 19px; }
  .qb-website .site-nav .button { padding-inline: 10px; }
  .qb-website .site-nav .button .arrow { display: none; }
  .qb-identity-muted { display: block; margin: 4px 0 0; }
}
@media (prefers-reduced-transparency: reduce) {
  .qb-shell, .qb-website .site-header, .qb-rail { background: #28201F; backdrop-filter: none; -webkit-backdrop-filter: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
/* Showcase: the submitted story, in the website's display scale and section rhythm. */
.qb-story-home .showcase-hero { position: relative; text-align: center; padding: 80px 0 72px; }
.qb-story-home .showcase-hero .eyebrow { justify-content: center; text-transform: none; letter-spacing: .02em; font-size: 11px; margin-bottom: 24px; }
.qb-story-home .showcase-hero .eyebrow::before { display: none; }
.qb-story-home .showcase-hero h1 { font-size: clamp(48px,6.4vw,88px); line-height: 1.03; letter-spacing: -.045em; font-weight: 600; margin: 0 0 24px; }
.qb-story-home .showcase-hero h1 em { display: inline-block; padding-bottom: 8px; font-family: var(--serif); font-weight: 400; line-height: 1.1; color: #FFE7D6; letter-spacing: -.025em; }
.qb-story-home .hero-description { font-size: 18px; line-height: 29px; max-width: 55ch; margin: 0 auto 32px; color: var(--ink-3); }
.qb-story-home .hero-ask { text-align: left; max-width: 660px; margin: 0 auto; padding: 20px 20px 16px 24px; background: rgba(41,30,26,.88); border-color: var(--line-3); border-radius: var(--r-lg); box-shadow: 0 14px 40px -24px rgba(0,0,0,.7); }
.qb-story-home .hero-ask label { font-size: 12px; color: var(--ink-3); margin-bottom: 8px; }
.qb-story-home .hero-ask input { background: transparent; border: 0; font-size: 14px; color: var(--ink); }
.qb-story-home .hero-ask .button { min-height: 44px; width: 48px; border-radius: var(--r-pill); }
.qb-story-home .hero-links { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 12px 28px; margin-top: 16px; }
.qb-story-home .example-link { margin: 0; font-size: 12px; }
.video-play { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; font-size: 12px; text-decoration: none; color: var(--ink-2); }
.play-circle { width: 30px; height: 30px; border: 1px solid var(--line-3); border-radius: 50%; display: grid; place-items: center; padding-left: 2px; font-size: 9px; color: var(--ink); }
.video-play:hover .play-circle { background: var(--cta); color: var(--cta-ink); }
.story-opening { padding-top: 32px; }
.story-intro { max-width: 680px; margin-bottom: 40px; }
.story-intro h2, .story-copy h2 { font-size: clamp(32px,3.8vw,52px); line-height: 1.08; letter-spacing: -.04em; margin-bottom: 20px; }
.story-intro p, .story-copy p { font-size: 16px; line-height: 26px; max-width: 49ch; margin-bottom: 16px; }
.story-copy p:last-of-type { margin-bottom: 16px; }
.story-copy .text-link { color: var(--ink-2); font-size: 13px; }
.story-figure { margin: 0; min-width: 0; }
.story-art { position: relative; isolation: isolate; overflow: hidden; min-width: 0; aspect-ratio: 3 / 2; border-radius: 18px; border: 1px solid var(--line-2); background: radial-gradient(ellipse 70% 50% at 70% 80%,rgba(255,109,41,.2),transparent 85%),linear-gradient(135deg,#191719,#34251F); }
.story-art picture { position: absolute; inset: 0; display: block; }
.story-art img { display: block; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity var(--page) var(--ease); }
.story-art img.is-ready { opacity: 1; }
.story-art img:not([src]) { visibility: hidden; }
.story-fallback { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; gap: 24px; padding: 12%; }
.story-fallback span { flex: none; width: 44px; height: 44px; border-radius: 50%; background: var(--raised-2); border: 1px solid var(--line-3); }
.story-fallback span:last-child { background: rgba(255,109,41,.1); border-color: var(--qb-ink); border-radius: 12px; }
.story-fallback i { width: 80px; height: 1px; background: var(--line-3); }
.story-figure figcaption { margin-top: 12px; font-size: 12px; line-height: 20px; color: var(--ink-3); max-width: 75ch; }
.story-opening .story-art { aspect-ratio: 16 / 8; }
.story-chapter { display: grid; grid-template-columns: minmax(0,.78fr) minmax(0,1.22fr); gap: 64px; align-items: center; padding-top: 128px; }
.story-chapter.story-reverse { grid-template-columns: minmax(0,1.22fr) minmax(0,.78fr); }
.story-reverse .story-copy { grid-column: 2; grid-row: 1; }
.story-reverse .story-figure { grid-column: 1; grid-row: 1; }
.story-ring-section { padding-top: 128px; }
.story-ring-section .story-art { aspect-ratio: 16 / 8; }
.story-graph-demo { max-width: 720px; margin: 48px auto 0; }
.story-graph-demo .hero-visual { min-width: 0; border: 1px solid var(--line); border-radius: 18px; padding: 16px 24px; background: var(--panel-solid); }
.story-graph-demo .visual-topline { padding-top: 0; }
.story-graph-demo .lineage-visual { max-height: 410px; }
.story-evidence { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); align-items: center; gap: 64px; padding-top: 128px; }
.story-evidence h2 em { display: inline-block; padding-bottom: 5px; color: #FFE7D6; line-height: 1.12; }
.story-answer-demo { padding: 24px; border-radius: 18px; border: 1px solid var(--line-2); background: var(--raised); }
.story-demo-top { display: flex; align-items: center; gap: 12px; color: var(--ink-2); font-size: 13px; margin-bottom: 28px; }
.story-demo-top .tag { margin-left: auto; font-size: 10px; }
.story-answer-demo>p { font-size: 20px; line-height: 32px; color: var(--ink); margin-bottom: 24px; letter-spacing: -.015em; }
.story-answer-demo .ev { font-size: 11px; text-decoration: none; }
.story-evidence-source { border: 1px solid rgba(255,109,41,.24); background: rgba(255,109,41,.05); border-radius: 10px; padding: 16px; display: grid; gap: 8px; font-size: 12px; line-height: 20px; color: var(--ink-3); }
.story-evidence-source .mono { color: var(--qb-ink); font-size: 11px; }
.story-demo-foot { border-top: 1px solid var(--line); padding-top: 16px; margin-top: 24px; color: var(--ink-3); font-size: 11px; }
.story-twist { padding-block: 144px 96px; text-align: center; }
.story-side-note { font: 400 11px/1.5 var(--mono); color: var(--ink-3); }
.story-twist h2 { font-size: clamp(48px,6.4vw,88px); line-height: 1.02; letter-spacing: -.045em; margin: 28px 0 24px; }
.story-twist h2 em { display: inline-block; line-height: 1.15; padding-bottom: 6px; color: #FFE7D6; }
.story-twist p { max-width: 55ch; margin: 0 auto 16px; font-size: 16px; line-height: 26px; }
.story-twist .text-link { color: var(--ink-2); margin-top: 8px; }
.qb-story-home .tracks-section { padding-block: 32px 80px; }
.qb-story-home .section-intro h2 { font-size: 48px; letter-spacing: -.04em; }
.qb-story-home .section-intro>p { font-size: 16px; line-height: 26px; }
.qb-story-home .track-list article { grid-template-columns: 32px minmax(0,1fr) 172px; padding-block: 28px; gap: 24px; }
.qb-story-home .track-list h3 { font-size: 24px; }
.qb-story-home .track-list p { font-size: 14px; line-height: 23px; }
.qb-story-home .quantbase-section { padding-block: 80px; background: radial-gradient(ellipse 70% 65% at 0 100%,rgba(255,109,41,.1),transparent 85%); border-block: 1px solid var(--line); }
.qb-story-home .quantbase-inner { gap: 64px; }
.qb-story-home .quantbase-copy h2 { font-size: 48px; }
.qb-story-home .quantbase-copy p { font-size: 15px; line-height: 25px; }
.qb-story-home .product-connection { background: var(--raised); }
.story-snapshot { padding-top: 96px; }
.story-snapshot h2 { font-size: 32px; letter-spacing: -.03em; }
.qb-story-home .stats { margin-block: 40px 16px; gap: 20px; }
.qb-story-home .stats strong { font-family: var(--mono); font-size: 36px; letter-spacing: -.05em; }
.qb-story-home .developer-section, .qb-story-home .results-section { padding-block: 96px 0; }
.qb-story-home .developer-grid { gap: 48px; }
.qb-story-home .results-section .limits { margin-top: 40px; }
.qb-story-home .closing { padding-block: 96px 80px; }
.qb-story-home .closing h2 { font-size: 40px; }
.qb-story-home .eyebrow::before { display: none; }
.demo-dialog { width: min(960px,calc(100% - 32px)); max-height: calc(100dvh - 32px); padding: 24px; border: 1px solid var(--line-3); border-radius: 22px; background: var(--raised); color: var(--ink); box-shadow: 0 24px 64px rgba(0,0,0,.55); }
.demo-dialog::backdrop { background: rgba(12,9,10,.85); backdrop-filter: blur(12px); }
.demo-dialog-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.demo-dialog-head h2 { font-size: 16px; line-height: 24px; letter-spacing: -.02em; margin: 0; }
.demo-player { aspect-ratio: 16 / 9; background: var(--sunk); border-radius: 10px; overflow: hidden; }
.demo-player iframe { width: 100%; height: 100%; border: 0; }
.demo-dialog>.text-link { margin-top: 12px; font-size: 12px; }
@media (prefers-reduced-motion: no-preference) {
  [data-reveal].reveal-pending { opacity: 0; transform: translateY(16px); }
  [data-reveal] { transition: opacity 500ms var(--ease),transform 500ms var(--ease); }
}
@media (max-width: 1000px) {
  .story-chapter, .story-chapter.story-reverse, .story-evidence { gap: 32px; }
  .qb-story-home .quantbase-inner { gap: 32px; }
}
@media (max-width: 768px) {
  .qb-story-home .showcase-hero { padding: 56px 0 40px; }
  .qb-story-home .showcase-hero .eyebrow { font-size: 9px; letter-spacing: 0; margin-bottom: 24px; }
  .qb-story-home .showcase-hero h1 { font-size: clamp(40px,9.8vw,62px); line-height: 1.06; margin-bottom: 20px; }
  .qb-story-home .showcase-hero h1 em { line-height: 1.13; padding-bottom: 4px; }
  .qb-story-home .hero-description { font-size: 15px; line-height: 24px; margin-bottom: 24px; max-width: 39ch; }
  .qb-story-home .hero-ask { padding: 16px; }
  .qb-story-home .hero-ask label { font-size: 11px; }
  .qb-story-home .hero-ask input { font-size: 12px; min-height: 44px; height: 44px; }
  .qb-story-home .hero-ask .button { width: 44px; }
  .qb-story-home .hero-links { gap: 8px 16px; margin-top: 12px; }
  .qb-story-home .example-link { font-size: 11px; gap: 8px; }
  .qb-story-home .hero-links .example-context { display: none; }
  .story-opening { padding-top: 32px; }
  .story-intro { margin-bottom: 24px; }
  .story-intro h2, .story-copy h2 { font-size: 32px; line-height: 1.12; margin-bottom: 16px; }
  .story-intro p, .story-copy p { font-size: 15px; line-height: 25px; }
  .story-chapter, .story-chapter.story-reverse, .story-evidence { grid-template-columns: minmax(0,1fr); gap: 24px; padding-top: 72px; }
  .story-reverse .story-copy, .story-reverse .story-figure { grid-column: 1; grid-row: auto; }
  .story-ring-section { padding-top: 72px; }
  .story-art, .story-opening .story-art, .story-ring-section .story-art { aspect-ratio: 4 / 3; border-radius: 14px; }
  .story-figure figcaption { font-size: 11px; line-height: 18px; margin-top: 10px; }
  .story-fallback { gap: 16px; }
  .story-fallback span { width: 32px; height: 32px; }
  .story-fallback i { width: 40px; }
  .story-graph-demo { margin-top: 24px; }
  .story-graph-demo .hero-visual { padding: 12px; border-radius: 14px; }
  .story-graph-demo .visual-topline { gap: 4px; }
  .story-graph-demo .visual-topline .mono { font-size: 10px; }
  .story-graph-demo .diagram-label { font-size: 9px; }
  .story-answer-demo { padding: 20px; }
  .story-answer-demo>p { font-size: 19px; line-height: 30px; }
  .story-twist { padding-block: 88px 56px; }
  .story-side-note { font-size: 10px; }
  .story-twist h2 { font-size: 48px; }
  .story-twist p { font-size: 15px; line-height: 25px; }
  .qb-story-home .section-intro h2, .qb-story-home .quantbase-copy h2 { font-size: 36px; }
  .qb-story-home .tracks-section { padding-block: 16px 56px; }
  .qb-story-home .track-list article { grid-template-columns: 24px minmax(0,1fr); gap: 8px 12px; padding-block: 24px; }
  .qb-story-home .track-list h3 { font-size: 21px; line-height: 26px; }
  .qb-story-home .track-list .text-link { grid-column: 2; }
  .qb-story-home .quantbase-section { padding-block: 48px; }
  .qb-story-home .quantbase-inner { gap: 32px; }
  .story-snapshot { padding-top: 56px; }
  .story-snapshot h2 { font-size: 28px; }
  .qb-story-home .stats { gap: 24px 16px; grid-template-columns: repeat(2,minmax(0,1fr)); margin-top: 28px; }
  .qb-story-home .stats strong { font-size: 29px; }
  .qb-story-home .stats>div:nth-child(3) { border-left: 0; padding-left: 0; }
  .qb-story-home .developer-section, .qb-story-home .results-section { padding-top: 64px; }
  .qb-story-home .developer-grid { gap: 24px; }
  .qb-story-home .closing { padding-block: 64px 48px; }
  .qb-story-home .closing h2 { font-size: 32px; }
  .demo-dialog { padding: 16px; }
  .demo-dialog-head { margin-bottom: 16px; gap: 8px; }
  .demo-dialog-head h2 { font-size: 13px; }
  .demo-dialog-head .button { min-height: 44px; padding-inline: 12px; font-size: 12px; }
}
/* Hero graph: a calm ten-second narrative, then a quiet reset. Every node has a text equivalent. */
.qb-story-home .landing-ambient { height: 1120px; background: linear-gradient(180deg,rgba(22,19,22,.76),rgba(22,19,22,.72) 42%,rgba(22,19,22,.93) 80%,var(--canvas)),url('/static/img/story/00-hero-bg.webp') center top / cover no-repeat; }
.qb-story-home .showcase-hero { padding-top: 56px; padding-bottom: 56px; }
.qb-story-home .showcase-hero h1 { font-size: clamp(48px,5.7vw,80px); }
.production-badge { display: inline-flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px; padding: 7px 12px; margin-bottom: 24px; color: var(--ink-2); background: rgba(22,19,22,.68); border: 1px solid rgba(255,236,222,.2); border-radius: var(--r-pill); font: 400 11px/18px var(--mono); text-decoration: none; }
.production-badge span { color: var(--qb-ink); border-left: 1px solid var(--line-2); padding-left: 10px; }
.production-badge:hover { border-color: var(--line-3); }
.hero-flow { max-width: 1000px; margin: 24px auto 0; }
.hero-flow-canvas { width: 100%; height: auto; overflow: visible; display: block; }
.hero-flow-canvas use, .hero-flow-legend svg, .story-glyph svg { fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.flow-base-paths, .flow-branch-base { fill: none; stroke: var(--line-3); stroke-width: 1; }
.flow-branch-base { opacity: .65; }
.flow-hub-base { stroke-dasharray: 3 5; }
.flow-ring-outline { fill: none; stroke: rgba(255,170,128,.35); stroke-width: 1; stroke-dasharray: 3 7; }
.flow-trace { fill: none; stroke: var(--qb-ink); stroke-width: 2; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 1; animation: flow-creator 10s var(--ease) infinite; }
.flow-trace-funder { animation-name: flow-funder; }
.flow-trace-ring, .flow-trace-branch { animation-name: flow-ring; }
.flow-trace-hub { animation-name: flow-hub; stroke: var(--warn); }
.flow-node { color: var(--ink-2); }
.flow-node-base { fill: var(--raised); stroke: var(--line-3); stroke-width: 1; }
.flow-node-light { fill: rgba(255,109,41,.15); stroke: var(--qb-ink); stroke-width: 1.5; opacity: 0; animation: node-coin 10s var(--ease) infinite; }
.flow-node-creator .flow-node-light { animation-name: node-creator; }
.flow-node-funder .flow-node-light { animation-name: node-funder; }
.flow-node-branch .flow-node-light { animation-name: node-ring; }
.flow-node-hub .flow-node-light { stroke: var(--warn); animation-name: node-hub; }
.flow-label { fill: var(--ink-2); font: 400 14px var(--sans); }
.flow-small-label { fill: var(--ink-3); font: 400 11px var(--mono); }
.hero-flow-legend { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 8px 12px; margin-top: 0; font-size: 11px; color: var(--ink-3); }
.hero-flow-legend>span { display: inline-flex; align-items: center; gap: 6px; }
.hero-flow-legend svg { width: 15px; height: 15px; color: var(--qb-ink); }
.hero-flow-legend i { font-style: normal; color: var(--ink-4); }
.hero-flow-legend button { border: 0; border-left: 1px solid var(--line-2); background: transparent; font: 400 10px/1.5 var(--mono); color: var(--ink-3); min-height: 44px; padding: 0 0 0 16px; margin-left: 8px; }
.hero-flow-legend button:hover { color: var(--ink); }
.hero-flow[data-flow='paused'] * { animation-play-state: paused; }
.story-glyph { display: grid; place-items: center; width: 40px; height: 40px; border: 1px solid rgba(255,170,128,.3); background: rgba(255,109,41,.06); border-radius: 12px; margin-bottom: 20px; color: var(--qb-ink); }
.story-glyph svg { width: 22px; height: 22px; }
.story-art:has(img.is-ready) .story-fallback { visibility: hidden; }
@keyframes flow-creator { 0%,8% { stroke-dashoffset: 1; opacity: 0; } 12% { opacity: 1; } 25%,88% { stroke-dashoffset: 0; opacity: 1; } 100% { stroke-dashoffset: 0; opacity: 0; } }
@keyframes flow-funder { 0%,24% { stroke-dashoffset: 1; opacity: 0; } 28% { opacity: 1; } 41%,88% { stroke-dashoffset: 0; opacity: 1; } 100% { stroke-dashoffset: 0; opacity: 0; } }
@keyframes flow-ring { 0%,40% { stroke-dashoffset: 1; opacity: 0; } 44% { opacity: 1; } 62%,88% { stroke-dashoffset: 0; opacity: 1; } 100% { stroke-dashoffset: 0; opacity: 0; } }
@keyframes flow-hub { 0%,62% { stroke-dashoffset: 1; opacity: 0; } 66% { opacity: 1; } 76%,88% { stroke-dashoffset: 0; opacity: 1; } 100% { stroke-dashoffset: 0; opacity: 0; } }
@keyframes node-coin { 0% { opacity: 0; } 8%,88% { opacity: 1; } 100% { opacity: 0; } }
@keyframes node-creator { 0%,20% { opacity: 0; } 28%,88% { opacity: 1; } 100% { opacity: 0; } }
@keyframes node-funder { 0%,36% { opacity: 0; } 44%,88% { opacity: 1; } 100% { opacity: 0; } }
@keyframes node-ring { 0%,55% { opacity: 0; } 65%,88% { opacity: 1; } 100% { opacity: 0; } }
@keyframes node-hub { 0%,70% { opacity: 0; } 78%,88% { opacity: 1; } 100% { opacity: 0; } }
@media (max-width: 768px) {
  .qb-story-home .landing-ambient { height: 950px; background-image: linear-gradient(180deg,rgba(22,19,22,.83),rgba(22,19,22,.72) 42%,rgba(22,19,22,.93) 80%,var(--canvas)),url('/static/img/story/00-hero-bg-m.webp'); }
  .qb-story-home .showcase-hero { padding-top: 40px; padding-bottom: 32px; }
  .qb-story-home .showcase-hero h1 { font-size: clamp(38px,9.6vw,58px); }
  .production-badge { font-size: 9px; line-height: 16px; gap: 7px; margin-bottom: 20px; padding: 6px 10px; }
  .production-badge span { padding-left: 7px; }
  .hero-flow { margin-top: 16px; }
  .hero-flow-canvas { margin-block: 8px; }
  .flow-label, .flow-small-label { display: none; }
  .flow-node-base, .flow-node-light, .flow-base-paths, .flow-branch-base, .flow-trace, .flow-ring-outline { vector-effect: non-scaling-stroke; }
  .hero-flow-legend { gap: 6px; font-size: 10px; }
  .hero-flow-legend>span { gap: 4px; }
  .hero-flow-legend svg { width: 13px; height: 13px; }
  .hero-flow-legend button { flex-basis: 100%; border-left: 0; margin: 0; padding: 0; font-size: 10px; }
  .story-glyph { width: 36px; height: 36px; margin-bottom: 16px; }
  .story-glyph svg { width: 20px; height: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  .flow-trace { animation: none !important; stroke-dashoffset: 0; opacity: 1; }
  .flow-node-light { animation: none !important; opacity: 1; }
  .hero-flow-legend button { color: var(--ink-3); }
}
/* Second comparison pass: keep the dashboard frame visible while its reading pane scrolls. */
@media (min-width: 769px) {
  .qb-dashboard { overflow: hidden; }
  .qb-shell { position: fixed; inset: 12px; width: auto; min-height: 0; margin: 0; grid-template-rows: var(--header-height) minmax(0,1fr); }
  .qb-rail { position: relative; top: auto; height: 100%; min-height: 0; }
  .qb-content { min-height: 0; overflow-y: auto; overscroll-behavior: contain; scroll-padding-block: 24px; scrollbar-width: thin; scrollbar-color: var(--raised-3) transparent; }
  .qb-app:not(.has-investigation) .workspace-heading { min-height: max(560px,calc(100dvh - 270px)); padding-top: clamp(80px,15vh,154px); }
  .qb-app .workspace-footer { padding: 24px 0 8px; }
}
/* Anchor the website menu to the full header, keeping both columns inside narrow viewports. */
.qb-website .nav-menu { position: static; }
.qb-website .nav-menu-links { top: calc(100% + 8px); right: 8px; width: 320px; max-width: calc(100% - 16px); }
@media (max-width: 640px) {
  .story-new-coin .story-art, .story-trail .story-art, .story-ring .story-art { aspect-ratio: 4 / 5; }
}
@media (max-width: 768px) {
  .qb-app:not(.has-investigation) .workspace-heading { padding-top: 32px; padding-bottom: 24px; }
  .qb-app:not(.has-investigation) .qb-welcome-identity { margin-bottom: 20px; }
  .qb-app:not(.has-investigation) .chips { margin-top: 20px; }
  .qb-app:not(.has-investigation) .chip { min-height: 68px; }
  .qb-app:not(.has-investigation) .fields { gap: 10px; }
  .qb-app:not(.has-investigation) .composer-meta { margin-top: 12px; }
}
/* Website footer: the same brand/three-column/risk-note structure as QuantBase. */
.qb-website .site-footer { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,2fr); gap: 40px 64px; }
.footer-columns { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 24px; }
.footer-columns nav { display: flex; flex-direction: column; align-items: start; }
.footer-columns h2 { margin: 0 0 12px; color: var(--qb-ink); font: 500 11px/18px var(--mono); letter-spacing: .08em; text-transform: uppercase; }
.footer-columns a { display: inline-flex; align-items: center; min-height: 40px; color: var(--ink-2); font-size: 13px; line-height: 20px; text-decoration: none; }
.footer-columns a:hover { color: var(--ink); }
.footer-risk { grid-column: 1 / -1; padding-top: 24px; border-top: 1px solid var(--line); margin: 0; font-size: 12px; line-height: 20px; color: var(--ink-3); }
.footer-risk strong { color: var(--ink-2); font-weight: 500; }
@media (max-width: 768px) {
  .qb-website .site-footer { grid-template-columns: minmax(0,1fr); gap: 32px; }
  .footer-columns { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 24px 20px; }
  .footer-columns a { min-height: 44px; }
}
/* Landing polish: the v6 font families, a measured display scale and an 8px rhythm. */
.qb-story-home { --landing-section-space: 112px; --landing-heading: clamp(34px,3.6vw,48px); }
.qb-story-home h1, .qb-story-home h2, .qb-story-home h3 { text-wrap: balance; }
.qb-story-home .showcase-hero h1 { font-size: clamp(48px,5.6vw,80px); font-weight: 500; line-height: 1.04; letter-spacing: -.03em; }
.qb-story-home .showcase-hero h1 em { letter-spacing: -.025em; line-height: 1.1; }
.qb-story-home .hero-description { max-width: 60ch; font-size: 18px; line-height: 1.6; text-wrap: pretty; }
.qb-story-home .story-intro { max-width: 760px; margin-bottom: 40px; }
.qb-story-home .story-intro h2, .qb-story-home .story-copy h2,
.qb-story-home .section-intro h2, .qb-story-home .quantbase-copy h2,
.qb-story-home .closing h2 { font-size: var(--landing-heading); font-weight: 500; line-height: 1.08; letter-spacing: -.03em; margin-bottom: 24px; }
.qb-story-home .story-intro p, .qb-story-home .story-copy p,
.qb-story-home .section-intro>p, .qb-story-home .quantbase-copy p,
.qb-story-home .story-twist p, .qb-story-home .track-list p,
.qb-story-home .falkor-details p, .qb-story-home .closing p { font-size: 18px; line-height: 1.6; max-width: 64ch; color: var(--ink-3); text-wrap: pretty; }
.qb-story-home .story-copy p { margin-bottom: 16px; }
.qb-story-home .story-chapter, .qb-story-home .story-ring-section,
.qb-story-home .story-evidence, .qb-story-home .story-snapshot,
.qb-story-home .developer-section, .qb-story-home .results-section { padding-top: var(--landing-section-space); }
.qb-story-home .story-twist { padding-block: var(--landing-section-space) 80px; }
.qb-story-home .story-twist h2 { letter-spacing: -.03em; line-height: 1.05; font-weight: 500; }
.qb-story-home .eyebrow, .qb-story-home .story-side-note,
.qb-story-home .feature-label, .qb-story-home .connection-label { font: 500 11px/1.5 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
.qb-story-home .track-list h3, .qb-story-home .falkor-details h3 { font-size: 24px; line-height: 1.2; letter-spacing: -.02em; }
/* SVG geometry stays fixed. Glows and moving particles only paint inside the reserved canvas. */
.graph-icon { color: var(--qb-hi); fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.hub-core { fill: #30291e; stroke: var(--warn); stroke-width: 1.5; }
.hub-stop { fill: none; stroke: var(--warn); stroke-width: 2.5; stroke-linecap: round; }
.edge-hub { stroke: var(--warn); }
.graph-staged .trace-node { --reached: 0; }
.graph-staged .trace-node .svg-title, .graph-staged .trace-node .svg-address,
.graph-staged .hub-stop { opacity: var(--reached); }
.graph-staged .node-core, .graph-staged .coin-core { stroke: var(--qb-hi); stroke-opacity: calc(.3 + var(--reached) * .7); }
.graph-staged .node-halo { transition: none; }
.graph-staged .aggregate-branches { opacity: 1; }
.graph-staged .aggregate-nodes { opacity: 1; }
.graph-staged .aggregate-nodes>* { fill: rgba(255,109,41,.12); stroke: var(--qb-hi); opacity: calc(.2 + var(--reached,0) * .8); }
.graph-staged .staged-edge { fill: none; stroke: var(--qb-ink); stroke-width: 1.5; stroke-linecap: round; transition: none; }
.graph-staged .edge-hub { stroke: var(--warn); stroke-width: 1.8; }
.graph-staged .edge-arrows, .graph-staged .evidence-path>path:first-child { display: none; }
.graph-sparks { fill: #ffe5ce; filter: drop-shadow(0 0 4px #ff6d29); pointer-events: none; }
.graph-staged .hub-node .node-halo { fill: var(--warn); }
@media (max-width: 768px) {
  .qb-story-home { --landing-section-space: 72px; --landing-heading: 34px; }
  .qb-story-home .showcase-hero h1 { font-size: clamp(36px,9.4vw,58px); line-height: 1.06; }
  .qb-story-home .hero-description, .qb-story-home .story-intro p,
  .qb-story-home .story-copy p, .qb-story-home .section-intro>p,
  .qb-story-home .quantbase-copy p, .qb-story-home .story-twist p,
  .qb-story-home .track-list p, .qb-story-home .falkor-details p,
  .qb-story-home .closing p { font-size: 17px; line-height: 1.6; }
  .qb-story-home .story-intro h2, .qb-story-home .story-copy h2,
  .qb-story-home .section-intro h2, .qb-story-home .quantbase-copy h2,
  .qb-story-home .closing h2 { margin-bottom: 20px; }
  .qb-story-home .story-twist { padding-bottom: 56px; }
}
@media (prefers-reduced-motion: reduce) { .graph-sparks { display: none; } }
.graph-staged .hub-core { stroke-opacity: calc(.25 + var(--reached) * .75); }
.graph-staged .trace-node .graph-icon { opacity: calc(.4 + var(--reached) * .6); }
.graph-trail-caption { margin: 16px 0 0; color: var(--ink-3); font-size: 13px; line-height: 1.6; text-wrap: pretty; text-align: center; }
/* The first schematic uses the same ember treatment, with a stagger across its ring. */
.flow-trace { filter: drop-shadow(0 0 3px rgba(255,109,41,.4)); }
.flow-node-light { filter: drop-shadow(0 0 5px rgba(255,109,41,.3)); }
.graph-staged .pause-graph { min-width: 64px; text-align: right; }
