/* Modal container */
.mega-menu-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    background-color: rgba(0, 0, 0, 0.5);
}

/* Modal content box */
.mega-menu-modal-content {
    background-color: #fefefe;
    margin: 5% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-height: 80vh;
    overflow-y: auto;
}

/* Close button */
.close-mega-menu-button {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

.close-mega-menu-button:hover,
.close-mega-menu-button:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}

.mega-menu-search-box {
    padding: 10px;
    margin-bottom: 10px;
}

#mega-menu-search {
    width: 100%;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.mega-menu ul {
    list-style-type: none;
    margin: 0;
    padding: 0;
}

.mega-menu li a{
    display: block;
}

.mega-menu-container ul.mega-menu {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    padding: 0;
    margin: 0;
    list-style-type: none;
}

.mega-menu-container ul.mega-menu li a{
    background-color: #f0f0f0;
    padding: 10px;
    border: 1px solid #ddd;
    text-align: center;
    text-decoration: none;
}

/* Adjust grid layout for smaller screens */
@media (max-width: 600px) {
    .mega-menu-container ul.mega-menu {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    }
}

#custom-top-bar {
    background-color: #3eab4d;
}

a.open-mega-menu {
    color: white;
}

#custom-top-bar .container {
    display: flex;
    justify-content: end; /* Ensure space between content and button */
    align-items: center;
}