html, body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    height: 100%;
    overflow: hidden;     /* PulseLayout handles its own scroll inside .pulse-canvas */
    margin: 0;
}

/* Viewport lock — anchored at .page so Blazor wrapper divs are irrelevant.
   100vh is absolute so it doesn't need a height: 100% chain above it.
   This only affects pages that use MainLayout (.page exists).
   Login / EmptyLayout pages are unaffected. */
.page {
    display: flex;
    flex-direction: row;
    height: 100vh;
    max-height: 100vh;
    overflow: hidden;
}

main {
    flex: 1;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

article.content {
    flex: 1;
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

a, .btn-link {
    color: #006bb7;
}

.btn-primary {
    color: #fff;
    background-color: #1b6ec2;
    border-color: #1861ac;
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

.content {
    padding-top: 1.1rem;
}

h1:focus {
    outline: none;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid #e50000;
}

.validation-message {
    color: #e50000;
}

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.darker-border-checkbox.form-check-input {
    border-color: #929292;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

/* ── Shared editor shell + menubar ─────────────────────────────────────────── */
.ici-shell {
    background: var(--mud-palette-drawer-background, #FAFAFA);
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.ici-sticky-header {
    position: sticky;
    top: 0;
    z-index: 200;
    background: var(--mud-palette-drawer-background, #FAFAFA);
}
.ici-content {
    flex: 1;
    min-height: 0;
    overflow: auto;
}
.ici-grid-search { background: var(--mud-palette-background, #FFFFFF) !important; }
/* MudDataGrid cell font size — matches BR editor grid (0.78rem body, 0.75rem header) */
.ici-shell .mud-table-cell { font-size: 0.78rem !important; }
.ici-shell .mud-table-head .mud-table-cell { font-size: 0.75rem !important; }
.ici-title-row {
    background: var(--mud-palette-drawer-background, #FAFAFA);
    color: var(--mud-palette-drawer-text, #0E0E0E);
}
.ici-title-row .mud-secondary-text,
.ici-title-row .mud-typography-overline {
    color: var(--mud-palette-drawer-text, #0E0E0E) !important;
}
.ici-title { font-weight: 400 !important; letter-spacing: -0.01em; display: inline-flex; align-items: center; gap: 0.45rem; }
.ici-title .mud-icon-root { color: #86BC25; font-size: 1.4rem !important; }
.ici-menubar {
    border-top: 1px solid var(--mud-palette-lines-default, #E0E0E0);
    border-bottom: 1px solid var(--mud-palette-lines-default, #E0E0E0);
    background: var(--mud-palette-surface, #FFFFFF);
    /* a little vertical breathing room so the bar doesn't crowd the title above
       or the content below — applies to every page that uses this menubar. */
    padding: 6px 0.25rem;
    margin: 6px 0;
}
.ici-dd-bar {
    display: flex; align-items: stretch;
    height: 100%; width: 100%;
}
.ici-dd { position: relative; display: flex; align-items: stretch; }
.ici-dd-btn {
    background: none; border: none; padding: 0 12px;
    cursor: pointer; font-size: 0.8125rem; font-weight: 400;
    color: var(--mud-palette-text-primary, #0E0E0E);
    white-space: nowrap; display: flex; align-items: center;
}
.ici-dd-btn:hover,
.ici-dd:focus-within .ici-dd-btn { background: rgba(0,0,0,0.06); }
/* File / Config / menu buttons are not bold. Higher specificity than the
   stale per-page `.ici-dd-btn { font-weight:600 }` copies, so it wins
   everywhere without touching 15 component <style> blocks. */
.ici-dd-bar .ici-dd-btn { font-weight: 400; }
.ici-dd-panel {
    display: none;
    position: absolute;
    top: 100%; left: 0;
    z-index: 2000;
    background: var(--mud-palette-surface, #fff);
    border: 1px solid var(--mud-palette-lines-default, #E0E0E0);
    border-radius: 0 0 4px 4px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.12);
    min-width: 160px;
    padding: 8px 0;
}
.ici-dd:focus-within .ici-dd-panel,
.ici-dd:hover .ici-dd-panel { display: block; }
.ici-dd-item {
    display: block; width: 100%;
    background: none; border: none;
    padding: 10px 16px; text-align: left;
    cursor: pointer; font-size: 0.875rem;
    color: var(--mud-palette-text-primary, #0E0E0E);
    white-space: nowrap;
}
.ici-dd-item:hover:not(:disabled) { background: rgba(0,0,0,0.06); }
.ici-dd-item:disabled { opacity: 0.45; cursor: default; }
.ici-dd-soon {
    display: block; padding: 10px 16px;
    font-size: 0.875rem; font-style: italic;
    color: var(--mud-palette-text-secondary, #666);
}
.ici-dd-sep { border: none; border-top: 1px solid var(--mud-palette-lines-default, #E0E0E0); margin: 4px 0; }

/* ── Dashboard workstream sidebar ──────────────────────────────────────────── */
.ws-layout {
    display: flex;
    gap: 0;
    background: var(--mud-palette-background, #fff);
    border-radius: 8px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
    overflow: hidden;
    min-height: 420px;
}
.ws-sidebar {
    width: 172px;
    min-width: 172px;
    background: var(--mud-palette-background-grey, #f8f9fb);
    border-right: 1px solid #e8e8e8;
    display: flex;
    flex-direction: column;
    padding: 4px 0 8px;
    flex-shrink: 0;
}
.ws-sidebar-group {
    font-size: 0.61rem;
    font-weight: 700;
    letter-spacing: 0.11em;
    text-transform: uppercase;
    color: #aaa;
    padding: 10px 14px 4px;
}
.ws-sidebar-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 7px 14px;
    font-size: 0.8rem;
    color: #444;
    background: none;
    border: none;
    border-left: 3px solid transparent;
    width: 100%;
    text-align: left;
    cursor: pointer;
    transition: background 0.1s, color 0.1s, border-color 0.1s;
    gap: 6px;
    box-sizing: border-box;
}
.ws-sidebar-item:hover { background: #eef0f4; color: #052767; }
.ws-sidebar-active {
    background: #e8eef8;
    color: #052767;
    font-weight: 600;
    border-left-color: #86BC25;
}
.ws-sidebar-soon { opacity: 0.42; cursor: default; }
.ws-sidebar-soon:hover { background: none !important; color: #444 !important; }
.ws-sidebar-label { flex: 1; }
.ws-sidebar-badge {
    font-size: 0.68rem;
    font-weight: 700;
    background: #e8eef8;
    color: #2a5aad;
    padding: 1px 6px;
    border-radius: 10px;
    min-width: 22px;
    text-align: center;
    flex-shrink: 0;
}
.ws-sidebar-active .ws-sidebar-badge { background: #052767; color: #fff; }
.ws-soon-chip {
    font-size: 0.58rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    background: #e5e7eb;
    color: #9ca3af;
    padding: 1px 5px;
    border-radius: 3px;
    flex-shrink: 0;
}
.ws-sidebar-divider { border-top: 1px solid #e4e6ea; margin: 6px 0; }
.ws-content {
    flex: 1;
    padding: 18px 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    overflow: hidden;
}
.form-splitter {
    height: 5px;
    background: #e4e6ea;
    cursor: ns-resize;
    flex-shrink: 0;
}
.form-splitter:hover, .form-splitter.active {
    background: #86bc25;
}
.project-readonly-banner {
    background: #fff3cd;
    color: #856404;
    border-bottom: 1px solid #ffc107;
    padding: 6px 20px;
    font-size: 0.82rem;
    font-weight: 500;
    display: flex;
    align-items: center;
}

/* Selected-row highlight, shared across every grid editor. */
.ici-row-selected { background-color: rgba(134,188,37,.15) !important; }
.ici-row-selected td { background-color: rgba(134,188,37,.15) !important; }

/* ── Theme-aware native form controls ─────────────────────────────────────── */
/* Native <input>, <select>, <textarea> default to browser white regardless of
   the active theme. These rules pull them into the palette so tinted themes
   (Granite, Ocean, Forest, Desert, Moab) look consistent throughout.         */
input:not([type="checkbox"]):not([type="radio"]):not([type="range"])
    :not([type="color"]):not([type="submit"]):not([type="button"]):not([type="reset"]),
select,
textarea {
    background-color: var(--mud-palette-background, #FFFFFF);
    color: var(--mud-palette-text-primary, #0E0E0E);
}

/* Override component-local hardcoded whites for lists and dialog selects */
.pc-listbox,
.dlg-field-select {
    background: var(--mud-palette-background, #FFFFFF) !important;
    color: var(--mud-palette-text-primary, #0E0E0E) !important;
}

/* Workstream content pane */
.ws-content {
    background: var(--mud-palette-background, #FFFFFF);
}


/* ── Dashboard advanced widget CSS ──────────────────────────────────────────── */

/* Sparkline */
.db-w-sparkline {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 8px 10px 6px;
    overflow: hidden;
    color: var(--mud-palette-text-primary);
}
.db-w-sparkline-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 2px;
}
.db-w-sparkline-title  { font-size: 0.78rem; font-weight: 700; color: #555; }
.db-w-sparkline-trend  { font-size: 0.78rem; font-weight: 600; }
.db-w-sparkline-sublabel { font-size: 0.68rem; color: #aaa; margin-bottom: 4px; }
.db-w-sparkline-footer   { font-size: 0.65rem; color: #bbb; margin-top: 4px; }
.db-w-sparkline-nodata   { font-size: 0.75rem; color: #ccc; text-align: center; padding: 12px 0; }

/* Gauge */
.db-w-gauge {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    padding: 6px;
    color: var(--mud-palette-text-primary);
}
.db-w-gauge-title {
    font-size: 0.75rem;
    font-weight: 700;
    color: #555;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 4px;
}

/* Variance meter */
.db-w-variance {
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%;
    padding: 8px 12px;
    color: var(--mud-palette-text-primary);
}
.db-w-variance-title   { font-size: 0.75rem; font-weight: 700; color: #555; margin-bottom: 2px; }
.db-w-variance-display { font-size: 1rem; font-weight: 700; color: #333; margin-bottom: 4px; }
.db-w-variance-sub     { font-size: 0.68rem; color: #aaa; margin-top: 4px; }

/* Radar */
.db-w-radar {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: center;
    height: 100%;
    width: 100%;
    padding: 4px 6px;
    color: var(--mud-palette-text-primary);
    overflow: hidden;
}
.db-w-radar svg { max-height: 100%; max-width: 100%; }
.db-w-radar-title {
    font-size: 0.75rem;
    font-weight: 700;
    color: #555;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 4px 4px 0;
    flex-shrink: 0;
}
.db-w-radar-nodata  { font-size: 0.75rem; color: #ccc; padding: 20px; text-align: center; }
/* Scale toggle pill at the bottom of the radar widget. */
.db-w-radar-scale {
    display: flex; align-items: center; gap: 2px;
    align-self: center;
    padding: 2px 4px;
    margin-top: 4px;
    background: #FAFAFA;
    border: 1px solid #ECEFF1;
    border-radius: 12px;
    font-size: 0.62rem;
}
.db-w-radar-scale-lbl {
    color: #888; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.05em;
    padding: 0 6px 0 4px;
}
.db-w-radar-scale button {
    background: transparent; border: none;
    padding: 2px 8px; border-radius: 10px;
    font-size: 0.66rem; font-weight: 700;
    color: #607D8B; cursor: pointer;
    transition: background 0.12s, color 0.12s;
}
.db-w-radar-scale button:hover { background: #E0E0E0; color: #1a1a1a; }
.db-w-radar-scale button.on   { background: #1976D2; color: #fff; }

/* Heatmap */
.db-w-heatmap {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 8px 10px;
    overflow: hidden;
    color: var(--mud-palette-text-primary);
}
.db-w-heatmap-title   { font-size: 0.75rem; font-weight: 700; color: #555; margin-bottom: 6px; }
.db-w-heatmap-scroll  { overflow-x: auto; flex: 1; }
.db-w-heatmap-nodata  { font-size: 0.75rem; color: #ccc; padding: 12px 0; }
.db-w-heatmap-table   { border-collapse: collapse; width: 100%; font-size: 0.72rem; }
.db-w-hm-rowlabel {
    text-align: left;
    padding: 3px 6px 3px 0;
    white-space: nowrap;
    font-weight: 600;
    color: #555;
    min-width: 60px;
}
.db-w-hm-collabel {
    text-align: center;
    padding: 2px 4px;
    font-size: 0.66rem;
    color: #888;
    font-weight: 600;
    white-space: nowrap;
    min-width: 32px;
}
.db-w-hm-cell {
    text-align: center;
    padding: 4px 6px;
    border: 1px solid rgba(255,255,255,0.5);
    border-radius: 3px;
    font-size: 0.72rem;
    font-weight: 600;
    min-width: 28px;
}

/* Risk Pulse */
.db-w-risk {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 8px 10px;
    color: var(--mud-palette-text-primary);
}
.db-w-risk-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}
.db-w-risk-title { font-size: 0.75rem; font-weight: 700; color: #555; text-transform: uppercase; letter-spacing: 0.06em; }
.db-w-risk-rag   { font-size: 1.4rem; line-height: 1; }
.db-w-risk-rows  { display: flex; flex-direction: column; gap: 4px; flex: 1; overflow: hidden; }
.db-w-risk-row   { display: grid; grid-template-columns: 20px 1fr auto 14px; align-items: center; gap: 4px; font-size: 0.75rem; }
.db-w-risk-icon  { font-size: 0.85rem; }
.db-w-risk-lbl   { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #444; }
.db-w-risk-count { font-weight: 700; color: #333; }
.db-w-risk-dot   { font-size: 0.75rem; }

/* Go-Live Countdown */
.db-w-golive {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    padding: 8px 12px;
    text-align: center;
    color: var(--mud-palette-text-primary);
}
.db-w-golive-title     { font-size: 0.72rem; font-weight: 700; color: #888; text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 4px; }
.db-w-golive-count     { font-size: 2.6rem; font-weight: 800; line-height: 1; }
.db-w-golive-label     { font-size: 0.75rem; font-weight: 600; margin-top: 2px; }
.db-w-golive-date      { font-size: 0.7rem; color: #888; margin-top: 4px; }
.db-w-golive-conf-label { font-size: 0.68rem; color: #888; margin-top: 8px; }
.db-w-golive-conf-bar-bg {
    width: 80%;
    height: 6px;
    background: #e8ecf0;
    border-radius: 3px;
    overflow: hidden;
    margin: 4px auto 0;
}
.db-w-golive-conf-bar { height: 100%; border-radius: 3px; min-width: 3px; }
.db-w-golive-conf-pct { font-size: 0.72rem; font-weight: 700; margin-top: 3px; }

/* Milestone Timeline */
.db-w-milestone {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 8px 10px;
    overflow: hidden;
    color: var(--mud-palette-text-primary);
}
.db-w-milestone-title { font-size: 0.75rem; font-weight: 700; color: #555; margin-bottom: 6px; text-transform: uppercase; letter-spacing: 0.06em; }
.db-w-milestone-list  { display: flex; flex-direction: column; gap: 4px; flex: 1; overflow: hidden; }
.db-w-milestone-row {
    display: grid;
    grid-template-columns: 16px 1fr auto;
    align-items: center;
    gap: 6px;
    font-size: 0.75rem;
    border-left: 3px solid #9E9E9E;
    padding: 3px 4px 3px 6px;
    border-radius: 2px;
    background: #fafafa;
}
.db-w-ms-icon  { font-size: 0.8rem; flex-shrink: 0; }
.db-w-ms-name  { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #333; }
.db-w-ms-date  { font-size: 0.68rem; color: #888; white-space: nowrap; flex-shrink: 0; }
.db-w-milestone-empty { font-size: 0.75rem; color: #ccc; padding: 12px 0; }

/* Defect Age */
.db-w-defect-age {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 8px 12px;
    overflow: hidden;
    color: var(--mud-palette-text-primary);
}
.db-w-da-title  { font-size: 0.75rem; font-weight: 700; color: #555; margin-bottom: 6px; text-transform: uppercase; letter-spacing: 0.06em; }
.db-w-da-list   { display: flex; flex-direction: column; gap: 5px; flex: 1; overflow: hidden; }
.db-w-da-row    { display: grid; grid-template-columns: 70px 1fr 32px; align-items: center; gap: 6px; font-size: 0.75rem; }
.db-w-da-label  { font-size: 0.72rem; color: #555; white-space: nowrap; }
.db-w-da-bar-bg { background: #f0f0f0; border-radius: 4px; height: 8px; overflow: hidden; }
.db-w-da-bar    { height: 100%; border-radius: 4px; min-width: 3px; }
.db-w-da-count  { font-weight: 700; text-align: right; font-size: 0.78rem; }
.db-w-da-footer { font-size: 0.65rem; color: #bbb; margin-top: 6px; }
.db-w-da-empty  { font-size: 0.75rem; color: #ccc; padding: 12px 0; }

/* ── Widget tooltip (? icon in top-right corner) ─────────────────────────── */
.db-widget-tip-anchor {
    position: absolute;
    top: 6px;
    right: 6px;
    z-index: 10;
}
.db-widget-tip-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: rgba(0,0,0,0.08);
    color: #777;
    font-size: 0.65rem;
    font-weight: 700;
    cursor: default;
    line-height: 1;
    user-select: none;
    transition: background 0.15s;
}
.db-widget-tip-anchor:hover .db-widget-tip-icon {
    background: rgba(0,0,0,0.18);
    color: #333;
}
.db-widget-tip-panel {
    display: none;
    position: absolute;
    top: 24px;
    right: 0;
    width: 260px;
    background: #fff;
    border: 1px solid rgba(0,0,0,0.12);
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.14);
    padding: 10px 13px;
    font-size: 0.75rem;
    line-height: 1.5;
    color: #333;
    z-index: 999;
    pointer-events: none;
}
.db-widget-tip-anchor:hover .db-widget-tip-panel {
    display: block;
}
/* keep the widget itself position:relative so the anchor sits inside */
.db-widget { position: relative; }

/* Zoom control — used by both the Dashboards builder and the Home dashboards.
   Sits inline in a toolbar; bind value to a 0.5–2.0 zoom field. */
.db-zoom {
    display: flex; align-items: center; gap: 4px;
    padding: 0 10px;
    flex-shrink: 0;
}
.db-zoom input[type="range"] {
    width: 110px;
    accent-color: #86BC25;
    cursor: pointer;
}
.db-zoom-btn, .db-zoom-pct {
    height: 22px; min-width: 22px;
    padding: 0 6px;
    background: #fff; border: 1px solid #CFD8DC; border-radius: 4px;
    font-size: 0.78rem; font-weight: 700; line-height: 1;
    color: #555; cursor: pointer;
}
.db-zoom-btn:hover, .db-zoom-pct:hover { background: #ECEFF1; color: #1a1a1a; }
.db-zoom-pct { font-family: 'JetBrains Mono', Consolas, monospace; min-width: 46px; text-align: center; }

/* Health indicator dot — sits directly below the ? icon in the top right corner. */
.db-widget-health {
    position: absolute;
    top: 30px;                    /* 6px (top) + 18px (? icon) + 6px gap */
    right: 10px;                  /* aligns with ? icon center (6 + 18/2 - 5) */
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #BDBDBD;
    box-shadow: 0 0 0 2px #fff;   /* tiny halo so it reads cleanly on any tile bg */
    z-index: 10;
    pointer-events: none;
}
.db-widget-health.g { background: #86BC25; }   /* green  */
.db-widget-health.a { background: #FB8C00; }   /* amber  */
.db-widget-health.r { background: #E53935; }   /* red    */
.db-widget-health.n { background: #BDBDBD; }   /* neutral / not started */

/* ── Home page analytical widget row ─────────────────────────────────────── */
.ph-widget-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    /* Vertical spacing between panels is owned by .ph-shell { gap }; the old
       margin:12px 0 doubled the gap above/below this row, making the
       Health-at-a-Glance -> cards gap larger than every other gap. */
    margin: 0;
}
.ph-widget-card {
    background: var(--mud-palette-surface, #fff);
    border: 1px solid var(--mud-palette-lines-default, #e0e0e0);
    border-radius: 10px;
    padding: 10px 14px 12px;
    display: flex;
    flex-direction: column;
    min-height: 160px;
    overflow: hidden;
}
.ph-widget-card--md  { flex: 1 1 200px; }
.ph-widget-card--lg  { flex: 2 1 300px; }
.ph-widget-card-title {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.07em;
    color: #888;
    text-transform: uppercase;
    margin-bottom: 6px;
}

/* Hide the floating help "?" button when the user has opted out (toggled
   from the Config menu; persisted in localStorage via window.backpackHelp). */
body.help-hidden .help-fab { display: none !important; }

/* Section header inside the menubar dropdowns (Admin/Config menus). */
.ici-dd-head { padding: 6px 16px 2px; font-size: 0.64rem; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.07em; color: #9e9e9e; cursor: default; }

/* Flyout submenus inside the menubar dropdowns (Admin menu groups). */
.ici-dd-sub { position: relative; }
.ici-dd-subhead { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.ici-dd-arrow { color: #b0b0b0; font-size: 0.7rem; line-height: 1; }
.ici-dd-subpanel { display: none; position: absolute; top: -5px; left: 100%; background: #fff;
    border: 1px solid #E0E0E0; border-radius: 4px; box-shadow: 0 4px 16px rgba(0,0,0,.14);
    min-width: 180px; padding: 4px 0; z-index: 2001; }
.ici-dd-sub:hover > .ici-dd-subpanel,
.ici-dd-sub:focus-within > .ici-dd-subpanel { display: block; }
.ici-dd-sub:hover > .ici-dd-subhead { background: rgba(0,0,0,.06); }


/* ── Expanded grid: sidebar becomes an icon rail ── */
@media (min-width: 641px) {
    .sidebar { transition: width .2s ease; }   /* slides both ways: into the icon rail and back out */
    body.bp-rail .sidebar { width: 64px !important; overflow-x: hidden; }
    body.bp-rail .fabric-wordmark-text, body.bp-rail .fabric-dot { display: none !important; }
    body.bp-rail .fabric-nav-brand { padding-left: 17px !important; padding-right: 0 !important; }
    body.bp-rail .sidebar .mud-nav-link-text,
    body.bp-rail .sidebar .mud-nav-link-expand-icon { display: none !important; }
    body.bp-rail .sidebar .mud-nav-link { justify-content: center; padding-left: 0 !important; padding-right: 0 !important; }
    body.bp-rail .sidebar .mud-nav-link .mud-nav-link-icon { margin: 0 !important; }
    body.bp-rail .sidebar .mud-navgroup-collapse .mud-nav-link { padding-left: 0 !important; }
    /* The whole rail scrolls as one column, so the icons keep their spacing on short screens instead of squeezing. */
    body.bp-rail .fabric-nav { overflow-y: auto !important; scrollbar-width: thin; }
    body.bp-rail .fabric-nav > * { flex-shrink: 0 !important; }
    body.bp-rail .fabric-nav-scroll { flex: none !important; overflow: visible !important; }
    body.bp-rail .sidebar .mud-nav-link, body.bp-rail .sidebar .mud-divider { flex-shrink: 0 !important; }
    body.bp-rail .sidebar .mud-nav-link { min-height: 44px; }
    body.bp-rail .sidebar { height: 100vh; overflow-y: hidden; }
    body.bp-rail .fabric-nav { height: 100%; max-height: 100vh; min-height: 0; }
}

/* ── Schedule baseline + variance (migration 123) ── */
.bl-bar { display:flex; flex-wrap:wrap; gap:12px; align-items:center; padding:6px 12px; font-size:0.8rem; border-bottom:1px solid var(--mud-palette-lines-default,#e0e0e0); }
.bl-tag { background:#E3F2FD; color:#0D47A1; border:1px solid #90CAF9; border-radius:12px; padding:1px 10px; font-weight:600; }
.bl-tag-none { background:#F5F5F5; color:#616161; border-color:#E0E0E0; }
.bl-muted { color:#757575; }
.bl-stat b { font-weight:700; }
.bl-red { color:#C62828; }
.bl-btn { background:#86BC25; color:#fff; border:none; border-radius:4px; padding:3px 10px; font-size:0.78rem; cursor:pointer; }
.bl-btn:disabled { opacity:.5; cursor:default; }
.bl-link { background:none; border:none; color:#1565C0; cursor:pointer; font-size:0.78rem; padding:0; text-decoration:underline; }
.bl-confirm { display:flex; flex-wrap:wrap; gap:8px; align-items:center; padding:6px 12px; background:#FFF8E1; font-size:0.8rem; }
.bl-input { min-width:320px; padding:3px 6px; border:1px solid #BDBDBD; border-radius:4px; font-size:0.8rem; }
.bl-detail { padding:6px 12px 10px; font-size:0.78rem; }
.bl-table { border-collapse:collapse; }
.bl-table th, .bl-table td { text-align:left; padding:2px 14px 2px 0; }
.bl-hist-title { margin-top:8px; font-weight:600; }
.bl-hist { color:#616161; }
.bl-chip { display:inline-block; min-width:38px; text-align:center; border-radius:10px; padding:0 6px; font-size:0.72rem; font-weight:600; }
.bl-late  { background:#FFEBEE; color:#C62828; }
.bl-slip  { background:#FFF3E0; color:#E65100; }
.bl-early { background:#E8F5E9; color:#2E7D32; }
.bl-ok    { background:#F5F5F5; color:#616161; }
.bl-added { background:#EDE7F6; color:#4527A0; }
.bl-none  { color:#9E9E9E; }

/* ── Weekly status report (/report/status) ───────────────────────────── */
.sr-toolbar { display: flex; align-items: center; gap: 6px; width: 100%; padding: 0 10px; }
.sr-spacer { flex: 1; }
.sr-btn { background: #fff; border: 1px solid #D0D0D0; border-radius: 4px; padding: 4px 12px; font-size: 0.8125rem; font-weight: 600; color: #0E0E0E; cursor: pointer; text-decoration: none; white-space: nowrap; }
.sr-btn:hover:not(:disabled) { background: #F4F4F4; }
.sr-btn:disabled { opacity: .45; cursor: default; }
.sr-btn-primary { background: #86BC25; border-color: #86BC25; color: #fff; }
.sr-btn-primary:hover:not(:disabled) { background: #76A820; }
.sr-select, .sr-input { border: 1px solid #D0D0D0; border-radius: 4px; padding: 5px 8px; font: inherit; font-size: 0.85rem; background: #fff; color: #0E0E0E; }
.sr-input { width: 100%; box-sizing: border-box; resize: vertical; }
.sr-page { padding: 12px 16px 32px; max-width: 1180px; }
.sr-edit { background: #FAFAFA; border: 1px solid #E6E6E6; border-radius: 8px; padding: 12px 14px; margin-bottom: 16px; display: flex; flex-direction: column; gap: 10px; }
.sr-edit label { display: flex; flex-direction: column; gap: 4px; font-size: 0.75rem; font-weight: 600; color: #555; }
.sr-edit-row { display: flex; gap: 12px; flex-wrap: wrap; }
.sr-grow { flex: 1 1 280px; }
.sr-hint { font-size: 0.75rem; color: #757575; }

.sr { color: #1A1A1A; font-size: 0.85rem; }
.sr-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; border-bottom: 3px solid #86BC25; padding-bottom: 10px; }
.sr-kicker { font-size: 0.7rem; letter-spacing: .08em; text-transform: uppercase; color: #757575; font-weight: 700; }
.sr-project { font-size: 1.4rem; font-weight: 700; }
.sr-week { font-size: 0.82rem; color: #555; }
.sr-draft { margin-left: 6px; background: #FFF4D6; color: #8A6100; border-radius: 3px; padding: 1px 6px; font-size: 0.72rem; font-weight: 600; }
.sr-rag-box { text-align: center; }
.sr-rag { min-width: 96px; padding: 8px 14px; border-radius: 6px; font-weight: 800; font-size: 1rem; color: #fff; }
.sr-rag-label { font-size: 0.7rem; color: #757575; margin-top: 3px; }
.sr-rag-green { background: #2E7D32; } .sr-rag-amber { background: #E0A800; } .sr-rag-red { background: #C62828; }
.sr-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px; margin: 12px 0 8px; }
.sr-kpi { border: 1px solid #E6E6E6; border-radius: 6px; padding: 8px 10px; display: flex; flex-direction: column; }
.sr-kpi b { font-size: 1.25rem; }
.sr-kpi span { font-size: 0.72rem; color: #666; }
.sr-note { font-size: 0.78rem; color: #555; margin-bottom: 8px; }
.sr-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.sr-wide { grid-column: 1 / -1; }
.sr-card { border: 1px solid #E6E6E6; border-radius: 8px; padding: 10px 12px; break-inside: avoid; }
.sr-card h3 { margin: 0 0 6px; font-size: 0.78rem; text-transform: uppercase; letter-spacing: .04em; color: #455A64; }
.sr-para { white-space: pre-wrap; line-height: 1.45; }
.sr-empty { color: #9E9E9E; font-style: italic; font-size: 0.8rem; }
.sr-sub { font-size: 0.78rem; color: #555; margin-bottom: 6px; }
.sr-list { list-style: none; margin: 0; padding: 0; }
.sr-list li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px; padding: 4px 0; border-top: 1px solid #F0F0F0; }
.sr-list li:first-child { border-top: none; }
.sr-code { font-family: Consolas, monospace; font-size: 0.75rem; color: #455A64; min-width: 52px; }
.sr-title { flex: 1 1 200px; font-weight: 600; }
.sr-title a { color: inherit; text-decoration: none; }
.sr-title a:hover { text-decoration: underline; }
.sr-meta { flex-basis: 100%; padding-left: 58px; font-size: 0.74rem; color: #757575; }
.sr-flag { font-size: 0.66rem; font-weight: 700; text-transform: uppercase; border-radius: 3px; padding: 1px 5px; }
.sr-flag-overdue, .sr-flag-critical, .sr-flag-late { background: #FDE7E7; color: #B71C1C; }
.sr-flag-new { background: #E8F3D6; color: #4C7A0F; }
.sr-table { width: 100%; border-collapse: collapse; font-size: 0.8rem; }
.sr-table th { text-align: left; font-size: 0.7rem; color: #757575; font-weight: 700; border-bottom: 1px solid #E0E0E0; padding: 4px 6px; }
.sr-table td { border-bottom: 1px solid #F0F0F0; padding: 5px 6px; white-space: nowrap; }
.sr-table td:first-child { white-space: normal; font-weight: 600; }
.sr-bar { display: inline-block; width: 60px; height: 6px; background: #EEE; border-radius: 3px; margin-right: 6px; vertical-align: middle; overflow: hidden; }
.sr-bar i { display: block; height: 100%; background: #86BC25; }
.sr-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 5px; }
.sr-foot { margin-top: 14px; font-size: 0.7rem; color: #9E9E9E; text-align: right; }
.sr-print { background: #fff; min-height: 100vh; padding: 24px; max-width: 1000px; margin: 0 auto; }
.sr-print-bar { text-align: right; margin-bottom: 12px; }
@media (max-width: 760px) { .sr-grid { grid-template-columns: 1fr; } .sr-meta { padding-left: 0; } }
@media print {
    .sr-print-bar { display: none; }
    .sr-print { padding: 0; max-width: none; }
    .sr { font-size: 10pt; }
    .sr-rag, .sr-dot, .sr-bar i, .sr-flag { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
    .sr-title a { color: inherit; }
}

/* ── Roadmap (/roadmap, status report) ───────────────────────────────── */
.rm-page { padding: 12px 16px 32px; }
.rm-sub { font-size: 0.8rem; color: #555; }
.rm-empty { color: #9E9E9E; font-style: italic; font-size: 0.82rem; padding: 8px 0; }
.rm-wrap { overflow-x: auto; }
.rm-svg { display: block; font-family: inherit; min-width: 900px; }
@media print { .rm-svg { min-width: 0; } }
.rm-grid { stroke: #ECECEC; stroke-width: 1; }
.rm-month { font-size: 11px; fill: #757575; }
.rm-phase { font-size: 11px; font-weight: 700; fill: #37474F; }
.rm-stripe { fill: #FAFAFA; }
.rm-code { font-size: 10.5px; fill: #607D8B; font-family: Consolas, monospace; }
.rm-label { font-size: 11.5px; fill: #1A1A1A; }
.rm-crit { font-weight: 700; }
.rm-bar { opacity: .35; }
.rm-bar-done { fill: #78909C; } .rm-bar-green { fill: #2E7D32; } .rm-bar-amber { fill: #E0A800; } .rm-bar-red { fill: #C62828; }
.rm-dia { stroke: #fff; stroke-width: 1.5; }
.rm-dia-done { fill: #78909C; } .rm-dia-green { fill: #2E7D32; } .rm-dia-amber { fill: #E0A800; } .rm-dia-red { fill: #C62828; }
.rm-ghost { fill: #fff; stroke: #9E9E9E; stroke-width: 1.5; stroke-dasharray: 2 1.5; }
.rm-slip { stroke-width: 1.5; }
.rm-slip-late { stroke: #C62828; } .rm-slip-early { stroke: #2E7D32; }
.rm-sliptext { font-size: 10px; fill: #2E7D32; font-weight: 700; }
.rm-slip-late-t { fill: #C62828; }
.rm-today { stroke: #1565C0; stroke-width: 1.5; stroke-dasharray: 4 3; }
.rm-today-t { font-size: 10.5px; fill: #1565C0; font-weight: 700; }
.rm-golive { stroke: #86BC25; stroke-width: 2.5; }
.rm-golive-t { font-size: 10.5px; fill: #4C7A0F; font-weight: 700; }
.rm-legend { display: flex; flex-wrap: wrap; gap: 14px; font-size: 0.74rem; color: #616161; margin-top: 6px; }
.rm-legend span { display: inline-flex; align-items: center; gap: 4px; }
.rm-print { max-width: 1200px; }
@media print { @page { size: landscape; } .rm-dia, .rm-bar, .rm-svg rect { -webkit-print-color-adjust: exact; print-color-adjust: exact; } }
.ph-page { padding: 4px 16px 32px; max-width: 900px; }
.ph-table td { white-space: nowrap; }
.ph-table .sr-input { min-width: 0; }
.ph-mini { background: none; border: 1px solid #DDD; border-radius: 3px; font-size: 0.7rem; padding: 1px 5px; cursor: pointer; color: #555; }
.ph-mini:disabled { opacity: .35; cursor: default; }
.ph-actions { display: flex; gap: 8px; margin-top: 10px; align-items: center; }

/* ── Required leads checklist (Config → Members) ── */
.rl-box { max-width: 760px; border: 1px solid #E0E0E0; border-radius: 8px; padding: 10px 12px; margin-bottom: 14px; background: #fff; }
.rl-warn { border-color: #F2C94C; background: #FFFCF0; }
.rl-ok { border-color: #C5E1A5; }
.rl-head { display: flex; justify-content: space-between; align-items: baseline; font-size: 0.9rem; }
.rl-head span { font-size: 0.78rem; font-weight: 700; color: #8A6100; }
.rl-ok .rl-head span { color: #4C7A0F; }
.rl-sub { font-size: 0.76rem; color: #616161; margin: 2px 0 8px; }
.rl-table { width: 100%; border-collapse: collapse; font-size: 0.8rem; }
.rl-table th { text-align: left; font-size: 0.72rem; color: #757575; border-bottom: 1px solid #E0E0E0; padding: 4px 6px; }
.rl-table td { border-bottom: 1px solid #F2F2F2; padding: 4px 6px; }
.rl-missing { color: #B71C1C; font-weight: 600; }
.rl-note { font-size: 0.74rem; color: #8A6100; }

/* ── Integration blueprints ── */
.bp-search { max-width: 360px; }
.bp-count { font-size: 0.78rem; color: #757575; }
.bp-wrap { display: grid; grid-template-columns: minmax(260px, 360px) 1fr; gap: 0; min-height: 0; flex: 1; }
.bp-list { border-right: 1px solid #E6E6E6; overflow-y: auto; padding: 8px; display: flex; flex-direction: column; gap: 4px; max-height: calc(100vh - 170px); }
.bp-item { text-align: left; background: #fff; border: 1px solid #ECECEC; border-radius: 6px; padding: 7px 10px; cursor: pointer; display: flex; flex-direction: column; align-items: flex-start; gap: 2px; font: inherit; }
.bp-item:hover { border-color: #C5E1A5; }
.bp-on { border-color: #86BC25; background: #F6FAEE; }
.bp-name { font-weight: 600; font-size: 0.85rem; }
.bp-meta { font-size: 0.75rem; color: #616161; }
.bp-tags { display: flex; gap: 4px; flex-wrap: wrap; }
.bp-tag { font-style: normal; font-size: 0.66rem; background: #ECEFF1; color: #455A64; border-radius: 3px; padding: 0 5px; }
.bp-tag-saved { background: #E8EAF6; color: #3949AB; }
.bp-tag-rich { background: #E8F5E9; color: #2E7D32; }
.bp-tag-draft { background: #FFF3E0; color: #E65100; }
.bp-draft { background: #FFF8E1; border: 1px solid #FFE082; border-radius: 6px; padding: 8px 10px; margin: 8px 0; font-size: 0.82rem; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.bp-detail { padding: 12px 18px; overflow-y: auto; max-height: calc(100vh - 170px); min-width: 0; }
.bp-detail h2 { margin: 0; font-size: 1.15rem; }
.bp-detail h3 { font-size: 0.78rem; text-transform: uppercase; letter-spacing: .05em; color: #455A64; margin: 14px 0 4px; }
.bp-head { display: flex; justify-content: space-between; gap: 10px; align-items: center; flex-wrap: wrap; }
.bp-actions { display: flex; gap: 6px; }
.bp-facts { display: flex; gap: 16px; flex-wrap: wrap; font-size: 0.8rem; color: #424242; margin-top: 6px; }
.bp-para { white-space: pre-wrap; font-size: 0.84rem; line-height: 1.45; }
.bp-none, .bp-empty { color: #9E9E9E; font-style: italic; font-size: 0.82rem; padding: 6px 0; }
.bp-scroll { overflow-x: auto; }
.bp-q { margin: 0; padding-left: 18px; font-size: 0.84rem; }
.bp-incl { display: flex; flex-wrap: wrap; gap: 8px; }
.bp-incl-btn { border: 1px solid #D0D7DE; background: #F6F8FA; border-radius: 14px; padding: 4px 12px; font-size: 0.82rem; cursor: pointer; color: inherit; }
.bp-incl-btn:hover { background: #E8F0FE; border-color: #90B4E8; }
.bp-modal-back { position: fixed; inset: 0; background: rgba(0,0,0,0.35); z-index: 1400; display: flex; align-items: center; justify-content: center; }
.bp-modal { background: var(--mud-palette-surface, #fff); border-radius: 8px; width: min(1000px, 92vw); max-height: 82vh; display: flex; flex-direction: column; box-shadow: 0 8px 30px rgba(0,0,0,0.25); }
.bp-modal-head { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; border-bottom: 1px solid #E0E0E0; }
.bp-modal-x { border: none; background: none; font-size: 1rem; cursor: pointer; color: inherit; }
.bp-modal-body { overflow: auto; padding: 12px 16px; }
.bp-hint { margin-top: 16px; font-size: 0.78rem; color: #616161; background: #FAFAFA; border: 1px solid #EEE; border-radius: 6px; padding: 8px 10px; }
@media (max-width: 760px) { .bp-wrap { grid-template-columns: 1fr; } .bp-list { max-height: 40vh; border-right: none; border-bottom: 1px solid #E6E6E6; } }
.ie-bp { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; background: #FAFCF6; border: 1px solid #DCE9C5; border-radius: 8px; padding: 10px 14px; margin: 6px 12px; }
.ie-bp-col { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.ie-bp-row { display: flex; gap: 8px; align-items: center; justify-content: space-between; }
.ie-bp-row select, .ie-bp-row input { flex: 1; min-width: 0; }
.ie-bp-row i { color: #757575; font-size: 0.78rem; }
.ie-bp-sub { font-size: 0.76rem; color: #616161; }
@media (max-width: 860px) { .ie-bp { grid-template-columns: 1fr; } }

/* ── Build guide (integration editor) ── */
.ie-guide { background: #FCFCFA; border: 1px solid #E3E8DA; border-radius: 8px; padding: 10px 14px; margin: 6px 12px; max-height: 60vh; overflow-y: auto; }
.ie-guide-head { font-size: 0.85rem; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.ie-guide-draft { font-size: 0.66rem; font-weight: 700; text-transform: uppercase; background: #FFF4D6; color: #8A6100; border-radius: 3px; padding: 1px 6px; }
.ie-guide-link { margin-left: auto; font-size: 0.78rem; }
.ie-guide-phase { font-size: 0.7rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #5a8418; margin: 10px 0 2px; }
.ie-guide-step { display: flex; gap: 8px; padding: 5px 6px; border-radius: 6px; }
.ie-guide-step.done .ie-guide-title { color: #9E9E9E; text-decoration: line-through; }
.ie-guide-step.next { background: #F1F8E6; border: 1px solid #C5E1A5; }
.ie-guide-body { min-width: 0; }
.ie-guide-title { font-size: 0.84rem; font-weight: 600; }
.ie-guide-text { font-size: 0.8rem; color: #333; }
.ie-guide-where { font-size: 0.74rem; color: #757575; }
.ie-guide-tip { font-size: 0.76rem; color: #8A6100; }
.ie-guide-ask { display: flex; gap: 8px; margin-top: 10px; }
.ie-guide-ask input { flex: 1; min-width: 0; }
.bg-step { border-top: 1px solid #F0F0F0; padding: 8px 0; }
.bg-step-head { display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; }
.bg-phase { font-size: 0.68rem; font-weight: 700; text-transform: uppercase; color: #5a8418; min-width: 62px; }
.bg-edit { margin-left: auto; padding: 1px 8px !important; font-size: 0.72rem !important; }
.bg-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.bg-grid label { display: flex; flex-direction: column; gap: 3px; font-size: 0.74rem; font-weight: 600; color: #555; }
.bg-wide { grid-column: 1 / -1; }
.bg-q { border: 1px solid #ECECEC; border-radius: 6px; padding: 8px 10px; margin-bottom: 6px; font-size: 0.84rem; }
.bg-ans { width: 100%; margin-top: 6px; border: 1px solid #CFD6DC; border-radius: 6px; padding: 6px 10px; font-family: inherit; font-size: .85rem; }

.ie-guide-row { display: flex; gap: 6px; align-items: center; }
.ie-guide-toggle { background: none; border: none; cursor: pointer; color: #757575; width: 18px; padding: 0; }
.ie-guide-row .ie-guide-title { flex: 1; min-width: 0; }
.ie-guide-status { font-size: 0.74rem; padding: 1px 4px; border: 1px solid #D0D0D0; border-radius: 4px; background: #fff; }
.ie-guide-badge { font-size: 0.68rem; font-weight: 700; border-radius: 3px; padding: 1px 6px; background: #E8F5E9; color: #2E7D32; }
.ie-guide-step.st-blocked { background: #FDECEC; }
.ie-guide-step.st-in_progress .ie-guide-title { color: #1565C0; }
.ie-guide-step.st-na .ie-guide-title { color: #9E9E9E; font-style: italic; text-decoration: none; }
.ie-guide-body { flex: 1; }
.ie-guide-why { font-size: 0.8rem; color: #37474F; margin: 2px 0 2px 24px; }
.ie-guide-text, .ie-guide-where, .ie-guide-tip, .ie-guide-src, .ie-guide-stop { margin-left: 24px; }
.ie-guide-items { list-style: none; margin: 4px 0 4px 24px; padding: 0; font-size: 0.8rem; }
.ie-guide-items li label { display: flex; gap: 6px; align-items: flex-start; }
.ie-guide-items li.val i { color: #5a8418; font-style: normal; font-weight: 600; }
.ie-guide-stop { font-size: 0.78rem; color: #B71C1C; }
.ie-guide-src { font-size: 0.7rem; color: #9E9E9E; }
.ie-guide-note { margin: 4px 0 2px 24px; width: calc(100% - 24px); font-size: 0.78rem; padding: 3px 6px; border: 1px solid #DDD; border-radius: 4px; }

/* Live EKG on the Pulse icon: a bright trace draws across a faint baseline with a dot riding the peak;
   each time the line refreshes it beats bold, then settles. */
.ekg-live { overflow: visible; }
.ekg-live .ekg-base  { opacity: .35; animation: ekg-beat 2.4s linear infinite; }
.ekg-live .ekg-trace { stroke-dasharray: 100; stroke-dashoffset: 100; animation: ekg-draw 2.4s linear infinite, ekg-beat 2.4s linear infinite; }
.ekg-live .ekg-dot   { offset-path: path("M2 12 H14 L18 4 L24 20 L30 8 L36 16 L42 12 H58"); offset-rotate: 0deg;
                       filter: drop-shadow(0 0 2px #fff); animation: ekg-ride 2.4s linear infinite; }
@keyframes ekg-draw { 0% { stroke-dashoffset: 100; opacity: 1; } 75% { stroke-dashoffset: 0; opacity: 1; } 92% { stroke-dashoffset: 0; opacity: 1; } 100% { stroke-dashoffset: 0; opacity: 0; } }
@keyframes ekg-ride { 0% { offset-distance: 0%; opacity: 1; } 75% { offset-distance: 100%; opacity: 1; } 80%, 100% { offset-distance: 100%; opacity: 0; } }
@keyframes ekg-beat { 0%, 80% { stroke-width: 2.6; } 85% { stroke-width: 3.6; } 94%, 100% { stroke-width: 2.6; } }
@media (prefers-reduced-motion: reduce) {
    .ekg-live .ekg-base, .ekg-live .ekg-trace, .ekg-live .ekg-dot { animation: none; }
    .ekg-live .ekg-base { opacity: 1; } .ekg-live .ekg-trace { stroke-dashoffset: 0; } .ekg-live .ekg-dot { display: none; }
}
body.ie-dragging, body.ie-dragging * { user-select: none !important; }

.stab-lib { position: relative; display: inline-block; }
.stab-lib-menu { position: absolute; top: 100%; left: 0; z-index: 30; background: var(--mud-palette-surface, #fff); border: 1px solid #DDE3E7; border-radius: 6px; box-shadow: 0 4px 14px rgba(0,0,0,.12); min-width: 190px; padding: 4px 0; }
.stab-lib-menu a { display: block; padding: 7px 14px; font-size: .85rem; color: inherit; text-decoration: none; }
.stab-lib-menu a:hover { background: #F2F5F7; }
.ie-tpl-best { margin-left: 6px; font-size: .68rem; font-weight: 600; color: #00796B; background: #E0F2F1; border-radius: 8px; padding: 1px 6px; vertical-align: 1px; }

/* Inventory grid: dropdown column filters and header drag-to-move */
#grid-integrations .inv-filter { width: 100%; font: inherit; font-size: 12px; padding: 3px 4px; border: 1px solid var(--mud-palette-lines-default); border-radius: 4px; background: var(--mud-palette-surface); color: var(--mud-palette-text-primary); }
#grid-integrations thead th[draggable="true"] { cursor: grab; }
#grid-integrations thead th.col-dragging { opacity: .5; }
#grid-integrations thead th.col-drop { box-shadow: inset 3px 0 0 var(--mud-palette-primary); }

/* Inventory grid: frozen ID / Integration columns (placed by fabricFreeze) and the clear-filters button */
#grid-integrations .col-frozen { position: sticky; z-index: 2; background: var(--mud-palette-surface); }
#grid-integrations thead .col-frozen { z-index: 4; }
#grid-integrations .col-frozen-last { box-shadow: 2px 0 3px -1px rgba(0,0,0,.18); }
#grid-integrations .inv-clear { display: flex; align-items: center; justify-content: center; width: 100%; height: 28px; border: none; background: none; color: var(--mud-palette-text-secondary); cursor: pointer; border-radius: 4px; }
#grid-integrations .inv-clear:hover { background: var(--mud-palette-action-default-hover); color: var(--mud-palette-error); }
#grid-integrations .inv-clear:disabled { opacity: .3; cursor: default; background: none; color: var(--mud-palette-text-secondary); }
#grid-integrations .inv-clear.on { color: var(--mud-palette-primary); }

/* ── DP Flow, the delivery pool (migration 152). Screens fit a 15-inch laptop; lists fill the screen and scroll inside, headers frozen. ── */
.dp { height: calc(100vh - 16px); display: flex; flex-direction: column; gap: 10px; padding: 8px 4px 0; box-sizing: border-box; color: #263238; font-size: 13px; }
.dp *, .dp *::before, .dp *::after { box-sizing: border-box; }
.dp-top { display: flex; align-items: center; gap: 4px; border-bottom: 2px solid #7CB342; padding-bottom: 6px; flex-wrap: wrap; }
.dp-top .dp-title { font-weight: 700; color: #33691E; font-size: 15px; margin-right: 12px; }
.dp-top button.dp-tab { border: 0; background: none; font: inherit; padding: 5px 11px; border-radius: 5px; cursor: pointer; color: #546E7A; white-space: nowrap; }
.dp-top button.dp-tab.on { background: #7CB342; color: #fff; font-weight: 600; }
.dp-top .dp-badge { display: inline-block; min-width: 17px; padding: 0 5px; margin-left: 5px; border-radius: 9px; font-size: 10.5px; background: #ECEFF1; color: #455A64; }
.dp-top button.dp-tab.on .dp-badge { background: rgba(255,255,255,.3); color: #fff; }
.dp-top .dp-proj { margin-left: auto; font-size: 11.5px; color: #90A4AE; }
.dp-screen { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 10px; padding-bottom: 8px; }
.dp-card { background: #fff; border: 1px solid #dfe5dc; border-radius: 8px; padding: 10px 12px; }
.dp-fill { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.dp-list { flex: 1; min-height: 0; overflow-y: scroll; overflow-x: auto; border: 1px solid #eceff1; border-radius: 6px; }
.dp-list::-webkit-scrollbar, .dp-cards::-webkit-scrollbar { width: 10px; height: 10px; }
.dp-list::-webkit-scrollbar-track, .dp-cards::-webkit-scrollbar-track { background: #F1F3F0; }
.dp-list::-webkit-scrollbar-thumb, .dp-cards::-webkit-scrollbar-thumb { background: #B0BEC5; border-radius: 5px; border: 2px solid #F1F3F0; }
.dp-list::-webkit-scrollbar-thumb:hover { background: #90A4AE; }
.dp-sec { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #7CB342; margin: 0 0 6px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.dp-sec .dp-muted { text-transform: none; letter-spacing: 0; font-weight: 400; }
.dp-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px 12px; }
.dp label.dp-f { display: flex; flex-direction: column; gap: 2px; font-size: 11px; color: #78909C; min-width: 0; }
.dp select, .dp input, .dp textarea { font: inherit; font-size: 13px; padding: 4px 8px; border: 1px solid #cfd8dc; border-radius: 5px; background: #fff; color: #263238; min-width: 0; }
.dp input[type=checkbox] { padding: 0; }
.dp textarea { height: 34px; resize: vertical; }
.dp table.dp-t { width: 100%; border-collapse: collapse; }
.dp-t th, .dp-t td { text-align: left; padding: 6px 8px; border-bottom: 1px solid #eceff1; vertical-align: top; }
.dp-t th { font-size: 11px; color: #78909C; text-transform: uppercase; position: sticky; top: 0; background: #fff; z-index: 2; box-shadow: 0 1px 0 #dfe5dc; white-space: nowrap; font-weight: 600; }
.dp-t td select { width: 100%; }
.dp-t td.dp-name { max-width: 420px; line-height: 1.35; }
.dp button.dp-btn { display: inline-block; padding: 4px 12px; border-radius: 5px; border: 1px solid #7CB342; color: #33691E; background: #fff; font: inherit; font-weight: 600; font-size: 12px; white-space: nowrap; cursor: pointer; }
.dp button.dp-btn.pri { background: #7CB342; color: #fff; }
.dp button.dp-btn.warn { border-color: #E65100; color: #E65100; }
.dp button.dp-btn.sm { padding: 2px 9px; font-weight: 500; }
.dp button.dp-btn:disabled { opacity: .5; cursor: default; }
.dp button.dp-x { border: 0; background: none; color: #90A4AE; cursor: pointer; font-size: 14px; }
.dp-bar { display: flex; justify-content: flex-end; gap: 6px; align-items: center; flex-wrap: wrap; }
.dp-tag { font-size: 10.5px; padding: 2px 7px; border-radius: 10px; background: #ECEFF1; white-space: nowrap; }
.dp-tag.blk { background: #FFEBEE; color: #C62828; } .dp-tag.warn { background: #FFF3E0; color: #E65100; } .dp-tag.dp-blue { background: #E3F2FD; color: #1565C0; }
.dp-muted { color: #90A4AE; font-size: 11.5px; }
.dp-hist { font-size: 10.5px; color: #1565C0; }
.dp-chip { font-size: 11px; padding: 2px 8px; border-radius: 12px; background: #F5F7F4; border: 1px solid #dfe5dc; white-space: nowrap; display: inline-block; margin: 1px 2px 1px 0; }
.dp-meter { height: 6px; background: #ECEFF1; border-radius: 3px; overflow: hidden; display: block; margin-top: 3px; min-width: 60px; }
.dp-meter i { display: block; height: 100%; background: #90A4AE; } .dp-meter i.over { background: #E65100; }
.dp-kpis { display: flex; gap: 8px; flex-wrap: wrap; }
.dp-kpi { background: #fff; border: 1px solid #dfe5dc; border-radius: 8px; padding: 5px 12px; }
.dp-kpi b { font-size: 16px; margin-right: 6px; } .dp-kpi.dp-red b { color: #C62828; } .dp-kpi.dp-amber b { color: #E65100; }
.dp-who { font-size: 10px; color: #6A1B9A; background: #F3E5F5; border-radius: 4px; padding: 1px 5px; text-transform: none; letter-spacing: 0; font-weight: 500; }
.dp-err { background: #FFEBEE; border: 1px solid #FFCDD2; color: #B71C1C; border-radius: 6px; padding: 7px 10px; font-size: 12.5px; }
.dp-ok { background: #F1F8E9; border: 1px solid #C5E1A5; color: #33691E; border-radius: 6px; padding: 7px 10px; font-size: 12.5px; }
.dp-empty { padding: 28px 16px; text-align: center; color: #90A4AE; }
.dp-split { flex: 1; min-height: 0; display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 10px; }
.dp-q { padding: 8px 10px; border-bottom: 1px solid #eceff1; cursor: pointer; display: grid; grid-template-columns: 10px 1fr auto; gap: 2px 8px; align-items: start; }
.dp-q:hover { background: #FAFBF9; }
.dp-q.on { background: #F1F8E9; box-shadow: inset 3px 0 #7CB342; }
.dp-q .t { font-weight: 600; } .dp-q .m { grid-column: 2; color: #90A4AE; font-size: 11.5px; } .dp-q .d { color: #78909C; font-size: 11.5px; white-space: nowrap; }
.dp-dot { width: 8px; height: 8px; border-radius: 50%; margin-top: 5px; background: #CFD8DC; display: inline-block; }
.dp-dot.r { background: #C62828; } .dp-dot.a { background: #F9A825; }
.dp-legend { display: flex; gap: 10px; font-size: 11px; color: #78909C; text-transform: none; letter-spacing: 0; font-weight: 400; margin-left: auto; }
.dp-legend .dp-dot { margin: 0 4px 0 0; vertical-align: middle; }
.dp-right { display: flex; flex-direction: column; gap: 8px; min-height: 0; }
.dp-seg { display: inline-flex; border: 1px solid #7CB342; border-radius: 5px; overflow: hidden; margin-left: auto; }
.dp-seg button { border: 0; background: #fff; padding: 2px 10px; font: inherit; font-size: 12px; cursor: pointer; color: #33691E; }
.dp-seg button.on { background: #7CB342; color: #fff; }
.dp-board { flex: 1; min-height: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.dp-col { background: #F5F7F4; border-radius: 6px; display: flex; flex-direction: column; min-height: 0; }
.dp-col h4 { margin: 0; padding: 7px 8px; font-size: 11px; text-transform: uppercase; color: #78909C; border-bottom: 1px solid #dfe5dc; }
.dp-cards { flex: 1; min-height: 0; overflow-y: scroll; padding: 6px; }
.dp-pc { background: #fff; border: 1px solid #dfe5dc; border-radius: 6px; padding: 6px; margin-bottom: 6px; font-size: 12px; cursor: pointer; }
.dp-pc b { display: block; } .dp-pc.blk { border-left: 3px solid #C62828; }
.dp-dash { flex: 1; min-height: 0; display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; gap: 10px; }
.dp-dash .wide { grid-column: span 2; }
.dp-prog { display: flex; align-items: center; gap: 14px; white-space: nowrap; }
.dp-pips { display: inline-flex; gap: 3px; } .dp-pips i { width: 16px; height: 4px; border-radius: 2px; background: #E0E4E2; } .dp-pips i.d { background: #78909C; }
.dp-t tr.dp-job td { background: #F7F8F6; font-weight: 600; color: #455A64; position: sticky; top: 29px; z-index: 1; border-bottom: 1px solid #dfe5dc; }
.dp-t tr.dp-job .dp-muted { font-weight: 400; }
.dp-t tr.act td { background: #FFFDF6; } .dp-t tr.act td:first-child { box-shadow: inset 3px 0 #F9A825; }
.dp-t tr.blk td { background: #FFF8F8; } .dp-t tr.blk td:first-child { box-shadow: inset 3px 0 #C62828; }
.dp-need { font-weight: 600; font-size: 12px; } .dp-need.r { color: #C62828; } .dp-need.a { color: #B26A00; }
.dp-filters { display: flex; gap: 6px; align-items: center; margin-left: auto; }
.dp-filters button { font: inherit; font-size: 12px; padding: 2px 10px; border: 1px solid #dfe5dc; border-radius: 12px; color: #546E7A; cursor: pointer; background: #fff; }
.dp-filters button.on { border-color: #7CB342; background: #F1F8E9; color: #33691E; }
.dp-pop { position: fixed; inset: 0; background: rgba(38,50,56,.35); z-index: 1300; display: flex; align-items: center; justify-content: center; }
.dp-pop > div { background: #fff; border-radius: 10px; padding: 16px 18px; width: min(560px, 94vw); max-height: 90vh; overflow: auto; display: flex; flex-direction: column; gap: 10px; box-shadow: 0 10px 30px rgba(0,0,0,.2); }
.dp-pop h3 { margin: 0; font-size: 15px; color: #33691E; }
.dp-pop pre { white-space: pre-wrap; font: inherit; font-size: 12.5px; background: #F7F8F6; border: 1px solid #eceff1; border-radius: 6px; padding: 10px; margin: 0; }
.dp-switch { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
.dp-pc[draggable=true] { cursor: grab; } .dp-pc.dp-dragging { opacity: .45; }
.dp-col.dp-drop { background: #F1F8E9; box-shadow: inset 0 0 0 2px #7CB342; }

/* DP Flow: stronger contrast for list, New Job and dashboard; larger KPI tiles */
.dp-muted { color: #607D8B; }
.dp-card { border-color: #C9D3C4; box-shadow: 0 1px 2px rgba(38,50,56,.06); }
.dp-list { border-color: #D5DCD1; }
.dp-t th { color: #455A64; box-shadow: 0 1px 0 #C9D3C4; }
.dp-t th, .dp-t td { border-bottom-color: #E0E5DD; }
.dp-t td { color: #263238; }
.dp label.dp-f { color: #455A64; font-weight: 600; }
.dp select, .dp input, .dp textarea { border-color: #B0BEC5; color: #263238; font-weight: 400; }
.dp-sec { color: #558B2F; }
.dp-tag { background: #E3E8EA; color: #37474F; }
.dp-chip { background: #EEF2EC; border-color: #C9D3C4; color: #37474F; }
.dp-meter { background: #DDE3E6; } .dp-meter i { background: #607D8B; }
.dp-kpis { gap: 10px; }
.dp-kpi { flex: 1 1 150px; padding: 10px 16px; border: 1px solid #C9D3C4; border-left: 4px solid #7CB342; box-shadow: 0 1px 3px rgba(38,50,56,.08); display: flex; flex-direction: column; gap: 2px; }
.dp-kpi b { font-size: 24px; line-height: 1.15; color: #263238; margin-right: 0; }
.dp-kpi .dp-muted { font-size: 12px; color: #546E7A; }
.dp-kpi.dp-red { border-left-color: #C62828; } .dp-kpi.dp-amber { border-left-color: #E65100; }
.dp-split { grid-template-columns: var(--dp-q, 300px) 8px minmax(0, 1fr); gap: 0; }
.dp-splitter { cursor: col-resize; position: relative; }
.dp-splitter::after { content: ""; position: absolute; top: 0; bottom: 0; left: 3px; width: 2px; border-radius: 1px; background: #DDE3D9; }
.dp-splitter:hover::after, .dp-splitter.on::after { background: #7CB342; }
/* KPI tiles: one row of equal tiles, a little smaller, clear of the window edge */
.dp-screen { padding-right: 12px; }
.dp-kpis { flex-wrap: nowrap; gap: 8px; }
.dp-kpi { flex: 1 1 0; min-width: 0; padding: 7px 12px; }
.dp-kpi b { font-size: 20px; white-space: nowrap; }
.dp-kpi .dp-muted { font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* Leave the bottom-right corner free for the Pulse button when it shows */
body:has(.chat-wrap) .dp-screen { padding-bottom: 76px; }
/* DP Flow project grid: sortable headers and a filter row, like the inventory grid */
.dp-t th.dp-sortable { cursor: pointer; user-select: none; }
.dp-t th.dp-sortable:hover { color: #33691E; }
.dp-t .dp-sort { margin-left: 4px; font-size: 9px; color: #558B2F; }
.dp-t th.dp-cx, .dp-t td.dp-cx { width: 28px; padding-left: 4px; padding-right: 0; }
.dp-t tr.dp-frow th { top: 29px; text-transform: none; padding-top: 2px; padding-bottom: 6px; }
.dp-t tr.dp-frow input, .dp-t tr.dp-frow select { width: 100%; font-size: 12px; padding: 3px 4px; }
.dp-t tr.dp-job td { top: 65px; }
.dp button.dp-clear { border: 0; background: none; cursor: pointer; color: #90A4AE; font-size: 12px; width: 22px; height: 24px; border-radius: 4px; }
.dp button.dp-clear.on { color: #558B2F; }
.dp button.dp-clear.on:hover { color: #C62828; background: #FFEBEE; }
.dp button.dp-clear:disabled { opacity: .35; cursor: default; }

/* DP Flow settings */
.dp-subtabs { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.dp button.dp-sub { padding: 4px 12px; border-radius: 14px; border: 1px solid #CFD8DC; background: #fff; font: inherit; font-size: 12px; cursor: pointer; color: #455A64; }
.dp button.dp-sub.on { background: #7CB342; border-color: #7CB342; color: #fff; font-weight: 600; }
.dp button.dp-link { border: none; background: none; color: #1565C0; text-decoration: underline; cursor: pointer; font: inherit; padding: 0; }
.dp-t tr.dp-sel td { background: #F1F8E9; }
.dp-chip .dp-yr { width: 58px; margin-left: 4px; padding: 0 2px; font-size: 11px; }
.dp select.dp-addcert { width: auto; font-size: 11px; padding: 1px 4px; }
/* DP project view: roomier rows, with a gap above each Job heading */
.dp-pv { gap: 14px; }
.dp-pv .dp-t td { padding: 10px 10px; vertical-align: middle; line-height: 1.35; }
.dp-pv .dp-t tr.dp-job td { padding: 14px 10px 9px; }
.dp-pv .dp-t tbody tr.dp-job:not(:first-child) td { border-top: 10px solid #fff; }

/* Integration trend widgets (IntegrationTrendWidget) */
.itr{padding:10px 14px 12px;height:100%;box-sizing:border-box;overflow:auto;font-family:inherit}
.itr-head{display:flex;align-items:center;gap:8px;flex-wrap:wrap;padding-right:44px}
.itr-pill{font-size:11px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;padding:3px 9px;border-radius:7px;white-space:nowrap}
.itr-pill.sm{font-size:9px;padding:2px 6px}
.itr-pill.d{background:#ede9fe;color:#6d28d9}.itr-pill.b{background:#e0f2fe;color:#0369a1}.itr-pill.a{background:#fef3c7;color:#b45309}
.itr-ms{font-size:11px;color:#64748b}
.itr-k{display:flex;gap:8px;margin:10px 0 4px}
.itr-kp{flex:1;background:#f8fafc;border-radius:10px;padding:7px 10px;min-width:0}
.itr-kp.ring{display:flex;align-items:center;gap:8px}
.itr-kp-link{text-decoration:none;color:inherit;cursor:pointer}.itr-kp-link:hover{background:#f3e8ff}
.itr-kp b{display:block;font-size:19px;font-weight:700;line-height:1.2;color:#0f172a}
.itr-kp span{font-size:11px;color:#64748b}
.itr-kp b.neg{color:#dc2626}.itr-kp b.warn{color:#d97706}
.itr-svg{display:block}
.itr-lg{display:flex;gap:12px;font-size:11px;color:#475569;flex-wrap:wrap;margin-top:2px}
.itr-lg i{display:inline-block;width:16px;border-top:2px solid;vertical-align:middle;margin-right:4px}
.itr-warn{color:#b45309}
.itr-empty{font-size:12px;color:#64748b;padding:18px 4px}
a.itr-q{display:flex;align-items:center;gap:10px;padding:9px 0;border-bottom:1px solid #f1f5f9;text-decoration:none;color:#0f172a}
a.itr-q:last-child{border:0}a.itr-q:hover{background:#f8fafc}
.itr-qn{flex:1;font-size:13px;min-width:0}.itr-qn small{display:block;color:#64748b;font-size:11px}
.itr-bar{width:110px;height:6px;background:#f1f5f9;border-radius:4px;overflow:hidden;flex-shrink:0}
.itr-bar i{display:block;height:100%;border-radius:4px}
a.itr-q b{width:52px;text-align:right;font-size:12px}

/* Dashboard widget resize handle + ghost */
.db-widget-resize{position:absolute;right:0;bottom:0;width:16px;height:16px;cursor:nwse-resize;z-index:5;
  background:linear-gradient(135deg,transparent 50%,#94a3b8 50%,#94a3b8 58%,transparent 58%,transparent 70%,#94a3b8 70%,#94a3b8 78%,transparent 78%);opacity:0;transition:opacity .15s}
.db-widget:hover .db-widget-resize{opacity:1}
.db-resize-ghost{position:fixed;z-index:9999;pointer-events:none;border-radius:8px;border:2px solid #1976D2;background:rgba(25,118,210,.12)}
.db-resize-ghost.bad{border-color:#ec4899;background:rgba(236,72,153,.16)}
.db-resize-ghost span{position:absolute;right:6px;bottom:4px;font:600 11px Segoe UI,sans-serif;color:#1976D2}
.db-resize-ghost.bad span{color:#db2777}
body.db-resizing, body.db-resizing *{cursor:nwse-resize !important;user-select:none}

/* Pool dashboard: higher contrast */
.dp-hc { color: #1F2A30; }
.dp-hc .dp-muted { color: #455A64; }
.dp-hc .dp-card, .dp-hc .dp-kpi { border-color: #A9B8A2; box-shadow: 0 1px 3px rgba(38,50,56,.12); }
.dp-hc .dp-kpi { border-left-color: #558B2F; }
.dp-hc .dp-kpi.dp-red { border-left-color: #B71C1C; background: #FFF5F5; } .dp-hc .dp-kpi.dp-red b { color: #B71C1C; }
.dp-hc .dp-kpi.dp-amber { border-left-color: #BF360C; background: #FFF8F0; } .dp-hc .dp-kpi.dp-amber b { color: #BF360C; }
.dp-hc .dp-kpi b { color: #102027; }
.dp-hc .dp-kpi .dp-muted { color: #37474F; font-weight: 500; }
.dp-hc .dp-sec { color: #33691E; font-size: 12px; }
.dp-hc .dp-sec .dp-muted { color: #455A64; }
.dp-hc .dp-t th { color: #263238; background: #EEF2EC; box-shadow: 0 1px 0 #A9B8A2; }
.dp-hc .dp-t th, .dp-hc .dp-t td { border-bottom-color: #D3DBCF; }
.dp-hc .dp-t td { color: #1F2A30; }
.dp-hc .dp-t tbody tr:nth-child(even) td { background: #F8FAF7; }
.dp-hc .dp-tag { background: #CFD8DC; color: #263238; font-weight: 600; }
.dp-hc .dp-tag.blk { background: #C62828; color: #fff; }
.dp-hc .dp-tag.warn { background: #E65100; color: #fff; }
.dp-hc .dp-tag.dp-blue { background: #1565C0; color: #fff; }
.dp-hc .dp-meter { background: #CFD8DC; height: 8px; } .dp-hc .dp-meter i { background: #37474F; } .dp-hc .dp-meter i.over { background: #C62828; }
.dp-filters { margin-left: auto; display: inline-flex; gap: 8px; align-items: center; text-transform: none; letter-spacing: 0; font-weight: 400; color: #37474F; font-size: 12px; }
.dp-filters input:not([type=checkbox]) { width: 180px; font-size: 12px; padding: 3px 6px; }
.dp-filters select { font-size: 12px; padding: 3px 4px; }
.dp-filters label { display: inline-flex; gap: 4px; align-items: center; white-space: nowrap; }
.dp-t tr.dp-rowpick { cursor: pointer; } .dp-t tr.dp-rowpick:hover td { background: #F1F8E9; }
/* The chip and checklist icons draw small next to the other group icons. */
.nav-tech > .mud-nav-link > .mud-nav-link-icon,
.nav-test > .mud-nav-link > .mud-nav-link-icon { transform: scale(1.25); }

/* Greyed-out sidebar links (workstream off for the project) ignore the mouse, so the rail's tooltip never showed.
   They have no href, so letting hover through can't navigate. */
.bp-rail .sidebar .mud-nav-link-disabled { pointer-events: auto; cursor: default; }

/* Dashboard KPIs that open another Delivery Pool tab. */
.dp-kpi.dp-link { cursor: pointer; } .dp-kpi.dp-link:hover { border-color: #7CB342; background: #F1F8E9; }

/* Delivery pipeline drill-downs (PipelineDesignDrill / PipelineStageDrill) */
    .pdd { border: 1px solid #E0E5DC; border-top: 3px solid #86BC25; border-radius: 8px; background: #fff; padding: 14px 16px; margin-top: 10px; }
    .pdd-hd { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 10px; font-size: 15px; }
    .pdd-muted { color: #78909C; font-size: 12px; font-weight: 400; }
    .pdd-steps { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; margin-bottom: 14px; }
    .pdd-s { border: 1px solid #E0E5DC; border-radius: 6px; padding: 10px; cursor: pointer; }
    .pdd-s:hover { border-color: #86BC25; }
    .pdd-s.on { outline: 2px solid #86BC25; }
    .pdd-s h4 { margin: 0 0 4px; font-size: 12px; text-transform: uppercase; letter-spacing: .4px; color: #43B02A; }
    .pdd-s.warn { border-color: #F3C4C4; background: #FFF7F7; } .pdd-s.warn h4 { color: #C62828; }
    .pdd-n { font-size: 24px; font-weight: 700; } .pdd-n small { font-size: 13px; color: #90A4AE; font-weight: 400; }
    .pdd-pct { font-size: 14px; font-weight: 700; color: #43B02A; margin-left: 6px; }
    .pdd-s.warn .pdd-pct { color: #C62828; }
    .pdd-s { position: relative; }
    .pdd-s h4 { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
    .pdd-q { flex: none; display: inline-grid; place-items: center; width: 16px; height: 16px; border-radius: 50%; border: 1px solid #9CA3AF; color: #6B7280; font-size: 11px; font-weight: 700; cursor: pointer; text-transform: none; }
    .pdd-q:hover { background: #F3F4F6; color: #111; }
    .pdd-help { position: absolute; top: 34px; left: 8px; width: 300px; max-width: 80vw; z-index: 20; background: #fff; border: 1px solid #D1D5DB; border-radius: 8px; box-shadow: 0 8px 24px rgba(0,0,0,.15); padding: 10px 28px 10px 12px; font-size: 12.5px; font-weight: 400; color: #374151; white-space: pre-line; line-height: 1.4; cursor: default; }
    .pdd-steps > .pdd-s:nth-last-child(-n+2) .pdd-help { left: auto; right: 8px; }
    .pdd-help-x { position: absolute; top: 4px; right: 4px; border: 0; background: none; cursor: pointer; color: #6B7280; }
    .pdd-sub { font-size: 11.5px; color: #607D8B; margin-top: 4px; }
    .pdd-funnel { display: flex; height: 20px; border-radius: 4px; overflow: hidden; font-size: 11px; color: #fff; font-weight: 600; margin-top: 6px; }
    .pdd-funnel div { display: flex; align-items: center; justify-content: center; min-width: 16px; }
    .pdd-cap { font-size: 12px; font-weight: 700; color: #546E7A; text-transform: uppercase; letter-spacing: .4px; margin-bottom: 6px; }
    .pdd-list table { width: 100%; border-collapse: collapse; font-size: 13px; }
    /* The integrations list scrolls inside the drill; its header and filter rows stay put. */
    .pdd-list .dtb { max-height: 62vh; overflow: auto; }
    .pdd-list .dtb thead { position: sticky; top: 0; z-index: 2; background: #fff; }
    .pdd-list .dtb thead th { background: #F1F3F0; }
    .pdd-list .dtb thead .dtb-frow th { background: #fff; }
    .pdd-list th { background: #F1F3F0; text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: .4px; color: #546E7A; padding: 7px 8px; white-space: nowrap; }
    .pdd-list td { padding: 7px 8px; border-bottom: 1px solid #EEF1EC; }
    .pdd-list td a { color: #2E7D32; font-weight: 600; margin-right: 4px; }
    .pdd-list .n { text-align: right; } .pdd-list td.late { color: #C62828; font-weight: 700; }
    .pdd-pill { display: inline-block; padding: 2px 8px; border-radius: 10px; font-size: 11.5px; font-weight: 600; white-space: nowrap; }
    .pdd-pill.g { background: #E8F5E9; color: #2E7D32; } .pdd-pill.a { background: #FFF4D6; color: #8A6200; }
    .pdd-pill.r { background: #FDECEC; color: #C62828; } .pdd-pill.x { background: #ECEFF1; color: #607D8B; }
    .pdd-tag { font-size: 11px; background: #FFF4D6; color: #8A6200; border-radius: 4px; padding: 1px 6px; margin-left: 6px; }
    .pdd-foot { margin-top: 10px; }
    @media (max-width: 1100px) { .pdd-steps { grid-template-columns: repeat(3, 1fr); } }
/* DrillTable: same look as the Integrations inventory grid (title-case headers, filter row, click to sort) */
.dtb { overflow-x: auto; }
.dtb table { width: 100%; border-collapse: collapse; font-size: 13px; }
.dtb thead th { position: sticky; top: 0; background: var(--mud-palette-surface, #fff); text-align: left; font-size: 13px; font-weight: 600; color: var(--mud-palette-text-primary, #263238); padding: 8px; border-bottom: 1px solid var(--mud-palette-lines-default, #E0E0E0); white-space: nowrap; cursor: pointer; text-transform: none; letter-spacing: 0; }
.dtb thead th:hover { background: var(--mud-palette-action-default-hover, #F5F5F5); }
.dtb thead .dtb-frow th { cursor: default; padding: 4px 8px 8px; font-weight: 400; }
.dtb thead .dtb-frow th:hover { background: var(--mud-palette-surface, #fff); }
.dtb .dtb-frow input, .dtb .dtb-frow select { width: 100%; min-width: 60px; font: inherit; font-size: 12px; padding: 3px 4px; border: 1px solid var(--mud-palette-lines-default, #E0E0E0); border-radius: 4px; background: var(--mud-palette-surface, #fff); color: var(--mud-palette-text-primary); }
.dtb .dtb-sort { color: #43B02A; font-size: 11px; }
.dtb td { padding: 8px; border-bottom: 1px solid #EEF1EC; }
.dtb td a { color: #2E7D32; font-weight: 600; margin-right: 4px; }
.dtb .n { text-align: right; } .dtb td.late { color: #C62828; font-weight: 700; }
.dtb-clear { margin-top: 6px; border: none; background: none; color: #43B02A; font-weight: 600; font-size: 12px; cursor: pointer; }
.dtb .dtb-x { width: 34px; padding-left: 2px; padding-right: 2px; }
.dtb .inv-clear { display: flex; align-items: center; justify-content: center; width: 100%; height: 28px; border: none; background: none; color: var(--mud-palette-text-secondary); cursor: pointer; border-radius: 4px; }
.dtb .inv-clear:hover { background: var(--mud-palette-action-default-hover); color: var(--mud-palette-error); }
.dtb .inv-clear:disabled { opacity: .3; cursor: default; background: none; }
.dtb .inv-clear.on { color: var(--mud-palette-primary); }

/* Inventory row count in the menu bar; highlighted when filters narrow the list. */
.inv-count { font-size: 12px; color: #616161; margin-right: 12px; white-space: nowrap; flex-shrink: 0; }
.inv-count.on { color: #1565C0; font-weight: 600; }

/* Inventory filter panel (docs/mockups/inventory-filter-panel.png) */
.invf-btn { display:inline-flex; align-items:center; gap:4px; border:1px solid #c5cbbf; background:#fff; border-radius:5px; padding:3px 10px; font:inherit; font-size:13px; cursor:pointer; margin-left:8px; }
.invf-btn.on { background:#eef5e6; border-color:#689f38; color:#33691e; font-weight:600; }
.invf-badge { background:#689f38; color:#fff; border-radius:9px; padding:0 7px; font-size:11px; }
.invf-saved { border:1px solid #c5cbbf; border-radius:5px; padding:3px 6px; font:inherit; font-size:13px; margin-left:6px; background:#fff; }
.invf-panel { background:#fff; border:1px solid #dde3d8; border-radius:8px; padding:12px 16px; margin:6px 0 8px; box-shadow:0 6px 16px rgba(0,0,0,.06); max-width:980px; }
.invf-head { display:flex; align-items:center; gap:10px; margin-bottom:8px; flex-wrap:wrap; }
.invf-title { font-size:13px; letter-spacing:.06em; color:#689f38; text-transform:uppercase; font-weight:700; }
.invf-muted { color:#78909c; font-size:12px; }
.invf-seg { display:inline-flex; border:1px solid #c5cbbf; border-radius:5px; overflow:hidden; }
.invf-seg button { border:0; background:#fff; padding:3px 12px; font:inherit; font-size:12px; cursor:pointer; }
.invf-seg button.on { background:#689f38; color:#fff; }
.invf-t { width:100%; border-collapse:collapse; }
.invf-t th { font-size:11px; text-transform:uppercase; color:#78909c; text-align:left; font-weight:600; padding:4px 6px; border-bottom:1px solid #e5e9e1; }
.invf-t td { padding:5px 6px; border-bottom:1px solid #f0f2ee; vertical-align:middle; }
.invf-t select, .invf-t input { border:1px solid #c5cbbf; border-radius:4px; padding:4px 6px; font:inherit; font-size:13px; width:100%; box-sizing:border-box; background:#fff; }
.invf-chips { display:flex; flex-wrap:wrap; gap:4px; align-items:center; border:1px solid #c5cbbf; border-radius:4px; padding:3px 5px; min-height:30px; box-sizing:border-box; }
.invf-chip { background:#eef5e6; border:1px solid #c5e1a5; border-radius:10px; padding:1px 8px; font-size:12px; white-space:nowrap; }
.invf-chip b { color:#78909c; font-weight:400; margin-left:4px; cursor:pointer; }
.invf-t .invf-add { border:0 !important; width:auto !important; color:#90a4ae; padding:1px 2px !important; }
.invf-two { display:flex; gap:6px; align-items:center; }
.invf-two input { width:140px !important; }
.invf-x { border:0; background:none; color:#b0bec5; font-size:17px; cursor:pointer; }
.invf-x:hover { color:#c62828; }
.invf-addrow { border:0; background:none; color:#689f38; font-weight:600; padding:8px 0 0; cursor:pointer; font:inherit; }
.invf-foot { display:flex; gap:8px; align-items:center; justify-content:flex-end; margin-top:10px; flex-wrap:wrap; }
.invf-foot > .invf-muted { margin-right:auto; }
.invf-sets { display:flex; gap:4px; flex-wrap:wrap; }
.invf-name { border:1px solid #c5cbbf; border-radius:5px; padding:4px 8px; font:inherit; font-size:13px; width:170px; }
.invf-b { border:1px solid #c5cbbf; background:#fff; border-radius:5px; padding:4px 12px; font:inherit; font-size:13px; cursor:pointer; }
.invf-b.pri { background:#689f38; color:#fff; border-color:#689f38; }
.invf-b:disabled { opacity:.5; cursor:default; }

.invf-overlay { position: fixed; inset: 0; background: rgba(38,50,56,.28); z-index: 1400; display: flex; justify-content: center; align-items: flex-start; padding: 72px 16px 16px; }
.invf-modal { width: min(980px, 100%); max-height: calc(100vh - 100px); overflow: auto; border-radius: 8px; }
.invf-modal .invf-panel { margin: 0; max-width: none; box-shadow: 0 16px 40px rgba(0,0,0,.25); }
.invf-live { margin-left: auto; order: 9; color: #1565C0; font-weight: 600; font-size: 12px; }
.invf-btn .invf-n { font-weight: 400; color: #1565C0; font-size: 12px; }
.invf-panel { position: relative; }
.invf-head { padding-right: 28px; }
.invf-close { position: absolute; top: 6px; right: 8px; border: 0; background: none; color: #90a4ae; font-size: 22px; line-height: 1; cursor: pointer; padding: 2px 6px; border-radius: 4px; }
.invf-close:hover { background: #eceff1; color: #37474f; }
/* Inventory column chooser (docs/mockups/inventory-column-chooser.png) */
.invc-modal { width: min(1000px, 100%); }
.invc-search { margin-left: auto; border: 1px solid #c5cbbf; border-radius: 5px; padding: 4px 9px; font: inherit; font-size: 13px; width: 240px; }
.invc-cols { display: flex; gap: 14px; }
.invc-left { flex: 1.7; border: 1px solid #e5e9e1; border-radius: 6px; height: 56vh; overflow: auto; padding: 4px 10px 10px; }
.invc-right { flex: 1; border: 1px solid #e5e9e1; border-radius: 6px; height: 56vh; overflow: auto; padding: 4px 10px; }
.invc-g { font-size: 11px; text-transform: uppercase; color: #689f38; font-weight: 700; margin: 10px 0 4px; display: flex; justify-content: space-between; }
.invc-g span { color: #78909c; font-weight: 400; text-transform: none; }
.invc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1px 14px; }
.invc-c { display: flex; align-items: center; gap: 6px; padding: 2px 0; font-size: 13px; cursor: pointer; }
.invc-c input { accent-color: #689f38; }
.invc-c.k { color: #33691e; font-weight: 600; }
.invc-c i { font-style: normal; font-size: 10px; color: #90a4ae; border: 1px solid #cfd8dc; border-radius: 3px; padding: 0 4px; margin-left: auto; font-weight: 400; }
.invc-sh { display: flex; align-items: center; gap: 8px; padding: 4px 6px; border-bottom: 1px solid #f0f2ee; font-size: 13px; cursor: grab; background: #fff; }
.invc-sh.fz { color: #78909c; cursor: default; }
.invc-sh.drag { opacity: .4; }
.invc-sh .h { color: #b0bec5; letter-spacing: -2px; }
.invc-sh b { margin-left: auto; color: #b0bec5; font-weight: 400; cursor: pointer; }
.invc-sh b:hover { color: #c62828; }
.inv-filter-more { border: 1px dashed #c5cbbf; background: #fff; border-radius: 4px; font-size: 11px; color: #78909c; padding: 2px 6px; cursor: pointer; width: 100%; }

/* Daily Brief: questions from the person's other projects (collapsed by default, tagged) */
.ph-other-head { display: block; width: 100%; text-align: left; border: 1px dashed #cfd8dc; background: #fafbfa; color: #546e7a; border-radius: 8px; padding: 8px 12px; margin: 6px 0; font: inherit; font-size: 13px; cursor: pointer; }
.ph-other-head:hover { background: #f1f4ef; }
.ph-other-head.open { border-style: solid; }
.ph-proj-tag { display: inline-block; background: #37474f; color: #fff; border-radius: 4px; padding: 0 6px; margin-right: 6px; font-size: 11px; font-weight: 600; }
.ph-alarm.other { border-left: 3px solid #90a4ae; }

/* Trend widgets: shared count-axis zoom */
.itr-zoom { margin-left: auto; display: inline-flex; align-items: center; gap: 4px; font-size: 11px; color: #64748b; }
.itr-zoom button { width: 20px; height: 20px; border: 1px solid #cbd5e1; border-radius: 4px; background: #fff; cursor: pointer; line-height: 1; padding: 0; }
.itr-zoom button:disabled { opacity: .4; cursor: default; }
.itr-hv .itr-hv-show{display:none}
.itr-hv:hover .itr-hv-show{display:inline}
.itr-zoom input[type=range]{width:90px;accent-color:#64748b}
.itr-zoom .itr-zoom-pct{width:auto;padding:0 5px;font-size:11px}
.itr-zoom .itr-zoom-val{min-width:24px;text-align:right}
/* Trend KPI cards: one line each, scaled to the widget width, so Design and Build read the same whatever their numbers */
.itr{container-type:inline-size}
.itr-kp b{font-size:clamp(13px,3.4cqw,19px);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.itr-kp span{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.itr-kp.ring > div{min-width:0}

/* Pool dashboard: Needs-attention rows open a side panel with fixes. */
.dp-att-row { cursor: pointer; }
.dp-att-row:hover { background: #F6FAEF; }
.dp-att-row.sel { background: #EAF4DC; box-shadow: inset 3px 0 #7CB342; }
.dp-att-shade { position: fixed; inset: 0; z-index: 1250; background: rgba(38,50,56,.12); }
.dp-att-panel { position: fixed; top: 0; right: 0; bottom: 0; width: min(400px, 96vw); z-index: 1260; background: #fff; border-left: 1px solid #d9dccf; box-shadow: -8px 0 24px rgba(0,0,0,.12); padding: 16px 18px; overflow-y: auto; display: flex; flex-direction: column; gap: 6px; box-sizing: border-box; }
.dp-att-top { display: flex; justify-content: space-between; align-items: center; }
.dp-att-panel h3 { margin: 6px 0 0; font-size: 16px; }
.dp-att-kv { display: grid; grid-template-columns: 90px 1fr; gap: 4px 8px; margin: 10px 0 4px; font-size: 13px; }
.dp-att-kv span { color: #6b7280; } .dp-att-kv b { font-weight: 600; }
.dp-att-why { background: #FDECEA; border-left: 3px solid #C62828; padding: 8px 10px; border-radius: 4px; font-size: 13px; }
.dp-att-why.warn { background: #FFF4E5; border-left-color: #EF6C00; }
.dp-att-lbl { font-size: 11.5px; color: #6b7280; letter-spacing: .05em; margin-top: 12px; }
.dp-att-btn { text-align: left; padding: 8px 12px; border: 1px solid #cfd5c3; background: #fff; border-radius: 6px; font-size: 13.5px; cursor: pointer; }
.dp-att-btn:hover { background: #F6FAEF; }
.dp-att-btn.pri { background: #7CB342; border-color: #7CB342; color: #fff; }
.dp-att-fly { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; padding: 6px; border: 1px solid #e5e7eb; border-radius: 6px; }
.dp-att-fly select, .dp-att-fly input { flex: 1; min-width: 160px; padding: 5px; }
.dp-att-links a { color: #33691E; margin-right: 14px; font-size: 13px; cursor: pointer; text-decoration: underline; }
