@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Space+Grotesk:wght@400;500;600;700&display=swap');

:root {
    color-scheme: dark;
    font-family: 'DM Sans', sans-serif;
    background: #070b14;
    color: #f5f7fc;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-width: 320px;
}

button, a {
    font: inherit;
}

button:focus-visible, a:focus-visible {
    outline: 2px solid #b7eece;
    outline-offset: 4px;
}

.app {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding: 0 5.3%;
    overflow: hidden;
    background: radial-gradient(ellipse at 68% 50%, #111d2b 0, #090e19 35%, #070b14 72%);
}

.topbar {
    height: 88px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #ffffff14;
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: white;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 19px;
    font-weight: 700;
    letter-spacing: .13em;
}

.brand-mark {
    color: #b7eece;
    font-size: 28px;
    line-height: 1;
}

.brand-divider {
    width: 1px;
    height: 19px;
    background: #ffffff30;
    margin: 0 8px;
}

.brand-sub {
    font-family: 'DM Sans', sans-serif;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .16em;
    color: #9da8b9;
}

.status-dot {
    display: inline-block;
    flex: none;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #b7eece;
    box-shadow: 0 0 10px #b7eece99;
}

.layout {
    display: grid;
    grid-template-columns: minmax(340px, .82fr) minmax(0, 1.18fr);
    align-items: center;
    flex: 1;
    gap: 5%;
    max-width: 1600px;
    width: 100%;
    margin: 0 auto;
    padding: 54px 0;
}

.step-view {
    display: none;
}

.step-view.is-active {
    display: block;
}

.layout.step-view.is-active {
    display: grid;
}

.step-label {
    margin: 0 0 20px;
    color: #8290a1;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .15em;
}

.step-label span,
.step-next > span {
    color: #b7eece;
}

.intro {
    max-width: 510px;
}

.eyebrow, .footnote, .scene-label, .scene-hint, .planet-kicker {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .16em;
}

.eyebrow {
    color: #b7eece;
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 25px;
}

.eyebrow-line {
    display: inline-block;
    width: 24px;
    height: 1px;
    background: #b7eece;
}

h1 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(52px, 5.5vw, 84px);
    font-weight: 500;
    letter-spacing: -.065em;
    line-height: 1.02;
    margin: 0;
}

h1 em {
    font-style: normal;
    color: #b7eece;
}

.intro-copy {
    color: #98a5b7;
    font-size: 15px;
    line-height: 1.8;
    max-width: 370px;
    margin: 24px 0 49px;
}

.lunar-brief {
    padding: 18px 20px;
    border: 1px solid #b7eece40;
    border-radius: 5px;
    background: #b7eece0a;
}

.lunar-brief span {
    display: block;
    margin-bottom: 10px;
    color: #b7eece;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .16em;
}

.lunar-brief strong {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 17px;
    font-weight: 500;
}

.lunar-brief p {
    margin: 6px 0 0;
    color: #98a5b7;
    font-size: 12px;
    line-height: 1.5;
}

.lunar-brief .mission-stages {
    margin: 14px 0 0;
    padding: 12px 0 0;
    border-top: 1px solid #b7eece26;
    list-style: none;
    counter-reset: stage;
    display: grid;
    gap: 7px;
}

.mission-stages li {
    counter-increment: stage;
    display: flex;
    align-items: baseline;
    gap: 10px;
    color: #d5dde8;
    font-size: 12px;
    line-height: 1.35;
}

.mission-stages li::before {
    content: "0" counter(stage);
    color: #b7eece;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .08em;
}

.lunar-brief .mission-meta {
    margin-top: 13px;
    color: #b7eece;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .16em;
}

.footnote {
    color: #667587;
    margin: 37px 0 0;
}

.footnote span {
    color: #b7eece;
    margin-right: 7px;
}

.step-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 44px;
    padding: 0 16px;
    border: 1px solid #b7eece70;
    border-radius: 4px;
    background: #b7eece0a;
    color: #b7eece;
    cursor: pointer;
    font: inherit;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .14em;
    transition: background .2s, border-color .2s, color .2s;
}

.step-button:hover:not(:disabled) {
    border-color: #b7eece;
    background: #b7eece18;
    color: #e0ffec;
}

.intro > .step-button {
    margin-top: 20px;
}

.step-button:disabled {
    border-color: #ffffff20;
    background: #ffffff05;
    color: #667587;
    cursor: not-allowed;
}

.step-back {
    margin: 0 0 22px;
    padding: 0;
    border: 0;
    background: none;
    color: #98a5b7;
    cursor: pointer;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .12em;
}

.step-back:hover {
    color: #b7eece;
}

.rocket-config {
    width: 100%;
    max-width: 1600px;
    margin: 0 auto;
    padding: 38px 0 72px;
    border-top: 1px solid #ffffff14;
}

.rocket-config.is-active {
    min-height: calc(100vh - 89px);
}

.launch-step.is-active {
    position: fixed;
    inset: 0;
    z-index: 50;
    padding: 0;
    overflow: hidden;
    background: #050914;
}

.launch-step .flight-panel,
.launch-step .flight-scene {
    width: 100%;
    height: 100%;
}

.launch-step .flight-panel {
    border: 0;
    border-radius: 0;
}

.launch-step .flight-topline,
.launch-step .flight-bottomline {
    position: absolute;
    z-index: 2;
    left: 0;
    right: 0;
    pointer-events: none;
}

.launch-step .flight-topline {
    top: 0;
}

.launch-step .flight-bottomline {
    bottom: 0;
    border: 0;
}

.launch-step .flight-location {
    bottom: 60px;
}

.flight-handoff-fade {
    position: fixed;
    inset: 0;
    z-index: 3;
    background: #000;
    opacity: 0;
    pointer-events: none;
    transition: opacity .65s ease;
}

.launch-step.is-transitioning .flight-handoff-fade {
    opacity: 1;
}

.launch-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 30px;
    margin-bottom: 28px;
}

.launch-heading .eyebrow {
    margin-bottom: 17px;
}

.launch-heading h2 {
    margin: 0;
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(38px, 5vw, 68px);
    font-weight: 500;
    letter-spacing: -.06em;
    line-height: 1.02;
}

.launch-heading h2 em {
    color: #b7eece;
    font-style: normal;
}

.launch-heading > p {
    max-width: 330px;
    margin: 0 0 5px;
    color: #98a5b7;
    font-size: 13px;
    line-height: 1.8;
}

.flight-panel {
    overflow: hidden;
    border: 1px solid #ffffff1b;
    border-radius: 7px;
    background: linear-gradient(155deg, #0d1b2b, #070b14 75%);
}

.flight-topline,
.flight-bottomline {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    color: #8092a7;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .13em;
}

.flight-topline > span:first-child {
    display: flex;
    align-items: center;
    gap: 9px;
    color: #c4d2d7;
}

.flight-scene {
    position: relative;
    height: clamp(300px, 43vw, 480px);
    overflow: hidden;
    background:
        radial-gradient(ellipse at 18% 55%, #1b436733, transparent 30%),
        radial-gradient(ellipse at 85% 50%, #8d929c22, transparent 20%),
        radial-gradient(ellipse at 50% 50%, #0d1b2b, #050914 75%);
}

.flight-scene canvas {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
}

.flight-location {
    position: absolute;
    z-index: 1;
    bottom: 24px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #a7b7c8;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .15em;
    pointer-events: none;
}

.flight-location span {
    color: #b7eece;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 16px;
}

.earth-location {
    left: 5%;
}

.moon-location {
    right: 5%;
}

.flight-scene-status {
    position: absolute;
    top: 50%;
    left: 10%;
    right: 10%;
    z-index: 1;
    margin: 0;
    color: #aab8c7;
    font-size: 13px;
    text-align: center;
    pointer-events: none;
}

.flight-scene-status:empty {
    display: none;
}

.flight-bottomline {
    border-top: 1px solid #ffffff12;
}

#flight-status {
    color: #b7eece;
}

.flight-progress {
    height: 3px;
    background: #ffffff10;
}

.flight-progress span {
    display: block;
    width: 0;
    height: 100%;
    background: linear-gradient(90deg, #60b6da, #b7eece);
    box-shadow: 0 0 10px #b7eece88;
    transition: width .15s linear;
}

.launch-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-top: 24px;
}

.launch-actions p {
    margin: 0;
    color: #708094;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .13em;
}

.launch-action-buttons {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.flight-next-hint {
    margin: 12px 0 0;
    color: #8290a1;
    font-size: 11px;
    text-align: right;
}

/* Surface exploration: the game fills the window and the rest of the page is hidden. */
body.is-playing,
body.is-in-flight {
    overflow: hidden;
}

body.is-playing .topbar,
body.is-in-flight .topbar {
    display: none;
}

.playground-step.is-active {
    position: fixed;
    inset: 0;
    z-index: 50;
    background: #000;
    overflow: hidden;
    user-select: none;
    -webkit-user-select: none;
    -webkit-touch-callout: none;
}

.playground-scene {
    position: absolute;
    inset: 0;
    overflow: hidden;
    background: #000;
    touch-action: none;
}

.playground-scene {
    cursor: grab;
}

.playground-scene.is-dragging {
    cursor: grabbing;
}

.playground-scene canvas {
    display: block;
    width: 100%;
    height: 100%;
}

.pg-hud {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: max(16px, env(safe-area-inset-top)) max(18px, env(safe-area-inset-right)) max(18px, env(safe-area-inset-bottom)) max(18px, env(safe-area-inset-left));
    pointer-events: none;
    color: #f5f7fc;
    text-shadow: 0 1px 3px #000c;
}

.pg-hud [hidden] {
    display: none !important;
}

.pg-hud button {
    pointer-events: auto;
}

.pg-top {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
}

.pg-location,
.pg-mission {
    padding: 10px 14px;
    border: 1px solid #ffffff24;
    border-radius: 6px;
    background: #070b14b8;
    backdrop-filter: blur(6px);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .13em;
}

.pg-location strong {
    display: flex;
    align-items: center;
    gap: 7px;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 13px;
    letter-spacing: .14em;
}

.pg-location > span {
    display: block;
    margin-top: 5px;
    color: #a9b6c7;
}

.pg-mission {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #a9b6c7;
    white-space: nowrap;
}

.pg-mission strong {
    padding-left: 10px;
    border-left: 1px solid #ffffff24;
    color: #b7eece;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 14px;
    font-variant-numeric: tabular-nums;
    letter-spacing: .04em;
    white-space: nowrap;
}

.pg-pips {
    display: flex;
    gap: 5px;
}

.pg-pips i {
    width: 11px;
    height: 11px;
    border: 1.5px solid #b7eece;
    border-radius: 2px;
    transform: rotate(45deg);
    transition: background .25s, box-shadow .25s;
}

.pg-pips i.is-found {
    background: #b7eece;
    box-shadow: 0 0 10px #b7eecea0;
}

.pg-pips i.is-current {
    background: #b7eece59;
}

/* Stage briefings and facts share the look of the information signs. */
.pg-card {
    max-width: min(480px, 100%);
    background: #070b14e6;
}

.pg-card strong {
    font-size: clamp(18px, 4vw, 23px);
}

.pg-card p {
    font-size: 13px;
}

/* Shown while a task needs the camera pointed at something in the sky. */
.pg-reticle {
    position: absolute;
    top: 50%;
    left: 50%;
    /* About 6.5 degrees of the view around its centre: what counts as on target. */
    width: min(22vh, 44vw);
    height: min(22vh, 44vw);
    transform: translate(-50%, -50%);
    border: 2px dashed #ffffffb0;
    border-radius: 50%;
    transition: border-color .15s, box-shadow .15s;
}

.pg-reticle::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 6px;
    height: 6px;
    margin: -3px 0 0 -3px;
    border-radius: 50%;
    background: #ffffffd0;
}

.pg-reticle.is-locked {
    border: 2px solid #b7eece;
    box-shadow: 0 0 22px #b7eece90, inset 0 0 14px #b7eece50;
}

.pg-reticle.is-locked::after {
    background: #b7eece;
}

.pg-prompt {
    min-width: min(300px, 80vw);
    padding: 9px 14px 10px;
    border: 1px solid #b7eece80;
    border-radius: 6px;
    background: #070b14d9;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .12em;
}

.pg-progress {
    height: 5px;
    margin-top: 8px;
    border-radius: 3px;
    background: #ffffff24;
    overflow: hidden;
}

.pg-progress i {
    display: block;
    width: 0;
    height: 100%;
    border-radius: 3px;
    background: #b7eece;
    box-shadow: 0 0 10px #b7eecea0;
}

.pg-carry {
    margin: 0;
    padding: 4px 10px;
    border-radius: 999px;
    background: #b7eece;
    color: #070b14;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .13em;
    text-shadow: none;
}

.pg-stage-title {
    margin: 2px 0 -4px;
    color: #b7eece;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .18em;
}

.pg-sign {
    margin-top: 14px;
    max-width: min(420px, 100%);
    padding: 12px 18px 14px;
    border: 1px solid #b7eece80;
    border-radius: 6px;
    background: #070b14d9;
    text-align: center;
}

.pg-sign span {
    display: block;
    color: #b7eece;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .18em;
}

.pg-sign strong {
    display: block;
    margin: 4px 0 6px;
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(22px, 5vw, 30px);
    font-weight: 600;
}

.pg-sign p {
    margin: 2px 0 0;
    color: #c3d0de;
    font-size: 12px;
    line-height: 1.45;
}

.pg-bottom {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 9px;
    text-align: center;
}

.pg-compass {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 6px 13px 6px 8px;
    border: 1px solid #ffffff24;
    border-radius: 999px;
    background: #070b14b8;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .12em;
    font-variant-numeric: tabular-nums;
}

.pg-compass-arrow {
    display: grid;
    place-items: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #b7eece;
    color: #070b14;
    font-size: 15px;
    line-height: 1;
    text-shadow: none;
    transition: transform .12s linear;
}

.pg-objective {
    margin: 0;
    padding: 0 8px;
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(12px, 2.6vw, 15px);
    font-weight: 600;
    letter-spacing: .12em;
}

.pg-board {
    box-shadow: 0 0 26px #b7eece55;
    text-shadow: none;
}

.pg-board kbd {
    margin-left: 6px;
    padding: 2px 6px;
    border: 1px solid currentColor;
    border-radius: 3px;
    font: inherit;
    font-size: .85em;
    opacity: .75;
}

.pg-keys {
    margin: 0;
    color: #a9b6c7;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .13em;
}

/* Nothing to steer during the landing and take-off cutscenes. */
.pg-hud:not([data-phase="play"]) .pg-keys,
.pg-hud:not([data-phase="play"]) .pg-stage-title,
.pg-hud:not([data-phase="play"]) .movement-controls,
.pg-hud:not([data-phase="play"]) .move-jump,
.pg-hud:not([data-phase="play"]) .move-action {
    visibility: hidden;
}

/* On-screen controls: only on touch devices. A keyboard uses WASD / arrows, Space and E. */
.movement-controls,
.move-jump,
.move-action {
    display: none;
}

.move-button {
    border: 1px solid #b7eece80;
    border-radius: 10px;
    background: #070b1499;
    color: #b7eece;
    cursor: pointer;
    font-size: 24px;
    touch-action: none;
    user-select: none;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.move-button:active {
    border-color: #b7eece;
    background: #b7eece40;
}

.move-up { grid-column: 2; grid-row: 1; }
.move-button[data-move="left"] { grid-column: 1; grid-row: 2; }
.move-button[data-move="backward"] { grid-column: 2; grid-row: 2; }
.move-button[data-move="right"] { grid-column: 3; grid-row: 2; }
.move-sprint {
    grid-column: 3;
    grid-row: 1;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .1em;
}
.move-sprint[aria-pressed="true"] {
    border-color: #b7eece;
    background: #b7eece40;
}

@media (hover: none), (pointer: coarse) {
    .movement-controls {
        position: absolute;
        left: max(16px, env(safe-area-inset-left));
        bottom: max(18px, env(safe-area-inset-bottom));
        display: grid;
        grid-template-columns: repeat(3, 58px);
        grid-auto-rows: 58px;
        gap: 6px;
    }
    .move-jump {
        position: absolute;
        right: max(18px, env(safe-area-inset-right));
        bottom: max(30px, env(safe-area-inset-bottom));
        display: block;
        width: 92px;
        height: 92px;
        border-radius: 50%;
        font-size: 13px;
        font-weight: 700;
        letter-spacing: .1em;
    }
    .move-action {
        position: absolute;
        /* Stacked above the jump button, within reach of the same thumb. */
        right: max(27px, calc(env(safe-area-inset-right) + 9px));
        bottom: calc(max(30px, env(safe-area-inset-bottom)) + 104px);
        display: block;
        width: 74px;
        height: 74px;
        border-radius: 50%;
        font-size: 13px;
        font-weight: 700;
        letter-spacing: .1em;
    }
    .pg-keys,
    .pg-board kbd {
        display: none;
    }
    /* Keep the centred messages clear of the thumbs. */
    .pg-bottom {
        margin-bottom: 218px;
    }
}

@media (hover: none) and (orientation: landscape), (pointer: coarse) and (orientation: landscape) {
    .pg-bottom {
        margin-bottom: 0;
        max-width: calc(100% - 420px);
    }
}

.pg-fade {
    position: absolute;
    inset: 0;
    background: #000;
    opacity: 0;
    pointer-events: none;
    transition: opacity .9s ease;
}

.pg-fade.is-dark {
    opacity: 1;
}

.pg-fade.is-instant {
    transition: none;
}

@media (prefers-reduced-motion: reduce) {
    .flight-handoff-fade,
    .pg-fade {
        transition: none;
    }
}

#playground-status {
    z-index: 1;
}

.rocket-intro {
    margin-bottom: 30px;
}

.rocket-intro .eyebrow {
    margin-bottom: 16px;
}

.rocket-intro h2 {
    margin: 0;
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(36px, 4vw, 58px);
    font-weight: 500;
    letter-spacing: -.055em;
    line-height: 1.05;
}

.rocket-intro h2 em {
    color: #b7eece;
    font-style: normal;
}

.rocket-intro > p:last-child {
    max-width: 540px;
    color: #98a5b7;
    font-size: 14px;
    line-height: 1.7;
    margin: 14px 0 0;
}

.rocket-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(230px, .5fr) minmax(300px, .7fr);
    align-items: start;
    gap: 24px;
}

.rocket-options,
.rocket-stack,
.rocket-telemetry {
    border: 1px solid #ffffff16;
    border-radius: 6px;
    background: #ffffff04;
    padding: 22px;
}

.rocket-group {
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
}

.rocket-group + .rocket-group {
    margin-top: 25px;
}

.rocket-group legend {
    padding: 0;
    color: #8e9aac;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .16em;
}

.rocket-module-list {
    display: grid;
    gap: 7px;
    margin-top: 12px;
}

.rocket-module {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 62px;
    padding: 10px 12px;
    border: 1px solid #ffffff12;
    border-radius: 5px;
    background: #ffffff04;
    cursor: pointer;
    transition: background .2s, border-color .2s;
}

.rocket-module:hover,
.rocket-module:has(input:checked) {
    border-color: #b7eece80;
    background: #b7eece0a;
}

.rocket-module input {
    flex: none;
    width: 16px;
    height: 16px;
    accent-color: #b7eece;
}

.module-copy {
    display: block;
    min-width: 0;
    flex: 1;
}

.module-copy strong,
.module-copy small {
    display: block;
}

.module-copy strong {
    color: #edf2f8;
    font-size: 12px;
    font-weight: 600;
}

.module-copy small {
    margin-top: 4px;
    color: #8290a1;
    font-size: 10px;
    line-height: 1.4;
}

.module-cost {
    flex: none;
    color: #b7eece;
    font-size: 10px;
    text-align: right;
    white-space: nowrap;
}

.rocket-base {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin: 22px 0 0;
    color: #667587;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .1em;
}

.rocket-base span {
    color: #98a5b7;
    font-weight: 500;
    letter-spacing: normal;
    white-space: nowrap;
}

.rocket-telemetry {
    position: sticky;
    top: 20px;
}

.telemetry-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-bottom: 17px;
    border-bottom: 1px solid #ffffff14;
}

.telemetry-heading .planet-kicker {
    margin: 0 0 7px;
}

.telemetry-heading h3 {
    margin: 0;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 20px;
    font-weight: 500;
}

.reset-modules {
    border: 1px solid #ffffff24;
    border-radius: 4px;
    padding: 7px 9px;
    background: transparent;
    color: #98a5b7;
    cursor: pointer;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .1em;
}

.reset-modules:hover {
    border-color: #b7eece80;
    color: #b7eece;
}

.rocket-stats {
    display: grid;
    gap: 16px;
    padding-top: 18px;
}

.rocket-stat-label {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 7px;
}

.rocket-stat-label span {
    color: #8e9aac;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .11em;
}

.rocket-stat-label strong {
    color: #edf2f8;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 11px;
    font-weight: 500;
    text-align: right;
}

.rocket-meter {
    height: 5px;
    overflow: hidden;
    border-radius: 5px;
    background: #ffffff14;
}

.rocket-meter span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #7dca9e, #b7eece);
    transition: width .2s;
}

.rocket-meter span.over {
    background: #e98678;
}

.rocket-meter span.complete {
    background: #b7eece;
}

.rocket-status {
    margin: 19px 0 0;
    padding: 11px;
    border-radius: 4px;
    background: #b7eece0d;
    color: #b7eece;
    font-size: 11px;
    line-height: 1.55;
}

.rocket-status.has-issues {
    background: #e9867812;
    color: #ef9d91;
}

.rocket-target {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin: 18px 0 0;
    color: #8290a1;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .1em;
}

.rocket-target strong {
    color: #edf2f8;
    font-size: 10px;
    letter-spacing: normal;
}

.rocket-stack {
    position: sticky;
    top: 20px;
    display: flex;
    flex-direction: column;
}

.stack-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-bottom: 17px;
    border-bottom: 1px solid #ffffff14;
}

.stack-heading .planet-kicker {
    margin: 0 0 7px;
}

.stack-heading h3 {
    margin: 0;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 20px;
    font-weight: 500;
}

.stack-heading > strong {
    color: #b7eece;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 15px;
    font-weight: 500;
    white-space: nowrap;
}

.stack-hint {
    margin: 14px 0 0;
    color: #8290a1;
    font-size: 11px;
    line-height: 1.5;
}

.rocket-stack-scene {
    position: relative;
    height: clamp(300px, 46vh, 480px);
    margin-top: 10px;
    border-radius: 5px;
    overflow: hidden;
    background: radial-gradient(ellipse at 50% 55%, #1a2e3e 0, #0b1421 55%, transparent 85%);
}

.rocket-stack-scene canvas {
    display: block;
    width: 100%;
    height: 100%;
}

.rocket-stack-status {
    position: absolute;
    inset: 50% 12px auto;
    margin: 0;
    transform: translateY(-50%);
    color: #98a5b7;
    font-size: 11px;
    text-align: center;
}

.rocket-stack-stages {
    display: grid;
    gap: 6px;
    margin: 14px 0 0;
    padding: 0;
    list-style: none;
}

.stack-stage {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border: 1px solid #ffffff10;
    border-radius: 5px;
    color: #667587;
    transition: border-color .2s, background .2s, color .2s;
}

.stack-stage-index {
    flex: none;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 11px;
}

.stack-stage-copy {
    flex: 1;
    min-width: 0;
}

.stack-stage-copy strong,
.stack-stage-copy small {
    display: block;
}

.stack-stage-copy strong {
    font-size: 11px;
    font-weight: 600;
}

.stack-stage-copy em {
    margin-left: 4px;
    color: inherit;
    font-style: normal;
    font-weight: 500;
    opacity: .7;
}

.stack-stage-copy small {
    margin-top: 2px;
    font-size: 9px;
    line-height: 1.4;
}

.stack-stage-state {
    flex: none;
    font-size: 8px;
    font-weight: 700;
    letter-spacing: .12em;
}

.stack-stage.is-next {
    border-color: #ffffff26;
    color: #c8d3e0;
}

.stack-stage.is-ready {
    border-color: #b7eece55;
    background: #b7eece0a;
    color: #b7eece;
}

.stack-stage.is-warning {
    border-color: #e9867866;
    background: #e9867810;
    color: #ef9d91;
}

.explorer {
    position: relative;
    height: min(680px, 68vh);
    min-height: 500px;
    border: 1px solid #ffffff16;
    background: radial-gradient(ellipse at 50% 45%, #1a2e3e 0, #0b1421 47%, #080e19 80%);
    overflow: hidden;
}

.scene {
    position: absolute;
    inset: 0;
}

.scene canvas {
    display: block;
    width: 100%;
    height: 100%;
    touch-action: none;
}

.scene-label {
    position: absolute;
    z-index: 1;
    top: 25px;
    left: 26px;
    display: flex;
    align-items: center;
    gap: 9px;
    color: #c4d2d7;
    pointer-events: none;
}

.scene-label-muted {
    color: #657587;
    margin-left: 2px;
}

.scene-status {
    position: absolute;
    top: 50%;
    left: 10%;
    right: 10%;
    text-align: center;
    color: #aab8c7;
    font-size: 13px;
    pointer-events: none;
}

.scene-status:empty {
    display: none;
}

.scene-hint {
    position: absolute;
    top: 28px;
    right: 26px;
    color: #708094;
    font-size: 9px;
    pointer-events: none;
}

.drag-icon {
    color: #b7eece;
    font-size: 15px;
    vertical-align: middle;
    margin-right: 4px;
}

.hint-divider {
    display: inline-block;
    height: 12px;
    width: 1px;
    background: #ffffff30;
    margin: 0 9px;
    vertical-align: middle;
}

.planet-info {
    position: absolute;
    left: 30px;
    right: 30px;
    bottom: 28px;
    display: flex;
    justify-content: space-between;
    align-items: end;
    pointer-events: none;
}

.planet-kicker {
    color: #b7eece;
    margin: 0 0 9px;
}

.planet-info h2 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 40px;
    font-weight: 500;
    letter-spacing: -.04em;
    line-height: 1;
    margin: 0;
}

.planet-info h2 span {
    color: #b7eece;
}

.planet-info p:last-child {
    color: #91a1b2;
    font-size: 12px;
    margin: 10px 0 0;
}

.step-next {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 16px;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #ffffff14;
}

.step-next > span {
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .13em;
}

.mission-complete.is-active {
    display: grid;
    flex: 1;
    min-height: calc(100vh - 152px);
    place-items: center;
    padding: 48px 0;
}

.completion-content {
    width: min(100%, 760px);
    margin: 0 auto;
    text-align: center;
}

.completion-content h2 {
    margin: 18px 0;
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(44px, 7vw, 82px);
    font-weight: 500;
    letter-spacing: -.065em;
    line-height: .98;
}

.completion-copy {
    max-width: 560px;
    margin: 0 auto;
    color: #98a5b7;
    font-size: 14px;
    line-height: 1.8;
}

.completion-copy span {
    color: #e4f2e9;
}

.completion-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin: 34px 0 26px;
    border: 1px solid #ffffff1b;
    border-radius: 7px;
    background: #ffffff05;
}

.completion-summary > div {
    display: grid;
    gap: 9px;
    padding: 20px 14px;
}

.completion-summary > div + div {
    border-left: 1px solid #ffffff1b;
}

.completion-summary span {
    color: #8290a1;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .13em;
}

.completion-summary strong {
    color: #e6edf2;
    font-size: 13px;
    font-weight: 500;
}

@media (max-width: 1180px) {
    .rocket-layout {
        grid-template-columns: minmax(0, 1fr) minmax(300px, .8fr);
    }
    .rocket-options {
        grid-column: 1;
        grid-row: 1 / span 2;
    }
    .rocket-stack,
    .rocket-telemetry {
        position: static;
        grid-column: 2;
    }
    /* The narrow rocket sits beside its stage list instead of above it. */
    .rocket-stack {
        display: grid;
        grid-template-columns: 120px minmax(0, 1fr);
        column-gap: 14px;
        align-items: center;
    }
    .stack-heading,
    .stack-hint {
        grid-column: 1 / -1;
    }
    .rocket-stack-scene {
        height: 300px;
    }
}

@media (max-width: 800px) {
    .app {
        padding: 0 6%;
    }
    .topbar {
        height: 72px;
    }
    .layout {
        grid-template-columns: 1fr;
        gap: 32px;
        padding: 50px 0;
    }
    .rocket-config {
        padding: 32px 0 56px;
    }
    .rocket-config.is-active {
        min-height: calc(100vh - 73px);
    }
    .launch-step {
        min-height: calc(100vh - 73px);
        padding: 32px 0 52px;
    }
    .launch-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 12px;
    }
    .launch-heading > p {
        max-width: 520px;
    }
    .flight-scene {
        height: 360px;
    }
    .intro {
        max-width: none;
    }
    .intro-copy {
        margin-bottom: 30px;
    }
    .footnote {
        display: none;
    }
    .explorer {
        height: 520px;
        min-height: 0;
    }
    .rocket-layout {
        grid-template-columns: 1fr;
    }
    .rocket-options,
    .rocket-stack,
    .rocket-telemetry {
        grid-column: auto;
        grid-row: auto;
    }
    .rocket-telemetry {
        position: static;
    }
}

@media (max-width: 480px) {
    .brand-sub {
        font-size: 8px;
    }
    h1 {
        font-size: 49px;
    }
    .explorer {
        height: 410px;
    }
    .rocket-options,
    .rocket-stack,
    .rocket-telemetry {
        padding: 16px;
    }
    .rocket-stack {
        grid-template-columns: 96px minmax(0, 1fr);
        column-gap: 10px;
    }
    .rocket-stack-scene {
        height: 260px;
    }
    .rocket-module {
        flex-wrap: wrap;
    }
    .module-cost {
        margin-left: 28px;
        text-align: left;
    }
    .rocket-base {
        flex-direction: column;
        gap: 6px;
    }
    .flight-scene {
        height: 320px;
    }
    .flight-topline,
    .flight-bottomline {
        padding: 13px 12px;
        font-size: 8px;
        letter-spacing: .08em;
    }
    .flight-location {
        bottom: 16px;
        font-size: 8px;
    }
    .launch-actions {
        align-items: flex-start;
        flex-direction: column;
    }
    .flight-next-hint {
        text-align: left;
    }
    .mission-complete.is-active {
        min-height: calc(100vh - 137px);
    }
    .completion-summary {
        grid-template-columns: 1fr;
        text-align: left;
    }
    .completion-summary > div + div {
        border-top: 1px solid #ffffff1b;
        border-left: 0;
    }
    .scene-hint {
        top: auto;
        bottom: 110px;
        left: 30px;
        right: auto;
    }
    .scene-label {
        font-size: 9px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        transition-duration: .01ms !important;
    }
}


/* Destination selector */
.destination-picker { display:flex; gap:10px; margin:22px 0 18px; flex-wrap:wrap; }
.destination-choice { border:1px solid rgba(167,195,220,.32); background:rgba(13,25,42,.72); color:#c8d8e8; padding:12px 18px; border-radius:999px; font:inherit; font-size:.76rem; font-weight:700; letter-spacing:.09em; cursor:pointer; transition:background .2s,border-color .2s,transform .2s; }
.destination-choice:hover { transform:translateY(-2px); border-color:#83c9ec; }
.destination-choice.is-selected { background:rgba(70,151,202,.22); border-color:#78c9f0; color:#fff; box-shadow:0 0 22px rgba(70,151,202,.15); }
.destination-choice:focus-visible { outline:2px solid #9bdcff; outline-offset:3px; }
