:root {
  color-scheme: dark;
  --bg: #080c1b;
  --panel: #0d1226;
  --ink: #f4f3fe;
  --muted: #a6afca;
  --faint: #8c99ba;
  --line: #252e4a;
  --violet: #a69aff;
  --cyan: #72e6dc;
  --mono: "Cascadia Mono", Consolas, monospace;
  font-family: "Segoe UI", system-ui, sans-serif;
  background: var(--bg);
  color: var(--ink);
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  min-height: 100vh;
  min-height: 100svh;
  margin: 0;
  display: flex;
  flex-direction: column;
  background: radial-gradient(ellipse at 69% 30%, #181438 0%, transparent 56%), var(--bg);
}
button, input { font: inherit; }
button { color: inherit; }
button:focus-visible, input:focus-visible + span { outline: 2px solid var(--cyan); outline-offset: 4px; }
h1:focus, h2:focus { outline: none; }
.symbols, .sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.shell { width: min(100% - 104px, 1320px); margin-inline: auto; }
.icon { width: 19px; height: 19px; stroke: currentColor; stroke-width: 1.65; stroke-linecap: round; stroke-linejoin: round; fill: none; flex: none; }
.topbar { border-bottom: 1px solid #242a43; background: #090d1caa; }
.header-inner, .footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.header-inner { min-height: 83px; }
.brand { display: flex; align-items: center; gap: 11px; }
.brand strong, .brand small { display: block; }
.brand strong { font-size: 25px; font-weight: 730; letter-spacing: -.06em; line-height: 1; }
.brand strong span { color: var(--violet); }
.brand small { margin-top: 6px; color: var(--muted); font: 9px var(--mono); letter-spacing: .105em; }
.header-context, .micro, .eyebrow, .figure-caption, figcaption, .counter {
  font-family: var(--mono);
  letter-spacing: .11em;
  font-size: 11px;
}
.header-context { display: flex; align-items: center; gap: 9px; color: var(--faint); }
.header-context span, .figure-caption i { width: 6px; height: 6px; display: inline-block; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 10px #72e6dca0; }
.button {
  min-height: 44px;
  border: 1px solid transparent;
  border-radius: 9px;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 650;
  cursor: pointer;
  transition: border-color .2s, background .2s, color .2s, transform .2s;
}
.button:active:not(:disabled) { transform: translateY(1px); }
.ghost { background: #141a2b80; color: var(--muted); border-color: var(--line); }
.ghost:hover:not(:disabled) { background: #202642; color: var(--ink); border-color: #525a80; }
.primary { background: #b1a5ff; color: #11112b; box-shadow: 0 7px 36px #8c78fb38, inset 0 1px #ffffff5c; }
.primary:hover { background: #c4baff; }
.next { background: #211d43; border-color: #403664; color: #ded6ff; min-width: 122px; }
.next:hover:not(:disabled) { background: #322853; border-color: var(--violet); }
.button:disabled { opacity: .44; cursor: default; }
.back svg { transform: rotate(180deg); }
#experience { flex: 1; display: grid; align-items: center; }
.scene { padding-block: clamp(36px, 6vh, 76px); width: 100%; animation: scene-in .45s ease-out both; }
@keyframes scene-in { from { opacity: 0; transform: translateY(9px); } to { opacity: 1; transform: translateY(0); } }
.intro { display: grid; grid-template-columns: 1.03fr 1fr; gap: clamp(24px, 4vw, 64px); align-items: center; }
.eyebrow { color: #c8beff; margin: 0 0 24px; display: flex; align-items: center; gap: 10px; font-weight: 650; }
.eyebrow span { width: 22px; height: 1px; background: var(--violet); box-shadow: 0 0 9px #a69aff8c; }
h1, h2, h3, p, figure { margin: 0; }
h1, h2 { font-weight: 690; letter-spacing: -.069em; }
h1 { font-size: clamp(43px, 6.1vw, 96px); line-height: 1.035; }
h2 { font-size: clamp(36px, 4.75vw, 68px); line-height: 1.07; }
em { font-style: normal; color: var(--violet); background: linear-gradient(110deg, #b6a5ff 14%, #9584f7 74%, #ad9ffc); background-clip: text; -webkit-text-fill-color: transparent; }
.kinetic { display: block; overflow: hidden; padding-bottom: .08em; margin-bottom: -.08em; }
.kinetic > span { display: block; animation: type-in .8s cubic-bezier(.17,.74,.27,1) both; }
.kinetic:nth-child(2) > span { animation-delay: .12s; }
@keyframes type-in { from { transform: translateY(102%); opacity: .4; } to { transform: translateY(0); opacity: 1; } }
.lede { color: var(--muted); line-height: 1.65; font-size: clamp(16px, 1.42vw, 20px); }
.intro .lede { margin-top: 24px; max-width: 465px; }
.lede strong { color: #e6e5f4; font-weight: 620; }
.signals { margin: 26px 0 32px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; list-style: none; }
.signals li, .profile span { display: flex; align-items: center; gap: 7px; background: #14192c; border: 1px solid #272f4b; border-radius: 6px; color: #ccd3e9; padding: 7px 9px; font-size: 12px; }
.signals i { width: 5px; height: 5px; border-radius: 50%; background: #ae98ff; box-shadow: 0 0 8px #ae98ff99; }
.signals li:nth-child(2) i { background: #70ded9; box-shadow: 0 0 8px #70ded999; }
.signals li:nth-child(3) i { background: #f0b388; box-shadow: 0 0 8px #f0b38899; }
.hero-action { min-height: 52px; padding-inline: 18px; gap: 25px; font-size: 14px; }
.system-figure, .map-panel {
  position: relative;
  overflow: hidden;
  border: 1px solid #303554;
  border-radius: 16px;
  background: radial-gradient(ellipse at 50% 50%, #231b47 0%, #10152c 55%, #0d1224 100%);
  box-shadow: 0 28px 80px #05071460, inset 0 0 35px #080c1b55;
}
.figure-caption, figcaption { display: flex; justify-content: space-between; align-items: center; gap: 8px; color: var(--faint); }
.figure-caption { padding: 18px 20px; }
.figure-caption span:last-child { color: var(--cyan); display: flex; align-items: center; gap: 8px; }
.system-art { position: relative; }
.system-art > svg { width: 100%; display: block; }
figcaption { border-top: 1px solid #242c46; padding: 16px 20px; font-size: 9px; }
.orbit { transform-origin: 300px 236px; animation: orbit 28s linear infinite; }
.orbit.reverse { animation: orbit 40s linear infinite reverse; }
.twinkle { animation: twinkle 3s ease-in-out infinite alternate; }
@keyframes orbit { to { transform: rotate(360deg); } }
@keyframes twinkle { from { opacity: .45; } to { opacity: 1; } }

.scene-heading { margin-bottom: 30px; }
.scene-heading .eyebrow { margin-bottom: 14px; }
.scene-heading .lede { margin-top: 13px; }
.questions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.question { min-width: 0; margin: 0; border: 1px solid var(--line); border-radius: 15px; padding: 18px; background: #0f1429; }
.question-title { display: flex; align-items: center; gap: 11px; font-size: 17px; font-weight: 650; margin-bottom: 14px; }
.question-title span { font: 11px var(--mono); color: var(--violet); background: #211c3e; border-radius: 5px; padding: 6px; }
.options { display: grid; gap: 7px; }
.option { display: block; position: relative; cursor: pointer; }
.option > span { display: flex; align-items: center; gap: 11px; border: 1px solid #28314b; border-radius: 8px; padding: 8px 12px; min-height: 48px; background: #11182d; color: #d6dcee; font-size: 14px; transition: background .2s, border-color .2s; }
.option .icon { color: var(--violet); }
.option .check { display: none; margin-left: auto; color: var(--cyan); }
.option:hover > span { background: #1b2240; border-color: #54547a; }
.option input:checked + span { background: #242045; border-color: #9a8aef; color: var(--ink); }
.option input:checked + span .check { display: block; }
.selection-note { margin-top: 17px; display: flex; align-items: center; gap: 9px; font-size: 14px; color: var(--muted); }
.selection-note svg { color: var(--cyan); }
.discovery-grid { display: grid; grid-template-columns: 1.45fr 1fr; gap: 16px; }
.map-canvas { position: relative; width: 100%; aspect-ratio: 600 / 338; }
.map-canvas > svg { position: absolute; width: 100%; height: 100%; }
.map-node { position: absolute; transform: translate(-50%, -50%); display: grid; justify-items: center; gap: 3px; min-width: 96px; min-height: 55px; align-content: center; padding: 6px; border-radius: 10px; border: 1px solid #41486a; background: #141a31; color: #d8def5; font-size: 12px; font-weight: 650; cursor: pointer; }
.map-node svg { color: #9d9ac4; }
.map-node.in-chain { border-color: #697699; }
.map-node.in-chain svg { color: var(--cyan); }
.map-node:hover { background: #242b49; }
.map-node[aria-pressed="true"] { border-color: var(--cyan); color: #e0fffb; box-shadow: 0 0 18px #72e6dc40; background: #152b3b; }
.map-core { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); display: grid; justify-items: center; gap: 5px; font: 9px var(--mono); color: #bbb5ec; letter-spacing: .08em; }
.map-core img { width: 35px; height: 35px; }
.map-hint { padding: 8px 15px 15px; text-align: center; font-size: 12px; color: var(--muted); }
.flow { stroke-dasharray: 4 8; animation: flow 2.2s linear infinite; }
@keyframes flow { to { stroke-dashoffset: -36; } }
.insight { padding: 19px; border: 1px solid var(--line); border-radius: 15px; background: #101529; }
.profile { display: flex; flex-wrap: wrap; gap: 6px; }
.profile span { border-color: #3a345f; background: #1a1835; color: #dbd0ff; }
.micro { color: var(--violet); font-size: 10px; }
.insight-label { margin-top: 17px; }
.hypothesis { margin-top: 7px; line-height: 1.48; font-size: 15px; }
.chain { color: var(--cyan); font: 11px/1.65 var(--mono); margin-top: 9px; }
.node-detail { margin-top: 14px; border-top: 1px solid var(--line); padding-top: 13px; }
.node-detail h3 { margin-top: 4px; font-size: 18px; }
.node-detail p:not(.micro) { color: var(--muted); margin-top: 5px; font-size: 13px; line-height: 1.5; }
#detail-prompt { color: #e0e3f9; }
.footer { border-top: 1px solid #242a43; background: #090d1cbe; }
.footer-inner { min-height: 76px; }
.progress, .controls, .steps { display: flex; align-items: center; gap: 8px; }
.progress { gap: 15px; }
.counter { white-space: nowrap; color: var(--ink); font-size: 13px; }
.counter span { color: var(--faint); }
.steps { gap: 5px; }
.step { width: 35px; height: 44px; position: relative; border: 0; background: transparent; border-radius: 5px; cursor: pointer; }
.step::after { content: ""; position: absolute; inset: 20px 1px; border-radius: 3px; background: #343a54; }
.step[aria-current]::after { background: var(--violet); box-shadow: 0 0 12px #a69aff88; }
.step.visited::after { background: #7168aa; }
.step:disabled { cursor: default; }
.step:hover:not(:disabled)::after { background: #c5b9ff; }
.step-label { color: var(--faint); font-size: 12px; }
.motion { width: 44px; padding-inline: 0; }
.no-script { padding: 16px; background: #241d40; }
.motion-off *, .motion-off *::before, .motion-off *::after { animation: none !important; transition: none !important; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .motion { display: none; }
}
@media (max-width: 1050px) {
  .shell { width: calc(100% - 64px); }
  .figure-caption, figcaption { padding-inline: 13px; font-size: 9px; }
}
@media (max-width: 760px) {
  .shell { width: calc(100% - 36px); }
  .header-inner { min-height: 67px; }
  .header-context { display: none; }
  .intro, .questions, .discovery-grid { grid-template-columns: minmax(0, 1fr); }
  .intro { gap: 30px; }
  h1 { font-size: clamp(42px, 10vw, 70px); }
  .scene { padding-block: 35px; }
  .eyebrow { margin-bottom: 15px; }
  .intro .lede { margin-top: 15px; }
  .signals { margin: 18px 0 23px; }
  .system-figure { width: min(100%, 530px); }
  .footer-inner { gap: 3px; min-height: 65px; flex-wrap: wrap; padding-block: 7px; }
  .progress { gap: 7px; }
  .step-label { display: none; }
  .step { width: 20px; }
  .controls { gap: 5px; margin-left: auto; }
  .controls .button { padding-inline: 8px; }
  .next { min-width: 0; }
  .back span { display: none; }
  .motion { width: 39px; }
}
@media (max-width: 430px) {
  .map-canvas { aspect-ratio: 600 / 410; }
  .map-node { min-width: 66px; min-height: 44px; font-size: 10px; padding: 4px; }
  .map-node .icon { width: 15px; height: 15px; }
  .map-core img { width: 29px; height: 29px; }
  .figure-caption { letter-spacing: .05em; }
}
