/* Game Page Styles */
.game-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
}

.game-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.game-header h1 {
  font-size: 3.5rem;
  margin-bottom: 0.75rem;
  font-weight: 900;
  letter-spacing: -1px;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.game-header p {
  color: var(--text-secondary);
  font-size: 1.15rem;
}

/* Game Stats */
.game-stats {
  display: flex;
  gap: 1.25rem;
  justify-content: center;
  margin-bottom: 2.5rem;
  flex-wrap: wrap;
}

.stat-box {
  background: linear-gradient(135deg, rgba(36, 45, 66, 0.6) 0%, rgba(30, 37, 54, 0.4) 100%);
  backdrop-filter: blur(20px);
  padding: 1.5rem 2.5rem;
  border-radius: 18px;
  border: 1px solid var(--border-light);
  text-align: center;
  min-width: 160px;
  box-shadow: var(--shadow-md);
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

.stat-box::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--gradient-primary);
}

.stat-box:hover {
  transform: translateY(-5px) scale(1.02);
  box-shadow: var(--glow-orange), var(--shadow-lg);
  border-color: var(--primary-orange);
}

.stat-label {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-bottom: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
}

.stat-value {
  font-size: 2.5rem;
  font-weight: 900;
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -1px;
}

/* Game Canvas */
.game-canvas-wrapper {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 3rem;
  padding: 2rem;
  background: linear-gradient(135deg, rgba(36, 45, 66, 0.6) 0%, rgba(30, 37, 54, 0.4) 100%);
  backdrop-filter: blur(20px);
  border-radius: 28px;
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-xl);
}

#gameCanvas {
  border: 3px solid var(--border-light);
  border-radius: 20px;
  background: linear-gradient(135deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
  cursor: crosshair;
  max-width: 100%;
  height: auto;
  box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.5);
  transition: all var(--transition-base);
}

#gameCanvas:hover {
  border-color: var(--primary-orange);
  box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.5), var(--glow-orange);
}

#startBtn {
  position: absolute;
  z-index: 10;
  left: 42%;
  top: 69%;
  box-shadow: var(--shadow-glow), var(--shadow-xl);
}

/* Game Instructions */
.game-instructions {
  background: var(--card-bg);
  padding: 2.5rem;
  border-radius: 16px;
  border: 1px solid var(--border-color);
  max-width: 700px;
  margin: 0 auto;
  box-shadow: var(--shadow-lg);
}

.game-instructions h3 {
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 1.5rem;
  font-size: 1.4rem;
  font-weight: 600;
}

.game-instructions ul {
  list-style: none;
  padding-left: 0;
}

.game-instructions li {
  padding: 0.85rem 0;
  color: var(--text-secondary);
  position: relative;
  padding-left: 2rem;
  line-height: 1.6;
  font-size: 1.05rem;
}

.game-instructions li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--success-color);
  font-weight: bold;
  font-size: 1.2rem;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(16, 185, 129, 0.1);
  border-radius: 6px;
}

/* Game Over Panel */
.game-over-content {
  max-width: 540px;
}

.game-over-content h2 {
  font-size: 2rem;
  margin-bottom: 2rem;
}

.game-over-stats {
  background: var(--dark-bg);
  padding: 2rem;
  border-radius: 14px;
  margin: 2rem 0;
  border: 1px solid var(--border-color);
}

.stat-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
  border-bottom: 1px solid var(--border-color);
}

.stat-item:last-child {
  border-bottom: none;
}

.stat-item .stat-label {
  color: var(--text-secondary);
  font-size: 1.05rem;
  font-weight: 500;
}

.stat-item .stat-value {
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 700;
  font-size: 1.35rem;
}

.game-over-buttons {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.game-over-buttons .btn {
  width: 100%;
}

/* Reward Popup */
.reward-content {
  max-width: 540px;
  text-align: center;
}

.reward-content h2 {
  font-size: 2.2rem;
  margin-bottom: 1rem;
}

.reward-info {
  margin: 2.5rem 0;
}

.reward-amount-box {
  background: linear-gradient(135deg, rgba(79, 70, 229, 0.25), rgba(6, 182, 212, 0.25));
  padding: 3rem 2rem;
  border-radius: 20px;
  margin-bottom: 2rem;
  border: 1px solid rgba(79, 70, 229, 0.3);
  box-shadow: var(--shadow-xl), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  position: relative;
  overflow: hidden;
}

.reward-amount-box::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(79, 70, 229, 0.2) 0%, transparent 70%);
  animation: pulse 3s ease-in-out infinite;
}

.reward-label {
  color: var(--text-secondary);
  font-size: 1.05rem;
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 600;
  position: relative;
  z-index: 1;
}

.reward-amount {
  font-size: 3.5rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--primary-light), var(--secondary-color), var(--accent-color));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: 0 0 40px rgba(79, 70, 229, 0.5);
  position: relative;
  z-index: 1;
  line-height: 1.2;
}

.reward-details {
  background: var(--dark-bg);
  padding: 1.75rem;
  border-radius: 14px;
  border: 1px solid var(--border-color);
}

.reward-detail-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.85rem 0;
  color: var(--text-secondary);
  font-size: 1.05rem;
}

.reward-detail-item:first-child {
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 1rem;
  margin-bottom: 0.5rem;
}

.reward-detail-item span:last-child {
  color: var(--text-primary);
  font-weight: 600;
}

.reward-detail-item a {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.3s ease;
}

.reward-detail-item a:hover {
  color: var(--primary-light);
  text-decoration: underline;
}

.reward-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.reward-buttons .btn {
  flex: 1;
  min-width: 200px;
}

/* Responsive */
@media (max-width: 768px) {
  .game-header h1 {
    font-size: 2.2rem;
  }

  #gameCanvas {
    width: 100%;
    height: auto;
  }

  .game-stats {
    flex-direction: column;
    align-items: center;
  }

  .stat-box {
    width: 100%;
    max-width: 320px;
  }

  .reward-buttons {
    flex-direction: column;
  }

  .reward-buttons .btn {
    width: 100%;
  }

  .game-over-buttons {
    width: 100%;
  }

  .reward-amount {
    font-size: 2.8rem;
  }

  .game-canvas-wrapper {
    padding: 1rem;
  }
}

@media (max-width: 480px) {
  .game-container {
    padding: 1rem;
  }

  .game-header h1 {
    font-size: 1.8rem;
  }

  .stat-value {
    font-size: 1.8rem;
  }

  .reward-amount-box {
    padding: 2rem 1.5rem;
  }
}