/* Gallery Styles – responsive Layout mit sichtbaren Pfeilen und KEINEM Abstecken */
.gallery-root { 
  max-width: 1200px; 
  margin: 2rem auto; 
  padding: 0 1rem; 
}

.viewer { 
  position: relative; 
  text-align: center; 
  margin-bottom: 1rem; 
  overflow: visible; /* Wichtig: Verhindert Verstecken der Buttons */
}

.photo-card { 
  position: relative; /* Für besseres Positioning */
  display: inline-block; /* Zentriert das Bild */
  margin: 0 auto;
  background: #f8f9fa; /* Leichter Hintergrund, falls Rand sichtbar (anpassbar) */
  border-radius: 8px;
  padding: 1rem; /* Etwas Padding für Rand */
}

.photo-card img { 
  max-width: 100%; 
  max-height: 70vh; /* Etwas höher, um mehr Platz für contain zu geben */
  object-fit: contain; /* GANZES Bild sichtbar, kein Zuschneiden! */
  display: block; /* Verhindert Inline-Spacing */
}

.meta { 
  background: #fff; 
  padding: 1rem; 
  border-radius: 8px; 
  margin-top: 0.5rem; 
  box-shadow: 0 2px 4px rgba(0,0,0,0.1); 
}

.thumbnails { 
  margin-top: 1rem; 
}

.thumb-list { 
  display: flex; 
  flex-wrap: nowrap; 
  overflow-x: auto; 
  gap: 0.5rem; 
  padding: 0.5rem 0; 
  scroll-snap-type: x mandatory; 
}

.thumb { 
  flex: 0 0 auto; 
  border: none; 
  background: none; 
  cursor: pointer; 
  padding: 0.25rem; 
  border-radius: 4px; 
  transition: background 0.3s; 
}

.thumb:focus { 
  outline: 2px solid #0d6efd; 
  outline-offset: 2px; 
}

.thumb img { 
  width: 80px; 
  height: 60px; 
  object-fit: contain; /* KEIN Abstecken für Thumbs – vollständiges Bild */
  border-radius: 4px; 
  background: #f8f9fa; /* Leichter Hintergrund für Thumbs */
}

.thumb.active { 
  background: rgba(13,110,253,0.1); 
}

.thumb:hover { 
  background: rgba(0,0,0,0.05); 
}

/* Navigationspfeile: Links/Rechts – ROBUSTER STYLING (kombiniert & priorisiert) */
.nav-btn {
  position: absolute !important; /* !important für Overrides */
  top: 50%;
  left: 0; /* Basis-Position */
  transform: translateY(-50%);
  display: block !important; /* Explizit sichtbar */
  background: rgba(0, 0, 0, 0.6) !important;
  color: white !important;
  border: none !important;
  width: 50px !important;
  height: 50px !important;
  border-radius: 50% !important;
  cursor: pointer !important;
  font-size: 24px !important;
  font-weight: bold !important;
  line-height: 50px !important; /* Zentriert den Text vertikal */
  text-align: center !important;
  z-index: 20 !important; /* Höher als Bild (10+), um Überlappungen zu vermeiden */
  transition: all 0.3s ease !important;
  opacity: 0.9 !important; /* Immer sichtbar, nicht zu transparent */
  visibility: visible !important; /* Explizit sichtbar */
  text-shadow: 0 1px 2px rgba(0,0,0,0.5); /* Besser lesbar */
}

.nav-btn:hover,
.nav-btn:focus {
  opacity: 1 !important;
  background: rgba(0, 0, 0, 0.9) !important;
  transform: translateY(-50%) scale(1.1) !important;
  outline: none; /* Entfernt Standard-Fokus-Rahmen */
}

.prev {
  left: 10px !important; /* Links positionieren */
}

.next {
  left: auto !important; /* Reset für right */
  right: 10px !important; /* Rechts positionieren */
}

/* Mobile: Kleiner und näher */
@media (max-width: 768px) {
  .thumb img { 
    width: 60px; 
    height: 45px; 
  }
  
  .nav-btn { 
    width: 40px !important;
    height: 40px !important;
    font-size: 18px !important;
    line-height: 40px !important;
  }
  
  .prev { 
    left: 5px !important; 
  }
  
  .next { 
    right: 5px !important; 
  }
  
  .photo-card img { 
    max-height: 50vh; /* Kleiner auf Mobile, um Platz zu sparen */
  }
}
