:root {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #172033;
  background: #eef4fb;
  font-synthesis: none;
  --panel: rgba(255, 255, 255, 0.9);
  --panel-strong: #ffffff;
  --line: rgba(69, 91, 120, 0.14);
  --muted: #6f7f94;
  --blue: #2879dd;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; min-height: 100vh; background: radial-gradient(circle at top, #ffffff 0, #f2f7fc 44%, #e8f0f8 100%); }
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
.hidden { display: none !important; }
.ambient { position: fixed; width: 420px; height: 420px; border-radius: 50%; filter: blur(100px); opacity: .16; pointer-events: none; }
.ambient-one { top: -180px; left: -100px; background: #78b9ff; }
.ambient-two { right: -140px; top: 34%; background: #a997ff; }
.shell { position: relative; width: min(1500px, calc(100% - 48px)); margin: 0 auto; padding: 28px 0 64px; }
.topbar { display: flex; align-items: center; justify-content: space-between; min-height: 58px; }
.brand { display: flex; align-items: center; gap: 14px; }
.brand-mark { display: grid; place-items: center; width: 44px; height: 44px; border: 1px solid rgba(121, 184, 255, .4); border-radius: 14px; background: linear-gradient(145deg, #2e91ff, #6857ff); font-weight: 800; font-size: 21px; box-shadow: 0 12px 30px rgba(46, 145, 255, .22); }
.eyebrow { margin: 0 0 4px; color: #6f8bab; font-size: 10px; font-weight: 800; letter-spacing: .18em; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 0; font-size: 20px; letter-spacing: -.02em; }
h2 { margin-bottom: 10px; font-size: clamp(28px, 4vw, 46px); line-height: 1.12; letter-spacing: -.045em; }
h3 { margin-bottom: 0; font-size: 20px; letter-spacing: -.025em; }
.top-actions { display: flex; align-items: center; gap: 12px; }
.text-link { color: #60728a; text-decoration: none; font-size: 13px; }
.text-link:hover { color: #185aa9; }
.scope-badge, .subtle-chip, .pill { border: 1px solid rgba(42, 124, 220, .2); border-radius: 999px; color: #286ab7; background: rgba(55, 139, 234, .08); }
.scope-badge { padding: 6px 10px; font-size: 12px; }
.ghost-button, .theme-toggle, .refresh-button, .small-button, .pagination button, .quick-range button { border: 1px solid var(--line); color: #42546b; background: rgba(255, 255, 255, .82); cursor: pointer; }
.ghost-button { padding: 8px 12px; border-radius: 10px; }
.theme-toggle { padding: 8px 12px; border-radius: 10px; }
.login-wrap { display: grid; grid-template-columns: 1.2fr .8fr; align-items: center; gap: clamp(40px, 8vw, 130px); min-height: calc(100vh - 120px); padding: 48px 6vw; }
.login-copy { max-width: 690px; }
.login-copy h2 { margin-top: 24px; font-size: clamp(42px, 6.2vw, 78px); }
.login-copy > p { max-width: 590px; color: #65768d; font-size: 17px; line-height: 1.8; }
.pill { display: inline-flex; padding: 7px 12px; font-size: 12px; }
.trust-row { display: flex; flex-wrap: wrap; gap: 20px; margin-top: 34px; color: #657991; font-size: 12px; }
.trust-row span::before { content: "✓"; margin-right: 7px; color: #5dd8a5; }
.login-card { display: grid; gap: 20px; padding: 34px; border: 1px solid var(--line); border-radius: 24px; background: rgba(255, 255, 255, .94); box-shadow: 0 24px 70px rgba(38, 68, 105, .14); backdrop-filter: blur(20px); }
.login-card h3 { margin: 4px 0 8px; font-size: 27px; }
.muted { color: var(--muted); line-height: 1.6; }
.login-card label, .filters label, .detail-filters label { display: grid; gap: 7px; color: #66788f; font-size: 12px; }
.key-field { display: flex; border: 1px solid rgba(83, 108, 140, .2); border-radius: 13px; background: #f4f7fb; overflow: hidden; }
.key-field:focus-within { border-color: rgba(76, 158, 255, .72); box-shadow: 0 0 0 3px rgba(52, 133, 235, .1); }
.key-field input { width: 100%; min-width: 0; padding: 14px 15px; border: 0; outline: 0; color: #172033; background: transparent; }
.key-field button { border: 0; padding: 0 15px; color: #7f94ad; background: transparent; cursor: pointer; }
.login-card .remember-option { display: flex; align-items: flex-start; gap: 10px; cursor: pointer; }
.remember-option input { width: 16px; height: 16px; margin: 2px 0 0; accent-color: #347fcf; }
.remember-option span { display: grid; gap: 3px; }
.remember-option strong { color: #42546b; font-size: 12px; font-weight: 650; }
.remember-option small { color: #8191a5; font-size: 10px; line-height: 1.5; }
.primary-button { padding: 14px 18px; border: 0; border-radius: 13px; color: white; font-weight: 700; background: linear-gradient(110deg, #278cff, #6557f5); box-shadow: 0 12px 28px rgba(39, 140, 255, .23); cursor: pointer; }
.primary-button:disabled { opacity: .6; cursor: wait; }
.error-text { min-height: 18px; margin: -8px 0 0; color: #ff7f8b; font-size: 12px; }
.dashboard { padding-top: 70px; }
.welcome-row { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
.welcome-row h2 { margin-bottom: 7px; font-size: 34px; }
.welcome-row p { margin-bottom: 0; }
.refresh-button { display: inline-flex; gap: 8px; align-items: center; padding: 10px 14px; border-radius: 11px; }
.refresh-button:hover, .ghost-button:hover, .theme-toggle:hover, .small-button:hover, .pagination button:hover { border-color: rgba(38, 117, 208, .4); color: #145daa; }
.filters { display: flex; flex-wrap: wrap; align-items: end; gap: 12px; margin-bottom: 18px; padding: 12px; border: 1px solid var(--line); border-radius: 15px; background: rgba(255, 255, 255, .68); }
.filters input, .filters select, .detail-filters input, .detail-filters select { min-height: 36px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 9px; outline: none; color: #27364a; background: #f8fafc; }
.quick-range { display: flex; padding: 3px; border-radius: 10px; background: #edf2f8; }
.quick-range button { padding: 8px 12px; border: 0; border-radius: 8px; background: transparent; }
.quick-range button.active { color: white; background: #347fcf; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 18px; }
.stat-card { position: relative; overflow: hidden; min-height: 118px; padding: 22px; border: 1px solid var(--line); border-radius: 18px; background: linear-gradient(145deg, #ffffff, #f5f8fc); box-shadow: 0 10px 30px rgba(39, 68, 101, .06); }
.stat-card::after { position: absolute; content: ""; width: 90px; height: 90px; right: -32px; top: -32px; border-radius: 50%; filter: blur(22px); opacity: .24; }
.accent-blue::after { background: #3e9eff; }.accent-violet::after { background: #7758ff; }.accent-emerald::after { background: #32d399; }.accent-amber::after { background: #f6a836; }
.stat-card span { color: #72839a; font-size: 12px; }
.stat-card strong { display: block; margin: 15px 0 7px; font-size: clamp(25px, 3vw, 36px); letter-spacing: -.04em; }
.stat-card small { display: none; }
.dashboard .eyebrow { display: none; }
.panel { margin-top: 18px; border: 1px solid var(--line); border-radius: 19px; background: var(--panel); box-shadow: 0 18px 50px rgba(45, 73, 105, .08); overflow: hidden; }
.panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 20px 22px; border-bottom: 1px solid var(--line); }
.ranking-actions { display: flex; align-items: center; gap: 12px; }
.cost-ranking-chip { padding: 7px 11px; border: 1px solid rgba(53, 126, 212, .15); border-radius: 9px; color: #3979bd; background: rgba(59, 135, 220, .08); font-size: 10px; font-weight: 800; letter-spacing: .04em; }
.podium-section { position: relative; padding: 30px; overflow-x: auto; background: linear-gradient(180deg, #f6f8fb, #f2f5f8); }
.podium { display: grid; grid-template-columns: repeat(3, minmax(210px, 1fr)); align-items: end; gap: 14px; width: 100%; padding-top: 10px; }
.podium-card { display: flex; flex-direction: column; min-width: 0; text-align: center; }
.podium-card-body { position: relative; display: flex; align-items: center; flex-direction: column; min-height: 270px; padding: 24px 22px 21px; border: 1px solid #dce3ea; border-top-width: 3px; border-radius: 18px 18px 0 0; background: #ffffff; box-shadow: 0 8px 24px rgba(40, 55, 72, .055); isolation: isolate; overflow: hidden; }
.podium-1 .podium-card-body { border-top-color: #b79752; background: #fffdfa; }
.podium-2 .podium-card-body { border-top-color: #84919e; background: #fbfcfd; }
.podium-3 .podium-card-body { border-top-color: #aa7a61; background: #fdfbf9; }
.podium-base { display: grid; place-items: center; border: 1px solid #d8e0e7; border-top: 0; border-radius: 0 0 12px 12px; color: rgba(74, 87, 102, .34); background: #e9eef2; font-size: 18px; font-weight: 850; letter-spacing: .06em; }
.podium-1 .podium-base { height: 58px; border-color: #ded2b8; color: rgba(128, 100, 41, .42); background: #eee6d4; }
.podium-2 .podium-base { height: 42px; background: #e3e9ee; }
.podium-3 .podium-base { height: 32px; border-color: #dfd1ca; color: rgba(129, 91, 72, .4); background: #eee2dc; }
.podium-watermark { position: absolute; right: 14px; bottom: -20px; z-index: -1; color: rgba(64, 77, 93, .035); font-size: 92px; font-weight: 900; letter-spacing: -.08em; }
.podium-medal { position: absolute; top: 18px; left: 18px; display: grid; place-items: center; width: 29px; height: 29px; border: 1px solid #d3dbe3; border-radius: 9px; color: #667687; background: #f4f6f8; font-size: 11px; font-weight: 850; }
.podium-1 .podium-medal { border-color: #dbc99f; color: #826729; background: #faf5e9; }
.podium-3 .podium-medal { border-color: #dcc5b9; color: #8e654f; background: #f8f0ec; }
.podium-icon { display: grid; place-items: center; width: 44px; height: 44px; margin: 18px 0 13px; border: 1px solid currentColor; border-radius: 13px; }
.podium-icon svg { width: 22px; height: 22px; }
.podium-icon-1 { color: #9a7938; background: #fbf7ed; }
.podium-icon-2 { color: #748391; background: #f3f6f8; }
.podium-icon-3 { color: #9b6d55; background: #f8f1ed; }
.podium-place { margin-bottom: 9px; color: #7b8999; font-size: 9px; font-weight: 800; letter-spacing: .14em; }
.podium-1 .podium-place { color: #92743a; }
.podium-identity { width: 100%; }
.podium-identity strong { display: block; overflow: hidden; color: #1c2f47; font-size: 17px; font-weight: 850; text-overflow: ellipsis; white-space: nowrap; }
.podium-identity small { display: block; margin-top: 5px; overflow: hidden; color: #71849a; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.defending-card-badge { display: inline-flex; margin-top: 8px; padding: 4px 8px; border: 1px solid #ddcfad; border-radius: 7px; color: #80672f; background: #faf6ec; font-size: 8px; font-weight: 800; letter-spacing: .05em; }
.podium-praise { margin-top: 14px; color: #56667a; font-size: 10px; font-weight: 800; letter-spacing: .06em; }
.podium-metric-label { margin-top: auto; padding-top: 17px; color: #8996a6; font-size: 9px; font-weight: 700; letter-spacing: .08em; }
.podium-metric { margin-top: 4px; color: #305f8d; font-size: 19px; letter-spacing: -.02em; }
.podium-1 .podium-metric { color: #826425; font-size: 20px; }
.honors { display: flex; align-items: center; justify-content: center; gap: 5px; }
.podium-honors { margin-top: 12px; }
.honor { display: inline-flex; padding: 4px 7px; border: 1px solid transparent; border-radius: 999px; font-size: 9px; font-weight: 850; white-space: nowrap; }
.honor-gold { border-color: #e0d2b3; color: #81682f; background: #faf6ed; }
.honor-silver { border-color: #d7dee5; color: #697887; background: #f5f7f9; }
.honor-bronze { border-color: #e1d0c7; color: #8d6652; background: #faf4f1; }
.table-honors { justify-content: flex-start; }
.table-honors .honor { padding: 3px 6px; font-size: 8px; }
.subtle-chip { padding: 6px 10px; color: #687e98; font-size: 11px; border-color: var(--line); background: #f3f7fb; }
.table-wrap { width: 100%; overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th { padding: 11px 16px; color: #6b7d93; background: #f5f8fb; font-size: 10px; font-weight: 800; letter-spacing: .08em; text-align: left; text-transform: uppercase; white-space: nowrap; }
td { padding: 14px 16px; border-top: 1px solid rgba(90, 110, 136, .1); color: #35465c; font-size: 13px; }
tbody tr:hover td { background: rgba(58, 126, 203, .055); }
.top-rank-row td { background: rgba(249, 251, 254, .72); }
.top-rank-1 td { background: #fbf8ef; }
.top-rank-2 td { background: #f4f7f9; }
.top-rank-3 td { background: #faf5f2; }
.num { text-align: right; font-variant-numeric: tabular-nums; }
.rank { display: grid; place-items: center; width: 27px; height: 27px; border-radius: 8px; color: #60758d; background: #edf2f7; font-weight: 800; }
.rank.top-1 { color: #80662c; background: #f7f0de; }.rank.top-2 { color: #667686; background: #eaf0f4; }.rank.top-3 { color: #8e6652; background: #f4e9e3; }
.rank-trend { display: inline-flex; align-items: center; padding: 4px 7px; border: 1px solid transparent; border-radius: 7px; font-size: 9px; font-weight: 800; white-space: nowrap; }
.rank-up { border-color: #cfe3d9; color: #3f765f; background: #f0f7f3; }
.rank-down { border-color: #ead7d2; color: #996458; background: #faf4f2; }
.rank-same { border-color: #dce2e8; color: #718091; background: #f5f7f9; }
.rank-new { border-color: #d8dcef; color: #676f9c; background: #f4f5fa; }
.user-cell strong, .model-cell strong { display: block; color: #1f3045; font-weight: 650; }
.user-cell small, .model-cell small { display: block; margin-top: 4px; color: #75869b; font-size: 11px; }
.user-name-line { display: flex; min-width: 0; align-items: center; gap: 7px; }
.user-name-line > strong { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.baseline-badge {
  display: inline-flex;
  flex: 0 0 auto;
  padding: 2px 6px;
  border: 1px solid rgba(75, 122, 103, .24);
  border-radius: 999px;
  color: #557d6d;
  background: rgba(89, 139, 119, .09);
  font-size: 8px;
  font-weight: 750;
  line-height: 1.35;
  letter-spacing: 0;
  text-transform: lowercase;
}
.key-line { display: flex; align-items: center; gap: 8px; min-height: 24px; }
.key-line small { margin-top: 0; }
.key-disable-button { padding: 3px 7px; border: 1px solid rgba(174, 79, 73, .2); border-radius: 7px; color: #9b5550; background: rgba(174, 79, 73, .06); font-size: 9px; font-weight: 750; cursor: pointer; }
.key-disable-button:hover { border-color: rgba(174, 79, 73, .38); color: #843f3a; background: rgba(174, 79, 73, .1); }
.key-disable-button:disabled { opacity: .55; cursor: wait; }
.key-status { display: inline-flex; padding: 3px 7px; border-radius: 7px; font-size: 9px; font-weight: 750; white-space: nowrap; }
.key-status-inactive { border: 1px solid rgba(113, 128, 145, .18); color: #778493; background: rgba(113, 128, 145, .07); }
.defending-inline { display: inline-flex; margin-top: 7px; padding: 3px 7px; border: 1px solid rgba(188, 128, 18, .18); border-radius: 999px; color: #956109; background: rgba(230, 174, 54, .11); font-size: 8px; font-weight: 900; letter-spacing: .06em; }
.bar-track { width: 110px; height: 5px; border-radius: 99px; background: #e4ebf3; overflow: hidden; }
.bar-fill { height: 100%; border-radius: inherit; background: linear-gradient(90deg, #2e91ff, #725cff); }
.usage-heading { align-items: end; }
.detail-filters { display: flex; align-items: end; gap: 9px; }
.small-button { min-height: 36px; padding: 8px 13px; border-radius: 9px; }
.detail-table { min-width: 1120px; }
.endpoint { display: inline-flex; padding: 4px 7px; border-radius: 7px; color: #3578bc; background: rgba(39, 116, 194, .08); font-size: 10px; }
.empty-state { padding: 45px; color: #667e9a; text-align: center; }
.pagination { display: flex; align-items: center; justify-content: space-between; padding: 14px 20px; border-top: 1px solid var(--line); color: #6f849d; font-size: 12px; }
.pagination button { padding: 7px 11px; border-radius: 8px; margin-left: 7px; }
.pagination button:disabled { opacity: .35; cursor: not-allowed; }
.toast { position: fixed; left: 50%; bottom: 30px; transform: translate(-50%, 20px); padding: 10px 15px; border: 1px solid var(--line); border-radius: 10px; color: #ffffff; background: #274a73; opacity: 0; pointer-events: none; transition: .22s ease; box-shadow: 0 14px 45px rgba(38, 67, 101, .22); }
.toast.show { transform: translate(-50%, 0); opacity: 1; }

html[data-theme="dark"] {
  color: #eef4ff;
  background: #07101f;
  --panel: rgba(13, 25, 44, .9);
  --panel-strong: #0f1d32;
  --line: rgba(148, 163, 184, .16);
  --muted: #8fa0b8;
}
html[data-theme="dark"] body { background: radial-gradient(circle at top, #102446 0, #07101f 42%, #050b15 100%); }
html[data-theme="dark"] .text-link { color: #a8b8ce; }
html[data-theme="dark"] .text-link:hover { color: #ffffff; }
html[data-theme="dark"] .scope-badge,
html[data-theme="dark"] .pill { color: #9cc9ff; background: rgba(37, 112, 195, .12); }
html[data-theme="dark"] .ghost-button,
html[data-theme="dark"] .theme-toggle,
html[data-theme="dark"] .refresh-button,
html[data-theme="dark"] .small-button,
html[data-theme="dark"] .pagination button { color: #c6d2e3; background: rgba(18, 33, 55, .78); }
html[data-theme="dark"] .login-copy > p { color: #9eafc4; }
html[data-theme="dark"] .trust-row { color: #7287a3; }
html[data-theme="dark"] .login-card { background: linear-gradient(145deg, rgba(19, 37, 63, .96), rgba(9, 19, 34, .94)); box-shadow: 0 24px 80px rgba(0, 0, 0, .28); }
html[data-theme="dark"] .login-card label,
html[data-theme="dark"] .filters label,
html[data-theme="dark"] .detail-filters label { color: #9aabc0; }
html[data-theme="dark"] .remember-option strong { color: #b7c7d9; }
html[data-theme="dark"] .remember-option small { color: #71859e; }
html[data-theme="dark"] .key-field { border-color: rgba(144, 168, 199, .2); background: #091424; }
html[data-theme="dark"] .key-field input { color: #f6f9ff; }
html[data-theme="dark"] .filters { background: rgba(9, 19, 34, .68); }
html[data-theme="dark"] .filters input,
html[data-theme="dark"] .filters select,
html[data-theme="dark"] .detail-filters input,
html[data-theme="dark"] .detail-filters select { color: #dce8f8; background: #0b1728; }
html[data-theme="dark"] .quick-range,
html[data-theme="dark"] .cost-ranking-chip { color: #8fc4ff; background: rgba(42, 112, 192, .13); }
html[data-theme="dark"] .stat-card { background: linear-gradient(145deg, rgba(19, 35, 58, .94), rgba(10, 21, 37, .9)); box-shadow: none; }
html[data-theme="dark"] .stat-card span { color: #8fa2ba; }
html[data-theme="dark"] .stat-card small { color: #637a96; }
html[data-theme="dark"] .panel { box-shadow: 0 18px 55px rgba(0, 0, 0, .16); }
html[data-theme="dark"] .subtle-chip { color: #8ea6c2; background: rgba(11, 24, 42, .8); }
html[data-theme="dark"] .podium-section { background: #0c1725; }
html[data-theme="dark"] .podium-card-body { border-color: rgba(139, 158, 185, .16); background: #111f2f; box-shadow: 0 8px 24px rgba(0, 0, 0, .14); }
html[data-theme="dark"] .podium-1 .podium-card-body { border-top-color: #a88a4c; background: #201e19; }
html[data-theme="dark"] .podium-2 .podium-card-body { border-top-color: #788795; background: #151f2b; }
html[data-theme="dark"] .podium-3 .podium-card-body { border-top-color: #916b58; background: #201b1a; }
html[data-theme="dark"] .podium-base { border-color: #2d3b4a; color: rgba(185, 199, 214, .28); background: #182534; }
html[data-theme="dark"] .podium-1 .podium-base { border-color: #4c422d; color: rgba(212, 183, 121, .34); background: #2b281f; }
html[data-theme="dark"] .podium-3 .podium-base { border-color: #493832; color: rgba(204, 154, 130, .32); background: #2b2422; }
html[data-theme="dark"] .podium-medal { border-color: #354457; color: #aebccc; background: #192737; }
html[data-theme="dark"] .podium-icon-1 { color: #c0a369; background: rgba(151, 117, 50, .1); }
html[data-theme="dark"] .podium-icon-2 { color: #9cabb9; background: rgba(112, 131, 149, .1); }
html[data-theme="dark"] .podium-icon-3 { color: #bd8d74; background: rgba(147, 94, 67, .1); }
html[data-theme="dark"] .podium-identity strong { color: #eef4fc; }
html[data-theme="dark"] .podium-identity small { color: #70849e; }
html[data-theme="dark"] .podium-praise { color: #9eafc2; }
html[data-theme="dark"] .defending-card-badge,
html[data-theme="dark"] .defending-inline { border-color: rgba(223, 168, 57, .24); color: #f0c76d; background: rgba(178, 124, 21, .15); }
html[data-theme="dark"] .podium-metric-label { color: #657a94; }
html[data-theme="dark"] .honor-gold { color: #f1ca72; background: rgba(192, 137, 25, .15); }
html[data-theme="dark"] .honor-silver { color: #b8c7d7; background: rgba(137, 156, 178, .14); }
html[data-theme="dark"] .honor-bronze { color: #e4a47e; background: rgba(181, 99, 51, .14); }
html[data-theme="dark"] th { color: #627894; background: rgba(7, 16, 29, .55); }
html[data-theme="dark"] td { border-top-color: rgba(148, 163, 184, .09); color: #cbd7e8; }
html[data-theme="dark"] tbody tr:hover td { background: rgba(35, 79, 127, .08); }
html[data-theme="dark"] .top-rank-row td { background: rgba(17, 33, 54, .6); }
html[data-theme="dark"] .top-rank-1 td { background: rgba(74, 62, 35, .32); }
html[data-theme="dark"] .top-rank-2 td { background: rgba(45, 57, 70, .46); }
html[data-theme="dark"] .top-rank-3 td { background: rgba(69, 49, 41, .38); }
html[data-theme="dark"] .rank { color: #7890aa; background: #111f34; }
html[data-theme="dark"] .rank.top-1 { color: #ffe9a4; background: rgba(213, 154, 36, .17); }
html[data-theme="dark"] .rank.top-2 { color: #dce8f5; background: rgba(157, 177, 201, .15); }
html[data-theme="dark"] .rank.top-3 { color: #ffc494; background: rgba(198, 106, 45, .15); }
html[data-theme="dark"] .rank-up { border-color: rgba(83, 143, 115, .26); color: #83c3a5; background: rgba(55, 113, 86, .13); }
html[data-theme="dark"] .rank-down { border-color: rgba(164, 99, 83, .28); color: #d7a095; background: rgba(130, 72, 59, .14); }
html[data-theme="dark"] .rank-same { border-color: rgba(119, 137, 158, .22); color: #94a5b7; background: rgba(76, 94, 115, .13); }
html[data-theme="dark"] .rank-new { border-color: rgba(111, 119, 177, .24); color: #aab0df; background: rgba(77, 83, 137, .14); }
html[data-theme="dark"] .user-cell strong,
html[data-theme="dark"] .model-cell strong { color: #e9f1fc; }
html[data-theme="dark"] .user-cell small,
html[data-theme="dark"] .model-cell small { color: #607691; }
html[data-theme="dark"] .key-disable-button { border-color: rgba(210, 120, 112, .24); color: #d99a94; background: rgba(156, 75, 69, .12); }
html[data-theme="dark"] .key-disable-button:hover { border-color: rgba(225, 135, 127, .4); color: #f0b1aa; background: rgba(172, 82, 75, .18); }
html[data-theme="dark"] .key-status-inactive { border-color: rgba(137, 153, 172, .2); color: #8fa0b3; background: rgba(91, 107, 127, .12); }
html[data-theme="dark"] .baseline-badge { border-color: rgba(126, 171, 151, .28); color: #9fcab7; background: rgba(83, 132, 111, .16); }
html[data-theme="dark"] .bar-track { background: #14243a; }
html[data-theme="dark"] .endpoint { color: #7eb6f2; background: rgba(39, 116, 194, .1); }

@media (max-width: 1050px) {
  .login-wrap { grid-template-columns: 1fr; padding: 70px 6vw; }
  .login-copy { display: none; }
  .login-card { width: min(520px, 100%); margin: auto; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .usage-heading { align-items: start; flex-direction: column; }
}
@media (max-width: 680px) {
  .shell { width: min(100% - 24px, 1500px); padding-top: 16px; }
  .text-link { display: none; }
  .dashboard { padding-top: 48px; }
  .welcome-row { align-items: start; flex-direction: column; }
  .stats-grid { grid-template-columns: 1fr; }
  .filters, .detail-filters { align-items: stretch; flex-direction: column; }
  .filters label, .detail-filters label { width: 100%; }
  .filters input, .filters select, .detail-filters input, .detail-filters select { width: 100%; }
  .quick-range { width: 100%; }
  .quick-range button { flex: 1; }
  .panel-heading { align-items: start; flex-direction: column; }
  .ranking-actions { width: 100%; align-items: stretch; flex-direction: column; }
  .podium { width: 700px; }
  .login-card { padding: 25px; }
}


/* dashboard-view-tabs */
.view-tabs { display: inline-flex; gap: 4px; margin-bottom: 22px; padding: 4px; border: 1px solid var(--line); border-radius: 13px; background: rgba(255, 255, 255, .72); box-shadow: 0 8px 24px rgba(39, 68, 101, .05); }
.view-tab { min-width: 150px; padding: 10px 18px; border: 0; border-radius: 9px; color: #66788f; background: transparent; font-weight: 700; cursor: pointer; }
.view-tab.active { color: #fff; background: #2f78c9; box-shadow: 0 6px 16px rgba(47, 120, 201, .2); }
.view-section { animation: view-enter .18s ease-out; }
@keyframes view-enter { from { opacity: .55; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.previous-period-button { min-height: 36px; padding: 8px 13px; border: 1px solid var(--line); border-radius: 9px; color: #3d668f; background: #f8fafc; font-weight: 700; cursor: pointer; }
.previous-period-button:hover { border-color: rgba(38, 117, 208, .4); color: #145daa; }
.usage-date-filters { margin-top: 0; }
.request-status { display: inline-flex; align-items: center; gap: 6px; padding: 5px 9px; border: 1px solid transparent; border-radius: 999px; font-size: 11px; font-weight: 750; white-space: nowrap; }
.request-status::before { width: 6px; height: 6px; border-radius: 50%; content: ""; background: currentColor; }
.status-completed { border-color: rgba(49, 137, 95, .16); color: #3a8b65; background: rgba(49, 137, 95, .08); }
.status-running { border-color: rgba(47, 120, 201, .18); color: #347fcf; background: rgba(47, 120, 201, .09); }
html[data-theme="dark"] .view-tabs { background: rgba(9, 19, 34, .72); }
html[data-theme="dark"] .view-tab { color: #8ea2bb; }
html[data-theme="dark"] .view-tab.active { color: #fff; background: #2b6dad; }
html[data-theme="dark"] .previous-period-button { border-color: rgba(144, 168, 199, .2); color: #a9bfd8; background: #0b1728; }
html[data-theme="dark"] .status-completed { color: #83c3a5; background: rgba(55, 113, 86, .13); }
html[data-theme="dark"] .status-running { color: #8fc4ff; background: rgba(42, 112, 192, .13); }
@media (max-width: 680px) {
  .view-tabs { display: flex; width: 100%; }
  .view-tab { flex: 1; min-width: 0; padding-inline: 10px; }
  .previous-period-button { width: 100%; }
}

/* codex-install-docs */
.docs-view { color: #26384d; }
.docs-hero { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(300px, .65fr); gap: 28px; align-items: center; margin-bottom: 22px; padding: 34px; border: 1px solid var(--line); border-radius: 22px; background: linear-gradient(135deg, rgba(255,255,255,.94), rgba(241,247,253,.92)); box-shadow: 0 18px 48px rgba(39, 68, 101, .08); }
.docs-kicker { display: inline-flex; margin-bottom: 14px; color: #3978bb; font-size: 10px; font-weight: 850; letter-spacing: .16em; }
.docs-hero h2 { margin-bottom: 12px; font-size: clamp(30px, 4vw, 48px); }
.docs-hero p { max-width: 720px; margin: 0; color: #66798f; font-size: 15px; line-height: 1.8; }
.docs-endpoint-card { display: grid; gap: 11px; padding: 22px; border: 1px solid rgba(51, 124, 207, .16); border-radius: 16px; background: rgba(246, 250, 255, .92); }
.docs-endpoint-card > span { color: #788ba1; font-size: 10px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.docs-endpoint-card code { overflow-wrap: anywhere; color: #245f9f; font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 13px; }
.docs-layout { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 20px; align-items: start; }
.docs-toc { position: sticky; top: 18px; display: grid; gap: 5px; padding: 17px; border: 1px solid var(--line); border-radius: 16px; background: rgba(255,255,255,.75); }
.docs-toc span { margin: 2px 9px 8px; color: #8a99ab; font-size: 9px; font-weight: 850; letter-spacing: .12em; }
.docs-toc a { padding: 9px; border-radius: 9px; color: #5b6e84; text-decoration: none; font-size: 12px; font-weight: 650; }
.docs-toc a:hover { color: #2365aa; background: rgba(48, 126, 211, .07); }
.docs-content { display: grid; gap: 16px; }
.docs-card { scroll-margin-top: 22px; padding: 26px; border: 1px solid var(--line); border-radius: 18px; background: var(--panel); box-shadow: 0 10px 32px rgba(42, 70, 103, .055); }
.installer-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.installer-card { position: relative; display: flex; min-height: 178px; padding: 19px; border: 1px solid var(--line); border-radius: 14px; flex-direction: column; color: inherit; background: #f8fafc; text-decoration: none; transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease; }
.installer-card::after { position: absolute; content: ""; width: 48px; height: 48px; top: 14px; right: 14px; border-radius: 50%; filter: blur(18px); opacity: .2; }
.installer-macos::after { background: #7d91a8; }
.installer-linux::after { background: #d79d43; }
.installer-windows::after { background: #3b8edf; }
.installer-card:hover { transform: translateY(-2px); border-color: rgba(53, 127, 210, .28); box-shadow: 0 12px 25px rgba(42, 75, 112, .08); }
.installer-platform { color: #8292a5; font-size: 8px; font-weight: 900; letter-spacing: .14em; }
.installer-card strong { margin-top: 23px; color: #263b53; font-size: 15px; }
.installer-card small { margin-top: 7px; color: #718297; font-size: 10px; line-height: 1.55; }
.installer-card em { margin-top: auto; padding-top: 18px; color: #3679be; font-size: 10px; font-style: normal; font-weight: 800; }
.installer-help { display: grid; gap: 8px; margin-top: 14px; }
.installer-help > div { display: grid; grid-template-columns: 72px 1fr; gap: 10px; align-items: baseline; padding: 9px 12px; border-radius: 9px; background: rgba(68, 112, 159, .045); }
.installer-help strong { color: #4c627a; font-size: 10px; }
.installer-help span { color: #74869a; font-size: 10px; line-height: 1.6; }
.installer-help code { overflow-wrap: anywhere; color: #3e6e9f; }
.installer-command { margin-top: 12px; }
.remote-support-card { position: relative; overflow: hidden; padding: 17px 19px; border: 1px solid rgba(63, 130, 202, .28); border-radius: 11px; color: #fff; background: linear-gradient(135deg, #315f91, #397fc5); box-shadow: 0 10px 24px rgba(36, 95, 157, .13); }
.remote-support-card::after { position: absolute; content: ""; width: 120px; height: 120px; right: -42px; bottom: -58px; border-radius: 50%; background: rgba(255,255,255,.1); }
.remote-support-heading { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.remote-support-heading span { color: rgba(255,255,255,.76); font-size: 9px; font-weight: 900; letter-spacing: .13em; }
.remote-support-heading em { padding: 4px 7px; border: 1px solid rgba(255,255,255,.2); border-radius: 999px; color: rgba(255,255,255,.86); background: rgba(255,255,255,.08); font-size: 9px; font-style: normal; font-weight: 750; }
.remote-support-card > strong { position: relative; z-index: 1; display: block; margin-top: 10px; color: #fff; font-size: 16px; }
.remote-support-card > p { position: relative; z-index: 1; margin: 5px 0 13px; color: rgba(255,255,255,.76); font-size: 11px; line-height: 1.55; }
.remote-support-meta { position: relative; z-index: 1; display: flex; align-items: end; justify-content: space-between; gap: 14px; }
.remote-support-meta > div { display: grid; gap: 2px; }
.remote-support-meta small { color: rgba(255,255,255,.62); font-size: 9px; }
.remote-support-meta code { color: #fff; font-size: 14px; font-weight: 900; letter-spacing: .02em; }
.remote-support-meta b { padding: 6px 9px; border-radius: 7px; color: #244d78; background: #fff; font-size: 10px; white-space: nowrap; }
.docs-toc .remote-support-card { margin-top: 9px; padding: 14px; }
.docs-toc .remote-support-card > strong { font-size: 13px; line-height: 1.45; }
.docs-toc .remote-support-card > p { margin-bottom: 10px; font-size: 10px; }
.docs-toc .remote-support-meta { display: grid; align-items: start; }
.docs-toc .remote-support-meta b { justify-self: start; margin-top: 7px; }
.remote-tool-link { position: relative; z-index: 1; display: grid; grid-template-columns: 1fr auto; gap: 2px 8px; align-items: center; margin-top: 11px; padding-top: 10px; border-top: 1px solid rgba(255,255,255,.18); color: #fff; text-decoration: none; }
.remote-tool-link span { grid-column: 1 / -1; color: rgba(255,255,255,.62); font-size: 8px; }
.remote-tool-link strong { color: #fff; font-size: 11px; }
.remote-tool-link em { color: rgba(255,255,255,.82); font-size: 9px; font-style: normal; font-weight: 750; }
.remote-tool-link:hover strong,
.remote-tool-link:hover em { text-decoration: underline; }
.desktop-downloads { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 20px; align-items: center; margin-top: 18px; padding: 18px; border: 1px solid var(--line); border-radius: 13px; background: rgba(65, 137, 213, .045); }
.desktop-downloads span { display: block; color: #8292a5; font-size: 8px; font-weight: 900; letter-spacing: .14em; }
.desktop-downloads strong { display: block; margin-top: 6px; color: #304a66; font-size: 14px; }
.desktop-downloads p { max-width: 560px; margin: 6px 0 0; color: #718297; font-size: 10px; line-height: 1.65; }
.desktop-download-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.desktop-download-actions a { padding: 9px 12px; border-radius: 8px; color: #fff; background: #397fc5; font-size: 10px; font-weight: 800; text-decoration: none; white-space: nowrap; }
.desktop-download-actions a.secondary { color: #4b6682; border: 1px solid var(--line); background: transparent; }
.docs-divider { display: flex; align-items: center; gap: 12px; margin: 22px 0 13px; color: #8997a7; font-size: 9px; }
.docs-divider::before, .docs-divider::after { height: 1px; content: ""; background: var(--line); flex: 1; }
.docs-step { display: flex; gap: 15px; align-items: flex-start; margin-bottom: 20px; }
.docs-step > span { display: grid; flex: 0 0 34px; place-items: center; width: 34px; height: 34px; border: 1px solid rgba(52, 126, 207, .2); border-radius: 10px; color: #3274ba; background: rgba(52, 126, 207, .07); font-size: 11px; font-weight: 850; }
.docs-step h3 { margin: 1px 0 7px; font-size: 19px; }
.docs-step p { margin: 0; color: #718197; font-size: 13px; line-height: 1.65; }
.docs-card code { font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace; }
.code-block { position: relative; overflow: hidden; border: 1px solid #dbe4ee; border-radius: 13px; background: #f6f9fc; }
.code-label { padding: 9px 13px; border-bottom: 1px solid #dbe4ee; color: #8493a5; background: #edf3f8; font-size: 9px; font-weight: 800; letter-spacing: .08em; }
.code-block pre { overflow-x: auto; margin: 0; padding: 18px 92px 18px 18px; color: #28425f; font-size: 12px; line-height: 1.75; white-space: pre; }
.code-block.compact pre { padding-block: 15px; }
.copy-button { justify-self: start; padding: 7px 11px; border: 1px solid rgba(51, 123, 201, .2); border-radius: 8px; color: #2c6fb5; background: rgba(54, 133, 219, .07); font-size: 10px; font-weight: 750; cursor: pointer; }
.code-block > .copy-button { position: absolute; top: 10px; right: 10px; }
.code-block .code-label + pre + .copy-button { top: 42px; }
.copy-button:hover { border-color: rgba(51, 123, 201, .4); background: rgba(54, 133, 219, .12); }
.docs-os-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px; }
.docs-os-grid > div > strong { display: block; margin-bottom: 9px; color: #52667e; font-size: 11px; }
.docs-note { margin: 14px 0 0; color: #8090a3; font-size: 11px; }
.docs-callout { margin-top: 14px; padding: 15px 17px; border-left: 3px solid #4b8ed5; border-radius: 0 10px 10px 0; background: rgba(65, 137, 213, .06); }
.docs-callout strong { color: #386fa8; font-size: 11px; }
.docs-callout p { margin: 5px 0 0; color: #6c7e92; font-size: 11px; line-height: 1.65; }
.docs-checks { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 14px; }
.docs-checks span { padding: 10px 12px; border: 1px solid rgba(50, 139, 99, .13); border-radius: 9px; color: #4e7e67; background: rgba(50, 139, 99, .05); font-size: 10px; }
.docs-faq details { border-top: 1px solid var(--line); }
.docs-faq summary { padding: 15px 2px; color: #42576f; font-size: 12px; font-weight: 750; cursor: pointer; }
.docs-faq details p { margin: -3px 2px 15px; color: #718399; font-size: 11px; line-height: 1.7; }
.docs-faq details a { color: #3478bc; text-decoration: none; }
.docs-faq details a:hover { text-decoration: underline; }
.docs-footer-note { padding: 6px; color: #8a98a9; font-size: 10px; text-align: center; }
.docs-footer-note a { margin-right: 3px; color: #4c7fb5; text-decoration: none; }
.docs-footer-note a:hover { text-decoration: underline; }

html[data-theme="dark"] .docs-view { color: #dbe7f5; }
html[data-theme="dark"] .docs-hero { background: linear-gradient(135deg, rgba(17,32,53,.96), rgba(9,20,36,.95)); box-shadow: none; }
html[data-theme="dark"] .docs-hero p { color: #91a4bc; }
html[data-theme="dark"] .docs-endpoint-card { border-color: rgba(90, 154, 223, .18); background: rgba(11,25,44,.88); }
html[data-theme="dark"] .docs-endpoint-card code { color: #91c5fc; }
html[data-theme="dark"] .docs-toc { background: rgba(10,22,38,.78); }
html[data-theme="dark"] .docs-toc a { color: #91a5be; }
html[data-theme="dark"] .docs-card { box-shadow: none; }
html[data-theme="dark"] .installer-card { background: #0d1a2a; }
html[data-theme="dark"] .installer-card strong { color: #e5eef9; }
html[data-theme="dark"] .installer-card small { color: #8195ad; }
html[data-theme="dark"] .installer-help > div { background: rgba(80, 124, 172, .07); }
html[data-theme="dark"] .installer-help strong { color: #a9bbcf; }
html[data-theme="dark"] .installer-help span { color: #8195ad; }
html[data-theme="dark"] .remote-support-card { border-color: rgba(107, 174, 243, .3); background: linear-gradient(135deg, #21466f, #286aa8); box-shadow: none; }
html[data-theme="dark"] .desktop-downloads { background: rgba(58,122,190,.08); }
html[data-theme="dark"] .desktop-downloads strong { color: #dce9f8; }
html[data-theme="dark"] .desktop-downloads p { color: #8195ad; }
html[data-theme="dark"] .desktop-download-actions a.secondary { color: #aec2d8; }
html[data-theme="dark"] .docs-step h3 { color: #edf4fd; }
html[data-theme="dark"] .docs-step p { color: #8397b0; }
html[data-theme="dark"] .code-block { border-color: rgba(132,155,184,.16); background: #091522; }
html[data-theme="dark"] .code-label { border-color: rgba(132,155,184,.13); color: #70859e; background: #0d1b2c; }
html[data-theme="dark"] .code-block pre { color: #bad2ec; }
html[data-theme="dark"] .docs-os-grid > div > strong { color: #a4b6ca; }
html[data-theme="dark"] .docs-callout { background: rgba(58,122,190,.1); }
html[data-theme="dark"] .docs-callout p,
html[data-theme="dark"] .docs-faq details p { color: #8195ae; }
html[data-theme="dark"] .docs-faq summary { color: #becde0; }

@media (max-width: 900px) {
  .docs-hero { grid-template-columns: 1fr; }
  .docs-layout { grid-template-columns: 1fr; }
  .docs-toc { position: static; grid-template-columns: repeat(5, auto); overflow-x: auto; }
  .docs-toc span { display: none; }
  .docs-toc a { white-space: nowrap; }
  .docs-toc .remote-support-card { grid-column: 1 / -1; }
  .installer-grid { grid-template-columns: 1fr; }
  .installer-card { min-height: 146px; }
}
@media (max-width: 680px) {
  .docs-hero, .docs-card { padding: 21px; }
  .docs-os-grid, .docs-checks, .desktop-downloads { grid-template-columns: 1fr; }
  .desktop-download-actions { justify-content: flex-start; }
  .code-block pre { padding-right: 18px; padding-top: 52px; font-size: 11px; }
  .code-block .code-label + pre { padding-top: 52px; }
  .code-block > .copy-button, .code-block .code-label + pre + .copy-button { top: 10px; }
  .code-label { display: none; }
}

/* light data console */
:root {
  color-scheme: light;
  --app-bg: #f4f7fb;
  --surface: #ffffff;
  --surface-soft: #edf3f9;
  --ink: #142033;
  --muted: #687991;
  --line: #dbe3ed;
  --blue: #2369b7;
  --blue-strong: #174f91;
  --green: #147d57;
  --red: #a94747;
  --gold: #956c1e;
}
body { color: var(--ink); background: var(--app-bg); }
.ambient { display: none; }
.shell { width: min(1380px, calc(100% - 40px)); padding: 0 0 40px; }
.topbar { min-height: 68px; border-bottom: 1px solid var(--line); background: var(--surface); }
.brand { gap: 10px; }
.brand-mark { width: 36px; height: 36px; border: 0; border-radius: 9px; color: #fff; background: var(--blue); box-shadow: none; font-size: 17px; }
.brand .eyebrow { display: none; }
.brand h1 { font-size: 15px; }
.top-actions { gap: 6px; }
.scope-badge { padding: 5px 9px; font-size: 11px; }
.ghost-button, .theme-toggle, .refresh-button, .small-button, .pagination button { min-height: 44px; padding: 0 13px; border-radius: 9px; color: #52647b; background: var(--surface); }
.text-link { display: inline-flex; align-items: center; min-height: 44px; padding: 0 9px; font-size: 12px; }
.dashboard { padding-top: 26px; }
.welcome-row { align-items: center; margin-bottom: 18px; }
.welcome-row h2 { margin: 4px 0 3px; font-size: 28px; }
.welcome-row .eyebrow { display: block; color: var(--muted); letter-spacing: .1em; }
.dashboard-subtitle { color: var(--muted); font-size: 12px; }
.view-tabs { display: flex; width: fit-content; margin-bottom: 14px; padding: 3px; border: 0; border-radius: 10px; background: var(--surface-soft); box-shadow: none; }
.view-tab { min-width: 128px; min-height: 42px; padding: 0 14px; border-radius: 8px; color: var(--muted); font-size: 13px; }
.view-tab.active { color: var(--blue-strong); background: var(--surface); box-shadow: 0 1px 3px rgba(36, 58, 82, .12); }
.filters { align-items: end; gap: 10px; margin-bottom: 14px; padding: 10px; border-color: var(--line); border-radius: 12px; background: var(--surface); }
.quick-range { padding: 3px; border-radius: 9px; background: var(--surface-soft); }
.quick-range button { min-width: 72px; min-height: 38px; padding: 0 12px; color: var(--muted); }
.quick-range button.active { color: #fff; background: var(--blue); }
.previous-period-button { min-height: 44px; padding: 0 13px; border-color: var(--line); border-radius: 9px; color: #52647b; background: var(--surface); }
.filters label, .detail-filters label { gap: 4px; color: var(--muted); font-size: 10px; }
.filters input, .filters select, .detail-filters input, .detail-filters select { min-height: 44px; padding: 0 11px; border-color: var(--line); color: var(--ink); background: var(--surface); font-size: 13px; }
.stats-grid { grid-template-columns: repeat(4, 1fr); gap: 0; margin: 17px 0; border-block: 1px solid var(--line); }
.stat-card { min-height: 0; padding: 15px 20px; border: 0; border-right: 1px solid var(--line); border-radius: 0; background: transparent; box-shadow: none; }
.stat-card:last-child { border-right: 0; }
.stat-card::after { display: none; }
.stat-card span, .stat-card small { display: block; color: var(--muted); font-size: 11px; }
.stat-card strong { margin: 6px 0 3px; font-size: 24px; font-variant-numeric: tabular-nums; }
.panel { margin-top: 0; border-color: var(--line); border-radius: 13px; background: var(--surface); box-shadow: none; }
.panel-heading, .full-ranking-heading { display: flex; align-items: end; justify-content: space-between; gap: 20px; padding: 17px 18px 12px; }
.panel-heading { border-bottom: 0; }
.panel-heading h3, .full-ranking-heading h3 { font-size: 18px; }
.panel-heading .eyebrow, .full-ranking-heading .eyebrow { display: block; margin-bottom: 3px; color: var(--muted); letter-spacing: .11em; }
.ranking-actions { gap: 8px; }
.cost-ranking-chip, .subtle-chip { padding: 6px 9px; border-color: var(--line); color: var(--muted); background: var(--surface-soft); font-weight: 650; letter-spacing: 0; }
.podium-section { padding: 0 18px 18px; background: transparent; overflow: visible; }
.podium { grid-template-columns: 1.15fr 1fr 1fr; gap: 0; padding: 0; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); overflow: hidden; }
.podium-card { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: center; gap: 12px; min-height: 76px; padding: 14px 16px; border-right: 1px solid var(--line); text-align: left; }
.podium-card:last-child { border-right: 0; }
.podium-1 { background: #fffaf0; }
.podium-medal { position: static; width: 30px; height: 30px; border-color: transparent; border-radius: 8px; color: var(--gold); background: #fff4d8; }
.podium-identity { min-width: 0; }
.podium-identity strong, .podium-identity small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.podium-identity strong { font-size: 13px; }
.podium-identity small { margin-top: 4px; font-size: 10px; }
.podium-metric { margin: 0; color: var(--blue-strong); font-size: 15px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.podium-1 .podium-metric { color: var(--gold); font-size: 15px; }
.full-ranking-heading { padding-top: 17px; border-top: 1px solid var(--line); }
.full-ranking-heading > span { color: var(--muted); font-size: 11px; }
.table-wrap { border-top: 1px solid var(--line); }
th { padding: 10px 12px; color: var(--muted); background: #f8fafc; font-size: 10px; letter-spacing: 0; text-transform: none; }
td { padding: 11px 12px; border-top-color: var(--line); color: #35465c; font-size: 12px; }
.top-rank-row td, .top-rank-1 td, .top-rank-2 td, .top-rank-3 td { background: transparent; }
.rank { width: 30px; height: 30px; }
.rank-trend { border: 0; background: transparent; font-size: 10px; }
.rank-up { color: var(--green); }
.rank-down { color: var(--red); }
.rank-same { color: var(--muted); }
.rank-new { color: #676f9c; }
.honor { padding: 3px 5px; border: 0; border-radius: 5px; }
.bar-track { display: inline-block; width: 64px; height: 4px; margin-right: 6px; vertical-align: middle; }
.bar-fill { background: var(--blue); }
.share-cell { white-space: nowrap; }
.share-value { color: var(--muted); font-size: 10px; font-variant-numeric: tabular-nums; }
.research-baseline-row td { background: #f1f6f4 !important; }
.research-baseline-row td:first-child { box-shadow: inset 3px 0 0 #6f9285; }
.research-baseline-row:hover td { background: #eaf2ef !important; }
.mobile-ranking-list { display: none; }
.refresh-button:disabled { opacity: .55; cursor: wait; }
.toast { z-index: 1000; }
button, a, select, input { transition: border-color .18s ease, color .18s ease, background-color .18s ease, box-shadow .18s ease, opacity .18s ease; }
button:focus-visible, a:focus-visible, select:focus-visible, input:focus-visible, summary:focus-visible { outline: 3px solid rgba(35, 105, 183, .3); outline-offset: 2px; }

html[data-theme="dark"] { color-scheme: dark; --app-bg: #081321; --surface: #0e1c2c; --surface-soft: #142437; --ink: #edf4ff; --muted: #91a3bb; --line: #28384c; --blue: #71b3ff; --blue-strong: #9dccff; --green: #65d6a9; --red: #ef9999; --gold: #dfbd70; }
html[data-theme="dark"] body { color: var(--ink); background: var(--app-bg); }
html[data-theme="dark"] .topbar, html[data-theme="dark"] .filters, html[data-theme="dark"] .panel, html[data-theme="dark"] .podium, html[data-theme="dark"] .ghost-button, html[data-theme="dark"] .theme-toggle, html[data-theme="dark"] .refresh-button, html[data-theme="dark"] .previous-period-button { background: var(--surface); }
html[data-theme="dark"] .view-tabs, html[data-theme="dark"] .quick-range, html[data-theme="dark"] .cost-ranking-chip, html[data-theme="dark"] .subtle-chip { background: var(--surface-soft); }
html[data-theme="dark"] .view-tab.active { color: var(--blue-strong); background: #1a2c40; }
html[data-theme="dark"] .filters input, html[data-theme="dark"] .filters select, html[data-theme="dark"] .detail-filters input, html[data-theme="dark"] .detail-filters select { color: var(--ink); background: var(--surface); }
html[data-theme="dark"] .stat-card { background: transparent; }
html[data-theme="dark"] .podium-1 { background: #211d14; }
html[data-theme="dark"] .podium-card { border-color: var(--line); }
html[data-theme="dark"] .podium-medal { color: var(--gold); background: #282215; }
html[data-theme="dark"] .podium-identity strong { color: var(--ink); }
html[data-theme="dark"] th { color: var(--muted); background: #0a1725; }
html[data-theme="dark"] td, html[data-theme="dark"] .top-rank-row td, html[data-theme="dark"] .top-rank-1 td, html[data-theme="dark"] .top-rank-2 td, html[data-theme="dark"] .top-rank-3 td { color: #cbd7e8; background: transparent; }
html[data-theme="dark"] .research-baseline-row td { background: #132620 !important; }
html[data-theme="dark"] .research-baseline-row td:first-child { box-shadow: inset 3px 0 0 #719b8a; }
html[data-theme="dark"] .research-baseline-row:hover td { background: #182e27 !important; }

@media (max-width: 900px) {
  .podium { grid-template-columns: 1fr; }
  .podium-card { border-right: 0; border-bottom: 1px solid var(--line); }
  .podium-card:last-child { border-bottom: 0; }
}

@media (max-width: 680px) {
  .shell { width: 100%; padding: 0 14px 28px; }
  .topbar { display: grid; grid-template-columns: 1fr auto; gap: 10px; margin-inline: -14px; padding: 10px 14px; }
  .brand h1 { font-size: 14px; }
  .top-actions { justify-content: end; }
  .top-actions .scope-badge, .top-actions .text-link, .top-actions .public-docs-button, .top-actions #logoutButton { display: none !important; }
  .theme-toggle { min-width: 88px; }
  .dashboard { padding-top: 20px; }
  .welcome-row { align-items: center; flex-direction: row; gap: 12px; }
  .welcome-row h2 { font-size: 23px; }
  .dashboard-subtitle { display: none; }
  .refresh-button { flex: 0 0 44px; width: 44px; padding: 0; justify-content: center; overflow: hidden; white-space: nowrap; color: transparent; }
  .refresh-button span { display: none; }
  .refresh-button::before { content: "↻"; color: var(--blue-strong); font-size: 18px; }
  .view-tabs { width: 100%; }
  .view-tab { min-width: 0; min-height: 44px; font-size: 12px; }
  .filters { align-items: stretch; flex-direction: row; flex-wrap: wrap; }
  .quick-range { width: 100%; }
  .quick-range button { min-height: 44px; flex: 1; }
  .previous-period-button { width: calc(50% - 5px); }
  .filters label { width: calc(50% - 5px); }
  .filters label:nth-last-child(-n+2) { width: calc(50% - 5px); }
  .filters label select, .filters label input { width: 100%; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .stat-card { padding: 13px 12px; }
  .stat-card:nth-child(2) { border-right: 0; }
  .stat-card:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .stat-card strong { font-size: 20px; }
  .stat-card small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .panel-heading { align-items: end; flex-direction: row; padding-inline: 14px; }
  .ranking-actions { width: auto; align-items: end; }
  .cost-ranking-chip { display: none; }
  .podium-section { padding: 0 14px 14px; }
  .podium-card { grid-template-columns: auto minmax(0, 1fr) auto; min-height: 72px; padding: 12px; }
  .podium-card .rank-trend { grid-column: 3; }
  .podium-metric { grid-column: 3; grid-row: 1; }
  .podium-card > .rank-trend { display: none; }
  .full-ranking-heading { padding-inline: 14px; }
  .leaderboard-panel > .table-wrap { display: none; }
  .mobile-ranking-list { display: grid; padding: 0 14px; }
  .mobile-ranking-card { padding: 14px 0; border-top: 1px solid var(--line); }
  .mobile-ranking-card header { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 10px; }
  .mobile-ranking-identity { min-width: 0; }
  .mobile-ranking-identity strong, .mobile-ranking-identity small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .mobile-ranking-identity strong { font-size: 13px; }
  .mobile-ranking-identity small { margin-top: 3px; color: var(--muted); font-size: 10px; }
  .research-baseline-card { margin-inline: -14px; padding-inline: 14px; background: #f1f6f4; box-shadow: inset 3px 0 0 #6f9285; }
  html[data-theme="dark"] .research-baseline-card { background: #132620; box-shadow: inset 3px 0 0 #719b8a; }
  .mobile-ranking-metric { display: block; margin: 11px 0 3px; color: var(--blue-strong); font-size: 19px; font-variant-numeric: tabular-nums; }
  .mobile-ranking-card p { margin: 0; color: var(--muted); font-size: 11px; }
  .mobile-ranking-card footer { display: flex; align-items: center; justify-content: space-between; margin-top: 10px; }
  .mobile-honors { justify-content: flex-start; }
  .mobile-share { color: var(--muted); font-size: 11px; }
  .ranking-actions .subtle-chip { max-width: 152px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
}

@media (max-width: 420px) {
  .previous-period-button, .filters label { width: 100%; }
}

/* Nexum cinematic operations console */
:root,
html[data-theme="dark"] {
  color-scheme: dark;
  --nexum-ink: #f7f7f5;
  --nexum-muted: rgba(255, 255, 255, .68);
  --nexum-glass: rgba(255, 255, 255, .10);
  --nexum-glass-strong: rgba(12, 12, 12, .72);
  --nexum-line: rgba(255, 255, 255, .15);
  --nexum-black: #010101;
  --nexum-green: #8ed9a7;
  --nexum-amber: #f1ca79;
  --nexum-red: #f29a95;
  --app-bg: #010101;
  --surface: rgba(12, 12, 12, .72);
  --surface-soft: rgba(255, 255, 255, .08);
  --ink: var(--nexum-ink);
  --muted: var(--nexum-muted);
  --line: var(--nexum-line);
  --blue: #ffffff;
  --blue-strong: #ffffff;
}

* { box-sizing: border-box; }
html, body { width: 100%; height: 100%; overflow: hidden; }
body {
  margin: 0;
  min-width: 320px;
  min-height: 100%;
  color: var(--nexum-ink);
  background: #010101;
  font-family: 'Geist', -apple-system, BlinkMacSystemFont, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
.background-video {
  position: fixed;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.ambient { display: none; }
.shell {
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  margin: 0;
  padding: 0;
  overflow: hidden;
}

.topbar {
  position: relative;
  z-index: 50;
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: space-between;
  min-height: 0;
  padding: 20px;
  border: 0;
  background: transparent;
}
html[data-theme="dark"] .topbar { border: 0; background: transparent; }
.brand {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 8px;
  padding: 0;
  border: 0;
  color: var(--nexum-black);
  background: transparent;
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.brand:focus-visible { outline: 2px solid currentColor; outline-offset: 5px; border-radius: 4px; }
.brand-mark {
  display: block;
  width: 24px;
  height: 24px;
  border: 0;
  border-radius: 0;
  fill: currentColor;
  background: transparent;
  box-shadow: none;
}
.brand h1 { margin: 0; color: currentColor; font-size: 18px; font-weight: 600; line-height: 1.2; letter-spacing: 0; }
.desktop-nav { display: none; align-items: stretch; gap: 12px; }
.desktop-nav-cluster {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .10);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
}
.desktop-nav button {
  min-height: 34px;
  padding: 6px 16px;
  border: 0;
  border-radius: 999px;
  color: rgba(255, 255, 255, .8);
  background: transparent;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: color .2s ease, background-color .2s ease;
}
.desktop-nav button:hover,
.desktop-nav button.active { color: #fff; background: rgba(255, 255, 255, .10); }
.nav-cta,
.mobile-menu-footer a,
.mobile-menu-footer button,
.primary-button {
  border: 0;
  color: #fff;
  background: linear-gradient(to bottom, #2b2b2b, #101010);
  box-shadow: none;
  text-decoration: none;
  transition: opacity .2s ease;
}
.nav-cta { display: inline-flex; align-items: center; padding: 0 20px; border-radius: 999px; font-size: 14px; font-weight: 500; }
.nav-cta:hover, .mobile-menu-footer a:hover, .primary-button:hover { opacity: .9; }
.top-actions { display: none; }
.mobile-menu-button {
  position: relative;
  z-index: 50;
  display: grid;
  width: 44px;
  height: 44px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 999px;
  color: var(--nexum-black);
  background: rgba(255, 255, 255, .10);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  cursor: pointer;
}
.mobile-menu-button svg {
  position: absolute;
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  transition: transform .3s ease, opacity .3s ease;
}
.mobile-menu-button .close-icon { opacity: 0; transform: rotate(-90deg) scale(0); }
.mobile-menu-button.open .menu-icon { opacity: 0; transform: rotate(90deg) scale(0); }
.mobile-menu-button.open .close-icon { opacity: 1; transform: rotate(0) scale(1); color: #fff; }
.mobile-menu-backdrop {
  position: fixed;
  inset: 0;
  z-index: 40;
  opacity: 0;
  background: rgba(0, 0, 0, .80);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  pointer-events: none;
  transition: opacity .3s ease;
}
.mobile-menu-backdrop.open { opacity: 1; pointer-events: auto; }
.mobile-menu-panel {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 40;
  display: flex;
  flex-direction: column;
  width: 288px;
  height: 100%;
  padding: 96px 24px 40px;
  background: rgba(0, 0, 0, .90);
  -webkit-backdrop-filter: blur(24px);
  backdrop-filter: blur(24px);
  transform: translateX(100%);
  transition: transform .5s cubic-bezier(.16, 1, .3, 1);
}
.mobile-menu-panel.open { transform: translateX(0); }
.mobile-menu-panel nav { display: grid; gap: 8px; }
.mobile-menu-panel nav button {
  min-height: 52px;
  padding: 14px 16px;
  border: 0;
  border-radius: 12px;
  color: rgba(255, 255, 255, .8);
  background: transparent;
  font-size: 16px;
  font-weight: 500;
  text-align: left;
  opacity: 0;
  transform: translateX(24px);
  cursor: pointer;
  transition: color .2s ease, background-color .2s ease, opacity .3s ease, transform .3s ease;
}
.mobile-menu-panel.open nav button { opacity: 1; transform: translateX(0); }
.mobile-menu-panel.open nav button:nth-child(1) { transition-delay: 60ms; }
.mobile-menu-panel.open nav button:nth-child(2) { transition-delay: 120ms; }
.mobile-menu-panel.open nav button:nth-child(3) { transition-delay: 180ms; }
.mobile-menu-panel.open nav button:nth-child(4) { transition-delay: 240ms; }
.mobile-menu-panel nav button:hover,
.mobile-menu-panel nav button.active { color: #fff; background: rgba(255, 255, 255, .10); }
.mobile-menu-footer { display: grid; gap: 10px; margin-top: auto; opacity: 0; transform: translateY(16px); transition: opacity .4s ease .3s, transform .4s ease .3s; }
.mobile-menu-panel.open .mobile-menu-footer { opacity: 1; transform: translateY(0); }
.mobile-menu-footer a,
.mobile-menu-footer button { min-height: 48px; padding: 14px 18px; border-radius: 999px; font-size: 14px; font-weight: 500; text-align: center; cursor: pointer; }
.mobile-menu-footer button { background: rgba(255, 255, 255, .10); }
.mobile-menu-open { overflow: hidden; }

.login-wrap {
  display: grid;
  grid-template-columns: 1fr;
  align-items: end;
  gap: 24px;
  width: 100%;
  min-height: 0;
  margin-top: auto;
  padding: 24px 20px 32px;
  overflow-y: auto;
}
.login-copy { display: block; max-width: 576px; color: var(--nexum-black); }
.sr-only { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; border: 0 !important; }
.login-copy h2 {
  margin: 0;
  color: var(--nexum-black);
  font-size: 30px;
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: 0;
}
.login-card {
  display: grid;
  width: 100%;
  max-width: 520px;
  gap: 10px;
  margin-top: 24px;
  padding: 0;
  border: 0;
  border-radius: 0;
  color: var(--nexum-black);
  background: transparent;
  box-shadow: none;
}
html[data-theme="dark"] .login-card { background: transparent; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
.login-cta-row { display: grid; gap: 12px; }
.key-field { min-height: 48px; border: 0; border-radius: 999px; background: #fff; }
.key-field input { color: #171717; }
.key-field button { flex: 0 0 52px; min-width: 52px; color: #4c4c4c; white-space: nowrap; }
html[data-theme="dark"] .key-field { background: #fff; }
html[data-theme="dark"] .key-field input { color: #171717; }
.login-card .primary-button { min-height: 48px; padding: 12px 24px; border-radius: 999px; font-size: 14px; font-weight: 500; }
.login-card .remember-option { margin-left: 4px; color: rgba(1, 1, 1, .68); }
html[data-theme="dark"] .login-card .remember-option { color: rgba(1, 1, 1, .68); }
.login-card .remember-option strong,
.login-card .remember-option small { color: inherit; }
.login-card .error-text { margin: 0 4px; }
.hero-support-cards { display: flex; flex-direction: column; gap: 16px; width: 100%; }
.hero-glass-card {
  padding: 20px;
  border: 0;
  border-radius: 16px;
  color: var(--nexum-black);
  background: rgba(255, 255, 255, .10);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
}
.hero-stat-card { display: flex; flex-direction: column; justify-content: space-between; }
.hero-stat-card > strong { color: var(--nexum-black); font-size: 20px; font-weight: 600; letter-spacing: 0; }
.hero-stat-card p { margin: 12px 0 0; color: rgba(1, 1, 1, .70); font-size: 14px; line-height: 1.6; }
.hero-card-heading { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.hero-card-heading > span { display: grid; width: 24px; height: 24px; place-items: center; border-radius: 5px; color: #fff; background: #010101; font-size: 12px; font-weight: 700; }
.hero-card-heading > strong { color: var(--nexum-black); font-size: 20px; font-weight: 600; }
.hero-feature-card > p { margin: 0; color: rgba(1, 1, 1, .80); font-size: 14px; line-height: 1.6; }

@media (max-width: 420px) {
  .brand { max-width: calc(100% - 56px); }
  .brand-mark { flex: 0 0 22px; width: 22px; height: 22px; }
  .brand h1 { font-size: 15px; overflow-wrap: anywhere; }
}

.dashboard,
.docs-view {
  width: calc(100% - 40px);
  max-width: 1500px;
  min-height: 0;
  margin: 0 auto;
  padding: 14px 0 32px;
  overflow-x: hidden;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, .25) transparent;
}
.dashboard { flex: 1 1 auto; }
.welcome-row { align-items: end; margin: 0 0 18px; color: #fff; }
.welcome-row h2 { margin: 4px 0 5px; color: #fff; font-size: 28px; letter-spacing: 0; }
.welcome-row .eyebrow,
.dashboard-subtitle { color: rgba(255, 255, 255, .66); }
.dashboard:not([data-active-view="ranking"]) .welcome-row > div { display: none; }
.dashboard:not([data-active-view="ranking"]) .welcome-row { justify-content: flex-end; margin-bottom: 8px; }
.refresh-button,
.ghost-button,
.theme-toggle,
.small-button,
.pagination button,
.previous-period-button {
  min-height: 44px;
  border-color: rgba(255, 255, 255, .15);
  color: #fff;
  background: rgba(255, 255, 255, .10);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
}
.refresh-button:hover,
.ghost-button:hover,
.small-button:hover,
.pagination button:hover { color: #fff; border-color: rgba(255, 255, 255, .3); background: rgba(255, 255, 255, .16); }
.view-tabs { display: none; }
.filters,
.panel,
.docs-card,
.docs-hero,
.docs-toc,
.account-balance-card,
.balance-empty {
  border: 1px solid rgba(255, 255, 255, .15);
  background: rgba(255, 255, 255, .10);
  box-shadow: none;
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
}
.filters { padding: 10px; border-radius: 14px; }
.filters label, .detail-filters label { color: rgba(255, 255, 255, .64); }
.filters input,
.filters select,
.detail-filters input,
.detail-filters select,
html[data-theme="dark"] .filters input,
html[data-theme="dark"] .filters select,
html[data-theme="dark"] .detail-filters input,
html[data-theme="dark"] .detail-filters select { border-color: rgba(255, 255, 255, .16); color: #fff; background: rgba(0, 0, 0, .42); }
.quick-range { background: rgba(0, 0, 0, .30); }
.quick-range button { color: rgba(255, 255, 255, .68); }
.quick-range button.active { color: #fff; background: rgba(255, 255, 255, .16); }
.stats-grid { border-color: rgba(255, 255, 255, .14); }
.stat-card { border-color: rgba(255, 255, 255, .14); color: #fff; }
.stat-card span, .stat-card small { color: rgba(255, 255, 255, .66); }
.panel { border-radius: 16px; color: #fff; overflow: hidden; }
.podium,
html[data-theme="dark"] .podium { border-color: rgba(255, 255, 255, .13); background: rgba(0, 0, 0, .22); }
.podium-card { border-color: rgba(255, 255, 255, .12); }
.podium-1,
html[data-theme="dark"] .podium-1 { background: rgba(255, 255, 255, .08); }
.podium-medal,
html[data-theme="dark"] .podium-medal { color: #fff; background: rgba(255, 255, 255, .10); }
.podium-metric,
.podium-1 .podium-metric { color: #fff; }
.cost-ranking-chip,
.subtle-chip,
html[data-theme="dark"] .cost-ranking-chip,
html[data-theme="dark"] .subtle-chip { border-color: rgba(255, 255, 255, .13); color: rgba(255, 255, 255, .68); background: rgba(255, 255, 255, .08); }
.table-wrap { border-color: rgba(255, 255, 255, .12); }
th,
html[data-theme="dark"] th { color: rgba(255, 255, 255, .58); background: rgba(0, 0, 0, .28); }
td,
html[data-theme="dark"] td,
html[data-theme="dark"] .top-rank-row td,
html[data-theme="dark"] .top-rank-1 td,
html[data-theme="dark"] .top-rank-2 td,
html[data-theme="dark"] .top-rank-3 td { border-color: rgba(255, 255, 255, .10); color: rgba(255, 255, 255, .82); background: transparent; }

.balances-view { min-height: 100%; color: #fff; }
.balances-heading { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 20px; }
.balances-heading h2 { margin: 3px 0 5px; color: #fff; font-size: 30px; letter-spacing: 0; }
.balances-heading .eyebrow { margin-bottom: 0; color: rgba(255, 255, 255, .62); }
.balances-heading > div > span { color: rgba(255, 255, 255, .68); font-size: 13px; }
.balances-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.account-balance-card { display: grid; gap: 18px; min-height: 260px; padding: 22px; border-radius: 16px; }
.account-balance-card { background: rgba(0, 0, 0, .58); }
.account-balance-header { display: flex; align-items: start; justify-content: space-between; gap: 16px; }
.account-balance-identity span { color: rgba(255, 255, 255, .54); font-size: 10px; font-weight: 600; }
.account-balance-identity h3 { margin: 5px 0 0; color: #fff; font-size: 18px; letter-spacing: 0; }
.account-status { flex: 0 0 auto; padding: 5px 8px; border-radius: 999px; font-size: 11px; font-weight: 600; }
.account-status.available { color: #c9f4d6; background: rgba(84, 184, 117, .16); }
.account-status.unavailable { color: #ffd1cd; background: rgba(224, 96, 86, .16); }
.account-groups { display: flex; flex-wrap: wrap; gap: 6px; }
.account-groups span { padding: 5px 8px; border: 1px solid rgba(255, 255, 255, .12); border-radius: 999px; color: rgba(255, 255, 255, .72); background: rgba(0, 0, 0, .18); font-size: 11px; }
.quota-windows { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.quota-window { min-width: 0; }
.quota-window-header { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.quota-window-header span { color: rgba(255, 255, 255, .66); font-size: 12px; }
.quota-window-header strong { color: #fff; font-size: 24px; font-weight: 600; font-variant-numeric: tabular-nums; }
.quota-progress { height: 5px; margin: 8px 0; border-radius: 999px; background: rgba(255, 255, 255, .12); overflow: hidden; }
.quota-progress-fill { display: block; height: 100%; border-radius: inherit; background: var(--nexum-green); transition: width .35s ease; }
.quota-warning .quota-progress-fill { background: var(--nexum-amber); }
.quota-critical .quota-progress-fill { background: var(--nexum-red); }
.quota-window small { display: block; color: rgba(255, 255, 255, .48); font-size: 10px; line-height: 1.4; }
.account-balance-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: auto; padding-top: 14px; border-top: 1px solid rgba(255, 255, 255, .10); color: rgba(255, 255, 255, .52); font-size: 10px; }
.account-balance-footer .fresh { color: #b9ebc8; }
.account-balance-footer .stale { color: #f2d18d; }
.balance-empty { display: grid; gap: 8px; padding: 28px; border-radius: 16px; color: #fff; }
.balance-empty span { color: rgba(255, 255, 255, .62); font-size: 13px; }

.docs-hero,
.docs-card,
.docs-toc { color: #fff; background: rgba(8, 8, 8, .66); }
html[data-theme="dark"] .docs-hero { background: rgba(8, 8, 8, .66); }
.docs-hero p,
html[data-theme="dark"] .docs-hero p { color: rgba(255, 255, 255, .66); }

button:focus-visible,
a:focus-visible,
select:focus-visible,
input:focus-visible,
summary:focus-visible { outline: 3px solid rgba(255, 255, 255, .48); outline-offset: 2px; }

@media (min-width: 640px) {
  .topbar { padding: 24px 32px; }
  .login-wrap { grid-template-columns: 1fr; padding: 32px 32px 48px; }
  .login-copy h2 { font-size: 36px; }
  .login-cta-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 10px; width: 100%; }
  .login-cta-row .key-field { width: auto; min-height: 48px; border-radius: 999px; }
  .login-card .primary-button { min-height: 48px; padding: 11px 24px; }
  .hero-support-cards { flex-direction: row; }
  .hero-glass-card { flex: 1 1 0; max-width: 256px; padding: 24px; }
  .hero-stat-card > strong { font-size: 20px; }
  .dashboard, .docs-view { width: calc(100% - 64px); padding-bottom: 48px; }
}

@media (min-width: 768px) {
  .desktop-nav { display: flex; }
  .mobile-menu-button,
  .mobile-menu-backdrop,
  .mobile-menu-panel { display: none; }
}

@media (min-width: 1024px) {
  .topbar { padding: 24px 48px; }
  .brand { color: #fff; }
  .login-wrap { grid-template-columns: minmax(360px, 1fr) minmax(440px, 532px); gap: 32px; padding: 36px 48px 64px; }
  .login-copy { color: #fff; }
  .login-copy h2 { max-width: 520px; color: #fff; font-size: 48px; }
  .login-card .remember-option { color: rgba(255, 255, 255, .70); }
  html[data-theme="dark"] .login-card .remember-option { color: rgba(255, 255, 255, .70); }
  .hero-glass-card { color: #fff; }
  .hero-stat-card > strong,
  .hero-card-heading > strong { color: #fff; }
  .hero-stat-card p { color: rgba(255, 255, 255, .70); }
  .hero-feature-card > p { color: rgba(255, 255, 255, .80); }
  .dashboard, .docs-view { width: calc(100% - 96px); padding-bottom: 64px; }
}

@media (max-width: 1100px) {
  .balances-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 767px) {
  .topbar { display: flex; margin: 0; }
  .dashboard { width: calc(100% - 28px); padding-top: 8px; }
  .docs-view { width: calc(100% - 28px); }
  .welcome-row h2 { font-size: 23px; }
  .refresh-button { flex: 0 0 44px; width: 44px; padding: 0; justify-content: center; overflow: hidden; color: transparent; font-size: 0; white-space: nowrap; }
  .refresh-button span { display: none; }
  .refresh-button::before { content: "↻"; color: #fff; font-size: 18px; }
  .balances-heading { align-items: start; flex-direction: column; gap: 12px; }
  .balances-heading h2 { font-size: 26px; }
  .balances-grid { grid-template-columns: 1fr; }
  .account-balance-card { min-height: 0; padding: 18px; }
  .quota-window-header strong { font-size: 21px; }
}

@media (max-width: 520px) {
  .login-wrap { overflow-y: auto; }
  .login-card { padding: 0; }
  .quota-windows { grid-template-columns: 1fr; }
  .account-balance-footer { align-items: start; flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation: none !important; transition: none !important; }
}
