/* Styles for the Full-Screen Swipeable Reels Popup */

.reels-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.reels-modal.active {
    opacity: 1;
    visibility: visible;
}

/* This is the "viewport" for our videos */
.reels-modal-content {
    position: relative;
    width: 100%;
    height: 100%;
    max-width: 450px;
    max-height: 95vh;
    overflow: hidden; /* This hides the other video slides */
    border-radius: 1rem;
}

/* This is the track that holds the three videos and slides up/down */
.reels-video-track {
    position: relative;
    width: 100%;
    height: 300%;
    top: -100%;
    /* This new timing function creates the "snap" effect */
    transition: top 0.5s cubic-bezier(0.23, 1, 0.32, 1); 
}

.reels-video-slide {
    width: 100%;
    height: 33.3333%; /* Each slide takes up 1/3 of the track height */
    display: flex;
    align-items: center;
    justify-content: center;
}

.reels-modal-video {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Controls and overlays */
.reels-modal-close,
.reels-modal-mute-btn,
.reels-modal-nav,
.reels-modal-title,
.reel-play-pause-icon {
    position: absolute;
    z-index: 10;
}

.reels-modal-close {
    top: 15px; right: 15px; font-size: 2rem; color: white; background: none; border: none; cursor: pointer;
}
.reels-modal-mute-btn {
    top: 15px; left: 15px; width: 40px; height: 40px; border-radius: 50%; border: none; background-color: rgba(0, 0, 0, 0.5); color: white; font-size: 1.2rem; cursor: pointer; display: flex; align-items: center; justify-content: center;
}
.reels-modal-nav {
    right: 15px; top: 50%; transform: translateY(-50%); display: flex; flex-direction: column; gap: 1rem;
}
.reels-modal-nav button {
    width: 40px; height: 40px; border-radius: 50%; border: none; background-color: rgba(255, 255, 255, 0.2); color: white; font-size: 1.5rem; cursor: pointer; transition: background-color 0.2s ease;
}
.reels-modal-nav button:hover {
    background-color: rgba(255, 255, 255, 0.4);
}
.reels-modal-title {
    bottom: 20px; left: 20px; color: white; font-size: 1.2rem; font-weight: bold; text-shadow: 1px 1px 3px rgba(0,0,0,0.7);
}

.reel-play-pause-icon {
    top: 50%; left: 50%; transform: translate(-50%, -50%); font-size: 5rem; color: rgba(255, 255, 255, 0.85); pointer-events: none; opacity: 0; transition: opacity 0.2s ease-in-out; text-shadow: 0 2px 10px rgba(0,0,0,0.5);
}
.reel-play-pause-icon.visible {
    opacity: 1;
}