/* Vertex Resolution — calm, trustworthy, mobile-first. */

:root {
  --bg: #f4f7f9;
  --surface: #ffffff;
  --ink: #1c2b3a;
  --ink-soft: #46586b;
  --ink-faint: #5d6e81; /* 4.86:1 on --bg, 5.23:1 on white — AA for normal text */
  --brand: #14507b;
  --brand-dark: #0e3c5e;
  --brand-tint: #e8f1f8;
  --accent: #1e7d5f;
  --accent-tint: #e6f2ec;
  --border: #d5dee6;
  --border-strong: #b6c4d0;
  --error: #b3261e;
  --error-tint: #fbeeed;
  --radius: 12px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(16, 35, 53, 0.06), 0 1px 8px rgba(16, 35, 53, 0.04);
  --focus-ring: 0 0 0 3px rgba(20, 80, 123, 0.35);
}

* { box-sizing: border-box; }

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

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

/* ---------- Header / footer ---------- */

.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 14px;
  padding-bottom: 14px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
}

.brand-mark { width: 32px; height: 32px; flex: none; }

.brand-name {
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.01em;
}

.header-tag {
  margin: 0;
  font-size: 0.8rem;
  color: var(--ink-faint);
  text-align: right;
}

.site-footer {
  margin-top: 48px;
  padding: 28px 0 40px;
  border-top: 1px solid var(--border);
  background: var(--surface);
}

.footer-links { margin: 0 0 10px; font-size: 0.9rem; }
.footer-links a { color: var(--brand); }
.footer-links span { margin: 0 8px; color: var(--ink-faint); }

.footer-legal {
  margin: 0;
  font-size: 0.78rem;
  color: var(--ink-faint);
  max-width: 640px;
}

/* ---------- Layout ---------- */

.container {
  width: 100%;
  max-width: 640px;
  margin: 0 auto;
  padding-left: 20px;
  padding-right: 20px;
}

main.container { padding-top: 24px; }

.noscript-note {
  background: var(--error-tint);
  border: 1px solid var(--error);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
}

.screen-heading {
  font-size: 1.5rem;
  line-height: 1.25;
  letter-spacing: -0.015em;
  margin: 0 0 8px;
  outline: none; /* focused programmatically for screen readers; ring not needed */
}

.screen-sub {
  margin: 0 0 24px;
  color: var(--ink-soft);
}

/* ---------- Progress ---------- */

.progress {
  list-style: none;
  display: flex;
  margin: 4px 0 28px;
  padding: 0;
}

.progress-step {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  position: relative;
}

/* connector line */
.progress-step + .progress-step::before {
  content: "";
  position: absolute;
  top: 14px;
  right: 50%;
  width: 100%;
  transform: translateX(-14px);
  height: 2px;
  background: var(--border-strong);
}

.progress-step.is-done + .progress-step::before,
.progress-step.is-done + .progress-step.is-active::before {
  background: var(--brand);
}

.progress-dot {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.82rem;
  font-weight: 600;
  background: var(--surface);
  border: 2px solid var(--border-strong);
  color: var(--ink-faint);
  position: relative;
  z-index: 1;
}

.progress-step.is-active .progress-dot {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
}

.progress-step.is-done .progress-dot {
  background: var(--brand-tint);
  border-color: var(--brand);
  color: var(--brand);
}

.progress-label {
  font-size: 0.78rem;
  color: var(--ink-faint);
}

.progress-step.is-active .progress-label {
  color: var(--ink);
  font-weight: 600;
}

/* ---------- Service cards ---------- */

.cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.card {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  min-height: 76px;
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  cursor: pointer;
  text-align: left;
  font: inherit;
  color: inherit;
  transition: border-color 120ms ease, transform 120ms ease;
}

.card:hover { border-color: var(--brand); }
.card:active { transform: scale(0.99); }

.card-icon {
  flex: none;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: var(--brand-tint);
  color: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
}

.card-icon svg { width: 24px; height: 24px; }

.card-body { display: flex; flex-direction: column; gap: 2px; }

.card-title { font-weight: 600; }

.card-blurb { font-size: 0.86rem; color: var(--ink-soft); }

.card-arrow {
  margin-left: auto;
  color: var(--ink-faint);
  font-size: 1.1rem;
  flex: none;
}

/* ---------- Forms ---------- */

.field { margin-bottom: 18px; }

.field label,
.consent-row label {
  display: block;
  font-weight: 600;
  font-size: 0.94rem;
  margin-bottom: 6px;
}

input[type="text"],
input[type="tel"],
input[type="email"],
select {
  width: 100%;
  min-height: 52px;
  padding: 12px 14px;
  font: inherit;
  font-size: 1rem; /* ≥16px prevents iOS zoom-on-focus */
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  appearance: none;
}

select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9'%3E%3Cpath d='M1 1l6 6 6-6' fill='none' stroke='%2346586b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
}

input:focus-visible,
select:focus-visible,
input:focus,
select:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: var(--focus-ring);
}

input.is-invalid,
select.is-invalid {
  border-color: var(--error);
}

input.is-invalid:focus,
select.is-invalid:focus {
  box-shadow: 0 0 0 3px rgba(179, 38, 30, 0.25);
}

.input-prefix { position: relative; }

/* em-based metrics so the $ scales with text-only zoom instead of overlapping
   the first digit (WCAG 1.4.4) */
.input-prefix .prefix {
  position: absolute;
  left: 0.875em;
  top: 50%;
  transform: translateY(-50%);
  color: var(--ink-faint);
  font-size: 1rem;
  pointer-events: none;
}

.input-prefix input { padding-left: 1.9em; }

.field-hint {
  margin: 6px 0 0;
  font-size: 0.82rem;
  color: var(--ink-faint);
}

/* Error elements are permanent live regions: rendered but zero-footprint while
   empty, so screen readers announce the text the moment it is inserted. */
.field-error {
  margin: 6px 0 0;
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--error);
}

.field-error:empty { margin: 0; }

.form-status {
  margin: 0 0 16px;
  padding: 12px 14px;
  background: var(--error-tint);
  border: 1px solid rgba(179, 38, 30, 0.4);
  border-radius: var(--radius-sm);
  color: var(--error);
  font-size: 0.9rem;
}

.form-status:empty {
  margin: 0;
  padding: 0;
  border: none;
}

.form-status:focus { outline: none; }

/* ---------- Consent ---------- */

.consent-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
  margin: 22px 0 12px;
}

.consent-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.consent-row input[type="checkbox"] {
  flex: none;
  width: 22px;
  height: 22px;
  margin: 2px 0 0;
  accent-color: var(--brand);
  cursor: pointer;
}

.consent-row input[type="checkbox"]:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-radius: 4px;
}

.consent-row label {
  font-weight: 400;
  font-size: 0.9rem;
  margin: 0;
  cursor: pointer;
}

.consent-box .field-error { margin-top: 10px; }

.disclosure {
  font-size: 0.8rem;
  color: var(--ink-faint);
  margin: 0 0 22px;
}

.disclosure a { color: var(--brand); }

/* ---------- Buttons & links ---------- */

.btn {
  display: block;
  width: 100%;
  min-height: 54px;
  padding: 14px 20px;
  font: inherit;
  font-size: 1.05rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
}

.btn-primary {
  background: var(--brand);
  color: #fff;
}

.btn-primary:hover { background: var(--brand-dark); }

.btn-primary:focus-visible {
  outline: 3px solid var(--brand);
  outline-offset: 3px;
}

.btn[disabled] {
  opacity: 0.7;
  cursor: default;
}

.back-link {
  background: none;
  border: none;
  padding: 8px 0;
  margin: 0 0 8px;
  font: inherit;
  font-size: 0.9rem;
  color: var(--brand);
  cursor: pointer;
}

.back-link:hover { text-decoration: underline; }

.back-link:focus-visible {
  outline: 3px solid var(--brand);
  outline-offset: 2px;
  border-radius: 4px;
}

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

a:focus-visible {
  outline: 3px solid var(--brand);
  outline-offset: 2px;
  border-radius: 2px;
}

/* ---------- Thanks ---------- */

.thanks-icon { margin: 8px 0 18px; }
.thanks-icon svg { width: 64px; height: 64px; }

.next-steps {
  margin: 0 0 20px;
  padding: 0 0 0 20px;
  color: var(--ink-soft);
}

.next-steps li { margin-bottom: 10px; }

.fine-print {
  font-size: 0.82rem;
  color: var(--ink-faint);
}

/* ---------- Legal pages ---------- */

.legal { max-width: 760px; }

.legal h1 {
  font-size: 1.7rem;
  letter-spacing: -0.015em;
  margin: 8px 0 4px;
}

.legal .updated {
  color: var(--ink-faint);
  font-size: 0.88rem;
  margin: 0 0 28px;
}

.legal h2 {
  font-size: 1.15rem;
  margin: 32px 0 10px;
}

.legal h3 { font-size: 1rem; margin: 22px 0 8px; }

.legal p, .legal li { color: var(--ink-soft); font-size: 0.95rem; }

.legal ul { padding-left: 22px; }

.legal .callout {
  background: var(--brand-tint);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin: 16px 0;
}

/* ---------- Wider screens ---------- */

@media (min-width: 560px) {
  .cards { grid-template-columns: 1fr 1fr; }

  .card {
    flex-direction: column;
    align-items: flex-start;
    min-height: 150px;
  }

  .card-arrow { display: none; }

  .screen-heading { font-size: 1.75rem; }

  .btn { width: auto; min-width: 200px; }
}

/* ---------- Motion & misc ---------- */

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

.screen[hidden] { display: none; }

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