/**
 * Simple Mobile Menu CSS
 * Clear and working CSS for mobile menu
 */

/* Mobile Only Styles */
@media (max-width: 767px) {
    /* Hide menu by default on mobile */
    .main-navigation {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: 99999;
        background: transparent;
        display: none;
    }
    
    /* Show menu when open class is added */
    .main-navigation.menu-open {
        display: block !important;
    }
    
    /* Dark overlay */
    .main-navigation.menu-open::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.5);
        z-index: -1;
    }
    
    /* Menu wrapper slides from left */
    .main-navigation .nav-wrapper {
        position: absolute;
        top: 20px;
        left: -260px;
        width: 260px;
        height: auto;
        max-height: calc(100vh - 40px);
        background: #fff;
        transition: left 0.3s ease;
        overflow-y: auto;
        overflow-x: hidden;
        box-shadow: 2px 0 10px rgba(0,0,0,0.2);
        border-radius: 0 10px 10px 0;
    }
    
    /* Slide in when open */
    .main-navigation.menu-open .nav-wrapper {
        left: 0;
    }
    
    /* Menu close button - positioned in header */
    .mobile-menu-close {
        position: absolute;
        top: 10px;
        right: 10px;
        background: transparent;
        border: none;
        width: 32px;
        height: 32px;
        font-size: 24px;
        color: #fff;
        cursor: pointer;
        z-index: 10;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.2s ease;
        font-weight: bold;
        text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
    }
    
    .mobile-menu-close:hover {
        color: #ffd700;
        transform: rotate(90deg) scale(1.1);
    }
    
    /* Menu header */
    .nav-wrapper::before {
        content: 'MENU';
        display: block;
        padding: 10px 15px;
        background: linear-gradient(135deg, #c8232c 0%, #e74c3c 100%);
        color: white;
        font-weight: bold;
        font-size: 13px;
        margin-bottom: 0;
        letter-spacing: 1px;
        border-radius: 0 10px 0 0;
        box-sizing: border-box;
    }
    
    /* Menu items */
    .main-navigation .nav-menu {
        display: block;
        padding: 0;
        margin: 0;
        list-style: none;
        background: #fff;
    }
    
    .main-navigation .nav-menu li {
        display: block;
        border-bottom: 1px solid #f0f0f0;
        margin: 0;
    }
    
    .main-navigation .nav-menu li:last-child {
        border-bottom: none;
        border-radius: 0 0 10px 0;
    }
    
    .main-navigation .nav-menu li a {
        display: block;
        padding: 14px 20px;
        color: #333;
        text-decoration: none;
        font-size: 14px;
        transition: background 0.2s ease, color 0.2s ease;
        position: relative;
        white-space: nowrap;
        box-sizing: border-box;
        width: 100%;
        text-align: left;
    }
    
    /* Remove arrow icon - no longer needed */
    .main-navigation .nav-menu li a::before {
        content: none;
        display: none;
    }
    
    .main-navigation .nav-menu li a:hover {
        background: linear-gradient(90deg, #f8f8f8 0%, #fff 100%);
        color: #c8232c;
        /* Remove padding-left change to prevent shift */
    }
    
    /* Current page highlight */
    .main-navigation .nav-menu li.current-menu-item a,
    .main-navigation .nav-menu li.current_page_item a {
        background: #fff3f3;
        color: #c8232c;
        font-weight: 600;
    }
    
    /* Add padding bottom for last item */
    .main-navigation .nav-wrapper {
        padding-bottom: 10px;
    }
    
    /* Mobile menu toggle button */
    .mobile-menu-toggle {
        display: block;
        background: none;
        border: none;
        font-size: 24px;
        color: #333;
        cursor: pointer;
        padding: 10px;
    }
    
    /* Mobile bottom nav stays at bottom */
    .mobile-bottom-nav {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        z-index: 1000;
    }
}

/* Desktop - show menu normally */
@media (min-width: 768px) {
    .main-navigation {
        display: block !important;
        position: static !important;
        visibility: visible !important;
        opacity: 1 !important;
    }
    
    .main-navigation .nav-wrapper {
        position: static !important;
        left: auto !important;
        width: auto !important;
        transition: none !important;
    }
    
    .mobile-menu-toggle,
    .mobile-menu-close {
        display: none !important;
    }
    
    .mobile-bottom-nav {
        display: none !important;
    }
    
    /* Remove mobile-only elements */
    .nav-wrapper::before {
        display: none !important;
    }
}