﻿/* The shared look of panels, help icons and switches (APP-542, the owner's request of 2026-10-27: the same three faults
   pointed out on about five tickets). Loaded by every portal master (Templates/app/App1, App2, App3) and every League
   master (Templates/league/League1 to League6, which my/Member.master sits in). Use these; do not write your own.

   References the owner accepted:
   1. Panel: the Leagues > Program division form (APP-471): the Bootstrap card, with its heading inside.
   2. Help icon: the Triage Center's Clocked In Now card (APP-469): the plain blue ri-question-line that opens a modal.
   3. Switch: the Show all projects switch on a company's Projects tab (APP-512), a form-switch with its label spaced from it.
   Colours come from Bootstrap and the theme's variables, so light and dark follow the theme. */

/* 1. A panel: a card that is a section of a tab or a page (class="card ui-panel"), with its own padding, so it needs no
   card-body; its heading is .ui-panel-title. Same background, border, radius and shadow as every card. */
.card.ui-panel {
    padding: var(--bs-card-spacer-x, 1.25rem);
    margin-bottom: 1rem;
}

.ui-panel-title {
    margin: 0 0 .75rem;
    font-size: 1.25rem;
    font-weight: 500;
    line-height: 1.2;
}

/* 1a. A saved payment card drawn like a real credit card (.ui-card-grid holds them, .ui-card-item is a card with its Saved date and Remove
   under it, .ui-card-face is the card itself; APP-1303): the 85.6 by 54 proportion, a gradient per brand (.ui-card-visa, -mastercard,
   -amex, -discover; any other brand is the grey one), a drawn chip and contactless mark, the number as XXXX XXXX XXXX 1234, the name and
   Expires, and the brand's mark bottom right. The faces are coloured in light and dark alike, so their text is white and not themed. */
.ui-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(16rem, 20rem));
    gap: 1.5rem 1.25rem;
}

.ui-card-face {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    aspect-ratio: 85.6 / 54;
    padding: .8rem 1rem .7rem;
    border-radius: .85rem;
    color: #fff;
    background: linear-gradient(135deg, #5b6472 0%, #2f343d 100%);
    box-shadow: 0 .25rem .75rem rgba(0, 0, 0, .25);
    overflow: hidden;
}

.ui-card-face::after {
    content: "";
    position: absolute;
    top: -40%;
    right: -25%;
    width: 80%;
    height: 140%;
    background: radial-gradient(circle, rgba(255, 255, 255, .16) 0%, rgba(255, 255, 255, 0) 70%);
    pointer-events: none;
}

.ui-card-face.ui-card-visa { background: linear-gradient(135deg, #2a4fb8 0%, #0f1f5c 100%); }
.ui-card-face.ui-card-mastercard { background: linear-gradient(135deg, #3a3f4b 0%, #14161c 55%, #7a2a1c 100%); }
.ui-card-face.ui-card-amex { background: linear-gradient(135deg, #2f86b8 0%, #0f4668 100%); }
.ui-card-face.ui-card-discover { background: linear-gradient(135deg, #5a5f69 0%, #23262d 60%, #b5540f 100%); }
.ui-card-face.ui-card-expired { filter: grayscale(.85); opacity: .75; }
/* A saved bank account (APP-1417) on the same face: a deep green, the bank's mark where a card has its chip, the bank's name beside it, the
   account as four dots and 6789, and "Bank account" where a card has Expires; one being verified is a little greyed, one that can't be charged as an
   expired card is. Its badges (Verifying, Can't be used) sit top right, where an expired card's sits. */
.ui-card-face.ui-card-bank { background: linear-gradient(135deg, #1d7a63 0%, #0b3b30 100%); }
.ui-card-face.ui-card-waiting { filter: grayscale(.35); }
.ui-card-bankmark { display: inline-flex; align-items: center; justify-content: center; width: 2.1rem; height: 1.6rem; border-radius: .3rem; background: rgba(255, 255, 255, .18); font-size: 1.15rem; }
.ui-card-bankname { min-width: 0; max-width: 11rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .8rem; font-weight: 600; letter-spacing: .02em; }

.ui-card-face .ui-card-top,
.ui-card-face .ui-card-bottom {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: .5rem;
}

.ui-card-face .ui-card-top { align-items: flex-start; }

.ui-card-chipbox { display: flex; align-items: center; gap: .5rem; }

.ui-card-chip {
    position: relative;
    width: 2.1rem;
    height: 1.6rem;
    border-radius: .3rem;
    background:
        linear-gradient(90deg, transparent 32%, rgba(90, 60, 0, .45) 32%, rgba(90, 60, 0, .45) 34%, transparent 34%, transparent 66%, rgba(90, 60, 0, .45) 66%, rgba(90, 60, 0, .45) 68%, transparent 68%),
        linear-gradient(0deg, transparent 45%, rgba(90, 60, 0, .45) 45%, rgba(90, 60, 0, .45) 55%, transparent 55%),
        linear-gradient(135deg, #f3dd8f 0%, #c9a43c 100%);
    box-shadow: inset 0 0 0 1px rgba(90, 60, 0, .35);
}

.ui-card-nfc { width: 1.2rem; height: 1.2rem; opacity: .85; }

.ui-card-face .ui-card-number {
    position: relative;
    z-index: 1;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 1.1rem;
    letter-spacing: .06em;
    white-space: nowrap;
    text-shadow: 0 1px 1px rgba(0, 0, 0, .35);
}

.ui-card-face .ui-card-meta { min-width: 0; font-size: .7rem; line-height: 1.25; text-transform: uppercase; letter-spacing: .04em; }
.ui-card-face .ui-card-meta .ui-card-name { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .8rem; }
.ui-card-face .ui-card-meta .ui-card-exp-label { opacity: .75; font-size: .6rem; margin-right: .3rem; }

.ui-card-brand { flex-shrink: 0; display: flex; align-items: center; justify-content: flex-end; min-width: 3.2rem; height: 1.7rem; line-height: 1; }
.ui-card-brand svg { height: 100%; width: auto; }
.ui-card-brand .ui-card-wordmark { font-weight: 800; font-style: italic; letter-spacing: .02em; font-size: 1.35rem; }
.ui-card-brand .ui-card-wordmark.ui-card-amexmark { font-style: normal; font-size: .8rem; padding: .15rem .3rem; border: 2px solid #fff; border-radius: .2rem; }
.ui-card-brand .ui-card-wordmark.ui-card-discovermark { font-style: normal; font-size: .75rem; letter-spacing: .04em; }
.ui-card-brand i { font-size: 1.7rem; }

.ui-card-under { display: flex; justify-content: space-between; align-items: center; gap: .5rem; padding: .35rem .25rem 0; }

/* 1b. Charge a Saved Card (class="card ui-panel ui-charge", Controls/CardCharge.ascx, APP-1302): staff pick one of the card pictures of 1a
   by tapping it (a hidden radio button, Bootstrap's .btn-check, before label.ui-card-pick), then three plain steps (.ui-charge-step with
   its round number), what the charge is for as tiles (.ui-charge-for of label.ui-charge-choice, the same hidden radio buttons), one amount
   and one Charge Card button; the confirmation (.ui-charge-confirm) says the charge back in a sentence. A picked card has the theme's
   primary ring, a tick and "Chosen" under it; a picked tile the primary border and tint. Colours are the theme's, so light and dark follow it. */
.ui-charge .ui-card-grid { grid-template-columns: repeat(auto-fill, minmax(min(16rem, 100%), 20rem)); }
/* A registration's card on a phone leaves a card about 200 px: the number shrinks with the card (container units) rather than being cut off */
.ui-charge .ui-card-face { container-type: inline-size; }
.ui-charge .ui-card-face .ui-card-number { font-size: min(1.1rem, 8.2cqi); }
.ui-charge .ui-card-under { flex-wrap: wrap; row-gap: 0; }
.ui-charge .ui-card-under > span { white-space: nowrap; }

.ui-charge-step {
    display: flex;
    align-items: center;
    gap: .6rem;
    margin: 1.5rem 0 .75rem;
    font-size: 1.05rem;
    font-weight: 600;
}

.ui-charge-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 50%;
    font-size: .9rem;
    font-weight: 700;
    color: var(--bs-primary-text-emphasis);
    background-color: var(--bs-primary-bg-subtle);
    border: 1px solid var(--bs-primary-border-subtle);
}

.ui-charge-form { max-width: 46rem; }

.ui-card-pick {
    position: relative;
    display: block;
    margin: 0;
    cursor: pointer;
}

.ui-card-pick .ui-card-face {
    outline: 3px solid transparent;
    outline-offset: 3px;
    transition: transform .15s ease, box-shadow .15s ease, outline-color .15s ease;
}

.ui-card-pick:hover .ui-card-face { transform: translateY(-2px); box-shadow: 0 .6rem 1.2rem rgba(0, 0, 0, .3); }
.btn-check:checked + .ui-card-pick .ui-card-face { outline-color: var(--bs-primary); }
.btn-check:focus-visible + .ui-card-pick .ui-card-face { outline-color: var(--bs-primary); box-shadow: 0 0 0 .4rem rgba(var(--bs-primary-rgb), .35); }

.ui-card-tick {
    position: absolute;
    top: .55rem;
    right: .55rem;
    z-index: 2;
    display: none;
    align-items: center;
    justify-content: center;
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 50%;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--bs-primary);
    background-color: #fff;
    box-shadow: 0 .1rem .35rem rgba(0, 0, 0, .35);
}

.btn-check:checked + .ui-card-pick .ui-card-tick { display: inline-flex; }

.ui-card-chosen { display: none; font-size: .875rem; font-weight: 600; color: var(--bs-primary-text-emphasis); }
.btn-check:checked + .ui-card-pick .ui-card-chosen { display: inline-flex; align-items: center; }

.ui-charge-for {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(16rem, 100%), 1fr));
    gap: .6rem;
}

.ui-charge-for.ui-charge-for-3 { grid-template-columns: repeat(auto-fill, minmax(min(12rem, 100%), 1fr)); }

.ui-charge-choice {
    display: flex;
    align-items: center;
    gap: .75rem;
    height: 100%;
    margin: 0;
    padding: .7rem .85rem;
    border: 1px solid var(--bs-border-color);
    border-radius: .65rem;
    cursor: pointer;
    transition: border-color .15s ease, background-color .15s ease, box-shadow .15s ease;
}

.ui-charge-choice:hover { border-color: var(--bs-primary); }

.ui-charge-choice-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 2.4rem;
    height: 2.4rem;
    border-radius: 50%;
    font-size: 1.25rem;
    color: var(--bs-primary-text-emphasis);
    background-color: var(--bs-primary-bg-subtle);
}

.ui-charge-choice-text { min-width: 0; }
.ui-charge-choice-title { display: block; font-weight: 600; line-height: 1.25; }
.ui-charge-choice-note { display: block; font-size: .8125rem; line-height: 1.3; color: var(--bs-secondary-color); }

.btn-check:checked + .ui-charge-choice { border-color: var(--bs-primary); background-color: var(--bs-primary-bg-subtle); box-shadow: inset 0 0 0 1px var(--bs-primary); }
.btn-check:checked + .ui-charge-choice .ui-charge-choice-icon { color: #fff; background-color: var(--bs-primary); }
.btn-check:focus-visible + .ui-charge-choice { box-shadow: 0 0 0 .25rem rgba(var(--bs-primary-rgb), .35); }
/* A kind the picked method can't pay (APP-1417: a bank account and an account credit or a donation) is greyed and takes no hover */
.btn-check:disabled + .ui-charge-choice { opacity: .5; cursor: not-allowed; }
.btn-check:disabled + .ui-charge-choice:hover { border-color: var(--bs-border-color); }

/* In dark mode the theme's primary blue is close to the Visa card's and dim on the dark panel, so a picked card's ring and a picked tile's
   border take the lighter primary text colour */
[data-bs-theme="dark"] .btn-check:checked + .ui-card-pick .ui-card-face { outline-color: var(--bs-primary-text-emphasis); }
[data-bs-theme="dark"] .btn-check:checked + .ui-charge-choice { border-color: var(--bs-primary-text-emphasis); box-shadow: inset 0 0 0 1px var(--bs-primary-text-emphasis); }

.ui-charge-reason { margin-top: 1rem; }
.ui-charge-amount .input-group { max-width: 16rem; }

.ui-charge-go {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .5rem 1rem;
    margin-top: 1.5rem;
}

.ui-charge-confirm {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
    padding: 1.1rem 1.25rem;
    border: 1px solid var(--bs-primary-border-subtle);
    border-radius: .75rem;
    background-color: var(--bs-primary-bg-subtle);
}

.ui-charge-confirm-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 50%;
    font-size: 1.4rem;
    color: #fff;
    background-color: var(--bs-primary);
}

.ui-charge-confirm-body { min-width: 0; }
.ui-charge-sentence { margin: 0 0 .35rem; font-size: 1.15rem; font-weight: 600; line-height: 1.4; color: var(--bs-emphasis-color); }
.ui-charge-sentence:focus { outline: none; }
.ui-charge-confirm .small { margin-bottom: .9rem; }

@media (max-width: 575.98px) {
    .ui-charge-confirm { flex-direction: column; gap: .6rem; padding: 1rem; }
    .ui-charge-go .btn, .ui-charge-confirm .btn { flex: 1 1 100%; }
    .ui-charge-amount .input-group { max-width: none; }
}

/* 2. The help icon (button.ui-help > i.ri-question-line), beside a heading: plain, in the theme's blue, with a light tint on
   hover and focus. The Triage Center's card help buttons and icon buttons use it too. */
.ui-help {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 1.875rem;
    height: 1.875rem;
    padding: 0;
    font-size: 1.15rem;
    line-height: 1;
    border: 0;
    border-radius: .375rem;
    color: var(--bs-primary);
    background-color: transparent;
}

.ui-help:hover,
.ui-help:focus-visible {
    color: var(--bs-primary);
    background-color: var(--bs-primary-bg-subtle);
}

/* Colours the pages share, as variables (APP-1678). The Triage Center's task clock banner is a solid dark band with white text, red while
   the viewer isn't clocked in and green while they are; they are its own, not the theme's, as the theme's success is a turquoise that white
   text doesn't read on. The weather colours are the league pages' (leaguemanager.css), lighter for night and storm in dark mode. */
:root {
    --ui-clock-text: #fff;
    --ui-clock-stopped: #b02a37;
    --ui-clock-running: #146c43;
    --ui-weather-sun: #F2A900;
    --ui-weather-night: #5B6BB5;
    --ui-weather-cloud: #7A8691;
    --ui-weather-rain: #2F7FD1;
    --ui-weather-storm: #6B4FBB;
    --ui-weather-snow: #5BB6E5;
    --ui-weather-fog: #9AA3AB;
    --ui-weather-wind: #2A9D8F;
}

[data-bs-theme="dark"] {
    --ui-weather-night: #9AA8E8;
    --ui-weather-storm: #A68DE8;
}

/* 3. A switch's label always has room beside the slider, whether or not the page spaced it itself (Bootstrap's own 0.5rem) */
.form-switch .form-check-input + .form-check-label {
    margin-left: .5rem;
}

/* An unticked check box, radio button or switch has a mid-grey border in both themes, so it can be seen on a white panel: the theme's
   own border (#dee2e6) all but hides it. The portal masters have had this rule since 2026-10-13 (Templates/app/AppStyles.ascx); here
   it reaches the League masters too (the public league site and my/), whose unticked switches showed only a faint outline (APP-917). */
.form-check-input:not(:checked):not(:focus) {
    border-color: #868e96;
}

[data-bs-theme="dark"] .form-check-input:not(:checked):not(:focus) {
    border-color: #7a8594;
}

/* 4. A company's logo (class="company-logo", APP-545, the owner's decision of 2026-10-27): in dark mode a logo of dark artwork on a
   transparent background (Acuity, Bristol Myers Squibb) can't be read on the dark page, so every company logo gets a light backing with
   rounded corners and a little padding. Light mode is unchanged. Put the class on every image that shows a company's logo. */
[data-bs-theme="dark"] .company-logo {
    background-color: var(--bs-white, #fff);
    border-radius: .375rem;
    padding: .25rem;
}

/* 5. Dark mode leftovers (APP-603, the UI consistency audit of 2026-10-28): three hand-set light colours that no theme rule remaps,
   fixed once here for every page instead of on each of the files that write them.
   a. A code-built table's header row (CssClass "table-light"): a near-white bar with black text on the dark page. It takes the dark
      card's own shade and the body text colour.
   b. The light border (style="border: 1px solid #e4e5e7") written onto error boxes: it takes the alert's own border colour.
   c. A light badge (class "text-bg-light"; the theme remaps only ".badge.bg-light"): the same dark chip as .badge.bg-light. */
[data-bs-theme="dark"] .table-light {
    --bs-table-color: var(--bs-body-color);
    --bs-table-bg: rgba(255, 255, 255, .08);
    --bs-table-border-color: var(--bs-border-color);
    --bs-table-striped-bg: rgba(255, 255, 255, .08);
    --bs-table-striped-color: var(--bs-body-color);
    --bs-table-hover-bg: rgba(255, 255, 255, .12);
    --bs-table-hover-color: var(--bs-body-color);
    color: var(--bs-body-color);
    border-color: var(--bs-border-color);
}

/* 5d. Alert text (APP-1144, APP-1308): the app theme (app.min.css) sets each alert's text to its own colour at 85% over a 20% tint, so in
   light mode warning is 1.3:1, info 1.6, success 1.5, danger 2.3, primary 2.9 and secondary 3.0, and in dark mode danger is 3.1, info 4.3,
   primary 2.4 and the links 2.0 to 4.4. Every alert and its link take Bootstrap's own text-emphasis colour for that colour and mode
   (6.8:1 or better in light, 5.5:1 or better in dark). The Enterprise and League templates use Bootstrap's alert, which already does. */
.alert-primary,
.alert-primary .alert-link {
    color: var(--bs-primary-text-emphasis);
}

.alert-secondary,
.alert-secondary .alert-link {
    color: var(--bs-secondary-text-emphasis);
}

.alert-success,
.alert-success .alert-link {
    color: var(--bs-success-text-emphasis);
}

.alert-danger,
.alert-danger .alert-link {
    color: var(--bs-danger-text-emphasis);
}

.alert-warning,
.alert-warning .alert-link {
    color: var(--bs-warning-text-emphasis);
}

.alert-info,
.alert-info .alert-link {
    color: var(--bs-info-text-emphasis);
}

[data-bs-theme="dark"] .alert-danger[style*="e4e5e7"] {
    border-color: var(--bs-alert-border-color) !important;
}

[data-bs-theme="dark"] .text-bg-light,
[data-bs-theme="dark"] .badge.bg-light.text-body {
    background-color: rgb(42, 53, 73) !important;
    color: #e9ecf2 !important;
}

/* 5e. Outline buttons in dark mode (APP-1673; found by APP-962, APP-1814, APP-1815): the theme's btn-outline-secondary (#5e6e86) and
   btn-outline-primary (#306fd6) draw their text and border in the solid colour, which on the dark card is 2.96:1 and 3.2:1. In dark mode
   both take Bootstrap's own text-emphasis colour for text and border (6.4:1 and 6.5:1 on the card), and fill with it, in dark text, when
   hovered, pressed or chosen. A disabled one keeps the colour at Bootstrap's reduced opacity. Light mode is unchanged. */
[data-bs-theme="dark"] .btn-outline-secondary {
    --bs-btn-color: var(--bs-secondary-text-emphasis);
    --bs-btn-border-color: var(--bs-secondary-text-emphasis);
    --bs-btn-hover-color: #11151c;
    --bs-btn-hover-bg: var(--bs-secondary-text-emphasis);
    --bs-btn-hover-border-color: var(--bs-secondary-text-emphasis);
    --bs-btn-active-color: #11151c;
    --bs-btn-active-bg: var(--bs-secondary-text-emphasis);
    --bs-btn-active-border-color: var(--bs-secondary-text-emphasis);
    --bs-btn-disabled-color: var(--bs-secondary-text-emphasis);
    --bs-btn-disabled-border-color: var(--bs-secondary-text-emphasis);
}

[data-bs-theme="dark"] .btn-outline-primary {
    --bs-btn-color: var(--bs-primary-text-emphasis);
    --bs-btn-border-color: var(--bs-primary-text-emphasis);
    --bs-btn-hover-color: #11151c;
    --bs-btn-hover-bg: var(--bs-primary-text-emphasis);
    --bs-btn-hover-border-color: var(--bs-primary-text-emphasis);
    --bs-btn-active-color: #11151c;
    --bs-btn-active-bg: var(--bs-primary-text-emphasis);
    --bs-btn-active-border-color: var(--bs-primary-text-emphasis);
    --bs-btn-disabled-color: var(--bs-primary-text-emphasis);
    --bs-btn-disabled-border-color: var(--bs-primary-text-emphasis);
}

/* 5f. A section's header row inside a card (APP-1831): the record pages write it as <div class="bg-white d-flex ... card-body p-1">, and a card-header as
   <div class="card-header bg-white ...">. The theme (app.min.css) remaps .bg-white to --bs-bg-white, the page's own dark (#1a212d), which is darker than the
   card (#1f2531) it sits in, so the row showed as a bar. In dark mode a bg-white div inside a card, a modal or an offcanvas panel shows its container's colour.
   A bg-white outside those (on the page itself) already equals the page and stays. Light mode is untouched. */
[data-bs-theme="dark"] .card div.bg-white,
[data-bs-theme="dark"] .modal-content div.bg-white,
[data-bs-theme="dark"] .offcanvas div.bg-white {
    background-color: transparent !important;
}

/* 5b. The Beta mark of a Preview Feature (APP-1638): <span class="badge-beta">Beta</span> at the end of its menu link and beside its page heading
   (Core_AppMaster.AddBetaBadges and the heading block). A small amber pill from Bootstrap's subtle warning colours, which follow data-bs-theme, so
   the dark theme needs no rule of its own. The menu AI Orchestration count badge is the reference for size and shape (a .badge rounded-pill);
   this is lighter so a row of entries is not shouting. In the collapsed menu (body[data-sidebar=sm]) a section's entries show only in its
   flyout, where the mark sits beside the entry as in the open menu. */
.badge-beta {
    display: inline-block;
    margin-left: .3rem;
    padding: .08rem .3rem;
    border: 1px solid var(--bs-warning-border-subtle);
    border-radius: 50rem;
    background-color: var(--bs-warning-bg-subtle);
    color: var(--bs-warning-text-emphasis);
    font-size: .6rem;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
    letter-spacing: .01em;
    text-transform: uppercase;
    vertical-align: middle;
}
h1 .badge-beta { vertical-align: .15em; }
/* The collapsed menu, not hovered, clips its entries to two letters: the mark would wrap onto a line of its own as a clipped "B" */
body[data-sidebar="sm"] .left-sidebar:not(:hover) .badge-beta { display: none; }

/* 6. A CheckBoxList or RadioButtonList (class="ui-checklist", APP-604): ASP.NET writes each choice as a bare input and a bare label, so
   the box touches its label and the choices run together. This gives them the room a .form-check has. A single check box is not one of
   these: it is a plain <input type="checkbox" class="form-check-input" runat="server"> in a .form-check with its label (README, Check boxes). */
.ui-checklist input[type="checkbox"],
.ui-checklist input[type="radio"] {
    margin: 0 .4rem 0 0;
    vertical-align: middle;
}

.ui-checklist label {
    margin-right: 1rem;
    vertical-align: middle;
}

/* Who Can See This on Project's and Estimate's file forms (APP-528, APP-1061) and on Company's and Contact's Attachments forms (APP-1756): its choices (class="file-access-mode" on a ui-checklist) and its
   roles and people (class="file-access-list", scrolling and each on a line). On a phone each radio button stays beside its label. */
.file-access-mode input,
.file-access-list input {
    margin-right: .4rem;
}

.file-access-mode label {
    margin-right: 1.5rem;
}

.file-access-list {
    display: block;
    max-height: 220px;
    overflow-y: auto;
}

.file-access-list label {
    white-space: nowrap;
}

@media (max-width: 575.98px) {
    .file-access-mode {
        display: grid !important;
        grid-template-columns: auto 1fr;
        align-items: center;
    }

    /* A long "Name (Role)" wraps beside its box instead of scrolling the list sideways (APP-2071's Overdue Task Notices on Project's
       Edit form; also the roles and people lists of the file forms on Project, Estimate, Company and Contact) */
    .file-access-list {
        display: grid;
        grid-template-columns: auto 1fr;
        align-items: baseline;
        row-gap: .15rem;
    }

    .file-access-list label {
        white-space: normal;
        margin-right: 0;
    }

    .file-access-list br {
        display: none;
    }

    .file-access-list > span {
        display: contents;   /* a disabled list wraps each choice in <span class="aspNetDisabled"> */
    }
}

/* 7. A required field (APP-613, the owner's decision of 2026-10-28): the label of a field the user must fill in carries class="required",
   which adds the red asterisk. Replaces the inline lightcoral span and the text-danger marks. */
.required::after {
    content: " *";
    color: lightcoral;
}

/* 8. Signed in as someone (APP-732): the banner every signed-in master shows (Core_Admin.ImpersonationBannerHtml), pinned to the
   bottom of the window in the theme's warning colours, light and dark. A spacer before it leaves room under the page, so it covers
   nothing. The public masters don't load this file: there the banner's Bootstrap classes (fixed-bottom, bg-warning-subtle and the rest) draw it the same. */
.ui-impersonation {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1100;   /* above the bell's pop-ups and an open window, so End is always in reach */
    padding: 0.5rem 1rem;
    background: var(--bs-warning-bg-subtle, #fff3cd);
    color: var(--bs-warning-text-emphasis, #664d03);
    border-top: 2px solid var(--bs-warning-border-subtle, #ffe69c);
    font-size: 0.9rem;
}

/* 9. A filter strip above a list (APP-1178; first used on AI Orchestration's All tab): a wrapping row of a search box, filters and
   buttons (.ui-filterbar), with the search box growing up to 20rem (.ui-filter-search) and the number of records at the right (.ui-count). */
.ui-filterbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .5rem;
    margin-bottom: .75rem;
}

.ui-filterbar > .form-select,
.ui-filterbar > .form-control {
    width: auto;
    max-width: 12rem;
}

.ui-filterbar > .ui-filter-search {
    flex: 1 1 10rem;
    width: auto;
    min-width: 0;
    max-width: 20rem;
}

@media (max-width: 767.98px) {
    .ui-filterbar > .form-select {
        flex: 1 1 100%;
        min-width: 0;
        max-width: none;
    }
}

.ui-count {
    margin-left: auto;
    font-size: .875rem;
    color: var(--bs-secondary-color);
}

/* 10. A flat list (class="table table-hover ui-list", APP-1178): one line per record, with rules between the rows only and small
   one-line headers. The title cell (.ui-list-title) takes the room left and cuts its text with an ellipsis, its full text in its title
   attribute. Below 768 px each row wraps: the title takes a line of its own, a cell marked .ui-list-end goes to the line's right and
   the row's buttons (.ui-list-actions) and a cell marked .ui-list-full to lines of their own; a cell a phone doesn't need carries d-none d-md-table-cell.
   A stale row (table-warning) takes the theme's warning shade in dark mode, where Bootstrap's stays pale yellow and a link on it can't be read (2.17:1);
   so does a yellow row of an import's results (SheetImport's [data-sheet-import]: Data Import's tabs and Financial > Ledger's Import, APP-2174).
   DataTables' gutter is taken off a list it draws, so the list lines up with what is above it. */
.table.ui-list {
    margin-bottom: 0;
}

.table.ui-list > thead > tr > th {
    padding: .3rem .5rem;
    font-size: .75rem;
    font-weight: 600;
    white-space: nowrap;
    color: var(--bs-secondary-color);
}

.table.ui-list > tbody > tr > * {
    padding: .35rem .5rem;
    white-space: nowrap;
    vertical-align: middle;
}

.table.ui-list > tbody > tr:last-child > * {
    border-bottom: 0;
}

.table.ui-list > tbody > tr > .ui-list-title {
    width: 100%;
    max-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}

[data-bs-theme="dark"] .table.ui-list > tbody > tr.table-warning,
[data-bs-theme="dark"] [data-sheet-import] .table > tbody > tr.table-warning {
    --bs-table-bg: var(--bs-warning-bg-subtle);
    --bs-table-color: var(--bs-body-color);
    --bs-table-border-color: var(--bs-border-color);
    --bs-table-hover-bg: var(--bs-warning-bg-subtle);
    --bs-table-hover-color: var(--bs-body-color);
    color: var(--bs-body-color);
}

.dt-container:has(.ui-list) > .row {
    --bs-gutter-x: 0;
}

@media (max-width: 767.98px) {
    .table.ui-list,
    .table.ui-list > tbody {
        display: block;
        width: 100%;
    }

    .table.ui-list > thead {
        display: none;
    }

    .table.ui-list > tbody > tr {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        column-gap: .5rem;
        row-gap: .15rem;
        padding: .45rem .25rem;
        border-bottom: var(--bs-border-width) solid var(--bs-border-color);
        background-color: var(--bs-table-bg);
    }

    .table.ui-list > tbody > tr:last-child {
        border-bottom: 0;
    }

    .table.ui-list > tbody > tr > * {
        min-width: 0;
        padding: 0;
        border: 0;
    }

    .table.ui-list > tbody > tr > .ui-list-end {
        margin-left: auto;
    }

    .table.ui-list > tbody > tr > .ui-list-title {
        order: 5;
        display: -webkit-box;
        flex: 1 0 100%;
        max-width: 100%;
        white-space: normal;
        overflow-wrap: anywhere;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 2;
    }

    .table.ui-list > tbody > tr > .ui-list-actions {
        order: 6;
        flex: 1 0 100%;
        text-align: right;
    }

    .table.ui-list > tbody > tr > th,
    .table.ui-list > tbody > tr > .ui-list-full {
        flex: 1 0 100%;
    }
}

/* 10a. A list on a phone (APP-1821; the pages' own phone blocks of APP-1809, APP-1810, APP-1814 and APP-1819 made shared). Both act only
   below 768 px; from 768 px up the table is as it was. The page's own rules (which cell goes first, which takes a line of its own) stay
   in its <style>.
   ui-phone-compact: a DataTables list that stays a table but fits the screen without sideways scrolling: smaller type, tighter cell
   padding, and DataTables' <colgroup> (a width on every column, the hidden ones too, which left a blank column) and sort buttons hidden.
   ui-phone-small: the same smaller type (14 px) and cell padding (.35rem .3rem) and nothing more, so DataTables' column widths and sort
   buttons stay (Project's Primary Tasks and Daily Logs, APP-1829).
   ui-phone-rows: a list whose rows are drawn as blocks with no headings, each cell a flowing item of its row (a cell that is the row's last,
   or the "no data" cell, takes a line of its own).
   ui-phone-rows-labels, with ui-phone-rows: a cell with data-label="Name" starts with "Name: " in the muted colour, and an empty cell is hidden. */
@media (max-width: 767.98px) {
    .table.ui-phone-compact,
    .table.ui-phone-small {
        font-size: .875rem;
    }

    .table.ui-phone-small > thead > tr > th,
    .table.ui-phone-small > tbody > tr > td {
        padding: .35rem .3rem;
    }

    .table.ui-phone-compact > colgroup {
        display: none;
    }

    .table.ui-phone-compact > thead > tr > th,
    .table.ui-phone-compact > tbody > tr > td {
        padding: .35rem .2rem;
        font-size: .8125rem;   /* APP-1825: a list with four columns (RFIs, Purchase Requests, Tasks) fits from 370 px up */
    }

    /* An action column's px-2 (Core_Utilities.SortOrderCell and SortOrderHeader: Tasks' drag handles for a supervisor) is !important, so
       it gets the same tight sides here, or the handle column alone pushes the table 4 px past its box at 320 px (APP-1865) */
    .table.ui-phone-compact > thead > tr > th.px-2,
    .table.ui-phone-compact > tbody > tr > td.px-2 {
        padding-left: .2rem !important;
        padding-right: .2rem !important;
    }

    .table.ui-phone-compact > thead .dt-column-order {
        display: none;
    }

    .table.ui-phone-rows > colgroup,
    .table.ui-phone-rows > thead {
        display: none;
    }

    .table.ui-phone-rows,
    .table.ui-phone-rows > tbody {
        display: block;
        width: 100%;
    }

    .table.ui-phone-rows > tbody > tr {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        column-gap: .6rem;
        row-gap: .1rem;
        padding: .45rem .25rem;
        border-bottom: var(--bs-border-width) solid var(--bs-border-color);
    }

    .table.ui-phone-rows > tbody > tr:last-child {
        border-bottom: 0;
    }

    .table.ui-phone-rows > tbody > tr > td {
        min-width: 0;
        padding: 0;
        border: 0;
        box-shadow: none !important;
        background: transparent;
    }

    .table.ui-phone-rows > tbody > tr > td.dt-empty {
        flex: 1 0 100%;
    }

    .table.ui-phone-rows.ui-phone-rows-labels > tbody > tr > td:empty {
        display: none;
    }

    .table.ui-phone-rows.ui-phone-rows-labels > tbody > tr > td[data-label]::before {
        content: attr(data-label) ": ";
        color: var(--bs-secondary-color);
    }
}

/* 10b. The week board (class="table ui-board" on a table: Staffing > Schedules and Time Clocks, APP-1829): people down the side, the days
   across, the header and the person's cell sticky from 768 px up; below 768 px each person is a card with the day above each cell's content
   (the cell's data-day) and the days with nothing (ui-board-empty) hidden. Each cell's minimum width, and the rest of what a slot shows,
   stay in the page's <style>. */
.ui-board > thead > tr > th {
    white-space: nowrap;
    text-align: center;
    vertical-align: bottom;
    font-weight: 600;
}

.ui-board > thead > tr > th:first-child {
    text-align: left;
}

.ui-board > thead .ui-board-holiday {
    display: block;
    font-size: .75rem;
    font-weight: 400;
}

.ui-board > tbody > tr > th {
    white-space: nowrap;
    font-weight: 600;
}

.ui-board > tbody > tr > td {
    vertical-align: top;
    position: relative;
    padding: .35rem;
}

.ui-board .ui-board-today {
    background-color: var(--bs-primary-bg-subtle);
}

.ui-board .ui-board-slot {
    border-left: 3px solid var(--bs-primary);
    background-color: var(--bs-tertiary-bg);
    border-radius: .25rem;
    padding: .25rem .5rem;
    margin-bottom: .3rem;
    font-size: .85rem;
    line-height: 1.25;
}

.ui-board .ui-board-slot a.ui-board-link {
    color: inherit;
    text-decoration: none;
    display: block;
}

.ui-board .ui-board-slot a.ui-board-link:hover .ui-board-time {
    text-decoration: underline;
}

@media (min-width: 768px) {
    .ui-board > thead > tr > th:first-child {
        position: sticky;
        left: 0;
        background-color: var(--bs-tertiary-bg);
        z-index: 2;
    }

    .ui-board > tbody > tr > th {
        position: sticky;
        left: 0;
        background-color: var(--bs-tertiary-bg);
        z-index: 1;
    }
}

@media (max-width: 767.98px) {
    .ui-board,
    .ui-board > tbody,
    .ui-board > tbody > tr,
    .ui-board > tbody > tr > th,
    .ui-board > tbody > tr > td {
        display: block;
        width: 100%;
    }

    .ui-board > thead {
        display: none;
    }

    .ui-board > tbody > tr {
        border: 1px solid var(--bs-border-color);
        border-radius: .375rem;
        margin-bottom: .75rem;
        overflow: hidden;
    }

    .ui-board > tbody > tr > th {
        background-color: var(--bs-tertiary-bg);
        border: 0;
        padding: .5rem .75rem;
    }

    .ui-board > tbody > tr > td {
        min-width: 0;
        border: 0;
        border-top: 1px solid var(--bs-border-color);
        padding: .4rem .75rem;
    }

    .ui-board > tbody > tr > td::before {
        content: attr(data-day);
        display: block;
        font-size: .75rem;
        font-weight: 600;
        color: var(--bs-secondary-color);
    }

    .ui-board > tbody > tr > td.ui-board-empty {
        display: none;
    }
}

/* 11. A record's details beside it (class="ui-fields" on a dl, APP-1178): one-line labels and their values in two columns */
.ui-fields {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    column-gap: 1rem;
    row-gap: .5rem;
    margin: 0;
    font-size: .875rem;
}

.ui-fields > dt {
    font-weight: 400;
    white-space: nowrap;
    color: var(--bs-secondary-color);
}

.ui-fields > dd {
    margin: 0;
    overflow-wrap: anywhere;
}

/* 12. A comment or a change in a record's activity (class="ui-comment", APP-1178): a rule above it instead of a box of its own */
.ui-comment {
    padding: .75rem .5rem;
    border-top: var(--bs-border-width) solid var(--bs-border-color);
}

/* 13. Long text cut to eight lines, above a Show All button (class="ui-clamp", APP-1178): the page's script takes the class away */
.ui-clamp {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 8;
}

/* 13a. A work item's words drawn from their marked-up text (class="ui-text" on the box, Core_WorkList.RenderText, APP-1284): paragraphs, headings, lists, code, a table,
   with no margin left under the last block. A box of code (pre.ui-code) is the one the close-out's commands sit in too. Affects the Work Item page and Work list only. */
.ui-text > :last-child { margin-bottom: 0; }
.ui-text p { margin: 0 0 .5rem; }
.ui-text h5, .ui-text h6 { margin: .75rem 0 .25rem; font-weight: 600; line-height: 1.3; }
/* A heading in the words is never larger than a box heading (1rem, .h6) or the text around it (APP-1284, owner 2026-11-05): it is only bold */
.ui-text h5, .ui-text h6 { font-size: 1rem; }
.ui-text > :first-child { margin-top: 0; }
.ui-text ul, .ui-text ol { margin: 0 0 .5rem; padding-left: 1.5rem; }
.ui-text li { margin-bottom: .125rem; }
.ui-text li > ul, .ui-text li > ol { margin: .25rem 0 0; }
.ui-text hr { margin: .75rem 0; }
.ui-text .table { width: auto; max-width: 100%; margin-bottom: .5rem; }
.ui-text th, .ui-text td { padding: .25rem .5rem; vertical-align: top; }
/* a table keeps the width its cells need and scrolls inside its box (.table-responsive), as a code box does, and on a phone a cell stays on one line */
.ui-text .table-responsive > .table { width: auto; min-width: 100%; max-width: none; }
@media (max-width: 575.98px) { .ui-text th, .ui-text td { white-space: nowrap; } }
pre.ui-code {
    margin: 0 0 .5rem;
    padding: .75rem 1rem;
    overflow: auto;
    white-space: pre;
    border: var(--bs-border-width) solid var(--bs-border-color);
    border-radius: var(--bs-border-radius-lg);
    background-color: var(--bs-tertiary-bg);
    color: var(--bs-body-color);
}
pre.ui-code > code { color: inherit; font-size: .875rem; word-break: normal; }
/* A command a person must read whole and copy (APP-2138, the text reply topic steps) wraps instead of scrolling inside its box: pre.ui-code.ui-code-wrap. Boxes without the class are unchanged. */
pre.ui-code.ui-code-wrap { white-space: pre-wrap; overflow-wrap: anywhere; }

/* 13b. A rich-text box over a work item's marked-up text (class="rich-text-editor work-text", Assets/js/work-text.js, APP-1284): shorter than a message's, and scrolling
   inside itself once it is long; work-text-tall is for a request. Quill's own stylesheet loads after this one, so the selector names both classes. */
.rich-text-editor.work-text .ql-editor { min-height: 6rem; max-height: 24rem; overflow-y: auto; font-size: 1rem; }
.rich-text-editor.work-text .ql-editor h1, .rich-text-editor.work-text .ql-editor h2, .rich-text-editor.work-text .ql-editor h3,
.rich-text-editor.work-text .ql-editor h4, .rich-text-editor.work-text .ql-editor h5, .rich-text-editor.work-text .ql-editor h6 { font-size: 1rem; font-weight: 600; }
.rich-text-editor.work-text.work-text-tall .ql-editor { min-height: 11rem; max-height: 32rem; }
/* A picture in the text (APP-2077, Platform_TextPictures): in the box at its own size up to the box's width, and on the page on a line of its own between
   the words before and after it, opening at full size; a marker whose file isn't one of the record's pictures reads "Picture not found". */
.rich-text-editor.work-text .ql-editor img { max-width: 100%; max-height: 20rem; border-radius: .375rem; }
.ui-text-picture-link { display: inline-block; max-width: 100%; vertical-align: top; }
.ui-text-picture { display: block; max-width: 100%; max-height: 32rem; height: auto; margin: .25rem 0; border: 1px solid var(--bs-border-color); border-radius: .375rem; background: var(--bs-body-bg); }
.ui-text-picture-missing { display: inline-block; padding: .125rem .5rem; border: 1px dashed var(--bs-border-color); border-radius: .375rem; color: var(--bs-secondary-color); font-size: .875rem; }
/* In dark mode Quill's toolbar icons are drawn #444 on the dark bar and its placeholder is dark too: these boxes use the page's own colours (other editors of the site are unchanged) */
[data-bs-theme="dark"] .work-text-toolbar.ql-snow .ql-stroke { stroke: var(--bs-body-color); }
[data-bs-theme="dark"] .work-text-toolbar.ql-snow .ql-fill { fill: var(--bs-body-color); }
[data-bs-theme="dark"] .work-text-toolbar.ql-snow .ql-picker { color: var(--bs-body-color); }
[data-bs-theme="dark"] .work-text-toolbar.ql-snow button:hover .ql-stroke, [data-bs-theme="dark"] .work-text-toolbar.ql-snow button.ql-active .ql-stroke { stroke: var(--bs-primary); }
[data-bs-theme="dark"] .rich-text-editor.work-text .ql-editor.ql-blank::before { color: var(--bs-secondary-color); }
.work-text-toolbar button.work-text-codeblock i { font-size: 1.05rem; line-height: 1; color: #444; }
[data-bs-theme="dark"] .work-text-toolbar button.work-text-codeblock i { color: var(--bs-body-color); }

/* 13c. A review box of the Ready to Close section that is one link to the reviewer's comment (a.ui-review-box, APP-1284): hover and keyboard focus show it is a link; the box keeps its own colours */
a.ui-review-box, button.ui-review-box { color: inherit; cursor: pointer; transition: box-shadow .15s ease-in-out; }
a.ui-review-box:hover, button.ui-review-box:hover { color: inherit; box-shadow: 0 0 0 .2rem rgba(var(--bs-primary-rgb), .25); }
a.ui-review-box:focus-visible, button.ui-review-box:focus-visible { color: inherit; outline: 2px solid var(--bs-primary); outline-offset: 2px; }
/* The same box as a button (the status tiles of a task's Dashboard card, APP-1409) opens a tab of the page */
/* The status tiles along the foot of a task's Dashboard card (APP-1409): edge to edge, no gaps, a hairline between them, four across from md and
   two by two on a phone; the card's own border and rounded corners close them in, so each tile has none of its own */
.ui-status-tiles { display: flex; flex-wrap: wrap; overflow: hidden; margin: 0; border-top: 1px solid var(--bs-border-color); border-radius: 0 0 var(--bs-card-inner-border-radius, .375rem) var(--bs-card-inner-border-radius, .375rem); }
.ui-status-tiles > .ui-status-tile { flex: 1 1 50%; min-width: 0; margin: -1px 0 0 -1px; }
@media (min-width: 768px) { .ui-status-tiles > .ui-status-tile { flex: 1 1 0; } }
.ui-status-tile > * { display: block; width: 100%; height: 100%; margin: 0; padding: .3rem .75rem; border: 0; border-radius: 0; text-align: start; line-height: 1.3; box-shadow: inset 1px 1px 0 var(--bs-border-color); }
.ui-status-tile > button.ui-review-box:hover { box-shadow: inset 0 0 0 .15rem rgba(var(--bs-primary-rgb), .35); }
.ui-status-tile > button.ui-review-box:focus-visible { outline-offset: -2px; }

/* 14. The Refresh icon on a DataTables list (button.ui-refresh, APP-1201; Assets/js/table-refresh.js puts it there): the plain blue
   icon of the help icon (2), at the end of the list's search box, or alone at the end of a bar above a list without one. */
.ui-refresh {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 1.875rem;
    height: 1.875rem;
    padding: 0;
    font-size: 1.15rem;
    line-height: 1;
    border: 0;
    border-radius: .375rem;
    color: var(--bs-primary);
    background-color: transparent;
}

.ui-refresh:hover,
.ui-refresh:focus-visible {
    color: var(--bs-primary);
    background-color: var(--bs-primary-bg-subtle);
}

/* Busy while the table is being fetched (table-refresh.js sets aria-busy and .is-busy), and the short message beside it */
.ui-refresh.is-busy {
    cursor: progress;
    opacity: .75;
}

.ui-refresh.is-busy i {
    display: inline-block;
    animation: ui-refresh-spin 1s linear infinite;
}

@keyframes ui-refresh-spin {
    to { transform: rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
    .ui-refresh.is-busy i { animation: none; }
}

.ui-refresh-msg {
    margin-left: .5rem;
    min-width: 0;
    font-size: .8rem;
    line-height: 1.2;
    white-space: normal;
}

.ui-refresh-bar {
    display: flex;
    justify-content: flex-end;
    margin-bottom: .25rem;
}

/* 14a. A card's header row on a phone (APP-1851): a list card's header is a flex row, the title, then a block of buttons (Ledger, Add Category) at the right,
   then the Refresh icon table-refresh.js appends to the row. The buttons are text-nowrap, so at 320 px the row was wider than the card and pushed the Refresh
   icon (and the page) sideways. Below 576 px the row wraps: the title may shrink and wrap, the buttons keep to a block of their own that wraps with a gap
   (dropping under the title when they do not fit), and the Refresh icon stays at the end of the row. The same row inside a card body (the record pages'
   section header, item 5f) is treated alike. From 576 px the row is as it was. A modal's title keeps clear of the theme's close button, which sits in the
   header's top right corner without reserving room below 576 px. */
@media (max-width: 575.98px) {
    .card-header.d-flex,
    .card-body.d-flex:has(> .card-title) {
        flex-wrap: wrap;
        column-gap: .5rem;
        row-gap: .375rem;
    }
    .card-header.d-flex > .card-title,
    .card-body.d-flex:has(> .card-title) > .card-title {
        min-width: 0;
        overflow-wrap: anywhere;
    }
    .card-header.d-flex > .ms-auto:not(.ui-refresh),
    .card-body.d-flex:has(> .card-title) > .ms-auto:not(.ui-refresh) {
        display: flex;
        flex-wrap: wrap;
        gap: .375rem;
        justify-content: flex-end;
        min-width: 0;
        max-width: 100%;
    }
    .card-header.d-flex > .ms-auto:not(.ui-refresh) > .btn,
    .card-body.d-flex:has(> .card-title) > .ms-auto:not(.ui-refresh) > .btn {
        margin-left: 0 !important;
    }
    .card-header.d-flex > .ui-refresh,
    .card-body.d-flex:has(> .card-title) > .ui-refresh {
        margin-left: auto !important;
    }
    .modal-header .modal-title { padding-right: 2rem; }
}

/* 15. A record page (class="record-page" on the page's container-fluid, APP-993; the owner's request of 2026-10-20, APP-317, "Record pages" in
   documentation/Design/websites/webroot/README.md): Company, Contact, Estimate, Project, Task and every page built like them each carried
   this block under their own prefix. On a phone the action buttons beside each section title wrap onto their own lines with a gap, the
   side menu's buttons shrink and the cards lose some padding. */
@media (max-width: 767.98px) {
    /* The buttons' row only: not a panel, a grid row or a modal that happens to follow a heading (APP-1897: a panel after a setting's heading on Features
       Configuration sized its table to its content and widened the page at 320 px; a closed modal there became a full-screen layer that took every tap) */
    .record-page .card-title + div:not(.card):not(.row):not(.modal) { display: flex; flex-wrap: wrap; gap: .375rem; margin-top: .375rem; }
    .record-page .card-title + div > .btn { margin-left: 0 !important; }
    .record-page #menu-nav { gap: .25rem; }
    .record-page #menu-nav .nav-link { padding: .25rem .6rem; font-size: .875rem; }
    .record-page #divTabMenu > .card-body { padding: .5rem; }
    .record-page .record-content { padding: .5rem; }
    /* A pick-list with its Add button stays on one line, with the list taking the room the button leaves */
    .record-page .card-title + div:has(> .form-select) { flex-wrap: nowrap; width: 100%; }
    .record-page .card-title + div > .form-select { min-width: 0; }
}
/* 16. The icon of the page's menu section, left of the page title (i.ui-section-icon, APP-1407): Core_AppMaster writes it at the start of the master's title and of a record
   page's own header (lblHeaderTitle), from the same list as the menu's icons (Core_AppMenu), so it is in the menu's colour. Sized with the title it stands beside
   (em), and a little smaller on a phone, where the title is. */
.ui-section-icon {
    font-size: 1.35em;
    line-height: 1;
    margin-right: .5rem;
    vertical-align: middle;
}
/* The title that holds the icon is a row with the icon on its first line (APP-1441): the icon's centre and the first line's centre share one
   line on a list page, a record page and a task, and when the title wraps on a phone the icon stays beside the first line. */
:is(h1, h2, h3, span, div):has(> i.ui-section-icon) { display: flex; align-items: flex-start; }
:is(h1, h2, h3, span, div):has(> i.ui-section-icon) > i.ui-section-icon { margin-top: -.07em; }
/* The header icon is in the theme's primary colour (the menu's pale text-info is faint on a light header), brighter in dark mode; Triage Center keeps its own
   inline red. The Bootstrap colour classes are !important, so this is too. */
i.ui-section-icon:not([style]) { color: var(--bs-primary) !important; }
[data-bs-theme="dark"] i.ui-section-icon:not([style]) { color: var(--bs-primary-text-emphasis) !important; }
@media (max-width: 575.98px) {
    .ui-section-icon { font-size: 1.2em; margin-right: .375rem; }
}

/* 17. A grid of cards, one per record (class="row g-3 ui-program-grid" holding col-* divs, each with a card ui-panel ui-program-card, APP-1443; Leagues > Programs).
   The whole card is the link (the title's stretched-link); an editor's drag handle sits above it. A running season is a green edge and badge, an inactive
   program is greyed. Colours come from Bootstrap's theme variables, so dark mode follows. APP-1444 shares the card. */
.ui-program-card {
    position: relative;
    gap: .35rem;
    border-left: .25rem solid var(--bs-border-color);
    transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.ui-program-card.ui-program-running { border-left-color: var(--bs-success); }
.ui-program-card:hover, .ui-program-card:focus-within { transform: translateY(-.15rem); box-shadow: 0 .5rem 1rem rgba(var(--bs-emphasis-color-rgb), .15); }
@media (prefers-reduced-motion: reduce) { .ui-program-card { transition: none; } .ui-program-card:hover, .ui-program-card:focus-within { transform: none; } }
.ui-program-card.ui-program-inactive { background-color: var(--bs-tertiary-bg); }
.ui-program-card.ui-program-inactive > :not(.ui-program-handle) { opacity: .6; }
.ui-program-icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 3.5rem; height: 3.5rem; border-radius: 50%; margin-bottom: .25rem;
    font-size: 1.9rem; line-height: 1;
    color: var(--bs-secondary-color); background-color: var(--bs-secondary-bg);
}
.ui-program-icon-primary { color: var(--bs-primary-text-emphasis); background-color: var(--bs-primary-bg-subtle); }
.ui-program-icon-success { color: var(--bs-success-text-emphasis); background-color: var(--bs-success-bg-subtle); }
.ui-program-icon-danger { color: var(--bs-danger-text-emphasis); background-color: var(--bs-danger-bg-subtle); }
.ui-program-icon-warning { color: var(--bs-warning-text-emphasis); background-color: var(--bs-warning-bg-subtle); }
.ui-program-icon-info { color: var(--bs-info-text-emphasis); background-color: var(--bs-info-bg-subtle); }
.ui-program-icon-orange { color: #b45309; background-color: #ffedd5; }
/* Baseball is blue and softball pink (owner, 2026-11-08); a later sport is one more colour name here and one row in App_Code/Core_SportIcon.vb. */
.ui-program-icon-blue { color: #1d4ed8; background-color: #dbeafe; }
.ui-program-icon-pink { color: #be185d; background-color: #fce7f3; }
[data-bs-theme="dark"] .ui-program-icon-blue { color: #93c5fd; background-color: #172554; }
[data-bs-theme="dark"] .ui-program-icon-pink { color: #f9a8d4; background-color: #500724; }
[data-bs-theme="dark"] .ui-program-icon-orange { color: #fdba74; background-color: #431407; }
.ui-program-title { margin: 0; font-size: 1.25rem; font-weight: 500; line-height: 1.25; overflow-wrap: anywhere; }
.ui-program-title a { color: inherit; text-decoration: none; }
.ui-program-title a:focus-visible { outline: 2px solid var(--bs-primary); outline-offset: 2px; }
.ui-program-badges { display: flex; flex-wrap: wrap; gap: .35rem; }
.ui-program-season { margin-top: auto; padding-top: .5rem; display: flex; flex-direction: column; align-items: flex-start; gap: .25rem; }
.ui-program-season-title { font-weight: 500; overflow-wrap: anywhere; }
/* The drag handle: top right, above the stretched link */
.ui-program-handle { position: absolute; top: .5rem; right: .5rem; z-index: 2; }
/* A carried card (sort-order.js puts .sort-order-dragging on its column): the column stays clear and the card is lifted */
.ui-program-grid > .sort-order-dragging { background: none; box-shadow: none; }
.ui-program-grid > .sort-order-dragging .ui-program-card { box-shadow: 0 .5rem 1.25rem rgba(0, 0, 0, .35); border-color: var(--bs-primary); }

/* 18. A season as a card, with its divisions as a list inside it (class="card ui-panel ui-season-card", APP-1444; Leagues > Program, Current Seasons and Past Seasons).
   The same card as 17: a running season has the green edge, an ended or inactive one is plain or greyed. The head holds the drag handle, the title with its badges and
   the actions (.ui-season-actions: Edit, Signups, Add Division, and the place APP-1446's Rollover button takes); under it the dates, the counts as small chips and the
   one-line registration status. The divisions are .ui-division-list, one row each: handle, name (a division with a parent is indented), teams, Edit. */
.ui-season-list { display: flex; flex-direction: column; gap: 1rem; }
.ui-season-list > .sort-order-dragging { background: none; box-shadow: none; }
.ui-season-card { position: relative; margin-bottom: 0 !important; border-left: .25rem solid var(--bs-border-color); gap: .5rem; }
.ui-season-card.ui-season-running { border-left-color: var(--bs-success); }
.ui-season-card.ui-season-inactive { background-color: var(--bs-tertiary-bg); }
.ui-season-card.ui-season-inactive .ui-season-body { opacity: .65; }
.ui-season-list > .sort-order-dragging .ui-season-card { box-shadow: 0 .5rem 1.25rem rgba(0, 0, 0, .35); border-color: var(--bs-primary); }
.ui-season-head { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .75rem; }
.ui-season-title { margin: 0; font-size: 1.25rem; font-weight: 500; line-height: 1.25; overflow-wrap: anywhere; }
.ui-season-badges { display: inline-flex; flex-wrap: wrap; gap: .35rem; }
.ui-season-actions { margin-left: auto; display: flex; flex-wrap: wrap; gap: .35rem; }
.ui-season-meta { display: flex; flex-wrap: wrap; align-items: center; gap: .25rem 1rem; color: var(--bs-secondary-color); }
.ui-season-counts { display: flex; flex-wrap: wrap; gap: .35rem; }
.ui-season-count { display: inline-flex; align-items: center; gap: .3rem; padding: .15rem .6rem; border-radius: 50rem; font-size: .8125rem; color: var(--bs-body-color); background-color: var(--bs-secondary-bg); white-space: nowrap; }
.ui-season-registration { font-size: .875rem; color: var(--bs-secondary-color); overflow-wrap: anywhere; }
.ui-season-registration strong { color: var(--bs-body-color); font-weight: 600; }
.ui-division-list { list-style: none; margin: .25rem 0 0; padding: 0; border-top: 1px solid var(--bs-border-color); }
.ui-division-row { display: flex; align-items: center; gap: .5rem; padding: .5rem 0; border-bottom: 1px solid var(--bs-border-color-translucent); }
.ui-division-row:last-child { border-bottom: 0; }
.ui-division-row.ui-division-child .ui-division-name { padding-left: 1.25rem; }
.ui-division-handle { flex: 0 0 auto; width: 1.5rem; text-align: center; }
.ui-division-name { min-width: 0; flex: 1 1 auto; overflow-wrap: anywhere; }
.ui-division-name .ui-division-parent { color: var(--bs-secondary-color); font-size: .8125rem; white-space: nowrap; }
.ui-division-name .ui-division-rules { display: block; color: var(--bs-secondary-color); font-size: .8125rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ui-division-teams { flex: 0 0 auto; white-space: nowrap; }
.ui-division-actions { flex: 0 0 auto; white-space: nowrap; }
.ui-division-row.sort-order-dragging { background-color: var(--bs-primary-bg-subtle); }
.ui-season-toggle { display: inline-flex; align-items: center; gap: .25rem; }
.ui-season-toggle[aria-expanded="true"] .ri-arrow-down-s-line { transform: rotate(180deg); }
.ui-season-empty { color: var(--bs-secondary-color); }
@media (max-width: 575.98px) {
    .ui-season-actions { margin-left: 0; width: 100%; }
    .ui-division-row.ui-division-child .ui-division-name { padding-left: .75rem; }
}

/* 19. The league look (APP-1568; "The league look" in documentation/Design/websites/webroot/README.md). League pages are used by volunteers and parents, not office
   staff, so they are simple, well laid out and not a back-office form. First built on Leagues > Program; the other league pages copy it.
   - A heading card (.ui-hero): the sport's icon (the same .ui-program-icon-* colours as the cards on Programs), a coloured edge on the left that takes the icon's
     colour, the name, a line of friendly words and badges (.ui-hero-sub), and the way back or the page's actions (.ui-hero-actions). Numbers a person looks for
     are large, in tiles (.ui-stats > .ui-stat), not table cells.
   - Tabs across the top (.ui-tabs on a .nav-tabs): one line, scrolling sideways on a phone, so a tab never wraps or moves the page.
   - Facts in words (.ui-facts: an icon, a label and the value, one row each) instead of a read-only grid of fields.
   - A line of a name and a small help icon is .ui-help beside the text of what it explains (.ui-help-text). */
.ui-hero { position: relative; overflow: hidden; padding-left: calc(var(--bs-card-spacer-x, 1.25rem) + .4rem); }
:where(.ui-hero-edge) { color: var(--bs-secondary-color); }
.ui-hero > .ui-hero-edge { position: absolute; top: 0; bottom: 0; left: 0; width: .4rem; background-color: currentColor; }
.ui-hero-main { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1rem; }
.ui-hero-icon { flex: 0 0 auto; margin-bottom: 0; width: 4rem; height: 4rem; font-size: 2.1rem; }
.ui-hero-text { flex: 1 1 14rem; min-width: 0; }
.ui-hero-eyebrow { font-size: .875rem; color: var(--bs-secondary-color); overflow-wrap: anywhere; }
.ui-hero-eyebrow a { color: inherit; text-decoration: none; }
.ui-hero-eyebrow a:hover, .ui-hero-eyebrow a:focus-visible { color: var(--bs-primary); text-decoration: underline; }
.ui-hero-title { margin: 0; font-size: 1.65rem; font-weight: 600; line-height: 1.2; overflow-wrap: anywhere; }
.ui-hero-sub { display: flex; flex-wrap: wrap; align-items: center; gap: .25rem .75rem; margin-top: .25rem; color: var(--bs-secondary-color); }
.ui-hero-sub .badge { font-weight: 500; }
.ui-hero-actions { margin-left: auto; display: flex; flex-wrap: wrap; align-items: center; gap: .35rem; }
.ui-hero-actions:empty { display: none; }
.ui-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(7.5rem, 1fr)); gap: .75rem; margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--bs-border-color-translucent); }
.ui-stat { display: flex; flex-direction: column; padding: .6rem .9rem; border-radius: .5rem; background-color: var(--bs-tertiary-bg); color: inherit; text-decoration: none; }
a.ui-stat:hover, a.ui-stat:focus-visible { background-color: var(--bs-secondary-bg); color: inherit; }
.ui-stat-number { font-size: 1.75rem; font-weight: 600; line-height: 1.1; }
.ui-stat-label { font-size: .8125rem; color: var(--bs-secondary-color); white-space: nowrap; }
.ui-tabs { flex-wrap: nowrap; overflow-x: auto; overflow-y: hidden; scrollbar-width: none; }
.ui-tabs::-webkit-scrollbar { display: none; }
.ui-tabs .nav-link { white-space: nowrap; }
.ui-facts { list-style: none; margin: 0; padding: 0; }
.ui-facts > li { display: flex; align-items: baseline; gap: .6rem; padding: .5rem 0; border-bottom: 1px solid var(--bs-border-color-translucent); }
.ui-facts > li:last-child { border-bottom: 0; padding-bottom: 0; }
.ui-facts > li > i { flex: 0 0 1.25rem; text-align: center; color: var(--bs-primary); font-size: 1.1rem; }
.ui-facts .ui-fact-label { flex: 0 0 8.5rem; color: var(--bs-secondary-color); }
.ui-facts .ui-fact-value { flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere; }
.ui-prose { overflow-wrap: anywhere; }
.ui-help-text { margin-left: .15rem; font-size: .875rem; vertical-align: middle; color: var(--bs-secondary-color); }
.ui-division-pills { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: .25rem; }
.ui-division-pill { display: inline-flex; align-items: center; padding: .1rem .65rem; border-radius: 50rem; font-size: .8125rem; color: var(--bs-primary-text-emphasis); background-color: var(--bs-primary-bg-subtle); }
.ui-season-card .ui-season-title a { color: inherit; text-decoration: none; }
.ui-season-card .ui-season-title a:focus-visible { outline: 2px solid var(--bs-primary); outline-offset: 2px; }
.ui-season-card:not(.sort-order-dragging):hover, .ui-season-card:focus-within { box-shadow: 0 .5rem 1rem rgba(var(--bs-emphasis-color-rgb), .15); }
.ui-season-card .ui-season-actions, .ui-season-card .ui-season-head > span:first-child { position: relative; z-index: 2; }
.ui-signup-totals { display: grid; grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr)); gap: .5rem .75rem; list-style: none; margin: 0; padding: 0; }
.ui-signup-totals > li { display: flex; align-items: baseline; justify-content: space-between; gap: .75rem; padding: .45rem .75rem; border-radius: .5rem; background-color: var(--bs-tertiary-bg); }
.ui-signup-totals .ui-signup-total-name { min-width: 0; overflow-wrap: anywhere; }
.ui-signup-totals .ui-signup-total-count { font-weight: 600; white-space: nowrap; }
.ui-division-name a.ui-division-link { color: inherit; text-decoration: none; }
.ui-division-name a.ui-division-link:hover, .ui-division-name a.ui-division-link:focus-visible { color: var(--bs-primary); text-decoration: underline; }
/* The heading card already has the sport's icon beside the title, so the menu section's icon that Core_AppMaster writes at the start of a record page's title
   (section 16) would be a second one: hidden here (only .ui-hero-title, so no other page changes). */
.ui-hero-title > i.ui-section-icon { display: none; }
@media (max-width: 575.98px) {
    .ui-hero { padding-left: calc(var(--bs-card-spacer-x, 1.25rem) + .25rem); }
    .ui-hero > .ui-hero-edge { width: .25rem; }
    .ui-hero-icon { width: 3.25rem; height: 3.25rem; font-size: 1.7rem; }
    .ui-hero-text { flex-basis: 8rem; }
    .ui-hero-title { font-size: 1.4rem; }
    .ui-hero-actions { margin-left: 0; width: 100%; }
    .ui-stats { grid-template-columns: repeat(auto-fit, minmax(5.25rem, 1fr)); gap: .5rem; margin-top: .75rem; padding-top: .75rem; }
    .ui-stat { padding: .5rem .45rem; }
    .ui-stat-number { font-size: 1.5rem; }
    .ui-stat-label { white-space: normal; font-size: .75rem; overflow-wrap: break-word; hyphens: manual; }
    .ui-season-card .ui-season-actions { width: auto; margin-left: auto; }
    .ui-facts .ui-fact-label { flex-basis: 6.5rem; }
}

/* 20. Officials, discipline, board votes and clubs in the league look (APP-1572; "The league look" in documentation/Design/websites/webroot/README.md). Built on section 19.
   - Tiles (.ui-tile-grid holding card ui-panel ui-tile): one card per person, club, motion or report, with a round badge (.ui-tile-avatar, coloured as .ui-program-icon-*),
     the name, a line of small facts, chips (.ui-season-count) and one action at the foot (.ui-tile-foot). The edge takes a status colour (.ui-tile-success, -warning,
     -danger, -primary, -info) and the card lifts on hover; a title link with .stretched-link makes the whole card the link.
   - Fees (.ui-fee-grid): what a division pays for each role in small boxes with the role named above the amount, instead of a wide table of boxes.
   - A vote's tally (.ui-tally): one bar, green for yes, red for no, grey for abstain, with the numbers beside it. */
.ui-tile-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(18rem, 1fr)); gap: 1rem; margin-bottom: 1rem; }
.ui-tile-grid-wide { grid-template-columns: repeat(auto-fill, minmax(24rem, 1fr)); }
.ui-tile-grid > .ui-tile { margin-bottom: 0; }
.ui-tile { position: relative; gap: .6rem; border-left: .25rem solid var(--bs-border-color); transition: transform .15s ease, box-shadow .15s ease; }
.ui-tile:hover, .ui-tile:focus-within { transform: translateY(-.15rem); box-shadow: 0 .5rem 1rem rgba(var(--bs-emphasis-color-rgb), .15); }
@media (prefers-reduced-motion: reduce) { .ui-tile { transition: none; } .ui-tile:hover, .ui-tile:focus-within { transform: none; } }
.ui-tile.ui-tile-static:hover, .ui-tile.ui-tile-static:focus-within { transform: none; box-shadow: var(--bs-card-box-shadow, none); }
.ui-tile-success { border-left-color: var(--bs-success); }
.ui-tile-warning { border-left-color: var(--bs-warning); }
.ui-tile-danger { border-left-color: var(--bs-danger); }
.ui-tile-primary { border-left-color: var(--bs-primary); }
.ui-tile-info { border-left-color: var(--bs-info); }
.ui-tile-head { display: flex; align-items: center; gap: .75rem; min-width: 0; }
.ui-tile-avatar { flex: 0 0 auto; width: 3rem; height: 3rem; margin-bottom: 0; font-size: 1.05rem; font-weight: 600; }
.ui-tile-avatar i { font-size: 1.5rem; }
.ui-tile-avatar.ui-rep-avatar { width: 2.25rem; height: 2.25rem; font-size: .85rem; }
.ui-tile-title { min-width: 0; flex: 1 1 auto; }
.ui-tile-name { margin: 0; font-size: 1.15rem; font-weight: 500; line-height: 1.25; overflow-wrap: anywhere; }
.ui-tile-name a { color: inherit; text-decoration: none; }
.ui-tile-name a:focus-visible { outline: 2px solid var(--bs-primary); outline-offset: 2px; }
.ui-tile-meta { color: var(--bs-secondary-color); font-size: .875rem; overflow-wrap: anywhere; }
.ui-tile-badges { display: flex; flex-wrap: wrap; gap: .35rem; }
.ui-tile-badges .badge { font-weight: 500; }
.ui-tile-chips { display: flex; flex-wrap: wrap; gap: .35rem; }
.ui-tile-text { overflow-wrap: anywhere; }
.ui-tile-foot { margin-top: auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: .35rem; position: relative; z-index: 2; }
.ui-tile-foot .ui-tile-foot-note { margin-right: auto; color: var(--bs-secondary-color); font-size: .875rem; }
.ui-tile .ui-tile-lines { list-style: none; margin: 0; padding: 0; }
.ui-tile .ui-tile-lines > li { display: flex; align-items: baseline; gap: .5rem; padding: .15rem 0; overflow-wrap: anywhere; }
.ui-tile .ui-tile-lines > li > i { flex: 0 0 1.25rem; text-align: center; color: var(--bs-primary); }
.ui-section-head { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-bottom: 1rem; }
.ui-section-head .ui-panel-title { margin-bottom: 0; display: flex; align-items: center; gap: .25rem; }
.ui-section-head-actions { margin-left: auto; display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.ui-fee-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(12.5rem, 1fr)); gap: .75rem; }
.ui-fee { padding: .6rem .75rem; border-radius: .5rem; background-color: var(--bs-tertiary-bg); }
.ui-fee-role { font-weight: 600; }
.ui-fee-level { margin-bottom: .35rem; font-size: .8125rem; color: var(--bs-secondary-color); }
.ui-fee .input-group + .input-group { margin-top: .35rem; }
.ui-fee-playoff { max-width: 26rem; }
.ui-days-field { max-width: 14rem; flex-wrap: nowrap; }
.ui-tally { display: flex; height: .75rem; overflow: hidden; border-radius: 50rem; background-color: var(--bs-secondary-bg); }
.ui-tally > span { display: block; height: 100%; }
.ui-tally-yes { background-color: var(--bs-success); }
.ui-tally-no { background-color: var(--bs-danger); }
.ui-tally-abstain { background-color: var(--bs-secondary-color); }
.ui-wording { white-space: pre-wrap; overflow-wrap: anywhere; }
.ui-quote { margin: 0; padding: .5rem .75rem; border-left: .25rem solid var(--bs-border-color); background-color: var(--bs-tertiary-bg); border-radius: 0 .5rem .5rem 0; overflow-wrap: anywhere; }
.ui-log-table > :not(caption) > * > * { padding: .6rem .6rem; }
.ui-log-table .ui-log-what { min-width: 14rem; overflow-wrap: anywhere; }
.ui-money-table > :not(caption) > * > * { padding: .45rem .6rem; }
@media (max-width: 575.98px) {
    .ui-tile-grid, .ui-tile-grid-wide { grid-template-columns: 1fr; }
    .ui-section-head-actions { margin-left: 0; width: 100%; }
    .ui-costs-season { flex: 1 1 100%; min-width: 0; }
    .ui-costs-season .form-select { flex: 1 1 auto; min-width: 0; width: 100% !important; }
}

/* 21. Games and the schedule in the league look (APP-1571; the pattern is section 19). Schedule, Schedule Builder, Game, Reschedule Requests, Practices and
   Bookings and Tournaments use the heading card and top tabs of section 19 and add only what a game needs:
   - .ui-sport-dot: a small round sport icon (the .ui-program-icon-<colour> classes colour it) at the start of a game, a booking or a bracket.
   - .table.ui-games: the schedule as a roomy table (a game's when, its two teams, field, result and one Open button); below 768 px each row is a small card.
   - .ui-edge-card: a card with a coloured edge and a lift on hover, one per request, booking day or bracket (.ui-edge-warning, -success, -secondary, -primary, -danger).
   - .ui-filters: the search above a list, one line of the few boxes people use, the rest behind "More filters".
   - .ui-booking-row: one practice or booking inside its day's card. .ui-score: a result in large figures. .ui-chip: a small count or note on a game. */
.ui-sport-dot {
    display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto;
    width: 2.25rem; height: 2.25rem; border-radius: 50%; font-size: 1.2rem; line-height: 1;
    color: var(--bs-secondary-color); background-color: var(--bs-secondary-bg);
}
.ui-filters .form-label { font-size: .8125rem; color: var(--bs-secondary-color); margin-bottom: .25rem; }
.ui-filters-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.ui-filters-more { margin-top: .75rem; }
.ui-games-count { color: var(--bs-secondary-color); font-size: .875rem; }
.table.ui-games { margin-bottom: 0; }
.table.ui-games > thead > tr > th { padding: .5rem .75rem; font-size: .8125rem; font-weight: 600; white-space: nowrap; color: var(--bs-secondary-color); }
.table.ui-games > tbody > tr > td { padding: .75rem; vertical-align: middle; }
.table.ui-games > tbody > tr.ui-game-removed > td { opacity: .7; }
.ui-game-when { display: flex; align-items: center; gap: .65rem; }
.ui-game-day { font-weight: 600; white-space: nowrap; }
.ui-game-time { font-size: .8125rem; color: var(--bs-secondary-color); white-space: nowrap; }
.ui-game-teams { font-weight: 500; overflow-wrap: anywhere; }
.ui-game-vs { margin: 0 .3rem; font-size: .8125rem; font-weight: 400; color: var(--bs-secondary-color); }
.ui-game-sub { font-size: .8125rem; color: var(--bs-secondary-color); overflow-wrap: anywhere; }
.ui-game-problem { font-size: .8125rem; color: var(--bs-danger-text-emphasis); }
.ui-score { font-size: 1.35rem; font-weight: 700; line-height: 1.1; white-space: nowrap; }
.ui-chip { display: inline-flex; align-items: center; gap: .25rem; padding: .1rem .55rem; border-radius: 50rem; font-size: .75rem; font-weight: 500; white-space: nowrap; }
.ui-chip-need { color: var(--bs-warning-text-emphasis); background-color: var(--bs-warning-bg-subtle); }
.ui-chip-ok { color: var(--bs-success-text-emphasis); background-color: var(--bs-success-bg-subtle); }
.ui-chip-plain { color: var(--bs-body-color); background-color: var(--bs-secondary-bg); }
.ui-chips { display: flex; flex-wrap: wrap; gap: .3rem; margin-top: .3rem; }
.ui-games-open { text-align: right; white-space: nowrap; }
@media (max-width: 767.98px) {
    .table.ui-games, .table.ui-games > tbody { display: block; width: 100%; }
    .table.ui-games > thead { display: none; }
    .table.ui-games > tbody > tr { display: flex; flex-direction: column; gap: .35rem; padding: .85rem .25rem; border-bottom: var(--bs-border-width) solid var(--bs-border-color); background-color: var(--bs-table-bg); }
    .table.ui-games > tbody > tr:last-child { border-bottom: 0; }
    .table.ui-games > tbody > tr > td { display: block; padding: 0; border: 0; }
    .table.ui-games > tbody > tr > .ui-games-open { text-align: left; }
}
.ui-card-list { display: flex; flex-direction: column; gap: 1rem; }
.ui-card-list > .card { margin-bottom: 0 !important; }
.ui-edge-card { position: relative; border-left: .25rem solid var(--bs-border-color); gap: .5rem; transition: box-shadow .15s ease; }
.ui-edge-card:hover, .ui-edge-card:focus-within { box-shadow: 0 .5rem 1rem rgba(var(--bs-emphasis-color-rgb), .15); }
.ui-edge-warning { border-left-color: var(--bs-warning); }
.ui-edge-success { border-left-color: var(--bs-success); }
.ui-edge-danger { border-left-color: var(--bs-danger); }
.ui-edge-primary { border-left-color: var(--bs-primary); }
.ui-edge-secondary { border-left-color: var(--bs-secondary-color); }
.ui-edge-head { display: flex; flex-wrap: wrap; align-items: center; gap: .35rem .75rem; }
.ui-edge-title { margin: 0; font-size: 1.15rem; font-weight: 500; line-height: 1.25; overflow-wrap: anywhere; }
.ui-edge-title a { color: inherit; text-decoration: none; }
.ui-edge-title a:hover, .ui-edge-title a:focus-visible { color: var(--bs-primary); text-decoration: underline; }
.ui-edge-body { overflow-wrap: anywhere; }
.ui-edge-meta { font-size: .875rem; color: var(--bs-secondary-color); overflow-wrap: anywhere; }
.ui-edge-answer { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-top: .25rem; padding-top: .75rem; border-top: 1px solid var(--bs-border-color-translucent); }
.ui-edge-answer .form-control { flex: 1 1 14rem; min-width: 0; }
.ui-day-heading { margin: 1.25rem 0 .5rem; font-size: 1rem; font-weight: 600; color: var(--bs-secondary-color); }
.ui-day-heading:first-child { margin-top: 0; }
.ui-booking-row { display: flex; align-items: center; gap: .75rem; padding: .65rem 0; border-bottom: 1px solid var(--bs-border-color-translucent); }
.ui-booking-row:last-child { border-bottom: 0; padding-bottom: 0; }
.ui-booking-row:first-child { padding-top: 0; }
.ui-booking-time { flex: 0 0 8.5rem; font-weight: 600; }
.ui-booking-main { flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere; }
.ui-booking-actions { flex: 0 0 auto; }
@media (max-width: 575.98px) {
    .ui-booking-row { flex-wrap: wrap; row-gap: .15rem; }
    .ui-booking-time { flex: 1 0 100%; }
    .ui-booking-main { flex: 1 1 0; }
}
.ui-scroll-box { max-height: 28rem; overflow-y: auto; }
.ui-pre-line { white-space: pre-line; overflow-wrap: anywhere; }
.ui-col-9 { width: 9rem; }
.ui-note-max { max-width: 16rem; }
.ui-w-7 { width: 7rem; }

/* 22. Volunteers (APP-1573; Leagues > Volunteering, Volunteer Shift, Volunteer Hours, Volunteer Review and Staffing > Volunteers). A shift, an offer to help or a
   person is a card in a list (.ui-vol-list > .card.ui-panel.ui-vol-card), as a season is on Program: a coloured edge, a date tile or an initials circle, the name and a
   line of facts, a friendly badge and one action. A card that needs people has an amber edge, a full or answered one is green, one in the past is plain.
   .ui-fill is how full a shift is (a <progress>, so it needs no inline width). Colours come from Bootstrap's theme variables, so light and dark follow. */
.ui-vol-list { display: flex; flex-direction: column; gap: .75rem; }
.ui-vol-heading { margin: 1.25rem 0 .5rem; font-size: .8125rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--bs-secondary-color); }
.ui-vol-heading:first-child { margin-top: 0; }
.ui-vol-card { position: relative; flex-direction: row !important; flex-wrap: wrap; align-items: center; gap: .75rem 1rem; margin-bottom: 0 !important; border-left: .25rem solid var(--bs-border-color); transition: transform .15s ease, box-shadow .15s ease; }
.ui-vol-card.ui-vol-needs { border-left-color: var(--bs-warning); }
.ui-vol-card.ui-vol-done { border-left-color: var(--bs-success); }
.ui-vol-card.ui-vol-problem { border-left-color: var(--bs-danger); }
.ui-vol-card.ui-vol-past { background-color: var(--bs-tertiary-bg); }
.ui-vol-card.ui-vol-past .ui-vol-main { opacity: .8; }
.ui-vol-card.ui-vol-link:hover, .ui-vol-card.ui-vol-link:focus-within { transform: translateY(-.1rem); box-shadow: 0 .5rem 1rem rgba(var(--bs-emphasis-color-rgb), .15); }
@media (prefers-reduced-motion: reduce) { .ui-vol-card { transition: none; } .ui-vol-card.ui-vol-link:hover, .ui-vol-card.ui-vol-link:focus-within { transform: none; } }
.ui-vol-main { flex: 1 1 14rem; min-width: 0; }
.ui-vol-title { margin: 0; font-size: 1.1rem; font-weight: 600; line-height: 1.25; overflow-wrap: anywhere; }
.ui-vol-title a { color: inherit; text-decoration: none; }
.ui-vol-title a:hover, .ui-vol-title a:focus-visible { color: var(--bs-primary); text-decoration: underline; }
.ui-vol-title a.ui-vol-stretch::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.ui-vol-title a.ui-vol-stretch:focus-visible { outline: 2px solid var(--bs-primary); outline-offset: 2px; }
.ui-vol-meta { display: flex; flex-wrap: wrap; align-items: center; gap: .15rem 1rem; margin-top: .2rem; font-size: .875rem; color: var(--bs-secondary-color); }
.ui-vol-meta > span { display: inline-flex; align-items: center; gap: .3rem; overflow-wrap: anywhere; }
.ui-vol-meta a { color: inherit; position: relative; z-index: 2; }
.ui-vol-side { flex: 0 0 auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: .35rem .75rem; }
.ui-vol-action { position: relative; z-index: 2; flex: 0 0 auto; display: flex; flex-wrap: wrap; align-items: center; gap: .35rem; }
.ui-vol-amount { font-size: 1.35rem; font-weight: 600; line-height: 1.1; white-space: nowrap; }
.ui-vol-amount small { display: block; font-size: .75rem; font-weight: 400; color: var(--bs-secondary-color); text-align: right; }
.ui-vol-quote { flex: 1 0 100%; margin: 0; padding: .5rem .85rem; border-left: .2rem solid var(--bs-border-color); border-radius: 0 .5rem .5rem 0; background-color: var(--bs-tertiary-bg); white-space: pre-line; overflow-wrap: anywhere; font-size: .9rem; }
.ui-vol-note { flex: 1 0 100%; margin: 0; font-size: .85rem; color: var(--bs-secondary-color); white-space: pre-line; overflow-wrap: anywhere; }
.ui-vol-note.ui-vol-note-bad { color: var(--bs-danger-text-emphasis); }
.ui-date-tile { flex: 0 0 auto; display: inline-flex; flex-direction: column; align-items: center; justify-content: center; width: 3.5rem; height: 3.75rem; border-radius: .6rem; line-height: 1; color: var(--bs-primary-text-emphasis); background-color: var(--bs-primary-bg-subtle); }
.ui-date-tile .ui-date-month { font-size: .7rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.ui-date-tile .ui-date-day { font-size: 1.5rem; font-weight: 700; margin-top: .1rem; }
.ui-date-tile.ui-date-past { color: var(--bs-secondary-color); background-color: var(--bs-secondary-bg); }
.ui-date-tile.ui-date-none { font-size: 1.4rem; }
.ui-avatar { flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; width: 3rem; height: 3rem; border-radius: 50%; font-weight: 600; font-size: 1rem; color: var(--bs-success-text-emphasis); background-color: var(--bs-success-bg-subtle); }
progress.ui-fill { display: block; width: 7.5rem; max-width: 100%; height: .45rem; border: 0; border-radius: 50rem; overflow: hidden; background-color: var(--bs-secondary-bg); -webkit-appearance: none; appearance: none; }
progress.ui-fill::-webkit-progress-bar { background-color: var(--bs-secondary-bg); }
progress.ui-fill::-webkit-progress-value { background-color: var(--bs-warning); border-radius: 50rem; }
progress.ui-fill::-moz-progress-bar { background-color: var(--bs-warning); border-radius: 50rem; }
progress.ui-fill.ui-fill-full::-webkit-progress-value { background-color: var(--bs-success); }
progress.ui-fill.ui-fill-full::-moz-progress-bar { background-color: var(--bs-success); }
.ui-fill-label { display: flex; flex-direction: column; gap: .3rem; font-size: .8125rem; color: var(--bs-secondary-color); white-space: nowrap; }
.ui-fill-label strong { color: var(--bs-body-color); font-weight: 600; }
.ui-need-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr)); gap: .75rem; margin-bottom: 1rem; }
.ui-need-tile { display: flex; flex-direction: column; gap: .35rem; padding: .75rem .9rem; border-radius: .5rem; background-color: var(--bs-tertiary-bg); }
.ui-need-tile .ui-need-role { font-weight: 600; overflow-wrap: anywhere; }
.ui-need-tile .ui-need-status { font-size: .8125rem; color: var(--bs-secondary-color); }
.ui-vol-form { max-width: 46rem; }
.ui-vol-form .ui-vol-group { margin: 1.5rem 0 .75rem; padding-top: 1rem; border-top: 1px solid var(--bs-border-color-translucent); font-size: 1rem; font-weight: 600; }
.ui-vol-form .ui-vol-group:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.ui-vol-unit { display: inline-flex; align-items: center; gap: .6rem; }
.ui-decision { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.ui-vol-stats .ui-stat-number { white-space: nowrap; }
@media (max-width: 575.98px) {
    .ui-vol-stats .ui-stat-number { font-size: 1.2rem; }
    .ui-vol-side { justify-content: flex-start; width: 100%; }
    .ui-vol-action { width: 100%; }
    .ui-vol-amount small { text-align: left; }
    .ui-vol-filters { width: 100%; margin-left: 0 !important; }
    .ui-vol-filters .form-select { width: 100% !important; }
}

/* 23. Fundraising in the league look (APP-1574; Fundraising > Donations, Pools, Raffles, A-thons and their record pages). Cards in the Programs look (section 17) whose heart is
   the money raised, read at a glance: a big number (.ui-fund-money) with its label, an optional progress bar toward a goal (.ui-fund-progress), and small chips (the
   season's .ui-season-count). Each kind has its own icon colour (the .ui-program-icon-* of section 17). A raised-of-goal pair is .ui-fund-of; a list page's search is a
   .ui-filterbar (section 9) above the cards. A record page copies Leagues > Program: .ui-hero, .ui-stats and .ui-tabs of section 19. */
.ui-fund-card { gap: .5rem; }
.ui-fund-card.ui-program-card { border-left-color: currentColor; }
.ui-fund-card.ui-fund-pool { color: var(--bs-info); }
.ui-fund-card.ui-fund-raffle { color: #d97706; }
.ui-fund-card.ui-fund-athon { color: var(--bs-success); }
.ui-fund-card.ui-fund-ended, .ui-fund-card.ui-fund-removed { color: var(--bs-border-color); }
.ui-fund-card > * { color: var(--bs-body-color); }
.ui-fund-card .ui-program-icon { margin-bottom: 0; }
.ui-fund-head { display: flex; align-items: center; gap: .75rem; }
.ui-fund-head .ui-program-title { flex: 1 1 auto; min-width: 0; }
.ui-fund-sub { color: var(--bs-secondary-color); font-size: .875rem; overflow-wrap: anywhere; }
.ui-fund-money { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 .5rem; margin-top: auto; padding-top: .5rem; }
.ui-fund-money-number { font-size: 1.75rem; font-weight: 600; line-height: 1.1; }
.ui-fund-money-label { font-size: .875rem; color: var(--bs-secondary-color); }
.ui-fund-of { font-size: .875rem; color: var(--bs-secondary-color); }
.ui-fund-progress { height: .5rem; margin-top: .25rem; background-color: var(--bs-secondary-bg); }
.ui-fund-chips { display: flex; flex-wrap: wrap; gap: .35rem; min-width: 0; }
.ui-fund-chips .ui-season-count { white-space: normal; max-width: 100%; overflow-wrap: anywhere; }
.ui-fund-empty { text-align: center; padding: 2rem 1rem; color: var(--bs-secondary-color); }
.ui-fund-empty > i { display: block; font-size: 2.5rem; margin-bottom: .25rem; }
.ui-fund-tab-head { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-bottom: 1rem; }
.ui-fund-tab-head > h2 { margin: 0; font-size: 1.25rem; font-weight: 600; }
.ui-fund-tab-head > .ui-fund-tab-actions { margin-left: auto; display: flex; flex-wrap: wrap; gap: .35rem; }
.ui-fund-table.table > :not(caption) > * > * { padding-top: .6rem; padding-bottom: .6rem; }
.ui-fund-table.table > thead > tr > th { font-size: .8125rem; font-weight: 600; white-space: nowrap; color: var(--bs-secondary-color); }
.ui-fund-qty { max-width: 4.5rem; }
.ui-fund-result { width: 6rem; }
.ui-fund-goal { margin-top: .75rem; }
.ui-stats.ui-fund-stats-solo { margin-top: 0; padding-top: 0; border-top: 0; margin-bottom: 1rem; }
.ui-fund-stats-solo .ui-stat { background-color: var(--bs-card-bg, var(--bs-body-bg)); border: 1px solid var(--bs-border-color-translucent); border-left: .25rem solid var(--bs-danger); }
.ui-fund-goal .ui-fund-progress { height: .75rem; margin-top: 0; }
.ui-fund-goal .ui-fund-of { margin-top: .25rem; }
.ui-fund-board { overflow-x: auto; }
@media (max-width: 575.98px) {
    .ui-fund-money-number { font-size: 1.5rem; }
    /* Money in a tile must never break across lines ($1,00 / 0.00): two tiles to a row, the number on one line. */
    [id$="divHeroStats"].ui-stats, .ui-stats.ui-fund-stats-solo { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    [id$="divHeroStats"] .ui-stat-number, .ui-fund-stats-solo .ui-stat-number { font-size: 1.35rem; white-space: nowrap; }
    .ui-fund-tab-head > .ui-fund-tab-actions { margin-left: 0; width: 100%; }
}

/* 24. The registration pages in the league look (APP-1569; the pattern is section 19): Signups, Coupon Codes, Surveys, Members, Families, New Accounts and ID Documents.
   - .table.ui-rows: a long list people search or export (Signups, Members, New Accounts) as a roomy table with calm headers; below 768 px each row is a small card.
     .ui-row-name is the person's name, .ui-row-sub a small grey line under it, .ui-rows-main the cell that leads a phone card, .ui-rows-open the row's one button.
   - .ui-people-list: the people of one family (guardians, children, look-alike records) as rows with a round badge, the name and one or two buttons (.ui-person-row,
     .ui-person-main, .ui-person-actions); .ui-person-head is the person's name at the top of their card; .ui-subhead a heading inside a card (Guardians, Invitations Waiting).
   - .ui-edge-marked: a request a notification's link points to. .ui-find-box: a search box that is not the full width of its card. .ui-hero-initials: initials in a heading
     card's round badge. .ui-program-checks: a coupon's program boxes, each box beside its name. .ui-narrow-table: a small table of charges that does not stretch. */
.ui-find-box { max-width: 32rem; }
.ui-narrow-table { max-width: 40rem; }
.ui-hero-icon.ui-hero-initials { font-size: 1.5rem; font-weight: 600; }
.ui-program-checks > li { display: inline-flex; align-items: center; white-space: nowrap; }
.ui-edge-marked { box-shadow: 0 0 0 2px var(--bs-warning); }
.ui-subhead { margin: 1.5rem 0 .75rem; font-size: 1rem; font-weight: 600; }
.ui-person-head + .ui-subhead, .ui-subhead:first-child { margin-top: .5rem; }
.ui-person-head { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; margin-bottom: 1rem; }
.ui-people-list { list-style: none; margin: 0; padding: 0; }
.ui-person-row { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .75rem; padding: .65rem 0; border-bottom: 1px solid var(--bs-border-color-translucent); }
.ui-person-row:last-child { border-bottom: 0; padding-bottom: 0; }
.ui-person-row:first-child { padding-top: 0; }
.ui-person-row .ui-tile-avatar { flex: 0 0 auto; }
.ui-person-main { flex: 1 1 12rem; min-width: 0; overflow-wrap: anywhere; }
.ui-person-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .35rem; margin-left: auto; }
.ui-record-note { margin: 1.25rem 0 0; font-size: .8125rem; color: var(--bs-secondary-color); }
.table.ui-rows { margin-bottom: 0; }
.table.ui-rows > thead > tr > th { padding: .5rem .75rem; font-size: .8125rem; font-weight: 600; white-space: nowrap; color: var(--bs-secondary-color); }
.table.ui-rows > tbody > tr > td { padding: .75rem; vertical-align: middle; }
.table.ui-rows .ui-row-name { font-weight: 500; overflow-wrap: anywhere; }
.table.ui-rows .ui-row-sub { font-size: .8125rem; color: var(--bs-secondary-color); overflow-wrap: anywhere; }
.table.ui-rows .ui-game-when { gap: .65rem; }
.ui-rows-open { text-align: right; white-space: nowrap; }
@media (max-width: 767.98px) {
    .table.ui-rows, .table.ui-rows > tbody { display: block; width: 100%; }
    .table.ui-rows > thead { display: none; }
    .table.ui-rows > tbody > tr { display: flex; flex-direction: column; gap: .35rem; padding: .85rem .25rem; border-bottom: var(--bs-border-width) solid var(--bs-border-color); background-color: var(--bs-table-bg); }
    .table.ui-rows > tbody > tr:last-child { border-bottom: 0; }
    .table.ui-rows > tbody > tr > td { display: block; padding: 0; border: 0; }
    .table.ui-rows > tbody > tr > td:empty { display: none; }
    .table.ui-rows > tbody > tr > .ui-rows-open { text-align: left; }
}
@media (max-width: 575.98px) {
    .ui-hero-icon.ui-hero-initials { font-size: 1.2rem; }
    .ui-person-actions { margin-left: 0; width: 100%; }
}

.ui-stat-number { white-space: nowrap; }
@media (max-width: 767.98px) { .ui-tabs .nav-link { padding-left: .75rem; padding-right: .75rem; } }
/* 25. Teams and rosters in the league look (APP-1570; Leagues > Team, Drafts, Evaluations, All-Stars, Substitutes and Heat Levels). They copy Leagues > Program
   (section 19): a heading card, tabs across the top, cards. Section 20's tiles hold a coach, a draft, a session, a level or a team's all-stars. What is added here:
   - .ui-jersey: a player's number in a round badge, coloured as the team's sport (.ui-program-icon-<colour>), at the start of a roster row.
   - .ui-draft-team: a team's card on a draft's Board, whose players are one line each.
   - .ui-note-min: the room an evaluation's notes column needs. */
.ui-jersey { width: 2.25rem; height: 2.25rem; margin-bottom: 0; font-size: .95rem; font-weight: 700; }
.table.ui-roster > tbody > tr > td:first-child { width: 3rem; }
.table.ui-roster .ui-list-full { white-space: normal; min-width: 12rem; }
.ui-draft-team ol { padding-left: 1.4rem; }
.ui-draft-team li { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ui-note-min { min-width: 20rem; }
@media (max-width: 767.98px) {
    .table.ui-roster > tbody > tr > td:first-child { width: auto; }
}

/* 27. League Overview in the league look (APP-1577; the pattern is section 19): the band's season names are chips, the section headings
   and panels breathe, each figure lifts under the pointer, and on a phone the band's buttons and the waiting list stack. Scoped to .lgo. */
.lgo .ex-hero .ui-season-count { background-color: rgba(255, 255, 255, .18); color: #fff; margin: .25rem .35rem 0 0; white-space: normal; }
.lgo .ex-hero .ex-asof { display: flex; flex-wrap: wrap; align-items: center; }
.lgo .ex-section { margin-top: 1.75rem; scroll-margin-top: 4.5rem; }
.lgo .ex-section-head h2 { font-size: 1.35rem; }
.lgo .ex-section-head .ex-badge { border-radius: 50%; }
.lgo .card.ui-panel { border-radius: 1rem; padding: 1.25rem; }
.lgo .ex-stat { border-radius: 1rem; transition: transform .12s ease; }
.lgo a.ex-stat:hover { transform: translateY(-1px); }
.lgo .lgo-waiting .list-group-item { border-radius: .75rem; padding: .75rem .5rem; }

/* Menu tree (APP-1648): the project records nested under Projects in the portal menu, with guide lines and a connector to each link */
#sidebar-menu .sub-menu .menu-tree { position: relative; display: flex; flex-direction: column; }
#sidebar-menu .sub-menu .menu-tree:not(:has(> a)) { display: none; }
/* The theme draws every sub-menu link's dot with .nav-link::after, so the links' pseudo-elements are left alone: the children only move their dot and text right,
   and the guide line (from under Projects' dot to the last child's dot) is the wrapper's own ::before, with a short connector drawn as each link's background */
#sidebar-menu .sub-menu .menu-tree::before { content: ""; position: absolute; left: 24px; top: -8px; bottom: 20px; width: 0; border-left: 1px solid var(--bs-navlink-dot-color); opacity: .6; }
#sidebar-menu .sub-menu .menu-tree > .nav-link { padding-left: 58px; white-space: nowrap; background: linear-gradient(var(--bs-navlink-dot-color), var(--bs-navlink-dot-color)) 24px 50% / 9px 1px no-repeat; }
#sidebar-menu .sub-menu .menu-tree > .nav-link::after { left: 36px; }

/* Menu group titles (APP-1411): the headings of Administration's System Configuration, Feature Configuration and Reporting groups, a small quiet label over its links */
#sidebar-menu .sub-menu .menu-group-title { padding: 10px 12px 2px; font-size: .68rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--bs-secondary-color); opacity: .85; pointer-events: none; }

/* Triage Center sits close under the logo strip (APP-1651): its block's top margin (mt-4, 24px) is 8px here, so the gap to the logo is the strip's
   own 6px plus this, in the open and collapsed sidebar alike. The strip is a fixed height, so the link can't reach the logo either way */
#sidebar-menu > .nav-item.mt-4:first-child { margin-top: .5rem !important; }
@media (max-width: 575.98px) {
    .lgo .ex-hero-top > .d-flex { width: 100%; }
    .lgo .ex-hero-top > .d-flex .btn { flex: 1 1 100%; }
    .lgo .ex-chart { min-height: 220px; }
    .lgo .card.ui-panel { padding: 1rem; }
}

/* 26. Payments and sponsors in the league look (APP-1575; Leagues > Payments, Credits, Invoices, Revenue Report, Sponsorship Levels and Sponsor Report; "The league look"
   in documentation/Design/websites/webroot/README.md). A league treasurer is a volunteer, so the money is the first thing on the page, read at a glance:
   - Money tiles (.ui-stats.ui-money-stats above a list, or .ui-money-hero in a heading card): a big number (.ui-stat-number) with its label, and a coloured edge by what
     the money means: .ui-stat-good (in, paid), .ui-stat-owe (owed, to give back), .ui-stat-warn, .ui-stat-info. Core_LeagueMoney.Tile writes one.
   - A person or invoice card (.ui-pay-person: a round badge, the name, a line of words and the buttons) over its money tiles.
   - A calm table for a list that is searched or exported (.ui-money-table): roomy rows, quiet headers, money right-aligned (.ui-amount), friendly badges in place of columns.
   - A credit card per person (.ui-tile of section 20 with .ui-credit-amount). */
.ui-stat-note { font-size: .75rem; color: var(--bs-secondary-color); }
.ui-stats .ui-stat.ui-stat-good { border-left: .25rem solid var(--bs-success); }
.ui-stats .ui-stat.ui-stat-owe { border-left: .25rem solid var(--bs-danger); }
.ui-stats .ui-stat.ui-stat-warn { border-left: .25rem solid var(--bs-warning); }
.ui-stats .ui-stat.ui-stat-info { border-left: .25rem solid var(--bs-info); }
.ui-stat-good .ui-stat-number { color: var(--bs-success-text-emphasis); }
.ui-stat-owe .ui-stat-number { color: var(--bs-danger-text-emphasis); }
.ui-stats.ui-money-stats { margin-top: 0; padding-top: 0; border-top: 0; margin-bottom: 1rem; }
.ui-money-stats .ui-stat { background-color: var(--bs-card-bg, var(--bs-body-bg)); border: 1px solid var(--bs-border-color-translucent); border-left: .25rem solid var(--bs-border-color); }
.ui-money-stats .ui-stat-label { white-space: normal; }
.ui-pay-person { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1rem; }
.ui-pay-person .ui-tile-avatar { width: 3.5rem; height: 3.5rem; font-size: 1.2rem; }
.ui-pay-person-text { flex: 1 1 14rem; min-width: 0; }
.ui-pay-person-name { margin: 0; font-size: 1.35rem; font-weight: 600; line-height: 1.2; overflow-wrap: anywhere; }
.ui-pay-person-sub { margin-top: .15rem; color: var(--bs-secondary-color); overflow-wrap: anywhere; }
.ui-pay-person-sub .badge { font-weight: 500; }
.ui-pay-person-actions { margin-left: auto; display: flex; flex-wrap: wrap; align-items: center; gap: .35rem; }
.ui-pay-person + .ui-stats { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--bs-border-color-translucent); }
.ui-money-table.table > :not(caption) > * > * { padding-top: .6rem; padding-bottom: .6rem; }
.ui-money-table.table > thead > tr > th { font-size: .8125rem; font-weight: 600; white-space: nowrap; color: var(--bs-secondary-color); }
.ui-money-table .ui-amount, .ui-money-table td.ui-amount { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.ui-money-table .ui-cell-sub { display: block; font-size: .8125rem; color: var(--bs-secondary-color); overflow-wrap: anywhere; }
@media (min-width: 576px) { .ui-money-table .ui-nowrap-sm { white-space: nowrap; } }
/* APP-1877: below 576 px the sort arrows are hidden (as ui-phone-compact does below 768 px); tapping a heading still sorts */
@media (max-width: 575.98px) { .ui-money-table.ui-nosort-xs > thead .dt-column-order { display: none; } }
.ui-money-table .ui-cell-badges { display: flex; flex-wrap: wrap; align-items: center; gap: .25rem; }
.ui-money-table .badge { font-weight: 500; }
.ui-credit-amount { font-size: 1.75rem; font-weight: 600; line-height: 1.1; }
.ui-credit-amount.ui-credit-none { color: var(--bs-secondary-color); }
.ui-money-note { font-size: .875rem; color: var(--bs-secondary-color); }
.ui-money-empty { text-align: center; padding: 2rem 1rem; color: var(--bs-secondary-color); }
.ui-money-empty > i { display: block; font-size: 2.5rem; margin-bottom: .25rem; }
.ui-filterbar .input-group { width: auto; flex: 0 1 auto; }
.ui-filterbar .input-group > .form-control { max-width: 10.5rem; }
.ui-filterbar .ui-filterbar-end { margin-left: auto; display: flex; flex-wrap: wrap; align-items: center; gap: .35rem; }
@media (max-width: 575.98px) {
    .ui-stats.ui-money-stats, .ui-stats.ui-money-hero { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .ui-money-stats .ui-stat-number, .ui-money-hero .ui-stat-number { font-size: 1.35rem; white-space: nowrap; }
    .ui-money-table.table > :not(caption) > * > * { padding-left: .35rem; padding-right: .35rem; }
    .ui-pay-person-actions { margin-left: 0; width: 100%; }
    .ui-pay-person .ui-tile-avatar { width: 3rem; height: 3rem; font-size: 1.05rem; }
    .ui-filterbar .input-group { width: 100%; max-width: none; flex: 1 1 100%; flex-wrap: nowrap; }
    .ui-filterbar .input-group > .form-control, .ui-filterbar .input-group > .form-select { width: 1%; max-width: none; flex: 1 1 auto; min-width: 0; }
    .ui-filterbar .ui-filterbar-end { margin-left: 0; width: 100%; }
}

/* 28. Albums and the site reports in the league look (APP-1576; the pattern is section 19): Albums, Album, Visitors and Traffic Report.
   - .ui-album-grid: the albums (and an album's photos waiting for approval) as cards in a grid; .ui-album-card is one, with a cover photo (.ui-album-cover, or
     .ui-album-cover-empty when it has none), a body (.ui-album-body), the title (.ui-album-title, a stretched link) and who it is for (.ui-album-for). The edge shows
     where it stands: .ui-album-waiting (photos wait), .ui-album-down (taken down).
   - .ui-album-hero-cover: the cover photo as the round picture of an album's heading card. .ui-album-form: a form that does not stretch across the card.
     .ui-album-caption-cell: the box a photo's caption is typed in. .ui-chart-days and .ui-chart-pages: the height of the Traffic Report's two charts. */
.ui-album-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: 1rem; margin-bottom: 1rem; }
.card.ui-panel.ui-album-card { position: relative; padding: 0; margin-bottom: 0 !important; overflow: hidden; border-left: .25rem solid var(--bs-border-color); transition: transform .15s ease, box-shadow .15s ease; }
.ui-album-card:hover, .ui-album-card:focus-within { transform: translateY(-.15rem); box-shadow: 0 .5rem 1rem rgba(var(--bs-emphasis-color-rgb), .15); }
@media (prefers-reduced-motion: reduce) { .ui-album-card { transition: none; } .ui-album-card:hover, .ui-album-card:focus-within { transform: none; } }
.ui-album-card.ui-album-waiting { border-left-color: var(--bs-warning); }
.ui-album-card.ui-album-down { border-left-color: var(--bs-secondary); background-color: var(--bs-tertiary-bg); }
.ui-album-card.ui-album-down .ui-album-cover { opacity: .6; }
.ui-album-cover { display: block; width: 100%; height: 11rem; object-fit: cover; }
.ui-album-cover-empty { display: flex; align-items: center; justify-content: center; font-size: 3rem; color: var(--bs-secondary-color); background-color: var(--bs-secondary-bg); }
.ui-album-body { display: flex; flex-direction: column; gap: .3rem; padding: .85rem 1rem 1rem; }
.ui-album-title { margin: 0; font-size: 1.05rem; font-weight: 600; overflow-wrap: anywhere; }
.ui-album-title a { color: inherit; text-decoration: none; }
.ui-album-title a:focus-visible { outline: 2px solid var(--bs-primary); outline-offset: 2px; }
.ui-album-for { font-size: .875rem; color: var(--bs-secondary-color); overflow-wrap: anywhere; }
.ui-album-body .ui-chips { margin-top: .15rem; align-items: center; }
.ui-album-hero-cover { object-fit: cover; border-radius: 50%; }
.ui-album-form { max-width: 40rem; }
.ui-album-caption-cell { min-width: 16rem; }
.ui-chart-days { height: 280px; }
.ui-chart-pages { height: 320px; }
@media (max-width: 575.98px) { .ui-album-grid { grid-template-columns: 1fr; } }

/* 29. Small shared pieces that pages used to write inline or in a <style> block of their own (APP-1565, the look-and-feel notes of the part 4 code review).
   A policy's words with their links in the theme's link colour (they followed a fixed blue that dark mode did not change), the signature pad
   of a form's Signature question, a division's icon choices, and the widths, wrapping and line breaks that pages set with style="". */
/* A policy in a bordered box (My Agreements, Register) scrolls inside 24rem; a policy page (Privacy, Terms, Refund Policy) shows all its words. */
.policy-text.border { max-height: 24rem; overflow-y: auto; }
.policy-text a:not(.btn) { color: var(--bs-link-color); }
.policy-text a:not(.btn):hover { color: var(--bs-link-hover-color); }
[data-bs-theme="dark"] .policy-text a:not(.btn),
[data-bs-theme="dark"] .policy-text a:not(.btn):hover { color: var(--bs-primary-text-emphasis); }
.signature-box { display: block; width: 100%; max-width: 600px; aspect-ratio: 600 / 160; border: 1px solid var(--bs-border-color); border-radius: .375rem; background: var(--bs-body-bg); color: var(--bs-body-color); }
.signature-box.signature-pad { touch-action: none; cursor: crosshair; }
.signature-box path { fill: none; stroke: currentColor; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.division-icon-choice { min-width: 76px; white-space: nowrap; }
.division-icon-none { width: 56px; height: calc(56px + 1.5em); }
[data-bs-theme="dark"] .division-icon-choice img { background: #e9ecef; border-radius: .375rem; }
.btn-check:checked + .division-icon-choice img { background: #fff; border-radius: .375rem; }
.ui-pre-line { white-space: pre-line; }
.ui-pre-wrap { white-space: pre-wrap; }
.ui-anywhere { overflow-wrap: anywhere; }
.ui-minw-0 { min-width: 0; }
.ui-maxw-16 { max-width: 16rem; }
.ui-maxw-24 { max-width: 24rem; }
.ui-maxw-28 { max-width: 28rem; }
.ui-maxw-36 { max-width: 36rem; }
.ui-maxw-40 { max-width: 40rem; }
.ui-maxw-44 { max-width: 44rem; }
.ui-maxw-46 { max-width: 46rem; }
.ui-maxw-48 { max-width: 48rem; }
.ui-maxw-52 { max-width: 52rem; }
.ui-maxw-60 { max-width: 60rem; }
.ui-col-check { width: 2.5rem; }
.ui-photo-sq { aspect-ratio: 1 / 1; object-fit: cover; }
.ui-fs-inherit { font-size: inherit; }
.ui-message-frame { width: 100%; height: 320px; border: 1px solid var(--bs-border-color); background-color: #ededed; }
.ui-w-9 { width: 9rem; }
.ui-w-3-5 { width: 3.5rem; }
.ui-w-5-5 { width: 5.5rem; }
.ui-minw-15 { min-width: 15rem; }
.ui-minw-5 { min-width: 5rem; }
.ui-minw-4-5 { min-width: 4.5rem; }

/* 30. The project role grid (APP-1402; Administration > Security Roles > Project Roles, and the read-only copy in the modal of Project > Contacts):
   project roles down the side, permissions across, a switch (or, read-only, a tick or a dash) in each cell. The role column stays put while a phone
   scrolls the permissions sideways. Colours come from the theme's variables, so it follows light and dark mode. */
.prg-table { margin-bottom: 0; }
.prg-table th, .prg-table td { vertical-align: middle; }
.prg-table thead th { min-width: 7.5rem; text-align: center; font-size: .85rem; font-weight: 600; background-color: var(--bs-leftsidebar, var(--bs-body-bg)); }
.prg-table thead th:first-child, .prg-table tbody th { position: sticky; left: 0; z-index: 1; min-width: 8.5rem; text-align: left; background-color: var(--bs-leftsidebar, var(--bs-body-bg)); }
.prg-table tbody th { font-weight: 600; }
.prg-table thead th .ui-help { width: 1.5rem; height: 1.5rem; font-size: 1rem; vertical-align: middle; }
.prg-table .form-check { display: flex; justify-content: center; margin: 0; padding-left: 0; min-height: 0; }
.prg-table .form-check-input { float: none; margin: 0; }
.prg-table .prg-yes { color: var(--bs-success-text-emphasis); font-size: 1.25rem; }
.prg-table .prg-no { color: var(--bs-secondary-color); }
.prg-staff { display: block; font-size: .75rem; font-weight: 400; color: var(--bs-secondary-color); }
/* Phone width (APP-1860): the sticky Role column is narrow and its names wrap, so it leaves room to see the switches beside it */
@media (max-width: 575.98px) {
    .prg-table thead th { min-width: 5.5rem; padding: .35rem .3rem; font-size: .8rem; }
    .prg-table thead th:first-child, .prg-table tbody th { width: 5.5rem; min-width: 5.5rem; max-width: 5.5rem; padding: .35rem .3rem; font-size: .8rem; overflow-wrap: anywhere; hyphens: auto; }
    .prg-table tbody td { padding: .35rem .3rem; }
}

/* 31. Code-built pieces that wrote inline colours and sizes (APP-1497; the look-and-feel notes of the APP-969 and APP-962 reviews), now in the theme's
   colours so light and dark both follow: the server letter in the portal's top bar (Core_AppMaster, one class for Development, Testing and Production),
   the dot on the avatar saying Active or Away, a game's availability answers (Core_TeamAvailability: the dot, the player's circle and the answer buttons),
   and the widths of the call-up box (Core_CallUpBox). */
.ui-server-indicator { font-size: 22px !important; font-weight: 700; line-height: 1; border: 1px solid; }
/* !important: the top bar's own .avatar rules (app.min.css, app-frame.css) are more specific, and the letter's colour is what tells the servers apart */
.ui-server-indicator-development { background-color: var(--bs-info-bg-subtle) !important; border-color: var(--bs-info-bg-subtle) !important; color: var(--bs-info-text-emphasis) !important; }
.ui-server-indicator-testing { background-color: var(--bs-warning-bg-subtle) !important; border-color: var(--bs-warning-bg-subtle) !important; color: var(--bs-warning-text-emphasis) !important; }
.ui-server-indicator-production { background-color: var(--bs-danger-bg-subtle) !important; border-color: var(--bs-danger-bg-subtle) !important; color: var(--bs-danger-text-emphasis) !important; }
.ui-activity-dot { width: 12px; height: 12px; }
.ui-activity-active { background-color: var(--bs-success); }
.ui-activity-away { background-color: var(--bs-warning); }
.ui-avail-playing { background-color: var(--bs-success); }
.ui-avail-not-playing { background-color: var(--bs-danger); }
.ui-avail-no-response { background-color: var(--bs-orange, #fd7e14); }
.ui-avail-dot { display: inline-block; width: 1rem; height: 1rem; position: relative; top: -.12rem; }
.ui-avail-avatar { width: 2.25rem; height: 2.25rem; font-size: .75rem; line-height: 1; }
.ui-avail-avatar img { object-fit: cover; }
.ui-avail-btn { padding: .25rem .8rem; font-size: .75rem; }
.ui-maxw-20 { max-width: 20rem; }
.ui-maxw-32 { max-width: 32rem; }
.ui-cover-thumb { height: 40px; width: 56px; object-fit: cover; }
/* A form's error alert drawn with a quiet grey border (it was an inline border: 1px solid #e4e5e7, which stayed light in dark mode) */
.alert.ui-alert-plain { border: 1px solid var(--bs-border-color); }
.ui-w-4 { width: 4rem; }
/* Quiet hours week grid (APP-1883, Controls/PushSilence.ascx): one row for each day with its day, its choice (Off, All day, From and Until) and, for the last, the From and Until boxes on that same line under one pair of headings. A phone drops the headings, gives each box its own caption and puts the boxes under the day and its choice. */
.ui-quiet-head, .ui-quiet-row { display: grid; grid-template-columns: 6.5rem 10.5rem minmax(0, 9.5rem) minmax(0, 9.5rem); column-gap: .5rem; align-items: center; }
.ui-quiet-head { padding-bottom: .25rem; border-bottom: var(--bs-border-width, 1px) solid var(--bs-border-color); }
.ui-quiet-head span:nth-child(3) { grid-column: 3; }
.ui-quiet-head span:nth-child(4) { grid-column: 4; }
.ui-quiet-row { padding: .5rem 0; }
/* a select and a time box are the same height (a time box otherwise comes out a pixel taller), so the choice and the boxes share one line */
.ui-quiet-row .form-select, .ui-quiet-row .form-control { height: 2.25rem; min-height: 2.25rem; box-sizing: border-box; }
.ui-quiet-times { display: contents; }
.ui-quiet-field { display: block; min-width: 0; }
.ui-quiet-flabel { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
@media (max-width: 767.98px) {
    .ui-quiet-head { display: none; }
    .ui-quiet-row { grid-template-columns: minmax(0, 1fr); row-gap: .5rem; }
    .ui-quiet-times { display: grid; grid-template-columns: minmax(0, 1fr); row-gap: .5rem; }
    .ui-quiet-field { display: grid; grid-template-columns: 3rem minmax(0, 1fr); align-items: center; }
    .ui-quiet-row .form-control[type="time"] { padding-left: .5rem; padding-right: .25rem; }
    .ui-quiet-flabel { position: static; width: auto; height: auto; margin: 0; overflow: visible; clip: auto; white-space: normal; }
}

/* 32. The page's help and actions at the right of the portal's title row (div.ui-title-actions, Controls/TitleActions.ascx, APP-1907; in place of
   the breadcrumb and the page's own action panel): the help icon, then the page's button, or one drop-down when it has several actions, built as
   Close on AI Orchestration's work item. The block keeps its size and stays at the right; the title beside it gives way and wraps (a long word
   too), so at 320 px the help and the action are still on the title's row. The h1 rule is on every portal page's title, converted or not (a
   title with no actions beside it fills the row and wraps as before; only a word too long for a phone now breaks). */
.ui-title-actions {
    display: flex;
    align-items: center;
    gap: .5rem;
    flex-shrink: 0;
    margin-left: auto;
}
.page-title h1 {
    min-width: 0;
    overflow-wrap: break-word;
    flex-wrap: wrap;   /* a feature's gear after the title drops below it when the title and the block at the right leave it no room (Courses at 320 px, APP-1922) */
}
/* On a phone, when the title wraps to two or three lines (the section icon above it, a gear below it), the help and the action stay at the top
   of the row, beside the icon, and never lie against the title's second line (Companies at 320 px, APP-1922). Centred, as before, on a one-line title. */
@media (max-width: 575.98px) {
    .page-title .ui-title-actions { align-self: flex-start; }
    /* A title that leaves the help and the action no room (Consumables beside "Add Consumable", Expense Reports at 320 px) keeps its words whole and
       the block drops to its own line at the right, instead of the title shrinking to a few letters (APP-1979); a single word wider than the whole
       row still breaks inside the word ("anywhere", unlike break-word, also lowers the word's minimum width), so nothing scrolls sideways */
    .page-title .d-flex:has(> .ui-title-actions) { flex-wrap: wrap; row-gap: .5rem !important; }
    .page-title h1 { overflow-wrap: anywhere; }
}
/* App5 draws the title on the tenant's accent band, which fades into the menu colour towards the right, where the help icon sits: the icon
   keeps its own blue on the page's background colour, as the top bar's icons have their own tiles, so it reads on any accent and menu colour */
html[data-template="App5"] .page-title .ui-title-actions .ui-help { color: var(--bs-primary); background-color: var(--bs-body-bg); }
html[data-template="App5"] .page-title .ui-title-actions .ui-help:hover,
html[data-template="App5"] .page-title .ui-title-actions .ui-help:focus-visible { background-color: var(--bs-primary-bg-subtle); }
@media print { .ui-title-actions { display: none !important; } }
/* 32b. Who is on this page (div.ui-presence, Controls/PagePresence.ascx, APP-2076; the owner's screenshot of Confluence): up to three small round
   photos of the other staff on the same page and record, overlapping, each with a thin ring of the page's own colour, then how many they are, in a
   grey pill. At the right of the title row, left of the help and actions (which then lose their own auto margin, so the two keep together); beside a
   record page's own heading when the page hides the title row. A person with no photo shows their initials on the theme's subtle primary. A photo
   is a link to the person's contact page when the viewer may open it, else a plain circle; each names the person in its tooltip. On a phone only
   the first photo and the count. Hidden (the hidden attribute) while nobody else is on the page. */
/* --ui-presence-ring is the colour the block sits on: the page's own colour in the title row (App3, App6 and App7 paint the page in a colour of
   their own; App5's band keeps the page colour, as its help icon's tile does), and the card's in a heading card where the template names it (APP-2076
   UI review: one rule for every template, so the ring never shows as a halo of another colour). Beside a record page's own heading
   (Contact, Task) the block goes last and to the far right of the heading's row, as in the title row, never between the title and its badges. */
.ui-presence { --ui-presence-ring: var(--bs-body-bg); display: flex; align-items: center; gap: .375rem; flex-shrink: 0; margin-left: auto; order: 1; }
.ui-presence[hidden] { display: none; }
html[data-template="App3"] .ui-presence { --ui-presence-ring: var(--app3-page, var(--bs-body-bg)); }
html[data-template="App6"] .ui-presence { --ui-presence-ring: var(--app6-paper, var(--bs-body-bg)); }
html[data-template="App7"] .ui-presence { --ui-presence-ring: var(--app7-page, var(--bs-body-bg)); }
.page-title .ui-presence { order: 0; }
.page-title .ui-presence:not([hidden]) + .ui-title-actions { margin-left: 0; }
/* In a heading card (.ui-hero, the league look's pages that hide the title row), at the right of its icon and title */
/* (the ring stays the page colour in App1 to App4: the theme's --bs-card-bg reads #fff in dark mode too, while the page colour is within a shade
   of the card's; App5, App6 and App7 paint their cards with a variable of their own) */
.ui-hero-main .ui-presence { align-self: flex-start; }
html[data-template="App5"] .ui-hero-main .ui-presence { --ui-presence-ring: var(--app5-panel, var(--bs-body-bg)); }
html[data-template="App6"] .ui-hero-main .ui-presence { --ui-presence-ring: var(--app6-panel, var(--bs-body-bg)); }
html[data-template="App7"] .ui-hero-main .ui-presence { --ui-presence-ring: var(--app7-panel, var(--bs-body-bg)); }
.ui-presence-faces { display: inline-flex; align-items: center; }
.ui-presence-face {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 0 0 2px var(--ui-presence-ring);
    font-size: .625rem;
    letter-spacing: -.01em;
    font-weight: 600;
    line-height: 1;
    text-decoration: none;
    color: var(--bs-primary-text-emphasis);
    background-color: var(--bs-primary-bg-subtle);
    border: 1px solid var(--bs-primary-border-subtle);   /* so a circle of initials reads on the dark theme's page too */
}
.ui-presence-face:has(img) { border: 0; }
/* Overlapping by a seventh (4px, and the 2px ring), so the next circle never covers the second letter of wide initials (TW, MM; APP-2076 UI review) */
.ui-presence-face + .ui-presence-face { margin-left: -.25rem; }
.ui-presence-face img { display: block; width: 100%; height: 100%; object-fit: cover; }
a.ui-presence-face:hover, a.ui-presence-face:focus-visible { z-index: 1; color: var(--bs-primary-text-emphasis); box-shadow: 0 0 0 2px var(--bs-primary); outline: none; }
.ui-presence-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.5rem;
    height: 1.5rem;
    padding: 0 .4rem;
    border-radius: 999px;
    font-size: .75rem;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    color: var(--bs-secondary-color);
    background-color: var(--bs-secondary-bg);
}
@media (max-width: 575.98px) {
    .ui-presence-face:nth-child(n+2) { display: none; }
    .page-title .ui-presence { align-self: flex-start; }
}
@media print { .ui-presence { display: none !important; } }

/* 33. A second level of tabs: a setting's own tabs under a row of tabs, as a segmented control (class="nav ui-segmented" on the ul or div of
   tab buttons, with data-tab-dd-fit="only"; APP-1896, the owner's choice A of 2026-11-14, from DevGUI's study of three treatments). A rounded
   track holding small buttons, the open one a raised chip, so it reads as switching a view inside the setting, not as a second row of tabs
   (and differs from the first row in every template: App2 to App6 draw nav-tabs as an underline). First used on every second-level row of
   System Configuration; Features Configuration (APP-1897) uses it as it is. The buttons stay Bootstrap tabs (data-bs-toggle="tab", data-sub
   where tab-memory.js keeps them), so the arrow keys and the events are Bootstrap's.
   Too wide for its room, at any width, it becomes tab-dropdown.js's dropdown (data-tab-dd-fit="only": only then, a phone included; a row that
   fits stays a segmented row on a phone, its buttons sharing the width), and that dropdown is the quiet one (tab-dd-quiet, which tab-dropdown.js
   gives a .ui-segmented row's dropdown): a select-like box in the body's colours, not a second primary bar. */
.ui-segmented {
    --ui-seg-track: rgba(var(--bs-emphasis-color-rgb), .06);
    --ui-seg-chip: var(--bs-body-bg);
    display: inline-flex; flex-wrap: nowrap; gap: 2px; max-width: 100%; overflow-x: auto; scrollbar-width: none;
    margin: 0 0 1rem; padding: 3px; list-style: none; background: var(--ui-seg-track);
    border: 1px solid var(--bs-border-color-translucent); border-radius: .625rem;
}
[data-bs-theme="dark"] .ui-segmented { --ui-seg-track: rgba(var(--bs-emphasis-color-rgb), .05); --ui-seg-chip: rgba(var(--bs-emphasis-color-rgb), .16); }
.ui-segmented::-webkit-scrollbar { display: none; }
.ui-segmented > .nav-item { display: flex; }
.ui-segmented .nav-link {
    padding: .3125rem .875rem; font-size: .875rem; font-weight: 500; line-height: 1.25; white-space: nowrap;
    color: var(--bs-secondary-color); background: transparent !important; border: 0 !important; border-radius: .5rem; box-shadow: none !important;
}
.ui-segmented .nav-link:hover { color: var(--bs-emphasis-color); }
.ui-segmented .nav-link.active {
    color: var(--bs-emphasis-color) !important; background: var(--ui-seg-chip) !important; font-weight: 600;
    box-shadow: 0 1px 2px rgba(0, 0, 0, .10), 0 0 0 1px var(--bs-border-color-translucent) !important;
}
.ui-segmented .nav-link:focus-visible { outline: 2px solid var(--bs-primary); outline-offset: 1px; }
@media (max-width: 767.98px) {
    .ui-segmented { display: flex; width: 100%; }
    .ui-segmented > .nav-item { flex: 1 1 auto; }
    .ui-segmented .nav-link { width: 100%; padding-top: .5rem; padding-bottom: .5rem; }
}
.tab-dd.tab-dd-quiet .tab-dd-button {
    --bs-btn-bg: var(--bs-body-bg); --bs-btn-color: var(--bs-body-color); --bs-btn-border-color: var(--bs-border-color);
    --bs-btn-hover-bg: var(--bs-tertiary-bg); --bs-btn-hover-color: var(--bs-emphasis-color); --bs-btn-hover-border-color: var(--bs-border-color);
    --bs-btn-active-bg: var(--bs-tertiary-bg); --bs-btn-active-color: var(--bs-emphasis-color); --bs-btn-active-border-color: var(--bs-primary);
    background-color: var(--bs-body-bg) !important; color: var(--bs-body-color) !important; border-color: var(--bs-border-color) !important;
    min-height: 2.5rem; font-size: .9375rem; box-shadow: none !important;
}
.tab-dd.tab-dd-quiet .tab-dd-button:focus-visible { outline: 2px solid var(--bs-primary); outline-offset: 2px; }
.tab-dd.tab-dd-quiet .tab-dd-prefix { color: var(--bs-secondary-color); opacity: 1; }
.tab-dd.tab-dd-quiet .tab-dd-chevron { color: var(--bs-secondary-color); }
/* Features Configuration's moved setups (APP-1897): what their pages kept in a style block of their own, now shared */
/* Daily Logs > Forms, the trade level form's project roles: one checkbox and its label to an item, in rows that wrap */
.dl-roles { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: .35rem 1.25rem; }
.dl-roles li { white-space: nowrap; }
/* Leagues > Linked Leagues: the terms and notes are sentences, wide enough to read in two or three lines, the table scrolling sideways when it must */
.link-terms-cell { min-width: 22rem; }
.link-note-cell { min-width: 14rem; }
/* On a phone a league's long name, and the line beside it, wrap rather than run past the card's edge */
@media (max-width: 575.98px) { .link-card-name { white-space: normal !important; } }

/* 34. A tab row with the page's help and refresh icons at its right (APP-1938, the owner's page cleanup of 2026-11-14, "Page layout" item 15 in
   documentation/Design/websites/webroot/README.md). A row of tabs (nav-tabs) or of a setting's own tabs (.ui-segmented) is wrapped in
   <div class="ui-tabrow"><div class="ui-tabrow-main"> the tabs </div><div class="ui-tabrow-tools"></div></div> and followed by its .tab-content. A
   control puts the help icon of a tab in <div class="ui-tools" data-tools> inside the tab's pane (before a row of its own, data-tools="next",
   when the help belongs to the whole tab and not to one of the row's tabs); Assets/js/tab-tools.js moves the icons into the row's tools, shown
   only while their pane is open, and Assets/js/table-refresh.js puts a list's Refresh icon there too. The tabs and the dropdown tab-dropdown.js
   makes of them keep the room the icons leave. ui-tabrow-line draws the underline of a row of nav-tabs across the icons' room too. */
.ui-tabrow { display: flex; align-items: stretch; gap: .5rem; margin-bottom: 1rem; }
.ui-tabrow-main { flex: 1 1 auto; min-width: 0; }
.ui-tabrow-main > .ui-segmented, .ui-tabrow-main > .nav-tabs, .ui-tabrow-main > .tab-dd { margin-bottom: 0; }
.ui-tabrow-tools { flex: 0 0 auto; display: flex; align-items: center; align-self: flex-start; gap: .125rem; min-height: 2.375rem; }
.ui-tabrow-line:not(:has(.tab-dd-fit-on)) > .ui-tabrow-tools { align-self: stretch; min-height: 0; }
.ui-tabrow-tools:empty, .ui-tabrow-tools:not(:has(> :not([hidden]))) { display: none; }
.ui-tabrow:not(:has(> .ui-tabrow-main > *)) { display: none; }
.ui-tabrow-tools [hidden] { display: none !important; }
/* A table that must fit a phone without a sideways scroll (class ui-compact-xs): tighter cells below 576px (the Logins grid) */
@media (max-width: 575.98px) { .table.ui-compact-xs > :not(caption) > * > * { padding: .4rem .35rem; } }
.ui-tools[data-tools]:not([data-placed]) { display: none; }
@media (min-width: 768px) {
    .ui-tabrow-line:not(:has(.tab-dd-src:not(.tab-dd-empty), .tab-dd-fit-on)) > .ui-tabrow-tools { background: linear-gradient(var(--bs-nav-tabs-border-color, var(--bs-border-color)), var(--bs-nav-tabs-border-color, var(--bs-border-color))) no-repeat 1rem 100% / calc(100% - 1rem) 1px; }   /* from where the tabs' own line ends, so the two never overlap */
    /* The top row of a page's tabs is long: its icons overlap the empty 1.5rem of the last tab's right padding (the glyph has room of its own
       in the button), so the icons cost the tabs about 1.4rem and not 2.9rem, and a row that fit before stays tabs; the underline has no gap */
    .ui-tabrow-line:not(:has(.tab-dd-fit-on)) > .ui-tabrow-tools { margin-left: -1.5rem; position: relative; z-index: 1; }
}

/* 35. System Configuration's logo pictures and sample emails (APP-1948, the owner's request). A picture of Logos is a button that opens the modal that uploads it
   (button.ui-brand-pic holding the img, with the upload icon that shows on hover and keyboard focus): the picture on its own light or dark ground (bg-white or
   bg-dark on the button), a blue ring when it is hovered or focused. A sample email in Email Templates (iframe.ui-email-preview) is as tall as its email: the
   page's script sets the height, so the card never has a long empty box under a short email or cuts a long one off; its minimum is only for before it has loaded. */
.ui-brand-pic { position: relative; display: flex; align-items: center; justify-content: center; width: 100%; height: 96px; padding: .5rem; border: 1px solid var(--bs-border-color); border-radius: var(--bs-border-radius); cursor: pointer; }
.ui-brand-pic img { max-height: 80px; max-width: 100%; width: auto; height: auto; }
.ui-brand-light { background-color: #fff; }   /* the picture on the ground it is made for, in both themes (bg-white and bg-dark turn over in dark mode) */
.ui-brand-dark { background-color: #1c2331; }
.ui-brand-pic:hover, .ui-brand-pic:focus-visible { border-color: var(--bs-primary); box-shadow: 0 0 0 .2rem rgba(var(--bs-primary-rgb), .25); outline: 0; }
.ui-brand-pic-icon { position: absolute; right: .25rem; bottom: .25rem; display: none; align-items: center; justify-content: center; width: 1.5rem; height: 1.5rem; border-radius: 50%; background: var(--bs-primary); color: #fff; font-size: .95rem; }
.ui-brand-pic:hover .ui-brand-pic-icon, .ui-brand-pic:focus-visible .ui-brand-pic-icon { display: flex; }
@media (hover: none) { .ui-brand-pic-icon { display: flex; } }   /* a touch screen has no hover: the upload icon always shows, so a phone sees that the picture is a button */
.ui-email-preview { display: block; min-height: 12rem; flex: 1 1 auto; pointer-events: none; }   /* the card is a column: when a taller card beside it stretches it, the sample takes the extra, not a gap under the description (the card-body's own flex-grow is switched off in the markup) */

/* 36. System Configuration's second pass (APP-1949 part A, the owner's request of 2026-11-15). A panel's facts (dl.ui-facts holding div > dt.ui-fact-label +
   dd.ui-fact-value): a small grey name over its value, in as many columns as fit (Plan & Usage > Subscription's plan and billing panels); ui-fact-big sets the
   first value, the figure the panel is about, larger. The Check File button of a Data Import tab (.ui-import-check) stands level with the file box, not the
   note under it. These rules are for the dl only: a ul.ui-facts (section 19, rows of an icon, a label and a value) must not take them (APP-2128). */
dl.ui-facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr)); gap: 1rem 1.5rem; margin: 0; }
dl.ui-facts .ui-fact-label { margin: 0; font-size: .8125rem; font-weight: 400; color: var(--bs-secondary-color); }
dl.ui-facts .ui-fact-value { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
dl.ui-facts .ui-fact-big { font-size: 1.5rem; line-height: 1.2; }
@media (min-width: 768px) { .ui-import-check .btn { min-height: 3.25rem; } }   /* as tall as the file box (.core-file-drop, file-upload.js) */

/* 37. APP-1949 part B, the owner's cleanup of Features Configuration and Reporting (2026-11-15). 1. A tab's main button is on the row of tabs: a control writes it in
   <div class="ui-tools" data-tools> beside the tab's help icon (Controls/ListActions.ascx does it with InTabRow="true"), Assets/js/tab-tools.js moves it into the
   row's tools, and it leads the icons (order -1). On a phone, where the row may be a drop-down, the row wraps and the tools take a line of their own at its right.
   2. .ui-filterrow: a list's search above it, one line of small-labelled boxes and small buttons. 3. .ui-text-cells: a cell holding a badge is the table's size
   (the theme's ".table tr > :not(td:has(.badge))" leaves it at the page's 16px). 4. .ui-people: a count that opens its list of names (Trade Levels' Employees).
   5. .ui-table-fit: a table that fits its card, its cells wrapping (Employees > Plans, Reporting > Requests by Day). Reporting's figures need no class of their
   own: they are Google Analytics' tiles (row g-3, col-6 col-md-3, card ui-panel h-100 mb-0, small label over fs-4 number). */
.ui-tabrow-tools > .btn, .ui-tabrow-tools > .ui-tabrow-actions { order: -1; margin-left: 1rem; margin-right: .5rem; white-space: nowrap; }
.ui-tabrow-actions { display: flex; align-items: center; gap: .5rem; }
.ui-tabrow-actions .btn { margin: 0 !important; }
@media (max-width: 575.98px) {
    .ui-tabrow:has(> .ui-tabrow-tools > :is(.btn, .ui-tabrow-actions):not([hidden])) { flex-wrap: wrap; }
    .ui-tabrow:has(> .ui-tabrow-tools > :is(.btn, .ui-tabrow-actions):not([hidden])) > .ui-tabrow-main { flex: 1 1 100%; }
    .ui-tabrow-tools > .btn, .ui-tabrow-tools > .ui-tabrow-actions { margin-left: 0; }
    .ui-tabrow-tools { flex-wrap: wrap; justify-content: flex-end; max-width: 100%; }
    .ui-tabrow-tools > .ui-tabrow-actions { flex: 1 1 100%; flex-wrap: wrap; justify-content: flex-end; min-width: 0; margin-right: 0; }   /* two buttons take a line of their own and the help and Refresh icons stay together on the next */
    .ui-tabrow-actions > .d-flex { flex-wrap: wrap; justify-content: flex-end; }   /* ListActions' own row of buttons wraps too, so a pair too wide for the phone stacks */
    .ui-tabrow:has(> .ui-tabrow-tools > :is(.btn, .ui-tabrow-actions):not([hidden])) > .ui-tabrow-tools { margin-left: auto; }
}
.ui-filterrow { display: flex; flex-wrap: wrap; align-items: flex-end; gap: .5rem; margin-bottom: 1rem; }
.ui-filterrow .form-label { font-size: .8125rem; font-weight: 400; color: var(--bs-secondary-color); margin-bottom: .25rem; }
.ui-filterrow .form-control, .ui-filterrow .form-select { width: auto; min-width: 8rem; }
.ui-filterrow .ui-filter-wide .form-control { min-width: 14rem; }
.ui-filterrow .ui-filter-narrow .form-control { min-width: 0; width: 6rem; }
@media (max-width: 575.98px) {
    .ui-filterrow > div { flex: 1 1 100%; }
    .ui-filterrow .form-control, .ui-filterrow .form-select, .ui-filterrow .ui-filter-narrow .form-control { width: 100%; }
}
.table.ui-text-cells tr > td:has(.badge) { font-size: .9rem; }
.ui-people > summary { cursor: pointer; white-space: nowrap; color: var(--bs-link-color); }
.ui-people[open] > summary { margin-bottom: .25rem; }
.ui-people-list { max-height: 12rem; overflow-y: auto; font-size: .8125rem; min-width: 12rem; }
.ui-people-list > div { padding: .125rem 0; overflow-wrap: anywhere; }
.table.ui-table-fit { width: 100%; }
.table.ui-table-fit > :not(caption) > * > * { padding-left: .5rem; padding-right: .5rem; }
.table.ui-table-fit th { white-space: nowrap; }

/* Team Overview (APP-2009, APP-2025; app/Dashboard/Team.aspx; reworked 2026-11-16 after the owner's two reviews). Every rule here is scoped to .ui-team or #divTeam, so no other
   screen changes. The whole company on one screen: a grid of compact cards, as many across as the width allows (300 px or more each, and never more than six across, so on a very wide screen the cards grow wider instead: four at 1440 px with the
   menu open, five at 1920 px, one on a phone), under the master page's own title, with the Automatic / My order switch at the right of the title row.
   A card is the photo with its online state built into it (a coloured ring and dot), the name, job title and cell phone, a clock band (a light tint of the theme
   colour with a coloured left edge when clocked in to a task, a lighter red one with a dashed edge when not), and one row with the Active or Away badge and the Open and Overdue
   task counts. A Tenant Administrator drags a card by its handle in My order (sort-order.js, data-sort-grid, f_dashboard_team_move). Colours are Bootstrap's
   theme colours, so light and dark follow the theme. */

.ui-team-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(max(18.75rem, (100% - 3.75rem) / 6), 100%), 1fr)); gap: .75rem; }
.ui-team-grid.ui-team-locked [data-sort-handle] { display: none; }
/* The Automatic / My order switch at a phone's width: compact, so the title beside it wraps to two lines at most (at 320 px it took three) */
@media (max-width: 575.98px) { .ui-team-order .btn { --bs-btn-padding-x: .45rem; --bs-btn-font-size: .75rem; } }
#divTeam .card.ui-panel.ui-team-card { container-type: inline-size; position: relative; display: flex; flex-direction: column; gap: .4rem; min-width: 0; margin: 0; padding: .5rem .625rem .625rem; border-top: 3px solid var(--bs-border-color); border-radius: .75rem; }
#divTeam .card.ui-panel.ui-team-card[hidden] { display: none; }
#divTeam .ui-team-card.is-clocked { border-top-color: var(--bs-primary); }
.ui-team-handle { position: absolute; top: .5rem; right: .5rem; line-height: 1; }
/* A finger's size (44 px) for the handle on a touch screen, still at the top right */
@media (pointer: coarse) { .ui-team-handle [data-sort-handle] { padding: .75rem .85rem; margin: -.75rem -.6rem; } }
.ui-team-head { display: flex; align-items: center; gap: .75rem; }
.ui-team-movable .ui-team-head { padding-right: 1.25rem; }
.ui-team-who { min-width: 0; line-height: 1.3; }
.ui-team-name { display: flex; align-items: center; gap: .25rem; margin: 0; font-size: 1.05rem; font-weight: 700; line-height: 1.25; }
.ui-team-name > a:first-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ui-team-job, .ui-team-phone { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .8125rem; }
.ui-team-job { color: var(--bs-secondary-color); }

/* The photo with the person's online state in it: a ring in the state's colour and a dot at its corner */
.ui-team-photo-wrap { position: relative; flex: 0 0 auto; width: 3.75rem; height: 3.75rem; border-radius: 50%; padding: 3px; background-color: var(--ui-team-state); }
.ui-team-photo { display: block; width: 100%; height: 100%; border-radius: 50%; object-fit: cover; border: 2px solid var(--bs-body-bg); background-color: var(--bs-tertiary-bg); }
.ui-team-dot { position: absolute; right: -2px; bottom: -2px; width: 1.05rem; height: 1.05rem; border-radius: 50%; background-color: var(--ui-team-state); border: 3px solid var(--bs-body-bg); }
.ui-team-state-active { --ui-team-state: color-mix(in srgb, var(--bs-success) 62%, var(--bs-body-bg)); }
.ui-team-state-away { --ui-team-state: var(--bs-warning); }
.ui-team-state-offline { --ui-team-state: color-mix(in srgb, var(--bs-body-color) 28%, var(--bs-body-bg)); }
.ui-team-state-active .ui-team-dot { box-shadow: 0 0 0 3px color-mix(in srgb, var(--bs-success) 18%, transparent); }

/* The clock band: a light tint with a coloured left edge while clocked in to a task, a dashed very light red band of the same size when not */
.ui-team-band { display: flex; flex-direction: column; justify-content: center; gap: 1px; min-height: 2.875rem; padding: .25rem .625rem; border-radius: .5rem; line-height: 1.3; }
.ui-team-band + .ui-team-band { margin-top: -.25rem; }
.ui-team-band-on { color: var(--bs-body-color); background-color: color-mix(in srgb, var(--bs-primary) 11%, var(--bs-body-bg)); border-left: 4px solid var(--bs-primary); border-radius: .25rem .5rem .5rem .25rem; }
.ui-team-band-on a { color: var(--bs-link-color); }
.ui-team-band-on .ui-team-band-line { font-weight: 400; }
.ui-team-band-off { flex-direction: row; align-items: center; gap: .5rem; color: var(--bs-body-color); background-color: color-mix(in srgb, var(--bs-danger) 5%, var(--bs-body-bg)); border: 2px dashed color-mix(in srgb, var(--bs-danger) 32%, var(--bs-body-bg)); border-left: 4px solid color-mix(in srgb, var(--bs-danger) 45%, var(--bs-body-bg)); font-weight: 600; }
.ui-team-band-off i { font-size: 1.25rem; }
.ui-team-band-line { display: flex; align-items: baseline; gap: .5rem; min-width: 0; }
.ui-team-band-text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ui-team-band-sub { font-size: .75rem; opacity: .92; }
.ui-team-band-sub .ui-team-band-text { flex: 1 1 auto; }
.ui-team-elapsed { flex: 0 0 auto; margin-left: auto; padding: 0 .5rem; border-radius: 999px; font-weight: 700; white-space: nowrap; color: var(--bs-body-color); background-color: color-mix(in srgb, var(--bs-primary) 20%, transparent); }
.ui-team-elapsed.is-warned { color: #fff; background-color: var(--bs-danger); }
.ui-team-more { font-size: .75rem; color: var(--bs-secondary-color); }

/* The row at the foot: the online badge, and the Open and Overdue counts */
.ui-team-foot { display: flex; align-items: center; gap: .25rem; min-width: 0; }
.ui-team-badge { display: block; flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; padding: .15rem .4rem; border-radius: 999px; font-size: .7rem; font-weight: 700; line-height: 1.3; white-space: nowrap; color: #fff; background-color: var(--ui-team-state); }
.ui-team-state-active .ui-team-badge { color: var(--bs-success-text-emphasis); background-color: var(--bs-success-bg-subtle); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--bs-success) 35%, transparent); }
.ui-team-state-away .ui-team-badge { color: #000; }
.ui-team-state-offline .ui-team-badge { color: var(--bs-body-color); background-color: var(--bs-secondary-bg); box-shadow: inset 0 0 0 1px var(--bs-border-color); }
.ui-team-badge-since { font-weight: 500; }
/* On the narrowest cards the word "since" goes, so the time and the counts keep their room (the badge's title says it in full) */
@container (max-width: 17.5rem) { .ui-team-badge-word { display: none; } }
.ui-team-counts { display: flex; flex: 0 0 auto; gap: .25rem; margin-left: auto; }
.ui-team-count { display: inline-flex; align-items: baseline; gap: .2rem; padding: .1rem .35rem; border-radius: .5rem; font-size: .7rem; line-height: 1.3; white-space: nowrap; text-decoration: none; color: var(--bs-body-color); background-color: var(--bs-tertiary-bg); border: 1px solid var(--bs-border-color); }
.ui-team-count b { font-size: .9375rem; font-variant-numeric: tabular-nums; }
a.ui-team-count:hover { border-color: var(--bs-primary); color: var(--bs-body-color); }
.ui-team-count-late { color: #fff; background-color: color-mix(in srgb, var(--bs-danger) 78%, #000); border-color: color-mix(in srgb, var(--bs-danger) 78%, #000); font-weight: 600; }
a.ui-team-count-late:hover { color: #fff; border-color: #fff; filter: brightness(1.1); }
.ui-team-count-none { color: var(--bs-secondary-color); background-color: transparent; }

/* The portal top bar's clocked-in task button and Triage Center icon (APP-2139; Templates/app/AppTopBar.ascx, every App template, App1 to App7;
   the portal pages only). The button is Bootstrap's success button in the Triage Center banner's clocked-in green, the task number on one line
   with a clock icon, at every width. The Triage Center icon is drawn always and shown only while the sidebar is collapsed (body[data-sidebar=sm],
   which the pin, the menu button and the window width change at once): at phone width, and on App1 and App4 from 992px. App2 (menu bar) and App3,
   5, 6, 7 (a sidebar that stays open from 992px) never show it from 992px, as their menu is in view there. */
.topbar-clock-task .btn-success { --bs-btn-bg: var(--ui-clock-running); --bs-btn-border-color: var(--ui-clock-running); --bs-btn-hover-bg: color-mix(in srgb, var(--ui-clock-running) 85%, #000); --bs-btn-hover-border-color: color-mix(in srgb, var(--ui-clock-running) 85%, #000); --bs-btn-active-bg: color-mix(in srgb, var(--ui-clock-running) 80%, #000); --bs-btn-active-border-color: color-mix(in srgb, var(--ui-clock-running) 80%, #000); --bs-btn-color: var(--ui-clock-text); --bs-btn-hover-color: var(--ui-clock-text); --bs-btn-active-color: var(--ui-clock-text); --bs-btn-focus-shadow-rgb: 20, 108, 67; white-space: nowrap; }
.topbar .topbar-triage { display: none; }
body[data-sidebar="sm"] .topbar .topbar-triage { display: block; }
/* Larger than the other icons, at the owner's request (its red is the sidebar's, inline from Core_AppMenu.SectionIconStyle). !important: app.min.css's
   .avatar-sm fixes 14px with !important, as .ui-server-indicator notes; the 38px box stays, so the bar's row keeps its height. line-height 1: the
   inherited 1.4 makes a 33.6px line box that sits the glyph off the box's centre */
.topbar .topbar-triage .avatar { font-size: 24px !important; line-height: 1; }
/* A narrow phone (320 to 399 px): the icons share the row with the menu button, so the button gives up its clock icon and some padding and the bar its gaps, and the number stays whole on one line */
@media (max-width: 399.98px) {
    .topbar .topbar-content .top-right-content { gap: 4px; }
    .topbar-clock-task .btn { padding-left: .25rem; padding-right: .25rem; font-size: .8rem; }
    .topbar-clock-task .btn > i { display: none; }
}
/* App2 draws its logo in the bar, which the button would overlap on a phone: the logo steps aside while the button shows */
@media (max-width: 479.98px) {
    html[data-template="App2"] .topbar:has(#divClockTask) .app-brand { display: none; }
}
@media (max-width: 339.98px) {
    .topbar .topbar-content .top-right-content { gap: 2px; }
}
@media (min-width: 992px) {
    html[data-template="App2"] .topbar .topbar-triage, html.app-frame:not([data-template="App4"]) .topbar .topbar-triage { display: none; }
}

/* The Estimate scope view (app/Projects/EstimateScope.aspx): printed, every tab's pane shows, one after the other (APP-2086; was an inline style) */
@media print {
    .scope-page .tab-content > .tab-pane { display: block !important; opacity: 1 !important; margin-bottom: 1.5rem; }
}
