/* BridgeBrain Intro Video Modal Styles */

.bb-intro-video-modal-wrapper {
    display: none;
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    height: 100dvh !important; /* Dynamic viewport height for mobile browsers */
    z-index: 999999 !important;
    margin: 0 !important;
    padding: 0 !important;
}

.bb-intro-video-modal-wrapper.bb-active {
    display: block !important;
}

.bb-intro-video-overlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    height: 100dvh !important; /* Dynamic viewport height for mobile browsers */
    background-color: rgba(0, 0, 0, 0.6) !important;
    cursor: pointer !important;
    z-index: 999999 !important;
}

.bb-intro-video-container {
    position: fixed !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
    width: auto !important;
    max-width: 90vw !important;
    max-height: 90vh !important;
    max-height: 90dvh !important; /* Dynamic viewport height for mobile browsers */
    background: #000 !important;
    border: 3px solid #000 !important;
    border-radius: 8px !important;
    overflow: visible !important;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.8) !important;
    z-index: 1000000 !important;
    display: flex !important;
    flex-direction: column !important;
}

.bb-intro-video-header {
    background: #000 !important;
    padding: 10px 50px 10px 15px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    border-bottom: 2px solid #1a1a1a !important;
    position: relative !important;
    flex-shrink: 0 !important;
    min-height: 48px !important;
}

.bb-intro-video-title {
    color: #87ceeb !important;
    font-size: 16px !important;
    font-weight: 600 !important;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif !important;
    margin: 0 !important;
    padding: 0 !important;
    line-height: 1.3 !important;
}

.bb-intro-video-close {
    position: absolute !important;
    top: 6px !important;
    right: 6px !important;
    width: 36px !important;
    height: 36px !important;
    min-width: 36px !important;
    min-height: 36px !important;
    background: #fff !important;
    border: none !important;
    border-radius: 50% !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    z-index: 1000001 !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3) !important;
    transition: all 0.2s ease !important;
    padding: 0 !important;
    margin: 0 !important;
    -webkit-tap-highlight-color: transparent !important;
}

.bb-intro-video-close:hover,
.bb-intro-video-close:active {
    background: #f0f0f0 !important;
    transform: scale(1.1) !important;
}

.bb-intro-video-close svg {
    color: #333 !important;
    width: 20px !important;
    height: 20px !important;
}

.bb-intro-video-content {
    background: #000 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    position: relative !important;
    overflow: hidden !important;
}

#bb-intro-video-player {
    display: block !important;
    max-width: 90vw !important;
    max-height: calc(90vh - 60px) !important;
    max-height: calc(90dvh - 60px) !important;
    width: auto !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Tablet and smaller desktop */
@media (max-width: 1024px) {
    .bb-intro-video-container {
        max-width: 92vw !important;
    }
    
    #bb-intro-video-player {
        max-width: 92vw !important;
        max-height: calc(85vh - 60px) !important;
        max-height: calc(85dvh - 60px) !important;
    }
    
    .bb-intro-video-title {
        font-size: 15px !important;
    }
}

/* Mobile devices */
@media (max-width: 768px) {
    .bb-intro-video-container {
        max-width: 95vw !important;
        border-radius: 6px !important;
    }
    
    .bb-intro-video-header {
        padding: 8px 45px 8px 12px !important;
        min-height: 44px !important;
    }
    
    .bb-intro-video-title {
        font-size: 14px !important;
    }
    
    #bb-intro-video-player {
        max-width: 95vw !important;
        max-height: calc(88vh - 55px) !important;
        max-height: calc(88dvh - 55px) !important;
    }
    
    .bb-intro-video-close {
        width: 32px !important;
        height: 32px !important;
        min-width: 32px !important;
        min-height: 32px !important;
        top: 5px !important;
        right: 5px !important;
    }
    
    .bb-intro-video-close svg {
        width: 18px !important;
        height: 18px !important;
    }
}

/* Small mobile devices */
@media (max-width: 480px) {
    .bb-intro-video-container {
        max-width: 98vw !important;
        border-radius: 4px !important;
    }
    
    .bb-intro-video-header {
        padding: 6px 40px 6px 10px !important;
        min-height: 40px !important;
    }
    
    .bb-intro-video-title {
        font-size: 13px !important;
    }
    
    #bb-intro-video-player {
        max-width: 98vw !important;
        max-height: calc(92vh - 50px) !important;
        max-height: calc(92dvh - 50px) !important;
    }
}

/* Landscape orientation on mobile */
@media (max-height: 500px) and (orientation: landscape) {
    .bb-intro-video-container {
        max-width: 95vw !important;
        max-height: 98vh !important;
        max-height: 98dvh !important;
    }
    
    .bb-intro-video-header {
        padding: 4px 40px 4px 8px !important;
        min-height: 36px !important;
    }
    
    .bb-intro-video-title {
        font-size: 12px !important;
    }
    
    #bb-intro-video-player {
        max-width: 95vw !important;
        max-height: calc(98vh - 46px) !important;
        max-height: calc(98dvh - 46px) !important;
    }
    
    .bb-intro-video-close {
        width: 28px !important;
        height: 28px !important;
        min-width: 28px !important;
        min-height: 28px !important;
        top: 3px !important;
        right: 3px !important;
    }
    
    .bb-intro-video-close svg {
        width: 16px !important;
        height: 16px !important;
    }
}
