/**
 * sportWTF - Main Stylesheet
 * Color concept: light grey bg, medium grey, black, blue accent
 * Mobile-first, responsive
 */

/* ========== CSS Variables ========== */
/*
 * THEME (бренд): чтобы сменить основной цвет сайта — меняй только эти три переменные.
 * Можно сказать ассистенту: "сделай в стиле Real Madrid" / "основной цвет как у Барсы" —
 * он подставит нужную палитру из SPORTWTF_CONTEXT.md → раздел "Тема и цвет".
 */
:root {
  /* Основной акцент (кнопки, активный таб, ссылки, линии). Сейчас: тёмно-синий (премиальный) */
  --sportwtf-accent: #003366;
  --sportwtf-accent-hover: #002244;
  /* Фон секций и hero — сливочный; основной фон страницы остаётся белым (--sportwtf-bg) */
  --sportwtf-bg-subtle: #faf6f0;

  --sportwtf-bg: #FFFFFF;
  --sportwtf-bg-panel: #FFFFFF;
  --sportwtf-grey: #6B6B6B;
  --sportwtf-grey-light: #9CA3AF;
  --sportwtf-black: #262626;
  /* Используй акцент везде вместо жёсткого синего */
  --sportwtf-blue: var(--sportwtf-accent);
  --sportwtf-blue-hover: var(--sportwtf-accent-hover);
  --sportwtf-border: #E5E5E5;
  --sportwtf-live: #22C55E;
  --sportwtf-live-bg: rgba(34, 197, 94, 0.1);
}

/* ========== Reset & Base ========== */
*, *::before, *::after {
  box-sizing: border-box;
}

.sportwtf-wrapper {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  color: var(--sportwtf-black);
  background: var(--sportwtf-bg);
  min-height: 100vh;
}

/* ========== Header ========== */
.sportwtf-header {
  background: #FFFFFF;
  padding: 1rem 1.25rem;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 1px 0 rgba(0,0,0,0.08);
}

.sportwtf-header-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.sportwtf-logo-link {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-decoration: none;
  color: inherit;
}

.sportwtf-logo-img {
  height: 40px;
  width: auto;
  max-width: 160px;
  object-fit: contain;
}

.sportwtf-tagline {
  display: block;
  margin-top: 0.25rem;
  color: var(--sportwtf-grey);
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Nav — отступ от лого, выравнивание по центру по высоте лого */
.sportwtf-nav {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  align-self: center;
}

.sportwtf-nav-links {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.sportwtf-nav-links > a,
.sportwtf-nav-item {
  color: var(--sportwtf-black);
  text-decoration: none;
  font-size: 0.9rem;
  padding: 0.4rem 0.75rem;
  border-radius: 4px;
  transition: color 0.2s;
}

.sportwtf-nav-links > a:hover,
.sportwtf-nav-trigger:hover {
  color: var(--sportwtf-grey);
}

.sportwtf-nav-item {
  position: relative;
  display: inline-block;
}

.sportwtf-nav-trigger {
  display: inline-block;
  color: inherit;
  text-decoration: none;
  padding: 0.4rem 0.75rem;
  border-radius: 4px;
}

/* Dropdown — по умолчанию скрыт */
.sportwtf-nav-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  margin-top: 2px;
  padding: 0.5rem 0;
  background: #fff;
  border: 1px solid var(--sportwtf-border);
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  z-index: 200;
  display: none;
  max-height: 70vh;
  overflow-y: auto;
}

.sportwtf-nav-dropdown a,
.sportwtf-nav-dropdown-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  color: var(--sportwtf-black);
  text-decoration: none;
  font-size: 0.88rem;
  white-space: nowrap;
  transition: background 0.15s, color 0.15s;
}

.sportwtf-nav-dropdown a:hover,
.sportwtf-nav-dropdown-item:hover {
  background: var(--sportwtf-bg-subtle);
  color: var(--sportwtf-accent);
}

.sportwtf-nav-dropdown-logo {
  width: 20px;
  height: 20px;
  object-fit: contain;
  flex-shrink: 0;
}

.sportwtf-nav-dropdown-label {
  flex: 1;
  min-width: 0;
}

/* Подменю «Прогнозы»: две строки (заголовок + пояснение) */
.sportwtf-nav-dropdown--stacked .sportwtf-nav-dropdown-item {
  flex-direction: column;
  align-items: flex-start;
  gap: 0.15rem;
  white-space: normal;
}

.sportwtf-nav-dropdown-hint {
  font-size: 0.75rem;
  color: var(--sportwtf-grey);
  font-weight: 400;
  line-height: 1.25;
  max-width: 280px;
}

/* Десктоп: показ по hover */
@media (min-width: 901px) {
  .sportwtf-header-inner .sportwtf-nav {
    margin-left: 1.5rem;
  }
  .sportwtf-nav-burger {
    display: none;
  }
  .sportwtf-nav-item:hover .sportwtf-nav-dropdown {
    display: block;
  }
}

/* Мобилка: показ по клику (.is-open) */
@media (max-width: 900px) {
  .sportwtf-header-inner {
    flex-wrap: nowrap;
  }
  .sportwtf-nav {
    margin-left: auto;
  }
  .sportwtf-nav-links {
    display: none;
  }
  .sportwtf-nav-burger {
    display: inline-flex !important;
  }
  .sportwtf-nav-trigger::after {
    content: '';
    display: inline-block;
    margin-left: 0.35rem;
    border: 5px solid transparent;
    border-top-color: currentColor;
    vertical-align: 0.2em;
  }
  .sportwtf-nav-item.is-open .sportwtf-nav-trigger::after {
    border-top-color: transparent;
    border-bottom-color: currentColor;
    vertical-align: -0.1em;
  }
  .sportwtf-nav-item.is-open .sportwtf-nav-dropdown {
    display: block;
  }
  .sportwtf-nav-dropdown {
    left: 0;
    right: auto;
    min-width: 200px;
    max-height: 60vh;
  }
}

/* Burger button */
.sportwtf-nav-burger {
  display: none;
  width: 40px;
  height: 32px;
  border: 0;
  padding: 0;
  margin: 0;
  background: transparent;
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.sportwtf-nav-burger-line {
  width: 22px;
  height: 2px;
  background: var(--sportwtf-black);
  border-radius: 999px;
  transition: transform 0.2s, opacity 0.2s, background-color 0.2s;
}

.sportwtf-nav-burger.is-open .sportwtf-nav-burger-line:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.sportwtf-nav-burger.is-open .sportwtf-nav-burger-line:nth-child(2) {
  opacity: 0;
}
.sportwtf-nav-burger.is-open .sportwtf-nav-burger-line:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.sportwtf-no-scroll {
  overflow: hidden;
}

/* Mobile full-screen menu */
.sportwtf-mobile-menu {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.75);
  z-index: 150;
  display: none;
}

.sportwtf-mobile-menu.is-open {
  display: block;
}

.sportwtf-mobile-menu-inner {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 80%;
  max-width: 360px;
  background: #ffffff;
  padding: 1rem 1.25rem 2rem;
  box-shadow: -4px 0 16px rgba(0, 0, 0, 0.25);
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  overflow-y: auto;
}

.sportwtf-mobile-menu-close {
  position: absolute;
  top: 0.9rem;
  right: 1rem;
  width: 28px;
  height: 28px;
  border: 0;
  padding: 0;
  background: transparent;
  cursor: pointer;
}

.sportwtf-mobile-menu-close span {
  position: absolute;
  left: 4px;
  right: 4px;
  height: 2px;
  background: var(--sportwtf-black);
  border-radius: 999px;
}
.sportwtf-mobile-menu-close span:first-child {
  top: 13px;
  transform: rotate(45deg);
}
.sportwtf-mobile-menu-close span:last-child {
  top: 13px;
  transform: rotate(-45deg);
}

.sportwtf-mobile-menu-section {
  margin-top: 1.5rem;
}

.sportwtf-mobile-menu-section-title {
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--sportwtf-grey);
  margin-bottom: 0.75rem;
}

.sportwtf-mobile-menu-leagues {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.sportwtf-mobile-league {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.4rem 0.1rem;
  text-decoration: none;
  color: var(--sportwtf-black);
  border-radius: 6px;
}

.sportwtf-mobile-league-logo {
  width: 24px;
  height: 24px;
  object-fit: contain;
}

.sportwtf-mobile-league-label {
  font-size: 0.95rem;
}

.sportwtf-mobile-menu-section-secondary {
  margin-top: 1rem;
  border-top: 1px solid var(--sportwtf-border);
  padding-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.sportwtf-mobile-menu-link {
  text-decoration: none;
  color: var(--sportwtf-black);
  font-size: 0.95rem;
}


/* ========== Main Content ========== */
.sportwtf-main {
  max-width: 1100px;
  margin: 0 auto;
  padding: 1.5rem 1.25rem;
  line-height: 1.6;
}

/* Section titles */
.sportwtf-section-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--sportwtf-black);
  margin: 0 0 1rem 0;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--sportwtf-blue);
}

/* Заголовок блока матчей + переключатель «Прогнозы» */
.sportwtf-fixtures-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  margin: 0 0 1rem 0;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--sportwtf-blue);
}

.sportwtf-fixtures-head .sportwtf-section-title {
  flex: 1 1 12rem;
  min-width: 0;
  margin: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.sportwtf-pred-toggle {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.sportwtf-pred-toggle-control {
  display: inline-flex;
  align-items: center;
  cursor: pointer;
  margin: 0;
}

.sportwtf-pred-toggle-input {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
  opacity: 0;
}

.sportwtf-pred-toggle-input:focus-visible + .sportwtf-pred-toggle-track {
  outline: 2px solid var(--sportwtf-accent, #003366);
  outline-offset: 2px;
}

.sportwtf-pred-toggle-track {
  display: inline-block;
  width: 2.75rem;
  height: 1.5rem;
  border-radius: 999px;
  background: #d1d5db;
  position: relative;
  flex-shrink: 0;
  transition: background 0.2s ease;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.08);
}

.sportwtf-pred-toggle-thumb {
  position: absolute;
  width: 1.25rem;
  height: 1.25rem;
  border-radius: 50%;
  background: #fff;
  top: 0.125rem;
  left: 0.125rem;
  transition: transform 0.2s ease;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.sportwtf-fixtures.sportwtf-predictions-on .sportwtf-pred-toggle-track {
  background: #6b7280;
}

.sportwtf-fixtures.sportwtf-predictions-on .sportwtf-pred-toggle-thumb {
  transform: translateX(1.25rem);
}

.sportwtf-pred-toggle-caption {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--sportwtf-grey, #6b7280);
  white-space: nowrap;
}

.sportwtf-fixtures.sportwtf-predictions-off .sportwtf-pred-card,
.sportwtf-fixtures.sportwtf-predictions-off .sportwtf-match--with-prediction .sportwtf-pred-card {
  display: none !important;
}

/* ========== Matches Hero ========== */
.sportwtf-matches-hero {
  margin-bottom: 1.5rem;
}

.sportwtf-hero-title {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--sportwtf-black);
  margin: 0 0 0.5rem 0;
  line-height: 1.3;
}

.sportwtf-hero-desc {
  font-size: 0.95rem;
  color: var(--sportwtf-grey);
  margin: 0;
  max-width: 42rem;
  line-height: 1.5;
}

/* ========== Date Tabs (Championat-style) ========== */
.sportwtf-date-tabs {
  background: var(--sportwtf-bg-subtle);
  padding: 1rem;
  border-radius: 12px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid var(--sportwtf-border);
}

.sportwtf-tab {
  display: inline-block;
  padding: 0.5rem 1rem;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--sportwtf-grey);
  text-decoration: none;
  border-radius: 6px;
  transition: color 0.2s, background 0.2s;
}

.sportwtf-tab:hover {
  color: var(--sportwtf-black);
  background: var(--sportwtf-border);
}

.sportwtf-tab-active {
  color: #fff;
  background: var(--sportwtf-blue);
}

.sportwtf-tab-active:hover {
  color: #fff;
  background: var(--sportwtf-blue-hover);
}

.sportwtf-date-picker-wrap {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.25rem;
  min-height: 44px;
  min-width: 180px;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  cursor: pointer;
  position: relative;
}

/* Input скрыт в блоке (0 размер), но остаётся в разметке — showPicker() на десктопе так работает */
.sportwtf-date-picker-input-offscreen {
  position: absolute;
  left: 0;
  top: 0;
  width: 1px;
  height: 1px;
  opacity: 0;
  margin: 0;
  padding: 0;
  border: none;
  pointer-events: none;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  z-index: -1;
}

/* Кнопка = вся область календаря (иконка + дата), без вида кнопки */
.sportwtf-date-picker-btn-wrap {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  min-height: 44px;
  padding: 0.25rem 0.5rem;
  cursor: pointer;
  background: none;
  border: none;
  border-radius: 6px;
  font: inherit;
  color: inherit;
  margin: 0;
  width: 100%;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}
.sportwtf-date-picker-btn-wrap:hover {
  background: var(--sportwtf-border);
}
.sportwtf-date-picker-btn-wrap:focus {
  outline: 2px solid var(--sportwtf-blue);
  outline-offset: 2px;
}

.sportwtf-date-picker-display {
  font-size: 0.9rem;
  padding: 0.2rem 0;
}

.sportwtf-calendar-label {
  font-size: 1.25rem;
  padding: 0.25rem;
  min-width: 36px;
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  touch-action: manipulation;
}

/* Кнопка «открыть календарь» (главная) — без рамки, как иконка */
.sportwtf-calendar-btn {
  cursor: pointer;
  font-size: 1.25rem;
  padding: 0.5rem;
  min-width: 44px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  background: none;
  border: none;
  color: inherit;
  margin: 0;
  border-radius: 6px;
}
.sportwtf-calendar-btn:hover {
  background: var(--sportwtf-border);
}
.sportwtf-calendar-btn:focus {
  outline: 2px solid var(--sportwtf-blue);
  outline-offset: 2px;
}

.sportwtf-date-picker {
  padding: 0.4rem 0.6rem;
  font-size: 0.9rem;
  border: 1px solid var(--sportwtf-border);
  border-radius: 6px;
  background: #fff;
  min-height: 44px;
  touch-action: manipulation;
}

.sportwtf-fixtures-wrap {
  margin-top: 0.5rem;
}

/* ========== Fixtures ========== */
.sportwtf-fixtures {
  margin-bottom: 2rem;
}

.sportwtf-league {
  background: var(--sportwtf-bg-panel);
  border-radius: 14px;
  margin-bottom: 1.25rem;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0,0,0,0.06);
}

.sportwtf-league-header {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  background: var(--sportwtf-bg-subtle);
  color: var(--sportwtf-black);
  font-size: 1rem;
  font-weight: 700;
}

.sportwtf-league-header-main {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
  flex: 1 1 auto;
  flex-wrap: wrap;
}

.sportwtf-league-logo {
  flex-shrink: 0;
  border-radius: 4px;
}

.sportwtf-league-name {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sportwtf-league-header-link {
  color: inherit;
  text-decoration: none;
}

.sportwtf-league-header-link:hover {
  text-decoration: underline;
}

.sportwtf-matches {
  list-style: none;
  margin: 0;
  padding: 0;
}

.sportwtf-match {
  border-bottom: 1px solid var(--sportwtf-border);
  padding: 0;
}

.sportwtf-match:last-child {
  border-bottom: none;
}

/* Строка матча + карточка вероятностей (товарищеские, данные из JSON) */
.sportwtf-match--with-prediction {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  gap: 0;
  flex-wrap: nowrap;
}

.sportwtf-match--with-prediction .sportwtf-match-link {
  flex: 1 1 auto;
  min-width: 0;
}

/* Строка матча + кнопка Claude (аналитика) без блока % — тот же flex */
.sportwtf-match--with-claude {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  gap: 0;
  flex-wrap: nowrap;
}

.sportwtf-match--with-claude .sportwtf-match-link {
  flex: 1 1 auto;
  min-width: 0;
}

/* Карточка Claude — та же сетка, что sportwtf-pred-card (две строки + узкая колонка); текст прогноза только в dialog */
.sportwtf-claude-insight-card {
  flex: 0 0 auto;
  display: flex;
  flex-direction: row;
  align-items: stretch;
  margin: 0.5rem 0.75rem 0.5rem 0;
  padding: 0;
  min-width: 200px;
  max-width: 260px;
  background: #fff;
  border: 1px solid var(--sportwtf-border);
  border-radius: 10px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  cursor: pointer;
  text-align: left;
  font: inherit;
  color: inherit;
  align-self: center;
  overflow: hidden;
  transition: box-shadow 0.15s ease, border-color 0.15s ease;
}

.sportwtf-claude-insight-card:hover,
.sportwtf-claude-insight-card:focus-visible {
  border-color: rgba(126, 58, 237, 0.35);
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.08);
  outline: none;
}

.sportwtf-claude-insight-card-main {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0.45rem 0.65rem;
  border-right: 1px solid var(--sportwtf-border);
  min-width: 0;
}

.sportwtf-claude-insight-card-row {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 0.35rem;
  padding: 0.15rem 0;
}

.sportwtf-claude-insight-card-row + .sportwtf-claude-insight-card-row {
  border-top: 1px solid #e8e8e8;
  margin-top: 0.2rem;
  padding-top: 0.35rem;
}

.sportwtf-claude-insight-card-cell {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.35rem;
  min-width: 0;
}

.sportwtf-claude-insight-card-cell--left {
  flex: 1 1 auto;
}

.sportwtf-claude-insight-card-cell--pct {
  flex-shrink: 0;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--sportwtf-black);
}

.sportwtf-claude-insight-card-ico {
  display: flex;
  flex-shrink: 0;
}

.sportwtf-claude-insight-card-ico img {
  width: 20px;
  height: 20px;
  border-radius: 5px;
  display: block;
}

.sportwtf-claude-insight-card-abbr {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--sportwtf-black);
}

.sportwtf-claude-insight-card-side {
  flex: 0 0 4.25rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0.35rem 0.45rem;
  background: #fafafa;
}

.sportwtf-claude-insight-card-side-label {
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--sportwtf-grey);
  margin-bottom: 0.15rem;
}

.sportwtf-claude-insight-card-side-cta {
  font-size: 0.95rem;
  font-weight: 700;
  color: #5b21b6;
  line-height: 1;
}

.sportwtf-claude-dialog {
  max-width: min(36rem, calc(100vw - 2rem));
  width: 100%;
  padding: 0;
  border: 1px solid var(--sportwtf-border);
  border-radius: 12px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
  background: #fffdf9;
}

.sportwtf-claude-dialog::backdrop {
  background: rgba(15, 15, 25, 0.45);
}

.sportwtf-claude-dialog-header {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--sportwtf-border);
  background: #faf8f4;
}

.sportwtf-claude-dialog-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
}

.sportwtf-claude-dialog-x {
  border: none;
  background: transparent;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  color: var(--sportwtf-grey);
  padding: 0.15rem 0.35rem;
  border-radius: 4px;
}

.sportwtf-claude-dialog-x:hover {
  background: #eee;
  color: var(--sportwtf-black);
}

.sportwtf-claude-dialog-meta {
  margin: 0;
  padding: 0.5rem 1rem 0;
  font-size: 0.85rem;
  color: var(--sportwtf-grey);
}

.sportwtf-claude-dialog-text {
  margin: 0;
  padding: 0.65rem 1rem 1rem;
  font-size: 0.88rem;
  line-height: 1.45;
  max-height: min(70vh, 32rem);
  overflow: auto;
  color: var(--sportwtf-black);
}

.sportwtf-claude-disclaimer {
  margin: 0;
  padding: 0 1rem 1rem;
  font-size: 0.75rem;
  color: var(--sportwtf-grey);
  line-height: 1.35;
}

.sportwtf-pred-card {
  flex: 0 0 auto;
  display: flex;
  flex-direction: row;
  align-items: stretch;
  background: #fff;
  border: 1px solid var(--sportwtf-border);
  border-radius: 10px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  min-width: 200px;
  max-width: 260px;
  margin: 0.5rem 0.75rem 0.5rem 0;
  overflow: hidden;
}

.sportwtf-pred-card--with-model-strip {
  flex-direction: column;
  align-items: stretch;
}

.sportwtf-pred-card-inner {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  flex: 1 1 auto;
  min-height: 0;
}

.sportwtf-pred-card-model-strip {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.28rem 0.5rem;
  background: rgba(255, 255, 255, 0.85);
  border-bottom: 1px solid var(--sportwtf-border);
  flex-shrink: 0;
}

.sportwtf-pred-card-model-strip-img {
  display: block;
  width: 18px;
  height: 18px;
  border-radius: 4px;
  flex-shrink: 0;
}

.sportwtf-pred-card-model-strip-text {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--sportwtf-grey);
  white-space: nowrap;
}

.sportwtf-pred-card.sportwtf-claude-pct-open {
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.sportwtf-pred-card.sportwtf-claude-pct-open:hover,
.sportwtf-pred-card.sportwtf-claude-pct-open:focus-visible {
  border-color: rgba(126, 58, 237, 0.35);
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.08);
  outline: none;
}

.sportwtf-pred-card--claude-pct .sportwtf-pred-card-draw {
  background: linear-gradient(180deg, #faf8ff 0%, #fafafa 100%);
}

.sportwtf-pred-card--link,
.sportwtf-claude-insight-card--link {
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}

.sportwtf-pred-card--link:hover,
.sportwtf-pred-card--link:focus-visible,
.sportwtf-claude-insight-card--link:hover,
.sportwtf-claude-insight-card--link:focus-visible {
  border-color: rgba(126, 58, 237, 0.35);
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.08);
  outline: none;
}

.sportwtf-article-layout--prediction {
  max-width: 48rem;
  margin: 0 auto;
}

.sportwtf-article-layout--prediction:has(.sportwtf-predictions-hub-page) {
  max-width: 56rem;
  margin: 0 auto;
}

.sportwtf-article-layout--prediction:has(.sportwtf-prediction-article-page) {
  max-width: 56rem;
  margin: 0 auto;
}

.sportwtf-prediction-page-lead {
  margin-bottom: 1rem;
}

.sportwtf-prediction-disclaimer {
  margin: 0;
  font-size: 0.85rem;
  color: var(--sportwtf-grey);
  line-height: 1.4;
}

.sportwtf-prediction-pct {
  margin: 1rem 0;
  padding: 1rem 1.1rem;
  background: linear-gradient(180deg, #faf8ff 0%, #fff 100%);
  border-radius: 10px;
  border: 1px solid var(--sportwtf-border);
}

.sportwtf-prediction-pct-title {
  font-size: 1rem;
  margin: 0 0 0.5rem 0;
}

.sportwtf-prediction-pct-list {
  margin: 0;
  padding-left: 1.25rem;
  line-height: 1.5;
}

.sportwtf-prediction-body {
  margin-top: 0.5rem;
}

.sportwtf-predictions-hub-page .sportwtf-predictions-hub-body {
  margin-top: 0.5rem;
}

.sportwtf-predictions-hub-feed {
  margin-top: 0.25rem;
}

/* Хаб «Прогнозы»: макет как в дизайне — заголовок страницы, строка лига·время + ссылка, две карточки */
.sportwtf-predictions-hub-page.sportwtf-article-page {
  max-width: 56rem;
}

.sportwtf-predictions-compare-section {
  max-width: none;
  margin: 0;
}

.sportwtf-predictions-compare-row {
  margin-bottom: 1.5rem;
  padding-bottom: 1.35rem;
  border-bottom: 1px solid #eeeeee;
}

.sportwtf-predictions-compare-row:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.sportwtf-predictions-compare-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  width: 100%;
  margin-bottom: 0.85rem;
  padding-bottom: 0.65rem;
  border-bottom: 1px solid #eeeeee;
  font-size: 0.8rem;
  color: var(--sportwtf-grey);
}

.sportwtf-predictions-compare-head-start {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 0.75rem;
  min-width: 0;
}

.sportwtf-predictions-compare-league {
  flex-shrink: 0;
}

.sportwtf-predictions-compare-kick {
  color: var(--sportwtf-grey);
  font-size: 0.8rem;
}

.sportwtf-predictions-compare-article {
  flex-shrink: 0;
  margin-left: auto;
  font-weight: 600;
  font-size: 0.82rem;
  color: var(--sportwtf-blue);
  text-decoration: none;
}

.sportwtf-predictions-compare-article:hover {
  text-decoration: underline;
}

/* Две карточки компактной ширины (как макет), не на всю колонку статьи */
.sportwtf-predictions-compare-cards {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: stretch;
  justify-content: flex-start;
  gap: 1rem;
}

.sportwtf-predictions-compare-cards > .sportwtf-pred-card.sportwtf-pred-card--hub-compare {
  box-sizing: border-box;
  flex: 0 0 auto;
  width: min(304px, calc(50% - 0.5rem));
  max-width: 100%;
  min-width: 0;
  margin: 0;
  border: 1px solid #eeeeee;
  border-radius: 9px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
}

.sportwtf-predictions-compare-cards .sportwtf-pred-card--hub-compare .sportwtf-pred-card-model-strip {
  justify-content: center;
  padding: 0.35rem 0.75rem;
  border-bottom-color: #eeeeee;
}

.sportwtf-predictions-compare-cards .sportwtf-pred-card--hub-compare.sportwtf-pred-card--claude-pct .sportwtf-pred-card-model-strip-text {
  color: #ea580c;
}

.sportwtf-predictions-compare-cards .sportwtf-pred-card--hub-compare.sportwtf-pred-card--api-sports-pred .sportwtf-pred-card-model-strip-text {
  color: #6b7280;
}

/* Логотип API Sports в полоске: компактный, в одну линию с подписью (как иконка у Claude) */
.sportwtf-predictions-compare-cards .sportwtf-pred-card-model-strip-img--api-sports {
  width: auto;
  height: 18px;
  max-width: 3.35rem;
  object-fit: contain;
  border-radius: 0;
  flex-shrink: 0;
}

.sportwtf-predictions-compare-cards .sportwtf-pred-card--hub-compare .sportwtf-pred-card-inner {
  min-height: 0;
}

.sportwtf-predictions-compare-cards .sportwtf-pred-card--hub-compare .sportwtf-pred-card-main {
  padding: 0.65rem 1rem 0.65rem 1rem;
  border-right-color: #eeeeee;
}

.sportwtf-predictions-compare-cards .sportwtf-pred-card--hub-compare .sportwtf-pred-card-row + .sportwtf-pred-card-row {
  border-top-color: #eeeeee;
}

/* Колонка ничьей фиксированной ширины — пропорции как на референсе, не «расползание» на широкой карточке */
.sportwtf-predictions-compare-cards .sportwtf-pred-card--hub-compare .sportwtf-pred-card-draw {
  flex: 0 0 5.5rem;
  min-width: 5.25rem;
  max-width: 5.75rem;
  padding: 0.65rem 0.5rem;
  background: #fafafa;
}

.sportwtf-predictions-compare-cards .sportwtf-pred-card--hub-compare .sportwtf-pred-card-row {
  align-items: flex-start;
}

.sportwtf-predictions-compare-cards .sportwtf-pred-card-code--hub-full {
  font-size: 0.85rem;
  font-weight: 600;
  line-height: 1.25;
  white-space: normal;
  word-break: break-word;
  min-width: 0;
}

.sportwtf-predictions-compare-section .sportwtf-pred-card-pct--countup,
.sportwtf-predictions-compare-section .sportwtf-pred-card-draw-pct--countup {
  font-variant-numeric: tabular-nums;
  display: inline-block;
  min-width: 3.25em;
  text-align: right;
  flex-shrink: 0;
}

@media (max-width: 700px) {
  .sportwtf-predictions-compare-cards > .sportwtf-pred-card.sportwtf-pred-card--hub-compare {
    width: 100%;
  }

  .sportwtf-predictions-compare-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .sportwtf-predictions-compare-article {
    margin-left: 0;
  }
}

.sportwtf-predictions-compare-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 118px;
  opacity: 0.92;
}

.sportwtf-predictions-compare-placeholder-inner {
  padding: 0.85rem 1rem;
  text-align: center;
  font-size: 0.82rem;
  color: var(--sportwtf-grey);
  line-height: 1.4;
}

.sportwtf-prediction-match-link {
  margin-top: 1.5rem;
  font-weight: 600;
}

/* Расширенная страница одного ИИ-прогноза (sportwtfPredictionArticlePage) */
.sportwtf-prediction-article-page.sportwtf-article-page {
  max-width: 52rem;
}

.sportwtf-ai-prediction {
  margin-top: 0.25rem;
}

.sportwtf-ai-prediction-disclaimer {
  margin: 0 0 1rem;
  padding: 0.75rem 1rem;
  font-size: 0.82rem;
  color: var(--sportwtf-grey);
  background: #f8fafc;
  border: 1px solid var(--sportwtf-border);
  border-radius: 8px;
  line-height: 1.45;
}

.sportwtf-ai-prediction-warn {
  margin: 0 0 1rem;
  padding: 0.65rem 0.9rem;
  font-size: 0.85rem;
  color: #92400e;
  background: #fffbeb;
  border: 1px solid #fcd34d;
  border-radius: 8px;
}

.sportwtf-ai-prediction-missing {
  margin: 0;
  padding: 0.65rem 0.85rem;
  font-size: 0.88rem;
  color: var(--sportwtf-grey);
  background: #fafafa;
  border: 1px dashed #e5e5e5;
  border-radius: 8px;
}

.sportwtf-ai-prediction-hint {
  margin: 0 0 0.65rem;
  font-size: 0.82rem;
  color: var(--sportwtf-grey);
  line-height: 1.4;
}

.sportwtf-ai-prediction-section-title {
  font-size: 1.05rem;
  font-weight: 700;
  margin: 0 0 0.65rem;
  color: var(--sportwtf-black);
  line-height: 1.25;
}

.sportwtf-ai-prediction-hero {
  margin-bottom: 1.75rem;
}

.sportwtf-ai-prediction-hero-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 1rem 1.15rem;
  align-items: stretch;
}

.sportwtf-ai-prediction-hero-row > * {
  min-width: 0;
}

.sportwtf-ai-prediction-hero-dashboard {
  display: block;
  margin-bottom: 0;
  min-width: 0;
}

.sportwtf-ai-prediction-hero-card {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  padding: 1.15rem 1.25rem 1.2rem;
  margin-bottom: 0;
  height: 100%;
  background: #fff;
  border: 1px solid #e8e8e8;
  border-radius: 12px;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.05);
}

.sportwtf-ai-prediction-hero-card-top {
  margin-bottom: 0.7rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid #eeeeee;
}

.sportwtf-ai-prediction-hero-league,
.sportwtf-ai-prediction-hero-league-link {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;
}

.sportwtf-ai-prediction-hero-league-link {
  color: inherit;
  text-decoration: none;
}

.sportwtf-ai-prediction-hero-league-link:hover .sportwtf-ai-prediction-hero-league-text,
.sportwtf-ai-prediction-hero-league-link:focus-visible .sportwtf-ai-prediction-hero-league-text {
  color: var(--sportwtf-accent);
}

.sportwtf-ai-prediction-hero-league-logo {
  object-fit: contain;
  flex-shrink: 0;
  border-radius: 4px;
}

.sportwtf-ai-prediction-hero-league-text {
  font-size: 0.8rem;
  font-weight: 600;
  color: #374151;
  line-height: 1.3;
}

.sportwtf-ai-prediction-hero-card-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: start;
  gap: 0.5rem 0.75rem;
  padding-bottom: 0.9rem;
}

.sportwtf-ai-prediction-hero-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 0.5rem;
  padding-top: 0.15rem;
  flex-shrink: 0;
}

.sportwtf-ai-prediction-date-pill {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.2rem;
  padding: 0.45rem 0.75rem;
  background: #f3f4f6;
  border-radius: 10px;
  text-align: center;
  min-width: 8rem;
}

.sportwtf-ai-prediction-date-pill--muted {
  opacity: 0.92;
}

.sportwtf-ai-prediction-date-pill-line {
  font-size: 0.72rem;
  font-weight: 600;
  color: #374151;
  line-height: 1.25;
}

.sportwtf-ai-prediction-date-pill-line--time {
  font-size: 0.72rem;
  font-weight: 700;
  color: #111827;
}

.sportwtf-ai-prediction-vs--lg {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #9ca3af;
  line-height: 1;
}

.sportwtf-ai-prediction-hero-card-form {
  margin: 0;
  padding-top: 0.8rem;
  border-top: 1px solid #eeeeee;
}

.sportwtf-ai-prediction-form-section-title {
  margin: 0 0 0.6rem;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #9ca3af;
  text-align: center;
}

.sportwtf-ai-prediction-form-row {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 1.75rem;
}

.sportwtf-ai-prediction-form-side {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.38rem;
  flex-wrap: nowrap;
}

.sportwtf-ai-prediction-form-side--home {
  justify-content: flex-start;
}

.sportwtf-ai-prediction-form-side--away {
  justify-content: flex-end;
}

.sportwtf-ai-prediction-form-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.55rem;
  height: 1.55rem;
  border-radius: 50%;
  font-size: 0.62rem;
  font-weight: 800;
  color: #fff;
  line-height: 1;
  flex-shrink: 0;
}

.sportwtf-ai-prediction-form-chip--win {
  background: #28a745;
}

.sportwtf-ai-prediction-form-chip--draw {
  background: #8e8e93;
}

.sportwtf-ai-prediction-form-chip--loss {
  background: #dc3545;
}

.sportwtf-ai-prediction-form-chip-link {
  position: relative;
  display: inline-flex;
  text-decoration: none;
  color: inherit;
  border-radius: 50%;
  outline: none;
}

.sportwtf-ai-prediction-form-chip-link:hover .sportwtf-ai-prediction-form-chip,
.sportwtf-ai-prediction-form-chip-link:focus-visible .sportwtf-ai-prediction-form-chip {
  box-shadow: 0 0 0 2px rgba(0, 51, 102, 0.35);
}

.sportwtf-ai-prediction-form-pop {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 0.45rem);
  transform: translateX(-50%);
  z-index: 30;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.15s ease, visibility 0.15s ease, transform 0.15s ease;
}

.sportwtf-ai-prediction-form-chip-link:hover .sportwtf-ai-prediction-form-pop,
.sportwtf-ai-prediction-form-chip-link:focus-visible .sportwtf-ai-prediction-form-pop {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(-2px);
}

/* Тултип формы: дата + строка КОД — лого — счёт — лого — КОД */
.sportwtf-ai-prediction-form-pop-inner {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.28rem;
  padding: 0.38rem 0.6rem 0.42rem;
  border: 1px solid #e8e8e8;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  white-space: nowrap;
}

.sportwtf-ai-prediction-form-pop-score-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.12rem;
  flex-shrink: 0;
  min-width: 2.1rem;
}

.sportwtf-ai-prediction-form-pop-date {
  display: block;
  font-size: 0.58rem;
  font-weight: 600;
  color: #6b7280;
  text-align: center;
  line-height: 1.1;
  letter-spacing: 0.01em;
}

.sportwtf-ai-prediction-form-pop-match {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
}

.sportwtf-ai-prediction-form-pop-code {
  font-size: 0.78rem;
  font-weight: 700;
  color: #111827;
  letter-spacing: 0.02em;
  line-height: 1;
}

.sportwtf-ai-prediction-form-pop-logo {
  width: 22px;
  height: 22px;
  object-fit: contain;
  flex-shrink: 0;
}

.sportwtf-ai-prediction-form-pop-score {
  font-size: 0.82rem;
  font-weight: 800;
  color: #111827;
  letter-spacing: 0.04em;
  line-height: 1;
  padding: 0;
}

.sportwtf-ai-prediction-hero-donuts {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 1rem;
  background: #fff;
  border: 1px solid var(--sportwtf-border);
  border-radius: 12px;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.05);
  min-width: 0;
}

.sportwtf-ai-prediction-donut-caption {
  margin: 0 0 0.5rem;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--sportwtf-grey);
  text-align: center;
}

.sportwtf-ai-prediction-donuts .sportwtf-match-prediction-donuts {
  flex-wrap: nowrap;
  gap: 0.5rem;
}

.sportwtf-ai-prediction-hero-donuts .sportwtf-pred-donut--home .sportwtf-pred-donut-arc {
  stroke: #2563eb;
}

.sportwtf-ai-prediction-hero-donuts .sportwtf-pred-donut--away .sportwtf-pred-donut-arc {
  stroke: #7c3aed;
}

.sportwtf-pred-donut--article .sportwtf-pred-donut-pct {
  font-size: 0.72rem;
}

.sportwtf-pred-donut--article .sportwtf-pred-donut-label {
  font-size: 0.62rem;
}

.sportwtf-ai-prediction-team {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.45rem;
  flex: 1 1 0;
  min-width: 0;
  text-align: center;
}

.sportwtf-ai-prediction-team-name {
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.25;
  word-break: break-word;
}

.sportwtf-ai-prediction-team-logo-link {
  display: inline-flex;
  line-height: 0;
  color: inherit;
  text-decoration: none;
}

.sportwtf-ai-prediction-logo {
  object-fit: contain;
  border-radius: 8px;
}

.sportwtf-ai-prediction-vs {
  font-size: 1.1rem;
  font-weight: 800;
  color: #d1d5db;
}

.sportwtf-ai-prediction-pct-wrap {
  display: flex;
  flex-direction: column;
  padding: 1rem 1.15rem 1.15rem;
  background: #fff;
  border: 1px solid var(--sportwtf-border);
  border-radius: 12px;
  box-shadow: 0 1px 6px rgba(0, 0, 0, 0.05);
  height: 100%;
  min-height: 0;
  box-sizing: border-box;
}

.sportwtf-ai-prediction-pct-wrap .sportwtf-ai-prediction-missing {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 6rem;
}

.sportwtf-ai-prediction-section-title--outcome {
  margin-bottom: 0.85rem;
  flex-shrink: 0;
}

.sportwtf-ai-prediction-outcome-assess {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: flex-start;
  gap: 1.35rem 1.75rem;
  flex: 1;
  min-height: 0;
  min-width: 0;
  overflow-x: hidden;
  overflow-y: visible;
}

.sportwtf-ai-prediction-outcome-visual {
  position: relative;
  width: 188px;
  height: 188px;
  flex-shrink: 0;
}

.sportwtf-ai-prediction-outcome-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.35);
  overflow: hidden;
}

.sportwtf-ai-prediction-outcome-ring-svg {
  display: block;
  width: 100%;
  height: 100%;
  shape-rendering: geometricPrecision;
}

.sportwtf-ai-prediction .sportwtf-countup {
  font-variant-numeric: tabular-nums;
}

/* Появление сегментов кольца от центра (концентрически), с лёгкой раскладкой по времени */
.sportwtf-ai-prediction-outcome-ring-svg {
  cursor: pointer;
}

.sportwtf-ai-prediction-outcome-ring-svg .sportwtf-prediction-wedge {
  pointer-events: none;
}

.sportwtf-ai-prediction-outcome-ring-svg .sportwtf-prediction-wedge-scale {
  opacity: 0;
  transform-origin: 0 0;
  transform: scale(0);
  animation: sportwtf-donut-seg-in 0.58s cubic-bezier(0.34, 1.15, 0.64, 1) forwards;
  transition: transform 0.22s cubic-bezier(0.34, 1.15, 0.64, 1);
}

/* Hover: дуга растёт наружу (от центра кольца) + сдвиг по направлению середины сегмента (--wedge-lift-tx/ty в SVG) */
.sportwtf-ai-prediction-outcome-ring-svg .sportwtf-prediction-wedge-scale--lift {
  transform: translate(var(--wedge-lift-tx, 0), var(--wedge-lift-ty, 0)) scale(1.08) !important;
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.15));
}

.sportwtf-ai-prediction-outcome-legend-item[data-wedge] {
  cursor: pointer;
}

.sportwtf-ai-prediction-outcome-ring-svg .sportwtf-prediction-wedge-scale--0 {
  animation-delay: 0.02s;
}

.sportwtf-ai-prediction-outcome-ring-svg .sportwtf-prediction-wedge-scale--1 {
  animation-delay: 0.12s;
}

.sportwtf-ai-prediction-outcome-ring-svg .sportwtf-prediction-wedge-scale--2 {
  animation-delay: 0.22s;
}

@keyframes sportwtf-donut-seg-in {
  from {
    opacity: 0;
    transform: scale(0);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

@media (prefers-reduced-motion: reduce) {
  .sportwtf-ai-prediction-outcome-ring-svg .sportwtf-prediction-wedge-scale {
    animation: none;
    opacity: 1;
    transform: scale(1);
    transition: none;
  }

  .sportwtf-ai-prediction-outcome-ring-svg .sportwtf-prediction-wedge-scale--lift {
    transform: translate(var(--wedge-lift-tx, 0), var(--wedge-lift-ty, 0)) scale(1.05) !important;
    transition: none;
  }

  .sportwtf-ai-prediction-outcome-assess.is-wedge-hover--home .sportwtf-ai-prediction-outcome-legend-item--home,
  .sportwtf-ai-prediction-outcome-assess.is-wedge-hover--draw .sportwtf-ai-prediction-outcome-legend-item--draw,
  .sportwtf-ai-prediction-outcome-assess.is-wedge-hover--away .sportwtf-ai-prediction-outcome-legend-item--away {
    transform: translateX(4px);
    transition: none;
  }
}

.sportwtf-ai-prediction-outcome-hole {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 74%;
  height: 74%;
  background: #fff;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0.35rem 0.4rem;
  box-sizing: border-box;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.04);
}

.sportwtf-ai-prediction-outcome-hole-pct {
  font-size: 1.45rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--sportwtf-black);
  line-height: 1.1;
}

.sportwtf-ai-prediction-outcome-hole-label {
  margin-top: 0.15rem;
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1.35;
  color: #4b5563;
  max-width: 100%;
  text-align: center;
  overflow-wrap: break-word;
  word-wrap: break-word;
  padding: 0 0.2rem;
  box-sizing: border-box;
}

.sportwtf-ai-prediction-outcome-legend {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  justify-content: center;
  flex: 1 1 0;
  align-self: stretch;
  min-width: 0;
  max-width: 100%;
  overflow: visible;
}

.sportwtf-ai-prediction-outcome-legend-item {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: 0.55rem;
  flex-wrap: nowrap;
  min-width: 0;
  max-width: 100%;
  border-radius: 8px;
  padding: 0.25rem 0.4rem;
  margin: -0.25rem -0.4rem;
  transition: transform 0.22s cubic-bezier(0.34, 1.15, 0.64, 1), background-color 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.sportwtf-ai-prediction-outcome-legend-line {
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1.35;
  color: #374151;
  min-width: 0;
  flex: 1 1 auto;
  overflow-wrap: break-word;
  word-wrap: break-word;
}

.sportwtf-ai-prediction-outcome-legend-line strong {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: #1f2937;
}

.sportwtf-ai-prediction-outcome-legend-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 0.28em;
  transition: transform 0.22s cubic-bezier(0.34, 1.15, 0.64, 1), box-shadow 0.2s ease;
}

/* Легенда: строка активной доли «выдвигается» вправо (от кольца), как сегмент наружу */
.sportwtf-ai-prediction-outcome-assess.is-wedge-hover--home .sportwtf-ai-prediction-outcome-legend-item--home,
.sportwtf-ai-prediction-outcome-assess.is-wedge-hover--draw .sportwtf-ai-prediction-outcome-legend-item--draw,
.sportwtf-ai-prediction-outcome-assess.is-wedge-hover--away .sportwtf-ai-prediction-outcome-legend-item--away {
  transform: translateX(7px);
  background: rgba(0, 51, 102, 0.07);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}

.sportwtf-ai-prediction-outcome-assess.is-wedge-hover--home .sportwtf-ai-prediction-outcome-legend-item--home .sportwtf-ai-prediction-outcome-legend-line,
.sportwtf-ai-prediction-outcome-assess.is-wedge-hover--draw .sportwtf-ai-prediction-outcome-legend-item--draw .sportwtf-ai-prediction-outcome-legend-line,
.sportwtf-ai-prediction-outcome-assess.is-wedge-hover--away .sportwtf-ai-prediction-outcome-legend-item--away .sportwtf-ai-prediction-outcome-legend-line {
  color: #111827;
}

.sportwtf-ai-prediction-outcome-assess.is-wedge-hover--home .sportwtf-ai-prediction-outcome-legend-item--home .sportwtf-ai-prediction-outcome-legend-dot,
.sportwtf-ai-prediction-outcome-assess.is-wedge-hover--draw .sportwtf-ai-prediction-outcome-legend-item--draw .sportwtf-ai-prediction-outcome-legend-dot,
.sportwtf-ai-prediction-outcome-assess.is-wedge-hover--away .sportwtf-ai-prediction-outcome-legend-item--away .sportwtf-ai-prediction-outcome-legend-dot {
  transform: scale(1.25);
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.9), 0 1px 4px rgba(0, 0, 0, 0.15);
}

.sportwtf-ai-prediction-outcome-assess.is-wedge-hover--home .sportwtf-ai-prediction-outcome-legend-item:not(.sportwtf-ai-prediction-outcome-legend-item--home),
.sportwtf-ai-prediction-outcome-assess.is-wedge-hover--draw .sportwtf-ai-prediction-outcome-legend-item:not(.sportwtf-ai-prediction-outcome-legend-item--draw),
.sportwtf-ai-prediction-outcome-assess.is-wedge-hover--away .sportwtf-ai-prediction-outcome-legend-item:not(.sportwtf-ai-prediction-outcome-legend-item--away) {
  opacity: 0.52;
}

.sportwtf-ai-prediction-outcome-legend-dot--home {
  background: #1a337e;
}

.sportwtf-ai-prediction-outcome-legend-dot--draw {
  background: #6c757d;
}

.sportwtf-ai-prediction-outcome-legend-dot--away {
  background: #8e7cc3;
}

.sportwtf-ai-prediction-bars {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.sportwtf-ai-prediction-bar-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2.2fr) auto;
  align-items: center;
  gap: 0.5rem 0.75rem;
}

.sportwtf-ai-prediction-bar-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--sportwtf-black);
  min-width: 0;
}

.sportwtf-ai-prediction-bar-track {
  height: 10px;
  background: #e5e7eb;
  border-radius: 6px;
  overflow: hidden;
}

.sportwtf-ai-prediction-bar-fill {
  display: block;
  height: 100%;
  border-radius: 6px;
  min-width: 0;
  transition: width 0.35s ease;
}

.sportwtf-ai-prediction-bar-fill--home {
  background: linear-gradient(90deg, #3b82f6, #2563eb);
}

.sportwtf-ai-prediction-bar-fill--draw {
  background: linear-gradient(90deg, #9ca3af, #6b7280);
}

.sportwtf-ai-prediction-bar-fill--away {
  background: linear-gradient(90deg, #8b5cf6, #7c3aed);
}

.sportwtf-ai-prediction-bar-pct {
  font-size: 0.8rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--sportwtf-black);
  min-width: 3.2em;
  text-align: right;
}

.sportwtf-ai-prediction-section {
  margin-bottom: 1.75rem;
}

.sportwtf-ai-prediction-split {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  gap: 1.25rem 1.5rem;
  margin-bottom: 1.75rem;
  align-items: start;
}

.sportwtf-ai-prediction-body {
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--sportwtf-black);
}

.sportwtf-ai-prediction-body p {
  margin: 0 0 0.85rem;
}

.sportwtf-ai-prediction-body p:last-child {
  margin-bottom: 0;
}

.sportwtf-ai-prediction-body h1,
.sportwtf-ai-prediction-body h2,
.sportwtf-ai-prediction-body h3 {
  margin: 1.15rem 0 0.5rem;
  font-weight: 800;
  line-height: 1.25;
  color: var(--sportwtf-black);
}

.sportwtf-ai-prediction-body h1 {
  font-size: 1.35rem;
}

.sportwtf-ai-prediction-body h2 {
  font-size: 1.12rem;
}

.sportwtf-ai-prediction-body h3 {
  font-size: 1rem;
  font-weight: 700;
}

.sportwtf-ai-prediction-body h1:first-child,
.sportwtf-ai-prediction-body h2:first-child,
.sportwtf-ai-prediction-body h3:first-child {
  margin-top: 0;
}

.sportwtf-ai-prediction-stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr));
  gap: 0.65rem;
}

.sportwtf-ai-prediction-stat-card {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.65rem 0.75rem;
  background: #fff;
  border: 1px solid var(--sportwtf-border);
  border-radius: 10px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
  min-width: 0;
}

.sportwtf-ai-prediction-stat-card-label {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--sportwtf-grey);
}

.sportwtf-ai-prediction-stat-card-sub {
  font-size: 0.72rem;
  color: #6b7280;
  line-height: 1.25;
  word-break: break-word;
}

.sportwtf-ai-prediction-stat-card-value {
  font-size: 1.15rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: var(--sportwtf-black);
  margin-top: 0.1rem;
}

.sportwtf-ai-prediction-standings-box {
  padding: 0.65rem 0.75rem;
  background: #fafafa;
  border: 1px dashed #e5e5e5;
  border-radius: 10px;
}

.sportwtf-ai-prediction-standings-cap {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.75rem;
  margin-bottom: 0.5rem;
}

.sportwtf-ai-prediction-standings-season {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--sportwtf-black);
}

.sportwtf-ai-prediction-standings-hint {
  font-size: 0.7rem;
  color: var(--sportwtf-grey);
}

.sportwtf-ai-prediction-standings-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
}

.sportwtf-ai-prediction-standings-table th,
.sportwtf-ai-prediction-standings-table td {
  padding: 0.35rem 0.45rem;
  text-align: left;
  border-bottom: 1px solid #eee;
}

.sportwtf-ai-prediction-standings-table th {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--sportwtf-grey);
}

.sportwtf-ai-prediction-standings-th-num {
  width: 2rem;
}

.sportwtf-ai-prediction-standings-tr--home td {
  background: rgba(59, 130, 246, 0.08);
}

.sportwtf-ai-prediction-standings-tr--away td {
  background: rgba(139, 92, 246, 0.08);
}

.sportwtf-ai-prediction-segbar {
  display: flex;
  flex-direction: row;
  width: 100%;
  height: 14px;
  border-radius: 8px;
  overflow: hidden;
  background: #e5e7eb;
  margin-bottom: 0.65rem;
}

.sportwtf-ai-prediction-seg {
  display: block;
  min-width: 3px;
  height: 100%;
  transition: width 0.35s ease;
}

.sportwtf-ai-prediction-seg--home {
  background: linear-gradient(90deg, #3b82f6, #2563eb);
}

.sportwtf-ai-prediction-seg--draw {
  background: linear-gradient(90deg, #9ca3af, #6b7280);
}

.sportwtf-ai-prediction-seg--away {
  background: linear-gradient(90deg, #8b5cf6, #7c3aed);
}

.sportwtf-ai-prediction-segbar-legend {
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.82rem;
  line-height: 1.5;
  color: var(--sportwtf-black);
}

.sportwtf-ai-prediction-segbar-legend li {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin-bottom: 0.2rem;
}

.sportwtf-ai-prediction-seg-legend-dot {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 2px;
  flex-shrink: 0;
}

.sportwtf-ai-prediction-seg-legend-dot--home {
  background: #2563eb;
}

.sportwtf-ai-prediction-seg-legend-dot--draw {
  background: #6b7280;
}

.sportwtf-ai-prediction-seg-legend-dot--away {
  background: #7c3aed;
}

.sportwtf-ai-prediction-outcome-lead {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--sportwtf-grey);
}

.sportwtf-ai-prediction-match-link--muted {
  color: var(--sportwtf-grey);
  font-weight: 500;
}

@media (max-width: 768px) {
  .sportwtf-ai-prediction-hero-row {
    grid-template-columns: 1fr;
  }

  .sportwtf-ai-prediction-pct-wrap {
    height: auto;
  }

  .sportwtf-ai-prediction-outcome-assess {
    flex: none;
    flex-direction: column;
    align-items: center;
    text-align: left;
    overflow-x: visible;
  }

  .sportwtf-ai-prediction-outcome-legend {
    align-self: stretch;
    width: 100%;
    min-width: 0;
    overflow: visible;
  }

  .sportwtf-ai-prediction-hero-card {
    padding: 0.85rem 0.85rem 1rem;
  }

  .sportwtf-ai-prediction-hero-card-main {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
    gap: 0.75rem;
  }

  .sportwtf-ai-prediction-team--home {
    order: 1;
  }

  .sportwtf-ai-prediction-hero-center {
    order: 0;
    width: 100%;
  }

  .sportwtf-ai-prediction-team--away {
    order: 2;
  }

  .sportwtf-ai-prediction-form-row {
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
  }

  .sportwtf-ai-prediction-form-side--home,
  .sportwtf-ai-prediction-form-side--away {
    justify-content: center;
  }

  .sportwtf-ai-prediction-outcome-visual {
    width: min(200px, 88vw);
    height: min(200px, 88vw);
  }

  .sportwtf-ai-prediction-bar-row {
    grid-template-columns: 1fr;
    gap: 0.25rem;
  }

  .sportwtf-ai-prediction-bar-pct {
    text-align: left;
  }

  .sportwtf-ai-prediction-split {
    grid-template-columns: 1fr;
  }
}

.sportwtf-pred-card-main {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0.45rem 0.65rem;
  border-right: 1px solid var(--sportwtf-border);
  min-width: 0;
}

.sportwtf-pred-card-row {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 0.35rem;
  padding: 0.15rem 0;
}

.sportwtf-pred-card-row + .sportwtf-pred-card-row {
  border-top: 1px solid #e8e8e8;
  margin-top: 0.2rem;
  padding-top: 0.35rem;
}

.sportwtf-pred-card-team {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.35rem;
  min-width: 0;
}

.sportwtf-pred-card-logo {
  width: 22px;
  height: 22px;
  object-fit: contain;
  border-radius: 50%;
  flex-shrink: 0;
}

.sportwtf-pred-card-code {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--sportwtf-black);
}

.sportwtf-pred-card-pct {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--sportwtf-black);
  flex-shrink: 0;
}

.sportwtf-pred-card-draw {
  flex: 0 0 4.25rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0.35rem 0.45rem;
  background: #fafafa;
}

.sportwtf-pred-card-draw-label {
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--sportwtf-grey);
  margin-bottom: 0.15rem;
}

.sportwtf-pred-card-draw-pct {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--sportwtf-black);
}

.sportwtf-match-link {
  display: block;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: background 0.2s ease;
}

.sportwtf-match-link:hover {
  background: #f3f4f6;
}

.sportwtf-match-teams {
  display: grid;
  grid-template-columns: 1fr auto auto 1fr;
  align-items: center;
  gap: 0.75rem;
  padding: 0.875rem 1rem;
  min-height: 56px;
}

.sportwtf-team {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
}

.sportwtf-team-home {
  justify-content: flex-end;
  text-align: right;
}

.sportwtf-team-away {
  justify-content: flex-start;
  text-align: left;
}

.sportwtf-team img {
  flex-shrink: 0;
}

.sportwtf-team-name {
  white-space: normal;
  overflow: visible;
  text-overflow: unset;
}

.sportwtf-score {
  font-weight: 700;
  font-size: 1rem;
  color: var(--sportwtf-black);
  min-width: 3rem;
  text-align: center;
}

.sportwtf-time {
  font-size: 0.85rem;
  color: var(--sportwtf-grey);
  min-width: 2.5rem;
  text-align: center;
}

.sportwtf-status-badge {
  font-size: 0.7rem;
  padding: 0.2rem 0.4rem;
  border-radius: 4px;
  font-weight: 600;
  text-transform: uppercase;
}

.sportwtf-status-ns .sportwtf-status-badge,
.sportwtf-status-tbd .sportwtf-status-badge {
  display: none;
}

.sportwtf-status-1h .sportwtf-status-badge,
.sportwtf-status-ht .sportwtf-status-badge,
.sportwtf-status-2h .sportwtf-status-badge,
.sportwtf-status-et .sportwtf-status-badge,
.sportwtf-status-p .sportwtf-status-badge {
  background: var(--sportwtf-live-bg);
  color: var(--sportwtf-live);
}

.sportwtf-status-ft .sportwtf-status-badge {
  background: var(--sportwtf-border);
  color: var(--sportwtf-grey);
}

/* Два счёта (хозяева/гости) в одной ячейке на десктопе, с отступами вокруг двоеточия */
.sportwtf-score-home::after {
  content: " : ";
  margin: 0 0.4rem;
  letter-spacing: 0.08em;
}
.sportwtf-score-away {
  margin-left: 0;
}

/* --- Single match page --- */
.sportwtf-match-page {
  max-width: 56rem;
  margin: 0 auto;
}

.sportwtf-match-header {
  background: var(--sportwtf-bg-subtle);
  text-align: center;
  padding: 1.5rem 1rem;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-match-league {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
  color: var(--sportwtf-grey);
}

.sportwtf-match-league-logo {
  flex-shrink: 0;
}

.sportwtf-match-league-link {
  color: inherit;
  text-decoration: none;
}

.sportwtf-match-league-link:hover {
  text-decoration: underline;
}

.sportwtf-match-round {
  margin-left: 0.25rem;
}

.sportwtf-match-datetime,
.sportwtf-match-status {
  margin: 0.25rem 0;
  font-size: 0.95rem;
  color: var(--sportwtf-grey);
}

.sportwtf-match-teams-block {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 1rem;
  margin-top: 1.5rem;
}

.sportwtf-match-team {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.sportwtf-match-team-logo {
  display: block;
}

.sportwtf-match-team-name {
  font-weight: 700;
  font-size: 1rem;
  text-align: center;
}

.sportwtf-match-score-block {
  min-width: 4rem;
  text-align: center;
}

.sportwtf-match-score,
.sportwtf-match-vs {
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--sportwtf-black);
}

.sportwtf-match-details {
  padding: 1rem;
  font-size: 0.9rem;
  color: var(--sportwtf-grey);
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-match-venue,
.sportwtf-match-referee {
  margin: 0.35rem 0;
}

/* Блок прогноза на странице матча (перед таблицей; тумблер как на главной) */
.sportwtf-match-prediction-section {
  padding: 1rem;
  border-bottom: 1px solid var(--sportwtf-border);
  background: var(--sportwtf-bg-subtle, #faf6f0);
}

.sportwtf-match-prediction-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  margin: 0 0 0.75rem 0;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--sportwtf-blue);
}

.sportwtf-match-prediction-head .sportwtf-match-section-title {
  flex: 1 1 12rem;
  min-width: 0;
  margin: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.sportwtf-match-prediction-section.sportwtf-match-predictions-off .sportwtf-match-prediction-body {
  display: none !important;
}

.sportwtf-match-prediction-section.sportwtf-match-predictions-on .sportwtf-pred-toggle-track {
  background: #6b7280;
}

.sportwtf-match-prediction-section.sportwtf-match-predictions-on .sportwtf-pred-toggle-thumb {
  transform: translateX(1.25rem);
}

.sportwtf-match-prediction-body {
  padding-top: 0.25rem;
}

.sportwtf-match-prediction-lead {
  margin: 0 0 0.75rem;
  font-size: 0.88rem;
  color: var(--sportwtf-grey, #6b7280);
  line-height: 1.45;
}

/* Карточка + кольца вероятностей (П1 / X / П2) */
.sportwtf-match-prediction-card-wrap .sportwtf-match-prediction-card-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 1rem 1.35rem;
}

.sportwtf-match-prediction-card-wrap .sportwtf-pred-card--match-page {
  max-width: 22rem;
  flex: 0 1 auto;
  margin: 0;
}

.sportwtf-match-prediction-card-wrap .sportwtf-pred-card-pct--countup,
.sportwtf-match-prediction-card-wrap .sportwtf-pred-card-draw-pct--countup {
  font-variant-numeric: tabular-nums;
  display: inline-block;
  min-width: 3.25em;
  text-align: right;
}

.sportwtf-match-prediction-donuts {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 0.75rem 1rem;
  flex: 1 1 14rem;
  justify-content: flex-start;
  min-width: 0;
}

.sportwtf-pred-donut {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  width: 4.6rem;
}

.sportwtf-pred-donut-svg {
  width: 72px;
  height: 72px;
  display: block;
}

.sportwtf-pred-donut-track {
  stroke: #e5e7eb;
}

.sportwtf-pred-donut-arc {
  stroke-dasharray: var(--donut-c);
  stroke-dashoffset: var(--donut-c);
  animation: sportwtfPredDonutFill 0.95s ease-out forwards;
}

.sportwtf-pred-donut--home .sportwtf-pred-donut-arc {
  stroke: var(--sportwtf-accent, #003366);
}

.sportwtf-pred-donut--draw .sportwtf-pred-donut-arc {
  stroke: #6b7280;
}

.sportwtf-pred-donut--away .sportwtf-pred-donut-arc {
  stroke: #0f766e;
}

@keyframes sportwtfPredDonutFill {
  to {
    stroke-dashoffset: var(--donut-off);
  }
}

@media (prefers-reduced-motion: reduce) {
  .sportwtf-pred-donut-arc {
    animation: none !important;
    stroke-dashoffset: var(--donut-off) !important;
  }
}

.sportwtf-pred-donut-pct {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--sportwtf-black);
  line-height: 1.2;
}

.sportwtf-pred-donut-label {
  font-size: 0.65rem;
  font-weight: 600;
  color: var(--sportwtf-grey, #6b7280);
  letter-spacing: 0.04em;
}

@media (max-width: 520px) {
  .sportwtf-match-prediction-donuts {
    justify-content: center;
    width: 100%;
  }
}

.sportwtf-match-prediction-extras {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--sportwtf-border);
  font-size: 0.9rem;
}

.sportwtf-match-prediction-advice {
  margin: 0 0 0.75rem;
  padding: 0.65rem 0.75rem;
  background: #fff;
  border-radius: 8px;
  border: 1px solid var(--sportwtf-border);
  line-height: 1.5;
  color: var(--sportwtf-black);
}

.sportwtf-match-prediction-dl {
  margin: 0 0 0.75rem;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.35rem 1rem;
  align-items: baseline;
}

.sportwtf-match-prediction-dl dt {
  margin: 0;
  font-weight: 600;
  color: var(--sportwtf-grey, #6b7280);
}

.sportwtf-match-prediction-dl dd {
  margin: 0;
}

.sportwtf-match-prediction-comp-wrap {
  margin-top: 0.5rem;
}

.sportwtf-match-prediction-comp-title {
  margin: 0 0 0.5rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--sportwtf-grey, #6b7280);
}

.sportwtf-match-prediction-comp-table {
  width: 100%;
  max-width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--sportwtf-border);
}

.sportwtf-match-prediction-comp-table th,
.sportwtf-match-prediction-comp-table td {
  padding: 0.45rem 0.5rem;
  text-align: left;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-match-prediction-comp-table th {
  background: #f3f4f6;
  font-weight: 600;
}

.sportwtf-match-prediction-comp-table tbody tr:last-child td {
  border-bottom: none;
}

.sportwtf-match-prediction-comp-table td:nth-child(2),
.sportwtf-match-prediction-comp-table td:nth-child(3) {
  text-align: center;
}

/* Form circles under team (green=win, yellow=draw, red=loss) */
.sportwtf-match-form {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  margin-top: 0.35rem;
}

.sportwtf-form-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.sportwtf-form-win {
  background: #22c55e;
}

.sportwtf-form-draw {
  background: #eab308;
}

.sportwtf-form-loss {
  background: #ef4444;
}

/* Section titles */
.sportwtf-match-section-title {
  font-size: 1.1rem;
  margin: 1rem 0 0.75rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--sportwtf-border);
}

/* Match events — compact timeline (Голы + Наказания) */
.sportwtf-match-events-section {
  padding: 1rem;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-match-events-section .sportwtf-match-section-title {
  margin-top: 0.5rem;
}

.sportwtf-match-events-section .sportwtf-match-section-title:first-child {
  margin-top: 0;
}

.sportwtf-timeline {
  list-style: none;
  margin: 0 0 0.5rem;
  padding: 0;
  font-size: 0.9rem;
}

/* Одна строка = три ячейки (left, center, right), flex без grid */
.sportwtf-timeline-goals .sportwtf-timeline-goal,
.sportwtf-timeline-cards .sportwtf-timeline-card {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-timeline-goals .sportwtf-timeline-goal:last-child,
.sportwtf-timeline-cards .sportwtf-timeline-card:last-child {
  border-bottom: none;
}

.sportwtf-timeline-cell {
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
}

.sportwtf-timeline-cell-center {
  flex: 0 0 auto;
  align-items: center;
}

.sportwtf-timeline-cell-left {
  flex: 1 1 0;
}

.sportwtf-timeline-cell-right {
  flex: 1 1 0;
  align-items: flex-end;
  text-align: right;
}

.sportwtf-timeline-cell-right .sportwtf-timeline-player,
.sportwtf-timeline-cell-right .sportwtf-timeline-assist,
.sportwtf-timeline-cell-right .sportwtf-timeline-min {
  text-align: right;
}

.sportwtf-timeline-score {
  background: var(--sportwtf-border);
  color: var(--sportwtf-black);
  font-weight: 700;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  font-size: 0.9rem;
}

.sportwtf-timeline-min {
  color: var(--sportwtf-grey);
  font-weight: 600;
  font-size: 0.85rem;
}

.sportwtf-timeline-player {
  font-weight: 500;
}

.sportwtf-timeline-assist {
  font-size: 0.8rem;
  color: var(--sportwtf-grey);
  margin-top: 0.1rem;
}

.sportwtf-timeline-card-icon {
  width: 12px;
  height: 14px;
  border-radius: 2px;
  flex-shrink: 0;
}

.sportwtf-card-yellow {
  background: #eab308;
}

.sportwtf-card-red {
  background: #dc2626;
}

/* Live match statistics */
.sportwtf-match-stats-section {
  padding: 1rem;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-match-stats-grid {
  display: block;
}

.sportwtf-stat-teams-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
}

.sportwtf-stat-team-name {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--sportwtf-black);
}

.sportwtf-stat-team-name-home {
  text-align: left;
}

.sportwtf-stat-team-name-away {
  text-align: right;
}

.sportwtf-match-stats-bars {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.sportwtf-stat-row {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.sportwtf-stat-row-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.85rem;
}

.sportwtf-stat-label {
  flex: 1 1 auto;
  text-align: center;
  color: var(--sportwtf-grey);
  padding: 0 0.5rem;
}

.sportwtf-stat-value {
  width: 2.75rem;
  text-align: center;
  font-weight: 600;
  color: var(--sportwtf-black);
}

.sportwtf-stat-bar {
  position: relative;
  display: flex;
  height: 6px;
  border-radius: 999px;
  overflow: hidden;
  background: var(--sportwtf-border);
}

.sportwtf-stat-bar-home {
  height: 100%;
  background: #787881;
}

.sportwtf-stat-bar-away {
  height: 100%;
  background: #c3c3c3;
}

/* Lineups */
.sportwtf-match-lineups-section {
  padding: 1rem;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-match-lineups-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.sportwtf-match-lineup-team-name {
  font-size: 1rem;
  font-weight: 700;
  margin: 0 0 0.5rem;
}

.sportwtf-lineup-row {
  font-size: 0.9rem;
  padding: 0.35rem 0;
  border-bottom: 1px solid var(--sportwtf-border);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.sportwtf-lineup-photo {
  width: 32px;
  height: 32px;
  object-fit: cover;
  border-radius: 50%;
  flex-shrink: 0;
}

.sportwtf-lineup-num {
  display: inline-block;
  min-width: 1.5rem;
  color: var(--sportwtf-grey);
}

.sportwtf-lineup-pos {
  display: inline-block;
  min-width: 2rem;
  color: var(--sportwtf-grey);
  font-size: 0.85rem;
}

.sportwtf-lineup-subtitle {
  font-weight: 600;
  margin: 0.75rem 0 0.35rem;
  font-size: 0.9rem;
}

.sportwtf-match-coach {
  margin: 0.75rem 0 0;
  font-size: 0.9rem;
}

/* Lineups pitch view (formation on field) */
.sportwtf-lineups-pitch-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

@media (max-width: 640px) {
  .sportwtf-lineups-pitch-wrap {
    grid-template-columns: 1fr;
  }
}

.sportwtf-pitch-team {
  display: flex;
  flex-direction: column;
  align-items: center;
  perspective: 800px;
}

.sportwtf-pitch-team-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  font-weight: 700;
  font-size: 0.95rem;
  width: 100%;
  max-width: 400px;
}

.sportwtf-pitch-team-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: inherit;
  text-decoration: none;
}

.sportwtf-pitch-team-link:hover {
  color: var(--sportwtf-blue);
}

.sportwtf-pitch-player-link {
  display: block;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: color 0.2s;
}
.sportwtf-pitch-player-link:hover .sportwtf-pitch-name-wrap,
.sportwtf-pitch-player-link:hover .sportwtf-pitch-name {
  color: var(--sportwtf-blue);
}
.sportwtf-pitch-player-link:hover .sportwtf-pitch-name {
  text-decoration: underline;
}

.sportwtf-pitch-team-logo {
  width: 28px;
  height: 28px;
  object-fit: contain;
}

.sportwtf-pitch-formation {
  margin-left: auto;
  font-size: 0.85rem;
  color: var(--sportwtf-grey);
  font-weight: 600;
}

.sportwtf-pitch {
  position: relative;
  width: 100%;
  max-width: 400px;
  margin: 0 auto;
  aspect-ratio: 68 / 105;
  background: #2e8b3a;
  border-radius: 4px;
  overflow: hidden;
  box-shadow:
    0 6px 20px rgba(0, 0, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  transform: rotateX(14deg);
  transform-style: preserve-3d;
  transform-origin: center bottom;
}

.sportwtf-pitch-emblem {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 0;
  pointer-events: none;
}

.sportwtf-pitch-emblem img {
  width: 38%;
  height: auto;
  max-height: 50%;
  object-fit: contain;
  opacity: 0.14;
  mix-blend-mode: multiply;
}

.sportwtf-pitch-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
}

.sportwtf-pitch-player-wrap {
  position: absolute;
  transform: translate(-50%, -50%);
  z-index: 2;
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 1px;
}

.sportwtf-pitch-player {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  padding: 2px 3px;
  background: transparent;
  border-radius: 5px;
  min-width: 0;
  max-width: 72px;
}

.sportwtf-pitch-player-top {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 2px;
}

.sportwtf-pitch-badges {
  display: flex;
  align-items: center;
  gap: 2px;
  flex-shrink: 0;
}

.sportwtf-pitch-photo-wrap {
  flex-shrink: 0;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  overflow: hidden;
  background: transparent;
  border: 1px solid rgba(0, 0, 0, 0.3);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.sportwtf-pitch-photo {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 50%;
  display: block;
  background: transparent;
}

@media (max-width: 640px) {
  .sportwtf-pitch-photo-wrap,
  .sportwtf-pitch-photo {
    width: 60px !important;
    height: 60px !important;
  }
}

.sportwtf-pitch-name-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  max-width: 90px;
  min-width: 0;
  padding: 0 4px 0 0;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 2px;
}

.sportwtf-pitch-num {
  display: inline-block;
  min-width: 18px;
  padding: 0 3px;
  background: rgba(255, 255, 255, 0.45);
  border-radius: 2px;
  font-size: 0.7rem;
  font-weight: 700;
  text-align: center;
}

.sportwtf-pitch-name {
  font-size: 0.7rem;
  font-weight: 500;
  color: #111;
  text-align: center;
  display: inline-block;
  white-space: nowrap;
  line-height: 1.15;
  padding: 0 2px;
  background: transparent;
  border-radius: 0;
}

.sportwtf-pitch-badge {
  display: inline-block;
  font-size: 0.55rem;
  font-weight: 700;
  min-width: 12px;
  height: 10px;
  line-height: 10px;
  text-align: center;
  border-radius: 1px;
  flex-shrink: 0;
}

.sportwtf-pitch-badge-goals {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  background: rgba(255, 255, 255, 0.9);
  color: #111;
  padding: 0 3px;
}

.sportwtf-pitch-ball-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
}

.sportwtf-pitch-ball-icon svg {
  display: block;
}

.sportwtf-pitch-badge-card {
  width: 8px;
  height: 14px;
  background: #eab308;
  border-radius: 1px;
}

/* Последние игры (форма + список матчей по каждой команде) */
.sportwtf-match-lastgames-section {
  padding: 1rem;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-match-lastgames-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

@media (max-width: 640px) {
  .sportwtf-match-lastgames-grid {
    grid-template-columns: 1fr;
  }
}

.sportwtf-match-lastgames-team-name {
  font-size: 0.95rem;
  font-weight: 600;
  margin: 0 0 0.5rem 0;
  color: var(--sportwtf-grey);
}

.sportwtf-match-lastgames-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.sportwtf-match-lastgames-item {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.35rem;
  padding: 0.55rem 0;
  border-bottom: 1px solid rgba(0,0,0,0.06);
  font-size: 0.875rem;
}

.sportwtf-match-lastgames-item:last-child {
  border-bottom: none;
}

/* Строка 1: дата · турнир */
.sportwtf-match-lastgames-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.25rem 0.35rem;
  font-size: 0.8rem;
  line-height: 1.3;
}

.sportwtf-match-lastgames-meta-sep {
  color: var(--sportwtf-grey);
  opacity: 0.7;
  user-select: none;
}

.sportwtf-match-lastgames-date {
  white-space: nowrap;
  color: var(--sportwtf-grey);
}

.sportwtf-match-lastgames-league-wrap {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  color: var(--sportwtf-grey);
  font-size: 0.8rem;
  min-width: 0;
}

.sportwtf-match-lastgames-league-icon {
  flex-shrink: 0;
  object-fit: contain;
  vertical-align: middle;
}

.sportwtf-match-lastgames-league {
  color: var(--sportwtf-grey);
  font-size: 0.8rem;
}

/* Строка 2: бейдж + эмблемы + счёт (вид «матча») */
.sportwtf-match-lastgames-fixture {
  min-width: 0;
}

.sportwtf-match-lastgames-fixture-link {
  display: flex;
  align-items: center;
  gap: 0.4rem 0.5rem;
  width: 100%;
  min-width: 0;
  text-decoration: none;
  color: inherit;
  box-sizing: border-box;
}

a.sportwtf-match-lastgames-fixture-link:hover .sportwtf-match-lastgames-club-name {
  color: var(--sportwtf-blue);
}

.sportwtf-match-lastgames-fixture-link--nohref {
  cursor: default;
}

.sportwtf-match-lastgames-pair {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  min-width: 0;
}

.sportwtf-match-lastgames-pair--home {
  flex: 1 1 0;
  justify-content: flex-end;
}

.sportwtf-match-lastgames-pair--away {
  flex: 1 1 0;
  justify-content: flex-start;
}

.sportwtf-match-lastgames-club-logo {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  object-fit: contain;
}

.sportwtf-match-lastgames-club-name {
  font-size: 0.82rem;
  font-weight: 500;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.sportwtf-match-lastgames-score {
  flex-shrink: 0;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  font-size: 0.9rem;
  white-space: nowrap;
  padding: 0 0.15rem;
}

@media (max-width: 400px) {
  .sportwtf-match-lastgames-pair--home .sportwtf-match-lastgames-club-name,
  .sportwtf-match-lastgames-pair--away .sportwtf-match-lastgames-club-name {
    max-width: 6.5rem;
  }
}

/* H2H — последние очные встречи */
.sportwtf-match-h2h-section {
  padding: 1rem;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-match-h2h-wrap {
  overflow-x: auto;
}

.sportwtf-match-h2h-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.sportwtf-match-h2h-table th,
.sportwtf-match-h2h-table td {
  padding: 0.5rem 0.75rem;
  text-align: left;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-match-h2h-table th {
  font-weight: 600;
  color: var(--sportwtf-grey);
}

.sportwtf-match-h2h-date {
  white-space: nowrap;
  width: 6rem;
}

.sportwtf-match-h2h-score {
  text-align: center;
  font-weight: 600;
}

.sportwtf-match-h2h-link {
  color: var(--sportwtf-accent);
  text-decoration: none;
}

.sportwtf-match-h2h-link:hover {
  color: var(--sportwtf-accent-hover);
  text-decoration: underline;
}

.sportwtf-match-h2h-table tbody tr:hover {
  background: var(--sportwtf-bg-subtle);
}

.sportwtf-match-h2h-summary {
  margin: 0.75rem 0 0;
  font-size: 0.9rem;
  color: var(--sportwtf-grey);
}

/* Standings table */
.sportwtf-match-standings-section {
  padding: 1rem;
}

.sportwtf-standings-wrap {
  overflow-x: auto;
}

.sportwtf-standings-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.sportwtf-standings-table th,
.sportwtf-standings-table td {
  padding: 0.5rem 0.75rem;
  text-align: left;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-standings-table th {
  font-weight: 600;
  color: var(--sportwtf-grey);
}

.sportwtf-standings-table td:first-child {
  width: 2.5rem;
  text-align: center;
}

/* Колонка «Команда»: flex только у внутренней ссылки/обёртки — не у td, иначе ломается table-layout на узких экранах */
.sportwtf-standings-table td:nth-child(2) {
  vertical-align: middle;
}

.sportwtf-standings-team-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  max-width: 100%;
  text-decoration: none;
  color: inherit;
}

.sportwtf-league-team-link.sportwtf-standings-team-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  max-width: 100%;
}

.sportwtf-standings-team-link:hover {
  text-decoration: underline;
}

.sportwtf-standings-logo {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  object-fit: contain;
  vertical-align: middle;
}

.sportwtf-standings-logo.sportwtf-standings-flag,
.sportwtf-standings-logo[src*="/assets/media/flags/"],
.sportwtf-standings-logo[src*="flagcdn.com"] {
  width: 24px;
  height: 16px;
  object-fit: cover;
  border-radius: 2px;
}

.sportwtf-standings-row-match {
  background: rgba(0, 0, 0, 0.04);
}

.sportwtf-standings-row-current {
  background: var(--sportwtf-live-bg);
  font-weight: 600;
}

.sportwtf-standings-table abbr {
  text-decoration: none;
}

.sportwtf-standings-team-text {
  min-width: 0;
}

/*
 * Десктоп: полная турнирка — фиксированные доли колонок + ellipsis, чтобы длинный текст
 * («Team will be confirmed») не сдвигал И/В/Н/… между группами.
 */
@media (min-width: 641px) {
  .sportwtf-standings-table.sportwtf-standings-table--full {
    table-layout: fixed;
  }

  .sportwtf-standings-table--full th:first-child,
  .sportwtf-standings-table--full td:first-child {
    width: 4%;
    box-sizing: border-box;
  }

  .sportwtf-standings-table--full th:nth-child(2),
  .sportwtf-standings-table--full td:nth-child(2) {
    width: 44%;
    min-width: 0;
  }

  .sportwtf-standings-table--full th:nth-child(n + 3),
  .sportwtf-standings-table--full td:nth-child(n + 3) {
    width: 8.666%;
    text-align: center;
    box-sizing: border-box;
  }

  .sportwtf-standings-table--full td:nth-child(2) {
    overflow: hidden;
    vertical-align: middle;
  }

  .sportwtf-standings-table--full td:nth-child(2) .sportwtf-league-team-link,
  .sportwtf-standings-table--full td:nth-child(2) .sportwtf-standings-team-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    min-width: 0;
    max-width: 100%;
  }

  .sportwtf-standings-table--full td:nth-child(2) .sportwtf-standings-team-text {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}

/* Место в таблице: номер + цветная полоса зоны (оттенки как у спортивных медиа) */
.sportwtf-standings-rank-cell {
  vertical-align: middle;
  text-align: center;
}

.sportwtf-standings-rank-inner {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
}

.sportwtf-standings-rank-num {
  font-variant-numeric: tabular-nums;
}

.sportwtf-standings-rank-stripe {
  display: inline-block;
  width: 3px;
  min-height: 1.2em;
  align-self: center;
  border-radius: 1px;
  flex-shrink: 0;
}

.sportwtf-standings-zone--direct {
  background: #22c55e;
}

.sportwtf-standings-zone--playoff {
  background: #f59e0b;
}

.sportwtf-standings-zone--europa {
  background: #3b82f6;
}

.sportwtf-standings-zone--relegate {
  background: #ef4444;
}

.sportwtf-standings-zone--neutral {
  background: #d1d5db;
}

@media (max-width: 640px) {
  .sportwtf-standings-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-left: -0.35rem;
    margin-right: -0.35rem;
    padding-left: 0.35rem;
    padding-right: 0.35rem;
    max-width: 100%;
    box-sizing: border-box;
  }

  .sportwtf-league-section .sportwtf-standings-wrap,
  .sportwtf-team-section .sportwtf-standings-wrap {
    margin-left: -0.5rem;
    margin-right: -0.5rem;
  }

  .sportwtf-standings-table {
    table-layout: fixed;
    width: 100%;
    min-width: 0;
    font-size: 0.8rem;
    border-spacing: 0;
  }

  .sportwtf-standings-table th,
  .sportwtf-standings-table td {
    padding: 0.28rem 0.12rem;
    word-break: keep-all;
  }

  .sportwtf-standings-table th {
    font-size: 0.8rem;
    line-height: 1.15;
  }

  .sportwtf-standings-table th:first-child,
  .sportwtf-standings-table td:first-child {
    width: 6%;
    min-width: 0;
    max-width: none;
    padding-left: 0.08rem;
    padding-right: 0.08rem;
    text-align: center;
  }

  /* Числовые колонки — 8% каждая; «Команда» забирает остаток */
  .sportwtf-standings-table th:nth-child(n + 3),
  .sportwtf-standings-table td:nth-child(n + 3) {
    width: 8%;
    min-width: 0;
    max-width: none;
    text-align: center;
    white-space: nowrap;
    padding-left: 0.05rem;
    padding-right: 0.05rem;
    font-variant-numeric: tabular-nums;
  }

  .sportwtf-standings-table th:nth-child(2),
  .sportwtf-standings-table td:nth-child(2) {
    width: auto;
    min-width: 0;
  }

  /* Сброс flex у ячейки «Команда» на мобилке — иначе таблица не сжимается по colgroup */
  .sportwtf-standings-table td:nth-child(2) {
    display: table-cell;
    vertical-align: middle;
    overflow: hidden;
  }

  .sportwtf-standings-table td:nth-child(2) .sportwtf-league-team-link,
  .sportwtf-standings-table td:nth-child(2) .sportwtf-standings-team-link {
    display: flex;
    align-items: center;
    gap: 0.28rem;
    min-width: 0;
    max-width: 100%;
  }

  .sportwtf-standings-table:not(.sportwtf-topscorers-table) td:nth-child(2) .sportwtf-standings-team-text {
    flex: 1 1 auto;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 0.8rem;
  }

  .sportwtf-league-standings .sportwtf-league-group-title {
    font-size: 0.82rem;
  }

  .sportwtf-standings-table .sportwtf-standings-logo {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
    object-fit: contain;
  }

  .sportwtf-standings-table:not(.sportwtf-topscorers-table) td:nth-child(2) .sportwtf-standings-logo {
    width: 17px;
    height: 17px;
    border-radius: 50%;
    object-fit: cover;
  }

  .sportwtf-topscorers-table th:nth-child(n + 3),
  .sportwtf-topscorers-table td:nth-child(n + 3) {
    width: auto;
    max-width: none;
    white-space: normal;
  }

  .sportwtf-topscorers-table th:nth-child(4),
  .sportwtf-topscorers-table td:nth-child(4) {
    width: 2.25rem;
    text-align: center;
    white-space: nowrap;
  }

  /* Полная турнирная таблица на мобилке — как на десктопе: шапка без фона, обычные линии */
  .sportwtf-league-standings .sportwtf-standings-table--full,
  .sportwtf-team-standings .sportwtf-standings-table--full {
    background: transparent;
    border-radius: 0;
    box-shadow: none;
    overflow: visible;
  }

  .sportwtf-league-standings .sportwtf-standings-table--full thead,
  .sportwtf-team-standings .sportwtf-standings-table--full thead {
    background: transparent;
  }

  .sportwtf-league-standings .sportwtf-standings-table--full th,
  .sportwtf-team-standings .sportwtf-standings-table--full th {
    color: var(--sportwtf-grey);
    font-weight: 600;
    border-bottom: 1px solid var(--sportwtf-border);
  }

  .sportwtf-league-standings .sportwtf-standings-table--full td,
  .sportwtf-team-standings .sportwtf-standings-table--full td {
    border-bottom: 1px solid var(--sportwtf-border);
    vertical-align: middle;
  }

  .sportwtf-league-standings .sportwtf-standings-table--full tbody td:last-child,
  .sportwtf-team-standings .sportwtf-standings-table--full tbody td:last-child {
    font-weight: 700;
  }

  /* Нац. лига на мобилке (.sportwtf-standings-table--wide-mobile): как у конкурентов — только И и О */
  .sportwtf-standings-table--wide-mobile th:nth-child(4),
  .sportwtf-standings-table--wide-mobile td:nth-child(4),
  .sportwtf-standings-table--wide-mobile th:nth-child(5),
  .sportwtf-standings-table--wide-mobile td:nth-child(5),
  .sportwtf-standings-table--wide-mobile th:nth-child(6),
  .sportwtf-standings-table--wide-mobile td:nth-child(6),
  .sportwtf-standings-table--wide-mobile th:nth-child(7),
  .sportwtf-standings-table--wide-mobile td:nth-child(7) {
    display: none;
  }

  .sportwtf-standings-table--wide-mobile th:first-child,
  .sportwtf-standings-table--wide-mobile td:first-child {
    width: 10%;
  }

  .sportwtf-standings-table--wide-mobile th:nth-child(3),
  .sportwtf-standings-table--wide-mobile td:nth-child(3),
  .sportwtf-standings-table--wide-mobile th:nth-child(8),
  .sportwtf-standings-table--wide-mobile td:nth-child(8) {
    width: 12%;
  }
}

/* Узкие телефоны — те же пропорции, что и до 640px (0.8rem, колонки 8%) */
@media (max-width: 560px) {
  .sportwtf-standings-table:not(.sportwtf-topscorers-table) {
    font-size: 0.8rem;
    min-width: 0;
  }

  .sportwtf-standings-table:not(.sportwtf-topscorers-table) th {
    font-size: 0.8rem;
  }

  .sportwtf-standings-table:not(.sportwtf-topscorers-table) th:first-child,
  .sportwtf-standings-table:not(.sportwtf-topscorers-table) td:first-child {
    width: 6%;
    min-width: 0;
    max-width: none;
  }

  .sportwtf-standings-table:not(.sportwtf-topscorers-table) th:nth-child(n + 3),
  .sportwtf-standings-table:not(.sportwtf-topscorers-table) td:nth-child(n + 3) {
    width: 8%;
    min-width: 0;
    max-width: none;
    padding-left: 0.03rem;
    padding-right: 0.03rem;
  }

  .sportwtf-standings-table:not(.sportwtf-topscorers-table) .sportwtf-standings-logo {
    width: 14px;
    height: 14px;
  }

  .sportwtf-standings-table:not(.sportwtf-topscorers-table) td:nth-child(2) .sportwtf-standings-logo {
    width: 17px;
    height: 17px;
    border-radius: 50%;
    object-fit: cover;
  }

  .sportwtf-standings-table:not(.sportwtf-topscorers-table) td:nth-child(2) .sportwtf-standings-team-text {
    font-size: 0.8rem;
  }

  .sportwtf-standings-table:not(.sportwtf-topscorers-table) td:nth-child(2) .sportwtf-league-team-link,
  .sportwtf-standings-table:not(.sportwtf-topscorers-table) td:nth-child(2) .sportwtf-standings-team-link {
    gap: 0.12rem;
  }

  .sportwtf-league-section.sportwtf-league-standings,
  .sportwtf-team-section.sportwtf-team-standings,
  .sportwtf-match-standings-section {
    padding-left: 0.7rem;
    padding-right: 0.7rem;
  }

  .sportwtf-standings-table--wide-mobile:not(.sportwtf-topscorers-table) th:first-child,
  .sportwtf-standings-table--wide-mobile:not(.sportwtf-topscorers-table) td:first-child {
    width: 10%;
  }

  .sportwtf-standings-table--wide-mobile:not(.sportwtf-topscorers-table) th:nth-child(3),
  .sportwtf-standings-table--wide-mobile:not(.sportwtf-topscorers-table) td:nth-child(3),
  .sportwtf-standings-table--wide-mobile:not(.sportwtf-topscorers-table) th:nth-child(8),
  .sportwtf-standings-table--wide-mobile:not(.sportwtf-topscorers-table) td:nth-child(8) {
    width: 12%;
  }
}

/* ========== Team page ========== */
.sportwtf-team-with-sidebar .sportwtf-team-page {
  max-width: none;
  margin: 0;
}

.sportwtf-team-page {
  max-width: 900px;
  margin: 0 auto;
}

.sportwtf-team-news-teaser {
  margin: 0.35rem 0 0;
  font-size: 0.78rem;
  line-height: 1.35;
  color: #6b7280;
}

.sportwtf-article-sidebar-link--plain {
  color: inherit;
  text-decoration: none;
  font-weight: 600;
}

/* Постматчевый обзор на странице матча */
.sportwtf-match-review-section {
  margin: 1.25rem 0 0;
  padding: 1rem 0 0;
  border-top: 1px solid #e5e7eb;
}

.sportwtf-match-review-text {
  font-size: 0.95rem;
  line-height: 1.65;
  color: #1f2937;
}

.sportwtf-match-review-text p {
  margin: 0 0 0.85rem;
}

.sportwtf-match-review-text p:last-child {
  margin-bottom: 0;
}

.sportwtf-team-hero {
  text-align: center;
  padding: 1.5rem 1rem;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-team-hero-logo,
.sportwtf-team-hero-flag-img {
  display: block;
  margin: 0 auto 0.75rem;
}

.sportwtf-team-hero-flag-img {
  width: 96px;
  height: auto;
  max-height: 64px;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
}

.sportwtf-team-hero-name {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 0 0.25rem;
}

.sportwtf-team-hero-country,
.sportwtf-team-hero-venue,
.sportwtf-team-hero-league,
.sportwtf-team-hero-position {
  margin: 0.25rem 0;
  color: var(--sportwtf-grey);
  font-size: 0.9rem;
}

.sportwtf-team-section {
  padding: 1.25rem 1rem;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-team-section-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0 0 0.75rem;
}

.sportwtf-team-fixture-group {
  margin-bottom: 1.15rem;
}

.sportwtf-team-fixture-group:last-child {
  margin-bottom: 0;
}

.sportwtf-team-fixture-league-head {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 0.35rem;
  padding-bottom: 0.45rem;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-team-fixture-league-titles {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: baseline;
  gap: 0.35rem;
  min-width: 0;
}

.sportwtf-team-fixture-league-logo {
  width: 22px;
  height: 22px;
  object-fit: contain;
  flex-shrink: 0;
}

.sportwtf-team-fixture-league-name {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--sportwtf-black);
  line-height: 1.25;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sportwtf-team-fixture-league-meta {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--sportwtf-grey);
  flex-shrink: 0;
  white-space: nowrap;
}

.sportwtf-team-fixture-group .sportwtf-team-fixture-list {
  margin: 0.12rem 0 0;
}

.sportwtf-team-fixture-group .sportwtf-team-fixture-item:last-child {
  border-bottom: 0;
}

.sportwtf-team-fixture-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.sportwtf-team-fixture-item {
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--sportwtf-border);
  font-size: 0.9rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.35rem 0.75rem;
}

.sportwtf-team-fixture-link {
  color: inherit;
  text-decoration: none;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.35rem 0.75rem;
  width: 100%;
  box-sizing: border-box;
}

.sportwtf-team-fixture-link:hover {
  color: var(--sportwtf-blue);
}

.sportwtf-team-fixture-teams {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.35rem 0.5rem;
  margin-right: 0.5rem;
  min-width: 0;
  flex: 1 1 auto;
}

.sportwtf-team-fixture-side {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-width: 0;
}

.sportwtf-team-fixture-crest {
  width: 20px;
  height: 20px;
  object-fit: contain;
  flex-shrink: 0;
}

.sportwtf-team-fixture-name {
  min-width: 0;
}

.sportwtf-team-fixture-sep {
  color: var(--sportwtf-grey);
  font-weight: 500;
  flex-shrink: 0;
  padding: 0 0.1rem;
}

.sportwtf-team-fixture-score,
.sportwtf-team-fixture-date {
  font-weight: 600;
  color: var(--sportwtf-grey);
}

.sportwtf-team-fixture-teams--withscore {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 0.35rem 0.65rem;
  width: 100%;
  margin-right: 0;
}

.sportwtf-team-fixture-side--home {
  justify-self: start;
}

.sportwtf-team-fixture-side--away {
  justify-self: end;
}

.sportwtf-team-fixture-teams--withscore .sportwtf-team-fixture-score {
  justify-self: center;
  text-align: center;
  white-space: nowrap;
}

/* Тур лиги: навигация и сетка матчей */
.sportwtf-league-tour {
  max-width: 100%;
  overflow-x: hidden;
  box-sizing: border-box;
  min-width: 0;
}

.sportwtf-league-tour-bar {
  display: flex;
  align-items: stretch;
  gap: 0.4rem;
  margin: 0 0 0.75rem;
  min-height: 2.25rem;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
  /* длинная лента чипов не должна раздвигать ширину страницы */
  overflow: hidden;
}

.sportwtf-league-tour-shear {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  min-width: 2.25rem;
  padding: 0 0.35rem;
  text-decoration: none;
  color: #fff;
  background: #1f2937;
  border: 1px solid #1a2330;
  clip-path: polygon(0.35rem 0, 100% 0, calc(100% - 0.35rem) 100%, 0 100%);
  font-size: 1.1rem;
  line-height: 1;
  transition: background 0.15s, opacity 0.15s;
}

.sportwtf-league-tour-shear--nav:hover {
  background: #111827;
  color: #fff;
}

.sportwtf-league-tour-shear--off {
  opacity: 0.35;
  pointer-events: none;
  cursor: default;
}

button.sportwtf-league-tour-shear {
  border: none;
  font: inherit;
  cursor: pointer;
  color: #fff;
}

button.sportwtf-league-tour-shear:disabled {
  cursor: not-allowed;
  opacity: 0.35;
}

.sportwtf-league-tour-shear-text {
  display: block;
  transform: translateY(-0.05em);
}

.sportwtf-league-tour-strip-wrap {
  /* 1 1 auto даёт flex-basis:auto → в ряду легко «рвёт» ширину под min-content чипов; 0% — предсказуемо в Safari */
  flex: 1 1 0%;
  min-width: 0;
  width: 0;
  max-width: 100%;
  align-self: stretch;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
  -ms-overflow-style: none;
  border-radius: 0;
  border: none;
  background: transparent;
  cursor: grab;
  touch-action: pan-x;
}

.sportwtf-league-tour-strip-wrap::-webkit-scrollbar {
  display: none;
  width: 0;
  height: 0;
}

.sportwtf-league-tour-strip-wrap--grabbing {
  cursor: grabbing;
}

.sportwtf-league-tour-strip {
  display: flex;
  flex-wrap: nowrap;
  gap: 0.35rem;
  list-style: none;
  margin: 0;
  padding: 0.35rem 0.45rem;
  align-items: center;
  width: max-content;
  max-width: none;
  box-sizing: border-box;
}

.sportwtf-league-tour-strip-item {
  flex: 0 0 auto;
}

.sportwtf-league-tour-chip {
  display: inline-block;
  padding: 0.35rem 0.65rem;
  font-size: 0.8rem;
  font-weight: 600;
  text-decoration: none;
  color: #444;
  background: #f3f3f3;
  border: 1px solid #c8c8c8;
  clip-path: polygon(0.35rem 0, 100% 0, calc(100% - 0.35rem) 100%, 0 100%);
  white-space: nowrap;
  transition: background 0.15s, color 0.15s;
  font: inherit;
  cursor: pointer;
  box-sizing: border-box;
}

.sportwtf-league-tour-chip:hover {
  background: #fff;
  color: #1a2744;
}

.sportwtf-league-tour-chip--current:disabled,
.sportwtf-league-tour-chip--current {
  background: #1f2937;
  color: #fff;
  border-color: #1a2330;
  opacity: 1;
  cursor: default;
}

.sportwtf-league-tour--busy {
  pointer-events: none;
  opacity: 0.65;
  transition: opacity 0.15s;
}

.sportwtf-league-tour .sportwtf-league-tour-matches {
  background: transparent;
}

.sportwtf-league-tour-matches {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--sportwtf-border);
}

.sportwtf-league-tour-empty {
  padding: 0.75rem 0.25rem;
  color: var(--sportwtf-grey);
  font-size: 0.9rem;
}

.sportwtf-league-tour-row {
  border-bottom: 1px solid var(--sportwtf-border);
  font-size: 0.9rem;
}

.sportwtf-league-tour-row:last-child {
  border-bottom: none;
}

.sportwtf-league-tour-row-link {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  column-gap: 0.5rem;
  padding: 0.55rem 0.2rem;
  text-decoration: none;
  color: inherit;
  box-sizing: border-box;
  width: 100%;
  max-width: min(36rem, 100%);
  margin: 0 auto;
  min-width: 0;
}

.sportwtf-league-tour-row-link:hover .sportwtf-league-tour-name {
  color: var(--sportwtf-blue);
}

.sportwtf-league-tour-cell {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  min-width: 0;
}

.sportwtf-league-tour-pair {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.4rem;
  min-width: 0;
}

.sportwtf-league-tour-pair--home {
  justify-content: flex-end;
  text-align: right;
}

.sportwtf-league-tour-pair--home .sportwtf-league-tour-name {
  order: 0;
}

.sportwtf-league-tour-pair--home .sportwtf-league-tour-crest {
  order: 1;
}

.sportwtf-league-tour-pair--away {
  justify-content: flex-start;
  text-align: left;
}

.sportwtf-league-tour-cell--mid {
  justify-self: center;
  flex: 0 0 auto;
}

.sportwtf-league-tour-crest {
  width: 22px;
  height: 22px;
  object-fit: contain;
  flex-shrink: 0;
}

.sportwtf-league-tour-name {
  font-weight: 400;
  color: #1a2744;
  min-width: 0;
  word-break: break-word;
}

.sportwtf-league-tour-name-mob {
  display: none;
}

.sportwtf-league-tour-name-abbr {
  display: none;
  font-weight: 400;
}

.sportwtf-league-tour-mid-txt {
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.sportwtf-league-tour-mid-txt--score {
  color: var(--sportwtf-black);
}

.sportwtf-league-tour-mid-txt--muted {
  font-weight: 600;
  color: var(--sportwtf-grey);
  font-size: 0.85rem;
}

.sportwtf-team-squad-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.75rem;
}

.sportwtf-team-squad-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.5rem;
  background: var(--sportwtf-bg-panel);
  border: 1px solid var(--sportwtf-border);
  border-radius: 6px;
  font-size: 0.85rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.sportwtf-team-squad-photo {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: 50%;
  margin-bottom: 0.35rem;
}

.sportwtf-team-squad-num {
  font-weight: 700;
  color: var(--sportwtf-grey);
}

.sportwtf-team-squad-name {
  font-weight: 500;
  text-align: center;
}

.sportwtf-team-squad-pos-row {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  flex-wrap: wrap;
  margin-top: 0.2rem;
}

.sportwtf-team-squad-pos-flag {
  width: 22px;
  height: auto;
  max-height: 16px;
  object-fit: cover;
  border-radius: 2px;
  flex-shrink: 0;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.06);
}

.sportwtf-team-squad-pos-club {
  width: 18px;
  height: 18px;
  object-fit: contain;
  flex-shrink: 0;
}

.sportwtf-team-squad-pos {
  font-size: 0.75rem;
  color: var(--sportwtf-grey);
}

/* ========== League page ========== */
.sportwtf-league-page {
  max-width: 900px;
  margin: 0 auto;
}

@media (max-width: 640px) {
  .sportwtf-league-page {
    max-width: none;
    width: 100%;
    min-width: 0;
    margin: 0;
    box-sizing: border-box;
  }

  .sportwtf-league-hero,
  .sportwtf-league-section {
    padding-left: max(0.75rem, env(safe-area-inset-left, 0px));
    padding-right: max(0.75rem, env(safe-area-inset-right, 0px));
  }

  .sportwtf-league-tournament,
  .sportwtf-league-knockout,
  .sportwtf-league-ko-bracket-wrap,
  .sportwtf-league-knockout .sportwtf-league-ko-cols {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }

  .sportwtf-pred-card.sportwtf-pred-card--league-ko {
    max-width: none;
    width: 100%;
  }

  .sportwtf-league-tour {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
  }

  .sportwtf-league-tournament {
    overflow-x: hidden;
    min-width: 0;
  }

  .sportwtf-league-with-sidebar {
    min-width: 0;
    max-width: 100%;
    overflow-x: hidden;
  }

  .sportwtf-league-tour-matches {
    max-width: 100%;
    min-width: 0;
  }

  /* Полные названия клубов, как у строки игрока в «лучшие бомбардиры» (.sportwtf-stats-widget-clubname) */
  .sportwtf-league-tour-name-mob,
  .sportwtf-league-tour-name-abbr {
    display: none;
  }

  .sportwtf-league-tour-row-link {
    align-items: start;
    column-gap: 0.3rem;
  }

  .sportwtf-league-tour-pair {
    align-items: flex-start;
    gap: 0.3rem;
  }

  .sportwtf-league-tour-pair .sportwtf-league-tour-crest {
    margin-top: 0.1rem;
  }

  .sportwtf-league-tour-pair .sportwtf-league-tour-name {
    min-width: 0;
    max-width: 100%;
    font-size: 0.75rem;
    color: var(--sportwtf-grey);
    line-height: 1.25;
  }

  /* до 2 строк вместо одной с "…" — длинные немецкие/англ. названия читаемее */
  .sportwtf-league-tour-pair .sportwtf-league-tour-name-full {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    overflow-wrap: anywhere;
    word-break: break-word;
  }

  a.sportwtf-league-tour-row-link:hover .sportwtf-league-tour-pair .sportwtf-league-tour-name {
    color: var(--sportwtf-blue);
  }
}

@media (max-width: 360px) {
  .sportwtf-league-tour-pair .sportwtf-league-tour-name {
    font-size: 0.7rem;
  }
}

.sportwtf-league-hero {
  background: var(--sportwtf-bg-subtle);
  text-align: center;
  padding: 1.5rem 1rem;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-league-hero-logo {
  display: block;
  margin: 0 auto 0.75rem;
  width: 72px;
  height: 72px;
  object-fit: contain;
}

.sportwtf-league-hero-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 0 0.25rem;
}

.sportwtf-league-hero-season {
  display: inline-block;
  margin-left: 0.35rem;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--sportwtf-grey);
}

.sportwtf-league-hero-country {
  margin: 0.25rem 0;
  color: var(--sportwtf-grey);
  font-size: 0.9rem;
}

.sportwtf-league-hero-description {
  margin: 0.75rem auto 0;
  max-width: 44rem;
  color: var(--sportwtf-grey);
  font-size: 0.9rem;
  line-height: 1.6;
}

.sportwtf-league-section {
  padding: 1.25rem 1rem;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-league-section-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0 0 0.75rem;
}

/* Заголовок секции + ссылки на соседние дивизионы (leaguePage) */
.sportwtf-league-section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  margin-bottom: 0.75rem;
}

.sportwtf-league-section-head .sportwtf-league-section-title {
  margin: 0;
  flex: 1 1 12rem;
}

.sportwtf-league-peer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.65rem;
  justify-content: flex-end;
  align-items: center;
  max-width: 100%;
}

.sportwtf-league-peer-link {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--sportwtf-blue);
  text-decoration: none;
  white-space: nowrap;
}

.sportwtf-league-peer-link:hover {
  text-decoration: underline;
}

@media (max-width: 520px) {
  .sportwtf-league-peer-nav {
    justify-content: flex-start;
  }
}

.sportwtf-league-group-title {
  font-size: 1rem;
  font-weight: 600;
  margin: 1.25rem 0 0.5rem;
  color: var(--sportwtf-grey);
}

.sportwtf-league-standings .sportwtf-league-group-title:first-of-type {
  margin-top: 0.5rem;
}

.sportwtf-league-analytics {
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}

.sportwtf-league-analytics-line {
  margin: 0.25rem 0;
  font-size: 0.9rem;
  color: var(--sportwtf-grey);
  line-height: 1.5;
}

/* Новости лиги (индекс из cron_articles → articles_index.json) */
.sportwtf-league-news-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.sportwtf-league-news-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.2rem;
  padding-bottom: 0.65rem;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-league-news-item:last-of-type {
  border-bottom: none;
  padding-bottom: 0;
}

.sportwtf-league-news-link {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--sportwtf-black);
  text-decoration: none;
  line-height: 1.35;
}

.sportwtf-league-news-link:hover {
  color: var(--sportwtf-blue);
}

.sportwtf-league-news-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.65rem;
  margin-bottom: 0.35rem;
  font-size: 0.8rem;
  color: var(--sportwtf-grey);
}

/* Плашка турнира: ленты новостей и сайдбар на странице статьи */
.sportwtf-news-meta-badge,
.sportwtf-article-sidebar-meta .sportwtf-article-sidebar-cat {
  display: inline-block;
  padding: 0.12rem 0.45rem;
  border-radius: 4px;
  background: var(--sportwtf-bg-subtle);
  border: 1px solid var(--sportwtf-border);
  color: var(--sportwtf-grey);
  font-size: 0.72rem;
  font-weight: 600;
  line-height: 1.25;
}

.sportwtf-league-news-more {
  margin: 0.75rem 0 0;
  font-size: 0.9rem;
}

.sportwtf-league-news-more-link {
  color: var(--sportwtf-blue);
  text-decoration: none;
  font-weight: 500;
}

.sportwtf-league-news-more-link:hover {
  text-decoration: underline;
}

.sportwtf-news-hub {
  max-width: 720px;
  margin: 0 auto;
}

.sportwtf-news-hub-title {
  margin-top: 0;
}

.sportwtf-empty {
  color: var(--sportwtf-grey);
  font-size: 0.95rem;
}

.sportwtf-topscorers-table {
  max-width: 480px;
}

/* Виджет статистики лиги (бомбардиры / ассистенты / гол+пас) — стиль «лента» */
.sportwtf-stats-widget {
  max-width: 520px;
  margin-top: 0.25rem;
  background: transparent;
}

.sportwtf-stats-widget-state {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.sportwtf-stats-widget-tabbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  padding: 0.25rem 0;
  border-radius: 0;
  background: transparent;
  border: none;
}

.sportwtf-stats-widget-tab {
  flex: 1 1 auto;
  min-width: 0;
  text-align: center;
  padding: 0.42rem 0.7rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: #444;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  border-radius: 0;
  border: 1px solid #c8c8c8;
  background: #f3f3f3;
  clip-path: polygon(0.4rem 0, 100% 0, calc(100% - 0.4rem) 100%, 0 100%);
}

.sportwtf-stats-widget .sportwtf-stats-widget-state:nth-of-type(1):checked ~ .sportwtf-stats-widget-tabbar .sportwtf-stats-widget-tab:nth-child(1),
.sportwtf-stats-widget .sportwtf-stats-widget-state:nth-of-type(2):checked ~ .sportwtf-stats-widget-tabbar .sportwtf-stats-widget-tab:nth-child(2),
.sportwtf-stats-widget .sportwtf-stats-widget-state:nth-of-type(3):checked ~ .sportwtf-stats-widget-tabbar .sportwtf-stats-widget-tab:nth-child(3) {
  background: #1f2937;
  color: #fff;
  border-color: #1a2330;
  clip-path: polygon(0.4rem 0, 100% 0, calc(100% - 0.4rem) 100%, 0 100%);
}

.sportwtf-stats-widget-panel {
  display: none;
  margin-top: 0.75rem;
}

.sportwtf-stats-widget .sportwtf-stats-widget-state:nth-of-type(1):checked ~ .sportwtf-stats-widget-panel--g,
.sportwtf-stats-widget .sportwtf-stats-widget-state:nth-of-type(2):checked ~ .sportwtf-stats-widget-panel--a,
.sportwtf-stats-widget .sportwtf-stats-widget-state:nth-of-type(3):checked ~ .sportwtf-stats-widget-panel--ga {
  display: block;
}

.sportwtf-stats-widget-head {
  display: grid;
  grid-template-columns: 1fr 2.25rem 2.25rem;
  align-items: center;
  gap: 0.35rem 0.75rem;
  padding: 0.25rem 0 0.4rem 0.25rem;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--sportwtf-grey);
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-stats-widget-col-h {
  text-align: center;
}

.sportwtf-stats-widget-list {
  display: flex;
  flex-direction: column;
}

.sportwtf-stats-widget-list:hover .sportwtf-stats-widget-row {
  opacity: 0.38;
  filter: grayscale(0.2);
  transition: opacity 0.2s ease, filter 0.2s ease, background 0.2s ease;
}

.sportwtf-stats-widget-list .sportwtf-stats-widget-row:hover {
  opacity: 1;
  filter: none;
  background: #eef2f7;
}

.sportwtf-stats-widget-row {
  display: grid;
  grid-template-columns: 1fr 2.25rem 2.25rem;
  align-items: center;
  gap: 0.35rem 0.75rem;
  padding: 0.55rem 0.35rem;
  text-decoration: none;
  color: inherit;
  border-bottom: 1px solid #e8e8e8;
  transition: opacity 0.2s ease, filter 0.2s ease, background 0.2s ease;
}

.sportwtf-stats-widget-row:last-child {
  border-bottom: none;
}

.sportwtf-stats-widget-player {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
}

.sportwtf-stats-widget-avatar {
  position: relative;
  flex-shrink: 0;
  width: 48px;
  height: 48px;
}

.sportwtf-stats-widget-face {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  background: #e5e5e5;
  display: block;
}

.sportwtf-stats-widget-clubline {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-width: 0;
  max-width: 100%;
}

.sportwtf-stats-widget-club-ico {
  width: 18px;
  height: 18px;
  object-fit: contain;
  flex-shrink: 0;
}

.sportwtf-stats-widget-names {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  min-width: 0;
}

.sportwtf-stats-widget-name {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--sportwtf-black);
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sportwtf-stats-widget-clubname {
  font-size: 0.75rem;
  color: var(--sportwtf-grey);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.sportwtf-stats-widget-stat {
  text-align: center;
  font-size: 0.88rem;
  color: #333;
}

.sportwtf-stats-widget-stat--strong {
  font-weight: 700;
  color: var(--sportwtf-black);
}

.sportwtf-stats-widget-empty {
  margin: 0.75rem 0;
  font-size: 0.9rem;
  color: var(--sportwtf-grey);
}

.sportwtf-stats-widget-footer {
  margin: 0.85rem 0 0;
  text-align: center;
}

.sportwtf-stats-widget-footer-link {
  font-size: 0.88rem;
  color: var(--sportwtf-blue);
  text-decoration: none;
  font-weight: 500;
}

.sportwtf-stats-widget-footer-link:hover {
  text-decoration: underline;
}

@media (max-width: 480px) {
  .sportwtf-stats-widget-head,
  .sportwtf-stats-widget-row {
    grid-template-columns: 1fr 2rem 2rem;
    gap: 0.25rem 0.35rem;
  }

  .sportwtf-stats-widget-avatar,
  .sportwtf-stats-widget-face {
    width: 40px;
    height: 40px;
  }

  .sportwtf-stats-widget-avatar {
    width: 40px;
    height: 40px;
  }
}

.sportwtf-team-analytics-line {
  margin: 0.35rem 0 0;
  font-size: 0.9rem;
  color: var(--sportwtf-grey);
  line-height: 1.5;
}

.sportwtf-league-team-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 0.5rem 1rem;
}

.sportwtf-league-team-item {
  font-size: 0.9rem;
}

.sportwtf-league-team-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: inherit;
  text-decoration: none;
}

.sportwtf-league-team-link:hover {
  color: var(--sportwtf-blue);
}

.sportwtf-league-team-logo {
  flex-shrink: 0;
}

.sportwtf-league-team-name {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Турниры: группы + плей-офф (вкладки, карточки пар) */
.sportwtf-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Блок с вкладками и плей-офф — на белом; бежевый только hero турнира выше */
.sportwtf-league-tournament {
  background: #fff;
}

.sportwtf-league-tab-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.35rem 0.5rem;
  padding: 0.75rem 0.5rem 1rem;
  background: #fff;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-league-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.5rem;
  min-height: 2.5rem;
  padding: 0.35rem 0.5rem;
  font-size: 0.8rem;
  font-weight: 500;
  border: 1px solid var(--sportwtf-border);
  border-radius: 8px;
  background: #fff;
  color: inherit;
  cursor: pointer;
  line-height: 1.2;
  text-align: center;
}

.sportwtf-league-tab:hover {
  border-color: var(--sportwtf-grey);
}

/* Вкладки плей-офф + переключатель «Прогнозы» справа */
.sportwtf-league-tab-bar--with-ko-pred {
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem 0.75rem;
}

.sportwtf-league-tab-bar-tabs {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.35rem 0.5rem;
  flex: 1 1 auto;
  min-width: 0;
}

.sportwtf-league-tab-bar--with-ko-pred .sportwtf-league-ko-tab-pred {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-left: auto;
}

.sportwtf-league-tournament.sportwtf-league-ko-predictions-on .sportwtf-league-ko-tab-pred .sportwtf-pred-toggle-track {
  background: #6b7280;
}

.sportwtf-league-tournament.sportwtf-league-ko-predictions-on .sportwtf-league-ko-tab-pred .sportwtf-pred-toggle-thumb {
  transform: translateX(1.25rem);
}

.sportwtf-league-tournament.sportwtf-league-ko-predictions-off .sportwtf-league-ko-pred-rail .sportwtf-pred-card {
  display: none !important;
}

.sportwtf-league-tournament.sportwtf-league-ko-predictions-off .sportwtf-league-ko-pred-inline .sportwtf-pred-card {
  display: none !important;
}

/* Мобилка: прогнозы под карточкой пары; на десктопе скрыто (см. media ниже) */
.sportwtf-league-ko-pred-inline {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  width: 100%;
  min-width: 0;
}

/* Плей-офф: узкие боковые колонки с карточками прогнозов */
.sportwtf-league-ko-bracket-wrap {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
  align-items: start;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow: visible;
}

.sportwtf-league-ko-pred-rail {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  min-width: 0;
  align-self: start;
}

.sportwtf-league-ko-pred-tie {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.sportwtf-pred-card--league-ko {
  font-size: 0.8rem;
  min-width: 0;
  max-width: 100%;
  width: 100%;
  margin: 0;
}

/* Инлайн под матчем (мобилка): в строке лого + 3 буквы + % */
.sportwtf-pred-card--league-ko .sportwtf-pred-card-row {
  align-items: center;
  justify-content: space-between;
  gap: 0.3rem;
}

.sportwtf-pred-card--league-ko .sportwtf-pred-card-team {
  min-width: 0;
  flex: 1 1 auto;
}

.sportwtf-pred-card--league-ko .sportwtf-pred-card-logo {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.sportwtf-pred-card--league-ko .sportwtf-pred-card-code {
  font-size: 0.68rem;
  font-weight: 700;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sportwtf-pred-card--league-ko .sportwtf-pred-card-pct {
  font-size: 0.75rem;
  flex-shrink: 0;
}

.sportwtf-pred-card--league-ko .sportwtf-pred-card-main {
  padding: 0.35rem 0.45rem;
}

.sportwtf-pred-card--league-ko .sportwtf-pred-card-draw {
  padding: 0.25rem 0.4rem;
}

@media (max-width: 640px) {
  .sportwtf-league-tab-bar--with-ko-pred {
    flex-direction: column;
    align-items: stretch;
  }

  .sportwtf-league-tab-bar--with-ko-pred .sportwtf-league-ko-tab-pred {
    margin-left: 0;
    justify-content: center;
  }

  .sportwtf-league-ko-bracket-wrap {
    display: flex;
    flex-direction: column;
  }

  /* Боковые рейлы на телефоне не используем — прогнозы вынесены под каждый матч */
  .sportwtf-league-ko-pred-rail {
    display: none !important;
  }
}

@media (min-width: 641px) {
  /*
   * Важно: align-items: start — иначе колонки рейлов растягиваются по высоте сетки, а блоки прогнозов
   * остаются у верхнего края и визуально «отрываются» от нижних пар.
   */
  .sportwtf-league-ko-bracket-wrap {
    grid-template-columns: minmax(7.25rem, 10rem) minmax(0, 1fr) minmax(7.25rem, 10rem);
    gap: 0.35rem 0.5rem;
    align-items: start;
  }

  .sportwtf-league-ko-cols--with-pred-rails {
    align-self: start;
  }

  .sportwtf-league-ko-pred-inline {
    display: none !important;
  }

  /*
   * Рейлы: одна строка на команду — лого + 3 буквы + %.
   * padding-top ≈ высота .sportwtf-league-ko-card-head + верхний отступ у .sportwtf-league-ko-card-link,
   * чтобы ряды прогноза сошлись по вертикали с рядами команд у карточки пары.
   */
  .sportwtf-league-ko-pred-rail {
    gap: 3.9rem;
    /* +0.9rem: компенсация margin/padding первой строки после .sportwtf-league-ko-card-head */
    padding-top: 3.25rem;
  }

  .sportwtf-league-ko-pred-rail .sportwtf-pred-card--league-ko {
    align-items: stretch;
  }

  .sportwtf-league-ko-pred-rail .sportwtf-pred-card--league-ko .sportwtf-pred-card-main {
    flex: 1 1 auto;
    min-width: 0;
    justify-content: center;
    padding: 0.32rem 0.28rem;
    border-right: 1px solid var(--sportwtf-border);
  }

  .sportwtf-league-ko-pred-rail .sportwtf-pred-card--league-ko .sportwtf-pred-card-row {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 0.2rem;
    padding: 0.18rem 0;
  }

  .sportwtf-league-ko-pred-rail .sportwtf-pred-card--league-ko .sportwtf-pred-card-row + .sportwtf-pred-card-row {
    margin-top: 0.2rem;
    padding-top: 0.35rem;
  }

  .sportwtf-league-ko-pred-rail .sportwtf-pred-card--league-ko .sportwtf-pred-card-team {
    flex-direction: row;
    align-items: center;
    gap: 0.28rem;
    min-width: 0;
    flex: 1 1 auto;
  }

  .sportwtf-league-ko-pred-rail .sportwtf-pred-card--league-ko .sportwtf-pred-card-logo {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
  }

  .sportwtf-league-ko-pred-rail .sportwtf-pred-card--league-ko .sportwtf-pred-card-code {
    font-size: 0.62rem;
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: 0.02em;
    color: var(--sportwtf-black);
    flex-shrink: 0;
  }

  .sportwtf-league-ko-pred-rail .sportwtf-pred-card--league-ko .sportwtf-pred-card-pct {
    font-size: 0.65rem;
    font-weight: 700;
    line-height: 1.1;
    flex-shrink: 0;
    text-align: right;
  }

  .sportwtf-league-ko-pred-rail .sportwtf-pred-card--league-ko .sportwtf-pred-card-draw {
    flex: 0 0 2.65rem;
    min-width: 0;
    padding: 0.28rem 0.22rem;
  }

  .sportwtf-league-ko-pred-rail .sportwtf-pred-card--league-ko .sportwtf-pred-card-draw-label {
    font-size: 0.52rem;
  }

  .sportwtf-league-ko-pred-rail .sportwtf-pred-card--league-ko .sportwtf-pred-card-draw-pct {
    font-size: 0.72rem;
  }
}

.sportwtf-league-knockout {
  background: #fff;
}

.sportwtf-league-knockout-round-title {
  text-align: center;
  font-size: 1rem;
  margin-bottom: 0.85rem;
}

.sportwtf-league-knockout .sportwtf-league-ko-cols {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.sportwtf-league-knockout .sportwtf-league-ko-col {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.sportwtf-league-ko-card {
  margin: 0;
  border: 1px solid var(--sportwtf-border);
  border-radius: 8px;
  background: #fff;
  overflow: hidden;
}

.sportwtf-league-ko-card-head {
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--sportwtf-grey);
  padding: 0.35rem 0.65rem 0.25rem;
  border-bottom: 1px solid var(--sportwtf-border);
  background: #fff;
}

/* Воздух под линией шапки (дата) — как между двумя строками команд */
.sportwtf-league-ko-card-head + .sportwtf-league-ko-row {
  margin-top: 0.45rem;
  padding-top: 0.45rem;
}

.sportwtf-league-ko-card--wide-text .sportwtf-league-ko-name {
  white-space: normal;
  line-height: 1.25;
  font-weight: 400;
}

.sportwtf-league-ko-card-link {
  display: block;
  padding: 0.55rem 0.65rem;
  color: inherit;
  text-decoration: none;
}

/* Двухматчевая карточка: два числа справа — без прилипания к рамке */
.sportwtf-league-ko-card--tie .sportwtf-league-ko-card-link {
  padding-right: 0.95rem;
}

.sportwtf-league-ko-card-link:hover .sportwtf-league-ko-name {
  color: var(--sportwtf-blue);
}

.sportwtf-league-ko-row {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.8rem;
  line-height: 1.35;
  color: var(--sportwtf-black);
}

.sportwtf-league-ko-row + .sportwtf-league-ko-row {
  border-top: 1px solid var(--sportwtf-border);
  margin-top: 0.45rem;
  padding-top: 0.45rem;
}

.sportwtf-league-ko-crest {
  width: 20px;
  height: 20px;
  object-fit: contain;
  border-radius: 50%;
  flex-shrink: 0;
}

.sportwtf-league-knockout .sportwtf-league-ko-crest.sportwtf-standings-logo {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  object-fit: contain;
}

.sportwtf-league-ko-crest--ph {
  display: inline-block;
  box-sizing: border-box;
  width: 20px;
  height: 20px;
  min-width: 20px;
  border-radius: 50%;
  background: linear-gradient(145deg, #e8e8e8 0%, #d4d4d4 100%);
  border: 1px solid var(--sportwtf-border);
}

.sportwtf-league-ko-name {
  flex: 1;
  min-width: 0;
  font-weight: 400;
  color: var(--sportwtf-black);
}

.sportwtf-league-knockout .sportwtf-league-ko-row .sportwtf-standings-team-text {
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--sportwtf-black);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sportwtf-league-ko-card--wide-text .sportwtf-league-ko-row .sportwtf-standings-team-text {
  white-space: normal;
}

.sportwtf-league-ko-meta {
  flex-shrink: 0;
  min-width: 1.15rem;
  text-align: right;
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--sportwtf-grey);
  font-variant-numeric: tabular-nums;
}

/* Двухматчевая: один вес/кегль со строкой (название и счёт как у конкурента) */
.sportwtf-league-ko-meta--tie-inline {
  display: inline-flex;
  flex-direction: row;
  align-items: center;
  flex-shrink: 0;
  gap: 0.45em;
  font: inherit;
  font-variant-numeric: tabular-nums;
  line-height: inherit;
  color: inherit;
  text-align: right;
  min-width: 0;
}

.sportwtf-league-ko-meta--tie-inline .sportwtf-league-ko-meta-leg {
  font: inherit;
  color: inherit;
  text-align: right;
}

.sportwtf-league-ko-meta--goal {
  font-weight: 400;
  font-size: 0.8rem;
  color: var(--sportwtf-black);
}

/* Двухматчевая стыковка (legacy разметка): два счёта/даты */
.sportwtf-league-ko-meta--pair {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  font-variant-numeric: tabular-nums;
}

.sportwtf-league-ko-meta--pair .sportwtf-league-ko-meta-cell {
  min-width: 1.35rem;
  text-align: right;
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--sportwtf-grey);
}

.sportwtf-league-ko-meta--pair .sportwtf-league-ko-meta-cell--goal {
  color: var(--sportwtf-black);
}

@media (max-width: 640px) {
  .sportwtf-league-ko-meta--tie-inline {
    flex-direction: column;
    align-items: flex-end;
    gap: 0.08rem;
    line-height: 1.2;
  }

  .sportwtf-league-ko-meta--desktop-pair {
    flex-direction: column;
    align-items: flex-end;
    gap: 0.08rem;
    line-height: 1.15;
  }
}

@media (min-width: 641px) {
  .sportwtf-league-ko-meta--desktop-pair {
    flex-direction: row;
    gap: 0.55rem;
  }
}

/* Проигравший — чуть светлее (текст/счёт одним тоном, без «выцветания» герба) */
.sportwtf-league-knockout .sportwtf-league-ko-row--muted {
  color: #5a5a5a;
}

.sportwtf-league-knockout .sportwtf-league-ko-row--muted .sportwtf-league-ko-name,
.sportwtf-league-knockout .sportwtf-league-ko-row--muted .sportwtf-standings-team-text {
  color: inherit;
}

.sportwtf-league-knockout .sportwtf-league-ko-row--muted .sportwtf-league-ko-meta {
  color: inherit;
}

.sportwtf-league-knockout .sportwtf-league-ko-row--muted .sportwtf-league-ko-meta--pair .sportwtf-league-ko-meta-cell,
.sportwtf-league-knockout .sportwtf-league-ko-row--muted .sportwtf-league-ko-meta--pair .sportwtf-league-ko-meta-cell--goal {
  color: inherit;
}

@media (min-width: 641px) {
  .sportwtf-league-knockout .sportwtf-league-ko-cols--bracket {
    gap: 1.5rem 2.75rem;
  }

  .sportwtf-league-knockout .sportwtf-league-ko-cols {
    flex-direction: row;
    align-items: flex-start;
    justify-content: center;
    gap: 1.5rem 2rem;
  }

  .sportwtf-league-knockout .sportwtf-league-ko-col {
    flex: 1;
    max-width: 22rem;
  }

  .sportwtf-league-knockout .sportwtf-league-ko-col--left {
    align-items: flex-end;
  }

  .sportwtf-league-knockout .sportwtf-league-ko-col--right {
    align-items: flex-start;
  }

  .sportwtf-league-knockout .sportwtf-league-ko-col--left .sportwtf-league-ko-card {
    width: 100%;
  }

  .sportwtf-league-knockout .sportwtf-league-ko-col--right .sportwtf-league-ko-card {
    width: 100%;
  }

  /* Плей-офф: локальные «ветки» между двумя стыками в половине сетки (десктоп) */
  .sportwtf-league-knockout .sportwtf-league-ko-cols--bracket-tree {
    overflow: visible;
  }

  .sportwtf-league-knockout .sportwtf-league-ko-cols--bracket-tree .sportwtf-league-ko-col {
    gap: 1.4rem;
    overflow: visible;
  }

  .sportwtf-league-knockout .sportwtf-league-ko-cols--bracket-tree .sportwtf-league-ko-bracket-cluster {
    width: 100%;
    max-width: 22rem;
    overflow: visible;
  }

  .sportwtf-league-knockout .sportwtf-league-ko-bracket-cluster {
    --sportwtf-ko-bracket-row-gap: 0.75rem;
    position: relative;
    display: grid;
    grid-template-rows: 1fr 1fr;
    align-items: stretch;
    gap: var(--sportwtf-ko-bracket-row-gap);
    padding-right: 26px;
    min-height: 12rem;
    box-sizing: border-box;
    overflow: visible;
  }

  .sportwtf-league-knockout .sportwtf-league-ko-col--right .sportwtf-league-ko-bracket-cluster {
    padding-right: 0;
    padding-left: 26px;
  }

  .sportwtf-league-knockout .sportwtf-league-ko-bracket-cluster--single {
    grid-template-rows: auto;
    min-height: 0;
  }

  .sportwtf-league-knockout .sportwtf-league-ko-bracket-match {
    position: relative;
    display: flex;
    align-items: stretch;
    min-height: 0;
    overflow: visible;
  }

  .sportwtf-league-knockout .sportwtf-league-ko-bracket-match .sportwtf-league-ko-card {
    width: 100%;
    flex: 1 1 auto;
  }

  /* Горизонталь от правого края карточки к «стойке» кластера (раньше были с right:0 и уходили ВНУТРЬ карточки) */
  .sportwtf-league-knockout .sportwtf-league-ko-col--left .sportwtf-league-ko-bracket-match::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 100%;
    right: auto;
    width: 26px;
    height: 1px;
    background: var(--sportwtf-border);
    transform: translateY(-50%);
    pointer-events: none;
    z-index: 0;
  }

  .sportwtf-league-knockout .sportwtf-league-ko-col--right .sportwtf-league-ko-bracket-match::after {
    content: "";
    position: absolute;
    top: 50%;
    right: 100%;
    left: auto;
    width: 26px;
    height: 1px;
    background: var(--sportwtf-border);
    transform: translateY(-50%);
    pointer-events: none;
    z-index: 0;
  }

  /* Вертикаль ровно между центрами двух матчей (сетка 1fr 1fr + gap), без «хвостов» за горизонталями */
  .sportwtf-league-knockout .sportwtf-league-ko-col--left .sportwtf-league-ko-bracket-cluster:not(.sportwtf-league-ko-bracket-cluster--single)::after {
    content: "";
    position: absolute;
    right: 0;
    top: calc((100% - var(--sportwtf-ko-bracket-row-gap, 0.75rem)) / 4);
    bottom: auto;
    height: calc((100% - var(--sportwtf-ko-bracket-row-gap, 0.75rem)) / 2 + var(--sportwtf-ko-bracket-row-gap, 0.75rem));
    width: 1px;
    background: var(--sportwtf-border);
    pointer-events: none;
    z-index: 0;
  }

  .sportwtf-league-knockout .sportwtf-league-ko-col--right .sportwtf-league-ko-bracket-cluster:not(.sportwtf-league-ko-bracket-cluster--single)::after {
    content: "";
    position: absolute;
    left: 0;
    top: calc((100% - var(--sportwtf-ko-bracket-row-gap, 0.75rem)) / 4);
    bottom: auto;
    height: calc((100% - var(--sportwtf-ko-bracket-row-gap, 0.75rem)) / 2 + var(--sportwtf-ko-bracket-row-gap, 0.75rem));
    width: 1px;
    background: var(--sportwtf-border);
    pointer-events: none;
    z-index: 0;
  }
}

@media (max-width: 640px) {
  .sportwtf-league-knockout .sportwtf-league-ko-bracket-cluster {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding-left: 0 !important;
    padding-right: 0 !important;
    min-height: 0 !important;
  }

  .sportwtf-league-knockout .sportwtf-league-ko-bracket-match {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
  }

  .sportwtf-league-knockout .sportwtf-league-ko-bracket-match::after,
  .sportwtf-league-knockout .sportwtf-league-ko-bracket-cluster::after {
    content: none !important;
  }
}

.sportwtf-match-team-link {
  display: flex;
  flex-direction: column;
  align-items: center;
  color: inherit;
  text-decoration: none;
}

.sportwtf-match-team-link:hover {
  color: var(--sportwtf-blue);
}

.sportwtf-lineup-player-link {
  color: inherit;
  text-decoration: none;
}
.sportwtf-lineup-player-link:hover {
  color: var(--sportwtf-blue);
  text-decoration: underline;
}

/* ========== Player page ========== */
.sportwtf-player-page {
  max-width: 900px;
  margin: 0 auto;
}

.sportwtf-player-hero {
  padding: 1.5rem 1rem;
  margin-bottom: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 1.25rem;
  border: 1px solid var(--sportwtf-border);
  border-radius: 12px;
}

/* Круглое фото как в составах на странице клуба */
.sportwtf-player-page .sportwtf-player-hero-photo {
  width: 150px;
  height: 150px;
  object-fit: cover;
  border-radius: 50%;
  display: block;
  flex-shrink: 0;
}

.sportwtf-player-hero-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 2rem 2.5rem;
  align-items: flex-start;
}

.sportwtf-player-hero-main {
  min-width: 0;
  flex: 1 1 200px;
}

.sportwtf-player-hero-extra {
  min-width: 0;
  flex: 0 1 220px;
}

.sportwtf-player-hero-name {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 0 0.5rem 0;
  color: var(--sportwtf-black);
}

.sportwtf-player-hero-meta {
  margin: 0.25rem 0;
  font-size: 0.95rem;
}

.sportwtf-player-hero-meta-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.sportwtf-player-hero-row {
  display: grid;
  grid-template-columns: 10rem 1fr;
  gap: 0.75rem;
  align-items: center;
  margin: 0;
  padding: 0;
}

/* Подпись параметра — как фамилия на схеме поля */
.sportwtf-player-hero-label {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 500;
  color: #111;
  letter-spacing: 0.02em;
}

/* Значение — как номер на схеме (бейдж) */
.sportwtf-player-hero-value {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--sportwtf-black);
  display: inline-block;
  padding: 0.15rem 0.4rem;
  background: rgba(0, 0, 0, 0.06);
  border-radius: 2px;
}

.sportwtf-player-hero-value .sportwtf-player-link {
  color: var(--sportwtf-accent);
  background: none;
  padding: 0;
}

/* Мобильная версия: блок с фото и инфой игрока */
@media (max-width: 640px) {
  .sportwtf-player-hero {
    flex-direction: column;
    align-items: center;
    padding: 1.25rem 1rem;
    gap: 1rem;
    text-align: center;
  }

  .sportwtf-player-page .sportwtf-player-hero-photo {
    width: 120px;
    height: 120px;
  }

  .sportwtf-player-hero-info {
    width: 100%;
    flex-direction: column;
    gap: 1.25rem;
    text-align: left;
  }

  .sportwtf-player-hero-main,
  .sportwtf-player-hero-extra {
    flex: 1 1 100%;
    width: 100%;
  }

  .sportwtf-player-hero-name {
    text-align: center;
    font-size: 1.35rem;
  }

  .sportwtf-player-hero-main .sportwtf-player-hero-meta:first-of-type {
    text-align: center;
  }
}

.sportwtf-player-hero-flag {
  vertical-align: middle;
  border-radius: 2px;
  margin-right: 0.35rem;
  object-fit: cover;
}

.sportwtf-player-hero-team-logo {
  vertical-align: middle;
  margin-right: 0.35rem;
}

.sportwtf-player-link {
  color: var(--sportwtf-blue);
  text-decoration: none;
}
.sportwtf-player-link:hover {
  text-decoration: underline;
}

.sportwtf-player-section {
  margin-bottom: 1.5rem;
  padding: 1rem 0;
}

.sportwtf-player-section-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin: 0 0 0.75rem 0;
  color: var(--sportwtf-black);
}

.sportwtf-player-stats-wrap {
  overflow-x: auto;
}

.sportwtf-player-stats-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.sportwtf-player-stats-table th,
.sportwtf-player-stats-table td {
  padding: 0.5rem 0.75rem;
  text-align: left;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-player-stats-table th:nth-child(n+2) {
  text-align: center;
  min-width: 3rem;
}

.sportwtf-player-stats-table td:nth-child(n+2) {
  text-align: center;
  min-width: 3rem;
}

.sportwtf-player-stats-table th {
  font-weight: 600;
  color: var(--sportwtf-grey);
}

.sportwtf-player-stats-league {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  text-decoration: none;
  color: inherit;
}

.sportwtf-player-stats-league:hover {
  color: var(--sportwtf-accent);
}

.sportwtf-player-stats-league-logo {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  object-fit: contain;
  vertical-align: middle;
}

.sportwtf-player-match-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.sportwtf-player-match-item {
  margin-bottom: 0.5rem;
}

.sportwtf-player-match-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.6rem 0.75rem;
  text-decoration: none;
  color: inherit;
  border-radius: 8px;
  transition: background 0.2s;
}

.sportwtf-player-match-link:hover {
  background: #f3f4f6;
}

.sportwtf-player-match-teams {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.sportwtf-player-match-teams img {
  flex-shrink: 0;
}

.sportwtf-player-match-score {
  font-weight: 600;
  flex-shrink: 0;
}

.sportwtf-player-analytics {
  margin: 0.75rem 0 0;
  font-size: 0.9rem;
  color: var(--sportwtf-grey);
  line-height: 1.5;
}

.sportwtf-player-seo .sportwtf-player-seo-text {
  margin: 0;
  font-size: 0.95rem;
  color: var(--sportwtf-grey);
  line-height: 1.6;
}

.sportwtf-team-squad-card-link {
  text-decoration: none;
  color: inherit;
  display: block;
}
.sportwtf-team-squad-card-link:hover .sportwtf-team-squad-card {
  border-color: var(--sportwtf-blue);
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

@media (max-width: 640px) {
  .sportwtf-match-lineups-grid,
  .sportwtf-match-stats-grid {
    grid-template-columns: 1fr;
  }
}

/* No matches / Error */
.sportwtf-no-matches,
.sportwtf-error {
  background: var(--sportwtf-bg-panel);
  padding: 2rem;
  border-radius: 8px;
  text-align: center;
  color: var(--sportwtf-grey);
}

.sportwtf-error {
  color: #b91c1c;
}

/* ========== Footer ========== */
.sportwtf-footer {
  margin-top: 2rem;
  padding: 1.5rem 1rem;
  text-align: center;
  font-size: 0.85rem;
  color: var(--sportwtf-grey);
  border-top: 1px solid var(--sportwtf-border);
}

.sportwtf-footer a {
  color: var(--sportwtf-blue);
  text-decoration: none;
}

.sportwtf-footer a:hover {
  text-decoration: underline;
}

/* ========== Mobile: структура в стиле LiveScore, в наших цветах ========== */
@media (max-width: 640px) {
  .sportwtf-date-tabs {
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    padding: 0.75rem 0.5rem;
    gap: 0.35rem;
    margin-bottom: 1rem;
  }

  .sportwtf-tab {
    flex-shrink: 0;
    padding: 0.4rem 0.6rem;
    font-size: 0.8rem;
  }

  .sportwtf-date-picker-wrap {
    flex-shrink: 0;
    min-width: auto;
  }

  .sportwtf-date-picker-display {
    display: none;
  }

  .sportwtf-date-picker-btn-wrap {
    padding: 0.35rem;
    min-width: 44px;
    min-height: 44px;
    justify-content: center;
  }

  .sportwtf-fixtures-head {
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.45rem;
    margin-bottom: 0.55rem;
    padding-bottom: 0.35rem;
  }

  .sportwtf-fixtures-head .sportwtf-section-title {
    flex: 1 1 auto;
    min-width: 0;
    width: auto;
    font-size: 1.02rem;
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .sportwtf-pred-toggle {
    flex-shrink: 0;
    width: auto;
    justify-content: flex-end;
    margin-top: 0;
    gap: 0.35rem;
  }

  .sportwtf-pred-toggle-caption {
    font-size: 0.8rem;
  }

  /* Лига: компактный заголовок */
  .sportwtf-league {
    border-radius: 12px;
    margin-bottom: 1rem;
    overflow: visible;
    box-shadow: 0 1px 4px rgba(0,0,0,0.06);
  }

  .sportwtf-league-header {
    padding: 0.75rem 1rem;
    border-radius: 12px 12px 0 0;
    font-size: 0.95rem;
  }

  .sportwtf-league-logo {
    width: 28px;
    height: 28px;
  }

  /* Список матчей: без карточек, тонкая серая полоска между матчами */
  .sportwtf-matches {
    padding: 0 0.5rem 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 0;
  }

  .sportwtf-match {
    border-radius: 0;
    box-shadow: none;
    background: transparent;
    border-bottom: 1px solid var(--sportwtf-border);
  }

  .sportwtf-match--with-prediction {
    flex-direction: column;
    align-items: stretch;
  }

  .sportwtf-match--with-prediction .sportwtf-pred-card {
    max-width: none;
    width: 100%;
    margin: 0 0.5rem 0.65rem;
    align-self: stretch;
    box-sizing: border-box;
  }

  .sportwtf-match:last-child {
    border-bottom: none;
  }

  .sportwtf-match-link {
    display: block;
    padding: 0;
    border-radius: 0;
  }

  .sportwtf-match-link:hover {
    background: var(--sportwtf-bg-subtle);
  }

  /* Мобилка: обёртка не участвует в сетке, дети — в гриде */
  .sportwtf-match-center {
    display: contents;
  }

  /* Мобилка: команды и счёт; бейдж статуса не используем */
  .sportwtf-match-teams {
    grid-template-columns: 1fr auto auto;
    grid-template-rows: auto auto;
    gap: 0.25rem 0.75rem;
    padding: 0.75rem 1rem;
    align-items: center;
    min-height: 0;
  }

  .sportwtf-team-home {
    grid-row: 1;
    grid-column: 1;
    justify-content: flex-start;
    justify-self: start;
  }

  .sportwtf-team-home::after {
    display: none;
  }

  .sportwtf-team-away {
    grid-row: 2;
    grid-column: 1;
    justify-content: flex-start;
    justify-self: start;
  }

  .sportwtf-status-badge {
    display: none;
  }

  .sportwtf-time {
    display: none;
  }

  /* Один счёт/время (для NS и лайва) по центру справа */
  .sportwtf-score {
    grid-row: 1 / -1;
    grid-column: 3;
    justify-self: end;
    align-self: center;
    min-width: 2.5rem;
    font-size: 0.95rem;
    color: var(--sportwtf-black);
  }

  /* Два счёта напротив команд (завершённые матчи) */
  .sportwtf-score-home {
    grid-row: 1;
    grid-column: 3;
    justify-self: end;
    min-width: 1.5rem;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--sportwtf-black);
  }

  .sportwtf-score-home::after {
    content: none;
  }

  .sportwtf-score-away {
    grid-row: 2;
    grid-column: 3;
    justify-self: end;
    min-width: 1.5rem;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--sportwtf-black);
  }

  .sportwtf-team {
    min-width: 0;
    font-size: 0.875rem;
    align-items: center;
    gap: 0.4rem;
  }

  .sportwtf-team-name {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
  }

  .sportwtf-team img {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
  }
}

/* ========== Tablet & Up ========== */
@media (min-width: 641px) {
  .sportwtf-header {
    padding: 1rem 1.5rem;
  }

  .sportwtf-logo-img {
    height: 44px;
  }

  .sportwtf-main {
    padding: 1.5rem 1.5rem;
  }

  .sportwtf-section-title {
    font-size: 1.5rem;
  }

  /* Десктоп: хозяева | счёт по центру | гости */
  .sportwtf-match-teams {
    grid-template-columns: 1fr minmax(6rem, auto) 1fr;
    grid-template-rows: auto;
    gap: 0 1rem;
    padding: 1rem 1.25rem;
    align-items: center;
    justify-items: center;
  }

  .sportwtf-team-home {
    grid-column: 1;
    grid-row: 1;
    justify-self: end;
  }

  .sportwtf-team-away {
    grid-column: 3;
    grid-row: 1;
    justify-self: start;
  }

  .sportwtf-match-center {
    grid-column: 2;
    grid-row: 1;
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-width: 0;
  }

  .sportwtf-score,
  .sportwtf-score-home,
  .sportwtf-score-away {
    min-width: auto;
    white-space: nowrap;
    overflow: visible;
    line-height: 1.2;
  }

  .sportwtf-score-home,
  .sportwtf-score-away {
    display: inline;
  }

  .sportwtf-status-badge,
  .sportwtf-time {
    margin-top: 0;
  }

  .sportwtf-team-name {
    font-size: 0.95rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
}

@media (min-width: 768px) {
  .sportwtf-match-teams {
    gap: 0.4rem 1.25rem;
  }

  .sportwtf-score,
  .sportwtf-score-home,
  .sportwtf-score-away {
    font-size: 1.1rem;
  }
}

/* ========== Страница новости (шаблон football-news-article) ========== */
.sportwtf-article-main {
  max-width: 1100px;
  margin: 0 auto;
  padding: 1rem 1.25rem 2rem;
}

.sportwtf-article-layout {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 1.5rem 2rem;
}

/* Страница лиги: таблица слева, новости справа (те же классы колонок, что у статьи) */
.sportwtf-league-with-sidebar.sportwtf-article-layout {
  width: 100%;
}

.sportwtf-league-layout-main {
  flex: 1 1 0;
  min-width: 0;
}

/* Правая колонка лиги: новости + блок «Статистика» под ними */
.sportwtf-league-sidebar-col {
  flex: 0 0 320px;
  width: 100%;
  max-width: 350px;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.sportwtf-league-sidebar-col .sportwtf-article-sidebar {
  flex: 0 0 auto;
  max-width: 100%;
}

.sportwtf-league-sidebar-col .sportwtf-stats-widget {
  max-width: 100%;
}

.sportwtf-league-sidebar-stats.sportwtf-league-section {
  padding-left: 0.75rem;
  padding-right: 0.75rem;
}

@media (min-width: 901px) {
  .sportwtf-league-sidebar-col .sportwtf-stats-widget-tabbar {
    flex-wrap: nowrap;
    gap: 0.3rem;
  }

  .sportwtf-league-sidebar-col .sportwtf-stats-widget-tab {
    flex: 1 1 0;
    min-width: 0;
    padding: 0.4rem 0.45rem;
    font-size: 0.75rem;
    white-space: nowrap;
  }
}

.sportwtf-article-page {
  flex: 1 1 0;
  min-width: 0;
  max-width: 720px;
}

.sportwtf-article-header {
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--sportwtf-border);
}

.sportwtf-article-title {
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.25;
  margin: 0 0 0.5rem;
  color: var(--sportwtf-black);
}

.sportwtf-article-meta {
  margin: 0;
  font-size: 0.875rem;
  color: var(--sportwtf-grey);
}

.sportwtf-article-body {
  font-size: 1rem;
  line-height: 1.65;
  color: var(--sportwtf-black);
}

.sportwtf-article-body p {
  margin: 0 0 1rem;
}

.sportwtf-article-body p:last-child {
  margin-bottom: 0;
}

/* Боковая колонка «Новости» на странице статьи (ArticlesSidebar) */
.sportwtf-article-sidebar {
  flex: 0 0 260px;
  width: 100%;
  max-width: 300px;
  min-width: 0;
}

.sportwtf-article-sidebar-title {
  margin: 0 0 0.75rem;
  font-size: 1rem;
  font-weight: 700;
  color: var(--sportwtf-black);
  line-height: 1.2;
}

.sportwtf-article-sidebar-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.sportwtf-article-sidebar-item {
  margin: 0 0 1rem;
  padding: 0;
}

.sportwtf-article-sidebar-item:last-child {
  margin-bottom: 0;
}

.sportwtf-article-sidebar-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.5rem;
  margin-bottom: 0.3rem;
  font-size: 0.75rem;
  color: var(--sportwtf-grey);
  line-height: 1.3;
}

.sportwtf-article-sidebar-time {
  white-space: nowrap;
}

.sportwtf-article-sidebar-more {
  margin: 0.75rem 0 0;
  font-size: 0.9rem;
}

.sportwtf-article-sidebar-more-link {
  color: var(--sportwtf-blue);
  text-decoration: none;
  font-weight: 500;
}

.sportwtf-article-sidebar-more-link:hover {
  text-decoration: underline;
}

.sportwtf-article-sidebar-link {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--sportwtf-black);
  text-decoration: none;
}

.sportwtf-article-sidebar-link:hover {
  color: var(--sportwtf-accent);
}

@media (max-width: 900px) {
  .sportwtf-article-layout {
    flex-direction: column;
  }

  /* колонка лиги/статьи — иначе дочерний блок (лента туров) раздувает ширину окна */
  .sportwtf-article-main {
    min-width: 0;
    max-width: 100%;
    overflow-x: hidden;
  }

  .sportwtf-article-page {
    max-width: 100%;
    min-width: 0;
    overflow-x: hidden;
  }

  .sportwtf-wrapper {
    overflow-x: hidden;
  }

  .sportwtf-article-sidebar {
    flex: 1 1 auto;
    max-width: 100%;
    padding-top: 1rem;
    border-top: 1px solid var(--sportwtf-border);
  }

  .sportwtf-league-sidebar-col {
    flex: 1 1 auto;
    max-width: 100%;
  }

  /*
   * Статья + сайдбар (новости), хаб/SEO прогнозов: сочетание flex: 1 1 0 у .sportwtf-article-page
   * и overflow-x: hidden на .sportwtf-article-main на узких экранах давало «пустой» столбец статьи
   * (Chrome / WebKit): текст в DOM, но блок без высоты — на экране остаётся только «Новости».
   */
  .sportwtf-article-layout > .sportwtf-article-page {
    flex: 0 1 auto;
    width: 100%;
    align-self: stretch;
    overflow-x: visible;
  }

  .sportwtf-article-main:has(.sportwtf-article-layout) {
    overflow-x: visible;
    overflow-y: visible;
  }
}

/* Карточка матча «билет» над текстом новости (ArticleMatchTicket) */
.sportwtf-article-ticket {
  margin: 0 0 1.5rem;
  position: relative;
}

.sportwtf-article-ticket-inner {
  position: relative;
  background: var(--sportwtf-bg-subtle);
  border: 1px solid #d0d0d0;
  border-radius: 14px;
  padding: 1rem 1.25rem 1rem;
  overflow: visible;
}

.sportwtf-article-ticket-meta {
  margin: 0 0 0.35rem;
  font-size: 0.8125rem;
  font-weight: 600;
  text-align: center;
  color: var(--sportwtf-grey);
  letter-spacing: 0.02em;
}

.sportwtf-article-ticket-sub {
  margin: 0 0 1rem;
  font-size: 0.8125rem;
  text-align: center;
  color: var(--sportwtf-grey-light);
}

.sportwtf-article-ticket-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.sportwtf-article-ticket-team {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.5rem;
}

.sportwtf-article-ticket-team--away .sportwtf-article-ticket-name {
  font-weight: 600;
}

.sportwtf-article-ticket-logo {
  width: 56px;
  height: 56px;
  object-fit: contain;
  border-radius: 50%;
  background: transparent;
  border: none;
  outline: none;
  box-shadow: none;
}

.sportwtf-article-ticket-name {
  font-size: 0.8125rem;
  line-height: 1.25;
  color: var(--sportwtf-black);
  word-break: break-word;
}

.sportwtf-article-ticket-center {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  min-width: 7rem;
}

.sportwtf-article-ticket-status {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--sportwtf-grey);
}

.sportwtf-article-ticket-scorebox {
  background: linear-gradient(180deg, #1a3355 0%, var(--sportwtf-accent) 100%);
  color: #fff;
  border-radius: 10px;
  padding: 0.4rem 0.85rem;
  min-width: 5.5rem;
  text-align: center;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.sportwtf-article-ticket-score {
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: 0.04em;
}

.sportwtf-article-ticket-score--muted {
  opacity: 0.85;
  font-weight: 600;
}

.sportwtf-article-ticket-ht {
  font-size: 0.6875rem;
  color: var(--sportwtf-grey);
}

.sportwtf-article-ticket-footer {
  position: relative;
  margin-top: 1rem;
  padding: 0 0 0.65rem;
  border-top: none;
  text-align: center;
}

/* Пунктир короче ширины блока — отступы слева/справа как на референсе */
.sportwtf-article-ticket-footer::before {
  content: '';
  display: block;
  width: calc(100% - 2.5rem);
  max-width: 100%;
  margin: 0 auto 0.75rem;
  border-top: 1px dashed #c8c8c8;
}

/* «Пробивные» кружки по центру высоты билета; по горизонтали — середина боковой рамки */
.sportwtf-article-ticket-stub-notch {
  position: absolute;
  top: 50%;
  width: 22px;
  height: 22px;
  margin-top: 0;
  border-radius: 50%;
  background: var(--sportwtf-bg);
  z-index: 2;
  pointer-events: none;
  box-sizing: border-box;
}

.sportwtf-article-ticket-stub-notch--left {
  left: 0;
  transform: translate(calc(-50% - 0.5px), -50%);
}

.sportwtf-article-ticket-stub-notch--right {
  right: 0;
  transform: translate(calc(50% + 0.5px), -50%);
}

.sportwtf-article-ticket-link {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--sportwtf-accent);
  text-decoration: none;
}

.sportwtf-article-ticket-link:hover {
  color: var(--sportwtf-accent-hover);
  text-decoration: underline;
}

@media (max-width: 480px) {
  .sportwtf-article-ticket {
    margin-bottom: 1rem;
  }

  .sportwtf-article-ticket-inner {
    padding: 0.6rem 0.85rem 0.65rem;
  }

  .sportwtf-article-ticket-meta {
    margin-bottom: 0.25rem;
  }

  .sportwtf-article-ticket-sub {
    margin-bottom: 0.55rem;
  }

  /* Одна строка: две равные колонки под эмблемы + центр со счётом — без wrap/order, чтобы лого не «плыли» */
  .sportwtf-article-ticket-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: start;
    justify-items: center;
    column-gap: 0.3rem;
    row-gap: 0.15rem;
  }

  .sportwtf-article-ticket-team {
    flex: unset;
    min-width: 0;
    width: 100%;
    max-width: 100%;
    gap: 0.35rem;
  }

  .sportwtf-article-ticket-center {
    min-width: 0;
    order: 0;
    margin-bottom: 0;
    gap: 0.25rem;
  }

  .sportwtf-article-ticket-scorebox {
    padding: 0.3rem 0.65rem;
  }

  .sportwtf-article-ticket-score {
    font-size: 1.35rem;
  }

  .sportwtf-article-ticket-logo {
    width: 48px;
    height: 48px;
    flex-shrink: 0;
  }

  .sportwtf-article-ticket-footer {
    margin-top: 0.6rem;
    padding-bottom: 0.45rem;
  }

  .sportwtf-article-ticket-footer::before {
    margin-bottom: 0.5rem;
  }
}

/* ========== Touch-friendly ========== */
@media (hover: none) {
  .sportwtf-match {
    min-height: 48px;
  }

  .sportwtf-nav > a,
  .sportwtf-nav-trigger {
    padding: 0.5rem 1rem;
    min-height: 44px;
    display: flex;
    align-items: center;
  }
}
