/* AnyManager v4 · 唯一样式表
   字号 12 / 13 / 14 / 16 / 28 / 48 / 84；圆角 6 / 10 / 14；内容宽 1200。
   金 = AgentRouter，绿 = AnyRouter，余烬 = 花掉的；琥珀只给「要你处理」，红只给「坏了」，灰 = 等待中。 */

:root {
  --font: "Avenir Next", "PingFang SC", -apple-system, BlinkMacSystemFont, "Helvetica Neue", sans-serif;
  --display: "Futura", "Futura PT", "Avenir Next", "PingFang SC", sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, monospace;
  --w: 1200px; --r1: 6px; --r2: 10px; --r3: 14px;

  --bg: #f4f0e7; --surface: #fcfaf5; --sunk: #ede7da; --line: #e3dac7; --line-2: #cdc1a4;
  --text: #221e17; --muted: #6b6352; --dim: #9a907a;
  --ar: #a8741c; --ar-hi: #7a530f; --any: #3f8a5a; --any-hi: #2b6a42; --ember: #c4502e;
  --amber: #b0700f; --red: #b8402d; --ok: #3f8a5a;
  --s1: #a8741c; --s2: #3f8a5a; --s3: #c4502e; --s4: #4f7fb8; --s5: #8a63b5; --s6: #b0a283;
  --on-ar: #fff; --scrim: rgba(40, 30, 10, .28); --shadow: 0 12px 40px rgba(60, 45, 15, .16);
  color-scheme: light;
}
:root.night {
  --bg: #13110d; --surface: #1b1813; --sunk: #232019; --line: #2d271e; --line-2: #463c2c;
  --text: #efe6d3; --muted: #a69a82; --dim: #6e6553;
  --ar: #e2b25a; --ar-hi: #ffd88a; --any: #6fbf8a; --any-hi: #a9e3bb; --ember: #f0704a;
  --amber: #e0a548; --red: #ee6b52; --ok: #6fbf8a;
  --s1: #e2b25a; --s2: #6fbf8a; --s3: #f0704a; --s4: #7fa8d8; --s5: #b393d3; --s6: #6e6553;
  --on-ar: #1b1408; --scrim: rgba(0, 0, 0, .5); --shadow: 0 16px 48px rgba(0, 0, 0, .5);
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not(.day) {
    --bg: #13110d; --surface: #1b1813; --sunk: #232019; --line: #2d271e; --line-2: #463c2c;
    --text: #efe6d3; --muted: #a69a82; --dim: #6e6553;
    --ar: #e2b25a; --ar-hi: #ffd88a; --any: #6fbf8a; --any-hi: #a9e3bb; --ember: #f0704a;
    --amber: #e0a548; --red: #ee6b52; --ok: #6fbf8a;
    --s1: #e2b25a; --s2: #6fbf8a; --s3: #f0704a; --s4: #7fa8d8; --s5: #b393d3; --s6: #6e6553;
    --on-ar: #1b1408; --scrim: rgba(0, 0, 0, .5); --shadow: 0 16px 48px rgba(0, 0, 0, .5);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text); }
body { font: 14px/1.55 var(--font); -webkit-font-smoothing: antialiased; font-variant-numeric: tabular-nums; min-height: 100vh; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
h1, h2, h3, p { margin: 0; }
.num { font-family: var(--display); font-weight: 500; }
.mono { font-family: var(--mono); font-size: 13px; }
.m { color: var(--muted); }
.d { color: var(--dim); }
.c-ar { color: var(--ar); } .c-any { color: var(--any); } .c-ember { color: var(--ember); }
.c-amber { color: var(--amber); } .c-red { color: var(--red); } .c-ok { color: var(--ok); } .c-hi { color: var(--ar-hi); }
.lnk { color: var(--ar); cursor: pointer; }
.lnk:hover { text-decoration: underline; text-underline-offset: 3px; }
.hide { display: none !important; }

/* ---------- 框架 ---------- */
.frame { max-width: calc(var(--w) + 64px); margin: 0 auto; padding: 0 32px; }
.top { border-bottom: 1px solid var(--line); background: var(--bg); position: sticky; top: 0; z-index: 20; }
.top .frame { display: flex; align-items: center; height: 64px; gap: 40px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ar); }
.brand svg { width: 47px; height: 22px; display: block; }
.brand span { font: 500 16px var(--display); letter-spacing: .01em; color: var(--text); }
.nav { display: flex; gap: 4px; height: 100%; }
.nav a { position: relative; display: flex; align-items: center; padding: 0 14px; color: var(--muted); font-size: 14px; }
.nav a:hover { color: var(--text); }
.nav a.on { color: var(--text); font-weight: 500; }
.nav a.on:after { content: ""; position: absolute; left: 14px; right: 14px; bottom: -1px; height: 2px; border-radius: 2px; background: var(--ar); }
.top .r { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.sys { display: flex; align-items: center; gap: 8px; height: 32px; padding: 0 12px; border-radius: var(--r2); color: var(--muted); font-size: 13px; }
.sys:hover, .sys.on { background: var(--sunk); color: var(--text); }
.ib { width: 32px; height: 32px; display: grid; place-items: center; border-radius: var(--r2); color: var(--muted); }
.ib:hover, .ib.on { background: var(--sunk); color: var(--text); }
.ib svg { width: 18px; height: 18px; }
main.frame { padding-bottom: 96px; }

/* 页头：标题 + 一句话 + 主动作 + ⋯ */
.ph { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; padding: 40px 0 28px; }
.ph h1 { font: 500 28px/1.15 var(--display); letter-spacing: -.01em; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.ph .sum { margin-top: 10px; color: var(--muted); }
.ph .sum b { color: var(--text); font-weight: 500; }
.ph .act { display: flex; align-items: center; gap: 8px; flex: none; }
.back { display: inline-flex; gap: 6px; margin-top: 28px; color: var(--muted); font-size: 13px; }
.back:hover { color: var(--text); }
.back + .ph { padding-top: 12px; }

/* ---------- 块 ---------- */
.stack > * + * { margin-top: 24px; }
.g2 { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.g3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.g21 { display: grid; grid-template-columns: 1.6fr 1fr; gap: 24px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r3); padding: 24px; min-width: 0; }
.card.flush { padding: 0; overflow: hidden; }
.card.flush > .ch { padding: 20px 24px 12px; }
.ch { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; min-height: 30px; }
.ch h2 { font-size: 16px; font-weight: 600; }
.ch .r { margin-left: auto; display: flex; align-items: center; gap: 12px; color: var(--dim); font-size: 13px; }
.cap { font: 500 12px var(--display); letter-spacing: .12em; text-transform: uppercase; color: var(--dim); }
.note { color: var(--dim); font-size: 13px; }
.sep { height: 1px; background: var(--line); margin: 20px 0; }

/* 数字 */
.stats { display: grid; grid-template-columns: repeat(var(--n, 4), 1fr); }
.stat { padding: 0 24px; border-left: 1px solid var(--line); min-width: 0; }
.stat:first-child { padding-left: 0; border-left: 0; }
.stat .v { font: 500 28px/1 var(--display); margin-top: 12px; white-space: nowrap; }
.stat .v small { font-size: 16px; color: var(--muted); margin-left: 4px; }
.stat .s { margin-top: 10px; font-size: 13px; color: var(--dim); line-height: 1.6; }
.stat .s b { color: var(--muted); font-weight: 500; }
.big { font: 500 48px/1 var(--display); letter-spacing: -.01em; }
.big small { font-size: 28px; }
.big.md { font-size: 28px; }

/* 标签与点 */
.tag { display: inline-flex; align-items: center; gap: 4px; height: 20px; padding: 0 7px; border-radius: var(--r1); font-size: 12px; line-height: 1; white-space: nowrap;
  color: var(--muted); background: var(--sunk); font-weight: 400; vertical-align: 2px; }
.tag.ar { color: var(--ar); background: color-mix(in srgb, var(--ar) 14%, transparent); }
.tag.any { color: var(--any); background: color-mix(in srgb, var(--any) 14%, transparent); }
.tag.amber { color: var(--amber); background: color-mix(in srgb, var(--amber) 14%, transparent); }
.tag.red { color: var(--red); background: color-mix(in srgb, var(--red) 13%, transparent); }
.tag.ember { color: var(--ember); background: color-mix(in srgb, var(--ember) 13%, transparent); }
.tag.line { background: none; box-shadow: inset 0 0 0 1px var(--line-2); }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--dim); flex: none; }
.dot.ok { background: var(--ok); } .dot.amber { background: var(--amber); } .dot.red { background: var(--red); }
.dot.ar { background: var(--ar); } .dot.any { background: var(--any); }
.dot.use { background: var(--ember); box-shadow: 0 0 0 0 color-mix(in srgb, var(--ember) 60%, transparent); animation: pulse 1.8s infinite; }
.dot.hollow { background: none; box-shadow: inset 0 0 0 1.5px var(--dim); }
@keyframes pulse { 70% { box-shadow: 0 0 0 6px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }

/* 按钮 */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: var(--r2);
  border: 1px solid var(--line-2); background: var(--surface); color: var(--text); font-size: 14px; font-weight: 500; white-space: nowrap; transition: background .12s, border-color .12s; }
.btn:hover { border-color: var(--dim); }
.btn.pri { background: var(--ar); border-color: var(--ar); color: var(--on-ar); }
.btn.pri:hover { filter: brightness(1.06); }
.btn.ghost { border-color: transparent; background: none; color: var(--muted); }
.btn.ghost:hover { background: var(--sunk); color: var(--text); }
.btn.danger { color: var(--red); border-color: color-mix(in srgb, var(--red) 40%, transparent); background: none; }
.btn.danger.solid { background: var(--red); color: #fff; border-color: var(--red); }
.btn.sm { height: 30px; padding: 0 10px; font-size: 13px; }
.btn.more { width: 36px; padding: 0; font-size: 16px; letter-spacing: 1px; }
.btn.sm.more { width: 30px; }
.btn[disabled] { opacity: .45; pointer-events: none; }
.btn svg { width: 16px; height: 16px; }

/* 分段 */
.seg { display: inline-flex; padding: 3px; gap: 2px; background: var(--sunk); border-radius: var(--r2); flex: none; }
.seg button { height: 28px; padding: 0 12px; border-radius: var(--r1); font-size: 13px; color: var(--muted); white-space: nowrap; }
.seg button:hover { color: var(--text); }
.seg button.on { background: var(--surface); color: var(--text); font-weight: 500; box-shadow: 0 1px 2px rgba(0, 0, 0, .12); }
.seg button b { font-weight: 400; color: var(--dim); margin-left: 6px; }
.seg.wide { display: flex; } .seg.wide button { flex: 1; }

/* 列表 */
.tbl { --cols: 1fr; }
.tr { display: grid; grid-template-columns: var(--cols); align-items: center; gap: 16px; min-height: 56px; padding: 8px 24px; border-top: 1px solid var(--line); }
.tr.th { min-height: 40px; padding-top: 0; padding-bottom: 0; color: var(--dim); font-size: 12px; border-top: 0; }
.tbl > .tr:first-child:not(.th) { border-top: 0; }
.tr.go { cursor: pointer; transition: background .1s; }
.tr.go:hover { background: color-mix(in srgb, var(--sunk) 70%, transparent); }
.tr .r, .tr.th .r { text-align: right; justify-self: end; }
.tr .nm { font-weight: 500; }
.tr .sub { font-size: 13px; color: var(--dim); margin-top: 2px; }
.tr.off { color: var(--dim); }
.tr.off .nm { color: var(--muted); font-weight: 400; }
.tr .hov { opacity: 0; transition: opacity .12s; display: flex; gap: 4px; justify-content: flex-end; }
.tr:hover .hov, .tr .hov:focus-within, .tr .hov.keep { opacity: 1; }
.grp { display: flex; align-items: center; gap: 12px; padding: 16px 24px 8px; border-top: 1px solid var(--line); }
.grp:first-child { border-top: 0; }
.grp b { font-size: 13px; font-weight: 600; }
.grp span { font-size: 13px; color: var(--dim); }
.grp .r { margin-left: auto; }
.bar { height: 4px; border-radius: 2px; background: var(--line); overflow: hidden; }
.bar i { display: block; height: 100%; border-radius: 2px; background: var(--ar); }
.empty { padding: 40px 24px; text-align: center; color: var(--dim); }

/* 折叠 */
details.fold > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 12px; }
details.fold > summary::-webkit-details-marker { display: none; }
details.fold > summary .chev { width: 16px; height: 16px; color: var(--dim); transition: transform .15s; flex: none; }
details.fold[open] > summary .chev { transform: rotate(90deg); }
.foldrow > summary { padding: 16px 24px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; }
.foldrow > summary:hover { color: var(--text); }

/* 横幅 */
.banner { display: flex; align-items: center; gap: 14px; padding: 14px 18px; border-radius: var(--r2); font-size: 14px;
  border: 1px solid color-mix(in srgb, var(--c) 35%, transparent); background: color-mix(in srgb, var(--c) 9%, transparent); --c: var(--amber); }
.banner.red { --c: var(--red); }
.banner .dot { background: var(--c); }
.banner b { font-weight: 600; }
.banner .r { margin-left: auto; display: flex; gap: 8px; }

/* 表单 */
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > label, .field > .lb { font-size: 13px; color: var(--muted); }
.field .hint { font-size: 12px; color: var(--dim); }
.in, select.in, textarea.in { width: 100%; height: 38px; padding: 0 12px; border-radius: var(--r2); border: 1px solid var(--line-2); background: var(--surface);
  color: var(--text); font: 14px var(--font); outline: none; transition: border-color .12s, box-shadow .12s; }
textarea.in { height: auto; min-height: 120px; padding: 10px 12px; line-height: 1.5; resize: vertical; }
.in:focus { border-color: var(--ar); box-shadow: 0 0 0 3px color-mix(in srgb, var(--ar) 18%, transparent); }
.in.mono { font-family: var(--mono); font-size: 13px; }
.in.sm { height: 32px; font-size: 13px; }
.pair { display: flex; align-items: center; gap: 8px; }
.pair .in { flex: 1; }
.pair > span { color: var(--dim); }
.fields { display: grid; grid-template-columns: repeat(var(--fc, 2), 1fr); gap: 18px 20px; }
.fields .full { grid-column: 1 / -1; }
.sw { position: relative; width: 36px; height: 20px; border-radius: 10px; background: var(--line-2); flex: none; transition: background .15s; }
.sw:after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform .15s; box-shadow: 0 1px 2px rgba(0, 0, 0, .25); }
.sw.on { background: var(--ar); }
.sw.on:after { transform: translateX(16px); }
.swrow { display: flex; align-items: center; gap: 12px; cursor: pointer; }
.swrow .t { flex: 1; }
.swrow .t div:first-child { font-size: 14px; }
.swrow .t .hint { font-size: 12px; color: var(--dim); margin-top: 2px; }

/* 键值 */
.kv { display: grid; grid-template-columns: 96px 1fr; gap: 10px 16px; font-size: 14px; }
.kv dt { color: var(--dim); font-size: 13px; padding-top: 1px; }
.kv dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }

/* ---------- 浮层 ---------- */
.pop { position: fixed; min-width: 220px; max-width: 320px; padding: 6px; background: var(--surface); border: 1px solid var(--line-2); border-radius: var(--r2);
  box-shadow: var(--shadow); z-index: 60; animation: popin .12s ease-out; }
@keyframes popin { from { opacity: 0; transform: translateY(-4px); } }
.mi { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; border-radius: var(--r1); text-align: left; font-size: 14px; }
.mi:hover { background: var(--sunk); }
.mi .k { margin-left: auto; font-size: 12px; color: var(--dim); white-space: nowrap; }
.mi.danger { color: var(--red); }
.mi .sub { display: block; font-size: 12px; color: var(--dim); margin-top: 1px; }
.msep { height: 1px; background: var(--line); margin: 6px 4px; }
.mhead { padding: 8px 10px 4px; font-size: 12px; color: var(--dim); }

.scrim { position: fixed; inset: 0; background: var(--scrim); z-index: 40; opacity: 0; transition: opacity .2s; }
.scrim.on { opacity: 1; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(540px, 100vw); background: var(--bg); border-left: 1px solid var(--line-2); z-index: 50;
  display: flex; flex-direction: column; transform: translateX(100%); transition: transform .22s cubic-bezier(.2, .7, .2, 1); box-shadow: var(--shadow); }
.drawer.on { transform: none; }
.drawer.wide { width: min(760px, 100vw); }
.dw-h { padding: 24px 28px 20px; border-bottom: 1px solid var(--line); display: flex; gap: 16px; align-items: flex-start; }
.dw-h h2 { font: 600 16px/1.4 var(--font); display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.dw-h .sub { margin-top: 6px; color: var(--muted); font-size: 13px; }
.dw-h .x { margin-left: auto; }
.dw-b { flex: 1; overflow: auto; padding: 24px 28px 32px; }
.dw-b > section + section { margin-top: 28px; }
.dw-b h3 { font-size: 13px; font-weight: 600; color: var(--muted); margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
.dw-b h3 .r { margin-left: auto; font-weight: 400; color: var(--dim); }
.dw-f { padding: 16px 28px; border-top: 1px solid var(--line); display: flex; gap: 8px; align-items: center; }
.dw-f .sp { flex: 1; }
.box { border: 1px solid var(--line); border-radius: var(--r2); background: var(--surface); padding: 16px 18px; }

.modal { position: fixed; left: 50%; top: 28vh; transform: translateX(-50%); width: min(420px, calc(100vw - 32px)); z-index: 70; background: var(--surface);
  border: 1px solid var(--line-2); border-radius: var(--r3); box-shadow: var(--shadow); padding: 24px; animation: popin .14s ease-out; }
.modal h3 { font-size: 16px; font-weight: 600; }
.modal p { margin-top: 10px; color: var(--muted); }
.modal .acts { display: flex; justify-content: flex-end; gap: 8px; margin-top: 24px; }

.toast { position: fixed; left: 50%; bottom: 32px; transform: translate(-50%, 12px); opacity: 0; z-index: 80; display: flex; align-items: center; gap: 12px;
  max-width: min(720px, calc(100vw - 32px)); padding: 11px 10px 11px 16px; border-radius: var(--r2); background: var(--text); color: var(--bg); font-size: 14px;
  box-shadow: var(--shadow); transition: .2s; pointer-events: none; }
.toast.on { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.toast .tm { white-space: pre-line; max-height: 40vh; overflow: auto; line-height: 1.55; }
.toast small { font-family: var(--mono); font-size: 12px; opacity: .55; }
.toast .btn { flex: none; background: transparent; color: inherit; border-color: color-mix(in srgb, var(--bg) 35%, transparent); }
.toast .tx { flex: none; width: 26px; height: 26px; color: inherit; opacity: .5; }
.toast .tx:hover { opacity: 1; background: transparent; }
.toast .tx svg { width: 14px; height: 14px; }
.toast.red { background: var(--red); color: #fff; }
.toast.amber { background: var(--amber); color: #1b1408; }
.toast.busy .tm::before { content: ""; display: inline-block; width: 10px; height: 10px; margin-right: 10px; border-radius: 50%; border: 2px solid currentColor;
  border-right-color: transparent; vertical-align: -1px; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.tip { position: fixed; z-index: 65; pointer-events: none; padding: 10px 12px; border-radius: var(--r2); background: var(--surface); border: 1px solid var(--line-2);
  box-shadow: var(--shadow); font-size: 13px; min-width: 180px; opacity: 0; transition: opacity .1s; }
.tip.on { opacity: 1; }
.tip b { font-weight: 600; }
.tip .row { display: flex; justify-content: space-between; gap: 16px; margin-top: 4px; color: var(--muted); }
.tip .row span:last-child { color: var(--text); font-family: var(--display); }
.tip .row i { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 6px; }

.demo { position: fixed; left: 16px; bottom: 16px; z-index: 30; display: flex; gap: 10px; align-items: center; padding: 6px 12px; border-radius: var(--r2);
  background: var(--surface); border: 1px dashed var(--line-2); font-size: 12px; color: var(--dim); }
.demo a { color: var(--muted); }
.demo a:hover { color: var(--text); }

/* ---------- 图表 ---------- */
.chart { width: 100%; height: auto; display: block; overflow: visible; }
.chart text { font: 500 12px var(--display); fill: var(--dim); }
.chart .grid line { stroke: var(--line); stroke-dasharray: 2 4; }
.chart .axis { stroke: var(--line-2); }
.legend { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 13px; color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 7px; cursor: default; }
.legend i { width: 10px; height: 10px; border-radius: 3px; }
.legend b { font-family: var(--display); font-weight: 500; color: var(--text); }

/* 排行 */
.rank { display: flex; flex-direction: column; }
.ri { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; padding: 10px 12px; margin: 0 -12px; border-radius: var(--r2); cursor: pointer; transition: background .1s; }
.ri:hover { background: var(--sunk); }
.ri.on { background: color-mix(in srgb, var(--ar) 12%, transparent); }
.ri.dim { opacity: .4; }
.ri .n { font-weight: 500; display: flex; align-items: center; gap: 8px; min-width: 0; }
.ri .n span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ri .v { font: 500 14px var(--display); text-align: right; }
.ri .bar { grid-column: 1 / -1; margin-top: 6px; }
.ri .s { font-size: 12px; color: var(--dim); }
.ri .p { font-size: 12px; color: var(--dim); text-align: right; }

/* 热力 */
.heat { display: grid; grid-template-columns: 28px repeat(24, 1fr); gap: 3px; font: 500 12px var(--display); color: var(--dim); }
.heat i { aspect-ratio: 1.5; border-radius: 3px; background: var(--sunk); }
.heat span { display: flex; align-items: center; }
.heat .hx { text-align: center; padding-top: 4px; }

/* 健康 */
.checks { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; }
.ck { padding: 14px 16px; border-radius: var(--r2); background: var(--sunk); min-width: 0; }
.ck .h { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; }
.ck .s { margin-top: 6px; font-size: 13px; color: var(--muted); line-height: 1.5; }

/* 时间线（身份轨迹 / 换 Key 历史） */
.tline { position: relative; padding-left: 22px; }
.tline:before { content: ""; position: absolute; left: 5px; top: 8px; bottom: 8px; width: 2px; border-radius: 1px; background: var(--line-2); }
.tl-i { position: relative; padding: 6px 0 14px; }
.tl-i:last-child { padding-bottom: 0; }
.tl-i:before { content: ""; position: absolute; left: -21px; top: 12px; width: 10px; height: 10px; border-radius: 50%; background: var(--bg); box-shadow: inset 0 0 0 2px var(--line-2); }
.tl-i.now:before { background: var(--ar); box-shadow: 0 0 0 4px color-mix(in srgb, var(--ar) 20%, transparent); }
.tl-i .t { font-size: 12px; color: var(--dim); }
.tl-i .w { margin-top: 2px; }
.tl-i .w .d { font-size: 13px; }

/* 一次性令牌 */
.once { display: flex; align-items: center; gap: 12px; padding: 16px 18px; border-radius: var(--r2); background: color-mix(in srgb, var(--ar) 10%, transparent);
  border: 1px solid color-mix(in srgb, var(--ar) 35%, transparent); }
.once code { flex: 1; font: 500 14px var(--mono); overflow-wrap: anywhere; color: var(--ar-hi); }

/* 设置页左侧目录 */
.side { display: grid; grid-template-columns: 200px 1fr; gap: 48px; align-items: start; }
.side nav { position: sticky; top: 104px; display: flex; flex-direction: column; gap: 2px; }
.side nav a { padding: 8px 12px; border-radius: var(--r2); color: var(--muted); font-size: 14px; }
.side nav a:hover { color: var(--text); background: var(--sunk); }
.side nav a.on { color: var(--text); background: var(--sunk); font-weight: 500; }
.side nav .sub { padding: 16px 12px 6px; font-size: 12px; color: var(--dim); }
.sect { scroll-margin-top: 96px; }
.sect .ch { margin-bottom: 6px; }
.sect .say { color: var(--muted); margin-bottom: 22px; }
.sect .say b { color: var(--text); font-weight: 500; }
.sect .foot { display: flex; align-items: center; gap: 12px; margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--line); }
.sect .foot .note { flex: 1; }
.sub-h { font-size: 13px; font-weight: 600; margin: 28px 0 14px; color: var(--muted); }
.sub-h:first-of-type { margin-top: 0; }
.rhythm { display: grid; grid-template-columns: 84px repeat(4, 1fr); gap: 10px 14px; align-items: center; font-size: 13px; }
.rhythm .h { color: var(--dim); font-size: 12px; }

/* 公告正文 */
.prose { font-size: 14px; line-height: 1.7; color: var(--muted); overflow-wrap: anywhere; }
.prose h4 { font-size: 14px; color: var(--text); margin: 0 0 6px; }
.prose p { margin: 0 0 8px; }
.prose p:last-child { margin-bottom: 0; }
.prose strong { color: var(--text); font-weight: 600; }
.prose hr { border: 0; height: 1px; background: var(--line); margin: 12px 0; }
.beats { display: flex; gap: 2px; height: 22px; margin-top: 12px; }
.beats i { flex: 1; border-radius: 2px; background: var(--ok); opacity: .75; }
.beats i.warn { background: var(--amber); opacity: 1; }
.beats i.bad, .beats i.severe { background: var(--red); opacity: 1; }
.beats i.none { background: var(--line); }
.chip { display: inline-flex; align-items: center; height: 26px; padding: 0 10px; border-radius: var(--r1); background: var(--sunk); font: 13px var(--mono); color: var(--muted); cursor: pointer; }
.chip:hover { color: var(--text); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }

/* 首页 */
.hero { display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: end; padding: 40px 0 32px; }
.hero .total { font: 500 84px/.95 var(--display); letter-spacing: -.02em; margin-top: 16px;
  background: linear-gradient(180deg, var(--text) -20%, var(--ar) 130%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero .total small { font-size: 48px; }
.split { margin-top: 24px; max-width: 560px; }
.split .bar { height: 8px; border-radius: 4px; display: flex; background: var(--line); }
.split .bar i { border-radius: 0; }
.split .lg { display: flex; justify-content: space-between; margin-top: 10px; font-size: 13px; color: var(--muted); }
.split .lg b { font: 500 16px var(--display); color: var(--text); margin-left: 6px; }
.split .lg .dot { border-radius: 2px; margin-right: 7px; vertical-align: 0; }
.tl-card { position: relative; background: linear-gradient(180deg, #15120d, #100e0a); border: 1px solid #2c261e; border-radius: var(--r3); padding: 22px 24px 10px; color: #f3ead9; overflow: hidden; }
.tl-card .ch h2 { font: 500 16px var(--display); letter-spacing: .02em; color: #f3ead9; }
.tl-card .ch .r { color: #867862; font-size: 12px; gap: 18px; }
.tl-card .ch .r i { display: inline-block; width: 18px; height: 3px; border-radius: 2px; margin-right: 6px; vertical-align: 3px; }
#tree { width: 100%; height: auto; display: block; }
#tree .trunk { stroke-width: 3; stroke-linecap: round; }
#tree .br { fill: none; stroke-linecap: round; }
#tree .br.main { stroke-width: 2.2; }
#tree .br.gain { stroke-width: 3.6; filter: drop-shadow(0 0 4px rgba(255, 216, 138, .55)); }
#tree .br.gift { stroke-width: 3.6; stroke: #fff1c9; filter: drop-shadow(0 0 6px rgba(255, 230, 160, .9)); }
#tree .br.burn { stroke: #f0704a; stroke-width: 2; stroke-dasharray: 2 5; opacity: .75; }
#tree .br.draw { stroke-dasharray: var(--len); stroke-dashoffset: var(--len); animation: draw 1.4s cubic-bezier(.2, .7, .2, 1) forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
#tree .br.burn.use { animation: flow 1s linear infinite; opacity: 1; }
@keyframes flow { to { stroke-dashoffset: -14; } }
#tree .lab { font: 500 12.5px var(--font); fill: #c0b198; }
#tree .amt { font: 500 13px var(--display); fill: #f3ead9; }
#tree .dimt { fill: #867862; font: 400 11px var(--font); }
#tree .tgrid line { stroke: #2c261e; stroke-dasharray: 2 6; }
#tree .tgrid text { fill: #5b5042; font: 500 10.5px var(--display); letter-spacing: .06em; }
#tree .pl .nm { font: 500 11px var(--display); letter-spacing: .2em; fill: #867862; }
#tree .pl .tot { font: 500 28px var(--display); }
#tree .pl .sub { font: 400 11.5px var(--font); fill: #867862; }
#tree .tip-use { animation: ring 1.6s ease-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes ring { 0% { opacity: .9; transform: scale(.6); } 100% { opacity: 0; transform: scale(2.4); } }
#tree .hit { fill: transparent; cursor: pointer; }
#tree .g-br { transition: opacity .2s; }
#tree.focus .g-br { opacity: .28; }
#tree.focus .g-br.hl { opacity: 1; }
.gift-bars { display: flex; gap: 6px; align-items: flex-end; height: 64px; margin-top: 20px; }
.gift-bars div { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 12px; color: var(--dim); font-family: var(--display); }
.gift-bars i { display: block; width: 100%; border-radius: 3px 3px 0 0; background: linear-gradient(180deg, var(--ar-hi), var(--ar)); }
.gift-bars div.last { color: var(--ar-hi); }
.lastb { margin-top: 16px; padding: 12px 14px; border-radius: var(--r2); font-size: 13px; color: var(--muted); background: color-mix(in srgb, var(--ar) 9%, transparent); }
.lastb b { color: var(--ar-hi); font-weight: 600; }
.lastb .chips { margin-top: 8px; }
.lastb .chips span { font-size: 12px; padding: 2px 8px; border-radius: var(--r1); background: var(--surface); color: var(--text); }
.lastb .chips em { font-style: normal; color: var(--ar-hi); margin-left: 5px; font-family: var(--display); }
.mx { width: 100%; border-collapse: collapse; font-size: 13px; }
.mx th { font: 500 12px var(--display); color: var(--dim); text-align: right; padding: 8px; border-bottom: 1px solid var(--line); }
.mx th:first-child, .mx td:first-child { text-align: left; }
.mx td { padding: 7px 8px; text-align: right; border-bottom: 1px solid var(--line); font-family: var(--display); }
.mx td:first-child { font-family: var(--font); color: var(--muted); }
.mx td.c { position: relative; }
.mx td.c span { position: relative; }
.mx td.c:before { content: ""; position: absolute; inset: 3px 2px; border-radius: var(--r1); background: var(--ar); opacity: var(--o, 0); }
.mx td.z { color: var(--dim); }
.mx td.sum { color: var(--ar-hi); }
.mx tr.tot td { border-bottom: 0; font-weight: 500; color: var(--text); }

.still *, .still *:before, .still *:after { animation: none !important; transition: none !important; }
.still #tree .br.draw { stroke-dashoffset: 0; }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; } #tree .br.draw { stroke-dashoffset: 0; } }

@media (max-width: 1000px) {
  .hero, .g2, .g3, .g21, .side { grid-template-columns: 1fr; }
  .side nav { position: static; flex-direction: row; flex-wrap: wrap; }
  .checks { grid-template-columns: 1fr 1fr; }
  .stats { grid-template-columns: 1fr 1fr; row-gap: 24px; }
  .stat:nth-child(odd) { padding-left: 0; border-left: 0; }
  .hero .total { font-size: 60px; }
  .nav a { padding: 0 10px; }
  .top .frame { gap: 20px; }
}
