/* ==========================================================================
   Que nota tira a sua anamnese? — Doctors Institute
   Identidade: "clínica premium editorial" — deep teal-ink + ouro metálico
   líquido + ivory. Fraunces (títulos) + Manrope (corpo).
   Mobile-first: 100dvh, safe-area, CTA fixo, opções roláveis.
   ========================================================================== */

:root {
  --bg: #0C2224;
  --surface: #12302F;
  --surface-2: #173B39;
  --ink: #F4EFE6;
  --muted: #9FB3AC;
  --line: rgba(244, 239, 230, 0.13);
  --line-strong: rgba(244, 239, 230, 0.25);

  --gold: #C9A45C;
  --gold-light: #DDBB7A;
  --gold-dark: #6B4F1E;
  --emerald: #4E9B7D;
  --steel: #5A93A0;
  --bronze: #B8834F;

  --tone-gold: var(--gold);
  --tone-green: #3EA06D;
  --tone-yellow: #D9A73B;
  --tone-red: #C1503F;

  --gold-gradient: linear-gradient(135deg, var(--gold-light), var(--gold) 55%, var(--gold-dark));

  --display: "Fraunces", Georgia, serif;
  --body: "Manrope", system-ui, sans-serif;
  --page-padding: clamp(20px, 4vw, 56px);
  --transition: 280ms cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  background: var(--bg);
  color-scheme: dark;
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  min-height: 100vh;
  overflow-x: hidden;
  background:
    radial-gradient(60% 46% at 88% 6%, rgba(201, 164, 92, 0.09), transparent 70%),
    radial-gradient(55% 55% at 4% 100%, rgba(78, 155, 125, 0.08), transparent 70%),
    var(--bg);
  color: var(--ink);
  font: 400 16px/1.6 var(--body);
  letter-spacing: 0.005em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

button,
input {
  font: inherit;
}

em, i, cite { font-style: normal; }
button { color: inherit; background: none; border: none; cursor: pointer; }
button, a, input, [tabindex] { -webkit-tap-highlight-color: transparent; }

button:focus-visible,
input:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--gold-light);
  outline-offset: 3px;
}

#question-title:focus-visible,
#contact-title:focus-visible {
  outline: none;
}

::selection { background: var(--gold); color: var(--bg); }

.grain {
  position: fixed;
  z-index: 20;
  inset: 0;
  opacity: 0.03;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 140 140' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.8'/%3E%3C/svg%3E");
}

/* ---------------------------- Tipografia utilitária ---------------------------- */

.eyebrow {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
}
.eyebrow b { color: var(--ink); font-weight: 700; }

h1, h2, h3 {
  font-family: var(--display);
  font-weight: 300;
  line-height: 1.06;
  color: var(--ink);
}

h1 em, h2 em {
  font-style: italic;
  font-weight: 400;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.spectrum-line {
  height: 3px;
  width: min(220px, 60%);
  border-radius: 99px;
  margin: 20px 0;
  background: linear-gradient(90deg, var(--gold-light), var(--gold), var(--emerald));
}

/* ---------------------------- Botões ---------------------------- */

.primary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 56px;
  padding: 0 28px;
  border-radius: 999px;
  border: 1px solid var(--gold);
  background: var(--gold-gradient);
  color: #1a1204;
  font: 700 15px/1 var(--body);
  letter-spacing: 0.01em;
  box-shadow: 0 18px 40px rgba(201, 164, 92, 0.22);
  transition: transform var(--transition), box-shadow var(--transition), opacity var(--transition);
}
.primary-button:hover { transform: translateY(-2px); box-shadow: 0 22px 48px rgba(201, 164, 92, 0.3); }
.primary-button:disabled { opacity: 0.55; cursor: not-allowed; transform: none; box-shadow: none; }
.primary-button svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.primary-button.full { width: 100%; }

.text-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font: 600 13.5px/1 var(--body);
  letter-spacing: 0.03em;
  padding: 10px 4px;
  transition: color var(--transition);
}
.text-button:hover { color: var(--ink); }
.text-button svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ---------------------------- Componente de imagem placeholder ---------------------------- */

.img-ph {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  border-radius: 18px;
  border: 1px solid rgba(201, 164, 92, 0.32);
  background:
    linear-gradient(155deg, rgba(23, 59, 57, 0.92), rgba(201, 164, 92, 0.14) 60%, rgba(23, 59, 57, 0.92)),
    var(--surface);
  overflow: hidden;
  text-align: center;
}
.img-ph::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(135deg, rgba(244, 239, 230, 0.035) 0 2px, transparent 2px 26px);
  pointer-events: none;
}
.img-ph-icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid rgba(201, 164, 92, 0.5);
  background: rgba(12, 34, 36, 0.55);
  box-shadow: 0 0 22px rgba(201, 164, 92, 0.28);
}
.img-ph-icon svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: var(--gold-light);
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.img-ph-icon.play-icon svg { fill: var(--gold-light); stroke: none; width: 18px; height: 18px; }
.img-ph-caption {
  font: 600 13px/1.3 var(--body);
  color: var(--ink);
  padding: 0 16px;
}
.img-ph-label {
  position: absolute;
  top: 10px;
  right: 10px;
  font: 700 9.5px/1 var(--body);
  letter-spacing: 0.1em;
  color: var(--gold-light);
  background: rgba(12, 34, 36, 0.72);
  border: 1px solid rgba(201, 164, 92, 0.35);
  border-radius: 6px;
  padding: 4px 7px;
}

/* ---------------------------- Telas (screens) ---------------------------- */

#app { min-height: 100vh; }

.screen {
  min-height: 100vh;
  width: 100%;
  padding: 32px var(--page-padding) 48px;
  display: flex;
  flex-direction: column;
  animation: screen-in 480ms var(--transition) both;
}
.screen[hidden] { display: none !important; }

@keyframes screen-in {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}

/* ---------------------------- HERO ---------------------------- */

.screen-hero {
  justify-content: center;
  align-items: center;
  text-align: center;
}
.hero-copy {
  width: 100%;
  max-width: 480px;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.brand-mark span {
  font-family: var(--display);
  font-weight: 500;
  font-size: 15px;
  letter-spacing: 0.06em;
  color: var(--gold-light);
}
.seal-eyebrow { margin-top: 18px; }
.seal-eyebrow span {
  display: inline-block;
  padding: 6px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--surface);
}
#hero-title {
  margin-top: 18px;
  font-size: clamp(34px, 8vw, 54px);
  max-width: 14ch;
  text-wrap: balance;
}
.hero-lead {
  color: var(--muted);
  font-size: 16px;
  max-width: 42ch;
  margin-bottom: 26px;
}

.hero-video-wrap { width: 100%; max-width: 300px; margin-bottom: 26px; }
.hero-video-ph {
  aspect-ratio: 4 / 5;
  padding: 18px;
  cursor: pointer;
}
.hero-video-ph:hover .img-ph-icon { box-shadow: 0 0 30px rgba(201, 164, 92, 0.45); }

.hero-start { width: 100%; max-width: 340px; }
.hero-microcopy {
  margin-top: 14px;
  font-size: 12.5px;
  color: var(--muted);
  letter-spacing: 0.03em;
}

/* ---------------------------- SEÇÃO — TELA-INTERCALAR ---------------------------- */

.screen-section {
  justify-content: center;
  align-items: center;
  text-align: center;
  cursor: pointer;
}
.section-image {
  width: 100%;
  max-width: 320px;
  aspect-ratio: 4 / 3;
  margin: 18px 0 22px;
}
.section-kicker {
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-light);
  margin-bottom: 8px;
}
#section-title {
  font-size: clamp(28px, 6.4vw, 40px);
  max-width: 16ch;
}
.section-hint {
  margin-top: 22px;
  font-size: 12.5px;
  color: var(--muted);
  letter-spacing: 0.03em;
}

/* ---------------------------- QUIZ ---------------------------- */

.screen-quiz {
  padding-top: 24px;
  gap: 18px;
}

.quiz-progress { width: 100%; max-width: 560px; margin: 0 auto; }
.progress-copy {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
  font-size: 11.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold-light);
}
.progress-copy strong {
  font-family: var(--body);
  font-weight: 700;
  color: var(--muted);
  letter-spacing: 0.04em;
  text-transform: none;
  white-space: nowrap;
}
.progress-track {
  position: relative;
  height: 5px;
  border-radius: 99px;
  background: var(--surface-2);
  overflow: hidden;
}
#progress-bar {
  display: block;
  height: 100%;
  width: 5.5%;
  border-radius: 99px;
  background: var(--gold-gradient);
  transition: width 420ms var(--transition);
}

.question-panel {
  width: 100%;
  max-width: 560px;
  margin: 0 auto;
  flex: 1;
  display: flex;
  flex-direction: column;
}
#question-title {
  font-size: clamp(26px, 5.6vw, 36px);
  margin: 10px 0 10px;
  text-wrap: balance;
}
.question-help {
  color: var(--muted);
  font-size: 14.5px;
  line-height: 1.5;
  margin-bottom: 18px;
}
.question-help[hidden] { display: none; }

.options {
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow-y: auto;
  padding-right: 2px;
}
.option {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  text-align: left;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  transition: border-color var(--transition), background var(--transition), transform var(--transition);
}
.option:hover { border-color: var(--line-strong); background: var(--surface-2); }
.option.is-selected {
  border-color: var(--gold);
  background: linear-gradient(135deg, rgba(201, 164, 92, 0.16), rgba(78, 155, 125, 0.08));
}
.option.is-advancing { transform: scale(0.99); }
.option-marker {
  flex: none;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  font: 700 12.5px/1 var(--body);
  color: var(--muted);
}
.option.is-selected .option-marker {
  border-color: var(--gold);
  background: var(--gold-gradient);
  color: #1a1204;
}
.option-text { font-size: 14.5px; line-height: 1.4; color: var(--ink); }

.validation-message {
  margin-top: 12px;
  font-size: 12.5px;
  color: var(--tone-yellow);
}
.validation-message.is-confirmed { color: var(--emerald); }
.validation-message[hidden] { display: none; }

.question-actions {
  margin-top: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.auto-advance-hint {
  font-size: 11.5px;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 6px;
}
.auto-advance-hint i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--emerald);
  flex: none;
}

/* ---------------------------- CONTATO ---------------------------- */

.screen-contact { justify-content: center; align-items: center; }
.contact-card {
  width: 100%;
  max-width: 440px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
#contact-title { font-size: clamp(26px, 5.6vw, 34px); margin: 8px 0 4px; }
.contact-lead { color: var(--muted); font-size: 14.5px; margin-bottom: 6px; }

.field { display: flex; flex-direction: column; gap: 6px; }
.field span {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--muted);
  text-transform: uppercase;
}
.field input {
  height: 52px;
  padding: 0 16px;
  border-radius: 12px;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--ink);
  font-size: 15px;
}
.field input::placeholder { color: var(--muted); }
.field input.is-invalid { border-color: var(--tone-red); }
.field-error { min-height: 14px; font-size: 12px; color: var(--tone-red); }

.check-field {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
  cursor: pointer;
}
.check-field input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--gold); flex: none; }
.check-field.optional { opacity: 0.85; }

.privacy-note { font-size: 11.5px; color: var(--muted); text-align: center; margin-top: 4px; }

/* ---------------------------- ANÁLISE ---------------------------- */

.screen-analysis {
  justify-content: center;
  align-items: center;
  text-align: center;
  gap: 6px;
}
.analysis-orb {
  position: relative;
  width: 72px;
  height: 72px;
  margin-bottom: 20px;
}
.analysis-orb span {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px solid var(--gold);
  opacity: 0.55;
  animation: orb-pulse 1.8s var(--transition) infinite;
}
.analysis-orb span:nth-child(2) { animation-delay: 0.3s; }
.analysis-orb span:nth-child(3) { animation-delay: 0.6s; }
@keyframes orb-pulse {
  0% { transform: scale(0.6); opacity: 0.7; }
  100% { transform: scale(1.4); opacity: 0; }
}

#analysis-title { max-width: 20ch; font-size: clamp(24px, 5.2vw, 32px); margin: 6px 0 14px; }
#analysis-status { color: var(--gold-light); font-size: 14.5px; min-height: 20px; margin-bottom: 18px; }

.analysis-track {
  width: 100%;
  max-width: 320px;
  height: 4px;
  border-radius: 99px;
  background: var(--surface-2);
  overflow: hidden;
  margin-bottom: 22px;
}
#analysis-bar {
  display: block;
  height: 100%;
  width: 8%;
  background: var(--gold-gradient);
  border-radius: 99px;
  transition: width 500ms var(--transition);
}

.analysis-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 13px;
  color: var(--muted);
}
.analysis-list li { position: relative; padding-left: 22px; text-align: left; }
.analysis-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
}
.analysis-list li.is-done { color: var(--ink); }
.analysis-list li.is-done::before {
  border-color: var(--emerald);
  background: var(--emerald);
}

/* ---------------------------- RESULTADO ---------------------------- */

.screen-result { position: relative; align-items: center; text-align: center; gap: 28px; }
.result-bg {
  position: absolute;
  inset: 12px var(--page-padding);
  z-index: -1;
  opacity: 0.5;
  border-radius: 24px;
}
.result-bg .img-ph-label { top: auto; bottom: 10px; right: 10px; }

.result-hero { width: 100%; max-width: 480px; display: flex; flex-direction: column; align-items: center; }
.result-score-wrap { display: flex; flex-direction: column; align-items: center; gap: 14px; margin: 14px 0 18px; }
.result-score {
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(96px, 26vw, 148px);
  line-height: 0.9;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.result-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 18px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: var(--surface);
}
.result-badge strong { font: 700 13px/1 var(--body); letter-spacing: 0.04em; }
.badge-image {
  width: 22px;
  height: 22px;
  min-height: 0;
  border-radius: 50%;
  padding: 0;
}
.result-badge.tone-gold { border-color: var(--gold); }
.result-badge.tone-gold strong { color: var(--gold-light); }
.result-badge.tone-green { border-color: var(--tone-green); }
.result-badge.tone-green strong { color: var(--tone-green); }
.result-badge.tone-yellow { border-color: var(--tone-yellow); }
.result-badge.tone-yellow strong { color: var(--tone-yellow); }
.result-badge.tone-red { border-color: var(--tone-red); }
.result-badge.tone-red strong { color: var(--tone-red); }

#result-title { font-size: clamp(22px, 5vw, 30px); max-width: 20ch; }

.result-grid {
  width: 100%;
  max-width: 720px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}
.result-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 20px;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.result-weak-dims { display: flex; flex-direction: column; gap: 10px; }
.weak-dim {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-top: 1px solid var(--line);
  padding-top: 10px;
}
.weak-dim:first-child { border-top: none; padding-top: 0; }
.weak-dim strong { font-size: 14px; font-weight: 600; color: var(--ink); }
.weak-dim span { font-family: var(--display); font-size: 18px; color: var(--gold-light); }
.result-gap { font-size: 15px; line-height: 1.55; color: var(--ink); }

.result-bridge {
  width: 100%;
  max-width: 480px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}
.result-bridge p { color: var(--muted); font-size: 14.5px; line-height: 1.55; }

/* ---------------------------- OFERTA ---------------------------- */

.screen-offer { align-items: center; }
.offer-grid {
  width: 100%;
  max-width: 980px;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 32px;
  align-items: start;
}
.offer-copy { display: flex; flex-direction: column; gap: 16px; }
#offer-title { font-size: clamp(26px, 4.6vw, 36px); max-width: 18ch; }

.offer-items { list-style: none; display: flex; flex-direction: column; gap: 9px; }
.offer-items li {
  position: relative;
  padding-left: 22px;
  font-size: 14.5px;
  color: var(--ink);
  line-height: 1.4;
}
.offer-items li::before { content: "✦"; position: absolute; left: 0; top: 0; color: var(--gold); font-size: 12px; }

.offer-scope-note {
  font-size: 12.5px;
  color: var(--muted);
  font-style: italic;
  border-left: 2px solid var(--line-strong);
  padding-left: 12px;
}

.offer-differentials ul { list-style: none; display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.offer-differentials li {
  position: relative;
  padding-left: 20px;
  font-size: 13.5px;
  color: var(--muted);
  line-height: 1.4;
}
.offer-differentials li::before { content: "—"; position: absolute; left: 0; color: var(--emerald); }

.offer-social {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 6px;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--surface);
}
.offer-social-ph { width: 84px; height: 84px; flex: none; aspect-ratio: 1; border-radius: 12px; }
.offer-social-quote { font-size: 13px; color: var(--muted); font-style: italic; line-height: 1.4; }

.offer-checkout-card {
  background: var(--surface);
  border: 1px solid var(--gold);
  border-radius: 20px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.28);
}
.checkout-badge {
  align-self: flex-start;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--bg);
  background: var(--gold-gradient);
  padding: 5px 12px;
  border-radius: 999px;
}
.offer-kit-ph { aspect-ratio: 4 / 3; margin: 4px 0; }
.offer-checkout-card h3 { font-size: 19px; font-weight: 500; line-height: 1.25; }

.price { display: flex; align-items: baseline; gap: 10px; margin-top: 4px; }
.price small { font-size: 12.5px; color: var(--muted); }
.price small s { color: var(--muted); }
.price strong {
  font-family: var(--display);
  font-size: 40px;
  font-weight: 500;
  color: var(--gold-light);
}
.price strong sup { font-size: 18px; margin-right: 2px; }

.offer-anchor-line {
  font-size: 13px;
  font-style: italic;
  color: var(--ink);
  border-left: 2px solid var(--gold);
  padding-left: 10px;
}
.offer-guarantee { font-size: 12.5px; color: var(--muted); }

.offer-gateway-note {
  font-size: 11.5px;
  color: var(--muted);
  text-align: center;
}
.offer-waitlist-status {
  font-size: 13px;
  color: var(--emerald);
  text-align: center;
  line-height: 1.4;
}
.offer-waitlist-status[hidden] { display: none; }
.offer-restart { align-self: center; margin-top: 4px; }

/* ---------------------------- Toast / noscript ---------------------------- */

.toast {
  position: fixed;
  z-index: 30;
  left: 50%;
  bottom: max(24px, env(safe-area-inset-bottom));
  transform: translateX(-50%);
  padding: 12px 20px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: rgba(18, 48, 47, 0.95);
  backdrop-filter: blur(12px);
  color: var(--ink);
  font-size: 13px;
  max-width: min(90vw, 360px);
  text-align: center;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.3);
}
.toast[hidden] { display: none; }

.noscript {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  text-align: center;
  background: var(--bg);
  color: var(--ink);
}

/* ==========================================================================
   Mobile-first refinements — 100dvh, safe-area, CTA fixo, opções roláveis
   ========================================================================== */

@media (max-width: 720px) {
  .offer-grid { grid-template-columns: 1fr; }
  .result-grid { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  :root { --page-padding: 18px; }

  body[data-active-screen="hero"],
  body[data-active-screen="quiz"],
  body[data-active-screen="section"] {
    height: 100dvh;
    overflow: hidden;
    overscroll-behavior: none;
  }

  body[data-active-screen="hero"] #app,
  body[data-active-screen="quiz"] #app,
  body[data-active-screen="section"] #app {
    height: 100%;
    min-height: 0;
  }

  .screen-hero {
    height: 100dvh;
    min-height: 0;
    padding:
      max(20px, env(safe-area-inset-top))
      var(--page-padding)
      calc(96px + env(safe-area-inset-bottom));
  }

  .hero-video-wrap { max-width: 220px; margin-bottom: 18px; }

  .hero-start {
    position: fixed;
    z-index: 12;
    left: var(--page-padding);
    right: var(--page-padding);
    bottom: max(14px, env(safe-area-inset-bottom));
    width: auto;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4);
  }

  .hero-microcopy { margin-bottom: 70px; }

  .screen-section {
    height: 100dvh;
    min-height: 0;
    padding:
      max(20px, env(safe-area-inset-top))
      var(--page-padding)
      max(20px, env(safe-area-inset-bottom));
  }

  .screen-quiz {
    height: 100dvh;
    min-height: 0;
    padding:
      max(14px, env(safe-area-inset-top))
      16px
      max(10px, env(safe-area-inset-bottom));
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    gap: 12px;
  }

  .question-panel {
    min-height: 0;
    overflow: hidden;
  }

  #question-title {
    font-size: clamp(24px, 7vw, 30px);
  }

  .options {
    min-height: 0;
    overscroll-behavior: contain;
    scrollbar-width: none;
  }
  .options::-webkit-scrollbar { display: none; }

  .question-actions {
    position: sticky;
    bottom: max(6px, env(safe-area-inset-bottom));
    padding-top: 8px;
    background: linear-gradient(180deg, transparent, var(--bg) 40%);
  }

  .screen-contact,
  .screen-analysis,
  .screen-result,
  .screen-offer {
    padding-bottom: calc(40px + env(safe-area-inset-bottom));
  }

  .offer-social { flex-direction: column; text-align: center; }

  .toast { bottom: max(16px, env(safe-area-inset-bottom)); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
