 #galerie {
    scroll-margin-top: 260px; /* Höhe von Header + Navbar */
}

/* Grundstruktur Galerie */
.galerie-section {
  background-color: #faf8f8;
  padding: 50px 20px;
  text-align: center;
}

.galerie-section h2 {
  font-size: 2.2rem;
  color: green;
  text-shadow: 1px 1px black;
  margin-bottom: 40px;
}

.galerie-section h3 {
  font-size: 1.6rem;
  margin: 50px 0 20px;
  color: green;
  text-shadow: 1px 1px black;
}

/* Grid für 4er Bildreihen */
.galerie-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 25px;
  margin-bottom: 40px;
}

/* Einzelbild zentriert */
.galerie-single {
  display: flex;
  justify-content: center;
  margin-bottom: 40px;
  gap: 1.5rem;
}

/* Figure-Box mit Link */
.galerie-grid figure,
.galerie-single figure {
  max-width: 220px;
  width: 100%;
  margin: 0;
  border: 3px solid #ccc;
  border-radius: 6px;
  overflow: hidden;
  background: white;
  transition: transform 0.2s ease;
}

.galerie-grid figure:hover,
.galerie-single figure:hover {
  transform: scale(1.03);
}

.galerie-section img {
  width: 100%;
  height: auto;
  display: block;
}

.galerie-section figcaption {
  padding: 10px;
  font-size: 0.9rem;
  color: #444;
}

/* Responsive Verhalten */
@media (max-width: 768px) {
  .galerie-grid {
    gap: 20px;
  }

  .galerie-grid figure,
  .galerie-single figure {
    max-width: 180px;
  }

  .galerie-section h2 {
    font-size: 1.8rem;
  }

  .galerie-section h3 {
    font-size: 1.3rem;
  }
}

@media (max-width: 480px) {
  .galerie-grid {
    flex-direction: column;
    align-items: center;
  }

  .galerie-grid figure,
  .galerie-single figure {
    max-width: 90%;
  }

  .galerie-section h2,
  .galerie-section h3 {
    text-align: center;
  }
}
