/* Escape Room Game Styles */

/* Game Container */
.escape-room-container {
  min-height: 100vh;
  padding: 2rem 0;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  position: relative;
  overflow: hidden;
}

.escape-room-container::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: 
    radial-gradient(circle at 20% 80%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(255, 193, 7, 0.2) 0%, transparent 50%),
    radial-gradient(circle at 40% 40%, rgba(220, 53, 69, 0.2) 0%, transparent 50%);
  pointer-events: none;
  animation: backgroundFloat 20s ease-in-out infinite;
}

@keyframes backgroundFloat {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  33% { transform: translate(30px, -30px) rotate(120deg); }
  66% { transform: translate(-20px, 20px) rotate(240deg); }
}

/* Game Header */
.game-header {
  position: relative;
  z-index: 2;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  padding: 2rem;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.game-title {
  font-size: 2.5rem;
  font-weight: 800;
  color: #2c3e50;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

.game-subtitle {
  font-size: 1.2rem;
  color: #6c757d;
  margin: 0;
}

/* Game Stats */
.game-stats {
  position: relative;
  z-index: 2;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-radius: 15px;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: all 0.3s ease;
}

.game-stats:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.stat-item {
  padding: 1rem;
  border-radius: 10px;
  transition: all 0.3s ease;
}

.stat-item:hover {
  background: rgba(102, 126, 234, 0.1);
}

.stat-number {
  font-size: 2rem;
  font-weight: 700;
  color: #667eea;
  margin: 0;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.stat-label {
  font-size: 0.9rem;
  color: #6c757d;
  margin: 0;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Game Screens */
.game-screen {
  position: relative;
  z-index: 2;
  animation: fadeIn 0.6s ease;
}

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

/* Welcome Card */
.welcome-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(15px);
  border-radius: 20px;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.2);
  overflow: hidden;
  position: relative;
}

.welcome-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #667eea, #764ba2, #667eea);
  background-size: 200% 100%;
  animation: gradientShift 3s ease infinite;
}

@keyframes gradientShift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.welcome-icon {
  animation: bounce 2s ease infinite;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
  40% { transform: translateY(-10px); }
  60% { transform: translateY(-5px); }
}

.game-flow-info .flow-step {
  padding: 1rem;
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(5px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: all 0.3s ease;
  margin: 0 0.5rem;
}

.game-flow-info .flow-step:hover {
  transform: translateY(-5px);
  background: rgba(255, 255, 255, 0.2);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

/* Question Card */
.question-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(15px);
  border-radius: 20px;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.2);
  overflow: hidden;
  min-height: 500px;
}

.question-card .card-header {
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: white;
  border: none;
  padding: 1.5rem;
}

.timer-display {
  background: rgba(255, 255, 255, 0.2);
  padding: 0.5rem 1rem;
  border-radius: 25px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.progress {
  height: 8px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
  overflow: hidden;
}

.progress-bar {
  background: linear-gradient(90deg, #28a745, #20c997);
  transition: width 0.3s ease;
}

/* Partners Section */
.partners-section {
  position: relative;
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border-top: 1px solid rgba(102, 126, 234, 0.1);
  margin-top: 2rem;
}

.partners-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, #667eea, transparent);
}

.partner-logo {
  padding: 1rem;
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.partner-logo:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
  background: rgba(255, 255, 255, 0.95);
}

.partner-img {
  transition: all 0.3s ease;
  filter: grayscale(20%) opacity(0.8);
}

.partner-logo:hover .partner-img {
  filter: grayscale(0%) opacity(1);
  transform: scale(1.05);
}

@media (max-width: 768px) {
  .partner-logo {
    height: 100px;
    margin-bottom: 1rem;
  }
  
  .partner-img {
    max-height: 60px !important;
  }
}


.progress-bar {
  background: linear-gradient(90deg, #28a745, #20c997);
  transition: width 0.3s ease;
}

/* Question Content */
.question-content {
  margin-bottom: 2rem;
}

.question-text {
  font-size: 1.3rem;
  font-weight: 600;
  color: #2c3e50;
  line-height: 1.6;
}

.question-image img {
  max-height: 200px;
  width: auto;
  margin: 0 auto;
  display: block;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

/* Answer Options */
.answer-options {
  display: grid;
  gap: 1rem;
}

.answer-option {
  background: rgba(255, 255, 255, 0.8);
  border: 2px solid #e9ecef;
  border-radius: 15px;
  padding: 1.5rem;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.answer-option::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
  transition: left 0.5s ease;
}

.answer-option:hover {
  background: rgba(102, 126, 234, 0.1);
  border-color: #667eea;
  transform: translateY(-3px);
  box-shadow: 0 15px 30px rgba(102, 126, 234, 0.2);
}

.answer-option:hover::before {
  left: 100%;
}

.answer-option.correct {
  background: rgba(40, 167, 69, 0.1);
  border-color: #28a745;
  animation: correctPulse 0.6s ease;
}

.answer-option.wrong {
  background: rgba(220, 53, 69, 0.1);
  border-color: #dc3545;
  animation: wrongShake 0.6s ease;
}

.answer-option.disabled {
  opacity: 0.6;
  cursor: not-allowed;
  pointer-events: none;
}

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

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

.answer-text {
  font-size: 1.1rem;
  font-weight: 500;
  color: #495057;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.answer-letter {
  background: #667eea;
  color: white;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.2rem;
  flex-shrink: 0;
}

.answer-option.correct .answer-letter {
  background: #28a745;
}

.answer-option.wrong .answer-letter {
  background: #dc3545;
}

/* Hint Section */
.hint-section {
  animation: slideDown 0.5s ease;
}

@keyframes slideDown {
  from { 
    opacity: 0; 
    max-height: 0; 
    transform: translateY(-20px); 
  }
  to { 
    opacity: 1; 
    max-height: 100px; 
    transform: translateY(0); 
  }
}

/* Question Actions */
.question-actions {
  background: none !important;
  backdrop-filter: none !important;
}

.question-actions .btn {
  border-radius: 25px;
  font-weight: 600;
  padding: 0.75rem 1.5rem;
  transition: all 0.3s ease;
  border: 2px solid;
  background: white;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.question-actions .btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
  background: white;
}

/* Suggerimento Button - Ciano/Azzurro */
.question-actions .btn-outline-info {
  border-color: #20c997 !important;
  color: #20c997 !important;
  background: white !important;
}

.question-actions .btn-outline-info:hover {
  background: #20c997 !important;
  border-color: #20c997 !important;
  color: white !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 20px rgba(32, 201, 151, 0.4) !important;
}

/* Salta Button - Giallo/Arancione */ 
.question-actions .btn-outline-warning {
  border-color: #ffc107 !important;
  color: #ffc107 !important;
  background: white !important;
}

.question-actions .btn-outline-warning:hover {
  background: #ffc107 !important;
  border-color: #ffc107 !important;
  color: #212529 !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 20px rgba(255, 193, 7, 0.4) !important;
}

/* Complete Card */
.complete-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(15px);
  border-radius: 20px;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.2);
  overflow: hidden;
}

.complete-icon {
  animation: zoomIn 0.8s ease;
}

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

.final-stats {
  background: rgba(102, 126, 234, 0.05);
  border-radius: 15px;
  padding: 2rem;
  margin: 2rem 0;
}

.final-stats .stat-item {
  padding: 1rem;
}

.final-stats .stat-number {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
}

/* Complete Actions */
.complete-actions .btn {
  border-radius: 25px;
  font-weight: 600;
  padding: 1rem 2rem;
  font-size: 1.1rem;
  transition: all 0.3s ease;
}

.complete-actions .btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

/* Responsive Design */
@media (max-width: 768px) {
  .game-title {
    font-size: 2rem;
    flex-direction: column;
    gap: 0.5rem;
  }
  
  .stat-number {
    font-size: 1.5rem;
  }
  
  .question-text {
    font-size: 1.1rem;
  }
  
  .answer-text {
    font-size: 1rem;
  }
  
  .answer-letter {
    width: 35px;
    height: 35px;
    font-size: 1rem;
  }
  
  .game-flow-info .flow-step {
    margin: 0.5rem 0;
    padding: 1.5rem;
  }
  
  .complete-actions .btn {
    display: block;
    width: 100%;
    margin-bottom: 1rem;
  }
  
  .final-stats .col-4 {
    margin-bottom: 1rem;
  }
}

/* Animations for game state changes */
.fade-out {
  animation: fadeOut 0.3s ease forwards;
}

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

.slide-in-right {
  animation: slideInRight 0.5s ease forwards;
}

@keyframes slideInRight {
  from { 
    opacity: 0; 
    transform: translateX(100px); 
  }
  to { 
    opacity: 1; 
    transform: translateX(0); 
  }
}

/* Timer animation when time is running out */
.timer-warning {
  animation: timerPulse 1s ease infinite;
}

@keyframes timerPulse {
  0%, 100% { 
    background: rgba(220, 53, 69, 0.2); 
    color: #dc3545; 
  }
  50% { 
    background: rgba(220, 53, 69, 0.4); 
    color: #ffffff; 
  }
}

/* Loading spinner for questions */
.loading-spinner {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid rgba(102, 126, 234, 0.3);
  border-radius: 50%;
  border-top-color: #667eea;
  animation: spin 1s ease-in-out infinite;
}

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

/* Score animation */
.score-animation {
  animation: scoreUp 0.6s ease;
}

@keyframes scoreUp {
  0% { transform: scale(1); }
  50% { transform: scale(1.2); color: #28a745; }
  100% { transform: scale(1); }
}

/* Custom scrollbar for game area */
.escape-room-container::-webkit-scrollbar {
  width: 8px;
}

.escape-room-container::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
}

.escape-room-container::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.3);
  border-radius: 4px;
}

.escape-room-container::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.5);
}

/* ===================
   NEW MINI GAMES STYLES
   =================== */

/* Mini Game Card */
.mini-game-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(15px);
  border-radius: 20px;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.2);
  overflow: hidden;
  min-height: 500px;
  animation: slideInUp 0.6s ease;
}

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

.mini-game-card .card-header {
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: white;
  border: none;
  padding: 1.5rem;
}

/* Enhanced Memory Game */
.memory-enhanced-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(2, 1fr);
  gap: 15px;
  max-width: 400px;
  margin: 0 auto;
  padding: 20px;
}

.memory-enhanced-card {
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, #667eea, #764ba2);
  border-radius: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.4s ease;
  position: relative;
  transform-style: preserve-3d;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  border: 3px solid transparent;
}

.memory-enhanced-card:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 12px 35px rgba(102, 126, 234, 0.3);
}

.memory-enhanced-card.flipped {
  background: white;
  border-color: #667eea;
  transform: rotateY(180deg);
}

.memory-enhanced-card.matched {
  background: linear-gradient(135deg, #28a745, #20c997);
  border-color: #28a745;
  animation: matchSuccess 0.8s ease;
  cursor: default;
}

@keyframes matchSuccess {
  0%, 100% { transform: scale(1); }
  25% { transform: scale(1.1) rotate(5deg); }
  75% { transform: scale(1.1) rotate(-5deg); }
}

.memory-enhanced-card .card-content {
  font-size: 2rem;
  transition: all 0.3s ease;
  opacity: 0;
}

.memory-enhanced-card::before {
  content: '?';
  font-size: 2rem;
  color: white;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.memory-enhanced-card.flipped::before,
.memory-enhanced-card.matched::before {
  display: none;
}

.memory-enhanced-card.flipped .card-content,
.memory-enhanced-card.matched .card-content {
  opacity: 1;
}

.memory-enhanced-card.wrong {
  animation: wrongShake 0.5s ease;
}

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

/* Quick Quiz Game */
.quick-quiz-container {
  max-width: 600px;
  margin: 0 auto;
}

.quiz-progress-bar {
  width: 100%;
  height: 8px;
  background: #e9ecef;
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 2rem;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.quiz-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #28a745, #20c997);
  border-radius: 4px;
  transition: width 0.3s ease;
  position: relative;
}

.quiz-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: progressShimmer 2s infinite;
}

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

.quiz-question {
  font-size: 1.3rem;
  font-weight: 600;
  color: #2c3e50;
  padding: 1.5rem;
  background: rgba(255, 255, 255, 0.9);
  border-radius: 15px;
  margin-bottom: 1.5rem;
  border-left: 4px solid #667eea;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
  animation: questionSlide 0.5s ease;
}

@keyframes questionSlide {
  from { 
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.quiz-options {
  display: grid;
  gap: 12px;
}

.quiz-option {
  background: white;
  border: 2px solid #e9ecef;
  border-radius: 12px;
  padding: 1rem 1.5rem;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1rem;
  font-weight: 500;
  color: #495057;
  position: relative;
  overflow: hidden;
}

.quiz-option::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
  transition: left 0.5s ease;
}

.quiz-option:hover {
  background: rgba(102, 126, 234, 0.1);
  border-color: #667eea;
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(102, 126, 234, 0.2);
}

.quiz-option:hover::before {
  left: 100%;
}

.quiz-option.correct {
  background: rgba(40, 167, 69, 0.1);
  border-color: #28a745;
  animation: correctPulse 0.6s ease;
}

.quiz-option.wrong {
  background: rgba(220, 53, 69, 0.1);
  border-color: #dc3545;
  animation: wrongShake 0.5s ease;
}

.quiz-option.disabled {
  opacity: 0.6;
  cursor: not-allowed;
  pointer-events: none;
}

/* Find the Odd Game */
.find-odd-container {
  max-width: 500px;
  margin: 0 auto;
}

.odd-items {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  padding: 20px;
}

.odd-item {
  width: 120px;
  height: 120px;
  background: white;
  border: 3px solid #e9ecef;
  border-radius: 15px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
  position: relative;
  overflow: hidden;
}

.odd-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(45deg, transparent, rgba(102, 126, 234, 0.1), transparent);
  transform: translateX(-100%);
  transition: transform 0.5s ease;
}

.odd-item:hover {
  transform: translateY(-5px) scale(1.02);
  border-color: #667eea;
  box-shadow: 0 15px 35px rgba(102, 126, 234, 0.2);
}

.odd-item:hover::before {
  transform: translateX(100%);
}

.odd-item.correct {
  border-color: #28a745;
  background: rgba(40, 167, 69, 0.05);
  animation: oddSuccess 0.8s ease;
  pointer-events: none;
}

@keyframes oddSuccess {
  0%, 100% { transform: scale(1); }
  25% { transform: scale(1.1) rotate(3deg); }
  75% { transform: scale(1.1) rotate(-3deg); }
}

.odd-item.wrong {
  border-color: #dc3545;
  background: rgba(220, 53, 69, 0.05);
  animation: wrongPulse 0.5s ease;
}

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

.odd-item-icon {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
  transition: all 0.3s ease;
}

.odd-item-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: #6c757d;
  text-align: center;
  transition: all 0.3s ease;
}

.odd-item:hover .odd-item-icon {
  transform: scale(1.1);
}

.odd-item.correct .odd-item-icon {
  color: #28a745;
}

.odd-item.wrong .odd-item-icon {
  color: #dc3545;
}

/* General Mini Game Animations */
@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

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

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

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

/* Mini Game Complete */
.mini-game-complete {
  padding: 2rem;
  animation: zoomIn 0.6s ease;
}

/* Mobile Responsive for New Mini Games */
@media (max-width: 768px) {
  .flag-puzzle-container {
    max-width: 300px;
  }
  
  .flag-pieces {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
  
  .flag-piece {
    width: 60px;
    height: 45px;
    font-size: 1.4rem;
  }
  
  .flag-target {
    width: 160px;
    height: 120px;
  }
  
  .memory-enhanced-grid {
    grid-template-columns: repeat(3, 1fr);
    max-width: 300px;
  }
  
  .memory-enhanced-card {
    width: 70px;
    height: 70px;
    font-size: 1.5rem;
  }
  
  .odd-items {
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
  }
  
  .odd-item {
    width: 100px;
    height: 100px;
  }
  
  .odd-item-icon {
    font-size: 2rem;
  }
  
  .quiz-question {
    font-size: 1.1rem;
    padding: 1rem;
  }
  
  .quiz-option {
    padding: 0.8rem 1rem;
    font-size: 0.9rem;
  }
}

/* ===================
   SWEETALERT2 & MODAL BUTTON FIXES
   =================== */

/* Fix SweetAlert2 buttons */
.swal2-popup .swal2-actions button {
  background: #667eea !important;
  color: white !important;
  border: none !important;
  border-radius: 25px !important;
  padding: 12px 24px !important;
  font-weight: 600 !important;
  font-size: 16px !important;
  margin: 0 8px !important;
  transition: all 0.3s ease !important;
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3) !important;
  text-transform: none !important;
  min-width: 120px !important;
}

.swal2-popup .swal2-actions button:hover {
  background: #5a67d8 !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 6px 16px rgba(102, 126, 234, 0.4) !important;
}

.swal2-popup .swal2-actions button:active {
  transform: translateY(0) !important;
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3) !important;
}

/* Different button types for SweetAlert2 */
.swal2-popup .swal2-confirm {
  background: #667eea !important;
}

.swal2-popup .swal2-cancel {
  background: #6c757d !important;
}

.swal2-popup .swal2-cancel:hover {
  background: #545b62 !important;
  box-shadow: 0 6px 16px rgba(108, 117, 125, 0.4) !important;
}

/* Success button variant */
.swal2-popup.swal2-success .swal2-confirm {
  background: #28a745 !important;
}

.swal2-popup.swal2-success .swal2-confirm:hover {
  background: #218838 !important;
  box-shadow: 0 6px 16px rgba(40, 167, 69, 0.4) !important;
}

/* Error button variant */
.swal2-popup.swal2-error .swal2-confirm {
  background: #dc3545 !important;
}

.swal2-popup.swal2-error .swal2-confirm:hover {
  background: #c82333 !important;
  box-shadow: 0 6px 16px rgba(220, 53, 69, 0.4) !important;
}

/* Warning button variant */
.swal2-popup.swal2-warning .swal2-confirm {
  background: #ffc107 !important;
  color: #212529 !important;
}

.swal2-popup.swal2-warning .swal2-confirm:hover {
  background: #e0a800 !important;
  box-shadow: 0 6px 16px rgba(255, 193, 7, 0.4) !important;
}

/* Custom game modal class */
.game-modal .swal2-popup {
  border-radius: 20px !important;
  padding: 2rem !important;
}

.game-modal .swal2-title {
  color: #2c3e50 !important;
  font-weight: 700 !important;
  margin-bottom: 1rem !important;
}

.game-modal .swal2-content {
  color: #6c757d !important;
  font-size: 1.1rem !important;
  line-height: 1.6 !important;
}

/* Fix for any unstyled buttons in the game */
.escape-room-container button:not([class*="swal2"]) {
  background: #667eea;
  color: white;
  border: none;
  border-radius: 25px;
  padding: 12px 24px;
  font-weight: 600;
  font-size: 16px;
  transition: all 0.3s ease;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.escape-room-container button:not([class*="swal2"]):hover {
  background: #5a67d8;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(102, 126, 234, 0.4);
}

/* Ensure mini-game complete button has proper styling */
#miniGameComplete .btn {
  background: #667eea !important;
  color: white !important;
  border: none !important;
  border-radius: 25px !important;
  padding: 15px 30px !important;
  font-weight: 600 !important;
  font-size: 1.1rem !important;
  transition: all 0.3s ease !important;
  box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3) !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
}

#miniGameComplete .btn:hover {
  background: #5a67d8 !important;
  transform: translateY(-3px) !important;
  box-shadow: 0 12px 25px rgba(102, 126, 234, 0.4) !important;
}

#miniGameComplete .btn:active {
  transform: translateY(-1px) !important;
}

