.account_nav .grid_contain{
    max-width: 1220px;
    padding: 0 !important;
}

.account_nav .grid_contain .mepr-nav-item:not(.menu-item) {
    display: none;
}
.account_nav .grid_contain a{
    font-size: 18px;
    color: #777;
}
.account_nav .grid_contain .mepr-nav-item{
    padding: 0px 12px;
}
@media screen and (max-width: 768px){
    .account_nav .grid_contain .mepr-nav-item{
        width: 100%;
        box-sizing: border-box;
    }
}
.account_nav .current-menu-item a{
    text-decoration: underline;
    text-underline-offset: 5px;
    color: #493e3e;
}
.after-header-menu-wrapper{
    background: white;
    padding: 40px 0px 36px;
    text-align: right;
    
}
.after-header-menu-wrap{
    max-width: 1220px;
    margin: 0 auto;
}

.after-header-menu-wrapper .after-header-menu-wrap a{
    font-size: 18px;
    color: #777;
}
.after-header-menu-wrapper .after-header-menu-wrap .current_page_item a{
    text-decoration: underline;
    text-underline-offset: 5px;
    color: #493e3e;
}
.after-header-menu-wrapper .after-header-menu-wrap .mepr-nav-item{
    padding: 0px 12px;
}
@media screen and (max-width: 768px){
    .after-header-menu-wrapper .after-header-menu-wrap .mepr-nav-item{
   width: 100%;
        box-sizing: border-box;
        padding-right: 32px;
        margin-right: 0;
}
}
.after-header-menu-wrapper .menu-item-has-children.open-mobile-menu::after {
    transform: translateY(-75%) rotate(-135deg);
}
.page-template-template-recipes .dropdown-check-list.visible .items {
    display: none;
}
.page-template-template-recipes .dropdown-check-list.visible .anchor{
    color: inherit;
}

.page-template-template-recipes .recipe_search_bar form input[type="text"], select{
    border-color: black;
    background: black;
    color: white;
}

.page-template-template-recipes #recipe_search,
#categoryfilter,
#recipe_diet,
#list1 .items {
    background-color: #000 !important;
    color: #fff;
    border: 1px solid black;
    border-right-color: white !important;
}
.page-template-template-recipes #recipe_search::placeholder{
    color: #fff;
}

.page-template-template-recipes #recipe_button button{
        border: 0px solid #7BCBBE;
    background: #7BCBBE;
}
.page-template-template-learn .learn_search_bar #learn_text input,
#learn_categoryfilter {
    background-color: #000;
    color: #fff;
    border: 1px solid black;
}
.page-template-template-learn .learn_search_bar #learn_text input::placeholder{
    color: #fff;
}
.page-template-template-learn .learn_search_bar #learn_text input{
    border-right-color: white;
}
.page-template-template-learn .learn_search_bar #learn_button button{
    background: #7BCBBE;
}
.featured-image{
    display: none;
}

/* 1. Set the main container to relative so absolute elements stay contained */
.nmr-administrator.menu-item-has-children {
    position: relative;
    display: inline-block;
    
    padding-bottom: 10px; 
}

.nmr-administrator.menu-item-has-children a{
    padding-right: 15px;
}
/* 2. Hide all the sub-menu items by default and stack them absolutely */
.nmr-administrator.menu-item-has-children .mepr-nav-item {
    display: none;
    position: absolute;
    left: 0;
    width: 200px; 
    background-color: #ffffff; 
    box-shadow: 0px 4px 10px rgba(0,0,0,0.15);
    z-index: 999;
    padding: 0;
}

/* 3. Position each dropdown item sequentially below the main "Dashboard" link 
   (ONLY triggers when actively hovering the menu layout container) */

/* First dropdown item (Subscriptions) */
.nmr-administrator.menu-item-has-children:hover .mepr-nav-item:nth-of-type(1) {
    top: 100%; 
}
/* Second dropdown item (Payments) */
.nmr-administrator.menu-item-has-children:hover .mepr-nav-item:nth-of-type(2) {
    top: calc(100% + 40px); 
}
/* Third dropdown item (Account) */
.nmr-administrator.menu-item-has-children:hover .mepr-nav-item:nth-of-type(3) {
    top: calc(100% + 80px);
}
/* Fourth dropdown item (Logout) */
.nmr-administrator.menu-item-has-children:hover .mepr-nav-item:nth-of-type(4) {
    top: calc(100% + 120px);
}
/* Fifth dropdown item (Security Safety Net) */
.nmr-administrator.menu-item-has-children:hover .mepr-nav-item:nth-of-type(5) {
    top: calc(100% + 160px);
}
/* Sixth dropdown item (Security Safety Net) */
.nmr-administrator.menu-item-has-children:hover .mepr-nav-item:nth-of-type(6) {
    top: calc(100% + 200px);
}

/* 4. Style the links inside the dropdown so they look clean */
.nmr-administrator.menu-item-has-children .mepr-nav-item a {
    display: block;
    padding: 10px 15px;
    color: #333;
    text-decoration: none;
    font-size: 16px;
    text-align: left;
}
@media screen and (max-width: 767px){
    .nmr-administrator.menu-item-has-children .mepr-nav-item a{
        
    text-align: right;
    }
}


/* 6. Underline the main Dashboard link when you are actively on one of its sub-pages */
.nmr-administrator.menu-item-has-children.current-menu-ancestor > a {
    text-decoration: underline;
}

/* 7. THE FIX: Force display block ONLY when hovered. 
   Removing the persistent active class selector ensures it closes when the mouse leaves. */
.nmr-administrator.menu-item-has-children:hover .mepr-nav-item {
    display: block;
}
.nmr-administrator.menu-item-has-children::after {

    content: '';

    position: absolute;

    right: 6px;

    top: 50%;

    border: solid #333;

    border-width: 0 2px 2px 0;

    display: inline-block;

    padding: 4px;

    transform: translateY(-75%) rotate(45deg); /* pointing down */

    transform-origin: center center;

    transition: transform 0.2s ease;

    pointer-events: none;

}


@media screen and (max-width: 767px) {
    
    /* 1. Main parent container */
    .nmr-administrator.menu-item-has-children {
        position: relative;
        display: inline-flex;
        flex-direction: column;
        align-items: flex-start;
        width: 100%; 
    }

    /* 2. Main "Dashboard" text link */
    .nmr-administrator.menu-item-has-children > a {
        display: block;
        padding-right: 30px;
        z-index: 1000; 
        position: relative;
        width: 100%;
        box-sizing: border-box;
    }

    /* 3. The Arrow Graphic */
    .nmr-administrator.menu-item-has-children::after {
        content: '';
        position: absolute;
        right: 20px;
        top: 12px; 
        border: solid #333;
        border-width: 0 2px 2px 0;
        display: inline-block;
        padding: 4px;
        z-index: 1002; 
        pointer-events: none; /* Mouse/touch events fall through to the parent container */
    }

    /* 4. Sub-menu items (Hidden by default) */
    .nmr-administrator.menu-item-has-children .mepr-nav-item {
        position: static !important; 
        box-shadow: none !important;
        width: 100% !important;
        
        display: block !important; 
        opacity: 0;
        visibility: hidden;
        height: 0;
        overflow: hidden;
        transition: opacity 0.2s ease, height 0.2s ease;
    }

    /* 5. THE TOGGLE REVEAL: Driven cleanly by the JS class injection */
    .nmr-administrator.menu-item-has-children.open-mobile-menu .mepr-nav-item {
        opacity: 1;
        visibility: visible;
        height: auto; 
    }

   

    /* 7. Inner Sub-menu Links styling */
    .nmr-administrator.menu-item-has-children .mepr-nav-item a {
        display: block;
        padding: 5px; 
        color: #333333;
        text-decoration: none;
        box-sizing: border-box;
    }
    
}
.page-template-template-learn .content_wrap{
    pointer-events: auto;
}

.wpb_content_element.page-all-header{
    margin-bottom: 0;
}
.wpb_content_element.page-all-header h2{
        font-size: 50px;
        font-weight: 500;
        line-height: 1.2em;
        color: #fff;
        margin-bottom: 10px;
    }
    @media screen and (max-width: 767px){
        .wpb_content_element.page-all-header h2{
            font-size: 32px;
            text-align: center !important;
        }
    }
    
    
    
    .account_nav .grid_contain{
    max-width: 1220px;
    padding: 0 !important;
}

.account_nav .grid_contain a{
    font-size: 18px;
    color: #777;
}

.account_nav .grid_contain .mepr-nav-item{
    padding: 0 12px;
}

.account_nav .current-menu-item > a,
.account_nav .mepr-active-nav-tab > a{
    text-decoration: underline;
    text-underline-offset: 5px;
    color: #493e3e;
}

/* AFTER HEADER MENU */
.after-header-menu-wrapper .menu-item-has-children.open-mobile-menu::after,
.account_nav #mepr-account-nav .menu-item-has-children.open-mobile-menu::after {
    transform: translateY(-75%) rotate(-135deg);
}

/* Hide default MemberPress tabs if using custom menu */
.account_nav #mepr-account-nav > .dashboard,
.account_nav #mepr-account-nav > .mepr-home,
.account_nav #mepr-account-nav > .mepr-subscriptions,
.account_nav #mepr-account-nav > .mepr-payments{
    display:none;
}

/* Main dropdown parent */
.account_nav #mepr-account-nav .menu-item-has-children{
    position: relative;
    display: inline-block;
    padding-bottom: 10px;
}

.account_nav #mepr-account-nav .menu-item-has-children > a{
    padding-right: 15px;
}

/* Dropdown arrow */
.account_nav #mepr-account-nav .menu-item-has-children::after{
    content:'';
    position:absolute;
    right:6px;
    top:50%;
    border:solid #333;
    border-width:0 2px 2px 0;
    display:inline-block;
    padding:4px;
    transform:translateY(-75%) rotate(45deg);
    transform-origin:center;
    transition:transform .2s ease;
    pointer-events:none;
}

/* Hide submenu */
.account_nav #mepr-account-nav .menu-item-has-children .mepr-nav-item{
    display:none;
    position:absolute;
    left:0;
    width:200px;
    background:#fff;
    box-shadow:0 4px 10px rgba(0,0,0,.15);
    z-index:999;
    padding:0;
}

/* Show submenu on hover */
.account_nav #mepr-account-nav .menu-item-has-children:hover .mepr-nav-item{
    display:block;
}

/* Position dropdown items */
.account_nav #mepr-account-nav .menu-item-has-children:hover .mepr-nav-item:nth-of-type(1){
    top:100%;
}

.account_nav #mepr-account-nav .menu-item-has-children:hover .mepr-nav-item:nth-of-type(2){
    top:calc(100% + 40px);
}

.account_nav #mepr-account-nav .menu-item-has-children:hover .mepr-nav-item:nth-of-type(3){
    top:calc(100% + 80px);
}

.account_nav #mepr-account-nav .menu-item-has-children:hover .mepr-nav-item:nth-of-type(4){
    top:calc(100% + 120px);
}

/* Dropdown links */
.account_nav #mepr-account-nav .menu-item-has-children .mepr-nav-item a{
    display:block;
    padding:10px 15px;
    color:#333;
    text-decoration:none;
    font-size:16px;
    text-align:left;
}

/* Mobile */
@media screen and (max-width:767px){

    .account_nav .grid_contain .mepr-nav-item{
        width:100%;
    }

.account_nav #mepr-account-nav .menu-item{
box-sizing: border-box;
padding-right: 32px;
margin-right: 0;

}
    .account_nav #mepr-account-nav .menu-item-has-children{
        display:flex;
        flex-direction:column;
        align-items:flex-start;
        width:100%;
        
    }

    .account_nav #mepr-account-nav .menu-item-has-children > a{
        width:100%;
        padding-right:4px;
        position:relative;
        z-index:1000;
        box-sizing:border-box;
    }

    .account_nav #mepr-account-nav .menu-item-has-children::after{
        right:16px;
        top:15px;
        z-index:1002;
        
    }

    .account_nav #mepr-account-nav .menu-item-has-children .mepr-nav-item{
        position:static !important;
        width:100% !important;
        box-shadow:none !important;

        display:block !important;
        opacity:0;
        visibility:hidden;
        height:0;
        overflow:hidden;

        transition:opacity .2s ease,height .2s ease;
    }

    .account_nav #mepr-account-nav .menu-item-has-children.open-mobile-menu .mepr-nav-item{
        opacity:1;
        visibility:visible;
        height:auto;
    }

    .account_nav #mepr-account-nav .menu-item-has-children .mepr-nav-item a{
        padding:5px;
        text-align:right;
    }
}
/* Main dropdown parent */
.after-header-menu-wrapper .menu-item-has-children{
    position: relative;
    display: inline-block;
    padding-bottom: 10px;
}

.after-header-menu-wrapper .menu-item-has-children > a{
    padding-right: 15px;
}

/* Arrow */
.after-header-menu-wrapper .menu-item-has-children::after{
    content: '';
    position: absolute;
    right: 6px;
    top: 64%;
    border: solid #333;
    border-width: 0 2px 2px 0;
    display: inline-block;
    padding: 4px;
    transform: translateY(-75%) rotate(45deg);
    pointer-events: none;
}
.after-header-menu-wrapper .menu-item-has-children::after {
    transition: transform 0.3s ease;
    transform-origin: center;
    will-change: transform;
}

/* Hide submenu */
.after-header-menu-wrapper .menu-item-has-children .mepr-nav-item{
    display: none;
    position: absolute;
    left: 0;
    width: 200px;
    background: #fff;
    box-shadow: 0 4px 10px rgba(0,0,0,.15);
    z-index: 999;
    padding: 0;
}

/* Show submenu on hover */
.after-header-menu-wrapper .menu-item-has-children:hover .mepr-nav-item{
    display: block;
}

/* Position items */
.after-header-menu-wrapper .menu-item-has-children:hover .mepr-nav-item:nth-of-type(1){
    top: 100%;
}

.after-header-menu-wrapper .menu-item-has-children:hover .mepr-nav-item:nth-of-type(2){
    top: calc(100% + 40px);
}

.after-header-menu-wrapper .menu-item-has-children:hover .mepr-nav-item:nth-of-type(3){
    top: calc(100% + 80px);
}

.after-header-menu-wrapper .menu-item-has-children:hover .mepr-nav-item:nth-of-type(4){
    top: calc(100% + 120px);
}

/* Dropdown links */
.after-header-menu-wrapper .menu-item-has-children .mepr-nav-item a{
    display: block;
    padding: 10px 15px;
    color: #333;
    text-decoration: none;
    font-size: 16px;
    text-align: left;
}

/* Mobile */
@media screen and (max-width:767px){

    .after-header-menu-wrapper .menu-item-has-children{
        display:flex;
        flex-direction:column;
        align-items:flex-start;
        width:100%;
    }

    .after-header-menu-wrapper .menu-item-has-children > a{
        width:100%;
        padding-right:30px;
    }

    .after-header-menu-wrapper .menu-item-has-children::after{
        right:12px;
        top:15px;
    }

    .after-header-menu-wrapper .menu-item-has-children .mepr-nav-item{
        position:static !important;
        width:100% !important;
        box-shadow:none !important;

        display:block !important;
        opacity:0;
        visibility:hidden;
        height:0;
        overflow:hidden;
    }

    .after-header-menu-wrapper .menu-item-has-children.open-mobile-menu .mepr-nav-item{
        opacity:1;
        visibility:visible;
        height:auto;
    }

    .after-header-menu-wrapper .menu-item-has-children .mepr-nav-item a{
        text-align:right;
        padding:5px;
    }
}