/* --- MOBILE MENU (POPUP SIDEBAR) --- */
.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    visibility: hidden;
    opacity: 0;
    transition: all 0.3s ease;
}

.mobile-menu-overlay.active {
    visibility: visible;
    opacity: 1;
}

.mobile-menu-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(3px);
}

.mobile-menu-panel {
    position: absolute;
    top: 0;
    left: -300px; /* Start off-screen */
    width: 280px;
    height: 100%;
    background: #fff;
    box-shadow: 5px 0 25px rgba(0,0,0,0.2);
    transition: all 0.4s cubic-bezier(0.77, 0, 0.175, 1);
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.mobile-menu-overlay.active .mobile-menu-panel {
    left: 0; /* Slide in */
}

.mobile-menu-header {
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #f0f0f0;
}

.mobile-logo-img {
    max-height: 40px;
}

.mobile-close-btn {
    font-size: 28px;
    color: #333;
    cursor: pointer;
    line-height: 1;
}

.mobile-menu-items {
    padding: 20px 0;
}

.mobile-link {
    display: block;
    padding: 12px 25px;
    font-size: 15px;
    font-weight: 500;
    color: #333;
    border-bottom: 1px solid #f9f9f9;
    transition: 0.2s;
}

.mobile-link:hover {
    background-color: #f8f9fa;
    color: var(--primary-color);
    padding-left: 30px;
}

.mobile-link i {
    width: 20px;
    text-align: center;
    margin-right: 10px;
    color: var(--primary-color);
}

/* Submenu in mobile */
.mobile-submenu-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.mobile-submenu {
    display: none;
    background-color: #fcfcfc;
    padding: 10px 0;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
}

.mobile-submenu a {
    padding: 10px 25px 10px 45px; /* Indent */
    font-size: 14px;
    color: #666;
    display: block;
}

.mobile-submenu a:hover {
    color: var(--primary-color);
}

/* Mobile Toggle Button (Visible only on mobile) */
@media (max-width: 991px) {
    .nav-container { display: none; } /* Hide Desktop Nav */
    .mobile-menu-toggle { display: block; } /* Show Toggle */
    .hide-on-mobile { display: none !important; }
}
