/* =========================================================
   GEW SPORTS — style.css (Clean Profissional, refinado)
   Mantém todas as classes/IDs existentes. Drop-in replacement.
   ========================================================= */

/* -------- TOKENS -------- */
:root{
  --bg:           #f1f5f9;
  --bg-soft:      #f8fafc;
  --surface:      #ffffff;
  --surface-2:    #f8fafc;
  --surface-3:    #eef2f7;
  --border:       #e2e8f0;
  --border-soft:  #eef2f7;

  --text:         #0f172a;
  --text-2:       #334155;
  --text-dim:     #64748b;
  --text-mute:    #94a3b8;

  --primary:      #2563eb;   /* azul corporativo */
  --primary-2:    #1d4ed8;
  --primary-soft: #dbeafe;

  --accent:       #0ea5e9;
  --success:      #10b981;
  --warn:         #f59e0b;
  --danger:       #ef4444;
  --danger-2:     #dc2626;

  --dark:         #0f172a;
  --dark-2:       #1e293b;

  --radius:       14px;
  --radius-sm:    10px;
  --radius-lg:    18px;

  --shadow-xs: 0 1px 2px rgba(15,23,42,.04);
  --shadow-sm: 0 2px 8px rgba(15,23,42,.06);
  --shadow:    0 6px 20px rgba(15,23,42,.08);
  --shadow-lg: 0 18px 40px rgba(15,23,42,.14);
  --ring:      0 0 0 3px rgba(37,99,235,.18);

  --grad-sidebar: linear-gradient(180deg,#0f172a 0%,#020617 100%);
  --grad-primary: linear-gradient(135deg,#2563eb 0%,#1d4ed8 100%);
  --grad-success: linear-gradient(135deg,#10b981 0%,#059669 100%);
  --grad-danger:  linear-gradient(135deg,#ef4444 0%,#dc2626 100%);
  --grad-warn:    linear-gradient(135deg,#f59e0b 0%,#d97706 100%);
  --grad-whats:   linear-gradient(135deg,#25D366 0%,#128C7E 100%);
}

/* -------- RESET / BASE -------- */
*{ box-sizing:border-box; margin:0; padding:0;
   font-family:'Inter','Segoe UI',system-ui,-apple-system,Roboto,Helvetica,Arial,sans-serif; }

html,body{ height:100%; }
body{
  background:
    radial-gradient(900px 500px at 100% -10%, rgba(37,99,235,.06), transparent 60%),
    radial-gradient(700px 400px at -10% 110%, rgba(14,165,233,.05), transparent 60%),
    var(--bg);
  color: var(--text);
  font-size: 14.5px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1,h2,h3,h4{ color: var(--text); font-weight: 700; letter-spacing: -.01em; }
h1{ font-size: 1.6rem; margin-bottom: 18px; }
h2{ font-size: 1.2rem; margin: 22px 0 14px; }
h3{ font-size: 1rem;   margin-bottom: 10px; }
h4{ font-size: .9rem;  color: var(--text-2); }
p { color: var(--text-2); }
a { color: var(--primary); text-decoration: none; }
a:hover{ text-decoration: underline; }

::selection{ background: var(--primary); color:#fff; }

/* Scrollbar */
*::-webkit-scrollbar{ width:10px; height:10px; }
*::-webkit-scrollbar-track{ background: transparent; }
*::-webkit-scrollbar-thumb{ background:#cbd5e1; border-radius:8px; }
*::-webkit-scrollbar-thumb:hover{ background:#94a3b8; }

/* =========================
   LAYOUT PRINCIPAL
========================= */
.container{
  display:flex;
  min-height: 100vh;
}

/* =========================
   SIDEBAR
========================= */
.sidebar{
  width: 240px;
  flex-shrink: 0;
  height: 100vh;
  position: sticky;
  top: 0;
  padding: 22px 14px;
  background: var(--grad-sidebar);
  color:#fff;
  display:flex;
  flex-direction: column;
  gap: 4px;
  box-shadow: var(--shadow-lg);
  overflow-y: auto;
}
.sidebar h2{
  text-align:center;
  width:100%;
  color:#fff;
  font-size: 1.2rem;
  padding: 4px 0 14px;
  margin: 0 0 12px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  background: linear-gradient(135deg,#60a5fa,#22d3ee);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.sidebar p{
  color: rgba(255,255,255,.7);
  font-size: .82rem;
  text-align: center;
  margin: 0 0 10px;
}
.logo-sidebar{
  width:140px;
  display:block;
  margin: 0 auto 22px;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,.4));
}
.logo-box{ display:flex; justify-content:center; align-items:center; margin-bottom:22px; }

.sidebar button{
  width:100%;
  text-align: left;
  margin: 3px 0;
  padding: 11px 14px;
  border-radius: 10px;
  background: rgba(255,255,255,.04);
  color: rgba(255,255,255,.85);
  border: 1px solid transparent;
  backdrop-filter: blur(6px);
  font-size: .92rem;
  font-weight: 500;
  cursor: pointer;
  transition: background .18s, transform .18s, border-color .18s, color .18s;
}
.sidebar button:hover{
  background: rgba(255,255,255,.12);
  color: #fff;
  transform: translateX(3px);
  border-color: rgba(255,255,255,.08);
}
.sidebar button.ativo{
  background: linear-gradient(135deg, rgba(37,99,235,.35), rgba(37,99,235,.15));
  color:#fff;
  border-color: rgba(96,165,250,.4);
  box-shadow: 0 4px 14px rgba(37,99,235,.35);
}

/* =========================
   CONTENT / SEÇÕES
========================= */
.content{
  flex: 1;
  padding: 26px 30px 90px;
  overflow-y: auto;
  min-height: 100vh;
  min-width: 0;
}

.secao{
  display: none;
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px 26px;
  box-shadow: var(--shadow-sm);
  animation: fadeUp .3s ease;
  height: fit-content;
}
.secao.ativa{ display: block !important; }
@keyframes fadeUp{
  from{ opacity:0; transform: translateY(6px); }
  to  { opacity:1; transform: translateY(0); }
}

/* =========================
   DASHBOARD (CARDS)
========================= */
.cards{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px,1fr));
  gap: 14px;
  margin-bottom: 24px;
}
.card{
  background: var(--surface);
  padding: 18px 20px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-xs);
  position: relative;
  overflow: hidden;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.card::before{
  content:"";
  position:absolute; left:0; top:0; bottom:0; width:4px;
  background: var(--grad-primary);
  border-radius: 4px 0 0 4px;
}
.card:hover{
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  border-color: #cbd5e1;
}
.card h3{
  margin-bottom: 10px;
  color: var(--text-dim);
  font-size: .78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .08em;
}
.card p{
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  margin: 0;
}
.card p strong{ color: var(--primary); }

.cards-abaixo{
  display: flex;
  margin-top: 16px;
  gap: 16px;
  flex-wrap: wrap;
}
.card-grande{
  flex: 1;
  min-width: 280px;
  padding: 22px 24px;
}
.card-grande h3{
  font-size: 1rem;
  text-transform: none;
  letter-spacing: 0;
  color: var(--text);
  margin-bottom: 14px;
}
/* =========================================
   SYNGEST — DASHBOARD REFINADO
   ========================================= */

#painel {
  background:
    radial-gradient(
      circle at 100% 0%,
      rgba(37, 99, 235, 0.045),
      transparent 35%
    ),
    var(--surface);
}

/* Cabeçalho do painel */
#painel .painel-cabecalho {
  margin-bottom: 26px;
}

#painel .painel-cabecalho h1 {
  margin-bottom: 6px;
  font-size: 1.75rem;
  font-weight: 800;
  letter-spacing: -0.045em;
}

#painel .painel-cabecalho h2 {
  margin: 0 0 6px;
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text-2);
}

#painel .painel-descricao {
  color: var(--text-dim);
  font-size: 0.92rem;
}

/* Indicadores principais */
#painel .painel-indicadores {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 24px;
}

#painel .painel-indicadores > .card {
  min-width: 0;
  min-height: 138px;
  padding: 23px 22px;
  border: 1px solid #e5eaf3;
  border-radius: 16px;
  background: linear-gradient(145deg, #ffffff, #fbfcff);
  box-shadow: 0 3px 12px rgba(15, 23, 42, 0.035);
}

#painel .painel-indicadores > .card::before {
  width: 3px;
  background: linear-gradient(
    180deg,
    #3b82f6,
    #2563eb
  );
}

#painel .painel-indicadores > .card:hover {
  transform: translateY(-3px);
  border-color: #cbdaf5;
  box-shadow: 0 12px 26px rgba(37, 99, 235, 0.08);
}

#painel .painel-indicadores > .card h3 {
  margin-bottom: 13px;
  color: #64748b;
  font-size: 0.73rem;
  font-weight: 700;
  letter-spacing: 0.09em;
}

#painel .painel-indicadores > .card p {
  font-size: 1.05rem;
  line-height: 1.65;
  font-weight: 700;
  overflow-wrap: anywhere;
}

#painel .painel-indicadores > .card p strong {
  color: #2563eb;
}

/* Conteúdo complementar */
#painel .painel-conteudo {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 20px;
}

#painel .painel-conteudo > .card {
  min-width: 0;
  padding: 24px;
  border: 1px solid #e5eaf3;
  border-radius: 16px;
  box-shadow: 0 3px 12px rgba(15, 23, 42, 0.035);
}

#painel .painel-conteudo > .card h3 {
  margin-bottom: 18px;
  color: #172033;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.015em;
  text-transform: none;
}

/* Adaptação para telas menores */
@media (max-width: 900px) {
  #painel .painel-indicadores {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }
}

@media (max-width: 480px) {
  #painel .painel-cabecalho h1 {
    font-size: 1.35rem;
  }

  #painel .painel-indicadores > .card {
    min-height: 120px;
    padding: 16px 14px;
  }

  #painel .painel-indicadores > .card p {
    font-size: 0.9rem;
  }

  #painel .painel-conteudo > .card {
    padding: 17px;
  }
}

/* =========================================
   SYNGEST — VALORES DOS INDICADORES
   ========================================= */

#painel .indicador-valor {
  display: block;
  margin: 2px 0 8px;
  color: #0f172a;
  font-size: 1.65rem;
  line-height: 1.25;
  font-weight: 800;
  letter-spacing: -0.045em;
  overflow-wrap: anywhere;
}

#painel .indicador-detalhe {
  display: block;
  margin-top: 5px;
  color: #64748b;
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0;
}

#painel .status-ativo {
  color: #10b981;
  margin-right: 5px;
}

#painel .status-inativo {
  color: #ef4444;
  margin-right: 5px;
}

#painel #totalJogadores .indicador-valor {
  color: #2563eb;
}

#painel #totalMesAtual .indicador-valor,
#painel #totalAno .indicador-valor {
  color: #047857;
}

#painel #saldoTurma .indicador-valor {
  color: #047857;
}

@media (max-width: 480px) {
  #painel .indicador-valor {
    font-size: 1.3rem;
  }

  #painel .indicador-detalhe {
    font-size: 0.76rem;
  }
}

/* =========================
   TABELAS
========================= */
table{
  width:100%;
  border-collapse: separate;
  border-spacing: 0;
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-xs);
  border: 1px solid var(--border);
  margin: 12px 0 18px;
  font-size: .92rem;
}
table th{
  background: var(--dark-2);
  color:#fff;
  padding: 12px 14px;
  text-align: left;
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .07em;
  text-transform: uppercase;
}
table td{
  padding: 11px 14px;
  border-bottom: 1px solid var(--border-soft);
  color: var(--text-2);
  vertical-align: middle;
}
table td:first-child{ text-align:left; }
table tbody tr{ transition: background .12s ease; }
table tbody tr:hover{ background: var(--surface-2); }
table tbody tr:last-child td{ border-bottom: none; }

table button{
  padding: 7px 11px;
  font-size: .82rem;
  height: auto;
}

/* =========================
   FORMULÁRIOS
========================= */
input, select, textarea{
  padding: 10px 12px;
  margin: 5px 5px 10px 0;
  border-radius: 10px;
  border: 1px solid #cbd5e1;
  background: #fff;
  color: var(--text);
  font-size: .92rem;
  font-family: inherit;
  transition: border-color .15s, box-shadow .15s, background .15s;
  min-width: 160px;
}
input::placeholder, textarea::placeholder{ color: var(--text-mute); }
input:focus, select:focus, textarea:focus{
  outline: none;
  border-color: var(--primary);
  box-shadow: var(--ring);
}

/* =========================
   BOTÕES
========================= */
button{
  background: var(--grad-primary);
  color:#fff;
  border:none;
  padding: 9px 16px;
  border-radius: 10px;
  cursor: pointer;
  font-size: .9rem;
  font-weight: 600;
  letter-spacing: .01em;
  transition: transform .12s ease, box-shadow .15s ease, filter .15s ease;
  box-shadow: 0 4px 10px rgba(37,99,235,.22);
  margin: 3px 4px 3px 0;
}
button:hover{
  transform: translateY(-1px);
  filter: brightness(1.05);
  box-shadow: 0 8px 18px rgba(37,99,235,.28);
}
button:active{ transform: translateY(0); filter: brightness(.95); }
button:disabled{ opacity:.55; cursor:not-allowed; box-shadow:none; transform:none; }

/* Variantes por seletor existente */
button[onclick*="excluir"],
button[onclick*="remover"],
.btn-excluir{
  background: var(--grad-danger);
  box-shadow: 0 4px 10px rgba(239,68,68,.25);
}
button[onclick*="excluir"]:hover,
button[onclick*="remover"]:hover,
.btn-excluir:hover{
  box-shadow: 0 8px 18px rgba(239,68,68,.32);
}

.btn-editar{
  background: var(--grad-warn);
  margin-right: 5px;
  color:#3b2503;
  box-shadow: 0 4px 10px rgba(245,158,11,.25);
}

#btnGerarLink{
  background: var(--grad-whats);
  box-shadow: 0 4px 10px rgba(37,211,102,.25);
}
#btnSalvarJogo{
  background: var(--grad-success);
  box-shadow: 0 4px 10px rgba(16,185,129,.25);
}
#btnLimparJogo{
  background: var(--grad-danger);
  box-shadow: 0 4px 10px rgba(239,68,68,.25);
}

/* .btn helper class */
.btn{
  background: var(--grad-primary);
  color:#fff;
  border:none;
  padding: 9px 16px;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
  transition: .2s;
}
.btn:hover{ filter: brightness(1.06); }
.btn-danger{ background: var(--grad-danger); }
.btn-danger:hover{ filter: brightness(1.06); }

/* =========================
   TÍTULOS COM TOGGLE
========================= */
.toggle-title{
  cursor: pointer;
  user-select: none;
  margin-top: 18px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 11px 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: background .15s, color .15s, border-color .15s;
}
.toggle-title:hover{
  color: var(--primary);
  background: var(--primary-soft);
  border-color: #bfdbfe;
}

/* h3 com onclick (financeiro) */
#financeiro h3[onclick]{
  cursor: pointer;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 11px 16px;
  margin: 18px 0 10px;
  transition: background .15s, color .15s, border-color .15s;
}
#financeiro h3[onclick]:hover{
  color: var(--primary);
  background: var(--primary-soft);
  border-color: #bfdbfe;
}

/* =========================
   ANIVERSÁRIOS
========================= */
.aniversario-card,
.card-aniversario{
  background: var(--surface);
  padding: 14px;
  margin-bottom: 10px;
  border-radius: 12px;
  border-left: 4px solid var(--primary);
  box-shadow: var(--shadow-xs);
  transition: transform .15s, box-shadow .15s;
}
.aniversario-card:hover,
.card-aniversario:hover{
  transform: translateX(4px);
  box-shadow: var(--shadow-sm);
}
#listaAniversarios{
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px,1fr));
  gap: 12px;
  margin-top: 10px;
}
.card-aniversario.hoje{
  background: linear-gradient(135deg,#ff9800,#ff5722);
  color:#fff;
  font-weight: 700;
  border-left-color: #ffd166;
  box-shadow: 0 8px 20px rgba(255,87,34,.25);
}

/* =========================
   RANKING
========================= */
.ranking-item{
  display: flex;
  flex-direction: column;
  width: 100%;
  background: var(--surface);
  margin-bottom: 10px;
  padding: 12px 16px;
  border-radius: 12px;
  border-left: 4px solid var(--primary);
  box-shadow: var(--shadow-xs);
  transition: transform .12s, box-shadow .15s;
}
.ranking-item:hover{
  transform: translateX(3px);
  box-shadow: var(--shadow-sm);
}
.ranking-header{
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  cursor: pointer;
}
.ranking-left{
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
}
.ranking-right{
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 120px;
  justify-content: flex-end;
}
.ranking-pontos, .ranking-nome{ white-space: nowrap; }
.ranking-right button{
  background: var(--grad-danger);
  border: none;
  border-radius: 8px;
  padding: 6px 10px;
  color:#fff;
  cursor: pointer;
  font-size: .82rem;
}
.ranking-body{
  display: none;
  width: 100%;
  margin-top: 10px;
}

/* Barra de progresso */
.barra{
  background: #e2e8f0;
  border-radius: 8px;
  overflow: hidden;
  height: 18px;
}
.progresso{
  background: var(--grad-primary);
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color:#fff;
  font-size: 11px;
  font-weight: 700;
  transition: width .4s ease;
}

/* =========================
   HISTÓRICO
========================= */
.historico-card{
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 14px;
  box-shadow: var(--shadow-xs);
  transition: transform .12s, box-shadow .15s;
}
.historico-card:hover{ transform: translateY(-2px); box-shadow: var(--shadow-sm); }

/* =========================
   LOGIN
========================= */
.login-container{
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  background:
    radial-gradient(800px 500px at 20% 20%, rgba(37,99,235,.25), transparent 60%),
    radial-gradient(800px 500px at 80% 80%, rgba(14,165,233,.18), transparent 60%),
    linear-gradient(135deg,#0f172a,#1e293b);
  padding: 20px;
}
.login-box{
  background: rgba(30,41,59,.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  padding: 38px 32px;
  border-radius: 16px;
  width: 100%;
  max-width: 360px;
  text-align: center;
  border: 1px solid rgba(255,255,255,.08);
  box-shadow: 0 20px 60px rgba(0,0,0,.45);
  animation: fadeUp .4s ease;
}
.login-box h2{
  color:#fff;
  margin-bottom: 22px;
  background: linear-gradient(135deg,#60a5fa,#22d3ee);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.login-box input{
  width: 100%;
  padding: 13px 14px;
  margin-bottom: 12px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,.08);
  background: #f1f5f9;
  color: var(--text);
  font-size: 1rem;
}
.login-box input:focus{
  outline: none;
  border-color: #60a5fa;
  box-shadow: 0 0 0 3px rgba(96,165,250,.3);
}
#btnLogin{
  width: 100%;
  padding: 13px;
  background: var(--grad-primary);
  color:#fff;
  border: none;
  border-radius: 10px;
  font-size: 1rem;
  font-weight: 600;
  margin-top: 4px;
  box-shadow: 0 8px 22px rgba(37,99,235,.35);
}
#btnLogin:hover{ filter: brightness(1.08); }

/* =========================
   MODAL
========================= */
.modal{
  position: fixed;
  inset: 0;
  background: rgba(15,23,42,.6);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 999;
  padding: 20px;
}
.modal-content{
  background: #fff;
  padding: 28px 26px;
  border-radius: 16px;
  width: 100%;
  max-width: 360px;
  text-align: center;
  color: var(--text);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  animation: fadeUp .3s ease;
}
.modal-content h2{ margin-top: 0; color: var(--text); }
.modal-content select{ width: 100%; margin-bottom: 14px; }
.modal-content button{ width: 100%; }

/* =========================
   TOAST
========================= */
#toast{
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--dark-2);
  color:#fff;
  padding: 12px 20px;
  border-radius: 999px;
  font-size: .9rem;
  font-weight: 500;
  visibility: hidden;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .25s ease, transform .25s ease, visibility .25s;
  box-shadow: var(--shadow-lg);
  z-index: 2000;
  border: 1px solid rgba(255,255,255,.08);
}
#toast.show{
  visibility: visible;
  opacity: 1;
  transform: translateY(0);
}

/* =========================
   CONFIGURAÇÕES
========================= */
#configuracoes h2{ margin-bottom: 16px; }
#configuracoes h3{ margin-top: 22px; margin-bottom: 10px; }
#configuracoes input{ margin-top: 8px; }
#configuracoes button{ margin-left: 8px; }

.menu-config{
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 22px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}
.menu-config button{
  background: var(--surface-2);
  color: var(--text-2);
  border: 1px solid var(--border);
  box-shadow: none;
  font-weight: 500;
}
.menu-config button:hover{
  background: var(--primary-soft);
  color: var(--primary-2);
  border-color: #bfdbfe;
  box-shadow: none;
}

.aba-config{
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 22px;
}

#aba-permissoes{ padding: 22px; }
#aba-permissoes h3{ margin-bottom: 14px; }
#aba-permissoes h4{
  margin-top: 18px;
  margin-bottom: 10px;
  color: var(--text);
  font-size: .9rem;
  text-transform: uppercase;
  letter-spacing: .06em;
}
#aba-permissoes label{
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 4px 14px 4px 0;
  cursor: pointer;
  color: var(--text-2);
  font-size: .92rem;
}
#aba-permissoes input[type="checkbox"]{
  width: 16px; height: 16px;
  accent-color: var(--primary);
  margin: 0; min-width: auto;
}
#aba-permissoes select{
  padding: 9px 12px;
  margin-bottom: 14px;
  border-radius: 8px;
  border: 1px solid #cbd5e1;
}
#aba-permissoes button{ margin-top: 14px; }

/* =========================
   SECTION (helper)
========================= */
.section{
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 16px 18px;
  margin-bottom: 16px;
  box-shadow: var(--shadow-xs);
  transition: transform .15s ease, box-shadow .15s ease;
}
.section h3{ margin-bottom: 10px; font-weight: 600; }
.section:hover{ transform: translateY(-2px); box-shadow: var(--shadow-sm); }

/* =========================
   PAGAMENTOS / FINANCEIRO
========================= */
#grupoPagamentos{ margin-top: 12px; }

.mes-card{
  background: linear-gradient(135deg,#1e293b,#0f172a);
  color:#fff;
  padding: 12px 16px;
  border-radius: 10px;
  margin: 12px 0 8px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: var(--shadow-xs);
  transition: transform .12s, box-shadow .15s;
}
.mes-card:hover{
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.card-pagamento{
  background: var(--surface);
  padding: 12px 14px;
  margin: 6px 0;
  border-radius: 10px;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-xs);
  transition: transform .12s, box-shadow .15s, border-color .15s;
}
.card-pagamento:hover{
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
  border-color: #cbd5e1;
}

.detalhe-pagamento{
  background: var(--surface-2);
  padding: 12px 14px;
  border-radius: 10px;
  margin-bottom: 12px;
  border: 1px solid var(--border-soft);
  font-size: .9rem;
}

/* =========================
   JOGADORES — CARDS MOBILE
========================= */
.card-jogador{
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 10px;
  box-shadow: var(--shadow-xs);
}
.card-header{
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.card-detalhe{
  margin-top: 10px;
  font-size: .88rem;
  color: var(--text-2);
  border-top: 1px solid var(--border-soft);
  padding-top: 10px;
}
.acoes button{ margin-right: 5px; }

.mobile-actions{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 10px;
}
.mobile-actions button{ width: 100%; }

#secao_ativos, #secao_inativos{ transition: all .3s ease; }

/* =========================================
   EDIÇÃO DE JOGADOR — MOBILE
========================================= */

@media (max-width: 768px) {

  .edicao-jogador-mobile {
    width: 100%;
    max-width: 100%;
    display: flex;
    flex-direction: column;
    gap: 6px;
    box-sizing: border-box;
  }

  .edicao-jogador-mobile label {
    margin-top: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-2);
  }

  .edicao-jogador-mobile input,
  .edicao-jogador-mobile select {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
    margin: 0;
  }

  .jogador-acoes-mobile {
    display: flex;
    gap: 8px;
    margin-top: 16px;
  }

  .jogador-acoes-mobile button {
    flex: 1;
    min-width: 0;
  }

}

@media (max-width: 768px) {

  .detalhe-jogador {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow: hidden;
  }

}

/* =========================================
   LISTA DESKTOP - JOGADORES
========================================= */

.jogador-linha {
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.jogador-linha > td {
  padding: 0 !important;
  border-bottom: 1px solid var(--border-soft);
}

.jogador-linha:last-child > td {
  border-bottom: none;
}

.jogador-linha:hover {
  background: var(--surface-hover);
}

.jogador-resumo {
  min-height: 54px;
  padding: 0 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text);
  background: var(--surface);
  transition: background 0.2s ease;
}

.jogador-resumo:hover {
  background: var(--surface-soft);
}

.jogador-seta {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: var(--text-2);
  font-size: 16px;
  transition: all 0.2s ease;
}

.detalhe-jogador-desktop {
  padding: 18px 22px 18px;
  background: var(--surface-soft);
  border-top: 1px solid var(--border-soft);
  cursor: default;
}

.jogador-info {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px 28px;
  font-size: 0.88rem;
  color: var(--text-2);
}

.jogador-info > div {
  line-height: 1.4;
  padding: 2px 0;
}

.jogador-info strong {
  display: block;
  color: var(--text-2);
  font-size: 0.76rem;
  font-weight: 600;
  margin-bottom: 2px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.jogador-acoes {
  display: flex;
  gap: 8px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--border-soft);
}

.jogador-acoes button {
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  border-radius: 8px;
  padding: 8px 14px;
  cursor: pointer;
  font-size: 0.85rem;
  transition: all 0.2s ease;
}

.jogador-acoes button:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-xs);
}

@media (min-width: 769px) {

  #tabelaJogadores thead,
  #tabelaJogadoresInativos thead {
    display: none;
  }

}

/* =========================================
   CADASTRO DE JOGADOR - MENU EXPANSÍVEL
========================================= */

#cadastroJogador {
  margin-bottom: 18px;
}

.cadastro-jogador-header {
  min-height: 54px;
  padding: 0 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--surface-soft);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s ease;
}

.cadastro-jogador-header:hover {
  background: var(--surface-hover);
}

#formularioCadastroJogador {
  display: none;
  margin-top: 10px;
  padding: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
}

.formulario-cadastro-jogador {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.formulario-cadastro-jogador input,
.formulario-cadastro-jogador select {
  width: 100%;
}

.formulario-cadastro-jogador button {
  width: fit-content;
  padding: 9px 18px;
}

.cadastro-jogador-header .titulo-secao {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -.01em;
  color: var(--text);
}

/* =========================
   UTILIDADES
========================= */
hr{
  margin: 24px 0;
  border: none;
  height: 1px;
  background: var(--border);
}

#jogos{
  color: var(--text);
  width: calc(100% + 60px) !important;
  max-width: none !important;
  min-height: 100vh;
  margin-left: -30px !important;
  margin-right: -30px !important;
  box-sizing: border-box;
}

/* Receita por mês */
#receitaPorMes{
  display: grid;
  gap: 8px;
}

/* =========================
   BOTTOM NAV
========================= */
.bottom-nav{ display: none; }

/* =========================
   RESPONSIVO
========================= */
@media (max-width: 900px){
  .content{ padding: 18px 16px 90px; }
  .secao{ padding: 18px; border-radius: 14px; }
  .cards{ grid-template-columns: repeat(auto-fit,minmax(150px,1fr)); }
}

@media (max-width: 768px){
  .sidebar{ display: none; }

  .bottom-nav{
    display: flex;
    position: fixed;
    bottom: 0; left: 0; right: 0;
    background: var(--dark);
    padding: 10px calc(10px + env(safe-area-inset-right)) calc(10px + env(safe-area-inset-bottom)) calc(10px + env(safe-area-inset-left));
    justify-content: space-around;
    z-index: 999;
    box-shadow: 0 -8px 24px rgba(0,0,0,.25);
    border-top: 1px solid rgba(255,255,255,.06);
  }
  .bottom-nav button{
  flex: 1;
  max-width: 90px;
  background: none;
  border: none;
  color: rgba(255,255,255,.75);
  box-shadow: none;
  padding: 5px 2px;
  margin: 0;
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  transition: background .15s, color .15s;
}

.bottom-nav button span{
  font-size: 1.2rem;
  line-height: 1;
}

.bottom-nav button small{
  font-size: .62rem;
  line-height: 1.1;
  white-space: nowrap;
}
  .bottom-nav button:hover,
  .bottom-nav button:active{
    background: rgba(255,255,255,.08);
    color: #fff;
    transform: none;
  }

  .content{ padding-bottom: 80px; }

  button{ height: 44px; font-size: .95rem; }

  input, select{
    width: 100%;
    height: 44px;
    font-size: 16px;   /* evita zoom iOS */
    margin-right: 0;
  }

  /* Tabelas viram cards */
  table{ display: block; background: transparent; box-shadow: none; border: none; }
  thead{ display: none; }
  tr{
    display: block;
    background: var(--surface);
    margin-bottom: 10px;
    border-radius: 12px;
    padding: 12px 14px;
    box-shadow: var(--shadow-xs);
    border: 1px solid var(--border);
  }
  td{
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 6px 0;
    border: none;
    color: var(--text-2);
  }
  td::before{
    content: attr(data-label);
    font-weight: 600;
    color: var(--text);
    font-size: .82rem;
  }

  h1{ font-size: 1.15rem; text-align: center; }

  .modo-mobile .tabela-desktop{ display: none; }
  .modo-mobile .card-jogador{ display: block; }

  .cards{ grid-template-columns: 1fr 1fr; gap: 10px; }
  .card{ padding: 14px; }
  .card p{ font-size: .95rem; }

  .cards-abaixo{ flex-direction: column; }
  .card-grande{ min-width: 0; }

  #toast{
    left: 16px;
    right: 16px;
    bottom: 80px;
    text-align: center;
  }
}

.lgpd-box{
  margin-top: 12px;
  margin-bottom: 10px;
  text-align: left;
}

.lgpd-label{
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: #94a3b8;
  cursor: pointer;
}

.lgpd-label input{
  width: 16px;
  height: 16px;
  cursor: pointer;
}

.lgpd-label a{
  color: #38bdf8;
  text-decoration: none;
  font-weight: 500;
}

.lgpd-label a:hover{
  text-decoration: underline;
}

.linha-mes {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  border-bottom: 1px solid #eee;
}

.linha-dupla {
  display: flex;
  gap: 20px;
}

.linha-dupla .card {
  flex: 1;
}

@media (max-width: 768px) {
  .linha-dupla {
    flex-direction: column;
  }
}

#proximosAniversarios {
  max-height: 200px;
  overflow-y: auto;
}

.btn-expandir {
  margin-top: 10px;
  padding: 10px;
  width: 100%; /* 🔥 ISSO RESOLVE */
  border: none;
  background: linear-gradient(90deg, #2563eb, #1d4ed8);
  color: white;
  border-radius: 10px;
  cursor: pointer;
  font-weight: bold;
}

.btn-expandir:hover {
  opacity: 0.9;
}

.card:nth-child(1) .btn-expandir {
  background: linear-gradient(90deg, #16a34a, #15803d); /* receita verde */
}

.card:nth-child(2) .btn-expandir {
  background: linear-gradient(90deg, #dc2626, #b91c1c); /* despesa vermelho */
}

@media (max-width: 768px){

  .bottom-nav button span,
  .bottom-nav button small,
  .bottom-nav button label{
    display: none !important;
  }

}

/* =========================================
   CADASTRO DE JOGO
========================================= */

.cadastro-jogo-header {
  width: 100%;
  box-sizing: border-box;
  padding: 14px 18px;
  margin-bottom: 12px;
  background: var(--surface-soft);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -.01em;
  cursor: pointer;
}

.cadastro-jogo-header:hover {
  background: var(--surface);
}

.formulario-cadastro-jogo {
  padding: 18px;
  margin-bottom: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
}

.jogos-agendados-header {
  width: 100%;
  box-sizing: border-box;
  padding: 14px 18px;
  margin-top: 12px;
  margin-bottom: 12px;
  background: var(--surface-soft);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -.01em;
  cursor: pointer;
}

.jogos-agendados-header:hover {
  background: var(--surface);
}

#financeiro{
  width: calc(100% + 60px) !important;
  max-width: none !important;
  min-height: 100vh;
  margin-left: -30px !important;
  margin-right: -30px !important;
  margin-top: -26px !important;
  box-sizing: border-box;
}

/* ============================= */
/* MODAL DE CONFIRMAÇÃO */
/* ============================= */

.modal-confirmacao {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  align-items: center;
  justify-content: center;
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(3px);
}

.modal-confirmacao-box {
  width: min(420px, calc(100% - 32px));
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  text-align: center;
  animation: fadeUp .2s ease;
}

.modal-confirmacao-icone {
  width: 52px;
  height: 52px;
  margin: 0 auto 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fee2e2;
  border-radius: 50%;
  font-size: 24px;
}

.modal-confirmacao-box h3 {
  margin-bottom: 10px;
  color: var(--text);
  font-size: 1.2rem;
}

.modal-confirmacao-box p {
  margin-bottom: 6px;
  color: var(--text-2);
  font-size: .95rem;
}

.modal-confirmacao-box > span {
  display: block;
  margin-bottom: 24px;
  color: var(--text-dim);
  font-size: .85rem;
}

.modal-confirmacao-acoes {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.btn-cancelar-confirmacao,
.btn-excluir-confirmacao {
  padding: 10px 18px;
  border-radius: 10px;
  border: 1px solid var(--border);
  font-weight: 600;
  cursor: pointer;
}

.btn-cancelar-confirmacao {
  background: var(--surface-2);
  color: var(--text-2);
}

.btn-excluir-confirmacao {
  background: var(--danger);
  color: white;
  border-color: var(--danger);
}

.btn-cancelar-confirmacao:hover {
  background: var(--surface-3);
}

.btn-excluir-confirmacao:hover {
  background: var(--danger-2);
}


/* ============================= */
/* RELATÓRIOS */
/* ============================= */

.relatorio-card{
  margin-bottom: 18px;
  padding: 22px;
  border: 1px solid #dbe3ef;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.04);
}

.relatorio-cabecalho{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  cursor: pointer;
}

.relatorio-cabecalho h3{
  margin: 0 0 7px;
  color: #172033;
  font-size: 17px;
}

.relatorio-cabecalho p{
  margin: 0;
  color: #64748b;
  font-size: 13px;
}

.relatorio-cabecalho > span{
  color: #2563eb;
  font-size: 16px;
  font-weight: 700;
}

.relatorio-filtros{
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid #e2e8f0;
}

.filtros-relatorio{
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 18px;
}

.filtros-relatorio > div{
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.relatorio-filtros label{
  color: #475569;
  font-size: 13px;
  font-weight: 600;
}

.relatorio-filtros input,
.relatorio-filtros select,
.relatorio-filtros > select{
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

.relatorio-filtros button{
  margin-top: 4px;
}

#resultadoRelatorioAvaliacao,
#rankingAvaliacoes{
  margin-top: 16px;
}

@media (max-width: 700px){

  .relatorio-card{
    padding: 16px;
  }

  .filtros-relatorio{
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .relatorio-cabecalho h3{
    font-size: 15px;
  }

}
/* =====================================
   PAINEL — PRÓXIMOS JOGOS
===================================== */

#painelProximosJogos .historico-card {
  padding: 18px 20px;
  margin-bottom: 12px;
  border-radius: 14px;
  border-left: 4px solid var(--primary, #356dff);
  background: var(--surface);
  box-shadow: var(--shadow-xs);
  transition: transform .18s ease, box-shadow .18s ease;
}

#painelProximosJogos .historico-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

#painelProximosJogos .historico-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

#painelProximosJogos .historico-header > div {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 16px;
}

#painelProximosJogos .historico-header strong {
  color: var(--text);
  font-size: 15px;
  font-weight: 700;
}

#painelProximosJogos .historico-header > span {
  color: var(--text-muted, #64748b);
  font-size: 12px;
  font-weight: 600;
}

@media (max-width: 600px) {
  #painelProximosJogos .historico-card {
    padding: 15px;
  }

  #painelProximosJogos .historico-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  #painelProximosJogos .historico-header > div {
    gap: 10px;
  }
}
/* Ajustes finais — Próximos jogos */

#painel .painel-proximos-jogos {
  margin-top: 28px;
  margin-bottom: 12px;
}

#painel .painel-proximos-jogos .painel-bloco-titulo {
  margin-bottom: 14px;
}

#painel .painel-proximos-jogos .painel-bloco-titulo h3 {
  margin-bottom: 6px;
}

#painel .painel-proximos-jogos .painel-bloco-titulo p {
  margin-top: 0;
}

/* ========================================
   GRÁFICO DE MENSALIDADES — DASHBOARD
======================================== */

.grafico-mensalidade {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px minmax(0, 1fr);
    align-items: center;
    gap: 24px;
    width: 100%;
    box-sizing: border-box;
}

.grafico-mensalidade-info {
    min-width: 0;
}

.grafico-mensalidade-info h4 {
    margin: 0 0 8px;
}

.grafico-mensalidade-info p {
    margin: 0 0 16px;
    color: #64748b;
    font-size: 13px;
}

.grafico-legenda {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.grafico-legenda-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}

.grafico-legenda-item strong {
    margin-left: auto;
}

.grafico-ponto {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.grafico-pago {
    background: #3478F6;
}

.grafico-nao-pago {
    background: #DC4545;
}

.grafico-mensalidade-visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

.grafico-circular {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.grafico-circular-centro {
    width: 112px;
    height: 112px;
    border-radius: 50%;
    background: #ffffff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.grafico-circular-centro strong {
    font-size: 27px;
    color: #1e293b;
}

.grafico-circular-centro span {
    font-size: 12px;
    color: #64748b;
}

@media (max-width: 700px) {
    .grafico-mensalidade {
        grid-template-columns: minmax(0, 1fr) 130px;
        gap: 12px;
    }

    .grafico-mensalidade-visual {
        grid-column: 2;
        grid-row: 1;
    }

    .grafico-circular {
        width: 120px;
        height: 120px;
    }

    .grafico-circular-centro {
        width: 84px;
        height: 84px;
    }

    .grafico-circular-centro strong {
        font-size: 22px;
    }
}

@media (max-width: 380px) {
    .grafico-mensalidade {
        grid-template-columns: 1fr;
    }

    .grafico-mensalidade-visual {
        grid-column: 1;
        grid-row: auto;
    }
}

/* Visão da turma — card compacto */

.card.card-grande.painel-destaques {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}


.card.card-grande.painel-destaques .grafico-mensalidade {
    grid-template-columns: 1fr;
    gap: 16px;
}

.card.card-grande.painel-destaques .grafico-mensalidade-visual {
    grid-column: 1;
    grid-row: auto;
}

.card.card-grande.painel-destaques .grafico-circular {
    width: 140px;
    height: 140px;
}

.card.card-grande.painel-destaques .grafico-circular-centro {
    width: 98px;
    height: 98px;
}

@media (max-width: 900px) {
    .card.card-grande.painel-destaques {
        width: 100%;
        max-width: 100%;
    }
}

/* CABEÇALHO DA VISÃO DA TURMA */
.painel-destaques-cabecalho {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 24px;
}

.painel-destaques-cabecalho h3 {
    margin: 0 0 6px;
}

.painel-destaques-cabecalho p {
    margin: 0;
    color: #64748b;
    font-size: 13px;
    line-height: 1.5;
}

.painel-destaques-icone {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #eff6ff;
    border-radius: 12px;
    font-size: 19px;
}

/* ORGANIZAÇÃO DO GRÁFICO */


.card.card-grande.painel-destaques #resumoTurma {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 32px;
    row-gap: 24px;
    align-items: start;
}

.card.card-grande.painel-destaques .grafico-mensalidade {
    min-width: 0;
}

.card.card-grande.painel-destaques .grafico-mensalidade-info {
    padding: 0 4px;
}


.card.card-grande.painel-destaques .grafico-mensalidade {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
    min-width: 0;
}


.card.card-grande.painel-destaques .grafico-mensalidade-info {
    width: 100%;
}

.grafico-mensalidade-titulo h4 {
    margin: 0 0 8px;
    font-size: 14px;
}

.grafico-mensalidade-titulo p {
    margin: 0 0 18px;
    color: #64748b;
    font-size: 12px;
    line-height: 1.5;
}

.grafico-legenda-identificacao {
    display: flex;
    align-items: center;
    gap: 9px;
}

.card.card-grande.painel-destaques .grafico-legenda {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.card.card-grande.painel-destaques .grafico-legenda-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    font-size: 13px;
}

.card.card-grande.painel-destaques .grafico-mensalidade-visual {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.card.card-grande.painel-destaques .grafico-circular {
    width: 150px;
    height: 150px;
    flex-shrink: 0;
}

.card.card-grande.painel-destaques .grafico-circular-centro {
    width: 106px;
    height: 106px;
}

@media (max-width: 900px) {
    .card.card-grande.painel-destaques {
        width: 100%;
        max-width: 100%;
    }
}

/* Refinamento visual do card de mensalidades */
.card.card-grande.painel-destaques .painel-destaques-cabecalho {
    margin-bottom: 20px;
}

.card.card-grande.painel-destaques .grafico-mensalidade {
    gap: 16px;
}

.card.card-grande.painel-destaques .grafico-mensalidade-titulo p {
    margin-bottom: 14px;
}

.card.card-grande.painel-destaques .grafico-legenda {
    gap: 10px;
}

.card.card-grande.painel-destaques .grafico-mensalidade-visual {
    margin-top: 0;
}

.card.card-grande.painel-destaques .grafico-circular {
    width: 132px;
    height: 132px;
}

.card.card-grande.painel-destaques .grafico-circular-centro {
    width: 94px;
    height: 94px;
}

/* Espaçamento entre os painéis do dashboard */
.painel-proximos-jogos {
    margin-top: 24px;
    width: 100%;
    box-sizing: border-box;
}

.painel-proximos-jogos .painel-bloco-titulo {
    margin-bottom: 16px;
}

.painel-proximos-jogos .painel-bloco-titulo h3 {
    margin-top: 0;
}

@media (max-width: 600px) {
    .card.card-grande.painel-destaques #resumoTurma {
        grid-template-columns: 1fr;
    }
}


/* DASHBOARD — CARDS DE GRÁFICOS INDEPENDENTES */

#painel .painel-conteudo {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    align-items: start;
}

#painel .painel-conteudo > .card-grafico-individual {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin: 0;
}

#painel .card-grafico-individual .painel-destaques-cabecalho {
    margin-bottom: 18px;
}

#painel .card-grafico-individual .grafico-mensalidade-info {
    width: 100%;
}

#painel .card-grafico-individual .grafico-mensalidade-visual {
    width: 100%;
    margin-top: 20px;
}

#painel .painel-conteudo > .painel-proximos-jogos {
    grid-column: 1 / -1;
    grid-row: 2;
    min-width: 0;
}

#painel .painel-conteudo > .painel-aniversarios {
    grid-column: 1 / -1;
    grid-row: 3;
    min-width: 0;
}

@media (max-width: 900px) {
    #painel .painel-conteudo {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    #painel .painel-conteudo > .painel-proximos-jogos {
        grid-column: 1 / -1;
    }
}

@media (max-width: 600px) {
    #painel .painel-conteudo {
        grid-template-columns: 1fr;
    }

    #painel .painel-conteudo > .card-grafico-individual {
        grid-column: 1;
        grid-row: auto;
    }

    #painel .painel-conteudo > .painel-proximos-jogos {
        grid-column: 1;
        grid-row: auto;
    }

    #painel .painel-conteudo > .painel-aniversarios {
        grid-column: 1;
        grid-row: auto;
    }
}
