/* Catalog card galleries are phone-only. Desktop and tablet keep the old card. */
.mobile-catalog-gallery,
.mobile-catalog-gallery__dots {
    display: none;
}

/* The rating badge must always sit above black PERSONA captions. */
.box-snippet .img-wrapper > .rating-label {
    z-index: 6 !important;
}

@media (max-width: 767px) {
    /* catalog-gallery-overlay-pass-through
     * Decorative labels stay visible, but must not intercept a finger gesture.
     * This also covers PERSONA badges whose invisible wrapper spans the photo.
     */
    .box-snippet .img-wrapper .badge-card,
    .box-snippet .img-wrapper .badge-card *,
    .box-snippet .img-wrapper .snippet-badges,
    .box-snippet .img-wrapper .snippet-badges *,
    .box-snippet .img-wrapper .rating-label,
    .box-snippet .img-wrapper .rating-label *,
    .box-snippet .img-wrapper .stick,
    .box-snippet .img-wrapper .stick * {
        pointer-events: none !important;
    }

    /* Keep legacy Hit/New badges on the square photo, above the dots gutter. */
    .box-snippet .img-wrapper > .snippet-badges {
        bottom: 15px !important;
    }

    .box-snippet .img-wrapper .mobile-catalog-card {
        position: relative;
        display: block;
        padding-bottom: 15px;
        overflow: hidden;
        background: #fff;
    }

    .box-snippet .img-wrapper .mobile-catalog-card.has-mobile-catalog-gallery > img {
        display: none !important;
    }

    .box-snippet .img-wrapper .mobile-catalog-gallery {
        display: block;
        width: 100%;
        overflow: hidden;
        touch-action: pan-y;
    }

    .box-snippet .img-wrapper .mobile-catalog-gallery:not(.slick-initialized) .mobile-catalog-gallery__slide:not(:first-child) {
        display: none;
    }

    .box-snippet .img-wrapper .mobile-catalog-gallery__slide {
        width: 100%;
        aspect-ratio: 1 / 1;
        overflow: hidden;
        background: #f7f7f7;
    }

    .box-snippet .img-wrapper .mobile-catalog-gallery__slide img {
        display: block;
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .box-snippet .img-wrapper .mobile-catalog-gallery__dots {
        position: absolute;
        left: 50%;
        bottom: 4px;
        z-index: 4;
        display: block;
        overflow: hidden;
        height: 7px;
        transform: translateX(-50%);
    }

    .mobile-catalog-gallery__dots-track {
        display: flex;
        gap: 4px;
        align-items: center;
        height: 7px;
        transition: transform .2s ease;
        will-change: transform;
    }

    .mobile-catalog-gallery__dots-track.is-jump {
        transition: none;
    }

    .mobile-catalog-gallery__dot {
        display: block;
        flex: 0 0 6px;
        width: 6px;
        height: 6px;
        border-radius: 50%;
        background: #c9edf2;
        transform: scale(.78);
        transition: background-color .18s ease, transform .18s ease;
    }

    .mobile-catalog-gallery__dot.is-active {
        background: #53bed0;
        transform: scale(1);
    }

    .box-snippet .img-wrapper .mobile-catalog-card .snippet-badges,
    .box-snippet .img-wrapper .mobile-catalog-card .rating-label,
    .box-snippet .img-wrapper .mobile-catalog-card .badge-card {
        z-index: 5;
    }
}
