@font-face {
  font-family: 'ArcadePx';
  src: local('Courier New');
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: #000;
  overflow: hidden;
  font-family: 'Courier New', monospace;
  color: #33ff33;
}

#arcade-cabinet {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  width: 100%;
  padding: 6px;
}

#hud {
  display: flex;
  justify-content: space-between;
  width: 100%;
  max-width: 448px;
  padding: 4px 8px;
  letter-spacing: 2px;
}

.hud-block {
  text-align: center;
}

.hud-label {
  font-size: 10px;
  color: #33ff33;
  text-shadow: 0 0 4px #33ff33;
}

.hud-value {
  font-size: 16px;
  color: #ffffff;
  text-shadow: 0 0 6px #33ff33;
}

#screen-wrap {
  position: relative;
  width: 448px;
  height: 512px;
  max-width: 94vw;
  max-height: 66vh;
  background: #000;
  border: 2px solid #1a1a1a;
  box-shadow: 0 0 30px rgba(51,255,51,0.15) inset, 0 0 12px rgba(0,0,0,0.8);
}

canvas {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  image-rendering: pixelated;
  image-rendering: -moz-crisp-edges;
  image-rendering: crisp-edges;
}

#crt-canvas {
  pointer-events: none;
  mix-blend-mode: normal;
}

#footer-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  max-width: 448px;
  margin-top: 6px;
  padding: 0 8px;
}

#lives-display {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 10px;
}

#lives-icons svg {
  width: 16px;
  height: 12px;
  margin-left: 3px;
  vertical-align: middle;
}

.arcade-btn {
  background: #000;
  color: #33ff33;
  border: 1px solid #33ff33;
  font-family: 'Courier New', monospace;
  font-size: 10px;
  padding: 6px 10px;
  cursor: pointer;
  letter-spacing: 1px;
  text-shadow: 0 0 4px #33ff33;
}

.arcade-btn:active {
  background: #113311;
}

#mobile-controls {
  display: flex;
  justify-content: space-between;
  width: 100%;
  max-width: 448px;
  margin-top: 10px;
  gap: 8px;
}

.mobile-btn {
  flex: 1;
  background: #050505;
  border: 1px solid #33ff33;
  color: #33ff33;
  font-family: 'Courier New', monospace;
  font-size: 18px;
  padding: 14px 0;
  text-shadow: 0 0 4px #33ff33;
  touch-action: manipulation;
}

.mobile-btn:active {
  background: #113311;
}

@media (min-width: 900px) {
  #mobile-controls { display: none; }
}

@media (max-height: 700px) {
  #screen-wrap { max-height: 58vh; }
}
