* { box-sizing: border-box; user-select: none; }
body {
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background: linear-gradient(135deg, #7cd3ff, #b7ffb0);
  margin: 0;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.game-wrapper {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  border: 2px solid rgba(0,0,0,0.15);
  border-radius: 20px;
  box-shadow: 0 0 25px rgba(0,0,0,0.25);
  padding: 25px;
  max-width: 460px;
  width: 90%;
  text-align: center;
  animation: fadeIn 0.5s ease-in-out;
}

header { padding: 10px 0; }
h1 { margin: 10px 0; color: #1d1d1d; font-size: 26px; letter-spacing: 0.5px; }

.menu-bar {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 15px;
}

button {
  background: linear-gradient(135deg, #00c853, #009624);
  color: #fff;
  border: none;
  border-radius: 30px;
  padding: 10px 22px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.25s ease;
  box-shadow: 0 4px 10px rgba(0, 128, 0, 0.3);
}

button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(0, 128, 0, 0.4);
  background: linear-gradient(135deg, #00e676, #00c853);
}

button:active {
  transform: scale(0.97);
  box-shadow: 0 2px 6px rgba(0, 128, 0, 0.25);
}

button#home-btn {
  background: linear-gradient(135deg, #2196f3, #0d47a1);
  box-shadow: 0 4px 10px rgba(33, 150, 243, 0.3);
}

button#home-btn:hover {
  background: linear-gradient(135deg, #42a5f5, #1976d2);
  box-shadow: 0 6px 14px rgba(33, 150, 243, 0.4);
}

button#restart-btn {
  background: linear-gradient(135deg, #ff3d00, #b71c1c);
  box-shadow: 0 4px 10px rgba(255, 61, 0, 0.3);
}

button#restart-btn:hover {
  background: linear-gradient(135deg, #ff5722, #d32f2f);
  box-shadow: 0 6px 14px rgba(255, 61, 0, 0.4);
}

.game-container { max-width: 400px; margin: 0 auto; padding: 10px; }
.scoreboard { font-size: 18px; margin-bottom: 10px; }
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }

.hole {
  background: #5c4033;
  border-radius: 50%;
  aspect-ratio: 1;
  position: relative;
  overflow: hidden;
}

.mole {
  background: url('img/mole.png') center/108% no-repeat;
  position: absolute;
  width: 104%;
  height: 104%;
  left: -2%;
  bottom: -100%;
  transition: bottom 0.18s;
  touch-action: manipulation;
}

.mole.up { bottom: 0; }

.status {
  margin-top: 12px;
  min-height: 28px;
  font-weight: 600;
  color: #1a1a1a;
  font-size: 18px;
}

@media (max-width: 480px) {
  .game-wrapper {
    width: 95%;
    padding: 15px;
  }
  h1 { font-size: 22px; }
  button { padding: 8px 18px; font-size: 15px; }
}

@keyframes fadeIn {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: scale(1); }
}

.scoreboard {
  font-size: 18px;
  margin-bottom: 10px;
  display: flex;
  justify-content: space-between;
  padding: 0 10px;
}

