.berg-product-carousel {
    width: 100%;
    padding: 42px 0;
}

.berg-product-carousel__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin: 0 0 26px;
}

.berg-product-carousel__title {
    margin: 0 !important;
    color: var(--berg-primary);
    font-size: clamp(26px, 3vw, 36px);
    font-weight: 400;
}

.berg-product-carousel__overview {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 210px;
    min-height: 62px;
    padding: 12px 28px;
    border-radius: 999px;
    background: var(--berg-primary);
    color: #fff !important;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    text-transform: uppercase;
    transition: background-color 160ms ease;
}

.berg-product-carousel__overview:hover {
    background: var(--berg-primary-hover);
}

.berg-product-carousel__viewport {
    position: relative;
}

.berg-product-carousel__track {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    padding: 0;
    scrollbar-width: none;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
}

.berg-product-carousel__track::-webkit-scrollbar {
    display: none;
}

.berg-product-carousel__card {
    flex: 0 0 calc((100% - 32px) / 3);
    min-width: 0;
    overflow: hidden;
    background: #fff;
    scroll-snap-align: start;
}

.berg-product-carousel__image-link,
.berg-product-carousel__image {
    display: block;
    width: 100%;
}

.berg-product-carousel__image {
    aspect-ratio: 4 / 5;
    object-fit: cover;
    object-position: top center;
}

.berg-product-carousel .berg-card-footer p {
    margin-bottom: 0;
}

.berg-product-carousel .berg-card-footer__info {
    padding-right: 14px;
}

.berg-product-carousel .berg-card-footer__name {
    color: #fff !important;
}

.berg-product-carousel__arrow {
    position: absolute;
    top: 50%;
    z-index: 2;
    width: 24px;
    height: 42px;
    border: 0;
    background: transparent;
    cursor: pointer;
    transform: translateY(-50%);
    transition: opacity 160ms ease;
}

.berg-product-carousel__arrow::before {
    content: "";
    position: absolute;
    top: 8px;
    width: 20px;
    height: 20px;
    border-top: 2px solid var(--berg-primary);
    border-right: 2px solid var(--berg-primary);
}

.berg-product-carousel__arrow--previous {
    left: -54px;
}

.berg-product-carousel__arrow--previous::before {
    left: 6px;
    transform: rotate(-135deg);
}

.berg-product-carousel__arrow--next {
    right: -54px;
}

.berg-product-carousel__arrow--next::before {
    right: 6px;
    transform: rotate(45deg);
}

.berg-product-carousel__arrow:disabled {
    cursor: default;
    opacity: 0.24;
}

@media (max-width: 980px) {
    .berg-product-carousel__arrow--previous {
        left: -36px;
    }

    .berg-product-carousel__arrow--next {
        right: -36px;
    }

    .berg-product-carousel__card {
        flex-basis: calc((100% - 16px) / 2);
    }
}

@media (max-width: 600px) {
    .berg-product-carousel__header {
        align-items: flex-start;
        flex-direction: column;
        margin-bottom: 18px;
    }

    .berg-product-carousel__overview {
        min-width: 170px;
        min-height: 48px;
    }

    .berg-product-carousel__arrow--previous {
        left: -22px;
    }

    .berg-product-carousel__arrow--next {
        right: -22px;
    }

    .berg-product-carousel__card {
        flex-basis: 100%;
    }
}
