/* GALERIE MASONRY — shortcode [galerie_masonry] */
.masonry-gallery {
  display: block;
  columns: var(--masonry-cols, 4);
  column-gap: var(--masonry-gap, 12px);
}
@media (max-width: 980px) {
  .masonry-gallery { columns: 2; }
}
@media (max-width: 480px) {
  .masonry-gallery { columns: 1; }
}
.masonry-gallery__item {
  break-inside: avoid;
  overflow: hidden;
  border-radius: var(--Radius-xs, 0.5rem);
}
.masonry-gallery__link {
  display: block;
  cursor: zoom-in;
  overflow: hidden;
  border-radius: var(--Radius-xs, 0.5rem);
}
.masonry-gallery__item img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.45s ease-out, opacity 0.3s ease;
}
.masonry-gallery__item:hover img {
  transform: scale(1.04);
  opacity: 0.9;
}

/* Lightbox */
#masonry-lightbox {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}
#masonry-lightbox.is-open {
  opacity: 1;
  pointer-events: all;
}
.mlb-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.88);
}
.mlb-content {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  align-items: center;
  justify-content: center;
}
.mlb-img {
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
  border-radius: var(--Radius-s, 0.75rem);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5);
  transition: opacity 0.2s ease;
}
.mlb-close {
  position: absolute;
  top: -2.75rem;
  right: 0;
  background: transparent;
  border: none;
  color: #fff;
  font-size: 2.25rem;
  line-height: 1;
  cursor: pointer;
  padding: 0.25rem 0.5rem;
  opacity: 0.75;
  transition: opacity 0.2s ease;
}
.mlb-close:hover { opacity: 1; }
