/* ==== QUARK MOBILE MENU – Streamlined Slide-from-Left ==== */

/* Spectre / Utility Utilities */
.d-flex{display:flex}.d-inline-flex{display:inline-flex}.d-none{display:none}.d-block{display:block}
.flex-column{flex-direction:column}.pos-relative{position:relative}.pos-absolute{position:absolute}.pos-fixed{position:fixed}
.top-0{top:0}.right-0{right:0}.bottom-0{bottom:0}.left-0{left:0}
.w-100{width:100%}.h-100{height:100vh}
.z-4{z-index:1000}

/* 1. Body Lock - Prevents the background from scrolling when menu is open */
body.menu-open { 
    overflow: hidden !important; 
    touch-action: none; /* Extra insurance for mobile */
}

/* 2. The Hamburger Button Container (The 3 White Lines) */
.button_container {
    position: relative;
    height: 20px;
    width: 28px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    cursor: pointer;
    z-index: 10002;
}
.button_container span {
    background: #fff;
    height: 3px;
    width: 100%;
    border-radius: 3px;
    transition: all .35s ease;
}

/* 3. The Wrapper / Dimmed Overlay Background */
#mobile-container-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6); /* Semi-transparent black */
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: opacity .3s ease, visibility .3s;
}

/* Active State for Wrapper */
#mobile-container-wrapper.active {
    opacity: 1;
    visibility: visible;
}

/* 4. The Sliding Menu Panel (The White Drawer) */
.overlay {
    position: absolute;
    top: 0 !important;
    left: 0 !important; /* Align to LEFT */
    right: auto !important;
    width: 80vw; /* Leaves 20% on the right for clicking out */
    max-width: 450px; /* Cap width for tablets */
    min-width:260px;
    height: 100%;
    background: #fff;
    padding: 40px 20px;
    box-shadow: 5px 0 15px rgba(0,0,0,0.3); /* Shadow on the right side */
    overflow-y: auto;
    
    /* Hide off-screen to the left by default */
    transform: translateX(-100%);
    transition: transform .3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Active State for Sliding Panel */
#mobile-container-wrapper.active .overlay {
    transform: translateX(0); /* Slides into view */
}

/* 5. View Switching Logic (Menu vs Sub-menus) */
.overlay-view { 
    display: none; 
    opacity: 0;
    transition: opacity 0.3s ease;
}

.overlay-view.active { 
    display: block !important; 
    opacity: 1;
}

/* Remove the Close X Button styles as requested, 
   the 20% right-side gap handles dismissal now. */
#overlay-close { display: none; }
