/* assets/css/offcanvas-menu.css */
.offcanvas-menu-wrapper {
    position: relative;
    display: inline-block;
    width: 100%;
}
body .offcanvas-menu-wrapper .offcanvas-toggle-btn {
    border: none;
    background: transparent;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
    padding: 0;
}
.offcanvas-menu-container {
    position: fixed;
    top: 0;
    width: 300px;
    height: 100vh;
    z-index: 999999;
    visibility: hidden;
    transition: all 0.4s ease;
}
.offcanvas-position-right {
    right: -100vw;
}
.offcanvas-position-right.is-open {
    right: 0;
    visibility: visible;
}
.offcanvas-position-left {
    left: -100vw;
}
.offcanvas-position-left.is-open {
    left: 0;
    visibility: visible;
}

.offcanvas-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0,0,0,0.6);
    z-index: -1;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease;
}
.offcanvas-menu-container.is-open .offcanvas-menu-overlay {
    opacity: 1;
    visibility: visible;
}
.offcanvas-menu-content {
    position: relative;
    width: 100%;
    height: 100%;
    background-color: #ffffff; 
    overflow-y: auto;
    box-shadow: 0 0 15px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
}

.offcanvas-close-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    background: transparent;
    border: none;
    font-size: 30px;
    cursor: pointer;
    line-height: 1;
    padding: 5px;
    z-index: 999;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
}
.offcanvas-close-btn:hover {
    opacity: 0.7;
}

.offcanvas-inner-content {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    padding: 20px 0;
}

.offcanvas-logo {
    padding: 30px 20px 20px;
    text-align: center;
}
.offcanvas-logo img {
    max-width: 100%;
    height: auto;
}

/* Custom Walker WP Nav Menu Styles */
.offcanvas-menu-content .custom-mobile-menu {
    width: 100%;
}
.offcanvas-menu-content .mobile-menu-list, 
.offcanvas-menu-content .sub-menu { 
    list-style: none; 
    padding: 0; 
    margin: 0; 
}
.offcanvas-menu-content .menu-item { 
    padding: 15px 20px; 
    /* Default border if not styled in Elementor */
    border-bottom: 1px solid rgba(0,0,0,0.05); 
} 
.offcanvas-menu-content .menu-item a {
    text-decoration: none; 
    display: block;
    transition: color 0.3s ease;
}
.offcanvas-menu-content .menu-item-inner { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
}
.offcanvas-menu-content .toggle-icon {
    width: 30px; 
    height: 30px; 
    display: flex; 
    justify-content: center; 
    align-items: center;
    cursor: pointer; 
    transition: all 0.3s ease;
}
.offcanvas-menu-content .toggle-icon svg {
    transition: transform 0.3s ease;
}
.offcanvas-menu-content .menu-item.active-dropdown > .menu-item-inner .toggle-icon svg { 
    transform: rotate(180deg); 
}
.offcanvas-menu-content .sub-menu { 
    display: none; 
}
.offcanvas-menu-content .sub-menu li { 
    padding: 10px 15px; 
    border: none; 
}
.offcanvas-menu-content .menu-item.active-dropdown > .sub-menu { 
    display: block; 
}

/* --- Desktop Menu Styles --- */
.oem-menu-container {
    width: 100%;
}
.oem-desktop-menu {
    display: none;
}
.oem-desktop-nav .oem-desktop-menu-list {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    align-items: center;
    flex-wrap: wrap;
}
.oem-desktop-nav .oem-desktop-menu-list > li {
    position: relative;
}
.oem-desktop-nav .oem-desktop-menu-list a {
    display: block;
    padding: 10px 15px;
    text-decoration: none;
    transition: all 0.3s ease;
}

/* Dropdowns moved to bottom */

/* --- Breakpoint Logic --- */

/* Always Offcanvas */
.oem-menu-container.oem-breakpoint-none .oem-offcanvas-toggle-wrapper {
    display: inline-block;
}

/* Tablet Breakpoint (< 1025px) */
.oem-menu-container.oem-breakpoint-tablet .oem-offcanvas-toggle-wrapper {
    display: none;
}
.oem-menu-container.oem-breakpoint-tablet .oem-desktop-menu {
    display: block;
}
@media (max-width: 1024px) {
    .oem-menu-container.oem-breakpoint-tablet .oem-offcanvas-toggle-wrapper {
        display: inline-block;
    }
    .oem-menu-container.oem-breakpoint-tablet .oem-desktop-menu {
        display: none;
    }
}

/* Mobile Breakpoint (< 768px) */
.oem-menu-container.oem-breakpoint-mobile .oem-offcanvas-toggle-wrapper {
    display: none;
}
.oem-menu-container.oem-breakpoint-mobile .oem-desktop-menu {
    display: block;
}
@media (max-width: 767px) {
    .oem-menu-container.oem-breakpoint-mobile .oem-offcanvas-toggle-wrapper {
        display: inline-block;
    }
    .oem-menu-container.oem-breakpoint-mobile .oem-desktop-menu {
        display: none;
    }
}
/* --- Desktop Menu Styles Fix --- */
.oem-desktop-nav > ul,
.oem-desktop-nav .oem-desktop-menu-list {
    display: flex !important;
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
    align-items: center;
    flex-wrap: wrap;
}
.oem-desktop-nav > ul > li,
.oem-desktop-nav .oem-desktop-menu-list > li {
    position: relative;
    list-style: none !important;
}
.oem-desktop-nav a {
    display: block;
    padding: 10px 15px;
    text-decoration: none;
    transition: all 0.3s ease;
}

/* Dropdowns Fix */
.oem-desktop-nav .sub-menu {
    position: absolute !important;
    top: 100%;
    left: 0;
    background-color: rgba(255, 255, 255, 0.85); /* Glass fallback */
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px !important;
    list-style: none !important;
    padding: 10px 0 !important;
    margin: 0 !important;
    min-width: 220px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    opacity: 0;
    visibility: hidden;
    transform: translateY(15px);
    transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
    z-index: 99;
}
.oem-desktop-nav li:hover > .sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.oem-desktop-nav .sub-menu .sub-menu {
    top: 0;
    left: 100%;
}
.oem-desktop-nav .sub-menu li {
    position: relative;
    list-style: none !important;
}
.oem-desktop-nav .sub-menu a {
    padding: 10px 25px;
    transition: all 0.2s ease;
}
.oem-desktop-nav .sub-menu li:hover > a {
    padding-left: 30px;
    background-color: transparent !important;
}

/* --- Breakpoint Logic Fixes --- */

.oem-menu-container.oem-breakpoint-tablet .oem-offcanvas-toggle-wrapper,
.oem-menu-container.oem-breakpoint-mobile .oem-offcanvas-toggle-wrapper {
    display: none !important;
}
.oem-menu-container.oem-breakpoint-tablet .oem-desktop-menu,
.oem-menu-container.oem-breakpoint-mobile .oem-desktop-menu {
    display: block !important;
}

@media (max-width: 1024px) {
    .oem-menu-container.oem-breakpoint-tablet .oem-offcanvas-toggle-wrapper {
        display: inline-block !important;
    }
    .oem-menu-container.oem-breakpoint-tablet .oem-desktop-menu {
        display: none !important;
    }
}

@media (max-width: 767px) {
    .oem-menu-container.oem-breakpoint-mobile .oem-offcanvas-toggle-wrapper {
        display: inline-block !important;
    }
    .oem-menu-container.oem-breakpoint-mobile .oem-desktop-menu {
        display: none !important;
    }
}
