/* PitOp Mobile Optimization */

@media (max-width: 768px) {

    /* 1. Hide Sidebar, Expand Content */
    .main-sidebar {
        display: none !important;
    }

    .content-wrapper,
    .main-footer {
        margin-left: 0 !important;
    }

    .content-wrapper {
        padding-bottom: 80px !important;
    }

    /* Space for nav */

    /* 2. Bottom Navigation Bar */
    .mobile-bottom-nav {
        display: flex !important;
        position: fixed;
        bottom: 0;
        left: 0;
        width: 100%;
        height: 65px;
        background: #ffffff;
        border-top: 1px solid #e0e0e0;
        z-index: 10000;
        justify-content: space-around;
        align-items: center;
        box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.05);
        padding-bottom: env(safe-area-inset-bottom);
    }

    .mobile-nav-item {
        flex: 1;
        text-align: center;
        color: #888;
        padding: 8px 0;
        cursor: pointer;
        transition: color 0.2s;
    }

    .mobile-nav-item:active,
    .mobile-nav-item.active {
        color: #007bff;
        /* Primary Blue */
        background-color: #f8f9fa;
    }

    .mobile-nav-item i {
        font-size: 20px;
        display: block;
        margin-bottom: 4px;
    }

    .mobile-nav-item span {
        font-size: 10px;
        font-weight: 500;
        display: block;
    }

    /* 3. More Menu Overlay */
    .mobile-more-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: 20000;
        animation: fadeIn 0.2s;
    }

    @keyframes fadeIn {
        from {
            opacity: 0;
        }

        to {
            opacity: 1;
        }
    }

    .mobile-more-content {
        position: absolute;
        bottom: 0;
        left: 0;
        width: 100%;
        background: white;
        border-radius: 20px 20px 0 0;
        padding: 20px;
        animation: slideUp 0.3s;
        max-height: 80vh;
        overflow-y: auto;
    }

    @keyframes slideUp {
        from {
            transform: translateY(100%);
        }

        to {
            transform: translateY(0);
        }
    }

    .mobile-more-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding-bottom: 15px;
        border-bottom: 1px solid #eee;
        margin-bottom: 15px;
    }

    .mobile-more-body {
        display: flex;
        flex-direction: column;
        gap: 5px;
    }

    .mobile-menu-item {
        display: flex;
        align-items: center;
        padding: 15px;
        border-radius: 10px;
        cursor: pointer;
        transition: background 0.2s;
    }

    .mobile-menu-item:active {
        background: #f0f0f0;
    }

    .mobile-menu-item i {
        font-size: 22px;
        color: #007bff;
        margin-right: 15px;
        width: 30px;
    }

    .mobile-menu-item span {
        font-size: 16px;
        font-weight: 500;
        color: #333;
    }
}

@media (min-width: 769px) {

    .mobile-bottom-nav,
    .mobile-more-overlay {
        display: none !important;
    }
}