:root {
  color-scheme: dark;
  --bg: #070914;
  --surface: rgba(19, 23, 43, 0.78);
  --surface-strong: #151a31;
  --surface-soft: rgba(255, 255, 255, 0.055);
  --text: #f8f4e8;
  --muted: #aeb5c9;
  --line: rgba(255, 255, 255, 0.12);
  --gold: #f5c96a;
  --violet: #ad92ff;
  --cyan: #71e1e8;
  --danger: #ff8c8c;
  --success: #91e5b2;
  --radius-lg: 28px;
  --radius-md: 18px;
  --shadow: 0 28px 80px rgba(0, 0, 0, 0.38);
  --max: 1120px;
}

* { box-sizing: border-box; }

html { min-width: 320px; background: var(--bg); scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 10% 10%, rgba(80, 53, 180, 0.18), transparent 32rem),
    radial-gradient(circle at 90% 88%, rgba(22, 151, 162, 0.13), transparent 28rem),
    var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
}

button, a { -webkit-tap-highlight-color: transparent; }
button, input { font: inherit; }
button { color: inherit; }

:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 4px;
}

h1[tabindex="-1"]:focus,
h2[tabindex="-1"]:focus {
  outline: none;
}

.skip-link {
  position: fixed;
  left: 16px;
  top: -80px;
  z-index: 50;
  padding: 12px 18px;
  border-radius: 999px;
  background: var(--text);
  color: var(--bg);
  font-weight: 800;
  transition: top 160ms ease;
}
.skip-link:focus { top: 16px; }

.ambient {
  position: fixed;
  z-index: -1;
  width: 28rem;
  height: 28rem;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.17;
  pointer-events: none;
}
.ambient-one { background: #7b52ff; top: -16rem; left: -12rem; }
.ambient-two { background: #1dd7c4; bottom: -18rem; right: -10rem; }

.topbar {
  width: min(calc(100% - 32px), var(--max));
  min-height: 82px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: auto minmax(180px, 1fr) auto;
  align-items: center;
  gap: 28px;
}

.brand {
  min-height: 48px;
  padding: 0;
  border: 0;
  background: transparent;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-align: left;
  cursor: pointer;
}
.brand strong, .brand small { display: block; }
.brand strong { font-size: 0.96rem; letter-spacing: 0.02em; }
.brand small { color: var(--muted); font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; }
.brand-mark { width: 38px; height: 38px; display: grid; place-items: center; position: relative; }
.brand-mark i { position: absolute; width: 23px; height: 23px; border: 2px solid var(--gold); border-radius: 9px; transform: rotate(45deg); }
.brand-mark i:nth-child(2) { width: 15px; height: 15px; border-color: var(--violet); transform: rotate(24deg); }
.brand-mark i:nth-child(3) { width: 6px; height: 6px; border: 0; background: var(--cyan); border-radius: 50%; transform: none; }

.progress-shell { width: min(100%, 420px); justify-self: center; }
.progress-copy { display: flex; justify-content: space-between; gap: 16px; color: var(--muted); font-size: 0.76rem; margin-bottom: 6px; }
.progress-copy strong { color: var(--text); }
.progress-track { width: 100%; height: 6px; overflow: hidden; background: rgba(255,255,255,0.08); border-radius: 99px; }
.progress-track span { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--violet), var(--gold), var(--cyan)); transition: width 380ms cubic-bezier(.2,.8,.2,1); }

.quiet-button, .secondary-button, .primary-button, .text-button {
  min-height: 46px;
  border-radius: 999px;
  padding: 0 20px;
  border: 1px solid var(--line);
  cursor: pointer;
  font-weight: 750;
}
.quiet-button, .secondary-button { background: rgba(255,255,255,0.05); }
.quiet-button:hover, .secondary-button:hover { background: rgba(255,255,255,0.1); }
.primary-button {
  min-height: 54px;
  border: 0;
  background: linear-gradient(110deg, var(--gold), #fff0ac);
  color: #15110a;
  box-shadow: 0 12px 30px rgba(245,201,106,0.17);
}
.primary-button:hover { transform: translateY(-2px); box-shadow: 0 17px 38px rgba(245,201,106,0.22); }
.primary-button span { display: inline-block; transition: transform 180ms ease; }
.primary-button:hover span, .primary-button:focus-visible span { transform: translateX(4px); }
.primary-button:disabled { cursor: not-allowed; opacity: 0.42; transform: none; box-shadow: none; }
.danger-button { background: var(--danger); color: #250808; }
.text-button { border-color: transparent; background: transparent; color: var(--muted); }
.text-button:hover { color: var(--text); background: rgba(255,255,255,0.05); }

main { width: min(calc(100% - 32px), var(--max)); min-height: calc(100vh - 82px); margin: 0 auto; padding: 42px 0 90px; }
.screen { animation: screen-in 420ms cubic-bezier(.2,.8,.2,1) both; }
@keyframes screen-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

.hero { min-height: calc(100vh - 190px); display: grid; grid-template-columns: 1.05fr 0.95fr; align-items: center; gap: clamp(28px, 7vw, 90px); }
.hero-copy { max-width: 670px; }
.eyebrow { display: block; margin-bottom: 18px; color: var(--gold); font-size: 0.75rem; font-weight: 850; letter-spacing: 0.2em; text-transform: uppercase; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 22px; font-size: clamp(3.1rem, 8.3vw, 7.2rem); line-height: 0.92; letter-spacing: -0.065em; }
h2 { margin-bottom: 16px; font-size: clamp(2.1rem, 5.6vw, 4.6rem); line-height: 0.98; letter-spacing: -0.045em; }
h3 { margin-bottom: 9px; font-size: 1.18rem; line-height: 1.16; }
.lede { max-width: 700px; color: var(--muted); font-size: clamp(1.05rem, 2vw, 1.3rem); }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-top: 34px; }
.safety-note { display: flex; align-items: center; gap: 9px; color: var(--muted); font-size: 0.82rem; }
.safety-note::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--success); box-shadow: 0 0 0 5px rgba(145,229,178,0.1); }
.quest-facts { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 27px; color: var(--muted); font-size: 0.78rem; }
.quest-facts strong { margin-right: 3px; color: var(--text); font-size: 1rem; }
.quest-facts i { width: 4px; height: 4px; border-radius: 50%; background: var(--gold); opacity: .72; }

.quest-orbit { position: relative; aspect-ratio: 1; width: min(100%, 470px); justify-self: center; display: grid; place-items: center; }
.orbit-core { width: 39%; aspect-ratio: 1; border-radius: 32%; transform: rotate(12deg); background: linear-gradient(135deg, rgba(245,201,106,0.24), rgba(173,146,255,0.14)); border: 1px solid rgba(255,255,255,0.15); box-shadow: inset 0 0 40px rgba(255,255,255,0.04), 0 28px 90px rgba(0,0,0,0.42); display: grid; place-items: center; }
.orbit-core span { transform: rotate(-12deg); font-size: clamp(2.6rem, 8vw, 5.2rem); font-weight: 900; letter-spacing: -0.08em; color: var(--gold); }
.orbit-ring { position: absolute; width: 75%; aspect-ratio: 1; border: 1px solid rgba(255,255,255,0.14); border-radius: 50%; animation: orbit 24s linear infinite; }
.orbit-ring::before, .orbit-ring::after { content: ""; position: absolute; width: 20px; height: 20px; border-radius: 7px; background: var(--violet); box-shadow: 0 0 24px rgba(173,146,255,0.55); }
.orbit-ring::before { top: 8%; left: 18%; }
.orbit-ring::after { right: 3%; bottom: 25%; background: var(--cyan); box-shadow: 0 0 24px rgba(113,225,232,0.5); }
.orbit-ring.two { width: 100%; animation-direction: reverse; animation-duration: 35s; border-style: dashed; opacity: .62; }
@keyframes orbit { to { transform: rotate(360deg); } }

.step-head { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px; align-items: end; margin-bottom: 34px; }
.step-number { color: var(--muted); font-size: 0.78rem; letter-spacing: 0.14em; text-transform: uppercase; }
.instruction { color: var(--muted); max-width: 680px; font-size: 1rem; }
.selection-status { min-width: 154px; padding: 12px 16px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface-soft); text-align: center; color: var(--muted); font-size: 0.84rem; }
.selection-status strong { color: var(--text); }

.choice-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.choice-card {
  position: relative;
  min-height: 132px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: linear-gradient(145deg, rgba(255,255,255,0.07), rgba(255,255,255,0.025));
  text-align: left;
  cursor: pointer;
  overflow: hidden;
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease;
}
.choice-card::before { content: ""; position: absolute; inset: -70% 30% -70% -60%; pointer-events: none; background: linear-gradient(105deg, transparent 30%, rgba(255,255,255,.12) 50%, transparent 70%); transform: translateX(-80%) rotate(8deg); transition: transform 520ms cubic-bezier(.2,.8,.2,1); }
.choice-card:hover::before, .choice-card:focus-visible::before { transform: translateX(155%) rotate(8deg); }
.choice-card:hover { transform: translateY(-3px); border-color: rgba(255,255,255,0.25); }
.choice-card[aria-pressed="true"] { border-color: var(--gold); background: linear-gradient(145deg, rgba(245,201,106,0.16), rgba(173,146,255,0.08)); box-shadow: inset 0 0 0 1px rgba(245,201,106,0.25); }
.choice-card[aria-pressed="true"]::after { content: "✓"; position: absolute; top: 12px; right: 12px; width: 26px; height: 26px; display: grid; place-items: center; border-radius: 50%; background: var(--gold); color: #171109; font-weight: 900; }
.choice-card .card-kicker { display: block; margin-bottom: 9px; color: var(--gold); font-size: 0.69rem; font-weight: 850; letter-spacing: 0.14em; text-transform: uppercase; }
.choice-card .card-title { display: block; padding-right: 22px; font-weight: 800; line-height: 1.28; }
.choice-card[aria-pressed="true"] .card-title, .choice-card[aria-pressed="true"] strong { color: #fff7d6; }
.choice-card .card-detail { display: block; margin-top: 8px; color: var(--muted); font-size: 0.83rem; }
.choice-card.limit-hit:not([aria-pressed="true"]) { opacity: 0.52; }

.class-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); max-width: 800px; }
.class-card { min-height: 210px; display: flex; flex-direction: column; justify-content: space-between; }
.class-card strong { font-size: 2.8rem; letter-spacing: -0.06em; }

.challenge-wrap { display: grid; grid-template-columns: 0.72fr 1.28fr; gap: 28px; align-items: stretch; }
.challenge-scene { padding: clamp(24px, 4vw, 48px); border: 1px solid var(--line); border-radius: var(--radius-lg); background: radial-gradient(circle at top right, rgba(173,146,255,0.18), transparent 55%), var(--surface); box-shadow: var(--shadow); }
.challenge-scene .scene-icon { width: 76px; height: 76px; display: grid; place-items: center; border-radius: 24px; margin-bottom: 50px; background: rgba(255,255,255,0.07); color: var(--gold); font-size: 2rem; font-weight: 900; }
.challenge-scene p { color: var(--muted); font-size: 1.04rem; }
.challenge-options { display: grid; gap: 12px; }
.challenge-options .choice-card { min-height: 92px; }

.reveal-screen { min-height: calc(100vh - 190px); display: grid; place-items: center; align-content: center; text-align: center; }
.reveal-screen .eyebrow { margin-bottom: 24px; }
.reveal-screen h2 { max-width: 850px; margin-top: 34px; }
.reveal-screen .lede { max-width: 620px; }
.reveal-orbit { position: relative; width: 174px; height: 174px; display: grid; place-items: center; }
.reveal-orbit::before, .reveal-orbit::after { content: ""; position: absolute; inset: 0; border: 1px solid rgba(255,255,255,.17); border-radius: 50%; animation: reveal-spin 5s linear infinite; }
.reveal-orbit::after { inset: 24px; border-style: dashed; animation-direction: reverse; animation-duration: 3.8s; }
.reveal-orbit b { width: 76px; height: 76px; display: grid; place-items: center; border-radius: 26px; background: linear-gradient(140deg, rgba(245,201,106,.28), rgba(173,146,255,.18)); border: 1px solid rgba(255,255,255,.18); color: var(--gold); font-size: 2.4rem; box-shadow: 0 22px 60px rgba(0,0,0,.45); }
.reveal-orbit i { position: absolute; width: 15px; height: 15px; border-radius: 6px; background: var(--violet); box-shadow: 0 0 28px currentColor; animation: reveal-breathe 900ms ease-in-out infinite alternate; }
.reveal-orbit i:nth-child(1) { left: 10px; top: 46%; color: var(--violet); }
.reveal-orbit i:nth-child(2) { right: 28px; top: 7px; color: var(--cyan); background: var(--cyan); animation-delay: 180ms; }
.reveal-orbit i:nth-child(3) { right: 2px; bottom: 34px; color: var(--gold); background: var(--gold); animation-delay: 360ms; }
.reveal-pulse { display: flex; gap: 8px; margin-top: 22px; }
.reveal-pulse span { width: 8px; height: 8px; border-radius: 50%; background: var(--gold); animation: reveal-dot 700ms ease-in-out infinite alternate; }
.reveal-pulse span:nth-child(2) { animation-delay: 160ms; background: var(--violet); }
.reveal-pulse span:nth-child(3) { animation-delay: 320ms; background: var(--cyan); }
@keyframes reveal-spin { to { transform: rotate(360deg); } }
@keyframes reveal-breathe { to { transform: scale(1.35) rotate(18deg); } }
@keyframes reveal-dot { to { transform: translateY(-8px); opacity: .45; } }

.nav-row { display: flex; justify-content: space-between; align-items: center; gap: 18px; margin-top: 34px; padding-top: 20px; border-top: 1px solid var(--line); }
.nav-row .nav-right { display: flex; align-items: center; gap: 12px; }
.validation-message { min-height: 22px; color: var(--gold); font-size: 0.84rem; text-align: right; }

.reveal-intro { text-align: center; max-width: 720px; margin: 0 auto 42px; }
.reveal-intro h2 { font-size: clamp(2.4rem, 7vw, 5.5rem); }
.world-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.world-card { --world: var(--gold); --mx: 50%; --my: 20%; --rx: 0deg; --ry: 0deg; position: relative; min-height: 500px; padding: 28px; border: 1px solid color-mix(in srgb, var(--world) 48%, transparent); border-radius: var(--radius-lg); background: linear-gradient(155deg, color-mix(in srgb, var(--world) 16%, transparent), rgba(17,21,39,0.92) 42%); box-shadow: var(--shadow); display: flex; flex-direction: column; overflow: hidden; animation: world-rise 620ms cubic-bezier(.2,.85,.2,1) both; transform-style: preserve-3d; transition: transform 150ms ease-out, box-shadow 220ms ease, border-color 220ms ease; }
.world-card:nth-child(2) { animation-delay: 120ms; }
.world-card:nth-child(3) { animation-delay: 240ms; }
@keyframes world-rise { from { opacity: 0; transform: translateY(25px) scale(.97); } to { opacity: 1; transform: none; } }
.world-card::before { content: ""; position: absolute; width: 160px; height: 160px; right: -70px; top: -70px; border: 1px solid color-mix(in srgb, var(--world) 55%, transparent); border-radius: 42%; transform: rotate(28deg); }
.world-card::after { content: ""; position: absolute; inset: 0; z-index: 0; pointer-events: none; background: radial-gradient(280px circle at var(--mx) var(--my), color-mix(in srgb, var(--world) 17%, transparent), transparent 62%); opacity: .25; transition: opacity 180ms ease; }
.world-card > * { position: relative; z-index: 1; }
.world-card:hover, .world-card:focus-within { border-color: color-mix(in srgb, var(--world) 72%, transparent); box-shadow: 0 34px 95px rgba(0,0,0,.48), 0 0 45px color-mix(in srgb, var(--world) 12%, transparent); }
.world-card:hover::after, .world-card:focus-within::after { opacity: 1; }
@media (hover: hover) and (pointer: fine) { .world-card:hover { transform: perspective(900px) rotateX(var(--rx)) rotateY(var(--ry)) translateY(-7px); } }
.world-label { color: var(--world); font-size: 0.72rem; font-weight: 900; letter-spacing: 0.16em; text-transform: uppercase; }
.world-symbol { width: 54px; height: 54px; margin: 28px 0 24px; display: grid; place-items: center; border-radius: 18px; background: color-mix(in srgb, var(--world) 18%, transparent); color: var(--world); font-size: 1.5rem; font-weight: 900; transition: transform 280ms cubic-bezier(.2,.8,.2,1); }
.world-card:hover .world-symbol, .world-card:focus-within .world-symbol { transform: rotate(10deg) scale(1.08); }
.world-card h3 { font-size: 1.65rem; letter-spacing: -0.035em; }
.world-purpose { color: var(--muted); min-height: 76px; }
.reason-list { display: grid; gap: 8px; padding: 0; margin: 8px 0 22px; list-style: none; }
.reason-list li { position: relative; padding-left: 18px; font-size: 0.84rem; color: #d5d8e5; }
.reason-list li::before { content: ""; position: absolute; left: 0; top: 0.62em; width: 6px; height: 6px; border-radius: 50%; background: var(--world); }
.career-preview { margin-top: auto; padding-top: 20px; border-top: 1px solid var(--line); color: var(--muted); font-size: 0.78rem; }
.career-preview strong { display: block; margin-bottom: 7px; color: var(--text); }
.world-card .secondary-button { width: 100%; margin-top: 20px; border-color: color-mix(in srgb, var(--world) 38%, transparent); }
.result-notice { margin: 26px 0 0; padding: 18px 20px; border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--surface-soft); color: var(--muted); font-size: 0.88rem; }
.result-actions { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; margin-top: 30px; }

.explore-hero { --world: var(--gold); display: grid; grid-template-columns: 0.8fr 1.2fr; gap: 28px; margin-bottom: 28px; }
.world-emblem, .explore-copy, .career-section, .question-section, .reflection-box, .passport { border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); box-shadow: var(--shadow); }
.world-emblem { position: relative; min-height: 340px; display: grid; place-items: center; overflow: hidden; background: radial-gradient(circle, color-mix(in srgb, var(--world) 26%, transparent), transparent 60%), var(--surface); }
.world-emblem::before, .world-emblem::after { content: ""; position: absolute; width: 260px; height: 260px; border: 1px solid color-mix(in srgb, var(--world) 25%, transparent); border-radius: 50%; animation: orbit 28s linear infinite; }
.world-emblem::after { width: 205px; height: 205px; border-style: dashed; animation-direction: reverse; animation-duration: 21s; }
.world-emblem span { width: 135px; height: 135px; display: grid; place-items: center; border: 1px solid color-mix(in srgb, var(--world) 55%, transparent); border-radius: 38%; transform: rotate(12deg); color: var(--world); font-size: 3.3rem; font-weight: 950; }
.world-emblem span i { font-style: normal; transform: rotate(-12deg); }
.explore-copy { padding: clamp(26px, 5vw, 54px); }
.explore-copy .eyebrow { color: var(--world); }
.explore-copy p { color: var(--muted); font-size: 1.03rem; }
.content-grid { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 28px; }
.career-section, .question-section { padding: 28px; }
.career-cards { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 10px; }
.career-card { min-height: 86px; padding: 15px; border: 1px solid var(--line); border-radius: 15px; background: var(--surface-soft); display: grid; grid-template-columns: 42px minmax(0,1fr); align-items: center; gap: 12px; transition: transform 180ms ease, background 180ms ease, border-color 180ms ease; }
.career-card:hover, .career-card:focus-within { transform: translateY(-3px); background: color-mix(in srgb, var(--world) 9%, var(--surface-soft)); border-color: color-mix(in srgb, var(--world) 35%, var(--line)); }
.career-icon { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 13px; background: color-mix(in srgb, var(--world) 15%, transparent); color: var(--world); font-size: 1.05rem; font-weight: 900; transition: transform 180ms ease; }
.career-card:hover .career-icon { transform: rotate(-6deg) scale(1.08); }
.career-card strong { display: block; margin-bottom: 4px; }
.career-card small { color: var(--muted); }
.question-list { margin: 0; padding-left: 22px; color: var(--muted); }
.question-list li + li { margin-top: 13px; }
.subjects { margin-top: 22px; padding: 18px; border-radius: 16px; background: var(--surface-soft); color: var(--muted); font-size: 0.86rem; }
.subjects strong { color: var(--text); }
.official-link { display: inline-flex; margin-top: 14px; color: var(--gold); font-weight: 800; }
.pathway-inline { min-height: 46px; margin-top: 16px; padding: 0; border: 0; background: transparent; color: var(--gold); font-weight: 850; text-align: left; cursor: pointer; }
.pathway-inline:hover { color: #fff0ac; }
.reflection-box { margin-top: 28px; padding: 28px; }
.reflection-box p { color: var(--muted); }

.pathways-hero { max-width: 920px; margin: 0 auto 42px; text-align: center; }
.pathways-hero h2 { font-size: clamp(2.6rem, 7.2vw, 6rem); }
.pathways-hero .lede { margin-inline: auto; }
.pathway-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 16px; }
.pathway-card { position: relative; min-height: 410px; padding: 28px; overflow: hidden; display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--radius-lg); background: linear-gradient(150deg, rgba(255,255,255,.075), rgba(17,21,39,.88)); box-shadow: var(--shadow); transition: transform 190ms ease, border-color 190ms ease, background 190ms ease; }
.pathway-card::after { content: ""; position: absolute; width: 180px; height: 180px; right: -115px; bottom: -115px; border: 1px solid rgba(245,201,106,.28); border-radius: 50%; transition: transform 320ms ease; }
.pathway-card:hover, .pathway-card:focus-within { transform: translateY(-5px); border-color: rgba(245,201,106,.42); background: linear-gradient(150deg, rgba(245,201,106,.105), rgba(17,21,39,.9)); }
.pathway-card:hover::after, .pathway-card:focus-within::after { transform: scale(1.25); }
.pathway-card .eyebrow { min-height: 34px; margin-bottom: 10px; font-size: .64rem; }
.pathway-card h3 { font-size: 1.55rem; letter-spacing: -.035em; }
.pathway-card p { color: var(--muted); font-size: .9rem; }
.pathway-symbol { width: 62px; height: 62px; margin-bottom: 32px; display: grid; place-items: center; border-radius: 20px; background: rgba(245,201,106,.12); color: var(--gold); font-size: 1rem; font-weight: 950; letter-spacing: -.04em; }
.pathway-links { position: relative; z-index: 1; display: grid; gap: 8px; margin-top: auto; padding-top: 22px; }
.pathway-links a { min-height: 40px; display: inline-flex; align-items: center; color: var(--gold); font-size: .82rem; font-weight: 850; }
.pathway-links a:hover { color: #fff0ac; }
.pathway-caution { display: grid; grid-template-columns: auto 1fr; gap: 18px; margin-top: 24px; padding: 22px 24px; border: 1px solid rgba(245,201,106,.25); border-radius: var(--radius-md); background: rgba(245,201,106,.06); }
.pathway-caution strong { color: var(--gold); }
.pathway-caution span { color: var(--muted); }

.passport { max-width: 900px; margin: 0 auto; padding: clamp(26px, 5vw, 56px); position: relative; overflow: hidden; }
.passport::after { content: ""; position: absolute; width: 320px; height: 320px; right: -180px; top: -180px; border: 1px solid rgba(245,201,106,0.35); border-radius: 42%; transform: rotate(28deg); }
.passport-header { display: flex; justify-content: space-between; align-items: start; gap: 24px; padding-bottom: 26px; border-bottom: 1px solid var(--line); }
.passport-header h2 { margin-bottom: 8px; }
.passport-stamp { flex: 0 0 auto; width: 86px; height: 86px; display: grid; place-items: center; border: 1px solid var(--gold); border-radius: 28px; color: var(--gold); font-weight: 950; transform: rotate(7deg); }
.passport-section { padding: 24px 0; border-bottom: 1px solid var(--line); }
.passport-worlds { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 12px; }
.passport-world { padding: 17px; border-radius: 16px; border: 1px solid var(--line); background: var(--surface-soft); }
.passport-world span { display: block; color: var(--muted); font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; }
.passport-world strong { display: block; margin-top: 7px; }
.passport-question { font-size: clamp(1.2rem, 3vw, 1.65rem); color: var(--gold); }
.passport-actions { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; margin-top: 28px; }
.replay-note { max-width: 680px; margin: 24px auto 0; color: var(--muted); text-align: center; font-size: .84rem; }

.modal-backdrop { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 20px; background: rgba(2,3,9,0.82); backdrop-filter: blur(12px); }
.modal-backdrop[hidden] { display: none; }
.modal { width: min(100%, 520px); padding: 30px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: #111529; box-shadow: var(--shadow); }
.modal h2 { font-size: 2rem; }
.modal p { color: var(--muted); }
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 24px; }

.empty-state { padding: 60px 24px; text-align: center; border: 1px dashed var(--line); border-radius: var(--radius-lg); color: var(--muted); }

@media (max-width: 900px) {
  .topbar { grid-template-columns: auto 1fr auto; gap: 14px; }
  .progress-shell { width: 100%; }
  .hero { grid-template-columns: 1fr; min-height: auto; }
  .quest-orbit { width: min(78vw, 400px); grid-row: 1; }
  .hero-copy { grid-row: 2; }
  .choice-grid, .world-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .world-card:last-child { grid-column: 1 / -1; min-height: 410px; }
  .challenge-wrap, .explore-hero, .content-grid { grid-template-columns: 1fr; }
  .pathway-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .challenge-scene .scene-icon { margin-bottom: 28px; }
}

@media (max-width: 640px) {
  .topbar { min-height: 74px; grid-template-columns: 1fr auto; }
  .brand small { display: none; }
  .progress-shell { grid-column: 1 / -1; grid-row: 2; padding-bottom: 10px; }
  .quiet-button { min-height: 44px; padding: 0 14px; }
  main { padding-top: 28px; }
  .hero { gap: 30px; }
  .quest-orbit { width: min(86vw, 330px); }
  .step-head { grid-template-columns: 1fr; gap: 12px; margin-bottom: 24px; }
  .selection-status { text-align: left; min-width: 0; }
  .choice-grid, .class-grid, .world-grid, .career-cards, .passport-worlds { grid-template-columns: 1fr; }
  .pathway-grid { grid-template-columns: 1fr; }
  .pathway-card { min-height: 360px; }
  .pathway-caution { grid-template-columns: 1fr; gap: 8px; }
  .class-card { min-height: 150px; }
  .choice-card { min-height: 102px; }
  .world-card, .world-card:last-child { grid-column: auto; min-height: 0; }
  .nav-row { align-items: stretch; flex-direction: column-reverse; }
  .nav-row .nav-right { flex-direction: column; align-items: stretch; }
  .validation-message { text-align: left; }
  .nav-row button { width: 100%; }
  .passport-header { flex-direction: column; }
  .modal-actions { flex-direction: column-reverse; }
  .modal-actions button { width: 100%; }
}

@media (max-width: 360px) {
  .topbar, main { width: min(calc(100% - 20px), var(--max)); }
  h1 { font-size: 2.9rem; }
  h2 { font-size: 2rem; }
  .choice-card { padding: 17px; }
  .challenge-scene, .career-section, .question-section, .reflection-box { padding: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

@media print {
  @page { margin: 12mm; }
  body { background: white !important; color: #111 !important; }
  .topbar, .ambient, .passport-actions, .screen > .eyebrow, .result-notice { display: none !important; }
  main { width: 100%; min-height: 0; padding: 0; }
  .screen { animation: none; }
  .passport { border: 2px solid #111; background: white; color: #111; box-shadow: none; }
  .passport * { color: #111 !important; }
  .passport-world { border-color: #777; background: #f5f5f5; }
}
