/* =========================================================================
   HOMEPAGE DOCTOR REEL WIDGET & FULLSCREEN SLIDER OVERLAY
   ========================================================================= */

/* ── 1. FLOATING MINI REEL WIDGET (BOTTOM-RIGHT) ── */
.aih-floating-reel-widget {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 145px;
    height: 255px;
    border-radius: 16px;
    border: 3.5px solid #ffffff;
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.4);
    overflow: hidden;
    background: #000000;
    z-index: 9990;
    cursor: pointer;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s ease;
    user-select: none;
}

.aih-floating-reel-widget:hover {
    transform: translateY(-5px) scale(1.03);
    box-shadow: 0 16px 45px rgba(0, 0, 0, 0.5);
}

.aih-floating-reel-inner {
    width: 100%;
    height: 100%;
    position: relative;
}

.aih-floating-reel-iframe,
.aih-floating-reel-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border: none;
    pointer-events: none; /* Allows click through to container */
}

/* Floating Overlay Top Bar Controls */
.aih-floating-top-bar {
    position: absolute;
    top: 8px;
    left: 8px;
    right: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 10;
}

.aih-floating-mute-badge {
    background: rgba(0, 0, 0, 0.7);
    color: #ffffff;
    border-radius: 20px;
    padding: 3px 9px;
    font-size: 10.5px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    font-family: 'Poppins', sans-serif;
}

.aih-floating-close-btn {
    background: rgba(0, 0, 0, 0.75);
    color: #ffffff;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
}

.aih-floating-close-btn:hover {
    background: #e61d25;
    transform: scale(1.1);
}

/* Floating Doctor Bottom Label */
.aih-floating-doctor-label {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px 8px 8px 8px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0) 100%);
    color: #ffffff;
    display: flex;
    align-items: center;
    gap: 6px;
    z-index: 9;
}

.aih-floating-doctor-avatar {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    object-fit: cover;
    border: 1.5px solid #ffffff;
    flex-shrink: 0;
}

.aih-floating-doctor-name {
    font-size: 10.5px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.2;
    font-family: 'Poppins', sans-serif;
}


/* ── 2. FULLSCREEN REEL MODAL OVERLAY ── */
.aih-reel-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.96);
    z-index: 10000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    backdrop-filter: blur(8px);
    touch-action: none;
    overscroll-behavior: contain;
}

.aih-reel-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Header Bar */
.aih-reel-modal-header {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 80px;
    padding: 16px 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 10020;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0) 100%);
}

.aih-reel-doctor-info {
    display: flex;
    align-items: center;
    gap: 14px;
}

.aih-reel-doctor-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #e61d25;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
}

.aih-reel-doctor-details {
    display: flex;
    flex-direction: column;
}

.aih-reel-doctor-title {
    font-family: 'Poppins', sans-serif;
    font-size: 16px;
    font-weight: 700;
    color: #ffffff;
    margin: 0;
    line-height: 1.25;
    letter-spacing: 0.2px;
}

.aih-reel-doctor-subtitle {
    font-family: 'Poppins', sans-serif;
    font-size: 12.5px;
    color: #ffca28;
    font-weight: 500;
    margin-top: 2px;
}

/* Top Action Controls */
.aih-reel-modal-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

.aih-reel-sound-btn,
.aih-reel-close-btn {
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.25);
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
    backdrop-filter: blur(6px);
}

.aih-reel-sound-btn:hover,
.aih-reel-close-btn:hover {
    background: #e61d25;
    border-color: #e61d25;
    transform: scale(1.08);
}

/* ── 3. CENTER REEL PLAYER CONTAINER ── */
.aih-reel-player-container {
    position: relative;
    width: 100%;
    max-width: 420px;
    height: 82vh;
    max-height: 740px;
    border-radius: 20px;
    overflow: hidden;
    background: #000000;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.9);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.aih-reel-iframe-wrapper {
    width: 100%;
    height: 100%;
    position: relative;
}

.aih-reel-iframe-wrapper iframe,
.aih-reel-iframe-wrapper video {
    width: 100%;
    height: 100%;
    border: none;
    object-fit: cover;
}

/* CTA Button Overlaid at Bottom of Video */
.aih-reel-cta-overlay {
    position: absolute;
    bottom: 45px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10010;
    width: 85%;
    display: flex;
    justify-content: center;
}

.aih-reel-book-btn {
    background: linear-gradient(135deg, #e61d25 0%, #c0181b 100%);
    color: #ffffff !important;
    font-family: 'Poppins', sans-serif;
    font-size: 14.5px;
    font-weight: 700;
    padding: 13px 28px;
    border-radius: 30px;
    box-shadow: 0 6px 20px rgba(230, 29, 37, 0.6);
    display: inline-flex;
    align-items: center;
    gap: 9px;
    text-decoration: none !important;
    cursor: pointer;
    border: none;
    transition: all 0.25s ease;
    letter-spacing: 0.3px;
    width: 100%;
    justify-content: center;
}

.aih-reel-book-btn:hover {
    background: linear-gradient(135deg, #ff2a33 0%, #d91b20 100%);
    transform: scale(1.03);
    box-shadow: 0 8px 25px rgba(230, 29, 37, 0.8);
    color: #ffffff !important;
}

/* Prompt Below Video */
.aih-reel-scroll-prompt {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255, 255, 255, 0.85);
    font-family: 'Poppins', sans-serif;
    font-size: 11.5px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 6px;
    z-index: 10010;
    pointer-events: none;
}

.aih-reel-scroll-prompt i {
    animation: aihBounceDown 1.5s infinite;
}

@keyframes aihBounceDown {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(4px); }
    60% { transform: translateY(2px); }
}

/* ── 4. VERTICAL SLIDER NAVIGATION CONTROLS ── */
.aih-reel-nav-sidebar {
    position: absolute;
    right: 25px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    z-index: 10020;
}

.aih-reel-nav-btn {
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.25);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.2s ease;
    backdrop-filter: blur(6px);
}

.aih-reel-nav-btn:hover:not(:disabled) {
    background: #e61d25;
    border-color: #e61d25;
    transform: scale(1.1);
}

.aih-reel-nav-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.aih-reel-counter-badge {
    color: #ffffff;
    font-family: 'Poppins', sans-serif;
    font-size: 12px;
    font-weight: 600;
    background: rgba(0, 0, 0, 0.6);
    padding: 4px 10px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Doctor Dots Indicator Sidebar */
.aih-reel-dots-container {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 4px 0;
}

.aih-reel-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.35);
    cursor: pointer;
    transition: all 0.25s ease;
}

.aih-reel-dot.active {
    background: #e61d25;
    height: 20px;
    border-radius: 10px;
}

/* RESPONSIVE DESIGN */
@media (max-width: 768px) {
    .aih-floating-reel-widget {
        width: 120px;
        height: 210px;
        bottom: 16px;
        right: 16px;
    }
    
    .aih-reel-player-container {
        max-width: 100vw;
        height: 88vh;
        border-radius: 0;
    }
    
    .aih-reel-nav-sidebar {
        right: 12px;
    }
    
    .aih-reel-nav-btn {
        width: 38px;
        height: 38px;
        font-size: 15px;
    }
    
    .aih-reel-modal-header {
        padding: 12px 16px;
    }
    
    .aih-reel-doctor-title {
        font-size: 14px;
    }
    
    .aih-reel-doctor-subtitle {
        font-size: 11px;
    }
}

/* Ensure Booking Modal Overlay floats directly on top of Video Reel Modal */
.aih-booking-modal-overlay {
    z-index: 10050 !important;
}

/* Transparent gesture overlay to capture mobile touch swipes reliably */
.aih-reel-gesture-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 95px;
    z-index: 8;
    background: transparent;
    touch-action: none;
    cursor: pointer;
}


