* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: #e2e2e8;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #111111;
  padding: 20px;
}

.container {
  max-width: 600px;
  width: 100%;
}

.header {
  text-align: center;
  margin-bottom: 40px;
}

.header h1 {
  font-size: 3rem;
  font-weight: bold;
  margin-bottom: 10px;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.header p {
  font-size: 1.1rem;
  color: #625f5f;
}

.score-display {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-bottom: 40px;
}

.score-card {
  background: rgba(168, 85, 247, 0.1);
  border: 2px solid rgba(168, 85, 247, 0.3);
  border-radius: 12px;
  padding: 10px 20px;
  text-align: center;
}

.score-label {
  font-size: 0.9rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #6a6969;
  margin-bottom: 5px;
}

.score-value {
  font-size: 2rem;
  font-weight: 800;
  color: #a855f7;
}


.game-board {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  max-width: 400px;
  margin: 0 auto 30px;
  justify-items: center;
}


.game-button {
  width: 100%;
  max-width: 160px;
  aspect-ratio: 1;
  border-radius: 12px;
  border: 4px solid;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 0 20px 40px -8px rgba(0, 0, 0, 0.3);
}

.game-button:not(.disabled):hover {
  transform: scale(1.05);
}

.game-button:not(.disabled):active {
  transform: scale(0.95);
}

.game-button.active {
  transform: scale(1.1);
  box-shadow: 0 0 30px rgba(255, 255, 255, 0.5);
}

.game-button.disabled {
  opacity: 0.6;
  cursor: not-allowed;
}


.red {
  background-color: hsl(0, 85%, 60%);
  border-color: hsla(0, 85%, 60%, 0.4);
}
.red.active {
  background-color: hsl(0, 90%, 50%);
  border-color: hsla(0, 90%, 50%, 0.6);
}

.blue {
  background-color: hsl(210, 85%, 55%);
  border-color: hsla(210, 85%, 55%, 0.4);
}
.blue.active {
  background-color: hsl(210, 90%, 45%);
  border-color: hsla(210, 90%, 45%, 0.6);
}

.green {
  background-color: hsl(140, 70%, 50%);
  border-color: hsla(140, 70%, 50%, 0.4);
}
.green.active {
  background-color: hsl(140, 80%, 40%);
  border-color: hsla(140, 80%, 40%, 0.6);
}

.yellow {
  background-color: hsl(50, 95%, 60%);
  border-color: hsla(50, 95%, 60%, 0.4);
}
.yellow.active {
  background-color: hsl(50, 100%, 55%);
  border-color: hsla(50, 100%, 55%, 0.6);
}

.controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.btn {
  padding: 12px 32px;
  font-size: 1rem;
  font-weight: 600;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-primary {
  background-color: #a855f7;
  color: white;
}

.btn-primary:hover {
  background-color: #9333ea;
  transform: translateY(-1px);
}

.btn-ghost {
  background-color: rgb(122, 117, 117);
  color: #494848;
  padding: 8px;
}

.btn-ghost:hover {
  color: #393838;
}

.status-text {
  color: #706e6e;
  font-weight: 500;
  font-size: 1rem;
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(110, 110, 110, 0.7);
  backdrop-filter: blur(4px);
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.modal.open {
  display: flex;
}

.modal-content {
  background: #1e1e30;
  border-radius: 16px;
  padding: 40px;
  max-width: 400px;
  width: 90%;
  text-align: center;
}

.modal-icon {
  width: 64px;
  height: 64px;
  background: rgba(168, 85, 247, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  font-size: 2rem;
}

.modal-title {
  font-size: 1.75rem;
  color: white;
  font-weight: bold;
  margin-bottom: 10px;
}

.modal-description {
  color: #a0a0a0;
  margin-bottom: 30px;
}

.modal-scores {
  display: flex;
  justify-content: center;
  gap: 40px;
  margin-bottom: 30px;
}

.modal-score-item {
  text-align: center;
}

.modal-score-label {
  font-size: 0.875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #a0a0a0;
  margin-bottom: 5px;
}

.modal-score-value {
  font-size: 2.5rem;
  font-weight: 800;
  color: #a855f7;
}

.hidden {
  display: none !important;
}


@media (max-width: 640px) {
  .header h1 {
    font-size: 2rem;
  }

  .score-card {
    padding: 15px 20px;
  }

  .score-value {
    font-size: 2rem;
  }

  .game-board {
    max-width: 300px;
    gap: 12px;
  }

  .game-button {
    max-width: 130px;
  }
}
