:root {
  --ink: #10273f;
  --ink-soft: #526477;
  --paper: #f7f9fb;
  --white: #ffffff;
  --line: #dce4ea;
  --blue: #176c96;
  --blue-deep: #0b4a6c;
  --safety: #f28a2e;
  --success: #287a5b;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--paper);
}

* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; }
button, input, select, textarea { font: inherit; }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--safety) 60%, white);
  outline-offset: 2px;
}

.masthead {
  min-height: 72px;
  padding: 0 4vw;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--white);
  border-bottom: 1px solid var(--line);
}
.brand { color: var(--ink); text-decoration: none; font-size: 1.35rem; font-weight: 850; letter-spacing: -.04em; }
.brand span { color: var(--blue); }
.save-state { color: var(--success); font-size: .82rem; font-weight: 750; letter-spacing: .02em; }
.review-summary { max-height: 24rem; overflow: auto; white-space: pre-wrap; overflow-wrap: anywhere; padding: 1rem; border: 1px solid var(--line); border-radius: 12px; background: #f7f8f5; font: .78rem/1.45 ui-monospace, SFMono-Regular, Menlo, monospace; }

.shell { min-height: calc(100vh - 72px); display: grid; grid-template-columns: minmax(300px, 38%) 1fr; }
.progress-panel {
  position: relative;
  overflow: hidden;
  padding: clamp(42px, 7vw, 96px) clamp(30px, 6vw, 88px);
  color: white;
  background: var(--ink);
}
.progress-panel::after {
  content: "";
  position: absolute;
  width: 380px;
  height: 190px;
  right: -165px;
  top: 68px;
  border: 22px solid rgba(255,255,255,.055);
  border-left-width: 0;
  transform: rotate(-34deg);
  pointer-events: none;
}
.eyebrow, .step-label { text-transform: uppercase; letter-spacing: .14em; font-size: .72rem; font-weight: 800; }
.eyebrow { color: #8dc7df; }
h1 { max-width: 560px; margin: 16px 0; font-family: "Arial Narrow", "Helvetica Neue", sans-serif; font-size: clamp(2.4rem, 5vw, 4.6rem); line-height: .96; letter-spacing: -.055em; }
.intro { max-width: 460px; color: #c6d4df; line-height: 1.6; }
.roofline { list-style: none; margin: 48px 0 0; padding: 0 0 0 23px; border-left: 1px solid #456078; }
.roofline li { position: relative; padding: 0 0 18px 22px; }
.roofline li::before { content: ""; position: absolute; width: 9px; height: 9px; border-radius: 50%; left: -28px; top: .56em; background: #5d7387; box-shadow: 0 0 0 5px var(--ink); }
.roofline li.active::before { background: var(--safety); }
.roofline button { padding: 2px 0; color: #aebdca; background: none; border: 0; cursor: pointer; text-align: left; }
.roofline li.active button { color: white; font-weight: 750; }
.privacy-note { margin-top: 26px; color: #91a5b5; font-size: .78rem; }

.work-panel { padding: clamp(42px, 7vw, 96px) clamp(28px, 8vw, 112px); background: var(--white); }
.state-card { max-width: 540px; margin: 14vh auto 0; text-align: center; }
.state-card h2, form h2 { margin: 8px 0 10px; font-size: clamp(1.9rem, 3vw, 2.8rem); letter-spacing: -.04em; }
.state-card p, .section-copy { color: var(--ink-soft); line-height: 1.55; }
.spinner { width: 34px; height: 34px; margin: 0 auto 24px; border: 3px solid var(--line); border-top-color: var(--blue); border-radius: 50%; animation: spin .8s linear infinite; }
.state-mark { display: grid; place-items: center; width: 52px; height: 52px; margin: auto; border-radius: 50%; background: #fff0e1; color: #a14c00 !important; font-size: 1.6rem; font-weight: 850; }
.step-label { color: var(--blue); }
.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; margin: 38px 0 54px; }
.field { display: grid; gap: 8px; }
.field.wide { grid-column: 1 / -1; }
.field label { font-size: .88rem; font-weight: 760; }
.field input, .field select, .field textarea { width: 100%; min-height: 48px; padding: 12px 14px; color: var(--ink); background: #fbfcfd; border: 1px solid #bbc9d4; border-radius: 7px; }
.field small { color: var(--ink-soft); }
.form-actions { display: flex; justify-content: space-between; gap: 14px; padding-top: 24px; border-top: 1px solid var(--line); }
.button { min-height: 48px; padding: 0 22px; border-radius: 6px; border: 1px solid transparent; font-weight: 800; cursor: pointer; }
.button.primary { color: white; background: var(--blue-deep); }
.button.secondary { color: var(--ink); background: white; border-color: #aebdca; }
.button:disabled { opacity: .45; cursor: not-allowed; }

@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spinner { animation: none; } }
@media (max-width: 820px) {
  .shell { grid-template-columns: 1fr; }
  .progress-panel { padding: 32px 24px 26px; }
  h1 { font-size: 2.65rem; }
  .roofline { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; padding: 0; border: 0; margin-top: 30px; }
  .roofline li { height: 5px; padding: 0; background: #456078; border-radius: 4px; }
  .roofline li.active { background: var(--safety); }
  .roofline li::before, .roofline button { display: none; }
  .privacy-note { margin-bottom: 0; }
  .work-panel { padding: 40px 24px; }
  .field-grid { grid-template-columns: 1fr; }
  .field.wide { grid-column: auto; }
}
