/* B4 Overview. One sans, a quiet neutral canvas, one accent for selection and links,
   colour only where it reports a state. Spacing sits on a 4px grid. */
@font-face { font-family: "Albert Sans"; src: url("../fonts/albert-sans-latin-wght-normal.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }
/* Digits only, for amount columns: Albert Sans has no tabular figures, Hanken Grotesk's are tabular. */
@font-face { font-family: "Tabular"; src: url("../fonts/hanken-grotesk-var.woff2") format("woff2"); font-weight: 100 900; font-display: swap; unicode-range: U+30-39; }
@font-face { font-family: "Fragment Mono"; src: url("../fonts/fragment-mono-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }

:root {
  --font: "Albert Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Fragment Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --side: 232px;
  --pad: 40px;
  --n-base: #2f6fed; --n-arbitrum: #74aef5; --n-ethereum: #7b80d8; --n-polygon: #a474e2; --n-solana: #1ba79a; --n-bitcoin: #e0962c;
}
[data-theme="light"] {
  color-scheme: light;
  --canvas: #f5f6f7; --surface: #ffffff; --sunk: #f1f2f4; --sunk-2: #e9ebee;
  --ink: #0c0e12; --ink-2: #4a5260; --ink-3: #68707c; --ink-hover: #262a33; --on-ink: #ffffff;
  --line: #e4e7eb; --line-2: #d2d6dc;
  --accent: #2460cf; --accent-wash: #eaf0fb;
  --safe: #0b7a53; --safe-wash: #e5f4ed; --safe-fill: #0f8a5f;
  --wait: #9a5a00; --wait-wash: #fbf1df; --wait-fill: #c27a10;
  --stop: #c0301e; --stop-wash: #fbeae7; --stop-fill: #c93421;
  --float: 0 0 0 1px rgb(12 14 18 / .06), 0 2px 4px rgb(12 14 18 / .04), 0 16px 40px -8px rgb(12 14 18 / .18);
  --scrim: rgb(12 14 18 / .18);
}
[data-theme="dark"] {
  color-scheme: dark;
  --canvas: #0a0b0d; --surface: #111317; --sunk: #191c21; --sunk-2: #22262c;
  --ink: #eef0f4; --ink-2: #aab0ba; --ink-3: #8a919c; --ink-hover: #ffffff; --on-ink: #0a0b0d;
  --line: #22252b; --line-2: #31353d;
  --accent: #80b5ff; --accent-wash: #15223a;
  --safe: #52c79d; --safe-wash: #10261f; --safe-fill: #3fb88c;
  --wait: #e2a74e; --wait-wash: #2a2010; --wait-fill: #d99a3a;
  --stop: #f27a68; --stop-wash: #2e1512; --stop-fill: #ef6a57;
  --float: 0 0 0 1px rgb(255 255 255 / .07), 0 16px 48px -8px rgb(0 0 0 / .7);
  --scrim: rgb(0 0 0 / .5);
  --n-base: #5b8ff5; --n-arbitrum: #8fc0fa; --n-ethereum: #9599e6; --n-polygon: #b78cec; --n-solana: #3dbfb1; --n-bitcoin: #e8a742;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--surface); color: var(--ink); font: 400 14px/20px var(--font); letter-spacing: -0.003em; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; }
h1, h2, h3, p, dl, dd, ul, figure { margin: 0; }
ul { padding: 0; list-style: none; }
i, em { font-style: normal; }
b { font-weight: 600; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; color: inherit; letter-spacing: inherit; }
button { background: none; border: 0; padding: 0; cursor: pointer; -webkit-tap-highlight-color: transparent; }
a { -webkit-tap-highlight-color: transparent; }
svg { flex: none; }
hr { border: 0; border-top: 1px solid var(--line); margin: 0; }
[hidden] { display: none !important; }
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
::selection { background: var(--accent-wash); }
.skip { position: fixed; left: 12px; top: -60px; z-index: 300; padding: 8px 12px; border-radius: 8px; background: var(--ink); color: var(--on-ink); }
.skip:focus { top: 12px; }
.mono { font-family: var(--mono); font-size: 13px; letter-spacing: 0; }
.mute { color: var(--ink-3); }
.grow { flex: 1; }
.grow > .btn { width: 100%; }

/* Figures. In amount columns the digits come from a tabular set so the columns line up.
   Everywhere else digits keep Albert Sans and its natural spacing. */
.fig { white-space: nowrap; }
.fig var { font-style: normal; }
.tx-a .fig, .v-amt .fig, .h-a .fig, .vl-a .fig, .inv-a .fig, .cp-a .fig, .flag-amt .fig, .tab .fig { font-family: "Tabular", var(--font); }
.tok { display: inline-block; width: 36px; margin-left: 6px; text-align: left; color: var(--ink-3); font-size: 12px; font-weight: 400; letter-spacing: 0; }
.sg { display: inline-block; width: 1ch; text-align: center; }

/* ---------- shell ---------- */
.app { display: grid; grid-template-columns: var(--side) minmax(0, 1fr); min-height: 100dvh; }
.side { position: sticky; top: 0; height: 100dvh; display: flex; flex-direction: column; padding: 12px; background: var(--canvas); border-right: 1px solid var(--line); }
.org { display: flex; align-items: center; gap: 10px; height: 40px; padding: 0 8px; border-radius: 8px; width: 100%; text-align: left; color: var(--ink-3); }
.org:hover { background: var(--sunk-2); }
.org-mark { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 6px; background: var(--ink); color: var(--on-ink); flex: none; }
.org-mark .mark { width: 16px; height: 16px; }
.org-name { flex: 1; min-width: 0; font-weight: 600; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav { display: grid; gap: 2px; margin-top: 16px; }
.nav hr { margin: 10px 10px; }
.nav a { display: flex; align-items: center; gap: 10px; height: 34px; padding: 0 10px; border-radius: 8px; color: var(--ink-2); font-weight: 500; transition: background .12s, color .12s; }
.nav a .ic { color: var(--ink-3); transition: color .12s; }
.nav a:hover { background: var(--sunk-2); color: var(--ink); }
.nav a[aria-current] { background: var(--surface); color: var(--ink); box-shadow: 0 0 0 1px var(--line), 0 1px 2px rgb(12 14 18 / .04); }
.nav a[aria-current] .ic { color: var(--ink); }
.count { margin-left: auto; min-width: 20px; height: 20px; padding: 0 6px; display: grid; place-items: center; border-radius: 10px; background: var(--ink); color: var(--on-ink); font-size: 12px; font-weight: 600; letter-spacing: 0; }
.side-foot { margin-top: auto; display: grid; gap: 4px; }
.stopbtn { display: flex; align-items: center; gap: 10px; height: 34px; padding: 0 10px; border-radius: 8px; color: var(--ink-2); font-weight: 500; text-align: left; transition: background .12s, color .12s; }
.stopbtn .ic { color: var(--ink-3); }
.stopbtn:hover, .stopbtn[data-on] { background: var(--stop-wash); color: var(--stop); }
.stopbtn:hover .ic, .stopbtn[data-on] .ic { color: var(--stop); }
.me { display: flex; align-items: center; gap: 10px; height: 48px; padding: 0 8px; border-radius: 8px; text-align: left; margin-top: 4px; border-top: 1px solid var(--line); border-top-left-radius: 0; border-top-right-radius: 0; padding-top: 4px; }
.me:hover .me-t b { color: var(--accent); }
.me-t { display: grid; min-width: 0; }
.me-t b { font-size: 13px; line-height: 18px; }
.me-t i { font-size: 12px; line-height: 16px; color: var(--ink-3); }

.page { min-width: 0; background: var(--surface); }
.top { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 64px; padding: 0 var(--pad); background: var(--surface); }
.top.scrolled { box-shadow: 0 1px 0 var(--line); }
.top { transition: box-shadow .16s; }
.top-l { display: flex; align-items: center; gap: 12px; min-width: 0; }
.top h1 { font-size: 20px; line-height: 28px; font-weight: 600; letter-spacing: -0.015em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.crumb { display: inline-flex; align-items: center; gap: 2px; height: 32px; padding: 0 8px 0 4px; margin-left: -8px; border-radius: 8px; color: var(--ink-3); font-weight: 500; }
.crumb:hover { background: var(--sunk); color: var(--ink); }
.crumb + h1::before { content: "/"; margin-right: 12px; color: var(--line-2); font-weight: 400; }
.org-s { display: none; }
.top-r { display: flex; align-items: center; gap: 8px; flex: none; }
.find { display: flex; align-items: center; gap: 8px; width: 264px; height: 36px; padding: 0 8px 0 10px; border: 1px solid var(--line); border-radius: 8px; color: var(--ink-3); background: var(--canvas); text-align: left; transition: border-color .12s, background .12s; }
.find:hover { border-color: var(--line-2); }
.find span { flex: 1; }
kbd { font: 500 12px/18px var(--font); padding: 0 5px; border-radius: 4px; border: 1px solid var(--line-2); color: var(--ink-3); background: var(--surface); letter-spacing: 0; }
.main { padding: 8px var(--pad) 96px; max-width: 1200px; }
.main-narrow { max-width: 1040px; }
.tabs { display: none; }

.banner { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 0 var(--pad) 12px; max-width: 1120px; padding: 8px 8px 8px 14px; border-radius: 10px; background: var(--stop-wash); }
.banner p { display: flex; gap: 10px; align-items: flex-start; }
.banner .ic { color: var(--stop); margin-top: 1px; }
.banner b { color: var(--stop); }

/* ---------- buttons, chips, small parts ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 36px; padding: 0 14px; border-radius: 8px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink); font-weight: 500; white-space: nowrap; transition: background .12s, border-color .12s, transform .12s var(--ease), opacity .12s; }
.btn:hover { background: var(--sunk); }
.btn:active, .btn[data-pressed] { transform: scale(.975); }
.btn-p { background: var(--ink); border-color: var(--ink); color: var(--on-ink); font-weight: 600; }
.btn-p:hover { background: var(--ink-hover); border-color: var(--ink-hover); }
.btn-s { height: 32px; padding: 0 12px; font-size: 13px; gap: 6px; }
.btn-l { height: 44px; padding: 0 18px; font-size: 15px; border-radius: 10px; }
.btn-ghost { border-color: transparent; background: transparent; color: var(--ink-2); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .42; cursor: not-allowed; }
.btn:disabled:hover { background: var(--surface); }
.btn-p:disabled:hover { background: var(--ink); }
.btn .mk-load, .waiting .mk-load { width: 14px; height: 14px; }
.link { color: var(--accent); font-weight: 500; cursor: pointer; }
.link:hover { text-decoration: underline; text-underline-offset: 3px; }
.iconbtn { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 8px; color: var(--ink-2); }
.iconbtn:hover { background: var(--sunk); color: var(--ink); }

.chip { display: inline-flex; align-items: center; gap: 6px; height: 22px; padding: 0 8px; border-radius: 6px; background: var(--sunk); color: var(--ink-2); font-size: 12px; line-height: 22px; font-weight: 500; white-space: nowrap; letter-spacing: 0; vertical-align: middle; }
.chip::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.chip[data-tone="plain"]::before { display: none; }
.chip[data-tone="safe"] { background: var(--safe-wash); color: var(--safe); }
.chip[data-tone="wait"] { background: var(--wait-wash); color: var(--wait); }
.chip[data-tone="stop"] { background: var(--stop-wash); color: var(--stop); }

.av { display: inline-grid; place-items: center; width: var(--s, 24px); height: var(--s, 24px); border-radius: 50%; flex: none; background: var(--sunk-2); color: var(--ink-2); font-size: calc(var(--s, 24px) * .4); line-height: 1; font-weight: 600; letter-spacing: 0; }
.av[data-you] { background: var(--ink); color: var(--on-ink); }
.avs { display: inline-flex; }
.avs .av + .av { margin-left: -6px; box-shadow: 0 0 0 2px var(--surface); }

.meter { display: inline-flex; gap: 2px; }
.meter i { width: 10px; height: 6px; border-radius: 2px; background: var(--line-2); transition: background .3s; }
.meter i.on { background: var(--ink); }
.ap-w { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink-2); white-space: nowrap; }
.ap-w-l .meter i { width: 24px; height: 8px; }

[data-net="base"] { --n: var(--n-base); } [data-net="arbitrum"] { --n: var(--n-arbitrum); } [data-net="ethereum"] { --n: var(--n-ethereum); }
[data-net="polygon"] { --n: var(--n-polygon); } [data-net="solana"] { --n: var(--n-solana); } [data-net="bitcoin"] { --n: var(--n-bitcoin); }
.alloc { display: flex; gap: 2px; height: 6px; border-radius: 3px; overflow: hidden; }
.alloc i { min-width: 4px; background: var(--n); }
.netdot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--n); margin-right: 8px; }
.bar { display: block; height: 6px; border-radius: 3px; background: var(--sunk-2); overflow: hidden; }
.bar i { display: block; height: 100%; border-radius: 3px; background: var(--ink); }
.bar-wait i { background: var(--wait-fill); }

.waiting { display: inline-flex; align-items: center; gap: 8px; height: 32px; font-size: 13px; color: var(--ink-2); white-space: nowrap; }
.waiting-l { height: 44px; font-size: 15px; justify-content: center; width: 100%; }
.okline { display: inline-flex; align-items: center; gap: 6px; height: 32px; font-size: 13px; font-weight: 600; color: var(--safe); white-space: nowrap; }

.search { display: flex; align-items: center; gap: 8px; height: 36px; padding: 0 10px; border: 1px solid var(--line-2); border-radius: 8px; color: var(--ink-3); background: var(--surface); width: 320px; max-width: 100%; transition: border-color .12s, box-shadow .12s; }
.search-s { height: 32px; width: 280px; font-size: 13px; }
.search input { flex: 1; min-width: 0; border: 0; background: none; color: var(--ink); padding: 0; }
.search input::placeholder, .input::placeholder, .combo-in input::placeholder, .amount input::placeholder { color: var(--ink-3); opacity: 1; }
.search input::-webkit-search-cancel-button { display: none; }
.search:focus-within, .input:focus, .combo-in:focus-within, .amount:focus-within, .select select:focus-visible, .try-amt:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent); outline: none; }
.search input:focus-visible, .combo-in input:focus-visible, .amount input:focus-visible, .try-amt input:focus-visible { outline: none; }
.select { position: relative; display: inline-flex; align-items: center; }
.select select { appearance: none; -webkit-appearance: none; width: 100%; height: 44px; padding: 0 36px 0 12px; border: 1px solid var(--line-2); border-radius: 8px; background: var(--surface); font-size: 15px; cursor: pointer; text-overflow: ellipsis; }
.select .ic { position: absolute; right: 12px; pointer-events: none; color: var(--ink-3); }
.select-s select { height: 36px; font-size: 14px; padding-right: 32px; }
.select-s .ic { right: 10px; }
.seg { display: inline-flex; padding: 2px; border-radius: 8px; background: var(--sunk); gap: 2px; }
.seg button { height: 32px; padding: 0 12px; border-radius: 6px; color: var(--ink-2); font-weight: 500; font-size: 13px; white-space: nowrap; transition: background .12s, color .12s; }
.seg button:hover { color: var(--ink); }
.seg button[aria-selected="true"] { background: var(--surface); color: var(--ink); box-shadow: 0 0 0 1px var(--line), 0 1px 2px rgb(12 14 18 / .06); }
.input { height: 44px; padding: 0 12px; border: 1px solid var(--line-2); border-radius: 8px; background: var(--surface); font-size: 15px; width: 100%; transition: border-color .12s, box-shadow .12s; }
.input.mono { font-size: 13px; }

/* ---------- sections ---------- */
.lede { max-width: 72ch; font-size: 15px; line-height: 24px; color: var(--ink-2); padding: 4px 0 20px; text-wrap: pretty; }
.lede b { color: var(--ink); font-weight: 600; }
.sec { margin-top: 32px; padding-top: 28px; border-top: 1px solid var(--line); }
.sec-first { margin-top: 0; padding-top: 4px; border-top: 0; }
.sec-h { display: flex; align-items: center; justify-content: space-between; gap: 8px 16px; flex-wrap: wrap; margin-bottom: 8px; min-height: 32px; }
.sec-h h2 { display: flex; align-items: center; gap: 8px; font-size: 18px; line-height: 24px; font-weight: 600; letter-spacing: -0.012em; }
.sec-h .n { min-width: 22px; height: 22px; padding: 0 7px; display: inline-grid; place-items: center; border-radius: 11px; background: var(--sunk); color: var(--ink-2); font-size: 12px; font-weight: 600; letter-spacing: 0; }
.sec-note { font-size: 13px; color: var(--ink-3); }
.sec-p { max-width: 72ch; color: var(--ink-2); margin-bottom: 8px; text-wrap: pretty; }
.sec-foot { margin-top: 16px; font-size: 13px; color: var(--ink-2); }
.sec-foot .link { font-size: 13px; }
.sub { font-size: 14px; font-weight: 600; margin: 28px 0 4px; }
.empty { padding: 20px 0 8px; color: var(--ink-2); display: grid; gap: 4px; justify-items: start; }
.empty-t { color: var(--ink); font-weight: 600; }
.empty .btn { margin-top: 12px; }
.tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 4px 0 20px; }
.tools-end { margin-left: auto; }

/* ---------- home ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 1fr) 296px; gap: 64px; padding: 12px 0 8px; }
.hero-k { color: var(--ink-2); }
.hero-n { margin-top: 8px; font-size: 52px; line-height: 56px; font-weight: 500; letter-spacing: -0.03em; }
.hero-d { margin-top: 8px; height: 20px; color: var(--ink-2); }
.hero-d .up { color: var(--safe); font-weight: 600; }
.chart { position: relative; margin-top: 20px; touch-action: pan-y; cursor: crosshair; user-select: none; -webkit-user-select: none; }
.chart svg { display: block; width: 100%; height: 150px; overflow: visible; }
.c-line { fill: none; stroke: var(--ink); stroke-width: 1.75; vector-effect: non-scaling-stroke; stroke-linejoin: round; stroke-linecap: round; }
.c-area { fill: var(--ink); opacity: .035; }
.c-rule { position: absolute; top: 0; height: 150px; width: 1px; margin-left: -.5px; background: var(--line-2); opacity: 0; transition: opacity .12s; }
.chart.scrub .c-rule { opacity: 1; }
.c-dot { position: absolute; width: 9px; height: 9px; margin: -4.5px 0 0 -4.5px; border-radius: 50%; background: var(--ink); box-shadow: 0 0 0 3px var(--surface); transition: left .1s var(--ease), top .1s var(--ease); }
.c-x { display: flex; justify-content: space-between; margin-top: 10px; font-size: 12px; line-height: 16px; color: var(--ink-3); }
.hero-r { display: flex; flex-direction: column; }
.flow-n { display: flex; gap: 40px; margin-top: 12px; }
.flow-n p { display: flex; flex-wrap: wrap; align-items: center; column-gap: 8px; }
.flow-n span { font-size: 13px; color: var(--ink-2); }
.flow-n b { flex-basis: 100%; font-size: 24px; line-height: 32px; font-weight: 500; letter-spacing: -0.02em; margin-top: 2px; }
.sw { width: 8px; height: 8px; border-radius: 2px; }
.sw-in { background: var(--ink); }
.sw-out { background: var(--line-2); }
.flow { flex: 1; display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px; min-height: 132px; margin-top: 20px; }
.flow-d { display: flex; flex-direction: column; gap: 10px; }
.flow-b { flex: 1; display: flex; align-items: flex-end; justify-content: center; gap: 3px; border-bottom: 1px solid var(--line); }
.flow-b i { width: 9px; min-height: 2px; border-radius: 2px 2px 0 0; }
.flow-d span { font-size: 12px; line-height: 16px; color: var(--ink-3); text-align: center; }
.hero + .sec { margin-top: 28px; }

/* approvals as sentences */
.ap, .vrow, .tx[data-detail], .cp, .tm, .hrow { position: relative; }
.ap { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px 32px; align-items: center; margin: 0 -12px; padding: 16px 12px; border-radius: 10px; cursor: pointer; transition: background .12s; }
.ap::before, .vrow::before, .tx::before, .cp::before, .tm::before, .inv::before, .au::before, .agent::before, .pend::before, .flag::before { content: ""; position: absolute; left: 12px; right: 12px; top: 0; border-top: 1px solid var(--line); transition: opacity .12s; }
.ap:first-child::before, .vrows:not(.vrows-full) .vrow:first-child::before, .txs:not(.txs-full) > .tx:first-child::before, .pend:first-child::before, .flag:first-child::before { display: none; }
@media (hover: hover) {
  .ap:hover, .vrow:hover, .tx[data-detail]:hover, .cp:hover, .tm:hover { background: var(--sunk); }
  .ap:hover::before, .ap:hover + .ap::before, .vrow:hover::before, .vrow:hover + .vrow::before, .tx[data-detail]:hover::before, .tx[data-detail]:hover + .tx::before, .cp:hover::before, .cp:hover + .cp::before, .tm:hover::before, .tm:hover + .tm::before { opacity: 0; }
}
.ap-s { max-width: 70ch; font-size: 15px; line-height: 22px; color: var(--ink-2); text-wrap: pretty; }
.ap-s b { color: var(--ink); font-weight: 600; }
.ap-m { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; margin-top: 8px; font-size: 13px; color: var(--ink-3); }
.ap-side { display: flex; align-items: center; gap: 24px; }
.ap-act { display: flex; justify-content: flex-end; min-width: 88px; }
.ap-act.grow { min-width: 0; }

/* vault rows */
.vrow { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(170px, auto) 16px; gap: 32px; align-items: center; margin: 0 -12px; padding: 12px; min-height: 68px; border-radius: 10px; transition: background .12s; }
.vrows-full .vrow, .vhead { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, .9fr) minmax(170px, auto) 16px; }
.v-id { display: grid; grid-template-columns: auto 1fr; column-gap: 8px; align-items: center; min-width: 0; }
.v-id b { font-size: 15px; line-height: 22px; }
.v-id .chip { justify-self: start; }
.v-id i { grid-column: 1 / -1; font-size: 13px; color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.v-alloc { display: grid; gap: 8px; min-width: 0; }
.v-alloc > i { font-size: 12px; line-height: 16px; color: var(--ink-3); }
.v-rule { font-size: 13px; color: var(--ink-2); }
.v-amt { text-align: right; display: grid; }
.v-amt b { font-size: 15px; line-height: 22px; font-weight: 500; }
.v-amt i { font-size: 12px; color: var(--ink-3); }
.v-go { color: var(--line-2); transition: color .12s, transform .12s var(--ease); }
.vrow:hover .v-go { color: var(--ink-2); transform: translateX(2px); }
.vhead, .tx-head, .cp-head, .tm-head, .inv-head, .au-head, .vl-head { display: grid; gap: 32px; padding: 0 0 8px; font-size: 12px; line-height: 16px; font-weight: 500; color: var(--ink-3); }
.vhead span:nth-child(4), .tx-head span:last-child, .cp-head span:last-child, .tm-head span:last-child, .inv-head span:last-child, .vl-head span:last-child { text-align: right; }
.vhead span:nth-child(4) { padding-right: 0; }

/* ledger rows */
.tx { display: grid; grid-template-columns: 32px minmax(0, 1.5fr) minmax(0, .8fr) 124px minmax(160px, auto); gap: 16px; align-items: center; margin: 0 -12px; padding: 0 12px; min-height: 56px; border-radius: 10px; transition: background .12s; }
.tx[data-detail] { cursor: pointer; }
.tx:not(:has(.tx-v)) { grid-template-columns: 32px minmax(0, 1fr) 124px minmax(160px, auto); }
.tx-head { grid-template-columns: 32px minmax(0, 1.5fr) minmax(0, .8fr) 124px minmax(160px, auto); gap: 16px; }
.tx-ic { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--sunk); color: var(--ink-2); }
.tx[data-dir="in"] .tx-ic { background: var(--safe-wash); color: var(--safe); }
.tx-t { display: grid; min-width: 0; }
.tx-t b { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tx-t i { font-size: 13px; line-height: 18px; color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tx-v, .tx-w { font-size: 13px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tx-w { color: var(--ink-3); }
.tx-a { text-align: right; white-space: nowrap; font-weight: 500; }
.tx[data-dir="in"] .tx-n { color: var(--safe); }
.tx-day { padding: 20px 0 6px; font-size: 13px; font-weight: 600; color: var(--ink-2); }
.tx-day:first-child { padding-top: 4px; }
.tx-day + .tx::before { display: none; }
.txs-s .tx { grid-template-columns: 32px minmax(0, 1fr) auto; }
.txs-s .tx-w { display: none; }

/* ---------- vault page ---------- */
.vp-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; flex-wrap: wrap; padding: 12px 0 28px; }
.vp-k { display: flex; align-items: center; gap: 10px; color: var(--ink-2); }
.vp-n { margin-top: 8px; font-size: 44px; line-height: 48px; font-weight: 500; letter-spacing: -0.03em; }
.vp-n .v-bal, .vp-k .v-name { display: inline-block; }
.vp-p { margin-top: 8px; color: var(--ink-2); }
.vp-acts { display: flex; gap: 8px; }
.vp-grid { display: grid; grid-template-columns: minmax(0, 1fr) 304px; gap: 64px; border-top: 1px solid var(--line); padding-top: 28px; }
.hrow { display: grid; grid-template-columns: minmax(150px, .8fr) minmax(0, 1fr) 40px minmax(170px, auto); gap: 24px; align-items: center; min-height: 48px; border-top: 1px solid var(--line); }
.hrow:first-child { border-top: 0; }
.h-t b { font-weight: 500; margin-right: 6px; }
.h-t i { color: var(--ink-3); font-size: 13px; }
.h-bar { height: 6px; border-radius: 3px; background: var(--sunk); overflow: hidden; }
.h-bar i { display: block; height: 100%; border-radius: 3px; background: var(--n); }
.h-p { font-size: 13px; color: var(--ink-3); text-align: right; }
.h-a { text-align: right; font-weight: 500; white-space: nowrap; }
.vp-side { display: grid; gap: 28px; align-content: start; }
.vp-side h3 { font-size: 14px; font-weight: 600; margin-bottom: 8px; }
.vp-rule { color: var(--ink-2); margin-bottom: 8px; text-wrap: pretty; }
.vp-note { font-size: 13px; color: var(--ink-3); margin: 8px 0 12px; text-wrap: pretty; }
.people li { display: flex; align-items: center; gap: 12px; padding: 8px 0; }
.people li span { display: grid; min-width: 0; }
.people li span b { font-weight: 500; }
.people li span i { font-size: 13px; color: var(--ink-3); }
.people em { margin-left: auto; display: inline-flex; align-items: center; gap: 4px; font-size: 13px; color: var(--ink-3); white-space: nowrap; }
.people em.ok { color: var(--safe); font-weight: 500; }
.people-s li { padding: 5px 0; }
.copyline { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; height: 36px; padding: 0 10px 0 12px; border-radius: 8px; background: var(--sunk); color: var(--ink-2); transition: background .12s; }
.copyline:hover { background: var(--sunk-2); color: var(--ink); }
.copyline-s { width: auto; display: inline-flex; height: 28px; padding: 0 8px; margin: -4px 0; }

/* hold buttons */
.holdbtn { position: relative; display: block; width: 100%; height: 48px; border-radius: 10px; overflow: hidden; background: var(--ink); color: var(--on-ink); font-weight: 600; font-size: 15px; touch-action: none; user-select: none; -webkit-user-select: none; transition: transform .12s var(--ease); }
.holdbtn[data-holding] { transform: scale(.985); }
.hold-fill { position: absolute; inset: 0; transform-origin: left; transform: scaleX(var(--p, 0)); background: var(--safe-fill); }
.holdbtn[data-danger] .hold-fill { background: var(--stop-fill); }
.hold-label { position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 100%; }
.holdbtn.done { background: var(--safe-fill); }
.holdbtn-s { height: 40px; font-size: 14px; background: var(--surface); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line-2); }
.holdbtn-s .hold-fill { background: color-mix(in srgb, var(--accent) 22%, var(--surface)); }

/* ---------- payments ---------- */
.starts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; padding: 4px 0 0; max-width: 720px; }
.start { display: flex; align-items: center; gap: 14px; padding: 16px; border: 1px solid var(--line); border-radius: 10px; transition: border-color .12s, background .12s; }
.start:hover { border-color: var(--line-2); background: var(--canvas); }
.start-ic { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 10px; background: var(--ink); color: var(--on-ink); }
.start span:last-child { display: grid; }
.start b { font-size: 15px; line-height: 22px; }
.start i { font-size: 13px; color: var(--ink-3); }

.pay { display: grid; grid-template-columns: minmax(0, 480px) minmax(0, 344px); gap: 80px; padding-top: 12px; }
.field { display: grid; gap: 8px; margin-bottom: 24px; }
.field > span:first-child { font-size: 13px; line-height: 18px; font-weight: 500; color: var(--ink-2); }
.field > span:first-child i { color: var(--ink-3); font-weight: 400; margin-left: 4px; }
.field .select { display: flex; }
.hint { font-size: 13px; color: var(--ink-3); text-wrap: pretty; }
.hint[data-tone="wait"] { color: var(--wait); }
.hint[data-tone="stop"] { color: var(--stop); }
.combo { position: relative; }
.combo-in { display: flex; align-items: center; gap: 8px; height: 44px; padding: 0 12px; border: 1px solid var(--line-2); border-radius: 8px; color: var(--ink-3); transition: border-color .12s, box-shadow .12s; }
.combo-in input { flex: 1; min-width: 0; border: 0; background: none; color: var(--ink); font-size: 15px; padding: 0; height: 100%; }
.combo-list { position: absolute; z-index: 10; top: 50px; left: 0; right: 0; max-height: 320px; overflow: auto; padding: 4px; border-radius: 10px; background: var(--surface); box-shadow: var(--float); }
.opt { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; min-height: 48px; padding: 6px 10px; border-radius: 6px; text-align: left; }
.opt[aria-selected="true"] { background: var(--sunk); }
.opt-t { display: grid; min-width: 0; }
.opt-t b { font-weight: 500; }
.opt-t i { font-size: 13px; color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.opt-none { padding: 12px 10px; font-size: 13px; color: var(--ink-3); }
.picked { display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 8px 12px; border: 1px solid var(--line-2); border-radius: 8px; }
.picked-ic { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 8px; background: var(--sunk); color: var(--ink-2); }
.picked-t { display: grid; flex: 1; min-width: 0; }
.picked-t b { font-size: 15px; font-weight: 500; }
.picked-t i { font-size: 13px; color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.amount { display: flex; align-items: center; gap: 8px; height: 64px; padding: 0 8px 0 14px; border: 1px solid var(--line-2); border-radius: 8px; transition: border-color .12s, box-shadow .12s; }
.amount input { flex: 1; min-width: 0; height: 100%; border: 0; background: none; padding: 0; font-size: 28px; font-weight: 500; letter-spacing: -0.02em; }
.select-in select { height: 40px; border: 0; background: var(--sunk); border-radius: 6px; font-size: 14px; font-weight: 500; padding-right: 32px; }
.select-in .ic { right: 10px; }
.pay-go { margin-top: 8px; }
.pay-go .btn { min-width: 200px; }
.pay-go-2 { display: flex; gap: 8px; margin-top: 28px; }
.pay-go-2 > .btn { min-width: 0; }
.pay-sum { align-self: start; position: sticky; top: 88px; padding-left: 32px; border-left: 1px solid var(--line); }
.pay-sum h2 { font-size: 14px; font-weight: 600; margin-bottom: 12px; }
.rule-line { display: flex; gap: 10px; padding: 12px; border-radius: 10px; background: var(--sunk); color: var(--ink-2); text-wrap: pretty; }
.rule-line .ic { margin-top: 1px; }
.rule-line[data-tone="safe"] { background: var(--safe-wash); color: var(--safe); }
.rule-line[data-tone="wait"] { background: var(--wait-wash); color: var(--wait); }
.rule-line[data-tone="stop"] { background: var(--stop-wash); color: var(--stop); }
.rule-line span { color: var(--ink); }
.kv > div { display: grid; grid-template-columns: 116px minmax(0, 1fr); gap: 16px; padding: 10px 0; border-top: 1px solid var(--line); }
.kv > div:first-child { border-top: 0; }
.kv dt { font-size: 13px; color: var(--ink-3); }
.kv dd { min-width: 0; overflow-wrap: anywhere; }
.kv dd > i { display: block; font-size: 13px; color: var(--ink-3); margin-top: 2px; }
.kv-line { display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.kv-av { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.kv-tight { margin-top: 12px; }
.kv-tight > div { grid-template-columns: 124px minmax(0, 1fr); }
.kv-tight > div:first-child { border-top: 0; }
.review { max-width: 480px; }
.rv-k { color: var(--ink-2); }
.rv-n { margin-top: 8px; font-size: 44px; line-height: 48px; font-weight: 500; letter-spacing: -0.03em; }
.rv-n .tok { font-size: 18px; width: auto; margin-left: 10px; }
.rv-to { margin-top: 12px; font-size: 16px; line-height: 24px; color: var(--ink-2); }
.rv-to b { color: var(--ink); }
.rv-addr { margin: 20px 0 12px; padding: 14px 16px; border-radius: 10px; background: var(--sunk); }
.rv-addr p { margin-top: 8px; font-size: 13px; color: var(--ink-3); }
.addr { display: grid; grid-template-columns: repeat(5, max-content); gap: 2px 12px; font-family: var(--mono); font-size: 13px; line-height: 20px; letter-spacing: 0; }
.addr i:nth-child(even) { color: var(--ink-3); }
.stage { display: grid; justify-items: center; text-align: center; max-width: 480px; margin: 0 auto; padding: 40px 0 0; }
.stage-field { width: 208px; height: 208px; color: var(--ink); }
.stage h2 { margin-top: 12px; font-size: 24px; line-height: 32px; font-weight: 600; letter-spacing: -0.02em; }
.stage > p { margin-top: 4px; font-size: 15px; line-height: 24px; color: var(--ink-2); max-width: 44ch; text-wrap: pretty; }
.stage-more { width: 100%; margin-top: 28px; animation: rise .32s var(--ease) both; }
.stage-more .kv { text-align: left; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-top: 0; }
.stage-acts { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.stage-ok { display: grid; place-items: center; width: 64px; height: 64px; margin-top: 40px; border-radius: 50%; background: var(--safe-wash); color: var(--safe); }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } }

/* ---------- batch ---------- */
.drop { display: grid; justify-items: center; gap: 8px; margin-top: 12px; padding: 72px 24px; border: 1.5px dashed var(--line-2); border-radius: 14px; text-align: center; transition: border-color .12s, background .12s; }
.drop.over { border-color: var(--accent); background: var(--accent-wash); }
.drop-ic { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 12px; background: var(--sunk); color: var(--ink-2); margin-bottom: 8px; }
.drop h2 { font-size: 20px; line-height: 28px; font-weight: 600; letter-spacing: -0.015em; }
.drop p { max-width: 52ch; color: var(--ink-2); text-wrap: pretty; }
.drop-acts { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin-top: 16px; min-height: 44px; }
.b-stats { display: grid; grid-template-columns: 1fr 1.3fr 1.5fr 1fr; gap: 0; padding: 8px 0 4px; }
.b-stats-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.b-stats > div { display: grid; align-content: start; gap: 4px; padding: 0 24px; border-left: 1px solid var(--line); }
.b-stats > div:first-child { padding-left: 0; border-left: 0; }
.b-stats span { font-size: 13px; color: var(--ink-2); }
.b-stats b { font-size: 24px; line-height: 32px; font-weight: 500; letter-spacing: -0.02em; white-space: nowrap; }
.b-stats b .tok { font-size: 13px; width: auto; }
.b-stats i { font-size: 13px; color: var(--ink-3); }
.b-stats b span { font-size: inherit; color: inherit; }
.flag { position: relative; padding: 16px 0; }
.flag-top { display: grid; grid-template-columns: 80px auto minmax(0, 1fr) minmax(150px, auto); gap: 16px; align-items: baseline; }
.flag::before, .pend::before { left: 0; right: 0; }
.flag-n { font-size: 13px; color: var(--ink-3); }
.flag-top b { font-weight: 500; }
.flag-a { color: var(--ink-2); }
.flag-amt { text-align: right; font-weight: 500; white-space: nowrap; }
.flag-why { display: flex; gap: 8px; align-items: flex-start; margin: 8px 0 12px 96px; color: var(--ink); }
.flag-why .ic { color: var(--wait-fill); margin-top: 1px; }
.flag-acts { display: flex; gap: 8px; flex-wrap: wrap; margin-left: 96px; }
.flag-done { display: flex; align-items: center; gap: 10px; padding: 12px 0; color: var(--ink-2); }
.flag-done .ic { color: var(--safe); }
.flag-done p { flex: 1; }
.flag-done b { font-weight: 500; color: var(--ink); }
.vl-head, .vl-row { grid-template-columns: 64px minmax(0, 1.2fr) 132px minmax(0, 1fr) 120px; gap: 16px; }
.vl-head { padding: 12px 0 8px; border-bottom: 1px solid var(--line); }
.vl { position: relative; height: min(440px, 56vh); overflow: auto; overscroll-behavior: contain; border-bottom: 1px solid var(--line); }
.vl-space { position: relative; }
.vl-win { position: absolute; left: 0; right: 0; top: 0; will-change: transform; }
.vl-row { display: grid; align-items: center; height: 44px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.vl-row > span { overflow: hidden; text-overflow: ellipsis; }
.vl-row > span:first-child { font-size: 13px; color: var(--ink-3); }
.vl-row .mono { color: var(--ink-2); }
.vl-n { font-size: 13px; color: var(--ink-2); }
.vl-a { text-align: right; font-weight: 500; }
.vl-row.off { color: var(--ink-3); }
.vl-row.off .vl-s { text-decoration: line-through; }
.vl-row.off .vl-a { font-weight: 400; }
.vl-row.flagd > span:first-child { color: var(--wait); font-weight: 600; }
.vl-none { padding: 20px 0; color: var(--ink-3); }
.b-bar { position: sticky; bottom: 0; z-index: 5; display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 24px; padding: 16px 0; background: var(--surface); border-top: 1px solid var(--line); }
.b-bar p { color: var(--ink-2); }
.b-bar b { color: var(--ink); }
.b-bar #b-act { min-width: 280px; display: flex; justify-content: flex-end; }

/* ---------- counterparties, team, deposits, automation, audit ---------- */
.cp, .cp-head { display: grid; grid-template-columns: minmax(0, 1.4fr) 150px 140px minmax(170px, auto); gap: 32px; align-items: center; }
.cp, .tm { margin: 0 -12px; padding: 0 12px; min-height: 60px; border-radius: 10px; cursor: pointer; transition: background .12s; }
.cp-n, .tm-p > span { display: grid; min-width: 0; }
.cp-n b, .tm-p b { font-weight: 500; }
.cp-n i, .tm-p i { font-size: 13px; color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cp-net { font-size: 13px; color: var(--ink-2); }
.cp-a { text-align: right; font-weight: 500; white-space: nowrap; }
.tm, .tm-head { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) 120px 90px; gap: 32px; align-items: center; }
.tm-p { display: flex; align-items: center; gap: 12px; min-width: 0; }
.tm-d, .tm-l { font-size: 13px; color: var(--ink-2); }
.tm-w { display: flex; align-items: center; justify-content: flex-end; gap: 8px; font-weight: 500; }
.wt { display: inline-flex; gap: 2px; }
.wt i { width: 10px; height: 6px; border-radius: 2px; background: var(--line-2); }
.wt i.on { background: var(--ink); }
.inv, .inv-head { position: relative; display: grid; grid-template-columns: 104px minmax(0, 1.3fr) minmax(0, 1fr) 100px minmax(160px, auto); gap: 24px; align-items: center; }
.inv { min-height: 56px; }
.invs .inv:first-child::before, .tms .tm:first-child::before, .cps .cp:first-child::before, .aus .au:first-child::before { display: block; }
.inv::before, .au::before, .agent::before { left: 0; right: 0; }
.inv-id { font-size: 13px; color: var(--ink-2); }
.inv-c { display: grid; min-width: 0; }
.inv-c b { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.inv-c i { font-size: 13px; color: var(--ink-3); }
.inv-short { margin-left: 8px; font-size: 13px; color: var(--wait); }
.inv-w { font-size: 13px; color: var(--ink-3); }
.inv-a { text-align: right; font-weight: 500; white-space: nowrap; }
.limits { display: grid; grid-template-columns: 1.4fr 1fr 1.4fr; gap: 0; margin-top: 16px; }
.limits > div { display: grid; gap: 10px; align-content: start; padding: 0 24px; border-left: 1px solid var(--line); }
.limits > div:first-child { padding-left: 0; border-left: 0; }
.limits p { display: grid; gap: 2px; }
.limits span { font-size: 13px; color: var(--ink-2); }
.limits b { font-size: 16px; line-height: 24px; font-weight: 500; white-space: nowrap; }
.limits b .tok, .limits b .fig { font-size: inherit; color: inherit; }
.limits b .tok { font-size: 12px; color: var(--ink-3); width: auto; }
.sec-h h2 .chip { margin-left: 4px; }
.agent { position: relative; display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1.2fr) 120px 84px; gap: 24px; align-items: center; min-height: 64px; }
.agents .agent:first-child::before { display: none; }
.ag-n { display: grid; min-width: 0; }
.ag-n b { font-weight: 500; }
.ag-n i { font-size: 13px; color: var(--ink-3); }
.ag-l { font-size: 13px; color: var(--ink-2); }
.ag-b { display: grid; gap: 6px; }
.ag-bt { font-size: 13px; color: var(--ink-2); }
.agent .btn { justify-self: end; }
.au, .au-head { position: relative; display: grid; grid-template-columns: 88px 200px minmax(0, 1fr) minmax(0, 1.4fr); gap: 24px; align-items: center; }
.au { min-height: 48px; }
.au-w { font-size: 13px; color: var(--ink-3); }
.au-p { display: flex; align-items: center; gap: 10px; min-width: 0; }
.au-p b { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.au-d { color: var(--ink-2); }
.more { display: grid; margin-top: 4px; }
.more + .more { margin-top: 24px; border-top: 1px solid var(--line); }
.more > * { display: flex; align-items: center; gap: 14px; min-height: 64px; border-top: 1px solid var(--line); text-align: left; width: 100%; }
.more > *:first-child { border-top: 0; }
.more > * > .ic:first-child { color: var(--ink-2); }
.more > * > .ic:last-child { color: var(--line-2); }
.more span { flex: 1; display: grid; }
.more b { font-size: 15px; font-weight: 500; }
.more i { font-size: 13px; color: var(--ink-3); }
.more-stop b, .more-stop > .ic:first-child { color: var(--stop); }

/* ---------- rules ---------- */
.rules .rule { padding: 24px 0; border-top: 1px solid var(--line); }
.rules .rule:first-child { border-top: 0; padding-top: 4px; }
.rule h2 { font-size: 15px; line-height: 22px; font-weight: 600; }
.rule-s { margin-top: 8px; max-width: 36em; font-size: 22px; line-height: 34px; letter-spacing: -0.015em; text-wrap: pretty; }
.tokn { display: inline; padding: 1px 3px; margin: 0 -1px; border-radius: 5px; font-weight: 600; text-decoration: underline dotted var(--ink-3); text-decoration-thickness: 1.5px; text-underline-offset: 5px; transition: background .12s, color .12s; }
.tokn:hover, .tokn[data-pop-anchor]:has(~ *), .tokn:focus-visible { background: var(--accent-wash); color: var(--accent); text-decoration-color: var(--accent); }
.tokn.busy { color: var(--ink-3); text-decoration: none; }
.tokn .mk-load { display: inline-block; vertical-align: -1px; margin-right: 6px; }
.pend { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px 32px; align-items: center; padding: 16px 0; }
.pend-s { font-size: 15px; line-height: 22px; }
.pend-s s { color: var(--ink-3); }
.pend-m { margin-top: 4px; font-size: 13px; color: var(--ink-2); }
.pend-m b { color: var(--ink); font-weight: 600; }
.pend .bar { margin-top: 12px; max-width: 360px; }
.pend-side { display: flex; align-items: center; gap: 24px; }
.try { display: grid; gap: 12px; max-width: 760px; margin-top: 12px; }
.try-in { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.try-in .select select { height: 36px; font-size: 14px; }
.try-amt { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 10px; border: 1px solid var(--line-2); border-radius: 8px; transition: border-color .12s, box-shadow .12s; }
.try-amt input { width: 104px; border: 0; background: none; padding: 0; font-weight: 500; text-align: right; }
.try-amt span { font-size: 12px; color: var(--ink-3); }
.cases li { display: flex; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); }
.cases li:first-child { border-top: 0; }
.cases .ic { color: var(--safe); margin-top: 1px; }
.cases span { display: grid; }
.cases b { font-weight: 500; }
.cases i { color: var(--ink-2); font-size: 13px; }
.lint { margin-top: 16px; padding-left: 18px; list-style: disc; color: var(--ink-3); font-size: 13px; display: grid; gap: 4px; }
.edit { display: grid; gap: 12px; padding: 12px; }
.edit label { display: grid; gap: 8px; }
.edit label span { font-size: 13px; font-weight: 500; color: var(--ink-2); }
.edit .input { height: 40px; }
.edit p { font-size: 13px; color: var(--ink-3); text-wrap: pretty; }
.edit div { display: flex; justify-content: flex-end; gap: 8px; }

/* ---------- layers ---------- */
.layer { position: fixed; inset: 0; z-index: 60; }
.scrim { position: absolute; inset: 0; background: var(--scrim); opacity: 0; transition: opacity .2s; }
.layer.in .scrim { opacity: 1; }
.layer.out .scrim { opacity: 0; }
.layer-drawer .scrim { background: color-mix(in srgb, var(--scrim) 55%, transparent); }
.drawer { position: absolute; top: 0; right: 0; bottom: 0; width: min(464px, 100vw); display: flex; flex-direction: column; background: var(--surface); box-shadow: var(--float); }
.grab { display: none; }
.drawer:focus-visible, .dialog:focus-visible { outline: none; }
.dr-h { padding: 16px 24px 20px; }
.dr-top { display: flex; align-items: center; justify-content: space-between; margin: 0 -8px 16px 0; min-height: 32px; }
.dr-h h2 { font-size: 20px; line-height: 28px; font-weight: 600; letter-spacing: -0.015em; }
.dr-amt { margin-top: 4px; font-size: 32px; line-height: 40px; font-weight: 500; letter-spacing: -0.025em; }
.dr-amt .tok { font-size: 15px; width: auto; margin-left: 8px; }
.dr-change { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 8px; font-size: 24px; line-height: 32px; font-weight: 500; letter-spacing: -0.02em; }
.dr-change s { color: var(--ink-3); }
.dr-change .ic { color: var(--ink-3); }
.dr-change span { font-size: 14px; color: var(--ink-2); font-weight: 400; letter-spacing: 0; }
.dr-s { margin-top: 8px; color: var(--ink-2); text-wrap: pretty; }
.dr-s b { color: var(--ink); }
.dr-person { display: flex; align-items: center; gap: 14px; }
.dr-person .dr-s { margin-top: 0; }
.dr-b { flex: 1; overflow: auto; padding: 4px 24px 24px; border-top: 1px solid var(--line); }
.dr-b h3 { margin: 24px 0 8px; font-size: 14px; font-weight: 600; }
.dr-b > .kv:first-child { margin-top: 4px; }
.flags { display: grid; gap: 8px; margin-top: 16px; }
.flags p { display: flex; gap: 10px; padding: 10px 12px; border-radius: 8px; background: var(--sunk); color: var(--ink-2); font-size: 13px; line-height: 20px; }
.flags p span { color: var(--ink); }
.flags p[data-tone="wait"] { background: var(--wait-wash); color: var(--wait); }
.flags p[data-tone="stop"] { background: var(--stop-wash); color: var(--stop); }
.dr-f { display: flex; gap: 8px; padding: 16px 24px; border-top: 1px solid var(--line); }
.dr-state { color: var(--ink-2); padding: 12px 0; }
.dialog { position: absolute; left: 50%; top: 50%; translate: -50% -50%; width: min(440px, calc(100vw - 32px)); max-height: calc(100dvh - 48px); overflow: auto; border-radius: 14px; background: var(--surface); box-shadow: var(--float); }
.dialog.cmd { top: 14vh; translate: -50% 0; width: min(600px, calc(100vw - 32px)); overflow: hidden; display: flex; flex-direction: column; max-height: min(520px, 72vh); }
.cmd-in { flex: none; display: flex; align-items: center; gap: 10px; height: 52px; padding: 0 16px; border-bottom: 1px solid var(--line); color: var(--ink-3); }
.cmd-in input { flex: 1; min-width: 0; height: 100%; border: 0; background: none; font-size: 16px; color: var(--ink); }
.cmd-in input:focus-visible { outline: none; }
.cmd-list { overflow: auto; padding: 4px 8px 8px; }
.cmd-g { padding: 12px 8px 4px; font-size: 12px; font-weight: 500; color: var(--ink-3); }
.cmd-it { display: flex; align-items: center; gap: 12px; width: 100%; height: 40px; padding: 0 8px; border-radius: 8px; text-align: left; color: var(--ink); }
.cmd-it .ic { color: var(--ink-3); }
.cmd-it span { flex: none; font-weight: 500; }
.cmd-it i { margin-left: auto; font-size: 13px; color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.cmd-it[aria-selected="true"] { background: var(--sunk); }
.cmd-it[aria-selected="true"] .ic { color: var(--ink); }
.cmd-none { padding: 24px 8px; color: var(--ink-3); }
.form { display: grid; padding: 24px; }
.form h2 { font-size: 20px; line-height: 28px; font-weight: 600; letter-spacing: -0.015em; }
.form-p { margin: 4px 0 20px; color: var(--ink-2); text-wrap: pretty; }
.form .field { margin-bottom: 16px; }
.form-acts { display: flex; justify-content: flex-end; gap: 8px; margin-top: 8px; }
.stop { display: grid; justify-items: center; text-align: center; padding: 28px 28px 24px; }
.stop-field { width: 176px; height: 176px; color: var(--ink); }
.stop h2 { margin-top: 12px; font-size: 20px; line-height: 28px; font-weight: 600; letter-spacing: -0.015em; }
.stop > p { margin-top: 8px; max-width: 36ch; color: var(--ink-2); text-wrap: pretty; }
.stop-rule { display: inline-flex; align-items: center; gap: 8px; color: var(--ink) !important; font-weight: 500; }
.stop-acts { display: grid; gap: 8px; width: 100%; margin-top: 24px; }
.stop-acts .btn { width: 100%; }

.pop { position: fixed; z-index: 80; min-width: 200px; border-radius: 12px; background: var(--surface); box-shadow: var(--float); opacity: 0; transform: translateY(-4px) scale(.98); transform-origin: top left; transition: opacity .12s, transform .16s var(--ease); }
.pop.in { opacity: 1; transform: none; }
.menu { padding: 6px; display: grid; gap: 2px; }
.menu hr { margin: 4px 0; }
.menu-cur { display: flex; align-items: center; gap: 10px; padding: 8px; }
.menu-cur > span:nth-child(2) { display: grid; flex: 1; min-width: 0; }
.menu-cur i { font-size: 12px; color: var(--ink-3); }
.menu-cur > .ic { color: var(--ink-2); }
.menu-it { display: flex; align-items: center; gap: 10px; height: 36px; padding: 0 8px; border-radius: 8px; width: 100%; text-align: left; font-weight: 500; color: var(--ink); }
.menu-it .ic { color: var(--ink-3); }
.menu-it:hover { background: var(--sunk); }

#toasts { position: fixed; z-index: 120; left: calc(var(--side) + (100vw - var(--side)) / 2); bottom: 24px; transform: translateX(-50%); display: grid; gap: 8px; justify-items: center; pointer-events: none; width: max-content; max-width: calc(100vw - 32px); }
.toast { display: flex; align-items: center; gap: 16px; max-width: 520px; padding: 10px 14px; border-radius: 10px; background: var(--ink); color: var(--on-ink); font-weight: 500; box-shadow: 0 8px 24px -8px rgb(0 0 0 / .4); pointer-events: auto; animation: toast-in .24s var(--ease) both; }
.toast button { font-weight: 600; text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }
.toast.out { opacity: 0; transform: translateY(4px); transition: opacity .18s, transform .18s; }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px) scale(.98); } }

/* ---------- the stand-in phone ---------- */
.phone { position: fixed; z-index: 100; right: 24px; bottom: 24px; width: 300px; padding: 6px 6px 0; border-radius: 34px; background: #0c0e12; box-shadow: 0 0 0 1px rgb(255 255 255 / .1), 0 24px 64px -12px rgb(0 0 0 / .45); opacity: 0; transform: translateY(24px); transition: opacity .2s, transform .32s var(--ease); }
.phone.in { opacity: 1; transform: none; }
.ph-screen { padding: 12px 16px 16px; border-radius: 28px; background: var(--surface); }
.ph-top { display: flex; align-items: center; justify-content: space-between; margin: 0 -6px 12px 0; font-size: 12px; color: var(--ink-3); }
.ph-top span { display: inline-flex; align-items: center; gap: 6px; }
.ph-x { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; color: var(--ink-2); }
.ph-x:hover { background: var(--sunk); }
.ph-app { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; }
.ph-title { margin-top: 12px; font-size: 15px; line-height: 22px; font-weight: 500; color: var(--ink-2); }
.ph-amt { margin-top: 2px; font-size: 26px; line-height: 32px; font-weight: 600; letter-spacing: -0.025em; }
.ph-rows { margin: 12px 0 16px; }
.ph-rows > div { display: flex; justify-content: space-between; gap: 16px; padding: 7px 0; border-top: 1px solid var(--line); font-size: 13px; }
.ph-rows dt { color: var(--ink-3); }
.ph-rows dd { text-align: right; font-weight: 500; }
.ph-note { padding: 8px 0 10px; text-align: center; font-size: 12px; color: #9aa1ac; }
.ph-face { display: grid; justify-items: center; gap: 6px; height: 56px; align-content: center; font-size: 12px; color: var(--ink-2); transition: color .2s; }
.ph-face .ic { animation: face .64s var(--ease) both; }
.ph-face.ok { color: var(--safe); }
@keyframes face { 0% { opacity: 0; transform: scale(.8); } 40% { opacity: 1; transform: scale(1.06); } 100% { transform: scale(1); } }
.ph-sheet { padding: 8px 20px 12px; }
.ph-sheet .ph-amt { font-size: 32px; line-height: 40px; }
.ph-sheet .holdbtn { height: 56px; border-radius: 14px; font-size: 16px; }
.ph-sheet .ph-face { height: 56px; }
.ph-cancel { width: 100%; margin-top: 4px; height: 44px; }

/* ---------- opening ---------- */
.opening { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; align-content: center; gap: 20px; background: var(--surface); color: var(--ink); transition: opacity .3s; }
.opening.out { opacity: 0; pointer-events: none; }
.open-field { width: 200px; height: 200px; }
.open-lock { opacity: 0; transform: translateY(6px); transition: opacity .4s .5s, transform .5s .5s var(--ease); }
.opening.in .open-lock { opacity: 1; transform: none; }
.open-lock svg { display: block; height: 28px; width: auto; }

/* ---------- view transitions ---------- */
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .16s; animation-timing-function: ease; }
::view-transition-group(vault-name), ::view-transition-group(vault-bal) { animation-duration: .28s; animation-timing-function: var(--ease); }

/* ---------- narrower desktop ---------- */
@media (max-width: 1180px) {
  :root { --pad: 28px; }
  .hero { grid-template-columns: minmax(0, 1fr) 260px; gap: 40px; }
  .pay { gap: 48px; }
  .vp-grid { gap: 40px; grid-template-columns: minmax(0, 1fr) 272px; }
  .find { width: 200px; }
}
@media (max-width: 980px) {
  :root { --side: 200px; }
  .hero, .vp-grid, .pay { grid-template-columns: minmax(0, 1fr); }
  .pay-sum { position: static; padding: 24px 0 0; border-left: 0; border-top: 1px solid var(--line); }
  .v-rule, .vhead { display: none; }
  .vrows-full .vrow { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(170px, auto) 16px; }
  .tx, .tx-head { grid-template-columns: 32px minmax(0, 1fr) 110px minmax(150px, auto); }
  .tx-v, .tx-head span:nth-child(3) { display: none; }
}

/* ---------- phone ---------- */
@media (max-width: 760px) {
  :root { --pad: 16px; }
  body { font-size: 15px; line-height: 22px; }
  .app { display: block; padding-bottom: calc(64px + env(safe-area-inset-bottom)); }
  .side { display: none; }
  .top { height: 56px; }
  .top h1 { font-size: 18px; line-height: 24px; }
  .org-s { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 8px; background: var(--ink); color: var(--on-ink); flex: none; }
  .crumb span { display: none; }
  .crumb { margin-left: -4px; padding: 0 4px; height: 40px; }
  .crumb + h1::before { display: none; }
  .org-s:has(+ .crumb) { display: none; }
  .find { width: 40px; height: 40px; padding: 0; justify-content: center; border-color: transparent; background: none; color: var(--ink); }
  .find span, .find kbd { display: none; }
  .top .btn-p { height: 40px; padding: 0 14px; }
  .main { padding: 4px var(--pad) 32px; }
  .banner { flex-direction: column; align-items: stretch; margin-bottom: 8px; padding: 12px; }
  .tabs { position: fixed; z-index: 40; left: 0; right: 0; bottom: 0; display: grid; grid-template-columns: repeat(5, 1fr); height: calc(60px + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); background: var(--surface); border-top: 1px solid var(--line); }
  .tabs a { position: relative; display: grid; justify-items: center; align-content: center; gap: 3px; color: var(--ink-3); font-size: 11px; line-height: 14px; font-weight: 500; letter-spacing: 0; }
  .tabs a[aria-current] { color: var(--ink); font-weight: 600; }
  .tabs a[data-pressed] .ic { transform: scale(.9); }
  .tabs .ic { transition: transform .12s var(--ease); }
  .tabs .count { position: absolute; top: 6px; left: calc(50% + 4px); min-width: 16px; height: 16px; padding: 0 4px; font-size: 10px; box-shadow: 0 0 0 2px var(--surface); }
  .btn { height: 44px; padding: 0 16px; font-size: 15px; }
  .btn-s { height: 40px; font-size: 14px; padding: 0 14px; }
  .btn-l { height: 52px; font-size: 16px; }
  .iconbtn { width: 40px; height: 40px; }
  .seg button { height: 36px; }
  .search, .search-s { height: 44px; width: 100%; font-size: 16px; }
  .input, .select select, .combo-in { height: 48px; font-size: 16px; }
  .combo-in input, .search input, .cmd-in input { font-size: 16px; }
  .combo-list { top: 54px; }
  .lede { font-size: 15px; padding-bottom: 12px; }
  .sec { margin-top: 28px; padding-top: 24px; }
  .hero { gap: 28px; padding-top: 8px; }
  .hero-n { font-size: 38px; line-height: 44px; }
  .chart svg, .c-rule { height: 120px; }
  .flow { min-height: 104px; }
  .ap { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .ap-side { justify-content: space-between; }
  .ap-s { font-size: 16px; line-height: 24px; }
  .ap-act .btn { min-width: 112px; }
  .vrow, .vrows-full .vrow { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "id amt" "al al"; gap: 10px 16px; padding: 14px 12px; }
  .v-id { grid-area: id; } .v-amt { grid-area: amt; } .v-alloc { grid-area: al; grid-template-columns: 1fr; }
  .v-go { display: none; }
  .tx, .tx:not(:has(.tx-v)), .txs-s .tx { grid-template-columns: 36px minmax(0, 1fr) auto; grid-template-areas: "ic t a" "ic t w"; gap: 0 12px; min-height: 64px; padding: 10px 12px; }
  .tx-ic { grid-area: ic; width: 36px; height: 36px; } .tx-t { grid-area: t; } .tx-a { grid-area: a; align-self: end; } .tx-w { grid-area: w; display: block !important; text-align: right; align-self: start; font-size: 12px; }
  .tx-v, .tx-head, .cp-head, .tm-head, .inv-head, .au-head, .vl-head { display: none; }
  .tx .tok { width: auto; }
  .tools { gap: 8px; }
  .tools .seg { order: 3; width: 100%; overflow-x: auto; scrollbar-width: none; }
  .tools .seg button { flex: 1; }
  .tools .select { flex: 1; }
  .tools-end { margin-left: 0; }
  .vp-head { align-items: stretch; flex-direction: column; padding-bottom: 20px; }
  .vp-n { font-size: 36px; line-height: 44px; }
  .vp-acts .btn { flex: 1; }
  .vp-grid { gap: 28px; padding-top: 20px; }
  .hrow { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "t a" "b p"; gap: 6px 16px; padding: 12px 0; }
  .h-t { grid-area: t; } .h-a { grid-area: a; } .h-bar { grid-area: b; } .h-p { grid-area: p; }
  .starts { grid-template-columns: 1fr; }
  .pay { gap: 0; padding-top: 4px; }
  .amount { height: 72px; }
  .amount input { font-size: 30px; }
  .pay-go .btn, .pay-go-2 .grow { width: 100%; }
  .rv-n { font-size: 36px; line-height: 44px; }
  .stage { padding-top: 16px; }
  .stage-acts { display: grid; width: 100%; }
  .b-stats, .b-stats-4, .limits { grid-template-columns: 1fr 1fr; gap: 20px 0; }
  .b-stats > div:nth-child(odd), .limits > div:nth-child(odd) { padding-left: 0; border-left: 0; }
  .b-stats > div, .limits > div { padding-right: 0; padding-left: 16px; }
  .limits { grid-template-columns: 1fr; }
  .limits > div { padding-left: 0; border-left: 0; }
  .b-stats b { font-size: 20px; line-height: 28px; }
  .flag-top { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "s amt" "n a"; gap: 2px 12px; }
  .flag-top b { grid-area: s; } .flag-n { grid-area: n; } .flag-a { grid-area: a; text-align: right; } .flag-amt { grid-area: amt; }
  .flag-why, .flag-acts { margin-left: 0; }
  .flag-acts .btn { flex: 1; white-space: normal; height: auto; min-height: 40px; padding: 8px 12px; line-height: 18px; }
  .vl-row { grid-template-columns: 52px minmax(0, 1fr) auto; }
  .vl-row .mono, .vl-n { display: none; }
  .b-bar { flex-direction: column; align-items: stretch; bottom: calc(60px + env(safe-area-inset-bottom)); padding: 12px 0; gap: 8px; }
  .b-bar #b-act { min-width: 0; } .b-bar .btn { width: 100%; }
  .cp { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "n b" "n a"; gap: 2px 12px; padding: 12px; }
  .cp-n { grid-area: n; } .cp-b { grid-area: b; justify-self: end; } .cp-a { grid-area: a; font-size: 13px; color: var(--ink-2); font-weight: 400; } .cp-net { display: none; }
  .tm { grid-template-columns: minmax(0, 1fr) auto; gap: 12px; padding: 12px; }
  .tm-d, .tm-l { display: none; }
  .inv { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "c a" "s w"; gap: 4px 12px; padding: 12px 0; }
  .inv-id { display: none; } .inv-c { grid-area: c; } .inv-a { grid-area: a; } .inv > span:nth-child(3) { grid-area: s; } .inv-w { grid-area: w; text-align: right; }
  .agent { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "n s" "l l" "b b" "x x"; gap: 8px 12px; padding: 16px 0; }
  .ag-n { grid-area: n; } .ag-s { grid-area: s; } .ag-l { grid-area: l; } .ag-b { grid-area: b; } .agent .btn { grid-area: x; justify-self: stretch; }
  .au { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "p w" "t t" "d d"; gap: 4px 12px; padding: 12px 0; }
  .au-p { grid-area: p; } .au-w { grid-area: w; } .au-t { grid-area: t; font-weight: 500; } .au-d { grid-area: d; font-size: 14px; }
  .rule-s { font-size: 20px; line-height: 32px; }
  .pend { grid-template-columns: 1fr; }
  .pend-side { justify-content: space-between; }
  .try-in > * { width: 100%; }
  .try-in .seg button { flex: 1; }
  .try-amt, .try-in .select select { height: 44px; }
  .try-amt input { flex: 1; text-align: left; font-size: 16px; }
  /* sheets */
  .drawer, .dialog, .dialog.cmd { left: 0; right: 0; top: auto; bottom: 0; translate: none; width: auto; max-height: 92dvh; border-radius: 20px 20px 0 0; padding-bottom: env(safe-area-inset-bottom); transform: translateY(var(--drag, 0)); }
  .dialog.cmd { top: 8dvh; max-height: none; }
  .drawer { height: auto; }
  .grab { display: block; flex: none; height: 24px; touch-action: none; cursor: grab; }
  .grab::after { content: ""; display: block; width: 36px; height: 4px; margin: 8px auto 0; border-radius: 2px; background: var(--line-2); }
  .dr-h { padding: 0 20px 16px; }
  .dr-b { padding: 4px 20px 20px; }
  .dr-f { padding: 12px 20px; }
  .kv > div { grid-template-columns: 104px minmax(0, 1fr); }
  .stop { padding: 8px 20px 16px; }
  #toasts { left: 50%; bottom: calc(72px + env(safe-area-inset-bottom)); }
  .toast { max-width: calc(100vw - 32px); }
  .pop { max-width: calc(100vw - 16px); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; }
}

/* On a phone the home screen shows what needs you before the weekly flow. */
@media (max-width: 760px) {
  .home { display: flex; flex-direction: column; }
  .home .hero { display: contents; }
  .home .hero-l { order: 0; padding-top: 8px; }
  .home .sec-needs { order: 1; }
  .home .hero-r { order: 2; margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--line); }
  .home .sec:not(.sec-needs) { order: 3; }
  .home .chart svg, .home .c-rule { height: 104px; }
}
@media (max-width: 760px) {
  .sec-first { margin-top: 0; padding-top: 4px; }
}
.field { grid-template-columns: minmax(0, 1fr); }
.amount input { width: 100%; }
@media (max-width: 980px) {
  /* One column: the fields, then what will happen, then the button. */
  .pay-form { display: contents; }
  .pay-form .field { margin-bottom: 20px; }
  .pay-sum { order: 2; margin-top: 4px; }
  .pay-go { order: 3; margin-top: 24px; }
  .review + .pay-sum { display: none; }
}
@media (max-width: 760px) {
  .pay-form ~ .pay-go, .pay-go:not(.pay-go-2) { position: sticky; bottom: calc(60px + env(safe-area-inset-bottom)); z-index: 4; margin: 16px calc(var(--pad) * -1) 0; padding: 12px var(--pad); background: var(--surface); border-top: 1px solid var(--line); }
}

/* Counterparty totals are all in USD, so the unit hugs the right edge. */
.cp-a .tok { width: auto; }
