/* ============================================================
 * Quiz AllPass — estilos (fiel ao protótipo oficial QuizAllPass.dc.html,
 * variante "gradient" / fundo escuro alinhada à página do AllPass).
 * ============================================================ */
:root {
  /* Paleta oficial (tema gradient/escuro) */
  --app-bg: #0C0E12;
  --body: #A6ACB9;
  --heading: #FFFFFF;
  --kicker: #7FBEF7;

  --blue: #2E93EE;
  --purple: #5E60CE;
  --grad: linear-gradient(92deg, #2E93EE, #5E60CE);
  --prog-fill: linear-gradient(90deg, #2E93EE, #5E60CE);
  --intro-bg: linear-gradient(150deg, #1D5297 0%, #2E93EE 48%, #5E60CE 100%);

  --yellow: #FFCF00;
  --yellow-ink: #1F2044;
  --yellow-shadow: 0 8px 20px rgba(255, 207, 0, 0.28);

  --prog-track: rgba(255, 255, 255, 0.10);
  --input-bg: #12141B;
  --input-border: rgba(255, 255, 255, 0.14);
  --video-border: rgba(255, 255, 255, 0.14);

  --hero-bg: radial-gradient(130% 90% at 50% -10%, rgba(46,147,238,0.20), transparent 55%), #12141B;
  --hero-border: rgba(255, 255, 255, 0.08);
  --hero-chip-border: #141821;
  --result-glow: radial-gradient(130% 60% at 50% 0%, rgba(46,147,238,0.16), transparent 55%);

  --pill-bg: rgba(255, 255, 255, 0.06);
  --pill-border: rgba(255, 255, 255, 0.14);
  --pill-text: #C7CCD4;
  --pill-dot: #34D399;

  --opt-bg: #191D24;
  --opt-border: rgba(255, 255, 255, 0.10);
  --opt-bg-sel: rgba(46, 147, 238, 0.16);
  --opt-border-sel: #2E93EE;
  --opt-ring: rgba(255, 255, 255, 0.25);
}

* { box-sizing: border-box; }

html, body { margin: 0; height: 100%; }

body {
  background: var(--app-bg);
  color: var(--body);
  font-family: Figtree, system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

/* Palco: centraliza a "tela" mobile no desktop */
.stage {
  min-height: 100dvh;
  display: flex;
  justify-content: center;
  align-items: stretch;
  padding: 0;
}

#app {
  width: 100%;
  max-width: 420px;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--app-bg);
  overflow-x: hidden;
}

@media (min-width: 460px) {
  .stage { padding: 28px 16px; align-items: center; }
  #app {
    min-height: auto;
    height: min(820px, calc(100dvh - 56px));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 30px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, .55);
    overflow-y: auto;
  }
}

@keyframes fade { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes spin { to { transform: rotate(360deg); } }

/* ── Topbar (progresso) ── */
.topbar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 22px 6px;
  flex-shrink: 0;
}
.back {
  flex: none;
  padding: 4px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 0; cursor: pointer; line-height: 0;
  background: none; color: var(--heading); opacity: .7;
  transition: opacity .15s;
}
.back:hover { opacity: 1; }
.back[hidden] { display: none; }
.track {
  flex: 1;
  height: 6px;
  background: var(--prog-track);
  border-radius: 999px;
  overflow: hidden;
}
.fill {
  height: 100%;
  border-radius: 999px;
  background: var(--prog-fill);
  transition: width .35s ease;
}
.step-label {
  flex: none;
  font-size: 12px;
  font-weight: 700;
  color: var(--heading);
  white-space: nowrap;
}

/* ── Layout de conteúdo por tela ── */
.screen {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 24px 26px 32px;
  animation: fade .35s ease both;
}
.screen--center { justify-content: center; }

/* ── Tipografia ── */
h1 { font-size: 27px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.15; margin: 0 0 12px; color: var(--heading); text-wrap: balance; }
h2 { font-size: 23px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.22; margin: 0 0 18px; color: var(--heading); text-wrap: balance; }
.grad-text {
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.sub { font-size: 15px; color: var(--body); margin: 0 0 22px; line-height: 1.5; }
.eyebrow {
  font-size: 12px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase;
  color: var(--kicker); margin: 0 0 10px;
}

/* ── Botões ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%;
  font: inherit; font-weight: 800; font-size: 17px;
  padding: 16px; border: 0; border-radius: 14px; cursor: pointer;
  transition: transform .06s ease, filter .15s ease;
  text-decoration: none;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--yellow); color: var(--yellow-ink); box-shadow: var(--yellow-shadow); }
.btn-primary:hover { filter: brightness(1.03); }
.btn-primary:disabled { opacity: .55; cursor: not-allowed; }
.btn-outline {
  background: transparent; color: var(--heading);
  border: 1.5px solid var(--opt-ring); font-weight: 700; font-size: 15px; padding: 13px;
  box-shadow: none;
}
.btn-link {
  background: none; border: 0; cursor: pointer;
  font: inherit; font-size: 13px; font-weight: 600; color: var(--body);
  text-decoration: underline; text-underline-offset: 2px; padding: 6px;
}
.btn-link:hover { color: var(--heading); }

/* ── Tela inicial ── */
/* Conteúdo alinhado ao topo (fiel ao layout do design), sobrepondo o
   justify-content:center herdado de .screen--center. */
.screen--intro { padding: 32px 26px 40px; justify-content: flex-start; }
.intro-card {
  background: var(--hero-bg);
  border: 1px solid var(--hero-border);
  border-radius: 26px;
  padding: 30px 24px;
  text-align: center;
}
.badge {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 12px; font-weight: 700; color: var(--pill-text);
  background: var(--pill-bg); border: 1px solid var(--pill-border);
  padding: 6px 12px; border-radius: 999px;
}
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--pill-dot); }
.intro-card h1 { font-size: 27px; margin: 16px 0 0; }
.intro-card .sub { font-size: 15px; color: rgba(255, 255, 255, 0.9); margin: 12px 0 0; }
.ai-row { display: flex; align-items: center; justify-content: center; margin-top: 22px; }
.ai-icon {
  width: 40px; height: 40px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: #fff; border: 2px solid var(--hero-chip-border); overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}
.ai-icon + .ai-icon { margin-left: -10px; }
.ai-icon img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ai-icon--contain img { width: 21px; height: 21px; object-fit: contain; }
.ai-icon svg { width: 24px; height: 24px; display: block; }
.intro-card + .btn { margin-top: 22px; }
.fineprint { font-size: 13px; color: var(--body); margin: 14px 0 0; text-align: center; }

/* ── Opções (perguntas) ── */
.options { display: flex; flex-direction: column; gap: 12px; margin-top: 24px; animation: fade .35s ease; }
.option {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  text-align: left; width: 100%;
  font: inherit; font-size: 16px; font-weight: 600; line-height: 1.35; color: var(--heading);
  padding: 18px; border-radius: 16px;
  border: 2px solid var(--opt-border); background: var(--opt-bg);
  cursor: pointer; transition: border-color .15s, background .15s;
}
.option:hover { border-color: var(--opt-ring); }
.option.selected { border-color: var(--opt-border-sel); background: var(--opt-bg-sel); }
.option .emoji { font-size: 18px; line-height: 1; flex: none; }
.option .label { flex: 1; }
.option .radio {
  flex: none; width: 22px; height: 22px; border-radius: 50%;
  border: 2px solid var(--opt-ring);
  display: flex; align-items: center; justify-content: center;
  transition: border-color .15s;
}
.option .radio::after {
  content: ""; width: 12px; height: 12px; border-radius: 50%;
  background: var(--blue); opacity: 0; transition: opacity .15s;
}
.option.selected .radio { border-color: var(--blue); }
.option.selected .radio::after { opacity: 1; }

/* ── Insight (card gradiente + ícone branco/azul) ── */
.screen--insight { padding: 32px 26px; }
.insight-card {
  background: var(--intro-bg);
  border-radius: 24px;
  padding: 30px 24px;
  text-align: center;
  color: #fff;
}
.insight-ic {
  width: 58px; height: 58px; margin: 0 auto;
  border-radius: 50%; background: #fff;
  display: inline-flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.14);
}
.insight-ic svg { width: 28px; height: 28px; stroke: var(--blue); }
.insight-card h2 { color: #fff; font-size: 21px; margin: 18px 0 0; }
.insight-card p { font-size: 14.5px; line-height: 1.5; color: rgba(255, 255, 255, 0.9); margin: 10px 0 0; }
.chip {
  display: inline-flex; align-items: center; gap: 10px;
  margin-top: 18px; font-size: 14px; font-weight: 700;
}
.chip .de { color: rgba(255, 255, 255, 0.9); text-decoration: line-through; }
.chip .arrow { display: inline-flex; opacity: .9; }
.chip .arrow svg { width: 18px; height: 18px; stroke: #fff; }
.chip .para { font-size: 15px; background: var(--yellow); color: var(--yellow-ink); padding: 6px 12px; border-radius: 999px; font-weight: 800; }

/* ── Formulário (captura) ── */
.screen--lead { padding: 20px 26px 32px; }
.lead-intro { margin: 8px 0 22px; }
form { display: flex; flex-direction: column; gap: 14px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 13px; font-weight: 700; color: var(--heading); }
.field input {
  width: 100%; font: inherit; font-size: 15px; color: var(--heading);
  padding: 14px 15px; border-radius: 12px;
  border: 1.5px solid var(--input-border); background: var(--input-bg);
  outline: none;
}
.field input::placeholder { color: #5c5f67; }
.field input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(46, 147, 238, .2); }
.field input.invalid { border-color: #ef4444; }
.field .error { color: #f87171; font-size: 12px; min-height: 1em; }
.consent {
  display: flex; gap: 10px; align-items: flex-start;
  font-size: 13px; color: var(--body); line-height: 1.45; margin-top: 2px;
}
.consent input { margin-top: 2px; width: 17px; height: 17px; flex: none; accent-color: var(--blue); }
.consent a { color: var(--blue); font-weight: 700; text-decoration: underline; }
form .btn { margin-top: 6px; }

/* ── Processando ── */
.processing { align-items: center; justify-content: center; text-align: center; gap: 22px; padding: 40px 30px; }
.spinner {
  width: 52px; height: 52px;
  border: 4px solid rgba(46, 147, 238, 0.2); border-top-color: var(--blue);
  border-radius: 50%; animation: spin .9s linear infinite;
}
.processing h2 { margin: 0; font-size: 20px; }
.processing p { color: var(--body); font-size: 14.5px; margin: 8px 0 0; }

/* ── Resultado ── */
.screen--result { padding: 30px 24px 34px; background: var(--result-glow); }
.screen--result h1 { font-size: 25px; line-height: 1.18; margin: 0 0 12px; }
.result-desc { font-size: 15px; line-height: 1.55; color: var(--body); margin: 0 0 22px; }

/* card do plano (branco, fixo) */
.plan {
  background: #FFFFFF; color: #14161B;
  border: 1px solid #ECEEF2;
  border-radius: 20px; padding: 22px;
  box-shadow: 0 16px 40px rgba(15, 20, 40, .16);
}
.plan-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.plan-name { font-size: 21px; font-weight: 800; color: #14161B; }
.off { font-size: 12px; font-weight: 700; color: #16A34A; background: #E9F9EE; padding: 4px 9px; border-radius: 8px; }
.plan-tag { font-size: 13.5px; line-height: 1.5; color: #5B6470; margin: 8px 0 0; }
.price { display: flex; align-items: baseline; gap: 8px; margin-top: 16px; }
.price .was { color: #9AA0AA; text-decoration: line-through; font-size: 14px; }
.price .now { font-size: 32px; font-weight: 800; letter-spacing: -0.02em; color: #14161B; }
.price .per { font-size: 14px; color: #5B6470; }
.price-year { font-size: 12.5px; color: #9AA0AA; margin: 4px 0 0; }
.feats { list-style: none; margin: 18px 0 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.feats li { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: #333A44; line-height: 1.4; }
.feats .ck { flex: none; color: var(--blue); margin-top: 1px; }
.plan .btn { margin-top: 20px; }
.plan .fineprint { color: #9AA0AA; text-align: center; margin-top: 12px; }

/* card educacional (frio, gradiente) */
.edu {
  background: var(--intro-bg);
  border: 1px solid var(--video-border);
  border-radius: 20px; padding: 24px; color: #fff;
}
.edu h3 { font-size: 16px; font-weight: 800; margin: 0 0 8px; color: #fff; }
.edu p { font-size: 14px; line-height: 1.5; color: rgba(255, 255, 255, 0.9); margin: 0 0 18px; }
.edu .actions { display: flex; flex-direction: column; gap: 10px; }

.result-foot { text-align: center; margin-top: 20px; }

/* utilidades / erro */
.error-box { background: var(--hero-bg); border: 1px solid var(--hero-border); border-radius: 20px; padding: 26px 22px; text-align: center; }
