.mars-page { background: radial-gradient(ellipse at 50% 0%, #211b44, #090b17 68%); color: #fbf1f6; min-height: 100vh; }
.mars-shell { width: min(100% - 24px, 900px); margin-inline: auto; padding-block: 15px 24px; }
.mars-header { display: flex; justify-content: space-between; align-items: center; gap: 18px; }
.mars-header > a { display: inline-flex; padding: 3px 10px; background: #fff3ec; border-radius: 10px; }
.mars-header > a img { mix-blend-mode: multiply; }
.mars-header nav { display: flex; gap: 15px; font-size: .9rem; }
.mars-page .mars-header nav a { display: inline; }
.mars-shell h1 { font-size: clamp(2.6rem, 8vw, 5.6rem); margin: 12px 0 18px; letter-spacing: -.06em; }
.mars-stage { position: relative; overflow: hidden; border: 1px solid #b8b3f24d; border-radius: 20px; background: #090e22; }
#mars-view { display: block; width: 100%; height: auto; }
.mars-phase { position: absolute; top: 10px; left: 10px; border: 1px solid #b5bef959; background: #100f29de; padding: 6px 11px; border-radius: 20px; font-weight: 650; font-size: .875rem; }
.mars-overlay { position: absolute; inset: 0; display: grid; place-items: center; padding: 15px; background: #080a1866; text-align: center; }
.mars-overlay > div { background: #13142beF; border: 1px solid #e3c2ed4d; border-radius: 18px; padding: 16px clamp(14px,4vw,34px); width: min(100%, 440px); }
.mars-overlay h2 { font-size: clamp(1.55rem,5vw,2.95rem); }
.mars-overlay p, #mars-hint { color: #ddd4ee; }
.mars-controls { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 12px; padding: 12px 3px; }
.mars-controls label { display: block; font-weight: 650; }
#mars-meter { display: block; margin-top: 4px; width: min(100%,270px); }
#mars-hint { margin: 5px 0 0; font-size: .9rem; }
.mars-page button { background: #ffc2a0; color: #25182d; cursor: pointer; }
.mars-page button:hover { background: #ffdfcd; }
.mars-page button:disabled { opacity: .6; cursor: default; }
@media (max-width: 510px) {
  #mars-view { min-height: 245px; }
  .mars-controls { grid-template-columns: 1fr; }
  .mars-controls button { justify-self: start; }
}
.mars-page #mars-action.landing-window:enabled { background: #a6f1b4; }

.mission-steps { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 6px; list-style: none; padding: 0; margin: 0 0 9px; }
.mission-steps li { padding: 6px 3px; color: #ddd4ee; border-bottom: 2px solid #c8b8f43f; text-align: center; font-size: .875rem; }
.mission-steps li[aria-current] { color: #ffe0c4; border-color: #f8a776; }
.mars-command { display: grid; gap: 6px; align-items: center; }
#mars-telemetry { color: #ffe0c4; font-variant-numeric: tabular-nums; font-size: .9rem; }
.cargo-selector { min-width: 0; margin: 10px 0 0; padding: 12px; border: 1px solid #b8b3f24d; border-radius: 16px; }
.cargo-selector legend { padding-inline: 8px; font-weight: 700; }
.cargo-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 8px; }
.cargo-option { position: relative; }
.cargo-option input { position: absolute; opacity: 0; }
.cargo-option span { display: grid; gap: 5px; place-items: center; min-width: 0; padding: 7px 2px; background: #25223a; border: 1px solid #756487; border-radius: 12px; cursor: pointer; font-size: .9rem; }
.cargo-option input:checked + span { background: #4a3147; border-color: #ffc2a0; }
.cargo-option input:focus-visible + span { outline: 3px solid #ffc2a0; outline-offset: 2px; }
.cargo-option input:disabled + span { cursor: default; }
.cargo-option img { width: auto; height: 62px; object-fit: contain; }
.cargo-packages { margin-top: 9px; }
.cargo-packages summary { cursor: pointer; color: #f6d6c6; padding: 6px 0; }
.cargo-packages div { display: flex; gap: 10px; }
.cargo-packages img { width: min(46%,180px); height: auto; border-radius: 10px; }
.landing-steering { display: flex; gap: 8px; }
.landing-steering button { touch-action: none; min-height: 44px; padding: 6px 13px; border: 1px solid #d3bad26b; border-radius: 20px; background: #332443; color: #fff0e4; font: inherit; }
.landing-steering button:hover, .landing-steering button:active { background: #533a62; }

.mars-mark {
  position: absolute;
  right: 10px;
  bottom: 10px;
  box-sizing: content-box;
  width: clamp(56px, 10%, 76px);
  height: auto;
  padding: 5px 7px;
  border-radius: 7px;
  background: #fff4eb;
  pointer-events: none;
}
.cargo-format { display: inline-flex; align-items: center; min-height: 44px; gap: 7px; cursor: pointer; }
.cargo-format input { accent-color: #ffc2a0; }
#orbit-steering button[aria-pressed="true"] { background: #ffc2a0; color: #25182d; }
.mars-sound {
  position: absolute;
  top: 10px;
  right: 10px;
  min-height: 36px;
  padding: 4px 10px;
  border: 1px solid #b5bef959;
  border-radius: 20px;
  font: 650 .875rem system-ui;
}

.mars-page { overflow-anchor: none; }
#mars-action { min-width: 148px; }
#mars-hint { min-height: 3em; }
#mars-telemetry { min-height: 2em; }
