/* MageTime Apps widget styles — product cards drag slider */

.relx-home .rx-section--flush .rx-cards-wrap {
    max-width: none;
    width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    position: relative;
}

.relx-home .rx-cards-slider {
    position: relative;
}

.relx-home .rx-cards-slider .rx-cards {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(280px, 300px);
    gap: 20px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 8px var(--rx-content-inset) 20px;
    scrollbar-width: none;
    -ms-overflow-style: none;
    cursor: grab;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-x;
    user-select: none;
    overscroll-behavior-x: contain;
    scroll-behavior: auto;
}

.relx-home .rx-cards-slider .rx-cards::-webkit-scrollbar {
    display: none;
}

.relx-home .rx-cards-slider .rx-cards.is-dragging {
    cursor: grabbing;
}

.relx-home .rx-cards-slider .rx-cards.is-springing {
    transition: transform 0.32s cubic-bezier(0.33, 1, 0.68, 1);
    will-change: transform;
}

.relx-home .rx-cards-slider .rx-cards.is-dragging .rx-card {
    pointer-events: none;
    transition: none;
}

.relx-home .rx-card {
    position: relative;
    border-radius: var(--rx-radius, 18px);
    overflow: hidden;
    aspect-ratio: 3 / 4;
    min-height: 360px;
    /* background: #1a1a1a; */
    box-shadow: 0 16px 32px -20px rgba(0, 0, 0, .32);
    transition: transform .3s cubic-bezier(.22, 1, .36, 1), box-shadow .3s ease;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    user-select: none;
    text-decoration: none;
    color: inherit;
}

.relx-home .rx-cards-slider .rx-cards:not(.is-dragging) .rx-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 24px 40px -18px rgba(0, 0, 0, .4);
    z-index: 2;
}

.relx-home .rx-card-media {
    position: absolute;
    inset: 0;
    overflow: hidden;
}

.relx-home .rx-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform .55s cubic-bezier(.22, 1, .36, 1);
    pointer-events: none;
}

.relx-home .rx-cards-slider .rx-cards:not(.is-dragging) .rx-card:hover .rx-card-img {
    transform: scale(1.06);
}

.relx-home .rx-card-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, 0) 42%,
        rgba(0, 0, 0, .25) 62%,
        rgba(0, 0, 0, .82) 100%
    );
    pointer-events: none;
}

.relx-home .rx-card-body {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2;
    padding: 16px 18px 20px;
    color: #fff;
    pointer-events: none;
}

.relx-home .rx-card-title {
    margin: 0 0 4px;
    font-size: 18px;
    font-weight: 800;
    line-height: 1.25;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
}

.relx-home .rx-card .quote {
    font-size: 12px;
    opacity: .88;
    font-style: italic;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
}

@media (max-width: 1024px) {
    .relx-home .rx-cards-slider .rx-cards {
        grid-auto-columns: minmax(260px, 280px);
    }
}

@media (max-width: 768px) {
    .relx-home .rx-cards-slider .rx-cards {
        grid-auto-columns: 78%;
        gap: 16px;
    }

    .relx-home .rx-card {
        min-height: 320px;
    }
}

@media (max-width: 480px) {
    .relx-home .rx-cards-slider .rx-cards {
        grid-auto-columns: 84%;
    }

    .relx-home .rx-card-title {
        font-size: 16px;
    }
}
