/* ============================================================
   Sports-Max — компоненты. Modern sports, mobile-first (360px → вверх).
   Единственный источник стилей компонентов; цвета/размеры — из tokens.css.
   ============================================================ */

/* ----- Заголовок страницы ----- */
.page-title {
  position: relative;
  font-size: var(--fs-2xl);
  letter-spacing: -0.025em;
  margin-bottom: var(--sp-4);
  padding-bottom: var(--sp-2);
}
.page-title::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 58px;
  height: 4px;
  border-radius: var(--r-pill);
  background: var(--grad-accent);
}

/* ----- Панели ----- */
.panel {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--r-xl);
  box-shadow: var(--shadow-1);
  padding: var(--sp-4);
  margin-bottom: var(--sp-4);
}
@media (min-width: 768px) {
  .panel { padding: var(--sp-5); }
}
.panel > h2,
.panel h2 {
  font-size: var(--fs-xl);
  margin-bottom: var(--sp-3);
}
/* Акцентная полоса у заголовка секции */
.panel > h2,
.panel-head h2 {
  position: relative;
  padding-left: var(--sp-3);
}
.panel > h2::before,
.panel-head h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.16em;
  bottom: 0.16em;
  width: 4px;
  border-radius: var(--r-pill);
  background: var(--grad-accent);
}
.panel-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--sp-2);
  flex-wrap: wrap;
  margin-bottom: var(--sp-3);
}
.panel-head h2 { margin: 0; }

.link { color: var(--c-primary); font-size: var(--fs-sm); font-weight: 800; }
.muted { color: var(--c-muted); }
.updated { color: var(--c-muted); font-size: var(--fs-sm); margin-top: var(--sp-3); }
.zone-note {
  margin: var(--sp-4) 0 var(--sp-2);
  font-size: var(--fs-xs);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--c-muted);
}
.data-meta {
  margin-top: var(--sp-4);
  font-size: var(--fs-sm);
  color: var(--c-muted);
}

/* ----- Кнопки ----- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  min-height: var(--touch);
  padding: 0 var(--sp-5);
  border-radius: var(--r-md);
  border: 1px solid transparent;
  background-color: var(--c-primary);
  background-image: var(--grad-brand);
  color: var(--c-on-primary);
  font-size: var(--fs-sm);
  font-weight: 800;
  text-decoration: none;
  box-shadow: var(--shadow-glow);
  transition: filter var(--dur) var(--ease), transform 0.06s var(--ease),
    box-shadow var(--dur) var(--ease), background-color var(--dur) var(--ease);
}
.btn:hover {
  filter: brightness(1.06);
  color: var(--c-on-primary);
  text-decoration: none;
}
.btn:active { transform: translateY(1px); box-shadow: none; }
.btn-ghost {
  background-image: none;
  background-color: var(--c-surface);
  color: var(--c-primary);
  border-color: var(--c-border-2);
  box-shadow: none;
}
.btn-ghost:hover {
  filter: none;
  background-color: var(--c-primary-soft);
  color: var(--c-primary);
  border-color: var(--c-primary);
}
.export-row { display: flex; flex-wrap: wrap; gap: var(--sp-2); }

/* ----- Турнирная таблица ----- */
.table-scroll {
  overflow-x: auto;
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
}
.standings {
  width: 100%;
  min-width: 320px;
  border-collapse: separate;
  border-spacing: 0;
  font-size: var(--fs-sm);
}
.standings th,
.standings td {
  padding: var(--sp-2) var(--sp-3);
  text-align: center;
  white-space: nowrap;
  border-bottom: 1px solid var(--c-border);
  background: var(--c-surface);
}
.standings thead th {
  background: var(--c-thead);
  color: var(--c-thead-text);
  font-weight: 800;
  font-size: var(--fs-xs);
  letter-spacing: 0.02em;
  border-bottom: 0;
}
.standings thead th:first-child { border-top-left-radius: var(--r-lg); }
.standings thead th:last-child { border-top-right-radius: var(--r-lg); }
.standings .col-pos { color: var(--c-muted); font-variant-numeric: tabular-nums; }
.standings .col-team { text-align: left; }
.standings th.col-team,
.standings td.col-team {
  position: sticky;
  left: 0;
  z-index: 1;
  box-shadow: 1px 0 0 var(--c-border);
}
.standings thead th.col-team { z-index: 3; background: var(--c-thead); }
.standings .col-pts { font-weight: 800; font-variant-numeric: tabular-nums; }
.standings tbody tr:last-child td { border-bottom: 0; }
.standings tbody tr:nth-child(even) td { background: var(--c-surface-2); }
.standings tbody tr:hover td { background: color-mix(in srgb, var(--c-primary) 7%, var(--c-surface)); }

/* Зоны — цветной маркер в первой колонке (базовый .zone — прозрачный) */
.standings tr.zone > td:first-child { box-shadow: inset 3px 0 0 transparent; }
.standings tr.zone-promotion > td:first-child,
.standings tr.zone-champions > td:first-child,
.standings tr.zone-playoff > td:first-child,
.standings tr.zone-playoffs > td:first-child { box-shadow: inset 4px 0 0 var(--c-success); }
.standings tr.zone-europa > td:first-child { box-shadow: inset 4px 0 0 var(--c-info); }
.standings tr.zone-relegation > td:first-child { box-shadow: inset 4px 0 0 var(--c-danger); }
.standings tr.zone-out > td:first-child { box-shadow: inset 4px 0 0 var(--c-muted); }

/* Мобильный — только ключевые колонки; второстепенные на планшете/ПК */
.col-md { display: none; }
@media (min-width: 768px) {
  .standings .col-md { display: table-cell; }
  /* На широком экране таблица влезает — включаем липкую шапку по странице */
  .table-scroll { overflow: visible; border: 0; border-radius: 0; }
  .standings thead th { position: sticky; top: calc(var(--header-h) - 1px); z-index: 4; }
  .standings td.col-team { position: static; box-shadow: none; }
  .standings thead th.col-team { position: sticky; }
}
.standings .col-team a { color: var(--c-text); font-weight: 700; }
.standings .col-team a:hover { color: var(--c-primary); text-decoration: none; }

/* ----- Форма (последние матчи) ----- */
.col-form { text-align: left; }
.form-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.7em;
  height: 1.7em;
  margin-right: 3px;
  border-radius: 8px;
  font-size: var(--fs-xs);
  font-weight: 800;
  color: #fff;
  background: var(--c-muted);
  box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.12);
}
.form-win, .form-ot_win { background: var(--c-success); }
.form-draw, .form-ot_loss { background: var(--c-warning); }
.form-loss { background: var(--c-danger); }

/* ----- Список матчей (карточки) ----- */
.match-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--sp-2);
}
@media (min-width: 768px) {
  .match-list { grid-template-columns: 1fr 1fr; gap: var(--sp-3); }
}
.match-card {
  display: grid;
  gap: var(--sp-1);
  padding: var(--sp-3) var(--sp-3) var(--sp-3) calc(var(--sp-3) + 3px);
  border: 1px solid var(--c-border);
  border-left: 4px solid var(--c-border-2);
  border-radius: var(--r-md);
  background: var(--c-surface);
  color: inherit;
  text-decoration: none;
  transition: box-shadow var(--dur) var(--ease), transform var(--dur) var(--ease),
    border-color var(--dur) var(--ease);
}
.status-scheduled { border-left-color: var(--c-info); }
.status-post { border-left-color: var(--c-success); }
.match-card:hover {
  box-shadow: var(--shadow-2);
  transform: translateY(-2px);
  border-color: var(--c-border-2);
  text-decoration: none;
}
.mc-date { font-size: var(--fs-xs); color: var(--c-muted); font-weight: 700; }
.mc-body {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: var(--sp-2);
}
.mc-team { font-weight: 700; font-size: var(--fs-sm); }
.mc-home { text-align: right; }
.mc-away { text-align: left; }
.mc-score {
  font-weight: 900;
  font-size: var(--fs-md);
  font-variant-numeric: tabular-nums;
  padding: 3px var(--sp-3);
  border-radius: var(--r-sm);
  background: var(--c-surface-2);
}
.status-scheduled .mc-score { color: var(--c-muted); font-size: var(--fs-sm); }
.mc-tour { font-size: var(--fs-xs); color: var(--c-muted); }

/* ----- Календарь: компактные строки матчей (мобильный скролл) ----- */
.cal-panel .panel-head { margin-bottom: var(--sp-2); }
.cal-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.cal-item + .cal-item { border-top: 1px solid var(--c-border); }
.cal-row {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  min-height: 46px;
  padding: 0 var(--sp-2);
  border-radius: var(--r-sm);
  color: inherit;
  text-decoration: none;
  transition: background var(--dur) var(--ease);
}
.cal-row:hover { background: var(--c-surface-2); text-decoration: none; }
.cal-side {
  flex: 1 1 0;
  min-width: 0;
  font-size: var(--fs-sm);
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cal-home { text-align: right; }
.cal-away { text-align: left; }
.cal-score {
  flex: 0 0 auto;
  min-width: 3.4ch;
  text-align: center;
  font-weight: 900;
  font-size: var(--fs-sm);
  font-variant-numeric: tabular-nums;
}
.cal-row.status-scheduled .cal-score { color: var(--c-muted); }
.cal-date {
  flex: 0 0 auto;
  font-size: var(--fs-xs);
  color: var(--c-muted);
  font-weight: 700;
}

/* ----- Уведомление на странице матча («результат ожидается») ----- */
.panel.notice {
  border-left: 4px solid var(--c-primary);
  background: var(--c-surface-2);
}
.panel.notice p {
  margin: 0;
  font-size: var(--fs-sm);
  line-height: 1.5;
}

/* Легенда зон таблицы (из конфига лиги) */
.legend-zones {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2) var(--sp-4);
  margin: var(--sp-3) 0 0;
  padding: 0;
  list-style: none;
}
.lz-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: var(--fs-xs);
  color: var(--c-muted);
}
.lz-dot {
  width: 10px;
  height: 10px;
  border-radius: 3px;
  flex: 0 0 auto;
}
.lz-dot.zone-promotion,
.lz-dot.zone-champions,
.lz-dot.zone-playoff,
.lz-dot.zone-playoffs { background: var(--c-success); }
.lz-dot.zone-europa { background: var(--c-info); }
.lz-dot.zone-relegation { background: var(--c-danger); }
.lz-dot.zone-out { background: var(--c-muted); }
.lz-mark { font-size: 0.9em; }
.lz-mark.up { color: var(--c-success); }
.lz-mark.down { color: var(--c-danger); }

/* Страница тура: место и динамика позиции по итогам тура */
.t-pos {
  display: inline-block;
  min-width: 1.3em;
  margin-right: 2px;
  color: var(--c-muted);
  font-variant-numeric: tabular-nums;
}
.t-delta { font-size: 0.72em; margin-right: 4px; }
.t-delta.up { color: var(--c-success); }
.t-delta.down { color: var(--c-danger); }

/* Главная: подборка бомбардиров */
.scorers-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.scorers-list li {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  padding: var(--sp-2) 0;
  border-bottom: 1px solid var(--c-border);
}
.scorers-list li:last-child { border-bottom: 0; }
.sc-name { display: flex; flex-direction: column; min-width: 0; }
.sc-club { font-size: var(--fs-xs); color: var(--c-muted); }
.sc-goals {
  margin-left: auto;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: var(--c-primary);
}

/* Детали матча: ход матча (таймлайн) */
.timeline { list-style: none; margin: 0; padding: 0; }
.tl-item {
  display: grid;
  grid-template-columns: 3.2rem 1fr;
  gap: var(--sp-2);
  padding: var(--sp-2);
  border-left: 3px solid transparent;
  border-radius: 0 var(--r-sm) var(--r-sm) 0;
}
.tl-item.tl-home { border-left-color: color-mix(in srgb, var(--c-primary) 55%, transparent); }
.tl-item.tl-guest { border-left-color: color-mix(in srgb, var(--c-muted) 55%, transparent); }
.tl-item.tl-goal { background: color-mix(in srgb, var(--c-success) 8%, transparent); }
.tl-min { text-align: right; font-weight: 700; color: var(--c-muted); font-variant-numeric: tabular-nums; font-size: var(--fs-sm); }
.tl-body { min-width: 0; }
.tl-name { font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .04em; color: var(--c-muted); }
.tl-item.tl-goal .tl-name { color: var(--c-success); font-weight: 800; }
.tl-player { display: block; font-weight: 600; }
.tl-arrow { color: var(--c-muted); }

/* Детали матча: составы */
.lineups { display: grid; gap: var(--sp-5); }
@media (min-width: 640px) { .lineups { grid-template-columns: 1fr 1fr; } }
.lu-team { min-width: 0; }
.lu-title { margin: 0 0 var(--sp-1); font-size: var(--fs-md); }
.lu-coach { margin: 0 0 var(--sp-2); font-size: var(--fs-xs); color: var(--c-muted); }
.lu-label { margin: var(--sp-3) 0 var(--sp-1); font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .06em; color: var(--c-muted); font-weight: 800; }
.lu-list { list-style: none; margin: 0; padding: 0; }
.lu-player { display: grid; grid-template-columns: 2rem 1fr auto; gap: var(--sp-2); align-items: baseline; padding: 5px 0; border-bottom: 1px solid var(--c-border); }
.lu-num { text-align: center; color: var(--c-muted); font-variant-numeric: tabular-nums; font-size: var(--fs-xs); }
.lu-name { min-width: 0; }
.lu-cap { display: inline-block; font-size: .68em; background: var(--c-primary-soft); color: var(--c-primary); border-radius: 4px; padding: 0 4px; font-weight: 800; }
.lu-post { font-size: var(--fs-xs); color: var(--c-muted); white-space: nowrap; }

/* Детали матча: статистика */
.stats { list-style: none; margin: 0; padding: 0; }
.st-row { display: grid; grid-template-columns: 2.4rem 1fr 2.4rem; align-items: center; gap: var(--sp-2); padding: var(--sp-1) 0; }
.st-side { text-align: center; font-weight: 800; font-variant-numeric: tabular-nums; }
.st-mid { min-width: 0; }
.st-name { display: block; font-size: var(--fs-xs); color: var(--c-muted); text-align: center; margin-bottom: 4px; }
.st-bar { display: block; height: 7px; border-radius: var(--r-pill); background: var(--c-surface-3); overflow: hidden; }
.st-bar > i { display: block; height: 100%; background: var(--grad-brand); border-radius: var(--r-pill); }

/* Страница игрока */
.player-head { margin-bottom: var(--sp-3); }
.player-name { margin: 0 0 var(--sp-1); }
.player-meta { margin: 0; color: var(--c-muted); }
.player-meta a { color: var(--c-primary); font-weight: 700; }
.player-totals { display: flex; flex-wrap: wrap; gap: var(--sp-3); list-style: none; margin: 0; padding: 0; }
.player-totals li { flex: 1 1 5rem; background: var(--c-surface-2); border: 1px solid var(--c-border); border-radius: var(--r-md); padding: var(--sp-3); text-align: center; }
.player-totals strong { display: block; font-size: 1.5rem; font-variant-numeric: tabular-nums; }
.player-totals span { font-size: var(--fs-xs); color: var(--c-muted); }
.player-src { margin-top: var(--sp-3); }
.player-links { margin: var(--sp-2) 0 0; }
.player-bio {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(8rem, 1fr));
  gap: var(--sp-2);
  margin: var(--sp-3) 0 0;
  padding: 0;
}
.player-bio > div {
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--r-md);
  padding: var(--sp-2) var(--sp-3);
}
.player-bio dt { margin: 0; font-size: var(--fs-xs); color: var(--c-muted); }
.player-bio dd { margin: 2px 0 0; font-weight: 700; font-variant-numeric: tabular-nums; }
.cmp-team { text-align: left; white-space: nowrap; }

/* ----- Автовыводы ----- */
.insights {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: var(--sp-3);
}
.insights li {
  position: relative;
  padding-left: var(--sp-5);
  line-height: 1.5;
}
.insights li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.5em;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--grad-brand);
}

/* ----- Рекорды/цифры: ряд числовых плиток (тур, команда) ----- */
.stat-grid {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
  margin: 0 0 var(--sp-3);
  padding: 0;
}
.stat-grid li {
  flex: 1 1 6.5rem;
  padding: var(--sp-3);
  text-align: center;
  border-radius: var(--r-md);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
}
.stat-grid strong { display: block; font-size: var(--fs-xl); font-variant-numeric: tabular-nums; line-height: 1.1; }
.stat-grid span { font-size: var(--fs-xs); color: var(--c-muted); }

/* ----- Легенда ----- */
.legend {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--sp-1);
  margin-top: var(--sp-3);
  font-size: var(--fs-sm);
  color: var(--c-muted);
}

/* ----- Поделиться ----- */
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  min-height: var(--touch);
  padding: 0 var(--sp-4);
  border: 1px solid var(--c-border-2);
  border-radius: var(--r-md);
  background: var(--c-surface);
  color: var(--c-text-2);
  font-size: var(--fs-sm);
  font-weight: 800;
}
.share-btn:hover { border-color: var(--c-primary); color: var(--c-primary); }
.share-btn .ico svg { width: 18px; height: 18px; display: block; }

/* ============================================================
   Герой (главная) — эмоция из данных, без внешних ассетов.
   ============================================================ */
.hero {
  position: relative;
  overflow: hidden;
  border-radius: var(--r-2xl);
  padding: var(--sp-6) var(--sp-4) var(--sp-5);
  margin-bottom: var(--sp-5);
  color: #fff;
  background: var(--grad-hero);
  box-shadow: var(--shadow-2);
}
.hero::after {
  content: "";
  position: absolute;
  right: -20%;
  top: -55%;
  width: 72%;
  height: 175%;
  z-index: 0;
  background: radial-gradient(closest-side, rgba(255, 255, 255, 0.22), transparent 70%);
  pointer-events: none;
}
@media (min-width: 768px) {
  .hero { padding: var(--sp-7) var(--sp-6); }
}
/* Орнамент (локальный ассет: детерминированный или векторный ИИ) — за текстом. */
.hero-deco {
  position: absolute;
  inset: 0;
  z-index: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}
/* Со скримом (для фонового арта ИИ): гарантируем контраст текста. */
.hero--media::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(100deg,
    rgba(7, 13, 31, 0.92) 0%,
    rgba(29, 78, 216, 0.72) 52%,
    rgba(8, 145, 178, 0.46) 100%);
  pointer-events: none;
}
.hero > *:not(.hero-deco) { position: relative; z-index: 2; }
.hero-kicker {
  margin: 0 0 var(--sp-2);
  font-size: var(--fs-xs);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  opacity: 0.88;
}
.hero-title {
  margin: 0 0 var(--sp-3);
  font-size: var(--fs-hero);
  font-weight: 900;
  line-height: 1.03;
  letter-spacing: -0.035em;
  color: #fff;
}
.hero-title span { color: rgba(255, 255, 255, 0.66); }
.hero-sub {
  margin: 0;
  max-width: 46ch;
  font-size: var(--fs-sm);
  opacity: 0.92;
}
.hero-stats {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
  margin: var(--sp-4) 0 0;
  padding: 0;
}
.hero-stats li {
  display: flex;
  flex-direction: column;
  min-width: 92px;
  padding: var(--sp-2) var(--sp-3);
  border-radius: var(--r-md);
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.hero-stats strong { font-size: var(--fs-xl); line-height: 1.08; }
.hero-stats span { font-size: var(--fs-xs); opacity: 0.9; }
.hero-cta { display: flex; flex-wrap: wrap; gap: var(--sp-2); margin-top: var(--sp-4); }
.hero-cta .btn {
  background-image: none;
  background-color: #fff;
  color: #0b1220;
  border-color: #fff;
  box-shadow: none;
}
.hero-cta .btn:hover { filter: none; background-color: #eaf1ff; border-color: #eaf1ff; color: #0b1220; }
.hero-cta .btn-ghost { background-color: transparent; color: #fff; border-color: rgba(255, 255, 255, 0.6); }
.hero-cta .btn-ghost:hover { background-color: rgba(255, 255, 255, 0.14); color: #fff; border-color: #fff; }

/* ============================================================
   Превью тура + карточки несыгранных матчей (из данных).
   ============================================================ */
.tour-preview {
  border: 1px solid var(--c-border);
  border-radius: var(--r-xl);
  background: var(--c-surface);
  box-shadow: var(--shadow-1);
  padding: var(--sp-4);
  margin-bottom: var(--sp-4);
}
.tp-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--sp-2);
  flex-wrap: wrap;
  margin-bottom: var(--sp-2);
}
.tp-title { margin: 0; font-size: var(--fs-xl); }
.tp-when {
  font-size: var(--fs-sm);
  font-weight: 800;
  color: var(--c-primary);
  background: var(--c-primary-soft);
  padding: 3px var(--sp-3);
  border-radius: var(--r-pill);
  white-space: nowrap;
}
.tp-lead { margin: 0 0 var(--sp-3); color: var(--c-text-2); font-size: var(--fs-sm); }
.tp-narrative {
  margin: 0 0 var(--sp-3);
  padding: var(--sp-3) var(--sp-4);
  border-left: 3px solid var(--c-primary);
  border-radius: 0 var(--r-md) var(--r-md) 0;
  background: var(--c-surface-2);
  color: var(--c-text-2);
  font-size: var(--fs-sm);
  line-height: 1.58;
}
.tp-narrative p { margin: 0 0 var(--sp-2); }
.tp-narrative p:last-child { margin-bottom: 0; }
.tp-lead-label {
  display: inline-block;
  margin-right: var(--sp-2);
  padding: 2px var(--sp-2);
  border-radius: var(--r-sm);
  font-size: var(--fs-xs);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #fff;
  background: var(--grad-accent);
}
.pv-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-2); }
@media (min-width: 768px) {
  .pv-list { grid-template-columns: 1fr 1fr; gap: var(--sp-3); }
}
.pv-card {
  border: 1px solid var(--c-border);
  border-radius: var(--r-lg);
  background: var(--c-surface);
  transition: box-shadow var(--dur) var(--ease), transform var(--dur) var(--ease),
    border-color var(--dur) var(--ease);
}
.pv-card:hover { box-shadow: var(--shadow-2); transform: translateY(-2px); border-color: var(--c-border-2); }
.pv-featured { border-color: transparent; box-shadow: inset 0 0 0 2px var(--c-accent); }
.pv-link { display: block; padding: var(--sp-3); color: inherit; }
.pv-link:hover { text-decoration: none; }
.pv-top { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-2); margin-bottom: var(--sp-2); }
.pv-date { font-size: var(--fs-xs); color: var(--c-muted); font-weight: 700; }
.pv-flag {
  padding: 3px var(--sp-2);
  border-radius: var(--r-sm);
  font-size: var(--fs-xs);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #fff;
  background: var(--grad-accent);
}
.pv-teams { display: grid; gap: var(--sp-1); }
.pv-row { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: var(--sp-2); }
.pv-pos { min-width: 2.4em; font-size: var(--fs-xs); font-weight: 800; color: var(--c-muted); font-variant-numeric: tabular-nums; }
.pv-name { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pv-pts { display: none; font-size: var(--fs-xs); color: var(--c-muted); font-weight: 700; }
.pv-form { display: inline-flex; gap: 2px; }
.pv-stakes { list-style: none; margin: var(--sp-2) 0 0; padding: 0; display: grid; gap: 3px; }
.pv-stakes li {
  position: relative;
  padding-left: var(--sp-4);
  font-size: var(--fs-xs);
  color: var(--c-text-2);
  line-height: 1.45;
}
.pv-stakes li::before {
  content: "";
  position: absolute;
  left: 3px;
  top: 0.5em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--c-primary);
}
.tp-all { display: inline-block; margin-top: var(--sp-3); }
@media (min-width: 420px) {
  .pv-row { grid-template-columns: auto 1fr auto auto; }
  .pv-pts { display: inline; }
}

/* ============================================================
   Страница матча
   ============================================================ */
/* Шапка матча: два «лого» (монограммы) и счёт. Растровый баннер убран — экономнее. */
.match-head {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: var(--sp-2) var(--sp-3);
  text-align: center;
  padding: var(--sp-4) var(--sp-3);
  border-radius: var(--r-lg);
  margin-bottom: var(--sp-3);
  background:
    radial-gradient(130% 120% at 50% 0%, color-mix(in srgb, var(--c-primary) 14%, transparent), transparent 72%),
    var(--c-surface-2);
}
.match-head .mh-team {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-2);
  color: var(--c-text);
  font-weight: 800;
  line-height: 1.2;
  text-decoration: none;
}
.match-head .mh-team:hover { color: var(--c-primary); text-decoration: none; }
.match-head .mh-logo { display: block; width: clamp(52px, 17vw, 84px); aspect-ratio: 1; }
.match-head .mh-logo svg,
.match-head .mh-logo img { display: block; width: 100%; height: 100%; object-fit: contain; }
.match-head .mh-name { font-size: var(--fs-sm); overflow-wrap: anywhere; }
@media (min-width: 480px) {
  .match-head .mh-name { font-size: var(--fs-md); }
}
.match-head .mh-score {
  align-self: center;
  font-size: var(--fs-2xl);
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  padding: var(--sp-1) var(--sp-3);
  border-radius: var(--r-md);
  background: var(--c-surface);
  box-shadow: var(--shadow-1);
}
.live-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-1);
  margin: 0 0 var(--sp-2);
  padding: 3px var(--sp-3);
  border-radius: var(--r-pill);
  background: color-mix(in srgb, var(--c-accent) 14%, transparent);
  color: var(--c-accent);
  font-size: var(--fs-sm);
  font-weight: 700;
}
.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--c-accent);
  animation: live-pulse 1.6s ease-in-out infinite;
}
@keyframes live-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.7); }
}
@media (prefers-reduced-motion: reduce) {
  .live-dot { animation: none; }
}
.match-narrative-head { font-size: var(--fs-lg); margin: 0 0 var(--sp-2); color: var(--c-text); }
.match-narrative {
  margin: 0 0 var(--sp-3);
  padding-left: var(--sp-3);
  border-left: 3px solid var(--c-accent);
  color: var(--c-text-2);
  line-height: 1.62;
}
.match-narrative p { margin: 0 0 var(--sp-2); }
.match-narrative p:last-child { margin-bottom: 0; }
.preview-cta { margin: var(--sp-4) 0 0; }
.form-row { display: flex; align-items: center; flex-wrap: wrap; gap: var(--sp-1); margin-bottom: var(--sp-2); }
.form-row .fr-name { font-weight: 800; margin-right: var(--sp-2); }

/* ============================================================
   Страница команды
   ============================================================ */
.team-head { display: flex; align-items: center; gap: var(--sp-4); }
.team-mark {
  flex: 0 0 auto;
  width: 68px;
  height: 68px;
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--shadow-1);
}
.team-mark svg,
.team-mark img { display: block; width: 100%; height: 100%; object-fit: contain; }
.team-info { min-width: 0; }
.team-name { margin: 0 0 var(--sp-1); font-size: var(--fs-xl); }
.team-mark-note { margin: var(--sp-1) 0 0; font-size: var(--fs-xs); color: var(--c-muted); }

/* Состав команды */
.squad-list { list-style: none; margin: 0 0 var(--sp-2); padding: 0; display: grid; gap: 2px; }
@media (min-width: 640px) {
  .squad-list { grid-template-columns: 1fr 1fr; column-gap: var(--sp-5); }
}
.squad-item {
  display: grid;
  grid-template-columns: 2.4em 1fr auto;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-1) 0;
  border-bottom: 1px solid var(--c-border);
  font-size: var(--fs-sm);
}
.squad-num { font-weight: 800; color: var(--c-muted); font-variant-numeric: tabular-nums; text-align: center; }
.squad-name { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.squad-birth { color: var(--c-muted); font-size: var(--fs-xs); font-variant-numeric: tabular-nums; }

/* ============================================================
   Поиск и симулятор
   ============================================================ */
.search, .search-mini { display: flex; gap: var(--sp-2); align-items: center; }
.search input[type="search"],
.search-mini input[type="search"] {
  min-height: var(--touch);
  padding: 0 var(--sp-3);
  border: 1px solid var(--c-border-2);
  border-radius: var(--r-md);
  background: var(--c-surface);
  color: var(--c-text);
  font-size: var(--fs-sm);
  transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.search input[type="search"]:focus,
.search-mini input[type="search"]:focus {
  outline: none;
  border-color: var(--c-primary);
  box-shadow: var(--shadow-focus);
}
.search input[type="search"] { flex: 1 1 auto; }
.search-mini { order: 3; flex: 0 1 auto; margin-left: auto; }
.search-mini input[type="search"] { width: 150px; }
@media (max-width: 720px) { .search-mini { display: none; } }
.league-chips { order: 2; }
.brand { order: 1; }

.sim { margin: 0; }
.sim-row { display: flex; flex-wrap: wrap; gap: var(--sp-2); margin-bottom: var(--sp-3); }
.sim-row select {
  flex: 1 1 140px;
  min-height: var(--touch);
  padding: 0 var(--sp-2);
  border: 1px solid var(--c-border-2);
  border-radius: var(--r-md);
  background: var(--c-surface);
  color: var(--c-text);
  font-size: var(--fs-sm);
}
.sim-result { margin-top: var(--sp-3); }
.standings tr.is-sim td { background: var(--c-primary-soft); font-weight: 800; }

/* ============================================================
   Мобильная полировка (90% трафика — телефон)
   ============================================================ */
@media (max-width: 767px) {
  .export-row .btn,
  .hero-cta .btn { flex: 1 1 100%; }
  .standings th,
  .standings td { padding: var(--sp-2) var(--sp-2); }
  .form-badge { min-width: 1.75em; height: 1.75em; }
  .insights li { padding-left: var(--sp-6); }
  .btn { font-size: var(--fs-md); }
  .panel { border-radius: var(--r-lg); }
}

/* ============================================================
   Страница матча: сравнение команд, последние матчи, FAQ
   ============================================================ */
.cmp {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: var(--fs-sm);
}
.cmp th,
.cmp td {
  padding: var(--sp-2) var(--sp-3);
  text-align: center;
  white-space: nowrap;
  border-bottom: 1px solid var(--c-border);
}
.cmp thead th {
  background: var(--c-thead);
  color: var(--c-thead-text);
  font-weight: 800;
  font-size: var(--fs-xs);
  border-bottom: 0;
}
.cmp thead th:first-child { border-top-left-radius: var(--r-lg); }
.cmp thead th:last-child { border-top-right-radius: var(--r-lg); }
.cmp tbody tr:last-child th,
.cmp tbody tr:last-child td { border-bottom: 0; }
.cmp tbody tr:nth-child(even) th,
.cmp tbody tr:nth-child(even) td { background: var(--c-surface-2); }
.cmp .cmp-label {
  text-align: left;
  color: var(--c-text-2);
  font-weight: 700;
  white-space: normal;
}
.cmp thead .cmp-label { color: var(--c-thead-text); }
.cmp td.is-better { font-weight: 800; color: var(--c-success); }
@media (min-width: 768px) {
  .cmp { font-size: var(--fs-md); }
}

.recent { display: grid; gap: var(--sp-3); }
@media (min-width: 640px) {
  .recent { grid-template-columns: 1fr 1fr; gap: var(--sp-4); }
}
.recent-col { min-width: 0; }
.recent-team { font-size: var(--fs-md); margin: 0 0 var(--sp-2); }
.recent-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.recent-item {
  display: grid;
  grid-template-columns: auto 1fr auto auto;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-1) 0;
  border-bottom: 1px solid var(--c-border);
  font-size: var(--fs-sm);
}
.recent-list > .recent-item:last-child { border-bottom: 0; }
.recent-item .ri-tour {
  color: var(--c-muted);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.recent-item .ri-opp { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.recent-item .ri-score { font-weight: 800; font-variant-numeric: tabular-nums; }

.faq { margin: 0; }
.faq-item {
  padding: var(--sp-3) 0;
  border-bottom: 1px solid var(--c-border);
}
.faq-item:first-child { padding-top: 0; }
.faq-item:last-child { padding-bottom: 0; border-bottom: 0; }
.faq dt { font-weight: 800; margin-bottom: var(--sp-1); }
.faq dd { margin: 0; color: var(--c-text-2); }

/* ----- Блок «Модель матча» ----- */
.model-xg {
  list-style: none;
  margin: 0 0 var(--sp-3);
  padding: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sp-2);
}
.model-xg li {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--sp-2);
  padding: var(--sp-3);
  border-radius: var(--r-md);
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
}
.model-xg span {
  min-width: 0;
  font-size: var(--fs-sm);
  color: var(--c-text-2);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.model-xg strong { font-size: var(--fs-2xl); line-height: 1; font-variant-numeric: tabular-nums; }
@media (max-width: 480px) {
  .model-xg { grid-template-columns: 1fr; }
}
.model-prob {
  display: grid;
  gap: var(--sp-3);
  margin: var(--sp-4) 0;
  padding: var(--sp-4);
  border-radius: var(--r-md);
  background: var(--c-surface-2);
}
.mp-row {
  display: grid;
  grid-template-columns: 6.5em 1fr auto;
  align-items: center;
  gap: var(--sp-3);
  font-size: var(--fs-sm);
}
.mp-label { color: var(--c-text-2); font-weight: 700; }
.mp-bar {
  display: block;
  height: 13px;
  border-radius: var(--r-pill);
  background: var(--c-surface-3);
  overflow: hidden;
}
.mp-bar i { display: block; height: 100%; border-radius: var(--r-pill); background: var(--grad-brand); }
.mp-val { min-width: 3.2em; text-align: right; font-weight: 800; font-variant-numeric: tabular-nums; }
.model-note { margin: 0 0 var(--sp-2); font-size: var(--fs-sm); color: var(--c-text-2); }
.model-disclaimer {
  margin: var(--sp-3) 0 0;
  padding-top: var(--sp-3);
  border-top: 1px solid var(--c-border);
  font-size: var(--fs-xs);
  color: var(--c-muted);
}
@media (max-width: 767px) {
  .mp-row { grid-template-columns: 5.5em 1fr auto; gap: var(--sp-2); font-size: var(--fs-xs); }
}

/* ----- График «Динамика позиции» ----- */
.pt-wrap { width: 100%; }
.pt-chart { display: block; width: 100%; height: 160px; }
.pt-grid { stroke: var(--c-border); stroke-width: 1; stroke-dasharray: 3 3; }
.pt-line { stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.pt-line.pt-a { stroke: var(--c-primary); }
.pt-line.pt-b { stroke: var(--c-accent); }
.pt-dot.pt-a { fill: var(--c-primary); }
.pt-dot.pt-b { fill: var(--c-accent); }
.pt-legend {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--sp-1) var(--sp-3);
  margin: var(--sp-2) 0 0;
  font-size: var(--fs-sm);
  color: var(--c-text-2);
}
.pt-key { display: inline-block; width: 14px; height: 4px; border-radius: 2px; margin-right: 6px; vertical-align: middle; }
.pt-key.pt-a { background: var(--c-primary); }
.pt-key.pt-b { background: var(--c-accent); }
