/* sales-dash — «трейдинг-терминал»: тёмная приборная панель.
   Объём без стекломорфизма: фаска сверху (свет), тень снизу, утопленные
   «экраны» под данные, LED-индикаторы. Цифры — только JetBrains Mono. */

@font-face {
  font-family: "Onest";
  src: url("/static/fonts/onest.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "JBMono";
  src: url("/static/fonts/jetbrainsmono.woff2") format("woff2");
  font-weight: 100 800;
  font-display: swap;
}

:root {
  --bg: #0A0712;
  --bg-2: #0D0916;
  /* панель: светлее сверху, темнее снизу = объём */
  --panel-t: #191323;
  --panel-b: #120D1B;
  --panel-line: #292138;
  --panel-hi: rgba(255, 255, 255, .055);     /* фаска-блик по верхней кромке */
  --screen: #0B0712;                          /* утопленный экран */
  --screen-line: #1E1830;
  --text: #ECE8F4;
  --text-2: #A89FBE;
  --muted: #6E6584;
  --accent: #FF7A2E;
  --good: #2BB673;
  --bad: #E0568B;
  --c-blue: #3987e5;
  --c-orange: #d95926;
  --c-green: #199e70;
  --c-gold: #c98500;
  --c-pink: #d55181;
  --c-violet: #9085e9;
  --r: 14px;
  --font: "Onest", -apple-system, "Segoe UI", system-ui, sans-serif;
  --mono: "JBMono", ui-monospace, "Cascadia Mono", Consolas, monospace;
  /* парящие блоки: только мягкие глубокие тени вниз + цветной ореол (--halo) */
  --halo: transparent;
  --shadow-panel: 0 10px 26px -10px rgba(0, 0, 0, .55),
                  0 30px 70px -24px rgba(0, 0, 0, .72),
                  0 24px 60px -18px var(--halo);
  --shadow-lift:  0 16px 34px -12px rgba(0, 0, 0, .6),
                  0 44px 90px -26px rgba(0, 0, 0, .8),
                  0 30px 72px -18px var(--halo);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font: 14px/1.45 var(--font);
  min-height: 100vh;
  position: relative;
}
/* дышащий амбиент: тёплое свечение + холодный противовес, очень тихо */
body::before {
  content: ""; position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background:
    /* инженерная сетка — едва различимые линии */
    repeating-linear-gradient(0deg, transparent 0 55px, rgba(255, 255, 255, .022) 55px 56px),
    repeating-linear-gradient(90deg, transparent 0 55px, rgba(255, 255, 255, .022) 55px 56px),
    radial-gradient(900px 520px at 12% -8%, rgba(255, 122, 46, .09), transparent 62%),
    radial-gradient(1100px 700px at 108% 112%, rgba(144, 133, 233, .07), transparent 60%),
    radial-gradient(1400px 900px at 50% 50%, transparent 55%, rgba(0, 0, 0, .42) 100%);
}
body::after {  /* зерно, чтобы градиенты не полосили */
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none; opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.92' numOctaves='2'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='.6'/%3E%3C/svg%3E");
}
@media (prefers-reduced-motion: no-preference) {
  body::before { animation: breathe 9s ease-in-out infinite alternate; }
  @keyframes breathe { from { opacity: .75; } to { opacity: 1; } }
}
a { color: inherit; text-decoration: none; }

/* все цифры — моно */
.num, .kpi-value, td.n, td.strong, .board-rev, .rank-num, .race-end, .prog-pct,
.chip, .delta, .clock, .tick-item b, .urg-conv, .row-item .val, .fstage .val,
.plan-line, .board-stats b, .alert b {
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
}

/* ── каркас: сайдбар + контент ─────────────────────── */
.shell { display: flex; min-height: 100vh; }
.side {
  width: 208px; flex: none;
  display: flex; flex-direction: column;
  border-right: 1px solid var(--panel-line);
  background: linear-gradient(180deg, #110C1B, #0C0814);
  box-shadow: 1px 0 0 var(--panel-hi) inset;
  position: sticky; top: 0; height: 100vh;
  padding: 18px 12px 16px;
}
.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }

.brand { display: flex; align-items: center; gap: 10px; padding: 2px 8px 18px; }
.brand-mark {
  width: 12px; height: 12px; background: var(--accent);
  display: inline-block; border-radius: 3px; flex: none;
  box-shadow: 0 0 12px rgba(255, 122, 46, .6);
}
.brand-name { font-weight: 800; letter-spacing: .02em; font-size: 15px; display: block; }
.brand-sub { color: var(--muted); font-size: 11px; display: block; }

.nav { display: flex; flex-direction: column; gap: 3px; }
.nav a {
  display: flex; align-items: center; gap: 11px;
  padding: 10px 12px; border-radius: 8px;
  color: var(--text-2); font-weight: 600; font-size: 13.5px;
  border: 1px solid transparent;
  transition: color .15s, background .15s;
}
.nav a svg { width: 19px; height: 19px; flex: none; opacity: .8; }
.nav a:hover { color: var(--text); background: rgba(30, 24, 48, .5); }
.nav a.on {
  color: var(--text);
  background: linear-gradient(var(--panel-t), var(--panel-b));
  border-color: var(--panel-line);
  box-shadow: 0 1px 0 var(--panel-hi) inset, 0 2px 6px rgba(0,0,0,.4);
}
.nav a.on svg { color: var(--accent); opacity: 1; filter: drop-shadow(0 0 5px rgba(255,122,46,.5)); }

.side-foot {
  margin-top: auto; display: flex; align-items: center; justify-content: space-between;
  padding: 12px 10px 0; border-top: 1px solid var(--panel-line);
}
.live {
  display: flex; align-items: center; gap: 7px;
  font: 600 11px/1 var(--mono); letter-spacing: .12em; color: var(--text-2);
}

.topbar {
  display: flex; align-items: center; gap: 14px;
  border-bottom: 1px solid var(--panel-line);
  position: sticky; top: 0; z-index: 30;
  background: rgba(10, 7, 18, .88);
  backdrop-filter: blur(8px);
  padding: 0 20px 0 0;
  box-shadow: 0 1px 0 var(--panel-hi) inset;
  height: 44px;
}
.topbar .ticker { flex: 1; min-width: 0; border-bottom: 0; box-shadow: none; background: none; }
.topbar .periods { flex: none; }
.led {
  width: 7px; height: 7px; border-radius: 50%; background: var(--good);
  box-shadow: 0 0 8px var(--good);
}
@media (prefers-reduced-motion: no-preference) {
  .led { animation: ledpulse 2.2s ease-in-out infinite; }
  @keyframes ledpulse { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }
}
.clock { font: 500 12.5px/1 var(--mono); color: var(--text-2); letter-spacing: .04em; min-width: 62px; }

.periods {
  display: flex; border: 1px solid var(--panel-line); border-radius: 7px; overflow: hidden;
  background: linear-gradient(var(--panel-t), var(--panel-b));
  box-shadow: 0 1px 0 var(--panel-hi) inset, 0 2px 5px rgba(0,0,0,.4);
}
.periods button {
  background: none; border: 0; color: var(--text-2); font: 500 12px/1 var(--font);
  padding: 8px 12px; cursor: pointer; white-space: nowrap; transition: color .15s, background .15s;
}
.periods button + button { border-left: 1px solid var(--panel-line); }
.periods button:hover { color: var(--text); }
.periods button.on {
  background: rgba(255, 122, 46, .13); color: var(--accent); font-weight: 700;
}

/* ── тикер сделок ──────────────────────────────────── */
.ticker {
  overflow: hidden; position: relative; height: 44px;
}
.ticker::before, .ticker::after {
  content: ""; position: absolute; top: 0; bottom: 0; width: 60px; z-index: 2; pointer-events: none;
}
.ticker::before { left: 0; background: linear-gradient(90deg, var(--bg), transparent); }
.ticker::after { right: 0; background: linear-gradient(-90deg, var(--bg), transparent); }
.tick-track {
  display: inline-flex; align-items: center; height: 44px; white-space: nowrap;
  will-change: transform;
}
@media (prefers-reduced-motion: no-preference) {
  .tick-track { animation: tickmove var(--tick-dur, 60s) linear infinite; }
  .ticker:hover .tick-track { animation-play-state: paused; }
  @keyframes tickmove { to { transform: translateX(-50%); } }
}
.tick-item {
  display: inline-flex; align-items: baseline; gap: 7px; padding: 0 26px;
  font: 500 12px/1 var(--mono); color: var(--text-2);
}
.tick-item .t { color: var(--muted); }
.tick-item b { color: var(--good); font-weight: 700; }
.tick-item .m { color: var(--text-2); }
.tick-sep { color: var(--accent); opacity: .6; font-size: 9px; }

/* ── контент ───────────────────────────────────────── */
.view { max-width: 1280px; margin: 0 auto; width: 100%; padding: 20px 20px 44px; }
.ftr {
  max-width: 1280px; margin: 0 auto; width: 100%; padding: 0 20px 26px;
  color: var(--muted); font-size: 11.5px; font-family: var(--mono);
}

/* ── герой: горы на закате ─────────────────────────── */
.hero {
  position: relative; border-radius: var(--r); overflow: hidden;
  border: 1px solid var(--panel-line);
  min-height: 240px;
  display: flex; align-items: stretch;
  background: #120D1B url("/static/hero.jpg") center 68% / cover no-repeat;
  box-shadow: var(--shadow-panel), 0 0 70px -22px rgba(255, 122, 46, .5);
}
.hero::before {   /* затемнение слева и снизу для текста */
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(10, 7, 18, .88) 0%, rgba(10, 7, 18, .55) 38%, rgba(10, 7, 18, .06) 70%),
    linear-gradient(0deg, rgba(10, 7, 18, .82) 0%, transparent 46%);
}
.hero-in {
  position: relative; z-index: 1; width: 100%;
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 24px; padding: 22px 26px 20px;
}
.hero-left { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.hero-eyebrow {
  font: 700 11px/1 var(--mono); letter-spacing: .14em; text-transform: uppercase;
  color: var(--text-2);
}
.hero-value {
  font-family: var(--mono); font-variant-numeric: tabular-nums;
  font-size: 44px; font-weight: 800; letter-spacing: -.03em; line-height: 1;
  text-shadow: 0 2px 18px rgba(0, 0, 0, .6);
}
.hero-value .unit { font-size: 24px; font-weight: 600; color: var(--text-2); }
.hero-sub { display: flex; align-items: center; gap: 12px; font-size: 12.5px; color: var(--text-2); flex-wrap: wrap; }
.hero-sub .delta { font-size: 12.5px; }
.hero-today {
  font-family: var(--mono); color: var(--good); font-weight: 700; font-size: 12.5px;
  text-shadow: 0 0 12px rgba(43, 182, 115, .45);
}
.hero-right { display: flex; align-items: center; gap: 20px; flex: none; }

/* ── кольцевой гейдж ───────────────────────────────── */
.ring { position: relative; display: inline-block; }
.ring svg { display: block; }
.ring .ring-track { stroke: rgba(255, 255, 255, .1); }
.ring .ring-val {
  stroke: var(--accent); stroke-linecap: round;
  filter: drop-shadow(0 0 6px rgba(255, 122, 46, .65));
  transform: rotate(-90deg); transform-origin: center;
}
.ring .ring-val.over { stroke: var(--good); filter: drop-shadow(0 0 6px rgba(43, 182, 115, .65)); }
@media (prefers-reduced-motion: no-preference) {
  .ring .ring-val { transition: stroke-dashoffset .7s cubic-bezier(.2, .7, .3, 1); }
}
.ring-txt {
  position: absolute; inset: 0; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 1px;
}
.ring-pct { font-family: var(--mono); font-weight: 800; letter-spacing: -.02em; }
.ring-cap {
  font: 600 9.5px/1 var(--mono); letter-spacing: .1em; text-transform: uppercase;
  color: var(--text-2);
}

.grid { display: grid; gap: 16px; }
.g2 { grid-template-columns: 1fr 1fr; }
.mt { margin-top: 16px; }

/* панель: парит в воздухе */
.card {
  background: linear-gradient(172deg, #1B1526, #141020);
  border: 1px solid rgba(255, 255, 255, .05);
  border-radius: var(--r);
  padding: 18px 20px;
  min-width: 0;
  box-shadow: var(--shadow-panel);
  transition: box-shadow .25s ease, transform .25s ease;
}
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .card:hover { box-shadow: var(--shadow-lift); transform: translateY(-3px); }
}
.card.halo-ember { --halo: rgba(255, 122, 46, .16); }
.card h2 {
  font-size: 12px; font-weight: 700; color: var(--text-2);
  text-transform: uppercase; letter-spacing: .1em; margin-bottom: 12px;
  display: flex; align-items: baseline; gap: 9px;
}
.card h2 .note { text-transform: none; letter-spacing: 0; font-weight: 400; color: var(--muted); font-size: 12px; }
.caption { color: var(--muted); font-size: 11.5px; margin-top: 10px; }

/* экраны упразднены: данные лежат прямо на поверхности парящего блока */
.screen { padding: 2px 0 0; }

.empty { color: var(--muted); padding: 24px 0; text-align: center; font-size: 13px; }
.loading { color: var(--muted); padding: 60px 0; text-align: center; font-family: var(--mono); }

/* появление блоков ведёт GSAP (enterAnim); CSS-fallback не нужен */
@media (prefers-reduced-motion: no-preference) {
  .bar-fill, .prog-fill { transition: width .45s cubic-bezier(.2, .7, .3, 1); }
}

/* вспышка при изменении значения */
@media (prefers-reduced-motion: no-preference) {
  .flash-up { animation: flup .9s ease-out; }
  .flash-dn { animation: fldn .9s ease-out; }
  @keyframes flup { 20% { color: var(--good); text-shadow: 0 0 14px rgba(43,182,115,.5); } }
  @keyframes fldn { 20% { color: var(--bad); text-shadow: 0 0 14px rgba(224,86,139,.5); } }
}

/* ── KPI ───────────────────────────────────────────── */
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.kpi { display: flex; flex-direction: column; gap: 8px; }
.kpi-label {
  color: var(--text-2); font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .1em;
  display: flex; align-items: center; gap: 7px;
}
.kpi-screen {
  position: relative; display: flex; flex-direction: column; gap: 3px;
  padding: 6px 0 0;
}
.kpi-value { font-size: 25px; font-weight: 700; letter-spacing: -.02em; line-height: 1.1; }
.kpi-value .unit { font-size: 14px; font-weight: 500; color: var(--text-2); margin-left: 2px; }
.kpi-sub {
  display: flex; align-items: center; gap: 8px; font-size: 11.5px; color: var(--muted);
  min-height: 16px; white-space: nowrap;
}
.kpi-screen:has(.kpi-spark) .kpi-sub { padding-right: 66px; white-space: normal; }
.delta { font-weight: 700; font-size: 11.5px; }
.delta.up { color: var(--good); }
.delta.down { color: var(--bad); }
.kpi-spark { position: absolute; right: 0; bottom: 2px; opacity: .95; }

/* ── бары / прогрессы: живые, с бегущим бликом ─────── */
.bar {
  height: 9px; background: rgba(255, 255, 255, .07); border-radius: 5px; overflow: hidden;
}
.bar-fill { height: 100%; border-radius: 5px; background: var(--c-blue); position: relative; overflow: hidden; }
.prog {
  height: 11px; background: rgba(255, 255, 255, .07); border-radius: 6px; overflow: hidden; position: relative;
}
.prog-fill { height: 100%; border-radius: 6px; background: var(--c-blue); position: relative; overflow: hidden; }
.prog-fill.over { background: var(--good); }
@media (prefers-reduced-motion: no-preference) {
  .bar-fill::after, .prog-fill::after {
    content: ""; position: absolute; top: 0; bottom: 0; width: 42%; left: -50%;
    background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .4), transparent);
    animation: shine 3.4s ease-in-out infinite;
    animation-delay: var(--shd, 0s);
  }
  @keyframes shine { 0% { left: -50%; } 60% { left: 115%; } 100% { left: 115%; } }
}

/* ── строки-разрезы ────────────────────────────────── */
.rows { display: flex; flex-direction: column; gap: 9px; }
.row-item { display: grid; grid-template-columns: minmax(90px, 160px) 1fr auto; gap: 10px; align-items: center; }
.row-item .lbl { font-size: 13px; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row-item .val { font-size: 12px; color: var(--text-2); white-space: nowrap; }
.row-item .val b { color: var(--text); font-weight: 700; }
.chip {
  display: inline-block; padding: 2px 7px; border-radius: 6px; font-size: 11px;
  font-weight: 700; background: rgba(255, 255, 255, .08); color: var(--text-2);
}
.chip.hot { color: var(--good); }
.chip.cold { color: var(--bad); }

/* ── таблицы ───────────────────────────────────────── */
.tbl-wrap { overflow-x: auto; margin: 0 -18px; padding: 0 18px; }
table.tbl { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 720px; }
table.tbl.sm { min-width: 420px; }
.tbl th {
  text-align: right; color: var(--muted); font-weight: 600; font-size: 10.5px;
  text-transform: uppercase; letter-spacing: .07em;
  padding: 6px 10px; border-bottom: 1px solid var(--panel-line);
  white-space: nowrap; cursor: pointer; user-select: none;
}
.tbl th:first-child { text-align: left; }
.tbl th.sorted { color: var(--accent); }
.tbl td { padding: 8.5px 10px; border-bottom: 1px solid rgba(41, 33, 56, .55); text-align: right; white-space: nowrap; }
.tbl td:first-child { text-align: left; font-family: var(--font); }
.tbl td.n { color: var(--text-2); font-size: 12.5px; }
.tbl td.strong { color: var(--text); font-weight: 700; font-size: 12.5px; }
.tbl tbody tr { transition: background .15s; }
.tbl tbody tr:hover td { background: rgba(30, 24, 48, .5); }
.tbl tr.expandable { cursor: pointer; }
.tbl tr.detail td { background: var(--screen); white-space: normal; text-align: left; padding: 12px 14px; }
.dot {
  display: inline-block; width: 8px; height: 8px; border-radius: 50%;
  margin-right: 8px; vertical-align: baseline;
}
.board-name .dot { box-shadow: 0 0 8px color-mix(in srgb, currentColor 60%, transparent); }
.tag-former { color: var(--muted); font-size: 11px; margin-left: 6px; }

/* ── Broadcast Steel: матч-центр ───────────────────── */
/* лестница поверхностей и hairline по Linear-принципу */
:root {
  --bs-canvas: #0B0813;
  --bs-s1: #120E1B;
  --bs-s2: #161120;
  --bs-s3: #1A1526;
  --bs-hair: #262033;
  --bs-hair-strong: #342C46;
  --bs-edge: rgba(255, 255, 255, .07);   /* верхняя световая кромка */
}
/* одометр (odometer.js) */
.odometer, .odometer .odometer-digit, .odometer .odometer-value {
  font-family: var(--mono) !important;
  font-variant-numeric: tabular-nums;
}
.odometer.odometer-auto-theme { line-height: 1.1; }

/* ── MVP-карта «ID игрока» (реф MAVE): фаски, кант, золото, флип ── */
.mvpx-slot { display: flex; justify-content: center; padding-bottom: 30px; }
.mvpx { position: relative; perspective: 900px; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.mvpx-tilt, .mvpx-card { position: absolute; inset: 0; transform-style: preserve-3d; }
.mvpx-face {
  position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden;
  transform: translateZ(0);
}
.mvpx-back { transform: rotateY(180deg); }
.mvpx-body { position: absolute; inset: 0; width: 100%; height: 100%; }

/* золотое свечение: аура пульсирует, комета бежит по контуру (GSAP) */
.mvpx-glow { position: absolute; pointer-events: none; z-index: -1; }
.mxg-aura { opacity: .42; }
@media (prefers-reduced-motion: no-preference) {
  .mxg-aura { animation: mxg-pulse 5.5s ease-in-out infinite; }
  @keyframes mxg-pulse { 0%, 100% { opacity: .3; } 50% { opacity: .55; } }
}
.mxg-comet, .mxg-comet-soft { opacity: .9; }

/* голо-фольга: блик следует за курсором (--mx/--my), в покое плывёт сам */
.mvpx-foil {
  position: absolute; inset: 0; pointer-events: none; opacity: .4; mix-blend-mode: color-dodge;
  background:
    radial-gradient(farthest-corner at var(--mx, 50%) var(--my, 38%),
      rgba(255, 214, 140, .5) 0%, rgba(255, 170, 70, .13) 26%, transparent 52%),
    repeating-linear-gradient(115deg,
      rgba(255, 200, 110, 0) 0 6%, rgba(255, 208, 128, .055) 9%,
      rgba(160, 120, 255, .035) 12%, rgba(255, 200, 110, 0) 16%);
  transition: opacity .4s;
}
.mvpx.lit .mvpx-foil { opacity: .85; }
.mvpx-foil.strong { opacity: .6; }

/* содержимое лицевой стороны */
.mvpx-in { position: absolute; inset: 0; padding: 22px 24px 20px; display: flex; flex-direction: column; }
.mvpx-toprow { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 12px; }
.mvpx-qr { width: 44px; height: 44px; border-radius: 3px; flex: none; box-shadow: 0 2px 8px rgba(0, 0, 0, .5); }
.mvpx-holo {
  width: 30px; height: 30px; border-radius: 6px; margin-top: 7px; flex: none;
  background:
    conic-gradient(from 210deg, #caa3ff, #ffd98e, #9be8ff, #ffb3d9, #ffd98e, #caa3ff);
  filter: saturate(.8) brightness(.95); opacity: .8;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .25);
}
@media (prefers-reduced-motion: no-preference) {
  .mvpx-holo { animation: holo-turn 6s linear infinite; }
  @keyframes holo-turn { to { filter: saturate(.8) brightness(.95) hue-rotate(360deg); } }
}
.mvpx-tag {
  margin-left: auto; margin-top: 2px; text-align: right;
  font: 800 10px var(--mono); letter-spacing: .2em; color: var(--accent);
}

/* окно портрета: видео-луп целиком (contain) на размытом кино-кадре,
   монограмма — под видео как фолбэк; скан-линия + светящаяся окантовка */
.mvpx-win {
  position: relative; height: 164px; border-radius: 8px; overflow: hidden;
  background:
    radial-gradient(120% 90% at 50% 0%, rgba(232, 169, 62, .17), transparent 70%),
    linear-gradient(180deg, #1B1428, #100C1B);
  display: flex; align-items: center; justify-content: center;
}
.mvpx-winbg {
  position: absolute; inset: -18px; pointer-events: none;
  background: url("/static/media/mvp-poster.jpg") center/cover;
  filter: blur(15px) brightness(.42) saturate(1.2);
}
@media (prefers-reduced-motion: no-preference) {
  .mvpx-winbg { animation: winbg-drift 16s ease-in-out infinite alternate; }
  @keyframes winbg-drift { from { transform: scale(1.04); } to { transform: scale(1.16); } }
}
.mvpx-vid {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: contain;   /* кадр целиком, без обрезки */
  filter: saturate(1.06) contrast(1.03);
}
.mvpx-winrim {
  position: absolute; inset: 0; border-radius: 8px; pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(232, 169, 62, .5),
              inset 0 0 22px -6px rgba(232, 169, 62, .38);
}
.mvpx-mono {
  font: 800 44px var(--mono); letter-spacing: .04em; color: transparent;
  background: linear-gradient(168deg, #F5EDE0 18%, #B9A98F 46%, #7E7160 52%, #E8D9BC 82%);
  -webkit-background-clip: text; background-clip: text;
  filter: drop-shadow(0 3px 8px rgba(0, 0, 0, .55));
}
.mvpx-scan { position: absolute; left: 0; right: 0; height: 26px; top: -30px; pointer-events: none;
  background: linear-gradient(180deg, transparent, rgba(232, 169, 62, .14), transparent); }
@media (prefers-reduced-motion: no-preference) {
  .mvpx-scan { animation: mvpx-scan 4.5s ease-in-out infinite; }
  @keyframes mvpx-scan { 0%, 12% { top: -30px; } 55%, 62% { top: 122px; } 100% { top: -30px; } }
}

/* служебные данные — «документная» типографика */
.mvpx-meta { display: flex; gap: 14px; margin: 10px 0 8px; }
.mvpx-meta span { display: flex; flex-direction: column; gap: 2px; font: 600 9.5px var(--mono); letter-spacing: .1em; color: var(--text-2); }
.mvpx-meta i { font-style: normal; font-size: 8px; letter-spacing: .18em; color: var(--muted); }
.mvpx-name { margin-top: 2px; }
.mvpx-name i { font-style: normal; display: block; font: 700 8.5px var(--mono); letter-spacing: .22em; color: var(--muted); }
.mvpx-name b { font-size: 17px; letter-spacing: -.01em; display: block; margin: 2px 0; }
.mvpx-name small { font: 600 9px var(--mono); letter-spacing: .14em; color: #E8C87A; }
.mvpx-rev { font: 800 27px/1 var(--mono); letter-spacing: -.03em; margin-top: 10px; }
.mvpx-rev .u { font-size: 15px; font-weight: 600; color: var(--text-2); }
.mvpx-revcap { font: 700 9px var(--mono); letter-spacing: .16em; color: var(--muted); text-transform: uppercase; margin-top: 3px; }
.mvpx-row3 { display: flex; gap: 0; margin-top: 10px; border-top: 1px solid var(--bs-hair); padding-top: 9px; }
.mvpx-row3 span { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.mvpx-row3 span + span { border-left: 1px solid var(--bs-hair); padding-left: 12px; }
.mvpx-row3 i { font-style: normal; font: 700 8px var(--mono); letter-spacing: .16em; color: var(--muted); text-transform: uppercase; }
.mvpx-row3 b { font: 700 13px var(--mono); }
.mvpx-foot { margin-top: auto; display: flex; align-items: flex-end; justify-content: space-between; }
.mvpx-bar { height: 22px; fill: #C8B590; opacity: .75; }
.mvpx-emb { width: 34px; height: 34px; color: #D9C08E; opacity: .9; }
.mvpx-hint {
  position: absolute; left: 50%; bottom: -24px; transform: translateX(-50%);
  font: 600 9.5px var(--mono); letter-spacing: .12em; color: var(--muted); white-space: nowrap;
}

/* ── тыльная сторона: БОГ ПРОДАЖ #1 ── */
.mvpx-rays {
  position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background: repeating-conic-gradient(from 0deg at 50% 44%,
    rgba(232, 169, 62, .1) 0 7deg, transparent 7deg 18deg);
  -webkit-mask-image: radial-gradient(85% 60% at 50% 44%, #000 20%, transparent 72%);
  mask-image: radial-gradient(85% 60% at 50% 44%, #000 20%, transparent 72%);
}
@media (prefers-reduced-motion: no-preference) {
  .mvpx-rays { animation: mvpx-rays 26s linear infinite; }
  @keyframes mvpx-rays { to { transform: rotate(360deg); } }
}
.mvpx-in.back { align-items: center; justify-content: center; text-align: center; gap: 6px; }
.bk-emb { width: 44px; height: 44px; color: #E3C98F; margin-bottom: 4px; }
.bk-emb svg { width: 100%; height: 100%; }
.bk-title { display: flex; flex-direction: column; line-height: .96; }
.bk-title span {
  font: 800 44px/0.98 var(--font, inherit); letter-spacing: .02em; color: transparent;
  background: linear-gradient(105deg, #8A5A1C 8%, #F7D98B 32%, #B3781F 50%, #FFE9AD 66%, #8A5A1C 92%);
  background-size: 220% 100%; -webkit-background-clip: text; background-clip: text;
  filter: drop-shadow(0 4px 14px rgba(232, 169, 62, .3));
}
@media (prefers-reduced-motion: no-preference) {
  .bk-title span { animation: gold-sweep 4.2s linear infinite; }
  @keyframes gold-sweep { to { background-position: -220% 0; } }
}
.bk-one {
  font: 800 88px/1 var(--mono); letter-spacing: -.05em; margin-top: 6px; color: transparent;
  -webkit-text-stroke: 2px #E8C87A;
  filter: drop-shadow(0 0 22px rgba(232, 169, 62, .45));
}
.bk-who { margin-top: 14px; }
.bk-who b { display: block; font-size: 15px; }
.bk-who small { font: 600 10px var(--mono); color: var(--text-2); }
.bk-code { position: absolute; bottom: 22px; font: 600 8px var(--mono); letter-spacing: .22em; color: var(--muted); }

.mc { display: flex; flex-direction: column; gap: 14px; }
.mc-bar {
  display: flex; align-items: center; gap: 0;
  background: var(--bs-s1);
  border: 1px solid var(--bs-hair); border-radius: 10px;
  box-shadow: 0 1px 0 var(--bs-edge) inset, 0 16px 40px -20px rgba(0, 0, 0, .6);
  padding: 0 6px; overflow-x: auto;
}
.mc-bar > div {
  padding: 12px 18px; display: flex; flex-direction: column; gap: 3px; white-space: nowrap;
}
.mc-bar > div + div { border-left: 1px solid var(--bs-hair); }
.mc-bar .k { font: 700 9.5px var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.mc-bar .v { font: 700 17px var(--mono); letter-spacing: -.02em; }
.mc-bar .v .u { font-size: 12px; color: var(--text-2); font-weight: 500; }
.mc-bar .live-cell { margin-left: auto; flex-direction: row; align-items: center; gap: 8px; border-left: 1px solid var(--bs-hair); }

.mc-grid { display: grid; grid-template-columns: 296px 1fr 264px; gap: 14px; align-items: start; }

/* (стальная MVP-карточка v5 заменена на mvpx «ID игрока», см. блок выше) */

/* ── жетоны отряда: стальные пластины с оборотом ───── */
.tags { display: flex; flex-direction: column; gap: 9px; }
.tags-cap {
  display: flex; justify-content: space-between; align-items: baseline; padding: 2px 6px 3px;
  font: 700 9.5px var(--mono); letter-spacing: .16em; color: var(--muted); text-transform: uppercase;
}
.tags-cap .hint { letter-spacing: .1em; color: #8A7A57; text-transform: none; }

.tag { position: relative; height: 58px; perspective: 640px; cursor: pointer; outline: none; -webkit-tap-highlight-color: transparent; }
.tag-inner { position: absolute; inset: 0; transform-style: preserve-3d; }
.tag-face {
  position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden;
  display: flex; align-items: center; gap: 12px; padding: 0 20px 0 14px; overflow: hidden;
  /* фаскованная пластина: срез TL, ступень TR, срезы снизу */
  clip-path: polygon(10px 0, calc(100% - 40px) 0, calc(100% - 32px) 6px, calc(100% - 12px) 6px,
                     100% 16px, 100% calc(100% - 11px), calc(100% - 11px) 100%, 10px 100%, 0 calc(100% - 10px), 0 10px);
  background:
    linear-gradient(178deg, #85729B, #43375C 30%, #292039 72%, #4A3E62) padding-box;
}
.tag-face::before {   /* тело пластины поверх металлической кромки */
  content: ""; position: absolute; inset: 1.4px; z-index: 0;
  clip-path: polygon(10px 0, calc(100% - 40px) 0, calc(100% - 32px) 6px, calc(100% - 12px) 6px,
                     100% 16px, 100% calc(100% - 11px), calc(100% - 11px) 100%, 10px 100%, 0 calc(100% - 10px), 0 10px);
  background: linear-gradient(176deg, #1F1830, #131022 55%, #100C1B);
}
.tag-face > * { position: relative; z-index: 1; }
.tag-back { transform: rotateX(180deg); gap: 10px; }

/* пробитое отверстие слева и заклёпка справа */
.tag-hole {
  width: 9px; height: 9px; border-radius: 50%; flex: none; background: var(--bg);
  box-shadow: inset 0 1.5px 3px rgba(0, 0, 0, .9), 0 1px 0 rgba(255, 255, 255, .12);
}
.tag-rivet {
  width: 5px; height: 5px; border-radius: 50%; flex: none;
  background: radial-gradient(circle at 35% 30%, #9A88B0, #3A3050 70%);
}
.tag-pos { font: 800 12px var(--mono); color: var(--muted); width: 24px; flex: none; }
.tag-chip {
  width: 30px; height: 30px; border-radius: 7px; flex: none;
  display: flex; align-items: center; justify-content: center;
  font: 800 11px var(--mono); color: #0A0712; background: var(--mc, var(--accent));
  box-shadow: 0 2px 6px rgba(0, 0, 0, .45), 0 0 10px -3px var(--mc, transparent);
}
.tag-who { font-weight: 700; font-size: 13.5px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tag-rev { margin-left: auto; font: 700 14px var(--mono); letter-spacing: -.02em; white-space: nowrap; }
.tag-gap { font: 600 10.5px var(--mono); color: var(--muted); width: 74px; text-align: right; flex: none; white-space: nowrap; }
.tag-gap.leader { color: var(--accent); letter-spacing: .12em; font-weight: 800; }
.tag-code { height: 14px; width: 26px; flex: none; fill: #C8B590; opacity: .4; }
/* расплав плана — тонкая полоса вдоль нижней кромки */
.tag-melt {
  position: absolute; left: 10px; bottom: 0; height: 2.5px; z-index: 1;
  background: linear-gradient(90deg, #7A2A1E, #C2571F 55%, var(--accent));
  box-shadow: 0 0 8px rgba(255, 122, 46, .5);
}

/* оборот: ачивки + темп + цифры */
.tag-bwrap { display: flex; gap: 8px; min-width: 0; overflow: hidden; }
.tag-badge {
  display: inline-flex; align-items: center; gap: 5px; flex: none;
  font: 700 9px var(--mono); letter-spacing: .1em; text-transform: uppercase; color: #E8C87A;
  background: rgba(232, 169, 62, .09); border: 1px solid rgba(232, 169, 62, .28);
  border-radius: 5px; padding: 3px 7px;
}
.tag-badge svg { width: 11px; height: 11px; }
.tag-badge.none { color: var(--muted); background: none; border-color: var(--bs-hair); }
.tag-badge i { font-style: normal; }
.tag-spark { margin-left: auto; flex: none; display: flex; align-items: center; }
.tag-kv { display: flex; flex-direction: column; flex: none; gap: 1px; }
.tag-kv i { font-style: normal; font: 700 7.5px var(--mono); letter-spacing: .14em; color: var(--muted); text-transform: uppercase; }
.tag-kv b { font: 700 11.5px var(--mono); }

/* лидер: золотой жетон */
.tag.p1 .tag-face { background: linear-gradient(178deg, #D9B36A, #8A6A2E 30%, #4A3820 72%, #A8854A) padding-box; }
.tag.p1 .tag-face::before { background: linear-gradient(176deg, #241A2E, #171021 55%, #130D1C); }
.tag.p1 { filter: drop-shadow(0 0 14px rgba(232, 169, 62, .28)); }
.tag.p1 .tag-pos { color: #E8C87A; }
/* объём при наведении */
@media (prefers-reduced-motion: no-preference) {
  .tag { transition: transform .25s ease; }
  .tag:hover { transform: translateY(-2px); }
  .tag:hover .tag-face { filter: brightness(1.07); }
}
@media (prefers-reduced-motion: reduce) {
  .tag.flipped .tag-inner { transform: rotateX(180deg); }
}

/* ── пульт миссии: общий результат отдела ──────────── */
.mission {
  position: relative; padding: 16px 26px 22px; overflow: hidden;
  clip-path: polygon(14px 0, calc(100% - 64px) 0, calc(100% - 52px) 8px, calc(100% - 16px) 8px,
                     100% 22px, 100% calc(100% - 14px), calc(100% - 14px) 100%, 14px 100%, 0 calc(100% - 14px), 0 14px);
  background: linear-gradient(178deg, #85729B, #43375C 26%, #292039 74%, #4A3E62);
}
.mission::before {   /* тело консоли поверх металлической кромки */
  content: ""; position: absolute; inset: 1.6px; z-index: 0;
  clip-path: polygon(14px 0, calc(100% - 64px) 0, calc(100% - 52px) 8px, calc(100% - 16px) 8px,
                     100% 22px, 100% calc(100% - 14px), calc(100% - 14px) 100%, 14px 100%, 0 calc(100% - 14px), 0 14px);
  background: linear-gradient(176deg, #1D1730, #120E1E 55%, #0F0B19);
}
.mission::after {    /* редкий блик по стеклу пульта */
  content: ""; position: absolute; top: -40%; bottom: -40%; width: 26%; left: -50%; z-index: 2;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .045) 45%, rgba(255, 255, 255, .09) 50%, rgba(255, 255, 255, .045) 55%, transparent);
  transform: rotate(8deg); pointer-events: none;
}
@media (prefers-reduced-motion: no-preference) {
  .mission::after { animation: mi-sheen 9s ease-in-out infinite; }
  @keyframes mi-sheen { 0%, 78% { left: -50%; } 94%, 100% { left: 140%; } }
}
.mission > * { position: relative; z-index: 1; }
.mi-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.mi-title { font: 800 10.5px var(--mono); letter-spacing: .22em; color: var(--accent); }
.mi-live { display: flex; align-items: center; gap: 7px; font: 700 9.5px var(--mono); letter-spacing: .18em; color: var(--muted); }

.mi-grid { display: flex; align-items: flex-end; gap: 34px; margin-bottom: 16px; flex-wrap: wrap; }
.mi-fact i { font-style: normal; display: block; font: 700 9px var(--mono); letter-spacing: .16em; color: var(--muted); text-transform: uppercase; margin-bottom: 4px; }
.mi-fact b { font: 800 36px/1 var(--mono); letter-spacing: -.03em; display: block; }
.mi-fact b .u { font-size: 19px; font-weight: 600; color: var(--text-2); }
.mi-fact small { display: block; margin-top: 6px; font: 600 11px var(--mono); color: var(--text-2); }
/* процент — золотом (сплошной цвет: градиент-clip ломает барабаны одометра) */
.mi-pct b {
  font: 800 44px/1 var(--mono); letter-spacing: -.04em; display: block; color: #F0CC84;
  /* свечение фильтром, не text-shadow: тень режется overflow барабанов одометра */
  filter: drop-shadow(0 0 16px rgba(232, 169, 62, .38)) drop-shadow(0 2px 8px rgba(0, 0, 0, .5));
}
.mi-pct b .u { font-size: 22px; color: #B99552; }
.mi-pct i { font-style: normal; display: block; font: 700 9px var(--mono); letter-spacing: .16em; color: var(--muted); text-transform: uppercase; margin-top: 5px; }
.mi-slots { display: flex; gap: 10px; margin-left: auto; }
.mi-slot {
  display: flex; flex-direction: column; gap: 3px; padding: 10px 16px 11px; min-width: 108px;
  clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px);
  background: linear-gradient(178deg, #4E4166, #2A2138 40%, #201933);
  position: relative;
}
.mi-slot::before {
  content: ""; position: absolute; inset: 1.2px;
  clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px);
  background: linear-gradient(176deg, #191330, #110D1E);
}
.mi-slot > * { position: relative; }
.mi-slot i { font-style: normal; font: 700 8.5px var(--mono); letter-spacing: .16em; color: var(--muted); text-transform: uppercase; }
.mi-slot b { font: 700 17px var(--mono); letter-spacing: -.01em; }

/* расплав к плану: вехи 25/50/75, тлеющий фронт, бегущий блик */
.mi-trackwrap { position: relative; }
.mi-track {
  position: relative; height: 14px; border-radius: 4px; overflow: hidden;
  background: linear-gradient(180deg, #0B0813, #140F22);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, .7), 0 1px 0 rgba(255, 255, 255, .05);
}
.mi-fill {
  position: absolute; inset: 0 auto 0 0; border-radius: 4px 0 0 4px;
  background: linear-gradient(90deg, #571E15, #A03A1A 45%, #E06024 78%, var(--accent));
  box-shadow: 0 0 16px rgba(255, 122, 46, .35);
}
.mi-fill::after {   /* бегущий блик по расплаву */
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(100deg, transparent 30%, rgba(255, 230, 180, .28) 50%, transparent 70%);
  background-size: 220% 100%;
}
@media (prefers-reduced-motion: no-preference) {
  .mi-fill::after { animation: mi-flow 3.2s linear infinite; }
  @keyframes mi-flow { from { background-position: 160% 0; } to { background-position: -60% 0; } }
}
.mi-front {   /* раскалённая точка на фронте расплава */
  position: absolute; right: -1px; top: 50%; width: 9px; height: 9px; border-radius: 50%;
  transform: translate(0, -50%);
  background: radial-gradient(circle, #FFF3D6 20%, #FFB36B 55%, transparent 75%);
}
@media (prefers-reduced-motion: no-preference) {
  .mi-front { animation: mi-ember 1.6s ease-in-out infinite; }
  @keyframes mi-ember { 0%, 100% { opacity: 1; box-shadow: 0 0 10px 2px rgba(255, 179, 107, .8); }
                        50% { opacity: .65; box-shadow: 0 0 16px 5px rgba(255, 179, 107, .5); } }
}
.mi-tick { position: absolute; top: 2px; bottom: 2px; width: 1px; background: rgba(255, 255, 255, .16); }
.mi-tick.hit { background: rgba(255, 218, 150, .55); box-shadow: 0 0 6px rgba(232, 169, 62, .6); }
.mi-marks { position: relative; height: 16px; margin-top: 5px; font: 700 9px var(--mono); letter-spacing: .1em; color: var(--muted); }
.mi-marks span { position: absolute; transform: translateX(-50%); }
.mi-marks span.hit { color: #E8C87A; }
.mi-marks .fin { right: 0; transform: none; }
.mi-marks .fin.hit { color: #E8C87A; text-shadow: 0 0 10px rgba(232, 169, 62, .6); }

/* ── отчёт продаж: реестр с ручными полями ─────────── */
.rpt-wrap { overflow-x: auto; }
.rpt { min-width: 1080px; }
.rpt th { white-space: nowrap; }
.rpt td { vertical-align: middle; }
.rpt .who { white-space: nowrap; font-weight: 600; }
.rpt .co { max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rpt .svc { max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rpt-in {
  width: 96px; padding: 6px 8px; border-radius: 6px;
  background: var(--screen); border: 1px solid var(--screen-line);
  color: var(--text); font: 600 12px var(--mono);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, .45);
  transition: border-color .2s, box-shadow .2s;
}
.rpt-in.num { text-align: right; }
.rpt-in.date { width: 128px; color-scheme: dark; }
.rpt-in:focus {
  outline: none; border-color: var(--accent);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, .45), 0 0 0 2px rgba(255, 122, 46, .18);
}
.rpt-in.saved { border-color: var(--good); box-shadow: inset 0 1px 3px rgba(0,0,0,.45), 0 0 0 2px rgba(43, 182, 115, .22); }
.rpt-in.err { border-color: var(--bad); }
.rpt-in::placeholder { color: var(--muted); }
.rpt .act { white-space: nowrap; text-align: right; }
.rpt-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 27px; height: 27px; border-radius: 6px; border: 1px solid var(--panel-line);
  background: linear-gradient(var(--panel-t), var(--panel-b)); color: var(--text-2);
  cursor: pointer; vertical-align: middle; transition: color .15s, border-color .15s;
}
.rpt-btn + .rpt-btn, .rpt-btn + a, a + .rpt-btn { margin-left: 5px; }
.rpt-btn svg { width: 13px; height: 13px; }
.rpt-btn:hover { color: var(--accent); border-color: var(--accent); }
.rpt-btn.del:hover { color: var(--bad); border-color: var(--bad); }
.rpt tfoot td {
  border-top: 1px solid var(--bs-hair-strong); padding-top: 11px;
  font: 700 11px var(--mono); letter-spacing: .06em; color: var(--text-2); white-space: nowrap;
}
.rpt tfoot td.strong { color: var(--text); font-size: 12.5px; }
.rpt tr.off { opacity: .38; }
.rpt-foot { display: flex; align-items: center; gap: 16px; margin-top: 12px; font: 600 11px var(--mono); color: var(--muted); }
.rpt-show {
  background: none; border: 1px solid var(--panel-line); border-radius: 6px;
  color: var(--text-2); font: 600 11px var(--mono); padding: 5px 12px; cursor: pointer;
}
.rpt-show:hover { color: var(--text); border-color: var(--bs-hair-strong); }
.rpt-hidden { margin-top: 10px; }

/* ── ЗП: калькулятор менеджера ─────────────────────── */
.zp {
  position: relative; padding: 16px 26px 24px; overflow: hidden;
  clip-path: polygon(14px 0, calc(100% - 64px) 0, calc(100% - 52px) 8px, calc(100% - 16px) 8px,
                     100% 22px, 100% calc(100% - 14px), calc(100% - 14px) 100%, 14px 100%, 0 calc(100% - 14px), 0 14px);
  background: linear-gradient(178deg, #85729B, #43375C 26%, #292039 74%, #4A3E62);
}
.zp::before {
  content: ""; position: absolute; inset: 1.6px; z-index: 0;
  clip-path: polygon(14px 0, calc(100% - 64px) 0, calc(100% - 52px) 8px, calc(100% - 16px) 8px,
                     100% 22px, 100% calc(100% - 14px), calc(100% - 14px) 100%, 14px 100%, 0 calc(100% - 14px), 0 14px);
  background: linear-gradient(176deg, #1D1730, #120E1E 55%, #0F0B19);
}
.zp > * { position: relative; z-index: 1; }
.zp-cols { display: grid; grid-template-columns: 1fr 1fr 1.2fr; gap: 30px; }
@media (max-width: 1100px) { .zp-cols { grid-template-columns: 1fr; } }
.zp-col h3 {
  font: 800 10px var(--mono); letter-spacing: .2em; text-transform: uppercase;
  color: var(--text-2); margin-bottom: 14px; border-bottom: 1px solid var(--bs-hair);
  padding-bottom: 8px;
}
.zp-col h3 .auto, .zp-row .auto {
  font: 600 8.5px var(--mono); letter-spacing: .1em; color: #8A7A57;
  border: 1px solid rgba(232, 169, 62, .3); border-radius: 4px; padding: 1px 5px;
  vertical-align: 1px; margin-left: 6px; text-transform: none;
}
.zp-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 11px; }
.zp-row > span { font: 600 12px var(--font); color: var(--text-2); }
.zp-in {
  padding: 7px 10px; border-radius: 6px; background: var(--screen);
  border: 1px solid var(--screen-line); color: var(--text);
  font: 600 13px var(--mono); box-shadow: inset 0 1px 3px rgba(0, 0, 0, .45);
}
.zp-in.num { text-align: right; }
.zp-in:focus { outline: none; border-color: var(--accent); box-shadow: inset 0 1px 3px rgba(0,0,0,.45), 0 0 0 2px rgba(255,122,46,.18); }
select.zp-in { width: 100%; max-width: 200px; }
.zp-note { font: 500 10.5px var(--font); color: var(--muted); margin-top: 12px; line-height: 1.5; }

/* ступени комиссии */
.zp-steps { display: flex; flex-direction: column; gap: 7px; margin-top: 4px; }
.zp-step {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 8px 12px; border-radius: 8px; border: 1px solid var(--bs-hair);
  background: var(--bs-s1); transition: border-color .25s, box-shadow .25s;
}
.zp-step em { font-style: normal; font: 600 11.5px var(--mono); color: var(--text-2); display: flex; align-items: center; gap: 5px; }
.zp-step b { font: 700 13px var(--mono); display: flex; align-items: center; gap: 4px; }
.zp-step .zp-in { padding: 4px 6px; font-size: 12px; }
.zp-step.on {
  border-color: rgba(232, 169, 62, .55);
  box-shadow: 0 0 14px -4px rgba(232, 169, 62, .5), 0 1px 0 var(--bs-edge) inset;
}
.zp-step.on b { color: #F0CC84; }

/* результат */
.zp-scale { position: relative; height: 34px; margin: 6px 0 18px; }
.zp-zones { display: flex; height: 10px; border-radius: 4px; overflow: hidden; margin-top: 14px;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, .6); }
.zp-zones span { height: 100%; }
.zp-zones .z1 { background: #3A2530; }
.zp-zones .z2 { background: #6E3A1C; }
.zp-zones .z3 { background: linear-gradient(90deg, #A85A1E, var(--accent)); }
.zp-marker {
  position: absolute; top: 0; transform: translateX(-50%); transition: left .45s cubic-bezier(.3,1.4,.4,1);
  display: flex; flex-direction: column; align-items: center; gap: 1px;
}
.zp-marker b { font: 700 10.5px var(--mono); color: #F0CC84; }
.zp-marker::after {
  content: ""; width: 2px; height: 16px; background: #F0CC84; border-radius: 1px;
  box-shadow: 0 0 8px rgba(232, 169, 62, .8);
}
.zp-break { display: flex; flex-direction: column; gap: 8px; margin-bottom: 16px; }
.zp-break .r { display: flex; justify-content: space-between; font: 600 12px var(--mono); color: var(--text-2); }
.zp-break .r b { color: var(--text); }
.zp-total {
  border-top: 1px solid var(--bs-hair-strong); padding-top: 14px;
  display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap;
}
.zp-total i { font-style: normal; font: 800 10px var(--mono); letter-spacing: .2em; color: var(--muted); }
.zp-total b {
  font: 800 40px/1 var(--mono); letter-spacing: -.03em; color: #F0CC84;
  filter: drop-shadow(0 0 16px rgba(232, 169, 62, .38));
}
.zp-total .u { font: 600 20px var(--mono); color: #B99552; }

/* ── вход в ЛК ─────────────────────────────────────── */
#login-veil {
  position: fixed; inset: 0; z-index: 100;
  background: radial-gradient(900px 600px at 50% 30%, rgba(255, 122, 46, .07), transparent 60%), var(--bg);
  display: flex; align-items: center; justify-content: center; padding: 20px;
}
.login-card {
  width: 340px; padding: 34px 34px 30px; position: relative;
  clip-path: polygon(12px 0, calc(100% - 46px) 0, calc(100% - 38px) 7px, calc(100% - 12px) 7px,
                     100% 19px, 100% calc(100% - 12px), calc(100% - 12px) 100%, 12px 100%, 0 calc(100% - 12px), 0 12px);
  background: linear-gradient(178deg, #85729B, #43375C 26%, #292039 74%, #4A3E62);
}
.login-card::before {
  content: ""; position: absolute; inset: 1.6px; z-index: 0;
  clip-path: polygon(12px 0, calc(100% - 46px) 0, calc(100% - 38px) 7px, calc(100% - 12px) 7px,
                     100% 19px, 100% calc(100% - 12px), calc(100% - 12px) 100%, 12px 100%, 0 calc(100% - 12px), 0 12px);
  background: linear-gradient(176deg, #1D1730, #110D1E 60%, #0E0A18);
}
.login-card > * { position: relative; z-index: 1; }
.login-card .brand-mark.big { width: 16px; height: 16px; border-radius: 4px; display: block; margin-bottom: 14px; }
.login-card h1 { font: 800 17px var(--font); letter-spacing: -.01em; }
.lc-sub { font: 600 10px var(--mono); letter-spacing: .18em; text-transform: uppercase; color: var(--muted); margin: 4px 0 22px; }
.login-card label { display: block; font: 600 11px var(--font); color: var(--text-2); margin-bottom: 14px; }
.login-card input {
  display: block; width: 100%; margin-top: 5px; padding: 9px 11px; border-radius: 7px;
  background: var(--screen); border: 1px solid var(--screen-line); color: var(--text);
  font: 600 14px var(--mono); box-shadow: inset 0 1px 3px rgba(0, 0, 0, .45);
}
.login-card input:focus { outline: none; border-color: var(--accent); box-shadow: inset 0 1px 3px rgba(0,0,0,.45), 0 0 0 2px rgba(255,122,46,.18); }
.login-card button {
  width: 100%; margin-top: 6px; padding: 11px; border: 0; border-radius: 8px; cursor: pointer;
  background: linear-gradient(180deg, #FF8A45, #E5601C); color: #1A0D04;
  font: 800 13px var(--font); letter-spacing: .04em;
  box-shadow: 0 1px 0 rgba(255, 255, 255, .25) inset, 0 6px 18px -6px rgba(255, 122, 46, .55);
}
.login-card button:hover { filter: brightness(1.07); }
.lc-err { font: 600 11px var(--mono); color: var(--bad); margin: -6px 0 10px; }
.login-card.shake { animation: lc-shake .4s; }
@keyframes lc-shake { 0%,100% { transform: translateX(0); } 20%,60% { transform: translateX(-7px); } 40%,80% { transform: translateX(7px); } }

/* пользователь в сайдбаре */
.side-user {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  margin-top: auto; padding: 10px 10px 0;
}
.side-user + .side-foot { margin-top: 0; }
.su-name { font: 600 11.5px var(--font); color: var(--text-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.su-exit {
  background: none; border: 1px solid var(--panel-line); border-radius: 6px; cursor: pointer;
  width: 26px; height: 26px; display: flex; align-items: center; justify-content: center;
  color: var(--muted); flex: none;
}
.su-exit svg { width: 13px; height: 13px; }
.su-exit:hover { color: var(--bad); border-color: var(--bad); }

/* настройки доступов */
.st .who { display: flex; align-items: center; gap: 9px; font-weight: 600; }
.st .dot { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.st-login { font: 700 12.5px var(--mono); color: #E8C87A; background: rgba(232, 169, 62, .08); padding: 3px 8px; border-radius: 5px; }
.st-none { color: var(--muted); font: 500 11.5px var(--font); }
.st-act { text-align: right; white-space: nowrap; }
.st-act .rpt-in { margin-right: 6px; }
.st-do.primary { color: var(--accent); border-color: rgba(255, 122, 46, .5); }
.st-do.danger:hover { color: var(--bad); border-color: var(--bad); }
.st-msg { margin-top: 12px; font: 600 12px var(--mono); }
.st-msg.ok { color: var(--good); }
.st-msg.bad { color: var(--bad); }
.st-admin { display: flex; gap: 8px; align-items: center; }

/* планы на месяц */
.pl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 10px 24px; }
.pl-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.pl-row > span { font: 600 12px var(--font); color: var(--text-2); }
.pl-row.team > span { color: var(--accent); font-weight: 700; }
.pl-row.team { grid-column: 1 / -1; border-bottom: 1px solid var(--bs-hair); padding-bottom: 12px; margin-bottom: 4px; }
.pl-in { width: 130px; text-align: right; }
.pl-foot { display: flex; align-items: center; gap: 14px; margin-top: 16px; }
.pl-save { width: auto; padding: 11px 22px; }

/* ── расходы: штаб ─────────────────────────────────── */
.cost { display: flex; flex-direction: column; gap: 14px; }
.cost-grid { display: grid; grid-template-columns: 320px 1fr; gap: 14px; align-items: start; }
@media (max-width: 980px) { .cost-grid { grid-template-columns: 1fr; } }
.cost-form { display: flex; flex-direction: column; }
.cost-form .zp-row { margin-bottom: 13px; }
.cost-entpick { display: flex; border: 1px solid var(--panel-line); border-radius: 7px; overflow: hidden; }
.cost-entpick button {
  background: none; border: 0; color: var(--text-2); font: 700 12px var(--mono);
  padding: 7px 16px; cursor: pointer;
}
.cost-entpick button + button { border-left: 1px solid var(--panel-line); }
.cost-entpick button.on { background: rgba(255, 122, 46, .14); color: var(--accent); }
.cost-add {
  margin-top: 4px; padding: 12px; border: 0; border-radius: 8px; cursor: pointer;
  background: linear-gradient(180deg, #FF8A45, #E5601C); color: #1A0D04;
  font: 800 13px var(--font); letter-spacing: .08em;
  box-shadow: 0 1px 0 rgba(255, 255, 255, .25) inset, 0 6px 18px -6px rgba(255, 122, 46, .55);
  transition: filter .15s;
}
.cost-add:hover { filter: brightness(1.07); }
.cost-add.done { background: linear-gradient(180deg, #3ECF8E, #1F9A62); }
.cost-msg { margin-top: 10px; font: 600 11px var(--mono); color: var(--bad); }

/* полосы по статьям */
.cost-bars { display: flex; flex-direction: column; gap: 11px; }
.cost-bar { display: grid; grid-template-columns: 128px 1fr 110px 40px; gap: 12px; align-items: center; }
.cb-name { font: 600 12px var(--font); color: var(--text-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cb-track {
  height: 12px; border-radius: 4px; overflow: hidden; position: relative;
  background: linear-gradient(180deg, #0B0813, #140F22);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, .6);
}
.cb-fill {
  position: absolute; inset: 0 auto 0 0; border-radius: 4px 0 0 4px; min-width: 3px;
  background: linear-gradient(90deg, #571E15, #A03A1A 45%, #E06024 78%, var(--accent));
  box-shadow: 0 0 12px rgba(255, 122, 46, .3);
}
.cb-fill::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(100deg, transparent 30%, rgba(255, 230, 180, .25) 50%, transparent 70%);
  background-size: 220% 100%;
}
@media (prefers-reduced-motion: no-preference) {
  .cb-fill::after { animation: mi-flow 3.4s linear infinite; }
  .cost-bar { animation: cb-in .5s calc(var(--i) * 70ms) both cubic-bezier(.2, .9, .3, 1); }
  @keyframes cb-in { from { opacity: 0; transform: translateX(-14px); } }
}
.cb-sum { font: 700 13px var(--mono); text-align: right; white-space: nowrap; }
.cb-share { font: 600 10.5px var(--mono); color: var(--muted); text-align: right; }

.cost-ent {
  font: 700 10px var(--mono); letter-spacing: .08em; padding: 3px 8px; border-radius: 5px;
  background: rgba(57, 135, 229, .12); color: #7FB3F2; border: 1px solid rgba(57, 135, 229, .3);
}
.cost-ent.ip { background: rgba(232, 169, 62, .1); color: #E8C87A; border-color: rgba(232, 169, 62, .3); }
.cost-hist .act { text-align: right; }

/* F1-грид позиций */
.f1 {
  background: var(--bs-s1); border: 1px solid var(--bs-hair); border-radius: 12px;
  box-shadow: 0 1px 0 var(--bs-edge) inset, 0 20px 50px -24px rgba(0, 0, 0, .65);
  overflow: hidden;
}
.f1-head {
  display: grid; grid-template-columns: 40px minmax(92px, 1fr) 112px 80px 66px 108px;
  gap: 10px; padding: 9px 14px;
  font: 700 9.5px var(--mono); letter-spacing: .12em; text-transform: uppercase;
  color: var(--muted); border-bottom: 1px solid var(--bs-hair);
}
.f1-head span:nth-child(n+3) { text-align: right; }
.f1-row {
  position: relative;
  display: grid; grid-template-columns: 40px minmax(92px, 1fr) 112px 80px 66px 108px;
  gap: 10px; padding: 12px 14px; align-items: center;
  border-left: 3px solid var(--mc, var(--muted));
  transition: background .15s;
}
.f1-row + .f1-row { border-top: 1px solid var(--bs-hair); }
.f1-row:hover { background: var(--bs-s2); }
.f1-row.p1 { background: linear-gradient(90deg, rgba(255, 122, 46, .06), transparent 55%); }
.f1-pos { font: 800 15px var(--mono); color: var(--muted); }
.f1-row.p1 .f1-pos { color: var(--accent); }
.f1-who { min-width: 0; display: flex; align-items: center; gap: 8px; }
.f1-who b { font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.f1-badge { width: 15px; height: 15px; border-radius: 4px; flex: none; display: inline-flex; align-items: center; justify-content: center; background: rgba(255, 255, 255, .07); color: #c98500; cursor: help; }
.f1-badge svg { width: 9.5px; height: 9.5px; }
.f1-rev { text-align: right; font: 700 13.5px var(--mono); letter-spacing: -.01em; }
.f1-gap { text-align: right; font: 600 12px var(--mono); color: var(--muted); }
.f1-gap.leader { color: var(--accent); font-weight: 800; letter-spacing: .06em; }
.f1-spark { text-align: right; opacity: .85; }
.f1-plan { display: flex; flex-direction: column; gap: 5px; }
.f1-plan .t { display: flex; justify-content: space-between; font: 700 10.5px var(--mono); color: var(--text-2); }

/* расплав-прогресс */
.melt {
  height: 7px; border-radius: 2px; position: relative;
  background: linear-gradient(#0d0a14, #17121f);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .05);
}
.melt-fill {
  position: absolute; inset: 0 auto 0 0; border-radius: 2px; overflow: visible;
  background: linear-gradient(90deg, #591708, #a83a14 55%, #e85a20 85%, #FF7A2E);
}
.melt-fill::after {   /* раскалённая кромка */
  content: ""; position: absolute; right: -2px; top: 50%; width: 5px; height: 5px;
  transform: translateY(-50%); border-radius: 50%;
  background: #FFE9CE;
  box-shadow: 0 0 6px 1px rgba(255, 170, 90, .9), 0 0 14px 3px rgba(255, 122, 46, .45);
}
@media (prefers-reduced-motion: no-preference) {
  .melt-fill::after { animation: ember 2.2s ease-in-out infinite; }
  @keyframes ember {
    0%, 100% { box-shadow: 0 0 6px 1px rgba(255, 170, 90, .9), 0 0 14px 3px rgba(255, 122, 46, .45); }
    50% { box-shadow: 0 0 4px 1px rgba(255, 170, 90, .6), 0 0 9px 2px rgba(255, 122, 46, .3); }
  }
}
.melt-fill.done { background: linear-gradient(90deg, #0f5c3a, #199e70 70%, #2BB673); }
.melt-fill.done::after { background: #D9FFEC; box-shadow: 0 0 6px 1px rgba(43, 182, 115, .9), 0 0 14px 3px rgba(43, 182, 115, .45); }

/* лента сделок */
.feed-pro {
  background: var(--bs-s1); border: 1px solid var(--bs-hair); border-radius: 12px;
  box-shadow: 0 1px 0 var(--bs-edge) inset, 0 20px 50px -24px rgba(0, 0, 0, .65);
  padding: 12px 14px; max-height: 460px; overflow: hidden;
}
.feed-pro h3 { font: 700 9.5px var(--mono); letter-spacing: .16em; color: var(--muted); margin: 2px 2px 10px; }
.fp-item {
  border-left: 2px solid var(--mc, var(--good));
  padding: 7px 10px; margin-bottom: 7px; border-radius: 0 7px 7px 0;
  background: var(--bs-s2);
  font: 600 11.5px var(--mono);
}
.fp-item b { color: var(--good); }
.fp-item .w { color: var(--text); }
.fp-item small { display: block; color: var(--muted); margin-top: 2px; font-size: 10px; }
@media (prefers-reduced-motion: no-preference) {
  .fp-item.in { animation: fp-in .45s cubic-bezier(.2, .9, .3, 1.15) both; }
  @keyframes fp-in { from { opacity: 0; transform: translateX(14px); } to { opacity: 1; transform: none; } }
}

@media (max-width: 1100px) {
  .mc-grid { grid-template-columns: 1fr; }
  .f1-head { display: none; }
  .f1-row { grid-template-columns: 36px 1fr 100px; }
  .f1-gap, .f1-spark { display: none; }
  .f1-plan { grid-column: 2 / -1; }
}

/* ── гоночная трасса ───────────────────────────────── */
.track { position: relative; padding: 6px 0 2px; }
.track-head {
  position: relative; height: 18px; margin: 0 170px 6px 232px;
  font: 600 10px/1 var(--mono); color: var(--muted);
}
.track-head span { position: absolute; transform: translateX(-50%); }
.lane { display: grid; grid-template-columns: 232px 1fr 170px; gap: 0; align-items: center; padding: 9px 0; }
.lane + .lane { border-top: 1px solid rgba(255, 255, 255, .04); }
.lane-who { display: flex; align-items: center; gap: 10px; min-width: 0; padding-right: 14px; }
.lane-rank { font-family: var(--mono); font-weight: 800; font-size: 15px; color: var(--muted); width: 26px; flex: none; }
.lane.top1 .lane-rank { color: var(--accent); }
.lane-name { min-width: 0; }
.lane-name b { font-size: 13.5px; display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lane-name small {
  font: 500 10.5px/1.4 var(--mono); color: var(--muted); display: block;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.badges { display: inline-flex; gap: 4px; margin-left: 2px; vertical-align: middle; }
.badge {
  width: 17px; height: 17px; border-radius: 50%; flex: none; cursor: help;
  display: inline-flex; align-items: center; justify-content: center;
  background: rgba(255, 255, 255, .1); color: var(--c-gold);
}
.badge svg { width: 11px; height: 11px; }

.lane-road { position: relative; height: 34px; }
.lane-road::before {  /* полотно дорожки с разметкой */
  content: ""; position: absolute; inset: 12px 0;
  background: rgba(255, 255, 255, .05); border-radius: 5px;
  background-image: repeating-linear-gradient(90deg,
    transparent 0 calc(25% - 1px), rgba(255, 255, 255, .12) calc(25% - 1px) 25%);
}
.lane-road::after {   /* финиш: клетчатый флаг */
  content: ""; position: absolute; right: 0; top: 6px; bottom: 6px; width: 8px;
  border-radius: 2px; opacity: .55;
  background: repeating-conic-gradient(#cfc9dd 0% 25%, #14101d 0% 50%) 0 0 / 8px 8px;
}
.lane-trail {
  position: absolute; left: 0; top: 50%; height: 4px; transform: translateY(-50%);
  border-radius: 2px; background: var(--tc, var(--c-blue)); opacity: .5;
  transition: width .7s cubic-bezier(.2, .7, .3, 1);
}
.lane.top1 .lane-trail {
  height: 8px; opacity: .9;
  background: linear-gradient(90deg, transparent, #b8431c 30%, #FF7A2E 80%, #FFC08A);
  box-shadow: 0 0 14px rgba(255, 122, 46, .55);
}
.chip-car {
  position: absolute; top: 50%; transform: translate(-50%, -50%);
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--tc, var(--c-blue));
  display: flex; align-items: center; justify-content: center;
  font: 800 10.5px/1 var(--mono); color: #0A0712; letter-spacing: .02em;
  box-shadow: 0 0 12px var(--tc, var(--c-blue)), 0 4px 10px rgba(0, 0, 0, .5);
  transition: left .7s cubic-bezier(.2, .7, .3, 1);
  z-index: 2;
}
.lane.top1 .chip-car { width: 34px; height: 34px; font-size: 11.5px; }
/* искры за лидером */
.spark { position: absolute; top: 50%; width: 4px; height: 4px; border-radius: 50%; background: #FFC08A; opacity: 0; z-index: 1; }
@media (prefers-reduced-motion: no-preference) {
  .spark { animation: sparkfly 1.5s ease-out infinite; }
  .spark:nth-child(2) { animation-delay: .5s; }
  .spark:nth-child(3) { animation-delay: 1s; }
  @keyframes sparkfly {
    0% { opacity: .9; transform: translate(0, -50%) scale(1); }
    100% { opacity: 0; transform: translate(-34px, calc(-50% + var(--sy, -10px))) scale(.3); }
  }
}
.lane-res { text-align: right; font-family: var(--mono); padding-left: 12px; }
.lane-res b { font-size: 15px; font-weight: 700; display: block; }
.lane-res small { font-size: 10.5px; color: var(--muted); display: block; line-height: 1.5; white-space: nowrap; }
.lane-pct { font: 700 11px/1 var(--mono); }

/* медали топ-3 */
.medal { width: 18px; height: 22px; flex: none; }

/* ── лидерборд ─────────────────────────────────────── */
.board { display: flex; flex-direction: column; gap: 12px; position: relative; }
.board-row {
  display: grid; grid-template-columns: 62px minmax(120px, 200px) 1fr minmax(190px, 260px) auto;
  gap: 18px; align-items: center;
  background: linear-gradient(var(--panel-t), var(--panel-b));
  border: 1px solid var(--panel-line);
  border-radius: var(--r); padding: 15px 20px;
  box-shadow: var(--shadow-panel);
  will-change: transform;
}
.board-row.top1 {
  border-color: color-mix(in srgb, var(--accent) 50%, var(--panel-line));
  box-shadow: var(--shadow-panel), 0 0 30px -12px rgba(255, 122, 46, .45);
}
.rank-num {
  font-size: 26px; font-weight: 800; color: var(--muted); line-height: 1; text-align: center;
  letter-spacing: -.04em;
}
.rank-num::before { content: "P"; font-size: 15px; font-weight: 700; opacity: .55; margin-right: 1px; }
.top1 .rank-num { color: var(--accent); font-size: 31px; text-shadow: 0 0 18px rgba(255,122,46,.4); }
.top2 .rank-num, .top3 .rank-num { color: var(--text-2); font-size: 28px; }
.board-name { font-weight: 700; font-size: 15px; }
.board-name small { display: block; color: var(--muted); font-weight: 400; font-size: 11.5px; margin-top: 3px; font-family: var(--mono); }
.board-rev { font-size: 21px; font-weight: 700; text-align: right; letter-spacing: -.02em; }
.top1 .board-rev { font-size: 24px; }
.board-rev small { display: block; font-size: 11px; color: var(--muted); font-weight: 400; margin-top: 2px; }
.board-plan .prog { margin-top: 5px; }
.plan-line { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--text-2); }
.prog-pct { font-weight: 700; }
.board-stats { text-align: right; font-size: 12px; color: var(--text-2); line-height: 1.6; }
.board-stats b { color: var(--text); }

.team-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }

/* ── воронка ───────────────────────────────────────── */
.funnel { display: flex; flex-direction: column; gap: 7px; }
.fstage { display: grid; grid-template-columns: minmax(110px, 170px) 1fr 90px; gap: 10px; align-items: center; }
.fstage .lbl { font-size: 12.5px; color: var(--text-2); text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fstage .val { font-size: 12px; color: var(--text-2); }
.fstage .val b { color: var(--text); font-weight: 700; }
.fstage .bar { height: 21px; border-radius: 5px; }
.fstage .bar-fill { border-radius: 5px; }
.ftrans { display: grid; grid-template-columns: minmax(110px, 170px) 1fr 90px; gap: 10px; }
.ftrans span { grid-column: 2; font-size: 10.5px; color: var(--muted); padding-left: 4px; font-family: var(--mono); }

/* ── алерты ────────────────────────────────────────── */
.alerts { display: flex; flex-direction: column; gap: 12px; }
.alert { display: flex; gap: 12px; align-items: flex-start; }
.alert-ind {
  width: 4px; align-self: stretch; border-radius: 2px; background: var(--bad); flex: none; margin-top: 2px;
  box-shadow: 0 0 8px color-mix(in srgb, var(--bad) 60%, transparent);
}
.alert-ind.warn { background: var(--c-gold); box-shadow: 0 0 8px color-mix(in srgb, var(--c-gold) 60%, transparent); }
.alert .desc { color: var(--text-2); font-size: 12.5px; margin-top: 1px; }

/* ── срочность / плитки ────────────────────────────── */
.urg { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.urg-tile {
  background: linear-gradient(172deg, #221B30, #191428);
  border: 1px solid rgba(255, 255, 255, .05);
  border-radius: 11px; padding: 14px;
  box-shadow: 0 8px 20px -8px rgba(0, 0, 0, .55);
}
.urg-tile.hi { border-color: color-mix(in srgb, var(--good) 55%, var(--screen-line)); }
.urg-key { font-size: 12.5px; font-weight: 700; color: var(--text-2); }
.urg-conv { font-size: 25px; font-weight: 700; margin: 5px 0 3px; letter-spacing: -.02em; }
.urg-tile.hi .urg-conv { color: var(--good); text-shadow: 0 0 16px rgba(43,182,115,.35); }
.urg-sub { font-size: 11.5px; color: var(--muted); font-family: var(--mono); }

/* ── svg-чарты ─────────────────────────────────────── */
.chart-box { width: 100%; overflow: hidden; }
.chart-box svg { display: block; width: 100%; height: auto; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 10px; font-size: 12px; color: var(--text-2); }
.legend .li { display: flex; align-items: center; gap: 6px; }
.legend .sw { width: 10px; height: 10px; border-radius: 3px; }
.axis text { fill: var(--muted); font-size: 10px; font-family: var(--mono); }
.gridline { stroke: #1B1529; }

@media (prefers-reduced-motion: no-preference) {
  .pulse-dot { animation: pdot 2.4s ease-in-out infinite; transform-origin: center; transform-box: fill-box; }
  @keyframes pdot { 0%, 100% { opacity: .9; transform: scale(1); } 50% { opacity: .3; transform: scale(1.8); } }
}

/* ── адаптив ───────────────────────────────────────── */
@media (max-width: 1060px) {
  .kpis { grid-template-columns: repeat(2, 1fr); }
  .team-strip { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 800px) {
  .shell { flex-direction: column; }
  .side {
    width: 100%; height: auto; position: static; flex-direction: row;
    align-items: center; padding: 8px 12px; gap: 10px;
    border-right: 0; border-bottom: 1px solid var(--panel-line);
  }
  .brand { padding: 0; }
  .brand-sub { display: none; }
  .nav { flex-direction: row; overflow-x: auto; flex: 1; }
  .nav a { padding: 8px 10px; }
  .nav a span { display: none; }
  .side-foot { margin: 0; padding: 0; border: 0; }
  .clock { display: none; }
  .topbar { flex-wrap: wrap; height: auto; padding: 0 10px; }
  .topbar .ticker { order: 2; width: 100%; flex: none; height: 34px; }
  .tick-track { height: 34px; }
  .topbar .periods { order: 1; margin: 8px 0 8px auto; }
  .hero-value { font-size: 32px; }
  .hero-in { flex-direction: column; align-items: flex-start; }
  .g2 { grid-template-columns: 1fr; }
  .kpis { grid-template-columns: 1fr 1fr; }
  .board-row { grid-template-columns: 46px 1fr auto; grid-template-rows: auto auto; }
  .board-plan { grid-column: 2 / -1; }
  .board-stats { display: none; }
  .urg { grid-template-columns: 1fr; }
  .view { padding: 14px 14px 32px; }
}

/* всплывающий выбор диапазона дат */
.range-pop {
  display: flex; align-items: center; gap: 6px; padding: 0 10px;
  background: rgba(255, 122, 46, .07);
}
.range-pop .sep { color: var(--muted); font: 600 11px var(--mono); }
.range-pop input[type="date"] {
  background: var(--screen); border: 1px solid var(--screen-line); border-radius: 6px;
  color: var(--text); font: 600 11.5px var(--mono); padding: 5px 7px; color-scheme: dark;
}
.range-pop button {
  background: linear-gradient(180deg, #FF8A45, #E5601C); border: 0; border-radius: 6px;
  color: #1A0D04; font: 800 11px var(--font); padding: 6px 12px; cursor: pointer;
}
.rpt-mgrsel { margin-left: auto; float: right; max-width: 190px; font-size: 12px; }
.rpt-card h2 { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.rpt-card h2 .note { flex: 1; }
