/* Quotavo landing pages — shared styles. Mobile first. */
:root {
  --purple: #7138D4;
  --purple-deep: #5A28B8;
  --purple-tint: #F1EBFC;
  --teal: #20B8A6;
  --teal-bright: #2EE0C6;
  --teal-tint: #E3F7F4;
  --navy: #111A3A;
  --navy-deep: #0C1330;
  --lightblue: #67B7FF;
  --blue-tint: #E8F3FF;
  --bg: #F5F7FF;
  --white: #FFFFFF;
  --text: #1A1F36;
  --muted: #5F6682;
  --line: #DCE1F0;
  --field: #F8F9FE;
  --error: #C8344B;
  --on-dark: #C5CCEB;
  --display: 'Outfit', 'Montserrat', system-ui, sans-serif;
  --body: 'Montserrat', system-ui, sans-serif;
  --ring: 0 0 0 4px rgba(113, 56, 212, 0.16);
  --steps: 2;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: env(safe-area-inset-top, 0px); }
body {
  margin: 0;
  font-family: var(--body);
  font-size: 15px;
  line-height: 1.55;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
a { color: inherit; }
:focus-visible { outline: 3px solid var(--purple); outline-offset: 3px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  color: var(--white);
  background:
    radial-gradient(120% 70% at 100% 0%, rgba(113, 56, 212, 0.55) 0%, rgba(113, 56, 212, 0) 60%),
    radial-gradient(90% 60% at 0% 100%, rgba(61, 92, 232, 0.28) 0%, rgba(61, 92, 232, 0) 65%),
    var(--navy-deep);
  padding: env(safe-area-inset-top, 0px) 16px 36px;
}
/* The Q mark, enlarged and faint, anchored to the top-right */
.hero::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: -70px;
  right: -150px;
  width: 400px;
  aspect-ratio: 560 / 510;
  opacity: 0.1;
  pointer-events: none;
  background: no-repeat center / contain url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-10 -10 560 510'%3E%3Cdefs%3E%3ClinearGradient id='r' gradientUnits='userSpaceOnUse' x1='40' y1='0' x2='300' y2='490'%3E%3Cstop offset='0' stop-color='%23A565F8'/%3E%3Cstop offset='.5' stop-color='%237138D4'/%3E%3Cstop offset='1' stop-color='%233D5CE8'/%3E%3C/linearGradient%3E%3ClinearGradient id='t' gradientUnits='userSpaceOnUse' x1='214' y1='248' x2='540' y2='465'%3E%3Cstop offset='0' stop-color='%2334EBCB'/%3E%3Cstop offset='1' stop-color='%2314AE9B'/%3E%3C/linearGradient%3E%3Cmask id='m' maskUnits='userSpaceOnUse' x='-50' y='-50' width='800' height='800'%3E%3Crect x='-50' y='-50' width='800' height='800' fill='%23fff'/%3E%3Cpath d='M213 248L354 248L710 620L569 620Z'/%3E%3C/mask%3E%3C/defs%3E%3Cpath fill='url(%23r)' fill-rule='evenodd' mask='url(%23m)' d='M0 245a245 245 0 1 0 490 0a245 245 0 1 0-490 0ZM105 245a140 140 0 1 1 280 0a140 140 0 1 1-280 0Z'/%3E%3Cpath fill='url(%23t)' d='M214 248L332 248L540 465L422 465Z'/%3E%3C/svg%3E");
}
.hero-inner { max-width: 1120px; margin: 0 auto; padding-top: 20px; }

a.brandrow { display: inline-flex; align-items: center; text-decoration: none; margin-bottom: 28px; }
.brand-logo { height: 32px; width: auto; display: block; }

.hero-grid { display: grid; grid-template-columns: 1fr; gap: 28px; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--teal-bright);
  margin-bottom: 16px;
}
.eyebrow::before {
  content: "";
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: var(--teal-bright);
}

h1 {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(33px, 9vw, 58px);
  line-height: 1.04;
  letter-spacing: -0.025em;
  margin: 0 0 16px;
  text-wrap: balance;
}
h1 .accent { color: var(--teal-bright); }
.p-estimate h1 .accent,
.p-fe h1 .accent { display: block; }

.hero p.sub {
  font-size: 15.5px;
  line-height: 1.6;
  color: var(--on-dark);
  max-width: 34em;
  margin: 0 0 20px;
}

.trust-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  font-size: 13px;
  font-weight: 600;
  color: #E4E8F8;
}
.trust-badges > span { display: inline-flex; align-items: center; gap: 8px; }
.dot {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: rgba(46, 224, 198, 0.16) no-repeat center / 11px url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232EE0C6' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 12.5L9.5 18L20 6'/%3E%3C/svg%3E");
}

/* ---------- Form card ---------- */
.card {
  position: relative;
  background: var(--white);
  color: var(--text);
  border-radius: 20px;
  padding: 24px 20px 22px;
  box-shadow:
    0 1px 2px rgba(12, 19, 48, 0.08),
    0 12px 28px -8px rgba(12, 19, 48, 0.28),
    0 40px 80px -24px rgba(12, 19, 48, 0.45);
  animation: cardIn 0.6s cubic-bezier(0.2, 0.8, 0.2, 1) both 0.1s;
}
@keyframes cardIn { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

.card h2 {
  font-family: var(--display);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.15;
  color: var(--navy);
  margin: 0 0 4px;
}
.card .card-sub { font-size: 14px; color: var(--muted); margin-bottom: 20px; line-height: 1.5; }

label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--navy);
  margin: 16px 0 7px;
}
label:first-of-type { margin-top: 0; }
.row2 label,
.row2 + label,
.check-group + label { margin-top: 16px; }
.step-sub + label,
.step-sub + .row2 label { margin-top: 0; }

input, select {
  display: block;
  width: 100%;
  min-height: 52px;
  padding: 13px 15px;
  border-radius: 12px;
  border: 1.5px solid var(--line);
  background: var(--field);
  font-family: var(--body);
  font-size: 16px; /* 16px stops iOS from zooming on focus */
  font-weight: 500;
  color: var(--text);
  -webkit-appearance: none;
  appearance: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}
input::placeholder { color: #9AA0B8; opacity: 1; }
input:hover, select:hover { border-color: #C3CAE2; }
input:focus, select:focus { outline: none; border-color: var(--purple); background: var(--white); box-shadow: var(--ring); }
input:user-invalid, select:user-invalid { border-color: var(--error); }
input[type="number"] { -moz-appearance: textfield; }
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
input[type="date"] { text-align: left; }
input[type="date"]::-webkit-date-and-time-value { text-align: left; }

select {
  padding-right: 42px;
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237138D4' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 18px;
}
select:invalid { color: #9AA0B8; }
select option { color: var(--text); }

.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.row2 > div { min-width: 0; }
/* On phones, phone + email each get a full row so the email is fully visible while typing */
@media (max-width: 559px) {
  .row2:has(#email) { grid-template-columns: 1fr; gap: 0; }
}

/* Custom checkboxes */
input[type="checkbox"] {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  min-height: 0;
  padding: 0;
  margin: 0;
  border-radius: 7px;
  border: 1.5px solid #B9C0DA;
  background: var(--white) no-repeat center / 14px;
  cursor: pointer;
}
input[type="checkbox"]:checked {
  border-color: var(--purple);
  background-color: var(--purple);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 12.5L9.5 18L20 6'/%3E%3C/svg%3E");
}

.consent {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin-top: 20px;
  padding: 14px;
  border-radius: 12px;
  background: var(--bg);
}
.consent input { margin-top: 1px; }
.consent p { margin: 0; font-size: 12px; line-height: 1.55; color: var(--muted); }

/* Primary action */
.submit-btn, .btn-next {
  display: block;
  width: 100%;
  min-height: 56px;
  margin-top: 20px;
  padding: 16px 20px;
  border: 0;
  border-radius: 14px;
  background: linear-gradient(180deg, #7B44DC 0%, var(--purple) 55%, var(--purple-deep) 100%);
  color: var(--white);
  font-family: var(--display);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.005em;
  cursor: pointer;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.22) inset, 0 10px 22px -8px rgba(113, 56, 212, 0.7);
  transition: transform 0.12s ease, box-shadow 0.15s ease, filter 0.15s ease;
  -webkit-tap-highlight-color: transparent;
}
.submit-btn:hover, .btn-next:hover { filter: brightness(1.06); box-shadow: 0 1px 0 rgba(255,255,255,0.22) inset, 0 14px 28px -8px rgba(113, 56, 212, 0.75); }
.submit-btn:active, .btn-next:active { transform: translateY(1px) scale(0.995); }
.submit-btn:disabled { opacity: 0.6; cursor: not-allowed; }

.form-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  margin-top: 12px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--muted);
  text-align: center;
}
.form-note::before {
  content: "";
  flex-shrink: 0;
  width: 13px;
  height: 13px;
  background: no-repeat center / contain url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2320B8A6' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='4' y='10.5' width='16' height='11' rx='2.5'/%3E%3Cpath d='M8 10.5V7a4 4 0 0 1 8 0v3.5'/%3E%3C/svg%3E");
}

/* Inline success state (kept for completeness; forms redirect to /thank-you/) */
.success { display: none; text-align: center; padding: 24px 8px; }
.success .check {
  width: 60px; height: 60px; border-radius: 50%;
  background: var(--teal);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 18px;
  box-shadow: 0 0 0 8px var(--teal-tint);
}
.success h2 { color: var(--navy); }
.success p { color: var(--muted); font-size: 15px; line-height: 1.6; }

/* ---------- Multi-step forms (/match/, /personalized/) ---------- */
.hero-text { max-width: 640px; }
.p-steps .hero { padding-bottom: 76px; }
.form-wrap { position: relative; max-width: 580px; margin: -48px auto 0; padding: 0 16px 48px; }

.progress-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 10px; }
.progress-head .step-label { font-size: 13px; font-weight: 700; color: var(--purple); }
.progress-head .step-count { font-size: 12.5px; font-weight: 500; color: var(--muted); font-variant-numeric: tabular-nums; }
.progress-track {
  position: relative;
  height: 6px;
  border-radius: 6px;
  background: #E6E9F5;
  overflow: hidden;
  margin-bottom: 26px;
}
/* white gaps split the bar into one segment per step */
.progress-track::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(90deg,
    transparent 0 calc(100% / var(--steps) - 4px),
    var(--white) calc(100% / var(--steps) - 4px) calc(100% / var(--steps)));
  pointer-events: none;
}
.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--purple) 0%, var(--teal) 100%);
  transition: width 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.step { display: none; }
.step.active { display: block; animation: stepIn 0.35s cubic-bezier(0.2, 0.8, 0.2, 1); }
@keyframes stepIn { from { opacity: 0; transform: translateX(14px); } to { opacity: 1; transform: none; } }
.step-title {
  font-family: var(--display);
  font-size: 23px;
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.2;
  color: var(--navy);
  margin: 0 0 4px;
}
.step-sub { font-size: 14px; color: var(--muted); margin-bottom: 20px; }

.check-group { display: grid; grid-template-columns: 1fr; gap: 8px; margin-top: 2px; }
label.check-item {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 52px;
  margin: 0;
  padding: 12px 14px;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  background: var(--field);
  font-size: 15px;
  font-weight: 500;
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}
label.check-item:has(input:checked) { border-color: var(--purple); background: var(--purple-tint); }

.conditional { display: none; margin-top: 16px; }
.conditional.show { display: block; }
.conditional label { margin-top: 0; }

.nav-row { display: flex; gap: 10px; margin-top: 22px; }
.nav-row .btn { margin-top: 0; }
.btn { font-family: var(--display); cursor: pointer; }
.btn-next { flex: 1; }
.btn-back {
  flex: 0 0 auto;
  min-height: 56px;
  padding: 0 20px;
  border: 1.5px solid var(--line);
  border-radius: 14px;
  background: var(--white);
  color: var(--navy);
  font-size: 16px;
  font-weight: 600;
}
.btn-back:hover { border-color: #C3CAE2; background: var(--bg); }

/* ---------- Benefits ---------- */
.benefits {
  max-width: 1120px;
  margin: 0 auto;
  padding: 36px 16px 20px;
  display: grid;
  grid-template-columns: 1fr;
}
.benefit {
  display: grid;
  grid-template-columns: 44px 1fr;
  column-gap: 16px;
  align-items: start;
  padding: 18px 0;
  border-top: 1px solid var(--line);
}
.benefit:first-child { border-top: 0; }
.benefit .icon-circle {
  grid-row: span 2;
  width: 44px;
  height: 44px;
  border-radius: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.benefit .icon-circle svg { width: 21px; height: 21px; }
.benefit .icon-circle svg * { stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; }
.ic-purple { background: var(--purple-tint); color: var(--purple); }
.ic-teal { background: var(--teal-tint); color: #128B7D; }
.ic-blue { background: var(--blue-tint); color: #2F86D9; }
.ic-indigo { background: #E9ECFC; color: #3D5CE8; }
.benefit h3 {
  font-family: var(--display);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.25;
  color: var(--navy);
  margin: 1px 0 4px;
}
.benefit p { font-size: 14px; color: var(--muted); margin: 0; line-height: 1.55; }

/* ---------- Footer ---------- */
footer {
  max-width: 1120px;
  margin: 0 auto;
  padding: 24px 16px 40px;
  font-size: 12px;
  line-height: 1.7;
  color: var(--muted);
  text-align: center;
}
.p-premium footer { padding-top: 0; }
.form-wrap + .benefits { padding-top: 0; }

/* ---------- Larger screens ---------- */
@media (min-width: 560px) {
  .card { padding: 32px 30px 28px; border-radius: 24px; }
  .check-group { grid-template-columns: 1fr 1fr; }
  .brand-logo { height: 38px; }
}

@media (min-width: 900px) {
  .hero { padding: 0 32px 72px; }
  .hero::before { width: 760px; top: -120px; right: -170px; opacity: 0.16; }
  .hero-inner { padding-top: 32px; }
  a.brandrow { margin-bottom: 56px; }
  .hero-grid { grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr); gap: 64px; align-items: center; }
  .eyebrow { font-size: 12px; margin-bottom: 20px; }
  h1 { margin-bottom: 20px; }
  .hero p.sub { font-size: 18px; margin-bottom: 28px; }
  .trust-badges { font-size: 14px; gap: 12px 24px; }
  .card { margin-bottom: -24px; }

  .p-steps .hero { padding-bottom: 120px; }
  .p-steps .hero::before { right: -240px; }
  .p-steps .hero-text { max-width: 760px; margin: 0 auto; text-align: center; }
  .p-steps .trust-badges { justify-content: center; }
  .p-steps h1 { font-size: 50px; }
  .p-steps .hero p.sub { margin-left: auto; margin-right: auto; }
  .form-wrap { margin-top: -72px; padding-bottom: 64px; }

  .benefits {
    padding: 72px 32px 40px;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
  }
  .benefit { grid-template-columns: 1fr; padding: 0; border-top: 0; }
  .benefit .icon-circle { grid-row: auto; margin-bottom: 16px; }
  footer { padding: 32px 32px 48px; border-top: 1px solid var(--line); }
  .p-premium footer { border-top: 0; }
  .form-wrap + .benefits { padding-top: 16px; }
}

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