/* Variables CSS */
:root {
  --color-primary: #667eea;
  --color-primary-hover: #5568d3;
  --color-secondary: #764ba2;
  --color-success: green;
  --color-success-light: #82fed1;
  --color-error: red;
  --color-error-light: #ffa2a2; 
  --color-warning: #f59e0b;
  --color-bg: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --color-surface: #ffffff;
  --color-text: #1f2937;
  --color-text-secondary: #6b7280;
  --color-border: #e5e7eb;
  --color-disabled: #9ca3af;
  --space-xs: 8px;
  --space-sm: 12px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 32px;
  --radius: 12px;
  --radius-lg: 16px;
  --shadow: 0 4px 6px rgba(0, 0, 0, 0.07);
  --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.15);
  --shadow-xl: 0 20px 40px rgba(0, 0, 0, 0.2);
}

/* Reset & Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  padding: var(--space-md);
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
  animation: rotate 30s linear infinite;
  pointer-events: none;
  z-index: 0;
}

/* Animations */
@keyframes rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@keyframes successPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.02); }
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-10px); }
  75% { transform: translateX(10px); }
}

@keyframes shimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes zoomIn {
  from {
    opacity: 0;
    transform: scale(0.5);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes scoreReveal {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.8);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes celebration {
  0%, 100% { transform: scale(1); }
  25% { transform: scale(1.05) rotate(2deg); }
  75% { transform: scale(1.05) rotate(-2deg); }
}

@keyframes popIn {
  0% { transform: scale(0); }
  50% { transform: scale(1.3); }
  100% { transform: scale(1); }
}

/* Layout */
.container {
  max-width: 600px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.screen {
  display: none;
  animation: fadeInUp 0.4s ease-out;
}

.screen.active {
  display: block;
}

/* Cards */
.card {
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  box-shadow: var(--shadow-lg);
  margin-bottom: var(--space-md);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border 0.3s ease;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-xl);
}

.card.feedback-success {
  background: var(--color-success-light);
  border: 5px solid var(--color-success);
  box-shadow: 0 4px 20px rgba(0, 128, 0, 0.4);
}

.card.feedback-error {
  background: var(--color-error-light);
  border: 5px solid var(--color-error);
  box-shadow: 0 4px 20px rgba(255, 0, 0, 0.4);
}

.card-compact {
  padding: var(--space-md);
}

.card-compact h2 {
  font-size: 16px;
  margin-bottom: var(--space-sm);
}

/* Typography */
h1 {
  font-size: 28px;
  margin-bottom: var(--space-md);
  text-align: center;
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 800;
  letter-spacing: -0.5px;
}

h2 {
  font-size: 20px;
  margin-bottom: var(--space-md);
  color: var(--color-text);
}

h3 {
  font-size: 18px;
  margin-bottom: var(--space-sm);
}

/* Tabs */
.tab-buttons {
  display: flex;
  gap: var(--space-sm);
  margin-bottom: var(--space-lg);
}

.tab-btn {
  flex: 1;
  padding: var(--space-sm);
  background: white;
  border: 2px solid rgba(102, 126, 234, 0.3);
  border-radius: var(--radius);
  cursor: pointer;
  font-weight: 600;
  transition: all 0.3s;
  color: var(--color-primary);
}

.tab-btn:hover:not(.active) {
  background: rgba(102, 126, 234, 0.05);
  border-color: var(--color-primary);
}

.tab-btn.active {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
  color: white;
  border-color: transparent;
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

/* Forms */
.auth-form {
  animation: fadeIn 0.3s;
}

.input-group {
  margin-bottom: var(--space-md);
}

label {
  display: block;
  margin-bottom: var(--space-xs);
  font-weight: 600;
  color: var(--color-text);
}

.form-control,
input[type="text"],
input[type="email"],
input[type="password"] {
  width: 100%;
  padding: var(--space-md);
  font-size: 16px;
  border: 2px solid var(--color-border);
  border-radius: var(--radius);
  background: var(--color-surface);
  color: var(--color-text);
  min-height: 44px;
}

.form-control:focus,
input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus {
  outline: none;
  border-color: var(--color-primary);
}

/* Buttons */
.btn {
  display: block;
  width: 100%;
  padding: var(--space-md);
  font-size: 16px;
  font-weight: 600;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 0.3s ease;
  min-height: 48px;
  text-align: center;
  margin-bottom: var(--space-sm);
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.btn-danger {
  background: white;
  border: 2px solid var(--color-error);
  color: var(--color-error);
}

.btn-danger:hover:not(:disabled) {
  background: var(--color-error);
  color: white;
  transform: translateY(-2px);
}

.btn::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.btn:active::before {
  width: 300px;
  height: 300px;
}

.btn-primary {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
  color: white;
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.btn-primary:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(102, 126, 234, 0.5);
}

.btn-success {
  background: linear-gradient(135deg, var(--color-success) 0%, var(--color-success-light) 100%);
  color: white;
  box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
}

.btn-success:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.5);
}

.btn-outline {
  background: white;
  border: 2px solid var(--color-primary);
  color: var(--color-primary);
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.15);
}

.btn-outline:hover:not(:disabled) {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
  color: white;
  border-color: transparent;
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.btn:disabled:not(.btn-option) {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
}

.btn-option:disabled {
  cursor: not-allowed;
  transform: none !important;
}

.btn-sm {
  padding: var(--space-xs) var(--space-md);
  font-size: 14px;
  min-height: auto;
}

.btn-option {
  background: white;
  border: 2px solid var(--color-border);
  color: var(--color-text);
  text-align: left;
  padding: var(--space-md);
  margin-bottom: var(--space-sm);
  font-weight: 500;
  transition: all 0.3s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.btn-option:hover:not(:disabled) {
  border-color: var(--color-primary);
  background: white;
  transform: translateX(5px);
}

.btn-option.correct {
  background: white !important;
  border-color: var(--color-success);
  color: var(--color-success);
  font-weight: 600;
  animation: successPulse 0.5s ease;
}

.btn-option.incorrect {
  background: white !important;
  border-color: var(--color-error);
  color: var(--color-error);
  font-weight: 600;
  animation: shake 0.5s ease;
}

.btn-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-sm);
}

/* Messages */
.error-message {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.15) 0%, rgba(248, 113, 113, 0.15) 100%);
  color: #b91c1c;
  padding: var(--space-md);
  border-radius: var(--radius);
  margin-bottom: var(--space-md);
  display: none;
  border: 2px solid var(--color-error);
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.2);
}

.error-message.show {
  display: block;
  animation: shake 0.5s ease;
}

.feedback {
  padding: var(--space-md);
  border-radius: var(--radius);
  margin-bottom: var(--space-md);
  text-align: center;
  font-weight: 600;
  display: none;
}

.feedback.show {
  display: block;
}

.feedback.success {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.15) 0%, rgba(52, 211, 153, 0.15) 100%);
  color: #047857;
  border: 2px solid var(--color-success);
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2);
}

.feedback.error {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.15) 0%, rgba(248, 113, 113, 0.15) 100%);
  color: #b91c1c;
  border: 2px solid var(--color-error);
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.2);
}

.correct-answer {
  padding: var(--space-md);
  margin-top: var(--space-md);
  margin-bottom: var(--space-md);
  text-align: center;
  font-size: 20px;
  font-weight: 700;
  color: #7f1d1d;
  background: rgba(255, 255, 255, 0.7);
  border-radius: var(--radius);
  border: 2px solid #991b1b;
  display: none;
}

.correct-answer.show {
  display: block;
}

.success-message {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.2) 0%, rgba(52, 211, 153, 0.2) 100%);
  color: var(--color-success);
  padding: var(--space-md);
  border-radius: var(--radius-lg);
  text-align: center;
  font-weight: bold;
  margin-bottom: var(--space-md);
  border: 2px solid var(--color-success);
  animation: celebration 0.6s ease-out;
  box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
}

/* Loading */
.loading-spinner {
  text-align: center;
  padding: var(--space-xl);
}

.spinner {
  width: 40px;
  height: 40px;
  margin: 0 auto var(--space-md);
  border: 4px solid var(--color-border);
  border-top-color: var(--color-primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

/* Menu */
.menu-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--space-md);
  margin-bottom: var(--space-md);
}

.welcome-text {
  color: var(--color-text-secondary);
  margin-top: var(--space-xs);
}

.btn-disconnect {
  padding: var(--space-xs) var(--space-sm);
  font-size: 12px;
  background: white;
  border: 1.5px solid rgba(239, 68, 68, 0.4);
  color: var(--color-error);
  border-radius: var(--radius);
  cursor: pointer;
  font-weight: 600;
  transition: all 0.3s ease;
  min-height: auto;
}

.btn-disconnect:hover {
  background: var(--color-error);
  color: white;
  border-color: var(--color-error);
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3);
}

/* Progress Chart */
#progressChart {
  position: relative;
  width: 100%;
  height: 300px;
  margin-top: var(--space-md);
}

#progressCanvas {
  width: 100%;
  height: 100%;
  max-width: 600px;
  display: block;
  margin: 0 auto;
}

/* Game */
.game-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-md);
  flex-wrap: wrap;
  gap: var(--space-sm);
}

.timer {
  font-size: 24px;
  font-weight: bold;
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  padding: var(--space-sm) var(--space-md);
  background-color: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 2px solid rgba(102, 126, 234, 0.2);
}

.progress-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-md);
  padding: var(--space-md);
  background: white;
  border-radius: var(--radius);
  border: 2px solid rgba(102, 126, 234, 0.2);
  box-shadow: var(--shadow);
  font-weight: 600;
  color: var(--color-text);
}

.progress-bar {
  width: 100%;
  height: 10px;
  background: rgba(229, 231, 235, 0.5);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: var(--space-md);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--color-success) 0%, var(--color-success-light) 100%);
  transition: width 0.5s ease;
  border-radius: 10px;
  position: relative;
  overflow: hidden;
}

.progress-fill::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  animation: shimmer 2s infinite;
}

.country-flag {
  text-align: center;
  margin: var(--space-md) 0 var(--space-sm) 0;
  animation: slideIn 0.5s ease-out;
}

.country-flag img {
  max-width: 200px;
  height: auto;
  border-radius: var(--radius);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  border: 2px solid rgba(102, 126, 234, 0.2);
  transition: transform 0.3s ease;
}

.country-flag img:hover {
  transform: scale(1.05);
}

.country-name {
  font-size: 32px;
  font-weight: 800;
  text-align: center;
  margin: var(--space-sm) 0 var(--space-lg) 0;
  color: #1f2937;
  animation: slideIn 0.5s ease-out;
  text-shadow: 0 0 8px rgba(255, 255, 255, 0.9), 0 0 16px rgba(255, 255, 255, 0.7);
}

.score-indicator {
  display: flex;
  gap: var(--space-xs);
  justify-content: center;
  margin-bottom: var(--space-md);
  flex-wrap: wrap;
}

.score-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--color-border);
  transition: all 0.3s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.score-dot.correct {
  background: linear-gradient(135deg, var(--color-success) 0%, var(--color-success-light) 100%);
  animation: popIn 0.3s ease;
  box-shadow: 0 2px 8px rgba(16, 185, 129, 0.4);
}

.score-dot.incorrect {
  background: linear-gradient(135deg, var(--color-error) 0%, #f87171 100%);
  animation: popIn 0.3s ease;
  box-shadow: 0 2px 8px rgba(239, 68, 68, 0.4);
}

/* Levels */
/* Continent Selection */
.continent-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: var(--space-md);
}

.continent-card {
  border: 2px solid var(--color-border);
  border-radius: var(--radius);
  padding: var(--space-md);
  cursor: pointer;
  transition: all 0.3s ease;
  background: white;
  text-align: center;
  font-weight: 600;
  font-size: 16px;
}

.continent-card:hover {
  border-color: var(--color-primary);
  background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.continent-card.selected {
  border-color: var(--color-primary);
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
  color: white;
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.continent-emoji {
  font-size: 32px;
  display: block;
  margin-bottom: var(--space-xs);
}

.level-card {
  border: 2px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  margin-bottom: var(--space-md);
  cursor: pointer;
  transition: all 0.3s ease;
  background: white;
  position: relative;
  overflow: hidden;
}

.level-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(102, 126, 234, 0.1), transparent);
  transition: left 0.5s ease;
}

.level-card:hover:not(.locked)::before {
  left: 100%;
}

.level-card:hover:not(.locked) {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-xl);
  transform: translateY(-5px) scale(1.02);
}

.level-card.locked {
  opacity: 0.6;
  cursor: not-allowed;
  background: linear-gradient(135deg, rgba(156, 163, 175, 0.1) 0%, rgba(209, 213, 219, 0.1) 100%);
}

.level-card.unlocked {
  border-color: var(--color-success);
  box-shadow: 0 4px 15px rgba(16, 185, 129, 0.2);
}

.level-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-sm);
}

.level-title {
  font-size: 18px;
  font-weight: bold;
}

.level-badge {
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: bold;
}

.badge-locked {
  background: var(--color-disabled);
  color: white;
}

.badge-unlocked {
  background: var(--color-success);
  color: white;
}

/* Stats */
.stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-sm);
  margin-top: var(--space-sm);
}

.stat-item {
  background: white;
  padding: var(--space-md);
  border-radius: var(--radius);
  text-align: center;
  border: 2px solid rgba(102, 126, 234, 0.2);
  box-shadow: var(--shadow);
}

.stat-label {
  font-size: 12px;
  color: var(--color-text-secondary);
  margin-bottom: 4px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.stat-value {
  font-size: 24px;
  font-weight: 900;
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Results */
.result-score {
  text-align: center;
  padding: var(--space-xl);
  animation: zoomIn 0.5s ease-out;
}

.result-score .score {
  font-size: 64px;
  font-weight: 900;
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: var(--space-sm);
  text-shadow: 0 4px 20px rgba(102, 126, 234, 0.3);
  animation: scoreReveal 0.8s ease-out 0.2s both;
}

.result-score .percentage {
  font-size: 28px;
  font-weight: 600;
  background: linear-gradient(135deg, var(--color-success) 0%, var(--color-success-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: scoreReveal 0.8s ease-out 0.4s both;
}

/* History */
.history-item {
  background: white;
  padding: var(--space-md);
  border-radius: var(--radius);
  margin-bottom: var(--space-sm);
  border: 2px solid rgba(102, 126, 234, 0.15);
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
}

.history-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(102, 126, 234, 0.3);
}

.history-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-xs);
}

.history-level {
  font-weight: 800;
  font-size: 14px;
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.history-date {
  font-size: 12px;
  color: var(--color-text-secondary);
}

.history-stats {
  display: flex;
  gap: var(--space-md);
  font-size: 14px;
}

/* Player List */
.player-select {
  position: relative;
}

.player-list {
  max-height: 150px;
  overflow-y: auto;
  border: 2px solid var(--color-border);
  border-radius: var(--radius);
  margin-top: var(--space-sm);
  display: none;
}

.player-list.show {
  display: block;
}

.player-item {
  padding: var(--space-md);
  cursor: pointer;
  border-bottom: 1px solid var(--color-border);
}

.player-item:hover {
  background: var(--color-bg);
}

.player-item:last-child {
  border-bottom: none;
}

/* Errors Review */
.errors-review-card {
  margin-top: var(--space-md);
  padding: var(--space-lg);
  background: white;
  border-radius: var(--radius-lg);
  border: 2px solid rgba(239, 68, 68, 0.3);
  box-shadow: var(--shadow-lg);
}

.errors-review-card h3 {
  color: var(--color-text);
  font-size: 18px;
  font-weight: 800;
  margin-bottom: var(--space-md);
  text-align: center;
}

.errors-list {
  margin-top: var(--space-md);
}

.error-item {
  padding: var(--space-sm);
  margin-bottom: var(--space-xs);
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.08) 0%, rgba(248, 113, 113, 0.08) 100%);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  flex-wrap: wrap;
  border: 1px solid rgba(239, 68, 68, 0.15);
  transition: all 0.3s ease;
}

.error-item:hover {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.12) 0%, rgba(248, 113, 113, 0.12) 100%);
  border-color: rgba(239, 68, 68, 0.3);
  transform: translateX(5px);
}

.error-country {
  font-weight: 700;
  color: var(--color-text);
  font-size: 15px;
}

.error-arrow {
  color: var(--color-error);
  font-weight: 900;
  font-size: 18px;
}

.error-capital {
  font-weight: 700;
  color: var(--color-error);
  font-size: 15px;
}

.error-user-answer {
  font-size: 12px;
  color: var(--color-text-secondary);
  font-style: italic;
  margin-left: var(--space-xs);
}

.perfect-score-card {
  margin-top: var(--space-md);
  padding: var(--space-lg);
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.15) 0%, rgba(52, 211, 153, 0.15) 100%);
  border-radius: var(--radius-lg);
  border: 2px solid var(--color-success);
  text-align: center;
  box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
  animation: celebration 0.6s ease-out;
}

.perfect-score-card h3 {
  font-size: 18px;
  font-weight: 800;
  color: var(--color-success);
  margin-bottom: 0;
}

/* Responsive */
@media (max-width: 480px) {
  /* Hide game header on mobile to save space */
  .game-header {
    display: none;
  }

  /* Reduce card padding on mobile */
  .card {
    padding: var(--space-md);
    margin-bottom: var(--space-sm);
  }

  /* Reduce progress info spacing */
  .progress-info {
    padding: var(--space-sm);
    margin-bottom: var(--space-sm);
    font-size: 14px;
  }

  /* Reduce score indicator spacing */
  .score-indicator {
    margin-bottom: var(--space-sm);
  }

  /* Reduce feedback spacing */
  .feedback {
    padding: var(--space-sm);
    margin-bottom: var(--space-sm);
    font-size: 14px;
  }

  /* Reduce flag size and spacing */
  .country-flag {
    margin: var(--space-sm) 0 var(--space-xs) 0;
  }

  .country-flag img {
    max-width: 120px;
  }

  /* Reduce country name size and spacing */
  .country-name {
    font-size: 22px;
    margin: var(--space-xs) 0 var(--space-md) 0;
  }

  /* Reduce button size */
  .btn-option {
    padding: var(--space-sm);
    margin-bottom: var(--space-xs);
    font-size: 14px;
  }

  /* Reduce input group spacing */
  .input-group {
    margin-bottom: var(--space-sm);
  }

  /* Reduce button grid spacing */
  .btn-grid {
    gap: var(--space-xs);
    margin-top: var(--space-sm);
  }

  .btn-grid .btn {
    padding: var(--space-sm);
    font-size: 14px;
  }

  .error-item {
    gap: var(--space-xs);
  }

  .error-user-answer {
    flex-basis: 100%;
  }
}
