/* =============================================================
   MDD — Formulário de Qualificação
   Identidade visual: Dra. Natália Pinheiro
   Paleta herdada da página da mentoria
============================================================= */

:root {
  --bordeaux: #6B1F2A;
  --bordeaux-deep: #3D1218;
  --bordeaux-ink: #2A0C12;
  --creme: #EFE8D6;
  --creme-2: #F5EFDF;
  --blush: #F4E9EA;
  --oliva: #5C6B3D;
  --gold: #c9a14d;
  --gold-soft: rgba(201, 161, 77, 0.55);
  --ink: #0a0a0a;
  --creme-soft: rgba(239, 232, 214, 0.85);
  --creme-mute: rgba(239, 232, 214, 0.62);
  --creme-faint: rgba(239, 232, 214, 0.35);
  --line: rgba(239, 232, 214, 0.14);
  --line-gold: rgba(201, 161, 77, 0.32);
  --error: #d97757;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }

body {
  font-family: 'Archivo', system-ui, sans-serif;
  background: var(--bordeaux);
  color: var(--creme);
  font-weight: 500;
  line-height: 1.55;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Noise overlay sutil */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 30;
  opacity: 0.03;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%25' height='100%25' filter='url(%23n)' opacity='0.9'/></svg>");
}

.shell {
  max-width: 680px;
  margin: 0 auto;
  padding: 0 28px;
  width: 100%;
}

/* ============ HEADER ============ */
.header {
  padding: 28px 0;
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.header-mark {
  font-family: 'Fraunces', Georgia, serif;
  font-style: italic;
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--gold);
  letter-spacing: -0.01em;
}
.header-meta {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--creme-mute);
}

/* ============ PROGRESS BAR ============ */
.progress-track {
  height: 2px;
  background: var(--line);
  width: 100%;
}
.progress-fill {
  height: 100%;
  background: var(--gold);
  transition: width 0.4s ease;
  width: 0;
}

/* ============ MAIN ============ */
main {
  flex: 1;
  padding: 56px 0 80px;
}

.step {
  display: none;
  animation: fadeIn 0.4s ease;
}
.step.active { display: block; }

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

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: 0.72rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--creme);
  margin-bottom: 18px;
}
.eyebrow::before { content: "§"; color: var(--gold); font-size: 1rem; line-height: 1; }

h1, h2 {
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.08;
  color: var(--creme);
}
h1 { font-size: clamp(2rem, 5vw, 2.8rem); margin-bottom: 16px; }
h2 { font-size: clamp(1.5rem, 3.5vw, 2rem); margin-bottom: 14px; }

.subtitle {
  color: var(--creme-soft);
  font-size: 1.05rem;
  max-width: 540px;
  margin-bottom: 40px;
}

/* ============ FORM ============ */
.form-grid {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.form-field { display: flex; flex-direction: column; gap: 10px; }

.form-label {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--creme);
}
.form-label .optional {
  text-transform: none;
  color: var(--creme-mute);
  font-weight: 400;
  letter-spacing: 0.04em;
}

.form-input,
.form-textarea {
  width: 100%;
  background: var(--bordeaux-deep);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 16px 18px;
  font-family: 'Archivo', sans-serif;
  font-size: 1rem;
  color: var(--creme);
  transition: border-color 0.2s ease, background 0.2s ease;
}
.form-input:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--gold);
  background: var(--bordeaux-ink);
}
.form-input::placeholder,
.form-textarea::placeholder {
  color: var(--creme-faint);
}
.form-textarea { resize: vertical; min-height: 110px; line-height: 1.5; }

.form-help {
  font-size: 0.85rem;
  color: var(--creme-mute);
}

/* ============ RADIO CARDS ============ */
.radio-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.radio-card {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--bordeaux-deep);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 16px 18px;
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease;
}
.radio-card:hover { border-color: var(--gold-soft); }
.radio-card input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.radio-card .radio-dot {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 1.5px solid var(--creme-mute);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 0.2s ease;
}
.radio-card .radio-dot::after {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--gold);
  opacity: 0;
  transition: opacity 0.2s ease;
}
.radio-card input[type="radio"]:checked ~ .radio-dot {
  border-color: var(--gold);
}
.radio-card input[type="radio"]:checked ~ .radio-dot::after { opacity: 1; }
.radio-card input[type="radio"]:checked ~ .radio-label { color: var(--creme); }
.radio-card:has(input:checked) {
  border-color: var(--gold);
  background: var(--bordeaux-ink);
}
.radio-label {
  color: var(--creme-soft);
  font-size: 1rem;
  line-height: 1.35;
}
.radio-label strong { color: var(--creme); font-weight: 600; }
.radio-label .hint {
  display: block;
  font-size: 0.85rem;
  color: var(--creme-mute);
  margin-top: 2px;
}

/* ============ BOTÕES ============ */
.nav-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 40px;
  gap: 16px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 28px;
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  border: none;
  cursor: pointer;
  text-decoration: none;
  border-radius: 999px;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, opacity 0.2s ease;
  min-height: 52px;
}
.btn-primary {
  background: var(--creme);
  color: var(--bordeaux);
}
.btn-primary::after {
  content: "→";
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px; height: 26px;
  border-radius: 50%;
  background: var(--bordeaux);
  color: var(--gold);
  font-size: 0.78rem;
}
.btn-primary:hover:not(:disabled) { background: #fff; transform: translateY(-1px); }
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-ghost {
  background: transparent;
  color: var(--creme-soft);
  border: 1px solid var(--line);
}
.btn-ghost:hover { color: var(--creme); border-color: var(--gold-soft); }

/* ============ MSG / TOAST ============ */
.msg-erro {
  color: var(--error);
  font-size: 0.95rem;
  margin-top: 12px;
  display: none;
}
.msg-erro.show { display: block; }

/* ============ FOOTER ============ */
.footer {
  padding: 24px 0;
  border-top: 1px solid var(--line);
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--creme-mute);
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.footer a { color: var(--creme-mute); text-decoration: none; }
.footer a:hover { color: var(--gold); }

/* ============ OBRIGADA ============ */
.obrigada-wrap { text-align: center; padding: 80px 0; }
.obrigada-wrap h1 { margin-bottom: 20px; }
.obrigada-wrap .subtitle { margin: 0 auto 32px; }
.obrigada-actions {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ============ MOBILE ============ */
@media (max-width: 540px) {
  .shell { padding: 0 20px; }
  main { padding: 40px 0 60px; }
  .header { padding: 20px 0; }
  .nav-row { flex-direction: column-reverse; gap: 12px; }
  .nav-row .btn { width: 100%; }
  .footer-inner { flex-direction: column; gap: 10px; text-align: center; }
}
