* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #000;
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
}
canvas {
  display: block;
  width: 100%;
  height: 100%;
}

#scanlines {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: repeating-linear-gradient(
    0deg,
    rgba(0,0,0,0.15) 0px,
    rgba(0,0,0,0.15) 2px,
    transparent 2px,
    transparent 4px
  );
  pointer-events: none;
  z-index: 15;
}

#titleOverlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(ellipse at center, #1a1a2e 0%, #0a0a0f 100%);
  z-index: 10;
}
#titleOverlay.hidden {
  display: none;
}

#titleContent {
  text-align: center;
  color: #fff;
  text-shadow: 0 0 10px rgba(68,136,255,0.5), 0 0 30px rgba(68,136,255,0.2);
}
#titleText {
  font-family: 'Press Start 2P', monospace;
  font-size: 1.6em;
  letter-spacing: 0.15em;
  margin-bottom: 16px;
  color: #ffd700;
  text-shadow:
    0 0 8px rgba(255,215,0,0.6),
    0 0 20px rgba(255,215,0,0.3),
    2px 2px 0 #8b6914,
    -1px -1px 0 #8b6914;
}
#titleSub {
  font-family: 'Press Start 2P', monospace;
  font-size: 0.55em;
  color: #88aaff;
  margin-bottom: 40px;
  text-shadow: 0 0 6px rgba(68,136,255,0.4);
}
#startButton {
  font-family: 'Press Start 2P', monospace;
  font-size: 0.85em;
  padding: 14px 48px;
  background: #4488ff;
  color: #fff;
  border: 4px solid #2266dd;
  outline: 2px solid #88aaff;
  outline-offset: -6px;
  cursor: pointer;
  letter-spacing: 0.1em;
  text-shadow: 1px 1px 0 #113388;
  box-shadow: 0 0 15px rgba(68,136,255,0.4);
  transition: background 0.1s, box-shadow 0.1s;
}
#startButton:hover {
  background: #5599ff;
  box-shadow: 0 0 25px rgba(68,136,255,0.7);
}
#startButton:active {
  background: #3377ee;
  box-shadow: 0 0 10px rgba(68,136,255,0.3);
}
#soundToggle {
  position: fixed;
  top: 12px;
  right: 12px;
  font-family: 'Press Start 2P', monospace;
  font-size: 0.5em;
  padding: 8px 12px;
  background: #1a1a2e;
  color: #88aaff;
  border: 2px solid #445588;
  cursor: pointer;
  z-index: 20;
  letter-spacing: 0.05em;
  text-shadow: 0 0 4px rgba(68,136,255,0.3);
}
#resetButton {
  position: fixed;
  top: 12px;
  left: 12px;
  font-family: 'Press Start 2P', monospace;
  font-size: 0.5em;
  padding: 8px 12px;
  background: #1a1a2e;
  color: #887777;
  border: 2px solid #554444;
  cursor: pointer;
  z-index: 20;
  letter-spacing: 0.05em;
  text-shadow: 0 0 4px rgba(255,80,80,0.2);
}
#resetButton:hover {
  color: #ff6666;
  border-color: #886666;
}
#potatoLink {
  position: fixed;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  font-family: 'Press Start 2P', monospace;
  font-size: 0.65em;
  color: #cc8800;
  text-decoration: none;
  z-index: 20;
  text-shadow: 0 0 8px rgba(204,136,0,0.3);
  transition: color 0.15s, text-shadow 0.15s;
}
#potatoLink:hover {
  color: #ffaa22;
  text-shadow: 0 0 15px rgba(255,170,34,0.6);
}
