/* PonsBot — "order ticket" design system.
   Hard 2px rules, no blur, one offset shadow, indigo signal, semantic red/green
   reserved exclusively for money. Nothing decorative is allowed to use them. */

:root {
  /* Black and white, with Robinhood green used the way the artwork uses it: as a
     light source, not a fill. Almost everything is monochrome, so the few green
     things — live state, gains, the primary action — are unmistakable. */
  --bg:        #000000;
  --panel:     #0E0E0E;
  --panel-2:   #151515;   /* recessed: stripes, inputs, code */
  --panel-3:   #1D1D1D;   /* raised within a panel */
  --deep:      #050505;

  --ink:       #FFFFFF;
  --ink-80:    #DCDCDC;
  --ink-60:    #B0B0B0;
  --ink-30:    #8C8C8C;
  --rule:      #303030;
  --edge:      #444444;

  --signal:    #00C805;   /* Robinhood green */
  --signal-glow: #3DFF6E; /* the artwork's emissive green, for light only */
  --signal-dim:#1F9A3A;
  --signal-ink:#00C805;
  --tint:      rgba(0,200,5,.08);
  --amber:     #C9A227;

  --gain:      #00C805;
  --loss:      #FF5A4E;
  --warn:      #C9A227;
  --warn-bg:   rgba(201,162,39,.08);

  --paper:     var(--bg);
  --paper-on:  #FFFFFF;
  --paper-ink: #000000;

  /* Depth on black comes from light, not shadow: a hairline that catches the top
     edge, and an inner rim. Drop shadows are invisible against #000. */
  --e1: 0 0 0 1px var(--rule), inset 0 1px 0 rgba(255,255,255,.04);
  --e2: 0 0 0 1px var(--edge), inset 0 1px 0 rgba(255,255,255,.06), 0 18px 40px rgba(0,0,0,.6);
  --e3: 0 0 0 1px var(--edge), inset 0 1px 0 rgba(255,255,255,.08), 0 30px 70px rgba(0,0,0,.75);
  --shadow: var(--e1);

  --display: "Instrument Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --body: "Instrument Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --gut: clamp(20px, 4vw, 56px);
  --ease: cubic-bezier(.22, .68, .36, 1);
  --ease-soft: cubic-bezier(.32, .72, .28, 1);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 90px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
}

/* Faint ledger ruling — the page is a blotter, not a canvas. */
/* Faint scanline ruling — the page is an instrument readout, not a document. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(760px 520px at 12% -10%, rgba(0,0,0,.55), transparent 62%),
    radial-gradient(680px 460px at 92% 4%, rgba(10,155,87,.07), transparent 60%),
    radial-gradient(900px 600px at 50% 108%, rgba(0,0,0,.55), transparent 62%);
  pointer-events: none;
  z-index: 0;
}

a { color: var(--signal-ink); text-underline-offset: 3px; }
a:hover { color: var(--signal); }
:focus-visible { outline: 3px solid var(--signal); outline-offset: 2px; }

h1, h2, h3, h4 {
  font-family: var(--display); font-weight: 400; letter-spacing: -.015em;
  line-height: 1.04; margin: 0 0 .4em; color: var(--ink);
}
h1 { font-size: clamp(38px, 6.4vw, 76px); letter-spacing: -.028em; }
h2 { font-size: clamp(27px, 3.6vw, 44px); letter-spacing: -.022em; }
h3 { font-family: var(--body); font-weight: 600; letter-spacing: -.01em; font-size: 17px; }
h4 { font-family: var(--body); font-weight: 600; letter-spacing: 0; }

/* Numbers are instrumentation: tabular, tight, never reflowing as they tick. */
.stat .v, .bignum, .num, .mono, .poscard .mult, .hero-nums .v {
  font-variant-numeric: tabular-nums; font-feature-settings: "tnum" 1, "ss02" 1;
}
h1 { font-size: clamp(34px, 6vw, 62px); }
h2 { font-size: clamp(24px, 3.4vw, 34px); margin-top: 0; }
h3 { font-size: 19px; letter-spacing: -.01em; }
p { margin: 0 0 1em; max-width: 68ch; }
code { font-family: var(--mono); font-size: .88em; background: var(--tint); color: var(--signal-ink); padding: 1px 5px; border-radius: 3px; }

.wrap { position: relative; z-index: 1; max-width: 1320px; margin: 0 auto; padding: 0 var(--gut); }
.mono { font-family: var(--mono); }
.tabular { font-variant-numeric: tabular-nums; }

/* ── ticket chrome ─────────────────────────────────────────────────────── */
.topbar {
  position: sticky; top: 0; z-index: 30;
  background: rgba(10,10,10,.82); backdrop-filter: saturate(180%) blur(18px);
  color: var(--ink); border-bottom: 1px solid var(--rule);
}
.topbar .wrap { display: flex; align-items: center; gap: 20px; height: 62px; }
.brand { font-family: var(--display); font-weight: 800; font-size: 20px; letter-spacing: -.03em; color: var(--paper); text-decoration: none; }
.wordmark span { color: var(--signal); }
.topnav { margin-left: auto; display: flex; gap: 18px; font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: .1em; }
.topnav a { color: var(--paper); opacity: .72; text-decoration: none; }
.topnav a:hover, .topnav a[aria-current="page"] { opacity: 1; color: #A99BFF; }

.pill {
  font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: .1em;
  border: 2px solid currentColor; border-radius: 999px; padding: 2px 10px; display: inline-flex; align-items: center; gap: 6px;
}
.pill.live { color: var(--signal); }
.pill.dry { color: var(--warn); }
.dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.dot.pulse { animation: pulse 1.8s ease-in-out infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .25; } }

/* ── panels ───────────────────────────────────────────────────────────── */
.panel {
  background: var(--panel); border: 0; border-radius: 16px; box-shadow: var(--e1);
  overflow: hidden; transition: box-shadow .22s ease, transform .22s ease;
}
.panel:hover { box-shadow: var(--e2); }
.panel + .panel { margin-top: 22px; }
.panel-hd {
  display: flex; align-items: baseline; gap: 12px;
  padding: 13px 16px; border-bottom: 1px solid var(--rule);
  background: linear-gradient(180deg, var(--panel-3), var(--panel));
  font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: .12em;
}
.panel-hd .sub { margin-left: auto; color: var(--ink-60); letter-spacing: .06em; text-transform: none; }
.panel-bd { padding: 16px; }

.eyebrow {
  font-family: var(--mono); font-size: 11.5px; letter-spacing: .18em; text-transform: uppercase;
  color: var(--amber); margin-bottom: 12px; display: flex; align-items: center; gap: 12px;
}
.eyebrow::after { content: ""; flex: 1; height: 1px; background: var(--rule); }

.note, .warnbox {
  border-left: 3px solid var(--signal); background: var(--tint);
  padding: 13px 16px; margin: 18px 0; font-size: 15px; border-radius: 0 8px 8px 0;
}
.note p, .warnbox p { margin: 0; max-width: none; }
.warnbox { border-left-color: var(--warn); background: var(--warn-bg); }
.dangerbox { border-left: 3px solid var(--loss); background: rgba(255,92,108,.09); padding: 13px 16px; margin: 18px 0; border-radius: 0 8px 8px 0; }

/* ── tables ───────────────────────────────────────────────────────────── */
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--rule); vertical-align: top; }
th { font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: .1em; color: var(--ink-60); border-bottom: 1px solid var(--edge); }
tbody tr:hover { background: var(--panel-2); }
td.num { font-family: var(--mono); font-variant-numeric: tabular-nums; white-space: nowrap; }
.gain { color: var(--gain); }
.loss { color: var(--loss); }

pre {
  background: #111111; color: #E6E6E6; padding: 16px 18px; overflow-x: auto;
  font-family: var(--mono); font-size: 13px; line-height: 1.6;
  border: 0; border-radius: 14px; box-shadow: var(--e2);
}
pre .k { color: #A9B4CC; }
pre .s { color: #7FE3FF; }
pre .c { color: #8A8A8A; }

/* ── the exit ladder — signature element ──────────────────────────────── */
/* Four lanes: label | track | value | bag. The bag gets its own gutter so it can
   never sit on top of the rung text, which is what happened when it was absolutely
   positioned over the full width. */
.ladder {
  --h: 260px; --lane-label: 88px; --lane-bag: 54px; --lane-val: 66px;
  position: relative; height: var(--h); margin: 10px 0 6px;
  padding-right: calc(var(--lane-bag) + 14px);
}
.ladder .rail {
  position: absolute; left: var(--lane-label); top: 0; bottom: 0;
  width: 1px; background: var(--edge);
}
.rung {
  position: absolute; left: 0; right: calc(var(--lane-bag) + 14px);
  display: flex; align-items: center; gap: 10px; transform: translateY(-50%);
}
.rung .label {
  width: var(--lane-label); flex: 0 0 var(--lane-label); text-align: right;
  font-family: var(--mono); font-size: 10.5px; letter-spacing: .06em;
  text-transform: uppercase; color: var(--ink-60);
}
.rung .line { flex: 1 1 auto; min-width: 0; height: 1px; background: var(--rule); }
.rung .val {
  width: var(--lane-val); flex: 0 0 var(--lane-val); text-align: right;
  font-family: var(--mono); font-size: 10.5px; color: var(--ink-30);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.rung.tp .line { background: var(--signal-dim); }
.rung.tp .val { color: var(--signal-dim); }
.rung.stop .line { background: rgba(232,106,106,.5); }
.rung.stop .val { color: var(--loss); }
.rung.entry .line { background: var(--ink-30); }
.rung.filled .label { color: var(--ink); }
.rung.filled .line { height: 2px; background: var(--signal); }
.rung.filled .val { color: var(--signal); }

.marker {
  position: absolute; left: calc(var(--lane-label) - 9px); width: 18px; height: 18px;
  transform: translateY(-50%); z-index: 2;
}
.marker b {
  position: absolute; inset: 0; display: block;
  background: radial-gradient(circle at 30% 30%, #8A91A2, var(--signal));
  border: 2px solid #fff; border-radius: 50%; box-shadow: var(--e2);
}
.marker .tag {
  position: absolute; left: 26px; top: 50%; transform: translateY(-50%); white-space: nowrap;
  background: var(--ink); color: #000; font-family: var(--mono); font-size: 10.5px;
  padding: 3px 8px; border-radius: 6px; font-weight: 500; box-shadow: var(--e1);
}

/* The bag: a slim capacity gauge in its own lane, filling from the bottom. */
.bag {
  position: absolute; right: 0; top: 14px; bottom: 14px; width: var(--lane-bag);
  border: 1px solid var(--edge); border-radius: 6px; background: var(--panel-2);
  overflow: hidden;
}
.bag i {
  position: absolute; left: 0; right: 0; bottom: 0; display: block;
  background: linear-gradient(180deg, rgba(0,0,0,.55), rgba(0,0,0,.55));
  border-top: 2px solid var(--signal);
}
.bag span {
  position: absolute; left: 0; right: 0; top: 6px; text-align: center;
  font-family: var(--mono); font-size: 9.5px; letter-spacing: .04em;
  color: var(--ink-60); white-space: nowrap; z-index: 2;
}

/* ── dashboard grid ───────────────────────────────────────────────────── */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(168px, 1fr)); gap: 0; border: 0; border-radius: 18px; background: var(--panel); box-shadow: var(--e2); overflow: hidden; }
.stat { padding: 15px 16px; border-right: 1px solid var(--rule); }
.stat:last-child { border-right: 0; }
.stat .k { font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: .1em; color: var(--ink-60); }
.stat .v { font-family: var(--display); font-weight: 800; font-size: 30px; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.stat .s { font-family: var(--mono); font-size: 11px; color: var(--ink-60); }

.cols { display: grid; grid-template-columns: 1.05fr .95fr; gap: 22px; margin-top: 22px; align-items: start; }
.feed { max-height: 560px; overflow-y: auto; }
.feed-row { display: flex; gap: 12px; padding: 10px 16px; border-bottom: 1px solid var(--rule); align-items: baseline; }
.feed-row:hover { background: var(--panel-2); }
.feed-row .sym { font-family: var(--display); font-weight: 700; }
.feed-row .meta { font-family: var(--mono); font-size: 11px; color: var(--ink-60); margin-left: auto; text-align: right; }
.tag {
  font-family: var(--mono); font-size: 10px; text-transform: uppercase; letter-spacing: .08em;
  border: 1.5px solid currentColor; padding: 0 5px; border-radius: 2px;
}
.tag.bought { color: var(--gain); }
.tag.skipped { color: var(--ink-30); }
.tag.pending { color: var(--warn); }

.poscard { border-bottom: 1px solid var(--rule); padding: 14px 16px; display: grid; grid-template-columns: 1fr 150px; gap: 14px; }
.poscard:last-child { border-bottom: 0; }
.poscard .hd { display: flex; align-items: baseline; gap: 10px; }
.poscard .mult { font-family: var(--display); font-weight: 800; font-size: 26px; font-variant-numeric: tabular-nums; }
.kv { font-family: var(--mono); font-size: 11.5px; color: var(--ink-60); display: flex; gap: 14px; flex-wrap: wrap; margin-top: 4px; }

.bars { display: grid; gap: 6px; }
.bar { display: grid; grid-template-columns: 150px 1fr 52px; align-items: center; gap: 10px; font-family: var(--mono); font-size: 11.5px; }
.bar .t { height: 12px; background: var(--panel-2); border: 1px solid var(--edge); border-radius: 3px; position: relative; overflow: hidden; }
.bar .t i { position: absolute; top: 0; bottom: 0; background: var(--signal); }
.bar .t i.neg { background: var(--loss); }

.log { font-family: var(--mono); font-size: 12px; max-height: 260px; overflow-y: auto; }
.log div { padding: 6px 16px; border-bottom: 1px solid var(--rule); display: flex; gap: 10px; }
.log .t { color: var(--ink-30); }
.log .k { color: var(--signal-dim); }
.log .warn { color: var(--warn); }
.log .error { color: var(--loss); }

.empty { padding: 30px 16px; text-align: center; color: var(--ink-30); font-family: var(--mono); font-size: 13px; }

/* ── docs layout ──────────────────────────────────────────────────────── */
.docs { display: grid; grid-template-columns: 232px 1fr; gap: 44px; padding: 38px 0 90px; }
.rail { position: sticky; top: 86px; align-self: start; }
.rail ol { list-style: none; margin: 0; padding: 0; counter-reset: step; }
.rail li { counter-increment: step; }
.rail a {
  display: grid; grid-template-columns: 26px 1fr; gap: 8px; padding: 7px 0;
  font-family: var(--mono); font-size: 12px; letter-spacing: .04em; text-transform: uppercase;
  color: var(--ink-60); text-decoration: none; border-bottom: 1px solid var(--rule);
}
.rail a::before { content: counter(step, decimal-leading-zero); color: var(--ink-30); }
.rail a:hover, .rail a.on { color: var(--ink); }
.rail a.on::after { content: ""; }
.rail a.on::before { color: var(--amber); }
.doc section { padding-bottom: 46px; }
.doc section + section { border-top: 1px solid var(--edge); padding-top: 34px; }
.lede { font-size: 19px; line-height: 1.5; color: var(--ink-60); max-width: 62ch; }
.hero { padding: 54px 0 30px; border-bottom: 1px solid var(--edge); }
.hero h1 { max-width: 16ch; }
.hero .kicker { font-family: var(--mono); font-size: 12px; letter-spacing: .18em; text-transform: uppercase; color: var(--signal-ink); }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.deflist { display: grid; grid-template-columns: 168px 1fr; gap: 2px 16px; font-size: 14.5px; }
.deflist dt { font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-60); padding-top: 3px; }
.deflist dd { margin: 0 0 8px; }

footer { border-top: 1px solid var(--edge); margin-top: 40px; padding: 22px 0 50px; font-family: var(--mono); font-size: 12px; color: var(--ink-60); }
footer .wrap { display: flex; gap: 18px; flex-wrap: wrap; }



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

/* ══ buttons ══════════════════════════════════════════════════════════ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: .1em;
  background: var(--signal); color: #000;
  border: 0; border-radius: 11px;
  padding: 10px 17px; text-decoration: none; font-weight: 500;
  box-shadow: 0 1px 2px rgba(0,0,0,.55), 0 6px 16px rgba(0,0,0,.55);
  transition: transform .12s ease, filter .12s ease, background .12s ease;
}
.btn:hover { color: #000; transform: translateY(-2px); box-shadow: 0 0 0 1px var(--signal), 0 10px 30px rgba(0,200,5,.28); }
.btn:active { transform: translateY(1px); }
.btn.ghost { background: var(--panel); color: var(--ink); box-shadow: var(--e1); }
.btn.ghost:hover { color: var(--signal-ink); background: var(--panel); box-shadow: var(--e2); }
.btn.big { padding: 13px 22px; font-size: 13px; }
.topnav .btn { color: #000; opacity: 1; }
.minibtn {
  margin-left: auto; font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: .08em;
  background: none; border: 0; color: var(--ink-60); cursor: pointer; padding: 0;
}
.minibtn:hover { color: var(--signal-ink); }
.micro { font-size: 11.5px; color: var(--ink-60); line-height: 1.5; }
.bignum { font-family: var(--display); font-weight: 800; font-size: 34px; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }

/* ══ landing ══════════════════════════════════════════════════════════ */
.hero-lp { border-bottom: 2px solid var(--ink); padding: 46px 0 40px; }
.hero-lp-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 40px; align-items: start; }
.hero-lp h1 { max-width: 14ch; margin-top: 10px; }
.cta-row { display: flex; gap: 12px; flex-wrap: wrap; margin: 24px 0 14px; }
.hero-card { position: sticky; top: 86px; }
.hero-nums { display: grid; grid-template-columns: 1fr 1fr; }
.hero-nums > div { padding: 14px 16px; border-bottom: 1px solid var(--rule); }
.hero-nums > div:nth-child(odd) { border-right: 1px solid var(--rule); }
.hero-nums .k { display: block; font-family: var(--mono); font-size: 10.5px; text-transform: uppercase; letter-spacing: .1em; color: var(--ink-60); }
.hero-nums .v { display: block; font-family: var(--display); font-weight: 800; font-size: 26px; font-variant-numeric: tabular-nums; }
.hero-feed { max-height: 210px; overflow-y: auto; }
.txline { display: flex; align-items: baseline; gap: 9px; padding: 8px 16px; border-bottom: 1px solid var(--rule); text-decoration: none; color: var(--ink); }
.txline:hover { background: var(--panel-2); }
.txline .sym { font-family: var(--display); font-weight: 700; font-size: 14px; }
.txline .meta { margin-left: auto; font-family: var(--mono); font-size: 10.5px; color: var(--ink-60); }

.band { padding: 46px 0; }
.band + .band { border-top: 2px solid var(--ink); }
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 0; border: 0; border-radius: 18px; background: var(--panel); box-shadow: var(--e2); overflow: hidden; }
.steps article { padding: 20px; border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.steps article .n { font-family: var(--mono); font-size: 11px; letter-spacing: .14em; color: var(--signal); }
.steps article h3 { margin: 6px 0 6px; }
.steps article p { font-size: 14px; margin: 0; color: var(--ink-60); }

.ladder-lp { display: grid; grid-template-columns: 1fr 1fr; gap: 34px; align-items: center; }
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; }
.tile { margin: 0; }
.panel + .tile, .tile + .tile { margin-top: 0; }
.deflist.tight { grid-template-columns: 104px 1fr; font-size: 14px; }

/* ══ app shell ════════════════════════════════════════════════════════ */
.app-wrap { padding: 22px 0 60px; }
.tabs {
  display: flex; gap: 0; margin: 22px 0 0; overflow-x: auto; scrollbar-width: none;
  border: 0; border-radius: 14px; background: var(--panel); box-shadow: var(--e1); padding: 5px;
}
.tabs::-webkit-scrollbar { display: none; }
.tab {
  flex: 1 0 auto; background: none; border: 0; border-radius: 10px; cursor: pointer;
  font-family: var(--mono); font-size: 11.5px; text-transform: uppercase; letter-spacing: .1em;
  color: var(--ink-60); padding: 12px 16px; white-space: nowrap;
}
.tab:last-child { border-right: 0; }
.tab.on { background: var(--ink); color: #000; box-shadow: none; }
.tab .c { font-size: 10px; color: var(--ink-30); margin-left: 4px; }
.tab.on .c { color: #9FBEFF; }
.tabpanel { display: none; margin-top: 22px; }
.tabpanel.on { display: block; }
.explain {
  font-size: 14.5px; color: var(--ink-60); max-width: 74ch; margin: 0 0 16px;
  border-left: 4px solid var(--rule); padding-left: 14px;
}
.explain b { color: var(--ink); font-weight: 600; }

.txrow {
  display: grid; grid-template-columns: 74px 1fr auto 150px; gap: 12px; align-items: center;
  padding: 11px 16px; border-bottom: 1px solid var(--rule); text-decoration: none; color: var(--ink);
}
.txrow:hover { background: var(--panel-2); }
.txrow .who b { font-family: var(--display); font-size: 15px; display: block; }
.txrow .amt { font-family: var(--mono); font-variant-numeric: tabular-nums; font-size: 13px; }
.txrow .meta { text-align: right; font-size: 11px; color: var(--ink-60); }
.feed.tall { max-height: 640px; }
.ladder.mini { --lane-label: 42px; --lane-bag: 26px; --lane-val: 0px; }
.ladder.mini .val { display: none; }
.ladder.mini .marker { width: 14px; height: 14px; left: calc(var(--lane-label) - 7px); }
.ladder.mini .marker .tag { display: none; }
.ladder.mini .bag span { font-size: 8.5px; top: 4px; }
.small { font-size: 12px; }
.kv.loss { color: var(--loss); }
.logpanel { margin-top: 26px; }
.log .k { min-width: 54px; }

/* ══ responsive ═══════════════════════════════════════════════════════ */




/* ══ motion ═══════════════════════════════════════════════════════════ */
/* Reveal behaviour lives in the motion layer at the end of this file. */

@keyframes flashbg {
  0%   { background: var(--tint); box-shadow: inset 0 0 0 2px var(--signal); }
  100% { background: transparent; box-shadow: inset 0 0 0 2px transparent; }
}
.flash { animation: flashbg .9s ease-out; border-radius: 2px; }

@keyframes enterRow {
  from { opacity: 0; transform: translateX(-10px); background: var(--tint); }
  to   { opacity: 1; transform: none; background: transparent; }
}
.enter { animation: enterRow .45s cubic-bezier(.22,.68,.36,1); }

/* live pill and log get a heartbeat so a stalled engine is visible at a glance */
@keyframes tick { 0%,100% { transform: scaleY(1); } 50% { transform: scaleY(.4); } }
.pill.live .dot { animation: pulse 1.6s ease-in-out infinite; }
.pill.dry .dot { animation: pulse 3.2s ease-in-out infinite; }

@keyframes sweep { from { background-position: 200% 0; } to { background-position: -200% 0; } }
.loading {
  background: linear-gradient(90deg, transparent 0%, var(--tint) 50%, transparent 100%);
  background-size: 200% 100%;
  animation: sweep 1.4s linear infinite;
}

/* the marker moving between rungs is the one place motion carries meaning */
.marker { transition: top .7s cubic-bezier(.4,0,.2,1); }
.bag i { transition: height .7s cubic-bezier(.4,0,.2,1); }
.rung .line { transition: opacity .3s ease, height .3s ease; }

.btn, .tab, .txrow, .feed-row, .txline { transition: background .16s ease, color .16s ease, transform .12s ease, box-shadow .12s ease; }
.txrow:hover, .feed-row:hover, .txline:hover { transform: translateX(3px); }

@media (prefers-reduced-motion: reduce) {
  .reveal, .reveal.shown { opacity: 1; transform: none; }
}

/* ══ header, rebuilt ══════════════════════════════════════════════════ */
.topbar .wrap { display: flex; align-items: center; gap: 16px; height: 64px; }
.brand { font-size: 21px; letter-spacing: -.035em; flex: 0 0 auto; }
.topnav { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.topnav a {
  color: var(--ink); opacity: .7; text-decoration: none; padding: 7px 11px;
  font-family: var(--mono); font-size: 11.5px; text-transform: uppercase; letter-spacing: .09em;
  border-radius: 2px;
}
.topnav a:hover { opacity: 1; color: var(--signal-ink); background: var(--tint); }
.topnav a[aria-current="page"] { opacity: 1; color: var(--signal); background: var(--tint); }
.topnav .btn { margin-left: 8px; opacity: 1; }

/* contract address chip */
.ca {
  display: inline-flex; align-items: center; gap: 7px; margin-left: 8px; cursor: pointer;
  background: var(--panel); border: 0; box-shadow: var(--e1);
  color: var(--ink); padding: 7px 12px; border-radius: 10px;
  font-family: var(--mono); font-size: 11px; letter-spacing: .05em;
}
.ca:disabled { cursor: default; opacity: 1; color: var(--ink-30); }
.ca .ca-k { color: var(--signal); font-size: 9.5px; letter-spacing: .14em; }
.ca.live:hover { border-color: var(--signal-dim); background: var(--tint); }
.ca.copied { border-color: var(--signal); color: var(--signal); }

.burger { display: none; background: none; border: 0; cursor: pointer; padding: 8px; margin-left: auto; }
.burger span { display: block; width: 22px; height: 2px; background: var(--ink); margin: 4px 0; border-radius: 2px; transition: transform .2s ease, opacity .2s ease; }
.burger.x span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.burger.x span:nth-child(2) { opacity: 0; }
.burger.x span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* the on-page contract block */
.cablock {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  border: 0; border-radius: 16px; background: var(--panel);
  box-shadow: var(--e2); padding: 18px 20px;
}
.cablock .lab { font-family: var(--mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-60); }
.cablock .val {
  font-family: var(--mono); font-size: clamp(11px, 2.4vw, 16px); word-break: break-all; flex: 1 1 260px;
  color: var(--ink-30);
}
.cablock.has-ca .val { color: var(--ink); }
.cablock .tba { font-family: var(--display); font-weight: 800; font-size: 20px; color: var(--ink-30); }
.cablock.has-ca .tba { display: none; }
.cablock:not(.has-ca) .val, .cablock:not(.has-ca) [data-ca-copy], .cablock:not(.has-ca) [data-ca-link] { display: none; }




/* ══ brand lockup ═════════════════════════════════════════════════════ */
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.logo { display: block; border-radius: 8px; }
.wordmark { font-family: var(--display); font-weight: 800; font-size: 20px; letter-spacing: -.035em; color: var(--ink); }

/* ══ mobile bottom tab bar ════════════════════════════════════════════ */
.tabbar { display: none; }





.hzgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 12px; }
.hzgrid > div { display: flex; flex-direction: column; gap: 3px; }
.hzgrid .k { font-family: var(--mono); font-size: 10px; text-transform: uppercase; letter-spacing: .1em; color: var(--ink-60); }
.hzgrid .v { font-family: var(--mono); font-size: 15px; font-variant-numeric: tabular-nums; color: var(--ink); }


/* ══════════════════════════════════════════════════════════════════════
   RESPONSIVE — one place, one direction, no overrides fighting each other.
   ≤1024  two-column layouts collapse
   ≤860   phone: bottom tab bar, stacked cards, condensed header
   ≤420   very narrow
   ══════════════════════════════════════════════════════════════════════ */

@media (max-width: 1024px) {
  .cols, .grid2, .hero-lp-grid, .ladder-lp { grid-template-columns: 1fr; }
  .docs { grid-template-columns: 1fr; gap: 24px; }
  .rail { position: static; }
  .rail ol { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
  .hero-card { position: static; }
}

@media (max-width: 860px) {
  /* ── header ──────────────────────────────────────────────────────── */
  .topbar .wrap { height: 58px; gap: 10px; }
  .logo { width: 30px; height: 30px; }
  .wordmark { font-size: 18px; }
  .topnav { margin-left: auto; display: flex; align-items: center; gap: 6px; }
  .topnav a:not(.btn):not(.social) { display: none; }   /* links live in the tab bar */
  .burger { display: none !important; }
  .topbar .pill { display: none; }

  /* ── page rhythm ─────────────────────────────────────────────────── */
  .wrap { padding: 0 14px; }
  .app-wrap { padding: 16px 0 40px; }
  .band { padding: 32px 0; }
  h1 { font-size: clamp(30px, 8.5vw, 42px); }
  h2 { font-size: clamp(21px, 5.5vw, 27px); }
  p, .lede { max-width: none; }
  .lede { font-size: 16.5px; }

  /* ── stats: 2 up, no orphan borders ──────────────────────────────── */
  .stats { grid-template-columns: 1fr 1fr; }
  .stat { border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); padding: 12px 14px; }
  .stat:nth-child(2n) { border-right: 0; }
  .stat .v { font-size: 22px; }
  .stat .s { font-size: 10px; }

  /* ── tabs: swipeable, edge to edge ───────────────────────────────── */
  .tabs {
    margin: 16px -14px 0; border-radius: 0; border-left: 0; border-right: 0;
    -webkit-overflow-scrolling: touch;
  }
  .tab { flex: 0 0 auto; padding: 13px 15px; font-size: 11px; }
  .tabpanel { margin-top: 16px; }
  .explain { font-size: 14px; padding-left: 12px; }

  /* ── panels ──────────────────────────────────────────────────────── */
  .panel { border-radius: 10px; }
  .panel-hd { padding: 11px 13px; font-size: 11px; flex-wrap: wrap; gap: 6px; }
  .panel-hd .sub { margin-left: 0; flex-basis: 100%; }
  .panel-bd { padding: 13px; }
  .panel + .panel { margin-top: 16px; }
  .tiles { grid-template-columns: 1fr; gap: 14px; }
  .steps { grid-template-columns: 1fr; }
  .steps article { border-right: 0; padding: 16px; }

  /* ── positions: ladder under the numbers, not squeezed beside them ─ */
  .poscard { grid-template-columns: 1fr; gap: 10px; padding: 13px; }
  .poscard .mult { font-size: 23px; }
  .kv { font-size: 11px; gap: 10px; }
  .ladder.mini { --h: 108px; max-width: 260px; }

  /* ── tables become cards ─────────────────────────────────────────── */
  table.cards thead { display: none; }
  table.cards, table.cards tbody, table.cards tr, table.cards td { display: block; width: 100%; }
  table.cards tr { border-bottom: 1px solid var(--rule); padding: 10px 2px; }
  table.cards td { border: 0; padding: 4px 13px; display: grid; grid-template-columns: 96px 1fr; gap: 10px; align-items: baseline; }
  table.cards td::before {
    content: attr(data-l); font-family: var(--mono); font-size: 10px; text-transform: uppercase;
    letter-spacing: .08em; color: var(--ink-60);
  }
  table.cards td.num { text-align: left; }

  /* plain tables just shrink */
  table:not(.cards) th, table:not(.cards) td { padding: 8px 10px; font-size: 12.5px; }

  /* ── transactions ────────────────────────────────────────────────── */
  .txrow { grid-template-columns: 62px 1fr; gap: 8px 10px; padding: 11px 13px; }
  .txrow .amt { grid-column: 2; justify-self: end; margin-top: -22px; }
  .txrow .meta { grid-column: 1 / -1; text-align: left; font-size: 10.5px; }
  .txrow:hover, .feed-row:hover, .txline:hover { transform: none; }
  .feed-row { padding: 10px 13px; flex-wrap: wrap; }
  .feed-row .meta { margin-left: 0; flex-basis: 100%; text-align: left; margin-top: 3px; }
  .feed.tall, .feed { max-height: 60vh; }

  /* ── contract block ──────────────────────────────────────────────── */
  .cablock { padding: 14px; gap: 10px; }
  .cablock .val { flex-basis: 100%; font-size: 11.5px; }
  .cablock .btn { flex: 1; }

  /* ── bars, logs, health ──────────────────────────────────────────── */
  .bar { grid-template-columns: 104px 1fr 46px; font-size: 10.5px; }
  .log { font-size: 11px; max-height: 220px; }
  .log div { padding: 6px 13px; }
  .hzgrid { grid-template-columns: 1fr 1fr; }
  .cta-row { flex-direction: column; }
  .cta-row .btn { width: 100%; }
  .hero-nums { grid-template-columns: 1fr 1fr; }
  .deflist { grid-template-columns: 1fr; gap: 0; }
  .deflist dt { padding-top: 10px; }
  pre { font-size: 11.5px; padding: 12px; border-radius: 8px; }

  /* ── bottom tab bar ──────────────────────────────────────────────── */
  .tabbar {
    display: block; position: fixed; z-index: 40;
    left: 10px; right: 10px; bottom: calc(10px + env(safe-area-inset-bottom));
  }
  .tabbar-in {
    display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px;
    background: rgba(10,10,10,.82); backdrop-filter: saturate(180%) blur(20px);
    border: 0; border-radius: 20px; padding: 6px;
    box-shadow: var(--e3);
  }
  .tabbar a {
    display: flex; flex-direction: column; align-items: center; gap: 4px;
    padding: 9px 4px 7px; border-radius: 13px; text-decoration: none;
    color: var(--ink-60); font-family: var(--mono); font-size: 10px; letter-spacing: .03em;
    -webkit-tap-highlight-color: transparent;
  }
  .tabbar a svg { width: 20px; height: 20px; }
  .tabbar a.on { background: var(--ink); color: #000; box-shadow: none; }
  body.has-tabbar { padding-bottom: 92px; }
  footer { padding-bottom: 20px; }
}

@media (max-width: 420px) {
  .topnav .btn { display: none; }
  .wordmark { font-size: 16px; }
  .stat .v { font-size: 19px; }
  .tabbar a span { font-size: 9px; }
  table.cards td { grid-template-columns: 84px 1fr; }
}

/* social buttons in the header */
.social {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; margin-left: 6px; border-radius: 9px;
  border: 0; background: var(--panel); color: var(--ink); box-shadow: var(--e1);
  transition: color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.social svg { width: 16px; height: 16px; }
.social:hover { color: var(--signal-ink); transform: translateY(-1px); box-shadow: var(--e2); }


/* ══ docs, mobile ═════════════════════════════════════════════════════ */
@media (max-width: 1024px) {
  /* The section rail becomes a horizontal chip strip pinned under the header,
     instead of a two-column list nobody scrolls back up to. */
  .rail {
    position: sticky; top: 57px; z-index: 15;
    margin: 0 calc(var(--gut) * -1) 8px; padding: 8px var(--gut);
    background: rgba(10,10,10,.82); backdrop-filter: saturate(180%) blur(14px);
    border-bottom: 1px solid var(--rule);
  }
  .rail ol {
    display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .rail ol::-webkit-scrollbar { display: none; }
  .rail li { flex: 0 0 auto; }
  .rail a {
    display: inline-flex; align-items: center; gap: 6px; white-space: nowrap;
    padding: 7px 12px; border: 1px solid var(--rule); border-radius: 999px;
    background: var(--panel); font-size: 11px; color: var(--ink-60);
  }
  .rail a::before { color: var(--ink-30); }
  .rail a.on { background: var(--panel-2); border-color: var(--edge); color: var(--ink); }
  .docs { padding-top: 0; }
}

@media (max-width: 860px) {
  .hero { padding: 26px 0 20px; }
  .hero h1 { max-width: none; }
  .doc section { padding-bottom: 30px; }
  .doc section + section { padding-top: 26px; }
  .doc h3 { margin-top: 20px; }

  /* Reference tables stack into cards. Sideways scrolling inside a page that also
     scrolls vertically is the worst of both. */
  .doc table, .doc tbody, .doc tr, .doc td { display: block; width: 100%; }
  .doc thead { display: none; }
  .doc tr {
    border: 1px solid var(--rule); border-radius: 9px; background: var(--panel);
    margin-bottom: 9px; padding: 11px 13px;
  }
  .doc tr:hover { background: var(--panel); }
  .doc td { border: 0; padding: 2px 0; font-size: 13.5px; color: var(--ink-60); }
  .doc td:first-child {
    font-family: var(--body); font-weight: 600; font-size: 14.5px; color: var(--ink);
    padding-bottom: 5px;
  }
  .doc td.num { text-align: left; }

  /* Addresses and hashes wrap instead of blowing out the layout. */
  .doc td.num, .doc code { word-break: break-all; }
  .doc pre { font-size: 10.5px; line-height: 1.5; }
  .doc pre code { word-break: normal; }

  /* Definition lists read better stacked than as a cramped two-column grid. */
  .doc .deflist { grid-template-columns: 1fr; gap: 0; }
  .doc .deflist dt { padding-top: 12px; color: var(--amber); }
  .doc .deflist dd { margin-bottom: 2px; }

  .doc .grid2 { gap: 4px; }
  .doc .note, .doc .warnbox, .doc .dangerbox { font-size: 14px; padding: 12px 14px; }
  .doc ul { padding-left: 20px; }
  .doc li { margin-bottom: 6px; font-size: 14.5px; }

  .ladder { --h: 200px; --lane-label: 62px; --lane-bag: 34px; --lane-val: 0px; }
  .ladder .val { display: none; }
  .ladder .marker .tag { font-size: 9.5px; left: 22px; }
}


/* ══ segmented menu ═══════════════════════════════════════════════════ */
.seg {
  display: inline-flex; align-items: center; gap: 2px; padding: 4px;
  background: var(--panel-2); border: 0; border-radius: 12px; box-shadow: inset 0 1px 2px rgba(0,0,0,.55);
}
.seg a {
  padding: 6px 12px; border-radius: 6px; opacity: 1; color: var(--ink-60);
  font-family: var(--mono); font-size: 11.5px; letter-spacing: .07em; text-transform: uppercase;
  text-decoration: none; transition: background .14s ease, color .14s ease;
}
.seg a:hover { background: var(--panel-2); color: var(--ink); }
.seg a[aria-current="page"] { background: var(--panel); color: var(--ink); box-shadow: var(--e1); }
@media (max-width: 860px) { .seg { display: none; } }


/* ══ docs, phone: final pass ══════════════════════════════════════════ */
@media (max-width: 860px) {
  html { scroll-padding-top: 118px; }      /* header + sticky chip rail */

  .doc h2 { font-size: clamp(20px, 5.8vw, 26px); line-height: 1.15; }
  .doc h3 { font-size: 16px; margin-top: 22px; }
  .doc p { font-size: 15px; line-height: 1.6; }
  .doc .lede { font-size: 16px; }
  .eyebrow { font-size: 10.5px; letter-spacing: .14em; margin-bottom: 10px; }

  .hero .kicker { font-size: 10.5px; letter-spacing: .12em; }
  .hero h1 { font-size: clamp(28px, 8vw, 38px); }

  /* Long words in headings and inline code must not force a sideways scroll. */
  .doc h1, .doc h2, .doc h3 { overflow-wrap: anywhere; }
  .doc code { overflow-wrap: anywhere; }

  /* Code blocks scroll on their own, inside a rounded frame. */
  .doc pre {
    margin-left: -2px; margin-right: -2px;
    -webkit-overflow-scrolling: touch;
  }

  /* Panels inside docs (the ladder walkthrough) need breathing room. */
  .doc .panel { margin: 16px 0; }
  .doc .panel-bd { padding: 12px; }

  .docs { gap: 0; }
  .doc section { padding-bottom: 26px; }
}


/* ══ overflow containment ═════════════════════════════════════════════
   A grid or flex child defaults to min-width:auto, meaning it refuses to shrink
   below its content. One <pre> with a long line therefore widens the whole grid
   column, the column widens the page, and the entire document scrolls sideways
   on a phone. Every container in the chain needs min-width:0. */

html, body { max-width: 100%; overflow-x: hidden; }

.docs, .doc, .doc section,
.cols, .cols > *, .grid2, .grid2 > *,
.tiles, .tile, .steps, .steps article,
.hero-lp-grid, .hero-lp-grid > *, .ladder-lp, .ladder-lp > *,
.panel, .panel-bd, .tabpanel, .poscard, .poscard > * {
  min-width: 0;
}

pre, .doc pre { max-width: 100%; overflow-x: auto; }
table { max-width: 100%; }
.doc p, .doc li, .doc dd, .explain { overflow-wrap: anywhere; }
.txrow, .feed-row, .txline { min-width: 0; }
.txrow > *, .feed-row > *, .txline > * { min-width: 0; overflow-wrap: anywhere; }

@media (max-width: 860px) {
  /* The chip rail is full-bleed, so it must not add to the document width. */
  .rail { max-width: 100vw; box-sizing: border-box; }
  .wrap { max-width: 100%; }
  .doc pre { font-size: 10px; }
}


/* ══ white surfaces ═══════════════════════════════════════════════════
   Used sparingly and only where attention belongs: the headline figures and
   the primary call to action. Everywhere else stays dark, so white reads as
   emphasis rather than as a second background. */

.stat .v, .poscard .mult, .bignum, .hero-nums .v { color: var(--ink); }
.wordmark { color: var(--ink); font-family: var(--body); font-weight: 700; letter-spacing: -.02em; }
.panel-hd { color: var(--ink-80); }

.stats { background: var(--panel); }
.stat:first-child { box-shadow: inset 3px 0 0 var(--signal); }

/* The primary action inverts to white: the one element that should stop the eye. */
.btn.solid {
  background: var(--paper-on); color: var(--paper-ink); border-color: var(--paper-on);
}
.btn.solid:hover { background: #E6E6E6; color: var(--paper-ink); }

/* Audit chips */
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px;
  font-family: var(--mono); font-size: 10.5px; letter-spacing: .04em;
  border: 0; background: var(--panel-2); color: var(--ink-80); box-shadow: inset 0 0 0 1px rgba(0,0,0,.55);
}
.chip b { color: var(--ink); font-weight: 600; }
.chip.good { border-color: rgba(111,227,155,.35); color: var(--signal-ink); }
.chip.bad  { border-color: rgba(232,106,106,.4); color: var(--loss); }
.chip.warn { border-color: rgba(232,180,84,.4); color: var(--warn); }

/* Deployer history */
.devrow { display: grid; grid-template-columns: 1fr auto; gap: 8px; padding: 9px 13px; border-bottom: 1px solid var(--rule); }
.devrow:hover { background: var(--panel-2); }
.devrow .who { font-family: var(--mono); font-size: 12px; color: var(--ink); }
.devrow .meta { font-family: var(--mono); font-size: 10.5px; color: var(--ink-60); text-align: right; }
.bar-mini { height: 4px; border-radius: 2px; background: var(--panel-2); overflow: hidden; margin-top: 5px; }
.bar-mini i { display: block; height: 100%; background: var(--signal); }


/* ══ elevation and depth ══════════════════════════════════════════════
   White on white only reads if surfaces sit at different heights, so depth
   comes from layered shadow and a top highlight rather than from borders. */

.panel, .stats, .steps, .cablock, .tabs {
  background-image: linear-gradient(180deg, rgba(255,255,255,.025), rgba(255,255,255,0) 90px), none;
  position: relative;
}
.panel::before, .stats::before {
  content: ""; position: absolute; inset: 0 0 auto; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.06), transparent);
  pointer-events: none;
}

.poscard, .txrow, .feed-row, .devrow { transition: background .18s ease, transform .18s ease; }
.poscard:hover { background: var(--panel-2); }

/* Figures are the content here, so they get the weight. */
.stat .v { font-family: var(--body); font-weight: 700; letter-spacing: -.035em; }
.stat { position: relative; }
.stat::after {
  content: ""; position: absolute; right: 0; top: 18%; bottom: 18%; width: 1px;
  background: var(--rule);
}
.stat:last-child::after { display: none; }

.tag { border-width: 1px; border-radius: 999px; padding: 1px 8px; }
.tag.bought { background: rgba(10,155,87,.10); border-color: transparent; }
.tag.skipped { background: var(--panel-2); border-color: transparent; }
.tag.pending { background: rgba(178,106,0,.10); border-color: transparent; }

.pill { border-width: 1px; background: var(--panel); box-shadow: var(--e1); border-color: var(--rule); }
.pill.live { color: var(--gain); }
.pill.dry { color: var(--warn); }

.empty { color: var(--ink-30); }
.explain { border-left-color: var(--edge); color: var(--ink-60); }
.log { background: #111111; border-radius: 12px; color: #D4D4D4; }
.log div { border-bottom-color: rgba(255,255,255,.06); }
.log .t { color: #8A8A8A; }

.note { background: var(--tint); border-left-color: var(--signal); }
.bar .t { background: var(--panel-2); border-color: var(--rule); }
.bar .t i { background: linear-gradient(90deg, #3A4256, var(--signal)); }
.bar .t i.neg { background: linear-gradient(90deg, #161616, var(--loss)); }

::selection { background: rgba(0,0,0,.55); }

/* Scrollbars, since light panels make the default ones obtrusive. */
.feed, .log, .tabs, .rail ol { scrollbar-width: thin; scrollbar-color: var(--edge) transparent; }
.feed::-webkit-scrollbar, .log::-webkit-scrollbar { width: 8px; height: 8px; }
.feed::-webkit-scrollbar-thumb, .log::-webkit-scrollbar-thumb {
  background: var(--edge); border-radius: 99px; border: 2px solid transparent; background-clip: content-box;
}

/* ══ filter bar ═══════════════════════════════════════════════════════ */
.filterbar {
  display: flex; gap: 10px; align-items: center; flex-wrap: wrap;
  padding: 11px 14px; border-bottom: 1px solid var(--rule); background: var(--panel-2);
}
.fld {
  flex: 1 1 200px; min-width: 0; padding: 8px 12px; border-radius: 10px;
  border: 0; background: var(--panel); box-shadow: inset 0 0 0 1px var(--rule);
  font-family: var(--body); font-size: 13px; color: var(--ink);
}
.fld::placeholder { color: var(--ink-30); }
.fld:focus { outline: 0; box-shadow: inset 0 0 0 2px var(--signal); }
.segbtns { display: inline-flex; gap: 3px; padding: 3px; background: var(--panel); border-radius: 10px; box-shadow: inset 0 0 0 1px var(--rule); }
.segbtns button {
  border: 0; background: none; cursor: pointer; padding: 6px 11px; border-radius: 8px;
  font-family: var(--mono); font-size: 11px; color: var(--ink-60); letter-spacing: .04em;
}
.segbtns button:hover { color: var(--ink); background: var(--panel-2); }
.segbtns button.on { background: var(--ink); color: #000; }

/* ══ token drawer ═════════════════════════════════════════════════════ */
.drawer { position: fixed; inset: 0; z-index: 60; }
.drawer-scrim {
  position: absolute; inset: 0; background: rgba(0,0,0,.55);
  backdrop-filter: blur(3px); animation: fade .2s ease;
}
.drawer-panel {
  position: absolute; top: 0; right: 0; bottom: 0; width: min(460px, 100%);
  background: var(--bg); box-shadow: var(--e3); overflow-y: auto;
  animation: slidein .26s cubic-bezier(.22,.68,.36,1);
  display: flex; flex-direction: column;
}
@keyframes fade { from { opacity: 0 } to { opacity: 1 } }
@keyframes slidein { from { transform: translateX(26px); opacity: 0 } to { transform: none; opacity: 1 } }
.drawer-hd {
  position: sticky; top: 0; z-index: 2; display: flex; align-items: center; gap: 12px;
  padding: 16px 18px; background: rgba(10,10,10,.82); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--rule);
}
.drawer-hd b { font-family: var(--display); font-size: 19px; letter-spacing: -.02em; }
.drawer-hd .micro { margin-left: 8px; }
.drawer-hd .minibtn { margin-left: auto; }
.drawer-bd { padding: 16px 18px 40px; }
.dw-h {
  font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: .12em;
  color: var(--ink-60); margin: 22px 0 8px; padding-bottom: 6px; border-bottom: 1px solid var(--rule);
}
.drawer .devrow { padding: 8px 0; }
a.chip { text-decoration: none; }
a.chip:hover { box-shadow: inset 0 0 0 1px var(--signal-dim); color: var(--signal-ink); }

@media (max-width: 700px) {
  .drawer-panel { width: 100%; top: auto; height: 88vh; border-radius: 20px 20px 0 0; }
  @keyframes slidein { from { transform: translateY(30px); opacity: 0 } to { transform: none; opacity: 1 } }
}

@media (prefers-reduced-motion: reduce) {
  .drawer-panel, .drawer-scrim { animation: none; }
}

/* ══════════════════════════════════════════════════════════════════════
   3D — real perspective, not drop shadows pretending.
   Surfaces are plates in space: they have thickness, they catch light from
   above-left, and they tilt slightly toward the viewer.
   ══════════════════════════════════════════════════════════════════════ */

.scene { perspective: 1400px; perspective-origin: 50% 20%; }

/* Plate: a card with visible thickness along its bottom edge. */
.plate {
  position: relative; border-radius: 18px; background: var(--panel);
  box-shadow:
    0 0 0 1px rgba(0,0,0,.55),
    0 1px 0 #fff inset,
    0 10px 0 -4px #161616,          /* the slab edge */
    0 14px 0 -4px rgba(0,0,0,.55),
    0 26px 44px rgba(0,0,0,.55);
  transform-style: preserve-3d;
  transition: transform .3s cubic-bezier(.22,.68,.36,1), box-shadow .3s ease;
}
.plate:hover { transform: translateY(-3px) rotateX(2deg); }

/* Apply the plate treatment to the main surfaces. */
.panel, .stats, .steps, .cablock, .scan-card {
  box-shadow:
    0 0 0 1px rgba(0,0,0,.55),
    0 1px 0 rgba(255,255,255,.06) inset,
    0 8px 0 -4px #161616,
    0 12px 0 -4px rgba(0,0,0,.55),
    0 22px 40px rgba(0,0,0,.55);
}
.panel:hover { transform: translateY(-2px); box-shadow:
    0 0 0 1px rgba(0,0,0,.55),
    0 1px 0 rgba(255,255,255,.06) inset,
    0 10px 0 -4px #161616,
    0 15px 0 -4px rgba(0,0,0,.55),
    0 30px 56px rgba(0,0,0,.55); }

/* Buttons get a pressable body with a lit top face. */
.btn {
  box-shadow:
    0 1px 0 rgba(255,255,255,.06) inset,
    0 5px 0 -1px #000000,
    0 8px 18px rgba(0,0,0,.55);
  transform: translateZ(0);
}
.btn:hover { transform: translateY(-2px); box-shadow:
    0 1px 0 rgba(255,255,255,.06) inset, 0 7px 0 -1px #000000, 0 14px 26px rgba(0,0,0,.55); }
.btn:active { transform: translateY(3px); box-shadow:
    0 1px 0 rgba(255,255,255,.35) inset, 0 2px 0 -1px #000000, 0 4px 10px rgba(0,0,0,.55); }
.btn.ghost {
  box-shadow: 0 0 0 1px rgba(0,0,0,.55), 0 4px 0 -1px #161616, 0 8px 18px rgba(0,0,0,.55);
}
.btn.ghost:active { transform: translateY(3px); box-shadow: 0 0 0 1px rgba(0,0,0,.55), 0 1px 0 -1px #161616; }

/* ══ the exit ladder, in perspective ══════════════════════════════════
   The rungs are stacked plates receding into the scene, the marker is a lit
   sphere that travels between them, and the bag is a column with a visible
   top face. Depth carries the meaning: a rung you have passed sits behind you. */

.ladder {
  --h: 300px; --lane-label: 88px; --lane-bag: 62px; --lane-val: 66px;
  height: var(--h); padding-right: calc(var(--lane-bag) + 22px);
  perspective: 900px; perspective-origin: 40% 50%;
}
.ladder .rail {
  left: var(--lane-label); width: 3px; border-radius: 3px;
  background: linear-gradient(180deg, var(--rule), var(--edge));
  box-shadow: 1px 0 0 rgba(255,255,255,.06), -1px 0 0 rgba(0,0,0,.55);
}
.rung { transform: translateY(-50%) rotateX(6deg); transform-style: preserve-3d; }
.rung .line {
  height: 7px; border-radius: 4px;
  background: linear-gradient(180deg, #161616, #161616);
  box-shadow:
    0 1px 0 rgba(255,255,255,.06) inset,
    0 3px 0 -1px rgba(0,0,0,.55),
    0 6px 10px rgba(0,0,0,.55);
  transition: background .25s ease, box-shadow .25s ease, transform .25s ease;
}
.rung.tp .line { background: linear-gradient(180deg, #161616, #DCDCD9); }
.rung.stop .line { background: linear-gradient(180deg, #161616, #161616); }
.rung.entry .line { background: linear-gradient(180deg, #161616, #161616); }
.rung.filled .line {
  background: linear-gradient(180deg, #3A4256, var(--signal));
  box-shadow: 0 1px 0 rgba(255,255,255,.4) inset, 0 4px 0 -1px #000000, 0 8px 16px rgba(0,0,0,.55);
  transform: translateZ(10px);
}
.rung .label { color: var(--ink-60); text-shadow: none; }
.rung.filled .label { color: var(--ink); font-weight: 600; }

.marker { width: 26px; height: 26px; left: calc(var(--lane-label) - 13px); z-index: 3; }
.marker b {
  background: radial-gradient(circle at 32% 28%, #C9CDD6 0%, #2A3145 42%, #000000 100%);
  border: 0;
  box-shadow:
    0 2px 0 rgba(255,255,255,.06) inset,
    0 6px 12px rgba(30,79,203,.45),
    0 0 0 6px rgba(0,0,0,.55);
}
.marker .tag {
  background: var(--ink); color: #000;
  box-shadow: 0 3px 0 -1px rgba(0,0,0,.55), 0 8px 18px rgba(0,0,0,.55);
  border-radius: 8px; left: 34px;
}

/* The bag: a column with a lit top face and a shaded body. */
.bag {
  width: var(--lane-bag); border: 0; border-radius: 10px;
  background: linear-gradient(180deg, #161616, #161616);
  box-shadow:
    0 1px 0 rgba(255,255,255,.06) inset,
    0 0 0 1px rgba(0,0,0,.55),
    0 10px 20px rgba(0,0,0,.55);
  transform: rotateX(4deg);
}
.bag i {
  background: linear-gradient(180deg, #5B6478 0%, #2A3145 55%, #000000 100%);
  border-top: 0; border-radius: 0 0 9px 9px;
  box-shadow: 0 -1px 0 rgba(255,255,255,.06) inset, 0 -6px 14px rgba(0,0,0,.55);
}
.bag span { color: var(--ink-60); text-shadow: none; font-weight: 500; }

/* ══ analyzer ═════════════════════════════════════════════════════════ */
.scanner { margin-top: 22px; }
.scan-in { display: flex; gap: 10px; flex-wrap: wrap; }
.scan-in.slim { margin: 16px 0 0; }
.fld.big { padding: 15px 18px; font-size: 15px; border-radius: 14px; font-family: var(--mono); }
.scan-card {
  margin-top: 16px; background: var(--panel); border-radius: 18px; padding: 20px 22px;
  animation: rise .28s cubic-bezier(.22,.68,.36,1);
}
@keyframes rise { from { opacity: 0; transform: translateY(10px) } to { opacity: 1; transform: none } }
.scan-card.loading { opacity: .8; }
.scan-top { display: flex; gap: 16px; align-items: flex-start; flex-wrap: wrap; }
.stamp {
  font-family: var(--mono); font-size: 11px; letter-spacing: .12em; padding: 9px 14px;
  border-radius: 12px; color: #fff; white-space: nowrap;
  background: linear-gradient(180deg, #2A3145, var(--signal));
  box-shadow: 0 4px 0 -1px #000000, 0 10px 20px rgba(0,0,0,.55);
}
.verdict-yes .stamp { background: linear-gradient(180deg, #0F8C50, var(--gain)); box-shadow: 0 4px 0 -1px #065C3A, 0 10px 20px rgba(10,155,87,.3); }
.verdict-no .stamp { background: linear-gradient(180deg, #C4293B, var(--loss)); box-shadow: 0 4px 0 -1px #8E1926, 0 10px 20px rgba(217,58,75,.28); }
.verdict-maybe .stamp { background: linear-gradient(180deg, #6B5A2E, var(--warn)); box-shadow: 0 4px 0 -1px #4A3E1F, 0 10px 20px rgba(178,106,0,.26); }
.scan-head { font-family: var(--display); font-weight: 800; font-size: 19px; margin: 0; letter-spacing: -.02em; }
.scan-head.bad { color: var(--loss); }
.scan-why { margin: 4px 0 0; color: var(--ink-60); font-size: 14.5px; max-width: 58ch; }
.scan-facts { display: flex; flex-wrap: wrap; gap: 7px; margin: 16px 0 14px; }
.scan-row {
  display: grid; grid-template-columns: 26px 150px 1fr; gap: 10px; align-items: baseline;
  padding: 9px 0; border-top: 1px solid var(--rule); font-size: 13.5px;
}
.scan-row .ic { display: flex; align-items: center; justify-content: center; width: 22px; height: 22px; border-radius: 7px; }
.scan-row .ic svg { width: 13px; height: 13px; }
.scan-row.pass .ic { background: rgba(10,155,87,.12); color: var(--gain); }
.scan-row.fail .ic { background: rgba(217,58,75,.12); color: var(--loss); }
.scan-row.warn .ic { background: rgba(178,106,0,.12); color: var(--warn); }
.scan-row.unknown .ic { background: var(--panel-2); color: var(--ink-30); }
.scan-row .lb { font-weight: 600; color: var(--ink); }
.scan-row .dt { color: var(--ink-60); }
.scan-sub { margin-top: 12px; font-size: 13.5px; color: var(--ink-60); }
.scan-sub b { color: var(--ink); }

@media (max-width: 700px) {
  .scan-row { grid-template-columns: 24px 1fr; }
  .scan-row .dt { grid-column: 2; color: var(--ink-60); font-size: 13px; }
  .scan-in .btn { flex: 1; }
  .fld.big { font-size: 14px; }
  .stamp { width: 100%; text-align: center; }
  .ladder { --h: 250px; --lane-bag: 44px; perspective: 600px; }
  .panel:hover, .plate:hover { transform: none; }
}

/* ══ price chart ══════════════════════════════════════════════════════
   Paint lives in the SVG itself; only layout belongs here. */
.pchart, #ladder svg { width: 100%; height: auto; display: block; }
#ladder { min-height: 220px; }

@media (max-width: 700px) {
  #ladder { min-height: 180px; }
}


/* ══ pointer-reactive depth ═══════════════════════════════════════════ */
.panel, .scan-card, .steps article, .cablock { position: relative; }
.panel.lit::after, .scan-card.lit::after, .steps article.lit::after, .cablock.lit::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 1;
  border-radius: inherit;
  background: radial-gradient(420px circle at var(--hx, 50%) var(--hy, 0%),
              rgba(255,255,255,.06), rgba(255,255,255,0) 55%);
  mix-blend-mode: overlay;
}

/* The page itself has a horizon: content sits in front of a soft field rather than
   on a flat colour. */
body::after {
  content: ""; position: fixed; left: 0; right: 0; bottom: 0; height: 46vh;
  background: linear-gradient(180deg, transparent, rgba(0,0,0,.55));
  pointer-events: none; z-index: 0;
}

/* Stat figures get a subtle extruded face. */
.stat .v {
  background: linear-gradient(180deg, #FFFFFF 0%, #BDBDBD 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  text-shadow: none;
}
.stat .v.gain { background: linear-gradient(180deg, #0F8C50, #067A43); -webkit-background-clip: text; background-clip: text; }
.stat .v.loss { background: linear-gradient(180deg, #C4293B, #B02434); -webkit-background-clip: text; background-clip: text; }

/* Tabs sit in a recessed well. */
.tabs { background: linear-gradient(180deg, #161616, #161616); box-shadow: inset 0 2px 4px rgba(0,0,0,.55), 0 1px 0 #fff; }
.tab.on { box-shadow: 0 2px 0 -1px #000000, 0 6px 14px rgba(0,0,0,.55); }

/* Rows lift off the card as the pointer crosses them. */
.devrow:hover, .txrow:hover, .feed-row:hover {
  box-shadow: 0 1px 0 rgba(255,255,255,.06) inset, 0 6px 16px rgba(0,0,0,.55);
  border-radius: 10px;
}

@media (hover: none) {
  .panel.lit::after { display: none; }
}

.scan-mode { margin-bottom: 12px; }
.scan-mode button { padding: 7px 16px; }

/* ══════════════════════════════════════════════════════════════════════
   Motion
   Everything here is short and eased out. The purpose is to show where
   things came from and what just changed — not to make people wait.
   ══════════════════════════════════════════════════════════════════════ */

:root {
  --ease: cubic-bezier(.22, .68, .36, 1);
  --ease-soft: cubic-bezier(.32, .72, .28, 1);
}

/* ── entrance ─────────────────────────────────────────────────────────
   Sections arrive as their own group, with children staggered behind the
   parent so the eye is led down rather than hit all at once. */
.reveal { opacity: 0; transform: translateY(16px); }
.reveal.shown {
  opacity: 1; transform: none;
  transition: opacity .55s var(--ease), transform .6s var(--ease);
}
/* Children follow their parent in, so a panel arrives as one thing that then
   fills in rather than as a dozen independent pieces. */
.reveal.shown > .panel-bd > *, .reveal.shown > table tbody tr {
  animation: riseIn .45s var(--ease) both;
}
.reveal.shown > .panel-bd > *:nth-child(2) { animation-delay: .05s }
.reveal.shown > .panel-bd > *:nth-child(3) { animation-delay: .1s }
.reveal.shown > .panel-bd > *:nth-child(n+4) { animation-delay: .14s }
@keyframes riseIn { from { opacity: 0; transform: translateY(10px) } to { opacity: 1; transform: none } }

/* The first screen does not wait for a scroll event. */
.topbar { animation: dropIn .5s var(--ease) both; }
.hero > * { animation: riseIn .6s var(--ease) both; }
.hero > *:nth-child(2) { animation-delay: .06s }
.hero > *:nth-child(3) { animation-delay: .12s }
.hero > *:nth-child(4) { animation-delay: .18s }
@keyframes dropIn { from { opacity: 0; transform: translateY(-10px) } to { opacity: 1; transform: none } }

/* ── the field behind everything drifts ───────────────────────────────
   Slow enough to be felt rather than watched. */
body::before { animation: drift 34s ease-in-out infinite alternate; }
@keyframes drift {
  0%   { transform: translate3d(0, 0, 0) scale(1) }
  50%  { transform: translate3d(-1.5%, 1.5%, 0) scale(1.04) }
  100% { transform: translate3d(1.5%, -1%, 0) scale(1.02) }
}

/* ── loading ──────────────────────────────────────────────────────────
   A shimmer says "coming", a spinner says "stuck". */
.empty.loading, .skel {
  background: linear-gradient(90deg, var(--panel-2) 25%, #fff 50%, var(--panel-2) 75%);
  background-size: 300% 100%;
  animation: shimmer 1.4s linear infinite;
  color: transparent; border-radius: 8px;
}
@keyframes shimmer { from { background-position: 150% 0 } to { background-position: -150% 0 } }

/* ── tabs ─────────────────────────────────────────────────────────────
   The panel slides in from the direction of travel, so switching tabs
   reads as movement along a row rather than a hard cut. */
.tabpanel:not([hidden]) { animation: panelIn .34s var(--ease) both; }
@keyframes panelIn { from { opacity: 0; transform: translateY(8px) } to { opacity: 1; transform: none } }
.tab { transition: background .22s var(--ease), color .22s var(--ease), box-shadow .22s var(--ease); }

/* ── buttons lean toward the cursor ──────────────────────────────────── */
.btn { transition: transform .18s var(--ease), box-shadow .22s var(--ease), background .2s ease; }
.btn:focus-visible { outline: 2px solid var(--signal); outline-offset: 3px; }

/* ── value changes ────────────────────────────────────────────────────
   A number that changed silently may as well not have. */
.flash-up   { animation: flashUp .9s var(--ease-soft); }
.flash-down { animation: flashDown .9s var(--ease-soft); }
@keyframes flashUp {
  0% { background: rgba(10,155,87,.22); border-radius: 6px }
  100% { background: transparent }
}
@keyframes flashDown {
  0% { background: rgba(217,58,75,.2); border-radius: 6px }
  100% { background: transparent }
}

/* New rows arrive rather than appear. */
.feed-row.fresh, .txrow.fresh, .poscard.fresh { animation: slideIn .45s var(--ease) both; }
@keyframes slideIn {
  from { opacity: 0; transform: translateX(-10px); background: var(--tint) }
  to { opacity: 1; transform: none; background: transparent }
}

/* ── the live pill breathes ───────────────────────────────────────────── */
.pill.live::before {
  content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%;
  background: currentColor; margin-right: 7px; animation: pulse 2.1s ease-in-out infinite;
}
@keyframes pulse { 0%, 100% { opacity: 1; box-shadow: 0 0 0 0 currentColor } 50% { opacity: .45; box-shadow: 0 0 0 4px transparent } }

/* ── links draw their own underline ───────────────────────────────────── */
.doc p a, .explain a, p a.inline {
  background-image: linear-gradient(var(--signal), var(--signal));
  background-size: 0% 1.5px; background-repeat: no-repeat; background-position: 0 100%;
  transition: background-size .3s var(--ease); text-decoration: none;
}
.doc p a:hover, .explain a:hover, p a.inline:hover { background-size: 100% 1.5px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important; animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}

/* ══════════════════════════════════════════════════════════════════════
   Spacing
   The density was inherited from the dark theme, where low contrast made
   tight rows readable. On white the same spacing reads as cramped, so the
   whole scale opens up — sections breathe, panels get real padding, and
   rows are tall enough to scan rather than decode.
   ══════════════════════════════════════════════════════════════════════ */

:root { --gut: clamp(20px, 4vw, 56px); }

.wrap { padding-left: var(--gut); padding-right: var(--gut); }
.band { padding-block: clamp(56px, 8vw, 104px); }
section + section { margin-top: clamp(8px, 2vw, 24px); }

.stats { margin-top: clamp(20px, 3vw, 34px); }
.stat { padding: 22px 24px; }
.stat .k { margin-bottom: 12px; letter-spacing: .14em; }
.stat .v { margin-bottom: 8px; }
.stat .sub { line-height: 1.5; }

.panel { margin-bottom: clamp(18px, 2.4vw, 28px); }
.panel-hd { padding: 16px 22px; }
.panel-bd { padding: 22px; }
.panel-bd > * + * { margin-top: 14px; }

.tabs { margin: clamp(22px, 3vw, 32px) 0 clamp(20px, 2.6vw, 28px); }
.tab { padding: 13px 20px; }

table th, table td { padding: 14px 18px; }
table th { letter-spacing: .12em; }

.devrow { padding: 14px 20px; gap: 16px; }
.feed-row { padding: 16px 20px; gap: 14px; }
.txrow { padding: 15px 20px; }
.poscard { padding: 22px; }
.poscard + .poscard { border-top: 1px solid var(--rule); }

.explain { padding: 4px 0 4px 18px; margin: 0 0 clamp(18px, 2.4vw, 26px); line-height: 1.65; }
.lede { line-height: 1.6; margin-bottom: clamp(18px, 2.4vw, 26px); max-width: 62ch; }
p { line-height: 1.62; }
.doc p { margin-bottom: 1.1em; }
.doc h2 { margin-top: clamp(40px, 5vw, 64px); }
.doc h3 { margin-top: 34px; }
.doc section { padding-bottom: clamp(40px, 5vw, 64px); }

.chips { gap: 8px; margin-top: 12px; }
.scan-in { gap: 12px; }
.scan-card { padding: 26px 28px; margin-top: 20px; }
.scan-row { padding: 13px 0; }
.scan-facts { margin: 20px 0 18px; }
.filterbar { padding: 14px 20px; gap: 12px; }
.cablock { padding: 22px 26px; gap: 18px; }
.eyebrow { margin-bottom: 14px; }

/* Numbers are set in the UI face, not the editorial serif — a serif "0.0000 ETH"
   reads as a pull quote rather than as a balance. */
.bignum, .stat .v, .poscard .mult, .hero-nums .v, .scan-head, .stamp, .drawer-hd b {
  font-family: var(--body); font-weight: 700; letter-spacing: -.03em;
}
.cablock .addr, .cablock b { font-family: var(--mono); font-weight: 500; }

@media (max-width: 860px) {
  .panel-bd { padding: 18px; }
  .stat { padding: 18px; }
  .devrow, .feed-row, .txrow { padding: 14px 16px; }
  table th, table td { padding: 12px 14px; }
  .scan-card { padding: 20px; }
}

/* ══════════════════════════════════════════════════════════════════════
   Pons Agent
   Taken from the artwork: a black field, matte graphite surfaces, and green
   as emissive light — it glows from edges and indicators, it does not fill
   panels. Type is one family at many weights, so hierarchy comes from size
   and weight rather than from switching faces.
   ══════════════════════════════════════════════════════════════════════ */

html { background: #000; color-scheme: dark; }
body { background: #000; color: var(--ink); }

/* The field: green light leaking in from off-frame, like the artwork's rim light. */
body::before {
  background:
    radial-gradient(900px 520px at 78% -8%, rgba(0,200,5,.10), transparent 62%),
    radial-gradient(700px 480px at 6% 18%, rgba(61,255,110,.05), transparent 60%),
    radial-gradient(1100px 700px at 50% 112%, rgba(0,200,5,.06), transparent 60%);
}
body::after { background: none; }

/* ── type ─────────────────────────────────────────────────────────────── */
h1, h2 {
  font-family: var(--display); font-weight: 600; color: #fff;
  letter-spacing: -.035em; line-height: 1.02;
}
h1 { font-size: clamp(42px, 7vw, 84px); letter-spacing: -.045em; }
h2 { font-size: clamp(30px, 4vw, 50px); }
h3 { color: #fff; font-weight: 600; }
p, li { color: var(--ink-80); }
.lede { color: var(--ink-60); font-size: clamp(16px, 1.5vw, 19px); }
.eyebrow {
  color: var(--signal); font-family: var(--mono); font-size: 11px;
  letter-spacing: .2em; text-transform: uppercase;
}
.eyebrow::after { background: linear-gradient(90deg, var(--rule), transparent); }
.explain { border-left-color: var(--signal-dim); color: var(--ink-60); }
.explain b { color: #fff; }
.micro, .sub, .k { color: var(--ink-60); }
a { color: #fff; }

/* ── header ───────────────────────────────────────────────────────────── */
.topbar {
  background: rgba(0,0,0,.72); backdrop-filter: saturate(160%) blur(18px);
  border-bottom: 1px solid var(--rule);
}
.brand img.logo, .brand .logo { width: 34px; height: 34px; border-radius: 9px; box-shadow: 0 0 0 1px var(--edge), 0 0 18px rgba(0,200,5,.18); }
.wordmark { color: #fff; font-weight: 600; letter-spacing: -.025em; font-size: 17px; }
.wordmark span { color: var(--signal); }
.seg { background: var(--panel-2); box-shadow: inset 0 0 0 1px var(--rule); }
.seg a { color: var(--ink-60); }
.seg a:hover { color: #fff; }
.seg a[aria-current="page"] { background: #fff; color: #000; box-shadow: none; }
.ca { background: var(--panel-2); color: var(--ink-80); box-shadow: inset 0 0 0 1px var(--rule); }
.ca-k { color: var(--signal); }
.social { background: var(--panel-2); color: var(--ink-80); box-shadow: inset 0 0 0 1px var(--rule); }
.social:hover { color: var(--signal); box-shadow: inset 0 0 0 1px var(--signal-dim); }

.pill { background: var(--panel-2); border-color: var(--edge); box-shadow: none; color: var(--ink-60); }
.pill.live { color: var(--signal); border-color: var(--signal-dim); }
.pill.dry { color: var(--warn); border-color: rgba(201,162,39,.3); }

/* ── surfaces ─────────────────────────────────────────────────────────── */
.panel, .stats, .steps, .cablock, .scan-card, .tabs {
  background: var(--panel);
  box-shadow: 0 0 0 1px var(--rule), inset 0 1px 0 rgba(255,255,255,.035);
}
.panel:hover { box-shadow: 0 0 0 1px var(--edge), inset 0 1px 0 rgba(255,255,255,.05), 0 24px 60px rgba(0,0,0,.7); }
.panel-hd {
  background: linear-gradient(180deg, var(--panel-3), var(--panel));
  border-bottom: 1px solid var(--rule); color: var(--ink-80);
}
.panel-hd .sub { color: var(--ink-30); }

.stat { border-color: var(--rule); }
.stat::after { background: var(--rule); }
.stat:first-child { box-shadow: inset 2px 0 0 var(--signal); }
.stat .v {
  background: linear-gradient(180deg, #fff 0%, #BFBFBF 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.stat .v.gain { background: none; color: var(--gain); -webkit-text-fill-color: currentColor; }
.stat .v.loss { background: none; color: var(--loss); -webkit-text-fill-color: currentColor; }

.tabs { background: var(--panel); box-shadow: inset 0 0 0 1px var(--rule); }
.tab { color: var(--ink-60); }
.tab:hover { color: #fff; }
.tab .c { color: var(--ink-30); }
.tab.on .c { color: var(--signal-dim); }

table th { color: var(--ink-60); border-bottom-color: var(--rule); background: var(--panel-2); }
table td { border-bottom-color: var(--rule); color: var(--ink-80); }
tbody tr:hover td { background: var(--panel-2); }

pre { background: var(--deep); color: #E6E6E6; box-shadow: inset 0 0 0 1px var(--edge); }
pre .k { color: var(--signal); }
pre .c { color: #8C8C8C; }
code { background: var(--panel-2); color: var(--ink); border-color: var(--rule); }

.note { background: var(--tint); border-left-color: var(--signal); }
.warnbox { background: rgba(255,90,78,.06); border-left-color: var(--loss); }
.log { background: var(--deep); box-shadow: inset 0 0 0 1px var(--rule); color: #BDBDBD; }

/* ── controls ─────────────────────────────────────────────────────────── */
.btn { box-shadow: 0 0 0 1px rgba(0,200,5,.4), 0 8px 24px rgba(0,200,5,.18); }
.btn:active { transform: translateY(1px); box-shadow: 0 0 0 1px var(--signal); }
.btn.ghost { background: transparent; color: #fff; box-shadow: inset 0 0 0 1px var(--edge); }
.btn.ghost:hover { color: #fff; box-shadow: inset 0 0 0 1px #fff; background: rgba(255,255,255,.03); }

.fld {
  background: var(--panel-2); color: #fff; box-shadow: inset 0 0 0 1px var(--edge);
}
.fld::placeholder { color: var(--ink-30); }
.fld:focus { box-shadow: inset 0 0 0 1px var(--signal), 0 0 0 4px rgba(0,200,5,.12); }
.filterbar { background: var(--panel-2); border-bottom-color: var(--rule); }
.segbtns { background: var(--panel); box-shadow: inset 0 0 0 1px var(--rule); }
.segbtns button { color: var(--ink-60); }
.segbtns button:hover { color: #fff; background: var(--panel-3); }
.minibtn { background: var(--panel-2); color: var(--ink-80); border-color: var(--edge); }

.chip { background: var(--panel-2); color: var(--ink-80); box-shadow: inset 0 0 0 1px var(--rule); }
.chip b { color: #fff; }
.chip.good { color: var(--signal); box-shadow: inset 0 0 0 1px rgba(0,200,5,.3); }
.chip.bad { color: var(--loss); box-shadow: inset 0 0 0 1px rgba(255,90,78,.3); }
.chip.warn { color: var(--warn); box-shadow: inset 0 0 0 1px rgba(201,162,39,.3); }

.tag { background: var(--panel-2); color: var(--ink-60); border-color: transparent; }
.tag.bought { background: rgba(0,200,5,.12); color: var(--signal); }
.tag.pending { background: rgba(201,162,39,.1); color: var(--warn); }

/* ── rows ─────────────────────────────────────────────────────────────── */
.devrow, .feed-row, .txrow { border-bottom-color: var(--rule); }
.devrow:hover, .feed-row:hover, .txrow:hover { background: var(--panel-2); box-shadow: none; }
.devrow .who, .feed-row .sym { color: #fff; }
.devrow .meta { color: var(--ink-60); }
.bar-mini { background: var(--panel-3); }
.bar-mini i { background: var(--signal); box-shadow: 0 0 10px rgba(0,200,5,.4); }
.bar .t { background: var(--panel-3); border-color: var(--rule); }
.bar .t i { background: var(--signal); }
.bar .t i.neg { background: var(--loss); }

.gain { color: var(--gain); }
.loss { color: var(--loss); }

/* ── analyzer ─────────────────────────────────────────────────────────── */
.scan-card { background: var(--panel); }
.scan-head { color: #fff; }
.scan-why { color: var(--ink-60); }
.scan-row { border-top-color: var(--rule); }
.scan-row .lb { color: #fff; }
.scan-row .dt { color: var(--ink-60); }
.scan-row.pass .ic { background: rgba(0,200,5,.12); color: var(--signal); }
.scan-row.fail .ic { background: rgba(255,90,78,.12); color: var(--loss); }
.scan-row.warn .ic { background: rgba(201,162,39,.12); color: var(--warn); }
.scan-row.unknown .ic { background: var(--panel-3); color: var(--ink-30); }
.stamp { background: #fff; color: #000; box-shadow: none; }
.verdict-yes .stamp { background: var(--signal); color: #000; box-shadow: 0 0 24px rgba(0,200,5,.35); }
.verdict-no .stamp { background: var(--loss); color: #000; box-shadow: none; }
.verdict-maybe .stamp { background: var(--warn); color: #000; box-shadow: none; }

/* ── drawer ───────────────────────────────────────────────────────────── */
.drawer-scrim { background: rgba(0,0,0,.7); }
.drawer-panel { background: #050505; box-shadow: -1px 0 0 var(--edge), 0 0 80px rgba(0,0,0,.9); }
.drawer-hd { background: rgba(5,5,5,.9); border-bottom-color: var(--rule); }
.dw-h { color: var(--signal); border-bottom-color: var(--rule); }

/* ── depth on dark: rim light that follows the pointer ────────────────── */
.panel.lit::after, .scan-card.lit::after, .steps article.lit::after, .cablock.lit::after {
  background: radial-gradient(360px circle at var(--hx, 50%) var(--hy, 0%),
              rgba(61,255,110,.07), rgba(0,0,0,0) 60%);
  mix-blend-mode: screen;
}

/* ── mobile bar ───────────────────────────────────────────────────────── */
@media (max-width: 860px) {
  .tabbar-in { background: rgba(10,10,10,.92) !important; box-shadow: 0 0 0 1px var(--edge), 0 20px 50px rgba(0,0,0,.8) !important; }
  .tabbar a { color: var(--ink-60); }
  .rail { background: rgba(0,0,0,.92) !important; border-bottom-color: var(--rule) !important; }
}

::selection { background: rgba(0,200,5,.3); color: #fff; }
.feed::-webkit-scrollbar-thumb, .log::-webkit-scrollbar-thumb { background: var(--edge); }

/* ══ hero — composed like the artwork: the figure, then its name ═══════ */
.agent-hero { position: relative; overflow: hidden; padding-bottom: clamp(40px, 6vw, 72px); }
.agent-figure {
  position: relative; max-width: 1376px; margin: 0 auto;
  -webkit-mask-image: radial-gradient(ellipse 72% 90% at 50% 38%, #000 58%, transparent 100%);
          mask-image: radial-gradient(ellipse 72% 90% at 50% 38%, #000 58%, transparent 100%);
}
.agent-figure img {
  display: block; width: 100%; height: auto;
  animation: figureIn 1.1s var(--ease) both;
}
@keyframes figureIn { from { opacity: 0; transform: scale(1.04) translateY(10px); filter: brightness(.4) } to { opacity: 1; transform: none; filter: none } }

/* The visor glows. Slow, and only on the light — the figure itself never moves. */
.agent-figure::after {
  content: ""; position: absolute; left: 50%; top: 36%; width: 22%; aspect-ratio: 1;
  transform: translate(-50%, -50%); border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, rgba(61,255,110,.22), transparent 64%);
  mix-blend-mode: screen; animation: visor 4.8s ease-in-out infinite;
}
@keyframes visor { 0%, 100% { opacity: .45 } 50% { opacity: 1 } }

.agent-copy { text-align: center; margin-top: clamp(-120px, -9vw, -48px); position: relative; z-index: 2; }
.agent-copy .kicker { color: var(--signal); font-family: var(--mono); font-size: 11px; letter-spacing: .22em; text-transform: uppercase; }
.agent-copy h1 { margin: 14px 0 18px; }
.agent-copy .lede { margin-left: auto; margin-right: auto; max-width: 60ch; }
.agent-copy .cta-row { justify-content: center; }
.agent-copy #hero-status { margin-top: 18px; color: var(--ink-30); }
.agent-hero .hero-card { margin-top: clamp(36px, 5vw, 60px); }

/* ══ holder rewards ════════════════════════════════════════════════════ */
.reward-stack { display: grid; gap: 20px; }
.reward-split {
  background: var(--panel); border-radius: 16px; padding: 24px;
  box-shadow: 0 0 0 1px var(--rule), inset 0 1px 0 rgba(255,255,255,.035);
}
.seg-bar { display: flex; height: 14px; border-radius: 999px; overflow: hidden; gap: 3px; background: var(--panel-2); }
.seg-bar i { display: block; width: var(--w); height: 100%; animation: grow 1.1s var(--ease) both; transform-origin: left; }
.seg-bar i.hold { background: var(--signal); box-shadow: 0 0 16px rgba(0,200,5,.5); }
.seg-bar i.burn { background: #fff; animation-delay: .12s; }
.seg-bar i.keep { background: var(--ink-30); animation-delay: .24s; }
@keyframes grow { from { transform: scaleX(0) } to { transform: scaleX(1) } }
.split-legend { display: grid; gap: 10px; margin-top: 18px; font-size: 14.5px; color: var(--ink-80); }
.split-legend b { color: #fff; font-family: var(--mono); font-weight: 600; margin-right: 6px; }
.split-legend .dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 10px; vertical-align: 1px; }
.dot.hold { background: var(--signal); box-shadow: 0 0 8px rgba(0,200,5,.6); }
.dot.burn { background: #fff; }
.dot.keep { background: var(--ink-30); }

@media (max-width: 860px) {
  .agent-copy { margin-top: -28px; }
  .agent-copy .cta-row { flex-direction: column; align-items: stretch; }
  .agent-figure { -webkit-mask-image: radial-gradient(ellipse 95% 90% at 50% 40%, #000 55%, transparent 100%);
                          mask-image: radial-gradient(ellipse 95% 90% at 50% 40%, #000 55%, transparent 100%); }
}
@media (prefers-reduced-motion: reduce) {
  .agent-figure img, .agent-figure::after, .seg-bar i { animation: none; }
}
