/* ── Galerie justifiée marivat ── */
.marivat-gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0;
  padding: 0;
}
.marivat-gallery-item {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  flex-shrink: 1;
  min-width: 80px;
  text-decoration: none;
}
.marivat-gallery-item img {
  display: block;
  height: 210px;
  width: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.marivat-gallery-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0);
  transition: background 0.3s ease;
  pointer-events: none;
}
.marivat-gallery-item:hover .marivat-gallery-overlay {
  background: rgba(0, 0, 0, 0.5);
}
.marivat-gallery-item:hover img {
  transform: scale(1.04);
}

@media (max-width: 1024px) {
  .marivat-gallery-item img { height: 150px; }
}
@media (max-width: 640px) {
  .marivat-gallery-item {
    flex-basis: 45% !important;
    flex-grow: 1 !important;
  }
  .marivat-gallery-item img { height: 130px; }
}

/* GLightbox overrides */
.glightbox-container { z-index: 999999 !important; }

/* Elementor lightbox : fix positionnement initial */
.dialog-type-lightbox,
.elementor-lightbox {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  z-index: 99999 !important;
}
.elementor-lightbox .dialog-widget-content {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  max-width: none !important;
  overflow: visible !important;
}
.elementor-lightbox .elementor-lightbox-image {
  max-width: 90vw !important;
  max-height: 90vh !important;
  width: auto !important;
  height: auto !important;
  object-fit: contain !important;
}
.elementor-lightbox .elementor-lightbox-item {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  height: 100% !important;
  width: 100% !important;
}
