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

/* ========== PALETA DE CORES — RouteSec Defender ========== */
:root {
  /* Verde floresta — cor principal da marca (fundo da logo) */
  --primary-blue: #1E4A37;
  --primary-blue-dark: #143528;
  --primary-blue-light: #E7EDE9;

  /* Aliases do verde (nomes antigos mantidos por compatibilidade) */
  --accent-purple: #1E4A37;
  --accent-purple-dark: #143528;
  --accent-purple-light: rgba(30, 74, 55, 0.1);

  /* Acentos quentes — laranja e magenta da "rota" na logo */
  --accent-orange: #E8782F;
  --accent-orange-dark: #C45B18;
  --accent-magenta: #C5286E;
  --accent-magenta-dark: #9E1A52;

  /* Creme/off-white usado no texto da logo */
  --brand-cream: #F5EFE0;

  /* Gradiente híbrido (nav, cartões) — verde floresta */
  --gradient-primary: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-blue-dark) 100%);
  /* Gradiente da "rota" — laranja → magenta (usar em destaques pontuais) */
  --gradient-accent: linear-gradient(135deg, var(--accent-orange) 0%, var(--accent-magenta) 100%);
  --gradient-hybrid: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-blue-dark) 100%);

  /* Tons neutros */
  --text-primary: #333;
  --text-secondary: #666;
  --text-muted: #888;
  --bg-light: #f6f7f8;
  --bg-white: #fff;
  --border-light: #e0e0e0;
  --shadow-light: rgba(0, 0, 0, 0.1);
  --shadow-medium: rgba(0, 0, 0, 0.15);
}

body {
  font-family: Arial, Helvetica, sans-serif;
  background-color: var(--bg-light);
  color: var(--text-primary);
}

/* ========== TOP NAVIGATION BAR ========== */
.top-nav {
  background: var(--gradient-hybrid);
  box-shadow: 0 2px 8px var(--shadow-light);
  position: sticky;
  top: 0;
  z-index: 1000;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.top-nav .nav-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
}

.top-nav .nav-icon {
  font-size: 24px;
  filter: brightness(0) invert(1);
}

.top-nav .nav-logo {
  width: 24px;
  height: 24px;
  object-fit: contain;
  filter: brightness(0) invert(1);
  flex-shrink: 0;
}

.top-nav .nav-title {
  font-size: 18px;
  font-weight: 700;
  color: white;
}

.top-nav .nav-info {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.top-nav .version-badge {
  background: var(--accent-purple-light);
  color: white;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.top-nav .mode-badge {
  background: rgba(255, 255, 255, 0.15);
  color: white;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.top-nav .nav-right {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  justify-content: flex-end;
}

.top-nav .acesso-restante {
  color: rgba(255, 255, 255, 0.85);
  font-size: 12px;
  font-weight: 500;
  padding: 5px 10px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  white-space: nowrap;
}
.top-nav .acesso-restante:empty {
  display: none;
}
.top-nav .acesso-restante.urgente {
  background: rgba(255, 152, 0, 0.25);
  border-color: rgba(255, 152, 0, 0.6);
  color: #ffcc80;
}

.top-nav .nav-back-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  color: white;
  text-decoration: none;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s ease;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.top-nav .nav-back-btn:hover {
  background: var(--accent-purple-light);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.2);
}

.top-nav .back-icon {
  font-size: 16px;
  transition: transform 0.2s ease;
}

.top-nav .nav-back-btn:hover .back-icon {
  transform: translateX(-2px);
}

.top-nav .nav-report-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  color: white;
  text-decoration: none;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s ease;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.top-nav .nav-report-btn:hover {
  background: rgba(102, 126, 234, 0.35);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.25);
}

.top-nav .nav-admin-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  color: white;
  text-decoration: none;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s ease;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.top-nav .nav-admin-btn[hidden] { display: none; }

.top-nav .nav-admin-btn:hover {
  background: rgba(102, 126, 234, 0.35);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.25);
}

.top-nav .nav-reset-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  color: white;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.top-nav .nav-reset-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.25);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.top-nav .reset-icon {
  font-size: 16px;
}

/* Header geral da página */
h1 {
  width: 95%;
  max-width: 1400px;
  margin: 32px auto 8px;
  font-size: 22px;
  font-weight: 600;
}

/* Container principal do quiz */
#quiz {
  width: 95%;
  max-width: 1400px;
  margin: 0 auto 40px;
  background-color: #fff;
  border: 1px solid #ddd;
  border-radius: 4px;
  padding: 32px;
  display: flex;
  flex-direction: column;
}

/* Cabeçalho interno */
#cabecalho-quiz {
  margin-bottom: 16px;
  border-bottom: 1px solid #e0e0e0;
  padding-bottom: 8px;
}

#cabecalho-quiz h2 {
  font-size: 18px;
  margin-bottom: 4px;
}

#cabecalho-quiz p {
  font-size: 13px;
  color: #666;
}

/* Indicadores de progresso */
#indicadores-progresso {
  display: flex;
  gap: 8px;
  row-gap: 10px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.indicador-questao {
  width: 24px;
  height: 8px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s ease;
  opacity: 0.7;
}

.indicador-questao:hover {
  opacity: 1;
  transform: translateY(-2px);
}

/* Desativa hover para indicadores não clicáveis (modo normal) */
.indicador-questao.nao-clicavel:hover {
  opacity: 0.7;
  transform: none;
}

.indicador-questao.atual {
  opacity: 1;
  height: 12px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Animação de transição entre questões */
@keyframes questao-slide-in {
  from { transform: translateX(24px); opacity: 0; }
  to   { transform: translateX(0);    opacity: 1; }
}

.questao-slide-in {
  animation: questao-slide-in 0.22s ease;
}

/* Layout de duas colunas */
#conteudo-quiz {
  display: flex;
  gap: 32px;
  margin-top: 16px;
}

/* Colunas (pergunta e resposta) */
#coluna-pergunta,
#coluna-resposta {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 400px;
}

/* Coluna da pergunta */
#texto-pergunta {
  flex: 1;
  font-size: 16px;
  line-height: 1.6;
  min-height: 6em;
  padding: 8px 0;
}

/* Blocos de tabela/log dentro do enunciado — preserva alinhamento monoespaçado */
#texto-pergunta pre {
  font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
  font-size: 13px;
  line-height: 1.4;
  background: rgba(0, 0, 0, 0.03);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 6px;
  padding: 12px;
  margin: 12px 0;
  overflow-x: auto;
  white-space: pre;
  color: #2a2a2a;
}

@media (max-width: 768px) {
  #texto-pergunta pre {
    font-size: 11px;
    padding: 8px;
  }
}

/* Código inline no enunciado, alternativas e justificativa — fonte
   monoespaçada com fundo sutil pra destacar comandos/payloads/paths */
#texto-pergunta code,
#lista-opcoes code,
#feedback-justificativa code {
  font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
  font-size: 0.92em;
  background: rgba(0, 0, 0, 0.05);
  padding: 1px 5px;
  border-radius: 3px;
  color: #2a2a2a;
  word-break: break-word;
}

@media (max-width: 768px) {
  #texto-pergunta code,
  #lista-opcoes code,
  #feedback-justificativa code {
    font-size: 0.85em;
  }
}

/* Quando <code> envolve a alternativa INTEIRA (única filha do span do
   botão), tira o fundo cinza pra não criar "caixa dentro de caixa".
   Mantém só a fonte monoespaçada — útil pra alternativas que são
   funções shell completas, regex, ou outros blocos de código curtos. */
#lista-opcoes .option-button span > code:only-child {
  background: transparent;
  padding: 0;
  font-size: 0.95em;
}

/* Coluna das respostas */
#lista-opcoes {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 8px 0;
}

/* Títulos “PERGUNTA” / “RESPOSTA” */
.titulo-secao {
  font-size: 16px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 12px;
}

/* Botões das alternativas */
.option-button {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 3.5em;
  padding: 0.9em 1em;
  margin-bottom: 10px;
  border: 2px solid #c0d2e0;
  border-radius: 8px;
  background-color: #fff;
  cursor: pointer;
  font-size: 15px;
  line-height: 1.5;
  text-align: left;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.1s ease;
}

/* Círculo de seleção à esquerda */
.option-circle {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid #1E4A37;
  margin-right: 10px;
  background-color: #fff;
  flex-shrink: 0; /* importante: impede que encolha */
  flex-grow: 0;   /* importante: impede que cresça */
}

.option-button:active {
  transform: scale(0.97);
  background-color: #e8f2fa;
  transition: transform 0.1s ease;
}

.option-button:hover {
  background-color: #f2f7fb;
  border-color: #1E4A37;
}

/* estados visuais de dúvida e certeza */
.option-button.estado-duvida .option-circle {
  background: linear-gradient(to right, #1E4A37 50%, #fff 50%);
  border-color: #1E4A37;
}

.option-button.estado-certeza .option-circle {
  background-color: #1E4A37;
  border-color: #1E4A37;
}

/* Checkbox para múltipla escolha */
.option-checkbox {
  width: 28px;
  height: 28px;
  border: 2px solid #1E4A37;
  border-radius: 4px;
  margin-right: 10px;
  background-color: #fff;
  flex-shrink: 0;
  flex-grow: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.option-checkbox.selecionado {
  background-color: #1E4A37;
}

.option-checkbox.selecionado::after {
  content: "✓";
  color: #fff;
  font-size: 18px;
  font-weight: bold;
}

/* Estilos para modo revisão */
.option-button.correta {
  border-color: #95c952 !important;
  background-color: #f0f9e8 !important;
}

.option-button.incorreta {
  border-color: #e74c3c !important;
  background-color: #fef5f5 !important;
}

.option-button.correta .option-circle,
.option-button.correta .option-checkbox {
  border-color: #95c952 !important;
  background-color: #95c952 !important;
}

.option-button.incorreta .option-circle,
.option-button.incorreta .option-checkbox {
  border-color: #e74c3c !important;
  background-color: #e74c3c !important;
}

.option-button:disabled {
  cursor: default !important;
  opacity: 0.9;
}

.option-button:disabled:hover {
  background-color: inherit;
}

/* Bloco de feedback / explicação */
#bloco-feedback {
  margin-top: 24px;
  border-top: 1px solid #e0e0e0;
  padding-top: 16px;
  order: 6;
}

#feedback-resultado {
  font-weight: 600;
  margin-bottom: 8px;
}

#feedback-justificativa {
  font-size: 14px;
  line-height: 1.5;
}

#feedback-sinalizador {
  margin-top: 6px;
  font-size: 13px;
  color: #666;
}

/* Rodapé com botão enviar/próxima */
#rodape-quiz {
  margin-top: 24px;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  order: 5;
}

#botao-finalizar-revisao {
  margin-right: auto;
  padding: 10px 24px;
  border-radius: 24px;
  border: 2px solid var(--primary-color, #1E4A37);
  background: transparent;
  color: var(--primary-color, #1E4A37);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

#botao-finalizar-revisao:hover {
  background: var(--primary-color, #1E4A37);
  color: white;
}

#btn-finalizar-simulado {
  margin-right: auto;
  padding: 10px 24px;
  border-radius: 24px;
  border: 2px solid #b71c1c;
  background: transparent;
  color: #b71c1c;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

#btn-finalizar-simulado:hover {
  background: #b71c1c;
  color: white;
}

#botao-proxima {
  padding: 10px 40px;
  border-radius: 24px;
  border: none;
  background: var(--gradient-primary);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  box-shadow: 0 2px 4px rgba(26, 111, 168, 0.2);
}

/* Formato de seta quando resposta está visível */
#botao-proxima.mostrar-seta {
  border-radius: 24px 0 0 24px;
  padding-right: 50px;
}

#botao-proxima.mostrar-seta::after {
  content: "";
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 22px 0 22px 20px;
  border-color: transparent transparent transparent #1E4A37;
}

#botao-proxima:disabled {
  background: #e0e0e0;
  color: #999;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

#botao-proxima:disabled.mostrar-seta::after {
  border-left-color: #d7e4ee;
}

#botao-proxima:not(:disabled):hover {
  background: linear-gradient(135deg, var(--primary-blue-dark) 0%, var(--primary-blue) 100%);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(26, 111, 168, 0.3);
}

#botao-proxima:not(:disabled):hover.mostrar-seta::after {
  border-left-color: #7095b1;
}

/* Botões de confiança */
#bloco-confianca {
  margin-top: 20px;
  padding: 16px;
  background-color: #f0f4f8;
  border-radius: 8px;
  order: 4;
}

#bloco-confianca p {
  margin-bottom: 12px;
  font-weight: bold;
  color: #333;
}

#botoes-confianca {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.botao-confianca {
  flex: 1;
  min-width: 150px;
  padding: 10px 16px;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
}

#botao-nao-sei {
  background: linear-gradient(135deg, #95a5a6 0%, #7f8c8d 100%);
  color: #fff;
}

#botao-nao-sei:hover:not(:disabled) {
  background: linear-gradient(135deg, #7f8c8d 0%, #6c7b7d 100%);
  transform: translateY(-1px);
  box-shadow: 0 3px 6px rgba(127, 140, 141, 0.3);
}

#botao-nao-sei:disabled {
  background: linear-gradient(135deg, #d5dbdb 0%, #aab7b8 100%);
  color: #7f8c8d;
  cursor: not-allowed;
  opacity: 0.7;
}

#botao-nao-certeza {
  background: var(--gradient-primary);
  color: #fff;
}

#botao-nao-certeza:hover:not(:disabled) {
  background: linear-gradient(135deg, var(--primary-blue-dark) 0%, var(--primary-blue) 100%);
  transform: translateY(-1px);
  box-shadow: 0 3px 6px rgba(52, 152, 219, 0.3);
}

#botao-nao-certeza:disabled {
  background: linear-gradient(135deg, #ecf0f1 0%, #bdc3c7 100%);
  color: #95a5a6;
  cursor: not-allowed;
  opacity: 0.5;
}

#botao-certeza {
  background: linear-gradient(135deg, #0d4a6b 0%, #4a1a7a 50%, #2d1a5c 100%);
  color: #fff;
}

#botao-certeza:hover:not(:disabled) {
  background: linear-gradient(135deg, #0a3a56 0%, #3a1462 50%, #24124a 100%);
  transform: translateY(-1px);
  box-shadow: 0 3px 6px rgba(13, 74, 107, 0.3);
}

#botao-certeza:disabled {
  background: linear-gradient(135deg, #ecf0f1 0%, #bdc3c7 100%);
  color: #95a5a6;
  cursor: not-allowed;
  opacity: 0.5;
}

/* ========== HAMBURGER BUTTON ========== */
.nav-hamburger {
  display: none; /* hidden on desktop */
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 8px;
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
}

.nav-hamburger span {
  display: block;
  width: 20px;
  height: 2px;
  background: white;
  border-radius: 2px;
  transition: all 0.25s ease;
  transform-origin: center;
}

.nav-hamburger.is-open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-hamburger.is-open span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}
.nav-hamburger.is-open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Responsivo */
@media (max-width: 768px) {
  /* Viewport travado — escopo APENAS na página do quiz */
  html:has(body.page-quiz),
  body.page-quiz {
    height: 100%;
    overflow: hidden;
  }

  body.page-quiz {
    display: flex;
    flex-direction: column;
  }

  body.page-quiz .top-nav {
    flex-shrink: 0;
  }

  body.page-quiz #titulo-simulado {
    display: none;
  }

  /* #quiz ocupa o espaço restante e rola internamente */
  body.page-quiz #quiz {
    flex: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    margin: 0;
    padding: 16px 16px 0;
    border-radius: 0;
    border-left: none;
    border-right: none;
    display: flex;
    flex-direction: column;
    min-height: 0;
  }

  body.page-quiz #conteudo-quiz {
    flex-direction: column;
    gap: 16px;
  }

  body.page-quiz .option-button {
    font-size: 16px;
  }

  body.page-quiz #coluna-pergunta,
  body.page-quiz #coluna-resposta {
    min-height: unset;
  }

  /* Footer sticky dentro do scroll container */
  body.page-quiz #rodape-quiz {
    position: sticky;
    bottom: 0;
    margin-top: auto;
    background: #fff;
    border-top: 1px solid #e8e8e8;
    padding: 10px 16px;
    padding-bottom: calc(10px + env(safe-area-inset-bottom, 0px));
    gap: 8px;
    box-shadow: 0 -3px 10px rgba(0, 0, 0, 0.08);
  }

  body.page-quiz #botao-finalizar-revisao,
  body.page-quiz #btn-finalizar-simulado {
    flex: 1;
    margin-right: 0;
  }

  body.page-quiz #botao-proxima {
    flex: 1;
  }

  /* Top Nav Mobile */
  .top-nav {
    padding: 8px 16px;
    position: relative;
  }

  /* Brand mobile: mostra "RouteSec" + "Networks" em duas linhas */
  .top-nav .nav-brand {
    flex: 0 0 auto;
    align-items: flex-start;
    gap: 10px;
  }

  .top-nav .nav-brand .nav-title {
    display: inline-flex;
    flex-direction: column;
    line-height: 1.05;
    font-size: 14px;
  }

  .top-nav .nav-brand .nav-title-sub {
    display: block;
    font-size: 11px;
    font-weight: 600;
    opacity: 0.95;
  }

  .top-nav .nav-info {
    gap: 12px;
  }

  .top-nav .nav-user-info {
    flex: 1;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-rows: auto auto;
    align-items: center;
    justify-items: center;
    column-gap: 8px;
    row-gap: 2px;
    min-width: 0;
    max-width: 260px;
    margin: 0 8px 0 12px;
  }

  .top-nav #nav-user-name {
    grid-column: 1;
    grid-row: 1;
    text-align: center;
    font-size: 10px;
    line-height: 1.05;
    max-width: 118px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .top-nav #nav-plan-badge {
    grid-column: 1;
    grid-row: 2;
    font-size: 9px;
    padding: 2px 6px;
    line-height: 1;
  }

  .top-nav .acesso-restante {
    grid-column: 2;
    grid-row: 1 / span 2;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: flex-end;
    font-size: 10px;
    line-height: 1.05;
    background: transparent;
    border: none;
    padding: 0;
    white-space: normal;
    min-width: 64px;
    align-self: stretch;
  }

  .top-nav .acesso-restante .dias-num,
  .top-nav .acesso-restante .dias-label {
    display: block;
  }

  /* Hamburger: visível no mobile */
  .nav-hamburger {
    display: flex;
  }

  /* nav-right vira dropdown no mobile */
  .top-nav .nav-right {
    display: none;
    position: fixed;
    top: 52px;
    right: 0;
    left: 0;
    background: var(--primary-blue-dark);
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px 0;
    box-shadow: 0 4px 12px rgba(0,0,0,0.25);
    z-index: 1001;
  }

  .top-nav .nav-right.nav-menu-open {
    display: flex;
  }

  /* Itens do menu mobile em lista vertical */
  .top-nav .nav-right .version-badge,
  .top-nav .nav-right .mode-badge {
    margin: 0;
    border-radius: 0;
    text-align: center;
    padding: 10px 20px;
    font-size: 12px;
    border: none;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    background: rgba(255,255,255,0.08);
  }

  .top-nav .nav-back-btn,
  .top-nav .nav-report-btn,
  .top-nav .nav-admin-btn,
  .top-nav .nav-reset-btn,
  .top-nav .nav-logout-btn {
    border-radius: 0;
    padding: 12px 20px;
    font-size: 14px;
    justify-content: flex-start;
    gap: 10px;
    background: transparent;
    border: none;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    flex-direction: row;
    min-width: unset;
    width: 100%;
    text-align: left;
  }

  .top-nav .nav-back-btn:hover,
  .top-nav .nav-report-btn:hover,
  .top-nav .nav-admin-btn:hover,
  .top-nav .nav-reset-btn:hover,
  .top-nav .nav-logout-btn:hover {
    background: rgba(255,255,255,0.15);
  }

  .top-nav .reset-text,
  .top-nav .report-text,
  .top-nav .logout-text {
    display: inline;
    font-size: 14px;
    opacity: 1;
  }
}

/* ========== ESTILOS DO DASHBOARD ========== */

.container-dashboard {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px;
}

.header-dashboard {
  text-align: center;
  margin-bottom: 48px;
  padding-top: 16px;
}

.header-dashboard h1 {
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 32px;
  background: var(--gradient-hybrid);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.progresso-geral {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.progresso-geral h2 {
  font-size: 20px;
  font-weight: 600;
  color: #333;
}

.circulo-progresso {
  position: relative;
  width: 200px;
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.progresso-texto {
  position: absolute;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.progresso-texto span {
  font-size: 36px;
  font-weight: 700;
  color: #1E4A37;
}

.progresso-texto small {
  font-size: 14px;
  color: #666;
  margin-top: 4px;
}

.lista-simulados {
  background-color: #fff;
  border-radius: 8px;
  padding: 32px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.lista-simulados h2 {
  font-size: 22px;
  font-weight: 600;
  color: #333;
  margin-bottom: 24px;
  padding-bottom: 12px;
  border-bottom: 2px solid #e0e0e0;
}

#container-modulos {
  display: block;
}

.card-modulo {
  background-color: #f8f9fa;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 20px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.card-modulo:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 12px rgba(26, 111, 168, 0.15);
  border-color: #1E4A37;
}

.card-modulo h3 {
  font-size: 16px;
  font-weight: 600;
  color: #1E4A37;
  margin-bottom: 8px;
}

.card-modulo p {
  font-size: 14px;
  color: #666;
  line-height: 1.5;
}

.card-info {
  display: flex;
  gap: 16px;
  margin-top: 12px;
  font-size: 13px;
  color: #888;
}

/* Breadcrumb removido - agora usa top-nav */

/* Botões de ação dos módulos */
.modulo-acoes {
  display: flex;
  gap: 12px;
  margin-top: 16px;
}

.btn-modo-normal,
.btn-modo-treino,
.btn-modo-fixacao {
  flex: 1;
  padding: 10px 20px;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-modo-normal {
  background: linear-gradient(135deg, var(--primary-blue) 0%, var(--accent-purple) 70%, var(--primary-blue-dark) 100%);
  color: white;
}

.btn-modo-normal:hover {
  background: linear-gradient(135deg, var(--primary-blue-dark) 0%, var(--accent-purple-dark) 70%, var(--primary-blue) 100%);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(26, 111, 168, 0.3);
}

.btn-modo-treino {
  background: linear-gradient(135deg, #27ae60 0%, #229954 50%, #1e8449 100%);
  color: white;
}

.btn-modo-treino:hover {
  background: linear-gradient(135deg, #229954 0%, #1e8449 50%, #186a3b 100%);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(39, 174, 96, 0.3);
}

.btn-modo-fixacao {
  background: linear-gradient(135deg, #0d4a6b 0%, #4a1a7a 50%, #2d1a5c 100%);
  color: white;
}

.btn-modo-fixacao:hover {
  background: linear-gradient(135deg, #0a3a56 0%, #3a1462 50%, #24124a 100%);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

/* Responsivo Dashboard */
@media (max-width: 768px) {
  .container-dashboard {
    padding: 20px 16px;
  }

  .header-dashboard h1 {
    font-size: 22px;
  }

  .lista-simulados {
    padding: 20px;
  }

  #container-modulos {
    grid-template-columns: 1fr;
  }
}

/* ========== HOME PAGE (index.html) ========== */

.nav-user-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

#nav-user-name {
  color: white;
  font-size: 14px;
  font-weight: 500;
}

.nav-plan-badge {
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.nav-plan-badge.badge-free {
  background: rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.nav-plan-badge.badge-premium {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: white;
}

.nav-plan-badge.badge-version {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.3);
}


.nav-logout-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  color: white;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.nav-logout-btn:hover {
  background: rgba(220, 53, 69, 0.35);
  border-color: rgba(220, 53, 69, 0.5);
}

.container-home {
  max-width: 780px;
  margin: 0 auto;
  padding: 36px 20px 48px;
}

.home-header {
  text-align: center;
  margin-bottom: 32px;
}

.home-header h1 {
  width: auto;
  max-width: none;
  margin: 0 0 8px 0;
  font-size: 28px;
  font-weight: 700;
  color: var(--text-primary);
}

.home-header p {
  color: var(--text-secondary);
  font-size: 15px;
}

.home-stats {
  display: flex;
  gap: 16px;
  margin-bottom: 32px;
}

.stat-card {
  flex: 1;
  background: var(--bg-white);
  border-radius: 12px;
  padding: 20px 16px;
  text-align: center;
  box-shadow: 0 2px 8px var(--shadow-light);
  border: 1px solid var(--border-light);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.stat-card.highlight {
  border-color: var(--primary-blue);
  background: var(--primary-blue-light);
}

.stat-value {
  font-size: 28px;
  font-weight: 700;
  color: var(--primary-blue);
}

.stat-label {
  font-size: 11px;
  color: var(--text-secondary);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.home-cards-section {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.home-cards-header h2 {
  margin: 0;
  font-size: 19px;
  color: #2f3338;
}

.home-cards-header p {
  margin-top: 4px;
  font-size: 14px;
  color: var(--text-secondary);
}

.home-cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.card-versao-mini {
  background: var(--bg-white);
  border-radius: 14px;
  padding: 20px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 14px;
  cursor: pointer;
  border: 1px solid var(--border-light);
  box-shadow: 0 2px 10px var(--shadow-light);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  text-align: left;
  width: 100%;
  font-family: inherit;
  position: relative;
}

.card-versao-mini:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 22px var(--shadow-medium);
  border-color: var(--primary-blue);
}

.card-versao-mini:active {
  transform: scale(0.99);
}

.card-versao-mini:focus-visible {
  outline: 3px solid rgba(30, 74, 55, 0.35);
  outline-offset: 2px;
}

.card-versao-featured {
  grid-column: 1 / -1;
  min-height: 104px;
  border-color: rgba(30, 74, 55, 0.35);
  background: linear-gradient(135deg, #ffffff 0%, #f8f2ff 100%);
}

.card-mini-badge {
  position: absolute;
  top: -10px;
  right: 14px;
  background: var(--gradient-primary);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.35px;
  padding: 5px 10px;
  border-radius: 999px;
  box-shadow: 0 6px 14px rgba(30, 74, 55, 0.3);
}

.card-mini-icon {
  font-size: 30px;
  width: 54px;
  height: 54px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: #f1f3f5;
  flex-shrink: 0;
}

.card-versao-featured .card-mini-icon {
  background: rgba(30, 74, 55, 0.12);
}

.card-mini-body h3 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0 0 4px;
}

.card-mini-body p {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.45;
  margin: 0;
}

.card-mini-arrow {
  font-size: 20px;
  color: var(--primary-blue);
  opacity: 0.75;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.card-versao-mini:hover .card-mini-arrow {
  transform: translateX(3px);
  opacity: 1;
}

/* Home mobile */
@media (max-width: 768px) {
  .home-cards-header h2 {
    font-size: 17px;
  }

  .home-cards-header p {
    font-size: 13px;
  }

  .home-cards {
    grid-template-columns: 1fr;
  }

  .card-versao-featured {
    grid-column: auto;
  }

  .card-versao-mini {
    padding: 16px;
    gap: 10px;
  }

  .card-mini-icon {
    width: 44px;
    height: 44px;
    font-size: 24px;
    border-radius: 10px;
  }

  .card-mini-body h3 {
    font-size: 18px;
  }

  .card-mini-body p {
    font-size: 12px;
  }

  .card-mini-badge {
    top: -8px;
    right: 10px;
    font-size: 10px;
    padding: 4px 8px;
  }

  .home-stats {
    flex-wrap: wrap;
  }

  .stat-card {
    flex: 1 1 calc(50% - 8px);
    min-width: 120px;
  }

  .stat-card.highlight {
    flex: 1 1 100%;
  }

}

/* ========== ESTILOS DA PÁGINA DE SELEÇÃO ========== */

.container-selecao {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 40px 20px;
  background: linear-gradient(135deg, #1E4A37 0%, #143528 100%);
}

.header-selecao {
  text-align: center;
  margin-bottom: 48px;
  color: white;
}

.header-selecao h1 {
  font-size: 36px;
  font-weight: 700;
  margin-bottom: 16px;
  color: white;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

.header-selecao p {
  font-size: 18px;
  opacity: 0.95;
}

.opcoes-versao {
  display: flex;
  gap: 20px;
  max-width: 1400px;
  flex-wrap: nowrap;
  justify-content: center;
  overflow-x: auto;
  padding: 20px 0 30px 0; /* Espaço para o hover não cortar */
  overflow-y: visible; /* Permitir que o card saia do container verticalmente */
}

.card-versao {
  background: white;
  border-radius: 16px;
  padding: 32px 24px;
  flex: 1;
  min-width: 240px;
  max-width: 300px;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 380px;
}

.card-versao:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.icone-versao {
  font-size: 64px;
  margin-bottom: 20px;
}

.card-versao h2 {
  font-size: 28px;
  font-weight: 700;
  color: #1E4A37;
  margin-bottom: 16px;
}

.card-versao p {
  font-size: 16px;
  color: #666;
  margin-bottom: 12px;
  line-height: 1.5;
}

.card-versao p strong {
  color: #333;
}

.card-versao .subtitulo {
  font-size: 14px;
  color: #888;
  margin-bottom: 24px;
}

.btn-selecionar {
  background: linear-gradient(135deg, #1E4A37 0%, #143528 100%);
  color: white;
  border: none;
  padding: 14px 32px;
  border-radius: 24px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  width: 100%;
}

.btn-selecionar:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.info-selecao {
  margin-top: 48px;
  text-align: center;
  color: white;
  font-size: 14px;
  opacity: 0.9;
}

/* Responsivo Seleção */
@media (max-width: 1200px) {
  .opcoes-versao {
    flex-wrap: wrap;
  }
  
  .card-versao {
    flex: 1 1 calc(50% - 10px);
    min-width: 240px;
  }
}

@media (max-width: 768px) {
  .header-selecao h1 {
    font-size: 28px;
  }

  .opcoes-versao {
    gap: 20px;
    flex-wrap: wrap;
  }

  .card-versao {
    flex: 1 1 100%;
    max-width: 340px;
  }
}

/* ========== NOVO LAYOUT - LISTA HORIZONTAL ========== */

.modulo-section {
  margin-bottom: 32px;
  background: var(--bg-white);
  border-radius: 12px;
  box-shadow: 0 2px 8px var(--shadow-light);
  overflow: hidden;
  border: 1px solid var(--accent-purple-light);
}

.modulo-header {
  display: flex;
  align-items: center;
  cursor: pointer;
  user-select: none;
  padding: 20px 24px;
  margin-bottom: 0;
  border-radius: 12px 12px 0 0;
  transition: background-color 0.2s ease;
}

.modulo-header:hover {
  background-color: #f8f9fa;
}

.modulo-titulo-principal {
  font-size: 24px;
  font-weight: 700;
  color: var(--primary-blue);
  margin: 0;
  flex: 1;
  transition: color 0.2s ease;
}

.modulo-header:hover .modulo-titulo-principal {
  color: var(--primary-blue-dark);
}

.modulo-toggle {
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
  padding: 8px 12px;
  border-radius: 6px;
  transition: all 0.2s ease;
  color: var(--primary-blue);
  margin-right: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  min-height: 32px;
}

.modulo-toggle:hover {
  background-color: var(--primary-blue-light);
  transform: scale(1.05);
}

.modulo-toggle:active {
  transform: scale(0.95);
}

.licoes-lista {
  display: flex;
  flex-direction: column;
  margin-top: 0;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
}

.licoes-lista.modulo-colapsado {
  max-height: 0;
  margin-top: 0;
  opacity: 0;
  transform: translateY(-10px);
}

.licao-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 24px;
  background-color: #f8f9fa;
  transition: all 0.2s ease;
  gap: 24px;
}

.licao-item:hover {
  background-color: #e8f4f8;
}

/* Lição concluída — borda verde + fundo sutil para feedback visual */
.licao-item-concluido {
  border-left: 4px solid #4CAF50;
  background-color: #f0f9f1;
}

.licao-item-concluido:hover {
  background-color: #e2f3e4;
}

/* Lição bloqueada (usuário FREE) */
/* Opacidade só no conteúdo informativo — botão CTA fica vívido para incentivar clique */
.licao-item-locked .licao-info-principal {
  opacity: 0.55;
  filter: grayscale(0.25);
}

.licao-item-locked:hover {
  background-color: #f8f9fa;
  cursor: default;
}

.btn-desbloquear {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 18px;
  background: linear-gradient(135deg, #1976d2, #1565c0);
  color: white;
  text-decoration: none;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  transition: filter 0.2s;
}

.btn-desbloquear:hover {
  filter: brightness(1.12);
  cursor: pointer;
}

.licao-separador {
  height: 1px;
  background-color: #ddd;
}

.licao-info-principal {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.licao-titulo-area {
  display: flex;
  align-items: center;
  gap: 12px;
}

.licao-icone {
  font-size: 20px;
}

.licao-titulo {
  font-size: 16px;
  font-weight: 600;
  color: #333;
  margin: 0;
}

.badge-concluido {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  min-width: 24px;
  min-height: 24px;
  flex-shrink: 0;
  background-color: #4CAF50;
  color: white;
  border-radius: 50%;
  font-size: 14px;
  font-weight: bold;
  margin-left: 8px;
}

.licao-stats {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.stat-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: #666;
}

.stat-icon {
  font-size: 16px;
}

.licao-acoes-bloco {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  flex-shrink: 0;
}

.licao-acoes {
  display: flex;
  gap: 12px;
  flex-shrink: 0;
}

.licao-acoes .btn-modo-normal,
.licao-acoes .btn-modo-fixacao {
  padding: 10px 20px;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.licao-acoes .btn-modo-normal {
  background-color: #4CAF50;
  color: white;
}

.licao-acoes .btn-modo-normal:hover {
  background-color: #45a049;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(76, 175, 80, 0.3);
}

.licao-acoes .btn-modo-treino {
  background-color: #27ae60;
  color: white;
}

.licao-acoes .btn-modo-treino:hover {
  background-color: #229954;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(39, 174, 96, 0.3);
}

.licao-acoes .btn-modo-fixacao {
  background-color: #1E4A37;
  color: white;
}

.licao-acoes .btn-modo-fixacao:hover {
  background-color: #155a8a;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(26, 111, 168, 0.3);
}

.btn-revisar-sessao {
  background: none;
  border: none;
  color: #6b3d9b;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  padding: 0;
  text-decoration: underline;
}

.btn-revisar-sessao:hover {
  color: #4a2070;
  text-decoration: none;
}

/* Responsivo - Layout Lista */
@media (max-width: 768px) {
  .licao-item {
    flex-direction: column;
    align-items: flex-start;
    padding: 16px;
  }

  .licao-acoes-bloco {
    width: 100%;
    align-items: stretch;
  }

  .licao-acoes {
    width: 100%;
    flex-direction: column;
  }

  .licao-acoes .btn-modo-normal,
  .licao-acoes .btn-modo-treino,
  .licao-acoes .btn-modo-fixacao {
    width: 100%;
    font-size: 13px;
    padding: 10px 12px;
  }

  .btn-revisar-sessao {
    text-align: center;
    padding-top: 4px;
  }

  .modulo-titulo-principal {
    font-size: 20px;
  }
}

/* ========== RESUMO DO QUIZ ========== */
#bloco-resumo {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  display: none; /* Inicialmente oculto */
  align-items: center;
  justify-content: center;
  z-index: 9999;
  animation: fadeIn 0.3s ease;
}

#bloco-resumo[style*="display: flex"] {
  display: flex !important;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

#conteudo-resumo {
  background: white;
  border-radius: 20px;
  padding: 50px 40px;
  max-width: 600px;
  width: 90%;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  animation: slideUp 0.4s ease;
}

@keyframes slideUp {
  from {
    transform: translateY(50px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

#titulo-resumo {
  font-size: 36px;
  font-weight: 700;
  color: #1E4A37;
  margin-bottom: 30px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

#secao-estatisticas {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin: 30px 0;
}

.estatistica-item {
  background: linear-gradient(135deg, #f6f7f8 0%, #e9ecef 100%);
  border-radius: 12px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: transform 0.2s ease;
}

.estatistica-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.label-estatistica {
  font-size: 13px;
  color: #666;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
}

.valor-estatistica {
  font-size: 40px;
  font-weight: 700;
  color: #333;
}

.valor-estatistica.acertos {
  color: #28a745;
}

.valor-estatistica.erros {
  color: #dc3545;
}

.valor-estatistica.percentual {
  color: #1E4A37;
}

#feedback-resumo {
  font-size: 18px;
  line-height: 1.6;
  color: #444;
  margin: 25px 0;
  padding: 20px;
  background: #f0f8ff;
  border-radius: 10px;
  border-left: 4px solid #1E4A37;
}

#botoes-resumo {
  display: flex;
  gap: 15px;
  margin-top: 30px;
  flex-wrap: wrap;
  justify-content: center;
}

.btn-resumo {
  flex: 1;
  min-width: 200px;
  padding: 15px 30px;
  font-size: 16px;
  font-weight: 600;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.btn-revisar {
  background: linear-gradient(135deg, #6b3d9b 0%, #4a2070 100%);
  color: white;
}

.btn-revisar:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(107, 61, 155, 0.4);
}

.btn-dashboard {
  background: transparent;
  color: #6b3d9b;
  border: 2px solid #6b3d9b;
}

.btn-dashboard:hover {
  background: #6b3d9b;
  color: white;
  transform: translateY(-2px);
}

@media (max-width: 768px) {
  #conteudo-resumo {
    padding: 24px 16px;
    max-height: 90vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  #titulo-resumo {
    font-size: 22px;
    margin-bottom: 16px;
  }

  #secao-estatisticas {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin: 16px 0;
  }

  .estatistica-item {
    padding: 12px;
    gap: 4px;
  }

  .valor-estatistica {
    font-size: 28px;
  }

  #feedback-resumo {
    font-size: 15px;
    padding: 12px;
    margin: 16px 0;
  }

  #botoes-resumo {
    gap: 10px;
    margin-top: 16px;
  }

  .btn-resumo {
    min-width: 100%;
    padding: 12px 20px;
    font-size: 14px;
  }
}

/* ========== MODAL DE CONFIRMAÇÃO ========== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  backdrop-filter: blur(3px);
  animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.modal-content {
  background: white;
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  max-width: 500px;
  width: 90%;
  animation: slideUp 0.3s ease;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.modal-header {
  background: linear-gradient(135deg, #ff5757 0%, #d93636 100%);
  padding: 24px;
  border-radius: 16px 16px 0 0;
  text-align: center;
}

.modal-header h2 {
  color: white;
  font-size: 22px;
  font-weight: 600;
  margin: 0;
}

.modal-body {
  padding: 30px;
}

.modal-body p {
  color: #333;
  font-size: 16px;
  line-height: 1.6;
  text-align: center;
  margin: 0 0 20px 0;
}

.modal-warning {
  background: #fff3cd;
  border: 1px solid #ffc107;
  border-left: 4px solid #ffc107;
  padding: 16px;
  border-radius: 8px;
  color: #856404;
  font-size: 14px;
  line-height: 1.6;
}

.modal-warning strong {
  display: block;
  margin-bottom: 8px;
  color: #d39e00;
}

.modal-footer {
  padding: 20px 30px 30px;
  display: flex;
  gap: 12px;
  justify-content: center;
}

.modal-footer button {
  padding: 12px 32px;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-secondary {
  background: #6c757d;
  color: white;
}

.btn-secondary:hover {
  background: #5a6268;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(108, 117, 125, 0.3);
}

.btn-danger {
  background: linear-gradient(135deg, #ff5757 0%, #d93636 100%);
  color: white;
}

.btn-danger:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(255, 87, 87, 0.4);
}

@media (max-width: 768px) {
  .modal-content {
    width: 95%;
    margin: 20px;
  }

  .modal-footer {
    flex-direction: column;
  }

  .modal-footer button {
    width: 100%;
  }
}

/* Stats banner removido — info migrou pro hero card do index. */

/* ============================================================================
   Hero card — Revisão diária (esquerda) + Sua sequência (direita).
   Substitui o card .daily-review-card no index. Layout 2 colunas em desktop,
   stack em mobile.
   ============================================================================ */
.hero-card {
  position: relative;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 32px;
  background:
    radial-gradient(circle at 18% 110%, rgba(255,255,255,0.08) 0, transparent 30%),
    radial-gradient(circle at 92% -10%, rgba(255,255,255,0.10) 0, transparent 35%),
    linear-gradient(135deg, #16a34a 0%, #15803d 100%);
  color: #fff;
  border-radius: 18px;
  padding: 36px;
  margin: 0 auto 20px;
  max-width: 1100px;
  box-shadow: 0 8px 28px rgba(21, 128, 61, 0.28);
  overflow: hidden;
}
/* Ilustração decorativa — alvo grande no canto, semi-transparente */
.hero-card::before {
  content: '🎯';
  position: absolute;
  font-size: 280px;
  opacity: 0.08;
  right: -40px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  line-height: 1;
}
/* Pontinhos decorativos */
.hero-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 22% 30%, rgba(255,255,255,0.35) 1.5px, transparent 2px),
    radial-gradient(circle at 65% 18%, rgba(255,255,255,0.25) 1.5px, transparent 2px),
    radial-gradient(circle at 88% 85%, rgba(255,255,255,0.30) 2px, transparent 3px),
    radial-gradient(circle at 45% 92%, rgba(255,255,255,0.20) 1.5px, transparent 2px),
    radial-gradient(circle at 12% 78%, rgba(255,255,255,0.25) 1.5px, transparent 2px);
  pointer-events: none;
}
.hero-card-left, .hero-card-right { position: relative; z-index: 1; }
.hero-card-left { display: flex; flex-direction: column; gap: 12px; }
.hero-badge {
  display: inline-block;
  background: rgba(255, 255, 255, 0.18);
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.2px;
  width: fit-content;
}
.hero-title { font-size: 26px; font-weight: 800; line-height: 1.2; margin: 4px 0; }
.hero-subtitle { font-size: 14px; opacity: 0.92; line-height: 1.5; margin: 0; }
.hero-cta {
  display: inline-block;
  margin-top: 12px;
  background: #fff;
  color: #15803d;
  padding: 12px 24px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
  transition: transform 0.15s, box-shadow 0.15s;
  width: fit-content;
}
.hero-cta:hover { transform: translateY(-1px); box-shadow: 0 4px 10px rgba(0,0,0,0.18); }

.hero-card-right {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-left: 24px;
  border-left: 1px solid rgba(255,255,255,0.18);
}
.hero-streak {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-bottom: 4px;
}
.hero-streak-label { font-size: 13px; opacity: 0.92; font-weight: 600; }
.hero-streak-number {
  font-size: 56px;
  font-weight: 800;
  line-height: 1;
  margin-top: 2px;
  letter-spacing: -1px;
}
.hero-streak-unit { font-size: 15px; opacity: 0.9; margin-top: 2px; }
.hero-metrics { display: flex; flex-direction: column; gap: 8px; }
.hero-metric {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255, 255, 255, 0.10);
  padding: 10px 14px;
  border-radius: 10px;
  backdrop-filter: blur(4px);
}
.hero-metric-icon { font-size: 22px; flex-shrink: 0; }
.hero-metric-value { font-size: 20px; font-weight: 800; display: block; line-height: 1; }
.hero-metric-label { font-size: 11px; opacity: 0.88; display: block; margin-top: 2px; text-transform: uppercase; letter-spacing: 0.4px; }
.hero-stats-link {
  color: #fff;
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  margin-top: 6px;
  opacity: 0.95;
  align-self: flex-start;
}
.hero-stats-link:hover { opacity: 1; text-decoration: underline; }

@media (max-width: 768px) {
  .hero-card { grid-template-columns: 1fr; gap: 20px; padding: 22px; }
  .hero-card-right { padding-left: 0; border-left: none; border-top: 1px solid rgba(255,255,255,0.2); padding-top: 20px; }
  .hero-title { font-size: 22px; }
}

/* ============================================================================
   Progresso card — card branco com 88% + barra + lições/acerto.
   ============================================================================ */
.progresso-card {
  background: #fff;
  border-radius: 14px;
  padding: 22px 26px;
  margin: 0 auto 20px;
  max-width: 1100px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.06);
  border: 1px solid #ececf5;
}
.progresso-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.progresso-card-header h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--primary-blue-dark);
  margin: 0;
}
.progresso-card-link {
  color: var(--primary-blue);
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
}
.progresso-card-link:hover { text-decoration: underline; }
.progresso-card-main {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 10px;
}
.progresso-card-percent {
  font-size: 42px;
  font-weight: 800;
  color: var(--primary-blue);
  line-height: 1;
}
.progresso-card-percent-label {
  font-size: 13px;
  color: #666;
}
.progresso-card-bar {
  height: 8px;
  background: #f0e8f8;
  border-radius: 6px;
  overflow: hidden;
  margin-bottom: 14px;
}
.progresso-card-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary-blue) 0%, var(--primary-blue-dark) 100%);
  border-radius: 6px;
  transition: width 0.6s ease;
}
.progresso-card-stats {
  display: flex;
  gap: 36px;
  flex-wrap: wrap;
}
.progresso-card-stat { display: flex; flex-direction: column; }
.progresso-card-stat-value {
  font-size: 18px;
  font-weight: 700;
  color: var(--primary-blue-dark);
  line-height: 1;
}
.progresso-card-stat-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: #888;
  margin-top: 4px;
}
.progresso-card-tagline {
  margin-top: 16px;
  background: #fef3c7;
  border-left: 4px solid #eab308;
  padding: 12px 16px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: #713f12;
}
.progresso-card-tagline-icon { font-size: 18px; }

/* ============================================================================
   Home v2 - Fundamentals dashboard inspirado no layout de estudo gamificado.
   Escopado em body.page-home para preservar quiz, dashboard e checkout.
   ============================================================================ */
body.page-home {
  background:
    radial-gradient(circle at 18% 0%, rgba(30, 74, 55, 0.10), transparent 34%),
    radial-gradient(circle at 92% 12%, rgba(22, 163, 74, 0.08), transparent 30%),
    #f7f5fc;
  color: #10183f;
}

body.page-home .container-home {
  width: min(1180px, calc(100% - 48px));
  max-width: none;
  margin: 0 auto;
  padding: 34px 0 38px;
}

body.page-home .home-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  text-align: left;
  margin-bottom: 26px;
}

body.page-home .home-header h1 {
  width: auto;
  max-width: none;
  margin: 0 0 8px;
  color: #10183f;
  font-size: 36px;
  line-height: 1.05;
  font-weight: 800;
}

body.page-home .home-header p {
  margin: 0;
  color: #4c5579;
  font-size: 18px;
}

body.page-home .home-quick-stats {
  display: flex;
  gap: 20px;
  flex-shrink: 0;
}

body.page-home .home-quick-pill {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 210px;
  min-height: 88px;
  padding: 18px 22px;
  background: rgba(255, 255, 255, 0.86);
  border: 1px solid rgba(30, 74, 55, 0.10);
  border-radius: 12px;
  box-shadow: 0 18px 36px rgba(32, 19, 74, 0.08);
}

body.page-home .home-quick-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: #f1e8ff;
  font-size: 24px;
}

body.page-home .home-quick-pill strong,
body.page-home .home-quick-pill small {
  display: block;
}

body.page-home .home-quick-pill strong {
  color: #111944;
  font-size: 16px;
  line-height: 1.2;
}

body.page-home .home-quick-pill small {
  margin-top: 5px;
  color: #58617e;
  font-size: 13px;
}

body.page-home .hero-card {
  max-width: none;
  min-height: 310px;
  grid-template-columns: minmax(280px, 1fr) minmax(250px, 360px) minmax(220px, 300px);
  align-items: stretch;
  gap: 20px;
  margin: 0 0 24px;
  padding: 36px 34px 34px 48px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 12px;
  background:
    radial-gradient(circle at 36% 50%, rgba(65, 213, 110, 0.42), transparent 24%),
    linear-gradient(90deg, #0b7d34 0%, #0b692e 70%, #075a29 100%);
  box-shadow: 0 22px 44px rgba(8, 82, 40, 0.26);
}

body.page-home .hero-card::before {
  content: "";
  position: absolute;
  inset: 0;
  right: 0;
  top: 0;
  transform: none;
  font-size: 0;
  opacity: 1;
  background:
    radial-gradient(circle at 48% 16%, rgba(255,255,255,0.36) 2px, transparent 3px),
    radial-gradient(circle at 42% 36%, rgba(255,255,255,0.42) 2px, transparent 3px),
    radial-gradient(circle at 69% 27%, rgba(255,255,255,0.40) 2px, transparent 3px),
    radial-gradient(circle at 45% 79%, rgba(255,255,255,0.34) 2px, transparent 3px),
    radial-gradient(circle at 69% 82%, rgba(255,255,255,0.34) 3px, transparent 4px);
}

body.page-home .hero-card::after {
  display: none;
}

body.page-home .hero-card-left {
  justify-content: center;
  gap: 16px;
}

body.page-home .hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  width: fit-content;
  padding: 9px 18px;
  border-radius: 999px;
  background: rgba(34, 197, 94, 0.48);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
}

body.page-home .hero-title {
  max-width: 440px;
  margin: 0;
  color: #fff;
  font-size: 33px;
  line-height: 1.18;
  font-weight: 800;
}

body.page-home .hero-subtitle {
  max-width: 430px;
  color: rgba(255, 255, 255, 0.94);
  font-size: 18px;
  line-height: 1.45;
}

body.page-home .hero-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 36px;
  min-width: 270px;
  min-height: 64px;
  margin-top: 8px;
  padding: 0 28px;
  border-radius: 10px;
  background: #fff;
  color: #10183f;
  box-shadow: 0 14px 28px rgba(2, 36, 18, 0.22);
}

body.page-home .hero-visual {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  min-height: 230px;
}

body.page-home .target-rings {
  position: relative;
  width: 190px;
  height: 190px;
  border-radius: 50%;
  background: #f8fbf8;
  box-shadow: 0 24px 34px rgba(0, 0, 0, 0.20), 0 0 0 56px rgba(255,255,255,0.04);
}

body.page-home .target-rings span {
  position: absolute;
  inset: 18px;
  border-radius: 50%;
  border: 22px solid #43c565;
}

body.page-home .target-rings span:nth-child(2) {
  inset: 52px;
  border-width: 16px;
  border-color: #fff;
}

body.page-home .target-rings span:nth-child(3) {
  inset: 76px;
  border-width: 15px;
  border-color: #43c565;
}

body.page-home .target-rings span:nth-child(4) {
  inset: 92px;
  border-width: 0;
  background: #22c55e;
}

body.page-home .target-dart {
  position: absolute;
  width: 22px;
  height: 150px;
  border-radius: 999px;
  background: linear-gradient(180deg, #8d5cf5 0%, #6f3ee9 45%, #dfe8ff 46%, #dfe8ff 100%);
  transform: translate(30px, -46px) rotate(38deg);
  box-shadow: 0 18px 20px rgba(0,0,0,0.18);
}

body.page-home .target-dart::before,
body.page-home .target-dart::after {
  content: "";
  position: absolute;
  top: -16px;
  width: 36px;
  height: 58px;
  border-radius: 8px 8px 4px 30px;
  background: #7b4be8;
}

body.page-home .target-dart::before {
  left: -30px;
  transform: rotate(-18deg);
}

body.page-home .target-dart::after {
  right: -30px;
  transform: rotate(18deg);
}

body.page-home .hero-card-right {
  justify-content: center;
  gap: 18px;
  padding: 18px 0 18px 30px;
  border-left: 1px solid rgba(255, 255, 255, 0.18);
}

body.page-home .hero-streak-label {
  color: rgba(255,255,255,0.96);
  font-size: 16px;
}

body.page-home .hero-streak-number {
  color: #fff;
  font-size: 48px;
}

body.page-home .hero-streak-unit {
  color: rgba(255,255,255,0.90);
  font-size: 17px;
  font-weight: 700;
}

body.page-home .hero-metrics {
  gap: 0;
  border-top: 1px solid rgba(255,255,255,0.18);
}

body.page-home .hero-metric {
  min-height: 68px;
  padding: 14px 0;
  background: transparent;
  border-bottom: 1px solid rgba(255,255,255,0.18);
  border-radius: 0;
}

body.page-home .hero-metric-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
}

body.page-home .hero-metric-value {
  font-size: 20px;
}

body.page-home .hero-metric-label {
  color: rgba(255,255,255,0.92);
  font-size: 14px;
  text-transform: none;
  letter-spacing: 0;
}

body.page-home .home-detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(340px, 0.95fr);
  gap: 22px;
  margin-bottom: 26px;
}

/* Card "Seu progresso" ocupa largura total — banner inferior CTA absorve a
   função do antigo continue-card (informa próxima lição + botão pra continuar). */
body.page-home .home-overview-grid {
  display: block;
  margin-bottom: 26px;
}

body.page-home .progresso-card,
body.page-home .domain-card,
body.page-home .achievement-card {
  max-width: none;
  margin: 0;
  padding: 24px 26px;
  border: 1px solid rgba(30, 74, 55, 0.12);
  border-radius: 12px;
  background: rgba(255,255,255,0.90);
  box-shadow: 0 16px 36px rgba(32, 19, 74, 0.08);
}

body.page-home .progresso-card-header h3,
body.page-home .section-card-header h3 {
  color: #10183f;
  font-size: 20px;
  font-weight: 800;
}

body.page-home .progresso-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

body.page-home .progress-trend {
  background: #e4f8ec;
  color: #1f8a4a;
  border: 1px solid rgba(31, 138, 74, 0.25);
  font-weight: 700;
  font-size: 12px;
  padding: 5px 12px;
  border-radius: 999px;
}

body.page-home .progresso-card-hero {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 10px;
}

body.page-home .progresso-card-percent {
  color: #1E4A37;
  font-size: 64px;
  font-weight: 900;
  line-height: 1;
  letter-spacing: -1px;
}

body.page-home .progresso-card-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border-radius: 999px;
  background: #E7EDE9;
  color: #143528;
  font-weight: 700;
  font-size: 14px;
  border: 1px solid rgba(20, 53, 40, 0.18);
}

body.page-home .progresso-card-pill-icon {
  font-size: 16px;
}

body.page-home .progresso-card-percent-label {
  color: #5a607a;
  font-size: 15px;
  display: block;
  margin-top: 6px;
}

body.page-home .progresso-card-bar,
body.page-home .continue-progress div,
body.page-home .domain-row div {
  background: #dde2df;
  overflow: hidden;
  position: relative;
}

body.page-home .progresso-card-bar {
  height: 18px;
  border-radius: 999px;
}

body.page-home .continue-progress div,
body.page-home .domain-row div {
  height: 12px;
  border-radius: 999px;
}

body.page-home .progresso-card-bar-fill,
body.page-home .continue-progress div span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #2A6850, #143528);
  position: relative;
  overflow: hidden;
  transition: width 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}

body.page-home .progresso-card-bar-fill::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: linear-gradient(
    -45deg,
    rgba(255, 255, 255, 0.18) 25%,
    transparent 25%,
    transparent 50%,
    rgba(255, 255, 255, 0.18) 50%,
    rgba(255, 255, 255, 0.18) 75%,
    transparent 75%,
    transparent
  );
  background-size: 18px 18px;
  animation: progresso-stripes 1.4s linear infinite;
}

body.page-home .progresso-card-bar-wrap {
  position: relative;
  padding: 38px 0 36px;
  margin-bottom: 6px;
}

body.page-home .progresso-card-bar-balao {
  position: absolute;
  top: 0;
  /* Clamp evita que o balão saia visualmente do trilho perto de 0% ou 100%. */
  left: clamp(2%, var(--bar-progress, 0%), 98%);
  transform: translateX(-50%);
  background: linear-gradient(135deg, #2A6850, #143528);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.3px;
  padding: 6px 12px;
  border-radius: 10px;
  box-shadow: 0 8px 20px rgba(20, 53, 40, 0.32);
  transition: left 0.8s cubic-bezier(0.22, 1, 0.36, 1);
  white-space: nowrap;
  pointer-events: none;
  z-index: 3;
}

body.page-home .progresso-card-bar-balao::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: -5px;
  transform: translateX(-50%) rotate(45deg);
  width: 10px;
  height: 10px;
  background: #143528;
  border-radius: 2px;
}

body.page-home .progresso-card-bar-handle {
  position: absolute;
  top: 50%;
  right: 0;
  transform: translate(50%, -50%);
  width: 18px;
  height: 18px;
  background: #fff;
  border: 4px solid #143528;
  border-radius: 50%;
  box-shadow: 0 4px 10px rgba(20, 53, 40, 0.35);
  z-index: 2;
  pointer-events: none;
}

body.page-home .progresso-card-bar-marco {
  position: absolute;
  left: 90%;
  top: -6px;
  bottom: -6px;
  width: 0;
  border-left: 2px dashed rgba(20, 53, 40, 0.55);
  z-index: 1;
}

body.page-home .progresso-card-bar-marco-label {
  position: absolute;
  left: 90%;
  bottom: 8px;
  transform: translateX(-50%);
  font-size: 12px;
  font-weight: 800;
  color: #143528;
  letter-spacing: 0.2px;
  white-space: nowrap;
  background: #E7EDE9;
  border: 1px solid rgba(20, 53, 40, 0.25);
  padding: 4px 10px;
  border-radius: 999px;
}

body.page-home .progresso-card-bar-ticks {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -22px;
  display: flex;
  justify-content: space-between;
  color: #8a8da0;
  font-size: 12px;
  font-weight: 600;
}

body.page-home .progresso-card-bar-wrap.is-ready .progresso-card-bar-fill::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.55) 50%, transparent 100%);
  animation: progresso-shimmer 2.2s infinite;
}

body.page-home .progresso-card-bar-wrap.is-ready .progresso-card-bar-marco-label {
  background: linear-gradient(135deg, #2A6850, #143528);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 4px 12px rgba(20, 53, 40, 0.32);
}

@keyframes progresso-shimmer {
  0%   { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

@keyframes progresso-stripes {
  0%   { background-position: 0 0; }
  100% { background-position: 36px 0; }
}

body.page-home .progresso-card-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  margin-top: 28px;
  padding: 18px 20px;
  background: #eef3f0;
  border-radius: 14px;
  border: 1px solid rgba(20, 53, 40, 0.08);
}

body.page-home .progresso-card-stat {
  flex-direction: row;
  align-items: center;
  gap: 12px;
  padding: 4px 14px;
  border-left: 1px solid rgba(20, 53, 40, 0.12);
}

body.page-home .progresso-card-stat:first-child {
  border-left: 0;
  padding-left: 0;
}

body.page-home .progresso-card-stat:last-child {
  padding-right: 0;
}

body.page-home .progresso-card-stat-icon {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: #d5e0d9;
  font-size: 18px;
  flex-shrink: 0;
}

body.page-home .progresso-card-stat:nth-child(2) .progresso-card-stat-icon {
  background: #e2f5e9;
}

body.page-home .progresso-card-stat:nth-child(3) .progresso-card-stat-icon {
  background: #fff0d8;
}

body.page-home .progresso-card-stat-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

body.page-home .progresso-card-stat-value {
  color: #10183f;
  font-size: 22px;
  font-weight: 800;
  line-height: 1.1;
}

body.page-home .progresso-card-stat-label {
  color: #10183f;
  font-size: 14px;
  text-transform: none;
  letter-spacing: 0;
}

body.page-home .progresso-card-stat-sub {
  color: #6a7088;
  font-size: 12px;
  margin-top: 2px;
}

body.page-home .progresso-card-stat:nth-child(2) .progresso-card-stat-sub {
  color: #1f8a4a;
  font-weight: 700;
}

/* Tagline antiga ainda existe no DOM em outras páginas; manter estilo base
   pra não quebrar. No card do Home redesign, ela foi substituida pelo CTA. */
body.page-home .progresso-card-tagline {
  justify-content: space-between;
  margin-top: 22px;
  padding: 16px 18px;
  border: 1px solid rgba(30, 74, 55, 0.18);
  border-left: 0;
  border-radius: 12px;
  background: linear-gradient(135deg, #E7EDE9, #d5e0d9);
  color: #0d2419;
  font-weight: 700;
}

body.page-home .progresso-card-tagline a {
  color: #1E4A37;
  text-decoration: none;
  font-size: 22px;
}

/* CTA banner inferior — absorveu o antigo continue-card. */
body.page-home .progresso-card-cta {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 24px;
  padding: 18px 22px;
  border-radius: 14px;
  background: linear-gradient(135deg, #E7EDE9, #c0d2c8);
  border: 1px solid rgba(20, 53, 40, 0.15);
}

body.page-home .progresso-card-cta-icon {
  font-size: 36px;
  flex-shrink: 0;
  filter: drop-shadow(0 2px 4px rgba(20, 53, 40, 0.18));
}

body.page-home .progresso-card-cta-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

body.page-home .progresso-card-cta-info strong {
  color: #082015;
  font-size: 18px;
  font-weight: 800;
}

body.page-home .progresso-card-cta-info span {
  color: #1a3528;
  font-size: 14px;
}

body.page-home .progresso-card-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, #2A6850, #143528);
  color: #fff;
  font-weight: 700;
  font-size: 15px;
  padding: 12px 22px;
  border-radius: 999px;
  text-decoration: none;
  box-shadow: 0 8px 18px rgba(20, 53, 40, 0.28);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  flex-shrink: 0;
  white-space: nowrap;
}

body.page-home .progresso-card-cta-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(20, 53, 40, 0.34);
}

body.page-home .continue-card {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

body.page-home .continue-main {
  display: flex;
  align-items: center;
  gap: 18px;
}

body.page-home .continue-icon {
  width: 68px;
  height: 68px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: linear-gradient(135deg, #7b3ddd, #5822a8);
  color: #fff;
  font-size: 34px;
  box-shadow: 0 12px 20px rgba(30, 74, 55, 0.22);
}

body.page-home .continue-main strong,
body.page-home .continue-main small {
  display: block;
}

body.page-home .continue-main strong {
  color: #10183f;
  font-size: 21px;
}

body.page-home .continue-main small {
  margin-top: 8px;
  color: #4c5579;
  font-size: 16px;
}

body.page-home .continue-btn {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  min-height: 58px;
  padding: 0 24px;
  border: 0;
  border-radius: 9px;
  background: linear-gradient(135deg, #7335d0, #5b24b0);
  color: #fff;
  font-size: 17px;
  font-weight: 800;
  text-decoration: none;
  box-shadow: 0 12px 22px rgba(30, 74, 55, 0.28);
  transition: transform 0.15s, box-shadow 0.15s;
}
body.page-home .continue-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 26px rgba(30, 74, 55, 0.35);
  color: #fff;
}

body.page-home .continue-progress {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px 12px;
  margin-top: auto;
  color: #10183f;
  font-size: 13px;
}

body.page-home .continue-progress div {
  grid-column: 1 / -1;
}

body.page-home .home-cards-section {
  gap: 18px;
  margin-bottom: 26px;
}

body.page-home .home-cards-header h2 {
  color: #10183f;
  font-size: 24px;
  font-weight: 800;
}

body.page-home .home-cards-header p {
  color: #4c5579;
  font-size: 16px;
}

body.page-home .home-cards {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

body.page-home .card-versao-mini {
  position: relative;
  display: flex;
  min-height: 235px;
  flex-direction: column;
  align-items: flex-start;
  justify-content: stretch;
  gap: 14px;
  padding: 26px 20px 18px;
  border-radius: 12px;
  border: 1px solid rgba(30, 74, 55, 0.16);
  background: rgba(255,255,255,0.86);
  box-shadow: 0 14px 30px rgba(32, 19, 74, 0.08);
}

body.page-home .card-versao-featured {
  grid-column: auto;
  background: linear-gradient(135deg, #ffffff 0%, #f6efff 100%);
}

body.page-home .card-versao-pbq {
  border-color: rgba(245, 145, 26, 0.55);
  background: linear-gradient(135deg, #fffdfa 0%, #fff7e8 100%);
}

body.page-home .card-versao-simulado {
  border-color: rgba(28, 119, 226, 0.22);
  background: linear-gradient(135deg, #ffffff 0%, #eef7ff 100%);
}

body.page-home .card-mini-icon {
  width: 64px;
  height: 64px;
  border-radius: 12px;
  background: linear-gradient(135deg, #8f55ef, #6535cf);
  color: #fff;
  font-size: 34px;
}

body.page-home .card-versao-pbq .card-mini-icon {
  background: linear-gradient(135deg, #ffb51d, #ff7900);
}

body.page-home .card-versao-simulado .card-mini-icon {
  background: linear-gradient(135deg, #4aa9ff, #0d6fdb);
}

body.page-home .card-mini-body h3 {
  color: #10183f;
  font-size: 22px;
}

body.page-home .card-mini-body p {
  color: #25305c;
  font-size: 15px;
}

body.page-home .card-mini-body ul {
  margin: 18px 0 0 18px;
  color: #10183f;
  font-size: 14px;
  line-height: 1.8;
}

body.page-home .card-mini-badge {
  position: absolute;
  top: -14px;
  right: 24px;
  padding: 6px 12px;
  border: 1px solid rgba(28, 119, 226, 0.55);
  border-radius: 999px;
  background: #eaf3ff;
  color: #0d6fdb;
  box-shadow: none;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.3px;
  white-space: nowrap;
  z-index: 2;
}

body.page-home .card-mini-action {
  width: 100%;
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  margin-top: auto;
  border-radius: 8px;
  background: linear-gradient(135deg, #7c3ddd, #6228bd);
  color: #fff;
  font-weight: 800;
}

body.page-home .card-versao-pbq .card-mini-action {
  background: linear-gradient(135deg, #ff920f, #ff6b00);
}

body.page-home .card-versao-simulado .card-mini-action {
  background: linear-gradient(135deg, #1688ed, #076dd0);
}

body.page-home .section-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

body.page-home .section-card-header a {
  flex-shrink: 0;
  padding: 8px 12px;
  border: 1px solid rgba(30, 74, 55, 0.18);
  border-radius: 8px;
  color: #5d28b4;
  text-decoration: none;
  font-size: 13px;
  font-weight: 800;
}

body.page-home .domain-list,
body.page-home .achievement-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

body.page-home .domain-row {
  display: grid;
  grid-template-columns: 36px minmax(180px, 1fr) minmax(120px, 170px) 44px;
  align-items: center;
  gap: 14px;
  color: #25305c;
  font-size: 13px;
}

body.page-home .domain-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: #d5e0d9;
}

body.page-home .domain-row div {
  height: 7px;
}

body.page-home .domain-row i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #20b85a, #49ca73);
}

body.page-home .domain-row strong {
  color: #10183f;
  font-size: 13px;
}

body.page-home .achievement-item {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  align-items: center;
  gap: 12px;
}

body.page-home .achievement-item span {
  grid-row: 1 / span 2;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: #d5e0d9;
  font-size: 22px;
}

body.page-home .achievement-item strong {
  color: #10183f;
  font-size: 15px;
}

body.page-home .achievement-item small {
  grid-column: 2 / -1;
  color: #58617e;
  font-size: 13px;
}

body.page-home .study-plan-banner {
  display: grid;
  grid-template-columns: 90px 1fr auto;
  align-items: center;
  gap: 26px;
  min-height: 92px;
  padding: 16px 34px 16px 22px;
  border-radius: 12px;
  background: linear-gradient(90deg, #f3efff 0%, #fff 52%, #f3efff 100%);
  box-shadow: 0 16px 36px rgba(32, 19, 74, 0.08);
}

body.page-home .study-plan-icon {
  width: 74px;
  height: 74px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  background: #ece3ff;
  font-size: 42px;
}

body.page-home .study-plan-banner strong {
  display: block;
  color: #4a18a0;
  font-size: 18px;
  line-height: 1.3;
}

body.page-home .study-plan-banner p {
  margin: 8px 0 0;
  color: #58617e;
  font-size: 15px;
}

body.page-home .study-plan-banner a {
  min-width: 235px;
  min-height: 50px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  padding: 0 20px;
  border-radius: 8px;
  background: linear-gradient(135deg, #7335d0, #5b24b0);
  color: #fff;
  text-decoration: none;
  font-weight: 800;
}

/* Largura intermediária (tablet / split-screen ~720-980px):
   - Hero mantém 3 colunas mas com alvo reduzido (scale 0.68)
   - Cards de modo usam auto-fit pra fluir entre 2 e 3 colunas
   - Grids de detalhe viram 1 coluna */
@media (max-width: 980px) {
  body.page-home .home-header,
  body.page-home .home-quick-stats {
    flex-direction: column;
    align-items: stretch;
  }

  body.page-home .home-overview-grid,
  body.page-home .home-detail-grid {
    grid-template-columns: 1fr;
  }

  body.page-home .hero-card {
    grid-template-columns: minmax(0, 1.4fr) minmax(140px, 200px) minmax(190px, 260px);
    gap: 14px;
    padding: 28px 26px;
  }

  body.page-home .hero-visual {
    min-height: 130px;
    transform: scale(0.68);
    transform-origin: center;
  }

  body.page-home .hero-card::before {
    font-size: 180px;
    right: -30px;
  }

  body.page-home .home-cards {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  }

  body.page-home .study-plan-banner {
    grid-template-columns: auto 1fr;
  }

  body.page-home .study-plan-banner a {
    grid-column: 1 / -1;
    width: 100%;
  }
}

/* Mobile estreito — empilha tudo de vez (alvo decorativo sai). */
@media (max-width: 720px) {
  body.page-home .hero-card,
  body.page-home .home-cards {
    grid-template-columns: 1fr;
  }

  body.page-home .hero-visual {
    display: none;
  }

  body.page-home .hero-card-right {
    padding-left: 0;
    border-left: 0;
    border-top: 1px solid rgba(255,255,255,0.18);
    padding-top: 16px;
  }
}

@media (max-width: 640px) {
  body.page-home .container-home {
    width: min(100% - 28px, 1180px);
    padding-top: 22px;
  }

  body.page-home .home-header h1 {
    font-size: 28px;
  }

  body.page-home .home-header p {
    font-size: 15px;
  }

  body.page-home .home-quick-pill {
    min-width: 0;
    min-height: 76px;
  }

  body.page-home .hero-card {
    min-height: 0;
    padding: 24px 20px;
  }

  body.page-home .hero-visual {
    display: none;
  }

  body.page-home .hero-card-right {
    gap: 10px;
    padding-top: 16px;
  }

  body.page-home .hero-streak-number {
    font-size: 42px;
  }

  body.page-home .hero-metrics {
    display: grid;
    grid-template-columns: 1fr;
  }

  body.page-home .hero-metric {
    min-height: 58px;
    padding: 10px 0;
  }

  body.page-home .hero-title {
    font-size: 25px;
  }

  body.page-home .hero-subtitle {
    font-size: 15px;
  }

  body.page-home .hero-cta {
    width: 100%;
    min-width: 0;
  }

  body.page-home .progresso-card,
  body.page-home .domain-card,
  body.page-home .achievement-card {
    padding: 20px 18px;
  }

  body.page-home .progresso-card-percent {
    font-size: 46px;
  }

  /* Stats em coluna única no mobile pra não apertar 3 colunas em 390px. */
  body.page-home .progresso-card-stats {
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 16px;
  }

  body.page-home .progresso-card-stat {
    border-left: 0;
    border-top: 1px solid rgba(20, 53, 40, 0.12);
    padding: 12px 0 0;
  }

  body.page-home .progresso-card-stat:first-child {
    border-top: 0;
    padding-top: 0;
  }

  body.page-home .progresso-card-stat:last-child {
    padding-right: 0;
  }

  /* CTA banner empilha no mobile (icone+texto em cima, botao full embaixo). */
  body.page-home .progresso-card-cta {
    flex-wrap: wrap;
    padding: 16px 18px;
  }

  body.page-home .progresso-card-cta-btn {
    width: 100%;
    justify-content: center;
  }

  body.page-home .domain-row {
    grid-template-columns: 34px minmax(0, 1fr) 42px;
  }

  body.page-home .domain-row div {
    grid-column: 2 / -1;
  }

  body.page-home .study-plan-banner {
    grid-template-columns: 1fr;
    padding: 20px;
    text-align: left;
  }
}

/* Acessibilidade: respeita preferência de motion reduzido. Desliga stripes,
   shimmer, transições longas e mantém só estados estáticos. */
@media (prefers-reduced-motion: reduce) {
  body.page-home .progresso-card-bar-fill,
  body.page-home .progresso-card-bar-balao {
    transition: none;
  }
  body.page-home .progresso-card-bar-fill::before,
  body.page-home .progresso-card-bar-wrap.is-ready .progresso-card-bar-fill::after {
    animation: none;
  }
}

