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

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: #0b0e1a;
  color: #fff;
  font-family: "Segoe UI", system-ui, sans-serif;
  user-select: none;
}

#gameCanvas {
  position: fixed;
  inset: 0;
  display: block;
}

#hud {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  pointer-events: none;
  z-index: 5;
}

#levelLabel {
  font-size: 18px;
  font-weight: 700;
  text-shadow: 0 2px 6px #000a;
  letter-spacing: 1px;
}

#progressBarWrap {
  flex: 1;
  max-width: 420px;
  height: 10px;
  background: #ffffff22;
  border-radius: 5px;
  overflow: hidden;
}

#progressBar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #4cf, #8f4);
  transition: width 0.1s linear;
}

.overlay {
  position: fixed;
  inset: 0;
  background: radial-gradient(#1a2040dd, #070910ee);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  z-index: 10;
  text-align: center;
  padding: 20px;
}

.overlay.hidden { display: none; }

.overlay h1 {
  font-size: 72px;
  letter-spacing: 8px;
  background: linear-gradient(180deg, #8cf, #28e);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 4px 20px #4cf6;
}

.overlay h2 {
  font-size: 44px;
  letter-spacing: 2px;
}

.overlay .tag {
  font-size: 18px;
  color: #9ab;
  letter-spacing: 4px;
  margin-bottom: 10px;
}

.overlay .hint {
  font-size: 14px;
  color: #789;
  margin-top: 14px;
}

.menu-row {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 10px;
}

.menu-btn {
  padding: 12px 28px;
  font-size: 18px;
  font-weight: 600;
  border: 2px solid #4cf;
  background: #4cf2;
  color: #fff;
  border-radius: 8px;
  cursor: pointer;
  min-width: 260px;
  transition: background 0.15s, transform 0.1s;
}

.menu-btn:hover {
  background: #4cf5;
  transform: translateY(-1px);
}

.menu-btn:active {
  transform: translateY(1px);
}
