/**
 * Stili comuni per l'header MatWork
 */

/* Navbar */
.navbar {
    background: var(--surface) !important;
    border-bottom: 1px solid var(--border);
    padding: 0 1rem;
    flex-shrink: 0;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.navbar-brand {
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--primary) !important;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    flex-shrink: 0;
}

.navbar-brand i { 
    font-size: 1.3rem; 
}

.nav-links {
    display: flex;
    gap: 0.25rem;
    align-items: center;
}

.nav-link {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.85rem;
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    gap: 0.35rem;
    transition: all 0.15s;
    white-space: nowrap;
    position: relative;
}

.nav-link:hover {
    color: var(--primary);
    background: var(--primary-light);
}

.nav-link.active {
    color: var(--primary);
    background: var(--primary-light);
    font-weight: 500;
}

/* Badge richieste */
.header-badge {
    background: #ef4444;
    color: white;
    font-size: 0.65rem;
    font-weight: 600;
    min-width: 18px;
    height: 18px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 5px;
    margin-left: 4px;
    box-shadow: 0 1px 3px rgba(239, 68, 68, 0.4);
}

/* User info */
.header-user {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.75rem;
    background: var(--surface-dim);
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    flex-shrink: 0;
}

.header-user i.bi-person-circle {
    color: var(--primary);
    font-size: 1.1rem;
}

.header-user .divider {
    color: var(--text-muted);
    opacity: 0.5;
}

.header-user .role {
    color: var(--text-muted);
    font-size: 0.8rem;
}

.header-user .nav-link {
    padding: 0.35rem 0.5rem;
    font-size: 0.8rem;
}

.header-user .btn {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
}

/* Sidebar comune */
.sidebar {
    width: 280px;
    background: var(--surface);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    overflow-y: auto;
}

.sidebar-content {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Responsive */
@media (max-width: 1200px) {
    .nav-link span:not(.header-badge) {
        display: none;
    }
    .nav-link i {
        font-size: 1.1rem;
    }
    .header-user #currentRole,
    .header-user .divider {
        display: none;
    }
}

@media (max-width: 768px) {
    .navbar {
        padding: 0 0.5rem;
    }
    .sidebar {
        width: 240px;
    }
    .header-user {
        padding: 0.3rem 0.5rem;
    }
    .header-user #currentUser {
        display: none;
    }
}
