/* WageBot: the payroll office. Cool form-paper ground, navy ink, IBM Plex, and one burnt orange that means two
   things only: the slice of a reward that buys back and burns an agent's coin, and the one main action. The home
   page shows one real paid task as a pay slip, so where the money goes is never a guess.
   IBM Plex Sans does all the talking; IBM Plex Mono only reads amounts, handles, tickers and addresses.
   No eyebrow labels, no accent words in headlines, no arrows on links, no "·" joiners. */

@font-face { font-family: "IBM Plex Sans"; src: url("/fonts/IBMPlexSans.ttf") format("truetype"); font-weight: 100 700; font-stretch: 85% 100%; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("/fonts/IBMPlexMono-Regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("/fonts/IBMPlexMono-Medium.ttf") format("truetype"); font-weight: 500; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("/fonts/IBMPlexMono-SemiBold.ttf") format("truetype"); font-weight: 600; font-display: swap; }

:root {
  color-scheme: light;
  --ground: #eef1f4;
  --surface: #ffffff;
  --surface-2: #e4e9ee;
  --surface-3: #d6dde4;
  --line: rgba(15, 27, 45, 0.09);
  --line-2: rgba(15, 27, 45, 0.16);
  --line-3: rgba(15, 27, 45, 0.3);
  --ink: #0f1b2d;
  --ink-2: #3c4a5c;
  --muted: #5d6979;
  --accent: #c9431f;
  --accent-deep: #a8361a;
  --accent-wash: rgba(201, 67, 31, 0.08);
  --on-accent: #ffffff;
  --good: #1b7a4a;
  --bad: #b3261e;
  --warn: #8a5a00;
  --focus: #2457d6;

  --sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --gutter: clamp(16px, 4vw, 40px);
  --max: 1200px;
  --r: 6px;
  --r-lg: 10px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --z-bar: 30;
  --z-menu: 40;
  --z-toast: 60;
  --z-dialog: 80;
  --z-skip: 100;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 80px; -webkit-tap-highlight-color: transparent; }
body { margin: 0; background: var(--ground); color: var(--ink); font: 400 17px/1.55 var(--sans); -webkit-font-smoothing: antialiased; overflow-x: clip; }
main { display: block; min-height: 60vh; outline: none; padding-bottom: 48px; overflow-x: clip; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration-color: var(--line-3); text-underline-offset: 3px; }
a:hover { text-decoration-color: currentColor; }
button, input, textarea, select { font: inherit; color: inherit; }
a, button, input, select, textarea, label, summary { touch-action: manipulation; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
[hidden] { display: none !important; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; font-size: 0.9em; }
.num { font-family: var(--mono); font-variant-numeric: tabular-nums; text-align: right; }
.muted { color: var(--muted); }
.small, small { font-size: 14px; }
.fine { color: var(--muted); font-size: 14px; margin: 8px 0 0; }
.center { text-align: center; margin-top: 28px; }
.up { color: var(--good); }
.down { color: var(--bad); }
.burn { color: var(--accent); }
.skip { position: absolute; left: 8px; top: -48px; background: var(--ink); color: var(--surface); padding: 8px 12px; border-radius: var(--r); z-index: var(--z-skip); }
.skip:focus { top: 8px; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
/* A plain label, like a field name on a form. It never sits on top of a heading. */
.kicker { font: 600 14px/1.3 var(--sans); color: var(--muted); margin: 0 0 6px; }
.accent { color: inherit; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

h1, h2 { font-family: var(--sans); font-weight: 700; letter-spacing: -0.025em; line-height: 1.02; margin: 0 0 16px; text-wrap: balance; }
h1 { font-size: clamp(40px, 5.4vw, 76px); }
h2 { font-size: clamp(30px, 3.4vw, 44px); }
h3 { font: 600 19px/1.3 var(--sans); margin: 0 0 6px; text-wrap: balance; }
p, li, dd, summary { text-wrap: pretty; }
.lede { font-size: clamp(18px, 1.5vw, 20px); line-height: 1.55; color: var(--ink-2); max-width: 34em; margin: 0 0 24px; }
.lede b { color: var(--ink); font-weight: 600; }
.text-link { font-weight: 600; color: var(--ink); text-decoration: underline; text-decoration-thickness: 2px; text-decoration-color: var(--accent); text-underline-offset: 5px; }
.text-link:hover { color: var(--accent-deep); }

/* ---- header ---------------------------------------------------------------------------------------------- */
.demo-banner { background: var(--ink); color: var(--ground); text-align: center; font-size: 14px; line-height: 1.4; padding: 8px var(--gutter); }
.topbar { position: sticky; top: 0; z-index: var(--z-bar); display: flex; align-items: center; gap: 28px; height: 66px; padding: 0 var(--gutter); background: rgba(238, 241, 244, 0.94); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line-2); }
.brand { display: inline-flex; color: var(--ink); text-decoration: none; }
.lockup { display: block; height: 28px; width: auto; }
.nav { display: flex; gap: 2px; margin-right: auto; }
.nav a { padding: 8px 12px; text-decoration: none; color: var(--ink-2); font-size: 16px; font-weight: 500; border-radius: var(--r); }
.nav a:hover { color: var(--ink); background: var(--surface-2); }
.nav a[aria-current="page"] { color: var(--ink); box-shadow: inset 0 -2px 0 var(--ink); border-radius: 0; }
.top-actions { display: flex; align-items: center; gap: 10px; }
.ca-chip-inner { display: inline-flex; align-items: center; gap: 6px; height: 38px; padding: 0 12px; border: 1px dashed var(--line-3); border-radius: var(--r); background: transparent; font-size: 12px; cursor: pointer; color: var(--ink-2); }
.ca-chip-inner.soon { cursor: default; }
.ca-chip-inner b { font-weight: 600; color: var(--ink); }
.wallet-slot { position: relative; }
.wallet-btn.on { gap: 8px; }
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); }
.live-dot.signed { background: var(--good); }
.wallet-menu { position: absolute; right: 0; top: 46px; min-width: 250px; background: var(--surface); border: 1px solid var(--line-2); border-radius: var(--r-lg); box-shadow: 0 18px 48px rgba(15, 27, 45, 0.16); padding: 8px; z-index: var(--z-menu); display: grid; gap: 2px; }
.wallet-menu p { margin: 6px 10px; font-size: 13px; color: var(--muted); }
.wallet-menu button, .wallet-menu a { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 44px; text-align: left; padding: 10px; border: 0; background: none; border-radius: var(--r); cursor: pointer; text-decoration: none; font-size: 15px; }
.wallet-menu button:hover, .wallet-menu a:hover { background: var(--surface-2); }
.wallet-menu img { width: 22px; height: 22px; border-radius: 5px; }

/* ---- buttons, fields ------------------------------------------------------------------------------------ */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 44px; padding: 0 18px; border: 1px solid var(--line-3); border-radius: var(--r); background: var(--surface); color: var(--ink); font: 600 16px/1 var(--sans); text-decoration: none; cursor: pointer; transition: background 0.15s, border-color 0.15s, transform 0.1s; white-space: nowrap; }
.btn:hover { border-color: var(--ink); }
.btn:active { transform: translateY(1px); }
.btn:disabled, .btn.disabled { opacity: 0.45; cursor: not-allowed; transform: none; }
.btn-primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.btn-primary:hover { background: var(--accent-deep); border-color: var(--accent-deep); }
.btn-sell { background: var(--ink); border-color: var(--ink); color: var(--surface); }
.btn-small { height: 36px; padding: 0 14px; font-size: 15px; }
.btn-large { height: 54px; padding: 0 26px; font-size: 18px; }
.btn-block { width: 100%; height: 52px; font-size: 17px; }
.link-btn { font: 500 15px/1.3 var(--sans); color: var(--ink-2); background: none; border: 0; padding: 0; cursor: pointer; text-decoration: underline; text-decoration-color: var(--line-3); text-underline-offset: 4px; }
.link-btn:hover { color: var(--ink); text-decoration-color: currentColor; }
.chip { display: inline-flex; align-items: center; height: 28px; padding: 0 10px; border: 1px solid var(--line-2); border-radius: var(--r); background: var(--surface); font-size: 13px; font-weight: 500; color: var(--ink-2); vertical-align: middle; }
.chip.done { border-color: var(--good); color: var(--good); }
h2 .chip, h1 .chip { margin-left: 12px; letter-spacing: 0; }
.field { display: grid; gap: 6px; margin: 0 0 18px; align-content: start; }
.field > span { font-weight: 600; font-size: 15px; }
.field small { color: var(--muted); }
.input, .textarea, select.input { width: 100%; min-height: 46px; padding: 10px 13px; background: var(--surface); border: 1px solid var(--line-3); border-radius: var(--r); font-size: 16px; }
.input:focus, .textarea:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px rgba(15, 27, 45, 0.08); }
.textarea { min-height: 104px; resize: vertical; line-height: 1.5; }
.textarea.tall { min-height: 156px; }
.input-group { display: flex; align-items: stretch; border: 1px solid var(--line-3); border-radius: var(--r); background: var(--surface); }
.input-group .input { border: 0; background: transparent; min-width: 0; }
.input-group .input:focus { box-shadow: none; }
.input-group:focus-within { border-color: var(--ink); box-shadow: 0 0 0 3px rgba(15, 27, 45, 0.08); }
.prefix, .suffix { display: flex; align-items: center; padding: 0 12px; color: var(--muted); font-size: 14px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.seg { display: inline-flex; border: 1px solid var(--line-3); border-radius: var(--r); overflow: hidden; flex-wrap: wrap; background: var(--surface); }
.seg button { border: 0; background: none; padding: 9px 14px; font: 500 14px/1 var(--sans); cursor: pointer; color: var(--ink-2); }
.seg button + button { border-left: 1px solid var(--line-2); }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--surface); }
.quick { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 14px; }
.quick button { border: 1px solid var(--line-3); background: var(--surface); border-radius: var(--r); padding: 7px 11px; font: 500 13px/1 var(--mono); cursor: pointer; }
.quick button:hover { border-color: var(--ink); }
.range { width: 100%; accent-color: var(--accent); }
.burn-pick { display: flex; align-items: center; gap: 16px; margin-bottom: 8px; }
.burn-pick b { font: 600 22px/1 var(--mono); min-width: 60px; text-align: right; color: var(--accent); }
.skeleton { background: var(--surface-2); border-radius: var(--r-lg); }

/* ---- the pay slip: one paid task, line by line ---------------------------------------------------------- */
.slip { margin: 0; background: var(--surface); border-radius: var(--r-lg); box-shadow: 0 1px 2px rgba(15, 27, 45, 0.06), 0 18px 40px rgba(15, 27, 45, 0.08); overflow: hidden; }
.slip-head { display: flex; align-items: center; gap: 14px; padding: 14px 22px; background: var(--ink); color: var(--surface); }
.slip-head b { font-size: 17px; font-weight: 600; letter-spacing: 0.01em; }
.slip-head .mono { color: rgba(255, 255, 255, 0.65); font-size: 13px; }
.slip-paid { margin-left: auto; padding: 4px 10px; border: 1px solid rgba(255, 255, 255, 0.4); border-radius: var(--r); font-size: 13px; font-weight: 600; }
.slip-task { padding: 20px 22px 18px; border-bottom: 1px dashed var(--line-3); }
.slip-title { margin: 0 0 6px; font-size: clamp(19px, 1.7vw, 23px); font-weight: 600; line-height: 1.3; letter-spacing: -0.01em; }
.slip-who { margin: 0; font-size: 15px; color: var(--ink-2); }
.slip-who .mono { color: var(--muted); }
.slip-lines { width: 100%; border-collapse: collapse; }
.slip-lines th, .slip-lines td { padding: 14px 22px; border-bottom: 1px solid var(--line); vertical-align: top; }
.slip-lines th { text-align: left; font-weight: 500; font-size: 16px; }
.slip-lines th small { display: block; margin-top: 2px; font-size: 14px; font-weight: 400; color: var(--muted); }
.slip-lines td { text-align: right; font-size: 17px; font-weight: 500; white-space: nowrap; }
.slip-lines .minus td { color: var(--ink-2); }
/* the burn: the one line in orange, with a mark in the margin */
.slip-lines .burn th, .slip-lines .burn td { background: var(--accent-wash); }
.slip-lines .burn th { box-shadow: inset 4px 0 0 var(--accent); }
.slip-lines .burn td, .slip-lines .burn th small { color: var(--accent-deep); }
.slip-lines .total th, .slip-lines .total td { border-bottom: 0; border-top: 2px solid var(--ink); font-weight: 600; font-size: 18px; }
.slip-lines .total td { font-size: 20px; }
.slip-foot { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin: 0; padding: 12px 22px; background: var(--surface-2); font-size: 14px; color: var(--muted); }
.slip-note { margin: 14px 0 0; font-size: 14px; color: var(--muted); }

/* ---- the work card: an agent and its record ------------------------------------------------------------- */
.work { position: relative; margin: 0; display: grid; gap: 16px; padding: 18px; background: var(--surface); border: 1px solid var(--line-2); border-radius: var(--r-lg); min-width: 0; }
.work-top { display: flex; align-items: center; gap: 12px; min-width: 0; }
.work-face { display: grid; place-items: center; flex: none; width: 46px; height: 46px; border-radius: 10px; background: var(--ink); color: var(--surface); font-size: 21px; font-weight: 700; }
.work-id { display: grid; min-width: 0; flex: 1; }
.work-name { font-size: 19px; font-weight: 600; line-height: 1.2; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.work-handle { display: flex; gap: 8px; flex-wrap: wrap; font-size: 14px; color: var(--muted); }
.work-busy { flex: none; padding: 4px 9px; border-radius: var(--r); background: var(--surface-2); color: var(--ink); font-size: 13px; font-weight: 600; }
/* the record reads like lines on a slip: what, then the figure on the right */
.work-figs { display: grid; gap: 0; margin: 0; border-top: 1px solid var(--line-2); }
.work-figs > div { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 7px 0; border-bottom: 1px solid var(--line); min-width: 0; }
.work-figs dt { font-size: 14px; color: var(--muted); }
.work-figs dd { margin: 0; font-size: 15px; font-weight: 600; white-space: nowrap; }
.work-burn { display: flex; align-items: center; gap: 8px; margin: 0; font-size: 14px; color: var(--accent-deep); font-weight: 500; }
.work-burn i { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.work-demo { position: absolute; right: 14px; bottom: 12px; font-size: 12px; color: var(--muted); }
.work-hero { padding: 24px; gap: 20px; }
.work-hero .work-face { width: 64px; height: 64px; font-size: 30px; border-radius: 14px; }
.work-hero .work-name { font-size: 26px; white-space: normal; }
.work-hero .work-figs dd { font-size: 18px; }
.work-mini { padding: 14px; gap: 10px; }

/* Agents in a list: the work card, then what it does. */
.rack { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 18px; }
.rack.small { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); margin-top: 12px; }
.rack-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.agent-card { display: grid; align-content: start; gap: 0; text-decoration: none; color: inherit; border-radius: var(--r-lg); transition: transform 0.15s var(--ease), box-shadow 0.15s var(--ease); }
.agent-card .work { border-bottom-left-radius: 0; border-bottom-right-radius: 0; }
@media (hover: hover) and (pointer: fine) { a.agent-card:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(15, 27, 45, 0.1); } }
.agent-card.skeleton { min-height: 280px; }
.agent-foot { display: grid; gap: 10px; padding: 14px 18px 16px; background: var(--surface); border: 1px solid var(--line-2); border-top: 0; border-radius: 0 0 var(--r-lg) var(--r-lg); }
.agent-title { display: flex; align-items: baseline; gap: 8px; }
.agent-title strong { font-size: 18px; }
.ticker { font-size: 13px; padding: 3px 7px; border: 1px solid var(--line-3); border-radius: 4px; }
.agent-about { margin: 0; color: var(--ink-2); font-size: 15px; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.skills { display: flex; flex-wrap: wrap; gap: 6px; }
.skill { font-size: 13px; padding: 3px 8px; background: var(--surface-2); border-radius: 4px; color: var(--ink-2); }

/* ---- home ------------------------------------------------------------------------------------------------ */
/* The headline across the top; under it the pay slip on the left, the pitch, the steps and the button on the right. */
.intro { padding-top: clamp(40px, 5vw, 72px); }
.intro h1 { font-size: clamp(40px, 4.8vw, 70px); margin-bottom: clamp(28px, 3.4vw, 44px); }
.intro-grid { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr); gap: 32px 56px; align-items: start; }
.intro-side .lede { margin-bottom: 20px; }
.intro-steps { list-style: none; margin: 0 0 28px; padding: 0; counter-reset: s; border-top: 1px solid var(--line-2); }
.intro-steps li { position: relative; padding: 14px 0 14px 44px; border-bottom: 1px solid var(--line-2); color: var(--ink-2); counter-increment: s; }
.intro-steps li::before { content: counter(s); position: absolute; left: 0; top: 13px; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; border: 1.5px solid var(--ink); font: 600 14px/1 var(--mono); color: var(--ink); }
.intro-steps b { color: var(--ink); font-weight: 600; }
.intro-actions { display: flex; align-items: center; gap: 14px 26px; flex-wrap: wrap; }

.section { padding-top: clamp(76px, 9vw, 116px); }
.section-sm { padding-top: 48px; }
.section-intro { max-width: 680px; margin-bottom: 26px; }
.section-intro h2 { margin-bottom: 12px; }
.section-intro p { margin: 0; color: var(--ink-2); font-size: 18px; }
.head-row, .section-head { display: flex; justify-content: space-between; align-items: end; gap: 12px 24px; flex-wrap: wrap; margin-bottom: 20px; }
.head-row h2, .section-head h2 { margin-bottom: 6px; }
.head-row p { margin: 0; color: var(--ink-2); max-width: 40em; }
.row-head { display: flex; justify-content: space-between; align-items: end; gap: 20px; flex-wrap: wrap; }
.two-col { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 72px); align-items: start; }
.tally { display: flex; flex-wrap: wrap; column-gap: 0.35em; margin: 16px 0 0; color: var(--muted); font-size: 15px; }
.tally > span { white-space: nowrap; }
.tally b { color: var(--ink); font-family: var(--mono); font-weight: 600; font-size: 0.95em; }
.example-label { margin: 0 0 10px; font-weight: 600; }
.example { max-width: 680px; margin: 0 0 22px; }

/* Who it's for, as a form: the role, what goes in, what comes out. */
.form-table { width: 100%; border-collapse: collapse; margin-top: 8px; font-size: 16px; }
.form-table thead th { text-align: left; font-size: 14px; font-weight: 600; color: var(--muted); padding: 0 16px 10px 0; border-bottom: 2px solid var(--ink); }
.form-table tbody th { text-align: left; vertical-align: top; font-size: 21px; font-weight: 600; letter-spacing: -0.01em; padding: 18px 16px 18px 0; white-space: nowrap; border-bottom: 1px solid var(--line-2); }
.form-table td { vertical-align: top; padding: 18px 16px 18px 0; border-bottom: 1px solid var(--line-2); color: var(--ink-2); min-width: 12em; }
.form-table td:last-child { min-width: 0; white-space: nowrap; padding-right: 0; }

/* ---- the board ---------------------------------------------------------------------------------------------- */
.orders { display: grid; gap: 8px; }
.order { display: grid; grid-template-columns: 126px minmax(0, 1fr) auto; align-items: center; gap: 18px; padding: 14px 18px; background: var(--surface); border: 1px solid var(--line-2); border-radius: var(--r-lg); text-decoration: none; color: inherit; transition: border-color 0.15s; }
.order:hover { border-color: var(--ink); }
.order.skeleton { height: 76px; }
.order-reward { display: flex; align-items: baseline; gap: 5px; }
.order-reward b { font: 600 26px/1 var(--mono); letter-spacing: -0.03em; }
.order-reward small { font: 500 12px/1 var(--mono); color: var(--muted); }
.order-main { display: grid; gap: 4px; min-width: 0; }
.order-title { font-weight: 600; font-size: 17px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.order-meta { font-size: 14px; color: var(--muted); }
.status { font: 600 13px/1 var(--sans); padding: 6px 9px; border-radius: var(--r); border: 1px solid var(--line-3); white-space: nowrap; }
.status.open { color: var(--surface); background: var(--ink); border-color: var(--ink); }
.status.working { color: var(--ink); border-color: var(--ink); }
.status.paid { color: var(--good); border-color: var(--good); }
.status.muted { color: var(--muted); }
.status.warn { color: var(--warn); border-color: var(--warn); }

/* Payments and burns: one line each, its transaction at the end. */
.log { list-style: none; margin: 18px 0 0; padding: 0; border-top: 1px solid var(--line-2); }
.log-row { display: grid; grid-template-columns: 74px minmax(0, 1fr) auto; gap: 12px; align-items: baseline; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.log-time { font-size: 13px; color: var(--muted); }
.log-what { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.log-what a { text-decoration: none; font-weight: 600; }
.punch-dot, .burn-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 8px; vertical-align: 1px; }
.punch-dot { background: var(--ink); }
.burn-dot { background: var(--accent); }
.faq-side .faq details:last-child { border-bottom: 1px solid var(--line-2); margin-bottom: 26px; }
.step-n { font-size: 14px; color: var(--muted); }

/* ---- the payout split ---------------------------------------------------------------------------------- */
.split { display: grid; gap: 14px; }
.split-bar { display: flex; height: 46px; border-radius: var(--r); overflow: hidden; gap: 2px; }
.split-bar span { display: flex; align-items: center; padding: 0 12px; min-width: 0; }
.split-bar b { font-size: 14px; font-weight: 600; }
.split-agent { background: var(--ink); color: var(--surface); }
.split-burn { background: var(--accent); color: var(--on-accent); }
.split-house { background: var(--surface-3); color: var(--ink); }
.split-legend { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font-size: 15px; color: var(--ink-2); }
.split-legend li { display: flex; align-items: center; gap: 10px; background: none !important; color: var(--ink-2) !important; }
.split-legend i { width: 14px; height: 14px; border-radius: 3px; flex: none; }
.split-legend .split-agent i { background: var(--ink); }
.split-legend .split-burn i { background: var(--accent); }
.split-legend .split-house i { background: var(--surface-3); }

.closing { padding: clamp(88px, 11vw, 140px) var(--gutter) 40px; }
.closing h2 { font-size: clamp(38px, 5vw, 68px); max-width: 13em; margin: 0 0 28px; }
.assure { color: var(--ink-2); font-size: 15px; max-width: 34em; margin: 14px 0 24px; }
.closing .assure { margin: 18px 0 0; }
.faq-home { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 40px; align-items: start; }
.faq-home .faq summary { font-size: 18px; }
.faq-home .faq details:last-child { border-bottom: 1px solid var(--line-2); }
.faq-home .faq p { color: var(--ink-2); max-width: 46em; }

.ca-box { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 12px; max-width: 640px; }
.ca-box .kicker { margin: 0; color: var(--ink-2); }
.ca-box code { font-family: var(--mono); font-size: 14px; user-select: all; overflow-wrap: anywhere; }
.ca-box.soon code { font-weight: 600; }
.ca-box small { width: 100%; color: var(--muted); }
.empty { padding: 36px 20px; text-align: center; border: 1px dashed var(--line-3); border-radius: var(--r-lg); grid-column: 1 / -1; background: var(--surface); }
.empty h3 { font-size: 22px; }
.empty p { color: var(--muted); margin: 0 0 14px; }
.empty-page { display: grid; grid-template-columns: 320px 1fr; gap: 48px; align-items: center; padding-top: 64px; }

/* ---- pages -------------------------------------------------------------------------------------------------- */
.page-head { padding-top: clamp(36px, 5vw, 64px); padding-bottom: 22px; }
.page-head h1 { font-size: clamp(38px, 5vw, 62px); }
.controls { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; margin: 6px 0 22px; }
.controls .input { max-width: 380px; }
.panel { background: var(--surface); border: 1px solid var(--line-2); border-radius: var(--r-lg); min-width: 0; }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 18px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.panel-head h2 { font: 600 18px/1.2 var(--sans); letter-spacing: -0.01em; margin: 0; }
.panel-body { padding: 18px; }
.statline { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: 24px 0; border-top: 2px solid var(--ink); }
.statline > div { padding: 14px 16px 4px 0; min-width: 0; }
.statline dt { font-size: 14px; color: var(--muted); }
.statline dd { margin: 4px 0 0; font: 600 clamp(19px, 1.9vw, 24px)/1.2 var(--mono); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.statline.compact { margin: 20px 0 14px; }
.statline.compact dd { font-size: 20px; }
.facts { list-style: none; margin: 14px 0 10px; padding: 0; }
.facts li { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line-2); font-size: 15px; }
.facts li > span:first-child { color: var(--muted); }
.result { display: grid; gap: 6px; padding: 14px 16px; border-radius: var(--r-lg); border: 1px solid var(--line-2); margin: 12px 0 0; font-size: 15px; background: var(--surface); }
.result.pass { border-color: var(--good); }
.result.fail { border-color: var(--bad); }
.key { display: block; padding: 10px; background: var(--surface-2); border-radius: var(--r); overflow-wrap: anywhere; user-select: all; }
.snippet { margin: 10px 0; padding: 12px 14px; background: var(--ink); color: #dbe3ec; border-radius: var(--r); font-size: 13px; line-height: 1.55; white-space: pre-wrap; overflow-wrap: anywhere; }
.addr { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; }
.addr button { border: 1px solid var(--line-3); background: var(--surface); border-radius: 4px; padding: 4px 8px; font: 500 12px/1 var(--sans); cursor: pointer; }
.agent-head { display: grid; grid-template-columns: 380px minmax(0, 1fr); gap: 48px; align-items: start; padding-top: 36px; }
.agent-id h1 { margin-bottom: 8px; }
.agent-id .sub { color: var(--muted); font-size: 15px; margin: 0 0 16px; }
.agent-id .lede { margin-bottom: 14px; }
.operator { margin-top: 30px; border-color: var(--ink); }
.coin-block { padding-top: 56px; }
.coin-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(300px, 380px); gap: 24px; align-items: start; }
.col { display: grid; gap: 24px; min-width: 0; }
.chart-wrap { position: relative; height: 280px; }
.chart-wrap canvas { width: 100%; height: 100%; display: block; }
.chart-empty { position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); font-size: 14px; }
.chart-readout { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 13px; color: var(--ink-2); }
.chart-readout b { font-weight: 600; margin-left: 4px; }
.trade-switch { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-bottom: 14px; }
.trade-switch button { height: 42px; border: 1px solid var(--line-3); background: var(--surface); border-radius: var(--r); font-weight: 600; cursor: pointer; }
.trade-switch button[aria-pressed="true"] { background: var(--ink); color: var(--surface); border-color: var(--ink); }
.settings-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 0 0 12px; font-size: 14px; color: var(--muted); }
.quote { display: grid; gap: 4px; min-height: 44px; margin-bottom: 12px; font-size: 15px; }
.holders { list-style: none; margin: 0; padding: 0; }
.holders li { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.who { display: inline-flex; gap: 8px; align-items: center; }
.tag-chip { font-size: 11px; font-weight: 600; padding: 3px 6px; border: 1px solid var(--line-3); border-radius: 4px; color: var(--muted); }
.tabs { display: flex; gap: 4px; }
.tabs button { border: 0; background: none; padding: 7px 12px; border-radius: var(--r); cursor: pointer; font-weight: 600; color: var(--muted); }
.tabs button[aria-selected="true"] { color: var(--ink); background: var(--surface-2); }
.table-scroll { overflow-x: auto; }
.trade-list { max-height: 520px; overflow-y: auto; }
.ledger { width: 100%; border-collapse: collapse; font-size: 14px; }
.ledger th { text-align: left; font-size: 13px; font-weight: 600; color: var(--muted); padding: 10px 14px; border-bottom: 1px solid var(--line-3); white-space: nowrap; }
.ledger td { padding: 11px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.ledger th.num, .ledger td.num { text-align: right; }
.ledger tr.fresh td { animation: fresh 1.6s var(--ease); }
@keyframes fresh { from { background: var(--accent-wash); } to { background: transparent; } }
[data-motion="off"] .ledger tr.fresh td { animation: none; }
.comments { list-style: none; margin: 0; padding: 0 18px 18px; }
.comments li { padding: 10px 0; border-bottom: 1px solid var(--line); }
.comments .by { font-size: 13px; color: var(--muted); }
.comments p { margin: 4px 0 0; overflow-wrap: anywhere; }
.comment-form { padding: 18px; display: grid; gap: 10px; }

/* ---- a task ---------------------------------------------------------------------------------------------- */
.task-head { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 30px; align-items: end; padding-top: 36px; padding-bottom: 24px; border-bottom: 1px solid var(--line-2); margin-bottom: 24px; }
.task-head h1 { font-size: clamp(34px, 4.4vw, 60px); }
.task-head .sub { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; font-size: 15px; }
.ticket-reward { display: grid; justify-items: end; gap: 4px; padding: 16px 20px; background: var(--surface); border: 1px solid var(--line-2); border-top: 4px solid var(--ink); border-radius: var(--r-lg); }
.ticket-reward .kicker { margin: 0; }
.ticket-reward b { font: 600 48px/1 var(--mono); letter-spacing: -0.04em; }
.ticket-reward small { font: 500 13px/1 var(--mono); color: var(--muted); }
.task-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(300px, 380px); gap: 24px; align-items: start; }
.brief { margin: 0; white-space: pre-wrap; color: var(--ink-2); }
.delivered-text { margin: 0 0 10px; padding: 14px; background: var(--ground); border-radius: var(--r); white-space: pre-wrap; font: 400 15px/1.5 var(--sans); max-height: 480px; overflow: auto; }
.timeline { list-style: none; margin: 0; padding: 8px 18px 18px; }
.timeline li { display: grid; grid-template-columns: 86px 1fr auto; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.status-line { margin: 0 0 12px; font-weight: 600; }
.actions { display: grid; gap: 10px; }
.actions .reject summary { cursor: pointer; color: var(--ink-2); font-size: 15px; }
.actions .reject[open] { display: grid; gap: 8px; }
.claim, .deliver { display: grid; gap: 10px; }
.mini-card { padding: 16px; background: var(--ground); border-radius: 0 0 var(--r-lg) var(--r-lg); }

/* ---- forms with stages (post, register, launch) --------------------------------------------------------- */
.launch { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 32px; align-items: start; }
.stages { display: grid; gap: 18px; }
.stage { background: var(--surface); border: 1px solid var(--line-2); border-radius: var(--r-lg); }
.stage[data-state="locked"] { opacity: 0.55; }
.stage[data-state="locked"] .stage-body { display: none; }
.stage[data-state="done"] { border-color: var(--ink); }
.stage-head { display: flex; gap: 16px; padding: 20px; }
.stage-head h2 { font: 600 21px/1.2 var(--sans); letter-spacing: -0.01em; margin: 0 0 4px; }
.stage-head p { margin: 0; color: var(--muted); font-size: 15px; }
.stage-num { display: grid; place-items: center; flex: none; width: 36px; height: 36px; border-radius: 50%; border: 1.5px solid var(--ink); font-weight: 600; font-size: 13px; }
.stage[data-state="done"] .stage-num { background: var(--ink); color: var(--surface); }
.stage-body { padding: 0 20px 20px; }
.pick { display: grid; gap: 8px; }
.pick-agent { display: grid; gap: 2px; text-align: left; padding: 12px 14px; border: 1px solid var(--line-3); border-radius: var(--r); background: var(--surface); cursor: pointer; }
.pick-agent span { font-size: 13px; color: var(--muted); }
.pick-agent.on { border-color: var(--ink); box-shadow: 0 0 0 3px rgba(15, 27, 45, 0.08); }
.art-choice { display: grid; grid-template-columns: 120px 1fr; gap: 16px; align-items: center; margin-bottom: 16px; }
.art { width: 120px; height: 120px; border-radius: var(--r-lg); overflow: hidden; background: var(--surface-2); }
.art img { width: 100%; height: 100%; object-fit: cover; }
.art-choice input[type="file"] { margin-top: 8px; font-size: 14px; max-width: 100%; }
.links summary { cursor: pointer; font-weight: 600; font-size: 15px; margin-bottom: 10px; }
.quote-table { width: 100%; border-collapse: collapse; font-size: 15px; }
.quote-table td { padding: 8px 0; border-bottom: 1px solid var(--line); }
.quote-table tr.total td { font-weight: 700; border-bottom: 0; }
.wallet-ask { display: grid; gap: 4px; padding: 14px 16px; border-radius: var(--r-lg); background: var(--surface-2); font-size: 15px; margin: 14px 0; }
.check-row { display: flex; gap: 10px; align-items: flex-start; font-size: 15px; margin: 0 0 14px; color: var(--ink-2); }
.check-row input { width: 18px; height: 18px; margin-top: 3px; flex: none; accent-color: var(--ink); }
.progress-steps { list-style: none; padding: 0; margin: 16px 0 0; display: grid; gap: 6px; font-size: 15px; counter-reset: s; }
.progress-steps li { counter-increment: s; color: var(--muted); }
.progress-steps li::before { content: counter(s) ". "; font-family: var(--mono); }
.progress-steps li.done { color: var(--ink); }
.progress-steps li.done::before { content: "✓ "; color: var(--good); }
.progress-steps li.active { color: var(--ink); font-weight: 600; }
.launch-side { position: sticky; top: 90px; display: grid; gap: 16px; }
.notes { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font-size: 15px; color: var(--ink-2); }
.notes li { position: relative; padding-left: 16px; }
.notes li::before { content: ""; position: absolute; left: 0; top: 0.6em; width: 6px; height: 6px; border-radius: 50%; background: var(--ink-2); }
.setup-status { border: 1px dashed var(--warn); border-radius: var(--r-lg); padding: 12px 14px; font-size: 15px; margin-top: 12px; }
.setup-status ul { margin: 6px 0; padding-left: 20px; }

.how-steps { list-style: none; padding: 0; margin: 10px 0 0; display: grid; gap: 0; border-top: 2px solid var(--ink); }
.how-step { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 340px); gap: 48px; align-items: center; padding: 30px 0; border-bottom: 1px solid var(--line-2); }
.how-step p { color: var(--ink-2); max-width: 36em; }
.prose { max-width: 760px; }
.prose p, .prose li { color: var(--ink-2); }
.prose a { color: var(--ink); }
.prose code, .docs code { font-family: var(--mono); font-size: 0.85em; background: var(--surface-2); padding: 1px 5px; border-radius: 4px; }
.faq details { border-top: 1px solid var(--line-2); padding: 15px 0; }
.faq summary { cursor: pointer; font-weight: 600; }
.faq p { margin: 10px 0 0; color: var(--ink-2); }
.notes-grid { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; margin: 36px 0 0; }
.notes-grid li { border-top: 2px solid var(--ink); padding-top: 14px; }
.notes-grid p { color: var(--ink-2); margin: 0; }
.token-page .panel { margin-top: 24px; }
.docs-grid { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 40px; align-items: start; }
.docs-toc { position: sticky; top: 90px; display: grid; gap: 8px; font-size: 15px; }
.docs-toc a { color: var(--ink-2); text-decoration: none; }
.docs-toc a:hover { color: var(--ink); }
.docs-body h2 { margin-top: 40px; font-size: clamp(28px, 3vw, 38px); }
.endpoint { padding: 14px 0; border-top: 1px solid var(--line); }
.endpoint h3 { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.verb { font: 600 12px/1 var(--mono); padding: 5px 7px; border-radius: 4px; }
.verb.get { background: var(--surface-2); color: var(--ink); }
.verb.post { background: var(--ink); color: var(--surface); }

/* ---- the confirm dialog ----------------------------------------------------------------------------------- */
dialog.confirm { z-index: var(--z-dialog); width: min(440px, calc(100vw - 32px)); padding: 26px; background: var(--surface); color: var(--ink); border: 0; border-radius: var(--r-lg); box-shadow: 0 24px 64px rgba(15, 27, 45, 0.3); }
dialog.confirm::backdrop { background: rgba(15, 27, 45, 0.45); }
dialog.confirm h2 { font-size: 28px; margin-bottom: 10px; }
dialog.confirm p { color: var(--ink-2); margin: 0 0 22px; }
.confirm-actions { display: flex; justify-content: flex-end; gap: 10px; flex-wrap: wrap; }

/* ---- footer, tab bar, toasts ------------------------------------------------------------------------------ */
.footer { margin-top: 64px; border-top: 1px solid var(--line-2); padding: 44px 0 32px; background: var(--surface); }
.footer-grid { display: grid; grid-template-columns: minmax(0, 2fr) 1fr 1fr; gap: 32px; }
.footer-brand .lockup { height: 26px; color: var(--ink); }
.footer-brand p { color: var(--ink-2); max-width: 32em; font-size: 15px; }
.footer-links { display: grid; align-content: start; gap: 10px; font-size: 15px; }
.footer-links a { text-decoration: none; color: var(--ink-2); }
.footer-links a:hover { color: var(--ink); text-decoration: underline; }
.footer-base { display: flex; justify-content: space-between; gap: 20px; align-items: flex-start; margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--line-2); font-size: 14px; color: var(--muted); }
.footer-base p { margin: 0; max-width: 60em; }
.tabbar { display: none; }
.toasts { position: fixed; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); z-index: var(--z-toast); display: grid; gap: 8px; max-width: min(380px, calc(100vw - 32px)); }
.toast { background: var(--ink); color: var(--surface); padding: 12px 16px; border-radius: var(--r-lg); font-size: 15px; display: flex; gap: 10px; justify-content: space-between; box-shadow: 0 12px 32px rgba(15, 27, 45, 0.25); }
.toast.error { background: var(--bad); }
.toast a { color: inherit; }

/* ---- smaller screens -------------------------------------------------------------------------------------- */
@media (max-width: 1000px) {
  .intro-grid, .two-col, .coin-layout, .launch, .task-layout, .agent-head, .faq-home { grid-template-columns: minmax(0, 1fr); }
  .intro-side { order: -1; }
  .launch-side { position: static; }
  .agent-card-big .work { max-width: 460px; }
  .rack-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .nav, .ca-chip, .top-cta { display: none; }
  .top-actions { margin-left: auto; }
  .topbar { gap: 12px; height: 58px; }
  .lockup { height: 24px; }
  .tabbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: var(--z-bar); display: grid; grid-template-columns: repeat(4, 1fr); background: var(--surface); border-top: 1px solid var(--line-2); padding-bottom: env(safe-area-inset-bottom); }
  .tabbar a { display: grid; place-items: center; height: 56px; font-size: 14px; font-weight: 600; text-decoration: none; color: var(--muted); }
  .tabbar a[aria-current="page"] { color: var(--ink); box-shadow: inset 0 2px 0 var(--accent); }
  body { padding-bottom: 64px; }
  html { scroll-padding-bottom: calc(64px + env(safe-area-inset-bottom)); }
  .toasts { bottom: calc(68px + env(safe-area-inset-bottom)); left: 16px; right: 16px; max-width: none; }
  .intro-actions .btn { width: 100%; }
  .slip-head, .slip-task, .slip-lines th, .slip-lines td, .slip-foot { padding-left: 16px; padding-right: 16px; }
  .slip-lines th { font-size: 15px; }
  .order { grid-template-columns: 86px minmax(0, 1fr); }
  .order .status { grid-column: 2; justify-self: start; }
  .order-reward b { font-size: 22px; }
  .order-title { white-space: normal; }
  .notes-grid, .footer-grid, .grid-2, .docs-grid { grid-template-columns: minmax(0, 1fr); }
  .docs-toc { position: static; }
  .how-step { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .empty-page { grid-template-columns: minmax(0, 1fr); }
  .statline { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .task-head { grid-template-columns: minmax(0, 1fr); }
  .ticket-reward { justify-items: start; }
  .footer-base { flex-direction: column; }
  .log-row { grid-template-columns: 60px minmax(0, 1fr); }
  .log-row > :last-child { grid-column: 2; }
  /* On phones the agents are a row you swipe; the next card peeks past the edge. */
  .rack-row { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 82%; overflow-x: auto; scroll-snap-type: x mandatory; overscroll-behavior-x: contain; padding-bottom: 10px; }
  .rack-row > * { scroll-snap-align: start; }
  /* The who-it's-for form stacks: each role becomes its own block. */
  .form-table, .form-table tbody, .form-table tr, .form-table th, .form-table td { display: block; }
  .form-table thead { display: none; }
  .form-table tr { padding: 18px 0; border-bottom: 1px solid var(--line-2); }
  .form-table tbody th, .form-table td { border: 0; padding: 0 0 8px; min-width: 0; white-space: normal; }
}
@media (pointer: coarse) {
  .btn-small, .ca-chip-inner, .seg button, .quick button, .tabs button, button.chip { min-height: 44px; }
}
.proof > span { white-space: nowrap; }
