/* Layout: one centered playfield filling the screen height on phones, buttons laid over it; deliberately one night look (Zecky's night-and-gold), tinted per zone: Earth, Moon, Mars. */
:root {
  --night: #0d0d12;
  --gold: #d6b062;
  --gold-hi: #f1d79a;
  --ink: #f2eee6;
  --muted: #a39d92;
  --line: #2c2934;
  --display: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --ui: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: dark;
}
html, body { height: 100%; }
[hidden] { display: none !important; }
body {
  background: var(--night);
  color: var(--ink);
  font-family: var(--ui);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 10px;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
  padding-top: max(10px, env(safe-area-inset-top, 0px));
  padding-bottom: max(10px, env(safe-area-inset-bottom, 0px));
  box-sizing: border-box;
  overflow: hidden;
  -webkit-user-select: none; user-select: none;
  -webkit-tap-highlight-color: transparent;
}
#stage {
  position: relative;
  height: min(100%, 880px);
  max-height: calc(100% - 30px);
  aspect-ratio: 9 / 16;
  max-width: 100%;
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 0 0 1px var(--line), 0 30px 80px rgba(0,0,0,.6);
  touch-action: none;
  cursor: pointer;
}
#stage:focus-visible { outline: 2px solid var(--gold); outline-offset: 4px; }
canvas { display: block; width: 100%; height: 100%; }
.bar {
  position: absolute; left: 0; right: 0; bottom: 96px;
  display: flex; gap: 10px; justify-content: center; flex-wrap: wrap;
  padding-inline: 16px;
}
.btn {
  font: 600 14px/1 var(--ui);
  padding: 12px 18px; border-radius: 999px;
  border: 1px solid var(--gold); color: var(--night); background: var(--gold);
  cursor: pointer;
}
.btn.ghost { background: rgba(13,13,18,.6); color: var(--gold-hi); }
.btn:focus-visible { outline: 2px solid var(--gold-hi); outline-offset: 3px; }
.snd {
  position: absolute; top: 10px; right: 10px; z-index: 2;
  font: 600 11px/1 var(--ui); padding: 7px 10px; border-radius: 999px;
  border: 1px solid var(--line); background: rgba(13,13,18,.72); color: var(--gold-hi); cursor: pointer;
}
.snd[aria-pressed="false"] { color: var(--muted); }
.snd:focus-visible { outline: 2px solid var(--gold-hi); outline-offset: 2px; }
.hint {
  position: absolute; left: 16px; right: 16px; bottom: 150px;
  font-size: 13px; line-height: 1.45; text-align: center; color: var(--gold-hi);
  background: rgba(13,13,18,.85); border: 1px solid var(--line); border-radius: 14px; padding: 10px 12px;
}
.caption { font-size: 12px; letter-spacing: .04em; color: var(--muted); text-align: center; margin: 0; }
.caption b { color: var(--gold); font-weight: 600; }
.caption a { color: var(--gold); font-weight: 600; text-decoration: none; }
.caption a:hover { text-decoration: underline; }

/* Stream page only (live.html): the Lock it for Mac screen fills the background, always visible. The game sits on the left so the lock stays in view. */
@media (min-width: 900px) {
  html[data-live] body { align-items: flex-start; }
  html[data-live] body::before {
    content: ""; position: fixed; inset: 0; z-index: 0;
    background: url(lockit-mac.webp) center / cover no-repeat;
    pointer-events: none;
  }
  html[data-live] #stage { z-index: 1; }
  html[data-live] .caption { display: none; }   /* it would sit on the picture's status line; the Zecky line is inside the game */
}
