/* Burger Menu Button */
body.no-scroll {
    overflow: hidden;
    height: 100vh;
}

#cbm-sidebar {
    z-index: 999999; /* Asegúrate de que sea superior al resto */
}
.sidebar-overlay {
    z-index: 999900;
}


#cbm-burger-btn {
    background: #e0c387 !important;
    width: 40px;
    height: 40px;
    color: #ffffff;
    display: flex
;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    cursor: pointer;
    border: 0px !important;
    z-index: 1100;
    padding: 3px;
    margin-left: 20px;
}
.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5); /* Semi-transparent background */
    display: none; /* Hide by default */
    z-index: 999; /* Ensure it stays above other content */
    transition: opacity 0.3s ease-in-out;
}



/* Sidebar Container */
#cbm-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 400px;
    height: 100%;
    background: #fff;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.2);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
    z-index: 1000;
    overflow-y: auto;
}


/* Sidebar Active State */
#cbm-sidebar.active {
    transform: translateX(0);
}



/* Close Button */
#cbm-close-btn {
    font-size: 35px;
    color: #333;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 1200;
    
}
button.cbm-close-btn:focus{
    outline: 0px !important;
}
button.cbm-close-btn:focus-visible{
    outline: 0px !important;
}
button.cbm-burger-btn:focus{
    outline: 0px !important;
}
button.cbm-burger-btn:focus-visible{
    outline: 0px !important;
}

/* Menu Items */
.cbm-menu {
    list-style: none;
    margin: 0;
    padding: 0;
    padding-top: 5px;
}


.cbm-menu-item {
    display: flex;
    height: 75px !important;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    position: relative;
    cursor: pointer;
    padding: 10px;
    transition: background 0.2s ease;
    border-bottom: 1px solid #e9e9e982;
}
.cbm-menu-item-parent{
    padding-top: 0px !important;
    padding-bottom: 0px !important;
    width: 100%;
    display: flex;
    align-items: center;
}
.cbm-menu-item:hover {
    background: #f7f7f7;
    border-radius: 5px;
}
.no-scroll {
    overflow: hidden;
    height: 100%; 
}

/* Menu Item Image */
.cbm-menu-item-image {
    width: 50px;
    height: 50px !important;
    object-fit: cover;
    border-radius: 50% !important;
    margin-right: 10px;
    
}

/* Menu Item Link */
.cbm-menu-item-link {
    font-size: 16px;
    padding-left: 10px;
    color: #333 !important;
    text-decoration: none;
    flex-grow: 1;
    width: 310px !important;
    transition: color 0.2s ease;
    white-space: normal; /* Allows the text to wrap */
    word-wrap: break-word; /* Ensures long words break properly */
    overflow-wrap: break-word; /* Adds extra compatibility */
}

.cbm-menu-item-link:hover {
    color: #0073aa;
}



.cbm-toggle-submenu:hover {
    color: #0073aa;
}

/* Submenu */
.cbm-submenu {
    display: none;
    margin: 0;
    padding: 0;
    width: 100%;
    list-style: none;
    transform: translateX(-100%);
    transition: transform 0.6s ease;

}
.cbm-submenu.active {
    display: block !important; 
    transform: translateX(0);
}
.cbm-menu-item.active{
    flex-direction: column;
}
.cbm-menu-item .cbm-toggle-submenu {
    cursor: pointer;
}
.cbm-menu-item.active > .cbm-submenu {
    display: block;
}

/* Submenu Item */
.cbm-submenu-item {
    display: flex;
    align-items: center;
    margin: 10px 0;
}

.cbm-submenu-item:hover {
    background: #f9f9f9;
}



/* Submenu Item Image */
.cbm-submenu-item .cbm-menu-item-image {
    width: 30px;
    height: 30px;
    margin-right: 10px;
}

/* Submenu Item Link */
.cbm-submenu-item .cbm-menu-item-link {
    font-size: 14px;
    color: #666;
}

.cbm-submenu-item .cbm-menu-item-link:hover {
    color: #0073aa;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    #cbm-sidebar {
        width: 100%;
    }


}

.cbm-back-container {
    display: flex;
    color: black !important;
    padding: 10px;
    align-items: center;
    font-weight: bold;
    border-bottom: 1px solid #ccc; /* Optional border */
}
div#cbm-sidebar {
    overflow-y: auto; /* Enables vertical scrolling */
    overflow-x: hidden; /* Hides horizontal scrollbar */
}

/* For Chrome, Edge, Safari */
div#cbm-sidebar::-webkit-scrollbar {
    width: 10px; /* Set the width of the scrollbar */
}

div#cbm-sidebar::-webkit-scrollbar-track {
    background: #f1f1f1; /* Track color */
    border-radius: 5px; /* Rounded corners */
}

div#cbm-sidebar::-webkit-scrollbar-thumb {
    background-color: #888; /* Scrollbar color */
    border-radius: 5px; /* Rounded corners for the thumb */
    border: 2px solid #f1f1f1; /* Adds padding effect around the thumb */
}

div#cbm-sidebar::-webkit-scrollbar-thumb:hover {
    background: #555; /* Color when hovering */
}

/* For Firefox */
div#cbm-sidebar {
    scrollbar-width: thin; /* Sets scrollbar thickness */
    scrollbar-color: #888 #f1f1f1; /* thumb color | track color */
}

.cbm-back-button {
    font-size: 12px !important;
    cursor: pointer !important;
    background: none !important;
    background-color: none !important;
    padding-left: 0px !important;
    border: 0px !important;
    padding-bottom: 2px !important;
    border: none !important;
    color: black !important;
}

.cbm-parent-title {
    cursor: pointer;
    font-weight: bold;
    font-size: 14px;
    color: black !important;
}


.sidebar-header {
    display: flex
;
    align-items: center;
    height: 110px;
    justify-content: space-between;
}
img.cbm-menu-logo {
    height: 50px;
    width: 90px;
    margin-left: 10px;
    /* padding-top: 35px !important; */
    /* padding-bottom: 30px ! Important; */
}

a.cbm-parent-link {
    text-decoration: none;
    font-size: 12px;
    background: rgb(244, 244, 244);
    font-weight: 500;
    padding: 7px;
    color: black !important;
    border-radius: 10px;
    margin-left: auto;
}

/* Keyframes for sliding animation */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(20px); /* Start slightly shifted */
    }
    to {
        opacity: 1;
        transform: translateX(0); /* End in place */
    }
}

/* Animate submenu items when added */
.cbm-submenu li {
    animation: slideIn 0.2s ease; /* Smooth animation for each item */
}

.cbm-menu li{
    animation: slideIn 0.2s ease; 
}