﻿/* Platform Preview Modal Styles */
.platform-preview-modal {
    background: linear-gradient(145deg, rgba(10, 10, 10, 0.98) 0%, rgba(20, 20, 20, 0.98) 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    overflow: hidden;
    width: 100%;
    max-height: 90vh;
    backdrop-filter: blur(30px);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.8), 0 0 100px rgba(138, 43, 226, 0.15);
    position: relative;
    animation: modalSlideIn 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-header-v25 {
    position: relative;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, rgba(138, 43, 226, 0.05) 0%, transparent 100%);
    pointer-events: none;
}

.platform-type-badge {
    background: linear-gradient(135deg, #8A2BE2 0%, #9932CC 100%);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 4px 15px rgba(138, 43, 226, 0.3);
    position: relative;
    z-index: 2;
}

.modal-close-v25 {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    z-index: 2;
}

    .modal-close-v25:hover {
        background: rgba(239, 68, 68, 0.2);
        border-color: rgba(239, 68, 68, 0.4);
        color: #ef4444;
        transform: scale(1.1);
    }

.modal-content-v25 {
    padding: 0;
    max-height: calc(90vh - 80px);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

/* Media Section */
.platform-media-section {
    flex-shrink: 0;
}

.media-container {
    position: relative;
}

.media-display {
    height: 300px;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(138, 43, 226, 0.1) 0%, rgba(0, 0, 0, 0.5) 100%);
}

.platform-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.5s ease;
}

.contentContainer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

    .contentContainer.active {
        opacity: 1;
    }

.qr-container {
    flex-direction: column;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 16px;
    padding: 2rem;
    margin: 2rem;
}

.qr-code {
    width: 200px;
    height: 200px;
    border-radius: 12px;
    margin-bottom: 1rem;
}

.qr-label {
    color: #333;
    font-weight: 600;
    text-align: center;
    margin: 0;
}

.video-container iframe,
.video-container video {
    width: 100%;
    height: 100%;
    border: none;
}

.media-controls {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    padding: 1rem;
    display: flex;
    gap: 0.5rem;
    justify-content: center;
}

.media-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    color: #fff;
    padding: 8px 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    backdrop-filter: blur(10px);
}

    .media-btn:hover,
    .media-btn.active {
        background: linear-gradient(135deg, #8A2BE2 0%, #9932CC 100%);
        border-color: #8A2BE2;
        transform: translateY(-2px);
        box-shadow: 0 4px 15px rgba(138, 43, 226, 0.4);
    }

    .media-btn.admin-only {
        border-color: rgba(255, 193, 7, 0.3);
    }

        .media-btn.admin-only:hover {
            background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%);
            border-color: #ffc107;
        }

/* Platform Info Section */
.platform-info-section {
    padding: 2rem;
    flex: 1;
}

.platform-header {
    margin-bottom: 1.5rem;
}

.platform-name {
    font-size: 1.8rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    line-height: 1.2;
}

.verified-badge {
    color: #10b981;
    font-size: 1.2rem;
    filter: drop-shadow(0 0 4px rgba(16, 185, 129, 0.3));
}

.platform-location {
    color: #b0b0b0;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
}

.platform-description {
    margin-bottom: 2rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.02);
    border-left: 3px solid #8A2BE2;
    border-radius: 0 8px 8px 0;
}

    .platform-description p {
        color: #e0e0e0;
        line-height: 1.6;
        margin: 0;
    }

/* Action Buttons */
.platform-actions {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.action-btn {
    background: linear-gradient(135deg, rgba(138, 43, 226, 0.1) 0%, rgba(153, 50, 204, 0.05) 100%);
    border: 1px solid rgba(138, 43, 226, 0.3);
    border-radius: 25px;
    color: #fff;
    padding: 12px 20px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    text-decoration: none;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

    .action-btn:hover {
        background: linear-gradient(135deg, #8A2BE2 0%, #9932CC 100%);
        color: white;
        transform: translateY(-2px);
        box-shadow: 0 8px 25px rgba(138, 43, 226, 0.4);
        text-decoration: none;
    }

.btn-glow {
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.action-btn:hover .btn-glow {
    left: 100%;
}

.btn-subscribe.subscribed {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    border-color: #10b981;
}

.btn-rsvp {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1) 0%, rgba(5, 150, 105, 0.05) 100%);
    border-color: rgba(16, 185, 129, 0.3);
}

    .btn-rsvp:hover {
        background: linear-gradient(135deg, #10b981 0%, #059669 100%);
        border-color: #10b981;
    }

/* Platform Stats */
.platform-stats {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.stat-item {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    color: #b0b0b0;
}

    .stat-item i {
        color: #8A2BE2;
    }

/* Loading Overlay */
.loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    backdrop-filter: blur(4px);
}

.loading-spinner {
    color: #8A2BE2;
    font-size: 2rem;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .platform-preview-modal {
        margin: 1rem;
        max-height: calc(100vh - 2rem);
    }

    .modal-content-v25 {
        max-height: calc(100vh - 140px);
    }

    .media-display {
        height: 200px;
    }

    .platform-info-section {
        padding: 1.5rem;
    }

    .platform-name {
        font-size: 1.5rem;
    }

    .platform-actions {
        flex-direction: column;
    }

    .action-btn {
        justify-content: center;
    }

    .media-controls {
        flex-wrap: wrap;
    }

    .qr-container {
        padding: 1rem;
        margin: 1rem;
    }

    .qr-code {
        width: 150px;
        height: 150px;
    }
}
/* Platform Preview - Video Visibility Fix */

/* Hide video button by default - JS will show it when video loads */
#btnToggleVideo {
    display: none !important;
}

    #btnToggleVideo[style*="display: "] {
        display: block !important;
    }

/* Ensure contentContainer uses CSS transitions, not inline styles */
.contentContainer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex !important; /* Override any inline display:none */
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

    .contentContainer.active {
        opacity: 1;
        pointer-events: auto;
    }

/* Ensure video container is ready */
.video-container {
    position: relative;
    width: 100%;
    height: 100%;
}

    .video-container iframe,
    .video-container video,
    .video-container #platformPromoPlayer {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        border: none;
    }

#platformPromoPlayer {
    background: #000;
}

