/* ==========================================
   REDLINE — Mobile Navigation (mobile-nav.css)
   ========================================== */

/* ===== MOBILE APPBAR ===== */
.mobile-appbar {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1100;
    height: 56px;
    background: var(--bg-surface);
    border-bottom: 1px solid var(--border-color);
    padding: 0 16px;
    align-items: center;
    justify-content: space-between;
}

.mobile-appbar .appbar-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.mobile-appbar .appbar-logo img {
    width: 28px;
    height: 28px;
}

.mobile-appbar .appbar-logo span {
    font-family: var(--font-brand);
    font-weight: 800;
    font-size: 1.1rem;
    color: var(--text-primary);
    letter-spacing: 0.05em;
}

.mobile-appbar .appbar-actions {
    display: flex;
    align-items: center;
    gap: 4px;
}

.mobile-appbar .appbar-btn {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    color: var(--text-secondary);
    font-size: 1.1rem;
    background: transparent;
    border: none;
    cursor: pointer;
    position: relative;
    text-decoration: none;
}

.mobile-appbar .appbar-btn:hover {
    background: var(--bg-card);
    color: var(--text-primary);
}

.mobile-appbar .cart-badge {
    position: absolute;
    top: 4px;
    right: 2px;
    min-width: 16px;
    height: 16px;
    background: var(--accent-red);
    color: white;
    font-size: 0.6rem;
    font-weight: 700;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
}

/* ===== MOBILE DRAWER ===== */
.mobile-drawer-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 1200;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.mobile-drawer-overlay.active {
    display: block;
    opacity: 1;
}

.mobile-drawer {
    position: fixed;
    top: 0;
    right: -300px;
    width: 280px;
    height: 100%;
    background: var(--bg-surface);
    z-index: 1300;
    transition: right 0.3s ease;
    overflow-y: auto;
    border-left: 1px solid var(--border-color);
}

.mobile-drawer.active {
    right: 0;
}

.mobile-drawer-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
}

.mobile-drawer-header img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
}

.mobile-drawer-header .user-info h4 {
    font-size: 0.95rem;
    font-weight: 600;
    margin: 0;
    color: var(--text-primary);
}

.mobile-drawer-header .user-info span {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.mobile-drawer-nav {
    padding: 8px 0;
}

.mobile-drawer-nav a {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s;
}

.mobile-drawer-nav a:hover,
.mobile-drawer-nav a.active {
    background: var(--bg-card);
    color: var(--accent-red);
}

.mobile-drawer-nav a i {
    width: 20px;
    font-size: 1rem;
    text-align: center;
}

.mobile-drawer-divider {
    height: 1px;
    background: var(--border-color);
    margin: 8px 0;
}

/* ===== MOBILE BOTTOM NAV ===== */
.bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: var(--bg-surface);
    border-top: 1px solid var(--border-color);
    padding: 6px 0 env(safe-area-inset-bottom, 6px);
}

.bottom-nav-container {
    display: flex;
    justify-content: space-around;
    align-items: center;
    max-width: 500px;
    margin: 0 auto;
}

.bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 6px 12px;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.65rem;
    font-weight: 500;
    transition: color 0.2s;
    position: relative;
}

.bottom-nav-item i {
    font-size: 1.15rem;
}

.bottom-nav-item.active {
    color: var(--accent-red);
}

.bottom-nav-item .nav-badge {
    position: absolute;
    top: 0;
    right: 4px;
    min-width: 16px;
    height: 16px;
    background: var(--accent-red);
    color: white;
    font-size: 0.55rem;
    font-weight: 700;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
}

/* ===== SHOW MOBILE ELEMENTS ===== */
@media (max-width: 768px) {
    .mobile-appbar {
        display: flex;
    }

    .bottom-nav {
        display: block;
    }

    /* Hide desktop footer on mobile */
    .desktop-footer {
        margin-bottom: 72px;
    }
}
