/* Multipad. The look, layered over the base components in style.css. DESIGN.md is the contract.
   Warm paper and ink, one burnt-orange accent, a geometric display face, soft 12px corners on
   controls (no pills), 24px on cards. Chain colours appear only as dots and chips. Green and red only
   ever mean up and down. */

:root {
  --font: 'Manrope', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-display: 'Syne', 'Manrope', ui-sans-serif, system-ui, sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  --r-card: 24px; --r-inner: 14px; --r-ctl: 12px;
  --bg: #f4f1ea; --surface: #fffdf8; --surface-2: #ece7dc; --line: #ddd6c8;
  --ink: #14110d; --muted: #6e675c; --accent: #2f9e5f; --accent-ink: #ffffff; --accent-text: #23804b;
  --up: #178a4c; --down: #c9341a;
  --c-sol: #9945ff; --c-bnb: #f0b90b; --c-rh: #1fb954;
  color-scheme: light;
}
:root[data-theme='dark'] {
  --bg: #0f0e0c; --surface: #181612; --surface-2: #221f1a; --line: #332e27;
  --ink: #f5f1ea; --muted: #a39b8d; --accent: #4fcf86; --accent-ink: #14110d; --accent-text: #7fe3a6;
  --up: #3ecf7a; --down: #ff6a4a;
  color-scheme: dark;
}
body { background: var(--bg); font-family: var(--font); }
a:not(.btn):not(.btn-secondary):not(.card):not(.wordmark):not(.tag):not(.chip):not([class*='btn']) { color: var(--accent-text); }
.tape a, .nav a, .foot-right a, .wm { color: inherit; }

/* ---------- type ---------- */
.display { font-family: var(--font-display); font-weight: 800; text-transform: none; letter-spacing: -0.02em; line-height: 1.04; }
.display em { font-style: normal; color: var(--accent-text); }
.eyebrow { font-family: var(--font-mono); font-size: 11px; line-height: 16px; font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase; }
.section-head h2, .band h2 { font-size: 40px; }
.section-head { justify-items: start; text-align: left; }
.section-head p { margin-inline: 0; }
.page-h { font-family: var(--font-display); font-weight: 800; font-size: 38px; line-height: 42px; letter-spacing: -0.02em; }
.page-h em { font-style: normal; color: var(--accent-text); }
.lede { font-size: 17px; line-height: 27px; color: var(--muted); max-width: 58ch; }
h1, h2, h3, b, strong { font-weight: 700; }

/* ---------- controls: soft corners, not pills ---------- */
.btn, .btn-secondary, .btn-ghost { border-radius: var(--r-ctl); }
.btn { font-weight: 700; }
.btn-secondary { background: var(--surface); border-color: var(--line); }
.btn-secondary:hover { border-color: var(--ink); }
.tabs { border-radius: var(--r-ctl); background: var(--surface-2); padding: 3px; }
.tabs button { border-radius: 9px; }
.tabs button[aria-selected='true'] { background: var(--surface); color: var(--ink); border-color: var(--line); box-shadow: 0 1px 0 rgba(0,0,0,.04); }
.pill, .icon-btn { border-radius: var(--r-ctl); background: transparent; }
.meter { border-radius: 4px; }
.meter > i { background: var(--accent); }
.meter.curve > i { background: var(--up); }
.chip { font-family: var(--font-mono); font-weight: 500; border-radius: 8px; }
.chip-on { color: var(--accent-ink); background: var(--accent); border-color: var(--accent); }
.input, .textarea, .input.ro { border-radius: var(--r-inner); background: var(--surface); }
.pl i { width: 7px; height: 7px; }
.pl.sol i, .dot.sol { background: var(--c-sol); } .pl.bnb i, .dot.bnb { background: var(--c-bnb); } .pl.robinhood i, .dot.robinhood { background: var(--c-rh); }
.dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; flex: none; }
.btn.act { background: var(--accent); color: var(--accent-ink); border-color: transparent; }
button.link { color: var(--accent-text); text-decoration: underline; text-underline-offset: 2px; font: inherit; }
.card { border-radius: var(--r-card); }

/* ---------- header, tape, footer ---------- */
.header { background: color-mix(in srgb, var(--bg) 90%, transparent); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.wordmark { gap: 10px; }
.header .wordmark .mark, .mark { width: 28px; height: 28px; border-radius: 8px; display: block; flex: none; background: #fff; }
.wm { display: inline-flex; align-items: baseline; font-family: var(--font-display); font-size: 20px; font-weight: 800; letter-spacing: -0.02em; }
.wm em { font-style: normal; color: var(--accent-text); }
.nav a { border-radius: var(--r-ctl); }
.ca-pill { border: 1px solid var(--line); color: var(--ink); font-weight: 600; max-width: 260px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; background: var(--surface); }
.ca-pill:hover { border-color: var(--accent-text); color: var(--accent-text); }

.tape { border-bottom: 1px solid var(--line); overflow: hidden; background: var(--surface); }
.tape-run { display: flex; width: max-content; animation: tape 90s linear infinite; }
.tape:hover .tape-run { animation-play-state: paused; }
.tape-set { display: flex; }
.tape a { display: inline-flex; align-items: center; gap: var(--s2); height: 34px; padding: 0 var(--s4); border-right: 1px solid var(--line); font: 500 12px/16px var(--font-mono); white-space: nowrap; }
.tape a b { font-weight: 700; }
.tape a:hover b { color: var(--accent-text); }
@keyframes tape { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .tape-run { animation: none; } }

.footer { border-top: 1px solid var(--line); }
.footer .container { align-items: flex-start; padding-block: var(--s5); }
.foot-col { display: grid; gap: var(--s2); max-width: 56ch; }
.foot-right { text-align: right; justify-items: end; }
.footer a { text-decoration: underline; text-underline-offset: 2px; }

/* ---------- home: hero (two halves: words, the ladder) ---------- */
.hero2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--s5); align-items: stretch; padding-top: var(--s6); }
.hero-words { display: grid; gap: var(--s4); align-content: center; }
.hero-words h1 { font-size: clamp(40px, 5.2vw, 68px); line-height: 1.02; max-width: 14ch; }
.hero-cta { display: flex; gap: var(--s3); flex-wrap: wrap; }
.ladder { display: grid; grid-template-rows: auto 1fr auto 1fr auto; gap: 0; padding: var(--s5); border: 1px solid var(--line); border-radius: var(--r-card); background: var(--surface); }
.ladder .rung { display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; align-items: center; gap: var(--s3); padding: var(--s3) var(--s4); border: 1px solid var(--line); border-radius: var(--r-inner); background: var(--bg); }
.ladder .rung b { display: block; font-size: 15px; line-height: 20px; }
.ladder .rung small { display: block; font-size: 12px; line-height: 16px; color: var(--muted); }
.ladder .rung .n { font: 700 12px/1 var(--font-mono); color: var(--accent-text); }
.ladder .rung .dots { display: inline-flex; gap: 6px; }
.ladder .rung .dots .dot { width: 10px; height: 10px; }
.ladder .gap { width: 2px; min-height: 22px; margin-left: calc(var(--s4) + 13px); background: var(--line); }

.tiles3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s4); }
.tiles3 > div { display: grid; gap: var(--s1); padding: var(--s5); border: 1px solid var(--line); border-radius: var(--r-card); background: var(--surface); }
.tiles3 b { font-family: var(--font-display); font-weight: 800; font-size: 40px; line-height: 44px; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }

/* ---------- board: two columns of row cards ---------- */
.grid-rows { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s4); }
.card.coin-row { display: grid; grid-template-columns: 96px minmax(0, 1fr); grid-template-rows: auto auto auto; gap: var(--s2) var(--s4); padding: var(--s4); border-radius: var(--r-card); align-items: start; }
.card.coin-row:hover { border-color: var(--accent-text); }
.coin-row .pic { grid-row: 1 / 4; width: 96px; height: 96px; border-radius: 50%; overflow: hidden; border: 1px solid var(--line); background: var(--surface-2); }
.coin-row .pic img { width: 100%; height: 100%; object-fit: cover; }
.coin-row .pic .ph { width: 100%; height: 100%; display: grid; place-items: center; font: 800 40px/1 var(--font-display); color: var(--muted); }
.coin-row .top { display: flex; align-items: center; justify-content: space-between; gap: var(--s2); min-width: 0; }
.coin-row .top b { font-size: 17px; line-height: 22px; }
.tick { font: 500 12px/16px var(--font-mono); color: var(--muted); white-space: nowrap; }
.tag { height: 22px; padding: 0 8px; border-radius: 8px; display: inline-flex; align-items: center; font: 500 11px/1 var(--font-mono); background: var(--surface-2); color: var(--ink); white-space: nowrap; flex: none; }
.tag.live { background: var(--accent); color: var(--accent-ink); }
.where { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; min-width: 0; }
.where .ch { display: inline-flex; align-items: center; gap: 6px; height: 22px; padding: 0 8px; border: 1px solid var(--line); border-radius: 8px; font: 500 11px/1 var(--font-mono); color: var(--muted); white-space: nowrap; background: var(--surface); }
.where .ch.live { color: var(--ink); border-color: var(--ink); }
.where .ch.busy { border-style: dashed; color: var(--ink); }
.coin-row .bottom { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: var(--s3); }
.quote-v { display: block; font-size: 19px; line-height: 24px; font-weight: 700; letter-spacing: -0.01em; }
.quote-l { display: block; font-size: 11px; line-height: 14px; color: var(--muted); }
.delta { height: 24px; padding: 0 8px; border-radius: 8px; display: inline-flex; align-items: center; font: 700 12px/16px var(--font-mono); background: color-mix(in srgb, currentColor 12%, transparent); }
.curve-line { grid-column: 2; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: var(--s2); font-size: 11px; line-height: 14px; color: var(--muted); }
.curve-line .meter { height: 5px; margin: 0; }

/* ---------- home: the four moves ---------- */
.moves { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border: 1px solid var(--line); border-radius: var(--r-card); background: var(--surface); overflow: hidden; }
.moves > li { display: grid; grid-template-rows: auto auto 1fr auto; gap: var(--s3); padding: var(--s5); border-left: 1px solid var(--line); }
.moves > li:first-child { border-left: 0; }
.moves .n { font: 700 12px/16px var(--font-mono); color: var(--accent-text); letter-spacing: 0.12em; }
.moves h3 { font-family: var(--font-display); font-weight: 800; font-size: 26px; line-height: 28px; letter-spacing: -0.01em; }
.moves p { color: var(--muted); font-size: 14px; line-height: 20px; }
.moves .demo { min-height: 72px; display: grid; align-content: center; gap: 6px; padding: var(--s3) var(--s4); border-radius: var(--r-inner); background: var(--surface-2); font: 500 12px/16px var(--font-mono); }
.moves .demo .row { display: flex; align-items: center; justify-content: space-between; gap: var(--s2); }
.moves .demo .row > :first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.moves .demo .row > :last-child { flex: none; white-space: nowrap; }
.moves .demo .ok::before { content: '\2713'; color: var(--up); font-weight: 700; margin-right: 6px; }

.details { border-radius: var(--r-card); }
.band { border-radius: var(--r-card); background: var(--ink); color: var(--bg); }
.band h2 { font-size: clamp(36px, 5.5vw, 68px); color: var(--bg); }
.band .display em { color: var(--accent); }

/* ---------- launch ---------- */
.sign { display: grid; border: 1px solid var(--line); border-radius: var(--r-inner); background: var(--bg); }
.sign > div { display: flex; justify-content: space-between; gap: var(--s4); padding: 10px var(--s4); border-top: 1px solid var(--line); font-size: 13px; line-height: 18px; }
.sign > div:first-child { border-top: 0; }
.sign dt { color: var(--muted); }
.sign dd { font-weight: 600; text-align: right; overflow-wrap: anywhere; }
.fields > .field + .field { margin-top: 0; }
.chains-pick { display: grid; gap: var(--s2); }
.chain-opt { display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; align-items: center; gap: var(--s3); min-height: 56px; padding: var(--s3) var(--s4); border: 1px solid var(--line); border-radius: var(--r-inner); background: var(--bg); cursor: pointer; text-align: left; transition: border-color 120ms; }
.chain-opt:hover { border-color: var(--muted); }
.chain-opt[aria-pressed='true'] { border-color: var(--accent-text); background: var(--surface); }
.chain-opt .dot { width: 10px; height: 10px; margin: auto; }
.chain-opt b { display: block; font-size: 15px; line-height: 20px; }
.chain-opt small { display: block; font-size: 12px; line-height: 16px; color: var(--muted); }
.chain-opt .ord { font: 500 12px/1 var(--font-mono); color: var(--muted); }
.chain-opt[aria-pressed='true'] .ord { color: var(--accent-text); }
.steps-v li[data-done='true']::before { background: var(--up); border-color: var(--up); color: #fff; }

/* ---------- coin page ---------- */
.ident-text h1 { font-family: var(--font-display); font-weight: 800; letter-spacing: -0.02em; font-size: 36px; line-height: 40px; }
.chart-price { font-family: var(--font-display); font-weight: 800; }
.avatar { border-radius: 50%; }
.vault-num { font-family: var(--font-display); font-weight: 800; font-size: 30px; line-height: 34px; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }

/* the crossing tracker */
.hub-row { display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; align-items: center; gap: var(--s3); padding: var(--s3) 0; border-bottom: 1px solid var(--line); font-size: 14px; line-height: 20px; }
.hub-row .dot { width: 10px; height: 10px; margin: auto; }
.exp { display: grid; gap: var(--s3); padding: var(--s4) 0; border-bottom: 1px solid var(--line); }
.exp:last-of-type { border-bottom: 0; }
.exp-head { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); flex-wrap: wrap; }
.exp-head b { display: inline-flex; align-items: center; gap: 8px; font-size: 16px; line-height: 22px; }
.stepper { display: grid; grid-template-columns: repeat(9, minmax(0, 1fr)); gap: 4px; }
.stepper > span { display: grid; gap: 6px; min-width: 0; }
.stepper i { display: block; height: 8px; border-radius: 4px; background: var(--surface-2); border: 1px solid var(--line); }
.stepper .done i { background: var(--accent); border-color: var(--accent); }
.stepper .now i { background: color-mix(in srgb, var(--accent) 45%, var(--surface-2)); border-color: var(--accent); animation: pulse 1.4s ease-in-out infinite; }
.stepper .fail i { background: var(--down); border-color: var(--down); }
.stepper small { font: 500 10px/14px var(--font-mono); color: var(--muted); text-align: center; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stepper .done small, .stepper .now small { color: var(--ink); }
@keyframes pulse { 50% { opacity: 0.45; } }
.exp .kv { margin: 0; }
.exp-err { padding: var(--s3) var(--s4); border: 1px solid var(--down); border-radius: var(--r-inner); font-size: 13px; line-height: 18px; }
.exp-err pre { margin-top: 6px; max-height: 160px; overflow: auto; font: 11px/15px var(--font-mono); color: var(--muted); white-space: pre-wrap; }
.addr { font: 500 12px/16px var(--font-mono); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }
.events .log-row span:first-of-type { min-width: 0; }

/* ---------- responsive ---------- */
@media (max-width: 1099px) { .moves { grid-template-columns: repeat(2, minmax(0, 1fr)); } .moves > li:nth-child(3) { border-left: 0; } .moves > li:nth-child(n+3) { border-top: 1px solid var(--line); } }
@media (max-width: 959px) {
  .hero2 { grid-template-columns: minmax(0, 1fr); }
  .stepper small { display: none; }
  .grid-rows { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 819px) {
  .section-head h2, .band h2 { font-size: 34px; }
  .tiles3 { grid-template-columns: minmax(0, 1fr); }
  .tiles3 b { font-size: 32px; line-height: 36px; }
  .foot-right { text-align: left; justify-items: start; }
}
@media (max-width: 639px) {
  .moves { grid-template-columns: minmax(0, 1fr); }
  .moves > li { border-left: 0; border-top: 1px solid var(--line); padding: var(--s4); }
  .moves > li:first-child { border-top: 0; }
  .lede { font-size: 16px; line-height: 24px; }
  .wordmark .wm { display: none; }
  .footer .wm { display: inline-flex; }
  .chart-price { font-size: 26px; }
  .ident-text h1 { font-size: 28px; line-height: 32px; }
  .page-h { font-size: 30px; line-height: 34px; }
  .header .btn, .header .btn-secondary { padding: 0 14px; height: 38px; font-size: 14px; }
  .header .btn-sm { height: 36px; padding: 0 12px; }
  .header button.pill { max-width: 104px; font-size: 12px; padding: 0 10px; }
  .ca-pill { max-width: 112px; font-size: 12px; padding: 0 10px; }
  .hero-cta .btn, .hero-cta .btn-secondary { width: 100%; }
  .card.coin-row { grid-template-columns: 64px minmax(0, 1fr); }
  .coin-row .pic { width: 64px; height: 64px; }
}
@media (max-width: 767px) { .header .wide, #theme { display: none; } }
@media (max-width: 359px) {
  .header .container { gap: 6px; }
  .nav a { padding: 0 5px; font-size: 13px; }
  .header .btn, .header .btn-secondary, .header .btn-sm { padding: 0 10px; font-size: 13px; }
}
