/* =============================== */
/*  Netflix Font und Base Styles   */
/* =============================== */

@import url('https://fonts.googleapis.com/css2?family=Netflix+Sans:wght@300;400;700;900&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --netflix-red: #e50914;
    --netflix-black: #141414;
    --netflix-dark-gray: #181818;
    --netflix-gray: #2f2f2f;
    --netflix-light-gray: #b3b3b3;
    --netflix-white: #ffffff;
    --netflix-hover: #2a2a2a;
}

body {
    font-family: 'Netflix Sans', 'Segoe UI Emoji', 'Apple Color Emoji', 'Noto Color Emoji', 'Segoe UI Symbol', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    background-color: var(--netflix-black);
    color: var(--netflix-white);
    line-height: 1.4;
    overflow-x: hidden;
}

/* =============================== */
/*            NEW HEADER           */
/* =============================== */

.main-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #000;
    padding: 12px 25px;
    border-bottom: 1px solid #222;
    z-index: 999;
    position: relative;
}

/* LOGO LINKS */
.header-left .logo {
    display: flex;
    align-items: center;
    gap: 8px;
}

.logo-text {
    color: var(--netflix-red);
    font-size: 24px;
    font-weight: bold;
}

.logo-icon {
    font-size: 28px;
}

/* NAVIGATION + SUCHE MITTE */
.header-center {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.nav-menu {
    display: flex;
    gap: 20px;
}

.nav-menu a {
    color: #eee;
    text-decoration: none;
    font-size: 17px;
    transition: .2s;
}

.nav-menu a:hover {
    color: var(--netflix-red);
}

.search-box {
    display: flex;
    justify-content: center;
    width: 100%;
}

.search-form {
    display: flex;
    gap: 5px;
}

.search-form input {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    padding: 8px 12px;
    color: var(--netflix-white);
    font-size: 14px;
    width: 200px;
    transition: all 0.3s;
}

.search-form input:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.15);
    border-color: var(--netflix-white);
    width: 250px;
}

.search-btn {
    background: var(--netflix-red);
    display: block;
    border: none;
    border-radius: 4px;
    padding: 8px 12px;
    color: var(--netflix-white);
    cursor: pointer;
    transition: .2s;
}

.search-btn:hover {
    background: #f40612;
}

/* PROFILE RECHTS */
.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.profile-switcher {
    display: flex;
    gap: 12px;
}

.profile-avatar .avatar-img {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--netflix-red);
    color: var(--netflix-white);
    font-weight: bold;
    font-size: 18px;
    border: 2px solid transparent;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: transform .2s, border-color .2s;
    text-decoration: none;
}

.profile-avatar.active .avatar-img {
    border-color: var(--netflix-white);
}

.profile-avatar:hover .avatar-img {
    transform: scale(1.1);
}

.logout-btn {
    background: transparent;
    border: 1px solid var(--netflix-white);
    color: var(--netflix-white);
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 14px;
    text-decoration: none;
    transition: .2s;
}

.logout-btn:hover {
    background: var(--netflix-white);
    color: var(--netflix-black);
}

/* =============================== */
/*           HERO BANNER           */
/* =============================== */

.hero-banner {
    background: linear-gradient(135deg, #e50914 0%, #221f1f 100%);
    height: 65vh;
    display: flex;
    align-items: center;
    position: relative;
    margin-top: 0px;
}

.hero-content {
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 40px;
}

.hero-title {
    font-size: 3.2em;
    font-weight: 900;
    margin-bottom: 20px;
}

.hero-subtitle {
    font-size: 1.4em;
    color: var(--netflix-light-gray);
}

.hero-stats {
    display: flex;
    gap: 40px;
    margin-top: 30px;
}

.stat-number {
    font-size: 2.5em;
    font-weight: bold;
}

.stat-label {
    text-transform: uppercase;
    font-size: .9em;
    color: var(--netflix-light-gray);
}

/* =============================== */
/*           POSTER GRID           */
/* =============================== */

.poster-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 25px;
    margin: 40px auto;
    padding: 0 40px;
    max-width: 1600px;
}

.poster-item {
    background: var(--netflix-dark-gray);
    border-radius: 8px;
    overflow: hidden;
    transition: .3s;
    position: relative;
    aspect-ratio: 2/3;
}

.poster-item:hover {
    transform: scale(1.05);
    z-index: 50;
}

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

/* Poster Overlay */
.poster-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.9) 100%);
    opacity: 0;
    transition: .3s;
    display: flex;
    align-items: flex-end;
    padding: 20px;
}

.poster-item:hover .poster-overlay {
    opacity: 1;
}

/* =============================== */
/*           FOOTER                */
/* =============================== */

.netflix-footer {
    background: var(--netflix-dark-gray);
    padding: 40px 0 20px;
    margin-top: 80px;
    border-top: 1px solid var(--netflix-gray);
}

.footer-content {
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 40px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    font-size: .8em;
    color: var(--netflix-light-gray);
}

.episode-stepper {
    display: flex;
    align-items: center;
    background: #000;
    border: 1px solid #333;
    border-radius: 6px;
    overflow: hidden;
}

.episode-input-small {
    width: 55px;
    text-align: center;
    background: #000;
    color: #fff;
    border: none;
    font-size: 14px;
    padding: 6px 0;
}

.stepper-btn {
    width: 32px;
    height: 32px;
    background: #111;
    border: none;
    color: #fff;
    font-size: 20px;
    cursor: pointer;
    line-height: 0;
    transition: 0.2s;
}

.stepper-btn:hover {
    background: #e50914;
}


.btn-save {
    background: #0f9d58;
    color: white;
    border: none;
    padding: 8px 14px;
    border-radius: 6px;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: .5px;
    cursor: pointer;
    transition: .2s;
}

.btn-save:hover {
    background: #12b368;
    transform: translateY(-2px);
}

.btn-delete {
    background: rgba(229, 9, 20, 0.15);
    color: #e50914;
    border: 1px solid #e50914;
    padding: 8px 14px;
    border-radius: 6px;
    font-size: 13px;
    cursor: pointer;
    transition: .2s;
    text-transform: uppercase;
    letter-spacing: .5px;
}

.btn-delete:hover {
    background: rgba(229, 9, 20, 0.35);
    transform: translateY(-2px);
}

/* =============================== */
/*       RESPONSIVE DESIGN         */
/* =============================== */

/* ---------- Tablet (max-width: 1024px) ---------- */

/* Social Features - Shared Badge */
.mutual-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(229, 9, 20, 0.95);
    color: white;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 900;
    display: flex;
    align-items: center;
    gap: 5px;
    z-index: 10;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    pointer-events: none;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.badge-icon {
    font-size: 14px;
}

/* Leaderboard Link */
.leader-link {
    color: white;
    text-decoration: none;
    transition: 0.2s;
}

.leader-link:hover {
    color: var(--netflix-red);
    text-decoration: underline;
}

@media screen and (max-width: 1024px) {
    .hero-banner {
        height: 50vh;
    }

    .hero-title {
        font-size: 2.5em;
    }

    .poster-grid {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
        gap: 20px;
        padding: 0 25px;
    }
}

/* ---------- Mobile (max-width: 768px) ---------- */
@media screen and (max-width: 768px) {
    .main-header {
        flex-direction: column;
        padding: 15px;
        gap: 15px;
    }

    .header-center {
        width: 100%;
    }

    .nav-menu {
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px 15px;
    }

    .nav-menu a {
        font-size: 15px;
    }

    .search-box {
        width: 100%;
    }

    .search-form {
        width: 100%;
        justify-content: center;
    }

    .search-form input {
        flex-grow: 1;
        width: auto;
        min-width: 0;
    }

    .search-form input:focus {
        width: auto;
        flex-grow: 1;
    }

    .header-right {
        width: 100%;
        justify-content: center;
        border-top: 1px solid #222;
        padding-top: 10px;
    }

    .hero-banner {
        height: auto;
        min-height: 40vh;
        padding: 60px 0;
    }

    .hero-content {
        padding: 0 20px;
        text-align: center;
    }

    .hero-title {
        font-size: 1.8em;
    }

    .hero-subtitle {
        font-size: 1.1em;
    }

    .hero-stats {
        justify-content: center;
        gap: 25px;
        flex-wrap: wrap;
    }

    .stat-number {
        font-size: 1.8em;
    }

    .poster-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 15px;
        padding: 0 15px;
        margin: 25px auto;
    }

    .poster-overlay {
        padding: 10px;
    }

    .overlay-title {
        font-size: 0.9em;
    }

    .overlay-actions {
        flex-direction: column;
        gap: 8px;
    }

    .episode-stepper {
        width: 100%;
    }

    .btn-save,
    .btn-delete {
        width: 100%;
        padding: 6px 10px;
        font-size: 12px;
    }

    .footer-content {
        padding: 0 20px;
        grid-template-columns: 1fr;
        text-align: center;
        gap: 20px;
    }

    /* Auth Forms Responsiveness */
    .login-container,
    .register-container,
    .auth-container {
        padding: 30px 20px;
        margin: 20px;
        max-width: calc(100% - 40px);
    }
}

/* ---------- Small Mobile (max-width: 480px) ---------- */
@media screen and (max-width: 480px) {
    .header-left .logo {
        justify-content: center;
    }

    .logo-text {
        font-size: 20px;
    }

    .hero-title {
        font-size: 1.5em;
    }
}
/* Series Interactions */
.poster-rating {
    position: absolute;
    bottom: 8px;
    left: 8px;
    background: rgba(0, 0, 0, 0.75);
    color: #ffc107;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: bold;
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 193, 7, 0.3);
    z-index: 5;
    pointer-events: none;
}

.overlay-community {
    margin-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 10px;
}

.community-link {
    color: var(--netflix-red);
    text-decoration: none;
    font-weight: bold;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: 0.2s;
}

.community-link:hover {
    transform: translateX(5px);
    text-decoration: underline;
}
