/* ================= Global Reset ================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background-color: #0f172a; /* Dark background */
    color: #f8fafc;
    line-height: 1.6;
}

/* ================= Header / Navbar ================= */
header {
    background: rgba(30, 41, 59, 0.9);
    backdrop-filter: blur(10px);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

nav ul {
    display: flex;
    justify-content: center;
    gap: 25px;
    list-style: none;
    flex-wrap: wrap;
}

nav a {
    text-decoration: none;
    color: #cbd5e1;
    font-weight: 600;
    transition: all 0.3s ease;
}

nav a:hover {
    color: #f97316;
    transform: scale(1.1);
}

/* ================= Search Section ================= */
#search-section {
    text-align: center;
    padding: 20px;
    position: relative;
}

#search-input {
    width: 60%;
    max-width: 500px;
    padding: 12px 15px;
    border-radius: 30px;
    border: none;
    outline: none;
    background: #334155;
    color: #f8fafc;
    font-size: 16px;
}
#search-form > button{
    padding: 10px 20px;
    border: none;
    border-radius: 20px;
    background: #f97316;
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s;
}
#realtime-search-result {
    position: absolute;
    top: 65px;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    max-width: 500px;
    background: #1e293b;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    max-height: 250px;
    overflow-y: auto;
    z-index: 200;
}

.search-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 10px;
    cursor: pointer;
    border-bottom: 1px solid #334155;
    transition: background 0.3s;
}

.search-item img {
    width: 50px;
    height: 70px;
    border-radius: 5px;
    object-fit: cover;
}

.search-item span {
    font-weight: 500;
    color: #f8fafc;
}

.search-item:hover {
    background: #475569;
}

/* ================= Sections ================= */
section {
    padding: 30px 20px;
}

section h2 {
    font-size: 24px;
    margin-bottom: 15px;
    color: #f97316;
}

/* ================= Content Grid ================= */

.content-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 20px;
}

/* ================= Movie / Card Styling ================= */
.movie-card, .card {
    background: rgba(30, 41, 59, 0.7);
    border-radius: 15px;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
    width: 180px;
    text-align: center;
}

.movie-card:hover, .card:hover {
    transform: scale(1.05);
    box-shadow: 0 0 15px #f97316;
}

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

.movie-card h3, .card h3 {
    font-size: 16px;
    margin: 10px 0 5px;
    font-weight: 600;
    color: #f8fafc;
}

.movie-card p, .card p {
    font-size: 14px;
    color: #94a3b8;
    margin-bottom: 8px;
}

.movie-card button, .card button {
    padding: 8px 12px;
    margin-bottom: 10px;
    border: none;
    border-radius: 20px;
    background: #f97316;
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s, transform 0.3s;
}

.movie-card button:hover, .card button:hover {
    background: #ea580c;
    transform: scale(1.05);
}

/* ================= Favourites Section ================= */
#favourites p {
    text-align: center;
    color: #94a3b8;
}

/* ================= Trailer / Providers ================= */
.trailer-iframe {
    width: 100%;
    max-width: 800px;
    height: 450px;
    margin: 20px auto;
    display: block;
    border-radius: 15px;
    box-shadow: 0 0 40px #f97316;
}

.provider {
    display: inline-block;
    margin: 10px;
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
}

.provider img {
    width: 60px;
    height: 60px;
    object-fit: cover;
}

.provider:hover {
    transform: scale(1.2);
    box-shadow: 0 0 15px #f97316;
}

/* ================= Footer ================= */
footer {
    background: #1e293b;
    padding: 40px 20px;
    margin-top: 30px;
    text-align: center;
}

footer h2 {
    color: #f97316;
    margin-bottom: 15px;
}

footer form {
    max-width: 500px;
    margin: auto;
    text-align: left;
}

footer form div {
    margin-bottom: 15px;
}

footer label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #cbd5e1;
}

footer input, footer textarea {
    width: 100%;
    padding: 10px;
    border-radius: 10px;
    border: none;
    background: #334155;
    color: #f8fafc;
}

footer button {
    padding: 10px 20px;
    border: none;
    border-radius: 20px;
    background: #f97316;
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s;
}

footer button:hover {
    background: #ea580c;
}

/* ================= Responsive ================= */
@media (max-width: 768px) {
    #search-input {
        width: 90%;
    }

    #realtime-search-result {
        width: 90%;
        left: 50%;
        transform: translateX(-50%);
    }

    nav ul {
        flex-direction: column;
        gap: 15px;
    }

    .movie-card img, .card img {
        height: 180px;
    }

    .trailer-iframe {
        height: 250px;
    }
}
