/* ----------------- BASE NAVIGATION ----------------- */
nav {
    width: 100%;
    padding: 0 1.5rem;
    border-top: 3px dashed var(--brand-color);
    border-bottom: 3px dashed var(--brand-color);
    background: transparent;
}

/* Dark mode for nav borders */
body.dark-mode nav {
    border-top-color: #fff;
    border-bottom-color: #fff;
}

/* Nav container (desktop) */
.nav-container {
    display: flex;
    justify-content: center; /* horizontally center menu */
    align-items: center;
}

/* Dark mode container */
body.dark-mode .nav-container {
    color: #fff;
}

/* Nav menu list (desktop) */
nav ul.nav-menu {
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem 1.2rem;
    list-style: none;
    padding: 0;
    margin: 0 auto;
}

/* Nav links */
nav li a {
    display: inline-block;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    text-decoration: none;
    font-size: 1.25rem;
    font-weight: 500;
    color: #333;
    transition: background-color 0.2s ease, color 0.2s ease;
}

/* Hover effect */
nav li a:hover {
    background-color: #f0f0f0;
    color: var(--brand-color);
}

/* Active link */
nav li a.active {
    background-color: #e0e0e0;
    font-weight: 600;
}

/* Dark mode links */
body.dark-mode nav li a {
    color: #fff;
}

body.dark-mode nav li a:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--brand-color);
}

body.dark-mode nav li a.active {
    background-color: rgba(255, 255, 255, 0.2);
    color: var(--brand-color);
}

/* ----------------- MOBILE NAVIGATION ----------------- */
/* Hamburger button (hidden on desktop) */
.openbtn {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0.5rem;
    color: #333;
}

/* Sidebar (hidden by default) */
.sidebar {
    display: none;
    height: 100%;
    width: 0;
    position: fixed;
    z-index: 1000;
    top: 0;
    left: 0;
    background-color: #fff;
    overflow-x: hidden;
    padding-top: 60px;
    transition: width 0.5s;
    box-shadow: 2px 0 5px rgba(0,0,0,0.1);
}

/* Sidebar links */
.sidebar a {
    display: block;
    padding: 8px 32px;
    font-size: 1.2rem;
    color: #333;
    text-decoration: none;
    transition: color 0.3s;
}

.sidebar a:hover {
    color: #000;
}

/* Close button for sidebar */
.closebtn {
    position: absolute;
    top: 0;
    right: 25px;
    font-size: 2rem;
    margin-left: 50px;
    color: #333;
}

/* ----------------- RESPONSIVE ----------------- */
@media (max-width: 768px) {

    /* Hide desktop nav */
    .nav-container {
        display: none;
    }

    /* Show mobile menu button */
    .openbtn {
        display: block;
    }

    /* Show sidebar */
    .sidebar {
        display: block;
    }

    /* Dark mode adjustments */
    body.dark-mode .openbtn {
        color: var(--brand-color);
    }

    body.dark-mode .sidebar {
        background-color: #333;
    }

    body.dark-mode .sidebar a {
        color: #fff;
    }
}


/* Hide hamburger menu by default (desktop) */
#mainNavigationButton {
    display: none;
}

/* Show only on mobile */
@media (max-width: 768px) {
    #mainNavigationButton {
        display: block;
        margin-bottom: 0.5rem; /* optional spacing under button */
    }
}

