/* Theme: the device's own UI font (Segoe UI on Windows, San Francisco on Apple, Roboto on Android), an indigo brand colour
   with cyan and amber accents, a dark header and Bootstrap Icons (loaded by Site.master). */
:root {
    --pr-brand: #4f46e5;        /* indigo */
    --pr-brand-dark: #4338ca;
    --pr-brand-soft: #eef2ff;
    --pr-brand-rgb: 79, 70, 229;
    --pr-cyan: #06b6d4;
    --pr-amber: #f59e0b;
    --pr-green: #10b981;
    --pr-rose: #f43f5e;
    --pr-header-from: #0f172a;
    --pr-header-to: #1e1b4b;
    --pr-bg: #f5f7fb;
    --pr-surface: #ffffff;
    --pr-border: #e5e7eb;
    --pr-ink: #0f172a;
    --pr-muted: #64748b;
    --pr-radius: .75rem;
    --pr-shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 2px 8px rgba(15, 23, 42, .06);
    --bs-body-font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --bs-body-color: var(--pr-ink);
    --bs-body-bg: var(--pr-bg);
    --bs-border-color: var(--pr-border);
    --bs-link-color: var(--pr-brand);
    --bs-link-color-rgb: 79, 70, 229;
    --bs-link-hover-color: var(--pr-brand-dark);
    --bs-link-hover-color-rgb: 67, 56, 202;
    --bs-focus-ring-color: rgba(79, 70, 229, .25);
}
body { background: var(--pr-bg); font-family: var(--bs-body-font-family); color: var(--pr-ink); -webkit-font-smoothing: antialiased; }
h1, h2, h3, h4, h5, h6 { font-weight: 650; letter-spacing: -.015em; color: var(--pr-ink); }
h3 { font-size: 1.45rem; }
h5 { font-size: 1.05rem; color: var(--pr-ink); }
.text-muted { color: var(--pr-muted) !important; }
a { text-underline-offset: .15em; }
.bi { line-height: 1; }
/* a heading's leading icon sits in a soft tile */
.page-icon { display: inline-flex; align-items: center; justify-content: center; width: 2.1rem; height: 2.1rem; border-radius: .6rem; margin-right: .6rem;
    background: var(--pr-brand-soft); color: var(--pr-brand); font-size: 1.05rem; vertical-align: -.35rem; }
h5 > .bi:first-child { color: var(--pr-brand); margin-right: .4rem; }

/* header */
.app-header { background: linear-gradient(100deg, var(--pr-header-from) 0%, var(--pr-header-to) 100%); padding-top: .45rem; padding-bottom: .45rem;
    box-shadow: 0 1px 0 rgba(255, 255, 255, .06), 0 6px 20px rgba(15, 23, 42, .18); position: sticky; top: 0; z-index: 1030; }
.brand { display: flex; align-items: center; gap: .6rem; margin-right: 1.5rem; }
.brand-mark { display: inline-flex; align-items: center; justify-content: center; width: 2.25rem; height: 2.25rem; border-radius: .65rem;
    background: linear-gradient(135deg, #6366f1, var(--pr-cyan)); color: #fff; font-size: 1.15rem; box-shadow: 0 4px 12px rgba(99, 102, 241, .45); position: relative; }
.brand-mark::after { content: ""; position: absolute; right: -2px; top: -2px; width: .55rem; height: .55rem; border-radius: 50%; background: var(--pr-amber); border: 2px solid var(--pr-header-from); }
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-name { font-size: 1.2rem; font-weight: 400; letter-spacing: -.01em; color: #fff; }
.brand-name b { font-weight: 800; background: linear-gradient(90deg, #a5b4fc, #67e8f9); -webkit-background-clip: text; background-clip: text; color: transparent; }
.brand-sub { font-size: .66rem; text-transform: uppercase; letter-spacing: .12em; color: rgba(255, 255, 255, .55); margin-top: .15rem; }
.app-header .navbar-toggler { border: 0; color: #fff; font-size: 1.6rem; padding: .1rem .4rem; }
.app-header .navbar-toggler:focus { box-shadow: none; }
.app-header .navbar-nav .nav-link { color: rgba(255, 255, 255, .72); border-radius: .55rem; padding: .45rem .75rem; font-weight: 500; font-size: .93rem; display: flex; align-items: center; gap: .45rem; }
.app-header .navbar-nav .nav-link .bi { font-size: 1rem; opacity: .9; }
.app-header .navbar-nav .nav-link:hover, .app-header .navbar-nav .nav-link:focus, .app-header .navbar-nav .show > .nav-link { color: #fff; background: rgba(255, 255, 255, .08); }
.app-header .navbar-nav .nav-link.active { color: #fff; background: rgba(129, 140, 248, .22); box-shadow: inset 0 0 0 1px rgba(165, 180, 252, .25); }
.app-header .dropdown-toggle::after { margin-left: .1rem; opacity: .6; }
.header-actions { margin-left: auto; }
.btn-accent { --bs-btn-color: #0f172a; --bs-btn-bg: #fbbf24; --bs-btn-border-color: #fbbf24; --bs-btn-hover-color: #0f172a; --bs-btn-hover-bg: #f59e0b;
    --bs-btn-hover-border-color: #f59e0b; --bs-btn-active-bg: #d97706; --bs-btn-active-border-color: #d97706; font-weight: 600; border-radius: .55rem; }
.user-chip { display: inline-flex; align-items: center; gap: .5rem; color: rgba(255, 255, 255, .9); text-decoration: none; padding: .2rem .55rem .2rem .2rem;
    border-radius: 2rem; background: rgba(255, 255, 255, .07); font-size: .9rem; }
.user-chip:hover, .user-chip:focus { color: #fff; background: rgba(255, 255, 255, .13); }
.avatar { display: inline-flex; align-items: center; justify-content: center; width: 1.85rem; height: 1.85rem; border-radius: 50%; font-size: .75rem; font-weight: 700;
    background: linear-gradient(135deg, #818cf8, #22d3ee); color: #0f172a; }
.btn-header-icon { color: rgba(255, 255, 255, .8); background: rgba(255, 255, 255, .07); border: 0; border-radius: 50%; width: 2.2rem; height: 2.2rem; font-size: 1.05rem; }
.btn-header-icon:hover, .btn-header-icon:focus { color: #fff; background: rgba(244, 63, 94, .7); }
.dropdown-menu { border: 1px solid var(--pr-border); box-shadow: 0 12px 32px rgba(15, 23, 42, .14); border-radius: .7rem; padding: .35rem; font-size: .93rem; }
.dropdown-item { border-radius: .45rem; padding: .45rem .7rem; display: flex; align-items: center; gap: .55rem; }
.dropdown-item .bi, .dropdown-item-text .bi { color: var(--pr-brand); font-size: 1rem; width: 1.1rem; text-align: center; }
.dropdown-item-text .bi { margin-right: .4rem; }
.dropdown-item:hover, .dropdown-item:focus { background: var(--pr-brand-soft); color: var(--pr-brand-dark); }
.dropdown-item:active { background-color: var(--pr-brand); color: #fff; }
.dropdown-item:active .bi { color: #fff; }

/* buttons, forms, pagination in the brand colour */
.btn { font-weight: 500; border-radius: .55rem; }
.btn .bi { margin-right: .15rem; }
.btn-primary { --bs-btn-bg: var(--pr-brand); --bs-btn-border-color: var(--pr-brand); --bs-btn-hover-bg: var(--pr-brand-dark); --bs-btn-hover-border-color: var(--pr-brand-dark);
    --bs-btn-active-bg: var(--pr-brand-dark); --bs-btn-active-border-color: var(--pr-brand-dark); --bs-btn-disabled-bg: var(--pr-brand); --bs-btn-disabled-border-color: var(--pr-brand);
    --bs-btn-focus-shadow-rgb: 79, 70, 229; box-shadow: 0 1px 2px rgba(79, 70, 229, .25); }
.btn-outline-primary { --bs-btn-color: var(--pr-brand); --bs-btn-border-color: var(--pr-brand); --bs-btn-hover-bg: var(--pr-brand); --bs-btn-hover-border-color: var(--pr-brand); --bs-btn-active-bg: var(--pr-brand); --bs-btn-active-border-color: var(--pr-brand); }
.btn-outline-secondary { --bs-btn-color: #334155; --bs-btn-border-color: #d1d5db; --bs-btn-bg: #fff; --bs-btn-hover-color: var(--pr-brand-dark); --bs-btn-hover-bg: var(--pr-brand-soft);
    --bs-btn-hover-border-color: #c7d2fe; --bs-btn-active-color: var(--pr-brand-dark); --bs-btn-active-bg: #e0e7ff; --bs-btn-active-border-color: #a5b4fc; }
.btn-secondary { --bs-btn-bg: #334155; --bs-btn-border-color: #334155; --bs-btn-hover-bg: #1e293b; --bs-btn-hover-border-color: #1e293b; }
.btn-success { --bs-btn-bg: #059669; --bs-btn-border-color: #059669; --bs-btn-hover-bg: #047857; --bs-btn-hover-border-color: #047857; }
.btn-link { text-decoration: none; }
.form-control, .form-select { border-color: #d1d5db; border-radius: .55rem; }
.form-control:focus, .form-select:focus { border-color: #818cf8; box-shadow: 0 0 0 .22rem rgba(79, 70, 229, .15); }
.form-check-input:checked { background-color: var(--pr-brand); border-color: var(--pr-brand); }
.form-check-input:focus { box-shadow: 0 0 0 .22rem rgba(79, 70, 229, .15); border-color: #818cf8; }
.pagination { --bs-pagination-active-bg: var(--pr-brand); --bs-pagination-active-border-color: var(--pr-brand); --bs-pagination-color: var(--pr-brand);
    --bs-pagination-border-radius: .5rem; --bs-pagination-hover-bg: var(--pr-brand-soft); gap: .25rem; }
.pagination .page-link { border-radius: .5rem !important; }

/* cards and tables */
.card { --bs-card-bg: var(--pr-surface); border: 1px solid var(--pr-border); box-shadow: var(--pr-shadow); border-radius: var(--pr-radius); }
.card-header { background: transparent; border-bottom-color: var(--pr-border); font-weight: 600; }
.card.stat { overflow: hidden; }
.card.stat .card-body { display: flex; align-items: center; gap: .85rem; }
.card.stat .stat-icon { flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; width: 2.9rem; height: 2.9rem; border-radius: .8rem; font-size: 1.35rem;
    background: var(--pr-brand-soft); color: var(--pr-brand); }
.row > div:nth-child(4n+2) > .card.stat .stat-icon { background: #ecfeff; color: #0891b2; }
.row > div:nth-child(4n+3) > .card.stat .stat-icon { background: #ecfdf5; color: #059669; }
.row > div:nth-child(4n+4) > .card.stat .stat-icon { background: #fffbeb; color: #d97706; }
.card.stat .label { font-size: .72rem; color: var(--pr-muted); text-transform: uppercase; letter-spacing: .07em; font-weight: 600; }
.card.stat .value { font-size: 1.6rem; font-weight: 750; color: var(--pr-ink); font-variant-numeric: tabular-nums; line-height: 1.2; }
.card.stat .value a { text-decoration: none; }
.table { --bs-table-bg: transparent; --bs-table-hover-bg: #f5f7ff; --bs-table-border-color: #eef0f4; margin-bottom: 0; }
/* Bootstrap 5.3 leaves the table's own border-color unset, so .table-bordered row lines fell back to the text colour
   (near-white lines in the dark theme, near-black in the light one). */
.table, .table > :not(caption) > * { border-color: var(--bs-table-border-color); }
.table-responsive { background: var(--pr-surface); border: 1px solid var(--pr-border); border-radius: var(--pr-radius); box-shadow: var(--pr-shadow); margin-bottom: 1rem; }
.table-responsive > .table { background: transparent !important; }
.table-responsive > .table-bordered { border: 0; }
.table-responsive > .table-bordered > :not(caption) > * > * { border-left-width: 0; border-right-width: 0; }
.table > thead > tr > th, .table > thead.table-light > tr > th { background-color: #f8fafc; color: #475569; font-weight: 600; font-size: .74rem; text-transform: uppercase;
    letter-spacing: .05em; border-bottom: 1px solid var(--pr-border); padding-top: .55rem; padding-bottom: .55rem; }
.table > tfoot > tr > td, .table > tfoot > tr > th, .table > tfoot.table-light > tr > td { background-color: #f8fafc; border-top: 1px solid var(--pr-border); }
.alert { border: 1px solid transparent; border-radius: var(--pr-radius); }
.alert > .bi { font-size: 1.1rem; margin-top: .05rem; }
.alert-success { background: #ecfdf5; border-color: #a7f3d0; color: #065f46; }
.alert-danger { background: #fff1f2; border-color: #fecdd3; color: #9f1239; }
.alert-warning { background: #fffbeb; border-color: #fde68a; color: #92400e; }
.alert-info { background: #eff6ff; border-color: #bfdbfe; color: #1e40af; }
.filter-bar { background: var(--pr-surface); border: 1px solid var(--pr-border); border-radius: var(--pr-radius); padding: .7rem .85rem; box-shadow: var(--pr-shadow); }
/* a filter bar that is also a .row: drop the row's negative margins so the card lines up with the table card below it
   and keeps its gap to the heading (the columns' top gutter replaces part of the top padding) */
.filter-bar.row { margin-left: 0; margin-right: 0; margin-top: 0; padding-top: .2rem; }
.filter-bar .btn-secondary { --bs-btn-bg: var(--pr-brand); --bs-btn-border-color: var(--pr-brand); --bs-btn-hover-bg: var(--pr-brand-dark); --bs-btn-hover-border-color: var(--pr-brand-dark); }
.badge-soft { background: var(--pr-brand-soft); color: var(--pr-brand-dark); font-weight: 600; border-radius: 2rem; padding: .3em .7em; }

.table-sm td, .table-sm th { padding: .35rem .5rem; white-space: nowrap; }
.num { text-align: right; font-variant-numeric: tabular-nums; }
.calc { background: var(--pr-brand-soft); border: 1px solid #e0e7ff; }
.filter-bar .form-control, .filter-bar .form-select { min-width: 9rem; }
/* tick boxes and the Filter / Clear buttons sit on the same line as the bottom of the inputs */
.filter-bar .filter-check, .filter-bar .filter-actions { display: flex; align-items: center; min-height: calc(1.5em + .5rem + 2px); }
.filter-bar .filter-actions { gap: .25rem; }
/* page heading row: title on its own line on a phone, buttons below it */
.page-head > h3 { min-width: 0; }
.nav-icon { vertical-align: -3px; margin-right: .25rem; }
.btn-icon { padding: .2rem .45rem; line-height: 1; }
.legend-swatch { display: inline-block; width: 1em; height: 1em; vertical-align: -2px; border-radius: .25rem; margin-right: .3rem; }
.pagination { flex-wrap: wrap; }
.form-label { margin-bottom: .2rem; font-size: .88rem; font-weight: 500; color: #334155; }
.filter-bar .form-label { font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; color: var(--pr-muted); }

/* sign-in page */
.login-wrap { min-height: calc(100vh - 3rem); display: flex; align-items: center; justify-content: center; }
.login-card { width: 100%; max-width: 400px; }
.login-card .card-body { padding: 2rem; }
.login-brand { display: flex; align-items: center; gap: .7rem; margin-bottom: 1.4rem; }
.login-brand .brand-mark { width: 2.75rem; height: 2.75rem; font-size: 1.35rem; }
.login-brand .brand-mark::after { border-color: #fff; }
.login-brand .brand-name { color: var(--pr-ink); font-size: 1.5rem; }
.login-brand .brand-name b { background: linear-gradient(90deg, var(--pr-brand), #0891b2); -webkit-background-clip: text; background-clip: text; color: transparent; }
.login-brand .brand-sub { color: var(--pr-muted); }
.input-icon { position: relative; }
.input-icon > .bi { position: absolute; left: .8rem; top: 50%; transform: translateY(-50%); color: #94a3b8; pointer-events: none; }
.input-icon > .form-control { padding-left: 2.3rem; }
body.anon { background: radial-gradient(1200px 600px at 10% -10%, #e0e7ff 0%, transparent 60%), radial-gradient(900px 500px at 110% 110%, #cffafe 0%, transparent 55%), var(--pr-bg); }

@media (max-width: 991.98px) {
    .calc.sticky-top { position: static; }
    .app-header .navbar-collapse { padding: .5rem 0 .25rem; }
    .header-actions { margin: .5rem 0 0; }
    .brand-sub { display: none; }
}
@media (max-width: 767.98px) {
    h3 { font-size: 1.25rem; }
    .page-icon { width: 1.8rem; height: 1.8rem; font-size: .95rem; }
    .card.stat .value { font-size: 1.2rem; }
    .card.stat .stat-icon { width: 2.3rem; height: 2.3rem; font-size: 1.1rem; }
    .filter-bar .form-control, .filter-bar .form-select { min-width: 0; width: 100%; }
    .filter-bar .col-auto { flex: 1 1 45%; }
    .filter-bar .form-control-sm, .filter-bar .form-select-sm { min-height: calc(1.5em + .5rem + 2px); }   /* empty iOS date boxes collapse otherwise */
    .filter-bar .filter-check, .filter-bar .filter-actions { min-height: 2.6rem; }
    .page-head .page-actions { width: 100%; }
    .page-head .page-actions > .btn { flex: 1 1 0; white-space: nowrap; }
    main.container-fluid { padding-left: .75rem; padding-right: .75rem; } /* not less than a g-4 row's negative margin, or the page scrolls sideways */
    .table-sm td, .table-sm th { padding: .25rem .35rem; font-size: .85rem; }
    .form-control, .form-select { font-size: 16px; } /* keeps iOS from zooming into inputs */
}
@media print {
    .no-print { display: none !important; }
    body { background: #fff; }
    main { padding: 0 !important; }
    .table { font-size: 11px; }
    .table-responsive { border: 0; box-shadow: none; }
}

a.clip { text-decoration: none; }
.drop-zone { border: 2px dashed #c7d2fe; border-radius: var(--pr-radius); background: #fafbff; padding: .75rem; transition: background-color .15s, border-color .15s; }
.drop-zone.over { border-color: var(--pr-brand); background-color: var(--pr-brand-soft); }
.drop-zone .drop-hint { display: none; }
.drop-zone.enhanced .drop-hint { display: block; }
.drop-list { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .5rem; }
.drop-list:empty { display: none; }
.drop-list .pick { display: inline-flex; align-items: center; gap: .35rem; border: 1px solid #dee2e6; border-radius: .375rem; padding: .15rem .4rem; background: #fff; }
.drop-list .pick img { width: 2.5rem; height: 2.5rem; object-fit: cover; border-radius: .25rem; }
.drop-list .pick button { border: 0; background: none; color: #6c757d; padding: 0 .15rem; line-height: 1; font-size: 1.1rem; }
.drop-list .pick button:hover { color: #b02a37; }

/* footer (every page, also printed) */
.app-footer { display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem 1rem; padding: 1rem 1.5rem 1.25rem; margin-top: 1rem;
    color: var(--pr-muted); font-size: .8rem; border-top: 1px solid var(--pr-border); }
body.anon .app-footer { border-top: 0; justify-content: center; }
body.anon .app-footer > .no-print { display: none; }

/* theme switch in the user menu */
.theme-switch .btn { --bs-btn-padding-x: .45rem; font-size: .8rem; white-space: nowrap; }
.theme-switch .btn.active { background: var(--pr-brand); border-color: var(--pr-brand); color: #fff; }
.input-group-text { background: #f8fafc; border-color: #d1d5db; color: #475569; border-radius: .55rem; }

/* phones and tablets: no drag-and-drop or clipboard paste for images, only the picker (camera / gallery) */
@media (hover: none) and (pointer: coarse) {
    .drop-zone .drop-hint, .image-paste { display: none !important; }
}

@media print {
    .app-footer { border-top: 1px solid #cbd5e1; color: #475569; font-size: 9px; padding: 6px 0 0; margin-top: 12px; }
    .table > thead > tr > th { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* dark theme: Bootstrap's own dark mode (data-bs-theme="dark" on <html>) plus the FlyAsh colours */
:root[data-bs-theme="dark"] {
    color-scheme: dark;
    --pr-brand: #818cf8;
    --pr-brand-dark: #a5b4fc;
    --pr-brand-soft: rgba(129, 140, 248, .14);
    --pr-bg: #0b1120;
    --pr-surface: #111827;
    --pr-border: #1f2937;
    --pr-ink: #e5e7eb;
    --pr-muted: #94a3b8;
    --pr-shadow: 0 1px 2px rgba(0, 0, 0, .35), 0 2px 8px rgba(0, 0, 0, .25);
    --bs-body-color: #e5e7eb;
    --bs-body-bg: #0b1120;
    --bs-border-color: #263244;
    --bs-secondary-bg: #1f2937;
    --bs-tertiary-bg: #111827;
    --bs-emphasis-color: #fff;
    --bs-secondary-color: rgba(226, 232, 240, .7);
    --bs-link-color: #a5b4fc;
    --bs-link-color-rgb: 165, 180, 252;
    --bs-link-hover-color: #c7d2fe;
    --bs-link-hover-color-rgb: 199, 210, 254;
}
[data-bs-theme="dark"] body.anon { background: radial-gradient(1200px 600px at 10% -10%, rgba(99, 102, 241, .22) 0%, transparent 60%), radial-gradient(900px 500px at 110% 110%, rgba(6, 182, 212, .14) 0%, transparent 55%), var(--pr-bg); }
[data-bs-theme="dark"] .btn-primary { --bs-btn-bg: #6366f1; --bs-btn-border-color: #6366f1; --bs-btn-hover-bg: #4f46e5; --bs-btn-hover-border-color: #4f46e5; --bs-btn-active-bg: #4338ca; --bs-btn-active-border-color: #4338ca; --bs-btn-disabled-bg: #6366f1; --bs-btn-disabled-border-color: #6366f1; box-shadow: none; }
[data-bs-theme="dark"] .filter-bar .btn-secondary { --bs-btn-bg: #6366f1; --bs-btn-border-color: #6366f1; --bs-btn-hover-bg: #4f46e5; --bs-btn-hover-border-color: #4f46e5; }
[data-bs-theme="dark"] .btn-outline-secondary { --bs-btn-color: #cbd5e1; --bs-btn-border-color: #334155; --bs-btn-bg: transparent; --bs-btn-hover-color: #e0e7ff; --bs-btn-hover-bg: rgba(129, 140, 248, .16);
    --bs-btn-hover-border-color: #4f46e5; --bs-btn-active-color: #e0e7ff; --bs-btn-active-bg: rgba(129, 140, 248, .25); --bs-btn-active-border-color: #6366f1; }
[data-bs-theme="dark"] .btn-secondary { --bs-btn-bg: #334155; --bs-btn-border-color: #334155; --bs-btn-hover-bg: #475569; --bs-btn-hover-border-color: #475569; }
[data-bs-theme="dark"] .theme-switch .btn.active { background: #6366f1; border-color: #6366f1; }
[data-bs-theme="dark"] .form-control, [data-bs-theme="dark"] .form-select { background-color: #0f172a; border-color: #334155; color: #e5e7eb; }
[data-bs-theme="dark"] .form-control::placeholder { color: #64748b; }
[data-bs-theme="dark"] .form-control:focus, [data-bs-theme="dark"] .form-select:focus { border-color: #6366f1; box-shadow: 0 0 0 .22rem rgba(99, 102, 241, .25); }
[data-bs-theme="dark"] .form-control[readonly], [data-bs-theme="dark"] .bg-light { background-color: #1e293b !important; }
[data-bs-theme="dark"] .bg-white { background-color: var(--pr-surface) !important; }
[data-bs-theme="dark"] .input-group-text { background: #1e293b; border-color: #334155; color: #cbd5e1; }
[data-bs-theme="dark"] .form-label { color: #cbd5e1; }
[data-bs-theme="dark"] .filter-bar .form-label { color: var(--pr-muted); }
[data-bs-theme="dark"] .table { --bs-table-color: #e5e7eb; --bs-table-hover-bg: rgba(129, 140, 248, .08); --bs-table-hover-color: #fff; --bs-table-border-color: #1f2937; }
[data-bs-theme="dark"] .table > thead > tr > th, [data-bs-theme="dark"] .table > thead.table-light > tr > th { background-color: #0f172a; color: #cbd5e1; }
[data-bs-theme="dark"] .table > tfoot > tr > td, [data-bs-theme="dark"] .table > tfoot > tr > th, [data-bs-theme="dark"] .table > tfoot.table-light > tr > td { background-color: #0f172a; color: #e5e7eb; }
[data-bs-theme="dark"] .card.stat .stat-icon { background: rgba(129, 140, 248, .16); color: #a5b4fc; }
[data-bs-theme="dark"] .row > div:nth-child(4n+2) > .card.stat .stat-icon { background: rgba(34, 211, 238, .14); color: #67e8f9; }
[data-bs-theme="dark"] .row > div:nth-child(4n+3) > .card.stat .stat-icon { background: rgba(52, 211, 153, .14); color: #6ee7b7; }
[data-bs-theme="dark"] .row > div:nth-child(4n+4) > .card.stat .stat-icon { background: rgba(251, 191, 36, .14); color: #fcd34d; }
[data-bs-theme="dark"] .alert-success { background: rgba(16, 185, 129, .12); border-color: rgba(16, 185, 129, .35); color: #6ee7b7; }
[data-bs-theme="dark"] .alert-danger { background: rgba(244, 63, 94, .12); border-color: rgba(244, 63, 94, .35); color: #fda4af; }
[data-bs-theme="dark"] .alert-warning { background: rgba(245, 158, 11, .12); border-color: rgba(245, 158, 11, .35); color: #fcd34d; }
[data-bs-theme="dark"] .alert-info { background: rgba(59, 130, 246, .12); border-color: rgba(59, 130, 246, .35); color: #93c5fd; }
[data-bs-theme="dark"] .calc { border-color: rgba(129, 140, 248, .25); }
[data-bs-theme="dark"] .drop-zone { background: rgba(129, 140, 248, .05); border-color: #334155; }
[data-bs-theme="dark"] .drop-list .pick { background: #0f172a; border-color: #334155; }
[data-bs-theme="dark"] .dropdown-item:hover, [data-bs-theme="dark"] .dropdown-item:focus { color: #e0e7ff; }
[data-bs-theme="dark"] .pagination { --bs-pagination-bg: var(--pr-surface); --bs-pagination-border-color: #334155; --bs-pagination-hover-bg: rgba(129, 140, 248, .16); --bs-pagination-disabled-bg: var(--pr-surface); --bs-pagination-active-bg: #6366f1; --bs-pagination-active-border-color: #6366f1; }
[data-bs-theme="dark"] .login-brand .brand-mark::after { border-color: var(--pr-surface); }
[data-bs-theme="dark"] .login-brand .brand-name b { background: linear-gradient(90deg, #a5b4fc, #67e8f9); -webkit-background-clip: text; background-clip: text; color: transparent; }
/* ---- payroll ---- */
/* company switcher in the header */
.company-chip { display: inline-flex; align-items: center; gap: .45rem; color: #fff; text-decoration: none; padding: .3rem .7rem; border-radius: 2rem;
    background: rgba(255, 255, 255, .08); box-shadow: inset 0 0 0 1px rgba(165, 180, 252, .25); font-weight: 600; font-size: .88rem; max-width: 22rem; }
.company-chip span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.company-chip:hover, .company-chip:focus { color: #fff; background: rgba(255, 255, 255, .15); }
/* monthly entry sheet: compact number inputs inside the table */
.entry-table td { vertical-align: middle; }
.entry-table input.form-control, .entry-table select.form-select { padding: .15rem .35rem; font-size: .85rem; min-width: 4.2rem; text-align: right; }
.entry-table select.form-select { text-align: left; min-width: 6.5rem; padding-right: 1.6rem; }
.entry-table .calc-cell { background: var(--pr-brand-soft); }
.entry-table tr.changed > td { background-color: #fefce8; }
.entry-table tr.left-employee > td:first-child { box-shadow: inset 3px 0 0 #f43f5e; }
.table .subtotal > td { background: #f8fafc; font-weight: 600; }
/* pay slips: two per A4 page */
.payslip { border: 1px solid #cbd5e1; border-radius: .4rem; padding: 10px 12px; margin-bottom: 14px; page-break-inside: avoid; font-size: 11px; }
.payslip h6 { margin: 0 0 2px 0; font-size: 13px; }
.payslip table { width: 100%; border-collapse: collapse; }
.payslip td, .payslip th { padding: 1px 4px; }
.payslip .net { font-size: 13px; font-weight: 700; border-top: 1px solid #cbd5e1; }
.payslip:nth-of-type(2n) { page-break-after: always; }
[data-bs-theme="dark"] .entry-table .calc-cell { background: rgba(99, 102, 241, .15); }
[data-bs-theme="dark"] .entry-table tr.changed > td { background-color: rgba(250, 204, 21, .08); }
[data-bs-theme="dark"] .table .subtotal > td { background: #1e293b; }
