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

:root {
  --azul: #1A2E8C;
  --azul-escuro: #0F1D5E;
  --amarelo: #FFC107;
  --amarelo-hover: #e6ac00;
  --branco: #ffffff;
  --cinza-claro: #f4f4f4;
  --cinza-texto: #444;
  --font: 'Barlow', sans-serif;
  --font-cond: 'Barlow Condensed', sans-serif;
  --vh100: 100dvh;
}

html { height: 100%; }

body {
  height: 100%;
  font-family: var(--font);
  background: var(--azul-escuro);
  color: var(--azul-escuro);
  overflow: hidden;
  overscroll-behavior: none;
}

img { max-width: 100%; display: block; }

button { font-family: var(--font); }

.app {
  position: relative;
  width: 100%;
  height: var(--vh100);
  overflow: hidden;
}

/* ══════════════════════════════════════
   TELAS (wizard full-screen)
══════════════════════════════════════ */
.screen {
  position: fixed;
  inset: 0;
  height: var(--vh100);
  display: flex;
  flex-direction: column;
  background: var(--branco);
  transform: translateX(100%);
  opacity: 0;
  pointer-events: none;
  z-index: 1;
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.35s ease;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.screen.active {
  pointer-events: auto;
  z-index: 2;
}

/* ══════════════════════════════════════
   PROGRESSO + BOTÃO VOLTAR (globais)
══════════════════════════════════════ */
.progress-bar {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 5px;
  background: rgba(15,29,94,0.08);
  z-index: 50;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}
.progress-bar.show { opacity: 1; }

.progress-fill {
  height: 100%;
  width: 0%;
  background: var(--amarelo);
  border-radius: 0 4px 4px 0;
  transition: width 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

.back-btn {
  position: fixed;
  top: calc(16px + env(safe-area-inset-top));
  left: 16px;
  width: 40px; height: 40px;
  border-radius: 50%;
  border: none;
  background: rgba(15,29,94,0.06);
  color: var(--azul-escuro);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  z-index: 50;
  opacity: 0;
  visibility: hidden;
  transform: scale(0.85);
  transition: opacity 0.25s ease, transform 0.25s ease, background 0.2s ease;
}
.back-btn.show { opacity: 1; visibility: visible; transform: scale(1); }
.back-btn:hover { background: rgba(15,29,94,0.12); }
.back-btn:active { transform: scale(0.92); }

/* ══════════════════════════════════════
   TELA 0 — CAPA / CARROSSEL
══════════════════════════════════════ */
.screen-cover {
  background: var(--azul-escuro);
  color: var(--branco);
  justify-content: center;
  align-items: center;
  padding: calc(28px + env(safe-area-inset-top)) 1.5rem calc(110px + env(safe-area-inset-bottom));
}

.cover-inner {
  width: 100%;
  max-width: 400px;
  margin: 0 auto;
  text-align: center;
  animation: contentUp 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

.cover-logo {
  height: 30px;
  width: auto;
  margin: 0 auto 1.5rem;
}

.cover-card {
  width: 100%;
  max-width: 260px;
  margin: 0 auto;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 14px 40px rgba(0,0,0,0.4);
}

.cover-carousel {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
}

.cover-slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 1s ease;
}

.cover-slide.is-active { opacity: 1; }

.cover-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin: 14px 0 1.5rem;
}

.cover-dots .dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: rgba(255,255,255,0.25);
  transition: background 0.3s, transform 0.3s;
}
.cover-dots .dot.active { background: var(--amarelo); transform: scale(1.3); }

.cover-inner h1 {
  font-family: var(--font-cond);
  font-size: clamp(26px, 7.5vw, 36px);
  font-weight: 900;
  text-transform: uppercase;
  line-height: 1.08;
  margin-bottom: 0.75rem;
}

.cover-inner h1 span { color: var(--amarelo); }

.cover-inner p {
  font-size: clamp(15px, 4vw, 17px);
  color: rgba(255,255,255,0.8);
  line-height: 1.5;
}

/* ══════════════════════════════════════
   BOTÃO FLUTUANTE
══════════════════════════════════════ */
.btn-float {
  position: fixed;
  left: 20px; right: 20px;
  bottom: calc(20px + env(safe-area-inset-bottom));
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: var(--amarelo);
  color: var(--azul-escuro);
  border: none;
  font-size: 17px;
  font-weight: 800;
  padding: 18px 24px;
  border-radius: 14px;
  cursor: pointer;
  box-shadow: 0 10px 30px rgba(0,0,0,0.28);
  transition: background 0.2s, transform 0.15s;
  max-width: 440px;
  margin: 0 auto;
}
.btn-float:hover { background: var(--amarelo-hover); }
.btn-float:active { transform: scale(0.98); }
.btn-float:disabled { opacity: 0.45; pointer-events: none; }

@keyframes pulse-float {
  0%   { box-shadow: 0 10px 30px rgba(0,0,0,0.28), 0 0 0 0 rgba(255,193,7,0.55); }
  60%  { box-shadow: 0 10px 30px rgba(0,0,0,0.28), 0 0 0 12px rgba(255,193,7,0); }
  100% { box-shadow: 0 10px 30px rgba(0,0,0,0.28), 0 0 0 0 rgba(255,193,7,0); }
}
.btn-float-pulse { animation: pulse-float 2.2s ease-in-out infinite; }
.btn-float-pulse:hover { animation: none; }

/* Botão "Continuar" das perguntas com campo de texto — fica no fluxo
   normal, logo abaixo do campo, para nunca ficar escondido atrás do
   teclado do celular (posição fixa quebra nesse cenário). */
.btn-inline {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  background: var(--amarelo);
  color: var(--azul-escuro);
  border: none;
  font-size: 17px;
  font-weight: 800;
  padding: 18px 24px;
  border-radius: 14px;
  cursor: pointer;
  box-shadow: 0 8px 22px rgba(0,0,0,0.14);
  transition: background 0.2s, transform 0.15s;
  margin-top: 1.5rem;
}
.btn-inline:hover { background: var(--amarelo-hover); }
.btn-inline:active { transform: scale(0.98); }

/* ══════════════════════════════════════
   PERGUNTAS
══════════════════════════════════════ */
.screen-question {
  justify-content: center;
  padding: calc(72px + env(safe-area-inset-top)) 1.5rem calc(40px + env(safe-area-inset-bottom));
}

.question-content {
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  animation: contentUp 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

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

.question-tag {
  display: inline-block;
  font-size: 12px;
  font-weight: 800;
  color: var(--azul);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.75rem;
}

.question-title {
  font-family: var(--font-cond);
  font-size: clamp(26px, 7vw, 36px);
  font-weight: 900;
  color: var(--azul-escuro);
  line-height: 1.1;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.question-hint {
  font-size: 15px;
  color: var(--cinza-texto);
  line-height: 1.5;
  margin-bottom: 1.75rem;
}

/* Opções (chips grandes) */
.options {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.option-btn {
  text-align: left;
  padding: 18px 20px;
  border: 1.5px solid #dcdce6;
  background: var(--branco);
  border-radius: 14px;
  font-size: 16px;
  font-weight: 700;
  color: var(--azul-escuro);
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s, color 0.2s, transform 0.15s;
}
.option-btn:hover { border-color: var(--azul); }
.option-btn:active { transform: scale(0.98); }
.option-btn.selected {
  border-color: var(--azul);
  background: var(--azul);
  color: var(--branco);
}

/* Campos de texto */
.field-input {
  display: flex;
  align-items: center;
  border: 1.5px solid #dcdce6;
  border-radius: 14px;
  padding: 0 18px;
  background: var(--branco);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.field-input:focus-within {
  border-color: var(--azul);
  box-shadow: 0 0 0 3px rgba(26,46,140,0.12);
}
.field-input input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-family: var(--font);
  font-size: 18px;
  font-weight: 600;
  color: var(--azul-escuro);
  padding: 18px 0;
  width: 100%;
}
.field-input input::placeholder { color: #a6a6b5; font-weight: 500; }

.field-erro {
  font-size: 13px;
  font-weight: 600;
  color: #d92d20;
  min-height: 18px;
  margin-top: 8px;
}

.link-btn {
  border: none;
  background: none;
  color: var(--azul);
  font-size: 14px;
  font-weight: 700;
  text-decoration: underline;
  cursor: pointer;
  margin-top: 1.5rem;
}

/* ══════════════════════════════════════
   DESQUALIFICADO
══════════════════════════════════════ */
.screen-disqualified {
  justify-content: center;
  align-items: center;
  padding: calc(72px + env(safe-area-inset-top)) 1.5rem calc(40px + env(safe-area-inset-bottom));
  background: var(--cinza-claro);
}

.disqualified-content {
  max-width: 460px;
  text-align: center;
  animation: contentUp 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

.disqualified-icon {
  font-size: 48px;
  margin-bottom: 1.25rem;
}

.disqualified-content h2 {
  font-family: var(--font-cond);
  font-size: clamp(24px, 6vw, 32px);
  font-weight: 900;
  color: var(--azul-escuro);
  text-transform: uppercase;
  line-height: 1.1;
  margin-bottom: 0.9rem;
}

.disqualified-content p {
  font-size: 15px;
  color: var(--cinza-texto);
  line-height: 1.6;
  margin-bottom: 0.75rem;
}

/* ══════════════════════════════════════
   CONCLUSÃO
══════════════════════════════════════ */
.screen-conclusion {
  justify-content: center;
  align-items: center;
  padding: calc(40px + env(safe-area-inset-top)) 1.5rem calc(110px + env(safe-area-inset-bottom));
  background: var(--azul-escuro);
  color: var(--branco);
}

.conclusion-content {
  width: 100%;
  max-width: 440px;
  text-align: center;
  animation: contentUp 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

.conclusion-check {
  width: 68px; height: 68px;
  margin: 0 auto 1.5rem;
  background: var(--amarelo);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  animation: checkPop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) 0.1s both;
}

@keyframes checkPop {
  from { transform: scale(0); opacity: 0; }
  to   { transform: scale(1); opacity: 1; }
}

.conclusion-content h2 {
  font-family: var(--font-cond);
  font-size: clamp(26px, 7vw, 36px);
  font-weight: 900;
  text-transform: uppercase;
  line-height: 1.1;
  margin-bottom: 0.6rem;
}

.conclusion-content h2 span { color: var(--amarelo); }

.conclusion-sub {
  font-size: 15px;
  color: rgba(255,255,255,0.78);
  line-height: 1.6;
  margin-bottom: 1.75rem;
}

.summary-card {
  background: rgba(255,255,255,0.06);
  border: 1.5px solid rgba(255,255,255,0.14);
  border-radius: 16px;
  padding: 6px 20px;
  text-align: left;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 14px 0;
}
.summary-row + .summary-row { border-top: 1px solid rgba(255,255,255,0.1); }

.summary-label {
  font-size: 13px;
  font-weight: 700;
  color: rgba(255,255,255,0.55);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.summary-value {
  font-size: 15px;
  font-weight: 700;
  color: var(--branco);
  text-align: right;
}

.btn-whatsapp svg { flex-shrink: 0; }

/* ══════════════════════════════════════
   MOBILE / TELAS PEQUENAS
══════════════════════════════════════ */
@media (max-width: 380px) {
  .cover-card { max-width: 220px; }
  .option-btn { padding: 16px 18px; font-size: 15px; }
}

/* Reduz movimento para quem preferir */
@media (prefers-reduced-motion: reduce) {
  .screen, .cover-slide, .btn-float-pulse, .conclusion-check { transition: none !important; animation: none !important; }
}
