/* Header Menu Scroll */
.hms-wrap,
.hms-wrap * { box-sizing: border-box; }

.hms-wrap {
    width: 100%;
    background: var(--hms-bg);
    border-bottom: 3px solid var(--hms-border);
    position: relative;
    z-index: 999;
    color: var(--hms-text);
}

.hms-wrap.hms-sticky-desktop {
    position: sticky;
    top: 0;
}

.hms-scroll {
    width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: var(--hms-hover) transparent;
}

.hms-scroll::-webkit-scrollbar { height: 4px; }
.hms-scroll::-webkit-scrollbar-track { background: transparent; }
.hms-scroll::-webkit-scrollbar-thumb { background: var(--hms-hover); border-radius: 10px; }

.hms-inner {
    width: min(100%, var(--hms-width));
    min-height: var(--hms-height);
    margin: 0 auto;
    display: flex;
    align-items: stretch;
    white-space: nowrap;
}

.hms-menu {
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
    display: flex !important;
    align-items: stretch;
    gap: var(--hms-gap);
    width: max-content;
    min-width: max-content;
}

.hms-menu > li,
.hms-home {
    position: relative;
    display: flex;
    align-items: center;
    min-height: var(--hms-height);
}

.hms-menu > li > a,
.hms-home {
    display: flex;
    align-items: center;
    min-height: var(--hms-height);
    padding: 0 16px;
    color: var(--hms-text) !important;
    font-size: var(--hms-font);
    font-weight: var(--hms-weight);
    line-height: 1.2;
    text-decoration: none !important;
    transition: background-color .2s ease, color .2s ease;
}

.hms-menu > li:hover > a,
.hms-menu > li.current-menu-item > a,
.hms-menu > li.current-menu-ancestor > a,
.hms-home:hover {
    background: var(--hms-hover) !important;
    color: var(--hms-hover-text) !important;
}

.hms-menu > li.current-menu-item > a,
.hms-menu > li.current-menu-ancestor > a {
    box-shadow: inset 0 -3px 0 var(--hms-active);
}

.hms-menu .sub-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 200px;
    margin: 0 !important;
    padding: 6px 0 !important;
    list-style: none !important;
    background: var(--hms-bg);
    border: 1px solid rgba(255,255,255,.12);
    box-shadow: 0 8px 25px rgba(0,0,0,.2);
    white-space: normal;
}

.hms-menu li:hover > .sub-menu,
.hms-menu li:focus-within > .sub-menu {
    display: block;
}

.hms-menu .sub-menu a {
    display: block;
    padding: 10px 14px;
    color: var(--hms-text) !important;
    text-decoration: none !important;
}

.hms-menu .sub-menu a:hover {
    background: var(--hms-hover) !important;
    color: var(--hms-hover-text) !important;
}

.hms-empty {
    display: flex;
    align-items: center;
    min-height: var(--hms-height);
    padding: 0 15px;
    color: var(--hms-text);
    opacity: .85;
    font-size: 14px;
}

.hms-shadow { box-shadow: 0 2px 10px rgba(0,0,0,.12); }

@media (max-width: 767px) {
    .hms-wrap.hms-sticky-desktop { position: relative; }
    .hms-wrap.hms-sticky-mobile {
        position: sticky;
        top: 0;
    }

    .hms-inner {
        width: max-content;
        min-width: 100%;
        min-height: var(--hms-mobile-height);
    }

    .hms-menu > li,
    .hms-home,
    .hms-menu > li > a {
        min-height: var(--hms-mobile-height);
    }

    .hms-menu > li > a,
    .hms-home {
        padding: 0 13px;
        font-size: var(--hms-mobile-font);
    }

    .hms-menu .sub-menu {
        position: fixed;
        left: 0;
        right: 0;
        top: var(--hms-mobile-height);
        width: 100%;
    }
}

@media (max-width: 420px) {
    .hms-menu > li > a,
    .hms-home {
        padding-left: 11px;
        padding-right: 11px;
    }
}
