/* Game Section Styles */
.game-section {
  padding: 2rem 0;
}

.game-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.game-info {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.game-status {
  font-size: 1.5rem;
  font-weight: bold;
  color: #333;
}

.win-requirement {
  font-size: 1.1rem;
  color: #666;
}

.game-settings {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.game-button {
  padding: 0.75rem 1.5rem;
  background: #4CAF50;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 1rem;
  transition: background-color 0.2s;
}

.game-button:hover {
  background: #45a049;
}

/* AI Difficulty Selector */
#aiDifficulty {
  padding: 0.75rem 1.5rem;
  background: #2196F3;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 1rem;
  transition: background-color 0.2s;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3e%3cpath d='M7 10l5 5 5-5z'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
  background-size: 1.5rem;
  padding-right: 2.5rem;
}

#aiDifficulty:hover {
  background-color: #1976D2;
}

#aiDifficulty option {
  background: #2196F3;
  color: white;
}

/* Game Board Styles */
.game-board {
  display: grid;
  grid-template-columns: repeat(10, 1fr);
  gap: 2px;
  background: #333;
  padding: 2px;
  border-radius: 5px;
  margin: 0 auto;
  max-width: 800px;
  aspect-ratio: 1;
}

.cell {
  background: #fff;
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: bold;
  cursor: pointer;
  transition: background-color 0.2s;
  position: relative;
}

.cell:hover {
  background: #f0f0f0;
}

.cell.x {
  color: #2196F3;
}

.cell.o {
  color: #F44336;
}

/* Game Stats Styles */
.game-stats {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin-top: 2rem;
  padding: 1rem;
  background: #f5f5f5;
  border-radius: 5px;
}

.stat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.stat-label {
  font-size: 1rem;
  color: #666;
}

.stat-value {
  font-size: 1.5rem;
  font-weight: bold;
  color: #333;
}

/* Responsive Design */
@media (max-width: 768px) {
  .game-board {
    max-width: 100%;
    gap: 1px;
  }

  .cell {
    font-size: 1.2rem;
  }

  .game-controls {
    flex-direction: column;
    align-items: stretch;
  }

  .game-settings {
    justify-content: center;
    flex-wrap: wrap;
  }

  .game-stats {
    flex-direction: column;
    gap: 1rem;
  }

  #aiDifficulty {
    width: 100%;
    text-align: center;
  }
}

/* Animation for placing X and O */
@keyframes placeMark {
  0% {
    transform: scale(0);
    opacity: 0;
  }
  50% {
    transform: scale(1.2);
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.cell.x::before,
.cell.o::before {
  animation: placeMark 0.3s ease-out;
}

/* Win Animation */
@keyframes winHighlight {
  0% {
    background-color: rgba(76, 175, 80, 0.2);
  }
  50% {
    background-color: rgba(76, 175, 80, 0.4);
  }
  100% {
    background-color: rgba(76, 175, 80, 0.2);
  }
}

.cell.win {
  animation: winHighlight 1s infinite;
} 