:root {
  --navy-950: #11182f;
  --navy-900: #17213f;
  --navy-800: #21305a;
  --navy-700: #304474;
  --green-700: #075f23;
  --green-600: #0b7130;
  --green-100: #dcf7e2;
  --ink: #17213f;
  --muted: #59647b;
  --surface: #ffffff;
  --surface-soft: #f5f7fb;
  --line: #dce2ec;
  --danger: #b42318;
  --danger-soft: #fff1f0;
  --focus: #2f66d0;
  --shadow: 0 22px 60px rgba(17, 24, 47, .14);
  --radius: 14px;
}

* { box-sizing: border-box; }
html { min-height: 100%; scroll-behavior: smooth; }

body {
  min-height: 100%;
  margin: 0;
  background: var(--surface-soft);
  color: var(--ink);
  font-family: "Figtree", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.5;
}

::selection { background: var(--green-100); color: var(--navy-950); }
button, input, select, textarea { font: inherit; }
button, label, select { -webkit-tap-highlight-color: transparent; }

.skip-link {
  position: absolute;
  z-index: 50;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
  border-radius: 10px;
  background: var(--navy-950);
  color: #fff;
}

.skip-link:focus {
  position: fixed;
  top: 12px;
  left: 12px;
  width: auto;
  height: auto;
  padding: 10px 14px;
  margin: 0;
  overflow: visible;
  clip: auto;
  white-space: normal;
}

.page-shell {
  width: min(1100px, calc(100% - 40px));
  margin: 0 auto;
  padding: 30px 0 40px;
}

.brand-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  min-height: 84px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--line);
}

.brand-logo {
  display: block;
  width: 236px;
  height: auto;
}

.brand-bar p {
  max-width: 360px;
  margin: 0;
  color: var(--muted);
  font-size: .94rem;
  text-align: right;
}

.intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, .7fr);
  gap: clamp(32px, 6vw, 74px);
  align-items: end;
  padding: clamp(48px, 8vw, 86px) 0 44px;
}

.intro h1 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(2.35rem, 5vw, 4.6rem);
  line-height: .98;
  letter-spacing: -.035em;
  text-wrap: balance;
}

.intro-copy > p {
  max-width: 650px;
  margin: 24px 0 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.8vw, 1.16rem);
  line-height: 1.65;
}

.trust-note {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  max-width: 610px;
  margin-top: 24px;
  color: var(--navy-700);
  font-size: .92rem;
}

.trust-note svg { flex: 0 0 auto; fill: var(--green-600); }

.progress-steps {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.progress-steps li {
  position: relative;
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 13px;
  align-items: center;
  min-height: 64px;
  color: #667085;
}

.progress-steps li:not(:last-child)::after {
  position: absolute;
  top: 44px;
  bottom: -4px;
  left: 19px;
  width: 2px;
  background: var(--line);
  content: "";
}

.progress-steps span {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border: 2px solid var(--line);
  border-radius: 50%;
  background: var(--surface-soft);
  font-weight: 800;
}

.progress-steps strong { font-size: .95rem; }
.progress-steps .is-current,
.progress-steps .is-complete { color: var(--navy-900); }

.progress-steps .is-current span {
  border-color: var(--green-600);
  background: var(--green-600);
  color: #fff;
}

.progress-steps .is-complete span {
  border-color: var(--green-600);
  background: var(--green-100);
  color: var(--green-700);
}

.progress-steps li.is-complete:not(:last-child)::after { background: var(--green-600); }

.form-shell {
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.form-step {
  display: none;
  min-height: 520px;
  padding: clamp(28px, 5vw, 58px);
}

.form-step.is-active { display: block; animation: step-enter .38s cubic-bezier(.16, 1, .3, 1); }

@keyframes step-enter {
  from { opacity: .01; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.step-heading { margin-bottom: 34px; }

.step-heading p {
  margin: 0 0 10px;
  color: var(--green-700);
  font-size: .86rem;
  font-weight: 800;
}

.step-heading h2 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(1.7rem, 3vw, 2.35rem);
  line-height: 1.15;
  letter-spacing: -.025em;
  text-wrap: balance;
}

.step-heading > span {
  display: block;
  max-width: 680px;
  margin-top: 10px;
  color: var(--muted);
}

.fields-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}

.compact-grid { margin-top: 30px; }
.field-wide { grid-column: 1 / -1; }
.field { display: grid; align-content: start; gap: 8px; }

.field > span {
  color: var(--navy-900);
  font-size: .94rem;
  font-weight: 700;
}

.field em {
  margin-left: 4px;
  color: var(--muted);
  font-size: .8rem;
  font-style: normal;
  font-weight: 500;
}

input, select, textarea {
  width: 100%;
  border: 1px solid #c7cfdd;
  border-radius: 12px;
  outline: none;
  background: #fff;
  color: var(--ink);
  caret-color: var(--green-600);
  transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
}

input, select { min-height: 54px; padding: 0 15px; }
textarea { min-height: 160px; padding: 14px 15px; line-height: 1.55; resize: vertical; }
input::placeholder, textarea::placeholder { color: #667085; opacity: 1; }
input:hover, select:hover, textarea:hover { border-color: #8e9ab0; }

input:focus-visible, select:focus-visible, textarea:focus-visible {
  border-color: var(--focus);
  box-shadow: 0 0 0 4px rgba(47, 102, 208, .16);
}

[aria-invalid="true"] {
  border-color: var(--danger);
  background: var(--danger-soft);
}

.field-help, .field-error, .field-meta small {
  min-height: 18px;
  font-size: .8rem;
  line-height: 1.35;
}

.field-help { color: var(--muted); }
.field-error { color: var(--danger); }
.field-meta { display: flex; justify-content: space-between; gap: 16px; color: var(--muted); }
.field-meta .field-error { flex: 1; }
.choice-fieldset { margin: 0; padding: 0; border: 0; }

.choice-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.choice-card {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 70px;
  padding: 16px 16px 16px 48px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--navy-800);
  cursor: pointer;
  font-weight: 700;
  transition: border-color .18s ease, background .18s ease, transform .18s ease;
}

.choice-card:hover { border-color: var(--green-600); transform: translateY(-1px); }

.choice-card input {
  position: absolute;
  left: 16px;
  width: 19px;
  min-height: 19px;
  height: 19px;
  padding: 0;
  accent-color: var(--green-600);
}

.choice-card:has(input:checked) {
  border-color: var(--green-600);
  background: var(--green-100);
  color: var(--navy-950);
}

.choice-card:has(input:focus-visible) { box-shadow: 0 0 0 4px rgba(47, 102, 208, .16); }

.form-actions {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  margin-top: 38px;
}

.form-actions-end { justify-content: flex-end; }

.button {
  min-height: 50px;
  min-width: 140px;
  border: 0;
  border-radius: 999px;
  padding: 0 24px;
  cursor: pointer;
  font-weight: 800;
  transition: transform .18s ease, background .18s ease, box-shadow .18s ease, opacity .18s ease;
}

.button:hover:not(:disabled) { transform: translateY(-1px); }
.button:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }

.button-primary {
  background: var(--green-600);
  color: #fff;
  box-shadow: 0 10px 24px rgba(29, 168, 62, .22);
}

.button-primary:hover:not(:disabled) { background: var(--green-700); }
.button-secondary { border: 1px solid var(--line); background: #fff; color: var(--navy-800); }
.button-secondary:hover:not(:disabled) { background: var(--surface-soft); }
.button:disabled { cursor: wait; opacity: .62; transform: none; box-shadow: none; }

.consent {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin-top: 28px;
  cursor: pointer;
}

.consent input {
  flex: 0 0 auto;
  width: 21px;
  min-height: 21px;
  height: 21px;
  margin-top: 2px;
  padding: 0;
  accent-color: var(--green-600);
}

.consent span { max-width: 800px; color: var(--muted); font-size: .92rem; }
.consent-error { display: block; margin: 6px 0 0 33px; }

.form-alert {
  margin: 28px clamp(28px, 5vw, 58px) 0;
  padding: 14px 16px;
  border-radius: 12px;
  background: var(--danger-soft);
  color: var(--danger);
  font-weight: 700;
}

.success-state {
  min-height: 520px;
  padding: clamp(48px, 9vw, 96px);
  text-align: center;
}

.success-state[hidden], .form-alert[hidden] { display: none; }

.success-icon {
  display: grid;
  width: 72px;
  height: 72px;
  margin: 0 auto 24px;
  place-items: center;
  border-radius: 50%;
  background: var(--green-100);
}

.success-icon svg { fill: var(--green-700); }
.success-state h2 { margin: 0; font-size: clamp(2rem, 4vw, 3.2rem); letter-spacing: -.03em; }
.success-state p { max-width: 620px; margin: 18px auto 0; color: var(--muted); font-size: 1.08rem; }

.hp-field {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

footer {
  display: flex;
  justify-content: space-between;
  gap: 28px;
  padding: 28px 4px 0;
  color: var(--muted);
  font-size: .82rem;
}

footer p { margin: 0; }

@media (max-width: 840px) {
  .intro { grid-template-columns: 1fr; padding-top: 52px; }
  .progress-steps { grid-template-columns: repeat(3, 1fr); }
  .progress-steps li { grid-template-columns: 36px 1fr; min-height: 52px; font-size: .86rem; }
  .progress-steps span { width: 36px; height: 36px; }
  .progress-steps li:not(:last-child)::after {
    top: 18px;
    right: -4px;
    bottom: auto;
    left: 36px;
    width: calc(100% - 28px);
    height: 2px;
  }
  .choice-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 620px) {
  .page-shell { width: min(100% - 24px, 1100px); padding-top: 16px; }
  .brand-bar { align-items: flex-start; padding-bottom: 16px; }
  .brand-logo { width: 190px; }
  .brand-bar p { display: none; }
  .intro { gap: 32px; padding: 42px 0 32px; }
  .intro h1 { font-size: clamp(2.35rem, 12vw, 3.35rem); }
  .progress-steps li {
    display: grid;
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 6px;
    text-align: center;
  }
  .progress-steps strong { font-size: .74rem; white-space: nowrap; }
  .progress-steps li:not(:last-child)::after {
    left: calc(50% + 18px);
    width: calc(100% - 36px);
  }
  .form-step { min-height: 0; padding: 26px 20px 30px; }
  .form-alert { margin: 20px 20px 0; }
  .fields-grid, .choice-grid { grid-template-columns: 1fr; }
  .field-wide { grid-column: auto; }
  .compact-grid { margin-top: 24px; }
  .form-actions { margin-top: 30px; }
  .button { min-width: 0; }
  .form-actions .button-primary { flex: 1; }
  .success-state { min-height: 440px; padding: 64px 24px; }
  footer { flex-direction: column; gap: 8px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
