body {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
  margin: 0;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  color: white;
  padding: 20px;
}

#game-container {
  text-align: center;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border-radius: 15px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  padding: 20px;
  max-width: 800px;
  width: 100%;
}

#game-board {
  display: grid;
  gap: 3px;
  margin: 20px auto;
  padding: 10px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.2);
  width: fit-content;
}

.cell {
  width: 40px;
  height: 40px;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  border-radius: 5px;
  transition: all 0.3s ease;
  background: linear-gradient(145deg, #2a5298, #1e3c72);
  box-shadow: 2px 2px 5px rgba(0,0,0,0.2);
  font-weight: bold;
  color: white;
  border: none;
  user-select: none;
}

.cell:hover {
  transform: scale(1.05);
  z-index: 1;
}

.cell.revealed {
  background: linear-gradient(145deg, #3a6bc7, #2a5298);
}

.cell.mine {
  background: linear-gradient(145deg, #ff6b6b, #ee5253);
  animation: explode 0.5s ease-out;
}

.cell.flagged {
  background: linear-gradient(145deg, #ffd93d, #ff9f43);
}

@keyframes explode {
  0% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.2); opacity: 0.8; }
  100% { transform: scale(1); opacity: 1; }
}

button {
  padding: 12px 24px;
  border: none;
  background: linear-gradient(145deg, #3a6bc7, #2a5298);
  color: white;
  border-radius: 25px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 16px;
  margin: 10px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

#game-info {
  display: flex;
  justify-content: space-around;
  margin: 20px 0;
  font-size: 18px;
  flex-wrap: wrap;
}

.number-1 { color: #4834d4; }
.number-2 { color: #2ed573; }
.number-3 { color: #ff6b81; }
.number-4 { color: #5352ed; }
.number-5 { color: #ff4757; }
.number-6 { color: #2ed573; }
.number-7 { color: #ff6b6b; }
.number-8 { color: #5352ed; }

.difficulty-btn {
  padding: 8px 16px;
  font-size: 14px;
}

.difficulty-btn.active {
  background: linear-gradient(145deg, #ffd93d, #ff9f43);
  transform: scale(1.1);
}

.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.modal.show {
  display: flex;
}

.modal-content {
  background: linear-gradient(145deg, #2a5298, #1e3c72);
  padding: 30px;
  border-radius: 15px;
  text-align: center;
  animation: modalShow 0.3s ease-out;
}

@keyframes modalShow {
  from { transform: scale(0.8); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

@media (max-width: 600px) {
  .cell {
    width: 30px;
    height: 30px;
    font-size: 14px;
  }
  
  #game-info {
    font-size: 16px;
  }
  
  button {
    padding: 8px 16px;
    font-size: 14px;
  }
}