/* Product Scroll — horizontal carousel for modules */

.scroll-wrapper {
    position: relative;
}

.products-scroll {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 4px;
}

.products-scroll::-webkit-scrollbar {
    display: none;
}

.products-scroll .scroll-card {
    flex: 0 0 260px;
    scroll-snap-align: start;
    min-width: 0;
}

.products-scroll .scroll-card .product {
    height: 100%;
}

.products-scroll .scroll-card .image img {
    width: 100%;
    height: auto;
}

.products-scroll .product-block.scroll-card > .product .caption > h4 {
    min-height: 50px;
}

.products-scroll .product-block.scroll-card > .product .caption > h4 > a {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.products-scroll .product-block.scroll-card > .product .caption > .module-attr {
    min-height: 24px;
}

/* Navigation arrows */
.scroll-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #fff;
    border: 1.5px solid #e0e0e0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    transition: all 0.2s;
}

.scroll-arrow:hover {
    border-color: #800020;
    box-shadow: 0 2px 12px rgba(128,0,32,0.15);
}

.scroll-arrow svg {
    width: 14px;
    height: 14px;
}

.scroll-arrow-left {
    left: -18px;
    display: none;
}

.scroll-arrow-right {
    right: -18px;
}

/* Fade hint on right edge */
.scroll-wrapper::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 40px;
    height: 100%;
    background: linear-gradient(to left, rgba(255,255,255,0.9), transparent);
    pointer-events: none;
    z-index: 1;
    transition: opacity 0.3s;
}

.scroll-wrapper.at-end::after {
    opacity: 0;
}

@media (max-width: 767px) {
    .products-scroll .scroll-card {
        flex: 0 0 170px;
    }
    .scroll-arrow {
        display: none !important;
    }
    .scroll-wrapper::after {
        width: 24px;
    }
}

@media (min-width: 768px) and (max-width: 1024px) {
    .products-scroll .scroll-card {
        flex: 0 0 200px;
    }
}
