/* Reset & Variáveis */
:root {
  --bg-primary: #0C1411; /* Chalk (escuro) */
  --bg-secondary: #16211D; /* Paper (escuro) */
  --bg-tertiary: #1E2B25; /* Medium dark forest green */
  --border-color: #33433C; /* Line (escuro) */
  --text-main: #E8F0EC; /* Light minty grey */
  --text-muted: #9AAAA2; /* Soft (escuro) */
  --accent-blue: #1B9E6B; /* Medium green */
  --accent-green: #1B9E6B; /* Medium green */
  --accent-red: #E5484D; /* Live red */
  --accent-yellow: #F4C430; /* Gold */
  --font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-title: 'Oswald', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --card-shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 10px 30px rgba(0, 0, 0, 0.45);
  --transition: all 0.15s ease-in-out;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-primary);
  color: var(--text-main);
  font-family: var(--font-family);
  line-height: 1.5;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  min-height: 100vh;
  padding: 0 1.5rem 1.5rem 1.5rem; /* Sem padding no topo para colar o header */
}

/* Container do App */
.app-container {
  width: 100%;
  max-width: 1100px;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

/* Header Principal - Estilo Top Idêntico ao Bolão */
.top {
  background: linear-gradient(145deg, #0B1F1A 0%, #0E5C3F 140%);
  color: #fff;
  border-radius: 0 0 22px 22px;
  padding: 26px 28px 24px;
  margin-bottom: 1.5rem;
  position: relative;
  overflow: hidden;
  border: 1px solid var(--border-color);
  border-top: none;
}

.top::after {
  content: "";
  position: absolute;
  right: -60px;
  top: -60px;
  width: 220px;
  height: 220px;
  background: radial-gradient(circle, rgba(27, 158, 107, 0.35), transparent 70%);
}

.top-in {
  position: relative;
  z-index: 1;
  width: 100%;
}

.eyebrow {
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-yellow);
  margin: 0 0 6px;
}

.top h1 {
  font-family: var(--font-title);
  font-size: clamp(28px, 5vw, 44px);
  line-height: 1.02;
  margin: 0;
  text-transform: uppercase;
  color: #fff;
  letter-spacing: 0.02em;
}

.subline {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  align-items: center;
  margin-top: 12px;
  color: #CFE3D9;
  font-size: 13.5px;
}

.subline b {
  color: #fff;
}

.live-flag {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(229, 72, 77, 0.16);
  border: 1px solid rgba(229, 72, 77, 0.5);
  color: #FFD3D4;
  padding: 3px 10px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-red);
  display: inline-block;
  animation: pulse-dot 1.4s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.35;
    transform: scale(0.7);
  }
}

/* Ferramentas do Header (Refresh) */
.top-tools {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 2;
  display: flex;
  gap: 8px;
}

.top-tools button {
  min-width: 42px;
  height: 42px;
  padding: 0 10px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 16px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  transition: var(--transition);
}

.top-tools button:hover {
  background: rgba(255, 255, 255, 0.26);
  border-color: #fff;
}

.top-tools button svg {
  transition: transform 0.3s ease;
}

.top-tools button.loading svg {
  animation: spin 0.7s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Filtros em Container */
.filters-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.filters-bar {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding-bottom: 0.25rem;
}

.select-filters {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.select-wrapper {
  position: relative;
  display: inline-block;
}

.filter-select {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 0.5rem 2rem 0.5rem 1rem;
  border-radius: 9999px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  outline: none;
  appearance: none;
  -webkit-appearance: none;
  transition: var(--transition);
}

.filter-select:hover {
  border-color: var(--text-muted);
}

.filter-select:focus {
  border-color: var(--accent-blue);
}

.select-wrapper::after {
  content: "";
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 5px solid var(--text-muted);
  pointer-events: none;
}

@media (max-width: 767px) {
  .filters-container {
    flex-direction: column;
    align-items: stretch;
  }
  .filters-bar {
    width: 100%;
  }
  .select-filters {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
    width: 100%;
  }
  .select-wrapper {
    width: 100%;
  }
  .filter-select {
    width: 100%;
  }
}

.filter-btn {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: var(--transition);
}

.filter-btn:hover {
  border-color: var(--text-muted);
  color: var(--text-main);
}

.filter-btn.active {
  background: var(--accent-blue);
  color: #fff;
  border-color: var(--accent-blue);
}

.live-dot {
  width: 8px;
  height: 8px;
  background-color: var(--accent-green);
  border-radius: 50%;
  display: inline-block;
}

/* Estados (Loading, Error, Vazio) */
.loading-state, .error-state, .empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 4rem 2rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 1rem;
  gap: 1rem;
}

.hidden {
  display: none !important;
}

.spinner {
  width: 40px;
  height: 40px;
  border: 4px solid var(--border-color);
  border-top-color: var(--accent-blue);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.error-icon {
  font-size: 3rem;
}

.btn-retry, .btn-retry-card {
  background: var(--accent-blue);
  color: #fff;
  border: none;
  padding: 0.5rem 1.25rem;
  border-radius: 0.5rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.btn-retry:hover {
  background: #2563eb;
}

.empty-icon {
  font-size: 3.5rem;
  opacity: 0.4;
}

/* Grid de Partidas */
.matches-grid-container {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

.group-section {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.group-header {
  font-family: var(--font-title);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-main);
  border-left: 4px solid var(--accent-blue);
  padding-left: 0.75rem;
  margin-bottom: 0.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.5rem;
}

.group-header-meta {
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--text-muted);
}

.matches-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

@media (max-width: 768px) {
  .matches-grid {
    grid-template-columns: 1fr;
  }
}

/* Card de Partida - Estilo Idêntico ao Bolão */
.game {
  background: linear-gradient(160deg, #0B1F1A 0%, #16211D 100%);
  color: #fff;
  border-radius: 16px;
  padding: 16px;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid var(--border-color);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  min-height: 310px;
}

/* Se houver conteúdo denso (artilheiros, cartões disciplinares ou o player de transmissão aberto), 
   o card remove a proporção fixa de 16:9 e se expande verticalmente de forma natural e fluida para evitar overflow. */
.game:has(.match-scorers-container),
.game:has(.match-card-cards),
.game:has(.live-stream-player:not(.hidden)) {
  aspect-ratio: auto;
  min-height: 320px;
}

@media (max-width: 480px) {
  .game {
    aspect-ratio: auto;
    min-height: auto;
  }
}

.game:hover {
  transform: translateY(-2px);
  border-color: rgba(27, 158, 107, 0.4);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
}

/* Borda indicativa para jogos ao vivo */
.game.live-card {
  border-color: rgba(229, 72, 77, 0.4);
}
.game.live-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background-color: var(--accent-red);
}

.game-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
  gap: 8px;
}

/* Nova Barra de Confronto (Matchup Bar) Horizontal */
.matchup-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 12px;
  padding: 10px 14px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  margin-bottom: 8px;
}

.team-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  width: 38%;
  text-align: center;
}

.team-block .flag {
  font-size: 24px;
  line-height: 1;
}

.team-block .team-name {
  font-family: var(--font-main);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.match-score-center {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 24%;
}

.match-score-center .score-val {
  font-family: var(--font-title);
  font-size: 22px;
  font-weight: 700;
  color: var(--accent-yellow);
}

.match-score-center .score-val.empty {
  color: var(--text-muted);
}

.match-score-center .vs-divider {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.08);
  padding: 2px 6px;
  border-radius: 4px;
  font-weight: 600;
}

/* Badge de Classificado */
.qualified-badge {
  font-family: var(--font-mono);
  font-size: 8.5px;
  font-weight: 600;
  color: #ffd700;
  background: rgba(255, 215, 0, 0.12);
  border: 1px solid rgba(255, 215, 0, 0.25);
  border-radius: 4px;
  padding: 1px 4px;
  margin-top: 2px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  display: inline-block;
}

/* Cartões Disciplinares (Premium CSS Mini-Cards) Abaixo da Posse de Bola */
.match-card-cards {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(0, 0, 0, 0.25);
  border-radius: 8px;
  padding: 6px 10px;
  font-size: 10px;
  color: #A3C0B3;
  margin-top: 6px;
  border: 1px solid rgba(255, 255, 255, 0.03);
}

.team-cards {
  display: flex;
  flex-direction: column;
  gap: 3.5px;
  width: 45%;
}

.team-cards.home-cards {
  align-items: flex-start;
}

.team-cards.away-cards {
  align-items: flex-end;
}

.cards-separator {
  font-size: 11px;
  opacity: 0.25;
  color: #fff;
  font-weight: 300;
}

.player-card {
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

/* Os cartõezinhos CSS físicos */
.card-mini {
  display: inline-block;
  width: 8px;
  height: 11px;
  border-radius: 1.5px;
  flex-shrink: 0;
}

.card-mini.yellow {
  background-color: #ffd700;
  border: 1px solid #cca100;
  box-shadow: 0 0 6px rgba(255, 215, 0, 0.4);
}

.card-mini.red {
  background-color: #ff3b30;
  border: 1px solid #d32f2f;
  box-shadow: 0 0 6px rgba(255, 59, 48, 0.4);
}

.card-player-name {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.game-meta {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: #9DBBAE;
}

.game-meta .grp {
  color: var(--accent-yellow);
  font-weight: 600;
}

.game-meta .round-label {
  color: #c5e1a5; /* Um verde claro suave e elegante para contraste harmônico */
  font-weight: 500;
}

.badge {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 999px;
  white-space: nowrap;
}

.badge.live {
  background: rgba(229, 72, 77, 0.18);
  color: #FF9C9E;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.badge.post {
  background: rgba(157, 187, 174, 0.16);
  color: #B9D2C6;
}

.badge.pre {
  background: rgba(244, 196, 48, 0.14);
  color: var(--accent-yellow);
}

.team-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 0;
}

.team-row + .team-row {
  border-top: 1px solid rgba(255, 255, 255, 0.07);
}

.flag {
  font-size: 22px;
  width: 26px;
  text-align: center;
  flex: none;
  line-height: 1;
}

.score {
  font-family: var(--font-mono);
  font-weight: 800;
  font-size: 26px;
  color: var(--accent-yellow);
  min-width: 30px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.score.empty {
  color: #3F5249;
}

.source {
  margin-top: 9px;
  font-size: 11px;
  color: #9DBBAE;
  font-family: var(--font-mono);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Card Header */
.match-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding-bottom: 0.75rem;
}

/* Badges de Grupos e Cores Temáticas */
.group-badge {
  font-size: 0.65rem;
  font-weight: 800;
  padding: 0.2rem 0.6rem;
  border-radius: 6px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  display: inline-block;
}

/* Cores específicas de badge e efeitos hover para cada grupo (A a L + Outros) */
.group-badge-a { background-color: rgba(16, 185, 129, 0.12); color: #10b981; border: 1px solid rgba(16, 185, 129, 0.25); }
.group-card-a:hover { border-color: rgba(16, 185, 129, 0.5) !important; box-shadow: 0 0 12px rgba(16, 185, 129, 0.15); }

.group-badge-b { background-color: rgba(59, 130, 246, 0.12); color: #3b82f6; border: 1px solid rgba(59, 130, 246, 0.25); }
.group-card-b:hover { border-color: rgba(59, 130, 246, 0.5) !important; box-shadow: 0 0 12px rgba(59, 130, 246, 0.15); }

.group-badge-c { background-color: rgba(139, 92, 246, 0.12); color: #8b5cf6; border: 1px solid rgba(139, 92, 246, 0.25); }
.group-card-c:hover { border-color: rgba(139, 92, 246, 0.5) !important; box-shadow: 0 0 12px rgba(139, 92, 246, 0.15); }

.group-badge-d { background-color: rgba(236, 72, 153, 0.12); color: #ec4899; border: 1px solid rgba(236, 72, 153, 0.25); }
.group-card-d:hover { border-color: rgba(236, 72, 153, 0.5) !important; box-shadow: 0 0 12px rgba(236, 72, 153, 0.15); }

.group-badge-e { background-color: rgba(249, 115, 22, 0.12); color: #f97316; border: 1px solid rgba(249, 115, 22, 0.25); }
.group-card-e:hover { border-color: rgba(249, 115, 22, 0.5) !important; box-shadow: 0 0 12px rgba(249, 115, 22, 0.15); }

.group-badge-f { background-color: rgba(6, 182, 212, 0.12); color: #06b6d4; border: 1px solid rgba(6, 182, 212, 0.25); }
.group-card-f:hover { border-color: rgba(6, 182, 212, 0.5) !important; box-shadow: 0 0 12px rgba(6, 182, 212, 0.15); }

.group-badge-g { background-color: rgba(245, 158, 11, 0.12); color: #f59e0b; border: 1px solid rgba(245, 158, 11, 0.25); }
.group-card-g:hover { border-color: rgba(245, 158, 11, 0.5) !important; box-shadow: 0 0 12px rgba(245, 158, 11, 0.15); }

.group-badge-h { background-color: rgba(99, 102, 241, 0.12); color: #6366f1; border: 1px solid rgba(99, 102, 241, 0.25); }
.group-card-h:hover { border-color: rgba(99, 102, 241, 0.5) !important; box-shadow: 0 0 12px rgba(99, 102, 241, 0.15); }

.group-badge-i { background-color: rgba(244, 63, 94, 0.12); color: #f43f5e; border: 1px solid rgba(244, 63, 94, 0.25); }
.group-card-i:hover { border-color: rgba(244, 63, 94, 0.5) !important; box-shadow: 0 0 12px rgba(244, 63, 94, 0.15); }

.group-badge-j { background-color: rgba(132, 204, 22, 0.12); color: #84cc16; border: 1px solid rgba(132, 204, 22, 0.25); }
.group-card-j:hover { border-color: rgba(132, 204, 22, 0.5) !important; box-shadow: 0 0 12px rgba(132, 204, 22, 0.15); }

.group-badge-k { background-color: rgba(168, 85, 247, 0.12); color: #a855f7; border: 1px solid rgba(168, 85, 247, 0.25); }
.group-card-k:hover { border-color: rgba(168, 85, 247, 0.5) !important; box-shadow: 0 0 12px rgba(168, 85, 247, 0.15); }

.group-badge-l { background-color: rgba(20, 184, 166, 0.12); color: #14b8a6; border: 1px solid rgba(20, 184, 166, 0.25); }
.group-card-l:hover { border-color: rgba(20, 184, 166, 0.5) !important; box-shadow: 0 0 12px rgba(20, 184, 166, 0.15); }

.group-badge-outros { background-color: rgba(148, 163, 184, 0.1); color: var(--text-muted); border: 1px solid rgba(148, 163, 184, 0.2); }
.group-card-outros:hover { border-color: rgba(148, 163, 184, 0.4) !important; box-shadow: 0 0 12px rgba(148, 163, 184, 0.1); }

.match-status {
  padding: 0.15rem 0.5rem;
  border-radius: 0.25rem;
  font-weight: 800;
}

.match-status.live {
  background: rgba(34, 197, 94, 0.15);
  color: var(--accent-green);
}

.match-status.post {
  background: rgba(148, 163, 184, 0.1);
  color: var(--text-muted);
}

.match-status.pre {
  background: rgba(59, 130, 246, 0.15);
  color: var(--accent-blue);
}

/* Times e Placar */
.match-card-body {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 0;
}

.team-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  width: 35%;
  text-align: center;
}

.team-logo {
  width: 48px;
  height: 48px;
  object-fit: contain;
  background-color: rgba(255, 255, 255, 0.03);
  border-radius: 50%;
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.team-flag {
  font-size: 2.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background-color: rgba(255, 255, 255, 0.03);
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.08);
  line-height: 1;
}

.emoji-icon {
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.match-scorers-container {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  font-size: 0.75rem;
  color: var(--text-muted);
  background-color: rgba(255, 255, 255, 0.015);
  border-top: 1px dashed rgba(255, 255, 255, 0.06);
  border-bottom: 1px dashed rgba(255, 255, 255, 0.06);
  padding: 0.5rem 0.25rem;
  margin-top: -0.25rem;
  margin-bottom: 0.25rem;
  gap: 0.5rem;
}

.home-scorers, .away-scorers {
  width: 42%;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.home-scorers {
  text-align: right;
  align-items: flex-end;
}

.away-scorers {
  text-align: left;
  align-items: flex-start;
}

.scorers-icon {
  width: 16%;
  text-align: center;
  font-size: 0.75rem;
  opacity: 0.4;
  display: flex;
  justify-content: center;
  align-self: center;
}

.scorer-item {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.team-name {
  font-family: var(--font-title);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  font-size: 1.05rem;
  font-weight: 500;
  max-width: 110px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.scoreboard-center {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  width: 30%;
}

.score-display {
  font-family: var(--font-mono);
  font-size: 2.25rem;
  font-weight: 800;
  color: var(--accent-yellow);
  font-variant-numeric: tabular-nums;
  width: 40px;
  text-align: center;
}

.score-divider {
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--text-muted);
  opacity: 0.5;
}

/* Informações do Jogo */
.match-card-info {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.info-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.info-item svg {
  opacity: 0.6;
}

/* Estatísticas */
.match-card-stats {
  background-color: rgba(255, 255, 255, 0.02);
  border-top: 1px dashed var(--border-color);
  padding-top: 0.75rem;
  margin-top: 0.25rem;
}

.stat-row {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  font-size: 0.75rem;
  font-weight: 600;
}

.stat-labels {
  display: flex;
  justify-content: space-between;
  color: var(--text-muted);
}

.stat-title {
  color: var(--text-main);
  text-transform: uppercase;
  font-size: 0.7rem;
  letter-spacing: 0.05em;
}

.stat-bar-container {
  height: 6px;
  background-color: var(--bg-tertiary);
  border-radius: 9999px;
  overflow: hidden;
  display: flex;
}

.stat-bar-left {
  height: 100%;
  background-color: var(--accent-blue);
  transition: width 0.5s ease-out;
}

.stat-bar-right {
  height: 100%;
  background-color: var(--accent-red);
  transition: width 0.5s ease-out;
}

/* Rodapé do App */
.app-footer {
  text-align: center;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-color);
  color: var(--text-muted);
  font-size: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.app-footer strong {
  color: var(--text-main);
}

/* CazéTV Embed Stream */
.cazetv-embed-container {
  margin-top: 0.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  width: 100%;
}

.btn-watch-live {
  background: linear-gradient(135deg, #e11d48, #be123c);
  color: #fff;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  font-weight: 700;
  font-size: 0.8rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: var(--transition);
  box-shadow: 0 4px 6px -1px rgba(225, 29, 72, 0.2);
}

.btn-watch-live:hover {
  background: linear-gradient(135deg, #f43f5e, #e11d48);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px -1px rgba(225, 29, 72, 0.4);
}

.pulse-indicator-small {
  width: 8px;
  height: 8px;
  background-color: #fff;
  border-radius: 50%;
  display: inline-block;
  box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.7);
  animation: pulse-white 1.5s infinite;
}

@keyframes pulse-white {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.7);
  }
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 6px rgba(255, 255, 255, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(255, 255, 255, 0);
  }
}

.live-stream-player {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
  height: 0;
  border-radius: 0.5rem;
  overflow: hidden;
  border: 1px solid var(--border-color);
  background: #000;
}

.live-stream-player iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

/* Banner Hero - Próxima Transmissão */
.hero-banner {
  background: radial-gradient(circle at top right, #1e1b4b, #0f172a);
  border: 1px solid rgba(251, 191, 36, 0.2);
  border-radius: 1.25rem;
  padding: 2rem;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.4), 0 10px 10px -5px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.05);
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 0.5rem;
  position: relative;
  overflow: hidden;
  transition: var(--transition);
}

.hero-banner::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.03) 0%, transparent 100%);
  pointer-events: none;
}

.hero-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  width: 100%;
  max-width: 700px;
  text-align: center;
  z-index: 1;
}

.hero-badge {
  background-color: rgba(251, 191, 36, 0.12);
  color: #fbbf24;
  border: 1px solid rgba(251, 191, 36, 0.25);
  font-size: 0.75rem;
  font-weight: 800;
  padding: 0.35rem 0.85rem;
  border-radius: 9999px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  display: inline-block;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

/* Banner Hero - Slider Rotativo */
.hero-banner {
  background: radial-gradient(circle at top right, #1e1b4b, #0f172a);
  border: 1px solid rgba(251, 191, 36, 0.2);
  border-radius: 1.25rem;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.4), 0 10px 10px -5px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.05);
  display: block;
  margin-bottom: 0.5rem;
  position: relative;
  overflow: hidden;
  transition: var(--transition);
}

/* Faixa deslizante que suporta snap scroll nativo */
.hero-carousel-track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  width: 100%;
  scrollbar-width: none; /* Firefox */
}

.hero-carousel-track::-webkit-scrollbar {
  display: none; /* Chrome/Safari */
}

/* Cada slide ocupa exatamente 100% da largura do banner */
.hero-slide {
  flex: 0 0 100%;
  min-width: 100%;
  scroll-snap-align: start;
  box-sizing: border-box;
  padding: 2.5rem 3.5rem; /* Padding interno para o conteúdo respirar */
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

.hero-slide::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.03) 0%, transparent 100%);
  pointer-events: none;
}

.hero-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  width: 100%;
  max-width: 700px;
  text-align: center;
  z-index: 1;
}

.hero-badge {
  background-color: rgba(251, 191, 36, 0.12);
  color: #fbbf24;
  border: 1px solid rgba(251, 191, 36, 0.25);
  font-size: 0.75rem;
  font-weight: 800;
  padding: 0.35rem 0.85rem;
  border-radius: 9999px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  display: inline-block;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.hero-teams-container {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  width: 100%;
  flex-wrap: wrap;
}

.hero-team {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  min-width: 120px;
}

.hero-flag {
  font-size: 3.5rem;
  line-height: 1;
  filter: drop-shadow(0 10px 8px rgba(0, 0, 0, 0.3));
  transition: transform 0.3s ease;
}

.hero-team:hover .hero-flag {
  transform: scale(1.1);
}

.hero-team-name {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #fff;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
}

.hero-vs {
  font-size: 1.25rem;
  font-weight: 900;
  color: rgba(251, 191, 36, 0.8);
  font-style: italic;
  background: rgba(255, 255, 255, 0.05);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

/* Placar de Jogo em Andamento no Hero */
.hero-score-container {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

.hero-score-val {
  font-size: 3rem;
  font-weight: 900;
  color: #fff;
  text-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
  font-variant-numeric: tabular-nums;
  width: 50px;
  text-align: center;
}

.hero-score-divider {
  font-size: 1.5rem;
  font-weight: 700;
  color: rgba(251, 191, 36, 0.8);
  opacity: 0.7;
}

.hero-meta-info {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  font-size: 0.95rem;
  color: #cbd5e1;
  background-color: rgba(255, 255, 255, 0.03);
  padding: 0.6rem 1.25rem;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.hero-meta-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.hero-meta-icon {
  font-size: 1.1rem;
}

.hero-cta {
  margin-top: 0.5rem;
}

.btn-hero-watch {
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
  color: #0b0f19;
  text-decoration: none;
  padding: 0.75rem 2rem;
  border-radius: 9999px;
  font-weight: 800;
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  box-shadow: 0 10px 15px -3px rgba(245, 158, 11, 0.3);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-hero-watch:hover {
  background: linear-gradient(135deg, #fef08a, #fbbf24);
  transform: translateY(-2px);
  box-shadow: 0 20px 25px -5px rgba(245, 158, 11, 0.4);
}

.btn-hero-watch .pulse-indicator-small {
  background-color: #0b0f19;
  box-shadow: 0 0 0 0 rgba(11, 15, 25, 0.7);
  animation: pulse-dark 1.5s infinite;
}

@keyframes pulse-dark {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(11, 15, 25, 0.7);
  }
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 6px rgba(11, 15, 25, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(11, 15, 25, 0);
  }
}

/* Botões de navegação sobrepostos nas laterais */
.hero-carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #fff;
  font-size: 1.75rem;
  font-weight: bold;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  z-index: 10;
  backdrop-filter: blur(4px);
  user-select: none;
}

.hero-carousel-btn:hover:not(.inactive) {
  background: #fbbf24;
  color: #0b0f19;
  border-color: #fbbf24;
  box-shadow: 0 0 12px rgba(251, 191, 36, 0.5);
}

.hero-carousel-btn.prev {
  left: 1rem;
}

.hero-carousel-btn.next {
  right: 1rem;
}

.hero-carousel-btn.inactive {
  opacity: 0;
  pointer-events: none;
}

/* Ajustes responsivos para dispositivos touch */
@media (max-width: 768px) {
  .hero-carousel-btn {
    display: none; /* Esconde botões no celular para rolagem nativa swipe */
  }
  .hero-slide {
    padding: 2.25rem 1.25rem;
  }
  .hero-flag {
    font-size: 2.75rem;
  }
  .hero-team-name {
    font-size: 1.1rem;
  }
  .hero-meta-info {
    flex-direction: column;
    gap: 0.5rem;
    border-radius: 1rem;
    width: 100%;
  }
  .hero-score-val {
    font-size: 2.25rem;
    width: 35px;
  }
}

/* Filtro de Calendário de Data */
.calendar-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.calendar-input {
  padding-right: 2.25rem !important; /* Espaço para o botão de limpar data */
  color-scheme: dark; /* Garante que o date picker nativo use tema escuro */
}

.btn-clear-date {
  position: absolute;
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.85rem;
  cursor: pointer;
  padding: 0.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  border-radius: 50%;
  width: 20px;
  height: 20px;
  z-index: 5;
}

.btn-clear-date:hover {
  background-color: rgba(255, 255, 255, 0.1);
  color: var(--accent-red);
}

.btn-clear-date.hidden {
  display: none !important;
}
