/* v2.1.0: Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.85);
}

.lightbox-content {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lightbox-content img {
  max-width: 100%;
  max-height: 80vh;
  border-radius: var(--radius);
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

.lightbox-close {
  position: absolute;
  top: -40px;
  right: 0;
  font-size: 2rem;
  color: white;
  background: none;
  border: none;
  cursor: pointer;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity var(--transition);
}

.lightbox-close:hover {
  opacity: 0.7;
}

.lightbox-caption {
  color: rgba(255,255,255,0.8);
  margin-top: var(--space-md);
  font-size: 0.9375rem;
  text-align: center;
}

/* v2.6.0: Lightbox navigation arrows */
.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.5);
  color: white;
  border: none;
  border-radius: 50%;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s ease, opacity 0.2s ease;
  z-index: 2;
  opacity: 0.8;
}

.lightbox-nav:hover {
  background: rgba(0,0,0,0.75);
  opacity: 1;
}

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

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

.lightbox-counter {
  color: rgba(255,255,255,0.6);
  font-size: 0.8125rem;
  margin-top: var(--space-xs);
  text-align: center;
}

/* Mobile: arrows inside the image area */
@media (max-width: 768px) {
  .lightbox-prev {
    left: 8px;
  }
  .lightbox-next {
    right: 8px;
  }
  .lightbox-nav {
    width: 40px;
    height: 40px;
    background: rgba(0,0,0,0.6);
  }
}
