/* =================================================================== */
/* 1. VARIÁVEIS E CONFIGURAÇÕES GERAIS                               */
/* =================================================================== */
:root {
  --cor-primaria: #920000;
  --cor-primaria-escura: #670000;
  --cor-primaria-gradiente: linear-gradient(135deg, #670000, #3f1616);
  --cor-secundaria-escura: #343a40;
  --cor-fundo-cabecalho-tabela: linear-gradient(135deg, #2c2c2c, #1a1a1a);
  --cor-texto-claro: #fff;
  --cor-amarelo: #ffc107;
  --cor-vermelho-card: #ff2929;
}

body {
  background: #fff;
  color: #fff;
  /* Nota: O body tem cor de texto branca, mas sobrescrito em componentes */
  margin: 0;
  padding: 0;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

.main-content {
  padding: 0;
  background-color: rgba(255, 255, 255, 0.85);
  border-radius: 8px;
  margin: 5rem 0;
  overflow-x: hidden;
}

section:nth-child(even) {
  background: rgba(255, 255, 255, 0.05);
}

#patrocinadores {
  background: transparent;
}

/* =================================================================== */
/* 2. ANIMAÇÕES E EFEITOS VISUAIS                                    */
/* =================================================================== */
@keyframes shimmer {
  0% {
    transform: translateX(-100%);
  }

  100% {
    transform: translateX(100%);
  }
}

.alert-camp,
.classification-table-header,
.data-header,
.stats-summary-card {
  position: relative;
  overflow: hidden;
}

.alert-camp::before,
.classification-table-header::before,
.data-header::before,
.stats-summary-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  scale: 2.5;
  background: linear-gradient(45deg, transparent 30%, rgba(255, 255, 255, 0.1) 50%, transparent 70%);
  animation: shimmer 5s infinite;
}

/* =================================================================== */
/* 3. COMPONENTES DE UI (Botões, Badges, Alerts)                     */
/* =================================================================== */
.alert-camp {
  background: var(--cor-primaria-gradiente);
  text-align: center;
  color: var(--cor-texto-claro);
  border: none;
  border-radius: 6px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
  padding: 2.3rem;
  font-size: 1.1rem;
}

/* Botões Outline Primary */
.btn-outline-primary {
  border-color: #cb0000;
  color: #cb0000;
}

.btn-outline-primary:hover,
.filters-card .btn-outline-primary.active,
.btn-check:active+.btn-outline-primary,
.btn-check:checked+.btn-outline-primary,
.btn-outline-primary.active,
.btn-outline-primary.dropdown-toggle.show,
.btn-outline-primary:active {
  color: var(--cor-texto-claro);
  background-color: #cb0000;
  border-color: #cb0000;
}

/* Toggle Switch */
.toggle-switch-wrapper {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.85rem;
  font-weight: normal;
  padding: 0.3rem 0.5rem;
  border-radius: 50px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.form-switch .form-check-input {
  background-color: #a1a1a1;
  border-color: #8c8c8c;
  width: 3.5rem;
  height: 1.8em;
  cursor: pointer;
  margin-top: 0;
}

.form-switch .form-check-input:checked {
  background-color: #fff;
  border-color: #f0f0f0;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23a00a0a'/%3e%3c/svg%3e");
}

.toggle-label {
  transition: color 0.2s ease-in-out;
  pointer-events: none;
}

.toggle-label.inactive {
  color: #d1d1d1;
}

.toggle-label.active {
  color: var(--cor-texto-claro);
  font-weight: bold;
}

/* Carousel */
.carousel-item {
  background-color: transparent;
  border-radius: 8px;
  padding: 1rem;
}

.carousel-item img {
  max-width: 100%;
  max-height: 100px;
  height: auto;
  object-fit: contain;
  display: block;
  margin: 0 auto;
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
  filter: invert(1);
}

/* =================================================================== */
/* 4. NAVEGAÇÃO (Tabs, Pills, Toggle View)                           */
/* =================================================================== */
#viewToggle {
  transform: scale(1);

}

#viewToggle .btn-group {
  background-color: #e9ecef;
  border-radius: 50px;
  padding: 5px;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

#viewToggle .btn {
  border: none !important;
  background-color: transparent !important;
  color: #495057 !important;
  font-weight: 600;
  border-radius: 50px !important;
  padding: 0.5rem 1.2rem;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

#viewToggle .btn.active {
  background-color: var(--cor-primaria) !important;
  color: var(--cor-texto-claro) !important;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.15);
}

.classification-table-header .toggle-switch-wrapper {
  transform: scale(0.8);
  margin: 0 auto;
}




/* Nav Tabs - Modificado para Scroll Horizontal Mobile */
.nav-tabs {
  border-bottom: 2px solid #dee2e6 !important;
  display: flex;
  align-items: center;
  flex-wrap: nowrap !important;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding-bottom: 2px;
  padding-left: 15px !important;
  /* Espaçamento para o item não encostar na borda */
  justify-content: flex-start !important;
  /* Mobile: Começa do início para não cortar o primeiro item no scroll */
}

/* Oculta a barra de rolagem visual no Chrome/Safari/Edge */
.nav-tabs::-webkit-scrollbar {
  display: none;
}

/* Centraliza os itens apenas em telas grandes (PC) */
@media (min-width: 768px) {
  .nav-tabs {
    justify-content: center !important;

  }
}

/* Animação suave para o aviso de deslizar */
.swipe-hint {
  animation: pulse-hint 2s infinite;
}

@keyframes pulse-hint {
  0% {
    opacity: 0.5;
  }

  50% {
    opacity: 1;
  }

  100% {
    opacity: 0.5;
  }
}



.nav-item {
  border-radius: 999px;
  margin-bottom: 0px;
}

.nav-tabs .nav-link {
  background: none !important;
  border: none !important;
  border-radius: 0 !important;
  padding: 12px 24px !important;
  color: #6b7280 !important;
  font-weight: 600;
  cursor: pointer;
  border-bottom: 3px solid transparent !important;
  transition: all 0.2s ease;
  white-space: nowrap;
  text-decoration: none;
  box-shadow: none !important;
}

.nav-tabs .nav-link:not(.active):hover {
  color: #374151 !important;
  background: #f9fafb !important;
}

.nav-tabs .nav-link.active {
  border-radius: 999px;
  color: var(--cor-primaria) !important;
  border-bottom-color: var(--cor-primaria) !important;
  background: #fef2f2 !important;
  font-weight: 700;
}

/* Nav Pills */
.nav-pills {
  transform: scale(0.8);
  background-color: #f3f4f6;
  border-radius: 25px;
  padding: 5px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
}

.nav-pills .nav-link {
  background-color: transparent !important;
  border: none !important;
  color: #4b5563;
  font-weight: 600;
  padding: 8px 24px;
  border-radius: 10px;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.nav-pills .nav-link:not(.active):hover {
  color: #2a2a2a;
}

.nav-pills .nav-link.active {
  border-radius: 9999px;
  background-color: #ffffff !important;
  color: var(--cor-primaria) !important;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1);
}

.tab-content>.tab-pane {
  display: none;
}

.tab-content>.active {
  display: block;
}

#categoryTabContent .tab-pane {
  text-align: center;
}

/* =================================================================== */
/* 5. TABELA DE CLASSIFICAÇÃO                                        */
/* =================================================================== */
.table-responsive {
  overflow-x: auto;
}

.classification-table {
  background-color: #fff;
  border-radius: 8px;
  margin-top: 15px !important;
  margin-bottom: 1.5rem;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
  transition: transform 0.2s ease;
}

.classification-table:hover {
  transform: translateY(-3px);
}

.classification-table-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  font-weight: bold;
  font-size: 1rem;
  color: var(--cor-texto-claro);
  padding: 0.8rem 1.2rem;
  background: var(--cor-primaria-gradiente);
}

.classification-table table {
  width: 100%;
  color: #131313;
  border-collapse: collapse;
  min-width: 550px;
}

.classification-table th,
.classification-table td {
  padding: 0.8rem;
  text-align: center;
  border-bottom: 1px solid #d6d6d6;
}

.classification-table thead th {
  background: var(--cor-fundo-cabecalho-tabela) !important;
  color: var(--cor-texto-claro) !important;
  text-align: center;
  vertical-align: middle;
  border: none !important;
  text-transform: uppercase;
  font-size: 0.85rem;
}

/* Coluna de Posição */
.classification-table td:first-child,
.classification-table th:first-child {
  width: 40px;
  text-align: center;
  font-weight: bold;
  color: #333;
}

/* Coluna Nome do Time (Ajustes Específicos) */
.classification-table thead th.time-name {
  display: table-cell !important;
  text-align: left !important;
  padding-left: 55px !important;
}

.classification-table tbody td.time-name {
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  text-align: left !important;
  padding: 0.8rem 1rem !important;
  border-bottom: 1px solid #d6d6d6 !important;
  min-height: 60px;
}

.classification-table .time-name {
  font-weight: 600;
  white-space: nowrap;
}

.escudo-tabela {
  width: 36px !important;
  height: 36px !important;
  max-width: 36px !important;
  max-height: 36px !important;
  object-fit: contain !important;
  flex-shrink: 0 !important;
  margin: 0 !important;
}

.mb-4 {
  margin-bottom: 0.5rem;
}

.classification-table img {
  margin-left: 10px;
}

/* =================================================================== */
/* 6. JOGOS E CARDS (FASE DE GRUPOS & CALENDÁRIO)                    */
/* =================================================================== */
.round-nav {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 1rem;
}

.round-nav .btn {
  color: var(--cor-texto-claro);
  background-color: #303030;
  border: 1px solid #0d0d0d;
  width: 36px;
  height: 36px;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 4px;
  transition: background-color 0.2s ease, transform 0.2s ease;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

.round-nav .btn:hover {
  background-color: #1f1f1f;
  transform: translateY(-2px);
}

.round-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: #3f1616;
  margin: 0 1rem;
  min-width: 110px;
  text-align: center;
  flex-shrink: 0;
}

.round-section {
  display: none;
  margin-bottom: 1.5rem;
}

.round-section.active {
  display: block;
}

/* Card de Jogo Refatorado */
.match-card-refactored {
  background-color: #fff;
  border-radius: 12px;
  margin-bottom: 1.25rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  border: 1px solid #e0e0e0;
  overflow: hidden;
  color: #333;
}

.card-header-refactored {
  background-color: var(--cor-primaria-escura);
  color: var(--cor-texto-claro);
  padding: 0.75rem 1rem;
  font-weight: 700;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.95rem;
  text-transform: uppercase;
}

.card-body-refactored {
  padding: 1.25rem;
}

.match-info-refactored {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.5rem;
  font-size: 0.9rem;
  color: #555;
  margin-bottom: 0.5rem;
}

.match-stadium-refactored {
  text-align: center;
  font-size: 0.95rem;
  font-weight: 500;
  color: #444;
  margin-bottom: 1.25rem;
}

.match-info-refactored i,
.match-stadium-refactored i {
  color: var(--cor-primaria-escura);
}

.match-teams-refactored {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}

.team-display {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  width: 35%;
  text-align: center;
}

.team-display img {
  width: 55px;
  height: auto;
  object-fit: contain;
}

.team-display .team-name {
  font-weight: 700;
  font-size: 1rem;
}

.score-display {
  font-size: 2rem;
  font-weight: 800;
  color: #121212;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
}

/* =================================================================== */
/* 7. CARDS DE JOGO (MATA-MATA / KNOCKOUT)                           */
/* =================================================================== */
.knockout-card {
  border: 2px solid var(--cor-primaria-escura);
}

.knockout-main-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 1.25rem;
}

.knockout-teams-section {
  flex: 2;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 1.5rem;
}

.team-display-knockout {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.team-display-knockout img {
  width: 70px;
  height: 70px;
  object-fit: contain;
}

.team-display-knockout .team-name {
  font-size: 1.2rem;
  font-weight: 700;
}

.score-display-knockout {
  display: flex;
  flex-direction: column;
  align-items: center;
  font-weight: 800;
  font-size: 2.2rem;
  color: #121212;
  gap: 0.5rem;
}

.main-score {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.vs-knockout {
  font-size: 1.5rem;
  color: #666;
}

.additional-scores {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  font-size: 0.85rem;
  color: #555;
}

.additional-score-item {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  background-color: #f9fafb;
  padding: 2px 8px;
  border-radius: 4px;
}

.additional-score-item .score-label {
  font-weight: 600;
}

.additional-score-item .score-value {
  font-weight: 700;
  color: #333;
}

.knockout-info-section {
  display: flex;
  flex-direction: column;
  align-items: left;
  justify-content: center;
  gap: 0.75rem;
  padding: 1rem;
  border-left: 1px solid #ddd;
}

.knockout-info-section .info-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.95rem;
}

.knockout-info-section .info-item i {
  color: var(--cor-primaria-escura);
  font-size: 1.2rem;
}

/* Eventos (Gols/Cartões) */
.match-events-refactored {
  border-top: 1px solid #eee;
  padding-top: 0.5rem;
  display: flex;
  font-weight: 200;
  gap: 2.5rem;
  font-size: 0.85rem;
  color: #444;
}

.knockout-teams-section .events-col {
  width: -webkit-fill-available;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.events-col {
  width: 45%;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.event-item {
  display: flex !important;
  align-items: center !important;
  flex-wrap: nowrap !important;
  /* Impede que o bloco quebre linha */
  gap: 5px !important;
  /* Espacinho entre ícone e nome */
  width: 100%;
  /* Garante largura total para cálculo do corte */
  max-width: 100%;
  /* Limite de segurança */
  margin-bottom: 2px;
  line-height: 1.2;
}

.event-item span {
  white-space: nowrap !important;
  /* Força o texto a ficar em 1 linha */
  overflow: hidden !important;
  /* Esconde o que passar da largura */
  text-overflow: ellipsis !important;
  /* Adiciona os "..." no final */

  flex: 1 !important;
  /* Ocupa todo o espaço restante disponível */
  min-width: 0 !important;
  /* CRUCIAL: Permite que o texto encolha dentro do flex */

  display: block !important;
  /* Comporta-se como bloco para o overflow funcionar */
  text-align: left !important;
  /* Alinha o texto junto ao ícone */
  font-size: 0.8rem !important;
  /* Tamanho da fonte */
}

.event-item i {
  font-size: 1rem;
  flex-shrink: 0;
}

.icon-goal-img {
  width: 1.2em;
  height: 1.2em;
  vertical-align: -0.25em;
}

.knockout-teams-section .icon-goal-img {
  width: 20px;
  height: 20px;
}

.event-yellow {
  color: var(--cor-amarelo);
}

.event-red {
  color: var(--cor-vermelho-card);
}

.bi-square-fill.event-yellow,
.bi-square-fill.event-red {
  border: none;
  border-radius: 2px;
}

.icon-placeholder {
  font-size: 65px;
  color: #e0e0e0;
  line-height: 1;
  height: 65px;
  display: flex;
  align-items: center;
}

/* =================================================================== */
/* 8. CALENDÁRIO COMPLETO E FILTROS                                  */
/* =================================================================== */
.filters-card {
  background-color: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

.filters-card .form-label {
  color: #333;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 0.3rem;
  display: flex;
  align-items: center;
  gap: 5px;
}

.filters-card .form-control,
.filters-card .form-select {
  border-radius: 6px;
}

#filterUpcomingGames {
  background-color: transparent;
  border-color: var(--cor-primaria);
  color: var(--cor-primaria);
}

#filterUpcomingGames:hover,
#filterUpcomingGames.active {
  background-color: var(--cor-primaria);
  border-color: var(--cor-primaria);
  color: var(--cor-texto-claro);
}

#clearFilters {
  background-color: var(--cor-amarelo);
  border-color: #e6a700;
  color: #111;
}

#clearFilters:hover {
  background-color: #e6a700;
  border-color: #d39800;
  color: #111;
}

.filters-card .btn-danger {
  align-self: center;
  background-color: var(--cor-primaria);
  border-color: var(--cor-primaria-escura);
  font-weight: bold;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.bg-danger {
  align-self: center;
}

.game-counter-card {
  background-color: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 0.75rem 1rem;
  margin-bottom: 2rem;
  text-align: center;
  color: #333;
  font-weight: 500;
  margin-top: 20px;
}

.game-counter-card .bi-calendar-check {
  margin-right: 8px;
  color: var(--cor-primaria-escura);
}

.data-header {
  background: var(--cor-primaria);
  color: var(--cor-texto-claro);
  padding: 1rem 2rem;
  border-radius: 12px 12px 0 0;
  margin-bottom: 0;
  text-align: center;
}

.data-header h5 {
  font-size: 1rem;
  font-weight: 700;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 15px;
  justify-content: center;
  position: relative;
  z-index: 1;
}

.dia-semana {
  background-color: #fff;
  color: var(--cor-primaria);
  padding: 5px 15px;
  border-radius: 50rem;
  font-size: 0.85em;
  font-weight: bold;
}

/* Tabela de Jogos (Desktop) */
.table-jogos {
  width: 100%;
  border-collapse: collapse;
  min-width: 700px;
}

.table-jogos thead th {
  background: var(--cor-fundo-cabecalho-tabela);
  color: var(--cor-texto-claro);
  padding: 1rem;
  text-align: center;
  font-weight: 700;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.table-jogos tbody td {
  background: #fff;
  color: #333;
  text-align: center;
  border: none;
  border-bottom: 1px solid #f0f0f0;
  vertical-align: middle;
  padding: 1rem;
  height: auto !important;
  padding: 12px 8px !important;
}

.table-jogos tbody tr {
  transition: all 0.2s ease-in-out;
}

.table-jogos tbody tr:hover {
  transform: scale(0.99);
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
  position: relative;
  z-index: 10;
}

.table-jogos td.jogo .score-container {
  background-color: var(--cor-secundaria-escura);
  color: var(--cor-texto-claro);
  border-radius: 50rem;
  padding: 8px 15px;
  font-weight: bold;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9em;
}

.table-jogos td.team-name,
.table-jogos td.categoria {
  font-weight: 600;
  font-size: 0.95em;
  white-space: normal !important;
  word-break: break-word;
}

.badge-time {
  width: 30px;
  height: auto;
  object-fit: cover;
  border-radius: 4px;
}

.badge-categoria,
.badge-fase-grupo {
  display: inline-block;
  padding: 0.5em 1em;
  font-size: 0.8em;
  font-weight: 700;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
  vertical-align: baseline;
  border-radius: 50rem;
}

.badge-categoria {
  color: #111;
  background-color: var(--cor-amarelo);
}

.badge-fase-grupo {
  color: var(--cor-texto-claro);
  background-color: var(--cor-primaria);
}

/* Estádio Icons */
.stadium-icon {
  width: 30px;
  height: 30px;
  margin-right: 8px;
  vertical-align: middle;
  margin-top: -3px;
  filter: brightness(0) invert(1);
}

.stadium-header {
  background-color: #333;
  color: #fff;
  padding: 20px 20px;
  margin-bottom: 0;
  text-align: center;
}

.stadium-header h6 {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 500;
  text-transform: uppercase;
}

.stadium-header i {
  margin-right: 8px;
}

/* Match Card Calendar (Lista Mobile) */
.match-list-container {
  display: none;
}

.match-card-calendar {
  background-color: #ffffff;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  color: var(--cor-secundaria-escura);
  border-bottom: 1px solid #dfdfdf;
}

.match-card-calendar .match-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.match-card-calendar .match-teams {
  display: flex;
  justify-content: space-between;
  align-items: center;
  text-align: center;
}

.match-card-calendar .team {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 40%;
  gap: 0.5rem;
}

.match-card-calendar .team img {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.match-card-calendar .team .team-name {
  font-size: 0.9rem;
  font-weight: bold;
  line-height: 1.2;
}

.match-card-calendar .score-time {
  display: flex;
  flex-direction: column;
  align-items: center;
  font-weight: bold;
  width: 20%;
}

.match-card-calendar .score-time .score {
  font-size: 1.2rem;
}

.match-card-calendar .score-time .time {
  font-size: 0.9rem;
  color: var(--cor-primaria);
}

.match-card-calendar .score-time .vs {
  font-size: 1.1rem;
  color: #131313;
}

.score-time .penalty-score {
  display: block;
  width: 100%;
  text-align: center;
}

/* =================================================================== */
/* 9. ESTATÍSTICAS E LISTAS DE JOGADORES                             */
/* =================================================================== */
.stats-refactored-container {
  padding: 1rem;
  background-color: #fff;
}

.stats-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.stats-summary-card {
  background-color: var(--cor-primaria);
  color: var(--cor-texto-claro);
  padding: 1.25rem 1rem;
  border-radius: 8px;
  text-align: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
}

.stats-summary-card i {
  font-size: 1.8rem;
  margin-bottom: 0.5rem;
  opacity: 0.8;
}

.stats-summary-card img {
  width: 1.8rem;
  height: 1.8rem;
  margin-bottom: 0.5rem;
  opacity: 0.8;
}

.stats-summary-title {
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.stats-summary-number {
  font-size: 2.2rem;
  font-weight: 800;
  line-height: 1;
}

.stats-summary-subtitle {
  font-size: 0.8rem;
  opacity: 0.9;
}

.stats-details-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

.stat-block {
  background-color: #f0f2f5;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  overflow: hidden;
}

.stat-block-header {
  background-color: var(--cor-secundaria-escura);
  color: var(--cor-texto-claro);
  padding: 0.75rem 1.25rem;
  font-weight: 700;
  text-align: center;
}

.stat-block-header h5 {
  margin-bottom: 12px !important;
}

.stat-header-subtitle {
  display: block;
  margin-top: 5px;
  margin-bottom: 10px;
  line-height: 1.4;
  font-size: 0.85rem;
  opacity: 0.9;
}

.stat-block-content {
  padding: 0.5rem;
}

/* Itens de Jogador/Time (Lista) */
.player-item,
.team-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  overflow: hidden;
  padding: 0.5rem;
  margin-bottom: 4px;
  background-color: rgba(255, 255, 255, 0.02);
  border-radius: 6px;
}

.player-item:not(:last-child),
.team-item:not(:last-child) {
  border-bottom: 1px solid #f0f0f0;
}

.player-item:hover,
.team-item:hover {
  background-color: #f8f9fa;
}

.player-photo-container {
  position: relative;
  width: 50px;
  height: auto;
  flex-shrink: 0;
}

.player-photo {
  width: 50px;
  height: auto;
}

.player-photo i {
  font-size: 2.5rem;
  color: #adb5bd;
}

.team-shield {
  width: 30px;
  height: auto;
  object-fit: cover;
  flex-shrink: 0;
  border-radius: 4px;
}

.team-shield-mini {
  width: 18px !important;
  height: 18px !important;
  object-fit: contain;
  margin-right: 6px;
  vertical-align: middle;
  display: inline-block;
}

/* Ajuste para garantir que o flexbox funcione bem dentro das infos do modal */
.modal-body .player-info small {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-wrap: nowrap !important;
}

/* Ajuste específico para mobile onde o alinhamento pode variar */
@media (max-width: 767px) {
  .modal-body .player-info small {
    justify-content: center !important;
  }
}

.team-shield-overlay {
  position: absolute;
  bottom: -5px;
  right: -5px;
  width: 30px;
  height: auto;
  object-fit: cover;
}

.modal .team-shield-overlay {
  display: none !important;
}

.player-info,
.team-info {
  display: flex !important;
  flex-direction: column;
  justify-content: center;
  flex: 1;
  min-width: 0;
  max-width: 100%;
  margin-left: 10px;
  padding-right: 10px;
  overflow: hidden;
  position: relative;
  z-index: 1;
}

.player-info strong,
.team-info strong {
  display: block;
  width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 0.9rem;
  color: #212529 !important;
}

.player-info small,
.team-info small {
  display: block;
  width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 0.75rem;
  color: #6c757d !important;
}

.bg-info {
  --bs-bg-opacity: 1;
  background-color: rgba(var(--bs-info-rgb), var(--bs-bg-opacity)) !important;
  margin-top: 20px;
}

.stat-badge {
  background-color: var(--cor-primaria);
  color: var(--cor-texto-claro);
  padding: 0.3rem 0.75rem;
  border-radius: 50px;
  font-weight: 700;
  font-size: 0.85rem;
  white-space: nowrap;
  flex-shrink: 0;
}

.stat-badge.yellow {
  background-color: var(--cor-amarelo);
  color: #000;
}

.stat-badge.red {
  background-color: var(--cor-vermelho-card);
}

.btn-stats-all {
  display: block;
  width: calc(100% - 1rem);
  margin: 0.5rem;
  background-color: var(--cor-primaria);
  border: none;
  font-weight: 600;
  transition: background-color 0.2s;
}

.btn-stats-all:hover {
  background-color: #800808;
}

/* =================================================================== */
/* 10. MODAIS GERAIS (Overrides Base)                                */
/* =================================================================== */
.modal * {
  font-size: small;
}

.modal .list-group-item .player-info {
  text-align: center;
}

.modal .badge {
  padding: 8px 12px;
  font-size: 0.9rem;
}

.player-hidden {
  display: none !important;
}

.modal .list-group-item {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  flex-wrap: nowrap !important;
  padding: 8px 15px !important;
  gap: 10px;
}

.modal .player-photo-container {
  flex: 0 0 50px !important;
  width: 50px !important;
  height: auto !important;
  margin-right: 15px !important;
  position: relative;
  overflow: visible !important;
}

.modal .player-photo {
  width: 100%;
  height: 100%;
}

.modal .player-info {
  flex: 1 !important;
  min-width: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  justify-content: center !important;
  gap: 0px !important;
  text-align: center !important;
  padding: 0 !important;
  margin: 0 !important;
}

.modal .player-info strong {
  display: block !important;
  width: 100% !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  font-size: 0.95rem;
  color: #212529 !important;
  margin-bottom: 0 !important;
  line-height: 1.1 !important;
  padding-bottom: 2px !important;
}

.modal .player-info small {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 100%;
  line-height: 1.2;
}

.suspension-badge-modal {
  white-space: normal !important;
  /* O Pulo do Gato: Permite que o texto quebre para a linha de baixo */
  overflow: visible !important;
  /* Garante que o texto não seja escondido */
  text-overflow: clip !important;
  /* Remove os "..." (reticências) */

  display: inline-block !important;
  /* Garante comportamento de caixa */
  width: auto !important;
  /* Largura automática baseada no texto */
  max-width: 100% !important;
  /* Garante que não estoure a largura da tela */
  height: auto !important;
  /* Permite que a altura cresça se quebrar linha */

  line-height: 1.2 !important;
  /* Ajusta a altura da linha para ficar bonito se quebrar */
  padding: 5px 8px !important;
  /* Um pouco mais de espaço interno */
  font-size: 0.7rem !important;
  /* Garante uma fonte legível no mobile */
}

.modal .player-info .suspension-badge-modal,
.modal-body .player-info .suspension-badge-modal {
  align-self: center !important;
  margin-left: auto !important;
  margin-right: auto !important;
  margin-bottom: 4px !important;
  text-align: center !important;
}

/* =================================================================== */
/* 11. LAYOUT RESPONSIVO (MEDIA QUERIES)                             */
/* =================================================================== */

/* --- Ajustes para Mobile (max-width: 767px) --- */
@media (max-width: 767px) {

  /* Carousel */
  .carousel-item img {
    max-height: 70px;
  }

  .carousel-item {
    padding: 0.5rem;
  }

  /* Tabela de Classificação & Jogos */
  .table-jogos {
    display: none;
  }

  .match-list-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
  }

  /* Sticky Columns Tabela (Estilo App) */
  .table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-right: -10px;
  }

  .classification-table th:nth-child(1),
  .classification-table td:nth-child(1),
  .classification-table th.time-name,
  .classification-table td.time-name {
    position: sticky;
    z-index: 2;
    background-color: #fff;
    border-right: 1px solid #e0e0e0;
  }

  .classification-table th:nth-child(1),
  .classification-table td:nth-child(1) {
    left: 0;
    width: 35px;
    min-width: 35px;
    text-align: center;
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.05);
  }

  .classification-table th.time-name,
  .classification-table td.time-name {
    left: 35px;
    min-width: 140px;
    max-width: 140px;
    box-shadow: 4px 0 5px rgba(0, 0, 0, 0.1);
  }

  .classification-table thead th:nth-child(1),
  .classification-table thead th.time-name {
    background: var(--cor-fundo-cabecalho-tabela) !important;
    color: #fff !important;
    z-index: 3;
  }

  .classification-table tbody td.time-name {
    font-size: 0.85rem;
    word-break: keep-all;
    overflow-wrap: break-word;
    font-size: 0.8rem;
    white-space: normal;
    line-height: 1.1;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
  }

  .classification-table thead th.time-name {
    padding-left: 10px !important;
  }

  .classification-table tbody td.time-name {
    padding: 0.6rem 0.5rem !important;
    gap: 8px !important;
    min-width: 130px;
  }

  .classification-table .time-name span {
    font-size: 0.85rem;
    word-break: keep-all;
    overflow-wrap: break-word;
    font-size: 0.8rem;
    white-space: normal;
    line-height: 1.1;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
  }

  .escudo-tabela {
    width: 30px !important;
    height: 30px !important;
    max-width: 30px !important;
    margin-right: 8px !important;
    flex-shrink: 0;
  }

  /* Cards Mata-Mata Mobile */
  .knockout-main-content {
    flex-direction: column;
    gap: 1.25rem;
    margin-bottom: 0;
  }

  .knockout-info-section {
    width: 100%;
    border-left: none;
    border-top: 1px solid #eee;
    flex-direction: row;
    justify-content: space-around;
    text-align: center;
  }

  .knockout-info-section .info-item {
    gap: 2px !important;
    /* Reduz drasticamente o espaço entre ícone e texto */
    align-items: center !important;
    justify-content: center;
    /* Mantém centralizado no bloco */
  }

  .knockout-info-section .info-item i {
    font-size: 1rem !important;
  }

  .knockout-info-section .info-item span {
    text-align: left !important;
    /* Puxa o texto para a esquerda (perto do ícone) */
    line-height: 1.0 !important;
    /* Junta as linhas caso o nome do estádio quebre */
    display: inline-block;
  }

  .knockout-teams-section {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    justify-content: space-between;
    gap: 5px;
    width: 100%;
  }

  .team-display-knockout {
    flex: 1;
    width: 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .score-display-knockout {
    font-size: 2rem;
    flex: 0 0 auto;
    width: auto;
    margin: 0 2px;
  }

  .team-display-knockout img {
    width: 50px;
    height: 50px;
    margin-bottom: 5px;
  }

  .team-display-knockout .team-name {
    font-size: 0.9rem;
    text-align: center;
    line-height: 1.1;
    height: auto;
    margin-bottom: 5px;
  }

  .knockout-teams-section .events-col {
    align-items: center !important;
  }
}

.event-item {
  justify-content: flex-start !important;
  /* Mantém alinhado à esquerda para ler o começo do nome */
}

.event-item .bi-person-badge-fill {
  font-size: 12px !important;
  margin-left: 2px;
}

.event-item i,
.event-item .icon-goal-img {
  font-size: 14px !important;
  width: 14px !important;
  height: auto !important;
  flex-shrink: 0 !important;
  /* Ícone nunca encolhe */
  display: inline-block !important;
}

/* Player List Mobile Fix */
.player-item {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  align-items: center !important;
  padding: 10px !important;
  position: relative;
}

.player-photo-container {
  width: 60px !important;
  flex: 0 0 60px !important;
  margin-right: 12px !important;
  position: relative;
}

.player-photo {
  width: 100% !important;
  height: auto !important;
  display: block;
}

.player-info {
  flex: 1 !important;
  min-width: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: flex-start !important;
  text-align: center !important;
  margin-left: 0 !important;
}

.player-info strong {
  width: 100%;
  white-space: normal !important;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  font-size: 0.9rem !important;
  color: #000 !important;
}

.stat-badge {
  margin-left: 10px !important;
  flex-shrink: 0 !important;
}

.modal .stat-badge {
  flex: 0 0 auto !important;
  margin-left: 10px !important;
}

/* Modal Mobile Centering */
.modal-body .player-info,
.modal-body .team-info {
  align-items: center !important;
  text-align: center !important;
}

.modal-body .player-info strong,
.modal-body .team-info strong {
  text-align: center !important;
}



/* =================================================================== */
/* 11. CHAMPIONS AND SPONSORS (MOBILE-FIRST)                         */
/* =================================================================== */

/* --- LAYOUT CLEAN & GOLD --- */
.champions-container {
  background-color: #ffffff;
  border-top: 4px solid #b8860b;
  /* Dourado Escuro */
  border-bottom: 1px solid #f0f0f0;
  border-radius: 12px;
  padding: 1rem;
  /* Padding reduzido */
  box-shadow: 0 8px 25px rgba(184, 134, 11, 0.15);
  /* Sombra dourada suave */
  position: relative;
  overflow: hidden;
  /* Para o brilho não vazar */
}

/* Título */
.champions-header {
  text-align: center;
  margin-bottom: 1rem;
}

.champions-title {
  color: #333;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-size: 1.2rem;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.icon-trophy {
  color: #b8860b;
  font-size: 1.4rem;
}

/* --- GRID (O SEGREDO DO MOBILE) --- */
.champions-grid {
  display: grid;
  /* Mobile: 4 colunas apertadas */
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  /* Gap bem pequeno para caber */
  align-items: stretch;
}

/* Card Individual */
.champion-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  text-align: center;
  background: #fff;
  border-radius: 8px;
  padding: 8px 2px;
  /* Padding lateral quase zero no mobile */
  border: 1px solid #f1f1f1;
  position: relative;
  transition: transform 0.2s;
}

/* Área das Imagens (Stack) */
.img-stack-container {
  position: relative;
  width: 100%;
  height: 55px;
  /* Altura fixa para alinhar */
  margin-bottom: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Campeão (Frente) */
.champ-img-front {
  width: 45px;
  /* Reduzido levemente para caber 4 */
  height: 45px;
  object-fit: contain;
  z-index: 2;
  filter: drop-shadow(0 3px 3px rgba(0, 0, 0, 0.2));
}

/* Vice (Fundo) */
.vice-bg-shield {
  position: absolute;
  width: 28px;
  height: 28px;
  object-fit: contain;
  left: 65%;
  /* Deslocado para direita */
  top: 50%;
  transform: translateY(-50%);
  z-index: 1;
  opacity: 0.3;
  /* Bem suave */
  filter: grayscale(100%);
}

/* Textos */
.champ-cat {
  font-size: 0.55rem;
  /* Fonte micro no mobile */
  color: #999;
  text-transform: uppercase;
  font-weight: 700;
  margin-bottom: 4px;
  width: 100%;
  white-space: nowrap;
  /* Não quebra linha */
  overflow: hidden;
  text-overflow: ellipsis;
  /* ... se for grande */
}

.champ-name {
  font-size: 0.65rem;
  /* Fonte pequena */
  color: #222;
  font-weight: 700;
  line-height: 1.1;
  width: 100%;
  white-space: nowrap;
  /* Força 1 linha */
  overflow: hidden;
  text-overflow: ellipsis;
  /* Adiciona ... */
  margin-bottom: 5px;
  padding: 0 2px;
}

/* Badge Dourada Melhorada */
.champ-badge {
  font-size: 0.55rem;
  background: linear-gradient(135deg, #b8860b 0%, #eec95e 100%);
  color: #fff;
  padding: 2px 8px;
  border-radius: 10px;
  font-weight: 800;
  text-transform: uppercase;
  box-shadow: 0 2px 4px rgba(184, 134, 11, 0.2);
  width: 90%;
  /* Ocupa quase toda largura do card */
}

.sponsor-logo-box {
  width: 110px;
  height: 75px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  border-radius: 8px;
  transition: transform 0.2s ease;
}

.sponsor-logo-box:hover {
  transform: scale(1.08);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.sponsor-logo-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

/* Ajuste da setinha do carrossel para ficar visível e nas pontas */
.carousel-control-custom {
  width: 5%;
  filter: invert(1) grayscale(100);
  /* Deixa a seta escura/visível */
}

/* --- PC / TABLET DESKTOP OVERRIDES --- */
@media (min-width: 768px) {
  .sponsor-logo-box {
    width: 140px;
    height: 90px;
  }

  .champions-grid {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    /* Mais espaçado no PC */
    gap: 20px;
  }

  .champion-item {
    padding: 15px 10px;
    border: 1px solid #eee;
  }

  .img-stack-container {
    height: 90px;
  }

  .champ-img-front {
    width: 75px;
    height: 75px;
  }

  .vice-bg-shield {
    width: 45px;
    height: 45px;
    left: 60%;
  }

  .champ-cat {
    font-size: 0.8rem;
  }

  .champ-name {
    font-size: 0.95rem;
    white-space: normal;
  }

  /* No PC pode quebrar linha */
  .champ-badge {
    font-size: 0.7rem;
    width: auto;
    padding: 4px 12px;
  }

  .champions-header {
    text-align: center;
  }

  .champions-title {
    font-size: 1.5rem;
  }
}

/* --- OUTROS AJUSTES DESKTOP (700px+) --- */
@media (min-width: 700px) {
  .stats-details-grid {
    grid-template-columns: 2fr 1.8fr;
    grid-template-areas:
      "artilharia   ataque"
      "artilharia   defesa"
      "amarelos     vermelhos";
  }

  .stat-artilharia {
    grid-area: artilharia;
  }

  .stat-ataque {
    grid-area: ataque;
  }

  .stat-defesa {
    grid-area: defesa;
  }

  .stat-amarelos {
    grid-area: amarelos;
  }

  .stat-vermelhos {
    grid-area: vermelhos;
  }

  .stat-ataque,
  .stat-defesa,
  .stat-amarelos,
  .stat-vermelhos {
    align-self: start;
  }

  .main-artillery-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
  }

  .main-artillery-card .player-photo-container {
    width: 100px;
    height: auto;
  }

  .main-artillery-card .player-photo {
    width: 100px;
    height: auto;
  }

  .main-artillery-card .player-photo i {
    font-size: 4.5rem;
  }

  .main-artillery-card .team-shield-overlay {
    width: 50px;
    height: auto;
    bottom: -10px;
    right: -10px;
    border-width: 2px;
  }

  .team-shield-inline {
    width: 20px !important;
    height: 20px !important;
    object-fit: contain;
    margin-right: 6px;
    vertical-align: middle;
  }
}

/* =================================================================== */
/* 12. IMPRESSÃO (PRINT)                                             */
/* =================================================================== */
@media print {
  @page {
    margin: 1cm 0.5cm;
    size: A4 portrait;
  }

  body {
    zoom: 78%;
    background: white !important;
    color: black !important;
    padding: 0 !important;
    margin: 0 !important;
  }

  /* Remoção de elementos */
  #viewToggle,
  .navbar,
  #calendarioSection .row.g-3,
  .game-counter-card,
  .btn,
  #categoryTabs,
  #categoryTabContent .nav,
  .round-nav,
  .col-card-gerador,
  .col-sumula,
  footer {
    display: none !important;
  }

  .main-content {
    margin: 0 !important;
    padding: 0 !important;
  }

  .alert-camp {
    padding: 8px !important;
    font-size: 0.9rem !important;
    margin-bottom: 1px !important;
    border: 1px solid #920000 !important;
  }

  .table-jogos {
    width: 100% !important;
    margin-bottom: 5px !important;
    font-size: 10pt !important;
  }

  .table-jogos thead th {
    padding: 10px !important;
    font-size: 9pt !important;
    background-color: #2c2c2c !important;
    -webkit-print-color-adjust: exact;
  }

  .table-jogos tbody td {
    padding: 15px 15px !important;
  }

  .stadium-header {
    padding: 6px !important;
    background-color: #333 !important;
    -webkit-print-color-adjust: exact;
  }

  .stadium-block,
  .date-block {
    page-break-inside: avoid !important;
    margin-bottom: 10px !important;
  }

  #patrocinadores {
    margin-top: 5px !important;
    padding: 0 !important;
  }

  .carousel-item img {
    max-height: 50px !important;
    width: auto !important;
    margin: 0 auto !important;
  }

  * {
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }
}

/* =================================================================== */
/* 13. CORREÇÕES FINAIS E CRÍTICAS (MODAL & OVERRIDES)               */
/* =================================================================== */
/* Estas regras são mantidas no final para garantir a prioridade sobre todas as anteriores */

/* Modal Body - Player Item Blindagem */
.modal-body .player-item,
.modal-body .team-item {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  align-items: center !important;
  width: 100%;
  padding: 10px 0;
  border-bottom: 1px solid #f0f0f0;
  position: relative;
}

/* Foto com espaço reservado */
.modal-body .player-item img,
.modal-body .player-item .player-photo-container,
.modal-body .team-item img {
  flex: 0 0 50px !important;
  width: 50px !important;
  height: 50px !important;
  margin-right: 15px !important;
  object-fit: cover;
  border-radius: 50%;
  display: block;
}

/* Coluna de Texto */
.modal-body .player-info,
.modal-body .team-info {
  flex: 1 !important;
  min-width: 0 !important;
  margin-left: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  justify-content: center !important;
  align-items: flex-start !important;
}

/* Nome do Jogador (Limitado a 2 linhas) */
.modal-body .player-info strong,
.modal-body .team-info strong {
  display: -webkit-box !important;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  white-space: normal !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  font-size: 0.9rem;
  line-height: 1.2;
  height: auto;
  color: #212529 !important;
  margin-bottom: 2px;
}

/* Detalhes (Uma linha) */
.modal-body .player-info small,
.modal-body .team-info small {
  display: block;
  width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 0.75rem;
  color: #6c757d !important;
}

/* Badge Fixo na direita */
.modal-body .stat-badge {
  flex: 0 0 auto !important;
  margin-left: 10px !important;
}

/* Adicione no final do arquivo CSS */

.penalty-badge-calendar {
  background-color: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  padding: 3px 6px;
  /* Padding levemente ajustado */
  font-size: 0.7rem;
  /* Fonte levemente menor para caber melhor */
  color: #555;
  font-weight: 600;
  margin-top: 4px;

  /* FLEXBOX MÁGICO */
  display: inline-flex;
  /* Comporta-se como texto, mas usa flexbox dentro */
  flex-wrap: wrap;
  /* PERMITE quebrar a linha se faltar espaço */
  justify-content: center;
  /* Centraliza o conteúdo horizontalmente */
  align-items: center;
  /* Centraliza verticalmente */
  gap: 3px;
  /* Espacinho entre o texto e o placar */

  text-align: center;
  line-height: 1.1;
  /* Altura de linha menor para ficar compacto se quebrar */
  max-width: 100%;
}

/* Removemos a margem do span para usar o 'gap' do flexbox e evitar desalinhamento */
.penalty-badge-calendar span {
  color: #111;
  font-weight: 800;
  margin-left: 0 !important;
}

.bg-warning {
  --bs-bg-opacity: 1;
  background-color: rgba(var(--bs-warning-rgb), var(--bs-bg-opacity)) !important;
  align-self: center !important;
  margin-left: auto !important;
  margin-right: auto !important;
  margin-bottom: 4px !important;
  text-align: center !important;
}

.team-card-elenco {
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  border: 1px solid #eee;
}

.team-card-elenco:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  border-color: #ccc;
  background-color: #f9f9f9;
}

/* Submenu Mata-Mata - Estilo Chips/Outline */
.nav-matamata {
  display: flex;
  align-items: center;
  flex-wrap: nowrap !important;
  overflow-x: auto;
  gap: 12px;
  padding: 5px 10px;
  margin-bottom: 1.5rem;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

@media (min-width: 768px) {
  .nav-matamata {
    justify-content: center;
  }
}

@media (max-width: 767px) {
  .nav-matamata {
    justify-content: flex-start;
  }
}

.nav-matamata::-webkit-scrollbar {
  display: none;
}

.nav-matamata .nav-item {
  flex: 0 0 auto;
}

.nav-matamata .nav-link {
  background: transparent !important;
  color: var(--cor-primaria-escura) !important;
  border: 1.5px solid var(--cor-primaria-escura) !important;
  border-radius: 50px !important;
  padding: 6px 18px !important;
  font-size: 0.85rem;
  font-weight: 700;
  transition: all 0.3s ease;
  box-shadow: none !important;
}

.nav-matamata .nav-link:hover {
  background: rgba(146, 0, 0, 0.05) !important;
}

.nav-matamata .nav-link.active {
  background: var(--cor-primaria) !important;
  color: #ffffff !important;
  border-color: var(--cor-primaria) !important;
  box-shadow: 0 4px 10px rgba(146, 0, 0, 0.3) !important;
  transform: translateY(-2px);
}