/* ───────────────────────────────────────────────────────────────
   CobraAí — pre-login funnel styles (#N-D113)
   Funnel-specific layout on top of the shared brand.css design system
   (tokens + .btn/.brand-card etc.). Scoped to the .brand body wrapper,
   like brand.css. No @import / inline anything (strict CSP).
   Covers: qualificação wizard, login, check-email, confirm.
   ─────────────────────────────────────────────────────────────── */

/* Shared utility — these pages toggle visibility from JS via .hidden. */
.brand .hidden { display: none !important; }

/* ── Minimal top bar (funnel — lighter than the full site-nav) ── */
.funnel-bar {
  background: var(--white);
  border-bottom: 1px solid var(--border);
}
.funnel-bar__inner {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 24px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.funnel-bar__wordmark { font-size: 24px; }

/* ── Page shell ── */
.funnel-page {
  background: var(--bg);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.funnel-main {
  flex: 1;
  width: 100%;
  max-width: 560px;
  margin: 0 auto;
  padding: 48px 24px 64px;
}

/* ── Funnel footer ── */
.funnel-footer {
  text-align: center;
  padding: 28px 24px 40px;
  font-size: 13px;
  color: var(--faint);
}
.funnel-footer a {
  color: var(--muted);
  text-decoration: none;
}
.funnel-footer a:hover { color: var(--navy); }

/* ───────────────────────────────────────────────────────────────
   Centered single-card screens (login / check-email / confirm)
   ─────────────────────────────────────────────────────────────── */
.funnel-center {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 24px;
}
.funnel-card {
  width: 100%;
  max-width: 440px;
  text-align: center;
  padding: 40px 36px;
}
.funnel-card__icon { font-size: 44px; line-height: 1; margin-bottom: 16px; color: var(--amber); }
.funnel-card__icon svg { width: 44px; height: 44px; display: block; margin: 0 auto; }
.funnel-card h1 { font-size: 28px; letter-spacing: -0.5px; margin-bottom: 10px; }
.funnel-card__sub { color: var(--muted); font-size: 15px; line-height: 1.6; }
.funnel-card form { margin-top: 28px; text-align: left; }
.funnel-card .funnel-info { text-align: center; }

/* ── Form fields (shared) ── */
.funnel-field { display: block; margin-bottom: 18px; text-align: left; }
.funnel-field > span,
.funnel-field > legend {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 6px;
}
.funnel-field input,
.funnel-field select {
  width: 100%;
  font-family: inherit;
  font-size: 15px;
  color: var(--text);
  background: var(--white);
  border: 1.5px solid var(--border-dark);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  transition: border-color .15s, box-shadow .15s;
}
.funnel-field input:focus,
.funnel-field select:focus {
  outline: none;
  border-color: var(--amber);
  box-shadow: 0 0 0 3px rgba(201,139,10,0.12);
}
.funnel-field small {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin-top: 5px;
}

/* ── Info / error blocks ── */
.funnel-info {
  margin-top: 24px;
  padding: 14px 16px;
  background: var(--info-bg);
  border-radius: var(--radius-sm);
  font-size: 13px;
  line-height: 1.6;
  color: var(--info-text);
}
.funnel-err {
  margin-top: 14px;
  padding: 12px 14px;
  background: var(--red-light);
  border: 1px solid var(--red);
  border-radius: var(--radius-sm);
  color: var(--red);
  font-size: 14px;
  text-align: left;
}
.funnel-link {
  display: inline-block;
  margin-top: 22px;
  color: var(--muted);
  font-size: 14px;
  text-decoration: none;
}
.funnel-link:hover { color: var(--navy); }

/* Resend-magic-link feedback on /check-email (#N-D121). */
.funnel-card #resendBtn { margin-top: 24px; }
.funnel-resend-status { margin: 12px 0 0; font-size: 13px; color: var(--green); }
.funnel-resend-status--err { color: var(--red); }

/* ───────────────────────────────────────────────────────────────
   Qualificação wizard
   ─────────────────────────────────────────────────────────────── */
.prequal { width: 100%; }

/* Progress dots (rendered by qualificacao.js into #progress) */
.prequal-progress {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-bottom: 32px;
}
.prequal-dot {
  width: 40px;
  height: 5px;
  border-radius: 4px;
  background: var(--border);
  transition: background .2s;
}
.prequal-dot.is-active { background: var(--amber); }
.prequal-dot.is-done { background: var(--navy); }

/* Step / result cards reuse the brand-card surface */
.prequal-step,
.prequal-result {
  background: var(--white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  padding: 36px 36px 32px;
}
.prequal-result { text-align: center; }

.prequal-eyebrow {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--amber);
  margin-bottom: 10px;
}
.prequal-step h1,
.prequal-result h1 {
  font-size: 26px;
  letter-spacing: -0.5px;
  margin-bottom: 8px;
}
.prequal .muted { color: var(--muted); font-size: 15px; line-height: 1.6; margin-bottom: 24px; }
.prequal-result .muted { margin-left: auto; margin-right: auto; max-width: 420px; }

/* Reuse the shared field styles for the wizard */
.prequal-field { display: block; margin-bottom: 20px; text-align: left; border: none; padding: 0; }
.prequal-field > span,
.prequal-field > legend {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 6px;
  padding: 0;
}
.prequal-field input,
.prequal-field select {
  width: 100%;
  font-family: inherit;
  font-size: 15px;
  color: var(--text);
  background: var(--white);
  border: 1.5px solid var(--border-dark);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  transition: border-color .15s, box-shadow .15s;
}
.prequal-field input:focus,
.prequal-field select:focus {
  outline: none;
  border-color: var(--amber);
  box-shadow: 0 0 0 3px rgba(201,139,10,0.12);
}
.prequal-field small { display: block; font-size: 12px; color: var(--muted); margin-top: 5px; }

/* Phone (DDI + number) group */
.phone-group { display: flex; gap: 8px; }
.phone-ddi { flex: 0 0 110px; }
.phone-number { flex: 1; }

/* Yes/No toggle buttons */
.prequal-toggle { display: flex; gap: 10px; margin-top: 8px; }
.prequal-toggle button {
  flex: 1;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  color: var(--navy);
  background: var(--white);
  border: 1.5px solid var(--border-dark);
  border-radius: var(--radius-sm);
  padding: 12px;
  cursor: pointer;
  transition: border-color .15s, background .15s, color .15s;
}
.prequal-toggle button:hover { border-color: var(--navy); }
.prequal-toggle button.is-selected {
  background: var(--navy);
  border-color: var(--navy);
  color: var(--white);
}

/* Step navigation row */
.prequal-nav {
  display: flex;
  gap: 12px;
  justify-content: space-between;
  margin-top: 28px;
}
.prequal-nav .btn { flex: 0 0 auto; }
.prequal-nav [data-action="next"],
.prequal-nav [data-action="submit"] { margin-left: auto; }
.btn:disabled,
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.btn:disabled:hover { opacity: .45; }

/* Result badges */
.prequal-badge {
  width: 56px; height: 56px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 28px; font-weight: 700;
  margin: 0 auto 18px;
}
.prequal-badge--ok { background: var(--green-light); color: var(--green); }
.prequal-badge--no { background: var(--red-light); color: var(--red); }

/* Eligible — quote box */
.prequal-quote {
  background: var(--amber-light);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  margin: 24px 0 16px;
  text-align: left;
}
.prequal-quote > div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
}
.prequal-quote > div + div { border-top: 1px solid var(--border); }
.prequal-quote span { font-size: 14px; color: var(--muted); }
.prequal-quote strong { font-family: var(--font-serif); font-size: 20px; color: var(--navy); }
.prequal-fineprint { font-size: 12px; color: var(--faint); line-height: 1.6; text-align: left; margin-bottom: 8px; }

/* Lead capture block */
.prequal-lead { margin-top: 24px; text-align: left; }
.prequal-lead .btn { width: 100%; margin-top: 4px; }

/* Reassurance checklist at the e-mail-capture moment (the funnel's highest
   drop point): LGPD + no-marketing + what-happens-next (C1/funnel pass). */
.prequal-reassure {
  list-style: none;
  margin: 14px 0 4px;
  padding: 28px 32px;
  background: var(--green-light);
  border: 1px solid var(--green);
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.prequal-reassure li {
  position: relative;
  padding-left: 22px;
  font-size: 13px;
  color: var(--text);
  line-height: 1.45;
}
.prequal-reassure li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--green);
  font-weight: 700;
}

.prequal-err {
  margin: 0 0 14px;
  padding: 16px 24px;
  background: var(--red-light);
  border: 1px solid var(--red);
  border-radius: var(--radius-sm);
  color: var(--red);
  font-size: 14px;
  text-align: left;
}

.btn-large { font-size: 16px; padding: 16px 28px; }

/* Ineligible — help block */
.prequal-help {
  margin-top: 28px;
  padding: 22px 24px;
  background: var(--amber-light);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.prequal-help p { font-size: 14px; color: var(--muted); margin-bottom: 14px; line-height: 1.6; }

.prequal-link {
  display: block;
  margin-top: 22px;
  color: var(--muted);
  font-size: 14px;
  text-decoration: none;
}
.prequal-link:hover { color: var(--navy); }

.prequal-result .btn { margin-top: 8px; }
.prequal-result .btn + .prequal-help { margin-top: 28px; }

@media (max-width: 540px) {
  .prequal-step,
  .prequal-result { padding: 28px 22px; }
  .funnel-card { padding: 32px 24px; }
  .prequal-nav { flex-wrap: wrap; }
  .prequal-nav .btn { flex: 1 1 auto; }
}
