﻿.slide-homepage {
    padding: 65px 15% 65px 14%;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.wrapper {
    width: 100%;
    position: relative;
}

    .wrapper i {
        height: 50px;
        width: 50px;
        background: #F3F4F6;
        text-align: center;
        line-height: 50px;
        border-radius: 50%;
        cursor: pointer;
        position: absolute;
        top: 50%;
        font-size: 1.25 rem;
        transform: translateY(-50%);
        box-shadow: 0 3px 6px rgba(0, 0, 0, 0.23);
    }

        .wrapper i:first-child {
            left: -75px;
        }

        .wrapper i:last-child {
            right: -70px;
        }

    .wrapper .carousel {
        display: grid;
        grid-auto-flow: column;
        grid-auto-columns: calc((100% / 3) - 12px);
        gap: 24px;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        scroll-behavior: smooth;
        scrollbar-width: 0;
    }

.carousel::-webkit-scrollbar {
    display: none;
}

.carousel :where(.card, .img) {
    display: flex;
    align-items: center;
    justify-content: center;
}

.carousel.dragging {
    scroll-snap-type: none;
    scroll-behavior: auto;
}

.carousel.no-transition {
    scroll-behavior: auto;
}

.carousel.dragging .card {
    cursor: grab;
    user-select: none;
}

.carousel .card {
    scroll-snap-align: start;
    list-style: none;
    background: #fff;
    cursor: pointer;
    padding-bottom: 15px;
}
.card a {
    display: flex;
    flex-direction: column;
    gap: 16px;
    background-repeat: no-repeat;
    background-size: cover;
    width: 98%;
    height: 350px;
    justify-content: end;
    padding: 17px;
}
    .card span {
        color: white;
        font-size: 16px;
        font-weight: 600;
        line-height: 22px;
        overflow: hidden;
        display: -webkit-box;
        -webkit-line-clamp: 3;
        line-clamp: 3;
        -webkit-box-orient: vertical;
        text-align: justify;
    }

@media (min-width: 1261px) and (max-width: 1420px) {
    .wrapper i:first-child {
        left: -75px;
    }

    .wrapper i:last-child {
        right: -70px;
    }

    .wrapper .carousel {
        grid-auto-columns: calc(100% / 3);
    }
    .slide-homepage {
        padding: 65px 10% 65px 15%;
    }
}
@media (min-width: 992px) and (max-width: 1260px) {
    .wrapper i:first-child {
        display: none
    }

    .wrapper i:last-child {
        display: none
    }

    .wrapper .carousel {
        grid-auto-columns: calc(100% / 2);
    }
}
@media (min-width: 601px) and (max-width: 991px) {
    .wrapper i:first-child {
        display: none
    }

    .wrapper i:last-child {
        display: none
    }

    .wrapper .carousel {
        grid-auto-columns: calc((100% / 1) + 30px);
    }
    .slide-homepage {
        padding: 65px 5% 65px 5%;
    }
}

@media (max-width: 600px) {
    .wrapper .carousel {
        grid-auto-columns: calc((100% / 1) + 30px);
    }
    .wrapper i:first-child {
       display: none
    }

    .wrapper i:last-child {
        display: none
    }
    .slide-homepage {
        padding: 65px 5% 65px 5%;
    }
}
