/* Films Page Styles */

/* Films Hero Section */
.films-hero {
    height: 700px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 80px;
    overflow: hidden;
    background: #000;
}

/* Movie Slider Background */
.movie-collage {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
}

/* Sliding Rows */
.movie-row {
    display: flex;
    position: absolute;
    width: 200%;
    height: calc(33.33% - 20px);
    gap: 15px;
    padding: 0 10px;
}

.movie-row:nth-child(1) {
    top: 10px;
    animation: slideLeft 40s linear infinite;
}

.movie-row:nth-child(2) {
    top: calc(33.33% + 10px);
    animation: slideRight 35s linear infinite;
}

.movie-row:nth-child(3) {
    top: calc(66.66% + 10px);
    animation: slideLeft 45s linear infinite;
}

@keyframes slideLeft {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

@keyframes slideRight {
    0% {
        transform: translateX(-50%);
    }
    100% {
        transform: translateX(0);
    }
}

.movie-poster {
    flex: 0 0 280px;
    height: 100%;
    overflow: hidden;
    opacity: 0.25;
    border-radius: 8px;
    background: #111;
}

.movie-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(80%);
    transition: filter 0.3s ease;
}

/* Dark Overlay */
.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0.75) 60%, rgba(0, 0, 0, 0.85) 100%);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: var(--white);
    max-width: 800px;
    padding: 0 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 120px;
}

.hero-title {
    font-size: 90px;
    font-weight: 700;
    margin-bottom: 30px;
    letter-spacing: -2px;
    line-height: 0.9;
    color: var(--white);
    text-transform: uppercase;
}

.hero-subtitle {
    font-size: 24px;
    opacity: 0.9;
    font-weight: 300;
    letter-spacing: 0.5px;
    line-height: 1.4;
    margin: 0;
}

/* Simple Line Decoration */
.hero-line {
    width: 100px;
    height: 1px;
    background: var(--white);
    margin: 30px auto;
    opacity: 0.5;
}

/* Films Section */
.films-section {
    background: #000;
    padding: 80px 0;
    min-height: 100vh;
}

.films-section .container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Filter Buttons */
.filter-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 60px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 12px 30px;
    background: transparent;
    color: var(--white);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 30px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--white);
    color: #000;
    transform: translateY(-2px);
}

/* Films Grid */
.films-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 30px;
    padding: 0 20px;
    max-width: 1400px;
    margin: 0 auto;
}

/* Film Card */
.film-card {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #111;
    border: none;
    animation: fadeInUp 0.6s ease forwards;
    opacity: 0;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

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

.film-card:nth-child(1) { animation-delay: 0.1s; }
.film-card:nth-child(2) { animation-delay: 0.2s; }
.film-card:nth-child(3) { animation-delay: 0.3s; }
.film-card:nth-child(4) { animation-delay: 0.4s; }
.film-card:nth-child(5) { animation-delay: 0.5s; }
.film-card:nth-child(6) { animation-delay: 0.6s; }
.film-card:nth-child(7) { animation-delay: 0.7s; }
.film-card:nth-child(8) { animation-delay: 0.8s; }
.film-card:nth-child(9) { animation-delay: 0.9s; }
.film-card:nth-child(10) { animation-delay: 1s; }
.film-card:nth-child(11) { animation-delay: 1.1s; }
.film-card:nth-child(12) { animation-delay: 1.2s; }

.film-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
}

.film-poster {
    position: relative;
    width: 100%;
    padding-bottom: 140%;
    overflow: hidden;
    background: #111;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.film-poster img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    transition: transform 0.3s ease;
    background: #111;
    border-radius: 16px;
}

.film-card:hover .film-poster img {
    transform: scale(1.05);
}

/* Film Overlay */
.film-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.95) 0%, rgba(0, 0, 0, 0.7) 50%, transparent 100%);
    padding: 40px 20px 20px;
    transform: translateY(0);
    transition: all 0.3s ease;
}

.film-card:hover .film-overlay {
    background: linear-gradient(to top, rgba(0, 0, 0, 0.98) 0%, rgba(0, 0, 0, 0.8) 60%, transparent 100%);
}

.film-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 5px;
    color: var(--white);
}

.film-year {
    font-size: 14px;
    opacity: 0.8;
    color: var(--white);
}

/* Modal Styles */
.film-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    overflow-y: auto;
}

.modal-content {
    position: relative;
    background: #111;
    margin: 50px auto;
    padding: 0;
    width: 90%;
    max-width: 1000px;
    border-radius: 10px;
    overflow: hidden;
}

.close-modal {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 40px;
    color: var(--white);
    cursor: pointer;
    z-index: 10;
    transition: transform 0.3s ease;
}

.close-modal:hover {
    transform: rotate(90deg);
}

.modal-body {
    display: grid;
    grid-template-columns: 400px 1fr;
    min-height: 600px;
}

.modal-poster {
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-poster img {
    width: 100%;
    height: auto;
    max-height: 600px;
    object-fit: contain;
}

.modal-info {
    padding: 40px;
    color: var(--white);
}

#modalTitle {
    font-size: 36px;
    margin-bottom: 30px;
    color: var(--white);
}

.film-details {
    margin-bottom: 30px;
}

.film-details p {
    margin-bottom: 15px;
    font-size: 16px;
    color: rgba(255, 255, 255, 0.8);
}

.film-details strong {
    color: var(--white);
    margin-right: 10px;
}

.film-synopsis {
    margin-bottom: 30px;
}

.film-synopsis h3 {
    font-size: 20px;
    margin-bottom: 15px;
    color: var(--white);
}

.film-synopsis p {
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.8);
}

/* Platform Links */
.platform-links h3 {
    font-size: 18px;
    margin-bottom: 14px;
    color: var(--white);
    letter-spacing: 0.5px;
}

.platform-links-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.platform-link-btn {
    display: inline-flex;
    align-items: center;
    padding: 10px 22px;
    background: rgba(200, 167, 80, 0.12);
    border: 1px solid rgba(200, 167, 80, 0.35);
    color: #d4af37;
    border-radius: 24px;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    letter-spacing: 0.3px;
    transition: all 0.3s ease;
}

.platform-link-btn:hover {
    background: rgba(200, 167, 80, 0.25);
    border-color: #d4af37;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(200, 167, 80, 0.2);
}

.modal-actions {
    margin-top: 40px;
}

.btn-more-info {
    display: inline-block;
    padding: 12px 30px;
    background: var(--white);
    color: #000;
    text-decoration: none;
    border-radius: 30px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-more-info:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(255, 255, 255, 0.2);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .modal-body {
        grid-template-columns: 1fr;
    }
    
    .modal-poster {
        max-height: 400px;
    }
}

@media (max-width: 768px) {
    .films-hero {
        height: 600px;
    }
    
    .hero-content {
        padding-top: 100px;
    }
    
    .hero-title {
        font-size: 60px;
        margin-bottom: 20px;
    }
    
    .hero-subtitle {
        font-size: 20px;
    }
    
    .movie-poster {
        flex: 0 0 200px;
    }
    
    .films-grid {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
        gap: 20px;
    }
    
    .filter-buttons {
        gap: 10px;
    }
    
    .filter-btn {
        padding: 10px 20px;
        font-size: 14px;
    }
    
    .modal-info {
        padding: 30px 20px;
    }
    
    #modalTitle {
        font-size: 28px;
    }
}

@media (max-width: 480px) {
    .films-hero {
        height: 500px;
    }
    
    .hero-content {
        padding-top: 80px;
    }
    
    .hero-title {
        font-size: 48px;
        letter-spacing: -1px;
        margin-bottom: 20px;
    }
    
    .hero-subtitle {
        font-size: 18px;
    }
    
    .hero-line {
        margin: 20px auto;
    }
    
    .movie-poster {
        flex: 0 0 150px;
    }
    
    .movie-row {
        gap: 5px;
    }
    
    .hero-content {
        padding: 0 20px;
    }
    
    .films-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
        padding: 0 10px;
    }
    
    .close-modal {
        top: 10px;
        right: 15px;
        font-size: 30px;
    }
}