@font-face {
    font-family: "Material Symbols Outlined";
    font-style: normal;
    font-weight: 400 700;
    font-display: block;
    src: url("fonts/material-symbols-outlined.woff2") format("woff2");
}

:root {
    color-scheme: light;
    --ink: #181d26;
    --ink-deep: #0d1218;
    --text: #333840;
    --muted: #666c76;
    --canvas: #eef6fb;
    --surface: #ffffff;
    --surface-low: #f8fafc;
    --surface-warm: #f5e9d4;
    --border: #d5e0e8;
    --border-strong: #929fac;
    --primary: #0f6fbf;
    --primary-dark: #0b4f8a;
    --primary-rgb: 15, 111, 191;
    --primary-soft: #eef7fd;
    --teal: #14b8a6;
    --teal-dark: #0f8f88;
    --teal-rgb: 20, 184, 166;
    --navy: #0b263f;
    --navy-deep: #071b2e;
    --accent: #aa2d00;
    --danger: #c5334d;
    --danger-soft: #fff0f3;
    --warning: #8a650b;
    --warning-soft: #fff4d8;
    --success: #147a57;
    --success-soft: #e7f6e9;
    --info-soft: #f2f7ff;
    --focus: rgba(170, 45, 0, .30);
    --shadow: 0 22px 54px rgba(11, 38, 63, .10), 0 5px 16px rgba(11, 38, 63, .05);
    --shadow-soft: 0 10px 28px rgba(11, 38, 63, .07);
    --sidebar: 278px;
    --radius: 22px;
    --radius-control: 10px;
    --font-sans: "Inter", "Segoe UI", Arial, sans-serif;
    --font-mono: "JetBrains Mono", Consolas, monospace;
}

html[data-theme="dark"] {
    --ink: #edf4f8;
    --ink-deep: #f7fafc;
    --text: #d3dde4;
    --muted: #9dafbc;
    --canvas: #101720;
    --surface: #18232e;
    --surface-low: #202c38;
    --surface-warm: #2d3030;
    --border: #344655;
    --border-strong: #617485;
    --primary: #65b3ef;
    --primary-dark: #9bd2f7;
    --primary-soft: #15344b;
    --teal: #62d2c5;
    --teal-dark: #82e2d8;
    --navy: #091a29;
    --navy-deep: #06121c;
    --accent: #ffad89;
    --danger: #ff9cab;
    --danger-soft: #3c2029;
    --warning: #f2d188;
    --warning-soft: #3b321f;
    --success: #83d9a4;
    --success-soft: #1a382a;
    --info-soft: #173149;
    --focus: rgba(255, 173, 137, .32);
    --shadow: 0 20px 52px rgba(0, 0, 0, .24);
    --shadow-soft: 0 9px 24px rgba(0, 0, 0, .17);
}

html {
    scrollbar-color: rgba(170, 45, 0, .58) rgba(71, 82, 96, .07);
    scrollbar-width: thin;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

html::-webkit-scrollbar { width: 11px; height: 11px; }
html::-webkit-scrollbar-track { background: rgba(71, 82, 96, .07); }
html::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, rgba(170, 45, 0, .78), rgba(203, 134, 72, .82));
    border: 2px solid rgba(238, 246, 251, .94);
    border-radius: 999px;
    background-clip: padding-box;
}

body { color: var(--text); background: var(--canvas); font: 500 14px/1.55 var(--font-sans); }
.material-symbols-outlined {
    display: inline-block;
    flex: 0 0 auto;
    font-family: "Material Symbols Outlined";
    font-size: 20px;
    font-style: normal;
    font-weight: normal;
    font-feature-settings: "liga";
    font-variation-settings: "FILL" 0, "wght" 500, "GRAD" 0, "opsz" 24;
    letter-spacing: normal;
    line-height: 1;
    text-transform: none;
    vertical-align: middle;
    white-space: nowrap;
    word-wrap: normal;
    -webkit-font-feature-settings: "liga";
    -webkit-font-smoothing: antialiased;
}
.ui-icon, .nav-icon { width: auto; height: auto; }

.skip-link {
    color: #fff;
    background: var(--ink-deep);
    border: 1px solid var(--ink-deep);
    box-shadow: 0 8px 18px rgba(11, 15, 25, .18);
    font-weight: 700;
}

.button {
    min-height: 40px;
    padding: 9px 15px;
    border-radius: 10px;
    box-shadow: 0 7px 14px rgba(15, 111, 191, .18);
    font-size: 12px;
    font-weight: 800;
    transition: transform .18s cubic-bezier(.2, .75, .3, 1), box-shadow .18s cubic-bezier(.2, .75, .3, 1), background .18s cubic-bezier(.2, .75, .3, 1);
}
.button-primary { background: linear-gradient(135deg, var(--primary), #1689c6); }
.button-primary:hover { background: linear-gradient(135deg, var(--primary-dark), var(--primary)); box-shadow: 0 10px 18px rgba(15, 111, 191, .25); }
.button-secondary { color: var(--primary-dark); background: rgba(255, 255, 255, .84); border-color: rgba(15, 111, 191, .24); box-shadow: none; }
.button-secondary:hover { color: #fff; background: var(--primary); border-color: var(--primary); }
.button-quiet { min-height: 34px; padding: 6px 10px; color: var(--primary-dark); background: transparent; border-color: transparent; box-shadow: none; }
.button-quiet:hover { color: var(--primary); background: rgba(15, 111, 191, .08); }
.button-small { min-height: 32px; padding: 6px 10px; border-radius: 8px; font-size: 10px; }
.button-light { color: #181d26; background: #fff; border-color: #fff; box-shadow: none; }
.button-light:hover { color: #181d26; background: #f5e9d4; border-color: #f5e9d4; }
.button .material-symbols-outlined { font-size: 16px; }

/* Public access pages: the same split-shell composition as the actively managed reference. */
.public-shell {
    position: relative;
    color: #41454d;
    background:
        linear-gradient(135deg, rgba(247, 250, 253, .18), rgba(232, 242, 250, .10) 52%, rgba(247, 251, 253, .24)),
        url("img/menu_bg.png") center / cover fixed no-repeat;
}
.public-shell::before {
    position: fixed;
    inset: 0;
    z-index: 0;
    content: "";
    pointer-events: none;
    opacity: .18;
    background-image:
        linear-gradient(rgba(100, 116, 139, .10) 1px, transparent 1px),
        linear-gradient(90deg, rgba(100, 116, 139, .09) 1px, transparent 1px);
    background-size: 44px 44px;
    -webkit-mask-image: linear-gradient(180deg, rgba(0, 0, 0, .84), transparent 82%);
    mask-image: linear-gradient(180deg, rgba(0, 0, 0, .84), transparent 82%);
}
.public-main {
    position: relative;
    z-index: 1;
    display: grid;
    width: 100%;
    min-height: calc(100dvh - 48px);
    padding: 24px 0;
    place-items: center;
}
.public-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 392px;
    gap: 24px;
    align-items: stretch;
    width: min(1120px, 100%);
}
.public-layout-wide {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: min(1280px, calc(100% - 48px));
}
.public-brand,
.public-panel {
    color: #41454d;
    background: rgba(255, 255, 255, .93);
    border: 1px solid rgba(255, 255, 255, .78);
    border-radius: 18px;
    box-shadow: 0 18px 42px rgba(11, 15, 25, .10);
}
.public-brand {
    position: relative;
    display: grid;
    grid-template-rows: auto minmax(310px, 1fr) auto;
    gap: 20px;
    min-height: 620px;
    padding: 48px;
    overflow: hidden;
}
.public-brand::before {
    position: absolute;
    inset: 0 0 auto;
    height: 6px;
    content: "";
    background: #aa2d00;
}
.brand-organisation {
    margin: 0 0 16px;
    color: #aa2d00;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0;
}
.public-brand h1 {
    max-width: 620px;
    margin: 0 0 12px;
    color: #181d26;
    font-size: 40px;
    font-weight: 400;
    letter-spacing: 0;
    line-height: 1.15;
}
.public-intro {
    max-width: 590px;
    margin: 0;
    color: #41454d;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.65;
}
.public-hero-visual {
    position: relative;
    min-height: 320px;
    overflow: hidden;
    background: #edf0ef;
    border: 1px solid #d4d8dc;
    border-radius: 16px;
}
.public-hero-visual > img {
    position: absolute;
    top: 50%;
    left: 50%;
    display: block;
    width: min(640px, calc(100% + 60px));
    height: 360px;
    object-fit: cover;
    object-position: center 52%;
    transform: translate(-50%, -50%);
}
.public-footnote { align-self: end; margin: 0; color: #666c76; font-size: 12px; }
.public-panel {
    align-self: center;
    display: flex;
    flex-direction: column;
    padding: 36px;
    text-align: center;
}
.public-layout-wide .public-panel { min-height: 620px; justify-content: center; padding: 48px clamp(36px, 6vw, 72px); }
.public-panel-logo {
    display: block;
    width: 62px;
    height: 62px;
    margin: 0 auto 16px;
    object-fit: contain;
}
.public-panel h2 {
    max-width: 430px;
    margin: 0 auto;
    color: #20252d;
    font-size: 24px;
    font-weight: 500;
    letter-spacing: 0;
    line-height: 1.3;
}
.public-panel-subtitle { margin: 5px 0 28px; color: #666c76; font-size: 13px; }
.public-panel .stack-form { text-align: left; }
.public-panel .stack-form { gap: 18px; }
.public-panel .field-grid { gap: 15px; }
.public-panel label { margin-bottom: 7px; font-family: var(--font-mono); font-size: 10px; font-weight: 600; letter-spacing: .02em; }
.public-panel input, .public-panel select, .public-panel textarea { min-height: 44px; padding: 10px 12px; border-color: #dddddd; box-shadow: none; font-size: 13px; font-weight: 500; }
.public-panel .button-full { min-height: 42px; margin-top: 12px; background: #181d26; border-color: #181d26; box-shadow: none; font-weight: 600; }
.public-panel .button-full:hover { background: #2d343e; border-color: #2d343e; }
.public-panel .form-link { margin: 0; color: #666c76; font-size: 12px; font-weight: 500; text-align: center; }
.public-privacy {
    margin: 18px 0 0;
    padding-top: 0;
    color: #666c76;
    border-top: 0;
    font-size: 12px;
    line-height: 1.5;
    text-align: center;
}
.auth-theme-toggle {
    position: fixed;
    top: 22px;
    right: 24px;
    z-index: 20;
    color: #181d26;
    background: rgba(255, 255, 255, .90);
    border-color: #d7dbe0;
    box-shadow: 0 8px 20px rgba(11, 15, 25, .10);
}

/* Authenticated workspace shell. */
.app-shell {
    position: relative;
    isolation: isolate;
    background: var(--canvas);
}
.app-frame { position: relative; z-index: 1; }
.app-shell::before {
    position: fixed;
    inset: 0 0 0 var(--sidebar);
    z-index: 0;
    content: "";
    pointer-events: none;
    opacity: 1;
    background:
        linear-gradient(135deg, rgba(238, 246, 251, .18), rgba(248, 252, 255, .38)),
        url("img/menu_bg.png") center / cover fixed no-repeat;
}
.sidebar {
    padding: 18px 12px;
    height: 100dvh;
    overflow: hidden;
    color: #dce9f2;
    background:
        radial-gradient(circle at 18% 4%, rgba(255, 255, 255, .07), transparent 34%),
        linear-gradient(145deg, #0c4b73 0%, #0c4c52 47%, #3a2336 100%);
    border-right: 1px solid rgba(255, 255, 255, .08);
    box-shadow: none;
}
.sidebar-mobile-bar { flex: 0 0 auto; }
.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 11px;
    min-height: 70px;
    padding: 12px;
    margin-bottom: 16px;
    color: inherit;
    background: rgba(255, 255, 255, .045);
    border: 1px solid rgba(255, 255, 255, .09);
    border-radius: 16px;
    text-decoration: none;
}
.sidebar-brand:hover { color: inherit; background: rgba(255, 255, 255, .07); }
.sidebar-brand-logo {
    display: grid;
    flex: 0 0 auto;
    width: 45px;
    height: 45px;
    padding: 5px;
    background: #fff;
    border-radius: 14px;
    place-items: center;
}
.sidebar-brand-logo img { display: block; width: 100%; height: 100%; object-fit: contain; }
.sidebar-brand > span:last-child { min-width: 0; }
.sidebar-brand strong,
.sidebar-brand small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sidebar-brand strong { color: #fff; font-size: 14px; line-height: 1.15; }
.sidebar-brand small { margin-top: 4px; color: rgba(255, 255, 255, .60); font-size: 9px; font-weight: 750; letter-spacing: .09em; text-transform: uppercase; }
.mobile-nav-toggle { display: none; }
.nav-groups {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    min-height: 0;
    padding: 18px 2px 14px 0;
    gap: 3px;
    overflow-y: auto;
    scrollbar-color: rgba(92, 205, 198, .64) transparent;
    scrollbar-width: thin;
}
.nav-link {
    width: 100%;
    min-height: 42px;
    margin: 0;
    padding: 10px 12px;
    gap: 11px;
    color: rgba(235, 245, 252, .76);
    background: transparent;
    border: 0;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 700;
    transition: color .17s cubic-bezier(.2, .75, .3, 1), background .17s cubic-bezier(.2, .75, .3, 1), transform .17s cubic-bezier(.2, .75, .3, 1);
}
.nav-link .nav-icon, .nav-logout .nav-icon { font-size: 20px; }
.nav-link:hover { color: #fff; background: rgba(255, 255, 255, .095); }
.nav-link.is-active {
    color: #fff;
    background: linear-gradient(90deg, rgba(15, 111, 191, .96), rgba(20, 184, 166, .48));
    border: 0;
    box-shadow: 0 8px 18px rgba(2, 17, 29, .18);
}
.nav-link.is-active .nav-icon { stroke-width: 2.2; }
.nav-label { margin: 22px 12px 6px; color: rgba(186, 220, 239, .48); font-size: 9px; font-weight: 800; letter-spacing: .13em; }
.nav-label:first-child { margin-top: 0; }
.sidebar-footer {
    flex: 0 0 auto;
    padding: 14px 4px 0;
    margin-top: auto;
    border-top: 1px solid rgba(255, 255, 255, .09);
}
.sidebar-user {
    min-height: 0;
    gap: 10px;
    padding: 9px 8px;
    border: 0;
}
.user-avatar {
    width: 36px;
    height: 36px;
    background: linear-gradient(145deg, var(--primary), var(--teal));
    border: 1px solid rgba(255, 255, 255, .28);
}
.sidebar-user strong { max-width: 180px; font-size: 11px; }
.sidebar-user div span { color: rgba(255, 255, 255, .58); font-size: 10px; }
.nav-logout {
    display: flex;
    align-items: center;
    gap: 11px;
    width: 100%;
    min-height: 42px;
    padding: 10px 12px;
    margin-top: 4px;
    color: rgba(235, 245, 252, .68);
    background: transparent;
    border: 0;
    border-radius: 10px;
    font: inherit;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
}
.nav-logout:hover { color: #fff; background: rgba(255, 255, 255, .095); }
.app-main { margin-left: var(--sidebar); }
.topbar {
    justify-content: space-between;
    min-height: 94px;
    padding: 18px clamp(24px, 4vw, 50px);
    background: rgba(255, 255, 255, .84);
    border-bottom: 1px solid rgba(207, 220, 232, .88);
    -webkit-backdrop-filter: blur(16px) saturate(145%);
    backdrop-filter: blur(16px) saturate(145%);
}
.topbar-title .eyebrow { margin: 0 0 4px; color: var(--teal-dark); }
.topbar-title h1 { color: var(--ink); font-size: clamp(21px, 2.2vw, 28px); font-weight: 800; letter-spacing: -.035em; }
.topbar-subtitle { color: var(--muted); font-size: 11px; font-weight: 600; }
.topbar-actions { gap: 12px; }
.theme-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-height: 36px;
    padding: 7px 10px;
    color: var(--ink);
    background: rgba(255, 255, 255, .84);
    border: 1px solid var(--border);
    border-radius: 9px;
    font-size: 11px;
    font-weight: 700;
}
.theme-toggle [data-theme-icon] { font-size: 17px; }
.role-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 11px;
    color: var(--primary-dark);
    background: rgba(15, 111, 191, .09);
    border: 1px solid rgba(15, 111, 191, .12);
    border-radius: 999px;
    font-size: 11px;
    font-weight: 800;
    white-space: nowrap;
}
.role-pill svg { width: 16px; height: 16px; }
.content { width: min(100% - clamp(32px, 5vw, 72px), 1240px); margin: 0 auto; padding: clamp(26px, 4vw, 42px) 0 52px; }

.page-intro { align-items: flex-start; margin-bottom: 24px; }
.page-intro h2 { color: var(--ink); font-size: 21px; font-weight: 800; letter-spacing: -.025em; }
.page-intro p:not(.eyebrow) { font-size: 13px; font-weight: 600; line-height: 1.65; }
.eyebrow { color: var(--teal-dark); font-size: 10px; font-weight: 800; }
.panel, .kpi-card, .detail-strip {
    background: rgba(255, 255, 255, .86);
    border-color: rgba(207, 220, 232, .88);
    box-shadow: var(--shadow-soft);
}
.panel { padding: clamp(20px, 3vw, 28px); border-radius: 22px; }
.panel-heading h2 { font-size: 16px; font-weight: 800; }
.panel-heading > div > p:not(.eyebrow) { margin: 5px 0 0; color: var(--muted); font-size: 11px; font-weight: 550; }
.field label, fieldset legend { color: var(--ink); font-size: 11px; font-weight: 800; }
input, select, textarea {
    min-height: 42px;
    color: var(--text);
    background: rgba(255, 255, 255, .92);
    border-color: var(--border-strong);
    border-radius: 10px;
}
input:focus, select:focus, textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 4px var(--focus); }
.form-actions {
    background: rgba(255, 255, 255, .94);
    border-color: var(--border);
    box-shadow: var(--shadow);
}
.filter-panel, .criteria-toolbar {
    background: rgba(245, 233, 212, .82);
    border-color: #ead6b9;
}
th { color: var(--ink); background: var(--surface-warm); }
tr:hover > td { background: rgba(242, 247, 251, .68); }
.table-action { color: var(--primary-dark); background: rgba(255, 255, 255, .72); border-color: rgba(15, 111, 191, .24); }
.table-action:hover { color: #fff; background: var(--primary); border-color: var(--primary); }

/* Role-aware command centre. */
.dashboard-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(250px, .42fr);
    gap: 24px;
    align-items: stretch;
    padding: clamp(27px, 3.5vw, 40px);
    margin-bottom: 20px;
    background: linear-gradient(125deg, rgba(255, 255, 255, .96), rgba(244, 249, 250, .94));
    border: 1px solid rgba(24, 29, 38, .10);
    border-radius: 22px;
    box-shadow: 0 16px 38px rgba(11, 15, 25, .07);
}
.dashboard-hero-copy { align-self: center; }
.dashboard-hero h2 { max-width: 690px; margin: 0; color: var(--ink); font-size: clamp(25px, 2.9vw, 34px); font-weight: 650; letter-spacing: -.035em; line-height: 1.18; }
.dashboard-hero p:not(.eyebrow) { max-width: 660px; margin: 11px 0 0; color: var(--muted); font-size: 13px; line-height: 1.65; }
.dashboard-scope {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 104px;
    padding: 17px;
    color: var(--text);
    background: rgba(245, 233, 212, .66);
    border: 1px solid #ead6b9;
    border-radius: 14px;
}
.dashboard-scope > svg { width: 23px; height: 23px; color: var(--accent); }
.dashboard-scope strong, .dashboard-scope small { display: block; }
.dashboard-scope strong { color: var(--ink); font-size: 11px; }
.dashboard-scope small { margin-top: 3px; color: var(--muted); font-size: 10px; line-height: 1.45; }
.dashboard-summary {
    display: grid;
    grid-template-columns: minmax(0, 1.52fr) minmax(340px, .9fr);
    gap: 18px;
    margin-bottom: 12px;
}
.dashboard-priority-card {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 17px;
    align-items: center;
    min-height: 164px;
    padding: 24px 25px;
    color: rgba(255, 255, 255, .82);
    background: linear-gradient(135deg, #202631, #303a46);
    border: 1px solid #202631;
    border-radius: 18px;
    box-shadow: 0 16px 32px rgba(11, 15, 25, .16);
}
.dashboard-priority-card.is-attention { background: linear-gradient(135deg, #2b2b2a, #4a392d); border-color: #594333; }
.dashboard-priority-card.is-review { background: linear-gradient(135deg, #202631, #3d3341); border-color: #493c4d; }
.dashboard-priority-card.is-progress { background: linear-gradient(135deg, #18303f, #184a53); border-color: #225966; }
.dashboard-priority-icon {
    display: grid;
    width: 42px;
    height: 42px;
    color: #fff;
    background: rgba(255, 255, 255, .13);
    border: 1px solid rgba(255, 255, 255, .18);
    border-radius: 12px;
    place-items: center;
}
.dashboard-priority-icon svg { width: 22px; height: 22px; }
.dashboard-priority-label { margin: 0 0 5px; color: rgba(255, 255, 255, .66); font-size: 9px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.dashboard-priority-copy h3 { margin: 0; color: #fff; font-size: clamp(18px, 1.8vw, 23px); font-weight: 650; letter-spacing: -.025em; line-height: 1.22; }
.dashboard-priority-copy > p:last-child { max-width: 520px; margin: 7px 0 0; color: rgba(255, 255, 255, .75); font-size: 11px; line-height: 1.55; }
.dashboard-priority-action { display: grid; gap: 10px; justify-items: end; min-width: 126px; text-align: right; }
.dashboard-priority-action > div { display: grid; gap: 1px; }
.dashboard-priority-action strong { color: #fff; font-size: 31px; font-weight: 700; letter-spacing: -.045em; line-height: 1; }
.dashboard-priority-action > div > span { color: rgba(255, 255, 255, .67); font-size: 9px; font-weight: 700; }
.dashboard-kpis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.dashboard-kpi {
    display: flex;
    min-width: 0;
    min-height: 78px;
    flex-direction: column;
    justify-content: center;
    padding: 14px;
    background: rgba(255, 255, 255, .86);
    border: 1px solid rgba(207, 220, 232, .78);
    border-radius: 13px;
    box-shadow: 0 8px 20px rgba(11, 15, 25, .045);
}
.dashboard-kpis .dashboard-kpi:last-child { grid-column: 1 / -1; }
.dashboard-kpi > span { color: var(--muted); font-size: 8px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.dashboard-kpi strong { margin-top: 2px; color: var(--ink); font-size: 22px; font-weight: 650; letter-spacing: -.03em; line-height: 1.15; }
.dashboard-kpi strong.text-value { font-size: 15px; letter-spacing: -.01em; }
.dashboard-kpi small { margin-top: 3px; color: var(--muted); font-size: 9px; line-height: 1.4; }
.dashboard-kpi.is-warning { border-top: 3px solid var(--warning); }
.dashboard-kpi.is-danger { border-top: 3px solid var(--danger); }
.dashboard-kpi.is-muted { border-top: 3px solid var(--border-strong); }
.dashboard-secondary-kpis {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 30px;
}
.dashboard-secondary-kpis .dashboard-kpi { min-height: 92px; }
.dashboard-workspace { gap: 20px; }
.dashboard-workspace .panel { min-width: 0; }
.record-row { min-height: 61px; padding: 13px 4px; }
.record-row strong { font-size: 12px; }
.record-row small { font-size: 10px; }

html[data-theme="dark"] { scrollbar-color: rgba(255, 154, 115, .64) rgba(255, 255, 255, .06); }
html[data-theme="dark"] .public-shell {
    color: #d8e0e7;
    background:
        linear-gradient(135deg, rgba(16, 23, 32, .76), rgba(16, 23, 32, .82)),
        url("img/menu_bg.png") center / cover fixed no-repeat;
}
html[data-theme="dark"] .public-shell::before { opacity: .16; }
html[data-theme="dark"] .public-brand,
html[data-theme="dark"] .public-panel { color: #d0d8df; background: rgba(22, 34, 46, .96); border-color: #385066; box-shadow: 0 18px 42px rgba(0, 0, 0, .24); }
html[data-theme="dark"] .public-brand::before { background: linear-gradient(90deg, #f2d188, #ffad89, #8cc8df); }
html[data-theme="dark"] .public-brand h1,
html[data-theme="dark"] .public-panel h2 { color: #edf4f8; }
html[data-theme="dark"] .brand-organisation { color: #ffad89; }
html[data-theme="dark"] .public-intro,
html[data-theme="dark"] .public-footnote,
html[data-theme="dark"] .public-panel-subtitle,
html[data-theme="dark"] .public-privacy,
html[data-theme="dark"] .public-panel .form-link { color: #aebbc6; }
html[data-theme="dark"] .public-hero-visual { background: #14202a; border-color: #385066; }
html[data-theme="dark"] .public-hero-visual > img { opacity: .70; filter: saturate(.62) brightness(.56) contrast(1.15); }
html[data-theme="dark"] .public-panel .button-full { color: #21140f; background: #ffd3c0; border-color: #ffd3c0; }
html[data-theme="dark"] .public-panel .button-full:hover { background: #ffe0d2; border-color: #ffe0d2; }
html[data-theme="dark"] .public-privacy { border-color: #354858; }
html[data-theme="dark"] .auth-theme-toggle,
html[data-theme="dark"] .theme-toggle { color: #edf4f8; background: #253544; border-color: #577087; }
html[data-theme="dark"] .app-shell::before {
    background: linear-gradient(135deg, rgba(16, 23, 32, .74), rgba(19, 29, 39, .82)), url("img/menu_bg.png") center / cover fixed no-repeat;
}
html[data-theme="dark"] .topbar { background: rgba(19, 30, 40, .90); border-color: #344655; }
html[data-theme="dark"] .role-pill { color: #b9dcff; background: #20374a; border-color: #38566d; }
html[data-theme="dark"] .panel,
html[data-theme="dark"] .kpi-card,
html[data-theme="dark"] .detail-strip,
html[data-theme="dark"] .dashboard-kpi { background: #18232e; border-color: #344655; box-shadow: none; }
html[data-theme="dark"] .dashboard-hero { background: linear-gradient(125deg, #1b2632, #1d2e38); border-color: #334a57; }
html[data-theme="dark"] .dashboard-scope { background: #202c38; border-color: #39495a; }
html[data-theme="dark"] .dashboard-scope > svg { color: #ffad89; }
html[data-theme="dark"] .filter-panel,
html[data-theme="dark"] .criteria-toolbar,
html[data-theme="dark"] th { background: #272c31; border-color: #4d4d46; }
html[data-theme="dark"] input,
html[data-theme="dark"] select,
html[data-theme="dark"] textarea { background: #131e28; border-color: #526878; }
html[data-theme="dark"] tr:hover > td { background: rgba(37, 51, 63, .68); }
html[data-theme="dark"] .button-secondary { color: #c8e4f7; background: #1c2a35; border-color: #456075; }
html[data-theme="dark"] .button-secondary:hover { color: #0b1d2a; background: #8cc8ef; border-color: #8cc8ef; }

.nav-backdrop[hidden] { display: none !important; }
.menu-icon-close { display: none; }

@media (max-width: 1240px) {
    .dashboard-summary { grid-template-columns: 1fr; }
    .dashboard-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .dashboard-kpis .dashboard-kpi:last-child { grid-column: auto; }
    .dashboard-secondary-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 1080px) {
    .public-layout-wide { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 980px) {
    .sidebar {
        position: relative;
        inset: auto;
        z-index: 30;
        width: 100%;
        height: auto;
        padding: 10px 14px;
        transform: none;
        overflow: visible;
    }
    .sidebar-mobile-bar { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
    .sidebar-brand { flex: 1 1 auto; min-width: 0; min-height: 58px; padding: 7px 9px; margin: 0; }
    .sidebar-brand-logo { width: 42px; height: 42px; border-radius: 12px; }
    .mobile-nav-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 7px;
        min-height: 42px;
        padding: 8px 11px;
        color: #fff;
        background: rgba(255, 255, 255, .09);
        border: 1px solid rgba(255, 255, 255, .15);
        border-radius: 10px;
        font: inherit;
        font-size: 11px;
        font-weight: 700;
    }
    .mobile-nav-toggle[aria-expanded="true"] .menu-icon-open { display: none; }
    .mobile-nav-toggle[aria-expanded="true"] .menu-icon-close { display: inline-flex; }
    .nav-groups {
        display: none;
        padding: 15px 2px 10px;
        overflow: visible;
    }
    .sidebar.is-open .nav-groups { display: flex; }
    .sidebar-footer { display: none; }
    .sidebar.is-open .sidebar-footer { display: block; }
    .app-main { margin-left: 0; }
    .app-shell::before { inset: 0; }
    .nav-backdrop { display: none !important; }
    body.nav-open { overflow: auto; }
    .public-layout { grid-template-columns: minmax(0, 1fr) minmax(370px, 420px); }
    .public-layout-wide { grid-template-columns: 1fr; max-width: 650px; }
    .public-layout-wide .public-brand { display: none; }
    .public-layout-wide .public-panel { width: 100%; }
}

@media (max-width: 760px) {
    .theme-toggle { overflow: visible; color: var(--ink); }
    .theme-toggle::after { display: none; content: none; }
    .public-main { padding: 72px 12px 28px; }
    .public-layout { display: block; width: min(100%, 520px); }
    .public-brand { display: none; }
    .public-panel { width: 100%; padding: 31px 22px 26px; border-radius: 16px; }
    .public-panel-logo { width: 72px; height: 72px; margin-bottom: 18px; }
    .public-panel h2 { font-size: 23px; }
    .public-panel-subtitle { margin-bottom: 26px; }
    .auth-theme-toggle { top: 15px; right: 14px; width: 42px; padding: 8px; }
    .auth-theme-toggle [data-theme-label] { display: none; }
    .topbar { min-height: 76px; padding: 15px 18px; }
    .topbar-title h1 { font-size: 22px; }
    .topbar-title .eyebrow { display: none; }
    .topbar-subtitle { display: none; }
    .topbar-actions .theme-toggle [data-theme-label] { display: none; }
    .topbar-actions .theme-toggle { width: 36px; padding: 7px; }
    .role-pill > span:not(.material-symbols-outlined) { display: none; }
    .role-pill { width: 36px; height: 36px; justify-content: center; padding: 0; }
    .content { width: min(100% - 28px, 1240px); padding-top: 25px; padding-bottom: 42px; }
    .dashboard-hero { grid-template-columns: 1fr; gap: 16px; padding: 24px 20px; }
    .dashboard-scope { min-height: 0; }
    .dashboard-priority-card { grid-template-columns: auto minmax(0, 1fr); padding: 20px; }
    .dashboard-priority-action {
        grid-column: 1 / -1;
        grid-template-columns: 1fr auto;
        align-items: center;
        justify-items: stretch;
        width: 100%;
        padding-top: 12px;
        border-top: 1px solid rgba(255, 255, 255, .16);
        text-align: left;
    }
    .dashboard-priority-action > div { display: flex; gap: 7px; align-items: baseline; }
    .dashboard-priority-action .button { justify-self: end; }
    .dashboard-kpis,
    .dashboard-secondary-kpis { grid-template-columns: 1fr; }
    .dashboard-kpis .dashboard-kpi:last-child { grid-column: auto; }
    .dashboard-secondary-kpis { margin-bottom: 24px; }
    .dashboard-kpi { min-height: 88px; }
    .page-intro { display: block; }
    .page-intro .page-actions,
    .page-intro > .button { margin-top: 15px; }
    .panel-heading { align-items: flex-start; }
}

@media (max-width: 480px) {
    .sidebar { padding: 9px 10px; }
    .sidebar-brand strong { font-size: 13px; }
    .sidebar-brand small { font-size: 8px; }
    .mobile-nav-toggle { min-width: 42px; padding: 8px; }
    .mobile-nav-toggle [data-nav-label] { display: none; }
    .topbar { min-height: 70px; padding: 14px; }
    .topbar-title h1 { font-size: 20px; }
    .content { width: min(100% - 22px, 1240px); padding-top: 20px; padding-bottom: 34px; }
    .panel { padding: 19px 16px; border-radius: 17px; }
    .public-panel { padding-right: 18px; padding-left: 18px; }
    .public-layout-wide .field-grid { grid-template-columns: 1fr; }
    input, select, textarea { min-height: 46px; font-size: 16px; }
    .dashboard-priority-card { grid-template-columns: 1fr; }
    .dashboard-priority-action { grid-column: auto; grid-template-columns: 1fr; }
    .dashboard-priority-action .button { width: 100%; justify-self: stretch; }
}

@media (prefers-reduced-transparency: reduce) {
    .public-brand,
    .public-panel,
    .topbar,
    .panel,
    .dashboard-kpi { background: var(--surface); }
}

/* Reference-aligned module launcher. */
.main-menu-intro {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: clamp(24px, 4vw, 36px);
    margin-bottom: 24px;
    overflow: hidden;
    background: linear-gradient(120deg, rgba(255, 255, 255, .92), rgba(238, 248, 252, .86));
    border: 1px solid rgba(var(--primary-rgb), .14);
    border-radius: 22px;
    box-shadow: var(--shadow);
}
.main-menu-intro .eyebrow { color: var(--primary-dark); }
.main-menu-intro h2 { max-width: 650px; margin: 0; color: var(--ink); font-size: clamp(24px, 3vw, 34px); font-weight: 800; letter-spacing: -.04em; line-height: 1.15; }
.main-menu-intro p:not(.eyebrow) { max-width: 680px; margin: 10px 0 0; color: var(--muted); font-size: 13px; font-weight: 600; line-height: 1.65; }
.main-menu-scope { display: flex; flex: 0 0 auto; gap: 10px; align-items: center; max-width: 250px; padding: 13px 15px; color: var(--primary-dark); background: rgba(var(--primary-rgb), .08); border: 1px solid rgba(var(--primary-rgb), .14); border-radius: 14px; font-size: 11px; font-weight: 700; line-height: 1.45; }
.main-menu-scope > .material-symbols-outlined { color: var(--teal-dark); font-size: 21px; }
.main-menu-scope strong { display: block; margin-bottom: 2px; color: var(--ink); font-size: 10px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
/* Five desktop launchers retain the reference card width. Lower-width layouts
   reduce the column count before cards would become too narrow. */
.main-menu-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 18px; max-width: 1240px; }
.main-menu-card { display: flex; flex-direction: column; min-width: 0; overflow: hidden; color: inherit; background: rgba(255, 255, 255, .88); border: 1px solid rgba(207, 220, 232, .92); border-radius: 16px; box-shadow: var(--shadow-soft); text-decoration: none; transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease; }
.main-menu-card:hover { color: inherit; border-color: rgba(var(--primary-rgb), .35); box-shadow: 0 18px 32px rgba(15, 57, 87, .16); text-decoration: none; transform: translateY(-4px); }
.main-menu-card:focus-visible { outline: 3px solid rgba(var(--primary-rgb), .35); outline-offset: 3px; }
.main-menu-card-image { display: block; aspect-ratio: 1 / 1; padding: 13px; background: linear-gradient(135deg, rgba(248, 252, 254, .94), rgba(231, 241, 247, .72)); }
.main-menu-card-image img { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: 11px; }
.main-menu-card-body { display: flex; gap: 12px; align-items: center; justify-content: space-between; min-height: 102px; padding: 17px 18px 18px; }
.main-menu-card-body > span:first-child { min-width: 0; }
.main-menu-card-body strong, .main-menu-card-body small { display: block; }
.main-menu-card-body strong { color: #1e4b85; font-size: 15px; font-weight: 800; letter-spacing: -.015em; line-height: 1.3; }
.main-menu-card-body small { margin-top: 6px; color: var(--text); font-size: 11px; font-weight: 600; line-height: 1.45; }
.main-menu-card-arrow { display: grid; flex: 0 0 auto; width: 31px; height: 31px; color: var(--primary); background: rgba(var(--primary-rgb), .08); border-radius: 50%; font-size: 18px; place-items: center; transition: background .18s ease, color .18s ease, transform .18s ease; }
.main-menu-card:hover .main-menu-card-arrow { color: #fff; background: var(--primary); transform: translateX(2px); }
.main-menu-empty { display: flex; gap: 16px; align-items: center; }
.main-menu-empty > .material-symbols-outlined { flex: 0 0 auto; color: var(--primary); font-size: 30px; }
.main-menu-empty > div { flex: 1 1 auto; }
.main-menu-empty h3 { margin: 0 0 4px; }
.main-menu-empty p { margin: 0; color: var(--muted); font-size: 12px; font-weight: 600; line-height: 1.55; }

/* Compact workflow tabs used by the reference list and review pages. */
.request-tabs { display: flex; flex-wrap: wrap; gap: 8px; padding-bottom: 20px; margin-bottom: 18px; border-bottom: 1px solid rgba(207, 220, 232, .78); -webkit-overflow-scrolling: touch; }
.request-tab { display: inline-flex; align-items: center; gap: 8px; min-height: 35px; padding: 7px 11px; color: #555b64; background: #fff; border: 1px solid var(--border); border-radius: 8px; font-size: 11px; font-weight: 600; text-decoration: none; white-space: nowrap; }
.request-tab:hover { color: var(--ink); background: var(--surface-warm); text-decoration: none; }
.request-tab.active { color: #fff; background: var(--ink); border-color: var(--ink); box-shadow: none; }
.request-tab strong { display: inline-grid; min-width: 19px; height: 19px; padding: 0 5px; place-items: center; color: inherit; background: rgba(255, 255, 255, .35); border-radius: 999px; font-size: 9px; }
.request-tab:not(.active) strong { color: var(--accent); background: #fff0e8; }
.criteria-tab-complete { display: inline-grid; flex: 0 0 auto; width: 20px; height: 20px; place-items: center; color: #fff; background: var(--success); border-radius: 50%; }
.criteria-tab-complete[hidden] { display: none; }
.criteria-tab-complete .ui-icon { font-size: 14px; }
.criteria-tab.is-complete { color: #0a2e0e; background: var(--success-soft); border-color: #b8d6bd; }
.criteria-tab.is-complete:hover { color: #0a2e0e; background: #d9efdd; border-color: #92c29c; }
.criteria-tab.is-complete.active { color: #fff; background: var(--success); border-color: var(--success); }
.criteria-tab.is-complete.active .criteria-tab-complete { color: var(--success); background: #fff; }

/* Command centre: the reference hierarchy, adapted to MOI workflow data. */
.command-centre-hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(250px, .42fr); gap: 24px; align-items: stretch; padding: clamp(27px, 3.5vw, 40px); margin-bottom: 20px; background: linear-gradient(125deg, rgba(255, 255, 255, .96), rgba(244, 249, 250, .94)); border: 1px solid rgba(24, 29, 38, .10); border-radius: 22px; box-shadow: 0 16px 38px rgba(11, 15, 25, .07); }
.command-centre-hero-copy { align-self: center; }
.command-centre-hero .eyebrow { margin-bottom: 7px; color: var(--primary-dark); }
.command-centre-hero h2 { max-width: 690px; margin: 0; color: var(--ink); font-size: clamp(25px, 2.9vw, 34px); font-weight: 650; letter-spacing: -.035em; line-height: 1.15; }
.command-centre-hero p:not(.eyebrow) { max-width: 660px; margin: 11px 0 0; color: var(--muted); font-size: 13px; font-weight: 500; line-height: 1.65; }
.command-centre-scope { display: flex; flex: 0 0 auto; gap: 10px; align-items: center; max-width: 270px; padding: 14px 16px; color: var(--primary-dark); background: rgba(var(--primary-rgb), .075); border: 1px solid rgba(var(--primary-rgb), .14); border-radius: 14px; font-size: 11px; font-weight: 700; line-height: 1.45; }
.command-centre-scope-hero { align-self: stretch; min-height: 104px; max-width: none; padding: 17px; color: var(--text); background: rgba(245, 233, 212, .62); border-color: #ead6b9; }
.command-centre-scope > .material-symbols-outlined { color: var(--accent); font-size: 21px; }
.command-centre-scope strong { display: block; margin-bottom: 3px; color: var(--ink); font-size: 10px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.command-centre-summary { display: grid; grid-template-columns: minmax(0, 1.52fr) minmax(340px, .9fr); gap: 18px; margin-bottom: 30px; }
.command-centre-priority-card { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 17px; align-items: center; min-height: 164px; padding: 24px 25px; color: rgba(255, 255, 255, .82); background: linear-gradient(135deg, #202631, #303a46); border: 1px solid #202631; border-radius: 18px; box-shadow: 0 16px 32px rgba(11, 15, 25, .16); }
.command-centre-priority-card.is-attention { background: linear-gradient(135deg, #2b2b2a, #4a392d); border-color: #594333; }
.command-centre-priority-card.is-review { background: linear-gradient(135deg, #202631, #3d3341); border-color: #493c4d; }
.command-centre-priority-card.is-progress { background: linear-gradient(135deg, #18303f, #184a53); border-color: #225966; }
.command-centre-priority-icon { display: grid; width: 42px; height: 42px; place-items: center; color: #fff; background: rgba(255, 255, 255, .13); border: 1px solid rgba(255, 255, 255, .18); border-radius: 12px; font-size: 22px; }
.command-centre-priority-copy { min-width: 0; }
.command-centre-label { margin: 0 0 5px; color: rgba(255, 255, 255, .66); font-size: 9px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.command-centre-priority-copy h3 { margin: 0; color: #fff; font-size: clamp(18px, 1.8vw, 23px); font-weight: 650; letter-spacing: -.025em; line-height: 1.22; }
.command-centre-priority-copy > p:not(.command-centre-label) { max-width: 520px; margin: 7px 0 0; color: rgba(255, 255, 255, .75); font-size: 11px; font-weight: 500; line-height: 1.55; }
.command-centre-priority-action { display: grid; gap: 10px; justify-items: end; min-width: 116px; text-align: right; }
.command-centre-priority-action > div { display: grid; gap: 1px; }
.command-centre-priority-action strong { color: #fff; font-size: 31px; font-weight: 700; letter-spacing: -.045em; line-height: 1; }
.command-centre-priority-action > div > span { color: rgba(255, 255, 255, .67); font-size: 9px; font-weight: 700; line-height: 1.35; }
.command-centre-priority-action .button { min-height: 34px; padding: 7px 10px; color: #181d26; background: #fff; border-color: #fff; box-shadow: none; white-space: nowrap; }
.command-centre-priority-action .button:hover { color: #181d26; background: #f5e9d4; border-color: #f5e9d4; }
.command-centre-priority-action .material-symbols-outlined { font-size: 16px; }
.command-centre-kpis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 0; }
.command-centre-kpi { display: flex; gap: 10px; min-width: 0; min-height: 78px; padding: 14px; background: rgba(255, 255, 255, .82); border: 1px solid rgba(207, 220, 232, .78); border-radius: 13px; box-shadow: 0 8px 20px rgba(11, 15, 25, .045); }
.command-centre-kpi:last-child { grid-column: 1 / -1; }
.command-centre-kpi > .material-symbols-outlined { display: grid; flex: 0 0 auto; width: 30px; height: 30px; place-items: center; color: #181d26; background: #f5e9d4; border-radius: 9px; font-size: 17px; }
.command-centre-kpi div { min-width: 0; }
.command-centre-kpi small { display: block; color: var(--muted); font-size: 8px; font-weight: 800; letter-spacing: .07em; line-height: 1.3; text-transform: uppercase; }
.command-centre-kpi strong { display: block; margin-top: 2px; color: var(--ink); font-size: 20px; font-weight: 650; letter-spacing: -.03em; line-height: 1.15; }
.command-centre-kpi p { margin: 3px 0 0; color: var(--muted); font-size: 9px; font-weight: 500; line-height: 1.45; }
.command-centre-layout { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(280px, .8fr); gap: 20px; align-items: start; min-width: 0; }
.command-centre-primary, .command-centre-side { display: grid; gap: 20px; min-width: 0; }
.command-centre-primary > .panel, .command-centre-side > .panel { margin-bottom: 0; }
.command-centre-heading { display: flex; gap: 15px; align-items: flex-start; justify-content: space-between; margin-bottom: 18px; }
.command-centre-heading h3 { margin: 0; color: var(--ink); font-size: 18px; font-weight: 650; letter-spacing: -.02em; }
.command-centre-heading .eyebrow { color: var(--primary-dark); }
.command-centre-heading p:not(.eyebrow) { max-width: 620px; margin: 5px 0 0; color: var(--muted); font-size: 11px; font-weight: 500; line-height: 1.5; }
.command-centre-worklist { min-width: 0; padding-bottom: 23px; }
.command-centre-due-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(148px, 1fr)); gap: 10px; }
.command-centre-due-item { position: relative; display: block; min-width: 0; min-height: 118px; padding: 14px; color: inherit; background: rgba(var(--primary-rgb), .045); border: 1px solid rgba(var(--primary-rgb), .11); border-radius: 11px; text-decoration: none; transition: background .16s ease, border-color .16s ease, transform .16s ease; }
.command-centre-due-item:hover { color: inherit; background: rgba(var(--primary-rgb), .085); border-color: rgba(var(--primary-rgb), .26); text-decoration: none; transform: translateY(-1px); }
.command-centre-due-item.is-due { background: #fff9ec; border-color: #efd69b; }
.command-centre-due-item > span:first-child { display: block; color: #80520b; font-size: 10px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.command-centre-due-item strong { display: block; margin-top: 5px; color: var(--ink); font-size: 23px; font-weight: 800; line-height: 1; }
.command-centre-due-item small { display: block; margin-top: 5px; color: var(--muted); font-size: 10px; font-weight: 650; }
.command-centre-due-item > .material-symbols-outlined { position: absolute; right: 10px; bottom: 10px; color: var(--primary); font-size: 17px; }
.command-centre-zero-state { display: flex; gap: 13px; align-items: center; padding: 17px; color: var(--text); background: #f4faf5; border: 1px solid #c8e0cb; border-radius: 12px; }
.command-centre-zero-state > .material-symbols-outlined { display: grid; flex: 0 0 auto; width: 34px; height: 34px; place-items: center; color: var(--success); background: #e7f6e9; border-radius: 50%; font-size: 20px; }
.command-centre-zero-state > div { min-width: 0; flex: 1 1 auto; }
.command-centre-zero-state strong { display: block; color: var(--success); font-size: 11px; font-weight: 700; }
.command-centre-zero-state p { margin: 3px 0 0; color: var(--muted); font-size: 10px; font-weight: 500; line-height: 1.45; }
.command-centre-zero-state .button { flex: 0 0 auto; white-space: nowrap; }
.command-centre-module-card { min-width: 0; padding-bottom: 18px; }
.command-centre-module-card .table-wrap { width: 100%; min-width: 0; max-width: 100%; }
.command-centre-table { min-width: 650px; border-collapse: separate; border-spacing: 0; }
.command-centre-table th, .command-centre-table td { padding-top: 12px; padding-bottom: 12px; text-align: center; }
.command-centre-table td:first-child { text-align: left; }
.command-centre-table td strong, .command-centre-table td small { display: block; }
.command-centre-table td strong { color: var(--ink); font-size: 11px; }
.command-centre-table td small { margin-top: 2px; color: var(--muted); font-size: 9px; font-weight: 650; line-height: 1.35; }
.command-centre-table td:last-child .button { min-width: 66px; white-space: nowrap; }
.command-centre-side-card { padding: 21px; }
.command-centre-side-card .command-centre-heading { margin-bottom: 18px; }
.command-centre-indicator-list, .command-centre-queue-list { display: grid; gap: 8px; }
.command-centre-indicator-list a, .command-centre-queue-list a { display: flex; gap: 10px; align-items: center; min-height: 50px; padding: 10px; color: inherit; background: rgba(241, 248, 251, .68); border: 1px solid rgba(207, 220, 232, .78); border-radius: 10px; text-decoration: none; transition: background .16s ease, border-color .16s ease; }
.command-centre-indicator-list a:hover, .command-centre-queue-list a:hover { color: inherit; background: rgba(var(--primary-rgb), .075); border-color: rgba(var(--primary-rgb), .24); text-decoration: none; }
.command-centre-indicator-list a > span:first-child { flex: 1 1 auto; min-width: 0; color: var(--muted); font-size: 10px; font-weight: 650; line-height: 1.35; }
.command-centre-indicator-list strong { display: block; color: var(--ink); font-size: 10px; font-weight: 800; }
.command-centre-indicator-list b, .command-centre-queue-list b { display: inline-grid; flex: 0 0 auto; min-height: 24px; padding: 4px 7px; place-items: center; color: #80520b; background: #fff1d3; border-radius: 999px; font-size: 9px; font-weight: 800; line-height: 1.2; text-align: center; }
.command-centre-queue-list > a > .material-symbols-outlined:first-child { color: var(--primary); font-size: 19px; }
.command-centre-queue-list > a > span:nth-child(2) { flex: 1 1 auto; min-width: 0; color: var(--ink); font-size: 11px; font-weight: 750; }
.command-centre-queue-list > a > span:nth-child(2) small { display: block; margin-top: 2px; color: var(--muted); font-size: 9px; font-weight: 600; line-height: 1.35; }
.command-centre-queue-list > a > .material-symbols-outlined:last-child { color: var(--muted); font-size: 18px; }
.command-centre-empty { margin: 0; padding: 14px; color: var(--muted); background: var(--surface-low); border: 1px dashed var(--border); border-radius: 10px; font-size: 11px; font-weight: 600; line-height: 1.55; }
.command-centre-steps { display: grid; gap: 12px; padding: 0; margin: 0; list-style: none; }
.command-centre-steps li { display: flex; gap: 10px; align-items: flex-start; }
.command-centre-steps li > span { display: grid; flex: 0 0 auto; width: 22px; height: 22px; place-items: center; color: #181d26; background: #f5e9d4; border-radius: 50%; font-size: 10px; font-weight: 800; }
.command-centre-steps p { margin: 1px 0 0; color: var(--text); font-size: 11px; font-weight: 600; line-height: 1.52; }
.command-centre-full-button { width: 100%; margin-top: 17px; }

html[data-theme="dark"] .nav-link.is-active { color: #fff; background: rgba(170, 45, 0, .20); box-shadow: inset 4px 0 0 #ff9a73; }
html[data-theme="dark"] .main-menu-intro { background: linear-gradient(120deg, rgba(27, 39, 52, .96), rgba(23, 48, 60, .92)); border-color: rgba(143, 175, 193, .22); }
html[data-theme="dark"] .main-menu-intro h2, html[data-theme="dark"] .main-menu-scope strong { color: var(--ink); }
html[data-theme="dark"] .main-menu-intro .eyebrow, html[data-theme="dark"] .main-menu-scope { color: #b9dcff; }
html[data-theme="dark"] .main-menu-scope { background: rgba(55, 119, 156, .20); border-color: rgba(143, 175, 193, .28); }
html[data-theme="dark"] .main-menu-card { background: #18222d; border-color: #334354; }
html[data-theme="dark"] .main-menu-card:hover { border-color: rgba(157, 202, 255, .54); box-shadow: 0 18px 34px rgba(0, 0, 0, .28); }
html[data-theme="dark"] .main-menu-card-image { background: #202c38; }
html[data-theme="dark"] .main-menu-card-image img { opacity: .78; filter: saturate(.75) brightness(.72) contrast(1.08); }
html[data-theme="dark"] .main-menu-card-body strong { color: #b9dcff; }
html[data-theme="dark"] .main-menu-card-body small { color: var(--muted); }
html[data-theme="dark"] .main-menu-card-arrow { color: #b9dcff; background: rgba(157, 202, 255, .13); }
html[data-theme="dark"] .main-menu-card:hover .main-menu-card-arrow { color: #18222d; background: #b9dcff; }
html[data-theme="dark"] .request-tabs { border-color: var(--border); }
html[data-theme="dark"] .request-tab { color: #c0cad5; background: #202c38; border-color: #39495a; }
html[data-theme="dark"] .request-tab:hover { color: #fff; background: #2b3948; }
html[data-theme="dark"] .request-tab.active { color: #21140f; background: #ffd6c3; border-color: #ffd6c3; }
html[data-theme="dark"] .request-tab:not(.active) strong { color: #ffd0bb; background: rgba(170, 45, 0, .22); }
html[data-theme="dark"] .command-centre-hero { background: linear-gradient(125deg, #1b2632, #1d2e38); border-color: #334a57; }
html[data-theme="dark"] .command-centre-scope-hero { color: #d5dee6; background: #202c38; border-color: #39495a; }
html[data-theme="dark"] .command-centre-scope-hero > .material-symbols-outlined { color: #ffad89; }
html[data-theme="dark"] .command-centre-priority-card { background: linear-gradient(135deg, #101821, #1d2a36); border-color: #304452; }
html[data-theme="dark"] .command-centre-priority-card.is-attention { background: linear-gradient(135deg, #2e2922, #4c3a29); border-color: #654d32; }
html[data-theme="dark"] .command-centre-priority-card.is-review { background: linear-gradient(135deg, #181d28, #30283a); border-color: #493b50; }
html[data-theme="dark"] .command-centre-priority-card.is-progress { background: linear-gradient(135deg, #132631, #17434b); border-color: #295864; }
html[data-theme="dark"] .command-centre-kpi { background: #202c38; border-color: #39495a; box-shadow: none; }
html[data-theme="dark"] .command-centre-kpi > .material-symbols-outlined { color: #e8eef4; background: #2f4050; }
html[data-theme="dark"] .command-centre-zero-state { background: #193326; border-color: #2f6547; }
html[data-theme="dark"] .command-centre-zero-state p { color: #c8d1dc; }
html[data-theme="dark"] .command-centre-due-item, html[data-theme="dark"] .command-centre-indicator-list a, html[data-theme="dark"] .command-centre-queue-list a, html[data-theme="dark"] .command-centre-empty { background: #202c38; border-color: #39495a; }
html[data-theme="dark"] .command-centre-due-item.is-due { background: rgba(112, 79, 23, .35); border-color: rgba(242, 209, 136, .42); }
html[data-theme="dark"] .command-centre-due-item.is-due > span:first-child, html[data-theme="dark"] .command-centre-indicator-list b, html[data-theme="dark"] .command-centre-queue-list b { color: #f2d188; }
html[data-theme="dark"] .command-centre-indicator-list b, html[data-theme="dark"] .command-centre-queue-list b { background: rgba(128, 93, 22, .25); }

@media (max-width: 1240px) {
    .command-centre-summary { grid-template-columns: 1fr; }
    .command-centre-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .command-centre-kpi:last-child { grid-column: auto; }
    .command-centre-layout { grid-template-columns: 1fr; }
}

@media (max-width: 1540px) {
    .main-menu-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); max-width: 994px; }
}

@media (max-width: 1340px) {
    .main-menu-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); max-width: 741px; }
}

@media (max-width: 820px) {
    .main-menu-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 488px; }
}

@media (max-width: 1080px) {
    .command-centre-side { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .command-centre-side > .panel:last-child { grid-column: 1 / -1; }
}

@media (max-width: 760px) {
    .main-menu-intro { display: block; }
    .main-menu-scope { max-width: none; margin-top: 17px; }
    .main-menu-empty { display: block; }
    .main-menu-empty > .material-symbols-outlined { margin-bottom: 10px; }
    .main-menu-empty .button { margin-top: 16px; }
    .request-tabs { flex-wrap: nowrap; width: calc(100% + 2px); padding-bottom: 9px; margin-right: -2px; overflow-x: auto; }
    .request-tab { flex: 0 0 auto; min-height: 40px; }
    .command-centre-hero { grid-template-columns: 1fr; gap: 16px; padding: 24px 20px; }
    .command-centre-scope-hero { min-height: 0; }
    .command-centre-priority-card { grid-template-columns: auto minmax(0, 1fr); padding: 20px; }
    .command-centre-priority-action { grid-column: 1 / -1; grid-template-columns: 1fr auto; align-items: center; justify-items: stretch; width: 100%; padding-top: 12px; border-top: 1px solid rgba(255, 255, 255, .16); text-align: left; }
    .command-centre-priority-action > div { display: flex; gap: 7px; align-items: baseline; }
    .command-centre-priority-action .button { justify-self: end; }
    .command-centre-kpis, .command-centre-side, .command-centre-due-grid { grid-template-columns: 1fr; }
    .command-centre-side > .panel:last-child { grid-column: auto; }
    .command-centre-heading { display: block; }
    .command-centre-heading > .button, .command-centre-heading > .status-badge { margin-top: 12px; }
    .command-centre-zero-state { align-items: flex-start; flex-wrap: wrap; }
    .command-centre-zero-state .button { width: 100%; }
    .command-centre-table { min-width: 690px; }
}

@media (max-width: 540px) {
    .main-menu-grid { grid-template-columns: minmax(0, 1fr); max-width: none; }
}

@media (max-width: 991px) {
    .public-main { min-height: calc(100dvh - 40px); padding: 20px; }
    .public-layout, .public-layout-wide { grid-template-columns: minmax(0, 520px); justify-content: center; width: 100%; max-width: 520px; }
    .public-brand { display: none; }
    .public-layout-wide .public-panel { min-height: 0; padding: 36px; }
}

@media (max-width: 575px) {
    .public-main { min-height: calc(100dvh - 32px); padding: 16px 14px; }
    .public-panel, .public-layout-wide .public-panel { min-height: 0; padding: 28px 22px; }
    .public-panel h2 { font-size: 22px; }
}

/* Account access and administration: aligned to the maintained bundle-care workspace. */
.public-main {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
    width: 100%;
    max-width: none;
    margin: 0;
    padding-right: 24px;
    padding-left: 24px;
    justify-content: center;
}
.public-layout { justify-self: center; margin-right: auto; margin-left: auto; }
.public-layout-compact {
    grid-template-columns: minmax(0, 520px);
    justify-content: center;
    width: min(520px, 100%);
}
.public-layout-compact .public-brand { display: none; }
.public-layout-compact .public-panel { width: 100%; min-height: 0; }
.public-panel, .public-panel form { min-width: 0; }
.public-panel h2 { overflow-wrap: anywhere; }
.auth-footer { display: flex; flex-wrap: wrap; justify-content: center; gap: 7px; align-items: center; }
.auth-footer > span { color: #a6abb2; }

.sidebar-user {
    display: flex;
    align-items: center;
    color: inherit;
    border-radius: 11px;
    text-decoration: none;
    transition: background .16s ease;
}
.sidebar-user:hover { color: inherit; background: rgba(255, 255, 255, .08); text-decoration: none; }
.sidebar-user > div { flex: 1 1 auto; min-width: 0; }
.sidebar-user-arrow { color: rgba(255, 255, 255, .44); font-size: 17px; transition: color .16s ease, transform .16s ease; }
.sidebar-user:hover .sidebar-user-arrow { color: #fff; transform: translateX(2px); }
.user-avatar-photo { overflow: hidden; padding: 0; background: #fff; }
.user-avatar-photo img { display: block; width: 100%; height: 100%; object-fit: cover; }
.user-avatar-photo.user-avatar-default { padding: 5px; }
.user-avatar-photo.user-avatar-default img { object-fit: contain; }

.profile-grid {
    display: grid;
    grid-template-columns: minmax(240px, 300px) minmax(0, 1fr);
    gap: 22px;
    align-items: start;
}
.profile-summary-card {
    position: sticky;
    top: 132px;
    overflow: hidden;
    color: var(--text);
    background: rgba(255, 255, 255, .92);
    border: 1px solid rgba(207, 220, 232, .9);
    border-radius: 19px;
    box-shadow: var(--shadow-soft);
}
.profile-summary-card::before { display: block; height: 6px; content: ""; background: var(--accent); }
.profile-summary-identity { padding: 28px 24px 22px; text-align: center; }
.profile-avatar-large {
    display: grid;
    width: 84px;
    height: 84px;
    margin: 0 auto 17px;
    color: #fff;
    background: linear-gradient(145deg, var(--primary), var(--teal));
    border: 5px solid rgba(var(--primary-rgb), .10);
    border-radius: 50%;
    box-shadow: 0 11px 24px rgba(15, 111, 191, .18);
    font-size: 30px;
    font-weight: 750;
    place-items: center;
}
.profile-avatar-image { overflow: hidden; padding: 0; background: #fff; }
.profile-avatar-image img { display: block; width: 100%; height: 100%; object-fit: cover; }
.profile-avatar-image.profile-photo-default { padding: 12px; }
.profile-avatar-image.profile-photo-default img { object-fit: contain; }
.profile-summary-identity h3 { margin: 0; color: var(--ink); font-size: 18px; font-weight: 750; letter-spacing: -.02em; }
.profile-username { margin: 4px 0 13px; color: var(--muted); font-family: var(--font-mono); font-size: 10px; }
.profile-role { width: auto; height: auto; padding: 7px 10px; }
.profile-role > span { display: inline-block; }
.profile-details { padding: 0 22px 22px; margin: 0; }
.profile-details > div { padding: 13px 0; border-top: 1px solid var(--border); }
.profile-details dt { margin-bottom: 3px; color: var(--muted); font-size: 9px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.profile-details dd { margin: 0; color: var(--ink); font-size: 11px; font-weight: 700; line-height: 1.45; }
.profile-settings { display: grid; gap: 20px; min-width: 0; }
.profile-settings-card { margin: 0; }
.settings-heading { display: flex; gap: 13px; align-items: flex-start; padding-bottom: 18px; margin-bottom: 20px; border-bottom: 1px solid var(--border); }
.settings-heading > div { min-width: 0; }
.settings-heading h3 { margin: 0; color: var(--ink); font-size: 16px; font-weight: 800; }
.settings-heading p { margin: 4px 0 0; color: var(--muted); font-size: 11px; font-weight: 550; line-height: 1.5; }
.settings-icon { display: grid; flex: 0 0 auto; width: 35px; height: 35px; color: var(--primary-dark); background: rgba(var(--primary-rgb), .09); border-radius: 10px; font-size: 19px; place-items: center; }
.profile-settings-card input[readonly] { color: var(--muted); background: var(--surface-low); cursor: not-allowed; }
.field-span-2 { grid-column: 1 / -1; }
.profile-photo-card { overflow: hidden; }
.profile-photo-editor { display: flex; gap: 24px; align-items: center; padding: 18px; background: linear-gradient(135deg, rgba(var(--primary-rgb), .045), rgba(var(--teal-rgb), .08)); border: 1px solid rgba(var(--primary-rgb), .10); border-radius: 15px; }
.profile-photo-preview-wrap { flex: 0 0 118px; margin: 0; text-align: center; }
.profile-photo-preview { display: block; width: 112px; height: 112px; padding: 0; overflow: hidden; object-fit: cover; background: #fff; border: 3px solid #fff; border-radius: 20px; box-shadow: 0 10px 22px rgba(14, 52, 79, .16); }
.profile-photo-preview.profile-photo-default { padding: 14px; object-fit: contain; }
.profile-photo-preview-wrap figcaption { margin: 9px 0 0; color: var(--muted); font-size: 10px; font-weight: 750; line-height: 1.4; }
.profile-photo-controls { flex: 1 1 auto; min-width: 0; }
.profile-photo-controls form { min-width: 0; }
.profile-photo-controls input[type="file"] { width: 100%; padding: 7px; background: #fff; font-size: 11px; }
.profile-photo-controls input[type="file"]::file-selector-button { padding: 7px 10px; margin-right: 9px; color: var(--primary-dark); background: rgba(var(--primary-rgb), .09); border: 0; border-radius: 7px; font: inherit; font-weight: 800; cursor: pointer; }
.profile-photo-form-actions { display: flex; flex-wrap: wrap; gap: 9px; align-items: center; margin-top: 16px; }
.profile-photo-form-actions .button, .profile-photo-remove-form .button { min-height: 36px; padding: 7px 12px; }
.profile-photo-remove-form { padding-top: 12px; margin-top: 12px; border-top: 1px solid var(--border); }
.button:disabled { cursor: not-allowed; opacity: .52; box-shadow: none; transform: none; }

.scope-assignment-summary { display: flex; gap: 16px; align-items: center; justify-content: space-between; padding: 15px 16px; background: var(--surface-low); border: 1px solid var(--border); border-radius: 12px; }
.scope-assignment-summary > div { min-width: 0; }
.scope-assignment-summary span:not(.status-badge), .scope-dialog-current span { display: block; margin-bottom: 4px; color: var(--muted); font-size: 9px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.scope-assignment-summary strong, .scope-dialog-current strong { display: block; color: var(--ink); font-size: 12px; line-height: 1.45; }
.scope-not-applicable { display: flex; gap: 12px; align-items: flex-start; padding: 16px; margin-top: 14px; color: var(--text); background: var(--info-soft); border: 1px solid rgba(var(--primary-rgb), .18); border-radius: 12px; }
.scope-not-applicable .ui-icon { flex: 0 0 auto; color: var(--primary-dark); }
.scope-not-applicable strong { display: block; color: var(--ink); font-size: 11px; }
.scope-not-applicable p { margin: 4px 0 0; color: var(--muted); font-size: 10px; line-height: 1.5; }
.scope-request-intro { display: flex; gap: 18px; align-items: center; justify-content: space-between; padding-top: 17px; }
.scope-request-intro p { max-width: 620px; margin: 0; color: var(--muted); font-size: 10px; line-height: 1.55; }
.scope-request-intro .button { flex: 0 0 auto; }
.scope-pending-card { padding: 17px; margin-top: 14px; background: var(--warning-soft); border: 1px solid rgba(138, 101, 11, .22); border-radius: 13px; }
.scope-pending-heading { display: flex; gap: 14px; align-items: flex-start; justify-content: space-between; }
.scope-pending-heading h4 { margin: 8px 0 0; color: var(--ink); font-size: 13px; }
.scope-request-id { color: var(--muted); font-family: var(--font-mono); font-size: 9px; font-weight: 700; white-space: nowrap; }
.scope-request-details { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 18px; padding: 14px 0 0; margin: 14px 0 0; border-top: 1px solid rgba(138, 101, 11, .18); }
.scope-request-details > div { min-width: 0; }
.scope-request-details dt, .scope-review-details dt { margin-bottom: 4px; color: var(--muted); font-size: 9px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; }
.scope-request-details dd, .scope-review-details dd { margin: 0; color: var(--text); font-size: 10px; font-weight: 650; line-height: 1.55; overflow-wrap: anywhere; }
.scope-request-note { grid-column: 1 / -1; }
.scope-cancel-form { padding-top: 15px; margin-top: 15px; border-top: 1px solid rgba(138, 101, 11, .18); }
.profile-scope-dialog { width: min(calc(100vw - 32px), 720px); }
.scope-dialog-current { padding: 14px 15px; background: var(--surface-low); border: 1px solid var(--border); border-radius: 11px; }

.account-form-card { max-width: 920px; margin-right: auto; margin-left: auto; }
.account-password-reset-grid { align-items: start; padding-top: 22px; margin-top: 22px; border-top: 1px solid var(--border); }
.checkbox-field {
    display: flex;
    align-items: center;
    align-self: end;
    gap: 9px;
    min-height: 42px;
    padding: 10px 12px;
    color: var(--ink);
    background: var(--surface-low);
    border: 1px solid var(--border);
    border-radius: 10px;
    font-size: 11px;
    font-weight: 750;
    cursor: pointer;
}
.checkbox-field input { width: 17px; min-height: 17px; margin: 0; accent-color: var(--primary); }
.binary-choice-field { min-width: 0; padding: 0; margin: 0; border: 0; }
.binary-choice-field legend { padding: 0; margin-bottom: 7px; color: var(--ink); font-size: 11px; font-weight: 800; }
.binary-choice-options { display: flex; gap: 8px; min-height: 42px; }
.binary-choice { display: flex; flex: 1 1 0; gap: 8px; align-items: center; justify-content: center; min-width: 78px; padding: 9px 12px; color: var(--text); background: var(--surface-low); border: 1px solid var(--border); border-radius: 10px; font-size: 11px; font-weight: 750; cursor: pointer; transition: background .16s ease, border-color .16s ease; }
.binary-choice:hover, .binary-choice:focus-within { background: var(--primary-soft); border-color: var(--primary); }
.binary-choice input { width: 17px; min-height: 17px; margin: 0; accent-color: var(--primary); }
.binary-choice-field:disabled .binary-choice { cursor: not-allowed; opacity: .68; }

.user-management-panel { padding: 0; overflow: hidden; }
.user-filter-bar {
    display: grid;
    grid-template-columns: minmax(250px, 1.35fr) minmax(160px, .65fr) minmax(220px, .85fr) auto;
    gap: 13px;
    align-items: end;
    padding: 22px;
    background: rgba(245, 233, 212, .54);
    border-bottom: 1px solid #ead6b9;
}
.user-filter-actions { display: flex; gap: 8px; padding-bottom: 1px; }
.user-filter-actions .button { white-space: nowrap; }
.user-management-panel .request-tabs { padding: 18px 22px 16px; margin: 0; }
.user-management-panel .table-wrap { margin: 0; border: 0; border-radius: 0; box-shadow: none; }
.user-management-table { min-width: 900px; }
.user-management-table th, .user-management-table td { padding: 13px 15px; vertical-align: middle; }
.user-management-table th:first-child, .user-management-table td:first-child { padding-left: 22px; }
.user-management-table th:last-child, .user-management-table td:last-child { padding-right: 22px; }
.user-listing-identity { display: flex; gap: 11px; align-items: center; min-width: 245px; }
.user-listing-avatar { display: block; flex: 0 0 auto; width: 40px; height: 40px; overflow: hidden; background: #fff; border: 1px solid rgba(var(--primary-rgb), .16); border-radius: 12px; box-shadow: 0 4px 12px rgba(11, 34, 53, .08); }
.user-listing-avatar img { display: block; width: 100%; height: 100%; object-fit: cover; }
.user-listing-avatar.user-listing-avatar-default { padding: 6px; }
.user-listing-avatar.user-listing-avatar-default img { object-fit: contain; }
.user-listing-identity > div { min-width: 0; }
.user-listing-identity strong, .user-listing-identity span, .user-listing-identity small { display: block; }
.user-listing-identity strong { color: var(--ink); font-size: 11px; font-weight: 800; }
.user-listing-identity span { max-width: 320px; margin-top: 2px; overflow: hidden; color: var(--muted); font-size: 9px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.user-listing-identity small { margin-top: 2px; color: var(--primary-dark); font-size: 9px; font-weight: 700; }
.user-listing-last-login { min-width: 136px; white-space: nowrap; }
.table-sort-link { display: inline-flex; gap: 6px; align-items: center; color: inherit; text-decoration: none; }
.table-sort-link:hover { color: var(--primary-dark); text-decoration: none; }
.table-sort-icon { font-size: 16px; }
.action-links { display: flex; gap: 7px; align-items: center; }
.button-count { display: inline-grid; min-width: 20px; height: 20px; margin-left: 2px; padding: 0 5px; color: #fff; background: var(--accent); border-radius: 999px; font-size: 9px; place-items: center; }
.status-muted { color: var(--muted); background: var(--surface-low); border-color: var(--border); }
.management-section-tabs { display: flex; gap: 8px; margin-bottom: 18px; padding: 7px; overflow-x: auto; background: var(--surface); border: 1px solid var(--border); border-radius: 13px; box-shadow: var(--shadow-soft); }
.management-section-tabs a { display: inline-flex; flex: 0 0 auto; gap: 8px; align-items: center; min-height: 38px; padding: 8px 12px; color: var(--muted); border-radius: 9px; font-size: 10px; font-weight: 800; text-decoration: none; white-space: nowrap; }
.management-section-tabs a:hover { color: var(--primary-dark); background: var(--primary-soft); text-decoration: none; }
.management-section-tabs a.active { color: #fff; background: var(--ink); }
.management-section-tabs .ui-icon { font-size: 17px; }
.management-section-tabs strong { display: inline-grid; min-width: 20px; height: 20px; padding: 0 5px; color: #fff; background: var(--accent); border-radius: 999px; font-size: 9px; place-items: center; }
.scope-request-filter-bar { display: grid; grid-template-columns: minmax(260px, 1fr) minmax(180px, .45fr) auto; gap: 13px; align-items: end; padding: 22px; background: rgba(245, 233, 212, .54); border-bottom: 1px solid #ead6b9; }
.scope-request-filter-bar.scope-request-filter-simple { grid-template-columns: minmax(260px, 1fr) auto; }
.scope-request-table { min-width: 1180px; }
.scope-request-table th, .scope-request-table td { padding: 13px 14px; vertical-align: top; }
.scope-request-table th:first-child, .scope-request-table td:first-child { width: 66px; padding-left: 22px; text-align: center; }
.scope-request-table th:last-child, .scope-request-table td:last-child { padding-right: 22px; }
.scope-request-table td { font-size: 10px; line-height: 1.5; }
.scope-request-table td > strong { color: var(--ink); }
.scope-request-table .table-subtext { max-width: 260px; white-space: normal; }
.scope-request-view-button { display: inline-grid; width: 36px; min-height: 36px; padding: 0; place-items: center; }
.scope-request-view-button .ui-icon { font-size: 18px; }
.scope-request-review-dialog { width: min(calc(100vw - 32px), 820px); }
.scope-review-status-row { display: flex; gap: 12px; align-items: center; justify-content: space-between; }
.scope-review-status-row > span:last-child { color: var(--muted); font-family: var(--font-mono); font-size: 10px; font-weight: 750; }
.scope-review-details { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0; margin: 0; overflow: hidden; border: 1px solid var(--border); border-radius: 12px; }
.scope-review-details > div { min-width: 0; padding: 14px 15px; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.scope-review-details > div:nth-child(2n) { border-right: 0; }
.scope-review-details > div:nth-last-child(-n+2) { border-bottom: 0; }
.scope-review-details > .scope-review-full { grid-column: 1 / -1; border-right: 0; border-bottom: 0; }
.scope-review-history { padding-top: 2px; }
.scope-review-impact { display: flex; gap: 11px; align-items: flex-start; padding: 13px 14px; color: var(--primary-dark); background: var(--info-soft); border: 1px solid rgba(var(--primary-rgb), .18); border-radius: 11px; }
.scope-review-impact .ui-icon { flex: 0 0 auto; font-size: 19px; }
.scope-review-impact p { margin: 0; font-size: 10px; font-weight: 650; line-height: 1.55; }
.scope-review-actions { gap: 9px; }
.pagination-bar { display: flex; gap: 18px; align-items: center; justify-content: space-between; padding: 17px 22px; border-top: 1px solid var(--border); }
.pagination-summary { margin: 0; color: var(--muted); font-size: 10px; font-weight: 650; }
.pagination { display: flex; flex-wrap: wrap; gap: 5px; justify-content: flex-end; }
.pagination a, .pagination > span { display: inline-grid; min-width: 31px; min-height: 31px; padding: 5px 8px; color: var(--primary-dark); background: #fff; border: 1px solid var(--border); border-radius: 7px; font-size: 10px; font-weight: 750; text-decoration: none; place-items: center; }
.pagination a:hover { color: #fff; background: var(--primary); border-color: var(--primary); text-decoration: none; }
.pagination .pagination-current { color: #fff; background: var(--ink); border-color: var(--ink); }
.pagination .disabled { color: #a2aab2; background: var(--surface-low); }
.pagination .pagination-ellipsis { min-width: 20px; padding-right: 2px; padding-left: 2px; background: transparent; border-color: transparent; }

html[data-theme="dark"] .profile-summary-card,
html[data-theme="dark"] .pagination a { background: var(--surface); }
html[data-theme="dark"] .profile-avatar-image,
html[data-theme="dark"] .profile-avatar-image.profile-photo-default,
html[data-theme="dark"] .user-avatar-photo,
html[data-theme="dark"] .user-listing-avatar { background: #fff; }
html[data-theme="dark"] .profile-photo-editor { background: var(--surface-low); border-color: var(--border); }
html[data-theme="dark"] .profile-photo-preview { box-shadow: none; }
html[data-theme="dark"] .profile-photo-controls input[type="file"] { color: var(--text); background: var(--surface); }
html[data-theme="dark"] .user-filter-bar,
html[data-theme="dark"] .scope-request-filter-bar { background: #2d3030; border-color: #4a4d4d; }
html[data-theme="dark"] .user-listing-avatar { box-shadow: 0 7px 16px rgba(0, 0, 0, .18); }
html[data-theme="dark"] .pagination .pagination-current { color: #21140f; background: #ffd6c3; border-color: #ffd6c3; }
html[data-theme="dark"] .pagination .disabled { color: #71808c; background: var(--surface-low); }
html[data-theme="dark"] .scope-assignment-summary,
html[data-theme="dark"] .scope-dialog-current { background: var(--surface-low); border-color: var(--border); }
html[data-theme="dark"] .scope-not-applicable,
html[data-theme="dark"] .scope-review-impact { color: var(--text); background: rgba(var(--primary-rgb), .12); border-color: rgba(var(--primary-rgb), .32); }
html[data-theme="dark"] .scope-pending-card { background: rgba(138, 101, 11, .15); border-color: rgba(255, 210, 92, .28); }
html[data-theme="dark"] .scope-pending-card .scope-request-details,
html[data-theme="dark"] .scope-pending-card .scope-cancel-form { border-color: rgba(255, 210, 92, .22); }
html[data-theme="dark"] .management-section-tabs { background: var(--surface); border-color: var(--border); box-shadow: none; }
html[data-theme="dark"] .management-section-tabs a.active { color: #21140f; background: #ffd6c3; }
html[data-theme="dark"] .scope-review-details { border-color: var(--border); }
html[data-theme="dark"] .scope-review-details > div { border-color: var(--border); }

@media (max-width: 1080px) {
    .user-filter-bar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .scope-request-filter-bar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .user-filter-actions { justify-content: flex-end; }
}

@media (max-width: 991px) {
    .public-layout, .public-layout-wide, .public-layout-compact { grid-template-columns: minmax(0, 520px); justify-content: center; width: 100%; max-width: 520px; }
    .profile-grid { grid-template-columns: 1fr; }
    .profile-summary-card { position: static; }
}

@media (max-width: 760px) {
    .topbar-actions .role-pill > span:not(.material-symbols-outlined) { display: none; }
    .profile-role > span:not(.material-symbols-outlined) { display: inline-block; }
    .profile-role { width: auto; height: auto; padding: 7px 10px; }
    .user-filter-bar { grid-template-columns: 1fr; padding: 18px; }
    .scope-request-filter-bar { grid-template-columns: 1fr; padding: 18px; }
    .scope-request-filter-bar.scope-request-filter-simple { grid-template-columns: 1fr; }
    .user-filter-actions { justify-content: stretch; }
    .user-filter-actions .button { flex: 1 1 0; }
    .user-management-panel .request-tabs { padding-right: 18px; padding-left: 18px; }
    .pagination-bar { align-items: flex-start; flex-direction: column; padding: 16px 18px; }
    .pagination { justify-content: flex-start; }
    .profile-photo-editor { align-items: flex-start; flex-direction: column; }
    .profile-photo-preview-wrap { display: flex; flex-basis: auto; gap: 12px; align-items: center; text-align: left; }
    .profile-photo-preview-wrap figcaption { margin: 0; }
    .profile-photo-preview { width: 82px; height: 82px; border-radius: 16px; }
    .profile-photo-controls { width: 100%; }
    .scope-request-intro { align-items: stretch; flex-direction: column; }
    .scope-request-intro .button { justify-content: center; width: 100%; }
    .scope-review-actions { flex-direction: column-reverse; align-items: stretch; }
    .scope-review-actions .button { justify-content: center; width: 100%; }
}

@media (max-width: 575px) {
    .public-layout-compact .public-panel { padding: 28px 22px; }
    .profile-settings-card .field-grid, .account-form-card .field-grid { grid-template-columns: 1fr; }
    .field-span-2 { grid-column: auto; }
    .profile-summary-identity { padding: 24px 20px 19px; }
    .profile-details { padding-right: 19px; padding-left: 19px; }
    .scope-assignment-summary, .scope-pending-heading { align-items: flex-start; flex-direction: column; }
    .scope-request-details, .scope-review-details { grid-template-columns: 1fr; }
    .scope-request-details > div, .scope-request-note { grid-column: auto; }
    .scope-review-details > div, .scope-review-details > div:nth-child(2n), .scope-review-details > div:nth-last-child(-n+2) { border-right: 0; border-bottom: 1px solid var(--border); }
    .scope-review-details > div:last-child { border-bottom: 0; }
    .profile-scope-dialog, .scope-request-review-dialog { width: calc(100vw - 20px); max-height: calc(100dvh - 20px); }
    .pagination a:nth-child(-n+2), .pagination a:nth-last-child(-n+2), .pagination > span.disabled { display: none; }
}

.notification-status-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}
.smtp-settings-panel { margin-bottom: 20px; }
.smtp-settings-grid > label:not(.checkbox-field) { display: flex; min-width: 0; flex-direction: column; gap: 7px; color: var(--ink); font-size: 11px; font-weight: 800; }
.smtp-settings-grid > label:not(.checkbox-field) > small { color: var(--muted); font-size: 9px; font-weight: 600; line-height: 1.45; }
.smtp-clear-password { align-self: end; }
.notification-status-card { min-width: 0; margin: 0; }
.notification-status-list { margin: 0; }
.notification-status-list > div { display: flex; gap: 16px; align-items: center; justify-content: space-between; padding: 10px 0; border-top: 1px solid var(--border); }
.notification-status-list > div:first-child { padding-top: 0; border-top: 0; }
.notification-status-list dt { color: var(--muted); font-size: 10px; font-weight: 750; }
.notification-status-list dd { margin: 0; color: var(--ink); font-size: 11px; font-weight: 750; text-align: right; }
.notification-test-form { display: flex; flex-wrap: wrap; gap: 10px 13px; align-items: center; padding-top: 16px; margin-top: 7px; border-top: 1px solid var(--border); }
.notification-test-form span { color: var(--muted); font-size: 10px; font-weight: 600; }
.notification-queue-counts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 9px; }
.notification-queue-counts > div { min-width: 0; padding: 13px 9px; text-align: center; background: var(--surface-low); border: 1px solid var(--border); border-radius: 11px; }
.notification-queue-counts span, .notification-queue-counts strong { display: block; }
.notification-queue-counts span { color: var(--muted); font-size: 9px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.notification-queue-counts strong { margin-top: 4px; color: var(--ink); font-family: var(--font-mono); font-size: 21px; }
.notification-worker-note { padding: 11px 12px; margin: 14px 0 0; color: var(--text); background: rgba(var(--primary-rgb), .06); border: 1px solid rgba(var(--primary-rgb), .13); border-radius: 10px; font-size: 10px; line-height: 1.55; overflow-wrap: anywhere; }
.notification-worker-note code { color: var(--primary-dark); font-weight: 750; }
.notification-queue-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 12px; }
.notification-queue-actions .button { flex: 1 1 180px; justify-content: center; }
.notification-tabs { margin-bottom: 20px; }
.notification-tab-panel { margin-bottom: 0; }
.notification-page-note { max-width: 720px; margin: 10px 0 0; color: var(--muted); font-size: 10px; font-weight: 650; line-height: 1.5; }
.notification-recipient-panel { padding: 0; margin-bottom: 20px; overflow: hidden; }
.notification-recipient-panel > .panel-heading { padding: 22px 22px 18px; margin: 0; }
.notification-recipient-panel .table-wrap, .notification-history-panel .table-wrap { margin: 0; border-right: 0; border-left: 0; border-radius: 0; box-shadow: none; }
.notification-recipient-panel .pagination-bar, .notification-history-panel .pagination-bar { margin: 0; }
.notification-recipient-panel .form-actions { padding: 16px 22px; margin: 0; }
.notification-recipient-table { min-width: 940px; }
.notification-recipient-table th, .notification-recipient-table td { padding: 12px 11px; text-align: center; vertical-align: middle; }
.notification-recipient-table th:first-child, .notification-recipient-table td:first-child { min-width: 260px; padding-left: 22px; text-align: left; }
.notification-recipient-table th:last-child, .notification-recipient-table td:last-child { padding-right: 22px; }
.notification-recipient-table td:first-child strong, .notification-recipient-table .table-subtext { display: block; }
.notification-recipient-table td:first-child strong { color: var(--ink); font-size: 11px; }
.notification-recipient-table .table-subtext { margin-top: 3px; color: var(--muted); font-size: 9px; }
.notification-choice { display: inline-flex; width: 36px; height: 34px; align-items: center; justify-content: center; background: var(--surface-low); border: 1px solid var(--border); border-radius: 9px; cursor: pointer; transition: background .16s ease, border-color .16s ease; }
.notification-choice:hover, .notification-choice:focus-within { background: var(--primary-soft); border-color: var(--primary); }
.notification-choice input { width: 17px; min-height: 17px; margin: 0; accent-color: var(--primary); cursor: pointer; }
.notification-choice > span { display: none; }
.notification-history-panel { padding: 0; overflow: hidden; }
.notification-history-panel > .panel-heading { padding: 22px 22px 18px; margin: 0; }
.notification-history-table { min-width: 1040px; }
.notification-history-table th, .notification-history-table td { padding: 12px 14px; vertical-align: middle; }
.notification-history-table th:first-child, .notification-history-table td:first-child { padding-left: 22px; }
.notification-history-table th:last-child, .notification-history-table td:last-child { padding-right: 22px; }
.notification-history-table td strong, .notification-history-table .table-subtext { display: block; }
.notification-history-table .table-subtext { max-width: 290px; margin-top: 3px; color: var(--muted); font-size: 9px; white-space: normal; }
.notification-history-table td:last-child { max-width: 300px; white-space: normal; overflow-wrap: anywhere; }

/* Versioned audit form management. */
.template-create-dialog { width: min(calc(100vw - 32px), 720px); max-height: min(90dvh, 680px); padding: 0; overflow: hidden; color: var(--text); background: var(--surface); border: 1px solid var(--border-strong); border-radius: 18px; box-shadow: 0 24px 62px rgba(11, 38, 63, .24); }
.template-create-dialog::backdrop { background: rgba(7, 27, 46, .58); backdrop-filter: blur(3px); }
.template-create-dialog-card { display: flex; flex-direction: column; max-height: min(90dvh, 680px); }
.template-create-dialog-header { display: flex; gap: 18px; align-items: flex-start; justify-content: space-between; padding: 24px 24px 18px; border-bottom: 1px solid var(--border); }
.template-create-dialog-header > div { min-width: 0; }
.template-create-dialog-header h2 { margin: 0; font-size: 17px; }
.template-create-dialog-header p:not(.eyebrow) { max-width: 550px; margin: 6px 0 0; color: var(--muted); font-size: 11px; line-height: 1.55; }
.template-create-dialog-header .icon-button { flex: 0 0 auto; }
.template-create-dialog-body { display: grid; gap: 18px; padding: 22px 24px 24px; overflow: auto; overscroll-behavior: contain; }
.template-create-dialog-body .field-grid { align-items: start; }
.template-create-dialog-actions { position: static; display: flex; justify-content: flex-end; margin: 4px 0 0; }
.template-editor-dialog { width: min(calc(100vw - 32px), 820px); max-height: min(90dvh, 760px); padding: 0; overflow: hidden; color: var(--text); background: var(--surface); border: 1px solid var(--border-strong); border-radius: 18px; box-shadow: 0 24px 62px rgba(11, 38, 63, .24); }
.template-editor-dialog::backdrop { background: rgba(7, 27, 46, .58); backdrop-filter: blur(3px); }
.template-editor-dialog-card { display: flex; flex-direction: column; max-height: min(90dvh, 760px); }
.template-editor-dialog-header { display: flex; gap: 18px; align-items: flex-start; justify-content: space-between; padding: 24px 24px 18px; border-bottom: 1px solid var(--border); }
.template-editor-dialog-header > div { min-width: 0; }
.template-editor-dialog-header h2 { margin: 0; font-size: 17px; }
.template-editor-dialog-header p:not(.eyebrow) { max-width: 650px; margin: 6px 0 0; color: var(--muted); font-size: 11px; line-height: 1.55; }
.template-editor-dialog-header .icon-button { display: inline-flex; flex: 0 0 auto; align-items: center; justify-content: center; text-decoration: none; }
.template-editor-dialog-body { display: grid; gap: 18px; padding: 22px 24px 24px; overflow: auto; overscroll-behavior: contain; }
.template-editor-dialog-body .field-grid { align-items: start; }
.template-editor-dialog-actions { position: static; display: flex; justify-content: flex-end; margin: 4px 0 0; }
.template-version-panel, .template-content-panel { padding: 0; overflow: hidden; }
.template-version-panel > .panel-heading, .template-content-panel > .panel-heading { padding: 22px 22px 18px; margin: 0; }
.template-version-panel .template-version-tabs { padding: 0 22px 16px; margin: 0; }
.template-content-panel .template-content-tabs { padding: 0 22px 16px; margin: 0; }
.template-content-heading .button { flex: 0 0 auto; white-space: nowrap; }
.template-version-panel .table-wrap, .template-content-panel .table-wrap { margin: 0; border-right: 0; border-left: 0; border-radius: 0; box-shadow: none; }
.template-content-panel .pagination-bar { margin: 0; }
.template-version-table { min-width: 980px; }
.template-version-table th, .template-version-table td { padding: 13px 14px; vertical-align: middle; }
.template-version-table th:first-child, .template-version-table td:first-child, .template-tab-table th:first-child, .template-tab-table td:first-child, .template-criteria-table th:first-child, .template-criteria-table td:first-child { padding-left: 22px; }
.template-version-table th:last-child, .template-version-table td:last-child, .template-tab-table th:last-child, .template-tab-table td:last-child, .template-criteria-table th:last-child, .template-criteria-table td:last-child { padding-right: 22px; }
.template-version-table strong, .template-tab-table strong, .template-criteria-table strong { color: var(--ink); font-size: 11px; }
.template-version-table form { margin: 0; }
.template-version-actions { flex-wrap: wrap; }
.template-version-icon-action { width: 34px; min-width: 34px; min-height: 34px; padding: 5px; gap: 0; }
.template-version-icon-action .ui-icon { font-size: 18px; }
.template-current-tag { display: inline-flex; align-items: center; min-height: 20px; margin-left: 7px; padding: 2px 7px; color: var(--primary-dark); background: var(--primary-soft); border-radius: 999px; font-size: 9px; font-weight: 800; vertical-align: middle; }
.template-scope-field { min-width: 0; padding: 0; margin: 0; border: 0; }
.template-scope-field legend { padding: 0; margin-bottom: 7px; color: var(--ink); font-size: 11px; font-weight: 800; }
.template-scope-choice-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px; }
.template-scope-choice { display: flex; gap: 8px; align-items: center; min-height: 40px; padding: 8px 10px; color: var(--text); background: var(--surface-low); border: 1px solid var(--border); border-radius: 9px; font-size: 11px; font-weight: 700; cursor: pointer; transition: background .16s ease, border-color .16s ease; }
.template-scope-choice:hover, .template-scope-choice:focus-within { background: var(--primary-soft); border-color: var(--primary); }
.template-scope-choice input { width: 16px; min-height: 16px; margin: 0; accent-color: var(--primary); }
.template-scope-description { margin: 0 0 9px; color: var(--muted); font-size: 10px; font-weight: 600; line-height: 1.45; }
.template-scope-departments { padding: 12px; background: var(--surface-low); border: 1px solid var(--border); border-radius: 11px; }
.template-scope-departments > summary { color: var(--primary-dark); font-size: 11px; font-weight: 800; cursor: pointer; }
.template-scope-department-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 10px; padding-top: 12px; }
.template-scope-department-group { min-width: 0; padding: 11px; background: var(--surface); border: 1px solid var(--border); border-radius: 9px; }
.template-scope-department-group h3 { margin: 0 0 8px; color: var(--ink); font-size: 11px; font-weight: 800; }
.template-scope-department-group > div { display: grid; gap: 7px; }
.template-scope-department-group .template-scope-choice { min-height: 36px; padding: 7px 8px; font-size: 10px; }
.template-builder-grid { display: grid; grid-template-columns: minmax(280px, .8fr) minmax(340px, 1.2fr); gap: 20px; align-items: start; }
.template-editor-card { min-width: 0; }
.template-editor-card .stack-form { display: grid; gap: 16px; }
.template-editor-card .form-actions { position: static; margin-top: 3px; }
.template-readonly-note, .template-publish-panel { display: flex; gap: 18px; align-items: center; justify-content: space-between; }
.template-readonly-note > div, .template-publish-panel > div { min-width: 0; }
.template-readonly-note h2, .template-publish-panel h2 { margin: 0; font-size: 16px; }
.template-readonly-note p:not(.eyebrow), .template-publish-panel p:not(.eyebrow) { max-width: 760px; margin: 6px 0 0; color: var(--muted); font-size: 11px; line-height: 1.55; }
.template-readonly-note form, .template-publish-panel form { flex: 0 0 auto; margin: 0; }
.template-readonly-note .button, .template-publish-panel .button { white-space: nowrap; }
.template-tab-table { min-width: 720px; }
.template-criteria-wrap { border-top: 1px solid var(--border); }
.template-criteria-table { min-width: 1120px; }
.template-tab-table th, .template-tab-table td, .template-criteria-table th, .template-criteria-table td { padding: 12px 14px; vertical-align: middle; }

html[data-theme="dark"] .template-create-dialog { color: var(--text); background: var(--surface); border-color: var(--border-strong); box-shadow: 0 24px 62px rgba(0, 0, 0, .48); }
html[data-theme="dark"] .template-create-dialog-header { border-color: var(--border); }
html[data-theme="dark"] .template-editor-dialog { color: var(--text); background: var(--surface); border-color: var(--border-strong); box-shadow: 0 24px 62px rgba(0, 0, 0, .48); }
html[data-theme="dark"] .template-editor-dialog-header { border-color: var(--border); }
html[data-theme="dark"] .template-current-tag { color: #b9dcff; background: rgba(57, 122, 177, .28); }
html[data-theme="dark"] .template-scope-departments, html[data-theme="dark"] .template-scope-department-group { color: var(--text); background: var(--surface-low); border-color: var(--border); }
html[data-theme="dark"] .template-scope-choice { color: var(--text); background: var(--surface); border-color: var(--border); }
html[data-theme="dark"] .template-scope-choice:hover, html[data-theme="dark"] .template-scope-choice:focus-within { background: rgba(57, 122, 177, .24); border-color: #79b8ef; }
html[data-theme="dark"] .template-readonly-note, html[data-theme="dark"] .template-publish-panel { color: var(--text); background: var(--surface); border-color: var(--border); }
html[data-theme="dark"] .template-version-panel .template-version-tabs { border-color: var(--border); }
html[data-theme="dark"] .template-content-panel .template-content-tabs { border-color: var(--border); }

@media (max-width: 980px) {
    .notification-status-grid { grid-template-columns: 1fr; }
    .template-builder-grid { grid-template-columns: 1fr; }
}

@media (max-width: 575px) {
    .notification-status-grid { gap: 16px; }
    .notification-queue-counts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .notification-test-form { align-items: stretch; flex-direction: column; }
    .notification-test-form .button { justify-content: center; width: 100%; }
    .template-readonly-note, .template-publish-panel { align-items: flex-start; flex-direction: column; }
    .template-readonly-note .button, .template-publish-panel .button { width: 100%; justify-content: center; }
    .template-version-panel .template-version-tabs { padding-right: 18px; padding-left: 18px; }
    .template-content-panel .template-content-tabs { padding-right: 18px; padding-left: 18px; }
    .template-scope-choice-grid, .template-scope-department-grid { grid-template-columns: 1fr; }
    .template-editor-dialog { width: calc(100vw - 20px); max-height: calc(100dvh - 20px); }
    .template-editor-dialog-card { max-height: calc(100dvh - 20px); }
    .template-editor-dialog-header, .template-editor-dialog-body { padding-right: 18px; padding-left: 18px; }
    .template-editor-dialog-actions { flex-direction: column-reverse; align-items: stretch; }
    .template-editor-dialog-actions .button { width: 100%; justify-content: center; }
    .template-create-dialog { width: calc(100vw - 20px); max-height: calc(100dvh - 20px); }
    .template-create-dialog-card { max-height: calc(100dvh - 20px); }
    .template-create-dialog-header, .template-create-dialog-body { padding-right: 18px; padding-left: 18px; }
    .template-create-dialog-actions { flex-direction: column-reverse; align-items: stretch; }
    .template-create-dialog-actions .button { width: 100%; justify-content: center; }
}

/* Effective-dated department sample-size settings. */
.sample-size-management-panel { padding: 0; overflow: hidden; }
.sample-size-heading { padding: 22px 22px 18px; margin: 0; }
.sample-size-heading p:not(.eyebrow) { max-width: 740px; margin: 6px 0 0; color: var(--muted); font-size: 11px; font-weight: 600; line-height: 1.55; }
.sample-size-tabs { padding: 0 22px 16px; margin: 0; }
.sample-size-filter-bar { display: grid; grid-template-columns: minmax(150px, .6fr) minmax(220px, 1fr) minmax(220px, 1fr) auto; gap: 13px; align-items: end; padding: 17px 22px 19px; background: rgba(245, 233, 212, .52); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.sample-size-filter-actions { display: flex; gap: 8px; align-items: center; justify-content: flex-end; }
.sample-size-target-table { min-width: 1180px; }
.sample-size-target-table th, .sample-size-target-table td { padding: 12px 13px; vertical-align: middle; }
.sample-size-target-table th:first-child, .sample-size-target-table td:first-child { padding-left: 22px; }
.sample-size-target-table th:last-child, .sample-size-target-table td:last-child { padding-right: 22px; }
.sample-size-row-actions { flex-wrap: nowrap; }
.sample-size-row-actions form { margin: 0; }
.sample-size-target-value { color: var(--ink); font-family: var(--font-mono); font-size: 16px; }
.sample-size-month-cell { white-space: nowrap; }
.sample-size-notes { max-width: 310px; white-space: normal; overflow-wrap: anywhere; }
.sample-size-dialog { width: min(calc(100vw - 32px), 780px); }
.sample-size-locked-scope { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.sample-size-locked-scope[hidden], .sample-size-scope-fields[hidden] { display: none; }
.sample-size-locked-scope > div { min-width: 0; padding: 11px 12px; background: var(--surface-low); border: 1px solid var(--border); border-radius: 10px; }
.sample-size-locked-scope span, .sample-size-locked-scope strong { display: block; }
.sample-size-locked-scope span { margin-bottom: 4px; color: var(--muted); font-size: 9px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; }
.sample-size-locked-scope strong { color: var(--ink); font-size: 11px; line-height: 1.45; overflow-wrap: anywhere; }

@media (max-width: 980px) {
    .sample-size-filter-bar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .sample-size-filter-actions { justify-content: stretch; }
    .sample-size-filter-actions .button { flex: 1 1 auto; justify-content: center; }
}

@media (max-width: 575px) {
    .sample-size-tabs { flex-wrap: nowrap; overflow-x: auto; padding-right: 18px; padding-left: 18px; }
    .sample-size-filter-bar { grid-template-columns: 1fr; padding-right: 18px; padding-left: 18px; }
    .sample-size-filter-actions { flex-direction: column; align-items: stretch; }
    .sample-size-filter-actions .button { width: 100%; }
    .sample-size-locked-scope { grid-template-columns: 1fr; }
    .sample-size-dialog { width: calc(100vw - 20px); max-height: calc(100dvh - 20px); }
}

/* Complete dark-theme component contract. Keep this final block after all module rules. */
html[data-theme="dark"] {
    color-scheme: dark;
}

html[data-theme="dark"] body,
html[data-theme="dark"] .app-shell {
    color: var(--text);
    background-color: var(--canvas);
}

html[data-theme="dark"] .app-main,
html[data-theme="dark"] .content {
    color: var(--text);
    background-color: transparent;
}

html[data-theme="dark"] ::selection {
    color: #07131d;
    background: #9bd2f7;
}

html[data-theme="dark"] :focus-visible {
    outline-color: rgba(255, 173, 137, .72);
    box-shadow: 0 0 0 4px var(--focus);
}

html[data-theme="dark"] .skip-link {
    color: #21140f;
    background: #ffd6c3;
    border-color: #ffd6c3;
    box-shadow: 0 8px 18px rgba(0, 0, 0, .26);
}

html[data-theme="dark"] .app-shell::before {
    opacity: 1;
}

html[data-theme="dark"] .account-password-reset-grid { border-top-color: #344655; }

html[data-theme="dark"] .topbar,
html[data-theme="dark"] .form-actions {
    color: var(--text);
    background: rgba(19, 30, 40, .94);
    border-color: #344655;
    box-shadow: 0 12px 30px rgba(0, 0, 0, .20);
}

html[data-theme="dark"] .panel,
html[data-theme="dark"] .kpi-card,
html[data-theme="dark"] .detail-strip,
html[data-theme="dark"] .profile-summary-card,
html[data-theme="dark"] .dashboard-kpi,
html[data-theme="dark"] .command-centre-kpi {
    color: var(--text);
    background: var(--surface);
    border-color: var(--border);
    box-shadow: none;
}

html[data-theme="dark"] .theme-toggle,
html[data-theme="dark"] .auth-theme-toggle {
    color: var(--ink);
    background: #263543;
    border-color: #52677a;
    box-shadow: none;
}

html[data-theme="dark"] .theme-toggle:hover,
html[data-theme="dark"] .auth-theme-toggle:hover {
    color: #fff;
    background: #334554;
    border-color: #70879a;
}

html[data-theme="dark"] .role-pill,
html[data-theme="dark"] .settings-icon {
    color: #b9dcff;
    background: #20374a;
    border-color: #38566d;
}

html[data-theme="dark"] .button-primary {
    color: #071b2e;
    background: linear-gradient(135deg, #8cc8ef, #62d2c5);
    border-color: #8cc8ef;
    box-shadow: 0 7px 16px rgba(0, 0, 0, .20);
}

html[data-theme="dark"] .button-primary:hover {
    color: #071b2e;
    background: linear-gradient(135deg, #a9d9f7, #82e2d8);
    border-color: #a9d9f7;
}

html[data-theme="dark"] .button-secondary,
html[data-theme="dark"] .table-action {
    color: #c8e4f7;
    background: #1c2a35;
    border-color: #456075;
    box-shadow: none;
}

html[data-theme="dark"] .button-secondary:hover,
html[data-theme="dark"] .table-action:hover {
    color: #071b2e;
    background: #8cc8ef;
    border-color: #8cc8ef;
}

html[data-theme="dark"] .button-quiet {
    color: #b9dcff;
    background: transparent;
    border-color: transparent;
}

html[data-theme="dark"] .button-quiet:hover {
    color: #e6f4ff;
    background: rgba(101, 179, 239, .14);
}

html[data-theme="dark"] .button-danger {
    color: #fff;
    background: #a92d46;
    border-color: #c3445b;
}

html[data-theme="dark"] .button:disabled {
    color: #9dafbc;
    background: #141f29;
    border-color: #405464;
    box-shadow: none;
    opacity: 1;
}

html[data-theme="dark"] input,
html[data-theme="dark"] select,
html[data-theme="dark"] textarea,
html[data-theme="dark"] .profile-photo-controls input[type="file"] {
    color: var(--text);
    background-color: #131e28;
    border-color: #526878;
    caret-color: #edf4f8;
}

html[data-theme="dark"] input::placeholder,
html[data-theme="dark"] textarea::placeholder {
    color: #8fa0ad;
    opacity: 1;
}

html[data-theme="dark"] input:disabled,
html[data-theme="dark"] select:disabled,
html[data-theme="dark"] textarea:disabled,
html[data-theme="dark"] input[readonly],
html[data-theme="dark"] .locked-value {
    color: #9dafbc;
    background: #0d1822;
    border-color: #405464;
    opacity: 1;
}

html[data-theme="dark"] input:-webkit-autofill,
html[data-theme="dark"] input:-webkit-autofill:hover,
html[data-theme="dark"] input:-webkit-autofill:focus {
    -webkit-text-fill-color: #d3dde4;
    box-shadow: 0 0 0 1000px #131e28 inset;
    caret-color: #edf4f8;
}

html[data-theme="dark"] input[type="date"]::-webkit-calendar-picker-indicator {
    filter: invert(.82);
}

html[data-theme="dark"] .profile-photo-controls input[type="file"]::file-selector-button {
    color: #c8e4f7;
    background: #20374a;
}

html[data-theme="dark"] .checkbox-field,
html[data-theme="dark"] .binary-choice,
html[data-theme="dark"] .answer-choice,
html[data-theme="dark"] .criterion-notes,
html[data-theme="dark"] .request-note,
html[data-theme="dark"] .timeline blockquote,
html[data-theme="dark"] .command-centre-empty {
    color: var(--text);
    background: var(--surface-low);
    border-color: var(--border);
}

html[data-theme="dark"] .answer-choice:hover,
html[data-theme="dark"] .answer-choice:focus-within,
html[data-theme="dark"] .binary-choice:hover,
html[data-theme="dark"] .binary-choice:focus-within {
    background: #263543;
    border-color: #65b3ef;
}

html[data-theme="dark"] .filter-panel,
html[data-theme="dark"] .criteria-toolbar,
html[data-theme="dark"] .criteria-section > .panel-heading,
html[data-theme="dark"] .user-filter-bar,
html[data-theme="dark"] th {
    color: var(--ink);
    background: var(--surface-warm);
    border-color: #4d4d46;
}

html[data-theme="dark"] td,
html[data-theme="dark"] .criterion,
html[data-theme="dark"] .registration-card,
html[data-theme="dark"] .approval-form,
html[data-theme="dark"] .pagination-bar,
html[data-theme="dark"] .settings-heading,
html[data-theme="dark"] .profile-details > div,
html[data-theme="dark"] .profile-photo-remove-form {
    border-color: var(--border);
}

html[data-theme="dark"] tr:hover > td {
    background: #21313e;
}

html[data-theme="dark"] .row-discrepancy > td {
    background: rgba(110, 32, 49, .30);
}

html[data-theme="dark"] .row-discrepancy:hover > td {
    background: rgba(132, 40, 59, .42);
}

html[data-theme="dark"] .notice strong,
html[data-theme="dark"] .flash strong {
    color: inherit;
}

html[data-theme="dark"] .notice-error,
html[data-theme="dark"] .flash-error {
    color: #ffb0bd;
    background: #3c2029;
    border-color: #784052;
}

html[data-theme="dark"] .notice-warning,
html[data-theme="dark"] .flash-warning {
    color: #f2d188;
    background: #3b321f;
    border-color: #74643e;
}

html[data-theme="dark"] .flash-success {
    color: #9ae2b6;
    background: #1a382a;
    border-color: #376c4d;
}

html[data-theme="dark"] .flash-info {
    color: #c8e4f7;
    background: #173149;
    border-color: #385d79;
}

html[data-theme="dark"] .status-success,
html[data-theme="dark"] .answer-met,
html[data-theme="dark"] .answer-yes {
    color: #9ae2b6;
    background: #1a382a;
}

html[data-theme="dark"] .status-warning {
    color: #f2d188;
    background: #3b321f;
}

html[data-theme="dark"] .status-danger,
html[data-theme="dark"] .answer-missing_form,
html[data-theme="dark"] .answer-incomplete,
html[data-theme="dark"] .answer-unapproved_abbreviation,
html[data-theme="dark"] .answer-other,
html[data-theme="dark"] .answer-no {
    color: #ffb0bd;
    background: #3c2029;
}

html[data-theme="dark"] .status-info,
html[data-theme="dark"] .answer-not_answered,
html[data-theme="dark"] .answer-not_applicable {
    color: #b9dcff;
    background: #173149;
}

html[data-theme="dark"] .status-muted {
    color: #b1bfca;
    background: #202c38;
    border-color: #45596a;
}

html[data-theme="dark"] .main-menu-card,
html[data-theme="dark"] .main-menu-intro,
html[data-theme="dark"] .dashboard-hero,
html[data-theme="dark"] .command-centre-hero {
    box-shadow: none;
}

html[data-theme="dark"] .dashboard-scope,
html[data-theme="dark"] .command-centre-scope-hero,
html[data-theme="dark"] .main-menu-scope {
    color: var(--text);
    background: var(--surface-low);
    border-color: var(--border);
}

html[data-theme="dark"] .dashboard-priority-card,
html[data-theme="dark"] .command-centre-priority-card {
    box-shadow: 0 16px 32px rgba(0, 0, 0, .22);
}

html[data-theme="dark"] .command-centre-due-item,
html[data-theme="dark"] .command-centre-indicator-list a,
html[data-theme="dark"] .command-centre-queue-list a {
    color: var(--text);
    background: var(--surface-low);
    border-color: var(--border);
}

html[data-theme="dark"] .command-centre-due-item:hover,
html[data-theme="dark"] .command-centre-indicator-list a:hover,
html[data-theme="dark"] .command-centre-queue-list a:hover {
    background: #293947;
    border-color: #557188;
}

html[data-theme="dark"] .command-centre-due-item > span:first-child,
html[data-theme="dark"] .command-centre-indicator-list b,
html[data-theme="dark"] .command-centre-queue-list b {
    color: #f2d188;
}

html[data-theme="dark"] .command-centre-zero-state {
    color: var(--text);
    background: #193326;
    border-color: #376c4d;
}

html[data-theme="dark"] .command-centre-zero-state > .material-symbols-outlined {
    color: #9ae2b6;
    background: #22513b;
}

html[data-theme="dark"] .command-centre-steps li > span {
    color: #f2d188;
    background: #3b321f;
}

html[data-theme="dark"] .request-tab {
    color: #c0cad5;
    background: var(--surface-low);
    border-color: var(--border);
}

html[data-theme="dark"] .request-tab:hover {
    color: #fff;
    background: #2b3948;
}

html[data-theme="dark"] .request-tab.active,
html[data-theme="dark"] .pagination .pagination-current {
    color: #21140f;
    background: #ffd6c3;
    border-color: #ffd6c3;
}

html[data-theme="dark"] .criteria-tab.is-complete {
    color: #9ae2b6;
    background: #1a382a;
    border-color: #376c4d;
}

html[data-theme="dark"] .criteria-tab.is-complete:hover {
    color: #c5f2d6;
    background: #234a36;
    border-color: #4b8a64;
}

html[data-theme="dark"] .criteria-tab.is-complete.active {
    color: #071b2e;
    background: #9ae2b6;
    border-color: #9ae2b6;
}

html[data-theme="dark"] .criteria-tab.is-complete .criteria-tab-complete {
    color: #071b2e;
    background: #9ae2b6;
}

html[data-theme="dark"] .criteria-tab.is-complete.active .criteria-tab-complete {
    color: #9ae2b6;
    background: #071b2e;
}

html[data-theme="dark"] .criteria-tab-list.request-tabs {
    background: #18232e;
    border-color: #344655;
}

html[data-theme="dark"] .criteria-tabs .criteria-tab-panel {
    background: #18232e;
    border-color: #344655;
}

html[data-theme="dark"] .criteria-section > .panel-heading {
    color: var(--text);
    background: #202c38;
    border-color: #344655;
}

html[data-theme="dark"] .criterion {
    background: rgba(24, 35, 46, .82);
    border-color: #344655;
}

html[data-theme="dark"] .criterion:nth-child(even) {
    background: rgba(32, 44, 56, .82);
}

html[data-theme="dark"] .audit-view-answer-options .answer-choice.is-selected {
    color: #b9dcff;
    background: #173149;
    border-color: #4f7897;
    box-shadow: inset 0 0 0 1px rgba(140, 200, 239, .12);
}

html[data-theme="dark"] .audit-view-answer-options .answer-choice.is-selected.is-noncompliant {
    color: #ffb4c2;
    background: #3a1e2a;
    border-color: #754052;
    box-shadow: inset 0 0 0 1px rgba(255, 180, 194, .10);
}

html[data-theme="dark"] .audit-view-answer-options .answer-choice:hover {
    background: var(--surface-low);
    border-color: var(--border);
}

html[data-theme="dark"] .audit-view-answer-options .answer-choice.is-selected:hover {
    background: #173149;
    border-color: #4f7897;
}

html[data-theme="dark"] .audit-view-answer-options .answer-choice.is-selected.is-noncompliant:hover {
    background: #3a1e2a;
    border-color: #754052;
}

html[data-theme="dark"] .criteria-section-progress progress,
html[data-theme="dark"] .criteria-section-progress progress::-webkit-progress-bar {
    background: #405464;
}

html[data-theme="dark"] .criteria-section-progress progress::-webkit-progress-value,
html[data-theme="dark"] .criteria-section-progress progress::-moz-progress-bar {
    background: #8cc8ef;
}

html[data-theme="dark"] .pagination a {
    color: #b9dcff;
    background: var(--surface-low);
    border-color: var(--border);
}

html[data-theme="dark"] .pagination a:hover {
    color: #071b2e;
    background: #8cc8ef;
    border-color: #8cc8ef;
}

html[data-theme="dark"] .pagination .disabled {
    color: #9aaab6;
    background: #101b25;
    border-color: #2d404f;
}

html[data-theme="dark"] .audit-records-filter-panel {
    color: var(--text);
    background: #2d3030;
    border-color: #4a4d4d;
}

html[data-theme="dark"] .audit-records-filter-body,
html[data-theme="dark"] .audit-records-date-filters {
    border-color: #4a4d4d;
}

html[data-theme="dark"] .audit-records-filter-summary:hover {
    background: #353939;
}

html[data-theme="dark"] .audit-records-filter-chevron {
    color: #b9dcff;
}

html[data-theme="dark"] .audit-records-filter-label .ui-icon {
    color: #b9dcff;
}

html[data-theme="dark"] .audit-response-records-panel {
    background: #18232e;
    border-color: #344655;
}

html[data-theme="dark"] .audit-response-records-table tbody tr:hover {
    background: rgba(86, 169, 233, .08);
}

html[data-theme="dark"] .audit-record-chapter {
    color: #b9dcff;
    background: #173149;
}

html[data-theme="dark"] .audit-record-id {
    color: var(--ink);
}

html[data-theme="dark"] .audit-record-view-action {
    color: #b9dcff;
    background: #173149;
    border-color: #385d79;
}

html[data-theme="dark"] .audit-record-view-action:hover {
    color: #071b2e;
    background: #8cc8ef;
    border-color: #8cc8ef;
}

html[data-theme="dark"] .audit-record-delete-action {
    color: #ffb4c2;
    background: #3a1e2a;
    border-color: #754052;
}

html[data-theme="dark"] .audit-record-delete-action:hover {
    color: #fff;
    background: #b83a54;
    border-color: #d45a70;
}

html[data-theme="dark"] .sample-size-management-panel,
html[data-theme="dark"] .sample-size-dialog {
    color: var(--text);
    background: var(--surface);
    border-color: var(--border);
}

html[data-theme="dark"] .sample-size-heading,
html[data-theme="dark"] .sample-size-tabs,
html[data-theme="dark"] .sample-size-filter-bar {
    border-color: var(--border);
}

/* Audit performance dashboard. Centre-level aggregates deliberately remain
   separate from the stricter record-level access rules used by audit pages. */
.sr-only { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; border: 0 !important; }
.performance-hero { position: relative; display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(250px, .58fr); gap: 30px; align-items: stretch; padding: clamp(28px, 4vw, 42px); margin-bottom: 20px; overflow: hidden; background: linear-gradient(118deg, rgba(255, 255, 255, .97) 0%, rgba(241, 249, 251, .93) 64%, rgba(235, 244, 247, .88) 100%); border: 1px solid rgba(var(--primary-rgb), .15); border-radius: 22px; box-shadow: var(--shadow); }
.performance-hero::after { position: absolute; right: -72px; bottom: -100px; width: 280px; height: 280px; content: ""; background: radial-gradient(circle, rgba(17, 143, 136, .16), rgba(17, 143, 136, 0) 68%); pointer-events: none; }
.performance-hero-copy { position: relative; z-index: 1; align-self: center; }
.performance-hero-copy .eyebrow { color: var(--teal-dark); }
.performance-hero-copy h2 { max-width: 780px; margin: 0; color: var(--ink); font-size: clamp(25px, 3vw, 36px); font-weight: 720; letter-spacing: -.04em; line-height: 1.14; }
.performance-hero-copy p:not(.eyebrow) { max-width: 720px; margin: 12px 0 0; color: var(--muted); font-size: 13px; font-weight: 550; line-height: 1.65; }
.performance-scope-card { position: relative; z-index: 1; display: flex; gap: 13px; align-items: center; min-height: 120px; padding: 19px; color: var(--text); background: rgba(255, 255, 255, .74); border: 1px solid rgba(var(--primary-rgb), .16); border-radius: 17px; box-shadow: 0 12px 30px rgba(11, 38, 63, .07); }
.performance-scope-icon { display: grid; flex: 0 0 auto; width: 42px; height: 42px; place-items: center; color: var(--primary-dark); background: var(--primary-soft); border-radius: 12px; font-size: 22px; }
.performance-scope-card div { min-width: 0; }
.performance-scope-card span, .performance-scope-card strong, .performance-scope-card small { display: block; }
.performance-scope-card span { color: var(--muted); font-size: 9px; font-weight: 850; letter-spacing: .1em; text-transform: uppercase; }
.performance-scope-card strong { margin-top: 4px; color: var(--ink); font-size: 13px; font-weight: 800; line-height: 1.35; }
.performance-scope-card small { margin-top: 5px; color: var(--muted); font-family: var(--font-mono); font-size: 9px; font-weight: 650; }
.performance-filter-panel { margin-bottom: 18px; }
.performance-filter-form { padding: 18px 22px 21px; }
.performance-filter-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px 16px; align-items: end; }
.performance-filter-form .audit-records-filter-actions { padding: 18px 0 0; border: 0; }
.performance-tabs { display: flex; gap: 8px; padding: 7px; margin-bottom: 20px; overflow-x: auto; background: color-mix(in srgb, var(--surface) 94%, transparent); border: 1px solid var(--border); border-radius: 14px; box-shadow: var(--shadow-soft); scrollbar-width: thin; }
.performance-tab { display: inline-flex; flex: 1 0 auto; gap: 8px; align-items: center; justify-content: center; min-height: 42px; padding: 9px 14px; color: var(--muted); border-radius: 10px; font-size: 10px; font-weight: 800; text-decoration: none; white-space: nowrap; transition: color 180ms cubic-bezier(.2, .75, .3, 1), background-color 180ms cubic-bezier(.2, .75, .3, 1), transform 180ms cubic-bezier(.2, .75, .3, 1); }
.performance-tab:hover { color: var(--primary-dark); background: var(--primary-soft); text-decoration: none; transform: translateY(-1px); }
.performance-tab.active { color: #fff; background: var(--ink-deep); box-shadow: 0 8px 20px rgba(11, 38, 63, .15); }
.performance-tab .ui-icon { font-size: 18px; }
.performance-tab-panel[hidden] { display: none; }
.performance-kpi-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 13px; margin-bottom: 20px; }
.performance-kpi { position: relative; display: flex; gap: 12px; align-items: flex-start; min-width: 0; min-height: 122px; padding: 18px; overflow: hidden; background: color-mix(in srgb, var(--surface) 93%, transparent); border: 1px solid var(--border); border-radius: 16px; box-shadow: var(--shadow-soft); }
.performance-kpi::after { position: absolute; right: -24px; bottom: -28px; width: 82px; height: 82px; content: ""; background: radial-gradient(circle, rgba(var(--primary-rgb), .09), transparent 68%); pointer-events: none; }
.performance-kpi-lead { grid-column: span 2; color: #fff; background: linear-gradient(135deg, #0b263f, #134d61 68%, #17686e); border-color: #174d60; box-shadow: 0 16px 34px rgba(8, 36, 55, .18); }
.performance-kpi-lead::after { width: 150px; height: 150px; background: radial-gradient(circle, rgba(99, 214, 196, .23), transparent 68%); }
.performance-kpi-icon { display: grid; flex: 0 0 auto; width: 36px; height: 36px; place-items: center; color: var(--primary-dark); background: var(--primary-soft); border-radius: 11px; font-size: 20px; }
.performance-kpi.is-success .performance-kpi-icon { color: var(--success); background: var(--success-soft); }
.performance-kpi.is-warning .performance-kpi-icon { color: var(--warning); background: var(--warning-soft); }
.performance-kpi.is-danger .performance-kpi-icon, .performance-kpi.is-finding .performance-kpi-icon { color: var(--danger); background: var(--danger-soft); }
.performance-kpi.is-target .performance-kpi-icon { color: var(--teal-dark); background: rgba(17, 143, 136, .10); }
.performance-kpi-lead .performance-kpi-icon { color: #fff; background: rgba(255, 255, 255, .14); }
.performance-kpi > div { position: relative; z-index: 1; min-width: 0; }
.performance-kpi > div > span { display: block; color: var(--muted); font-size: 8px; font-weight: 850; letter-spacing: .09em; line-height: 1.35; text-transform: uppercase; }
.performance-kpi strong { display: block; margin-top: 5px; color: var(--ink); font-size: clamp(22px, 2vw, 29px); font-weight: 750; letter-spacing: -.04em; line-height: 1; }
.performance-kpi strong.text-value { font-size: 14px; line-height: 1.25; }
.performance-kpi small { display: block; margin-top: 7px; color: var(--muted); font-size: 9px; font-weight: 600; line-height: 1.45; }
.performance-kpi-lead span, .performance-kpi-lead small { color: rgba(255, 255, 255, .72); }
.performance-kpi-lead strong { color: #fff; }
.performance-chart-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(340px, .8fr); gap: 20px; margin-bottom: 20px; }
.performance-chart-card, .performance-breakdown-card { min-width: 0; min-height: 408px; margin: 0; padding: 22px; }
.performance-section-heading { display: flex; gap: 16px; align-items: flex-start; justify-content: space-between; margin-bottom: 18px; }
.performance-section-heading > div { min-width: 0; }
.performance-section-heading .eyebrow { color: var(--primary-dark); }
.performance-section-heading h3 { margin: 0; color: var(--ink); font-size: 17px; font-weight: 750; letter-spacing: -.025em; line-height: 1.25; }
.performance-section-heading p:not(.eyebrow) { max-width: 650px; margin: 5px 0 0; color: var(--muted); font-size: 10px; font-weight: 600; line-height: 1.5; }
.performance-chart-unit, .performance-scope-note { flex: 0 0 auto; padding: 6px 9px; color: var(--primary-dark); background: var(--primary-soft); border-radius: 999px; font-size: 9px; font-weight: 800; }
.performance-info-button { display: inline-grid; flex: 0 0 auto; width: 36px; min-height: 36px; padding: 0; place-items: center; }
.performance-info-button .ui-icon { font-size: 19px; }
.performance-chart { display: grid; min-height: 270px; color: var(--muted); place-items: center; }
.performance-chart svg { display: block; width: 100%; height: 270px; overflow: visible; }
.performance-chart-horizontal { min-height: 300px; overflow-y: auto; }
.performance-chart-horizontal svg { height: auto; min-height: 270px; }
.performance-chart-grid-line { stroke: var(--border); stroke-width: 1; }
.performance-chart-axis-label, .performance-chart-category-label, .performance-chart-value-label { fill: var(--muted); font-family: var(--font-sans); font-size: 10px; font-weight: 650; }
.performance-chart-category-label { fill: var(--text); font-size: 11px; font-weight: 700; }
.performance-chart-value-label { fill: var(--ink); font-weight: 800; }
.performance-chart-fill-success { fill: var(--success); }
.performance-chart-fill-warning { fill: var(--warning); }
.performance-chart-fill-danger { fill: var(--danger); }
.performance-chart-fill-accent { fill: var(--accent); }
.performance-chart-track { fill: var(--surface-low); stroke: var(--border); stroke-width: 1; }
.performance-chart-line { fill: none; stroke: var(--teal); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; }
.performance-chart-point { fill: var(--surface); stroke: var(--teal); stroke-width: 3; }
.performance-chart-legend { display: flex; flex-wrap: wrap; gap: 13px; margin-top: 9px; color: var(--muted); font-size: 9px; font-weight: 750; }
.performance-chart-legend span { display: inline-flex; gap: 6px; align-items: center; }
.performance-chart-legend span::before { width: 8px; height: 8px; content: ""; background: currentColor; border-radius: 2px; }
.performance-chart-legend .is-success { color: var(--success); }
.performance-chart-legend .is-warning { color: var(--warning); }
.performance-chart-legend .is-danger { color: var(--danger); }
.performance-overview-lower { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(330px, .7fr); gap: 20px; margin-bottom: 20px; }
.performance-overview-lower .command-centre-priority-card, .performance-overview-lower .panel { min-height: 190px; margin: 0; }
.performance-queue-card { padding: 21px; }
.performance-monthly-table-panel, .performance-citations-panel, .performance-sample-table-panel { padding: 22px; }
.performance-table { width: 100%; min-width: 720px; border-collapse: separate; border-spacing: 0; }
.performance-table th, .performance-table td { padding: 11px 12px; vertical-align: middle; border-bottom: 1px solid var(--border); font-size: 10px; text-align: center; }
.performance-table th { color: var(--ink); background: var(--surface-warm); font-size: 9px; font-weight: 850; letter-spacing: .04em; text-transform: uppercase; }
.performance-table th:first-child { border-radius: 9px 0 0 0; }
.performance-table th:last-child { border-radius: 0 9px 0 0; }
.performance-table th:first-child, .performance-table td:first-child { text-align: left; }
.performance-table td { color: var(--text); font-weight: 600; }
.performance-table tbody tr:last-child td { border-bottom: 0; }
.performance-table tbody tr:hover td { background: color-mix(in srgb, var(--primary-soft) 55%, transparent); }
.performance-table.compact { min-width: 500px; }
.performance-table-note { margin: 15px 0 0; color: var(--muted); font-size: 10px; font-weight: 600; }
.performance-rate { display: inline-flex; min-height: 26px; align-items: center; padding: 4px 8px; color: var(--text); background: var(--surface-low); border-radius: 999px; font-size: 9px; font-weight: 800; }
.performance-rate.is-strong { color: var(--success); background: var(--success-soft); }
.performance-mini-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 13px; margin-bottom: 20px; }
.performance-mini-kpis article { display: flex; gap: 11px; align-items: center; min-height: 88px; padding: 15px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; box-shadow: var(--shadow-soft); }
.performance-mini-kpis article > span { display: grid; flex: 0 0 auto; width: 33px; height: 33px; place-items: center; border-radius: 10px; }
.performance-mini-kpis article > span .ui-icon { font-size: 19px; }
.performance-mini-kpis article > span.is-success { color: var(--success); background: var(--success-soft); }
.performance-mini-kpis article > span.is-danger { color: var(--danger); background: var(--danger-soft); }
.performance-mini-kpis article > span.is-warning { color: var(--warning); background: var(--warning-soft); }
.performance-mini-kpis article > span.is-info, .performance-mini-kpis article > span.is-target { color: var(--primary-dark); background: var(--primary-soft); }
.performance-mini-kpis small, .performance-mini-kpis strong { display: block; }
.performance-mini-kpis small { color: var(--muted); font-size: 8px; font-weight: 850; letter-spacing: .06em; text-transform: uppercase; }
.performance-mini-kpis strong { margin-top: 3px; color: var(--ink); font-size: 22px; font-weight: 750; letter-spacing: -.03em; line-height: 1; }
.performance-breakdown-list { display: grid; gap: 13px; }
.performance-breakdown-list > div { display: grid; grid-template-columns: minmax(130px, .85fr) minmax(110px, 1fr) auto; gap: 12px; align-items: center; }
.performance-breakdown-list span strong, .performance-breakdown-list span small { display: block; }
.performance-breakdown-list span strong { color: var(--ink); font-size: 10px; font-weight: 800; }
.performance-breakdown-list span small { margin-top: 2px; color: var(--muted); font-size: 8px; font-weight: 650; }
.performance-breakdown-list progress, .performance-progress progress { width: 100%; height: 8px; overflow: hidden; appearance: none; background: var(--surface-low); border: 0; border-radius: 999px; }
.performance-breakdown-list progress::-webkit-progress-bar, .performance-progress progress::-webkit-progress-bar { background: var(--surface-low); border-radius: 999px; }
.performance-breakdown-list progress::-webkit-progress-value, .performance-progress progress::-webkit-progress-value { background: linear-gradient(90deg, var(--primary), var(--teal)); border-radius: 999px; }
.performance-breakdown-list progress::-moz-progress-bar, .performance-progress progress::-moz-progress-bar { background: linear-gradient(90deg, var(--primary), var(--teal)); border-radius: 999px; }
.performance-breakdown-list b { min-width: 46px; color: var(--ink); font-family: var(--font-mono); font-size: 10px; text-align: right; }
.performance-findings-table { min-width: 980px; }
.performance-findings-table td:nth-child(3) { max-width: 360px; text-align: left; }
.performance-compliance-tables { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.performance-compliance-tables .panel { min-width: 0; margin: 0; padding: 22px; }
.performance-review-strip { display: grid; grid-template-columns: minmax(0, 1.45fr) repeat(2, minmax(190px, .55fr)); gap: 1px; margin-bottom: 20px; overflow: hidden; color: rgba(255, 255, 255, .78); background: #223444; border: 1px solid #2f4b5c; border-radius: 18px; box-shadow: 0 16px 36px rgba(7, 27, 46, .17); }
.performance-review-strip > div { min-height: 125px; padding: 22px; background: linear-gradient(135deg, #132b3d, #1b4250); }
.performance-review-strip > div:not(.performance-review-primary) { display: grid; align-content: center; }
.performance-review-primary { display: flex; gap: 15px; align-items: center; }
.performance-review-primary > .ui-icon { display: grid; flex: 0 0 auto; width: 43px; height: 43px; color: #fff; background: rgba(255, 255, 255, .12); border-radius: 12px; font-size: 23px; place-items: center; }
.performance-review-strip small { color: rgba(255, 255, 255, .62); font-size: 8px; font-weight: 850; letter-spacing: .09em; text-transform: uppercase; }
.performance-review-strip strong { display: block; margin-top: 5px; color: #fff; font-size: 26px; font-weight: 750; letter-spacing: -.035em; line-height: 1; }
.performance-review-strip strong.text-value { font-size: 13px; line-height: 1.4; }
.performance-review-strip p { max-width: 540px; margin: 7px 0 0; color: rgba(255, 255, 255, .72); font-size: 10px; font-weight: 550; line-height: 1.5; }
.performance-productivity-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-bottom: 20px; }
.performance-productivity-grid .panel { min-width: 0; margin: 0; padding: 22px; }
.productivity-table { min-width: 720px; }
.productivity-table td:first-child { min-width: 150px; }
.performance-sample-hero { display: flex; gap: 20px; align-items: center; justify-content: space-between; padding: 24px 26px; margin-bottom: 16px; background: linear-gradient(120deg, var(--surface), color-mix(in srgb, var(--primary-soft) 70%, var(--surface))); border: 1px solid var(--border); border-radius: 18px; box-shadow: var(--shadow-soft); }
.performance-sample-hero h3 { margin: 0; color: var(--ink); font-size: 20px; font-weight: 750; letter-spacing: -.025em; }
.performance-sample-hero p:not(.eyebrow) { max-width: 720px; margin: 7px 0 0; color: var(--muted); font-size: 11px; font-weight: 600; }
.performance-sample-hero .button { flex: 0 0 auto; }
.performance-sample-table { min-width: 1040px; }
.performance-progress { display: grid; gap: 6px; min-width: 130px; }
.performance-progress span { display: flex; gap: 8px; align-items: baseline; justify-content: space-between; }
.performance-progress strong { color: var(--ink); font-size: 10px; }
.performance-progress small { color: var(--muted); font-size: 8px; }
.performance-methodology-dialog { width: min(650px, calc(100vw - 28px)); max-height: min(720px, calc(100dvh - 28px)); padding: 0; overflow: hidden; color: var(--text); background: var(--surface); border: 1px solid var(--border); border-radius: 19px; box-shadow: 0 28px 70px rgba(6, 27, 46, .28); }
.performance-methodology-dialog::backdrop { background: rgba(4, 15, 24, .66); }
.performance-methodology-dialog .dialog-header { display: flex; gap: 18px; align-items: flex-start; justify-content: space-between; padding: 23px 24px 18px; border-bottom: 1px solid var(--border); }
.performance-methodology-dialog .dialog-header h2 { margin: 0; font-size: 18px; }
.performance-methodology-dialog .dialog-header .icon-button { display: inline-grid; flex: 0 0 auto; width: 38px; padding: 0; place-items: center; }
.performance-methodology-dialog .dialog-body { display: grid; gap: 13px; padding: 22px 24px; overflow-y: auto; overscroll-behavior: contain; }
.performance-methodology-dialog .dialog-body p { margin: 0; color: var(--text); font-size: 12px; font-weight: 550; line-height: 1.65; }
.performance-methodology-dialog .dialog-actions { display: flex; justify-content: flex-end; padding: 15px 24px 20px; border-top: 1px solid var(--border); }
body.dialog-open { overflow: hidden; }

html[data-theme="dark"] .performance-hero { background: linear-gradient(118deg, #142635 0%, #173340 62%, #163b40 100%); border-color: #355365; box-shadow: none; }
html[data-theme="dark"] .performance-hero::after { background: radial-gradient(circle, rgba(85, 198, 182, .17), transparent 68%); }
html[data-theme="dark"] .performance-scope-card { background: rgba(10, 28, 40, .72); border-color: #3a5869; box-shadow: none; }
html[data-theme="dark"] .performance-tabs { background: #102230; border-color: #294151; box-shadow: none; }
html[data-theme="dark"] .performance-tab.active { color: #18222e; background: #d7edf8; box-shadow: none; }
html[data-theme="dark"] .performance-kpi, html[data-theme="dark"] .performance-mini-kpis article { background: #102230; border-color: #294151; box-shadow: none; }
html[data-theme="dark"] .performance-kpi-lead { background: linear-gradient(135deg, #081f31, #124251 68%, #155c60); border-color: #2a5b68; }
html[data-theme="dark"] .performance-kpi.is-target .performance-kpi-icon { color: #8fe4d6; background: rgba(85, 198, 182, .14); }
html[data-theme="dark"] .performance-chart-track { fill: #0c1c28; stroke: #294151; }
html[data-theme="dark"] .performance-chart-point { fill: #102230; }
html[data-theme="dark"] .performance-table th { color: var(--ink); background: #2b2923; }
html[data-theme="dark"] .performance-table tbody tr:hover td { background: rgba(65, 130, 169, .12); }
html[data-theme="dark"] .performance-sample-hero { background: linear-gradient(120deg, #102230, #123244); border-color: #294151; box-shadow: none; }
html[data-theme="dark"] .performance-methodology-dialog { background: #102230; border-color: #3a5365; }

@media (max-width: 1240px) {
    .performance-filter-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .performance-kpi-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .performance-kpi-lead { grid-column: span 2; }
    .performance-chart-grid { grid-template-columns: 1fr 1fr; }
    .performance-overview-lower { grid-template-columns: 1fr; }
}

@media (max-width: 1020px) {
    .performance-hero { grid-template-columns: 1fr; gap: 18px; }
    .performance-scope-card { min-height: 0; }
    .performance-filter-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .performance-kpi-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .performance-chart-grid, .performance-compliance-tables, .performance-productivity-grid { grid-template-columns: 1fr; }
    .performance-chart-card, .performance-breakdown-card { min-height: auto; }
    .performance-review-strip { grid-template-columns: 1fr 1fr; }
    .performance-review-primary { grid-column: 1 / -1; }
}

@media (max-width: 760px) {
    .performance-hero { padding: 24px 20px; }
    .performance-hero-copy h2 { font-size: 26px; }
    .performance-filter-form { padding-right: 18px; padding-left: 18px; }
    .performance-filter-grid, .performance-kpi-grid, .performance-mini-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .performance-kpi-lead { grid-column: 1 / -1; }
    .performance-tabs { justify-content: flex-start; }
    .performance-tab { flex: 0 0 auto; min-height: 44px; }
    .performance-chart-card, .performance-breakdown-card, .performance-monthly-table-panel, .performance-citations-panel, .performance-sample-table-panel { padding: 19px 17px; }
    .performance-overview-lower .command-centre-priority-card { min-height: 0; }
    .performance-sample-hero { align-items: flex-start; flex-direction: column; padding: 21px 19px; }
    .performance-sample-hero .button { width: 100%; }
}

@media (max-width: 520px) {
    .performance-filter-grid, .performance-kpi-grid, .performance-mini-kpis, .performance-review-strip { grid-template-columns: 1fr; }
    .performance-kpi-lead, .performance-review-primary { grid-column: auto; }
    .performance-kpi { min-height: 104px; }
    .performance-chart { min-height: 235px; overflow-x: auto; justify-content: start; }
    .performance-chart svg { min-width: 600px; height: 235px; }
    .performance-chart-horizontal svg { min-width: 650px; }
    .performance-breakdown-list > div { grid-template-columns: minmax(0, 1fr) auto; }
    .performance-breakdown-list progress { grid-column: 1 / -1; grid-row: 2; }
    .performance-section-heading { display: block; }
    .performance-section-heading > .performance-chart-unit, .performance-section-heading > .performance-info-button, .performance-section-heading > .performance-scope-note { margin-top: 10px; }
    .performance-methodology-dialog .dialog-header, .performance-methodology-dialog .dialog-body, .performance-methodology-dialog .dialog-actions { padding-right: 18px; padding-left: 18px; }
    .performance-methodology-dialog .dialog-actions .button { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
    .performance-tab { transition: none; }
}

html[data-theme="dark"] .sample-size-filter-bar {
    color: var(--text);
    background: #2d3030;
}

html[data-theme="dark"] .sample-size-locked-scope > div {
    color: var(--text);
    background: var(--surface-low);
    border-color: var(--border);
}

html[data-theme="dark"] .sample-size-target-value,
html[data-theme="dark"] .sample-size-locked-scope strong {
    color: var(--ink);
}
html[data-theme="dark"] .notification-page-note { color: var(--muted); }

html[data-theme="dark"] .profile-photo-editor {
    color: var(--text);
    background: var(--surface-low);
    border-color: var(--border);
}

html[data-theme="dark"] .profile-photo-preview {
    border-color: #344655;
    box-shadow: 0 10px 22px rgba(0, 0, 0, .22);
}

html[data-theme="dark"] .notification-status-list > div,
html[data-theme="dark"] .notification-test-form {
    border-color: var(--border);
}

html[data-theme="dark"] .notification-queue-counts > div,
html[data-theme="dark"] .notification-choice {
    color: var(--text);
    background: var(--surface-low);
    border-color: var(--border);
}

html[data-theme="dark"] .notification-choice:hover,
html[data-theme="dark"] .notification-choice:focus-within {
    background: #263543;
    border-color: #65b3ef;
}

html[data-theme="dark"] .notification-worker-note {
    color: var(--text);
    background: #173149;
    border-color: #385d79;
}

html[data-theme="dark"] .notification-worker-note code {
    color: #b9dcff;
}

html[data-theme="dark"] .profile-avatar-image,
html[data-theme="dark"] .user-avatar-photo,
html[data-theme="dark"] .user-listing-avatar,
html[data-theme="dark"] .sidebar-brand-logo {
    background: #fff;
    border-color: #617485;
}

html[data-theme="dark"] hr {
    border-color: var(--border);
}

html[data-theme="dark"] ::-webkit-scrollbar-track {
    background: #101b25;
}

html[data-theme="dark"] ::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #a76148, #8f7140);
    border-color: #101720;
}

/* Audit worklists and sample-size progress reporting */
.summary-card-icon {
    display: inline-grid !important;
    flex: 0 0 auto;
    width: 36px;
    height: 36px;
    color: var(--primary-dark) !important;
    background: var(--primary-soft);
    border: 1px solid color-mix(in srgb, var(--primary) 22%, var(--border));
    border-radius: 11px;
    font-size: 20px !important;
    font-weight: 400 !important;
    line-height: 1 !important;
    letter-spacing: normal !important;
    text-transform: none !important;
    place-items: center;
}
.summary-card-icon.is-success { color: var(--success) !important; background: var(--success-soft); border-color: color-mix(in srgb, var(--success) 28%, var(--border)); }
.summary-card-icon.is-warning { color: var(--warning) !important; background: var(--warning-soft); border-color: color-mix(in srgb, var(--warning) 28%, var(--border)); }
.summary-card-icon.is-danger { color: var(--danger) !important; background: var(--danger-soft); border-color: color-mix(in srgb, var(--danger) 28%, var(--border)); }
.summary-card-icon.is-muted { color: var(--muted) !important; background: var(--surface-low); border-color: var(--border); }
.detail-strip > div { position: relative; padding-right: 56px; }
.detail-strip > div > .summary-card-icon,
.sample-progress-detail-summary > div > .summary-card-icon { position: absolute; top: 14px; right: 13px; width: 30px; height: 30px; border-radius: 9px; font-size: 17px !important; }
.notification-queue-counts > div { display: flex; flex-direction: column; align-items: center; }
.notification-queue-counts > div > .summary-card-icon { width: 30px; height: 30px; margin: 0 auto 7px; border-radius: 9px; font-size: 17px !important; }
.audit-list-table { min-width: 1060px; }
.audit-list-table th, .audit-list-table td { padding: 12px 13px; vertical-align: middle; }
.audit-list-table th:first-child, .audit-list-table td:first-child { padding-left: 22px; text-align: center; }
.audit-list-table th:last-child, .audit-list-table td:last-child { padding-right: 22px; }
.audit-list-table tbody tr { transition: background-color 180ms cubic-bezier(.2,.75,.3,1); }
.audit-list-table tbody tr:hover { background: #f5f9fc; }
.sample-progress-filter-form { display: grid; gap: 16px; }
.sample-progress-filter-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 13px 16px; align-items: start; }
.sample-progress-filter-grid [data-period-field][hidden],
.sample-progress-filter-grid [data-progress-period-field][hidden] { display: none; }
.sample-progress-summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 24px; }
.sample-progress-kpi {
    position: relative;
    min-width: 0;
    min-height: 116px;
    padding: 18px 68px 18px 19px;
    background: rgba(255, 255, 255, .9);
    border: 1px solid rgba(196, 211, 224, .92);
    border-top: 3px solid var(--primary);
    border-radius: 15px;
    box-shadow: 0 10px 25px rgba(11, 38, 63, .06);
}
.sample-progress-kpi > .summary-card-icon { position: absolute; top: 16px; right: 16px; }
.sample-progress-kpi.is-warning { border-top-color: var(--warning); }
.sample-progress-kpi.is-success { border-top-color: var(--success); }
.sample-progress-kpi.is-info { border-top-color: var(--primary); }
.sample-progress-kpi.is-warning > .summary-card-icon { color: var(--warning) !important; background: var(--warning-soft); border-color: color-mix(in srgb, var(--warning) 28%, var(--border)); }
.sample-progress-kpi.is-success > .summary-card-icon { color: var(--success) !important; background: var(--success-soft); border-color: color-mix(in srgb, var(--success) 28%, var(--border)); }
.sample-progress-kpi > span:not(.summary-card-icon) { display: block; color: var(--muted); font-size: 9px; font-weight: 800; letter-spacing: .065em; text-transform: uppercase; }
.sample-progress-kpi > strong { display: block; margin: 7px 0 6px; color: var(--ink); font-size: 28px; font-weight: 750; letter-spacing: -.035em; line-height: 1; }
.sample-progress-kpi > strong.text-value { font-size: 18px; line-height: 1.2; }
.sample-progress-kpi > small { display: block; color: var(--muted); font-size: 10px; font-weight: 550; line-height: 1.45; }
.sample-progress-panel .panel-heading { align-items: center; }
.sample-progress-scope-note { color: var(--muted); font-size: 10px; font-weight: 700; }
.sample-progress-table { min-width: 1280px; }
.sample-progress-table th, .sample-progress-table td { padding: 12px 13px; vertical-align: middle; }
.sample-progress-table th:first-child, .sample-progress-table td:first-child { padding-left: 22px; text-align: center; }
.sample-progress-table th:last-child, .sample-progress-table td:last-child { padding-right: 22px; }
.sample-progress-table tbody tr { transition: background-color 180ms cubic-bezier(.2,.75,.3,1); }
.sample-progress-table tbody tr:hover { background: #f5f9fc; }
.sample-progress-number { text-align: center; }
.sample-progress-number > strong { color: var(--ink); font-size: 14px; }
.sample-progress-month { white-space: nowrap; }
.sample-progress-meter { min-width: 154px; }
.sample-progress-meter > div { display: flex; gap: 8px; align-items: baseline; justify-content: space-between; }
.sample-progress-meter strong { color: var(--ink); font-size: 12px; }
.sample-progress-meter span { color: var(--muted); font-size: 8px; font-weight: 650; white-space: nowrap; }
.sample-progress-meter progress { display: block; width: 100%; height: 7px; margin-top: 7px; overflow: hidden; appearance: none; background: var(--border); border: 0; border-radius: 999px; }
.sample-progress-meter progress::-webkit-progress-bar { background: var(--border); border-radius: 999px; }
.sample-progress-meter progress::-webkit-progress-value { background: var(--success); border-radius: 999px; }
.sample-progress-meter progress::-moz-progress-bar { background: var(--success); border-radius: 999px; }
.sample-progress-methodology { margin-top: 20px; padding: 0; overflow: hidden; }
.sample-progress-methodology > summary { display: flex; align-items: center; justify-content: space-between; padding: 17px 21px; cursor: pointer; list-style: none; }
.sample-progress-methodology > summary::-webkit-details-marker { display: none; }
.sample-progress-methodology > summary::marker { content: ""; }
.sample-progress-methodology > summary > span { display: inline-flex; gap: 9px; align-items: center; }
.sample-progress-methodology > summary .ui-icon { color: var(--primary-dark); font-size: 20px; }
.sample-progress-methodology-chevron { transition: transform 220ms cubic-bezier(.2,.75,.3,1); }
.sample-progress-methodology[open] .sample-progress-methodology-chevron { transform: rotate(180deg); }
.sample-progress-methodology > div { padding: 0 21px 19px; color: var(--muted); font-size: 11px; font-weight: 550; line-height: 1.65; }
.sample-progress-methodology > div p { margin: 0 0 8px; }
.sample-progress-methodology > div p:last-child { margin-bottom: 0; }
.sample-progress-detail-summary { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 1px; margin-bottom: 24px; overflow: hidden; background: var(--border); border: 1px solid var(--border); border-radius: 16px; box-shadow: var(--shadow-soft); }
.sample-progress-detail-summary > div { position: relative; min-width: 0; min-height: 94px; padding: 16px 54px 16px 16px; background: rgba(255, 255, 255, .94); }
.sample-progress-detail-summary span:not(.status-badge):not(.summary-card-icon), .sample-progress-detail-summary strong, .sample-progress-detail-summary small { display: block; }
.sample-progress-detail-summary > div > span:not(.summary-card-icon) { color: var(--muted); font-size: 8px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.sample-progress-detail-summary > div > strong { margin-top: 7px; color: var(--ink); font-size: 15px; font-weight: 750; line-height: 1.25; }
.sample-progress-detail-summary > div > small { margin-top: 5px; color: var(--muted); font-size: 9px; line-height: 1.4; }
.sample-progress-detail-table { min-width: 1180px; }
.sample-progress-detail-table th, .sample-progress-detail-table td { padding: 12px 13px; vertical-align: middle; }
.sample-progress-detail-table th:first-child, .sample-progress-detail-table td:first-child { padding-left: 22px; text-align: center; }
.sample-progress-detail-table th:last-child, .sample-progress-detail-table td:last-child { padding-right: 22px; }
.sample-progress-restricted-action { display: inline-grid; width: 34px; height: 34px; place-items: center; color: var(--muted); background: var(--surface-low); border: 1px solid var(--border); border-radius: 9px; }
.sample-progress-restricted-action .ui-icon { font-size: 17px; }

html[data-theme="dark"] .sample-progress-kpi,
html[data-theme="dark"] .sample-progress-detail-summary > div { background: #18232e; border-color: #344655; box-shadow: none; }
html[data-theme="dark"] .sample-progress-detail-summary { background: #344655; border-color: #344655; box-shadow: none; }
html[data-theme="dark"] .summary-card-icon { color: #b9dcff !important; background: #173149; border-color: #385d79; }
html[data-theme="dark"] .summary-card-icon.is-success,
html[data-theme="dark"] .sample-progress-kpi.is-success > .summary-card-icon { color: #7be0b7 !important; background: #17372d; border-color: #315d4e; }
html[data-theme="dark"] .summary-card-icon.is-warning,
html[data-theme="dark"] .sample-progress-kpi.is-warning > .summary-card-icon { color: #f1cf7a !important; background: #3a311c; border-color: #66552d; }
html[data-theme="dark"] .summary-card-icon.is-danger { color: #ff9aab !important; background: #41232b; border-color: #71404b; }
html[data-theme="dark"] .summary-card-icon.is-muted { color: #a9b5c1 !important; background: #202c38; border-color: #3c4d5e; }
html[data-theme="dark"] .audit-list-table tbody tr:hover,
html[data-theme="dark"] .sample-progress-table tbody tr:hover,
html[data-theme="dark"] .sample-progress-detail-table tbody tr:hover { background: #1d2a36; }
html[data-theme="dark"] .sample-progress-meter progress,
html[data-theme="dark"] .sample-progress-meter progress::-webkit-progress-bar { background: #344655; }
html[data-theme="dark"] .sample-progress-methodology { background: rgba(24, 35, 46, .94); border-color: #344655; }
html[data-theme="dark"] .sample-progress-methodology > summary .ui-icon { color: #9dd9d3; }
html[data-theme="dark"] .sample-progress-restricted-action { color: #9aa9b8; background: #202c38; border-color: #3c4d5e; }

@media (max-width: 1120px) {
    .sample-progress-filter-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .sample-progress-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .sample-progress-detail-summary { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 720px) {
    .sample-progress-filter-grid { grid-template-columns: 1fr; }
    .sample-progress-summary { grid-template-columns: 1fr; gap: 11px; }
    .sample-progress-kpi { min-height: 102px; padding: 16px 64px 16px 17px; }
    .sample-progress-kpi > strong { font-size: 25px; }
    .sample-progress-panel .panel-heading { align-items: flex-start; }
    .sample-progress-scope-note { margin-top: 7px; }
    .sample-progress-detail-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .sample-progress-methodology > summary { padding: 16px 18px; }
    .sample-progress-methodology > div { padding: 0 18px 17px; }
}

@media (max-width: 460px) {
    .sample-progress-detail-summary { grid-template-columns: 1fr; }
    .sample-progress-detail-summary > div { min-height: 82px; }
}

/* Bundle Care-aligned audit dashboard composition. The analytics and access
   rules remain owned by dashboard_analytics_service.php; this layer is visual. */
.performance-dashboard { width: 100%; max-width: 1240px; margin: 0 auto; }
.performance-dashboard .performance-hero {
    position: relative;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    padding: 0;
    margin-bottom: 22px;
    overflow: visible;
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}
.performance-dashboard .performance-hero::after { display: none; }
.performance-dashboard .performance-hero-copy { align-self: auto; }
.performance-dashboard .performance-hero-copy .eyebrow { color: var(--accent); }
.performance-dashboard .performance-hero-copy h2 {
    max-width: 740px;
    margin: 0 0 7px;
    font-size: clamp(23px, 2.3vw, 30px);
    font-weight: 760;
    letter-spacing: -.035em;
    line-height: 1.14;
}
.performance-dashboard .performance-hero-copy p:not(.eyebrow) {
    max-width: 760px;
    margin: 0;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.6;
}
.performance-dashboard .performance-scope-card {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 9px;
    min-width: 230px;
    min-height: 0;
    padding: 11px 13px;
    background: rgba(255, 255, 255, .78);
    border: 1px solid rgba(207, 220, 232, .94);
    border-radius: 13px;
    box-shadow: var(--shadow-soft);
}
.performance-dashboard .performance-scope-icon {
    width: 34px;
    height: 34px;
    color: var(--accent);
    background: var(--accent-soft);
    border: 1px solid var(--accent-border);
    border-radius: 9px;
    font-size: 19px;
}
.performance-dashboard .performance-scope-card span { font-size: 9px; letter-spacing: .055em; }
.performance-dashboard .performance-scope-card strong { margin-top: 2px; font-size: 11px; }
.performance-dashboard .performance-scope-card small { margin-top: 2px; font-size: 9px; }

.performance-dashboard .performance-filter-panel {
    padding: 0;
    margin-bottom: 19px;
    overflow: hidden;
}
.performance-filter-heading {
    display: flex;
    align-items: flex-start;
    gap: 11px;
    padding: 19px 22px 17px;
    background: linear-gradient(100deg, rgba(245, 233, 212, .76), rgba(255, 255, 255, 0));
}
.performance-filter-heading > .performance-filter-icon {
    display: grid;
    flex: 0 0 auto;
    width: 34px;
    height: 34px;
    color: var(--accent);
    background: var(--accent-soft);
    border: 1px solid var(--accent-border);
    border-radius: 9px;
    font-size: 19px;
    place-items: center;
}
.performance-filter-heading > div { min-width: 0; }
.performance-filter-heading h3 { margin: 0; color: var(--ink); font-size: 15px; font-weight: 750; letter-spacing: -.015em; }
.performance-filter-heading p { margin: 4px 0 0; color: var(--muted); font-size: 11px; font-weight: 600; line-height: 1.55; }
.performance-filter-state { flex: 0 0 auto; margin-left: auto; }
.performance-dashboard .performance-filter-form { padding: 0; }
.performance-dashboard .performance-filter-grid {
    grid-template-columns: repeat(4, minmax(140px, 1fr));
    gap: 14px;
    align-items: start;
    padding: 17px 22px;
    border-top: 1px solid var(--border);
}
.performance-dashboard .performance-filter-grid .field { min-width: 0; margin: 0; }
.performance-filter-actions {
    display: flex;
    justify-content: flex-end;
    gap: 7px;
    padding: 14px 22px 16px;
    background: #faf7f2;
    border-top: 1px solid var(--border);
}

.performance-dashboard .performance-tabs {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 9px;
    padding: 10px;
    margin: 0 0 20px;
    overflow: visible;
    background: rgba(255, 255, 255, .78);
    border: 1px solid rgba(207, 220, 232, .92);
    border-radius: 16px;
    box-shadow: 0 9px 24px rgba(32, 56, 76, .07);
}
.performance-dashboard .performance-tab {
    display: inline-flex;
    min-width: 0;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 46px;
    padding: 10px 14px;
    color: #687586;
    background: rgba(245, 248, 250, .88);
    border: 1px solid #d7e0e8;
    border-radius: 11px;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.25;
    text-align: center;
    white-space: normal;
    transition: color 180ms cubic-bezier(.2, .75, .3, 1), background-color 180ms cubic-bezier(.2, .75, .3, 1), border-color 180ms cubic-bezier(.2, .75, .3, 1), transform 180ms cubic-bezier(.2, .75, .3, 1);
}
.performance-dashboard .performance-tab:hover { color: var(--ink); background: #fff; border-color: #b8c7d4; transform: translateY(-1px); }
.performance-dashboard .performance-tab:focus-visible { outline: 3px solid rgba(31, 132, 181, .28); outline-offset: 2px; }
.performance-dashboard .performance-tab.active { color: #fff; background: #18212d; border-color: #18212d; box-shadow: 0 7px 14px rgba(24, 33, 45, .16); }
.performance-dashboard .performance-tab .ui-icon { font-size: 17px; }

.performance-dashboard .performance-kpi-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 11px;
    margin-bottom: 18px;
}
.performance-dashboard .performance-kpi {
    display: block;
    min-height: 150px;
    padding: 15px;
    background: rgba(255, 255, 255, .88);
    border: 1px solid rgba(207, 220, 232, .90);
    border-radius: 14px;
    box-shadow: var(--shadow-soft);
}
.performance-dashboard .performance-kpi::after { right: -20px; bottom: -30px; width: 92px; height: 92px; background: radial-gradient(circle, rgba(156, 182, 204, .16), transparent 68%); }
.performance-dashboard .performance-kpi-lead { grid-column: auto; color: var(--text); }
.performance-dashboard .performance-kpi-icon,
.performance-dashboard .performance-kpi-lead .performance-kpi-icon {
    width: 30px;
    height: 30px;
    margin-bottom: 12px;
    color: #376c90;
    background: #ecf5fb;
    border: 1px solid #cfe2ef;
    border-radius: 8px;
    font-size: 17px;
}
.performance-dashboard .performance-kpi.is-success .performance-kpi-icon { color: #11683a; background: #e8f6eb; border-color: #bddfc8; }
.performance-dashboard .performance-kpi.is-warning .performance-kpi-icon { color: #87580e; background: #fff2d8; border-color: #f1d89c; }
.performance-dashboard .performance-kpi.is-danger .performance-kpi-icon,
.performance-dashboard .performance-kpi.is-finding .performance-kpi-icon { color: #a4291d; background: #fff0ed; border-color: #f0c0b9; }
.performance-dashboard .performance-kpi.is-target .performance-kpi-icon,
.performance-dashboard .performance-kpi.is-compliance .performance-kpi-icon { color: #0f756f; background: #e6f6f3; border-color: #b9ddd8; }
.performance-dashboard .performance-kpi > div > span,
.performance-dashboard .performance-kpi-lead span {
    color: var(--muted);
    font-size: 9px;
    font-weight: 750;
    letter-spacing: .065em;
}
.performance-dashboard .performance-kpi strong,
.performance-dashboard .performance-kpi-lead strong { margin-top: 5px; color: var(--ink); font-size: 22px; font-weight: 790; line-height: 1.05; }
.performance-dashboard .performance-kpi small,
.performance-dashboard .performance-kpi-lead small { margin-top: 6px; color: var(--muted); font-size: 10px; line-height: 1.45; }
.performance-dashboard .performance-kpi strong.text-value { font-size: 15px; line-height: 1.2; }

.performance-dashboard .performance-chart-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 17px; margin-bottom: 18px; }
.performance-dashboard .performance-chart-card,
.performance-dashboard .performance-breakdown-card { min-height: 390px; padding: 20px; }
.performance-dashboard .performance-section-heading { gap: 16px; margin-bottom: 14px; }
.performance-dashboard .performance-section-heading .eyebrow { margin: 0 0 5px; color: var(--accent); }
.performance-dashboard .performance-section-heading h3 { font-size: 15px; font-weight: 750; letter-spacing: -.016em; }
.performance-dashboard .performance-section-heading p:not(.eyebrow) { margin-top: 5px; font-size: 11px; line-height: 1.5; }
.performance-dashboard .performance-chart-unit,
.performance-dashboard .performance-scope-note { padding: 5px 8px; color: #87580e; background: #fff3dc; border: 1px solid #f1d89c; font-size: 9px; font-weight: 750; }
.performance-dashboard .performance-chart { min-height: 262px; }
.performance-dashboard .performance-chart svg { height: 262px; }
.performance-dashboard .performance-overview-lower { gap: 17px; margin-bottom: 18px; }
.performance-dashboard .performance-monthly-table-panel,
.performance-dashboard .performance-citations-panel,
.performance-dashboard .performance-sample-table-panel,
.performance-dashboard .performance-compliance-tables .panel,
.performance-dashboard .performance-productivity-grid .panel { padding: 20px; }
.performance-dashboard .performance-table th,
.performance-dashboard .performance-table td { padding: 10px 11px; font-size: 10px; }
.performance-dashboard .performance-table th { background: var(--surface-warm); font-size: 9px; }

.performance-dashboard .performance-mini-kpis { gap: 11px; margin-bottom: 18px; }
.performance-dashboard .performance-mini-kpis article { min-height: 92px; padding: 15px; border-radius: 14px; }
.performance-dashboard .performance-review-strip { gap: 11px; overflow: visible; color: var(--text); background: transparent; border: 0; box-shadow: none; }
.performance-dashboard .performance-review-strip > div {
    min-height: 118px;
    color: var(--text);
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    box-shadow: var(--shadow-soft);
}
.performance-dashboard .performance-review-strip small { color: var(--muted); }
.performance-dashboard .performance-review-strip strong { color: var(--ink); }
.performance-dashboard .performance-review-strip p { color: var(--muted); }
.performance-dashboard .performance-review-primary > .ui-icon { color: #376c90; background: #ecf5fb; border: 1px solid #cfe2ef; }
.performance-dashboard .performance-productivity-grid { gap: 17px; margin-bottom: 18px; }
.performance-dashboard .performance-sample-hero { padding: 20px 22px; background: var(--surface); border-radius: 18px; }
.performance-dashboard .performance-sample-hero h3 { font-size: 17px; }

html[data-theme="dark"] .performance-dashboard .performance-hero { background: transparent; border: 0; }
html[data-theme="dark"] .performance-dashboard .performance-scope-card,
html[data-theme="dark"] .performance-dashboard .performance-kpi,
html[data-theme="dark"] .performance-dashboard .performance-mini-kpis article,
html[data-theme="dark"] .performance-dashboard .performance-review-strip > div { background: #18232e; border-color: #344655; box-shadow: none; }
html[data-theme="dark"] .performance-filter-heading { background: linear-gradient(100deg, rgba(170, 45, 0, .13), rgba(32, 44, 56, 0)); }
html[data-theme="dark"] .performance-filter-heading > .performance-filter-icon { color: #ffad89; background: rgba(170, 45, 0, .20); border-color: rgba(255, 173, 137, .32); }
html[data-theme="dark"] .performance-filter-actions { background: #202425; border-color: var(--border); }
html[data-theme="dark"] .performance-dashboard .performance-tabs { background: rgba(20, 32, 43, .94); border-color: #344655; box-shadow: 0 10px 28px rgba(0, 0, 0, .16); }
html[data-theme="dark"] .performance-dashboard .performance-tab { color: #b8c5d1; background: #202c38; border-color: #3a4a5c; }
html[data-theme="dark"] .performance-dashboard .performance-tab:hover { color: var(--ink); background: #293746; }
html[data-theme="dark"] .performance-dashboard .performance-tab.active { color: #21140f; background: #ffd6c3; border-color: #ffd6c3; }
html[data-theme="dark"] .performance-dashboard .performance-kpi-icon,
html[data-theme="dark"] .performance-dashboard .performance-kpi-lead .performance-kpi-icon,
html[data-theme="dark"] .performance-dashboard .performance-review-primary > .ui-icon { color: #a8d3ff; background: #263747; border-color: #40576a; }
html[data-theme="dark"] .performance-dashboard .performance-kpi.is-success .performance-kpi-icon { color: #7be0b7; background: #17372d; border-color: #315d4e; }
html[data-theme="dark"] .performance-dashboard .performance-kpi.is-warning .performance-kpi-icon { color: #f1cf7a; background: #3a311c; border-color: #66552d; }
html[data-theme="dark"] .performance-dashboard .performance-kpi.is-danger .performance-kpi-icon,
html[data-theme="dark"] .performance-dashboard .performance-kpi.is-finding .performance-kpi-icon { color: #ff9aab; background: #41232b; border-color: #71404b; }
html[data-theme="dark"] .performance-dashboard .performance-kpi.is-target .performance-kpi-icon,
html[data-theme="dark"] .performance-dashboard .performance-kpi.is-compliance .performance-kpi-icon { color: #8fe4d6; background: rgba(85, 198, 182, .14); border-color: rgba(143, 228, 214, .28); }
html[data-theme="dark"] .performance-dashboard .performance-chart-unit,
html[data-theme="dark"] .performance-dashboard .performance-scope-note { color: #ffd08b; background: rgba(147, 99, 8, .23); border-color: rgba(255, 208, 139, .25); }
html[data-theme="dark"] .performance-dashboard .performance-sample-hero { background: #18232e; border-color: #344655; }

@media (max-width: 1240px) {
    .performance-dashboard .performance-filter-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .performance-dashboard .performance-kpi-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 980px) {
    .performance-dashboard .performance-chart-grid,
    .performance-dashboard .performance-compliance-tables,
    .performance-dashboard .performance-productivity-grid { grid-template-columns: 1fr; }
    .performance-dashboard .performance-chart-card,
    .performance-dashboard .performance-breakdown-card { min-height: auto; }
}

@media (max-width: 760px) {
    .performance-dashboard .performance-hero { display: block; }
    .performance-dashboard .performance-scope-card { width: 100%; margin-top: 15px; }
    .performance-filter-heading { padding: 18px; }
    .performance-filter-state { margin-left: auto; }
    .performance-dashboard .performance-filter-grid { grid-template-columns: 1fr; padding: 17px 18px; }
    .performance-filter-actions { display: grid; grid-template-columns: 1fr 1fr; padding: 14px 18px 18px; }
    .performance-dashboard .performance-kpi-grid,
    .performance-dashboard .performance-mini-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .performance-dashboard .performance-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; padding: 8px; }
    .performance-dashboard .performance-tab { min-height: 50px; padding: 9px 10px; }
}

@media (max-width: 520px) {
    .performance-filter-heading { align-items: flex-start; flex-wrap: wrap; }
    .performance-filter-state { margin-left: 45px; }
    .performance-filter-actions { grid-template-columns: 1fr; }
    .performance-dashboard .performance-tabs { margin-bottom: 18px; }
    .performance-dashboard .performance-kpi-grid,
    .performance-dashboard .performance-mini-kpis,
    .performance-dashboard .performance-review-strip { grid-template-columns: 1fr; }
    .performance-dashboard .performance-kpi { min-height: 136px; }
}

@media (prefers-reduced-motion: reduce) {
    .performance-dashboard .performance-tab { transition: none; }
}
