/* Hatchcast: graphite trading terminal. One accent (yolk amber) for selection, primary actions and odds;
   green/red only for what happened (still trading / gone). Geist for everything, Geist Mono for addresses,
   hashes and clock times. Tabular numerals everywhere. No shadows, no glow, no load motion. */
:root {
  color-scheme: dark;
  --font: "Geist", "Segoe UI", system-ui, sans-serif;
  --mono: "Geist Mono", ui-monospace, Consolas, monospace;
  --bg: #0a0c0f; --side: #0d1014; --panel: #101318; --panel-2: #151920; --hover: #171c24;
  --line: #1c2129; --line-2: #262c36;
  --ink: #e7e9ec; --ink-2: #b3b9c2; --muted: #808894;
  --yolk: #f2b33d; --yolk-2: #f7c868; --yolk-soft: rgba(242, 179, 61, .12); --on-yolk: #15110a;
  --up: #3ecf8e; --up-soft: rgba(62, 207, 142, .12); --down: #f0616d; --down-soft: rgba(240, 97, 109, .12);
  --notice: rgba(242, 179, 61, .1);
  --r: 6px; --sidew: 212px;
  --t-2xs: 11px; --t-xs: 12px; --t-s: 13px; --t-m: 14px; --t-l: 16px; --t-xl: 20px; --t-2xl: 26px;
}
*, *::before, *::after { box-sizing: border-box; }
html, body { overflow-x: clip; }
html { -webkit-text-size-adjust: 100%; font-synthesis: none; scrollbar-color: var(--line-2) transparent; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 var(--t-m)/1.5 var(--font); font-variant-numeric: tabular-nums; -webkit-font-smoothing: antialiased; }
::selection { background: var(--yolk); color: var(--on-yolk); }
a { color: var(--yolk); text-decoration: none; text-underline-offset: 3px; }
a:hover { text-decoration: underline; }
:focus-visible { outline: 2px solid var(--yolk); outline-offset: 2px; border-radius: 4px; }
.skip { position: absolute; left: 12px; top: -60px; background: var(--yolk); color: var(--on-yolk); padding: 8px 12px; border-radius: var(--r); z-index: 30; }
.skip:focus { top: 12px; }
.mono { font-family: var(--mono); font-size: .92em; word-break: break-all; }
.muted { color: var(--muted); } .small { font-size: var(--t-xs); } .num { font-variant-numeric: tabular-nums; } .r { text-align: right; }
.show-s { display: none; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.tools { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.tools .sep { margin-left: 10px; }
.panel-f a svg, .more svg { width: 12px; height: 12px; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; vertical-align: -1px; margin-left: 4px; }
.odds strong.hi { color: var(--yolk); }
.tok .nm a { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tok .sym { flex: none; }
.up { color: var(--up); } .down { color: var(--down); }

/* ---- shell: fixed sidebar + content ---- */
.shell { display: grid; grid-template-columns: var(--sidew) minmax(0, 1fr); min-height: 100vh; }
.side { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; gap: 18px; padding: 16px 12px; background: var(--side); border-right: 1px solid var(--line); }
.bar { display: flex; align-items: center; justify-content: space-between; }
.wordmark { display: flex; align-items: center; gap: 9px; color: var(--ink); font-weight: 650; font-size: var(--t-l); letter-spacing: -.01em; padding: 2px 6px; }
.wordmark:hover { text-decoration: none; }
.wordmark svg { width: 24px; height: 24px; flex: none; }
.menu-btn { display: none; }
.side nav { display: flex; flex-direction: column; gap: 2px; }
.side nav a { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: var(--r); color: var(--ink-2); font-weight: 500; font-size: var(--t-m); transition: background-color .12s, color .12s; }
.side nav a svg { width: 17px; height: 17px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; opacity: .8; }
.side nav a small { margin-left: auto; color: var(--muted); font-size: var(--t-2xs); font-weight: 400; }
.side nav a:hover { background: var(--hover); color: var(--ink); text-decoration: none; }
.side nav a[aria-current="page"] { background: var(--yolk-soft); color: var(--yolk); }
.side nav a[aria-current="page"] svg { opacity: 1; }
.side .live { margin-top: auto; padding: 10px; border: 1px solid var(--line); border-radius: var(--r); font-size: var(--t-xs); color: var(--ink-2); line-height: 1.45; }
.side .live b { display: flex; align-items: center; gap: 7px; color: var(--ink); font-weight: 600; font-size: var(--t-s); }
.side .live b::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--up); }
.side .live.late b::before { background: var(--yolk); }
.side .meta { font-size: var(--t-2xs); color: var(--muted); padding: 0 4px; line-height: 1.5; }
.side .meta a { color: var(--ink-2); }
.content { min-width: 0; display: flex; flex-direction: column; }
.status { display: none; }

/* ---- market strip ---- */
.strip { display: flex; align-items: stretch; border-bottom: 1px solid var(--line); background: var(--side); overflow-x: auto; scrollbar-width: none; }
.strip > div { display: flex; flex-direction: column; justify-content: center; gap: 1px; padding: 9px 18px; border-right: 1px solid var(--line); white-space: nowrap; min-height: 56px; }
.strip > div:last-child { border-right: 0; }
.strip span { font-size: var(--t-2xs); color: var(--muted); }
.strip strong { font-size: var(--t-l); font-weight: 600; letter-spacing: -.01em; }
.strip strong small { font-size: var(--t-xs); font-weight: 400; color: var(--muted); margin-left: 4px; }
.strip .spark { width: 120px; height: 26px; }
.strip .grow { flex: 1; border-right: 0; align-items: flex-end; }
#notice:empty { display: none; }
.notice { margin: 12px 20px 0; padding: 9px 12px; border: 1px solid rgba(242, 179, 61, .35); background: var(--notice); color: var(--yolk-2); border-radius: var(--r); font-size: var(--t-s); }

/* ---- page ---- */
.wrap { padding: 18px 20px 40px; max-width: 1480px; width: 100%; }
.page-h { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }
h1 { font-size: var(--t-xl); font-weight: 650; letter-spacing: -.015em; line-height: 1.25; margin: 0; text-wrap: balance; }
h2 { font-size: var(--t-m); font-weight: 600; margin: 0; letter-spacing: -.005em; }
h3 { font-size: var(--t-m); font-weight: 600; margin: 22px 0 6px; }
.lede { color: var(--ink-2); font-size: var(--t-m); margin: 4px 0 0; max-width: 80ch; }
.note { color: var(--muted); font-size: var(--t-xs); margin: 8px 2px 0; max-width: 90ch; }
p { margin: 8px 0; }
.read { max-width: 72ch; }
.read h1 { font-size: var(--t-2xl); margin-bottom: 8px; }
.read h2 { font-size: var(--t-l); margin: 30px 0 8px; }
.read p, .read li { color: var(--ink-2); line-height: 1.65; }
.read strong { color: var(--ink); }

/* panels */
.grid { display: grid; gap: 14px; align-items: start; }
.grid.home { grid-template-columns: minmax(0, 2.4fr) minmax(300px, 1fr); }
.grid.halves { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.stack { display: grid; gap: 14px; min-width: 0; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); min-width: 0; }
.panel-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding: 10px 14px; border-bottom: 1px solid var(--line); min-height: 46px; }
.panel-h h2 { display: block; }
.panel-h h2 small { margin-left: 6px; }
.panel-h h2 small { color: var(--muted); font-weight: 400; font-size: var(--t-xs); }
.panel-b { padding: 12px 14px; }
.panel-f { padding: 9px 14px; border-top: 1px solid var(--line); font-size: var(--t-xs); color: var(--muted); display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.panel-f a { color: var(--ink-2); }
.panel-f a:hover { color: var(--yolk); }
.section { margin-top: 14px; }

/* ---- terminal table ---- */
.scroll { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; font-size: var(--t-s); }
th { text-align: left; font-weight: 500; font-size: var(--t-2xs); color: var(--muted); padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; background: var(--panel); position: sticky; top: 0; z-index: 1; }
td { padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr { transition: background-color .08s; }
tbody tr:hover { background: var(--hover); }
th.r, td.r { text-align: right; }
.tt td:first-child, .tt th:first-child { padding-left: 14px; }
.tt td:last-child, .tt th:last-child { padding-right: 14px; }
.rank { color: var(--muted); width: 28px; font-size: var(--t-xs); }
.tok { display: flex; align-items: center; gap: 10px; min-width: 0; }
.tok a { color: var(--ink); font-weight: 600; }
.tok a:hover { color: var(--yolk); text-decoration: none; }
.tok .nm { min-width: 0; }
.tok .nm > div:first-child { display: flex; align-items: baseline; gap: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 22ch; }
.tok .sym { color: var(--muted); font-size: var(--t-xs); font-weight: 400; }
.tok .sub { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: var(--t-2xs); margin-top: 1px; white-space: nowrap; }
.av { width: 30px; height: 30px; border-radius: 7px; flex: none; display: grid; place-items: center; font-weight: 650; font-size: 13px; color: #0b0d10; }
.av.big { width: 48px; height: 48px; font-size: 20px; border-radius: 10px; }
.pad-ic { width: 14px; height: 14px; border-radius: 50%; flex: none; object-fit: cover; background: var(--panel-2); }
.pad-ic.txt { display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 5px; font-size: 10px; font-weight: 700; color: var(--ink); background: var(--line-2); }
.odds { display: flex; align-items: center; gap: 10px; justify-content: flex-end; }
.odds strong { font-size: var(--t-m); font-weight: 650; min-width: 44px; text-align: right; }
.odds .track { width: 64px; height: 5px; flex: none; background: var(--line-2); }
.mult { color: var(--ink-2); font-size: var(--t-xs); white-space: nowrap; }
.mult.hi { color: var(--yolk); }
.acts { display: flex; gap: 4px; justify-content: flex-end; }
.act { display: inline-flex; align-items: center; gap: 5px; height: 26px; padding: 0 7px; border: 1px solid var(--line-2); border-radius: 5px; color: var(--ink-2); font-size: var(--t-xs); font-weight: 500; white-space: nowrap; background: transparent; transition: border-color .1s, color .1s, background-color .1s; }
.act img { width: 14px; height: 14px; border-radius: 50%; }
.act svg { width: 13px; height: 13px; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.act:hover { color: var(--ink); border-color: var(--muted); background: var(--panel-2); text-decoration: none; }
.act.pump:hover { border-color: #5fd48b; }
.empty-row td { color: var(--muted); text-align: center; padding: 28px 10px; }

/* tags */
.tag { display: inline-flex; align-items: center; gap: 5px; padding: 1px 7px; border-radius: 4px; font-size: var(--t-2xs); font-weight: 600; background: var(--panel-2); color: var(--ink-2); white-space: nowrap; }
.tag.hit { background: var(--up-soft); color: var(--up); }
.tag.miss { background: var(--down-soft); color: var(--down); }
.tag.open { background: transparent; color: var(--muted); border: 1px solid var(--line-2); }
.tag.state-born, .tag.state-rising { background: var(--yolk-soft); color: var(--yolk); }
.tag.state-peaking { color: var(--ink); }
.tag.state-fading { color: var(--muted); }

/* segmented control */
.seg { display: inline-flex; border: 1px solid var(--line-2); border-radius: var(--r); overflow: hidden; }
.seg.wrap { flex-wrap: wrap; }
.seg button { min-height: 28px; padding: 0 10px; border: 0; border-right: 1px solid var(--line-2); background: transparent; color: var(--ink-2); font: 500 var(--t-xs) var(--font); cursor: pointer; transition: background-color .1s, color .1s; }
.seg button:last-child { border-right: 0; }
.seg button:hover { background: var(--panel-2); color: var(--ink); }
.seg button[aria-pressed="true"] { background: var(--yolk-soft); color: var(--yolk); }
.seg .n { opacity: .7; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 32px; padding: 0 12px; border-radius: var(--r); border: 1px solid var(--line-2); background: var(--panel-2); color: var(--ink); font: 500 var(--t-s) var(--font); cursor: pointer; text-decoration: none; transition: background-color .1s, border-color .1s; }
.btn:hover { background: var(--hover); border-color: var(--muted); text-decoration: none; }
.btn.primary { background: var(--yolk); border-color: var(--yolk); color: var(--on-yolk); font-weight: 600; }
.btn.primary:hover { background: var(--yolk-2); }
.btn.small { min-height: 26px; font-size: var(--t-xs); padding: 0 9px; }
.btn:disabled { opacity: .5; cursor: default; }

/* filters */
.filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-end; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.filters label, .pad-pick { display: flex; flex-direction: column; gap: 3px; font-size: var(--t-2xs); color: var(--muted); }
select, input[type=search] { height: 30px; padding: 0 9px; border: 1px solid var(--line-2); border-radius: var(--r); background: var(--bg); color: var(--ink); font: 400 var(--t-s) var(--font); min-width: 120px; }
input[type=search] { min-width: 190px; }
select:hover, input:hover { border-color: var(--muted); }
input::placeholder { color: var(--muted); }

/* ---- bars (barlist, meter) ---- */
.rows { display: grid; grid-template-columns: minmax(110px, max-content) minmax(80px, 1fr) max-content; gap: 9px 12px; align-items: center; }
.rows .name { font-size: var(--t-s); line-height: 1.3; }
.rows .name small, .rows .fig small { display: block; color: var(--muted); font-size: var(--t-2xs); font-weight: 400; }
.rows .fig { font-weight: 600; font-size: var(--t-s); text-align: right; }
.track { position: relative; height: 7px; border-radius: 4px; background: var(--panel-2); }
.track.plain { background: var(--line); }
.fill { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 4px; background: var(--yolk); }
.fill.dim { background: var(--line-2); }
.ci { position: absolute; top: -3px; bottom: -3px; border: 1px solid var(--ink-2); border-left-width: 1.5px; border-right-width: 1.5px; border-top: 0; border-bottom: 0; opacity: .7; }
.tick { position: absolute; top: -4px; bottom: -4px; width: 2px; background: var(--ink); border-radius: 1px; }
.mini { display: flex; align-items: center; gap: 8px; } .mini .track { width: 80px; } .mini strong { min-width: 42px; text-align: right; }
.legend { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-top: 10px; font-size: var(--t-2xs); color: var(--muted); }
.legend i { display: inline-block; width: 12px; height: 7px; border-radius: 2px; margin-right: 5px; vertical-align: middle; }
.k-fill { background: var(--yolk); } .k-tick { width: 2px !important; height: 11px !important; background: var(--ink); }
.k-ci { border-left: 1.5px solid var(--ink-2); border-right: 1.5px solid var(--ink-2); height: 9px !important; }
.k-dim { background: var(--line-2); }
.k-hatch { background: repeating-linear-gradient(45deg, rgba(240, 97, 109, .5) 0 1.5px, transparent 1.5px 5px); }
.chart { min-width: 0; }
.chart-title { font-weight: 600; font-size: var(--t-s); margin: 0; }
.chart-sub { color: var(--muted); font-size: var(--t-xs); margin: 2px 0 12px; max-width: 80ch; }
.spark { display: block; width: 100%; height: 44px; }

/* ---- big numbers row (funnel) ---- */
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.kpis > div { padding: 12px 14px; border-right: 1px solid var(--line); }
.kpis > div:last-child { border-right: 0; }
.kpis span { display: block; font-size: var(--t-2xs); color: var(--muted); }
.kpis strong { font-size: var(--t-xl); font-weight: 650; letter-spacing: -.015em; }
.kpis small { display: block; font-size: var(--t-2xs); color: var(--muted); }

/* ---- narratives list ---- */
.nar { list-style: none; margin: 0; padding: 0; }
.nar li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 10px; padding: 9px 14px; border-bottom: 1px solid var(--line); }
.nar li:last-child { border-bottom: 0; }
.nar .w { font-weight: 650; display: flex; align-items: center; gap: 7px; min-width: 0; }
.nar .w span:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nar .x { font-weight: 650; text-align: right; }
.nar .ex { grid-column: 1 / -1; font-size: var(--t-2xs); color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nar .n { font-size: var(--t-2xs); color: var(--muted); text-align: right; }
.chip { display: inline-block; padding: 0 6px; border-radius: 4px; background: var(--yolk-soft); color: var(--yolk); font-size: var(--t-2xs); font-weight: 600; }

/* ---- pulse stream ---- */
.pulse-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.pulse-title { font-weight: 600; }
.pulse-tools { display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.stream { list-style: none; margin: 0; padding: 0; }
.msg { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 10px; padding: 9px 14px; border-bottom: 1px solid var(--line); margin: 0; }
.msg:last-child { border-bottom: 0; }
.msg.fresh { background: var(--yolk-soft); }
@media (prefers-reduced-motion: no-preference) { .msg.fresh { animation: settle 3s ease-out forwards; } @keyframes settle { to { background: transparent; } } }
.mark { width: 22px; height: 22px; border-radius: 5px; display: grid; place-items: center; background: var(--panel-2); color: var(--ink-2); margin-top: 1px; }
.mark svg { width: 13px; height: 13px; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.k-forecast .mark { background: var(--yolk-soft); color: var(--yolk); }
.k-outcome .mark { background: var(--up-soft); color: var(--up); }
.k-outcome.miss .mark { background: var(--down-soft); color: var(--down); }
.k-theme .mark, .k-copycat .mark { color: var(--ink); }
.msg-main { min-width: 0; }
.msg-head { font-size: var(--t-s); line-height: 1.45; }
.msg-head a { color: var(--ink); font-weight: 600; }
.msg-head a:hover { color: var(--yolk); text-decoration: none; }
.msg-body { font-size: var(--t-xs); color: var(--ink-2); margin-top: 2px; }
.msg-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 3px 10px; margin-top: 4px; font-size: var(--t-2xs); color: var(--muted); }
.msg-meta time { font-family: var(--mono); }
.msg-meta a { color: var(--muted); text-decoration: underline; }
.msg-meta a:hover { color: var(--yolk); }
.more { display: block; padding: 9px 14px; border-top: 1px solid var(--line); font-size: var(--t-xs); color: var(--ink-2); }
.more:hover { color: var(--yolk); text-decoration: none; }
.empty { color: var(--muted); padding: 24px 14px; text-align: center; font-size: var(--t-s); margin: 0; }

/* ---- quadrant ---- */
.quad { margin: 0; }
.quad svg { width: 100%; height: auto; display: block; }
.quad text { font-family: var(--font); }
.q-axis { stroke: var(--line-2); stroke-width: 1.5; }
.q-hatch { stroke: var(--down); stroke-width: 1.2; opacity: .2; }
.q-corner { font-size: 11.5px; font-weight: 500; fill: var(--muted); paint-order: stroke; stroke: var(--panel); stroke-width: 4px; stroke-linejoin: round; }
.q-end { font-size: 12px; font-weight: 600; fill: var(--ink-2); }
.q-avg, .q-tick { font-size: 11px; fill: var(--muted); paint-order: stroke; stroke: var(--panel); stroke-width: 4px; }
.q-badge { fill: var(--panel-2); }
.q-ring { fill: none; stroke: var(--panel); stroke-width: 2.5; }
.q-init { font-size: 11px; font-weight: 700; fill: var(--ink-2); }
.q-pill { fill: var(--yolk); stroke: var(--panel); stroke-width: 2; }
.q-pill-t { font-size: 12px; font-weight: 650; fill: var(--on-yolk); }
.q-lead { stroke: var(--muted); stroke-width: 1; } .q-anchor { fill: var(--muted); }
.q-hit { fill: transparent; }
.q-pt:hover .q-ring, .q-pt:focus .q-ring { stroke: var(--yolk); }
.q-pt:hover .q-pill { fill: var(--yolk-2); }
.q-pt:focus { outline: none; } .q-pt:focus-visible .q-ring, .q-pt:focus-visible .q-pill { stroke: var(--ink); }
.q-label { font-size: 12.5px; font-weight: 600; fill: var(--ink); paint-order: stroke; stroke: var(--panel); stroke-width: 4px; stroke-linejoin: round; }

/* verify */
.verify-out { margin-top: 6px; font-size: var(--t-xs); color: var(--ink-2); }
.verify-out strong { color: var(--ink); }

/* loading */
.skel { height: 14px; border-radius: 4px; background: var(--panel-2); margin: 12px 0; }
.skel.h { height: 26px; width: 40%; margin-top: 8px; } .skel.w80 { width: 80%; } .skel.w50 { width: 50%; }

footer { margin-top: auto; padding: 16px 20px 24px; border-top: 1px solid var(--line); font-size: var(--t-2xs); color: var(--muted); }
footer p { margin: 3px 0; }
footer a { color: var(--ink-2); }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* ---- narrower screens ---- */
@media (max-width: 1180px) { .grid.home { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 60rem) {
  .shell { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto 1fr; }
  .side { position: sticky; top: 0; z-index: 20; height: auto; padding: 10px 14px; gap: 0; border-right: 0; border-bottom: 1px solid var(--line); }
  .menu-btn { display: inline-flex; align-items: center; min-height: 34px; padding: 0 12px; border: 1px solid var(--line-2); border-radius: var(--r); background: transparent; color: var(--ink); font: 500 var(--t-s) var(--font); cursor: pointer; }
  .side nav, .side .live, .side .meta { display: none; }
  .side.open nav { display: flex; padding-top: 10px; }
  .side.open .live { display: block; margin-top: 10px; }
  .side nav a { min-height: 42px; }
  .wrap { padding: 14px 12px 32px; }
  .grid.halves { grid-template-columns: minmax(0, 1fr); }
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kpis > div:nth-child(2) { border-right: 0; } .kpis > div:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .hide-s { display: none; }
  .odds .track { display: none; }
  .tok .nm > div:first-child { max-width: 11ch; }
  .tok .sym { display: none; }
  .show-s { display: inline; }
  td > .show-s { display: block; margin-top: 4px; text-align: right; }
  .rank, .acts .lbl { display: none; }
  .tt td:first-child, .tt th:first-child { padding-left: 10px; }
  .page-h .acts .lbl { display: inline; }
  .seg button { min-height: 34px; }
  .rows { grid-template-columns: minmax(90px, max-content) minmax(60px, 1fr) max-content; }
}
.btn svg { width: 14px; height: 14px; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.reliab text { fill: var(--muted); font-size: 11px; }
.two { display: grid; grid-template-columns: minmax(0, 380px) minmax(0, 1fr); gap: 20px; align-items: start; }
.grid.split { grid-template-columns: minmax(0, 1.6fr) minmax(300px, 1fr); }
@media (max-width: 1180px) { .grid.split { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 60rem) { .two { grid-template-columns: minmax(0, 1fr); } }
.av { position: relative; overflow: hidden; }
.av img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.mk { display: flex; flex-direction: column; align-items: flex-end; line-height: 1.25; }
.mk strong { font-weight: 600; font-size: var(--t-s); }
.mk small { font-size: var(--t-2xs); }
/* click-to-sort headers */
#main thead th:not(.nosort) { cursor: pointer; user-select: none; }
#main thead th:not(.nosort):hover { color: var(--ink); }
#main thead th[aria-sort="ascending"], #main thead th[aria-sort="descending"] { color: var(--yolk); }
#main thead th[aria-sort="ascending"]::after, #main thead th[aria-sort="descending"]::after { content: ""; display: inline-block; margin-left: 5px; vertical-align: 2px; border: 4px solid transparent; }
#main thead th[aria-sort="descending"]::after { border-top-color: currentColor; border-bottom-width: 0; }
#main thead th[aria-sort="ascending"]::after { border-bottom-color: currentColor; border-top-width: 0; }
/* launch pace in the top strip */
.strip .pace { gap: 2px; }
.pace-row { display: flex; align-items: center; gap: 12px; }
.pace-row strong small { display: block; margin: 0; font-size: var(--t-2xs); }
.pace-row .range { font-size: var(--t-2xs); color: var(--muted); line-height: 1.4; white-space: nowrap; }
.spark .hr { fill: transparent; }
.spark .hr:hover { fill: var(--yolk); fill-opacity: .18; }
/* proof and method: a quieter group at the foot of the sidebar */
.side nav.sub { margin-top: auto; padding-top: 10px; border-top: 1px solid var(--line); }
.side nav.sub a { padding: 6px 10px; font-size: var(--t-s); color: var(--muted); }
.side nav.sub + .live { margin-top: 0; }
@media (max-width: 60rem) { .side nav.sub { display: none; } .side.open nav.sub { display: flex; margin-top: 8px; } }
.tag.warn { background: var(--down-soft); color: var(--down); }
.tok .sub .tag { margin-left: 4px; }
/* Pulse: summary filters, time groups, event rows with a figure and links on the right */
.pulse-sum { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); border-bottom: 1px solid var(--line); }
.pulse-sum button { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; padding: 10px 14px; border: 0; border-right: 1px solid var(--line);
  background: transparent; color: var(--ink-2); font: 500 var(--t-xs) var(--font); cursor: pointer; text-align: left; transition: background-color .1s; }
.pulse-sum button:last-child { border-right: 0; }
.pulse-sum button strong { font-size: var(--t-xl); font-weight: 650; color: var(--ink); letter-spacing: -.015em; }
.pulse-sum button:hover { background: var(--hover); }
.pulse-sum button[aria-pressed="true"] { background: var(--yolk-soft); color: var(--yolk); }
.pulse-sum button[aria-pressed="true"] strong { color: var(--yolk); }
.bucket { margin: 0; padding: 8px 14px; font-size: var(--t-2xs); font-weight: 600; color: var(--muted); background: var(--side); border-bottom: 1px solid var(--line); }
.stream .msg { grid-template-columns: 30px minmax(0, 1fr) auto; align-items: start; }
.stream .msg > .av, .stream .msg > .mark { width: 30px; height: 30px; }
.msg-side { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.msg-fig { display: flex; flex-direction: column; align-items: flex-end; line-height: 1.2; }
.msg-fig .fig { font-size: var(--t-l); font-weight: 650; }
.msg-fig .fig.hi { color: var(--yolk); }
.msg-fig small { font-size: var(--t-2xs); color: var(--muted); }
.msg-warn { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 5px; }
.msg.warned { box-shadow: none; }
.msg-meta span { display: inline-flex; align-items: center; gap: 4px; }
.mark .pad-ic { width: 18px; height: 18px; }
#pulse-mini .acts, #pulse-mini .msg-body { display: none; }
@media (max-width: 1180px) { .pulse-sum { grid-template-columns: repeat(4, minmax(0, 1fr)); } .pulse-sum button:nth-child(4) { border-right: 0; } .pulse-sum button:nth-child(-n+4) { border-bottom: 1px solid var(--line); } }
@media (max-width: 60rem) { .stream .msg { grid-template-columns: 30px minmax(0, 1fr); } .msg-side { grid-column: 2; flex-direction: row; justify-content: space-between; width: 100%; align-items: center; } .msg-fig { align-items: flex-start; } }
/* search */
.sbox input { width: 100%; height: 34px; padding: 0 10px; border: 1px solid var(--line-2); border-radius: var(--r); background: var(--bg); color: var(--ink); font: 400 var(--t-s) var(--font); }
.sbox input:focus { border-color: var(--yolk); outline: none; }
.sform { display: flex; gap: 8px; padding: 10px; }
.sform input { flex: 1; height: 40px; padding: 0 12px; border: 1px solid var(--line-2); border-radius: var(--r); background: var(--bg); color: var(--ink); font: 400 var(--t-m) var(--font); }
.sform input:focus { border-color: var(--yolk); outline: none; }
@media (max-width: 60rem) { .side .sbox { display: none; } .side.open .sbox { display: block; padding-top: 10px; } }
.btn-more { width: 100%; border: 0; border-top: 1px solid var(--line); background: transparent; text-align: left; cursor: pointer; font: 500 var(--t-xs) var(--font); }
#surv.tall .scroll { max-height: 560px; overflow-y: auto; }
/* Collapsible sidebar: an icon rail on wide screens. Labels stay readable to screen readers; search becomes an icon that reopens the bar. */
.rail-btn, .s-ico { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; padding: 0; border: 0; border-radius: var(--r); background: transparent; color: var(--muted); cursor: pointer; }
.rail-btn:hover, .s-ico:hover { background: var(--hover); color: var(--ink); }
.rail-btn svg, .s-ico svg { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.s-ico { display: none; }
@media (min-width: 60.01rem) {
  .rail { --sidew: 64px; }
  .rail .side { padding: 16px 10px; align-items: center; }
  .rail .bar { flex-direction: column; gap: 10px; }
  .rail .wordmark span, .rail .side nav a span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .rail .wordmark { padding: 2px; }
  .rail .side nav { width: 100%; align-items: center; }
  .rail .side nav a { justify-content: center; width: 42px; padding: 10px 0; }
  .rail .side nav a svg { width: 19px; height: 19px; }
  .rail .side nav.sub { width: 100%; }
  .rail .sbox input, .rail .side .live, .rail .side .meta { display: none; }
  .rail .s-ico { display: inline-flex; width: 42px; height: 38px; border: 1px solid var(--line-2); }
}
@media (max-width: 60rem) { .rail-btn { display: none; } }
/* Light theme: same layout, paler surfaces; the amber accent darkens so text on white keeps 4.5:1 contrast. */
[data-theme="light"] {
  color-scheme: light;
  --bg: #f6f6f3; --side: #efefeb; --panel: #ffffff; --panel-2: #f4f4f0; --hover: #e9e9e4;
  --line: #e2e2dc; --line-2: #d2d2cb;
  --ink: #15181d; --ink-2: #3d444e; --muted: #656d78;
  --yolk: #8f5b00; --yolk-2: #7a4d00; --yolk-soft: rgba(242, 179, 61, .2); --on-yolk: #ffffff;
  --up: #0e7c52; --up-soft: rgba(14, 124, 82, .12); --down: #c22c3a; --down-soft: rgba(194, 44, 58, .1);
  --notice: rgba(242, 179, 61, .16);
}
.theme-btn { display: flex; align-items: center; gap: 10px; width: 100%; padding: 6px 10px; border: 0; border-radius: var(--r); background: transparent; color: var(--muted); font: 500 var(--t-s) var(--font); text-align: left; cursor: pointer; }
.theme-btn:hover { background: var(--hover); color: var(--ink); }
.theme-btn svg { width: 17px; height: 17px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
html:not([data-theme="light"]) .theme-btn svg { fill: currentColor; }
@media (min-width: 60.01rem) {
  .rail .theme-btn { justify-content: center; width: 42px; padding: 10px 0; }
  .rail .theme-btn span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
}
