/* Fajr Al-Khair theme ("clean modern" with the brand's brown and orange).
   Light and dark modes: colours come from the variables below; dark mode = [data-theme="dark"] on <html>.
   Only looks change here: every page keeps its contents and class names. */
:root {
    --brand: #6B2F0F;          /* brown (logo) */
    --brand-dark: #4A1F08;
    --accent: #E67E22;         /* orange (website) */
    --accent-dark: #C8691A;
    --ok: #1F9D61;
    --warn: #D98E04;
    --bad: #D64545;
    --info: #2F80ED;

    --bg: #F5F6F8;
    --surface: #FFFFFF;
    --surface-2: #F9FAFB;
    --surface-3: #F2F4F7;
    --ink: #111827;
    --ink-2: #374151;
    --muted: #6B7280;
    --line: #E7E9EE;
    --line-2: #D9DDE4;
    --brand-soft: #FDF1E7;     /* light orange for active items */
    --head: #4A1F08;           /* headings */
    --shadow: 0 1px 2px rgba(16,24,40,.05), 0 1px 3px rgba(16,24,40,.06);
    --shadow-lg: 0 12px 32px -12px rgba(16,24,40,.18), 0 2px 6px rgba(16,24,40,.06);
    --radius: 14px;
    --sidebar-w: 260px;
    --font: "IBM Plex Sans Arabic", "Cairo", "Segoe UI", Tahoma, sans-serif;
    color-scheme: light;
}
[data-theme="dark"] {
    --bg: #0F1115;
    --surface: #171A21;
    --surface-2: #1C2028;
    --surface-3: #222733;
    --ink: #E8EAED;
    --ink-2: #C9CED6;
    --muted: #9AA3AF;
    --line: #262B35;
    --line-2: #323845;
    --brand-soft: rgba(230,126,34,.14);
    --head: #F6C59A;
    --shadow: 0 1px 2px rgba(0,0,0,.45);
    --shadow-lg: 0 16px 40px -12px rgba(0,0,0,.7);
    color-scheme: dark;
}

html { font-size: 15px; }
body { font-family: var(--font); background: var(--bg); color: var(--ink); margin: 0; min-height: 100vh; transition: background .2s, color .2s; }
a { color: var(--accent-dark); }
a:hover { color: var(--accent); }
[data-theme="dark"] a:not(.btn):not(.dropdown-item):not(.side-link):not(.kpi):not(.list-group-item) { color: #F6A55B; }
h1, h2, h3, h4, h5 { color: var(--head); font-weight: 700; letter-spacing: -.2px; }
h2.text-dark, h3.text-dark, .text-dark { color: var(--head) !important; }
.text-primary { color: var(--accent-dark) !important; }
[data-theme="dark"] .text-primary { color: #F6A55B !important; }
.text-muted { color: var(--muted) !important; }
::selection { background: rgba(230,126,34,.25); }

/* ---------- side menu ---------- */
.sidebar { background: var(--surface); color: var(--ink-2); width: var(--sidebar-w); border-left: 1px solid var(--line); display: flex; flex-direction: column; transition: width .2s; }
@media (min-width: 992px) {
    .sidebar { position: fixed; top: 0; bottom: 0; right: 0; overflow-y: auto; z-index: 1030; }
    body.has-sidebar .page { margin-right: var(--sidebar-w); transition: margin .2s; }
    body.side-mini { --sidebar-w: 76px; }
    body.side-mini .sidebar .side-link span, body.side-mini .sidebar .side-group, body.side-mini .sidebar-brand .brand-text, body.side-mini .side-user .side-user-text { display: none; }
    body.side-mini .sidebar .side-link { justify-content: center; }
    body.side-mini .side-user { justify-content: center; }
}
@media (max-width: 991.98px) {
    .sidebar { position: fixed; top: 0; bottom: 0; right: 0; z-index: 1050; overflow-y: auto; transform: translateX(100%); transition: transform .2s ease; box-shadow: var(--shadow-lg); }
    body.sidebar-open .sidebar { transform: none; }
    .sidebar-backdrop { display: none; position: fixed; inset: 0; background: rgba(0,0,0,.35); z-index: 1040; }
    body.sidebar-open .sidebar-backdrop { display: block; }
}
.sidebar-brand { display: flex; align-items: center; justify-content: space-between; padding: 1rem 1rem .9rem; }
.sidebar-brand a { color: var(--ink); }
.sidebar-brand img { height: 44px; width: 44px; object-fit: contain; background: #fff; border-radius: 12px; padding: 3px; margin-left: .65rem; box-shadow: var(--shadow); }
.sidebar-brand .brand-text b { display: block; font-weight: 700; font-size: 1.02rem; color: var(--ink); }
.sidebar-brand .brand-text small { color: var(--muted); font-size: .78rem; }
.sidebar-nav { padding: .25rem .65rem 1rem; flex: 1; }
.side-group { color: var(--muted); font-size: .74rem; font-weight: 600; margin: 1rem .7rem .35rem; letter-spacing: .02em; }
.side-link { display: flex; align-items: center; gap: .7rem; color: var(--ink-2); text-decoration: none; padding: .55rem .75rem; border-radius: 11px; margin-bottom: 2px; font-size: .95rem; font-weight: 500; transition: background .12s, color .12s; }
.side-link i { font-size: 1.12rem; width: 1.35rem; text-align: center; color: var(--muted); transition: color .12s; }
.side-link:hover { background: var(--surface-3); color: var(--ink); }
.side-link:hover i { color: var(--accent); }
.side-link.active { background: var(--brand-soft); color: var(--brand); font-weight: 700; box-shadow: inset -3px 0 0 var(--accent); }
.side-link.active i { color: var(--accent); }
[data-theme="dark"] .side-link.active { color: #F6A55B; }
.side-user { margin: .5rem .65rem 1rem; padding: .65rem .75rem; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); display: flex; align-items: center; gap: .6rem; }
.side-user .avatar { width: 36px; height: 36px; border-radius: 50%; background: linear-gradient(135deg, var(--accent), var(--brand)); color: #fff; display: grid; place-items: center; font-weight: 700; flex: none; }
.side-user-text b { display: block; font-size: .9rem; color: var(--ink); }
.side-user-text small { color: var(--muted); font-size: .78rem; }

/* ---------- top bar ---------- */
.topbar { position: sticky; top: 0; z-index: 1020; display: flex; align-items: center; gap: .6rem; background: color-mix(in srgb, var(--bg) 85%, transparent); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); padding: .6rem 1.4rem; min-height: 62px; }
.topbar-title { font-weight: 700; color: var(--head); }
.icon-btn { width: 40px; height: 40px; border-radius: 11px; border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; font-size: 1.1rem; transition: transform .12s, border-color .12s; padding: 0; }
.icon-btn:hover { transform: translateY(-1px); border-color: var(--line-2); color: var(--accent); }
.topbar-user { display: flex; align-items: center; gap: .5rem; color: var(--muted); }
.role-badge { background: var(--brand-soft) !important; color: var(--brand) !important; font-weight: 600; }
[data-theme="dark"] .role-badge { color: #F6A55B !important; }
.topbar-public { justify-content: center; background: var(--surface); }
.public-logo { height: 44px; margin-left: .5rem; }

/* global search */
.gsearch { position: relative; flex: 1; max-width: 520px; }
.gsearch input { width: 100%; height: 42px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); padding: 0 2.6rem 0 4.2rem; font-family: inherit; font-size: .93rem; outline: none; transition: border-color .15s, box-shadow .15s; }
.gsearch input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(230,126,34,.16); }
.gsearch > i { position: absolute; right: .9rem; top: .72rem; color: var(--muted); }
.gsearch kbd { position: absolute; left: .6rem; top: .62rem; font-family: inherit; font-size: .7rem; color: var(--muted); border: 1px solid var(--line); border-radius: 6px; padding: 2px 6px; background: var(--surface-2); }
.gsearch-pop { position: absolute; top: 48px; right: 0; left: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-lg); padding: .4rem; display: none; max-height: 420px; overflow-y: auto; z-index: 1100; }
.gsearch.open .gsearch-pop { display: block; animation: ui-pop .14s ease-out; }
.gsearch-pop .gs-head { font-size: .74rem; color: var(--muted); padding: .35rem .6rem; font-weight: 600; }
.gsearch-pop a { display: flex; gap: .6rem; align-items: center; padding: .5rem .6rem; border-radius: 9px; color: var(--ink); text-decoration: none; font-size: .9rem; }
.gsearch-pop a:hover, .gsearch-pop a.on { background: var(--surface-3); }
.gsearch-pop a i { color: var(--accent); }
.gsearch-pop a small { color: var(--muted); margin-right: auto; font-size: .78rem; }
.gsearch-pop .gs-empty { color: var(--muted); padding: .8rem; text-align: center; font-size: .88rem; }
@media (max-width: 767.98px) { .gsearch kbd { display: none; } .gsearch input { padding-left: .8rem; } }

/* ---------- page ---------- */
.page { min-height: 100vh; display: flex; flex-direction: column; }
.content { flex: 1; padding: 1.5rem 1.6rem 2.5rem; overflow-x: auto; animation: ui-fade .2s ease-out; }
.app-footer { text-align: center; color: var(--muted); font-size: .82rem; padding: .9rem; border-top: 1px solid var(--line); background: transparent; }
.content .w-75, .content .w-50 { width: 100% !important; max-width: 1120px; }

/* ---------- cards ---------- */
.card { border: 1px solid var(--line) !important; border-radius: var(--radius); box-shadow: var(--shadow) !important; background: var(--surface); color: var(--ink); }
.card.shadow-lg { box-shadow: var(--shadow) !important; }
.card-header { background: transparent; border-bottom: 1px solid var(--line); border-radius: var(--radius) var(--radius) 0 0 !important; }
.card-header .card-title { color: var(--head) !important; }
.bg-light { background: var(--surface-2) !important; }
.bg-white { background: var(--surface) !important; }
.border, .border-top, .border-bottom { border-color: var(--line) !important; }

/* ---------- home page number cards ---------- */
.kpi { display: block; position: relative; text-decoration: none; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.1rem 1.2rem; box-shadow: var(--shadow); height: 100%; overflow: hidden; transition: transform .15s, box-shadow .15s; }
a.kpi:hover { color: var(--ink); transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.kpi-icon { position: absolute; left: 1.1rem; top: 1.1rem; width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; font-size: 1.25rem; background: var(--brand-soft); color: var(--accent); }
.kpi-label { color: var(--muted); font-weight: 600; font-size: .88rem; }
.kpi-value { font-size: 1.95rem; font-weight: 700; color: var(--ink); line-height: 1.25; margin-top: .25rem; letter-spacing: -.5px; }
.kpi-warn .kpi-icon { background: rgba(217,142,4,.13); color: var(--warn); }
.kpi-ok .kpi-icon { background: rgba(31,157,97,.12); color: var(--ok); }
.kpi-muted .kpi-icon { background: var(--surface-3); color: var(--muted); }
/* the first card in the brand colour */
.row > div:first-child > .kpi:not(.kpi-warn):not(.kpi-ok):not(.kpi-muted) { background: linear-gradient(135deg, #6B2F0F 0%, #A0522D 100%); border: 0; color: #fff; }
.row > div:first-child > .kpi:not(.kpi-warn):not(.kpi-ok):not(.kpi-muted) .kpi-label { color: #F3DCC6; }
.row > div:first-child > .kpi:not(.kpi-warn):not(.kpi-ok):not(.kpi-muted) .kpi-value { color: #fff; }
.row > div:first-child > .kpi:not(.kpi-warn):not(.kpi-ok):not(.kpi-muted) .kpi-icon { background: rgba(255,255,255,.16); color: #fff; }

/* ---------- buttons ---------- */
.btn { border-radius: 10px; font-weight: 600; transition: transform .1s, box-shadow .15s, background .15s; }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0) scale(.98); }
.btn-primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn-primary:hover, .btn-primary:focus { background: var(--brand-dark); border-color: var(--brand-dark); color: #fff; }
.btn-outline-primary { color: var(--brand); border-color: var(--line-2); background: var(--surface); }
.btn-outline-primary:hover, .btn-outline-primary.active { background: var(--brand); border-color: var(--brand); color: #fff; }
[data-theme="dark"] .btn-primary { background: var(--accent); border-color: var(--accent); }
[data-theme="dark"] .btn-outline-primary { color: #F6A55B; }
.btn-success { background: var(--ok); border-color: var(--ok); }
.btn-warning { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-warning:hover { background: var(--accent-dark); border-color: var(--accent-dark); color: #fff; }
.btn-info { background: var(--surface); border-color: var(--line-2); color: var(--ink-2); }
.btn-info:hover { background: var(--surface-3); border-color: var(--line-2); color: var(--ink); }
.btn-secondary { background: var(--surface); border-color: var(--line-2); color: var(--ink-2); }
.btn-secondary:hover { background: var(--surface-3); border-color: var(--line-2); color: var(--ink); }
.btn-light { background: var(--surface); border-color: var(--line); color: var(--ink-2); }
.btn-light:hover { background: var(--surface-3); color: var(--ink); }
.btn-dark { background: var(--ink); border-color: var(--ink); color: var(--surface); }
.btn-outline-dark { color: var(--ink-2); border-color: var(--line-2); background: var(--surface); }
.btn-outline-dark:hover, .btn-outline-dark.active { background: var(--ink); border-color: var(--ink); color: var(--surface); }
.btn-outline-secondary { color: var(--ink-2); border-color: var(--line-2); }
.btn-outline-secondary:hover { background: var(--surface-3); color: var(--ink); border-color: var(--line-2); }
.btn-link { color: var(--accent-dark); }
.btn:focus, .form-control:focus, .form-select:focus, .form-check-input:focus { box-shadow: 0 0 0 4px rgba(230,126,34,.16) !important; border-color: var(--accent) !important; }
.form-check-input:checked { background-color: var(--accent); border-color: var(--accent); }

/* ---------- tables ---------- */
.table { --bs-table-bg: transparent; color: var(--ink); background: var(--surface); font-size: .92rem; margin-bottom: 0; }
.table thead th, .table thead td, .table .table-light th, .table-light, .table-light > * > * { background: var(--surface-2) !important; color: var(--muted) !important; font-weight: 600; font-size: .82rem; border-bottom: 1px solid var(--line) !important; white-space: nowrap; }
.content .table thead th { position: sticky; top: 0; z-index: 2; }
.table > :not(caption) > * > * { padding: .7rem .7rem; vertical-align: middle; border-color: var(--line); color: var(--ink); background-color: transparent; }
.table-striped > tbody > tr:nth-of-type(odd) > * { --bs-table-accent-bg: transparent; color: var(--ink); }
.table tbody tr { transition: background .1s; }
.table tbody tr:hover > * { --bs-table-accent-bg: var(--surface-2); background-color: var(--surface-2); }
.table-bordered > :not(caption) > * > * { border-width: 0 0 1px 0; }
.table-bordered { border: 1px solid var(--line) !important; border-radius: 12px; overflow: hidden; }
.table-hover > tbody > tr:hover > * { --bs-table-accent-bg: var(--surface-2); color: var(--ink); }
.table-danger > * { background-color: rgba(214,69,69,.08) !important; }
.table-success > * { background-color: rgba(31,157,97,.08) !important; }
.content .table td { white-space: nowrap; max-width: 280px; overflow: hidden; text-overflow: ellipsis; }
.content .table td:has(.row-actions), .content .table td:has(form), .content .table td:has(.dropdown) { overflow: visible; max-width: none; }
.content .table-wrap { overflow-x: auto; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); box-shadow: var(--shadow); }
.content .table-wrap > .table-bordered { border: 0 !important; }
.content .card .table td, .content dl { white-space: normal; }
.content .card .table td > div.small > div { white-space: nowrap; } /* breakdown lines (e.g. payroll commissions) stay on one line */

/* row actions: main button + ⋯ menu */
.row-actions { display: inline-flex; gap: .3rem; align-items: center; }
.row-actions .btn-outline-primary { border-color: var(--line-2); color: var(--ink-2); }
.row-actions .btn-outline-primary:hover { background: var(--surface-3); color: var(--ink); }
.row-actions .btn-light { border-color: var(--line-2); }
.dropdown-menu { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); padding: .35rem; text-align: right; font-size: .92rem; animation: ui-pop .12s ease-out; }
.dropdown-item { border-radius: 8px; color: var(--ink); padding: .45rem .7rem; }
.dropdown-item:hover, .dropdown-item:focus { background: var(--surface-3); color: var(--ink); }
.dropdown-item i { margin-left: .45rem; color: var(--muted); }
.dropdown-item.text-danger i { color: var(--bad); }

/* ---------- badges / alerts / forms ---------- */
.badge { font-weight: 600; border-radius: 999px; padding: .38em .75em; }
/* brand colours through Bootstrap's own variables, so light backgrounds (bg-opacity-10/25) keep working */
:root { --bs-primary-rgb: 107,47,15; --bs-success-rgb: 31,157,97; --bs-danger-rgb: 214,69,69; --bs-info-rgb: 47,128,237; --bs-warning-rgb: 246,194,122; --bs-secondary-rgb: 139,147,161; }
.badge.bg-warning, .bg-warning:not([class*="bg-opacity"]) { color: #3A2A10 !important; }
[data-theme="dark"] .text-black, [data-theme="dark"] .text-dark { color: var(--ink) !important; }
[data-theme="dark"] .bg-opacity-10, [data-theme="dark"] .bg-opacity-25 { color: var(--ink); }
.alert { border-radius: 12px; border: 1px solid transparent; animation: ui-slide .2s ease-out; }
.alert-success { background: rgba(31,157,97,.1); border-color: rgba(31,157,97,.25); color: var(--ok); }
.alert-danger { background: rgba(214,69,69,.1); border-color: rgba(214,69,69,.25); color: var(--bad); }
.alert-warning { background: rgba(217,142,4,.1); border-color: rgba(217,142,4,.28); color: #9A6503; }
.alert-info { background: rgba(47,128,237,.08); border-color: rgba(47,128,237,.22); color: #1F5FB0; }
.alert-secondary { background: var(--surface-3); border-color: var(--line); color: var(--ink-2); }
.alert-light { background: var(--surface-2); border-color: var(--line); color: var(--ink); }
[data-theme="dark"] .alert-warning { color: #F2C25B; }
[data-theme="dark"] .alert-info { color: #86B6F6; }
.form-control, .form-select { border-radius: 10px; border-color: var(--line-2); background-color: var(--surface); color: var(--ink); }
.form-control::placeholder { color: var(--muted); opacity: .8; }
.form-control:disabled, .form-select:disabled, .form-control[readonly] { background-color: var(--surface-3); color: var(--muted); }
label, .col-form-label { color: var(--ink-2); font-weight: 600; }
.input-group-text { background: var(--surface-2); border-color: var(--line-2); color: var(--muted); }
.list-group-item { background: var(--surface); color: var(--ink); border-color: var(--line); }
.modal-content { background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: 16px; }
.modal-header, .modal-footer { border-color: var(--line); }
hr { border-color: var(--line); opacity: 1; }
.select2-container .select2-selection { border-radius: 10px !important; border-color: var(--line-2) !important; min-height: 38px; background: var(--surface) !important; }
.select2-container .select2-selection__rendered { color: var(--ink) !important; }
.select2-dropdown { background: var(--surface) !important; border-color: var(--line-2) !important; color: var(--ink); }
.select2-search__field { background: var(--surface-2) !important; color: var(--ink) !important; }
.select2-results__option--highlighted { background: var(--accent) !important; }
[data-theme="dark"] .btn-close { filter: invert(1) grayscale(1); }
[data-theme="dark"] img.img-thumbnail { background: var(--surface-2); border-color: var(--line); }
[data-theme="dark"] input[type="date"]::-webkit-calendar-picker-indicator, [data-theme="dark"] input[type="month"]::-webkit-calendar-picker-indicator { filter: invert(.8); }

/* pagination */
.page-link { color: var(--ink-2); background: var(--surface); border-color: var(--line); }
.page-item.active .page-link { background: var(--brand); border-color: var(--brand); }

/* ---------- confirm window and toasts (ui.js) ---------- */
.ui-modal-bg { position: fixed; inset: 0; background: rgba(15,10,5,.45); backdrop-filter: blur(3px); display: grid; place-items: center; z-index: 2000; animation: ui-fade .15s; }
.ui-modal { background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: 18px; padding: 1.5rem; width: min(430px, 92vw); box-shadow: var(--shadow-lg); animation: ui-pop .18s ease-out; text-align: right; }
.ui-modal .ui-mi { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; font-size: 1.35rem; background: var(--brand-soft); color: var(--accent); }
.ui-modal .ui-mi.danger { background: rgba(214,69,69,.12); color: var(--bad); }
.ui-modal h5 { margin: .9rem 0 .4rem; font-size: 1.1rem; color: var(--ink); }
.ui-modal p { color: var(--muted); margin: 0 0 1.25rem; line-height: 1.8; font-size: .93rem; }
.ui-modal .ui-acts { display: flex; gap: .5rem; }
.ui-toasts { position: fixed; top: 1rem; left: 1rem; z-index: 2100; display: flex; flex-direction: column; gap: .6rem; }
.ui-toast { background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-right: 4px solid var(--ok); border-radius: 12px; box-shadow: var(--shadow-lg); padding: .75rem 1rem; display: flex; gap: .6rem; align-items: center; min-width: 280px; max-width: 420px; font-size: .92rem; animation: ui-tin .3s cubic-bezier(.2,.8,.2,1); }
.ui-toast i { color: var(--ok); font-size: 1.2rem; }
.ui-toast.err { border-right-color: var(--bad); } .ui-toast.err i { color: var(--bad); }
.ui-toast.out { animation: ui-tout .3s forwards; }

@keyframes ui-pop { from { opacity: 0; transform: translateY(-4px) scale(.98); } }
@keyframes ui-fade { from { opacity: 0; } }
@keyframes ui-slide { from { opacity: 0; transform: translateY(-6px); } }
@keyframes ui-tin { from { opacity: 0; transform: translateX(-30px); } }
@keyframes ui-tout { to { opacity: 0; transform: translateX(-30px); } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

@media (max-width: 575.98px) {
    .content { padding: 1rem .85rem 2rem; }
    .topbar { padding: .5rem .75rem; }
    .topbar-user .uname { display: none; }
}

@media print {
    .sidebar, .topbar, .app-footer, .btn, form, .ui-toasts { display: none !important; }
    body.has-sidebar .page { margin: 0; }
    body { background: #fff; color: #000; }
}

/* ---------- login page ---------- */
.login-shell { min-height: 100vh; display: grid; grid-template-columns: 1fr 1.05fr; }
.login-form { display: grid; place-items: center; padding: 2.5rem 1.5rem; background: var(--bg); }
.login-box { width: 100%; max-width: 380px; }
.login-box .login-logo { width: 72px; height: 72px; object-fit: contain; background: #fff; border-radius: 18px; padding: 5px; box-shadow: var(--shadow-lg); }
.login-box h1 { font-size: 1.7rem; margin: 1.1rem 0 .3rem; color: var(--ink); }
.login-box .sub { color: var(--muted); font-size: .93rem; margin-bottom: 1.2rem; }
.login-field { margin-top: 1rem; }
.login-field label { display: block; font-size: .85rem; color: var(--muted); margin-bottom: .35rem; }
.login-field .inp { position: relative; }
.login-field .inp i { position: absolute; right: .9rem; top: .78rem; color: var(--muted); }
.login-field .form-control { height: 48px; padding-right: 2.5rem; border-radius: 12px; }
.login-box .btn-primary { width: 100%; height: 48px; margin-top: 1.4rem; font-size: 1rem; display: inline-flex; align-items: center; justify-content: center; gap: .5rem; }
.login-art { background: linear-gradient(160deg, #6B2F0F 0%, #3A1806 75%); color: #fff; padding: 3rem; display: flex; flex-direction: column; position: relative; overflow: hidden; }
.login-art .glow { position: absolute; width: 520px; height: 520px; border-radius: 50%; background: radial-gradient(circle, rgba(230,126,34,.45), transparent 60%); left: -160px; bottom: -160px; animation: login-float 9s ease-in-out infinite; }
.login-art .top { display: flex; align-items: center; gap: .75rem; position: relative; }
.login-art .top img { width: 44px; height: 44px; object-fit: contain; background: #fff; border-radius: 12px; padding: 3px; }
.login-art h2 { color: #fff; font-size: 2.3rem; font-weight: 700; margin: auto 0 .7rem; line-height: 1.45; position: relative; }
.login-art p { color: #F3DCC6; max-width: 440px; line-height: 1.9; position: relative; }
.login-copy { text-align: center; color: var(--muted); font-size: .8rem; margin-top: 1.8rem; }
@keyframes login-float { 50% { transform: translate(30px, -30px); } }
@media (max-width: 899.98px) { .login-shell { grid-template-columns: 1fr; } .login-art { display: none; } }

/* owner tasks count in the side menu */
.side-badge { font-size: .72rem; font-weight: 600; padding: .25em .55em; }
body.side-mini .sidebar .side-badge { position: absolute; top: 2px; left: 6px; font-size: .62rem; }
body.side-mini .sidebar .side-link { position: relative; }

/* tabs of related pages (one menu link → several pages) */
.page-tabs { display: flex; gap: .35rem; overflow-x: auto; padding: .25rem 0 .75rem; margin-bottom: .75rem; border-bottom: 1px solid var(--line); scrollbar-width: thin; }
.page-tab { flex: 0 0 auto; display: inline-flex; align-items: center; gap: .4rem; padding: .45rem .85rem; border-radius: 999px; color: var(--ink-2); text-decoration: none; font-weight: 500; font-size: .92rem; border: 1px solid transparent; white-space: nowrap; }
.page-tab:hover { background: var(--surface-3); color: var(--ink-2); }
.page-tab.active { background: var(--brand-soft); color: var(--brand); border-color: var(--line-2); font-weight: 600; }
.page-crumb { margin-bottom: .75rem; font-size: .9rem; }
.page-crumb a { color: var(--ink-2); text-decoration: none; }
/* cards of the reports and settings pages */
.hub-card { display: flex; align-items: center; gap: .85rem; padding: 1rem 1.1rem; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); color: var(--ink-2); text-decoration: none; height: 100%; transition: border-color .12s, box-shadow .12s; }
.hub-card:hover { border-color: var(--line-2); box-shadow: 0 2px 10px rgba(0,0,0,.06); color: var(--ink-2); }
.hub-card > i { font-size: 1.5rem; color: var(--brand); }
.hub-card b { display: block; }
.hub-card small { display: block; color: var(--ink-3, #6b7280); font-size: .82rem; }

/* notifications bell */
.bell-badge { position: absolute; top: -2px; left: -4px; font-size: .62rem; padding: .2em .45em; }
.bell-menu { width: 340px; max-width: 92vw; max-height: 70vh; overflow-y: auto; }
