﻿/* ---------------------------------------------------
   TopNav.css - Modernized for QuePashop (Light Mode)
--------------------------------------------------- */

.tm-topnav {
    background: rgba(255, 255, 255, 0.85); /* Semi-transparent white */
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-soft);
    padding: 0.8rem 0;
    position: sticky;
    top: 0;
    z-index: 1030;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.05);
    transition: var(--trans-smooth);
}

.tm-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    transition: var(--trans-fast);
}

.tm-brand:hover {
    color: var(--accent-primary);
}

.tm-brand i {
    color: var(--accent-primary); /* Cyan box */
    font-size: 1.8rem;
    filter: drop-shadow(0 4px 6px rgba(14, 165, 233, 0.2));
}

.tm-brand-text {
    color: var(--text-primary);
}

.tm-brand-mx {
    color: var(--accent-primary) !important;
    font-weight: 800;
}

.tm-toggler {
    border: 1px solid var(--border-soft) !important;
    padding: 0.5rem;
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    transition: var(--trans-fast);
}

.tm-toggler:focus {
    box-shadow: 0 0 0 3px var(--accent-primary-glow);
    outline: none;
}

.tm-toggler-icon i {
    font-size: 1.5rem;
    color: var(--text-primary);
}

.tm-nav-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    border-radius: var(--radius-sm);
    transition: var(--trans-fast);
}

.tm-nav-link i {
    font-size: 1.1rem;
    color: var(--text-muted);
    transition: var(--trans-fast);
}

.tm-nav-link:hover, .tm-nav-link.active {
    color: var(--accent-primary);
    background: rgba(14, 165, 233, 0.05); /* Very light cyan */
}

.tm-nav-link:hover i {
    color: var(--accent-primary);
    transform: scale(1.1);
}

.tm-nav-quick-link {
    background: rgba(14, 165, 233, 0.05);
    border: 1px solid rgba(14, 165, 233, 0.1);
}

.tm-nav-quick-link:hover {
    background: rgba(14, 165, 233, 0.1);
    border-color: rgba(14, 165, 233, 0.3);
}

.nav-orders .tm-nav-quick-link {
    background: rgba(16, 185, 129, 0.05); /* Light Emerald */
    border-color: rgba(16, 185, 129, 0.1);
}
.nav-orders .tm-nav-quick-link i {
    color: var(--accent-success);
}

.nav-orders .tm-nav-quick-link:hover {
    background: rgba(16, 185, 129, 0.1);
    border-color: rgba(16, 185, 129, 0.3);
}

/* Badges */
.tm-badge {
    background: var(--accent-danger);
    color: white;
    font-size: 0.7rem;
    font-weight: bold;
    padding: 0.2rem 0.4rem;
    border-radius: var(--radius-pill);
    top: -5px;
    right: -5px;
    box-shadow: 0 2px 4px rgba(239, 68, 68, 0.4);
    border: 1px solid var(--bg-surface);
}

.nav-badge-orders {
    background: var(--accent-success);
    box-shadow: 0 2px 4px rgba(16, 185, 129, 0.4);
}

/* CTAs (Buttons) */
.tm-nav-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1.2rem;
    border-radius: var(--radius-pill);
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    transition: var(--trans-fast);
    margin-left: 0.5rem;
}

.tm-cta-customer {
    background: var(--accent-primary);
    color: white !important;
    box-shadow: 0 4px 10px rgba(14, 165, 233, 0.3);
}

.tm-cta-customer i { color: white !important; }

.tm-cta-customer:hover {
    background: var(--accent-primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(14, 165, 233, 0.4);
}

.tm-cta-business {
    background: var(--bg-surface);
    color: var(--text-primary) !important;
    border: 1px solid var(--border-soft);
    box-shadow: var(--shadow-soft);
}

.tm-cta-business i { color: var(--accent-primary) !important; }

.tm-cta-business:hover {
    background: var(--bg-surface-hover);
    border-color: var(--text-muted);
    transform: translateY(-2px);
}

/* User Dropdown */
.tm-user-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.3rem 0.8rem !important;
    background: var(--bg-surface);
    border-radius: var(--radius-pill);
    border: 1px solid var(--border-soft);
    box-shadow: var(--shadow-soft);
}

.tm-user-toggle:hover {
    background: var(--bg-surface-hover);
    border-color: var(--border-accent);
}

.tm-avatar {
    background: var(--accent-primary);
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.9rem;
    box-shadow: 0 2px 6px rgba(14, 165, 233, 0.3);
}

.tm-user-name {
    font-weight: 500;
    color: var(--text-primary);
}

.tm-dropdown-menu {
    background: var(--bg-surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-soft);
    padding: 0.5rem;
    margin-top: 0.5rem !important;
}

.tm-dropdown-item {
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    padding: 0.5rem 1rem;
    transition: var(--trans-fast);
    font-weight: 500;
}

.tm-dropdown-item:hover {
    background: rgba(14, 165, 233, 0.05);
    color: var(--accent-primary);
}

.tm-dropdown-item i {
    color: var(--text-muted);
}
.tm-dropdown-item:hover i {
    color: var(--accent-primary);
}

.tm-logout {
    color: var(--accent-danger) !important;
}
.tm-logout i { color: var(--accent-danger) !important; }

.tm-logout:hover {
    background: rgba(239, 68, 68, 0.1);
}

/* Mobile Adjustments */
@media (max-width: 991.98px) {
    .tm-nav-actions {
        margin-top: 1rem;
        padding-top: 1rem;
        border-top: 1px solid var(--border-soft);
        gap: 0.5rem;
        display: flex;
        flex-direction: column;
    }

    .tm-nav-cta {
        margin-left: 0;
        justify-content: center;
        width: 100%;
    }

    /* En móvil, el botón de negocio se convierte en estilo botón con colores invertidos */
    .tm-nav-actions .tm-cta-business {
        background: white;
        color: var(--accent-primary) !important;
        border: 2px solid var(--accent-primary);
        box-shadow: 0 4px 10px rgba(14, 165, 233, 0.15);
        padding: 0.5rem 1.2rem;
        border-radius: var(--radius-pill);
        font-weight: 600;
        font-size: 0.95rem;
    }

    .tm-nav-actions .tm-cta-business i {
        color: var(--accent-primary) !important;
    }

    .tm-nav-actions .tm-cta-business:hover {
        background: rgba(14, 165, 233, 0.05);
        border-color: var(--accent-primary);
        transform: translateY(-2px);
        box-shadow: 0 6px 15px rgba(14, 165, 233, 0.25);
    }

    .tm-logout-mobile {
        color: var(--accent-danger) !important;
    }
    .tm-logout-mobile i {
        color: var(--accent-danger) !important;
    }
}

