/* Movie Listing Shared Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: #141414;
    font-family: 'Segoe UI', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    color: #fff;
}

/* Hero Banner Styles */
.hero-banner {
    position: relative;
    height: 80vh;
    min-height: 550px;
    background-size: cover;
    background-position: center top;
    background-repeat: no-repeat;
    margin-bottom: -150px;
    z-index: 1;
}

.banner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(0deg, #141414 0%, rgba(0,0,0,0.5) 50%, rgba(0,0,0,0.7) 100%);
}

.banner-gradient {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 200px;
    background: linear-gradient(0deg, #141414 0%, transparent 100%);
}

.banner-content {
    position: absolute;
    bottom: 25%;
    left: 5%;
    max-width: 600px;
    z-index: 2;
    animation: fadeInUp 0.8s ease;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.badge {
    display: inline-block;
    padding: 6px 18px;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: bold;
    margin-bottom: 20px;
    letter-spacing: 1px;
    backdrop-filter: blur(5px);
}

.badge i {
    margin-right: 8px;
}

.banner-content h1 {
    font-size: 3.8rem;
    font-weight: 800;
    margin-bottom: 15px;
    text-shadow: 2px 2px 8px rgba(0,0,0,0.8);
    line-height: 1.2;
}

.banner-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    font-size: 0.9rem;
    color: #ddd;
    flex-wrap: wrap;
}

.banner-meta span {
    display: flex;
    align-items: center;
    gap: 8px;
}

.rating {
    color: #ffc107;
}

.banner-description {
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 25px;
    color: #e0e0e0;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.banner-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.btn-watch, .btn-list {
    padding: 12px 30px;
    border: none;
    border-radius: 5px;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.btn-watch {
    background: white;
    color: black;
}

.btn-watch:hover {
    background: rgba(255,255,255,0.8);
    transform: scale(1.05);
}

.btn-list {
    background: rgba(109, 109, 110, 0.7);
    color: white;
    backdrop-filter: blur(5px);
}

.btn-list:hover {
    background: rgba(109, 109, 110, 0.4);
    transform: scale(1.05);
}

/* All Movies Wrapper */
.all-movies-wrapper {
    max-width: 95%;
    margin: 0 auto;
    position: relative;
    z-index: 10;
    padding: 20px 0 50px;
}

/* Page Header */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin: 30px 0 20px;
    flex-wrap: wrap;
    gap: 20px;
}

.header-left {
    flex: 1;
}

.header-left h1 {
    font-size: 1.8rem;
    font-weight: 600;
    color: #fff;
    margin-bottom: 8px;
}

.header-left p {
    color: #aaa;
    font-size: 0.9rem;
}

.movies-count {
    color: #aaa;
    font-size: 0.9rem;
    background: rgba(255,255,255,0.05);
    padding: 8px 16px;
    border-radius: 8px;
    white-space: nowrap;
}

.movies-count i {
    margin-right: 8px;
}

/* Filter Navigation Bar */
.filter-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    padding: 12px 0;
    margin-bottom: 25px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    background: transparent;
}

.filter-nav .filter-item {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.filter-nav select {
    background: transparent;
    border: none;
    color: #aaa;
    font-size: 0.85rem;
    padding: 8px 28px 8px 12px;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    font-family: inherit;
    transition: color 0.3s;
    border-radius: 6px;
    min-width: 80px;
}

.filter-nav select:hover {
    color: #fff;
}

.filter-nav select:focus {
    outline: none;
    color: #fff;
}

.filter-nav select option {
    background: #1a1a2e;
    color: #fff;
    padding: 8px 12px;
}

.filter-nav .filter-arrow {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    color: #666;
    font-size: 0.65rem;
    pointer-events: none;
    transition: color 0.3s;
}

.filter-nav .filter-item:hover .filter-arrow {
    color: #fff;
}

.filter-nav .filter-divider {
    color: #333;
    font-size: 0.8rem;
    padding: 0 2px;
}

.filter-nav select.active-filter {
    color: #fff;
}

/* Grid layout */
.movies-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 15px;
    margin-bottom: 40px;
}

/* Card Styles */
.card {
    background: #1a1a2e;
    border-radius: 10px;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
    position: relative;
}

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

.card img {
    width: 100%;
    height: auto;
    min-height: 250px;
    object-fit: cover;
}

.movie-info {
    padding: 12px;
}

.movie-title {
    font-size: 0.9rem;
    font-weight: bold;
    margin-bottom: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.movie-rating {
    color: #ffc107;
    font-size: 0.8rem;
    margin-bottom: 3px;
}

.movie-year {
    color: #888;
    font-size: 0.75rem;
    margin-bottom: 5px;
}

.movie-runtime {
    color: #00BCD4;
    font-size: 0.7rem;
    margin-bottom: 3px;
}

.movie-genres {
    color: #aaa;
    font-size: 0.7rem;
    margin-bottom: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.media-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: bold;
    margin-bottom: 8px;
}

.badge-movie {
    background: #e74c3c;
}

.badge-tv {
    background: #3498db;
}

.language-tag {
    display: inline-block;
    background: rgba(231, 76, 60, 0.2);
    border-left: 3px solid #e74c3c;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    margin-top: 5px;
    color: #e74c3c;
}

/* Download Options */
.download-options {
    margin-top: 8px;
}

.download-links-container {
    max-height: 80px;
    overflow-y: auto;
    margin-top: 4px;
}

.download-links-container::-webkit-scrollbar {
    width: 3px;
}

.download-links-container::-webkit-scrollbar-track {
    background: rgba(255,255,255,0.05);
    border-radius: 10px;
}

.download-links-container::-webkit-scrollbar-thumb {
    border-radius: 10px;
}

.download-link-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255,255,255,0.08);
    padding: 6px 10px;
    border-radius: 6px;
    margin-bottom: 4px;
    transition: background 0.3s;
    text-decoration: none;
    color: #fff;
    font-size: 0.7rem;
}

.download-link-item:hover {
    background: rgba(255,255,255,0.15);
}

.download-link-item .quality {
    font-weight: bold;
    color: #ffc107;
    font-size: 0.75rem;
}

.download-link-item .file-size {
    color: #4CAF50;
    font-size: 0.7rem;
    background: rgba(76, 175, 80, 0.15);
    padding: 2px 8px;
    border-radius: 10px;
}

.download-link-item .download-icon {
    color: #2196F3;
    font-size: 0.8rem;
}

.download-link-item:hover .download-icon {
    color: #ffc107;
}

.no-links-text {
    color: #f39c12;
    font-size: 0.7rem;
    font-weight: bold;
    text-align: center;
    padding: 4px;
    background: rgba(243, 156, 18, 0.15);
    border-radius: 4px;
    border: 1px dashed #f39c12;
}

/* Hover info panel */
.card-hover-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(0deg, rgba(0,0,0,0.95) 0%, rgba(0,0,0,0.8) 100%);
    padding: 10px;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    z-index: 10;
    border-radius: 0 0 10px 10px;
}

.card:hover .card-hover-info {
    transform: translateY(0);
}

.hover-text {
    font-size: 0.7rem;
    color: #ddd;
    margin: 3px 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.hover-text i {
    width: 16px;
    margin-right: 5px;
}

/* Pagination */
.pagination-container {
    text-align: center;
    margin: 40px 0 20px;
}

.pagination {
    display: inline-flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
}

.pagination a, .pagination span {
    padding: 8px 14px;
    border-radius: 8px;
    background: #2a2a2a;
    color: white;
    text-decoration: none;
    transition: all 0.3s;
}

.pagination a:hover {
    background: #e74c3c;
}

.pagination .active {
    background: #e74c3c;
}

.pagination .disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pagination-info {
    margin-top: 15px;
    color: #888;
    font-size: 0.85rem;
}

.page-prev, .page-next {
    font-weight: bold;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 50px;
    background: #1a1a2e;
    border-radius: 15px;
    margin: 30px 0;
}

.empty-state p {
    color: #aaa;
    margin: 10px 0;
    line-height: 1.6;
}

.back-btn {
    display: inline-block;
    color: white;
    padding: 10px 20px;
    border-radius: 8px;
    text-decoration: none;
    margin: 20px 0;
    transition: all 0.3s;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #1a1a1a;
}

::-webkit-scrollbar-thumb {
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: #c0392b;
}

/* Responsive */
@media (max-width: 1400px) {
    .movies-grid {
        grid-template-columns: repeat(6, 1fr);
    }
}

@media (max-width: 1100px) {
    .movies-grid {
        grid-template-columns: repeat(5, 1fr);
    }
}

@media (max-width: 900px) {
    .movies-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 768px) {
    .hero-banner {
        height: 70vh;
        min-height: 450px;
    }

    .banner-content {
        bottom: 20%;
        left: 5%;
        right: 5%;
    }

    .banner-content h1 {
        font-size: 2rem;
    }

    .banner-description {
        font-size: 0.85rem;
        -webkit-line-clamp: 2;
    }

    .banner-meta {
        font-size: 0.75rem;
        gap: 12px;
    }

    .btn-watch, .btn-list {
        padding: 8px 20px;
        font-size: 0.85rem;
    }

    .header-left h1 {
        font-size: 1.4rem;
    }

    .filter-nav {
        gap: 4px;
        padding: 8px 0;
        overflow-x: auto;
        flex-wrap: nowrap;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .filter-nav::-webkit-scrollbar {
        display: none;
    }

    .filter-nav select {
        font-size: 0.75rem;
        padding: 6px 24px 6px 10px;
        min-width: 60px;
    }

    .filter-nav .filter-divider {
        display: none;
    }

    .movies-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 600px) {
    .movies-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 480px) {
    .hero-banner {
        height: 60vh;
        min-height: 350px;
    }

    .banner-content h1 {
        font-size: 1.6rem;
    }

    .banner-buttons {
        flex-direction: column;
    }

    .btn-watch, .btn-list {
        justify-content: center;
    }

    .filter-nav select {
        font-size: 0.7rem;
        padding: 5px 20px 5px 8px;
        min-width: 50px;
    }

    .movies-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .page-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .movies-count {
        white-space: normal;
    }
}