/* player.css - Video player and related components */
/* Video.js custom skin */
.video-js {
    width: 100%;
    height: 100%;
    border-radius: 15px;
    overflow: hidden;
    background: #000 !important;
}

.vjs-poster {
    background-size: cover !important;
    border-radius: 15px;
}

.vjs-big-play-button {
    background: linear-gradient(135deg, #00e5ff, #00bcd4) !important;
    border: none !important;
    width: 80px !important;
    height: 80px !important;
    border-radius: 50% !important;
    line-height: 80px !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
    font-size: 40px !important;
    text-shadow: none !important;
    box-shadow: 0 10px 30px rgba(0, 229, 255, 0.5) !important;
    transition: all 0.3s !important;
}

.vjs-big-play-button:hover {
    background: linear-gradient(135deg, #00bcd4, #0097a7) !important;
    transform: translate(-50%, -50%) scale(1.1) !important;
    box-shadow: 0 15px 40px rgba(0, 229, 255, 0.7) !important;
}

.vjs-control-bar {
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent) !important;
    height: 60px !important;
    padding: 0 20px !important;
}

.vjs-button > .vjs-icon-placeholder:before {
    line-height: 60px !important;
    font-size: 24px !important;
}

.vjs-progress-control {
    height: 60px !important;
}

.vjs-play-progress {
    background: linear-gradient(90deg, #00e5ff, #ff4081) !important;
}

.vjs-slider {
    background: rgba(255, 255, 255, 0.2) !important;
}

.vjs-volume-level {
    background: #00e5ff !important;
}

/* Player Container */
.player-container {
    position: relative;
    background: #000;
    border-radius: 15px;
    overflow: hidden;
    margin-bottom: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.player-wrapper {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 Aspect Ratio */
}

#videoPlayer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
}

/* Channel Info Overlay */
.channel-info-overlay {
    position: absolute;
    top: 20px;
    left: 20px;
    right: 20px;
    background: linear-gradient(90deg, 
        rgba(0, 0, 0, 0.9) 0%,
        rgba(0, 0, 0, 0.7) 100%);
    padding: 20px;
    border-radius: 15px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 10;
    display: flex;
    justify-content: space-between;
    align-items: center;
    animation: slideDown 0.5s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.channel-info-header {
    display: flex;
    align-items: center;
    gap: 15px;
}

.channel-number {
    background: linear-gradient(135deg, #00e5ff, #00bcd4);
    color: #000;
    padding: 8px 16px;
    border-radius: 25px;
    font-weight: 800;
    font-size: 1.2em;
    min-width: 60px;
    text-align: center;
}

.channel-hd-badge {
    background: linear-gradient(135deg, #ff4081, #f50057);
    color: white;
    padding: 6px 12px;
    border-radius: 15px;
    font-size: 0.8em;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.channel-name {
    color: white;
    font-size: 1.8em;
    font-weight: 700;
    margin: 0;
    flex: 1;
}

.program-title {
    color: #ccc;
    font-size: 1.1em;
    margin: 5px 0 0 0;
}

.program-time {
    color: #888;
    font-size: 0.9em;
    margin-top: 5px;
}

/* Player Controls Overlay */
.player-controls-overlay {
    position: absolute;
    bottom: 20px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 15px;
    z-index: 10;
}

.control-btn {
    background: rgba(0, 0, 0, 0.7);
    border: 2px solid rgba(255, 255, 255, 0.2);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 1.2em;
}

.control-btn:hover {
    background: rgba(0, 229, 255, 0.8);
    border-color: #00e5ff;
    transform: scale(1.1);
    box-shadow: 0 5px 20px rgba(0, 229, 255, 0.4);
}

/* Player Loading */
.player-loading {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 20;
    border-radius: 15px;
}

.player-loading.active {
    display: flex;
}

.loading-spinner-small {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.1);
    border-top: 4px solid #00e5ff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
}

.player-loading p {
    color: white;
    font-size: 1.1em;
    text-shadow: 0 0 10px rgba(0, 229, 255, 0.7);
}

/* Player Status Bar */
.player-status-bar {
    background: rgba(0, 0, 0, 0.8);
    padding: 15px 25px;
    border-radius: 0 0 15px 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.status-item {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #ccc;
    font-size: 0.95em;
}

.status-item i {
    color: #00e5ff;
    font-size: 1.1em;
}

#streamQuality, #bufferStatus, #bitrate, #playbackTime {
    color: white;
    font-weight: 500;
    min-width: 80px;
}

/* Now Playing Details */
.now-playing-details {
    background: linear-gradient(145deg, #1a1a2e, #16213e);
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.now-playing-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.now-playing-header h3 {
    color: white;
    font-size: 1.5em;
    display: flex;
    align-items: center;
    gap: 10px;
}

.now-playing-header i {
    color: #00e5ff;
}

.btn-small {
    padding: 10px 20px;
    background: rgba(0, 229, 255, 0.1);
    color: #00e5ff;
    border: 1px solid #00e5ff;
    border-radius: 8px;
    font-size: 0.9em;
    cursor: pointer;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-small:hover {
    background: rgba(0, 229, 255, 0.2);
    transform: translateY(-2px);
}

.now-playing-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

@media (max-width: 992px) {
    .now-playing-content {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

.program-info {
    display: flex;
    gap: 25px;
    align-items: flex-start;
}

.program-image {
    width: 120px;
    height: 180px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.program-image i {
    color: white;
    opacity: 0.7;
}

.program-details {
    flex: 1;
}

.program-details h4 {
    color: white;
    font-size: 1.4em;
    margin-bottom: 10px;
    line-height: 1.3;
}

.program-description {
    color: #aaa;
    line-height: 1.6;
    margin-bottom: 20px;
    font-size: 0.95em;
}

.program-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.meta-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #888;
    font-size: 0.9em;
    background: rgba(255, 255, 255, 0.05);
    padding: 8px 15px;
    border-radius: 20px;
}

.meta-item i {
    color: #00e5ff;
    font-size: 0.9em;
}

.program-schedule h5 {
    color: white;
    font-size: 1.2em;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.up-next-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.up-next-item {
    background: rgba(255, 255, 255, 0.03);
    padding: 15px;
    border-radius: 10px;
    border-left: 3px solid #00e5ff;
    transition: all 0.3s;
}

.up-next-item:hover {
    background: rgba(0, 229, 255, 0.05);
    transform: translateX(5px);
}

.up-next-time {
    color: #00e5ff;
    font-weight: 600;
    font-size: 0.9em;
    margin-bottom: 5px;
}

.up-next-title {
    color: white;
    font-weight: 500;
    font-size: 1em;
}

/* Categories Container */
.categories-container {
    background: linear-gradient(145deg, #1a1a2e, #16213e);
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.categories-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.categories-header h3 {
    color: white;
    font-size: 1.4em;
    display: flex;
    align-items: center;
    gap: 10px;
}

.categories-header i {
    color: #00e5ff;
}

.category-stats {
    background: rgba(0, 229, 255, 0.1);
    color: #00e5ff;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9em;
}

.categories-scroll {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding-bottom: 10px;
    scrollbar-width: thin;
}

.categories-scroll::-webkit-scrollbar {
    height: 6px;
}

.categories-scroll::-webkit-scrollbar-thumb {
    background: #00e5ff;
    border-radius: 3px;
}

.category-btn {
    padding: 12px 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 25px;
    color: #ccc;
    font-size: 0.95em;
    cursor: pointer;
    transition: all 0.3s;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.category-btn:hover {
    background: rgba(0, 229, 255, 0.1);
    color: white;
    border-color: rgba(0, 229, 255, 0.3);
}

.category-btn.active {
    background: linear-gradient(135deg, #00e5ff, #00bcd4);
    color: black;
    border-color: #00e5ff;
    font-weight: 600;
}

/* Channels Container */
.channels-container {
    background: linear-gradient(145deg, #1a1a2e, #16213e);
    border-radius: 15px;
    padding: 25px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    height: 500px;
    display: flex;
    flex-direction: column;
}

.channels-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.channels-header h3 {
    color: white;
    font-size: 1.4em;
    display: flex;
    align-items: center;
    gap: 10px;
}

.channels-header i {
    color: #00e5ff;
}

.channel-controls {
    display: flex;
    gap: 10px;
}

.view-toggle, .sort-toggle, .refresh-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #ccc;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    font-size: 1.1em;
}

.view-toggle:hover, .sort-toggle:hover, .refresh-btn:hover {
    background: rgba(0, 229, 255, 0.1);
    color: white;
    border-color: rgba(0, 229, 255, 0.3);
}

/* Channel Grid/List Views */
.channels-view {
    flex: 1;
    overflow-y: auto;
    position: relative;
}

.channel-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 15px;
    padding: 5px;
}

.channel-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 5px;
}

.channel-item {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 15px;
    cursor: pointer;
    transition: all 0.3s;
    border: 1px solid transparent;
    position: relative;
}

.channel-item:hover {
    background: rgba(0, 229, 255, 0.1);
    border-color: rgba(0, 229, 255, 0.3);
    transform: translateY(-3px);
}

.channel-item.selected {
    background: rgba(0, 229, 255, 0.15);
    border-color: #00e5ff;
    box-shadow: 0 5px 20px rgba(0, 229, 255, 0.2);
}

.channel-logo-container {
    width: 60px;
    height: 60px;
    border-radius: 10px;
    overflow: hidden;
    background: linear-gradient(135deg, #667eea, #764ba2);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 10px;
}

.channel-logo {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.channel-logo-fallback {
    color: white;
    font-size: 1.5em;
    font-weight: 700;
}

.channel-info {
    flex: 1;
}

.channel-number {
    display: inline-block;
    background: rgba(0, 229, 255, 0.2);
    color: #00e5ff;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.85em;
    font-weight: 600;
    margin-bottom: 8px;
}

.channel-name {
    color: white;
    font-weight: 600;
    font-size: 1em;
    margin-bottom: 5px;
    line-height: 1.3;
}

.channel-group {
    color: #888;
    font-size: 0.85em;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.fav-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: gold;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1em;
    transition: all 0.3s;
}

.fav-btn:hover {
    background: rgba(255, 215, 0, 0.2);
    transform: scale(1.1);
}

/* No Channels Message */
.no-channels {
    text-align: center;
    padding: 60px 20px;
    color: #888;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.no-channels i {
    font-size: 4em;
    color: #444;
    opacity: 0.5;
}

.no-channels h4 {
    color: #aaa;
    font-size: 1.5em;
    margin: 0;
}

.no-channels p {
    color: #666;
    font-size: 1.1em;
    margin: 0;
}

/* Channel Navigation */
.channel-navigation {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.nav-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #ccc;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2em;
    transition: all 0.3s;
}

.nav-btn:hover {
    background: rgba(0, 229, 255, 0.1);
    color: white;
    border-color: rgba(0, 229, 255, 0.3);
    transform: translateY(-3px);
}

.nav-info {
    color: #aaa;
    font-size: 0.9em;
    min-width: 60px;
    text-align: center;
}

/* DTH Header */
.dth-header {
    background: linear-gradient(90deg, #1a237e, #311b92);
    padding: 20px 30px;
    border-radius: 15px 15px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    border-bottom: 3px solid #00e5ff;
    position: relative;
    z-index: 2;
}

.header-left, .header-center, .header-right {
    display: flex;
    align-items: center;
    gap: 25px;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo-icon {
    font-size: 2em;
    color: #00e5ff;
    background: rgba(0, 0, 0, 0.3);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-text {
    font-size: 1.8em;
    font-weight: 800;
    color: white;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.logo-badge {
    background: #ff4081;
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8em;
    font-weight: 700;
    letter-spacing: 1px;
}

.current-time {
    background: rgba(0, 0, 0, 0.3);
    padding: 10px 20px;
    border-radius: 25px;
    color: white;
    font-size: 1.1em;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.current-time i {
    color: #00e5ff;
}

.search-container {
    position: relative;
    width: 300px;
}

.search-input {
    width: 100%;
    padding: 15px 50px 15px 20px;
    background: rgba(0, 0, 0, 0.3);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 30px;
    color: white;
    font-size: 1em;
    transition: all 0.3s;
}

.search-input:focus {
    background: rgba(0, 0, 0, 0.5);
    border-color: #00e5ff;
    outline: none;
    box-shadow: 0 0 20px rgba(0, 229, 255, 0.3);
}

.search-icon {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: #aaa;
    font-size: 1.2em;
}

.search-clear {
    position: absolute;
    right: 50px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #aaa;
    cursor: pointer;
    font-size: 1.2em;
    transition: color 0.3s;
}

.search-clear:hover {
    color: #ff4444;
}

.signal-indicator {
    background: rgba(0, 0, 0, 0.3);
    padding: 10px 20px;
    border-radius: 25px;
    color: white;
    font-size: 1em;
    display: flex;
    align-items: center;
    gap: 10px;
}

.signal-indicator i {
    color: #4CAF50;
}

.header-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.3);
    border: 2px solid rgba(255, 255, 255, 0.1);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2em;
    transition: all 0.3s;
}

.header-btn:hover {
    background: rgba(0, 229, 255, 0.2);
    border-color: #00e5ff;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 229, 255, 0.3);
}

.volume-control {
    display: flex;
    align-items: center;
    gap: 15px;
    background: rgba(0, 0, 0, 0.3);
    padding: 10px 20px;
    border-radius: 30px;
}

.volume-icon {
    color: #00e5ff;
    font-size: 1.2em;
}

.volume-slider {
    width: 120px;
    height: 6px;
    -webkit-appearance: none;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    outline: none;
}

.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #00e5ff;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(0, 229, 255, 0.5);
}

/* DTH Main Layout */
.dth-main {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 25px;
    margin-bottom: 25px;
}

@media (max-width: 1200px) {
    .dth-main {
        grid-template-columns: 1fr;
    }
    
    .dth-header {
        flex-direction: column;
        gap: 20px;
        padding: 20px;
    }
    
    .header-left, .header-center, .header-right {
        width: 100%;
        justify-content: center;
    }
    
    .search-container {
        width: 100%;
        max-width: 400px;
    }
}

/* DTH Footer */
.dth-footer {
    background: linear-gradient(90deg, #1a237e, #311b92);
    padding: 20px 30px;
    border-radius: 0 0 15px 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 3px solid #00e5ff;
    position: relative;
    z-index: 2;
}

.footer-left, .footer-center, .footer-right {
    flex: 1;
}

.footer-info {
    display: flex;
    gap: 25px;
    flex-wrap: wrap;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 10px;
    color: white;
    font-size: 0.95em;
    background: rgba(0, 0, 0, 0.3);
    padding: 8px 16px;
    border-radius: 20px;
}

.info-item i {
    color: #00e5ff;
}

.epg-timeline {
    text-align: center;
}

.timeline-header {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-bottom: 10px;
}

.timeline-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.timeline-btn:hover {
    background: rgba(0, 229, 255, 0.2);
    border-color: #00e5ff;
}

.timeline-date {
    color: white;
    font-weight: 600;
    font-size: 1.1em;
    min-width: 150px;
}

.timeline-slots {
    display: flex;
    justify-content: center;
    gap: 5px;
    overflow-x: auto;
    padding: 10px;
}

.timeline-slot {
    width: 60px;
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    transition: all 0.3s;
}

.timeline-slot.active {
    background: #00e5ff;
}

.footer-controls {
    display: flex;
    justify-content: flex-end;
    gap: 15px;
}

.footer-btn {
    padding: 12px 25px;
    background: rgba(0, 0, 0, 0.3);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 25px;
    color: white;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.footer-btn:hover {
    background: rgba(0, 229, 255, 0.2);
    border-color: #00e5ff;
    transform: translateY(-3px);
}

/* OSD Overlay */
.osd-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    pointer-events: none;
}

.osd-content {
    background: rgba(0, 0, 0, 0.9);
    padding: 30px 50px;
    border-radius: 20px;
    border: 3px solid #00e5ff;
    color: white;
    font-size: 2em;
    font-weight: 700;
    text-align: center;
    max-width: 80%;
    animation: fadeInOut 3s ease;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8);
}

@keyframes fadeInOut {
    0%, 100% {
        opacity: 0;
        transform: scale(0.8);
    }
    20%, 80% {
        opacity: 1;
        transform: scale(1);
    }
}
