/* Media Grid & Cards */
.media-card {
    position: relative;
    cursor: pointer;
}

.media-card video {
    display: none;
    width: 100%;
    height: 100%;
}

.play-btn {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 40px;
    color: #fff;
    background: rgba(0, 0, 0, 0.4);
}

.media-card.playing img,
.media-card.playing .play-btn {
    display: none;
}

.media-card.playing video {
    display: block;
}


/* Moments Section */
.moments-sticky-container {
    height: 300vh;
    /* 3 screens worth of scroll-room */
    position: relative;
}

.moments-vertical-wrapper {
    position: sticky;
    top: 0;
    width: 100%;
    height: 100vh;
    height: 100dvh;
    overflow: hidden;
    background: #000;
    z-index: 100;
}

.moments-vertical-swiper {
    width: 100%;
    height: 100%;
}

.moments-vertical-swiper>.swiper-wrapper>.swiper-slide {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100vh !important;
    height: 100dvh !important;
}

.moments-section {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    margin: 0;
}

.moments-container {
    position: relative;
    width: 450px;
    height: 800px;
    max-height: 100vh;
    max-height: 100dvh;
    border-radius: 40px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    background: #000;
}

.moments-bg {
    position: absolute;
    inset: 0;
    z-index: 1;
}

.moments-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.moments-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.5) 0%, transparent 30%, transparent 70%, rgba(0, 0, 0, 0.7) 100%),
        radial-gradient(circle at left, rgba(0, 0, 0, 0.3) 0%, transparent 40%);
    /* Vignette for side icons */
    z-index: 2;
}

.moments-top {
    position: absolute;
    top: 40px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 30px;
    z-index: 10;
}

.moments-logo {
    color: #fff;
    font-size: 28px;
    font-weight: bold;
    font-family: 'Playfair Display SC Bold', sans-serif;
    letter-spacing: 1px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);

    img {
        width: 60px;
        height: 60px;
    }
}

.moments-share {
    position: relative;
    color: #fff;
    font-size: 28px;
    cursor: pointer;
    filter: drop-shadow(0 0 8px rgba(0, 0, 0, 0.9));
}

.moments-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
}

.moments-center .play-icon {
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 30px;
    cursor: pointer;
    transition: transform 0.3s;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.4);
}

.moments-center .play-icon:hover {
    transform: scale(1.1);
}

.moments-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.moments-actions .action-item {
    color: #fff;
    font-size: 28px;
    cursor: pointer;
    transition: transform 0.2s;
    filter: drop-shadow(0 0 10px rgba(0, 0, 0, 1));
    display: flex;
    align-items: center;
    justify-content: center;
}

.moments-actions .action-item:hover {
    transform: scale(1.2);
}

.moments-actions .action-item.wishlist-active i {
    color: #ff4d4d;
    font-family: "uicons-solid-rounded" !important;
}

.moments-actions .action-item.mute-toggle.muted i {
    color: #ff4d4d;
}

/* Play/Pause Overlay */
.play-pause-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 15;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.play-pause-overlay.show {
    opacity: 1;
}


.play-pause-overlay i {
    font-size: 36px;
    color: #fff;
    margin-left: 5px;
}

/* Video Loader / Animated Thumbnail */
.video-loader {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent;
    /* Changed from #000 to transparent */
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 4;
    transition: opacity 0.3s ease, visibility 0.3s;
    backdrop-filter: blur(5px);
}

.video-loader.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.spinning-logo {
    width: 60px !important;
    height: 60px !important;
    object-fit: contain;
    filter: drop-shadow(0 0 10px rgba(0, 0, 0, 0.3));
    animation: slowSpin 3s linear infinite;
}

@keyframes slowSpin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}


.moments-bottom {
    position: absolute;
    bottom: 50px;
    left: 0;
    right: 0;
    padding: 0 0 0 20px;
    /* Left padding for swiper start */
    z-index: 10;
    display: flex;
    align-items: flex-end;
    gap: 15px;
}

.moments-products-swiper {
    width: 100%;
    padding-bottom: 10px;
}

.moments-products-swiper .swiper-slide {
    width: auto;
    /* Fix for slidesPerView: 'auto' */
}

.moments-product-card {
    min-width: 280px;
    background: rgba(49, 33, 17, 0.8);
    backdrop-filter: blur(10px);
    border-radius: 60px;
    padding: 10px 20px 10px 10px;
    display: flex;
    align-items: center;
    gap: 15px;
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.product-img-circle {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    overflow: hidden;
    background: #fff;
    flex-shrink: 0;
}

.product-img-circle img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-info h4 {
    margin: 0;
    font-size: 18px;
    font-weight: 400;
    font-family: 'Satoshi', sans-serif;
}

.product-info p {
    margin: 5px 0 0;
    font-size: 14px;
    opacity: 0.8;
    font-family: 'Satoshi', sans-serif;
}

.moments-fullscreen {
    color: #fff;
    font-size: 22px;
    cursor: pointer;
    margin-bottom: 30px;
}

/* Fullscreen styles */
.moments-vertical-wrapper:fullscreen,
.moments-vertical-wrapper:-webkit-full-screen {
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    background: #000;
}

.moments-vertical-wrapper:fullscreen .moments-container,
.moments-vertical-wrapper:-webkit-full-screen .moments-container {
    width: 100%;
    height: 100%;
    max-height: 100vh;
    max-height: 100dvh;
    border-radius: 0;
}

@media (min-width: 769px) {
    .moments-sticky-container {
        display: none;
    }
}

/* Responsive Moments */
@media (max-width: 768px) {
    .moments-section {
        padding: 0;
    }

    .moments-container {
        width: 100%;
        height: 100dvh;
        max-height: 100dvh;
        border-radius: 0;
    }
}