/* LTS VPN Mini App.
   Look: cloxii (charcoal stage, Onest + JetBrains Mono, white pill CTAs, glass secondaries,
   rise/fade motion) + apple-design principles (one idea per block, generous air,
   typographic hierarchy, 18–24px radii, layered soft shadows). Tokens only — no raw values below :root. */

:root {
  --ink: #060607;
  --ink-2: #0c0c0e;
  --card: #111114;
  --card-2: #17171b;
  --card-3: #1f1f24;
  --fg: #f3f3f5;
  --muted: #8c8c93;
  --dim: #55555c;
  --line: rgba(255, 255, 255, .08);
  --line-2: rgba(255, 255, 255, .14);
  --glass: rgba(255, 255, 255, .06);
  --glass-2: rgba(255, 255, 255, .1);
  --ok: #30d158;
  --warn: #ffb340;
  --bad: #ff5a4f;
  --c1: #f3f3f5;
  --c2: #8c8c93;
  --c3: #30d158;

  --f-display: "Onest", "SF Pro Display", -apple-system, "Segoe UI", Roboto, system-ui, sans-serif;
  --f-body: "Onest", -apple-system, "Segoe UI", Roboto, system-ui, sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Consolas, monospace;

  --ease: cubic-bezier(.2, .8, .2, 1);
  --ease-in-out: cubic-bezier(.75, 0, .2, 1);

  --r-card: 24px;
  --r-md: 18px;
  --r-sm: 14px;
  --r-pill: 999px;

  --gut: 18px;
  --gap: 12px;
  --section: 36px;

  --shadow: 0 1px 0 rgba(255, 255, 255, .04) inset, 0 12px 32px rgba(0, 0, 0, .32);
  --shadow-lg: 0 1px 0 rgba(255, 255, 255, .05) inset, 0 24px 60px rgba(0, 0, 0, .5);

  --tabbar-h: 66px;
  --safe-b: max(env(safe-area-inset-bottom, 0px), 10px);
  color-scheme: dark;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { background: var(--ink); }
body {
  margin: 0;
  min-height: 100dvh;
  background: var(--ink);
  color: var(--fg);
  font: 400 16px/1.5 var(--f-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
button { font: inherit; color: inherit; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--fg); outline-offset: 3px; border-radius: 10px; }
.ic { width: 1em; height: 1em; flex: none; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ---------- stage ---------- */
.glow {
  position: fixed; inset: 0 0 auto; height: 70vh; z-index: -1; pointer-events: none;
  background: radial-gradient(90% 60% at 80% -10%, #2a2a30 0%, #121215 45%, transparent 80%);
}
.app {
  max-width: 560px; margin: 0 auto;
  padding: calc(env(safe-area-inset-top, 0px) + 12px) var(--gut) calc(var(--tabbar-h) + var(--safe-b) + 28px);
}
.app.no-tabs { padding-bottom: calc(var(--safe-b) + 28px); }

/* ---------- loader (cloxii) ---------- */
.loader {
  position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; background: var(--ink);
  transition: transform .9s var(--ease-in-out), visibility 0s .9s;
}
.loader.out { transform: translateY(-100%); visibility: hidden; }
.loader-in { display: grid; justify-items: center; gap: 22px; }
.loader-mark {
  display: flex; padding: 12px 20px; border-radius: var(--r-pill); background: #101012;
  box-shadow: inset 0 0 0 1px var(--line); font: 700 26px/1 var(--f-display); letter-spacing: -.01em;
}
.loader-mark span { display: inline-block; animation: letterIn .6s var(--ease) both; animation-delay: calc(var(--i) * 60ms); }
.loader-bar { width: 120px; height: 1px; background: rgba(255, 255, 255, .14); overflow: hidden; }
.loader-bar i { display: block; height: 100%; background: #fff; transform-origin: left; animation: barFill 1.1s var(--ease-in-out) .1s both; }
@keyframes letterIn { from { opacity: 0; transform: translateY(60%); } }
@keyframes barFill { from { transform: scaleX(0); } }

/* ---------- motion ---------- */
.in { animation: fadeUp .8s var(--ease) both; animation-delay: var(--d, 0s); }
@keyframes fadeUp { from { opacity: 0; transform: translateY(18px); } }
.title .line { display: block; overflow: hidden; padding-bottom: .08em; margin-bottom: -.08em; }
.title .line > span { display: inline-block; animation: rise .9s var(--ease) both; animation-delay: calc(var(--i, 0) * 90ms + var(--d, 0s)); }
@keyframes rise { from { transform: translateY(108%); } }
.screen { animation: screenIn .45s var(--ease) both; }
@keyframes screenIn { from { opacity: 0; transform: translateY(8px); } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; transition-duration: .01ms !important; }
}

/* ---------- top bar ---------- */
.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 26px; }
.brand { display: flex; align-items: center; gap: 9px; font: 700 18px/1 var(--f-display); letter-spacing: -.02em; text-decoration: none; }
.brand-mark { width: 28px; height: 28px; border-radius: 9px; background: #fff; color: #000; display: grid; place-items: center; font: 800 16px/1 var(--f-display); }
.avatar {
  width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; border: 0; cursor: pointer; text-decoration: none;
  background: var(--glass); box-shadow: inset 0 0 0 1px var(--line); font: 600 14px/1 var(--f-display); color: var(--fg);
}

/* ---------- type ---------- */
.eyebrow { font: 500 11.5px/1.2 var(--f-mono); letter-spacing: .16em; text-transform: uppercase; color: var(--muted); margin: 0 0 14px; }
.title { font-family: var(--f-display); font-weight: 700; font-size: clamp(38px, 11vw, 50px); line-height: 1; letter-spacing: -.045em; margin: 0 0 14px; text-wrap: balance; }
.title.sm { font-size: clamp(30px, 8.5vw, 38px); }
.sub { color: var(--muted); font-size: 16px; margin: 0 0 22px; max-width: 30em; }
.h3 { font: 650 19px/1.2 var(--f-display); letter-spacing: -.02em; margin: 0; }
.section { margin-top: var(--section); }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 12px; }
.section-head a, .link { color: var(--muted); font-size: 14px; text-decoration: none; cursor: pointer; background: none; border: 0; padding: 0; }
.muted { color: var(--muted); }
.dim { color: var(--dim); }
.mono { font-family: var(--f-mono); }
.ok { color: var(--ok); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; height: 52px; padding: 0 22px;
  border-radius: var(--r-pill); border: 0; font: 600 15.5px/1 var(--f-body); text-decoration: none; cursor: pointer;
  white-space: nowrap; transition: background .25s, color .25s, transform .35s var(--ease), opacity .25s;
}
.btn:active { transform: scale(.97); }
.btn[disabled] { opacity: .45; pointer-events: none; }
.btn .ic { width: 18px; height: 18px; }
.btn-light { background: #fff; color: #000; }
.btn-light:hover { background: #e6e6ea; }
.btn-glass { background: var(--glass); color: var(--fg); box-shadow: inset 0 0 0 1px var(--line); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
.btn-glass:hover { background: var(--glass-2); }
.btn-danger { background: rgba(255, 90, 79, .12); color: var(--bad); }
.btn-block { width: 100%; }
.btn-sm { height: 40px; padding: 0 16px; font-size: 14px; }
.cta { display: flex; gap: 10px; flex-wrap: wrap; }
.cta .btn { flex: 1 1 auto; }

/* ---------- hero / status ---------- */
.hero { position: relative; }
.hero-row { display: flex; align-items: center; gap: 18px; justify-content: space-between; }
.ring { position: relative; width: 104px; height: 104px; flex: none; }
.ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring circle { fill: none; stroke-width: 7; stroke-linecap: round; }
.ring .track { stroke: rgba(255, 255, 255, .08); }
.ring .bar { stroke: #fff; stroke-dasharray: 1; stroke-dashoffset: 1; transition: stroke-dashoffset 1.4s var(--ease) .35s; }
.ring-label { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.ring-label b { font: 700 28px/1 var(--f-display); letter-spacing: -.04em; }
.ring-label small { font: 500 10px/1.4 var(--f-mono); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }

.pills { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; }
.pills li { display: flex; align-items: baseline; gap: 7px; padding: 8px 14px; border-radius: var(--r-pill); background: rgba(255, 255, 255, .05); box-shadow: inset 0 0 0 1px var(--line); font-size: 13px; color: var(--muted); }
.pills b { color: var(--fg); font-weight: 600; }
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 4px rgba(48, 209, 88, .14); flex: none; align-self: center; }
.dot.off { background: var(--dim); box-shadow: none; }
.dot.warn { background: var(--warn); box-shadow: 0 0 0 4px rgba(255, 179, 64, .14); }

/* ---------- cards ---------- */
.card { background: var(--card); border-radius: var(--r-card); box-shadow: var(--shadow), inset 0 0 0 1px var(--line); padding: 20px; }
.card + .card { margin-top: var(--gap); }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); }
.tile {
  display: flex; flex-direction: column; gap: 22px; min-height: 132px; padding: 18px; border: 0; text-align: left; cursor: pointer; text-decoration: none;
  background: var(--card); border-radius: var(--r-card); box-shadow: var(--shadow), inset 0 0 0 1px var(--line);
  transition: transform .35s var(--ease), background .25s;
}
.tile:active { transform: scale(.97); }
.tile:hover { background: var(--card-2); }
.tile .ic-wrap { width: 40px; height: 40px; border-radius: 13px; display: grid; place-items: center; background: var(--glass); box-shadow: inset 0 0 0 1px var(--line); }
.tile .ic-wrap .ic { width: 20px; height: 20px; }
.tile b { display: block; font: 650 16px/1.2 var(--f-display); letter-spacing: -.01em; margin-bottom: 3px; }
.tile span { font-size: 13px; color: var(--muted); line-height: 1.35; }
.tile.primary { background: #fff; color: #000; }
.tile.primary span { color: #55555c; }
.tile.primary .ic-wrap { background: #000; color: #fff; box-shadow: none; }

/* icon draw-in (cloxii) */
.draw path, .draw circle, .draw rect, .draw line, .draw polyline { stroke-dasharray: 1; stroke-dashoffset: 1; animation: icDraw 1.1s var(--ease) both; animation-delay: calc(var(--d, 0s) + .25s); }
@keyframes icDraw { to { stroke-dashoffset: 0; } }

/* ---------- lists ---------- */
.list { background: var(--card); border-radius: var(--r-card); box-shadow: var(--shadow), inset 0 0 0 1px var(--line); overflow: hidden; }
.row { display: flex; align-items: center; gap: 14px; padding: 14px 18px; min-height: 62px; width: 100%; border: 0; background: none; text-align: left; cursor: default; }
button.row, a.row { cursor: pointer; text-decoration: none; transition: background .2s; }
button.row:active, a.row:active { background: var(--glass); }
.row + .row { box-shadow: 0 -1px 0 var(--line); }
.row-main { flex: 1; min-width: 0; }
.row-main b { display: block; font-weight: 600; font-size: 15.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row-main small { display: block; color: var(--muted); font-size: 13px; margin-top: 2px; }
.row-side { color: var(--muted); font-size: 13px; display: flex; align-items: center; gap: 8px; flex: none; }
.row .chev { width: 16px; height: 16px; color: var(--dim); }
.row-ic { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: var(--glass); box-shadow: inset 0 0 0 1px var(--line); flex: none; }
.row-ic .ic { width: 19px; height: 19px; }
.flag { width: 30px; height: 30px; border-radius: 50%; overflow: hidden; flex: none; box-shadow: 0 0 0 1px var(--line-2); }
.flag svg { width: 100%; height: 100%; display: block; }

/* ---------- protocol badge (home) ---------- */
.proto {
  position: relative; overflow: hidden; display: flex; align-items: center; gap: 14px; padding: 18px;
  border-radius: var(--r-card); background: var(--card); box-shadow: var(--shadow), inset 0 0 0 1px var(--line);
}
.proto::before {
  content: ""; position: absolute; inset: -40% -10%; pointer-events: none;
  background: linear-gradient(100deg, transparent 40%, rgba(255, 255, 255, .07) 50%, transparent 60%);
  animation: sweep 3.2s var(--ease) infinite;
}
@keyframes sweep { from { transform: translateX(-60%); } to { transform: translateX(60%); } }
.proto b { display: block; font: 700 22px/1.1 var(--f-display); letter-spacing: -.03em; }
.proto small { display: block; color: var(--muted); font-size: 13px; }
.proto-ic { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; background: #fff; color: #000; flex: none; }
.proto-ic .ic { width: 22px; height: 22px; }
.proto-live { display: flex; align-items: center; gap: 7px; font-size: 12.5px; font-weight: 600; color: var(--ok); flex: none; }
.proto-live i { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); animation: pulse 1.8s ease-out infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(48, 209, 88, .5); } 100% { box-shadow: 0 0 0 10px rgba(48, 209, 88, 0); } }

/* ---------- segmented ---------- */
.seg { position: relative; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; padding: 4px; border-radius: var(--r-pill); background: var(--card); box-shadow: inset 0 0 0 1px var(--line); }
.seg button { position: relative; z-index: 1; height: 42px; border: 0; background: none; border-radius: var(--r-pill); font-weight: 600; font-size: 14.5px; color: var(--muted); cursor: pointer; transition: color .3s; }
.seg button.on { color: #000; }
.seg i { position: absolute; z-index: 0; top: 4px; bottom: 4px; left: 4px; border-radius: var(--r-pill); background: #fff; transition: transform .45s var(--ease), width .45s var(--ease); }

/* ---------- plans ---------- */
.plans { display: grid; gap: 10px; }
.plan {
  position: relative; display: flex; align-items: center; gap: 14px; padding: 18px; width: 100%; border: 0; text-align: left; cursor: pointer;
  background: var(--card); border-radius: var(--r-md); box-shadow: inset 0 0 0 1px var(--line); transition: box-shadow .25s, background .25s, transform .35s var(--ease);
}
.plan:active { transform: scale(.985); }
.plan.on { background: var(--card-2); box-shadow: inset 0 0 0 1.5px #fff; }
.plan .radio { width: 22px; height: 22px; border-radius: 50%; box-shadow: inset 0 0 0 1.5px var(--line-2); flex: none; display: grid; place-items: center; transition: box-shadow .25s; }
.plan.on .radio { box-shadow: inset 0 0 0 7px #fff; }
.plan-main { flex: 1; }
.plan-main b { display: block; font: 650 17px/1.2 var(--f-display); letter-spacing: -.01em; }
.plan-main small { color: var(--muted); font-size: 13px; }
.plan-price { text-align: right; }
.plan-price b { display: block; font: 700 19px/1.1 var(--f-display); letter-spacing: -.02em; }
.plan-price s { color: var(--dim); font-size: 12.5px; }
.badge { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: var(--r-pill); font: 600 11.5px/1 var(--f-body); background: #fff; color: #000; margin-left: 6px; vertical-align: 2px; }
.badge.ghost { background: var(--glass-2); color: var(--fg); }
.paybar {
  position: sticky; bottom: calc(var(--tabbar-h) + var(--safe-b) + 14px); margin-top: 18px; padding: 14px; border-radius: var(--r-card);
  background: rgba(17, 17, 20, .82); backdrop-filter: blur(18px) saturate(1.4); -webkit-backdrop-filter: blur(18px) saturate(1.4); box-shadow: var(--shadow-lg), inset 0 0 0 1px var(--line);
}
.paybar-top { display: flex; justify-content: space-between; align-items: baseline; margin: 2px 4px 12px; }
.paybar-top b { font: 700 22px/1 var(--f-display); letter-spacing: -.03em; }

/* ---------- steps (setup) ---------- */
.steps { display: flex; gap: 6px; margin-bottom: 26px; }
.steps i { height: 3px; flex: 1; border-radius: 3px; background: rgba(255, 255, 255, .1); overflow: hidden; position: relative; }
.steps i::after { content: ""; position: absolute; inset: 0; background: #fff; transform: scaleX(0); transform-origin: left; transition: transform .6s var(--ease); }
.steps i.done::after { transform: scaleX(1); }
.apps { display: grid; gap: 10px; }
.app-card { display: flex; align-items: center; gap: 14px; padding: 16px; border: 0; width: 100%; text-align: left; cursor: pointer; border-radius: var(--r-md); background: var(--card); box-shadow: inset 0 0 0 1px var(--line); transition: box-shadow .25s, transform .35s var(--ease); }
.app-card.on { box-shadow: inset 0 0 0 1.5px #fff; background: var(--card-2); }
.app-logo { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; font: 800 20px/1 var(--f-display); background: #fff; color: #000; flex: none; }
.app-logo.dark { background: #26262c; color: #fff; }
.keybox { display: flex; align-items: center; gap: 10px; padding: 12px 12px 12px 16px; border-radius: var(--r-md); background: var(--ink-2); box-shadow: inset 0 0 0 1px var(--line); }
.keybox code { flex: 1; min-width: 0; font: 500 12.5px/1.4 var(--f-mono); color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------- FAQ ---------- */
.faq details { border-radius: var(--r-md); background: var(--card); box-shadow: inset 0 0 0 1px var(--line); }
.faq details + details { margin-top: 10px; }
.faq summary { list-style: none; display: flex; align-items: center; gap: 14px; padding: 16px 18px; cursor: pointer; font-weight: 600; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary .num { width: 28px; height: 28px; border-radius: 9px; display: grid; place-items: center; font: 600 13px/1 var(--f-mono); background: var(--glass); box-shadow: inset 0 0 0 1px var(--line); flex: none; }
.faq summary .chev { margin-left: auto; width: 16px; height: 16px; color: var(--dim); transition: transform .35s var(--ease); }
.faq details[open] summary .chev { transform: rotate(90deg); }
.faq .ans { padding: 0 18px 18px 60px; color: var(--muted); font-size: 14.5px; }
.faq .ans p { margin: 0 0 8px; }
.faq .ans ol { margin: 0; padding-left: 18px; }

/* ---------- toggle ---------- */
.toggle { position: relative; width: 50px; height: 30px; flex: none; }
.toggle input { position: absolute; opacity: 0; inset: 0; cursor: pointer; z-index: 1; margin: 0; }
.toggle span { position: absolute; inset: 0; border-radius: var(--r-pill); background: var(--card-3); box-shadow: inset 0 0 0 1px var(--line); transition: background .3s; }
.toggle span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; transition: transform .35s var(--ease); }
.toggle input:checked + span { background: var(--ok); }
.toggle input:checked + span::after { transform: translateX(20px); }

/* ---------- tab bar ---------- */
.tabbar {
  position: fixed; z-index: 40; left: 50%; bottom: calc(var(--safe-b) + 8px); translate: -50% 0;
  width: min(520px, calc(100% - 24px)); height: var(--tabbar-h); padding: 7px; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr;
  border-radius: var(--r-pill); background: rgba(16, 16, 19, .72); backdrop-filter: blur(20px) saturate(1.5); -webkit-backdrop-filter: blur(20px) saturate(1.5);
  box-shadow: var(--shadow-lg), inset 0 0 0 1px var(--line);
  transition: transform .5s var(--ease), opacity .3s;
}
.tabbar.hidden { transform: translateY(140%); opacity: 0; pointer-events: none; }
.tabbar a { position: relative; z-index: 1; display: grid; place-items: center; align-content: center; gap: 3px; border-radius: var(--r-pill); text-decoration: none; color: var(--muted); font-size: 10.5px; font-weight: 600; transition: color .3s; }
.tabbar a .ic { width: 21px; height: 21px; }
.tabbar a.on { color: #000; }
.tabbar .pill { position: absolute; z-index: 0; top: 7px; bottom: 7px; left: 7px; border-radius: var(--r-pill); background: #fff; transition: transform .5s var(--ease), width .5s var(--ease); }

/* ---------- sheet / toast ---------- */
.scrim { position: fixed; inset: 0; z-index: 60; background: rgba(0, 0, 0, .55); opacity: 0; transition: opacity .3s; }
.scrim.on { opacity: 1; }
.sheet {
  position: fixed; z-index: 61; left: 50%; bottom: 0; width: min(560px, 100%); translate: -50% 0; transform: translateY(100%);
  padding: 10px var(--gut) calc(var(--safe-b) + 18px); border-radius: 28px 28px 0 0; background: var(--ink-2); box-shadow: var(--shadow-lg), inset 0 1px 0 var(--line-2);
  transition: transform .5s var(--ease);
}
.sheet.on { transform: none; }
.sheet .grab { width: 38px; height: 5px; border-radius: 5px; background: rgba(255, 255, 255, .18); margin: 0 auto 18px; }
.sheet h3 { font: 700 22px/1.15 var(--f-display); letter-spacing: -.03em; margin: 0 0 8px; }
.sheet p { color: var(--muted); margin: 0 0 18px; }
.sheet .stack { display: grid; gap: 10px; }
.input { width: 100%; height: 52px; padding: 0 16px; border: 0; border-radius: var(--r-md); background: var(--card); box-shadow: inset 0 0 0 1px var(--line-2); color: var(--fg); font: 500 16px var(--f-body); outline: none; }
.input:focus { box-shadow: inset 0 0 0 1.5px #fff; }
.toast {
  position: fixed; z-index: 80; left: 50%; top: calc(env(safe-area-inset-top, 0px) + 14px); translate: -50% 0; transform: translateY(-160%);
  display: flex; align-items: center; gap: 10px; max-width: calc(100% - 32px); padding: 12px 18px; border-radius: var(--r-pill);
  background: #fff; color: #000; font-weight: 600; font-size: 14.5px; box-shadow: var(--shadow-lg); transition: transform .5s var(--ease);
}
.toast.on { transform: none; }
.toast.err { background: var(--bad); color: #fff; }
.spinner { width: 22px; height: 22px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .15); border-top-color: #fff; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- skeleton ---------- */
.skel { border-radius: var(--r-card); background: linear-gradient(100deg, var(--card) 30%, var(--card-2) 50%, var(--card) 70%) 0 0 / 300% 100%; animation: shimmer 1.4s linear infinite; }
@keyframes shimmer { to { background-position: -150% 0; } }

/* ---------- admin ---------- */
.kpis { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); }
.kpi { padding: 16px 18px; border-radius: var(--r-md); background: var(--card); box-shadow: inset 0 0 0 1px var(--line); }
.kpi small { display: block; font: 500 10.5px/1.3 var(--f-mono); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.kpi b { font: 700 28px/1 var(--f-display); letter-spacing: -.04em; }
.kpi em { font-style: normal; color: var(--muted); font-size: 13px; margin-left: 4px; }
.chart-card { padding: 18px 18px 12px; }
.chart-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 6px; }
.legend { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 12px; color: var(--muted); }
.legend i { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 5px; vertical-align: 0; }
.chart { position: relative; }
.chart svg { display: block; width: 100%; height: auto; overflow: visible; }
.chart .grid line { stroke: rgba(255, 255, 255, .06); }
.chart .axis text { fill: var(--dim); font: 500 10px var(--f-mono); }
.chart .line { fill: none; stroke-width: 2.2; stroke-linejoin: round; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 1; animation: icDraw 1.6s var(--ease) both .2s; }
.chart .area { opacity: 0; animation: fadeIn 1s ease 1s forwards; }
.chart .bar { transform-box: fill-box; transform-origin: bottom; animation: barUp .9s var(--ease) both; animation-delay: calc(var(--i) * 18ms + .15s); }
@keyframes barUp { from { transform: scaleY(0); } }
@keyframes fadeIn { to { opacity: 1; } }
.chart .cursor { stroke: rgba(255, 255, 255, .3); stroke-dasharray: 3 3; }
.tip { position: absolute; top: 0; pointer-events: none; padding: 8px 10px; border-radius: 12px; background: #fff; color: #000; font-size: 12px; line-height: 1.45; white-space: nowrap; box-shadow: var(--shadow-lg); transform: translate(-50%, -105%); }
.tip b { font-weight: 700; }
