/* --- ESTILOS DE LA BARRA DE NAVEGACIÓN PÚBLICA --- */
.navbar.public-navbar {
  padding-top: 1rem;
  padding-bottom: 1rem;
  background-color: #161b22 !important;
  border: none;
}
.navbar.public-navbar .navbar-brand {
  font-weight: 900;
}
.navbar.public-navbar .nav-link {
  font-size: 1rem;
  font-weight: 700;
  color: var(--color-text-secondary);
  transition: all 0.2s ease-in-out;
  border-radius: 6px;
  padding: 0.5rem 1rem;
  margin-left: 0.5rem;
}
.navbar.public-navbar .nav-link:hover,
.navbar.public-navbar .nav-link.active {
  color: var(--color-text-primary);
  background-color: rgba(255, 255, 255, 0.1);
}

/* --- OTROS ESTILOS PÚBLICOS --- */
#search-button {
  margin-left: 8px;
}
.ranking-card {
  position: relative;
  overflow: hidden;
  border-radius: 6px;
  transition: transform 0.2s ease-in-out;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}
.ranking-card:hover {
  transform: scale(1.05);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.4);
}
.ranking-poster {
  width: 100%;
  display: block;
  background-color: #161b22;
}
.ranking-info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 10px;
  background: linear-gradient(
    to top,
    rgba(0, 0, 0, 0.95) 20%,
    rgba(0, 0, 0, 0)
  );
  color: #fff;
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.9);
}
.ranking-title {
  font-weight: bold;
  font-size: 0.9rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
}
.ranking-year {
  font-size: 0.8rem;
  opacity: 0.8;
}

/* --- Estilos del Hero Image --- */
#hero-container {
  position: relative;
  width: 100vw;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  min-height: 400px;
  background-size: cover;
  background-position: center 20%;
  background-repeat: no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-bottom: 2rem;
  transition: background-image 1s ease-in-out;
}
.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    to top,
    rgba(13, 17, 23, 1) 5%,
    rgba(13, 17, 23, 0.5) 50%,
    rgba(13, 17, 23, 1) 95%
  );
}
.hero-content {
  position: relative;
  z-index: 2;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.8);
  padding-top: 3rem;
}
.hero-title {
  color: #fff !important;
  font-weight: 900 !important;
  font-size: 3.5rem;
}
.hero-lead {
  color: #fff !important;
  font-size: 1.25rem;
  font-weight: 400;
}
.main-content {
  padding-top: 4rem;
}

/* --- ESTILOS PARA LA PÁGINA DE DETALLE --- */
.detail-title {
  font-weight: 900;
}
.detail-tagline {
  font-size: 1.2rem;
  color: var(--color-text-secondary);
  margin-top: -0.5rem;
}
.badge.fs-6 {
  padding: 0.5em 0.8em;
  font-weight: 700;
}
.cast-container-detail {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 1.5rem;
}
.cast-member-detail {
  text-align: center;
}
.cast-img {
  width: 100%;
  height: auto;
  aspect-ratio: 2/3;
  object-fit: cover;
  border-radius: 6px;
  margin-bottom: 0.5rem;
  background-color: #30363d;
}
.cast-name {
  display: block;
  font-weight: bold;
}
.cast-character {
  display: block;
  font-size: 0.9rem;
  color: var(--color-text-secondary);
}

/* --- ESTILOS PARA EL WIDGET DE CALIFICACIÓN --- */
.stars {
  font-size: 2rem;
  color: #6c757d; /* Color base de las estrellas (gris) */
  cursor: pointer;
  line-height: 1;
}

.stars a {
  text-decoration: none; /* Quita el subrayado de los enlaces */
  color: inherit; /* Hereda el color del contenedor .stars */
  transition: transform 0.1s ease-in-out;
  display: inline-block; /* Permite aplicar transformaciones */
}

/* Estrella llena (ya votada o en hover) */
.stars a:hover i,
.stars a i.bi-star-fill {
  color: #f5c518; /* Color amarillo IMDb */
}

/* Efecto hover: ilumina todas las estrellas hasta la actual */
.stars:hover a i {
  color: #f5c518;
}

/* Efecto hover: apaga las estrellas que están después de la actual */
.stars a:hover ~ a i {
  color: #6c757d;
}

/* Agranda la estrella específica sobre la que está el cursor */
.stars a:hover {
  transform: scale(1.2);
}

/* --- ESTILOS PARA EL CUADRO DE CALIFICACIÓN TVERSE --- */
.rating-box {
  background-color: #fff;
  color: #6f42c1; /* Violeta de Bootstrap */
  padding: 8px 12px;
  border-radius: 8px;
  text-align: center;
  border: 2px solid #6f42c1;
}
.rating-source {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  line-height: 1;
}
.rating-score {
  font-size: 1.8rem;
  font-weight: 900;
  line-height: 1;
}
.rating-count {
  font-size: 0.7rem;
  line-height: 1;
  opacity: 0.8;
}

/* --- INICIO: NUEVOS ESTILOS PARA LA NAVBAR RESPONSIVE --- */

/* Estilos para pantallas pequeñas (cuando el menú se colapsa) */
@media (max-width: 991.98px) {
  .navbar.public-navbar .navbar-nav {
      align-items: stretch !important;
      padding-top: 1rem;
  }

  .navbar.public-navbar .navbar-nav .nav-item {
      margin-bottom: 0.5rem;
  }

  /* Regla para NUESTRA clase personalizada */
  .navbar.public-navbar .navbar-nav .btn-mobile-nav {
      width: 100%;
      margin-top: 0.5rem;
      margin-left: 0 !important;
      padding: 0.5rem 0.75rem; /* Padding unificado */
      border-width: 1px;      /* Grosor de borde unificado */
  }
  
  /* El botón primario ahora tiene un borde transparente para igualar el tamaño */
  .navbar.public-navbar .navbar-nav .btn-primary.btn-mobile-nav {
      border-color: transparent;
  }
}

/* --- INICIO: NUEVOS ESTILOS PARA EL LOGO --- */
.navbar-logo {
  height: 60px; /* Tu altura deseada */
  width: auto;
  border-radius: 8px; /* Bordes redondeados */
  border: 2px solid rgba(255, 255, 255, 0.1); /* Un borde sutil */
  transition: all 0.3s ease; /* Transición suave para el hover */
  padding: 4px; /* Un pequeño relleno interior */
  background-color: #020418; /* Un fondo muy sutil */
}
.navbar-logo:hover {
  transform: scale(1.05); /* Agranda ligeramente el logo */
  box-shadow: 0 0 15px rgba(0, 169, 255, 0.5); /* Sombra con nuestro azul primario */
  border-color: rgba(0, 169, 255, 0.7); /* El borde se vuelve azul */
}