/* ==========================================================================
   LIGHTBOX
   ========================================================================== */

#lb-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(5, 5, 5, 0.96);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

#lb-overlay.lb-active {
  opacity: 1;
  pointer-events: all;
}

.lb-img-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 90vw;
  max-height: 88vh;
}

.lb-img {
  max-width: 88vw;
  max-height: 84vh;
  object-fit: contain;
  border-radius: 6px;
  user-select: none;
  display: block;
  transition: opacity 0.18s ease;
}

.lb-img.lb-loading { opacity: 0.3; }

.lb-btn {
  position: absolute;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  cursor: pointer;
  transition: background 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.lb-btn:hover { background: rgba(255, 255, 255, 0.18); }

.lb-close {
  top: 18px; right: 18px;
  width: 44px; height: 44px;
  z-index: 2;
}

.lb-prev {
  left: 16px; top: 50%;
  transform: translateY(-50%);
  width: 52px; height: 52px;
}

.lb-next {
  right: 16px; top: 50%;
  transform: translateY(-50%);
  width: 52px; height: 52px;
}

.lb-counter {
  position: absolute;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255, 255, 255, 0.5);
  font-size: 12px;
  letter-spacing: 1.5px;
  font-weight: 500;
  white-space: nowrap;
}

.lb-caption {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255, 255, 255, 0.65);
  font-size: 13px;
  text-align: center;
  max-width: 60vw;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (max-width: 600px) {
  .lb-prev { left: 8px; width: 42px; height: 42px; }
  .lb-next { right: 8px; width: 42px; height: 42px; }
  .lb-img { max-width: 96vw; max-height: 78vh; }
}
