body {
  text-align: center;
  background-color: #2c1810;
  font-family: 'MedievalSharp', cursive;
  color: #d4af37;
  line-height: 1.5;
}

.game-container {
  position: absolute;
  margin: auto;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  height: 600px;
  width: 800px;
  background-color: #1a1a1a;
  border-radius: 10px;
  color: #d4af37;
  padding: 20px;
  box-shadow: 0 0 20px rgba(212, 175, 55, 0.3);
  border: 2px solid #d4af37;
  max-width: 95%;
  max-height: 95vh;
  overflow-y: auto;
}

.game-title h1 {
  color: #d4af37;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
  font-size: 2.5em;
  margin-bottom: 20px;
}

.game-text {
  min-height: 200px;
  padding: 20px;
  margin: 20px 0;
  background-color: rgba(0, 0, 0, 0.5);
  border-radius: 5px;
  border: 1px solid #d4af37;
  line-height: 1.6;
}

.game-button {
  color: #d4af37;
  background-color: #2c1810;
  border: 1px solid #d4af37;
  padding: 10px 20px;
  margin: 5px;
  border-radius: 5px;
  cursor: pointer;
  font-family: 'MedievalSharp', cursive;
  transition: all 0.3s ease;
  min-width: 120px;
}

.game-button:hover {
  background-color: #d4af37;
  color: #2c1810;
  transform: scale(1.05);
}

.game-button:focus {
  outline: 2px solid #d4af37;
  outline-offset: 2px;
}

.button-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 20px;
}

/* Loading indicator */
.loading-indicator {
  display: none;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background-color: rgba(0, 0, 0, 0.8);
  padding: 20px;
  border-radius: 5px;
  border: 1px solid #d4af37;
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #d4af37;
  border-top: 4px solid transparent;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 10px;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Help section */
.help-section {
  position: absolute;
  top: 10px;
  right: 10px;
}

.help-button {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background-color: #d4af37;
  color: #2c1810;
  font-weight: bold;
  padding: 0;
  margin: 0;
  min-width: auto;
}

.help-content {
  display: none;
  position: absolute;
  top: 40px;
  right: 0;
  background-color: rgba(0, 0, 0, 0.8);
  padding: 15px;
  border-radius: 5px;
  border: 1px solid #d4af37;
  max-width: 300px;
  text-align: left;
}

.help-content h3 {
  margin-top: 0;
  color: #d4af37;
}

.help-content ul {
  padding-left: 20px;
  margin-bottom: 15px;
}

.close-help {
  background-color: #d4af37;
  color: #2c1810;
  padding: 5px 10px;
  font-size: 0.9em;
}

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
  .game-button {
    transition: none;
  }
  
  .game-button:hover {
    transform: none;
  }

  .loading-spinner {
    animation: none;
    border: 4px solid #d4af37;
  }
}

/* High contrast mode support */
@media (forced-colors: active) {
  .game-button {
    border: 2px solid currentColor;
  }
  
  .game-container {
    border: 2px solid currentColor;
  }
}

/* Focus styles for keyboard navigation */
:focus-visible {
  outline: 2px solid #d4af37;
  outline-offset: 2px;
}

/* Utility Classes */
.hidden {
  display: none !important;
}

.visible {
  display: block !important;
}

.visible-flex {
  display: flex !important;
}
