/* Discover carousel: intentionally loaded after the legacy theme styles. */
.doreanse-collections {
    overflow: hidden;
    padding: 72px 0 21px;
}

.doreanse-collections .section-heading {
    margin-bottom: 22px;
    text-align: center;
}

.doreanse-collections .section-heading h2 {
    margin: 0;
    color: #171717;
    font-family: var(--doreanse-display, Georgia, serif);
    font-size: clamp(27px, 2.5vw, 34px);
    font-weight: 500;
    letter-spacing: .20em;
    line-height: 1.15;
    text-transform: uppercase;
}

.collection-carousel {
    position: relative;
    width: 100%;
    padding: 0;
    box-sizing: border-box;
}

.collection-carousel .collection-rail {
    display: flex;
    align-items: center;
    gap: 22px;
    width: auto;
    min-height: 470px;
    margin: 0;
    padding: 52px calc(50% - 102px);
    overflow-x: auto;
    overflow-y: hidden;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    cursor: grab;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
    touch-action: pan-x;
}

.collection-carousel .collection-rail::-webkit-scrollbar {
    display: none;
}

.collection-carousel .collection-rail.is-dragging {
    cursor: grabbing;
    scroll-behavior: auto;
    scroll-snap-type: none;
    user-select: none;
}

.collection-carousel .collection-pill {
    position: relative;
    display: block;
    flex: 0 0 204px;
    width: 204px;
    height: 340px;
    margin: 0;
    padding: 0;
    overflow: hidden;
    border: 1px solid rgba(23, 23, 23, .16);
    border-radius: 0;
    background: #e7ecef;
    box-shadow: 0 12px 30px rgba(17, 17, 17, .10);
    opacity: .42;
    transform: scale(.64);
    transform-origin: center;
    transition: transform .46s cubic-bezier(.2, .75, .25, 1), opacity .38s ease, box-shadow .38s ease;
    scroll-snap-align: center;
    isolation: isolate;
}

.collection-carousel .collection-pill.is-far {
    z-index: 0;
    opacity: .42;
    transform: scale(.64);
}

.collection-carousel .collection-pill.is-mid {
    z-index: 1;
    opacity: .58;
    transform: scale(.75);
}

.collection-carousel .collection-pill.is-near {
    z-index: 2;
    opacity: .78;
    transform: scale(.89);
}

.collection-carousel .collection-pill.is-active {
    z-index: 4;
    opacity: 1;
    transform: scale(1.18);
    box-shadow: 0 24px 54px rgba(17, 17, 17, .20);
}

.collection-carousel .collection-pill__media {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    border-radius: inherit;
    overflow: hidden;
}

.collection-carousel .collection-pill__media::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 0%, transparent 62%, rgba(0, 0, 0, .58) 100%);
    pointer-events: none;
}

.collection-carousel .collection-pill__media img {
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
    transition: transform .55s ease;
}

.collection-carousel .collection-pill.is-active:hover .collection-pill__media img {
    transform: scale(1.045);
}

.collection-carousel .collection-pill__gender-links {
    position: absolute;
    z-index: 2;
    inset: 0;
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 100%;
    height: 100%;
    border: 0;
    border-radius: 0;
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    overflow: hidden;
}

.collection-carousel .collection-pill__gender-links::after {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 1px;
    background: rgba(255, 255, 255, .62);
    transform: translateX(-.5px);
    pointer-events: none;
}

.collection-carousel .collection-pill__gender-links--single {
    grid-template-columns: 1fr;
}

.collection-carousel .collection-pill__gender-links--single::after {
    display: none;
}

.collection-carousel .collection-pill__gender-link,
.collection-carousel .collection-pill__gender-link + .collection-pill__gender-link {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    min-width: 0;
    height: 100%;
    margin: 0;
    padding: 0 6px 18px;
    border: 0 !important;
    color: #fff;
    font-family: var(--doreanse-body, Arial, sans-serif);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .11em;
    line-height: 1;
    text-decoration: none;
    text-shadow: 0 1px 3px rgba(0, 0, 0, .45);
    transition: background .2s ease;
}

.collection-carousel .collection-pill__gender-link:hover,
.collection-carousel .collection-pill__gender-link:focus {
    background: rgba(0, 0, 0, .10);
    color: #fff;
}

.collection-carousel .collection-pill__gender-link span {
    position: static;
    display: inline;
    min-width: 58px;
    padding: 0 3px 5px;
    border-bottom: 1px solid rgba(255, 255, 255, .78);
    color: inherit;
    background: none;
    text-align: center;
}

.collection-carousel .collection-pill__category-title {
    position: absolute;
    z-index: 4;
    top: 50%;
    bottom: auto;
    left: 50%;
    width: 100%;
    padding: 0 10px;
    box-sizing: border-box;
    color: #fff;
    font-family: var(--doreanse-body, Arial, sans-serif);
    font-size: 15px;
    font-weight: 700;
    letter-spacing: .13em;
    line-height: 1.2;
    text-align: center;
    text-shadow: 0 1px 4px rgba(0, 0, 0, .65);
    transform: translate(-50%, -50%);
    pointer-events: none;
}

.collection-carousel .collection-arrow {
    position: absolute;
    z-index: 8;
    top: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    margin: 0;
    padding: 0;
    border: 1px solid rgba(23, 23, 23, .3);
    border-radius: 50%;
    background: rgba(251, 252, 252, .88);
    color: #171717;
    box-shadow: 0 8px 24px rgba(17, 17, 17, .12);
    font-size: 23px;
    line-height: 1;
    transform: translateY(-50%);
    transition: background .2s ease, color .2s ease, transform .2s ease;
    backdrop-filter: blur(8px);
}

.collection-carousel .collection-arrow:hover {
    background: #171717;
    color: #fff;
    transform: translateY(-50%) scale(1.06);
}

.collection-carousel .collection-arrow--prev {
    left: 16px;
}

.collection-carousel .collection-arrow--next {
    right: 16px;
}

@media (max-width: 767px) {
    .doreanse-collections {
        padding: 48px 0 14px;
    }

    .doreanse-collections .section-heading {
        margin-bottom: 10px;
    }

    .doreanse-collections .section-heading h2 {
        font-size: 25px;
        letter-spacing: .16em;
    }

    .collection-carousel {
        padding: 0;
    }

    .collection-carousel .collection-rail {
        gap: 14px;
        min-height: 400px;
        padding: 38px calc(50% - 84px);
    }

    .collection-carousel .collection-pill {
        flex-basis: 168px;
        width: 168px;
        height: 286px;
        border-radius: 0;
    }

    .collection-carousel .collection-pill.is-active {
        transform: scale(1.13);
    }

    .collection-carousel .collection-pill__gender-link,
    .collection-carousel .collection-pill__gender-link + .collection-pill__gender-link {
        padding: 0 4px 15px;
    }

    .collection-carousel .collection-arrow {
        width: 40px;
        height: 40px;
        font-size: 19px;
    }

    .collection-carousel .collection-arrow--prev {
        left: 10px;
    }

    .collection-carousel .collection-arrow--next {
        right: 10px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .collection-carousel .collection-rail {
        scroll-behavior: auto;
    }

    .collection-carousel .collection-pill,
    .collection-carousel .collection-pill__media img {
        transition: none;
    }
}
