:root {
  --navy: #0f2557;
  --navy-2: #16306f;
  --orange: #f46134;
  --orange-dark: #e55124;
  --bg: #f8fafc;
  --card: #ffffff;
  --text: #1e293b;
  --muted: #475569;
  --line: #e2e8f0;
  --red: #e5484d;
  --yellow: #f5a623;
  --green: #2fa84f;
  --radius: 14px;
  --shadow: 0 10px 30px rgba(15, 37, 87, 0.08);
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

.bg {
  position: fixed;
  inset: 0;
  background:
    radial-gradient(600px 300px at 85% -5%, rgba(244, 97, 52, 0.10), transparent 60%),
    radial-gradient(700px 380px at 0% 0%, rgba(22, 48, 111, 0.10), transparent 60%),
    var(--bg);
  z-index: -1;
}

.container { max-width: 720px; margin: 0 auto; padding: 0 20px; }

.hidden { display: none !important; }

/* Header */
.site-header {
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 10;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 12px;
  padding-bottom: 12px;
}
.logo { display: flex; align-items: center; }
.header-link {
  font-size: 13px;
  color: var(--muted);
  text-decoration: none;
}
.header-link:hover { color: var(--orange); }

/* Hero */
.hero { text-align: center; padding-top: 64px; padding-bottom: 40px; }
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--navy);
  background: #eef2ff;
  border: 1px solid #dbe4ff;
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 22px;
}
.badge-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--orange);
  box-shadow: 0 0 0 4px rgba(244, 97, 52, 0.15);
}
.hero-title {
  font-size: 38px;
  line-height: 1.15;
  font-weight: 800;
  color: var(--navy);
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}
.hero-title .grad {
  background: linear-gradient(90deg, var(--orange), #f97316);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-sub {
  font-size: 17px;
  color: var(--muted);
  max-width: 620px;
  margin: 0 auto 30px;
}
.hero-sub strong { color: var(--navy); }
.btn {
  display: inline-block;
  border: none;
  cursor: pointer;
  font-family: inherit;
  font-weight: 700;
  font-size: 15px;
  border-radius: 10px;
  padding: 12px 22px;
  text-decoration: none;
  transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.12s ease;
}
.btn:active { transform: scale(0.98); }
.btn-primary {
  background: linear-gradient(90deg, var(--orange), var(--orange-dark));
  color: #fff;
  box-shadow: 0 8px 20px rgba(244, 97, 52, 0.28);
}
.btn-primary:hover { box-shadow: 0 10px 26px rgba(244, 97, 52, 0.36); }
.btn-ghost {
  background: #fff;
  color: var(--navy);
  border: 1px solid var(--line);
}
.btn-ghost:hover { border-color: var(--orange); color: var(--orange); }
.btn-lg { padding: 15px 32px; font-size: 16px; }
.btn-arrow { margin-left: 6px; }
.btn[disabled] { opacity: 0.6; cursor: default; }
.hero-trust {
  margin-top: 22px;
  font-size: 13px;
  color: var(--muted);
  display: flex;
  gap: 10px;
  justify-content: center;
  align-items: center;
}
.dot-sep { color: var(--line); }

/* Cards / form */
.form-wrap { padding-top: 24px; padding-bottom: 56px; }
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 32px;
}

/* Gate */
.gate-card { max-width: 480px; margin: 0 auto; }
.gate-title { font-size: 24px; font-weight: 800; color: var(--navy); margin-bottom: 6px; }
.gate-sub { font-size: 14px; color: var(--muted); margin-bottom: 22px; }
.gate-actions { margin-top: 18px; display: flex; }
.gate-actions .btn { width: 100%; }
.gate-error {
  margin-top: 14px;
  padding: 10px 14px;
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
  border-radius: 8px;
  font-size: 13px;
}

/* Fields */
.field { margin-bottom: 16px; }
.field label, .check-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 6px;
}
.req { color: var(--red); }
.field input, .field select {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 9px;
  font-size: 15px;
  font-family: inherit;
  color: var(--text);
  background: #fff;
}
.field input:focus, .field select:focus {
  outline: none;
  border-color: var(--orange);
  box-shadow: 0 0 0 3px rgba(244, 97, 52, 0.12);
}
.field input.error {
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(229, 72, 77, 0.12);
}
.checkbox-field {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin: 14px 0;
}
.checkbox-field input[type="checkbox"] {
  width: 17px; height: 17px;
  margin-top: 2px;
  accent-color: var(--orange);
}
.check-label { font-weight: 400; font-size: 13px; color: var(--muted); margin: 0; }
.check-label a, .consent-note a { color: var(--orange); }
.check-label a:hover, .consent-note a:hover { text-decoration: underline; }
.consent-note { font-size: 12px; color: #64748b; margin-top: 14px; }

/* Progress */
.progress-area { margin-bottom: 26px; }
.step-count { font-size: 13px; font-weight: 700; color: var(--orange); margin-bottom: 8px; }
.progress-track { height: 6px; background: #eef2ff; border-radius: 999px; overflow: hidden; }
.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--orange), var(--orange-dark));
  border-radius: 999px;
  transition: width 0.35s ease;
}
.step-label { margin-top: 8px; font-size: 13px; font-weight: 600; color: var(--navy); }

/* Questions */
.dim-intro {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 14px 16px;
  margin-bottom: 24px;
  font-size: 14px;
  color: var(--muted);
}
.dim-icon { font-size: 20px; }
.q-group { margin-bottom: 26px; }
.q-text {
  font-size: 16px;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 12px;
}
.q-options { display: flex; flex-direction: column; gap: 8px; }
.q-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 9px;
  cursor: pointer;
  transition: border-color 0.12s, background 0.12s;
}
.q-option:hover { border-color: var(--orange); }
.q-option.selected {
  border-color: var(--orange);
  background: #fff7ed;
}
.q-option input { accent-color: var(--orange); width: 16px; height: 16px; }
.opt-label { font-size: 14px; color: var(--text); }

/* Nav buttons */
.form-nav {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 28px;
}
.error-banner {
  margin-bottom: 16px;
  padding: 12px 16px;
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
  border-radius: 8px;
  font-size: 14px;
}

/* Loading */
.loading-card { text-align: center; padding: 64px 32px; }
.loading-card h2 { font-size: 22px; color: var(--navy); margin: 20px 0 6px; }
.loading-card p { color: var(--muted); font-size: 14px; }
.spinner {
  width: 44px; height: 44px;
  margin: 0 auto;
  border: 4px solid #eef2ff;
  border-top-color: var(--orange);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Result */
.result-card { padding: 36px; }
.result-top {
  display: flex;
  gap: 28px;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 28px;
}
.score-ring {
  width: 150px; height: 150px;
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: conic-gradient(var(--orange) 0deg, #e6efff 0deg);
  flex-shrink: 0;
}
.score-ring::before {
  content: '';
  position: absolute;
  width: 120px; height: 120px;
  border-radius: 50%;
  background: #fff;
}
.score-num { font-size: 42px; font-weight: 800; color: var(--orange); z-index: 1; line-height: 1; }
.score-label { font-size: 13px; color: var(--muted); z-index: 1; margin-top: 2px; }
.result-headline { flex: 1; min-width: 260px; }
.result-band {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 999px;
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.band-overflow { background: #fee2e2; color: #b91c1c; }
.band-leaking { background: #fef3c7; color: #b45309; }
.band-machine { background: #dcfce7; color: #15803d; }
.result-headline h2 { font-size: 22px; font-weight: 800; color: var(--navy); margin-bottom: 6px; }
.result-headline p { font-size: 14px; color: var(--muted); }

.dims { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; margin-bottom: 22px; }
.dim-card {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 14px;
  text-align: center;
}
.dim-name { font-size: 13px; font-weight: 600; color: var(--muted); }
.dim-value { font-size: 28px; font-weight: 800; }
.dim-bar { height: 6px; background: #eef2ff; border-radius: 999px; overflow: hidden; margin-top: 6px; }
.dim-bar-fill { height: 100%; border-radius: 999px; }

.goal-box {
  background: #e6efff;
  border-radius: 10px;
  padding: 14px 18px;
  margin-bottom: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}
.goal-box strong { font-size: 14px; color: var(--navy); }

.payoff-box {
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-radius: 10px;
  padding: 12px 16px;
  margin-bottom: 20px;
  font-size: 14px;
  color: #7c2d12;
}

.section-title { font-size: 17px; font-weight: 800; color: var(--navy); margin: 22px 0 12px; }
.rec-card {
  border: 1px solid var(--line);
  border-left: 4px solid var(--orange);
  border-radius: 10px;
  padding: 16px 18px;
  margin-bottom: 14px;
}
.rec-quick { border-left-color: var(--green); background: #f0fdf4; }
.rec-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.rec-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px; height: 24px;
  background: var(--orange);
  color: #fff;
  border-radius: 7px;
  font-size: 13px;
  font-weight: 800;
  flex-shrink: 0;
}
.rec-quick .rec-num { background: var(--green); }
.rec-line { font-size: 13px; color: #444; line-height: 1.55; margin-bottom: 4px; }
.rec-line strong { color: var(--orange); }
.rec-quick .rec-line strong { color: var(--green); }

.cta-box {
  margin-top: 26px;
  background: linear-gradient(135deg, var(--navy), var(--navy-2));
  border-radius: 12px;
  padding: 26px;
  text-align: center;
  color: #fff;
}
.cta-box h3 { font-size: 20px; font-weight: 800; margin-bottom: 8px; }
.cta-box p { font-size: 14px; color: #cbd5e1; margin-bottom: 20px; }
.cta-note { margin-top: 12px; font-size: 12px; color: #94a3b8; }

/* Footer */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 22px 0;
  margin-top: 12px;
}
.footer-inner {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--muted);
}
.footer-inner a { color: var(--muted); }
.footer-inner a:hover { color: var(--orange); }

/* Embed mode (sem header/footer/hero-extra) */
body.embed .site-header { display: none; }
body.embed .site-footer { display: none; }
body.embed .hero { padding-top: 28px; }
body.embed .hero-badge { margin-bottom: 14px; }

@media (max-width: 560px) {
  .hero-title { font-size: 30px; }
  .card { padding: 24px; }
  .result-card { padding: 24px; }
  .dims { grid-template-columns: 1fr; }
  .result-top { flex-direction: column; text-align: center; }
  .score-ring { margin: 0 auto; }
}