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

body {
  background-color: #0b0b0c;
  font-family: 'Outfit', sans-serif;
  color: #ffffff;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  overflow: hidden;
}

#game-container {
  position: relative;
  width: 800px;
  height: 450px;
  background-color: #000;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  border-radius: 8px;
  overflow: hidden;
}

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

/* HUD panels */
.hud-panel {
  position: absolute;
  top: 15px;
  background: rgba(20, 20, 25, 0.75);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  padding: 10px 15px;
  z-index: 10;
}

#hud-top-left {
  left: 15px;
  width: 280px;
}

#hud-top-right {
  right: 15px;
  width: 150px;
}

.game-title {
  font-size: 14px;
  font-weight: 800;
  color: #a3e635;
  margin-bottom: 5px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.stats-row {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 5px;
}

.stats-row.vertical {
  flex-direction: column;
  gap: 4px;
}

.power-container {
  margin-top: 8px;
}

.power-label {
  font-size: 10px;
  font-weight: 800;
  color: #f43f5e;
  margin-bottom: 2px;
}

.power-bar-bg {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  overflow: hidden;
}

#power-bar-fill {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, #a3e635, #fbbf24, #f43f5e);
  transition: width 0.05s linear;
}

/* Controls */
#controls-arrows {
  position: absolute;
  bottom: 15px;
  left: 15px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  z-index: 10;
}

.arrow-middle-row {
  display: flex;
  gap: 5px;
}

.ctrl-btn {
  width: 44px;
  height: 44px;
  background: rgba(20, 20, 25, 0.75);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #ffffff;
  font-size: 18px;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: transform 0.1s, background-color 0.1s;
}

.ctrl-btn:active {
  transform: scale(0.9);
  background: #a3e635;
  color: #000;
}

#btn-kick {
  position: absolute;
  bottom: 20px;
  right: 20px;
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: linear-gradient(135deg, #a3e635, #84cc16);
  border: none;
  color: #0b0b0c;
  font-weight: 800;
  font-size: 15px;
  cursor: pointer;
  z-index: 10;
  box-shadow: 0 4px 15px rgba(163, 230, 53, 0.4);
  transition: transform 0.1s, box-shadow 0.1s;
}

#btn-kick:active {
  transform: scale(0.9);
  box-shadow: 0 2px 5px rgba(163, 230, 53, 0.2);
}

/* Overlay */
.overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(18, 18, 20, 0.9);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 20;
  transition: opacity 0.3s;
}

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

#overlay-content {
  text-align: center;
}

#overlay-title {
  font-size: 32px;
  font-weight: 800;
  color: #a3e635;
  margin-bottom: 10px;
  letter-spacing: 2px;
}

#overlay-message {
  font-size: 16px;
  color: #9ca3af;
  margin-bottom: 20px;
}

.action-btn {
  background: #a3e635;
  color: #0b0b0c;
  font-weight: 800;
  padding: 10px 24px;
  border-radius: 6px;
  border: none;
  font-size: 14px;
  cursor: pointer;
  transition: transform 0.1s;
}

.action-btn:hover {
  transform: scale(1.05);
}

/* Toast notification */
.toast {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(0, 0, 0, 0.85);
  border: 2px solid #a3e635;
  color: #a3e635;
  font-size: 40px;
  font-weight: 800;
  padding: 15px 40px;
  border-radius: 10px;
  z-index: 15;
  pointer-events: none;
  letter-spacing: 1px;
}

.toast.hidden {
  display: none;
}

.toast.miss {
  border-color: #f43f5e;
  color: #f43f5e;
}

.toast.save {
  border-color: #fbbf24;
  color: #fbbf24;
}
