/* MarkaSahne - Live Broadcast Page (TV Experience) */

.live-page {
    padding: 24px;
}

.live-page-header h1 {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 20px;
}

/* ===== MAIN GRID: Player + Chat ===== */
.live-main-grid {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 20px;
    margin-bottom: 40px;
}

/* ===== VIDEO PLAYER ===== */
.live-player-container {
    border-radius: 12px;
    overflow: hidden;
    background: #000;
    box-shadow: 0 4px 30px rgba(0,0,0,0.5);
}

.live-player-video {
    position: relative;
    width: 100%;
    aspect-ratio: 16/9;
    background: #000;
}

.live-player-video iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.live-player-video.empty {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #0a0a0a, #141414);
}

.live-empty-state {
    text-align: center;
    color: var(--text-muted);
}

.live-empty-state i {
    font-size: 40px;
    color: var(--gold);
    margin-bottom: 12px;
}

.live-empty-state h3 {
    font-size: 18px;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.live-player-overlay-top {
    position: absolute;
    top: 16px;
    left: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 5;
}

.live-red-badge {
    background: #e50914;
    color: #fff;
    font-size: 11px;
    font-weight: 800;
    padding: 5px 14px;
    border-radius: 4px;
    letter-spacing: 0.3px;
    animation: badgePulse 2s infinite;
}

@keyframes badgePulse {
    0%, 100% { box-shadow: 0 0 8px rgba(229,9,20,0.5); }
    50% { box-shadow: 0 0 16px rgba(229,9,20,0.8); }
}

.live-viewer-count {
    font-size: 12px;
    color: rgba(255,255,255,0.8);
    background: rgba(0,0,0,0.6);
    padding: 4px 10px;
    border-radius: 4px;
    backdrop-filter: blur(4px);
}

/* Player Controls */
.live-player-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    background: #111;
    border-top: 1px solid #222;
}

.live-controls-left,
.live-controls-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.ctrl-btn {
    background: none;
    border: none;
    color: #aaa;
    font-size: 14px;
    cursor: pointer;
    padding: 4px;
    transition: color 0.2s;
}

.ctrl-btn:hover {
    color: #fff;
}

.live-progress-bar {
    width: 200px;
    height: 4px;
    background: #333;
    border-radius: 2px;
    position: relative;
    cursor: pointer;
}

.live-progress-fill {
    width: 65%;
    height: 100%;
    background: #e50914;
    border-radius: 2px;
}

.live-progress-dot {
    position: absolute;
    top: -4px;
    left: 65%;
    width: 12px;
    height: 12px;
    background: #e50914;
    border-radius: 50%;
    transform: translateX(-50%);
    box-shadow: 0 0 6px rgba(229,9,20,0.5);
}

.live-label {
    font-size: 10px;
    font-weight: 800;
    color: #e50914;
    background: rgba(229,9,20,0.15);
    padding: 3px 8px;
    border-radius: 3px;
    letter-spacing: 0.5px;
}

/* ===== STREAM INFO ===== */
.live-stream-info {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 20px 0 0;
    gap: 20px;
}

.live-stream-info-left {
    display: flex;
    gap: 16px;
}

.live-stream-thumb {
    width: 100px;
    height: 70px;
    border-radius: 8px;
    background: linear-gradient(135deg, #1a1510, #0f0d0a);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    flex-shrink: 0;
    border: 1px solid #2a2a2a;
}

.live-thumb-text {
    font-size: 12px;
    font-weight: 800;
    color: var(--gold);
    text-align: center;
    line-height: 1.2;
}

.live-thumb-badge {
    position: absolute;
    top: -6px;
    right: -6px;
    background: #e50914;
    color: #fff;
    font-size: 8px;
    font-weight: 800;
    padding: 2px 6px;
    border-radius: 3px;
}

.live-stream-details h2 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 2px;
}

.live-stream-subtitle {
    font-size: 13px;
    color: var(--gold);
    margin-bottom: 6px;
}

.live-stream-desc {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 10px;
    max-width: 450px;
}

.live-stream-host {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: var(--text-secondary);
}

.live-host-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--gold);
    color: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 700;
}

.live-stream-info-right {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

.live-info-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: transparent;
    border: 1px solid #333;
    border-radius: 6px;
    color: var(--text-secondary);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: inherit;
}

.live-info-btn:hover {
    border-color: var(--gold);
    color: var(--gold);
}

/* ===== LIVE CHAT ===== */
.live-chat-col {
    min-width: 0;
}

.live-chat-box {
    background: #111;
    border: 1px solid #222;
    border-radius: 12px;
    height: 100%;
    display: flex;
    flex-direction: column;
    max-height: calc(56.25vw * 0.65 + 60px);
    min-height: 480px;
}

.live-chat-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 16px;
    border-bottom: 1px solid #222;
}

.live-chat-dot {
    width: 8px;
    height: 8px;
    background: #e50914;
    border-radius: 50%;
    animation: badgePulse 2s infinite;
}

.live-chat-header h3 {
    font-size: 14px;
    font-weight: 600;
}

.live-chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.live-chat-messages::-webkit-scrollbar {
    width: 3px;
}

.live-chat-messages::-webkit-scrollbar-thumb {
    background: #333;
    border-radius: 3px;
}

.chat-msg {
    display: flex;
    gap: 10px;
}

.chat-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    color: #fff;
    flex-shrink: 0;
}

.chat-content {
    min-width: 0;
}

.chat-name {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-primary);
    display: block;
    margin-bottom: 2px;
}

.chat-time {
    font-weight: 400;
    color: var(--text-muted);
    font-size: 10px;
    margin-left: 6px;
}

.chat-content p {
    font-size: 12px;
    color: var(--text-secondary);
    line-height: 1.4;
}

.live-chat-input {
    display: flex;
    gap: 8px;
    padding: 12px 16px;
    border-top: 1px solid #222;
}

.live-chat-input input {
    flex: 1;
    padding: 10px 14px;
    background: #0a0a0a;
    border: 1px solid #2a2a2a;
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 12px;
    font-family: inherit;
    outline: none;
    transition: border-color 0.3s;
}

.live-chat-input input:focus {
    border-color: var(--gold);
}

.chat-send-btn {
    width: 38px;
    height: 38px;
    border-radius: 8px;
    background: var(--gold);
    border: none;
    color: #000;
    font-size: 13px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.chat-send-btn:hover {
    background: #e8c96d;
    transform: scale(1.05);
}

/* ===== OTHER STREAMS ===== */
.live-others {
    margin-top: 8px;
}

.live-others-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.live-others-header h2 {
    font-size: 18px;
    font-weight: 700;
}

.live-others-link {
    font-size: 13px;
    color: var(--gold);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 4px;
}

.live-others-slider {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    scrollbar-width: none;
    position: relative;
    padding-bottom: 8px;
}

.live-others-slider::-webkit-scrollbar {
    display: none;
}

.live-other-card {
    flex: 0 0 calc(25% - 12px);
    min-width: 220px;
}

.live-other-thumb {
    width: 100%;
    aspect-ratio: 16/9;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    margin-bottom: 10px;
    background: #141414;
}

.live-other-img {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #1a1510, #0f0d0a);
}

.live-other-card:nth-child(1) .live-other-img { background: url('https://images.unsplash.com/photo-1478737270239-2f02b77fc618?w=400&q=70') center/cover; }
.live-other-card:nth-child(2) .live-other-img { background: url('https://images.unsplash.com/photo-1611974789855-9c2a0a7236a3?w=400&q=70') center/cover; }
.live-other-card:nth-child(3) .live-other-img { background: url('https://images.unsplash.com/photo-1556761175-5973dc0f32e7?w=400&q=70') center/cover; }
.live-other-card:nth-child(4) .live-other-img { background: url('https://images.unsplash.com/photo-1504384308090-c894fdcc538d?w=400&q=70') center/cover; }

.live-other-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #e50914;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 4px;
}

.live-other-card h4 {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 2px;
}

.live-other-card p {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.live-other-viewers {
    font-size: 11px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 4px;
}

.live-others-next {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-80%);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(0,0,0,0.8);
    border: 1px solid #333;
    color: #fff;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.live-others-next:hover {
    border-color: var(--gold);
    color: var(--gold);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
    .live-main-grid {
        grid-template-columns: 1fr;
    }
    .live-chat-box {
        max-height: 400px;
        min-height: 350px;
    }
}

@media (max-width: 768px) {
    .live-page {
        padding: 16px;
    }
    .live-stream-info {
        flex-direction: column;
    }
    .live-stream-info-left {
        flex-direction: column;
    }
    .live-other-card {
        flex: 0 0 200px;
        min-width: 200px;
    }
    .live-progress-bar {
        width: 100px;
    }
}
