:root {
  color-scheme: dark;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #010303;
  color: #e8f2f2;
}
* { box-sizing: border-box; }
html, body, main { margin: 0; width: 100%; height: 100%; overflow: hidden; }
main { position: relative; isolation: isolate; }
#space { position: absolute; inset: 0; background: #010303 center / cover no-repeat; }
#space canvas { display: block; width: 100%; height: 100%; touch-action: none; }
#space canvas:focus-visible { outline: 1px solid #a4d5d3; outline-offset: -4px; }
[data-phase="orbit"] canvas { cursor: grab; }
[data-phase="orbit"] canvas:active { cursor: grabbing; }
#gate {
  position: absolute; inset: 0; z-index: 2;
  display: grid; align-content: center; justify-items: center; gap: clamp(26px, 4vh, 42px);
  background-color: #10151d;
  background-image: radial-gradient(ellipse at 50% 44%, transparent 8%, rgb(4 6 12 / 43%) 100%), url("./cover-grain.png");
  transition: opacity .48s ease;
}
.cover-emblem {
  position: absolute; left: 50%; top: 47%; transform: translate(-50%, -50%);
  width: min(76vw, 61vh, 560px); fill: none; stroke: #afc3c5; stroke-width: .045;
  opacity: .09; pointer-events: none;
}
h1 { position: absolute; left: 50%; top: 47%; transform: translate(-50%, -50%); margin: 0; line-height: 0; }
h1 img { display: block; width: clamp(174px, 17vw, 252px); height: auto; }
button {
  appearance: none; font: inherit; color: inherit; cursor: pointer;
  background: transparent; border: 0; padding: 0;
}
button:focus-visible { outline: 2px solid #a4dfde; outline-offset: 5px; }
#enter {
  position: absolute; bottom: max(8%, env(safe-area-inset-bottom)); left: 50%; transform: translateX(-50%);
  display: inline-flex; align-items: center; justify-content: space-between; gap: 28px;
  min-height: 44px; padding: 0 18px; border: 1px solid #a9cccc68;
  background: #0811147a; font-size: 11px; font-weight: 550; letter-spacing: .19em; text-transform: uppercase;
  transition: background .2s, border-color .2s;
}
#enter:disabled { color: #a6b8b9; cursor: progress; }
#enter:hover:enabled { background: #1a3438ab; border-color: #a9ccccc4; }
.arrow { font-size: 17px; letter-spacing: 0; }
[data-phase="flying"] #gate, [data-phase="orbit"] #gate { opacity: 0; pointer-events: none; }
footer, #flight-controls {
  position: absolute; bottom: max(17px, env(safe-area-inset-bottom));
  right: max(25px, env(safe-area-inset-right)); font-size: 12px; color: #a5b6b6;
}
footer { left: max(25px, env(safe-area-inset-left)); display: flex; align-items: center; justify-content: space-between; gap: 15px; }
footer p { margin: 0; }
footer b { margin: 0 .25em; font-weight: 400; opacity: .65; }
footer button, #skip { min-height: 44px; padding: 0 8px; letter-spacing: .025em; }
footer button:hover, #skip:hover { color: white; }
[hidden], .touch { display: none; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
@media (pointer: coarse) { .mouse { display: none; } .touch { display: inline; } }
@media (max-width: 600px) {

  footer { left: max(12px, env(safe-area-inset-left)); right: max(10px, env(safe-area-inset-right)); font-size: 11px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
