/* ══════════════════════════════════════════════════════
   Bricks Scroll Carousel — CSS
══════════════════════════════════════════════════════ */

.bsc-wrapper {
    --bsc-height:    280px;
    --bsc-gap:       16px;
    --bsc-nav-color: #333;
    position: relative;
    width: 100%;
    overflow: hidden;
    user-select: none;
    -webkit-user-select: none;
}

/* ── Viewport ── */
.bsc-viewport {
    width: 100%;
    overflow: hidden;
}

/* ── Track ── */
.bsc-track {
    display: flex;
    gap: var(--bsc-gap);
    will-change: transform;
    cursor: grab;
    touch-action: pan-y;
}
.bsc-track:active { cursor: grabbing; }

/* ── Slide ── */
.bsc-slide {
    flex-shrink: 0;
    height: var(--bsc-height);
    overflow: hidden;
    border-radius: 8px;
    position: relative;
    /* width défini par inline style PHP */
}

/* Hover zoom — désactivable via data-no-hover */
.bsc-wrapper:not([data-no-hover="1"]) .bsc-slide {
    transition: transform .28s ease, box-shadow .28s ease;
}
.bsc-wrapper:not([data-no-hover="1"]) .bsc-slide:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 14px 36px rgba(0,0,0,.18);
    z-index: 2;
}

/* ── Image ── */
.bsc-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    pointer-events: none;
    -webkit-user-drag: none;
}

/* ── Flèches ── */
.bsc-nav {
    position: absolute;
    top: 50%;
    left: 0; right: 0;
    transform: translateY(-50%);
    display: flex;
    justify-content: space-between;
    padding: 0 10px;
    pointer-events: none;
    z-index: 10;
}

.bsc-btn {
    pointer-events: all;
    width: 40px; height: 40px;
    border-radius: 50%;
    border: none;
    background: rgba(255,255,255,.92);
    color: var(--bsc-nav-color);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 12px rgba(0,0,0,.15);
    transition: background .2s, transform .2s;
    padding: 0;
    flex-shrink: 0;
}
.bsc-btn:hover  { background:#fff; transform:scale(1.1); }
.bsc-btn:active { transform:scale(.94); }

/* ── Dots ── */
.bsc-dots {
    display: flex;
    justify-content: center;
    gap: 7px;
    padding-top: 12px;
    flex-wrap: wrap;
}
.bsc-dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    border: none;
    background: rgba(0,0,0,.2);
    cursor: pointer;
    padding: 0;
    transition: background .2s, width .3s, transform .2s;
    flex-shrink: 0;
}
.bsc-dot:hover { background:rgba(0,0,0,.4); transform:scale(1.2); }
.bsc-dot--on {
    background: var(--bsc-nav-color);
    width: 20px;
    border-radius: 4px;
}

/* ── Masquage flèches / dots ── */
.bsc-wrapper[data-hide-nav="1"]  .bsc-nav  { display:none !important; }
.bsc-wrapper[data-hide-dots="1"] .bsc-dots { display:none !important; }

/* ══════════════════════════════════════════════════════
   LIGHTBOX
══════════════════════════════════════════════════════ */
.bsc-lb {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 99999;
    align-items: center;
    justify-content: center;
}
.bsc-lb--open { display: flex; }

.bsc-lb-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.88);
    cursor: zoom-out;
}

.bsc-lb-stage {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    max-width: 92vw;
    max-height: 92vh;
}

.bsc-lb-img {
    max-width: 92vw;
    max-height: 88vh;
    object-fit: contain;
    display: block;
    border-radius: 4px;
    box-shadow: 0 24px 80px rgba(0,0,0,.7);
    user-select: none;
}

.bsc-lb-close,
.bsc-lb-prev,
.bsc-lb-next {
    position: absolute;
    background: rgba(255,255,255,.12);
    border: none;
    color: #fff;
    cursor: pointer;
    border-radius: 50%;
    width: 46px; height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .2s, transform .2s;
    padding: 0;
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}
.bsc-lb-close:hover,
.bsc-lb-prev:hover,
.bsc-lb-next:hover {
    background: rgba(255,255,255,.26);
    transform: scale(1.1);
}

.bsc-lb-close { top: -54px; right: 0; }
.bsc-lb-prev  { left: -58px; top: 50%; transform: translateY(-50%); }
.bsc-lb-next  { right: -58px; top: 50%; transform: translateY(-50%); }
.bsc-lb-prev:hover { transform: translateY(-50%) scale(1.1); }
.bsc-lb-next:hover { transform: translateY(-50%) scale(1.1); }

.bsc-lb-counter {
    position: absolute;
    bottom: -40px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255,255,255,.65);
    font-size: 13px;
    font-family: sans-serif;
    white-space: nowrap;
}

/* Mobile lightbox */
@media (max-width: 640px) {
    .bsc-lb-prev  { left: 6px;  bottom: -60px; top: auto; transform: none; }
    .bsc-lb-next  { right: 6px; bottom: -60px; top: auto; transform: none; }
    .bsc-lb-close { top: -52px; right: 0; }
    .bsc-lb-prev:hover, .bsc-lb-next:hover { transform: scale(1.1); }
}
