/*
 * Remind Legal PMS — enterprise interface layer
 * Loaded after AdminLTE, plugins and the legacy stylesheet so the application
 * can share one predictable design system while legacy screens are migrated.
 */

:root {
    --ui-bg: #f8f9fa;
    --ui-surface: #ffffff;
    --ui-surface-soft: #fafafa;
    --ui-text: #242424;
    --ui-text-strong: #171717;
    --ui-text-muted: #71717a;
    --ui-text-subtle: #8b8b93;
    --ui-border: #e9eaec;
    --ui-border-strong: #d8dadd;
    --ui-hover: #f4f5f6;

    --ui-brand: #c7c9cc;
    --ui-brand-soft: #f1f2f3;
    --ui-brand-subtle: #f7f8f9;
    --ui-accent: #242424;
    --ui-accent-hover: #414141;
    --ui-accent-text: #242424;

    --ui-success: #16845b;
    --ui-success-soft: #eaf7f1;
    --ui-warning: #52525b;
    --ui-warning-soft: #f4f4f5;
    --ui-error: #dc4545;
    --ui-error-soft: #fff0f0;
    --ui-info: #4f6b65;
    --ui-info-soft: #eef4f2;

    --ui-radius-sm: 6px;
    --ui-radius-md: 8px;
    --ui-radius-lg: 12px;
    --ui-radius-pill: 999px;
    --ui-shadow-sm: 0 1px 2px rgba(24, 24, 27, 0.04);
    --ui-shadow-md: 0 10px 28px rgba(24, 24, 27, 0.06);
    --ui-ring: 0 0 0 3px rgba(36, 36, 36, 0.16);

    --ui-space-1: 4px;
    --ui-space-2: 8px;
    --ui-space-3: 12px;
    --ui-space-4: 16px;
    --ui-space-5: 20px;
    --ui-space-6: 24px;
    --ui-space-8: 32px;

    --ui-sidebar-width: 264px;
    --ui-header-height: 64px;
    --ui-control-height: 42px;
    /* One type scale for admin and employee workspaces. */
    --ui-font-page-title: 24px;
    --ui-font-section-title: 18px;
    --ui-font-card-title: 16px;
    --ui-font-body: 14px;
    --ui-font-control: 14px;
    --ui-font-button: 13px;
    --ui-font-table: 12px;
    --ui-font-label: 12px;
    --ui-font-caption: 12px;
    --ui-font-kicker: 11px;
    --ui-font-metric: 21px;
    --ui-transition: 160ms ease;
}

html {
    background: var(--ui-bg);
}

body,
button,
input,
select,
textarea,
.select2-container {
    font-family: Inter, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

body.pms-shell {
    --pms-primary: var(--ui-accent);
    --pms-primary-hover: var(--ui-accent-hover);
    --pms-accent: var(--ui-brand);
    --pms-accent-soft: var(--ui-brand-soft);
    --pms-bg: var(--ui-bg);
    --pms-text: var(--ui-text);
    --pms-muted: var(--ui-text-muted);
    --pms-border: var(--ui-border);
    background: var(--ui-bg);
    color: var(--ui-text);
    font-size: 14px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

.pms-shell a {
    color: var(--ui-accent);
    transition: color var(--ui-transition), background-color var(--ui-transition),
        border-color var(--ui-transition), box-shadow var(--ui-transition),
        transform var(--ui-transition);
}

.pms-shell a:hover {
    color: var(--ui-accent-hover);
    text-decoration: none;
}

.pms-shell :focus-visible {
    outline: 2px solid var(--ui-accent);
    outline-offset: 2px;
}

.pms-shell h1,
.pms-shell .h1,
.pms-shell .content-header h1 {
    color: var(--ui-text-strong);
    font-size: 24px;
    font-weight: 600;
    letter-spacing: -0.025em;
    line-height: 1.25;
}

.pms-shell h2,
.pms-shell .h2,
.pms-shell .pms-panel-heading h2 {
    color: var(--ui-text-strong);
    font-size: 18px;
    font-weight: 600;
    line-height: 1.35;
}

.pms-shell h3,
.pms-shell .h3,
.pms-shell .card-title {
    color: var(--ui-text-strong);
    font-size: 16px;
    font-weight: 600;
    line-height: 1.4;
}

.pms-shell h4,
.pms-shell .h4,
.pms-shell h5,
.pms-shell .h5 {
    color: var(--ui-text-strong);
    font-size: 15px;
    font-weight: 600;
}

.pms-shell small,
.pms-shell .small,
.pms-shell .form-text,
.pms-shell .help-block,
.pms-shell .pms-page-subtitle {
    color: var(--ui-text-muted);
    font-size: 12px;
}

/* Header spark: a borderless, continuous ribbon rather than dashboard cards. */
body.pms-shell .main-header { flex-wrap: nowrap; }
.pms-shell .main-header .pms-header-title,
.pms-shell .main-header .pms-navbar-actions { flex-shrink: 0; }
.pms-shell .pms-header-spark { display: flex; align-items: center; gap: 10px; flex: 1 1 0%; min-width: 0; width: 0; height: 36px; margin: 0 22px; padding-left: 18px; border-left: 1px solid #dfcfb2; }
.pms-shell .pms-spark-viewport { min-width: 0; flex: 1 1 auto; overflow: hidden; padding: 5px 0; mask-image: linear-gradient(90deg, #000 calc(100% - 20px), transparent); -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 20px), transparent); }
.pms-shell .pms-spark-track { display: flex; width: max-content; white-space: nowrap; }
.pms-shell .pms-header-spark.is-ready .pms-spark-track { animation: pms-header-spark-scroll var(--spark-duration, 120s) linear infinite; will-change: transform; }
.pms-shell .pms-header-spark.is-paused .pms-spark-track,
.pms-shell .pms-header-spark:hover .pms-spark-track,
.pms-shell .pms-header-spark:focus-within .pms-spark-track { animation-play-state: paused; }
.pms-shell .pms-spark-group { display: flex; align-items: center; gap: 32px; flex: 0 0 auto; padding-right: 32px; }
.pms-shell .pms-spark-item { display: inline-flex; align-items: center; gap: 10px; color: #444449; font-size: 12px !important; line-height: 1.5; }
.pms-shell .pms-spark-item::after { content: ""; width: 4px; height: 4px; margin-left: 20px; background: #c2a879; transform: rotate(45deg); }
.pms-shell .pms-spark-emoji { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 24px; width: 24px; font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif; font-size: 18px !important; line-height: 1.4; }
.pms-shell .pms-spark-copy { font-size: 12px !important; }
.pms-shell .pms-spark-item--thought .pms-spark-copy { color: #52525b; font-style: italic; }
.pms-shell .pms-spark-item--birthday .pms-spark-copy { color: #88652f; font-weight: 600; }
@keyframes pms-header-spark-scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.pms-shell .pms-header-spark.is-reduced-motion .pms-spark-track { animation: none !important; transform: none; will-change: auto; }
.pms-shell .pms-header-spark.is-reduced-motion .pms-spark-group[aria-hidden="true"] { display: none; }
.pms-shell .pms-header-spark.is-reduced-motion .pms-spark-viewport { overflow-x: auto; scrollbar-width: thin; }
@media (max-width: 1199.98px) {
    .pms-shell .pms-header-spark { margin-inline: 12px; padding-left: 12px; gap: 7px; }
}
@media (max-width: 767.98px) {
    .pms-shell .pms-header-spark { margin-inline: 6px; padding-left: 0; border-left: 0; gap: 4px; }
}
@media (prefers-reduced-motion: reduce) {
    .pms-shell .pms-header-spark .pms-spark-track { animation: none !important; transform: none; will-change: auto; }
    .pms-shell .pms-header-spark .pms-spark-group[aria-hidden="true"] { display: none; }
    .pms-shell .pms-header-spark .pms-spark-viewport { overflow-x: auto; scrollbar-width: thin; }
}

/* Ginnie: reserved space, a brief blink, and contextual static poses. */
.pms-shell .pms-ginnie { position: relative; display: inline-block; flex: 0 0 88px; width: 88px; height: 88px; overflow: hidden; vertical-align: middle; }
.pms-shell .pms-ginnie img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; max-width: none; object-fit: contain; }
.pms-shell .pms-ginnie-blink { opacity: 0; animation: pms-ginnie-blink 7s step-end infinite; }
@keyframes pms-ginnie-blink { 0%, 94%, 98%, 100% { opacity: 0; } 95%, 97% { opacity: 1; } }
.pms-shell .pms-header-spark > .pms-ginnie { flex-basis: 42px; width: 42px; height: 44px; }
.pms-shell .pms-header-spark > .pms-ginnie img { inset: -3px auto auto -27px; width: 96px; height: 96px; }
.pms-shell .pms-header-spark > .pms-ginnie--working img,
.pms-shell .pms-header-spark > .pms-ginnie--pointing img { inset: 0; width: 100%; height: 100%; }
.pms-shell .pms-header-spark.is-paused .pms-ginnie-blink { animation-play-state: paused; }
.pms-shell .pms-ginnie-empty { display: grid; justify-items: center; gap: 6px; white-space: normal; }
.pms-shell .pms-ginnie-empty strong { color: var(--ui-text-strong); font-size: 14px; }
.pms-shell .pms-ginnie-empty > span:last-child { color: var(--ui-text-muted); font-size: 12px; }
.pms-birthday-popup .swal2-image { margin: 0 auto 4px; object-fit: contain; }
.swal2-popup.pms-ginnie-success { width: min(360px, calc(100vw - 32px)); padding: 18px 22px 20px; }
.pms-ginnie-success .swal2-image { margin: 0 auto 6px; object-fit: contain; }
.pms-ginnie-success .swal2-title { margin: 0; padding: 0; font-size: 18px !important; line-height: 1.35; }
.pms-ginnie-success .swal2-html-container { margin: 8px 0 0; font-size: 13px !important; line-height: 1.5; }
.pms-ginnie-success .swal2-actions { margin: 16px 0 0; gap: 8px; }
.pms-ginnie-success .swal2-confirm { min-height: 38px; margin: 0; padding: 8px 22px; font-size: 13px; line-height: 1.3; }
.swal2-popup.pms-ginnie-success--toast { width: auto; max-width: calc(100vw - 24px); padding: 10px 14px; }
.pms-ginnie-success--toast .swal2-image { margin: 0 10px 0 0; }
.pms-ginnie-success-video { display: block; grid-column: 1 / -1; width: 184px; height: 184px; max-width: 100%; margin: 0 auto 10px; object-fit: cover; object-position: 50% 50%; border-radius: 12px; }
.pms-ginnie-success--toast .pms-ginnie-success-video { grid-column: 1; grid-row: 1 / span 2; width: 76px; height: 76px; margin: 0 10px 0 0; }
.pms-ginnie-success .pms-ginnie-replay { position: absolute; top: 8px; right: 8px; width: 36px; height: 36px; margin: 0; }
.pms-ginnie-success--toast { padding-right: 42px !important; }
.pms-ginnie-overdue-list { display: grid; gap: 8px; max-height: 220px; margin-top: 12px; overflow-y: auto; text-align: left; }
.pms-ginnie-overdue-list > div { display: grid; gap: 3px; padding: 9px 11px; background: #faf8f3; border: 1px solid #ece3d3; border-radius: 7px; }
.pms-ginnie-overdue-list strong { color: var(--ui-text-strong); font-size: 13px; line-height: 1.4; overflow-wrap: anywhere; }
.pms-ginnie-overdue-list span { color: #9a452d; font-size: 12px; }
.pms-ginnie-overdue-list > a { justify-self: center; margin-top: 4px; }
.swal2-popup.pms-ginnie-overdue { width: min(390px, calc(100vw - 32px)); }
.pms-ginnie-overdue .pms-ginnie-replay { right: 42px; }
.pms-ginnie-sound, .pms-ginnie-replay { display: inline-grid; flex: 0 0 32px; width: 32px; height: 36px; place-items: center; padding: 0; background: transparent; border: 0; border-radius: 6px; cursor: pointer; }
.pms-ginnie-sound:hover, .pms-ginnie-replay:hover { background: var(--ui-hover); }
.pms-ginnie-replay { margin: 6px auto 0; font-size: 16px; }
.pms-ginnie-nudge[hidden] { display: none !important; }
.pms-ginnie-nudge { position: fixed; z-index: 1038; right: 24px; bottom: 24px; display: flex; align-items: flex-end; gap: 0; width: min(410px, calc(100vw - 28px)); pointer-events: none; }
.pms-ginnie-nudge > img { flex: 0 0 90px; width: 90px; height: 110px; object-fit: contain; }
.pms-ginnie-bubble { position: relative; flex: 1; min-width: 0; padding: 18px 16px 12px; color: var(--ui-text); background: #fffdf8; border: 1px solid #e5d6b9; border-radius: 14px 14px 14px 3px; box-shadow: 0 8px 30px rgba(40, 32, 18, .13); pointer-events: auto; }
.pms-ginnie-bubble p { margin: 4px 0 10px; font-size: 13px; line-height: 1.5; overflow-wrap: anywhere; }
.pms-ginnie-close { position: absolute; top: 0; right: 1px; width: 32px; height: 32px; padding: 0; color: #716858; background: transparent; border: 0; border-radius: 8px; font-size: 21px; cursor: pointer; }
.pms-ginnie-nudge-actions { display: flex; flex-wrap: wrap; gap: 6px; }
.pms-ginnie-nudge-actions [hidden] { display: none !important; }
.pms-ginnie-nudge.is-speaking > img { animation: pms-ginnie-talk 650ms ease-in-out infinite alternate; }
@keyframes pms-ginnie-talk { to { transform: translateY(-3px) rotate(-2deg); } }
@media (max-width: 575.98px) {
    .pms-ginnie-nudge { right: 14px; bottom: 16px; }
    .pms-ginnie-nudge > img { flex-basis: 65px; width: 65px; height: 90px; }
}
@media (prefers-reduced-motion: reduce) { .pms-ginnie-nudge.is-speaking > img { animation: none; } }
@media print { .pms-ginnie-nudge, .pms-ginnie-sound { display: none !important; } }
@media (max-width: 575.98px) {
    .pms-shell .pms-header-spark > .pms-ginnie { flex-basis: 30px; width: 30px; height: 36px; }
    .pms-shell .pms-header-spark > .pms-ginnie img { width: 78px; height: 78px; left: -24px; }
}
@media (prefers-reduced-motion: reduce) {
    .pms-shell .pms-ginnie-blink { display: none; animation: none; }
}
@media print { .pms-shell .pms-ginnie { display: none; } }

/* Application shell */
.pms-shell .content-wrapper {
    min-height: calc(100vh - var(--ui-header-height));
    margin-left: var(--ui-sidebar-width);
    background: var(--ui-bg);
}

.pms-shell .main-header {
    position: sticky;
    top: 0;
    z-index: 1035;
    min-height: var(--ui-header-height);
    margin-left: var(--ui-sidebar-width);
    padding: 0 var(--ui-space-6);
    background: rgba(255, 255, 255, 0.96);
    border: 0;
    border-bottom: 1px solid var(--ui-border);
    box-shadow: none;
    backdrop-filter: blur(10px);
}

.pms-shell .main-footer {
    margin-left: var(--ui-sidebar-width);
    padding: 14px var(--ui-space-6);
    color: var(--ui-text-muted);
    font-size: 12px;
    font-weight: 400;
    background: var(--ui-surface);
    border-top: 1px solid var(--ui-border);
}

.pms-shell .main-footer strong {
    font-weight: 500;
}

.pms-header-title {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 1px;
    color: var(--ui-text-strong);
    font-size: 14px;
    font-weight: 600;
    line-height: 1.25;
}

.pms-header-title .pms-header-kicker {
    color: var(--ui-text-muted);
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.pms-navbar-actions {
    align-items: center;
    gap: 4px;
}

.pms-shell .main-header .nav-link.pms-icon-button {
    position: relative;
    display: inline-flex;
    width: 38px;
    height: 38px;
    align-items: center;
    justify-content: center;
    padding: 0;
    color: var(--ui-text-muted);
    border: 1px solid transparent;
    border-radius: var(--ui-radius-md);
}

.pms-shell .main-header .nav-link.pms-icon-button:hover,
.pms-shell .main-header .show > .nav-link.pms-icon-button {
    color: var(--ui-text-strong);
    background: var(--ui-hover);
    border-color: var(--ui-border);
}

.pms-notification-dot {
    position: absolute;
    top: 7px;
    right: 7px;
    width: 7px;
    height: 7px;
    background: var(--ui-error);
    border: 2px solid var(--ui-surface);
    border-radius: 50%;
}

.pms-notification-dropdown {
    width: min(340px, calc(100vw - 24px));
    padding: 8px;
}

.pms-dropdown-heading {
    padding: 8px 10px 10px;
    color: var(--ui-text-strong);
    font-size: 13px;
    font-weight: 600;
    border-bottom: 1px solid var(--ui-border);
}

.pms-notification-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-top: 4px;
    padding: 10px;
    white-space: normal;
    border-radius: var(--ui-radius-md);
}

.pms-notification-item:hover {
    background: var(--ui-hover);
}

.pms-notification-item > span:last-child {
    display: flex;
    min-width: 0;
    flex-direction: column;
    color: var(--ui-text-muted);
    font-size: 12px;
}

.pms-notification-item strong {
    color: var(--ui-text);
    font-size: 13px;
    font-weight: 600;
}

.pms-notification-icon {
    display: inline-flex;
    width: 30px;
    height: 30px;
    flex: 0 0 30px;
    align-items: center;
    justify-content: center;
    color: var(--ui-accent);
    background: var(--ui-brand-soft);
    border-radius: var(--ui-radius-md);
}

.pms-notification-empty {
    padding: 18px 10px;
    color: var(--ui-text-muted);
    font-size: 13px;
    text-align: center;
}

.pms-shell .pms-avatar {
    width: 38px;
    height: 38px;
    color: var(--ui-text-strong) !important;
    font-size: 14px;
    font-weight: 600;
    background: var(--ui-brand-soft) !important;
    border: 1px solid rgba(36, 36, 36, 0.16);
    box-shadow: none;
}

.pms-shell .dropdown-menu {
    margin-top: 8px;
    color: var(--ui-text);
    background: var(--ui-surface);
    border: 1px solid var(--ui-border);
    border-radius: var(--ui-radius-lg);
    box-shadow: var(--ui-shadow-md);
}

.pms-shell .dropdown-item {
    color: var(--ui-text);
    font-size: 13px;
    border-radius: var(--ui-radius-sm);
}

.pms-shell .dropdown-item:hover,
.pms-shell .dropdown-item:focus {
    color: var(--ui-text-strong);
    background: var(--ui-hover);
}

.pms-shell .dropdown-divider {
    border-top-color: var(--ui-border);
}

.pms-header-message {
    display: none;
}

.pms-header-message .marquee-container {
    width: auto;
    max-width: 100%;
    padding: 7px 12px;
    color: var(--ui-accent-text);
    background: var(--ui-brand-subtle);
    border: 1px solid rgba(36, 36, 36, 0.14);
    border-radius: var(--ui-radius-pill);
}

.pms-header-message .marquee-text {
    color: inherit;
    font-size: 12px;
}

.pms-header-message:hover .marquee-text,
.pms-header-message:focus-within .marquee-text {
    animation-play-state: paused;
}

/* Sidebar */
/* AdminLTE positions non-layout-fixed sidebars absolutely, so they move with
   long pages. Keep the shell anchored while its menu scrolls independently. */
body.pms-shell:not(.layout-fixed) .main-sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    height: 100vh;
    min-height: 0;
}

.pms-shell .main-sidebar,
.pms-shell .main-sidebar::before {
    width: var(--ui-sidebar-width);
    background: var(--ui-surface);
    border-right: 1px solid var(--ui-border);
    box-shadow: none;
}

.pms-shell .brand-link {
    display: flex;
    height: var(--ui-header-height);
    align-items: center;
    padding: 12px 20px;
    background: var(--ui-surface);
    border-bottom: 1px solid var(--ui-border);
}

.pms-shell .brand-link .brand-image {
    width: auto !important;
    max-width: 176px;
    height: 38px;
    max-height: 38px;
    margin: 0;
    object-fit: contain;
    opacity: 1;
}

.pms-shell .sidebar {
    height: calc(100vh - var(--ui-header-height));
    padding: 8px 10px 12px;
    overflow-y: auto;
    overscroll-behavior-y: contain;
    scrollbar-width: thin;
    scrollbar-color: var(--ui-border-strong) transparent;
}

.pms-shell .nav-sidebar > .nav-header {
    margin: 10px 10px 4px;
    padding: 0;
    color: #565d66;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.06em;
    line-height: 1.4;
}

.pms-shell .nav-sidebar > .nav-item {
    margin-bottom: 0;
}

.pms-shell .nav-sidebar .nav-link {
    display: flex;
    min-height: 36px;
    align-items: center;
    gap: 10px;
    padding: 6px 11px;
    color: #4f4f55;
    font-size: 13px;
    font-weight: 500;
    border: 1px solid transparent;
    border-radius: var(--ui-radius-md);
}

.pms-shell .nav-sidebar .nav-link .nav-icon {
    width: 18px;
    margin: 0;
    color: #8a8070;
    font-size: 15px;
    text-align: center;
}

.pms-shell .nav-sidebar .nav-link svg.nav-icon {
    width: 18px;
    height: 18px;
}

.pms-shell .nav-sidebar .nav-link p {
    display: flex;
    min-width: 0;
    flex: 1;
    align-items: center;
    margin: 0;
}

.pms-shell .nav-sidebar .nav-link:hover {
    color: var(--ui-text-strong);
    background: var(--ui-hover);
    border-color: var(--ui-border);
}

.pms-shell .nav-sidebar .nav-link:hover .nav-icon {
    color: var(--ui-accent);
}

.pms-shell .nav-sidebar .nav-link.active {
    color: var(--ui-accent-text);
    background: var(--ui-brand-soft);
    border-color: rgba(36, 36, 36, 0.14);
    box-shadow: inset 3px 0 0 var(--ui-brand);
}

.pms-shell .nav-sidebar .nav-link.active .nav-icon {
    color: var(--ui-accent);
}

.pms-shell .pms-sidebar-toggle {
    color: var(--ui-text-muted);
    background: var(--ui-surface-soft);
    border-color: var(--ui-border);
}

.pms-shell .main-header .pms-admin-sidebar-toggle {
    color: var(--ui-text-muted);
    background: transparent;
    border-color: transparent;
}

.pms-shell .nav-sidebar .badge {
    margin-left: auto;
    padding: 3px 6px;
    color: var(--ui-accent-text);
    font-size: 10px;
    font-weight: 600;
    background: var(--ui-brand-soft);
    border-radius: var(--ui-radius-pill);
}

.pms-shell .mobilecloseicon {
    position: absolute;
    top: 14px;
    right: 12px;
    z-index: 2;
    width: 36px;
    height: 36px;
    color: var(--ui-text-muted);
    background: var(--ui-surface);
    border: 1px solid var(--ui-border);
    border-radius: var(--ui-radius-md);
}

.pms-shell .pms-date-display {
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.02em;
}

.pms-shell .pms-account-remark {
    max-width: 320px;
    white-space: normal;
    line-height: 1.45;
    overflow-wrap: anywhere;
}

.pms-shell .pms-account-remark-text {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.pms-sidebar-backdrop {
    display: none;
}

/* Content frame */
body.pms-shell .content-header {
    padding: 24px 24px 10px;
}

.pms-shell .content-header .container-fluid {
    padding-right: 0;
    padding-left: 0;
}

body.pms-admin-shell .content-wrapper h1 {
    text-transform: uppercase;
}

.pms-shell .content-header .container-fluid,
.pms-shell .content > .container-fluid {
    width: 100%;
    max-width: 1680px;
    margin: 0 auto;
}

body.pms-shell .content {
    padding: 0 24px 24px;
}

.pms-shell .content > .container-fluid {
    padding-right: 0;
    padding-left: 0;
}

.pms-shell .pms-page-subtitle {
    margin: 4px 0 0;
    line-height: 1.5;
}

.pms-shell .breadcrumb {
    padding: 0;
    font-size: 12px;
    background: transparent;
}

.pms-shell .breadcrumb-item + .breadcrumb-item::before {
    color: var(--ui-text-subtle);
}

/* Cards and panels */
.pms-shell .card,
.pms-shell .small-box.card,
.pms-shell .info-box {
    color: var(--ui-text);
    background: var(--ui-surface);
    border: 1px solid var(--ui-border);
    border-radius: var(--ui-radius-lg);
    box-shadow: var(--ui-shadow-sm);
}

.pms-shell .card {
    margin-bottom: 18px;
    overflow: visible;
}

.pms-shell .card-header {
    min-height: 58px;
    padding: 14px 18px;
    background: transparent;
    border-bottom: 1px solid var(--ui-border);
    border-radius: var(--ui-radius-lg) var(--ui-radius-lg) 0 0;
}

.pms-shell .card-body {
    padding: 18px;
}

.pms-shell .card-footer {
    padding: 12px 18px;
    background: var(--ui-surface-soft);
    border-top: 1px solid var(--ui-border);
    border-radius: 0 0 var(--ui-radius-lg) var(--ui-radius-lg);
}

.pms-shell .card-outline,
.pms-shell .card-primary.card-outline,
.pms-shell .card-info.card-outline,
.pms-shell .card-warning.card-outline {
    border-top: 1px solid var(--ui-border);
}

.pms-shell .pms-panel-heading {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 16px;
}

.pms-shell .pms-panel-heading h2,
.pms-shell .pms-panel-heading p {
    margin: 0;
}

.pms-shell .pms-panel-heading p {
    margin-top: 2px;
    color: var(--ui-text-muted);
    font-size: 12px;
}

.pms-shell .pms-panel-icon {
    display: inline-flex;
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    align-items: center;
    justify-content: center;
    color: var(--ui-accent);
    background: var(--ui-brand-soft);
    border-radius: var(--ui-radius-md);
}

.pms-shell .pms-eyebrow {
    display: block;
    margin-bottom: 3px;
    color: var(--ui-accent);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

/* Forms */
.pms-shell label,
.pms-shell .form-label {
    margin-bottom: 6px;
    color: #444449;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.35;
    text-transform: none;
}

.pms-shell .form-group {
    margin-bottom: 14px;
}

.pms-shell .form-control,
.pms-shell .custom-select,
.pms-shell .select2-container--default .select2-selection--single,
.pms-shell .select2-container--default .select2-selection--multiple {
    min-height: var(--ui-control-height);
    color: var(--ui-text);
    font-size: 14px;
    background-color: var(--ui-surface);
    border: 1px solid var(--ui-border-strong);
    border-radius: var(--ui-radius-md);
    box-shadow: none;
    transition: border-color var(--ui-transition), box-shadow var(--ui-transition),
        background-color var(--ui-transition);
}

.pms-shell .form-control,
.pms-shell .custom-select {
    height: var(--ui-control-height);
    padding: 9px 12px;
}

.pms-shell textarea.form-control {
    min-height: 96px;
    height: auto;
    resize: vertical;
}

.pms-shell .form-control::placeholder {
    color: #9a9aa1;
    opacity: 1;
}

.pms-shell .form-control:hover:not(:disabled):not([readonly]),
.pms-shell .custom-select:hover:not(:disabled) {
    border-color: #c4c6ca;
}

.pms-shell .form-control:focus,
.pms-shell .custom-select:focus,
.pms-shell .select2-container--default.select2-container--focus .select2-selection--multiple,
.pms-shell .select2-container--default.select2-container--open .select2-selection--single {
    color: var(--ui-text);
    background: var(--ui-surface);
    border-color: var(--ui-brand);
    box-shadow: var(--ui-ring);
    outline: 0;
}

.pms-shell .form-control:disabled,
.pms-shell .form-control[readonly],
.pms-shell .custom-select:disabled {
    color: #707078;
    background: #f2f3f4;
    border-color: var(--ui-border);
    opacity: 1;
}

.pms-shell .input-group-text {
    min-height: var(--ui-control-height);
    color: var(--ui-text-muted);
    background: var(--ui-surface-soft);
    border-color: var(--ui-border-strong);
}

.pms-shell .custom-control-label::before {
    border-color: var(--ui-border-strong);
}

.pms-shell .custom-control-input:checked ~ .custom-control-label::before {
    background-color: var(--ui-accent);
    border-color: var(--ui-accent);
}

.pms-shell .custom-control-input:focus ~ .custom-control-label::before {
    box-shadow: var(--ui-ring);
}

.pms-shell .is-invalid,
.pms-shell .form-control.is-invalid,
.pms-shell .was-validated .form-control:invalid {
    border-color: var(--ui-error);
    background-image: none;
}

.pms-shell .invalid-feedback,
.pms-shell .text-danger {
    color: var(--ui-error) !important;
    font-size: 12px;
}

.pms-shell .select2-container {
    width: 100% !important;
}

.pms-shell .select2-container--default .select2-selection--single .select2-selection__rendered {
    padding: 6px 36px 14px 12px;
    color: var(--ui-text);
    line-height: 22px;
}

.pms-shell .select2-container--default .select2-selection--single .select2-selection__arrow {
    top: 7px;
    right: 8px;
}

.select2-dropdown {
    border-color: var(--ui-border-strong);
    border-radius: var(--ui-radius-md);
    box-shadow: var(--ui-shadow-md);
}

.select2-container--default .select2-results__option--highlighted[aria-selected] {
    color: var(--ui-text-strong);
    background: var(--ui-brand-soft);
}

.pms-shell .note-editor.note-frame {
    border: 1px solid var(--ui-border-strong);
    border-radius: var(--ui-radius-md);
    box-shadow: none;
}

.pms-shell .note-editor.note-frame .note-toolbar {
    padding: 6px;
    background: var(--ui-surface-soft);
    border-bottom: 1px solid var(--ui-border);
    border-radius: var(--ui-radius-md) var(--ui-radius-md) 0 0;
}

.pms-shell .note-editor .note-editable {
    min-height: 110px;
    padding: 12px;
    font-size: 14px;
}

/* Buttons */
.pms-shell .btn {
    display: inline-flex;
    min-height: 38px;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 8px 14px;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.25;
    border-width: 1px;
    border-radius: var(--ui-radius-md);
    box-shadow: none;
    transition: color var(--ui-transition), background-color var(--ui-transition),
        border-color var(--ui-transition), box-shadow var(--ui-transition),
        transform var(--ui-transition);
}

.pms-shell .btn:hover {
    transform: translateY(-1px);
}

.pms-shell .btn:active {
    transform: translateY(0);
}

.pms-shell .btn:focus,
.pms-shell .btn.focus {
    box-shadow: var(--ui-ring);
}

.pms-shell .btn-sm,
.pms-shell .mblbtn.btn-sm {
    min-height: 34px;
    padding: 6px 11px;
    font-size: 12px;
}

.pms-shell .btn-lg {
    min-height: 44px;
    padding: 10px 18px;
    font-size: 14px;
}

.pms-shell .btn-primary,
.pms-shell .btnblue,
.pms-shell .btnblack {
    color: #fff;
    background: var(--ui-accent);
    border-color: var(--ui-accent);
}

.pms-shell .btn-primary:hover,
.pms-shell .btn-primary:focus,
.pms-shell .btnblue:hover,
.pms-shell .btnblue:focus,
.pms-shell .btnblack:hover,
.pms-shell .btnblack:focus {
    color: #fff;
    background: var(--ui-accent-hover);
    border-color: var(--ui-accent-hover);
}

.pms-shell .btn-secondary,
.pms-shell .btn-default,
.pms-shell .btn-light {
    color: var(--ui-text);
    background: var(--ui-surface);
    border-color: var(--ui-border-strong);
}

.pms-shell .btn-secondary:hover,
.pms-shell .btn-default:hover,
.pms-shell .btn-light:hover {
    color: var(--ui-text-strong);
    background: var(--ui-hover);
    border-color: #c8c9cd;
}

.pms-shell .btnorange,
.pms-shell .btn-warning {
    color: var(--ui-accent-text);
    background: var(--ui-brand-soft);
    border-color: rgba(36, 36, 36, 0.18);
}

.pms-shell .btnorange:hover,
.pms-shell .btn-warning:hover {
    color: var(--ui-accent-hover);
    background: #e9eaec;
    border-color: var(--ui-brand);
}

.pms-shell .btn-danger,
.pms-shell .btnred {
    color: var(--ui-error);
    background: var(--ui-error-soft);
    border-color: rgba(220, 69, 69, 0.28);
}

.pms-shell .btn-danger:hover,
.pms-shell .btnred:hover {
    color: #fff;
    background: var(--ui-error);
    border-color: var(--ui-error);
}

.pms-shell .btn-success,
.pms-shell .btngreen {
    color: var(--ui-success);
    background: var(--ui-success-soft);
    border-color: rgba(22, 132, 91, 0.25);
}

.pms-shell .btn-success:hover,
.pms-shell .btngreen:hover {
    color: #fff;
    background: var(--ui-success);
    border-color: var(--ui-success);
}

.pms-shell .btn-link {
    color: var(--ui-accent);
    background: transparent;
    border-color: transparent;
}

.pms-shell .pms-action-cell {
    display: table-cell;
    white-space: nowrap;
}

.pms-shell .pms-action-cell .btn,
.pms-shell td:last-child .btn.btn-sm {
    width: 34px;
    min-width: 34px;
    height: 34px;
    min-height: 34px;
    padding: 0;
}

/* Tables and list controls */
.pms-shell .table-responsive {
    max-width: 100%;
    overflow-x: auto;
    border-radius: 0 0 var(--ui-radius-lg) var(--ui-radius-lg);
    scrollbar-width: thin;
    scrollbar-color: #cfd1d4 transparent;
}

.pms-shell table.table {
    width: 100%;
    margin-bottom: 0;
    color: var(--ui-text);
    font-size: 13px;
    background: var(--ui-surface);
    border: 0;
    border-collapse: separate;
    border-spacing: 0;
}

.pms-shell table.table thead th,
.pms-shell .tablehead {
    position: sticky;
    top: 0;
    z-index: 2;
    padding: 11px 12px;
    color: #5c6470;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.02em;
    line-height: 1.35;
    vertical-align: middle;
    background: #f7f8f9;
    border: 0;
    border-bottom: 1px solid var(--ui-border-strong);
}

.pms-shell table.table tbody td {
    padding: 12px;
    color: var(--ui-text);
    font-size: 13px;
    line-height: 1.45;
    vertical-align: middle;
    background: var(--ui-surface);
    border: 0;
    border-bottom: 1px solid var(--ui-border);
}

.pms-shell table.table-bordered th,
.pms-shell table.table-bordered td {
    border-right: 0;
    border-left: 0;
}

.pms-shell table.table-striped tbody tr:nth-of-type(odd) td,
.pms-shell table.table-striped tbody tr:nth-of-type(even) td {
    background: var(--ui-surface);
}

.pms-shell table.table tbody tr:hover td:not(.pms-empty-state-row) {
    background: var(--ui-brand-subtle);
}

.pms-shell table.table tbody tr:last-child td {
    border-bottom: 0;
}

.pms-shell .text-nowrap {
    white-space: nowrap;
}

.pms-shell .dataTables_wrapper {
    padding: 0;
    color: var(--ui-text-muted);
    font-size: 12px;
}

.pms-shell .dataTables_wrapper .dataTables_length,
.pms-shell .dataTables_wrapper .dataTables_filter,
.pms-shell .dataTables_wrapper .dataTables_info,
.pms-shell .dataTables_wrapper .dataTables_paginate {
    padding: 12px 16px;
}

.pms-shell .dataTables_wrapper .dataTables_filter input,
.pms-shell .dataTables_wrapper .dataTables_length select {
    height: 36px;
    padding: 6px 10px;
    border: 1px solid var(--ui-border-strong);
    border-radius: var(--ui-radius-md);
}

.pms-shell .pagination {
    gap: 4px;
    margin: 0;
}

.pms-shell .pagination .page-link {
    display: inline-flex;
    min-width: 34px;
    height: 34px;
    align-items: center;
    justify-content: center;
    padding: 5px 9px;
    color: var(--ui-text-muted);
    font-size: 12px;
    background: var(--ui-surface);
    border: 1px solid var(--ui-border);
    border-radius: var(--ui-radius-md);
}

.pms-shell .pagination .page-link:hover {
    color: var(--ui-accent);
    background: var(--ui-brand-soft);
    border-color: var(--ui-brand);
}

.pms-shell .pagination .active .page-link {
    color: #fff;
    background: var(--ui-accent);
    border-color: var(--ui-accent);
}

.pms-shell .badge {
    padding: 5px 8px;
    font-size: 11px;
    font-weight: 600;
    line-height: 1.2;
    border-radius: var(--ui-radius-pill);
}

.pms-shell .badge-primary,
.pms-shell .badge-info {
    color: var(--ui-accent-text);
    background: var(--ui-brand-soft);
}

.pms-shell .badge-success {
    color: var(--ui-success);
    background: var(--ui-success-soft);
}

.pms-shell .badge-warning {
    color: var(--ui-warning);
    background: var(--ui-warning-soft);
}

.pms-shell .badge-danger {
    color: var(--ui-error);
    background: var(--ui-error-soft);
}

.pms-empty-state-row td {
    padding: 42px 20px !important;
    color: var(--ui-text-muted) !important;
    text-align: center !important;
    background: var(--ui-surface) !important;
}

/* Assignment list */
.pms-shell .pms-task-page-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.pms-shell .pms-task-page-heading h1 {
    margin: 0;
}

.pms-shell .pms-task-index-card {
    overflow: hidden;
}

.pms-shell .pms-task-list-header {
    display: flex;
    min-height: 76px;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 16px 18px;
}

.pms-shell .pms-task-list-header h2,
.pms-shell .pms-task-export-heading h3 {
    color: var(--ui-text-strong);
    font-weight: 600;
}

.pms-shell .pms-task-quick-filter {
    display: grid;
    width: min(100%, 740px);
    grid-template-columns: minmax(220px, 1fr) minmax(190px, 240px) auto auto;
    align-items: center;
    gap: 8px;
}

.pms-shell .pms-task-search-control {
    position: relative;
}

.pms-shell .pms-task-search-control > i {
    position: absolute;
    top: 50%;
    left: 13px;
    z-index: 1;
    color: var(--ui-text-subtle);
    font-size: 12px;
    pointer-events: none;
    transform: translateY(-50%);
}

.pms-shell .pms-task-search-control .form-control {
    padding-left: 36px;
}

.pms-shell .pms-task-export-panel {
    display: grid;
    grid-template-columns: 190px minmax(0, 1fr);
    align-items: end;
    gap: 20px;
    padding: 14px 18px 16px;
    background: var(--ui-surface-soft);
    border-bottom: 1px solid var(--ui-border);
}

.pms-shell .pms-task-export-heading {
    display: flex;
    align-items: center;
    gap: 10px;
    padding-bottom: 4px;
}

.pms-shell .pms-task-export-heading h3 {
    margin: 0;
    font-size: 14px !important;
}

.pms-shell .pms-task-export-heading div > span {
    display: block;
    margin-top: 2px;
    color: var(--ui-text-muted);
    font-size: 12px;
    line-height: 1.35;
}

.pms-shell .pms-task-export-icon {
    display: inline-flex;
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    align-items: center;
    justify-content: center;
    color: var(--ui-accent);
    background: var(--ui-brand-soft);
    border: 1px solid rgba(36, 36, 36, 0.14);
    border-radius: var(--ui-radius-md);
}

.pms-shell .pms-task-export-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(128px, 0.75fr)) repeat(3, minmax(150px, 1fr)) auto;
    align-items: end;
    gap: 10px;
}

.pms-shell .pms-task-export-field {
    min-width: 0;
}

.pms-shell .pms-task-export-field label {
    display: block;
}

.pms-shell .pms-task-export-button {
    white-space: nowrap;
}

.pms-shell .pms-task-list-table,
.pms-shell .pms-task-index-card > .table-responsive {
    border-radius: 0;
}

.pms-shell .pms-task-list-grid thead th {
    white-space: nowrap;
}

.pms-shell .pms-task-list-grid tbody td {
    white-space: normal;
}

.pms-shell .pms-task-list-grid {
    min-width: 1100px;
    border: 1px solid var(--ui-border);
    border-collapse: separate;
    border-spacing: 0;
}

.pms-shell .pms-task-list-grid thead th,
.pms-shell .pms-task-list-grid tbody td {
    border-right: 1px solid var(--ui-border) !important;
    border-bottom: 1px solid var(--ui-border) !important;
    text-align: center;
    vertical-align: middle !important;
}

.pms-shell .pms-task-list-grid thead th {
    border-bottom-color: var(--ui-border-strong) !important;
}

.pms-shell .pms-task-list-grid thead th:last-child,
.pms-shell .pms-task-list-grid tbody td:last-child {
    border-right: 0 !important;
}

.pms-shell .pms-task-list-grid tbody tr:last-child td {
    border-bottom: 0 !important;
}

.pms-shell .pms-task-list-grid tbody tr.is-completed td {
    background: var(--ui-success-soft);
}

.pms-shell .pms-task-list-grid tbody tr.is-completed:hover td {
    background: #def1e9;
}

.pms-shell .pms-task-list-grid .linkcolor a {
    color: var(--ui-text-strong);
    font-weight: 600;
}

.pms-shell .pms-task-list-grid .linkcolor a:hover {
    color: var(--ui-accent);
}

.pms-shell .pms-task-list-grid .pms-action-cell {
    min-width: 98px;
}

.pms-shell .pms-task-list-grid .pms-action-btn {
    width: 34px;
    min-width: 34px;
    height: 34px;
    min-height: 34px !important;
    color: var(--ui-accent-text) !important;
    background: var(--ui-brand-soft) !important;
    border: 1px solid rgba(36, 36, 36, 0.18) !important;
    border-radius: var(--ui-radius-md);
}

.pms-shell .pms-task-list-grid .pms-action-btn:hover,
.pms-shell .pms-task-list-grid .pms-action-btn:focus-visible {
    color: var(--ui-accent-hover) !important;
    background: #e9eaec !important;
    border-color: var(--ui-brand) !important;
    outline: 0;
    box-shadow: var(--ui-ring) !important;
}

.pms-shell .pms-task-list-grid .pms-action-delete {
    color: var(--ui-error) !important;
    background: var(--ui-error-soft) !important;
    border-color: rgba(220, 69, 69, 0.28) !important;
}

.pms-shell .pms-task-list-grid .pms-action-delete:hover,
.pms-shell .pms-task-list-grid .pms-action-delete:focus-visible {
    color: #fff !important;
    background: var(--ui-error) !important;
    border-color: var(--ui-error) !important;
}

.pms-shell .pms-task-status {
    display: inline-flex;
    align-items: center;
    padding: 5px 8px;
    color: var(--ui-text-muted);
    font-size: 11px;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
    background: var(--ui-hover);
    border-radius: var(--ui-radius-pill);
}

.pms-shell .pms-task-status--completed {
    color: var(--ui-success);
    background: var(--ui-success-soft);
}

.pms-shell .pms-task-status--wip {
    color: #45625b;
    background: var(--ui-info-soft);
}

.pms-shell .pms-task-status--pending {
    color: var(--ui-error);
    background: var(--ui-error-soft);
}

.pms-shell .pms-task-empty-state {
    display: flex;
    min-height: 210px;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 40px 20px;
    color: var(--ui-text-muted);
    text-align: center;
    background: var(--ui-surface);
}

.pms-shell .pms-task-empty-icon {
    display: inline-flex;
    width: 48px;
    height: 48px;
    align-items: center;
    justify-content: center;
    color: var(--ui-accent);
    background: var(--ui-brand-soft);
    border-radius: 50%;
}

.pms-shell .pms-task-empty-state h3 {
    margin: 0;
    color: var(--ui-text-strong);
}

.pms-shell .pms-task-empty-state .btn {
    margin-top: 2px;
}

.pms-shell .pms-filter-heading-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
}

.pms-shell .pms-filter-heading-actions .btn {
    white-space: nowrap;
}

.pms-shell .pms-task-filter-card {
    overflow: hidden;
}

.pms-shell .pms-task-filter-form {
    padding: 18px;
    background: var(--ui-surface);
    border-bottom: 1px solid var(--ui-border);
}

.pms-shell .pms-task-filter-fields {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    align-items: end;
    gap: 12px;
}

.pms-shell .pms-task-filter-field {
    min-width: 0;
    grid-column: auto;
}

.pms-shell .pms-task-filter-field label {
    display: block;
}

.pms-shell .pms-task-filter-search {
    grid-column: span 2;
}

.pms-shell .pms-task-filter-search .input-group .form-control {
    min-width: 0;
}

.pms-shell .pms-task-filter-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

.pms-shell .pms-task-filter-results {
    display: none;
}

.pms-shell .pms-task-filter-table {
    padding: 0 !important;
    border-radius: 0;
}

.pms-shell .pms-task-filter-grid {
    min-width: 900px;
}

.pms-shell .pms-task-filter-grid tbody td {
    vertical-align: middle;
}

.pms-shell .pms-task-filter-grid .linkcolor a {
    color: var(--ui-text-strong);
    font-weight: 600;
}

/* Client directory: light column rules make the compact grid easier to scan. */
.pms-shell table.pms-client-table--compact {
    border: 1px solid var(--ui-border);
}

.pms-shell table.pms-client-table--compact thead th,
.pms-shell table.pms-client-table--compact tbody td {
    border-right: 1px solid var(--ui-border) !important;
    border-bottom: 1px solid var(--ui-border) !important;
    vertical-align: middle !important;
    text-align: center;
}

.pms-shell table.pms-client-table--compact thead th:last-child,
.pms-shell table.pms-client-table--compact tbody td:last-child {
    border-right: 0 !important;
}

.pms-shell table.pms-client-table--compact thead th {
    border-bottom-color: var(--ui-border-strong) !important;
}

.pms-shell table.pms-client-table--compact tbody tr:last-child td {
    border-bottom: 0 !important;
}

.pms-shell .pms-activity-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.pms-shell .pms-activity-toolbar h2 {
    color: var(--ui-text-strong);
}

.pms-shell .pms-activity-filters {
    display: grid;
    width: min(100%, 860px);
    grid-template-columns: minmax(220px, 1fr) minmax(150px, 200px) minmax(150px, 180px) auto auto;
    align-items: center;
    gap: 8px;
}

.pms-shell .pms-activity-table-wrap {
    border-radius: 0;
}

.pms-shell .pms-activity-table {
    min-width: 760px;
}

.pms-shell .pms-activity-table th:first-child,
.pms-shell .pms-activity-timestamp {
    min-width: 155px;
    white-space: nowrap;
}

.pms-shell .pms-activity-task-link {
    display: block;
    color: var(--ui-text-strong);
    font-weight: 600;
}

.pms-shell .pms-activity-meta {
    display: block;
    margin-top: 3px;
    color: var(--ui-text-muted);
    font-size: 12px;
}

.pms-shell .pms-activity-changes {
    min-width: 360px;
}

.pms-shell .pms-activity-change {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 6px;
    padding: 3px 0;
    font-size: 13px;
}

.pms-shell .pms-activity-change strong {
    min-width: 110px;
}

.pms-shell .pms-activity-change span {
    max-width: 220px;
    overflow-wrap: anywhere;
}

.pms-shell .pms-activity-change i {
    color: var(--ui-accent);
    font-size: 11px;
}

.pms-shell .pms-activity-created {
    display: inline-flex;
    padding: 5px 9px;
    color: var(--ui-success);
    font-size: 12px;
    font-weight: 600;
    background: var(--ui-success-soft);
    border-radius: var(--ui-radius-pill);
}

/* Dashboard */
.pms-shell .pms-kpi-card {
    position: relative;
    display: grid;
    min-height: 150px;
    grid-template-columns: 42px 1fr;
    grid-template-rows: 1fr auto;
    gap: 12px;
    margin-bottom: 18px;
    padding: 18px;
    color: var(--ui-text);
    background: var(--ui-surface);
    border: 1px solid var(--ui-border);
    border-radius: var(--ui-radius-lg);
    box-shadow: var(--ui-shadow-sm);
}

.pms-shell .pms-kpi-card:hover {
    color: var(--ui-text);
    border-color: var(--ui-brand);
    box-shadow: var(--ui-shadow-md);
    transform: translateY(-2px);
}

.pms-shell .pms-kpi-icon {
    display: inline-flex;
    width: 42px;
    height: 42px;
    align-items: center;
    justify-content: center;
    color: var(--ui-accent);
    background: var(--ui-brand-soft);
    border-radius: 10px;
}

.pms-shell .pms-kpi-copy {
    display: flex;
    min-width: 0;
    flex-direction: column;
}

.pms-shell .pms-kpi-label {
    color: var(--ui-text-muted);
    font-size: 12px;
    font-weight: 500;
}

.pms-shell .pms-kpi-value {
    margin-top: 3px;
    color: var(--ui-text-strong);
    font-size: 24px;
    font-weight: 650;
    letter-spacing: -0.03em;
    line-height: 1.2;
}

.pms-shell .pms-kpi-meta {
    margin-top: 3px;
    color: var(--ui-text-muted);
    font-size: 12px;
}

.pms-shell .pms-kpi-link {
    grid-column: 1 / -1;
    color: var(--ui-accent);
    font-size: 12px;
    font-weight: 600;
}

.pms-shell .pms-kpi-link i {
    margin-left: 4px;
    font-size: 10px;
}

.pms-shell .small-box.card {
    min-height: 138px;
    overflow: hidden;
}

.pms-shell .small-box.card > .inner {
    padding: 18px;
}

.pms-shell .small-box.card .inner h3,
.pms-shell .small-box.card .inner h4,
.pms-shell .pms-dashboard-grid .small-box .inner h3[style] {
    margin: 0;
    color: var(--ui-text-strong) !important;
    font-size: 24px;
    font-weight: 650;
    letter-spacing: -0.03em;
}

.pms-shell .small-box.card .inner p,
.pms-shell .pms-dashboard-grid .small-box .inner p[style] {
    margin: 6px 0 0;
    color: var(--ui-text-muted) !important;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0;
}

.pms-shell .small-box.card .icon {
    display: none;
}

.pms-shell .small-box.card .small-box-footer {
    display: flex;
    min-height: 36px;
    align-items: center;
    justify-content: flex-end;
    padding: 7px 14px;
    color: var(--ui-accent) !important;
    background: var(--ui-surface-soft);
    border-top: 1px solid var(--ui-border);
}

.pms-shell .small-box.card .small-box-footer i,
.pms-shell .small-box.card .small-box-footer i[style] {
    color: var(--ui-accent) !important;
}

.pms-shell .pms-chart-card canvas {
    max-height: 300px;
}

.pms-shell .pms-panel-badge,
.pms-shell .pms-filter-result {
    color: var(--ui-accent-text);
    background: var(--ui-brand-soft);
    border: 1px solid rgba(36, 36, 36, 0.14);
    border-radius: var(--ui-radius-pill);
}

.pms-shell .pms-revenue-item {
    border-color: var(--ui-border);
}

/* Alerts, modals and feedback */
.pms-shell .alert {
    padding: 12px 14px;
    color: var(--ui-text);
    font-size: 13px;
    background: var(--ui-surface);
    border: 1px solid var(--ui-border);
    border-left-width: 4px;
    border-radius: var(--ui-radius-md);
    box-shadow: var(--ui-shadow-sm);
}

.pms-shell .alert-success {
    color: #115f43;
    background: var(--ui-success-soft);
    border-color: rgba(22, 132, 91, 0.22);
    border-left-color: var(--ui-success);
}

.pms-shell .alert-danger {
    color: #a02f2f;
    background: var(--ui-error-soft);
    border-color: rgba(220, 69, 69, 0.22);
    border-left-color: var(--ui-error);
}

.pms-shell .alert-warning {
    color: #242424;
    background: var(--ui-warning-soft);
    border-color: rgba(185, 108, 16, 0.22);
    border-left-color: var(--ui-warning);
}

.pms-shell .alert-info {
    color: #38514b;
    background: var(--ui-info-soft);
    border-color: rgba(79, 107, 101, 0.22);
    border-left-color: var(--ui-info);
}

.pms-shell .modal-content {
    color: var(--ui-text);
    background: var(--ui-surface);
    border: 1px solid var(--ui-border);
    border-radius: var(--ui-radius-lg);
    box-shadow: 0 24px 72px rgba(24, 24, 27, 0.18);
}

.pms-shell .modal-header,
.pms-shell .modal-footer {
    padding: 14px 18px;
    border-color: var(--ui-border);
}

.pms-shell .modal-body {
    padding: 18px;
}

.pms-shell .modal-title {
    font-size: 16px;
    font-weight: 600;
}

.pms-shell .close {
    color: var(--ui-text-muted);
    text-shadow: none;
    opacity: 1;
}

.swal2-popup {
    font-family: Inter, "Segoe UI", Roboto, Helvetica, Arial, sans-serif !important;
    border: 1px solid var(--ui-border) !important;
    border-radius: var(--ui-radius-lg) !important;
    box-shadow: 0 24px 72px rgba(24, 24, 27, 0.18) !important;
}

.swal2-title {
    color: var(--ui-text-strong) !important;
    font-size: 18px !important;
}

.swal2-html-container {
    color: var(--ui-text-muted) !important;
    font-size: 14px !important;
}

.swal2-confirm {
    background: var(--ui-accent) !important;
    border-radius: var(--ui-radius-md) !important;
    box-shadow: none !important;
}

.swal2-popup.pms-birthday-popup {
    width: min(440px, calc(100vw - 32px));
    padding: 28px 24px;
    border-top: 4px solid var(--ui-success) !important;
}

.pms-birthday-popup .swal2-title { margin-top: 8px; font-size: 24px !important; }
.pms-birthday-popup .swal2-html-container { color: var(--ui-text) !important; line-height: 1.6; }
.pms-birthday-popup .swal2-confirm { min-height: 44px; padding: 10px 20px; }
.pms-birthday-popup .swal2-close:focus-visible,
.pms-birthday-popup .swal2-confirm:focus-visible { outline: 2px solid var(--ui-accent); outline-offset: 3px; }

/* Authentication */
.login-page {
    min-height: 100vh;
    padding: 24px;
    color: var(--ui-text);
    font-family: Inter, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background: var(--ui-bg);
}

.login-page::before {
    background: radial-gradient(circle at top left, rgba(36, 36, 36, 0.08), transparent 36%);
}

.login-page .login-box {
    width: min(420px, calc(100vw - 28px)) !important;
}

.login-page .login-bg {
    padding: 24px;
    background-color: var(--ui-bg) !important;
    background-image: radial-gradient(circle at 15% 10%, rgba(36, 36, 36, 0.08), transparent 32%),
        radial-gradient(circle at 90% 85%, rgba(36, 36, 36, 0.05), transparent 28%) !important;
}

.login-page .card {
    background: var(--ui-surface);
    border: 1px solid var(--ui-border);
    border-radius: var(--ui-radius-lg);
    box-shadow: var(--ui-shadow-md);
}

.login-page .card-header,
.login-page .card-body {
    padding: 22px;
}

.login-page .card-header {
    background: var(--ui-surface);
    border-bottom: 1px solid var(--ui-border);
}

.pms-auth-brand {
    color: #111;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 28px;
    font-weight: 600;
    letter-spacing: -0.045em;
    line-height: 1.1;
}

.pms-auth-title {
    margin-top: 7px;
    color: var(--ui-text-muted);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.login-page .login-box-msg {
    padding: 0 0 18px;
    color: var(--ui-text-muted);
    font-size: 13px;
}

.login-page .input-group-text {
    min-width: 40px;
    justify-content: center;
    color: var(--ui-text-muted);
    background: var(--ui-surface-soft);
    border-color: var(--ui-border-strong);
}

.login-page a {
    color: var(--ui-accent);
    font-size: 13px;
    font-weight: 500;
}

.login-page .pms-auth-switch-link {
    display: inline-block;
    min-width: 104px;
    font-size: 13px !important;
    font-weight: 500;
    line-height: 20px;
    text-align: right;
    white-space: nowrap;
}

.login-page .form-control {
    height: var(--ui-control-height);
    color: var(--ui-text);
    font-size: 14px;
    background: var(--ui-surface);
    border: 1px solid var(--ui-border-strong);
    border-radius: var(--ui-radius-md);
}

.login-page .form-control:focus {
    border-color: var(--ui-brand);
    box-shadow: var(--ui-ring);
}

.login-page .btn-primary,
.login-page .btnblack,
.login-page .btnblue {
    min-height: 42px;
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    background: var(--ui-accent) !important;
    border: 1px solid var(--ui-accent) !important;
    border-radius: var(--ui-radius-md);
}

.login-page .btn-primary:hover,
.login-page .btn-primary:focus {
    background: var(--ui-accent-hover) !important;
    border-color: var(--ui-accent-hover) !important;
    box-shadow: var(--ui-ring) !important;
}

.login-page .login-switch-panel {
    background: rgba(253, 248, 238, 0.72);
}

/* Legacy colour neutralisation — final layer intentionally removes dark blue. */
.pms-shell .bg-primary,
.pms-shell .bg-info,
.pms-shell .bg-blue,
.pms-shell .bg-navy {
    color: var(--ui-accent-text) !important;
    background-color: var(--ui-brand-soft) !important;
}

.pms-shell .text-primary,
.pms-shell .text-info,
.pms-shell .text-blue,
.pms-shell [style*="#2323d9"],
.pms-shell [style*="#100efc"],
.pms-shell [style*="#1e3a8a"],
.pms-shell [style*="#2563eb"] {
    color: var(--ui-accent) !important;
}

.pms-shell td .pms-entity-balance-link,
.pms-shell .pms-closing-summary strong {
    color: var(--ui-accent) !important;
}

.pms-shell .popup-content {
    border-left-color: var(--ui-brand) !important;
}

.pms-shell .pms-person-badge,
.pms-shell .pms-assignee-name,
.pms-shell .pms-owner-avatar {
    color: var(--ui-accent-text) !important;
    background: var(--ui-brand-soft) !important;
    border-color: rgba(36, 36, 36, 0.14) !important;
}

.pms-shell .pms-revenue-copy strong,
.pms-shell .pms-pending-row:hover,
.pms-shell .pms-pending-row strong,
.pms-shell .pms-task-form .pms-task-section h2,
.pms-shell .pms-task-create-grid > .pms-task-section h2 {
    color: var(--ui-accent-text) !important;
}

.pms-shell .pms-dashboard-grid .pms-stat-col .small-box.card::before {
    background: var(--ui-brand) !important;
}

.pms-shell .pms-task-create-grid > .pms-task-section {
    border-top-color: var(--ui-border) !important;
    border-left-color: var(--ui-brand) !important;
}

.pms-shell .nav-sidebar .pms-sidebar-toggle:hover,
.pms-shell .nav-sidebar .pms-sidebar-toggle:focus-visible {
    color: var(--ui-accent-text) !important;
    background: var(--ui-brand-soft) !important;
    border-color: var(--ui-brand) !important;
}

/*
 * Compatibility typography overrides. The legacy stylesheet enforces a global
 * 18px ceiling with !important, so these narrowly-scoped declarations restore
 * the documented enterprise scale without affecting third-party widgets.
 */
body.pms-shell h1,
body.pms-shell .h1,
body.pms-shell .content-header h1 {
    font-size: var(--ui-font-page-title) !important;
    line-height: 1.25 !important;
}

body.pms-shell h2,
body.pms-shell .h2,
body.pms-shell .pms-panel-heading h2 {
    font-size: var(--ui-font-section-title) !important;
    line-height: 1.35 !important;
}

body.pms-shell h3,
body.pms-shell .h3,
body.pms-shell .card-title,
body.pms-shell .modal-title {
    font-size: var(--ui-font-card-title) !important;
    line-height: 1.4 !important;
}

body.pms-shell h4,
body.pms-shell .h4,
body.pms-shell h5,
body.pms-shell .h5,
body.pms-shell h6,
body.pms-shell .h6 {
    font-size: 15px !important;
}

body.pms-shell .pms-kpi-value,
body.pms-shell .small-box .inner h3,
body.pms-shell .pms-dashboard-grid .small-box .inner h3 {
    font-size: 24px !important;
    line-height: 1.2 !important;
}

body.pms-shell .pms-header-kicker,
body.pms-shell .nav-sidebar > .nav-header,
body.pms-shell .pms-eyebrow,
body.pms-shell .badge {
    font-size: 11px !important;
}

body.pms-shell .nav-sidebar .nav-link,
body.pms-shell table.table tbody td,
body.pms-shell .dropdown-item,
body.pms-shell .btn,
body.pms-shell .pms-kpi-label,
body.pms-shell .pms-kpi-meta {
    font-size: var(--ui-font-button) !important;
}

body.pms-shell table.table thead th,
body.pms-shell label,
body.pms-shell .form-label,
body.pms-shell .btn-sm,
body.pms-shell .small,
body.pms-shell small,
body.pms-shell .form-text,
body.pms-shell .invalid-feedback,
body.pms-shell .pms-page-subtitle {
    font-size: var(--ui-font-caption) !important;
}

body.pms-shell .form-control,
body.pms-shell .custom-select,
body.pms-shell textarea,
body.pms-shell select,
body.pms-shell input {
    font-size: var(--ui-font-control) !important;
}

.login-page .pms-auth-brand {
    font-size: 28px !important;
}

.login-page .pms-auth-title {
    font-size: 12px !important;
}

.login-page .pms-auth-feedback {
    display: flex;
    flex-direction: column;
    gap: 3px;
    margin-bottom: 18px;
    padding: 11px 13px;
    font-size: 13px;
    line-height: 1.45;
    border-radius: var(--ui-radius-md);
}
.login-page .pms-auth-feedback strong { font-size: 13px; }
.login-page .input-group .invalid-feedback { width: 100%; margin: 5px 0 0; }

/* AdminLTE collapsed state */
@media (min-width: 992px) {
    .sidebar-mini.sidebar-collapse .main-sidebar,
    .sidebar-mini.sidebar-collapse .main-sidebar::before {
        width: 74px;
    }

    .sidebar-mini.sidebar-collapse .main-header,
    .sidebar-mini.sidebar-collapse .content-wrapper,
    .sidebar-mini.sidebar-collapse .main-footer {
        margin-left: 74px;
    }

    .sidebar-mini.sidebar-collapse .main-sidebar .brand-link {
        justify-content: center;
        padding-right: 10px;
        padding-left: 10px;
    }

    .sidebar-mini.sidebar-collapse .main-sidebar .brand-image {
        width: 38px !important;
        height: 38px;
        object-fit: cover;
        object-position: left;
    }

    .sidebar-mini.sidebar-collapse .nav-sidebar .nav-link {
        justify-content: center;
        padding-right: 10px;
        padding-left: 10px;
    }

    .sidebar-mini.sidebar-collapse .nav-sidebar .nav-link p,
    .sidebar-mini.sidebar-collapse .nav-sidebar .nav-header {
        display: none;
    }

    .sidebar-mini.sidebar-collapse .nav-sidebar .nav-link .nav-icon {
        margin: 0;
    }
}

/* Responsive shell */
@media (max-width: 1199.98px) {
    :root {
        --ui-sidebar-width: 240px;
    }

    .pms-shell .pms-kpi-card {
        min-height: 140px;
    }

    .pms-shell .pms-task-export-panel {
        grid-template-columns: 1fr;
        align-items: start;
        gap: 12px;
    }

    .pms-shell .pms-task-export-form {
        grid-template-columns: repeat(3, minmax(150px, 1fr));
    }

    .pms-shell .pms-task-filter-fields {
        grid-template-columns: repeat(6, minmax(0, 1fr));
    }

    .pms-shell .pms-task-filter-field {
        grid-column: span 2;
    }

    .pms-shell .pms-task-filter-search {
        grid-column: 1 / -1;
    }
}

@media (max-width: 991.98px) {
    body.pms-shell {
        overflow-x: hidden;
    }

    body.pms-shell:not(.layout-fixed) .main-sidebar {
        height: 100dvh;
    }

    .pms-shell .main-header,
    .pms-shell .content-wrapper,
    .pms-shell .main-footer {
        margin-left: 0;
    }

    .pms-shell .main-header {
        min-height: 58px;
        padding: 0 14px;
    }

    .pms-shell .main-sidebar {
        position: fixed;
        top: 0;
        bottom: 0;
        left: 0;
        z-index: 1045;
        width: min(288px, calc(100vw - 44px));
        max-width: calc(100vw - 44px);
        height: 100dvh;
        margin-left: 0 !important;
        overflow: hidden;
        visibility: visible !important;
        transform: translateX(-100%);
        transition: transform var(--ui-transition);
        box-shadow: 18px 0 48px rgba(24, 24, 27, 0.12);
    }

    .pms-shell .main-sidebar::before {
        width: 100%;
    }

    .pms-shell.sidebar-open .main-sidebar {
        transform: translateX(0);
    }

    .pms-shell.sidebar-open {
        overflow: hidden;
    }

    .pms-shell .brand-link {
        justify-content: flex-start;
        padding-right: 62px;
    }

    .pms-shell .brand-link .brand-image {
        max-width: 160px;
    }

    .pms-shell .sidebar {
        height: calc(100dvh - var(--ui-header-height));
        overscroll-behavior: contain;
    }

    .pms-shell .mobilecloseicon {
        display: flex !important;
        width: 44px;
        height: 44px;
        align-items: center;
        justify-content: center;
        cursor: pointer;
    }

    .pms-shell .pms-collapse-item {
        display: none !important;
    }

    .pms-sidebar-backdrop {
        position: fixed;
        inset: 0;
        z-index: 1040;
        display: block;
        padding: 0;
        background: rgba(36, 36, 36, 0.38);
        border: 0;
        opacity: 0;
        visibility: hidden;
        transition: opacity var(--ui-transition), visibility var(--ui-transition);
    }

    .pms-shell.sidebar-open .pms-sidebar-backdrop {
        opacity: 1;
        visibility: visible;
    }

    body.pms-shell .content-header {
        padding: 20px 16px 8px;
    }

    body.pms-shell .content {
        padding-right: 16px;
        padding-left: 16px;
    }

    .pms-header-message {
        display: none;
    }

    .pms-shell .pms-task-list-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .pms-shell .pms-task-quick-filter {
        width: 100%;
    }

    .pms-shell .pms-activity-toolbar {
        align-items: flex-start;
        flex-direction: column;
    }

    .pms-shell .pms-activity-filters {
        width: 100%;
    }
}

@media (max-width: 767.98px) {
    .pms-shell h1,
    .pms-shell .h1,
    .pms-shell .content-header h1 {
        font-size: 22px !important;
    }

    body.pms-shell .content-header {
        padding-top: 16px;
    }

    .pms-shell .card-header,
    .pms-shell .card-body,
    .pms-shell .card-footer {
        padding-right: 14px;
        padding-left: 14px;
    }

    .pms-shell .card-header > .row,
    .pms-shell .card > .row.align-items-center {
        row-gap: 12px;
    }

    .pms-shell .card > .row.align-items-center > [class*="col-"] {
        width: 100%;
        max-width: 100%;
        flex: 0 0 100%;
        justify-content: flex-start !important;
    }

    .pms-shell .form-control,
    .pms-shell .custom-select,
    .pms-shell .select2-container--default .select2-selection--single,
    .pms-shell .select2-container--default .select2-selection--multiple {
        min-height: 44px;
    }

    .pms-shell .btn {
        min-height: 40px;
    }

    .pms-shell .table-responsive {
        border-top: 1px solid var(--ui-border);
        border-radius: 0;
        -webkit-overflow-scrolling: touch;
    }

    .pms-shell table.table {
        min-width: 720px;
    }

    .pms-shell table.table thead th,
    .pms-shell table.table tbody td {
        padding: 10px;
    }

    .pms-shell .modal-dialog {
        margin: 12px;
    }

    .pms-shell .modal-body {
        max-height: calc(100vh - 140px);
        overflow-y: auto;
    }

    .pms-shell .pms-kpi-card {
        min-height: 132px;
        padding: 16px;
    }

    .pms-shell .pms-task-page-heading {
        align-items: stretch;
        flex-direction: column;
    }

    .pms-shell .pms-task-page-heading .btn {
        align-self: flex-start;
    }

    .pms-shell .pms-task-quick-filter {
        grid-template-columns: minmax(0, 1fr) minmax(160px, 0.7fr) auto;
    }

    .pms-shell .pms-task-quick-filter > .btn-secondary {
        grid-column: 1 / -1;
        justify-self: start;
    }

    .pms-shell .pms-task-export-form {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .pms-shell .pms-task-export-button {
        width: 100%;
    }

    .pms-shell .pms-task-filter-fields {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .pms-shell .pms-task-filter-field,
    .pms-shell .pms-task-filter-search {
        grid-column: auto;
    }

    .pms-shell .pms-task-filter-search {
        grid-column: 1 / -1;
    }

    .pms-shell .pms-activity-filters {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .pms-shell .pms-activity-search {
        grid-column: 1 / -1;
    }
}

@media (max-width: 575.98px) {
    body.pms-shell .content {
        padding-right: 12px;
        padding-left: 12px;
    }

    body.pms-shell .content-header {
        padding-right: 12px;
        padding-left: 12px;
    }

    .pms-shell .pms-notification-menu {
        display: list-item;
    }

    .pms-shell .main-header [data-widget="fullscreen"] {
        display: none;
    }

    .pms-shell .main-header .dropdown-menu {
        right: 8px;
        left: auto;
    }

    .pms-shell .pms-action-cell .btn,
    .pms-shell td:last-child .btn.btn-sm {
        width: 38px;
        min-width: 38px;
        height: 38px;
    }

    .login-page {
        padding: 14px;
    }

    .login-page .login-bg {
        padding: 14px;
    }

    .login-page .login-box {
        width: calc(100vw - 28px) !important;
    }

    .login-page .card-header,
    .login-page .card-body {
        padding: 18px;
    }

    .login-page .login-switch-panel {
        min-height: auto;
        padding: 20px 0 0;
        background: transparent;
        border-left: 0 !important;
    }

    .pms-shell .pms-task-list-header,
    .pms-shell .pms-task-export-panel {
        padding-right: 14px;
        padding-left: 14px;
    }

    .pms-shell .pms-task-quick-filter,
    .pms-shell .pms-task-export-form {
        grid-template-columns: 1fr;
    }

    .pms-shell .pms-task-quick-filter > .btn,
    .pms-shell .pms-task-quick-filter > .btn-secondary {
        width: 100%;
        grid-column: auto;
    }

    .pms-shell .pms-task-filter-fields,
    .pms-shell .pms-activity-filters {
        grid-template-columns: 1fr;
    }

    .pms-shell .pms-task-filter-search,
    .pms-shell .pms-activity-search {
        grid-column: auto;
    }

    .pms-shell .pms-task-filter-actions .btn,
    .pms-shell .pms-filter-heading-actions .btn,
    .pms-shell .pms-activity-filters .btn {
        width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .pms-header-message .marquee-text {
        transform: none !important;
    }
}

@media print {
    .pms-shell .main-sidebar,
    .pms-shell .main-header,
    .pms-shell .main-footer,
    .pms-shell .btn,
    .pms-shell .pms-action-cell {
        display: none !important;
    }

    .pms-shell .content-wrapper {
        margin: 0 !important;
        background: #fff;
    }

    .pms-shell .card {
        border-color: #d8dadd;
        box-shadow: none;
    }
}

/* Employee task creation: clear task-first grouping with compact enterprise spacing. */
.pms-shell .pms-employee-task-create .pms-employee-form-section {
    margin: 4px 0 14px;
    padding: 10px 12px;
    background: var(--ui-hover);
    border: 1px solid var(--ui-border);
    border-left: 3px solid var(--ui-brand);
    border-radius: 0 var(--ui-radius-md) var(--ui-radius-md) 0;
}

.pms-shell .pms-employee-task-create .pms-employee-form-section h2 {
    margin: 0;
    color: var(--ui-accent-text);
    font-size: 14px;
    font-weight: 650;
    line-height: 1.35;
}

.pms-shell .pms-employee-task-create > .card {
    border: 1px solid var(--ui-border);
    border-radius: var(--ui-radius-lg);
    box-shadow: 0 2px 8px rgba(25, 35, 45, .04);
}

.pms-shell .pms-employee-task-create .mb-3 {
    margin-bottom: 14px !important;
}

.pms-shell .pms-employee-task-create label {
    color: var(--ui-text-strong);
    font-size: 12px;
    font-weight: 600;
}

.pms-shell .pms-employee-task-create input[type="radio"] {
    accent-color: var(--ui-brand);
}

.pms-shell .pms-employee-task-create .pms-choice-group {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 16px;
    min-height: 32px;
}

.pms-shell .pms-employee-task-create .pms-choice-option {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 32px;
    margin: 0;
    color: var(--ui-text-strong);
    font-size: 13px;
    font-weight: 500;
    line-height: 1.3;
    cursor: pointer;
}

.pms-shell .pms-employee-task-create .pms-choice-option input[type="radio"] {
    flex: 0 0 16px;
    width: 16px !important;
    height: 16px !important;
    min-height: 16px !important;
    margin: 0;
    padding: 0;
    appearance: auto;
    cursor: pointer;
}

.pms-shell .pms-employee-task-create #contact_no {
    font-variant-numeric: tabular-nums;
}

.pms-shell .pms-owner-companies-table th,
.pms-shell .pms-owner-companies-table td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--ui-border);
    vertical-align: middle;
}

.pms-shell .pms-owner-companies-table th {
    color: var(--ui-text-muted);
    background: var(--ui-hover);
    font-size: 12px;
    font-weight: 650;
    letter-spacing: .02em;
}

.pms-shell .pms-owner-companies-table .pms-owner-company-action {
    display: inline-flex;
    width: auto !important;
    min-width: 108px;
    min-height: 36px;
    align-items: center;
    justify-content: center;
    padding: 7px 12px;
    white-space: nowrap;
    line-height: 1.2;
}

.pms-shell .pms-task-list-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.pms-shell .pms-task-management-title {
    flex: 0 0 auto;
    text-align: left;
}

.pms-shell .pms-task-management-title .pms-eyebrow {
    text-align: left;
}

.pms-shell .pms-task-quick-filter {
    width: min(100%, 740px);
    margin-left: auto;
}

body.pms-shell table.table.pms-task-list-grid thead th,
body.pms-shell table.table.pms-task-list-grid tbody td {
    font-size: 12px !important;
}

body.pms-shell table.table.pms-task-list-grid tbody td a,
body.pms-shell table.table.pms-task-list-grid tbody td span,
body.pms-shell table.table.pms-task-list-grid tbody td .badge,
body.pms-shell table.table.pms-task-list-grid tbody td .pms-tag-name,
body.pms-shell table.table.pms-task-list-grid tbody td .pms-task-status {
    font-size: 12px !important;
    line-height: 1.35 !important;
}

body.pms-shell table.table.pms-task-list-grid thead th {
    font-size: 11px !important;
}

body.pms-shell table.table.pms-task-list-grid tbody td {
    padding: 8px 6px !important;
    line-height: 1.35 !important;
}

@media (max-width: 767.98px) {
    .pms-shell .pms-task-list-header {
        align-items: stretch;
        flex-direction: column;
    }

    .pms-shell .pms-task-quick-filter {
        grid-template-columns: minmax(0, 1fr);
    }
}

.pms-shell .pms-employee-task-create .gov-entry,
.pms-shell .pms-employee-task-create .pocket-entry {
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid var(--ui-border);
}

/* Employee assignment table: centered cells and visible, restrained column rules. */
.pms-shell .pms-employee-task-table-wrap {
    overflow-x: auto;
}

.pms-shell .pms-employee-task-list {
    width: 100%;
    min-width: 1120px;
    margin-bottom: 0;
    border: 1px solid var(--ui-border);
    border-collapse: separate;
    border-spacing: 0;
}

.pms-shell .pms-employee-task-list > thead > tr > th,
.pms-shell .pms-employee-task-list > tbody > tr > td {
    padding: 11px 9px;
    border-right: 1px solid var(--ui-border) !important;
    border-bottom: 1px solid var(--ui-border) !important;
    text-align: center;
    vertical-align: middle !important;
    font-size: 13px;
}

.pms-shell .pms-employee-task-list > thead > tr > th {
    color: var(--ui-text-muted);
    background: #f7f8f9;
    border-bottom-color: var(--ui-border-strong) !important;
    font-size: 12px;
    font-weight: 650;
    white-space: nowrap;
}

.pms-shell .pms-employee-task-list > thead > tr > th:last-child,
.pms-shell .pms-employee-task-list > tbody > tr > td:last-child {
    border-right: 0 !important;
}

.pms-shell .pms-employee-task-list > tbody > tr:last-child > td {
    border-bottom: 0 !important;
}

.pms-shell .pms-employee-task-list .pms-icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    margin: 0 2px;
}

.pms-shell .pms-employee-empty-state {
    display: grid;
    justify-items: center;
    gap: 6px;
    padding: 32px 16px;
    color: var(--ui-text-muted);
}

.pms-shell .pms-employee-empty-state i {
    margin-bottom: 4px;
    color: var(--ui-brand);
    font-size: 22px;
}

.pms-shell .pms-employee-empty-state strong {
    color: var(--ui-text-strong);
    font-size: 14px;
}

.pms-shell .pms-employee-empty-state span {
    font-size: 12px;
}

/* Compact client and accounting directories */
.pms-shell .pms-directory-card {
    overflow: visible;
}

.pms-shell .pms-directory-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px 18px;
    padding: 18px 20px;
    border-bottom: 1px solid var(--ui-border);
}

.pms-shell .pms-client-list-card .pms-directory-toolbar {
    padding: 12px 18px;
}

.pms-shell .pms-client-page-heading,
.pms-shell .pms-client-list-card {
    width: 100%;
    max-width: 1200px;
    margin-right: auto;
    margin-left: auto;
}

.pms-shell .pms-client-list-header .pms-directory-search {
    width: min(100%, 520px);
    margin-left: auto;
}

.pms-shell .pms-client-toolbar-main {
    display: flex;
    min-width: 0;
    flex: 1 1 auto;
    align-items: center;
    gap: 24px;
}

.pms-shell .pms-client-toolbar-main h1 {
    flex: 0 0 auto;
}

.pms-shell .pms-client-toolbar-main .pms-directory-search {
    width: min(100%, 460px);
}

.pms-shell .pms-client-list-card .pms-directory-actions {
    margin-left: auto;
}

.pms-shell .pms-client-list-card .card-footer {
    padding: 8px 16px;
}

.pms-shell .pms-client-list-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px 24px;
}

.pms-shell .pms-client-list-total {
    display: inline-flex;
    align-items: baseline;
    gap: 8px;
    color: var(--ui-text-muted);
    font-size: 12px;
}

.pms-shell .pms-client-list-total strong {
    color: var(--ui-text-strong);
    font-size: 13px;
    font-variant-numeric: tabular-nums;
}

.pms-shell .pms-client-list-pagination {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 16px;
    margin-left: auto;
    color: var(--ui-text-muted);
    font-size: 12px;
}

.pms-shell .pms-client-list-pagination nav,
.pms-shell .pms-client-list-pagination .pagination {
    margin: 0;
}

.pms-shell .pms-directory-toolbar h1 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    text-transform: uppercase;
}

.pms-shell .pms-directory-subtitle {
    margin: 4px 0 0;
    color: var(--ui-text-muted);
    font-size: 12px;
}

.pms-shell .pms-directory-search,
.pms-shell .pms-directory-actions,
.pms-shell .pms-directory-row-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.pms-shell .pms-directory-search {
    width: min(100%, 380px);
}

.pms-shell .pms-directory-search .form-control {
    min-width: 120px;
    flex: 1;
}

.pms-shell .pms-directory-table,
.pms-shell .pms-ledger-table {
    table-layout: fixed;
    width: 100%;
}

.pms-shell .pms-directory-table th,
.pms-shell .pms-directory-table td {
    overflow-wrap: anywhere;
    border-right: 1px solid var(--ui-border) !important;
}

body.pms-shell table.table.pms-directory-table tbody td,
body.pms-shell table.table.pms-directory-table tbody td .pms-text-action,
body.pms-shell table.table.pms-directory-table tbody td .pms-tag-name {
    font-size: 12px !important;
    line-height: 1.4;
}

.pms-shell .pms-directory-table th:last-child,
.pms-shell .pms-directory-table td:last-child {
    border-right: 0 !important;
}

.pms-shell .pms-directory-table th:first-child,
.pms-shell .pms-directory-table td:first-child {
    width: 80px;
}

.pms-shell .pms-directory-table thead th:first-child,
.pms-shell .pms-ledger-table thead th:first-child,
.pms-shell .pms-task-list-grid thead th:first-child {
    white-space: nowrap;
    overflow-wrap: normal;
}

.pms-shell .pms-directory-table th:last-child,
.pms-shell .pms-directory-table td:last-child {
    width: 170px;
}

.pms-shell .pms-directory-table .pms-tag-name {
    display: inline-block;
    margin: 2px;
}

.pms-shell .pms-client-owner-table-wrap {
    overflow-x: auto;
}

.pms-shell .pms-client-owner-table {
    min-width: 960px;
    table-layout: fixed;
}

.pms-shell .pms-client-owner-table th,
.pms-shell .pms-client-owner-table td {
    vertical-align: middle;
}

.pms-shell .pms-client-owner-table th:first-child,
.pms-shell .pms-client-owner-table td:first-child {
    width: 6%;
    text-align: center;
}

.pms-shell .pms-client-owner-table th:nth-child(2),
.pms-shell .pms-client-owner-table td:nth-child(2) {
    width: 37%;
    text-align: left;
}

.pms-shell .pms-client-owner-table th:nth-child(3),
.pms-shell .pms-client-owner-table td:nth-child(3) {
    width: 30%;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

.pms-shell .pms-client-owner-table th:nth-child(4),
.pms-shell .pms-client-owner-table td:nth-child(4) {
    width: 17%;
    text-align: center;
}

.pms-shell .pms-client-owner-table th:last-child,
.pms-shell .pms-client-owner-table td:last-child {
    width: 10%;
    text-align: center;
}

.pms-shell .pms-client-owner-link {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    min-height: 38px;
    min-width: 0;
    line-height: 1.35;
}

.pms-shell .pms-client-owner-name {
    flex: 1 1 auto;
    min-width: 0;
    overflow-wrap: anywhere;
}

.pms-shell .pms-client-owner-company-count {
    flex: 0 0 auto;
    margin-left: auto;
    padding: 4px 8px;
    color: var(--ui-text-muted);
    background: var(--ui-surface-soft);
    border: 1px solid var(--ui-border);
    border-radius: var(--ui-radius-pill);
    font-size: 11px;
    font-weight: 500;
    line-height: 1.2;
    white-space: nowrap;
}

.pms-shell .pms-client-owner-contact a {
    color: var(--ui-text-strong);
    font-weight: 500;
    white-space: nowrap;
}

.pms-shell .pms-client-owner-contact a:hover {
    color: var(--ui-accent);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.pms-shell .pms-client-owner-modal-title {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.pms-shell .pms-client-owner-modal-title .pms-ginnie {
    flex-basis: 48px;
    width: 48px;
    height: 48px;
}

.pms-shell .pms-client-owner-table td:last-child form {
    margin: 0;
}

body.pms-shell .pms-client-owner-table td:last-child .btn.pms-client-owner-delete {
    width: 30px;
    min-width: 30px;
    height: 30px;
    min-height: 30px;
    padding: 0;
}

body.pms-shell table.table.pms-client-companies-table th,
body.pms-shell table.table.pms-client-companies-table td {
    padding: 10px 12px !important;
    font-size: 12px !important;
    line-height: 1.4;
    vertical-align: middle;
    overflow-wrap: normal;
    word-break: normal;
    border-bottom: 1px solid var(--ui-border) !important;
}

.pms-shell .pms-client-companies-table th:first-child,
.pms-shell .pms-client-companies-table td:first-child {
    width: 51%;
    text-align: left;
}

.pms-shell .pms-client-companies-table th:nth-child(2),
.pms-shell .pms-client-companies-table td:nth-child(2) {
    width: 22%;
    white-space: nowrap;
}

.pms-shell .pms-client-companies-table th:nth-child(3),
.pms-shell .pms-client-companies-table td:nth-child(3) {
    width: 8%;
    text-align: center;
}

.pms-shell .pms-client-companies-table th:last-child,
.pms-shell .pms-client-companies-table td:last-child {
    width: 19%;
    text-align: center;
}

.pms-shell .pms-client-companies-table .pms-directory-row-actions {
    justify-content: center;
    flex-wrap: nowrap;
    gap: 6px;
}

body.pms-shell .pms-client-companies-table td:last-child .pms-directory-row-actions .btn.btn-sm {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    min-width: 34px;
    height: 34px;
    min-height: 34px;
    padding: 0;
}

/* Keep the owner list and its company popup as compact, fully divided tables. */
body.pms-shell table.table.pms-client-owner-table,
body.pms-shell table.table.pms-client-companies-table {
    border-top: 1px solid var(--ui-border) !important;
    border-left: 1px solid var(--ui-border) !important;
}

body.pms-shell table.table.pms-client-owner-table thead th,
body.pms-shell table.table.pms-client-owner-table tbody td,
body.pms-shell table.table.pms-client-companies-table thead th,
body.pms-shell table.table.pms-client-companies-table tbody td {
    border-right: 1px solid var(--ui-border) !important;
    border-bottom: 1px solid var(--ui-border) !important;
}

body.pms-shell table.table.pms-client-owner-table thead th {
    padding: 11px 14px !important;
    color: #5c6470;
    background: #f7f8f9;
    font-size: 11px !important;
    font-weight: 650;
    line-height: 1.3;
}

body.pms-shell table.table.pms-client-owner-table tbody td {
    padding: 8px 14px !important;
    font-size: 12px !important;
    line-height: 1.35;
}

body.pms-shell table.table.pms-client-owner-table tbody tr:nth-child(even) td {
    background: #fbfbfc;
}

body.pms-shell table.table.pms-client-owner-table tbody tr:hover td {
    background: var(--ui-brand-subtle);
}

body.pms-shell table.table.pms-client-companies-table thead th,
body.pms-shell table.table.pms-client-companies-table tbody td {
    padding: 8px 10px !important;
}

body.pms-shell table.table.pms-client-owner-table tr > :last-child,
body.pms-shell table.table.pms-client-companies-table tr > :last-child {
    border-right: 1px solid var(--ui-border) !important;
}

.pms-shell .pms-text-action {
    padding: 0;
    border: 0;
    background: none;
    color: var(--ui-text-strong);
    font-weight: 600;
    text-align: left;
    cursor: pointer;
}

.pms-shell .pms-text-action:hover,
.pms-shell .pms-text-action:focus-visible {
    color: var(--ui-accent);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.pms-shell .pms-directory-count {
    display: block;
    margin-top: 2px;
    color: var(--ui-text-muted);
    font-size: 12px;
    font-weight: 400;
}

.pms-shell .pms-directory-row-actions .btn,
.pms-shell .pms-directory-table td:last-child .btn.btn-sm {
    width: auto;
    min-width: 0;
    height: auto;
    min-height: 34px;
    padding: 6px 10px;
}

.pms-shell .pms-directory-row-actions form {
    margin: 0;
}

.pms-shell .pms-account-total {
    color: var(--ui-text-muted);
    font-size: 12px;
}

.pms-shell .pms-account-total strong {
    margin-left: 6px;
    color: var(--ui-error);
    font-size: 16px;
    white-space: nowrap;
}

.pms-shell .pms-account-summary-table th:nth-child(3),
.pms-shell .pms-account-summary-table td:nth-child(3) {
    width: 165px;
}

.pms-shell .pms-account-summary-table th:last-child,
.pms-shell .pms-account-summary-table td:last-child {
    width: 42%;
}

.pms-shell .pms-account-expand i {
    margin-right: 8px;
    color: var(--ui-text-muted);
    font-size: 10px;
    transition: transform 150ms ease;
}

.pms-shell .pms-account-expand[aria-expanded="true"] i {
    transform: rotate(90deg);
}

.pms-shell .pms-account-company-remarks {
    text-align: left;
}

.pms-shell .pms-account-company-remarks span {
    display: block;
    margin: 0;
}

.pms-shell .pms-account-company-line {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: baseline;
    gap: 6px 14px;
    padding: 4px 0;
    text-align: left;
}

.pms-shell .pms-account-company-line + .pms-account-company-line { border-top: 1px solid var(--ui-border); }
.pms-shell .pms-account-company-line > span { min-width: 0; overflow-wrap: anywhere; }
.pms-shell .pms-account-company-line > strong { text-align: right; }

.pms-shell .pms-account-company-remarks strong {
    white-space: nowrap;
}

.pms-shell .pms-account-detail-row > td {
    width: 100% !important;
    background: var(--ui-surface-soft) !important;
}

.pms-shell .pms-account-company-section {
    padding: 12px;
    border-bottom: 1px solid var(--ui-border);
}

.pms-shell .pms-account-company-heading {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 16px;
    margin-bottom: 10px;
    font-size: 12px;
}

.pms-shell .pms-account-company-heading .btn {
    margin-left: auto;
}

.pms-shell .pms-owner-company-list .pms-account-company-heading {
    margin-bottom: 0;
}

body.pms-shell table.table.pms-owner-company-table,
body.pms-shell table.table.pms-retainership-table {
    border-top: 1px solid var(--ui-border) !important;
    border-left: 1px solid var(--ui-border) !important;
}

body.pms-shell table.table.pms-owner-company-table th,
body.pms-shell table.table.pms-owner-company-table td,
body.pms-shell table.table.pms-retainership-table th,
body.pms-shell table.table.pms-retainership-table td {
    padding: 8px 10px !important;
    font-size: 12px !important;
    line-height: 1.35;
    vertical-align: middle;
    border-right: 1px solid var(--ui-border) !important;
    border-bottom: 1px solid var(--ui-border) !important;
}

.pms-shell .pms-owner-company-table th:first-child,
.pms-shell .pms-owner-company-table td:first-child {
    width: 75px;
    text-align: center;
    white-space: nowrap;
}

.pms-shell .pms-owner-company-table th:nth-child(3),
.pms-shell .pms-owner-company-table td:nth-child(3) {
    width: 175px;
    text-align: right;
}

.pms-shell .pms-owner-company-table th:last-child,
.pms-shell .pms-owner-company-table td:last-child {
    width: 175px;
    text-align: center;
}

.pms-shell .pms-retainership-table {
    min-width: 1100px;
}

.pms-shell .pms-retainership-table th:first-child,
.pms-shell .pms-retainership-table td:first-child {
    width: 70px;
    text-align: center;
    white-space: nowrap;
}

.pms-shell .pms-retainership-table th:last-child,
.pms-shell .pms-retainership-table td:last-child {
    width: 100px;
}

.pms-shell .pms-retainership-table .pms-directory-row-actions {
    flex-wrap: nowrap;
}

body.pms-shell .content > .container-fluid > form.pms-retainership-form {
    max-width: none;
}

.pms-shell .pms-retainership-form .card-body {
    padding: 18px;
}

.pms-shell .pms-retainership-form h2 {
    margin: 0 0 16px;
}

.pms-shell .pms-retainership-fields {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 4px 16px;
}

.pms-shell .pms-retainership-scope {
    grid-column: span 2;
}

.pms-shell .pms-retainership-actions {
    display: flex;
    justify-content: flex-end;
}

.pms-shell .pms-retainership-table th,
.pms-shell .pms-retainership-table td {
    text-align: center;
}

.pms-shell .pms-retainership-table th:nth-child(3),
.pms-shell .pms-retainership-table td:nth-child(3),
.pms-shell .pms-retainership-table th:nth-child(4),
.pms-shell .pms-retainership-table td:nth-child(4) {
    text-align: left;
}

@media (min-width: 1200px) {
    body.pms-shell table.table.pms-retainership-table {
        min-width: 0;
        table-layout: fixed;
    }

    .pms-shell .pms-retainership-table th,
    .pms-shell .pms-retainership-table td {
        overflow-wrap: anywhere;
    }
}

@media (max-width: 991.98px) {
    .pms-shell .pms-retainership-fields {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 575.98px) {
    .pms-shell .pms-retainership-fields {
        grid-template-columns: 1fr;
    }

    .pms-shell .pms-retainership-scope {
        grid-column: auto;
    }
}

/* Consistent column and row dividers on the remaining admin lists. */
body.pms-admin-shell table.table.pms-account-summary-table,
body.pms-shell table.table.pms-price-table,
body.pms-admin-shell table.table.pms-staff-table,
body.pms-admin-shell table.table.pms-policies-table {
    border-top: 1px solid var(--ui-border) !important;
    border-left: 1px solid var(--ui-border) !important;
}

body.pms-admin-shell table.table.pms-account-summary-table thead th,
body.pms-admin-shell table.table.pms-account-summary-table tbody td,
body.pms-shell table.table.pms-price-table thead th,
body.pms-shell table.table.pms-price-table tbody td,
body.pms-admin-shell table.table.pms-staff-table thead th,
body.pms-admin-shell table.table.pms-staff-table tbody td,
body.pms-admin-shell table.table.pms-policies-table thead th,
body.pms-admin-shell table.table.pms-policies-table tbody td {
    border-right: 1px solid var(--ui-border) !important;
    border-bottom: 1px solid var(--ui-border) !important;
    vertical-align: middle;
}

body.pms-admin-shell table.table.pms-staff-table thead th:first-child,
body.pms-shell table.table.pms-price-table thead th:first-child,
body.pms-admin-shell table.table.pms-policies-table thead th:first-child {
    min-width: 72px;
    white-space: nowrap;
}

/* Staff directory: reserve name space and keep the date columns compact. */
body.pms-admin-shell table.table.pms-staff-table {
    width: 100%;
    min-width: 1320px;
    table-layout: fixed;
}
body.pms-admin-shell table.table.pms-staff-table > thead > tr > th,
body.pms-admin-shell table.table.pms-staff-table > tbody > tr > td {
    padding: 9px 7px;
    overflow-wrap: anywhere;
    white-space: normal;
}
body.pms-admin-shell table.table.pms-staff-table > tbody > tr > td:nth-child(2),
body.pms-admin-shell table.table.pms-staff-table > tbody > tr > td:nth-child(5),
body.pms-admin-shell table.table.pms-staff-table > tbody > tr > td:nth-child(6),
body.pms-admin-shell table.table.pms-staff-table > tbody > tr > td:nth-child(7) {
    white-space: nowrap;
    overflow-wrap: normal;
}

body.pms-shell table.table.pms-ledger-table th,
body.pms-shell table.table.pms-ledger-table td {
    padding: 8px 5px;
    font-size: 12px !important;
    line-height: 1.35;
    vertical-align: middle;
    overflow-wrap: anywhere;
    border-right: 1px solid var(--ui-border) !important;
    border-bottom: 1px solid var(--ui-border) !important;
}

body.pms-shell table.table.pms-ledger-table thead th {
    white-space: nowrap;
    overflow-wrap: normal;
}

.pms-shell .pms-closing-toolbar > div:first-child {
    min-width: 0;
    flex: 1 1 320px;
}

.pms-shell .pms-closing-toolbar h1 {
    overflow-wrap: break-word;
}

@media (min-width: 1501px) {
    body.pms-shell table.table.pms-ledger-table th:first-child,
    body.pms-shell table.table.pms-ledger-table td:first-child {
        width: 5.5%;
        min-width: 70px;
        padding-inline: 4px;
        text-align: center;
        white-space: nowrap;
        overflow-wrap: normal;
    }
}

.pms-shell .pms-ledger-table th:nth-child(2),
.pms-shell .pms-ledger-table td:nth-child(2),
.pms-shell .pms-ledger-table th:nth-child(10),
.pms-shell .pms-ledger-table td:nth-child(10) {
    width: 7%;
}

.pms-shell .pms-ledger-table th:nth-child(10),
.pms-shell .pms-ledger-table td:nth-child(10) {
    width: 8%;
}

.pms-shell .pms-ledger-table th:nth-child(3),
.pms-shell .pms-ledger-table td:nth-child(3),
.pms-shell .pms-ledger-table th:nth-child(4),
.pms-shell .pms-ledger-table td:nth-child(4) {
    width: 13%;
}

.pms-shell .pms-ledger-table th:nth-child(5),
.pms-shell .pms-ledger-table td:nth-child(5),
.pms-shell .pms-ledger-table th:nth-child(6),
.pms-shell .pms-ledger-table td:nth-child(6),
.pms-shell .pms-ledger-table th:nth-child(7),
.pms-shell .pms-ledger-table td:nth-child(7),
.pms-shell .pms-ledger-table th:nth-child(8),
.pms-shell .pms-ledger-table td:nth-child(8),
.pms-shell .pms-ledger-table th:nth-child(11),
.pms-shell .pms-ledger-table td:nth-child(11) {
    width: 9%;
}

.pms-shell .pms-ledger-table th:nth-child(9),
.pms-shell .pms-ledger-table td:nth-child(9) {
    width: 5%;
}

.pms-shell .pms-ledger-table th:last-child,
.pms-shell .pms-ledger-table td:last-child {
    border-right: 0 !important;
}

.pms-shell .pms-money {
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.pms-shell .pms-money--strong {
    font-weight: 700;
}

.pms-shell .pms-ledger-edit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    margin-left: 4px;
    border: 1px solid var(--ui-border-strong);
    border-radius: 6px;
    background: var(--ui-surface);
    color: var(--ui-text);
    cursor: pointer;
}

.pms-shell .pms-ledger-edit:hover {
    background: var(--ui-hover);
}

.pms-shell .pms-closing-totals {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 8px 18px;
    padding: 16px 20px;
    border-top: 1px solid var(--ui-border);
    font-size: 12px;
}

.pms-shell .pms-closing-totals strong {
    color: var(--ui-text-strong);
    font-size: 15px;
    white-space: nowrap;
}

body.pms-shell table.table tbody td,
body.pms-shell .pms-client-details dd {
    font-size: 12px !important;
}

.pms-shell .btnorange,
.pms-shell .btn-warning,
.pms-shell .pms-task-list-grid .pms-action-btn:not(.pms-action-delete) {
    color: var(--ui-text) !important;
    background: var(--ui-hover) !important;
    border-color: var(--ui-border-strong) !important;
}

.pms-shell .btnorange:hover,
.pms-shell .btn-warning:hover,
.pms-shell .pms-task-list-grid .pms-action-btn:not(.pms-action-delete):hover {
    color: var(--ui-text-strong) !important;
    background: #e9eaec !important;
    border-color: #c8c9cd !important;
}

@media (max-width: 1500px) {
    .pms-shell .pms-ledger-table,
    .pms-shell .pms-ledger-table tbody,
    .pms-shell .pms-ledger-table tr,
    .pms-shell .pms-ledger-table td {
        display: block;
        width: 100% !important;
    }
    .pms-shell .pms-ledger-table thead {
        display: none;
    }
    .pms-shell .pms-ledger-table tbody tr {
        padding: 10px;
        border-bottom: 1px solid var(--ui-border);
    }
    .pms-shell .pms-ledger-table tbody td {
        display: flex;
        justify-content: space-between;
        gap: 12px;
        padding: 5px 0;
        text-align: right;
        border: 0 !important;
    }
    .pms-shell .pms-ledger-table tbody td::before {
        content: attr(data-label);
        flex: 0 0 44%;
        color: var(--ui-text-muted);
        font-weight: 600;
        text-align: left;
    }
}

@media (max-width: 600px) {
    .pms-shell .pms-directory-toolbar {
        padding: 16px;
    }
    .pms-shell .pms-directory-search {
        order: 3;
        width: 100%;
    }
    .pms-shell .pms-directory-table th:first-child,
    .pms-shell .pms-directory-table td:first-child {
        width: 44px;
    }
    .pms-shell .pms-directory-table th:last-child,
    .pms-shell .pms-directory-table td:last-child {
        width: 94px;
    }
    .pms-shell .pms-client-owner-table th:first-child,
    .pms-shell .pms-client-owner-table td:first-child {
        width: 80px;
    }
    .pms-shell .pms-account-summary-table thead th:last-child,
    .pms-shell .pms-account-summary-table tbody tr:not(.pms-account-detail-row) > td:last-child {
        display: none;
    }
    .pms-shell .modal .pms-directory-table,
    .pms-shell .modal .pms-directory-table tbody,
    .pms-shell .modal .pms-directory-table tr,
    .pms-shell .modal .pms-directory-table td {
        display: block;
        width: 100% !important;
    }
    .pms-shell .modal .pms-directory-table thead {
        display: none;
    }
    .pms-shell .modal .pms-directory-table tbody tr {
        padding: 10px;
        border-bottom: 1px solid var(--ui-border);
    }
    .pms-shell .modal .pms-directory-table tbody td {
        display: flex;
        justify-content: space-between;
        gap: 12px;
        padding: 6px 0;
        text-align: right;
        border: 0 !important;
    }
    .pms-shell .modal .pms-directory-table tbody td::before {
        content: attr(data-label);
        flex: 0 0 38%;
        color: var(--ui-text-muted);
        font-weight: 600;
        text-align: left;
    }
}

@media (prefers-reduced-motion: reduce) {
    .pms-shell .pms-account-expand i {
        transition: none;
    }
}

/* Shared admin tables: consistent dividers and centered headings/values. */
body.pms-admin-shell .content table.table {
    border-top: 1px solid var(--ui-border) !important;
    border-left: 1px solid var(--ui-border) !important;
    border-collapse: separate;
    border-spacing: 0;
}

body.pms-admin-shell .content table.table > thead > tr > th,
body.pms-admin-shell .content table.table > tbody > tr > td {
    border-right: 1px solid var(--ui-border) !important;
    border-bottom: 1px solid var(--ui-border) !important;
    vertical-align: middle;
}

body.pms-admin-shell table.table > thead > tr > th,
body.pms-admin-shell table.table > tbody > tr > td,
body.pms-admin-shell table.table > tfoot > tr > td {
    text-align: center !important;
}

body.pms-admin-shell table.table .pms-directory-row-actions {
    justify-content: center;
}

/* Center only the heading; keep owner names aligned with the row content. */
body.pms-admin-shell table.table.pms-client-owner-table > thead > tr > th:nth-child(2) {
    text-align: center !important;
}

body.pms-admin-shell table.table.pms-client-owner-table > tbody > tr > td:nth-child(2) {
    text-align: left !important;
}

/* Legacy price-list rules use an ID and !important, so match that specificity. */
body.pms-admin-shell #myTable.pms-price-table > thead > tr > th,
body.pms-admin-shell #myTable.pms-price-table > tbody > tr > td {
    text-align: center !important;
    border-right: 1px solid var(--ui-border) !important;
    border-bottom: 1px solid var(--ui-border) !important;
}

.pms-shell .pms-account-list-header .pms-directory-search {
    width: min(100%, 520px);
    margin-left: auto;
}

body.pms-shell .content > .container-fluid > form.pms-task-form {
    max-width: none;
}

.pms-shell .pms-account-summary-table th,
.pms-shell .pms-account-summary-table td,
.pms-shell .pms-task-filter-grid th,
.pms-shell .pms-task-filter-grid td {
    text-align: center;
}

/* Keep the search filters and collapsed results usable without desktop scrolling. */
body.pms-shell .pms-task-filter-form {
    display: flex;
    align-items: end;
    gap: 12px;
    padding: 12px 14px;
}

body.pms-shell .pms-task-filter-fields {
    display: grid;
    flex: 1 1 auto;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
}

body.pms-shell .pms-task-filter-field {
    grid-column: auto;
}

body.pms-shell .pms-task-filter-actions {
    flex: 0 0 auto;
    margin: 0;
}

body.pms-shell table.table.pms-task-filter-grid {
    min-width: 0 !important;
    table-layout: fixed;
}

body.pms-shell .pms-task-filter-grid > thead > tr > th,
body.pms-shell .pms-task-filter-grid > tbody > tr > td {
    width: auto;
    min-width: 0 !important;
    padding: 7px 6px !important;
    font-size: 12px !important;
    line-height: 1.3;
    overflow-wrap: anywhere !important;
    white-space: normal !important;
}

body.pms-shell .pms-task-filter-grid > thead > tr > th:first-child,
body.pms-shell .pms-task-filter-grid > tbody > tr > td:first-child {
    width: 5%;
}

body.pms-shell .pms-task-filter-grid > thead > tr > th:nth-child(5),
body.pms-shell .pms-task-filter-grid > tbody > tr > td:nth-child(5) {
    width: 12%;
}

.pms-shell .pms-task-filter-grid tbody td a {
    display: inline-block;
    max-width: 100%;
}

.pms-shell .pms-task-filter-grid tbody td:nth-child(2) a,
.pms-shell .pms-task-filter-grid tbody td:nth-child(3) a,
.pms-shell .pms-task-filter-grid tbody td:nth-child(4) a {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pms-shell .pms-challan-details summary {
    color: var(--ui-accent);
    font-weight: 600;
    cursor: pointer;
}

.pms-shell .pms-challan-details table {
    margin-top: 6px;
    text-align: left;
}

.pms-shell .pms-task-filter-table::after {
    display: none;
}

@media (max-width: 1199.98px) {
    body.pms-shell .pms-task-filter-form {
        flex-wrap: wrap;
    }

    body.pms-shell .pms-task-filter-fields {
        flex-basis: 100%;
    }
}

@media (max-width: 767.98px) {
    body.pms-shell .pms-task-filter-fields {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    body.pms-shell table.table.pms-task-filter-grid {
        min-width: 850px !important;
    }
}

@media (max-width: 575.98px) {
    body.pms-shell .pms-task-filter-fields {
        grid-template-columns: 1fr;
    }
}

/* Salary-slip entry and print view */
.pms-shell .pms-salary-heading,
.pms-shell .pms-salary-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
}

.pms-shell .pms-salary-heading h1 { margin: 0; }
.pms-shell .pms-salary-form { display: grid; width: 100%; grid-template-columns: minmax(0, 1fr) 300px; align-items: start; gap: 16px; }
.pms-shell .pms-salary-form > .card { margin-bottom: 0; }
.pms-shell .pms-salary-form .card-body { padding: 16px; }
.pms-shell .pms-salary-form h2,
.pms-shell .pms-salary-preview h2 { margin: 0 0 12px; }
.pms-shell .pms-salary-form h2:not(:first-child) { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--ui-border); }
.pms-shell .pms-salary-fields { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2px 12px; }
.pms-shell .pms-salary-form .form-group { margin-bottom: 8px; }
.pms-shell .pms-salary-form label { margin-bottom: 4px; }
.pms-shell .pms-salary-form .form-control { height: 38px; min-height: 38px; padding: 6px 10px; }
.pms-shell .pms-salary-day-count { display: flex; flex-direction: column; justify-content: center; min-height: 62px; padding: 9px 12px; background: var(--ui-surface-soft); border: 1px solid var(--ui-border); border-radius: var(--ui-radius-md); }
.pms-shell .pms-salary-day-count span,
.pms-shell .pms-salary-preview-grid span { color: var(--ui-text-muted); font-size: 12px; }
.pms-shell .pms-salary-preview-grid span { min-width: 0; }
.pms-shell .pms-salary-day-count strong { font-size: 18px; }
.pms-shell .pms-salary-help { margin: 4px 0 10px; color: var(--ui-text-muted); font-size: 12px; }
.pms-shell .pms-salary-preview-grid { display: grid; grid-template-columns: 1fr; gap: 6px; margin-bottom: 10px; }
.pms-shell .pms-salary-preview-grid > div { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 10px; background: var(--ui-surface-soft); border: 1px solid var(--ui-border); border-radius: var(--ui-radius-md); }
.pms-shell .pms-salary-preview-grid strong { flex: 0 0 auto; font-size: 16px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.pms-shell .pms-salary-preview-grid .pms-salary-net { background: var(--ui-brand-soft); }
.pms-shell .pms-salary-list { min-width: 650px; }
.pms-shell .pms-salary-list td:last-child .btn { width: auto; height: auto; padding: 6px 10px; }
.pms-shell .pms-salary-row-actions { white-space: nowrap; }
.pms-shell .pms-salary-row-actions form { display: inline-block; margin: 0 0 0 4px; }
.pms-shell .pms-salary-actions form { margin: 0; }

.pms-shell .pms-salary-slip { --salary-ink: #242424; --salary-line: #d8d1c3; --salary-fill: #f8f4eb; --salary-gold: #a47b35; position: relative; display: flex; flex-direction: column; isolation: isolate; max-width: 850px; min-height: 980px; margin: 0 auto 24px; padding: 42px 38px 38px; color: var(--salary-ink); background: #fff; border: 1px solid var(--salary-line); box-shadow: var(--ui-shadow-sm); }
.pms-shell .pms-salary-slip > :not(.pms-salary-watermark) { position: relative; z-index: 1; }
.pms-shell .pms-salary-watermark { position: absolute; z-index: 0; top: 52%; left: 50%; width: min(88%, 690px); height: auto; opacity: .18; pointer-events: none; transform: translate(-50%, -50%); }
.pms-shell .pms-salary-slip-header { display: grid; grid-template-columns: 210px minmax(0, 1fr); align-items: center; gap: 22px; padding-bottom: 18px; border-bottom: 3px solid var(--salary-gold); }
.pms-shell .pms-salary-slip-logo { display: block; width: 100%; height: auto; align-self: start; object-fit: contain; filter: brightness(0); transform: translate(-8%, -20%); }
.pms-shell .pms-salary-slip-company { text-align: right; }
body.pms-shell .pms-salary-slip-header h2 { margin: 0 0 6px; color: var(--salary-ink) !important; font-size: 18px !important; font-weight: 700; letter-spacing: .015em; }
.pms-shell .pms-salary-slip-header p { margin: 3px 0; color: var(--salary-ink); font-size: 11px; }
body.pms-shell .pms-salary-slip-title { margin: 20px 0; padding: 10px 12px; color: var(--salary-ink) !important; background: var(--salary-fill); border-left: 4px solid var(--salary-gold); text-align: center; }
body.pms-shell .pms-salary-slip-title h3 { margin: 0; color: var(--salary-ink) !important; font-size: 18px !important; font-weight: 700; letter-spacing: .045em; }
.pms-shell .pms-salary-slip-details { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); margin-bottom: 22px; border-top: 1px solid var(--salary-line); border-left: 1px solid var(--salary-line); }
.pms-shell .pms-salary-slip-details > div { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); border-right: 1px solid var(--salary-line); border-bottom: 1px solid var(--salary-line); font-size: 12px; }
.pms-shell .pms-salary-slip-details > div:nth-child(4n + 1),
.pms-shell .pms-salary-slip-details > div:nth-child(4n + 2) { background: #f8fafc; }
.pms-shell .pms-salary-slip-details span { padding: 9px 11px; color: #625a4e; border-right: 1px solid var(--salary-line); }
.pms-shell .pms-salary-slip-details strong { padding: 9px 11px; color: var(--salary-ink); text-align: right; overflow-wrap: anywhere; }
.pms-shell .pms-salary-slip-tables { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; align-items: start; }
.pms-shell .pms-salary-slip-tables table { width: 100%; border-collapse: collapse; font-size: 12px; }
.pms-shell .pms-salary-slip-tables th,
.pms-shell .pms-salary-slip-tables td { padding: 10px 11px; color: var(--salary-ink); border: 1px solid var(--salary-line); }
.pms-shell .pms-salary-slip-tables thead th,
.pms-shell .pms-salary-total { color: var(--salary-ink); background: var(--salary-fill); font-weight: 700; }
.pms-shell .pms-salary-slip-tables tr > :last-child { text-align: right; white-space: nowrap; }
.pms-shell .pms-salary-slip-net { display: flex; justify-content: space-between; gap: 12px; margin-top: 20px; padding: 13px 16px; background: var(--salary-ink); border-left: 5px solid var(--salary-gold); color: #fff; font-size: 15px; }
.pms-shell .pms-salary-words { margin: 16px 0 0; color: var(--salary-ink); font-size: 12px; }
.pms-shell .pms-salary-slip-signatures { display: flex; justify-content: space-between; gap: 30px; margin-top: auto; padding-top: 78px; }
.pms-shell .pms-salary-slip-signatures > div { display: flex; min-width: 0; width: 45%; flex-direction: column; gap: 3px; padding: 0; text-align: left; font-size: 12px; }
.pms-shell .pms-salary-slip-signatures > div:last-child { text-align: right; }
.pms-shell .pms-salary-slip-signatures span { color: #625a4e; }
.pms-shell .pms-salary-slip-signatures strong { min-height: 20px; color: var(--salary-ink); font-size: 14px; }

@media (min-width: 1600px) {
    .pms-shell .pms-salary-fields { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 1199.98px) {
    .pms-shell .pms-salary-form { grid-template-columns: 1fr; }
    .pms-shell .pms-salary-preview-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .pms-shell .pms-salary-preview-grid > div { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 767.98px) {
    .pms-shell .pms-salary-fields,
    .pms-shell .pms-salary-preview-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pms-shell .pms-salary-slip { min-height: 0; padding: 24px 20px; }
    .pms-shell .pms-salary-slip-header { grid-template-columns: 1fr; gap: 8px; }
    .pms-shell .pms-salary-slip-logo { max-width: 190px; transform: none; }
    .pms-shell .pms-salary-slip-company { text-align: left; }
    .pms-shell .pms-salary-slip-signatures { padding-top: 36px; }
}

@media (max-width: 575.98px) {
    .pms-shell .pms-salary-fields,
    .pms-shell .pms-salary-preview-grid,
    .pms-shell .pms-salary-slip-details,
    .pms-shell .pms-salary-slip-tables { grid-template-columns: 1fr; }
    .pms-shell .pms-salary-slip-signatures { flex-direction: column; gap: 12px; }
    .pms-shell .pms-client-toolbar-main { width: 100%; flex-wrap: wrap; gap: 8px; }
    .pms-shell .pms-client-toolbar-main .pms-directory-search { width: 100%; }
}

@media print {
    @page { size: A4; margin: 25.4mm; }
    body.pms-shell { min-width: 0 !important; }
    .pms-shell .pms-salary-screen-only,
    .pms-shell .main-sidebar,
    .pms-shell .main-header,
    .pms-shell .main-footer { display: none !important; }
    .pms-shell .content-wrapper { margin: 0 !important; min-height: 0; background: #fff; }
    body.pms-shell .content { padding: 0 !important; }
    .pms-shell .content > .container-fluid { max-width: none; padding: 0; }
    .pms-shell .pms-salary-slip { box-sizing: border-box; width: 100%; max-width: 100%; min-width: 0; min-height: 246.2mm; margin: 0; padding: 0; border: 0; box-shadow: none; print-color-adjust: exact; -webkit-print-color-adjust: exact; }
    .pms-shell .pms-salary-watermark { width: 88%; opacity: .18; }
    .pms-shell .pms-salary-slip-header { grid-template-columns: 28% minmax(0, 1fr); align-items: center; gap: 5mm; padding-bottom: 12px; }
    .pms-shell .pms-salary-slip-logo { width: 100%; max-width: none; align-self: start; transform: translate(-8%, -20%); }
    .pms-shell .pms-salary-slip-company { min-width: 0; text-align: right; overflow-wrap: anywhere; }
    body.pms-shell .pms-salary-slip-title { margin: 12px 0; }
    .pms-shell .pms-salary-slip-details { width: 100%; min-width: 0; grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pms-shell .pms-salary-slip-details > div,
    .pms-shell .pms-salary-slip-details span,
    .pms-shell .pms-salary-slip-details strong { min-width: 0; overflow-wrap: anywhere; }
    .pms-shell .pms-salary-slip-details span,
    .pms-shell .pms-salary-slip-details strong { padding: 5px 7px; }
    .pms-shell .pms-salary-slip-tables { width: 100%; min-width: 0; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4mm; }
    .pms-shell .pms-salary-slip-tables table { min-width: 0; table-layout: fixed; }
    .pms-shell .pms-salary-slip-tables th,
    .pms-shell .pms-salary-slip-tables td { padding: 4px 6px; overflow-wrap: anywhere; }
    .pms-shell .pms-salary-slip-net { margin-top: 12px; }
    .pms-shell .pms-salary-words { margin-top: 10px; }
    .pms-shell .pms-salary-slip-signatures { flex-direction: row; justify-content: space-between; gap: 8mm; padding-top: 24px; }
    .pms-shell .pms-salary-slip-signatures > div { flex: 1 1 0; width: auto; }
}

/* Status highlights: red for outstanding work/dues, green for completed work. */
body.pms-shell .pms-kpi-card--warning .pms-kpi-icon {
    color: var(--ui-error);
    background: var(--ui-error-soft);
}

body.pms-shell .pms-kpi-card--warning .pms-kpi-value {
    color: var(--ui-error) !important;
}

body.pms-shell .pms-kpi-card--success .pms-kpi-icon {
    color: var(--ui-success);
    background: var(--ui-success-soft);
}

body.pms-shell .pms-kpi-card--success .pms-kpi-value {
    color: var(--ui-success) !important;
}

body.pms-shell .pms-balance--pending,
body.pms-shell table.table tbody td.pms-balance--pending,
body.pms-shell .pms-account-company-remarks strong {
    color: var(--ui-error) !important;
    font-weight: 700;
}

body.pms-shell .pms-balance--cleared,
body.pms-shell table.table tbody td.pms-balance--cleared {
    color: var(--ui-success) !important;
    font-weight: 700;
}

body.pms-shell table.table.pms-task-filter-grid tbody tr.pms-filter-row-completed > td {
    background: var(--ui-success-soft) !important;
}

/* Dashboard: compact, balanced metric cards and revenue panels. */
.pms-shell .pms-admin-dashboard .pms-kpi-col { margin-bottom: 12px; }
.pms-shell .pms-admin-dashboard .pms-kpi-card {
    min-height: 94px;
    grid-template-columns: 38px minmax(0, 1fr) 14px;
    grid-template-rows: 1fr;
    align-items: center;
    gap: 10px;
    margin: 0;
    padding: 14px;
    border-color: var(--ui-border-strong);
    box-shadow: 0 3px 12px rgba(24, 24, 27, .045);
}
.pms-shell .pms-admin-dashboard .pms-kpi-icon {
    width: 38px;
    height: 38px;
    grid-row: 1;
    font-size: 16px;
}
.pms-shell .pms-admin-dashboard .pms-kpi-copy { grid-row: 1; justify-content: center; }
.pms-shell .pms-admin-dashboard .pms-kpi-label { color: #52525b; font-size: 11px; }
body.pms-shell .pms-admin-dashboard .pms-kpi-value { margin-top: 3px; font-size: 23px !important; line-height: 1.1 !important; }
.pms-shell .pms-admin-dashboard .pms-kpi-arrow { color: var(--ui-text-muted); font-size: 11px; justify-self: end; }
.pms-shell .pms-admin-dashboard .pms-kpi-card:hover .pms-kpi-arrow { color: var(--ui-text-strong); transform: translateX(2px); }
.pms-shell .pms-admin-dashboard .pms-panel { border-color: var(--ui-border-strong); }
.pms-shell .pms-admin-dashboard .pms-revenue-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.pms-shell .pms-admin-dashboard .pms-revenue-item { align-items: flex-start; background: var(--ui-surface-soft); }

.pms-shell table.table.pms-salary-list { border: 1px solid var(--ui-border-strong); border-collapse: separate; border-spacing: 0; }
body.pms-shell table.table.pms-salary-list thead th,
body.pms-shell table.table.pms-salary-list tbody td {
    border-right: 1px solid var(--ui-border) !important;
    border-bottom: 1px solid var(--ui-border) !important;
    vertical-align: middle;
}
body.pms-shell table.table.pms-salary-list tr > :last-child { border-right: 0 !important; }

/* Task details: fixed column rhythm, readable rich-text and full table rules. */
.pms-shell .pms-task-details-dialog { max-width: min(1200px, calc(100vw - 32px)); }
.pms-shell .pms-task-details-modal .modal-body { max-height: calc(100vh - 170px); overflow-y: auto; padding: 20px; }
.pms-shell .pms-task-details-column { min-width: 0; }
.pms-shell .pms-task-details-column > .table { width: 100%; table-layout: fixed; margin-bottom: 18px; border: 1px solid var(--ui-border-strong) !important; }
body.pms-admin-shell .pms-task-details-column > .table th,
body.pms-admin-shell .pms-task-details-column > .table td {
    width: 50%;
    padding: 10px 12px !important;
    text-align: left !important;
    vertical-align: top !important;
    overflow-wrap: anywhere;
    border-right: 1px solid var(--ui-border-strong) !important;
    border-bottom: 1px solid var(--ui-border-strong) !important;
}
body.pms-admin-shell .pms-task-details-column > .table thead th { width: auto; padding: 10px 12px !important; background: #f5f6f7; text-align: left !important; }
.pms-shell .pms-task-details-column td strong { display: block; margin-bottom: 4px; color: var(--ui-text-muted); font-size: 11px; }
.pms-shell .pms-task-details-column td span { display: block; font-size: 13px; line-height: 1.5; }
.pms-shell .pms-task-rich-text,
.pms-shell #modalHistory td:nth-child(3) { white-space: pre-line; text-align: left !important; line-height: 1.5; }
.pms-shell #modalHistory td:nth-child(3) > div { padding-bottom: 8px; border-bottom: 1px solid var(--ui-border); }
.pms-shell #modalHistory td:nth-child(3) > div:last-child { padding-bottom: 0; border-bottom: 0; }
.pms-shell .pms-task-details-column h5 { margin: 20px 0 10px !important; }
@media (max-width: 991.98px) {
    .pms-shell .pms-task-details-dialog { max-width: calc(100vw - 24px); margin: 12px auto; }
    .pms-shell .pms-admin-dashboard .pms-revenue-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 575.98px) {
    .pms-shell .pms-task-details-modal .modal-body { padding: 12px; }
    .pms-shell .pms-admin-dashboard .pms-revenue-grid { grid-template-columns: 1fr; }
}

/* Admin dashboard: compact overview and data-first charts. */
body.pms-shell .pms-dashboard-heading { padding-bottom: 12px; }
.pms-shell .pms-admin-dashboard .container-fluid { max-width: 1580px; }
.pms-shell .pms-dashboard-metrics { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 10px; margin-bottom: 12px; }
.pms-shell .pms-dashboard-metric { display: flex; min-width: 0; min-height: 84px; align-items: center; flex-direction: column; justify-content: center; gap: 5px; padding: 9px 12px; color: var(--ui-text) !important; text-align: center; background: var(--ui-surface); border: 1px solid var(--ui-border); border-radius: var(--ui-radius-lg); box-shadow: var(--ui-shadow-sm); }
.pms-shell .pms-dashboard-metric:hover { border-color: var(--ui-border-strong); box-shadow: var(--ui-shadow-md); transform: translateY(-2px); }
.pms-shell .pms-dashboard-metric:focus-visible { outline: 2px solid var(--ui-accent); outline-offset: 2px; }
.pms-shell .pms-dashboard-metric-icon { display: grid; width: 28px; height: 28px; flex: 0 0 28px; place-items: center; color: var(--ui-text); background: var(--ui-hover); border-radius: 7px; font-size: 12px; }
.pms-shell .pms-dashboard-metric--success .pms-dashboard-metric-icon { color: var(--ui-success); background: var(--ui-success-soft); }
.pms-shell .pms-dashboard-metric--warning .pms-dashboard-metric-icon { color: var(--ui-error); background: var(--ui-error-soft); }
.pms-shell .pms-dashboard-metric-copy { display: flex; min-width: 0; flex-direction: column; align-items: center; justify-content: center; }
.pms-shell .pms-dashboard-metric-copy > span { color: var(--ui-text-muted); font-size: 11px; font-weight: 600; line-height: 1.2; overflow-wrap: anywhere; }
.pms-shell .pms-dashboard-metric-copy strong { color: var(--ui-text-strong); font-size: 21px; font-weight: 700; line-height: 1.1; font-variant-numeric: tabular-nums; }
.pms-shell .pms-dashboard-metric--success .pms-dashboard-metric-copy strong { color: var(--ui-success); }
.pms-shell .pms-dashboard-metric--warning .pms-dashboard-metric-copy strong { color: var(--ui-error); }
.pms-shell .pms-dashboard-insights { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(310px, 1fr); gap: 12px; margin-bottom: 12px; }
.pms-shell .pms-dashboard-panel { min-width: 0; margin: 0 !important; padding: 16px 18px; border-color: var(--ui-border) !important; box-shadow: var(--ui-shadow-sm); }
.pms-shell .pms-dashboard-panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.pms-shell .pms-dashboard-kicker { display: block; margin-bottom: 2px; color: var(--ui-text-muted); font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
body.pms-shell .pms-dashboard-panel h2 { margin: 0; color: var(--ui-text-strong); font-size: 16px !important; line-height: 1.25 !important; }
.pms-shell .pms-dashboard-period { padding: 5px 9px; color: var(--ui-text-muted); font-size: 11px; white-space: nowrap; background: var(--ui-hover); border-radius: var(--ui-radius-pill); }
.pms-shell .pms-dashboard-legend { display: flex; justify-content: flex-end; gap: 14px; margin-top: 4px; color: var(--ui-text-muted); font-size: 11px; }
.pms-shell .pms-dashboard-legend span,
.pms-shell .pms-dashboard-status-list span { display: inline-flex; align-items: center; gap: 6px; }
.pms-shell .pms-dashboard-key { display: inline-block; width: 9px; height: 9px; flex: 0 0 9px; background: #b9c0c8; border-radius: 3px; }
.pms-shell .pms-dashboard-key--completed { background: var(--ui-success); }
.pms-shell .pms-dashboard-key--pending { background: var(--ui-error); }
.pms-shell .pms-dashboard-workload-list { display: grid; align-content: center; gap: 8px; min-height: 180px; padding-top: 8px; }
.pms-shell .pms-dashboard-workload-row { display: grid; min-width: 0; grid-template-columns: minmax(100px, 150px) minmax(60px, 1fr) 50px; align-items: center; gap: 12px; }
.pms-shell .pms-dashboard-workload-name { overflow: hidden; color: var(--ui-text); font-size: 12px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.pms-shell .pms-dashboard-workload-track { display: flex; height: 13px; overflow: hidden; background: #edf0f2; border-radius: var(--ui-radius-pill); }
.pms-shell .pms-dashboard-workload-track > span { display: block; height: 100%; }
.pms-shell .pms-dashboard-workload-completed { background: var(--ui-success); }
.pms-shell .pms-dashboard-workload-pending { background: var(--ui-error); }
.pms-shell .pms-dashboard-workload-row strong { color: var(--ui-text-strong); font-size: 12px; text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.pms-shell .pms-dashboard-status-body { display: flex; align-items: center; justify-content: center; gap: min(5vw, 36px); min-height: 180px; }
.pms-shell .pms-dashboard-donut { display: grid; width: 150px; height: 150px; flex: 0 0 150px; place-items: center; background: conic-gradient(var(--ui-success) 0 var(--completion), #edf0f2 var(--completion) 100%); border-radius: 50%; }
.pms-shell .pms-dashboard-donut > div { display: flex; width: 112px; height: 112px; flex-direction: column; align-items: center; justify-content: center; background: #fff; border-radius: 50%; }
.pms-shell .pms-dashboard-donut strong { color: var(--ui-text-strong); font-size: 27px; line-height: 1.1; }
.pms-shell .pms-dashboard-donut span { color: var(--ui-text-muted); font-size: 11px; }
.pms-shell .pms-dashboard-status-list { min-width: 145px; flex: 1; max-width: 230px; }
.pms-shell .pms-dashboard-status-list > div { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 0; color: var(--ui-text-muted); font-size: 12px; border-bottom: 1px solid var(--ui-border); }
.pms-shell .pms-dashboard-status-list strong { color: var(--ui-text-strong); font-size: 14px; font-variant-numeric: tabular-nums; }
.pms-shell .pms-dashboard-status-list .pms-dashboard-status-total { border: 0; color: var(--ui-text-strong); font-weight: 600; }
.pms-shell .pms-dashboard-revenue-head { align-items: center; padding-bottom: 12px; border-bottom: 1px solid var(--ui-border); }
.pms-shell .pms-dashboard-revenue-head p { margin: 4px 0 0; color: var(--ui-text-muted); font-size: 12px; }
.pms-shell .pms-dashboard-revenue-filter { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.pms-shell .pms-dashboard-revenue-filter label { margin: 0 2px 0 5px; color: var(--ui-text-muted); font-size: 11px; }
.pms-shell .pms-dashboard-revenue-filter .form-control { width: 142px; height: 34px; min-height: 34px; padding: 5px 8px; font-size: 12px; }
.pms-shell .pms-dashboard-revenue-filter .btn { min-height: 34px; padding: 6px 10px; font-size: 11px; }
.pms-shell .pms-dashboard-filter-error { margin: 8px 0 0; color: var(--ui-error); font-size: 12px; }
.pms-shell .pms-dashboard-revenue-list { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; padding-top: 12px; }
.pms-shell .pms-dashboard-revenue-card { display: flex; min-width: 0; min-height: 105px; flex-direction: column; justify-content: space-between; gap: 7px; padding: 12px 14px; background: var(--ui-surface-soft); border: 1px solid var(--ui-border); border-radius: var(--ui-radius-md); }
.pms-shell .pms-dashboard-revenue-card-top { display: flex; min-width: 0; align-items: center; gap: 8px; }
.pms-shell .pms-dashboard-revenue-rank { display: grid; width: 22px; height: 22px; flex: 0 0 22px; place-items: center; color: var(--ui-text); background: #e9eaec; border-radius: 6px; font-size: 11px; font-weight: 700; }
.pms-shell .pms-dashboard-revenue-name { overflow: hidden; color: var(--ui-text); font-size: 12px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.pms-shell .pms-dashboard-revenue-card > strong { color: var(--ui-text-strong); font-size: 19px; line-height: 1.2; white-space: nowrap; font-variant-numeric: tabular-nums; }
.pms-shell .pms-dashboard-revenue-track { height: 6px; overflow: hidden; background: #e9eaec; border-radius: var(--ui-radius-pill); }
.pms-shell .pms-dashboard-revenue-track > span { display: block; height: 100%; background: var(--ui-success); border-radius: inherit; }
.pms-shell .pms-dashboard-revenue-card--top { background: var(--ui-text-strong); border-color: var(--ui-text-strong); }
.pms-shell .pms-dashboard-revenue-card--top .pms-dashboard-revenue-name,
.pms-shell .pms-dashboard-revenue-card--top > strong { color: #fff; }
.pms-shell .pms-dashboard-revenue-card--top .pms-dashboard-revenue-rank { color: #fff; background: rgba(255, 255, 255, .18); }
.pms-shell .pms-dashboard-revenue-card--top .pms-dashboard-revenue-track { background: rgba(255, 255, 255, .18); }
.pms-shell .pms-dashboard-revenue-card--top .pms-dashboard-revenue-track > span { background: #b8decf; }
.pms-shell .pms-dashboard-empty { margin: 6px 0; color: var(--ui-text-muted); font-size: 12px; }
@media (max-width: 1199.98px) {
    .pms-shell .pms-dashboard-metrics { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .pms-shell .pms-dashboard-insights { grid-template-columns: minmax(0, 1fr) minmax(290px, .9fr); }
    .pms-shell .pms-dashboard-revenue-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 991.98px) {
    .pms-shell .pms-dashboard-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pms-shell .pms-dashboard-insights { grid-template-columns: 1fr; }
}
@media (max-width: 575.98px) {
    .pms-shell .pms-dashboard-metrics { gap: 8px; }
    .pms-shell .pms-dashboard-metric { min-height: 70px; }
    .pms-shell .pms-dashboard-metric-copy strong { font-size: 19px; }
    .pms-shell .pms-dashboard-panel { padding: 14px; }
    .pms-shell .pms-dashboard-revenue-head { align-items: flex-start; flex-direction: column; }
    .pms-shell .pms-dashboard-revenue-list { grid-template-columns: 1fr; }
    .pms-shell .pms-dashboard-status-body { gap: 16px; }
    .pms-shell .pms-dashboard-donut { width: 118px; height: 118px; flex-basis: 118px; }
    .pms-shell .pms-dashboard-donut > div { width: 88px; height: 88px; }
    .pms-shell .pms-dashboard-donut strong { font-size: 22px; }
}

/* Employee workspace: the same compact, neutral visual language as admin. */
body.pms-employee-shell .pms-employee-dashboard > .pms-dashboard-grid { row-gap: 12px; }
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col {
    flex: 0 0 20%;
    max-width: 20%;
}
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col .small-box.card {
    min-height: 98px;
    height: 100%;
    margin-bottom: 0;
    overflow: hidden;
    background: var(--ui-surface);
    border: 1px solid var(--ui-border);
    box-shadow: var(--ui-shadow-sm);
}
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col .small-box.card::before {
    height: 2px;
    background: var(--ui-border-strong);
}
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col:nth-child(3) .small-box.card::before { background: var(--ui-success); }
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col:nth-child(4) .small-box.card::before { background: var(--ui-error); }
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col .inner {
    display: flex;
    min-height: 96px;
    flex-direction: column-reverse;
    align-items: flex-start;
    justify-content: center;
    padding: 12px 46px 12px 16px;
    text-align: left;
}
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col .inner h3 {
    margin: 5px 0 0;
    color: var(--ui-text-strong) !important;
    font-size: 24px !important;
    line-height: 1.1 !important;
}
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col .inner p {
    margin: 0;
    color: var(--ui-text-muted) !important;
    font-size: 11px !important;
    font-weight: 600;
    line-height: 1.25;
}
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col .small-box-footer {
    position: absolute;
    top: 50%;
    right: 10px;
    width: 32px;
    height: 32px;
    min-height: 32px;
    align-items: center;
    justify-content: center;
    padding: 0;
    background: var(--ui-hover);
    border: 0;
    border-radius: var(--ui-radius-md);
    transform: translateY(-50%);
}
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col .small-box-footer:hover {
    background: var(--ui-brand-soft);
}
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col .small-box-footer i { font-size: 13px; }
body.pms-employee-shell .pms-employee-dashboard .pms-dashboard-filter,
body.pms-employee-shell .pms-employee-dashboard .pms-chart-card {
    margin-bottom: 0;
    background: var(--ui-surface);
    border: 1px solid var(--ui-border);
    box-shadow: var(--ui-shadow-sm);
}
body.pms-employee-shell .pms-employee-dashboard .pms-chart-card h4 { margin-bottom: 12px; }
body.pms-employee-shell .pms-employee-dashboard .pms-dashboard-filter { border-radius: var(--ui-radius-lg); }
body.pms-employee-shell .pms-employee-dashboard .pms-chart-card .inner { padding: 18px !important; }
body.pms-employee-shell .pms-employee-dashboard .pms-chart-card h4 {
    color: var(--ui-text-strong);
    font-size: 16px !important;
    font-weight: 600;
}
body.pms-employee-shell .content .card {
    border-color: var(--ui-border);
    box-shadow: var(--ui-shadow-sm);
}
body.pms-employee-shell .content .card-header {
    background: var(--ui-surface);
    border-bottom-color: var(--ui-border);
}
body.pms-employee-shell .content .table-responsive { overflow-x: auto; }
body.pms-employee-shell .content table.table {
    border-top: 1px solid var(--ui-border) !important;
    border-left: 1px solid var(--ui-border) !important;
    border-collapse: separate;
    border-spacing: 0;
}
body.pms-employee-shell .content table.table > thead > tr > th,
body.pms-employee-shell .content table.table > tbody > tr > td {
    vertical-align: middle;
    text-align: center;
    border-right: 1px solid var(--ui-border) !important;
    border-bottom: 1px solid var(--ui-border) !important;
}
body.pms-employee-shell .content table.table > thead > tr > th {
    color: #5c6470;
    background: #f7f8f9;
    font-size: 12px !important;
    font-weight: 600;
}
body.pms-employee-shell .content table.table > tbody > tr:hover > td { background: var(--ui-brand-subtle); }
body.pms-employee-shell .content table.table table.table > thead > tr > th,
body.pms-employee-shell .content table.table table.table > tbody > tr > td {
    padding: 6px 8px;
    font-size: 11px !important;
}
body.pms-employee-shell .pms-employee-task-toolbar {
    align-items: center;
    padding: 12px 16px !important;
    background: var(--ui-surface);
}
body.pms-employee-shell .pms-employee-task-toolbar .row { align-items: center; }
body.pms-employee-shell .pms-employee-task-toolbar [class*="col-"] { margin-top: 0 !important; }
body.pms-employee-shell .pms-employee-task-toolbar .pms-list-title { font-size: 18px !important; }
body.pms-employee-shell .pms-employee-task-toolbar--simple {
    margin: 0;
    border-bottom: 1px solid var(--ui-border);
}
body.pms-employee-shell .pms-employee-task-toolbar--simple .input-group { max-width: 420px; }
body.pms-employee-shell .pms-employee-task-list > thead > tr > th,
body.pms-employee-shell .pms-employee-task-list > tbody > tr > td {
    border-right: 1px solid var(--ui-border) !important;
    border-bottom: 1px solid var(--ui-border) !important;
}
body.pms-employee-shell .pms-employee-task-list .pms-icon-btn {
    width: 34px;
    height: 34px;
    min-height: 34px;
    padding: 0;
    color: var(--ui-text);
    background: var(--ui-hover);
    border: 1px solid var(--ui-border-strong);
}
body.pms-employee-shell .pms-employee-task-list .pms-icon-btn:hover { background: var(--ui-brand-soft); }

@media (max-width: 1199.98px) {
    body.pms-employee-shell .pms-employee-dashboard .pms-stat-col { flex-basis: 33.3333%; max-width: 33.3333%; }
}
@media (max-width: 767.98px) {
    body.pms-employee-shell .pms-employee-dashboard .pms-stat-col { flex-basis: 50%; max-width: 50%; }
}

/* Employee shell details shared by dashboard, lists, forms and login. */
.login-page .pms-auth-logo {
    display: block;
    width: min(230px, 100%);
    height: 58px;
    margin: 0 auto;
    object-fit: contain;
    filter: brightness(0);
}
body.pms-employee-shell .pms-header-title {
    font-size: var(--ui-font-body);
    letter-spacing: normal;
    text-transform: uppercase;
}
body.pms-employee-shell .brand-link .brand-image {
    display: block;
    width: auto !important;
    max-width: 176px;
    height: 38px;
    margin: 0;
    object-fit: contain;
}
body.pms-employee-shell .content > .container-fluid,
body.pms-employee-shell .content-header .container-fluid {
    max-width: 1680px;
}
body.pms-employee-shell .pms-employee-task-list > thead > tr > th,
body.pms-employee-shell .pms-employee-task-list > tbody > tr > td {
    padding: 9px 10px !important;
    font-size: 12px !important;
    line-height: 1.4;
}
body.pms-employee-shell .pms-employee-task-list > thead > tr > th {
    white-space: nowrap;
    letter-spacing: .02em;
}
body.pms-employee-shell .pms-employee-task-list > tbody > tr.is-completed > td {
    background: var(--ui-success-soft);
}
body.pms-employee-shell .pms-employee-task-list > thead > tr > th.pms-task-actions,
body.pms-employee-shell .pms-employee-task-list > tbody > tr > td.pms-task-actions {
    min-width: 98px;
    white-space: nowrap;
}
body.pms-employee-shell .pms-employee-task-list .pms-task-actions .pms-icon-btn {
    display: inline-flex;
    margin: 0 2px;
    vertical-align: middle;
}
body.pms-employee-shell .pms-employee-task-list > tbody > tr > td.pms-task-primary {
    min-width: 150px;
    max-width: 250px;
    color: var(--ui-text-strong);
    font-weight: 600;
    text-align: left;
    white-space: normal;
    overflow-wrap: anywhere;
}
body.pms-employee-shell .pms-employee-task-list > tbody > tr > td.pms-date-cell {
    min-width: 118px;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}
body.pms-employee-shell .pms-employee-task-list > tbody > tr > td.pms-date-cell small {
    display: block;
    margin-top: 2px;
}
body.pms-employee-shell .pms-employee-task-list .pms-status,
body.pms-employee-shell .pms-employee-task-list .pms-tag-name,
body.pms-employee-shell .pms-employee-task-list .pms-person-badge,
body.pms-employee-shell .pms-employee-task-list .pms-muted-badge {
    display: inline-flex;
    max-width: 100%;
    align-items: center;
    justify-content: center;
    padding: 5px 8px;
    font-size: 11px !important;
    font-weight: 600;
    line-height: 1.25;
    white-space: normal;
    overflow-wrap: anywhere;
    border-radius: var(--ui-radius-pill);
}
body.pms-employee-shell .pms-employee-task-list .pms-status--completed { color: var(--ui-success); background: var(--ui-success-soft); }
body.pms-employee-shell .pms-employee-task-list .pms-status--pending,
body.pms-employee-shell .pms-employee-task-list .pms-status--not-started { color: var(--ui-error); background: var(--ui-error-soft); }
body.pms-employee-shell .pms-employee-task-list .pms-status--wip { color: var(--ui-info); background: var(--ui-info-soft); }
body.pms-employee-shell .pms-employee-task-list .pms-person-badge,
body.pms-employee-shell .pms-employee-task-list .pms-muted-badge,
body.pms-employee-shell .pms-employee-task-list .pms-tag-name { color: var(--ui-accent-text); background: var(--ui-brand-soft); }
body.pms-employee-shell .pms-employee-task-list > tbody > tr > td > table.table { min-width: 270px; }
body.pms-employee-shell .pms-employee-task-list > tbody > tr > td > table.table th,
body.pms-employee-shell .pms-employee-task-list > tbody > tr > td > table.table td {
    padding: 4px 6px !important;
    font-size: 10px !important;
    white-space: normal;
}
body.pms-employee-shell .pms-employee-task-list .pms-icon-btn-danger {
    color: var(--ui-error);
    background: var(--ui-error-soft);
    border-color: rgba(220, 69, 69, .28);
}
body.pms-employee-shell .pms-employee-task-list .pms-icon-btn-danger:hover {
    color: #fff;
    background: var(--ui-error);
    border-color: var(--ui-error);
}
/* My Tasks: keep the dense desktop view readable at normal browser zoom. */
body.pms-employee-shell .pms-my-task-table-wrap { overflow-x: visible; }
body.pms-employee-shell .pms-my-task-table-wrap > table.pms-my-task-list {
    width: 100% !important;
    min-width: 0 !important;
    table-layout: fixed;
}
body.pms-employee-shell .pms-my-task-list > thead > tr > th,
body.pms-employee-shell .pms-my-task-list > tbody > tr > td {
    min-width: 0 !important;
    padding: 7px 6px !important;
    line-height: 1.3;
}
body.pms-employee-shell .pms-my-task-list > thead > tr > :nth-child(1) { width: 5%; }
body.pms-employee-shell .pms-my-task-list > thead > tr > :nth-child(2) { width: 8%; }
body.pms-employee-shell .pms-my-task-list > thead > tr > :nth-child(3) { width: 9%; }
body.pms-employee-shell .pms-my-task-list > thead > tr > :nth-child(4) { width: 9%; }
body.pms-employee-shell .pms-my-task-list > thead > tr > :nth-child(5) { width: 16%; }
body.pms-employee-shell .pms-my-task-list > thead > tr > :nth-child(6) { width: 17%; }
body.pms-employee-shell .pms-my-task-list > thead > tr > :nth-child(7) { width: 12%; }
body.pms-employee-shell .pms-my-task-list > thead > tr > :nth-child(8) { width: 10%; }
body.pms-employee-shell .pms-my-task-list > thead > tr > :nth-child(9) { width: 5%; }
body.pms-employee-shell .pms-my-task-list > thead > tr > :nth-child(10) { width: 9%; }
body.pms-employee-shell .pms-my-task-list--manager > thead > tr > :nth-child(1) { width: 5%; }
body.pms-employee-shell .pms-my-task-list--manager > thead > tr > :nth-child(2) { width: 11%; }
body.pms-employee-shell .pms-my-task-list--manager > thead > tr > :nth-child(3) { width: 8%; }
body.pms-employee-shell .pms-my-task-list--manager > thead > tr > :nth-child(4) { width: 8%; }
body.pms-employee-shell .pms-my-task-list--manager > thead > tr > :nth-child(5) { width: 8%; }
body.pms-employee-shell .pms-my-task-list--manager > thead > tr > :nth-child(6) { width: 12%; }
body.pms-employee-shell .pms-my-task-list--manager > thead > tr > :nth-child(7) { width: 14%; }
body.pms-employee-shell .pms-my-task-list--manager > thead > tr > :nth-child(8) { width: 10%; }
body.pms-employee-shell .pms-my-task-list--manager > thead > tr > :nth-child(9) { width: 10%; }
body.pms-employee-shell .pms-my-task-list--manager > thead > tr > :nth-child(10) { width: 5%; }
body.pms-employee-shell .pms-my-task-list--manager > thead > tr > :nth-child(11) { width: 9%; }
body.pms-employee-shell .pms-my-task-list .pms-task-actions .pms-icon-btn {
    width: 34px;
    height: 34px;
    min-height: 34px;
    margin: 0 1px;
}
body.pms-employee-shell .pms-my-task-list .pms-status {
    max-width: none;
    padding: 5px 7px;
    white-space: nowrap;
    overflow-wrap: normal;
}
body.pms-employee-shell .pms-my-task-list .pms-task-challan-list {
    display: grid;
    gap: 4px;
    min-width: 0;
}
body.pms-employee-shell .pms-my-task-list .pms-task-challan-entry {
    display: grid;
    gap: 2px;
    padding: 4px 0;
    font-size: 11px;
    line-height: 1.3;
    text-align: left;
    overflow-wrap: anywhere;
}
body.pms-employee-shell .pms-my-task-list .pms-task-challan-entry + .pms-task-challan-entry {
    border-top: 1px solid var(--ui-border);
}
body.pms-employee-shell .pms-my-task-list .pms-task-challan-entry strong {
    color: var(--ui-text-muted);
    font-weight: 600;
}
@media (max-width: 1499.98px) {
    body.pms-employee-shell .pms-my-task-table-wrap { overflow: visible; }
    body.pms-employee-shell .pms-my-task-table-wrap > table.pms-my-task-list,
    body.pms-employee-shell .pms-my-task-list > tbody { display: block; width: 100% !important; }
    body.pms-employee-shell .pms-my-task-list > thead { display: none; }
    body.pms-employee-shell .pms-my-task-list > tbody > tr.pms-task-row {
        display: grid;
        grid-template-columns: repeat(12, minmax(0, 1fr));
        gap: 0;
        margin-bottom: 10px;
        border: 1px solid var(--ui-border);
        border-radius: var(--ui-radius-md);
        overflow: hidden;
    }
    body.pms-employee-shell .pms-my-task-list > tbody > tr.pms-task-row > td {
        display: flex;
        min-width: 0 !important;
        max-width: none;
        flex-direction: column;
        align-items: flex-start;
        justify-content: center;
        gap: 3px;
        padding: 8px 10px !important;
        text-align: left;
        white-space: normal;
        overflow-wrap: anywhere;
    }
    body.pms-employee-shell .pms-my-task-list > tbody > tr.pms-task-row > td::before {
        content: attr(data-label);
        color: var(--ui-text-muted);
        font-size: 10px;
        font-weight: 600;
        line-height: 1.2;
        text-transform: uppercase;
    }
    body.pms-employee-shell .pms-my-task-list .pms-task-number { grid-column: 1 / span 1; grid-row: 1; }
    body.pms-employee-shell .pms-my-task-list .pms-date-cell { grid-column: 2 / span 2; grid-row: 1; }
    body.pms-employee-shell .pms-my-task-list .pms-task-assignment { grid-column: 4 / span 3; grid-row: 1; }
    body.pms-employee-shell .pms-my-task-list .pms-task-entity { grid-column: 7 / span 4; grid-row: 1; }
    body.pms-employee-shell .pms-my-task-list .pms-task-status-cell { grid-column: 11 / span 2; grid-row: 1; }
    body.pms-employee-shell .pms-my-task-list .pms-task-actions { grid-column: 1 / span 2; grid-row: 2; }
    body.pms-employee-shell .pms-my-task-list .pms-task-sub-assigned { grid-column: 3 / span 2; grid-row: 2; }
    body.pms-employee-shell .pms-my-task-list .pms-task-client { grid-column: 5 / span 3; grid-row: 2; }
    body.pms-employee-shell .pms-my-task-list .pms-task-challan-cell { grid-column: 8 / span 3; grid-row: 2; }
    body.pms-employee-shell .pms-my-task-list .pms-tag-cell { grid-column: 11 / span 2; grid-row: 2; }
    body.pms-employee-shell .pms-my-task-list--manager .pms-task-assigned-by { grid-column: 3 / span 2; grid-row: 2; }
    body.pms-employee-shell .pms-my-task-list--manager .pms-task-sub-assigned { grid-column: 5 / span 2; }
    body.pms-employee-shell .pms-my-task-list--manager .pms-task-client { grid-column: 7 / span 3; }
    body.pms-employee-shell .pms-my-task-list--manager .pms-task-challan-cell { grid-column: 10 / span 2; }
    body.pms-employee-shell .pms-my-task-list--manager .pms-tag-cell { grid-column: 12 / span 1; }
    body.pms-employee-shell .pms-my-task-list > tbody > tr.pms-task-row > td.pms-task-actions {
        display: block;
        white-space: nowrap;
    }
    body.pms-employee-shell .pms-my-task-list .pms-task-actions::before { display: block; margin-bottom: 6px; }
    body.pms-employee-shell .pms-my-task-list .pms-status { white-space: nowrap; }
    body.pms-employee-shell .pms-my-task-list > tbody > tr.pms-my-task-empty-row { display: block; }
    body.pms-employee-shell .pms-my-task-list > tbody > tr.pms-my-task-empty-row > td { display: block; width: 100%; }
}
@media (max-width: 767.98px) {
    body.pms-employee-shell .pms-my-task-list > tbody > tr.pms-task-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    body.pms-employee-shell .pms-my-task-list > tbody > tr.pms-task-row > td { grid-column: auto !important; grid-row: auto !important; }
    body.pms-employee-shell .pms-my-task-list > tbody > tr.pms-task-row > td.pms-task-assignment,
    body.pms-employee-shell .pms-my-task-list > tbody > tr.pms-task-row > td.pms-task-entity,
    body.pms-employee-shell .pms-my-task-list > tbody > tr.pms-task-row > td.pms-task-client,
    body.pms-employee-shell .pms-my-task-list > tbody > tr.pms-task-row > td.pms-task-challan-cell { grid-column: 1 / -1 !important; }
}
@media (max-width: 575.98px) {
    body.pms-employee-shell .pms-my-task-list > tbody > tr.pms-task-row { grid-template-columns: 1fr; }
    body.pms-employee-shell .pms-my-task-list > tbody > tr.pms-task-row > td { grid-column: 1 / -1 !important; }
}
@media (max-width: 767.98px) {
    body.pms-employee-shell .pms-employee-task-list { min-width: 1120px; }
}

/* Keep employee KPI density and report hierarchy aligned with the admin workspace. */
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col .small-box.card {
    border-top: 2px solid var(--ui-border-strong);
    transition: border-color var(--ui-transition), box-shadow var(--ui-transition), transform var(--ui-transition);
}
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col .small-box.card:hover {
    border-color: var(--ui-brand);
    box-shadow: var(--ui-shadow-md);
    transform: translateY(-2px);
}
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col:nth-child(3) .small-box.card { border-top-color: var(--ui-success); }
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col:nth-child(4) .small-box.card { border-top-color: var(--ui-error); }
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col .inner p {
    color: #52525b !important;
    font-size: 12px !important;
    line-height: 1.35;
}
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col .small-box-footer:focus-visible {
    outline: 2px solid var(--ui-accent);
    outline-offset: 2px;
}
body.pms-employee-shell .pms-employee-report-grid { min-width: 1160px; }
body.pms-employee-shell .pms-employee-report-grid > tbody > tr.is-completed > td { background: var(--ui-success-soft); }
body.pms-employee-shell .pms-employee-report-grid > tbody > tr > td {
    padding: 10px 9px !important;
    font-size: 12px !important;
    line-height: 1.4;
    overflow-wrap: anywhere;
}
body.pms-employee-shell .pms-employee-report-grid .pms-date-cell small { display: block; margin-top: 2px; color: var(--ui-text-muted); white-space: nowrap; }
body.pms-employee-shell .pms-employee-report-grid > tbody > tr > td:nth-child(5),
body.pms-employee-shell .pms-employee-report-grid > tbody > tr > td.pms-report-description { text-align: left; }
body.pms-employee-shell .pms-employee-report-grid > tbody > tr > td.pms-report-description {
    min-width: 230px;
    max-width: 310px;
    color: var(--ui-text-muted);
}
body.pms-employee-shell .pms-employee-report-grid .pms-report-view {
    width: 34px;
    min-width: 34px;
    height: 34px;
    min-height: 34px;
    padding: 0;
}
body.pms-employee-shell .pms-employee-report-grid .pms-task-status {
    display: inline-flex;
    padding: 5px 8px;
    white-space: nowrap;
    border-radius: var(--ui-radius-pill);
}
body.pms-employee-shell .pms-task-rich-text { text-align: left; overflow-wrap: anywhere; }
body.pms-employee-shell .pms-task-rich-text p:last-child,
body.pms-employee-shell .pms-task-rich-text ul:last-child,
body.pms-employee-shell .pms-task-rich-text ol:last-child { margin-bottom: 0; }
body.pms-employee-shell .pms-employee-report-toolbar { align-items: center; row-gap: 10px; }
body.pms-employee-shell .pms-employee-report-toolbar .card-tools,
body.pms-employee-shell .pms-employee-report-toolbar form { width: 100%; }
body.pms-employee-shell .pms-employee-report-search { width: min(100%, 400px); margin-left: auto; }
body.pms-employee-shell .pms-employee-report-search .form-control { min-width: 0; }
@media (max-width: 991.98px) {
    body.pms-employee-shell .pms-employee-report-search { width: 100%; }
}

/* Compact employee filters share one predictable grid, independent of Bootstrap columns. */
body.pms-employee-shell .pms-employee-filter-card .pms-task-filter-table {
    overflow-x: auto;
}
body.pms-employee-shell .pms-employee-filter-card .pms-task-filter-table > table.pms-task-filter-grid {
    width: 100% !important;
    min-width: 1450px !important;
    table-layout: fixed;
}
body.pms-employee-shell .pms-employee-filter-card .pms-task-filter-grid > thead > tr > th,
body.pms-employee-shell .pms-employee-filter-card .pms-task-filter-grid > tbody > tr > td {
    min-width: 0 !important;
    vertical-align: middle;
}
body.pms-employee-shell .pms-employee-filter-card .pms-task-filter-grid > thead > tr > th {
    white-space: nowrap !important;
}
body.pms-employee-shell .pms-employee-filter-card .pms-task-filter-grid > thead > tr > :nth-child(1) { width: 4.5%; }
body.pms-employee-shell .pms-employee-filter-card .pms-task-filter-grid > thead > tr > :nth-child(2) { width: 13%; }
body.pms-employee-shell .pms-employee-filter-card .pms-task-filter-grid > thead > tr > :nth-child(3) { width: 14%; }
body.pms-employee-shell .pms-employee-filter-card .pms-task-filter-grid > thead > tr > :nth-child(4) { width: 11%; }
body.pms-employee-shell .pms-employee-filter-card .pms-task-filter-grid > thead > tr > :nth-child(5) { width: 30%; }
body.pms-employee-shell .pms-employee-filter-card .pms-task-filter-grid > thead > tr > :nth-child(6) { width: 5.5%; }
body.pms-employee-shell .pms-employee-filter-card .pms-task-filter-grid > thead > tr > :nth-child(7) { width: 11%; }
body.pms-employee-shell .pms-employee-filter-card .pms-task-filter-grid > thead > tr > :nth-child(8) { width: 11%; }
body.pms-employee-shell .pms-employee-filter-card .pms-task-filter-grid > tbody > tr > td:nth-child(5) > .pms-filter-challan-table {
    width: 100% !important;
    min-width: 0 !important;
    table-layout: fixed;
}
body.pms-employee-shell .pms-employee-filter-card .pms-filter-challan-table th,
body.pms-employee-shell .pms-employee-filter-card .pms-filter-challan-table td {
    min-width: 0 !important;
    padding: 6px !important;
    overflow-wrap: anywhere !important;
    white-space: normal !important;
}
body.pms-employee-shell .pms-employee-filter-card .pms-filter-challan-table tr > :nth-child(1) { width: 20%; }
body.pms-employee-shell .pms-employee-filter-card .pms-filter-challan-table tr > :nth-child(2) { width: 28%; }
body.pms-employee-shell .pms-employee-filter-card .pms-filter-challan-table tr > :nth-child(3) { width: 18%; }
body.pms-employee-shell .pms-employee-filter-card .pms-filter-challan-table tr > :nth-child(4) { width: 34%; }
body.pms-employee-shell .pms-employee-filter-controls {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 12px 16px;
    padding: 16px 18px;
    border-bottom: 1px solid var(--ui-border);
}
body.pms-employee-shell .pms-date-filter-section { grid-column: span 6; min-width: 0; }
body.pms-employee-shell .pms-date-filter-section form,
body.pms-employee-shell .pms-quick-filter form { width: 100%; margin: 0; }
body.pms-employee-shell .pms-date-filter-grid {
    display: grid;
    grid-template-columns: minmax(145px, 1fr) minmax(145px, 1fr) minmax(190px, 1.25fr) auto;
    align-items: end;
    gap: 10px;
}
body.pms-employee-shell .pms-filter-field,
body.pms-employee-shell .pms-filter-submit,
body.pms-employee-shell .pms-quick-filter { min-width: 0; }
body.pms-employee-shell .pms-filter-field label { display: block; margin: 0 0 5px; white-space: nowrap; }
body.pms-employee-shell .pms-filter-field .form-control,
body.pms-employee-shell .pms-quick-filter .form-control { width: 100%; min-width: 0; }
body.pms-employee-shell .pms-filter-submit .btn { height: var(--ui-control-height); white-space: nowrap; }
body.pms-employee-shell .pms-quick-filter { grid-column: span 2; padding-top: 12px; border-top: 1px solid var(--ui-border); }
body.pms-employee-shell .pms-quick-filter--search { grid-column: span 6; }
body.pms-employee-shell .pms-quick-filter .input-group { display: flex; width: 100%; flex-wrap: nowrap; }
body.pms-employee-shell .pms-quick-filter .select2-container { width: 100% !important; }
body.pms-employee-shell .pms-quick-filter .select2-selection--single { min-height: var(--ui-control-height) !important; }
body.pms-employee-shell .pms-quick-filter--search .form-control { width: auto; min-width: 0; flex: 1 1 auto; }
body.pms-employee-shell .pms-quick-filter--search .input-group-append { flex: 0 0 auto; }
body.pms-employee-shell .pms-quick-filter--search .btn { width: 44px; height: var(--ui-control-height); padding: 0; }
@media (max-width: 1699.98px) {
    body.pms-employee-shell .pms-date-filter-section { grid-column: 1 / -1; }
    body.pms-employee-shell .pms-quick-filter { grid-column: span 4; }
    body.pms-employee-shell .pms-quick-filter--search { grid-column: 1 / -1; padding-top: 0; border-top: 0; }
}
@media (max-width: 767.98px) {
    body.pms-employee-shell .pms-employee-filter-controls { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 14px; }
    body.pms-employee-shell .pms-date-filter-section,
    body.pms-employee-shell .pms-quick-filter { grid-column: 1 / -1; }
    body.pms-employee-shell .pms-date-filter-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    body.pms-employee-shell .pms-filter-field label { white-space: normal; }
    body.pms-employee-shell .pms-filter-submit .btn { width: 100%; }
    body.pms-employee-shell .pms-quick-filter { padding-top: 0; border-top: 0; }
}
@media (max-width: 575.98px) {
    body.pms-employee-shell .pms-date-filter-grid .pms-filter-field:nth-child(3),
    body.pms-employee-shell .pms-date-filter-grid .pms-filter-submit { grid-column: 1 / -1; }
}

/* Employee client directory follows the admin title/search/action hierarchy. */
body.pms-employee-shell .pms-employee-price-toolbar {
    grid-template-columns: minmax(0, 1fr) minmax(280px, 460px);
}
body.pms-employee-shell .pms-employee-price-toolbar .pms-price-search {
    width: 100%;
    max-width: 460px;
    margin: 0 0 0 auto;
}
@media (max-width: 767.98px) {
    body.pms-employee-shell .pms-employee-price-toolbar { grid-template-columns: 1fr; }
    body.pms-employee-shell .pms-employee-price-toolbar > [class*="col-"]:last-child { justify-self: stretch; }
    body.pms-employee-shell .pms-employee-price-toolbar .pms-price-search { max-width: none; }
}

.pms-employee-shell .pms-policy-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--ui-border); }
.pms-employee-shell .pms-policy-row:first-child { padding-top: 0; }
.pms-employee-shell .pms-policy-row:last-child { padding-bottom: 0; border-bottom: 0; }
.pms-employee-shell .pms-policy-row strong { display: block; color: var(--ui-text-strong); font-size: 13px; }
.pms-employee-shell .pms-policy-row small { display: block; margin-top: 2px; color: var(--ui-text-muted); }
@media (max-width: 575.98px) { .pms-employee-shell .pms-policy-row { align-items: flex-start; flex-direction: column; } }

/* Employee client directory follows the admin title/search/action hierarchy. */
/* Ordered task columns and role-specific progress editor. */
body.pms-employee-shell .pms-my-task-toolbar { display: flex; width: 100%; align-items: center; gap: 12px; }
body.pms-employee-shell .pms-my-task-toolbar h1 { flex: 0 0 auto; margin: 0; font-size: 18px !important; }
body.pms-employee-shell .pms-my-task-search { display: flex; min-width: 0; max-width: 820px; flex: 1 1 auto; align-items: center; gap: 8px; margin-left: auto; }
body.pms-employee-shell .pms-my-task-search input { min-width: 140px; flex: 1 1 auto; }
body.pms-employee-shell .pms-my-task-search select { width: 210px; flex: 0 1 210px; }
body.pms-employee-shell .pms-my-task-toolbar > .pms-primary-action { flex: 0 0 auto; }
body.pms-employee-shell .pms-my-task-table-wrap > table.pms-task-ordered-table { width: 100% !important; min-width: 0 !important; table-layout: fixed; }
body.pms-employee-shell .pms-task-ordered-table > thead > tr > :nth-child(1) { width: 4%; }
body.pms-employee-shell .pms-task-ordered-table > thead > tr > :nth-child(2) { width: 9%; }
body.pms-employee-shell .pms-task-ordered-table > thead > tr > :nth-child(3) { width: 7%; }
body.pms-employee-shell .pms-task-ordered-table > thead > tr > :nth-child(4) { width: 11%; }
body.pms-employee-shell .pms-task-ordered-table > thead > tr > :nth-child(5) { width: 17%; }
body.pms-employee-shell .pms-task-ordered-table > thead > tr > :nth-child(6) { width: 8%; }
body.pms-employee-shell .pms-task-ordered-table > thead > tr > :nth-child(7) { width: 9%; }
body.pms-employee-shell .pms-task-ordered-table > thead > tr > :nth-child(8) { width: 12%; }
body.pms-employee-shell .pms-task-ordered-table > thead > tr > :nth-child(9) { width: 5%; }
body.pms-employee-shell .pms-task-ordered-table > thead > tr > :nth-child(10) { width: 7%; }
body.pms-employee-shell .pms-task-ordered-table > thead > tr > :nth-child(11) { width: 11%; }
body.pms-employee-shell .pms-task-ordered-table > thead > tr > th { padding: 9px 5px !important; font-size: 11px !important; white-space: normal; }
body.pms-employee-shell .pms-task-ordered-table > tbody > tr > td { padding: 8px 5px !important; font-size: 12px !important; overflow-wrap: anywhere; }
body.pms-employee-shell .pms-task-ordered-table .pms-task-primary { min-width: 0 !important; max-width: none !important; text-align: center !important; }
body.pms-employee-shell .pms-task-ordered-table .pms-task-description-cell { color: var(--ui-text-muted); text-align: left; }
body.pms-employee-shell .pms-task-ordered-table .pms-date-cell { min-width: 0 !important; white-space: normal; }
body.pms-employee-shell .pms-task-ordered-table .pms-date-cell small { display: block; margin-top: 2px; color: var(--ui-text-muted); }
body.pms-employee-shell .pms-task-ordered-table .pms-task-actions { min-width: 0 !important; white-space: nowrap; }
body.pms-employee-shell .pms-task-ordered-table .pms-task-actions .pms-icon-btn { width: 30px; height: 30px; min-height: 30px; margin: 1px; padding: 0; }
body.pms-employee-shell .pms-task-ordered-table .pms-status { white-space: normal; overflow-wrap: anywhere; }
body.pms-employee-shell .pms-employee-progress { max-width: 1150px !important; }
body.pms-employee-shell .pms-employee-progress .card-header h2 { margin: 0; font-size: 17px !important; }
body.pms-employee-shell .pms-progress-top-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 14px; }
body.pms-employee-shell .pms-progress-comment { grid-column: 1 / -1; }
body.pms-employee-shell .pms-progress-section-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 14px 0 8px; padding-top: 12px; border-top: 1px solid var(--ui-border); }
body.pms-employee-shell .pms-progress-section-head h3 { margin: 0; font-size: 15px !important; }
body.pms-employee-shell .pms-progress-row { display: grid; grid-template-columns: 1.2fr 1fr 1fr 1fr auto; align-items: end; gap: 8px; margin-bottom: 8px; }
body.pms-employee-shell .pms-progress-row > div { min-width: 0; }
body.pms-employee-shell .pms-progress-row label { display: block; }
body.pms-employee-shell .pms-progress-expense { grid-template-columns: 1fr 1fr auto; }
body.pms-employee-shell .pms-progress-remove { min-height: var(--ui-control-height); }
body.pms-employee-shell .pms-progress-actions { display: flex; justify-content: flex-end; padding-top: 14px; }
@media (max-width: 1500px) {
    body.pms-employee-shell .pms-my-task-table-wrap { overflow: visible; }
    body.pms-employee-shell .pms-my-task-table-wrap > table.pms-task-ordered-table,
    body.pms-employee-shell .pms-task-ordered-table > tbody { display: block; width: 100% !important; }
    body.pms-employee-shell .pms-task-ordered-table > thead { display: none; }
    body.pms-employee-shell .pms-task-ordered-table > tbody > tr.pms-ordered-task-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 14px; margin: 10px; padding: 10px 14px; background: var(--ui-surface); border: 1px solid var(--ui-border); border-left: 3px solid var(--ui-brand); border-radius: var(--ui-radius-md); }
    body.pms-employee-shell .pms-task-ordered-table > tbody > tr.is-completed { border-left-color: var(--ui-success); }
    body.pms-employee-shell .pms-task-ordered-table > tbody > tr > td { display: block; min-width: 0; padding: 7px 0 !important; text-align: left !important; background: transparent !important; border: 0 !important; border-bottom: 1px solid var(--ui-border) !important; }
    body.pms-employee-shell .pms-task-ordered-table > tbody > tr > td::before { display: block; margin-bottom: 3px; color: var(--ui-text-muted); content: attr(data-label); font-size: 11px; font-weight: 600; }
    body.pms-employee-shell .pms-task-ordered-table > tbody > tr > td.pms-task-primary { text-align: left !important; }
    body.pms-employee-shell .pms-task-ordered-table > tbody > tr > td.pms-task-description-cell { grid-column: span 2; }
    body.pms-employee-shell .pms-task-ordered-table > tbody > tr > td.pms-task-actions { white-space: nowrap; }
    body.pms-employee-shell .pms-task-ordered-table > tbody > tr > td.pms-task-actions .pms-icon-btn { width: 34px; height: 34px; min-height: 34px; }
}
@media (max-width: 991.98px) {
    body.pms-employee-shell .pms-my-task-toolbar { align-items: stretch; flex-wrap: wrap; }
    body.pms-employee-shell .pms-my-task-search { order: 3; width: 100%; max-width: none; flex-basis: 100%; }
    body.pms-employee-shell .pms-my-task-toolbar > .pms-primary-action { margin-left: auto; }
    body.pms-employee-shell .pms-task-ordered-table > tbody > tr.pms-ordered-task-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    body.pms-employee-shell .pms-progress-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    body.pms-employee-shell .pms-progress-remove { justify-self: start; }
}
@media (max-width: 575.98px) {
    body.pms-employee-shell .pms-my-task-search { flex-wrap: wrap; }
    body.pms-employee-shell .pms-my-task-search input,
    body.pms-employee-shell .pms-my-task-search select { width: 100%; flex-basis: 100%; }
    body.pms-employee-shell .pms-task-ordered-table > tbody > tr.pms-ordered-task-row { grid-template-columns: 1fr; }
    body.pms-employee-shell .pms-task-ordered-table > tbody > tr > td.pms-task-description-cell { grid-column: auto; }
    body.pms-employee-shell .pms-progress-top-fields,
    body.pms-employee-shell .pms-progress-row { grid-template-columns: 1fr; }
}

/* Employee client directory follows the admin title/search/action hierarchy. */
/* Employee task details: compact sections without the legacy full-width field table. */
body.pms-employee-shell .pms-task-detail-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
body.pms-employee-shell .pms-task-detail-heading h1 { margin: 0; }
body.pms-employee-shell .pms-employee-task-detail .card { margin-bottom: 14px; }
body.pms-employee-shell .pms-employee-task-detail .card-header { min-height: 0; padding: 12px 16px; }
body.pms-employee-shell .pms-employee-task-detail .card-header h2 { margin: 0; font-size: 16px !important; }
body.pms-employee-shell .pms-employee-task-detail .card-body { padding: 16px; }
body.pms-employee-shell .pms-task-detail-summary-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
body.pms-employee-shell .pms-task-detail-summary-top h2 { margin: 0; font-size: 20px !important; overflow-wrap: anywhere; }
body.pms-employee-shell .pms-task-detail-summary-top p { margin: 3px 0 0; color: var(--ui-text-muted); }
body.pms-employee-shell .pms-task-detail-summary-top .pms-status { flex: 0 0 auto; padding: 6px 10px; font-size: 12px; border-radius: var(--ui-radius-pill); }
body.pms-employee-shell .pms-task-detail-summary-top .pms-status--completed { color: var(--ui-success); background: var(--ui-success-soft); }
body.pms-employee-shell .pms-task-detail-summary-top .pms-status--pending,
body.pms-employee-shell .pms-task-detail-summary-top .pms-status--not-started { color: var(--ui-error); background: var(--ui-error-soft); }
body.pms-employee-shell .pms-task-detail-summary-top .pms-status--wip { color: var(--ui-info); background: var(--ui-info-soft); }
body.pms-employee-shell .pms-task-detail-facts { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; margin-top: 16px; }
body.pms-employee-shell .pms-detail-time { display: block; color: var(--ui-text-muted); font-size: 11px; font-weight: 500; }
body.pms-employee-shell .pms-task-detail-facts > div { min-width: 0; padding: 10px 12px; background: var(--ui-surface-soft); border: 1px solid var(--ui-border); border-radius: var(--ui-radius-md); }
body.pms-employee-shell .pms-task-detail-facts span,
body.pms-employee-shell .pms-task-detail-entry span { display: block; color: var(--ui-text-muted); font-size: 11px; font-weight: 600; }
body.pms-employee-shell .pms-task-detail-facts strong,
body.pms-employee-shell .pms-task-detail-entry strong { display: block; margin-top: 3px; color: var(--ui-text-strong); font-size: 13px; font-weight: 600; overflow-wrap: anywhere; }
body.pms-employee-shell .pms-task-detail-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; gap: 14px; }
body.pms-employee-shell .pms-task-detail-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 18px; margin: 0; }
body.pms-employee-shell .pms-task-detail-fields > div { display: flex; min-width: 0; justify-content: space-between; gap: 8px; padding: 9px 0; border-bottom: 1px solid var(--ui-border); }
body.pms-employee-shell .pms-task-detail-fields dt { color: var(--ui-text-muted); font-size: 12px; font-weight: 500; }
body.pms-employee-shell .pms-task-detail-fields dd { max-width: 60%; margin: 0; color: var(--ui-text-strong); font-size: 12px; font-weight: 600; text-align: right; overflow-wrap: anywhere; }
body.pms-employee-shell .pms-task-detail-description { margin-top: 16px; }
body.pms-employee-shell .pms-task-detail-description h3 { margin: 0 0 8px; font-size: 14px !important; }
body.pms-employee-shell .pms-task-detail-description .pms-task-rich-text { max-height: 280px; overflow-y: auto; padding: 12px; background: var(--ui-surface-soft); border: 1px solid var(--ui-border); border-radius: var(--ui-radius-md); }
body.pms-employee-shell .pms-task-detail-entry { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--ui-border); }
body.pms-employee-shell .pms-task-detail-entry:first-child { padding-top: 0; }
body.pms-employee-shell .pms-task-detail-entry:last-child { padding-bottom: 0; border-bottom: 0; }
body.pms-employee-shell .pms-task-detail-expense { grid-template-columns: repeat(2, minmax(0, 1fr)); }
body.pms-employee-shell .pms-task-detail-empty { margin: 0; color: var(--ui-text-muted); font-size: 13px; }
@media (max-width: 1199.98px) {
    body.pms-employee-shell .pms-task-detail-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    body.pms-employee-shell .pms-task-detail-grid { grid-template-columns: 1fr; }
}
@media (max-width: 575.98px) {
    body.pms-employee-shell .pms-task-detail-heading { align-items: flex-start; flex-direction: column; }
    body.pms-employee-shell .pms-task-detail-summary-top { flex-direction: column; }
    body.pms-employee-shell .pms-task-detail-facts,
    body.pms-employee-shell .pms-task-detail-fields { grid-template-columns: 1fr; }
    body.pms-employee-shell .pms-task-detail-entry { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Employee client directory follows the admin title/search/action hierarchy. */
body.pms-employee-shell .pms-employee-client-card .pms-client-list-header {
    min-height: 70px;
    padding: 14px 18px;
    border-bottom: 1px solid var(--ui-border);
}
body.pms-employee-shell .pms-employee-client-card .pms-directory-search {
    width: min(100%, 460px);
    margin-left: auto;
    flex-wrap: nowrap;
}
body.pms-employee-shell .pms-employee-client-card .pms-directory-search .form-control { min-width: 0; }
body.pms-employee-shell .pms-employee-client-card .pms-directory-search .btn { flex: 0 0 auto; }
body.pms-employee-shell .pms-employee-client-card .pms-client-table-wrap {
    overflow-x: auto;
    border-radius: 0;
}
body.pms-employee-shell .pms-employee-client-card table.pms-client-table {
    min-width: 1350px !important;
    table-layout: fixed;
    border-top: 0 !important;
    border-left: 0 !important;
}
body.pms-employee-shell .pms-employee-client-card table.pms-client-table tr > :nth-child(1) { width: 5%; }
body.pms-employee-shell .pms-employee-client-card table.pms-client-table tr > :nth-child(2) { width: 17%; }
body.pms-employee-shell .pms-employee-client-card table.pms-client-table tr > :nth-child(3) { width: 12%; }
body.pms-employee-shell .pms-employee-client-card table.pms-client-table tr > :nth-child(4) { width: 9%; }
body.pms-employee-shell .pms-employee-client-card table.pms-client-table tr > :nth-child(5) { width: 10%; }
body.pms-employee-shell .pms-employee-client-card table.pms-client-table tr > :nth-child(6) { width: 14%; }
body.pms-employee-shell .pms-employee-client-card table.pms-client-table tr > :nth-child(7) { width: 11%; }
body.pms-employee-shell .pms-employee-client-card table.pms-client-table tr > :nth-child(8) { width: 5%; }
body.pms-employee-shell .pms-employee-client-card table.pms-client-table tr > :nth-child(9) { width: 8%; }
body.pms-employee-shell .pms-employee-client-card table.pms-client-table tr > :nth-child(10) { width: 9%; }
body.pms-employee-shell .pms-employee-client-card table.pms-client-table thead th,
body.pms-employee-shell .pms-employee-client-card table.pms-client-table tbody td {
    padding: 9px 10px !important;
    font-size: 12px !important;
    line-height: 1.4;
    border-right: 1px solid var(--ui-border) !important;
    border-bottom: 1px solid var(--ui-border) !important;
}
body.pms-employee-shell .pms-employee-client-card table.pms-client-table tr > :last-child { border-right: 0 !important; }
body.pms-employee-shell .pms-employee-client-card table.pms-client-table thead th {
    color: #5c6470;
    background: #f7f8f9;
    font-weight: 600;
    white-space: nowrap !important;
}
body.pms-employee-shell .pms-employee-client-card .pms-action-group {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}
body.pms-employee-shell .pms-employee-client-card .pms-action-btn {
    color: var(--ui-text);
    background: var(--ui-surface);
    border: 1px solid var(--ui-border-strong);
    border-radius: var(--ui-radius-md);
}
body.pms-employee-shell .pms-employee-client-card .pms-action-btn:hover { background: var(--ui-hover); }
body.pms-employee-shell .pms-employee-client-card .pms-client-list-footer { padding: 10px 16px; }
@media (max-width: 767.98px) {
    body.pms-employee-shell .pms-employee-client-card .pms-client-list-header { align-items: stretch; }
    body.pms-employee-shell .pms-employee-client-card .pms-directory-search { width: 100%; margin-left: 0; }
}

/* Reports follow the same assignment-first reading order as the task list. */
.pms-employee-shell .pms-report-header { display:flex; align-items:center; justify-content:space-between; gap:12px; }
.pms-employee-shell .pms-report-header::after { display:none; }
.pms-employee-shell .pms-report-header h1 { margin:0; font-size:18px !important; }
.pms-employee-shell .pms-report-header small { display:block; margin-top:2px; }
.pms-employee-shell .pms-report-export-actions { display:flex; gap:8px; flex-wrap:wrap; }
.pms-employee-shell .pms-report-filters { display:grid; grid-template-columns:repeat(3,minmax(140px,1fr)) minmax(200px,1.4fr) auto auto; align-items:end; gap:10px; padding:14px 18px; border-bottom:1px solid var(--ui-border); }
.pms-employee-shell .pms-report-filters label { min-width:0; margin:0; }
.pms-employee-shell .pms-report-filters .form-control { margin-top:4px; }
.pms-employee-shell .pms-report-summary { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:10px; padding:12px 18px; border-bottom:1px solid var(--ui-border); }
.pms-employee-shell .pms-report-summary > div { display:flex; align-items:center; justify-content:space-between; gap:8px; padding:10px 12px; background:var(--ui-surface-soft); border:1px solid var(--ui-border); border-radius:var(--ui-radius-md); }
.pms-employee-shell .pms-report-summary span { color:var(--ui-text-muted); font-size:12px; }
.pms-employee-shell .pms-report-summary strong { color:var(--ui-text-strong); font-size:17px; }
@media (max-width:1199.98px) { .pms-employee-shell .pms-report-filters { grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media (max-width:575.98px) { .pms-employee-shell .pms-report-header { align-items:flex-start; flex-direction:column; } .pms-employee-shell .pms-report-filters { grid-template-columns:1fr; } .pms-employee-shell .pms-report-summary { grid-template-columns:1fr; } }
body.pms-employee-shell .pms-employee-report-card .pms-employee-report-toolbar {
    margin: 0;
    padding: 12px 18px;
}
body.pms-employee-shell .pms-employee-report-toolbar .pms-list-title { margin: 0; font-size: 18px !important; }
body.pms-employee-shell .pms-employee-report-card .card-body { overflow-x: auto; }
body.pms-employee-shell .pms-report-ordered-table {
    width: 100%;
    min-width: 0;
    table-layout: fixed;
}
body.pms-employee-shell .pms-report-ordered-table > thead > tr > :nth-child(1) { width: 4%; }
body.pms-employee-shell .pms-report-ordered-table > thead > tr > :nth-child(2) { width: 9%; }
body.pms-employee-shell .pms-report-ordered-table > thead > tr > :nth-child(3) { width: 7%; }
body.pms-employee-shell .pms-report-ordered-table > thead > tr > :nth-child(4) { width: 11%; }
body.pms-employee-shell .pms-report-ordered-table > thead > tr > :nth-child(5) { width: 17%; }
body.pms-employee-shell .pms-report-ordered-table > thead > tr > :nth-child(6) { width: 9%; }
body.pms-employee-shell .pms-report-ordered-table > thead > tr > :nth-child(7) { width: 9%; }
body.pms-employee-shell .pms-report-ordered-table > thead > tr > :nth-child(8) { width: 13%; }
body.pms-employee-shell .pms-report-ordered-table > thead > tr > :nth-child(9) { width: 5%; }
body.pms-employee-shell .pms-report-ordered-table > thead > tr > :nth-child(10) { width: 10%; }
body.pms-employee-shell .pms-report-ordered-table > thead > tr > :nth-child(11) { width: 6%; }
body.pms-employee-shell .pms-report-ordered-table > thead > tr > th,
body.pms-employee-shell .pms-report-ordered-table > tbody > tr > td {
    min-width: 0;
    padding: 7px 6px !important;
    overflow-wrap: anywhere;
    line-height: 1.3;
}
body.pms-employee-shell .pms-report-ordered-table > thead > tr > th { font-size: 11px !important; white-space: normal; }
body.pms-employee-shell .pms-report-ordered-table .pms-date-cell { white-space: normal; font-variant-numeric: tabular-nums; }
body.pms-employee-shell .pms-report-ordered-table .pms-report-primary { color: var(--ui-text-strong); font-weight: 600; text-align: center; }
body.pms-employee-shell .pms-report-ordered-table > tbody > tr > td.pms-report-description {
    min-width: 0;
    max-width: none;
    color: var(--ui-text-muted);
    text-align: left;
}
body.pms-employee-shell .pms-report-ordered-table .pms-report-description-text {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}
body.pms-employee-shell .pms-report-ordered-table .pms-person-badge {
    display: inline-flex;
    max-width: 100%;
    padding: 4px 7px;
    font-size: 11px !important;
    font-weight: 600;
    line-height: 1.2;
    white-space: normal;
    overflow-wrap: normal;
}
body.pms-employee-shell .pms-report-ordered-table .pms-task-status {
    max-width: 100%;
    padding: 4px 7px;
    font-size: 11px !important;
    white-space: nowrap;
    overflow-wrap: normal;
    word-break: keep-all;
}
body.pms-employee-shell .pms-report-ordered-table .pms-task-status--pending {
    white-space: normal;
    overflow-wrap: break-word;
}
body.pms-employee-shell .pms-report-ordered-table .pms-tag-name { padding: 4px 6px; font-size: 11px !important; }

/* Client profile: compact cards with readable, aligned values. */
body.pms-shell .pms-client-details { max-width: 1480px; }
body.pms-shell .pms-client-details-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
}
body.pms-shell .pms-client-details-heading h1 { margin: 0; overflow-wrap: anywhere; }
body.pms-shell .pms-client-details-heading p { margin: 4px 0 0; color: var(--ui-text-muted); font-size: 12px; }
body.pms-shell .pms-client-details-actions { display: flex; flex-wrap: wrap; gap: 8px; }
body.pms-shell .pms-client-details-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: stretch;
    gap: 16px;
}
body.pms-shell .pms-client-detail-card { min-width: 0; margin: 0; overflow: hidden; }
body.pms-shell .pms-client-detail-card--entity { grid-column: 1 / -1; }
body.pms-shell .pms-client-detail-card .card-header { display: flex; align-items: center; min-height: 54px; padding: 13px 18px; }
body.pms-shell .pms-client-detail-card .card-title { float: none; margin: 0; font-size: 16px !important; font-weight: 600; }
body.pms-shell .pms-client-detail-card .card-body { padding: 4px 18px; }
body.pms-shell .pms-client-detail-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 24px;
    margin: 0;
}
body.pms-shell .pms-client-detail-fields > div { min-width: 0; padding: 13px 0; border-bottom: 1px solid var(--ui-border); }
body.pms-shell .pms-client-detail-fields > div:last-child,
body.pms-shell .pms-client-detail-fields > div:nth-last-child(2):nth-child(odd) { border-bottom: 0; }
body.pms-shell .pms-client-detail-fields dt { margin: 0 0 5px; color: var(--ui-text-muted); font-size: 12px; font-weight: 600; line-height: 1.35; }
body.pms-shell .pms-client-details .pms-client-detail-fields dd {
    margin: 0;
    color: var(--ui-text-strong);
    font-size: 14px !important;
    font-weight: 500;
    line-height: 1.45;
    overflow-wrap: anywhere;
}
@media (max-width: 991.98px) {
    body.pms-shell .pms-client-details-grid { grid-template-columns: 1fr; }
    body.pms-shell .pms-client-detail-card--entity { grid-column: auto; }
}
@media (max-width: 575.98px) {
    body.pms-shell .pms-client-detail-fields { grid-template-columns: 1fr; }
    body.pms-shell .pms-client-detail-fields > div:nth-last-child(2) { border-bottom: 1px solid var(--ui-border); }
    body.pms-shell .pms-client-details-actions { width: 100%; }
}

/* Quiet gold dividers distinguish sidebar groups in both workspaces. */
body.pms-shell .nav-sidebar > .nav-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 11px 10px 5px;
    color: #936d31;
    font-size: 11px !important;
    font-weight: 700;
    letter-spacing: .07em;
    white-space: nowrap;
}
body.pms-shell .nav-sidebar > .nav-header::after {
    content: "";
    height: 1px;
    flex: 1;
    background: linear-gradient(90deg, #ad8846, #e5dac5);
}
body.pms-shell .sidebar { padding-top: 5px; }
body.pms-shell .sidebar nav.mt-2 { margin-top: 4px !important; }
body.pms-shell .nav-sidebar > .nav-header:first-child { margin-top: 8px; }
body.pms-shell .nav-sidebar > .nav-item { margin-bottom: 1px; }
body.pms-shell .nav-sidebar .nav-link {
    min-height: 38px;
    gap: 9px;
    padding: 7px 11px;
    line-height: 1.3;
}
body.pms-shell .nav-sidebar .nav-link .nav-icon { color: #817a6f; }
body.pms-shell .nav-sidebar .nav-link.active {
    background: #f5f5f3;
    border-color: #e4e2dd;
    box-shadow: inset 3px 0 0 #a47b35;
}

/* Policy library follows the same restrained card and control rhythm. */
body.pms-employee-shell .pms-policy-card .card-header {
    display: flex;
    align-items: center;
    min-height: 58px;
}
body.pms-employee-shell .pms-policy-card .card-body { padding: 6px 18px; }
body.pms-employee-shell .pms-policy-row {
    min-height: 72px;
    gap: 18px;
    padding: 12px 0;
}
body.pms-employee-shell .pms-policy-document {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 12px;
}
body.pms-employee-shell .pms-policy-icon {
    display: inline-flex;
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    align-items: center;
    justify-content: center;
    color: #8a6733;
    background: #f8f4eb;
    border: 1px solid #eee4d3;
    border-radius: var(--ui-radius-md);
}
body.pms-employee-shell .pms-policy-copy { min-width: 0; }
body.pms-employee-shell .pms-policy-copy strong { font-size: 14px; line-height: 1.35; overflow-wrap: anywhere; }
body.pms-employee-shell .pms-policy-copy small { margin-top: 4px; }
body.pms-employee-shell .pms-policy-open { flex: 0 0 auto; white-space: nowrap; }
@media (max-width: 575.98px) {
    body.pms-employee-shell .pms-policy-row { align-items: stretch; }
    body.pms-employee-shell .pms-policy-open { align-self: flex-start; }
}

/* Task details: fixed label column and left-aligned values for easy scanning. */
body.pms-employee-shell .pms-task-detail-grid { align-items: stretch; }
body.pms-employee-shell .pms-task-detail-grid > .card { min-width: 0; }
body.pms-employee-shell .pms-task-detail-fields { grid-template-columns: 1fr; }
body.pms-employee-shell .pms-task-detail-fields > div {
    display: grid;
    grid-template-columns: minmax(130px, 38%) minmax(0, 1fr);
    align-items: start;
    gap: 14px;
    padding: 10px 0;
}
body.pms-employee-shell .pms-task-detail-fields dt { margin: 0; }
body.pms-employee-shell .pms-task-detail-fields dd {
    max-width: none;
    min-width: 0;
    text-align: left;
}
body.pms-employee-shell .pms-task-detail-entry > div { min-width: 0; }
@media (max-width: 575.98px) {
    body.pms-employee-shell .pms-task-detail-fields > div { grid-template-columns: minmax(110px, 38%) minmax(0, 1fr); }
}

/* Keep completed assignments neutral; status text carries the meaning. */
body.pms-employee-shell .content table.pms-task-ordered-table > tbody > tr.is-completed > td,
body.pms-employee-shell .content table.pms-report-ordered-table > tbody > tr.is-completed > td {
    background: var(--ui-surface) !important;
}
body.pms-employee-shell .pms-task-ordered-table > tbody > tr.is-completed:hover > td,
body.pms-employee-shell .pms-report-ordered-table > tbody > tr.is-completed:hover > td {
    background: var(--ui-brand-subtle) !important;
}
body.pms-employee-shell .pms-task-ordered-table .pms-status--completed,
body.pms-employee-shell .pms-report-ordered-table .pms-task-status--completed {
    color: var(--ui-success);
    background: var(--ui-success-soft);
}

@media (max-width: 1500px) {
    body.pms-employee-shell .pms-employee-report-card .card-body { overflow: visible; }
    body.pms-employee-shell .pms-report-ordered-table,
    body.pms-employee-shell .pms-report-ordered-table > tbody { display: block; width: 100%; min-width: 0; }
    body.pms-employee-shell .pms-report-ordered-table > thead { display: none; }
    body.pms-employee-shell .pms-report-ordered-table > tbody > tr.pms-report-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 14px; margin: 10px; padding: 10px 14px; background: var(--ui-surface); border: 1px solid var(--ui-border); border-left: 3px solid var(--ui-brand); border-radius: var(--ui-radius-md); }
    body.pms-employee-shell .pms-report-ordered-table > tbody > tr.is-completed { border-left-color: var(--ui-success); }
    body.pms-employee-shell .pms-report-ordered-table > tbody > tr > td { display: block; min-width: 0; max-width: none; padding: 7px 0 !important; text-align: left !important; background: transparent !important; border: 0 !important; border-bottom: 1px solid var(--ui-border) !important; }
    body.pms-employee-shell .pms-report-ordered-table > tbody > tr > td::before { display: block; margin-bottom: 3px; color: var(--ui-text-muted); content: attr(data-label); font-size: 11px; font-weight: 600; }
    body.pms-employee-shell .pms-report-ordered-table > tbody > tr > td.pms-report-description { grid-column: span 2; }
    body.pms-employee-shell .pms-report-ordered-table .pms-report-description-text { display: block; -webkit-line-clamp: unset; }
    body.pms-employee-shell .pms-report-ordered-table > tbody > tr:not(.pms-report-row) { display: block; }
    body.pms-employee-shell .pms-report-ordered-table > tbody > tr:not(.pms-report-row) > td { display: block; width: 100%; }
}
@media (max-width: 991.98px) {
    body.pms-employee-shell .pms-report-ordered-table > tbody > tr.pms-report-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 575.98px) {
    body.pms-employee-shell .pms-report-ordered-table > tbody > tr.pms-report-row { grid-template-columns: 1fr; }
    body.pms-employee-shell .pms-report-ordered-table > tbody > tr > td.pms-report-description { grid-column: auto; }
}

/* Website enquiries: shared compact admin rhythm, with independent source tables. */
/* Assignment and billing forms share the same layout in both workspaces. */
.pms-shell .pms-assignment-heading,
.pms-shell .pms-assignment-actions,
.pms-shell .pms-assignment-submit { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; }
.pms-shell .pms-assignment-heading h1,
.pms-shell .pms-assignment-heading h2 { margin: 0; }
.pms-shell .pms-assignment-actions { justify-content: flex-end; gap: 8px; }
.pms-shell .pms-assignment-page,
.pms-shell .pms-billing-page { max-width: 1580px; }
.pms-shell .pms-assignment-form,
.pms-shell .pms-billing-form { width: 100%; max-width: none; }
/* Override the legacy 1040px form limit with the same specificity as its source. */
body.pms-shell .content .container-fluid > form.pms-assignment-form,
body.pms-shell .content .container-fluid > form.pms-billing-form { width: 100%; max-width: none; margin-left: 0; margin-right: 0; }
.pms-shell .pms-billing-section-header { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; }
.pms-shell .pms-billing-section-header > h2 { min-width: 0; float: none; }
.pms-shell .pms-billing-section-header > [data-add-billing-row] { justify-self: end; white-space: nowrap; }
/* AdminLTE clearfix becomes an extra flex/grid child unless suppressed. */
.pms-shell .pms-billing-section-header::after,
.pms-shell .card-header.pms-assignment-heading::after,
.pms-shell .card-header.pms-task-list-header::after { display: none; content: none; }
body.pms-employee-shell .content-header h1 { text-transform: uppercase; margin: 0; }
body.pms-employee-shell .content-header .container-fluid.my-2 { margin-top: 0 !important; margin-bottom: 0 !important; }
body.pms-employee-shell .content-header .row.mb-2 { margin-bottom: 0 !important; }
.pms-shell .pms-assignment-form .card,
.pms-shell .pms-billing-form .card { margin-bottom: 14px; overflow: hidden; }
.pms-shell .pms-assignment-form .card-header,
.pms-shell .pms-billing-form .card-header { min-height: 0; padding: 11px 16px; }
body.pms-shell .pms-assignment-form h2,
body.pms-shell .pms-billing-form h2 { margin: 0; font-size: 15px !important; line-height: 1.35 !important; }
.pms-shell .pms-assignment-fields { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px 16px; padding: 16px; }
.pms-shell .pms-assignment-three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.pms-shell .pms-assignment-fields > div { min-width: 0; }
.pms-shell .pms-assignment-fields label,
.pms-shell .pms-billing-row label { display: block; margin-bottom: 5px; }
.pms-shell .pms-assignment-full { grid-column: 1 / -1; }
.pms-shell .pms-assignment-wide { grid-column: span 2; }
/* Fit each section's actual field count instead of leaving orphaned controls. */
@media (min-width: 1200px) {
    .pms-shell .pms-assignment-client-fields { grid-template-columns: repeat(12, minmax(0, 1fr)); }
    .pms-shell .pms-assignment-client-fields > div { grid-column: span 3; }
    .pms-shell .pms-assignment-client-fields > div:first-child { grid-column: span 4; }
    .pms-shell .pms-assignment-client-fields > div:nth-child(2) { grid-column: span 2; }
    .pms-shell .pms-assignment-schedule-fields { grid-template-columns: minmax(0, .9fr) minmax(0, .9fr) minmax(0, 1.3fr) repeat(2, minmax(0, 1fr)); }
    .pms-shell .pms-assignment-name { grid-column: span 3; }
}
@media (min-width: 576px) and (max-width: 1199.98px) {
    .pms-shell .pms-assignment-schedule-fields > div:nth-child(5) { grid-column: 1 / -1; }
}
.pms-shell .pms-assignment-submit { padding: 4px 0 18px; }
.pms-shell .pms-assignment-submit small { flex: 1; min-width: 200px; }
.pms-shell .pms-inline-billing { scroll-margin-top: calc(var(--ui-header-height) + 12px); }
.pms-shell .pms-inline-billing > .card-body { padding: 10px 14px; }
.pms-shell .pms-inline-billing-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 6px; }
body.pms-shell .pms-inline-billing-heading h3 { margin: 0; font-size: 13px !important; }
.pms-shell .pms-inline-billing-heading .btn { min-height: 30px; padding: 4px 9px; font-size: 12px !important; }
.pms-shell .pms-inline-billing-group { padding: 9px 0; border-top: 1px solid var(--ui-border); }
.pms-shell .pms-inline-billing .pms-billing-row { gap: 8px; padding: 6px 0; }
.pms-shell .pms-inline-billing label { margin-bottom: 4px; }
.pms-shell .pms-inline-billing .pms-assignment-fields { padding: 0; gap: 8px; }
body.pms-shell .pms-inline-billing .form-control { height: 34px; min-height: 34px; padding: 5px 9px; font-size: 12px !important; }
.pms-shell .pms-inline-billing .pms-billing-remove { height: 34px; min-height: 34px; margin-top: 20px; }
.pms-shell .pms-inline-billing .pms-billing-summary { padding: 0 0 9px; }
.pms-shell .pms-inline-billing .pms-billing-summary > div { padding: 6px 8px; }
.pms-shell .pms-inline-billing .pms-billing-summary strong { margin-top: 2px; font-size: 14px; }
@media (max-width: 767.98px) {
    body.pms-shell .pms-inline-billing .form-control { height: 44px; min-height: 44px; }
    .pms-shell .pms-inline-billing .pms-billing-remove { min-height: 44px; margin-top: 0; }
}
.pms-shell .pms-billing-summary { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; padding: 14px 16px; }
.pms-shell .pms-billing-summary > div { min-width: 0; padding: 10px 12px; background: var(--ui-surface-soft); border: 1px solid var(--ui-border); border-radius: var(--ui-radius-md); }
.pms-shell .pms-billing-summary span { display: block; color: var(--ui-text-muted); font-size: 12px; }
.pms-shell .pms-billing-summary strong { display: block; margin-top: 5px; font-size: 17px; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.pms-shell .pms-billing-summary > div:last-child { border-color: #d9c9a9; background: #faf7f0; }
.pms-shell .pms-billing-row { display: grid; align-items: start; grid-template-columns: repeat(4, minmax(0, 1fr)) 38px; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--ui-border); }
.pms-shell .pms-billing-row:first-child { padding-top: 0; }
.pms-shell .pms-billing-row:last-child { padding-bottom: 0; border-bottom: 0; }
.pms-shell .pms-billing-row > div { min-width: 0; }
.pms-shell .pms-billing-row--professional { grid-template-columns: minmax(0, 2fr) minmax(160px, 1fr) 38px; }
.pms-shell .pms-billing-row--expenses { grid-template-columns: repeat(2, minmax(0, 1fr)) 38px; }
.pms-shell .pms-billing-row--advance { grid-template-columns: repeat(3, minmax(0, 1fr)) 38px; }
.pms-shell .pms-billing-form .card-body { padding: 14px 16px; }
.pms-shell .pms-billing-form .form-control { height: 38px; min-height: 38px; padding: 7px 10px; font-size: 12px !important; }
.pms-shell .pms-billing-remove { width: 38px; height: 38px; min-height: 38px; margin-top: 21px; padding: 0; color: var(--ui-error); }
.pms-shell .pms-assignment-form .select2-container { min-width: 0; }
@media (max-width: 1199.98px) {
    .pms-shell .pms-assignment-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pms-shell .pms-billing-summary { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 767.98px) {
    .pms-shell .pms-billing-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pms-shell .pms-billing-remove { margin-top: 0; }
    .pms-shell .pms-billing-form .form-control { min-height: 44px; height: 44px; }
}
@media (max-width: 575.98px) {
    .pms-shell .pms-assignment-fields { grid-template-columns: 1fr; }
    .pms-shell .pms-assignment-wide { grid-column: auto; }
    .pms-shell .pms-billing-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .pms-shell .pms-billing-row { grid-template-columns: 1fr; }
    .pms-shell .pms-assignment-submit .btn { width: 100%; }
}

.pms-shell .pms-website-leads-heading,
.pms-shell .pms-website-leads-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.pms-shell .pms-website-leads-heading h1,
.pms-shell .pms-website-leads-heading h2 { margin: 0; }
.pms-shell .pms-website-leads-actions { justify-content: flex-end; gap: 8px; }
.pms-shell .pms-website-leads-summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-bottom: 16px; }
.pms-shell .pms-website-lead-stat { display: flex; min-width: 0; flex-direction: column; gap: 3px; padding: 16px 18px; color: var(--ui-text); background: var(--ui-surface); border: 1px solid var(--ui-border); border-radius: var(--ui-radius-lg); }
.pms-shell a.pms-website-lead-stat:hover { border-color: #ad8846; background: var(--ui-surface-soft); }
.pms-shell .pms-website-lead-stat strong { color: var(--ui-text-strong); font-size: 28px; line-height: 1.25; font-variant-numeric: tabular-nums; }
.pms-shell .pms-website-lead-stat > span:not(.pms-eyebrow) { color: var(--ui-text-muted); font-size: 12px; }
.pms-shell .pms-website-lead-stat--total { border-top: 3px solid #a47b35; padding-top: 14px; }
.pms-shell .pms-website-lead-filter-card { overflow: hidden; }
.pms-shell .pms-website-lead-filters { display: grid; grid-template-columns: minmax(130px, 1fr) minmax(130px, 1fr) repeat(2, minmax(135px, .8fr)) minmax(180px, 1.4fr) auto auto; align-items: end; gap: 10px; padding: 14px 18px; }
.pms-shell .pms-website-lead-filters > div { min-width: 0; }
.pms-shell .pms-website-lead-filters label { display: block; }
.pms-shell .pms-website-lead-filters .btn { min-height: var(--ui-control-height); }
.pms-shell .pms-website-lead-results { overflow: hidden; }
.pms-shell .pms-website-lead-results[hidden] { display: none !important; }
.pms-shell .pms-website-lead-tabs { position: sticky; top: calc(var(--ui-header-height) + 6px); z-index: 5; display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; padding: 6px; background: var(--ui-surface); border: 1px solid var(--ui-border); border-radius: var(--ui-radius-md); box-shadow: var(--ui-shadow-sm); }
.pms-shell .pms-website-lead-tab { display: inline-flex; min-height: 42px; align-items: center; justify-content: center; gap: 10px; padding: 9px 16px; color: var(--ui-text-muted); font-size: 13px; font-weight: 600; background: transparent; border: 1px solid transparent; border-radius: var(--ui-radius-sm); cursor: pointer; }
.pms-shell .pms-website-lead-tab:hover { color: var(--ui-text-strong); background: var(--ui-hover); }
.pms-shell .pms-website-lead-tab[aria-selected="true"] { color: var(--ui-text-strong); background: #f8f4eb; border-color: #e5dac5; box-shadow: inset 0 -2px 0 #a47b35; }
.pms-shell .pms-website-lead-tab span { padding: 3px 7px; color: inherit; font-size: 12px; font-variant-numeric: tabular-nums; background: var(--ui-hover); border-radius: var(--ui-radius-pill); }
.pms-shell .pms-website-lead-results { scroll-margin-top: calc(var(--ui-header-height) + 78px); }
body.pms-shell .pms-website-lead-results h2 { font-size: 16px !important; }
.pms-shell .pms-website-lead-connection { color: var(--ui-text-muted); font-size: 12px; }
.pms-shell .pms-website-lead-notice { display: flex; align-items: flex-start; gap: 12px; padding: 24px 18px; color: var(--ui-text-muted); }
.pms-shell .pms-website-lead-notice > i { padding-top: 3px; color: #936d31; }
.pms-shell .pms-website-lead-notice strong { color: var(--ui-text); font-size: 13px; }
.pms-shell .pms-website-lead-notice p { margin: 4px 0 0; font-size: 12px; }
body.pms-admin-shell .content table.pms-website-lead-table { min-width: 1050px; table-layout: fixed; border-left: 0 !important; border-top: 0 !important; }
body.pms-admin-shell .content table.pms-website-lead-table > thead > tr > th,
body.pms-admin-shell .content table.pms-website-lead-table > tbody > tr > td { padding: 10px 12px !important; font-size: 12px !important; text-align: left !important; vertical-align: top; overflow-wrap: anywhere; }
.pms-shell .pms-website-lead-table tr > :nth-child(1) { width: 13%; }
.pms-shell .pms-website-lead-table tr > :nth-child(2) { width: 15%; }
.pms-shell .pms-website-lead-table tr > :nth-child(3) { width: 20%; }
.pms-shell .pms-website-lead-table tr > :nth-child(4) { width: 12%; }
.pms-shell .pms-website-lead-table tr > :nth-child(5) { width: 15%; }
.pms-shell .pms-website-lead-table tr > :nth-child(6) { width: 12%; }
.pms-shell .pms-website-lead-table tr > :nth-child(7) { width: 13%; }
.pms-shell .pms-website-lead-status-cell form { margin-top: 6px; }
body.pms-shell .content table.pms-website-lead-table td.pms-website-lead-status-cell .btn.btn-sm { width: auto; min-width: 0; height: auto; min-height: 30px; padding: 4px 8px; white-space: nowrap; }
.pms-shell .pms-website-lead-state { display: inline-flex; padding: 4px 8px; color: var(--ui-text-muted); background: var(--ui-hover); border-radius: var(--ui-radius-pill); font-size: 11px; font-weight: 600; }
.pms-shell .pms-website-lead-state.is-matured { color: var(--ui-success); background: var(--ui-success-soft); }
.pms-shell .pms-website-lead-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 16px; }
.pms-shell .pms-website-lead-form > div { min-width: 0; }
.pms-shell .pms-website-lead-form label { display: block; }
.pms-shell .pms-website-lead-form-wide { grid-column: 1 / -1; }
.pms-shell .pms-website-lead-form small { color: var(--ui-text-muted); }
.pms-shell .pms-website-lead-table td small,
.pms-shell .pms-website-lead-phone { display: block; margin-top: 4px; }
.pms-shell .pms-website-lead-table td a { text-decoration: underline; text-underline-offset: 3px; }
.pms-shell .pms-website-lead-date { font-variant-numeric: tabular-nums; }
.pms-shell .pms-website-lead-details summary { cursor: pointer; color: var(--ui-text); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.pms-shell .pms-website-lead-details dl { margin: 12px 0 0; }
.pms-shell .pms-website-lead-details dl > div + div { margin-top: 10px; }
.pms-shell .pms-website-lead-details dt { color: var(--ui-text-muted); font-weight: 500; }
.pms-shell .pms-website-lead-details dd { margin: 3px 0 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.pms-shell [data-lead-status] { display: block; margin-top: 3px; font-size: 10px !important; line-height: 1.2; }
.pms-shell #website-leads-today .pms-dashboard-metric-copy { min-height: 49px; }
/* Lead center: the looping video is the stage, with one choice on each side of the character. */
.pms-shell .pms-lead-center-hero {
    position: relative;
    display: flex;
    align-items: center;
    /* Fill the screen down to just above the footer. */
    height: max(460px, calc(100vh - 290px));
    overflow: hidden;
    background: #e9e9e9;
    border: 1px solid var(--ui-border-strong);
    border-radius: var(--ui-radius-lg);
    box-shadow: var(--ui-shadow-sm);
    isolation: isolate;
}
.pms-shell .pms-lead-center-video-frame {
    position: absolute;
    inset: 0;
    z-index: -1;
    display: flex;
    justify-content: center;
    pointer-events: none;
}
.pms-shell .content .pms-lead-center-hero video.pms-lead-center-video {
    display: block;
    width: auto !important;
    max-width: 100% !important;
    height: 100% !important;
    object-fit: contain;
    /* Long soft fade on every edge so the clip melts into the panel instead of showing a box. */
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 22%, #000 78%, transparent 100%), linear-gradient(180deg, transparent 0%, #000 8%, #000 94%, transparent 100%);
    -webkit-mask-composite: source-in;
    mask-image: linear-gradient(90deg, transparent 0%, #000 22%, #000 78%, transparent 100%), linear-gradient(180deg, transparent 0%, #000 8%, #000 94%, transparent 100%);
    mask-composite: intersect;
    opacity: 0;
    transform: scale(1.03);
    transition: opacity 1s ease, transform 1.6s ease;
}
.pms-shell .content .pms-lead-center-hero video.pms-lead-center-video.is-ready { opacity: 1; transform: none; }
.pms-shell .pms-lead-center-sound {
    position: absolute;
    right: 16px;
    bottom: 16px;
    z-index: 2;
    display: grid;
    width: 40px;
    height: 40px;
    place-items: center;
    padding: 0;
    color: #8a6733;
    background: rgba(255, 255, 255, .82);
    border: 1px solid #eadfc8;
    border-radius: 50%;
    box-shadow: 0 6px 18px rgba(36, 36, 36, .12);
    cursor: pointer;
    transition: background .2s ease, color .2s ease;
}
.pms-shell .pms-lead-center-sound:hover,
.pms-shell .pms-lead-center-sound:focus-visible { color: #fff; background: #aa864a; border-color: #aa864a; }
.pms-shell .pms-lead-center-grid {
    display: grid;
    width: 100%;
    grid-template-columns: minmax(0, 1fr) minmax(220px, 34%) minmax(0, 1fr);
    grid-template-areas: "left . right";
    align-items: center;
    padding: 32px clamp(20px, 3vw, 48px);
}
.pms-shell .pms-lead-center-option:first-child { grid-area: left; justify-self: end; }
.pms-shell .pms-lead-center-option:last-child { grid-area: right; justify-self: start; }
.pms-shell .pms-lead-center-option {
    display: flex;
    align-items: center;
    gap: 14px;
    width: min(100%, 330px);
    padding: 14px 14px 14px 16px;
    color: var(--ui-text) !important;
    text-decoration: none !important;
    background: rgba(255, 255, 255, .78);
    border: 1px solid rgba(255, 255, 255, .9);
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(36, 36, 36, .12), inset 0 0 0 1px rgba(170, 134, 74, .12);
    -webkit-backdrop-filter: blur(10px) saturate(1.2);
    backdrop-filter: blur(10px) saturate(1.2);
    transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.pms-shell .pms-lead-center-option:hover,
.pms-shell .pms-lead-center-option:focus-visible {
    background: rgba(255, 255, 255, .94);
    box-shadow: 0 16px 38px rgba(36, 36, 36, .18), inset 0 0 0 1px rgba(170, 134, 74, .45);
    transform: translateY(-3px);
}
.pms-shell .pms-lead-center-icon {
    display: grid;
    width: 46px;
    height: 46px;
    flex: 0 0 46px;
    place-items: center;
    color: #8a6733;
    font-size: 18px;
    background: #f8f4eb;
    border: 1px solid #eadfc8;
    border-radius: 12px;
}
.pms-shell .pms-lead-center-copy { flex: 1 1 auto; min-width: 0; }
.pms-shell .pms-lead-center-copy strong { display: block; color: var(--ui-text-strong); font-size: 17px; font-weight: 600; line-height: 1.3; }
.pms-shell .pms-lead-center-arrow {
    display: grid;
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
    place-items: center;
    color: #8a6733;
    font-size: 13px;
    border: 1px solid #eadfc8;
    border-radius: 50%;
    transition: background .2s ease, color .2s ease, border-color .2s ease, transform .2s ease;
}
.pms-shell .pms-lead-center-option:hover .pms-lead-center-arrow,
.pms-shell .pms-lead-center-option:focus-visible .pms-lead-center-arrow {
    color: #fff;
    background: #aa864a;
    border-color: #aa864a;
    transform: translateX(2px);
}
@media (max-width: 991.98px) {
    .pms-shell .pms-lead-center-hero { flex-direction: column; align-items: stretch; height: auto; }
    .pms-shell .pms-lead-center-video-frame { position: relative; inset: auto; }
    .pms-shell .content .pms-lead-center-hero video.pms-lead-center-video { width: 100% !important; height: auto !important; aspect-ratio: 16 / 9; }
    .pms-shell .pms-lead-center-grid { grid-template-columns: 1fr; grid-template-areas: none; gap: 12px; padding: 16px; }
    .pms-shell .pms-lead-center-option:first-child,
    .pms-shell .pms-lead-center-option:last-child { grid-area: auto; justify-self: stretch; width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
    .pms-shell .content .pms-lead-center-hero video.pms-lead-center-video,
    .pms-shell .pms-lead-center-option,
    .pms-shell .pms-lead-center-arrow { transition: none; transform: none !important; }
}
.pms-shell .pms-lead-register-actions { display: flex; flex-wrap: wrap; gap: 8px; }
@media (max-width: 1399.98px) {
    .pms-shell .pms-website-lead-filters { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .pms-shell .pms-website-lead-search { grid-column: span 2; }
}
@media (max-width: 767.98px) {
    .pms-shell .pms-website-leads-summary { grid-template-columns: 1fr; gap: 8px; }
    .pms-shell .pms-website-lead-stat { padding: 12px 14px; }
    .pms-shell .pms-website-lead-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 14px; }
    .pms-shell .pms-website-lead-search { grid-column: 1 / -1; }
    .pms-shell .pms-website-leads-heading { align-items: flex-start; }
    .pms-shell .pms-website-lead-form { grid-template-columns: 1fr; }
    .pms-shell .pms-website-lead-form-wide { grid-column: auto; }
}

/* Keep shared UI content on the same scale in both workspaces, including nested tables. */
body.pms-shell .content table.table :is(th, td, td span, td a:not(.btn), td small) {
    font-size: var(--ui-font-table) !important;
    line-height: 1.4;
}
body.pms-shell .content table.table:is(.pms-task-list-grid, .pms-task-ordered-table, .pms-report-ordered-table) > thead > tr > th {
    font-size: var(--ui-font-kicker) !important;
    line-height: 1.35;
}
body.pms-shell .content table.table:is(.pms-task-list-grid, .pms-task-ordered-table, .pms-report-ordered-table) > tbody > tr > td {
    padding: 8px 6px !important;
}
body.pms-shell .content .card .card-header :is(h2, h3, .card-title) {
    font-size: var(--ui-font-card-title) !important;
    line-height: 1.4 !important;
}
body.pms-employee-shell .pms-employee-dashboard .pms-stat-col .small-box.card .inner h3 {
    font-size: var(--ui-font-metric) !important;
    line-height: 1.1 !important;
}
body.pms-employee-shell .content > .pms-employee-dashboard { max-width: 1580px; }
@media (max-width: 767.98px) {
    body.pms-shell { --ui-font-page-title: 22px; }
}
@media (max-width: 575.98px) {
    body.pms-shell { --ui-font-metric: 19px; }
}

/* Manual lead register: compact rows with stable columns and readable long scopes. */
.pms-shell .pms-manual-leads-card { overflow: hidden; }
.pms-shell .pms-manual-leads-toolbar { min-height: 66px; padding: 12px 18px; }
.pms-shell .pms-manual-leads-toolbar .pms-eyebrow { margin: 0; }
.pms-shell .pms-manual-leads-toolbar .pms-directory-search { width: min(100%, 520px); margin-left: auto; }
.pms-shell .pms-lead-delete-toggle { color: var(--ui-error); border-color: rgba(220, 69, 69, .3); }
.pms-shell .pms-lead-delete-toggle:hover { color: var(--ui-error); background: var(--ui-error-soft); }
.pms-shell .pms-lead-selection-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 9px 16px;
    color: var(--ui-text);
    font-size: 12px;
    background: var(--ui-surface-soft);
    border-bottom: 1px solid var(--ui-border);
}
.pms-shell .pms-lead-selection-bar[hidden] { display: none !important; }
.pms-shell .pms-manual-leads-table .pms-lead-select-checkbox { display: none; width: 17px; height: 17px; margin: 0 auto; cursor: pointer; accent-color: var(--ui-accent); }
.pms-shell .pms-manual-leads-card.is-selecting .pms-lead-serial { display: none; }
.pms-shell .pms-manual-leads-card.is-selecting .pms-lead-select-checkbox { display: block; }
.pms-shell .pms-manual-leads-card.is-selecting table.pms-manual-leads-table > tbody > tr:has(.pms-lead-select-checkbox:checked) > td { background: var(--ui-brand-subtle); }
.pms-shell .pms-manual-leads-table-wrap { border-radius: 0; }
body.pms-admin-shell .content table.pms-manual-leads-table {
    width: 100%;
    min-width: 980px;
    table-layout: fixed;
    margin: 0;
    border-collapse: collapse;
    border: 0 !important;
}
body.pms-admin-shell .content table.pms-manual-leads-table > thead > tr > th,
body.pms-admin-shell .content table.pms-manual-leads-table > tbody > tr > td {
    padding: 12px 14px !important;
    border: 1px solid var(--ui-border-strong) !important;
    vertical-align: middle;
    overflow-wrap: anywhere;
    text-align: center !important;
}
body.pms-admin-shell .content table.pms-manual-leads-table > thead > tr > th {
    padding-top: 11px !important;
    padding-bottom: 11px !important;
    background: var(--ui-surface-soft);
    text-align: center !important;
    vertical-align: middle;
    white-space: nowrap;
}
body.pms-admin-shell .content table.pms-manual-leads-table tr > :first-child { border-left: 0 !important; }
body.pms-admin-shell .content table.pms-manual-leads-table tr > :last-child { border-right: 0 !important; }
body.pms-admin-shell .content table.pms-manual-leads-table > thead > tr > th { border-top: 0 !important; }
body.pms-admin-shell .content table.pms-manual-leads-table > tbody > tr:last-child > td { border-bottom: 0 !important; }
body.pms-admin-shell .content table.pms-manual-leads-table > tbody > tr > td.pms-empty-state-row { text-align: center !important; padding: 36px 16px !important; }
body.pms-admin-shell .content table.pms-manual-leads-table > tbody > tr > td:first-child { text-align: center !important; }
/* One type size for every piece of text in the register. */
body.pms-shell .content table.pms-manual-leads-table :is(td, td *) { font-size: var(--ui-font-table) !important; line-height: 1.5; }
.pms-shell .pms-manual-leads-table tr > :nth-child(1) { width: 64px; }
.pms-shell .pms-manual-leads-table tr > :nth-child(2) { width: 120px; }
.pms-shell .pms-manual-leads-table tr > :nth-child(3) { width: 18%; }
.pms-shell .pms-manual-leads-table tr > :nth-child(4) { width: 22%; }
.pms-shell .pms-manual-leads-table tr > :nth-child(5) { width: 21%; }
.pms-shell .pms-manual-leads-table tr > :nth-child(6) { width: 230px; }
.pms-shell .pms-manual-leads-table tr > :nth-child(7) { width: 13%; }
.pms-shell .pms-manual-leads-table .pms-lead-index { color: var(--ui-text-muted); font-variant-numeric: tabular-nums; }
.pms-shell .pms-manual-leads-table .pms-lead-entity { display: block; color: var(--ui-text-strong); font-weight: 600; }
.pms-shell .pms-manual-leads-table .pms-lead-date {
    white-space: nowrap; font-variant-numeric: tabular-nums;
}
.pms-shell .pms-manual-leads-table .pms-lead-scope {
    display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 4; line-clamp: 4; overflow: hidden;
    white-space: pre-line; color: var(--ui-text);
}
.pms-shell .pms-manual-leads-table .pms-lead-person { display: block; color: var(--ui-text-strong); font-weight: 600; margin-bottom: 4px; }
.pms-shell .pms-manual-leads-table .pms-lead-contact-line {
    display: flex; align-items: baseline; justify-content: center; gap: 8px; margin-top: 2px;
    color: var(--ui-text-muted); text-decoration: none;
}
.pms-shell .pms-manual-leads-table .pms-lead-contact-line i { width: 14px; flex: 0 0 14px; text-align: center; color: var(--ui-text-subtle); }
.pms-shell .pms-manual-leads-table .pms-lead-contact-line span { min-width: 0; overflow-wrap: anywhere; }
.pms-shell .pms-manual-leads-table .pms-lead-contact-line:hover span { color: var(--ui-text-strong); text-decoration: underline; text-underline-offset: 3px; }
.pms-shell .pms-manual-leads-table .pms-lead-fees {
    display: grid; grid-template-columns: auto auto; row-gap: 2px; width: max-content; max-width: 100%; margin: 0 auto;
    font-variant-numeric: tabular-nums;
}
.pms-shell .pms-manual-leads-table .pms-lead-fees dt { margin: 0; padding-right: 16px; text-align: left; font-weight: 400; color: var(--ui-text-muted); }
.pms-shell .pms-manual-leads-table .pms-lead-fees dd { margin: 0; text-align: right; color: var(--ui-text); white-space: nowrap; }
.pms-shell .pms-manual-leads-table .pms-lead-fees .pms-lead-fees-total {
    margin-top: 5px; padding-top: 5px; border-top: 1px solid var(--ui-border-strong);
    color: var(--ui-text-strong); font-weight: 700;
}
.pms-shell .pms-manual-leads-table .pms-lead-assignee { display: inline-flex; align-items: center; gap: 8px; color: var(--ui-text-strong); font-weight: 500; }
.pms-shell .pms-manual-leads-table .pms-lead-avatar {
    display: inline-grid; place-items: center; flex: 0 0 24px; width: 24px; height: 24px; border-radius: 50%;
    background: var(--ui-accent); color: #fff; font-weight: 600;
}
.pms-shell #addManualLead .modal-dialog { max-width: min(900px, calc(100vw - 24px)); }
.pms-shell .pms-manual-lead-fields { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px 16px; }
.pms-shell .pms-manual-lead-fields > div { min-width: 0; }
.pms-shell .pms-manual-lead-fields label { display: block; }
.pms-shell .pms-manual-lead-fields .pms-lead-field-scope { grid-column: 1 / -1; }
.pms-shell .pms-manual-lead-form > small { display: block; margin-top: 12px; }
@media (max-width: 767.98px) {
    .pms-shell .pms-manual-leads-toolbar { align-items: stretch; flex-direction: column; }
    .pms-shell .pms-manual-leads-toolbar .pms-directory-search { width: 100%; margin-left: 0; }
    .pms-shell .pms-manual-lead-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 575.98px) {
    .pms-shell .pms-manual-lead-fields { grid-template-columns: 1fr; }
    .pms-shell .pms-manual-lead-fields .pms-lead-field-scope { grid-column: auto; }
}

/* RLL Policies: one bordered register, name column carries the weight, compact action column. */
.pms-shell .pms-policies-card { overflow: hidden; }
.pms-shell .pms-policies-toolbar { min-height: 58px; padding: 12px 18px; }
.pms-shell .pms-policies-toolbar .pms-eyebrow { margin: 0; }
.pms-shell .pms-policies-count {
    margin-left: auto; padding: 3px 10px; color: var(--ui-text-muted);
    background: var(--ui-surface-soft); border: 1px solid var(--ui-border); border-radius: var(--ui-radius-pill);
}
body.pms-admin-shell .content table.table.pms-policies-table {
    width: 100%; min-width: 620px; margin: 0; table-layout: fixed; border-collapse: collapse; border: 0 !important;
}
body.pms-admin-shell .content table.table.pms-policies-table > thead > tr > th,
body.pms-admin-shell .content table.table.pms-policies-table > tbody > tr > td {
    padding: 12px 16px !important;
    border: 1px solid var(--ui-border-strong) !important;
    vertical-align: middle;
    text-align: center !important;
    white-space: normal;
    overflow-wrap: anywhere;
}
body.pms-admin-shell .content table.table.pms-policies-table > thead > tr > th { background: var(--ui-surface-soft); white-space: nowrap; }
body.pms-admin-shell .content table.table.pms-policies-table tr > :first-child { border-left: 0 !important; }
body.pms-admin-shell .content table.table.pms-policies-table tr > :last-child { border-right: 0 !important; }
body.pms-admin-shell .content table.table.pms-policies-table > tbody > tr:last-child > td { border-bottom: 0 !important; }
body.pms-admin-shell .content table.table.pms-policies-table > tbody > tr > td:nth-child(2) { text-align: left !important; }
body.pms-admin-shell .content table.table.pms-policies-table > tbody > tr > td.pms-empty-state-row { text-align: center !important; padding: 36px 16px !important; }
.pms-shell .pms-policies-table tr > :nth-child(1) { width: 90px; }
.pms-shell .pms-policies-table tr > :nth-child(3) { width: 190px; }
.pms-shell .pms-policies-table .pms-policy-index { color: var(--ui-text-muted); font-variant-numeric: tabular-nums; }
.pms-shell .pms-policies-table .pms-policy-name { display: flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; }
.pms-shell .pms-policies-table .pms-policy-icon {
    display: grid; width: 38px; height: 38px; flex: 0 0 38px; place-items: center;
    color: #8a6733; font-size: 17px !important; background: #f8f4eb; border: 1px solid #eadfc8; border-radius: 10px;
}
.pms-shell .pms-policies-table .pms-policy-icon i { font-size: 17px !important; }
.pms-shell .pms-policies-table .pms-policy-copy { display: grid; min-width: 0; gap: 2px; }
.pms-shell .pms-policies-table .pms-policy-copy strong { color: var(--ui-text-strong); font-weight: 600; }
.pms-shell .pms-policies-table .pms-policy-copy small { color: var(--ui-text-muted); }
.pms-shell .pms-policies-table .pms-policy-name:hover strong { text-decoration: underline; text-underline-offset: 3px; }
.pms-shell .pms-policies-table .pms-policy-actions { display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.pms-shell .pms-policies-table .pms-policy-actions .btn {
    display: inline-grid; width: 34px; height: 34px; padding: 0; margin: 0; place-items: center; border-radius: 8px;
}

/* Staff details: five key columns plus actions; everything else lives in the detail modal. */
.pms-shell .pms-staff-heading-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.pms-shell .pms-staff-card { overflow: hidden; }
.pms-shell .pms-staff-toolbar { min-height: 66px; padding: 12px 18px; }
.pms-shell .pms-staff-toolbar .pms-eyebrow { margin: 0; }
.pms-shell .pms-staff-toolbar .pms-directory-search { width: min(100%, 560px); margin-left: auto; }
body.pms-admin-shell .content table.table.pms-staff-list-table {
    width: 100%; min-width: 820px; margin: 0; table-layout: fixed; border-collapse: collapse; border: 0 !important;
}
body.pms-admin-shell .content table.table.pms-staff-list-table > thead > tr > th,
body.pms-admin-shell .content table.table.pms-staff-list-table > tbody > tr > td {
    padding: 11px 16px !important;
    border: 1px solid var(--ui-border-strong) !important;
    vertical-align: middle;
    text-align: center !important;
    white-space: normal;
    overflow-wrap: anywhere;
}
body.pms-admin-shell .content table.table.pms-staff-list-table > thead > tr > th { background: var(--ui-surface-soft); white-space: nowrap; }
body.pms-admin-shell .content table.table.pms-staff-list-table tr > :first-child { border-left: 0 !important; }
body.pms-admin-shell .content table.table.pms-staff-list-table tr > :last-child { border-right: 0 !important; }
body.pms-admin-shell .content table.table.pms-staff-list-table > tbody > tr:last-child > td { border-bottom: 0 !important; }
body.pms-admin-shell .content table.table.pms-staff-list-table > tbody > tr > td.pms-empty-state-row { text-align: center !important; padding: 36px 16px !important; }
.pms-shell .pms-staff-list-table tr > :nth-child(1) { width: 80px; }
.pms-shell .pms-staff-list-table tr > :nth-child(3),
.pms-shell .pms-staff-list-table tr > :nth-child(4) { width: 15%; }
.pms-shell .pms-staff-list-table tr > :nth-child(5) { width: 22%; }
.pms-shell .pms-staff-list-table tr > :nth-child(6) { width: 170px; }
.pms-shell .pms-staff-list-table .pms-staff-index { color: var(--ui-text-muted); font-variant-numeric: tabular-nums; }
.pms-shell .pms-staff-list-table .pms-staff-date { font-variant-numeric: tabular-nums; white-space: nowrap; }
.pms-shell .pms-staff-person { display: inline-flex; align-items: center; gap: 10px; min-width: 0; }
.pms-shell .pms-staff-name { color: var(--ui-text-strong); font-weight: 600; text-transform: capitalize; }
.pms-shell .pms-staff-avatar {
    display: inline-grid; width: 30px; height: 30px; flex: 0 0 30px; place-items: center; border-radius: 50%;
    color: #8a6733; font-weight: 600; background: #f8f4eb; border: 1px solid #eadfc8;
}
.pms-shell .pms-staff-actions { display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.pms-shell .pms-staff-actions .btn {
    display: inline-grid; width: 34px; height: 34px; padding: 0; margin: 0; place-items: center; border-radius: 8px;
}
.pms-shell #staffDetailModal .modal-dialog { max-width: min(560px, calc(100vw - 24px)); }
.pms-shell .pms-staff-detail-head { display: flex; align-items: center; gap: 14px; min-width: 0; }
.pms-shell .pms-staff-detail-head .modal-title { margin: 0; text-transform: capitalize; }
.pms-shell .pms-staff-avatar-lg { width: 48px; height: 48px; flex-basis: 48px; font-size: 20px; }
.pms-shell .pms-staff-role {
    display: inline-block; margin-top: 4px; padding: 1px 10px; color: var(--ui-text-muted); font-size: 12px;
    background: var(--ui-surface-soft); border: 1px solid var(--ui-border); border-radius: var(--ui-radius-pill);
}
.pms-shell .pms-staff-detail-list {
    display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); margin: 0;
    border-top: 1px solid var(--ui-border-strong); border-left: 1px solid var(--ui-border-strong);
}
.pms-shell .pms-staff-detail-list > div {
    min-width: 0; padding: 10px 14px;
    border-right: 1px solid var(--ui-border-strong); border-bottom: 1px solid var(--ui-border-strong);
}
.pms-shell .pms-staff-detail-list .pms-staff-detail-wide { grid-column: 1 / -1; }
.pms-shell .pms-staff-detail-list dt { margin: 0 0 2px; color: var(--ui-text-muted); font-size: 11px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.pms-shell .pms-staff-detail-list dd { margin: 0; color: var(--ui-text-strong); overflow-wrap: anywhere; }
.pms-shell .pms-staff-detail-list dd a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 767.98px) {
    .pms-shell .pms-staff-toolbar { align-items: stretch; flex-direction: column; }
    .pms-shell .pms-staff-toolbar .pms-directory-search { width: 100%; margin-left: 0; }
    .pms-shell .pms-staff-detail-list { grid-template-columns: 1fr; }
}

/* Website leads: share the filtered list as a formatted message. */
.pms-shell .pms-website-lead-head-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 12px; }
.pms-shell .pms-lead-share-open { display: inline-flex; align-items: center; gap: 6px; }
.pms-shell #shareLeadsModal .modal-dialog { max-width: min(560px, calc(100vw - 24px)); }
.pms-shell .pms-lead-share-meta { margin: 0 0 10px; color: var(--ui-text-muted); font-size: 13px; }
.pms-shell .pms-lead-share-meta.is-error { color: #b42318; }
.pms-shell .pms-lead-share-text {
    min-height: 300px; resize: vertical; font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
    font-size: 13px; line-height: 1.55; background: var(--ui-surface-soft); white-space: pre-wrap;
}
.pms-shell .pms-lead-share-actions { gap: 8px; }
.pms-shell .pms-lead-share-actions .btn { display: inline-flex; align-items: center; gap: 7px; margin: 0; }
.pms-shell .pms-lead-share-actions .is-copied { color: #1e7b46 !important; border-color: #1e7b46 !important; }
.pms-shell .pms-lead-share-whatsapp { color: #fff !important; background: #1f9e55; border: 1px solid #1f9e55; }
.pms-shell .pms-lead-share-whatsapp:hover, .pms-shell .pms-lead-share-whatsapp:focus-visible { background: #178445; border-color: #178445; }
.pms-shell .pms-lead-share-whatsapp.disabled { opacity: .55; pointer-events: none; }
.pms-shell .pms-lead-share-whatsapp i { font-size: 16px; }

/* New website lead alert: stays on screen until dismissed. */
.pms-lead-alert {
    position: fixed; right: 20px; bottom: 20px; z-index: 2000;
    width: min(380px, calc(100vw - 32px)); overflow: hidden;
    color: var(--ui-text); background: var(--ui-surface, #fff);
    border: 1px solid #eadfc8; border-radius: 16px;
    box-shadow: 0 18px 50px rgba(36, 36, 36, .22);
    transform: translateY(24px); opacity: 0;
    transition: transform .35s cubic-bezier(.2, .9, .3, 1.2), opacity .25s ease;
}
.pms-lead-alert.is-visible { transform: none; opacity: 1; }
.pms-lead-alert::before { content: ""; position: absolute; inset: 0 0 auto; height: 4px; background: #aa864a; }
.pms-lead-alert-head { display: flex; align-items: center; gap: 12px; padding: 16px 16px 10px; }
.pms-lead-alert-bell {
    display: grid; width: 40px; height: 40px; flex: 0 0 40px; place-items: center; border-radius: 12px;
    color: #8a6733; background: #f8f4eb; border: 1px solid #eadfc8; animation: pms-lead-ring 1.2s ease 2;
}
.pms-lead-alert-head strong { display: block; color: var(--ui-text-strong); font-size: 16px; line-height: 1.3; }
.pms-lead-alert-head small { color: var(--ui-text-muted); font-size: 12px; }
.pms-lead-alert-close {
    margin-left: auto; align-self: flex-start; padding: 2px 6px; color: var(--ui-text-muted);
    font-size: 20px; line-height: 1; background: none; border: 0; cursor: pointer;
}
.pms-lead-alert-list { max-height: 240px; margin: 0; padding: 0 16px; overflow-y: auto; list-style: none; }
.pms-lead-alert-list li { padding: 9px 0; border-top: 1px solid var(--ui-border); }
.pms-lead-alert-list li strong { display: block; color: var(--ui-text-strong); font-size: 14px; }
.pms-lead-alert-list li span { display: block; color: var(--ui-text-muted); font-size: 12px; }
.pms-lead-alert-actions { display: flex; gap: 8px; padding: 12px 16px 16px; }
.pms-lead-alert-actions .btn { flex: 1 1 0; margin: 0; }
.pms-lead-alert-enable {
    position: fixed; right: 20px; bottom: 20px; z-index: 1990; display: flex; align-items: center; gap: 10px;
    max-width: calc(100vw - 32px); padding: 10px 12px 10px 14px; font-size: 13px; color: var(--ui-text);
    background: var(--ui-surface, #fff); border: 1px solid #eadfc8; border-radius: 12px; box-shadow: 0 10px 30px rgba(36, 36, 36, .15);
}
.pms-lead-alert-enable i { color: #8a6733; }
.pms-lead-alert-enable .btn { margin: 0; white-space: nowrap; }
@keyframes pms-lead-ring {
    0%, 100% { transform: rotate(0); } 15% { transform: rotate(14deg); } 30% { transform: rotate(-12deg); }
    45% { transform: rotate(8deg); } 60% { transform: rotate(-6deg); } 75% { transform: rotate(3deg); }
}
@media (prefers-reduced-motion: reduce) {
    .pms-lead-alert { transition: none; }
    .pms-lead-alert-bell { animation: none; }
}
