:root {
  color-scheme: dark;
  --background: #19161f;
  --paper: #f3eddf;
  --muted: #aea4b2;
  --lime: #d7ec8a;
  --ink: #302a32;
  --mono: "DejaVu Sans Mono", "Courier New", monospace;
  font-family: system-ui, sans-serif;
  color: var(--paper);
  background: var(--background);
}

* { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(ellipse at 50% 20%, #2c23317d, transparent 70%),
    radial-gradient(circle, #f8e4fa12 1px, transparent 1.4px) 0 0 / 20px 20px,
    var(--background);
}
button { color: inherit; font: inherit; cursor: pointer; }
button:focus-visible { outline: 3px solid #a7a5ff; outline-offset: 4px; }
button, .screen { -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }
kbd { font: inherit; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}

.arcade { max-width: 1176px; margin: auto; padding: 28px 34px 26px; }
.masthead {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #ffffff20;
  padding-bottom: 17px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 7px;
  font: 800 17px var(--mono);
  letter-spacing: .08em;
}
.brand-mark, .model-mark {
  display: inline-block;
  background: currentColor;
  clip-path: polygon(20% 20%, 35% 20%, 35% 5%, 65% 5%, 65% 20%, 80% 20%, 80% 35%, 95% 35%, 95% 65%, 65% 65%, 65% 95%, 35% 95%, 35% 65%, 5% 65%, 5% 35%, 20% 35%);
}
.brand-mark { width: 23px; height: 23px; background: var(--lime); margin-right: 4px; }
.brand-divider { color: var(--lime); }
.sound {
  display: flex;
  align-items: center;
  gap: 9px;
  background: #261f2c;
  border: 1px solid #4f4455;
  border-radius: 6px;
  padding: 7px 10px;
  font-size: 14px;
}
.sound:hover { border-color: #9c8da4; }
.sound-icon { font-size: 19px; line-height: 1; color: var(--lime); }
.sound-state { font: 700 12px var(--mono); color: var(--muted); }
.sound[aria-pressed="true"] .sound-state { color: var(--lime); }

.intro { margin: 31px 0 25px; }
h1 {
  margin: 0;
  font-size: clamp(2.15rem, 5.2vw, 4.65rem);
  font-weight: 900;
  letter-spacing: -.075em;
  line-height: 1;
}
h1 span { color: var(--lime); }
.intro p { margin: 13px 0 0; color: #c6bdcb; font-size: 1rem; line-height: 1.5; }

.console {
  border-radius: 16px;
  color: var(--ink);
  padding: 0 19px 18px;
  background: linear-gradient(155deg, #eee5d9, #d6c6b8);
  border: 1px solid #fff3e4;
  border-bottom-color: #bdad9e;
  box-shadow: inset 0 2px 0 #fff8f1, inset 0 -7px #b5a396, 0 9px 0 #110e15, 0 22px 48px #0e0a12a3;
}
.console-header {
  min-height: 58px;
  padding: 0 6px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.model {
  display: flex;
  align-items: center;
  gap: 9px;
  font: 900 18px var(--mono);
  letter-spacing: -.06em;
}
.model-mark { width: 16px; height: 16px; background: #a73a54; }
.model span:last-child { color: #5e5159; font-size: 11px; letter-spacing: .08em; }
.power { display: flex; align-items: center; gap: 8px; font: 800 12px var(--mono); letter-spacing: .09em; }
.power span { width: 8px; height: 8px; background: #ba2547; border-radius: 50%; box-shadow: inset 0 0 0 1px #77253c, 0 0 6px #cc365b85; }
.console-body { display: grid; grid-template-columns: minmax(0, 1fr) 230px; gap: 17px; }
.bezel {
  background: #2e2932;
  border-radius: 10px;
  border: 1px solid #1b171e;
  box-shadow: inset 0 1px #625667, 0 2px #fbefe4;
  padding: 13px 13px 8px;
  min-width: 0;
}
.screen {
  position: relative;
  isolation: isolate;
  aspect-ratio: 12 / 7;
  background: #241e3d;
  border: 2px solid #14111b;
  overflow: hidden;
  border-radius: 5px;
  color: var(--paper);
}
.screen::after {
  content: "";
  position: absolute;
  z-index: 3;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(transparent 0 3px, #120e2422 3px 4px), radial-gradient(ellipse, transparent 65%, #0c08144f);
}
canvas { width: 100%; height: 100%; display: block; image-rendering: pixelated; }
.bezel-mark { display: flex; justify-content: flex-end; gap: 3px; margin: 7px 2px 0; }
.bezel-mark i { width: 13px; height: 3px; background: #a65067; transform: skew(-25deg); }
.bezel-mark i:nth-child(2) { background: #bf7482; }
.bezel-mark i:nth-child(3) { background: #d3a6a4; }
.hud {
  position: absolute;
  top: 0;
  width: 100%;
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: clamp(10px, 2vw, 20px) clamp(13px, 3vw, 24px) 11px;
  background: linear-gradient(#1b152de6, #1b152d00);
  font-family: var(--mono);
  text-shadow: 0 2px 0 #1c142d;
  z-index: 2;
}
.hud > div { display: grid; gap: 3px; }
.hud > div:last-child { text-align: right; }
.hud span { color: #e2d2e7; font-size: clamp(9px, 1.2vw, 12px); letter-spacing: .06em; }
.hud strong { font-size: clamp(13px, 2vw, 20px); }
.hud .hearts { color: #ff8e9e; letter-spacing: .12em; white-space: pre; }
.game-menu {
  position: absolute;
  inset: 0;
  display: grid;
  align-items: center;
  padding: clamp(16px, 4vw, 48px);
  background: linear-gradient(90deg, #1a142de8, #211832b3 30%, #241b3200 79%);
  z-index: 1;
}
.game-menu-content { margin-top: 5%; }
.game-menu p {
  margin: 0 0 8px;
  color: var(--lime);
  font: 700 clamp(10px, 1.25vw, 14px) var(--mono);
  letter-spacing: .15em;
}
.game-menu h2 {
  margin: 0 0 17px;
  font-size: clamp(1.7rem, 5.2vw, 4.5rem);
  font-weight: 900;
  letter-spacing: -.065em;
  line-height: .94;
  text-shadow: 3px 4px #150f24;
}
.play {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  border: 1px solid #edf8ba;
  border-radius: 4px;
  padding: 8px 11px;
  background: var(--lime);
  color: #232419;
  font-weight: 850;
  box-shadow: 0 4px #7f8e52;
}
.play:hover { background: #edf7ad; }
.play:active { transform: translateY(3px); box-shadow: 0 1px #7f8e52; }
.play kbd { font: 700 11px var(--mono); border: 1px solid #33382162; padding: 2px 4px; border-radius: 2px; }
.notice {
  position: absolute;
  bottom: 8%;
  left: 50%;
  width: max-content;
  max-width: 90%;
  transform: translateX(-50%);
  margin: 0;
  background: #20192f;
  border: 1px solid #c1a8ca;
  padding: 6px 9px;
  color: var(--paper);
  font: 700 clamp(10px, 1.4vw, 14px) var(--mono);
  text-align: center;
}

.controller {
  background: linear-gradient(#ded2c9, #c9b8af);
  border: 1px solid #b2a49d;
  border-radius: 9px;
  box-shadow: inset 0 1px #f4e9e1, 0 1px #f6e8df;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 21px 14px 14px;
  min-width: 0;
}
.vents { display: grid; gap: 6px; }
.vents i { background: #9f8d8a; height: 5px; border-radius: 3px; box-shadow: inset 0 2px #796863, 0 1px #f4e5db; }
.controls h2 { margin: 0 0 13px; font: 800 14px var(--mono); text-transform: uppercase; letter-spacing: .065em; }
.input-panel {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 6px;
  padding: 14px 9px 12px;
  border-radius: 6px;
  color: #f6e7dc;
  background: #332c36;
  box-shadow: inset 0 2px #201922, 0 1px #f1e2d8;
}
.control-group { display: grid; justify-items: center; grid-template-rows: 52px auto auto; align-items: center; gap: 8px; font: 700 10px var(--mono); letter-spacing: .06em; }
.dpad { display: flex; padding: 3px; border-radius: 5px; background: #1c181f; box-shadow: 0 1px #4e4553; }
.dpad button, .jump {
  display: grid;
  place-items: center;
  touch-action: none;
  user-select: none;
  height: 41px;
  border: 1px solid #222026;
  background: linear-gradient(#68606e, #49414e);
  box-shadow: inset 0 1px #827887, 0 3px #151118;
}
.dpad button { width: 41px; font-size: 13px; }
.dpad button:first-child { border-radius: 4px 0 0 4px; }
.dpad button:last-child { border-radius: 0 4px 4px 0; }
.jump {
  width: 45px;
  height: 45px;
  border-radius: 50%;
  background: linear-gradient(#c64f70, #a12e51);
  box-shadow: inset 0 1px #ef89a5, 0 4px #4b1f34;
  color: #fff1f4;
  font: 800 19px var(--mono);
}
.dpad button:hover, .jump:hover { filter: brightness(1.15); }
.dpad button.engaged, .jump.engaged { transform: translateY(2px); box-shadow: inset 0 1px 3px #1e1724; }
.key-label { display: flex; gap: 3px; font-size: 11px; color: #f1dceb; letter-spacing: 0; }
.key-label kbd { border: 1px solid #a18b9e; border-radius: 3px; padding: 2px 4px; }
.start {
  display: flex;
  align-items: center;
  gap: 7px;
  background: #ddcec5;
  border: 1px solid #a48f8c;
  padding: 9px 7px;
  border-radius: 5px;
  box-shadow: 0 1px #f0dfd6;
  font: 900 12px var(--mono);
  letter-spacing: .05em;
}
.start:hover { background: #ecded3; }
.start span { width: 23px; height: 8px; border-radius: 12px; background: #4e4453; box-shadow: inset 0 -2px #251e29; }
.start kbd { margin-left: auto; font-size: 11px; letter-spacing: 0; color: #53454f; }
.footer { display: flex; gap: 12px 24px; flex-wrap: wrap; margin-top: 23px; color: var(--muted); font-size: 13px; }
.footer kbd { padding: 2px 4px; border: 1px solid #625468; border-radius: 3px; color: #e9ddeb; font-family: var(--mono); }

@media (max-width: 790px) {
  .arcade { padding: 20px 17px; }
  .console { padding: 0 11px 13px; }
  .console-header { min-height: 44px; }
  .console-body { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .bezel { padding: 7px 7px 5px; }
  .controller { flex-direction: row; align-items: center; gap: 8px; padding: 8px; }
  .controls { display: flex; align-items: center; gap: 15px; }
  .controls h2 { margin: 0; }
  .input-panel { gap: 10px; padding: 6px 9px; }
  .control-group { grid-template-rows: 48px auto; gap: 3px; }
  .key-label, .vents { display: none; }
}
@media (max-width: 515px) {
  .intro { margin: 22px 0 17px; }
  .intro p { font-size: .91rem; }
  .model span:last-child, .controls h2, .start kbd { display: none; }
  .game-menu h2 { margin-bottom: 10px; }
  .game-menu-content { margin-top: 10%; }
  .play { padding: 4px 8px; font-size: 14px; }
  .play kbd { display: none; }
  .footer { margin-top: 18px; }
}
