/* NewsPortal Studio - Frontend Styles */

/* Reset and Base */
.nps-studio-body {
    margin: 0;
    padding: 0;
    background: #000;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    overflow: hidden;
    height: 100vh;
}

#nps-main-container {
    display: flex;
    flex-direction: column;
    height: 100vh;
    background: #0a0a0a;
    color: #fff;
}

/* Header */
.nps-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
    background: #cc0000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.5);
    z-index: 1000;
}

.nps-header-left {
    display: flex;
    align-items: center;
    gap: 15px;
}

.nps-logo {
    height: 50px;
    width: auto;
    max-width: 200px;
}

.nps-show-info h1 {
    margin: 0;
    font-size: 22px;
    font-weight: bold;
    color: white;
}

.nps-show-info p {
    margin: 5px 0 0;
    font-size: 14px;
    opacity: 0.9;
    color: white;
}

.nps-header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.nps-live-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(0,0,0,0.3);
    padding: 5px 15px;
    border-radius: 20px;
    font-weight: bold;
    font-size: 14px;
}

.nps-live-dot {
    width: 10px;
    height: 10px;
    background: #ff3333;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.5; }
    100% { opacity: 1; }
}

.nps-time-display {
    font-size: 16px;
    font-weight: bold;
}

.nps-viewer-count {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 14px;
}

/* Content Area */
.nps-content-area {
    display: flex;
    flex: 1;
    overflow: hidden;
}

.nps-video-section {
    flex: 3;
    display: flex;
    flex-direction: column;
    padding: 20px;
}

.nps-video-grid {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 10px;
    padding: 10px;
    overflow-y: auto;
}

/* Video Player */
.nps-video-player {
    position: relative;
    background: #000;
    border-radius: 8px;
    overflow: hidden;
    border: 2px solid #333;
    height: 300px;
    transition: all 0.3s ease;
}

.nps-video-player:hover {
    border-color: #cc0000;
    transform: scale(1.02);
}

.video-player-element {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.nps-name-plate {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.8));
    padding: 10px;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nps-guest-name {
    font-size: 16px;
    font-weight: bold;
}

.nps-you-badge {
    background: #cc0000;
    color: white;
    padding: 2px 8px;
    border-radius: 3px;
    font-size: 12px;
    font-weight: bold;
}

.nps-audio-indicator {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0,0,0,0.7);
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nps-audio-indicator.muted {
    background: #cc0000;
}

.nps-audio-indicator .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
}

/* Controls */
.nps-controls-bar {
    display: flex;
    gap: 10px;
    padding: 15px;
    background: rgba(0,0,0,0.8);
    border-radius: 10px;
    margin-top: 10px;
    flex-wrap: wrap;
    justify-content: center;
}

.nps-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border: none;
    border-radius: 5px;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
}

.nps-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

.nps-btn-primary {
    background: #cc0000;
    color: white;
}

.nps-btn-primary:hover {
    background: #ff3333;
}

.nps-btn-danger {
    background: #dc3545;
    color: white;
}

.nps-btn-success {
    background: #28a745;
    color: white;
}

.nps-btn-warning {
    background: #ffc107;
    color: #000;
}

.nps-btn-secondary {
    background: #6c757d;
    color: white;
}

/* Sidebar */
.nps-sidebar {
    flex: 1;
    min-width: 300px;
    background: rgba(20,20,20,0.95);
    padding: 20px;
    overflow-y: auto;
    border-left: 2px solid #333;
}

.nps-ads-section {
    margin-bottom: 20px;
}

.nps-ads-section h3 {
    color: #cc0000;
    border-bottom: 2px solid #cc0000;
    padding-bottom: 5px;
    margin-bottom: 15px;
}

.nps-ad-item {
    background: rgba(255,255,255,0.1);
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 10px;
    transition: transform 0.3s ease;
}

.nps-ad-item:hover {
    transform: scale(1.02);
    background: rgba(255,255,255,0.15);
}

.nps-ad-item img {
    width: 100%;
    height: auto;
    border-radius: 5px;
}

.nps-info-section h3 {
    color: #00ccff;
    border-bottom: 2px solid #00ccff;
    padding-bottom: 5px;
    margin-bottom: 15px;
}

.nps-participant-list {
    margin-bottom: 20px;
}

.nps-participant-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    background: rgba(255,255,255,0.05);
    margin-bottom: 8px;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.nps-participant-item.joined {
    background: rgba(0,255,0,0.1);
    border-left: 4px solid #00cc00;
}

.nps-participant-status {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #666;
}

.nps-participant-item.joined .nps-participant-status {
    background: #00cc00;
    animation: pulse 2s infinite;
}

.nps-participant-name {
    font-weight: bold;
    flex: 1;
}

.nps-participant-role {
    font-size: 12px;
    opacity: 0.8;
    font-style: italic;
}

/* Social Share */
.nps-social-share {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #333;
}

.nps-share-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.nps-share-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px;
    border: none;
    border-radius: 5px;
    color: white;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    justify-content: center;
}

.nps-share-btn.facebook {
    background: #3b5998;
}

.nps-share-btn.twitter {
    background: #1da1f2;
}

.nps-share-btn.whatsapp {
    background: #25d366;
}

.nps-share-btn:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

/* Ticker */
.nps-ticker-container {
    background: #000;
    border-top: 2px solid #cc0000;
    border-bottom: 2px solid #cc0000;
    padding: 8px 0;
    overflow: hidden;
    white-space: nowrap;
}

.nps-ticker-wrapper {
    display: flex;
    align-items: center;
    animation: ticker-scroll 30s linear infinite;
}

@keyframes ticker-scroll {
    0% { transform: translateX(100%); }
    100% { transform: translateX(-100%); }
}

.nps-ticker-label {
    background: #cc0000;
    color: white;
    padding: 5px 15px;
    font-weight: bold;
    font-size: 14px;
    margin-right: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.nps-ticker-content {
    font-size: 16px;
    font-weight: bold;
    color: #ffcc00;
    display: inline-block;
    padding-right: 50px;
}

/* Bottom Ads */
.nps-bottom-ads {
    padding: 10px;
    background: rgba(0,0,0,0.9);
    text-align: center;
    border-top: 1px solid #333;
}

/* Error States */
.nps-error {
    background: #f8d7da;
    color: #721c24;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    margin: 20px;
}

.nps-error h3 {
    margin-top: 0;
}

/* Loading Animation */
.nps-loading {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100%;
    background: #000;
    color: white;
}

.nps-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #333;
    border-top: 4px solid #cc0000;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 10px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Popup Ads */
.nps-popup-ad {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    padding: 20px;
    border-radius: 10px;
    z-index: 10000;
    box-shadow: 0 0 30px rgba(0,0,0,0.5);
    animation: popup-in 0.3s ease;
}

@keyframes popup-in {
    from { opacity: 0; transform: translate(-50%, -60%); }
    to { opacity: 1; transform: translate(-50%, -50%); }
}

.nps-popup-close {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #cc0000;
    color: white;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    font-weight: bold;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .nps-content-area {
        flex-direction: column;
    }
    
    .nps-sidebar {
        min-width: 100%;
        max-height: 300px;
    }
    
    .nps-video-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }
}

@media (max-width: 768px) {
    .nps-header {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
    
    .nps-header-left, .nps-header-right {
        width: 100%;
        justify-content: center;
    }
    
    .nps-video-grid {
        grid-template-columns: 1fr;
    }
    
    .nps-controls-bar {
        justify-content: center;
    }
    
    .nps-btn {
        padding: 10px 15px;
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .nps-show-info h1 {
        font-size: 18px;
    }
    
    .nps-ticker-content {
        font-size: 14px;
    }
    
    .nps-controls-bar {
        padding: 10px;
    }
    
    .nps-btn {
        padding: 8px 12px;
    }
}