/* CompareRatesHQ auto lander — lightweight, mobile-first (replaces Bootstrap + jQuery) */
:root {
  --navy: #0f2744;
  --ink: #1b2430;
  --muted: #5b6676;
  --blue: #1d4ed8;
  --blue-dark: #1e40af;
  --accent: #e11d48;
  --green: #16a34a;
  --green-dark: #15803d;
  --gold: #f5b301;
  --bg: #f2f5fa;
  --card: #ffffff;
  --line: #dde3ec;
  --radius: 16px;
  --shadow: 0 6px 24px rgba(15, 39, 68, .08);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

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

img { max-width: 100%; height: auto; }

a { color: var(--blue); }

.wrap { max-width: 640px; margin: 0 auto; padding: 0 16px; }

/* top trust bar */
.topbar {
  background: var(--navy);
  color: #fff;
  text-align: center;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .01em;
  padding: 8px 12px;
}
.topbar .stars { color: var(--gold); letter-spacing: 2px; margin-right: 6px; }

/* hero + quiz */
.hero { text-align: center; padding: 18px 0 6px; }

h1 {
  margin: 0 0 10px;
  font-size: clamp(26px, 7.2vw, 38px);
  line-height: 1.12;
  letter-spacing: -.02em;
  font-weight: 800;
  color: var(--navy);
}
h1 .hl { color: var(--accent); }

.lead { margin: 0 auto 16px; max-width: 30em; color: var(--muted); font-size: 16px; }
.lead strong { color: var(--ink); }

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px 16px;
  text-align: center;
}

#quiz { min-height: 292px; display: flex; flex-direction: column; justify-content: center; }
.question { display: none; }
.question.active { display: block; animation: rise .35s ease both; }

.question h2 {
  margin: 0 0 16px;
  font-size: 20px;
  line-height: 1.25;
  font-weight: 800;
  color: var(--navy);
}

.answers { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.answer {
  appearance: none;
  -webkit-appearance: none;
  min-height: 54px;
  padding: 10px 8px;
  border: 2px solid var(--green);
  border-radius: 12px;
  background: #fff;
  color: var(--navy);
  font: inherit;
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
  transition: background .15s, color .15s, transform .1s;
  -webkit-tap-highlight-color: transparent;
}
.answer:active { transform: scale(.98); }
.answer:hover, .answer:focus-visible { background: var(--green); color: #fff; outline: none; }
.answer.alt { border-color: var(--line); color: var(--muted); }
.answer.alt:hover, .answer.alt:focus-visible { background: var(--muted); border-color: var(--muted); color: #fff; }

/* testimonials */
.reviews { padding: 28px 0 8px; }
.review {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 12px;
}
.review img { width: 56px; height: 56px; flex: none; border-radius: 50%; object-fit: cover; }
.review p { margin: 0 0 6px; font-style: italic; font-size: 15px; }
.review p strong { font-style: normal; }
.review .stars { color: var(--gold); letter-spacing: 2px; font-size: 15px; line-height: 1; margin-bottom: 4px; }
.review .who { font-weight: 700; font-size: 14px; color: var(--navy); }

/* call button */
.cta {
  display: block;
  width: 100%;
  margin: 14px 0 0;
  padding: 18px 12px;
  border-radius: 14px;
  background: linear-gradient(180deg, var(--green), var(--green-dark));
  color: #fff;
  text-decoration: none;
  text-align: center;
  font-size: 20px;
  font-weight: 800;
  box-shadow: 0 8px 20px rgba(22, 163, 74, .35);
  animation: pulse 2.2s ease-in-out infinite;
}
.cta:active { transform: scale(.99); }

.timer { margin: 14px 0 4px; font-size: 16px; font-weight: 700; color: var(--navy); }
.timer b { color: var(--accent); font-variant-numeric: tabular-nums; }
.fine { margin: 0; font-size: 12px; color: var(--muted); }

/* thank-you steps */
.step { display: none; text-align: center; padding: 8px 0; }
.step.active { display: block; animation: rise .3s ease both; }
.step h3 { margin: 0; font-size: 18px; color: var(--navy); }
.step .ico { font-size: 26px; margin-right: 6px; vertical-align: -3px; }
.result { display: none; }
.result.active { display: block; animation: rise .4s ease both; }
.result h2 { margin: 0 0 8px; font-size: 24px; color: var(--green-dark); }
.result p.msg { margin: 0; font-size: 17px; font-weight: 600; }
.result .hl { color: var(--accent); }

.bottom-cta {
  margin: 8px 0 28px;
  padding: 22px 16px 20px;
  border-radius: var(--radius);
  background: var(--navy);
  color: #fff;
  text-align: center;
}
.bottom-cta h2 { margin: 0 0 4px; font-size: 20px; }
.bottom-cta p { margin: 0; color: #c9d6e8; font-size: 15px; }
.bottom-cta .timer { color: #fff; }
.bottom-cta .timer b { color: var(--gold); }

/* footer */
footer { background: #0b1a2f; color: #c9d6e8; padding: 24px 0 28px; text-align: center; font-size: 12.5px; }
footer nav { margin-bottom: 14px; font-size: 14px; }
footer nav a { color: #fff; margin: 0 10px; }
footer p { margin: 0 auto 10px; max-width: 640px; line-height: 1.55; }

/* legal pages */
.legal { padding-top: 24px; padding-bottom: 36px; }
.legal h1 { font-size: 28px; text-align: center; }
.legal h2 { font-size: 20px; margin: 28px 0 8px; color: var(--navy); }
.legal h3 { font-size: 16px; margin: 18px 0 6px; color: var(--navy); }
.legal p, .legal li { font-size: 15px; }
.legal .updated { text-align: center; color: var(--muted); font-size: 14px; margin-bottom: 20px; }
.legal .highlight-box { background: #fff7e6; border: 1px solid #f3d9a4; border-radius: 12px; padding: 12px 16px; margin: 16px 0; }

@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes pulse {
  0%, 100% { box-shadow: 0 8px 20px rgba(22, 163, 74, .35), 0 0 0 0 rgba(22, 163, 74, .35); }
  50% { box-shadow: 0 8px 20px rgba(22, 163, 74, .35), 0 0 0 10px rgba(22, 163, 74, 0); }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}

@media (min-width: 560px) {
  .card { padding: 28px 28px; }
  .question h2 { font-size: 23px; }
}
