/* ============================================================
   Beekom Carousel — carousel.css  v1.1.0
   ============================================================ */

/* ── Wrapper ── */
.bk-carousel-wrap {
  position: relative;
  -webkit-user-select: none;
  user-select: none;
}

/* ── Viewport ── */
.bk-carousel-viewport {
  overflow: hidden;
}

/* ── Track ── */
.bk-carousel-track {
  display: flex;
  gap: var(--bk-gap, 16px);
  transition: transform 0.45s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  will-change: transform;
}

/* ── Slide ── */
.bk-carousel-slide {
  flex: 0 0 auto;
  height: var(--bk-height, 260px);
  overflow: hidden;
  background: #f0f0f0;
  border-radius: 4px;
  /* Pas de flex ici par défaut : la zone image remplit tout */
}

/* Quand légende présente → flex column */
.bk-carousel-slide.bk-has-caption {
  display: flex;
  flex-direction: column;
}

/* Position above : inverse l'ordre */
.bk-carousel-slide.bk-has-caption.bk-cap-above {
  flex-direction: column-reverse;
}

/* ── Zone image ── */
.bk-slide-img {
  flex: 1 1 auto;
  min-height: 0;        /* permet au flex enfant de rétrécir */
  overflow: hidden;
  position: relative;
}

/* Sans légende : la div bk-slide-img occupe tout */
.bk-carousel-slide:not(.bk-has-caption) .bk-slide-img {
  height: 100%;
}

.bk-slide-img img,
.bk-slide-img a {
  display: block;
  width: 100%;
  height: 100%;
}

.bk-slide-img img {
  object-fit: cover;
  object-position: center;
  transition: transform 0.38s ease;
}

.bk-carousel-slide:hover .bk-slide-img img {
  transform: scale(1.04);
}

.bk-lightbox-trigger {
  cursor: zoom-in;
}

/* ── Legende ── */
.bk-slide-caption {
  flex: 0 0 auto;
  margin: 0;
  padding: 8px 10px;
  font-size: 13px;
  line-height: 1.4;
  color: #333;
  background: #f5f5f5;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Overlay : légende par-dessus l'image en bas */
.bk-carousel-slide.bk-cap-over {
  position: relative;
}

.bk-carousel-slide.bk-cap-over .bk-slide-img {
  height: 100%;
}

.bk-carousel-slide.bk-cap-over .bk-slide-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(0, 0, 0, 0.52);
  color: #fff;
  backdrop-filter: blur(2px);
  transform: translateY(100%);
  transition: transform 0.28s ease;
}

.bk-carousel-slide.bk-cap-over:hover .bk-slide-caption {
  transform: translateY(0);
}

/* ── Fleches ── */
.bk-carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  padding: 0;
  background: #fff;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.14);
  z-index: 10;
  transition: background 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.bk-carousel-btn:hover {
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.22);
}

.bk-carousel-btn:disabled {
  opacity: 0.25;
  cursor: default;
  pointer-events: none;
}

.bk-carousel-btn svg {
  width: 20px;
  height: 20px;
  stroke: #333;
  fill: none;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  display: block;
}

.bk-btn-prev { left: -22px; }
.bk-btn-next { right: -22px; }

/* ── Points ── */
.bk-carousel-dots {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.bk-dot {
  width: 8px;
  height: 8px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: #ccc;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.25s ease;
}

.bk-dot.active {
  background: #c8102e;
  transform: scale(1.4);
}

/* ============================================================
   Lightbox
   ============================================================ */

.bk-lightbox-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
  z-index: 999999;
  display: none;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.bk-lightbox-overlay.bk-lb-open    { display: flex; }
.bk-lightbox-overlay.bk-lb-visible { opacity: 1; }

.bk-lb-img-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  max-width: 92vw;
  max-height: 92vh;
}

.bk-lb-img-wrap img {
  max-width: 88vw;
  max-height: 80vh;
  object-fit: contain;
  border-radius: 3px;
  display: block;
  transform: scale(0.9);
  transition: transform 0.28s ease;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.5);
}

.bk-lightbox-overlay.bk-lb-visible .bk-lb-img-wrap img {
  transform: scale(1);
}

/* Legende dans la lightbox */
.bk-lb-caption {
  color: rgba(255, 255, 255, 0.8);
  font-size: 14px;
  font-family: sans-serif;
  text-align: center;
  max-width: 80vw;
  line-height: 1.5;
}

.bk-lb-btn {
  position: fixed;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  cursor: pointer;
  transition: background 0.2s ease;
  z-index: 1;
}

.bk-lb-btn:hover { background: rgba(255, 255, 255, 0.28); }

.bk-lb-btn svg {
  width: 22px;
  height: 22px;
  stroke: #fff;
  fill: none;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  display: block;
}

.bk-lb-close { top: 18px; right: 18px; }
.bk-lb-prev  { left: 18px;  top: 50%; transform: translateY(-50%); }
.bk-lb-next  { right: 18px; top: 50%; transform: translateY(-50%); }

.bk-lb-counter {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255, 255, 255, 0.5);
  font-size: 13px;
  font-family: sans-serif;
  pointer-events: none;
  letter-spacing: 0.04em;
}
