body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background-color: #121212;
  color: white;
}

a {
  text-decoration: none;
}

#gameCanvas {
  background-color: #1a1a1a;
  border: 2px solid #333;
  border-radius: 10px;
}

.dark-header {
  background-color: #1a1a1a;
  border-bottom: 1px solid #333;
}

.title-text {
  font-weight: 700;
  font-family: "Rajdhani", sans-serif;
  color: #ffffff;
  text-shadow: 0 0 5px rgba(255, 255, 255, 0.3);
}

.icono {
  width: 50px;
}
.title {
  display: flex;
  flex-direction: row; 
    gap: 10px;
  align-items: center;
  justify-content: center; 
}
.dark-nav-link {
  color: #e0e0e0 !important;
  transition: all 0.3s ease;
}

.dark-nav-link:hover {
  color: #ffffff !important;
}
.game-container {
  position: relative;
  display: flex;
  justify-content: center;
  flex-grow: 1;
  padding: 20px;
}

#rondaDisplay {
  margin-right: 30px;
  font-size: 50px;
  height: 90px;
  width: 250px;
  background-color: #1a1a1a;
  border: 2px solid #333;
  color: white;
  padding: 5px 5px;
  border-radius: 5px;
  font-weight: bold;
  text-shadow: 0 0 3px #ffffff;
  z-index: 10;
}

.clasificacion {
  margin-top: 30px;
  margin-left: 30px;
  height: 300px;
  font-size: 30px;
  width: 400px;
  background-color: #1a1a1a;
  border: 2px solid #333;
  color: white;
  padding: 5px 5px;
  border-radius: 5px;
  font-weight: bold;
  z-index: 10;
}
.tabla {
  background-color: #1a1a1a;
  border: 2px solid #333;
  margin-top: 20px;
  font-size: 15px;
  margin-left: auto;
  margin-right: auto;
  width: 300px;
  height: 200px;
}
th,
td {
  border: 2px solid #333;
}

.tabla tbody tr:first-child td {
  text-shadow: 0 0 5px rgba(248, 211, 71, 0.3);
  color: gold;
  font-weight: bold;
}

.tabla tbody tr:nth-child(2) td {
  text-shadow: 0 0 5px rgba(95, 179, 235, 0.3);
  color: rgb(95, 179, 235);
}

.tabla tbody tr:nth-child(3) td {
  text-shadow: 0 0 5px rgba(95, 179, 235, 0.3);
  color: #cd7f32; /* bronze */
}

.tabla tbody tr td {
  color: silver;
}
.puntuacion {
  flex-direction: column;
  align-items: center;
}

.text-puntuacion {
  font-weight: bold;
  margin-right: 30px;
  margin-top: 30px;
  font-size: 30px;
  text-shadow: 0 0 3px #ffffff;
}

#puntuacionDisplay {
  margin-right: 30px;
  font-size: 50px;
  height: 90px;
  width: 250px;
  background-color: #1a1a1a;
  border: 2px solid #333;
  color: white;
  padding: 5px 5px;
  border-radius: 5px;
  font-weight: bold;
  text-shadow: 0 0 3px #ffffff;
  z-index: 10;
}

.ball-speed {
  font-size: 20px;
  margin-top: 30px;
  margin-right: 30px;
  height: 70px;
  width: 250px;
  font-weight: bolder;
}

#gameOverMenu {
  z-index: 999;
  position: absolute;
  display: none;
  background: rgba(26, 26, 26, 0.95);
  color: white;
  font-family: Arial;
  text-align: center;
  padding: 20px;
  border: 2px solid #333;
  border-radius: 10px;
  overflow: auto;
}

#gameOverMenu h1 {
  color: #ff4444;
  text-shadow: 0 0 5px rgba(255, 68, 68, 0.5);
  margin-bottom: 20px;
  font-size: 2.5em;
}

.alert {
  color: #ff4444;
  font-size: 15px;
}

.nameField {
  font-size: 1.2em;
  margin-bottom: 15px;
}

#gameOverMenu input {
  background-color: #1a1a1a;
  border: 2px solid #333;
  color: white;
  padding: 12px;
  width: 80%;
  max-width: 300px;
  border-radius: 5px;
  font-size: 1em;
  margin-bottom: 20px;
  transition: border-color 0.3s;
}

#gameOverMenu input:focus {
  outline: none;
  border-color: #555;
}

#gameOverMenu button {
  background-color: #333;
  color: white;
  border: none;
  padding: 12px 25px;
  margin: 5px;
  border-radius: 5px;
  font-size: 1em;
  cursor: pointer;
  transition: all 0.3s;
}

#gameOverMenu button:hover {
  background-color: #444;
  transform: translateY(-2px);
  box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2);
}

#gameOverMenu button:active {
  transform: translateY(0);
}

@keyframes gameOverAppear {
  0% {
    transform: scale(0.5);
    opacity: 0;
  }
  70% {
    transform: scale(1.02);
    opacity: 1;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

@keyframes fadeInBackground {
  from {
    background-color: rgba(26, 26, 26, 0);
  }
  to {
    background-color: rgba(26, 26, 26, 0.95);
  }
}

#gameOverMenu {
  /* Mantén tus estilos actuales y añade: */
  animation: gameOverAppear 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275)
    forwards;
  opacity: 0; /* Inicia invisible para la animación */
}
