/**
 * BBTM Vagon Streaming Styles
 */

.bbtm-vagon-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: #000;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.vagon-loading {
    text-align: center;
    color: #fff;
}

.loading-spinner {
    width: 60px;
    height: 60px;
    border: 6px solid rgba(255, 255, 255, 0.2);
    border-top-color: #00ff88;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 30px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.vagon-player {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

#vagon-stream-iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.vagon-controls {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 100;
    display: flex;
    align-items: center;
    gap: 15px;
    background: rgba(0, 0, 0, 0.8);
    padding: 12px 20px;
    border-radius: 8px;
    backdrop-filter: blur(10px);
}

.session-timer {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #fff;
}

.timer-label {
    font-size: 0.9rem;
    opacity: 0.8;
}

.timer-display {
    font-size: 1.3rem;
    font-weight: 900;
    font-family: 'Courier New', monospace;
    color: #00ff88;
}

.btn-end-session {
    padding: 8px 18px;
    background: rgba(255, 0, 0, 0.8);
    color: #fff;
    border: none;
    border-radius: 6px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-end-session:hover {
    background: rgba(255, 0, 0, 1);
    transform: scale(1.05);
}

.vagon-warning {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 101;
    max-width: 500px;
    width: 90%;
}

.warning-content {
    background: linear-gradient(135deg, rgba(255, 152, 0, 0.95) 0%, rgba(255, 87, 34, 0.95) 100%);
    padding: 25px;
    border-radius: 12px;
    text-align: center;
    color: #fff;
    box-shadow: 0 8px 32px rgba(255, 152, 0, 0.4);
    animation: pulse 2s ease-in-out infinite;
}

.warning-content h3 {
    margin: 0 0 10px 0;
    font-size: 1.4rem;
}

.warning-content p {
    margin: 8px 0;
    font-size: 1.05rem;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 8px 32px rgba(255, 152, 0, 0.4);
    }
    50% {
        transform: scale(1.02);
        box-shadow: 0 12px 48px rgba(255, 152, 0, 0.6);
    }
}

.vagon-idle-warning {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 102;
    max-width: 450px;
    width: 90%;
}

.idle-content {
    background: rgba(0, 0, 0, 0.95);
    padding: 35px;
    border-radius: 16px;
    text-align: center;
    color: #fff;
    border: 3px solid #ff9800;
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.8);
}

.idle-content h3 {
    margin: 0 0 15px 0;
    font-size: 1.6rem;
    color: #ff9800;
}

.idle-content p {
    margin: 10px 0;
    font-size: 1.1rem;
}

#idle-countdown {
    color: #ff0000;
    font-weight: 900;
    font-size: 1.4rem;
}

.btn-continue {
    margin-top: 20px;
    padding: 14px 35px;
    background: linear-gradient(135deg, #00ff88 0%, #00cc6a 100%);
    color: #000;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 900;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 255, 136, 0.3);
}

.btn-continue:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 255, 136, 0.5);
}

.vagon-session-ended {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 600px;
    width: 90%;
    z-index: 100;
}

.ended-content {
    background: linear-gradient(135deg, rgba(0, 150, 255, 0.15) 0%, rgba(0, 100, 200, 0.15) 100%);
    padding: 50px;
    border-radius: 20px;
    text-align: center;
    color: #fff;
    border: 2px solid rgba(0, 150, 255, 0.4);
}

.ended-content h2 {
    margin: 0 0 15px 0;
    font-size: 2.2rem;
    color: #00ff88;
}

.ended-content p {
    margin: 12px 0;
    font-size: 1.15rem;
    opacity: 0.9;
}

.btn-purchase-again {
    display: inline-block;
    margin-top: 25px;
    padding: 16px 40px;
    background: linear-gradient(135deg, #0096ff 0%, #0070cc 100%);
    color: #fff;
    text-decoration: none;
    border-radius: 10px;
    font-size: 1.2rem;
    font-weight: 900;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 150, 255, 0.4);
}

.btn-purchase-again:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 150, 255, 0.6);
}

/* Mobile Responsive */
@media only screen and (max-width: 768px) {
    .vagon-controls {
        top: 10px;
        right: 10px;
        padding: 10px 15px;
        font-size: 0.85rem;
    }
    
    .timer-display {
        font-size: 1.1rem;
    }
    
    .btn-end-session {
        padding: 6px 12px;
        font-size: 0.85rem;
    }
    
    .warning-content,
    .idle-content {
        padding: 20px;
    }
    
    .warning-content h3,
    .idle-content h3 {
        font-size: 1.2rem;
    }
    
    .ended-content {
        padding: 30px 20px;
    }
    
    .ended-content h2 {
        font-size: 1.6rem;
    }
}

/* Fullscreen styles */
.vagon-player:-webkit-full-screen {
    width: 100%;
    height: 100%;
}

.vagon-player:-moz-full-screen {
    width: 100%;
    height: 100%;
}

.vagon-player:-ms-fullscreen {
    width: 100%;
    height: 100%;
}

.vagon-player:fullscreen {
    width: 100%;
    height: 100%;
}

/* Accessibility */
.btn-end-session:focus,
.btn-continue:focus,
.btn-purchase-again:focus {
    outline: 3px solid #00ff88;
    outline-offset: 2px;
}

/* Loading animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.vagon-loading,
.vagon-player,
.vagon-warning,
.vagon-idle-warning,
.vagon-session-ended {
    animation: fadeIn 0.5s ease-out;
}
