/*
 * css/pages/protocol.css: the protocol group (SPEC 12 C3): /protocol, /protocol/agents, /token, /analytics.
 * Tokens only (css/tokens.css); every shared component comes from css/site.css.
 */

/* ================================================================================================ /protocol */
.page--protocol { background: var(--bg); color: var(--body); }
.chapters { position: relative; }
.chapter { position: relative; isolation: isolate; background: var(--bg); overflow: hidden; }
.chapter__inner { position: relative; z-index: 1; padding-block: clamp(64px, 8vw, 104px); }
.chapter__head { display: flex; flex-direction: column; gap: 18px; max-width: 760px; }
.chapter__head .h2 { font-weight: 800; }
.proto-h2 { font: 800 clamp(34px, 4vw, 56px)/1.04 var(--font-body); letter-spacing: -0.035em; color: var(--text); }
.proto-h2 .l2 { display: block; font: 400 1em/1.08 var(--font-display); letter-spacing: 0; color: var(--accent); }
.chapter__foot {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 12px 32px;
  margin-top: clamp(40px, 5vw, 64px); padding-top: 20px; border-top: 1px solid var(--line);
}
.chapter__foot p { font-size: 14.5px; color: var(--muted); }
.chapter__foot .kicker { color: var(--accent); }
/* stacked chapters: each sticks under the header and the next slides over it (no wheel snapping) */
@media (min-width: 820px) {
  .chapter {
    position: sticky; top: var(--stick, var(--header-h));
    min-height: calc(100svh - var(--header-h)); display: flex; flex-direction: column; justify-content: center;
  }
  .chapter + .chapter {
    border-top: 1px solid var(--line-strong); border-radius: 24px 24px 0 0; box-shadow: 0 -24px 64px rgba(0, 0, 0, .4);
  }
}
/* a faint grid on the middle chapters (orbio's --grid-size) */
.chapter--grid::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: .5;
  background-image: linear-gradient(var(--line-row) 1px, transparent 1px), linear-gradient(90deg, var(--line-row) 1px, transparent 1px);
  background-size: 64px 64px; background-position: center top;
  -webkit-mask: radial-gradient(ellipse 80% 70% at 50% 50%, #000, transparent); mask: radial-gradient(ellipse 80% 70% at 50% 50%, #000, transparent);
}

/* ------------------------------------------------------------------------------------------------ 1. hero */
.glyphs { position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%; pointer-events: none; }
.hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 460px); align-items: center; gap: 48px; }
.hero__copy { display: flex; flex-direction: column; align-items: flex-start; gap: 26px; min-width: 0; }
.hero__title { font: 400 clamp(48px, 6.2vw, 88px)/1.04 var(--font-display); letter-spacing: 0; color: var(--text); }
.hero__title .l2 { display: block; color: var(--muted); }
.hero__copy .lede { max-width: 30ch; color: var(--dim); }
.hero__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; }
.btn--marble { background: var(--text); color: var(--bg); border-color: transparent; }
.btn--marble:hover { background: var(--dim); }
.btn--plain { height: 44px; padding: 0 4px; color: var(--dim); gap: 10px; }
.btn--plain:hover { color: var(--text); }
.btn--plain .icon { color: var(--accent); }
@media (max-width: 819px) {
  .hero { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .hero .coin { order: -1; width: min(300px, 78vw); margin-inline: auto; }
  .hero__copy { gap: 22px; }
}

/* ------------------------------------------------------------------------------------------------ the coin */
.coin { position: relative; width: 100%; aspect-ratio: 1; margin: 0; }
.coin__poster {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain;
  filter: drop-shadow(0 28px 36px rgba(0, 0, 0, .45));
  transition: opacity 450ms var(--ease-out), visibility 0s linear 450ms;
}
.coin__stage { position: absolute; inset: 0; }
.coin__stage canvas {
  width: 100%; height: 100%; opacity: 0; transition: opacity 450ms var(--ease-out);
  filter: drop-shadow(0 28px 36px rgba(0, 0, 0, .45));
}
.coin[data-ready] .coin__stage canvas { opacity: 1; }
.coin[data-ready] .coin__poster { opacity: 0; visibility: hidden; }
.coin__hit { position: absolute; inset: 4.35%; border-radius: 18%; touch-action: pan-y; }
.coin[data-ready] .coin__hit { cursor: grab; }
.coin__hit[data-dragging] { cursor: grabbing; }
.coin__hit:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }

/* ------------------------------------------------------------------------------------------------ 2. meet */
.meet { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 620px); align-items: center; gap: 48px; }
.meet__copy { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.meet__copy .lede { max-width: 32ch; }
.orbit { position: relative; width: 100%; aspect-ratio: 1; max-width: 620px; justify-self: end; }
.orbit .coin { position: absolute; inset: 18%; width: auto; }
.orbit__ring { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.orbit__ring path { fill: none; stroke: var(--line-input); stroke-width: 1.2px; vector-effect: non-scaling-stroke; }
.orbit__ring .flow { stroke: var(--accent); stroke-width: 2px; stroke-dasharray: 9 91; stroke-linecap: round; }
html.motion .orbit.is-playing .flow { animation: orbit-flow 7s linear infinite; }
@keyframes orbit-flow { to { stroke-dashoffset: -100; } }
.orbit__ring .head { fill: var(--line-input); stroke: none; }
.move { position: absolute; width: 34%; display: flex; flex-direction: column; gap: 4px; }
.move__n { font: 500 11px/1 var(--font-mono); color: var(--accent); letter-spacing: .08em; }
.move__name { font: 600 22px/1.2 var(--font-body); color: var(--text); letter-spacing: -0.01em; }
.move__line { font-size: 13.5px; line-height: 1.45; color: var(--muted); }
.move--1 { top: 0; left: 0; }
.move--2 { top: 0; right: 0; text-align: right; align-items: flex-end; }
.move--3 { bottom: 0; right: 0; text-align: right; align-items: flex-end; }
.move--4 { bottom: 0; left: 0; }
@media (max-width: 1023px) {
  .meet { grid-template-columns: minmax(0, 1fr); }
  .orbit { justify-self: center; }
}
@media (max-width: 639px) {
  .orbit { aspect-ratio: auto; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 16px; }
  .orbit .coin { position: relative; inset: auto; grid-column: 1 / -1; width: min(280px, 76vw); justify-self: center; }
  .orbit__ring { display: none; }
  .move { position: static; width: auto; text-align: left !important; align-items: flex-start !important; padding-top: 12px; border-top: 1px solid var(--line); }
  .move__name { font-size: 19px; }
}

/* ------------------------------------------------------------------------------------------------ 3. activate */
.activate { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 20px; }
.equation { font: 400 clamp(44px, 7.4vw, 104px)/1.02 var(--font-display); color: var(--text); letter-spacing: 0; }
.equation em { font-style: normal; color: var(--accent); }
.stem { position: relative; width: min(100%, 1100px); height: 56px; margin-top: 8px; }
.stem svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.stem path { fill: none; stroke: var(--accent-line); stroke-width: 1.2; vector-effect: non-scaling-stroke; }
.stem circle { fill: var(--accent); }
.models3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; width: min(100%, 1100px); min-height: 168px; }
.models3 > .state, .models3 > .skeleton { grid-column: 1 / -1; }
.mbox {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; min-width: 0;
  padding: 28px 20px; border: 1px solid var(--line-strong); border-radius: var(--r4); background: var(--panel);
  box-shadow: var(--shadow-card); transition: border-color var(--t2), transform var(--t2) var(--ease-out);
}
a.mbox:hover { border-color: var(--accent-line); transform: translateY(-2px); }
.mono-tile {
  width: 44px; height: 44px; display: grid; place-items: center; border-radius: var(--r2);
  background: var(--panel-2); border: 1px solid var(--line); font: 600 16px/1 var(--font-mono); color: var(--text); text-transform: uppercase;
}
.mbox > div { display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 0; }
.mbox__provider { font-size: 13px; color: var(--muted); }
.mbox__name { font: 600 clamp(18px, 1.8vw, 24px)/1.25 var(--font-body); color: var(--text); letter-spacing: -0.01em; overflow-wrap: anywhere; }
.activate__notes { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.activate__notes p { font-size: 14.5px; color: var(--muted); }
@media (max-width: 819px) {
  .stem { display: none; }
  .models3 { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .mbox { flex-direction: row; justify-content: flex-start; text-align: left; padding: 16px 18px; gap: 14px; }
  .mbox > div { align-items: flex-start; gap: 2px; }
}

/* ------------------------------------------------------------------------------------------------ 4. map */
.map-wrap { margin-top: clamp(28px, 4vw, 48px); }
.map-scroll { position: relative; display: flex; justify-content: center; }
.map-svg { display: block; flex: none; width: 1000px; max-width: none; height: auto; overflow: visible; }
.map-svg .edge { fill: none; stroke: var(--line-input); stroke-width: 1.2; }
.map-svg .mh { fill: var(--line-input); }
.map-svg .flow { fill: none; stroke: var(--accent); stroke-width: 5; stroke-linecap: round; stroke-dasharray: 0.001 1; stroke-dashoffset: 1; opacity: 0; }
html.motion .map-svg.is-playing .flow { animation: map-flow 3s linear infinite; animation-delay: var(--d, 0s); }
@keyframes map-flow {
  0% { stroke-dashoffset: 1; opacity: 0; }
  15% { opacity: 1; }
  85% { opacity: 1; }
  100% { stroke-dashoffset: 0; opacity: 0; }
}
.map-svg .node rect { fill: var(--panel); stroke: var(--line-strong); stroke-width: 1; }
.map-svg .node--you rect, .map-svg .node--key rect { fill: var(--accent-tint); stroke: var(--accent-line); }
.map-svg .node text { fill: var(--text); font-family: var(--font-body); font-size: 14px; font-weight: 500; text-anchor: middle; dominant-baseline: central; }
.map-svg .lbl { fill: var(--muted); font-family: var(--font-mono); font-size: 12px; font-weight: 500; text-anchor: middle; }
.map-svg .lbl--start { text-anchor: start; }
.map-swipe { display: none; }
@media (max-width: 1099px) {
  .map-scroll { display: block; overflow-x: auto; overscroll-behavior-x: contain; border: 1px solid var(--line); border-radius: var(--r3); background: var(--panel-3); padding: 16px; }
  .map-swipe { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; font: 500 12px/1.4 var(--font-mono); color: var(--muted); }
  .map-swipe .icon { width: 16px; height: 16px; color: var(--accent); }
}

/* ------------------------------------------------------------------------------------------------ 5. agents */
.agents-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 380px); align-items: end; gap: 24px 48px; }
.agents-head__side { font-size: 16px; color: var(--dim); }
.codecard {
  margin-top: clamp(28px, 4vw, 44px); border: 1px solid var(--line-strong); border-radius: var(--r4);
  background: var(--panel); box-shadow: var(--shadow-card); overflow: hidden;
}
.codecard__tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-bottom: 1px solid var(--line); }
.codecard__tabs [role="tab"] {
  position: relative; display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 56px; padding: 0 12px;
  font: 600 15px/1.2 var(--font-body); color: var(--muted); text-align: center; transition: color var(--t1);
}
.codecard__tabs [role="tab"] span { font: 500 11px/1 var(--font-mono); color: var(--faint); letter-spacing: .06em; }
.codecard__tabs [role="tab"]:hover { color: var(--text); }
.codecard__tabs [role="tab"][aria-selected="true"] { color: var(--text); }
.codecard__tabs [role="tab"][aria-selected="true"] span { color: var(--accent); }
.codecard__tabs [role="tab"][aria-selected="true"]::after { content: ""; position: absolute; left: 16px; right: 16px; bottom: -1px; height: 2px; background: var(--accent); }
.codecard__panel { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.6fr); min-height: 440px; }
.codecard__panel[hidden] { display: none; }
.codecard__copy { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; padding: 28px; border-right: 1px solid var(--line); }
.codecard__copy p { font-size: 15px; color: var(--body); }
.codecard__copy .note { margin-top: auto; }
.codepane { display: flex; flex-direction: column; min-width: 0; background: var(--bg-deep); }
.codepane__bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 48px; padding: 0 12px 0 20px; border-bottom: 1px solid var(--line); }
.codepane__lang { font: 500 12px/1 var(--font-mono); color: var(--muted); }
.codepane pre { flex: 1; border: 0; border-radius: 0; background: transparent; padding: 18px 20px 22px; counter-reset: ln; }
.codepane pre .ln { display: block; padding-left: 38px; position: relative; min-height: 1.75em; white-space: pre; }
.codepane pre .ln::before {
  counter-increment: ln; content: counter(ln); position: absolute; left: 0; width: 24px; text-align: right;
  color: var(--faint); font-size: 11.5px; user-select: none;
}
.codepane pre .c { color: var(--muted); }
.agents-links { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 28px; margin-top: 20px; }
.agents-links .note { flex-basis: 100%; }
@media (max-width: 1023px) {
  .agents-head { grid-template-columns: minmax(0, 1fr); }
  .codecard__panel { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .codecard__copy { border-right: 0; border-bottom: 1px solid var(--line); padding: 22px; }
}
@media (max-width: 639px) {
  .codecard__tabs [role="tab"] { flex-direction: column; gap: 6px; min-height: 64px; font-size: 13.5px; padding: 8px 6px; }
}

/* ------------------------------------------------------------------------------------------------ 6. why */
.why-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; margin-top: clamp(28px, 4vw, 48px); }
.why-col { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; padding-top: 20px; border-top: 1px solid var(--line-strong); }
.why-col .h3 { font-size: 20px; }
.why-col p { font-size: 15px; color: var(--body); }
.why-band { margin-top: clamp(32px, 4vw, 56px); }
.why-band__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
@media (max-width: 819px) { .why-cols { grid-template-columns: minmax(0, 1fr); gap: 24px; } }

/* ================================================================================================ /protocol/agents */
.docs {
  display: grid; grid-template-columns: 220px minmax(0, 72ch) 200px; justify-content: center; gap: 48px;
  padding-block: calc(var(--section) * .6) var(--section);
}
.docs__nav, .docs__toc { position: sticky; top: calc(var(--header-h) + 24px); align-self: start; max-height: calc(100dvh - var(--header-h) - 48px); overflow-y: auto; }
.docs__nav .label, .docs__toc .label { display: block; margin-bottom: 10px; }
.docs__nav ul, .docs__toc ul { list-style: none; display: flex; flex-direction: column; }
.docs__nav a { display: flex; align-items: center; min-height: 34px; padding: 0 10px; border-radius: var(--r2); font-size: 14px; color: var(--dim); }
.docs__nav a:hover { background: var(--panel-2); color: var(--text); }
.docs__nav a[aria-current="page"] { color: var(--text); background: var(--panel-2); box-shadow: inset 2px 0 0 var(--accent); }
.docs__toc a { display: block; padding: 5px 0 5px 12px; border-left: 1px solid var(--line); font-size: 13px; line-height: 1.4; color: var(--muted); }
.docs__toc a:hover, .docs__toc a.is-active { color: var(--text); border-left-color: var(--accent); }
.docs__group + .docs__group { margin-top: 24px; }
.article { min-width: 0; }
.article > * + * { margin-top: 18px; }
.article .kicker + h1 { margin-top: 14px; }
.article h1 { font: 400 clamp(38px, 4.4vw, 56px)/1.08 var(--font-display); color: var(--text); letter-spacing: 0; }
.article h2 { font: 800 28px/1.2 var(--font-body); letter-spacing: -0.02em; color: var(--text); margin-top: 56px; scroll-margin-top: calc(var(--header-h) + 20px); }
.article h3 { font: 700 19px/1.3 var(--font-body); color: var(--text); margin-top: 34px; scroll-margin-top: calc(var(--header-h) + 20px); }
.article h3 .n { font: 500 13px/1 var(--font-mono); color: var(--accent); margin-right: 10px; }
.article p, .article li { font-size: 16px; line-height: 1.7; color: var(--body); }
.article ul, .article ol { padding-left: 22px; display: flex; flex-direction: column; gap: 8px; }
.article strong { color: var(--text); font-weight: 600; }
.article .lede { font-size: 18px; }
.article pre { font-size: 13px; line-height: 1.7; }
.article .table-wrap { margin-top: 18px; }
.article .table td, .article .table th { vertical-align: top; }
.article .table td code { white-space: nowrap; }
.article .callout { margin-top: 20px; }
.addr { font: 500 12.5px/1.5 var(--font-mono); color: var(--text); overflow-wrap: anywhere; }
.addr a { color: inherit; text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 3px; }
.addr a:hover { color: var(--accent); text-decoration-color: currentColor; }
.contracts .role { display: block; margin-top: 2px; font-size: 13.5px; color: var(--muted); }
.contracts .addr { margin-top: 8px; }
.contracts td.r { white-space: nowrap; }
.live-num { font: 500 14px/1.4 var(--font-mono); color: var(--text); font-variant-numeric: tabular-nums; white-space: nowrap; }
@media (max-width: 1279px) {
  .docs { grid-template-columns: 200px minmax(0, 72ch); gap: 40px; }
  .docs__toc { display: none; }
}
@media (max-width: 1023px) {
  .docs { grid-template-columns: minmax(0, 1fr); gap: 20px; padding-top: 28px; }
  .docs__nav { position: static; max-height: none; overflow: visible; }
  .docs__nav nav { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; }
  .docs__nav .docs__group { flex: none; }
  .docs__nav .docs__group + .docs__group { margin-top: 0; }
  .docs__nav .label { display: none; }
  .docs__nav ul { flex-direction: row; gap: 6px; }
  .docs__nav a { white-space: nowrap; border: 1px solid var(--line); min-height: 40px; }
}
@media (max-width: 639px) {
  .stack-sm thead { display: none; }
  .stack-sm tr { display: block; padding: 12px 16px; border-bottom: 1px solid var(--line-row); }
  .stack-sm tbody tr:last-child { border-bottom: 0; }
  .stack-sm :is(td, th) { display: block; padding: 2px 0; border: 0; text-align: left; }
  .stack-sm tbody th { color: var(--text); font-weight: 600; }
  .stack-sm td[data-label]::before { content: attr(data-label); display: block; margin-top: 6px; font: 600 11px/1.6 var(--font-mono); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
  .contracts thead { display: none; }
  .contracts tr { display: block; padding: 14px 16px; border-bottom: 1px solid var(--line-row); }
  .contracts tbody tr:last-child { border-bottom: 0; }
  .contracts td { display: block; padding: 2px 0; border: 0; }
  .contracts td.r { text-align: left; padding-top: 8px; }
}

/* ================================================================================================ /token */
.tok-hero { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 22px; padding-block: calc(var(--section) * .7) calc(var(--section) * .55); }
.tok-title { font: 400 clamp(64px, 9vw, 120px)/1 var(--font-display); color: var(--text); letter-spacing: 0; }
.tok-title .accent { color: var(--accent); }
.tok-hero .lede { max-width: 62ch; }
.spec { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; list-style: none; }
.spec li { display: inline-flex; align-items: baseline; gap: 8px; }
.spec .k { font: 600 11px/1.4 var(--font-mono); text-transform: uppercase; letter-spacing: .12em; color: var(--muted); }
.spec .v { font: 600 12.5px/1.4 var(--font-mono); color: var(--text); }
.tok-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.tok-band { margin-top: 8px; }
.tok-band .band { text-align: left; }
.tok-band dd .laurel { gap: 8px; }
.tok-state { margin-top: 12px; }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 48px 64px; align-items: start; }
.split__copy { display: flex; flex-direction: column; gap: 18px; }
.split__copy .note { margin-top: 6px; }
@media (max-width: 1023px) { .split { grid-template-columns: minmax(0, 1fr); } }
.steps4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-top: 32px; }
.step4 { position: relative; }
.step4 .kicker { margin-bottom: 12px; }
.step4 .h3 { font-size: 19px; }
.step4 p { margin-top: 8px; }
.step4__arrow { position: absolute; top: 50%; right: -16px; width: 16px; display: grid; place-items: center; color: var(--accent); transform: translateY(-50%); }
.step4__arrow .icon { width: 14px; height: 14px; }
@media (max-width: 1023px) { .steps4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .step4__arrow { display: none; } }
@media (max-width: 559px) { .steps4 { grid-template-columns: minmax(0, 1fr); } }
.faq--box { border-top: 0; gap: 10px; }
.faq--box details { border: 1px solid var(--line); border-radius: var(--r3); background: var(--panel); padding: 0 20px; }
.faq--box details[open] { border-color: var(--line-strong); }
.faq--box summary { padding: 16px 0; }
.faq--box .faq__a { padding: 0 8px 18px 0; }
.faq__sign { flex: none; width: 24px; text-align: center; font: 500 18px/1 var(--font-mono); color: var(--accent); }
.faq__sign::before { content: "+"; }
.faq--box details[open] .faq__sign::before { content: "-"; }
.tok-more { margin-top: 24px; }
.sec-head { display: flex; flex-direction: column; gap: 16px; max-width: 760px; margin-bottom: 8px; }

/* ================================================================================================ /analytics */
.an-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 18px 32px; padding-block: calc(var(--section) * .6) calc(var(--section) * .35); }
.an-head__copy { display: flex; flex-direction: column; gap: 18px; max-width: 760px; }
.an-head__live { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.an-head__live .note { white-space: nowrap; }
@media (max-width: 819px) { .an-head__live { align-items: flex-start; } }
.kpis {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px;
  background: var(--line); border: 1px solid var(--line); border-radius: var(--r4); overflow: hidden;
}
.kpi { position: relative; display: flex; flex-direction: column; gap: 12px; min-width: 0; min-height: 176px; padding: 24px 26px; background: var(--panel); }
.kpi__top { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.kpi__label { font-size: 14.5px; font-weight: 500; color: var(--dim); }
.kpi__value { font: 400 40px/1.05 var(--font-display); color: var(--text); letter-spacing: 0; overflow-wrap: anywhere; }
.kpi__value .u { font: 500 13px/1 var(--font-mono); color: var(--muted); margin-left: 4px; letter-spacing: .04em; }
.kpi__value.is-launch { font: 500 20px/1.3 var(--font-mono); color: var(--muted); }
.kpi__cap { margin-top: auto; font: 400 12px/1.5 var(--font-mono); color: var(--faint); }
.kpi .laurel { gap: 10px; }
.spark { width: 88px; height: 32px; flex: none; overflow: visible; }
.spark path { fill: none; stroke: var(--series-1); stroke-width: 1.5; stroke-linejoin: round; stroke-linecap: round; }
.spark .base { stroke: var(--line-strong); stroke-width: 1; }
@media (max-width: 1023px) { .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 559px) { .kpis { grid-template-columns: minmax(0, 1fr); } .kpi { min-height: 0; } .kpi__value { font-size: 34px; } }
.an-sec { padding-block: calc(var(--section) * .55) 0; }
.an-sec__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; margin-bottom: 18px; }
.an-sec__title { display: flex; align-items: baseline; gap: 12px; }
.an-sec__title .n { font: 500 12px/1 var(--font-mono); color: var(--faint); }
.an-sec__title h2 { font: 700 22px/1.25 var(--font-body); color: var(--text); letter-spacing: -0.01em; }
.an-sec__title .range { font: 400 12.5px/1 var(--font-mono); color: var(--muted); }
.charts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 1023px) { .charts { grid-template-columns: minmax(0, 1fr); } }
.chart { display: flex; flex-direction: column; gap: 12px; min-width: 0; padding: 22px 24px; border: 1px solid var(--line); border-radius: var(--r4); background: var(--panel); }
.chart__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.chart__title { font: 600 15.5px/1.3 var(--font-body); color: var(--text); }
.chart__total { font: 400 30px/1.1 var(--font-display); color: var(--text); letter-spacing: 0; margin-top: 6px; }
.chart__sub { font: 400 12px/1.5 var(--font-mono); color: var(--faint); }
.chart__plot { position: relative; }
.chart__plot:focus-visible { outline: 2px solid var(--focus); outline-offset: 4px; border-radius: var(--r2); }
.chart__plot svg { display: block; overflow: visible; }
.chart .grid line { stroke: var(--line-row); stroke-width: 1; stroke-dasharray: 3 4; }
.chart .axis text { fill: var(--muted); font: 500 11px var(--font-mono); }
.chart .bar { fill: var(--series-1); }
.chart .bar--2 { fill: var(--series-2); }
.chart .bar--3 { fill: var(--series-3); }
.chart .bar--4 { fill: var(--series-4); }
.chart .bar--other { fill: var(--series-other); }
.chart .bar.is-hot { opacity: .72; }
.chart__empty { display: grid; place-items: center; height: 190px; padding: 16px; border: 1px dashed var(--line-strong); border-radius: var(--r3); font: 400 13px/1.5 var(--font-mono); color: var(--muted); text-align: center; }
@media (max-width: 639px) { .chart__head { flex-direction: column-reverse; align-items: flex-start; gap: 10px; } }
.tip {
  position: absolute; z-index: 5; pointer-events: none; padding: 7px 10px; border-radius: var(--r2); white-space: nowrap;
  background: var(--panel-2); border: 1px solid var(--line-strong); box-shadow: var(--shadow-pop);
  font: 500 12px/1.3 var(--font-mono); color: var(--text); transform: translate(-50%, calc(-100% - 10px));
}
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; }
.legend span { display: inline-flex; align-items: center; gap: 6px; font: 500 12px/1.4 var(--font-mono); color: var(--muted); }
.legend i { width: 8px; height: 8px; border-radius: 2px; background: var(--series-1); }
.viewdata summary { cursor: pointer; font: 500 12px/1.4 var(--font-mono); color: var(--muted); list-style: none; display: inline-flex; align-items: center; gap: 6px; min-height: 32px; }
@media (max-width: 819px) { .viewdata summary { min-height: 44px; min-width: 44px; } }
.viewdata summary::-webkit-details-marker { display: none; }
.viewdata summary .icon { width: 14px; height: 14px; transition: transform var(--t2) var(--ease-out); }
.viewdata[open] summary .icon { transform: rotate(90deg); }
.viewdata .table-wrap { margin-top: 8px; max-height: 280px; overflow: auto; }
.viewdata .table th, .viewdata .table td { padding: 8px 12px; font-size: 13px; }
.chart__foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; padding-top: 12px; border-top: 1px solid var(--line); }
.bookband { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 16px; }
@media (max-width: 1023px) { .bookband { grid-template-columns: minmax(0, 1fr); } }
.bookband .band { grid-auto-flow: row; grid-template-columns: minmax(0, 1fr); }
.depth-rows { display: flex; flex-direction: column; gap: 10px; }
.depth-row { display: grid; grid-template-columns: 92px minmax(0, 1fr) auto; align-items: center; gap: 14px; }
.depth-row__k { font: 500 12.5px/1.2 var(--font-mono); color: var(--accent); }
.depth-row__bar { height: 14px; border-radius: var(--r1); background: var(--panel-2); overflow: hidden; }
.depth-row__bar i { display: block; height: 100%; min-width: 2px; background: var(--series-1); }
.depth-row__v { font: 500 12.5px/1.2 var(--font-mono); color: var(--dim); text-align: right; white-space: nowrap; }
.method { margin-top: calc(var(--section) * .55); }
.method details { border: 1px solid var(--line); border-radius: var(--r4); background: var(--panel); padding: 0 24px; }
.method summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 60px; cursor: pointer; list-style: none; font: 700 18px/1.3 var(--font-body); color: var(--text); }
.method summary::-webkit-details-marker { display: none; }
.method .body { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 40px; padding: 4px 0 24px; }
.method .body div { display: flex; flex-direction: column; gap: 6px; }
.method .body h3 { font: 600 15px/1.3 var(--font-body); color: var(--text); }
.method .body p { font-size: 14.5px; color: var(--body); }
@media (max-width: 819px) { .method .body { grid-template-columns: minmax(0, 1fr); } }
.an-foot { padding-block: 28px var(--section); }
