/* ============================================
   DTSL CHAMPIONS LEAGUE – GLOBAL BACKGROUND
   ============================================ */

/* Full screen background, light (default) – tapi nuansanya tetap malam stadion */
body.champions-league {
  min-height: 100vh;
  background:
    radial-gradient(circle at 10% 0, #1d4ed8 0, transparent 55%),
    radial-gradient(circle at 90% 100%, #8b5cf6 0, transparent 60%),
    radial-gradient(circle at 50% 120%, #0ea5e9 0, transparent 65%),
    #020617;
  color: #e5e7eb;
}

/* Darkmode (kalau toggle global dipakai), makin dalam tapi tetap sama vibe */
body.champions-league.dark {
  background:
    radial-gradient(circle at 5% -5%, #38bdf8 0, transparent 50%),
    radial-gradient(circle at 95% 105%, #a855f7 0, transparent 55%),
    radial-gradient(circle at 50% 20%, rgba(59, 130, 246, 0.35) 0, transparent 60%),
    #020617;
}

/* ============================================
   SHELL & HEADER (ikut struktur liga)
   ============================================ */

.champions-league .liga-shell {
  max-width: 1120px;
  margin: 72px auto 48px;
  padding: 0 18px 40px;
}

.champions-league .liga-header {
  margin-bottom: 18px;
  padding-bottom: 6px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.35);
}

.champions-league .liga-topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  margin-bottom: 10px;
  color: #cbd5f5;
}

.champions-league .liga-back-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 12px;
  text-decoration: none;
  background: rgba(15, 23, 42, 0.6);
  color: #e5e7eb;
  border: 1px solid rgba(148, 163, 184, 0.6);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.9);
}
.champions-league .liga-back-btn:hover {
  background: rgba(37, 99, 235, 0.9);
}

.champions-league .liga-header h1 {
  margin: 0 0 4px;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #eff6ff;
}

.champions-league .liga-sub {
  margin: 0;
  font-size: 13px;
  color: #94a3b8;
}

/* Brand strip: tempat logo parody DTSL Champions League */
.champions-league .liga-brand {
  margin-top: 14px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.champions-league .liga-brand-logo {
  width: 60px;
  height: 60px;
  border-radius: 999px;
  background: radial-gradient(circle at 30% 20%, #ffffff 0, #e5e7eb 40%, #020617 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow:
    0 0 25px rgba(59, 130, 246, 0.7),
    0 0 40px rgba(129, 140, 248, 0.7);
  overflow: hidden;
}

.champions-league .liga-brand-title {
  font-size: 18px;
  font-weight: 700;
  color: #eff6ff;
}
.champions-league .liga-brand-sub {
  font-size: 12px;
  color: #cbd5f5;
}

/* Main blocks */
.champions-league .liga-main {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.champions-league .liga-block {
  background: radial-gradient(circle at top left, rgba(37, 99, 235, 0.45) 0, rgba(15, 23, 42, 0.96) 55%);
  border-radius: 24px;
  padding: 18px 20px 20px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  box-shadow:
    0 20px 60px rgba(0, 0, 0, 0.95),
    0 0 40px rgba(37, 99, 235, 0.45);
}

.champions-league .liga-block-title {
  font-size: 16px;
  font-weight: 600;
  margin: 0 0 10px;
  color: #e5e7eb;
}

/* ============================================
   THEME TOGGLE (boleh dipakai sama)
   ============================================ */

.champions-league #ligaThemeToggle {
  padding: 6px 16px;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  background: linear-gradient(90deg, #38bdf8, #6366f1, #a855f7);
  color: #f9fafb;
  box-shadow: 0 10px 25px rgba(37, 99, 235, 0.9);
}

/* ============================================
   SEEDING INFO / QUALIFIERS
   ============================================ */

.champions-league .cl-qualifiers {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}

.champions-league .cl-qual-card {
  padding: 10px 12px;
  border-radius: 16px;
  background: radial-gradient(circle at top, rgba(15, 23, 42, 0.9) 0, #020617 70%);
  border: 1px solid rgba(148, 163, 184, 0.5);
  font-size: 13px;
  color: #e5e7eb;
}

.champions-league .cl-qual-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #93c5fd;
  margin-bottom: 4px;
}
.champions-league .cl-qual-main {
  font-size: 14px;
  font-weight: 600;
}
.champions-league .cl-qual-sub {
  font-size: 12px;
  color: #9ca3af;
}

/* ============================================
   KNOCKOUT BRACKET
   ============================================ */

/*
  Struktur HTML yang disarankan:
  <div class="cl-bracket">
    <div class="cl-round cl-round-qf"> ... 4 match / 8 slot ... </div>
    <div class="cl-round cl-round-sf"> ... 2 match ... </div>
    <div class="cl-round cl-round-final"> ... 1 match ... </div>
  </div>
*/

.champions-league .cl-bracket {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  align-items: stretch;
  overflow-x: auto;
}

.champions-league .cl-round {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.champions-league .cl-round-title {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #93c5fd;
  margin-bottom: 6px;
}

/* match card */
.champions-league .cl-match {
  position: relative;
  padding: 10px 10px;
  border-radius: 16px;
  background: rgba(15, 23, 42, 0.96);
  border: 1px solid rgba(148, 163, 184, 0.6);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.9);
  font-size: 12px;
}

/* garis penghubung antar round (hanya dekoratif) */
.champions-league .cl-match::before {
  content: "";
  position: absolute;
  top: 50%;
  right: -12px;
  width: 12px;
  height: 1px;
  background: linear-gradient(90deg, rgba(148, 163, 184, 0.1), rgba(148, 163, 184, 0.7));
}
.champions-league .cl-round:last-child .cl-match::before {
  display: none;
}

.champions-league .cl-team {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 0;
}

.champions-league .cl-team + .cl-team {
  border-top: 1px solid rgba(30, 41, 59, 0.9);
}

/* badge peserta: misalnya icon liga Kamis / Monday di sini */
.champions-league .cl-team-badge {
  width: 26px;
  height: 26px;
  border-radius: 999px;
  overflow: hidden;
  background: radial-gradient(circle at 30% 20%, #ffffff 0, #020617 80%);
  box-shadow: 0 0 14px rgba(37, 99, 235, 0.8);
  flex-shrink: 0;
}
.champions-league .cl-team-badge img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.champions-league .cl-team-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.champions-league .cl-team-name {
  font-size: 12px;
  font-weight: 600;
  color: #e5e7eb;
}
.champions-league .cl-team-sub {
  font-size: 11px;
  color: #9ca3af;
}

/* skor */
.champions-league .cl-score {
  font-size: 13px;
  font-weight: 700;
  color: #e5e7eb;
  padding-left: 6px;
}

/* highlight pemenang */
.champions-league .cl-team.win {
  background: radial-gradient(circle at left, rgba(37, 99, 235, 0.5) 0, transparent 70%);
}
.champions-league .cl-team.win .cl-team-name {
  color: #bfdbfe;
}

/* badge “bye” jika top seed langsung masuk SF */
.champions-league .cl-team-bye {
  font-size: 11px;
  font-style: italic;
  color: #e5e7eb;
  opacity: 0.7;
}

/* Final match – tampil sedikit lebih besar */
.champions-league .cl-round-final .cl-match {
  border-width: 1.5px;
  border-color: rgba(129, 140, 248, 0.9);
  box-shadow:
    0 0 25px rgba(56, 189, 248, 0.7),
    0 0 40px rgba(129, 140, 248, 0.9);
}

/* Trophy / champion info di bawah final */
.champions-league .cl-champion-panel {
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 16px;
  background: radial-gradient(circle at top, rgba(37, 99, 235, 0.7) 0, rgba(15, 23, 42, 0.98) 65%);
  border: 1px solid rgba(248, 250, 252, 0.4);
  text-align: center;
  font-size: 13px;
}

.champions-league .cl-champion-title {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: #bfdbfe;
  margin-bottom: 4px;
}

.champions-league .cl-champion-name {
  font-size: 16px;
  font-weight: 700;
  color: #f9fafb;
}

/* ============================================
   MATCH META & TIMELINE
   ============================================ */

.champions-league .cl-match-meta {
  margin-top: 6px;
  font-size: 11px;
  color: #9ca3af;
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

.champions-league .cl-leg-label {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 10px;
  color: #93c5fd;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 960px) {
  .champions-league .cl-bracket {
    grid-template-columns: repeat(3, minmax(260px, 1fr));
  }
}

@media (max-width: 720px) {
  .champions-league .liga-shell {
    margin-top: 64px;
    padding-bottom: 28px;
  }

  .champions-league .cl-bracket {
    grid-template-columns: minmax(260px, 1fr);
  }

  .champions-league .cl-round {
    border-left: 2px solid rgba(30, 64, 175, 0.9);
    padding-left: 10px;
  }
  .champions-league .cl-match::before {
    display: none; /* garis antar round di HP dihilangkan biar ga berantakan */
  }
}

/* ============================================
   EXTRA: VOTE STATUS / INFO BAR (opsional)
   ============================================ */

.champions-league .liga-vote-status {
  display: flex;
  align-items: center;
  gap: 8px 12px;
  padding: 8px 14px;
  margin-top: 12px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(148, 163, 184, 0.7);
  font-size: 0.8rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.9);
}

.champions-league .liga-vote-label {
  font-weight: 600;
  white-space: nowrap;
  color: #bfdbfe;
}

.champions-league .liga-vote-live-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background: linear-gradient(135deg, #38bdf8, #a855f7);
  color: #fff;
}


/* ===============================
   CHAMPIONS BRACKET – CORE STYLE
=============================== */

.cl-bracket {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 24px;
  margin-top: 20px;
}

.cl-round h3 {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 10px;
  text-align: center;
  opacity: 0.85;
}

/* match card */
.cl-match {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 14px;
  padding: 10px;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

/* VS text */
.cl-vs {
  font-size: 11px;
  opacity: 0.6;
}

/* team */
.cl-team {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cl-team img {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: cover;
}

/* text */
.cl-name {
  font-size: 12px;
  font-weight: 600;
}

.cl-league {
  font-size: 10px;
  opacity: 0.6;
}

/* hover */
.cl-team:hover {
  background: rgba(255,255,255,0.08);
}

/* winner */
.cl-team.winner {
  background: linear-gradient(135deg, #ffd54f, #ff9800);
  color: #1a1a1a;
  box-shadow: 0 0 0 2px rgba(255,215,64,0.6);
}

/* empty slot */
.cl-team.empty {
  justify-content: center;
  font-size: 11px;
  opacity: 0.5;
  cursor: default;
}

/* ===============================
   LOSER STATE
=============================== */

.cl-team.loser {
  opacity: 0.35;
  filter: grayscale(0.6);
  cursor: not-allowed;
}

.cl-team.loser:hover {
  background: transparent;
}

/* ===============================
   CHAMPION REVEAL
=============================== */

.cl-champion-panel.revealed {
  background: radial-gradient(
    circle at center,
    rgba(255, 215, 0, 0.35),
    rgba(0,0,0,0.85)
  );
  border-color: rgba(255, 215, 0, 0.7);
  box-shadow:
    0 0 40px rgba(255, 215, 0, 0.6),
    0 0 80px rgba(255, 193, 7, 0.4);
}

.cl-champion-avatar {
  position: relative;
  width: 96px;
  height: 96px;
  margin: 0 auto 10px;
}

.cl-champion-avatar img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid gold;
}

.cl-crown {
  position: absolute;
  top: -10px;
  right: -10px;
  font-size: 28px;
}

.cl-champion-name {
  font-size: 18px;
  font-weight: 700;
  margin-top: 4px;
}

.cl-champion-league {
  font-size: 12px;
  opacity: 0.85;
}


/* ===============================
   PRE-TOURNAMENT MODE
=============================== */

.cl-match.disabled {
  filter: blur(3px);
  opacity: 0.5;
  pointer-events: none;
}

.cl-bracket-note {
  text-align: center;
  margin: 16px 0;
  font-size: 14px;
  font-weight: 600;
  color: rgba(255,255,255,0.85);
  letter-spacing: 0.3px;
}

/* ===============================
   PRE-TOURNAMENT BLUR (FIXED)
=============================== */

.cl-match.disabled {
  filter: blur(3px);
  opacity: 0.4;
  pointer-events: none;
}

/* ===============================
   CHAMPIONS FORMAT / RULES
=============================== */

.cl-rules {
  font-size: 14px;
  line-height: 1.6;
  opacity: 0.9;
}

.cl-rules ul {
  margin: 12px 0;
  padding-left: 20px;
}

.cl-rules li {
  margin-bottom: 6px;
}

.cl-note {
  margin-top: 10px;
  font-size: 13px;
  opacity: 0.75;
  font-style: italic;
}

/* Spacing khusus setelah Format Turnamen */
.liga-block.format-turnamen {
  margin-bottom: 28px;
}


/* ===============================
   CHAMPIONS HERO PARTICIPANTS
=============================== */

.champions-hero {
  text-align: center;
  margin-bottom: 32px;
}

.champions-hero-title {
  font-size: 20px;
  font-weight: 700;
}

.champions-hero-sub {
  font-size: 13px;
  opacity: 0.75;
  margin-bottom: 16px;
}

.champions-hero-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(90px, 1fr));
  gap: 16px;
  max-width: 720px;
  margin: 0 auto;
}

.hero-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.hero-card img {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(255,255,255,0.4);
}

.hero-card span {
  font-size: 12px;
  opacity: 0.9;
}

/* ===============================
   MATCH PREVIEW (PRE)
=============================== */

.match-preview {
  text-align: center;
  padding: 24px;
  border-radius: 14px;
  background: rgba(255,255,255,0.04);
}

.match-preview.disabled {
  filter: blur(1.5px);
  opacity: 0.6;
}

.champions-news {
  font-size: 14px;
  opacity: 0.85;
}

.champions-news li {
  margin-bottom: 6px;
}
