:root {
  --brand: #6C2BD9;
  --brand-strong: #5520B8;
  --brand-soft: #F3ECFF;
  --lime: #C6F73B;
  --lime-soft: #F7FFD8;
  --ink: #0A0612;
  --ink-soft: #2E263B;
  --muted: #6A6177;
  --bg: #FBFAFC;
  --surface: #FFFFFF;
  --surface-soft: #F6F2FA;
  --line: rgba(10, 6, 18, .09);
  --line-brand: rgba(108, 43, 217, .16);
  --shadow: 0 18px 48px -38px rgba(24, 13, 39, .45);
  --shadow-strong: 0 28px 70px -45px rgba(35, 16, 65, .55);
  --radius: 16px;
  --radius-sm: 12px;
  --max: 1080px;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  font-family: "Poppins", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(38% 42% at 98% 0%, rgba(198, 247, 59, .10), transparent 72%),
    radial-gradient(36% 46% at 0% 12%, rgba(108, 43, 217, .07), transparent 74%),
    var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }
a { color: inherit; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
svg { width: 20px; height: 20px; }

.wrap,
.app-shell {
  width: min(var(--max), calc(100% - 40px));
  margin: 0 auto;
}

h1, h2, h3, p { margin-top: 0; }

h1 {
  max-width: 12ch;
  margin: 14px 0 16px;
  font-size: clamp(2.2rem, 4.2vw, 3.55rem);
  line-height: 1.02;
  letter-spacing: -.052em;
}

h2 {
  margin-bottom: 8px;
  font-size: clamp(1.55rem, 2.6vw, 2.18rem);
  line-height: 1.1;
  letter-spacing: -.042em;
}

h3 {
  margin-bottom: 0;
  font-size: 1.06rem;
  line-height: 1.3;
  letter-spacing: -.026em;
}

p {
  color: var(--muted);
  line-height: 1.62;
}

.italic {
  color: var(--brand);
  font-style: italic;
}

.lead {
  max-width: 650px;
  margin-bottom: 0;
  color: var(--ink-soft);
  font-size: .98rem;
  line-height: 1.66;
}

.support-text {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: .78rem;
  line-height: 1.55;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin: 0 0 8px;
  color: var(--brand);
  font-size: .66rem;
  font-weight: 800;
  letter-spacing: .105em;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--lime);
}

.skip-link {
  position: fixed;
  top: -100px;
  left: 16px;
  z-index: 300;
  padding: 10px 13px;
  border-radius: 10px;
  background: var(--lime);
  color: var(--ink);
  font-size: .8rem;
  font-weight: 700;
}

.skip-link:focus { top: 16px; }

/* Global navigation */
.topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(251, 250, 252, .91);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.nav {
  min-height: 62px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -.02em;
}

.brand-mark {
  width: 32px;
  height: 32px;
  flex: 0 0 auto;
  object-fit: contain;
}

.brand-text {
  display: flex;
  flex-direction: column;
  font-size: .92rem;
}

.brand small {
  margin-top: 4px;
  color: var(--muted);
  font-size: .59rem;
  font-weight: 500;
}

.links {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-left: auto;
  color: var(--muted);
  font-size: .83rem;
  font-weight: 600;
}

.links a {
  text-decoration: none;
  transition: color .2s ease;
}

.links a:hover,
.links a.active { color: var(--brand); }

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #fff;
  color: var(--ink);
  font-size: 1.2rem;
}

.mobile-menu {
  display: none;
  width: min(var(--max), calc(100% - 40px));
  margin: 0 auto;
  padding: 8px 0 18px;
  flex-direction: column;
  gap: 4px;
}

.mobile-menu a:not(.btn) {
  padding: 11px 13px;
  border-radius: 10px;
  color: var(--muted);
  font-size: .91rem;
  font-weight: 600;
  text-decoration: none;
}

.mobile-menu a.active,
.mobile-menu a:not(.btn):hover {
  background: rgba(108, 43, 217, .07);
  color: var(--brand);
}

.mobile-menu .btn {
  width: 100%;
  margin-top: 8px;
}

/* Buttons */
.btn {
  appearance: none;
  min-height: 42px;
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid transparent;
  border-radius: 11px;
  font-size: .82rem;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  transition: transform .2s ease, background .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.btn:hover { transform: translateY(-2px); }

.btn:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible {
  outline: 3px solid rgba(198, 247, 59, .75);
  outline-offset: 3px;
}

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

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

.btn-lime {
  background: var(--lime);
  color: var(--ink);
  border-color: var(--lime);
}

.btn-light {
  background: #fff;
  color: var(--ink);
  border-color: var(--line);
}

.btn-ghost {
  background: rgba(108, 43, 217, .06);
  color: var(--brand);
  border-color: rgba(108, 43, 217, .10);
}

.btn:disabled {
  opacity: .42;
  cursor: not-allowed;
  transform: none;
}

/* Dynamic app */
.app-shell {
  min-height: 72vh;
  padding: 42px 0 58px;
}

.screen {
  animation: fadeUp .25s ease both;
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(310px, .72fr);
  gap: clamp(22px, 4vw, 42px);
  align-items: stretch;
}

.hero-card,
.panel,
.result-card {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, .92);
  box-shadow: var(--shadow);
}

.hero-copy {
  padding: clamp(28px, 4.5vw, 48px);
}

.hero-copy .actions { margin-top: 22px; }

.privacy-note {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: .7rem;
}

.diagnostic-summary {
  padding: 20px;
  border: 1px solid var(--line-brand);
  border-radius: 18px;
  background: var(--surface);
  box-shadow: var(--shadow-strong);
}

.summary-head {
  display: flex;
  align-items: center;
  gap: 11px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.summary-mark,
.lab-mark {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 12px;
  background: var(--brand-soft);
  color: var(--brand);
}

.summary-head strong,
.summary-head span { display: block; }

.summary-head strong {
  font-size: .85rem;
  letter-spacing: -.02em;
}

.summary-head span {
  margin-top: 3px;
  color: var(--muted);
  font-size: .65rem;
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-top: 14px;
}

.summary-grid div {
  padding: 12px;
  border-radius: 12px;
  background: var(--surface-soft);
}

.summary-grid strong,
.summary-grid span { display: block; }

.summary-grid strong {
  color: var(--brand);
  font-size: 1.05rem;
}

.summary-grid span {
  margin-top: 2px;
  color: var(--muted);
  font-size: .62rem;
}

.summary-list {
  display: grid;
  gap: 8px;
  margin-top: 15px;
  color: var(--ink-soft);
  font-size: .71rem;
  font-weight: 600;
}

.summary-list span {
  display: flex;
  align-items: center;
  gap: 8px;
}

.summary-list i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--lime);
}

.feature-grid,
.card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 11px;
  margin-top: 18px;
}

.card {
  padding: 17px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
}

.card-icon {
  width: 34px;
  height: 34px;
  margin-bottom: 12px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: var(--brand-soft);
  color: var(--brand);
  font-size: .68rem;
  font-weight: 800;
}

.card strong {
  display: block;
  margin-bottom: 6px;
  font-size: .82rem;
}

.card p {
  margin-bottom: 0;
  font-size: .71rem;
  line-height: 1.52;
}

.course-context {
  margin-top: 18px;
  padding: 18px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 22px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: var(--surface-soft);
}

.course-context h2 {
  margin-bottom: 5px;
  font-size: 1.12rem;
}

.course-context p {
  max-width: 720px;
  margin-bottom: 0;
  font-size: .75rem;
}

.panel {
  padding: clamp(24px, 4vw, 38px);
}

.compact-panel {
  max-width: 820px;
  margin: 0 auto;
}

.section-head {
  max-width: 760px;
  margin-bottom: 20px;
}

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

.choice-card {
  min-height: 210px;
  padding: 17px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
  text-align: left;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  color: var(--ink);
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.choice-card:hover {
  transform: translateY(-3px);
  border-color: rgba(108, 43, 217, .28);
  box-shadow: var(--shadow);
}

.choice-kicker {
  color: var(--brand);
  font-size: .61rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.choice-card strong {
  display: block;
  margin-bottom: 7px;
  font-size: .88rem;
}

.choice-card p {
  margin-bottom: 0;
  font-size: .71rem;
}

.choice-go {
  color: var(--brand);
  font-size: .7rem;
  font-weight: 700;
}

.disclaimer {
  margin-top: 17px;
  padding: 13px 14px;
  display: flex;
  gap: 11px;
  align-items: flex-start;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface-soft);
}

.disclaimer strong {
  flex: 0 0 auto;
  color: var(--brand);
  font-size: .7rem;
}

.disclaimer p {
  margin-bottom: 0;
  font-size: .7rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 18px;
}

.actions-split {
  justify-content: space-between;
}

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

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field-full { grid-column: 1 / -1; }

.field label {
  font-size: .72rem;
  font-weight: 700;
}

.field input,
.field select {
  width: 100%;
  min-height: 48px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #fff;
  color: var(--ink);
  outline: none;
}

.field input:focus,
.field select:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(108, 43, 217, .09);
}

.form-actions {
  grid-column: 1 / -1;
  justify-content: space-between;
}

.instruction-list {
  display: grid;
  gap: 9px;
}

.instruction-item {
  padding: 12px;
  display: flex;
  gap: 11px;
  align-items: flex-start;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface-soft);
  color: var(--ink-soft);
  font-size: .76rem;
  line-height: 1.5;
}

.dot {
  width: 27px;
  height: 27px;
  display: grid;
  place-items: center;
  flex: 0 0 27px;
  border-radius: 9px;
  background: var(--lime);
  font-size: .68rem;
  font-weight: 800;
}

/* Scenarios */
.scenario-card {
  max-width: 870px;
  margin: 0 auto;
}

.progress-wrap { margin-bottom: 17px; }

.progress-meta {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: .69rem;
  font-weight: 700;
}

.progress-bar {
  height: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--brand-soft);
}

.progress-fill {
  height: 100%;
  border-radius: inherit;
  background: var(--brand);
  transition: width .2s ease;
}

.scenario-title {
  margin-top: 3px;
  font-size: clamp(1.45rem, 2.7vw, 2rem);
}

.scenario-text {
  max-width: 760px;
  margin: 12px 0 0;
  color: var(--ink-soft);
  font-size: .87rem;
  line-height: 1.63;
}

.options-grid {
  display: grid;
  gap: 8px;
  margin-top: 14px;
}

.option-button {
  position: relative;
  width: 100%;
  min-height: 58px;
  padding: 12px 13px 12px 48px;
  text-align: left;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--ink-soft);
  font-size: .78rem;
  line-height: 1.46;
  transition: border-color .2s ease, background .2s ease, box-shadow .2s ease;
}

.option-button::before {
  content: attr(data-letter);
  position: absolute;
  top: 12px;
  left: 12px;
  width: 27px;
  height: 27px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: var(--surface-soft);
  color: var(--brand);
  font-size: .68rem;
  font-weight: 800;
}

.option-button:hover,
.option-button.selected {
  border-color: rgba(108, 43, 217, .42);
  background: rgba(108, 43, 217, .025);
  box-shadow: var(--shadow);
}

.option-button.selected::before {
  background: var(--lime);
  color: var(--ink);
}

.microcopy {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: .67rem;
}

.scenario-actions {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: 17px;
}

/* Loading */
.processing {
  min-height: 360px;
  display: grid;
  place-items: center;
  text-align: center;
}

.processing > div { max-width: 580px; }

.spinner {
  width: 56px;
  height: 56px;
  margin: 0 auto 18px;
  border: 5px solid var(--brand-soft);
  border-top-color: var(--brand);
  border-radius: 50%;
  animation: spin .75s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* Results */
.result-layout {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
  gap: 12px;
  align-items: start;
}

.result-card { padding: 20px; }

.result-hero {
  border-color: var(--ink);
  background: var(--ink);
  color: #fff;
}

.result-hero p { color: rgba(255, 255, 255, .68); }

.result-hero .comparison-code {
  background: rgba(255, 255, 255, .06);
  border-color: rgba(255, 255, 255, .12);
}

.result-hero .comparison-code label,
.result-hero .comparison-code .support-text { color: rgba(255, 255, 255, .72); }

.result-hero .comparison-code textarea {
  background: rgba(255, 255, 255, .08);
  border-color: rgba(255, 255, 255, .12);
  color: #fff;
}

.score-big {
  margin: 11px 0 4px;
  font-size: clamp(3rem, 7vw, 5.2rem);
  font-weight: 800;
  line-height: .94;
  letter-spacing: -.07em;
}

.score-big span { color: var(--lime); }

.metric-grid {
  display: grid;
  gap: 8px;
}

.metric-row {
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--bg);
}

.metric-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: .7rem;
  font-weight: 800;
}

.meter {
  height: 7px;
  margin-top: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--brand-soft);
}

.meter span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--brand);
}

.metric-tip {
  margin: 7px 0 0;
  font-size: .65rem;
  line-height: 1.45;
}

.reco-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.reco-card {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: #fff;
}

.reco-card strong {
  display: block;
  margin-bottom: 6px;
  font-size: .76rem;
}

.reco-card p,
.reco-card li {
  font-size: .7rem;
  line-height: 1.52;
}

.reco-card p { margin-bottom: 0; }

.reco-card ul {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
}

.quote-box {
  margin-top: 10px;
  padding: 13px;
  border: 1px solid rgba(198, 247, 59, .58);
  border-radius: 12px;
  background: var(--lime-soft);
  color: var(--ink-soft);
  font-size: .73rem;
  font-weight: 600;
  line-height: 1.52;
}

.first-aid { margin-top: 12px; }

.first-aid ol {
  margin: 12px 0 0;
  padding-left: 18px;
  color: var(--ink-soft);
  font-size: .75rem;
  line-height: 1.6;
}

.comparison-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 9px;
  margin-top: 13px;
}

.comparison-stat {
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface-soft);
}

.comparison-stat span {
  color: var(--muted);
  font-size: .66rem;
}

.comparison-stat .number {
  margin-top: 3px;
  font-size: 1.75rem;
  font-weight: 800;
  letter-spacing: -.05em;
}

.delta-positive { color: #2D7207; }
.delta-neutral { color: var(--muted); }

.compare-table {
  width: 100%;
  margin-top: 13px;
  border-collapse: collapse;
}

.compare-table th,
.compare-table td {
  padding: 10px 8px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  font-size: .69rem;
}

.compare-table th {
  color: var(--muted);
  font-size: .61rem;
  letter-spacing: .07em;
  text-transform: uppercase;
}

.card-grid { margin-top: 12px; }

.cta-section {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 11px;
  margin-top: 12px;
}

.cta-card {
  padding: 19px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
}

.cta-card h3 { margin-top: 4px; }

.cta-card p {
  margin: 10px 0 0;
  font-size: .74rem;
}

.lab-card {
  border-color: var(--ink);
  background: var(--ink);
  color: #fff;
}

.lab-card p { color: rgba(255, 255, 255, .66); }

.lab-card .eyebrow { color: var(--lime); }

.lab-mark {
  margin-bottom: 14px;
  background: rgba(255, 255, 255, .08);
  color: var(--lime);
}

.slogan {
  margin-top: 10px;
  color: var(--lime);
  font-size: .83rem;
  font-weight: 700;
}

/* Comparison import */
.comparison-code {
  margin-top: 15px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: #fff;
}

.comparison-code label {
  display: block;
  margin-bottom: 7px;
  font-size: .72rem;
  font-weight: 800;
}

.comparison-code textarea {
  width: 100%;
  min-height: 86px;
  resize: vertical;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface-soft);
  color: var(--ink-soft);
  font: 500 .7rem/1.45 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
}

.backup-option {
  margin-top: 13px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface-soft);
}

.backup-option summary {
  padding: 12px 14px;
  color: var(--muted);
  font-size: .7rem;
  font-weight: 700;
  cursor: pointer;
}

.file-upload {
  padding: 0 14px 14px;
}

.file-upload input {
  width: 100%;
  margin-top: 8px;
  font-size: .72rem;
}

.success-box,
.error-box {
  margin-top: 12px;
  padding: 12px 13px;
  display: flex;
  flex-direction: column;
  gap: 3px;
  border-radius: 11px;
  font-size: .7rem;
}

.success-box {
  border: 1px solid rgba(86, 151, 22, .24);
  background: #F4FFE9;
  color: #255706;
}

.error-box {
  border: 1px solid rgba(185, 72, 26, .22);
  background: #FFF3EC;
  color: #7A2E10;
}

/* Footer */
.footer {
  padding: 46px 0 25px;
  background: var(--ink);
  color: #fff;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr .75fr .95fr;
  gap: 42px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 13px;
  font-weight: 700;
}

.footer-brand img {
  width: 34px;
  height: 34px;
  object-fit: contain;
}

.footer p {
  max-width: 390px;
  color: rgba(255, 255, 255, .56);
  font-size: .76rem;
}

.footer h4 {
  margin: 0 0 13px;
  color: var(--lime);
  font-size: .65rem;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.footer a {
  display: block;
  margin-bottom: 9px;
  color: rgba(255, 255, 255, .68);
  font-size: .76rem;
  text-decoration: none;
}

.footer a:hover { color: #fff; }

.socials {
  display: flex;
  gap: 8px;
  margin-top: 16px;
}

.socials a {
  width: 34px;
  height: 34px;
  margin: 0;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .11);
  border-radius: 10px;
  background: rgba(255, 255, 255, .05);
  color: #fff;
}

.footer-bottom {
  margin-top: 29px;
  padding-top: 19px;
  display: flex;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  border-top: 1px solid rgba(255, 255, 255, .11);
  color: rgba(255, 255, 255, .43);
  font-size: .69rem;
}

.hidden { display: none !important; }

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

@media (max-width: 920px) {
  .links,
  .header-lab {
    display: none;
  }

  .menu-toggle { display: inline-flex; }
  .mobile-menu.open { display: flex; }

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

  .diagnostic-summary {
    max-width: 680px;
  }

  .choice-grid,
  .feature-grid,
  .card-grid,
  .comparison-grid {
    grid-template-columns: 1fr;
  }

  .choice-card { min-height: auto; }

  .course-context {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer-grid > div:first-child {
    grid-column: 1 / -1;
  }
}

@media (max-width: 650px) {
  .wrap,
  .app-shell {
    width: min(var(--max), calc(100% - 24px));
  }

  .app-shell { padding: 28px 0 42px; }

  h1 {
    font-size: clamp(2rem, 10vw, 2.72rem);
  }

  .hero-copy,
  .panel,
  .result-card {
    border-radius: 15px;
  }

  .summary-grid,
  .form-grid,
  .reco-grid,
  .cta-section,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .field-full,
  .form-actions,
  .footer-grid > div:first-child {
    grid-column: auto;
  }

  .actions,
  .actions-split,
  .scenario-actions {
    flex-direction: column;
  }

  .actions .btn,
  .scenario-actions .btn,
  .form-actions .btn,
  .course-context .btn {
    width: 100%;
  }

  .option-button {
    padding-left: 46px;
  }

  .compare-table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
