/* Fourgon Malin - agrandissement des photos produits */
.product-gallery img,
.gallery img,
.fm-lightbox-trigger {
  cursor: zoom-in;
  transition: transform .18s ease, box-shadow .18s ease;
}
.product-gallery img:hover,
.gallery img:hover,
.fm-lightbox-trigger:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 38px rgba(0,0,0,.14);
}
.product-gallery img:focus-visible,
.gallery img:focus-visible,
.fm-lightbox-trigger:focus-visible {
  outline: 3px solid #ff6a1a;
  outline-offset: 4px;
}
.fm-lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 56px 88px 70px;
  background: rgba(10,8,7,.96);
  backdrop-filter: blur(8px);
}
.fm-lightbox.is-open { display: flex; }
.fm-lightbox__figure {
  margin: 0;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
}
.fm-lightbox__img {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: calc(100vh - 150px);
  object-fit: contain;
  border-radius: 16px;
  box-shadow: 0 28px 80px rgba(0,0,0,.45);
  background: #15110f;
}
.fm-lightbox__caption {
  margin: 0;
  max-width: min(900px, 90vw);
  color: #f5eee8;
  font-size: .95rem;
  line-height: 1.4;
  text-align: center;
}
.fm-lightbox__close,
.fm-lightbox__nav {
  position: fixed;
  z-index: 10000;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255,255,255,.22);
  background: rgba(20,16,14,.78);
  color: #fff;
  box-shadow: 0 10px 30px rgba(0,0,0,.25);
  cursor: pointer;
  transition: background .18s ease, transform .18s ease;
}
.fm-lightbox__close:hover,
.fm-lightbox__nav:hover { background: #ff6a1a; transform: scale(1.04); }
.fm-lightbox__close:focus-visible,
.fm-lightbox__nav:focus-visible { outline: 3px solid #ff6a1a; outline-offset: 3px; }
.fm-lightbox__close {
  top: 18px;
  right: 22px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  font-size: 2rem;
  line-height: 1;
}
.fm-lightbox__nav {
  top: 50%;
  width: 54px;
  height: 54px;
  margin-top: -27px;
  border-radius: 50%;
  font-size: 2rem;
  line-height: 1;
}
.fm-lightbox__prev { left: 18px; }
.fm-lightbox__next { right: 18px; }
.fm-lightbox__counter {
  position: fixed;
  top: 22px;
  left: 50%;
  transform: translateX(-50%);
  color: #fff;
  background: rgba(20,16,14,.72);
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 999px;
  padding: 7px 12px;
  font-size: .88rem;
  font-weight: 800;
}
@media (max-width: 720px) {
  .fm-lightbox { padding: 66px 12px 58px; }
  .fm-lightbox__img { max-height: calc(100vh - 145px); border-radius: 12px; }
  .fm-lightbox__nav { width: 46px; height: 46px; margin-top: -23px; background: rgba(20,16,14,.7); }
  .fm-lightbox__prev { left: 8px; }
  .fm-lightbox__next { right: 8px; }
  .fm-lightbox__close { top: 12px; right: 12px; width: 44px; height: 44px; }
  .fm-lightbox__caption { font-size: .86rem; padding: 0 34px; }
}
@media (prefers-reduced-motion: reduce) {
  .product-gallery img,
  .gallery img,
  .fm-lightbox-trigger,
  .fm-lightbox__close,
  .fm-lightbox__nav { transition: none; }
}

/* Respecter hidden même si un bouton possède display:inline-flex. */
.fm-lightbox [hidden] { display: none !important; }
