/* --- Base Styles --- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Inter', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background:
        radial-gradient(circle at 8% 10%, rgba(37, 99, 235, 0.08), transparent 35%),
        radial-gradient(circle at 90% 0%, rgba(15, 23, 42, 0.06), transparent 38%),
        #f8fafc;
    color: #0f172a; /* Dark slate/black text */
    line-height: 1.6;
        overflow-x: hidden;
}

    img,
    video,
    iframe,
    svg {
        max-width: 100%;
    }

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6, p, a, li, span, strong {
    overflow-wrap: anywhere;
}

/* --- Colors & Variables --- */
:root {
    --primary-blue: #2563eb;
    --primary-blue-hover: #1d4ed8;
    --dark-bg: #0f172a;
    --text-main: #0f172a;
    --text-muted: #64748b;
    --white: #ffffff;
    --success: #10b981;
    --error: #ef4444;
    --warning: #f59e0b;
}

.text-blue {
    color: var(--primary-blue);
}

/* --- Header / Navbar --- */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(8px);
    padding: 15px 5%;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    z-index: 1000;
}

body.home-floating-header .navbar {
    top: 14px;
    left: 50%;
    transform: translateX(-50%);
    width: min(1220px, calc(100% - 34px));
    border-radius: 18px;
    border: 1px solid rgba(219, 234, 254, 0.8);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.72), rgba(239, 246, 255, 0.6));
    backdrop-filter: blur(12px) saturate(135%);
    -webkit-backdrop-filter: blur(12px) saturate(135%);
    box-shadow:
        0 24px 40px -32px rgba(15, 23, 42, 0.55),
        0 12px 24px -22px rgba(37, 99, 235, 0.5);
    transition: top 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}

body.home-floating-header.navbar-scrolled .navbar {
    top: 8px;
    border-color: rgba(147, 197, 253, 0.85);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.88), rgba(239, 246, 255, 0.82));
    box-shadow:
        0 28px 44px -34px rgba(15, 23, 42, 0.62),
        0 16px 28px -24px rgba(30, 64, 175, 0.58);
}

.logo-area {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo {
    width: 45px;
    height: 45px;
    object-fit: contain;
}

.brand h1 {
    color: var(--dark-bg);
    font-size: 24px;
    font-weight: 800;
    letter-spacing: -0.5px;
}

.motd {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 500;
}

nav {
    display: flex;
    align-items: center;
    gap: 30px;
    margin-left: auto;
}

nav a {
    color: var(--text-main);
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    transition: color 0.2s ease;
}

nav a:hover, nav a.active {
    color: var(--primary-blue);
}

.menu-login-btn {
    border: 1px solid #bfdbfe;
    padding: 8px 14px;
    border-radius: 8px;
    font-weight: 700;
}

.menu-login-btn:hover {
    border-color: #60a5fa;
    background: #eff6ff;
}

.nav-mobile-toggle {
    display: none;
    margin-left: auto;
    border: 1px solid #bfdbfe;
    background: #eff6ff;
    color: var(--primary-blue);
    border-radius: 10px;
    width: 42px;
    height: 42px;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    cursor: pointer;
}

.nav-mobile-toggle:hover {
    background: #dbeafe;
}

.site-user-menu {
    position: relative;
    display: inline-flex;
    align-items: center;
}

.site-user-trigger {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

.site-user-pop {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    min-width: 190px;
    background: #ffffff;
    border: 1px solid #dbe3ee;
    border-radius: 10px;
    box-shadow: 0 20px 30px -24px rgba(15, 23, 42, 0.45);
    overflow: hidden;
    z-index: 1400;
}

.site-user-pop a {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: #0f172a;
    padding: 10px 12px;
    font-size: 0.92rem;
    font-weight: 600;
    border-bottom: 1px solid #edf2f7;
}

.site-user-pop a:last-child {
    border-bottom: none;
    color: #b91c1c;
}

.site-user-pop a:hover {
    background: #f8fafc;
}

/* --- Navigation Dropdown --- */
.nav-item-dropdown {
    position: relative;
    display: flex;
    align-items: center;
}

.nav-item-dropdown > a {
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-submenu {
    display: none;
    position: absolute;
    /* Zet top op 100% in plaats van 120% voor naadloze overgang */
    top: 100%; 
    left: 0;
    background-color: var(--white);
    min-width: 180px;
    box-shadow: 0 10px 25px -5px rgba(0,0,0,0.1);
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    z-index: 10;
    /* Optioneel: voeg padding toe bovenaan het menu voor de overgang */
    padding-top: 10px;
}

.nav-item-dropdown:hover .nav-submenu {
    display: block;
}

.nav-submenu a {
    color: var(--text-main);
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    font-size: 14px;
    border-bottom: 1px solid #f1f5f9;
    transition: background 0.2s;
}

.nav-submenu a:last-child {
    border-bottom: none;
}

.nav-submenu a:hover {
    background-color: #f8fafc;
    color: var(--primary-blue);
}

/* --- Authentication --- */
#login-btn, .btn-primary {
    background-color: var(--primary-blue);
    color: var(--white);
    border: none;
    padding: 10px 24px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 15px;
    text-decoration: none;
    transition: all 0.2s ease;
    box-shadow: 0 4px 6px -1px rgba(37, 99, 235, 0.2);
}

#login-btn:hover, .btn-primary:hover {
    background-color: var(--primary-blue-hover);
    transform: translateY(-1px);
    box-shadow: 0 6px 8px -1px rgba(37, 99, 235, 0.3);
}

.hidden {
    display: none !important;
}

#user-module {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--white);
    padding: 6px 16px 6px 6px;
    border-radius: 30px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
}

.dropdown {
    position: relative;
    cursor: pointer;
    font-weight: 600;
    font-size: 14px;
    color: var(--text-main);
}

.dropdown-content {
    display: none;
    position: absolute;
    right: 0;
    top: 150%;
    background-color: var(--white);
    min-width: 180px;
    box-shadow: 0 10px 25px -5px rgba(0,0,0,0.1);
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    z-index: 10;
}

.dropdown:hover .dropdown-content {
    display: block;
    animation: fadeIn 0.2s ease;
}

.dropdown-content a {
    color: var(--text-main);
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    font-size: 14px;
    border-bottom: 1px solid #f1f5f9;
    transition: background 0.2s;
}

.dropdown-content a:last-child {
    border-bottom: none;
    color: var(--error);
}

.dropdown-content a:hover {
    background-color: #f8fafc;
}

/* --- Site Login Widget --- */
.site-login-modal {
    position: fixed;
    inset: 0;
    background: rgba(2, 6, 23, 0.62);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    z-index: 3000;
}

.site-login-card {
    width: 100%;
    max-width: 420px;
    background: var(--white);
    border: 1px solid #dbeafe;
    border-radius: 16px;
    padding: 22px;
    position: relative;
    box-shadow: 0 30px 48px -26px rgba(2, 6, 23, 0.6);
}

.site-login-close {
    position: absolute;
    top: 8px;
    right: 10px;
    border: none;
    background: transparent;
    font-size: 1.7rem;
    line-height: 1;
    color: #64748b;
    cursor: pointer;
}

.site-login-card h3 {
    color: var(--dark-bg);
    font-size: 1.4rem;
    margin-bottom: 6px;
}

.site-login-card > p {
    color: var(--text-muted);
    margin-bottom: 14px;
}

.site-login-form {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.site-login-form label {
    color: var(--text-main);
    font-weight: 600;
    font-size: 0.92rem;
}

.site-login-form input {
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    padding: 10px 11px;
    font-size: 0.94rem;
    outline: none;
}

.site-login-form input:focus {
    border-color: #60a5fa;
    box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.22);
}

.site-login-forgot {
    color: var(--primary-blue);
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    margin: 4px 0;
}

.site-login-forgot:hover {
    text-decoration: underline;
}

.site-login-feedback {
    border-radius: 10px;
    padding: 10px;
    font-size: 0.92rem;
}

.site-login-feedback.error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

.site-login-feedback.success {
    background: #ecfdf5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.site-login-feedback.pending {
    background: #fffbeb;
    color: #92400e;
    border: 1px solid #fde68a;
}

/* --- Hero Section (Full Screen) --- */
.hero {
    height: 100vh;
    min-height: 600px;
    background: linear-gradient(to right, rgba(15, 23, 42, 0.9) 0%, rgba(15, 23, 42, 0.6) 50%, rgba(15, 23, 42, 0.4) 100%), url('/images/hero-bg.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    padding: 80px 10% 0 10%; /* Top padding accounts for fixed navbar */
}

.hero-content {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 40px;
}

.intro {
    flex: 1;
    min-width: 300px;
    max-width: 600px;
}

.intro h2 {
    font-size: 56px;
    color: var(--white);
    margin-bottom: 20px;
    line-height: 1.1;
    font-weight: 800;
}

.intro p {
    color: #cbd5e1;
    font-size: 18px;
    margin-bottom: 35px;
    font-weight: 400;
}

/* --- Glassmorphism Status Widget --- */
.glass-panel {
background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 30px;
    border-radius: 16px;
    width: 100%;
    max-width: 350px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    color: var(--white);
}

.glass-panel h3 {
    margin-bottom: 20px;
    font-size: 18px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding-bottom: 10px;
}

#server-status-list {
    list-style: none;
}

#server-status-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    font-weight: 500;
    background: rgba(0, 0, 0, 0.2);
    padding: 12px 16px;
    border-radius: 8px;
}

.server-name {
    font-size: 15px;
}

.status-indicator {
    font-size: 14px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 20px;
    background: rgba(255,255,255,0.1);
}

.online { color: var(--success); }
.offline { color: var(--error); }
.checking { color: var(--warning); }

/* --- IP Banner --- */
.ip-banner {
    background-color: var(--primary-blue);
    color: var(--white);
    text-align: center;
    padding: 18px 0;
    cursor: pointer;
    transition: background-color 0.2s ease;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
    position: relative;
    z-index: 10;
}

.ip-banner:hover {
    background-color: var(--primary-blue-hover);
}

.ip-text {
    font-family: monospace;
    font-size: 26px;
    font-weight: 700;
    letter-spacing: 1px;
}

.copy-hint {
    font-size: 13px;
    margin-left: 20px;
    opacity: 0.9;
    font-weight: 600;
    text-transform: uppercase;
    vertical-align: middle;
    background: rgba(255, 255, 255, 0.2);
    padding: 5px 12px;
    border-radius: 20px;
    transition: background 0.2s ease;
}

.ip-banner:hover .copy-hint {
    background: rgba(255, 255, 255, 0.3);
}

/* --- White Content Area --- */
.content-wrapper {
    padding: 80px 10%;
    background:
        linear-gradient(180deg, #ffffff 0%, #f8fbff 52%, #ffffff 100%);
    position: relative;
    overflow: hidden;
}

.content-wrapper::before {
    content: '';
    position: absolute;
    top: -120px;
    right: -120px;
    width: 320px;
    height: 320px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.12), transparent 68%);
    pointer-events: none;
}

.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
    margin-bottom: 80px;
    position: relative;
    z-index: 1;
}

.feature-card {
    background:
        linear-gradient(155deg, #ffffff 0%, #f8fbff 100%);
    padding: 40px 30px;
    border-radius: 16px;
    text-align: center;
    border: 1px solid #dbe7f5;
    box-shadow: 0 18px 34px -24px rgba(15, 23, 42, 0.35);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, #2563eb, #3b82f6);
}

.feature-card:hover {
    transform: translateY(-6px);
    border-color: #bfdbfe;
    box-shadow: 0 24px 46px -26px rgba(37, 99, 235, 0.42);
}

.icon-wrapper {
    font-size: 40px;
    margin-bottom: 20px;
    display: inline-block;
    background: linear-gradient(160deg, #eff6ff, #dbeafe);
    width: 80px;
    height: 80px;
    line-height: 80px;
    border-radius: 50%;
    border: 1px solid #bfdbfe;
}

.feature-card h3 {
    color: var(--dark-bg);
    margin-bottom: 15px;
    font-size: 22px;
    font-weight: 700;
}

.feature-card p {
    color: var(--text-muted);
}

.discord-btn {
    display: flex;
    align-items: center;
    gap: 6px;
}
.discord-btn:hover {
    color: #5865F2 !important;
}
.vote-section {
    background:
        linear-gradient(145deg, #ffffff 0%, #f1f7ff 100%);
    padding: 50px;
    border-radius: 20px;
    border: 1px solid #dbe7f5;
    margin-top: 40px;
    text-align: center;
    position: relative;
    z-index: 1;
    box-shadow: 0 22px 38px -30px rgba(15, 23, 42, 0.35);
}

.home-team-section {
    margin-top: 8px;
    margin-bottom: 42px;
    padding: 34px 30px;
    border: 1px solid #dbe7f5;
    border-radius: 20px;
    background: linear-gradient(145deg, #ffffff 0%, #f5f9ff 100%);
    box-shadow: 0 22px 38px -30px rgba(15, 23, 42, 0.35);
}

.home-team-header {
    text-align: center;
    margin-bottom: 18px;
}

.home-team-header h3 {
    color: var(--dark-bg);
    font-size: 1.85rem;
}

.home-team-header p {
    color: var(--text-muted);
}

.home-team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

.home-team-card {
    border: 1px solid #dbe7f5;
    border-radius: 14px;
    background: #ffffff;
    padding: 18px;
    text-align: center;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.home-team-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 30px -26px rgba(37, 99, 235, 0.45);
}

.home-team-card img {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    margin-bottom: 10px;
    border: 2px solid #e2e8f0;
}

.home-team-card strong {
    display: block;
    font-size: 1rem;
    color: var(--dark-bg);
}

.home-team-card span {
    display: inline-block;
    margin-top: 5px;
    margin-bottom: 8px;
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    color: var(--primary-blue);
    background: #eff6ff;
    border-radius: 999px;
    padding: 4px 10px;
}

.home-team-card p {
    font-size: 0.84rem;
    color: var(--text-muted);
}

.home-team-footer {
    margin-top: 16px;
    text-align: center;
}
.vote-header {
    margin-bottom: 30px;
}
.vote-header h3 {
    font-size: 28px;
    color: var(--dark-bg);
    margin-bottom: 10px;
}
.vote-header p {
    color: var(--text-muted);
}
.vote-cards {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}
.vote-card {
    background: #ffffff;
    border: 1px solid #dbe7f5;
    padding: 25px 40px;
    border-radius: 12px;
    text-decoration: none;
    color: var(--dark-bg);
    transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
    min-width: 250px;
    box-shadow: 0 16px 26px -24px rgba(15, 23, 42, 0.35);
}
.vote-card:hover {
    transform: translateY(-3px);
    border-color: var(--primary-blue);
    box-shadow: 0 20px 34px -22px rgba(37, 99, 235, 0.36);
}
.vote-card i {
    font-size: 28px;
    color: var(--primary-blue);
    margin-bottom: 12px;
}
.vote-card h4 {
    font-size: 18px;
    margin-bottom: 5px;
}
.vote-card span {
    font-size: 14px;
    color: var(--text-muted);
    font-weight: 500;
}

/* --- Footer --- */
footer {
    text-align: center;
    padding: 30px;
    background-color: var(--dark-bg);
    color: #94a3b8;
    font-size: 14px;
}

footer p {
    margin: 4px 0;
}

footer a {
    color: #cbd5e1;
    font-weight: 600;
    text-decoration: none;
}

footer a:hover {
    color: var(--white);
    text-decoration: underline;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Responsive adjustments */
@media (max-width: 900px) {
    body.home-floating-header .navbar {
        top: 8px;
        width: calc(100% - 16px);
        border-radius: 14px;
        padding: 12px 16px;
    }

    body.home-floating-header.navbar-scrolled .navbar {
        top: 4px;
    }

    .content-wrapper {
        padding: 62px 6%;
    }

    .features {
        gap: 18px;
        margin-bottom: 48px;
    }

    .feature-card {
        padding: 28px 20px;
    }

    .vote-section {
        padding: 28px 20px;
    }

    .hero-content {
        flex-direction: column;
        justify-content: center;
        align-items: center;
        text-align: center;
        gap: 26px;
    }

    .intro {
        min-width: 0;
        width: min(100%, 560px);
        max-width: 560px;
        flex: none;
        order: 1;
    }

    .intro p {
        margin-bottom: 24px;
    }

    .status-widget {
        order: 2;
        width: min(100%, 520px);
    }

    .intro h2 {
        font-size: 40px;
    }

    .features {
        grid-template-columns: 1fr;
    }

    .nav-mobile-toggle {
        display: inline-flex;
    }

    .navbar {
        padding: 12px 16px;
    }

    .navbar nav {
        display: none;
        position: absolute;
        left: 0;
        right: 0;
        top: calc(100% + 8px);
        margin-left: 0;
        padding: 10px;
        gap: 6px;
        flex-direction: column;
        background: rgba(255, 255, 255, 0.98);
        border: 1px solid #dbe7f5;
        border-radius: 14px;
        box-shadow: 0 22px 30px -26px rgba(15, 23, 42, 0.5);
        z-index: 1200;
    }

    .navbar.nav-mobile-open nav {
        display: flex;
    }

    .navbar nav > a,
    .navbar nav .menu-login-btn,
    .navbar nav .discord-btn,
    .navbar nav .site-user-trigger {
        width: 100%;
        text-align: left;
        padding: 10px 12px;
        border-radius: 10px;
        border: 1px solid #e2e8f0;
        background: #ffffff;
        justify-content: flex-start;
    }

    .nav-item-dropdown {
        display: block;
        width: 100%;
    }

    .nav-item-dropdown > a {
        display: flex;
        justify-content: space-between;
        width: 100%;
        text-align: left;
        border: 1px solid #e2e8f0;
        border-radius: 10px;
        padding: 10px 12px;
        background: #ffffff;
    }

    .nav-submenu {
        position: static;
        min-width: 0;
        display: none;
        border: 1px solid #e2e8f0;
        border-radius: 10px;
        box-shadow: none;
        margin-top: 6px;
        padding-top: 0;
    }

    .nav-item-dropdown.mobile-open .nav-submenu {
        display: block;
    }

    .site-user-menu {
        width: 100%;
        display: block;
    }

    .site-user-pop {
        position: static;
        margin-top: 6px;
        width: 100%;
        box-shadow: none;
    }
}

@media (max-width: 520px) {
    .hero {
        height: auto;
        min-height: 100vh;
        padding: 124px 6% 44px 6%;
        align-items: flex-start;
    }

    .hero-content {
        justify-content: flex-start;
        gap: 22px;
    }

    .intro h2 {
        font-size: 32px;
        overflow-wrap: normal;
        word-break: normal;
    }

    .intro p {
        font-size: 16px;
        overflow-wrap: normal;
        word-break: normal;
    }

    .glass-panel {
        padding: 22px;
    }

    #server-status-list li {
        padding: 11px 12px;
    }

    .ip-text {
        font-size: 20px;
    }

    .copy-hint {
        display: inline-block;
        margin-left: 10px;
    }
}
