/* cards */

header section {
    position: relative;
    width: 100%;
    padding: 30px 5vw 20px 5vw;
    color: #fff;
    font-size: 25px;
    background: rgba(22, 37, 48, 0.7);
    border-radius: 0 0 24px 24px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.12);
    margin-bottom: 30px;
}

header section h3 {
    font-size: 2.2rem;
    font-weight: 700;
    letter-spacing: 1px;
    margin-bottom: 18px;
    color: #ffcc00;
    text-shadow: 0 2px 8px rgba(0,0,0,0.18);
    padding-left: 8px;
}

header section .cards {
    display: flex;
    gap: 24px;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding-bottom: 10px;
}

header section .cards::-webkit-scrollbar {
    height: 8px;
    background: rgba(255,255,255,0.08);
    border-radius: 4px;
}
header section .cards::-webkit-scrollbar-thumb {
    background: #ffcc00;
    border-radius: 4px;
}

header section .cards .card {
    min-width: 220px;
    height: 340px;
    background: rgba(255,255,255,0.07);
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.18);
    transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
    overflow: hidden;
    position: relative;
    border: 1.5px solid rgba(255,255,255,0.08);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

header section .cards .card:hover {
    transform: translateY(-8px) scale(1.04);
    box-shadow: 0 8px 32px rgba(255,204,0,0.18), 0 2px 16px rgba(0,0,0,0.18);
    background: rgba(255,255,255,0.13);
    z-index: 2;
}

header section .cards .card .poster {
    width: 100%;
    height: 70%;
    object-fit: cover;
    border-radius: 16px 16px 0 0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.10);
}

header section .cards .card .rest_card {
    background: none;
    position: static;
    width: 100%;
    height: 30%;
    padding: 12px 16px 10px 16px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    border-radius: 0 0 16px 16px;
}

header section .cards .card .rest_card .cont {
    color: #fff;
    padding: 0;
}

header section .cards .card .rest_card .cont h4 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 6px;
    color: #ffcc00;
    text-shadow: 0 1px 4px rgba(0,0,0,0.13);
}

header section .cards .card .rest_card .cont .sub {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

header section .cards .card .rest_card .cont p {
    font-size: 0.95rem;
    color: rgba(255,255,255,0.85);
    margin: 0;
}

header section .cards .card .rest_card .cont .sub h5 span {
    background: #ffcc00;
    color: #162530;
    padding: 2px 6px;
    margin: 0 5px 0 10px;
    font-weight: 600;
    border-radius: 8px;
    font-size: 0.95rem;
}

header section .cards .card .rest_card .cont .sub h5 i {
    margin-left: 3px;
    color: #ffcc00;
}
/* @media (max-width: 480px) {
    header section .cards .card .rest_card .cont .sub h5 i{
        font-size: 0.6rem;
    }    
} */
@media (max-width: 900px) {
    header section .cards {
        gap: 14px;
    }
    header section .cards .card {
        min-width: 170px;
        height: 260px;
    }
}

@media (max-width: 600px) {
    header section {
        padding: 18px 2vw 10px 2vw;
    }
    header section h3 {
        font-size: 1.3rem;
        padding-left: 2px;
    }
    header section .cards .card {
        min-width: 120px;
        height: 170px;
        border-radius: 10px;
    }
    header section .cards .card .poster {
        border-radius: 10px 10px 0 0;
    }
    header section .cards .card .rest_card {
        padding: 6px 7px 5px 7px;
        border-radius: 0 0 10px 10px;
    }
    header section .cards .card .rest_card .cont h4 {
        font-size: 0.65rem;
        margin-bottom: 0px;
    }
    header section .cards .card .rest_card .cont p {
        font-size: 0.5rem;
    }
    header section .cards .card .rest_card .cont .sub h5 span {
        font-size: 0.7rem;
        padding: 1px 4px;
    }
    header section .fa-chevron-left,
    header section .fa-chevron-right {
        width: 32px;
        height: 32px;
        font-size: 1.1rem;
        margin-left: -16px;
        margin-right: -16px;
    }
}

/* logo of mobile view */


header section .fa-chevron-left,
header section .fa-chevron-right {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    background: rgba(22, 37, 48, 0.85);
    color: #ffcc00;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 1.6rem;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0,0,0,0.18);
    z-index: 10;
    border: 2px solid #ffcc00;
    opacity: 1;
    transition: background 0.2s, color 0.2s, transform 0.2s;
}
header section .fa-chevron-left {
    left: 0;
    margin-left: 22px;
}
header section .fa-chevron-right {
    right: 0;
    margin-right: 22px;
}
header section .fa-chevron-left:hover,
header section .fa-chevron-right:hover {
    background: #ffcc00;
    color: #162530;
    transform: translateY(-50%) scale(1.08);
}

@media (max-width: 480px) {
    header section .fa-chevron-left, header section .fa-chevron-right {
        font-size: 0.6rem;
        width: 30px;
        height: 30px;
    }

}



/* All New Show Section - Modern Design */
.movie-list-container {
    color: white;
    padding: clamp(20px, 4vw, 40px);
    width: 100%;
    max-width: 1440px;
    margin: 0 auto;
    background: linear-gradient(180deg, rgba(17, 17, 17, 0.8) 0%, rgba(17, 17, 17, 0.4) 100%);
    border-radius: 20px;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    margin-bottom: 20px;
}

/* Section Header */
.section-header {
    margin-bottom: 30px;
}

.header-content {
    display: flex;
    align-items: baseline;
    gap: 15px;
    margin-bottom: 20px;
}

.section-header h4 {
    font-size: clamp(24px, 3vw, 32px);
    font-weight: 700;
    background: linear-gradient(45deg, #fff, #f71c24);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.section-header .subtitle {
    color: rgba(255, 255, 255, 0.7);
    font-size: clamp(14px, 1.5vw, 16px);
}

/* Filter and Sort Controls */
.filter-sort {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 8px 16px;
    border: 2px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.05);
    color: white;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.filter-btn.active {
    background: #f71c24;
    border-color: #f71c24;
    color: white;
}

.sort-select {
    padding: 8px 16px;
    border: 2px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.05);
    color: rgb(255, 0, 0);
    border-radius: 20px;
    font-size: 14px;
    cursor: pointer;
    outline: none;
}

.sort-select:hover {
    border-color: rgba(255, 255, 255, 0.2);
}

/* Movie Grid */
.Movie-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin: 30px 0;
}

/* Movie Card */
.container {
    perspective: 1000px;
    aspect-ratio: 2/3;
    width: 100%;
}

.card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.8s;
    transform-style: preserve-3d;
    cursor: pointer;
}

.container:hover .card-inner {
    transform: scale(1.02);
}

.card-inner.is-flipped {
    transform: rotateY(180deg);
}

.card-front,
.card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 15px;
    overflow: hidden;
    background: #1a1a1a;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.card-front {
    position: relative;
}

.card-back {
    transform: rotateY(180deg);
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background: linear-gradient(135deg, #1a1a1a 0%, #2a2a2a 100%);
}

.movie-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.8) 0%,
        rgba(0, 0, 0, 0) 30%,
        rgba(0, 0, 0, 0) 50%,
        rgba(0, 0, 0, 0.9) 100%
    );
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.container:hover .overlay {
    opacity: 1;
}

/* Card Content */
.title-box {
    position: absolute;
    bottom: 20px;
    left: 0;
    width: 100%;
    padding: 0 20px;
    text-align: left;
    z-index: 2;
}

.media {
    display: inline-block;
    padding: 4px 8px;
    background: rgba(247, 28, 36, 0.9);
    color: white;
    font-size: 12px;
    font-weight: 600;
    border-radius: 4px;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.movie-name {
    font-size: 18px;
    font-weight: 700;
    color: white;
    margin: 8px 0;
    line-height: 1.3;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.genre {
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    display: block;
}

.quick-info {
    position: absolute;
    top: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    z-index: 2;
}

.rating,
.year {
    background: rgba(0, 0, 0, 0.6);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.rating i {
    color: #ffd700;
}

/* Card Back Content */
.description {
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    line-height: 1.6;
    text-align: left;
    margin-bottom: 20px;
}

.action-buttons {
    display: flex;
    gap: 10px;
    margin-top: auto;
}

.watch-btn,
.info-btn {
    flex: 1;
    padding: 12px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s ease;
    text-decoration: none;
}

.watch-btn {
    background: #f71c24;
    color: white;
    border: none;
}

.watch-btn:hover {
    background: #ff2c34;
    transform: translateY(-2px);
}

.info-btn {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

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

/* Load More Button */
.list-footer {
    display: flex;
    justify-content: center;
    margin-top: 40px;
}

.load-more-button {
    position: relative;
    padding: 12px 30px;
    background: linear-gradient(45deg, #f71c24, #ff4b52);
    color: white;
    border: none;
    border-radius: 25px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
    overflow: hidden;
}

.load-more-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(247, 28, 36, 0.3);
}

.load-more-button .button-text {
    transition: opacity 0.3s ease;
}

.loader {
    display: none;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s linear infinite;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
}

@keyframes spin {
    to {
        transform: translateX(-50%) rotate(360deg);
    }
}

/* Not Found Message */
.not-found-message {
    text-align: center;
    color: rgba(255, 255, 255, 0.7);
    font-size: 16px;
    padding: 40px 0;
}

/* Mobile Optimizations */
@media screen and (max-width: 768px) {
    .movie-list-container {
        padding: 20px;
        border-radius: 15px;
    }

    .filter-sort {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }

    .filter-group {
        justify-content: center;
    }

    .sort-select {
        width: 100%;
        text-align: center;
    }

    .Movie-list {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 15px;
    }
}

@media screen and (max-width: 480px) {
    .movie-list-container {
        padding: 15px;
        border-radius: 10px;
    }

    .header-content {
        flex-direction: column;
        gap: 5px;
    }

    .filter-btn {
        padding: 6px 12px;
        font-size: 12px;
    }

    .Movie-list {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 10px;
    }

    .title-box {
        padding: 0 10px;
        bottom: 10px;
    }

    .movie-name {
        font-size: 14px;
    }

    .genre {
        font-size: 12px;
    }

    .quick-info {
        top: 10px;
        right: 10px;
    }

    .rating,
    .year {
        font-size: 10px;
        padding: 3px 6px;
    }
}

/* Dark Mode Enhancement */
@media (prefers-color-scheme: dark) {
    .movie-list-container {
        background: linear-gradient(180deg, rgba(10, 10, 10, 0.9) 0%, rgba(10, 10, 10, 0.5) 100%);
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .movie-list-container {
        background: #000;
    }

    .filter-btn,
    .sort-select {
        border: 2px solid #fff;
    }

    .movie-name {
        text-shadow: none;
    }

    .watch-btn {
        background: #f00;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .card-inner,
    .container:hover .card-inner,
    .movie-img,
    .load-more-button,
    .filter-btn,
    .watch-btn,
    .info-btn {
        transition: none;
        transform: none;
    }

    .loader {
        animation: none;
    }
}


