/* ===== Dark Theme Video Gallery ===== */

:root {
    --bg-primary: #0a0a0f;
    --bg-secondary: #12121a;
    --bg-tertiary: #1a1a25;
    --bg-hover: #22222f;
    --text-primary: #ffffff;
    --text-secondary: #a0a0b0;
    --text-muted: #606070;
    --accent: #b20101;
    --border: #2a2a3a;
    --shadow: rgba(0, 0, 0, 0.5);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: var(--bg-primary);
    color: var(--text-primary);
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    min-height: 100vh;
    line-height: 1.6;
}

/* ===== Banner Slider ===== */
.banner-wrapper {
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 20px 0;
    background: var(--bg-secondary);
}

.banner-slider {
    width: 100%;
    max-width: 900px;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 10px 40px var(--shadow);
}

.banner-slider .swiper-slide {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-tertiary);
}

.banner-slider .swiper-slide img {
    width: 100%;
    height: auto;
    max-height: 300px;
    object-fit: contain;
    display: block;
}

.banner-slider .swiper-pagination-bullet {
    width: 10px;
    height: 10px;
    background: var(--bg-tertiary);
    opacity: 1;
    transition: all 0.3s ease;
}

.banner-slider .swiper-pagination-bullet-active {
    background: var(--accent);
    width: 24px;
    border-radius: 5px;
}

/* ===== Main Layout ===== */
.main-layout {
    display: flex;
    gap: 20px;
    max-width: 1800px;
    margin: 0 auto;
    padding: 0 20px 20px;
}

/* ===== Left Sidebar ===== */
.sidebar {
    width: 380px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    max-height: calc(100vh - 380px);
}

.filters-bar {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 16px;
    padding: 14px;
    background: var(--bg-secondary);
    border-radius: 12px;
}

.search-input {
    width: 100%;
    padding: 10px 14px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 0.9rem;
}

.search-input:focus {
    outline: none;
    border-color: var(--accent);
}

.search-input::placeholder {
    color: var(--text-muted);
}

.date-range {
    display: flex;
    align-items: center;
    gap: 6px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 6px 10px;
}

.date-input {
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 0.8rem;
    width: 110px;
    cursor: pointer;
}

.date-input:focus {
    outline: none;
}

.date-input::-webkit-calendar-picker-indicator {
    filter: invert(1);
    opacity: 0.5;
    cursor: pointer;
}

.date-range span {
    color: var(--text-muted);
}

.clear-btn {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0 4px;
    margin-left: auto;
}

.clear-btn:hover {
    color: var(--accent);
}

.sort-select {
    width: 100%;
    padding: 10px 14px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 0.9rem;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 10 10'%3E%3Cpath fill='%23a0a0b0' d='M2 3l3 3 3-3z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
}

.sort-select:focus {
    outline: none;
    border-color: var(--accent);
}

.videos-list {
    flex: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-right: 4px;
}

.videos-list::-webkit-scrollbar {
    width: 6px;
}

.videos-list::-webkit-scrollbar-track {
    background: transparent;
}

.videos-list::-webkit-scrollbar-thumb {
    background: var(--bg-tertiary);
    border-radius: 3px;
}

.video-item {
    display: flex;
    gap: 10px;
    padding: 10px;
    background: var(--bg-secondary);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.video-item:hover {
    background: var(--bg-hover);
    border-color: var(--border);
    transform: translateX(4px);
}

.video-item .video-thumb {
    position: relative;
    width: 140px;
    flex-shrink: 0;
    aspect-ratio: 16/9;
    border-radius: 8px;
    overflow: hidden;
    background: var(--bg-tertiary);
}

.video-item .video-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.play-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.4);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.video-item:hover .play-overlay {
    opacity: 1;
}

.play-overlay svg {
    width: 32px;
    height: 32px;
}

.badge {
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 0.6rem;
    font-weight: 600;
    text-transform: uppercase;
}

.badge.premiera {
    background: var(--accent);
    color: white;
}

.badge.live {
    background: #ff4757;
    color: white;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}

.video-item .video-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
}

.video-item .video-info h4 {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-primary);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 6px;
}

.video-date {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* ===== Right Main Content ===== */
.main-content {
    flex: 1;
    min-width: 0;
}

.player-wrapper {
    background: var(--bg-secondary);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 20px 60px var(--shadow);
}

.player-container {
    position: relative;
    width: 100%;
    padding-top: 56.25%;
    background: #000;
}

.video-frame {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.player-info {
    padding: 20px 24px;
}

.player-info h1 {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.4;
}

.meta-info {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-top: 8px;
}

.schedule-section {
    margin-top: 24px;
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 16px 20px;
}

.schedule-section h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 14px;
}

.schedule-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.schedule-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    background: var(--bg-tertiary);
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s ease;
}

.schedule-item:hover {
    background: var(--bg-hover);
}

.schedule-time {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--accent);
    min-width: 55px;
}

.schedule-title {
    flex: 1;
    font-size: 0.9rem;
    color: var(--text-primary);
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
    background: var(--bg-tertiary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--border);
}

/* ===== Responsive ===== */
@media (max-width: 1200px) {
    .main-layout {
        flex-direction: column-reverse;
    }

    .sidebar {
        width: 100%;
        max-height: none;
    }

    .videos-list {
        overflow: visible;
    }
}

@media (max-width: 768px) {
    .main-layout {
        padding: 0 12px;
    }

    .banner-slider .swiper-slide img {
        max-height: 180px;
    }

    .player-info h1 {
        font-size: 1.1rem;
    }

    .filters-bar {
        padding: 12px;
    }

    .date-range {
        flex-wrap: wrap;
    }

    .date-input {
        width: 48%;
    }

    .video-item {
        flex-direction: column;
    }

    .video-item .video-thumb {
        width: 100%;
    }
}
