/*
  Design system
  Edit these root variables first if you want to scale the UI up or down later.
*/
:root {
  --bg: #f8f6f1;
  --bg-soft: #ffffff;
  --bg-alt: #eef3f4;
  --card: #ffffff;
  --card-soft: #f6f8f8;
  --ink: #243942;
  --ink-strong: #1b2d35;
  --muted: #4f6670;
  --line: #d7e0e3;
  --line-accent: #d9c389;
  --accent: #45606b;
  --accent-strong: #354b55;
  --accent-soft: #edf3f5;
  --gold: #d9c389;
  --gold-soft: #f5efdd;
  --success-bg: #e6f1ea;
  --success-ink: #28563a;
  --warning-bg: #f6edd2;
  --warning-ink: #765a17;
  --danger-bg: #f8e6df;
  --danger-ink: #7d4032;
  --shadow: 0 18px 40px rgba(26, 42, 49, 0.08);

  /* Edit heading sizes here */
  --font-size-display: clamp(2.35rem, 4vw, 3.95rem);
  --font-size-page-title: clamp(2rem, 3.3vw, 3.1rem);
  --font-size-section-title: clamp(1.95rem, 3vw, 2.7rem);
  --font-size-panel-title: clamp(1.3rem, 2vw, 1.7rem);

  /* Edit body text size here */
  --font-size-body: 1.05rem;
  --font-size-body-sm: 0.97rem;
  --font-size-label: 0.98rem;
  --font-size-eyebrow: 0.79rem;
  --font-size-button: 1rem;

  --line-height-tight: 1.08;
  --line-height-body: 1.68;
  --line-height-copy: 1.62;

  /* Edit spacing between sections here */
  --space-1: 0.4rem;
  --space-2: 0.65rem;
  --space-3: 0.9rem;
  --space-4: 1.15rem;
  --space-5: 1.45rem;
  --space-6: 1.85rem;
  --space-7: 2.35rem;
  --space-8: 3rem;

  /* Edit card padding here */
  --card-padding: clamp(1.15rem, 1.4vw, 1.45rem);
  --panel-padding: clamp(1.25rem, 1.6vw, 1.65rem);
  --screen-padding: clamp(1.4rem, 2.4vw, 2.2rem);
  --button-padding-y: 0.9rem;
  --button-padding-x: 1.4rem;

  --content-max: 72rem;
  --copy-max: 40rem;
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 12px;

  /* Edit mobile breakpoints here */
  --breakpoint-tablet: 920px;
  --breakpoint-mobile: 700px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-x: clip;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: clip;
  font-family: "Source Sans 3", sans-serif;
  font-size: var(--font-size-body);
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(217, 195, 137, 0.16), transparent 20%),
    linear-gradient(180deg, #faf9f5 0%, var(--bg) 52%, #f3f6f7 100%);
}

img {
  display: block;
  max-width: 100%;
}

button,
input,
textarea,
select {
  font: inherit;
}

.page-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(rgba(53, 75, 85, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(53, 75, 85, 0.03) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.9), transparent 88%);
}

.page-shell {
  width: min(var(--content-max), calc(100% - 2rem));
  margin: 0 auto;
  padding: var(--space-4) 0 var(--space-8);
}

.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-4);
  padding: var(--space-2) var(--space-2) var(--space-5);
}

.brand-lockup {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  min-width: 0;
}

.site-logo {
  width: 74px;
  height: 74px;
  object-fit: contain;
  border-radius: 16px;
  background: var(--bg-soft);
  padding: 6px;
  border: 1px solid var(--line);
  box-shadow: 0 8px 18px rgba(26, 42, 49, 0.06);
}

.brand-copy {
  display: grid;
  gap: var(--space-1);
  min-width: 0;
}

.site-header h1,
.hero-copy h2,
.section-header h2,
.result-panel h3,
.score-card .profile-name {
  margin: 0;
  font-family: "Cormorant Garamond", serif;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--ink-strong);
}

.site-header h1 {
  font-size: var(--font-size-page-title);
  line-height: 0.96;
}

.eyebrow {
  margin: 0;
  font-size: var(--font-size-eyebrow);
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
}

.site-header .eyebrow {
  font-size: clamp(0.92rem, 1.2vw, 1.08rem);
  letter-spacing: 0.14em;
}

.app-card {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.screen {
  display: none;
  padding: var(--screen-padding);
  animation: fade-up 260ms ease;
}

.screen.is-active {
  display: block;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.24fr) minmax(260px, 0.76fr);
  gap: var(--space-6);
  align-items: start;
}

.hero-copy {
  display: grid;
  gap: var(--space-4);
  max-width: 46rem;
  min-width: 0;
}

.hero-copy .eyebrow,
.section-header .eyebrow {
  margin-bottom: var(--space-2);
}

.hero-copy h2 {
  font-size: var(--font-size-display);
  line-height: var(--line-height-tight);
  max-width: none;
  margin-inline: 0;
  text-align: left;
}

.headline-line {
  display: block;
  white-space: nowrap;
}

.headline-line + .headline-line {
  margin-top: 0.08em;
}

.lead {
  margin: 0;
  max-width: 38rem;
  color: var(--muted);
  font-size: var(--font-size-body);
  line-height: var(--line-height-body);
}

.feature-list,
.question-stack,
.results-main,
.results-side,
.email-form,
.score-bars,
.tag-list {
  display: grid;
  gap: var(--space-4);
  min-width: 0;
}

.feature-list {
  margin-top: var(--space-1);
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}

.feature-item,
.question-card,
.result-panel,
.score-card,
.methodology-note {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
}

.feature-item,
.question-card,
.result-panel,
.score-card,
.methodology-note {
  padding: var(--card-padding);
}

.feature-item {
  color: var(--ink);
  font-size: var(--font-size-body-sm);
  line-height: var(--line-height-copy);
}

.methodology-note {
  margin-top: var(--space-2);
  background: var(--gold-soft);
  border-color: rgba(217, 195, 137, 0.55);
}

.setup-intro {
  display: grid;
  gap: var(--space-3);
  margin-bottom: var(--space-4);
  padding: var(--card-padding);
  background: var(--gold-soft);
  border: 1px solid rgba(217, 195, 137, 0.55);
  border-radius: var(--radius-md);
}

.setup-intro .intro-paragraph {
  margin: 0;
  font-size: var(--font-size-body);
  line-height: var(--line-height-copy);
  color: var(--ink);
}

.setup-intro .intro-paragraph:first-child {
  color: var(--ink-strong);
  font-weight: 600;
}

.opening-scope {
  margin-bottom: var(--space-4);
}

.opening-scope .choice-list {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.hero-panel {
  padding: clamp(1.4rem, 2vw, 2rem);
  background: linear-gradient(180deg, #f7fafb 0%, #f1f5f6 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  display: grid;
  gap: var(--space-5);
  justify-items: center;
  align-content: center;
  min-height: 100%;
}

.hero-logo,
.results-logo {
  width: 112px;
  height: auto;
  object-fit: contain;
}

.results-logo {
  width: 120px;
  margin: 0 auto;
}

.result-panel-logo {
  display: grid;
  place-items: center;
  min-height: 168px;
  background: linear-gradient(180deg, #f7fafb 0%, #f1f5f6 100%);
}

.panel-label,
.progress-text,
.helper-text,
.panel-copy,
.profile-description,
.form-feedback,
.result-meta,
.next-steps li,
.section-copy {
  color: var(--muted);
}

.panel-label,
.progress-text,
.helper-text,
.panel-copy,
.result-meta,
.form-feedback {
  font-size: var(--font-size-body-sm);
}

.section-header {
  margin-bottom: var(--space-5);
  max-width: 42rem;
}

.section-header h2 {
  font-size: var(--font-size-section-title);
  line-height: 1.08;
  margin-top: var(--space-2);
}

.section-copy,
.panel-copy,
.profile-description,
.form-feedback,
.next-steps li,
.helper-text {
  line-height: var(--line-height-copy);
}

.section-copy,
.panel-copy,
.profile-description,
.next-steps li {
  font-size: var(--font-size-body);
}

.progress-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-2);
}

.scale-legend {
  margin-bottom: var(--space-5);
  display: grid;
  gap: var(--space-3);
}

.scale-legend-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-3);
}

/* EDIT HERE: adjust the scale cue wording in data.js and the cue spacing/sizing here. */
.scale-progress {
  display: grid;
  grid-template-columns: auto minmax(2rem, 1fr) auto auto;
  align-items: center;
  gap: var(--space-2);
  padding: 0 var(--space-1);
}

.scale-progress-label-end {
  font-size: var(--font-size-body-sm);
  font-weight: 700;
  color: var(--ink-strong);
  line-height: 1.4;
}

.scale-progress-label {
  font-size: var(--font-size-body-sm);
  font-weight: 700;
  color: var(--ink-strong);
  line-height: 1.4;
}

.scale-progress-line {
  position: relative;
  display: block;
  height: 1px;
  background: #b4c2c8;
}

.scale-progress-line::after {
  content: "";
  position: absolute;
  right: -1px;
  top: 50%;
  width: 9px;
  height: 9px;
  border-top: 2px solid #8fa4ad;
  border-right: 2px solid #8fa4ad;
  transform: translateY(-50%) rotate(45deg);
}

.scale-progress-symbol {
  font-size: 1rem;
  line-height: 1;
  color: var(--muted);
  font-weight: 700;
}

.scale-progress-text-only .scale-progress-line {
  display: none;
}

.legend-item {
  padding: var(--space-3) var(--space-4);
  background: var(--accent-soft);
  border: 1px solid #dbe5e8;
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  font-size: var(--font-size-body-sm);
  min-height: 84px;
}

.legend-item strong {
  font-size: 1.02rem;
  color: var(--accent-strong);
}

.scale-legend-end-label {
  display: none;
}

.question-fieldset {
  border: 0;
  padding: 0;
  margin: 0;
}

.question-fieldset legend {
  padding: 0;
  font-size: 1.08rem;
  font-weight: 700;
  line-height: 1.55;
  color: var(--ink-strong);
  overflow-wrap: anywhere;
}

.choice-list,
.scale-list {
  display: grid;
  gap: var(--space-3);
  margin-top: var(--space-4);
}

.choice-card,
.scale-option {
  position: relative;
  display: flex;
  gap: var(--space-3);
  align-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0.95rem 1rem;
  background: var(--bg-soft);
  cursor: pointer;
  min-height: 58px;
  transition:
    border-color 140ms ease,
    transform 140ms ease,
    box-shadow 140ms ease,
    background 140ms ease;
}

.choice-card:hover,
.scale-option:hover,
.choice-card:focus-within,
.scale-option:focus-within {
  border-color: #9fb2ba;
  box-shadow: 0 10px 20px rgba(26, 42, 49, 0.05);
}

.choice-card input,
.scale-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.choice-mark,
.choice-box {
  width: 18px;
  height: 18px;
  border: 2px solid #92a5ad;
  flex: 0 0 auto;
}

.choice-mark {
  border-radius: 999px;
}

.choice-box {
  border-radius: 5px;
}

.choice-text,
.scale-text {
  line-height: 1.5;
  color: var(--ink);
  font-size: var(--font-size-label);
  overflow-wrap: anywhere;
}

.choice-card input:checked + .choice-mark {
  border-color: var(--accent);
  background: radial-gradient(circle, var(--accent) 45%, transparent 48%);
}

.choice-card input:checked + .choice-box {
  border-color: var(--accent);
  background:
    linear-gradient(135deg, transparent 42%, #ffffff 42%, #ffffff 54%, transparent 54%),
    linear-gradient(45deg, transparent 58%, var(--accent) 58%, var(--accent) 100%);
  background-color: var(--accent);
}

.scale-list {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.question-count {
  margin: 0 0 var(--space-2);
  color: var(--accent);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.scale-number {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  flex: 0 0 auto;
}

.scale-option input:checked ~ .scale-number {
  background: var(--accent);
  color: #ffffff;
}

.scale-option.is-selected,
.choice-card.is-selected {
  border-color: #8ea3ac;
  background: #f8fbfc;
  box-shadow: 0 10px 20px rgba(26, 42, 49, 0.06);
}

.actions {
  margin-top: var(--space-6);
  display: flex;
  justify-content: space-between;
  gap: var(--space-3);
}

.button {
  appearance: none;
  border: 0;
  border-radius: 999px;
  padding: var(--button-padding-y) var(--button-padding-x);
  font-size: var(--font-size-button);
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
  min-height: 50px;
  transition:
    transform 140ms ease,
    box-shadow 140ms ease,
    background 140ms ease,
    color 140ms ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button:disabled {
  opacity: 0.72;
  cursor: wait;
  transform: none;
}

.button:focus-visible,
.field input:focus-visible,
.choice-card:focus-within,
.scale-option:focus-within {
  outline: 3px solid rgba(69, 96, 107, 0.18);
  outline-offset: 2px;
}

.button-primary {
  color: #ffffff;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-strong) 100%);
  box-shadow: 0 10px 20px rgba(53, 75, 85, 0.16);
}

.button-secondary {
  color: var(--ink-strong);
  background: var(--bg-soft);
  border: 1px solid var(--line);
}

.button-full {
  width: 100%;
}

/* Results page polish */
.results-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.42fr) minmax(320px, 0.82fr);
  gap: var(--space-6);
  align-items: start;
}

.results-main {
  gap: var(--space-5);
}

.results-side {
  gap: var(--space-4);
  align-content: start;
}

.results-layout .result-panel,
.results-layout .score-card {
  padding: var(--panel-padding);
}

#results-screen .section-header {
  margin-bottom: var(--space-6);
}

#results-screen .section-copy,
#results-screen .profile-description {
  max-width: 44rem;
}

.score-card {
  display: grid;
  gap: var(--space-2);
  padding: var(--panel-padding);
  background: linear-gradient(180deg, #f7fafb 0%, #eef3f4 100%);
}

.score-card .panel-label,
.score-card .profile-description,
.score-card .score-band {
  color: var(--muted);
}

.score-line {
  display: flex;
  align-items: baseline;
  gap: var(--space-2);
  margin: var(--space-2) 0 var(--space-1);
}

#results-screen .panel-label {
  font-weight: 700;
  letter-spacing: 0.04em;
}

.score-value {
  font-size: clamp(3rem, 5vw, 4.35rem);
  line-height: 1;
  font-weight: 700;
  color: var(--accent-strong);
}

.score-range,
.profile-name {
  font-weight: 700;
}

.profile-name {
  margin: var(--space-2) 0 var(--space-2);
  font-size: var(--font-size-panel-title);
  line-height: 1.15;
}

.score-band {
  margin: 0;
  font-weight: 700;
  font-size: 1rem;
}

.results-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-4);
}

.results-grid > .result-panel {
  min-height: 100%;
}

.result-tag {
  padding: var(--space-4);
  border-radius: var(--radius-sm);
  display: grid;
  gap: var(--space-2);
  align-content: start;
  min-height: 102px;
  background: var(--card);
  border: 1px solid var(--line);
}

.result-tag strong,
.result-panel h3 {
  font-family: "Cormorant Garamond", serif;
  font-weight: 600;
  color: var(--ink-strong);
  overflow-wrap: anywhere;
}

.result-panel h3 {
  margin: 0 0 var(--space-3);
  font-size: var(--font-size-panel-title);
  line-height: 1.12;
}

.badge-inline,
.status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  padding: 0.38rem 0.62rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.tag-list {
  gap: var(--space-3);
}

.result-meta {
  line-height: 1.5;
}

.status-strong {
  background: var(--success-bg);
  color: var(--success-ink);
}

.status-watch {
  background: var(--warning-bg);
  color: var(--warning-ink);
}

.status-priority {
  background: var(--danger-bg);
  color: var(--danger-ink);
}

.score-bar-row {
  display: grid;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-4);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: linear-gradient(180deg, #ffffff 0%, #fbfcfc 100%);
}

.score-bar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-3);
  font-size: 1rem;
}

.score-bar-header > span:first-child {
  font-weight: 600;
  color: var(--ink-strong);
}

.score-bar-meta {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.score-bar-track {
  height: 12px;
  background: #edf2f4;
  border-radius: 999px;
  overflow: hidden;
}

.score-bar-fill {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent) 0%, #6c8994 100%);
}

.next-steps {
  margin: 0;
  padding-left: 1.35rem;
}

.next-steps li {
  padding-left: 0.15rem;
}

.next-steps li + li {
  margin-top: var(--space-3);
}

.field {
  display: grid;
  gap: var(--space-2);
}

.email-form {
  gap: var(--space-3);
}

.field span {
  font-size: var(--font-size-label);
  font-weight: 600;
  color: var(--ink-strong);
}

.field input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.9rem 0.95rem;
  color: var(--ink-strong);
  background: var(--bg-soft);
  min-height: 50px;
}

.field input::placeholder {
  color: #78909a;
}

.field input:focus {
  outline: 3px solid rgba(69, 96, 107, 0.16);
  border-color: #7a95a0;
}

.form-feedback {
  min-height: 22px;
  margin: 0;
  padding-top: var(--space-1);
}

.results-feedback {
  min-height: 1.6rem;
}

.feedback-loading {
  color: var(--accent-strong);
}

.feedback-success {
  color: var(--success-ink);
}

.feedback-error {
  color: var(--danger-ink);
}

.feedback-note {
  color: var(--warning-ink);
}

.consent-note {
  margin-top: var(--space-2);
  font-size: var(--font-size-body-sm);
}


.consultation-panel {
  display: grid;
  gap: var(--space-3);
  align-items: start;
}

.consultation-panel h3 {
  margin-bottom: 0;
}

.consultation-button {
  width: fit-content;
  min-width: min(100%, 18rem);
}

@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Edit tablet breakpoint here */
@media (max-width: 920px) {
  .page-shell {
    width: min(var(--content-max), calc(100% - 1.5rem));
  }

  .hero,
  .results-layout,
  .results-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    gap: var(--space-5);
  }

  .hero-copy,
  .section-header {
    max-width: 100%;
  }

  .hero-panel {
    order: -1;
    min-height: 220px;
  }

  .results-layout {
    gap: var(--space-5);
  }

  .results-side {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--space-3);
  }

  .results-side > :nth-child(2) {
    grid-column: 1 / -1;
  }

  .result-panel-logo {
    min-height: 100%;
  }
}

/* Edit mobile breakpoint here */
@media (max-width: 700px) {
  :root {
    --font-size-display: clamp(1.95rem, 8.2vw, 2.6rem);
    --font-size-page-title: clamp(1.55rem, 6.4vw, 2.15rem);
    --font-size-section-title: clamp(1.6rem, 6.8vw, 2.15rem);
    --font-size-panel-title: clamp(1.2rem, 5.6vw, 1.45rem);
    --font-size-body: 1rem;
    --font-size-body-sm: 0.95rem;
    --font-size-label: 1rem;
    --font-size-eyebrow: 0.74rem;
    --font-size-button: 1rem;
    --space-3: 0.82rem;
    --space-4: 1rem;
    --space-5: 1.2rem;
    --space-6: 1.45rem;
    --space-7: 1.8rem;
    --space-8: 2.3rem;
    --card-padding: 1rem;
    --panel-padding: 1rem;
    --screen-padding: 1rem;
    --button-padding-y: 0.95rem;
    --button-padding-x: 1.2rem;
  }

  .page-bg {
    background-size: 32px 32px;
  }

  .page-shell {
    width: min(100% - 0.9rem, var(--content-max));
    padding-top: var(--space-3);
    padding-bottom: var(--space-6);
  }

  .site-header {
    padding: var(--space-2) 0 var(--space-4);
  }

  .brand-lockup {
    align-items: flex-start;
    gap: var(--space-3);
  }

  .site-header h1 {
    line-height: 1;
  }

  .site-header .eyebrow {
    font-size: 0.78rem;
    letter-spacing: 0.12em;
  }

  .site-logo {
    width: 60px;
    height: 60px;
  }

  .screen {
    padding: var(--screen-padding);
  }

  .hero {
    gap: var(--space-4);
  }

  .hero-panel {
    order: 0;
    align-content: start;
  }

  .hero-copy {
    gap: var(--space-3);
  }

  .hero-copy h2 {
    max-width: 100%;
    font-size: var(--font-size-display);
    line-height: 1.02;
  }

  .headline-line {
    white-space: normal;
  }

  .lead {
    max-width: 100%;
  }

  .feature-list,
  .results-grid,
  .scale-legend,
  .scale-list,
  .results-side,
  .opening-scope .choice-list {
    grid-template-columns: 1fr;
  }

  .feature-list,
  .question-stack,
  .results-main,
  .results-side,
  .email-form,
  .score-bars,
  .tag-list {
    gap: var(--space-3);
  }

  .scale-legend {
    grid-template-columns: auto minmax(0, 1fr);
    align-items: start;
    column-gap: var(--space-3);
    row-gap: var(--space-2);
  }

  .scale-legend-grid {
    grid-template-columns: 1fr;
    gap: var(--space-2);
  }

  .scale-progress {
    grid-template-columns: 1fr;
    grid-template-rows: auto minmax(0, 1fr) auto;
    justify-items: center;
    align-items: start;
    gap: var(--space-2);
    padding: 0;
    min-height: 100%;
  }

  .scale-progress-label {
    text-align: left;
    font-size: 0.95rem;
    line-height: 1.3;
    justify-self: start;
  }

  .scale-progress-line {
    display: block;
    width: 2px;
    min-height: 100%;
    height: 100%;
    background: #b4c2c8;
  }

  .scale-progress-line::after {
    right: 50%;
    top: auto;
    bottom: -1px;
    transform: translateX(50%) rotate(135deg);
  }

  .scale-progress-symbol {
    display: none;
  }

  .scale-progress-label-end {
    display: block;
    margin-top: 0.2rem;
    color: var(--ink-strong);
    font-size: 0.9rem;
    font-weight: 700;
    line-height: 1.3;
    text-align: center;
    max-width: 6.5rem;
  }

  .legend-item {
    min-height: 0;
    padding: 0.78rem 0.9rem;
    flex-direction: row;
    align-items: center;
    gap: 0.35rem;
  }

  .legend-item strong {
    font-size: 0.98rem;
    flex: 0 0 auto;
  }

  .legend-item strong::after {
    content: " -";
  }

  .legend-item span {
    flex: 1 1 auto;
    font-size: 0.98rem;
    line-height: 1.35;
  }


  .section-header {
    margin-bottom: var(--space-4);
    max-width: 100%;
  }

  .section-header h2 {
    margin-top: var(--space-1);
  }

  .setup-intro {
    gap: var(--space-2);
    margin-bottom: var(--space-3);
  }

  .opening-scope,
  .methodology-note {
    margin-bottom: var(--space-3);
  }

  .question-fieldset legend {
    font-size: 1.02rem;
    line-height: 1.5;
  }

  .choice-list,
  .scale-list {
    gap: var(--space-2);
    margin-top: var(--space-3);
  }

  .choice-card,
  .scale-option {
    gap: var(--space-3);
    align-items: flex-start;
    min-height: 68px;
    padding: 1rem 0.95rem;
  }

  .choice-text,
  .scale-text {
    flex: 1 1 auto;
  }

  .scale-number {
    width: 38px;
    height: 38px;
    margin-top: 0.1rem;
  }

  .progress-row,
  .actions,
  .score-bar-header,
  .score-bar-meta {
    flex-direction: column;
    align-items: stretch;
  }

  .actions {
    margin-top: var(--space-5);
  }

  .actions .button + .button {
    margin-top: 0;
  }

  .results-layout {
    gap: var(--space-4);
  }

  .results-side {
    gap: var(--space-3);
  }

  .results-layout .result-panel,
  .results-layout .score-card {
    padding: var(--panel-padding);
  }

  #results-screen .section-header {
    margin-bottom: var(--space-4);
  }

  .score-line {
    flex-wrap: wrap;
    align-items: baseline;
    gap: var(--space-1);
  }

  .score-value {
    font-size: clamp(2.65rem, 14vw, 3.35rem);
  }

  .score-band {
    font-size: 0.98rem;
  }

  .result-panel-logo {
    display: none;
  }

  .result-tag {
    min-height: 0;
    padding: var(--space-3);
  }

  .score-bar-row {
    padding: var(--space-3);
  }

  .score-bar-header > span:first-child {
    line-height: 1.45;
  }

  .score-bar-meta {
    gap: var(--space-1);
  }

  .next-steps {
    padding-left: 1.1rem;
  }

  .next-steps li + li {
    margin-top: var(--space-2);
  }

  .field input {
    min-height: 54px;
    padding: 0.92rem;
  }

  .consultation-button,
  .button {
    width: 100%;
    min-height: 52px;
  }

  .hero-panel,
  .result-panel-logo {
    min-height: 0;
  }

  .hero-panel {
    padding: 1.1rem;
    gap: var(--space-4);
    justify-items: stretch;
  }

  .hero-logo,
  .results-logo {
    width: 98px;
    justify-self: center;
  }
}

@media (max-width: 420px) {
  .page-shell {
    width: min(100% - 0.75rem, var(--content-max));
  }

  .brand-lockup {
    gap: var(--space-2);
  }

  .site-logo {
    width: 54px;
    height: 54px;
    border-radius: 14px;
  }

  .site-header .eyebrow {
    font-size: 0.72rem;
  }

  .screen {
    padding: 0.92rem;
  }

  .hero-copy h2 {
    font-size: clamp(1.78rem, 9vw, 2.2rem);
  }

  .question-fieldset legend {
    font-size: 0.98rem;
  }

  .choice-card,
  .scale-option {
    min-height: 66px;
    padding: 0.92rem 0.85rem;
  }

  .score-value {
    font-size: clamp(2.35rem, 13vw, 3rem);
  }
}
