body {
  font-family: 'Segoe UI', sans-serif;
  margin: 0;
  padding: 0;
  background: #1c1c2c;
  color: #ffffff;
  text-align: center;
  overflow-x: hidden;
}

h1, h2 {
  margin-top: 20px;
}

button {
  padding: 12px 20px;
  margin: 12px;
  background: linear-gradient(to right, #3498db, #2980b9);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
  transition: transform 0.2s ease, background 0.3s ease;
}
button:hover {
  transform: scale(1.05);
  background: linear-gradient(to right, #2980b9, #1c6ea4);
}

canvas {
  background: white;
  border: 4px solid #333;
  border-radius: 12px;
  margin-top: 20px;
  box-shadow: 0 6px 20px rgba(0,0,0,0.5);
}

.screen {
  display: none;
  padding: 30px 15px;
}
.screen.active {
  display: block;
}

#rain-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom, #2c3e50, #34495e);
  z-index: -1;
}

/* Coin Animation */
#coin-fly {
  position: absolute;
  top: -50px;
  left: 50%;
  font-size: 32px;
  pointer-events: none;
  opacity: 0;
  transition: transform 1s ease, opacity 1s ease;
}

/* Coin Display */
#coin-display, #coin-display-game, #coin-display-shop {
  font-size: 20px;
  font-weight: bold;
  margin: 10px 0;
}

/* Level Buttons */
.level-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 15px;
}
.level-buttons button {
  margin: 5px;
  min-width: 40px;
  font-weight: bold;
  background: #8e44ad;
}
.level-buttons button:disabled {
  background: #555;
  opacity: 0.5;
}

/* Stars and Scores */
#stars-earned, #star-score, #iq-score {
  font-size: 18px;
  margin-top: 10px;
}
