/* HR Desk Web UI v1. Loaded last; reusable controls opt in through hrd-* classes.
   !important is limited to legacy important/inline presentation overrides. */
:root {
    --hrd-background: #f6f8fb;
    --hrd-surface: #ffffff;
    --hrd-surface-subtle: #f9fbfd;
    --hrd-text-primary: #142b4a;
    --hrd-text-secondary: #5f7188;
    --hrd-text-muted: #8896a8;
    --hrd-primary: #0aa6a6;
    --hrd-primary-hover: #078e8e;
    --hrd-primary-soft: #e6f7f7;
    /* Darker teal for small text and white-on-teal actions (WCAG AA). */
    --hrd-primary-ink: #087b7b;
    --hrd-accent: #2878df;
    --hrd-accent-soft: #eaf3ff;
    --hrd-border: #e3eaf2;
    --hrd-border-strong: #d3deea;
    --hrd-success: #16866b;
    --hrd-success-soft: #e4f7f0;
    --hrd-warning: #a86b13;
    --hrd-warning-soft: #fff4d8;
    --hrd-danger: #d84c4c;
    --hrd-danger-soft: #fdeaea;
    --hrd-radius-small: 6px;
    --hrd-radius-medium: 10px;
    --hrd-radius-large: 12px;
    --hrd-shadow-card: 0 6px 20px rgba(20, 43, 74, .06);
    --hrd-shadow-hover: 0 8px 24px rgba(20, 43, 74, .09);
    --hrd-transition: 160ms ease;
    --hrd-font: Inter, "Segoe UI", Roboto, Arial, sans-serif;
    --hrd-space-1: 4px;
    --hrd-space-2: 8px;
    --hrd-space-3: 12px;
    --hrd-space-4: 16px;
    --hrd-space-5: 24px;
    --hrd-space-20: 20px;
    --hrd-space-32: 32px;
    --hrd-title-size: 26px;
    --hrd-title-weight: 600;
    --hrd-section-size: 16px;
    --hrd-section-weight: 600;
    --hrd-body-size: 13px;
    --hrd-support-size: 12px;
    --hrd-label-size: 12px;
    --hrd-table-size: 13px;
    --hrd-meta-size: 11px;
    --hrd-control-height: 40px;
    --hrd-button-height: 40px;
    --hrd-control-compact-height: 36px;
    --hrd-sidebar-width: 260px;
    --hrd-header-height: 66px;
    --hrd-disabled-background: #eef2f6;
    --hrd-disabled-text: #66758a;
    --hrd-primary-ink-hover: #066969;
    --hrd-danger-ink: #ad3333;
}

/* The application surface is 66px. Retain the approved 78px logo/navigation rail
   and its document offset; paint the reserved space as main content background. */
.hrd-shell > [ng-include*="header.html"] > #page-wrapper {
    background: var(--hrd-background);
}
.hrd-shell #page-header {
    height: var(--hrd-header-height);
    margin-bottom: 12px;
    background: linear-gradient(110deg, #ffffff 0%, #f8fbfd 52%, #eef8f8 78%, #e7f4f7 100%) !important;
    border-bottom: 1px solid #dae7ed;
    box-shadow: 0 3px 10px rgba(20, 43, 74, .035);
    font-family: var(--hrd-font);
}
.hrd-shell #header-logo {
    background: var(--hrd-surface);
    border-right: 1px solid var(--hrd-border);
}
.hrd-shell #header-logo .logo-content-big {
    background-image: url('../img/logo_blue.png');
}
.hrd-shell #header-logo .logo-content-small,
.hrd-shell #mobile-navigation .logo-content-small {
    background-image: url('../img/logo_icon_blue.png');
}
.hrd-shell #mobile-navigation .logo-content-small { left: 68px !important; width: 60px; }
/* The collapsed mark and toggle align with the 66px application header. */
.closed-sidebar .hrd-shell #header-logo { height: var(--hrd-header-height); }
.closed-sidebar .hrd-shell #header-logo .logo-content-small {
    top: 0;
    left: 6px !important;
    width: 52px;
    height: 100%;
    margin: 0;
    background-position: center;
    background-size: auto 48px !important;
}
.hrd-shell #page-header #close-sidebar {
    color: var(--hrd-text-secondary);
    background: var(--hrd-surface-subtle);
    border-radius: var(--hrd-radius-small);
}
.hrd-shell #page-header #close-sidebar:hover {
    color: var(--hrd-primary-ink);
    background: var(--hrd-primary-soft);
}
.hrd-shell #header-nav-right { display: flex; align-items: center; height: var(--hrd-header-height); margin: 0 24px 0 0; }
/* Shared routed-page title. Modal titles and descriptive page content stay local. */
.hrd-shell .hrd-header-title-source,
.hrd-shell .hrd-header-title-empty { display: none !important; }
.hrd-shell #header-nav-left.hrd-header-title-slot {
    display: flex;
    align-items: center;
    float: left;
    height: var(--hrd-header-height);
    margin: 0 24px;
}
.hrd-shell #page-header .hrd-header-page-title {
    margin: 0;
    color: var(--hrd-text-primary);
    font-size: var(--hrd-title-size);
    font-weight: var(--hrd-title-weight) !important;
    line-height: 1.3;
    text-transform: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: max(80px, calc(100vw - 740px));
}
@media (min-width: 900px) {
    .closed-sidebar .hrd-shell #page-header .hrd-header-page-title { max-width: max(80px, calc(100vw - 560px)); }
}
@media (max-width: 767px) {
    .hrd-shell #header-nav-left.hrd-header-title-slot { margin: 0 12px; }
    .hrd-shell #page-header .hrd-header-page-title {
        font-size: 16px;
        max-width: calc(100vw - 276px);
        overflow: hidden;
        text-overflow: ellipsis;
    }
}
@media (min-width: 631px) and (max-width: 899px) {
    .hrd-shell #page-header .hrd-header-page-title { max-width: max(80px, calc(100vw - 600px)); }
}
.hrd-shell #page-header .user-profile .hrd-user-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 28px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--hrd-primary-soft);
    color: var(--hrd-primary-ink);
    font-size: 13px;
    font-style: normal;
    font-weight: 600;
    line-height: 1;
}
.hrd-shell #page-header .user-account-btn { margin-top: 0; }
.hrd-shell #page-header .user-account-btn > a.user-profile {
    color: var(--hrd-text-primary);
    background: rgba(255, 255, 255, .85);
    border: 1px solid #d5e5eb !important;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(20, 43, 74, .035);
    display: flex;
    align-items: center;
    gap: 8px;
    height: 38px;
    line-height: 36px;
    margin-top: 0;
    padding: 0 12px;
    font-weight: 600 !important;
}
.hrd-shell #page-header .user-account-btn > a.user-profile:hover,
.hrd-shell #page-header .user-account-btn.open > a.user-profile {
    background: var(--hrd-surface);
    border-color: #accfd7 !important;
}
.hrd-shell #page-header .user-account-btn > a.user-profile span {
    width: auto !important;
    max-width: 250px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.hrd-shell #page-header .user-account-btn > a.user-profile .glyph-icon { width: 20px; height: 20px; line-height: 20px; color: var(--hrd-text-secondary); }
.hrd-shell #page-header .user-account-btn .dropdown-menu {
    left: auto !important;
    right: 0;
    top: calc(100% + 8px);
    border: 1px solid var(--hrd-border);
    border-radius: var(--hrd-radius-medium);
    box-shadow: var(--hrd-shadow-hover);
    color: var(--hrd-text-primary);
}
.hrd-shell #nav-toggle.collapsed span,
.hrd-shell #nav-toggle span:before,
.hrd-shell #nav-toggle span:after { background: var(--hrd-text-primary); }
.hrd-shell #page-sidebar {
    background: var(--hrd-surface);
    border-right: 1px solid var(--hrd-border);
    font-family: var(--hrd-font);
}
.hrd-shell #page-sidebar #sidebar-menu { padding: 8px 16px; }
.hrd-shell #page-sidebar #sidebar-menu li.header {
    background: transparent !important;
    color: var(--hrd-text-secondary) !important;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .07em;
    padding: 12px 10px 6px;
}
.hrd-shell #page-sidebar #sidebar-menu li a {
    color: var(--hrd-text-secondary) !important;
    border: 1px solid transparent;
    border-radius: var(--hrd-radius-small);
    font-size: 13px;
    transition: background-color var(--hrd-transition), color var(--hrd-transition);
}
.hrd-shell #page-sidebar #sidebar-menu li:hover { background: var(--hrd-surface-subtle) !important; }
.hrd-shell #page-sidebar #sidebar-menu li.active { background: var(--hrd-primary-soft) !important; }
.hrd-shell #page-sidebar #sidebar-menu li.active > a {
    color: var(--hrd-primary-ink) !important;
    font-weight: 600;
    box-shadow: inset 3px 0 var(--hrd-primary);
}
.hrd-shell #page-sidebar li a .glyph-icon,
.hrd-shell #page-sidebar ul li a .menu-icon {
    color: var(--hrd-text-secondary) !important;
    opacity: 1;
    font-size: 18px;
    animation: none;
}
.hrd-shell #page-sidebar li.active a .glyph-icon,
.hrd-shell #page-sidebar li.active a .menu-icon { color: var(--hrd-primary-ink) !important; }
.hrd-shell #page-content { background: var(--hrd-background) !important; }

/* Opt-in page primitives. No global Bootstrap button, form, table or modal reset. */
.hrd-employee-list,
.hrd-menu { color: var(--hrd-text-primary); font-family: var(--hrd-font); font-size: 13px; }
.hrd-page-heading { display: flex; align-items: center; flex-wrap: wrap; row-gap: 12px; padding: 4px 0 16px; margin-bottom: 18px; border-bottom: 1px solid var(--hrd-border); }
.hrd-page-heading > #page-title { flex: 0 0 auto; width: auto; }
.hrd-page-heading > .text-right { flex: 1; width: auto; min-width: 0; }
.hrd-employee-list #page-title { color: var(--hrd-text-primary) !important; padding-bottom: 0; }
.hrd-employee-list #page-title h2 { color: var(--hrd-text-primary); font-family: var(--hrd-font); font-size: var(--hrd-title-size); font-weight: var(--hrd-title-weight) !important; line-height: 1.3; letter-spacing: -.5px; text-transform: none; }
.hrd-employee-list #page-title p { margin: 0; }
.hrd-toolbar { display: flex; align-items: center; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.hrd-toolbar .buttonDivider { color: var(--hrd-border-strong) !important; margin: 0 2px; }
.hrd-employee-list .hrd-toolbar .btn {
    color: var(--hrd-text-secondary) !important;
    border: 1px solid var(--hrd-border);
    border-radius: var(--hrd-radius-small);
    background: var(--hrd-surface);
    padding: 8px 10px !important;
    margin: 0;
    font-size: 12px;
    line-height: 18px;
    text-decoration: none;
    transition: background-color var(--hrd-transition), border-color var(--hrd-transition);
}
.hrd-employee-list .hrd-toolbar .btn:hover { background: var(--hrd-surface-subtle); border-color: var(--hrd-border-strong); }
.hrd-employee-list .hrd-toolbar .hrd-action-danger:hover { background: var(--hrd-danger-soft); color: var(--hrd-danger-ink) !important; }
.hrd-card,
.hrd-employee-list .hrd-dashboard .panel {
    background: var(--hrd-surface);
    border: 1px solid var(--hrd-border);
    border-radius: var(--hrd-radius-medium);
    box-shadow: var(--hrd-shadow-card);
}
.hrd-list-panel > .panel-body { padding: 20px; }
.hrd-employee-list .form-control,
.hrd-form-surface .form-control {
    color: var(--hrd-text-primary);
    background-color: var(--hrd-surface);
    border: 1px solid var(--hrd-border-strong);
    border-radius: var(--hrd-radius-small);
    box-shadow: none;
    font-family: var(--hrd-font);
    font-size: 13px;
    min-height: 36px;
}
.hrd-employee-list .form-control::placeholder { color: var(--hrd-text-secondary); opacity: 1; }
.hrd-employee-list .form-control:focus,
.hrd-form-surface .form-control:focus { border-color: var(--hrd-primary-ink); box-shadow: 0 0 0 3px var(--hrd-primary-soft); }
.hrd-employee-list input[type="checkbox"],
.hrd-menu input[type="checkbox"] { accent-color: var(--hrd-primary-ink); }
.hrd-employee-list a:focus-visible,
.hrd-employee-list button:focus-visible,
.hrd-menu a:focus-visible,
.hrd-menu button:focus-visible,
.hrd-shell #page-header a:focus-visible,
.hrd-shell #page-header button:focus-visible,
.hrd-shell #page-sidebar a:focus-visible { outline: 2px solid var(--hrd-primary-ink); outline-offset: 3px; }
.hrd-list-filters { padding: 0 0 12px; }
.hrd-employee-list .hrd-dashboard-toggle { margin-bottom: 12px !important; border-radius: var(--hrd-radius-small); }
.hrd-employee-list .hrd-dashboard-toggle.btn-primary,
.hrd-menu .btn-primary { background: var(--hrd-primary-ink); border-color: var(--hrd-primary-ink); }
.hrd-filter-grid { padding: 0 !important; }
.hrd-filter-grid > .row { display: flex; flex-wrap: wrap; margin: 0 -6px; }
.hrd-filter-grid > .row > div { width: 33.333333%; padding: 0 6px; margin-bottom: 10px; }
/* Six existing fields remain in their original order; desktop gets one row. */
@media (min-width: 1200px) {
    .hrd-filter-grid > .row { flex-wrap: nowrap; margin: 0 -4px; }
    .hrd-filter-grid > .row > div { flex: 1 1 0; width: auto; min-width: 0; padding: 0 4px; margin-bottom: 0; }
    .hrd-filter-grid .form-control { font-size: 12px; padding-left: 9px; padding-right: 9px; text-overflow: ellipsis; }
    .hrd-filter-grid .select2-selection__rendered { font-size: 12px; }
    .hrd-filter-grid > .row > div:last-child { display: flex; align-items: center; gap: 6px; }
    .hrd-filter-grid > .row > div:last-child > select { flex: 1; width: auto !important; min-width: 0; }
    .hrd-filter-grid > .row > div:last-child > input[type="checkbox"] { flex: 0 0 auto; margin-top: 0 !important; }
}
.hrd-employee-list .select2-container--default .select2-selection--single,
.hrd-menu .select2-container--default .select2-selection--single {
    background: var(--hrd-surface);
    border-color: var(--hrd-border-strong);
    border-radius: var(--hrd-radius-small);
    height: 36px;
}
.hrd-employee-list .select2-container--default .select2-selection--single .select2-selection__rendered,
.hrd-menu .select2-container--default .select2-selection--single .select2-selection__rendered { color: var(--hrd-text-primary); line-height: 34px; }
.hrd-employee-list .select2-container--default .select2-selection--single .select2-selection__arrow,
.hrd-menu .select2-container--default .select2-selection--single .select2-selection__arrow { height: 34px; }
.hrd-dashboard { display: flex; flex-wrap: wrap; margin: 0 -8px; clear: both; }
.hrd-dashboard > div { padding: 0 8px; }
.hrd-employee-list .hrd-dashboard .panel { box-shadow: none; margin-bottom: 16px; }
.hrd-employee-list .hrd-dashboard .panel-heading { background: var(--hrd-surface-subtle); border-bottom: 1px solid var(--hrd-border); border-radius: 10px 10px 0 0; padding: 12px; }
.hrd-employee-list .hrd-dashboard .panel-body { padding: 12px; }
.hrd-employee-list .hrd-dashboard .example-box-wrapper { margin-bottom: 0; overflow-x: auto; }
.hrd-employee-list .hrd-dashboard .user-details > a { color: var(--hrd-text-primary); font-size: 14px; font-weight: 600; text-transform: none; }
.hrd-employee-list .hrd-dashboard .user-details .row,
.hrd-employee-list .hrd-dashboard .user-details .row span { color: var(--hrd-text-secondary); }
.hrd-employee-list .hrd-dashboard .panel-body .panel { border-color: var(--hrd-border); border-radius: var(--hrd-radius-small); }
/* Preserve Flot's dimensions and inline styles: the controller owns the plots. */
.hrd-search-bar { clear: both; padding: 12px 0; border-top: 1px solid var(--hrd-border); }
.hrd-search-control { display: flex; align-items: stretch; gap: 8px; margin: 0 !important; padding: 0 !important; }
.hrd-employee-list .hrd-table-options {
    position: static !important;
    width: auto;
    height: 36px;
    flex: 0 0 38px;
    padding: 0;
    background: var(--hrd-surface-subtle) !important;
    border: 1px solid var(--hrd-border-strong);
    border-radius: var(--hrd-radius-small);
}
.hrd-employee-list .hrd-table-options > .btn { display: block; height: 34px; line-height: 20px; padding: 7px 10px; color: var(--hrd-text-secondary) !important; }
.hrd-employee-list .hrd-search-control > .form-control { min-width: 0; padding-left: 12px; }
.hrd-table-scroll { height: auto !important; max-height: 700px; min-height: 240px; padding: 0 !important; border: 1px solid var(--hrd-border); border-radius: var(--hrd-radius-small); }
.hrd-table-scroll > div { max-width: 100%; }
.hrd-employee-list .hrd-table,
.hrd-page .hrd-table { border: 0; margin: 0; font-size: var(--hrd-table-size); }
.hrd-employee-list .hrd-table > thead > tr > td,
.hrd-employee-list .hrd-table > tbody > tr > td,
.hrd-employee-list .hrd-table > tfoot > tr > td,
.hrd-page .hrd-table > tfoot > tr > td,
.hrd-page .hrd-table > thead > tr > td,
.hrd-page .hrd-table > tbody > tr > td { border: 0; border-bottom: 1px solid var(--hrd-border); padding: 10px 12px; vertical-align: middle; }
.hrd-employee-list .hrd-table > thead > tr > td,
.hrd-page .hrd-table > thead > tr > td { background: var(--hrd-surface-subtle); color: var(--hrd-text-secondary); font-weight: 600; white-space: nowrap; }
.hrd-employee-list .hrd-table > thead a,
.hrd-page .hrd-table > thead a { color: var(--hrd-text-secondary); }
.hrd-employee-list .hrd-table > tbody,
.hrd-page .hrd-table > tbody { color: var(--hrd-text-primary) !important; }
.hrd-employee-list .hrd-table > tbody > tr > td,
.hrd-page .hrd-table > tbody > tr > td { white-space: nowrap; }
.hrd-employee-list .hrd-table > tbody > tr:nth-of-type(odd),
.hrd-page .hrd-table > tbody > tr:nth-of-type(odd) { background: var(--hrd-surface); }
.hrd-employee-list .hrd-table > tbody > tr:nth-of-type(even),
.hrd-page .hrd-table > tbody > tr:nth-of-type(even) { background: var(--hrd-surface-subtle); }
.hrd-employee-list .hrd-table > tbody > tr:hover,
.hrd-page .hrd-table > tbody > tr:hover { background: var(--hrd-accent-soft); }
.hrd-employee-list .hrd-table .btn-link,
.hrd-page .hrd-table .btn-link { color: #2164bb !important; font-size: inherit; line-height: 20px; height: auto; min-height: 0; padding: 0; white-space: nowrap; }
.hrd-employee-list .hrd-table .pagination,
.hrd-page .hrd-table .pagination { margin: 8px 0; }
.hrd-employee-list .hrd-table .pagination > li > a,
.hrd-page .hrd-table .pagination > li > a { border-color: var(--hrd-border); color: var(--hrd-text-secondary); }
.hrd-employee-list .hrd-table .pagination > .active > a,
.hrd-page .hrd-table .pagination > .active > a { background: var(--hrd-primary-ink); border-color: var(--hrd-primary-ink); color: white; }
.hrd-table-scroll > .text-center > img { max-width: 100%; height: auto !important; max-height: 300px; object-fit: contain; }

/* UI Bootstrap appends menus to body. Scope the detached element itself. */
.hrd-menu { border: 1px solid var(--hrd-border); border-radius: var(--hrd-radius-medium); box-shadow: var(--hrd-shadow-hover); max-width: calc(100vw - 24px); }
.hrd-menu > .row { margin: 0; max-width: calc(100vw - 26px); }
.hrd-menu label { color: var(--hrd-text-secondary); font-size: 12px; }
.hrd-menu #sidebar-menu { padding: 4px; }
.hrd-menu #sidebar-menu li a { height: auto; min-height: 36px; line-height: 20px; padding: 8px 12px; white-space: normal; }
.hrd-menu #sidebar-menu li a:hover { background: var(--hrd-primary-soft); color: var(--hrd-primary-ink) !important; }

@media (max-width: 1199px) {
    .hrd-page-heading > #page-title,
    .hrd-page-heading > .text-right { flex: 0 0 100%; width: 100%; }
    .hrd-toolbar { justify-content: flex-start; margin-top: 0; }
    .hrd-filter-grid > .row > div { width: 33.333333%; }
}
@media (max-width: 991px) {
    .hrd-dashboard > div { width: 100%; }
}
/* Legacy responsive-tables.css transposes scroll-columns tables below 1000px. Keep this
   operational grid and Flot legends intact inside their horizontal scroll areas. */
@media (max-width: 1000px) {
.hrd-employee-list .hrd-table,
.hrd-page .hrd-table { display: table; }
.hrd-employee-list .hrd-table > thead,
.hrd-page .hrd-table > thead { display: table-header-group; float: none; }
.hrd-employee-list .hrd-table > tbody,
.hrd-page .hrd-table > tbody { display: table-row-group; overflow: visible; white-space: normal; }
.hrd-employee-list .hrd-table > tfoot,
.hrd-page .hrd-table > tfoot { display: table-footer-group; }
.hrd-employee-list .hrd-table tr,
.hrd-page .hrd-table tr { display: table-row; }
.hrd-employee-list .hrd-table > thead > tr > td,
.hrd-employee-list .hrd-table > tbody > tr > td,
.hrd-employee-list .hrd-table > tfoot > tr > td,
.hrd-page .hrd-table > tfoot > tr > td,
.hrd-page .hrd-table > thead > tr > td,
.hrd-page .hrd-table > tbody > tr > td { display: table-cell; }
    .hrd-employee-list .hrd-dashboard .legend table { display: table; }
    .hrd-employee-list .hrd-dashboard .legend tbody { display: table-row-group; }
    .hrd-employee-list .hrd-dashboard .legend tr { display: table-row; }
    .hrd-employee-list .hrd-dashboard .legend td { display: table-cell; }
}
@media (min-width: 1200px) and (max-width: 1699px) {
    .hrd-payroll-process-detail .hrd-payroll-heading > #page-title,
    .hrd-payroll-process-detail .hrd-payroll-heading > .text-right { flex: 0 0 100%; width: 100%; }
    .hrd-payroll-process-detail .hrd-action-toolbar { justify-content: flex-start; }
}
@media (max-width: 767px) {
    .hrd-list-panel > .panel-body { padding: 12px; }
    .hrd-filter-grid > .row > div { width: 50%; }
.hrd-employee-list .hrd-table,
.hrd-page .hrd-table { min-width: 720px; }
    .hrd-employee-list #page-title { text-align: left; }
    .hrd-shell #header-nav-right { margin-right: 12px; }
    .hrd-employee-list .hrd-dashboard .user-details .row > div { margin-bottom: 4px; }
.hrd-employee-list .hrd-table tfoot .icon-box,
.hrd-page .hrd-table tfoot .icon-box { position: sticky; left: 12px; width: max-content; margin-left: 0; }
}
@media (max-width: 410px) {
    .hrd-shell #header-nav-right { float: right; margin-left: 0; }
    /* The legacy phone menu is fixed to the viewport, so percentage top would
       place it below the screen rather than below the account control. */
    .hrd-shell #page-header .user-account-btn .dropdown-menu {
        top: 74px;
        right: 12px;
        width: calc(100% - 24px);
        max-height: calc(100vh - 86px);
        overflow-y: auto;
    }
}
@media (max-width: 460px) {
    .hrd-page-heading > div,
    .hrd-list-panel > .panel-body > .row > div,
    .hrd-dashboard > div { margin-bottom: 0; }
    .hrd-filter-grid > .row > div { width: 100%; }
    .hrd-toolbar { gap: 5px; }
    .hrd-toolbar .buttonDivider { margin: 0; }
    .hrd-menu > .row > div { margin-bottom: 0; }
}
@media (prefers-reduced-motion: reduce) {
    .hrd-employee-list,
    .hrd-employee-list *,
    .hrd-shell #page-sidebar,
    .hrd-shell #page-sidebar * { animation: none !important; transition: none !important; }
}
/* Shared opt-in patterns. Keep the approved shell/list selectors above stable. */
.hrd-page { color: var(--hrd-text-primary); font: var(--hrd-body-size)/1.5 var(--hrd-font); }
.hrd-page-header { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--hrd-space-3); padding-bottom: var(--hrd-space-4); border-bottom: 1px solid var(--hrd-border); }
.hrd-page .hrd-page-title { color: var(--hrd-text-primary); font: var(--hrd-title-weight) var(--hrd-title-size)/1.3 var(--hrd-font); letter-spacing: -.5px; text-transform: none; margin: 0; }
.hrd-page-eyebrow { color: var(--hrd-text-secondary); font-size: var(--hrd-meta-size); letter-spacing: .07em; text-transform: uppercase; }
.hrd-page-actions, .hrd-action-group { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: var(--hrd-space-2); }
.hrd-action-divider { width: 1px; height: var(--hrd-space-20); background: var(--hrd-border-strong); margin: 0 var(--hrd-space-1); }
.hrd-button { display: inline-flex; align-items: center; justify-content: center; gap: var(--hrd-space-2); min-height: var(--hrd-button-height); padding: var(--hrd-space-2) var(--hrd-space-4); border: 1px solid var(--hrd-border-strong); border-radius: var(--hrd-radius-small); font: 600 var(--hrd-body-size)/1.5 var(--hrd-font); text-decoration: none; transition: background-color var(--hrd-transition), border-color var(--hrd-transition); }
.hrd-button.hrd-button-primary { color: var(--hrd-surface); background: var(--hrd-primary-ink); border-color: var(--hrd-primary-ink); }
.hrd-button.hrd-button-primary:hover { color: var(--hrd-surface); background: var(--hrd-primary-ink-hover); border-color: var(--hrd-primary-ink-hover); }
.hrd-button.hrd-button-secondary { color: var(--hrd-text-secondary); background: var(--hrd-surface); }
.hrd-button.hrd-button-secondary:hover { background: var(--hrd-surface-subtle); border-color: var(--hrd-text-muted); }
.hrd-button.hrd-button-danger { color: var(--hrd-danger-ink); background: var(--hrd-danger-soft); border-color: var(--hrd-danger); }
.hrd-button.hrd-button-danger:hover { color: var(--hrd-surface); background: var(--hrd-danger-ink); }
.hrd-button.hrd-button-icon { color: var(--hrd-text-secondary); background: transparent; border-color: transparent; width: var(--hrd-button-height); padding: var(--hrd-space-2); }
.hrd-button:disabled, .hrd-button[aria-disabled="true"] { opacity: .65; cursor: not-allowed; box-shadow: none; }
.hrd-button[aria-busy="true"] { cursor: progress; }
.hrd-button:focus-visible, .hrd-page a:focus-visible, .hrd-form input:focus-visible, .hrd-form select:focus-visible, .hrd-form textarea:focus-visible { outline: 2px solid var(--hrd-primary-ink); outline-offset: 2px; }
.hrd-card-compact { padding: var(--hrd-space-3); }
.hrd-dashboard-card, .hrd-filter-card, .hrd-form-section { padding: var(--hrd-space-4); }
.hrd-section-title, .hrd-form .hrd-section-title { color: var(--hrd-text-primary); font: var(--hrd-section-weight) var(--hrd-section-size)/1.5 var(--hrd-font); text-transform: none; margin: 0; }
.hrd-form-dialog { width: calc(100% - 48px); max-width: 1140px; margin: 24px auto; }
.hrd-modal-surface { background: var(--hrd-surface); border: 1px solid var(--hrd-border); border-radius: var(--hrd-radius-large); box-shadow: var(--hrd-shadow-hover); }
.hrd-form .hrd-page-header { padding: var(--hrd-space-5); text-align: left !important; background: var(--hrd-surface-subtle); border-radius: var(--hrd-radius-large) var(--hrd-radius-large) 0 0; }
.hrd-form .hrd-page-header:before, .hrd-form .hrd-page-header:after { display: none; }
.hrd-form-body { padding: var(--hrd-space-5); }
.hrd-form-actions { padding: var(--hrd-space-4) var(--hrd-space-5); border-top: 1px solid var(--hrd-border); background: var(--hrd-surface-subtle); border-radius: 0 0 var(--hrd-radius-large) var(--hrd-radius-large); }
.hrd-form-actions:before, .hrd-form-actions:after { display: none; }
.hrd-form-actions .btn + .btn { margin-left: 0; }
.hrd-form-grid { display: flex; flex-wrap: wrap; margin: 0 -8px; }
.hrd-form-grid > [class*="col-md-"] { min-width: 0; padding: 0 var(--hrd-space-2); margin-bottom: 0; float: none; }
.hrd-form-grid > .col-md-3, .hrd-form-grid > .col-md-4 { width: 50%; }
.hrd-form-grid > .col-md-6 { width: 50%; }
.hrd-form-grid > .col-md-12 { width: 100%; }
.hrd-form .hrd-form-group { margin-bottom: var(--hrd-space-2); }
.hrd-form-group > label, .hrd-field-label { display: block; color: var(--hrd-text-secondary); font-size: var(--hrd-label-size); font-weight: 600; line-height: 1.5; margin-bottom: var(--hrd-space-1); overflow-wrap: anywhere; }
.hrd-required { color: var(--hrd-danger-ink); }
.hrd-input, .hrd-form .form-control { display: block; width: 100%; min-width: 0; height: var(--hrd-control-height); padding: var(--hrd-space-2) var(--hrd-space-3); background: var(--hrd-surface); color: var(--hrd-text-primary); border: 1px solid var(--hrd-border-strong); border-radius: var(--hrd-radius-small); box-shadow: none; font: var(--hrd-body-size)/1.5 var(--hrd-font); }
.hrd-input::placeholder { color: var(--hrd-text-secondary); opacity: 1; }
.hrd-input:focus { border-color: var(--hrd-primary-ink); box-shadow: 0 0 0 3px var(--hrd-primary-soft); }
.hrd-input:disabled, .hrd-input[readonly] { color: var(--hrd-disabled-text); background: var(--hrd-disabled-background); opacity: 1; }
.hrd-input:disabled { cursor: not-allowed; }
textarea.hrd-input { height: auto; min-height: 88px; resize: vertical; }
.hrd-help-text, .hrd-field-error { display: block; font-size: var(--hrd-support-size); line-height: 18px; margin-top: var(--hrd-space-1); }
.hrd-help-text { color: var(--hrd-text-secondary); }
.hrd-field-error { min-height: 18px; color: var(--hrd-danger-ink); }
.hrd-form .form-control.hrd-input-invalid, .hrd-form .select2-selection.hrd-input-invalid { border-color: var(--hrd-danger); }
.hrd-validation-summary { background: var(--hrd-danger-soft); border: 1px solid var(--hrd-danger); border-radius: var(--hrd-radius-small); color: var(--hrd-danger-ink); padding: var(--hrd-space-3); }
.hrd-form input[type="checkbox"], .hrd-form input[type="radio"], .hrd-checkbox, .hrd-radio { accent-color: var(--hrd-primary-ink); }
.hrd-form .checkbox label, .hrd-form .radio label { color: var(--hrd-text-primary); line-height: 1.5; overflow-wrap: anywhere; }
.hrd-form .nav-tabs { display: flex; flex-wrap: wrap; gap: var(--hrd-space-1); border-bottom: 1px solid var(--hrd-border); margin-bottom: var(--hrd-space-20); }
.hrd-form .nav-tabs:before, .hrd-form .nav-tabs:after { display: none; }
.hrd-form .nav-tabs > li { float: none; }
.hrd-form .nav-tabs > li > a { color: var(--hrd-text-secondary); font: 600 var(--hrd-body-size)/1.5 var(--hrd-font); padding: var(--hrd-space-3); background: transparent; border: 0; border-bottom: 2px solid transparent; border-radius: 0; margin: 0; }
.hrd-form .nav-tabs > li.active > a { color: var(--hrd-primary-ink); background: var(--hrd-primary-soft); border-bottom-color: var(--hrd-primary-ink); }
.hrd-form .tab-content { padding: 0; border: 0; background: transparent; }
.hrd-form .select2-container { display: block; width: 100% !important; min-width: 0; }
.hrd-form .select2-selection--single { height: var(--hrd-control-height); border-color: var(--hrd-border-strong); border-radius: var(--hrd-radius-small); }
.hrd-form .select2-selection--single .select2-selection__rendered { color: var(--hrd-text-primary); line-height: 38px; padding-left: var(--hrd-space-3); }
.hrd-form .select2-selection--single .select2-selection__arrow { height: 38px; }
.hrd-form .select2-container--focus .select2-selection { outline: 2px solid var(--hrd-primary-ink); outline-offset: 2px; }
.hrd-form .dropdown-menu { max-width: calc(100vw - 48px); }
.hrd-form .dropdown-menu > li > a { white-space: normal; overflow-wrap: anywhere; }
.hrd-form hr { border-color: var(--hrd-border); }
.hrd-table-card { overflow-x: auto; }
.hrd-table-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: var(--hrd-space-3); padding: var(--hrd-space-3) 0; }
.hrd-status-badge { display: inline-block; padding: var(--hrd-space-1) var(--hrd-space-2); border-radius: var(--hrd-radius-small); background: var(--hrd-primary-soft); color: var(--hrd-primary-ink); font-size: var(--hrd-meta-size); font-weight: 600; }
.hrd-empty-state, .hrd-loading-state { text-align: center; color: var(--hrd-text-secondary); padding: var(--hrd-space-32); }
.hrd-loading-state { cursor: progress; }
/* One state surface for every data table, outside data-dependent wrappers. */
hrd-table-state { display: block; clear: both; }
.hrd-table-body-hidden,
.hrd-table-legacy-state { display: none !important; }
.hrd-table-state-panel {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    min-height: 240px;
    margin: 0 0 16px;
    padding: 32px 16px;
    border: 1px solid var(--hrd-border);
    border-radius: var(--hrd-radius-large);
    background: var(--hrd-surface-subtle);
    color: var(--hrd-text-secondary);
    text-align: center;
    font-family: var(--hrd-font);
}
.hrd-table-state-title { color: var(--hrd-text-primary); font-size: 15px; font-weight: 600; line-height: 1.5; }
.hrd-table-state-description { margin: 0; font-size: 13px; line-height: 1.5; }
.hrd-table-state-empty-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    border-radius: 16px;
    background: var(--hrd-surface);
    color: var(--hrd-text-secondary);
    font-size: 28px;
}
.hrd-table-state-mark { position: relative; display: grid; place-items: center; width: 88px; height: 88px; }
.hrd-table-state-logo { width: 42px; height: 52px; object-fit: contain; animation: hrd-table-logo-breathe 1.8s ease-in-out infinite; }
.hrd-table-state-ring {
    position: absolute;
    inset: 0;
    border: 2px solid var(--hrd-border);
    border-top-color: var(--hrd-primary-ink);
    border-right-color: var(--hrd-primary-soft);
    border-radius: 50%;
    animation: hrd-table-ring-turn 1.2s linear infinite;
}
@keyframes hrd-table-ring-turn { to { transform: rotate(360deg); } }
@keyframes hrd-table-logo-breathe { 0%, 100% { opacity: .65; transform: scale(.96); } 50% { opacity: 1; transform: scale(1); } }
@media (prefers-reduced-motion: reduce) {
    .hrd-table-state-logo, .hrd-table-state-ring { animation: none; }
}
.hrd-pagination { display: flex; flex-wrap: wrap; gap: var(--hrd-space-1); }
.hrd-pagination > li > a { color: var(--hrd-text-secondary); border-color: var(--hrd-border); }
.hrd-pagination > .active > a { color: var(--hrd-surface); background: var(--hrd-primary-ink); border-color: var(--hrd-primary-ink); }
.hrd-search-field { min-width: 0; flex: 1; }
@media (max-width: 991px) {
    .hrd-form-grid > .col-md-3, .hrd-form-grid > .col-md-4, .hrd-form-grid > .col-md-6 { width: 50%; }
}
@media (max-width: 600px) {
    .hrd-form-dialog { width: calc(100% - 24px); margin: 12px auto; }
    .hrd-form .hrd-page-header, .hrd-form-body, .hrd-form-actions { padding: var(--hrd-space-4); }
    .hrd-form-grid > .col-md-3, .hrd-form-grid > .col-md-4, .hrd-form-grid > .col-md-6 { width: 100%; }
    .hrd-form .nav-tabs > li > a { padding: var(--hrd-space-2); font-size: var(--hrd-support-size); }
}

/* Attendance operational page pilot. All rules are opt-in and CSS-only per row. */
.hrd-attendance-page { color: var(--hrd-text-primary); font-family: var(--hrd-font); font-size: var(--hrd-body-size); }
.hrd-attendance-heading > #page-title { flex: 0 0 auto; width: auto; }
.hrd-attendance-heading > .text-right { flex: 1; width: auto; min-width: 0; }
.hrd-attendance-page #page-title { color: var(--hrd-text-primary) !important; padding-bottom: 0; }
.hrd-attendance-page #page-title h2 { color: var(--hrd-text-primary); font-family: var(--hrd-font); font-size: var(--hrd-title-size); font-weight: var(--hrd-title-weight) !important; line-height: 1.3; letter-spacing: -.5px; text-transform: none; }
.hrd-attendance-toolbar { gap: 6px; }
.hrd-attendance-toolbar .buttonDivider { color: var(--hrd-border-strong) !important; margin: 0 2px; }
.hrd-attendance-toolbar .hrd-button { min-height: 36px; height: 36px; padding: 7px 10px; font-size: var(--hrd-support-size); line-height: 18px; }
.hrd-attendance-toolbar .hrd-button-icon { width: 38px; }
.hrd-attendance-card { margin-bottom: var(--hrd-space-4); }
.hrd-attendance-card > .panel-body { padding: var(--hrd-space-20); }
.hrd-attendance-page .main-box-header { padding: 0; }
.hrd-attendance-filter-block { clear: both; padding: 0 !important; margin-bottom: var(--hrd-space-3) !important; }
.hrd-operational-filters { display: grid; grid-template-columns: 2.3fr 1.1fr 1.4fr 1.4fr .9fr .9fr 1.1fr 1.1fr; gap: var(--hrd-space-2); margin: 0; }
.hrd-operational-filters:before, .hrd-operational-filters:after { display: none; content: none; }
.hrd-operational-filters > [class*="col-"] { float: none; width: auto; min-width: 0; padding: 0; margin: 0; }
.hrd-operational-filters .hrd-field-label { margin-bottom: var(--hrd-space-1); white-space: nowrap; }
.hrd-attendance-page .hrd-operational-filters .form-control { height: var(--hrd-control-compact-height); min-height: var(--hrd-control-compact-height); padding: 7px 9px; color: var(--hrd-text-primary); background: var(--hrd-surface); border: 1px solid var(--hrd-border-strong); border-radius: var(--hrd-radius-small); box-shadow: none; font: var(--hrd-body-size)/20px var(--hrd-font); min-width: 0; }
.hrd-attendance-page .hrd-operational-filters .form-control:focus { border-color: var(--hrd-primary-ink); box-shadow: 0 0 0 3px var(--hrd-primary-soft); }
.hrd-operational-filters .input-group-addon { height: var(--hrd-control-compact-height); color: var(--hrd-text-secondary); border-color: var(--hrd-border-strong); border-radius: 0 var(--hrd-radius-small) var(--hrd-radius-small) 0; }
.hrd-filter-chip { display: inline-flex; align-items: center; gap: var(--hrd-space-1); min-height: 24px; margin-bottom: var(--hrd-space-2); padding: var(--hrd-space-1) var(--hrd-space-2); border-radius: var(--hrd-radius-small); font-size: var(--hrd-meta-size); font-weight: 600; line-height: 16px; }
.hrd-attendance-dashboard { display: flex; margin: 0 -8px var(--hrd-space-3); clear: both; animation: none; }
.hrd-attendance-dashboard > div { padding: 0 8px; }
.hrd-attendance-dashboard .panel { border: 1px solid var(--hrd-border); border-radius: var(--hrd-radius-medium); box-shadow: none; }
.hrd-attendance-dashboard .panel-heading { background: var(--hrd-surface-subtle); border-bottom: 1px solid var(--hrd-border); border-radius: var(--hrd-radius-medium) var(--hrd-radius-medium) 0 0; padding: var(--hrd-space-3); }
.hrd-attendance-dashboard .panel-body { padding: var(--hrd-space-3); }
.hrd-attendance-dashboard #donutChartAttendanceCode, .hrd-attendance-dashboard #donutChartAttendanceStatus { height: 240px !important; }
.hrd-attendance-dashboard .fc-view-container { max-height: 240px; overflow: auto; }
.hrd-attendance-table-toolbar { display: flex; align-items: stretch; gap: var(--hrd-space-2); margin: 0 0 var(--hrd-space-3) !important; padding: 0 !important; }
.hrd-attendance-table-toolbar > .btn-group { position: static !important; top: auto !important; left: auto !important; flex: 0 0 38px; width: 38px; height: 36px; padding: 0; background: var(--hrd-surface-subtle) !important; border: 1px solid var(--hrd-border-strong); border-radius: var(--hrd-radius-small); }
.hrd-attendance-table-toolbar > .btn-group > .btn { display: block; height: 34px; padding: 7px 10px; color: var(--hrd-text-secondary) !important; }
.hrd-attendance-table-toolbar > .hrd-search-field { flex: 1; min-width: 0; height: 36px; border-color: var(--hrd-border-strong); border-radius: var(--hrd-radius-small); box-shadow: none; }
.hrd-operation-table-scroll { height: 700px !important; max-width: 100%; padding: 0 !important; overflow: auto; border: 1px solid var(--hrd-border); border-radius: var(--hrd-radius-small); }
.hrd-attendance-page .hrd-operation-table { min-width: 1880px; table-layout: auto; margin: 0; }
.hrd-attendance-page .hrd-operation-table > thead > tr > td { position: sticky; top: 0; z-index: 2; background: var(--hrd-surface-subtle); }
.hrd-attendance-page .hrd-operation-table > thead > tr > td,
.hrd-attendance-page .hrd-operation-table > tbody > tr > td,
.hrd-attendance-page .hrd-operation-table > tfoot > tr > td { padding: 8px 10px; }
.hrd-attendance-page .hrd-operation-table > tbody > tr:nth-of-type(even) { background: var(--hrd-surface); }
.hrd-attendance-page .hrd-operation-table > tbody > tr:hover { background: var(--hrd-accent-soft); }
.hrd-attendance-page .hrd-operation-table input[type="checkbox"] { margin: 0; vertical-align: middle; accent-color: var(--hrd-primary-ink); }
.hrd-attendance-page .hrd-operation-table input[type="checkbox"]:disabled { opacity: 1; }
.hrd-attendance-page .hrd-operation-table tbody tr:has(.cbChild:checked) { background: var(--hrd-warning-soft); box-shadow: inset 3px 0 var(--hrd-warning); }
.hrd-cell-truncate { display: block; max-width: 190px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hrd-status-neutral { color: var(--hrd-text-secondary); background: var(--hrd-disabled-background); }
.hrd-attendance-page .hrd-empty-state { padding: var(--hrd-space-32) !important; color: var(--hrd-text-secondary); }
.hrd-attendance-page .hrd-empty-state img { width: 200px !important; height: 200px !important; max-width: 100%; object-fit: contain; }
.hrd-attendance-page .hrd-loading-state { padding-top: 64px !important; color: var(--hrd-text-secondary); }
.hrd-attendance-modal .uib-timepicker input { height: var(--hrd-control-height); border: 1px solid var(--hrd-border-strong); border-radius: var(--hrd-radius-small); box-shadow: none; color: var(--hrd-text-primary); }
.hrd-attendance-modal .uib-timepicker button { color: var(--hrd-primary-ink); }
.hrd-attendance-modal .hrd-operation-table { min-width: 620px; margin: 0; }
@media (max-width: 1350px) {
    .hrd-operational-filters { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 1199px) {
    .hrd-attendance-heading > #page-title, .hrd-attendance-heading > .text-right { flex: 0 0 100%; width: 100%; }
    .hrd-attendance-toolbar { justify-content: flex-start; }
    .hrd-attendance-dashboard { display: block; }
    .hrd-attendance-dashboard > div { width: 100%; }
}

/* Cross-page list consistency: shared by Employee List and Attendances. */
.hrd-action-toolbar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: nowrap;
    gap: var(--hrd-space-2);
}
.hrd-action-toolbar > .btn-group { display: inline-flex; align-items: center; flex: 0 0 auto; }
.hrd-page-heading .hrd-action-toolbar .hrd-action-button,
.hrd-admin-page .hrd-action-toolbar .hrd-action-button,
.hrd-admin-fragment .hrd-action-toolbar .hrd-action-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    height: var(--hrd-button-height);
    min-height: var(--hrd-button-height);
    padding: 0 var(--hrd-space-4) !important;
    margin: 0;
    color: var(--hrd-text-secondary) !important;
    background: var(--hrd-surface);
    border: 1px solid var(--hrd-border);
    border-radius: 8px;
    font: 600 var(--hrd-body-size)/1 var(--hrd-font);
    text-decoration: none;
    white-space: nowrap;
    transition: background-color var(--hrd-transition), border-color var(--hrd-transition), color var(--hrd-transition);
}
.hrd-action-toolbar .hrd-action-button i,
.hrd-action-toolbar .hrd-action-button svg { flex: 0 0 auto; font-size: 15px; }
.hrd-action-toolbar .hrd-action-button:hover { color: var(--hrd-text-primary) !important; background: var(--hrd-surface-subtle); border-color: var(--hrd-border-strong); }
.hrd-action-toolbar .hrd-action-danger { color: var(--hrd-text-secondary) !important; background: var(--hrd-surface); border-color: var(--hrd-border); }
.hrd-action-toolbar .hrd-action-danger:hover { color: var(--hrd-danger-ink) !important; background: var(--hrd-danger-soft); border-color: var(--hrd-danger); }
.hrd-action-toolbar .hrd-action-button:focus-visible { outline: 2px solid var(--hrd-primary-ink); outline-offset: 2px; }
.hrd-action-toolbar .hrd-action-button.disabled,
.hrd-action-toolbar .hrd-action-button[disabled],
.hrd-action-toolbar .hrd-action-button[aria-disabled="true"] { color: var(--hrd-disabled-text) !important; background: var(--hrd-disabled-background); border-color: var(--hrd-border); opacity: 1; cursor: not-allowed; }
.hrd-action-toolbar .hrd-action-button-icon { flex: 0 0 var(--hrd-button-height); width: var(--hrd-button-height); padding: 0 !important; }
.hrd-action-toolbar .hrd-action-divider { display: block; flex: 0 0 1px; width: 1px; height: var(--hrd-space-20); margin: 0 var(--hrd-space-1); overflow: hidden; color: transparent !important; background: var(--hrd-border-strong); font-size: 0; }

.hrd-dashboard-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: var(--hrd-button-height);
    height: var(--hrd-button-height);
    min-height: var(--hrd-button-height);
    margin-bottom: var(--hrd-space-3) !important;
    padding: 0 !important;
    color: var(--hrd-text-secondary) !important;
    background: var(--hrd-surface) !important;
    border: 1px solid var(--hrd-border-strong) !important;
    border-radius: 8px !important;
    box-shadow: none;
}
.hrd-dashboard-toggle.btn-primary,
.hrd-dashboard-toggle[aria-expanded="true"] { color: var(--hrd-surface) !important; background: var(--hrd-primary-ink) !important; border-color: var(--hrd-primary-ink) !important; }
.hrd-dashboard-toggle:hover { border-color: var(--hrd-primary-ink) !important; }
.hrd-dashboard-toggle:focus-visible { outline: 2px solid var(--hrd-primary-ink); outline-offset: 2px; }

.hrd-filter-grid > .row:before,
.hrd-filter-grid > .row:after { display: none; content: none; }
.hrd-filter-grid > .row > div { display: flex; flex-direction: column; align-items: stretch; }
.hrd-filter-grid .hrd-field-label { margin-bottom: var(--hrd-space-1); white-space: nowrap; }
.hrd-filter-grid .hrd-filter-inline { display: flex; align-items: center; gap: 6px; min-width: 0; }
.hrd-filter-grid .hrd-filter-inline > select { flex: 1; width: auto !important; min-width: 0; }
.hrd-filter-grid .hrd-filter-inline > input[type="checkbox"] { flex: 0 0 auto; margin: 0 !important; }
@media (min-width: 1200px) {
    .hrd-filter-grid > .row > div:last-child { flex-direction: column; align-items: stretch; gap: 0; }
}

.hrd-table-tools { clear: both; padding: var(--hrd-space-3) 0; border-top: 1px solid var(--hrd-border); }
.hrd-table-tools .hrd-table-toolbar,
.hrd-admin-page .hrd-table-tools > .input-group { display: flex; align-items: stretch; gap: var(--hrd-space-2); margin: 0 !important; padding: 0 !important; }
.hrd-table-tools .hrd-table-options {
    position: static !important;
    top: auto !important;
    left: auto !important;
    flex: 0 0 38px;
    width: 38px;
    height: var(--hrd-control-compact-height);
    padding: 0;
    background: var(--hrd-surface-subtle) !important;
    border: 1px solid var(--hrd-border-strong);
    border-radius: var(--hrd-radius-small);
}
.hrd-table-tools .hrd-table-options > .btn { display: flex; align-items: center; justify-content: center; width: 100%; height: 34px; padding: 0; color: var(--hrd-text-secondary) !important; }
.hrd-table-tools .hrd-table-toolbar > span.input-group-addon { position: static !important; display: flex; align-items: center; justify-content: center; flex: 0 0 38px; width: 38px; height: var(--hrd-control-compact-height); margin: 0; padding: 0; color: var(--hrd-text-secondary); background: var(--hrd-surface-subtle) !important; border: 1px solid var(--hrd-border-strong); border-radius: var(--hrd-radius-small); }
.hrd-table-tools .hrd-search-field,
.hrd-table-tools .hrd-search-control > .form-control { flex: 1; min-width: 0; height: var(--hrd-control-compact-height); border-color: var(--hrd-border-strong); border-radius: var(--hrd-radius-small); box-shadow: none; }

@media (max-width: 1199px) {
    .hrd-action-toolbar { justify-content: flex-start; flex-wrap: wrap; }
}

/* Shared table shell: toolbar and pagination stay outside the scrolling viewport. */
.hrd-table-shell { clear: both; min-width: 0; }
.hrd-table-shell .hrd-search-bar { margin: 0; }
.hrd-table-shell .hrd-table-viewport {
    position: relative;
    isolation: isolate;
    width: 100%;
    max-width: 100%;
    padding: 0 !important;
    overflow: auto;
    background: var(--hrd-surface);
    border: 1px solid var(--hrd-border);
    border-radius: var(--hrd-radius-small) var(--hrd-radius-small) 0 0;
}
.hrd-table-shell .hrd-table-viewport > div { max-width: none; overflow: visible !important; }
.hrd-table-shell .hrd-table-viewport .hrd-table {
    border-collapse: separate;
    border-spacing: 0;
}
.hrd-table-shell .hrd-table-viewport .hrd-table > thead {
    position: static;
    z-index: auto;
}
.hrd-table-shell .hrd-table-viewport .hrd-table > tbody > tr > th,
.hrd-table-shell .hrd-table-viewport .hrd-table > tbody > tr > td {
    position: relative;
    z-index: 0 !important;
}
.hrd-table-shell .hrd-table-viewport .hrd-table > thead > tr > th,
.hrd-table-shell .hrd-table-viewport .hrd-table > thead > tr > td {
    position: sticky;
    top: 0;
    z-index: 10 !important;
    isolation: isolate;
    opacity: 1;
    background-color: var(--hrd-surface-subtle) !important;
    background-image: none !important;
    background-clip: border-box;
    box-shadow: inset 0 -1px var(--hrd-border);
}
.hrd-table-shell .hrd-pagination-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 52px;
    padding: var(--hrd-space-2) var(--hrd-space-4);
    background: var(--hrd-surface-subtle);
    border: 1px solid var(--hrd-border);
    border-top: 0;
    border-radius: 0 0 var(--hrd-radius-small) var(--hrd-radius-small);
}
.hrd-table-shell .hrd-pagination-footer.ng-hide { display: none; }
.hrd-table-shell .hrd-table-viewport:has(+ .hrd-pagination-footer.ng-hide) { border-radius: var(--hrd-radius-small); }
.hrd-table-shell .hrd-pagination-footer .icon-box { position: static; width: auto; margin: 0; }
.hrd-table-shell .hrd-pagination-footer.icon-box { position: static; width: auto; }
.hrd-table-shell .hrd-pagination-footer .pagination,
.hrd-table-shell .hrd-pagination-footer .hrd-pagination { margin: 0; }
.hrd-table-tools .hrd-search-field,
.hrd-table-tools .hrd-search-control > .form-control { padding: 7px var(--hrd-space-3) !important; }

/* Reusable semantic statuses. Text remains the source of truth for workflow state. */
.hrd-status-success { color: #116b57; background: var(--hrd-success-soft); }
.hrd-status-warning { color: #85530e; background: var(--hrd-warning-soft); }
.hrd-status-danger { color: var(--hrd-danger-ink); background: var(--hrd-danger-soft); }

/* Payroll transactional workflow pilot. Existing actions and calculations opt in here. */
.hrd-payroll-page { color: var(--hrd-text-primary); font-family: var(--hrd-font); }
.hrd-payroll-heading > #page-title { flex: 0 0 auto; width: auto; padding-bottom: 0; }
.hrd-payroll-heading > .text-right { flex: 1; width: auto; min-width: 0; }
.hrd-payroll-page #page-title h2 {
    margin: 0;
    color: var(--hrd-text-primary);
    font-family: var(--hrd-font);
    font-size: var(--hrd-title-size);
    /* Legacy heading weight is important; mirror the approved Employee title override. */
    font-weight: var(--hrd-title-weight) !important;
    line-height: 1.3;
    text-transform: none;
}
.hrd-payroll-page .hrd-toolbar { gap: var(--hrd-space-2); }
.hrd-payroll-page .hrd-list-panel {
    overflow: visible;
    background: var(--hrd-surface);
    border: 1px solid var(--hrd-border);
    border-radius: var(--hrd-radius-medium);
    box-shadow: var(--hrd-shadow-card);
}
.hrd-payroll-page .hrd-menu { max-height: calc(100vh - 96px); overflow-y: auto; }
.hrd-payroll-page .hrd-payroll-dashboard { margin-bottom: var(--hrd-space-4); }
.hrd-payroll-page .hrd-payroll-dashboard > .main-box-header { padding: 0; }
.hrd-payroll-page .hrd-payroll-dashboard-card {
    margin-bottom: var(--hrd-space-4);
    overflow: hidden;
    background: var(--hrd-surface);
    border: 1px solid var(--hrd-border);
    border-radius: var(--hrd-radius-medium);
    box-shadow: none;
}
.hrd-payroll-page .hrd-payroll-dashboard-card .panel-body { padding: var(--hrd-space-4); }
.hrd-payroll-page .hrd-payroll-dashboard-card .title-hero {
    color: var(--hrd-text-primary);
    font: var(--hrd-section-weight) var(--hrd-section-size)/1.5 var(--hrd-font);
    text-transform: none;
}
.hrd-payroll-page .hrd-table-tools { border-top: 0; }
.hrd-payroll-page .hrd-payroll-table-viewport { min-height: 240px; }
.hrd-payroll-process-list .hrd-payroll-table-viewport { height: auto !important; max-height: 700px; }
.hrd-payroll-page .hrd-payroll-table { min-width: 980px; table-layout: auto; }
.hrd-payroll-process-detail .hrd-payroll-table { min-width: 1460px; }
.hrd-payroll-page .hrd-payroll-table input[type="checkbox"] { margin: 0; vertical-align: middle; accent-color: var(--hrd-primary-ink); }
.hrd-payroll-page .hrd-row-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    color: var(--hrd-text-secondary);
    border-radius: var(--hrd-radius-small);
    cursor: pointer;
}
.hrd-payroll-page .hrd-row-action:hover { color: var(--hrd-primary-ink); background: var(--hrd-primary-soft); }
.hrd-payroll-page .hrd-row-action:focus-visible { outline: 2px solid var(--hrd-primary-ink); outline-offset: 2px; }
.hrd-process-summary {
    display: grid;
    grid-template-columns: 1.35fr 1.35fr 1fr .8fr 1fr;
    gap: 0;
    margin-bottom: var(--hrd-space-4);
    overflow: hidden;
}
.hrd-process-summary-item {
    min-width: 0;
    padding: var(--hrd-space-3) var(--hrd-space-4);
    border-right: 1px solid var(--hrd-border);
}
.hrd-process-summary-item:last-child { border-right: 0; }
.hrd-process-summary-item > strong {
    display: block;
    overflow: hidden;
    color: var(--hrd-text-primary);
    font-size: var(--hrd-body-size);
    text-overflow: ellipsis;
    white-space: nowrap;
}
.hrd-process-summary-label {
    display: block;
    margin-bottom: var(--hrd-space-1);
    color: var(--hrd-text-secondary);
    font-size: var(--hrd-meta-size);
    font-weight: 600;
    letter-spacing: .04em;
    text-transform: uppercase;
}
.hrd-payroll-process-detail .hrd-payroll-metric .tile-box {
    min-height: 104px;
    margin-bottom: var(--hrd-space-4);
    overflow: hidden;
    box-shadow: none;
}
.hrd-payroll-process-detail .hrd-payroll-metric .tile-header {
    min-height: 42px;
    padding: var(--hrd-space-3) var(--hrd-space-4);
    color: var(--hrd-text-secondary);
    background: var(--hrd-surface-subtle);
    border-bottom: 1px solid var(--hrd-border);
    font-size: var(--hrd-label-size);
    font-weight: 600;
    line-height: 18px;
    text-transform: none;
}
.hrd-payroll-process-detail .hrd-payroll-metric .tile-content-wrapper { padding: var(--hrd-space-3) var(--hrd-space-4); }
.hrd-payroll-process-detail .hrd-payroll-metric .tile-content {
    color: var(--hrd-text-primary);
    font-size: 20px;
    font-weight: 600;
    line-height: 28px;
}
.hrd-payroll-modal { color: var(--hrd-text-primary); font-family: var(--hrd-font); }
.hrd-payroll-modal .modal-title { color: var(--hrd-text-primary); font: var(--hrd-section-weight) 18px/1.4 var(--hrd-font); }
.hrd-payroll-modal .hrd-page-header .close { order: 1; margin-left: auto; color: var(--hrd-text-secondary); opacity: 1; }
.hrd-payroll-modal .hrd-form-actions { justify-content: flex-end; }
.hrd-confirmation { color: var(--hrd-text-primary); font-family: var(--hrd-font); border: 1px solid var(--hrd-border); border-radius: var(--hrd-radius-large); box-shadow: var(--hrd-shadow-hover); }
.hrd-confirmation h2 { color: var(--hrd-text-primary); font-size: var(--hrd-section-size); }
.hrd-confirmation button { min-height: var(--hrd-button-height); border-radius: var(--hrd-radius-small); font-size: var(--hrd-body-size); }
.hrd-confirmation button.cancel { color: var(--hrd-text-secondary); background: var(--hrd-surface-subtle); border: 1px solid var(--hrd-border-strong); }
.hrd-confirmation button:focus-visible { outline: 2px solid var(--hrd-primary-ink); outline-offset: 2px; }

/* The legacy dropdown stylesheet uses !important positioning layers. Only this
   employee popup overrides them, outside grid/animation stacking contexts. */
.hrd-employee-suggestions.dropdown-menu {
    position: fixed;
    z-index: var(--hrd-suggestions-layer, 1060) !important;
    top: var(--hrd-suggestions-top) !important;
    left: var(--hrd-suggestions-left) !important;
    width: var(--hrd-suggestions-width);
    min-width: 0;
    max-width: calc(100vw - 24px);
    max-height: var(--hrd-suggestions-height, 240px);
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    margin: 0;
    padding: 4px 0;
    border: 1px solid var(--hrd-border-strong);
    border-radius: var(--hrd-radius-small);
    background: var(--hrd-surface);
    box-shadow: var(--hrd-shadow-hover);
    color: var(--hrd-text-primary);
    font: var(--hrd-body-size)/1.5 var(--hrd-font);
}
.hrd-employee-suggestions.dropdown-menu > li { background: var(--hrd-surface); }
.hrd-employee-suggestions.dropdown-menu > li > a,
.hrd-employee-suggestions.dropdown-menu > li > div > a { display: block; padding: 8px 12px; color: var(--hrd-text-primary); white-space: normal; overflow-wrap: anywhere; }
.hrd-employee-suggestions.dropdown-menu > li.active > a,
.hrd-employee-suggestions.dropdown-menu > li.active > div > a { color: var(--hrd-primary-ink); background: var(--hrd-primary-soft); }
/* Remaining web-admin pages reuse the baseline components without changing the shell. */
.hrd-admin-page #page-title h2 { color: var(--hrd-text-primary); font: var(--hrd-title-weight) var(--hrd-title-size)/1.3 var(--hrd-font); font-weight: var(--hrd-title-weight) !important; text-transform: none; margin: 0; }
.hrd-admin-heading > #page-title { padding-bottom: 0; }
.hrd-admin-heading #page-title p { margin: 0; }
.hrd-admin-heading .hrd-action-toolbar { justify-content: flex-end; }
.hrd-admin-heading > .hrd-action-toolbar { margin-left: auto; }
.hrd-admin-page .hrd-table-tools { float: none; width: 100%; }
.hrd-admin-page .hrd-table-toolbar { margin-left: 0; margin-right: 0; }
.hrd-admin-page .hrd-table-viewport { max-height: 700px; }
.hrd-table-shell.table-responsive:has(> .hrd-table-viewport),
.hrd-table-shell.table-responsive:has(> .hrd-table-content) { overflow: visible; height: auto !important; }
.hrd-table-shell.table-responsive .hrd-table-viewport { max-height: var(--hrd-viewport-height, 700px); }
.hrd-admin-page .hrd-table-viewport img[src="img/no-data.jpg"] { width: 200px !important; height: 200px !important; object-fit: contain; }
.hrd-admin-filters { display: flex; align-items: flex-end; flex-wrap: wrap; gap: 12px; margin-bottom: 16px; }
.hrd-admin-filters:before, .hrd-admin-filters:after { display: none; }
.hrd-admin-filters > .hrd-filter-field { flex: 1 1 170px; min-width: 0; width: auto; }
.hrd-admin-filters > .hrd-filter-spacer { display: none; }
/* Compact result filters share Employee/Attendance control density. */
.hrd-payroll-results-page .hrd-payroll-results-filter-block { padding: 0 !important; }
.hrd-payroll-results-filters {
    display: grid;
    grid-template-columns: minmax(180px, 2.5fr) minmax(140px, 1.5fr) repeat(2, minmax(70px, .65fr));
    gap: var(--hrd-space-2);
    margin: 0 0 var(--hrd-space-4);
}
.hrd-payroll-results-filters--extended {
    grid-template-columns: minmax(200px, 2fr) minmax(140px, 1.4fr) repeat(2, minmax(60px, .6fr)) repeat(2, minmax(120px, 1.2fr));
}
.hrd-payroll-results-filters > .hrd-filter-field { padding: 0; margin: 0; }
.hrd-payroll-results-page .hrd-payroll-results-filters .form-control {
    height: var(--hrd-control-compact-height);
    min-height: var(--hrd-control-compact-height);
    padding: 7px 9px;
}
.hrd-payroll-results-filters .input-group-addon {
    height: var(--hrd-control-compact-height);
    color: var(--hrd-text-secondary);
    border-color: var(--hrd-border-strong);
    border-radius: 0 var(--hrd-radius-small) var(--hrd-radius-small) 0;
}
@media (max-width: 1199px) {
    .hrd-payroll-results-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
    .hrd-payroll-results-filters { grid-template-columns: minmax(0, 1fr); }
}
.hrd-admin-filters .hrd-filter-label { display: block; margin-bottom: 4px; color: var(--hrd-text-secondary); font-size: 12px; font-weight: 600; }
.hrd-admin-modal .hrd-page-header, .hrd-admin-modal .hrd-form-body, .hrd-admin-modal .hrd-form-actions { padding: 15px; }
.hrd-admin-modal .hrd-page-header > .close { order: 1; margin-left: auto; color: var(--hrd-text-secondary); opacity: 1; }
.hrd-admin-modal .hrd-page-header > h3 { margin: 0; color: var(--hrd-text-primary); font-size: 16px; font-weight: 600; }
.hrd-admin-modal .hrd-field-error:empty { display: none; }
.hrd-admin-modal textarea[rows] { height: auto; }
.hrd-admin-modal .hrd-table { width: 100%; color: var(--hrd-text-primary); }
.hrd-admin-modal .hrd-table > thead > tr > th { background: var(--hrd-surface-subtle); color: var(--hrd-text-secondary); }
.hrd-admin-modal .nav-tabs { float: none; }
.hrd-admin-modal .tab-pane { margin-top: 0; }
.hrd-admin-modal .tab-content > .active { width: auto; display: block; }
@media (min-width: 1366px) {
    .hrd-admin-page .hrd-admin-heading { display: flex; align-items: center; flex-wrap: nowrap; gap: 12px; }
    .hrd-admin-heading:before, .hrd-admin-heading:after { display: none; }
    .hrd-admin-page .hrd-admin-heading > #page-title { flex: 0 0 auto; width: auto; }
    .hrd-admin-page .hrd-admin-heading > .text-right { flex: 1 1 auto; width: auto; min-width: 0; }
    .hrd-admin-page .hrd-admin-heading .hrd-action-toolbar { justify-content: flex-end; flex-wrap: wrap; }
}
/* Time Operations use the approved page, form, action and table primitives. */
.hrd-time-heading { margin-bottom: var(--hrd-space-20); }
.hrd-time-heading > #page-title { flex: 0 1 auto; width: auto; padding-bottom: 0; }
.hrd-time-heading > .text-right { flex: 1 1 auto; width: auto; min-width: 0; }
.hrd-time-page #page-title h2 { margin: 0; color: var(--hrd-text-primary); font-family: var(--hrd-font); font-size: var(--hrd-title-size); font-weight: var(--hrd-title-weight) !important; line-height: 1.3; text-transform: none; }
.hrd-time-page .hrd-action-toolbar { flex-wrap: wrap; }
.hrd-time-page .hrd-action-toolbar .pull-right { float: none !important; }
.hrd-time-page .hrd-table-tools { float: none; width: 100%; }
.hrd-time-page .hrd-time-filters { display: flex; flex-wrap: wrap; align-items: flex-end; gap: var(--hrd-space-3); margin: 0 0 var(--hrd-space-4); }
.hrd-time-filters:before, .hrd-time-filters:after { content: none; }
.hrd-time-filters > .hrd-filter-field { flex: 1 1 155px; min-width: 0; width: auto; padding: 0; }
.hrd-time-filters > .hrd-filter-field:has(.input-group) { flex-basis: 250px; }
.hrd-time-filters > div:empty,
.hrd-time-filters > .hrd-filter-spacer { display: none; }
.hrd-time-page .hrd-filter-label { display: block; margin-bottom: var(--hrd-space-1); color: var(--hrd-text-secondary); font-size: var(--hrd-label-size); font-weight: 600; }
.hrd-time-page .form-control { border-color: var(--hrd-border-strong); border-radius: var(--hrd-radius-small); color: var(--hrd-text-primary); box-shadow: none; }
.hrd-time-page .hrd-table-viewport { min-height: 240px; }
.hrd-time-page .hrd-table-viewport img[src="img/no-data.jpg"] { width: 200px !important; height: 200px !important; object-fit: contain; }
.hrd-time-modal .hrd-time-modal-header { flex-direction: column; align-items: flex-start; text-align: left; }
.hrd-time-modal .hrd-page-title { color: var(--hrd-text-primary); font: var(--hrd-section-weight) var(--hrd-section-size)/1.4 var(--hrd-font); }
.hrd-time-modal .table-responsive { border: 1px solid var(--hrd-border); border-radius: var(--hrd-radius-small); }
.hrd-time-page .overtime-dashboard-summary,
.hrd-time-page .overtime-dashboard-panel,
.hrd-time-page .leave-calendar-panel { border-color: var(--hrd-border); border-radius: var(--hrd-radius-large); background: var(--hrd-surface); }
.hrd-time-page .overtime-dashboard-panel-title,
.hrd-time-page .leave-calendar-header h3.title-hero,
.hrd-time-page .leave-calendar-month-title { color: var(--hrd-text-primary); text-transform: none; }
.hrd-time-page .overtime-dashboard-metric-value { color: var(--hrd-text-primary); }
.hrd-time-page .overtime-dashboard-metric-label,
.hrd-time-page .overtime-dashboard-panel-note { color: var(--hrd-text-secondary); }
.hrd-time-page .leave-info-shell { border-color: var(--hrd-border); }
.hrd-time-page .leave-info-section-title { color: var(--hrd-text-primary); }
.hrd-time-menu { max-width: calc(100vw - 32px); }
/* Honor UI Bootstrap's existing vertical tabsets in Criteria and account forms.
   Horizontal tabsets (including Employee Add/Edit) keep their original layout. */
.hrd-form [vertical="true"][type="tabs"] {
    display: grid;
    grid-template-columns: minmax(120px, 30%) minmax(0, 1fr);
    align-items: start;
    gap: 16px;
    min-width: 0;
}
.hrd-form [vertical="true"][type="tabs"] > .nav-tabs {
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    float: none;
    width: auto;
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
    border-right: 1px solid var(--hrd-border);
}
.hrd-form [vertical="true"][type="tabs"] > .nav-tabs > li {
    float: none;
    width: 100%;
    margin: 0;
}
.hrd-form [vertical="true"][type="tabs"] > .nav-tabs > li > a {
    margin: 0;
    padding: 10px 12px !important;
    border: 0;
    border-left: 2px solid transparent;
    border-radius: 0;
    white-space: normal;
    overflow-wrap: anywhere;
}
.hrd-form [vertical="true"][type="tabs"] > .nav-tabs > li.active > a {
    border-left-color: var(--hrd-primary-ink);
}
.hrd-form [vertical="true"][type="tabs"] > .tab-content {
    min-width: 0;
    width: auto;
    padding: 0;
    margin: 0;
}
.hrd-form [vertical="true"][type="tabs"] > .tab-content > .tab-pane { margin: 0; }
.hrd-form [vertical="true"][type="tabs"] > .tab-content > .active { display: block; width: auto; }
/* One compact desktop filter row; plugin controls share the native input baseline. */
:is(.hrd-admin-filters, .hrd-time-filters) > .hrd-filter-field { padding: 0; margin: 0; }
:is(.hrd-admin-filters, .hrd-time-filters) .form-control:not(.select2-hidden-accessible) {
    height: var(--hrd-control-compact-height);
    min-height: var(--hrd-control-compact-height);
    min-width: 0;
    padding: 7px 9px;
    font-size: var(--hrd-body-size);
    text-overflow: ellipsis;
}
:is(.hrd-admin-filters, .hrd-time-filters) .input-group { width: 100%; }
:is(.hrd-admin-filters, .hrd-time-filters) .input-group-addon { height: var(--hrd-control-compact-height); }
:is(.hrd-admin-filters, .hrd-time-filters) .select2-container { display: block; width: 100% !important; min-width: 0; }
:is(.hrd-admin-filters, .hrd-time-filters) .select2-selection--single {
    height: var(--hrd-control-compact-height);
    border-color: var(--hrd-border-strong);
    border-radius: var(--hrd-radius-small);
    background: var(--hrd-surface);
}
:is(.hrd-admin-filters, .hrd-time-filters) .select2-selection--single .select2-selection__rendered {
    color: var(--hrd-text-primary);
    font-size: var(--hrd-body-size);
    line-height: 34px;
    padding-left: 9px;
}
:is(.hrd-admin-filters, .hrd-time-filters) .select2-selection--single .select2-selection__arrow { height: 34px; }
:is(.hrd-admin-filters, .hrd-time-filters) > .hrd-filter-field:has(> input[type="checkbox"]) {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    column-gap: 6px;
}
:is(.hrd-admin-filters, .hrd-time-filters) > .hrd-filter-field:has(> input[type="checkbox"]) > label { grid-column: 1 / -1; }
:is(.hrd-admin-filters, .hrd-time-filters) > .hrd-filter-field:has(> input[type="checkbox"]) > select { width: 100% !important; }
:is(.hrd-admin-filters, .hrd-time-filters) > .hrd-filter-field > input[type="checkbox"] { margin: 0 !important; }
@media (min-width: 1200px) {
    /* Approved compact filter baseline: spare space stays to the left; dense
       rows shrink proportionally without changing order or wrapping. */
    :is(.hrd-admin-filters, .hrd-time-filters, .hrd-operational-filters),
    .hrd-time-page .hrd-time-filters,
    .hrd-filter-grid > .row {
        display: flex;
        align-items: flex-end;
        justify-content: flex-end;
        flex-wrap: nowrap;
        gap: 8px;
    }
    :is(.hrd-admin-filters, .hrd-time-filters) > :is(.hrd-filter-field, [class*="col-"]:has(.form-control)),
    .hrd-operational-filters > [class*="col-"],
    .hrd-filter-grid > .row > div { flex: 0 1 200px; max-width: 200px; padding: 0; }
    :is(.hrd-admin-filters, .hrd-time-filters) > :is(.hrd-filter-field, [class*="col-"]:has(.form-control)):has(.input-group),
    .hrd-operational-filters > [class*="col-"]:has(.input-group) { flex-basis: 280px; max-width: 280px; }
    .hrd-filter-grid > .row { margin: 0; }
    .hrd-filter-grid > .row > div { padding: 0; }
}
@media (max-width: 767px) {
    .hrd-operational-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .hrd-admin-filters > .hrd-filter-actions { flex: 0 1 100%; min-width: 0; max-width: 100%; }
    .hrd-filter-actions > .btn { max-width: 100%; white-space: normal; }
    .hrd-form [vertical="true"][type="tabs"] { grid-template-columns: minmax(100px, 32%) minmax(0, 1fr); gap: 8px; }
    .hrd-form [vertical="true"][type="tabs"] > .nav-tabs > li > a { padding: 8px !important; }
}
@media (max-width: 480px) {
    .hrd-operational-filters { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 1699px) {
    .hrd-time-heading > #page-title, .hrd-time-heading > .text-right { flex-basis: 100%; width: 100%; }
    .hrd-time-page .hrd-action-toolbar { justify-content: flex-start; }
}
/* Leave Request keeps the original default dialog width and compact inset. */
.hrd-form-dialog:has(.hrd-leave-request) { max-width: 600px; }
.hrd-leave-request .hrd-page-header,
.hrd-leave-request .hrd-form-body,
.hrd-leave-request .hrd-form-actions { padding: 15px; }
.hrd-leave-request .hrd-field-error:empty { display: none; }
/* Leaves and Overtimes share the reference lists' right-aligned command group. */
.hrd-time-page .hrd-time-command-heading .hrd-action-toolbar { justify-content: flex-end; }
@media (min-width: 1366px) {
    .hrd-time-page .hrd-time-command-heading { flex-wrap: nowrap; }
    .hrd-time-command-heading:before,
    .hrd-time-command-heading:after { display: none; }
    .hrd-time-page .hrd-time-command-heading > #page-title { flex: 0 0 auto; width: auto; }
    .hrd-time-command-heading #page-title p { margin: 0; }
    .hrd-time-page .hrd-time-command-heading > .text-right { flex: 1 1 auto; width: auto; }
    .hrd-time-page .hrd-time-command-heading .hrd-action-toolbar { flex-wrap: nowrap; }
}
@media (min-width: 1366px) and (max-width: 1499px) {
    .hrd-time-command-heading .hrd-action-toolbar .hrd-action-button { padding: 0 10px !important; }
}
.hrd-payroll-modal .hrd-table { width: 100%; margin-bottom: var(--hrd-space-3); color: var(--hrd-text-primary); }
.hrd-payroll-modal .hrd-table > thead > tr > th,
.hrd-payroll-modal .hrd-table > thead > tr > td { color: var(--hrd-text-secondary); background: var(--hrd-surface-subtle); font-weight: 600; }
.hrd-payroll-modal .hrd-table > thead > tr > th,
.hrd-payroll-modal .hrd-table > thead > tr > td,
.hrd-payroll-modal .hrd-table > tbody > tr > td { padding: 9px 10px; border-color: var(--hrd-border); vertical-align: middle; }

@media (max-width: 1199px) {
    .hrd-payroll-heading > #page-title,
    .hrd-payroll-heading > .text-right { flex: 0 0 100%; width: 100%; }
    .hrd-process-summary { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .hrd-process-summary-item { border-bottom: 1px solid var(--hrd-border); }
}
@media (max-width: 767px) {
    .hrd-process-summary { grid-template-columns: 1fr; }
    .hrd-process-summary-item { border-right: 0; }
    .hrd-process-summary-item:last-child { border-bottom: 0; }
    .hrd-payroll-process-detail .hrd-payroll-metric { width: 100%; }
}
