* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  background: radial-gradient(ellipse at top, #0a0d2e 0%, #050617 50%, #030410 100%);
  min-height: 100vh;
  font-family: -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", Roboto, sans-serif;
  color: #e0e7ff;
  display: flex; align-items: flex-start; justify-content: center;
  padding: 108px 30px 60px;
}

/* ── Nav ─────────────────────────────────────────────────────────── */
.top-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 9999;
  height: 48px;
  display: flex; align-items: center; gap: 4px;
  padding: 0 28px;
  background: rgba(5, 6, 23, 0.92);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid #1a1d3a;
}
.nav-brand {
  font-size: 13px; font-weight: 600; letter-spacing: 5px;
  color: #4ad6ff; margin-right: 20px; text-decoration: none;
}
.nav-tab {
  padding: 5px 16px; border-radius: 8px;
  font-size: 13px; font-weight: 500; letter-spacing: 0.5px;
  color: #5a608a; text-decoration: none;
  transition: all 0.2s; border: 1px solid transparent;
}
.nav-tab:hover { color: #c0c5e0; background: rgba(255,255,255,0.05); }
.nav-tab.nav-active {
  color: #4ad6ff; background: rgba(74,214,255,0.1);
  border-color: rgba(74,214,255,0.3);
}

/* ── Layout ──────────────────────────────────────────────────────── */
.page { width: 100%; max-width: 1290px; }

.card {
  background: rgba(7, 8, 28, 0.85);
  backdrop-filter: blur(12px);
  border: 1px solid #1a1d3a;
  border-radius: 30px;
  padding: 42px 48px;
  position: relative; overflow: hidden;
}
.card::before {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(ellipse 900px 300px at 20% 0%, rgba(74,214,255,0.07), transparent 70%),
    radial-gradient(ellipse 750px 300px at 80% 100%, rgba(181,102,255,0.05), transparent 70%);
}
.card > * { position: relative; }

/* ── Header ──────────────────────────────────────────────────────── */
.header {
  display: flex; justify-content: space-between; align-items: flex-end;
  margin-bottom: 36px;
}
.logo-mini { font-size: 15px; color: #5a608a; letter-spacing: 6px; }
.title { font-size: 39px; font-weight: 500; color: #4ad6ff; letter-spacing: 4.5px; margin-top: 6px; line-height: 1; }
.updated-label { margin-left: 20px; }
.live { display: flex; align-items: center; gap: 10px; font-size: 14px; color: #5a608a; }
.pulse-dot {
  width: 8px; height: 8px; border-radius: 50%; background: #4ade80;
  position: relative; flex-shrink: 0;
}
.pulse-dot::after {
  content: ''; position: absolute; inset: -4px; border-radius: 50%;
  background: #4ade80; animation: pulse-ring 2s ease-out infinite;
}
@keyframes pulse-ring {
  0%   { transform: scale(0.8); opacity: 0.6; }
  100% { transform: scale(2.4); opacity: 0; }
}

/* ── Tab bar ─────────────────────────────────────────────────────── */
.tab-bar {
  display: flex; gap: 6px; margin-bottom: 30px;
  border-bottom: 1px solid #1a1d3a; padding-bottom: 14px;
}
.tab-btn {
  padding: 9px 18px; border-radius: 10px; border: 1px solid transparent;
  background: transparent; color: #5a608a;
  font-size: 14px; font-family: inherit; font-weight: 500; cursor: pointer;
  transition: all 0.18s; display: flex; align-items: center; gap: 7px;
}
.tab-btn:hover { color: #c0c5e0; background: rgba(255,255,255,0.04); }
.tab-btn.active {
  color: #4ad6ff; background: rgba(74,214,255,0.1);
  border-color: rgba(74,214,255,0.25);
}
.tab-panel { display: none; }
.tab-panel.active { display: block; animation: fade-in 0.25s ease; }
@keyframes fade-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ── Stat grid ───────────────────────────────────────────────────── */
.stat-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px;
  margin-bottom: 24px;
}
.stat-grid-6 { grid-template-columns: repeat(6, 1fr); }
.stat-card {
  background: rgba(255,255,255,0.03);
  border: 1px solid #1a1d3a;
  border-radius: 16px;
  padding: 20px 22px;
  transition: border-color 0.2s;
}
.stat-card:hover { border-color: rgba(74,214,255,0.2); }
.stat-card-creator { border-color: rgba(245,184,10,0.12); }
.stat-card-creator:hover { border-color: rgba(245,184,10,0.3); }
.stat-icon { font-size: 22px; color: #4ad6ff; margin-bottom: 10px; }
.stat-val  { font-size: 28px; font-weight: 600; color: #e0e7ff; line-height: 1.1; font-variant-numeric: tabular-nums; }
.stat-val-sm { font-size: 17px; }
.stat-lbl  { font-size: 12px; color: #5a608a; letter-spacing: 1px; margin-top: 5px; }
.stat-sub  { font-size: 11px; color: #3a4060; margin-top: 3px; }

/* ── Panels (overview) ───────────────────────────────────────────── */
.panel {
  background: rgba(255,255,255,0.02);
  border: 1px solid #1a1d3a;
  border-radius: 16px;
  padding: 22px 24px;
  margin-bottom: 18px;
}
.panel-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 18px; }
.panel-title { font-size: 14px; font-weight: 600; color: #c0c5e0; }
.panel-hint  { font-size: 11px; color: #3a4060; font-weight: 400; }
.panel-legend { display: flex; gap: 16px; font-size: 12px; }
.lg { display: flex; align-items: center; gap: 6px; color: #5a608a; }
.lg::before { content: ''; width: 10px; height: 3px; border-radius: 2px; }
.lg-msg::before { background: #4ad6ff; }
.lg-usr::before { background: #b566ff; }

.overview-2col { display: grid; grid-template-columns: 1.3fr 1fr; gap: 18px; }

/* Growth chart */
.gc-wrap { position: relative; }
#growth-chart svg { width: 100%; height: 220px; display: block; overflow: visible; }
.gc-axis { font-size: 9px; fill: #3a4060; }
.gc-tooltip {
  position: absolute; top: 4px; transform: translateX(-50%);
  background: rgba(7,8,28,0.97); border: 1px solid #2a2d4a; border-radius: 9px;
  padding: 7px 11px; font-size: 12px; pointer-events: none; opacity: 0;
  transition: opacity 0.1s; white-space: nowrap; z-index: 5;
}
.gc-tt-date { color: #c0c5e0; font-weight: 600; margin-bottom: 4px; font-size: 11px; }
.gc-tt-row { color: #8890b0; display: flex; align-items: center; gap: 6px; }
.gc-tt-dot { width: 7px; height: 7px; border-radius: 50%; display: inline-block; }

/* Heatmap legend */
.hm-legend {
  display: flex; align-items: center; gap: 4px; justify-content: flex-end;
  margin-top: 12px; font-size: 10px; color: #5a608a;
}
.hm-leg-cell { width: 11px; height: 11px; border-radius: 2px; }

/* Heatmap */
.hm-grid { display: flex; flex-direction: column; gap: 3px; }
.hm-row  { display: flex; align-items: center; gap: 3px; }
.hm-daylabel { width: 30px; font-size: 10px; color: #5a608a; flex-shrink: 0; }
.hm-cell { flex: 1; aspect-ratio: 1; border-radius: 2px; min-width: 0; transition: transform 0.1s; }
.hm-cell:hover { transform: scale(1.35); outline: 1px solid #4ad6ff; }
.hm-hours { display: flex; gap: 3px; margin-left: 33px; margin-top: 5px; }
.hm-hour { flex: 1; font-size: 8px; color: #3a4060; text-align: center; }

/* Breakdown bars */
.bd-row { margin-bottom: 9px; }
.bd-head { display: flex; justify-content: space-between; font-size: 12px; margin-bottom: 4px; }
.bd-label { color: #8890b0; text-transform: capitalize; }
.bd-val { color: #e0e7ff; font-variant-numeric: tabular-nums; font-weight: 500; }
.bd-track { width: 100%; height: 7px; background: #14172e; border-radius: 4px; overflow: hidden; }
.bd-fill { height: 100%; border-radius: 4px; transition: width 0.5s ease; }

/* ── Controls row ────────────────────────────────────────────────── */
.controls-row {
  display: flex; justify-content: space-between; align-items: center;
  gap: 16px; margin-bottom: 20px; flex-wrap: wrap;
}
.filter-group { display: flex; gap: 6px; flex-wrap: wrap; }
.filter-btn {
  padding: 6px 14px; border-radius: 8px; border: 1px solid #1a1d3a;
  background: transparent; color: #5a608a;
  font-size: 13px; font-family: inherit; cursor: pointer;
  transition: all 0.18s; display: flex; align-items: center; gap: 5px;
}
.filter-btn:hover { color: #c0c5e0; background: rgba(255,255,255,0.05); }
.filter-btn.active {
  color: #4ad6ff; background: rgba(74,214,255,0.1);
  border-color: rgba(74,214,255,0.3);
}
.lb-search-wrap { position: relative; }
.lb-search-icon {
  position: absolute; left: 12px; top: 50%; transform: translateY(-50%);
  color: #5a608a; font-size: 14px; pointer-events: none;
}
.lb-search {
  background: rgba(255,255,255,0.04); border: 1px solid #1a1d3a;
  border-radius: 10px; padding: 7px 12px 7px 34px;
  color: #e0e7ff; font-size: 13px; font-family: inherit;
  width: 220px; outline: none; transition: border-color 0.2s;
}
.lb-search:focus { border-color: rgba(74,214,255,0.4); }

/* ── Column header ───────────────────────────────────────────────── */
.col-header {
  display: grid;
  grid-template-columns: 52px 1fr 80px 260px 60px;
  padding: 0 16px 10px;
  font-size: 11px; color: #3a4060; letter-spacing: 1.5px; font-weight: 600;
  border-bottom: 1px solid #1a1d3a;
}
.col-header-simple {
  grid-template-columns: 80px 1fr 540px;
  font-size: 14px; letter-spacing: 1.8px; padding: 0 22px 14px;
}
.ch-cscore { text-align: right; }
.ch-trend  { text-align: right; }

/* ── Table rows ──────────────────────────────────────────────────── */
.an-row {
  display: grid;
  grid-template-columns: 52px 1fr 80px 260px 60px;
  padding: 10px 16px;
  align-items: center;
  border-radius: 12px;
  cursor: pointer;
  transition: background 0.15s;
  border-bottom: 1px solid rgba(26,29,58,0.4);
}
.an-row:last-child { border-bottom: none; }
.an-row:hover { background: rgba(74,214,255,0.05); }

.an-row-simple {
  grid-template-columns: 80px 1fr 540px;
  padding: 16px 22px;
}
.an-row-simple .row-rank { font-size: 22px; }
.an-row-simple .row-avatar { width: 54px; height: 54px; font-size: 18px; }
.an-row-simple .row-name { font-size: 21px; }
.an-row-simple .row-handle { font-size: 15px; }

/* Big single-bar score */
.row-cscore-big { padding-left: 18px; }
.cscore-big-bar {
  position: relative;
  width: 100%; height: 38px;
  background: rgba(255,255,255,0.04);
  border: 1px solid #1a1d3a;
  border-radius: 10px;
  overflow: hidden;
}
.cscore-big-fill {
  position: absolute; top: 0; left: 0; bottom: 0;
  background: linear-gradient(90deg, rgba(74,214,255,0.35), rgba(181,102,255,0.45));
  border-right: 1px solid rgba(74,214,255,0.5);
  transition: width 0.4s ease;
}
.cscore-big-num {
  position: relative; z-index: 2;
  font-size: 19px; font-weight: 600; color: #e0e7ff;
  font-variant-numeric: tabular-nums;
  line-height: 38px; padding: 0 18px;
  display: flex; align-items: center; height: 100%;
  justify-content: flex-end;
}

.row-rank { font-size: 15px; font-weight: 600; color: #5a608a; font-variant-numeric: tabular-nums; }
.row-rank.top3 { color: #f5b80a; }

.row-user { display: flex; align-items: center; gap: 10px; min-width: 0; }
.row-avatar {
  width: 36px; height: 36px; border-radius: 50%; flex-shrink: 0;
  background: #1a1d3a; border: 1px solid #2a2d4a;
  background-size: cover; background-position: center;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; color: #5a608a; font-weight: 600;
}
.row-name-wrap { min-width: 0; flex: 1; }
.row-name   { font-size: 14px; font-weight: 500; color: #e0e7ff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row-handle { font-size: 11px; color: #5a608a; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ── Score cell ──────────────────────────────────────────────────── */
.row-cscore { text-align: right; }
.cscore-num { font-size: 18px; font-weight: 600; color: #4ad6ff; font-variant-numeric: tabular-nums; }
.cscore-bar-wrap {
  width: 52px; height: 3px; background: #1a1d3a; border-radius: 2px;
  margin-left: auto; margin-top: 5px;
}
.cscore-bar {
  height: 100%; border-radius: 2px;
  background: linear-gradient(90deg, #4ad6ff, #b566ff);
}

/* ── Component mini-bars ─────────────────────────────────────────── */
.row-bars {
  display: flex; gap: 6px; align-items: flex-end;
  height: 36px; padding: 0 4px;
}
.mini-col { display: flex; flex-direction: column; align-items: center; gap: 3px; flex: 1; }
.mini-track {
  width: 100%; height: 24px; background: #1a1d3a;
  border-radius: 3px; overflow: hidden; position: relative;
}
.mini-fill {
  position: absolute; bottom: 0; left: 0; right: 0;
  border-radius: 3px;
}
.mini-fill.act { background: #5865f2; }
.mini-fill.crt { background: #c8cacc; }
.mini-fill.inf { background: #b566ff; }
.mini-fill.con { background: #4ade80; }
.mini-dot { width: 5px; height: 5px; border-radius: 50%; }
.mini-dot.act { background: #5865f2; }
.mini-dot.crt { background: #c8cacc; }
.mini-dot.inf { background: #b566ff; }
.mini-dot.con { background: #4ade80; }

/* ── Trend ───────────────────────────────────────────────────────── */
.row-trend { text-align: right; font-size: 13px; font-weight: 600; }
.trend-up   { color: #4ade80; }
.trend-down { color: #f87171; }
.trend-flat { color: #3a4060; }

/* ── Tier badge ──────────────────────────────────────────────────── */
.tier-badge {
  display: inline-flex; padding: 2px 7px; border-radius: 5px;
  font-size: 10px; letter-spacing: 1px; font-weight: 600; flex-shrink: 0;
}
.tier-t5 { background: rgba(245,184,10,0.12); color: #f5b80a; border: 1px solid rgba(245,184,10,0.3); }
.tier-t3 { background: rgba(181,102,255,0.12); color: #b566ff; border: 1px solid rgba(181,102,255,0.3); }
.tier-t1 { background: rgba(74,144,226,0.12);  color: #4a90e2; border: 1px solid rgba(74,144,226,0.3); }

/* ── Pagination ──────────────────────────────────────────────────── */
.pagination { display: flex; align-items: center; justify-content: center; gap: 18px; padding: 24px 0 8px; }
.page-arrow {
  width: 34px; height: 34px; border-radius: 10px;
  background: rgba(255,255,255,0.04); border: 1px solid #1a1d3a;
  color: #5a608a; cursor: pointer; font-family: inherit;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; transition: all 0.18s;
}
.page-arrow:hover:not(:disabled) { color: #4ad6ff; border-color: rgba(74,214,255,0.4); }
.page-arrow:disabled { opacity: 0.3; cursor: default; }
.page-info { font-size: 13px; color: #5a608a; min-width: 90px; text-align: center; }

.footer { padding-top: 20px; text-align: center; font-size: 13px; color: #3a4060; }

/* ── Channels table ──────────────────────────────────────────────── */
.col-header-ch { grid-template-columns: 1fr 110px 120px 90px 120px 120px; }
.col-right { text-align: right; }
.chn-row {
  display: grid; grid-template-columns: 1fr 110px 120px 90px 120px 120px;
  padding: 12px 16px; align-items: center;
  border-bottom: 1px solid rgba(26,29,58,0.4);
  transition: background 0.15s;
}
.chn-row:hover { background: rgba(74,214,255,0.04); }
.chn-name-wrap { min-width: 0; }
.chn-name { font-size: 14px; color: #e0e7ff; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chn-cat  { font-size: 11px; color: #5a608a; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chn-num  { text-align: right; font-size: 14px; color: #c0c5e0; font-variant-numeric: tabular-nums; }
.ch-period-note { font-size: 12px; color: #5a608a; }
.chn-voice-ic { color: #b566ff; font-size: 13px; }

/* ── Spotlight tab ───────────────────────────────────────────────── */
.sp-controls { flex-wrap: wrap; gap: 12px; }
.sp-stats-line { font-size: 13px; color: #5a608a; margin-bottom: 14px; }
.sp-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
.sp-card {
  background: #0e1124;
  border: 1px solid #1a1d3a;
  border-radius: 14px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.18s, border-color 0.18s;
  position: relative;
}
.sp-card:hover { transform: translateY(-3px); border-color: rgba(74,214,255,0.35); }
.sp-card-img-wrap {
  width: 100%;
  aspect-ratio: 1;
  background: #1a1d3a center/cover no-repeat;
  position: relative;
}
.sp-card-img-wrap.video::after {
  content: "▶"; position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 36px; color: rgba(255,255,255,0.85);
  text-shadow: 0 0 14px rgba(0,0,0,0.5);
  pointer-events: none;
}
.sp-card-empty {
  width: 100%; aspect-ratio: 1;
  display: flex; align-items: center; justify-content: center;
  color: #3a4060; font-size: 11px; letter-spacing: 1px;
}
.sp-card-foot {
  padding: 9px 11px;
  display: flex; align-items: center; justify-content: space-between;
  font-size: 12px;
}
.sp-card-author { color: #c0c5e0; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sp-card-likes { color: #f87171; font-variant-numeric: tabular-nums; display: flex; align-items: center; gap: 4px; flex-shrink: 0; }
.sp-card-likes i { font-size: 13px; }

/* Spotlight modal */
.sp-modal {
  background: rgba(7,8,28,0.98);
  border: 1px solid #1a1d3a;
  border-radius: 22px;
  width: 100%; max-width: 720px;
  max-height: 92vh; overflow-y: auto;        /* контент скроллится, кнопка не обрезается */
  position: relative;
  animation: modal-in 0.2s ease;
  display: flex; flex-direction: column;
  scrollbar-width: thin;
  scrollbar-color: rgba(74,214,255,0.25) transparent;
}
.sp-modal::-webkit-scrollbar { width: 6px; }
.sp-modal::-webkit-scrollbar-track { background: transparent; }
.sp-modal::-webkit-scrollbar-thumb { background: rgba(74,214,255,0.18); border-radius: 3px; }
.sp-modal-media {
  width: 100%;
  max-height: 60vh; overflow: hidden;
  background: #050617 center/contain no-repeat;
  display: flex; align-items: center; justify-content: center;
}
.sp-modal-media img, .sp-modal-media video {
  max-width: 100%; max-height: 60vh; object-fit: contain; display: block;
}
.sp-modal-body { padding: 20px 24px 24px; }
.sp-modal-author {
  display: flex; align-items: center; gap: 10px;
  font-size: 16px; color: #e0e7ff; font-weight: 600; margin-bottom: 10px;
}
.sp-modal-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: #1a1d3a center/cover no-repeat;
  flex-shrink: 0;
}
.sp-modal-handle { font-size: 12px; color: #5a608a; font-weight: 400; }
.sp-modal-text {
  font-size: 14px; color: #b8c0e0; line-height: 1.55;
  margin-bottom: 14px;
  max-height: 120px; overflow-y: auto;
  white-space: pre-wrap;
}
.sp-modal-stats {
  display: flex; gap: 16px; font-size: 13px; color: #8890b0;
  margin-bottom: 14px; flex-wrap: wrap;
}
.sp-modal-stats span { display: flex; align-items: center; gap: 5px; }
.sp-modal-stats span.likes { color: #f87171; }
.sp-modal-stats span.views { color: #4ad6ff; }
.sp-modal-stats span.reposts { color: #4ade80; }
.sp-modal-stats span.date { color: #5a608a; }
.sp-modal-link {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 9px 16px; border-radius: 10px;
  background: rgba(74,214,255,0.12); color: #4ad6ff;
  border: 1px solid rgba(74,214,255,0.3);
  font-size: 13px; font-weight: 500; text-decoration: none;
  transition: background 0.15s;
}
.sp-modal-link:hover { background: rgba(74,214,255,0.2); }

@media (max-width: 1100px) { .sp-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 800px)  { .sp-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px)  { .sp-grid { grid-template-columns: 1fr; } .sp-card-img-wrap { aspect-ratio: 16/10; } }
.chn-growth { text-align: right; font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; }
.chn-status { text-align: right; }
.status-badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 10px; border-radius: 7px; font-size: 11px; font-weight: 600; letter-spacing: 0.5px;
}
.status-growing   { background: rgba(74,222,128,0.12); color: #4ade80; border: 1px solid rgba(74,222,128,0.3); }
.status-alive     { background: rgba(74,214,255,0.1);  color: #4ad6ff; border: 1px solid rgba(74,214,255,0.25); }
.status-declining { background: rgba(245,160,90,0.12); color: #f5a05a; border: 1px solid rgba(245,160,90,0.3); }
.status-dead      { background: rgba(90,96,138,0.12);  color: #5a608a; border: 1px solid rgba(90,96,138,0.3); }
.status-spam-heavy{ background: rgba(248,113,113,0.12); color: #f87171; border: 1px solid rgba(248,113,113,0.3); }

/* ── Modal ───────────────────────────────────────────────────────── */
.modal-overlay {
  position: fixed; inset: 0; z-index: 1000;
  background: rgba(3,4,16,0.75);
  backdrop-filter: blur(6px);
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
}
.modal-overlay.hidden { display: none; }

.modal {
  background: rgba(7,8,28,0.98);
  border: 1px solid #1a1d3a;
  border-radius: 28px;
  padding: 44px;
  width: 100%; max-width: 720px;
  max-height: 92vh; overflow-y: auto;
  position: relative;
  animation: modal-in 0.2s ease;
}
@keyframes modal-in {
  from { opacity: 0; transform: scale(0.96) translateY(6px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-close {
  position: absolute; top: 16px; right: 16px;
  width: 30px; height: 30px; border-radius: 8px;
  background: rgba(255,255,255,0.05); border: 1px solid #1a1d3a;
  color: #5a608a; cursor: pointer; font-size: 14px;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.15s;
}
.modal-close:hover { color: #e0e7ff; background: rgba(255,255,255,0.1); }

.modal-top {
  display: flex; gap: 16px; align-items: flex-start;
  margin-bottom: 28px;
}
.modal-avatar {
  width: 92px; height: 92px; border-radius: 50%; flex-shrink: 0;
  background: #1a1d3a; border: 2px solid #2a2d4a;
  background-size: cover; background-position: center;
  display: flex; align-items: center; justify-content: center;
  font-size: 32px; color: #5a608a; font-weight: 600;
}
.modal-identity { flex: 1; min-width: 0; }
.modal-name    { font-size: 26px; font-weight: 600; color: #e0e7ff; margin-bottom: 6px; }
.modal-handles { font-size: 14px; color: #5a608a; margin-bottom: 10px; line-height: 1.5; }

.modal-cscore-block { text-align: right; flex-shrink: 0; }
.modal-cscore-num { font-size: 60px; font-weight: 700; color: #4ad6ff; line-height: 1; }
.modal-cscore-lbl { font-size: 12px; color: #5a608a; letter-spacing: 1.5px; margin-top: 6px; text-transform: uppercase; }
.modal-rank-lbl   { font-size: 13px; color: #3a4060; margin-top: 6px; }

.modal-section-title {
  font-size: 13px; color: #3a4060; letter-spacing: 2px; font-weight: 600;
  margin-bottom: 16px; text-transform: uppercase;
}

/* Auto-review */
.modal-review {
  background: linear-gradient(135deg, rgba(74,214,255,0.06), rgba(181,102,255,0.06));
  border: 1px solid rgba(74,214,255,0.18);
  border-radius: 18px; padding: 22px 24px; margin-bottom: 28px;
}
.modal-review-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.modal-review-role { font-size: 20px; font-weight: 700; color: #4ad6ff; letter-spacing: 0.3px; }
.modal-review-tag {
  font-size: 12px; color: #8a6ad0; letter-spacing: 0.5px;
  display: flex; align-items: center; gap: 5px;
}
.modal-review-text { font-size: 17px; line-height: 1.65; color: #b8c0e0; }
.modal-review-text b { color: #e0e7ff; font-weight: 600; }
.rv-ch {
  background: rgba(74,214,255,0.1); color: #4ad6ff;
  padding: 2px 7px; border-radius: 6px; font-size: 14px; white-space: nowrap;
}
.rv-theme {
  background: rgba(181,102,255,0.12); color: #c89bff;
  padding: 2px 7px; border-radius: 6px; font-size: 14px; white-space: nowrap;
}

/* Breakdown bars */
.comp-row { margin-bottom: 12px; }
.comp-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 5px; }
.comp-label  { font-size: 12px; color: #8890b0; display: flex; align-items: center; gap: 7px; }
.comp-dot    { width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; }
.comp-pct    { font-size: 13px; font-weight: 600; color: #e0e7ff; }
.comp-track  { width: 100%; height: 6px; background: #1a1d3a; border-radius: 3px; overflow: hidden; }
.comp-fill   { height: 100%; border-radius: 3px; transition: width 0.5s cubic-bezier(.4,0,.2,1); }
.comp-fill.act { background: linear-gradient(90deg, #3a48c0, #5865f2); }
.comp-fill.crt { background: linear-gradient(90deg, #777, #c8cacc); }
.comp-fill.inf { background: linear-gradient(90deg, #7a30c0, #b566ff); }
.comp-fill.con { background: linear-gradient(90deg, #16a050, #4ade80); }
.comp-hint { font-size: 10px; color: #3a4060; margin-top: 3px; }

/* Stats grid */
.modal-stat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.m-stat {
  background: rgba(255,255,255,0.03); border: 1px solid #1a1d3a;
  border-radius: 13px; padding: 18px 12px; text-align: center;
}
.m-stat-val { font-size: 26px; font-weight: 600; color: #e0e7ff; font-variant-numeric: tabular-nums; }
.m-stat-lbl { font-size: 12px; color: #5a608a; letter-spacing: 0.5px; margin-top: 6px; }

/* Sparkline */
.sparkline-dates { display: flex; justify-content: space-between; font-size: 10px; color: #3a4060; margin-bottom: 6px; }
.sparkline-svg   { width: 100%; overflow: visible; display: block; }

/* ── Responsive ──────────────────────────────────────────────────── */
@media (max-width: 1000px) {
  .overview-2col { grid-template-columns: 1fr; }
  .stat-grid-6 { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 900px) {
  body { padding: 80px 12px 40px; }
  .card { padding: 24px 18px; border-radius: 20px; }
  .stat-grid, .stat-grid-6 { grid-template-columns: repeat(2, 1fr); }
  .col-header { grid-template-columns: 40px 1fr 70px 0 50px; }
  .an-row     { grid-template-columns: 40px 1fr 70px 0 50px; }
  .col-header-simple, .an-row-simple { grid-template-columns: 38px 1fr 120px; padding: 12px 14px; }
  .col-header-simple { font-size: 10px; letter-spacing: 1px; padding-bottom: 10px; }
  .an-row-simple .row-rank { font-size: 16px; }
  .an-row-simple .row-avatar { width: 38px; height: 38px; font-size: 13px; }
  .an-row-simple .row-name { font-size: 14px; }
  .an-row-simple .row-handle { font-size: 11px; }
  .row-cscore-big { padding-left: 8px; }
  .cscore-big-bar { height: 26px; border-radius: 7px; }
  .cscore-big-num { font-size: 13px; line-height: 26px; padding: 0 10px; }

  /* Модалка на мобилке — компактнее */
  .modal { padding: 22px 18px; border-radius: 20px; max-width: 96vw; }
  .modal-close {
    top: 25px;
    right: 6px;
    width: 15px;
    height: 15px;
    font-size: 10px;
  }
  .modal-top { gap: 12px; margin-bottom: 18px; flex-wrap: wrap; }
  .modal-avatar { width: 56px; height: 56px; font-size: 18px; }
  .modal-name { font-size: 18px; margin-bottom: 4px; }
  .modal-handles { font-size: 12px; margin-bottom: 6px; }
  .modal-cscore-num { font-size: 36px; }
  .modal-cscore-lbl { font-size: 10px; }
  .modal-rank-lbl { font-size: 11px; }
  .modal-review { padding: 14px 16px; border-radius: 12px; margin-bottom: 18px; }
  .modal-review-role { font-size: 15px; }
  .modal-review-text { font-size: 13px; line-height: 1.55; }
  .modal-section-title { font-size: 11px; margin-bottom: 10px; }
  .modal-stat-row { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .m-stat { padding: 12px 8px; }
  .m-stat-val { font-size: 18px; }
  .m-stat-lbl { font-size: 10px; }
  .ch-bars, .row-bars { display: none; }
  .col-header-ch, .chn-row { grid-template-columns: minmax(100px, 1fr) 70px 100px; }
  .chn-row > *:nth-child(3), .chn-row > *:nth-child(4), .chn-row > *:nth-child(5),
  .col-header-ch > *:nth-child(3), .col-header-ch > *:nth-child(4), .col-header-ch > *:nth-child(5) { display: none; }
  .title { font-size: 28px; letter-spacing: 3px; }

  /* Top nav на мобилке — 4 вкладки, разрешаем горизонтальный скролл */
  .top-nav { padding: 0 10px; gap: 2px; overflow-x: auto; }
  .top-nav::-webkit-scrollbar { display: none; }
  .nav-brand { margin-right: 6px; letter-spacing: 2px; font-size: 11px; flex-shrink: 0; }
  .nav-tab { padding: 4px 8px; font-size: 11px; letter-spacing: 0; white-space: nowrap; flex-shrink: 0; }

  /* Tab buttons (Overview / Top Contributors / Channels) — иконка рядом с текстом */
  .tab-btn {
    padding: 7px 10px; font-size: 12px; gap: 5px;
    flex-shrink: 0; white-space: nowrap;
  }
  .tab-bar { gap: 4px; overflow-x: auto; flex-wrap: nowrap; padding-bottom: 10px; }
  .tab-bar::-webkit-scrollbar { display: none; }

  /* Header: live-метку под заголовок чтобы не налезала */
  .header { flex-direction: column; align-items: flex-start; gap: 10px; margin-bottom: 24px; }
  .live { padding-left: 0; font-size: 12px; }
}
