/* ============================================================
   Multi-Game Tracker — UI 2.0 под лого (щит + лупа)
   Чёрный фон + градиент #ff8a1e → #ff4d00 → #e11d2e
   Анимации: пульс лого, градиентный тайтл, радар-сканер,
   stagger-вход отчёта, count-up шкалы, shimmer-скелетоны.
   Мобильный Telegram Mini App, max-width 480px.
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Onest:wght@400;600;800&display=swap');

:root {
  --bg: #08080c;
  --card: #101018;
  --card2: #17171f;
  --line: rgba(255, 94, 26, .2);
  --line-soft: rgba(255, 255, 255, .08);
  --text: #f5f3f0;
  --muted: #9494a2;
  --acc1: #ff8a1e;
  --acc2: #ff4d00;
  --acc3: #e11d2e;
  --grad: linear-gradient(135deg, #ff8a1e 0%, #ff4d00 55%, #e11d2e 100%);
  --glow: 0 8px 32px rgba(255, 77, 0, .25);
  --radius: 18px;
  --ok: #4caf50;
  --mid: #ffc107;
  --high: #ff7043;
  --crit: #f44336;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  color: var(--text);
  font-family: 'Onest', -apple-system, sans-serif;
  font-size: 15px;
  line-height: 1.5;
  -webkit-tap-highlight-color: transparent;
  font-feature-settings: "tnum";
}

body {
  background:
    radial-gradient(110% 45% at 50% -8%, rgba(255, 77, 0, .10), transparent 60%),
    radial-gradient(80% 30% at 100% 100%, rgba(225, 29, 46, .06), transparent 60%),
    var(--bg);
  min-height: 100vh;
}

.app {
  max-width: 480px;
  margin: 0 auto;
  padding: 16px 12px 42px;
}

/* ================= КЛЮЧЕВЫЕ КАДРЫ ================= */
@keyframes floaty   { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
@keyframes ringPulse {
  0%   { box-shadow: 0 0 0 0 rgba(255, 77, 0, .45); }
  70%  { box-shadow: 0 0 0 18px rgba(255, 77, 0, 0); }
  100% { box-shadow: 0 0 0 0 rgba(255, 77, 0, 0); }
}
@keyframes gradShift { to { background-position: 200% center; } }
@keyframes fadeUp   { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes sweep    { to { transform: rotate(360deg); } }
@keyframes blip     { 0% { opacity: .9; transform: scale(.3); } 80% { opacity: 0; transform: scale(1.5); } 100% { opacity: 0; } }
@keyframes shimmer  { to { background-position: -200% 0; } }
@keyframes dashIn   { from { stroke-dashoffset: 326.7; } }

/* ---------- Шапка с лого ---------- */
.header { text-align: center; padding: 8px 0 14px; }
.logo {
  width: 88px;
  height: 88px;
  border-radius: 26px;
  object-fit: cover;
  border: 1px solid var(--line);
  margin-bottom: 12px;
  animation: floaty 4s ease-in-out infinite, ringPulse 2.6s ease-out infinite;
}
.header .title {
  font-size: 19px;
  font-weight: 800;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  background: linear-gradient(90deg, #ff8a1e, #ff4d00, #e11d2e, #ff4d00, #ff8a1e);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: gradShift 5s linear infinite;
}
.header .subtitle {
  color: var(--muted);
  font-size: 11.5px;
  margin-top: 5px;
  letter-spacing: 1.2px;
}

/* Легенда шкалы */
.scale {
  display: flex;
  justify-content: center;
  gap: 5px;
  flex-wrap: wrap;
  margin-top: 12px;
}
.scale span {
  font-size: 10.5px;
  font-weight: 700;
  padding: 4px 9px;
  border-radius: 999px;
  background: var(--card2);
  border: 1px solid var(--line-soft);
  color: var(--muted);
  white-space: nowrap;
  animation: fadeUp .5s ease both;
}
.scale span:nth-child(2) { animation-delay: .07s; }
.scale span:nth-child(3) { animation-delay: .14s; }
.scale span:nth-child(4) { animation-delay: .21s; }
.scale .s0 { color: var(--ok); }
.scale .s1 { color: var(--mid); }
.scale .s2 { color: var(--high); }
.scale .s3 { color: var(--crit); }

/* ---------- Табы игр ---------- */
.tabs {
  display: flex;
  gap: 8px;
  margin: 14px 0 12px;
}
.tab {
  flex: 1;
  padding: 12px 6px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--card);
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: all .2s ease;
}
.tab:active { transform: scale(.97); }
.tab.active {
  background: var(--grad);
  border-color: transparent;
  color: #fff;
  box-shadow: var(--glow);
}

/* ---------- Панель / режимы ---------- */
.panel {
  background: linear-gradient(180deg, rgba(255, 77, 0, .04), transparent 30%), var(--card);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 12px;
  animation: fadeUp .25s ease;
}

.modes {
  display: flex;
  gap: 5px;
  margin-bottom: 12px;
  background: var(--bg);
  border: 1px solid var(--line-soft);
  border-radius: 12px;
  padding: 4px;
}
.mode {
  flex: 1;
  padding: 8px 4px;
  border: none;
  border-radius: 9px;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all .18s ease;
}
.mode.active {
  background: var(--grad);
  color: #fff;
  box-shadow: 0 3px 12px rgba(255, 77, 0, .3);
}

.hidden { display: none !important; }

.mode-section { animation: fadeUp .25s ease; }

/* ---------- Формы ---------- */
.lbl {
  display: block;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--muted);
  margin: 9px 0 4px;
}
.inp {
  width: 100%;
  padding: 11px 12px;
  border: 1px solid var(--line-soft);
  border-radius: 11px;
  background: var(--bg);
  color: var(--text);
  font-size: 15px;
  outline: none;
  transition: border .15s, box-shadow .15s;
}
.inp:focus {
  border-color: var(--acc2);
  box-shadow: 0 0 0 3px rgba(255, 77, 0, .15);
}
select.inp {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--acc1) 50%), linear-gradient(135deg, var(--acc1) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
  background-size: 5px 5px;
  background-repeat: no-repeat;
}

/* Поле с иконкой (поиск/API) */
.field { position: relative; }
.field .f-ico {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 14px;
  opacity: .65;
  pointer-events: none;
}
.field .inp { padding-left: 38px; }

.grid2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 10px;
}

.chk {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 12px;
  font-size: 14px;
}
.chk input { width: 18px; height: 18px; accent-color: var(--acc3); }

.hint {
  margin-top: 8px;
  font-size: 11.5px;
  color: var(--muted);
  line-height: 1.5;
}
.hint a, .help a { color: var(--acc1); }

/* ---------- Кнопки ---------- */
.btn {
  position: relative;
  overflow: hidden;
  width: 100%;
  margin-top: 14px;
  padding: 14px;
  border: none;
  border-radius: var(--radius);
  background: var(--grad);
  color: #fff;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: .5px;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: var(--glow);
  transition: transform .06s, opacity .15s, box-shadow .2s;
}
/* блик при наведении */
.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, .25) 50%, transparent 70%);
  background-size: 200% 100%;
  background-position: 120% 0;
  transition: background-position .6s ease;
  pointer-events: none;
}
.btn:hover::after { background-position: -120% 0; }
.btn:active { transform: scale(.98); }
.btn[disabled] { opacity: .6; cursor: default; box-shadow: none; }
.btn.ghost {
  background: var(--card);
  border: 1px solid var(--line);
  color: var(--acc1);
  box-shadow: none;
}

/* ---------- Зона отчёта ---------- */
.report-zone { margin-top: 14px; }
.report-zone .placeholder {
  text-align: center;
  color: var(--muted);
  padding: 30px 10px;
  font-size: 13px;
  border: 1px dashed var(--line-soft);
  border-radius: var(--radius);
}

/* ---------- РАДАР-СКАНЕР (поиск через API) ---------- */
.scanner {
  background:
    radial-gradient(130% 55% at 50% 0%, rgba(255, 77, 0, .09), transparent 60%),
    var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 14px 22px;
  text-align: center;
  animation: fadeUp .25s ease;
}
.radar {
  position: relative;
  width: 110px;
  height: 110px;
  margin: 0 auto 14px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background:
    radial-gradient(circle, transparent 32%, rgba(255, 77, 0, .05) 33%, transparent 34%),
    radial-gradient(circle, transparent 65%, rgba(255, 77, 0, .05) 66%, transparent 67%),
    var(--bg);
  overflow: hidden;
}
.radar .sweep {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: conic-gradient(from 0deg, rgba(255, 77, 0, .55), transparent 70deg, transparent 360deg);
  animation: sweep 1.4s linear infinite;
}
.radar .blip {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 70px;
  height: 70px;
  margin: -35px 0 0 -35px;
  border-radius: 50%;
  border: 2px solid var(--acc2);
  animation: blip 1.4s ease-out infinite;
}
.radar .radar-ico {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 30px;
  filter: drop-shadow(0 0 8px rgba(255, 77, 0, .6));
}
.scan-title {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.scan-steps {
  margin-top: 8px;
  font-size: 12.5px;
  color: var(--muted);
  min-height: 18px;
  transition: opacity .2s;
}
.scan-bar {
  margin: 14px auto 0;
  width: 180px;
  height: 4px;
  border-radius: 999px;
  background: var(--card2);
  overflow: hidden;
}
.scan-bar i {
  display: block;
  height: 100%;
  width: 40%;
  border-radius: 999px;
  background: var(--grad);
  animation: scanSlide 1.1s ease-in-out infinite;
}
@keyframes scanSlide {
  0%   { transform: translateX(-100%); }
  100% { transform: translateX(450%); }
}

/* ---------- Отчёт ---------- */
.report {
  background:
    radial-gradient(130% 55% at 50% 0%, rgba(255, 77, 0, .09), transparent 60%),
    var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px;
}
/* каскадный вход блоков отчёта */
.report > * { animation: fadeUp .45s ease both; }
.report > *:nth-child(2) { animation-delay: .06s; }
.report > *:nth-child(3) { animation-delay: .12s; }
.report > *:nth-child(4) { animation-delay: .18s; }
.report > *:nth-child(5) { animation-delay: .24s; }
.report > *:nth-child(6) { animation-delay: .3s; }

.rep-head {
  font-size: 16px;
  margin-bottom: 10px;
  word-break: break-all;
}

/* Плитки статов */
.tiles {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  margin-bottom: 10px;
}
.tile {
  position: relative;
  background: var(--card2);
  border: 1px solid var(--line-soft);
  border-radius: 11px;
  padding: 10px 3px 8px;
  text-align: center;
  font-size: 10px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
}
/* оранжевая искра сверху плитки */
.tile::before {
  content: '';
  position: absolute;
  top: 0;
  left: 20%;
  right: 20%;
  height: 2px;
  border-radius: 2px;
  background: var(--grad);
  opacity: .7;
}
.tile b {
  display: inline-block;
  font-size: 15px;
  color: var(--acc1);
}

/* Строки сравнения с нормой */
.row {
  display: flex;
  align-items: baseline;
  gap: 6px;
  padding: 8px 2px;
  border-bottom: 1px solid var(--line-soft);
  font-size: 14px;
}
.row:last-child { border-bottom: none; }
.row b { font-size: 15px; }
.row .muted { margin-left: auto; font-size: 11px; color: var(--muted); text-align: right; }

/* ---------- Круговая шкала ---------- */
.gauge-wrap {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 0 10px;
}
.gauge { position: relative; width: 118px; height: 118px; flex-shrink: 0; }
.gauge svg { transform: rotate(-90deg); display: block; }
.g-bg { fill: none; stroke: #1e1e28; stroke-width: 11; }
.g-val {
  fill: none;
  stroke-width: 11;
  stroke-linecap: round;
  filter: drop-shadow(0 0 6px rgba(255, 77, 0, .5));
  transition: stroke-dashoffset .8s cubic-bezier(.22, 1, .36, 1);
}
.g-num {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.g-num b { font-size: 25px; font-variant-numeric: tabular-nums; }
.g-num span { font-size: 10.5px; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; }

.verdict {
  font-size: 20px;
  letter-spacing: .5px;
  text-shadow: 0 0 18px currentColor;
  animation: fadeUp .5s .35s ease both;
}

/* ---------- Флаги ---------- */
.flags-title { font-size: 13px; font-weight: 800; margin-bottom: 7px; letter-spacing: .3px; }
.flag {
  background: var(--card2);
  border: 1px solid var(--line-soft);
  border-left: 3px solid var(--line-soft);
  border-radius: 10px;
  padding: 8px 10px;
  font-size: 12.5px;
  margin-bottom: 6px;
  display: flex;
  gap: 7px;
  align-items: baseline;
  animation: fadeUp .35s ease both;
}
.flag:nth-child(3) { animation-delay: .05s; }
.flag:nth-child(4) { animation-delay: .1s; }
.flag:nth-child(5) { animation-delay: .15s; }
.flag:nth-child(6) { animation-delay: .2s; }
.flag.crit { border-left-color: var(--crit); }
.flag.high { border-left-color: var(--high); }
.flag.mid  { border-left-color: var(--mid); }
.flag.ok   { border-left-color: var(--ok); color: var(--ok); }
.flag .fw { margin-left: auto; color: var(--muted); font-size: 12px; font-weight: 800; flex-shrink: 0; }

.verdict-text {
  margin-top: 10px;
  font-size: 12.5px;
  color: var(--muted);
  background: var(--card2);
  border: 1px solid var(--line-soft);
  border-radius: 11px;
  padding: 10px;
  line-height: 1.55;
}

/* ---------- Ошибки ---------- */
.report.error { border-color: var(--acc3); }
.err-msg { font-size: 14px; margin-bottom: 8px; }
.help {
  background: var(--card2);
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 10px;
  font-size: 12.5px;
  margin-top: 8px;
  line-height: 1.65;
}

/* ---------- Roblox Rivals profile / badges ---------- */
.rb-dash { padding-top: 0; }
.rb-profile {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border-radius: 15px 15px 0 0;
  background: linear-gradient(120deg, #6f22ff, #a715ef);
  color: #fff;
}
.rb-avatar {
  width: 70px;
  height: 70px;
  border-radius: 14px;
  object-fit: cover;
  border: 3px solid rgba(255,255,255,.35);
  flex-shrink: 0;
}
.rb-avatar.ph { display:flex; align-items:center; justify-content:center; background:rgba(0,0,0,.2); font-size:28px; }
.rb-profile-info { min-width: 0; flex: 1; }
.rb-profile-info b { display:block; font-size:16px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.rb-profile-info span { display:block; font-size:10px; opacity:.82; margin-top:4px; }
.rb-open { color:#fff; text-decoration:none; border:1px solid rgba(255,255,255,.35); border-radius:9px; padding:7px 9px; font-size:10px; white-space:nowrap; }
.rb-counters { display:grid; grid-template-columns:repeat(4,1fr); background:var(--card2); border-radius:0 0 15px 15px; overflow:hidden; margin-bottom:12px; border:1px solid var(--line-soft); border-top:0; }
.rb-counters > div { text-align:center; padding:10px 4px; border-right:1px solid var(--line-soft); }
.rb-counters > div:last-child { border-right:0; }
.rb-counters strong { display:block; font-size:19px; line-height:1.1; }
.rb-counters b { display:block; font-size:15px; margin-top:4px; }
.rb-counters span { display:block; color:var(--muted); font-size:8px; margin-top:3px; }
.rb-columns { display:grid; grid-template-columns:1fr 1fr; gap:10px; }
.rb-panel { min-width:0; background:var(--card2); border:1px solid var(--line-soft); border-radius:13px; padding:10px; }
.rb-panel-title { display:flex; align-items:center; gap:6px; font-size:13px; font-weight:800; margin-bottom:8px; }
.rb-panel-title em { font-style:normal; font-size:10px; padding:2px 6px; border-radius:7px; background:rgba(160,70,255,.14); color:var(--acc1); }
.rb-badge { display:flex; gap:8px; align-items:center; padding:7px 0; border-top:1px solid var(--line-soft); }
.rb-badge:first-of-type { border-top:0; }
.rb-badge-img { width:34px; height:34px; border-radius:8px; object-fit:cover; flex-shrink:0; }
.rb-badge-img.ph { display:flex; align-items:center; justify-content:center; background:var(--bg); font-size:19px; }
.rb-badge-info { min-width:0; }
.rb-badge-info b { display:block; font-size:10px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.rb-badge-info span { display:block; color:var(--muted); font-size:8px; line-height:1.3; margin-top:2px; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
.rb-empty { min-height:100px; display:flex; flex-direction:column; align-items:center; justify-content:center; text-align:center; color:var(--muted); font-size:10px; gap:6px; }
.rb-empty span { font-size:24px; opacity:.8; }
.rb-live { display:grid; grid-template-columns:repeat(3,1fr) auto; align-items:center; gap:8px; background:var(--card2); border:1px solid var(--line-soft); border-radius:13px; padding:10px; margin-top:10px; }
.rb-live span { display:block; color:var(--muted); font-size:8px; text-transform:uppercase; letter-spacing:.4px; }
.rb-live b { display:block; color:var(--acc1); font-size:14px; margin-top:3px; }
.rb-live a { color:var(--acc1); font-size:10px; text-decoration:none; text-align:right; }

/* ---------- Футер ---------- */
.footer {
  margin-top: 20px;
  text-align: center;
  font-size: 11px;
  color: var(--muted);
  padding: 0 10px;
  line-height: 1.6;
}

/* ============================================================
   ДАШБОРД (по референсу-скрину) — поиск, карточка игрока,
   мини-статы, gauge-карточки, KPI
   ============================================================ */

/* Строка поиска: инпут + кнопка */
.search-row {
  display: flex;
  gap: 8px;
  align-items: stretch;
}
.field.grow { flex: 1; min-width: 0; }
.btn.scan {
  flex: 0 0 auto;
  width: auto;
  margin-top: 0;
  padding: 0 16px;
  font-size: 12px;
}

/* Сворачиваемые настройки API */
.settings {
  margin-top: 10px;
  border: 1px solid var(--line-soft);
  border-radius: 11px;
  background: var(--bg);
  padding: 8px 10px;
}
.settings summary {
  cursor: pointer;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--muted);
  outline: none;
  list-style: none;
}
.settings summary::before { content: '▸ '; color: var(--acc1); }
.settings[open] summary::before { content: '▾ '; }
.settings summary::-webkit-details-marker { display: none; }

/* ---------- Карточка игрока ---------- */
.pcard {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--card2);
  border: 1px solid var(--line-soft);
  border-radius: 13px;
  padding: 12px;
  margin-bottom: 10px;
}
.avatar {
  width: 64px;
  height: 64px;
  border-radius: 12px;
  object-fit: cover;
  border: 1px solid var(--line);
  flex-shrink: 0;
}
.avatar.ph {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  background: var(--bg);
}
.pinfo { min-width: 0; }
.badge {
  display: inline-block;
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: 1.2px;
  padding: 3px 8px;
  border-radius: 6px;
  border: 1px solid currentColor;
  margin-bottom: 5px;
}
.b-ok   { color: var(--ok);   background: rgba(76, 175, 80, .12); }
.b-mid  { color: var(--mid);  background: rgba(255, 193, 7, .12); }
.b-high { color: var(--high); background: rgba(255, 112, 67, .12); }
.b-crit { color: var(--crit); background: rgba(244, 67, 54, .14); }
.pname {
  font-size: 15px;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.pid { font-size: 11px; color: var(--muted); }

/* ---------- Мини-статы 2x2 ---------- */
.minis {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 10px;
}
.mini {
  background: var(--card2);
  border: 1px solid var(--line-soft);
  border-radius: 11px;
  padding: 9px 12px;
}
.mini span {
  display: block;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: .8px;
  color: var(--muted);
  text-transform: uppercase;
  margin-bottom: 3px;
}
.mini b { font-size: 16px; }

/* ---------- Три gauge-карточки ---------- */
.gauges {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 10px;
}
.gcard {
  background: var(--card2);
  border: 1px solid var(--line-soft);
  border-radius: 13px;
  padding: 10px 8px;
  text-align: center;
  min-width: 0;
}
.gc-title {
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 1px;
  color: var(--muted);
  text-transform: uppercase;
  margin-bottom: 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.gc-gauge { position: relative; width: 76px; height: 76px; margin: 0 auto; }
.gc-gauge svg { transform: rotate(-90deg); display: block; }
.gc-gauge .g-bg { stroke: #1e1e28; stroke-width: 8; }
.gc-gauge .g-val {
  stroke-width: 8;
  stroke-linecap: round;
  filter: drop-shadow(0 0 4px rgba(255, 77, 0, .5));
  transition: stroke-dashoffset .8s cubic-bezier(.22, 1, .36, 1);
}
.gc-num {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.gc-num b { font-size: 17px; font-variant-numeric: tabular-nums; }
.gc-gauge.na {
  border: 2px dashed var(--line-soft);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-weight: 800;
  font-size: 15px;
}
.gc-label {
  margin-top: 8px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .5px;
  text-shadow: 0 0 12px currentColor;
}
.gc-sub {
  font-size: 8.5px;
  font-weight: 700;
  letter-spacing: .8px;
  color: var(--muted);
  margin-top: 2px;
}
.gc-desc {
  margin-top: 6px;
  font-size: 9.5px;
  color: var(--muted);
  line-height: 1.45;
}

/* ---------- KPI-полоса (K/D • раунды • HS • точность) ---------- */
.kpi {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: var(--card2);
  border: 1px solid var(--line-soft);
  border-radius: 13px;
  padding: 10px 4px;
  margin-bottom: 10px;
}
.kpi > div {
  text-align: center;
  border-right: 1px solid var(--line-soft);
  padding: 2px 4px;
}
.kpi > div:last-child { border-right: none; }
.kpi span {
  display: block;
  font-size: 8.5px;
  font-weight: 700;
  letter-spacing: .8px;
  color: var(--muted);
  text-transform: uppercase;
  margin-bottom: 3px;
}
.kpi b { font-size: 14px; color: var(--acc1); }

/* Узкие экраны: чуть жмём дашборд */
@media (max-width: 380px) {
  .gc-desc { display: none; }
  .kpi b { font-size: 12.5px; }
  .rb-profile { padding: 10px; gap: 8px; }
  .rb-avatar { width: 56px; height: 56px; }
  .rb-profile-info b { font-size: 13px; }
  .rb-open { padding: 6px; font-size: 9px; }
  .rb-counters b { font-size: 12px; }
  .rb-counters span { font-size: 7px; }
  .rb-columns { grid-template-columns: 1fr; }
  .rb-live { grid-template-columns:repeat(3,1fr); }
  .rb-live a { grid-column:1 / -1; text-align:left; }
}

/* ============================================================
   ИНВЕНТАРЬ / ОРУЖИЕ / САБ-ТАБЫ (по референсам)
   ============================================================ */

/* ---------- Саб-табы Stats | Инвентарь ---------- */
.subtabs {
  display: flex;
  gap: 6px;
  margin-bottom: 12px;
  background: var(--bg);
  border: 1px solid var(--line-soft);
  border-radius: 12px;
  padding: 4px;
}
.subtab {
  flex: 1;
  padding: 9px 4px;
  border: none;
  border-radius: 9px;
  background: transparent;
  color: var(--muted);
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all .18s ease;
}
.subtab.active {
  background: var(--grad);
  color: #fff;
  box-shadow: 0 3px 12px rgba(255, 77, 0, .3);
}
.sub-body { animation: fadeUp .25s ease; }

/* ---------- Иконка внутри gauge ---------- */
.gc-ico { font-size: 13px; margin-top: 1px; }

/* ---------- Шапка инвентаря ---------- */
.inv-head {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}
.inv-head .inv-title { font-size: 14px; font-weight: 800; }
.inv-head .inv-value {
  margin-left: auto;
  font-size: 15px;
  font-weight: 800;
  color: var(--acc1);
}
.inv-head .inv-note { width: 100%; font-size: 10.5px; color: var(--muted); }

/* ---------- Сетка скинов (карточка как на референсе) ---------- */
.skin-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.sk-card {
  position: relative;
  background: linear-gradient(180deg, rgba(255, 255, 255, .03), transparent 55%), var(--card2);
  border: 1px solid var(--line-soft);
  border-bottom: 3px solid var(--line-soft);
  border-radius: 12px;
  padding: 8px 8px 9px;
  animation: fadeUp .35s ease both;
  overflow: hidden;
}
.sk-wear {
  position: absolute;
  top: 7px;
  left: 8px;
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: .5px;
  color: var(--muted);
  z-index: 2;
}
.sk-count {
  position: absolute;
  top: 7px;
  right: 8px;
  font-size: 9.5px;
  font-weight: 800;
  color: var(--acc1);
  background: rgba(255, 77, 0, .12);
  border-radius: 6px;
  padding: 2px 6px;
  z-index: 2;
}
.sk-img {
  display: block;
  width: 100%;
  height: 74px;
  object-fit: contain;
  margin: 10px 0 6px;
  filter: drop-shadow(0 6px 10px rgba(0, 0, 0, .45));
}
.sk-name {
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sk-price {
  font-size: 14px;
  font-weight: 800;
  color: var(--text);
  margin-top: 2px;
}
.sk-price .sk-old {
  font-size: 10.5px;
  font-weight: 600;
  color: var(--muted);
  text-decoration: line-through;
  margin-left: 5px;
}
.sk-price.loading { color: var(--muted); font-weight: 600; font-size: 11px; }

.inv-more {
  text-align: center;
  color: var(--muted);
  font-size: 11.5px;
  padding: 10px 0 2px;
}

/* ---------- Лок-состояние (инвентарь приватный) ---------- */
.inv-lock {
  text-align: center;
  padding: 26px 14px;
  background: var(--card2);
  border: 1px solid var(--line-soft);
  border-radius: 13px;
}
.inv-lock .lock-ico { font-size: 30px; margin-bottom: 8px; }
.inv-lock .lock-title { font-size: 14px; font-weight: 800; margin-bottom: 6px; }
.inv-lock .lock-text { font-size: 12px; color: var(--muted); line-height: 1.6; }

/* ---------- Панели оружия (Most Kills / Точность) ---------- */
.wpn-panels {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 10px;
}
.wpn-panel {
  background: var(--card2);
  border: 1px solid var(--line-soft);
  border-radius: 13px;
  padding: 10px;
  min-width: 0;
}
.wpn-title {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .8px;
  color: var(--muted);
  text-transform: uppercase;
  margin-bottom: 8px;
}
.wpn-row {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
  font-size: 10.5px;
}
.wpn-row:last-child { margin-bottom: 0; }
.wpn-name {
  width: 58px;
  flex-shrink: 0;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.wpn-bar {
  flex: 1;
  height: 6px;
  background: var(--bg);
  border-radius: 999px;
  overflow: hidden;
}
.wpn-bar i {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: var(--grad);
  width: 0;
  transition: width .6s cubic-bezier(.22, 1, .36, 1);
}
.wpn-val {
  width: 34px;
  flex-shrink: 0;
  text-align: right;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

@media (max-width: 380px) {
  .wpn-name { width: 46px; }
}

/* ============================================================
   Широкий экран: Telegram Desktop и обычный браузер на ПК.
   Вёрстка мобильная (колонка 480px), на десктопе она смотрелась
   узкой полосой — расширяем контейнер и плотнее раскладываем сетки.
   ============================================================ */
@media (min-width: 900px) {
  .app { max-width: 760px; padding: 24px 20px 56px; }
  .minis { grid-template-columns: repeat(4, 1fr); }
  .skin-grid { grid-template-columns: repeat(4, 1fr); }
  .logo { width: 104px; height: 104px; }
  .gc-desc { font-size: 10px; }
}
