/* Existing Menu Styles */

.menu__link {width: calc(100% );}

.menu__item--depth-2 a.menu__link{
  font-size: 14px;
margin-left: 10px;}

.open__icon svg{
  width: 12px;}

.open__icon  svg path {
    fill: #816998;}

.open__icon {margin: 0px!important;
  position: absolute;
  top: 60%;
    -ms-transform: translateY(-60%);
  transform: translateY(-60%);

}

button.menu__child-toggle.no-button {background: #fff!important;
padding: 0px;
 }


ul.menu__wrapper.no-list {

    padding: 0px;
    margin: 0px;
}

.menu--desktop {
    display: block;
}

/* Mobile Menu Overlay */
.menu--mobile {
      margin-top: 75px;
    display: none; /* Initially hidden */
    position: fixed; /* Overlaying the page content */
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(45, 5, 84, 0.95); /* Semi-transparent background */
    z-index: 10000; /* High z-index to overlay content */
    overflow-y: auto; /* Scroll for overflow content */
}

/* Menu items */
.menu__item {
    position: relative;
}

.menu__link {
    font-size: 1 rem;
    line-height: 1.667rem;
    text-decoration: none;
}

a.menu__link{color: #816998;}

.menu__link:hover,
.menu__link:focus,
.menu__link:active {
    text-decoration: none;
}

a.menu__link--active-link {
    color: #A02E26;
}
a.menu__link:focus{color: #A02E26;}
a.menu__link:hover {color: #2D0554;}

/* Responsive Menu Link Font Size */
@media (min-width: 768px) and (max-width: 1150px) {
    .menu__link {
        font-size: 0.833rem;
    }
}
.menu__child-toggle.no-button {
        position: absolute;
        top: 15px;
        right: -20px; /* Adjust as needed */
        transform: translateY(-50%);
        background: none;
        border: none;
        padding: 0;
        cursor: pointer;
    }
/* Mobile Menu Items */
@media (max-width: 992px) {
    .menu__item {
        display: block;
        width: 200px;
    }
ul.menu__wrapper.no-list{  padding-top: 30px;
  width: 90%;
    height: 100%;
  background-color: #fff;}
    .menu__link {
        display: block;
        font-size: 1.083rem;
    }
  .menu__child-toggle.no-button {
     top: 30px;
   right: 100px;}
}

/* Top Level Menu Items */
.menu__item--depth-1 {
    display: inline-block;
    padding: 0rem 1rem 0rem 1rem;

}

/* Active Link Underline Effect */
.menu__item--depth-1 > .menu__link--active-link:after {
    bottom: -3px;
    content: '';
    height: 2px;
    left: 0;
    position: absolute;
    width: 50%;

}

/* Mobile Top Level Menu Items */
@media (max-width: 992px) {
    .menu__item--depth-1 {

        padding: 0;
    }

    .menu__item--depth-1 > .menu__link {
        padding: 0.8rem 1.225rem 0.2rem 1.225rem;
    }

    .menu__item--depth-1 > .menu__link--active-link:after {
        content: none;
    }
}

/* Submenus */

.menu__submenu {
  width: 180px;
  padding top: 60px;
  margin-top:0px;
    display: none;
    left: 0;
    position: absolute;
    text-align: left;
    text-transform: none;
    top: 100%;

    z-index: 99;
    padding:1.1rem;
    border-radius: 0px 0px 0px 0px;
    background: #f1eff500;

    /* Add these for animation */
   max-height: 0; /* Initial state */
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

.menu__item--open > .menu__submenu {
    /* Keep display: block; for visibility */
    display: block;
    
    /* Add this for animation */
    max-height: 500px; /* Adjust based on content */
    transition: max-height 0.5s ease-in;
}

.menu__item--depth-2 {padding: 10px 0px 10px 25px;
background: #f1eff5;}



/* Hamburger Icon */
.hamburger-icon {
    display: none; /* Hidden by default */
    cursor: pointer;
    padding-left: 0px;
      padding-right: 0px;

    padding-bottom: 10px;
    border: none;
    background: transparent;
    
    top: 0px; /* Adjust as needed */
    right: 10px; /* Adjust as needed */
    z-index: 1001; /* Higher z-index than menu */
}

.hamburger-icon span {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px 0;
    background: #333; /* Adjust color as needed */
    transition: all 0.3s ease-in-out; /* Smooth transition for transformation */
}

/* Hamburger Icon Active State ('X' icon) */

.hamburger-icon.is-active span:nth-child(1) {
    transform: rotate(45deg) translate(4px, 4px);
}

.hamburger-icon.is-active span:nth-child(2) {
    opacity: 0;
}

.hamburger-icon.is-active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

/* Show Hamburger Icon and Overlay Mobile Menu on Small Screens */
@media (max-width: 992px) {
    .hamburger-icon {
        display: block; /* Show only on mobile */
    }

    .menu--desktop {
        display: none;
    }

    .menu--mobile.menu--open {
        display: block; /* Show when open */
    }
}

ul.no-list {
    padding-left: 0px!important;
}

button:hover, button:focus, .button:hover, .button:focus, button:active, .button:active {
    background-color: #fff;
}

/* Mobile Menu Item Adjustments */
@media (max-width: 992px) {
    .menu__item--has-submenu {
      width: 100%;
        position: relative;
        padding-right: 30px; /* Space for the toggle button */
    }
    .menu__item--depth-2 {background:transparent;
      padding: 5px 0px 10px 25px;
      
}
   
   .menu__link {
        display: block;
        width: calc(70% ); /* Adjust width to prevent overlap with toggle button */
    }
  
  .menu__submenu {
    display: none; /* Initially hidden */
    position: relative; /* Ensure it pushes other items down */
    width: 100%; /* Full width to match the parent item */
    padding: 1.1rem 1.2rem; /* Padding around submenu items */
    background: #f1eff5; /* Adjust background as needed */
    transition: max-height 0.3s ease-out; /* Smooth transition for expanding */
    overflow: hidden; /* Hide overflow when not expanded */
    background-color: #fff;}
}
 .menu__item--open > .menu__submenu {
        /* Keep display: block; for visibility */
        display: block;
           padding-top: 0px;
        /* Add this for animation */
        max-height: 500px; /* Adjust based on content */
        transition: max-height 0.5s ease-in;
    }
    

    /* Adjustments for open icon */
    .open__icon {
        position: absolute;
        top: 50%;
        right: 15px; /* Adjust as needed */
        transform: translateY(-50%);
        margin: 0;
        width: 15px;
        height: 15px; /* Adjust size as needed */
      z-index: 9999;
    }

    .open__icon svg path {  width: 12px;
        fill: #816998; /* Adjust color as needed */
    }

    /* Menu link adjustments */
   


.menu__wrapper.no-list > li:last-child {
    /* Add button styles */
width: 180px;
    background-color: #A02E26;
    color: #fff!important;
    border: none;
    border-radius: 5px;
    padding: 1px 10px;
    margin-left: auto; /* Push it to the right */
  width: auto!important;
  text-align: center;
}


@media (max-width: 992px) {.menu__wrapper.no-list > li:last-child a.menu__link { 
  width: 100%;
  text-align: center; }
.menu__wrapper.no-list > li:last-child { margin-top: 15px!important;
  margin-left: 20px!important;
  width:auto;}
  .menu__wrapper.no-list > li:last-child .menu__item {width: auto!important;
  text-align: center;}
  }



.menu__wrapper.no-list > li:last-child a.menu__link {
  padding: 0px;
  color: #fff!important;}

/* Hover effect for the button */
.menu__wrapper.no-list > li:last-child:hover {
    background-color: #D1491F;
    cursor: pointer;
}

.menu__item--depth-2:first-of-type {
    margin-top: 20px;
}

