  
        :root { --primary-bg: #f3f4f6; --sidebar-bg: #ffffff; --text-main: #1e293b; --text-light: #64748b; --accent-teal: #0ea5e9; --accent-gold: #f59e0b; --border-color: #e2e8f0; }
        
        * { box-sizing: border-box; margin: 0; padding: 0; font-family: 'Vazirmatn', 'Segoe UI', 'Tahoma', sans-serif; text-decoration: none; outline: none; -webkit-tap-highlight-color: transparent; }
        
        body { background-color: var(--primary-bg); color: var(--text-main); display: flex; height: 100vh; overflow: hidden; }

        /* --- Mobile / Sidebar --- */
        .mobile-menu-btn { display: none; position: fixed; top: 20px; right: 20px; z-index: 1001; background: white; border: none; width: 45px; height: 45px; border-radius: 12px; box-shadow: 0 4px 15px rgba(0,0,0,0.1); color: var(--accent-teal); font-size: 20px; cursor: pointer; align-items: center; justify-content: center; }
        
        .overlay { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.4); backdrop-filter: blur(2px); z-index: 1002; }
        .overlay.active { display: block; }
        
        /* تغییر مهم: افزایش z-index سایدبار به عددی بالاتر از overlay */
        .sidebar { width: 260px; background-color: var(--sidebar-bg); border-left: 1px solid var(--border-color); display: flex; flex-direction: column; padding: 20px; z-index: 10100; transition: transform 0.3s; flex-shrink: 0; height: 100vh; }
        .sidebar.active { transform: translateX(0); }
        
        .brand-logo { font-size: 22px; font-weight: 800; color: var(--accent-teal); display: flex; align-items: center; justify-content: center; gap: 10px; margin-bottom: 40px; padding-bottom: 20px; border-bottom: 1px solid #f1f5f9; }
        .nav-menu { display: flex; flex-direction: column; gap: 10px; flex: 1; overflow-y: auto; }
        .nav-item { display: flex; align-items: center; gap: 12px; padding: 12px 15px; border-radius: 12px; color: var(--text-light); font-weight: 500; font-size: 14px; transition: 0.2s; white-space: nowrap; }
        .nav-item:hover { background-color: #f1f5f9; color: var(--accent-teal); transform: translateX(-5px); }
        .sidebar-footer { margin-top: auto; border-top: 1px solid #f1f5f9; padding-top: 20px; display: flex; align-items: center; gap: 10px; }
        .user-avatar { width: 40px; height: 40px; background: #e0f2fe; color: #0284c7; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: bold; flex-shrink: 0; }

        /* --- Main Content --- */
        .main-content { flex: 1; padding: 30px; overflow-y: auto; display: flex; flex-direction: column; gap: 20px; scroll-behavior: smooth; }
        .page-header { display: flex; align-items: center; gap: 15px; margin-bottom: 10px; }
        .back-btn { width: 40px; height: 40px; border-radius: 50%; background: white; display: flex; align-items: center; justify-content: center; color: var(--text-main); box-shadow: 0 2px 5px rgba(0,0,0,0.1); transition: 0.2s; cursor: pointer; flex-shrink: 0; }
        .page-title { font-size: 24px; font-weight: 800; color: var(--text-main); }
        
        /* Filter & Search */
        .filter-section { background: white; padding: 20px; border-radius: 16px; box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05); display: flex; flex-direction: column; gap: 20px; }
        .input-wrapper { flex: 1; position: relative; display: flex; align-items: center; }
        .input-wrapper input { width: 100%; padding: 12px 45px 12px 15px; border: 2px solid #cbd5e1; border-radius: 10px; font-size: 15px; transition: 0.3s; }
        .input-wrapper input:focus { border-color: var(--accent-gold); box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.1); }
        
        .chips-row { display: flex; align-items: center; gap: 10px; overflow-x: auto; padding-bottom: 5px; -ms-overflow-style: none; scrollbar-width: none; }
        .chips-row::-webkit-scrollbar { display: none; }
        .filter-chip { padding: 8px 16px; border-radius: 20px; background-color: #f1f5f9; color: var(--text-light); font-size: 14px; font-weight: 500; cursor: pointer; border: 1px solid transparent; transition: 0.2s; white-space: nowrap; user-select: none; }
        .filter-chip.active { background-color: var(--accent-gold); color: white; box-shadow: 0 2px 5px rgba(245, 158, 11, 0.3); }
        .result-count { margin-right: auto; font-size: 14px; color: var(--text-light); font-weight: bold; }

        /* Cards */
        .rv-list { display: flex; flex-direction: column; gap: 15px; min-height: 200px; }
        .rv-card { background: white; border-radius: 12px; padding: 20px; border: 1px solid #e2e8f0; display: flex; flex-direction: column; gap: 15px; animation: fadeIn 0.2s ease-out; cursor: pointer; transition: 0.2s; }
        .rv-card:hover { transform: translateY(-3px); box-shadow: 0 5px 15px rgba(0,0,0,0.05); border-color: var(--accent-gold); }
        
        .card-header-row { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px dashed #f1f5f9; padding-bottom: 10px; }
        .code-badge { font-weight: 800; font-size: 18px; color: var(--text-main); display: flex; align-items: center; gap: 8px; }
        .attr-badge { color: #ef4444; font-weight: 900; margin-right: 15px; font-size: 20px; display: inline-block; }
        
        .card-body p { font-size: 15px; line-height: 1.8; color: #334155; white-space: pre-line; }
        
        .tag-blue, .tag-light-blue, .tag-gray { padding: 4px 10px; border-radius: 6px; font-size: 12px; font-weight: 500; color: white; }
        .tag-blue { background-color: #0c4a6e; } .tag-light-blue { background-color: #0ea5e9; } .tag-gray { background-color: #64748b; }

        /* --- Modal (Popup) --- */
        .modal-overlay {
            display: none;
            position: fixed;
            top: 0; left: 0;
            width: 100%; height: 100%;
            background: rgba(0, 0, 0, 0.6);
            backdrop-filter: blur(4px);
            z-index: 2000;
            opacity: 0;
            transition: opacity 0.3s ease;
        }
        .modal-overlay.open { display: flex; opacity: 1; align-items: center; justify-content: center; }

        .modal-content {
            background: white;
            width: 90%;
            max-width: 600px;
            max-height: 85vh;
            border-radius: 20px;
            box-shadow: 0 10px 25px rgba(0,0,0,0.2);
            overflow-y: auto;
            transform: translateY(20px);
            transition: transform 0.3s ease;
            display: flex;
            flex-direction: column;
        }
        .modal-overlay.open .modal-content { transform: translateY(0); }

        .modal-header {
            padding: 20px;
            border-bottom: 1px solid #e2e8f0;
            display: flex;
            justify-content: space-between;
            align-items: center;
            background: #f8fafc;
            position: sticky; top: 0;
        }
        .modal-title { font-size: 18px; font-weight: 800; color: var(--text-main); }
        .close-btn { background: none; border: none; font-size: 24px; color: #64748b; cursor: pointer; }

        .modal-body { padding: 20px; }
        
        .detail-group { margin-bottom: 20px; }
        .detail-group-title { font-size: 14px; font-weight: 700; color: var(--accent-teal); margin-bottom: 10px; border-right: 3px solid var(--accent-teal); padding-right: 8px; }
        
        .detail-row { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid #f1f5f9; font-size: 14px; }
        .detail-label { color: var(--text-light); }
        .detail-value { color: var(--text-main); font-weight: 600; text-align: left; max-width: 60%; }

        @keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
        @media (max-width: 768px) {
            body { display: block; overflow: auto; }
            .mobile-menu-btn { display: flex; }
            .sidebar { position: fixed; top: 0; right: 0; height: 100vh; width: 280px; transform: translateX(100%); box-shadow: -5px 0 20px rgba(0,0,0,0.1); }
            .main-content { padding: 80px 20px 20px 20px; height: auto; overflow: visible; }
        }
   