.header {
    position: fixed;
    top: 0;
    width: 100%;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    background-color: var(--oxford);
}

.header__container {
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    box-sizing: border-box;
}

.header__brand a {
    display: flex;
    align-items: center;
}

.header__logo--mobile,
.menu-item-has-children.is-open>.sub-menu-desktop {
    display: block;
}

.header__nav,
.header__logo--desktop {
    display: none;
}

.header__nav-list {
    width: 100%;
    display: flex;
    align-items: center;
    list-style: none;
    padding: 0;
    margin: 0;
    gap: 12px;
    justify-content: space-between;
}

.header__nav-link {
    background: transparent;
    color: white;
    text-decoration: none;
    font-weight: 700;
    padding: 8px;
    border: none;
    border-radius: 4px;
    transition: background-color 0.2s, color 0.2s;
    display: flex;
    align-items: center;
    gap: 5px;
}

.cart-desktop,
.mobile-cart,
.header__menu-toggle,
.search-toggle,
.close-menu-btn,
.header__nav-close,
.header__action-btn {
    padding: 0 8px;
}


.header__nav-link:not(.tutor-btn):hover,
.header__nav-link:not(.tutor-btn):hover,
.sub-menu-desktop-container a:hover,
.sub-menu-mobile a:hover,
.dropdown-item:hover,
.cart-desktop:hover,
.mobile-cart:hover,
.search-toggle:hover,
.header__menu-toggle:hover,
.close-menu-btn:hover,
.header__nav-close:hover,
.header__action-btn:hover,
footer .social-media:hover {
    background: rgba(0, 172, 172, 0.33);
    border-radius: 4px;
}

.cart-item-count {
    background: red;
    color: white;
    border-radius: 50%;
    padding: 2px 6px;
    font-size: 12px;
    font-weight: bold;
    position: absolute;
    top: -5px;
    right: -10px;
    transition: transform 0.3s ease;
}

.tutor-dashboard-permalinks li {
    margin: 8px 0;
}

.header__nav-item.menu-item-has-children.is-open .tutor-icon-angle-down {
    transform: rotate(180deg);
}

#dropdown-menu-header {
    border: none;
}

.header__actions--mobile {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.header__action-btn {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 36px;
    height: 36px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 3000;
}

.header__menu-toggle .line {
    width: 25px;
    height: 2px;
    background-color: white;
    margin: 2px 0;
    transition: all 0.3s ease;
}

.cart-contents {
    color: white;
}

.academy-btn-login {
    color: white;
    background-color: var(--alwaysLight);
}

.academy-btn-login:hover {
    box-shadow: 0 4px 6px -1px rgb(255 255 255 / 35%), 0 2px 4px -1px rgb(255 255 255 / 2%) !important;
    transition: all 175ms cubic-bezier(.4, 0, .2, 1), opacity 15ms linear 30ms, transform 270ms cubic-bezier(0, 0, .2, 1) 0ms;
}

.sub-menu-desktop {
    display: none;
    position: absolute;
    top: 65px;
    left: 50%;
    transform: translateX(-50%);
    background-color: var(--oxford);
    padding: 12px;
    margin: 0 auto;
    max-width: 1280px;
    width: calc(100vw - 30px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    z-index: 1000;
}

.sub-menu-desktop-container {
    list-style: none;
    display: grid;
    grid-auto-flow: column;
    grid-template-rows: repeat(3, auto);
    gap: 24px;
    width: max-content;
    padding: 0;
}

.sub-menu-desktop-container a {
    display: flex;
    align-items: start;
    gap: 12px;
    padding: 12px;
    color: white;
    text-decoration: none;
    width: 275px;
    height: auto;
    border-radius: 8px;
}

.tutor-dashboard .tutor-dashboard-left-menu .tutor-dashboard-permalinks li a,
.header__nav-link,
header .tutor-btn {
    padding: 8px 12px;
    white-space: nowrap;
}

.user-profile-link .tutor-avatar {
    width: 5.4rem;
    height: 5.4rem;
}

.user-name {
    font-weight: 700;
    text-transform: uppercase;
    line-height: 1.2;
    letter-spacing: 0;
    font-size: 1.6rem;
    color: var(--gunmental);
}

.user-email {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #595c73;
    margin-block-start: 0.4rem;
    max-inline-size: 15.4rem;
}

.dropdown-item.active,
.dropdown-item:active {
    background-color: var(--tutor-color-primary);
}

.tutor-dashboard .tutor-dashboard-left-menu .tutor-dashboard-permalinks {
    margin: 0;
    list-style: none;
    padding: 0;
	overflow-x: hidden;
}

.tutor-dashboard .tutor-dashboard-left-menu .tutor-dashboard-permalinks li.active a:hover {
    background-color: var(--tutor-color-primary-hover);
}

.dropdown-item {
    padding: 0;
    border-radius: 0px !important;
}

.dropdown-toggle-header span {
    font-size: 16px;
}

.dropdown-toggle-header {
    cursor: pointer;
}

@media (min-width: 1120px) {
    .header__logo--desktop {
        display: block;
    }

    .header__logo--mobile,
    .header__actions--mobile,
    .sub-menu-mobile,
    .header__nav-header--mobile {
        display: none !important;
    }

    .header__nav {
        display: flex;
        width: 100%;
        gap: 1rem;
    }

    .header__actions {
        position: relative;
        bottom: 0;
        left: 0;
        display: flex;
        justify-content: end;
    }

    .asl_w_container,
    .header__nav-item.header__search {
        width: 100%;
    }

    .user-avatar-dropdown {
        position: relative;
    }

    .user-avatar-dropdown .dropdown-menu {
        display: block;
         position: absolute;
        opacity: 0;
        visibility: hidden;
        transform: translateY(10px);
        transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease;
        top: 100%;
        margin-top: 10px;
        inset-inline-end: 0px;
        max-height: calc(100vh - 80px);
        overflow-y: auto;
    }

    .user-avatar-dropdown:hover .dropdown-menu {
        opacity: 1;
        visibility: visible;
    }

    #dropdown-menu-header {
        background-color: white;
        border: 1px solid var(--tutor-border-color);
    }

    .dropdown-item.active a {
        color: white !important;
    }

    .tutor-dashboard .tutor-dashboard-left-menu .tutor-dashboard-permalinks li a {
        color: var(--gunmental);
    }

    .header__nav-actions .header__nav-buttons,
    .header__nav-actions {
        display: flex;
        align-items: center;
        gap: 1rem;
    }

    .user-profile-section {
        border-bottom: 1px solid var(--tutor-border-color) !important;
    }

}

@media (max-width: 1120px) {
    .tutor-dashboard-permalinks li a {
        color: white;
    }

    body.sults-nav-active {
        overflow: hidden;
    }

    .tutor-dashboard:not(.is-sidebar-expanded) .tutor-dashboard-left-menu {
        display: block !important;
    }

    .header__nav {
        display: flex;
        flex-direction: column;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background-color: var(--oxford);
        z-index: 99999;
        transform: translateX(100%);
        overflow-y: auto;
    }

    .header__nav.is-open {
        transform: translateX(0);
    }

    .header__nav-header--mobile {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 10px 15px;
        height: 60px;
    }

    .header__nav-close {
        display: block;
        font-size: 2rem;
        font-weight: bold;
        color: white;
        background: transparent;
        border: none;
        cursor: pointer;
    }

    .header__nav-list {
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
        gap: 12px;
    }

    .header__nav-item {
        width: 100%;
    }

    .header__nav-list {
        border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
    }

    .header__nav-item:last-child {
        border-bottom: none !important;
    }

    .header__nav-link {
        width: 100%;
        font-weight: normal;
        justify-content: space-between;
        background-color: transparent;
        border: none;
        cursor: pointer;
        margin-bottom: 8px;
    }

    .header__nav-item.header__search {
        order: -1;
    }

    #category-submenu-mobile ul {
        padding: 0;
    }

    .header__nav-item {
        position: relative;
        display: block;
    }

    .user-avatar-dropdown .user-link,
    .cart-desktop,
    .sub-menu-desktop {
        display: none !important;
    }

    .sub-menu-mobile {
        display: none;
        list-style: none;
        margin: 0;
        width: 100%;
    }

    .menu-item-has-children.is-open>.sub-menu-mobile {
        display: block;
    }

    .sub-menu-mobile a {
        padding: 0.75rem 15px;
        color: white;
        display: flex;
        align-items: start;
        gap: 12px;
    }

    .academy-btn-login {
        margin-bottom: 12px;
    }

    .user-avatar-dropdown .dropdown-menu {
        display: block;
        inset-inline-end: auto;
    }

    .user-profile-section {
        display: none;
    }

    #dropdown-menu-header {
        background-color: transparent;
        width: 100%;
    }

    .tutor-dashboard .tutor-dashboard-left-menu .tutor-dashboard-permalinks li a {
        color: white;
    }

    .tutor-dashboard-menu-divider {
        border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
        height: 0;
        margin: 0;
        background-color: transparent !important;
    }

    .header__nav-actions .header__nav-buttons {
        width: 100%;
        display: block;
        gap: 1rem;
        z-index: 100000;
        box-sizing: border-box;
    }

    .header__nav-actions {
/*         margin-top: auto; */
        flex-shrink: 0;
    }

    .header__nav-list,
    .header__nav-actions .header__nav-buttons {
        padding: 16px;
    }

    .tutor-dashboard .tutor-dashboard-left-menu .tutor-dashboard-permalinks {
       padding: 0 16px;
    }
}