
/*
 * Portfolio galleries: responsive masonry, original photograph proportions.
 * Applies only to the three photographic portfolio sections.
 * No changes to video grids, other images, or lightboxes.
 */
body[data-page="hochzeit"] .gallery-section .portfolio-grid,
body[data-page="abschlussball"] .gallery-section .portfolio-grid,
body[data-page="content"] .sf-content-photos .portfolio-grid{
  display:block!important;
  column-count:3!important;
  column-gap:12px!important;
  grid-template-columns:none!important;
  grid-auto-rows:auto!important;
  align-items:initial!important;
}
body[data-page="hochzeit"] .gallery-section .portfolio-grid > .portfolio-photo,
body[data-page="abschlussball"] .gallery-section .portfolio-grid > .portfolio-photo,
body[data-page="content"] .sf-content-photos .portfolio-grid > .portfolio-photo{
  display:block;
  width:100%!important;
  height:auto!important;
  min-height:0!important;
  max-height:none!important;
  padding:0!important;
  border:0!important;
  margin:0 0 12px!important;
  overflow:hidden!important;
  background:transparent!important;
  break-inside:avoid!important;
  -webkit-column-break-inside:avoid!important;
  page-break-inside:avoid!important;
  box-sizing:border-box!important;
  text-align:left;
}
body[data-page="hochzeit"] .gallery-section .portfolio-grid > .portfolio-photo img,
body[data-page="abschlussball"] .gallery-section .portfolio-grid > .portfolio-photo img,
body[data-page="content"] .sf-content-photos .portfolio-grid > .portfolio-photo img{
  display:block!important;
  width:100%!important;
  height:auto!important;
  min-height:0!important;
  max-height:none!important;
  aspect-ratio:auto!important;
  object-fit:contain!important;
  object-position:center center!important;
}
@media(max-width:720px){
  body[data-page="hochzeit"] .gallery-section .portfolio-grid,
  body[data-page="abschlussball"] .gallery-section .portfolio-grid,
  body[data-page="content"] .sf-content-photos .portfolio-grid{
    column-count:2!important;
    column-gap:8px!important;
  }
  body[data-page="hochzeit"] .gallery-section .portfolio-grid > .portfolio-photo,
  body[data-page="abschlussball"] .gallery-section .portfolio-grid > .portfolio-photo,
  body[data-page="content"] .sf-content-photos .portfolio-grid > .portfolio-photo{
    margin-bottom:8px!important;
  }
}
/* Keep gallery expand/collapse behavior managed by existing content code. */
