.ruth2m-product-slider {
    width: 100%;
    padding: var(--wp--preset--spacing--80, 64px) 0;
    overflow: hidden;
    position: relative;
    background-color: var(--wp--preset--color--neutral-100, #F2F2F2);
}

.ruth2m-product-slider__main {
    display: flex;
    align-items: center;
    gap: var(--wp--preset--spacing--60, 48px);
}

.ruth2m-product-slider__header {
    width: 30%;
    flex-shrink: 0;
}

.ruth2m-product-slider-title {
    margin: 0 0 var(--wp--preset--spacing--30, 24px);
}

.ruth2m-product-slider__copy {
    margin: 0 0 var(--wp--preset--spacing--30, 24px);
    font-size: var(--wp--preset--font-size--small, 16px);
    color: var(--wp--preset--color--neutral-900, #191919);
}

.ruth2m-product-slider__wrapper-body {
    width: 70%;
    min-width: 0;
}

.ruth2m-product-slider__wrapper-body-inner {
    display: flex;
    align-items: center;
    position: relative;
    gap: 8px;
}

.ruth2m-product-slider__wrapper-main {
    width: 100%;
    min-width: 0;
}

.ruth2m-product-slider__swiper {
    overflow: hidden;
}

/* Force equal-height cards across a row regardless of Swiper's own default
   wrapper alignment, so a longer title/price never makes just one card
   taller than its neighbors. */
.ruth2m-product-slider__swiper .swiper-wrapper {
    align-items: stretch;
}

.ruth2m-product-slider__swiper .swiper-slide {
    height: auto;
}

/* Card — image top with hover zoom, body below (same structure as
   Information Slider's card), but with product name/price/category and an
   add-to-cart button colored via the product's category color. */
.ruth2m-product-slider__card {
    display: flex;
    flex-direction: column;
    background-color: var(--wp--preset--color--base, #FFFFFF);
    height: 100%;
}

.ruth2m-product-slider__card-figure {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background-color: var(--wp--preset--color--neutral-100, #f9f6f4);
}

.ruth2m-product-slider__card-figure img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    margin: 0;
    transition: transform 0.45s ease;
}

.ruth2m-product-slider__card:hover .ruth2m-product-slider__card-figure img {
    transform: scale(1.05);
}

.ruth2m-product-slider__badge {
    position: absolute;
    z-index: 2;
    top: 10px;
    left: 10px;
    padding: 4px 10px;
    border-radius: 999px;
    background-color: var(--ruth2m-product-slider-color, #252525);
    color: var(--wp--preset--color--base, #fff);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.ruth2m-product-slider__card-body {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    padding: var(--wp--preset--spacing--20, 16px);
}

.ruth2m-product-slider__card-category {
    display: inline-block;
    margin-bottom: 6px;
    color: var(--ruth2m-product-slider-color, #252525);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.ruth2m-product-slider__card-title {
    margin: 0 0 6px;
    font-size: var(--wp--preset--font-size--medium, 16px);
    line-height: 1.3;
    /* No clipping — full title always shows. Slides in the same row still
       equalize to the tallest card (see .swiper-wrapper stretch below), so
       cards never look ragged even when one title runs to 3 lines. */
    min-height: calc(1.3em * 2);
}

.ruth2m-product-slider__card-title a {
    color: var(--wp--preset--color--contrast, #000);
    text-decoration: none;
}

.ruth2m-product-slider__card-body .price {
    display: block;
    min-height: 1.3em;
    margin-bottom: 12px;
    font-size: 14px;
    font-weight: 600;
    color: var(--wp--preset--color--neutral-700, #404040);
}

.ruth2m-product-slider .ruth2m-product-slider__card-button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    margin-top: auto;
    padding: 10px 14px;
    border: none;
    border-radius: 6px;
    background-color: var(--ruth2m-product-slider-color, #252525);
    color: var(--wp--preset--color--base, #fff);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.02em;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: filter 0.2s ease;
}

.ruth2m-product-slider .ruth2m-product-slider__card-button::before {
    display: none;
}

.ruth2m-product-slider .ruth2m-product-slider__card-button:hover {
    filter: brightness(0.9);
    background-color: var(--ruth2m-product-slider-color, #252525);
    color: var(--wp--preset--color--base, #fff);
    border-color: transparent;
}

.ruth2m-product-slider .ruth2m-product-slider__card-button.added {
    display: none;
}

.ruth2m-product-slider__arrow {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1.5px solid var(--wp--preset--color--neutral-300, #D9D4D0);
    background: var(--wp--preset--color--base, #fff);
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.ruth2m-product-slider__arrow::before {
    content: '';
    display: block;
    width: 18px;
    height: 18px;
    mask-size: contain;
    mask-repeat: no-repeat;
    mask-position: center;
    background-color: var(--wp--preset--color--contrast, #000);
}

.ruth2m-product-slider__arrow:hover {
    background-color: var(--wp--preset--color--contrast, #000);
}

.ruth2m-product-slider__arrow:hover::before {
    background-color: var(--wp--preset--color--base, #fff);
}

.ruth2m-product-slider__arrow-prev::before {
    mask-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none"><path d="M21.2998 12L3.2998 12" stroke="%23000" stroke-width="2"/><path d="M12.2998 21L3.29981 12L12.2998 3" stroke="%23000" stroke-width="2"/></svg>');
}

.ruth2m-product-slider__arrow-next::before {
    mask-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none"><path d="M21.2998 12L3.2998 12" stroke="%23000" stroke-width="2"/><path d="M12.2998 21L21.2998 12L12.2998 3" stroke="%23000" stroke-width="2"/></svg>');
}

@media (max-width: 1099px) {
    .ruth2m-product-slider__main {
        flex-direction: column;
        align-items: stretch;
    }

    .ruth2m-product-slider__header,
    .ruth2m-product-slider__wrapper-body {
        width: 100%;
    }

    .ruth2m-product-slider__header {
        margin-bottom: var(--wp--preset--spacing--40, 32px);
    }
}

@media (max-width: 680px) {
    .ruth2m-product-slider__arrow {
        display: none;
    }
}
