html, body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

h1:focus {
    outline: none;
}

#blazor-error-ui {
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 0.75rem;
        top: 0.5rem;
    }

.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."
    }


body {
    display: flex;
    flex-direction: column;
    height: 100vh;
    margin: 0;
}

/* position:relative + z-index makes this a STACKING CONTEXT, so any popup rendered *inside* the app
   bar is confined to this level however large its own z-index is. At z-index 1 the alert bell's panel
   (z-index 1002, but trapped in here) painted underneath the page's grid — its toolbar text and filter
   icons showed straight through it. Raised so an app-bar-anchored popup can sit above page content.
   Kept well below Telerik's own popup/window range (10000+) so dialogs and dropdowns still win, and
   the bar only occupies the top ~52px, which nothing else should be overlaying anyway.
   MainLayout's user menu sidesteps this by rendering outside the app bar; the bell cannot, because the
   button and its panel are one component. */
div.appbar-top {
    position: relative;
    z-index: 1100;
}

.mainlayout-drawer {
    flex: 1;
    align-items: stretch;
    overflow: hidden;
}

    .mainlayout-drawer > .k-drawer .k-drawer-items {
        margin-top: 1em;
    }

/* "View change history" sits with the buttons, slightly left of Save. Shared by the Workforce Jobs
   editor and the CRM customer editor so the two screens are identical — they had a copy each, and the
   customer one was in a SCOPED .razor.css where it could never match: the class is handed to
   TelerikButton, which renders the <button> itself, so the component's b-* scope attribute is never on
   it. Anything styling a class passed to another component has to live unscoped, here.

   A fixed gap, NOT margin-right:auto. Auto made it fight .qx-form-error (which also claims the slack,
   and wins by being earlier in the row) so the button sat hard-left while idle and snapped back beside
   Save the moment a validation error appeared. A fixed gap holds the same position in every state. */
.qx-history-btn {
    margin-right: 1.5em;
}

/* The chat composer's Send button. Unscoped for the same reason as .qx-history-btn above: the class is
   handed to TelerikButton, which renders the <button> itself, so ChatPanel's b-* scope attribute never
   lands on it and a rule in ChatPanel.razor.css would match nothing at all. */
.qx-chat-send {
    min-width: 92px;
}

/* The collapsed Messages bar's speech bubble, coloured while anything is unread - the bar is a thin strip
   at the bottom of a busy screen, so the count alone is easy to miss and the bubble changing is what
   catches an eye that is not looking for it. The same token the unread badge uses, so the two read as one
   signal rather than two colours arguing. No animation: this sits above every screen in the app.

   Unscoped because the class is handed to TablerIcon, which renders the <i> itself - a rule in
   ChatPanel.razor.css carries ChatPanel's b-* attribute and matches nothing, which is precisely what it
   did until this moved here. */
.qx-chat-bar-icon--unread {
    color: var(--kendo-color-primary, #ff6358);
}

/* Custom drawer navigation (grouped / collapsible items) */
.mainlayout-drawer .qx-nav-link,
.mainlayout-drawer .qx-nav-group,
.mainlayout-drawer .qx-nav-separator {
    display: flex;
    align-items: center;
    gap: 0.6em;
    width: 100%;
}

.mainlayout-drawer .qx-nav-link {
    color: inherit;
    text-decoration: none;
}

    .mainlayout-drawer .qx-nav-link.active {
        font-weight: 600;
    }

.mainlayout-drawer .qx-nav-group {
    cursor: pointer;
    user-select: none;
}

.mainlayout-drawer .qx-nav-chevron {
    margin-left: auto;
    font-size: 0.8em;
    opacity: 0.7;
}

.mainlayout-drawer .qx-nav-child {
    padding-left: 1.6em;
}

/* Rows 40px tall, a little more room to aim at, as in Azure DevOps. The theme's own variables, so every theme family follows. */
.mainlayout-drawer {
    --kendo-drawer-item-padding-y: 10.5px;
    --kendo-drawer-item-padding-x: 16px;
}

/* A heading fills its whole row, so a click or hover anywhere on it reaches the heading and not Telerik's item click. */
.mainlayout-drawer .k-drawer-item:has(> .qx-nav-group) {
    padding: 0;
}

.mainlayout-drawer .qx-nav-group {
    box-sizing: border-box;
    padding: var(--kendo-drawer-item-padding-y) var(--kendo-drawer-item-padding-x);
}

.mainlayout-drawer .qx-nav-group.is-open,
.mainlayout-drawer .qx-nav-group.is-current {
    font-weight: 600;
}

/* The heading of the current page, when the page itself is not in the drawer: the look of a selected item. */
.mainlayout-drawer .k-drawer-item:has(> .qx-nav-group.is-current) {
    background-color: var(--kendo-drawer-item-selected-bg, var(--kendo-drawer-item-bg, var(--kendo-drawer-bg, var(--kendo-color-secondary-subtle))));
}

    .mainlayout-drawer .k-drawer-item:has(> .qx-nav-group.is-current)::before {
        opacity: 1;
    }

/* Flyout menu style. Fixed, so the drawer cannot clip it; menu-flyout.js sets its place and the data-flyout-* state. */
.qx-nav-flyout {
    display: none;
    position: fixed;
    z-index: 1050;
    cursor: default;
}

.qx-menu-flyout .qx-nav-group[data-flyout-hover]:not([data-flyout-paused]) > .qx-nav-flyout,
.qx-menu-flyout .qx-nav-group[data-flyout-open] > .qx-nav-flyout,
.qx-menu-flyout .qx-nav-group:not([data-flyout-paused]):has(.qx-nav-flyout :focus-visible) > .qx-nav-flyout {
    display: block;
}
.qx-nav-popup {
    min-width: 200px;
    max-height: inherit;
    overflow-y: auto;
    padding: 0.4em 0;
    background: var(--kendo-color-surface);
    color: var(--kendo-color-on-app-surface);
    border: 1px solid var(--kendo-color-border);
    border-radius: 6px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
    font-weight: normal;
}

/* Panel menu style: a full-height list over the page's left edge, the look of the Settings menu. */
/* Above a page's own layers (the map's panels are 1000), below the flyout (1050) and the app bar (1100). Not a stacking
   context on main instead: that would trap a page's full-screen fixed modal (Correlation Logs) under the app bar. */
.qx-nav-panel-overlay {
    position: absolute;
    inset: 0;
    z-index: 1040;
    background: rgba(0, 0, 0, 0.08);
}

.qx-nav-panel {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 1041;
    width: 220px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    padding: 0.5em 0;
    background: var(--kendo-color-surface);
    border-right: 1px solid var(--kendo-color-border);
    box-shadow: 4px 0 12px rgba(0, 0, 0, 0.12);
}

/* As Azure DevOps: the group's name in bold, level with the group it came from (menu-flyout.js lines it up). */
.qx-nav-popup-title {
    padding: 0.55em 1em 0.35em calc(1em + 3px);
    font-weight: 700;
    white-space: nowrap;
}

.qx-nav-panel-title {
    padding: 0.6em 1em 0.5em;
    font-size: 0.72em;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--kendo-color-subtle);
}

.qx-nav-popup-item,
.qx-nav-panel-item {
    display: flex;
    align-items: center;
    gap: 0.5em;
    padding: 0.55em 1em;
    color: var(--kendo-color-on-app-surface);
    text-decoration: none;
    font-size: 0.9em;
    white-space: nowrap;
    border-left: 3px solid transparent;
}

    .qx-nav-popup-item:hover,
    .qx-nav-panel-item:hover {
        background: var(--kendo-color-base-hover);
        color: var(--kendo-color-on-base);
        text-decoration: none;
    }

    .qx-nav-popup-item.active,
    .qx-nav-panel-item.active {
        border-left-color: var(--kendo-color-primary);
        background: var(--kendo-color-primary-subtle);
        color: var(--kendo-color-primary);
        font-weight: 600;
    }

.mainlayout-drawer .qx-nav-separator {
    opacity: 0.6;
    font-size: 0.85em;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

/* Top AppBar */

.appbar-top > div {
    line-height: 2.4;
}

/* Help + alert bell: one pair of round icon buttons at the end of the bar. They share an AppBarSection so
   the bar's own 8px inter-section gap doesn't sit between them — at that distance they read as two
   unrelated controls rather than a pair. */
.appbar-tools {
    display: inline-flex;
    align-items: center;
    gap: 2px;
}

#app-title {
    display: flex;
    gap: .2em;
    align-items: center;
    margin: 0;
    padding: 0;
    font-size: 1.2em;
}

    #app-title strong {
        font-weight: 500;
    }

    #app-title sup {
        font-size: .4em;
    }

    #app-title a,
    #app-title a:hover {
        text-decoration: none;
        color: inherit;
    }

#product-page-link {
    display: block;
    width: 42px;
    margin-right: var(--kendo-spacing-2);
    background: url(devcraft-ninja-small.svg) center no-repeat;
    background-size: contain;
    font-size: var(--kendo-font-size-lg);
    text-decoration: none;
    text-indent: -9999px;
}

/* Main Content */

main {
    padding: 0 2em 2em;
}

/* Pass the drawer's computed height down to the page. .mainlayout-drawer already fills the space under the app
   bar, but the height stopped at <main>, so a page asking for height:100% got auto and grew off-screen — which
   is why full-height pages each hand-tuned their own calc(100vh - Npx). Now height:100% works and pages that
   overflow scroll inside main. */
.mainlayout-drawer > .k-drawer-content {
    position: relative;
    height: 100%;
    min-height: 0;
}

.mainlayout-drawer main {
    height: 100%;
    box-sizing: border-box;
    overflow: auto;
}

a {
    color: var(--kendo-color-on-app-surface);
}

    a:hover {
        color: var(--kendo-color-primary);
        text-decoration: none;
    }

h1, h2, h3 {
    margin: .67em 0 .3em;
    font-weight: normal;
}

h1 {
    font-size: 42px;
}

h2 {
    font-size: 32px;
}

h3 {
    font-size: 24px;
}

/* Bottom AppBar */

div.appbar-bottom {
    z-index: 1;
    background-color: var(--kendo-color-surface);
    color: var(--kendo-color-subtle);
}

#copyright {
    padding: .5em 0;
}

/* Project icon picker */

.pip-trigger-wrap {
    display: inline-block;
}

.pip-trigger {
    width: 100%;
    justify-content: flex-start;
}

.pip-trigger-inner {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.pip-trigger-inner > span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pip-placeholder {
    color: var(--kendo-color-subtle);
}

/* Icon-only swatch trigger (user-facing) */
.pip-trigger-compact {
    width: 36px;
    height: 36px;
    padding: 0;
    border-radius: 10px;
    font-size: 18px;
    background: var(--kendo-color-base);
    border: 1px solid var(--kendo-color-border);
    transition: transform .12s ease, box-shadow .12s ease, border-color .12s ease;
}

.pip-trigger-compact:hover {
    transform: translateY(-1px);
    border-color: var(--kendo-color-primary);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.pip-tabs {
    margin-top: 4px;
}

.pip-grid-tall {
    max-height: 440px;
}

.pip-toolbar {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.pip-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(48px, 1fr));
    gap: 6px;
    max-height: 380px;
    overflow: auto;
    padding: 2px;
}

.pip-tile {
    aspect-ratio: 1 / 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    border: 1px solid transparent;
    border-radius: 8px;
}

.pip-tile:hover {
    background: var(--kendo-color-base-hover);
    border-color: var(--kendo-color-border);
}

.pip-tile-active {
    border-color: var(--kendo-color-primary);
    background: var(--kendo-color-primary-subtle, var(--kendo-color-base-hover));
}

.pip-more,
.pip-empty {
    margin-top: 10px;
    font-size: 12px;
    color: var(--kendo-color-subtle);
}

/* ── CRM pipeline drag clue ──────────────────────────────────────────────────
   Kendo renders the floating drag image (.k-drag-clue) on <body>, outside any
   component scope, with its own padded dark frame + 0.8 opacity. Strip that so
   the dragged card looks like a real, lifted card. The cloned .crm-card keeps
   its own (scoped) styling; we just size it and neutralise the wrapper. */
.k-drag-clue:has(.crm-card) {
    padding: 0;
    border: none;
    background: transparent;
    background-image: none;
    box-shadow: 0 12px 28px rgba(0, 0, 0, .55);
    opacity: 1;
    border-radius: 6px;
    overflow: visible;
    /* Shrink the lifted card slightly so it reads as "picked up". */
    transform: scale(.92);
    transform-origin: center;
}

.k-drag-clue:has(.crm-card) .k-list-item,
.k-drag-clue:has(.crm-card) .k-list-item-text {
    display: block;
    width: auto;
    padding: 0;
    margin: 0;
    border: none;
    background: transparent;
    white-space: normal;
    overflow: visible;
}

.k-drag-clue .crm-card {
    width: 238px;
}

/* Highlight the label of a form field that failed validation (settings/edit forms), so the errored
   field is obvious, not just its message. Telerik marks the editor .k-invalid on submit.

   Child combinator, NOT descendant: a screen that builds its whole tab inside one templated FormItem
   (the CRM customer editor) has a single .k-form-field wrapping every label, so ":has(.k-invalid)
   .k-form-label" reddened all of them the moment any one editor failed. A declarative FormItem keeps
   its label as a direct child, so "> " still covers the normal case; templated layouts scope the
   highlight to their own field wrapper below. */
.k-form-field:has(.k-invalid) > .k-form-label,
.k-form-field.k-invalid > .k-form-label,
.k-form-field:has(.k-invalid) > label,
.k-form-field.k-invalid > label,
.crm-field:has(.k-invalid) > label,
.crm-qa-field:has(.k-invalid) > label,
.fin-qa-field:has(.k-invalid) > label,
.qx-validated-field:has(.k-invalid) > label {
    color: var(--kendo-color-error, #d51923);
    font-weight: 600;
}

/* The shared QixoLoader, scaled to 75%. Kendo's loader sizes are discrete steps (sm/md/lg), so a plain
   scale is the only way to land on an exact 25% reduction while keeping the Large proportions. */
.qx-loader .k-loader {
    transform: scale(0.75);
    transform-origin: center;
}

/* Opt a form into "all errors on the button row": suppresses the per-field message Telerik renders under
   a declarative FormItem, which is the other half of the resize. Only for forms that carry a .qx-form-error
   line — the Settings lookup screens deliberately keep their inline messages (they appear in FormItem
   order, which is how those forms tell you which field), so this must never be applied globally. */
.qx-errors-bottom .k-form-error {
    display: none;
}

/* Standard form-error line. It lives on the SAME row as Save/Cancel, deliberately: a per-field message
   rendered under its editor is inserted into flow as it appears, which resizes the form and shunts every
   field below it (the flicker). One fixed line at the bottom never moves anything — the red label above
   says which field, this says why. Pair it with the label rule above; don't add inline messages too.

   margin-right:auto pins it to the LEFT edge of the button row (the row is flex, right-aligned), so the
   message reads from the start of the form and has the full width to run into rather than being squeezed
   against the Save button. */
.qx-form-error {
    display: flex;
    align-items: center;
    gap: 4px;
    align-self: center;
    margin-right: auto;
    text-align: left;
    font-weight: 600;
    color: var(--kendo-color-error, #d51923);
}

/* The warning sign leads the line, ahead of the pager, so the row always starts the same way however
   many messages there are and whatever they say. */
.qx-form-error-sign {
    line-height: 1;
}

/* "2 of 5" between the pager arrows — quieter than the message it counts. */
.qx-form-error-count {
    font-weight: 400;
    font-size: 0.9em;
    opacity: 0.85;
    white-space: nowrap;
}

/* The pager arrows inherit the error colour rather than the button theme's. */
.qx-form-error .k-button {
    color: inherit;
}

/* Wrapper for a hand-built (templated) form field that needs the red-label rule above scoped to itself.
   display:contents means it produces no box at all — the label/editor/message lay out exactly as if the
   wrapper weren't there — so it can be added to an existing layout without moving anything. */
.qx-validated-field {
    display: contents;
}

/* ── Focus ring (global) ───────────────────────────────────────────────────────
   Kendo adds a .k-focus class (and draws a box-shadow / outline ring) on mouse
   click, not just keyboard focus — so tabs, tab panels and buttons pick up a
   border that reads as an accidental selection. Suppress the ring on that
   interactive chrome app-wide, so we never have to re-do it per dialog. Text
   editors keep their own focus border, and structural shadows/elevation are left
   untouched (we target the ring properties on focused chrome only). */
.k-tabstrip-items-wrapper .k-tabstrip-item:focus,
.k-tabstrip-items-wrapper .k-tabstrip-item.k-focus,
.k-tabstrip-items-wrapper .k-item:focus,
.k-tabstrip-items-wrapper .k-item.k-focus,
.k-tabstrip-content:focus, .k-tabstrip-content.k-focus,
.k-tabstrip > .k-content:focus, .k-tabstrip > .k-content.k-focus,
.k-button:focus, .k-button.k-focus,
.k-button.k-button-solid:focus, .k-button.k-button-solid.k-focus {
    box-shadow: none !important;
    outline: none !important;
}

/* ── Dialog shell (shared) ──────────────────────────────────────────────────────
   Chrome for the Blueprint Designer definition-editor dialogs (DialogShell.razor:
   Tool, Launch Workflow, Transform, Hydrate). One home for the banded header + body
   + footer so each editor is just its body markup. --ae is the entity accent, set
   inline per dialog. See the qixo-dialog-form-style memory. */
.qxd-window,
.qxd-window:focus, .qxd-window:focus-visible, .qxd-window:focus-within, .qxd-window.k-focus {
    border-radius: 12px; overflow: hidden; padding: 0;
    outline: none !important;
    border: none !important;
    box-shadow: 0 14px 44px rgba(0, 0, 0, 0.24) !important;
}
/* Telerik pins a reused window to the height it had last open; the content decides instead. */
.qxd-window { height: auto !important; }
.qxd-window .k-window-titlebar { display: none; }
.qxd-window .k-window-content { padding: 0; border: none; }

.qxd-root { display: flex; flex-direction: column; font-family: var(--kendo-font-family, 'Segoe UI', system-ui, sans-serif);
            border: 1px solid var(--kendo-color-border);
            border-radius: 12px; overflow: hidden; }

.qxd-band { display: flex; flex-direction: column; gap: 9px; padding: 15px 18px;
            background: color-mix(in srgb, var(--ae) 12%, var(--kendo-color-surface));
            border-bottom: 1px solid color-mix(in srgb, var(--ae) 24%, var(--kendo-color-border)); }
.qxd-band-top { display: flex; align-items: center; gap: 11px; }
/* The standard chip at dialog scale: accent (--ae) at 22% over the base, border and mark the accent at full strength. */
/* Formula, glyph sizing and the two Telerik workarounds all come from .qx-chip now (#1185 step 2) — this
   keeps only what is genuinely this chip's: its size, and the accent variable its surface happens to use.
   34px is not a rung of the ladder, so it stays declared here rather than being snapped to 32 or 40.
   Fallback inside the var() is not optional: an undefined --ae would make --c invalid-at-computed-value,
   which falls back to INHERITED rather than to .qx-chip's default, and the chip would take a colour from
   whatever is above it. */
.qxd-chip { --c: var(--ae, var(--kendo-color-subtle));
            width: 34px; height: 34px; border-radius: 8px; font-size: 19px; line-height: 1; }
.qxd-band-txt { flex: 1; min-width: 0; }
.qxd-type { font-size: 10.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
            color: var(--kendo-color-on-app-surface); }
.qxd-title { font-size: 15px; font-weight: 600; color: var(--kendo-color-on-app-surface); }
.qxd-close { cursor: pointer; color: var(--kendo-color-subtle); display: inline-flex; }
.qxd-blurb { font-size: 12.5px; line-height: 1.45; color: var(--kendo-color-on-app-surface); opacity: .82; white-space: pre-wrap; }

/* 560 = AgentEditor's 48px tab row + its 512 body, so every Toolbox dialog has the same working area; the cap keeps
   the footer on screen on a short window. */
.qxd-body { padding: 16px 18px; display: flex; flex-direction: column; gap: 12px; height: min(560px, calc(100vh - 240px)); overflow-y: auto; }
/* Short descriptive dialogs (Gate / Aggregate / Reduce / Set Metadata) size to their content instead. */
.qxd-body.qxd-body-auto { height: auto; max-height: min(560px, calc(100vh - 240px)); }
.qxd-body.qxd-body-auto:empty { display: none; }
.qxd-desc { font-size: 13px; line-height: 1.5; color: var(--kendo-color-on-app-surface); }
.qxd-desc code { font-family: var(--kendo-font-family-monospace, monospace); font-size: 11.5px;
                 background: var(--kendo-color-base-subtle, var(--kendo-color-base)); padding: 1px 5px;
                 border-radius: 5px; }
.qxd-field { display: flex; flex-direction: column; }
.qxd-field > label { font-size: 12.5px; color: var(--kendo-color-subtle); margin-bottom: 5px; }
.qxd-req { color: var(--kendo-color-error); }
.qxd-mono textarea { font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace; font-size: 12.5px; }
.qxd-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-items: start; }
.qxd-sec { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em;
           color: var(--kendo-color-subtle); border-top: 1px solid var(--kendo-color-border); padding-top: 12px; margin-top: 2px; }
.qxd-item { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 6px 10px;
            border: 1px solid var(--kendo-color-border); border-radius: 8px; }
.qxd-item-main { display: flex; align-items: center; gap: 7px; min-width: 0; overflow: hidden; }
.qxd-key { font-size: 12px; font-family: var(--kendo-font-family-monospace, monospace); color: var(--kendo-color-on-app-surface); }
.qxd-eq { color: var(--kendo-color-subtle); }
.qxd-val { font-size: 12.5px; color: var(--kendo-color-on-app-surface); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qxd-x { color: var(--kendo-color-subtle); cursor: pointer; flex-shrink: 0; display: inline-flex; }
.qxd-addrow { display: flex; align-items: center; gap: 6px; }
/* Hint text closing the body, the same as .ae-note in AgentEditor. */
.qxd-note { font-size: 12px; line-height: 1.45; color: var(--kendo-color-subtle); white-space: pre-wrap; padding-top: 2px; }
.qxd-note code { font-family: var(--kendo-font-family-monospace, monospace); font-size: 11px;
                 background: var(--kendo-color-base-subtle, var(--kendo-color-base)); padding: 1px 5px;
                 border-radius: 5px; color: var(--kendo-color-on-app-surface); }
.qxd-tmpl { display: flex; gap: 6px; align-items: center; }
.qxd-tmpl > :first-child { flex: 1; min-width: 0; }

.qxd-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 18px;
            border-top: 1px solid var(--kendo-color-border); background: var(--kendo-color-base); }
.qxd-path { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--kendo-color-subtle); }
.qxd-foot-btns { display: flex; gap: 8px; }

/* .qx-icon-inherit was here, in 43 places, and is DELETED (#1173).
   It existed only to undo the colour Kendo sets on span.k-icon.k-svg-icon, which beat any colour a
   wrapper tried to inherit down to a bridged glyph (#1133). #1184 moved every standalone glyph onto the
   webfont wrapper — a plain <i> that inherits colour like any other text — so there is nothing left to
   undo. If a colour override ever looks necessary again, the glyph is on the wrong renderer: see
   qixo-blazor-telerik-traps §11. The .qxd-x half of the rule went with it, for the same reason. */

/* Edit-in-place rule rows (Transform / Hydrate multi-field lists). */
.qxd-rule { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 8px 10px;
            border: 1px solid var(--kendo-color-border); border-radius: 8px; }
.qxd-chk { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; color: var(--kendo-color-subtle); white-space: nowrap; }
.qxd-addbtn { align-self: flex-start; }

/* Step cards (Hydrate: a function call + inputs + output per step). */
.qxd-step { display: flex; flex-direction: column; gap: 10px; padding: 12px;
            border: 1px solid var(--kendo-color-border); border-radius: 8px; }
.qxd-step-head { display: flex; align-items: center; justify-content: space-between; font-size: 11px; font-weight: 700;
                 text-transform: uppercase; letter-spacing: .05em; color: var(--kendo-color-subtle); }
.qxd-sublabel { font-size: 12.5px; color: var(--kendo-color-subtle); }
/* ── Master/detail surface (shared) ────────────────────────────────────────────
   The chrome behind Approvals and the State Model, and the contract for any future master/detail screen: a page
   that owns one family colour, panes that hold a tinted title band, and a queue of selectable rows. The rules were
   copy-pasted between the two pages first and drifted within a day (two different band tints), so they live here.

   A page opts in by setting its family accent on the root:  .ap-root { --a: #ec4899; }
   Everything below reads --a, so a page never restates its own hex. See the qixo-board-visual-system skill (§7). */

/* The page: fills the area main gives it, never scrolls itself (the panes do). */
.qxs-root { position: relative; height: 100%; overflow: hidden; display: flex; flex-direction: column; }

/* Recess the content below the app chrome — the inset shadow cast down from the top title bar and in from the side
   menu, matching the Blueprint Designer's Code view. The bar sits above it (z-index below) so the pills stay crisp;
   the panes sit under it and pick up the recess at their top-left. */
.qxs-root::before { content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 11;
                    box-shadow: inset 0 10px 14px -10px rgba(0,0,0,.65),
                                inset 10px 0 14px -10px rgba(0,0,0,.45); }

/* Title row above the panes. .qxs-mark is the standard chip at page scale (32/10) — same 22% fill + inset ring
   as .qxd-chip and .pb-av; see the skill's chip table before changing it. */
.qxs-bar { position: relative; z-index: 12; display: flex; align-items: center; gap: 16px; padding: 14px 12px 10px; }
.qxs-bar-title { display: inline-flex; align-items: center; gap: 10px; font-size: 19px; font-weight: 760; letter-spacing: -.01em; }
.qxs-bar-actions { margin-left: auto; display: inline-flex; align-items: center; gap: 10px; }
/* 32/10 IS the ladder's --lg rung, so the markup carries qx-chip--lg and only the accent alias and the
   glyph size are left here (17px rather than the rung's 18px — this surface was tuned). */
.qxs-mark { --c: var(--a, var(--kendo-color-subtle)); font-size: 17px; line-height: 1; }
/* A count beside the title: accent-tinted, no ring — it is a readout, not a chip. */
.qxs-count { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 7px; border-radius: 11px;
             font-size: 12px; font-weight: 700; color: var(--a); background: color-mix(in srgb, var(--a) 16%, transparent); }

/* The panes. 12px gutter on the sides and the bottom, 12px between them — one number, so nothing looks jammed
   against the window edge when a page anchors to the bottom. */
.qxs-split { flex: 1; min-height: 0; display: flex; gap: 12px; margin: 0 12px 12px; }
.qxs-pane { position: relative; display: flex; flex-direction: column; min-height: 0;
            background: var(--kendo-color-surface); border: 1px solid var(--kendo-color-border); border-radius: 12px;
            overflow: hidden;
            box-shadow: 0 6px 22px rgba(0,0,0,.20), 0 2px 6px rgba(0,0,0,.12); }
.qxs-pane-master { width: 360px; flex-shrink: 0; }
.qxs-pane-detail { flex: 1; min-width: 0; }

/* The title band: the accent washing LEFT TO RIGHT (135deg), pale end first, the same on both panes so they pair.
   FIXED 40px on every surface, so side-by-side panes line up: never let content set it. It holds a medium input or
   button, and the title is one line (below). */
.qxs-band { display: flex; align-items: center; gap: 10px; padding: 0 14px; flex-shrink: 0;
            height: 40px; box-sizing: border-box;
            background: linear-gradient(135deg, color-mix(in srgb, var(--a) 3%, var(--kendo-color-surface)),
                                                color-mix(in srgb, var(--a) 26%, var(--kendo-color-surface)));
            border-bottom: 1px solid color-mix(in srgb, var(--a) 35%, var(--kendo-color-border)); }
/* THE ORDER IS TITLE THEN SUBTEXT, ON ONE LINE. The plain-language name reads first at full contrast; the
   accent-coloured qualifier follows it after a middot ("Types · QIXO LIBRARY"). Markup order matches:
   .qxs-band-title, then .qxs-band-sub. The qualifier shrinks far faster, so it gives way before the name truncates. */
.qxs-band-tx { flex: 1; min-width: 0; display: flex; align-items: baseline; gap: 6px; }
.qxs-band-title { font-size: 13.5px; font-weight: 730; letter-spacing: -.01em; color: var(--kendo-color-on-app-surface);
                  flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qxs-band-sub { font-size: 9.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--a);
                flex: 0 1000 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qxs-band-sub::before, .qxs-band-name-tx > small::before { content: "·"; margin-right: 6px; letter-spacing: 0; }
.qxs-band-acts { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; }

/* A readout pinned in a title band: accent text on an accent tint with an accent border, so it belongs to the
   band rather than sitting on it. Use for a count the user needs before they act. */
.qxs-band-pill { display: inline-flex; align-items: center; gap: 5px; flex-shrink: 0; padding: 3px 10px;
                 border-radius: 20px; font-size: 11px; font-weight: 700; color: var(--a);
                 background: color-mix(in srgb, var(--a) 14%, var(--kendo-color-surface));
                 border: 1px solid color-mix(in srgb, var(--a) 55%, transparent); }
.qxs-band-pill .ti { font-size: 13px; line-height: 1; }

/* The queue. Rows are FLAT at rest with a transparent border, so hover and selection have somewhere to go.
   Selection is the accent as a border only, theme surface inside — a filled row was rejected (every row lit up). */
.qxs-list { flex: 1; overflow-y: auto; padding: 8px; display: flex; flex-direction: column; gap: 8px; }
.qxs-row { position: relative; display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px;
           cursor: pointer; min-width: 0; background: var(--kendo-color-surface); border: 1px solid transparent;
           transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease; }
.qxs-row:hover { transform: translateY(-1px); box-shadow: 0 6px 16px rgba(0,0,0,0.14);
                 border-color: color-mix(in srgb, var(--a) 40%, var(--kendo-color-border)); }
/* Selection: the accent border plus a light accent-tinted fill — the same 14% wash as the .qxs-band-pill. Only the
   one selected row is filled (a fill on every row was rejected — it read as "everything highlighted"). */
.qxs-row.is-sel { background: color-mix(in srgb, var(--a) 14%, var(--kendo-color-surface)); border-color: var(--a); }
.qxs-row-tx { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.qxs-row-title { font-size: 13px; font-weight: 730; letter-spacing: -.01em; color: var(--kendo-color-on-app-surface);
                 white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.qxs-row-sub { font-size: 11px; line-height: 1.2; color: var(--kendo-color-subtle);
               white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* Day / section headers breaking the queue into runs (the mail-client rhythm). */
.qxs-group { font-size: 10.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
             color: var(--kendo-color-subtle); padding: 8px 6px 2px; }
.qxs-group:first-child { padding-top: 2px; }

/* The row's leading mark (30/8). Two flavours of the same chip: --a for "this row is one of these" (a kind), or
   an inline --m for "this row came from THERE" (a per-item identity hue with initials). */
/* 30/8 is not a rung, so the size stays here. */
.qxs-av { --c: var(--a, var(--kendo-color-subtle));
          width: 30px; height: 30px; border-radius: 8px; font-size: 15px; line-height: 1; }

/* The per-item identity flavour: a different variable (--m, a hue derived from the item) and a
   deliberately weaker ring than .qx-chip's full-strength one, so initials read as identity rather than as
   a status chip. Overriding background and box-shadow rather than aliasing --c, because 20%/70% are not
   the chip's 22%/100% — this is the one place the formula genuinely differs. */
.qxs-av.qxs-av-id { font-size: 11.5px; font-weight: 800; letter-spacing: .02em;
                    color: var(--m); background: color-mix(in srgb, var(--m) 20%, var(--kendo-color-base));
                    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--m) 70%, transparent); }

/* Status pills carry SEMANTIC colour and stay out of the accent system — a tinted fill, not a bare outline
   (an outline-only pill on a surface reads as a grey ring). Pair with .qxs-pdot for the leading dot. */
.qxs-pill { display: inline-flex; align-items: center; gap: 5px; font-size: 10.5px; font-weight: 700; padding: 3px 9px;
            border-radius: 20px; flex-shrink: 0; align-self: flex-start; }
.qxs-pdot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.qxs-pill-warn { color: color-mix(in srgb, var(--kendo-color-warning) 78%, var(--kendo-color-on-app-surface));
                 background: color-mix(in srgb, var(--kendo-color-warning) 16%, transparent); }
.qxs-pill-ok { color: color-mix(in srgb, var(--kendo-color-success) 74%, var(--kendo-color-on-app-surface));
               background: color-mix(in srgb, var(--kendo-color-success) 15%, transparent); }
.qxs-pill-off { color: var(--kendo-color-subtle);
                background: color-mix(in srgb, var(--kendo-color-subtle) 14%, transparent); }
/* Added for the Notification Centre, which needs "seen" and "critical" alongside the three above.
   Same formula deliberately — a fourth and fifth hand-rolled pill on that page is exactly how this
   layer drifted the first time. */
.qxs-pill-info { color: color-mix(in srgb, var(--kendo-color-info) 78%, var(--kendo-color-on-app-surface));
                 background: color-mix(in srgb, var(--kendo-color-info) 16%, transparent); }
.qxs-pill-err { color: color-mix(in srgb, var(--kendo-color-error) 80%, var(--kendo-color-on-app-surface));
                background: color-mix(in srgb, var(--kendo-color-error) 16%, transparent); }
/* Too much of something, such as overstocked: violet, which the theme has no token for, so it never reads as link blue. */
.qxs-pill-over { color: color-mix(in srgb, #8b5cf6 80%, var(--kendo-color-on-app-surface));
                 background: color-mix(in srgb, #8b5cf6 16%, transparent); }

/* Section label inside a pane or rail. */
.qxs-sec { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--kendo-color-subtle); }
.qxs-empty { padding: 24px 16px; color: var(--kendo-color-subtle); font-size: 13px; font-style: italic; }

/* ── Master/detail: the "Designer chrome" variant ──────────────────────────────
   An alternative to the tinted-band look above, borrowed from the Blueprint Designer's code view: the accent is
   spent on a raised identity PILL and on the active tab, and everything else is plain boxing. Opt in per page by
   adding .is-chrome to .qxs-band and using .qxs-titlepill in the bar — the default band stays as it was, so a page
   picks one language and keeps it. Both read var(--a) exactly as before. */

/* The page's identity pill: chip + name, raised off the surface. Modelled on .bd-hdr / .bd-fpill so the Designer
   and a master/detail screen state their identity the same way. */
.qxs-titlepill { display: inline-flex; align-items: center; gap: 9px; padding: 6px 12px 6px 8px;
                 background: var(--kendo-color-surface); border-radius: 14px;
                 border: 1px solid color-mix(in srgb, var(--a) 45%, var(--kendo-color-border));
                 box-shadow: 0 6px 22px rgba(0,0,0,.20), 0 2px 6px rgba(0,0,0,.12); }
.qxs-titlepill > span:not([class]) { font-size: 15px; font-weight: 600; line-height: 1.2;
                                     color: var(--kendo-color-on-app-surface); }

/* The controls cluster, raised into a matching pill at the other end of the bar — the Designer's identity +
   controls pair. This is CHROME, not page furniture: a plain border and theme-primary buttons, exactly like the
   Designer's .bd-ctl. The family accent stays on the page's own bands/chips/pills, never on the controls. */
.qxs-ctlpill { display: inline-flex; align-items: center; gap: 6px; padding: 5px 8px;
               background: var(--kendo-color-surface); border-radius: 14px;
               border: 1px solid var(--kendo-color-border);
               box-shadow: 0 6px 22px rgba(0,0,0,.20), 0 2px 6px rgba(0,0,0,.12); }
/* Clear icon buttons in the pill — the Designer's .bd-hdr-ic: subtle at rest, full foreground on hover. */
.qxs-ctlpill .k-button-flat, .qxs-ctlpill .k-button-clear { color: var(--kendo-color-subtle); }
.qxs-ctlpill .k-button-flat:hover, .qxs-ctlpill .k-button-clear:hover { color: var(--kendo-color-on-app-surface); }

/* Plain pane header: no wash, a hairline rule, and the name carried by its own small pill. */
.qxs-band.is-chrome { background: var(--kendo-color-base); border-bottom: 1px solid var(--kendo-color-border); }
.qxs-band-name { display: inline-flex; align-items: center; gap: 8px; flex: 1 1 auto; min-width: 0; }
.qxs-band-name-tx { display: flex; align-items: baseline; gap: 6px; min-width: 0; }
.qxs-band-name-tx > b { font-size: 13px; font-weight: 700; letter-spacing: -.01em; line-height: 1.25;
                        color: var(--kendo-color-on-app-surface); flex: 0 1 auto; min-width: 0;
                        overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qxs-band-name-tx > small { font-size: 9px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
                            line-height: 1.25; color: var(--a); flex: 0 1000 auto; min-width: 0;
                            overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* File tabs, as in the code editor: flat, the active one underlined in the accent. The underline is on a
   transparent border at rest so switching tabs never shifts the row by a pixel. */
.qxs-ftabs { display: inline-flex; align-items: stretch; gap: 2px; align-self: stretch; }
/* Leading tabs run to the pane edge, as a code editor's do, rather than sitting inside the band's padding. */
.qxs-band > .qxs-ftabs:first-child { margin-left: -14px; }
.qxs-ftab { display: inline-flex; align-items: center; gap: 6px; padding: 0 14px; cursor: pointer;
            font-size: 12.5px; font-weight: 600; color: var(--kendo-color-subtle);
            border-bottom: 2px solid transparent; margin-bottom: -1px;
            transition: color .15s ease, background-color .15s ease, border-color .15s ease; }
.qxs-ftab:hover { color: var(--kendo-color-on-app-surface);
                  background: color-mix(in srgb, var(--a) 7%, transparent); }
.qxs-ftab.is-active { color: var(--kendo-color-on-app-surface); border-bottom-color: var(--a);
                      background: color-mix(in srgb, var(--a) 12%, transparent); }
.qxs-ftab-count { font-size: 10.5px; font-weight: 700; color: var(--a);
                  background: color-mix(in srgb, var(--a) 16%, transparent); border-radius: 9px; padding: 1px 6px; }

/* ── Settings lookup pages (/SystemSettings/*) ────────────────────────────────
   One shared page box so every lookup screen sizes identically, instead of each
   page repeating its own padding/height rule. Viewport-filling flex column: the
   grid gets the leftover height via .ss-grid-fill, so it keeps its frame when
   empty and pages internally instead of running the whole page long.
   Matches the Users settings page (UserListPanel). */
.ss-page {
    display: flex;
    flex-direction: column;
    height: 100%;
    box-sizing: border-box;
    padding: 12px 16px;
    overflow: hidden;
}

.ss-page > .ss-grid-fill {
    flex: 1;
    min-height: 0;
}

/* Roles: "sign out and back in" after a save (#1482). HERE rather than in a scoped sheet because
   RolesPanel has none — it is shared by two hosts and dresses itself from these ss- classes. Same
   treatment as .profile-relogin-notice so the two instructions read as one thing. */
.ss-role-relogin-notice {
    display: flex;
    align-items: flex-start;
    gap: 0.5em;
    flex: 0 0 auto;
    margin-bottom: 0.75rem;
    padding: 0.6em 0.8em;
    border: 1px solid color-mix(in srgb, var(--kendo-color-info) 45%, transparent);
    border-radius: 6px;
    background: color-mix(in srgb, var(--kendo-color-info) 12%, transparent);
    color: var(--kendo-color-on-app-surface);
    font-size: 0.85rem;
    line-height: 1.35;
}

.ss-role-relogin-notice .ti {
    color: var(--kendo-color-info);
    flex-shrink: 0;
    margin-top: 0.1em;
}

/* ── Integration diagnostics pages (BigChange, Sage) ────────────────────────────────────────────
   Flex-fill chain: page -> tabstrip -> active panel -> tab body, so nothing guesses the height of the
   chrome above it (#1430). Replaces three hand-tuned calc(100vh - Npx) offsets that disagreed with each
   other -- 210px on the tab body, 235px on the grids, 250px in the lookup panel whose comment claimed it
   matched the grids. The chrome is variable (the parameter row wraps, the requests-sent expander opens),
   so a fixed subtrahend finishes short of the bottom the moment it grows.

   HERE rather than in BigChange.razor.css because these target elements TELERIK renders: a scoped rule
   compiles to .k-tabstrip-content[b-xxxxx] and matches nothing, silently. It also means the Sage page,
   which reuses .bc-page and has no scoped stylesheet at all, gets the same box rather than none -- it
   never had the padding either. Insphire solves the same problem with an inline <style>; shared here
   because two pages want it. */
.bc-page {
    display: flex;
    flex-direction: column;
    height: 100%;
    box-sizing: border-box;
    overflow: hidden;
    padding: 12px 16px;
}

.bc-page > .k-tabstrip {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.bc-page .k-tabstrip-items-wrapper {
    flex: 0 0 auto;
}

/* The active tab panel takes the tabstrip's leftover height and is itself a column, so a tab never
   collapses to a short strip leaving dead space below the header.

   display NEEDS !important and nothing else here does. Telerik writes style="display: block" INLINE on
   whichever panel is active, and an inline style beats any stylesheet rule that is not !important -- so
   flex and min-height applied, display did not, and the panel stayed a block. Its children then had no
   flex parent to grow into and collapsed to content height, which is the dead band in #1430 and looks
   exactly like the rule never loaded. Measured: the grid was 132px inside a 718px panel. */
.bc-page .k-tabstrip-content {
    flex: 1;
    min-height: 0;
    display: flex !important;
    flex-direction: column;
}

/* Takes what the tab panel leaves. position: relative so the loader overlay fills it and the spinner
   sits in the middle rather than in a short strip under the tab headers. */
.bc-page .bc-tab-body {
    position: relative;
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

/* A Telerik grid cannot resolve Height="100%" against a flex parent that was never given one, so the
   filler takes the space and the grid fills the filler. */
.bc-page .bc-tab-body > .k-grid {
    flex: 1;
    min-height: 0;
}

/* The lookup edit dialog's label column. Telerik's horizontal form gives the label 25% of the form,
   which is 121px at this dialog's width — under the 171px "Planned Duration (mins)" needs, so five
   labels across the fourteen lookups wrapped to two lines and shortened the fields beside them. A
   fixed column sized to the longest label keeps every label on one line and every field aligned.
   Global rather than scoped: Telerik renders .k-window into its own popup container, so a
   .razor.css rule would compile to .k-form-label[b-xxxxx] and match nothing. */
.ss-lookup-window .k-form-horizontal .k-form-field > .k-form-label {
    flex: 0 0 180px;
    width: 180px;
}

/* A frame the dialog can be seen by. Fluent 14 gives .k-window a 1px border at 13% opacity and no
   shadow at all, so a white dialog over a pale grid has almost no edge — it reads as part of the page
   behind it rather than as something sitting over it.
   --kendo-color-border is the theme's own border colour (72% opacity, not 13%), so this stays visible
   and correctly inverted in the dark theme the app defaults to — which a hard-coded black would not. */
.ss-lookup-window {
    border: 2px solid var(--kendo-color-border);
}

/* Fluent draws the bottom edge twice: the border and a ::after offset by -1px. At fractional zoom the two split
   into a double line in any window or tab, so the ::after shows only when it carries focus or an error. */
:is(.k-input, .k-picker):not(.k-focus, :focus-within, .k-invalid)::after {
    border-bottom-color: transparent;
}

/* Capped to the viewport so a long form (a job's financial line) scrolls inside the window instead of
   pushing its title bar and Save/Cancel off screen, with the button row pinned to the bottom. */
.ss-lookup-window .k-window-content {
    overflow-y: auto;
    max-height: calc(100vh - 120px);
}

.ss-lookup-window .k-form-buttons {
    position: sticky;
    bottom: 0;
    z-index: 2;
    background: var(--kendo-color-surface);
    margin-top: 8px;
    padding-top: 12px;
    border-top: 1px solid var(--kendo-color-border);
}

/* SettingsLookupDialog BannerBeside: the summary cards on the left, the fields on the right behind a divider.
   Stretched, so the divider runs the full height. Narrower labels pull the fields left, tighter rows fit Enabled on. */
.ss-lookup-split {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 20px;
}

.ss-lookup-split > .qx-form-readonly-host {
    border-left: 1px solid var(--kendo-color-border);
    padding-left: 16px;
}

.ss-lookup-window .ss-lookup-split .k-form-horizontal .k-form-field + .k-form-field {
    margin-top: 8px;
}

.ss-lookup-window .ss-lookup-split .k-form-horizontal .k-form-field > .k-form-label {
    flex-basis: 160px;
    width: 160px;
}

/* SettingsLookupDialog Aside: a column at its own width left of the form, such as a resource's photo, top-aligned with Reference. */
.ss-lookup-aside {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 20px;
    align-items: start;
}

/* Separate the destructive Delete button from the Add/Edit group. Global rather than scoped
   because SettingsLookupGrid hands the class to a TelerikButton, whose <button> is rendered by
   Telerik and so never carries the scope attribute. */
.ss-delete-btn {
    margin-left: 1.5em;
}

/* The Show deleted control on a Settings lookup, matching CRM Customers and Workforce Jobs exactly —
   switch first, label after. Global for the same reason as .ss-delete-btn: SettingsLookupGrid renders
   this inside a Telerik toolbar tool. */
.ss-showdeleted {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-left: 1.5em;
}

.ss-showdeleted .k-label {
    margin: 0;
    white-space: nowrap;
}

/* The colour cell/field every lookup shares: a small square of the stored colour beside its hex,
   and the picker + textbox row in the edit dialog. Fourteen pages each carried their own copy
   under two names (.crm-* and .wf-*) before they were consolidated here. */
.ss-colour-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.ss-swatch {
    display: inline-block;
    width: 14px;
    height: 14px;
    border-radius: 3px;
    margin-right: 6px;
    vertical-align: middle;
    border: 1px solid var(--kendo-color-border);
}

/* ── Lookup dropdown with a colour swatch ─────────────────────────────────────
   A lookup dropdown with the selected entity's configured colour beside it: the
   dropdown fills the row, the swatch is a thin bar stretched to its height. Shared
   here rather than in a page's own <style> because more than one screen uses it
   (the Jobs edit dialog's status/type/category lookups, the Resources dialog's
   Team) and they must not drift apart. */
.wf-colour-field {
    display: flex;
    align-items: stretch;
    gap: 6px;
}

.wf-colour-field .k-dropdownlist {
    flex: 1 1 auto;
}

/* order:-1 puts the bar before the combobox, at the front of the row. */
.wf-colour-swatch {
    flex: 0 0 auto;
    order: -1;
    width: 5px;
    align-self: stretch;
    border-radius: 3px;
}

/* No selection / no colour set — a faint bar so the row doesn't jump as a colour appears. */
.wf-colour-swatch--empty {
    background: var(--kendo-color-base, #e9ecef);
}

/* ── Skill pills ──────────────────────────────────────────────────────────────
   A resource's skills in their configured colour — the Resources grid, the resource
   editor's multiselect tags and the Resource Teams members list all draw them, so
   they live here rather than in one page's <style> where the other two can't see them.
   Wrap onto a second line rather than widening a grid column. */
.ss-skillpills {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

/* The title tags' "+ Add tag" list: its prompt is the closed pill, so it is not offered again as the first option. */
.qx-tag-add-popup .k-list-optionlabel {
    display: none;
}

/* The tag picker opens over a dialog of the same colour, so it needs an edge, a lift and a visible search box to read as a list. */
.k-popup.qx-tag-add-popup,
.qx-tag-add-popup .k-popup {
    border: 1px solid var(--kendo-color-border-alt, #6e7681);
    border-radius: 6px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
}

.qx-tag-add-popup .k-list-filter .k-searchbox {
    border: 1px solid var(--kendo-color-border-alt, #6e7681);
    border-radius: 4px;
}

.qx-tag-add-popup .k-list-footer {
    border-top: 1px solid var(--kendo-color-border, #30363d);
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 4px;
}

/* Create new tag, the "type to narrow" count, and what the list says when the search matches nothing. */
.qx-tag-add-popup .qx-tag-create {
    width: 100%;
    justify-content: flex-start;
}

.qx-tag-add-popup .qx-tag-add-more,
.qx-tag-add-popup .qx-tag-add-none {
    display: block;
    padding: 4px 8px;
    font-size: 0.85em;
    color: var(--kendo-color-subtle, #8b949e);
}

.ss-skillpill {
    display: inline-block;
    padding: 1px 8px;
    border-radius: 10px;
    background: #9E9E9E;
    color: #fff;
    font-size: .72rem;
    font-weight: 600;
    line-height: 1.5;
    white-space: nowrap;
}

/* The pill in the TagTemplate *is* the tag, so the chip Telerik wraps around it is stripped back to
   nothing — otherwise the colour reads as a pill inside a second grey pill. The remove x keeps its own
   box and comes up to full strength on hover. */
.ss-skill-tags .k-chip {
    background: none;
    border: 0;
    padding: 0;
    gap: 2px;
}

.ss-skill-tags .k-chip-content {
    padding: 0;
    overflow: visible;
}

.ss-skill-tags .k-chip-actions {
    margin-inline-end: 2px;
    opacity: .55;
}

.ss-skill-tags .k-chip:hover .k-chip-actions {
    opacity: 1;
}

/* The job editor is a two-column form, and Job Status / External Reference sat 12px below the Job
   Reference they line up with. Telerik spaces fields with a top margin on every field BUT the first,
   which is right when fields stack in one column and wrong in a grid: the first ROW then has a
   zero-margin field on the left and a 12px one on the right. Giving the first field the same margin as
   the rest levels that row, and costs 12px at the top of the form.
   align-self:start on top of it, so a field carrying a Hint ("Leave blank to auto-generate from the job
   type") is taller than its neighbour without dragging the neighbour down the row with it. */
.wf-edit-window .k-form-layout > .k-form-field {
    align-self: start;
    margin-top: 0;
}

/* …and the row rhythm those margins were providing comes from the grid instead, which applies it BETWEEN
   rows only. Doing it this way round rather than adding the missing margin to the first field: Telerik
   zeroes that one with its own :first-child rule, so matching it means out-specifying a third-party
   selector, where row-gap simply replaces the mechanism. */
.wf-edit-window .k-form-layout {
    row-gap: 12px;
}

/* #1075: the reference cell on the Jobs list, with the held-back marker leading it. A flex row so the
   marker keeps its width and the reference stays on the baseline beside it rather than being pushed onto
   its own line on a narrow column. */
.wf-ref-cell {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

/* Job type / category / parts / status pills, and the booking-status pill beside them. Here rather than in
   a page's own style block because the Jobs List and Job Search both draw them, and a job has to look like
   the same job on either screen. */
.wf-status-pill {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 11px;
    color: #fff;
    font-size: 0.8em;
    font-weight: 600;
}

.wf-booking-pill {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 11px;
    color: #fff;
    font-size: 0.75em;
    font-weight: 600;
    letter-spacing: 0.03em;
}

/* Not yet scheduled — derived from WorkforceJobDto.IsScheduled, so it agrees with the calendar's Unallocated panel. */
.wf-unallocated-pill {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 11px;
    background: var(--kendo-color-warning, #f0ad4e);
    color: #fff;
    font-size: 0.75em;
    font-weight: 600;
}

/* #1075: the ready-to-schedule read-out on the job editor. Deliberately NOT styled like a validation
   message — it is tinted, not red, it sits in the form body rather than on the Save row, and it keeps its
   box in both states so filling in the last field doesn't resize the form under the cursor. */
.wf-ready {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    border-radius: 6px;
    border: 1px solid transparent;
    font-size: .82rem;
    line-height: 1.35;
}

/* Its own span so the tenant's configured marker colour lands on the glyph alone — the box keeps the tint
   that says ready-or-not, which a chosen colour must not be able to make unreadable. */
.wf-ready-icon {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
}

.wf-ready-title {
    font-weight: 600;
}

.wf-ready--ok {
    color: var(--kendo-color-success, #37b400);
    border-color: color-mix(in srgb, var(--kendo-color-success, #37b400) 35%, transparent);
    background: color-mix(in srgb, var(--kendo-color-success, #37b400) 10%, transparent);
}

/* Amber, matching the tile marker this line explains — the two are the same message in two places. */
.wf-ready--hold {
    color: var(--kendo-color-warning, #ffc000);
    border-color: color-mix(in srgb, var(--kendo-color-warning, #ffc000) 35%, transparent);
    background: color-mix(in srgb, var(--kendo-color-warning, #ffc000) 10%, transparent);
}

/* The job editor's roadworks line sits above the Description/Notes tabs in the same form row. */
.wf-roadworks {
    margin-bottom: 8px;
}

/* ── Tick-list filter dropdown ────────────────────────────────────────────────
   One button that opens a checkbox list — same treatment as the Columns control
   on the CRM Pipeline board. Shared here rather than in a component's scoped
   .razor.css because two components render it (the calendar's Teams filter and
   the reusable TickListFilter), and CSS isolation would stamp a scoped copy with
   one component's id, leaving the other unstyled. */
.qx-ticklist {
    position: relative;
    display: inline-flex;
}

/* Reserves the width of the widest count we design for — "(999/999)", hence 9ch — so the button keeps
   one size as values are ticked. Without it the button resized on every click and the filter bar
   reflowed under the cursor. Past 999 values it simply grows again; revisit then. */
.qx-ticklist-count {
    display: inline-block;
    min-width: 9ch;
    text-align: right;
}

.qx-ticklist-popup {
    position: absolute;
    top: 100%;
    right: 0;
    z-index: 100;
    margin-top: 4px;
    padding: 6px;
    min-width: 210px;
    max-height: 340px;
    overflow-y: auto;
    background: var(--kendo-color-surface, #fff);
    border: 1px solid var(--kendo-color-border, #d1d5db);
    border-radius: 6px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, .14);
}

/* A tick-list mounted inside a Telerik toolbar — the CRM Customers column picker (#1374) — needs the
   toolbar to stop clipping it. NO z-index lifts an absolutely-positioned popup out of a clipping ancestor:
   the list renders in full (measured at 354px) and is then cut to the toolbar's 55px, so it looks like a
   sliver of its own first row rather than like a bug.

   BOTH selectors, not just the outer one: Telerik nests a .k-toolbar-items-scroll inside .k-toolbar with
   its own `overflow: auto hidden` for horizontal tool scrolling, and that inner box is the 54px one doing
   the damage — fixing only .k-toolbar changes nothing you can see.

   :has() so it applies wherever a picker is mounted rather than waiting to be rediscovered on the next
   grid. Same problem, and the same fix, as .wf-cal-sidebar keeping its own overflow visible. */
.k-toolbar:has(.qx-ticklist),
.k-toolbar-items:has(.qx-ticklist) {
    overflow: visible;
}

/* Anchor left where the button sits at the left edge of a narrow panel (the 280px
   calendar sidebar) — right-anchored the popup would hang off the panel. */
.qx-ticklist-popup--left {
    left: 0;
    right: auto;
}

/* Type-to-narrow box, shown only once the list is long enough to be worth
   searching. Sticky so it stays reachable while the options below it scroll. */
.qx-ticklist-search {
    position: sticky;
    top: -6px;
    z-index: 1;
    padding: 2px 4px 6px;
    margin: -6px -6px 4px;
    background: var(--kendo-color-surface, #fff);
    border-bottom: 1px solid var(--kendo-color-border, #d1d5db);
}

/* All / None (#995), on their own row above the options. Sticky like the search box so they stay reachable
   while a long list scrolls; the offset stacks them under it rather than over it. */
.qx-ticklist-bulk {
    position: sticky;
    top: 30px;
    z-index: 1;
    display: flex;
    gap: 4px;
    padding: 0 4px 4px;
    margin: 0 -6px 2px;
    background: var(--kendo-color-surface, #fff);
}

/* Without a search box above it there is nothing to sit under — pin it to the top of the popup instead. */
.qx-ticklist-popup > .qx-ticklist-bulk:first-child {
    top: -6px;
    padding-top: 2px;
    margin-top: -6px;
}

.qx-ticklist-none {
    padding: 8px;
    font-size: .8rem;
    font-style: italic;
    color: var(--kendo-color-subtle, #6c757d);
}

.qx-ticklist-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 5px 8px;
    cursor: pointer;
    white-space: nowrap;
}

.qx-ticklist-item:hover {
    background: var(--kendo-color-base-hover, #f3f4f6);
}

/* Notification Centre: an unread alert reads bolder so a busy list still scans. Global rather than
   the page's scoped CSS because Telerik renders the row element itself, so the scope attribute the
   .razor.css relies on is never stamped on it. */
.qx-nc-unread > td {
    font-weight: 600;
}

.qx-nc-unread > td:first-child {
    box-shadow: inset 3px 0 0 0 var(--kendo-color-primary, #0d6efd);
}

/* Deleted tenant rows on Administration > Tenant: dimmed and struck through so they can never be
   mistaken for live ones while "Show deleted" is on.

   NOT in Tenant.razor.css. The class is handed to the grid via OnRowRender, so it lands on a <tr>
   TELERIK renders — a scoped rule would compile to .admin-tenant-row-deleted[b-xxxxx] and silently
   match nothing. This is the documented exception to keeping a component's styles in its own file.
   (CRM Customers' .crm-row-deleted gets away with an inline <style> for the same reason.) */
.admin-tenant-row-deleted { opacity: 0.6; }
.admin-tenant-row-deleted td { text-decoration: line-through; }
.admin-tenant-row-deleted td:last-child { text-decoration: none; }

/* The same three declarations, named once (#1444). There were already two copies of this — Tenants
   above and CRM Customers' .crm-row-deleted in an inline <style> — and #1445 puts a deleted row on 28
   more screens, so a third copy was the point to stop. New screens use THIS one; the two above converge
   onto it as part of that sweep rather than in an unrelated change.

   In app.css and not a .razor.css for the reason given above: OnRowRender hands the class to a <tr>
   Telerik renders, where a scoped rule matches nothing at all. */
.qx-row-deleted { opacity: 0.6; }
.qx-row-deleted td { text-decoration: line-through; }
.qx-row-deleted td:last-child { text-decoration: none; }

/* ── A standalone glyph ───────────────────────────────────────────────────────
   A Tabler webfont icon drawn on its own — not in a chip, which owns its own size.

   These exist only because a webfont icon inherits font-size and the Telerik SVG icon it replaced did
   NOT: .k-svg-icon is sized on the element, so it drew at a fixed 16px whatever the surrounding text was.
   Swapping renderer without these would have shrunk ~107 glyphs from 16px to whatever the local text
   happened to be (14px in most of the app) — a 12% shrink, everywhere, in one commit.

   Values measured against the live Kendo theme rather than assumed:
     .k-svg-icon default / k-icon-md   16px      -> .qx-icon
     k-icon-sm                         14px      -> .qx-icon--sm
     k-icon-lg                         20px      -> .qx-icon--lg
   A webfont icon at font-size N renders N x N, so the numbers map straight across.

   A glyph inside .qx-chip takes NONE of these: the chip's rung sets the size and the icon inherits it,
   which is the whole reason the chip ladder works. */
.qx-icon { font-size: 16px; }
.qx-icon--sm { font-size: 14px; }
.qx-icon--lg { font-size: 20px; }

/* ── The icon chip ────────────────────────────────────────────────────────────
   ONE definition of the chip treatment, at five sizes. The formula is the settled one from the board
   visual system: the accent as the mark, a 22% tint of it as the ground, and the accent again as an
   INSET shadow for the border — inset, never a real border, because chips have a fixed width/height and
   a real border would push a 40px box to 42px.

   Colour always arrives as --c. Three ways to set it, in cascade order: the class default below, a state
   modifier, or inline from data (style="--c: #ec4899"). That is the WorkforceCalendar resource-note
   button's pattern, generalised.

   ADDITIVE FOR NOW (#1228). The ten hand-copies of these three declarations — .pb-av, .pb-add-card-icon,
   .bd-av, .bd-chip, .qxd-chip, .ae-chip, .rf-chip, .qxs-mark, .qxs-av, .wf-cal-chip — are NOT repointed
   here, because that would change how ten existing screens render and this change is meant to be
   invisible outside the previewer. Repointing them is #1185 step 2, and this is the class it points at.
   Sizes match the rungs those ten already use, so the swap is a class rename rather than a retune. */
/* .rf-chip rides along rather than taking the class on its markup, because that markup is built in
   Blazor.ReactFlow/wwwroot/blazorReactFlow.js — a different project, and an ES module whose changes only
   reach the browser if the ?v= query on its import in ReactFlowDiagram.razor.cs is bumped too. Sharing
   the declaration here gets the same result with none of that. It keeps its own 24/6 size. */
.qx-chip,
.rf-chip {
    display: inline-grid;
    place-items: center;
    flex-shrink: 0;
    vertical-align: middle;
    color: var(--c, var(--kendo-color-subtle));
    background: color-mix(in srgb, var(--c, var(--kendo-color-subtle)) 22%, var(--kendo-color-base));
    box-shadow: inset 0 0 0 1px var(--c, var(--kendo-color-subtle));
}

.qx-chip--xs { width: 16px; height: 16px; border-radius: 4px;  font-size: 11px; }
.qx-chip--sm { width: 20px; height: 20px; border-radius: 5px;  font-size: 13px; }
.qx-chip--md { width: 24px; height: 24px; border-radius: 6px;  font-size: 15px; }
.qx-chip--lg { width: 32px; height: 32px; border-radius: 10px; font-size: 18px; }
.qx-chip--xl { width: 40px; height: 40px; border-radius: 12px; font-size: 20px; }

/* A chip draws <TablerIcon> — a plain <i> carrying the webfont classes — so colour inherits and font-size
   sizes it, both without help, and the ladder above is the whole of the sizing.

   There used to be an override here (colour + 1em) aimed at Kendo's span.k-icon.k-svg-icon, for the days
   when a chip could hold a BRIDGED glyph: Kendo styled that wrapper directly, and a value set ON an
   element beats one it would otherwise inherit. That was bug #1133 and the reason 43 .qx-icon-inherit
   classes existed. Both went with the bridge in #1231. */

/* ── Rounded grid frame ───────────────────────────────────────────────────────
   THE HOUSE STYLE for every TelerikGrid — put Class="qx-grid-rounded" on any grid you add or touch.
   overflow:hidden is the part that does the work: the toolbar, header bar and pager are square
   children that would otherwise square the corners straight back off. 8px matches the surface radius
   the boards use without fighting the 4px Kendo puts on inputs.

   Global rather than a .razor.css rule because Telerik renders .k-grid itself, so a scoped rule
   compiles to .qx-grid-rounded[b-xxxxx] and matches nothing.

   Adoption is part-done (Administration > Tenant search results, Settings > Database Schema); the
   rest arrive in a sweep, so a grid without the class is un-migrated rather than an exception. That
   sweep is this selector keyed on .k-grid alone with the per-grid Class deleted — its own change,
   since it restyles every grid at once. */
.qx-grid-rounded.k-grid {
    border-radius: 8px;
    overflow: hidden;
}

/* ── The came-from gutter ─────────────────────────────────────────────────────
   The 28px column that holds one 8px CameFromDot. Telerik gives every cell text padding plus
   text-overflow:ellipsis, so in a theme with roomier cell padding the dot no longer fits its own
   column — and the cell renders the dot followed by an ellipsis, which reads as stray "..” beside it.
   The cell has no text to ellipsise, so clip it and drop the padding it does not need.

   Global rather than a .razor.css rule because Telerik renders the td: a scoped rule would compile to
   .k-table-td[b-xxxxx] and match nothing. Keyed on the dot's own class so it reaches only these cells,
   whichever grid they are in. */
.k-table-td:has(> .qx-camefrom-dot),
.k-grid td:has(> .qx-camefrom-dot) {
    padding-inline: 0;
    overflow: visible;
    text-overflow: clip;
}

/* ── Settings > Widget manager: the form editor's tabs ────────────────────────
   Global because .k-tabstrip is Telerik's, which a scoped rule never matches. The strip takes the
   leftover height and the PANEL scrolls, so the tab headers stay put. */
.wf-tabs {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    border: 0;
}

.wf-tabs > .k-tabstrip-content {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 0;
    border: 0;
}

/* ── Settings > Integration > What3Words (What3WordsFeature) ─────────────────
   Global because the tab is drawn inside QixoConfigSections' Telerik tab strip. One column: its
   sections, then its own actions row — it saves on its own, not with the rest of the screen. */
.ft-feature {
    max-width: 880px;
    display: flex;
    flex-direction: column;
}

.ft-section {
    padding: 16px;
    background: var(--kendo-color-surface, #fff);
    border: 1px solid var(--kendo-color-border, #dee2e6);
    border-radius: 8px;
}

.ft-section + .ft-section {
    margin-top: 12px;
}

.ft-title {
    font-weight: 600;
    margin-bottom: 6px;
}

/* No max-width: each sentence is meant to sit on one line, so let it use the panel's full width.
   The margin is set through a descendant selector rather than on .ft-hint alone because the Kendo
   theme puts a 14px bottom margin on a <p> with a selector that outranks a single class — which left
   an empty line's worth of space between the last line of the hint and the panel's bottom edge. */
.ft-hint {
    color: var(--kendo-color-subtle, #6c757d);
    font-size: .85rem;
}

.ft-feature .ft-section .ft-hint {
    margin: 0;
}

.ft-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.ft-row .k-form-label {
    margin: 0;
}

/* Credential fields: label above its editor, one under the other. */
.ft-fields {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 12px;
}

.ft-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.ft-field .k-form-label {
    margin: 0;
}

/* Sticky to the bottom of the scrolling tab panel, so Save stays reachable as a tab grows past the
   viewport rather than dropping below the fold. Opaque background because the sections scroll under
   it. Save right, the save/error line left — the house rule. */
.ft-actions {
    position: sticky;
    bottom: 0;
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 0 0 auto;
    margin-top: 12px;
    padding: 12px 0 4px;
    border-top: 1px solid var(--kendo-color-border, #dee2e6);
    background: var(--kendo-color-app-surface, #fff);
}

.ft-actions .k-button:first-of-type {
    margin-left: auto;
}

.ft-feature .ft-section .ft-hint + .ft-fields {
    margin-top: 12px;
}

/* One field saved on its own, button beside it, where a sticky Save bar would sit over content (Google's Usage tab). */
.ft-inline-save {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

/* A feature with its own Connection / Usage tabs, inside the Integration tab strip. */
.ft-tabs > .k-tabstrip-content,
.ft-tabs > .k-tabstrip-items-wrapper + .k-tabstrip-content {
    padding: 12px 0 0;
}

/* ── CRM address dialog: the rows built from a template ───────────────────────
   A templated FormItem renders ONLY its template — Telerik generates no label for it — so those rows
   emit their own label and would otherwise sit where the labels are rather than where the editors do.
   These rules make such a row the flex row Telerik would have made: the label keeps the same fixed
   column as the generated ones either side of it, and the control starts where their editors start.
   Used by the What3Words row and the Primary switch.

   In app.css rather than the page's .razor.css because .k-form-field and .k-form-label are rendered by
   TELERIK — a scoped rule would compile to .k-form-field[b-xxxxx] and match nothing. */
.k-form-field.crm-templated-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.k-form-field.crm-templated-row > .k-form-label {
    flex: 0 0 auto;
    margin: 0;
}

/* The What3Words control wraps onto a second line once it carries the two lookup buttons as well as
   Validate, and a row that centres its label then puts "What3Words" beside the GAP between the box and
   the buttons instead of beside the box. This one row aligns to its first line; the Primary switch is a
   single line and stays centred. The padding is half the difference between the label's line box and the
   textbox's height, so the label sits on the value's baseline. */
.k-form-field.crm-templated-row.crm-w3w-row {
    align-items: flex-start;
}

.k-form-field.crm-templated-row.crm-w3w-row > .k-form-label {
    padding-top: 7px;
}

/* Sized to land in the same column as the editors above it rather than running the width of the dialog:
   three words is a short value, and the row reads as one field with a button rather than a wide box. */
.k-form-field.crm-templated-row > .w3w-field {
    flex: 0 0 auto;
    width: 320px;
    min-width: 0;
}

/* ── Multi-line predefined dialogs ────────────────────────────────────────────
   TelerikDialogs.ConfirmAsync/AlertAsync take a STRING and HTML-encode it, so neither a <br /> nor a
   newline puts the second sentence on its own line — it was verified in the browser, and the markup
   shows through literally. There is no RenderFragment overload on DialogFactory to reach for.

   pre-line makes a real "\n" in the message a line break, which is what lets a confirm say what is
   about to happen and, separately, what the consequence is somewhere the user cannot see. Run
   together as one paragraph the second half gets skimmed, and that is the half that matters.

   Safe to apply to every predefined dialog: pre-line only differs from normal where the string
   actually contains a newline, and every existing confirm is concatenated across C# source lines
   without one. Global rather than a .razor.css rule because Telerik renders .k-dialog itself, so a
   scoped rule compiles to .k-dialog[b-xxxxx] and matches nothing. */
.k-dialog.k-alert > .k-dialog-content,
.k-dialog.k-prompt > .k-dialog-content {
    white-space: pre-line;
}


/* ── Dashboards: the widget catalogue dialog ──────────────────────────────────────────────────────
   Global, not scoped, for the same reason .qx-grid-rounded is: Telerik renders a window into its own
   root container outside the component's DOM, so the k-window element never carries the component's
   scoped attribute and a .razor.css rule — ::deep or not — matches nothing. Without the cap the
   catalogue is taller than the viewport and the window centres itself with its search box off-screen. */
.wp-window .k-window-content {
    max-height: calc(100vh - 160px);
    overflow-y: auto;
    /* The sticky search pins below any top padding, and the cards scroll through that gap - .wp-search carries it instead. */
    padding-top: 0;
}

/* The dashboard's carousel and widget settings dialogs, global for the same reason. Both outgrow a short
   screen, which would leave their buttons below the fold with nothing to scroll them into view. */
.dash-carousel-window .k-window-content,
.dash-settings-window .k-window-content {
    max-height: calc(100vh - 120px);
    overflow-y: auto;
}

/* Read-only edit dialog. The Settings lookup screens all share one dialog shape — a TelerikForm inside a
   TelerikWindow — so the guard is defined once here rather than copied into fourteen scoped stylesheets.

   The fields only: the buttons row underneath must stay live so Close still works. pointer-events is a
   CSS suggestion (it stops a mouse and nothing else), which is enough here because the dialog also hides
   Save — there is nothing for a keyboard to reach that could be committed. Where a control has a text box
   of its own that could still be typed into meaningfully, disable it properly at source instead.

   Applied as <div class="qx-form-readonly"> around the form; the CRM customer and job dialogs keep their
   own scoped versions because their read-only areas are shaped differently (tabs, grids). */
.qx-form-readonly .k-form-field,
.qx-form-readonly .k-form-field-wrap {
    pointer-events: none;
}

/* ── Ticket dialog (TicketsPanel). Global because a TelerikWindow renders outside the component's DOM, so scoped rules
   match nothing. Auto-sizes to content, capped on short screens so the content scrolls internally. */
.crm-task-window .k-window-content { overflow-y: auto; max-height: calc(100vh - 120px); }

/* The ticket number in the header: a link to the ticket, with its copy button beside it. */
.crm-task-window .crm-ticket-number { font-size: .875rem; font-weight: 600; color: var(--kendo-color-primary); text-decoration: none; }
.crm-task-window .crm-ticket-number:hover { text-decoration: underline; }
/* The number's copy menu drawn as bare as a CopyButton glyph beside it. */
.crm-task-window .crm-ticket-copy { padding: 0; min-width: 0; color: var(--kendo-color-subtle); }
.crm-task-window .crm-ticket-copy:hover { color: var(--kendo-color-primary); background: none; }

/* #993: close the gap between the title bar and the first field. The values come from the Fluent
   theme's own rules, not from guesswork — an earlier attempt set padding-top on .k-window-content,
   which the theme already sets to 0, so it ADDED 8px instead of removing any. What is actually
   stacked above the first field, and what each is trimmed to:
     .k-window-titlebar   padding-block 24px 16px  -> bottom 8px   (top left alone; the job dialog
                                                                    shares it and reads correctly)
     .k-tabstrip .k-link  padding-block 12px       -> 7px          (shortens the whole tab row)
     .k-tabstrip-content  padding-block 10px       -> top 2px
   .k-form-field already carries margin-block-start: 0 in this theme, so there is no form-row margin
   to remove — form rows are spaced by the layout's row gap. The conflict banner renders nothing until
   there IS a conflict, so none of this affects it. */
.crm-task-window .k-window-titlebar { padding-block-end: 8px; }
.crm-task-window .k-tabstrip-items .k-link { padding-block: 7px; }
.crm-task-window .k-tabstrip-content { padding-top: 10px; }
/* Visible so the window content, not the tab, is the scroll container the buttons stick to. min-height stops
   Attachments shrinking the window. The flex column pins Save/Cancel to the bottom edge, level with the
   progress pane's Post update beside it, however tall the form turns out. */
.crm-task-window .k-tabstrip-content { overflow: visible; min-height: 650px; padding-bottom: 0; }
.crm-task-window .k-tabstrip-content.k-active { display: flex; flex-direction: column; }
.crm-task-window .k-tabstrip-content.k-active .k-form { flex: 1; display: flex; flex-direction: column; }
.crm-task-window .k-tabstrip-content.k-active .k-form > .k-form-buttons { margin-top: auto; }

/* Save/Cancel stay pinned ("sticky") to the bottom-right of the form as it scrolls, so they
   never drop below the fold — the standard Qixo edit-form behaviour. */
.crm-task-window .k-form-buttons {
    position: sticky;
    bottom: 0;
    background: var(--kendo-color-surface, #fff);
    margin-top: 8px;
    padding-top: 12px;
    border-top: 1px solid var(--kendo-color-border, #dee2e6);
    z-index: 2;
}

/* ── CRM address map (#854) ──────────────────────────────────────────────────
   The pin and the geofence handles are DOM elements MapLibre owns, created in
   wwwroot/js/address-map.js, so they never carry a component's scope attribute — a
   .razor.css rule would compile to .qx-geofence-handle[b-xxxxx] and match nothing.
   Same reason .qx-grid-rounded is global. */
.qx-geofence-handle {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #fff;
    border: 2px solid #2563eb;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .4);
    cursor: grab;
}

.qx-geofence-handle:active {
    cursor: grabbing;
}

.qx-address-pin {
    cursor: grab;
    line-height: 0;
}

.qx-address-pin:active {
    cursor: grabbing;
}

/* The address dialog is a form beside a map, so it is wide and the map needs a real height to
   draw into — the one place a fixed height is right, because the map fills whatever it is given
   and the form is short enough to sit inside it. Without the AWS Mapping module there is no map
   column at all, and the dialog collapses back to the single-column form it has always been. */
.crm-address-window .crm-address-layout {
    display: grid;
    grid-template-columns: minmax(0, 420px) minmax(0, 1fr);
    gap: 16px;
    align-items: stretch;
}

.crm-address-window .crm-address-layout > .crm-address-mapcol {
    min-height: 460px;
    display: flex;
    flex-direction: column;
}

.crm-address-window .crm-address-layout.crm-address-nomap {
    grid-template-columns: minmax(0, 1fr);
}

/* ============================================================================
   Workforce job editor (WorkforceJobEditor.razor)

   Global rather than a sibling .razor.css because half of it selects Telerik's own elements
   (.wf-job-dialog .k-form-buttons, .wf-dialog-readonly .k-disabled) — those are rendered by the
   window, not by our markup, so they carry no scope attribute and ::deep has no ancestor of ours
   to hang off. It was an inline <style>, which is global too, so this is the same cascade.
   ============================================================================ */
/* ── The Assistants tab (#1375) ───────────────────────────────────────── */
/* A column: the job's own resource on top, then the tick list under it.

   Deliberately NO height:100%. The dialog gets its height from job-dialog-height.js, which measures the
   Job-detail FORM and pins .k-window-content to it (#1293) — but Telerik's tab pane in between has no
   height of its own, so a percentage here would resolve against an auto-height parent and the list
   below would collapse to nothing. The list is bounded by its own max-height instead, which holds
   whatever the ancestors are doing. */
.wf-crew {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.wf-crew-main {
    display: flex;
    flex-direction: column;
    gap: 2px;
    max-width: 420px;
}

.wf-crew-panel {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.wf-crew-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5em;
    min-height: 28px;
}

.wf-crew-title {
    font-weight: 600;
}

.wf-crew-actions {
    display: flex;
    gap: 0.25em;
}

/* The search box takes the room, the Selected / Not selected filter keeps its own width. min-width: 0
   on the box is what lets it shrink inside the flex row instead of pushing the filter off the end. */
.wf-crew-search {
    display: flex;
    gap: 8px;
    align-items: center;
    min-height: 34px;
    margin: 0.35em 0;
}

.wf-crew-search-box {
    flex: 1 1 auto;
    min-width: 0;
}

/* Bounded by its own max-height rather than by flexing into space an ancestor may not have — see the
   note on .wf-crew. 420px rather than the Role editor's 320: this tab has one field above the list
   where that dialog has two panels, so there is room, and a roster is long enough that every extra row
   on screen is one less scroll while picking a crew. Still shorter than the Job-detail form the dialog
   is pinned to, so switching to this tab never grows the window. */
.wf-crew-list {
    max-height: 420px;
    overflow-y: auto;
    border: 1px solid var(--kendo-color-border);
    border-radius: 4px;
    padding: 0.4em 0.6em;
}

.wf-crew-row {
    display: flex;
    align-items: center;
    gap: 0.5em;
    padding: 0.2em 0;
}

/* Shown, not hidden. Somebody looking for a name that is already the job's resource needs to see why
   it cannot be ticked, rather than wonder where they went. */
.wf-crew-row--main {
    opacity: 0.6;
}

/* Same reasoning for a resource that is no longer enabled (#1377): greyed so it is plainly not an
   ordinary choice, but listed — one already on this job's crew has to be visible to be taken off. */
.wf-crew-row--off {
    opacity: 0.6;
}

.wf-crew-note {
    font-size: 0.8em;
    color: var(--kendo-color-subtle);
}

.wf-crew-note--main {
    margin-left: auto;
    font-style: italic;
}

.wf-crew-hint {
    display: flex;
    flex-direction: column;
    gap: 0.15em;
    font-size: 0.8em;
    color: var(--kendo-color-subtle);
    margin-top: 0.4em;
}

.wf-crew-count {
    font-weight: 600;
    color: var(--kendo-color-on-app-surface);
}

/* The Assistants tab's Save / Cancel row. Deliberately a copy of what .k-form-buttons gets on this
   dialog (see .wf-job-dialog .k-form-buttons below) rather than something new: the two rows have to
   land in the same place and look identical, or switching tabs appears to move the buttons. */
.wf-crew-buttons {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    position: sticky;
    bottom: 0;
    background: var(--kendo-color-surface, #fff);
    margin-top: 8px;
    padding-top: 12px;
    border-top: 1px solid var(--kendo-color-border, #dee2e6);
    z-index: 2;
}


/* Scheduled / Planned Time / Duration on one row (#797). align-items:flex-end keeps the three inputs
   on the same line whatever their labels do, and each field sizes to its own input rather than to the
   form column. The row itself still wraps — that is how the derived departure read-out drops below the
   inputs when the column is tight — but the three inputs do not wrap against each other (#993). */
.wf-schedule-row {
    display: flex;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 10px;
}

.wf-schedule-fields {
    display: flex;
    align-items: flex-end;
    flex-wrap: nowrap;
    gap: 10px;
}

.wf-schedule-field {
    display: flex;
    flex-direction: column;
}

/* The small x beside Resource / Scheduled / Planned Time that clears the field before the job starts. */
.wf-label-clear {
    border: 0;
    background: none;
    padding: 0 2px;
    margin-left: 2px;
    cursor: pointer;
    color: var(--kendo-color-subtle, inherit);
    font-size: 13px;
    line-height: 1;
    vertical-align: middle;
}

.wf-label-clear:hover {
    color: var(--kendo-color-error, inherit);
}

/* #991: Job Status and External Reference share the first row's right-hand cell. The status takes the
   slack so it fills the column on the usual job (no external link) and gives way to the reference when
   there is one. align-items:flex-end keeps both on the same line whatever their labels do. */
.wf-identity-row {
    display: flex;
    align-items: flex-end;
    gap: 12px;
}

.wf-identity-status {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-width: 0;
}

.wf-identity-extref {
    display: flex;
    flex-direction: column;
    flex: 0 1 auto;
    min-width: 0;
}

/* Derived departure at the end of the row — a quiet read-out, not another field. The bottom padding
   sits it on the inputs' own line rather than under them. */
.wf-departure-hint {
    padding-bottom: 6px;
    font-size: 0.8em;
    color: var(--kendo-color-subtle);
    white-space: nowrap;
}

/* Save/Cancel stay pinned ("sticky") to the bottom-right of the form as it scrolls, so they
   never drop below the fold — the standard Qixo edit-form behaviour. */
.wf-job-dialog .k-form-buttons {
    position: sticky;
    bottom: 0;
    background: var(--kendo-color-surface, #fff);
    margin-top: 8px;
    padding-top: 12px;
    border-top: 1px solid var(--kendo-color-border, #dee2e6);
    z-index: 2;
}

/* Read-only view of a job: the whole form is non-interactive so nothing can be changed, but the
   buttons row (Close, View change history) stays clickable. A lightweight read-only — editing may be
   enabled from here later. */
/* One guard for the whole dialog, every tab included. Three things must stay live inside it: the tab
   headers (a view is still something you page through), and both button rows (Close has to work). */
.wf-dialog-readonly { pointer-events: none; }

/* A finished job is closed, but its stock and financial lines, and the approvals a workflow raises once it is done, still
   need working on. Only for someone who may change the job: a read-only viewer gets none of them. */
.wf-dialog-finished .wf-fin,
.wf-dialog-finished .wf-stock,
.wf-dialog-finished .aap-panel,
.wf-dialog-readonly .k-tabstrip-items-wrapper,
.wf-dialog-readonly .k-tabstrip-items,
.wf-dialog-readonly .k-form-buttons,
.wf-dialog-readonly .wf-crew-buttons {
    pointer-events: auto;
}

/* The search pickers (Customer, Resource) are disabled properly rather than only being made
   unclickable, because pointer-events is a CSS suggestion: it stops a mouse and nothing else — not the
   keyboard, not a script. Telerik then greys them, which left them looking broken beside Parts Status
   and Booking Status, which this form leaves looking perfectly normal.

   So: keep the real disable, undo the grey. The value stays as readable as every other field on the
   form, and the fact it cannot be changed is carried by the dialog saying "view" and having no Save —
   the same way the rest of the form already says it. */
.wf-dialog-readonly .k-disabled,
.wf-dialog-readonly .k-combobox.k-disabled {
    opacity: 1;
    filter: none;
}

.wf-dialog-readonly .k-disabled .k-input-inner {
    color: var(--kendo-color-on-app-surface, inherit);
    -webkit-text-fill-color: var(--kendo-color-on-app-surface, inherit);
}

/* The crew tick list is disabled per checkbox, so it greys the same way and needs the same treatment —
   a crew list that fades out is harder to read, and being unable to change it is already said by the
   dialog title. */
.wf-dialog-readonly .k-checkbox:disabled {
    opacity: 1;
}

/* Read-only External Reference line on the job form, shown only when the job has one. Sized to sit
   as a value rather than an editor, so it reads as information and not another thing to fill in. */
.wf-extref-inline {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 32px;
}

.wf-extref-value {
    font-family: var(--kendo-font-family-monospace, monospace);
    overflow-wrap: anywhere;
}

/* External system link popup. Deliberately NOT covered by .wf-dialog-readonly — it is a separate
   window, so it never inherits that pointer-events rule and the External Reference box disables
   itself off _dialogReadOnly instead. */
.wf-extlink {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.wf-extlink-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

/* The textbox takes the slack so the copy button stays against the right-hand edge. */
.wf-extlink-row > :first-child {
    flex: 1 1 auto;
    min-width: 0;
}

.wf-extlink-hint {
    color: var(--kendo-color-subtle, #6c757d);
    font-style: italic;
    font-size: 12px;
    padding-top: 4px;
}

/* Says out loud what the greyed-out box only implies — External Id is written by the sync, and a
   user who cannot see why it is dead will otherwise try to type in it. */
.wf-readonly-tag {
    display: inline-block;
    margin-left: 6px;
    padding: 1px 6px;
    border: 1px solid var(--kendo-color-border, #dee2e6);
    border-radius: 10px;
    background: var(--kendo-color-base-subtle, #f5f5f5);
    color: var(--kendo-color-subtle, #6c757d);
    font-size: 11px;
    font-weight: 400;
    font-style: normal;
    text-transform: uppercase;
    letter-spacing: .04em;
    vertical-align: middle;
}

/* .wf-colour-field / .wf-colour-swatch (the lookup-with-colour rows above) live in app.css — the
   Resources edit dialog uses the same treatment for its Team lookup. */


/* #993: customer picker over its address. The block keeps the full two-column width — the ADDRESS is
   what needs it, and it is the longer of the two — and only the picker above is shortened, which is
   what opens the gap the eye sits in. */
.wf-customer-block {
    display: flex;
    flex-direction: column;
}

/* Picker + eye on one line, address + copy on the next. The picker takes all the width up to the eye,
   exactly as the address box below takes all the width up to the copy button — so the two inputs are
   the same length and the two icons line up in a column down the right-hand edge. min-width:0 lets the
   picker shrink inside the row rather than pushing the icon out of the block. */
.wf-customer-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.wf-customer-row > *:first-child {
    flex: 1 1 auto;
    min-width: 0;
}

/* The supplier editor and stock item windows. Global because Telerik renders the window itself: capped so it
   scrolls internally, with Save/Cancel pinned bottom right as the tabs grow — the customer editor's shape. */
.fin-supplier-edit-window .k-window-content,
.stk-detail-window .k-window-content { max-height: calc(100vh - 120px); overflow-y: auto; }
.fin-supplier-edit-window .k-tabstrip-content { overflow: visible; min-height: 700px; }
/* One fixed height for every tab, so switching tabs never resizes the stock item window. */
.stk-detail-window .stk-detail > .k-tabstrip > .k-tabstrip-content { height: 580px; overflow-y: auto; }
.stk-detail-window .stk-subtabs .k-tabstrip-content { overflow: visible; }

.fin-supplier-edit-window .k-form-buttons,
.stk-detail-window .stk-footer {
    position: sticky;
    bottom: 0;
    z-index: 2;
    background: var(--kendo-color-surface, #fff);
    margin-top: 8px;
    padding-top: 12px;
    border-top: 1px solid var(--kendo-color-border, #dee2e6);
}

/* The customer popup. Same rules as .crm-customer-edit-window on the Customers list — repeated rather
   than shared because those live in that page's own style block and are only present while that page
   is rendered. Auto-sized (no Height), capped so it scrolls internally, Save/Cancel pinned bottom
   right as the tabs grow, and the editor wrapper sized to its content instead of a full page. */
.wf-customer-window .k-window-content { max-height: calc(100vh - 120px); overflow-y: auto; }
.wf-customer-window .k-tabstrip-content { overflow: visible; }

.wf-customer-window .k-form-buttons {
    position: sticky;
    bottom: 0;
    z-index: 2;
    background: var(--kendo-color-surface, #fff);
    margin-top: 8px;
    padding-top: 12px;
    border-top: 1px solid var(--kendo-color-border, #dee2e6);
}

.wf-customer-window .k-window-content .crm-edit { height: auto; padding: 0; overflow: visible; }

/* The finance document window, sized like the job dialog: capped so the form scrolls inside it and Save stays reachable,
   with the same trimmed gap under the title. Here rather than scoped: .k-window-content is rendered by Telerik. */
.fdoc-window .k-window-content,
.fdoc-receive-window .k-window-content { overflow-y: auto; max-height: calc(100vh - 120px); padding-top: 8px; }

/* The job editor floated over another screen (a customer's Jobs tab, a finance document's Job eye). Capped like the
   Jobs screen's own window, so a tall job scrolls inside it rather than pushing its title off the top of the page. */
.wf-job-float-window .k-window-content { overflow-y: auto; max-height: calc(100vh - 120px); }

/* Matches CopyButton's chrome exactly — the two sit one above the other and must read as one pair. */
.wf-customer-open {
    display: inline-flex;
    align-items: center;
    cursor: pointer;
    color: var(--kendo-color-subtle);
}

.wf-customer-open:hover { color: var(--kendo-color-primary); }

/* No customer picked yet — nothing to open. Dimmed and inert rather than removed, so the address
   row below doesn't shift sideways the moment a customer is chosen. */
.wf-customer-open--off {
    opacity: 0.35;
    pointer-events: none;
}

/* The disabled address box with its copy button on the same line — the same shape as the
   colour-swatch fields, so a read-only value beside a small action reads the same wherever the form
   does it. min-width:0 lets the box shrink inside the flex row instead of pushing the button off. */
.wf-address-inline {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 4px;
}

.wf-address-inline .k-textbox { min-width: 0; }

.wf-detail-tabs {
    border: none;
    padding: 0;
}

/* The Assurance tab's badge: a count, and a dot saying whether anything under it is failing. Sized to
   sit inside the tab label without changing the strip's height. */
.wf-assurance-tab {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.wf-assurance-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex: none;
}

.wf-assurance-dot--ok { background: var(--kendo-color-success, #37b400); }
.wf-assurance-dot--bad { background: var(--kendo-color-error, #d51923); }

.wf-assurance-count {
    font-size: 0.75em;
    font-weight: 600;
    line-height: 1;
    padding: 2px 6px;
    border-radius: 9px;
    background: var(--kendo-color-base-subtle, #e9ecef);
    color: var(--kendo-color-on-app-surface, #212529);
}

/* The search pin's popup sits on a near-white map, so it needs an edge of its own to read as a box. */
.qx-pin-popup .maplibregl-popup-content {
    border: 1px solid #6b7280;
    border-radius: 6px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, .35);
}

/* Anchor-qualified: MapLibre's own anchor rule ties on specificity and its stylesheet loads after this one. */
.qx-pin-popup.maplibregl-popup-anchor-bottom .maplibregl-popup-tip,
.qx-pin-popup.maplibregl-popup-anchor-bottom-left .maplibregl-popup-tip,
.qx-pin-popup.maplibregl-popup-anchor-bottom-right .maplibregl-popup-tip {
    border-top-color: #6b7280;
}

.qx-pin-popup.maplibregl-popup-anchor-top .maplibregl-popup-tip,
.qx-pin-popup.maplibregl-popup-anchor-top-left .maplibregl-popup-tip,
.qx-pin-popup.maplibregl-popup-anchor-top-right .maplibregl-popup-tip {
    border-bottom-color: #6b7280;
}

.qx-pin-popup.maplibregl-popup-anchor-left .maplibregl-popup-tip {
    border-right-color: #6b7280;
}

.qx-pin-popup.maplibregl-popup-anchor-right .maplibregl-popup-tip {
    border-left-color: #6b7280;
}
