/* ==========================================================
   FASTexa light_classic — DashFlat inspired (offline)
   ========================================================== */

@font-face {
    font-family: 'Cairo';
    src: url('../fonts/cairo/Cairo-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
}
@font-face {
    font-family: 'Cairo';
    src: url('../fonts/cairo/Cairo-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
}
@font-face {
    font-family: 'Montserrat';
    src: url('../fonts/montserrat/Montserrat-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
}
@font-face {
    font-family: 'Montserrat';
    src: url('../fonts/montserrat/Montserrat-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
}

:root {
    /* كلاسيك حديث نظيف — تيل هادئ (بدون بنفسجي DashFlat) */
    --fx-bg: #eef4f5;
    --fx-surface: #ffffff;
    --fx-surface-2: #f5fafb;
    --fx-text: #1a2e33;
    --fx-muted: #647880;
    --fx-border: #d5e3e6;
    --fx-primary: #0f766e;
    --fx-primary-soft: rgba(15, 118, 110, 0.12);
    --fx-primary-hover: #0b5f59;
    --fx-cyan: #14b8a6;
    --fx-success: #16a34a;
    --fx-danger: #dc2626;
    --fx-warning: #d97706;
    --fx-sidebar-w: 260px;
    --fx-header-h: 0px;
    --fx-subnav-h: 48px;
    --fx-modebar-h: 36px;
    --fx-dayclose-h: 0px;
    --fx-chrome-h: calc(var(--fx-subnav-h) + var(--fx-modebar-h) + var(--fx-dayclose-h));
    --fx-radius: 12px;
    --fx-shadow: 0 10px 28px rgba(15, 60, 70, 0.07);
    /* أيقونات — تتغير مع الثيم/الستايل */
    --fx-icon: #3f5860;
    --fx-icon-active: var(--fx-primary);
    --fx-icon-on-solid: #ffffff;

    /* توافق القوالب القديمة */
    --primary-teal: var(--fx-primary);
    --primary-teal-hover: var(--fx-primary-hover);
    --dark-sidebar: var(--fx-surface);
    --card-shadow: var(--fx-shadow);
    --border-radius-soft: var(--fx-radius);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html, body {
    height: 100%;
}

body {
    font-family: 'Cairo', 'Montserrat', sans-serif;
    background: var(--fx-bg);
    color: var(--fx-text);
    direction: rtl;
    text-align: right;
    font-size: 0.95rem;
    margin: 0;
    -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
a:hover { color: var(--fx-primary); }

.text-muted { color: var(--fx-muted) !important; }
.text-teal { color: var(--fx-primary) !important; }
.bg-teal { background-color: var(--fx-primary) !important; }

/* ---- Header ---- */
.main-header {
    position: fixed;
    top: 0;
    right: var(--fx-sidebar-w);
    left: 0;
    height: var(--fx-chrome-h);
    z-index: 1030;
    background: var(--fx-bg);
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
    padding: 0;
}
.fx-header-bar { display: none; }
.fx-subnav {
    height: var(--fx-subnav-h);
    display: flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.35rem 1.75rem;
    overflow: visible;
}
.fx-subnav-main {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    overflow-x: auto;
    scrollbar-width: thin;
    flex: 1;
    min-width: 0;
}
.fx-main-nav .fx-subnav-main {
    overflow: visible;
}
.fx-main-nav {
    overflow: visible;
}
.main-header:has(.fx-main-nav-section.is-open) {
    overflow: visible;
    z-index: 1045;
}
.fx-main-nav .fx-main-nav-section {
    position: relative;
    flex-shrink: 0;
}
.fx-main-nav-trigger {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    border: 1px solid #cbd5e1;
    background: #fff;
    color: #0f172a;
    border-radius: 999px;
    padding: 0.35rem 0.75rem;
    font-size: 0.82rem;
    font-weight: 700;
    line-height: 1.2;
    cursor: pointer;
    white-space: nowrap;
    transition: background .15s, border-color .15s, box-shadow .15s;
}
.fx-main-nav-trigger .fx-ico:last-child {
    width: 12px;
    height: 12px;
    opacity: .65;
    transition: transform .15s;
}
.fx-main-nav-section.is-open .fx-main-nav-trigger,
.fx-main-nav-section.is-active .fx-main-nav-trigger {
    border-color: #2563eb;
    background: #eff6ff;
    color: #1d4ed8;
}
.fx-main-nav-section.is-open .fx-main-nav-trigger .fx-ico:last-child {
    transform: rotate(180deg);
}
.fx-main-nav-panel {
    position: fixed;
    top: 0;
    left: 0;
    min-width: 220px;
    max-width: min(92vw, 320px);
    max-height: min(70vh, 420px);
    overflow: auto;
    background: #fff;
    border: 1px solid #dbeafe;
    border-radius: 12px;
    box-shadow: 0 14px 34px rgba(15, 23, 42, 0.14);
    padding: 0.35rem;
    z-index: 2000;
    display: none;
}
.fx-main-nav-section.is-open .fx-main-nav-panel {
    display: block;
}
.fx-main-nav-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.08);
    z-index: 1990;
}
.fx-main-nav-link {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.55rem 0.65rem;
    border-radius: 8px;
    color: #0f172a;
    text-decoration: none;
    font-size: 0.86rem;
    font-weight: 700;
}
.fx-main-nav-link:hover {
    background: #f1f5f9;
    color: #0f172a;
}
.fx-main-nav-link.is-active {
    background: #dbeafe;
    color: #1d4ed8;
}
.fx-main-nav-link.is-solid {
    background: linear-gradient(180deg, #2563eb, #1d4ed8);
    color: #fff;
}
.fx-main-nav-link.is-solid:hover {
    background: linear-gradient(180deg, #1d4ed8, #1e40af);
    color: #fff;
}
.fx-main-nav-link.is-em-warning { color: #b45309; }
.fx-main-nav-link.is-em-success { color: #15803d; }
.fx-main-nav-link.is-em-danger {
    background: linear-gradient(180deg, #ef4444, #b91c1c);
    color: #fff;
}
.fx-main-nav-link.is-em-danger:hover {
    background: #991b1b;
    color: #fff;
}
.fx-sidebar-quick.is-solid {
    background: linear-gradient(180deg, #2563eb, #1d4ed8);
    color: #fff !important;
    border-radius: 10px;
    font-weight: 800;
}
.fx-sidebar-quick.is-solid:hover,
.fx-sidebar-quick.is-solid.active {
    background: linear-gradient(180deg, #1d4ed8, #1e40af);
    color: #fff !important;
}
body.fx-main-nav-open {
    overflow: auto;
}
[data-fx-theme="dark"] .fx-main-nav-trigger {
    background: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}
[data-fx-theme="dark"] .fx-main-nav-panel {
    background: #0f172a;
    border-color: #334155;
}
[data-fx-theme="dark"] .fx-main-nav-link {
    color: #e2e8f0;
}
[data-fx-theme="dark"] .fx-main-nav-link:hover {
    background: #1e293b;
}

/* قشرة ويندوز XP — قوائم مربّعة بلا border-radius (أسلوب الأصيل) */
html[data-fx-shell="windows7"] .fx-main-nav-trigger {
    border-radius: 0 !important;
    border: 1px solid #7a93ae !important;
    background: linear-gradient(180deg, #ffffff 0%, #e8f0f8 55%, #d0e0f0 100%) !important;
    color: #0f2944 !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9), 1px 1px 0 rgba(30, 60, 90, 0.12) !important;
    padding: 0.32rem 0.7rem !important;
    font-size: 0.86rem !important;
}
html[data-fx-shell="windows7"] .fx-main-nav-section.is-open .fx-main-nav-trigger,
html[data-fx-shell="windows7"] .fx-main-nav-section.is-active .fx-main-nav-trigger {
    border-color: #3f6fa0 !important;
    background: linear-gradient(180deg, #dbeaf8 0%, #b8d4ee 100%) !important;
    color: #0b5aa8 !important;
    box-shadow: inset 1px 1px 2px rgba(30, 60, 90, 0.18) !important;
}
html[data-fx-shell="windows7"] .fx-main-nav-panel {
    border-radius: 0 !important;
    border: 1px solid #5a7ea3 !important;
    box-shadow: 2px 3px 8px rgba(20, 50, 80, 0.22) !important;
    padding: 0 !important;
    background: #f4f8fc !important;
}
html[data-fx-shell="windows7"] .fx-main-nav-link {
    border-radius: 0 !important;
    border-bottom: 1px solid #d0dde8;
    padding: 0.5rem 0.75rem !important;
    font-size: 0.88rem !important;
}
html[data-fx-shell="windows7"] .fx-main-nav-link:last-child {
    border-bottom: 0;
}
html[data-fx-shell="windows7"] .fx-main-nav-link:hover {
    background: #c7dff5 !important;
}
html[data-fx-shell="windows7"] .fx-main-nav-link.is-active {
    background: #9cc5ea !important;
    color: #0b3d6e !important;
}

.fx-subnav-btn.is-day-close {
    margin-inline-start: auto;
    background: linear-gradient(180deg, #ef4444, #b91c1c) !important;
    color: #fff !important;
    border-color: #991b1b !important;
    box-shadow: 0 6px 14px rgba(185, 28, 28, 0.28) !important;
    font-weight: 800;
}
.fx-subnav-btn.is-day-close i,
.fx-subnav-btn.is-day-close .fx-ico {
    color: #fff !important;
    filter: brightness(0) invert(1);
    opacity: 1;
}
.fx-subnav-btn.is-day-close:hover,
.fx-subnav-btn.is-day-close.active {
    background: #991b1b !important;
    color: #fff !important;
    border-color: #7f1d1d !important;
}
.fx-report-meta { border-bottom: 1px solid #cbd5e1; padding-bottom: .65rem; }
.fx-report-doc-title { font-size: 1.15rem; font-weight: 800; color: #0f172a; }
.fx-report-party { font-size: 1.05rem; font-weight: 800; margin-top: .15rem; }
.fx-report-meta-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: .35rem 1rem;
    margin-top: .35rem;
    font-size: .86rem;
    font-weight: 700;
    color: #334155;
}
.fx-print-letterhead {
    display: none; /* شاشة الموقع: مخفية — تظهر عند الطباعة فقط */
    justify-content: space-between;
    gap: 1rem;
    align-items: center;
    padding: .85rem 0 1rem;
    margin-bottom: .75rem;
    border-bottom: 1px solid #e2e8f0;
    background: linear-gradient(135deg, #f8fafc, #eef2ff);
    padding-inline: 1rem;
    border-radius: 10px;
}
.fx-print-letterhead-main { display: flex; align-items: center; gap: .85rem; min-width: 0; }
.fx-print-letterhead-logo {
    width: 64px;
    height: 64px;
    object-fit: contain;
    border-radius: 10px;
    background: #fff;
    padding: 4px;
    border: 1px solid #e2e8f0;
    flex-shrink: 0;
}
.fx-print-letterhead-name { font-weight: 900; font-size: 1.2rem; color: #0f172a; line-height: 1.25; }
.fx-print-letterhead-meta { font-size: .82rem; color: #475569; }
.fx-print-letterhead-stamp {
    display: inline-block;
    border: 2px dashed #94a3b8;
    color: #64748b;
    padding: .35rem .75rem;
    border-radius: 8px;
    font-weight: 800;
    letter-spacing: .04em;
    white-space: nowrap;
}
.fx-print-doc-footer {
    display: none; /* شاشة الموقع: مخفي — يظهر عند الطباعة فقط */
    justify-content: center;
    align-items: center;
    margin-top: 1.25rem;
    padding-top: .75rem;
    border-top: 1px dashed #cbd5e1;
    font-size: .82rem;
    color: #334155;
    text-align: center;
}
.fx-print-doc-footer-system {
    font-weight: 800;
    color: #64748b;
    font-size: .78rem;
    text-align: center;
    width: 100%;
}

/* مودال تأكيد عام (رقم عشوائي) — وسط الشاشة على كل الصفحات */
.fx-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, .45);
    z-index: 210000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}
.fx-modal-backdrop.is-open {
    display: flex !important;
}
.fx-modal-box {
    background: var(--fx-surface, #fff);
    color: var(--fx-text, #111);
    border-radius: 14px;
    width: min(520px, 100%);
    max-height: min(92vh, 900px);
    overflow: auto;
    box-shadow: 0 20px 50px rgba(0, 0, 0, .25);
    padding: 1.15rem 1.25rem;
    margin: auto;
}

@media print {
    .fx-print-letterhead {
        display: flex !important;
        print-color-adjust: exact;
        -webkit-print-color-adjust: exact;
    }
    .fx-print-doc-footer {
        display: flex !important;
    }
}
.fx-report-brand-footer {
    margin-top: 1.25rem;
    margin-bottom: 0;
    text-align: center;
    font-size: .78rem;
    font-weight: 700;
    color: #64748b;
    border-top: 1px solid #e2e8f0;
    padding-top: .55rem;
}
@media print {
    .fx-report-brand-footer {
        margin-top: 8mm;
        font-size: 8pt !important;
        color: #475569 !important;
    }
}

/* شريط وضع الواجهة (بسيط / محاسبي) */
.fx-ui-mode-bar {
    height: var(--fx-modebar-h);
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.55rem;
    padding: 0 1.25rem;
    border-top: 1px solid var(--fx-border);
    font-size: 0.78rem;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
}
.fx-ui-mode-bar::-webkit-scrollbar { display: none; }
.fx-ui-mode-bar.is-simple {
    background: color-mix(in srgb, var(--fx-success, #16a34a) 14%, var(--fx-surface, #f4f7fb));
    color: var(--fx-text, #166534);
    border-color: var(--fx-border);
}
.fx-ui-mode-bar.is-advanced {
    background: color-mix(in srgb, var(--fx-primary, #0f766e) 12%, var(--fx-surface, #f4f7fb));
    color: var(--fx-text, #3730a3);
    border-color: var(--fx-border);
}
.fx-ui-mode-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    min-width: 0;
}
.fx-ui-mode-pill em {
    font-style: normal;
    opacity: 0.85;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 52vw;
}
.fx-ui-mode-switch {
    flex-shrink: 0;
    margin-inline-start: auto;
    font-weight: 700;
    text-decoration: none;
    color: inherit;
    border: 1px solid currentColor;
    border-radius: 999px;
    padding: 0.1rem 0.65rem;
    opacity: 0.9;
}
.fx-ui-mode-switch:hover { opacity: 1; background: rgba(255,255,255,0.55); }
body.fx-ui-advanced .main-content { box-shadow: inset 3px 0 0 var(--fx-primary); background: rgba(15, 118, 110, 0.04); }
body.fx-ui-simple .main-content { box-shadow: inset 3px 0 0 #22c55e; background: #ecfdf522; }
.fx-wh-advanced-card { border: 1px solid #c7d2fe !important; }
.fx-wh-simple-card { border: 1px solid #bbf7d0 !important; }

/* بطاقات الوضع البسيط للمخازن */
.fx-wh-simple-wrap { margin-top: .25rem; }
.fx-wh-card {
    background: var(--fx-surface, #fff);
    color: var(--fx-text, #0f172a);
    border-radius: 16px;
    padding: 1rem 1.1rem;
    border: 2px solid color-mix(in srgb, var(--fx-success, #22c55e) 45%, var(--fx-border, #bbf7d0));
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
    min-height: 160px;
    display: flex;
    flex-direction: column;
    gap: .65rem;
}
.fx-wh-card.is-frozen {
    border-color: color-mix(in srgb, var(--fx-warning, #f59e0b) 55%, transparent);
    background: color-mix(in srgb, var(--fx-warning, #f59e0b) 10%, var(--fx-surface, #fffbeb));
    box-shadow: none;
}
.fx-wh-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: .5rem;
}
.fx-wh-card-title { font-weight: 800; font-size: 1.05rem; color: var(--fx-text, #14532d); }
.fx-wh-card-code {
    background: var(--fx-surface-2, #f0fdf4);
    border: 1px solid var(--fx-border, #86efac);
    border-radius: 8px;
    color: var(--fx-text, inherit);
    padding: .15rem .45rem;
    font-size: .8rem;
}
.fx-wh-card-meta { display: flex; flex-wrap: wrap; gap: .35rem; }
.fx-wh-card-actions { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: auto; }

.fx-wh-adv-toolbar { display:flex; align-items:center; gap:.75rem; flex-wrap:wrap; }
.fx-wh-ledger thead th { font-size: .7rem; font-weight: 600; white-space: nowrap; padding: .28rem .4rem; }
.fx-wh-ledger td { font-size: .75rem; font-weight: 500; padding: .22rem .4rem; line-height: 1.3; }

.fx-subnav-btn.is-sales-lead {
    order: -100;
}
/* فاتورة إرجاع — أحمر فاتح جداً في الناف بار */
.fx-subnav-btn.is-return-soft {
    background: #fff5f5;
    color: #c53030;
    border-color: #fed7d7;
    box-shadow: 0 2px 8px rgba(197, 48, 48, 0.06);
}
.fx-subnav-btn.is-return-soft i,
.fx-subnav-btn.is-return-soft .fx-ico {
    color: #e53e3e;
}
.fx-subnav-btn.is-return-soft:hover,
.fx-subnav-btn.is-return-soft.active {
    background: #ffe8e8;
    color: #9b2c2c;
    border-color: #feb2b2;
}
.fx-btn-return-soft {
    background: #fff5f5;
    color: #c53030;
    border: 1px solid #fed7d7;
}
.fx-btn-return-soft:hover {
    background: #ffe8e8;
    color: #9b2c2c;
    border-color: #feb2b2;
}
.fx-subnav-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    height: 36px;
    padding: 0 0.8rem;
    border-radius: 12px;
    background: var(--fx-surface);
    color: var(--fx-icon);
    font-weight: 700;
    font-size: 0.82rem;
    box-shadow: 0 2px 10px rgba(31, 42, 68, 0.04);
    border: 1px solid transparent;
    white-space: nowrap;
    flex-shrink: 0;
}
.fx-subnav-btn i { color: var(--fx-icon-active); }
.fx-subnav-btn:hover,
.fx-subnav-btn.active {
    color: var(--fx-icon-active);
    border-color: var(--fx-primary-soft);
    background: var(--fx-primary-soft);
}
/* زر دائم اللون في الناف بار (فاتورة مبيعات أولاً) */
.fx-subnav-btn.is-solid {
    background: var(--fx-primary);
    color: var(--fx-icon-on-solid);
    border-color: var(--fx-primary);
    box-shadow: 0 4px 14px rgba(15, 118, 110, 0.28);
}
.fx-subnav-btn.is-solid i {
    color: var(--fx-icon-on-solid);
}
.fx-subnav-btn.is-solid:hover,
.fx-subnav-btn.is-solid.active {
    background: var(--fx-primary-hover);
    border-color: var(--fx-primary-hover);
    color: #fff;
}
.fx-subnav-btn.is-soon {
    opacity: 0.72;
    cursor: default;
}
.fx-subnav-btn .fx-menu-soon {
    font-style: normal;
    font-size: 0.68rem;
    font-weight: 800;
    color: #9aa3b5;
    background: #eef2f7;
    border-radius: 999px;
    padding: 0.1rem 0.4rem;
}
.fx-subnav-label { white-space: nowrap; }

.fx-search {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    background: var(--fx-surface);
    border: 1px solid var(--fx-border);
    border-radius: 999px;
    padding: 0.55rem 1rem;
    min-width: min(420px, 46vw);
    box-shadow: 0 2px 10px rgba(31, 42, 68, 0.03);
}
.fx-search i { color: var(--fx-muted); font-size: 0.9rem; }
.fx-search input {
    border: 0;
    outline: 0;
    background: transparent;
    width: 100%;
    color: var(--fx-text);
    font-family: inherit;
    font-size: 0.92rem;
}
.fx-search input::placeholder { color: #aab3c2; }

.fx-header-actions {
    display: flex;
    align-items: center;
    gap: 0.85rem;
}
.fx-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--fx-muted);
    font-weight: 600;
    font-size: 0.88rem;
    background: transparent;
    border: 0;
}
.fx-icon-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 0;
    background: var(--fx-surface);
    color: var(--fx-icon);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(31, 42, 68, 0.04);
    position: relative;
}
.fx-icon-btn .dot {
    position: absolute;
    top: 8px;
    left: 9px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--fx-danger);
    border: 2px solid #fff;
}
.fx-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #fff;
    box-shadow: 0 0 0 2px var(--fx-primary-soft);
}
.fx-avatar-fallback {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--fx-primary-soft);
    color: var(--fx-primary);
}
.fx-avatar-btn {
    border: 0;
    background: transparent;
    padding: 0;
    border-radius: 50%;
}

.fx-header-start,
.fx-header-end {
    display: flex;
    align-items: center;
    gap: 0.55rem;
}
.fx-quick-actions {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex-wrap: wrap;
}
.fx-quick-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    height: 40px;
    padding: 0 0.75rem;
    border-radius: 12px;
    background: var(--fx-surface);
    color: var(--fx-icon);
    font-weight: 700;
    font-size: 0.82rem;
    box-shadow: 0 2px 10px rgba(31, 42, 68, 0.04);
    border: 1px solid transparent;
}
.fx-quick-btn i { color: var(--fx-icon-active); }
.fx-quick-btn:hover,
.fx-quick-btn.active {
    color: var(--fx-icon-active);
    border-color: var(--fx-primary-soft);
    background: var(--fx-primary-soft);
}
.fx-quick-label { white-space: nowrap; }

.fx-quick-menu {
    position: absolute;
    top: calc(var(--fx-chrome-h) + 0.35rem);
    right: 1.25rem;
    width: min(300px, calc(100vw - 2rem));
    background: var(--fx-surface);
    border-radius: 16px;
    box-shadow: 0 16px 40px rgba(31, 42, 68, 0.16);
    border: 1px solid var(--fx-border);
    padding: 0.55rem;
    z-index: 1100;
}

/* منيو الحساب: أعمدة عريضة على اللابتوب/التابلت */
.fx-quick-menu.fx-mega-menu {
    width: min(920px, calc(100vw - var(--fx-sidebar-w) - 1.5rem));
    max-width: calc(100vw - var(--fx-sidebar-w) - 1.5rem);
    max-height: min(78vh, 560px);
    overflow: auto;
    padding: 0.65rem 0.75rem 0.85rem;
}
.fx-mega-head {
    font-size: 0.78rem;
    font-weight: 800;
    color: #9aa3b5;
    padding: 0.25rem 0.5rem 0.55rem;
}
.fx-mega-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.35rem 1rem;
    align-items: start;
}
.fx-mega-grid.is-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}
.fx-mega-grid.is-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}
.fx-mega-col {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.12rem;
}
.fx-mega-col .fx-quick-menu-title {
    padding-top: 0.15rem;
}
.fx-mega-menu .fx-quick-menu-item {
    padding: 0.58rem 0.65rem;
    font-size: 0.88rem;
}

/* تابلت متوسط: عمودان */
@media (max-width: 1100px) and (min-width: 769px) {
    .fx-quick-menu.fx-mega-menu {
        width: min(560px, calc(100vw - var(--fx-sidebar-w) - 1rem));
    }
    .fx-mega-grid,
    .fx-mega-grid.is-3,
    .fx-mega-grid.is-4 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* شريط قفز أقسام الإعدادات تحت الناف بار */
.fx-settings-jump {
    display: none;
    height: var(--fx-settings-jump-h, 42px);
    align-items: center;
    gap: 0.35rem;
    padding: 0.3rem 1.75rem;
    overflow-x: auto;
    scrollbar-width: thin;
    border-top: 1px solid var(--fx-border);
    background: var(--fx-surface, #fff);
}
body.fx-has-settings-jump {
    --fx-settings-jump-h: 42px;
    --fx-chrome-h: calc(var(--fx-subnav-h) + var(--fx-modebar-h) + var(--fx-settings-jump-h) + var(--fx-dayclose-h));
}
body.fx-has-dayclose-bar {
    --fx-dayclose-h: 32px;
}
.fx-day-close-bar {
    display: none;
    height: var(--fx-dayclose-h);
    align-items: center;
    justify-content: space-between;
    gap: 0.6rem;
    padding: 0 1.75rem;
    background: #fff8e6;
    border-bottom: 1px solid #e2b93b;
    color: #7a5b12;
    font-size: 0.8rem;
    flex-shrink: 0;
}
body.fx-has-dayclose-bar .fx-day-close-bar {
    display: flex;
}
.fx-day-close-bar-text {
    display: flex;
    align-items: baseline;
    gap: 0.45rem;
    min-width: 0;
    overflow: hidden;
}
.fx-day-close-bar-text strong {
    font-weight: 800;
    white-space: nowrap;
}
.fx-day-close-bar-text span {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    opacity: 0.88;
}
.fx-day-close-bar-btn {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 24px;
    padding: 0 0.65rem;
    border: 1px solid #dc2626;
    border-radius: 6px;
    background: #fff;
    color: #dc2626;
    font-size: 0.72rem;
    font-weight: 800;
    white-space: nowrap;
    text-decoration: none;
}
.fx-day-close-bar-btn:hover {
    background: #dc2626;
    color: #fff;
}
html[data-fx-theme="dark"] .fx-day-close-bar,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-day-close-bar {
    background: rgba(234, 179, 8, 0.16);
    border-bottom-color: rgba(234, 179, 8, 0.35);
    color: #fde68a;
}
body.fx-has-settings-jump .fx-settings-jump {
    display: flex;
}
.fx-settings-jump-link {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    padding: 0.28rem 0.7rem;
    border-radius: 999px;
    border: 1px solid var(--fx-border);
    background: var(--fx-surface-2, #f8fafc);
    color: var(--fx-muted, #5d6b82);
    font-size: 0.78rem;
    font-weight: 700;
    white-space: nowrap;
    text-decoration: none;
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.fx-settings-jump-link:hover {
    border-color: color-mix(in srgb, var(--fx-primary) 45%, transparent);
    color: var(--fx-primary);
    background: var(--fx-primary-soft);
}
.fx-settings-jump-link.is-active {
    border-color: var(--fx-primary);
    color: var(--fx-icon-on-solid, #fff);
    background: var(--fx-primary);
}

/* داكن / زجاجي: شريط أسود · زر فضي + نص أسود · هوفَر/أكتيف ذهبي + نص أسود */
html[data-fx-theme="dark"] .fx-settings-jump,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-settings-jump {
    background: #0a0a0a !important;
    border-top-color: rgba(192, 192, 192, 0.18) !important;
}
html[data-fx-theme="dark"] .fx-settings-jump-link,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-settings-jump-link {
    background: #c0c0c0 !important; /* فضي */
    border-color: #a8a8a8 !important;
    color: #0a0a0a !important; /* نص أسود للوضوح */
}
html[data-fx-theme="dark"] .fx-settings-jump-link:hover,
html[data-fx-theme="dark"] .fx-settings-jump-link:focus-visible,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-settings-jump-link:hover,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-settings-jump-link:focus-visible {
    background: var(--fx-primary, #d4af37) !important; /* ذهب */
    border-color: var(--fx-primary, #d4af37) !important;
    color: #0a0a0a !important;
}
html[data-fx-theme="dark"] .fx-settings-jump-link.is-active,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-settings-jump-link.is-active {
    background: var(--fx-primary, #d4af37) !important;
    border-color: var(--fx-primary, #d4af37) !important;
    color: #0a0a0a !important;
    font-weight: 800;
}
.fx-settings-section {
    scroll-margin-top: calc(var(--fx-chrome-h) + 0.75rem);
}

/* مجموعة الأزرار الطائرة (العودة + حفظ…) */
.fx-float-actions {
    display: none !important;
}
.fx-float-back {
    display: none !important;
}
.fx-header-back {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    height: 28px;
    padding: 0 0.7rem;
    border-radius: 999px;
    border: 1px solid var(--fx-border);
    background: var(--fx-surface);
    color: var(--fx-text);
    font-weight: 700;
    font-size: 0.78rem;
    cursor: pointer;
}
.fx-header-back:hover {
    border-color: var(--fx-primary);
    color: var(--fx-primary);
    background: var(--fx-primary-soft);
}
.fx-header-back .fx-ico {
    width: 14px;
    height: 14px;
    display: block;
    opacity: 0.9;
}
.fx-ui-mode-bar .fx-ico,
.fx-subnav-btn .fx-ico,
.sidebar .nav-link .fx-ico,
.fx-quick-menu .fx-ico,
.fx-theme-toggle .fx-ico {
    width: 1em;
    height: 1em;
    display: inline-block;
    vertical-align: -0.15em;
    flex-shrink: 0;
}
.sidebar .nav-link .fx-ico {
    width: 1.05rem;
    height: 1.05rem;
    margin-inline-end: 0.45rem;
}
.fx-float-save {
    height: 44px;
    min-width: 44px;
    padding: 0 1.1rem;
    border-radius: 999px;
    border: 0;
    background: linear-gradient(180deg, #14b8a6, #0f766e);
    color: #fff;
    font-weight: 800;
    font-size: 0.88rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    box-shadow: 0 8px 22px rgba(15, 118, 110, 0.28);
    cursor: pointer;
    white-space: nowrap;
}
.fx-float-save:hover {
    filter: brightness(1.05);
    box-shadow: 0 10px 26px rgba(15, 118, 110, 0.36);
    color: #fff;
}
.fx-float-save .fx-ico {
    width: 16px;
    height: 16px;
    display: block;
    filter: brightness(0) invert(1);
}

/* النماذج التشغيلية تملأ عرض المحتوى المتاح */
.main-content > .container-fluid[style*="max-width"],
.main-content > .card[style*="max-width"],
.main-content form.card[style*="max-width"],
.main-content form[style*="max-width"],
.main-content .fx-settings-form,
.main-content .fx-page-wide {
    max-width: none !important;
    width: 100% !important;
}
.fx-account-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.28);
    z-index: 1090;
}
.fx-quick-menu-title {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--fx-muted);
    padding: 0.45rem 0.65rem 0.35rem;
}
.fx-quick-menu-item {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.72rem 0.75rem;
    border-radius: 12px;
    color: var(--fx-icon);
    font-weight: 700;
    font-size: 0.92rem;
}
.fx-quick-menu-item i {
    width: 1.15rem;
    text-align: center;
    color: var(--fx-icon-active);
}
.fx-quick-menu-item:hover {
    background: var(--fx-primary-soft);
    color: var(--fx-icon-active);
}
.fx-menu-sub-status {
    cursor: default;
    pointer-events: none;
    font-size: 0.82rem;
    align-items: flex-start;
}
.fx-menu-sub-status:hover {
    background: transparent;
    color: inherit;
}
.fx-menu-sub-status.is-warn {
    color: #c2410c;
    background: rgba(255, 91, 92, 0.12);
}
.fx-menu-sub-status.is-ok {
    color: #0f9f6e;
    background: rgba(34, 197, 94, 0.12);
}
.fx-menu-sub-status span {
    display: flex;
    flex-direction: column;
    gap: 0.08rem;
    min-width: 0;
    line-height: 1.3;
}
.fx-menu-sub-status strong {
    font-size: 0.68rem;
    font-weight: 800;
    opacity: 0.75;
}
.fx-quick-menu-item.is-active {
    background: var(--fx-primary-soft);
    color: var(--fx-icon-active);
}
.fx-quick-menu-item.is-soon {
    opacity: 0.72;
    cursor: default;
}
.fx-quick-menu-item .fx-menu-soon {
    margin-inline-start: auto;
    font-style: normal;
    font-size: 0.7rem;
    font-weight: 800;
    color: #9aa3b5;
    background: #eef2f7;
    border-radius: 999px;
    padding: 0.12rem 0.45rem;
}
.fx-quick-menu-divider {
    height: 1px;
    background: var(--fx-border);
    margin: 0.4rem 0.35rem;
}
@media (max-width: 768px) {
    .fx-account-menu,
    .fx-quick-menu.fx-mega-menu {
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        top: auto;
        width: 100%;
        max-width: 100%;
        max-height: min(78vh, 560px);
        overflow-y: auto;
        border-radius: 20px 20px 0 0;
        padding: 0.85rem 0.75rem calc(0.85rem + env(safe-area-inset-bottom, 0px));
    }
    .fx-mega-grid {
        display: flex;
        flex-direction: column;
        gap: 0.25rem;
    }
    .fx-mega-col {
        display: contents;
    }
    .fx-mega-col .fx-quick-menu-title {
        padding-top: 0.45rem;
    }
}
.main-header { position: fixed; }

@media (max-width: 1100px) {
    .fx-quick-label,
    .fx-subnav-label { display: none; }
    .fx-quick-btn,
    .fx-subnav-btn { width: 40px; justify-content: center; padding: 0; }
    .fx-subnav-btn.is-soon .fx-menu-soon { display: none; }
    .fx-day-close-bar-text span { display: none; }
}
.sidebar-container {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: var(--fx-sidebar-w);
    background: var(--fx-surface);
    border-left: 1px solid var(--fx-border);
    z-index: 1040;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: none;
}

/* مشروع المستأجر: شعار واسم في صف واحد، والأيقونات تحتهم بلا مربعات */
.fx-project-head {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.2rem;
    padding: 0.5rem 0.75rem 0.4rem;
}
.fx-project-brand {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.55rem;
    min-width: 0;
    width: 100%;
}
.fx-project-logo {
    width: 42px;
    height: 42px;
    border-radius: 11px;
    object-fit: cover;
    background: #f3f5fb;
    box-shadow: 0 4px 12px rgba(31, 42, 68, 0.08);
    flex-shrink: 0;
}
.fx-project-logo-wrap {
    position: relative;
    display: inline-block;
    line-height: 0;
    order: 0;
    flex-shrink: 0;
}
.fx-project-logo-edit {
    position: absolute;
    left: -3px;
    bottom: -3px;
    width: 18px;
    height: 18px;
    border-radius: 999px;
    background: #fff;
    border: 1px solid var(--fx-border);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(31, 42, 68, 0.12);
}
.fx-project-logo-edit:hover { background: var(--fx-primary-soft); }
.fx-project-logo-fallback {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--fx-primary);
    font-size: 1.05rem;
}
.fx-project-name {
    font-weight: 800;
    font-size: 0.92rem;
    color: var(--fx-text);
    line-height: 1.3;
    flex: 1 1 auto;
    min-width: 0;
    text-align: start;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.fx-sidebar-tools {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.05rem;
    margin: 0;
    width: 100%;
    padding: 0.1rem 0 0.05rem;
}
.fx-side-tool {
    width: 28px;
    height: 28px;
    border-radius: 0;
    border: 0;
    background: transparent;
    color: var(--fx-muted);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 0;
    cursor: pointer;
    box-shadow: none;
    flex-shrink: 0;
}
.fx-side-tool .fx-ico {
    width: 20px !important;
    height: 20px !important;
    display: block;
    opacity: 0.58;
    transition: opacity .15s ease, filter .15s ease;
}
.fx-side-tool:hover,
.fx-side-tool.is-active {
    background: transparent;
    border: 0;
    box-shadow: none;
    color: var(--fx-primary);
}
.fx-side-tool:hover .fx-ico,
.fx-side-tool.is-active .fx-ico {
    opacity: 1;
    filter: invert(36%) sepia(55%) saturate(750%) hue-rotate(130deg) brightness(90%);
}
.fx-side-tool.is-calc,
.fx-side-tool.is-trash {
    background: #0f766e;
    border-color: #0f766e;
    color: #fff;
}
.fx-side-tool.is-calc:hover,
.fx-side-tool.is-trash:hover,
.fx-side-tool.is-trash.is-on {
    background: #115e59;
    border-color: #115e59;
    color: #fff;
}
.fx-side-tool.is-calc .fx-ico,
.fx-side-tool.is-trash .fx-ico {
    filter: brightness(0) invert(1);
    opacity: 1;
}
.fx-side-tool .dot {
    position: absolute;
    top: 7px;
    left: 8px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--fx-danger);
    border: 2px solid #fff;
    opacity: 0;
    transform: scale(.6);
    transition: opacity .15s ease, transform .15s ease;
}
.fx-side-tool .dot.is-on {
    opacity: 1;
    transform: scale(1);
}
/* جرس الإشعارات: أحمر عند وجود غير مقروء — طبيعي عند الصفر */
.fx-side-tool.is-notif-alert {
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    color: #b91c1c !important;
}
.fx-side-tool.is-notif-alert .fx-ico {
    filter: invert(18%) sepia(90%) saturate(2800%) hue-rotate(350deg) brightness(90%) contrast(95%);
    opacity: 1;
}
.fx-side-tool.is-notif-alert:hover {
    background: transparent !important;
}
.fx-side-tool.is-day-close-tool {
    width: 24px;
    height: 24px;
    border-radius: 8px;
    background: linear-gradient(180deg, #ef4444, #b91c1c);
    border: 1px solid #991b1b;
    box-shadow: 0 3px 8px rgba(185, 28, 28, 0.28);
    color: #fff;
}
.fx-side-tool.is-day-close-tool .fx-ico {
    width: 14px !important;
    height: 14px !important;
    filter: brightness(0) invert(1) !important;
    opacity: 1 !important;
}
.fx-side-tool.is-day-close-tool:hover,
.fx-side-tool.is-day-close-tool.is-active {
    background: #991b1b;
    border-color: #7f1d1d;
    box-shadow: 0 2px 6px rgba(127, 29, 29, 0.35);
    color: #fff;
}
.fx-side-tool.is-day-close-tool:hover .fx-ico,
.fx-side-tool.is-day-close-tool.is-active .fx-ico {
    filter: brightness(0) invert(1) !important;
    opacity: 1 !important;
}
.fx-notif-badge {
    position: absolute;
    top: -4px;
    inset-inline-end: -4px;
    min-width: 14px;
    height: 14px;
    padding: 0 3px;
    border-radius: 999px;
    background: #dc2626;
    color: #fff;
    font-size: 8px;
    font-weight: 800;
    line-height: 14px;
    text-align: center;
    border: 2px solid #fff;
    box-shadow: 0 1px 4px rgba(185, 28, 28, 0.35);
}
/* لوحة الإشعارات في الماين — نفس أسلوب منيو الحساب */
.fx-quick-menu.fx-notif-menu {
    width: min(420px, calc(100vw - var(--fx-sidebar-w) - 1.5rem));
    max-width: calc(100vw - var(--fx-sidebar-w) - 1.5rem);
    max-height: min(72vh, 520px);
    padding: 0;
    flex-direction: column;
    overflow: hidden;
    z-index: 1110;
}
.fx-quick-menu.fx-notif-menu:not([hidden]) {
    display: flex;
}
.fx-quick-menu.fx-notif-menu[hidden] {
    display: none !important;
}
.fx-notif-panel-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: .5rem;
    padding: .75rem 1rem;
    border-bottom: 1px solid #e2e8f0;
    background: #f8fafc;
    flex-shrink: 0;
}
.fx-notif-panel-body {
    overflow-y: auto;
    flex: 1;
    min-height: 120px;
}
.fx-notif-panel-foot {
    display: flex;
    align-items: center;
    gap: .55rem;
    padding: .55rem .85rem;
    border-top: 1px solid #e2e8f0;
    background: #f8fafc;
    flex-shrink: 0;
}
.fx-notif-vol-label {
    font-size: .72rem;
    font-weight: 700;
    color: #64748b;
    margin: 0;
    white-space: nowrap;
}
.fx-notif-vol-range {
    flex: 1;
    min-width: 0;
    accent-color: #dc2626;
}
.fx-notif-vol-val {
    font-size: .75rem;
    font-weight: 800;
    color: #0f172a;
    min-width: 2.6rem;
    text-align: end;
}
.fx-notif-row {
    display: block;
    padding: 0;
    border-bottom: 1px solid #f1f5f9;
    text-decoration: none;
    color: inherit;
    position: relative;
}
.fx-notif-row-link {
    display: flex;
    align-items: flex-start;
    gap: .55rem;
    padding: .7rem .95rem .5rem;
    text-decoration: none;
    color: inherit;
    cursor: pointer;
}
.fx-notif-row-link:hover { background: #f8fafc; }
.fx-notif-unread-dot {
    flex: 0 0 8px;
    width: 8px;
    height: 8px;
    margin-top: .45rem;
    border-radius: 999px;
    background: transparent;
}
.fx-notif-row.is-unread .fx-notif-unread-dot { background: #25d366; }
.fx-notif-row.is-unread .fx-notif-row-link { background: #f0fdf4; }
.fx-notif-row.is-unread .fx-notif-row-title { font-weight: 800; }
.fx-notif-row.is-read .fx-notif-row-link { opacity: .88; }
.fx-notif-row-main { min-width: 0; flex: 1; }
.fx-notif-row-top {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: .5rem;
    margin-bottom: .12rem;
}
.fx-notif-row-from { font-size: .72rem; font-weight: 700; color: #0f766e; }
.fx-notif-row-ago { font-size: .7rem; color: #94a3b8; white-space: nowrap; }
.fx-notif-row-meta { font-size: .68rem; color: #94a3b8; margin-top: .2rem; }
.fx-notif-row-title { font-size: .9rem; color: #0f172a; }
.fx-notif-row-body {
    font-size: .8rem;
    color: #475569;
    margin-top: .12rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.fx-notif-sticky-dot {
    display: inline-block;
    margin-inline-start: .4rem;
    font-size: .65rem;
    font-weight: 800;
    color: #0f766e;
    background: #ccfbf1;
    border-radius: 999px;
    padding: .05rem .4rem;
    vertical-align: middle;
}
.fx-notif-row-actions {
    display: flex;
    justify-content: flex-end;
    padding: 0 .75rem .55rem;
}
.fx-notif-row.is-unread .fx-notif-row-actions {
    background: #f0fdf4;
}
.fx-notif-read-mini {
    border: 0;
    background: transparent;
    color: #64748b;
    font-size: .72rem;
    font-weight: 700;
    padding: .15rem .35rem;
    line-height: 1.2;
    text-decoration: underline;
    cursor: pointer;
}
.fx-notif-read-mini:hover { color: #0f172a; }
.fx-notif-panel-all {
    padding: .45rem .85rem .65rem;
    border-top: 1px solid #e2e8f0;
    text-align: center;
    background: #fff;
    flex-shrink: 0;
}
.fx-notif-all-link {
    display: inline-block;
    font-size: .85rem;
    font-weight: 800;
    color: #0369a1;
    text-decoration: none;
}
.fx-notif-all-link:hover { text-decoration: underline; color: #0c4a6e; }
.fx-notif-item.is-unread {
    background: linear-gradient(90deg, #fff7ed, #fff);
    border-inline-start: 4px solid #f59e0b;
}
.fx-notif-item.is-task .fx-notif-subject { font-weight: 800; }
.fx-notif-item.is-read { opacity: .9; }
.fx-notif-item.is-normal .fx-notif-subject { font-weight: 600; color: #334155; }
.fx-notif-item-actions .btn { font-size: .75rem; padding: .2rem .45rem; }
.fx-notif-item-flash {
    outline: 2px solid #38bdf8;
    outline-offset: 2px;
    transition: outline-color .8s ease;
}
body.fx-notif-menu-open { overflow: hidden; }
@media (max-width: 768px) {
    .fx-quick-menu.fx-notif-menu {
        width: calc(100vw - 1.5rem);
        max-width: calc(100vw - 1.5rem);
        right: .75rem;
        left: .75rem;
    }
}

/* بريد داخلي مصغّر */
.fx-mail-shell {
    display: grid;
    grid-template-columns: 180px minmax(0, 1fr);
    gap: 1rem;
    align-items: start;
}
.fx-mail-folders {
    display: flex;
    flex-direction: column;
    gap: .25rem;
    position: sticky;
    top: calc(var(--fx-chrome-h, 90px) + .5rem);
}
.fx-mail-folder {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: .55rem .75rem;
    border-radius: 10px;
    font-weight: 700;
    color: #334155;
    text-decoration: none;
}
.fx-mail-folder:hover { background: #f1f5f9; }
.fx-mail-folder.is-active {
    background: #e0f2fe;
    color: #0369a1;
}
.fx-mail-folder-badge {
    min-width: 1.35rem;
    padding: 0 .35rem;
    border-radius: 999px;
    background: #dc2626;
    color: #fff;
    font-size: .7rem;
    font-weight: 800;
    text-align: center;
    line-height: 1.35rem;
}
.fx-mail-list { overflow: hidden; }
.fx-mail-row.is-unread .fx-mail-row-subject,
.fx-mail-row.is-unread .fx-mail-row-people { font-weight: 800; }
.fx-mail-row.is-unread { background: #fff7ed; }
.fx-mail-row-top {
    display: flex;
    justify-content: space-between;
    gap: .75rem;
    margin-bottom: .15rem;
}
.fx-mail-row-date { font-size: .75rem; color: #64748b; white-space: nowrap; }
.fx-mail-row-subject { color: #0f172a; }
.fx-mail-row-preview {
    font-size: .8rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.fx-mail-compose { max-width: 720px; }
.fx-mail-msg {
    padding: 1rem 1.15rem;
    border-bottom: 1px solid #f1f5f9;
}
.fx-mail-msg.is-mine { background: #f8fafc; }
.fx-mail-msg-meta {
    display: flex;
    justify-content: space-between;
    gap: .75rem;
    margin-bottom: .35rem;
}
.fx-mail-msg-body {
    white-space: pre-wrap;
    word-break: break-word;
    color: #1e293b;
    line-height: 1.55;
}
@media (max-width: 768px) {
    .fx-mail-shell { grid-template-columns: 1fr; }
    .fx-mail-folders {
        flex-direction: row;
        flex-wrap: wrap;
        position: static;
    }
}

/* منشور رسمي (أسلوب فيسبوك مبسّط) */
.fx-post-card .fx-post-head,
.fx-comment {
    display: flex;
    gap: .75rem;
    align-items: flex-start;
}
.fx-post-avatar,
.fx-comment-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #e0f2fe;
    color: #0369a1;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.fx-comment-avatar {
    width: 32px;
    height: 32px;
    font-size: .85rem;
    background: #f1f5f9;
    color: #475569;
}
.fx-post-body,
.fx-comment-body {
    white-space: pre-wrap;
    word-break: break-word;
    line-height: 1.55;
    color: #1e293b;
}
.fx-post-reacts,
.fx-comment-reacts {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .35rem;
}
.fx-react-btn {
    border: 1px solid #e2e8f0;
    background: #fff;
    border-radius: 999px;
    padding: .25rem .7rem;
    font-size: .78rem;
    font-weight: 700;
    color: #475569;
    cursor: pointer;
}
.fx-react-btn.is-mini { padding: .12rem .45rem; font-size: .72rem; }
.fx-react-btn.is-on {
    background: #dbeafe;
    border-color: #93c5fd;
    color: #1d4ed8;
}
.fx-react-btn.is-on-dislike {
    background: #fee2e2;
    border-color: #fca5a5;
    color: #b91c1c;
}
.fx-comment {
    padding: .85rem 1rem;
    border-bottom: 1px solid #f1f5f9;
}
.fx-comment-main { flex: 1; min-width: 0; }
.fx-comment-bubble {
    background: #f8fafc;
    border-radius: 14px;
    padding: .55rem .8rem;
}
.fx-comment-meta {
    display: flex;
    justify-content: space-between;
    gap: .5rem;
    margin-bottom: .2rem;
}
.fx-comment-reacts { margin-top: .35rem; margin-inline-start: .25rem; }
.fx-notif-tabs .nav-link { font-weight: 700; }

.fx-ico {
    display: block;
    object-fit: contain;
}

/* فاصل لطيف بظل بدل عناوين المخزون/العمليات */
.fx-sidebar-hr,
.fx-hr-wrap .fx-sidebar-hr {
    border: 0;
    height: 1px;
    margin: 0.55rem 1rem;
    background: linear-gradient(90deg, transparent, #d9deea 18%, #d9deea 82%, transparent);
    box-shadow: 0 6px 14px rgba(31, 42, 68, 0.12);
}
.fx-hr-wrap {
    list-style: none;
    padding: 0.35rem 0 0.55rem;
}

.sidebar {
    flex: 1;
    overflow: auto;
    padding: 0.15rem 0.85rem 1rem;
}
.sidebar .nav { list-style: none; padding: 0; margin: 0; }

.sidebar .nav-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.65rem;
    width: 100%;
    border: 0;
    background: transparent;
    color: var(--fx-icon);
    font-weight: 600;
    font-family: inherit;
    font-size: 0.94rem;
    padding: 0.7rem 0.85rem;
    border-radius: 12px;
    text-align: right;
    transition: 0.15s ease;
}
.sidebar .nav-link:hover {
    background: var(--fx-primary-soft);
    color: var(--fx-text);
}
.sidebar .nav-link.active,
.sidebar .nav-link.active:hover {
    background: var(--fx-primary-soft);
    color: var(--fx-icon-active);
    font-weight: 800;
}
.sidebar .nav-link > span {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
}
.sidebar .nav-link i {
    width: 18px;
    text-align: center;
    color: var(--fx-icon);
}
.sidebar .nav-link:hover i,
.sidebar .nav-link.active i { color: var(--fx-icon-active); }

/* تبديل مهنة المشرف — قبل المراقبة دائماً */
.fx-profession-item {
    list-style: none;
}
.fx-profession-switch {
    margin: 0 0.35rem 0.55rem;
    padding: 0.55rem 0.65rem;
    border-radius: 12px;
    background: linear-gradient(180deg, #fff, #f8fafc);
    border: 1px solid rgba(15, 118, 110, 0.22);
    box-shadow: 0 6px 14px rgba(15, 23, 42, 0.06);
}
.fx-profession-label {
    display: block;
    font-size: 0.72rem;
    font-weight: 800;
    color: #0f766e;
    margin-bottom: 0.25rem;
}
.fx-profession-select {
    font-weight: 700;
    border-color: rgba(13, 148, 136, 0.35);
    background: #fff;
}
.fx-profession-hint {
    margin-top: 0.35rem;
    font-size: 0.65rem;
    line-height: 1.35;
    color: #64748b;
}
.fx-profession-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    flex-shrink: 0;
    padding: 0.12rem 0.55rem;
    border-radius: 999px;
    border: 1px solid rgba(15, 118, 110, 0.3);
    background: rgba(255, 255, 255, 0.7);
    color: #0f766e;
    font-size: 0.74rem;
}
.fx-profession-pill em {
    font-style: normal;
    font-weight: 800;
}

/* شاشة المراقبة — عنصر قيادي متميز */
.sidebar .nav-link.fx-nav-monitor {
    position: relative;
    color: var(--fx-icon-active);
    font-weight: 800;
    background:
        linear-gradient(135deg, rgba(75, 203, 235, 0.22), rgba(34, 197, 94, 0.12) 55%, rgba(15, 118, 110, 0.08));
    border: 1px solid rgba(75, 203, 235, 0.45);
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.65) inset,
        0 8px 18px rgba(15, 118, 110, 0.16),
        0 0 22px rgba(75, 203, 235, 0.28);
    margin-bottom: 0.35rem;
}
.sidebar .nav-link.fx-nav-monitor i {
    color: var(--fx-icon-active);
    filter: drop-shadow(0 0 6px rgba(75, 203, 235, 0.7));
}
.sidebar .nav-link.fx-nav-monitor:hover {
    color: var(--fx-icon-active);
    background:
        linear-gradient(135deg, rgba(75, 203, 235, 0.32), rgba(34, 197, 94, 0.16) 55%, rgba(15, 118, 110, 0.1));
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.75) inset,
        0 10px 22px rgba(15, 118, 110, 0.22),
        0 0 28px rgba(75, 203, 235, 0.4);
    transform: translateY(-1px);
}
.sidebar .nav-link.fx-nav-monitor.active,
.sidebar .nav-link.fx-nav-monitor.active:hover {
    color: var(--fx-icon-active);
    background:
        linear-gradient(135deg, rgba(75, 203, 235, 0.38), rgba(34, 197, 94, 0.2));
    border-color: rgba(13, 148, 136, 0.55);
    box-shadow:
        0 0 0 2px rgba(13, 148, 136, 0.18),
        0 10px 24px rgba(15, 118, 110, 0.25),
        0 0 30px rgba(75, 203, 235, 0.45);
}
.sidebar .nav-link.fx-nav-monitor.active i { color: var(--fx-icon-active); }

/* تذييل المنصة صغير جداً */
.sidebar-footer.fx-platform-foot {
    border-top: 1px solid var(--fx-border);
    padding: 0.55rem 0.75rem 0.7rem;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.45rem;
}
.fx-sidebar-profile {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    padding: 0.45rem 0.6rem;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.82rem;
    color: #334155;
    background: #f8fafc;
    border: 1px solid var(--fx-border);
}
.fx-sidebar-profile:hover,
.fx-sidebar-profile.is-active {
    color: #0f766e;
    border-color: rgba(13, 148, 136, 0.35);
    background: #ecfdf5;
}
.fx-end-shift-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    width: 100%;
    padding: 0.65rem 0.75rem;
    border-radius: 12px;
    text-decoration: none !important;
    font-weight: 800;
    font-size: 0.9rem;
    color: #fff !important;
    background: linear-gradient(180deg, #ef4444, #b91c1c);
    border: 1px solid #991b1b;
    box-shadow: 0 8px 16px rgba(185, 28, 28, 0.28);
}
.fx-end-shift-btn:hover {
    color: #fff !important;
    filter: brightness(1.05);
    transform: translateY(-1px);
}
.fx-platform-mini-logo {
    height: 10px;
    width: auto;
    opacity: 0.55;
    align-self: center;
}
.fx-platform-copy {
    font-size: 8px;
    line-height: 1.2;
    color: #9aa3b5;
    font-weight: 600;
    letter-spacing: 0.01em;
    text-align: center;
}

.fx-brand,
.fx-profile,
.fx-nav-label,
.brand-link { display: none !important; }

/* ---- Main ---- */
.wrapper { min-height: 100vh; }
.main-content {
    margin-right: var(--fx-sidebar-w);
    margin-top: var(--fx-chrome-h);
    padding: 0.5rem 1.75rem 2rem;
    min-height: calc(100vh - var(--fx-chrome-h));
}

/* كاشير: بلا سايدبار — أزرار قليلة في الناف بار + منيو ☰ */
body.fx-cashier-shell {
    --fx-sidebar-w: 0px;
}
body.fx-cashier-shell .main-header {
    right: 0;
}
body.fx-cashier-shell .main-content {
    margin-right: 0;
}
body.fx-cashier-shell .fx-cashier-tools {
    width: auto;
    margin: 0;
    margin-inline-end: 0.55rem;
    padding: 0;
    gap: 0.7rem;
    justify-content: flex-start;
    flex-shrink: 0;
}
@media (max-width: 1100px) {
    body.fx-cashier-shell .fx-subnav-label { display: inline; }
    body.fx-cashier-shell .fx-subnav-btn { width: auto; padding: 0 0.65rem; justify-content: center; }
}
@media (max-width: 700px) {
    body.fx-cashier-shell .fx-subnav-label { display: none; }
    body.fx-cashier-shell .fx-subnav-btn { width: 40px; padding: 0; }
}

/* ---- Cards / DashFlat surfaces ---- */
.card {
    border: 0 !important;
    border-radius: var(--fx-radius) !important;
    background: var(--fx-surface);
    box-shadow: var(--fx-shadow);
    margin-bottom: 1.25rem;
    overflow: hidden;
}
.card-header {
    background: transparent;
    border-bottom: 1px solid var(--fx-border);
    padding: 1.1rem 1.25rem;
    font-weight: 800;
    color: var(--fx-text);
}
.card-body { padding: 1.25rem; }

.fx-page-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.35rem;
}
.fx-page-title {
    font-size: 1.55rem;
    font-weight: 800;
    color: var(--fx-text);
    margin: 0;
}
.fx-tabs {
    display: inline-flex;
    gap: 0.35rem;
    background: #eef1f7;
    border-radius: 999px;
    padding: 0.25rem;
}
.fx-tabs a,
.fx-tabs button {
    border: 0;
    background: transparent;
    color: var(--fx-muted);
    font-weight: 700;
    font-family: inherit;
    font-size: 0.86rem;
    padding: 0.45rem 0.9rem;
    border-radius: 999px;
}
.fx-tabs .active {
    background: var(--fx-surface);
    color: var(--fx-text);
    box-shadow: 0 2px 8px rgba(31, 42, 68, 0.08);
}
.fx-period {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    background: var(--fx-surface);
    border: 1px solid var(--fx-border);
    border-radius: 999px;
    padding: 0.45rem 0.9rem;
    color: var(--fx-muted);
    font-weight: 700;
    font-size: 0.86rem;
}

.fx-kpi {
    background: var(--fx-surface);
    border-radius: var(--fx-radius);
    box-shadow: var(--fx-shadow);
    padding: 1.15rem 1.2rem 1rem;
    height: 100%;
}
.fx-kpi-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.55rem;
}
.fx-kpi-label {
    color: var(--fx-muted);
    font-weight: 700;
    font-size: 0.9rem;
}
.fx-kpi-delta {
    font-size: 0.78rem;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
}
.fx-kpi-delta.up { color: var(--fx-success); }
.fx-kpi-delta.down { color: var(--fx-danger); }
.fx-kpi-value {
    font-size: 1.7rem;
    font-weight: 800;
    color: var(--fx-text);
    line-height: 1.15;
    font-family: 'Montserrat', 'Cairo', sans-serif;
}
.fx-spark {
    display: flex;
    align-items: flex-end;
    gap: 4px;
    height: 28px;
    margin-top: 0.85rem;
}
.fx-spark span {
    flex: 1;
    border-radius: 4px 4px 0 0;
    background: linear-gradient(180deg, var(--fx-primary) 0%, rgba(15, 118, 110, 0.25) 100%);
    opacity: 0.85;
}

.fx-panel {
    background: var(--fx-surface);
    border-radius: var(--fx-radius);
    box-shadow: var(--fx-shadow);
    padding: 1.25rem;
    height: 100%;
}
.fx-panel-title {
    font-weight: 800;
    color: var(--fx-text);
    margin-bottom: 0.75rem;
}
.fx-chart-placeholder {
    height: 220px;
    border-radius: 12px;
    background:
        linear-gradient(180deg, rgba(15, 118, 110, 0.16) 0%, rgba(15, 118, 110, 0.02) 70%, transparent 100%),
        repeating-linear-gradient(
            90deg,
            transparent 0,
            transparent 48px,
            rgba(238, 241, 246, 0.8) 48px,
            rgba(238, 241, 246, 0.8) 49px
        );
    position: relative;
    overflow: hidden;
}
.fx-chart-placeholder::after {
    content: "";
    position: absolute;
    left: 8%;
    right: 8%;
    bottom: 28%;
    height: 3px;
    border-radius: 999px;
    background: var(--fx-primary);
    box-shadow: 0 0 0 6px rgba(15, 118, 110, 0.08);
    transform: rotate(-6deg);
}

/* ---- Buttons / Forms / Tables ---- */
.btn {
    font-weight: 700;
    border-radius: 10px;
    padding: 0.6rem 1.1rem;
    transition: 0.15s ease;
    box-shadow: none;
}
.btn-teal,
.btn-primary {
    background: var(--fx-primary) !important;
    border-color: var(--fx-primary) !important;
    color: #fff !important;
}
.btn-teal:hover,
.btn-primary:hover {
    background: var(--fx-primary-hover) !important;
    border-color: var(--fx-primary-hover) !important;
    color: #fff !important;
    transform: translateY(-1px);
    box-shadow: 0 8px 18px rgba(15, 118, 110, 0.25);
}
.btn-outline-primary {
    color: var(--fx-primary);
    border-color: rgba(15, 118, 110, 0.35);
}
.btn-outline-primary:hover {
    background: var(--fx-primary);
    border-color: var(--fx-primary);
    color: #fff;
}

.form-control,
.form-select {
    border-radius: 12px;
    border: 1px solid #e6ebf2;
    padding: 0.7rem 1rem;
    background: #fcfdff;
    color: var(--fx-text);
}
.form-control:focus,
.form-select:focus {
    border-color: var(--fx-primary);
    box-shadow: 0 0 0 0.2rem rgba(15, 118, 110, 0.15);
    background: #fff;
}

.table { color: var(--fx-text); margin-bottom: 0; }
.table th,
.table td {
    padding: 0.95rem 1rem;
    vertical-align: middle;
    border-color: var(--fx-border) !important;
}
.table thead th {
    background: #f8fafc;
    color: #667085;
    font-size: 0.8rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    border-bottom-width: 1px !important;
}
.table-hover tbody tr:hover { background: #fafbff; }

.badge {
    border-radius: 999px;
    padding: 0.35rem 0.7rem;
    font-weight: 800;
    font-size: 0.75rem;
}
.badge.bg-primary,
.badge.bg-info { background: var(--fx-primary) !important; }
.badge.bg-success { background: var(--fx-success) !important; }
.badge.bg-danger { background: var(--fx-danger) !important; }
.badge.bg-secondary { background: #98a2b3 !important; }
.badge.bg-dark { background: #344054 !important; }

.alert {
    border: 0;
    border-radius: 12px;
    box-shadow: var(--fx-shadow);
}

@media (max-width: 991.98px) {
    /* إخفاء السايدبار مع الإبقاء على أيقونات الرئيسية/المنيو/الجرس */
    .sidebar-container {
        position: static;
        width: 0;
        height: 0;
        overflow: visible;
        border: 0;
        background: transparent;
        box-shadow: none;
        z-index: 1201;
    }
    .fx-project-head > *:not(.fx-sidebar-tools),
    .fx-sidebar-hr,
    .sidebar,
    .sidebar-footer {
        display: none !important;
    }
    .fx-project-head {
        padding: 0;
        margin: 0;
        gap: 0;
    }
    .fx-sidebar-tools {
        position: fixed;
        top: calc(var(--fx-chrome-h) + 0.55rem);
        right: 0.85rem;
        left: auto;
        width: auto;
        margin: 0;
        z-index: 1201;
        background: transparent;
        box-shadow: none;
        padding: 0;
        gap: 0.85rem;
    }
    .fx-float-actions {
        left: 0.75rem;
        top: calc(var(--fx-chrome-h) + 0.75rem);
    }
    .fx-float-back {
        left: auto;
        top: auto;
    }
    .main-header { right: 0; }
    .main-content { margin-right: 0; padding: 0.75rem 1rem 1.5rem; }
    .fx-subnav { padding-left: 1rem; padding-right: 1rem; }
    .fx-search { min-width: 0; flex: 1; }
}

/* أزرار إجراءات بأيقونات محلية (تعديل / حذف / إضافة …) */
.fx-icon-actions {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    flex-wrap: wrap;
}
.fx-icon-actions.fx-nowrap {
    flex-wrap: nowrap;
}
.fx-icon-actions form {
    display: inline-flex;
    margin: 0;
}
.fx-icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    padding: 0;
    border-radius: 9px;
    border: 1px solid var(--fx-border);
    background: var(--fx-surface);
    color: var(--fx-icon);
    text-decoration: none;
    cursor: pointer;
    transition: background .12s ease, border-color .12s ease, transform .12s ease;
}
.fx-icon-btn img {
    width: 16px;
    height: 16px;
    display: block;
    pointer-events: none;
}
.fx-icon-btn:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
    transform: translateY(-1px);
}
.fx-icon-btn.is-add {
    width: auto;
    min-width: 34px;
    height: 36px;
    padding: 0 0.7rem;
    gap: 0.35rem;
    background: var(--fx-primary, #0f766e);
    border-color: var(--fx-primary, #0f766e);
    color: #fff;
    font-weight: 800;
    font-size: 0.82rem;
}
.fx-icon-btn.is-add img {
    filter: brightness(0) invert(1);
}
.fx-icon-btn.is-add:hover {
    filter: brightness(0.95);
}
.fx-icon-btn.is-collect {
    background: #16a34a;
    border-color: #16a34a;
}
.fx-icon-btn.is-collect img {
    filter: brightness(0) invert(1);
}
.fx-icon-btn.is-collect:hover {
    background: #15803d;
    border-color: #15803d;
    transform: translateY(-1px);
}
.fx-icon-btn.is-edit:hover { border-color: #93c5fd; background: #eff6ff; }
/* حذف / سلة مهملات — أحمر دائماً لدرجة الخطورة */
.fx-icon-btn.is-del,
.fx-icon-btn.is-delete {
    border-color: rgba(220, 38, 38, 0.38);
    color: #dc2626;
    background: rgba(254, 242, 242, 0.7);
}
.fx-icon-btn.is-del img,
.fx-icon-btn.is-del .fx-ico,
.fx-icon-btn.is-delete img,
.fx-icon-btn.is-delete .fx-ico {
    filter: brightness(0) saturate(100%) invert(22%) sepia(92%) saturate(3200%) hue-rotate(350deg) brightness(0.95) contrast(1.05) !important;
    opacity: 1 !important;
}
.fx-icon-btn.is-del:hover,
.fx-icon-btn.is-delete:hover {
    border-color: #f87171;
    background: #fef2f2;
    color: #b91c1c;
}
.fx-icon-btn.is-del:hover img,
.fx-icon-btn.is-del:hover .fx-ico,
.fx-icon-btn.is-delete:hover img,
.fx-icon-btn.is-delete:hover .fx-ico {
    filter: brightness(0) saturate(100%) invert(18%) sepia(95%) saturate(3400%) hue-rotate(350deg) brightness(0.9) contrast(1.1) !important;
}
.fx-icon-btn.is-view:hover { border-color: #94a3b8; background: #f1f5f9; }
.fx-icon-btn.is-view:has(span) {
    width: auto;
    min-width: 44px;
    height: 44px;
    padding: 0 1rem;
    gap: 0.45rem;
    font-weight: 800;
    font-size: 0.95rem;
}
.fx-icon-btn.is-view:has(span) img {
    width: 18px;
    height: 18px;
}
.fx-icon-btn.is-stock:hover { border-color: #86efac; background: #f0fdf4; }
.fx-icon-btn.is-print:hover { border-color: #c4b5fd; background: #f5f3ff; }
.fx-icon-btn.is-warn:hover { border-color: #fcd34d; background: #fffbeb; }

/* ---- Payment account picker cards (صف واحد يلتف — بدون تكدس عمودي مؤذٍ) ---- */
.fx-pay-cards {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    gap: .55rem;
}
.fx-pay-card {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: .3rem;
    flex: 1 1 108px;
    max-width: 148px;
    min-width: 100px;
    min-height: 92px;
    padding: .5rem .35rem;
    border-radius: 14px;
    border: 2px solid #e2e8f0;
    background: #f8fafc;
    cursor: pointer;
    font-weight: 800;
    color: #64748b;
    transition: filter .15s ease, border-color .15s ease, transform .12s ease, box-shadow .15s ease, background .15s ease, color .15s ease;
    filter: grayscale(1) saturate(0.2) brightness(0.96);
    opacity: .88;
    user-select: none;
}
.fx-pay-card img {
    width: 40px;
    height: 40px;
    object-fit: contain;
    border-radius: 10px;
    background: #fff;
}
.fx-pay-card .fx-pay-card-ico {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #e2e8f0;
    color: #64748b;
    font-size: 1.05rem;
}
.fx-pay-card .fx-pay-card-name {
    font-size: .72rem;
    text-align: center;
    line-height: 1.2;
    max-width: 100%;
    word-break: break-word;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.fx-pay-card .fx-pay-card-currency {
    font-size: .65rem;
    font-weight: 700;
    opacity: .85;
    line-height: 1.1;
}
.fx-pay-card .fx-pay-card-balance {
    font-size: .78rem;
    font-weight: 900;
    font-variant-numeric: tabular-nums;
    line-height: 1.1;
    color: #475569;
}
.fx-pay-card .fx-pay-card-balance.is-enough {
    color: #15803d !important;
}
.fx-pay-card .fx-pay-card-balance.is-short {
    color: #dc2626 !important;
}
/* إظهار ألوان الرصيد بوضوح — الصفة على الحاوية data-fx-pay-cards وليس .fx-pay-cards */
[data-fx-pay-cards][data-fx-pay-compare-input] .fx-pay-card,
[data-fx-pay-cards][data-fx-pay-compare-amount] .fx-pay-card {
    filter: none;
    opacity: 1;
}
[data-fx-pay-cards][data-fx-pay-compare-input] .fx-pay-card:not(.is-on):not(:hover),
[data-fx-pay-cards][data-fx-pay-compare-amount] .fx-pay-card:not(.is-on):not(:hover) {
    background: #f8fafc;
    border-color: #e2e8f0;
    color: #475569;
    box-shadow: none;
    transform: none;
}
.fx-pay-card:hover .fx-pay-card-balance,
.fx-pay-card.is-on .fx-pay-card-balance {
    filter: none;
}
.fx-pay-card:hover,
.fx-pay-card.is-on,
.fx-pay-card:focus-visible {
    filter: none;
    opacity: 1;
    color: #0f172a;
    border-color: var(--fx-primary);
    background: #fff;
    transform: translateY(-2px);
    box-shadow: 0 8px 18px rgba(15, 23, 42, .12);
    outline: none;
}
.fx-pay-card.is-on {
    border-width: 2px;
    box-shadow: 0 0 0 3px var(--fx-primary-soft), 0 8px 18px rgba(15, 23, 42, .12);
}
.fx-pay-card input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}
.fx-pay-cards.is-on-dark-bg .fx-pay-card {
    background: rgba(255,255,255,.88);
    border-color: rgba(255,255,255,.25);
}
.fx-pay-cards.is-on-dark-bg .fx-pay-card:hover,
.fx-pay-cards.is-on-dark-bg .fx-pay-card.is-on {
    background: #fff;
}
.fx-pay-group-title {
    font-size: .82rem;
    font-weight: 800;
    color: #0f172a;
    margin: .55rem 0 .45rem;
}
.fx-pay-group-title:first-child { margin-top: 0; }
.fx-pay-card-type {
    display: inline-block;
    font-size: .62rem;
    font-weight: 800;
    padding: .08rem .4rem;
    border-radius: 999px;
    background: #e2e8f0;
    color: #334155;
}
.fx-pay-card.is-on .fx-pay-card-type {
    background: var(--fx-primary-soft, #dbeafe);
    color: var(--fx-primary, #2563eb);
}

/* ---- بطاقة زبون مضغوطة: اسم + هاتف | مبلغ / عليه|/له ---- */
.fx-cust-chip {
    padding: .65rem .85rem .7rem;
}
.fx-cust-chip-main {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
    min-width: 0;
}
.fx-cust-chip-name {
    font-weight: 800;
    font-size: 1rem;
    line-height: 1.25;
    color: #0f172a;
}
.fx-cust-chip-phone {
    font-size: .78rem;
    color: #64748b;
    margin-top: .1rem;
}
.fx-cust-chip-bal {
    flex-shrink: 0;
    display: flex;
    align-items: baseline;
    gap: .35rem;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
}
.fx-cust-chip-amt {
    font-size: 1.55rem;
    letter-spacing: -0.02em;
}
.fx-cust-chip-side {
    font-size: 1.15rem;
}
.fx-cust-chip-bal.is-owe { color: #dc2626; }
.fx-cust-chip-bal.is-credit { color: #16a34a; }
.fx-cust-chip-bal.is-clear { color: #64748b; }
.fx-cust-chip-actions {
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
    margin-top: .55rem;
}
.fx-cust-chip-actions .btn {
    padding: .25rem .7rem;
    font-size: .8rem;
}

/* ==========================================================
   Navigation hub — simple ops tiles + advanced accounting shell
   ========================================================== */
body.fx-ui-advanced {
    --fx-sidebar-w: 288px;
}
.fx-nav-group-label {
    list-style: none;
    margin: 0.85rem 0.85rem 0.35rem;
    padding: 0.2rem 0.35rem;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--fx-muted);
    text-transform: none;
    border-right: 3px solid var(--fx-border);
}
.fx-nav-group-label.is-accounting {
    color: #0f766e;
    border-right-color: #0d9488;
    background: rgba(13, 148, 136, 0.08);
    border-radius: 0 8px 8px 0;
}
.fx-nav-tree .nav-item { margin-bottom: 0.15rem; }
.fx-nav-tree .nav-link {
    padding: 0.42rem 0.85rem;
    font-size: 0.88rem;
    border-radius: 10px;
}
.sidebar-container.is-advanced-nav .sidebar {
    padding-bottom: 0.5rem;
}
.fx-subnav.is-advanced-subnav .fx-subnav-btn {
    border-color: var(--fx-border);
    background: var(--fx-surface);
}
.fx-subnav.is-advanced-subnav .fx-subnav-btn i { color: var(--fx-icon-active); }
.fx-subnav.is-advanced-subnav .fx-subnav-btn.active,
.fx-subnav.is-advanced-subnav .fx-subnav-btn:hover {
    border-color: var(--fx-primary);
    background: var(--fx-primary-soft);
}
.fx-subnav.is-advanced-subnav .fx-subnav-btn.is-solid {
    background: var(--fx-primary);
    border-color: var(--fx-primary);
    color: var(--fx-icon-on-solid);
}
.fx-subnav.is-advanced-subnav .fx-subnav-btn.is-solid i { color: var(--fx-icon-on-solid); }
.fx-subnav.is-advanced-subnav .fx-subnav-btn.is-return-soft,
.fx-subnav.is-simple-subnav .fx-subnav-btn.is-return-soft {
    background: #fff5f5;
    color: #c53030;
    border-color: #fed7d7;
}
.fx-subnav.is-advanced-subnav .fx-subnav-btn.is-return-soft i,
.fx-subnav.is-simple-subnav .fx-subnav-btn.is-return-soft i,
.fx-subnav .fx-subnav-btn.is-return-soft .fx-ico {
    color: #e53e3e;
}
.fx-subnav .fx-subnav-btn.is-day-close,
.fx-subnav.is-advanced-subnav .fx-subnav-btn.is-day-close,
.fx-subnav.is-simple-subnav .fx-subnav-btn.is-day-close {
    background: linear-gradient(180deg, #ef4444, #b91c1c) !important;
    color: #fff !important;
    border-color: #991b1b !important;
    box-shadow: 0 6px 14px rgba(185, 28, 28, 0.28) !important;
}
.fx-subnav .fx-subnav-btn.is-day-close i,
.fx-subnav .fx-subnav-btn.is-day-close .fx-ico,
.fx-subnav.is-advanced-subnav .fx-subnav-btn.is-day-close i {
    color: #fff !important;
    filter: brightness(0) invert(1);
    opacity: 1;
}
.fx-subnav .fx-subnav-btn.is-day-close:hover,
.fx-subnav .fx-subnav-btn.is-day-close.active,
.fx-subnav.is-advanced-subnav .fx-subnav-btn.is-day-close:hover,
.fx-subnav.is-advanced-subnav .fx-subnav-btn.is-day-close.active {
    background: #991b1b !important;
    color: #fff !important;
    border-color: #7f1d1d !important;
}
.fx-subnav.is-advanced-subnav .fx-subnav-btn.is-return-soft:hover,
.fx-subnav.is-advanced-subnav .fx-subnav-btn.is-return-soft.active,
.fx-subnav.is-simple-subnav .fx-subnav-btn.is-return-soft:hover,
.fx-subnav.is-simple-subnav .fx-subnav-btn.is-return-soft.active {
    background: #ffe8e8;
    color: #9b2c2c;
    border-color: #feb2b2;
}

.fx-hub-head { margin: 0 0 0.85rem; }
.fx-hub-title {
    font-size: 1.05rem;
    font-weight: 700;
    margin: 0 0 0.2rem;
}
.fx-hub-hint {
    margin: 0;
    color: var(--fx-muted);
    font-size: 0.85rem;
}
.fx-hub-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(148px, 1fr));
    gap: 0.65rem;
    margin-bottom: 0;
    width: 100%;
}
.fx-hub-tile {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.4rem;
    min-height: 108px;
    padding: 0.85rem 0.9rem;
    background: var(--fx-surface);
    border: 1px solid var(--fx-border);
    border-radius: 16px;
    box-shadow: var(--fx-shadow);
    text-decoration: none;
    color: inherit;
    transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.fx-hub-tile:hover,
.fx-hub-tile.is-active {
    transform: translateY(-2px);
    border-color: #0d9488;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.1);
    color: inherit;
}
.fx-hub-ico {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 118, 110, 0.12);
    color: #0f766e;
    font-size: 1rem;
    flex: 0 0 auto;
}
.fx-hub-ico .fx-ico,
.fx-hub-ico img {
    width: 1.35rem !important;
    height: 1.35rem !important;
    display: block;
    object-fit: contain;
    opacity: 0.92;
}
.fx-hub-label {
    font-weight: 700;
    font-size: 0.92rem;
    line-height: 1.35;
}
.fx-hub-sub {
    font-size: 0.75rem;
    color: var(--fx-muted);
    line-height: 1.35;
}
/* أقسام أفقية واضحة: شبكة بالعرض + فراغ فاصل بين كل قسم */
.fx-hub {
    width: 100%;
}
.fx-hub-section {
    margin: 0 0 1.65rem;
    padding: 0.85rem 0.95rem 1rem;
    background: rgba(255, 255, 255, 0.25);
    border: 1px solid rgba(148, 163, 184, 0.35);
    border-inline-start: 4px solid color-mix(in srgb, var(--fx-primary, #1e6db5) 75%, #1e6db5);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.22) inset;
    border-radius: 12px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
.fx-hub-section:last-of-type {
    margin-bottom: 0.5rem;
}
.fx-hub-section-title {
    font-size: 0.95rem;
    font-weight: 800;
    color: var(--fx-text, #1e3a5f);
    margin: 0 0 0.75rem;
    padding-bottom: 0.45rem;
    border-bottom: 1px dashed color-mix(in srgb, var(--fx-border, #7a93ae) 65%, transparent);
}
    letter-spacing: 0.01em;
}
.fx-hub-find {
    max-width: 420px;
    border-radius: 999px;
    padding-inline: 1rem 0.85rem;
    border-color: var(--fx-border);
    background: var(--fx-surface);
}
.fx-hub-empty { margin: 0.5rem 0 0; }

.fx-remind-toast {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 12050;
    display: flex;
    align-items: center;
    gap: 0.65rem;
    flex-wrap: wrap;
    padding: 0.55rem 0.85rem;
    background: linear-gradient(90deg, #0f766e 0%, #115e59 100%);
    color: #ecfdf5;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.22);
    transform: translateY(-110%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.32s ease, opacity 0.28s ease;
}
.fx-remind-toast.is-on {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}
.fx-remind-toast-text {
    flex: 1 1 180px;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    font-size: 0.84rem;
    line-height: 1.35;
}
.fx-remind-toast-text strong { font-weight: 700; font-size: 0.9rem; }
.fx-remind-toast-btn {
    flex: 0 0 auto;
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    background: #fff;
    color: #0f766e;
    font-weight: 700;
    font-size: 0.82rem;
    text-decoration: none;
    white-space: nowrap;
}
.fx-remind-toast-btn:hover { color: #115e59; background: #f0fdfa; }
.fx-remind-toast-x {
    flex: 0 0 auto;
    border: 0;
    background: rgba(255, 255, 255, 0.14);
    color: #ecfdf5;
    border-radius: 999px;
    padding: 0.28rem 0.65rem;
    font-size: 0.78rem;
    cursor: pointer;
}
.fx-remind-toast-x:hover { background: rgba(255, 255, 255, 0.22); }

.fx-hub-tile.is-sales .fx-hub-ico { background: rgba(15, 118, 110, 0.12); color: var(--fx-primary); }
.fx-hub-tile.is-purchase .fx-hub-ico { background: rgba(14, 165, 233, 0.14); color: #0284c7; }
.fx-hub-tile.is-expense .fx-hub-ico { background: rgba(245, 158, 11, 0.16); color: #d97706; }
.fx-hub-tile.is-stock .fx-hub-ico { background: rgba(34, 197, 94, 0.14); color: #16a34a; }
.fx-hub-tile.is-cash .fx-hub-ico { background: rgba(20, 184, 166, 0.14); color: #0d9488; }
.fx-hub-tile.is-ledger .fx-hub-ico,
.fx-hub-tile.is-journal .fx-hub-ico { background: rgba(15, 118, 110, 0.14); color: #0f766e; }
.fx-hub-tile.is-report .fx-hub-ico { background: rgba(99, 102, 241, 0.12); color: #4f46e5; }
.fx-hub-tile.is-finance .fx-hub-ico { background: rgba(2, 132, 199, 0.12); color: #0369a1; }
.fx-hub-tile.is-assets .fx-hub-ico { background: rgba(100, 116, 139, 0.16); color: #475569; }
.fx-hub-tile.is-equity .fx-hub-ico { background: rgba(168, 85, 247, 0.12); color: #7e22ce; }
.fx-hub-tile.is-settings .fx-hub-ico { background: rgba(71, 85, 105, 0.14); color: #334155; }

@media (max-width: 991.98px) {
    body.fx-ui-advanced { --fx-sidebar-w: 260px; }
    body.fx-cashier-shell { --fx-sidebar-w: 0px; }
    .fx-hub-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
}

/* ==========================================================
   أيقونات تتبع الثيم — كل الستايلات (كلاسيك / زجاجي / ويندوز7)
   ========================================================== */
html[data-fx-theme="dark"] {
    --fx-icon: #c9d4e3;
    --fx-icon-active: var(--fx-primary);
    --fx-icon-on-solid: #ffffff;
}

/*
 * أيقونات SVG داكنة على خلفية داكنة = تشوّه بصري.
 * عند الثيم الداكن: اقلبها لفاتح (ما عدا أزرار ملونة لها فلترها الخاص).
 */
html[data-fx-theme="dark"] img.fx-ico,
html[data-fx-theme="dark"] .fx-side-tool:not(.is-day-close-tool):not(.is-calc):not(.is-trash):not(.is-notif-alert) .fx-ico,
html[data-fx-theme="dark"] .sidebar .nav-link .fx-ico,
html[data-fx-theme="dark"] .fx-nav-tree .nav-link .fx-ico,
html[data-fx-theme="dark"] .fx-icon-btn:not(.is-del):not(.is-delete):not(.is-add):not(.is-collect) img,
html[data-fx-theme="dark"] .fx-icon-btn:not(.is-del):not(.is-delete):not(.is-add):not(.is-collect) .fx-ico,
html[data-fx-theme="dark"] .fx-subnav-btn:not(.is-solid):not(.is-day-close):not(.is-return-soft) .fx-ico,
html[data-fx-theme="dark"] .fx-quick-btn .fx-ico,
html[data-fx-theme="dark"] .fx-quick-menu .fx-ico,
html[data-fx-theme="dark"] .fx-theme-toggle .fx-ico,
html[data-fx-theme="dark"] .fx-header-back .fx-ico,
html[data-fx-theme="dark"] .fx-hub-tile .fx-ico,
html[data-fx-theme="dark"] .fx-hub-ico .fx-ico,
html[data-fx-theme="dark"] .btn-outline-secondary .fx-ico,
html[data-fx-theme="dark"] .btn-outline-primary .fx-ico,
html[data-fx-theme="dark"] .btn-light .fx-ico,
html[data-fx-theme="dark"] .btn-link .fx-ico,
html[data-fx-theme="dark"] .dropdown-item .fx-ico,
html[data-fx-theme="dark"] .list-group-item .fx-ico,
html[data-fx-theme="dark"] .fx-account-menu .fx-ico,
html[data-fx-theme="dark"] .fx-notif-panel .fx-ico,
html[data-fx-theme="dark"] .fx-personal-menu .fx-ico,
html[data-fx-theme="dark"] .fx-search .fx-ico,
html[data-fx-theme="dark"] .fx-chip .fx-ico,
html[data-fx-theme="dark"] .fx-profession-pill .fx-ico,
html[data-fx-theme="dark"] .fx-ui-mode-pill .fx-ico,
html[data-fx-theme="dark"] .main-content .btn-outline-secondary .fx-ico,
html[data-fx-theme="dark"] .main-content .btn-light .fx-ico {
    filter: brightness(0) invert(0.92) !important;
    opacity: 0.92;
}

html[data-fx-theme="dark"] .fx-side-tool:not(.is-day-close-tool):not(.is-calc):not(.is-trash):not(.is-notif-alert):hover .fx-ico,
html[data-fx-theme="dark"] .fx-side-tool:not(.is-day-close-tool):not(.is-calc):not(.is-trash):not(.is-notif-alert).is-active .fx-ico,
html[data-fx-theme="dark"] .sidebar .nav-link:hover .fx-ico,
html[data-fx-theme="dark"] .sidebar .nav-link.active .fx-ico,
html[data-fx-theme="dark"] .fx-nav-tree .nav-link:hover .fx-ico,
html[data-fx-theme="dark"] .fx-nav-tree .nav-link.active .fx-ico,
html[data-fx-theme="dark"] .fx-icon-btn:not(.is-del):not(.is-delete):not(.is-add):not(.is-collect):hover img,
html[data-fx-theme="dark"] .fx-subnav-btn:not(.is-solid):not(.is-day-close):hover .fx-ico,
html[data-fx-theme="dark"] .fx-subnav-btn.active:not(.is-solid):not(.is-day-close) .fx-ico,
html[data-fx-theme="dark"] .fx-quick-btn:hover .fx-ico,
html[data-fx-theme="dark"] .fx-quick-btn.active .fx-ico {
    filter: brightness(0) invert(1) !important;
    opacity: 1;
}

/* استثناءات: أزرار ملونة تحتاج أبيض صريح */
html[data-fx-theme="dark"] .fx-side-tool.is-day-close-tool .fx-ico,
html[data-fx-theme="dark"] .fx-side-tool.is-calc .fx-ico,
html[data-fx-theme="dark"] .fx-side-tool.is-trash .fx-ico,
html[data-fx-theme="dark"] .fx-subnav-btn.is-solid .fx-ico,
html[data-fx-theme="dark"] .fx-subnav-btn.is-day-close .fx-ico,
html[data-fx-theme="dark"] .fx-icon-btn.is-add img,
html[data-fx-theme="dark"] .fx-icon-btn.is-collect img,
html[data-fx-theme="dark"] .fx-float-save .fx-ico,
html[data-fx-theme="dark"] .btn-primary .fx-ico,
html[data-fx-theme="dark"] .btn-success .fx-ico,
html[data-fx-theme="dark"] .btn-danger .fx-ico {
    filter: brightness(0) invert(1) !important;
    opacity: 1 !important;
}

/* جرس بتنبيه: أحمر واضح على الداكن */
html[data-fx-theme="dark"] .fx-side-tool.is-notif-alert .fx-ico {
    filter: invert(42%) sepia(90%) saturate(2200%) hue-rotate(340deg) brightness(1.15) contrast(1.05) !important;
    opacity: 1 !important;
}

/* حذف: يبقى أحمر */
html[data-fx-theme="dark"] .fx-icon-btn.is-del img,
html[data-fx-theme="dark"] .fx-icon-btn.is-del .fx-ico,
html[data-fx-theme="dark"] .fx-icon-btn.is-delete img,
html[data-fx-theme="dark"] .fx-icon-btn.is-delete .fx-ico {
    filter: brightness(0) saturate(100%) invert(55%) sepia(80%) saturate(2800%) hue-rotate(330deg) brightness(1.1) contrast(1.05) !important;
}

html[data-fx-shell="classic"][data-fx-theme="light"],
html[data-fx-shell="classic"]:not([data-fx-theme="dark"]) {
    /* الألوان التفصيلية في fastexa_breeze.css — هنا فقط أيقونات عامة */
    --fx-icon: #5b5678;
    --fx-icon-active: var(--fx-primary);
}

/* خلفية الناف بار — أزرق ويندوز XP / الأصيل (قشرة windows7 فقط) */
html[data-fx-shell="windows7"] .main-header {
    background: linear-gradient(180deg, var(--fx-nav-blue-top, #2d7ed0) 0%, var(--fx-nav-blue-mid, #2574c3) 48%, var(--fx-nav-blue-bot, #1a64b2) 100%) !important;
    border-bottom: 1px solid #0f4d8c !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22) !important;
}
html[data-fx-shell="windows7"] .fx-subnav,
html[data-fx-shell="windows7"] .fx-main-nav {
    background: transparent !important;
}
html[data-fx-shell="windows7"] .fx-ui-mode-bar,
html[data-fx-shell="windows7"] .fx-ui-mode-bar.is-simple,
html[data-fx-shell="windows7"] .fx-ui-mode-bar.is-advanced {
    background: linear-gradient(180deg, rgba(15, 70, 140, 0.35) 0%, rgba(10, 55, 120, 0.55) 100%) !important;
    border-top: 1px solid rgba(255, 255, 255, 0.18) !important;
    border-bottom: 0 !important;
    color: #fff !important;
}
html[data-fx-shell="windows7"] .fx-ui-mode-pill,
html[data-fx-shell="windows7"] .fx-profession-pill {
    background: rgba(255, 255, 255, 0.16) !important;
    border: 1px solid rgba(255, 255, 255, 0.35) !important;
    color: #fff !important;
    border-radius: 0 !important;
}
html[data-fx-shell="windows7"] .fx-ui-mode-pill strong,
html[data-fx-shell="windows7"] .fx-ui-mode-pill em,
html[data-fx-shell="windows7"] .fx-profession-pill strong,
html[data-fx-shell="windows7"] .fx-profession-pill em {
    color: #fff !important;
}
html[data-fx-shell="windows7"] .fx-header-back,
html[data-fx-shell="windows7"] .fx-ui-mode-switch,
html[data-fx-shell="windows7"] .fx-theme-toggle {
    background: rgba(255, 255, 255, 0.14) !important;
    border: 1px solid rgba(255, 255, 255, 0.4) !important;
    color: #fff !important;
    border-radius: 0 !important;
}
html[data-fx-shell="windows7"] .fx-header-back:hover,
html[data-fx-shell="windows7"] .fx-ui-mode-switch:hover,
html[data-fx-shell="windows7"] .fx-theme-toggle:hover {
    background: rgba(255, 255, 255, 0.28) !important;
    color: #fff !important;
}
html[data-fx-shell="windows7"] .fx-ui-mode-bar .fx-ico,
html[data-fx-shell="windows7"] .fx-header-back .fx-ico,
html[data-fx-shell="windows7"] .fx-theme-toggle .fx-ico {
    filter: brightness(0) invert(1);
    opacity: 0.95;
}

html[data-fx-shell="classic"][data-fx-theme="dark"] {
    --fx-icon: #c4b5fd;
    --fx-icon-active: #ddd6fe;
}

html[data-fx-shell="glass"] {
    --fx-icon: #b4bcc2;
    --fx-icon-active: #ffb347;
}

html[data-fx-shell="glass"][data-fx-theme="light"] {
    --fx-icon: #3d454b;
    --fx-icon-active: #e86a0e;
}

html[data-fx-shell="windows7"] {
    --fx-icon: #202020;
    --fx-icon-active: #245399;
}

/* أيقونات واجهة عامة — تباين واضح مع الخلفية */
.sidebar .nav-link i,
.fx-nav-tree .nav-link i,
.fx-search i,
.fx-chip i,
.fx-header-actions .fx-icon-btn,
.fx-header-actions .fx-icon-btn i,
.fx-theme-toggle i,
.fx-float-actions i,
.fx-float-actions a i,
.fx-sidebar-profile i,
.fx-profession-pill i,
.dropdown-item i,
.dropdown-menu i.fas,
.dropdown-menu i.far,
.dropdown-menu i.fab,
.list-group-item i.fas,
.list-group-item i.far,
.card-header > i,
.card-title i,
.alert i.fas,
.breadcrumb i,
.nav-tabs .nav-link i,
.page-link i,
.btn-outline-secondary i,
.btn-outline-primary i,
.btn-outline-danger i,
.btn-outline-success i,
.btn-light i,
.btn-link i,
a.text-muted i,
.text-muted > i.fas,
.text-muted > i.far,
.form-label i,
.input-group-text i,
.modal-header i,
.fx-pay-card-ico i,
.fx-settings-glass-card i,
.fx-hub-ico i,
.table .fx-icon-btn i,
.main-content .btn-outline-secondary i,
.main-content .btn-light i {
    color: var(--fx-icon);
}

.sidebar .nav-link:hover i,
.sidebar .nav-link.active i,
.fx-subnav-btn:not(.is-solid):not(.is-soon) i,
.fx-quick-btn i,
.fx-quick-menu-item i,
.fx-header-actions .fx-icon-btn:hover,
.fx-header-actions .fx-icon-btn:hover i,
.fx-theme-toggle:hover i,
.btn-outline-primary:hover i,
.nav-tabs .nav-link.active i {
    color: var(--fx-icon-active);
}

.btn-primary i,
.btn-success i,
.btn-danger i,
.btn-warning i,
.btn-info i,
.btn-dark i,
.fx-subnav-btn.is-solid i,
.badge i,
.btn[class*="btn-"][style*="background"] i {
    color: var(--fx-icon-on-solid);
}

html[data-fx-theme="dark"] .fx-icon-btn,
html[data-fx-theme="dark"] .main-content .fx-icon-btn {
    background: var(--fx-surface-2, var(--fx-surface));
    border-color: var(--fx-border);
    color: var(--fx-icon);
}
html[data-fx-theme="dark"] .fx-icon-btn:hover {
    background: var(--fx-primary-soft);
    border-color: var(--fx-primary);
    color: var(--fx-icon-active);
}
html[data-fx-theme="dark"] .fx-icon-btn.is-del,
html[data-fx-theme="dark"] .main-content .fx-icon-btn.is-del,
html[data-fx-theme="dark"] .fx-icon-btn.is-delete,
html[data-fx-theme="dark"] .main-content .fx-icon-btn.is-delete {
    background: rgba(220, 38, 38, 0.14);
    border-color: rgba(248, 113, 113, 0.45);
    color: #f87171;
}
html[data-fx-theme="dark"] .fx-icon-btn.is-del:hover,
html[data-fx-theme="dark"] .fx-icon-btn.is-delete:hover {
    background: rgba(220, 38, 38, 0.22);
    border-color: #f87171;
    color: #fecaca;
}
html[data-fx-theme="dark"] .fx-hub-ico,
html[data-fx-theme="dark"] .fx-hub-tile.is-sales .fx-hub-ico,
html[data-fx-theme="dark"] .fx-hub-tile.is-purchase .fx-hub-ico,
html[data-fx-theme="dark"] .fx-hub-tile.is-expense .fx-hub-ico,
html[data-fx-theme="dark"] .fx-hub-tile.is-stock .fx-hub-ico,
html[data-fx-theme="dark"] .fx-hub-tile.is-cash .fx-hub-ico,
html[data-fx-theme="dark"] .fx-hub-tile.is-ledger .fx-hub-ico,
html[data-fx-theme="dark"] .fx-hub-tile.is-journal .fx-hub-ico,
html[data-fx-theme="dark"] .fx-hub-tile.is-report .fx-hub-ico,
html[data-fx-theme="dark"] .fx-hub-tile.is-finance .fx-hub-ico,
html[data-fx-theme="dark"] .fx-hub-tile.is-assets .fx-hub-ico,
html[data-fx-theme="dark"] .fx-hub-tile.is-equity .fx-hub-ico,
html[data-fx-theme="dark"] .fx-hub-tile.is-settings .fx-hub-ico {
    color: var(--fx-icon-active);
    background: var(--fx-primary-soft);
}

html[data-fx-theme="dark"] .text-dark,
html[data-fx-theme="dark"] .text-secondary,
html[data-fx-theme="dark"] .text-muted {
    color: var(--fx-muted) !important;
}
html[data-fx-theme="dark"] .text-dark i,
html[data-fx-theme="dark"] .text-secondary i,
html[data-fx-theme="dark"] .text-muted i {
    color: var(--fx-icon) !important;
}


/* تبديل المهنة — إطار هادئ من لون الزر الأساسي (كل الثيمات) */
.fx-profession-frame {
    margin: 0.65rem 0.85rem 0.85rem;
    padding: 0.85rem 0.9rem;
    border-radius: var(--fx-radius, 12px);
    border: 1px solid color-mix(in srgb, var(--fx-primary) 42%, transparent);
    background:
        linear-gradient(145deg,
            color-mix(in srgb, var(--fx-primary) 10%, transparent),
            color-mix(in srgb, var(--fx-primary) 4%, transparent));
    box-shadow:
        inset 0 1px 0 color-mix(in srgb, var(--fx-primary) 18%, transparent),
        0 4px 14px color-mix(in srgb, var(--fx-primary) 10%, transparent);
}
.fx-profession-frame .fx-profession-switch {
    margin: 0;
}
.fx-profession-frame .fx-profession-label {
    display: block;
    font-weight: 700;
    font-size: 0.92rem;
    margin-bottom: 0.4rem;
    color: var(--fx-primary);
}
.fx-profession-frame .fx-profession-select {
    border-color: color-mix(in srgb, var(--fx-primary) 35%, var(--fx-border, #cbd5e1)) !important;
    background: var(--fx-input-bg, var(--fx-surface, #fff));
    color: var(--fx-text);
}
.fx-profession-frame .fx-profession-select:focus {
    border-color: var(--fx-primary) !important;
    box-shadow: 0 0 0 0.18rem color-mix(in srgb, var(--fx-primary) 22%, transparent) !important;
}
.fx-profession-frame .fx-profession-hint {
    margin-top: 0.4rem;
    font-size: 0.78rem;
    color: var(--fx-muted);
    line-height: 1.45;
}

/* توافق متصفحات بلا color-mix */
@supports not (color: color-mix(in srgb, red 50%, blue)) {
    .fx-profession-frame {
        border-color: var(--fx-primary);
        background: var(--fx-primary-soft, rgba(0,0,0,.04));
        box-shadow: inset 0 1px 0 rgba(255,255,255,.2), 0 4px 14px rgba(0,0,0,.08);
        opacity: 1;
    }
}


/* ==========================================================
   شريط الاختصارات تحت النافبار — بدون جزيرة بيضاء في الداكن
   أبيض بظهور 20٪ كحد أقصى، أو رمادي متزّن
   ========================================================== */
html[data-fx-theme="dark"] .main-header,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .main-header {
    background: rgba(18, 18, 18, 0.92) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

html[data-fx-theme="dark"] .fx-subnav,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-subnav {
    background: rgba(255, 255, 255, 0.06) !important; /* ظهور أبيض خفيف ~6٪ طبقة فوق الرمادي */
}

html[data-fx-theme="dark"] .fx-ui-mode-bar,
html[data-fx-theme="dark"] .fx-ui-mode-bar.is-simple,
html[data-fx-theme="dark"] .fx-ui-mode-bar.is-advanced,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-ui-mode-bar,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-ui-mode-bar.is-simple,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-ui-mode-bar.is-advanced {
    background: rgba(255, 255, 255, 0.08) !important;
    border-top-color: rgba(255, 255, 255, 0.10) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
    color: var(--fx-text) !important;
}

/* أزرار الاختصارات: رمادي/أبيض 20٪ وليس بطاقة بيضاء صلبة */
html[data-fx-theme="dark"] .fx-subnav-btn:not(.is-solid):not(.is-day-close),
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-subnav-btn:not(.is-solid):not(.is-day-close) {
    background: rgba(255, 255, 255, 0.12) !important;
    border: 1px solid rgba(255, 255, 255, 0.16) !important;
    color: var(--fx-text) !important;
    box-shadow: none !important;
}
html[data-fx-theme="dark"] .fx-subnav-btn:not(.is-solid):not(.is-day-close):hover,
html[data-fx-theme="dark"] .fx-subnav-btn:not(.is-solid):not(.is-day-close).active,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-subnav-btn:not(.is-solid):not(.is-day-close):hover,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-subnav-btn:not(.is-solid):not(.is-day-close).active {
    background: rgba(255, 255, 255, 0.20) !important; /* ظهور 20٪ كحد أقصى */
    border-color: color-mix(in srgb, var(--fx-primary) 45%, transparent) !important;
    color: var(--fx-text) !important;
}

html[data-fx-theme="dark"] .fx-ui-mode-pill,
html[data-fx-theme="dark"] .fx-profession-pill,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-ui-mode-pill,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-profession-pill {
    background: rgba(255, 255, 255, 0.10) !important;
    border-color: rgba(255, 255, 255, 0.14) !important;
    color: var(--fx-text) !important;
}

html[data-fx-theme="dark"] .fx-ui-mode-switch,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-ui-mode-switch {
    background: rgba(255, 255, 255, 0.12) !important;
    color: var(--fx-text) !important;
}

/* ==========================================================
   ثيمات داكنة عامة — بلا أسطح فاتحة صلبة
   بطاقات داكنة · تنبيهات خلفية شفافية 20٪ · نص واضح 100٪
   ينطبق على: data-fx-theme=dark + غلاف glass (غير الفاتح)
   ========================================================== */
html[data-fx-theme="dark"],
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) {
    --fx-dark-panel: #141414;
    --fx-dark-panel-2: #1a1a1a;
    --fx-dark-border: rgba(192, 192, 192, 0.22);
}

/* بطاقات وألواح — ممنوع أبيض صلب */
html[data-fx-theme="dark"] .card,
html[data-fx-theme="dark"] .fx-azia-card,
html[data-fx-theme="dark"] .fx-panel,
html[data-fx-theme="dark"] .fx-kpi,
html[data-fx-theme="dark"] .fx-hub-tile,
html[data-fx-theme="dark"] .fx-wh-card,
html[data-fx-theme="dark"] .fx-wh-simple-card,
html[data-fx-theme="dark"] .fx-wh-advanced-card,
html[data-fx-theme="dark"] .modal-content,
html[data-fx-theme="dark"] .dropdown-menu,
html[data-fx-theme="dark"] .list-group-item,
html[data-fx-theme="dark"] .bg-white,
html[data-fx-theme="dark"] .card-footer.bg-white,
html[data-fx-theme="dark"] .card-header.bg-white,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .card,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-azia-card,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-panel,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-kpi,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-hub-tile,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-wh-card,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-wh-simple-card,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-wh-advanced-card,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .modal-content,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .dropdown-menu,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .list-group-item,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .bg-white,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .card-footer.bg-white,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .card-header.bg-white {
    background: var(--fx-surface, var(--fx-dark-panel, #141414)) !important;
    color: var(--fx-text, #e8e8e8) !important;
    border-color: var(--fx-border, var(--fx-dark-border)) !important;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35) !important;
}

html[data-fx-theme="dark"] .fx-wh-card.is-frozen,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-wh-card.is-frozen {
    background: color-mix(in srgb, var(--fx-warning, #d4af37) 12%, #141414) !important;
    border-color: color-mix(in srgb, var(--fx-warning, #d4af37) 45%, transparent) !important;
}

html[data-fx-theme="dark"] .fx-wh-card-title,
html[data-fx-theme="dark"] .fx-wh-card-code,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-wh-card-title,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-wh-card-code {
    color: var(--fx-text, #e8e8e8) !important;
    background: rgba(255, 255, 255, 0.06) !important;
    border-color: rgba(192, 192, 192, 0.28) !important;
}
html[data-fx-theme="dark"] .fx-wh-card-title,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-wh-card-title {
    background: transparent !important;
    border: 0 !important;
}

/* جداول داخل البطاقات */
html[data-fx-theme="dark"] .table,
html[data-fx-theme="dark"] .table > :not(caption) > * > *,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .table,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .table > :not(caption) > * > * {
    color: var(--fx-text, #e8e8e8);
    border-color: rgba(255, 255, 255, 0.1);
}
html[data-fx-theme="dark"] .table-secondary,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .table-secondary {
    background: rgba(255, 255, 255, 0.06) !important;
    color: var(--fx-text) !important;
}

/* حقول فاتحة قسرية → داكنة */
html[data-fx-theme="dark"] .form-control,
html[data-fx-theme="dark"] .form-select,
html[data-fx-theme="dark"] .input-group-text,
html[data-fx-theme="dark"] .bg-light,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .form-control,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .form-select,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .input-group-text,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .bg-light {
    background-color: var(--fx-input-bg, #1a1a1a) !important;
    color: var(--fx-text, #e8e8e8) !important;
    border-color: var(--fx-border, rgba(192, 192, 192, 0.28)) !important;
}

/* أزرار outline داخل الداكن: فضي → ذهب عند الهوفر */
html[data-fx-theme="dark"] .fx-wh-card-actions .btn,
html[data-fx-theme="dark"] .btn-outline-primary,
html[data-fx-theme="dark"] .btn-outline-secondary,
html[data-fx-theme="dark"] .btn-outline-dark,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-wh-card-actions .btn,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .btn-outline-primary,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .btn-outline-secondary,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .btn-outline-dark {
    background: #c0c0c0 !important;
    border-color: #a8a8a8 !important;
    color: #0a0a0a !important;
}
html[data-fx-theme="dark"] .fx-wh-card-actions .btn:hover,
html[data-fx-theme="dark"] .btn-outline-primary:hover,
html[data-fx-theme="dark"] .btn-outline-secondary:hover,
html[data-fx-theme="dark"] .btn-outline-dark:hover,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .fx-wh-card-actions .btn:hover,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .btn-outline-primary:hover,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .btn-outline-secondary:hover,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .btn-outline-dark:hover {
    background: var(--fx-primary, #d4af37) !important;
    border-color: var(--fx-primary, #d4af37) !important;
    color: #0a0a0a !important;
}

/* تنبيهات (حفظ/تعديل/خطأ…): خلفية شفافيتها 20٪ · النص واضح 100٪ */
html[data-fx-theme="dark"] .alert,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .alert {
    opacity: 1 !important;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-width: 1px;
    border-style: solid;
}
html[data-fx-theme="dark"] .alert,
html[data-fx-theme="dark"] .alert *,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .alert,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .alert * {
    opacity: 1 !important; /* النص والمحتوى ظاهر بالكامل */
}

html[data-fx-theme="dark"] .alert-success,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .alert-success {
    background-color: rgba(34, 197, 94, 0.20) !important;
    border-color: rgba(34, 197, 94, 0.45) !important;
    color: #bbf7d0 !important;
}
html[data-fx-theme="dark"] .alert-danger,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .alert-danger {
    background-color: rgba(239, 68, 68, 0.20) !important;
    border-color: rgba(239, 68, 68, 0.45) !important;
    color: #fecaca !important;
}
html[data-fx-theme="dark"] .alert-warning,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .alert-warning {
    background-color: rgba(212, 175, 55, 0.20) !important;
    border-color: rgba(212, 175, 55, 0.45) !important;
    color: #fde68a !important;
}
html[data-fx-theme="dark"] .alert-info,
html[data-fx-theme="dark"] .alert-primary,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .alert-info,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .alert-primary {
    background-color: rgba(96, 165, 250, 0.20) !important;
    border-color: rgba(96, 165, 250, 0.45) !important;
    color: #bfdbfe !important;
}

/* نصوص Bootstrap الداكنة القسرية على فاتح */
html[data-fx-theme="dark"] .text-dark,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .text-dark {
    color: var(--fx-text, #e8e8e8) !important;
}
html[data-fx-theme="dark"] .text-muted,
html[data-fx-shell="glass"]:not([data-fx-theme="light"]) .text-muted {
    color: var(--fx-muted, #a3a3a3) !important;
}


/* ختم العملة على المستندات */
.fx-currency-stamp{display:flex;flex-wrap:wrap;gap:.35rem .75rem;align-items:baseline;margin:.55rem 0 .85rem;padding:.45rem .75rem;border:1px dashed color-mix(in srgb,var(--fx-primary,#0f766e) 45%,var(--fx-border,#cbd5e1));border-radius:10px;background:color-mix(in srgb,var(--fx-primary,#0f766e) 8%,var(--fx-surface,#fff));font-size:.82rem;line-height:1.35}
.fx-currency-stamp strong{color:var(--fx-primary,#0f766e)}
.fx-receipt-thermal .fx-currency-stamp{margin:.35rem 0;padding:.25rem .35rem;font-size:.72rem;border-radius:6px}

/* شرائح أقسام الفلترة */
.fx-cat-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}
.fx-cat-chip {
    display: inline-flex;
    align-items: center;
    margin: 0;
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    border: 1px solid var(--fx-border, #cbd5e1);
    background: var(--fx-surface, #fff);
    color: #334155;
    font-weight: 700;
    font-size: 0.82rem;
    text-decoration: none;
    cursor: pointer;
    line-height: 1.2;
}
.fx-cat-chip:hover {
    border-color: rgba(13, 148, 136, 0.45);
    color: #0f766e;
}
.fx-cat-chip.is-on {
    background: #0f766e;
    border-color: #0f766e;
    color: #fff;
}

.fx-remind-toast {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 12050;
    display: flex;
    align-items: center;
    gap: 0.65rem;
    flex-wrap: wrap;
    padding: 0.55rem 0.85rem;
    background: linear-gradient(90deg, #0f766e 0%, #115e59 100%);
    color: #ecfdf5;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.22);
    transform: translateY(-110%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.32s ease, opacity 0.28s ease;
}
.fx-remind-toast.is-on {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}
.fx-alert-toast {
    position: fixed;
    top: 12px;
    left: 50%;
    right: auto;
    width: min(440px, calc(100vw - 1.5rem));
    z-index: 12070;
    padding: 0;
    background: transparent;
    box-shadow: none;
    transform: translate(-50%, -130%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.32s ease, opacity 0.28s ease;
}
.fx-alert-toast.is-on {
    transform: translate(-50%, 0);
    opacity: 1;
    pointer-events: auto;
}
body.fx-remind-toast-on .fx-alert-toast.is-on {
    transform: translate(-50%, 58px);
}
.fx-alert-toast-card {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    padding: 0.7rem 0.75rem;
    background: #075e54;
    color: #eafff6;
    border-radius: 16px;
    box-shadow: 0 12px 32px rgba(7, 94, 84, 0.38);
    cursor: pointer;
}
.fx-alert-toast-avatar {
    flex: 0 0 36px;
    width: 36px;
    height: 36px;
    border-radius: 999px;
    background: #128c7e;
    display: flex;
    align-items: center;
    justify-content: center;
}
.fx-alert-toast-avatar img {
    filter: brightness(0) invert(1);
    opacity: .95;
}
.fx-alert-toast-text {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.08rem;
}
.fx-alert-toast-meta {
    display: flex;
    justify-content: space-between;
    gap: .5rem;
    font-size: .72rem;
    opacity: .88;
}
.fx-alert-toast-title {
    font-weight: 800;
    font-size: .9rem;
    line-height: 1.3;
}
.fx-alert-toast-body {
    font-size: .8rem;
    line-height: 1.35;
    opacity: .92;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.fx-alert-toast-btn {
    flex: 0 0 auto;
    align-self: center;
    padding: 0.32rem 0.75rem;
    border-radius: 999px;
    background: #fff;
    color: #075e54;
    font-weight: 800;
    font-size: 0.78rem;
    text-decoration: none;
    white-space: nowrap;
}
.fx-alert-toast-btn:hover { color: #064e46; background: #f0fdfa; }
.fx-alert-toast-x {
    flex: 0 0 auto;
    border: 0;
    background: rgba(255, 255, 255, 0.14);
    color: #ecfdf5;
    border-radius: 999px;
    width: 28px;
    height: 28px;
    line-height: 1;
    font-size: 1.15rem;
    cursor: pointer;
}
.fx-alert-toast-x:hover { background: rgba(255, 255, 255, 0.24); }
html[data-fx-theme="dark"] .fx-alert-toast-card {
    background: #064e46;
}
.fx-remind-toast-text {
    flex: 1 1 180px;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    font-size: 0.84rem;
    line-height: 1.35;
}
.fx-remind-toast-text strong { font-weight: 700; font-size: 0.9rem; }
.fx-remind-toast-btn {
    flex: 0 0 auto;
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    background: #fff;
    color: #0f766e;
    font-weight: 700;
    font-size: 0.82rem;
    text-decoration: none;
    white-space: nowrap;
}
.fx-remind-toast-btn:hover { color: #115e59; background: #f0fdfa; }
.fx-remind-toast-x {
    flex: 0 0 auto;
    border: 0;
    background: rgba(255, 255, 255, 0.14);
    color: #ecfdf5;
    border-radius: 999px;
    padding: 0.28rem 0.65rem;
    font-size: 0.78rem;
    cursor: pointer;
}
.fx-remind-toast-x:hover { background: rgba(255, 255, 255, 0.22); }

/* ترقيم الصفحات: SVG تيلويند بلا حجم يصبح سهماً عملاقاً */
.pagination svg,
nav[role="navigation"] svg {
    width: 1.25rem;
    height: 1.25rem;
    max-width: 1.25rem;
    max-height: 1.25rem;
    display: inline-block;
    vertical-align: middle;
}

/* —— إخفاء أسهم الزيادة/النقصان في كل حقول الرقم (كل البرنامج) —— */
input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none !important;
    appearance: none !important;
    margin: 0 !important;
    opacity: 0 !important;
    display: none !important;
    pointer-events: none !important;
    height: 0 !important;
    width: 0 !important;
}
input[type="number"] {
    -moz-appearance: textfield !important;
    appearance: textfield !important;
}
