/* ===== MOBILE MENU ===== */
.mobile-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    background: none;
    border: none;
    cursor: pointer;
}

.mobile-toggle span {
    width: 26px;
    height: 2px;
    background: #111;
}

.mobile-toggle {
    z-index: 10001;
}

.mobile-toggle span {
    transition: .3s ease;
}

.mobile-toggle.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.mobile-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-toggle.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}


.mobile-menu {
    position: fixed;
    top: 0;
    right: 0;
    width: 320px;
    height: 100vh;
    background: #ffffff;
    z-index: 10000;

    transform: translateX(100%);
    transition: transform .35s ease, box-shadow .35s ease;

    box-shadow: none;
    border-left: 1px solid rgba(0,0,0,.06);

    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.mobile-menu.active {
    transform: translateX(0);
    box-shadow: -16px 0 40px rgba(0,0,0,.2);
}


.site-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

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

.mobile-close {
    font-size: 24px;
    background: none;
    border: none;
    cursor: pointer;
}

/* Menu list */
.mobile-menu-list {
    list-style: none;
    padding: 20px;
    margin: 0;
}

.mobile-menu-list li {
    margin-bottom: 12px;
}

.mobile-menu-list a {
    display: block;
    font-size: 16px;
    font-weight: 500;
    color: #111;
    text-decoration: none;
    padding: 10px 0;
}

.mobile-menu-list .sub-menu {
    display: none;
    margin-top: 8px;
    padding-left: 16px;
    border-left: 2px solid #e5e7eb;
}

.mobile-menu-list .sub-menu li {
    border-bottom: none; /* 🔥 không kẻ submenu */
}

.mobile-menu-list > li > a:hover {
    background: #f9fafb;
}

.mobile-menu-list .current-menu-item > a {
    background: #0b3ce3;
    color: #ffffff;
    border-radius: 8px;
}

.mobile-menu-list li.open > .sub-menu {
    display: block;
}

.mobile-menu-list > li {
    margin-bottom: 0;               /* bỏ margin cũ */
    padding: 2px 0;
    border-bottom: 1px solid #e5e7eb;
}

.mobile-menu-list > li > a {
    padding: 14px 10px;
}

/* item cuối không có border */
.mobile-menu-list > li:last-child {
    border-bottom: none;
}

/* Mobile only */
@media (max-width: 1024px) {
    .mobile-toggle {
        display: flex;
        padding: 0;
    }

    #site-navigation {
        display: none;
    }
}
