
    /* تنظیمات هدر ثابت (Fixed) - پایداری مطلق در بالای صفحه */
    .main-header {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        z-index: 1100;
        width: 100%;
        padding: 10px 0;
        transition: all 0.3s ease;
    }

    .header-glass {
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border: 1px solid rgba(255, 255, 255, 0.3);
        border-radius: 0 0 25px 25px;
        margin: 0 auto;
        width: calc(100% - 15px);
        max-width: 1400px;
        padding: 12px 25px;
        display: flex;
        justify-content: space-between;
        align-items: center;
        box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    }

    .dark-mode .header-glass {
        background: rgba(15, 23, 42, 0.96);
        border-color: rgba(255, 255, 255, 0.05);
        box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
    }

    /* بخش برند و لوگو */
    .header-brand {
        display: flex;
        align-items: center;
        gap: 15px;
        text-decoration: none !important;
        flex-shrink: 0;
    }
    .brand-logo {
        width: 60px;
        height: 60px;
        filter: drop-shadow(0 4px 6px rgba(0,0,0,0.15));
        transition: transform 0.4s ease;
    }
    .brand-name {
        line-height: 1.2;
    }
    .brand-name h2 {
        font-size: 1.4rem;
        font-weight: 900;
        color: #0f172a;
        margin: 0;
        letter-spacing: 0.8px;
        font-family: 'Samim', sans-serif;
    }
    .dark-mode .brand-name h2 { color: #f8fafc; }
    
    .brand-name span {
        font-size: 0.8rem;
        color: #64748b;
        font-weight: 700;
        display: block;
        margin-top: 2px;
    }

    /* ناوبری و نقش کاربری */
    .header-nav {
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .user-status-pill {
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 8px 18px;
        background: #f1f5f9;
        border-radius: 16px;
        font-size: 0.95rem;
        font-weight: 800;
        color: #334155;
        border: 1px solid rgba(0,0,0,0.05);
        white-space: nowrap;
    }
    .dark-mode .user-status-pill { 
        background: #1e293b; 
        color: #f1f5f9; 
    }

    .role-dot {
        width: 10px;
        height: 10px;
        border-radius: 50%;
        box-shadow: 0 0 8px currentColor;
    }

    .role-admin  { color: #ef4444; }
    .role-tech   { color: #0ea5e9; }
    .role-op     { color: #10b981; }
    .role-mng    { color: #a855f7; }
    .role-guest  { color: #94a3b8; }

    .nav-icon-btn {
        width: 48px;
        height: 48px;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 15px;
        background: rgba(0,0,0,0.03);
        color: #475569;
        font-size: 1.4rem;
        text-decoration: none !important;
        position: relative;
    }
    .dark-mode .nav-icon-btn { background: rgba(255,255,255,0.05); color: #cbd5e1; }

    .admin-badge {
        position: absolute;
        top: -2px;
        right: -2px;
        background: #ef4444;
        color: white;
        font-size: 0.7rem;
        min-width: 20px;
        height: 20px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-weight: bold;
        border: 2px solid white;
    }

    /* بهینه‌سازی اختصاصی و درشت برای موبایل */
    @media (max-width: 768px) {
        .main-header { padding: 5px 0; }
        .header-glass { 
            padding: 10px 12px; 
            border-radius: 0 0 20px 20px; 
            width: 100%; 
            margin: 0;
            gap: 8px;
        }
        
        /* افزایش اندازه لوگو در موبایل طبق خواسته شما */
        .brand-logo { 
            width: 55px; 
            height: 55px; 
        }
        
        /* نمایش درشت MY HVAC و تاریخ در موبایل */
        .brand-name h2 { 
            font-size: 1.15rem; 
            display: block !important;
        }
        .brand-name span { 
            font-size: 0.7rem; 
            display: block !important;
        }
        
        .user-status-pill { 
            padding: 6px 10px; 
            font-size: 0.8rem; 
            gap: 6px;
        }
        .nav-icon-btn { width: 42px; height: 42px; font-size: 1.2rem; }
        .header-nav { gap: 5px; }
    }

    /* بهینه‌سازی برای گوشی‌های کوچک (حفظ نمایش متن‌ها) */
    @media (max-width: 420px) {
        .header-brand { gap: 8px; }
        .brand-logo { width: 50px; height: 50px; }
        .brand-name h2 { font-size: 1rem; }
        .brand-name span { font-size: 0.6rem; }
        .user-status-pill { padding: 5px 8px; }
        .user-status-pill span { font-size: 0.75rem; }
    }
