/* forks — one stylesheet for every page. The look is a code host's: a flat canvas, boxes with a muted
   header row, hairline borders, 6px corners, system type, mono for code and numbers, a green primary
   button, an underlined tab bar. Colour carries meaning only: green = the traced line and "go",
   blue = links and project tokens, amber = coins launched here and pending $FORK, red = errors and sells. */
@font-face { font-family: 'Anybody'; src: url(../fonts/anybody.woff2) format('woff2'); font-weight: 100 900; font-stretch: 50% 150%; font-display: swap; }
@font-face { font-family: 'JetBrains Mono'; src: url(../fonts/jetbrains-mono.woff2) format('woff2'); font-weight: 100 800; font-display: swap; }

:root {
  --bg: #0d1117;          /* canvas */
  --bg-2: #0d1117;        /* boxes */
  --bg-3: #151b23;        /* box headers, muted surfaces */
  --bg-inset: #010409;    /* the header, insets */
  --ink: #f0f6fc;
  --ink-2: #9198a1;
  --ink-3: #656c76;
  --rule: #3d444db3;
  --rule-2: #3d444d;
  --acc: #3fb950;         /* the traced line, success, primary */
  --acc-soft: rgba(63, 185, 80, .15);
  --acc-ink: #ffffff;
  --link: #4493f8;        /* links, project tokens */
  --link-soft: rgba(56, 139, 253, .15);
  --warn: #d29922;        /* coins launched here, pending */
  --warn-soft: rgba(187, 128, 9, .15);
  --err: #f85149;
  --err-soft: rgba(248, 81, 73, .12);
  --done: #ab7df8;
  --btn: #212830; --btn-hover: #262c36; --btn-border: #3d444d;
  --primary: #238636; --primary-hover: #29903b;
  --tab: #f78166;
  --counter: rgba(101, 108, 118, .2);
  --veil: rgba(13, 17, 23, .86);
  --shadow: 0 8px 24px rgba(1, 4, 9, .75);
  --field-ink: #c9d1d9;

  --sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Noto Sans', Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji';
  --display: var(--sans);
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, 'Liberation Mono', monospace;
  --col: min(760px, calc(100vw - 32px));
  --page: min(1280px, calc(100vw - 32px));
  --r: 6px;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --gut: max(16px, env(safe-area-inset-left, 0px));
  --gut-r: max(16px, env(safe-area-inset-right, 0px));
  color-scheme: dark;
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #ffffff; --bg-2: #ffffff; --bg-3: #f6f8fa; --bg-inset: #f6f8fa; --ink: #1f2328; --ink-2: #59636e; --ink-3: #818b98;
    --rule: #d1d9e0b3; --rule-2: #d1d9e0; --acc: #1a7f37; --acc-soft: rgba(26, 127, 55, .1); --link: #0969da; --link-soft: rgba(9, 105, 218, .1);
    --warn: #9a6700; --warn-soft: rgba(212, 167, 44, .15); --err: #d1242f; --err-soft: rgba(209, 36, 47, .08); --done: #8250df;
    --btn: #f6f8fa; --btn-hover: #eff2f5; --btn-border: #d1d9e0; --primary: #1f883d; --primary-hover: #1c8139; --tab: #fd8c73;
    --counter: rgba(129, 139, 152, .18); --veil: rgba(255, 255, 255, .9); --shadow: 0 8px 24px rgba(140, 149, 159, .2); --field-ink: #24292f; color-scheme: light;
  }
}
:root[data-theme="light"] {
  --bg: #ffffff; --bg-2: #ffffff; --bg-3: #f6f8fa; --bg-inset: #f6f8fa; --ink: #1f2328; --ink-2: #59636e; --ink-3: #818b98;
  --rule: #d1d9e0b3; --rule-2: #d1d9e0; --acc: #1a7f37; --acc-soft: rgba(26, 127, 55, .1); --link: #0969da; --link-soft: rgba(9, 105, 218, .1);
  --warn: #9a6700; --warn-soft: rgba(212, 167, 44, .15); --err: #d1242f; --err-soft: rgba(209, 36, 47, .08); --done: #8250df;
  --btn: #f6f8fa; --btn-hover: #eff2f5; --btn-border: #d1d9e0; --primary: #1f883d; --primary-hover: #1c8139; --tab: #fd8c73;
  --counter: rgba(129, 139, 152, .18); --veil: rgba(255, 255, 255, .9); --shadow: 0 8px 24px rgba(140, 149, 159, .2); --field-ink: #24292f; color-scheme: light;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 14px/1.5 var(--sans);
  -webkit-font-smoothing: antialiased; overflow-x: hidden; min-height: 100vh;
}
::selection { background: var(--link-soft); }
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--link); outline-offset: -1px; border-radius: var(--r); }
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mono, code, kbd { font-family: var(--mono); }
.num { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.muted { color: var(--ink-2); }
.up { color: var(--acc); } .dn { color: var(--err); }
@keyframes rise { from { opacity: 0; transform: translateY(6px); } }
@keyframes fadeIn { from { opacity: 0; } }
@keyframes thk { 0%, 100% { opacity: .25; transform: scale(.7); } 50% { opacity: 1; transform: none; } }
@keyframes blink { 50% { opacity: 0; } }

/* ---------- mark ---------- */
.mark { width: 20px; height: 20px; flex: none; }
.mark path { fill: none; stroke: var(--acc); stroke-width: 2.1; stroke-linecap: round; }
.mark .d { fill: var(--acc); } .mark .e { fill: var(--bg); stroke: var(--acc); stroke-width: 1.5; }

/* ---------- buttons, labels, counters (shared) ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 32px; padding: 0 12px; border-radius: var(--r); border: 1px solid var(--btn-border); background: var(--btn); color: var(--ink); font: 500 14px/1 var(--sans); white-space: nowrap; text-decoration: none; transition: background .12s, border-color .12s, transform .12s var(--ease); }
.btn:hover { background: var(--btn-hover); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn.sm { height: 28px; padding: 0 10px; font-size: 12px; }
.btn.lg { height: 40px; padding: 0 16px; font-size: 15px; }
.btn.primary { background: var(--primary); border-color: rgba(240, 246, 252, .1); color: #fff; }
.btn.primary:hover { background: var(--primary-hover); }
.btn.danger { background: #da3633; border-color: rgba(240, 246, 252, .1); color: #fff; }
.btn.danger:hover { background: #e5534b; }
.btn.blue { background: #1f6feb; border-color: rgba(240, 246, 252, .1); color: #fff; }
.btn[disabled], .btn.busy { opacity: .5; pointer-events: none; }
.btn svg { width: 16px; height: 16px; flex: none; }
.btn.icon { width: 32px; padding: 0; }
.label { display: inline-flex; align-items: center; gap: 4px; height: 20px; padding: 0 7px; border-radius: 2em; border: 1px solid var(--rule-2); font: 500 12px/1 var(--sans); color: var(--ink-2); white-space: nowrap; }
.label.green { color: var(--acc); border-color: color-mix(in srgb, var(--acc) 45%, transparent); }
.label.blue { color: var(--link); border-color: color-mix(in srgb, var(--link) 45%, transparent); }
.label.amber { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 45%, transparent); }
.label.red { color: var(--err); border-color: color-mix(in srgb, var(--err) 45%, transparent); }
.label.purple { color: var(--done); border-color: color-mix(in srgb, var(--done) 45%, transparent); }
.counter { display: inline-grid; place-items: center; min-width: 20px; height: 18px; padding: 0 6px; border-radius: 2em; background: var(--counter); font: 500 12px/1 var(--sans); color: var(--ink); }
.tok { display: inline-flex; align-items: center; gap: 4px; padding: 0 6px; height: 20px; border-radius: 2em; font: 600 12px/1 var(--mono); white-space: nowrap; }
.tok.project { color: var(--link); background: var(--link-soft); }
.tok.forks { color: var(--warn); background: var(--warn-soft); }
.box { border: 1px solid var(--rule-2); border-radius: var(--r); background: var(--bg-2); }
.box-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 44px; padding: 8px 16px; background: var(--bg-3); border-bottom: 1px solid var(--rule-2); border-radius: var(--r) var(--r) 0 0; font-size: 14px; }
.box-h h2, .box-h h3 { margin: 0; font-size: 14px; font-weight: 600; }
.box-b { padding: 16px; }
.box-row { display: flex; align-items: center; gap: 12px; padding: 8px 16px; border-top: 1px solid var(--rule); }
.box-row:first-child { border-top: 0; }
.flash { padding: 12px 16px; border-radius: var(--r); border: 1px solid color-mix(in srgb, var(--link) 40%, transparent); background: var(--link-soft); color: var(--ink); font-size: 14px; }
.flash.warn { border-color: color-mix(in srgb, var(--warn) 40%, transparent); background: var(--warn-soft); }
.flash.err { border-color: color-mix(in srgb, var(--err) 40%, transparent); background: var(--err-soft); }
.input { height: 32px; padding: 0 12px; border-radius: var(--r); border: 1px solid var(--rule-2); background: var(--bg); color: var(--ink); font-size: 14px; outline: none; transition: border-color .12s, box-shadow .12s; }
.input:focus { border-color: var(--link); box-shadow: inset 0 0 0 1px var(--link); }
.input::placeholder { color: var(--ink-3); }
kbd { display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 4px; border: 1px solid var(--rule-2); border-radius: 4px; font-size: 11px; color: var(--ink-2); line-height: 1; }

/* ---------- the site header (every page) ---------- */
.hd { position: sticky; top: 0; z-index: 30; background: var(--bg-inset); border-bottom: 1px solid var(--rule-2); padding-top: env(safe-area-inset-top, 0px); }
.hd-row { display: flex; align-items: center; gap: 12px; height: 56px; padding: 0 var(--gut-r) 0 var(--gut); }
.hd-brand { display: inline-flex; align-items: center; gap: 8px; color: var(--ink); font: 600 16px/1 var(--sans); text-decoration: none; flex: none; }
.hd-brand:hover { text-decoration: none; }
.hd-brand .mark { width: 24px; height: 24px; }
.hd-crumb { color: var(--ink-2); font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.hd-crumb b { color: var(--ink); font-weight: 600; }
.hd-search { flex: 1; display: flex; justify-content: flex-end; min-width: 0; }
.hd-search form { position: relative; width: min(360px, 100%); }
.hd-search input { width: 100%; height: 32px; padding: 0 34px 0 32px; border-radius: var(--r); border: 1px solid var(--rule-2); background: var(--bg); color: var(--ink); font-size: 14px; outline: none; }
.hd-search input:focus { border-color: var(--link); box-shadow: inset 0 0 0 1px var(--link); }
.hd-search input::placeholder { color: var(--ink-2); }
.hd-search svg { position: absolute; left: 10px; top: 8px; width: 16px; height: 16px; color: var(--ink-2); pointer-events: none; }
.hd-search kbd { position: absolute; right: 8px; top: 7px; }
.hd-acts { display: flex; align-items: center; gap: 8px; flex: none; }
.hd-acts .btn { height: 32px; }
.hd-acts .btn.icon { width: 32px; }
.pill { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 10px; border-radius: var(--r); border: 1px solid var(--btn-border); background: var(--btn); font: 500 13px/1 var(--sans); color: var(--ink); text-decoration: none; white-space: nowrap; transition: background .12s; }
.pill:hover { background: var(--btn-hover); text-decoration: none; }
.pill.icon { width: 32px; padding: 0; justify-content: center; }
.pill svg { width: 16px; height: 16px; }
.pill .mob { display: none; }
.wbtn img { width: 16px; height: 16px; border-radius: 4px; }
.wbtn .dotg { width: 8px; height: 8px; border-radius: 50%; background: var(--acc); }
.tabs { display: flex; gap: 8px; padding: 0 var(--gut-r) 0 var(--gut); overflow-x: auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tab { position: relative; display: inline-flex; align-items: center; gap: 8px; height: 48px; padding: 0 8px; color: var(--ink); font-size: 14px; white-space: nowrap; text-decoration: none; }
.tab:hover { text-decoration: none; }
.tab::before { content: ""; position: absolute; left: 0; right: 0; top: 8px; bottom: 8px; border-radius: var(--r); transition: background .12s; z-index: -1; }
.tab:hover::before { background: var(--btn-hover); }
.tab svg { width: 16px; height: 16px; color: var(--ink-2); }
.tab.on { font-weight: 600; }
.tab.on::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; border-radius: 6px; background: var(--tab); }
.wmenu { position: absolute; z-index: 50; right: var(--gut-r); top: calc(52px + env(safe-area-inset-top, 0px)); width: 280px; border: 1px solid var(--rule-2); border-radius: 12px; background: var(--bg-3); box-shadow: var(--shadow); padding: 8px; animation: rise .2s var(--ease) both; }
.wmenu .wm-h { padding: 8px; font-size: 12px; color: var(--ink-2); }
.wmenu .wm-a { display: flex; align-items: center; gap: 8px; padding: 8px; font: 13px var(--mono); color: var(--ink); }
.wmenu .wm-b { display: flex; justify-content: space-between; padding: 4px 8px 8px; font-size: 13px; }
.wmenu button.wm-i { display: flex; align-items: center; gap: 8px; width: 100%; padding: 8px; border-radius: var(--r); text-align: left; font-size: 14px; }
.wmenu button.wm-i:hover { background: var(--btn-hover); }
.wmenu hr { border: 0; border-top: 1px solid var(--rule-2); margin: 6px 0; }
.foot { max-width: var(--page); margin: 40px auto 0; padding: 24px 0 calc(28px + env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--rule-2); display: flex; flex-wrap: wrap; gap: 8px 20px; align-items: center; font-size: 12px; color: var(--ink-2); }
.foot a { color: var(--ink-2); }
.foot .mark { width: 18px; height: 18px; opacity: .8; }
.foot .sp { flex: 1; }

/* ---------- page layout ---------- */
.page { max-width: var(--page); margin: 0 auto; padding: 24px 0 0; }
.page-h { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-bottom: 16px; margin-bottom: 16px; border-bottom: 1px solid var(--rule-2); }
.page-h h1 { margin: 0; font-size: 24px; font-weight: 600; line-height: 1.25; }
.page-h p { margin: 4px 0 0; color: var(--ink-2); font-size: 14px; max-width: 70ch; }
.layout { display: grid; grid-template-columns: minmax(0, 1fr) 296px; gap: 24px; align-items: start; }
.side { display: grid; gap: 16px; position: sticky; top: calc(130px + env(safe-area-inset-top, 0px)); }
.side h2 { margin: 0 0 8px; font-size: 16px; font-weight: 600; }
.side p { margin: 0 0 12px; color: var(--ink); font-size: 14px; }
.side .sect { padding-bottom: 16px; border-bottom: 1px solid var(--rule-2); }
.side .sect:last-child { border-bottom: 0; }
.side .links { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font-size: 14px; }
.side .links a { color: var(--ink-2); display: inline-flex; gap: 8px; align-items: center; }
.side .links a:hover { color: var(--link); text-decoration: none; }
.side .links svg { width: 16px; height: 16px; }
.trow { display: grid; grid-template-columns: 24px minmax(0, 1fr) auto; gap: 8px; align-items: center; padding: 6px 0; color: var(--ink); text-decoration: none; }
.trow:hover { text-decoration: none; }
.trow:hover .trow-s { color: var(--link); }
.trow-i { width: 24px; height: 24px; border-radius: 50%; overflow: hidden; display: grid; place-items: center; background: var(--bg-3); border: 1px solid var(--rule); font: 600 11px var(--mono); color: var(--ink-2); }
.trow-i img { width: 100%; height: 100%; object-fit: cover; }
.trow-n { display: grid; min-width: 0; }
.trow-s { font: 600 13px var(--mono); }
.trow-r { font-size: 12px; color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.trow-p { text-align: right; font: 12px/1.3 var(--mono); }
.trow-p span { display: block; font-size: 11px; }

/* ---------- home: intro, toolbar, timeline ---------- */
.intro { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 16px; }
.intro h1 { margin: 0; font-size: 20px; font-weight: 600; line-height: 1.3; }
.intro h1 .mark { width: 22px; height: 22px; vertical-align: -4px; margin-right: 6px; }
.intro p { margin: 4px 0 0; color: var(--ink-2); max-width: 72ch; }
.toolbar { display: flex; gap: 8px; align-items: center; margin-bottom: 16px; }
.toolbar .sel { flex: none; }
.ask { width: 100%; position: relative; }
.ask-row { display: flex; align-items: center; gap: 8px; }
.ask-in { position: relative; flex: 1; min-width: 0; }
.ask-in svg { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; color: var(--ink-2); pointer-events: none; }
.ask input { width: 100%; height: 36px; padding: 0 12px 0 34px; border-radius: var(--r); border: 1px solid var(--rule-2); background: var(--bg); color: var(--ink); font: 400 14px var(--sans); outline: none; transition: border-color .12s, box-shadow .12s; }
.ask input:focus { border-color: var(--link); box-shadow: inset 0 0 0 1px var(--link); }
.ask input::placeholder { color: var(--ink-2); }
.send { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 16px; border-radius: var(--r); background: var(--primary); border: 1px solid rgba(240, 246, 252, .1); color: #fff; font: 600 14px var(--sans); flex: none; }
.send:hover { background: var(--primary-hover); }
.send[disabled] { opacity: .55; cursor: default; }
.send svg { width: 16px; height: 16px; }
.send svg path { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ask-sub { display: flex; justify-content: flex-start; margin-top: 8px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: -4px 0 16px; }
.chip { display: inline-flex; align-items: center; height: 28px; padding: 0 12px; border-radius: 2em; border: 1px solid var(--rule-2); background: var(--bg); font: 500 12px/1 var(--sans); color: var(--link); transition: background .12s, border-color .12s; }
.chip:hover { background: var(--link-soft); border-color: color-mix(in srgb, var(--link) 50%, transparent); }
.chip:active { transform: scale(.98); }
.fine { margin: 8px 0 0; font-size: 12px; color: var(--ink-2); }

/* the timeline: you ask, upstream answers in a box with a header row */
.thread { list-style: none; margin: 0; padding: 0 0 140px; display: flex; flex-direction: column; gap: 16px; position: relative; }
.thread::before { content: ""; position: absolute; left: 19px; top: 0; bottom: 140px; width: 2px; background: var(--rule-2); z-index: -1; }
.msg { animation: rise .35s var(--ease) both; }
.msg.you { display: flex; align-items: center; gap: 8px; margin-left: 8px; padding: 2px 0; color: var(--ink-2); font-size: 14px; overflow-wrap: anywhere; }
.msg.you::before { content: ""; width: 24px; height: 24px; flex: none; border-radius: 50%; background: var(--bg-3) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%239198a1'%3E%3Cpath d='M10.68 11.74a6 6 0 0 1-7.922-8.982 6 6 0 0 1 8.982 7.922l3.04 3.04a.749.749 0 0 1-.326 1.275.749.749 0 0 1-.734-.215ZM11.5 7a4.499 4.499 0 1 0-8.997 0A4.499 4.499 0 0 0 11.5 7Z'/%3E%3C/svg%3E") center/12px no-repeat; border: 2px solid var(--bg); box-shadow: 0 0 0 1px var(--rule-2); }
.msg.you b { color: var(--ink); font-weight: 600; }
.msg.up { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 12px; }
.av { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--rule-2); background: var(--bg-3); display: grid; place-items: center; }
.av .mark { width: 22px; height: 22px; }
.msg.up .body { position: relative; border: 1px solid var(--rule-2); border-radius: var(--r); background: var(--bg-2); min-width: 0; }
.msg.up .body::before { content: ""; position: absolute; left: -8px; top: 12px; width: 14px; height: 14px; background: var(--bg-3); border-left: 1px solid var(--rule-2); border-bottom: 1px solid var(--rule-2); transform: rotate(45deg); }
.who { display: flex; gap: 8px; align-items: center; margin: 0; padding: 8px 16px; background: var(--bg-3); border-bottom: 1px solid var(--rule-2); border-radius: var(--r) var(--r) 0 0; font: 600 14px/1.5 var(--sans); color: var(--ink); }
.who .src { font: 500 12px/1 var(--sans); color: var(--ink-2); border: 1px solid var(--rule-2); border-radius: 2em; padding: 3px 7px; }
.msg.up .txt { padding: 12px 16px; }
.msg.up .txt:empty { display: none; }
.msg.up .cards { padding: 0 16px; }
.msg.up .cards:empty { display: none; }
.msg.up .cards > .card:last-child { margin-bottom: 16px; }
.msg.up .follow { padding: 0 16px 16px; margin-top: 0; }
.txt { white-space: pre-wrap; overflow-wrap: anywhere; color: var(--ink); }
.txt .caret { display: inline-block; width: .5em; height: 1.1em; background: var(--acc); vertical-align: -.2em; margin-left: 2px; animation: blink 1s steps(1) infinite; }
.thinking { color: var(--ink-2); display: inline-flex; gap: 8px; align-items: center; }
.thinking i { width: 6px; height: 6px; border-radius: 50%; background: var(--acc); animation: thk 1.1s var(--ease) infinite; }
.thinking i:nth-child(2) { animation-delay: .15s; } .thinking i:nth-child(3) { animation-delay: .3s; }
.follow { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.stop { margin-left: 8px; font-size: 12px; color: var(--ink-2); }

/* ---------- cards ---------- */
.card { margin-top: 14px; border: 1px solid var(--rule-2); border-radius: var(--r); background: color-mix(in srgb, var(--bg-2) 97%, transparent); overflow: hidden; animation: rise .5s var(--ease) both; }
.card-h { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 14px; border-bottom: 1px solid var(--rule); font: 400 11px/1.3 var(--mono); color: var(--ink-3); }
.card-h b { color: var(--ink-2); font-weight: 400; }
.card-h .acts { display: flex; gap: 12px; white-space: nowrap; flex: none; }
.card-h .acts button { color: var(--ink-2); } .card-h .acts button:hover { color: var(--acc); }
.card-b { padding: 12px 14px 14px; }
.tree-wrap { overflow-x: auto; padding: 6px 4px 8px; scrollbar-width: thin; }
.tree { display: block; overflow: visible; }
.tree .e { fill: none; stroke: var(--ink-3); stroke-width: 1.3; stroke-linecap: round; opacity: .55; }
.tree .e.sub { stroke: var(--ink-2); opacity: .85; }
.tree .e.path { stroke: var(--acc); stroke-width: 2.1; opacity: 1; }
.tree .e.LIKELY { stroke-dasharray: 5 4; } .tree .e.DISPUTED { stroke-dasharray: 1 4; }
.tree .e.grow { stroke-dashoffset: 0; animation: eIn .7s var(--ease) both; }
.tree .e.grow.LIKELY, .tree .e.grow.DISPUTED { animation-name: fadeIn; }
@keyframes eIn { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes fadeIn { from { opacity: 0; } }
.tree .n { cursor: pointer; }
.tree .n circle { fill: var(--bg-2); stroke: var(--ink-3); stroke-width: 1.3; transition: transform .15s var(--ease); transform-box: fill-box; transform-origin: center; }
.tree .n.sub circle { stroke: var(--ink-2); }
.tree .n.path circle { fill: var(--acc); stroke: var(--acc); }
.tree .n.root circle { fill: var(--acc); stroke: var(--acc); }
.tree .n.focus .ring { fill: none; stroke: var(--acc); stroke-width: 1.3; opacity: .7; }
.tree .n:hover circle { transform: scale(1.35); }
.tree .n text { font: 400 11px var(--mono); fill: var(--ink-3); paint-order: stroke; stroke: var(--bg-2); stroke-width: 4px; stroke-linejoin: round; }
.tree .n.sub text { fill: var(--ink-2); }
.tree .n.path text, .tree .n.focus text { fill: var(--ink); }
.tree .n .meta { font-size: 9.5px; fill: var(--ink-3) !important; }
.tree .n:hover text { fill: var(--acc); }
.tree .n.grow { animation: fadeIn .45s ease both; }
.legend { display: flex; flex-wrap: wrap; gap: 4px 14px; padding: 8px 14px 10px; border-top: 1px solid var(--rule); font: 400 10.5px/1.4 var(--mono); color: var(--ink-3); }
.legend i { display: inline-block; width: 18px; height: 0; border-top: 1.6px solid var(--ink-2); vertical-align: middle; margin-right: 6px; }
.legend i.l { border-top-style: dashed; } .legend i.d { border-top-style: dotted; border-top-width: 2px; } .legend i.p { border-color: var(--acc); }
.mut { display: grid; grid-template-columns: 128px minmax(0, 1fr) 18px minmax(0, 1fr); gap: 0 10px; }
.mut > * { padding: 7px 0; border-bottom: 1px solid var(--rule); font-size: 12.5px; line-height: 1.45; min-width: 0; overflow-wrap: anywhere; }
.mut .k { font-size: 10.5px; color: var(--ink-3); padding-top: 9px; }
.mut .then { color: var(--ink-3); } .mut .arr { color: var(--ink-3); text-align: center; }
.mut .ch .arr, .mut .arr.ch { color: var(--acc); }
.mut .now.ch { color: var(--ink); } .mut .now:not(.ch) { color: var(--ink-3); }
.mut .k.ch { color: var(--acc); }
.mut-h { display: grid; grid-template-columns: 128px minmax(0, 1fr) 18px minmax(0, 1fr); gap: 0 10px; padding-bottom: 6px; font: 750 20px/1.1 var(--display); color: var(--ink-2); }
.mut-h span:first-child { font: 400 10.5px var(--mono); color: var(--ink-3); align-self: end; }
.rows { display: grid; }
.row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 9px 2px; border-bottom: 1px solid var(--rule); text-align: left; width: 100%; }
.row:last-child { border-bottom: 0; }
.row:hover .rn { color: var(--acc); }
.rn { font-size: 13.5px; color: var(--ink); }
.rm { display: block; font-size: 10.5px; color: var(--ink-3); margin-top: 1px; }
.rv { font-size: 12px; color: var(--acc); white-space: nowrap; font-variant-numeric: tabular-nums; }
.srcs { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.srcs a { display: flex; gap: 10px; align-items: baseline; padding: 6px 0; text-decoration: none; font-size: 13px; color: var(--ink-2); border-bottom: 1px solid var(--rule); }
.srcs li:last-child a { border-bottom: 0; }
.srcs a::before { content: "↗"; color: var(--acc); }
.srcs a:hover { color: var(--ink); }

/* ---------- trace stage ---------- */
.msg.trace { width: min(1100px, calc(100vw - 32px)); align-self: center; display: grid; gap: 14px; }
.stage { position: relative; border: 1px solid var(--rule-2); border-radius: var(--r); background: color-mix(in srgb, var(--bg-2) 72%, transparent); overflow: hidden; height: 250px; transition: height .6s var(--ease); }
.st-top { position: absolute; z-index: 2; left: 0; right: 0; top: 0; display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 16px; pointer-events: none; }
.st-top > * { pointer-events: auto; }
.st-status { display: inline-flex; align-items: center; gap: 9px; min-width: 0; font: 400 11.5px/1.2 var(--mono); color: var(--ink-3); }
.st-status b { font-weight: 400; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.st-status i { width: 6px; height: 6px; border-radius: 50%; background: var(--acc); flex: none; }
.stage.looking .st-status i, .stage.growing .st-status i { animation: thk 1.1s var(--ease) infinite; }
.stage.grown .st-status { color: var(--ink-2); }
.st-acts button { font: 400 11.5px var(--mono); color: var(--ink-2); border-bottom: 1px dotted var(--ink-3); white-space: nowrap; }
.st-acts button:hover { color: var(--acc); border-color: var(--acc); }
.st-svg { display: block; width: 100%; height: 100%; overflow: visible; }
.st-probe { fill: none; stroke: var(--ink-3); stroke-width: 1.3; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 1; opacity: 0; animation: probe 1.9s var(--ease) both; }
@keyframes probe { 0% { stroke-dashoffset: 1; opacity: 0; } 15% { opacity: .75; } 60% { stroke-dashoffset: 0; opacity: .6; } 100% { stroke-dashoffset: 0; opacity: 0; } }
.st-tip { fill: var(--ink-3); opacity: 0; animation: tip 1.3s ease both; }
@keyframes tip { 30% { opacity: .9; } 100% { opacity: 0; } }
.st-seed { fill: var(--acc); animation: seed 1.4s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes seed { 50% { transform: scale(1.35); opacity: .7; } }
.st-e { fill: none; stroke: var(--ink-3); stroke-width: 1.3; stroke-linecap: round; opacity: .7; }
.st-e.path { stroke: var(--acc); stroke-width: 2.4; opacity: 1; }
.st-e.likely { stroke-dasharray: 5 4 !important; } .st-e.disputed { stroke-dasharray: 1 4 !important; }
.st-n { cursor: pointer; outline: none; }
.st-n .hit { fill: transparent; pointer-events: all; }
.st-n .dot { fill: var(--bg-2); stroke: var(--ink-3); stroke-width: 1.4; transform-box: fill-box; transform-origin: center; }
.st-n.path .dot, .st-n.root .dot { fill: var(--acc); stroke: var(--acc); }
.st-n .ring { fill: none; stroke: var(--acc); stroke-width: 1.4; transform-box: fill-box; transform-origin: center; }
.stage.grown .st-n.focus .ring { animation: ring 2.4s ease-out 1s infinite; }
@keyframes ring { 0% { opacity: .9; } 60% { opacity: .25; } 100% { opacity: .9; } }
.st-n text { font: 400 12.5px var(--mono); fill: var(--ink-3); paint-order: stroke; stroke: var(--bg-2); stroke-width: 5px; stroke-linejoin: round; transform-box: fill-box; }
.st-n.path text.nm { fill: var(--ink); }
.st-n.focus text.nm { font-size: 14px; font-weight: 500; fill: var(--ink); }
.st-n .mt { font-size: 10.5px; fill: var(--ink-3); }
.st-n.path .mt { fill: var(--ink-2); }
.st-n:hover text.nm, .st-n:focus-visible text.nm { fill: var(--acc); }
.st-n:hover .dot { stroke: var(--acc); }
.result { width: min(720px, 100%); margin: 0 auto; }
.r-head { font: 800 clamp(26px, 3.8vw, 44px)/1.04 var(--display); font-stretch: 92%; color: var(--ink); letter-spacing: -.015em; overflow-wrap: anywhere; animation: rise .5s var(--ease) both; }
.r-sub { margin: 6px 0 10px; font: 400 12px/1.5 var(--mono); color: var(--ink-3); animation: rise .5s var(--ease) .08s both; }
.r-sub b { font-weight: 400; color: var(--acc); }
.r-sub .sourced { color: var(--ink-2); }
.msg.trace .txt { color: var(--ink); }
@media (max-width: 640px) {
  .stage { border-radius: var(--r); }
  .st-n text { font-size: 12.5px; }
}

/* ---------- the repositories under a tree ---------- */
.line { margin-top: 16px; border: 1px solid var(--rule-2); border-radius: var(--r); background: color-mix(in srgb, var(--bg-2) 88%, transparent); overflow: hidden; }
.line-t { width: 100%; display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 10px 14px; text-align: left; transition: background .15s; }
.line-t:hover { background: color-mix(in srgb, var(--ink) 4%, transparent); }
.line-avs { display: flex; flex: none; }
.line-avs .rp-av.sm { width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--bg-2); margin-left: -7px; }
.line-avs .rp-av.sm:first-child { margin-left: 0; }
.line-avs .rp-av.sm b { font-size: 10px; }
.line-s { flex: 1; min-width: 0; font: 400 12px/1.4 var(--mono); color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.line-s b { font-weight: 500; color: var(--ink); }
.line-x { flex: none; font: 400 11.5px var(--mono); color: var(--ink-2); }
.line-x::after { content: ""; display: inline-block; width: 6px; height: 6px; margin: 0 2px 2px 8px; border-right: 1.4px solid currentColor; border-bottom: 1.4px solid currentColor; transform: rotate(45deg); transition: transform .2s var(--ease); }
.line.open .line-x::after { transform: rotate(-135deg); margin-bottom: -2px; }
.line-body { padding: 2px 8px 8px; border-top: 1px solid var(--rule); animation: rise .3s var(--ease) both; }
.line-k { margin: 12px 0 4px; padding-left: 12px; font: 400 10px/1 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); }
.rp { display: grid; grid-template-columns: auto 28px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px 12px; border-radius: var(--r); border: 1px solid transparent; text-decoration: none; color: inherit; transition: background .15s, border-color .15s, transform .15s var(--ease); }
.rp:hover { background: color-mix(in srgb, var(--bg-2) 85%, transparent); border-color: var(--rule); }
.rp:active { transform: scale(.995); }
.rp.focus { border-color: color-mix(in srgb, var(--acc) 40%, transparent); background: color-mix(in srgb, var(--acc) 6%, transparent); }
.rp-i { width: 18px; text-align: right; font: 400 11px var(--mono); color: var(--ink-3); font-variant-numeric: tabular-nums; }
.rp.main .rp-i { color: var(--acc); }
.rp:not(:has(.rp-i)) { grid-template-columns: 28px minmax(0, 1fr) auto; padding-left: 42px; }
.rp-av { width: 28px; height: 28px; border-radius: 8px; overflow: hidden; display: grid; place-items: center; background: var(--bg-3); border: 1px solid var(--rule); }
.rp-av b { font: 500 12px var(--mono); color: var(--ink-2); text-transform: lowercase; }
.rp-av img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rp-b { display: grid; gap: 2px; min-width: 0; }
.rp-name { font: 500 13.5px/1.3 var(--mono); color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rp-o { color: var(--ink-3); font-weight: 400; }
.rp.main .rp-name { color: var(--ink); }
.rp-desc { font-size: 12px; line-height: 1.4; color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rp-meta { font-size: 11px; color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rp-meta i { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; vertical-align: 0; }
.rp-s { font: 400 12px var(--mono); color: var(--ink-2); font-variant-numeric: tabular-nums; white-space: nowrap; }
.rp.focus .rp-s, .rp.main .rp-s { color: var(--ink); }
@media (max-width: 640px) {
  .rp { gap: 10px; padding: 9px 8px; }
  .rp:not(:has(.rp-i)) { padding-left: 8px; }
  .rp-desc { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
}

/* ---------- point card ---------- */
.point { position: absolute; z-index: 45; width: min(330px, calc(100vw - 24px)); max-height: min(70vh, 520px); overflow: auto; padding: 14px 16px 12px; border-radius: var(--r); border: 1px solid var(--rule-2); background: var(--bg-2); box-shadow: 0 18px 50px rgba(0, 0, 0, .35); font: 400 13px/1.5 var(--sans); animation: rise .25s var(--ease) both; }
.point.fixed { position: fixed; }
.point.sheet { position: fixed; left: 0 !important; right: 0; bottom: 0; top: auto !important; width: 100%; max-height: 72vh; border-radius: 18px 18px 0 0; padding: 18px 18px calc(16px + env(safe-area-inset-bottom, 0px)); }
.pt-h { padding-right: 22px; }
.pt-name { font: 800 21px/1.1 var(--display); font-stretch: 92%; color: var(--ink); overflow-wrap: anywhere; }
.pt-meta { margin-top: 4px; font-size: 11px; color: var(--ink-3); }
.pt-how { margin-top: 8px; font-size: 12px; color: var(--acc); }
.pt-desc { margin: 10px 0 0; font-size: 12px; color: var(--ink-2); }
.pt-k { margin: 12px 0 2px; font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); }
.pt-links { list-style: none; margin: 0; padding: 0; }
.pt-links a { display: flex; gap: 10px; align-items: baseline; padding: 8px 0; min-height: 36px; text-decoration: none; color: var(--ink); border-bottom: 1px solid var(--rule); overflow-wrap: anywhere; }
.pt-links li:last-child a { border-bottom: 0; }
.pt-links a::before { content: "↗"; color: var(--acc); flex: none; }
.pt-links a:hover { color: var(--acc); }
.pt-acts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.pt-acts button { min-height: 34px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--rule-2); font-size: 12px; color: var(--ink-2); }
.pt-acts button:first-child { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.pt-acts button:active { transform: scale(.97); }
.pt-x { position: absolute; top: 8px; right: 10px; width: 30px; height: 30px; font-size: 20px; line-height: 1; color: var(--ink-3); }
.r-sub .hint { color: var(--ink-3); }
@media (max-width: 640px) { .r-sub .hint { display: block; } }

/* ---------- $FORK: /freeforks ---------- */
.ask-sub { display: flex; justify-content: center; margin-top: 10px; }
.quest { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 13px; border-radius: 999px; border: 1px dashed color-mix(in srgb, var(--warn) 55%, transparent); background: var(--veil); font: 400 12px/1 var(--mono); color: var(--ink-2); transition: color .15s, border-color .15s, transform .15s var(--ease); }
.quest b { color: var(--warn); font-weight: 500; font-variant-numeric: tabular-nums; }
.quest:hover { color: var(--ink); border-style: solid; }
.quest:active { transform: translateY(1px) scale(.98); }
.quest.has { border-style: solid; border-color: var(--rule-2); }
body.chat .ask-sub { margin-top: 8px; }
.pill.me { color: var(--ink); gap: 6px; }
.pill.me img, .pill.me .ini { width: 18px; height: 18px; border-radius: 50%; flex: none; }
.pill.me .ini { display: grid; place-items: center; background: var(--bg-3); font-size: 10px; color: var(--ink-2); text-transform: uppercase; }
.pill.me .amt { font-variant-numeric: tabular-nums; }
.pill.me .demo, .card-h b.demo { font-size: 9.5px; color: var(--warn); border: 1px solid color-mix(in srgb, var(--warn) 40%, transparent); border-radius: 999px; padding: 1px 5px; }
.pill.me svg { width: 12px; height: 12px; }
.quest-card .card-b { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
.q-task { display: flex; justify-content: space-between; align-items: center; gap: 14px; }
.q-title { font-size: 14px; color: var(--ink); }
.q-reward { margin-top: 3px; font-size: 12px; color: var(--warn); font-variant-numeric: tabular-nums; }
.q-reward span { color: var(--ink-3); }
.q-reward.ok { color: var(--acc); }
.q-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 40px; padding: 0 18px; border-radius: var(--r); background: var(--ink); color: var(--bg); font: 500 13px/1 var(--mono); text-decoration: none; white-space: nowrap; flex: none; transition: transform .15s var(--ease), opacity .15s; }
.q-btn:active { transform: translateY(1px) scale(.98); }
.q-btn.busy { opacity: .35; pointer-events: none; }
.q-btn.ghost { background: transparent; color: var(--ink); border: 1px solid var(--rule-2); }
.q-btn.x svg { width: 15px; height: 15px; }
.q-state { display: grid; gap: 6px; font-size: 11px; color: var(--ink-3); }
.q-state.err .q-msg { color: var(--err); }
.q-bar { height: 2px; border-radius: 2px; background: var(--rule); overflow: hidden; }
.q-bar i { display: block; height: 100%; width: 0; background: var(--warn); transition: width linear; }
.quest-card.done { border-color: color-mix(in srgb, var(--acc) 35%, var(--rule-2)); }
.q-row { display: flex; gap: 8px; }
.q-in { flex: 1; min-width: 0; height: 40px; padding: 0 12px; border-radius: var(--r); border: 1px solid var(--rule-2); background: var(--bg); color: var(--ink); font: 400 14px var(--mono); outline: none; }
.q-in:focus { border-color: color-mix(in srgb, var(--acc) 55%, transparent); }
.q-note { margin: 0; font-size: 11px; color: var(--ink-3); }
.q-done { font-size: 13px; color: var(--acc); }
.mono { font-variant-numeric: tabular-nums; }
.q-sum { display: grid; gap: 8px; }
.q-who { display: flex; align-items: center; gap: 8px; color: var(--ink-2); font-size: 12px; }
.q-who img { border-radius: 50%; }
.q-big { font: 900 40px/1 var(--display); color: var(--ink); font-variant-numeric: tabular-nums; }
.q-big span { font: 400 12px var(--mono); color: var(--warn); margin-left: 4px; }
.q-meta { font-size: 11px; color: var(--ink-3); }
.q-acts { display: flex; align-items: center; gap: 14px; margin-top: 4px; }
.q-link { font-size: 12px; color: var(--ink-3); border-bottom: 1px dotted var(--ink-3); }
/* the x scan: the account read back line by line, then its tokens fly up into the header */
.sc { display: grid; gap: 12px; }
.sc-who { display: flex; align-items: center; gap: 10px; }
.sc-who img, .sc-who .ini { width: 36px; height: 36px; border-radius: 50%; flex: none; }
.sc-who .ini, .q-who .ini { display: grid; place-items: center; background: var(--bg-3); color: var(--ink-2); font: 500 13px var(--mono); text-transform: lowercase; }
.q-who .ini { width: 28px; height: 28px; border-radius: 50%; }
.sc-id { display: grid; gap: 2px; min-width: 0; flex: 1; }
.sc-id b { font-weight: 500; font-size: 13.5px; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sc-id span { font-size: 11.5px; color: var(--ink-3); }
.sc-st { display: inline-flex; align-items: center; gap: 7px; font-size: 11px; color: var(--warn); }
.sc-st::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; animation: thk 1.1s var(--ease) infinite; }
.sc.done .sc-st { color: var(--acc); } .sc.done .sc-st::before { animation: none; }
.sc-sweep { position: relative; height: 1px; background: var(--rule); overflow: hidden; }
.sc-sweep i { position: absolute; top: 0; bottom: 0; left: -40%; width: 40%; background: linear-gradient(90deg, transparent, var(--warn), transparent); animation: sweep 1.3s linear infinite; }
.sc.done .sc-sweep i { animation: none; opacity: 0; }
@keyframes sweep { to { left: 100%; } }
.sc-lines { list-style: none; margin: 0; padding: 0; display: grid; }
.sc-l { display: grid; grid-template-columns: minmax(0, 1fr) auto 76px; gap: 12px; align-items: baseline; padding: 8px 0; border-bottom: 1px dashed var(--rule-2); font-size: 12.5px; animation: rise .35s var(--ease) both; }
.sc-l .k { color: var(--ink-3); }
.sc-l .v { color: var(--ink); text-align: right; font-variant-numeric: tabular-nums; }
.sc-l .a { color: var(--warn); text-align: right; font-variant-numeric: tabular-nums; opacity: 0; transform: translateY(5px); transition: opacity .25s, transform .4s var(--ease); }
.sc-l.in .a { opacity: 1; transform: none; }
.sc-l.zero .a { color: var(--ink-3); }
.sc-tot { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding-top: 2px; }
.sc-tot .k { font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); }
.sc-tot .n { font: 900 42px/1 var(--display); color: var(--ink); white-space: nowrap; letter-spacing: -.02em; }
.sc-tot .n b { font-weight: 900; font-variant-numeric: tabular-nums; }
.sc-tot .tk { font: 400 12px var(--mono); color: var(--warn); }
.sc.done .sc-tot .n b { animation: lock 1.1s var(--ease); }
@keyframes lock { 30% { color: var(--warn); text-shadow: 0 0 26px color-mix(in srgb, var(--warn) 70%, transparent); } }
.coin { position: fixed; z-index: 70; left: 0; top: 0; width: 16px; height: 16px; margin: -8px 0 0 -8px; border-radius: 50%; display: grid; place-items: center; background: var(--warn); box-shadow: 0 0 14px color-mix(in srgb, var(--warn) 65%, transparent); pointer-events: none; will-change: transform, opacity; }
.coin svg { width: 11px; height: 11px; }
.coin path { fill: none; stroke: var(--bg); stroke-width: 3; stroke-linecap: round; }
.pill.me.bump { animation: bump .34s var(--ease); }
@keyframes bump { 40% { transform: scale(1.1); border-color: var(--warn); color: var(--warn); } }
/* your fork: the summary after the trials */
.fs-r { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--rule); font-size: 12.5px; color: var(--ink-3); }
.fs-r b { font-weight: 400; color: var(--ink); font-variant-numeric: tabular-nums; }
.fs-w .fs-r { border-top: 1px solid var(--rule); }
.fs-w .fs-r b { color: var(--acc); }
.fs-w { display: grid; gap: 8px; }
/* your fork: the printed card, then copy → quote → paste the link */
.fk { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
.fk-pic { position: relative; min-width: 0; aspect-ratio: 1200 / 675; border-radius: var(--r); overflow: hidden; background: #010409; border: 1px solid var(--rule-2); }
.fk-img { display: block; width: 100%; height: auto; animation: print 1.5s steps(10, end) both; }
@keyframes print { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0 0 0 0); } }
.fk-wait { position: absolute; inset: 0; display: grid; place-items: center; color: #9198a1; font: 400 12px var(--mono); }
.fk-acts { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.fk-acts .q-btn b, .fk-proof .q-note b { display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; font-size: 10.5px; font-weight: 600; background: var(--bg); color: var(--ink); }
.fk-acts .q-btn.x { background: transparent; color: var(--ink); border: 1px solid var(--rule-2); }
.fk-acts .q-btn.x b { background: var(--ink); color: var(--bg); }
.fk-proof { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; padding-top: 4px; border-top: 1px dashed var(--rule-2); }
.fk-proof .q-row .q-in { width: 100%; }
.fk-proof .q-note { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--ink-2); padding-top: 8px; }
.fk-proof .q-note b { background: var(--ink); color: var(--bg); }
.fk-foot { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.fk-foot .q-link { text-align: left; }
.q-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.q-chips .chip { min-height: 34px; }
/* invite */
.ivc { display: grid; gap: 12px; }
.ivc-link { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 6px 6px 6px 14px; border: 1px solid var(--rule-2); border-radius: var(--r); background: var(--bg); }
.ivc-link span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; color: var(--ink); }
.ivc-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.ivc-stats div { display: grid; gap: 4px; padding: 11px 12px; border: 1px solid var(--rule); border-radius: var(--r); }
.ivc-stats b { font: 900 28px/1 var(--display); color: var(--ink); font-variant-numeric: tabular-nums; }
.ivc-stats span { font-size: 11px; color: var(--ink-3); }
.pill.inv svg { width: 15px; height: 15px; }
.toast { position: fixed; z-index: 50; left: 50%; bottom: calc(118px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); max-width: calc(100vw - 32px); padding: 10px 14px; border-radius: var(--r); border: 1px solid var(--rule-2); background: var(--bg-2); color: var(--ink); font: 400 12.5px/1.4 var(--mono); box-shadow: 0 8px 30px rgba(0, 0, 0, .25); animation: rise .3s var(--ease) both; transition: opacity .3s; }
.toast.out { opacity: 0; }

/* ---------- coins on repositories (/launch, /coins) ---------- */
.st-n text.tk { font: 600 11px var(--mono); fill: var(--warn); }
.rp-coin { display: inline-block; margin-left: 8px; padding: 0 6px; border-radius: 999px; border: 1px solid color-mix(in srgb, var(--warn) 45%, transparent); font: 500 10.5px/1.6 var(--mono); color: var(--warn); vertical-align: 1px; cursor: pointer; }
.rp-coin:hover { background: color-mix(in srgb, var(--warn) 12%, transparent); }
.pt-coin { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-top: 12px; padding: 9px 12px; border-radius: var(--r); border: 1px solid color-mix(in srgb, var(--warn) 35%, var(--rule-2)); }
.pt-coin .pt-k { margin: 0; }
.pt-coin b { font: 800 17px/1 var(--display); color: var(--warn); }
.pt-coin .mono { color: var(--ink-2); font-size: 12px; }
.pt-coin a { margin-left: auto; color: var(--ink-2); font-size: 12px; text-decoration: none; }
.pt-coin a:hover { color: var(--acc); }
.ln .card-b, .tkn .card-b { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
.card-h .mono { color: var(--ink-3); }
.ln-k { font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); }
.ln-split { list-style: none; margin: -4px 0 0; padding: 0; display: grid; }
.ln-split li { position: relative; display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 8px 0 10px; border-bottom: 1px solid var(--rule); }
.ln-split li:last-child { border-bottom: 0; }
.ln-split li > i { position: absolute; left: 38px; bottom: 4px; height: 2px; width: calc((100% - 38px) * var(--w, 1)); border-radius: 2px; background: color-mix(in srgb, var(--ink-3) 55%, transparent); transform-origin: left; animation: barIn .7s var(--ease) both; }
@keyframes barIn { from { transform: scaleX(0); } }
.ln-split li.fk > i { background: color-mix(in srgb, var(--acc) 60%, transparent); }
.ln-av { width: 28px; height: 28px; border-radius: 50%; overflow: hidden; background: var(--bg-3); display: grid; place-items: center; }
.ln-av img { width: 100%; height: 100%; display: block; }
.ln-av.ghost { border: 1px dashed var(--rule-2); background: transparent; }
.ln-av.fk { border-radius: 8px; border: 1px solid var(--rule-2); background: var(--bg); }
.ln-av.fk svg { width: 16px; height: 16px; fill: none; stroke: var(--ink); stroke-width: 1.6; stroke-linecap: round; }
.ln-av.fk circle:first-of-type { fill: var(--acc); stroke: none; }
.ln-who { display: grid; gap: 1px; min-width: 0; }
.ln-who b { font-weight: 500; font-size: 13px; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ln-who a { text-decoration: none; min-width: 0; overflow: hidden; } .ln-who a:hover b { color: var(--acc); }
.ln-who span { font-size: 11px; color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ln-p { font-size: 13px; color: var(--ink); }
.ln-line { font-size: 11.5px; color: var(--ink-3); overflow-wrap: anywhere; }
.ln-line b { font-weight: 400; color: var(--ink-2); }
.ln-form { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 14px; align-items: start; }
.ln-logo { display: grid; gap: 6px; }
.ln-logo canvas { width: 112px; height: 112px; border-radius: var(--r); border: 1px solid var(--rule-2); display: block; }
.ln-la { display: flex; justify-content: space-between; gap: 6px; font-size: 11px; }
.ln-la button, .ln-la label { color: var(--ink-2); border-bottom: 1px dotted var(--ink-3); cursor: pointer; }
.ln-la button:hover, .ln-la label:hover { color: var(--ink); }
.ln-fields { display: grid; gap: 10px; min-width: 0; }
.ln-f { display: grid; gap: 5px; min-width: 0; }
.ln-f > span:first-child { font-size: 11px; color: var(--ink-3); }
.ln-f .q-in { width: 100%; }
.ln-tk { position: relative; display: block; }
.ln-tk i { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); font-style: normal; color: var(--warn); font-size: 14px; pointer-events: none; }
.ln-tk .q-in { padding-left: 24px; text-transform: uppercase; color: var(--warn); letter-spacing: .04em; }
.ln-ok { display: grid; grid-template-columns: 18px minmax(0, 1fr); gap: 10px; align-items: start; padding: 10px 12px; border-radius: var(--r); border: 1px dashed var(--rule-2); font-size: 12px; line-height: 1.45; color: var(--ink-2); cursor: pointer; }
.ln-ok input { width: 16px; height: 16px; margin: 1px 0 0; accent-color: var(--acc); }
.ln-ok.shake { animation: shake .4s var(--ease); border-color: var(--warn); }
@keyframes shake { 20%, 60% { transform: translateX(-5px); } 40%, 80% { transform: translateX(5px); } }
.ln-go { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.ln-go .q-btn { min-width: 168px; }
.ln-go .q-btn[disabled] { opacity: .4; cursor: default; }
.ln-w { display: inline-flex; align-items: center; gap: 7px; font-size: 12px; color: var(--ink-2); }
.ln-w img { border-radius: 4px; }
.ln-w button { color: var(--ink-3); border-bottom: 1px dotted var(--ink-3); font-size: 11px; }
.ln-ws { display: grid; gap: 8px; }
.ln-wb { display: flex; flex-wrap: wrap; gap: 8px; }
.ln-wb .q-btn img { border-radius: 4px; }
.ln-cost { margin-top: -4px; }
.ln-steps { list-style: none; margin: 0; padding: 10px 0 0; border-top: 1px dashed var(--rule-2); display: grid; gap: 8px; counter-reset: s; }
.ln-steps li { display: grid; grid-template-columns: 16px minmax(0, 1fr); gap: 4px 10px; font-size: 12px; color: var(--ink-3); }
.ln-steps li i { width: 9px; height: 9px; margin: 4px 0 0 3px; border-radius: 50%; border: 1.5px solid var(--rule-2); }
.ln-steps li.run { color: var(--ink); } .ln-steps li.run i { border-color: var(--warn); background: var(--warn); animation: thk 1.1s var(--ease) infinite; }
.ln-steps li.ok { color: var(--ink-2); } .ln-steps li.ok i { border-color: var(--acc); background: var(--acc); }
.ln-steps li.err { color: var(--ink); } .ln-steps li.err i { border-color: var(--err); background: var(--err); }
.ln-steps em { grid-column: 2; font-style: normal; font-size: 11px; color: var(--ink-3); }
.ln-steps em:empty { display: none; }
.ln-steps li.err em { color: var(--err); }
.ln.done { border-color: color-mix(in srgb, var(--acc) 35%, var(--rule-2)); }
.ln.preview .ln-split li > i { background: color-mix(in srgb, var(--ink-3) 35%, transparent); }
.tkn.new { border-color: color-mix(in srgb, var(--warn) 45%, var(--rule-2)); box-shadow: 0 0 0 1px color-mix(in srgb, var(--warn) 15%, transparent), 0 16px 60px color-mix(in srgb, var(--warn) 10%, transparent); }
.tkn-live { color: var(--acc); display: inline-flex; align-items: center; gap: 6px; }
.tkn-live::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.tkn-top { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto; gap: 12px; align-items: center; }
.tkn-img { width: 56px; height: 56px; border-radius: var(--r); overflow: hidden; background: var(--bg-3); display: grid; place-items: center; border: 1px solid var(--rule-2); }
.tkn-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tkn-img b { font: 900 24px var(--display); color: var(--warn); }
.tkn-img.sm { width: 32px; height: 32px; border-radius: var(--r); }
.tkn-img.sm b { font-size: 15px; }
.tkn-id { display: grid; gap: 3px; min-width: 0; }
.tkn-sym { font: 900 30px/1 var(--display); color: var(--ink); letter-spacing: -.01em; overflow: hidden; text-overflow: ellipsis; }
.tkn-id > span { font-size: 11.5px; color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tkn-id a { color: var(--ink-2); text-decoration: none; } .tkn-id a:hover { color: var(--acc); }
.tkn-mk { display: grid; justify-items: end; gap: 3px; font-size: 11px; color: var(--ink-3); text-align: right; }
.tkn-mk b { font-size: 16px; font-weight: 500; color: var(--ink); }
.tkn-mk .up { color: var(--acc); } .tkn-mk .dn { color: var(--err); }
.tkn-ca { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 10px; align-items: center; width: 100%; padding: 9px 8px 9px 12px; border-radius: var(--r); border: 1px solid var(--rule-2); background: var(--bg); text-align: left; transition: border-color .15s; }
.tkn-ca:hover { border-color: var(--ink-3); }
.tkn-ca .k { font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); }
.tkn-ca .v { font-size: 12.5px; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tkn-ca b { font-weight: 500; font-size: 12px; padding: 6px 10px; border-radius: 8px; background: var(--ink); color: var(--bg); }
.tkn-ca.pulse { animation: capulse .6s var(--ease); }
@keyframes capulse { 30% { border-color: var(--acc); box-shadow: 0 0 0 4px var(--acc-soft); } }
.tkn-links { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 12px; }
.tkn-links a { color: var(--ink-2); text-decoration: none; border-bottom: 1px dotted var(--ink-3); }
.tkn-links a:hover { color: var(--acc); }
.tkn-split summary { cursor: pointer; font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); list-style: none; }
.tkn-split summary::-webkit-details-marker { display: none; }
.tkn-split summary::after { content: " +"; } .tkn-split[open] summary::after { content: " −"; }
.tkn-split[open] summary { margin-bottom: 8px; }
.tkn-list .card-b { display: grid; padding-top: 4px; padding-bottom: 4px; }
.tkl { display: grid; grid-template-columns: 32px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--rule); text-align: left; }
.tkl:last-child { border-bottom: 0; }
.tkl-id { display: grid; gap: 2px; min-width: 0; }
.tkl-id b { font: 800 16px/1.1 var(--display); color: var(--ink); }
.tkl-id span { font-size: 11.5px; color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tkl-m { font-size: 12px; color: var(--ink-2); }
.tkl:hover .tkl-id b { color: var(--warn); }

/* ---------- dock (chat mode) ---------- */
.dock { position: fixed; z-index: 10; left: 0; right: 0; bottom: 0; padding: 26px var(--gut-r) calc(16px + env(safe-area-inset-bottom, 0px)) var(--gut); display: none; justify-content: center; background: linear-gradient(to bottom, transparent, var(--bg) 46%); }
body.chat .dock { display: flex; }

/* ---------- full tree ---------- */
.full { position: fixed; inset: 0; z-index: 40; background: color-mix(in srgb, var(--bg) 92%, transparent); display: grid; grid-template-rows: auto 1fr auto; animation: fadeIn .25s ease both; }
.full[hidden] { display: none; }
.full-h { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: calc(16px + env(safe-area-inset-top, 0px)) var(--gut-r) 12px var(--gut); }
.full-h h2 { margin: 0; font: 800 clamp(24px, 3vw, 36px)/1 var(--display); font-stretch: 92%; }
.full-h p { margin: 4px 0 0; font-size: 11.5px; color: var(--ink-3); }
.full-b { overflow: auto; padding: 10px var(--gut-r) 20px var(--gut); }
.full .tree .n text { stroke: var(--bg); font-size: 12.5px; }
.full .tree .n .meta { font-size: 10.5px; }
.full .legend { border-top: 1px solid var(--rule); padding: 12px var(--gut-r) calc(14px + env(safe-area-inset-bottom, 0px)) var(--gut); }

@media (max-width: 640px) {
  .chips { gap: 6px; }
  .chip { font-size: 12px; }
  .pill .lbl { display: none; }
  .pill.me .lbl { display: inline; }
  .pill .mob { display: block; }
  .pill.me { padding: 0 7px; }
  .pill.me .demo, .pill.me .tk { display: none; }
  .q-task { flex-wrap: wrap; }
  .q-big { font-size: 38px; }
  .sc-tot .n { font-size: 38px; }
  .sc-l { grid-template-columns: minmax(0, 1fr) auto 64px; gap: 8px; }
  .fk-acts { display: grid; grid-template-columns: 1fr 1fr; }
  .fk-acts .q-btn { padding: 0 8px; font-size: 12.5px; gap: 6px; }
  .fk-acts .q-link { grid-column: 1 / -1; justify-self: start; }
  .pill { padding: 0 9px; }
  .mut, .mut-h { grid-template-columns: 92px minmax(0, 1fr) 14px minmax(0, 1fr); gap: 0 6px; }
  .mut > * { font-size: 11.5px; }
  .msg.up { grid-template-columns: 22px minmax(0, 1fr); gap: 10px; }
  .av { width: 22px; height: 22px; }
  .fine { font-size: 10.5px; }
  .ln-form { grid-template-columns: 92px minmax(0, 1fr); gap: 12px; }
  .ln-logo canvas { width: 92px; height: 92px; border-radius: var(--r); }
  .ln-go .q-btn { flex: 1; }
  .tkn-sym { font-size: 26px; }
  .tkn-top { grid-template-columns: 48px minmax(0, 1fr) auto; }
  .tkn-img:not(.sm) { width: 48px; height: 48px; }
}
@media (max-width: 420px) {
  .pill.gh { display: none; }
  .pill.inv { width: 30px; padding: 0; justify-content: center; }
}
@media (max-width: 360px) {
  .fk-acts .q-btn b { display: none; }
  .fk-acts .q-btn { font-size: 12px; }
  .pill.xl { display: none; }
  .pill.me .lbl { display: none; }
  .pill.me .amt { display: none !important; }
  .pill.me { width: 30px; padding: 0; justify-content: center; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; transition-duration: .01ms !important; }
}

/* =====================================================================================================
   The code-host skin over the components above (cards, stage, list, point card, trials, launch, coins)
   ===================================================================================================== */
.card { margin-top: 16px; border-radius: var(--r); background: var(--bg-2); animation: rise .35s var(--ease) both; }
.card-h { min-height: 40px; padding: 8px 16px; background: var(--bg-3); border-bottom: 1px solid var(--rule-2); font: 400 13px/1.4 var(--sans); color: var(--ink-2); }
.card-h b { color: var(--ink); font-weight: 600; }
.card-h .acts button { color: var(--link); font-size: 13px; }
.card-b { padding: 16px; }
.pill.me .demo, .card-h b.demo { font: 500 11px/1 var(--sans); color: var(--warn); border: 1px solid color-mix(in srgb, var(--warn) 45%, transparent); border-radius: 2em; padding: 3px 6px; }

/* buttons inside cards */
.q-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 32px; padding: 0 16px; border-radius: var(--r); background: var(--primary); border: 1px solid rgba(240, 246, 252, .1); color: #fff; font: 600 14px/1 var(--sans); text-decoration: none; white-space: nowrap; flex: none; transition: background .12s, transform .12s var(--ease); }
.q-btn:hover { background: var(--primary-hover); text-decoration: none; }
.q-btn.ghost, .fk-acts .q-btn.x { background: var(--btn); border-color: var(--btn-border); color: var(--ink); }
.q-btn.ghost:hover, .fk-acts .q-btn.x:hover { background: var(--btn-hover); }
.q-in { height: 32px; padding: 0 12px; border-radius: var(--r); border: 1px solid var(--rule-2); background: var(--bg); color: var(--ink); font: 400 14px var(--sans); }
.q-in:focus { border-color: var(--link); box-shadow: inset 0 0 0 1px var(--link); }
.q-link { color: var(--link); border: 0; font-size: 13px; }
.q-link:hover { text-decoration: underline; }
.q-title { font-weight: 600; }
.q-big, .sc-tot .n, .ivc-stats b { font-family: var(--sans); font-weight: 600; letter-spacing: -.01em; }
.q-big { font-size: 32px; } .sc-tot .n { font-size: 32px; } .ivc-stats b { font-size: 22px; }
.quest { height: 32px; border-radius: var(--r); background: var(--bg); font: 500 13px/1 var(--sans); color: var(--ink); border: 1px dashed color-mix(in srgb, var(--warn) 60%, transparent); }
.quest b { font-family: var(--mono); }
.pill.me .amt { font-family: var(--mono); }
.sc-l, .fs-r, .ivc-link span { font-family: var(--mono); }
.chip.q-chip { color: var(--ink); }

/* the stage: a box, inset canvas */
.msg.trace { display: grid; gap: 0; }
.msg.trace .stage-host { min-width: 0; }
.stage { border-radius: var(--r); background: var(--bg-inset); border-color: var(--rule-2); height: 250px; }
.st-top { padding: 10px 14px; }
.st-status { font: 500 12px/1.2 var(--sans); color: var(--ink-2); }
.st-acts button { font: 500 12px var(--sans); color: var(--link); border: 0; }
.st-acts button:hover { text-decoration: underline; color: var(--link); }
.st-n text { fill: var(--ink-2); stroke: var(--bg-inset); }
.st-n .dot { fill: var(--bg-inset); }
.st-n.path text.nm { fill: var(--ink); }
.st-n:hover text.nm, .st-n:focus-visible text.nm { fill: var(--link); }
.st-n text.tk { font: 600 11px var(--mono); fill: var(--warn); }
.st-n text.tk.project { fill: var(--link); }
.result { width: 100%; margin: 0; padding: 12px 16px 0; }
.r-head { font: 600 20px/1.3 var(--sans); letter-spacing: 0; color: var(--ink); }
.r-head .o { color: var(--ink-2); font-weight: 400; }
.r-sub { margin: 4px 0 8px; font: 400 13px/1.5 var(--sans); color: var(--ink-2); }
.r-sub b { color: var(--acc); font-weight: 600; }
.msg.trace .txt { padding: 4px 0 0; }
.msg.trace .cards { padding: 0; }
.msg.trace .follow { padding: 12px 0 16px; }
.msg.trace .result > .line:last-child { margin-bottom: 16px; }

/* the repositories under a tree: a file list */
.line { margin-top: 12px; border-radius: var(--r); background: var(--bg-2); }
.line-t { min-height: 44px; padding: 8px 16px; background: var(--bg-3); }
.line-t:hover { background: var(--btn-hover); }
.line-s { font: 400 13px/1.4 var(--sans); color: var(--ink-2); }
.line-s b { font-weight: 600; }
.line-x { font: 500 13px var(--sans); color: var(--link); }
.line-body { padding: 0; }
.line-k { margin: 0; padding: 8px 16px; background: var(--bg-3); border-top: 1px solid var(--rule-2); border-bottom: 1px solid var(--rule-2); font: 600 12px/1 var(--sans); letter-spacing: 0; text-transform: none; color: var(--ink-2); }
.rp { border-radius: 0; border: 0; border-top: 1px solid var(--rule); padding: 8px 16px; color: var(--ink); }
.line-k + .rp { border-top: 0; }
.rp:hover { background: var(--bg-3); border-color: var(--rule); text-decoration: none; }
.rp.focus { background: var(--acc-soft); border-color: var(--rule); }
.rp:not(:has(.rp-i)) { padding-left: 46px; }
.rp-av { border-radius: 50%; }
.rp-name { font: 600 14px/1.3 var(--sans); color: var(--link); }
.rp-o { color: var(--link); font-weight: 400; }
.rp-desc { font-size: 13px; }
.rp-meta { font-size: 12px; }
.rp-s { font: 12px var(--mono); }
.rp-coin { margin-left: 8px; border: 0; border-radius: 2em; padding: 1px 7px; font: 600 11px/1.6 var(--mono); color: var(--warn); background: var(--warn-soft); }
.rp-coin.project { color: var(--link); background: var(--link-soft); }
.rp-coin small { font-weight: 400; margin-left: 4px; opacity: .85; }

/* the point card: a popover */
.point { border-radius: 12px; background: var(--bg-3); box-shadow: var(--shadow); padding: 16px; font: 400 13px/1.5 var(--sans); }
.point.sheet { border-radius: 12px 12px 0 0; }
.pt-name { font: 600 16px/1.3 var(--sans); color: var(--link); }
.pt-meta { font-size: 12px; color: var(--ink-2); }
.pt-how { font-size: 13px; color: var(--acc); }
.pt-desc { color: var(--ink); font-size: 13px; }
.pt-k { font: 600 12px var(--sans); letter-spacing: 0; text-transform: none; color: var(--ink-2); }
.pt-links a { color: var(--link); border-color: var(--rule); }
.pt-links a::before { content: ""; width: 14px; height: 14px; flex: none; background: currentColor; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z'/%3E%3C/svg%3E") center/contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3.75 2h3.5a.75.75 0 0 1 0 1.5h-3.5a.25.25 0 0 0-.25.25v8.5c0 .138.112.25.25.25h8.5a.25.25 0 0 0 .25-.25v-3.5a.75.75 0 0 1 1.5 0v3.5A1.75 1.75 0 0 1 12.25 14h-8.5A1.75 1.75 0 0 1 2 12.25v-8.5C2 2.784 2.784 2 3.75 2Zm6.854-1h4.146a.25.25 0 0 1 .25.25v4.146a.25.25 0 0 1-.427.177L13.03 4.03 9.28 7.78a.751.751 0 0 1-1.042-.018.751.751 0 0 1-.018-1.042l3.75-3.75-1.543-1.543A.25.25 0 0 1 10.604 1Z'/%3E%3C/svg%3E") center/contain no-repeat; align-self: center; }
.pt-acts button { min-height: 32px; border-radius: var(--r); background: var(--btn); border-color: var(--btn-border); color: var(--ink); font: 500 13px var(--sans); }
.pt-acts button:first-child { background: var(--primary); color: #fff; border-color: rgba(240, 246, 252, .1); }
.pt-acts button.coin { color: var(--warn); }
.pt-coin { border-radius: var(--r); border-color: var(--rule-2); background: var(--bg); }
.pt-coin.project b { color: var(--link); }
.pt-coin b { font: 600 15px/1 var(--mono); }

/* the full tree, the dock, the toast */
.full { background: var(--bg); }
.full-h h2 { font: 600 20px/1.3 var(--sans); }
.dock { padding: 16px var(--gut-r) calc(12px + env(safe-area-inset-bottom, 0px)) var(--gut); background: linear-gradient(to bottom, transparent, var(--bg) 30%); }
.dock .ask { width: min(980px, 100%); padding: 8px; border: 1px solid var(--rule-2); border-radius: 12px; background: var(--bg-3); box-shadow: var(--shadow); }
.toast { border-radius: var(--r); background: var(--bg-3); font: 400 14px/1.4 var(--sans); box-shadow: var(--shadow); bottom: calc(96px + env(safe-area-inset-bottom, 0px)); }

/* launch and coin cards in the timeline */
.ln-k, .ln-f > span:first-child { font: 600 12px var(--sans); letter-spacing: 0; text-transform: none; color: var(--ink-2); }
.ln-who b { font: 600 14px var(--sans); }
.ln-who a b { color: var(--link); }
.ln-p { font-family: var(--mono); }
.ln-ok { border-radius: var(--r); font: 400 13px/1.45 var(--sans); }
.ln-steps li { font: 400 13px var(--sans); }
.ln-la button, .ln-la label { color: var(--link); border: 0; font-size: 12px; }
.ln-tk .q-in { font-family: var(--mono); }
.tkn-sym { font: 600 26px/1.1 var(--sans); }
.tkn-img { border-radius: 50%; }
.tkn-img.sm { border-radius: 50%; }
.tkn-ca { border-radius: var(--r); }
.tkn-ca b { border-radius: var(--r); font-family: var(--sans); background: var(--btn); color: var(--ink); border: 1px solid var(--btn-border); }
.tkn-links a { color: var(--link); border: 0; }
.tkn-split summary { font: 600 12px var(--sans); letter-spacing: 0; text-transform: none; }
.tkl-id b { font: 600 14px var(--mono); }

/* =====================================================================================================
   Market
   ===================================================================================================== */
.subnav { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 16px; }
.seg { display: inline-flex; border: 1px solid var(--btn-border); border-radius: var(--r); overflow: hidden; }
.seg button { height: 32px; padding: 0 14px; background: var(--btn); color: var(--ink); font: 500 14px var(--sans); border-left: 1px solid var(--btn-border); display: inline-flex; align-items: center; gap: 6px; }
.seg button:first-child { border-left: 0; }
.seg button:hover { background: var(--btn-hover); }
.seg button.on { background: var(--bg-3); font-weight: 600; box-shadow: inset 0 -2px 0 var(--tab); }
.subnav .grow { flex: 1; min-width: 160px; }
.subnav .input { width: 100%; }
.select { height: 32px; padding: 0 28px 0 12px; border-radius: var(--r); border: 1px solid var(--btn-border); background: var(--btn) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%239198a1'%3E%3Cpath d='m4.427 7.427 3.396 3.396a.25.25 0 0 0 .354 0l3.396-3.396A.25.25 0 0 0 11.396 7H4.604a.25.25 0 0 0-.177.427Z'/%3E%3C/svg%3E") right 8px center/16px no-repeat; color: var(--ink); font: 500 14px var(--sans); appearance: none; -webkit-appearance: none; }
.mk { overflow: hidden; }
.mk-h { display: grid; grid-template-columns: minmax(0, 2.2fr) 1fr 1fr .8fr .9fr 104px; gap: 12px; align-items: center; padding: 10px 16px; background: var(--bg-3); border-bottom: 1px solid var(--rule-2); font: 600 12px var(--sans); color: var(--ink-2); }
.mk-h span:not(:first-child) { text-align: right; }
.mk-r { display: grid; grid-template-columns: minmax(0, 2.2fr) 1fr 1fr .8fr .9fr 104px; gap: 12px; align-items: center; padding: 12px 16px; border-top: 1px solid var(--rule); color: var(--ink); text-decoration: none; transition: background .1s; }
.mk-r:first-of-type { border-top: 0; }
.mk-r:hover { background: var(--bg-3); text-decoration: none; }
.mk-id { display: grid; grid-template-columns: 36px minmax(0, 1fr); gap: 12px; align-items: center; min-width: 0; }
.mk-img { width: 36px; height: 36px; border-radius: 50%; overflow: hidden; display: grid; place-items: center; background: var(--bg-3); border: 1px solid var(--rule); font: 600 14px var(--mono); color: var(--ink-2); }
.mk-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.mk-n { display: grid; gap: 2px; min-width: 0; }
.mk-n b { font: 600 14px var(--sans); color: var(--ink); display: flex; gap: 8px; align-items: center; min-width: 0; }
.mk-n b span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mk-n small { font-size: 12px; color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: flex; gap: 6px; align-items: center; }
.mk-n small svg { width: 12px; height: 12px; flex: none; }
.mk-v { text-align: right; font: 13px var(--mono); font-variant-numeric: tabular-nums; }
.mk-v small { display: block; font: 11px var(--sans); color: var(--ink-2); }
.mk-act { text-align: right; }
.prog { height: 6px; border-radius: 3px; background: var(--rule); overflow: hidden; margin-top: 4px; }
.prog i { display: block; height: 100%; border-radius: 3px; background: var(--acc); }
.prog.done i { background: var(--done); }
.blank { padding: 48px 24px; text-align: center; }
.blank svg { width: 32px; height: 32px; color: var(--ink-3); }
.blank h3 { margin: 12px 0 4px; font-size: 20px; font-weight: 600; }
.blank p { margin: 0 auto 16px; color: var(--ink-2); max-width: 46ch; }
.src-note { margin: 8px 0 0; font-size: 12px; color: var(--ink-2); }

/* =====================================================================================================
   Coin terminal
   ===================================================================================================== */
.cn-h { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 16px; }
.cn-img { width: 48px; height: 48px; border-radius: 50%; overflow: hidden; display: grid; place-items: center; background: var(--bg-3); border: 1px solid var(--rule-2); font: 600 20px var(--mono); color: var(--ink-2); flex: none; }
.cn-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cn-t { display: grid; gap: 4px; min-width: 0; flex: 1; }
.cn-t h1 { margin: 0; font-size: 24px; font-weight: 600; line-height: 1.2; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.cn-t h1 .nm { color: var(--ink-2); font-weight: 400; font-size: 18px; }
.cn-t .meta { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 13px; color: var(--ink-2); }
.cn-t .meta a { color: var(--link); }
.cn-price { text-align: right; }
.cn-price b { display: block; font: 600 26px/1.15 var(--mono); }
.cn-price span { font: 13px var(--mono); }
.stats { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); margin-bottom: 16px; }
.stats > div { padding: 12px 16px; border-left: 1px solid var(--rule); }
.stats > div:first-child { border-left: 0; }
.stats dt { font-size: 12px; color: var(--ink-2); }
.stats dd { margin: 2px 0 0; font: 600 15px var(--mono); font-variant-numeric: tabular-nums; }
.term { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 16px; align-items: start; }
.term-side { display: grid; gap: 16px; position: sticky; top: calc(124px + env(safe-area-inset-top, 0px)); }
.chart-box .box-h { gap: 4px; flex-wrap: wrap; }
.tfs { display: inline-flex; gap: 2px; }
.tfs button { height: 28px; padding: 0 8px; border-radius: var(--r); font: 500 12px var(--mono); color: var(--ink-2); }
.tfs button:hover { background: var(--btn-hover); color: var(--ink); }
.tfs button.on { background: var(--btn); color: var(--ink); box-shadow: inset 0 0 0 1px var(--btn-border); }
.chart { position: relative; height: 380px; }
.chart canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; touch-action: pan-y; }
.chart .ch-tip { position: absolute; left: 12px; top: 10px; display: flex; gap: 10px; flex-wrap: wrap; font: 12px var(--mono); color: var(--ink-2); pointer-events: none; }
.chart .ch-tip b { font-weight: 500; color: var(--ink); }
.chart .ch-empty { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; color: var(--ink-2); font-size: 13px; padding: 24px; }
.chart-foot { display: flex; justify-content: space-between; gap: 8px; padding: 6px 16px; border-top: 1px solid var(--rule); font-size: 11px; color: var(--ink-3); }
.tabbar { display: flex; gap: 4px; padding: 0 8px; border-bottom: 1px solid var(--rule-2); background: var(--bg-3); border-radius: var(--r) var(--r) 0 0; }
.tabbar button { position: relative; height: 44px; padding: 0 10px; font: 500 14px var(--sans); color: var(--ink-2); }
.tabbar button.on { color: var(--ink); font-weight: 600; }
.tabbar button.on::after { content: ""; position: absolute; left: 6px; right: 6px; bottom: -1px; height: 2px; border-radius: 2px; background: var(--tab); }
.tabbar .counter { margin-left: 6px; }
.tlist { max-height: 460px; overflow: auto; }
.tl-h, .tl-r { display: grid; grid-template-columns: 74px 54px minmax(0, 1fr) minmax(0, 1fr) 96px; gap: 8px; align-items: center; padding: 8px 16px; font: 12px var(--mono); }
.tl-h { position: sticky; top: 0; background: var(--bg-2); border-bottom: 1px solid var(--rule-2); color: var(--ink-2); font-family: var(--sans); font-weight: 600; z-index: 1; }
.tl-r { border-top: 1px solid var(--rule); }
.tl-r:first-of-type { border-top: 0; }
.tl-r.new { animation: flashrow 1.4s ease; }
@keyframes flashrow { 0% { background: var(--acc-soft); } }
.tl-r .r, .tl-h .r { text-align: right; }
.tl-r a { color: var(--ink-2); }
.hl-r { display: grid; grid-template-columns: 28px minmax(0, 1fr) 70px; gap: 8px; align-items: center; padding: 8px 16px; border-top: 1px solid var(--rule); font: 12px var(--mono); }
.hl-r:first-of-type { border-top: 0; }
.hl-r .bar { position: relative; height: 4px; border-radius: 2px; background: var(--rule); margin-top: 4px; overflow: hidden; }
.hl-r .bar i { position: absolute; inset: 0 auto 0 0; background: var(--link); border-radius: 2px; }
.hl-r .r { text-align: right; }
.trade .tabbar button { flex: 1; }
.trade .tabbar button.on.buy::after { background: var(--acc); }
.trade .tabbar button.on.sell::after { background: var(--err); }
.trade-b { padding: 16px; display: grid; gap: 12px; }
.amt { position: relative; }
.amt input { width: 100%; height: 48px; padding: 0 70px 0 12px; border-radius: var(--r); border: 1px solid var(--rule-2); background: var(--bg); color: var(--ink); font: 500 20px var(--mono); outline: none; }
.amt input:focus { border-color: var(--link); box-shadow: inset 0 0 0 1px var(--link); }
.amt .unit { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); font: 600 13px var(--mono); color: var(--ink-2); }
.quick { display: flex; gap: 6px; flex-wrap: wrap; }
.quick button { height: 28px; padding: 0 10px; border-radius: var(--r); border: 1px solid var(--btn-border); background: var(--btn); font: 500 12px var(--mono); color: var(--ink); }
.quick button:hover { background: var(--btn-hover); }
.bal { display: flex; justify-content: space-between; font-size: 12px; color: var(--ink-2); }
.bal b { font: 500 12px var(--mono); color: var(--ink); }
.qv { display: grid; gap: 6px; padding: 12px; border-radius: var(--r); background: var(--bg-3); border: 1px solid var(--rule); font-size: 13px; }
.qv div { display: flex; justify-content: space-between; gap: 8px; }
.qv span { color: var(--ink-2); }
.qv b { font: 500 13px var(--mono); text-align: right; }
.qv .big b { font-size: 16px; }
.qv.wait b { color: var(--ink-3); }
.qv .warn b { color: var(--warn); }
.btn.go { width: 100%; height: 40px; font-size: 15px; }
.btn.go.sell { background: #da3633; }
.btn.go.sell:hover { background: #e5534b; }
.slip { display: flex; justify-content: space-between; align-items: center; font-size: 12px; color: var(--ink-2); }
.slip button { color: var(--link); font-size: 12px; }
.slip-set { display: flex; gap: 6px; }
.slip-set button { height: 26px; padding: 0 8px; border-radius: var(--r); border: 1px solid var(--btn-border); background: var(--btn); color: var(--ink); font: 12px var(--mono); }
.slip-set button.on { border-color: var(--link); color: var(--link); }
.tstate { font-size: 13px; color: var(--ink-2); min-height: 18px; }
.tstate.ok { color: var(--acc); } .tstate.err { color: var(--err); }
.tstate a { color: var(--link); }
.about .box-b { display: grid; gap: 12px; font-size: 14px; }
.about .repo { display: grid; gap: 4px; }
.about .repo a.rn { font: 600 15px var(--sans); }
.about .repo p { margin: 0; color: var(--ink); }
.about .repo .rm { display: flex; gap: 12px; flex-wrap: wrap; font-size: 12px; color: var(--ink-2); }
.about .lin { font-size: 13px; color: var(--ink-2); }
.about .lin a { font-family: var(--mono); }
.kv { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 6px 12px; font-size: 13px; }
.kv dt { color: var(--ink-2); } .kv dd { margin: 0; text-align: right; font-family: var(--mono); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ca-row { display: flex; align-items: center; gap: 8px; padding: 6px 6px 6px 12px; border-radius: var(--r); border: 1px solid var(--rule-2); background: var(--bg); }
.ca-row code { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; }
.ca-row.pulse { animation: capulse .6s var(--ease); }
.buybar { display: none; }

/* =====================================================================================================
   Launch page
   ===================================================================================================== */
.lp { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 24px; align-items: start; }
.lp-step { display: grid; gap: 12px; margin-bottom: 24px; }
.lp-step > h2 { margin: 0; font-size: 16px; font-weight: 600; display: flex; gap: 8px; align-items: center; }
.lp-step > h2 .n { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--bg-3); border: 1px solid var(--rule-2); font: 600 12px var(--sans); }
.pick { position: relative; }
.pick .input { width: 100%; height: 40px; font-size: 15px; padding-left: 36px; }
.pick > svg { position: absolute; left: 12px; top: 12px; width: 16px; height: 16px; color: var(--ink-2); }
.sugg { position: absolute; z-index: 20; left: 0; right: 0; top: 44px; border: 1px solid var(--rule-2); border-radius: var(--r); background: var(--bg-3); box-shadow: var(--shadow); max-height: 340px; overflow: auto; }
.sugg button { display: grid; grid-template-columns: 20px minmax(0, 1fr) auto; gap: 10px; align-items: center; width: 100%; padding: 10px 12px; text-align: left; border-top: 1px solid var(--rule); }
.sugg button:first-child { border-top: 0; }
.sugg button:hover, .sugg button.on { background: var(--btn-hover); }
.sugg b { font: 600 14px var(--sans); color: var(--link); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sugg small { display: block; font-size: 12px; color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sugg svg { width: 16px; height: 16px; color: var(--ink-2); }
.sugg .st { font: 12px var(--mono); color: var(--ink-2); }
.repo-card { display: grid; gap: 6px; padding: 16px; }
.repo-card .rn { font: 600 16px var(--sans); display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.repo-card p { margin: 0; color: var(--ink); }
.repo-card .rm { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--ink-2); }
.repo-card .rm i { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 4px; vertical-align: -1px; }
.lp-form { display: grid; grid-template-columns: 140px minmax(0, 1fr); gap: 16px; align-items: start; }
.lp-form canvas { width: 140px; height: 140px; border-radius: 50%; border: 1px solid var(--rule-2); display: block; }
.lp-fields { display: grid; gap: 12px; min-width: 0; }
.fld { display: grid; gap: 6px; min-width: 0; }
.fld > span { font: 600 14px var(--sans); }
.fld > span small { font-weight: 400; color: var(--ink-2); margin-left: 6px; }
.fld .input { width: 100%; }
.fld .hint { font-size: 12px; color: var(--ink-2); }
.fld-sol { position: relative; }
.fld-sol .input { padding-right: 48px; font-family: var(--mono); }
.fld-sol .u { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); font: 600 12px var(--mono); color: var(--ink-2); }
.lp-side .box-b { display: grid; gap: 10px; font-size: 13px; }
.lp-side ol { margin: 0; padding-left: 18px; display: grid; gap: 6px; color: var(--ink-2); }
.lp-side ol b { color: var(--ink); font-weight: 600; }
.ln-launch { display: grid; gap: 12px; }

/* =====================================================================================================
   Guide
   ===================================================================================================== */
.guide { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 32px; align-items: start; }
.toc { position: sticky; top: calc(124px + env(safe-area-inset-top, 0px)); display: grid; gap: 2px; font-size: 14px; }
.toc a { display: block; padding: 6px 8px; border-radius: var(--r); color: var(--ink); }
.toc a:hover { background: var(--btn-hover); text-decoration: none; }
.toc a.on { background: var(--bg-3); font-weight: 600; box-shadow: inset 2px 0 0 var(--tab); }
.md { font-size: 16px; line-height: 1.6; color: var(--ink); max-width: 860px; }
.md h1 { margin: 0 0 16px; padding-bottom: .3em; font-size: 2em; font-weight: 600; line-height: 1.25; border-bottom: 1px solid var(--rule); }
.md h2 { margin: 32px 0 16px; padding-bottom: .3em; font-size: 1.5em; font-weight: 600; line-height: 1.25; border-bottom: 1px solid var(--rule); scroll-margin-top: 130px; }
.md h3 { margin: 24px 0 12px; font-size: 1.25em; font-weight: 600; }
.md p, .md ul, .md ol, .md table, .md blockquote { margin: 0 0 16px; }
.md ul, .md ol { padding-left: 2em; }
.md li + li { margin-top: .25em; }
.md code { padding: .2em .4em; border-radius: var(--r); background: var(--counter); font-size: 85%; }
.md pre { padding: 16px; border-radius: var(--r); background: var(--bg-3); overflow: auto; font: 85%/1.45 var(--mono); margin: 0 0 16px; }
.md pre code { background: none; padding: 0; font-size: 100%; }
.md table { border-collapse: collapse; display: block; overflow: auto; }
.md th, .md td { padding: 6px 13px; border: 1px solid var(--rule-2); font-size: 14px; }
.md th { font-weight: 600; background: var(--bg-3); }
.md tr:nth-child(2n) td { background: color-mix(in srgb, var(--bg-3) 50%, transparent); }
.md blockquote { padding: 0 1em; color: var(--ink-2); border-left: .25em solid var(--rule-2); }
.md .note { padding: 8px 16px; border-left: .25em solid var(--link); margin-bottom: 16px; }
.md .note.warn { border-color: var(--warn); }
.md .note b:first-child { display: flex; align-items: center; gap: 8px; color: var(--link); margin-bottom: 4px; }
.md .note.warn b:first-child { color: var(--warn); }
.md .cta { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 16px; }

/* =====================================================================================================
   Phones and tablets
   ===================================================================================================== */
@media (max-width: 1012px) {
  .layout, .term, .lp { grid-template-columns: minmax(0, 1fr); }
  .side, .term-side { position: static; }
  .guide { grid-template-columns: minmax(0, 1fr); }
  .toc { position: static; display: flex; flex-wrap: wrap; gap: 4px; padding-bottom: 12px; border-bottom: 1px solid var(--rule-2); }
  .toc a { padding: 4px 10px; border: 1px solid var(--rule-2); border-radius: 2em; font-size: 13px; }
  .toc a.on { box-shadow: none; }
}
@media (max-width: 768px) {
  .hd-search { display: none; }
  .hd-row { gap: 8px; }
  .hd-crumb { flex: 1; }
  .page { padding-top: 16px; }
  .page-h h1 { font-size: 20px; }
  .mk-h { display: none; }
  .mk-r { grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; }
  .mk-r .mk-v.hide-m { display: none; }
  .mk-r .mk-act { display: none; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stats > div { border-left: 0; border-top: 1px solid var(--rule); }
  .stats > div:nth-child(-n+2) { border-top: 0; }
  .stats > div:nth-child(2n) { border-left: 1px solid var(--rule); }
  .stats > div:nth-child(5) { grid-column: 1 / -1; }
  .chart { height: 300px; }
  .tl-h, .tl-r { grid-template-columns: 58px 40px minmax(0, 1fr) 72px; }
  .tl-h .w, .tl-r .w { display: none; }
  .cn-price { text-align: left; width: 100%; }
  .buybar { display: flex; position: fixed; z-index: 25; left: 0; right: 0; bottom: 0; gap: 8px; padding: 10px var(--gut-r) calc(10px + env(safe-area-inset-bottom, 0px)) var(--gut); background: var(--bg-inset); border-top: 1px solid var(--rule-2); }
  .buybar .btn { flex: 1; height: 44px; font-size: 15px; }
  body.coin-page { padding-bottom: 72px; }
  .lp-form { grid-template-columns: 96px minmax(0, 1fr); }
  .lp-form canvas { width: 96px; height: 96px; }
  .msg.up { grid-template-columns: 32px minmax(0, 1fr); gap: 8px; }
  .av { width: 32px; height: 32px; } .av .mark { width: 18px; height: 18px; }
  .thread::before { left: 15px; }
  .msg.up .body::before { display: none; }
  .msg.up .txt, .who { padding-left: 12px; padding-right: 12px; }
  .msg.up .cards, .result { padding-left: 12px; padding-right: 12px; }
  .intro h1 { font-size: 18px; }
  .md { font-size: 15px; }
}
@media (max-width: 520px) {
  .tab { padding: 0 6px; font-size: 13px; }
  .tab svg { display: none; }
  .tab .counter { display: none; }
  .hd-acts .pill .lbl { display: none; }
  .hd-acts .btn .lbl { display: none; }
  .msg.up { grid-template-columns: minmax(0, 1fr); }
  .msg.up .av { display: none; }
  .thread::before { display: none; }
  .toolbar .sel { display: none; }
  .send .lbl { display: none; }
  .send { padding: 0 12px; }
  .seg button { padding: 0 10px; font-size: 13px; }
  .lp-form { grid-template-columns: minmax(0, 1fr); }
  .lp-form canvas { width: 120px; height: 120px; }
}
@media (max-width: 360px) {
  .hd-brand span { display: none; }
}

/* every graph is a box in the timeline: a header row, the stage, then the result */
.msg.trace { border: 1px solid var(--rule-2); border-radius: var(--r); background: var(--bg-2); overflow: hidden; }
.msg.trace > .who { border-radius: 0; }
.msg.trace .stage { border: 0; border-radius: 0; border-bottom: 1px solid var(--rule-2); }
.msg.trace .result { padding: 12px 16px 0; }
.msg.trace .result:has(.follow:last-child) { padding-bottom: 0; }
.msg.trace.showcase .stage { height: 330px; }
@media (max-width: 768px) { .msg.trace .result { padding: 12px 12px 0; } }
.msg.trace { width: auto; align-self: stretch; }
.st-status { flex: 1; min-width: 0; overflow: hidden; }
.st-acts { flex: none; }
@media (max-width: 768px) {
  .intro p { display: none; }
  .intro h1 { font-size: 17px; }
  .chips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-right: calc(-1 * var(--gut-r)); padding-right: var(--gut-r); }
  .chips::-webkit-scrollbar { display: none; }
  .chip { flex: none; }
}
@media (max-width: 520px) {
  #xLink { display: none; }
  .hd-acts .pill.me .lbl { display: inline; }
  .hd-acts { gap: 6px; }
}
.term-main, .term-side, .term-side > *, .about .box-b > *, .trade-b > * { min-width: 0; }
.lp > *, .layout > *, .guide > * { min-width: 0; }
/* phones: the trade panel right under the chart */
@media (max-width: 1012px) {
  .term { display: flex; flex-direction: column; gap: 16px; }
  .term-main, .term-side { display: contents; }
  .chart-box { order: 1; }
  #trade { order: 2; }
  .term-main > section + section { order: 3; margin-top: 0 !important; }
  #about { order: 4; }
}
.repo-card .rn svg, .about .repo svg { width: 16px; height: 16px; color: var(--ink-2); flex: none; }
.repo-card .rn a { color: var(--link); }
@media (max-width: 768px) { .chart .ch-tip span:nth-child(2), .chart .ch-tip span:nth-child(3), .chart .ch-tip span:nth-child(4) { display: none; } }
.msg.trace { grid-template-columns: minmax(0, 1fr); }
.msg.trace .stage { width: 100%; }

/* ---------- 4.1: a trial, laid out: icon · what to do + reward · the button ---------- */
.q-task { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; align-items: center; gap: 12px 14px; }
.q-task > div { min-width: 0; }
.q-ico { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--rule-2); background: var(--bg-3); color: var(--ink); }
.q-ico svg { width: 16px; height: 16px; }
.q-ico.gh svg { width: 18px; height: 18px; }
.quest-card.done .q-ico { border-color: color-mix(in srgb, var(--acc) 45%, var(--rule-2)); color: var(--acc); }
.q-title { font-size: 15px; font-weight: 600; line-height: 1.35; overflow-wrap: anywhere; }
.q-reward { margin-top: 4px; font: 500 13px/1.3 var(--mono); }
.q-reward span { font-family: var(--sans); font-weight: 400; font-size: 12px; }
.q-task .q-btn { min-width: 132px; height: 36px; }
.q-hint { margin: 0; font-size: 12px; color: var(--ink-3); }
.q-opt { display: inline-flex; align-items: center; height: 18px; padding: 0 7px; margin-left: 8px; border-radius: 999px; border: 1px solid var(--rule-2); color: var(--ink-2); font: 500 11px/1 var(--sans); vertical-align: 2px; }
@media (max-width: 640px) {
  .q-task { grid-template-columns: 32px minmax(0, 1fr); }
  .q-ico { width: 32px; height: 32px; }
  .q-task .q-btn { grid-column: 1 / -1; width: 100%; height: 40px; }
}

/* ---------- 4.1: $FORK on the home page — what you earn, and where you stand ---------- */
.earn { margin: 0 0 16px; border: 1px solid color-mix(in srgb, var(--warn) 42%, var(--rule-2)); border-radius: var(--r); background: linear-gradient(180deg, var(--warn-soft), transparent 75%), var(--bg-2); overflow: hidden; animation: rise .5s var(--ease) both; }
.earn-top { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 14px 24px; padding: 18px 20px 16px; }
.earn-k { display: flex; align-items: center; gap: 8px; margin: 0; font: 500 12px/1 var(--mono); color: var(--warn); }
.earn-k svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.1; stroke-linecap: round; }
.earn-k .label { margin-left: 2px; }
.earn-big { margin: 10px 0 6px; font: 700 clamp(30px, 6vw, 46px)/1 var(--mono); letter-spacing: -.02em; color: var(--ink); font-variant-numeric: tabular-nums; }
.earn-big .tk { margin-left: 8px; font-size: .46em; font-weight: 600; letter-spacing: 0; color: var(--warn); }
.earn-big .pre { margin-right: 8px; font-size: .42em; font-weight: 500; letter-spacing: 0; color: var(--ink-2); vertical-align: .35em; }
.earn-sub { margin: 0; color: var(--ink-2); max-width: 62ch; }
.earn-who { display: inline-flex; align-items: center; gap: 8px; color: var(--ink); font-weight: 600; }
.earn-who img, .earn-who .ini { width: 20px; height: 20px; border-radius: 50%; }
.earn-who .ini { display: inline-grid; place-items: center; background: var(--bg-3); border: 1px solid var(--rule-2); font: 600 11px var(--mono); }
.earn-cta { display: grid; justify-items: end; gap: 6px; }
.earn-cta .btn { height: 40px; padding: 0 20px; font-size: 15px; font-weight: 600; }
.earn-cta .btn svg { width: 16px; height: 16px; }
.earn-cta small { font-size: 12px; color: var(--ink-3); }
.earn-prog { display: flex; align-items: center; gap: 10px; margin-top: 10px; font: 12px var(--mono); color: var(--ink-2); }
.earn-prog .bar { flex: 1; max-width: 260px; height: 6px; border-radius: 3px; background: var(--rule); overflow: hidden; }
.earn-prog .bar i { display: block; height: 100%; width: 0; border-radius: 3px; background: var(--warn); transition: width .8s var(--ease); }
.earn-steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--rule); }
.earn-s { position: relative; display: grid; align-content: start; gap: 3px; min-width: 0; padding: 12px 16px 14px; border: 0; border-left: 1px solid var(--rule); background: transparent; color: inherit; font: inherit; text-align: left; cursor: pointer; transition: background .12s; }
.earn-s:first-child { border-left: 0; }
.earn-s:hover { background: var(--bg-3); }
.earn-s:active { transform: translateY(1px); }
.earn-s b { font: 600 18px/1.25 var(--mono); color: var(--warn); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.earn-s .t { font-size: 13px; font-weight: 600; color: var(--ink); }
.earn-s small { font-size: 12px; line-height: 1.4; color: var(--ink-3); }
.earn-s .opt { position: absolute; top: 12px; right: 12px; height: 18px; padding: 0 7px; border-radius: 999px; border: 1px solid var(--rule-2); font: 500 11px/16px var(--sans); color: var(--ink-2); }
.earn-s.ok b { color: var(--acc); }
.earn-s.ok b::before { content: '✓ '; }
.earn-fine { margin: 0; padding: 8px 20px; border-top: 1px solid var(--rule); background: var(--bg-3); font-size: 11.5px; color: var(--ink-3); }
.earn.closed .earn-steps, .earn.closed .earn-cta { opacity: .55; pointer-events: none; }
@media (max-width: 768px) {
  .earn-top { grid-template-columns: minmax(0, 1fr); padding: 16px; }
  .earn-cta { justify-items: stretch; }
  .earn-cta .btn { width: 100%; }
  .earn-cta small { text-align: center; }
  .earn-steps { grid-template-columns: 1fr 1fr; }
  .earn-s:nth-child(3) { border-left: 0; }
  .earn-s:nth-child(n+3) { border-top: 1px solid var(--rule); }
  .earn-s { padding: 11px 14px 12px; }
  .earn-s b { font-size: 16px; }
  .earn-fine { padding: 8px 16px; }
}
@media (prefers-reduced-motion: reduce) { .earn, .earn-prog .bar i { animation: none; transition: none; } }
.earn-steps.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 768px) { .earn-steps.three .earn-s:nth-child(3) { grid-column: 1 / -1; } }
.q-task .q-btn svg, .earn-cta .btn svg { width: 15px; height: 15px; flex: none; }
/* phones: the $FORK box stays big where it counts (the number, the button) and leaves room for the graph */
@media (max-width: 640px) {
  .earn-top { gap: 10px; padding: 14px 14px 12px; }
  .earn-big { margin: 8px 0 2px; }
  .earn-sub { display: none; }
  .earn-cta small { display: none; }
  .earn-prog { margin-top: 6px; }
  .earn-steps, .earn-steps.three { grid-template-columns: 1fr 1fr; }
  .earn-s, .earn-steps.three .earn-s { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 7px; padding: 8px 12px; border-top: 0; }
  .earn-s:nth-child(odd) { border-left: 0; }
  .earn-s:nth-child(n+3) { border-top: 1px solid var(--rule); }
  .earn-steps.three .earn-s:nth-child(3) { grid-column: 1 / -1; }
  .earn-s small { display: none; }
  .earn-s b { font-size: 14.5px; }
  .earn-s .t { font-size: 12.5px; font-weight: 500; color: var(--ink-2); }
  .earn-s .opt { position: static; order: 3; height: 16px; padding: 0 6px; font-size: 10px; line-height: 14px; }
  .earn-fine { padding: 6px 14px; font-size: 10.5px; }
  .earn-fine .long { display: none; }
}
@media (min-width: 641px) { .earn-fine .short { display: none; } }
.pt-i { width: 20px; height: 20px; flex: none; border-radius: 50%; overflow: hidden; display: inline-grid; place-items: center; background: var(--bg-3); border: 1px solid var(--rule); font: 600 10px var(--mono); color: var(--ink-2); }
.pt-i img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pt-coin { align-items: center; }
