/* --- Hero-Bereich --- */
.hero.huk-hero {
  width: 100%;
  overflow: hidden;
  position: relative;
  text-align: center;
}

.hero.huk-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;      /* Bild füllt den Container aus, ohne verzerrt zu werden */
  object-position: center; /* zentriert das Bild */
  display: block;
  margin: 0;
}

/* --- Hauptinhalt --- */
.huk-content {
  max-width: 900px;
  margin: 0 auto;
}

/* --- Galerie-Bilder einheitlich, ohne Zuschneiden --- */
.gallery-img {
  width: 300px;       /* gleiche Breite für alle Bilder */
  min-width: 300px;
  max-width: 100%;    /* responsive */
  height: auto;
  border-radius: 12px;
  box-shadow: 0 6px 15px rgba(0,0,0,0.2);
  border: 3px solid white;
  cursor: pointer;
  display: block;
  margin: 0 auto 20px;
  transition: transform 0.3s ease;
}

.gallery-img:hover {
  transform: scale(1.02);
}

.gallery-img.rot-90 {
  transform: rotate(90deg);
}

/* --- Bild-Text Layout --- */
.image-left, .image-right {
  display: flex;
  align-items: flex-start;
  gap: 1.5em;
  margin: 2em 0;
}

.image-left > p,
.image-right > p {
  margin-top: 0;
}

.image-left > p > b,
.image-right > p > b {
  font-weight: 600;
}

.image-right {
  flex-direction: row-reverse;
}

/* --- Lightbox --- */
.lightbox {
  display: none;
  position: fixed;
  z-index: 1000;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0,0,0,0.8);
  justify-content: center;
  align-items: center;
}

.lightbox img {
  max-width: 90%;
  max-height: 90vh;
  border-radius: 6px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.7);
}

.lightbox .close-btn {
  position: fixed;
  top: 20px;
  right: 30px;
  font-size: 3rem;
  color: white;
  cursor: pointer;
  user-select: none;
  font-weight: bold;
  z-index: 1001;
}

/* --- Zitate --- */
blockquote.bild-im-zitat,
blockquote.kurzzitat,
blockquote.wappen-zitat {
  max-width: 85%;
  margin: 2em auto;
  padding: 1.2em 1.5em;
  background: #e8e2d5;
  font-family: 'IM Fell DW Pica', serif;
  font-size: 1.05rem;
  color: #2a2a2a;
  line-height: 1.8;
  border-left: 2px solid #999;
  border-radius: 4px;
  box-shadow: inset 1px 0 4px rgba(0,0,0,0.05);
}

blockquote.bild-im-zitat img.ersterwaehnung_wiebelskirchen {
  float: left;
  width: 300px;
  max-width: 100%;
  height: auto;
  margin: 0 1.5em 1em 0;
  border-radius: 4px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.1);
  cursor: pointer;
}

blockquote.wappen-zitat img.wappen {
  width: 180px;
  height: auto;
  border-radius: 4px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.1);
  cursor: pointer;
}

blockquote.wappen-zitat p {
  margin: 0;
  flex: 1;
}

/* --- Responsive Anpassungen --- */
@media (max-width: 768px) {
  .hero.huk-hero {
    height: 200px; /* kleinere Höhe für mobile Ansicht */
  }

  .image-left, .image-right {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .gallery-img {
    width: 90%;
    max-width: 480px;
  }

  blockquote.bild-im-zitat img.ersterwaehnung_wiebelskirchen,
  blockquote.wappen-zitat img.wappen {
    float: none;
    display: block;
    margin: 0 auto 1em auto;
    width: 90%;
    max-width: 480px;
  }

  blockquote.bild-im-zitat,
  blockquote.kurzzitat,
  blockquote.wappen-zitat {
    max-width: 100%;
    font-size: 1rem;
    flex-direction: column;
    text-align: center;
  }

  blockquote.wappen-zitat p {
    width: 100%;
  }
}

/* --- Druck-Styles --- */
@media print {
  body * { display: none !important; }
  main, main > div, main > div > div, #druckbereich, #druckbereich * {
    display: block !important;
    visibility: visible !important;
  }
  .hero.huk-hero, .hero.huk-hero img {
    display: block !important;
    visibility: visible !important;
    max-height: 120px !important;
    width: auto !important;
    max-width: 90% !important;
    margin: 0 auto !important;
    padding: 0 !important;
    object-fit: contain !important;
  }
  main, #druckbereich {
    page-break-inside: avoid !important;
    page-break-before: avoid !important;
    page-break-after: avoid !important;
  }
  #druckbereich {
    font-size: 10pt !important;
    margin: 0 !important;
    padding: 0 !important;
  }
  nav, footer, .menu-toggle, button:not([onclick="window.print()"]) {
    display: none !important;
  }
  @page { margin: 0.5cm; }
}
