/* Estilos generales */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #121212;
    color: #fff;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Encabezado */
header {
    background-color: #1e1e1e;
    padding: 15px 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header h1 {
    color: #e50914;
    font-size: 28px;
}

header h1 i {
    margin-right: 10px;
}

.search-container {
    display: flex;
}

#searchInput {
    padding: 8px 15px;
    border: none;
    background-color: #333;
    color: #fff;
    border-radius: 4px 0 0 4px;
    width: 250px;
}

#searchButton {
    background-color: #e50914;
    color: white;
    border: none;
    padding: 8px 15px;
    cursor: pointer;
    border-radius: 0 4px 4px 0;
}

/* Navegación */
nav {
    background-color: #1e1e1e;
    padding: 10px 0;
    border-bottom: 1px solid #333;
}

#categoryList {
    display: flex;
    list-style: none;
    overflow-x: auto;
    padding-bottom: 5px;
}

#categoryList::-webkit-scrollbar {
    height: 5px;
}

#categoryList::-webkit-scrollbar-thumb {
    background-color: #e50914;
    border-radius: 5px;
}

#categoryList li {
    margin-right: 15px;
}

#categoryList a {
    color: #aaa;
    text-decoration: none;
    padding: 5px 10px;
    border-radius: 4px;
    transition: all 0.3s ease;
    white-space: nowrap;
}

#categoryList a:hover, #categoryList a.active {
    color: #fff;
    background-color: #e50914;
}

/* Contenido principal */
main {
    padding: 30px 0;
}

/* Reproductor de video */
.player-container {
    background-color: #1e1e1e;
    border-radius: 8px;
    margin-bottom: 30px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.player-container.hidden {
    display: none;
}

.player-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background-color: #252525;
}

.player-header h2 {
    font-size: 18px;
    color: #fff;
}

#closePlayer {
    background: none;
    border: none;
    color: #aaa;
    font-size: 20px;
    cursor: pointer;
}

#closePlayer:hover {
    color: #e50914;
}

#videoPlayer {
    width: 100%;
    height: auto;
    max-height: 70vh;
    background-color: #000;
}

/* Canales */
.channels-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

.channel-card {
    background-color: #1e1e1e;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.channel-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
}

.channel-thumbnail {
    height: 120px;
    background-color: #252525;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #e50914;
    font-size: 40px;
}

.channel-info {
    padding: 15px;
}

.channel-info h3 {
    font-size: 16px;
    margin-bottom: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.channel-info p {
    color: #aaa;
    font-size: 14px;
}

/* Paginación */
.pagination {
    display: flex;
    justify-content: center;
    margin-top: 30px;
}

.pagination button {
    background-color: #252525;
    color: #fff;
    border: none;
    padding: 8px 15px;
    margin: 0 5px;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.3s ease;
}

.pagination button:hover {
    background-color: #333;
}

.pagination button.active {
    background-color: #e50914;
}

.pagination button:disabled {
    background-color: #1a1a1a;
    color: #555;
    cursor: not-allowed;
}

/* Footer */
footer {
    background-color: #1e1e1e;
    padding: 20px 0;
    text-align: center;
    border-top: 1px solid #333;
}

footer p {
    color: #aaa;
    font-size: 14px;
}

/* Responsive */
@media (max-width: 768px) {
    header .container {
        flex-direction: column;
    }
    
    header h1 {
        margin-bottom: 15px;
    }
    
    .search-container {
        width: 100%;
    }
    
    #searchInput {
        width: 100%;
    }
    
    .channels-container {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }
}

.channel-logo {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    background: #252525;
    border-radius: 4px;
    padding: 8px;
}