* {
  margin: 0;
  padding: 0;
}

body {
  background-color: #f1f2f3;
}

.container {
  box-sizing: border-box;
  max-width: 1560px;
  min-width: 1240px;
  width: 100%;
  margin: 20px auto;
  color: #333;
  line-height: 1.6;
}

.container * {
  box-sizing: border-box;
}

header {
  margin-bottom: 20px;
  text-align: center;
}

header h1 {
  font-size: 2.1rem;
  margin-bottom: 5px;
}

header p {
  font-size: 1rem;
  opacity: 0.9;
  margin: 0 auto;
}

.game-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 25px;
}

.game-info {
  display: flex;
  gap: 20px;
  font-size: 1.2em;
  background-color: #f8f9fa;
  padding: 10px 20px;
  border-radius: 5px;
}

.game-btn {
  padding: 13px 48px;
  font-size: 1em;
  background-color: #3498db;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  transition: background-color 0.3s;
}

.game-btn:hover {
  background-color: #2980b9;
}

.game-container {
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: #fff;
  padding: 25px;
  border-radius: 12px;
  margin-bottom: 25px;
}

.game-box {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 25px;
}

#game-board {
  display: grid;
  grid-template-columns: repeat(16, 50px);
  grid-template-rows: repeat(16, 50px);
  gap: 2px;
  background-color: #bdbdbd;
  padding: 10px;
  border-radius: 5px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.cell {
  width: 50px;
  height: 50px;
  background-color: #e0e0e0;
  display: flex;
  justify-content: center;
  align-items: center;
  font-weight: bold;
  font-size: 16px;
  cursor: pointer;
  user-select: none;
  border-radius: 2px;
  transition: all 0.2s;
}

.cell:hover {
  background-color: #d0d0d0;
}

.cell.revealed {
  background-color: #f5f5f5;
  cursor: default;
}

.cell.mine {
  background-color: #ffebee;
}

.cell.mine.revealed {
  background-color: #ffcdd2;
}

.cell.flagged {
  background-color: #fff3e0;
}

.cell-1 {
  color: #1976D2;
}

.cell-2 {
  color: #388E3C;
}

.cell-3 {
  color: #D32F2F;
}

.cell-4 {
  color: #7B1FA2;
}

.cell-5 {
  color: #FF8F00;
}

.cell-6 {
  color: #0097A7;
}

.cell-7 {
  color: #5D4037;
}

.cell-8 {
  color: #616161;
}

.game-instructions {
  background-color: #fff;
  padding: 20px;
  border-radius: 10px;
  margin-bottom: 25px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.game-instructions h2 {
  margin-top: 0;
  color: #2c3e50;
}

.instructions-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-top: 20px;
}

.instruction-item {
  background-color: #f8f9fa;
  padding: 15px;
  border-radius: 8px;
}

.instruction-item h3 {
  margin-top: 0;
  color: #3498db;
}

.game-features {
  background-color: #fff;
  padding: 20px;
  border-radius: 10px;
  margin-bottom: 30px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.game-features h2 {
  margin-top: 0;
  color: #2c3e50;
}

.game-features ul {
  list-style-type: none;
  padding: 0;
  display: flex;
  gap: 25px;
  margin-top: 20px;
}

.game-features li {
  padding: 8px 0;
  position: relative;
  padding-left: 30px;
}

.game-features li:before {
  content: "✓";
  color: #4CAF50;
  position: absolute;
  left: 0;
}

footer {
  text-align: center;
  color: #7f8c8d;
  font-size: 0.9em;
}

.notice {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background-color: #333;
  color: white;
  padding: 12px 24px;
  border-radius: 5px;
  opacity: 0;
  transition: opacity 0.3s;
  z-index: 1000;
}

.notice.show {
  opacity: 1;
}
