* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body,
html {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #000;
  cursor: none;
  touch-action: manipulation;
}

#screen {
  position: fixed;
  inset: 0;
  background: #000;
  transition: background-color 0.05s;
}

#screen canvas {
  display: block;
  width: 100%;
  height: 100%;
}

#overlay {
  position: fixed;
  inset: 0;
  z-index: 5;
  cursor: default;
  opacity: 0;
  transition: opacity 0.3s;
}

#overlay.visible {
  opacity: 1;
  pointer-events: auto;
}

/* Shortcuts panel */
#shortcuts {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  color: #ccc;
  font: 13px/1.8 sans-serif;
  background: rgba(0, 0, 0, 0.75);
  padding: 12px 20px;
  border-radius: 10px;
  transition: opacity 0.3s;
}

#shortcuts.hidden {
  opacity: 0;
  pointer-events: none;
}

#shortcuts kbd {
  display: inline-block;
  background: #444;
  color: #fff;
  padding: 1px 6px;
  border-radius: 4px;
  font: bold 12px monospace;
  min-width: 22px;
  text-align: center;
  margin-right: 2px;
}

/* Controls bar */
#controls {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  z-index: 10;
  background: rgba(0, 0, 0, 0.7);
  padding: 12px 20px;
  border-radius: 12px;
  transition: opacity 0.3s;
  max-width: 95vw;
}

#controls.hidden {
  opacity: 0;
  pointer-events: none;
}

#controls button {
  padding: 10px 14px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  background: #333;
  color: #fff;
  white-space: nowrap;
}

#controls button:hover {
  background: #555;
}

/* Ad slots */
.ad-slot {
  top: 10%;
  /* transform: translateY(-10%); */
  width: 50%;
  max-width: 300px;
  height: 80%;

  position: fixed;
  z-index: 10;
  background: rgba(30, 30, 30, 0.2);
  color: #666;
  display: flex;
  align-items: center;
  justify-content: center;
  font: 14px sans-serif;
  border-radius: 8px;
  transition: opacity 0.3s;
}

#ad-left {
  left: 20px;
}
#ad-right {
  right: 20px;
}

.ad-slot.hidden {
  opacity: 0;
  pointer-events: none;
}

@media (min-width: 768px) {
  .ad-slot {
  }
}
