        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            font-family:
                -apple-system, BlinkMacSystemFont, "Segoe UI", "Heebo", Arial,
                sans-serif;
        }

        :root {
            --color-primary: #2f4f7f;
            --color-success: #10b981;
            --color-warning: #f59e0b;
            --color-danger: #ef4444;
            --color-info: #0ea5e9;
            --color-muted: #64748b;
            /* Brand colors — set dynamically by branding.js only when custom branding is saved.
               These are NOT applied by default — original design stays intact. */
            --brand-primary:    #6366f1;
            --brand-secondary:  #7c3aed;
            --brand-primary-10: #6366f11a;
            --brand-primary-20: #6366f133;
        }

        /* ── Scrollbars עדינים (Webkit) ── */
        ::-webkit-scrollbar { width: 5px; height: 5px; }
        ::-webkit-scrollbar-track { background: transparent; }
        ::-webkit-scrollbar-thumb { background: rgba(100,116,139,.28); border-radius: 10px; }
        ::-webkit-scrollbar-thumb:hover { background: rgba(100,116,139,.5); }
        * { scrollbar-width: thin; scrollbar-color: rgba(100,116,139,.28) transparent; }

        body {
            background: #eef2f7;
            min-height: 100vh;
            overflow-x: hidden;
        }

        /* Login */
        .login-screen {
            display: flex;
            align-items: center;
            justify-content: center;
            min-height: 100vh;
            background: linear-gradient(140deg, #dfe6ef 0%, #edf2f8 50%, #d6e0ec 100%);
            padding: 20px;
        }

        .login-card {
            background: rgba(255, 255, 255, 0.95);
            backdrop-filter: blur(4px);
            padding: 48px;
            border-radius: 16px;
            border: 1px solid #dbe6ff;
            box-shadow: 0 20px 60px rgba(71, 85, 105, 0.22);
            max-width: 420px;
            width: 100%;
        }

        .login-header {
            text-align: center;
            margin-bottom: 24px;
        }

        .login-header h1 {
            font-size: 28px;
            font-weight: 700;
            color: #1e293b;
            margin-bottom: 8px;
            text-align: center;
        }

        .brand-logo {
            display: block;
            width: 112px;
            height: 112px;
            margin: 0 auto 14px;
            object-fit: contain;
            border-radius: 24px;
            padding: 4px;
            background: #ffffff;
            border: 1px solid #d5e1f1;
            box-shadow:
                0 10px 24px rgba(37, 59, 93, 0.16),
                inset 0 1px 0 rgba(255, 255, 255, 0.85);
        }

        .login-header p {
            color: #64748b;
            font-size: 16px;
            font-weight: 500;
            line-height: 1.25;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            text-align: center;
            margin-bottom: 24px;
        }

        .form-group {
            margin-bottom: 20px;
        }

        #newRequestSection .top-bar,
        #newRequestSection #requestEditBanner,
        #newRequestSection #requestForm {
            width: min(1120px, 100%);
            margin-inline: auto;
        }

        .request-form-grid {
            display: grid;
            grid-template-columns: repeat(12, minmax(0, 1fr));
            column-gap: 16px;
            row-gap: 14px;
            align-items: end;
            direction: rtl;
        }

        .request-form-grid .form-group {
            margin-bottom: 0;
        }

        .request-field--institution,
        .request-field--category,
        .request-field--urgency,
        .request-field--quantity {
            grid-column: span 4;
        }

        .request-field--title {
            grid-column: span 8;
        }

        .request-field--institution {
            order: 1;
        }

        .request-field--category {
            order: 2;
        }

        .request-field--urgency {
            order: 3;
        }

        .request-field--title {
            order: 4;
        }

        .request-field--quantity {
            order: 5;
        }

        .request-form-full-row {
            margin-top: 18px;
        }

        .form-label {
            display: block;
            font-size: 13px;
            font-weight: 600;
            color: #475569;
            margin-bottom: 8px;
        }

        .form-input,
        .form-select,
        .form-textarea {
            width: 100%;
            padding: 12px 16px;
            border: 1px solid #e2e8f0;
            border-radius: 8px;
            font-size: 14px;
            transition: all 0.2s;
            background: #f8fafc;
        }

        .form-input:focus,
        .form-select:focus,
        .form-textarea:focus {
            outline: none;
            border-color: #667eea;
            background: white;
            box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
        }

        .form-select[size] {
            padding: 4px;
        }

        .form-select[size] option {
            padding: 8px 12px;
            border-radius: 4px;
            margin: 2px 0;
        }

        .form-select[size] option:checked {
            background: #667eea !important;
            color: white !important;
        }

        .form-textarea {
            resize: vertical;
            min-height: 120px;
        }

        .password-input-wrapper {
            position: relative;
        }

        .password-input-wrapper .form-input {
            padding-left: 48px;
        }

        .password-toggle-btn {
            position: absolute;
            left: 8px;
            top: 50%;
            transform: translateY(-50%);
            border: none;
            background: transparent;
            color: #64748b;
            cursor: pointer;
            width: 32px;
            height: 32px;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            padding: 0;
            border-radius: 6px;
        }

        .password-toggle-btn:hover {
            background: rgba(148, 163, 184, 0.18);
        }

        .eye-icon {
            width: 18px;
            height: 18px;
            fill: currentColor;
        }

        .eye-icon-hide {
            display: none;
        }

        .password-toggle-btn.is-visible .eye-icon-show {
            display: none;
        }

        .password-toggle-btn.is-visible .eye-icon-hide {
            display: block;
        }

        .email-settings-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
            gap: 16px;
        }

        .email-settings-card {
            background: #f8fafc;
            border: 1px solid #e2e8f0;
            border-radius: 10px;
            padding: 16px;
            display: flex;
            flex-direction: column;
            gap: 8px;
        }

        .email-settings-card h4 {
            font-size: 15px;
            font-weight: 700;
            color: #1e293b;
            margin-bottom: 4px;
        }

        .email-settings-actions {
            display: flex;
            flex-wrap: wrap;
            gap: 12px;
            justify-content: flex-start;
            margin-top: 16px;
        }

        .email-settings-status {
            font-size: 12px;
            color: #475569;
            background: #eef2ff;
            border: 1px solid #c7d2fe;
            padding: 8px 12px;
            border-radius: 8px;
            margin-bottom: 16px;
        }

        .chip-input {
            display: flex;
            flex-direction: column;
            gap: 8px;
        }

        .chip-list {
            display: flex;
            flex-wrap: wrap;
            gap: 8px;
            min-height: 40px;
            padding: 8px;
            border: 1px solid #e2e8f0;
            border-radius: 8px;
            background: white;
        }

        .chip {
            display: inline-flex;
            align-items: center;
            gap: 6px;
            padding: 6px 10px;
            border-radius: 999px;
            background: #e0e7ff;
            color: #1e293b;
            font-size: 12px;
            font-weight: 600;
        }

        .chip button {
            border: none;
            background: transparent;
            cursor: pointer;
            color: #475569;
            font-size: 14px;
            line-height: 1;
        }

        .btn {
            padding: 12px 24px;
            border-radius: 8px;
            border: none;
            font-size: 14px;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.2s;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
        }

        .btn:disabled {
            opacity: 0.5;
            cursor: not-allowed;
        }

        .request-action-status {
            margin-top: 12px;
            padding: 10px 12px;
            border-radius: 8px;
            font-size: 13px;
            border: 1px solid transparent;
            line-height: 1.5;
        }

        .request-action-status-info {
            background: #eff6ff;
            color: #1e40af;
            border-color: #bfdbfe;
        }

        .request-action-status-success {
            background: #ecfdf5;
            color: #065f46;
            border-color: #6ee7b7;
        }

        .request-action-status-error {
            background: #fef2f2;
            color: #b91c1c;
            border-color: #fecaca;
        }

        .request-action-next {
            margin-top: 4px;
            font-weight: 600;
        }

        .btn-primary {
            background: var(--color-primary);
            color: white;
        }

        .btn-secondary {
            background: #f1f5f9;
            color: #475569;
        }

        .btn-success {
            background: var(--color-success);
            color: white;
        }

        .btn-danger {
            background: var(--color-danger);
            color: white;
        }

        .btn-warning {
            background: var(--color-warning);
            color: white;
        }

        .btn-refresh {
            background: linear-gradient(135deg, #4a6580 0%, #3a516f 55%, #2b415b 100%);
            color: white;
            border-radius: 50px;
            padding: 8px 18px;
            font-size: 13px;
            font-weight: 500;
            letter-spacing: 0.3px;
            box-shadow: 0 2px 8px rgba(43,65,91,.22);
            position: relative;
            overflow: hidden;
        }

        .btn-refresh::after {
            content: '';
            position: absolute;
            inset: 0;
            background: linear-gradient(135deg, rgba(255,255,255,0.14) 0%, transparent 60%);
            opacity: 0;
            transition: opacity 0.25s;
        }

        .btn-refresh:hover::after {
            opacity: 1;
        }

        .btn-refresh:hover {
            box-shadow: 0 4px 16px rgba(43,65,91,.35);
            transform: translateY(-1px);
        }

        .btn-refresh:active {
            transform: translateY(0);
            box-shadow: 0 1px 5px rgba(43,65,91,.2);
        }

        .btn-refresh .refresh-icon {
            transition: transform 0.55s cubic-bezier(0.4, 0, 0.2, 1);
        }

        .btn-refresh:hover .refresh-icon {
            transform: rotate(200deg);
        }

        /* Settings tab bar — pill style */
        #settingsSubNav {
            background: #fff;
            border: 1px solid #e2e8f0;
            border-radius: 12px;
            padding: 12px 16px;
            display: flex;
            flex-wrap: wrap;
            gap: 8px;
            margin-bottom: 20px;
        }

        .settings-tab {
            display: inline-flex;
            align-items: center;
            gap: 6px;
            padding: 8px 16px;
            border: 1.5px solid #e2e8f0;
            border-radius: 999px;
            background: #f8fafc;
            color: #475569;
            font-size: 13px;
            font-weight: 500;
            cursor: pointer;
            white-space: nowrap;
            transition: all 0.15s;
        }
        .settings-tab:hover {
            border-color: #667eea;
            color: #667eea;
            background: #eef2ff;
        }
        .settings-tab.active {
            background: #667eea;
            border-color: #667eea;
            color: #fff;
            font-weight: 600;
            box-shadow: 0 2px 8px rgba(102,126,234,0.35);
        }

        .btn-sm {
            padding: 7px 14px;
            font-size: 12px;
        }

        /* Main */
        .main-app {
            display: none;
        }

        .main-app.active {
            display: flex;
            min-height: 100vh;
        }

        /* Sidebar */
        .sidebar {
            width: 280px;
            background: linear-gradient(180deg, #3a516f 0%, #324a67 52%, #2b415b 100%);
            color: white;
            padding: 24px 0 0;
            position: fixed;
            right: 0;
            top: 0;
            bottom: 0;
            overflow: hidden;
            display: flex;
            flex-direction: column;
        }

        .sidebar-header {
            padding: 6px 16px 12px;
            border-bottom: 1px solid rgba(255, 255, 255, 0.14);
            margin-bottom: 10px;
            cursor: pointer;
            transition: opacity 0.2s ease;
            text-align: center;
            display: flex;
            flex-direction: column;
            align-items: center;
        }

        .sidebar-header:hover {
            opacity: 0.92;
        }

        .sidebar-header h2 {
            font-size: 12px;
            font-weight: 500;
            margin-bottom: 0;
            line-height: 1.2;
            color: rgba(255, 255, 255, 0.88);
            letter-spacing: 0.01em;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            width: 100%;
        }

        .sidebar-logo {
            width: 56px;
            height: 56px;
            object-fit: contain;
            border-radius: 14px;
            margin-bottom: 8px;
            background: #ffffff;
            padding: 2px;
            border: 1px solid rgba(218, 228, 242, 0.9);
            box-shadow: 0 8px 16px rgba(10, 22, 39, 0.22);
        }

        .sidebar-header p {
            font-size: 13px;
            color: #94a3b8;
        }

        .sidebar-header {
            flex-shrink: 0;
        }

        .notifications-overlay {
            display: none;
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: rgba(0, 0, 0, 0.3);
            z-index: 9997;
        }

        .notifications-overlay.active {
            display: block;
        }

        .notifications-panel {
            position: fixed;
            left: 0;
            top: 0;
            bottom: 0;
            width: 400px;
            background: white;
            box-shadow: 2px 0 20px rgba(0, 0, 0, 0.15);
            transform: translateX(-100%);
            transition: transform 0.3s;
            z-index: 9998;
            overflow-y: auto;
        }

        .notifications-panel.active {
            transform: translateX(0);
        }

        .notification-item {
            padding: 16px;
            border-bottom: 1px solid #e2e8f0;
            cursor: pointer;
            transition: background 0.2s;
        }

        .notification-item:hover {
            background: #f8fafc;
        }

        .notification-item.unread {
            background: #eff6ff;
            border-right: 3px solid #667eea;
        }

        .sidebar-menu {
            list-style: none;
            flex: 1;
            overflow-y: auto;
            min-height: 0;
            scrollbar-width: thin;
            scrollbar-color: rgba(255,255,255,0.2) transparent;
        }
        .sidebar-menu::-webkit-scrollbar { width: 4px; }
        .sidebar-menu::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.2); border-radius: 2px; }

        .sidebar-item {
            padding: 12px 24px;
            cursor: pointer;
            transition: all 0.2s;
            display: flex;
            align-items: center;
            gap: 12px;
            color: #94a3b8;
            font-size: 14px;
            font-weight: 500;
        }

        .sidebar-item:hover {
            background: rgba(255, 255, 255, 0.05);
            color: white;
        }

        .nav-icon {
            width: 18px;
            height: 18px;
            stroke: currentColor;
            stroke-width: 1.9;
            fill: none;
            flex: 0 0 18px;
        }

        .section-title-inline-icon {
            width: 16px;
            height: 16px;
            stroke: currentColor;
            stroke-width: 1.9;
            fill: none;
            vertical-align: -2px;
            margin-inline-start: 6px;
        }

        .sidebar-item.active {
            background: rgba(74, 103, 145, 0.9);
            color: white;
            border-right: 3px solid #bfdbfe;
        }

        .sidebar-footer {
            padding: 24px;
            border-top: 1px solid rgba(255, 255, 255, 0.1);
            margin-top: 0;
            flex-shrink: 0;
        }

        .user-profile {
            display: flex;
            align-items: center;
            gap: 12px;
            padding: 12px;
            background: rgba(255, 255, 255, 0.05);
            border-radius: 8px;
            margin-bottom: 12px;
        }

        .user-avatar {
            width: 40px;
            height: 40px;
            border-radius: 50%;
            background: #667eea;
            display: flex;
            align-items: center;
            justify-content: center;
            font-weight: 700;
        }

        .user-name {
            font-size: 14px;
            font-weight: 600;
        }

        .user-role {
            font-size: 11px;
            color: #94a3b8;
        }

        /* Main Content */
        .main-content {
            flex: 1;
            margin-right: 280px;
            padding: 24px;
            position: relative;
        }

        .top-bar {
            background: white;
            padding: 16px 24px;
            border-radius: 12px;
            margin-bottom: 24px;
            box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
            position: relative;
        }

        .notifications-bell {
            position: fixed;
            top: 24px;
            left: 24px;
            z-index: 9996;
            cursor: pointer;
            background: white;
            width: 48px;
            height: 48px;
            border-radius: 50%;
            display: none;
            align-items: center;
            justify-content: center;
            box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
            transition:
                transform 0.3s,
                box-shadow 0.3s;
        }

        body.logged-in .notifications-bell {
            display: flex;
        }


        .bell-icon {
            width: 20px;
            height: 20px;
            stroke: #334155;
            stroke-width: 2;
            fill: none;
        }

        .notifications-bell:hover {
            transform: scale(1.1);
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
        }

        .bell-badge {
            position: absolute;
            top: 2px;
            right: 2px;
            background: #ef4444;
            color: white;
            font-size: 10px;
            font-weight: 700;
            padding: 2px 6px;
            border-radius: 10px;
            min-width: 18px;
            text-align: center;
        }

        .page-title {
            font-size: 24px;
            font-weight: 700;
            color: #1e293b;
        }

        .page-subtitle {
            font-size: 13px;
            color: #64748b;
            margin-top: 4px;
        }

        .content-section {
            display: none;
        }

        .content-section.active {
            display: block;
        }

        .content-card {
            background: white;
            padding: 24px;
            border-radius: 12px;
            box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
            margin-bottom: 24px;
        }

        .request-submit-bar {
            position: static;
            display: flex;
            justify-content: center;
            margin-top: 8px;
            padding: 16px 0 0;
            border-top: 1px solid #e2e8f0;
            background: transparent;
        }

        .request-submit-bar .btn {
            width: auto;
            min-width: 220px;
            max-width: 320px;
            min-height: 48px;
            padding: 14px 28px !important;
        }

        /* Dashboard */
        .stats-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
            gap: 20px;
            margin-bottom: 24px;
        }

        .stat-card {
            background: white;
            padding: 24px;
            border-radius: 12px;
            box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
            display: flex;
            align-items: center;
            gap: 16px;
        }

        .stat-card.clickable {
            cursor: pointer;
            transition: transform 0.2s, box-shadow 0.2s;
        }

        .stat-card.clickable:hover {
            transform: translateY(-2px);
            box-shadow: 0 6px 14px rgba(15, 23, 42, 0.12);
        }

        .stat-icon {
            width: 48px;
            height: 48px;
            border-radius: 10px;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 24px;
        }

        .stat-icon-svg {
            width: 22px;
            height: 22px;
            stroke: currentColor;
            stroke-width: 2;
            fill: none;
        }

        .refresh-icon {
            width: 16px;
            height: 16px;
            stroke: currentColor;
            stroke-width: 2;
            fill: none;
        }

        .stat-content {
            flex: 1;
        }

        .stat-label {
            font-size: 13px;
            color: #64748b;
            margin-bottom: 4px;
        }

        .stat-value {
            font-size: 28px;
            font-weight: 700;
            color: #1e293b;
        }

        .dashboard-grid {
            display: grid;
            grid-template-columns: 2fr 1fr;
            gap: 24px;
        }

        .dashboard-list {
            max-height: 400px;
            overflow-y: auto;
            padding-left: 4px;
        }

        /* Request Card */
        .request-card {
            background: #f8fafc;
            border: 1px solid #e2e8f0;
            padding: 20px;
            border-radius: 12px;
            margin-bottom: 12px;
            cursor: pointer;
            transition: all 0.2s;
            box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
        }

        .request-card:hover {
            border-color: var(--color-primary);
            box-shadow: 0 4px 10px rgba(15, 23, 42, 0.12);
        }


        .request-header {
            display: flex;
            justify-content: space-between;
            margin-bottom: 12px;
        }

        .request-id {
            font-size: 14px;
            font-weight: 600;
            color: #667eea;
        }

        .request-title {
            font-size: 16px;
            font-weight: 600;
            color: #1e293b;
            margin-top: 4px;
        }

        .status-badge {
            display: inline-flex;
            align-items: center;
            font-size: 11px;
            font-weight: 600;
            padding: 3px 8px;
            border-radius: 4px;
            border: none !important;
            box-shadow: none !important;
            border-right: 3px solid transparent;
        }

        .status-pending       { background: #fff7ed; color: #9a3412; border-right-color: #f97316 !important; }
        .status-approved      { background: #f0fdf4; color: #15803d; border-right-color: #16a34a !important; }
        .status-rejected      { background: #fef2f2; color: #b91c1c; border-right-color: #dc2626 !important; }
        .status-clarification { background: #eef2ff; color: #4338ca; border-right-color: #4f46e5 !important; }
        .status-awaiting_invoice { background: #f5f3ff; color: #6d28d9; border-right-color: #7c3aed !important; }
        .status-closed        { background: #f8fafc; color: #475569; border-right-color: #94a3b8 !important; }
        .status-draft         { background: #eef2ff; color: #3730a3; border-right-color: #6366f1 !important; }
        .status-submitted     { background: #ecfeff; color: #0e7490; border-right-color: #0891b2 !important; }
        .status-returned      { background: #fff1f2; color: #be123c; border-right-color: #e11d48 !important; }
        .status-signed        { background: #ecfdf5; color: #15803d; border-right-color: #15803d !important; }
        .status-sent_to_accounting { background: #ecfdf5; color: #047857; border-right-color: #047857 !important; }

        .status-pending {
            background: #fff7ed;
            color: #9a3412;
            border-color: #fed7aa;
        }

        .status-approved {
            background: #ecfdf5;
            color: #15803d;
            border-color: #a7f3d0;
        }

        .status-rejected {
            background: #fef2f2;
            color: #b91c1c;
            border-color: #fecaca;
        }

        .status-clarification {
            background: #eef2ff;
            color: #4338ca;
            border-color: #c7d2fe;
        }

        .status-awaiting_invoice {
            background: #f5f3ff;
            color: #6d28d9;
            border-color: #ddd6fe;
        }

        .status-closed {
            background: #f8fafc;
            color: #475569;
            border-color: #e2e8f0;
        }

        .status-draft {
            background: #eef2ff;
            color: #3730a3;
            border-color: #c7d2fe;
        }

        .status-submitted {
            background: #ecfeff;
            color: #0e7490;
            border-color: #a5f3fc;
        }

        .status-returned {
            background: #fff1f2;
            color: #be123c;
            border-color: #fecdd3;
        }

        .status-signed {
            background: #ecfdf5;
            color: #15803d;
            border-color: #a7f3d0;
        }

        .status-sent_to_accounting {
            background: #ecfdf5;
            color: #047857;
            border-color: #6ee7b7;
        }


        .request-meta {
            display: flex;
            gap: 16px;
            flex-wrap: wrap;
            font-size: 13px;
            color: #64748b;
        }

        /* Drawer */
        .drawer-overlay {
            display: none;
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, 0.5);
            z-index: 999;
        }

        .drawer-overlay.active {
            display: block;
        }

        .drawer {
            position: fixed;
            left: 0;
            top: 0;
            bottom: 0;
            width: 600px;
            max-width: 90vw;
            background: white;
            box-shadow: -2px 0 20px rgba(0, 0, 0, 0.2);
            transform: translateX(-100%);
            transition: transform 0.3s;
            z-index: 1000;
            overflow-y: auto;
        }

        .drawer.active {
            transform: translateX(0);
        }

        .drawer-header {
            padding: 24px;
            border-bottom: 1px solid #e2e8f0;
            position: sticky;
            top: 0;
            background: white;
            z-index: 10;
        }

        .drawer-title {
            font-size: 20px;
            font-weight: 700;
            color: #1e293b;
        }

        .drawer-close {
            position: absolute;
            left: 24px;
            top: 24px;
            background: #f1f5f9;
            border: none;
            width: 32px;
            height: 32px;
            border-radius: 50%;
            cursor: pointer;
            font-size: 20px;
        }

        .drawer-content {
            padding: 24px;
        }

        .drawer-tabs {
            display: flex;
            border-bottom: 2px solid #f1f5f9;
            margin-bottom: 24px;
        }

        .drawer-tab {
            padding: 12px 20px;
            cursor: pointer;
            border-bottom: 3px solid transparent;
            margin-bottom: -2px;
            color: #64748b;
            font-weight: 600;
            font-size: 14px;
        }

        .drawer-tab.active {
            color: #667eea;
            border-bottom-color: #667eea;
        }

        .drawer-tab-content {
            display: none;
        }

        .drawer-tab-content.active {
            display: block;
        }

        .info-grid {
            display: grid;
            grid-template-columns: repeat(2, 1fr);
            gap: 16px;
            margin-bottom: 24px;
        }

        .info-box {
            padding: 14px;
            background: #f3f4f6;
            border-radius: 10px;
            border: 1px solid #e5e7eb;
        }

        .conversation-card {
            background: #ffffff;
            border: 1px solid #e2e8f0;
            border-radius: 12px;
            padding: 14px;
            margin-top: 20px;
            box-shadow: 0 2px 6px rgba(15, 23, 42, 0.04);
        }

        .conversation-header {
            font-size: 12px;
            font-weight: 700;
            color: #6b7280;
            margin-bottom: 12px;
            text-transform: uppercase;
            letter-spacing: 0.5px;
            display: flex;
            align-items: center;
            gap: 6px;
        }

        .conversation-thread {
            max-height: 240px;
            overflow-y: auto;
            display: flex;
            flex-direction: column;
            gap: 10px;
            padding-right: 4px;
        }

        .conversation-item {
            background: #f8fafc;
            border: 1px solid #e2e8f0;
            border-radius: 10px;
            padding: 10px 12px;
        }

        .conversation-title {
            font-weight: 600;
            font-size: 13px;
            color: #1f2937;
            margin-bottom: 6px;
        }

        .conversation-details {
            font-size: 13px;
            color: #475569;
            line-height: 1.5;
        }

        .conversation-meta {
            font-size: 11px;
            color: #94a3b8;
            margin-top: 8px;
        }


        .info-box-main {
            min-height: 90px;
            display: flex;
            flex-direction: column;
            justify-content: center;
        }

        /* כרטיס סיכום בדראוור */
        .request-summary-card {
            background: #ffffff;
            border-radius: 16px;
            padding: 18px 20px;
            box-shadow: 0 10px 25px rgba(15, 23, 42, 0.08);
            border: 1px solid #e2e8f0;
            margin-bottom: 24px;
            width: 100% !important;
            max-width: 100% !important;
            margin-right: 0 !important;
            margin-left: 0 !important;
        }

        /* כותרת מוסד */
        .request-summary-header {
            margin-bottom: 12px;
        }

        .request-summary-main-title {
            display: flex;
            flex-direction: column;
            gap: 4px;
        }

        .request-summary-title {
            font-size: 19px;
            font-weight: 800;
            color: #0f172a;
        }

        .request-summary-subtitle {
            font-size: 13px;
            color: #6b7280;
        }

        /* סרגל סטטוס + תאריך */
        .request-top-bar {
            margin-top: 8px;
            padding: 8px 12px;
            border-radius: 999px;
            background: #f8fafc;
            border: 1px solid #e2e8f0;
            display: inline-flex;
            align-items: center;
            gap: 8px;
            flex-wrap: wrap;
        }

        .request-top-bar .status-badge {
            font-size: 13px;
            padding: 6px 14px;
            border-radius: 999px;
            box-shadow: 0 0 0 1px rgba(148, 163, 184, 0.45);
        }

        .date-pill {
            display: inline-flex;
            align-items: center;
            gap: 4px;
            padding: 4px 10px;
            border-radius: 999px;
            background: #eff6ff;
            font-size: 12px;
            color: #1f2933;
        }

        /* תגיות מידע */
        .request-summary-tags {
            display: flex;
            flex-wrap: wrap;
            gap: 8px;
            margin: 12px 0 20px;
            padding: 12px;
            background: #f9fafb;
            border-radius: 12px;
            border: 1px solid #e5e7eb;
        }

        .summary-tag {
            font-size: 12px;
            padding: 6px 10px;
            border-radius: 999px;
            background: #eef2ff;
            color: #0f172a;
            display: inline-flex;
            align-items: center;
            gap: 4px;
            font-weight: 600;
            transition: transform 0.15s, box-shadow 0.15s;
        }

        .summary-tag:hover {
            transform: translateY(-1px);
            box-shadow: 0 2px 6px rgba(15, 23, 42, 0.08);
        }

        .summary-tag-urgent {
            background: #fee2e2;
            color: #b91c1c;
        }

        .summary-tag-high {
            background: #fef3c7;
            color: #92400e;
        }

        .summary-tag-normal {
            background: #e0f2fe;
            color: #075985;
        }

        .summary-tag-info {
            background: #eef2ff;
            color: #0f172a;
        }

        /* כרטיסי מידע למגיש וסכום - אותו גודל */
        .request-meta-row {
            display: flex;
            gap: 16px;
            margin-bottom: 16px;
            flex-wrap: wrap;
        }

        .request-meta-box {
            flex: 1;
            min-width: 220px;
            background: #f9fafb;
            border-radius: 12px;
            border: 1px solid #e2e8f0;
            padding: 14px;
        }

        /* כותרות אזור */
        .section-title {
            font-size: 13px;
            font-weight: 700;
            color: #64748b;
            margin: 4px 0 10px;
        }

        /* תיאור */
        .description-box {
            margin-top: 8px;
            padding: 14px 16px;
            background: #f3f4f6;
            border-radius: 12px;
            border: 1px solid #e5e7eb;
            font-size: 14px;
            line-height: 1.9;
            color: #374151;
        }

        /* קופסת סה"כ */
        .info-box-total {
            background: #ecfdf5;
            border: 2px solid #86efac;
        }

        /* טקסטי מידע */
        .info-muted {
            font-size: 11px;
            color: #94a3b8;
        }

        .info-label {
            font-size: 12px;
            color: #64748b;
        }

        .info-value {
            font-size: 15px;
            font-weight: 600;
            color: #1e293b;
            margin-top: 4px;
            line-height: 1.6;
        }

        /* שמירת התמיכה למקומות אחרים בקוד שלך */
        .description-text {
            font-size: 14px;
            line-height: 1.8;
            font-weight: 400;
            color: #374151;
        }

        .info-box.description-box {
            background: #f3f4f6 !important;
            border: 1px solid #e5e7eb;
        }


        /* Comments */
        .comment-form {
            background: #f8fafc;
            padding: 16px;
            border-radius: 8px;
            margin-bottom: 20px;
        }

        .comment-item {
            background: white;
            border: 1px solid #e2e8f0;
            padding: 16px;
            border-radius: 8px;
            margin-bottom: 12px;
        }

        .comment-item.internal {
            background: #fef3c7;
        }

        .comment-header {
            display: flex;
            justify-content: space-between;
            margin-bottom: 8px;
        }

        .comment-author {
            font-weight: 600;
            font-size: 14px;
        }

        .comment-text {
            font-size: 14px;
            color: #475569;
            line-height: 1.7;
        }

        /* Modal */
        .modal {
            display: none;
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, 0.5);
            align-items: center;
            justify-content: center;
            z-index: 10000;
        }

        .modal.active {
            display: flex;
        }

        .modal-content {
            background: white;
            padding: 32px;
            border-radius: 12px;
            max-width: 600px;
            width: 90%;
            max-height: 85vh;
            overflow-y: auto;
            position: relative;
            z-index: 10001;
        }

        .modal-header {
            display: flex;
            justify-content: space-between;
            margin-bottom: 24px;
            padding-bottom: 16px;
            border-bottom: 1px solid #e2e8f0;
        }

        .modal-title {
            font-size: 20px;
            font-weight: 700;
        }

        /* Toast */
        .toast-container {
            position: fixed;
            top: 20px;
            left: 50%;
            transform: translateX(-50%);
            z-index: 9999;
        }

        .toast {
            background: white;
            padding: 16px 24px;
            border-radius: 8px;
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
            margin-bottom: 12px;
            display: flex;
            gap: 12px;
            min-width: 300px;
        }

        .toast.success {
            border-right: 3px solid #10b981;
        }

        .toast.error {
            border-right: 3px solid #ef4444;
        }

        .toast.info {
            border-right: 3px solid #3b82f6;
        }

        .loading-overlay {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: rgba(0, 0, 0, 0.5);
            display: none;
            align-items: center;
            justify-content: center;
            z-index: 10000;
        }

        .loading-overlay.active {
            display: flex;
        }

        .loading-spinner {
            width: 60px;
            height: 60px;
            border: 6px solid #f3f4f6;
            border-top: 6px solid #667eea;
            border-radius: 50%;
            animation: spin 1s linear infinite;
        }

        @keyframes spin {
            0% {
                transform: rotate(0deg);
            }

            100% {
                transform: rotate(360deg);
            }
        }

        @keyframes slideIn {
            from {
                opacity: 0;
                transform: translateY(-10px);
            }

            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        .alert-card {
            background: #fef3c7;
            border-right: 3px solid #f59e0b;
            padding: 16px;
            border-radius: 8px;
            margin-bottom: 12px;
            cursor: pointer;
        }

        .alert-card:hover {
            background: #fde68a;
        }

        .alert-title {
            font-weight: 600;
            font-size: 14px;
            color: #92400e;
            margin-bottom: 4px;
        }

        .alert-text {
            font-size: 13px;
            color: #92400e;
        }

        .request-drop-zone {
            border: 1.5px dashed #cbd5e1;
            border-radius: 10px;
            padding: 14px 16px;
            min-height: 86px;
            display: flex;
            align-items: center;
            gap: 12px;
            cursor: pointer;
            background: #f8fafc;
            transition: all .2s ease;
        }

        .request-drop-zone:hover,
        .request-drop-zone.is-dragover {
            border-color: #667eea;
            background: #eef2ff;
        }

        .request-drop-zone-icon {
            font-size: 24px;
            line-height: 1;
            flex-shrink: 0;
        }

        .request-drop-zone-text {
            color: #334155;
            font-weight: 600;
            font-size: 13px;
            margin-bottom: 2px;
        }

        .request-drop-zone-hint {
            font-size: 11px;
            color: #94a3b8;
        }

        /* Upload Progress */
        .upload-queue {
            margin-top: 10px;
            width: 100%;
            display: flex;
            flex-direction: column;
            gap: 8px;
            max-height: 300px;
            overflow-y: auto;
        }

        .upload-item {
            padding: 10px 12px;
            background: white;
            border: 1px solid #e2e8f0;
            border-radius: 8px;
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 12px;
            margin-bottom: 0;
        }

        .upload-item-meta {
            min-width: 0;
            flex: 1;
        }

        .upload-item-name {
            font-size: 13px;
            color: #1e293b;
            font-weight: 600;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .upload-item-sub {
            margin-top: 2px;
            font-size: 11px;
            color: #64748b;
        }

        .upload-item-status {
            font-size: 11px;
            font-weight: 700;
            color: #4f46e5;
            background: #eef2ff;
            border-radius: 999px;
            padding: 3px 8px;
            white-space: nowrap;
        }

        .upload-item-status.status-existing {
            background: #f1f5f9;
            color: #475569;
        }

        .upload-item-remove {
            border: none;
            background: #fee2e2;
            color: #b91c1c;
            width: 24px;
            height: 24px;
            border-radius: 6px;
            font-weight: 700;
            cursor: pointer;
            line-height: 1;
            flex-shrink: 0;
        }

        .upload-progress {
            width: 100%;
            height: 6px;
            background: #e2e8f0;
            border-radius: 3px;
            margin-top: 8px;
            overflow: hidden;
        }

        .upload-progress-bar {
            height: 100%;
            background: linear-gradient(90deg, #667eea, #764ba2);
            transition: width 0.3s;
            border-radius: 3px;
        }

        /* Skeleton Loaders */
        .skeleton {
            background: linear-gradient(90deg,
                    #f0f0f0 25%,
                    #e0e0e0 50%,
                    #f0f0f0 75%);
            background-size: 200% 100%;
            animation: loading 1.5s infinite;
            border-radius: 8px;
        }

        @keyframes loading {
            0% {
                background-position: 200% 0;
            }

            100% {
                background-position: -200% 0;
            }
        }

        @keyframes pulse {

            0%,
            100% {
                opacity: 1;
            }

            50% {
                opacity: 0.7;
            }
        }

        .skeleton-card {
            height: 120px;
            margin-bottom: 12px;
        }

        .skeleton-text {
            height: 16px;
            margin-bottom: 8px;
        }

        /* Pagination */
        .pagination {
            display: flex;
            justify-content: center;
            gap: 8px;
            margin-top: 20px;
            flex-wrap: wrap;
        }

        .pagination button {
            padding: 8px 12px;
            border: 1px solid #e2e8f0;
            background: white;
            border-radius: 6px;
            cursor: pointer;
            font-size: 13px;
            transition: all 0.2s;
        }

        .pagination button:hover:not(:disabled) {
            border-color: #667eea;
            color: #667eea;
        }

        .pagination button.active {
            background: #667eea;
            color: white;
            border-color: #667eea;
        }

        .pagination button:disabled {
            opacity: 0.5;
            cursor: not-allowed;
        }

        /* ── Confirm / Prompt Modal ── */
        .confirm-modal-box {
            background: white;
            border-radius: 14px;
            padding: 28px;
            width: 90%;
            max-width: 420px;
            box-shadow: 0 20px 60px rgba(0,0,0,0.25);
        }

        .confirm-modal-title {
            font-size: 17px;
            font-weight: 700;
            color: #1e293b;
            margin-bottom: 10px;
        }

        .confirm-modal-message {
            font-size: 14px;
            color: #64748b;
            line-height: 1.65;
            margin-bottom: 20px;
            white-space: pre-wrap;
        }

        .prompt-modal-title {
            font-size: 17px;
            font-weight: 700;
            color: #1e293b;
            margin-bottom: 8px;
        }

        .prompt-modal-message {
            font-size: 14px;
            color: #64748b;
            margin-bottom: 12px;
        }

        .confirm-modal-actions {
            display: flex;
            gap: 8px;
            justify-content: flex-end;
        }

        /* ── Bulk checkbox ── */
        .bulk-checkbox {
            width: 20px !important;
            height: 20px !important;
            cursor: pointer;
            accent-color: #6366f1;
            flex-shrink: 0;
        }

        /* ── Empty state ── */
        .empty-state {
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            padding: 56px 24px;
            color: #94a3b8;
            text-align: center;
            gap: 12px;
        }

        .empty-state-icon {
            width: 34px;
            height: 34px;
            min-width: 34px;
            min-height: 34px;
            opacity: 0.55;
            stroke-width: 1.8;
        }

        .empty-state-title {
            font-size: 16px;
            font-weight: 600;
            color: #64748b;
        }

        .empty-state-subtitle {
            font-size: 13px;
            color: #94a3b8;
            margin-top: -4px;
        }

        /* ── Select All header row ── */
        .bulk-select-all-row {
            display: flex;
            align-items: center;
            gap: 10px;
            padding: 8px 16px 10px;
            border-bottom: 1px solid #f1f5f9;
            font-size: 13px;
            color: #64748b;
        }

        /* ── Filter count badge ── */
        .filter-result-count {
            font-size: 12px;
            color: #64748b;
            padding: 3px 10px;
            background: #f1f5f9;
            border-radius: 999px;
            font-weight: 500;
        }

        /* ── 1024px sidebar collapse ── */
        @media (max-width: 1024px) {
            .sidebar {
                width: 220px;
            }

            .sidebar-header h2 {
                font-size: 14px;
            }

            .stats-grid {
                grid-template-columns: repeat(2, 1fr);
            }

            .request-form-grid {
                grid-template-columns: repeat(2, minmax(0, 1fr));
                gap: 12px;
            }

            .request-field--title {
                grid-column: 1 / -1;
                order: 1;
            }

            .request-field--institution {
                order: 2;
            }

            .request-field--category {
                order: 3;
            }

            .request-field--urgency {
                order: 4;
            }

            .request-field--quantity {
                order: 5;
            }

            .request-field--institution,
            .request-field--category,
            .request-field--urgency,
            .request-field--quantity {
                grid-column: span 1;
            }

            .sidebar-item {
                font-size: 13px;
                padding: 10px 16px;
            }
        }

        @media (max-width: 768px) {
            .main-app.active {
                flex-direction: column;
            }

            .sidebar {
                position: fixed;
                top: 0;
                right: 0;
                left: 0;
                bottom: auto;
                width: 100%;
                height: auto;
                padding: 8px 10px;
                z-index: 35;
                box-shadow: 0 6px 18px rgba(15, 23, 42, 0.18);
                backdrop-filter: blur(8px);
            }

            .sidebar-header {
                display: none;
            }

            .sidebar-menu {
                display: flex;
                gap: 8px;
                padding: 0;
                overflow-x: auto;
                -webkit-overflow-scrolling: touch;
                scrollbar-width: none;
                scroll-snap-type: x proximity;
                align-items: center;
            }

            .sidebar-menu::-webkit-scrollbar {
                display: none;
            }

            .sidebar-item {
                padding: 8px 12px;
                border-radius: 999px;
                white-space: nowrap;
                font-size: 13px;
                scroll-snap-align: start;
                border: 1px solid rgba(255, 255, 255, 0.18);
                flex: 0 0 auto;
            }

            .sidebar-footer {
                display: none;
            }

            .main-content {
                margin-right: 0;
                padding: 74px 12px 12px;
            }

            .top-bar {
                padding: 14px 14px;
                margin-bottom: 12px;
            }

            .content-card {
                padding: 14px;
                border-radius: 10px;
                margin-bottom: 12px;
            }

            #newRequestSection .content-card {
                padding: 16px 14px !important;
            }
            #newRequestSection .top-bar,
            #newRequestSection #requestEditBanner,
            #newRequestSection #requestForm {
                width: 100%;
            }


            .request-form-grid {
                grid-template-columns: 1fr;
                gap: 10px;
            }

            .request-field--title,
            .request-field--institution,
            .request-field--category,
            .request-field--urgency,
            .request-field--quantity {
                grid-column: span 1;
            }

            .request-field--title {
                order: 1;
            }

            .request-field--institution {
                order: 2;
            }

            .request-field--category {
                order: 3;
            }

            .request-field--urgency {
                order: 4;
            }

            .request-field--quantity {
                order: 5;
            }

            .notifications-bell {
                width: 44px;
                height: 44px;
                top: auto;
                left: 14px;
                right: auto;
                bottom: calc(14px + env(safe-area-inset-bottom, 0px));
                z-index: 60;
            }

            .notifications-panel {
                width: min(92vw, 380px);
            }

            body.impersonating .notifications-bell {
                top: auto;
                bottom: calc(14px + env(safe-area-inset-bottom, 0px));
            }

            .request-submit-bar {
                position: static;
                margin: 8px 0 0 !important;
                padding: 16px 0 0 !important;
                border-top: 1px solid #e2e8f0 !important;
                background: transparent;
            }

            .request-submit-bar .btn {
                width: min(100%, 320px);
                min-width: 220px;
                max-width: 320px;
                min-height: 48px;
                font-size: 16px;
            }

            .stats-grid {
                grid-template-columns: 1fr;
            }

            .dashboard-grid {
                grid-template-columns: 1fr;
            }

            .drawer {
                width: 100%;
            }
        }

        /* ── SHC Credit Footer ── */
        .shc-footer {
            display: flex;
            align-items: center;
            justify-content: center;
            width: 100%;
            padding: 16px 0 8px;
            margin-top: 20px;
        }

        .login-screen {
            position: relative;
        }

        /* ═══ Entity Picker & Super-Admin Landing ════════════════════════════ */

        .ep-screen {
            display: flex;
            align-items: center;
            justify-content: center;
            min-height: 100vh;
            background: linear-gradient(140deg, #dfe6ef 0%, #edf2f8 50%, #d6e0ec 100%);
            padding: 20px 20px 60px;
            position: relative;
            flex-direction: column;
        }

        .ep-container {
            background: rgba(255,255,255,0.97);
            backdrop-filter: blur(6px);
            border-radius: 20px;
            border: 1px solid #dbe6ff;
            box-shadow: 0 24px 64px rgba(47,79,127,0.16);
            padding: 40px 36px 28px;
            width: 100%;
            max-width: 480px;
        }

        .sa-landing-container {
            background: rgba(255,255,255,0.97);
            backdrop-filter: blur(6px);
            border-radius: 20px;
            border: 1px solid #dbe6ff;
            box-shadow: 0 24px 64px rgba(47,79,127,0.16);
            padding: 40px 36px 28px;
            width: 100%;
            max-width: 580px;
        }

        .ep-header {
            text-align: center;
            margin-bottom: 24px;
        }

        .ep-user-avatar {
            width: 60px;
            height: 60px;
            border-radius: 50%;
            background: linear-gradient(135deg, #2f4f7f, #4a6fa5);
            color: white;
            font-size: 24px;
            font-weight: 700;
            display: flex;
            align-items: center;
            justify-content: center;
            margin: 0 auto 14px;
            box-shadow: 0 6px 20px rgba(47,79,127,0.28);
        }

        .sa-avatar-gold {
            background: linear-gradient(135deg, #d97706, #f59e0b) !important;
            box-shadow: 0 6px 20px rgba(217,119,6,0.3) !important;
        }

        .sa-role-badge {
            display: inline-flex;
            align-items: center;
            gap: 4px;
            padding: 3px 12px;
            border-radius: 99px;
            background: linear-gradient(135deg, #d97706, #f59e0b);
            color: white;
            font-size: 11px;
            font-weight: 700;
            letter-spacing: 0.5px;
            margin-bottom: 12px;
        }

        .ep-greeting {
            font-size: 20px;
            font-weight: 700;
            color: #1e293b;
            margin-bottom: 4px;
        }

        .ep-subtitle {
            font-size: 13px;
            color: #64748b;
            margin: 0;
        }

        /* ── Entity list (shared by picker & SA landing) ── */
        .ep-list {
            display: flex;
            flex-direction: column;
            gap: 8px;
            max-height: 340px;
            overflow-y: auto;
            margin-bottom: 14px;
            padding-left: 2px;
        }

        /* 2-column grid in super-admin landing */
        .sa-entity-grid {
            display: grid;
            grid-template-columns: 1fr 1fr;
            max-height: 280px;
        }

        /* ── Entity card ── */
        .entity-card {
            display: flex;
            align-items: center;
            gap: 12px;
            padding: 14px 16px;
            border-radius: 12px;
            border: 1.5px solid #e8edf5;
            background: #fff;
            cursor: pointer;
            text-align: right;
            width: 100%;
            transition: border-color 0.16s, box-shadow 0.16s, transform 0.12s, background 0.16s;
        }

        .entity-card:hover {
            border-color: #2f4f7f;
            box-shadow: 0 4px 18px rgba(47,79,127,0.12);
            transform: translateY(-2px);
            background: #f7faff;
        }

        .entity-card:active {
            transform: translateY(0);
            box-shadow: none;
        }

        /* Body appears on the RIGHT in RTL (first in DOM, RTL flex = rightmost) */
        .entity-card-body {
            flex: 1;
            min-width: 0;
        }

        .entity-card-name {
            font-size: 15px;
            font-weight: 700;
            color: #1e293b;
            margin-bottom: 5px;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            line-height: 1.3;
        }

        .entity-card-badge {
            display: inline-flex;
            align-items: center;
            padding: 3px 10px;
            border-radius: 99px;
            font-size: 11px;
            font-weight: 600;
        }

        /* Icon appears on the LEFT in RTL (last in DOM, RTL flex = leftmost) */
        .entity-card-icon {
            width: 40px;
            height: 40px;
            border-radius: 10px;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 17px;
            font-weight: 700;
            color: white;
            flex-shrink: 0;
            transition: transform 0.16s;
        }

        .entity-card:hover .entity-card-icon {
            transform: scale(1.06);
        }

        /* Grid-variant: compact column tiles for super-admin landing */
        .sa-entity-grid .entity-card {
            flex-direction: column;
            align-items: flex-start;
            gap: 8px;
            padding: 14px;
            min-height: 90px;
        }

        .sa-entity-grid .entity-card-body { order: 2; }
        .sa-entity-grid .entity-card-icon {
            order: 1;
            width: 36px;
            height: 36px;
            font-size: 15px;
            transform: none !important;
        }

        /* ── Super-admin global mode card ── */
        .sa-global-card {
            display: flex;
            align-items: center;
            gap: 14px;
            padding: 18px 20px;
            border-radius: 14px;
            border: 2px solid #2f4f7f;
            background: linear-gradient(135deg, #f5f8ff, #eef2ff);
            cursor: pointer;
            text-align: right;
            width: 100%;
            margin-bottom: 4px;
            transition: box-shadow 0.16s, transform 0.12s, background 0.16s;
        }

        .sa-global-card:hover {
            box-shadow: 0 6px 24px rgba(47,79,127,0.18);
            transform: translateY(-2px);
            background: linear-gradient(135deg, #eef2ff, #e0e7ff);
        }

        .sa-global-card:active { transform: translateY(0); }

        .sa-global-card-icon {
            width: 50px;
            height: 50px;
            border-radius: 12px;
            background: linear-gradient(135deg, #2f4f7f, #4a6fa5);
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 22px;
            flex-shrink: 0;
        }

        .sa-global-card-body { flex: 1; text-align: right; }

        .sa-global-card-title {
            font-size: 15px;
            font-weight: 700;
            color: #1e293b;
            margin-bottom: 2px;
        }

        .sa-global-card-desc {
            font-size: 12px;
            color: #64748b;
        }

        .sa-global-card-arrow {
            color: #94a3b8;
            transition: transform 0.16s, color 0.16s;
        }

        .sa-global-card:hover .sa-global-card-arrow {
            transform: translateX(-3px);
            color: #2f4f7f;
        }

        .sa-divider {
            display: flex;
            align-items: center;
            gap: 10px;
            margin: 16px 0 12px;
            color: #94a3b8;
            font-size: 12px;
            font-weight: 500;
        }

        .sa-divider::before,
        .sa-divider::after {
            content: '';
            flex: 1;
            height: 1px;
            background: #e2e8f0;
        }

        /* ── Sign-out button for picker/landing ── */
        .ep-signout-btn {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 6px;
            width: 100%;
            padding: 9px;
            border: none;
            background: none;
            color: #94a3b8;
            font-size: 13px;
            cursor: pointer;
            border-radius: 8px;
            transition: color 0.14s, background 0.14s;
            margin-top: 4px;
        }

        .ep-signout-btn:hover {
            color: #ef4444;
            background: #fef2f2;
        }

        /* ═══ Sidebar Entity Chip ════════════════════════════════════════════ */
        .sidebar-entity-chip {
            display: flex;
            align-items: center;
            gap: 10px;
            padding: 9px 12px;
            margin-bottom: 10px;
            border-radius: 10px;
            background: rgba(255,255,255,0.08);
            border: 1px solid rgba(255,255,255,0.12);
            cursor: pointer;
            user-select: none;
            transition: background 0.15s, border-color 0.15s;
        }

        .sidebar-entity-chip:hover {
            background: rgba(255,255,255,0.14);
            border-color: rgba(255,255,255,0.25);
        }

        .sec-icon {
            width: 30px;
            height: 30px;
            border-radius: 7px;
            background: rgba(255,255,255,0.15);
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 13px;
            font-weight: 700;
            color: white;
            flex-shrink: 0;
        }

        .sec-body {
            flex: 1;
            min-width: 0;
        }

        .sec-label {
            display: block;
            font-size: 9.5px;
            color: rgba(255,255,255,0.45);
            font-weight: 600;
            text-transform: uppercase;
            letter-spacing: 0.7px;
            margin-bottom: 1px;
        }

        .sec-name {
            display: block;
            font-size: 12.5px;
            color: rgba(255,255,255,0.9);
            font-weight: 600;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .sec-switch-icon {
            color: rgba(255,255,255,0.38);
            flex-shrink: 0;
            transition: color 0.15s;
        }

        .sidebar-entity-chip:hover .sec-switch-icon {
            color: rgba(255,255,255,0.75);
        }

        .login-shc-footer {
            position: absolute;
            bottom: 16px;
            left: 0;
            right: 0;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .shc-footer-btn {
            display: inline-flex;
            align-items: center;
            gap: 10px;
            padding: 6px 14px;
            border: none;
            background: transparent;
            border-radius: 100px;
            cursor: pointer;
            font-size: 12px;
            font-weight: 500;
            color: #b0bac5;
            transition: color 0.2s, transform 0.2s;
            direction: ltr;
        }

        .shc-footer-btn:hover {
            color: #64748b;
            transform: translateY(-1px);
        }

        .shc-footer-logo {
            height: 24px;
            width: 24px;
            object-fit: contain;
            opacity: 0.6;
            filter: drop-shadow(0 2px 6px rgba(47, 79, 127, 0.2));
            transition: transform 0.3s, opacity 0.2s;
        }

        .shc-footer-btn:hover .shc-footer-logo {
            transform: scale(1.12);
            opacity: 0.9;
        }

        /* ── SHC Modal ── */
        .shc-modal-overlay {
            display: none;
            position: fixed;
            inset: 0;
            z-index: 9999;
            align-items: center;
            justify-content: center;
            background: rgba(15, 23, 42, 0.88);
            backdrop-filter: blur(14px);
            padding: 20px;
        }

        .shc-modal-overlay.active {
            display: flex;
        }

        .shc-modal {
            position: relative;
            width: 100%;
            max-width: 420px;
            overflow: hidden;
            border-radius: 20px;
            border: 1px solid rgba(255, 255, 255, 0.12);
            background: rgba(15, 23, 42, 0.96);
            box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.6);
            backdrop-filter: blur(28px);
        }

        .shc-modal-close {
            position: absolute;
            left: 16px;
            top: 16px;
            display: flex;
            align-items: center;
            justify-content: center;
            width: 36px;
            height: 36px;
            border-radius: 50%;
            border: none;
            background: transparent;
            color: #64748b;
            font-size: 26px;
            line-height: 1;
            cursor: pointer;
            transition: background 0.2s, color 0.2s;
            z-index: 1;
        }

        .shc-modal-close:hover {
            background: rgba(255, 255, 255, 0.1);
            color: #fff;
        }

        .shc-modal-header {
            border-bottom: 1px solid rgba(255, 255, 255, 0.1);
            background: radial-gradient(circle at top, rgba(59, 130, 246, 0.2), transparent 60%);
            padding: 28px 28px 20px;
            text-align: center;
        }

        .shc-modal-logo-wrap {
            display: flex;
            align-items: center;
            justify-content: center;
            width: 76px;
            height: 76px;
            border-radius: 22px;
            background: rgba(255, 255, 255, 0.1);
            box-shadow: 0 16px 40px rgba(30, 41, 59, 0.25);
            outline: 1px solid rgba(255, 255, 255, 0.15);
            margin: 0 auto 16px;
        }

        .shc-modal-logo {
            width: 46px;
            height: 46px;
            object-fit: contain;
            filter: drop-shadow(0 6px 18px rgba(59, 130, 246, 0.22));
            transform: scale(1.3);
        }

        .shc-modal-title {
            font-size: 22px;
            font-weight: 600;
            color: #fff;
            letter-spacing: -0.3px;
            margin: 0;
        }

        .shc-modal-tagline {
            margin-top: 8px;
            font-size: 14px;
            line-height: 1.6;
            color: #94a3b8;
        }

        .shc-modal-body {
            display: flex;
            flex-direction: column;
            align-items: center;
            padding: 24px 28px;
            text-align: center;
        }

        .shc-email-box {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 10px;
            width: 100%;
            max-width: 340px;
            overflow: hidden;
            border-radius: 14px;
            border: 1px solid rgba(255, 255, 255, 0.1);
            background: rgba(255, 255, 255, 0.05);
            padding: 14px 18px;
            font-size: 14px;
            font-family: monospace;
            letter-spacing: 0.3px;
            color: #fff;
            margin-bottom: 16px;
        }

        .shc-email-copy-btn {
            display: flex;
            align-items: center;
            justify-content: center;
            width: 36px;
            height: 36px;
            border-radius: 50%;
            border: none;
            background: rgba(255, 255, 255, 0.1);
            color: #cbd5e1;
            cursor: pointer;
            flex-shrink: 0;
            transition: background 0.2s, color 0.2s, transform 0.2s;
        }

        .shc-email-copy-btn:hover {
            background: rgba(255, 255, 255, 0.18);
            color: #fff;
            transform: translateY(-1px);
        }

        .shc-email-copy-btn svg,
        .shc-btn-send svg,
        .shc-btn-copy svg {
            width: 16px;
            height: 16px;
        }

        .shc-modal-actions {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 10px;
            width: 100%;
            max-width: 340px;
        }

        .shc-btn-send {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            padding: 12px 16px;
            border-radius: 14px;
            border: none;
            background: linear-gradient(135deg, #3b82f6, #6366f1);
            color: #fff;
            font-size: 14px;
            font-weight: 600;
            cursor: pointer;
            box-shadow: 0 12px 28px rgba(59, 130, 246, 0.25);
            transition: transform 0.2s, filter 0.2s;
        }

        .shc-btn-send:hover {
            transform: translateY(-2px);
            filter: brightness(1.1);
        }

        .shc-btn-copy {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            padding: 12px 16px;
            border-radius: 14px;
            border: 1px solid rgba(255, 255, 255, 0.15);
            background: rgba(255, 255, 255, 0.1);
            color: #fff;
            font-size: 14px;
            font-weight: 600;
            cursor: pointer;
            transition: background 0.2s, transform 0.2s;
        }

        .shc-btn-copy:hover {
            background: rgba(255, 255, 255, 0.18);
            transform: translateY(-2px);
        }

        /* ── SHC Toast ── */
        .shc-toast {
            display: none;
            position: fixed;
            bottom: 24px;
            left: 50%;
            transform: translateX(-50%);
            z-index: 10000;
            align-items: center;
            gap: 8px;
            padding: 10px 20px;
            border-radius: 100px;
            border: 1px solid rgba(59, 130, 246, 0.2);
            background: rgba(255, 255, 255, 0.96);
            font-size: 13px;
            font-weight: 500;
            color: #2563eb;
            box-shadow: 0 10px 15px -3px rgba(15, 23, 42, 0.1);
            backdrop-filter: blur(16px);
            white-space: nowrap;
        }

        .shc-toast.active {
            display: flex;
            animation: shcFadeUp 0.35s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
        }

        .shc-toast svg {
            width: 15px;
            height: 15px;
        }

        @keyframes shcFadeUp {
            from {
                opacity: 0;
                transform: translateX(-50%) translateY(12px);
            }
            to {
                opacity: 1;
                transform: translateX(-50%) translateY(0);
            }
        }

        /* ============================================================
           KANBAN BOARD
        ============================================================ */

        /* wrapper — מאפשר גלילה פנימית בלי לגלוש מהמסך */
        .kanban-board {
            width: 100%;
            overflow-x: auto;
            overflow-y: visible;
            padding-bottom: 16px;
        }

        /* שורת העמודות עצמה */
        .kanban-board-inner {
            display: grid;
            grid-template-columns: repeat(5, minmax(0, 1fr));
            gap: 12px;
            min-width: 700px;  /* כדי שלא יידחס מדי על מסכים קטנים */
            align-items: start;
        }

        .kanban-column {
            background: #fff;
            border-radius: 14px;
            border: 1px solid #e8edf5;
            box-shadow: 0 2px 8px rgba(15,23,42,.06);
            overflow: hidden;
            display: flex;
            flex-direction: column;
        }

        .kanban-column-header {
            padding: 11px 14px;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }

        .kanban-col-label {
            font-weight: 700;
            font-size: 13px;
        }

        .kanban-count {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            min-width: 22px;
            height: 22px;
            border-radius: 11px;
            font-size: 11px;
            font-weight: 700;
            color: #fff;
            padding: 0 6px;
            box-shadow: 0 1px 4px rgba(0,0,0,.15);
        }

        .kanban-cards-list {
            flex: 1;
            padding: 8px;
            display: flex;
            flex-direction: column;
            gap: 7px;
            min-height: 64px;
            transition: background 0.15s;
        }

        .kanban-cards-list.drag-over {
            background: rgba(99,102,241,.08);
            border-radius: 8px;
            outline: 2px dashed #a5b4fc;
            outline-offset: -2px;
        }

        .kanban-card {
            background: #fff;
            border: 1px solid #e8edf5;
            border-right: 3px solid var(--k-accent, #94a3b8);
            border-radius: 10px;
            padding: 11px 12px;
            cursor: pointer;
            transition: box-shadow 0.15s, transform 0.12s;
            user-select: none;
            box-shadow: 0 1px 4px rgba(15,23,42,.05);
        }

        .kanban-card:hover {
            box-shadow: 0 4px 14px rgba(15,23,42,.12);
            transform: translateY(-2px);
        }

        .kanban-card[draggable=true] { cursor: grab; }
        .kanban-card[draggable=true]:active { cursor: grabbing; }

        .kanban-card-title {
            font-weight: 600;
            font-size: 13px;
            color: #1e293b;
            margin-bottom: 5px;
            line-height: 1.4;
        }

        .kanban-card-inst {
            display: flex;
            align-items: center;
            gap: 4px;
            font-size: 11px;
            color: #64748b;
            margin-bottom: 8px;
        }

        .kanban-card-footer {
            display: flex;
            justify-content: space-between;
            align-items: center;
            gap: 4px;
        }

        .kanban-card-amount {
            font-size: 12px;
            font-weight: 700;
            color: var(--k-accent, #4f46e5);
        }

        .kanban-urgency-badge {
            display: inline-block;
            padding: 1px 7px;
            border-radius: 10px;
            font-size: 10px;
            font-weight: 600;
        }

        .kanban-card-date {
            font-size: 10px;
            color: #94a3b8;
        }

        .kanban-empty {
            text-align: center;
            padding: 24px 12px;
            font-size: 12px;
            color: #cbd5e1;
        }

        /* skeleton טעינה */
        .kanban-skeleton {
            height: 72px;
            border-radius: 10px;
            background: linear-gradient(90deg, #f1f5f9 25%, #e8edf5 50%, #f1f5f9 75%);
            background-size: 200% 100%;
            animation: kanbanShimmer 1.4s infinite;
        }

        @keyframes kanbanShimmer {
            0%   { background-position: 200% 0; }
            100% { background-position: -200% 0; }
        }

        /* ============================================================
           GANTT CHART (compact table style)
        ============================================================ */
        .gt-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 12px;
        }

        .gt-scroll {
            overflow-x: auto;
            border: 1px solid #e2e8f0;
            border-radius: 10px;
        }

        .gt-table {
            width: 100%;
            border-collapse: collapse;
            min-width: 780px;
        }

        .gt-table thead tr {
            background: #1e293b;
        }

        .gt-table thead th {
            padding: 8px 4px;
            font-size: 11px;
            font-weight: 600;
            color: #94a3b8;
            text-align: center;
            border-left: 1px solid #334155;
        }

        .gt-table thead th:first-child {
            text-align: right;
            padding: 8px 14px;
            color: #fff;
            border-left: none;
            width: 190px;
        }

        th.gt-mhdr.gt-cur {
            color: #fff;
            background: rgba(79,70,229,.35);
        }

        th.gt-total-hdr {
            width: 110px;
            color: #fff;
        }

        .gt-row {
            border-bottom: 1px solid #f1f5f9;
        }

        .gt-row:hover { background: #f8fafc; }
        .gt-row:last-child { border-bottom: none; }

        .gt-name {
            padding: 8px 14px;
            background: #f8fafc;
            border-left: 1px solid #e2e8f0;
            vertical-align: middle;
            min-width: 160px;
        }

        .gt-row:hover .gt-name { background: #eef2ff; }

        .gt-name-text {
            font-size: 13px;
            font-weight: 600;
            color: #1e293b;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            max-width: 170px;
        }

        .gt-name-meta {
            font-size: 11px;
            color: #94a3b8;
            margin-top: 2px;
        }

        .gt-cell {
            padding: 4px 3px;
            border-left: 1px solid #f1f5f9;
            text-align: center;
            vertical-align: bottom;
            height: 44px;
        }

        .gt-cell.gt-cur { background: rgba(79,70,229,.04); }

        .gt-bar {
            width: 70%;
            margin: 0 auto;
            border-radius: 3px 3px 0 0;
            min-height: 4px;
            transition: height 0.3s ease;
        }

        .gt-total {
            padding: 8px 12px;
            border-left: 1px solid #e2e8f0;
            vertical-align: middle;
        }

        .gt-total-bar {
            height: 6px;
            background: #e2e8f0;
            border-radius: 3px;
            overflow: hidden;
            margin-bottom: 4px;
        }

        .gt-total-fill {
            height: 100%;
            border-radius: 3px;
            transition: width 0.4s ease;
        }

        .gt-total-pct {
            font-size: 12px;
            font-weight: 700;
        }

        .gt-legend {
            display: flex;
            gap: 16px;
            align-items: center;
            margin-top: 10px;
            font-size: 12px;
            color: #64748b;
            flex-wrap: wrap;
        }

        .gt-dot {
            display: inline-block;
            width: 10px;
            height: 10px;
            border-radius: 2px;
            margin-left: 4px;
            vertical-align: middle;
        }

        /* ============================================================
           NOTIFICATION FILTERS & INLINE ACTIONS
        ============================================================ */
        .notif-filter-btn {
            padding: 5px 12px;
            border-radius: 20px;
            border: 1px solid #e2e8f0;
            background: #f8fafc;
            color: #64748b;
            font-size: 12px;
            font-weight: 500;
            cursor: pointer;
            transition: all 0.15s;
            white-space: nowrap;
        }

        .notif-filter-btn:hover {
            background: #e0e7ff;
            border-color: #a5b4fc;
            color: #4338ca;
        }

        .notif-filter-btn.active {
            background: #4f46e5;
            border-color: #4f46e5;
            color: #fff;
            font-weight: 600;
        }

        .notif-inline-actions {
            display: flex;
            gap: 6px;
            margin-top: 8px;
            flex-wrap: wrap;
        }

        .notif-action-btn {
            padding: 4px 12px;
            border-radius: 6px;
            border: none;
            font-size: 12px;
            font-weight: 600;
            cursor: pointer;
            transition: opacity 0.15s;
        }

        .notif-action-btn:hover { opacity: 0.85; }

        .notif-action-approve {
            background: #d1fae5;
            color: #065f46;
        }

        .notif-action-reject {
            background: #fee2e2;
            color: #991b1b;
        }

        .notif-action-view {
            background: #e0e7ff;
            color: #3730a3;
        }

        /* ============================================================
           VIEW TOGGLE GROUP (רשימה | קנבן)
        ============================================================ */
        .view-toggle-group {
            display: inline-flex;
            border: 1.5px solid #e2e8f0;
            border-radius: 8px;
            overflow: hidden;
            background: #f8fafc;
        }

        .view-toggle-btn {
            display: inline-flex;
            align-items: center;
            gap: 5px;
            padding: 6px 13px;
            border: none;
            background: transparent;
            color: #64748b;
            font-size: 13px;
            font-weight: 500;
            cursor: pointer;
            transition: background 0.15s, color 0.15s;
            white-space: nowrap;
        }

        .view-toggle-btn + .view-toggle-btn {
            border-right: 1.5px solid #e2e8f0;
        }

        .view-toggle-btn:hover {
            background: rgba(47,79,127,.08);
            color: #2f4f7f;
        }

        .view-toggle-btn.active {
            background: var(--color-primary);
            color: #fff;
            font-weight: 600;
        }

        .view-toggle-btn.active svg {
            stroke: #fff;
        }

        /* ─── Impersonation Banner ──────────────────────────────────────────── */
        #impersonationBanner {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            z-index: 10000;
            background: linear-gradient(135deg, #dc2626 0%, #991b1b 100%);
            color: #fff;
            padding: 0 20px;
            height: 52px;
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 12px;
            box-shadow: 0 2px 16px rgba(220, 38, 38, 0.45);
            direction: rtl;
            font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Heebo", Arial, sans-serif;
        }

        .impersonation-banner-info {
            display: flex;
            align-items: center;
            gap: 10px;
            flex: 1;
            min-width: 0;
            overflow: hidden;
        }

        .impersonation-banner-icon {
            font-size: 18px;
            flex-shrink: 0;
        }

        .impersonation-banner-text {
            font-size: 13px;
            font-weight: 500;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .impersonation-banner-badge {
            background: rgba(255, 255, 255, 0.2);
            border: 1px solid rgba(255, 255, 255, 0.35);
            border-radius: 12px;
            padding: 2px 10px;
            font-size: 11px;
            font-weight: 700;
            white-space: nowrap;
            flex-shrink: 0;
        }

        .impersonation-banner-badge.readonly {
            background: rgba(251, 191, 36, 0.25);
            border-color: rgba(251, 191, 36, 0.55);
            color: #fef3c7;
        }

        .impersonation-banner-timer {
            font-size: 13px;
            font-weight: 700;
            color: rgba(255, 255, 255, 0.85);
            font-variant-numeric: tabular-nums;
            letter-spacing: 0.5px;
            white-space: nowrap;
        }

        .impersonation-exit-btn {
            background: rgba(255, 255, 255, 0.15);
            border: 1px solid rgba(255, 255, 255, 0.45);
            color: #fff;
            padding: 6px 16px;
            border-radius: 6px;
            font-size: 13px;
            font-weight: 600;
            cursor: pointer;
            white-space: nowrap;
            transition: background 0.15s, transform 0.1s;
            font-family: inherit;
        }

        .impersonation-exit-btn:hover {
            background: rgba(255, 255, 255, 0.28);
            transform: translateY(-1px);
        }

        /* הזזת כל התוכן כשהבאנר מוצג */
        body.impersonating {
            padding-top: 52px;
        }

        body.impersonating .notifications-bell {
            top: calc(16px + 52px);
        }

        /* כפתור התחזות ברשימת משתמשים */
        .btn-impersonate {
            background: #dc2626;
            color: #fff;
            border: none;
            font-size: 12px;
            padding: 5px 12px;
            border-radius: 6px;
            cursor: pointer;
            font-weight: 600;
            transition: background 0.15s;
            font-family: inherit;
        }

        .btn-impersonate:hover {
            background: #b91c1c;
        }

        /* Modal btn-danger */
        .btn-danger {
            background: #dc2626;
            color: #fff;
            border: 1px solid #dc2626;
        }

        .btn-danger:hover {
            background: #b91c1c;
            border-color: #b91c1c;
        }
