:root {
  --ink: #0b1515;
  --ink-soft: #405b5f;
  --deep: #0a1212;
  --deep-2: #102322;
  --teal: #184c47;
  --teal-bright: #78cfba;
  --teal-soft: #dfe8e3;
  --sand: #d2a16b;
  --cream: #f2efe6;
  --paper: #fbfaf6;
  --line: rgba(11,21,21,.15);
  --line-dark: rgba(11,21,21,.28);
  --danger: #9d3f3f;
  --danger-soft: #f8e6e3;
  --shadow: 0 24px 70px rgba(5,17,16,.16);
  --radius: 20px;
  --content: 1180px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--cream);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; min-height: 100vh; background: radial-gradient(circle at 85% 0%, rgba(121,184,173,.2), transparent 28%), var(--cream); color: var(--ink); }
body.nav-open { overflow: hidden; }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--teal-bright); outline-offset: 3px; }

.skip-link { position: fixed; top: 8px; left: 8px; transform: translateY(-160%); background: var(--paper); padding: .7rem 1rem; border-radius: 10px; z-index: 1000; }
.skip-link:focus { transform: none; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

.site-header { min-height: 78px; color: #f8fbf9; background: rgba(8,18,18,.96); border-bottom: 1px solid rgba(255,255,255,.14); backdrop-filter: blur(16px); position: sticky; top: 0; z-index: 20; }
.header-inner { width: min(calc(100% - 40px), var(--content)); min-height: 78px; margin-inline: auto; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 11px; text-decoration: none; }
.brand img { border-radius: 13px; }
.brand-copy { display: flex; flex-direction: column; line-height: 1.05; }
.brand-copy strong { font-size: 1rem; letter-spacing: .01em; }
.brand-copy small { margin-top: 5px; font-size: .67rem; letter-spacing: .1em; text-transform: uppercase; color: #9db0aa; }
.site-nav { display: flex; align-items: center; gap: 20px; font-size: .88rem; font-weight: 650; }
.site-nav > a { text-decoration: none; color: #dce8e3; transition: color .2s ease; }
.site-nav > a:hover, .site-nav > a:focus-visible, .site-nav > a[aria-current="page"] { color: var(--teal-bright); }
.nav-cta { padding: 10px 15px; border: 1px solid rgba(120,207,186,.45); border-radius: 999px; }
.nav-cta:hover, .nav-cta:focus-visible { background: var(--teal-bright); color: var(--ink) !important; }
.nav-toggle { display: none; background: none; border: 0; color: #f8fbf9; padding: 12px; }
.nav-toggle span:not(.sr-only) { display: block; width: 24px; height: 2px; background: currentColor; margin: 5px; transition: transform .2s ease; }

main { width: min(calc(100% - 32px), var(--content)); margin: 0 auto; }
.page { display: none; }
.page.active { display: block; }

.hero { min-height: calc(100vh - 150px); padding: 72px 0 54px; grid-template-columns: minmax(0, 1fr) 340px; gap: 42px; align-items: start; }
.hero.active { display: grid; }
.hero-copy { max-width: 780px; }
.eyebrow { margin: 0 0 12px; color: var(--teal); font-size: .78rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
h1, h2, h3 { font-family: Georgia, "Times New Roman", serif; color: var(--deep); }
h1 { margin: 0; font-size: clamp(2.4rem, 5.8vw, 5.15rem); line-height: .98; letter-spacing: -.045em; }
.lede { max-width: 700px; margin: 26px 0 0; font-size: 1.22rem; line-height: 1.65; color: var(--ink-soft); }

.privacy-promise { margin-top: 32px; padding: 24px 26px; background: linear-gradient(135deg, rgba(220,235,231,.9), rgba(255,253,248,.92)); border: 1px solid var(--line-dark); border-radius: var(--radius); }
.privacy-promise h2 { margin: 0 0 8px; font-size: 1.45rem; }
.privacy-promise p { margin: 0; line-height: 1.6; color: var(--ink-soft); }

.path-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-top: 28px; }
.path-card { min-height: 190px; display: flex; flex-direction: column; align-items: flex-start; gap: 12px; text-align: left; border: 1px solid var(--line); border-radius: 18px; background: var(--paper); padding: 22px; color: var(--ink); transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease; }
.path-card:hover, .path-card:focus-visible { transform: translateY(-4px); border-color: var(--teal); box-shadow: var(--shadow); outline: none; }
.path-card strong { font-family: Georgia, "Times New Roman", serif; color: var(--deep); font-size: 1.25rem; }
.path-card span:last-child { line-height: 1.48; color: var(--ink-soft); }
.path-time { color: var(--teal); font-size: .78rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }

.welcome-actions, .actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.button { border: 1px solid transparent; border-radius: 999px; padding: .78rem 1.15rem; font-weight: 750; transition: transform .15s ease, background .15s ease, border-color .15s ease; }
.button:hover { transform: translateY(-1px); }
.button.primary { background: var(--deep); color: white; }
.button.secondary { background: var(--teal-soft); border-color: var(--line-dark); color: var(--deep); }
.button.ghost { background: transparent; border-color: var(--line-dark); color: var(--ink); }
.button.danger { background: var(--danger-soft); border-color: #ddb9b4; color: var(--danger); }
.button.full { width: 100%; border-radius: 12px; }

.status-card { position: sticky; top: 108px; padding: 26px; background: var(--deep); color: white; border-radius: 24px; box-shadow: var(--shadow); }
.status-card .eyebrow { color: var(--sand); }
.status-card dl { margin: 0; }
.status-card dl div { display: grid; grid-template-columns: 1fr auto; gap: 14px; padding: 15px 0; border-bottom: 1px solid rgba(255,255,255,.14); }
.status-card dt { color: rgba(255,255,255,.68); }
.status-card dd { margin: 0; text-align: right; font-weight: 750; }
.microcopy { font-size: .83rem; line-height: 1.5; color: rgba(255,255,255,.68); margin: 18px 0 0; }

.panel { margin: 54px auto; background: var(--paper); border: 1px solid var(--line); border-radius: 24px; padding: clamp(24px, 5vw, 48px); box-shadow: var(--shadow); }
.panel.narrow { max-width: 820px; }
.panel h1, .panel > h2 { font-size: clamp(2.1rem, 5vw, 3.8rem); }
.panel > p:not(.eyebrow) { color: var(--ink-soft); line-height: 1.6; }
fieldset { border: 0; padding: 0; margin: 32px 0 0; }
legend { font-family: Georgia, "Times New Roman", serif; font-weight: 700; font-size: 1.3rem; color: var(--deep); margin-bottom: 14px; }
.choice-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.choice-grid.compact { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.choice { display: flex; gap: 10px; align-items: flex-start; padding: 14px; border: 1px solid var(--line); border-radius: 14px; background: white; }
.choice input { margin-top: 3px; accent-color: var(--teal); }
.choice strong { display: block; color: var(--deep); }
.choice span { display: block; margin-top: 3px; font-size: .85rem; color: var(--ink-soft); }

.workspace-shell { margin: 28px 0 50px; display: grid; grid-template-columns: 310px minmax(0, 1fr); min-height: 78vh; background: var(--paper); border: 1px solid var(--line); border-radius: 24px; overflow: hidden; box-shadow: var(--shadow); }
.workspace-nav { background: #f2f7f5; border-right: 1px solid var(--line); padding: 24px; display: flex; flex-direction: column; min-height: 78vh; }
.workspace-brand h2 { margin: 0; font-size: 1.45rem; }
.progress-block { margin: 22px 0; }
.progress-label { display: flex; justify-content: space-between; gap: 12px; color: var(--ink-soft); font-size: .82rem; }
.progress-track { height: 7px; background: #dce6e3; border-radius: 999px; margin-top: 8px; overflow: hidden; }
.progress-track span { display: block; height: 100%; width: 0; background: var(--teal); border-radius: inherit; transition: width .2s ease; }
.search-label { font-size: .8rem; font-weight: 800; color: var(--ink-soft); margin-bottom: 6px; }
#question-search { width: 100%; padding: .72rem .8rem; border: 1px solid var(--line-dark); border-radius: 12px; background: white; color: var(--ink); }
.nav-tabs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin: 16px 0; }
.nav-tab { border: 0; background: transparent; color: var(--ink-soft); padding: .65rem .35rem; border-radius: 10px; font-weight: 750; }
.nav-tab.active { background: var(--deep); color: white; }
.section-list { display: grid; gap: 6px; max-height: 48vh; overflow: auto; padding-right: 4px; }
.section-button { width: 100%; border: 0; background: transparent; color: var(--ink-soft); padding: 10px; border-radius: 10px; text-align: left; display: grid; grid-template-columns: 30px 1fr auto; gap: 8px; align-items: center; }
.section-button:hover, .section-button.active { background: white; color: var(--deep); }
.section-number { color: var(--teal); font-weight: 800; }
.section-count { font-size: .76rem; color: var(--ink-soft); }
.workspace-tools { display: grid; gap: 8px; margin-top: auto; padding-top: 18px; }

.workspace-main { padding: clamp(24px, 4vw, 52px); min-width: 0; }
.workspace-view { display: none; }
.workspace-view.active { display: block; }
.section-header { padding-bottom: 20px; border-bottom: 1px solid var(--line); margin-bottom: 24px; }
.section-header h1 { font-size: clamp(2rem, 4vw, 3.4rem); }
.section-header p { max-width: 720px; color: var(--ink-soft); line-height: 1.6; }
.question-stack { display: grid; gap: 18px; }
.question-card { border: 1px solid var(--line); border-radius: 18px; padding: 22px; background: white; }
.question-card.answered { border-color: rgba(47,118,111,.65); box-shadow: inset 4px 0 0 var(--teal); }
.question-topline { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; }
.question-id { color: var(--teal); font-weight: 850; font-size: .82rem; letter-spacing: .05em; }
.question-type { font-size: .76rem; color: var(--ink-soft); }
.question-card h3 { margin: 10px 0 16px; font-size: 1.24rem; line-height: 1.35; }
.status-options { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.status-pill { display: inline-flex; align-items: center; gap: 6px; padding: 7px 10px; border: 1px solid var(--line); border-radius: 999px; background: #fafcfb; font-size: .83rem; }
.status-pill input { accent-color: var(--teal); }
.response-label { display: grid; gap: 7px; color: var(--ink-soft); font-size: .84rem; font-weight: 750; }
.response-label textarea { min-height: 108px; resize: vertical; border: 1px solid var(--line-dark); border-radius: 12px; padding: 12px; line-height: 1.5; color: var(--ink); background: var(--paper); }
.metadata-toggle { margin-top: 12px; border: 0; background: transparent; padding: 0; color: var(--teal); font-weight: 750; }
.metadata-grid { margin-top: 14px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.metadata-grid[hidden] { display: none; }
.metadata-grid label { display: grid; gap: 6px; font-size: .78rem; font-weight: 750; color: var(--ink-soft); }
.metadata-grid input, .metadata-grid select, .metadata-grid textarea { width: 100%; border: 1px solid var(--line-dark); border-radius: 10px; padding: .65rem .72rem; color: var(--ink); background: var(--paper); }
.metadata-grid .wide { grid-column: 1 / -1; }

.review-hero h1, .privacy-view-content h1 { font-size: clamp(2rem, 4vw, 3.2rem); }
.review-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 22px 0; }
.metric { background: #f2f7f5; border: 1px solid var(--line); border-radius: 15px; padding: 18px; }
.metric strong { display: block; font-size: 1.8rem; color: var(--deep); }
.metric span { color: var(--ink-soft); font-size: .84rem; }
.review-section { margin-top: 28px; }
.review-section h2 { font-size: 1.5rem; }
.review-list { display: grid; gap: 10px; }
.review-item { padding: 14px 16px; border: 1px solid var(--line); border-radius: 12px; background: white; }
.review-item p { margin: 4px 0 0; color: var(--ink-soft); white-space: pre-wrap; }
.empty-state { color: var(--ink-soft); padding: 24px; border: 1px dashed var(--line-dark); border-radius: 14px; }
.privacy-ledger { display: grid; gap: 12px; margin-top: 24px; }
.privacy-ledger article { border: 1px solid var(--line); border-radius: 15px; padding: 18px; background: white; }
.privacy-ledger h2 { margin: 0 0 6px; font-size: 1.25rem; }
.privacy-ledger p { margin: 0; color: var(--ink-soft); line-height: 1.55; }
.code-note { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; background: var(--deep); color: white; padding: 16px; border-radius: 14px; overflow-wrap: anywhere; }

.modal { position: fixed; inset: 0; background: rgba(16,47,52,.62); display: grid; place-items: center; padding: 20px; z-index: 50; }
.modal[hidden] { display: none; }
.modal-card { width: min(680px, 100%); max-height: 86vh; overflow: auto; background: var(--paper); border-radius: 22px; padding: 30px; box-shadow: var(--shadow); position: relative; }
.modal-card h2 { font-size: 2rem; }
.modal-card p, .modal-card li { color: var(--ink-soft); line-height: 1.6; }
.modal-close { position: absolute; right: 16px; top: 12px; border: 0; background: transparent; font-size: 2rem; color: var(--ink-soft); }

.site-footer { width: min(calc(100% - 32px), var(--content)); margin: 0 auto 30px; border-top: 1px solid var(--line-dark); padding: 22px 0 0; display: flex; justify-content: space-between; gap: 30px; color: var(--ink-soft); font-size: .84rem; }
.site-footer p { max-width: 600px; }

@media (max-width: 960px) {
  .nav-toggle { display: block; }
  .site-nav { position: fixed; inset: 78px 0 auto; display: none; padding: 28px 20px 34px; background: rgba(8,18,18,.98); border-top: 1px solid rgba(255,255,255,.14); flex-direction: column; align-items: stretch; gap: 0; }
  body.nav-open .site-nav { display: flex; }
  .site-nav > a { padding: 13px 0; font-size: 1rem; }
  .site-nav .nav-cta { margin-top: 12px; padding: 13px 16px; text-align: center; }
  body.nav-open .nav-toggle span:not(.sr-only):nth-last-child(2) { transform: translateY(3.5px) rotate(45deg); }
  body.nav-open .nav-toggle span:last-child { transform: translateY(-3.5px) rotate(-45deg); }
  .hero.active { grid-template-columns: 1fr; }
  .status-card { position: static; }
  .path-grid { grid-template-columns: 1fr; }
  .path-card { min-height: 0; }
  .workspace-shell { grid-template-columns: 1fr; }
  .workspace-nav { min-height: auto; border-right: 0; border-bottom: 1px solid var(--line); }
  .section-list { max-height: 230px; }
  .workspace-tools { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .choice-grid.compact { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 640px) {
  main, .site-footer { width: min(calc(100% - 20px), var(--content)); }
  .header-inner { width: min(calc(100% - 20px), var(--content)); }
  .brand-copy small { display: none; }
  .hero { padding-top: 42px; }
  .choice-grid, .choice-grid.compact, .metadata-grid, .review-grid { grid-template-columns: 1fr; }
  .workspace-main { padding: 20px 14px; }
  .workspace-nav { padding: 20px 14px; }
  .workspace-tools { grid-template-columns: 1fr; }
  .question-card { padding: 18px 14px; }
  .site-footer { display: block; }
}

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