/* fonts.css */
/* Self-hosted, OFL-1.1 (the licence ships next to the files in /fonts). Latin subsets.
   Geist Pixel names and labels, Geist is what you read, Geist Mono is the app surface and every number. */
@font-face { font-family: "Geist"; src: url("/fonts/Geist-latin-var.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Geist Mono"; src: url("/fonts/GeistMono-latin-var.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Geist Pixel"; src: url("/fonts/GeistPixel-latin-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }

/* tokens.css */
/* Design tokens: the measured grammar of the reference (dark bands, pixel display type, square white
   controls, one hidden accent), in the mx namespace. Two surfaces share them:
   - the landing surface (home, tokens, the four content pages): #121212 bands, #000 cards, white islands;
   - the app surface (token view, launch, my loans, lookup): the warm #1f1811 ground, mono type, 8 px cards.
   The legacy aliases at the end keep older page styles on the same palette. */
:root {
  color-scheme: dark;

  /* grounds */
  --mx-bg-page: #1f1811;        /* the warm near-black: app surface, secondary buttons, the glyph layer */
  --mx-bg-band: #121212;        /* every landing band */
  --mx-bg-card: #000000;        /* dark cards, the nav bar */
  --mx-surface: #ffffff;        /* white islands: feature cards, chips, the CTA panel, the footer */
  --mx-pixel-light: #ededed;    /* pixel ornaments, the checker strip */
  --mx-app-card: #2a2119;       /* app panels */
  --mx-app-line: #3a2f24;       /* app hairlines and input borders */

  /* ink */
  --mx-ink: #121212;
  --mx-ink-strong: #000000;
  --mx-ink-75: rgba(0, 0, 0, .75);
  --mx-on-dark: #ffffff;
  --mx-on-dark-soft: #fafafa;
  --mx-mute: #9c9488;           /* secondary text on the warm ground, measured on the reference app */
  --mx-mute-band: #a3a3a3;      /* secondary text on #121212 (7.3:1) */
  --mx-accent: #d1fe05;         /* nav hover only: never at rest, never a fill */

  /* lines, rims, glows, shadows */
  --mx-hair: rgba(255, 255, 255, .30);
  --mx-dash: rgba(255, 255, 255, .50);
  --mx-rim: 1px solid #ffffff;
  --mx-glow: inset 0 0 50px rgba(255, 255, 255, .25);
  --mx-shadow-btn:
    rgba(0, 0, 0, .24) 0 .78px 1.41px -.43px, rgba(0, 0, 0, .24) 0 1.92px 3.46px -.86px,
    rgba(0, 0, 0, .23) 0 3.64px 6.55px -1.29px, rgba(0, 0, 0, .23) 0 6.35px 11.43px -1.71px,
    rgba(0, 0, 0, .22) 0 11.05px 19.89px -2.14px, rgba(0, 0, 0, .2) 0 20.24px 36.44px -2.57px,
    rgba(0, 0, 0, .16) 0 40px 72px -3px;
  --mx-shadow-off:
    rgba(0, 0, 0, 0) 0 .78px 1.41px -.43px, rgba(0, 0, 0, 0) 0 1.92px 3.46px -.86px,
    rgba(0, 0, 0, 0) 0 3.64px 6.55px -1.29px, rgba(0, 0, 0, 0) 0 6.35px 11.43px -1.71px,
    rgba(0, 0, 0, 0) 0 11.05px 19.89px -2.14px, rgba(0, 0, 0, 0) 0 20.24px 36.44px -2.57px,
    rgba(0, 0, 0, 0) 0 40px 72px -3px;

  /* type */
  --mx-pixel: "Geist Pixel", "Geist Mono", ui-monospace, monospace;
  --mx-sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mx-mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --mx-fs-display: clamp(36px, 4.4vw + 15px, 64px);
  --mx-fs-h2: clamp(32px, 1.4rem + 2.2vw, 50px);
  --mx-fs-h3: 24px;
  --mx-fs-step: 20px;
  --mx-fs-title: 18px;
  --mx-fs-body: 16px;
  --mx-fs-nav: 15px;
  --mx-fs-small: 14px;
  --mx-fs-micro: 13px;
  --mx-lh: 1.2;

  /* spacing */
  --mx-max: 1300px;
  --mx-gutter: 70px;
  --mx-nav-h: 101px;
  --mx-section-top: 54px;
  --mx-gap-h: 15px;
  --mx-gap-stack: 25px;
  --mx-gap-group: 45px;
  --mx-gap-cards: 100px;
  --mx-gap-cols: 94px;
  --mx-gap-grid: 27px;
  --mx-panel-pad: 54px;
  --mx-footer-top: 83px;

  /* controls */
  --mx-btn-h: 56px;
  --mx-btn-px: 32px;
  --mx-r-0: 0;
  --mx-r-card: 25px;
  --mx-r-app: 8px;
  --mx-r-ctl: 4px;
  --mx-step: 239px;
  --mx-chip-h: 45px;
  --mx-cell-lg: 53px;
  --mx-cell-md: 41px;
  --mx-cell-sm: 13px;

  /* motion */
  --mx-t-dissolve: 600ms;
  --mx-t-fill: 200ms;

  /* legacy aliases used by the page stylesheets and the client modules' markup */
  --bg: var(--mx-bg-band);
  --panel: var(--mx-bg-card);
  --panel-2: #1a1a1a;
  --panel-3: #262626;
  --rule: rgba(255, 255, 255, .14);
  --rule-strong: rgba(255, 255, 255, .30);
  --fg: var(--mx-on-dark);
  --fg-soft: #d4d4d4;
  --fg-mute: var(--mx-mute-band);
  --up: #ffffff;
  --up-ink: #121212;
  --up-dim: #262626;
  --up-line: rgba(255, 255, 255, .5);
  --down: #ffffff;
  --down-dim: #262626;
  --amber: #ffffff;
  --amber-dim: #262626;

  --sans: var(--mx-sans);
  --mono: var(--mx-mono);
  --fs-micro: 12px;
  --fs-nav: 15px;
  --fs-small: 14px;
  --fs-body: 16px;
  --fs-lead: 16px;
  --fs-h3: 18px;
  --fs-h2: var(--mx-fs-h2);
  --fs-h1: var(--mx-fs-display);
  --fs-num: clamp(22px, 2.6vw, 30px);

  --r-s: var(--mx-r-ctl);
  --r-m: var(--mx-r-app);
  --r-l: var(--mx-r-app);
  --gap: 16px;
  --col: var(--mx-max);
  --gutter: var(--mx-gutter);
  --header-h: var(--mx-nav-h);
}
@media (max-width: 1024px) { :root { --mx-gutter: 40px; } }
@media (max-width: 420px) { :root { --mx-gutter: 16px; } }

/* The app surface swaps the ground, the panel fill and the reading face. */
body.app {
  --bg: var(--mx-bg-page);
  --panel: var(--mx-app-card);
  --panel-2: #33291f;
  --panel-3: #3a2f24;
  --rule: var(--mx-app-line);
  --rule-strong: #4a3d2f;
  --fg-mute: var(--mx-mute);
  --fg-soft: #cfc7bb;
  --up-dim: #33291f;
  --down-dim: #33291f;
  --amber-dim: #33291f;
  --sans: var(--mx-mono);
  --fs-body: 15px;
  --fs-small: 13px;
  --fs-micro: 12px;
}

/* base.css */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--mx-nav-h) + 12px); background: var(--mx-bg-page); }
body {
  margin: 0; background: var(--bg); color: var(--fg);
  font: 400 var(--fs-body)/1.5 var(--sans);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg { max-width: 100%; }
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 2px solid var(--mx-on-dark); outline-offset: 3px; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3, .pixel { font-family: var(--mx-pixel); font-weight: 400; letter-spacing: normal; line-height: var(--mx-lh); }
h1 { font-size: var(--mx-fs-display); text-wrap: balance; overflow-wrap: anywhere; }
h2 { font-size: var(--mx-fs-h2); text-wrap: balance; }
h3 { font-size: var(--mx-fs-title); }
sub { font-size: .7em; vertical-align: -0.25em; line-height: 0; }
code, .mono { font-family: var(--mx-mono); }
[hidden] { display: none !important; }

.wrap { width: 100%; max-width: calc(var(--mx-max) + 2 * var(--mx-gutter)); margin-inline: auto; padding-inline: var(--mx-gutter); }
main { display: block; }
main.wrap { padding-block: 0 56px; display: flex; flex-direction: column; gap: 28px; }
body.landing main.wrap { max-width: none; padding-inline: 0; padding-block: 0; gap: 0; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.up { color: var(--mx-on-dark); } .down { color: var(--mx-on-dark); } .amber { color: var(--mx-on-dark); }
.soft { color: var(--fg-soft); } .mute { color: var(--fg-mute); }
.num { font-family: var(--mx-mono); font-variant-numeric: tabular-nums; }
.lead { color: var(--fg-soft); font-size: var(--fs-lead); }
.eyebrow { font: 400 var(--mx-fs-micro)/1 var(--mx-pixel); letter-spacing: .04em; text-transform: uppercase; color: var(--fg-mute); }

/* landing bands */
.mx-section { position: relative; display: flow-root; overflow: clip; background: var(--mx-bg-band); padding-block: var(--mx-section-top) 0; }
.mx-section > .wrap { position: relative; }
.mx-heading { display: grid; justify-items: center; text-align: center; gap: var(--mx-gap-h); position: relative; z-index: 1; }
.mx-heading--start { justify-items: start; text-align: left; }
.mx-heading--stack { gap: var(--mx-gap-stack); }
.mx-heading p { max-width: 640px; color: var(--mx-on-dark); font-size: var(--mx-fs-body); line-height: 1.2; }
.mx-heading .sub { color: var(--mx-mute-band); }

/* chrome.css */
/* The nav bar: 60 px, opaque black, sticky. Brand at the left, one row of hairline-divided cells
   (every route, then one cell per pool page) that scrolls sideways when the width runs out, the
   network pill and the wallet button at the right. Then the white footer with the ghost wordmark. */
.site-head {
  position: sticky; top: 0; z-index: 50;
  background: var(--mx-bg-card); color: var(--mx-on-dark);
}
.site-head .top { display: flex; align-items: center; gap: 12px; height: 56px; }
.brand { display: inline-flex; align-items: center; gap: 10px; flex: none; color: var(--mx-on-dark); }
.brand:hover { color: var(--mx-on-dark); }
.brand svg { width: 28px; height: 28px; }
.brand .word { font: 400 22px/1 var(--mx-pixel); }
.top .spacer { flex: 1; min-width: 0; }

/* The cell row: every route, then one cell per pool page, hairline-divided, scrolling sideways
   when the width runs out (a clipped cell is still reachable, so it is never off-viewport). */
.rail { display: block; overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: none; border-top: 1px solid var(--mx-hair); }
.rail::-webkit-scrollbar { display: none; }
.rail .cells { display: flex; align-items: stretch; height: 44px; width: max-content; min-width: 100%; }
.nav-link, .tick {
  flex: none; display: inline-flex; align-items: center; gap: 10px; padding: 0 20px;
  font: 400 13px/1.5 var(--mx-mono); color: var(--mx-on-dark); white-space: nowrap;
  border-right: 1px solid var(--mx-hair); background: var(--mx-bg-card);
  transition: background var(--mx-t-fill) ease-out, color var(--mx-t-fill) ease-out;
}
.nav-link:first-child { border-left: 1px solid var(--mx-hair); }
.nav-link:hover, .tick:hover { background: var(--mx-bg-page); color: var(--mx-accent); }
.nav-link[aria-current="page"], .tick[aria-current="page"] { box-shadow: inset 0 -2px 0 var(--mx-on-dark); }
.nav-link svg { display: none; }
.rail .sep { display: none; }
.rail .live { flex: none; display: inline-flex; align-items: center; gap: 8px; padding: 0 14px 0 20px; font: 400 12px/1 var(--mx-pixel); letter-spacing: .04em; color: var(--mx-mute-band); border-right: 1px solid var(--mx-hair); }
.rail .live i { width: 6px; height: 6px; background: var(--mx-on-dark); animation: m-blink 2s ease-in-out infinite; }
.tick { font-size: 13px; gap: 8px; }
.tick img, .tick .mono-img { width: 18px; height: 18px; }
.tick .sym { font-weight: 500; }
.tick .val { color: var(--mx-mute-band); }

.net {
  display: inline-flex; align-items: center; gap: 7px; flex: none; height: 31px; padding: 0 12px;
  border: 1px solid var(--mx-hair); font: 400 13px/1 var(--mx-mono); color: var(--mx-on-dark); white-space: nowrap;
}
.net i { width: 6px; height: 6px; background: currentColor; }
.wallet-btn { flex: none; height: 38px; padding: 0 18px; font: 600 14px/1 var(--mx-mono); }
.wallet-btn .addr { font-family: var(--mx-mono); }
.wallet-btn.warn { background: var(--mx-bg-page); color: var(--mx-on-dark-soft); border: 1px solid var(--mx-hair); }

@media (max-width: 810px) {
  .site-head .top { height: 52px; gap: 8px; }
  .brand .word { font-size: 20px; }
  .nav-link, .tick { padding: 0 14px; }
  .wallet-btn { padding: 0 12px; height: 34px; font-size: 13px; }
  .net { height: 28px; padding: 0 9px; font-size: 12px; }
  .net .long { display: none; }
}
@media (max-width: 420px) {
  .rail .cells { height: 40px; }
}

/* ---------------------------------------------------------------- footer */
.site-foot { position: relative; overflow: clip; background: var(--mx-surface); color: var(--mx-ink); margin-top: 0; padding-top: var(--mx-footer-top); }
body:not(.landing) .site-foot { margin-top: 40px; }
.site-foot .cols { display: flex; flex-wrap: wrap; gap: 40px 100px; align-items: flex-start; }
.site-foot .brand { color: var(--mx-ink); flex-direction: column; align-items: flex-start; gap: 31px; padding: 0; margin-right: auto; min-width: 226px; }
.site-foot .brand .word { font: 400 60px/1.2 var(--mx-pixel); }
.site-foot .brand svg { display: none; }
.site-foot .tag { font: 400 var(--mx-fs-title)/1.2 var(--mx-sans); color: var(--mx-ink); max-width: 300px; }
.site-foot nav { display: flex; flex-wrap: wrap; gap: 32px 100px; }
.site-foot nav > div { display: grid; gap: 0; min-width: 144px; align-content: start; }
.site-foot nav h3 { font: 400 var(--mx-fs-h3)/1.2 var(--mx-pixel); color: var(--mx-ink); margin-bottom: 13px; text-transform: uppercase; }
.site-foot nav a { font: 400 var(--mx-fs-title)/1.2 var(--mx-sans); color: var(--mx-ink-strong); padding: 4px 0; }
.site-foot nav a:hover { color: var(--mx-ink-strong); }
.site-foot nav a[target]::after { content: " \2192"; }
.site-foot .facts { display: flex; flex-wrap: wrap; gap: 6px 24px; margin-top: 120px; font: 400 var(--mx-fs-small)/1.2 var(--mx-sans); color: var(--mx-ink-75); }
.site-foot .facts b { color: var(--mx-ink); font-weight: 500; }
.site-foot .giant { color: var(--mx-ink-strong); opacity: .27; white-space: nowrap; }
.site-foot .giant span { display: block; font: 400 min(calc((100vw - 2 * var(--mx-gutter)) / 3.55), 342px)/1 var(--mx-pixel); height: .754em; overflow: hidden; margin-top: calc(31px - .133em); }
@media (max-width: 810px) {
  .site-foot { padding-top: 48px; }
  .site-foot .cols { gap: 32px 48px; }
  .site-foot .brand .word { font-size: 44px; }
  .site-foot .facts { margin-top: 48px; }
}

/* components.css */
/* Components. Square controls, white islands on dark, rims instead of shadows. The same classes render
   on both surfaces through the aliases in tokens.css (band: #000 cards; app: #2a2119 panels). */

/* ---------------------------------------------------------------- buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 20px; border-radius: var(--mx-r-ctl); border: 1px solid var(--mx-hair);
  background: transparent; color: var(--mx-on-dark); cursor: pointer;
  font: 500 var(--fs-small)/1 var(--mx-mono); white-space: nowrap;
  transition: background var(--mx-t-fill) ease-out, color var(--mx-t-fill) ease-out, border-color var(--mx-t-fill) ease-out, box-shadow var(--mx-t-dissolve) steps(6);
}
.btn:hover { color: var(--mx-on-dark); border-color: var(--mx-on-dark); background: var(--mx-bg-page); }
.btn svg { width: 16px; height: 16px; }
.btn.primary { background: var(--mx-surface); color: var(--mx-ink); border-color: var(--mx-surface); font-weight: 600; }
.btn.primary:hover { background: var(--mx-bg-page); color: var(--mx-on-dark-soft); border-color: var(--mx-bg-page); }
.btn.dark { background: var(--mx-bg-band); color: var(--mx-on-dark); border-color: var(--mx-bg-band); }
.btn.dark:hover { background: var(--mx-surface); color: var(--mx-ink); border-color: var(--mx-surface); }
.btn.ghost { border-color: transparent; }
.btn.small { height: 31px; padding: 0 12px; font-size: 13px; }
.btn.big { height: var(--mx-btn-h); padding: 0 var(--mx-btn-px); border-radius: 0; font: 500 16px/1.2 var(--mx-sans); box-shadow: var(--mx-shadow-btn); }
.btn.big:hover { box-shadow: var(--mx-shadow-off); }
.btn.big.secondary { background: var(--mx-bg-page); color: var(--mx-on-dark-soft); border-color: var(--mx-bg-page); }
.btn.big.secondary:hover { background: var(--mx-surface); color: var(--mx-ink); border-color: var(--mx-surface); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .5; cursor: not-allowed; box-shadow: none; }
.btn.danger { border-color: var(--mx-on-dark); }
.btn-row { display: flex; flex-wrap: wrap; gap: 24px; }
@media (max-width: 420px) { .btn-row { flex-direction: column; } .btn-row .btn.big { width: 100%; } }

/* ---------------------------------------------------------------- chips (were pills) */
.pill {
  display: inline-flex; align-items: center; gap: 8px; height: 31px; padding: 0 12px; border-radius: var(--mx-r-ctl);
  font: 400 13px/1 var(--mx-mono); white-space: nowrap;
  color: var(--mx-on-dark); border: 1px solid var(--mx-hair); background: transparent;
}
.pill i { width: 6px; height: 6px; background: currentColor; }
.pill.open { color: var(--mx-ink); background: var(--mx-surface); border-color: var(--mx-surface); font-weight: 600; }
.pill.clock, .pill.start, .pill.curve { color: var(--mx-on-dark); }
.pill.bad { color: var(--mx-on-dark); border-color: var(--mx-on-dark); }
body.band .pill, body.landing .pill { border-radius: 0; height: 33px; font-family: var(--mx-pixel); font-size: 14px; }

/* ---------------------------------------------------------------- stats */
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.stat { background: var(--panel); border: 1px solid var(--rule); border-radius: var(--r-m); padding: 14px 16px; min-width: 0; }
.stat .k { font: 400 12px/1 var(--mx-pixel); letter-spacing: .04em; text-transform: uppercase; color: var(--fg-mute); display: flex; align-items: center; gap: 6px; }
.stat .k svg { display: none; }
.stat .v { margin-top: 10px; font: 500 var(--fs-num)/1.1 var(--mx-mono); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stat .v small { font-size: .5em; color: var(--fg-mute); font-weight: 400; }
.stat .s { margin-top: 4px; font: 400 12px/1.3 var(--mx-mono); color: var(--fg-mute); }
@media (max-width: 479px) {
  .stats { gap: 8px; }
  .stat { padding: 10px 12px; }
  .stat .v { font-size: 18px; }
  .stat .v small { display: block; margin-top: 2px; }
}

/* ---------------------------------------------------------------- section heads */
.sec { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.sec-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.sec-head h2 { font-size: clamp(24px, 1rem + 1.6vw, 32px); }
.sec-head .aside { font: 400 var(--fs-small)/1 var(--mx-mono); color: var(--fg-mute); }
.sec-head a.aside:hover { color: var(--mx-on-dark); }

/* ---------------------------------------------------------------- token cards */
.grid { display: grid; gap: var(--mx-gap-grid); grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
@media (max-width: 479px) { .grid { grid-template-columns: 1fr; gap: 16px; } }
.card {
  position: relative; display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 16px;
  padding: 20px; background: var(--mx-bg-card); border: var(--mx-rim); box-shadow: var(--mx-glow); border-radius: var(--mx-r-card);
  color: var(--mx-on-dark); transition: color var(--mx-t-fill);
}
body.app .card { background: var(--panel); border: 1px solid var(--rule); box-shadow: none; border-radius: var(--r-m); }
.card:hover { color: var(--mx-on-dark); }
.card .pic { width: 96px; height: 96px; overflow: hidden; background: var(--mx-bg-page); }
.card .pic img, .card .pic svg { width: 100%; height: 100%; object-fit: cover; display: block; }
.card .body { min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.card .name { display: flex; align-items: baseline; gap: 8px; min-width: 0; }
.card .name b { font: 400 var(--mx-fs-title)/1.2 var(--mx-pixel); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card .name span { font: 400 13px/1 var(--mx-mono); color: var(--fg-mute); }
.card .big { font: 500 22px/1.1 var(--mx-mono); color: var(--mx-on-dark); }
.card .big small { font-size: 12px; color: var(--fg-mute); font-weight: 400; }
.card .meta { display: flex; flex-wrap: wrap; gap: 4px 12px; font: 400 12px/1.4 var(--mx-mono); color: var(--fg-mute); }
.card .meta b { color: var(--mx-on-dark); font-weight: 500; }
.card .bars { grid-column: 1 / -1; display: grid; gap: 6px; }
.card .row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.bar-line { display: grid; grid-template-columns: 64px minmax(0, 1fr) 48px; align-items: center; gap: 8px; font: 400 12px/1 var(--mx-mono); color: var(--fg-mute); }
.bar-line .pct { text-align: right; color: var(--mx-on-dark); }

/* <progress> and <meter>: the only way a width changes after load (no inline style anywhere). */
progress, meter {
  -webkit-appearance: none; appearance: none; display: block; width: 100%; height: 8px; border: 0; border-radius: 0;
  background: var(--panel-3); overflow: hidden; color: var(--mx-on-dark);
}
progress::-webkit-progress-bar { background: var(--panel-3); }
progress::-webkit-progress-value { background: var(--mx-on-dark); transition: width .4s; }
progress::-moz-progress-bar { background: var(--mx-on-dark); }
meter::-webkit-meter-bar { background: var(--panel-3); border: 0; border-radius: 0; height: 8px; }
meter::-webkit-meter-optimum-value { background: var(--mx-on-dark); }
meter::-webkit-meter-suboptimum-value { background: var(--mx-on-dark); opacity: .7; }
meter::-webkit-meter-even-less-good-value { background: var(--mx-on-dark); opacity: .5; }
progress.amber::-webkit-progress-value { background: var(--fg-soft); }
progress.amber::-moz-progress-bar { background: var(--fg-soft); }
progress.soft::-webkit-progress-value { background: var(--fg-mute); }
progress.soft::-moz-progress-bar { background: var(--fg-mute); }

/* ---------------------------------------------------------------- token image fallback */
.mono-img { display: block; }
.mono-img rect { fill: var(--mx-bg-page); }
.mono-img circle { fill: none; stroke: var(--mx-on-dark); stroke-width: 3; }
.mono-img text { fill: var(--mx-on-dark); font-family: var(--mx-pixel); font-weight: 400; }

/* ---------------------------------------------------------------- empty state */
.empty {
  display: grid; justify-items: center; gap: 14px; text-align: center; padding: 32px 20px;
  border: 1px dashed var(--mx-dash); border-radius: var(--mx-r-card); color: var(--fg-soft); background: var(--mx-bg-card);
}
body.app .empty { background: var(--panel); border-radius: var(--r-m); }
.empty svg.fig { width: min(260px, 70%); }
.empty p { max-width: 46ch; }
.empty .pixel { font-size: var(--mx-fs-step); color: var(--mx-on-dark); }

/* ---------------------------------------------------------------- tables */
.table-wrap { overflow-x: auto; border: 1px solid var(--rule); background: var(--panel); border-radius: var(--r-m); }
table.data { width: 100%; border-collapse: collapse; font-size: var(--fs-small); min-width: 860px; font-family: var(--mx-mono); }
table.data th { text-align: left; font: 400 12px/1 var(--mx-pixel); letter-spacing: .04em; text-transform: uppercase; color: var(--fg-mute); padding: 12px 14px; border-bottom: 1px solid var(--rule); white-space: nowrap; }
table.data td { padding: 12px 14px; border-bottom: 1px solid var(--rule); white-space: nowrap; vertical-align: middle; }
table.data tr:last-child td { border-bottom: 0; }
table.data tbody tr:hover td { background: var(--panel-2); }
table.data .r { text-align: right; }
table.data .tok { display: flex; align-items: center; gap: 10px; }
table.data .tok img, table.data .tok svg { width: 32px; height: 32px; flex: none; }
table.data .tok b { font-weight: 500; }
table.data .tok span { display: block; font: 400 12px/1.2 var(--mx-mono); color: var(--fg-mute); }

/* ---------------------------------------------------------------- panels, key-value lists */
.panel { background: var(--panel); border: 1px solid var(--rule); border-radius: var(--r-m); padding: 20px; min-width: 0; }
.panel > h2, .panel > h3 { margin-bottom: 12px; }
.kv { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.kv > div { background: var(--panel-2); border-radius: var(--r-s); padding: 10px 12px; min-width: 0; }
.kv dt, .kv .k { font: 400 12px/1 var(--mx-pixel); letter-spacing: .04em; text-transform: uppercase; color: var(--fg-mute); }
.kv dd, .kv .v { margin: 6px 0 0; font: 500 16px/1.2 var(--mx-mono); }
dl.kv { margin: 0; }

/* ---------------------------------------------------------------- addresses */
.addr { display: inline-flex; align-items: center; gap: 6px; min-width: 0; font: 400 var(--fs-small)/1 var(--mx-mono); }
.addr a { color: var(--fg-soft); }
.addr a:hover { color: var(--mx-on-dark); }
.addr .full { display: none; }
.copy { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: var(--mx-r-ctl); border: 1px solid var(--rule); background: transparent; color: var(--fg-soft); cursor: pointer; padding: 0; }
.copy svg { width: 14px; height: 14px; }
.copy:hover { color: var(--mx-on-dark); border-color: var(--mx-on-dark); }
.copy.done { color: var(--mx-ink); background: var(--mx-surface); border-color: var(--mx-surface); }

/* ---------------------------------------------------------------- icons */
.ic { width: 1em; height: 1em; flex: none; fill: currentColor; vertical-align: -0.125em; }

/* ---------------------------------------------------------------- module mounts */
.module { background: var(--panel); border: 1px solid var(--rule); border-radius: var(--r-m); padding: 20px; display: grid; gap: 12px; align-content: start; min-width: 0; }
.module > header { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.module > header h2 { font: 400 var(--mx-fs-title)/1.2 var(--mx-pixel); text-transform: uppercase; letter-spacing: .04em; display: flex; align-items: center; gap: 8px; }
.module > header h2 svg { display: none; }
.module .note { color: var(--fg-mute); font-size: var(--fs-small); }
.module[data-state="ready"] .note.wait { display: none; }

/* ---------------------------------------------------------------- forms */
.field { display: grid; gap: 6px; }
.field label { font: 400 12px/1 var(--mx-pixel); letter-spacing: .04em; text-transform: uppercase; color: var(--fg-mute); }
.input, input[type="text"], input[type="number"], input[type="search"], input[type="url"], textarea, select {
  width: 100%; height: 49px; padding: 0 14px; border-radius: var(--mx-r-ctl); border: 1px solid var(--rule);
  background: var(--bg); color: var(--fg); font: 400 18px/1 var(--mx-mono);
}
textarea { height: auto; min-height: 88px; padding: 12px 14px; line-height: 1.4; font-size: 15px; }
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--mx-on-dark); }
.seg { display: inline-flex; gap: 6px; }
.seg button { height: 31px; padding: 0 12px; border: 1px solid var(--rule); border-radius: var(--mx-r-ctl); background: transparent; color: var(--mx-on-dark); font: 400 13px/1 var(--mx-mono); cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--mx-surface); color: var(--mx-ink); border-color: var(--mx-surface); font-weight: 600; }
input[type="range"] { width: 100%; accent-color: var(--mx-on-dark); }

/* ---------------------------------------------------------------- chart frame */
.chart { position: relative; border: 1px solid var(--rule); border-radius: var(--r-m); overflow: hidden; background: var(--panel); aspect-ratio: 16 / 10; max-width: 100%; }
.chart iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.chart .empty { position: absolute; inset: 0; border: 0; border-radius: 0; align-content: center; }
@media (max-width: 767px) { .chart { aspect-ratio: 4 / 5; } }
.chart.chart-none { aspect-ratio: auto; }
.chart.chart-none .empty { position: static; padding: 20px 16px; }
.chart.chart-none .fig { max-height: 90px; }

/* ---------------------------------------------------------------- notices */
.notice { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: var(--mx-r-ctl); background: transparent; color: var(--mx-on-dark); font-size: var(--fs-small); border: 1px solid var(--mx-hair); }
.notice svg { width: 18px; height: 18px; flex: none; margin-top: 1px; }
.notice.ok { border-color: var(--mx-on-dark); }
.notice.bad { border-color: var(--mx-on-dark); background: var(--mx-bg-page); }

/* ---------------------------------------------------------------- one-line figure blocks */
.figs { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: var(--mx-gap-grid); }
.figcard { background: var(--mx-bg-card); border: var(--mx-rim); box-shadow: var(--mx-glow); border-radius: var(--mx-r-card); padding: 20px; display: grid; gap: 12px; align-content: start; }
.figcard .fig { max-height: 180px; }
.figcard h3 { font-size: var(--mx-fs-title); }
.figcard p { color: var(--fg-soft); font-size: var(--fs-small); }

/* ---------------------------------------------------------------- landing furniture */
.mx-steps { display: flex; justify-content: center; gap: var(--mx-gap-cards); list-style: none; margin: 122px 0 0; padding: 0; isolation: isolate; flex-wrap: wrap; }
.mx-step { position: relative; width: var(--mx-step); height: var(--mx-step); flex: none; background: var(--mx-bg-card); border: var(--mx-rim); box-shadow: var(--mx-glow); border-radius: var(--mx-r-card); overflow: clip; display: grid; justify-items: center; align-content: start; padding-top: 52px; }
.mx-step svg { width: 100px; height: 100px; color: var(--mx-on-dark); }
.mx-step .lbl { position: absolute; top: 177px; left: 12px; right: 12px; text-align: center; font: 400 var(--mx-fs-step)/1.2 var(--mx-pixel); color: var(--mx-on-dark); }
.mx-step::before { content: ""; position: absolute; left: 100%; top: 50%; width: var(--mx-gap-cards); height: 1px; background: repeating-linear-gradient(90deg, var(--mx-dash) 0 5px, transparent 5px 10px); z-index: -1; }
.mx-step:last-child::before { display: none; }
.mx-feature-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--mx-gap-grid); list-style: none; margin: 0; padding: 0; max-width: 585px; }
.mx-feature { display: flex; gap: 16px; align-items: flex-start; min-height: 105px; padding: 11px 24px 11px 20px; background: var(--mx-surface); color: var(--mx-ink); }
.mx-feature svg { width: 45px; height: 45px; flex: none; color: var(--mx-ink); margin-top: 4px; }
.mx-feature h3 { font: 400 var(--mx-fs-title)/1.2 var(--mx-pixel); color: var(--mx-ink); }
.mx-feature p { font: 400 var(--mx-fs-small)/1.2 var(--mx-sans); color: var(--mx-ink); margin-top: 5px; }
.mx-chip { display: inline-flex; align-items: center; justify-content: center; height: var(--mx-chip-h); min-width: 109px; padding: 0 20px; background: var(--mx-surface); color: var(--mx-ink); font: 400 var(--mx-fs-title)/1.2 var(--mx-pixel); white-space: nowrap; }
.mx-stair { position: absolute; z-index: 0; pointer-events: none; }
.mx-stair path { fill: var(--mx-pixel-light); }
.mx-stair--tl { left: 0; top: 0; width: 205px; height: 206px; }
.mx-stair--tr { right: 0; top: 0; width: 140px; height: 140px; }
.mx-stair--bl { left: 0; bottom: 0; width: 161px; height: 107px; }
.mx-stair--br { right: 0; bottom: 0; width: 156px; height: 104px; }
.mx-checker { height: 106px; background: linear-gradient(var(--mx-bg-band), var(--mx-bg-band)) 0 0 / 100% 40px no-repeat, var(--mx-pixel-light); position: relative; }
.mx-checker::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 40px; background:
  conic-gradient(var(--mx-pixel-light) 25%, transparent 0 50%, var(--mx-pixel-light) 0 75%, transparent 0) 0 0 / 26px 26px; }
.mx-panel { background: var(--mx-surface); color: var(--mx-ink); border-radius: var(--mx-r-card); width: min(var(--mx-max), 100% - 2 * var(--mx-gutter)); margin: 73px auto 71px; padding: var(--mx-panel-pad) 20px 31px; display: grid; justify-items: center; text-align: center; gap: var(--mx-gap-group); }
.mx-panel h2 { color: var(--mx-ink); }
.mx-panel .lead { color: var(--mx-ink-75); font: 500 var(--mx-fs-body)/1.2 var(--mx-sans); max-width: 549px; }
.mx-panel__lead { display: grid; gap: 10px; justify-items: center; }
.mx-panel__icons { display: flex; justify-content: center; gap: 100px; list-style: none; margin: 0; padding: 0; flex-wrap: wrap; }
.mx-panel__icons li { display: grid; justify-items: center; gap: 25px; width: 145px; font: 500 var(--mx-fs-body)/1.2 var(--mx-sans); color: var(--mx-ink-75); }
.mx-panel__icons svg { width: 63px; height: 63px; color: var(--mx-ink); }
.mx-panel__action { display: grid; gap: 25px; justify-items: center; }
.mx-panel .fine { font: 400 var(--mx-fs-small)/1.2 var(--mx-sans); color: var(--mx-ink-75); }
@media (max-width: 1310px) { .mx-steps { gap: 36px; } .mx-step::before { width: 36px; } }
@media (max-width: 1150px) { .mx-steps { display: grid; grid-template-columns: repeat(2, var(--mx-step)); gap: 60px; } .mx-step::before { width: 60px; } .mx-step:nth-child(2n)::before { display: none; } }
@media (max-width: 620px) {
  .mx-steps { grid-template-columns: var(--mx-step); gap: 40px; margin-top: 60px; }
  .mx-step::before { left: 50%; top: 100%; width: 1px; height: 40px; background: repeating-linear-gradient(180deg, var(--mx-dash) 0 5px, transparent 5px 10px); }
  .mx-step:nth-child(2n)::before { display: block; }
  .mx-feature-grid { grid-template-columns: 1fr; gap: 20px; }
  .mx-panel__icons { gap: 12px; }
  .mx-panel__icons li { width: 30%; font-size: 14px; gap: 12px; }
  .mx-panel__icons svg { width: 44px; height: 44px; }
  .mx-stair--tl, .mx-stair--tr { display: none; }
  .mx-stair--bl { width: 72px; height: 48px; } .mx-stair--br { width: 72px; height: 48px; }
}
@media (max-width: 810px) { .mx-panel { padding: 40px 20px 28px; gap: 32px; } .mx-panel__icons { gap: 32px; } }

/* drawings/base.css */
/* Shared by every drawing: the palette classes the parts use, the opening frame, and the motion
   primitives. A drawing's own file (src/styles/drawings/<id>.css) adds only d-<id>-* rules. */

.opening, .fig { display: block; width: 100%; height: auto; overflow: visible; }
.opening { max-height: min(62vh, 480px); background: var(--mx-bg-page); }
.opening text, .fig text { font-family: var(--mx-mono); }

/* Glyph mosaics (src/drawings/mosaic.mjs): four brightness layers of letters on the warm ground,
   arriving top to bottom inside 1.2 s, then a slow scan band keeps the picture alive. */
.mo text { font: 400 12px/1 var(--mx-mono); fill: var(--mx-on-dark); white-space: pre; pointer-events: none; }
.mo-0 { opacity: .10; } .mo-1 { opacity: .28; } .mo-2 { opacity: .58; } .mo-3 { opacity: 1; }
.mo text { animation: mo-arrive .5s ease-out both; }
.mo-d0 { animation-delay: 0s; } .mo-d1 { animation-delay: .1s; } .mo-d2 { animation-delay: .2s; } .mo-d3 { animation-delay: .3s; }
.mo-d4 { animation-delay: .4s; } .mo-d5 { animation-delay: .5s; } .mo-d6 { animation-delay: .6s; } .mo-d7 { animation-delay: .7s; }
@keyframes mo-arrive { from { opacity: 0; } }
.mo-scan { fill: var(--mx-on-dark); opacity: .045; animation: mo-scan 7s linear 1.2s infinite; }
@keyframes mo-scan { from { transform: translateY(-12%); } to { transform: translateY(112%); } }
.mo-ground { fill: var(--mx-bg-page); }

.s-fg { stroke: var(--fg); } .s-soft { stroke: var(--fg-soft); } .s-rule { stroke: var(--rule-strong); }
.s-up { stroke: var(--up); } .s-down { stroke: var(--down); } .s-amber { stroke: var(--amber); }
.f-none { fill: none; } .f-bg { fill: var(--bg); } .f-panel { fill: var(--panel); } .f-panel2 { fill: var(--panel-2); }
.f-rule { fill: var(--rule-strong); } .f-fg { fill: var(--fg); } .f-soft { fill: var(--fg-soft); }
.f-up { fill: var(--up); } .f-updim { fill: var(--up-dim); } .f-down { fill: var(--down); } .f-amber { fill: var(--amber); }
.t-mono { font-family: var(--mono); font-weight: 600; letter-spacing: 0; }
.t-sans { font-family: var(--sans); font-weight: 700; }

/* Motion primitives. Each animates FROM a hidden or displaced state, so the natural (static) state
   of every element is the finished picture: with motion reduced, nothing is missing. */
.opening g, .opening path, .opening rect, .opening circle, .opening text,
.fig g, .fig path, .fig rect, .fig circle, .fig text { transform-box: fill-box; }

.wave { animation: wave-slide 3.2s linear infinite; }
@keyframes wave-slide { from { transform: translateX(0); } to { transform: translateX(25%); } }

.m-draw { stroke-dasharray: 1; animation: m-draw 1.1s cubic-bezier(.3,.7,.2,1) both; }
@keyframes m-draw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }

.m-pop { transform-origin: center; animation: m-pop .6s cubic-bezier(.2,1.4,.4,1) both; }
@keyframes m-pop { from { opacity: 0; transform: scale(.4); } to { opacity: 1; transform: scale(1); } }

.m-fade { animation: m-fade .8s ease-out both; }
@keyframes m-fade { from { opacity: 0; } to { opacity: 1; } }

.m-rise { transform-origin: 50% 100%; animation: m-rise 1.2s cubic-bezier(.3,.7,.2,1) both; }
@keyframes m-rise { from { transform: scaleY(0); } to { transform: scaleY(1); } }

.m-d1 { animation-delay: .15s; } .m-d2 { animation-delay: .3s; } .m-d3 { animation-delay: .45s; }
.m-d4 { animation-delay: .6s; } .m-d5 { animation-delay: .75s; } .m-d6 { animation-delay: .9s; }

.m-bob { animation: m-bob 3.6s ease-in-out 1.2s infinite; }
@keyframes m-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }

.m-blink { animation: m-blink 2.4s ease-in-out 1.2s infinite; }
@keyframes m-blink { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }

.m-spin { transform-origin: 50% 100%; animation: m-spin 12s linear infinite; }
.m-spin-fast { transform-origin: 50% 100%; animation: m-spin 2s linear infinite; }
@keyframes m-spin { to { transform: rotate(360deg); } }

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

/* drawings/burn.css */
/* burn: a glyph mosaic; the scan band is the loop. */
.d-burn-l { font: 400 clamp(22px, 60px - 2.7vw, 44px)/1 var(--mx-pixel); fill: var(--mx-on-dark); }
.d-burn-scan { animation: mo-scan 5s linear 1.2s infinite; }

/* drawings/cycle.css */
/* cycle: a glyph mosaic; the scan band is the loop. */
.d-cycle-l { font: 400 clamp(22px, 60px - 2.7vw, 44px)/1 var(--mx-pixel); fill: var(--mx-on-dark); }
.d-cycle-scan { animation: mo-scan 8s linear 1.2s infinite; }

/* drawings/directory.css */
/* directory: a glyph mosaic; the scan band is the loop. */
.d-directory-l { font: 400 clamp(22px, 60px - 2.7vw, 44px)/1 var(--mx-pixel); fill: var(--mx-on-dark); }
.d-directory-scan { animation: mo-scan 7s linear 1.2s infinite; }
.d-directory-dim { opacity: .4; }

/* drawings/figures.css */
/* In-page figures from src/drawings/figures.mjs (not openings). Entrance under a second, then a calm
   loop; base.css stops both under prefers-reduced-motion and the still frame is the finished figure. */
.d-fig-draw { stroke-dasharray: 1; animation: m-draw 1s cubic-bezier(.3,.7,.2,1) both; }

.d-fig-sweep { opacity: 0; animation: d-fig-sweep 6s linear 1.2s infinite; }
@keyframes d-fig-sweep {
  0% { opacity: 0; transform: translateX(0); }
  5%, 90% { opacity: .5; }
  100% { opacity: 0; transform: translateX(484px); }
}

.d-fig-grow { transform-origin: 0 50%; animation: d-fig-grow .9s cubic-bezier(.3,.7,.2,1) .1s both; }
@keyframes d-fig-grow { from { transform: scaleX(0); } }
.d-fig-limits .d-fig-grow rect { animation: d-fig-glow 3s ease-in-out 1.2s infinite; }
@keyframes d-fig-glow { 50% { opacity: .7; } }

/* The cursor walks the term, the grace, and past it; at rest it sits at the start. */
.d-fig-cursor { animation: d-fig-cursor 6s ease-in-out .3s infinite; }
@keyframes d-fig-cursor {
  0%, 8% { transform: translateX(0); }
  55% { transform: translateX(384px); }
  80% { transform: translateX(548px); }
  92%, 100% { transform: translateX(612px); opacity: 0; }
}

.d-fig-out { animation: d-fig-out 2.4s ease-in-out .8s infinite; }
@keyframes d-fig-out { 0%, 100% { transform: translateX(0); opacity: 1; } 60% { transform: translateX(10px); opacity: .5; } }

/* drawings/guardian.css */
/* guardian: a glyph mosaic; the scan band is the loop. */
.d-guardian-l { font: 400 clamp(22px, 60px - 2.7vw, 44px)/1 var(--mx-pixel); fill: var(--mx-on-dark); }
.d-guardian-scan { animation: mo-scan 9s linear 1.2s infinite; }

/* drawings/loan-out.css */
/* loan-out: a glyph mosaic; the scan band is the loop. */
.d-loan-out-l { font: 400 clamp(22px, 60px - 2.7vw, 44px)/1 var(--mx-pixel); fill: var(--mx-on-dark); }
.d-loan-out-scan { animation: mo-scan 7s linear 1.2s infinite; }

/* drawings/lookup.css */
/* lookup: a glyph mosaic; the scan band is the loop. */
.d-lookup-l { font: 400 clamp(22px, 60px - 2.7vw, 44px)/1 var(--mx-pixel); fill: var(--mx-on-dark); }
.d-lookup-scan { animation: mo-scan 8s linear 1.2s infinite; }

/* drawings/mint.css */
/* mint: a glyph mosaic; the scan band is the loop. */
.d-mint-l { font: 400 clamp(22px, 60px - 2.7vw, 44px)/1 var(--mx-pixel); fill: var(--mx-on-dark); }
.d-mint-scan { animation: mo-scan 6s linear 1.2s infinite; }
.d-mint-top { opacity: .7; }

/* drawings/pool-fills.css */
/* pool-fills: a glyph mosaic; the scan band is the loop. */
.d-pool-fills-l { font: 400 clamp(14px, 30px - 1.2vw, 26px)/1 var(--mx-pixel); fill: var(--mx-on-dark); }
.d-pool-fills-scan { animation: mo-scan 9s linear 1.2s infinite; }
.d-pool-fills .mo { opacity: .36; }

/* drawings/stack.css */
/* stack: a glyph mosaic; the scan band is the loop. */
.d-stack-l { font: 400 clamp(22px, 60px - 2.7vw, 44px)/1 var(--mx-pixel); fill: var(--mx-on-dark); }
.d-stack-scan { animation: mo-scan 7s linear 1.2s infinite; }

/* drawings/vault.css */
/* vault: a glyph mosaic; the scan band is the loop. */
.d-vault-l { font: 400 clamp(22px, 60px - 2.7vw, 44px)/1 var(--mx-pixel); fill: var(--mx-on-dark); }
.d-vault-scan { animation: mo-scan 7s linear 1.2s infinite; }

/* pages/actions.css */
/* Token actions (borrow, repay, settle, trade) and /borrow (engineer B). Everything is prefixed act-. */

.act { display: grid; gap: 12px; min-width: 0; }
.act > * { min-width: 0; }

/* ------------------------------------------------------------ fields */
.act-field { display: grid; gap: 6px; }
.act-label { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; flex-wrap: wrap; font: 600 var(--fs-micro)/1.3 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--fg-mute); }
.act-label label { color: var(--fg-soft); }
.act-label > span { letter-spacing: 0; text-transform: none; font-weight: 500; }
.act-label b { color: var(--fg-soft); font-weight: 600; }
.act-input {
  display: flex; align-items: center; gap: 8px; min-width: 0; height: 52px; padding: 0 8px 0 14px;
  border: 1px solid var(--rule-strong); border-radius: var(--r-m); background: var(--bg);
  transition: border-color .15s, box-shadow .15s;
}
.act-input:focus-within { border-color: var(--up); box-shadow: 0 0 0 3px rgba(74, 222, 128, .12); }
.act-input input { flex: 1 1 auto; min-width: 0; height: 100%; padding: 0; border: 0; background: transparent; font: 600 20px/1 var(--mono); color: var(--fg); }
.act-input input:focus { outline: none; }
.act-input input::placeholder { color: var(--rule-strong); }
.act-input .unit { flex: none; max-width: 40%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 600 13px/1 var(--mono); color: var(--fg-soft); }
.act-chip {
  flex: none; height: 28px; padding: 0 10px; border-radius: 999px; border: 1px solid var(--rule-strong);
  background: var(--panel-2); color: var(--fg-soft); font: 600 11px/1 var(--mono); letter-spacing: .04em; cursor: pointer;
  transition: color .15s, border-color .15s, background .15s;
}
.act-chip:hover { color: var(--up); border-color: var(--up-line); background: var(--up-dim); }
.act-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.act-term { font: 700 15px/1 var(--mono); color: var(--fg); letter-spacing: 0; text-transform: none; }
.act-scale { display: flex; justify-content: space-between; font: 500 var(--fs-micro)/1 var(--mono); color: var(--fg-mute); }
.act input[type="range"] { height: 24px; margin: 0; }

/* ------------------------------------------------------------ read-outs */
.act-rows { margin: 0; display: grid; gap: 0; border: 1px solid var(--rule); border-radius: var(--r-m); background: var(--panel-2); padding: 4px 12px; }
.act-rows > div { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 7px 0; border-bottom: 1px solid var(--rule); min-width: 0; }
.act-rows > div:last-child { border-bottom: 0; }
.act-rows dt { font: 500 12px/1.3 var(--sans); color: var(--fg-soft); display: flex; align-items: center; gap: 6px; }
.act-rows dd { margin: 0; font: 600 13px/1.3 var(--mono); text-align: right; overflow-wrap: anywhere; min-width: 0; }
.act-rows dd b { font-weight: 700; }
.act-tax dt { color: var(--up); }
.act-tax dt svg { width: 14px; height: 14px; }
.act-tax dd { color: var(--up); }

.act-state { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.act-room { font: 500 var(--fs-micro)/1.3 var(--mono); color: var(--fg-mute); }
.act-why { padding: 8px 12px; border-radius: var(--r-s); background: var(--amber-dim); color: var(--amber); font-size: var(--fs-small); line-height: 1.4; }
.act-fine { color: var(--fg-mute); font-size: 12px; line-height: 1.45; }
.act-fine svg { width: 13px; height: 13px; }

/* ------------------------------------------------------------ the action button and its status */
.act-go { width: 100%; }
.act-go svg { width: 18px; height: 18px; }
.act-go.act-sell { background: var(--down); border-color: var(--down); color: #2a0707; }
.act-go.act-sell:hover { color: #2a0707; box-shadow: 0 0 24px rgba(248, 113, 113, .35); }
.act-go.act-burn:not([disabled]) { background: var(--down-dim); border-color: rgba(248, 113, 113, .45); color: var(--down); }
.act-go.act-burn:not([disabled]):hover { background: #3a1719; }
.act-busy { background: var(--panel-2); color: var(--fg-soft); border-color: var(--rule-strong); }
.act-spin { display: inline-flex; flex: none; }
.act-spin svg { width: 1.1em; height: 1.1em; animation: act-spin 1s linear infinite; }
@keyframes act-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .act-spin svg { animation: none; } }
.act .notice span { min-width: 0; overflow-wrap: anywhere; }
.act-tx { display: inline-flex; align-items: center; gap: 3px; font-family: var(--mono); text-decoration: underline; text-underline-offset: 2px; }
.act-tx svg { width: 12px; height: 12px; }

/* ------------------------------------------------------------ trade */
.act-trade-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.act-side { flex: 1 1 180px; max-width: 260px; }
.act-side button { flex: 1 1 0; height: 34px; font-size: 13px; }
.act-side button[data-side="buy"][aria-pressed="true"] { background: var(--up); color: var(--up-ink); }
.act-side button[data-side="sell"][aria-pressed="true"] { background: var(--down); color: #2a0707; }
.act-arrow { display: grid; place-items: center; height: 18px; margin: -6px 0; color: var(--fg-mute); }
.act-arrow svg { width: 16px; height: 16px; }
.act-out { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding: 12px 14px; border-radius: var(--r-m); background: var(--panel-2); border: 1px solid var(--rule); }
.act-out .k, .act-slip .k { font: 600 var(--fs-micro)/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--fg-mute); }
.act-out b { font: 700 20px/1.2 var(--mono); color: var(--fg); overflow-wrap: anywhere; }
.act-slip { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.act-slip .seg button { padding: 0 9px; }

/* ------------------------------------------------------------ loans (repay, settle, /borrow cards) */
.act-repay { display: grid; gap: 12px; min-width: 0; }
.act-repay > div { display: grid; gap: 12px; min-width: 0; }
.act-repay > div:empty { display: none; }
.act-loan-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.act-when { font: 600 12px/1.2 var(--mono); color: var(--fg-soft); }
.act-empty { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 14px; border-radius: var(--r-m); border: 1px dashed var(--rule-strong); color: var(--fg-soft); font-size: var(--fs-small); }
.act-empty > svg { width: 18px; height: 18px; flex: none; color: var(--fg-mute); }
.act-empty > span { flex: 1 1 160px; min-width: 0; }
.act .notice.bad svg, .act-repay .notice svg { flex: none; }

.act-upkeep { border-top: 1px solid var(--rule); padding-top: 10px; }
.act-upkeep summary { display: flex; align-items: center; gap: 8px; cursor: pointer; list-style: none; font: 600 12px/1.2 var(--mono); color: var(--fg-soft); }
.act-upkeep summary::-webkit-details-marker { display: none; }
.act-upkeep summary::after { content: "+"; margin-left: auto; font-size: 16px; color: var(--fg-mute); }
.act-upkeep[open] summary::after { content: "\2212"; }
.act-upkeep summary:hover { color: var(--up); }
.act-upkeep summary svg { width: 14px; height: 14px; }
.act-up { display: grid; gap: 8px; margin-top: 10px; }
.act-up-row { display: grid; grid-template-columns: 150px minmax(0, 1fr); align-items: center; gap: 10px; font-size: 12px; color: var(--fg-soft); }
.act-up-row .btn { width: 100%; font-family: var(--mono); }
.act-upkeep > div[data-o="upmsg"]:not(:empty) { margin-top: 10px; }
@media (max-width: 400px) { .act-up-row { grid-template-columns: minmax(0, 1fr); gap: 4px; } }

/* ------------------------------------------------------------ /borrow */
.act-mine-wrap { gap: 14px; }
.act-mine { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); align-items: start; }
.act-mine:empty { display: none; }
.act-mine-empty { padding: 22px 16px; }
.act-mine-empty > svg { width: 28px; height: 28px; color: var(--up); }
.act-mine-stats .v small { font-size: .5em; color: var(--fg-soft); }
.act-mine-who { font-size: 18px; }
@media (max-width: 479px) { .act-mine-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } .act-mine-stats .stat:last-child { grid-column: 1 / -1; } }
.act-card { display: grid; gap: 12px; padding: 14px; border-radius: var(--r-l); border: 1px solid var(--rule-strong); background: var(--panel-2); min-width: 0; }
.act-card.done { border-color: var(--up-line); }
.act-card-head, .act-pool { display: flex; align-items: center; gap: 12px; min-width: 0; }
.act-card-head > svg, .act-pool > svg { width: 16px; height: 16px; flex: none; color: var(--fg-mute); margin-left: auto; }
.act-card-head:hover > svg, .act-pool:hover > svg { color: var(--up); }
.act-card-head .pic, .act-pool .pic { width: 44px; height: 44px; flex: none; border-radius: var(--r-s); overflow: hidden; background: var(--panel-3); }
.act-pool .pic { width: 40px; height: 40px; }
.act-card-head .pic img, .act-card-head .pic svg, .act-pool .pic img, .act-pool .pic svg { width: 100%; height: 100%; display: block; object-fit: cover; }
.act-card-head .who, .act-pool .who { display: grid; gap: 2px; min-width: 0; }
.act-card-head .who b, .act-pool .who b { font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.act-card-head .who .sym { font: 600 12px/1 var(--mono); color: var(--up); }
.act-pool .who b { font-family: var(--mono); color: var(--up); }
.act-pool .who span { font-size: 12px; color: var(--fg-mute); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.act-card-body { min-width: 0; }

.act-pools { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 360px), 1fr)); }
.act-pool { padding: 12px 14px; border-radius: var(--r-m); border: 1px solid var(--rule); background: var(--panel); transition: border-color .15s, background .15s; }
.act-pool:hover { color: inherit; border-color: var(--up-line); background: var(--panel-2); }
.act-pool .pill { flex: none; }
.act-pool .room { display: grid; gap: 3px; justify-items: end; margin-left: auto; text-align: right; min-width: 0; }
.act-pool .room + svg { margin-left: 0; }
.act-pool .room .k { font: 600 10px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--fg-mute); white-space: nowrap; }
.act-pool .room b { font: 700 14px/1 var(--mono); white-space: nowrap; }
.act-pool .room b small { font-size: 11px; color: var(--fg-soft); font-weight: 500; }
@media (max-width: 479px) {
  .act-pool { flex-wrap: wrap; row-gap: 8px; }
  .act-pool .who { flex: 1 1 0; }
  .act-pool > svg { display: none; }
  .act-pool .room { margin-left: 0; width: 100%; grid-auto-flow: column; justify-content: space-between; align-items: baseline; padding-top: 8px; border-top: 1px solid var(--rule); }
}
.act-form { display: grid; gap: 12px; min-width: 0; }
.act-closed > svg { color: var(--amber); }
.act-mine-stats .stat:nth-child(2) .v { white-space: normal; overflow-wrap: anywhere; font-size: clamp(18px, 2vw, 24px); line-height: 1.25; }
.act-pool .who { flex: 1 1 auto; }
.act-addr input { font-size: 13px; }

/* pages/content.css */
/* Content routes (C): /how-it-works, /risks, /security, /contracts. Classes are c-*. */

/* ---------------------------------------------------------------- sections */
.c-sec { display: grid; gap: 14px; min-width: 0; }
.c-head { display: grid; gap: 4px; min-width: 0; }
.c-head p { color: var(--fg-soft); }
.c-sub { font-size: var(--fs-h3); margin-top: 4px; }
.c-note { font: 500 var(--fs-small)/1.45 var(--mono); color: var(--fg-soft); }
.c-note a, .c-facts a { color: var(--up); }
.c-note a:hover, .c-facts a:hover { text-decoration: underline; }
.c-sec code, .c-facts code, .notice code {
  font: 500 .88em/1.3 var(--mono); background: var(--panel-3); color: var(--fg); padding: 1px 5px; border-radius: 4px;
  overflow-wrap: anywhere;
}
.notice span { min-width: 0; }
.c-pair { display: grid; gap: 12px; min-width: 0; }
@media (min-width: 900px) { .c-pair { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; } }
.c-next { display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------------------------------------------------------------- figure panels */
.c-fig { margin: 0; min-width: 0; background: var(--panel); border: 1px solid var(--rule); border-radius: var(--r-l); padding: 16px; display: grid; gap: 10px; align-content: start; }
.c-fig figcaption { font: 500 var(--fs-small)/1.4 var(--mono); color: var(--fg-mute); text-align: center; }
.c-fig-svg { max-width: 480px; margin-inline: auto; }
.c-ink { fill: var(--up-ink); }
.c-downdim { fill: var(--down-dim); }

/* motion inside .fig: base.css stops all of it under prefers-reduced-motion */
.c-drip { animation: c-drip 2.4s ease-in 1s infinite; }
@keyframes c-drip { 0% { transform: translateY(-10px); opacity: 0; } 25%, 80% { transform: translateY(0); opacity: 1; } 100% { transform: translateY(6px); opacity: 0; } }
.c-grow { transform-origin: 0 50%; animation: c-grow 1.1s cubic-bezier(.3, .7, .2, 1) .2s both; }
@keyframes c-grow { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.c-draw { stroke-dasharray: 1; animation: m-draw 1.4s cubic-bezier(.3, .7, .2, 1) .2s both; }

/* ---------------------------------------------------------------- chips, steps, facts */
.c-chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.c-chips li { display: inline-flex; align-items: center; gap: 7px; min-height: 32px; padding: 4px 12px; border-radius: 999px; background: var(--panel-2); border: 1px solid var(--rule); font: 600 12px/1.2 var(--mono); color: var(--fg-soft); }
.c-chips svg { width: 15px; height: 15px; color: var(--up); }

.c-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 768px) { .c-steps { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.c-steps li { background: var(--panel); border: 1px solid var(--rule); border-radius: var(--r-m); padding: 12px; display: grid; gap: 4px; align-content: start; min-width: 0; }
.c-steps b { font: 700 15px/1.2 var(--mono); margin-top: 6px; }
.c-steps li > span:last-child { font-size: var(--fs-small); color: var(--fg-soft); line-height: 1.35; }
.c-dot { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--up-dim); color: var(--up); flex: none; }
.c-dot svg { width: 17px; height: 17px; }
.c-dot.amber { background: var(--amber-dim); color: var(--amber); }

.c-rule { font: 500 var(--fs-small)/1.5 var(--mono); color: var(--fg-soft); padding: 10px 14px; border-left: 3px solid var(--amber); background: var(--panel); border-radius: 0 var(--r-s) var(--r-s) 0; }
.c-rule b { color: var(--amber); }

.c-facts { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; align-content: start; min-width: 0; }
.c-facts li { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; background: var(--panel); border: 1px solid var(--rule); border-radius: var(--r-m); min-width: 0; }
.c-facts svg { width: 18px; height: 18px; color: var(--up); flex: none; margin-top: 2px; }
.c-row3 { grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); }

/* ---------------------------------------------------------------- borrowing limits */
.c-limits { background: var(--panel); border: 1px solid var(--rule); border-radius: var(--r-l); padding: 16px; display: grid; gap: 16px; }
.c-limit { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "k v" "m m"; gap: 8px 12px; align-items: center; }
@media (min-width: 768px) { .c-limit { grid-template-columns: minmax(0, 300px) minmax(0, 1fr) 80px; grid-template-areas: "k m v"; } }
.c-lk { grid-area: k; display: flex; gap: 8px; align-items: center; font-weight: 600; min-width: 0; }
.c-lk svg { width: 18px; height: 18px; color: var(--up); flex: none; }
.c-limit meter { grid-area: m; height: 12px; }
.c-limit meter::-webkit-meter-bar { height: 12px; }
.c-lv { grid-area: v; display: flex; align-items: baseline; justify-content: flex-end; gap: 6px; white-space: nowrap; }
.c-lv b { font: 700 20px/1 var(--mono); color: var(--up); }
.c-lk > span { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; min-width: 0; }
.c-lk small { font: 500 var(--fs-micro)/1.2 var(--mono); color: var(--fg-mute); }

/* ---------------------------------------------------------------- the price clock */
.c-clockmod { gap: 14px; }
.c-controls { display: grid; gap: 14px; }
@media (min-width: 768px) { .c-controls { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; } }
.c-range-row { display: flex; align-items: center; gap: 12px; }
.c-range-row input { flex: 1; min-width: 0; height: 28px; }
.c-range-row input:disabled { opacity: .5; }
.c-range-row output { min-width: 60px; text-align: right; font: 700 18px/1 var(--mono); color: var(--fg); }
.c-chart { height: 220px; border-radius: var(--r-m); background: var(--bg); border: 1px solid var(--rule); overflow: hidden; }
@media (min-width: 768px) { .c-chart { height: 300px; } }
.c-chart .fig { width: 100%; height: 100%; overflow: hidden; }
.c-closed { fill: var(--panel-2); }
.c-list { fill: none; stroke: var(--rule-strong); stroke-width: 1.5; stroke-dasharray: 4 5; }
.c-tick { fill: none; stroke: var(--rule-strong); stroke-width: 1; }
.c-market { fill: none; stroke: var(--fg-soft); stroke-width: 2; stroke-linejoin: round; }
.c-ref { fill: none; stroke: var(--amber); stroke-width: 2; stroke-linejoin: round; }
.c-lend { fill: none; stroke: var(--up); stroke-width: 6; stroke-linejoin: round; stroke-linecap: round; opacity: .55; }
.c-axis { display: flex; justify-content: space-between; margin-top: -8px; font: 500 var(--fs-micro)/1 var(--mono); color: var(--fg-mute); }
.c-legend { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 16px; font: 500 var(--fs-micro)/1.2 var(--mono); color: var(--fg-soft); }
.c-legend li, .c-pnl-legend span { display: inline-flex; align-items: center; gap: 6px; }
.c-sw { display: inline-block; width: 16px; height: 3px; border-radius: 2px; background: var(--fg-soft); }
.c-sw-ref { background: var(--amber); }
.c-sw-lend { background: var(--up); height: 5px; }
.c-sw-down { background: var(--down); height: 5px; }
.c-sw-closed { background: var(--panel-2); height: 10px; box-shadow: inset 0 0 0 1px var(--rule-strong); }
.c-readout { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.c-readout .stat { background: var(--panel-2); }
.c-readout + .c-note { margin-top: 10px; }

/* ---------------------------------------------------------------- risks */
.c-guard, .c-after { background: var(--panel); border: 1px solid var(--rule); border-radius: var(--r-l); padding: 16px; display: grid; gap: 14px; min-width: 0; }
.c-guard { border-color: rgba(251, 191, 36, .28); }
.c-guard-who { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; min-width: 0; }
.c-guard-who > svg { width: 22px; height: 22px; color: var(--amber); }
.c-guard-who > b { font-weight: 650; margin-right: auto; }
.c-guard-who.big { background: var(--panel); border: 1px solid rgba(251, 191, 36, .28); border-radius: var(--r-l); padding: 14px 16px; }
.c-powers { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.c-powers li { display: flex; gap: 12px; align-items: center; min-width: 0; }
.c-powers li > span:last-child { min-width: 0; }
.c-after h3 { font-size: 15px; }
.c-after .c-facts li { background: var(--panel-2); border: 0; }
.c-after .c-facts svg { color: var(--amber); }

.c-mrows, .c-bars2 { display: grid; gap: 14px; }
.c-mrow { display: grid; grid-template-columns: minmax(84px, auto) minmax(0, 1fr) 64px; gap: 12px; align-items: center; font: 500 var(--fs-small)/1.2 var(--mono); color: var(--fg-soft); }
.c-bars2 .c-mrow { grid-template-columns: minmax(0, 1fr) 64px; grid-template-areas: "k b" "m m"; gap: 6px 12px; }
.c-bars2 .c-mk { grid-area: k; }
.c-bars2 meter { grid-area: m; }
.c-bars2 .c-mrow > b { grid-area: b; }
.c-mrow > b { text-align: right; color: var(--fg); font-size: 16px; }
.c-mrow meter { height: 12px; }
.c-mrow meter::-webkit-meter-bar { height: 12px; }
.c-mrows meter::-webkit-meter-optimum-value { background: var(--amber); }
.c-mrows meter::-moz-meter-bar { background: var(--amber); }
.c-mrows .c-mrow > b { color: var(--amber); }
.c-bars2 .c-mrow:first-child meter::-webkit-meter-optimum-value { background: var(--down); }
.c-bars2 .c-mrow:first-child meter::-moz-meter-bar { background: var(--down); }

.c-pnl-legend { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-bottom: 4px; font: 500 var(--fs-micro)/1.2 var(--mono); color: var(--fg-soft); }
.c-pnls { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.c-pnl { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "k v" "m m" "b b"; gap: 3px 10px; align-items: center; }
@media (min-width: 900px) {
  .c-pnl { grid-template-columns: 220px 180px minmax(0, 1fr) 100px; grid-template-areas: "k m b v"; gap: 12px; }
}
.c-pk { grid-area: k; font: 500 var(--fs-small)/1.3 var(--mono); color: var(--fg-soft); white-space: nowrap; }
.c-pk b { color: var(--fg); font-weight: 650; }
.c-pk em { font: 600 10px/1 var(--mono); font-style: normal; text-transform: uppercase; letter-spacing: .04em; color: var(--fg-mute); border: 1px solid var(--rule-strong); border-radius: 4px; padding: 2px 4px; margin-left: 4px; vertical-align: 1px; }
.c-pm { grid-area: m; font: 500 var(--fs-micro)/1.2 var(--mono); color: var(--fg-mute); }
.c-pnlbar { grid-area: b; display: block; width: 100%; height: 18px; }
.c-pv { grid-area: v; text-align: right; font: 700 var(--fs-small)/1 var(--mono); color: var(--up); white-space: nowrap; }
.c-pnl.win .c-pv, .c-pnl.win .c-pk b { color: var(--down); }
.c-winbar { fill: var(--up); }
.c-lossbar { fill: var(--down); }
.c-axisline { fill: var(--rule); }
.c-zero { fill: var(--fg-mute); }
.c-early { margin-top: 16px; padding-top: 16px; border-top: 1px dashed var(--rule-strong); }

/* ---------------------------------------------------------------- security */
.c-keys { display: grid; gap: 10px; }
.c-auths { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); }
.c-auth { background: var(--panel); border: 1px solid var(--rule); border-left: 3px solid var(--up-line); border-radius: var(--r-m); padding: 12px 14px; display: grid; gap: 8px; align-content: start; min-width: 0; }
.c-auth.g { border-left-color: var(--amber); }
.c-auth-name { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 10px; min-width: 0; }
.c-auth-name b { font: 650 var(--fs-small)/1.2 var(--mono); overflow-wrap: anywhere; }
.c-auth-key { display: inline-flex; align-items: center; gap: 6px; font: 700 var(--fs-micro)/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--amber); }
.c-auth-key.none { color: var(--up); }
.c-auth-key svg { width: 15px; height: 15px; }
.c-auth-fns { display: flex; flex-wrap: wrap; gap: 6px; }
.c-auth-fns code { font-size: 11px; color: var(--amber); background: var(--amber-dim); }

.c-gatehead { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.c-big { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.c-big b { font: 800 clamp(44px, 7vw, 64px)/1 var(--mono); letter-spacing: -0.04em; }
.c-big span { color: var(--fg-soft); }
.c-fp { display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 999px; font: 600 var(--fs-small)/1.2 var(--mono); }
.c-fp svg { width: 16px; height: 16px; flex: none; }
.c-fp code { background: transparent; padding: 0; color: inherit; }
.c-fp.ok { background: var(--up-dim); color: var(--up); }
.c-fp.bad { background: var(--down-dim); color: var(--down); }
.c-cells { list-style: none; margin: 0; padding: 0; display: grid; gap: 5px; grid-template-columns: repeat(10, minmax(0, 1fr)); }
@media (min-width: 900px) { .c-cells { grid-template-columns: repeat(25, minmax(0, 1fr)); } }
.c-cells li { aspect-ratio: 1; border-radius: 6px; display: grid; place-items: center; font: 600 10px/1 var(--mono); animation: c-cell .5s ease-out both; }
.c-cells li.red { background: var(--down-dim); color: var(--down); border: 1px solid rgba(248, 113, 113, .4); }
.c-cells li.stale { background: var(--panel-3); color: var(--fg-mute); }
.c-cells li:nth-child(5n+2) { animation-delay: .08s; } .c-cells li:nth-child(5n+3) { animation-delay: .16s; }
.c-cells li:nth-child(5n+4) { animation-delay: .24s; } .c-cells li:nth-child(5n+5) { animation-delay: .32s; }
@keyframes c-cell { from { opacity: 0; transform: scale(.6); } to { opacity: 1; transform: scale(1); } }
.c-guards { list-style: none; margin: 0; padding: 0; columns: 2 340px; column-gap: 24px; }
.c-guards li { break-inside: avoid; display: flex; gap: 10px; align-items: baseline; padding: 7px 0; border-bottom: 1px solid var(--rule); font-size: var(--fs-small); line-height: 1.35; color: var(--fg-soft); }
.c-guards code { flex: none; background: transparent; padding: 0; font-weight: 700; }
.c-guards code.down { color: var(--down); }

.c-stats4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 767px) { .c-stats4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.c-stats4 .stat .s { line-height: 1.35; }
.c-sev { background: var(--panel); border: 1px solid var(--rule); border-radius: var(--r-l); padding: 16px; display: grid; gap: 10px; }
.c-sevrow { display: grid; grid-template-columns: 72px minmax(0, 1fr) 32px; gap: 12px; align-items: center; font: 600 var(--fs-small)/1 var(--mono); color: var(--fg-soft); }
.c-sevrow b { text-align: right; color: var(--fg); }
.c-sevrow meter { height: 12px; }
.c-sevrow meter::-webkit-meter-bar { height: 12px; }
.c-sevrow.high meter::-webkit-meter-optimum-value { background: var(--down); }
.c-sevrow.medium meter::-webkit-meter-optimum-value { background: var(--amber); }
.c-sevrow.low meter::-webkit-meter-optimum-value { background: var(--fg-mute); }
.c-sevrow.high meter::-moz-meter-bar { background: var(--down); }
.c-sevrow.medium meter::-moz-meter-bar { background: var(--amber); }
.c-sevrow.low meter::-moz-meter-bar { background: var(--fg-mute); }
.c-checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); }
.c-checks li { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; background: var(--panel); border: 1px solid var(--rule); border-radius: var(--r-s); min-width: 0; }
.c-gk { font-size: var(--fs-small); min-width: 0; }
.c-gd { display: flex; gap: 4px; flex: none; }
.c-gd i { width: 12px; height: 12px; border-radius: 3px; background: var(--up); }
.c-gd i.na { background: var(--panel-3); box-shadow: inset 0 0 0 1px var(--rule-strong); }

/* ---------------------------------------------------------------- contracts */
.c-nethead { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.c-meta { font: 500 var(--fs-micro)/1.3 var(--mono); color: var(--fg-mute); }
.c-addrs { list-style: none; margin: 0; padding: 0; background: var(--panel); border: 1px solid var(--rule); border-radius: var(--r-l); }
.c-addrs li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; padding: 12px 14px; border-bottom: 1px solid var(--rule); min-width: 0; }
.c-addrs li:last-child { border-bottom: 0; }
.c-an { display: flex; gap: 10px; align-items: flex-start; min-width: 0; }
.c-an > svg { width: 18px; height: 18px; color: var(--up); flex: none; margin-top: 2px; }
.c-an > span { display: grid; gap: 2px; min-width: 0; }
.c-an b { font-weight: 600; }
.c-an b a { color: var(--up); }
.c-an small { font-size: 12px; color: var(--fg-mute); line-height: 1.3; }
.c-pairaddr { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.c-stackfig { max-width: 400px; }
.c-net .empty { display: block; padding: 18px; }

@media (prefers-reduced-motion: reduce) {
  .c-cells li { animation: none; }
}
.c-addrs li > .addr, .c-pairaddr { margin-left: auto; }

/* pages/home.css */
/* "/": the landing bands. The opening mosaic paints under the hero (it stays first in the DOM). */
body.landing main { position: relative; --hero-h: clamp(560px, 100svh - var(--mx-nav-h) - 8px, 900px); }
body.landing main > .opening { position: absolute; left: 0; top: 0; width: 100%; height: var(--hero-h); max-height: none; z-index: 0; }
.mx-hero { position: relative; z-index: 1; min-height: var(--hero-h); display: grid; align-items: center; }
.mx-hero__in { display: grid; justify-items: center; text-align: center; gap: var(--mx-gap-stack); padding-block: 60px; }
.mx-hero h1 { max-width: 1200px; color: var(--mx-on-dark); text-shadow: 0 0 28px var(--mx-bg-band), 0 0 6px var(--mx-bg-band); }
.mx-lead, .mx-hero__facts { text-shadow: 0 0 12px var(--mx-bg-band), 0 0 4px var(--mx-bg-band); }
.mx-lead { max-width: 661px; color: var(--mx-on-dark); font-size: var(--mx-fs-body); line-height: 1.2; }
.mx-hero__facts { font: 400 13px/1.5 var(--mx-mono); color: var(--mx-mute-band); }
.mx-hero__facts span { color: var(--mx-on-dark); }
.mx-hero .btn-row { justify-content: center; }
@media (max-width: 420px) { .mx-hero .btn-row { width: 100%; } }

.mx-section--steps { padding-bottom: 270px; }
@media (max-width: 1150px) { .mx-section--steps { padding-top: 120px; } }
@media (max-width: 620px) { .mx-section--steps { padding-bottom: 96px; } }

.mx-section--twocol { padding-top: 77px; padding-bottom: 0; }
.mx-twocol { display: flex; align-items: center; justify-content: center; gap: var(--mx-gap-cols); }
.mx-twocol__text { flex: 0 1 584px; min-width: 0; padding-top: 44px; display: grid; gap: 50px; }
.mx-inline { text-decoration: underline; text-underline-offset: 3px; }
.mx-pools { flex: 0 1 592px; min-width: 0; display: grid; gap: var(--mx-gap-grid); }
.mx-slot { flex: 0 1 592px; min-width: 0; aspect-ratio: 1; display: grid; }
.mx-slot .empty { align-content: center; }
.mx-checker { margin-top: 5px; }
@media (max-width: 1200px) {
  .mx-twocol { flex-direction: column; align-items: stretch; gap: 50px; }
  .mx-twocol__text { flex-basis: auto; padding-top: 0; }
  .mx-feature-grid { max-width: none; }
  .mx-pools, .mx-slot { flex-basis: auto; width: min(592px, 100%); margin-inline: auto; }
}

.mx-section--rings { padding-bottom: 176px; }
.mx-rings { position: relative; width: min(455px, 100vw - 2 * var(--mx-gutter)); margin: 60px auto 0; }
.mx-rings__stage { position: relative; aspect-ratio: 1; display: grid; place-items: center; }
.mx-ring { position: absolute; left: 50%; top: 50%; translate: -50% -50%; aspect-ratio: 1; border-radius: 50%; background: var(--mx-bg-band); border: var(--mx-rim); box-shadow: var(--mx-glow); }
.mx-ring--1 { width: 317.14%; opacity: .26; }
.mx-ring--2 { width: 213.85%; opacity: .54; }
.mx-ring--3 { width: 100%; opacity: .75; }
.mx-rings__center { position: relative; width: 44%; aspect-ratio: 1; display: grid; place-items: center; color: var(--mx-on-dark); }
.mx-rings__center svg { width: 100%; height: 100%; }
.mx-rings__chips { position: absolute; inset: 0; margin: 0; padding: 0; list-style: none; }
.mx-chip.mx-slot-1, .mx-chip.mx-slot-2, .mx-chip.mx-slot-3, .mx-chip.mx-slot-4, .mx-chip.mx-slot-5 { position: absolute; translate: -50% -50%; }
.mx-slot-1 { left: -19%; top: 15%; }
.mx-slot-2 { left: 113%; top: 28%; }
.mx-slot-3 { left: -12%; top: 88%; }
.mx-slot-4 { left: 104%; top: 83%; }
.mx-slot-5 { left: 50%; top: 116%; }
@media (max-width: 810px) {
  .mx-section--rings { padding-bottom: 96px; }
  .mx-rings__chips { position: relative; inset: auto; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 24px; }
  .mx-chip.mx-slot-1, .mx-chip.mx-slot-2, .mx-chip.mx-slot-3, .mx-chip.mx-slot-4, .mx-chip.mx-slot-5 { position: static; translate: none; }
}

.mx-section--cta { padding-top: 0; }

/* pages/launch.css */
/* /launch (A): the form, its preview, and the fixed launch shape. Every class is lx-* or scoped to
   main.page-launch. No inline styles: runtime changes are classes, hidden and <progress>. */

main.page-launch { gap: 22px; }
main.page-launch > .page-head .lead { font-size: 15px; }
@media (min-width: 768px) { main.page-launch > .page-head .lead { font-size: var(--fs-lead); } }

/* ---------------------------------------------------------------- layout */
.lx { padding: 0; background: transparent; border: 0; gap: 0; }
.lx > .note.wait { margin-bottom: 12px; display: flex; align-items: center; gap: 6px; }
.lx-grid { display: grid; gap: 16px; grid-template-columns: minmax(0, 1fr); align-items: start; }
@media (min-width: 960px) {
  .lx-grid { grid-template-columns: minmax(0, 1fr) 340px; gap: 20px; }
  .lx-side { position: sticky; top: calc(var(--header-h) + 16px); }
}
.lx-form { display: grid; gap: 12px; min-width: 0; }

/* ---------------------------------------------------------------- steps */
.lx-step {
  margin: 0; min-width: 0; display: grid; gap: 12px;
  padding: 14px; border: 1px solid var(--rule); border-radius: var(--r-l); background: var(--panel);
}
@media (min-width: 768px) { .lx-step { padding: 18px; } }
.lx-step legend {
  float: left; width: 100%; padding: 0; display: flex; align-items: center; gap: 10px;
  font: 650 16px/1 var(--sans); letter-spacing: -0.01em;
}
.lx-step legend + * { clear: both; }
.lx-n {
  display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; flex: none;
  font: 700 12px/1 var(--mono); color: var(--up-ink); background: var(--up);
}
.lx-ok { margin-left: auto; display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; color: var(--up); background: var(--up-dim); }
.lx-ok svg { width: 14px; height: 14px; }

.lx-pair { display: grid; gap: 10px; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); }
.lx-links { display: grid; gap: 10px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 767px) { .lx-links { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 479px) { .lx-pair { grid-template-columns: minmax(0, 1fr); } }
.lx-field { min-width: 0; }
.lx-field input, .lx-field textarea { font-size: 14px; }
.lx-field input::placeholder, .lx-field textarea::placeholder { color: var(--fg-mute); }
.lx-field input:disabled, .lx-field textarea:disabled { opacity: .55; }
.lx-hint { font: 500 var(--fs-micro)/1.45 var(--mono); color: var(--fg-mute); }
.lx-hint .ic { width: 12px; height: 12px; }
.lx-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; min-width: 0; }

/* ---------------------------------------------------------------- image drop */
.lx-media { display: grid; gap: 10px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 768px) { .lx-media { grid-template-columns: 220px minmax(0, 1fr); } }
.lx-drop {
  position: relative; display: flex; align-items: center; gap: 12px; min-height: 88px; padding: 12px;
  border: 1.5px dashed var(--rule-strong); border-radius: var(--r-m); background: var(--bg); cursor: pointer;
  transition: border-color .15s, background .15s;
}
.lx-drop:hover, .lx-drop.over, .lx-drop:focus-within { border-color: var(--up); background: var(--up-dim); }
.lx-drop.has { border-style: solid; border-color: var(--up-line); }
.lx-drop.bad { border-color: var(--down); }
.lx-drop.bad [data-drop-note] { color: var(--down); }
.lx-drop input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.lx-drop-pic {
  flex: none; display: grid; place-items: center; width: 56px; height: 56px; border-radius: var(--r-s);
  background: var(--panel-3); color: var(--up); overflow: hidden;
}
.lx-drop-pic svg { width: 24px; height: 24px; }
.lx-drop-pic img { width: 100%; height: 100%; object-fit: cover; display: block; }
.lx-drop-text { display: grid; gap: 4px; min-width: 0; }
.lx-drop-text b { font: 600 14px/1.2 var(--sans); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lx-drop-text span { font: 500 var(--fs-micro)/1.4 var(--mono); color: var(--fg-mute); }

/* ---------------------------------------------------------------- listing */
.lx-cid input { font-size: 13px; }
.lx-cid.focus input { border-color: var(--amber); box-shadow: 0 0 0 3px var(--amber-dim); }

/* ---------------------------------------------------------------- messages */
.lx-msg {
  display: flex; align-items: flex-start; gap: 8px; margin: 0; padding: 10px 12px; border-radius: var(--r-s);
  font-size: var(--fs-small); line-height: 1.45; overflow-wrap: anywhere;
  background: var(--panel-2); color: var(--fg-soft); border: 1px solid var(--rule);
}
.lx-msg .ic { width: 16px; height: 16px; margin-top: 2px; }
.lx-msg.ok { background: var(--up-dim); color: var(--up); border-color: var(--up-line); }
.lx-msg.bad { background: var(--down-dim); color: var(--down); border-color: rgba(248, 113, 113, .3); }
.lx-msg.warn { background: var(--amber-dim); color: var(--amber); border-color: rgba(251, 191, 36, .3); }
.lx-msg.info .ic, .lx-progress li.run .ic { animation: lx-spin 1s linear infinite; }
@keyframes lx-spin { to { transform: rotate(360deg); } }

/* ---------------------------------------------------------------- quote */
.lx-seg { justify-self: start; }
.lx-seg button { min-width: 72px; height: 34px; font-size: 13px; }
.lx-seg button[aria-pressed="true"] { background: var(--up); color: var(--up-ink); }

/* ---------------------------------------------------------------- address mining */
.lx-mine { display: grid; gap: 10px; }
.lx-addr {
  display: block; min-width: 0; padding: 12px 14px; border-radius: var(--r-m);
  background: var(--bg); border: 1px solid var(--rule-strong);
  font: 600 clamp(10.5px, 2.8vw, 17px)/1.5 var(--mono); letter-spacing: 0; word-break: break-all;
}
.lx-addr-body { color: var(--fg-soft); }
.lx-q { color: var(--fg-mute); }
.lx-tail {
  display: inline-block; margin-left: 1px; padding: 0 4px; border-radius: 4px;
  color: var(--up-ink); background: var(--up); font-weight: 700;
}
.lx-addr.rolling .lx-q { animation: lx-roll 1.1s steps(4) infinite; }
@keyframes lx-roll { 50% { color: var(--fg-soft); } }
.lx-addr.found { border-color: var(--up-line); box-shadow: 0 0 0 3px var(--up-dim); }
.lx-addr.found .lx-addr-body { color: var(--fg); }
.lx-mine-foot { justify-content: space-between; }

/* ---------------------------------------------------------------- launch */
.lx-go { min-width: min(100%, 320px); }
.lx-go .ic { width: 18px; height: 18px; }
@media (max-width: 479px) { .lx-go { width: 100%; font-size: 14px; padding: 0 12px; } }
[data-go-note] { margin: 0; }
[data-go-note].bad { color: var(--down); }
.lx-confirm {
  display: grid; gap: 12px; padding: 14px; border-radius: var(--r-m);
  border: 1px solid rgba(251, 191, 36, .4); background: var(--amber-dim);
}
.lx-confirm h3 { display: flex; align-items: center; gap: 8px; font-size: 16px; color: var(--amber); }
.lx-confirm h3 .ic { width: 18px; height: 18px; }
.lx-confirm > p { color: var(--fg); font-size: var(--fs-small); }
.lx-confirm.main { border-color: var(--down); background: var(--down-dim); }
.lx-confirm.main h3 { color: var(--down); }
.lx-sum { margin: 0; display: grid; gap: 1px; border-radius: var(--r-s); overflow: hidden; background: var(--rule); }
.lx-sum > div { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 10px; padding: 8px 10px; background: var(--panel); }
.lx-sum dt { font: 600 var(--fs-micro)/1.5 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--fg-mute); }
.lx-sum dd { margin: 0; font-size: var(--fs-small); overflow-wrap: anywhere; min-width: 0; }
.lx-sum .num { font-size: 12px; }
.lx-sum .lx-tail { padding: 0 3px; }
.lx-progress { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.lx-progress li {
  display: flex; align-items: flex-start; gap: 8px; padding: 8px 10px; border-radius: var(--r-s);
  background: var(--panel-2); font-size: var(--fs-small); color: var(--fg-soft); overflow-wrap: anywhere;
}
.lx-progress li .ic { width: 16px; height: 16px; margin-top: 2px; }
.lx-progress li.ok .ic { color: var(--up); }
.lx-progress li.ok { color: var(--fg); }
.lx-progress li.bad { color: var(--down); background: var(--down-dim); }
.lx-progress li.run .ic { color: var(--amber); }
.lx-progress .lx-tail { padding: 0 3px; }

/* ---------------------------------------------------------------- preview */
.lx-side { display: grid; gap: 10px; min-width: 0; }
.lx-card { pointer-events: none; }
.lx-card .name b { max-width: 100%; }
.lx-pv-desc {
  color: var(--fg-soft); font-size: var(--fs-small); line-height: 1.45; overflow-wrap: anywhere;
  padding: 0 4px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.lx-checks {
  list-style: none; margin: 0; padding: 12px 14px; display: grid; gap: 8px;
  border: 1px solid var(--rule); border-radius: var(--r-l); background: var(--panel);
  font: 500 12px/1.3 var(--mono); color: var(--fg-mute);
}
.lx-checks li { display: flex; align-items: center; gap: 10px; }
.lx-checks i { flex: none; width: 14px; height: 14px; border-radius: 50%; border: 1.5px solid var(--rule-strong); }
.lx-checks li.ok { color: var(--fg); }
.lx-checks li.ok i { border-color: var(--up); background: var(--up); box-shadow: inset 0 0 0 3px var(--panel); }
@media (max-width: 959px) {
  .lx-side { grid-row: 1; }
  .lx-side .eyebrow, .lx-checks, .lx-pv-desc { display: none; }
}

/* ---------------------------------------------------------------- fixed at launch */
.lx-fixed { display: grid; gap: 14px; min-width: 0; }
.lx-fixed .aside { display: inline-flex; }
.lx-flow { max-height: 72px; max-width: 640px; }
.lx-dash { stroke-dasharray: 6 6; animation: lx-flow 1.2s linear infinite; }
@keyframes lx-flow { to { stroke-dashoffset: -12; } }
.lx-tiles { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
@media (max-width: 479px) { .lx-flow { display: none; } }
@media (max-width: 479px) { .lx-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.lx-tile {
  display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 10px; row-gap: 4px; align-items: center;
  padding: 12px; border-radius: var(--r-m); background: var(--panel); border: 1px solid var(--rule); min-width: 0;
}
.lx-tile .ic { grid-row: span 2; width: 22px; height: 22px; color: var(--fg-mute); }
.lx-tile b { font: 700 18px/1.15 var(--mono); letter-spacing: -0.01em; overflow-wrap: break-word; }
@media (max-width: 479px) { .lx-tile { padding: 10px; column-gap: 8px; } .lx-tile b { font-size: 15px; } .lx-tile .ic { width: 18px; height: 18px; } }
.lx-tile span { font: 500 var(--fs-micro)/1.3 var(--mono); color: var(--fg-mute); }
.lx-tile.up { border-color: var(--up-line); }
.lx-tile.up .ic, .lx-tile.up b { color: var(--up); }
@media (prefers-reduced-motion: reduce) {
  .lx-addr.rolling .lx-q, .lx-msg.info .ic, .lx-progress li.run .ic { animation: none; }
}

/* pages/shared.css */
/* Shared page furniture (lead). */
.page-head { display: grid; gap: 8px; }
.page-head h1 { font-size: clamp(28px, 4vw, 44px); }
.small { font-size: var(--fs-small); }
.nojs { display: block; }
.js .nojs { display: none; }
.visually-hidden:focus { position: fixed !important; top: 8px; left: 8px; width: auto; height: auto; clip: auto; z-index: 100; padding: 8px 12px; background: var(--up); color: var(--up-ink); border-radius: var(--r-s); }
table.data.narrow { min-width: 520px; }

/* pages/token.css */
/* /t/<address> and the /token lookup result (lead). */
.tok { display: grid; gap: 16px; min-width: 0; }
.tok-head { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 16px; align-items: center; }
.tok-head .pic { width: 112px; height: 112px; border-radius: var(--r-l); overflow: hidden; background: var(--panel-3); }
.tok-head .pic img, .tok-head .pic svg { width: 100%; height: 100%; display: block; object-fit: cover; }
.tok-head .who { display: grid; gap: 8px; min-width: 0; }
.tok-head .line { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; min-width: 0; }
.tok-head h1 { font-size: clamp(26px, 4vw, 40px); overflow-wrap: anywhere; }
.tok-head .sym { font: 700 18px/1 var(--mono); color: var(--up); }
.tok-head .desc { color: var(--fg-soft); max-width: 70ch; }
.tok-head .links { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px; }
@media (max-width: 479px) {
  .tok-head { grid-template-columns: 72px minmax(0, 1fr); gap: 12px; }
  .tok-head .pic { width: 72px; height: 72px; border-radius: var(--r-m); }
  .tok-head .addrs { gap: 6px 10px; }
}
.stats.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 767px) { .stats.four { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.tok-grid { display: grid; gap: 16px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 1024px) { .tok-grid { grid-template-columns: minmax(0, 1.7fr) minmax(320px, 1fr); align-items: start; } }
.tok-main, .tok-side { display: grid; gap: 16px; min-width: 0; }

.gauges { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); margin-bottom: 16px; }
.gauge { display: grid; gap: 8px; background: var(--panel-2); border-radius: var(--r-m); padding: 12px; min-width: 0; }
.g-head, .g-foot { display: flex; justify-content: space-between; gap: 8px; }
.g-head .k { display: flex; align-items: center; gap: 6px; font: 600 var(--fs-micro)/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--fg-mute); }
.g-head .num { font-weight: 700; }
.g-foot { font: 500 var(--fs-micro)/1.3 var(--mono); color: var(--fg-mute); flex-wrap: wrap; }

.pclock { display: grid; gap: 12px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 768px) { .pclock { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: center; } .pclock > p { grid-column: 1 / -1; } }
.pclock .fig { max-height: 140px; }
.pclock > .kv:only-of-type { grid-column: 1 / -1; }
.pc-bar { transform-origin: 0 50%; animation: pc-grow 1s cubic-bezier(.3,.7,.2,1) both; }
@keyframes pc-grow { from { transform: scaleX(0); } }
.kv dd.small-dd { font-size: 13px; font-weight: 500; line-height: 1.35; }

.lookup-form { display: flex; gap: 8px; flex-wrap: wrap; }
.lookup-form input { flex: 1 1 260px; }
.lookup-result { min-width: 0; }
