:root {
  --primary-color: #f39200;
  --secondary-color: #ffcc00;
  --accent-color: #e74c3c;
  --light-color: #ecf0f1;
  --dark-color: #2c3e50;
  --success-color: #2ecc71;
  --warning-color: #f39c12;
  --gold-color: #ffd700;
  --silver-color: #c0c0c0;
  --bronze-color: #cd7f32;
  --box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  --border-radius: 8px;
}

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

body {
  font-family: 'Poppins', sans-serif;
  line-height: 1.6;
  color: var(--dark-color);
  background-color: #f5f7fa;
}

.main-header {
  background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
  color: white;
  padding: 1.5rem 0;
  text-align: center;
  box-shadow: var(--box-shadow);
}

.header-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.logo-container {
  margin-bottom: 1rem;
}

.institute-logo {
  max-height: 100px; /* o ajusta al 30% si la quieres más pequeña */
  width: auto;
  display: block;
  margin: 0 auto;
}

.highlight {
  color: var(--accent-color);
}

.subtitle {
  font-size: 0.9rem;
  opacity: 0.9;
}

.results-top-container {
  background: white;
  padding: 1.5rem;
  margin: 1rem auto;
  max-width: 1200px;
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
  text-align: center;
}

.game-stats {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin: 1.5rem auto;
  max-width: 1200px;
  flex-wrap: wrap;
}

.stat-box {
  background: white;
  padding: 0.8rem 1.5rem;
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
}

.game-container {
  display: flex;
  flex-direction: column;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  gap: 2rem;
}

@media (min-width: 768px) {
  .game-container {
      flex-direction: row;
  }
}

.game-area {
  flex: 2;
  background: white;
  padding: 1.5rem;
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
}

.pond-container {
  width: 100%;
  overflow-x: auto;
  padding-bottom: 10px;
}

.pond {
  display: flex;
  min-width: min-content;
  gap: 0.5rem;
  margin: 1.5rem 0;
  justify-content: center;
}

.tile {
  width: 70px;
  height: 70px;
  min-width: 70px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  position: relative;
}

.tile i {
  font-size: 1.8rem;
  color: white;
}

.frog-red {
  background-color: #ff6b6b;
  border: 3px solid #ff5252;
}

.frog-red i {
  transform: scaleX(-1);
}

.frog-blue {
  background-color: #74b9ff;
  border: 3px solid #0984e3;
}

.empty {
  background-color: #dfe6e9;
  border: 3px dashed #b2bec3;
}

.btn {
  padding: 0.8rem 1.5rem;
  border: none;
  border-radius: var(--border-radius);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.reset-btn {
  background-color: var(--dark-color);
  color: white;
}

.whatsapp-btn {
  background-color: #25D366;
  color: white;
}

.leaderboard-btn {
  background-color: var(--secondary-color);
  color: white;
}

.register-btn {
  background-color: var(--accent-color);
  color: white;
}

.leaderboard-section {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.podium {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: 0.5rem;
  margin-top: 1.5rem;
  height: 200px;
}

.podium-place {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  border-radius: var(--border-radius) var(--border-radius) 0 0;
  padding: 1rem 0;
  max-width: 100px;
}

.gold {
  background: linear-gradient(to bottom, var(--gold-color), #e6c200);
  height: 180px;
}

.silver {
  background: linear-gradient(to bottom, var(--silver-color), #a8a8a8);
  height: 140px;
}

.bronze {
  background: linear-gradient(to bottom, var(--bronze-color), #a05a2c);
  height: 120px;
}

.place-number {
  font-size: 1.5rem;
  font-weight: bold;
  color: white;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.player-info {
  margin-top: 1rem;
  font-size: 0.9rem;
  text-align: center;
  color: white;
  text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3);
  word-break: break-word;
}

.full-leaderboard {
  background: white;
  padding: 1.5rem;
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
}

#leaderboard {
  list-style: none;
  margin-top: 1rem;
}

#leaderboard li {
  padding: 0.7rem 0;
  border-bottom: 1px solid #eee;
  display: flex;
  justify-content: space-between;
}

.win-message {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.win-message h2 {
  color: var(--accent-color);
}

.medal {
  font-weight: bold;
  font-size: 1.2rem;
}

.results-actions {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-top: 1rem;
  flex-wrap: wrap;
}

.main-footer {
  background: var(--primary-color);
  color: white;
  padding: 2rem 0;
  margin-top: 3rem;
}

.footer-info {
  align-content: center;
}

@media (max-width: 768px) {
  .pond {
      gap: 0.3rem;
  }
  
  .tile {
      width: 50px;
      height: 50px;
      min-width: 50px;
  }
  
  .podium {
      height: 150px;
  }
  
  .gold {
      height: 130px;
  }
  
  .silver {
      height: 100px;
  }
  
  .bronze {
      height: 80px;
  }
  
  .results-actions {
      flex-direction: column;
      align-items: center;
  }
  
  .btn {
      width: 100%;
  }
}
/*_______________ Footer Optimizado _______________*/

/* Estilo del contenedor principal del footer */
.main-footer {
  background: linear-gradient(135deg, var(--primary-color), #d2222a);
  color: white;
  padding: 2.5rem 0;
  margin-top: 3rem;
  font-size: 0.95rem;
}

/* Contenedor interno con layout de columnas responsive */
.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  height: auto;
  overflow: visible;
}

/* Imagen del logo */
.footer-logo-img {
  max-width: 50%; /* o ajusta al 30% si la quieres más pequeña */
  height: auto;
  display: block;
  margin: 0 auto;
}


.footer-logo-img:hover {
  transform: scale(1.05);
}

/* Sección de información */
.footer-info h3 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  color: var(--light-color);
}

/* Enlaces del footer */
.footer-links {
  display: flex;
  gap: 1rem;
  margin: 1rem 0;
  flex-wrap: wrap;
}

.footer-links a {
  color: white;
  text-decoration: none;
  padding: 0.5rem 1rem;
  border-radius: var(--border-radius);
  background-color: rgba(255, 255, 255, 0.1);
  transition: background-color 0.3s;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.footer-links a:hover {
  background-color: rgba(255, 255, 255, 0.2);
}

/* Redes sociales */
.footer-social {
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
  align-items: flex-start;
}

.footer-social a {
  color: white;
  background-color: rgba(255, 255, 255, 0.1);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s;
}

.footer-social a:hover {
  background-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-3px);
}

/* Créditos al pie */
.credits {
  margin-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 1rem;
  text-align: center;
  font-size: 0.85rem;
}

/* Accesibilidad: etiquetas para elementos expandibles */
[aria-expanded="true"]::after {
  content: ' (abierto)';
}

[aria-expanded="false"]::after {
  content: ' (cerrado)';
}

/* Botones: efectos y accesibilidad */
.btn {
  transition: transform 0.2s, box-shadow 0.2s, opacity 0.2s;
}

.btn:active {
  transform: translateY(1px);
  box-shadow: none;
}

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

/* Accesibilidad de tarjetas */
.tile:focus-visible {
  outline: 3px solid var(--secondary-color);
  outline-offset: 2px;
}

/*______________ Media Queries para móviles pequeños ______________*/
@media (max-width: 480px) {
  .footer-content {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .footer-social {
    justify-content: center;
  }

  .pond {
    gap: 0.2rem;
  }

  .tile {
    width: 40px;
    height: 40px;
    min-width: 40px;
  }
}
