/* =============================================
   MOBILE SIDEBAR CSS
   Add to your main stylesheet
   ============================================= */

/* --- Overlay backdrop --- */
#sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;                          /* top/right/bottom/left: 0 */
    background: rgba(0, 0, 0, 0.5);
    z-index: 1040;
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
}
#sidebar-overlay.show {
    display: block;
}

/* --- Body scroll lock when sidebar is open --- */
body.sidebar-open {
    overflow: hidden;
}

/* --- Sidebar base (mobile-first) --- */
@media (max-width: 991.98px) {
    .sidebar {
        position: fixed;
        top: 20px;
        left: -320px;                  /* hidden off-screen */
        width: 300px;
        max-width: 85vw;
        height: 100dvh;                /* dvh = dynamic viewport height */
        overflow-y: auto;
        background: #fff;
        z-index: 1050;
        padding: 1rem;
        box-shadow: 4px 0 24px rgba(0,0,0,.18);
        transition: left 0.3s cubic-bezier(.4,0,.2,1);
        border-radius: 0 1rem 1rem 0;
    }
    .sidebar.show {
        left: 0;
    }
}

/* --- Close button (visible on mobile only) --- */
.sidebar-close-btn {
    display: none;
}
@media (max-width: 991.98px) {
    .sidebar-close-btn {
        display: flex;
        align-items: center;
        gap: .4rem;
        width: 100%;
        justify-content: flex-end;
        background: none;
        border: none;
        font-size: 2rem;
        font-weight: 600;
        cursor: pointer;
        margin-bottom: .75rem;
        padding: .25rem;
        margin-top: 20px;
        background-color: #fff;
        color: #0a753c !important;
    }
    .sidebar-close-btn i {
        font-size: 1rem;
    }
}

/* --- Accordion: widget titles become tappable on mobile --- */
@media (max-width: 991.98px) {
    .widget .widget-title {
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: space-between;
        user-select: none;
    }
    /* Arrow indicator */
    .widget .widget-title::after {
        content: "\ea4e";              /* ri-arrow-down-s-line codepoint */
        font-family: "remixicon";
        font-size: 1.1rem;
        transition: transform .25s ease;
    }
    .widget .widget-title.collapsed::after {
        transform: rotate(-90deg);
    }
}

/* --- Sidebar trigger button (add this wherever you place it) --- */
.sidebar-trigger {
    display: none;
}
@media (max-width: 991.98px) {
    .sidebar-trigger {
        display: inline-flex;
        align-items: center;
        gap: .4rem;
        padding: .45rem .9rem;
        border-radius: .5rem;
        font-weight: 600;
        cursor: pointer;
        font-size: .9rem;
    }
}


.sidebar-trigger.close {
    position: relative;
   
    font-size: 1.5rem;
    line-height: 1;
    top: 24px;
    right: 0;
}

.close-btn-holder {
    padding-top:10px ;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    width: auto;
    height: 50px;
}