:root {
    --bg-dark: #000000;
    --primary: #1d4ed8;
    --primary-glow: rgba(29, 78, 216, 0.4);
    --accent-red: #ef4444;
    --text-main: #ffffff;
    --text-muted: rgba(255, 255, 255, 0.5);
    /* V6.0: Premium Navy Baseline */
    --glass-bg: rgba(10, 31, 64, 0.6);
    --glass-border: rgba(255, 255, 255, 0.12);
}

.tv-player-wp-container {
    position: fixed;
    inset: 0;
    z-index: 999999;
    background-color: #000;
    font-family: 'Inter', -apple-system, system-ui, sans-serif;
    color: var(--text-main);
    overflow: hidden;
}

.tv-player-wp-container .hidden {
    display: none !important;
}

.tv-player-wp-container #player-container {
    position: relative;
    width: 100%;
    height: 100%;
}

.tv-player-wp-container video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* --- NOISE TEXTURE --- */
.tv-player-wp-container .epg-canvas {
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.02'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.3;
    pointer-events: none;
    z-index: 1;
}

/* --- LOADING SCREEN --- */
.tv-player-wp-container .loading-overlay {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, #0a1b40 0%, #000000 100%);
    z-index: 3000;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: opacity 1s ease;
}

.tv-player-wp-container .loading-overlay.fade-out {
    opacity: 0;
    pointer-events: none;
}

.tv-player-wp-container .loading-logo {
    height: 180px;
    margin-bottom: 15px;
    animation: wpPulse 2.5s infinite ease-in-out;
    filter: drop-shadow(0 0 30px rgba(37, 99, 235, 0.45));
}

.tv-player-wp-container .loading-content p {
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 2px;
    color: var(--text-muted);
}

/* --- PILL (No Ar) --- */
.tv-player-wp-container .pill-container {
    position: absolute;
    top: 30px;
    right: 40px;
    z-index: 100;
}

.tv-player-wp-container .pill {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(10, 31, 64, 0.5);
    backdrop-filter: blur(15px);
    border: 1.2px solid var(--glass-border);
    border-radius: 30px;
    padding: 8px 18px;
}

.tv-player-wp-container .pill .dot {
    width: 6px;
    height: 6px;
    background: var(--accent-red);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--accent-red);
    animation: wpPulse 1.5s infinite;
}

/* --- MINI-GUIDE --- */
.tv-player-wp-container .mini-guide-bar {
    position: absolute;
    bottom: 35px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 1150px;
    background: var(--glass-bg);
    backdrop-filter: blur(60px);
    -webkit-backdrop-filter: blur(60px);
    border: 1.8px solid var(--glass-border);
    border-radius: 30px;
    z-index: 500;
    animation: wpSlideUp 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.9);
}

.tv-player-wp-container .mini-guide-inner {
    display: flex;
    align-items: center;
    height: 110px;
}

.tv-player-wp-container .mini-logo {
    height: 100%;
    padding: 0 15px;
    display: flex;
    align-items: center;
    border-right: 1px solid rgba(255, 255, 255, 0.1);
}

.tv-player-wp-container .mini-logo img {
    height: 95px;
    width: auto;
}

.tv-player-wp-container .mini-info {
    flex: 1;
    padding: 0 35px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 2px;
}

.tv-player-wp-container .info-block.current .name {
    font-size: 28px;
    font-weight: 800;
}

.tv-player-wp-container .mini-right {
    display: flex;
    align-items: center;
    gap: 45px;
    padding-right: 30px;
}

.tv-player-wp-container .btn-ver-grade {
    background: rgba(29, 78, 216, 0.6);
    backdrop-filter: blur(15px);
    border: 1.5px solid rgba(255, 255, 255, 0.3);
    color: white;
    padding: 12px 32px;
    border-radius: 50px;
    font-weight: 800;
    cursor: pointer;
}

/* --- FULL EPG (Unified List V6.0) --- */
.tv-player-wp-container .epg-container {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, rgba(10, 20, 50, 0.6) 0%, rgba(0, 0, 0, 0.98) 100%);
    backdrop-filter: blur(60px);
    -webkit-backdrop-filter: blur(60px);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    padding: 5vh 5vw;
    animation: wpFadeIn 0.5s ease;
}

.tv-player-wp-container .epg-header {
    margin-bottom: 25px;
}

.tv-player-wp-container .header-main {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.tv-player-wp-container .epg-header h1 {
    font-size: 38px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: -1.5px;
    margin: 0;
}

.tv-player-wp-container .current-date {
    font-size: 22px;
    color: var(--text-muted);
}

.tv-player-wp-container .epg-tabs {
    display: flex;
    gap: 15px;
    margin-top: 5px;
}

.tv-player-wp-container .tab {
    padding: 12px 28px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 100px;
    /* V6.0: Elegant Pills */
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.tv-player-wp-container .tab.active {
    background: var(--primary);
    color: #fff;
    border-color: #3b82f6;
    box-shadow: 0 0 25px var(--primary-glow);
    transform: scale(1.05);
}

.tv-player-wp-container .tab.focused {
    background: rgba(255, 255, 255, 0.2);
    border-color: #fff;
    transform: scale(1.1);
}

.tv-player-wp-container .epg-body {
    flex: 1;
    min-height: 0;
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(30px);
    border-radius: 20px;
    border: 1px solid var(--glass-border);
    margin-bottom: 25px;
    overflow: hidden;
}

.tv-player-wp-container .epg-grid-wrapper {
    height: 100%;
    overflow-y: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.tv-player-wp-container .epg-grid-wrapper::-webkit-scrollbar {
    display: none;
}

.tv-player-wp-container .epg-table {
    width: 100%;
    border-collapse: collapse;
}

.tv-player-wp-container .epg-header-row th {
    padding: 20px 35px;
    text-align: left;
    font-size: 15px;
    font-weight: 900;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 2px;
    background: rgba(0, 0, 0, 0.4);
    border-bottom: 1.5px solid rgba(255, 255, 255, 0.1);
}

.tv-player-wp-container .epg-header-row th:first-child {
    border-radius: 20px 0 0 0;
}

.tv-player-wp-container .epg-header-row th:last-child {
    border-radius: 0 20px 0 0;
}

.tv-player-wp-container .program-row td {
    padding: 24px 35px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.tv-player-wp-container .program-row td:first-child {
    width: 180px;
    color: #3b82f6;
    font-size: 26px;
    font-weight: 900;
}

.tv-player-wp-container .program-row td:last-child {
    font-size: 26px;
    font-weight: 400;
}

.tv-player-wp-container .program-row.focused td {
    background: var(--primary);
    color: #fff;
}

.tv-player-wp-container .epg-footer {
    padding: 10px 0;
    display: block !important;
    /* Ensure visibility */
}

.tv-player-wp-container .hint-bar {
    display: flex;
    justify-content: center;
    gap: 45px;
}

.tv-player-wp-container .hint-item {
    font-size: 16px;
    color: var(--text-muted);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 12px;
}

.tv-player-wp-container .key {
    background: rgba(255, 255, 255, 0.15);
    padding: 4px 12px;
    border-radius: 10px;
    color: #fff;
    font-weight: 900;
    font-size: 14px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

@keyframes wpPulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.05);
        opacity: 0.8;
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes wpSlideUp {
    from {
        transform: translate(-50%, 60px);
        opacity: 0;
    }

    to {
        transform: translate(-50%, 0);
        opacity: 1;
    }
}

@keyframes wpFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}