:root {
  color-scheme: dark;
  font-family: system-ui, sans-serif;
  color: #f4ede0;
  background: #101823;
}
body { margin: 0; }
main { max-width: 72rem; margin: auto; padding: clamp(1rem, 4vw, 3.5rem); }
header { max-width: 58rem; }
h1 { font-family: Georgia, serif; font-size: clamp(2.15rem, 5vw, 4.25rem); margin: .45rem 0; }
h2 { font-family: Georgia, serif; }
p { line-height: 1.55; }
.eyebrow { font-weight: 700; color: #ebc580; text-transform: uppercase; letter-spacing: .095em; }
a { color: #a9ddff; }
a:hover { color: #fff; }
.links, .controls { display: flex; flex-wrap: wrap; gap: .75rem 1rem; align-items: center; margin: 1rem 0; }
button, .action, select, input {
  font: inherit;
  color: inherit;
  background: #26374b;
  border: 1px solid #5d758d;
  border-radius: .3rem;
  padding: .5rem .75rem;
}
button, .action { cursor: pointer; }
.action { display: inline-block; text-decoration: none; }
button:disabled { opacity: .5; cursor: default; }
:focus-visible { outline: 3px solid #ebc580; outline-offset: 3px; }
.frame { background: #05080c; border: 1px solid #5d758d; }
#game { width: 100%; height: min(68vh, 43rem); min-height: 18rem; }
[hidden] { display: none !important; }
.gallery { padding: 0; list-style: none; display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr)); }
.gallery button { display: grid; gap: .75rem; place-items: center; width: 100%; height: 100%; overflow-wrap: anywhere; }
.gallery img { width: 100%; height: 7rem; object-fit: contain; image-rendering: pixelated; background: #141b23; }
dialog { width: min(80rem, 90vw); max-height: 85vh; background: #192432; color: inherit; border: 1px solid #5d758d; }
dialog::backdrop { background: #05080cbd; }
.image-stage { overflow: auto; background: #0d131b; max-height: 55vh; }
.image-stage img { display: block; image-rendering: pixelated; }
#sprite {
  width: min(8rem, 100%);
  height: auto;
  image-rendering: pixelated;
}
