:root {
  color-scheme: light;
  --paper: #f4f1ea;
  --surface: #fbfaf6;
  --ink: #202a25;
  --muted: #647169;
  --line: #dedfd6;
  --accent: #28614e;
  --accent-deep: #1c493b;
  --terra: #bf684a;
  --error: #a63e36;
  --serif: Georgia, "Times New Roman", serif;
  --sans: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

html { min-width: 320px; background: var(--paper); }

body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(ellipse at 82% 10%, rgba(196, 205, 184, .26), transparent 30rem),
    var(--paper);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
}

.masthead, .page-footer {
  width: min(1120px, calc(100% - 64px));
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.masthead {
  min-height: 78px;
  border-bottom: 1px solid rgba(32, 42, 37, .13);
}

.wordmark {
  color: var(--ink);
  text-decoration: none;
  font-size: 11px;
  letter-spacing: .16em;
  font-weight: 700;
}

.wordmark span { color: var(--terra); padding-inline: 5px; }
.masthead-note, .page-footer { color: var(--muted); font-size: 12px; }

.page-shell {
  width: min(820px, calc(100% - 48px));
  margin: 0 auto;
  padding: clamp(56px, 9vw, 104px) 0 74px;
}

.intro { max-width: 650px; margin: 0 auto 44px; }

.eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 22px;
  color: var(--accent);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .16em;
}

.eyebrow-mark {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--terra);
}

h1 {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(42px, 7vw, 68px);
  font-weight: 400;
  letter-spacing: -.045em;
  line-height: 1.08;
}

h1 em { color: var(--accent); font-weight: 400; }
.intro-copy { max-width: 510px; margin: 22px 0 0; color: var(--muted); font-size: 16px; }

.survey-panel {
  padding: clamp(25px, 5vw, 48px);
  border: 1px solid rgba(32, 42, 37, .12);
  background: var(--surface);
  box-shadow: 0 18px 48px rgba(48, 53, 46, .045);
}

.survey-meta { padding-bottom: 28px; border-bottom: 1px solid var(--line); }
.progress-copy { display: flex; justify-content: space-between; gap: 16px; margin-bottom: 12px; color: var(--muted); font-size: 12px; }
.progress-copy span:last-child { color: var(--ink); font-variant-numeric: tabular-nums; }
.progress-track { height: 4px; overflow: hidden; background: #e7e8df; border-radius: 9px; }
#progress-fill { display: block; width: 0; height: 100%; background: var(--accent); transition: width .2s ease; }

.question {
  min-width: 0;
  margin: 0;
  padding: 29px 0 30px;
  border: 0;
  border-bottom: 1px solid var(--line);
}

.question legend { display: block; width: 100%; padding: 0; font-size: 16px; font-weight: 600; line-height: 1.45; }
.required-mark, .optional-mark { margin-left: 7px; color: var(--muted); font-size: 10px; font-weight: 400; white-space: nowrap; }
.required-mark { color: var(--terra); }
.question-help { margin: 7px 0 16px; color: var(--muted); font-size: 13px; }
.question:not(:has(.question-help)) legend { margin-bottom: 17px; }

.text-control {
  display: block;
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border: 1px solid #cdd2c8;
  border-radius: 2px;
  background: #fffefa;
  color: var(--ink);
  font: inherit;
  line-height: 1.5;
  resize: vertical;
  transition: border-color .15s, box-shadow .15s;
}

.text-control:focus, .range-control:focus-visible, .choice:focus-within {
  outline: 2px solid transparent;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(40, 97, 78, .14);
}

.choice-list { display: grid; gap: 8px; }
.choice {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 48px;
  padding: 9px 13px;
  border: 1px solid var(--line);
  background: #fffefa;
  cursor: pointer;
  transition: border-color .15s, background .15s;
}

.choice:hover { border-color: #9cafa3; background: #f8f8f2; }
.choice input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.choice-marker { display: grid; place-items: center; flex: 0 0 18px; width: 18px; height: 18px; border: 1px solid #9aa79d; border-radius: 50%; }
.choice input[type="checkbox"] + .choice-marker { border-radius: 2px; }
.choice input:checked + .choice-marker { border-color: var(--accent); background: var(--accent); }
.choice input:checked + .choice-marker::after { content: ""; width: 6px; height: 6px; border-radius: 50%; background: white; }
.choice input[type="checkbox"]:checked + .choice-marker::after { width: 8px; height: 4px; border: 1.5px solid white; border-top: 0; border-right: 0; border-radius: 0; background: transparent; transform: rotate(-45deg) translate(1px, -1px); }
.choice:focus-within .choice-marker { outline: 2px solid var(--accent); outline-offset: 3px; }
.choice-text { font-size: 14px; }

.range-value {
  display: grid;
  place-items: center;
  width: 54px;
  height: 48px;
  margin: 0 auto 17px;
  border: 1px solid var(--line);
  background: #f5f5ee;
  color: var(--accent-deep);
  font-family: var(--serif);
  font-size: 24px;
}

.range-control { display: block; width: 100%; accent-color: var(--accent); cursor: pointer; }
.range-labels { display: flex; justify-content: space-between; gap: 16px; margin-top: 6px; color: var(--muted); font-size: 11px; }
.field-error { margin: 9px 0 0; color: var(--error); font-size: 12px; }
.field-error[hidden] { display: none; }
.question.has-error .text-control, .question.has-error .choice { border-color: var(--error); }

.form-message { margin-top: 18px; color: var(--muted); font-size: 13px; }
.form-message:empty { display: none; }
.is-error { color: var(--error) !important; }

.submit-button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  width: 100%;
  min-height: 56px;
  margin-top: 25px;
  padding: 0 20px;
  border: 0;
  background: var(--accent);
  color: #fffefa;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  transition: background .15s, transform .15s;
}

.submit-button:hover:not(:disabled) { background: var(--accent-deep); }
.submit-button:active:not(:disabled) { transform: translateY(1px); }
.submit-button:focus-visible { outline: 3px solid rgba(40, 97, 78, .35); outline-offset: 3px; }
.submit-button:disabled { opacity: .7; cursor: wait; }
.button-arrow { font-size: 20px; font-weight: 400; }
.privacy-note { margin: 14px 0 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.loading-message { padding: 32px 0; color: var(--muted); font-size: 14px; }

.success-panel { padding: 20px 0 8px; }
.success-panel .eyebrow { margin-bottom: 15px; }
.success-panel h2 { margin: 0; font: 400 clamp(30px, 5vw, 42px)/1.15 var(--serif); letter-spacing: -.035em; }
.success-panel > p:last-child { margin: 14px 0 0; color: var(--muted); }

.page-footer { min-height: 76px; border-top: 1px solid rgba(32, 42, 37, .13); }

@media (max-width: 600px) {
  .masthead, .page-footer { width: calc(100% - 36px); }
  .masthead { min-height: 64px; }
  .masthead-note { display: none; }
  .page-shell { width: calc(100% - 32px); padding-top: 56px; }
  .intro { margin-bottom: 30px; }
  .intro-copy { font-size: 15px; }
  .survey-panel { padding: 24px 20px; }
  .question { padding-block: 25px; }
  .page-footer { gap: 12px; align-items: flex-start; justify-content: center; flex-direction: column; padding-block: 14px; }
}

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

