/* ============================================================
   syncodia-core · ui · base.css
   The shared UI base: shell, components, utilities.
   Rules:
     · every class here starts with "core-"; state classes are "is-*"
     · no raw colours in this file: every colour comes from a token
       defined in themes/light.css, themes/dark.css or the product theme
     · geometry defaults (sizes, radii, spacing) live in :root below
       and may be overridden by a theme or a host
   ============================================================ */

/* ------------------------------------------------------------ fonts */
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 400; font-display: swap; src: url('fonts/inter-latin-ext-400-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 400; font-display: swap; src: url('fonts/inter-latin-400-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 500; font-display: swap; src: url('fonts/inter-latin-ext-500-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 500; font-display: swap; src: url('fonts/inter-latin-500-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 600; font-display: swap; src: url('fonts/inter-latin-ext-600-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 600; font-display: swap; src: url('fonts/inter-latin-600-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 700; font-display: swap; src: url('fonts/inter-latin-ext-700-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 700; font-display: swap; src: url('fonts/inter-latin-700-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

/* ------------------------------------------------------------ geometry tokens (no colours here) */
:root {
    --core-font:          'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
    --core-font-mono:     ui-monospace, 'JetBrains Mono', Consolas, monospace;
    --core-base-size:     16px;      /* the suite's text size (2 November 2026: 16) — the console can change it for the whole suite */
    --core-fs-2xs:        0.62rem;    /* nav group titles */
    --core-fs-xs:         0.68rem;    /* table heads, badges */
    --core-fs-label:      0.72rem;    /* field labels */
    --core-fs-sm:         0.8rem;     /* secondary text, tables */
    --core-fs-ctl:        0.825rem;   /* buttons, inputs, nav */
    --core-fs-md:         0.875rem;   /* body */
    --core-fs-lg:         0.95rem;    /* card and dialog titles */
    --core-fs-xl:         1.1rem;
    --core-fs-2xl:        1.3rem;     /* page title */
    --core-fs-hero:       2rem;       /* dashboard greeting / landing title */
    --core-fs-stat:       1.45rem;    /* stat values */
    --core-lh:            1.5;
    --core-weight-title:  600;

    --core-radius-sm:     2px;       /* corners "soft" (2 November 2026); the console can change them for the whole suite */
    --core-radius-md:     4px;
    --core-radius-lg:     6px;
    --core-radius-xl:     8px;
    --core-radius-pill:   999px;

    --core-sp-1: 4px;  --core-sp-2: 8px;  --core-sp-3: 12px; --core-sp-4: 16px;
    --core-sp-5: 20px; --core-sp-6: 24px; --core-sp-8: 32px; --core-sp-10: 40px; --core-sp-12: 48px;

    --core-ctl-h:         36px;      /* THE height of every control: field, select, date, lookup, stepper, colour, button, icon button (2 November 2026) */
    --core-ctl-h-sm:      28px;      /* only the actions inside a table row (--core-ctl-h-row) */
    --core-ctl-h-row:     var(--core-ctl-h-sm);
    --core-ctl-h-lg:      40px;
    --core-ctl-px:        12px;
    --core-ctl-radius:    var(--core-radius-md);
    --core-focus-w:       3px;
    --core-field-gap:     6px;       /* label → control inside a field */
    --core-row-gap:       var(--core-sp-4);   /* between fields in a row AND between two rows of fields */

    --core-sidebar-w:     264px;     /* 10.11.2026: room for the longer words (German), the folders of a big menu and the numbers */
    --core-sidebar-w-rail: 64px;     /* collapsed sidebar: icons only */
    --core-topbar-h:      52px;
    --core-page-px:       26px;
    --core-page-py:       22px;
    --core-page-max:      1600px;
    --core-block-gap:     var(--core-sp-4);   /* rule 11: the distance between the blocks of a page, the same across and down */
    --core-dialog-w:      680px;
    --core-card-pad:      18px;
    --core-card-head-h:   60px;   /* same height with or without a subtitle, so heads align across a row */
    --core-toggle-w:      34px;
    --core-card-radius:   var(--core-radius-lg);
    --core-table-row-h:   44px;
    --core-icon:          16px;

    --core-ease:          160ms cubic-bezier(.2, .7, .3, 1);
    --core-tint:          5%;        /* how much the neutrals lean towards the accent */
}

/* ------------------------------------------------------------ reset */
*, *::before, *::after { box-sizing: border-box; }
html { font-size: var(--core-base-size); -webkit-text-size-adjust: 100%; }
body {
    margin: 0;
    font-family: var(--core-font);
    font-size: var(--core-fs-md);
    line-height: var(--core-lh);
    color: var(--core-text);
    background: var(--core-bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
h1, h2, h3, h4, h5, h6, p { margin: 0; }
a { color: var(--core-accent-text); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
img, svg { display: block; max-width: 100%; }
table { border-collapse: collapse; border-spacing: 0; }
:focus-visible { outline: none; box-shadow: 0 0 0 var(--core-focus-w) var(--core-focus); }
::placeholder { color: var(--core-placeholder); opacity: 1; }
::selection { background: var(--core-selected); }

/* ------------------------------------------------------------ icons */
.core-icon { display: inline-block; vertical-align: -0.2em; width: var(--core-icon); height: var(--core-icon); flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }   /* inline in text like a glyph; flex parents align it themselves */
.core-icon-sm { width: 14px; height: 14px; }
.core-icon.core-glyph { fill: currentColor; stroke: none; }   /* a filled path at icon size: a product's brand mark (its own SVG, not from the sprite) */
.core-icon-md { width: 20px; height: 20px; }
.core-icon-lg { width: 24px; height: 24px; }
.core-icon-xl { width: 32px; height: 32px; stroke-width: 1.5; }
/* ------------------------------------------------------------ scrollbars (10 November 2026): the same everywhere — page, tables,
   menu, dialogs, menus — thin, in the theme's colours, vertical and horizontal. The thumb is the text colour faded, so it
   follows every theme (dark included); the track is transparent. A box that hides its bar on purpose (the tabs) keeps it hidden. */
:root { --core-scroll-thumb: color-mix(in srgb, var(--core-text) 24%, transparent); --core-scroll-thumb-hover: color-mix(in srgb, var(--core-text) 42%, transparent); }
/* the bands behind a time (UI.md "Gantt", 17 November 2026): the hours that are due, a span that is free to place
   (flexible: light stripes), a time paid more. Built from the theme's colours, so every theme has them. */
:root {
    --core-band: var(--core-surface-2);
    --core-band-line: var(--core-border-subtle);
    --core-band-stripe: var(--core-border-subtle);
    --core-band-plus: color-mix(in srgb, var(--core-pal-1-soft) 75%, var(--core-surface));       /* the first colour of the data palette, light */
    --core-band-plus-line: color-mix(in srgb, var(--core-pal-1) 35%, var(--core-surface));
}
/* Chrome, Edge, Safari: the drawn bar (no arrows); Firefox, which has no ::-webkit-scrollbar: the standard thin bar in the same colours */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track, ::-webkit-scrollbar-corner { background: transparent; }
::-webkit-scrollbar-button { display: none; }
::-webkit-scrollbar-thumb { background-color: var(--core-scroll-thumb); border: 3px solid transparent; border-radius: 10px; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background-color: var(--core-scroll-thumb-hover); }
.core-sidebar ::-webkit-scrollbar-thumb { background-color: color-mix(in srgb, var(--core-side-text) 26%, transparent); }
@supports not selector(::-webkit-scrollbar) {
    * { scrollbar-width: thin; scrollbar-color: var(--core-scroll-thumb) transparent; }
    .core-sidebar, .core-sidebar * { scrollbar-color: color-mix(in srgb, var(--core-side-text) 26%, transparent) transparent; }
}
.core-sprite { display: none; }   /* the inlined icon sprite: a class, so a strict CSP (style-src 'self') never shows the symbols */

/* ------------------------------------------------------------ app shell */
.core-app { display: flex; min-height: 100vh; }
.core-sidebar {
    position: fixed; top: 0; left: 0; bottom: 0; z-index: 40;
    width: var(--core-sidebar-w);
    display: flex; flex-direction: column;
    background: var(--core-side-bg);
    border-right: 1px solid var(--core-side-border);
    transition: transform var(--core-ease), width var(--core-ease);
}
.core-brand { display: flex; align-items: center; gap: 9px; height: var(--core-topbar-h); padding: 0 var(--core-sp-4); color: var(--core-side-text-strong); text-decoration: none; }
.core-sidebar .core-brand { border-bottom: 1px solid var(--core-side-border); }   /* same height as the top bar: the two lines meet */
/* the corner (UI.md "Shell", 18 November 2026): the side menu's own colour, like the top bar — one grey frame around the
   page; the product's colour is on its mark only (and on the accents of the page) */
.core-sidebar .core-brand { background: var(--core-corner-bg, transparent); color: var(--core-corner-text, var(--core-side-text-strong)); }
.core-sidebar .core-brand .core-brand-mark { background: var(--core-corner-mark-bg, var(--core-brand-mark-bg)); color: var(--core-corner-mark-text, var(--core-brand-mark-text)); }
@media (max-width: 768px) {
    .core-topbar { box-shadow: inset 0 3px 0 var(--core-brand-mark-bg, transparent); }   /* on a phone the menu is a drawer: a strip of the colour keeps the product recognisable */
    .core-search kbd { display: none; }   /* no keyboard shortcut on a phone: the field keeps its whole width for the text */
    .core-search .core-input { padding-right: 12px; }
    .core-tabs { overflow-x: auto; scrollbar-width: none; }   /* the tabs scroll sideways instead of leaving the screen */
    .core-tabs::-webkit-scrollbar { display: none; }
    .core-tabs > * { flex: none; }
}
.core-brand:hover { text-decoration: none; }
.core-brand-mark { width: 26px; height: 26px; border-radius: 6px; background: var(--core-brand-mark-bg); color: var(--core-brand-mark-text); display: inline-flex; align-items: center; justify-content: center; font-size: 0.85rem; font-weight: 700; letter-spacing: -0.02em; }
.core-brand-mark .core-icon { width: 16px; height: 16px; stroke-width: 2.4; }
.core-brand-name { font-size: 1rem; font-weight: 700; letter-spacing: -0.02em; }
/* the suite's logo (UI.md "Brand", 18 November 2026), printed by CoreUi::brand(): the product's mark on its colour, the
   company's name in bold and the product's name small under it, both in lower case; a fine ring keeps the mark apart
   from the menu when the two come close. The rail keeps the mark alone. */
.core-brand-logo .core-brand-mark { width: 32px; height: 32px; border-radius: 8px; flex: none; box-shadow: inset 0 0 0 1px var(--core-brand-mark-ring, transparent); }
.core-brand-mark .core-mark { width: 20px; height: 20px; display: block; }
.core-brand-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.1; gap: 1px; }
.core-brand-company { font-size: 1.06rem; font-weight: 700; letter-spacing: -0.02em; text-transform: lowercase; }
.core-brand-product { font-size: 0.78rem; font-weight: 500; text-transform: lowercase; color: var(--core-side-text, var(--core-text-2)); opacity: 0.85; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.core-topbar .core-brand-product { color: var(--core-topbar-muted); opacity: 1; }
.core-auth-brand .core-brand-product { color: var(--core-text-2); }
.core-site-brand { display: inline-flex; align-items: center; gap: 10px; color: var(--core-text); text-decoration: none; }   /* the head of a product's landing: the same logo, a size up */
.core-site-brand:hover { text-decoration: none; }
.core-site-brand .core-brand-mark { width: 36px; height: 36px; border-radius: 9px; }
.core-site-brand .core-brand-mark .core-mark { width: 22px; height: 22px; }
.core-site-brand .core-brand-company { font-size: 1.24rem; }
.core-site-brand .core-brand-product { font-size: 0.84rem; color: var(--core-text-2); opacity: 1; }
.core-brand-name b { color: var(--core-accent); }

/* the pictures of the application on a landing (UI.md "Pictures of the application", 18 November 2026): the page itself in
   a frame at the size it was taken in, scaled to the width of its box; it wears the product's theme in use (CoreShot) */
.core-shot { --core-shot-w: 1280px; --core-shot-h: 800px; container-type: inline-size; position: relative; overflow: hidden; aspect-ratio: 1280 / 800; }
.core-shot-narrow { --core-shot-w: 1060px; --core-shot-h: 700px; aspect-ratio: 1060 / 700; }
.core-shot iframe { position: absolute; top: 0; left: 0; width: var(--core-shot-w); height: var(--core-shot-h); border: 0; transform-origin: 0 0; transform: scale(tan(atan2(100cqw, var(--core-shot-w)))); pointer-events: none; }
html[data-core-shot], html[data-core-shot] body { overflow: hidden; }
html[data-core-shot] *, html[data-core-shot] *::before, html[data-core-shot] *::after { animation: none !important; transition: none !important; caret-color: transparent; }

.core-nav { flex: 1; overflow-y: auto; padding: var(--core-sp-3) var(--core-sp-3) var(--core-sp-4); }
.core-nav-group { margin-top: var(--core-sp-4); }
.core-nav-group:first-child { margin-top: var(--core-sp-1); }
.core-nav-group-title { padding: 0 var(--core-sp-3); margin-bottom: 3px; font-size: var(--core-fs-2xs); font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; color: var(--core-side-group); }
.core-nav-link {
    display: flex; align-items: center; gap: 10px;
    height: 32px; padding: 0 var(--core-sp-3); margin: 1px 0;
    border-radius: var(--core-radius-md);
    color: var(--core-side-text); font-size: var(--core-fs-ctl); font-weight: 400;
    text-decoration: none; cursor: pointer; border: 0; background: none; width: 100%; text-align: left;
    transition: background var(--core-ease), color var(--core-ease);
}
.core-nav-link:hover { background: var(--core-side-hover); color: var(--core-side-text-strong); text-decoration: none; }
.core-nav-link.is-active { background: var(--core-side-active-bg); color: var(--core-side-active-text); font-weight: 500; }
.core-nav-link.is-active::before { content: ''; position: absolute; left: 0; top: 7px; bottom: 7px; width: 3px; border-radius: 0 3px 3px 0; background: var(--core-side-stripe); }
.core-nav > .core-nav-group > .core-nav-link, .core-nav-item > .core-nav-link { position: relative; }
.core-nav-link.is-active .core-icon { color: var(--core-side-active-icon); }
/* the numbers keep their colours on the current page too: the row already says it is selected (10.11.2026, Christian) */
.core-nav-text { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.core-nav-link .core-icon { color: var(--core-side-icon); }
.core-nav-link .core-nav-chevron { margin-left: auto; width: 14px; height: 14px; opacity: 0.6; transition: transform var(--core-ease); }
.core-nav-item.is-open > .core-nav-link .core-nav-chevron { transform: rotate(90deg); }
.core-nav-badge { margin-left: auto; min-width: 18px; height: 18px; padding: 0 5px; border-radius: var(--core-radius-pill); background: var(--core-side-badge-bg); color: var(--core-side-badge-text); font-size: var(--core-fs-xs); font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }
.core-nav-link .core-nav-chevron + .core-nav-badge, .core-nav-badge + .core-nav-chevron { margin-left: 6px; }
/* the two numbers of a page (UI.md, "The menu"): the pill above is "it is your turn"; the queue is the same pill in a light grey */
.core-nav-count { margin-left: auto; min-width: 18px; height: 18px; padding: 0 5px; border-radius: var(--core-radius-pill); background: color-mix(in srgb, var(--core-side-text) 11%, transparent); color: var(--core-side-group); font-size: var(--core-fs-xs); font-weight: 600; font-variant-numeric: tabular-nums; display: inline-flex; align-items: center; justify-content: center; }
/* a closed folder never sums its pages: a dot when one of them has an alert; open, the pages show their own */
.core-nav-dot { margin-left: auto; width: 6px; height: 6px; border-radius: 50%; background: var(--core-side-badge-bg); flex: none; }
.core-nav-dot + .core-nav-chevron { margin-left: 8px; }
.core-nav-item.is-open > .core-nav-link > .core-nav-dot { display: none; }
.core-nav-item.is-open > .core-nav-link > .core-nav-dot + .core-nav-chevron { margin-left: auto; }
/* the favourites: a group on top, filled with the star of a page (shown on hover only: a menu of stars would be noise; filled when pinned) */
/* the star is always there but folded to no width (so the keyboard can reach it); on hover or keyboard focus it opens */
.core-nav-pin { flex: none; margin-left: auto; width: 0; height: 22px; overflow: hidden; opacity: 0; border-radius: var(--core-radius-sm); color: var(--core-side-icon); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
.core-nav-link:hover > .core-nav-pin + .core-nav-badge, .core-nav-link:hover > .core-nav-pin + .core-nav-count, .core-nav-pin:focus-visible + * { margin-left: 4px; }   /* the star comes before the numbers, the numbers stay at the end of the row */
.core-nav-pin .core-icon { width: 14px; height: 14px; }
.core-nav-pin:hover { color: var(--core-side-text-strong); background: var(--core-side-hover); }
.core-nav-pin[aria-pressed="true"] { color: var(--core-side-icon); }   /* pinned: the star filled in the grey of the menu icons — no yellow, no black */
.core-nav-pin[aria-pressed="true"] .core-icon { fill: currentColor; }
.core-nav-link:hover > .core-nav-pin, .core-nav-pin:focus-visible { width: 22px; opacity: 1; }   /* only the pointer or the keyboard on the star itself opens it: a focus left on the row never keeps it */
.core-nav-favs[hidden] { display: none; }
.core-nav.is-quiet .core-nav-pin { width: 0; opacity: 0; }   /* right after a star changed the menu, until the pointer moves (ui.js) */
.core-nav.is-quiet .core-nav-link:hover:not(.is-active) { background: transparent; }
@media (hover: none) { .core-nav-link.is-active > .core-nav-pin { width: 22px; opacity: 1; } }   /* a touch screen has no hover: the star of the current page stays in view */
.core-nav-sub { display: none; margin: 2px 0 6px; padding-left: 26px; position: relative; }
.core-nav-sub::before { content: ''; position: absolute; left: 19px; top: 4px; bottom: 4px; width: 1px; background: var(--core-side-border); }
.core-nav-item.is-open > .core-nav-sub { display: block; }
.core-nav-sub .core-nav-link { height: 29px; font-size: var(--core-fs-sm); font-weight: 400; }
.core-nav-sub .core-nav-link { position: relative; }
.core-nav-sub .core-nav-link > .core-icon { display: none; }   /* a page's icon is for the rail; in the full menu the page is its name under the group */
.core-nav-sub .core-nav-link.is-active { font-weight: 500; }
.core-nav-sub .core-nav-link.is-active::before { top: 50%; bottom: auto; left: -11px; width: 6px; height: 6px; margin-top: -3px; border-radius: 50%; }

.core-sidebar-foot { border-top: 1px solid var(--core-side-border); padding: var(--core-sp-3); }
.core-user { display: flex; align-items: center; gap: 10px; padding: 6px 8px; border-radius: var(--core-radius-md); color: var(--core-side-text); cursor: pointer; }
.core-user:hover { background: var(--core-side-hover); text-decoration: none; }   /* the tile is a link: no underline on hover */
.core-user-name { font-size: var(--core-fs-sm); font-weight: 500; color: var(--core-side-text-strong); line-height: 1.25; }
.core-user-meta { font-size: var(--core-fs-xs); color: var(--core-side-group); line-height: 1.25; }
.core-user .core-icon { margin-left: auto; color: var(--core-side-icon); }

/* collapsed sidebar (rail): .core-app.is-collapsed — icons only, labels as tooltips */
/* the label of a rail icon: one box on the page (ui.js), fixed beside the icon under the pointer — drawn inside the menu it
   would be cut by the menu's scrolling and would widen the menu (a scroll bar under the icons on Windows) */
.core-rail-tip { position: fixed; z-index: 1000; transform: translateY(-50%); background: var(--core-side-tip-bg); color: var(--core-side-tip-text); font-size: var(--core-fs-sm); font-weight: 500; padding: 5px 9px; border-radius: var(--core-radius-md); white-space: nowrap; box-shadow: var(--core-shadow-md); pointer-events: none; opacity: 0; transition: opacity var(--core-ease); }
.core-rail-tip.is-on { opacity: 1; }
.core-sidebar-toggle { display: inline-flex; }
@media (min-width: 769px) {   /* the rail exists on desktop only: on a phone the sidebar is a drawer and is always full */
    .core-app.is-collapsed .core-sidebar { width: var(--core-sidebar-w-rail); }
    .core-app.is-collapsed .core-main { margin-left: var(--core-sidebar-w-rail); }
    .core-app.is-collapsed .core-brand { justify-content: center; padding: 0; }
    .core-app.is-collapsed .core-brand-name,
    .core-app.is-collapsed .core-brand-text,
    .core-app.is-collapsed .core-nav-text,
    .core-app.is-collapsed .core-nav-chevron,
    .core-app.is-collapsed .core-nav-sub,
    .core-app.is-collapsed .core-user > div,
    .core-app.is-collapsed .core-user > .core-icon { display: none; }
    .core-app.is-collapsed .core-nav { padding-left: 10px; padding-right: 10px; overflow-x: hidden; scrollbar-width: none; }   /* the rail scrolls with the wheel, without a bar: a bar would eat its right side and push the icons off centre */
    .core-app.is-collapsed .core-nav::-webkit-scrollbar { display: none; }
    .core-app.is-collapsed .core-nav-group-title { height: 1px; padding: 0; margin: var(--core-sp-3) 6px var(--core-sp-2); background: var(--core-side-border); overflow: hidden; color: transparent; }
    .core-app.is-collapsed .core-nav-group:first-child .core-nav-group-title { display: none; }
    .core-app.is-collapsed .core-nav-link { justify-content: center; padding: 0; width: 44px; height: 40px; margin: 2px 0; position: relative; }
    .core-app.is-collapsed .core-nav-badge,
    .core-app.is-collapsed .core-nav-dot { position: absolute; top: 8px; right: 9px; min-width: 6px; width: 6px; height: 6px; padding: 0; margin: 0; font-size: 0; }
    .core-app.is-collapsed .core-nav-count,
    .core-app.is-collapsed .core-nav-pin { display: none; }
    .core-app.is-collapsed .core-sidebar-foot { padding: var(--core-sp-2); }
    .core-app.is-collapsed .core-user { justify-content: center; padding: 6px 0; }
    /* the rail keeps the pages of the open group in view as their icons (a menu grouped in core-nav-item whose pages carry one) */
    .core-app.is-collapsed .core-nav-item.is-open > .core-nav-sub:has(> .core-nav-link > .core-icon) { display: block; margin: 0; padding-left: 0; }
    .core-app.is-collapsed .core-nav-item.is-open { background: var(--core-side-hover); border-radius: var(--core-radius-md); }   /* the open group and its pages read as one block */
    .core-app.is-collapsed .core-nav-sub::before { display: none; }
    .core-app.is-collapsed .core-nav-sub .core-nav-link > .core-icon { display: block; }
    .core-app.is-collapsed .core-nav-sub .core-nav-link { height: 40px; }
    .core-app.is-collapsed .core-nav-sub .core-nav-link.is-active::before { top: 7px; bottom: 7px; left: 0; width: 3px; height: auto; margin-top: 0; border-radius: 0 3px 3px 0; }
}
.core-sidebar .core-sidebar-toggle { color: var(--core-side-icon); }

.core-main { flex: 1; min-width: 0; margin-left: var(--core-sidebar-w); display: flex; flex-direction: column; min-height: 100vh; transition: margin-left var(--core-ease); }
.core-app.is-bare .core-main { margin-left: 0; }   /* no sidebar at all: a wizard, a product's panel framed inside another product (docs/INTEGRATION.md) */
.core-topbar {
    position: sticky; top: 0; z-index: 30;
    display: flex; align-items: center; gap: var(--core-sp-3);
    height: var(--core-topbar-h); padding: 0 var(--core-page-px);
    background: var(--core-topbar-bg); color: var(--core-topbar-text);
    border-bottom: 1px solid var(--core-topbar-border);
    backdrop-filter: saturate(1.4) blur(8px);
}
.core-topbar .core-btn-ghost { color: var(--core-topbar-muted); }
.core-topbar .core-btn-ghost:hover { background: var(--core-topbar-hover); color: var(--core-topbar-text); }
.core-topbar .core-brand { display: none; padding: 0; margin-right: var(--core-sp-4); color: var(--core-topbar-text); }
:root[data-topbar="primary"] .core-topbar .core-brand { display: flex; }
:root[data-topbar="primary"] .core-sidebar .core-brand { display: none; }
:root[data-topbar="primary"] .core-topbar { backdrop-filter: none; position: fixed; left: 0; right: 0; }
:root[data-topbar="primary"] .core-sidebar { top: var(--core-topbar-h); }
:root[data-topbar="primary"] .core-content { padding-top: calc(var(--core-topbar-h) + var(--core-page-py)); }
:root[data-topbar="primary"] .core-dot::after { box-shadow: 0 0 0 2px var(--core-topbar-bg); background: var(--core-topbar-text); }
:root[data-topbar="primary"] .core-topbar .core-faint { color: var(--core-topbar-muted); }   /* the page's name after the business's, on the colour */
/* the bar in the app colour lined up with the page below it: the mark as wide as the menu with the menu button at its
   end, a thin line where the menu ends, the search (what follows the button) where the content starts */
@media (min-width: 769px) {
    :root[data-topbar="primary"] .core-topbar { padding-left: 0; gap: 0; }
    :root[data-topbar="primary"] .core-topbar::before { content: ""; position: absolute; top: 0; bottom: 0; left: calc(var(--core-sidebar-w) - 1px); width: 1px; background: color-mix(in srgb, var(--core-topbar-text) 22%, transparent); }
    :root[data-topbar="primary"] .core-topbar .core-brand { box-sizing: border-box; flex: none; width: calc(var(--core-sidebar-w) - var(--core-ctl-h) - var(--core-sp-2)); margin: 0; padding: 0 var(--core-sp-4); }
    :root[data-topbar="primary"] .core-topbar [data-core-sidebar-toggle] { flex: none; margin-right: var(--core-sp-2); }
    :root[data-topbar="primary"] .core-topbar [data-core-sidebar-toggle] + * { margin-left: var(--core-page-px); }
    /* the menu closed: its rail holds only the menu button, like the icons below it */
    :root[data-topbar="primary"] .core-app.is-collapsed .core-topbar::before { left: calc(var(--core-sidebar-w-rail) - 1px); }
    :root[data-topbar="primary"] .core-app.is-collapsed .core-topbar .core-brand { display: none; }
    :root[data-topbar="primary"] .core-app.is-collapsed .core-topbar [data-core-sidebar-toggle] { margin: 0 calc((var(--core-sidebar-w-rail) - var(--core-ctl-h)) / 2); }
    /* no menu (core-app is-bare: a wizard, a panel framed in another product): nothing to line up with, the bar keeps its spacing */
    :root[data-topbar="primary"] .core-app.is-bare .core-topbar { padding-left: var(--core-page-px); gap: var(--core-sp-3); }
    :root[data-topbar="primary"] .core-app.is-bare .core-topbar::before { display: none; }
    :root[data-topbar="primary"] .core-app.is-bare .core-topbar .core-brand { width: auto; padding: 0; margin-right: var(--core-sp-4); }
    :root[data-topbar="primary"] .core-app.is-bare .core-topbar [data-core-sidebar-toggle] + * { margin-left: 0; }
}
@media (max-width: 768px) {
    :root[data-topbar="primary"] .core-topbar { box-shadow: none; }   /* the bar is the colour already: no strip on top */
    :root[data-topbar="primary"] .core-topbar .core-brand-name { display: none; }   /* the mark alone, the search gets the room */
}
.core-topbar-title { min-width: 0; font-size: var(--core-fs-sm); color: var(--core-topbar-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.core-topbar-title b { color: var(--core-topbar-text); font-weight: 600; }
.core-topbar-actions { margin-left: auto; display: flex; align-items: center; gap: var(--core-sp-1); }
.core-topbar-center { position: absolute; left: 50%; transform: translateX(-50%); }   /* one control in the middle of the bar: the mode of a work screen (a till: counter or tables) */
@media (max-width: 1100px) { .core-topbar-center { position: static; transform: none; } }
.core-search { position: relative; width: 300px; max-width: 100%; }
.core-search .core-icon { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; pointer-events: none; color: var(--core-text-3); }
.core-search .core-input { padding-left: 34px; padding-right: 44px; background: var(--core-field-bg-soft); border-color: transparent; }
.core-search .core-input:focus { background: var(--core-field-bg); border-color: var(--core-accent); }
.core-search kbd { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); font: 600 var(--core-fs-xs) var(--core-font); color: var(--core-text-3); border: 1px solid var(--core-border); border-radius: var(--core-radius-sm); padding: 1px 5px; background: transparent; pointer-events: none; }
/* the filters of a list in its card head (UI.md rule 10): the search takes the room, a select its natural width */
.core-card-actions > .core-search { flex: 0 1 300px; width: auto; min-width: 140px; }   /* the search gives way when the head is narrow */
.core-card-actions > .core-select { width: auto; flex: 0 0 auto; }
.core-card-actions > form, .core-card-actions > .core-btn, .core-card-actions > .core-btn-group { flex: none; }   /* a select in its form (it reloads the page), a button, a group keep their width: the title wraps first */
.core-card-actions > form .core-select { width: auto; }
.core-topbar .core-search .core-icon { color: var(--core-topbar-muted); }
.core-topbar .core-search .core-input { background: var(--core-topbar-field-bg); color: var(--core-topbar-text); }
.core-topbar .core-search .core-input::placeholder { color: var(--core-topbar-muted); }
.core-topbar .core-search .core-input:focus { background: var(--core-field-bg); color: var(--core-text); border-color: var(--core-accent); }
.core-topbar .core-search kbd { color: var(--core-topbar-muted); border-color: var(--core-topbar-kbd-border); }
.core-topbar-sep { width: 1px; height: 22px; background: var(--core-topbar-kbd-border); margin: 0 var(--core-sp-2); }
/* a word beside an icon in the bar (Feedback, CoreFeedback::button): on a phone the icon alone */
@media (max-width: 768px) { .core-topbar .core-topbar-label { display: none; } }
/* a notice of the account in the top bar (the trial that ends): one short line, the link to act on it in the accent */
.core-topbar-notice { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 var(--core-sp-3); border-radius: var(--core-radius-pill); background: var(--core-surface-2); border: 1px solid var(--core-border); color: var(--core-text-2); font-size: var(--core-fs-sm); white-space: nowrap; text-decoration: none; margin-right: var(--core-sp-2); }
.core-topbar-notice .core-icon { width: 14px; height: 14px; color: var(--core-text-3); }
.core-topbar-notice b { font-weight: 600; color: var(--core-accent-text); }
a.core-topbar-notice:hover { border-color: var(--core-border-stronger); color: var(--core-text); }
@media (max-width: 768px) { .core-topbar-notice span { display: none; } }   /* on a phone the icon and the link stay */
.core-dot { position: relative; }
.core-dot::after { content: ''; position: absolute; top: 7px; right: 7px; width: 8px; height: 8px; border-radius: 50%; background: var(--core-accent); box-shadow: 0 0 0 2px var(--core-surface); }

.core-content { flex: 1; width: 100%; max-width: var(--core-page-max); padding: var(--core-page-py) var(--core-page-px); }
.core-page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--core-sp-4); margin-bottom: var(--core-sp-5); }
.core-page-title { font-size: var(--core-fs-2xl); font-weight: var(--core-weight-title); letter-spacing: -0.015em; line-height: 1.25; display: flex; align-items: center; gap: 8px; }
.core-page-title .core-icon { color: var(--core-title-icon); width: 18px; height: 18px; }
/* the landing page of an app (dashboard, greeting): one big title, Booking measure — inner pages keep the 1.3rem title */
.core-page-title-lg { font-size: var(--core-fs-hero); font-weight: 700; letter-spacing: -0.02em; line-height: 1.15; }
.core-page-title-lg .core-icon { width: 22px; height: 22px; }
.core-page-sub { margin-top: 3px; color: var(--core-text-3); font-size: var(--core-fs-sm); }
.core-page-actions { display: flex; align-items: center; gap: var(--core-sp-2); flex-shrink: 0; }
.core-breadcrumb { display: flex; align-items: center; gap: 6px; font-size: var(--core-fs-sm); color: var(--core-text-3); margin-bottom: var(--core-sp-2); }
.core-breadcrumb a { color: var(--core-text-2); }
.core-breadcrumb .core-icon { width: 14px; height: 14px; }
.core-section-title { font-size: var(--core-fs-xs); font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; color: var(--core-text-3); margin: var(--core-sp-6) 0 var(--core-sp-4); padding-bottom: var(--core-sp-2); border-bottom: 1px solid var(--core-border); line-height: var(--core-lh); }
.core-section-title:first-child { margin-top: 0; }
/* the standard (UI.md, Anatomy): a section title is words only — an icon a page still writes there is not shown (the audit names it) */
.core-section-title .core-icon { display: none; }

/* ------------------------------------------------------------ layout helpers */
.core-grid { display: grid; gap: var(--core-block-gap); }
.core-grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.core-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.core-grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.core-grid-main { grid-template-columns: minmax(0, 2fr) minmax(320px, 1fr); }
.core-grid-start { align-items: start; }   /* cards in a row keep their own height instead of stretching to the tallest */
.core-span-2 { grid-column: span 2; }
.core-span-all { grid-column: 1 / -1; }
.core-row { display: flex; align-items: center; gap: var(--core-sp-2); }
.core-row-wrap { flex-wrap: wrap; }
.core-row-between { justify-content: space-between; } .core-row-end { justify-content: flex-end; } .core-row-center { justify-content: center; }
.core-row-top { align-items: flex-start; } .core-row-bottom { align-items: flex-end; }
.core-stack { display: flex; flex-direction: column; gap: var(--core-sp-3); }
.core-grow { flex: 1; min-width: 0; }
.core-push { margin-left: auto; }
.core-gap-1 { gap: var(--core-sp-1); } .core-gap-2 { gap: var(--core-sp-2); } .core-gap-3 { gap: var(--core-sp-3); } .core-gap-4 { gap: var(--core-sp-4); } .core-gap-6 { gap: var(--core-sp-6); }
.core-mt-0 { margin-top: 0; } .core-mt-1 { margin-top: var(--core-sp-1); } .core-mt-2 { margin-top: var(--core-sp-2); } .core-mt-4 { margin-top: var(--core-sp-4); } .core-mt-6 { margin-top: var(--core-sp-6); }
.core-mb-0 { margin-bottom: 0; } .core-mb-1 { margin-bottom: var(--core-sp-1); } .core-mb-2 { margin-bottom: var(--core-sp-2); } .core-mb-4 { margin-bottom: var(--core-sp-4); } .core-mb-6 { margin-bottom: var(--core-sp-6); }
.core-me-2 { margin-right: var(--core-sp-2); }
/* the rhythm of a page (UI.md rule 11, 2 November 2026): the core sets the distance between the blocks of a page — head,
   alert, a row of stats, a row of cards, a card — one --core-block-gap, the same as between two cards of a row. A page
   does not set it (a core-mt-* / core-mb-* on a block is overruled: same weight as the utilities, written after them); .core-blocks gives the same rhythm to a wrapper
   (a form holding several cards). What is not a block — scripts, hidden parts, a layer over the page (a dialog, the scrim,
   the viewer) — neither gets nor makes it. */
.core-content > :where(:not(script, style, template, link, input[type="hidden"], [hidden], .core-hidden, .core-dialog-overlay, .core-scrim, .core-viewer)),
.core-blocks > :where(:not(script, style, template, link, input[type="hidden"], [hidden], .core-hidden, .core-dialog-overlay, .core-scrim, .core-viewer)) { margin-top: 0; margin-bottom: 0; }
.core-content > :where(:not(script, style, template, link, input[type="hidden"], [hidden], .core-hidden, .core-dialog-overlay, .core-scrim, .core-viewer)) ~ :where(:not(script, style, template, link, input[type="hidden"], [hidden], .core-hidden, .core-dialog-overlay, .core-scrim, .core-viewer)),
.core-blocks > :where(:not(script, style, template, link, input[type="hidden"], [hidden], .core-hidden, .core-dialog-overlay, .core-scrim, .core-viewer)) ~ :where(:not(script, style, template, link, input[type="hidden"], [hidden], .core-hidden, .core-dialog-overlay, .core-scrim, .core-viewer)) { margin-top: var(--core-block-gap); }
.core-p-0 { padding: 0 !important; }   /* a utility that says "no padding" wins over every component padding (a card body, 2 November 2026) */
.core-w-full { width: 100%; }
.core-block { display: block; } .core-inline { display: inline; } .core-inline-flex { display: inline-flex; align-items: center; gap: var(--core-sp-2); }
.core-pointer { cursor: pointer; }
.core-muted { color: var(--core-text-2); }
.core-faint { color: var(--core-text-3); }
.core-small { font-size: var(--core-fs-sm); }
.core-xs { font-size: var(--core-fs-xs); }
.core-strong { font-weight: 600; }
.core-num { font-variant-numeric: tabular-nums; }
.core-mono { font-family: var(--core-font-mono); font-size: 0.9em; }
.core-right { text-align: right; }
.core-center { text-align: center; }
.core-left { text-align: left; }
.core-text-ok { color: var(--core-ok); } .core-text-warn { color: var(--core-warn); } .core-text-danger { color: var(--core-danger); }
.core-nowrap { white-space: nowrap; }
.core-truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
[hidden], .core-hidden { display: none !important; }   /* the hidden attribute always wins over a component display */
.core-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.core-divider { height: 1px; background: var(--core-border); border: 0; margin: var(--core-sp-4) 0; }
.core-link { color: var(--core-accent-text); font-weight: 500; }

/* ------------------------------------------------------------ cards */
.core-card { background: var(--core-surface); border: 1px solid var(--core-card-border); border-radius: var(--core-card-radius); box-shadow: var(--core-card-shadow); min-width: 0; display: flex; flex-direction: column; }
.core-card-head { display: flex; flex-wrap: wrap; align-items: center; gap: var(--core-sp-3); min-height: var(--core-card-head-h); padding: 12px var(--core-card-pad); border-bottom: 1px solid var(--core-border); }
.core-card-head > :first-child:not(.core-card-actions) { flex: 1 1 12rem; min-width: 0; }   /* the title takes the room left and wraps; only when the actions need more do they go to a line of their own, instead of out of the card */
.core-card-title { font-size: var(--core-fs-md); font-weight: var(--core-weight-title); letter-spacing: -0.01em; display: flex; align-items: center; gap: 8px; }
.core-card-title .core-icon { color: var(--core-title-icon); }
.core-card-sub { font-size: var(--core-fs-sm); color: var(--core-text-3); }
.core-card-actions { margin-left: auto; display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: center; gap: var(--core-sp-2); min-width: 0; }
.core-card-body { padding: var(--core-card-pad); }
/* a card of one fixed height (a dashboard row of lists): its body scrolls, a table head stays on top */
.core-card-fixed { height: var(--core-card-fixed-h, 440px); }
.core-card-fixed-sm { --core-card-fixed-h: 320px; }   /* a chart, a short summary */
.core-card-fixed > .core-card-body > canvas { display: block; width: 100%; height: 100%; }
.core-card-fixed > .core-card-body { flex: 1; min-height: 0; overflow-y: auto; }
.core-card-fixed > .core-card-body > .core-empty { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.core-card-fixed .core-table thead th, .core-till .core-table thead th { position: sticky; top: 0; z-index: 1; }
.core-card-fixed .core-table tfoot, .core-till .core-table tfoot { position: sticky; bottom: 0; z-index: 1; }   /* the totals stay in view while the rows scroll */
/* a list beside its detail (core-card-fixed core-card-pane): as tall as its row, at most the window; it stays in view and its rows scroll */
@media (min-width: 992px) {
    .core-grid-12 > :has(> .core-card-pane) { align-self: stretch; }
    .core-card-pane { position: sticky; top: calc(var(--core-topbar-h) + var(--core-page-py)); height: 100%; max-height: calc(100vh - var(--core-topbar-h) - 2 * var(--core-page-py)); }
}
.core-card-body + .core-card-body { border-top: 1px solid var(--core-border); }
.core-card-foot { display: flex; align-items: center; gap: var(--core-sp-2); padding: var(--core-sp-3) var(--core-card-pad); border-top: 1px solid var(--core-border); background: var(--core-surface-2); border-radius: 0 0 var(--core-card-radius) var(--core-card-radius); margin-top: auto; }   /* stays at the bottom when cards in a row stretch */
.core-card-flush .core-card-body { padding: 0; }
.core-card-bar { padding: 10px var(--core-card-pad); border-bottom: 1px solid var(--core-border-subtle); min-width: 0; }   /* a line under the head of a card: its chips, its filters (17 November 2026) */
/* a colour the user chose on any element (data-core-color, painted by ui.js readable in the theme — UI.md "Colours of data") */
.core-color-soft { background: var(--core-c-soft); color: var(--core-c-text); }
.core-color-solid { background: var(--core-c); color: var(--core-c-on); }
.core-card-body:has(> .core-table-wrap:only-child, > .core-table:only-child) { padding: 0; }   /* a table in a card runs edge to edge: its head under the card head, its rows to the card border */
.core-card-accent { border-top: 3px solid var(--core-accent); }

/* stat tiles */
.core-stat { background: var(--core-surface); border: 1px solid var(--core-card-border); border-radius: var(--core-card-radius); box-shadow: var(--core-card-shadow); padding: var(--core-card-pad); display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.core-stat-label { font-size: var(--core-fs-sm); color: var(--core-text-2); font-weight: 500; display: flex; align-items: center; gap: 8px; }
.core-stat-label .core-icon { width: 16px; height: 16px; color: var(--core-text-3); }
.core-stat-value { font-size: var(--core-fs-stat); font-weight: var(--core-weight-title); letter-spacing: -0.02em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.core-stat-delta { font-size: var(--core-fs-sm); color: var(--core-text-3); display: flex; align-items: center; gap: 6px; }   /* plain words: "+3 vs yesterday"; an optional trend icon sits inline */
.core-stat-delta .core-icon { width: 14px; height: 14px; }
.core-stat-delta.is-up, .core-stat-delta.is-down { color: var(--core-text-3); }   /* a change is information, not a state: grey, its arrow says up or down (UI.md, colours) */
/* the stat of the suite (2 November 2026, "B"): the icon in the product's soft colour, the same for every tile; a change sits
   beside the value, small, grey, with its arrow — the tile keeps its height whether a change is there or not */
.core-stat-icon { width: 36px; height: 36px; border-radius: var(--core-radius-md); background: var(--core-accent-soft); color: var(--core-accent-text); display: inline-flex; align-items: center; justify-content: center; }
.core-stat-value { display: flex; align-items: baseline; column-gap: 8px; min-width: 0; }   /* one line: the change is short (a number), what it compares with is its title */
.core-stat-trend { display: inline-flex; align-items: center; gap: 3px; min-width: 0; overflow: hidden; text-overflow: ellipsis; font-size: var(--core-fs-sm); font-weight: 500; letter-spacing: 0; color: var(--core-text-3); white-space: nowrap; }
.core-stat-trend .core-icon { width: 14px; height: 14px; }
/* with an icon box the tile reads left-to-right: box, then label / value / delta beside it (Booking measure) */
.core-stat:has(.core-stat-icon) { display: grid; grid-template-columns: 36px minmax(0, 1fr); column-gap: 12px; row-gap: 4px; align-content: start; }
.core-stat:has(.core-stat-icon) .core-stat-icon { grid-row: 1 / span 3; align-self: start; }
.core-stat:has(.core-stat-icon) .core-stat-label, .core-stat:has(.core-stat-icon) .core-stat-value, .core-stat:has(.core-stat-icon) .core-stat-delta { grid-column: 2; }
/* a tile that filters what is under it (17 November 2026): a link, the chosen one framed in the accent */
a.core-stat { color: inherit; text-decoration: none; transition: border-color var(--core-ease), box-shadow var(--core-ease); }
a.core-stat:hover { border-color: var(--core-border-strong); text-decoration: none; }
a.core-stat:focus-visible { outline: none; box-shadow: 0 0 0 var(--core-focus-w) var(--core-focus); }
.core-stat.is-on, a.core-stat.is-on:hover { border-color: var(--core-accent); box-shadow: 0 0 0 1px var(--core-accent); }

/* facts: label / value pairs inside a card (the plan of an account, the summary of a record): dl.core-facts > dt + dd */
.core-facts { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 6px var(--core-sp-5); font-size: var(--core-fs-sm); }
:where(.core-facts) { margin: 0; }   /* no weight: the rhythm of a page or a form places it */
.core-facts dt { color: var(--core-text-3); }
.core-facts dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }

/* ------------------------------------------------------------ buttons */
.core-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 7px;
    height: var(--core-ctl-h); padding: 0 var(--core-sp-4);
    border: 1px solid transparent; border-radius: var(--core-ctl-radius);
    font-size: var(--core-fs-ctl); font-weight: 500; line-height: 1; white-space: nowrap;
    text-decoration: none; cursor: pointer; user-select: none;
    transition: background var(--core-ease), border-color var(--core-ease), color var(--core-ease), box-shadow var(--core-ease), transform var(--core-ease);
}
.core-btn:hover { text-decoration: none; }
.core-btn:active { transform: translateY(1px); }
.core-btn .core-icon { width: 16px; height: 16px; }
.core-btn:disabled, .core-btn.is-disabled { opacity: 0.5; pointer-events: none; }
.core-btn-primary { background: var(--core-btn-primary-bg); color: var(--core-btn-primary-text); border-color: var(--core-btn-primary-bg); box-shadow: var(--core-btn-shadow); }
.core-btn-primary:hover { background: var(--core-btn-primary-hover); border-color: var(--core-btn-primary-hover); }
.core-btn-secondary { background: var(--core-surface); color: var(--core-text); border-color: var(--core-border-strong); box-shadow: var(--core-btn-shadow); }
.core-btn-secondary:hover { background: var(--core-hover); border-color: var(--core-border-stronger); }
.core-btn-ghost { background: transparent; color: var(--core-text-2); }
.core-btn-ghost:hover { background: var(--core-hover); color: var(--core-text); }
.core-btn-soft { background: var(--core-accent-soft); color: var(--core-accent-text); }
.core-btn-soft:hover { background: var(--core-accent-soft-2); }
.core-btn-danger { background: var(--core-danger); color: var(--core-on-danger); border-color: var(--core-danger); }
.core-btn-danger:hover { background: var(--core-danger-hover); border-color: var(--core-danger-hover); }
.core-btn-danger-soft { background: var(--core-danger-bg); color: var(--core-danger); border-color: var(--core-danger-border); }
.core-btn-danger-soft:hover { background: var(--core-danger-border); }
.core-btn-link { background: none; color: var(--core-accent-text); padding: 0 var(--core-sp-1); height: auto; }
.core-btn-link:hover { text-decoration: underline; }
.core-btn-link-danger { color: var(--core-danger); }
.core-btn-sm { height: var(--core-ctl-h); }   /* one height: "-sm" outside a table row is the normal button (2 November 2026) */
.core-table .core-btn-sm { height: var(--core-ctl-h-row); padding: 0 var(--core-sp-3); font-size: var(--core-fs-sm); gap: 5px; }   /* the actions of a table row */
.core-table .core-btn-sm .core-icon { width: 14px; height: 14px; }
.core-btn-lg { height: var(--core-ctl-h-lg); padding: 0 var(--core-sp-5); font-size: var(--core-fs-md); }
.core-btn-icon { width: var(--core-ctl-h); padding: 0; }
.core-table .core-btn-icon.core-btn-sm { width: var(--core-ctl-h-row); padding: 0; }   /* the padding of a row button would squeeze its icon to 2 px */
.core-btn-icon .core-icon { width: 18px; height: 18px; }
.core-btn-pill { border-radius: var(--core-radius-pill); }
.core-btn-block { width: 100%; }
.core-btn.is-loading { position: relative; color: transparent !important; pointer-events: none; }
.core-btn.is-loading::after { content: ''; position: absolute; width: 16px; height: 16px; border: 2px solid var(--core-spinner-track); border-top-color: var(--core-spinner); border-radius: 50%; animation: core-spin 0.7s linear infinite; }
@keyframes core-spin { to { transform: rotate(360deg); } }
.core-btn-group { display: inline-flex; }
.core-btn-group .core-btn { border-radius: 0; margin-left: -1px; }
.core-btn-group .core-btn:first-child { border-radius: var(--core-ctl-radius) 0 0 var(--core-ctl-radius); margin-left: 0; }
.core-btn-group .core-btn:last-child { border-radius: 0 var(--core-ctl-radius) var(--core-ctl-radius) 0; }
.core-btn-group .core-btn.is-active { background: var(--core-accent-soft); color: var(--core-accent-text); border-color: var(--core-accent); position: relative; z-index: 1; }   /* quick choices: the chosen one */

/* ------------------------------------------------------------ forms */
.core-form { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--core-sp-4); }   /* an explicit minmax(0, 1fr) column: a wide table inside scrolls instead of widening the form */
.core-form-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--core-sp-4); }
.core-form-row-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.core-form-row-wide { grid-template-columns: minmax(0, 3fr) minmax(0, 1fr); }   /* a wide field and a short one: street + building number */
/* the 12-column grid of a form or a page: fields side by side with the row gap, and two grids one under the other keep the
   same gap between them — the rhythm comes from the core, never from a margin a page adds (2 November 2026) */
.core-grid-12 { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--core-row-gap); align-items: start; }
.core-grid-12 > * { grid-column: span 12; min-width: 0; }
.core-grid-12 > .core-col-1 { grid-column: span 1; } .core-grid-12 > .core-col-2 { grid-column: span 2; } .core-grid-12 > .core-col-3 { grid-column: span 3; } .core-grid-12 > .core-col-4 { grid-column: span 4; }
.core-grid-12 > .core-col-5 { grid-column: span 5; } .core-grid-12 > .core-col-6 { grid-column: span 6; } .core-grid-12 > .core-col-7 { grid-column: span 7; } .core-grid-12 > .core-col-8 { grid-column: span 8; }
.core-grid-12 > .core-col-9 { grid-column: span 9; } .core-grid-12 > .core-col-10 { grid-column: span 10; } .core-grid-12 > .core-col-11 { grid-column: span 11; } .core-grid-12 > .core-col-12 { grid-column: span 12; }
@media (min-width: 992px) {
    .core-grid-12 > .core-col-lg-1 { grid-column: span 1; } .core-grid-12 > .core-col-lg-2 { grid-column: span 2; } .core-grid-12 > .core-col-lg-3 { grid-column: span 3; } .core-grid-12 > .core-col-lg-4 { grid-column: span 4; }
    .core-grid-12 > .core-col-lg-5 { grid-column: span 5; } .core-grid-12 > .core-col-lg-6 { grid-column: span 6; } .core-grid-12 > .core-col-lg-7 { grid-column: span 7; } .core-grid-12 > .core-col-lg-8 { grid-column: span 8; }
    .core-grid-12 > .core-col-lg-9 { grid-column: span 9; } .core-grid-12 > .core-col-lg-10 { grid-column: span 10; } .core-grid-12 > .core-col-lg-11 { grid-column: span 11; } .core-grid-12 > .core-col-lg-12 { grid-column: span 12; }
}
@media (min-width: 1200px) {
    .core-grid-12 > .core-col-xl-1 { grid-column: span 1; } .core-grid-12 > .core-col-xl-2 { grid-column: span 2; } .core-grid-12 > .core-col-xl-3 { grid-column: span 3; } .core-grid-12 > .core-col-xl-4 { grid-column: span 4; }
    .core-grid-12 > .core-col-xl-5 { grid-column: span 5; } .core-grid-12 > .core-col-xl-6 { grid-column: span 6; } .core-grid-12 > .core-col-xl-7 { grid-column: span 7; } .core-grid-12 > .core-col-xl-8 { grid-column: span 8; }
    .core-grid-12 > .core-col-xl-9 { grid-column: span 9; } .core-grid-12 > .core-col-xl-10 { grid-column: span 10; } .core-grid-12 > .core-col-xl-11 { grid-column: span 11; } .core-grid-12 > .core-col-xl-12 { grid-column: span 12; }
}
@media (max-width: 768px) { .core-grid-12 > [class*="core-col-"] { grid-column: span 12; } }
.core-grid-12 + .core-grid-12, .core-form-row + .core-form-row { margin-top: var(--core-row-gap); }
.core-form > .core-grid-12 + .core-grid-12, .core-form > .core-form-row + .core-form-row { margin-top: 0; }   /* the form's own gap already spaces them */
/* the rhythm of a form (UI.md rule 11): in a dialog, a card or a tab panel the fields and rows of fields stack with the row gap,
   the same as between two fields of a row — however the page wrote them (a field after a row, a row after a field…); a hidden
   part (the alert of an error, until there is one) is not a row: what follows it takes the gap from the row before it, or none */
:is(.core-dialog-body, .core-card-body, [data-core-panel], .core-grid-12 > [class*="core-col"]:not(.core-field)) > :is(.core-field, .core-grid-12, .core-form-row, .core-alert, .core-table-wrap, .core-check, .core-switch, .core-input-group, .core-empty, .core-table, .core-choices, .core-row, .core-stack, .core-facts, .core-grid, .core-stat, .core-seg, .core-btn-group, .core-pin-dots, .core-keypad, p, form):where(:not([hidden], .core-hidden)) + :is(.core-field, .core-grid-12, .core-form-row, .core-alert, .core-table-wrap, .core-check, .core-switch, .core-input-group, .core-empty, .core-table, .core-choices, .core-row, .core-stack, .core-facts, .core-grid, .core-stat, .core-seg, .core-btn-group, .core-pin-dots, .core-keypad, p, form),
:is(.core-dialog-body, .core-card-body, [data-core-panel], .core-grid-12 > [class*="core-col"]:not(.core-field)) > :is(.core-field, .core-grid-12, .core-form-row, .core-alert, .core-table-wrap, .core-check, .core-switch, .core-input-group, .core-empty, .core-table, .core-choices, .core-row, .core-stack, .core-facts, .core-grid, .core-stat, .core-seg, .core-btn-group, .core-pin-dots, .core-keypad, p, form) + :is([hidden], .core-hidden) + :is(.core-field, .core-grid-12, .core-form-row, .core-alert, .core-table-wrap, .core-check, .core-switch, .core-input-group, .core-empty, .core-table, .core-choices, .core-row, .core-stack, .core-facts, .core-grid, .core-stat, .core-seg, .core-btn-group, .core-pin-dots, .core-keypad, p, form) { margin-top: var(--core-row-gap); }
/* inside a field the compound controls keep their natural width instead of stretching to the column */
.core-field > .core-seg, .core-field > .core-stepper, .core-field > .core-btn-group { align-self: flex-start; }
/* a cell with only buttons next to fields that have a label: its buttons sit on the fields' line, not under the label line */
.core-field-actions { display: flex; align-items: center; flex-wrap: wrap; gap: var(--core-sp-2); min-width: 0; padding-top: calc(var(--core-fs-label) * var(--core-lh) + var(--core-field-gap)); }
.core-field { display: flex; flex-direction: column; gap: var(--core-field-gap); min-width: 0; }
.core-field-inline { display: flex; flex-direction: row; align-items: center; flex-wrap: wrap; gap: var(--core-sp-2); }   /* a toolbar of fields: select, dates, search, button */
.core-field-inline .core-input, .core-field-inline .core-select, .core-field-inline .core-input-icon { width: auto; }   /* fields take their natural width in a toolbar */
.core-label { font-size: var(--core-fs-label); font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--core-text-2); }
.core-label-plain { text-transform: none; letter-spacing: 0; font-size: var(--core-fs-sm); }
.core-label-hint { text-transform: none; letter-spacing: 0; font-weight: 400; color: var(--core-text-3); margin-left: 4px; }   /* "(optional)" next to a label */
.core-label .core-req { color: var(--core-danger); margin-left: 2px; }
.core-hint { font-size: var(--core-fs-sm); color: var(--core-text-3); }
.core-hint:empty { display: none; }   /* a message line waiting for its text takes no room */
.core-error { font-size: var(--core-fs-sm); color: var(--core-danger); display: flex; align-items: center; gap: 4px; }
.core-error .core-icon { width: 14px; height: 14px; }
.core-input, .core-select, .core-textarea {
    width: 100%; height: var(--core-ctl-h); padding: 0 var(--core-ctl-px);
    background: var(--core-field-bg); color: var(--core-text);
    border: 1px solid var(--core-field-border); border-radius: var(--core-ctl-radius);
    font-size: var(--core-fs-ctl); line-height: 1.4;
    transition: border-color var(--core-ease), box-shadow var(--core-ease), background var(--core-ease);
}
.core-input:hover, .core-select:hover, .core-textarea:hover { border-color: var(--core-border-stronger); }
input[type="search"]::-webkit-search-cancel-button { -webkit-appearance: none; appearance: none; }   /* the browser's blue cross is not one of ours */
.core-input:focus, .core-select:focus, .core-textarea:focus { border-color: var(--core-accent); box-shadow: 0 0 0 var(--core-focus-w) var(--core-focus); outline: none; }
.core-input:disabled, .core-select:disabled, .core-textarea:disabled { background: var(--core-field-bg-soft); color: var(--core-text-3); cursor: not-allowed; }
.core-input[readonly] { background: var(--core-field-bg-soft); }
.core-field.is-invalid .core-input, .core-field.is-invalid .core-select, .core-field.is-invalid .core-textarea { border-color: var(--core-danger); }
.core-field-error { font-size: var(--core-fs-sm); color: var(--core-danger); }   /* the message under an invalid field */
.core-field.is-invalid .core-input:focus { box-shadow: 0 0 0 var(--core-focus-w) var(--core-danger-border); }
.core-textarea { height: auto; min-height: 88px; padding: 9px var(--core-ctl-px); resize: vertical; line-height: var(--core-lh); }
.core-select { appearance: none; padding-right: 34px; background-image: var(--core-select-arrow); background-repeat: no-repeat; background-position: right 10px center; background-size: 16px; }
.core-input-sm, .core-select-sm { height: var(--core-ctl-h); }   /* one height: "-sm" outside a table row is the normal field */
.core-table .core-input-sm, .core-table .core-select-sm { height: var(--core-ctl-h-row); font-size: var(--core-fs-sm); }
.core-table td > .core-input-sm[type="number"] { width: 96px; }   /* a quantity in a row keeps a quantity's width */
/* input group: field + addon (unit, prefix, button) on either side; only the outer corners are rounded, borders overlap by 1px */
.core-input-group { display: flex; align-items: stretch; }
.core-input-group > * { border-radius: 0; }
.core-input-group > * + * { margin-left: -1px; }
.core-input-group > :first-child { border-radius: var(--core-ctl-radius) 0 0 var(--core-ctl-radius); }
.core-input-group > :last-child { border-radius: 0 var(--core-ctl-radius) var(--core-ctl-radius) 0; }
.core-input-group .core-input, .core-input-group .core-select { flex: 1; min-width: 0; }
.core-row > .core-input-group { flex: 1; min-width: 96px; }   /* beside buttons it takes the rest of the row */
.core-input-group .core-input:focus { position: relative; z-index: 1; }
.core-input-addon { flex: 0 1 auto; max-width: 60%; height: var(--core-ctl-h); line-height: calc(var(--core-ctl-h) - 2px); padding: 0 var(--core-sp-3); border: 1px solid var(--core-field-border); background: var(--core-field-bg-soft); color: var(--core-text-3); font-size: var(--core-fs-sm); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }   /* a long prefix (a URL) shortens with an ellipsis instead of crushing the field */
.core-input-icon { position: relative; }
.core-input-icon .core-icon { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; color: var(--core-text-3); pointer-events: none; }
.core-input-icon .core-input { padding-left: 34px; }

/* lookup: pick a record (a patient, a customer, a product) — the display at the control height + a list under it */
.core-lookup { position: relative; min-width: 0; }
.core-lookup-display { display: flex; align-items: center; gap: var(--core-sp-2); width: 100%; height: var(--core-ctl-h); padding: 0 10px 0 var(--core-ctl-px); background: var(--core-field-bg); color: var(--core-text); border: 1px solid var(--core-field-border); border-radius: var(--core-ctl-radius); font-size: var(--core-fs-ctl); text-align: left; cursor: pointer; transition: border-color var(--core-ease), box-shadow var(--core-ease); }
.core-lookup-display:hover { border-color: var(--core-border-stronger); }
.core-lookup-display:focus-visible, .core-lookup.is-open .core-lookup-display { outline: none; border-color: var(--core-accent); box-shadow: 0 0 0 var(--core-focus-w) var(--core-focus); }
.core-lookup-display > .core-icon { color: var(--core-text-3); }
.core-lookup-value { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.core-lookup-value:empty::before { content: attr(data-placeholder); color: var(--core-placeholder); }   /* nothing chosen: the placeholder */
.core-lookup-clear { display: inline-flex; padding: 2px; border: 0; background: none; color: var(--core-text-3); border-radius: var(--core-radius-sm); cursor: pointer; }
.core-lookup-clear:hover { color: var(--core-text); background: var(--core-hover); }
.core-lookup-value:empty ~ .core-lookup-clear { display: none; }   /* nothing to clear */
.core-lookup-pop { display: none; position: absolute; z-index: 60; left: 0; right: 0; top: calc(100% + 4px); padding: var(--core-sp-2); background: var(--core-surface); border: 1px solid var(--core-border); border-radius: var(--core-radius-md); box-shadow: var(--core-shadow-lg); }
.core-lookup.is-open .core-lookup-pop { display: block; }
.core-lookup-search { width: 100%; }
.core-lookup-data { display: none; }   /* the inline list a short lookup carries (a JSON script) */
.core-lookup-items { max-height: 260px; overflow-y: auto; margin-top: var(--core-sp-2); }
.core-lookup-item { display: flex; flex-direction: column; gap: 1px; padding: var(--core-sp-2); border-radius: var(--core-radius-sm); cursor: pointer; }
.core-lookup-item:hover, .core-lookup-item.is-focus { background: var(--core-hover); }
.core-lookup-item.is-selected { background: var(--core-selected); }
.core-lookup-title { font-size: var(--core-fs-sm); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.core-lookup-sub { font-size: var(--core-fs-xs); color: var(--core-text-3); }
.core-lookup-empty { padding: var(--core-sp-2); font-size: var(--core-fs-sm); color: var(--core-text-3); }

/* stepper: − value + at the control height (a quantity, a number of sessions) */
.core-stepper { display: inline-flex; align-items: stretch; }
.core-stepper > * { border-radius: 0; }
.core-stepper > * + * { margin-left: -1px; }
.core-stepper > :first-child { border-radius: var(--core-ctl-radius) 0 0 var(--core-ctl-radius); }
.core-stepper > :last-child { border-radius: 0 var(--core-ctl-radius) var(--core-ctl-radius) 0; }
.core-stepper .core-input { width: 56px; text-align: center; padding: 0 4px; -moz-appearance: textfield; appearance: textfield; }
.core-stepper .core-input::-webkit-inner-spin-button, .core-stepper .core-input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.core-stepper .core-input:focus { position: relative; z-index: 1; }

/* a file to pick (13 November 2026): the browser's own field speaks the browser's language ("Choose File", "No file
   chosen") and cannot be styled — so the field is hidden and the box says it in the app's language: the button part,
   then the name of the file chosen (or the "nothing chosen" text, grey). CoreUi::file() prints it, ui.js writes the name. */
.core-file { position: relative; display: flex; align-items: stretch; width: 100%; height: var(--core-ctl-h); background: var(--core-field-bg); color: var(--core-text); border: 1px solid var(--core-field-border); border-radius: var(--core-ctl-radius); font-size: var(--core-fs-ctl); cursor: pointer; overflow: hidden; transition: border-color var(--core-ease), box-shadow var(--core-ease); }
.core-file:hover { border-color: var(--core-border-stronger); }
.core-file:has(input:focus-visible) { border-color: var(--core-accent); box-shadow: 0 0 0 var(--core-focus-w) var(--core-focus); }
.core-file-btn { flex: 0 0 auto; display: inline-flex; align-items: center; gap: var(--core-sp-2); padding: 0 var(--core-ctl-px); background: var(--core-field-bg-soft); border-right: 1px solid var(--core-field-border); font-weight: 500; white-space: nowrap; }
.core-file-btn .core-icon { color: var(--core-text-3); }
.core-file-name { flex: 1; min-width: 0; align-self: center; padding: 0 var(--core-ctl-px); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.core-file-name.is-empty { color: var(--core-text-3); }
.core-file:has(input:disabled) { background: var(--core-field-bg-soft); color: var(--core-text-3); cursor: not-allowed; }
.core-file.is-drag { border-color: var(--core-accent); background: var(--core-accent-soft); }   /* a file dragged over the box (13 November 2026): dropping it picks it */

/* a free colour: the swatch that opens the system picker + its code */
.core-color { display: flex; align-items: center; gap: var(--core-sp-2); min-width: 0; }
.core-color input[type="color"] { flex: 0 0 auto; width: calc(var(--core-ctl-h) * 1.25); height: var(--core-ctl-h); padding: 3px; border: 1px solid var(--core-field-border); border-radius: var(--core-ctl-radius); background: var(--core-field-bg); cursor: pointer; }
.core-color input[type="color"]::-webkit-color-swatch-wrapper { padding: 0; }
.core-color input[type="color"]::-webkit-color-swatch { border: 0; border-radius: calc(var(--core-ctl-radius) - 2px); }
.core-color input[type="color"]::-moz-color-swatch { border: 0; border-radius: calc(var(--core-ctl-radius) - 2px); }

/* a dropdown that shows the colour (from CVMaestro's colour combo): button + list, every item with its swatch; a hidden input carries the value */
.core-cselect { position: relative; min-width: 0; }
.core-cselect-btn { display: flex; align-items: center; gap: var(--core-sp-2); width: 100%; height: var(--core-ctl-h); padding: 0 10px 0 var(--core-ctl-px); background: var(--core-field-bg); color: var(--core-text); border: 1px solid var(--core-field-border); border-radius: var(--core-ctl-radius); font-size: var(--core-fs-ctl); text-align: left; cursor: pointer; transition: border-color var(--core-ease), box-shadow var(--core-ease); }
.core-cselect-btn:hover { border-color: var(--core-border-stronger); }
.core-cselect-btn:focus-visible, .core-cselect.is-open .core-cselect-btn { outline: none; border-color: var(--core-accent); box-shadow: 0 0 0 var(--core-focus-w) var(--core-focus); }
.core-cselect-btn > .core-icon { color: var(--core-text-3); transition: transform var(--core-ease); }
.core-cselect.is-open .core-cselect-btn > .core-icon { transform: rotate(180deg); }
.core-cselect-lbl { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.core-cselect-sw { flex: 0 0 auto; width: 16px; height: 16px; border-radius: var(--core-radius-sm); background: var(--sw, var(--core-n300)); outline: 1px solid var(--core-border-strong); outline-offset: -1px; }
.core-cselect-pop { display: none; position: absolute; z-index: 60; left: 0; right: 0; top: calc(100% + 4px); max-height: 240px; overflow-y: auto; padding: var(--core-sp-1); background: var(--core-surface); border: 1px solid var(--core-border); border-radius: var(--core-radius-md); box-shadow: var(--core-shadow-lg); }
.core-cselect.is-open .core-cselect-pop { display: block; }
.core-cselect-item { display: flex; align-items: center; gap: var(--core-sp-2); min-height: 32px; padding: 0 var(--core-sp-2); border-radius: var(--core-radius-sm); cursor: pointer; font-size: var(--core-fs-ctl); }
.core-cselect-item:hover, .core-cselect-item.is-focus { background: var(--core-hover); }
.core-cselect-text { flex: 1; min-width: 0; }
.core-cselect-check { color: var(--core-accent-text); visibility: hidden; }
.core-cselect-item[aria-selected="true"] { font-weight: 600; }
.core-cselect-item[aria-selected="true"] .core-cselect-check { visibility: visible; }
.core-cselect-other { border-top: 1px solid var(--core-border-subtle); margin-top: var(--core-sp-1); }   /* "Other colour…": the browser's picker (CoreUi::colorSelect) */
.core-cselect-sw[data-color=""] { background: transparent; outline-style: dashed; }

.core-check { display: inline-flex; align-items: center; gap: 8px; font-size: var(--core-fs-ctl); cursor: pointer; user-select: none; }
.core-check input { appearance: none; width: 16px; height: 16px; margin: 0; border: 1.5px solid var(--core-border-stronger); border-radius: 5px; background: var(--core-field-bg); display: inline-grid; place-content: center; transition: background var(--core-ease), border-color var(--core-ease); flex-shrink: 0; }
.core-check input[type="radio"] { border-radius: 50%; }
.core-check input::before { content: ''; width: 10px; height: 10px; transform: scale(0); transition: transform var(--core-ease); background: var(--core-on-accent); clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%); }
.core-check input[type="radio"]::before { clip-path: none; border-radius: 50%; width: 8px; height: 8px; }
.core-check input:checked { background: var(--core-accent); border-color: var(--core-accent); }
.core-check input:checked::before { transform: scale(1); }
.core-check input:focus-visible { box-shadow: 0 0 0 var(--core-focus-w) var(--core-focus); }
.core-check input:disabled { opacity: 0.45; cursor: default; }   /* a choice that cannot be changed (a fixed role, a right outside the plan) */
.core-check:has(input:disabled) { cursor: default; }
.core-check-desc { display: block; font-size: var(--core-fs-sm); color: var(--core-text-3); }
.core-check:has(.core-check-desc), .core-switch:has(.core-check-desc) { align-items: flex-start; }   /* with a description the box stays on the first line, beside the title */
.core-check:has(.core-check-desc) input { margin-top: calc((var(--core-fs-ctl) * var(--core-lh) - 16px) / 2); }
.core-switch:has(.core-check-desc) input { margin-top: calc((var(--core-fs-ctl) * var(--core-lh) - 20px) / 2); }

.core-switch { display: inline-flex; align-items: center; gap: 9px; cursor: pointer; user-select: none; font-size: var(--core-fs-ctl); }
.core-switch input { appearance: none; width: var(--core-toggle-w); height: 20px; margin: 0; border-radius: var(--core-radius-pill); background: var(--core-switch-off); position: relative; transition: background var(--core-ease); flex-shrink: 0; }
.core-switch input::before { content: ''; position: absolute; top: 3px; left: 3px; width: 14px; height: 14px; border-radius: 50%; background: var(--core-switch-knob); box-shadow: var(--core-shadow-sm); transition: transform var(--core-ease); }
.core-switch input:checked { background: var(--core-accent); }
.core-switch input:checked::before { transform: translateX(14px); }
.core-switch input:focus-visible { box-shadow: 0 0 0 var(--core-focus-w) var(--core-focus); }
/* a vertical list of checks / switches: one control column, so every label starts on the same line */
.core-options { display: flex; flex-direction: column; gap: 10px; }
.core-options .core-check, .core-options .core-switch { display: grid; grid-template-columns: var(--core-toggle-w) 1fr; gap: 10px; align-items: center; }
.core-options .core-check input { justify-self: start; }
.core-options :is(.core-check, .core-switch):has(.core-check-desc) { align-items: start; }

.core-form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--core-sp-2); padding-top: var(--core-sp-2); }   /* wraps on a narrow screen instead of widening the page */
.core-form-actions .core-push { margin-left: auto; }

/* ------------------------------------------------------------ badges, chips, avatars */
.core-badge { display: inline-flex; align-items: center; gap: 5px; height: 21px; padding: 0 7px; border-radius: var(--core-radius-sm); font-size: var(--core-fs-xs); font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; white-space: nowrap; background: var(--core-badge-bg); color: var(--core-badge-text); border: 1px solid var(--core-badge-border); }
.core-badge .core-icon { width: 12px; height: 12px; }
.core-badge-dot::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--core-badge-dot, currentColor); flex-shrink: 0; }
/* state badges are tinted: field = band 50, line = band 200, text = band 700 (Booking measure); .core-badge-quiet keeps the grey field and lets the dot carry the colour */
.core-badge-ok { --core-badge-dot: var(--core-ok-bright); background: var(--core-ok-bg); color: var(--core-ok); border-color: var(--core-ok-border); }
.core-badge-warn { --core-badge-dot: var(--core-warn-bright); background: var(--core-warn-bg); color: var(--core-warn); border-color: var(--core-warn-border); }
.core-badge-danger { --core-badge-dot: var(--core-danger-bright); background: var(--core-danger-bg); color: var(--core-danger); border-color: var(--core-danger-border); }
.core-badge-info { --core-badge-dot: var(--core-accent); background: var(--core-info-bg); color: var(--core-info); border-color: var(--core-info-border); }
.core-badge-quiet { background: var(--core-badge-bg); color: var(--core-badge-text); border-color: var(--core-badge-border); }
.core-badge-tint.core-badge-ok { background: var(--core-ok-bg); color: var(--core-ok); border-color: var(--core-ok-border); }
.core-badge-tint.core-badge-warn { background: var(--core-warn-bg); color: var(--core-warn); border-color: var(--core-warn-border); }
.core-badge-tint.core-badge-danger { background: var(--core-danger-bg); color: var(--core-danger); border-color: var(--core-danger-border); }
.core-badge-tint.core-badge-info { background: var(--core-info-bg); color: var(--core-info); border-color: var(--core-info-border); }
.core-badge-accent { background: var(--core-accent-soft); color: var(--core-accent-text); border-color: var(--core-accent-border); }
.core-badge-solid { background: var(--core-accent); color: var(--core-on-accent); border-color: var(--core-accent); }
.core-badge-pill { border-radius: var(--core-radius-pill); }
.core-badge-wide { min-width: 88px; justify-content: center; }

.core-chip { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 11px; border-radius: var(--core-radius-pill); border: 1px solid var(--core-border-strong); background: var(--core-surface); color: var(--core-text-2); font-size: var(--core-fs-sm); font-weight: 500; cursor: pointer; user-select: none; white-space: nowrap; transition: background var(--core-ease), border-color var(--core-ease), color var(--core-ease); }
.core-chip:hover { background: var(--core-hover); color: var(--core-text); }
.core-chip.is-on { background: var(--core-chip-on-bg); border-color: var(--core-chip-on-border); color: var(--core-chip-on-text); }
.core-chip .core-chip-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--core-chip-dot, var(--core-text-3)); }
.core-chip .core-icon { width: 14px; height: 14px; }
.core-chip-x { margin-right: -6px; width: 18px; height: 18px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; opacity: 0.6; }
.core-chip-x:hover { opacity: 1; background: var(--core-chip-on-border); }
button.core-chip-x { border: 0; padding: 0; background: none; color: inherit; font: inherit; cursor: pointer; }   /* the ✕ of a removable chip (an attachment of the Feedback dialog) */
button.core-chip-x:hover { background: var(--core-hover); }
/* a till (a point of sale): the sale on top, the menu of the catalog on the left as big tiles, the catalog, the receipt
   on the right; it fills the screen below the page head, the catalog and the receipt scroll inside their cards */
.core-content:has(> .core-till) { display: flex; flex-direction: column; }
.core-till { flex: 1 1 auto; min-height: 520px; display: grid; grid-template-areas: "top top top" "nav main side"; grid-template-columns: auto minmax(0, 1fr) 420px; grid-template-rows: auto minmax(0, 1fr); gap: var(--core-block-gap); }
.core-till > * { min-height: 0; }
.core-till-top { grid-area: top; }
.core-till-nav { grid-area: nav; }
.core-till-main { grid-area: main; }
.core-till-side { grid-area: side; }
.core-till-main > .core-card-body, .core-till-side > .core-card-body { flex: 1; min-height: 0; overflow-y: auto; }
.core-till-side > .core-card-foot > .core-btn { height: 48px; font-size: var(--core-fs-md); font-weight: 700; }   /* the two buttons of the receipt are the big ones of the screen */
/* the receipt is narrow: the name wraps, quantity, amount and the remove button always stay in view */
.core-till-side .core-table td.core-td-main { width: 100%; min-width: 0; max-width: 0; }
.core-till-side .core-table :is(th, td):not(:first-child):not(:last-child) { padding-left: 6px; padding-right: 6px; }
.core-till-side .core-stepper .core-input { width: 40px; }
.core-till-side .core-table td.core-td-main .core-cell-primary { white-space: normal; overflow: visible; text-overflow: clip; }
/* tiles: a menu of a few big buttons, an icon, a word, a count (the catalog menu of a till) */
.core-tiles { display: flex; flex-direction: column; gap: var(--core-sp-2); width: 140px; padding: 10px; background: var(--core-surface-2); border: 1px solid var(--core-card-border); border-radius: var(--core-card-radius); }
.core-tile { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--core-sp-2); padding: 20px 8px; border: 1px solid var(--core-border); border-radius: var(--core-radius-md); background: var(--core-surface); color: var(--core-text-2); font: inherit; cursor: pointer; box-shadow: var(--core-shadow-sm); transition: border-color var(--core-ease), color var(--core-ease); }
.core-tile .core-icon { width: 24px; height: 24px; }
.core-tile-label { font-size: var(--core-fs-xs); font-weight: 500; text-transform: uppercase; letter-spacing: 0.03em; line-height: 1; color: var(--core-text-3); }
.core-tile-count { position: absolute; top: 6px; right: 6px; font-size: var(--core-fs-2xs); font-weight: 700; line-height: 1.2; padding: 2px 5px; border-radius: var(--core-radius-pill); background: var(--core-surface-2); color: var(--core-text-2); }
.core-tile:hover:not(:disabled):not(.is-active) { border-color: var(--core-accent); color: var(--core-accent-text); }
.core-tile.is-active { color: var(--core-text); box-shadow: inset 0 -3px 0 var(--core-accent); }
.core-tile.is-active .core-tile-label { color: var(--core-text); }
.core-tile.is-active .core-tile-count { background: var(--core-accent); color: var(--core-on-accent); }
.core-tile:disabled { opacity: 0.35; cursor: default; }
/* tiles with a picture (a catalog whose categories have photos): the picture on the left, the name beside it, the count at the end;
   a tile without a picture keeps its icon in the same place */
.core-tiles-media { width: 196px; }
.core-tiles-media .core-tile { flex-direction: row; justify-content: flex-start; gap: 12px; padding: 8px 10px 8px 8px; }
.core-tiles-media .core-tile > img, .core-tiles-media .core-tile > .core-icon { flex: none; width: 44px; height: 44px; border-radius: var(--core-radius-sm); }
.core-tiles-media .core-tile > img { object-fit: cover; }
.core-tiles-media .core-tile > .core-icon { box-sizing: border-box; padding: 11px; }
.core-tiles-media .core-tile-label { text-transform: none; letter-spacing: 0; font-size: var(--core-fs-sm); line-height: 1.25; text-align: left; }
.core-tiles-media .core-tile-count { position: static; margin-left: auto; }
/* the shape of the tiles: core-tiles-round (the picture or the icon in a circle, the name under it), core-tiles-pill
   (rounded ends); core-tiles-plain = no border and no panel (the tile shows itself when chosen) */
.core-tiles-round .core-tile { flex-direction: column; justify-content: center; gap: 6px; padding: 12px 6px 10px; border-radius: 18px; text-align: center; }
.core-tiles-round:not(.core-tiles-media) .core-tile > .core-icon { box-sizing: border-box; width: 52px; height: 52px; padding: 14px; border-radius: 50%; background: var(--core-surface-2); }
.core-tiles-round.core-tiles-media { width: 140px; }
.core-tiles-round.core-tiles-media .core-tile > img, .core-tiles-round.core-tiles-media .core-tile > .core-icon { width: 68px; height: 68px; border-radius: 50%; }
.core-tiles-round.core-tiles-media .core-tile > .core-icon { padding: 20px; background: var(--core-surface-2); }
.core-tiles-round.core-tiles-media .core-tile-label { text-align: center; }
.core-tiles-round.core-tiles-media .core-tile-count { position: absolute; top: 8px; right: calc(50% - 46px); margin: 0; }
.core-tiles-pill .core-tile { border-radius: var(--core-radius-pill); }
.core-tiles-pill .core-tile.is-active { box-shadow: inset 0 0 0 2px var(--core-accent); }
.core-tiles-pill:not(.core-tiles-media) .core-tile { flex-direction: row; justify-content: flex-start; gap: 10px; padding: 10px 12px 10px 14px; }
.core-tiles-pill:not(.core-tiles-media) .core-tile-count { position: static; margin-left: auto; }
.core-tiles-pill:not(.core-tiles-media) { width: 196px; }
.core-tiles-pill:not(.core-tiles-media) .core-tile-label { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-transform: none; letter-spacing: 0; font-size: var(--core-fs-sm); line-height: 1.25; }
.core-tiles-pill.core-tiles-media .core-tile { padding: 6px 12px 6px 6px; }
.core-tiles-pill.core-tiles-media .core-tile > img, .core-tiles-pill.core-tiles-media .core-tile > .core-icon { width: 40px; height: 40px; border-radius: 50%; }
.core-tiles-pill.core-tiles-media .core-tile > .core-icon { padding: 10px; }
.core-tiles-plain { background: transparent; border-color: transparent; padding-left: 0; padding-right: 0; }
.core-tiles-plain .core-tile { border-color: transparent; background: transparent; box-shadow: none; }
.core-tiles-plain .core-tile.is-active { background: var(--core-accent-soft); box-shadow: none; }
.core-tiles-plain .core-tile:hover:not(.is-active) { background: var(--core-hover); }
.core-tiles-plain.core-tiles-round .core-tile.is-active { background: transparent; }
.core-tiles-plain.core-tiles-round .core-tile.is-active > img, .core-tiles-plain.core-tiles-round .core-tile.is-active > .core-icon { box-shadow: 0 0 0 3px var(--core-surface), 0 0 0 5px var(--core-accent); }
@media (min-width: 769px) {
    .core-main:has(> .core-content > .core-till) { height: 100vh; height: 100dvh; }   /* a till is one screen: the page does not grow, the catalog and the receipt scroll (the receipt's buttons stay in view) */
    .core-content:has(> .core-till) { min-height: 0; overflow-y: auto; }
}
@media (max-width: 1100px) {
    .core-till { grid-template-areas: "top top" "nav side" "main side"; grid-template-columns: minmax(0, 1fr) 340px; grid-template-rows: auto auto minmax(0, 1fr); }
    .core-till-nav.core-tiles { flex-direction: row; width: auto; overflow-x: auto; }
    .core-till-nav .core-tile { flex: 1; min-width: 0; padding: 10px 6px; }
}
@media (max-width: 768px) {
    .core-content:has(> .core-till) { display: block; }
    .core-till { grid-template-areas: "top" "nav" "main" "side"; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto; }
    .core-till-main { height: 420px; }
    .core-till-side { min-height: 480px; }
}
/* a PIN entry: four dots and a keypad of large keys (a till, a shared screen) */
.core-pin-dots { display: flex; justify-content: center; gap: var(--core-sp-3); }
.core-pin-dot { width: 14px; height: 14px; border-radius: 50%; border: 1.5px solid var(--core-border-stronger); transition: background var(--core-ease), border-color var(--core-ease); }
.core-pin-dot.is-filled { background: var(--core-text); border-color: var(--core-text); }
.core-pin-dots.is-error .core-pin-dot { border-color: var(--core-danger); background: var(--core-danger-bg); }
.core-keypad { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--core-sp-2); }
.core-keypad > .core-btn { height: 52px; font-size: var(--core-fs-xl); font-variant-numeric: tabular-nums; }
/* a document shown inside a dialog (a receipt to print) */
.core-dialog-body > iframe { display: block; width: 100%; height: 60vh; border: 0; }
/* the panel of a linked service inside a page (CoreUi::linkFrame, docs/INTEGRATION.md "The kit"): it IS the page — the
   content area loses its margins, the frame fills it edge to edge below the top bar, without border or background; the
   framed page (is-bare, the host's theme) brings its own margins, so its title and cards fall where the host's own
   pages put them, and its one scroll bar sits at the window's edge. A message of the host page (before the frame) keeps
   the page margins. */
.core-content:has(> .core-link-frame) { display: flex; flex-direction: column; height: calc(100vh - var(--core-topbar-h)); max-width: none; padding: 0; }
:root[data-topbar="primary"] .core-content:has(> .core-link-frame) { height: 100vh; padding: var(--core-topbar-h) 0 0; }
.core-content:has(> .core-link-frame) > :not(.core-link-frame, .core-dialog-overlay, .core-scrim, .core-viewer, script, style, template, link, [hidden]) { margin: var(--core-page-py) var(--core-page-px) 0; max-width: calc(var(--core-page-max) - 2 * var(--core-page-px)); }
.core-content > .core-link-frame { flex: 1 1 auto; min-height: 480px; margin-top: 0; }
.core-link-frame > iframe { display: block; width: 100%; height: 100%; border: 0; background: transparent; }
/* a multi-pick of a few short values (weekdays, tags): .core-chips > label.core-chip with a hidden checkbox */
.core-chips { display: flex; flex-wrap: wrap; gap: var(--core-sp-2); }
.core-chip { position: relative; }
.core-chip input { position: absolute; opacity: 0; width: 0; height: 0; }
.core-chip:has(input:checked) { background: var(--core-chip-on-bg); border-color: var(--core-chip-on-border); color: var(--core-chip-on-text); }
.core-chip:has(input:focus-visible) { box-shadow: 0 0 0 var(--core-focus-w) var(--core-focus); }
.core-chip:has(input:disabled) { cursor: default; opacity: 0.7; }
/* chips that keep one line (17 November 2026): .core-chips.core-chips-fit[data-core-chips-fit]; what does not fit goes into
   the menu of its last chip "Other n" (CoreUi::chipsMore, filled by ui.js); a chosen chip always stays in view */
.core-chips-fit { flex-wrap: nowrap; overflow: hidden; }
.core-chips-fit > .core-chip, .core-chips-fit > .core-chips-more { flex: none; }
.core-chips-fit > [hidden] { display: none; }
.core-chips-more > .core-chip { cursor: pointer; font: inherit; font-size: var(--core-fs-sm); font-weight: 500; }
.core-chips-more .core-menu { max-height: 320px; overflow-y: auto; }
.core-chip-n { color: var(--core-text-3); font-variant-numeric: tabular-nums; }
.core-chip.is-on .core-chip-n, .core-chip:has(input:checked) .core-chip-n { color: inherit; opacity: 0.7; }
.core-menu-item .core-chip-n { margin-left: auto; }
.core-menu-item.is-on { color: var(--core-accent-text); font-weight: 600; }

.core-avatar { width: 30px; height: 30px; border-radius: 50%; background: var(--core-avatar-bg); color: var(--core-avatar-text); display: inline-flex; align-items: center; justify-content: center; font-size: var(--core-fs-xs); font-weight: 600; letter-spacing: 0.02em; flex-shrink: 0; overflow: hidden; }
.core-avatar img { width: 100%; height: 100%; object-fit: cover; }
.core-avatar-sm { width: 26px; height: 26px; font-size: 0.62rem; }
.core-avatar-lg { width: 44px; height: 44px; font-size: var(--core-fs-md); }
.core-avatar-accent { background: var(--core-accent-soft); color: var(--core-accent-text); }
.core-avatar-group { display: inline-flex; }
.core-avatar-group .core-avatar { box-shadow: 0 0 0 2px var(--core-surface); margin-left: -8px; }
.core-avatar-group .core-avatar:first-child { margin-left: 0; }

/* steps: the progress of a wizard or an installer, as pills: ol.core-steps > li (is-done / is-current) */
.core-steps { list-style: none; margin: 0 0 var(--core-sp-5); padding: 0; display: flex; flex-wrap: wrap; gap: 6px; font-size: var(--core-fs-xs); }
.core-steps li { height: 26px; display: inline-flex; align-items: center; gap: 6px; padding: 0 10px; border-radius: var(--core-radius-pill); background: var(--core-surface-2); color: var(--core-text-2); font-weight: 500; }
.core-steps li.is-current { background: var(--core-accent); color: var(--core-on-accent); font-weight: 600; }
.core-steps li.is-done { background: var(--core-accent-soft); color: var(--core-accent-text); }
.core-steps li .core-icon { width: 14px; height: 14px; }

/* choice cards: pick one of a few (a language, a country, a template) — .core-choices > label.core-choice with a hidden radio, or button.core-choice + is-selected */
.core-choices { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: var(--core-sp-2); }
.core-choice { position: relative; border: 1px solid var(--core-border-strong); border-radius: var(--core-ctl-radius); padding: 10px 8px; text-align: center; cursor: pointer; background: var(--core-surface); font: inherit; font-size: var(--core-fs-sm); font-weight: 500; color: var(--core-text); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; min-height: 36px; transition: border-color var(--core-ease), background var(--core-ease); }
.core-choice input { position: absolute; opacity: 0; width: 0; height: 0; }
.core-choice:hover { border-color: var(--core-text-2); }
.core-choice:disabled { cursor: default; opacity: 0.6; }   /* a template already loaded, a choice not open */
.core-choice.is-selected, .core-choice:has(input:checked) { border-color: var(--core-accent); background: var(--core-accent-soft); color: var(--core-accent-text); box-shadow: inset 0 0 0 1px var(--core-accent); }
.core-choice-sub { font-size: var(--core-fs-xs); color: var(--core-text-3); font-weight: 400; }
.core-choice-glyph { font-size: 1.25rem; line-height: 1; }   /* a flag or an emoji above the label */
.core-choice:not(.core-choice-row) { height: 80px; overflow: hidden; }   /* the tiles of a grid are all one height: an icon or a flag and up to two lines */
.core-choice:not(.core-choice-row) > span:last-child:not(.core-choice-icon):not(.core-choice-glyph) { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.core-choice-row { flex-direction: row; justify-content: flex-start; text-align: left; gap: var(--core-sp-3); padding: 10px 12px; }   /* an icon and two lines, as a list */
.core-choice-icon { display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; color: var(--core-text-2); }   /* a plain icon: a coloured square is for stat tiles only */
.core-choice.is-selected .core-choice-icon, .core-choice:has(input:checked) .core-choice-icon { color: inherit; }
.core-choices-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
/* item tiles with a picture (a till whose catalog has photos): the picture, then the name and the price; a tile without a
   picture keeps the place (.core-choice-ph); .core-choice-opt marks an item that asks for options */
.core-choices.core-choices-media { grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: 12px; }
.core-choices-media > .core-choice-media:not(.core-choice-row) { height: auto; padding: 0; overflow: hidden; align-items: stretch; justify-content: flex-start; gap: 0; text-align: left; border-color: var(--core-border); box-shadow: var(--core-shadow-sm); }
.core-choices-media > .core-choice-media:not(.core-choice-row) > span.core-choice-text:last-child:not(.core-choice-icon):not(.core-choice-glyph) { display: flex; }
.core-choice-media > img, .core-choice-media > .core-choice-ph { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; background: var(--core-surface-2); }
.core-choice-text { display: flex; align-items: baseline; gap: 8px; padding: 10px 12px 12px; }
.core-choice-name { min-width: 0; font-weight: 500; line-height: 1.3; }
.core-choice-name > .core-choice-sub { display: block; margin-top: 2px; }
.core-choice-price { margin-left: auto; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.core-choice-opt { position: absolute; top: 8px; right: 8px; display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; border-radius: var(--core-radius-pill); background: var(--core-surface); color: var(--core-text-2); box-shadow: var(--core-shadow-sm); }
.core-choice-opt .core-icon { width: 15px; height: 15px; }
.core-choice-sub .core-icon { width: 12px; height: 12px; vertical-align: -2px; }   /* the options mark of a text tile, after its price */
/* the keys of a till laid out by hand (a till editor): a grid of keys at their place — grid-column / grid-row set on each
   key (column, span). .core-keys-box around it lets square and round keys take the width of a column as their height.
   Shape: core-keys (rectangles) | core-keys-square | core-keys-round. Height of a rectangle: core-keys-s / -m / -l / -xl.
   A key: core-key with a picture (core-key-media: img or an empty span) and core-key-text (core-key-name, core-key-price);
   is-photo = the picture fills the key, the text on a frosted band of the surface; is-color = a colour key: --core-key-c (background) and
   --core-key-on (its text) set by the page, a palette tone with core-key-pal-1…8; core-key-slot = an empty place (editor). */
.core-keys-box { container-type: inline-size; }
.core-keys { --core-keys-cols: 5; --core-keys-gap: 10px; --core-key-h: 112px; display: grid; grid-template-columns: repeat(var(--core-keys-cols), minmax(0, 1fr)); grid-auto-rows: var(--core-key-h); gap: var(--core-keys-gap); }
.core-keys-s { --core-key-h: 76px; }
.core-keys-m { --core-key-h: 112px; }
.core-keys-l { --core-key-h: 148px; }
.core-keys-xl { --core-key-h: 188px; }
.core-keys-f { height: 100%; grid-template-rows: repeat(var(--core-keys-rows, 4), minmax(0, 1fr)); grid-auto-rows: minmax(0, 1fr); }   /* fill: the rows share the height of the box, the same on every page */
.core-keys-square { --core-key-h: calc((100cqw - (var(--core-keys-cols) - 1) * var(--core-keys-gap)) / var(--core-keys-cols)); }
.core-keys-round { grid-auto-rows: auto; row-gap: 16px; }
.core-key { position: relative; display: flex; flex-direction: column; justify-content: flex-end; min-width: 0; min-height: 0; padding: 0; border: 1px solid var(--core-border); border-radius: var(--core-ctl-radius); background: var(--core-surface); color: var(--core-text); font: inherit; text-align: left; overflow: hidden; cursor: pointer; box-shadow: var(--core-shadow-sm); transition: transform .08s var(--core-ease), box-shadow .12s var(--core-ease); }
.core-key:active { transform: scale(.97); }
.core-key:focus-visible { outline: var(--core-focus-w) solid var(--core-focus); outline-offset: 2px; }
.core-key.is-sel { box-shadow: 0 0 0 2px var(--core-surface), 0 0 0 4px var(--core-accent); }
.core-key-media { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; background: var(--core-surface-2); }
.core-key-text { position: relative; display: flex; flex-wrap: wrap; align-items: baseline; column-gap: 8px; row-gap: 2px; padding: 8px 10px; font-size: var(--core-fs-sm); line-height: 1.25; }
.core-key-name { flex: 1 1 auto; min-width: 0; font-weight: 600; overflow: hidden; overflow-wrap: normal; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.core-key-name.is-fit-1 { font-size: .88em; } .core-key-name.is-fit-2 { font-size: .76em; } .core-key-name.is-fit-3 { font-size: .76em; overflow-wrap: anywhere; }
.core-key-price { margin-left: auto; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; opacity: .9; }
.core-key.is-photo { border-color: transparent; }
.core-key.is-photo .core-key-text { margin: 6px; border-radius: calc(var(--core-ctl-radius) - 2px); background: color-mix(in srgb, var(--core-surface) 90%, transparent); backdrop-filter: blur(6px); }
.core-key.is-color { border-color: transparent; background: var(--core-key-c, var(--core-surface-2)); color: var(--core-key-on, var(--core-text)); justify-content: space-between; }
.core-key.is-color .core-key-text { flex-direction: column; flex-wrap: nowrap; align-items: flex-start; justify-content: space-between; height: 100%; gap: 4px; padding: 10px 12px; font-size: var(--core-fs-md); }
.core-key.is-color:has(> .core-choice-opt) .core-key-name { padding-right: 24px; }
.core-key.is-color .core-key-price { margin-left: 0; font-size: var(--core-fs-sm); }
.core-keys-s .core-key.is-color .core-key-text { font-size: var(--core-fs-sm); padding: 8px 10px; }
.core-key-pal-1 { --core-key-c: var(--core-pal-1-soft); --core-key-on: var(--core-pal-1-text); } .core-key-pal-2 { --core-key-c: var(--core-pal-2-soft); --core-key-on: var(--core-pal-2-text); }
.core-key-pal-3 { --core-key-c: var(--core-pal-3-soft); --core-key-on: var(--core-pal-3-text); } .core-key-pal-4 { --core-key-c: var(--core-pal-4-soft); --core-key-on: var(--core-pal-4-text); }
.core-key-pal-5 { --core-key-c: var(--core-pal-5-soft); --core-key-on: var(--core-pal-5-text); } .core-key-pal-6 { --core-key-c: var(--core-pal-6-soft); --core-key-on: var(--core-pal-6-text); }
.core-key-pal-7 { --core-key-c: var(--core-pal-7-soft); --core-key-on: var(--core-pal-7-text); } .core-key-pal-8 { --core-key-c: var(--core-pal-8-soft); --core-key-on: var(--core-pal-8-text); }
/* the palettes of the keys (themes/keys.json): ten tones. Without a palette the theme's own (1–8 its data palette, 9 and 10
   the generator's); on the keys' container (or any ancestor) core-keys-pal-vivid / -earth / -deep / -neutral. The theme
   file of the app holds the colours (--core-key-<palette>-<n>, -on its text), light and dark. The name of a key that
   does not fit gets smaller (is-fit-1, -2; -3 breaks the word): the page measures it. */
.core-key-pal-9 { --core-key-c: var(--core-key-theme-9); --core-key-on: var(--core-key-theme-9-on); } .core-key-pal-10 { --core-key-c: var(--core-key-theme-10); --core-key-on: var(--core-key-theme-10-on); }
.core-keys-pal-vivid .core-key-pal-1 { --core-key-c: var(--core-key-vivid-1); --core-key-on: var(--core-key-vivid-1-on); } .core-keys-pal-vivid .core-key-pal-2 { --core-key-c: var(--core-key-vivid-2); --core-key-on: var(--core-key-vivid-2-on); }
.core-keys-pal-vivid .core-key-pal-3 { --core-key-c: var(--core-key-vivid-3); --core-key-on: var(--core-key-vivid-3-on); } .core-keys-pal-vivid .core-key-pal-4 { --core-key-c: var(--core-key-vivid-4); --core-key-on: var(--core-key-vivid-4-on); }
.core-keys-pal-vivid .core-key-pal-5 { --core-key-c: var(--core-key-vivid-5); --core-key-on: var(--core-key-vivid-5-on); } .core-keys-pal-vivid .core-key-pal-6 { --core-key-c: var(--core-key-vivid-6); --core-key-on: var(--core-key-vivid-6-on); }
.core-keys-pal-vivid .core-key-pal-7 { --core-key-c: var(--core-key-vivid-7); --core-key-on: var(--core-key-vivid-7-on); } .core-keys-pal-vivid .core-key-pal-8 { --core-key-c: var(--core-key-vivid-8); --core-key-on: var(--core-key-vivid-8-on); }
.core-keys-pal-vivid .core-key-pal-9 { --core-key-c: var(--core-key-vivid-9); --core-key-on: var(--core-key-vivid-9-on); } .core-keys-pal-vivid .core-key-pal-10 { --core-key-c: var(--core-key-vivid-10); --core-key-on: var(--core-key-vivid-10-on); }
.core-keys-pal-earth .core-key-pal-1 { --core-key-c: var(--core-key-earth-1); --core-key-on: var(--core-key-earth-1-on); } .core-keys-pal-earth .core-key-pal-2 { --core-key-c: var(--core-key-earth-2); --core-key-on: var(--core-key-earth-2-on); }
.core-keys-pal-earth .core-key-pal-3 { --core-key-c: var(--core-key-earth-3); --core-key-on: var(--core-key-earth-3-on); } .core-keys-pal-earth .core-key-pal-4 { --core-key-c: var(--core-key-earth-4); --core-key-on: var(--core-key-earth-4-on); }
.core-keys-pal-earth .core-key-pal-5 { --core-key-c: var(--core-key-earth-5); --core-key-on: var(--core-key-earth-5-on); } .core-keys-pal-earth .core-key-pal-6 { --core-key-c: var(--core-key-earth-6); --core-key-on: var(--core-key-earth-6-on); }
.core-keys-pal-earth .core-key-pal-7 { --core-key-c: var(--core-key-earth-7); --core-key-on: var(--core-key-earth-7-on); } .core-keys-pal-earth .core-key-pal-8 { --core-key-c: var(--core-key-earth-8); --core-key-on: var(--core-key-earth-8-on); }
.core-keys-pal-earth .core-key-pal-9 { --core-key-c: var(--core-key-earth-9); --core-key-on: var(--core-key-earth-9-on); } .core-keys-pal-earth .core-key-pal-10 { --core-key-c: var(--core-key-earth-10); --core-key-on: var(--core-key-earth-10-on); }
.core-keys-pal-deep .core-key-pal-1 { --core-key-c: var(--core-key-deep-1); --core-key-on: var(--core-key-deep-1-on); } .core-keys-pal-deep .core-key-pal-2 { --core-key-c: var(--core-key-deep-2); --core-key-on: var(--core-key-deep-2-on); }
.core-keys-pal-deep .core-key-pal-3 { --core-key-c: var(--core-key-deep-3); --core-key-on: var(--core-key-deep-3-on); } .core-keys-pal-deep .core-key-pal-4 { --core-key-c: var(--core-key-deep-4); --core-key-on: var(--core-key-deep-4-on); }
.core-keys-pal-deep .core-key-pal-5 { --core-key-c: var(--core-key-deep-5); --core-key-on: var(--core-key-deep-5-on); } .core-keys-pal-deep .core-key-pal-6 { --core-key-c: var(--core-key-deep-6); --core-key-on: var(--core-key-deep-6-on); }
.core-keys-pal-deep .core-key-pal-7 { --core-key-c: var(--core-key-deep-7); --core-key-on: var(--core-key-deep-7-on); } .core-keys-pal-deep .core-key-pal-8 { --core-key-c: var(--core-key-deep-8); --core-key-on: var(--core-key-deep-8-on); }
.core-keys-pal-deep .core-key-pal-9 { --core-key-c: var(--core-key-deep-9); --core-key-on: var(--core-key-deep-9-on); } .core-keys-pal-deep .core-key-pal-10 { --core-key-c: var(--core-key-deep-10); --core-key-on: var(--core-key-deep-10-on); }
.core-keys-pal-neutral .core-key-pal-1 { --core-key-c: var(--core-key-neutral-1); --core-key-on: var(--core-key-neutral-1-on); } .core-keys-pal-neutral .core-key-pal-2 { --core-key-c: var(--core-key-neutral-2); --core-key-on: var(--core-key-neutral-2-on); }
.core-keys-pal-neutral .core-key-pal-3 { --core-key-c: var(--core-key-neutral-3); --core-key-on: var(--core-key-neutral-3-on); } .core-keys-pal-neutral .core-key-pal-4 { --core-key-c: var(--core-key-neutral-4); --core-key-on: var(--core-key-neutral-4-on); }
.core-keys-pal-neutral .core-key-pal-5 { --core-key-c: var(--core-key-neutral-5); --core-key-on: var(--core-key-neutral-5-on); } .core-keys-pal-neutral .core-key-pal-6 { --core-key-c: var(--core-key-neutral-6); --core-key-on: var(--core-key-neutral-6-on); }
.core-keys-pal-neutral .core-key-pal-7 { --core-key-c: var(--core-key-neutral-7); --core-key-on: var(--core-key-neutral-7-on); } .core-keys-pal-neutral .core-key-pal-8 { --core-key-c: var(--core-key-neutral-8); --core-key-on: var(--core-key-neutral-8-on); }
.core-keys-pal-neutral .core-key-pal-9 { --core-key-c: var(--core-key-neutral-9); --core-key-on: var(--core-key-neutral-9-on); } .core-keys-pal-neutral .core-key-pal-10 { --core-key-c: var(--core-key-neutral-10); --core-key-on: var(--core-key-neutral-10-on); }
.core-keys-round .core-key { align-items: center; justify-content: flex-start; gap: 6px; padding: 0; border: 0; border-radius: 0; background: none; box-shadow: none; overflow: visible; color: var(--core-text); text-align: center; }
.core-keys-round .core-key-media { position: relative; inset: auto; width: min(100%, 132px); height: auto; aspect-ratio: 1; border-radius: 50%; border: 3px solid var(--core-surface); box-shadow: 0 0 0 1px var(--core-border), var(--core-shadow-sm); }
.core-keys-round .core-key.is-color .core-key-media { background: var(--core-key-c, var(--core-surface-2)); }
.core-keys-round .core-key.is-sel { box-shadow: none; }
.core-keys-round .core-key.is-sel .core-key-media { box-shadow: 0 0 0 3px var(--core-accent); }
.core-keys-round .core-key-text, .core-keys-round .core-key.is-color .core-key-text, .core-keys-round .core-key.is-photo .core-key-text { flex-direction: column; flex-wrap: nowrap; align-items: center; gap: 2px; height: auto; margin: 0; padding: 0 4px; background: none; backdrop-filter: none; font-size: var(--core-fs-sm); color: var(--core-text); }
.core-keys-round .core-key > .core-choice-opt { right: max(2px, calc(50% - 64px)); }
.core-keys-round .core-key-price { margin-left: 0; color: var(--core-text-2); }
.core-key > .core-choice-opt { z-index: 1; }
.core-key-slot { display: flex; align-items: center; justify-content: center; border: 1.5px dashed var(--core-border-strong); border-radius: var(--core-ctl-radius); background: transparent; color: var(--core-text-3); font: inherit; cursor: pointer; }
.core-key-slot:hover, .core-key-slot.is-over { border-color: var(--core-accent); color: var(--core-accent-text); background: var(--core-accent-soft); }
.core-keys-round .core-key-slot { border-radius: 50%; aspect-ratio: 1; width: min(100%, 132px); justify-self: center; }
/* core-keys-plain = keys without a border (a key without a picture or a colour stands on the second surface).
   The kinds of key: is-group = a key that opens a group of keys (core-key-mark: the folder mark, top left; a colour key
   gets a folded corner), is-action = a key that does something (a discount, a function: core-key-glyph, the big icon;
   core-key-sub, a line under the name; core-key-accent, the colour of the theme's accent). core-keys-path = the way
   back over the keys of an open group (a back button, then Group › Sub-group). */
.core-keys-plain .core-key { box-shadow: none; }
.core-keys-plain .core-key:not(.is-photo):not(.is-color) { border-color: transparent; background: var(--core-surface-2); }
.core-keys-plain.core-keys-round .core-key-media { border: 0; box-shadow: none; }
.core-key-mark { position: absolute; top: 8px; left: 8px; z-index: 1; display: inline-flex; align-items: center; gap: 4px; height: 24px; padding: 0 8px; border-radius: var(--core-radius-pill); background: var(--core-surface); color: var(--core-text-2); font-size: var(--core-fs-2xs); font-weight: 700; letter-spacing: .04em; text-transform: uppercase; box-shadow: var(--core-shadow-sm); }
.core-key-mark .core-icon { width: 14px; height: 14px; }
.core-keys-round .core-key-mark { left: auto; right: max(2px, calc(50% - 64px)); top: 4px; padding: 0 6px; }
.core-keys-round .core-key-mark span { display: none; }
.core-key.is-group.is-color::after { content: ""; position: absolute; right: 0; bottom: 0; width: 26px; height: 26px; background: linear-gradient(135deg, transparent 50%, color-mix(in srgb, var(--core-key-on, var(--core-text)) 22%, transparent) 50%); }
.core-keys-round .core-key.is-group.is-color::after { content: none; }
.core-key-glyph { display: inline-flex; width: 30px; height: 30px; }
.core-key-glyph .core-icon { width: 30px; height: 30px; }
.core-keys-s .core-key-glyph, .core-keys-s .core-key-glyph .core-icon { width: 20px; height: 20px; }
.core-keys-s .core-key-sub { display: none; }
.core-key.is-action .core-key-text { justify-content: space-between; }
.core-key-accent { --core-key-c: var(--core-accent); --core-key-on: var(--core-on-accent); }
.core-key-sub { font-size: var(--core-fs-xs); font-weight: 500; opacity: .85; }
.core-keys-round .core-key.is-action .core-key-media { display: grid; place-items: center; background: var(--core-key-c, var(--core-surface-2)); color: var(--core-key-on, var(--core-text)); }
.core-keys-round .core-key.is-action .core-key-media .core-icon { width: 44px; height: 44px; }
.core-keys-path { display: flex; align-items: center; gap: 8px; margin: -4px 0 12px; font-size: var(--core-fs-sm); color: var(--core-text-2); }
.core-keys-path b { color: var(--core-text); }
.core-keys-path .core-icon { width: 14px; height: 14px; }
/* a device frame around a page in an iframe (a preview of a screen from the back office): the page runs at the device's
   own size (--core-device-w / --core-device-h, px) and is scaled by --core-device-scale. Kind: core-device-kiosk (a
   standing totem), -tablet, -phone, -tv (a stand under it). core-device-stage centres it on a soft ground. */
.core-device-stage { display: flex; align-items: flex-start; justify-content: center; padding: var(--core-sp-8) var(--core-sp-4); border-radius: var(--core-card-radius); background: var(--core-surface-2); overflow: auto; }
.core-device { --core-device-w: 1280px; --core-device-h: 800px; --core-device-scale: .5; --core-device-bezel: 14px; position: relative; flex: none; box-sizing: content-box; width: calc(var(--core-device-w) * var(--core-device-scale)); height: calc(var(--core-device-h) * var(--core-device-scale)); padding: var(--core-device-bezel); border-radius: calc(var(--core-device-bezel) + 10px); background: color-mix(in srgb, var(--core-text) 86%, var(--core-bg)); box-shadow: 0 0 0 1px var(--core-border-strong), var(--core-shadow-md); }
.core-device-screen { position: relative; width: 100%; height: 100%; overflow: hidden; border-radius: 8px; background: var(--core-bg); }
.core-device-screen > iframe { position: absolute; top: 0; left: 0; width: var(--core-device-w); height: var(--core-device-h); border: 0; transform: scale(var(--core-device-scale)); transform-origin: 0 0; background: var(--core-bg); }
.core-device-phone { --core-device-bezel: 10px; border-radius: 34px; }
.core-device-phone .core-device-screen { border-radius: 24px; }
.core-device-kiosk { --core-device-bezel: 18px; border-radius: 22px; margin-bottom: 64px; }
.core-device-kiosk::after { content: ""; position: absolute; left: 50%; bottom: -64px; width: 34%; height: 64px; transform: translateX(-50%); border-radius: 0 0 10px 10px; background: linear-gradient(color-mix(in srgb, var(--core-text) 70%, var(--core-bg)), var(--core-border-stronger)); }
.core-device-tv { --core-device-bezel: 8px; border-radius: 10px; margin-bottom: 40px; }
.core-device-tv .core-device-screen { border-radius: 2px; }
.core-device-tv::after { content: ""; position: absolute; left: 50%; bottom: -40px; width: 22%; height: 40px; transform: translateX(-50%); clip-path: polygon(38% 0, 62% 0, 100% 100%, 0 100%); background: var(--core-border-stronger); }


/* ------------------------------------------------------------ tables */
.core-table-wrap { overflow-x: auto; }
.core-table { width: 100%; font-size: var(--core-fs-sm); }
.core-table th { height: 36px; padding: 0 var(--core-sp-4); text-align: left; font-size: var(--core-fs-xs); font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; color: var(--core-text-3); background: var(--core-table-head-bg); border-bottom: 1px solid var(--core-border); white-space: nowrap; }
.core-table td { height: var(--core-table-row-h); padding: 0 var(--core-sp-4); border-bottom: 1px solid var(--core-border-subtle); vertical-align: middle; }
.core-table tbody tr:last-child td { border-bottom: 0; }
.core-table tbody tr { transition: background var(--core-ease); }
.core-table tbody tr:hover td { background: var(--core-hover); }
.core-table tbody tr.is-selected td { background: var(--core-selected); }
.core-table .core-td-num, .core-table .core-th-num { text-align: right; font-variant-numeric: tabular-nums; }
.core-table .core-td-actions, .core-table .core-th-actions { text-align: right; width: 1%; white-space: nowrap; }
/* the actions of a row are always visible (2 November 2026): the main one and "⋯" with the rest (CoreUi::rowActions) */
.core-row-actions { display: inline-flex; align-items: center; justify-content: flex-end; gap: 2px; }
.core-table .core-td-actions .core-btn-icon { color: var(--core-text-3); }
.core-table tr:hover .core-td-actions .core-btn-icon, .core-table .core-td-actions .core-btn-icon:focus-visible { color: var(--core-text); }
.core-row-actions .core-btn-icon.is-danger:hover { color: var(--core-danger); }
/* one line per cell (UI.md rule 10): a long text is cut with "…"; the record cell has two — the name, one grey line under it */
.core-table td { white-space: nowrap; }
.core-table .core-td-wrap { white-space: normal; }          /* the rare cell that must wrap (a note in a small detail table) */
.core-table .core-td-wrap .core-cell-sub { white-space: normal; }   /* … and the grey line under its title wraps with it (the sentence under a right, in the grid of a role) */
.core-table .core-td-main { min-width: 160px; max-width: 340px; }
.core-td-main .core-cell-primary, .core-td-main .core-cell-sub { display: block; overflow: hidden; text-overflow: ellipsis; }
.core-table .core-td-text { max-width: 240px; overflow: hidden; text-overflow: ellipsis; }
.core-count { border-bottom: 1px dotted var(--core-border-stronger); cursor: default; }   /* "3 operators": the names on hover */
.core-table tbody tr[data-core-row] { cursor: pointer; }    /* a click on the row opens the record */
.core-table tr.core-tr-group td { height: auto; padding-top: 6px; padding-bottom: 6px; background: var(--core-surface-2); font-size: var(--core-fs-xs); font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; color: var(--core-text-2); }   /* a group title inside a table (CoreUi::groupRow): no icon, no columns */
.core-table tfoot td { height: 36px; font-weight: 600; background: var(--core-surface-2); border-top: 1px solid var(--core-border); border-bottom: 0; }   /* the totals row of a table */
.core-table tfoot tr + tr td { border-top-color: var(--core-border-subtle); }
.core-table tfoot tr.core-tr-sub td { height: 30px; font-weight: 400; color: var(--core-text-2); }   /* the lines that lead to a total (subtotal, discount, tax) */
.core-table tr.is-inactive td:not(.core-td-actions) { color: var(--core-text-3); }   /* a record switched off: its text greys, its badge says it */
.core-table tr.is-inactive .core-cell-primary { color: var(--core-text-2); }
.core-col-hidden { display: none !important; }               /* a column the table had no room for (data-core-priority) */
.core-table .core-td-check, .core-table .core-th-check { width: 1%; padding-right: 0; }
.core-table-compact td { height: 40px; }
/* a table of fields: many rows typed at once (14 November 2026, Securities' grid of movements). The cells sit closer and
   their field fills them; a column takes the width its th asks (core-th-w-xs … -lg), the one without takes the rest */
.core-table-fields th, .core-table-fields td { padding: 0 var(--core-sp-1); }
.core-table-fields td > .core-input, .core-table-fields td > .core-select { width: 100%; min-width: 0; }
.core-table .core-th-w-xs { width: 2.5rem; } .core-table .core-th-w-sm { width: 6rem; } .core-table .core-th-w-md { width: 7.5rem; } .core-table .core-th-w-lg { width: 9.5rem; }
.core-table-card { border: 1px solid var(--core-card-border); border-radius: var(--core-card-radius); overflow: hidden; background: var(--core-surface); box-shadow: var(--core-card-shadow); }
.core-table-card .core-table th:first-child, .core-table-card .core-table td:first-child { padding-left: var(--core-card-pad); }
.core-table-card .core-table th:last-child, .core-table-card .core-table td:last-child { padding-right: var(--core-card-pad); }
/* a table edge to edge in a card body: its first and last columns line up with the card head */
.core-card-body:has(> .core-table-wrap:only-child, > .core-table:only-child) .core-table :is(th, td):first-child { padding-left: var(--core-card-pad); }
.core-card-body:has(> .core-table-wrap:only-child, > .core-table:only-child) .core-table :is(th, td):last-child { padding-right: var(--core-card-pad); }
.core-cell-primary { font-weight: 600; color: var(--core-text); white-space: nowrap; }
.core-cell-sub { display: block; font-size: var(--core-fs-xs); color: var(--core-text-3); margin-top: 1px; white-space: nowrap; }
.core-cell-user { display: flex; align-items: center; gap: 10px; }
.core-th-sort { display: inline-flex; align-items: center; gap: 4px; cursor: pointer; }
.core-th-sort .core-icon { width: 12px; height: 12px; opacity: 0.5; }
.core-th-sort.is-active { color: var(--core-text); }
.core-th-sort.is-active .core-icon { opacity: 1; }

.core-toolbar { display: flex; align-items: center; gap: var(--core-sp-2); flex-wrap: wrap; padding: var(--core-sp-3) var(--core-card-pad); border-bottom: 1px solid var(--core-border); }
.core-toolbar .core-search { width: 260px; }
.core-pagination { display: flex; align-items: center; gap: var(--core-sp-3); padding: var(--core-sp-3) var(--core-card-pad); border-top: 1px solid var(--core-border); font-size: var(--core-fs-sm); color: var(--core-text-2); margin-top: auto; }
.core-pages { display: inline-flex; gap: 2px; }
.core-page-btn { min-width: 30px; height: 30px; padding: 0 8px; border-radius: var(--core-radius-md); border: 0; background: transparent; color: var(--core-text-2); font-size: var(--core-fs-sm); font-weight: 500; display: inline-flex; align-items: center; justify-content: center; }
.core-page-btn:hover { background: var(--core-hover); color: var(--core-text); }
.core-page-btn.is-active { background: var(--core-page-active-bg); color: var(--core-page-active-text); }
.core-page-btn:disabled { opacity: 0.4; pointer-events: none; }

/* ------------------------------------------------------------ tabs, segments, menus */
.core-tabs { display: flex; gap: var(--core-sp-1); border-bottom: 1px solid var(--core-border); margin-bottom: var(--core-sp-4); overflow-x: auto; scrollbar-width: none; }   /* a label never breaks: more tabs than room scroll sideways */
.core-tab { display: inline-flex; flex: none; white-space: nowrap; align-items: center; gap: 7px; height: 38px; padding: 0 var(--core-sp-3); margin-bottom: -1px; border: 0; border-bottom: 2px solid transparent; background: none; color: var(--core-text-2); font-size: var(--core-fs-ctl); font-weight: 500; cursor: pointer; text-decoration: none; transition: color var(--core-ease), border-color var(--core-ease); }
.core-tab:hover { color: var(--core-text); text-decoration: none; }
.core-tab.is-active { color: var(--core-text); border-bottom-color: var(--core-accent); font-weight: 600; }
.core-tab .core-icon { color: var(--core-text-3); }
.core-tab.is-active .core-icon { color: var(--core-accent); }
.core-tab .core-badge { height: 18px; padding: 0 6px; }

.core-seg { display: inline-flex; padding: 3px; background: var(--core-seg-bg); border: 1px solid var(--core-seg-border); border-radius: var(--core-radius-md); gap: 2px; }
.core-seg-btn { height: calc(var(--core-ctl-h) - 8px);   /* the whole segmented control is one control height: 3 + 3 padding + 2 border */
     padding: 0 11px; border: 0; border-radius: calc(var(--core-radius-md) - 3px); background: transparent; color: var(--core-text-2); font-size: var(--core-fs-sm); font-weight: 500; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; transition: background var(--core-ease), color var(--core-ease), box-shadow var(--core-ease); }
.core-seg-btn:hover { color: var(--core-text); }
.core-seg-btn.is-active { background: var(--core-seg-active-bg); color: var(--core-text); box-shadow: var(--core-shadow-sm); font-weight: 600; }
.core-seg-btn:disabled { opacity: 0.45; cursor: default; }   /* a choice that does not apply yet (it needs a customer) */
.core-seg-btn .core-icon { width: 14px; height: 14px; }
a.core-seg-btn { text-decoration: none; }
a.core-seg-btn:hover { text-decoration: none; }
.core-seg-lg .core-seg-btn { height: 34px; padding: 0 20px; font-size: var(--core-fs-md); font-weight: 600; gap: 8px; }   /* the big switch of a screen's mode (counter · tables) */
.core-seg-lg .core-seg-btn .core-icon { width: 18px; height: 18px; }

.core-menu { position: absolute; z-index: 60; top: var(--menu-top, calc(100% + 6px)); left: var(--menu-left, auto); right: var(--menu-right, auto); min-width: 200px; padding: 6px; background: var(--core-surface); border: 1px solid var(--core-border); border-radius: var(--core-radius-lg); box-shadow: var(--core-shadow-lg); display: none; }
.core-menu.is-open { display: block; }
.core-menu-anchor { position: relative; }
/* a menu inside a scrolling box (a table's row actions) is placed on the page, so the box never cuts it */
.core-menu.core-menu-fixed { position: fixed; top: var(--menu-top, 0); left: var(--menu-left, auto); right: auto; z-index: 90; }
.core-menu-item { display: flex; align-items: center; gap: 10px; width: 100%; padding: 7px 10px; border: 0; border-radius: var(--core-radius-md); background: none; color: var(--core-text); font-size: var(--core-fs-ctl); text-align: left; cursor: pointer; text-decoration: none; }
.core-menu-item:hover { background: var(--core-hover); text-decoration: none; }
.core-menu-item .core-icon { width: 16px; height: 16px; color: var(--core-text-3); }
.core-menu-item.is-danger { color: var(--core-danger); }
.core-menu-item.is-danger .core-icon { color: var(--core-danger); }
.core-menu-item kbd { margin-left: auto; font: 500 var(--core-fs-xs) var(--core-font); color: var(--core-text-3); }
.core-menu-sep { height: 1px; background: var(--core-border); margin: 6px 4px; }
.core-menu-title { padding: 6px 10px 4px; font-size: var(--core-fs-xs); font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; color: var(--core-text-3); }

/* ------------------------------------------------------------ dialogs, toasts, alerts, empty states */
/* the scrim (UI.md "The scrim", 18 November 2026): the one layer between the page and what opens over it — a dialog,
   the viewer, the menu on a phone, a layer of a product's own (.core-scrim). Darker and a little blurred, from the theme
   (--core-overlay, --core-overlay-blur): the same in every product, and no product paints one of its own (the audit names
   a backdrop-filter or an --core-overlay outside the core). It covers the whole window: it never takes the rhythm's margin. */
.core-scrim { position: fixed; inset: 0; z-index: 100; margin: 0; }
.core-scrim, .core-dialog-overlay, .core-viewer, .core-app.is-nav-open::after { background: var(--core-overlay); backdrop-filter: var(--core-overlay-blur); }
.core-dialog-overlay { position: fixed; inset: 0; z-index: 100; display: none; align-items: center; justify-content: center; padding: var(--core-sp-4); }
.core-dialog-overlay.is-open { display: flex; }
.core-dialog { width: var(--core-dialog-w); max-width: 100%; max-height: calc(100vh - 2 * var(--core-sp-6)); display: flex; flex-direction: column; background: var(--core-surface); border: 1px solid var(--core-border); border-radius: var(--core-radius-xl); box-shadow: var(--core-shadow-lg); animation: core-pop var(--core-ease); }
.core-dialog-sm { width: 440px; }
.core-dialog-lg { width: 920px; }
@keyframes core-pop { from { opacity: 0; transform: translateY(6px) scale(0.985); } to { opacity: 1; transform: none; } }
.core-dialog > form { display: contents; }   /* a form around body + foot (Salon, Messaging): its children lay out as the dialog's own, so the body scrolls */
.core-dialog-head { display: flex; align-items: center; gap: var(--core-sp-3); padding: var(--core-sp-4) var(--core-sp-6); border-bottom: 1px solid var(--core-border); }
.core-dialog-title { font-size: var(--core-fs-lg); font-weight: var(--core-weight-title); letter-spacing: -0.01em; line-height: 1.3; }
/* the standard (UI.md, Anatomy): a dialog title is words only — an icon a page still writes there is not shown (the audit names it) */
.core-dialog-title .core-icon { display: none; }
/* the title and, for a record, one line under it: code · state · key facts (CoreUi::dialogHead) */
.core-dialog-heading { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.core-dialog-sub { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; font-size: var(--core-fs-sm); color: var(--core-text-3); line-height: 1.4; }
.core-dialog-head .core-btn-icon { margin-left: auto; }
.core-dialog-body { padding: var(--core-sp-6); overflow-y: auto; }
.core-dialog-foot { display: flex; align-items: center; gap: var(--core-sp-2); padding: var(--core-sp-4) var(--core-sp-6); border-top: 1px solid var(--core-border); background: var(--core-surface-2); border-radius: 0 0 var(--core-radius-xl) var(--core-radius-xl); }

.core-toasts { position: fixed; right: var(--core-sp-6); bottom: var(--core-sp-6); z-index: 120; display: flex; flex-direction: column; gap: var(--core-sp-2); width: 380px; max-width: calc(100vw - 2 * var(--core-sp-4)); }
.core-toast { display: flex; align-items: center; gap: var(--core-sp-3); padding: 12px 14px; background: var(--core-toast-bg); color: var(--core-toast-text); border: 1px solid var(--core-toast-border); border-radius: var(--core-radius-lg); box-shadow: var(--core-shadow-lg); font-size: var(--core-fs-md); animation: core-pop var(--core-ease); }
.core-toast .core-icon { width: 18px; height: 18px; flex-shrink: 0; }
.core-toast-ok .core-icon { color: var(--core-ok-bright); }
.core-toast-warn .core-icon { color: var(--core-warn-bright); }
.core-toast-danger .core-icon { color: var(--core-danger-bright); }
.core-toast-text { flex: 1; }
.core-toast-action { background: none; border: 0; color: var(--core-toast-action); font-weight: 600; font-size: var(--core-fs-sm); padding: 4px 6px; border-radius: var(--core-radius-sm); cursor: pointer; }
.core-toast-action:hover { background: var(--core-toast-action-hover); }
.core-toast-x { background: none; border: 0; color: var(--core-toast-text); opacity: 0.6; cursor: pointer; padding: 2px; border-radius: var(--core-radius-sm); }
.core-toast-x:hover { opacity: 1; }

/* the viewer of a page's documents (13 November 2026, from Practice's lightbox): the room over the page, a bar with
   the name, the count, Download and Close, the document in the middle (a PDF in a frame, a picture, or the note that
   it cannot be shown with its Download), the arrows to the previous and the next. CoreUi::viewer() prints it once per
   page; links a[data-core-viewer] (data-title, data-mime) open it; ui.js fills it (CoreUI.viewer). The bar and the
   arrows wear the toast's colours: they stand out on the room in every theme. */
.core-viewer { position: fixed; inset: 0; z-index: 110; display: flex; flex-direction: column; }
.core-viewer[hidden] { display: none; }
.core-viewer-bar { display: flex; align-items: center; gap: var(--core-sp-3); margin: var(--core-sp-3) var(--core-sp-4); padding: var(--core-sp-2) var(--core-sp-2) var(--core-sp-2) var(--core-sp-4); background: var(--core-toast-bg); color: var(--core-toast-text); border: 1px solid var(--core-toast-border); border-radius: var(--core-radius-lg); box-shadow: var(--core-shadow-lg); }
.core-viewer-title { min-width: 0; font-weight: 600; font-size: var(--core-fs-md); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.core-viewer-count { flex: 0 0 auto; font-size: var(--core-fs-sm); opacity: 0.75; font-variant-numeric: tabular-nums; }
.core-viewer-btn { flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; width: var(--core-ctl-h); height: var(--core-ctl-h); border: 0; border-radius: var(--core-radius-md); background: transparent; color: var(--core-toast-text); cursor: pointer; text-decoration: none; }
.core-viewer-btn:hover { background: var(--core-toast-action-hover); text-decoration: none; }
.core-viewer-body { position: relative; flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; padding: 0 72px var(--core-sp-5); }
.core-viewer-slot { display: contents; }
.core-viewer-frame { width: min(940px, 100%); height: 100%; border: 0; border-radius: var(--core-radius-lg); background: var(--core-surface); box-shadow: var(--core-shadow-lg); }
.core-viewer-img { max-width: 100%; max-height: 100%; border-radius: var(--core-radius-lg); box-shadow: var(--core-shadow-lg); }
.core-viewer-none { display: flex; flex-direction: column; align-items: center; gap: var(--core-sp-3); padding: var(--core-sp-6) var(--core-sp-8); background: var(--core-surface); color: var(--core-text-2); border-radius: var(--core-radius-lg); box-shadow: var(--core-shadow-lg); text-align: center; }
.core-viewer-none > .core-icon { color: var(--core-text-3); }
.core-viewer-arrow { position: absolute; top: 50%; transform: translateY(-50%); display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border: 1px solid var(--core-toast-border); border-radius: 50%; background: var(--core-toast-bg); color: var(--core-toast-text); box-shadow: var(--core-shadow-lg); cursor: pointer; }
.core-viewer-arrow:hover { background: var(--core-toast-action-hover); }
.core-viewer-arrow[disabled] { opacity: 0.3; cursor: default; }
.core-viewer-arrow.is-prev { left: var(--core-sp-4); }
.core-viewer-arrow.is-next { right: var(--core-sp-4); }
.core-viewer.is-single .core-viewer-arrow, .core-viewer.is-single .core-viewer-count { display: none; }   /* one document: no arrows, no count */
@media (max-width: 768px) { .core-viewer-body { padding: 0 var(--core-sp-2) var(--core-sp-3); } .core-viewer-arrow { top: auto; bottom: var(--core-sp-5); transform: none; } }

.core-alert { display: flex; gap: var(--core-sp-3); padding: 12px 14px; border-radius: var(--core-radius-lg); border: 1px solid var(--core-border); background: var(--core-surface-2); font-size: var(--core-fs-md); color: var(--core-text); }
.core-alert .core-icon { flex-shrink: 0; margin-top: 1px; color: var(--core-text-2); }
.core-alert-title { font-weight: 600; margin-bottom: 2px; }
.core-alert-body { color: var(--core-text-2); }
.core-alert-body a { font-weight: 500; }
.core-alert-ok { background: var(--core-ok-bg); border-color: var(--core-ok-border); }
.core-alert-ok .core-icon, .core-alert-ok .core-alert-title { color: var(--core-ok); }
.core-alert-warn { background: var(--core-warn-bg); border-color: var(--core-warn-border); }
.core-alert-warn .core-icon, .core-alert-warn .core-alert-title { color: var(--core-warn); }
.core-alert-danger { background: var(--core-danger-bg); border-color: var(--core-danger-border); }
.core-alert-danger .core-icon, .core-alert-danger .core-alert-title { color: var(--core-danger); }
.core-alert-info { background: var(--core-info-bg); border-color: var(--core-info-border); }
.core-alert-info .core-icon, .core-alert-info .core-alert-title { color: var(--core-info); }
.core-alert .core-btn { margin-left: auto; align-self: center; }

.core-empty { display: flex; flex-direction: column; align-items: center; text-align: center; gap: var(--core-sp-2); padding: var(--core-sp-10) var(--core-sp-6); color: var(--core-text-2); }
.core-empty-icon { width: 56px; height: 56px; border-radius: var(--core-radius-xl); background: var(--core-hover); color: var(--core-text-2); display: inline-flex; align-items: center; justify-content: center; margin-bottom: var(--core-sp-2); }
.core-empty-icon .core-icon { width: 26px; height: 26px; stroke-width: 1.6; }
.core-empty-title { font-size: var(--core-fs-md); font-weight: 600; color: var(--core-text); }
.core-empty .core-btn { margin-top: var(--core-sp-2); }

.core-progress { height: 6px; border-radius: var(--core-radius-pill); background: var(--core-track); overflow: hidden; }
.core-progress > span { display: block; height: 100%; width: var(--value, 0%); background: var(--core-accent); border-radius: inherit; transition: width var(--core-ease); }
.core-skeleton { background: linear-gradient(90deg, var(--core-track) 25%, var(--core-hover) 50%, var(--core-track) 75%); background-size: 200% 100%; animation: core-shimmer 1.4s infinite; border-radius: var(--core-radius-sm); min-height: 12px; }
@keyframes core-shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
.core-kbd { display: inline-block; font: 600 var(--core-fs-xs) var(--core-font); color: var(--core-text-2); border: 1px solid var(--core-border); border-bottom-width: 2px; border-radius: var(--core-radius-sm); padding: 1px 6px; background: var(--core-surface); }
.core-tooltip { position: relative; }
.core-tooltip::after { content: attr(data-tip); position: absolute; left: 50%; bottom: calc(100% + 6px); transform: translateX(-50%); background: var(--core-toast-bg); color: var(--core-toast-text); font-size: var(--core-fs-xs); font-weight: 500; padding: 4px 8px; border-radius: var(--core-radius-sm); white-space: nowrap; opacity: 0; pointer-events: none; transition: opacity var(--core-ease); }
.core-tooltip:hover::after { opacity: 1; }
/* a hint of several lines (17 November 2026): [data-core-tip] — the first line is the title, the others its facts, one
   per line ("\n"); one box for the whole page, over the element (under it when there is no room), kept inside the window;
   it opens with the mouse, the keyboard's focus or a tap, and closes with a tap elsewhere, a scroll or Escape (ui.js) */
.core-tip { position: fixed; z-index: 1000; max-width: min(360px, calc(100vw - 16px)); padding: 8px 12px; background: var(--core-toast-bg); color: var(--core-toast-text); border-radius: var(--core-radius-md); box-shadow: var(--core-shadow-lg); font-size: var(--core-fs-xs); line-height: 1.5; pointer-events: none; opacity: 0; transition: opacity var(--core-ease); }
.core-tip.is-on { opacity: 1; }
.core-tip-title { font-weight: 600; }
.core-tip-line { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.core-tip::after { content: ""; position: absolute; left: var(--core-tip-arrow, 14px); top: 100%; margin-left: -6px; border: 6px solid transparent; border-top-color: var(--core-toast-bg); }
.core-tip.is-below::after { top: auto; bottom: 100%; border-top-color: transparent; border-bottom-color: var(--core-toast-bg); }
[data-core-tip] { cursor: default; }
[data-core-tip]:focus-visible { outline: none; box-shadow: 0 0 0 2px var(--core-focus); }

/* list rows (activity feeds, settings lists) */
.core-list { display: flex; flex-direction: column; }
:where(ul.core-list, ol.core-list) { list-style: none; margin: 0; padding: 0; }   /* a list written as ul/ol: no bullet, indent or margins of the browser (zero specificity: a spacing utility still wins) */
.core-list-item { display: flex; align-items: center; gap: var(--core-sp-3); padding: 12px var(--core-card-pad); border-bottom: 1px solid var(--core-border-subtle); }
.core-list-item:last-child { border-bottom: 0; }
.core-list-item:hover { background: var(--core-hover); }
.core-list-item.is-selected, .core-list-item.is-selected:hover { background: var(--core-selected); }   /* the item a list shows open on the page beside it (Booking's mail texts), like a chosen table row */
.core-list-title { font-weight: 500; }
.core-list-meta { font-size: var(--core-fs-sm); color: var(--core-text-3); }
.core-list-end { margin-left: auto; display: flex; align-items: center; gap: var(--core-sp-2); }

/* ------------------------------------------------------------ gantt (UI.md "Gantt", 17 November 2026)
   Rows on the left (people, days, rooms…), the hours of a day across, one to three lanes a row. CoreUi::gantt() prints
   it inside a core-card-flush; the places are per cent of the axis in data-core-x / data-core-w, painted by ui.js through
   the CSSOM (allowed under a strict CSP). The names stay on the left while the time scrolls; a quarter of an hour keeps
   at least --core-gantt-step px. A bar is filled with the colour of what it is (palette 1–8, is-pal-N); the states are
   drawn over it and not chosen: is-open (dashed: the end is missing), is-live (going on now: a dot at its end),
   is-accent (out of the schedule), is-joined (the second piece of a split, a fine cut before it). */
.core-gantt { --core-gantt-who: 196px; --core-gantt-lab: 84px; --core-gantt-lane: 24px; --core-gantt-step: 16px; }
.core-gantt-one { --core-gantt-who: 280px; --core-gantt-lab: 0px; --core-gantt-lane: 22px; }   /* one lane: the room of the labels goes to the names */
.core-gantt-scroll { display: grid; overflow-x: auto; }
.core-gantt-axis, .core-gantt-row { display: grid; grid-template-columns: var(--core-gantt-who) var(--core-gantt-lab) minmax(var(--core-gantt-min, 0px), 1fr); }
.core-gantt-axis { background: var(--core-surface); border-bottom: 1px solid var(--core-border); }
.core-gantt-axis > div:nth-child(-n+2), .core-gantt-who, .core-gantt-labs { position: sticky; z-index: 2; background: var(--core-surface); }
.core-gantt-axis > div:first-child, .core-gantt-who { left: 0; }
.core-gantt-axis > div:nth-child(2), .core-gantt-labs { left: var(--core-gantt-who); border-right: 1px solid var(--core-border); }
.core-gantt-hours { position: relative; height: 46px; }
.core-gantt-hours > span { position: absolute; line-height: 1; font-variant-numeric: tabular-nums; }
.core-gantt-h { top: 8px; padding-left: 4px; font-size: var(--core-fs-xs); font-weight: 600; color: var(--core-text-2); }
.core-gantt-q { bottom: 7px; transform: translateX(-50%); font-size: var(--core-fs-2xs); color: var(--core-text-3); }
.core-gantt-hline { position: absolute; top: 0; bottom: 0; width: 1px; background: var(--core-border); }
.core-gantt [data-core-x] { left: calc(var(--x, 0) * 1%); }
.core-gantt-row { border-bottom: 1px solid var(--core-border-subtle); }
.core-gantt-row:hover, .core-gantt-row.is-off { background: var(--core-surface-2); }
.core-gantt-row:hover > .core-gantt-who, .core-gantt-row:hover > .core-gantt-labs, .core-gantt-row.is-off > .core-gantt-who, .core-gantt-row.is-off > .core-gantt-labs { background: var(--core-surface-2); }
.core-gantt-row[data-core-row] { cursor: pointer; }
.core-gantt-who { padding: 8px var(--core-sp-4); display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.core-gantt-name { height: 24px; font-weight: 600; color: var(--core-text); display: flex; align-items: center; gap: var(--core-sp-2); white-space: nowrap; min-width: 0; }
.core-gantt-name > span:first-child { overflow: hidden; text-overflow: ellipsis; }
.core-gantt-sub { height: 24px; line-height: 24px; font-size: var(--core-fs-xs); color: var(--core-text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-variant-numeric: tabular-nums; }
.core-gantt-sub b { color: var(--core-text-2); font-weight: 600; }
.core-gantt-labs { display: grid; grid-auto-rows: var(--core-gantt-lane); gap: 4px; padding: 8px 0 8px var(--core-sp-2); align-content: center; font-size: var(--core-fs-2xs); text-transform: uppercase; letter-spacing: 0.04em; color: var(--core-text-3); }
.core-gantt-labs > span { display: flex; align-items: center; white-space: nowrap; overflow: hidden; }
.core-gantt-lanes { position: relative; display: grid; grid-auto-rows: var(--core-gantt-lane); gap: 4px; padding: 8px 0; align-content: center; }
.core-gantt-lane { position: relative; }
.core-gantt-grid { position: absolute; inset: 0; pointer-events: none; }
.core-gantt-grid > i { position: absolute; top: 0; bottom: 0; width: 1px; background: var(--core-border-subtle); }
.core-gantt-grid > i.is-hour { background: var(--core-border); }
.core-gantt-one .core-gantt-labs { padding: 0; display: block; }
.core-gantt-one .core-gantt-lanes { align-content: start; padding: 6px 0; }
.core-gantt-one .core-gantt-who { padding-top: 6px; padding-bottom: 6px; gap: 0; }
.core-gantt-one .core-gantt-name { height: 22px; }
.core-gantt-one .core-gantt-sub { height: 18px; line-height: 18px; }
/* the bands behind the lanes: the hours due, a flexible span, a time paid more */
.core-gantt-band { position: absolute; top: 0; bottom: 0; width: calc(var(--w, 0) * 1%); background: var(--core-band); border: 1px solid var(--core-band-line); border-radius: var(--core-radius-sm); }
.core-gantt-band.is-flex { background: repeating-linear-gradient(-45deg, var(--core-surface) 0 5px, var(--core-band-stripe) 5px 7px); }
.core-gantt-band.is-plus { background: var(--core-band-plus); border-color: var(--core-band-plus-line); }
/* the bars */
.core-gantt-bar { position: absolute; top: 0; bottom: 0; width: calc(var(--w, 0) * 1% - 1px); min-width: 2px; border: 1px solid transparent; border-radius: var(--core-radius-sm); background: var(--core-surface); color: var(--core-text-2); font-size: var(--core-fs-xs); line-height: 1; display: flex; align-items: center; overflow: hidden; }
.core-gantt-bar > span { padding: 0 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.core-gantt-bar.is-strong { font-weight: 600; }
.core-gantt-bar.is-plain { background: var(--core-surface); border-color: var(--core-border-strong); color: var(--core-text-2); }
.core-gantt-bar.is-pal-1 { background: var(--core-pal-1-soft); color: var(--core-pal-1-text); } .core-gantt-bar.is-pal-2 { background: var(--core-pal-2-soft); color: var(--core-pal-2-text); }
.core-gantt-bar.is-pal-3 { background: var(--core-pal-3-soft); color: var(--core-pal-3-text); } .core-gantt-bar.is-pal-4 { background: var(--core-pal-4-soft); color: var(--core-pal-4-text); }
.core-gantt-bar.is-pal-5 { background: var(--core-pal-5-soft); color: var(--core-pal-5-text); } .core-gantt-bar.is-pal-6 { background: var(--core-pal-6-soft); color: var(--core-pal-6-text); }
.core-gantt-bar.is-pal-7 { background: var(--core-pal-7-soft); color: var(--core-pal-7-text); } .core-gantt-bar.is-pal-8 { background: var(--core-pal-8-soft); color: var(--core-pal-8-text); }
.core-gantt-bar.is-accent { background: var(--core-accent); border-color: var(--core-accent); color: var(--core-on-accent); }
.core-gantt-bar.is-joined { box-shadow: inset 2px 0 0 var(--core-surface); }
.core-gantt-bar.is-live { overflow: visible; }
.core-gantt-bar.is-live::after { content: ""; position: absolute; right: -1px; top: 50%; width: 8px; height: 8px; margin-top: -4px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 2px var(--core-surface); }
/* the colours the user chose (data-core-color on a bar or a band, data-core-colors="open:…;now:…" on the gantt) */
.core-gantt-bar.is-color { background: var(--core-c-soft); color: var(--core-c-text); }
.core-gantt-bar.is-color-solid { background: var(--core-c); border-color: var(--core-c); color: var(--core-c-on); }
.core-gantt-band[data-core-color] { background: var(--core-c-faint); border-color: var(--core-c-soft); }
.core-gantt-band.is-flex[data-core-color] { background: repeating-linear-gradient(-45deg, var(--core-surface) 0 5px, var(--core-c-soft) 5px 7px); }
.core-gantt-bar.is-open { border-style: dashed; border-color: var(--core-c-open, var(--core-warn)); }
.core-gantt-bar.is-open.is-plain { background: var(--core-c-open-faint, var(--core-warn-bg)); }
/* now: a red line through the lanes, its time on the axis */
.core-gantt-now { position: absolute; top: 0; bottom: 0; width: 2px; margin-left: -1px; background: var(--core-c-now, var(--core-danger)); z-index: 1; pointer-events: none; }
.core-gantt-hours > .core-gantt-now-tag { top: 3px; transform: translateX(-50%); padding: 2px 6px; border-radius: var(--core-radius-pill); background: var(--core-c-now, var(--core-danger)); color: var(--core-c-now-on, var(--core-on-danger)); font-size: var(--core-fs-2xs); font-weight: 600; z-index: 3; }
/* a group of rows (a department): a grey head with its name and counts, opens and closes its rows */
.core-gantt-set.is-closed > .core-gantt-row { display: none; }
.core-gantt-group { display: grid; grid-template-columns: calc(var(--core-gantt-who) + var(--core-gantt-lab)) minmax(var(--core-gantt-min, 0px), 1fr); background: var(--core-surface-2); border-bottom: 1px solid var(--core-border); }
/* the head takes the whole row (its counts are not cut at the column of the names) and stays on the left while the time scrolls */
.core-gantt-group-head { grid-column: 1 / -1; grid-row: 1; justify-self: start; position: sticky; left: 0; z-index: 2; display: flex; align-items: center; gap: var(--core-sp-2); min-width: 0; max-width: 100%; height: 40px; padding: 0 var(--core-sp-4); border: 0; background: var(--core-surface-2); color: var(--core-text); font: inherit; text-align: left; cursor: pointer; }
.core-gantt-group-head:focus-visible { outline: none; box-shadow: inset 0 0 0 2px var(--core-focus); }
.core-gantt-group-head > .core-icon { width: 16px; height: 16px; color: var(--core-text-3); flex: none; transition: transform var(--core-ease); }
.core-gantt-set.is-closed .core-gantt-group-head > .core-icon { transform: rotate(-90deg); }
.core-gantt-group-name { font-weight: 600; white-space: nowrap; }
.core-gantt-group-sub { font-size: var(--core-fs-xs); color: var(--core-text-3); white-space: nowrap; }
.core-gantt-group-sub b { color: var(--core-text-2); font-weight: 600; }
.core-gantt-group-time { grid-column: 2; grid-row: 1; position: relative; overflow: hidden; height: 40px; }
/* the legend, in the head of the card */
.core-gantt-legend { display: flex; flex-wrap: wrap; gap: var(--core-sp-2) var(--core-sp-4); font-size: var(--core-fs-xs); color: var(--core-text-2); }
.core-gantt-legend > span { display: inline-flex; align-items: center; gap: var(--core-sp-2); white-space: nowrap; }
.core-gantt-sw { width: 18px; height: 10px; border-radius: 3px; border: 1px solid var(--core-border-strong); background: var(--core-surface); flex: none; }
.core-gantt-sw.is-band { background: var(--core-band); border-color: var(--core-band-line); }
.core-gantt-sw.is-flex { background: repeating-linear-gradient(-45deg, var(--core-surface) 0 3px, var(--core-band-stripe) 3px 5px); border-color: var(--core-band-line); }
.core-gantt-sw.is-plus { background: var(--core-band-plus); border-color: var(--core-band-plus-line); }
.core-gantt-sw.is-accent { background: var(--core-accent); border-color: var(--core-accent); }
.core-gantt-sw.is-open { border-style: dashed; border-color: var(--core-warn); background: var(--core-warn-bg); }
.core-gantt-sw.is-now { width: 2px; border: 0; border-radius: 0; background: var(--core-danger); }
.core-gantt-sw.is-pal-1 { background: var(--core-pal-1-soft); border-color: transparent; } .core-gantt-sw.is-pal-2 { background: var(--core-pal-2-soft); border-color: transparent; }
.core-gantt-sw.is-pal-3 { background: var(--core-pal-3-soft); border-color: transparent; } .core-gantt-sw.is-pal-4 { background: var(--core-pal-4-soft); border-color: transparent; }
.core-gantt-sw.is-pal-5 { background: var(--core-pal-5-soft); border-color: transparent; } .core-gantt-sw.is-pal-6 { background: var(--core-pal-6-soft); border-color: transparent; }
.core-gantt-sw.is-pal-7 { background: var(--core-pal-7-soft); border-color: transparent; } .core-gantt-sw.is-pal-8 { background: var(--core-pal-8-soft); border-color: transparent; }
.core-gantt-sw[data-core-color] { background: var(--core-c-soft); border-color: transparent; }
.core-gantt-sw.is-solid[data-core-color], .core-gantt-sw.is-accent[data-core-color], .core-gantt-sw.is-now[data-core-color] { background: var(--core-c); }
.core-gantt-sw.is-band[data-core-color], .core-gantt-sw.is-plus[data-core-color] { background: var(--core-c-faint); border-color: var(--core-c-soft); }
.core-gantt-sw.is-flex[data-core-color] { background: repeating-linear-gradient(-45deg, var(--core-surface) 0 3px, var(--core-c-soft) 3px 5px); border-color: var(--core-c-soft); }
.core-gantt-sw.is-open[data-core-color] { border-color: var(--core-c); background: var(--core-c-faint); }
/* the day of a row in small (a phone: a list instead of the gantt): one thin strip with the same bands and bars */
.core-gantt-strip { position: relative; height: 10px; border-radius: 3px; background: var(--core-surface); box-shadow: inset 0 0 0 1px var(--core-border-subtle); overflow: hidden; }
.core-gantt-strip > .core-gantt-band, .core-gantt-strip > .core-gantt-bar { border: 0; border-radius: 2px; }
.core-gantt-strip > .core-gantt-bar.is-open { border: 1px dashed var(--core-c-open, var(--core-warn)); }
.core-gantt-strip-hours { position: relative; height: 12px; font-size: var(--core-fs-2xs); color: var(--core-text-3); font-variant-numeric: tabular-nums; }
.core-gantt-strip-hours > span { position: absolute; transform: translateX(-50%); }
.core-gantt-strip-hours > span:first-child { transform: none; }
.core-gantt-strip-hours > span:last-child { transform: translateX(-100%); }
.core-gantt-strip [data-core-x], .core-gantt-strip-hours [data-core-x] { left: calc(var(--x, 0) * 1%); }
/* the list for a phone (CoreUi::gantt 'list'): under 768 px it takes the place of the gantt */
.core-gantt-list { display: none; }
.core-gantt-list-hours { padding: 10px var(--core-sp-4) 4px; border-bottom: 1px solid var(--core-border); }
.core-gantt-item { display: grid; gap: 4px; padding: 10px var(--core-sp-4) 12px; border-bottom: 1px solid var(--core-border-subtle); min-width: 0; }
.core-gantt-item.is-off { background: var(--core-surface-2); }
.core-gantt-item[data-core-row] { cursor: pointer; }
.core-gantt-item > .core-gantt-name, .core-gantt-item > .core-gantt-sub { height: auto; line-height: 1.4; }
.core-gantt-item > .core-gantt-strip { margin-top: 4px; }
.core-gantt-list .core-gantt-group-head { width: 100%; position: static; border-bottom: 1px solid var(--core-border); }
.core-gantt-list .core-gantt-group-sub { overflow: hidden; text-overflow: ellipsis; }
.core-gantt-set.is-closed > .core-gantt-item { display: none; }
@media (max-width: 768px) { .core-gantt-has-list > .core-gantt-scroll { display: none; } .core-gantt-has-list > .core-gantt-list { display: block; } }
@media (max-width: 768px) { .core-gantt { --core-gantt-who: 136px; --core-gantt-lab: 64px; } .core-gantt-one { --core-gantt-who: 160px; --core-gantt-lab: 0px; } .core-gantt-who { padding-left: var(--core-sp-3); padding-right: var(--core-sp-2); } }

/* ------------------------------------------------------------ auth pages (sign in, sign up, confirm, reset — docs/AUTH.md) */
.core-auth-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: var(--core-sp-6) var(--core-sp-4); background: var(--core-bg); }
.core-auth-card { width: 100%; max-width: 420px; background: var(--core-surface); border: 1px solid var(--core-border); border-radius: var(--core-radius-xl); padding: var(--core-sp-6) var(--core-sp-6) var(--core-sp-5); box-shadow: var(--core-shadow-md); }
.core-auth-card-wide { max-width: 640px; }   /* a longer form (a sign-up with more fields, an installer): two columns with .core-form-row */
.core-auth-brand { display: flex; align-items: center; gap: var(--core-sp-3); font-weight: 700; font-size: 1.05rem; letter-spacing: -0.02em; margin-bottom: var(--core-sp-6); color: var(--core-text); text-decoration: none; }
.core-auth-brand:hover { text-decoration: none; }
.core-auth-brand .core-brand-mark { width: 30px; height: 30px; }
.core-auth-title { font-size: 1.35rem; font-weight: 600; letter-spacing: -0.02em; margin: 0 0 var(--core-sp-1); }
.core-auth-sub { color: var(--core-text-2); font-size: var(--core-fs-sm); margin: 0 0 var(--core-sp-5); }
.core-auth-form { margin-bottom: var(--core-sp-4); }
.core-auth-links { margin-top: var(--core-sp-4); font-size: var(--core-fs-sm); text-align: center; color: var(--core-text-2); display: flex; flex-direction: column; gap: var(--core-sp-2); }
.core-auth-links a { color: var(--core-text); font-weight: 500; }
.core-auth-foot { margin-top: var(--core-sp-5); padding-top: var(--core-sp-4); border-top: 1px solid var(--core-border); display: flex; justify-content: space-between; align-items: center; gap: var(--core-sp-3); font-size: var(--core-fs-xs); color: var(--core-text-3); }
.core-auth-langs { display: flex; gap: var(--core-sp-2); }
.core-auth-langs a { color: var(--core-text-3); text-transform: uppercase; letter-spacing: 0.04em; }
.core-auth-langs a.is-active { color: var(--core-text); font-weight: 600; }
.core-auth-done { text-align: center; padding: var(--core-sp-4) 0 var(--core-sp-2); }
.core-auth-done .core-icon-lg { color: var(--core-ok); margin-bottom: var(--core-sp-3); }
.core-auth-card .core-alert-body { min-width: 0; overflow-wrap: anywhere; }   /* a long link (the development note) wraps inside the card */

/* ------------------------------------------------------------ documents (pdf/CoreDocHtml: the same model CoreDocPdf prints) */
.core-doc { width: 210mm; min-height: 297mm; margin: var(--core-sp-6) auto; padding: 14mm 15mm 18mm 20mm; background: var(--core-surface); color: var(--core-text); box-sizing: border-box; font-size: 9.5pt; line-height: 1.3; }
.core-doc-head { display: flex; justify-content: space-between; align-items: flex-start; gap: var(--core-sp-6); }
.core-doc-sender { font-size: 9.5pt; line-height: 1.3; }
.core-doc-logo { display: block; width: 40mm; height: auto; margin-bottom: 3mm; }
.core-doc-muted { color: var(--core-text-2); font-size: 8pt; }
.core-doc-fields { border-collapse: collapse; font-size: 8pt; }
.core-doc-fields th { text-align: left; font-weight: 500; color: var(--core-text-2); padding: 0 4mm 0 0; }
.core-doc-fields td { padding: 0; }
.core-doc-recipient { margin: 10mm 0 0; min-height: 22mm; line-height: 1.3; }
.core-doc-title { font-size: 15pt; font-weight: 700; letter-spacing: -0.01em; margin: 10mm 0 1mm; }
.core-doc-subject { margin: 0 0 4mm; }
.core-doc-text { margin: 0 0 2.5mm; white-space: pre-wrap; }
.core-doc-text.is-small, .core-doc-text.is-muted { font-size: 8pt; }
.core-doc-text.is-muted { color: var(--core-text-2); }
.core-doc-text.is-bold { font-weight: 700; }
.core-doc-html { margin: 0 0 2.5mm; }
.core-doc-html p, .core-doc-html ul, .core-doc-html ol { margin: 0 0 2.5mm; }
.core-doc-html ul, .core-doc-html ol { padding-left: 5mm; }
.core-doc-html h1, .core-doc-html h2, .core-doc-html h3 { margin: 0 0 2.5mm; font-weight: 700; }
.core-doc-html h1 { font-size: 1.6em; }
.core-doc-html h2 { font-size: 1.35em; }
.core-doc-html h3 { font-size: 1.15em; }
.core-doc-html small { font-size: 0.85em; }
.core-doc-html a { color: inherit; text-decoration: underline; }
.core-doc-facts { border-collapse: collapse; margin: 0 0 2.5mm; }
.core-doc-facts th { text-align: left; font-weight: 500; color: var(--core-text-2); font-size: 8pt; padding: 0 3mm 0 0; }
.core-doc-facts td { padding: 0 12mm 0 0; }
.core-doc-rows { width: 100%; border-collapse: collapse; margin: 0 0 3mm; table-layout: fixed; }
.core-doc-rows th { text-align: left; font-weight: 700; font-size: 8pt; color: var(--core-text-2); vertical-align: bottom; border-bottom: 1px solid var(--core-text-3); padding: 1.5mm 1.5mm; }
.core-doc-rows td { padding: 1.5mm 1.5mm; border-bottom: 1px solid var(--core-border); vertical-align: top; overflow-wrap: anywhere; }
.core-doc-rows .is-right { text-align: right; font-variant-numeric: tabular-nums; }
.core-doc-rows .is-center { text-align: center; }
.core-doc-rows tr.is-title td { font-weight: 700; background: var(--core-surface-2); }
.core-doc-rows tr.is-text td { color: var(--core-text-2); }
.core-doc-rows tr.is-subtotal td { font-style: italic; }
.core-doc-rows tr.is-total td { font-weight: 700; border-bottom: 1px solid var(--core-text-3); }
.core-doc-note { color: var(--core-text-2); font-size: 8pt; }
.core-doc-totals { border-collapse: collapse; margin: 0 0 4mm auto; min-width: 80mm; }
.core-doc-totals th { text-align: left; font-weight: 400; padding: 0.5mm 8mm 0.5mm 0; }
.core-doc-totals td { text-align: right; padding: 0.5mm 0; font-variant-numeric: tabular-nums; }
.core-doc-totals tr.is-total th, .core-doc-totals tr.is-total td { font-weight: 700; font-size: 10.5pt; border-top: 1px solid var(--core-text-3); padding-top: 1.5mm; }
.core-doc-sign { display: flex; gap: 10mm; margin: 14mm 0 10mm; font-size: 8pt; color: var(--core-text-2); }
.core-doc-sign > div { flex: 1 1 0; }
.core-doc-sign-line { display: block; border-top: 1px solid var(--core-text-3); margin-bottom: 1.5mm; }
.core-doc-sign-image { display: block; max-height: 16mm; max-width: 60mm; margin-bottom: 1mm; }
.core-doc-sign-name { display: block; color: var(--core-text); }
.core-doc-sign-note { display: block; }
.core-doc-images { display: grid; gap: 4mm; margin: 2mm 0 4mm; }
.core-doc-images.is-cols-1 { grid-template-columns: 1fr; }
.core-doc-images.is-cols-2 { grid-template-columns: 1fr 1fr; }
.core-doc-images.is-cols-3 { grid-template-columns: 1fr 1fr 1fr; }
.core-doc-images figure { margin: 0; font-size: 8pt; }
.core-doc-images strong { display: block; margin-bottom: 1mm; }
.core-doc-image { display: flex; align-items: center; justify-content: center; height: 45mm; border: 1px solid var(--core-border-subtle); }
.core-doc-image img { max-width: 100%; max-height: 100%; }
.core-doc-images figcaption { margin-top: 1mm; color: var(--core-text-2); }
.core-doc-spacer { height: 4mm; }
.core-doc-spacer.is-tall { height: 10mm; }
.core-doc-break { page-break-after: always; }
.core-doc-foot { margin-top: 10mm; padding-top: 2.5mm; border-top: 1px solid var(--core-border); font-size: 7pt; color: var(--core-text-2); line-height: 1.4; }
/* the Swiss QR-bill payment part (block payment_part): 210 × 105 mm, the receipt 62 mm and the payment part 148 mm */
.core-qrbill { position: relative; display: flex; width: 210mm; height: 105mm; margin: 12mm 0 0 -20mm; border-top: 0.2mm dashed var(--core-text); color: var(--core-text); background: #fff; font-family: inherit; break-inside: avoid; }
.core-qrbill-separate { position: absolute; top: -4.5mm; left: 0; right: 0; text-align: center; font-size: 7pt; color: var(--core-text-2); }
.core-qrbill-receipt { width: 62mm; flex: 0 0 62mm; padding: 5mm; border-right: 0.2mm dashed var(--core-text); position: relative; font-size: 8pt; line-height: 1.25; }
.core-qrbill-receipt .core-qrbill-h { font-size: 6pt; }
.core-qrbill-payment { flex: 1 1 auto; display: flex; padding: 5mm; font-size: 10pt; line-height: 1.25; }
.core-qrbill-left { width: 51mm; flex: 0 0 51mm; }
.core-qrbill-info { flex: 1 1 auto; padding-left: 5mm; }
.core-qrbill-title { font-size: 11pt; font-weight: 700; margin-bottom: 4mm; }
.core-qrbill-sec { margin-bottom: 2.5mm; }
.core-qrbill-h { font-size: 8pt; font-weight: 700; }
.core-qrbill-blank { width: 65mm; height: 25mm; border: 0.25mm solid var(--core-text); margin-top: 1mm; }
.core-qrbill-receipt .core-qrbill-blank { width: 52mm; height: 20mm; }
.core-qrbill-qr { width: 46mm; height: 46mm; margin: 0 0 5mm; }
.core-qrbill-qr svg { width: 46mm; height: 46mm; display: block; }
.core-qrbill-amount { display: flex; gap: 8mm; }
.core-qrbill-receipt .core-qrbill-amount { position: absolute; left: 5mm; bottom: 24mm; }
.core-qrbill-acceptance { position: absolute; right: 5mm; bottom: 18mm; font-size: 6pt; font-weight: 700; }
@media print { .core-qrbill { margin-left: -20mm; } }

/* ------------------------------------------------------------ legal documents (legal/CoreLegal: terms, privacy, processing agreement) */
.core-legal { max-width: 46rem; color: var(--core-text); line-height: 1.6; }
.core-legal-title { margin: 0; font-size: var(--core-fs-2xl); font-weight: 650; letter-spacing: -0.01em; }
.core-legal-meta { margin: var(--core-sp-2) 0 0; font-size: var(--core-fs-sm); color: var(--core-text-3); }
.core-legal-section { margin-top: var(--core-sp-8); }
.core-legal-h2 { margin: 0 0 var(--core-sp-2); font-size: var(--core-fs-lg); font-weight: 600; }
.core-legal p { margin: 0; color: var(--core-text-2); }
.core-legal p + p { margin-top: var(--core-sp-3); }
.core-legal strong { color: var(--core-text); font-weight: 600; }   /* a clause shown in evidence (legal 0.4.0) */
.core-legal-consent { align-items: flex-start; line-height: var(--core-lh); }   /* the consent box of a sign-up: two or three lines, the box beside the first */
.core-legal-consent input { margin-top: calc((var(--core-fs-ctl) * var(--core-lh) - 16px) / 2); }
.core-legal-consent a { color: var(--core-accent-text); text-decoration: underline; text-underline-offset: 2px; }
/* the page of a product's site (CoreLegal::site): the three documents as tabs, and under the open one the way to write about it */
.core-legal-tabs { margin-bottom: var(--core-sp-8); }
.core-legal-ask { max-width: 46rem; margin-top: var(--core-sp-8); }
.core-legal-ask > .core-card-body { display: flex; flex-wrap: wrap; align-items: center; gap: var(--core-sp-4); }
.core-legal-ask > .core-card-body > div { flex: 1 1 260px; }

/* ------------------------------------------------------------ responsive */
@media (max-width: 1024px) {
    :root { --core-page-px: 20px; }
    .core-grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .core-grid-main { grid-template-columns: minmax(0, 1fr); }   /* minmax(0, …): a plain 1fr track grows to the min-content of a wide table inside and the page scrolls sideways */
}
@media (max-width: 768px) {
    .core-sidebar { transform: translateX(-100%); }
    .core-app.is-nav-open .core-sidebar { transform: none; width: var(--core-sidebar-w); box-shadow: var(--core-shadow-lg); }   /* the shadow only while open: closed, it would peek in at the left edge */
    .core-card-head { flex-wrap: wrap; }   /* title and actions on two lines when the width is short */
    .core-app.is-nav-open::after { content: ''; position: fixed; inset: 0; z-index: 39; }   /* the scrim under the menu (its look: "the scrim" above) */
    .core-main, .core-app.is-collapsed .core-main { margin-left: 0; }
    .core-grid-2, .core-grid-3, .core-grid-4, .core-form-row, .core-form-row-3, .core-form-row-wide { grid-template-columns: minmax(0, 1fr); }
    .core-span-2 { grid-column: auto; }
    .core-search { width: 100%; }
    .core-page-head { flex-direction: column; }
    .core-dialog { max-height: 100vh; border-radius: var(--core-radius-lg); }
    .core-toasts { right: var(--core-sp-4); bottom: var(--core-sp-4); }
}
@media print {
    @page { size: A4; margin: 0; }
    .core-doc { width: auto; min-height: auto; margin: 0; box-shadow: none; }
    .core-doc-rows thead { display: table-header-group; }
    .core-doc-rows tr { page-break-inside: avoid; }
    .core-sidebar, .core-topbar, .core-page-actions, .core-toolbar, .core-pagination, .core-td-actions, .core-th-actions { display: none !important; }
    .core-main { margin-left: 0; }
    .core-card, .core-table-card { box-shadow: none; }
}
