/* ===== scuba.pics Lightbox ===== */

#sp-lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0, 0, 0, 0.93);
  align-items: center;
  justify-content: center;
  flex-direction: column;
}
#sp-lightbox.active {
  display: flex;
}

/* Haupt-Container */
#sp-lb-container {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 92vw;
  max-height: 92vh;
  width: 100%;
}

/* Bild-Bereich */
#sp-lb-img-wrap {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

#sp-lb-img {
  max-width: 88vw;
  max-height: 72vh;
  width: auto;
  height: auto;
  display: block;
  object-fit: contain;
  transition: opacity 0.2s ease;
}
#sp-lb-img.loading {
  opacity: 0.3;
}

/* Info-Leiste */
#sp-lb-info {
  width: 100%;
  max-width: 88vw;
  margin-top: 14px;
  color: #fff;
  font-family: 'Nunito', sans-serif;
}

#sp-lb-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 10px;
}

.sp-lb-tag {
  display: inline-block;
  padding: 2px 9px;
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 20px;
  color: #bbb;
  font-size: 0.72rem;
  font-family: 'Nunito', sans-serif;
  text-decoration: none;
  transition: border-color 0.15s, color 0.15s;
}
.sp-lb-tag:hover {
  border-color: rgba(255,255,255,0.7);
  color: #fff;
}

#sp-lb-desc {
  font-size: 0.9rem;
  font-weight: 300;
  line-height: 1.5;
  color: #ccc;
  margin: 0 0 10px 0;
  font-style: italic;
  min-height: 1.2em;
}

#sp-lb-exif {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  font-size: 0.78rem;
  font-weight: 400;
  color: #aaa;
}

.sp-lb-exif-item {
  display: flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}

.sp-lb-exif-item svg {
  opacity: 0.55;
  flex-shrink: 0;
  height: 22px;
  width: auto;
}

.sp-lb-exif-item span {
  color: #ddd;
}

.sp-lb-exif-item.hidden {
  display: none;
}

/* Schließen-Button */
#sp-lb-close {
  position: fixed;
  top: 18px;
  right: 24px;
  background: none;
  border: none;
  color: #fff;
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  opacity: 0.7;
  padding: 6px;
  z-index: 10001;
  transition: opacity 0.15s;
}
#sp-lb-close:hover { opacity: 1; }

/* Navigations-Pfeile */
#sp-lb-prev,
#sp-lb-next {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #fff;
  font-size: 3rem;
  line-height: 1;
  cursor: pointer;
  opacity: 0.5;
  padding: 10px 18px;
  z-index: 10001;
  transition: opacity 0.15s;
  user-select: none;
}
#sp-lb-prev { left: 10px; }
#sp-lb-next { right: 10px; }
#sp-lb-prev:hover,
#sp-lb-next:hover { opacity: 1; }

/* Zähler */
#sp-lb-counter {
  position: fixed;
  bottom: 14px;
  left: 50%;
  transform: translateX(-50%);
  color: #666;
  font-size: 0.75rem;
  font-family: 'Nunito', sans-serif;
  z-index: 10001;
}

/* Lade-Spinner */
#sp-lb-spinner {
  display: none;
  position: absolute;
  width: 36px;
  height: 36px;
  border: 3px solid rgba(255,255,255,0.15);
  border-top-color: rgba(255,255,255,0.7);
  border-radius: 50%;
  animation: sp-spin 0.7s linear infinite;
}
#sp-lb-img.loading + #sp-lb-spinner,
#sp-lb-spinner.active {
  display: block;
}

@keyframes sp-spin {
  to { transform: rotate(360deg); }
}

/* Mobile */
@media (max-width: 768px) {
  #sp-lb-img {
    max-width: 96vw;
    max-height: 60vh;
  }
  #sp-lb-info {
    max-width: 96vw;
  }
  #sp-lb-prev { font-size: 2rem; padding: 6px 10px; }
  #sp-lb-next { font-size: 2rem; padding: 6px 10px; }
  #sp-lb-exif {
    gap: 5px 12px;
    font-size: 0.72rem;
  }
}
