/* LIGHTBOX MODAL PARA IMÁGENES */
.lightbox-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.85);
  display: none;
  z-index: 10000;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transition: opacity 0.3s ease-in-out;
}

.lightbox-modal.active {
  display: flex;
  opacity: 1;
}

.lightbox-content {
  position: relative;
  max-width: 95vw;
  max-height: 95vh;
  background: white;
  border-radius: 0px;
  overflow: visible;
  box-shadow: 0 10px 50px rgba(0, 0, 0, 0.3);
  animation: zoomIn 0.3s ease-out;
  display: flex;
  flex-direction: column;
}

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

.lightbox-image {
  max-width: 100%;
  max-height: 88vh;
  display: block;
  object-fit: contain;
  width: 100%;
  height: auto;
  flex: 1;
}

.lightbox-close {
  position: absolute;
  top: 15px;
  right: 15px;
  background: rgba(255, 255, 255, 0.9);
  color: #333;
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  font-size: 38px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  z-index: 10001;
}

.lightbox-close:hover {
  background: white;
  color: #000;
  transform: scale(1.1);
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: transparent !important; /* Eliminado */
  border: none !important;             /* Eliminado */
  border-radius: 0 !important;         /* Eliminado */
  backdrop-filter: none !important;    /* Eliminado */
  /* color: transparent; */
  background: transparent !important;
  color: inherit;
  font-size: 0; /* Oculta cualquier texto dentro del botón */
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  z-index: 10001;
  width: auto;                         /* Libera el tamaño del círculo */
  height: auto;                        /* Libera el tamaño del círculo */
}


/* 2. LIMPIEZA BASE: Vaciamos antes de asignar para evitar duplicados */
.lightbox-nav::before,
.lightbox-nav::after {
  content: "" !important;
}

/* 3. BOTÓN IZQUIERDO: Asigna la comilla abierta solo en el ::before */
.lightbox-nav::before {
  content: '\00AB' !important;
  color: #fff !important;
  font-size: 36px !important;
  line-height: 1 !important;
}

/* 4. BOTÓN DERECHO: Si es el botón 'next', borra el 'before' izquierdo y activa el 'after' derecho */
.lightbox-nav.lightbox-next::before {
  content: "" !important; /* Elimina la comilla doble de la izquierda */
}
.lightbox-nav.lightbox-next::after {
  content: '\00BB' !important; /* Inserta la comilla de la derecha */
  color: #fff !important;
  font-size: 36px !important;
  line-height: 1 !important;
}



.lightbox-nav:hover::before {
  color: #c8102e !important;
}

.lightbox-nav:hover::after {
  color: #c8102e !important;
}

.lightbox-nav:hover {
  transform: translateY(-50%) scale(1.08);
  background: rgba(255, 255, 255, 0);
  border-color: rgba(255, 255, 255, 0);
}

.lightbox-prev {
  left: -65px;
}

.lightbox-next {
  right: -65px;
}

.lightbox-header {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(0, 0, 0, 0);
  padding: 12px 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  z-index: 10001;
}

.lightbox-title {
  margin: 0;
  font-size: 14px;
  font-weight: bold;
  color: #fff;
  text-shadow: 0 0 8px rgba(0, 0, 0, 0.7);
}

.lightbox-counter {
  background: rgba(0, 0, 0, 0.25);
  color: #fff;
  padding: 6px 12px;
  border-radius: 15px;
  font-size: 13px;
  font-weight: bold;
  text-shadow: 0 0 6px rgba(0, 0, 0, 0.5);
}

@media (max-width: 767px) {
  .lightbox-content {
    max-width: 90vw;
    margin-left: auto;
    margin-right: auto;
  }
  .lightbox-nav {
    width: 45px;
    height: 45px;
    font-size: 28px;
  }
  .lightbox-nav::before {
    font-size: 30px;
  }
  .lightbox-prev {
    left: -35px;
  }
  .lightbox-next {
    right: -35px;
  }
  .lightbox-header {
    padding: 10px 12px;
  }
  .lightbox-title {
    font-size: 13px;
  }
}
