/* lint: the live console. A linter's terminal in the style of tmux and htop:
   window tabs in the top bar, panes with 1 px borders, a status line at the
   bottom, one monospace face, small and dense. Lime for what passes and what
   matters, amber for claims and live things, red only for private records
   and errors. No gradients, no glow, no shadows, corners at most 4 px. */

@font-face { font-family: JBM; src: url(/fonts/jetbrains-mono-latin.woff2) format('woff2'); font-weight: 100 800; font-display: swap; }

:root {
  --bg: #060807; --pane: #0a0d0c; --row: #0d1110; --line: #1b2420; --line2: #26322d;
  --t1: #dfe7e1; --t2: #8d9a92; --t3: #4f5d55;
  --lime: #c4ff4d; --amber: #ffb02e; --red: #ff4d6a; --white: #f5f7f6; --slate: #7f8f99;
  --mono: JBM, ui-monospace, 'SFMono-Regular', Menlo, Consolas, monospace;
  --top: 48px; --status: 26px; --gut: 28px;
  color-scheme: dark;
}

/* ---- base ---- */
* { box-sizing: border-box; margin: 0; padding: 0; }
html { background: var(--bg); color: var(--t1); font: 400 13px/1.6 var(--mono); font-variant-numeric: tabular-nums; -webkit-font-smoothing: antialiased; text-size-adjust: 100%; scrollbar-color: var(--line2) var(--bg); }
body { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; background: var(--bg); overflow-x: hidden; }
main { flex: 1; width: 100%; min-width: 0; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; color: inherit; background: none; border: 0; }
button { cursor: pointer; }
img, svg, canvas { display: block; max-width: 100%; }
b, strong { font-weight: 600; color: var(--t1); }
input::placeholder, textarea::placeholder { color: var(--t3); opacity: 1; }
:focus-visible { outline: 1px solid var(--lime); outline-offset: 2px; }
::selection { background: var(--lime); color: var(--bg); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }
* { scrollbar-width: thin; scrollbar-color: var(--line2) transparent; }

.t1 { color: var(--t1); } .t2 { color: var(--t2); } .t3 { color: var(--t3); }
.lime { color: var(--lime); } .amber { color: var(--amber); } .red { color: var(--red); } .slate { color: var(--slate); }
.nowrap { white-space: nowrap; }
.r { text-align: right; }
.ell { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.small { font-size: 12px; } .tiny { font-size: 11px; }
.mt { margin-top: 12px; } .mt-l { margin-top: 20px; } .mt-xl { margin-top: 28px; }
a.lk { color: var(--lime); } a.lk:hover { color: var(--white); }
a.nm { color: var(--amber); } a.nm:hover { color: var(--white); }
.i { width: 1em; height: 1em; display: inline-block; vertical-align: -.12em; flex: none; }

/* ---- top bar: logo, tmux tabs, coin cells ---- */
.top { position: sticky; top: 0; z-index: 40; height: var(--top); display: flex; align-items: stretch; background: var(--bg); border-bottom: 1px solid var(--line); }
.logo { flex: none; width: 60px; display: grid; place-items: center; border-right: 1px solid var(--line); }
.logo .mark { width: 30px; height: auto; }
.mark .on { fill: var(--lime); } .mark .off { fill: var(--line2); }
.tabs { display: flex; min-width: 0; overflow: hidden; }
.tabs a { display: flex; align-items: center; padding: 0 15px; border-right: 1px solid var(--line); color: var(--t2); white-space: nowrap; transition: color .12s, background-color .12s; }
.tabs a:hover { color: var(--t1); background: var(--row); }
.tabs a[aria-current="page"] { background: var(--lime); color: var(--bg); font-weight: 600; }
.tabs a[aria-current="page"]::after { content: '*'; }
.top-r { margin-left: auto; display: flex; align-items: stretch; flex: none; }
.cell { display: flex; align-items: center; gap: 8px; padding: 0 16px; border-left: 1px solid var(--line); color: var(--t2); white-space: nowrap; }
button.cell, a.cell { cursor: pointer; transition: background-color .12s, color .12s; }
button.cell:hover, a.cell:hover { background: var(--row); color: var(--t1); }
.cell .v { color: var(--t1); font-weight: 600; }
.cell .up { color: var(--lime); } .cell .dn { color: var(--red); }
.cell.buy { background: var(--white); color: var(--bg); font-weight: 600; border-left-color: var(--white); }
.cell.buy:hover { background: var(--lime); color: var(--bg); }
.cell.soon { color: var(--amber); }
#wallet-btn { color: var(--t1); }
#wallet-btn.on { color: var(--lime); }
.menu-btn { display: none; width: 48px; border-left: 1px solid var(--line); place-items: center; color: var(--t2); }
.menu-btn svg { width: 18px; height: 18px; }
.drawer { position: fixed; top: var(--top); left: 0; right: 0; z-index: 39; background: var(--bg); border-bottom: 1px solid var(--line2); max-height: calc(100dvh - var(--top)); overflow: auto; }
.drawer a { display: flex; justify-content: space-between; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); color: var(--t1); }
.drawer a small { color: var(--t3); font-size: 12px; }
.drawer a[aria-current="page"] { color: var(--lime); }

/* ---- status line and the mobile tab bar ---- */
.status { position: sticky; bottom: 0; z-index: 30; height: var(--status); display: flex; align-items: stretch; background: var(--bg); border-top: 1px solid var(--line); font-size: 12px; color: var(--t3); white-space: nowrap; }
.status .brand { display: flex; align-items: center; padding: 0 12px; background: var(--lime); color: var(--bg); font-weight: 600; }
.status .dom { display: flex; align-items: center; padding: 0 14px; color: var(--t2); }
.status .nfa { display: flex; align-items: center; padding: 0 8px; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.status .sr { margin-left: auto; display: flex; align-items: center; gap: 14px; padding: 0 14px; }
.status .sr b { color: var(--t1); font-weight: 500; }
.dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--amber); flex: none; }
.dot.pulse { animation: pulse 1.8s ease-in-out infinite; }
.dot.lime { background: var(--lime); } .dot.gray { background: var(--t3); } .dot.red { background: var(--red); }
.tabbar { display: none; }
.nfa-m { display: none; }

/* ---- page frame ---- */
.page { padding: 26px var(--gut) 40px; }
.prompt { color: var(--t1); font-size: 14px; line-height: 1.5; display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 10px; margin-bottom: 18px; }
.prompt .home { color: var(--t3); }
.prompt .ps { color: var(--lime); }
.prompt b { font-weight: 600; }
.cmt { color: var(--t3); font-size: 12.5px; }
.cmt b { color: var(--t2); font-weight: 600; }

/* panes: 1 px borders, a header row, a body */
.pane { border: 1px solid var(--line); background: var(--pane); min-width: 0; display: flex; flex-direction: column; }
.pane-h { display: flex; align-items: center; gap: 10px; min-height: 34px; padding: 7px 14px; border-bottom: 1px solid var(--line); font-size: 12px; color: var(--t3); white-space: nowrap; overflow: hidden; }
.pane-h > b { color: var(--t1); font-weight: 600; }
.pane-h .r { margin-left: auto; text-align: right; }
.pane-b { padding: 14px 16px; min-width: 0; }
.pane-b + .pane-b, .pane-sep { border-top: 1px solid var(--line); }
.cols2 { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); align-items: start; }
.cols2 > * + * { margin-left: -1px; }
.cols2.even { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.stackp { display: grid; align-content: start; min-width: 0; }
.stackp > .pane + .pane { border-top: 0; }

/* stat grid */
.stats { display: grid; grid-template-columns: repeat(var(--n, 4), minmax(0, 1fr)); border-bottom: 1px solid var(--line); }
.stat { padding: 13px 16px 14px; border-right: 1px solid var(--line); min-width: 0; }
.stat:last-child { border-right: 0; }
.stat .k { display: block; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--t3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stat .v { display: block; font-size: 22px; line-height: 1.3; margin-top: 6px; color: var(--t1); font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stat .v.lime { color: var(--lime); } .stat .v.amber { color: var(--amber); }
.stat .v small { font-size: 12px; color: var(--t3); margin-left: 5px; font-weight: 400; }
.stat .s { display: block; font-size: 11.5px; color: var(--t3); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* tables: dense, aligned, sticky header */
.tbl-wrap { overflow: auto; min-width: 0; }
.tbl { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.tbl th { position: sticky; top: 0; z-index: 1; background: var(--row); color: var(--t1); font-weight: 600; text-align: left; padding: 6px 10px; white-space: nowrap; border-bottom: 1px solid var(--line); }
.tbl td { padding: 5px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; color: var(--t2); vertical-align: top; }
.tbl th.r, .tbl td.r { text-align: right; }
.tbl tbody tr { transition: background-color .12s; }
.tbl tbody tr:hover { background: var(--row); }
.tbl tr.go { cursor: pointer; }
.tbl td.t1 { color: var(--t1); } .tbl td.t3 { color: var(--t3); }
.tbl td.wrap { white-space: normal; min-width: 180px; overflow-wrap: anywhere; }
.tbl td.cut { max-width: 240px; overflow: hidden; text-overflow: ellipsis; }
.tbl .empty td { color: var(--t3); padding: 14px 10px; white-space: normal; }
.tbl tr.enter td { animation: rowin 1.2s ease-out; }
.st-R { color: var(--lime); } .st-S { color: var(--t3); } .st-C { color: var(--red); } .st-P { color: var(--amber); }

/* htop meters */
.meters { display: grid; gap: 1px; font-size: 12.5px; }
.meter { display: grid; grid-template-columns: 4ch auto minmax(0, 1fr) auto; align-items: center; white-space: nowrap; }
.meter .mk { color: var(--lime); text-align: right; padding-right: 1px; }
.meter .br { color: var(--t2); }
.meter .bar { position: relative; overflow: hidden; height: 1.6em; line-height: 1.6em; }
.meter .fill { position: absolute; left: 0; top: 0; bottom: 0; overflow: hidden; color: var(--lime); letter-spacing: -.02em; transition: width .8s ease-out; }
.meter .fill.amber { color: var(--amber); } .meter .fill.slate { color: var(--slate); } .meter .fill.red { color: var(--red); }
.meter .val { position: absolute; right: 2px; top: 0; color: var(--t3); background: var(--pane); padding-left: 6px; }
.tasks { font-size: 12.5px; color: var(--t2); line-height: 1.55; }
.tasks .k { color: var(--lime); }
.tasks b { color: var(--t1); font-weight: 600; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 40px; padding: 8px 18px; border: 1px solid var(--line2); color: var(--t1); background: transparent; font-weight: 500; white-space: nowrap; transition: background-color .12s, border-color .12s, color .12s; border-radius: 0; }
.btn:hover { border-color: var(--t2); background: var(--row); }
.btn.p { background: var(--lime); border-color: var(--lime); color: var(--bg); font-weight: 600; }
.btn.p:hover { background: var(--white); border-color: var(--white); }
.btn.w { background: var(--white); border-color: var(--white); color: var(--bg); font-weight: 600; }
.btn.w:hover { background: var(--lime); border-color: var(--lime); }
.btn.danger { color: var(--red); border-color: rgba(255, 77, 106, .45); }
.btn.danger:hover { background: rgba(255, 77, 106, .08); border-color: var(--red); }
.btn.s { min-height: 30px; padding: 4px 12px; font-size: 12px; }
.btn.blk { width: 100%; }
.btn[disabled] { opacity: .45; cursor: default; pointer-events: none; }
.btn .tag { margin-left: 2px; }
.btns { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.tag { display: inline-flex; align-items: center; height: 18px; padding: 0 6px; border: 1px solid var(--line2); color: var(--t3); font-size: 11px; font-weight: 400; line-height: 1; white-space: nowrap; vertical-align: 1px; }
.tag.lime { color: var(--lime); border-color: rgba(196, 255, 77, .4); }
.tag.amber { color: var(--amber); border-color: rgba(255, 176, 46, .45); }
.tag.red { color: var(--red); border-color: rgba(255, 77, 106, .45); }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 2px 8px; border: 1px solid var(--line2); color: var(--t2); font-size: 12px; cursor: pointer; }
.pill:hover { color: var(--t1); border-color: var(--t3); }
.pill .i { width: 12px; height: 12px; }

/* boxes */
.note { border: 1px dashed var(--line2); padding: 11px 14px; color: var(--t2); }
.note b { color: var(--t1); }
.notice { border: 1px solid var(--line); border-left: 2px solid var(--amber); background: var(--row); padding: 12px 16px; color: var(--t2); }
.notice > b:first-child, .notice .h { color: var(--t1); font-weight: 600; display: flex; align-items: center; gap: 8px; margin-bottom: 4px; }
.notice.red { border-left-color: var(--red); } .notice.lime { border-left-color: var(--lime); } .notice.gray { border-left-color: var(--t3); }
.errbox { border: 1px solid rgba(255, 77, 106, .35); border-left: 2px solid var(--red); padding: 10px 14px; color: var(--t2); }
.errbox b { color: var(--red); display: block; }
.empty { padding: 18px 16px; color: var(--t3); display: grid; gap: 8px; justify-items: start; }
.empty b { color: var(--t1); font-weight: 500; }
.empty .m { color: var(--t3); }

/* command line and flags */
.cmd { display: flex; align-items: stretch; border: 1px solid var(--line2); background: var(--pane); min-height: 44px; transition: border-color .12s; }
.cmd:focus-within { border-color: var(--lime); }
.cmd .ps { display: flex; align-items: center; padding: 0 0 0 14px; color: var(--lime); white-space: nowrap; gap: 8px; }
.cmd .ps b { color: var(--t1); font-weight: 500; }
.cmd input { flex: 1; min-width: 0; padding: 0 10px; outline: none; color: var(--t1); }
.cmd .btn { min-height: 0; border: 0; border-left: 1px solid var(--line2); }
.flag { display: grid; grid-template-columns: 13ch minmax(0, 1fr); align-items: baseline; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.flag > .fk { color: var(--lime); white-space: nowrap; }
.flag input, .flag textarea { width: 100%; outline: none; color: var(--t1); padding: 2px 0; }
.flag textarea { resize: vertical; min-height: 70px; border: 1px solid var(--line); padding: 8px; }
.flag:focus-within { border-bottom-color: var(--lime); }
.flag .fv { min-width: 0; }
.help { font-size: 12px; color: var(--t3); }
.err { font-size: 12px; color: var(--red); }
.input { width: 100%; border: 1px solid var(--line2); padding: 9px 12px; outline: none; color: var(--t1); background: var(--pane); }
.input:focus { border-color: var(--lime); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { display: inline-flex; align-items: baseline; gap: 6px; padding: 4px 10px; border: 1px solid var(--line2); color: var(--t2); font-size: 12.5px; transition: color .12s, border-color .12s; }
.chip small { color: var(--t3); font-size: 11px; }
.chip:hover { color: var(--t1); border-color: var(--t3); }
.chip[aria-pressed="true"] { color: var(--lime); border-color: var(--lime); background: rgba(196, 255, 77, .06); }
.chip[aria-pressed="true"] small { color: var(--t2); }
.keys { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 12.5px; }
.keys button { color: var(--t2); padding: 2px 0; }
.keys button .k { color: var(--t1); }
.keys button:hover { color: var(--t1); }
.keys button[aria-pressed="true"] { color: var(--bg); background: var(--lime); padding: 2px 6px; }
.keys button[aria-pressed="true"] .k { color: var(--bg); }
.keys .c { color: var(--t3); margin-left: 4px; }
.keys button[aria-pressed="true"] .c { color: var(--bg); opacity: .7; }

/* lint lines: a gutter with the line number, the mark, the text */
.ll { list-style: none; display: grid; gap: 3px; }
.ll li { display: grid; grid-template-columns: auto 1.6ch minmax(0, 1fr); gap: 0 10px; align-items: baseline; color: var(--t2); }
.ll li::before { content: attr(data-n); color: var(--t3); min-width: 0; font-size: 11.5px; }
.ll li:not([data-n])::before { content: none; }
.ll li:not([data-n]) { grid-template-columns: 1.6ch minmax(0, 1fr); }
.ll .m { font-weight: 700; text-align: center; }
.ll .ok .m, .ll li.ok > .m { color: var(--lime); }
.ll li.warn > .m { color: var(--amber); }
.ll li.bad > .m { color: var(--red); }
.ll li.info > .m { color: var(--t2); }
.ll li.dim > .m, .ll li.dim { color: var(--t3); }
.ll li.ok > span:last-child, .ll li.warn > span:last-child { color: var(--t1); }
.ll li.now > span:last-child::after { content: '\2588'; color: var(--lime); margin-left: 4px; animation: blink 1s steps(1) infinite; }
.ll a { color: var(--lime); }
.mk { color: var(--amber); }
.mk.ok { color: var(--lime); }
.out-file { color: var(--t1); }
.lintline { display: grid; grid-template-columns: auto 1.6ch minmax(0, 1fr); gap: 0 10px; align-items: baseline; padding: 2px 0; color: var(--t1); }
.lintline .loc { color: var(--t3); white-space: nowrap; }
.lintline .m { font-weight: 700; text-align: center; }
.lintline.ok .m { color: var(--lime); } .lintline.warn .m { color: var(--amber); } .lintline.bad .m { color: var(--red); } .lintline.info .m, .lintline.dim .m { color: var(--t3); }
.lintline .sub { color: var(--t2); }
.lintline.dim { color: var(--t3); }
.summary-line { display: flex; flex-wrap: wrap; gap: 4px 18px; padding: 10px 0 0; font-weight: 600; }
.summary-line .e { color: var(--red); } .summary-line .w { color: var(--amber); } .summary-line .p { color: var(--lime); } .summary-line .z { color: var(--t3); font-weight: 400; }
.sec-t { color: var(--t3); font-size: 11.5px; letter-spacing: .06em; text-transform: uppercase; margin: 16px 0 6px; }
.sec-t:first-child { margin-top: 0; }

/* activity rows */
.rows { list-style: none; }
.arow { display: grid; grid-template-columns: 2ch minmax(0, 1fr) auto; gap: 10px; align-items: baseline; padding: 7px 14px; border-bottom: 1px solid var(--line); color: var(--t2); }
a.arow:hover { background: var(--row); }
.arow .am { color: var(--t3); text-align: center; font-weight: 700; }
.arow .am.ok { color: var(--lime); } .arow .am.warn { color: var(--amber); } .arow .am.bad { color: var(--red); }
.arow .at { min-width: 0; display: grid; }
.arow .tt { color: var(--t1); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.arow .ts { color: var(--t3); font-size: 11.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.arow .aa { display: flex; gap: 10px; align-items: baseline; white-space: nowrap; font-size: 12px; }
.arow .aa b { color: var(--lime); font-weight: 600; }
.arow .tx { color: var(--t2); }
.arow .tx:hover { color: var(--lime); }
.vchip { white-space: nowrap; }
.vchip.green { color: var(--lime); } .vchip.yellow { color: var(--amber); } .vchip.red { color: var(--red); } .vchip.gray { color: var(--t3); }

/* key value grid */
.kv { display: grid; grid-template-columns: repeat(var(--n, 2), minmax(0, 1fr)); }
.kv > div { padding: 10px 14px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); min-width: 0; }
.kv dt { font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--t3); }
.kv dd { color: var(--t1); margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kv dd a { color: var(--lime); }

/* the terminal log of a signed action */
.term { border: 1px solid var(--line); background: var(--bg); padding: 12px 14px; font-size: 12.5px; }
.term .ll { gap: 4px; }
.trail p { color: var(--t1); white-space: pre; }
.trail .who { color: var(--amber); }
.trail .arr { color: var(--t3); }
.cursor { display: inline-block; width: .6em; height: 1.05em; background: var(--lime); vertical-align: -.15em; margin-left: 3px; animation: blink 1s steps(1) infinite; }

/* ---- the wordmark ---- */
.wordmark { width: 100%; max-width: 540px; height: auto; margin: 0 0 14px; }
.wordmark .off { fill: var(--line); }
.wordmark .on circle { fill: var(--lime); animation: light .5s ease-out both; animation-delay: calc(var(--c) * 55ms + 150ms); }
.wordmark .cur circle { fill: var(--lime); animation: blink 1.1s steps(1) infinite; animation-delay: 1.5s; }

/* ---- home: the console ---- */
.console { display: grid; grid-template-columns: minmax(0, 1fr); }
.console > section { min-width: 0; border-bottom: 1px solid var(--line); }
.hero { padding: 18px var(--gut) 22px; }
.hero h1 { font-size: 17px; line-height: 1.45; font-weight: 700; color: var(--t1); letter-spacing: -.01em; }
.hero h1 .ps { color: var(--lime); }
.hero .lead { color: var(--t2); margin-top: 10px; max-width: 86ch; }
.hero .lead b { color: var(--t1); }
.statline { margin-top: 12px; color: var(--t3); }
.statline b { color: var(--t1); font-weight: 600; }
.statline b.lime { color: var(--lime); }
.ca-box { display: flex; align-items: stretch; margin-top: 14px; border: 1px solid var(--line2); min-height: 40px; }
.ca-box .k { display: flex; align-items: center; padding: 0 12px; color: var(--t3); border-right: 0; white-space: nowrap; }
.ca-box .v { display: flex; align-items: center; flex: 1; min-width: 0; padding-right: 10px; color: var(--t1); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ca-box button { padding: 0 16px; border-left: 1px solid var(--line2); color: var(--t2); }
.ca-box button:hover { color: var(--t1); background: var(--row); }
.pot { margin-top: 12px; }
.pot .ps { color: var(--lime); }
.pot b.lime { color: var(--lime); }
.hero .btns { margin-top: 16px; }
.manlink { display: inline-flex; gap: 8px; margin-left: 8px; color: var(--t1); }
.manlink .ps { color: var(--lime); }
.manlink span:last-child { color: var(--t3); }
.manlink:hover span:last-child { color: var(--t1); }
.hero .cmd { margin-top: 16px; }
.result { margin-top: 14px; }

/* the live pane */
.live { display: flex; flex-direction: column; min-height: 0; min-width: 0; background: var(--pane); }
.live-h { display: flex; align-items: center; gap: 10px; height: 34px; padding: 0 12px; border-bottom: 1px solid var(--line); font-size: 12.5px; white-space: nowrap; overflow: hidden; color: var(--t3); flex: none; }
.live-h .step { color: var(--t2); padding: 0 4px; font-size: 14px; line-height: 1; }
.live-h .step:hover { color: var(--lime); }
.live-h .pos { color: var(--t3); min-width: 4ch; text-align: center; }
.live-h .hn { color: var(--amber); }
.live-h .dom { color: var(--t2); overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.live-h .open { margin-left: auto; color: var(--t1); flex: none; }
.live-h .open:hover { color: var(--lime); }
.stage { position: relative; overflow: hidden; background: #000; aspect-ratio: 16 / 10; flex: none; }
.stage img.shot { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top center; max-width: none; filter: brightness(.66) saturate(.6) contrast(1.05); transition: opacity .45s; }
.stage img.shot.off { opacity: 0; }
.stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; }
.stage .idle { position: absolute; inset: 0; display: grid; place-items: center; color: var(--t3); text-align: center; padding: 20px; font-size: 12.5px; }
.stage .idle b { color: var(--t2); font-weight: 500; display: block; }
.stamp { position: absolute; right: 18px; bottom: 18px; padding: 7px 14px 8px; border: 2px solid var(--lime); color: var(--lime); background: rgba(6, 8, 7, .9); font-weight: 700; font-size: 17px; letter-spacing: -.01em; transform: rotate(-4deg); transform-origin: 100% 100%; white-space: nowrap; pointer-events: none; }
.stamp.amber { border-color: var(--amber); color: var(--amber); }
.stamp.left { right: auto; left: 18px; transform-origin: 0 100%; }
.stamp.gray { border-color: var(--t3); color: var(--t2); font-size: 13px; font-weight: 500; }
.stamp small { display: block; font-size: 10.5px; font-weight: 400; color: var(--t2); letter-spacing: .02em; margin-top: 1px; }
.stamp.in { animation: stamp .42s cubic-bezier(.2, 1.6, .4, 1) both; }
.live-cap { display: flex; gap: 8px; align-items: baseline; padding: 8px 12px; border-top: 1px solid var(--line); font-size: 12.5px; color: var(--t2); white-space: nowrap; overflow: hidden; flex: none; }
.live-cap .hn { color: var(--amber); }
.live-cap .arr { color: var(--t3); }
.live-cap span:last-child { overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.tail { border-top: 1px solid var(--line); padding: 8px 12px 10px; font-size: 12px; min-height: 0; overflow: hidden; flex: 1 1 auto; }
.tail .tp { display: flex; justify-content: space-between; gap: 10px; color: var(--t1); margin-bottom: 4px; white-space: nowrap; }
.tail .tp .ps { color: var(--lime); }
.tail .tp span:last-child { color: var(--t3); }
.log { list-style: none; font-size: 12px; line-height: 1.62; }
.log li { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--t2); }
.log li > span + span { margin-left: 1ch; }
.log .ts { color: var(--t3); }
.log .who { color: var(--amber); }
.log .meth { color: var(--t2); }
.log .ok { color: var(--lime); } .log .wn { color: var(--amber); } .log .er { color: var(--red); }
.log .host { color: var(--t1); }
.log .path { color: var(--t2); margin-left: 0 !important; }
.log .own { color: var(--lime); } .log .third { color: var(--t3); }
.log .cnt:empty { display: none; } .log .cnt { color: var(--amber); margin-left: .6em; }
.log .mkv { color: var(--lime); font-weight: 700; } .log .mkv.amber { color: var(--amber); }
.log .txt { color: var(--t1); }
.log .money { color: var(--lime); }
.log li.new { animation: rowin 1.4s ease-out; }
.log li.typing .path::after { content: '\2588'; color: var(--lime); margin-left: 2px; animation: blink .7s steps(1) infinite; }
.glog { padding: 10px 14px; overflow: hidden; }

.htop { padding: 12px 14px 0; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 4px 28px; }
.htop .tasks { align-self: start; }
.hunters-tbl { padding-top: 10px; }
.hlist { display: none; }

/* ---- generic page bits ---- */
.cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 16px; }
.grow { flex: 1; min-height: 0; }
.spacer { flex: 1; }
.head-line { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 20px; margin-bottom: 14px; }
.big { font-size: 24px; font-weight: 600; letter-spacing: -.01em; color: var(--t1); line-height: 1.35; }
.big .lime { color: var(--lime); }
.body-t { color: var(--t2); max-width: 70ch; }
.body-t b { color: var(--t1); }
.calc { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; color: var(--t2); }
.calc .ps { color: var(--lime); }
.calc .num { display: inline-flex; align-items: stretch; border: 1px solid var(--line2); }
.calc .num button { width: 32px; color: var(--t2); }
.calc .num button:hover { color: var(--lime); background: var(--row); }
.calc .num span { min-width: 36px; display: grid; place-items: center; border-left: 1px solid var(--line2); border-right: 1px solid var(--line2); color: var(--t1); }
.calc .est { color: var(--lime); font-weight: 600; }
.rules { display: grid; gap: 6px; }
.rules p { color: var(--t3); }
.rules p b { color: var(--t2); font-weight: 600; }
.price-line { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; padding: 12px 0 4px; }
.price-line .v { font-size: 22px; font-weight: 600; color: var(--lime); }
.price-line .s { color: var(--t3); }

/* the hunter card art */
.hart { border: 1px solid var(--line); background: var(--bg); }
.hart img { width: 100%; height: auto; image-rendering: auto; }
.sprite-sm { width: 22px; height: 22px; display: inline-block; vertical-align: middle; image-rendering: pixelated; }

/* bars per share (treasury split) */
.shares { display: grid; gap: 4px; }
.share { display: grid; grid-template-columns: 13ch minmax(0, 1fr) 6ch; gap: 12px; align-items: center; font-size: 12.5px; }
.share .nm { color: var(--t1); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.share .pc { color: var(--lime); text-align: right; }
.share .meter, td .meter { grid-template-columns: auto minmax(0, 1fr) auto; }
.share .meter .mk, td .meter .mk { display: none; }
.grp { color: var(--t3); font-size: 11.5px; margin: 10px 0 2px; }
.grp:first-child { margin-top: 0; }

/* the man page */
.man { max-width: 92ch; }
.man h2 { font-size: 13px; font-weight: 700; color: var(--t1); margin: 26px 0 8px; letter-spacing: .02em; scroll-margin-top: 70px; }
.man h2:first-child { margin-top: 0; }
.man h3 { font-size: 13px; color: var(--lime); font-weight: 600; margin: 14px 0 4px 4ch; scroll-margin-top: 70px; }
.man p, .man .ll, .man pre, .man .tblm { margin-left: 4ch; color: var(--t2); }
.man p + p { margin-top: 8px; }
.man p b { color: var(--t1); }
.man .ll { margin-top: 8px; margin-bottom: 8px; }
.man pre { font: inherit; color: var(--t2); white-space: pre-wrap; border-left: 1px solid var(--line2); padding: 4px 0 4px 14px; margin-top: 10px; margin-bottom: 10px; }
.man pre b { color: var(--lime); font-weight: 600; }
.man .tblm { border-collapse: collapse; margin-top: 8px; margin-bottom: 8px; }
.man .tblm td { padding: 2px 16px 2px 0; vertical-align: top; }
.man .tblm td:first-child { color: var(--lime); white-space: nowrap; }
.man a { color: var(--lime); }
.man-head { display: flex; justify-content: space-between; gap: 12px; color: var(--t3); border-bottom: 1px solid var(--line); padding-bottom: 8px; margin-bottom: 18px; font-size: 12px; }
.man-toc { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 12px; margin-bottom: 22px; }
.man-toc a { color: var(--t2); }
.man-toc a:hover { color: var(--lime); }

/* proof, badge */
.code { display: block; font-size: 11.5px; color: var(--t2); background: var(--bg); border: 1px solid var(--line); padding: 8px 10px; white-space: pre-wrap; word-break: break-all; }
.badge-prev { padding: 12px; border: 1px solid var(--line); display: inline-block; background: var(--bg); }

/* admin */
.tree td { white-space: normal; word-break: break-all; }

/* toast, modal, skeleton */
.toast { position: fixed; left: 50%; bottom: 40px; transform: translate(-50%, 12px); z-index: 60; background: var(--white); color: var(--bg); padding: 8px 14px; font-weight: 600; font-size: 12.5px; opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; max-width: calc(100vw - 32px); }
.toast.on { opacity: 1; transform: translate(-50%, 0); }
.toast.error { background: var(--red); color: var(--bg); }
.modal { position: fixed; inset: 0; z-index: 60; background: rgba(0, 0, 0, .7); display: grid; place-items: center; padding: 16px; }
.modal-box { width: 100%; max-width: 360px; background: var(--pane); border: 1px solid var(--line2); padding: 18px; display: grid; gap: 10px; }
.modal-box h3 { font-size: 13px; font-weight: 600; color: var(--t1); }
.sk { display: block; height: 12px; background: var(--row); animation: skel 1.4s ease-in-out infinite; }
.sk.s { width: 45%; } .sk.l { width: 85%; } .sk.h { height: 22px; width: 50%; }
.skel { display: grid; gap: 10px; padding: 16px; }
.spin { display: inline-block; width: 1ch; color: var(--lime); }

@keyframes blink { 50% { opacity: 0; } }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }
@keyframes light { from { opacity: .08; } to { opacity: 1; } }
@keyframes stamp { from { opacity: 0; transform: rotate(-4deg) scale(1.35); } to { opacity: 1; transform: rotate(-4deg) scale(1); } }
@keyframes rowin { from { background-color: rgba(196, 255, 77, .1); } to { background-color: transparent; } }
@keyframes skel { 50% { opacity: .45; } }

/* ---- desktop: the home page is the console, panes fill the viewport ---- */
@media (min-width: 1100px) {
  body.fit { height: 100vh; height: 100dvh; overflow: hidden; }
  body.fit main.console { min-height: 0; display: grid; }
  .console { flex: 1; min-height: 0; grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr); grid-template-rows: minmax(0, 2.9fr) minmax(0, 1fr); }
  .console > section { border-bottom: 1px solid var(--line); min-height: 0; overflow: hidden; display: flex; flex-direction: column; }
  .console > .c-hero { grid-area: 1 / 1; overflow-y: auto; border-right: 1px solid var(--line); }
  .console > .c-live { grid-area: 1 / 2; }
  .console > .c-hunters { grid-area: 2 / 1; border-right: 1px solid var(--line); border-bottom: 0; }
  .console > .c-log { grid-area: 2 / 2; border-bottom: 0; }
  .c-live .stage { aspect-ratio: auto; flex: 1 1 auto; min-height: 180px; }
  .c-live .tail { flex: 0 0 auto; height: 116px; }
  .c-hunters .tbl-wrap { flex: 1; min-height: 0; }
  .c-hunters > .pane-h { display: none; }
  .c-hunters .tbl td { padding-top: 3px; padding-bottom: 3px; }
  .c-hunters .tbl th { padding-top: 4px; padding-bottom: 4px; }
  .c-log .glog { flex: 1; min-height: 0; }
}

/* below the console width the panes stack */
@media (max-width: 1099px) {
  .cols2, .cols2.even { grid-template-columns: minmax(0, 1fr); }
  .cols2 > * + * { margin-left: 0; margin-top: -1px; }
  .tabs a { padding: 0 11px; }
  .top-r .mcap { display: none; }
  .console > .c-live { order: -1; }
  .c-hunters .tbl-wrap { max-height: 460px; }
  .glog { max-height: 420px; }
}

/* ---- phone: an app with a bottom tab bar ---- */
@media (max-width: 759px) {
  :root { --gut: 16px; --top: 50px; }
  .tabs { display: none; }
  .logo { width: 50px; }
  .cell { padding: 0 11px; font-size: 12px; }
  .top-r { flex: 1; min-width: 0; justify-content: flex-end; }
  .top-r .ca { min-width: 0; flex: 1 1 auto; justify-content: center; }
  .top-r .ca .k { display: none; }
  .top-r .ca .v { overflow: hidden; text-overflow: ellipsis; }
  .menu-btn { display: grid; }
  .status { display: none; }
  .tabbar { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; background: var(--bg); border-top: 1px solid var(--line2); padding-bottom: env(safe-area-inset-bottom); }
  .tabbar a { display: grid; justify-items: center; gap: 3px; padding: 8px 0 7px; color: var(--t3); font-size: 11px; position: relative; }
  .tabbar a svg { width: 20px; height: 20px; }
  .tabbar a[aria-current="page"] { color: var(--lime); }
  .tabbar a[aria-current="page"]::before { content: '\25cf'; position: absolute; top: -6px; font-size: 9px; color: var(--lime); }
  .tabbar .cnt { position: absolute; top: 4px; left: calc(50% + 8px); background: var(--amber); color: var(--bg); font-size: 9.5px; font-weight: 700; padding: 0 4px; line-height: 14px; }
  body { padding-bottom: calc(58px + env(safe-area-inset-bottom)); }
  .nfa-m { display: block; padding: 16px var(--gut) 24px; color: var(--t3); font-size: 11.5px; }
  .page { padding-top: 18px; }
  .prompt { font-size: 13px; }
  .hero h1 { font-size: 17px; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stat:nth-child(2n) { border-right: 0; }
  .stat { border-bottom: 1px solid var(--line); }
  .stat .v { font-size: 19px; }
  .kv { --n: 2 !important; }
  .htop { grid-template-columns: minmax(0, 1fr); }
  .c-hunters .tbl-wrap { display: none; }
  .hlist { display: block; list-style: none; padding: 4px 0; }
  .hlist li a { display: grid; grid-template-columns: 10px minmax(0, auto) minmax(0, 1fr) auto; align-items: baseline; gap: 10px; padding: 9px var(--gut); border-bottom: 1px solid var(--line); }
  .hlist .dot { align-self: center; }
  .hlist .nm { color: var(--amber); white-space: nowrap; }
  .hlist .tg { color: var(--t3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .hlist .n { color: var(--t1); }
  .flag { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .share { grid-template-columns: 10ch minmax(0, 1fr) 5ch; gap: 8px; }
  .meter { grid-template-columns: 3ch auto minmax(0, 1fr) auto; }
  .ca-box .k { display: none; }
  .ca-box .v { padding-left: 12px; }
  .stamp { right: 10px; bottom: 10px; font-size: 14px; padding: 5px 10px 6px; }
  .stamp.left { left: 10px; right: auto; }
  .live-h .open span { display: none; }
  .hide-s { display: none; }
  .tail { max-height: 120px; }
  .man p, .man .ll, .man pre, .man .tblm, .man h3 { margin-left: 0; }
  .toast { bottom: 76px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001s !important; animation-iteration-count: 1 !important; transition-duration: .001s !important; }
  .wordmark .on circle { animation: none; }
  .dot.pulse, .cursor, .ll li.now > span:last-child::after { animation: none; }
}
