nav, div, body, header, h1, h2, h3, ul, li {
    margin: 0;
    padding: 0;
}

.navbar {
    position: relative;
    height: 50px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: nowrap;
    max-width: 90%; 
    margin-inline: auto;
    padding: 8px 16px;
}

.navbar-section {
    background-color: #ffffff00;
}

.nav-list {
    list-style: none;
    display: flex;
}

.nav-link {
    color: #222222;
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 14px;
    text-decoration: none;
    text-transform: uppercase;
    margin: 5px 20px;
    padding: 5px 5px;
    position: relative;
}

.nav-link:hover {
    color: #222222;
}

.nav-link::before {
    content: "";
    display: block;
    height: 2px;
    width: 0;
    background-color: #367faa;
    transition: width 0.3s ease;
    position: absolute;
    bottom: 0;
    left: 0;
}

.nav-link:hover::before {
    width: 100%;
}



/* Larger screens (min-width: 769px) */

@media only screen and (width >= 768px) {
    .navbar-toggle {
        display: none;
    }

    .navbar-right {
        display: flex;
        position: static;
        background-color: transparent;
        box-shadow: none;
        border-radius: 0;
        z-index: 1;
    }

    .navbar-section.active .navbar-right {
        display: flex;
    }

}



/* Smaller/Medium screens (max-width: 768px) */

@media only screen and (width <= 768px) {
    .navbar {
        flex-direction: row;
        align-items: flex-start;
    }

    .navbar-left,
    .navbar-middle,
    .navbar-right {
        text-align: center;
    }

    .nav-list {
        flex-direction: column;
    }

    .nav-link {
        margin: 0;
        padding: 10px;
        position: relative;
    }

    .navbar-toggle {
        display: block;
        cursor: pointer;
        font-size: 24px;
        margin: 0px 0px 0px 0px;
    }

    .navbar-toggle:hover {
        color: #367faa;
    }

    .navbar-right {
        display: none;
        position: absolute;
        top: 50px; /* Adjust this value based on your navbar height */
        left: 0;
        width: 100%;
        background-color: #fff;
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.33);
        border-radius: 10px;
        z-index: 11;
    }

    .navbar-section.active .navbar-right {
        display: block;
    }

    .nav-link::before {
        content: "";
        position: absolute;
        bottom: 0;
        left: 50%;
        transform: translateX(-50%);
        width: 0;
        height: 2px;
        background-color: #367faa;
        transition: width 0.3s ease-in-out;
    }

    .nav-link:hover::before {
        width: 100%;
    }

    /* Subtle line between items */
    .nav-link:not(:last-child)::after {
        content: "";
        display: block;
        height: 1px;
        width: 100%;
        background-color: #ccc;
        position: absolute;
        bottom: 0;
        left: 0;
    }
}