/* Statische Kopie Kiesel Autokrane (webtemps, 18.11.2026):
   Ersatz für Funktionen, die vorher das JavaScript des Baukastens erledigt hat. */

/* Fotogalerie: Masonry wie im Original (Layout "asymetric3"), ohne JS per CSS-Grid.
   Muster je 8 Bilder auf 10 Spalten:
   A: 1 groß links (4 Sp., 2 Reihen) | 2 + 3 klein (je 3 Sp.) | 4 breit darunter (6 Sp.)
   B: 5 + 6 klein (je 3 Sp.) | 7 breit darunter (6 Sp.) | 8 groß rechts (4 Sp., 2 Reihen)
   Reihenhöhe = Breite eines kleinen Bildes x 5/6 (Seitenverhältnis 6:5 wie im Original). */
#dmRoot #dm .dmPhotoGallery {
  container-type: inline-size;
}
#dmRoot #dm .dmPhotoGallery .dmPhotoGalleryHolder {
  display: grid !important;
  grid-template-columns: repeat(10, 1fr);
  grid-auto-rows: calc(25cqw - 7px);
  grid-auto-flow: dense; /* Bild 8 (hoch, rechts) füllt die Reihe neben Bild 5/6 */
  gap: 12px;
  height: auto !important;
  visibility: visible !important;
  opacity: 1 !important;
  padding: 0 !important;
  margin: 0 !important;
}
/* clearfix-Pseudoelemente würden sonst eine leere Rasterzelle belegen */
#dmRoot #dm .dmPhotoGallery .dmPhotoGalleryHolder::before,
#dmRoot #dm .dmPhotoGallery .dmPhotoGalleryHolder::after {
  content: none !important;
  display: none !important;
}
#dmRoot #dm .dmPhotoGallery .dmPhotoGalleryHolder > li.photoGalleryThumbs {
  position: static !important;
  float: none !important;
  width: auto !important;
  height: 100% !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  opacity: 1 !important;
  visibility: visible !important;
  transform: none !important;
  list-style: none;
}
#dmRoot #dm .dmPhotoGallery .image-container,
#dmRoot #dm .dmPhotoGallery .image-container a {
  position: static !important;
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  background: none !important;
}
#dmRoot #dm .dmPhotoGallery .image-container img {
  position: static !important;
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  max-height: none !important;
  object-fit: cover;
  opacity: 1 !important;
  visibility: visible !important;
}
#dmRoot #dm .dmPhotoGallery li.photoGalleryThumbs:nth-child(8n+1) { grid-column: 1 / span 4; grid-row: span 2; }
#dmRoot #dm .dmPhotoGallery li.photoGalleryThumbs:nth-child(8n+2) { grid-column: 5 / span 3; }
#dmRoot #dm .dmPhotoGallery li.photoGalleryThumbs:nth-child(8n+3) { grid-column: 8 / span 3; }
#dmRoot #dm .dmPhotoGallery li.photoGalleryThumbs:nth-child(8n+4) { grid-column: 5 / span 6; }
#dmRoot #dm .dmPhotoGallery li.photoGalleryThumbs:nth-child(8n+5) { grid-column: 1 / span 3; }
#dmRoot #dm .dmPhotoGallery li.photoGalleryThumbs:nth-child(8n+6) { grid-column: 4 / span 3; }
#dmRoot #dm .dmPhotoGallery li.photoGalleryThumbs:nth-child(8n+7) { grid-column: 1 / span 6; }
#dmRoot #dm .dmPhotoGallery li.photoGalleryThumbs:nth-child(8n+8) { grid-column: 7 / span 4; grid-row: span 2; }
@media (max-width: 767px) {
  #dmRoot #dm .dmPhotoGallery .dmPhotoGalleryHolder { grid-template-columns: 1fr; grid-auto-rows: auto; }
  #dmRoot #dm .dmPhotoGallery li.photoGalleryThumbs { grid-column: auto !important; grid-row: auto !important; }
  #dmRoot #dm .dmPhotoGallery .image-container img { height: auto !important; }
}

/* Bildschleife (flexslider) startet nur per JS: erstes Bild fest zeigen */
#dmRoot #dm .flexslider .slides > li { display: none !important; }
#dmRoot #dm .flexslider .slides > li:first-child {
  display: block !important;
  position: relative !important;
  opacity: 1 !important;
  visibility: visible !important;
  width: 100% !important;
  float: none !important;
}
#dmRoot #dm .flexslider .slides > li:first-child img {
  display: block !important;
  position: static !important;
  width: 100% !important;
  height: auto !important;
  opacity: 1 !important;
  visibility: visible !important;
}
#dmRoot #dm .flexslider .slide-inner,
#dmRoot #dm .flexslider .color-overlay,
#dmRoot #dm .flexslider .flex-direction-nav,
#dmRoot #dm .flexslider .flex-pauseplay { display: none !important; }

/* Einblend-Animationen: ohne JS bleiben diese Elemente sonst unsichtbar
   (Baukasten-Regel: [data-anim-desktop]:not([data-anim-desktop="none"]) { visibility: hidden }) */
#dmRoot [data-anim-desktop],
#dmRoot [data-anim-tablet],
#dmRoot [data-anim-mobile],
#dmRoot [data-anim-extended] {
  visibility: visible !important;
  opacity: 1 !important;
}

/* Ersatz für Facebook-Feed und Karte (luden per JS von Drittanbietern) */
#dmRoot #dm [data-type="inlineMap"] { height: auto !important; min-height: 0 !important; }
#dmRoot #dm [data-type="inlineMap"] .mapContainer,
#dmRoot #dm [data-widget-id="128151275e4145de9c457a6ae729489e"] .fallback { display: none !important; }
#dmRoot #dm .kopie-hinweis {
  padding: 32px 16px;
  text-align: center;
  font-size: 18px;
  line-height: 1.6;
}
#dmRoot #dm .kopie-hinweis a {
  display: inline-block;
  margin-top: 8px;
  padding: 10px 22px;
  border: 2px solid #c8161d;
  border-radius: 24px;
  color: #c8161d;
  text-decoration: none;
  font-weight: 600;
}

/* Handy-Fassung: Hamburger und Menü sichtbar, Unterpunkte im Menü immer aufgeklappt
   (das Auf-/Zuklappen der Unterpunkte erledigte das Baukasten-JS) */
#dmRoot.dmMobileBody .layout-drawer-hamburger,
#dmRoot.dmMobileBody .layout-drawer,
#dmRoot.dmMobileBody .layout-drawer-overlay { visibility: visible !important; }
#dmRoot.dmMobileBody .layout-drawer:not([open]) { visibility: hidden !important; }
#dmRoot.dmMobileBody .layout-drawer .unifiednav__container_sub-nav {
  display: block !important;
  position: static !important;
  max-height: none !important;
  height: auto !important;
  opacity: 1 !important;
  visibility: visible !important;
  transform: none !important;
}
