#carousel,
.carousel-item,
.carousel-clone,
.carousel-item img {
    user-select: none;
    -webkit-user-select: none;
    -webkit-user-drag: none;
    /* Specifically stops the "drag to desktop" ghosting */
    touch-action: pan-y;
    /* Allows scrolling up/down the page but takes over left/right */
}

.inner-no-transition,
.inner-no-transition * {
    transition: none !important;
}

.carolWrapper {
    margin-top: 20px;
    margin-left: 15px;
    margin-right: 15px;
    margin-bottom: 20px;
    z-index: 2;
}

.carolBG {
    /* background-color: var(--section-bg); */
    background: linear-gradient(90deg, var(--section-edge-bg) 0%, var(--section-bg) 50%, var(--section-edge-bg) 100%);
    border-radius: 10px;
    padding-top: 30px;
    box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.3);
    border: 1px solid var(--section-border);
    transition: background-color 0.3s ease, --section-bg 0.3s ease, --section-edge-bg 0.3s ease, border-color 0.3s ease;
    z-index: 3;
}

#carousel {
    position: relative;
    width: 100%;
    max-width: 1200px;
    /* Binds the carousel directly to your content width boundaries */
    margin: 0 auto;
    overflow: hidden;
    cursor: grab;
    user-select: none;
    -webkit-user-select: none;
    touch-action: pan-y;
    padding: 5rem 0 16rem 0;
    /* Extra bottom padding leaves room for the surface reflection */
}

#carousel:active {
    cursor: grabbing;
}

.carousel-inner {
    display: flex;
    align-items: center;
    /* gap: -40px; Tight, premium spacing to bring images closer on wide screens */
    will-change: transform;
    transform: translate3d(0, 0, 0);
    padding-top: 20px;

}

.carousel-item,
.carousel-clone {
    position: relative;
    flex: 0 0 33%;
    min-width: 320px;
    max-width: 320px;
    width: 320px;
    height: 760px;
    border-radius: 8px;
    box-sizing: border-box;
    will-change: transform, opacity;

    opacity: 0.4;
    /* This ensures clones are dimmed */
    filter: blur(4px) grayscale(30%);
    transform: scale(0.9);
    transition: transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1),
        opacity 0.8s cubic-bezier(0.2, 0.8, 0.2, 1),
        filter 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.carousel-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: top center;
    pointer-events: none;
    will-change: transform;
    transform: translate3d(var(--parallax-shift, 0px), 0, 0);
}

.carousel-item.active,
.carousel-clone.active {
    opacity: 1;
    filter: blur(0px) grayscale(0%);
    transform: scale(1.1);
    z-index: 5;
}

.carousel-item.active {
    opacity: 1 !important;
    filter: blur(0px) grayscale(0%) !important;
    transform: scale(1.1) !important;
    z-index: 10;
}

.carousel-item.prev-active,
.carousel-clone.prev-active,
.carousel-item.next-active,
.carousel-clone.next-active {
    opacity: 0.55;
    filter: blur(2px) grayscale(15%);
    transform: scale(0.94);
    z-index: 4;
}

.carousel-item::before {
    content: "";
    position: absolute;
    bottom: 0px;
    left: 50%;
    transform: translateX(-50%) translateY(50%);

    width: 600px;
    /* Adjust this width based on the diameter of the bottle */
    height: 32px;
    background: radial-gradient(ellipse at center, rgba(0, 0, 0, 1) 0%, rgba(0, 0, 0, 0.30) 30%, rgba(0, 0, 0, 0) 70%);
    border-radius: 50%;
    pointer-events: none;
    z-index: 4;

    /* Hardware acceleration */
    will-change: transform, opacity;
    opacity: 0.4;
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1),
        opacity 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

.carousel-item.active::before {
    opacity: 1;
    padding: 100px;
    width: 600px;
    /* Automatically widen */
    background: radial-gradient(ellipse 85% 95% at center, rgba(0, 0, 0, 0.95) 3%, rgba(0, 0, 0, 0.001) 30%, rgba(0, 0, 0, 0) 60%);
}

.reflection {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    height: 90%;
    margin-top: -25px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center top;
    will-change: transform;
    transform: scaleY(-1) translate3d(var(--parallax-shift, 0px), 0, 0);
    /* Flip the image */
    opacity: 0.75;
    pointer-events: none;

    /* Smooth linear fade to bleed cleanly into backgrounds */
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 1) 100%);
    -webkit-mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 1) 100%);
    filter: blur(10px);
    -webkit-filter: blur(10px);
}

.carousel-clone .carousel-text {
    display: block !important;
    /* Ensure it stays in the DOM */
}

.carousel-text {
    position: absolute;
    bottom: 0px;
    left: 50%;
    transform: translateX(-50%) translateY(15px);
    width: 100%;
    padding: 1.5rem;
    background: rgba(10, 10, 10, 0.7);
    box-shadow: 0px 3px 10px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    -webkit-backdrop-filter: blur(16px) saturate(130%);
    backdrop-filter: blur(16px) saturate(130%);
    color: #ffffff;
    text-align: center;
    z-index: 10;

    visibility: hidden;
    opacity: 0;
    transition: opacity 0.5s cubic-bezier(0.25, 1, 0.5, 1),
        transform 0.5s cubic-bezier(0.25, 1, 0.5, 1),
        visibility 0.5s ease;
}


.carousel-item.active .carousel-text {
    visibility: visible;
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.glass-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-top: 12px;
    padding: 0.6rem 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 30px;
    color: #FFFFFF;
    text-decoration: none;
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 1px;
    text-transform: uppercase;
    transition: background 0.3s, border-color 0.3s, transform 0.3s;
    cursor: pointer;
    z-index: 12;
}

.glass-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 220, 20, 0.75);
    color: #FFCC33;
    /* transform: translateY(-2px); */
}

/* Nav Utilities */
.carousel-btn {
    position: absolute;
    top: 60%;
    transform: translateY(-50%);
    background: rgba(4, 5, 1, 0.8);
    color: rgba(134, 134, 134, 0.8);
    border: 1px solid rgba(138, 138, 138, 0.216);
    width: 46px;
    height: 46px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}

@media (hover: hover) {
    .carousel-btn:hover {
        background: rgba(33, 33, 33, 0.75);
        border-color: rgba(255, 220, 20, 0.75);
        color: #FFCC33;
    }
}

.carousel-btn:active {
    background: rgba(33, 33, 33, 0.9);
    border-color: rgba(255, 220, 20, 0.75);
    color: #FFCC33;
}

.carousel-btn.prev {
    left: 10px;
}

.carousel-btn.next {
    right: 10px;
}

/* Responsive for Tablets (Portrait & Landscape limits) */
@media screen and (min-width: 769px) and (max-width: 1024px) {

    .carousel-item,
    .carousel-clone {
        flex: 0 0 35%;
        min-width: 280px;
        max-width: 300px;
        width: 300px;
        height: 620px;
    }

    #carousel {
        padding: 3rem 0 6rem 0;
        /* Reduced bottom padding */
    }

    .reflection {
        display: none !important;
        /* Hide blur calculations on tablet */
    }
}

/* Responsive for Phones */
@media screen and (max-width: 768px) {

    .carousel-item,
    .carousel-clone {
        flex: 0 0 78%;
        min-width: 250px;
        max-width: 280px;
        width: 280px;
        height: 480px;
    }

    .carousel-inner {
        gap: 16px;
    }

    #carousel {
        padding: 3rem 0 5rem 0;
        /* Reduced bottom padding */
    }

    .reflection {
        display: none !important;
        /* Hide blur calculations on mobile */
    }

    .carousel-text {
        width: 90%;
        padding: 1rem;
    }

    .carousel-btn {
        top: 85%;
    }
}