/* Fasra site. Built on g-design: only the accent slot is overridden; greys, spacing and motion are g's. */
:root, [data-theme] {
  --font-brand: "Young Serif", "Young Serif Fallback", Georgia, serif;
  --accent-fill: #5BD29A; --accent-fill-hover: #4FC28C; --accent-fg: #0F1A14; --accent-edge: #4FC28C;
  --leaf: #5BD29A; --leaf-text: #5BD29A;
  --frame: 1240px;
  --fade-x: linear-gradient(to right, transparent, #000 14%, #000 86%, transparent);
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .5  0 0 0 0 .5  0 0 0 0 .5  1.6 0 0 0 -.55'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  /* Light: set by fasra.js from the pointer. --lx/--ly are page coordinates in px. */
  --lx: 30vw; --ly: -10vh;
  /* Look and motion settings, tuned live from the studio playground (it sets these and fires fasra:set). */
  --fx-layout: split; --fx-cursor-light: 0; --fx-grain: .07; --fx-lean: -7; --fx-sway: 1.7; --fx-spin: .03; --fx-dof: 1;
  --fx-reveal-ms: 500; --fx-reveal-blur: 24; --fx-send-ms: 140;
  /* Three timings for every move on the page: quick for feedback and exits, move for anything that changes place or size
     (fasra.js reads it for its glides), and the reveal above at the same length. Two easings: out for reveals, in-out for moves. */
  --mo-quick: var(--dur-base); --mo-move: var(--dur-sheet);
}
:root[data-theme="light"], [data-theme="light"] {
  --accent-fill: #1E7F53; --accent-fill-hover: #1A6F49; --accent-fg: #FFFFFF; --accent-edge: #1A6F49; --leaf: #23905E; --leaf-text: #1E7F53;
}
@media (prefers-color-scheme: light) {
  :root[data-theme="system"] { --accent-fill: #1E7F53; --accent-fill-hover: #1A6F49; --accent-fg: #FFFFFF; --accent-edge: #1A6F49; --leaf: #23905E; --leaf-text: #1E7F53; }
}

html, body { overflow-x: clip; }
/* No visible scrollbars anywhere on the page. */
html, .gpanel { scrollbar-width: none; }
html::-webkit-scrollbar, .gpanel::-webkit-scrollbar { display: none; }
body { margin: 0; background: var(--surface-2); color: var(--text-primary); font-family: var(--font-ui); font-size: 14px; line-height: var(--lh-2); -webkit-font-smoothing: antialiased; }
a { color: inherit; }
a.btn { text-decoration: none; }

/* Selected text is painted token by token (os/ui/selection.js): each piece in the next of five highlighter colours, and the
   first and last piece of the selection in lemon. The colours are solid and the ink is one dark colour in both themes, so
   letters stay clear on any ground: a chip's coloured text, a link and quiet text all read the same while selected. Fields,
   pictures and text drawn inside an SVG keep the plain selection, because no engine paints a highlight there.
   Two ways to paint. tok-N is a background behind each piece. band-N, in the engine the script has measured, is an underline
   one line tall, lifted from the baseline to the top of the line (half a line plus .35em, the fonts' ascent less descent,
   halved), so rows of text make even bands with no gap in loose body text. Where a heading is set tighter than its letters
   are tall (.605em is half that height), the band drops to rest on the line of the tails, so it never covers the tails of
   the line above. */
:root {
  --tok-1: #B8E4D2; --tok-2: #DDD5F9; --tok-3: #B8E7ED; --tok-4: #FAD3DC; --tok-5: #C2E0FF; --tok-edge: #FFEC80; --tok-ink: #1C2024;
}
::highlight(tok-1) { background-color: var(--tok-1); color: var(--tok-ink); }
::highlight(tok-2) { background-color: var(--tok-2); color: var(--tok-ink); }
::highlight(tok-3) { background-color: var(--tok-3); color: var(--tok-ink); }
::highlight(tok-4) { background-color: var(--tok-4); color: var(--tok-ink); }
::highlight(tok-5) { background-color: var(--tok-5); color: var(--tok-ink); }
::highlight(tok-edge) { background-color: var(--tok-edge); color: var(--tok-ink); }
::highlight(band-1), ::highlight(band-2), ::highlight(band-3), ::highlight(band-4), ::highlight(band-5), ::highlight(band-edge) {
  color: var(--tok-ink); text-decoration-line: underline; text-decoration-thickness: 1lh;
  text-underline-offset: calc(max(0px, .605em - .5lh) - .5lh - .35em); text-decoration-skip-ink: none;
}
::highlight(band-1) { text-decoration-color: var(--tok-1); }
::highlight(band-2) { text-decoration-color: var(--tok-2); }
::highlight(band-3) { text-decoration-color: var(--tok-3); }
::highlight(band-4) { text-decoration-color: var(--tok-4); }
::highlight(band-5) { text-decoration-color: var(--tok-5); }
::highlight(band-edge) { text-decoration-color: var(--tok-edge); }
:root[data-selection] ::selection { background-color: transparent; }
/* Safari's engine takes the ink of selected text from ::selection, never from the highlight under it, so the ink is set here
   as well. It also paints no highlight on text its layout wraps in a nameless block (text straight inside a flex or grid
   box, as in a chip). The script marks such an element with data-tok, and its selected text takes that one colour. The
   colour is a hair short of solid, because the engine dulls a fully solid ::selection ground. */
:root[data-selection="tokens"] :not(input, textarea, svg, svg *)::selection { color: var(--tok-ink); }
:root[data-selection] [data-tok]::selection { background-color: color-mix(in srgb, var(--tok-1) 99.6%, transparent); color: var(--tok-ink); }
:root[data-selection] [data-tok="2"]::selection { background-color: color-mix(in srgb, var(--tok-2) 99.6%, transparent); }
:root[data-selection] [data-tok="3"]::selection { background-color: color-mix(in srgb, var(--tok-3) 99.6%, transparent); }
:root[data-selection] [data-tok="4"]::selection { background-color: color-mix(in srgb, var(--tok-4) 99.6%, transparent); }
:root[data-selection] [data-tok="5"]::selection { background-color: color-mix(in srgb, var(--tok-5) 99.6%, transparent); }
:root[data-selection] [data-tok="edge"]::selection { background-color: color-mix(in srgb, var(--tok-edge) 99.6%, transparent); }
:root[data-selection] :is(input, textarea, img, video, canvas, svg *)::selection { background-color: var(--slate-a5); }

/* Page grain and the 3% light. The light shades everything away from it; it never brightens past the surface. */
body::after { content: ""; position: fixed; inset: 0; z-index: 50; pointer-events: none; background-image: var(--grain); background-size: 180px; opacity: .05; mix-blend-mode: multiply; }
.lightfield { position: fixed; inset: 0; z-index: 49; pointer-events: none;
  background: radial-gradient(1100px circle at var(--lx) var(--ly), transparent 0%, rgb(0 10 30 / .03) 100%); }

/* Frame */
.frame { position: relative; max-width: var(--frame); margin: 0 auto; box-sizing: border-box; }
.frame { padding-inline: var(--sp-5); }
.olds { display: flex; gap: var(--sp-4); }
/* No rules between sections: panels on the page surface carry the structure. */
.seam { position: relative; }
.spacer { height: var(--sp-8); }

.ph { position: relative; display: grid; place-items: center; box-sizing: border-box; border: 1px dashed var(--border); border-radius: var(--radius-card); color: var(--text-secondary);
  background: repeating-linear-gradient(135deg, transparent 0 8px, var(--slate-a3) 8px 9px), var(--surface-1); font-family: var(--font-mono); font-size: 11px; line-height: var(--lh-1); text-align: center; padding: var(--sp-3); min-width: 0; }
.ph span { background: var(--surface-1); padding: 2px var(--sp-2); border-radius: var(--radius); }
.dither { background-image: radial-gradient(var(--slate-a5) 1px, transparent 1.5px); background-size: 8px 8px; -webkit-mask-image: var(--fade-x); mask-image: var(--fade-x); }

/* Lit surfaces: the shadow falls away from the light and a 1px rim catches it. */
.lit { position: relative; --sx: 0px; --sy: 6px; --ra: 180deg;
  box-shadow: var(--sx) var(--sy) 24px -14px rgb(0 10 30 / .18), 0 1px 2px var(--slate-a3); }
.lit::after { content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px; pointer-events: none;
  background: linear-gradient(var(--ra), rgb(255 255 255 / .95), rgb(255 255 255 / 0) 45%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0); }

/* Orbs: grainy gradient spheres, lit from the same light (--hx/--hy). */
.orb { --c: var(--chart-1); --c2: var(--chart-2); --hx: 35%; --hy: 30%; --blur: 7px; position: relative; display: inline-block; flex: none; width: 40px; height: 40px; border-radius: 50%; overflow: hidden; isolation: isolate; background: var(--c); box-shadow: inset 0 0 0 1px rgb(0 0 0 / .05); }
.orb::before { content: ""; position: absolute; inset: -25%; filter: blur(var(--blur));
  background:
    radial-gradient(circle at calc(var(--hx) * .7 + 15%) calc(var(--hy) * .7 + 15%), color-mix(in oklab, var(--c) 30%, white) 0%, transparent 32%),
    conic-gradient(from 150deg at 58% 58%, var(--c), var(--c2), color-mix(in oklab, var(--c2) 50%, white) 38%, var(--c) 55%, color-mix(in oklab, var(--c) 70%, var(--c2)) 80%, var(--c)); }
.orb::after { content: ""; position: absolute; inset: 0; border-radius: 50%; background-image: var(--grain), radial-gradient(circle at 50% 45%, transparent 58%, rgb(0 10 30 / .22)); background-size: 70px, 100%; mix-blend-mode: overlay; }
.orb.sm { width: 16px; height: 16px; vertical-align: -2px; --blur: 3px; }
.orb.lg { width: 64px; height: 64px; --blur: 11px; }

/* Top bar */
/* The top bar is solid, so an earlier turn never shows through it. */
.top { position: sticky; top: 0; z-index: 30; background: var(--surface-2); }
.top .seam-b { display: none; }
.top .in { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; height: 64px; padding-inline: var(--sp-5); max-width: var(--frame); margin: 0 auto; box-sizing: border-box; }
.top .mark { display: flex; align-items: center; height: 40px; }
[data-wordmark] svg text { letter-spacing: 0; word-spacing: 0; }
.top .mark svg { height: 32px; width: auto; display: block; }
.top nav.mid { display: flex; gap: var(--sp-5); font-size: 13px; }
.top nav.mid a { text-decoration: none; color: var(--text-primary); }
.top nav.mid a:hover { color: var(--leaf-text); }
.top .end { display: flex; gap: var(--sp-2); justify-content: flex-end; align-items: center; }

/* Hero: intro, then the ask bar. Chatting swaps the intro for the conversation, in the same place. */
.hero { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 400px; padding: 80px var(--sp-5) var(--sp-7); box-sizing: border-box; text-align: center; }
.intro h1 { font-family: var(--font-brand); font-weight: 400; font-size: 48px; line-height: 56px; letter-spacing: -0.01em; margin: 0; }
.intro .sub { margin: var(--sp-4) auto 0; font-size: 16px; line-height: 28px; max-width: 34em; }
/* Reveals arrive under a soft edge that sweeps down the block, and the intro leaves the same way. No opacity fade. fasra.js drops the class once it ends, so the mask never clips a shadow. */
.reveal, .intro.out, .gpanel.leaving, .wipe-out { --rb: calc(var(--fx-reveal-blur) * 1px);
  -webkit-mask-image: linear-gradient(to bottom, #000 calc(50% - var(--rb)), transparent calc(50% + var(--rb))); mask-image: linear-gradient(to bottom, #000 calc(50% - var(--rb)), transparent calc(50% + var(--rb)));
  -webkit-mask-size: 100% calc(200% + 2 * var(--rb)); mask-size: 100% calc(200% + 2 * var(--rb)); -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
  -webkit-mask-position: 0 0; mask-position: 0 0; }
.reveal { animation: soft-in calc(var(--fx-reveal-ms) * 1ms) var(--ease-out) both; }
.intro.out, .gpanel.leaving, .wipe-out { animation: soft-out var(--mo-quick) var(--ease-out) forwards; }
.gpanel.leaving, .wipe-out { pointer-events: none; }
.wipe-out { position: fixed; z-index: 1; margin: 0; }
.wipe-out.slow { animation-duration: var(--mo-move); }
.top .wipe-out { z-index: 2; }
.wipe-out.in-card { position: absolute; left: 0; right: 0; z-index: 0; }
.wipe-out .w, .wipe-out * { animation: none !important; clip-path: none !important; }
@keyframes soft-in { from { -webkit-mask-position: 0 100%; mask-position: 0 100%; } to { -webkit-mask-position: 0 0; mask-position: 0 0; } }
@keyframes soft-out { from { -webkit-mask-position: 0 0; mask-position: 0 0; } to { -webkit-mask-position: 0 100%; mask-position: 0 100%; } }

.ask-slot { width: min(520px, 100%); margin-top: var(--sp-6); }
.ask { display: flex; align-items: center; gap: var(--sp-2); height: 52px; padding: 0 6px 0 var(--sp-4); box-sizing: border-box; background: var(--surface-1); border-radius: 999px; border: 1px solid var(--border-subtle); }
.ask input { flex: 1; align-self: stretch; min-width: 0; border: 0; background: transparent; font: inherit; font-size: 15px; line-height: var(--lh-3); color: var(--text-primary); outline: none; }
.ask { position: relative; }
.ask .roll { position: absolute; left: var(--sp-4); right: 56px; top: 50%; height: var(--lh-3); margin-top: calc(var(--lh-3) / -2); overflow: hidden; pointer-events: none; text-align: left; color: var(--text-placeholder); font-size: 15px; line-height: var(--lh-3); }
.ask .roll span { position: absolute; inset: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ask .roll span.in { animation: roll-in var(--mo-move) var(--ease-out) both; }
.ask .roll span.out { animation: roll-out var(--mo-move) var(--ease-out) forwards; }
@keyframes roll-in { from { transform: translateY(100%); } }
@keyframes roll-out { to { transform: translateY(-100%); } }
.ask.typed .roll, .ask.sending .roll { visibility: hidden; }
.ask .go { width: var(--h-4); height: var(--h-4); padding: 0; display: grid; place-items: center; border-radius: 50%; flex: none; }
.ask .go svg { width: 16px; height: 16px; }
.suggest { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--sp-2); margin-top: var(--sp-3); }
.suggest button { font: inherit; font-size: 12px; line-height: var(--lh-1); height: var(--h-2); padding-inline: var(--sp-3); border-radius: 999px; border: 1px solid var(--border-subtle); background: var(--surface-1); color: var(--text-primary); cursor: pointer; transition: border-color var(--mo-quick) var(--ease-out); }
.suggest button:hover { border-color: var(--border-hover); }

/* Sending: the typed words lift out of the bar and the button gives a little. */
.ask .ghost { position: absolute; left: var(--sp-4); right: 56px; top: 50%; margin-top: calc(var(--lh-3) / -2); font-size: 15px; line-height: var(--lh-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-align: left; pointer-events: none; color: var(--text-primary);
  animation: lift-out calc(var(--fx-send-ms) * 1ms) var(--ease-out) forwards; }
@keyframes lift-out { to { opacity: 0; transform: translateY(-10px); filter: blur(3px); } }
.ask .go.press { animation: press calc(var(--fx-send-ms) * 1ms) var(--ease-out); }
@keyframes press { 40% { transform: scale(.92); } }
/* The orb that carries a question from the send button into the map. */

/* Conversation */
.convo { width: min(640px, 100%); text-align: left; }
.convo[hidden] { display: none; }
.turn { margin-top: var(--sp-5); }
.turn .q { display: flex; justify-content: flex-end; }
.turn .q span { max-width: 80%; background: var(--surface-1); border: 1px solid var(--border-subtle); border-radius: 14px 14px 4px 14px; padding: var(--sp-2) var(--sp-3); font-size: 14px; }
.turn .a { margin-top: var(--sp-4); display: flex; gap: var(--sp-3); align-items: flex-start; }
.turn .a .orb { width: 24px; height: 24px; margin-top: 2px; }
.turn .a p { margin: 0; font-size: 15px; line-height: var(--lh-3); }
/* Each word of a reply fades in, staggered so the fade runs along the line (the owner's call, 2026-11-20: no wipe here). */
.turn .w { display: inline-block; opacity: 0; animation: word-in calc(var(--fx-reveal-ms) * .8ms) var(--ease-out) forwards; }
.wipe-out .w { opacity: 1; }
@keyframes word-in { to { opacity: 1; } }
/* Steps the agents narrate while they build a map. */
.steps { list-style: none; margin: var(--sp-3) 0 0 36px; padding: 0; display: grid; gap: var(--sp-1); font-size: 13px; line-height: var(--lh-2); }
.steps li { display: grid; grid-template-columns: 16px minmax(0, 1fr) auto; gap: var(--sp-2); align-items: center; }
.steps li span:nth-child(2) { color: var(--text-secondary); transition: color var(--mo-quick) var(--ease-out); }
.steps li.done span:nth-child(2) { color: var(--text-primary); }
.steps .num { color: var(--text-secondary); font-variant-numeric: tabular-nums; }
.turn .a + p, .turn .more { margin: var(--sp-3) 0 0 36px; font-size: 15px; line-height: var(--lh-3); }
.turn .cta { margin: var(--sp-4) 0 0 36px; }
.turn .follow { display: flex; flex-wrap: wrap; gap: var(--sp-2); margin: var(--sp-4) 0 0 36px; }
.turn .follow button { font: inherit; font-size: 12px; height: var(--h-2); padding-inline: var(--sp-3); border-radius: 999px; border: 1px solid var(--border-subtle); background: var(--surface-1); cursor: pointer; }

/* Artifacts in the chat */
.art { margin: var(--sp-4) 0 0 36px; background: var(--surface-1); border: 1px solid var(--border-subtle); border-radius: 12px; overflow: hidden; }
.art-h { display: flex; align-items: center; gap: var(--sp-3); padding: var(--sp-3) var(--sp-4); border-bottom: 1px solid var(--border-subtle); }
.art-h b { font-weight: 500; font-size: 14px; }
.art-h span { color: var(--text-secondary); font-size: 12px; }
.art-h .x { margin-left: auto; }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-bottom: 1px solid var(--border-subtle); }
.stats > div { padding: var(--sp-3) var(--sp-4); min-width: 0; }
.stats > div + div { border-left: 1px solid var(--border-subtle); }
.stats .k { font-size: 11px; line-height: var(--lh-1); color: var(--text-secondary); }
.stats .v { font-size: 20px; line-height: var(--lh-4); font-weight: 500; font-variant-numeric: tabular-nums; }
.stats .n { font-size: 11px; line-height: var(--lh-1); color: var(--text-secondary); }
.rows { list-style: none; margin: 0; padding: var(--sp-1) 0; }
.rows .lbl { display: inline-flex; align-items: center; gap: var(--sp-2); white-space: nowrap; }
.rows li { display: grid; grid-template-columns: 112px 64px minmax(0, 1fr); gap: var(--sp-3); align-items: center; padding: 6px var(--sp-4); font-size: 13px; }
.rows .num { text-align: right; font-variant-numeric: tabular-nums; }
.rows .ex { color: var(--text-secondary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bars { padding: var(--sp-3) var(--sp-4) var(--sp-4); display: grid; gap: var(--sp-2); }
.bars .row { display: grid; grid-template-columns: 148px minmax(0, 1fr) 40px; gap: var(--sp-3); align-items: center; font-size: 13px; }
.bars .track { height: 8px; border-radius: 4px; background: var(--surface-2); overflow: hidden; }
.bars .fill { height: 100%; border-radius: 4px; background: var(--c); transform-origin: left; animation: grow var(--mo-move) var(--ease-out) both; }
@keyframes grow { from { transform: scaleX(0); } }
.bars .num { text-align: right; font-variant-numeric: tabular-nums; color: var(--text-secondary); }
.bars h5 { margin: var(--sp-2) 0 0; font-size: 11px; line-height: var(--lh-1); font-weight: 500; color: var(--text-secondary); }
.tasks { list-style: none; margin: 0; padding: var(--sp-1) 0; }
.tasks li { display: grid; grid-template-columns: 16px minmax(0, 1fr) auto; gap: var(--sp-3); align-items: start; padding: var(--sp-3) var(--sp-4); }
.tasks li + li { border-top: 1px solid var(--border-subtle); }
.tasks .orb { margin-top: 2px; }
.tasks b { font-weight: 500; font-size: 13px; display: block; }
.tasks small { font-size: 12px; line-height: var(--lh-1); color: var(--text-secondary); }
.state { font-size: 11px; line-height: var(--lh-1); padding: 2px var(--sp-2); border-radius: 999px; white-space: nowrap; background: color-mix(in oklab, var(--c) 14%, var(--surface-1)); box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--c) 30%, transparent); }
.art-f { display: flex; justify-content: space-between; align-items: center; gap: var(--sp-3); padding: var(--sp-3) var(--sp-4); border-top: 1px solid var(--border-subtle); font-size: 12px; color: var(--text-secondary); }

/* Map: one study as a galaxy, with a panel for whatever is open */
.mapsec { padding-bottom: var(--sp-2); }
.maphead { display: flex; justify-content: space-between; align-items: flex-end; gap: var(--sp-5); padding: var(--sp-7) var(--sp-1) var(--sp-5); }
.maphead h2 { margin: var(--sp-3) 0 0; font-size: 24px; line-height: 32px; font-weight: 500; letter-spacing: -0.015em; }
.mapnote { margin: 0; font-size: 12px; line-height: var(--lh-1); color: var(--text-secondary); text-align: right; max-width: 22em; }
.graph { --edge: var(--border); position: relative; height: 600px; overflow: hidden; touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.graph.gl { cursor: grab; }
.graph.grab { cursor: grabbing; }
.graph canvas.gl3d { position: absolute; left: 0; top: 0; pointer-events: none;
  -webkit-mask-image: linear-gradient(to right, transparent, #000 5%, #000 95%, transparent), linear-gradient(transparent, #000 5%, #000 95%, transparent); -webkit-mask-composite: source-in;
  mask-image: linear-gradient(to right, transparent, #000 5%, #000 95%, transparent), linear-gradient(transparent, #000 5%, #000 95%, transparent); mask-composite: intersect; }
/* With a card under the map (g-card, set by the renderer) the map is drawn over the card and cut away inside it, so a
   node lifted into the card's head orb sits on top while its links go under. Names stay over the map. */
.graph.g-card canvas.gl3d { z-index: 3; }
.graph.g-card .gl-label { z-index: 4; }
.graph.lifting .gpanel .gp-h .orb { visibility: hidden; }
.gl-label { position: absolute; left: 0; top: 0; display: flex; flex-direction: column; align-items: flex-start; padding: 2px var(--sp-1); background: none; border: 0; font: inherit; color: var(--text-primary); text-align: left; white-space: nowrap; cursor: pointer; will-change: transform; }
.gl-label { text-shadow: 0 0 1px var(--surface-2), 0 0 2px var(--surface-2), 0 0 4px var(--surface-2), 0 0 8px var(--surface-2); }
.gl-label b { font-size: 13px; line-height: var(--lh-1); font-weight: 500; transition: color var(--mo-quick) var(--ease-out); }
.gl-label span { font-size: 11px; line-height: var(--lh-1); color: var(--text-secondary); }
.graph.narrow .gl-label { align-items: center; text-align: center; }
.graph.flat { height: auto; padding: var(--sp-5); cursor: default; }
.graph.flat ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: var(--sp-3) var(--sp-5); }
.graph.flat li { display: flex; align-items: center; gap: var(--sp-2); font-size: 13px; }
.graph.flat li .num { margin-left: auto; color: var(--text-secondary); font-variant-numeric: tabular-nums; }
.graph.point { cursor: pointer; }
/* On touch every map label is a 40px tall target without its text moving. */
@media (pointer: coarse) { .hero .gl-label::before { content: ''; position: absolute; left: 0; right: 0; top: 50%; height: max(100%, 40px); transform: translateY(-50%); } }
.gl-label.bank b { font-size: 14px; font-weight: 500; }
.gl-label.dim b { color: var(--text-secondary); }
/* In the hero the answer beside the map already names the region, so only the dimming shows. */
.hero .gl-region { display: none; }
.graph.narrow.open .gl-label.dim { visibility: hidden; }
/* A name on hover reads like the labels already on the map, above the canvas, so it is never seen through an orb. */
.gl-tip { position: absolute; z-index: 4; left: 0; top: 0; max-width: 240px; padding: 2px var(--sp-1); font-size: 13px; font-weight: 500; line-height: var(--lh-1); color: var(--text-primary); text-shadow: 0 0 1px var(--surface-2), 0 0 2px var(--surface-2), 0 0 4px var(--surface-2), 0 0 8px var(--surface-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; pointer-events: none; will-change: transform; }
.gpanel { position: absolute; z-index: 2; top: var(--sp-3); right: var(--sp-3); max-height: calc(100% - 2 * var(--sp-3)); width: 320px; box-sizing: border-box; overflow: auto; overscroll-behavior: contain; border-radius: 10px; background: var(--surface-1); border: 1px solid var(--border-subtle); box-shadow: var(--shadow-overlay); cursor: default; text-align: left; user-select: text; -webkit-user-select: text; font-size: 13px; line-height: 20px; }
.gp-in { padding: var(--sp-4); }
.gp-h { display: flex; align-items: center; gap: var(--sp-2); color: var(--text-secondary); font-size: 12px; line-height: var(--lh-1); }
/* The card's head, with its close button, stays put while a long card scrolls. */
.gpanel .gp-h { position: sticky; top: calc(-1 * var(--sp-2)); z-index: 1; margin-top: calc(-1 * var(--sp-4)); padding-top: var(--sp-4); background: var(--surface-1); }
.gp-x { margin-left: auto; margin-right: calc(-1 * var(--sp-2)); }
.gpanel h3 { margin: var(--sp-3) 0 0; font-size: 18px; line-height: 24px; font-weight: 500; letter-spacing: -0.01em; overflow-wrap: anywhere; }
.gp-path { margin-top: var(--sp-1); font-family: var(--font-mono); font-size: 11px; line-height: 16px; color: var(--text-secondary); overflow-wrap: anywhere; }
.gp-big { margin-top: var(--sp-2); font-size: 32px; line-height: 40px; font-weight: 500; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.gpanel .stars { display: block; margin-top: var(--sp-1); letter-spacing: 2px; color: var(--chart-4); }
.gpanel .stars .off { opacity: .25; }
.gp-text { margin: var(--sp-3) 0 0; color: var(--text-primary); }
.gp-quote { margin: var(--sp-3) 0 0; padding-left: var(--sp-3); border-left: 2px solid var(--border); color: var(--text-primary); }
.gpanel dl { margin: var(--sp-4) 0 0; }
.gpanel dl div { display: flex; justify-content: space-between; gap: var(--sp-3); padding: var(--sp-2) 0; border-top: 1px solid var(--border-subtle); }
.gpanel dt { color: var(--text-secondary); }
.gpanel dd { margin: 0; text-align: right; }
.gp-l { margin-top: var(--sp-4); }
.gp-l h4 { margin: 0 0 var(--sp-2); font-size: 12px; line-height: var(--lh-1); font-weight: 500; color: var(--text-secondary); }
.gp-l > div { display: flex; flex-wrap: wrap; gap: var(--sp-1); }
.gp-chip { display: inline-flex; align-items: center; gap: 6px; max-width: 100%; min-height: var(--h-1); padding: 2px var(--sp-2); text-align: left; line-height: 16px; border-radius: 999px; border: 1px solid var(--border-subtle); background: var(--surface-2); font: inherit; font-size: 12px; color: var(--text-primary); cursor: pointer; }
.gp-chip span { overflow-wrap: anywhere; }
.gp-chip:hover { border-color: var(--border); }
/* A long linked record is a row, not a chip: two lines at most, a hairline between rows. */
.gp-l > .gp-rows { display: block; margin-top: var(--sp-2); }
.gp-l > div + .gp-rows { margin-top: var(--sp-3); }
.gp-row { display: flex; align-items: flex-start; gap: var(--sp-2); width: 100%; padding: var(--sp-2) 0; border: 0; border-top: 1px solid var(--border-subtle); background: none; font: inherit; font-size: 12px; line-height: 16px; color: var(--text-primary); text-align: left; cursor: pointer; }
.gp-row:first-child { border-top: 0; padding-top: 0; }
.gp-row .orb { flex: none; margin-top: 4px; }
.gp-row span { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.gp-row:hover span { color: var(--text-secondary); }
/* A card longer than its box scrolls, and its foot softens under a mask until the end is reached. */
.gpanel::after { content: ''; position: sticky; bottom: 0; z-index: 1; display: block; height: 32px; margin-top: -32px; background: linear-gradient(to bottom, color-mix(in oklab, var(--surface-1) 0%, transparent), var(--surface-1)); pointer-events: none; visibility: hidden; }
.gpanel.more::after { visibility: visible; }
.orb.xs { width: 8px; height: 8px; --blur: 2px; }
.graph.flat .gpanel { position: static; width: auto; margin-top: var(--sp-4); }
.graph.flat li button { display: flex; align-items: center; gap: var(--sp-2); width: 100%; padding: 0; border: 0; background: none; font: inherit; font-size: 13px; color: var(--text-primary); cursor: pointer; text-align: left; }
.graph.flat li button .num { margin-left: auto; color: var(--text-secondary); font-variant-numeric: tabular-nums; }

/* The layout comes from --fx-layout (split by default, ?layout= overrides it): side by side, the map as hero, or the map below.
   In the first two the galaxy is the hero's background, full bleed, framed in a region of it. On wider screens it is sticky:
   a long conversation grows the hero downward, the galaxy stays in view beside it and the bar stays at the bottom. */
.big .hero { --hero-h: calc(100svh - 64px); --hero-pt: var(--sp-7); --hero-pb: var(--sp-7); --hero-pl: var(--sp-5); --hero-pr: var(--sp-5); margin-inline: calc(50% - 50vw); min-height: var(--hero-h); padding: var(--hero-pt) var(--hero-pr) var(--hero-pb) var(--hero-pl); justify-content: flex-end; }
.pin { display: contents; }
.big .hero .graph { position: absolute; left: 0; right: 0; top: 0; height: var(--hero-h); }
.big .hero > :not(.pin) { position: relative; z-index: 1; }
@media (min-width: 941px) {
  .big .hero { justify-content: flex-start; padding-top: 0; }
  .big .hero > .pin { display: block; position: absolute; z-index: 0; left: 0; right: 0; top: 0; bottom: calc(100vh + var(--hero-pb) - 64px - var(--hero-h)); pointer-events: none; }
  .big .hero .graph { position: sticky; top: 64px; pointer-events: auto; }
  .big .hero > .pin ~ .intro { margin-top: auto; }
  body.big .hero > .ask-slot:not(.graph) { position: sticky; bottom: 0; margin-top: 0; padding: var(--sp-6) 0 var(--sp-5); background: linear-gradient(to bottom, transparent, var(--surface-2) var(--sp-6)); }
  body.big.chatting .hero > .ask-slot:not(.graph) { margin-top: auto; }
  body[data-layout="split"]:not(.chatting) .hero > .ask-slot:not(.graph) { margin-bottom: auto; }
}
/* At its end the hero holds still for a short stretch of scroll before the next section comes in. */
@media (min-width: 941px) and (prefers-reduced-motion: no-preference) {
  .big .hold::after { content: ""; display: block; height: min(8vh, 64px); }
  .big .hold > .hero { position: sticky; top: min(64px, calc(100vh - var(--hero-tall, 200vh))); }
}
.big .intro { pointer-events: none; }
.big .mapsec { display: none; }
[data-layout="hero"] .hero .graph { --g-y0: -.113; --g-y1: .627; --map-pitch: 22.4; --map-margin: 31; }
[data-layout="hero"] .intro h1 { font-size: 56px; line-height: 64px; }
/* Side by side: the galaxy keeps one pane on the right from idle to done, so starting a chat never reframes it.
   A clicked record opens as a strip under the galaxy, which lifts to make room, so the left column only ever holds the chat. */
[data-layout="split"] .hero { --hero-pl: max(var(--sp-5), calc(50vw - var(--frame) / 2 + var(--sp-5))); align-items: flex-start; text-align: left; --hero-pb: 0px; }
[data-layout="split"] .hero .graph { --g-x0: .44; --g-x1: .97; --g-y0: .06; --g-y1: .98; --g-open-x0: .44; --g-panel: below; --map-pitch: 22; --map-margin: 81; }
[data-layout="split"] .convo { width: min(440px, 100%); }
[data-layout="split"] .intro { max-width: 400px; }
[data-layout="split"] .intro h1 { font-size: 56px; line-height: 64px; }
[data-layout="split"] .intro .sub { margin-left: 0; }
[data-layout="split"] .ask-slot { width: min(440px, 100%); }
/* The hero fills the first screen at every size. On a wide screen the galaxy is as wide as its pane allows, so it takes a
   steeper look to fill the height too. */
@media (min-width: 1100px) {
  [data-layout="split"] .hero .graph { --g-x0: .42; --g-open-x0: .42; --g-y0: .02; --g-y1: .98; --map-pitch: 36; --map-margin: 24; --gp-max: 300px; }
}
@media (min-width: 941px) {
  [data-layout="split"] .graph:not(.narrow) .gpanel { top: auto; bottom: var(--sp-5); left: max(calc(var(--g-x0) * 100%), calc(var(--hero-pl) + 440px + var(--sp-6))); right: max(var(--sp-5), calc(50vw - var(--frame) / 2 + var(--sp-5))); width: auto; max-height: var(--gp-max, 40%); box-shadow: none; }
  [data-layout="split"] .graph:not(.narrow) .gp-in { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); grid-template-rows: auto auto auto 1fr; column-gap: var(--sp-6); align-items: start; }
  [data-layout="split"] .graph:not(.narrow) .gp-h { grid-column: 1 / -1; }
  /* The record and its numbers on the left, what it links to on the right, so neither column runs half empty. */
  [data-layout="split"] .graph:not(.narrow) .gp-a { grid-column: 1; grid-row: 2; }
  [data-layout="split"] .graph:not(.narrow) .gp-b { grid-column: 1; grid-row: 3; }
  [data-layout="split"] .graph:not(.narrow) .gp-c { grid-column: 2 / 3; grid-row: 2 / span 3; margin-top: var(--sp-3); }
  [data-layout="split"] .graph:not(.narrow) .gp-x { position: absolute; top: var(--sp-3); right: var(--sp-3); margin: 0; }
@media (min-width: 941px) {
  /* Not the record on its way out: that one lies over the card, so it adds nothing to the height. */
  [data-layout="split"] .graph:not(.narrow) .gp-in:not(.wipe-out) { position: relative; }
  /* The linked list never sets the card's height: the record on the left does, and the list scrolls in its own column,
     its last row fading only while there is more below it. */
  [data-layout="split"] .graph:not(.narrow) .gp-c { position: absolute; inset: 0; overflow: auto; overscroll-behavior: contain; scrollbar-width: none; }
  [data-layout="split"] .graph:not(.narrow) .gp-c.over { -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - var(--sp-6)), transparent); mask-image: linear-gradient(to bottom, #000 calc(100% - var(--sp-6)), transparent); }
}
}
/* Under the bar: the note about the data while idle, New chat once a chat starts. The line keeps its height either way. */
.under { display: flex; justify-content: center; align-items: center; min-height: var(--h-2); margin-top: var(--sp-2); padding-inline: var(--sp-4); }
.heronote { margin: 0; font-size: 12px; line-height: var(--lh-1); color: var(--text-secondary); }
/* New chat sits in the top bar while a chat runs: clear of the map and the answer, and in reach on a phone.
   It keeps the bar's button size and takes a 40px tall tap area from an invisible layer around it. */
.chatting .under .heronote { display: none; }
.top #reset { display: none; position: relative; }
.top #reset::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 40px; transform: translateY(-50%); }
.chatting .top #reset { display: inline-flex; }
@media (min-width: 941px) { [data-layout="split"] .under { justify-content: flex-start; } }

/* Section heads */
.eyebrow { display: inline-flex; align-items: center; gap: 6px; height: var(--h-1); padding-inline: var(--sp-2); border: 1px solid var(--border-subtle); border-radius: 999px; background: var(--surface-1); font-size: 12px; line-height: var(--lh-1); color: var(--text-primary); white-space: nowrap; }
.eyebrow i { width: 8px; height: 8px; border-radius: 50%; background: var(--leaf); }
.head { text-align: center; padding: 72px var(--sp-5) var(--sp-7); }
.head h2 { font-weight: 500; font-size: 32px; line-height: 40px; letter-spacing: -0.02em; margin: 0; }
.head p { margin: var(--sp-3) auto 0; max-width: 32em; font-size: 15px; line-height: var(--lh-3); }

/* Bento */
.bento { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--sp-2); padding: var(--sp-2); }
.card { background: var(--surface-1); border: 1px solid var(--border-subtle); border-radius: 12px; padding: var(--sp-5); min-width: 0; overflow: hidden; display: flex; flex-direction: column; box-sizing: border-box; }
.card h3 { margin: 0; font-size: 15px; line-height: var(--lh-3); font-weight: 500; display: flex; align-items: center; gap: var(--sp-2); }
.card p { margin: var(--sp-2) 0 0; font-size: 14px; line-height: var(--lh-2); max-width: 30em; color: var(--text-secondary); }
.card .ph { margin-top: var(--sp-4); flex: 1; min-height: 200px; -webkit-mask-image: linear-gradient(to bottom, #000 60%, transparent); mask-image: linear-gradient(to bottom, #000 60%, transparent); }
.card .ph.bleed { margin-right: calc(-1 * var(--sp-5)); margin-bottom: calc(-1 * var(--sp-5)); border-bottom-right-radius: 0; -webkit-mask-image: none; mask-image: none; }
.card.soon { background: color-mix(in oklab, var(--surface-1) 50%, transparent); }
.tag { font-size: 11px; line-height: var(--lh-1); font-weight: 500; padding: 1px var(--sp-2); border-radius: 999px; color: var(--text-secondary); border: 1px solid var(--border); }
.tag.live { color: var(--accent-fg); background: var(--accent-fill); border-color: transparent; }
.c12 { grid-column: span 12; } .c7 { grid-column: span 7; } .c5 { grid-column: span 5; } .c4 { grid-column: span 4; }
.card.split { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--sp-5); padding-right: 0; padding-bottom: 0; }
.card.split .txt { padding-bottom: var(--sp-5); }
.card.split .ph { margin-top: 0; min-height: 280px; border-right: 0; border-bottom: 0; border-radius: var(--radius-card) 0 0 0; -webkit-mask-image: none; mask-image: none; }
.card .more { margin-top: var(--sp-4); align-self: flex-start; }

/* Duo */
.duo { display: grid; grid-template-columns: minmax(0, 1fr) var(--sp-2) minmax(0, 1fr); }
.duo .vr { background: none; }
.duo .r { background: var(--surface-1); border: 1px solid var(--border-subtle); border-radius: 12px; }
.duo .l { padding: 80px var(--sp-6); display: flex; flex-direction: column; justify-content: flex-end; align-items: flex-start; }
.duo .l h2 { font-weight: 500; font-size: 32px; line-height: 40px; letter-spacing: -0.02em; margin: 0; }
.duo .l p { margin: var(--sp-3) 0 0; font-size: 15px; line-height: var(--lh-3); max-width: 26em; }
.duo .l .btn { margin-top: var(--sp-5); }
.duo .r { position: relative; padding: var(--sp-7) var(--sp-2) 0 var(--sp-6); overflow: hidden; }
.duo .r .dither { position: absolute; inset: 0; }
.duo .r .ph { height: 340px; border-style: solid; border-right: 0; border-bottom: 0; border-radius: var(--radius-card) 0 0 0; }

/* Footer */
footer .in { display: grid; grid-template-columns: minmax(0, 2fr) repeat(3, minmax(0, 1fr)); gap: var(--sp-6); padding: var(--sp-7) 0; }
footer .mark svg { height: 28px; width: auto; display: block; }
footer .mean { margin: var(--sp-3) 0 0; font-size: 13px; color: var(--text-secondary); }
footer h4 { margin: 0 0 var(--sp-3); font-size: 12px; line-height: var(--lh-1); font-weight: 500; color: var(--text-secondary); }
footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-1); font-size: 13px; }
footer ul a { display: inline-flex; align-items: center; min-height: var(--h-1); }
footer ul a, footer .base a { text-decoration: none; }
footer ul a:hover, footer .base a:hover { color: var(--leaf-text); }
footer .base { display: flex; justify-content: space-between; padding: var(--sp-4) 0; font-size: 12px; color: var(--text-secondary); }

@media (max-width: 900px) {
  .top nav.mid { display: none; }
  .top .in { grid-template-columns: 1fr auto; }
  .c7, .c5, .c4 { grid-column: span 12; }
  .card.split { grid-template-columns: minmax(0, 1fr); padding-right: var(--sp-5); }
  .card.split .txt { padding-bottom: 0; }
  .card.split .ph { min-height: 200px; margin-right: calc(-1 * var(--sp-5)); }
  .duo { grid-template-columns: minmax(0, 1fr); }
  .duo .vr { display: none; }
  .duo .l { padding: var(--sp-7) var(--sp-5) var(--sp-5); }
  footer .in { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); padding-inline: 0; }
  footer .in > :first-child { grid-column: 1 / -1; }
  footer .base { padding-inline: var(--sp-5); }
}
@media (max-width: 940px) {
  .frame { padding-inline: 0; margin-inline: max(16px, env(safe-area-inset-left, 0px)) max(16px, env(safe-area-inset-right, 0px)); }
  .top .in { padding-inline: max(16px, env(safe-area-inset-left, 0px)) max(16px, env(safe-area-inset-right, 0px)); }
  .top .end .hide-sm { display: none; }
  .hero { min-height: 0; padding: var(--sp-8) var(--sp-4) var(--sp-7); }
  .intro h1 { font-size: 40px; line-height: 48px; }
  .intro .sub { font-size: 15px; line-height: 28px; }
  .maphead { flex-direction: column; align-items: flex-start; padding-inline: var(--sp-4); }
  .mapnote { text-align: left; }
  .graph { height: 600px; }
  .big .hero, [data-layout="split"] .hero { --hero-h: calc(100svh - 64px); padding-bottom: var(--sp-6); }
  /* The galaxy eases between the full hero and the strip a chat shrinks it to, from wherever it is. */
  .big .hero .graph { transition: height var(--mo-move) var(--ease-in-out); }
  .big .hero { --hero-pt: var(--sp-8); --hero-pl: var(--sp-4); --hero-pr: var(--sp-4); }
  /* On a phone a chat shrinks the galaxy to a live strip under the top bar and the answer gets the screen, with the bar pinned
     to the bottom. A tapped record opens as a sheet that stops above the bar and scrolls inside itself. */
  /* In a chat the hero fills the screen under the top bar, so the bar sits at the bottom from the first frame and never jumps when the answer grows. */
  .big.chatting .hero, [data-layout].big.chatting .hero { justify-content: flex-start; padding-top: 0; padding-bottom: 0; min-height: calc(100svh - 64px); }
  .big.chatting .hero .graph { position: sticky; top: 64px; z-index: 2; flex: none; align-self: stretch; height: var(--strip-h); margin: 0 calc(-1 * var(--hero-pr)) 0 calc(-1 * var(--hero-pl)); background: var(--surface-2); box-shadow: 0 var(--sp-4) var(--sp-4) var(--surface-2); --g-y0: .02; --g-y1: .98; --map-margin: 8; }
  .big .hero { --strip-h: clamp(96px, 22svh, 200px); }
  .big.chatting .hero .graph .gpanel { position: fixed; z-index: 40; top: auto; width: auto; left: var(--sp-4); right: var(--sp-4); bottom: calc(var(--ask-h, 136px) + var(--sp-2)); max-height: max(160px, calc(100svh - var(--ask-h, 136px) - 64px - var(--strip-h) - var(--sp-4))); }
  body.big.chatting .hero > .ask-slot:not(.graph) { position: sticky; bottom: 0; margin-top: auto; padding: var(--sp-5) 0 var(--sp-4); background: linear-gradient(to bottom, transparent, var(--surface-2) var(--sp-5)); }
  [data-layout] .hero .graph { --g-x0: 0; --g-x1: 1; --g-y0: .012; --g-y1: .612; --map-pitch: 50; --map-margin: 23; }
  [data-layout="split"] .hero { align-items: center; text-align: center; padding-left: var(--sp-4); padding-bottom: var(--sp-6); }
  [data-layout="hero"] .intro h1, [data-layout="split"] .intro h1 { font-size: 40px; line-height: 48px; }
  [data-layout="split"] .intro .sub { margin-left: auto; }
  .graph.narrow .gpanel { top: auto; left: var(--sp-4); right: var(--sp-4); bottom: var(--sp-4); width: auto; max-height: 52%; z-index: 40; }
  .top .mark svg { height: 28px; }
  .top .in { column-gap: var(--sp-3); }
  .head { padding: var(--sp-7) var(--sp-4) var(--sp-5); }
  .head h2, .duo .l h2 { font-size: 28px; line-height: 36px; }
  .card { padding: var(--sp-4); }
  .card .ph { min-height: 140px; }
  .card .ph.bleed { margin-right: calc(-1 * var(--sp-4)); margin-bottom: calc(-1 * var(--sp-4)); }
  .card.split { padding-right: var(--sp-4); }
  .card.split .ph { margin-right: calc(-1 * var(--sp-4)); }
  .duo .r .ph { height: 240px; }
  .art { margin-left: 0; }
  .turn .follow { margin-left: 0; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stats > div:nth-child(3) { border-left: 0; }
  .stats > div:nth-child(n+3) { border-top: 1px solid var(--border-subtle); }
  .rows li { grid-template-columns: minmax(0, 1fr) auto; }
  .rows .ex { display: none; }
  .bars .row { grid-template-columns: 112px minmax(0, 1fr) 36px; }
}
/* Touch: every control in the hero is at least 40px to tap. At 360 and under the wordmark gives New chat room. */
@media (pointer: coarse) {
  .top .end .btn, .suggest button, .turn .follow button { min-height: 40px; }
  .gp-x { min-height: 40px; min-width: 40px; }
  footer .mark { display: flex; align-items: center; min-height: 40px; }
}
@media (max-width: 360px) { .top .mark svg { height: 24px; } }
@media (prefers-reduced-motion: reduce) {
  /* Reduced motion keeps every change as a short move, never a cut: masks and wipes run at the bar's 140 ms. */
  /* g.css cuts every move to 1 ms under reduced motion; the hero takes them back to short moves on purpose. */
  .hero, .hero *, .hero *::before, .hero *::after, .top *, body > .wipe-out { animation-duration: var(--mo-quick) !important; transition-duration: var(--mo-quick) !important; }
  .turn .w, .bars .fill { animation-delay: 0ms !important; }
  .ask .go.press { animation: none; }
  .hero .gpanel.leaving { animation-duration: var(--dur-fast) !important; }
  .ask .ghost { display: none; }
}

/* The resting view per layout, matched to the approved hero: the renderer fits the whole spin into the --g-* region less
   --map-margin px, seen from --map-pitch degrees (read by framing() in fasra.js). */
[data-layout="section"] .graph { --g-y0: .215; --g-y1: 1.215; --map-pitch: 23.7; --map-margin: 11; --map-margin-open: 40; }
@media (max-height: 760px) {
  [data-layout="hero"] .hero .graph { --g-y0: -.109; --g-y1: .631; --map-margin: 18; }
  [data-layout="split"] .hero .graph { --map-margin: 68; --map-margin-open: 35; }
  [data-layout="section"] .graph { --map-margin: 6; --map-margin-open: 45; }
}

/* Without WebGL2 the hero keeps its shape: in the split layout the kinds sit as a list where the galaxy would be,
   centred in its region. In the centred hero the map is only a backdrop, so it shows no list. On a phone the card opens as a sheet. */
.big .hero .graph.flat { height: var(--hero-h); padding: 0; }
.big .hero .graph.flat > ul { position: absolute; left: calc(var(--g-x0, 0) * 100% + var(--sp-6)); width: calc((var(--g-x1, 1) - var(--g-x0, 0)) * 100% - var(--sp-6) * 2); max-width: 480px; top: 50%; transform: translateY(-50%); grid-template-columns: 1fr 1fr; gap: var(--sp-3) var(--sp-6); }
.big .hero .graph.flat .gpanel { position: absolute; margin: 0; }
.big .hero .graph.flat.open > ul { top: var(--sp-7); transform: none; }
[data-layout="hero"] .hero .graph.flat > ul { display: none; }
@media (max-width: 940px) {
  .big .hero .graph.flat > ul { left: var(--sp-5); width: calc(100% - var(--sp-5) * 2); top: calc(var(--g-y1, .6) * 50%); }
  .big .hero .graph.flat .gpanel { position: fixed; left: var(--sp-4); right: var(--sp-4); top: auto; bottom: var(--sp-2); width: auto; max-height: 70svh; overflow: auto; z-index: 5; }
}

/* Short phones: a smaller headline and pitch leave the galaxy a band tall enough to tap every kind. */
@media (max-width: 940px) and (max-height: 700px) and (orientation: portrait) {
  .big .hero { --hero-pt: var(--sp-5); }
  .hero { padding-top: var(--sp-5); }
  [data-layout] .intro h1 { font-size: 30px; line-height: 36px; }
  [data-layout] .intro .sub { margin-top: var(--sp-2); font-size: 14px; line-height: 20px; }
  .ask-slot { margin-top: var(--sp-4); }
  [data-layout] .hero .graph { --map-pitch: 46; --map-margin: 24; }
}
/* A phone held sideways goes side by side: the words on the left, the galaxy on the right. In a chat the strip would be
   too thin to read, so the conversation takes the screen and the galaxy waits for New chat. */
@media (max-width: 940px) and (max-height: 500px) and (orientation: landscape) {
  [data-layout].big .hero { --hero-h: calc(100svh - 64px); min-height: var(--hero-h); align-items: flex-start; text-align: left; justify-content: center; padding: var(--sp-4) var(--sp-4) var(--sp-4) max(16px, env(safe-area-inset-left, 0px)); }
  [data-layout] .hero .graph { --g-x0: .52; --g-x1: 1; --g-y0: .02; --g-y1: .98; --map-pitch: 26; --map-margin: 20; }
  .big:not(.chatting) .hero > .intro, .big:not(.chatting) .hero > .ask-slot { width: 44%; max-width: none; }
  [data-layout] .intro h1 { font-size: 28px; line-height: 32px; }
  [data-layout] .intro .sub { margin: var(--sp-2) 0 0; font-size: 13px; line-height: 20px; }
  .ask-slot { margin-top: var(--sp-3); }
  .big.chatting .hero .graph { height: 0; visibility: hidden; box-shadow: none; }
  .big.chatting .hero > .convo, .big.chatting .hero > .ask-slot { width: min(560px, 100%); align-self: center; }
}
/* Tablets: the chat column gets wider and the galaxy strip takes the room under the top bar. */
@media (min-width: 600px) and (max-width: 940px) and (min-height: 701px) {
  .big .hero { --strip-h: clamp(160px, 28svh, 320px); }
  .big.chatting .hero > .convo, .big.chatting .hero > .ask-slot { width: min(560px, 100%); }
}
/* A tablet held upright reads the chat at tablet width, not as a phone column in a frame. */
@media (min-width: 700px) and (max-width: 940px) and (min-height: 701px) {
  .big.chatting .hero > .convo, .big.chatting .hero > .ask-slot { width: min(640px, 100%); }
}

/* A hovered name sits on its own plate, so it reads over orbs and lines alike. */
.gl-tip { padding: 3px var(--sp-2); background: var(--surface-1); border-radius: var(--radius-sm); box-shadow: 0 0 0 1px var(--slate-a4), 0 2px 8px var(--slate-a3); text-shadow: none; }
