/* =========================================================================
   KUNDEN-FOTO-GALERIE — fotogalerie.css
   Passt zum Design-System in style.css (Beerengarten Feldkirchen)
   ========================================================================= */

/* ── Section-Wrapper ────────────────────────────────────────────────────── */
#foto-galerie {
  padding: 6rem 1.5rem;
  background-color: var(--color-bg);
}

#foto-galerie .section-inner {
  max-width: var(--max-width, 1200px);
  margin-inline: auto;
}

/* ── Masonry-Grid (CSS columns) ─────────────────────────────────────────── */
#foto-galerie-grid {
  columns: 3;
  column-gap: 1rem;
  margin-bottom: 4rem;
}

@media (max-width: 768px) {
  #foto-galerie-grid {
    columns: 2;
  }
}

@media (max-width: 480px) {
  #foto-galerie-grid {
    columns: 1;
  }
}

/* ── Foto-Karte ─────────────────────────────────────────────────────────── */
.foto-karte {
  break-inside: avoid;
  margin-bottom: 1rem;
  border-radius: var(--radius-md, 20px);
  overflow: hidden;
  position: relative;
  cursor: pointer;
  box-shadow: var(--shadow-sm, 0 4px 14px rgba(0,0,0,0.05));
  background: var(--color-surface, #fff);
  transition: transform 0.35s var(--ease-spring, cubic-bezier(0.175, 0.885, 0.32, 1.1)),
              box-shadow 0.35s ease;
  display: block;           /* inline-block würde columns-Layout stören */
  width: 100%;
}

.foto-karte:hover {
  transform: scale(1.03);
  box-shadow: var(--shadow-lg, 0 20px 40px rgba(0,0,0,0.12));
  z-index: 1;
}

.foto-karte img {
  display: block;
  width: 100%;
  height: auto;
  transition: transform 0.45s var(--ease-soft, cubic-bezier(0.25, 1, 0.5, 1));
}

.foto-karte:hover img {
  transform: scale(1.06);
}

/* ── Overlay mit Autor-Name ─────────────────────────────────────────────── */
.foto-karte__overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 2.5rem 1rem 1rem;
  background: linear-gradient(to top, rgba(0,0,0,0.70) 0%, transparent 100%);
  color: #fff;
  opacity: 0;
  transition: opacity 0.3s ease;
  border-radius: 0 0 var(--radius-md, 20px) var(--radius-md, 20px);
}

.foto-karte:hover .foto-karte__overlay {
  opacity: 1;
}

.foto-karte__autor {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.75);
  margin-bottom: 0.2rem;
}

.foto-karte__caption {
  font-size: 0.95rem;
  font-weight: 500;
  line-height: 1.3;
}

/* ── Lightbox-Overlay ───────────────────────────────────────────────────── */
#foto-lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  padding: 2rem;
}

#foto-lightbox.is-open {
  opacity: 1;
  pointer-events: all;
}

#foto-lightbox__inner {
  position: relative;
  max-width: min(90vw, 900px);
  width: 100%;
  background: var(--color-surface, #fff);
  border-radius: var(--radius-lg, 32px);
  overflow: hidden;
  box-shadow: 0 30px 80px rgba(0,0,0,0.5);
  transform: scale(0.92) translateY(20px);
  transition: transform 0.35s var(--ease-spring, cubic-bezier(0.175, 0.885, 0.32, 1.1));
}

#foto-lightbox.is-open #foto-lightbox__inner {
  transform: scale(1) translateY(0);
}

#foto-lightbox__img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 70vh;
  object-fit: cover;
}

#foto-lightbox__info {
  padding: 1.25rem 1.5rem 1.5rem;
}

#foto-lightbox__caption {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--color-text-main, #1d1d1f);
  margin-bottom: 0.25rem;
}

#foto-lightbox__autor {
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-accent-red, #e63946);
}

/* Schliessen-Button (X) */
#foto-lightbox__close {
  position: absolute;
  top: 0.9rem;
  right: 0.9rem;
  width: 2.5rem;
  height: 2.5rem;
  border: none;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  transition: background 0.2s ease, transform 0.2s ease;
  backdrop-filter: blur(6px);
  z-index: 1;
}

#foto-lightbox__close:hover {
  background: rgba(230, 57, 70, 0.85);
  transform: scale(1.1);
}

/* ── Einschick-Formular ─────────────────────────────────────────────────── */
#foto-formular-wrapper {
  background: var(--color-surface, #fff);
  border-radius: var(--radius-lg, 32px);
  padding: 3rem 2.5rem;
  box-shadow: var(--shadow-md, 0 10px 30px rgba(0,0,0,0.08));
  max-width: 600px;
  margin-inline: auto;
  text-align: center;
}

#foto-formular-wrapper .form-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  display: block;
}

#foto-formular-wrapper h3 {
  font-size: 1.6rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--color-text-main, #1d1d1f);
}

#foto-formular-wrapper .form-beschreibung {
  font-size: 0.95rem;
  color: var(--color-text-muted, #86868b);
  margin-bottom: 2rem;
  line-height: 1.6;
}

.foto-form__gruppe {
  margin-bottom: 1.25rem;
  text-align: left;
}

.foto-form__gruppe label {
  display: block;
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-muted, #86868b);
  margin-bottom: 0.45rem;
}

.foto-form__gruppe input,
.foto-form__gruppe textarea {
  width: 100%;
  padding: 0.85rem 1.1rem;
  border: 1.5px solid rgba(0, 0, 0, 0.1);
  border-radius: var(--radius-sm, 12px);
  font-family: var(--font-sans, 'Inter', sans-serif);
  font-size: 0.97rem;
  color: var(--color-text-main, #1d1d1f);
  background: var(--color-bg, #f5f5f7);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  outline: none;
  resize: vertical;
}

.foto-form__gruppe input::placeholder,
.foto-form__gruppe textarea::placeholder {
  color: var(--color-text-muted, #86868b);
}

.foto-form__gruppe input:focus,
.foto-form__gruppe textarea:focus {
  border-color: var(--color-accent-red, #e63946);
  box-shadow: 0 0 0 3px rgba(230, 57, 70, 0.12);
  background: #fff;
}

#foto-formular-wrapper .btn {
  margin-top: 0.5rem;
  width: 100%;
  padding: 1rem 2rem;
  font-size: 1rem;
  font-weight: 700;
  gap: 0.5rem;
}

.form-hinweis {
  margin-top: 1rem;
  font-size: 0.8rem;
  color: var(--color-text-muted, #86868b);
  line-height: 1.5;
}
