/* Status: PROTOTYPE (not production code)
   SMART EMIS shared page shell of every module prototype (GOV-R154-A, CR-321), the styles of emis-shell.js. The patterns approved in the
   Payroll prototype (PAY-R976-A .. PAY-R985-A; skill ui-ux-pro-max section 6c). Colours come from emis-theme.css only (brand ramp of the
   module hue, surface, ink, line); presentation only. Every class starts with «es-». */

body.es-on { margin: 0; background: rgb(var(--canvas)); }
.es-hidden { display: none !important; }
#es-shell { display: flex; min-height: 100vh; }
#es-col { flex: 1; min-width: 0; display: flex; flex-direction: column; }
#es-main { flex: 1; min-width: 0; padding: 16px 20px 32px; }
.es-min { min-width: 0; display: flex; flex-direction: column; }
.es-n { font-size: 11px; font-weight: 700; min-width: 18px; padding: 0 5px; border-radius: 9px; background: rgba(255,255,255,.12); line-height: 16px; text-align: center; direction: ltr; }
.es-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 7px 12px; border-radius: 10px; font-size: 12.5px; font-weight: 600; border: 1px solid var(--line); background: rgb(var(--surface)); color: rgb(var(--ink-2)); cursor: pointer; }
.es-btn:hover { background: rgb(var(--surface-2)); }
.es-btn.es-primary { background: rgb(var(--brand-600)); border-color: rgb(var(--brand-600)); color: #fff; }
.es-btn.es-primary:hover { background: rgb(var(--brand-700)); }
.es-btn.es-danger { background: rgb(225 29 72); border-color: rgb(225 29 72); color: #fff; }
.es-btn.es-out { background: rgb(255 241 242); color: rgb(190 18 60); border-color: rgb(253 164 175); }
:focus-visible { outline-color: rgb(var(--brand-500)); }

/* ---- home bar (napp SneatNavBar) */
#es-bar { position: sticky; top: 0; z-index: 50 !important; display: flex; align-items: center; gap: 12px; height: 64px; padding: 0 16px; color: #fff; background: linear-gradient(135deg, rgb(var(--brand-600)) 0%, rgb(var(--brand-700)) 55%, rgb(var(--brand-900)) 100%); box-shadow: 0 6px 20px -10px rgb(var(--brand-900) / .6); }
body.es-bar-s #es-bar { height: 52px; } body.es-bar-l #es-bar { height: 78px; }
.es-glow { position: absolute; inset: 0; pointer-events: none; overflow: hidden; background: radial-gradient(circle at 15% -40%, rgb(255 255 255 / .22), transparent 55%), linear-gradient(rgb(255 255 255 / .05) 1px, transparent 1px) 0 0 / 22px 22px; }
.es-start, .es-end, .es-center { position: relative; display: flex; align-items: center; gap: 8px; }
.es-start { flex: 1; min-width: 0; }
.es-center { flex: none; }
.es-ic { position: relative; height: 38px; min-width: 38px; padding: 0 10px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; border-radius: 11px; background: rgb(255 255 255 / .10); border: 1px solid rgb(255 255 255 / .18); color: #fff; font-size: 13px; cursor: pointer; transition: background .15s, transform .15s; }
.es-ic:hover { background: rgb(255 255 255 / .22); transform: translateY(-1px); }
.es-page { min-width: 0; display: flex; flex-direction: column; line-height: 1.25; }
.es-page b { font-size: 15px; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.es-page small { font-size: 11px; opacity: .8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* CR-726 / GOV-R349-A */
/* the branding of the theme at the start of the top bar (drawn only when a logo or a name is set): the logo on a light tile so any logo reads on the bar colour, the name in the bar's text colour, then a thin line before the page title */
.es-brandx { flex: none; display: inline-flex; align-items: center; gap: 8px; max-width: 280px; min-width: 0; padding-inline-end: 10px; border-inline-end: 1px solid rgb(var(--on-brand) / .25); }
.es-brandx-lg { height: 32px; max-width: 112px; width: auto; padding: 3px 6px; border-radius: var(--r-ctl, 10px); background: rgb(var(--on-brand)); object-fit: contain; flex: none; }
.es-brandx-nm { font-size: var(--fs-3, 14px); font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
@media (max-width: 767px) { .es-brandx-nm { display: none; } .es-brandx { padding-inline-end: 6px; } }
.es-modules { display: inline-flex; align-items: center; gap: 9px; height: 40px; padding: 0 8px 0 14px; border-radius: 999px; background: rgb(255 255 255 / .14); border: 1px solid rgb(255 255 255 / .22); color: #fff; font-weight: 700; font-size: 13px; cursor: pointer; }
.es-modules:hover { background: rgb(255 255 255 / .24); }
.es-mod-ic { width: 28px; height: 28px; border-radius: 9px; display: inline-flex; align-items: center; justify-content: center; background: #fff; color: rgb(var(--brand-700)); }
.es-modules kbd { font: 600 11px/1 ui-monospace, monospace; padding: 4px 6px; border-radius: 6px; background: rgb(0 0 0 / .18); direction: ltr; }
.es-count { position: absolute; top: -5px; inset-inline-end: -5px; min-width: 18px; height: 18px; padding: 0 4px; border-radius: 9px; background: rgb(244 63 94); color: #fff; font-size: 11px; font-weight: 800; display: inline-flex; align-items: center; justify-content: center; border: 2px solid rgb(var(--brand-700)); }
.es-wrap { position: relative; }
.es-user { display: inline-flex; align-items: center; gap: 8px; padding: 3px 10px 3px 4px; border-radius: 999px; background: rgb(255 255 255 / .10); border: 1px solid rgb(255 255 255 / .18); color: #fff; cursor: pointer; }
.es-av { position: relative; width: 32px; height: 32px; flex: none; border-radius: 50%; background: #fff; color: rgb(var(--brand-700)); display: inline-flex; align-items: center; justify-content: center; font-weight: 800; font-size: 12px; }
.es-dot { position: absolute; bottom: -1px; inset-inline-end: -1px; width: 10px; height: 10px; border-radius: 50%; background: rgb(16 185 129); border: 2px solid #fff; }
.es-user-tx { display: flex; flex-direction: column; line-height: 1.2; text-align: start; }
.es-user-tx b { font-size: 12.5px; } .es-user-tx small { font-size: 11px; opacity: .8; }
.es-chev { font-size: 11px; opacity: .7; }
.es-dd { position: absolute; top: calc(100% + 10px); inset-inline-end: 0; display: none; flex-direction: column; max-height: calc(100vh - 90px); overflow: auto; border-radius: 16px; background: rgb(var(--surface)); color: rgb(var(--ink)); border: 1px solid var(--line); box-shadow: 0 24px 48px -16px rgba(2,6,23,.4); z-index: 50; }
.es-dd.show { display: flex; animation: es-in .14s ease-out; }
.es-dd-h { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--line); font-size: 13px; }
.es-dd-h small { display: block; color: rgb(var(--ink-muted)); font-size: 11px; }
.es-dd-h .es-n { background: rgb(var(--ink) / .07); color: rgb(var(--ink-2)); }
.es-hx { margin-inline-start: auto; width: 26px; height: 26px; flex: none; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; color: rgb(var(--ink-muted)); background: transparent; border: 0; cursor: pointer; }
.es-hx:hover { background: rgb(var(--brand-50)); color: rgb(var(--ink)); }
.es-dd-list { display: flex; flex-direction: column; padding: 6px; gap: 2px; }
.es-dd-sec { padding: 9px 12px 3px; font-size: 11px; font-weight: 700; color: rgb(var(--ink-muted)); }
.es-dd-f { padding: 9px 12px; border-top: 1px solid var(--line); font-size: 11px; color: rgb(var(--ink-muted)); }
.es-dd-acts { display: flex; justify-content: space-between; gap: 8px; }
.es-item, .es-note { display: flex; align-items: center; gap: 9px; width: 100%; padding: 8px 10px; border-radius: 9px; text-align: start; font-size: 12.5px; color: rgb(var(--ink-2)); background: transparent; border: 0; cursor: pointer; }
.es-item:hover, .es-note:hover { background: rgb(var(--surface-2)); color: rgb(var(--ink)); }
.es-item.on { background: rgb(var(--brand-50)); color: rgb(var(--brand-800)); font-weight: 700; }
.es-note-ic { width: 30px; height: 30px; flex: none; border-radius: 9px; display: inline-flex; align-items: center; justify-content: center; background: rgb(var(--brand-50)); color: rgb(var(--brand-700)); }
.es-note small { color: rgb(var(--ink-muted)); direction: ltr; text-align: start; }
.es-empty { padding: 20px; text-align: center; color: rgb(var(--ink-muted)); font-size: 12px; display: flex; flex-direction: column; gap: 6px; align-items: center; }
@keyframes es-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
/* GOV-R186-A (CR-397): reduced motion is one rule, not two (A41). The shell sets data-es-motion="reduce" on <html> when the system asks for it
   (prefers-reduced-motion, watched live) or when the user chose «مفعّل دائمًا» in «ملفي الشخصي»; every rule below hangs on that one attribute. */
html[data-es-motion="reduce"] .es-dd.show, html[data-es-motion="reduce"] .es-items, html[data-es-motion="reduce"] .es-am-menu, html[data-es-motion="reduce"] .es-modal, html[data-es-motion="reduce"] .es-drawer { animation: none !important; }

/* ---- side menu */
#es-side { width: 272px; flex: none; position: sticky; top: 64px !important; height: calc(100vh - 64px) !important; height: calc(100dvh - 64px) !important; display: flex; flex-direction: column; z-index: 30; color: var(--es-nav-text); background: linear-gradient(180deg, rgb(var(--nav-from, 15 23 42)) 0%, rgb(var(--nav-to, 17 28 58)) 100%);
  --es-nav-text: #c4cfe3; --es-nav-muted: #8d9cb9; --es-nav-hover: rgba(255,255,255,.07); }
body.es-nav-off #es-side { display: none; }
#es-backdrop { display: none; }
.es-app { position: relative; padding: 10px 10px 8px; border-bottom: 1px solid rgba(255,255,255,.08); }
.es-app-btn { width: 100%; display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 13px; text-align: start; background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.08); color: inherit; cursor: pointer; }
.es-app-btn:hover, .es-app-btn[aria-expanded="true"] { background: rgba(255,255,255,.09); border-color: rgb(var(--brand-400) / .5); }
.es-app-ic { width: 38px; height: 38px; flex: none; border-radius: 11px; display: inline-flex; align-items: center; justify-content: center; color: #fff; font-size: 16px; background: linear-gradient(135deg, rgb(var(--brand-500)), rgb(var(--brand-800))); box-shadow: 0 6px 16px -6px rgb(var(--brand-500) / .7); }
.es-app-tx { min-width: 0; flex: 1; display: flex; flex-direction: column; line-height: 1.25; }
.es-app-tx small { font-size: 11px; letter-spacing: .8px; color: var(--es-nav-muted); font-weight: 700; }
.es-app-tx b { font-size: 15px; font-weight: 800; color: #fff; }
.es-app-tx em { font-style: normal; font-size: 11px; color: var(--es-nav-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.es-app-chev { font-size: 11px; color: var(--es-nav-muted); transition: transform .18s; }
.es-app-btn[aria-expanded="true"] .es-app-chev { transform: rotate(180deg); }
.es-am-menu { position: absolute; z-index: 60; top: calc(100% - 2px); inset-inline: 10px; display: flex; flex-direction: column; max-height: min(70vh, 560px); border-radius: 16px; background: rgb(var(--surface)); color: rgb(var(--ink)); border: 1px solid var(--line); box-shadow: 0 24px 48px -16px rgba(2,6,23,.45); overflow: hidden; animation: es-in .16s ease-out; }
.es-am-list { overflow-y: auto; padding: 0 6px 6px; }
.es-am, .es-k-i { width: 100%; display: flex; align-items: center; gap: 9px; padding: 6px 8px; border-radius: 9px; text-align: start; font-size: 12.5px; color: rgb(var(--ink-2)); background: transparent; border: 0; cursor: pointer; text-decoration: none; }
.es-am:hover, .es-am:focus-visible, .es-k-i:hover, .es-k-i:focus-visible { background: rgb(var(--surface-2)); color: rgb(var(--ink)); }
.es-am.cur { background: rgb(var(--brand-50)); color: rgb(var(--brand-800)); font-weight: 700; }
.es-am-ic { width: 26px; height: 26px; flex: none; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; font-size: 12px; color: #fff; background: linear-gradient(135deg, rgb(var(--brand-500)), rgb(var(--brand-700))); }
.es-am.off .es-am-ic { opacity: .55; filter: saturate(.6); }
.es-t { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.es-am-st { flex: none; font-size: 11px; font-weight: 600; padding: 1px 7px; border-radius: 9px; }
.es-am-st.ok { background: rgb(16 185 129 / .12); color: rgb(4 120 87); }
.es-am-st.no { background: rgb(var(--ink) / .06); color: rgb(var(--ink-muted)); }
.es-am-st.cur { display: inline-flex; gap: 4px; align-items: center; background: rgb(var(--brand-600)); color: #fff; }
.es-head { padding: 10px 10px 6px; display: flex; flex-direction: column; gap: 8px; }
.es-tabs { display: flex; gap: 4px; padding: 3px; border-radius: 11px; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.08); }
.es-tab { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 6px 8px; border-radius: 8px; font-size: 12px; font-weight: 600; color: var(--es-nav-muted); background: transparent; border: 0; cursor: pointer; }
.es-tab:hover { color: #fff; }
.es-tab[aria-selected="true"] { background: rgb(var(--brand-600)); color: #fff; box-shadow: 0 4px 12px -4px rgb(var(--brand-600) / .6); }
.es-search { display: flex; align-items: center; gap: 6px; padding: 0 6px 0 9px; border-radius: 10px; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.12); }
.es-search:focus-within { border-color: rgb(var(--brand-400)); box-shadow: 0 0 0 3px rgb(var(--brand-500) / .25); }
.es-search > i { font-size: 11px; color: var(--es-nav-muted); }
.es-search input { flex: 1; min-width: 0; border: 0; background: transparent; padding: 7px 0; font-size: 12px; color: #fff; outline: none; }
.es-search input::-webkit-search-cancel-button { display: none; }
.es-x, .es-acts button { width: 22px; height: 22px; display: inline-flex; align-items: center; justify-content: center; border-radius: 6px; color: var(--es-nav-muted); font-size: 11px; background: transparent; border: 0; cursor: pointer; }
.es-x[hidden] { display: none; }
.es-x:hover { background: rgb(244 63 94 / .18); color: rgb(253 164 175); }
.es-acts { display: flex; gap: 1px; padding-inline-start: 4px; border-inline-start: 1px solid rgba(255,255,255,.12); }
.es-acts button:hover { background: rgba(255,255,255,.1); color: #fff; }
#es-nav { flex: 1; overflow-y: auto; padding: 2px 8px 12px; }
#es-nav::-webkit-scrollbar { width: 6px; } #es-nav::-webkit-scrollbar-thumb { background: rgba(255,255,255,.16); border-radius: 6px; }
.es-gh { width: 100%; display: flex; align-items: center; gap: 8px; padding: 8px 8px 6px; border-radius: 8px; font-size: 11px; font-weight: 700; color: var(--es-nav-muted); text-align: start; background: transparent; border: 0; cursor: pointer; }
.es-gh:hover { color: #fff; background: rgba(255,255,255,.04); }
.es-gi { width: 15px; text-align: center; font-size: 11px; }
.es-gh .es-n { margin-inline-start: auto; background: rgba(255,255,255,.08); font-weight: 600; }
.es-gh.has-cur { color: rgb(var(--brand-300)); }
.es-gchev { font-size: 11px; transition: transform .18s; transform: rotate(-90deg); }
[dir="rtl"] .es-gchev { transform: rotate(90deg); }
.es-g.open .es-gchev { transform: none; }
.es-items { display: flex; flex-direction: column; gap: 1px; padding-bottom: 4px; animation: es-in .16s ease-out; }
.es-row { position: relative; display: flex; align-items: center; }
.es-item-n { position: relative; width: 100%; display: flex; align-items: center; gap: 9px; padding: 6.5px 30px 6.5px 8px; border-radius: 8px; font-size: 12px; color: var(--es-nav-text); text-decoration: none; line-height: 1.35; }
[dir="rtl"] .es-item-n { padding: 6.5px 8px 6.5px 30px; }
.es-item-n:hover { background: var(--es-nav-hover); color: #fff; }
.es-item-n .es-i { width: 15px; text-align: center; font-size: 12px; opacity: .8; flex: none; }
.es-sid { margin-inline-start: auto; font-size: 11px; color: var(--es-nav-muted); direction: ltr; flex: none; }
.es-item-n.active { background: rgba(255,255,255,.10); color: #fff; font-weight: 600; }
.es-item-n.active::before { content: ''; position: absolute; inset-block: 6px; inset-inline-start: 0; width: 3px; border-radius: 3px; background: rgb(var(--brand-400)); }
.es-item-n.active .es-i { color: rgb(var(--brand-300)); opacity: 1; }
.es-star { position: absolute; inset-inline-end: 4px; width: 22px; height: 22px; display: inline-flex; align-items: center; justify-content: center; border-radius: 6px; font-size: 11px; color: var(--es-nav-muted); background: transparent; border: 0; opacity: 0; cursor: pointer; }
.es-row:hover .es-star, .es-star:focus-visible, .es-star.on { opacity: 1; }
.es-star.on { color: rgb(251 191 36); }
.es-row:hover .es-sid, .es-row .es-item-n:has(+ .es-star.on) .es-sid { visibility: hidden; }
#es-nav mark, .es-k-l mark { background: rgb(251 191 36 / .35); color: inherit; border-radius: 3px; padding: 0 1px; }
.es-none { padding: 26px 12px; text-align: center; color: var(--es-nav-muted); font-size: 12px; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.es-more { width: calc(100% - 8px); margin: 8px 4px 0; padding: 7px; border-radius: 8px; border: 1px dashed rgba(255,255,255,.18); background: transparent; color: var(--es-nav-muted); font-size: 11.5px; display: inline-flex; gap: 6px; align-items: center; justify-content: center; cursor: pointer; }
#es-foot { padding: 10px 14px; border-top: 1px solid rgba(255,255,255,.08); font-size: 11px; color: var(--es-nav-muted); }
/* the three looks (PAY-R984-A) */
body.es-look-brand #es-side { background: linear-gradient(180deg, rgb(var(--brand-800)) 0%, rgb(var(--brand-950)) 100%); --es-nav-text: rgb(var(--brand-50) / .92); --es-nav-muted: rgb(var(--brand-100) / .75); --es-nav-hover: rgba(255,255,255,.10); }
body.es-look-brand .es-item-n.active { background: rgba(255,255,255,.16); }
body.es-look-brand .es-item-n.active::before { background: #fff; }
body.es-look-brand .es-item-n.active .es-i, body.es-look-brand .es-gh.has-cur { color: #fff; }
body.es-look-brand .es-tab[aria-selected="true"] { background: #fff; color: rgb(var(--brand-800)); }
body.es-look-brand .es-tab[aria-selected="true"] .es-n { background: rgb(var(--brand-100)); }
body.es-look-brand .es-app-ic { background: rgba(255,255,255,.18); box-shadow: none; }
body.es-look-light #es-side { background: rgb(var(--surface)); border-inline-end: 1px solid var(--line); --es-nav-text: rgb(var(--ink-2)); --es-nav-muted: rgb(var(--ink-muted)); --es-nav-hover: rgb(var(--brand-50)); }
body.es-look-light .es-app, body.es-look-light #es-foot { border-color: var(--line); }
body.es-look-light .es-app-btn, body.es-look-light .es-tabs, body.es-look-light .es-search { background: rgb(var(--surface-2)); border-color: var(--line); }
body.es-look-light .es-app-tx b { color: rgb(var(--ink)); }
body.es-look-light .es-item-n:hover, body.es-look-light .es-item-n.active { background: rgb(var(--brand-50)); color: rgb(var(--brand-800)); }
body.es-look-light .es-item-n.active::before { background: rgb(var(--brand-600)); }
body.es-look-light .es-item-n.active .es-i, body.es-look-light .es-item-n.active .es-sid, body.es-look-light .es-gh.has-cur { color: rgb(var(--brand-700)); }
body.es-look-light .es-tab:hover, body.es-look-light .es-gh:hover, body.es-look-light .es-acts button:hover { color: rgb(var(--brand-700)); background: rgb(var(--surface-2)); }
body.es-look-light .es-search input { color: rgb(var(--ink)); }
body.es-look-light .es-n { background: rgb(var(--ink) / .07); }
body.es-look-light .es-tab[aria-selected="true"] .es-n { background: rgba(255,255,255,.22); }
body.es-look-light .es-acts, body.es-look-light .es-more { border-color: var(--line); }
.dark body.es-look-light .es-item-n:hover, .dark body.es-look-light .es-item-n.active { background: rgb(var(--brand-500) / .14); color: rgb(var(--brand-200)); }

/* ---- page band and helpers used inside the screens */
.es-band { position: relative; overflow: hidden; margin-bottom: 14px; padding: 10px 18px; border-radius: 16px; color: #fff; background: linear-gradient(120deg, rgb(var(--brand-600)) 0%, rgb(var(--brand-700)) 55%, rgb(var(--brand-900)) 100%); box-shadow: 0 10px 24px -14px rgb(var(--brand-700) / .7); }
.es-band::before { content: ''; position: absolute; width: 220px; height: 220px; top: -110px; inset-inline-end: -40px; border-radius: 50%; background: rgb(255 255 255 / .10); pointer-events: none; }
.es-band-in { position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; }
.es-band-t { flex: 1 1 360px; min-width: 0; display: flex; align-items: center; gap: 12px; }
.es-band h2 { margin: 0; font-size: 19px; font-weight: 800; white-space: nowrap; }
.es-band p { margin: 0; min-width: 0; padding-inline-start: 12px; border-inline-start: 1px solid rgb(255 255 255 / .35); font-size: 12.5px; opacity: .9; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.es-band-a { display: flex; flex-wrap: wrap; gap: 8px; margin-inline-start: auto; }
.es-band-a .es-btn { background: rgb(255 255 255 / .14); border-color: rgb(255 255 255 / .3); color: #fff; }
.es-band-a .es-btn.es-primary { background: #fff; color: rgb(var(--brand-700)); border-color: #fff; }
.es-scr-no { display: inline-block; margin-inline-start: 6px; padding: 1px 8px; border-radius: 7px; border: 1px dashed rgb(255 255 255 / .55); font: 700 11px/1.6 ui-monospace, monospace; direction: ltr; vertical-align: middle; }
body.es-band-m .es-band { padding: 14px 20px; } body.es-band-m .es-band-t { flex-wrap: wrap; } body.es-band-m .es-band h2 { font-size: 20px; }
body.es-band-m .es-band p, body.es-band-l .es-band p { flex: 1 1 100%; white-space: normal; padding-inline-start: 0; border: 0; }
body.es-band-l .es-band { padding: 22px 26px 24px; border-radius: 18px; } body.es-band-l .es-band-t { flex-wrap: wrap; } body.es-band-l .es-band h2 { font-size: 23px; }
body.es-calm .es-band { background: rgb(var(--surface)); color: rgb(var(--ink)); border: 1px solid var(--line); box-shadow: none; }
body.es-calm .es-band::before { display: none; }
body.es-calm .es-band p { border-color: var(--line); color: rgb(var(--ink-muted)); }
body.es-calm .es-band-a .es-btn { background: rgb(var(--surface)); color: rgb(var(--ink-2)); border-color: var(--line); }
body.es-calm .es-band-a .es-btn.es-primary { background: rgb(var(--brand-600)); color: #fff; border-color: rgb(var(--brand-600)); }
body.es-calm .es-scr-no { border-color: rgb(var(--ink-muted)); }
@media (max-width: 900px) { .es-band p { display: none; } body.es-band-m .es-band p, body.es-band-l .es-band p { display: block; } }
.es-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-bottom: 14px; }
.es-kpi { position: relative; display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border-radius: 16px; text-align: start; background: rgb(var(--surface)); border: 1px solid var(--line); color: rgb(var(--ink)); border-inline-start: 4px solid var(--k, rgb(var(--brand-500))); cursor: pointer; }
.es-kpi[disabled] { cursor: default; }
.es-kpi span { font-size: 12px; color: rgb(var(--ink-muted)); } .es-kpi b { font-size: 24px; font-weight: 800; } .es-kpi small { font-size: 11px; color: rgb(var(--ink-muted)); }
.es-kpi.on { box-shadow: 0 0 0 2px rgb(var(--brand-500) / .35); }
.es-kpi.t-amber { --k: rgb(245 158 11); } .es-kpi.t-emerald { --k: rgb(16 185 129); } .es-kpi.t-rose { --k: rgb(244 63 94); } .es-kpi.t-sky { --k: rgb(14 165 233); } .es-kpi.t-slate { --k: rgb(100 116 139); }
.es-act { position: relative; display: inline-block; }
.es-act-b { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; border-radius: 9px; border: 1px solid var(--line); background: rgb(var(--surface)); color: rgb(var(--ink-2)); font-size: 12px; font-weight: 600; cursor: pointer; }
.es-act-b:hover { border-color: rgb(var(--brand-300)); color: rgb(var(--brand-700)); }
.es-act-n { font-size: 11px; color: rgb(var(--ink-muted)); direction: ltr; }
.es-act-l { position: fixed; z-index: 70; display: none; min-width: 210px; max-width: 280px; flex-direction: column; padding: 6px; border-radius: 12px; background: rgb(var(--surface)); border: 1px solid var(--line); box-shadow: 0 18px 40px -14px rgba(2,6,23,.4); }
.es-act-l.show { display: flex; }
.es-act-i { display: flex; align-items: flex-start; gap: 9px; padding: 7px 9px; border-radius: 8px; text-align: start; font-size: 12.5px; color: rgb(var(--ink-2)); background: transparent; border: 0; cursor: pointer; }
.es-act-i i { margin-top: 2px; width: 14px; text-align: center; }
.es-act-i:hover:not([disabled]) { background: rgb(var(--brand-50)); color: rgb(var(--brand-800)); }
.es-act-i[disabled] { opacity: .55; cursor: not-allowed; }
.es-act-why { display: block; font-size: 11px; color: rgb(225 29 72); opacity: 1; }
.es-views { display: inline-flex; padding: 2px; border-radius: 10px; border: 1px solid var(--line); background: rgb(var(--surface-2)); }
.es-views button { width: 30px; height: 28px; border-radius: 8px; border: 0; background: transparent; color: rgb(var(--ink-muted)); cursor: pointer; }
.es-views button[aria-pressed="true"] { background: rgb(var(--surface)); color: rgb(var(--brand-700)); box-shadow: 0 1px 3px rgb(0 0 0 / .12); }
/* GOV-R206-A (CR-416): the card container only. The same class name marks a data table for the phone card rules
   (body.es-mobile-on table.es-cards, in the max-width 767px block below), so without :not(table) this rule laid every
   table out as a three-column grid at any width and the header and the rows came apart. */
.es-cards:not(table) { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.es-card { display: flex; flex-direction: column; gap: 6px; padding: 14px; border-radius: 16px; background: rgb(var(--surface)); border: 1px solid var(--line); }
.es-card > b { font-size: 13.5px; } .es-card > small { color: rgb(var(--ink-muted)); font-size: 11.5px; }
.es-card dl { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 10px; margin: 4px 0; } .es-card dt { font-size: 11px; color: rgb(var(--ink-muted)); } .es-card dd { margin: 0; font-size: 12px; }
body.es-dense table td, body.es-dense table th { padding-top: 6px; padding-bottom: 6px; }

/* ---- modal, drawer, toasts, command palette */
.es-modal-w, .es-drawer-w { position: fixed; inset: 0; z-index: 90; display: flex; align-items: center; justify-content: center; padding: 16px; }
.es-drawer-w { justify-content: flex-end; padding: 0; }
.es-mb { position: absolute; inset: 0; background: rgb(15 23 42 / .5); backdrop-filter: blur(2px); }
.es-modal, .es-drawer { position: relative; display: flex; flex-direction: column; max-height: 92vh; background: rgb(var(--surface)); color: rgb(var(--ink)); box-shadow: 0 30px 60px -20px rgba(0,0,0,.5); animation: es-in .16s ease-out; }
.es-modal { width: 100%; max-width: 460px; border-radius: 18px; } .es-modal.wide { max-width: 640px; }
.es-drawer { width: min(480px, 100vw); height: 100vh; max-height: none; }
.es-m-h { display: flex; align-items: center; gap: 8px; padding: 14px 16px; border-bottom: 1px solid var(--line); font-size: 15px; }
.es-m-h.danger b { color: rgb(190 18 60); }
.es-m-b { padding: 16px; overflow: auto; font-size: 13px; }
.es-m-f { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--line); }
.es-k-s { background: rgb(var(--surface-2)); border-color: var(--line); margin-bottom: 8px; } .es-k-s input { color: rgb(var(--ink)); font-size: 14px; padding: 10px 0; }
.es-k-l { max-height: 60vh; overflow: auto; } .es-k-l .es-sid { color: rgb(var(--ink-muted)); }
#es-toasts { position: fixed; z-index: 95; bottom: 18px; inset-inline-start: 50%; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; }
[dir="rtl"] #es-toasts { transform: translateX(50%); }
.es-toast { padding: 10px 16px; border-radius: 12px; font-size: 13px; color: #fff; background: rgb(15 23 42); box-shadow: 0 12px 30px -10px rgba(0,0,0,.4); }
.es-toast.success { background: rgb(5 150 105); } .es-toast.warning { background: rgb(217 119 6); } .es-toast.danger { background: rgb(225 29 72); }
/* appearance in My profile */
.es-prof { display: flex; flex-direction: column; gap: 10px; }
.es-prof-h { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 16px; background: rgb(var(--brand-50)); }
.es-prof-h .es-av { width: 44px; height: 44px; background: rgb(var(--brand-600)); color: #fff; font-size: 15px; }
.es-prof-h small { display: block; color: rgb(var(--ink-muted)); }
.es-prof h4 { margin: 6px 0 0; font-size: 13px; } .es-prof h4 small { font-weight: 400; color: rgb(var(--ink-muted)); }
.es-prow { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 6px 0; border-bottom: 1px dashed var(--line); }
.es-prow label { font-size: 12.5px; font-weight: 600; } .es-prow label small { display: block; font-size: 11px; font-weight: 400; color: rgb(var(--ink-muted)); }
.es-seg { display: inline-flex; flex-wrap: wrap; padding: 2px; border-radius: 10px; background: rgb(var(--surface-2)); border: 1px solid var(--line); }
.es-seg button { display: inline-flex; align-items: center; gap: 5px; padding: 5px 10px; border-radius: 8px; border: 0; background: transparent; font-size: 12px; color: rgb(var(--ink-2)); cursor: pointer; }
.es-seg button[aria-pressed="true"] { background: rgb(var(--brand-600)); color: #fff; }
.es-sw { display: flex; flex-wrap: wrap; gap: 6px; }
.es-sw button { width: 26px; height: 26px; border-radius: 50%; border: 2px solid rgb(var(--surface)); box-shadow: 0 0 0 1px var(--line); background: rgb(var(--brand-500)); color: #fff; font-size: 11px; cursor: pointer; }
.es-sw button:first-child { background: rgb(var(--surface-2)); color: rgb(var(--ink-2)); }
.es-sw button[aria-pressed="true"] { box-shadow: 0 0 0 2px rgb(var(--ink)); }
.es-lk { width: 14px; height: 14px; border-radius: 4px; border: 1px solid var(--line); }
.es-lk-light { background: #fff; } .es-lk-brand { background: linear-gradient(180deg, rgb(var(--brand-700)), rgb(var(--brand-950))); } .es-lk-dark { background: linear-gradient(180deg, rgb(15 23 42), rgb(17 28 58)); }
.es-note-s { font-size: 11.5px; color: rgb(var(--ink-muted)); margin: 4px 0; }
/* GOV-R196-A (CR-398): the «الجلسة والتنسيق / Session and format» card of My profile (start page, session timeout, time format, time zone) */
.es-pcard { display: flex; flex-direction: column; padding: 8px 12px 2px; border: 1px solid var(--line); border-radius: 16px; background: rgb(var(--surface)); }
.es-pcard h4 { margin: 2px 0 2px; }
.es-pcard .es-prow:last-child { border-bottom: 0; }
.es-psel, .es-pnum { min-width: 170px; max-width: 280px; padding: 6px 10px; border-radius: 10px; border: 1px solid rgb(var(--border-strong)); background: rgb(var(--surface)); color: rgb(var(--ink)); font-size: 12px; }
.es-pnum { width: 96px; min-width: 0; text-align: center; }
.es-psel:focus-visible, .es-pnum:focus-visible { outline: 2px solid rgb(var(--brand-500)); outline-offset: 1px; }
.dark .es-pcard { background: rgb(var(--surface-2)); }
.dark .es-psel, .dark .es-pnum { background: rgb(var(--surface)); }
/* signed out */
body.es-signed-out { overflow: hidden; }
#es-out { position: fixed; inset: 0; z-index: 100; display: flex; align-items: center; justify-content: center; padding: 20px; background: radial-gradient(circle at 20% 10%, rgb(var(--brand-500) / .35), transparent 50%), linear-gradient(135deg, rgb(var(--brand-800)), rgb(15 23 42)); }
.es-out-card { width: 100%; max-width: 420px; display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 28px 26px 22px; border-radius: 22px; background: rgb(var(--surface)); color: rgb(var(--ink)); text-align: center; }
.es-out-brand { display: flex; align-items: center; gap: 8px; color: rgb(var(--brand-700)); font-size: 13px; }
.es-out-ok { font-size: 44px; color: rgb(16 185 129); }
.es-out-card h2 { font-size: 20px; font-weight: 800; margin: 0; } .es-out-card p { margin: 0; color: rgb(var(--ink-muted)); font-size: 13px; }
.es-out-card #es-in { width: 100%; margin-top: 8px; }
.es-out-other { width: 100%; font-size: 12.5px; } .es-out-other summary { cursor: pointer; color: rgb(var(--brand-700)); }
.es-out-other div { display: flex; flex-direction: column; gap: 2px; max-height: 200px; overflow: auto; margin-top: 6px; padding: 4px; border: 1px solid var(--line); border-radius: 10px; }
.es-out-other div button { border: 0; background: transparent; padding: 6px 8px; border-radius: 8px; text-align: start; cursor: pointer; }
.es-out-card small { color: rgb(var(--ink-muted)); font-size: 11px; }
/* dark mode details */
.dark .es-am.cur, .dark .es-item.on { background: rgb(var(--brand-500) / .16); color: rgb(var(--brand-200)); }
.dark .es-am-st.ok { color: rgb(110 231 183); }
.dark .es-btn.es-out { background: rgb(244 63 94 / .15); color: rgb(253 164 175); border-color: rgb(244 63 94 / .35); }
.dark .es-prof-h { background: rgb(var(--brand-500) / .12); }

/* ---- small screens: the side menu slides in, the bar keeps the essentials */
@media (max-width: 1023px) {
  #es-side { position: fixed; top: 0; bottom: 0; inset-inline-start: 0; transform: translateX(-100%); transition: transform .2s ease; }
  [dir="rtl"] #es-side { transform: translateX(100%); }
  body.es-nav-open #es-side { transform: none; }
  body.es-nav-off #es-side { display: flex; }
  body.es-nav-open #es-backdrop { display: block; position: fixed; inset: 0; background: rgba(15,23,42,.5); z-index: 39; }
  .es-center { display: flex; }   /* GOV-R180-A (CR-394): the search control stays visible on a narrow bar (icon alone), it is never hidden */
  #es-main { padding: 12px 12px 28px; }
}
@media (max-width: 640px) { .es-hide-sm { display: none !important; } .es-page small { display: none; } }
@media print { #es-side, #es-bar { display: none !important; } #es-main { padding: 0; } }

/* GOV-R156-A (CR-322): the user photo in the home bar user button, the menu head and My profile (upload, remove) */
.es-av .es-photo { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: block; }
.es-av:has(.es-photo) { padding: 2px; box-shadow: 0 0 0 2px rgb(255 255 255 / .55); }
.es-av-dd { width: 40px; height: 40px; font-size: 14px; flex: none; background: rgb(var(--brand-600)); color: #fff; }
.es-prof-h .es-av-lg { width: 64px; height: 64px; font-size: 20px; overflow: visible; }
.es-av-cam { position: absolute; bottom: -2px; inset-inline-end: -4px; width: 26px; height: 26px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: rgb(var(--surface)); color: rgb(var(--brand-700)); border: 1px solid var(--line); font-size: 11px; cursor: pointer; box-shadow: 0 4px 10px -4px rgb(0 0 0 / .3); }
.es-av-cam:hover { background: rgb(var(--brand-50)); }
.es-av-cam:focus-within { outline: 2px solid rgb(var(--brand-500)); outline-offset: 1px; }
.es-av-cam input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.es-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.es-av-del { margin-top: 4px; display: inline-flex; align-items: center; gap: 5px; padding: 2px 8px; border-radius: 8px; border: 1px solid rgb(253 164 175); background: transparent; color: rgb(190 18 60); font-size: 11px; cursor: pointer; }

/* GOV-R157-A (CR-323): the «+» new colour in My profile */
.es-sw-add { position: relative; width: 26px; height: 26px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 11px; color: rgb(var(--ink-2)); background: rgb(var(--surface-2)); border: 2px dashed rgb(var(--ink-muted) / .6); cursor: pointer; }
.es-sw-add input[type="color"] { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.es-sw-add:focus-within { outline: 2px solid rgb(var(--brand-500)); outline-offset: 2px; }

/* GOV-R158-A (CR-323): the small close icon at the end of the coloured page band */
.es-band-x { flex: none; align-self: flex-start; width: 28px; height: 28px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 12px; color: #fff; background: rgb(255 255 255 / .14); border: 1px solid rgb(255 255 255 / .28); cursor: pointer; transition: background .15s, transform .15s; }
.es-band-x:hover { background: rgb(255 255 255 / .28); transform: rotate(90deg); }
.es-band-x:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
body.es-calm .es-band-x { color: rgb(var(--ink-2)); background: rgb(var(--surface-2)); border-color: var(--line); }
html[data-es-motion="reduce"] .es-band-x:hover { transform: none; }   /* GOV-R186-A (CR-397): system or user preference, one rule */

/* PAY-R990-A (CR-325): the screen number beside the name for the review period: always visible in the side menu, and in the home bar */
.es-row:hover .es-sid, .es-row .es-item-n:has(+ .es-star.on) .es-sid { visibility: visible; }
.es-sid { font: 600 11px/1.4 ui-monospace, monospace; padding: 0 5px; border-radius: 6px; border: 1px dashed rgba(255,255,255,.28); }
body.es-look-light .es-sid { border-color: var(--line); }
.es-page-scr { display: inline-block; margin-inline-start: 6px; padding: 0 6px; border-radius: 6px; border: 1px dashed rgb(255 255 255 / .5); font: 600 11px/1.5 ui-monospace, monospace; direction: ltr; }

/* PAY-R996-A (CR-328): the system name SEMIS — Smart Enterprise Management Information System on the signed-out card */
.so-brand, .es-out-brand { flex-wrap: wrap; justify-content: center; text-align: center; }
.so-full, .es-out-full { flex-basis: 100%; font-size: 11px; font-weight: 600; color: var(--ink-3, rgb(var(--ink-muted))); letter-spacing: .2px; }

/* GOV-R161-A (CR-333): the shell's own scroll areas keep the menu colours; a module page's global ::-webkit-scrollbar-track (light surface) no longer paints a strip beside the menu */
#es-nav, .es-am-list, .es-dd, .es-k-l { scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.18) transparent; }
.es-am-list, .es-dd, .es-k-l { scrollbar-color: rgb(var(--ink) / .18) transparent; }
body.es-look-light #es-nav { scrollbar-color: rgb(var(--ink) / .18) transparent; }
#es-nav::-webkit-scrollbar-track, .es-am-list::-webkit-scrollbar-track, .es-dd::-webkit-scrollbar-track, .es-k-l::-webkit-scrollbar-track { background: transparent; }
#es-nav::-webkit-scrollbar, .es-am-list::-webkit-scrollbar, .es-dd::-webkit-scrollbar, .es-k-l::-webkit-scrollbar { width: 6px; }
body.es-look-light #es-nav::-webkit-scrollbar-thumb { background: rgb(var(--ink) / .16); }

/* GOV-R162-A (CR-333): the KPI card of the Payroll prototype for every module: a 1px border, a soft shadow, a 3px rounded accent bar inside the card at its start edge (inset 12px top and bottom), a 2px lift on hover; colour by meaning (t-*) or brand, sky, amber, violet in turn */
.es-kpi { border: 1px solid var(--line); border-inline-start-width: 1px; padding: 14px 16px 14px 18px; overflow: hidden; box-shadow: var(--shadow-1, 0 1px 2px rgb(15 23 42 / .06)); transition: transform .15s, box-shadow .15s, border-color .15s; }
[dir="rtl"] .es-kpi { padding: 14px 18px 14px 16px; }
.es-kpi::after { content: ""; position: absolute; inset-block: 12px; inset-inline-start: 0; width: 3px; border-radius: 3px; background: var(--k, rgb(var(--brand-500))); opacity: .9; }
.es-kpis .es-kpi:not([class*="t-"]):nth-child(4n+2) { --k: #0EA5E9; } .es-kpis .es-kpi:not([class*="t-"]):nth-child(4n+3) { --k: #F59E0B; } .es-kpis .es-kpi:not([class*="t-"]):nth-child(4n+4) { --k: #8B5CF6; }
.es-kpi:not([disabled]):hover { transform: translateY(-2px); box-shadow: var(--shadow-2, 0 8px 20px -10px rgb(15 23 42 / .25)); border-color: rgb(var(--brand-200)); }
.es-kpi span { font-size: 11.5px; font-weight: 600; } .es-kpi b { font-size: 22px; letter-spacing: -.01em; margin-top: 4px; font-variant-numeric: tabular-nums; }
.es-kpi.on { border-color: rgb(var(--brand-300)); box-shadow: 0 0 0 3px rgb(var(--brand-500) / .15); }
html[data-es-motion="reduce"] .es-kpi { transition: none; } html[data-es-motion="reduce"] .es-kpi:not([disabled]):hover { transform: none; }

/* ---- SS-R028-A (CR-344): the phone layout of a module that turns it on (cfg.mobile), first Self Service:
   under 768px a bottom tab bar with safe-area padding, one fixed main action, touch targets of 44px, a compact home bar,
   and tables marked .es-cards shown as one card per row (the cell label from the column head); presentation only */
#es-mtabs, .es-fab { display: none; }
@media (max-width: 767px) {
  body.es-mobile-on #es-mtabs { display: flex; position: fixed; inset-inline: 0; bottom: 0; z-index: 45; gap: 2px; padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); background: rgb(var(--surface) / .96); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-top: 1px solid var(--line); box-shadow: 0 -10px 26px -18px rgb(15 23 42 / .45); }
  .es-mt { position: relative; flex: 1; min-width: 0; min-height: 52px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; border: 0; border-radius: 12px; background: transparent; color: rgb(var(--ink-muted)); font: inherit; font-size: 11px; font-weight: 600; cursor: pointer; }
  .es-mt-l { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .es-mt-ic { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 26px; border-radius: 999px; font-size: 17px; transition: background .15s; }
  .es-mt-ic b { position: absolute; top: -4px; inset-inline-end: 2px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 999px; background: rgb(225 29 72); color: #fff; font-size: 11px; line-height: 17px; text-align: center; direction: ltr; }
  .es-mt.on { color: rgb(var(--brand-700)); } .es-mt.on .es-mt-ic { background: rgb(var(--brand-100)); }
  .es-mt:focus-visible { outline: 2px solid rgb(var(--brand-500)); outline-offset: -2px; }
  body.es-mobile-on .es-fab { display: inline-flex; align-items: center; gap: 8px; position: fixed; inset-inline-end: 16px; bottom: calc(78px + env(safe-area-inset-bottom)); z-index: 46; height: 52px; padding: 0 20px; border: 0; border-radius: 16px; color: #fff; font: inherit; font-size: 14px; font-weight: 700; background: linear-gradient(135deg, rgb(var(--brand-600)), rgb(var(--brand-800))); box-shadow: 0 16px 30px -14px rgb(var(--brand-700)); cursor: pointer; }
  body.es-mobile-on .es-fab:focus-visible { outline: 3px solid rgb(var(--brand-300)); outline-offset: 2px; }
  body.es-mobile-on #es-main { padding-bottom: calc(150px + env(safe-area-inset-bottom)); }
  body.es-mobile-on #es-bar { padding-top: env(safe-area-inset-top); }
  body.es-mobile-on #es-bar button, body.es-mobile-on .es-btn, body.es-mobile-on .es-pill { min-height: 44px; min-width: 44px; }
  body.es-mobile-on #es-bar .es-hide-sm, body.es-mobile-on #es-bar [data-es-m="hide"] { display: none !important; }
  body.es-mobile-on table.es-cards thead { display: none; }
  body.es-mobile-on table.es-cards, body.es-mobile-on table.es-cards tbody { display: block; width: 100%; }
  body.es-mobile-on table.es-cards tr { display: block; margin: 0 0 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 16px; background: rgb(var(--surface)); box-shadow: 0 1px 2px rgb(15 23 42 / .05); }
  body.es-mobile-on table.es-cards td { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 4px 0 !important; border: 0 !important; text-align: end; }
  body.es-mobile-on table.es-cards td::before { content: attr(data-l); flex: none; max-width: 45%; color: rgb(var(--ink-muted)); font-size: 11.5px; font-weight: 600; text-align: start; }
  body.es-mobile-on table.es-cards td[data-l=""]::before { display: none; }
  body.es-mobile-on table.es-cards td:last-child { justify-content: flex-end; padding-top: 8px !important; margin-top: 4px; border-top: 1px dashed var(--line) !important; }
}
@media print { #es-mtabs, .es-fab { display: none !important; } }
html[data-es-motion="reduce"] .es-mt-ic { transition: none; }
/* SS-R028-A (owner: «لا تنسى توصياتك بخصوص self service فهى تبدو مختلفة»): the rest of the phone layout — a compact home bar (menu, title, bell, user;
   the tabs and My profile hold the rest), KPI cards two per row and compact, the module's own form dialogs as full pages with a sticky save footer */
@media (max-width: 767px) {
  body.es-mobile-on #es-bar .emis-theme-btn, body.es-mobile-on #es-bar .es-lang,
  body.es-mobile-on #es-bar button[aria-label="الرئيسية"], body.es-mobile-on #es-bar button[aria-label="Home"] { display: none !important; }
  /* SS-R032-A (CR-402, closing GOV-R184): search stays on the phone — the glass control of the home bar folds to one 44px
     icon beside the bell, because search, not the module tree, is the short way to a screen on a phone. */
  body.es-mobile-on #es-bar .es-center { flex: none; }
  body.es-mobile-on #es-bar .es-modules { min-width: 44px; width: 44px; min-height: 44px; height: 44px; justify-content: center; padding: 0; border-radius: 12px; }
  body.es-mobile-on #es-bar .es-modules .es-bs-tx, body.es-mobile-on #es-bar .es-modules kbd { display: none !important; }
  body.es-mobile-on #es-bar .es-modules .es-bs-ic { font-size: 16px; }
  body.es-mobile-on .es-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  body.es-mobile-on .es-kpi { padding: 12px 12px 12px 18px; } [dir="rtl"] body.es-mobile-on .es-kpi { padding: 12px 18px 12px 12px; }
  body.es-mobile-on .es-kpi small { display: none; }
  body.es-mobile-on > div.fixed.inset-0 > .overflow-y-auto > .min-h-full { padding: 0 !important; align-items: stretch !important; }
  body.es-mobile-on > div.fixed.inset-0 [role="dialog"] { max-width: none !important; width: 100% !important; min-height: 100dvh; border: 0 !important; border-radius: 0 !important; display: flex; flex-direction: column; padding-top: env(safe-area-inset-top); }
  body.es-mobile-on > div.fixed.inset-0 [role="dialog"] > div:last-child.border-t { position: sticky; bottom: 0; margin-top: auto; border-radius: 0 !important; padding-bottom: calc(12px + env(safe-area-inset-bottom)); z-index: 2; }
  body.es-mobile-on > div.fixed.inset-0 [role="dialog"] > div:last-child.border-t button { min-height: 44px; flex: 1; }
}
@media (max-width: 767px) {
  body.es-mobile-on > div.fixed.inset-0 [role="dialog"] > div:not(:first-child):not(:last-child) { flex: 1 1 auto; max-height: none !important; }
  body.es-mobile-on > div.fixed.inset-0 [role="dialog"] > div:last-child.border-t { flex-wrap: nowrap !important; gap: 8px !important; padding-inline: 12px !important; }
  body.es-mobile-on > div.fixed.inset-0 [role="dialog"] > div:last-child.border-t button { padding-inline: 10px; justify-content: center; }
}
/* GOV-R180-A (CR-394): item 29 of skill section 6c - one control in the home bar that reads as search: glass on the gradient bar
   (white 10%, blur, a hairline white 20% border, white text at 85%), brightening on hover AND on keyboard focus, always visible and
   shrinking to the magnifying glass alone when the bar is narrow; the palette's clear × follows the text, not the pointer.
   Item 31 - the keyboard shortcut panel (Shift+/ or the user menu). Presentation only. */
.es-modules.es-bs { gap: 8px; height: 38px; min-width: 250px; max-width: 320px; padding-inline: 12px 8px; background: rgb(255 255 255 / .10); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); border: 1px solid rgb(255 255 255 / .20); color: rgb(255 255 255 / .85); font-weight: 600; font-size: 12.5px; transition: background .15s, color .15s, transform .15s; }
.es-modules.es-bs:hover, .es-modules.es-bs:focus-visible { background: rgb(255 255 255 / .20); color: #fff; transform: translateY(-1px); }
.es-modules.es-bs:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }   /* the ring the file already uses on the gradient bar (.es-band-x), A6 */
.es-bs-ic { font-size: 13px; flex: none; }
.es-bs-tx { flex: 1; min-width: 0; text-align: start; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.es-modules.es-bs kbd { flex: none; margin-inline-start: auto; }
@media (max-width: 1180px) {
  .es-modules.es-bs { min-width: 0; max-width: none; padding-inline: 10px; }
  .es-modules.es-bs .es-bs-tx, .es-modules.es-bs kbd { display: none; }   /* the icon alone, still a 38px target (A10) */
}
html[data-es-motion="reduce"] .es-modules.es-bs { transition: none; } html[data-es-motion="reduce"] .es-modules.es-bs:hover, html[data-es-motion="reduce"] .es-modules.es-bs:focus-visible { transform: none; }
/* the × of the palette search: present while there is text, gone when there is not */
.es-k-x { width: 28px; height: 28px; flex: none; display: inline-flex; align-items: center; justify-content: center; border-radius: 8px; border: 1px solid var(--line); background: rgb(var(--ink) / .04); color: rgb(var(--ink-muted)); font-size: 12px; cursor: pointer; }
.es-k-x[hidden] { display: none; }
.es-k-x:hover, .es-k-x:focus-visible { background: rgb(var(--ink) / .10); color: rgb(var(--ink)); }
/* the shortcut panel */
.es-ks { display: flex; flex-direction: column; gap: 12px; }
.es-ks h4 { margin: 0 0 2px; font-size: 11.5px; font-weight: 700; color: rgb(var(--brand-700)); }
.es-ks dl { margin: 0; display: flex; flex-direction: column; }
.es-ks dl > div { display: flex; align-items: center; gap: 12px; padding: 6px 0; border-bottom: 1px dashed var(--line); }
.es-ks dl > div:last-child { border-bottom: 0; }
.es-ks dt { flex: none; min-width: 108px; display: inline-flex; align-items: center; gap: 4px; direction: ltr; }
.es-ks dt span { color: rgb(var(--ink-muted)); font-size: 11px; }
.es-ks dd { margin: 0; min-width: 0; font-size: 12.5px; color: rgb(var(--ink-2)); }
.es-ks kbd { display: inline-block; min-width: 24px; padding: 3px 6px; border-radius: 6px; border: 1px solid var(--line); border-bottom-width: 2px; background: rgb(var(--surface-2)); color: rgb(var(--ink)); font: 600 11px/1.3 ui-monospace, monospace; text-align: center; }
.dark .es-ks kbd { background: rgb(var(--ink) / .10); }

@media (max-width: 767px) {
  body.es-mobile-on > div.fixed.inset-0 [role="dialog"] > form { flex: 1 1 auto; max-height: none !important; min-height: 100dvh; }
  body.es-mobile-on > div.fixed.inset-0 [role="dialog"] > form > footer, body.es-mobile-on > div.fixed.inset-0 [role="dialog"] > footer { position: sticky; bottom: 0; margin-top: auto; flex-wrap: nowrap !important; gap: 8px !important; padding: 12px 12px calc(12px + env(safe-area-inset-bottom)) !important; border-radius: 0 !important; z-index: 2; }
  body.es-mobile-on > div.fixed.inset-0 [role="dialog"] > form > footer > button, body.es-mobile-on > div.fixed.inset-0 [role="dialog"] > footer > button { flex: 1 1 0; min-height: 44px; padding-inline: 8px !important; justify-content: center; white-space: nowrap; }
  body.es-mobile-on > div.fixed.inset-0 [role="dialog"] > form > header { padding-inline: 16px !important; }
  body.es-mobile-on > div.fixed.inset-0 [role="dialog"] > form > div.overflow-y-auto { padding-inline: 16px !important; }
}
/* SS-R028-A: the short top bar of a phone — back (not on the home page), screen name, notifications; wider gaps between buttons */
.es-mback { display: none; }
@media (max-width: 767px) {
  body.es-mobile-on #es-bar .es-mback { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; flex: none; border: 0; border-radius: 12px; background: rgb(255 255 255 / .14); color: inherit; font-size: 16px; cursor: pointer; }
  [dir="ltr"] body.es-mobile-on #es-bar .es-mback i { transform: scaleX(-1); }
  body.es-mobile-on.es-m-home #es-bar .es-mback { display: none; }
  body.es-mobile-on #es-bar .es-start > button.es-ic:not(.es-mback), body.es-mobile-on #es-bar .es-user, body.es-mobile-on #es-bar .es-user + .es-dd { display: none !important; }
  body.es-mobile-on #es-bar .es-end { gap: 10px; }
  body.es-mobile-on #es-main .es-btn + .es-btn, body.es-mobile-on #es-main .es-acts-row > * + * { margin-inline-start: 6px; }
  body.es-mobile-on #es-main [role="group"] > button, body.es-mobile-on .es-views button, body.es-mobile-on .es-seg button { min-height: 44px; }
}

/* ====================================================================================================================
   GOV-R180-A phase 2 (CR-396) — items 28, 29 and 30 of skill section 6c, and GOV-R185-A. Presentation only.
   ==================================================================================================================== */

/* item 28: the breadcrumb, a slim line under the page band; one line always, the chevron mirrored in RTL,
   a long step cut in the middle by the shell (A37/A38: the full text stays in the title, no hover-only truth) */
/* it sits either at the very top of the screen area (above the head the module draws itself) or, where the shared band is used, under that band */
.es-cr { display: flex; align-items: center; gap: 6px; flex-wrap: nowrap; overflow: hidden; margin: 2px 2px 8px; padding-inline: 2px; font-size: 12px; line-height: 20px; color: rgb(var(--ink-muted)); }
#es-main > .es-cr:first-child { margin: 0 4px 6px; }
.es-band + .es-cr { margin: -8px 2px 14px; }
.es-cr-l { flex: 0 1 auto; min-width: 0; max-width: 42%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding: 2px 4px; border: 0; border-radius: 6px; background: transparent; color: rgb(var(--ink-muted)); font: inherit; text-decoration: none; cursor: pointer; }
.es-cr-l:hover { color: rgb(var(--brand-700)); background: rgb(var(--brand-600) / .08); text-decoration: underline; }
.es-cr-l:focus-visible { outline: 2px solid rgb(var(--brand-600)); outline-offset: 1px; color: rgb(var(--brand-700)); }   /* A6 */
.es-cr-c { flex: 1 1 auto; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding: 2px 4px; font-weight: 700; color: rgb(var(--ink-2)); }
.es-cr-s { flex: none; font-size: 11px; opacity: .65; }
[dir="rtl"] .es-cr-s { transform: scaleX(-1); }   /* A44: the chevron mirrors with the page */
@media (max-width: 640px) { .es-band + .es-cr { margin-top: -4px; } .es-cr-l { max-width: 32%; } }

/* item 29: a row of «نتائج أخرى» — another module's screen, with the module it belongs to */
.es-k-o .es-k-oi { width: 22px; flex: none; text-align: center; color: rgb(var(--brand-600)); }
.es-k-m { flex: none; max-width: 40%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding: 1px 7px; border-radius: 999px; border: 1px solid var(--line); background: rgb(var(--surface-2)); color: rgb(var(--ink-muted)); font-size: 11px; }
.es-k-more { width: 100%; margin: 2px 0 6px; padding: 5px 8px; border: 1px dashed var(--line); border-radius: 9px; background: transparent; color: rgb(var(--ink-muted)); font-size: 11.5px; cursor: pointer; }
.es-k-more:hover, .es-k-more:focus-visible { background: rgb(var(--surface-2)); color: rgb(var(--ink)); }
.es-k-note { margin: 10px 2px 0; font-size: 11.5px; color: rgb(var(--ink-muted)); }

/* item 30: the undo button inside the toast — a real button, bilingual, with a visible focus ring on the dark toast (A6, A12) */
.es-toast { display: flex; align-items: center; gap: 12px; }
.es-toast-t { min-width: 0; }
.es-toast-u { flex: none; min-height: 26px; padding: 3px 10px; border-radius: 8px; border: 1px solid rgb(255 255 255 / .45); background: rgb(255 255 255 / .14); color: #fff; font: 700 12px/1.4 inherit; cursor: pointer; }
.es-toast-u:hover { background: rgb(255 255 255 / .28); }
.es-toast-u:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

/* ====================================================================================================================
   GOV-R186-A (CR-397) — «حجم النص / Text size» of «ملفي الشخصي» ← «التفضيلات والمظهر»: 100% (default), 112%, 125%.
   Two halves, so the whole interface grows and no fixed height breaks (A36 text reflow):
     (a) the root font size scales everything written in rem or em — that is every module screen (Tailwind: text-sm = .875rem);
     (b) the shell's own chrome is written in px on purpose (the bar and band heights are fixed), so its text is scaled by the
         factor --es-ts instead; at 100% every value below is exactly what it was, so nothing is restyled.
   The bars keep their heights (52/64/78px home bar, 52/80/105px band): only the text inside them grows, and it still fits at 125%.
   ==================================================================================================================== */
html { --es-ts: 1; }
html[data-es-text="112"] { font-size: 112%; --es-ts: 1.12; }
html[data-es-text="125"] { font-size: 125%; --es-ts: 1.25; }
html[data-es-text] .es-btn, html[data-es-text] .es-item, html[data-es-text] .es-note, html[data-es-text] .es-am, html[data-es-text] .es-k-i,
html[data-es-text] .es-prow label, html[data-es-text] .es-ks dd { font-size: calc(12.5px * var(--es-ts)); }
html[data-es-text] .es-item-n, html[data-es-text] .es-seg button, html[data-es-text] .es-search input { font-size: calc(12px * var(--es-ts)); }
/* GOV-R196-A (CR-398): the two fields of the session and format card grow with the text size like the rest */
html[data-es-text] .es-psel, html[data-es-text] .es-pnum { font-size: calc(12px * var(--es-ts)); }
html[data-es-text] .es-page b { font-size: calc(15px * var(--es-ts)); }
html[data-es-text] .es-page small { font-size: calc(11px * var(--es-ts)); }
html[data-es-text] .es-prow label small { font-size: calc(10.5px * var(--es-ts)); }
html[data-es-text] .es-band h2 { font-size: calc(19px * var(--es-ts)); }
html[data-es-text] body.es-band-m .es-band h2 { font-size: calc(20px * var(--es-ts)); }
html[data-es-text] body.es-band-l .es-band h2 { font-size: calc(23px * var(--es-ts)); }
html[data-es-text] .es-band p { font-size: calc(12.5px * var(--es-ts)); }
html[data-es-text] .es-cr { font-size: calc(12px * var(--es-ts)); }
html[data-es-text] .es-k-m { font-size: calc(11px * var(--es-ts)); }

/* ---- SS-R032-A (CR-402, owner 2026-11-13 «بالنسبة لعرض الهاتف هل اختيار الوظائف من النافيجيتور صحيح»): on a phone the side menu
   is not the way a function is chosen — the bottom tabs, the main action and search are. It stays as the third path, «كل الشاشات»,
   and is drawn for the thumb: a full-screen sheet with a close button, folded groups, 48px rows and no screen code.
   Phone layout only (body.es-mobile-on under 768px), so no desktop screen of any module changes. */
.es-mclose { display: none; }
@media (max-width: 767px) {
  body.es-mobile-on #es-side { width: 100%; max-width: 100%; padding-top: env(safe-area-inset-top); }
  body.es-mobile-on #es-backdrop { display: none; }
  body.es-mobile-on .es-mclose { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 44px; padding: 0 6px; margin-bottom: 2px; border: 0; background: transparent; color: var(--es-nav-text); font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; }
  body.es-mobile-on .es-mclose i { width: 32px; height: 32px; display: inline-flex; align-items: center; justify-content: center; border-radius: 10px; background: rgba(255,255,255,.08); font-size: 14px; }
  body.es-mobile-on .es-head { padding: 8px 12px 6px; }
  body.es-mobile-on .es-search input { padding: 11px 0; font-size: 14px; }
  body.es-mobile-on .es-tab { min-height: 40px; font-size: 13px; }
  body.es-mobile-on .es-x, body.es-mobile-on .es-acts button { width: 34px; height: 34px; font-size: 13px; }
  body.es-mobile-on #es-nav { padding: 2px 12px 14px; }
  body.es-mobile-on .es-gh { min-height: 46px; padding: 8px 10px; font-size: 13px; }
  body.es-mobile-on .es-item-n { min-height: 48px; padding: 10px 44px 10px 10px; font-size: 14px; }
  [dir="rtl"] body.es-mobile-on .es-item-n { padding: 10px 10px 10px 44px; }
  body.es-mobile-on .es-item-n .es-sid { display: none; }
  body.es-mobile-on .es-star { width: 44px; height: 44px; font-size: 14px; }
  body.es-mobile-on .es-app-btn { min-height: 56px; }
}
@media (max-width: 767px) {
  /* SS-R032-A: while the sheet is open the bottom tabs stay reachable above it, and the main action does not cover the list */
  body.es-mobile-on #es-side { z-index: 46; }
  body.es-mobile-on.es-nav-open #es-nav { padding-bottom: calc(86px + env(safe-area-inset-bottom)); }
  body.es-mobile-on.es-nav-open #es-foot { display: none; }
  body.es-mobile-on.es-nav-open .es-fab { display: none !important; }
  body.es-mobile-on #es-mtabs { z-index: 47; }
}
@media (max-width: 767px) {
  /* SS-R032-A: search is the first path on a phone, so the finder opens as a full page with a thumb-sized field and 48px rows */
  body.es-mobile-on #es-modal .es-modal.wide { width: 100%; max-width: none; min-height: 100dvh; border-radius: 0; padding-top: env(safe-area-inset-top); display: flex; flex-direction: column; }
  body.es-mobile-on #es-modal .es-modal.wide .es-m-b { flex: 1 1 auto; max-height: none; }
  body.es-mobile-on .es-k-s { position: sticky; top: 0; z-index: 2; }
  body.es-mobile-on .es-k-s input { padding: 13px 0; font-size: 15px; }
  body.es-mobile-on .es-k-l { max-height: none; }
  body.es-mobile-on .es-k-i { min-height: 48px; font-size: 14px; }
  body.es-mobile-on .es-k-x { width: 40px; height: 40px; }
  body.es-mobile-on #es-modal .es-hx { width: 40px; height: 40px; }
}
@media (max-width: 767px) {
  body.es-mobile-on #es-modal.es-modal-w:has(.es-modal.wide) { padding: 0; align-items: stretch; }
}

/* ---- GOV-R201-A (CR-410, measured 2026-11-13 across the ten employee screens at 390px): the 44px touch rule of the phone layout
   (skill item 18, SS-R028-A) was enforced only on the shell's own bar, so a module's own controls kept their desktop height —
   39 of 50 controls under 44px on the requests screen, 30 of 32 on the administrative one. It now reaches every control a module
   draws inside its screen area, for any module that turns the phone layout on. Phone widths only; no desktop view changes. */
@media (max-width: 767px) {
  body.es-mobile-on #es-main button,
  body.es-mobile-on #es-main a.btn,
  body.es-mobile-on #es-main [class*="rounded-xl"][onclick],
  body.es-mobile-on #es-main select,
  body.es-mobile-on #es-main input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="hidden"]),
  body.es-mobile-on #es-main textarea { min-height: 44px; }
  body.es-mobile-on #es-main input[type="checkbox"], body.es-mobile-on #es-main input[type="radio"] { min-width: 22px; min-height: 22px; }
  body.es-mobile-on #es-main td button, body.es-mobile-on #es-main td a.btn { min-height: 40px; }
  body.es-mobile-on #es-main .eg-bar button, body.es-mobile-on #es-main .eg-bar select { min-height: 44px; min-width: 44px; }
  body.es-mobile-on #es-main .eg-menu button { min-height: 44px; }
  /* a link inside a sentence is not a control row: it keeps the line height so prose does not break apart */
  body.es-mobile-on #es-main p a, body.es-mobile-on #es-main small a, body.es-mobile-on #es-main li a { min-height: 0; }
}

/* GOV-R222-A (CR-443): review information stays off the screen until the reviewer asks for it (design skill, sections 6c item 3 and 0d). */
html:not(.es-review-on) [data-review] { display: none !important; }
html.es-review-on [data-review] { outline: 1px dashed rgb(var(--border-strong)); outline-offset: 1px; border-radius: 4px; }
/* A module read by employees (it sets es-aud-employee on <html>, design skill section 0d) keeps the shell's own screen codes for the review switch too. */
html.es-aud-employee:not(.es-review-on) :is(.es-sid, .es-page-scr) { display: none !important; }

/* ====================================================================================================================
   GOV-R192-A (CR-573) — sticky notes «ملاحظاتي اللاصقة / My sticky notes», built once in the shared shell for every module: a card in
   My profile, a drawer from the user menu and the command palette, and EmisShell.notes({ form, object, label }). The user's own
   SYS_Notes rows (owner CREATED_BY) as cards in the colour of their SYS_Notes_Category: the script passes --nt-c (R G B), --nt-a (A as
   alpha) and --nt-fg (#0f172a or white, whichever reads better against the colour really behind the text). In dark mode a card is the
   raised dark surface with a faint tint and a 4px inline-start bar of its colour, so its text stays ink. Radii: 10px fields and buttons,
   16px cards, full pills (skill section 4). No status, no approval step. es-nt-tabs and es-nt-n belong to the bell (emis-shell-pages.css).
   ==================================================================================================================== */
.es-nt { display: flex; flex-direction: column; gap: 10px; padding: 4px 0 8px; }
.es-nt-tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.es-nt-s { flex: 1 1 180px; min-width: 0; display: flex; align-items: center; gap: 6px; padding: 0 10px; border-radius: 10px; border: 1px solid rgb(var(--border-strong)); background: rgb(var(--surface)); }
.es-nt-s:focus-within { outline: 2px solid rgb(var(--brand-600)); outline-offset: 2px; }
.es-nt-s > i { font-size: 12px; color: rgb(var(--ink-muted)); }
.es-nt-s input { flex: 1; min-width: 0; border: 0; background: transparent; padding: 8px 0; font: inherit; font-size: 12.5px; color: rgb(var(--ink)); outline: none; }
.es-nt-s input::placeholder { color: rgb(var(--ink-muted)); }
.es-nt-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.es-nt-chip { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 10px; border-radius: 999px; border: 1px solid var(--line); background: rgb(var(--surface)); color: rgb(var(--ink-2)); font: inherit; font-size: 12px; font-weight: 600; cursor: pointer; white-space: nowrap; }
.es-nt-chip:hover { background: rgb(var(--surface-2)); color: rgb(var(--ink)); }
.es-nt-chip[aria-pressed="true"] { background: rgb(var(--brand-50)); border-color: rgb(var(--brand-600)); color: rgb(var(--brand-700)); }
.es-nt-chip:focus-visible, .es-nt-add:focus-visible { outline: 2px solid rgb(var(--brand-600)); outline-offset: 2px; }
.es-nt-cnt { min-width: 18px; padding: 0 5px; border-radius: 999px; font-size: 11px; font-weight: 700; line-height: 16px; text-align: center; background: rgb(var(--ink) / .08); direction: ltr; font-variant-numeric: tabular-nums; }
.es-nt-mcnt { margin-inline-start: auto; }
.es-nt-sw { display: inline-block; width: 12px; height: 12px; flex: none; border-radius: 999px; background: rgb(var(--nt-c) / var(--nt-a)); box-shadow: inset 0 0 0 1px rgb(15 23 42 / .2); }
.es-nt-g { display: flex; flex-direction: column; gap: 8px; }
.es-nt-gh { display: flex; align-items: center; gap: 8px; margin: 4px 0 0; font-size: 12.5px; font-weight: 700; color: rgb(var(--ink)); }
.es-nt-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; }
.es-nt-card { display: flex; flex-direction: column; gap: 8px; min-width: 0; padding: 12px; border-radius: 16px; background: rgb(var(--nt-c) / var(--nt-a)); color: var(--nt-fg); border: 1px solid rgb(15 23 42 / .08); box-shadow: 0 1px 2px rgba(16,24,40,.05); }
.es-nt-tx { margin: 0; font-size: 13px; line-height: 1.6; white-space: pre-wrap; overflow-wrap: anywhere; }
[dir="rtl"] .es-nt-tx { line-height: 1.75; }
/* the link badge is a reference, not a button: an outlined pill on the surface, so it reads the same on every category colour */
.es-nt-link { align-self: flex-start; max-width: 100%; display: inline-flex; align-items: center; gap: 5px; height: 20px; padding: 0 8px; border-radius: 999px; font-size: 11px; font-weight: 600; line-height: 16px; background: rgb(var(--surface)); color: rgb(var(--ink-2)); border: 1px solid var(--line); }
.es-nt-link i { font-size: 10px; flex: none; }
.es-nt-link span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.es-nt-foot { display: flex; align-items: center; justify-content: space-between; gap: 6px; flex-wrap: wrap; }
.es-nt-meta { font-size: 11.5px; font-variant-numeric: tabular-nums; }
.es-nt-acts { display: inline-flex; align-items: center; gap: 4px; margin-inline-start: auto; }
.es-nt-mv { max-width: 128px; height: 30px; padding: 0 6px; border-radius: 10px; border: 1px solid currentColor; background: transparent; color: inherit; font: inherit; font-size: 11.5px; font-weight: 600; cursor: pointer; }
.es-nt-mv option { color: rgb(var(--ink)); background: rgb(var(--surface)); }
.es-nt-ib { width: 30px; height: 30px; display: inline-flex; align-items: center; justify-content: center; border-radius: 10px; border: 0; background: transparent; color: inherit; font-size: 12px; cursor: pointer; }
.es-nt-ib:hover, .es-nt-mv:hover { background: color-mix(in srgb, currentColor 12%, transparent); }
.es-nt-card :focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }
.dark .es-nt-card { background: linear-gradient(rgb(var(--nt-c) / .14), rgb(var(--nt-c) / .14)), rgb(var(--surface-2)); color: rgb(var(--ink)); border: 1px solid var(--line); border-inline-start: 4px solid rgb(var(--nt-c)); }
.dark .es-nt-chip[aria-pressed="true"] { background: rgb(var(--brand-500) / .16); color: rgb(var(--brand-200)); border-color: rgb(var(--brand-400)); }
.es-nt-empty { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 22px 12px; text-align: center; border: 1px dashed rgb(var(--border-strong)); border-radius: 16px; background: rgb(var(--surface-2)); }
.es-nt-empty-ic { width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center; border-radius: 10px; background: rgb(var(--brand-600)); color: #fff; font-size: 16px; }
.es-nt-empty b { font-size: 13px; color: rgb(var(--ink)); }
.es-nt-empty small { font-size: 12px; color: rgb(var(--ink-2)); }
.es-nt-scope { display: flex; align-items: center; gap: 8px; margin: 0 0 10px; padding: 8px 12px; border-radius: 10px; background: rgb(var(--brand-50)); color: rgb(var(--brand-800)); font-size: 12.5px; font-weight: 600; }
.dark .es-nt-scope { background: rgb(var(--brand-500) / .14); color: rgb(var(--brand-200)); }
.es-nt-pcard h4 i { color: rgb(var(--brand-600)); }
.dark .es-nt-pcard h4 i { color: rgb(var(--brand-300)); }
/* the add / edit dialog */
.es-nt-form { display: flex; flex-direction: column; gap: 14px; }
.es-nt-fld { display: flex; flex-direction: column; gap: 6px; margin: 0; padding: 0; border: 0; min-width: 0; }
.es-nt-fld > legend { margin-bottom: 6px; }   /* a legend stands outside the flex gap */
.es-nt-fld > label, .es-nt-fld > legend { padding: 0; font-size: 12.5px; font-weight: 600; color: rgb(var(--ink)); }
.es-nt-req { color: rgb(190 18 60); }
.es-nt-fld textarea { width: 100%; box-sizing: border-box; min-height: 110px; resize: vertical; padding: 8px 10px; border-radius: 10px; border: 1px solid rgb(var(--border-strong)); background: rgb(var(--surface)); color: rgb(var(--ink)); font: inherit; font-size: 13px; line-height: 1.6; }
.es-nt-fld textarea:focus-visible { outline: 2px solid rgb(var(--brand-600)); outline-offset: 2px; }
.es-nt-fld textarea[aria-invalid="true"] { border-color: rgb(225 29 72); }
.es-nt-err { display: flex; align-items: center; gap: 6px; margin: 0; font-size: 12px; font-weight: 600; color: rgb(190 18 60); }
.es-nt-err[hidden] { display: none; }
.dark .es-nt-err, .dark .es-nt-req { color: rgb(253 164 175); }
.es-nt-opts { display: flex; flex-wrap: wrap; gap: 6px; }
.es-nt-opt { position: relative; display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); background: rgb(var(--surface)); color: rgb(var(--ink-2)); font-size: 12.5px; font-weight: 600; cursor: pointer; }
.es-nt-opt input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.es-nt-opt:has(input:checked) { border-color: rgb(var(--brand-600)); background: rgb(var(--brand-50)); color: rgb(var(--brand-700)); box-shadow: inset 0 0 0 1px rgb(var(--brand-600)); }
.es-nt-opt:has(input:checked)::after { content: '\f00c'; font-family: 'Font Awesome 6 Free'; font-weight: 900; font-size: 10px; }   /* not colour alone: a check on the chosen one */
.es-nt-opt:has(input:focus-visible) { outline: 2px solid rgb(var(--brand-600)); outline-offset: 2px; }
.dark .es-nt-opt:has(input:checked) { background: rgb(var(--brand-500) / .16); color: rgb(var(--brand-200)); border-color: rgb(var(--brand-400)); box-shadow: none; }
.es-nt-lk { gap: 8px; }
.es-nt-chk { display: flex; align-items: flex-start; gap: 8px; font-size: 12.5px; font-weight: 600; color: rgb(var(--ink-2)); cursor: pointer; }
.es-nt-chk input { width: 16px; height: 16px; margin: 2px 0 0; flex: none; accent-color: rgb(var(--brand-600)); }
.es-nt-chk input:focus-visible { outline: 2px solid rgb(var(--brand-600)); outline-offset: 2px; }
.es-nt-chk small { display: block; font-size: 11.5px; font-weight: 400; color: rgb(var(--ink-muted)); }
.es-nt-chk:has(input:disabled) { opacity: .6; cursor: not-allowed; }
.es-nt-q { margin: 10px 0 0; padding: 8px 12px; border-radius: 10px; border-inline-start: 3px solid rgb(var(--border-strong)); background: rgb(var(--surface-2)); color: rgb(var(--ink-2)); font-size: 12.5px; white-space: pre-wrap; overflow-wrap: anywhere; }
html[data-es-text] .es-nt-tx { font-size: calc(13px * var(--es-ts)); }
html[data-es-text] .es-nt-chip, html[data-es-text] .es-nt-s input, html[data-es-text] .es-nt-meta, html[data-es-text] .es-nt-mv { font-size: calc(12px * var(--es-ts)); }
/* touch: 44px targets on a phone width and on any coarse pointer; one note per row on a phone */
@media (max-width: 767px), (pointer: coarse) {
  .es-nt-ib, .es-nt-chip, .es-nt-mv, .es-nt-opt, .es-nt-add, .es-nt-empty .es-btn { min-height: 44px; }
  .es-nt-ib { min-width: 44px; }
  .es-nt-s input { padding: 12px 0; min-height: 44px; box-sizing: border-box; }
  .es-nt-chk { min-height: 44px; align-items: center; }
  .es-nt-chk input { width: 20px; height: 20px; margin: 0; }
}
@media (max-width: 767px) { .es-nt-grid { grid-template-columns: 1fr; } }
/* GOV-R240 (CR-604): the band's close icon on a module's own page head (EmisShell.heroClose); the head's own text colour, so it reads on a white head and on a gradient one */
.page-hero.es-has-x { position: relative; padding-inline-end: 56px; }
.es-hero-x { position: absolute; top: 12px; inset-inline-end: 12px; z-index: 1; width: 30px; height: 30px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 13px; color: inherit; cursor: pointer;
  background: color-mix(in srgb, currentColor 10%, transparent); border: 1px solid color-mix(in srgb, currentColor 30%, transparent); transition: transform .2s ease, background-color .2s ease; }
.es-hero-x:hover { background: color-mix(in srgb, currentColor 22%, transparent); transform: rotate(90deg); }
.es-hero-x:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }
html[data-es-motion="reduce"] .es-hero-x:hover { transform: none; }
body .page-hero.es-has-x > .es-hero-x, #main-content .page-hero.es-has-x > .es-hero-x, #es-main .page-hero.es-has-x > .es-hero-x { position: absolute; }   /* a module rule such as «body .page-hero > *» (Self Service) or «#main-content .page-hero > *» (Attendance) { position: relative } must not pull it into the flow */
@media print { .es-hero-x { display: none; } }
/* GOV-R241 (CR-606): the inline error of a form dialog (EmisShell.formDialog / modal({ onSubmit })), slice 1 of ending the Payroll shell fork (GOV-R197) */
.es-m-err:empty { display: none; }
.es-m-err { margin-top: 12px; }
.es-m-errt { display: flex; align-items: flex-start; gap: 8px; padding: 9px 12px; border-radius: 12px; font-size: 12.5px; line-height: 1.6; color: rgb(159 18 57); background: rgb(255 241 242); border: 1px solid rgb(254 205 211); }
.es-m-errt i { margin-top: 3px; }
.dark .es-m-errt { color: rgb(254 205 211); background: rgb(136 19 55 / .28); border-color: rgb(190 18 60 / .55); }
/* GOV-R245 (CR-617): a KPI tile without an action (EmisShell.kpi with no onclick) is a plain box: the card look, no pointer, no hover lift */
.es-kpi.es-kpi-static { cursor: default; }
.es-kpi.es-kpi-static:hover { transform: none; box-shadow: var(--shadow-1, 0 1px 2px rgb(15 23 42 / .06)); border-color: var(--line); }
/* GOV-R250 (CR-625): the enterprise-home item at the foot of the application switcher (slice 10 of ending the Payroll shell fork, GOV-R197) */
.es-am-all { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 0 8px 8px; padding: 9px 10px; border: 1px dashed rgb(var(--brand-300)); border-radius: 12px; background: rgb(var(--brand-50)); color: rgb(var(--brand-800)); font: inherit; font-size: 12.5px; font-weight: 700; cursor: pointer; }
.es-am-all:hover { background: rgb(var(--brand-100)); }
.es-am-all:focus-visible { outline: 2px solid rgb(var(--brand-500)); outline-offset: 2px; }
.dark .es-am-all { background: rgb(var(--brand-500) / .14); color: rgb(var(--brand-100)); border-color: rgb(var(--brand-500) / .5); }
.es-am-menu .es-gold { color: rgb(245 158 11); }
.es-pthm { display: inline-flex; flex-wrap: wrap; gap: 6px; }   /* My profile: choose a theme or open the theme builder (GOV-R284-A) */
/* GOV-R286-A (CR-661): the page header in one place. The breadcrumb is the first line of the page band (.es-band, or a module's .page-hero),
 * with the parents only, in the band's own text colour; the band's title names the screen, so the top bar names the module. A screen
 * without a band keeps the title in the top bar and the breadcrumb above its content. */
.es-pg-m { display: none; }
html.es-cr-inband .es-pg-t { display: none; }
html.es-cr-inband .es-pg-m { display: inline; }
.es-cr.es-cr-in { margin: 0 0 6px; padding: 0; color: inherit; opacity: .85; font-size: 12px; line-height: 18px; }
.es-cr.es-cr-in :is(.es-cr-l, .es-cr-s, .es-cr-c) { color: inherit; }
.es-cr.es-cr-in .es-cr-l:hover { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.es-cr.es-cr-in .es-cr-l:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; border-radius: 4px; }
.es-band > .es-cr.es-cr-in { flex: 1 1 100%; order: -1; }
/* the compact page band (the theme's «شريط الصفحة: مضغوط»): the path keeps one short line, closer to the title */
body.es-band-s .es-cr.es-cr-in, html[data-band="s"] .es-cr.es-cr-in { margin-bottom: 2px; font-size: 11.5px; line-height: 16px; }
/* the space the separate path line held is given back: the screen starts closer to the bar */
@media (min-width: 900px) { html.es-cr-inband #es-main { padding-top: 6px; }
html.es-cr-inband #es-main > main.overflow-y-auto { padding-top: 16px; } }
html[data-foundation] .es-cr.es-cr-in, html[data-foundation][data-es-text] #es-main .es-cr.es-cr-in { font-size: calc(var(--fs-1, 12px) * var(--es-ts, 1)); }   /* the foundation v2 keeps the path in the band at its 12px floor (GOV-R283-A, GOV-R286-A) */
/* fixes of the profile page (owner 2026-11-18 «صحح الاخطاء فى شاشة برفايل المستخدم», GOV-R288-A):
 * the top-bar title had a line too tight for Arabic letters and the code chip, so their tops were cut */
.es-page b { line-height: 1.5; }
.es-page-scr { vertical-align: middle; line-height: 16px; }
/* the empty gap above the page band is given back on every page whose band comes first, not only on pages with a path (GOV-R286-A) */
@media (min-width: 900px) { html:has(#es-main .es-band, #es-main .page-hero) #es-main { padding-top: 6px; } html:has(#es-main .es-band, #es-main .page-hero) #es-main > main.overflow-y-auto { padding-top: 16px; } }
/* GOV-R294-A (owner 2026-11-18): (1) a screen-number chip is written left to right, so its «start» margin fell on the far side and it touched an
 * Arabic title; the space is set on the side of the title in each direction. (2) When the top bar names the module, the line under it does
 * not repeat it (group · SEMIS), so it is not cut on a narrower bar. */
html[dir="rtl"] :is(.es-page-scr, .page-hero .scr-no, .es-band .scr-no) { margin-left: 0; margin-right: 8px; }
html[dir="ltr"] :is(.es-page-scr, .page-hero .scr-no, .es-band .scr-no) { margin-right: 0; margin-left: 8px; }
html.es-cr-inband .es-pg-sm { display: none; }
.es-page small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* GOV-R300-A (CR-673): the review switch is a check item of the user menu */
.es-rv-item .es-rv-ck { margin-inline-start: auto; opacity: 0; color: rgb(var(--brand-600)); }
.es-rv-item[aria-checked="true"] .es-rv-ck { opacity: 1; }
/* GOV-R299-A (CR-673, found 2026-11-18 on SCR-PB11): below 400px the home bar icons fit the width; the bar no longer pushes the page into a sideways
 * scroll (at 313px it needed about 373px). Tighter padding, gaps and icon size; no control is removed. */
@media (max-width: 400px) {
  #es-bar { gap: 6px; padding: 0 8px; }
  #es-bar .es-end { gap: 4px; }
  #es-bar .es-ic, #es-bar .es-modules { height: 34px; min-width: 34px; padding: 0 8px; }
}

/* GOV-R307-A (CR-687, owner 2026-11-19 «فى حال الصفحة كبيرة ويكون فيها سكرول كبير لاغلاقها يتم الاستغراق وقت كبير للوصول الى زر الاغلاق»,
 * «ينطبق ايضا على التعديل او سجل جديد», then «نعم، نفّذها»): close and save within reach on a long page (emis-sticky.js).
 * (1) the slim title bar under the home bar once the page band has scrolled away: title, status, «to the top», close;
 * (2) the action row at the end of a long page form stays at the bottom of the window;
 * (3) the footer of a module dialog stays at the bottom of its window on every screen size (on a phone it already did, SS-R028-A).
 * Theme colours only; with nothing scrolled nothing changes. */
.es-stick { position: fixed; z-index: 29; display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 4px 6px 4px 14px; border-radius: 0 0 14px 14px;
  background: rgb(var(--surface) / .96); color: rgb(var(--ink)); border: 1px solid rgb(var(--border)); border-top: 0; box-shadow: var(--shadow-2); backdrop-filter: blur(8px);
  animation: es-stick-in .18s ease-out; }
[dir="rtl"] .es-stick { padding: 4px 14px 4px 6px; }
.es-stick[hidden] { display: none; }
.es-stick-t { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; font-weight: 700; }
.es-stick > .chip, .es-stick > .hub-status, .es-stick > span:not(.es-stick-sp) { flex: none; }
.es-stick-sp { flex: 1 1 auto; }
.es-stick-b { flex: none; width: 36px; height: 36px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid rgb(var(--border)); border-radius: 10px;
  background: rgb(var(--surface)); color: rgb(var(--ink-2)); font-size: 14px; cursor: pointer; transition: background-color .15s, color .15s, border-color .15s; }
.es-stick-b:hover { background: rgb(var(--surface-2)); color: rgb(var(--ink)); }
.es-stick-x:hover { color: rgb(var(--bad)); border-color: rgb(var(--bad) / .4); }
.es-stick-b:focus-visible { outline: 2px solid rgb(var(--brand-600)); outline-offset: 2px; }
@keyframes es-stick-in { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
html[data-es-motion="reduce"] .es-stick { animation: none; }
@media (prefers-reduced-motion: reduce) { .es-stick { animation: none; } }
@media (pointer: coarse) { .es-stick-b { width: 44px; height: 44px; } }
.es-stick-clip { overflow: clip !important; min-width: 0; }   /* clip, unlike hidden, lets a flex item grow to its content: min-width 0 keeps its old width */
.es-stickfoot { position: sticky; bottom: 0; z-index: 6; }
/* only while the row is held at the bottom of the window (emis-sticky.js sets is-stuck): a surface behind it, wider than the row, with a top line and a soft shadow; nothing moves in the layout */
.es-stickfoot.is-stuck::before { content: ""; position: absolute; inset: -10px -16px 0; z-index: -1; background: rgb(var(--surface)); border-top: 1px solid rgb(var(--border)); box-shadow: 0 -10px 18px -16px rgb(var(--ink) / .45); pointer-events: none; }
body > div.fixed.inset-0 [role="dialog"] > div:last-child.border-t, body > div.fixed.inset-0 [role="dialog"] > footer, body > div.fixed.inset-0 [role="dialog"] > form > footer { position: sticky; bottom: 0; z-index: 2; }
:where(body > div.fixed.inset-0 [role="dialog"] > div:last-child.border-t, body > div.fixed.inset-0 [role="dialog"] > footer, body > div.fixed.inset-0 [role="dialog"] > form > footer) { background-color: rgb(var(--surface)); }
@media print { .es-stick { display: none !important; } .es-stickfoot { position: static; box-shadow: none; } }
