/* ==========================================================================
   GLOBAL RESET & VARIABLES
   ========================================================================== */
*, *::before, *::after {
    box-sizing: border-box;
}

:root {
    --bg: #06070b;
    --bg2: #0d0e14;
    --border: rgba(148, 163, 184, 0.12);
    --border2: rgba(148, 163, 184, 0.16);
    --text: #f8fafc;
    --muted: #9ca3af;
    --blue-line: #12b8ff;
    --nav-height: 80px;
}

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

/* ==========================================================================
   NAVBAR (FIXED)
   ========================================================================== */
.site-nav {
    display: flex;
    align-items: center;
    height: var(--nav-height);
    padding: 0 12px;
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(6, 7, 11, 0.75);
    border-bottom: 1px solid rgba(18, 184, 255, 0.1);
    backdrop-filter: blur(24px);
}

.site-logo-img {
    max-height: 32px;
    width: auto;
    display: block;
}

.site-nav-links {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}

.site-nav-links a {
    color: #94a3b8;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    padding: 0 7px;
    height: var(--nav-height);
    display: flex;
    align-items: center;
    position: relative;
    text-decoration: none;
    white-space: nowrap;
}

.site-nav-links a.active::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 3px;
    background: var(--blue-line);
}

/* ==========================================================================
   SEARCH & SUGGESTIONS (STRICT LIMITS)
   ========================================================================== */
.site-search-form {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: auto;
    position: relative;
}

.site-search-input {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 4px;
    color: #fff;
    padding: 6px 12px;
    width: 180px;
}

.site-search-button {
    background: #12b8ff;
    border: none;
    border-radius: 4px;
    color: #fff;
    cursor: pointer;
    font-size: 12px;
    font-weight: 700;
    padding: 6px 14px;
    white-space: nowrap;
}

.site-search-button:hover {
    background: #38c8ff;
}


/* The Box */
.site-suggestions {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 300px !important;
    background: #0d0e14 !important;
    border: 1px solid rgba(18, 184, 255, 0.3);
    border-radius: 6px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.9);
    z-index: 1100;
    overflow: hidden;
}

/* The Item Row */
.site-suggestion {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    background: #0d0e14 !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

/* The Image - Forced Small */
.site-suggestion img {
    width: 40px !important;
    height: 55px !important;
    min-width: 40px !important;
    object-fit: cover !important;
    border-radius: 3px;
}

.site-suggestion-title {
    font-size: 13px;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ==========================================================================
   LOGIN / REGISTER CARD (PROPER CENTERING)
   ========================================================================== */
.account-page {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    min-height: calc(100vh - var(--nav-height));
    padding: 0;
}

.account-card {
    background: #0d0e14;
    border: 1px solid var(--border2);
    border-radius: 12px;
    width: 100%;
    max-width: 420px;
    padding: 40px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
}

.account-card h1 {
    font-size: 28px;
    margin: 0 0 15px 0;
    font-weight: 800;
}

.account-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.account-form label {
    display: flex;
    flex-direction: column;
    gap: 5px;
    font-size: 12px;
    font-weight: 700;
    color: var(--muted);
}

.account-form input {
    background: #06070b;
    border: 1px solid var(--border2);
    border-radius: 6px;
    color: #fff;
    padding: 12px;
    width: 100%;
}

.account-button {
    background: var(--blue-line);
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 14px;
    font-weight: 800;
    cursor: pointer;
    margin-top: 10px;
}

/* ==========================================================================
   FIXES FOR MISC ISSUES
   ========================================================================== */
/* Hide menu toggle on desktop */
.site-menu-toggle {
    display: none;
}

@media (max-width: 760px) {
    /* Nav becomes two rows on mobile */
    .site-nav {
        flex-wrap: wrap;
        height: auto;
        padding: 8px 14px;
        gap: 8px;
    }

    .site-nav-slash {
        display: none !important;
    }

    /* Row 1: logo on left, menu button on right */
    .site-logo {
        flex: 1;
    }

    .site-menu-toggle {
        display: flex;
        align-items: center;
        gap: 6px;
        background: rgba(18, 184, 255, 0.12);
        border: 1px solid rgba(18, 184, 255, 0.35);
        border-radius: 6px;
        color: #fff;
        cursor: pointer;
        font-size: 12px;
        font-weight: 700;
        letter-spacing: 0.05em;
        padding: 7px 12px;
        text-transform: uppercase;
        flex-shrink: 0;
    }

    .site-menu-toggle:hover {
        background: rgba(18, 184, 255, 0.22);
    }

    .site-menu-icon {
        display: block;
        width: 16px;
        height: 2px;
        background: #12b8ff;
        position: relative;
    }

    .site-menu-icon::before,
    .site-menu-icon::after {
        content: '';
        position: absolute;
        left: 0;
        width: 100%;
        height: 2px;
        background: #12b8ff;
    }

    .site-menu-icon::before { top: -5px; }
    .site-menu-icon::after  { top: 5px; }

    /* Row 2: search form full width */
    .site-search-form {
        order: 99;
        width: 100%;
        flex: none;
        margin: 0;
        max-width: none;
    }

    .site-search-input {
        flex: 1;
        min-width: 0;
        width: 100%;
    }

    .site-search-button {
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 6px 12px;
        white-space: nowrap;
    }

    /* Nav links hidden by default, dropdown when open */
    .site-nav-links {
        display: none !important;
    }

    .site-nav.menu-open .site-nav-links {
        display: flex !important;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(6, 7, 11, 0.97);
        border-bottom: 1px solid rgba(18, 184, 255, 0.1);
        z-index: 999;
        padding: 8px 0;
    }

    .site-nav.menu-open .site-nav-links a {
        height: auto;
        padding: 12px 20px;
        border-bottom: 1px solid rgba(255,255,255,0.05);
    }
}



.site-nav-links a::


/* ==========================================================================
   ACCOUNT PAGE - COMPLETE STYLES (MODERN + CLASSIC)
   ========================================================================== */

.account-page {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    min-height: calc(100vh - var(--nav-height));
    padding: 40px 20px 60px;
}

.account-card-wide {
    max-width: 640px !important;
}

.account-head {
    margin-bottom: 20px;
}

.account-head h1 {
    font-size: 28px;
    font-weight: 800;
    margin: 4px 0 6px;
    color: #f8fafc;
}

.account-head p {
    color: var(--muted);
    font-size: 14px;
    margin: 0;
}

.account-kicker {
    color: #12b8ff;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.account-alert {
    background: rgba(239, 68, 68, 0.12);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 8px;
    color: #fca5a5;
    font-size: 14px;
    padding: 10px 14px;
    margin-bottom: 16px;
}

.account-alert.success {
    background: rgba(34, 197, 94, 0.12);
    border-color: rgba(34, 197, 94, 0.3);
    color: #86efac;
}

.account-stats {
    display: flex;
    gap: 12px;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.account-stats a {
    background: rgba(18, 184, 255, 0.08);
    border: 1px solid rgba(18, 184, 255, 0.18);
    border-radius: 10px;
    color: #f8fafc;
    flex: 1;
    min-width: 80px;
    padding: 16px 12px;
    text-align: center;
    text-decoration: none;
    transition: background 0.15s;
}

.account-stats a:hover {
    background: rgba(18, 184, 255, 0.14);
}

.account-stats strong {
    display: block;
    font-size: 26px;
    font-weight: 800;
    color: #12b8ff;
    line-height: 1;
    margin-bottom: 4px;
}

.account-stats span {
    font-size: 11px;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 600;
}

.account-section {
    border-top: 1px solid var(--border2);
    margin-top: 24px;
    padding-top: 20px;
}

.account-section-title {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--muted);
    margin: 0 0 14px;
}

.account-button {
    background: #12b8ff;
    border: none;
    border-radius: 8px;
    color: #fff;
    cursor: pointer;
    display: inline-block;
    font-size: 14px;
    font-weight: 700;
    padding: 11px 20px;
    text-decoration: none;
    transition: background 0.15s;
    margin-top: 0;
}

.account-button:hover {
    background: #38c8ff;
}

.account-button.muted {
    background: rgba(148, 163, 184, 0.12);
    border: 1px solid rgba(148, 163, 184, 0.2);
    color: var(--muted);
}

.account-button.muted:hover {
    background: rgba(148, 163, 184, 0.2);
}

.account-link-button {
    background: rgba(18, 184, 255, 0.1);
    border: 1px solid rgba(18, 184, 255, 0.25);
    border-radius: 8px;
    color: #12b8ff;
    cursor: pointer;
    font-size: 14px;
    font-weight: 700;
    padding: 10px 18px;
    text-decoration: none;
    display: inline-block;
    transition: background 0.15s;
}

.account-link-button:hover {
    background: rgba(18, 184, 255, 0.18);
}

.account-link-button.muted {
    background: transparent;
    border-color: rgba(148, 163, 184, 0.2);
    color: var(--muted);
}

.account-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
    margin-top: 28px;
    padding-top: 20px;
    border-top: 1px solid var(--border2);
}

.account-mal-linked {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
    flex-wrap: wrap;
}

.account-mal-badge {
    background: rgba(18, 184, 255, 0.12);
    border: 1px solid rgba(18, 184, 255, 0.3);
    border-radius: 6px;
    color: #f8fafc;
    font-size: 14px;
    padding: 6px 12px;
}

.account-mal-date {
    color: var(--muted);
    font-size: 13px;
}

.account-mal-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.account-import-status {
    font-size: 13px;
    color: var(--muted);
    margin-top: 8px;
    min-height: 18px;
}

.account-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.account-form label {
    display: flex;
    flex-direction: column;
    gap: 5px;
    font-size: 12px;
    font-weight: 700;
    color: var(--muted);
}

.account-form input[type="file"],
.account-form input[type="text"],
.account-form input[type="email"],
.account-form input[type="password"] {
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border2);
    border-radius: 6px;
    color: #fff;
    font-size: 14px;
    padding: 10px 12px;
    width: 100%;
}

.account-note {
    color: var(--muted);
    font-size: 13px;
    margin-top: 14px;
}

.account-note a {
    color: #12b8ff;
}

/* ==========================================================================
   WATCHLIST IMPROVEMENTS
   ========================================================================== */
.watchlist-poster-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(18,184,255,0.15), rgba(18,184,255,0.05));
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
}

.watchlist-poster-placeholder span {
    color: rgba(18,184,255,0.6);
    font-size: 22px;
    font-weight: 800;
    text-transform: uppercase;
}

.watchlist-filters a.active,
.watchlist-filters a:hover {
    color: #f8fafc;
    border-color: rgba(18,184,255,0.4);
    background: rgba(18,184,255,0.14);
}

.watchlist-item:hover .watchlist-poster {
    opacity: 0.85;
}

.watchlist-poster {
    transition: opacity 0.15s;
}

/* Login/Register page centering */
.account-page .account-card {
    margin: 0 auto;
}
/* Watchlist grid */
.watchlist-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 14px;
}
.watchlist-item {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.watchlist-poster {
    display: block;
    aspect-ratio: 2/3;
    overflow: hidden;
    border-radius: 6px;
    background: #111824;
}
.watchlist-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.watchlist-title {
    color: #f8fafc;
    font-size: 12px;
    font-weight: 600;
    text-decoration: none;
    line-height: 1.3;
    display: block;
}
.watchlist-title:hover { color: #12b8ff; }
.watchlist-meta {
    color: #9ca3af;
    font-size: 11px;
}
.watchlist-progress {
    background: rgba(148,163,184,0.15);
    border-radius: 999px;
    height: 3px;
    overflow: hidden;
    margin-top: 3px;
}
.watchlist-progress span {
    display: block;
    height: 100%;
    background: #12b8ff;
}
.watchlist-filters {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}
.watchlist-filters a {
    background: rgba(18,184,255,0.08);
    border: 1px solid rgba(18,184,255,0.18);
    border-radius: 6px;
    color: #9ca3af;
    font-size: 13px;
    font-weight: 600;
    padding: 6px 14px;
    text-decoration: none;
}
.watchlist-filters a:hover { color: #f8fafc; background: rgba(18,184,255,0.14); }
.watchlist-empty { color: #9ca3af; font-size: 14px; text-align: center; padding: 40px 0; }
EOF ; echo "WinSCP: this is end-of-file:$?"

.watchlist-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(120px,1fr));gap:14px;}
.watchlist-item{display:flex;flex-direction:column;gap:6px;}
.watchlist-title{color:#f8fafc;font-size:12px;font-weight:600;text-decoration:none;line-height:1.3;display:block;}
.watchlist-title:hover{color:#12b8ff;}
.watchlist-meta{color:#9ca3af;font-size:11px;}
.watchlist-filters{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:20px;}
.watchlist-filters a{background:rgba(18,184,255,0.08);border:1px solid rgba(18,184,255,0.18);border-radius:6px;color:#9ca3af;font-size:13px;font-weight:600;padding:6px 14px;text-decoration:none;}
.watchlist-filters a:hover{color:#f8fafc;background:rgba(18,184,255,0.14);}
@media (max-width:600px){.auth-layout{grid-template-columns:1fr !important;padding:0 12px 40px;margin:16px auto;}.auth-sidebar{display:none !important;}.watchlist-grid{grid-template-columns:repeat(auto-fill,minmax(100px,1fr));gap:10px;}.watchlist-title{font-size:11px;}.account-stats{gap:8px;}.account-stats a,.account-stats div{padding:12px 8px;}.account-stats strong{font-size:20px;}.watchlist-filters a{font-size:11px;padding:5px 10px;}.account-card{padding:20px 16px;}}
@media (max-width:400px){.watchlist-grid{grid-template-columns:repeat(3,1fr);}}
@media (max-width:600px){.auth-layout{grid-template-columns:1fr !important;padding:0 12px 40px;margin:16px auto;}.auth-sidebar{display:none !important;}.watchlist-grid{grid-template-columns:repeat(auto-fill,minmax(100px,1fr));gap:10px;}.watchlist-title{font-size:11px;}.account-stats{gap:8px;}.account-stats a,.account-stats div{padding:12px 8px;}.account-stats strong{font-size:20px;}.watchlist-filters a{font-size:11px;padding:5px 10px;}.account-card{padding:20px 16px;}}
@media (max-width:400px){.watchlist-grid{grid-template-columns:repeat(3,1fr);}}