/* ==========================================================================
   OLIMPO — ESTILOS DO QUIZ (EXPERIÊNCIA 100dvh ZERO-SCROLL NO MOBILE & DESKTOP)
   ========================================================================== */

.quiz-shell {
  width: 100%;
  max-width: 680px;
  height: calc(100dvh - 64px);
  max-height: calc(100dvh - 64px);
  margin: 0 auto;
  padding: 12px 20px 16px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  box-sizing: border-box;
}

/* 1. Header & Barra de Progresso */
.quiz-header-bar {
  flex-shrink: 0;
  margin-bottom: 10px;
}

.quiz-progress-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11.5px;
  font-weight: 700;
  margin-bottom: 6px;
  gap: 8px;
}

.quiz-step-tag {
  color: var(--text-muted);
  letter-spacing: 0.5px;
  font-size: 11px;
}

.quiz-step-tag strong {
  color: var(--emerald);
  font-size: 12px;
}

.quiz-axis-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  padding: 3px 10px;
  border-radius: var(--radius-full);
  color: var(--text-primary);
  font-size: 11.5px;
  font-weight: 600;
}

.axis-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--axis-color, var(--emerald));
  box-shadow: 0 0 6px var(--axis-color, var(--emerald));
}

.quiz-complete-percent {
  color: var(--text-secondary);
  font-size: 11px;
  font-weight: 600;
}

.quiz-progress-track {
  height: 5px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.quiz-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--emerald), var(--cyan));
  border-radius: var(--radius-full);
  transition: width 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 0 8px var(--emerald-glow);
}

/* 2. Card Central da Pergunta */
.question-panel {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 18px 24px;
  box-shadow: var(--shadow-md);
  margin-bottom: 10px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  overflow: hidden;
}

.question-watermark {
  position: absolute;
  top: 8px;
  right: 16px;
  font-family: var(--font-heading);
  font-size: clamp(48px, 9vw, 68px);
  font-weight: 800;
  color: rgba(255, 255, 255, 0.03);
  pointer-events: none;
  line-height: 1;
  user-select: none;
}

.question-theme-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  align-self: flex-start;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-size: 10.5px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 10px;
}

.pill-divider {
  color: var(--emerald);
  font-weight: 700;
}

.question-statement {
  font-family: var(--font-body);
  font-size: clamp(16px, 3.8vw, 21px);
  font-weight: 600;
  line-height: 1.35;
  color: var(--text-white);
  margin: 0 0 16px 0;
  flex-shrink: 0;
}

/* 3. Opções de Resposta (5 Botões Otimizados para Celular) */
.answer-options-grid {
  display: flex;
  flex-direction: column;
  gap: 7px;
  flex-grow: 1;
  justify-content: center;
}

.answer-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  height: clamp(42px, 5.8vh, 50px);
  min-height: 42px;
  padding: 0 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: clamp(13px, 2.7vw, 14.5px);
  font-weight: 500;
  transition: all 0.15s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  text-align: left;
  user-select: none;
}

.answer-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--border-medium);
  transform: translateX(3px);
}

.answer-btn:active {
  transform: scale(0.985);
}

.btn-indicator {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  margin-right: 12px;
  flex-shrink: 0;
  transition: all 0.15s ease;
}

.btn-label {
  flex-grow: 1;
}

.btn-shortcut {
  font-size: 10px;
  color: var(--text-muted);
}

.btn-shortcut kbd {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-subtle);
  border-radius: 4px;
  padding: 1px 5px;
  font-family: monospace;
}

/* Cores Indicadoras */
.answer-tier-0 .btn-indicator { background: #00e676; box-shadow: 0 0 6px rgba(0, 230, 118, 0.6); }
.answer-tier-1 .btn-indicator { background: #34d399; }
.answer-tier-2 .btn-indicator { background: #94a3b8; }
.answer-tier-3 .btn-indicator { background: #fb7185; }
.answer-tier-4 .btn-indicator { background: #f43f5e; box-shadow: 0 0 6px rgba(244, 63, 94, 0.6); }

/* Estados Selecionados */
.answer-btn.selected {
  border-color: var(--emerald);
  background: rgba(0, 230, 118, 0.14);
  color: var(--text-white);
  font-weight: 700;
  box-shadow: 0 0 16px rgba(0, 230, 118, 0.18);
}

.answer-tier-0.selected { border-color: #00e676; background: rgba(0, 230, 118, 0.18); }
.answer-tier-1.selected { border-color: #34d399; background: rgba(52, 211, 153, 0.14); }
.answer-tier-2.selected { border-color: #94a3b8; background: rgba(148, 163, 184, 0.14); }
.answer-tier-3.selected { border-color: #fb7185; background: rgba(251, 113, 133, 0.14); }
.answer-tier-4.selected { border-color: #f43f5e; background: rgba(244, 63, 94, 0.18); }

.answer-btn.selected .btn-indicator {
  transform: scale(1.4);
}

/* 4. Navegação Inferior (Sem Scroll) */
.quiz-navigation {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 4px;
}

.button-nav-prev, .button-nav-next {
  height: 40px;
  padding: 0 18px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.15s ease;
}

.button-nav-prev {
  background: var(--bg-pill);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
}

.button-nav-prev:hover:not(:disabled) {
  color: var(--text-white);
  border-color: var(--border-medium);
}

.button-nav-prev:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.button-nav-next {
  background: linear-gradient(135deg, var(--emerald), var(--emerald-dark));
  color: #04120a;
  font-weight: 700;
  box-shadow: 0 4px 14px rgba(0, 230, 118, 0.25);
}

.button-nav-next:hover:not(:disabled) {
  filter: brightness(1.1);
  transform: translateY(-1px);
}

.button-nav-next:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  filter: grayscale(0.5);
}

.advance-toggle-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px 6px;
  user-select: none;
}

.toggle-pill {
  width: 26px;
  height: 14px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-full);
  position: relative;
  transition: background 0.2s ease;
}

.toggle-pill:after {
  content: '';
  position: absolute;
  top: 1.5px;
  left: 1.5px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #fff;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.toggle-pill.on {
  background: var(--emerald);
}

.toggle-pill.on:after {
  transform: translateX(12px);
}

.quiz-footer-help {
  flex-shrink: 0;
  text-align: center;
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 4px;
}

.quiz-footer-help kbd {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-subtle);
  border-radius: 3px;
  padding: 1px 4px;
  font-family: monospace;
}

/* Telas Pequenas (iPhone SE / Telas < 400px) */
@media (max-width: 480px) {
  .quiz-shell {
    padding: 8px 12px 12px;
  }

  .question-panel {
    padding: 12px 14px;
  }

  .question-statement {
    font-size: 15.5px;
    margin-bottom: 10px;
    line-height: 1.3;
  }

  .answer-btn {
    height: 38px;
    min-height: 38px;
    padding: 0 12px;
    font-size: 12.5px;
  }

  .btn-shortcut {
    display: none;
  }

  .quiz-footer-help {
    display: none;
  }
}
