/* ============================================================
   DBC – matches.css  (v2 – 2026 redesign)
   Карточки матчей, коллапсеры, таблица лиги.
   ============================================================ */

/* ══════════════════════════════════════════════════════════
   MATCH CARD
   ══════════════════════════════════════════════════════════ */
.match {
  padding: 11px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: linear-gradient(160deg, #0c1427, #090f1e);
  cursor: pointer;
  display: flex; gap: 12px; align-items: center;
  transition:
    border-color var(--t-fast),
    box-shadow var(--t-normal),
    background var(--t-normal),
    transform var(--t-fast);
  position: relative; overflow: hidden;
}
/* Subtle top glow line on each card */
.match::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.06), transparent);
  pointer-events: none;
}
.match:hover {
  border-color: rgba(65,189,217,.3);
  background: linear-gradient(160deg, #0f1b30, #0c1427);
  box-shadow:
    0 0 0 1px rgba(65,189,217,.08),
    0 8px 32px rgba(0,0,0,.4),
    0 0 20px rgba(65,189,217,.06);
  transform: translateY(-1px);
}
.match:active { transform: translateY(0); }

/* ── team name in match card ── */
.match > div[style*="font-weight:600"] {
  font-family: "DM Sans", system-ui, sans-serif;
  font-weight: 600;
  line-height: 1.3;
}

/* ══════════════════════════════════════════════════════════
   COUNTRY COLLAPSIBLE
   ══════════════════════════════════════════════════════════ */
.countryCollapsible {
  margin: 18px 0;
  border: 1px solid var(--line-hi);
  border-radius: 16px;
  overflow: hidden;
  background: linear-gradient(170deg, #080d1c, #060a17);
  box-shadow: 0 4px 20px rgba(0,0,0,.25);
}
.countryCollapsible > summary {
  list-style: none; cursor: pointer;
  display: flex; align-items: center; gap: 10px;
  padding: 13px 16px;
  border-bottom: 1px solid var(--line);
  font-family: "Roboto Slab", serif;
  font-weight: 900; font-size: 17px;
  color: var(--fg);
  user-select: none;
  transition: background var(--t-fast);
  position: relative;
}
.countryCollapsible > summary::-webkit-details-marker { display: none; }
.countryCollapsible > summary::before {
  content: '›';
  font-size: 20px; font-weight: 400;
  color: var(--muted);
  transition: transform var(--t-normal);
  display: inline-block; line-height: 1;
  margin-right: 2px;
}
.countryCollapsible[open] > summary::before { transform: rotate(90deg); }
.countryCollapsible > summary:hover { background: rgba(255,255,255,.02); }

.countryHeaderMeta {
  margin-left: auto; display: flex; gap: 8px;
  align-items: center; color: var(--muted);
  font-weight: 400; font-size: 13px;
  font-family: "DM Sans", sans-serif;
}
.countryCount {
  background: rgba(13,22,42,.9);
  border: 1px solid var(--line-hi);
  border-radius: 10px; padding: 2px 10px;
  font-size: 11px; font-weight: 700;
  color: #94a3b8; letter-spacing: .3px;
}
.countryInner { padding: 10px 12px; }
.countryInner .leagueCollapsible { margin: 10px 0; }

/* ══════════════════════════════════════════════════════════
   LEAGUE COLLAPSIBLE
   ══════════════════════════════════════════════════════════ */
.leagueCollapsible {
  margin: 12px 0;
  border: 1px solid var(--line);
  border-radius: 13px;
  overflow: hidden;
  background: linear-gradient(160deg, #0a1020, #080e1c);
  transition: border-color var(--t-normal);
}
.leagueCollapsible:hover { border-color: var(--line-hi); }

.leagueCollapsible > summary {
  list-style: none; cursor: pointer;
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
  font-family: "Roboto Slab", serif;
  font-weight: 800; font-size: 14px;
  color: var(--fg);
  user-select: none;
  transition: background var(--t-fast);
}
.leagueCollapsible > summary::-webkit-details-marker { display: none; }
.leagueCollapsible > summary::before {
  content: '›';
  font-size: 17px; font-weight: 400;
  color: var(--subtle);
  transition: transform var(--t-normal);
  display: inline-block; line-height: 1;
}
.leagueCollapsible[open] > summary::before { transform: rotate(90deg); }
.leagueCollapsible > summary:hover { background: rgba(255,255,255,.015); }

.leagueHeaderMeta {
  margin-left: auto; display: flex; gap: 8px;
  align-items: center; color: var(--muted);
  font-weight: 400; font-family: "DM Sans", sans-serif;
}
.leagueCount {
  background: rgba(12,18,40,.9);
  border: 1px solid var(--line-hi);
  border-radius: 8px; padding: 2px 8px;
  font-size: 11px; font-weight: 700;
  color: #7a8aab; letter-spacing: .3px;
}
.leagueCountry { font-size: 11px; color: var(--subtle); letter-spacing: .2px; }

.matchesBucket {
  padding: 10px 12px;
  display: flex; flex-direction: column; gap: 6px;
}

/* ══════════════════════════════════════════════════════════
   LEAGUE TABLE SIDEBAR
   ══════════════════════════════════════════════════════════ */
.leagueTable {
  background: linear-gradient(170deg, #0a1020, #070c1a);
  border: 1px solid var(--line-hi);
  border-radius: 13px;
  padding: 12px;
  color: var(--fg);
  position: relative; overflow: hidden;
}
/* Cyan top glow for the table */
.leagueTable::before {
  content: '';
  position: absolute; top: 0; left: 20px; right: 20px; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(65,189,217,.2), transparent);
  pointer-events: none;
}

.leagueTable table {
  width: 100%; border-collapse: collapse;
  font-size: 12px; font-family: "DM Sans", sans-serif;
}
.leagueTable th {
  font-family: "Roboto Slab", serif;
  font-weight: 700; font-size: 10px; letter-spacing: .6px;
  text-transform: uppercase; color: var(--muted);
  padding: 0 8px 8px; border-bottom: 1px solid var(--line-hi);
}
.leagueTable td {
  padding: 7px 8px;
  border-bottom: 1px solid rgba(22,31,56,.7);
  transition: background var(--t-fast);
}
.leagueTable tbody tr:hover td { background: rgba(255,255,255,.02); }
.leagueTable tbody tr:last-child td { border-bottom: none; }

/* Highlighted rows (selected teams) */
.leagueTable tr.hl td {
  background: rgba(65,189,217,.07);
}
.leagueTable tr.hl td:first-child {
  border-left: 2px solid rgba(65,189,217,.5);
  padding-left: 6px;
}
.leagueTable tr.hl .pts { color: var(--brand1); }

.leagueTable .pos { width: 28px; text-align: right; color: var(--subtle); font-size: 11px; }
.leagueTable .pts { font-weight: 800; text-align: right; font-family: "Roboto Slab", serif; }
