
/* ========================================
   1. GOOGLE FONTS
======================================== */

@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;600;700&family=Space+Grotesk:wght@500;700&display=swap');


/* ========================================
   2. ROOT COLORS
======================================== */

:root {
    --y: #F3FF12;
    --bg: #0E2431;
    --panel: #173443;
}


/* ========================================
   3. GLOBAL RESET
======================================== */

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: var(--bg);
    color: white;
    font-family: 'DM Sans', sans-serif;
}


/* ========================================
   4. HEADER & LOGO
======================================== */

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 22px 5%;
    background: #091b25;
    border-bottom: 1px solid #ffffff22;
}

.logo {
    font: 700 24px 'Space Grotesk';
    color: var(--y);
    text-decoration: none;
}


/* ========================================
   5. NAVIGATION
======================================== */

nav {
    display: flex;
    gap: 22px;
}

nav a {
    color: white;
    text-decoration: none;
}


/* ========================================
   6. MAIN CONTENT
======================================== */

main {
    width: min(1120px, 92%);
    margin: auto;
    min-height: 78vh;
    padding: 35px 0;
}


/* ========================================
   7. HEADINGS & TEXT
======================================== */

h1,
h2,
h3 {
    font-family: 'Space Grotesk';
}

h1 {
    font-size: clamp(36px, 6vw, 62px);
}

em,
small {
    color: var(--y);
}


/* ========================================
   8. HERO SECTION
======================================== */

.hero {
    padding: 65px 0;
}

.hero p {
    color: #b7c5cc;
}


/* ========================================
   9. BUTTONS
======================================== */

.btn {
    display: inline-block;
    background: var(--y);
    color: #14232a;
    padding: 12px 18px;
    border: 0;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 700;
    cursor: pointer;
}

.ghost {
    background: transparent;
    color: white;
    border: 1px solid #ffffff66;
}


/* ========================================
   10. MOVIE GRID
======================================== */

.grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
    margin: 22px 0 45px;
}


/* ========================================
   11. MOVIE CARD
======================================== */

.tile {
    background: var(--panel);
    border-radius: 9px;
    overflow: hidden;
    padding-bottom: 14px;
    color: white;
    text-decoration: none;
}

.tile .poster {
    height: 235px;
    background: #203f4e;
}

.poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.placeholder {
    height: 100%;
    display: grid;
    place-items: center;
    color: var(--y);
    font-size: 70px;
}

.tile span,
.tile h3,
.tile small {
    margin: 12px;
    display: block;
}

.tile span {
    font-size: 10px;
    letter-spacing: 2px;
    color: var(--y);
}


/* ========================================
   12. FORM INPUTS
======================================== */

input,
textarea,
select {
    display: block;
    width: 100%;
    padding: 13px;
    margin: 10px 0;
    background: #102d3b;
    color: white;
    border: 1px solid #ffffff33;
    border-radius: 6px;
}


/* ========================================
   13. MOVIE DETAILS
======================================== */

.detail {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 35px;
    align-items: center;
}

.detail img {
    width: 100%;
    border-radius: 10px;
}


/* ========================================
   14. ADMIN PANEL
======================================== */

.admin {
    max-width: 650px;
    margin: 25px auto;
    background: var(--panel);
    padding: 25px;
    border-radius: 10px;
}

.item {
    display: flex;
    justify-content: space-between;
    padding: 10px;
    border-bottom: 1px solid #ffffff22;
}

.item button {
    background: #753640;
    color: white;
    border: 0;
    padding: 7px;
    border-radius: 5px;
}


/* ========================================
   15. ERROR MESSAGE
======================================== */

.error {
    color: #ffaaaa;
}


/* ========================================
   16. FOOTER
======================================== */

footer {
    padding: 25px 5%;
    border-top: 1px solid #ffffff22;
    color: #aabac2;
}


/* ========================================
   17. MOBILE RESPONSIVE DESIGN
======================================== */

@media (max-width: 700px) {

    header {
        align-items: flex-start;
        gap: 15px;
        flex-direction: column;
    }

    nav {
        flex-wrap: wrap;
        gap: 14px;
    }

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

    .tile .poster {
        height: 185px;
    }

    .detail {
        grid-template-columns: 1fr;
    }

    .detail img {
        max-width: 280px;
    }
}
