/* ============================================================
   VSL — Gestão de tráfego pago para clínicas | Atemes
   Paleta: branco + verde esmeralda
   Para trocar para BRANCO + AZUL: mude apenas o bloco --brand-*
   abaixo para os valores comentados. Nada mais precisa mudar.
   ============================================================ */

:root {
  /* ---- MARCA (esmeralda) ---- */
  --brand-900: #052e26;
  --brand-700: #065f46;
  --brand-600: #047857;
  --brand-500: #059669;
  --brand-400: #10b981;
  --brand-100: #d1fae5;
  --brand-050: #ecfdf5;

  /* ---- ALTERNATIVA AZUL (descomente para trocar) ----
  --brand-900: #082f49;
  --brand-700: #075985;
  --brand-600: #0369a1;
  --brand-500: #0284c7;
  --brand-400: #0ea5e9;
  --brand-100: #e0f2fe;
  --brand-050: #f0f9ff;
  ---------------------------------------------------- */

  --ink-900: #0b1220;
  --ink-700: #253044;
  --ink-500: #55617a;
  --ink-300: #97a1b5;
  --line: #e4e8ef;
  --bg: #ffffff;
  --bg-soft: #f7f9fc;

  --radius: 16px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgba(11, 18, 32, .06), 0 4px 12px rgba(11, 18, 32, .04);
  --shadow-lg: 0 24px 60px rgba(5, 46, 38, .14), 0 4px 14px rgba(11, 18, 32, .06);
  --wrap: 1080px;
  --ease: cubic-bezier(.22, .61, .36, 1);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink-900);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 24px;
}

h1, h2, h3 { line-height: 1.18; letter-spacing: -.02em; margin: 0; }

/* ============ TOPBAR ============ */
.topbar {
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, .88);
  backdrop-filter: saturate(180%) blur(12px);
  position: sticky;
  top: 0;
  z-index: 50;
}
.topbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 62px;
}
.brand {
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: -.03em;
  color: var(--brand-700);
}
.brand--sm { font-size: 1rem; }
.topbar__tag {
  font-size: .78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .09em;
  color: var(--brand-600);
  background: var(--brand-050);
  border: 1px solid var(--brand-100);
  padding: 5px 12px;
  border-radius: 999px;
}

/* ============ HERO ============ */
.hero {
  padding: 56px 0 40px;
  background:
    radial-gradient(1100px 460px at 50% -12%, var(--brand-050) 0%, transparent 68%),
    var(--bg);
  text-align: center;
}
.eyebrow {
  margin: 0 0 16px;
  font-size: .8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--brand-600);
}
.hero__title {
  font-size: clamp(1.9rem, 4.6vw, 3.15rem);
  font-weight: 800;
  max-width: 20ch;
  margin: 0 auto;
}
.strike {
  position: relative;
  white-space: nowrap;
  color: var(--ink-500);
}
.strike::after {
  content: "";
  position: absolute;
  left: -2%;
  right: -2%;
  top: 52%;
  height: 3px;
  background: var(--brand-500);
  border-radius: 2px;
  transform: rotate(-2.5deg);
}
.hero__sub {
  margin: 20px auto 34px;
  max-width: 62ch;
  color: var(--ink-500);
  font-size: 1.06rem;
}
.hero__sub strong { color: var(--ink-900); }

/* ============ PLAYER ============ */
.player {
  position: relative;
  width: 100%;
  max-width: 860px;
  margin: 0 auto;
  aspect-ratio: 16 / 9;
  background: var(--brand-900);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.player__video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
}

/* Estado sem arquivo */
.player__missing {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #fff;
  background: linear-gradient(160deg, var(--brand-900), var(--brand-700));
  padding: 24px;
  text-align: center;
}
.player__missing-icon {
  width: 62px;
  height: 62px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, .32);
  display: grid;
  place-items: center;
  font-size: 1.3rem;
  margin-bottom: 6px;
}
.player__missing-title { margin: 0; font-weight: 700; font-size: 1.1rem; }
.player__missing-hint { margin: 0; font-size: .88rem; opacity: .72; }
.player__missing-hint code {
  background: rgba(255, 255, 255, .14);
  padding: 2px 7px;
  border-radius: 5px;
  font-size: .85em;
}

/* Overlay de play */
.player__overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  border: 0;
  cursor: pointer;
  color: #fff;
  background: linear-gradient(180deg, rgba(5, 46, 38, .34), rgba(5, 46, 38, .62));
  transition: opacity .32s var(--ease), visibility .32s;
  font: inherit;
}
.player__overlay[hidden] { display: none; }
.player.is-playing .player__overlay { opacity: 0; visibility: hidden; }
.player__play {
  width: 82px;
  height: 82px;
  border-radius: 50%;
  background: #fff;
  display: grid;
  place-items: center;
  box-shadow: 0 12px 32px rgba(0, 0, 0, .3);
  transition: transform .25s var(--ease);
}
.player__play::after {
  content: "";
  border-left: 22px solid var(--brand-600);
  border-top: 14px solid transparent;
  border-bottom: 14px solid transparent;
  margin-left: 6px;
}
.player__overlay:hover .player__play { transform: scale(1.07); }
.player__overlay-label {
  font-weight: 700;
  font-size: 1.02rem;
  letter-spacing: .01em;
  text-shadow: 0 2px 10px rgba(0, 0, 0, .45);
}

/* Controles */
.player__controls {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  background: linear-gradient(180deg, transparent, rgba(4, 20, 16, .8));
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .28s var(--ease), transform .28s var(--ease);
}
.player.is-playing .player__controls,
.player:hover .player__controls { opacity: 1; transform: none; }

.ctrl {
  flex: none;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 8px;
  background: rgba(255, 255, 255, .16);
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: background .2s;
}
.ctrl:hover { background: rgba(255, 255, 255, .3); }
.ctrl__pause {
  width: 11px; height: 13px;
  border-left: 4px solid #fff;
  border-right: 4px solid #fff;
}
.ctrl.is-paused .ctrl__pause {
  width: 0; height: 0;
  border: 0;
  border-left: 13px solid #fff;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  margin-left: 4px;
}
.ctrl__sound {
  width: 15px; height: 15px;
  background: #fff;
  clip-path: polygon(0 32%, 32% 32%, 62% 6%, 62% 94%, 32% 68%, 0 68%);
}
.ctrl.is-muted .ctrl__sound { opacity: .42; }

.progress {
  flex: 1;
  height: 5px;
  background: rgba(255, 255, 255, .24);
  border-radius: 999px;
  overflow: hidden;
  /* sem cursor pointer: barra é indicador, não controle — impede pular */
}
.progress__fill {
  height: 100%;
  width: 0%;
  background: var(--brand-400);
  border-radius: 999px;
  transition: width .2s linear;
}
.time {
  flex: none;
  font-size: .82rem;
  font-variant-numeric: tabular-nums;
  color: rgba(255, 255, 255, .9);
  min-width: 42px;
  text-align: right;
}

.player__note {
  margin: 18px auto 0;
  max-width: 52ch;
  font-size: .88rem;
  color: var(--ink-300);
}
.player__note.is-close { color: var(--brand-600); font-weight: 600; }

/* ============ CTA / FORM ============ */
.cta {
  padding: 12px 0 64px;
  scroll-margin-top: 80px;
}
.cta[hidden] { display: none; }
.cta__card {
  max-width: 640px;
  margin: 0 auto;
  background: var(--bg);
  border: 1px solid var(--brand-100);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 40px 36px;
  animation: rise .6s var(--ease) both;
}
@keyframes rise {
  from { opacity: 0; transform: translateY(22px); }
  to   { opacity: 1; transform: none; }
}
.cta__eyebrow {
  margin: 0 0 10px;
  font-size: .76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--brand-600);
}
.cta__title { font-size: clamp(1.4rem, 2.9vw, 1.85rem); font-weight: 800; }
.cta__sub { margin: 14px 0 26px; color: var(--ink-500); font-size: .98rem; }

/* ---- Progresso ---- */
.steps { display: flex; align-items: center; gap: 12px; margin-bottom: 26px; }
.steps__bar {
  flex: 1;
  height: 5px;
  background: var(--brand-050);
  border-radius: 999px;
  overflow: hidden;
}
.steps__fill {
  height: 100%;
  width: 20%;
  background: var(--brand-500);
  border-radius: 999px;
  transition: width .38s var(--ease);
}
.steps__count {
  flex: none;
  font-size: .78rem;
  font-weight: 700;
  color: var(--ink-300);
  font-variant-numeric: tabular-nums;
}

/* ---- Uma pergunta por vez ---- */
.quiz { position: relative; text-align: left; }

.step {
  display: none;
  border: 0;
  padding: 0;
  margin: 0;
  min-inline-size: 0; /* fieldset não estoura o grid */
}
.step.is-active {
  display: grid;
  gap: 14px;
  animation: stepIn .42s var(--ease) both;
}
@keyframes stepIn {
  from { opacity: 0; transform: translateX(18px); }
  to   { opacity: 1; transform: none; }
}
.step.is-leaving { animation: stepOut .2s var(--ease) both; }
@keyframes stepOut {
  from { opacity: 1; transform: none; }
  to   { opacity: 0; transform: translateX(-14px); }
}

.step__q {
  font-size: clamp(1.15rem, 2.6vw, 1.4rem);
  font-weight: 800;
  line-height: 1.3;
  color: var(--ink-900);
  padding: 0;
  margin-bottom: 2px;
}

.step__input {
  width: 100%;
  padding: 15px 16px;
  font: inherit;
  font-size: 1.02rem;
  color: var(--ink-900);
  background: var(--bg-soft);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  transition: border-color .2s, box-shadow .2s, background .2s;
}
.step__input::placeholder { color: var(--ink-300); }
.step__input:focus {
  outline: none;
  background: var(--bg);
  border-color: var(--brand-500);
  box-shadow: 0 0 0 4px var(--brand-050);
}
.step.has-error .step__input { border-color: #dc2626; }
.step.has-error .step__input:focus { box-shadow: 0 0 0 4px #fee2e2; }

.step__error { font-size: .82rem; color: #dc2626; min-height: 0; }
.step.has-error .step__error { min-height: 1em; }

.step__hint {
  margin: -2px 0 0;
  font-size: .78rem;
  color: var(--ink-300);
  text-align: center;
}
.step__hint kbd {
  font: inherit;
  font-size: .95em;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-bottom-width: 2px;
  border-radius: 4px;
  padding: 1px 5px;
}

.step__back {
  justify-self: center;
  background: none;
  border: 0;
  font: inherit;
  font-size: .85rem;
  color: var(--ink-300);
  cursor: pointer;
  padding: 4px 8px;
  transition: color .2s;
}
.step__back:hover { color: var(--brand-600); text-decoration: underline; }

/* ---- Opções de múltipla escolha ---- */
.opts { display: grid; gap: 10px; }
.opt {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 15px 17px;
  background: var(--bg-soft);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: .98rem;
  transition: border-color .18s, background .18s, transform .12s;
}
.opt:hover { border-color: var(--brand-400); background: var(--bg); }
.opt:active { transform: scale(.99); }
.opt input {
  appearance: none;
  -webkit-appearance: none;
  flex: none;
  width: 20px;
  height: 20px;
  margin: 0;
  border: 2px solid var(--ink-300);
  border-radius: 50%;
  transition: border-color .18s, box-shadow .18s;
}
.opt input:checked {
  border-color: var(--brand-500);
  box-shadow: inset 0 0 0 5px var(--brand-500);
}
.opt:has(input:checked) {
  border-color: var(--brand-500);
  background: var(--brand-050);
  font-weight: 600;
}
.opt input:focus-visible { outline: 3px solid var(--brand-500); outline-offset: 3px; }

/* ---- Tela final ---- */
.step--done { text-align: center; justify-items: center; }
.done__check {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--brand-050);
  color: var(--brand-600);
  display: grid;
  place-items: center;
  font-size: 1.7rem;
  font-weight: 800;
  margin-bottom: 4px;
}
.done__title { margin: 0; font-size: 1.25rem; font-weight: 800; }
.done__sub { margin: 0; color: var(--ink-500); font-size: .95rem; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  font: inherit;
  font-weight: 700;
  font-size: 1.01rem;
  padding: 15px 26px;
  border-radius: var(--radius-sm);
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform .18s var(--ease), box-shadow .22s, background .2s;
}
.btn--primary {
  background: var(--brand-600);
  color: #fff;
  box-shadow: 0 8px 22px rgba(4, 120, 87, .28);
  width: 100%;
}
.btn--primary:hover {
  background: var(--brand-700);
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(4, 120, 87, .34);
}
.btn--primary:disabled {
  background: var(--ink-300);
  box-shadow: none;
  cursor: not-allowed;
  transform: none;
}
.btn--ghost {
  background: transparent;
  color: var(--brand-700);
  border-color: var(--brand-100);
}
.btn--ghost:hover { background: var(--brand-050); }

.form__legal {
  margin: 0;
  font-size: .79rem;
  color: var(--ink-300);
  text-align: center;
}

/* ============ PONTOS ============ */
.points { padding: 64px 0; background: var(--bg-soft); border-top: 1px solid var(--line); }
.section__title {
  font-size: clamp(1.5rem, 3.1vw, 2.05rem);
  font-weight: 800;
  text-align: center;
  margin-bottom: 40px;
}
.section__title--left { text-align: left; margin-bottom: 20px; }
.points__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 22px;
}
.point {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px 26px;
  box-shadow: var(--shadow-sm);
}
.point__num {
  display: inline-block;
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .1em;
  color: var(--brand-600);
  background: var(--brand-050);
  border-radius: 6px;
  padding: 3px 9px;
  margin-bottom: 14px;
}
.point h3 { font-size: 1.08rem; font-weight: 700; margin-bottom: 10px; }
.point p { margin: 0; color: var(--ink-500); font-size: .95rem; }

/* ============ PROVA ============ */
.proof { padding: 64px 0; }
.proof__inner {
  max-width: 720px;
  text-align: center;
}
.proof__mark {
  font-size: 4.5rem;
  line-height: .8;
  color: var(--brand-100);
  font-weight: 800;
}
.proof__quote {
  margin: 6px 0 20px;
  font-size: clamp(1.05rem, 2.2vw, 1.3rem);
  line-height: 1.55;
  color: var(--ink-700);
  font-style: italic;
}
.proof__author { margin: 0; color: var(--ink-500); font-size: .93rem; }
.proof__author strong { color: var(--brand-700); }

/* ============ QUEM ============ */
.who { padding: 56px 0; background: var(--bg-soft); border-top: 1px solid var(--line); }
.who__inner { max-width: 720px; }
.who__text p { color: var(--ink-500); }
.who__text strong { color: var(--ink-900); }

/* ============ FECHAMENTO ============ */
.closing {
  padding: 72px 0;
  text-align: center;
  background: linear-gradient(165deg, var(--brand-700), var(--brand-900));
  color: #fff;
}
.closing__title { font-size: clamp(1.5rem, 3.4vw, 2.2rem); font-weight: 800; }
.closing__sub { margin: 14px auto 28px; max-width: 46ch; opacity: .82; }
.closing .btn--ghost {
  background: rgba(255, 255, 255, .1);
  color: #fff;
  border-color: rgba(255, 255, 255, .28);
}
.closing .btn--ghost:hover { background: rgba(255, 255, 255, .2); }

/* ============ FOOTER ============ */
.footer { padding: 30px 0; border-top: 1px solid var(--line); }
.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}
.footer__note { margin: 0; font-size: .8rem; color: var(--ink-300); }

/* ============ RESPONSIVO ============ */
@media (max-width: 640px) {
  body { font-size: 16px; }
  .hero { padding: 38px 0 30px; }
  .cta__card { padding: 30px 22px; }
  .player__play { width: 66px; height: 66px; }
  .player__play::after { border-left-width: 18px; border-top-width: 11px; border-bottom-width: 11px; }
  .player__controls { padding: 10px 12px; gap: 10px; }
  .points, .proof, .who, .closing { padding: 48px 0; }
}

/* ============ ACESSIBILIDADE ============ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
:focus-visible {
  outline: 3px solid var(--brand-500);
  outline-offset: 2px;
  border-radius: 4px;
}
