/* Minimal Light: the Light theme of the design system (decisions UI-48,
   UI-54). The spec is dev/engineering_notes/ui_design_system_spec_2026_11_11.md
   (section "Rollout as a theme family").

   This file holds the tokens of the family and the component rules of the
   families moved from the component sheet: since rollout job 1 the shell
   (the page frame and the families 1 to 4 and 22 to 24), since rollout
   job 2 the lists and panels (families 5 to 10 and 15 to 17), since rollout
   job 3 the data display (families 11 to 14), since rollout job 4 the
   tickets (families 18, 21 and 34 and the ticket dialog of family 28),
   since rollout job 5 the dashboard and the bills (families 19, 20 and
   38), since rollout job 6 the controls and the Mikron pages (families 25
   to 27).
   The rule below applies to both variants, because the setting
   "minimal-dark" also gives data-theme="minimal". minimal-dark.css sets
   every value that differs in Dark. The default themes keep the look of
   master; the values of the third UI climb live here instead of in
   light.css.

   The component rules of the family use the prefix
   html[data-theme="minimal"]. The later rollout jobs move the other
   families here from the component sheet. */
html[data-theme="minimal"] {
	color-scheme: light;
	/* Three background layers (UX-161, UI-84): a white page, light
	   grey cards on it (boxes, lists, tiles, dialogs: the panel level)
	   and a darker grey frame (the header; the side menu is white again,
	   UI-90). Page to card 1.11:1, card to frame 1.12:1, as the steps of
	   Dark. Fields and other
	   input controls are white on the card (--color-field), and so are
	   menus, popovers and messages (--color-raised-surface) and the rows
	   of a list (--p-item and --color-row-fill, UI-88): a list is a grey
	   container with white rows, as in the classic themes. A hover is
	   darker than its card; a sunken surface (open row, table head) is
	   lighter, towards the page, as in Dark. Hairline borders and one
	   accent: Treetops green, a deep forest green for actions, focus and
	   the active state. The organisation colour only marks the
	   organisation switcher; it never carries text. */
	--p-mainmenu: #e6e6ea;
	--p-surface-1: #ffffff;
	--p-surface-2: #f9f9fb;
	--p-surface-3: #f3f3f6;
	--p-surface-4: #dcdde2;
	/* The surface of a list row (--color-background-item; tickets and
	   task rows, bill rows, the rows of a box, the member list rows, the
	   time-and-leave rows, Mikron rows): white in its grey container
	   (UI-88), the card in Dark. Its hover is the row hover. A row that
	   stands on its container paints it through --color-row-fill. */
	--p-item: #ffffff;
	--p-item-low: #ffffff;
	--p-item-low-hover: #e8e8ec;
	--p-item-high: #ffffff;
	--p-item-high-hover: #e8e8ec;
	--p-text-1: #17181c;
	--p-text-2: #5f6370;
	/* Field edges and quiet controls: 3.85:1 on white (a field), 3.48:1 on
	   the card #f3f3f6. */
	--p-control: #7d828d;
	--p-placeholder: #6b6f7a;
	--p-accent: #18794e;
	/* The status inks of text, amounts, the danger button and red text
	   (UI-55, answer 5). */
	--p-success-bright: #e3f5ea;
	--p-success-dark: #15803d;
	--p-warning-bright: #fff4d6;
	--p-warning-dark: #b45309;
	--p-error-bright: #fde8e6;
	--p-error-dark: #c43b31;
	--p-shadow-xs: 0 1px 2px rgba(17, 19, 26, 0.05), 0 1px 1px rgba(17, 19, 26, 0.03);
	--p-ui-panel: #f3f3f6;
	/* The hairline: 1.26:1 on the card, 1.40:1 on the page. */
	--p-ui-panel-border: #d9dadf;
	--p-ui-hover: #e8e8ec;
	--p-menu-text: #3c3f47;
	--p-menu-shell: #ececf0;
	/* A hover in the frame is lighter than the frame, as in Dark. */
	--p-menu-hover: #f3f3f6;
	--p-menu-active: #ffffff;
	--p-scrollbar-thumb: rgba(23, 24, 28, 0.22);
	--p-progress-fill: #18794e;
	--p-table-border: #d9dadf;
	--p-tooltip-bg: #17181c;
	--p-copied-item: #d8ede0;
	--p-copied-item-hover: #cde6d7;
	/* The primary button is the accent green, not the teal of the default
	   themes (UI-30 keeps a fixed colour, never the organisation colour). */
	--p-button-confirm: #18794e;
	--p-button-confirm-hover: #136640;
	--p-button-confirm-text: #ffffff;
	--p-button-confirm-ink: #146b45;
	/* The selected tint differs from the card (1.20:1) and from the white
	   side menu (1.32:1, UI-90). */
	--p-selected: #cfe5d8;
	--p-lost: #7e22ce;
	--p-lost-bright: #f3e8ff;
	--p-shadow-md: 0 4px 12px rgba(17, 19, 26, .08), 0 1px 3px rgba(17, 19, 26, .06);
	--p-shadow-lg: 0 16px 40px rgba(17, 19, 26, .16), 0 2px 8px rgba(17, 19, 26, .08);

	/* Type. Inter (SIL Open Font License 1.1, public/fonts/Inter-LICENSE.txt;
	   the @font-face is in style.css). The scale starts at 12 px: the 11 px
	   and 12 px steps of the default themes move up by one pixel (UI-55,
	   answer 6), so no text of the theme is smaller than 12 px. */
	--p-font-body-line: 20px;
	--p-font-ui-family: "Inter", system-ui, -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
	--p-font-display-family: "Inter", system-ui, -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
	--p-font-size-xs: 12px;
	--p-font-size-sm: 13px;
	/* The lead figure: one key number per page (the first value of a tile
	   strip, the dashboard hours, the gross total of the bill editor),
	   32/40 px, tabular. */
	--font-size-display: 32px;

	/* A selected item (side menu, member list, split list): a quiet accent
	   tint and an accent bar. The bar and the semibold label carry the
	   state, so it does not depend on the tint alone. */
	--color-selected: var(--p-selected);
	--color-selected-mark: var(--color-border-highlight);
	/* Keyboard focus of buttons, rows and links: a 2 px ring in the text
	   colour (UI-38). Fields show the accent edge instead. */
	--color-focus: var(--color-text-primary);
	/* The status "Lost" of a bill (status 2). */
	--color-status-lost: var(--p-lost);
	--color-status-lost-bright: var(--p-lost-bright);
	--color-bill-purple: var(--color-status-lost);
	/* The ink of a status badge on its tint (family 20): the status ink of
	   the text. Each has 4.5:1 or more on its tint in Dark and the warning
	   ink also in Light; the Light block below sets the two that do not. */
	--color-badge-success-ink: var(--color-success-dark);
	--color-badge-warning-ink: var(--color-warning-dark);
	--color-badge-danger-ink: var(--color-error-dark);
	/* The hover surface of red text (the quiet danger button, a destructive
	   menu entry): the error tint. Red text keeps 4.5:1 on it in Dark
	   (6.06:1). */
	--color-danger-hover: var(--color-error-bright);
	/* The priority badge of a ticket row and the track of a progress bar. */
	--color-priority-badge-ink: #b42318;
	--color-progress-track: var(--color-background-quaternary);
	/* The surface of fields and input controls (text fields, selects, text
	   areas, check boxes, radios, the pressed segment of a segmented switch
	   and of the calendar view switch): the panel in Dark, white on the grey
	   card in Light (the Light block below). */
	--color-field: var(--color-ui-panel);
	/* The surface of dropdown menus, select lists, the time list, popovers
	   (help, chart settings) and messages, the layers above the page (not
	   tooltips, which keep the tooltip surface). The panel in Dark, white in
	   Light (UI-87, the Light block below). Their entries keep the hover
	   surface. */
	--color-raised-surface: var(--color-ui-panel);
	/* The surface of the side menu (family 2) and the hover of its
	   entries: the frame and the menu hover in Dark; in Light white with
	   the row hover (UI-90, the Light block below), while the header keeps
	   the frame. The hairline at its right edge stays. */
	--color-sidemenu: var(--color-background-mainmenu);
	--color-sidemenu-hover: var(--color-menu-hover);
	/* The surface of the detail area of a box with a list and a detail
	   (family 16: client projects, project and member memberships, the
	   Mikron templates): none in Dark, where the box shows through, and
	   the page in Light (UI-90, the Light block below). The list column,
	   the head and the foot of the box keep the grey card. */
	--color-box-detail: transparent;
	/* The surface of the dashboard lead (the hours box) and of the loading
	   notice of its chart: the page, in both variants (UI-88: white in
	   Light again; UI-84 had the grey card). */
	--color-lead-surface: var(--color-background-primary);
	/* The fill of a row over its grey container (UI-88): none in Dark,
	   where the row shows its container, and the row surface in Light
	   (the Light block below), where the rows are white cards. */
	--color-row-fill: transparent;
	/* The "Create bill" box under the quick filter (owner correction C10):
	   the sunken surface in Dark, the grey card in Light, so that it stands
	   apart from the white page. */
	--color-bill-start-surface: var(--color-background-secondary);
	/* The bars and lines of a loading skeleton: the sunken surface in Dark,
	   the hover grey in Light (1.24:1 on the page, 1.10:1 on the card). */
	--color-skeleton: var(--color-background-secondary);

	/* Elevation exists only for layers above the page: menus (md) and
	   dialogs (lg). Cards, lists and boxes are flat. */
	--shadow-md: var(--p-shadow-md);
	--shadow-lg: var(--p-shadow-lg);
	--motion-fast: 120ms;
	--motion-base: 180ms;
	--ease-standard: cubic-bezier(.2, 0, 0, 1);
	/* The page frame: the side menu column and the content gutter. The
	   content stretches at every width (UI-55, answer 1). */
	--sidebar-width: 232px;
	--page-gutter: var(--space-5xl);
	/* Control heights: buttons and toolbar tools 32 px (UI-38), fields
	   36 px, list rows 48 px, box rows 44 px. */
	--control-height: 32px;
	--field-height: 36px;
	--row-height: 48px;
	--box-row-height: 44px;
	/* A 1 px inner ring that keeps a pale data colour visible (organisation
	   dot, label dot, colour swatch). */
	--shadow-marker: inset 0 0 0 1px rgba(0, 0, 0, .16);
	/* Scrims: behind a dialog, and the lighter one behind a stacked dialog
	   and the narrow side menu. */
	--color-scrim: rgba(10, 11, 14, .55);
	--color-scrim-light: rgba(0, 0, 0, .32);
	/* The edge of a secondary button, a view tool and a bordered icon
	   button: the hairline, because the label and the panel identify the
	   button on the white page. */
	--color-button-edge: var(--color-ui-panel-border);
	--color-button-edge-hover: var(--color-background-quaternary);
	/* The knob of a switch and of the range slider. */
	--color-knob: #ffffff;
	/* Dialog widths (family 28). S: questions, filters and short forms. M:
	   one-column forms. L: a form with an aside (ticket, client, project,
	   an expense with its Processing aside). XL: wizards and wide data.
	   Full: tables. */
	--dialog-s: 440px;
	--dialog-m: 600px;
	--dialog-l: 880px;
	--dialog-xl: 1040px;
	--dialog-full: 1360px;
}

/* The values that only Minimal Light has. They live here, not in the main
   block, so that Minimal Dark needs no copies of the defaults. */
html[data-theme="minimal"]:not([data-theme-variant="dark"]) {
	/* Entity markers that had less than 3:1 on white. */
	--p-entity-client: #1e9450;
	/* The archived marker keeps 3:1 on the grey card (3.16:1). */
	--p-entity-archived: #848995;
	/* The text inks have less than 4.5:1 on their tints in Light (success
	   4.42:1, danger 4.45:1), so a badge alone takes a darker ink: success
	   5.24:1, danger 5.59:1. The warning ink has 4.58:1 on its tint and
	   keeps the default. */
	--color-badge-success-ink: #137337;
	--color-badge-danger-ink: #b42318;
	/* #c43b31 on #fdf0ee has 4.70:1 (on the error tint #fde8e6 it had
	   4.45:1). A surface, not an ink, so the inks of answer 5 stay. */
	--color-danger-hover: #fdf0ee;
	--color-field: #ffffff;
	--color-raised-surface: #ffffff;
	--color-sidemenu: var(--color-background-primary);
	--color-sidemenu-hover: var(--color-ui-hover);
	--color-box-detail: var(--color-background-primary);
	--color-row-fill: var(--color-background-item);
	--color-bill-start-surface: var(--color-ui-panel);
	--color-skeleton: var(--color-ui-hover);
}

/* Colour-vision assistance in Minimal Light: the success pair of the
   default Light theme (style.css), because the shared assistance values
   give a success text colour of less than 3:1 on white. */
html[data-theme="minimal"]:not([data-theme-variant="dark"])[data-cvd="1"] {
	--p-success-bright: #dff5ec;
	--p-success-dark: #16845c;
}

/* The narrower frame. CSS cannot use custom properties in media queries,
   so the widths are numbers (spec, "Breakpoints"). */
@media (max-width: 1199px) {
	html[data-theme="minimal"] {
		--sidebar-width: 208px;
		--page-gutter: var(--space-3xl);
	}
}

@media (max-width: 599px) {
	html[data-theme="minimal"] {
		--page-gutter: var(--space-xl);
	}
}

@media (prefers-reduced-motion: reduce) {
	html[data-theme="minimal"] {
		--motion-fast: 0ms;
		--motion-base: 0ms;
	}
}

/* Component rules of the family jobs. Each block came from
   dev/design/component_sheet/proposed.css (deleted after rollout job 8,
   when it held no rule) in the order of the families;
   every selector has the prefix html[data-theme="minimal"], and a rule
   for one variant has :not([data-theme-variant="dark"]) or
   [data-theme-variant="dark"]. A master rule of style.css that is stronger
   than a rule here is scoped to the other themes with
   :where(html:not([data-theme="minimal"])) in front. :where() keeps the
   specificity of the master rule; the plain html:not() form would add
   (0,1,1) and could win over a rule of a decorative theme file, because
   style.css loads after the theme files (spec, "Where the CSS goes"). */

/*------------------------------
=TYPE OF THE FRAME
The body type and the headings of the third UI climb (style.css keeps
master's rules for the other themes).
------------------------------*/

/* Inter with its alternate digits and the single-storey "a" (cv11, ss03). */
html[data-theme="minimal"] body {
	font-feature-settings: "cv11", "ss03";
	-webkit-font-smoothing: antialiased;
}

/* reset.css gives fields and input buttons a generic sans-serif; they take
   the UI font. :where() keeps the specificity of the element (0,0,1), so
   every rule of style.css still wins. */
:where(html[data-theme="minimal"]) :is(select, input, textarea) {
	font-family: var(--font-ui-family);
}

/* :where() keeps the specificity of this rule at (0,1,1). It wins over the
   element rule "h1, h2" and over a rule with one class only. A heading
   rule of style.css with an ID, two classes or a class and an element
   (".modalHeader > h2") still wins, because style.css loads later. */
html[data-theme="minimal"] :where(h1, h2) {
	font-size: var(--font-size-3xl);
	font-weight: 600;
	letter-spacing: -.02em;
}

html[data-theme="minimal"] :where(h3) {
	font-weight: 600;
	letter-spacing: -.01em;
}

/*------------------------------
=PAGE FRAME
Replaces: the padding of #content and, in =RESPONSIVE OVERRIDES, the rules
of #cssmenu, #cssmenu-body and .menu-icon-container for a window height of
720 px or less. style.css scopes these height rules to the other themes, so
the side menu stays at the top and an uploaded logo stays visible. The
entry padding of the height rules is weaker than the rules of family 2.
Family 2 replaces the 900 px width rules of #cssmenu. The 30 px bottom
padding of #content at 900 px or less applies in every theme.
------------------------------*/

/* The content column takes the free width at every window width (UI-55,
   answer 1: no cap at 1600 px). The gutter is 40 px (24 px under 1200 px,
   16 px under 600 px). */
html[data-theme="minimal"] #content {
	box-sizing: border-box;
	font-size: var(--font-size-md);
	padding-top: var(--space-3xl);
	padding-left: var(--page-gutter);
	padding-right: var(--page-gutter);
}

/*------------------------------
=1 APP HEADER (shell, shared with Skeleton)
Replaces: header, .header-top, #header-left/-center/-right, .appname,
header .menu-button and its trigger rules (style.css =HEADER).
------------------------------*/

/* The app header of layout.erb (the one with .header-top). The login page
   has a header of its own, and the calendar library writes its day heads
   as header elements; neither takes this rule. */
html[data-theme="minimal"] header:where(:has(> .header-top)) {
	position: relative;
	z-index: 3;
	background-color: var(--color-background-mainmenu);
	border-bottom: 1px solid var(--color-ui-panel-border);
}

/* Character option 3 (UI-55, answer 23): a 3 px top edge in the
   organisation colour. It lies over the empty top of the 48 px bar, so the
   header keeps its height. Only the header of the organisation area has
   the edge: layout.erb writes data-org-edge there (not in the user area
   and not on the login page). The colour is data: when it has less than
   3:1 on the shell of a theme, the attribute names that theme
   (data-org-edge="ring-light", "ring-dark" or both; one token per theme,
   so a theme switch without a reload stays right), and the edge gets a 1 px
   marker line in the control colour at its bottom (3.10:1 on the Light
   shell, 4.52:1 on the Dark shell). The organisation name in the switcher
   carries the meaning; the edge is the second signal. */
html[data-theme="minimal"] header[data-org-edge]::before {
	content: "";
	position: absolute;
	top: 0;
	right: 0;
	left: 0;
	z-index: 1;
	height: 3px;
	background-color: var(--color-org-global);
	pointer-events: none;
}

html[data-theme="minimal"]:not([data-theme-variant="dark"]) header[data-org-edge~="ring-light"]::before,
html[data-theme="minimal"][data-theme-variant="dark"] header[data-org-edge~="ring-dark"]::before {
	box-shadow: inset 0 -1px 0 var(--color-control);
}

html[data-theme="minimal"] .header-top {
	display: flex;
	align-items: center;
	height: 48px;
	background-color: transparent;
}

/* The 7 px strip under the bar of the other themes goes. */
html[data-theme="minimal"] #header-bottom-container {
	display: none;
}

html[data-theme="minimal"] #header-center {
	order: -1;
	flex: 0 0 var(--sidebar-width);
	box-sizing: border-box;
	padding-left: var(--space-xl);
	text-align: left;
}

html[data-theme="minimal"] #header-left {
	flex: 1 1 auto;
	min-width: 0;
	padding-left: var(--space-sm);
}

html[data-theme="minimal"] #header-right {
	flex: 0 1 auto;
	min-width: 0;
	padding-right: var(--space-lg);
}

html[data-theme="minimal"] .appname {
	margin-bottom: 0;
	font: 400 22px/1 'Pacifico', Helvetica, sans-serif;
	opacity: 1;
}

html[data-theme="minimal"] .appname:hover {
	opacity: .8;
}

/* One wordmark at every width; the second, larger copy for phones goes. */
html[data-theme="minimal"] #header-center .appname.bigtext {
	display: block;
}

html[data-theme="minimal"] #header-center .appname.smalltext {
	display: none;
}

html[data-theme="minimal"] .appname a {
	color: var(--color-button-confirm-ink);
	text-decoration: none;
}

html[data-theme="minimal"] .appname a:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
	border-radius: var(--radius-sm);
}

html[data-theme="minimal"] #org_info {
	align-items: center;
}

html[data-theme="minimal"] header .menu-button {
	position: relative;
	display: flex;
	align-items: center;
	height: auto;
	padding: 0;
	border: 0;
	border-radius: var(--radius-md);
	background: transparent;
	color: var(--color-text-primary);
	font-weight: 500;
	transition: none;
}

html[data-theme="minimal"] header .menu-button .menu-text {
	height: auto;
	padding-top: 0;
}

/* The trigger is the visible button: 32 px high, an optional leading mark,
   the name and a chevron. */
html[data-theme="minimal"] header .menu-button > .menu-trigger {
	display: flex;
	align-items: center;
	gap: var(--space-sm);
	box-sizing: border-box;
	max-width: 100%;
	height: var(--control-height);
	padding: 0 var(--space-sm);
	border: 0;
	border-radius: var(--radius-md);
	background: transparent;
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	font-weight: 500;
	line-height: 20px;
	white-space: nowrap;
	cursor: pointer;
	transition: background-color var(--motion-fast) ease;
}

html[data-theme="minimal"] header .menu-button > .menu-trigger > .bigtext {
	overflow: hidden;
	text-overflow: ellipsis;
}

html[data-theme="minimal"] header .menu-button > .menu-trigger:hover,
html[data-theme="minimal"] header .menu-button.open > .menu-trigger {
	background-color: var(--color-menu-hover);
}

html[data-theme="minimal"] header .menu-button > .menu-trigger:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
}

/* The organisation colour is a 10 px marker before the name. It is data, so
   an inset ring keeps a pale colour visible; the name carries the meaning. */
html[data-theme="minimal"] header .header-organization-switcher .menu-trigger::before {
	content: "";
	flex: 0 0 10px;
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background-color: var(--color-org-global);
	box-shadow: var(--shadow-marker);
}

html[data-theme="minimal"] header .menu-button > .menu-trigger::after {
	content: "";
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	background-color: var(--color-text-secondary);
	-webkit-mask: url(/icons/ui/chevron-down.svg) center / 14px no-repeat;
	mask: url(/icons/ui/chevron-down.svg) center / 14px no-repeat;
	transition: transform var(--motion-base) var(--ease-standard);
}

html[data-theme="minimal"] header .menu-button.open > .menu-trigger::after {
	transform: rotate(180deg);
}

/* The user button: the initials in a 28 px circle, then the name. */
html[data-theme="minimal"] header .header-user-switcher .menu-trigger {
	padding-left: var(--space-2xs);
}

html[data-theme="minimal"] header .header-user-switcher .menu-trigger > .smalltext {
	display: inline-flex;
	order: -1;
	flex: 0 0 28px;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	border-radius: var(--radius-pill);
	background-color: var(--color-background-quaternary);
	color: var(--color-text-primary);
	font-size: var(--font-size-xs);
	font-weight: 600;
	letter-spacing: 0;
}

html[data-theme="minimal"] header .header-organization-switcher .menu-trigger > .smalltext {
	display: none;
}

/* The arrow to the dashboard is not needed: the side menu has Dashboard in
   every width (as an overlay under 900 px). */
html[data-theme="minimal"] #org_info > a {
	display: none;
}

@media (max-width: 899px) {
	/* Room for the menu button at the left edge of the header. */
	html[data-theme="minimal"] #header-center {
		flex: 0 0 auto;
		padding-left: 52px;
		padding-right: var(--space-sm);
	}
}

@media (max-width: 599px) {
	/* The organisation shows its short name, the user only the initials. */
	html[data-theme="minimal"] header .header-organization-switcher .menu-trigger > .bigtext,
	html[data-theme="minimal"] header .header-user-switcher .menu-trigger > .bigtext {
		display: none;
	}

	html[data-theme="minimal"] header .header-organization-switcher .menu-trigger > .smalltext {
		display: inline;
	}

	html[data-theme="minimal"] #header-left {
		padding-left: 0;
	}

	html[data-theme="minimal"] #header-right {
		padding-right: var(--space-sm);
	}
}

/*------------------------------
=2 SIDE MENU AND ITS NARROW FORM (shell, shared with Skeleton)
Replaces: #cssmenu, #cssmenu-body a, li.active, .menu-icon, #cssmenu-button
and the 900 px rules of =RESPONSIVE OVERRIDES.
------------------------------*/

html[data-theme="minimal"] #cssmenu {
	flex: 0 0 var(--sidebar-width);
	box-sizing: border-box;
	min-width: auto;
	max-width: none;
	overflow-y: auto;
	padding: var(--space-lg) var(--space-sm);
	border-right: 1px solid var(--color-ui-panel-border);
	background: var(--color-sidemenu);
	font-size: var(--font-size-md);
}

html[data-theme="minimal"] #cssmenu-body ul {
	display: flex;
	flex-direction: column;
	gap: var(--space-3xs);
	margin: 0;
	list-style: none;
}

/* The entries draw their own hover and selected surfaces; the list items
   of the other themes (a hairline, a hover fill, the organisation colour on
   the active entry) are plain. */
html[data-theme="minimal"] #cssmenu-body ul li,
html[data-theme="minimal"] #cssmenu-body ul li:hover,
html[data-theme="minimal"] #cssmenu-body ul li.active {
	z-index: auto;
	border-top: 0;
	background: none;
	cursor: auto;
}

html[data-theme="minimal"] #cssmenu-body a {
	position: relative;
	display: flex;
	align-items: center;
	gap: var(--space-md);
	height: 36px;
	padding: 0 var(--space-md) 0 var(--space-lg);
	border-radius: var(--radius-md);
	color: var(--color-menu-text);
	font-weight: 500;
	line-height: 20px;
	text-decoration: none;
	text-transform: none;
	transition: background-color var(--motion-fast) ease;
}

html[data-theme="minimal"] #cssmenu-body .logout-button {
	padding: var(--space-sm) var(--space-md);
	text-transform: none;
}

html[data-theme="minimal"] #cssmenu-body ul li:hover > a {
	background: var(--color-sidemenu-hover);
	color: var(--color-text-primary);
}

html[data-theme="minimal"] #cssmenu-body a:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: -2px;
}

/* style.css hides the icons of the menu entries in the other themes. */
html[data-theme="minimal"] .menu-icon {
	display: block;
	flex: 0 0 18px;
	width: 18px;
	height: 18px;
	background-color: currentColor;
	opacity: 1;
	-webkit-mask: var(--menu-icon) center / 18px no-repeat;
	mask: var(--menu-icon) center / 18px no-repeat;
}

html[data-theme="minimal"] .menu-icon-dashboard { --menu-icon: url(/icons/ui/dashboard.svg); }
html[data-theme="minimal"] .menu-icon-clock { --menu-icon: url(/icons/ui/clock.svg); }
html[data-theme="minimal"] .menu-icon-calendar { --menu-icon: url(/icons/ui/calendar.svg); }
html[data-theme="minimal"] .menu-icon-ticket { --menu-icon: url(/icons/ui/ticket.svg); }
html[data-theme="minimal"] .menu-icon-folder { --menu-icon: url(/icons/ui/folder.svg); }
html[data-theme="minimal"] .menu-icon-briefcase { --menu-icon: url(/icons/ui/briefcase.svg); }
html[data-theme="minimal"] .menu-icon-tag { --menu-icon: url(/icons/ui/tag.svg); }
html[data-theme="minimal"] .menu-icon-receipt { --menu-icon: url(/icons/ui/receipt.svg); }
html[data-theme="minimal"] .menu-icon-users { --menu-icon: url(/icons/ui/users.svg); }
html[data-theme="minimal"] .menu-icon-settings { --menu-icon: url(/icons/ui/settings.svg); }
html[data-theme="minimal"] .menu-icon-building { --menu-icon: url(/icons/ui/building.svg); }

/* The selected pattern: tint, a 3 px accent bar at the left and a semibold
   label. The same pattern marks the selected member and the selected
   project of a split box. */
html[data-theme="minimal"] #cssmenu-body ul li.active > a {
	background: var(--color-selected);
	box-shadow: none;
	color: var(--color-text-primary);
	font-weight: 600;
}

html[data-theme="minimal"] #cssmenu-body ul li.active > a::before {
	content: "";
	position: absolute;
	top: 8px;
	bottom: 8px;
	left: 0;
	width: 3px;
	border-radius: 0 3px 3px 0;
	background-color: var(--color-selected-mark);
}

html[data-theme="minimal"] #cssmenu-body ul li.active .menu-icon {
	background-color: var(--color-button-confirm-ink);
}

html[data-theme="minimal"][data-theme-variant="dark"] #cssmenu-body ul li.active .menu-icon {
	background-color: var(--color-border-highlight);
}

/* An uploaded logo stands small above the entries. */
html[data-theme="minimal"] .menu-icon-container {
	width: 40px;
	height: 40px;
	margin: var(--space-2xs) var(--space-lg) var(--space-xl);
	border-radius: var(--radius-lg);
	overflow: hidden;
}

/* Without an uploaded logo the placeholder takes no room: the header
   already names the organisation. */
html[data-theme="minimal"] .menu-icon-container:has(> .menu-office-icon, > .menu-user-icon) {
	display: none;
}

html[data-theme="minimal"] #cssmenu-button-container {
	display: none;
}

@media (max-width: 899px) {
	/* The menu becomes an overlay. A 32 px menu button stands at the left of
	   the header; the old tab at the left edge of the content is gone. */
	html[data-theme="minimal"] #cssmenu {
		display: none;
		position: fixed;
		top: 0;
		bottom: 0;
		left: 0;
		z-index: 500;
		width: min(280px, calc(100vw - 48px));
		height: 100%;
		padding-top: 56px;
		border-right: 0;
		box-shadow: var(--shadow-lg), 0 0 0 100vmax var(--color-scrim-light);
	}

	html[data-theme="minimal"] #cssmenu-button-container {
		display: flex;
		position: fixed;
		top: 8px;
		left: var(--space-sm);
		z-index: 501;
		height: auto;
	}

	html[data-theme="minimal"] #cssmenu-button {
		display: flex;
		align-items: center;
		justify-content: center;
		width: var(--control-height);
		height: var(--control-height);
		border-radius: var(--radius-md);
		background-color: transparent;
		color: var(--color-text-primary);
		cursor: pointer;
	}

	html[data-theme="minimal"] #cssmenu-button:hover {
		background-color: var(--color-menu-hover);
	}

	html[data-theme="minimal"] #cssmenu-button:focus-visible {
		outline: 2px solid var(--color-focus);
		outline-offset: 2px;
	}

	/* Three 2 px lines, drawn in the text colour. The rollout can replace
	   them with a menu icon in public/icons/ui/. */
	html[data-theme="minimal"] #cssmenu-button > span {
		color: inherit;
		flex: 0 0 18px;
		width: 18px;
		height: 14px;
		font-size: 0;
		background:
			linear-gradient(currentColor, currentColor) 0 0 / 100% 2px no-repeat,
			linear-gradient(currentColor, currentColor) 0 6px / 100% 2px no-repeat,
			linear-gradient(currentColor, currentColor) 0 12px / 100% 2px no-repeat;
	}
}

/*------------------------------
=3 DROPDOWN MENUS (shell, shared with Skeleton)
Replaces: header .menu, .accordion .menu, .item .menu and their item rules,
.menu-divider, .menu-action-create.
------------------------------*/

/* The menu panel: the raised surface (white in Light, the panel in Dark;
   UI-87), a hairline and the menu shadow. */
html[data-theme="minimal"] .absence-entry-group .menu,
html[data-theme="minimal"] header .menu, html[data-theme="minimal"] .accordion .menu, html[data-theme="minimal"] .item .menu {
	box-sizing: border-box;
	width: 220px;
	max-width: calc(100vw - 20px);
	padding: var(--space-2xs);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-md);
	background: var(--color-raised-surface);
	box-shadow: var(--shadow-md);
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	font-weight: 400;
	line-height: 20px;
	text-align: left;
}

html[data-theme="minimal"] header .menu {
	top: 100%;
	margin-top: var(--space-2xs);
}

/* A row menu hangs below its trigger, right-aligned to it. */
html[data-theme="minimal"] .accordion .menu-button, html[data-theme="minimal"] .item .menu-button {
	position: relative;
}

html[data-theme="minimal"] .accordion .menu, html[data-theme="minimal"] .item .menu {
	position: absolute;
	top: calc(100% + var(--space-2xs));
	right: 0;
	margin-top: 0;
	z-index: 1000;
}

html[data-theme="minimal"] .absence-entry-group .menu > button,
html[data-theme="minimal"] header .menu > a > div, html[data-theme="minimal"] header .menu > details > summary, html[data-theme="minimal"] header .menu > form > button, html[data-theme="minimal"] header .menu > button,
html[data-theme="minimal"] .accordion .menu > :is(div, button), html[data-theme="minimal"] .item .menu > :is(div, button) {
	display: flex;
	box-sizing: border-box;
	align-items: center;
	gap: var(--space-sm);
	width: 100%;
	min-height: 34px;
	padding: 7px var(--space-md);
	border: 0;
	border-radius: var(--radius-sm);
	background: transparent;
	color: inherit;
	font: inherit;
	line-height: 20px;
	text-align: left;
	white-space: normal;
	overflow-wrap: anywhere;
	cursor: pointer;
}

html[data-theme="minimal"] header .menu > a:hover > div,
html[data-theme="minimal"] header .menu > details > summary:hover,
html[data-theme="minimal"] header .menu > form > button:hover,
html[data-theme="minimal"] header .menu > button:hover,
html[data-theme="minimal"] .accordion .menu > :is(div, button):hover,
html[data-theme="minimal"] .item .menu > :is(div, button):hover,
html[data-theme="minimal"] .absence-entry-group .menu > button:hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] header .menu > a:focus-visible,
html[data-theme="minimal"] header .menu > :is(button, form > button):focus-visible,
html[data-theme="minimal"] .accordion .menu > button:focus-visible,
html[data-theme="minimal"] .item .menu > button:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: -2px;
	border-radius: var(--radius-sm);
}

/* Each organisation row has an 8 px marker slot; the current organisation
   fills it with its colour, is semibold and ends with a check mark. */
html[data-theme="minimal"] header .header_menu_left > a > div::before {
	content: "";
	flex: 0 0 8px;
	width: 8px;
	height: 8px;
	border-radius: 50%;
}

html[data-theme="minimal"] header .menu > a[aria-current="page"] > div {
	background-color: transparent;
	font-weight: 600;
}

html[data-theme="minimal"] header .menu > a[aria-current="page"] > div::before {
	background-color: var(--color-org-global);
	box-shadow: var(--shadow-marker);
}

html[data-theme="minimal"] header .menu > a[aria-current="page"] > div::after {
	content: "";
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	margin-left: auto;
	background-color: var(--color-button-confirm-ink);
	-webkit-mask: url(/icons/ui/check-circle.svg) center / 16px no-repeat;
	mask: url(/icons/ui/check-circle.svg) center / 16px no-repeat;
}

html[data-theme="minimal"] .menu-divider {
	height: 1px;
	margin: var(--space-2xs) calc(-1 * var(--space-2xs));
	padding: 0;
	border: 0;
	background: var(--color-ui-panel-border);
}

html[data-theme="minimal"] .menu-action-create::before {
	content: "";
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	background-color: var(--color-text-secondary);
	-webkit-mask: url(/icons/ui/plus.svg) center / 16px no-repeat;
	mask: url(/icons/ui/plus.svg) center / 16px no-repeat;
}

/* A destructive entry of a row menu (Delete) is red text with a red tint
   on hover. */
html[data-theme="minimal"] :is(.accordion, .item) .menu > button:is([data-method="destroy"], .cancelbill, .deletebill) {
	color: var(--color-action-danger-ink);
}

html[data-theme="minimal"] :is(.accordion, .item) .menu > button:is([data-method="destroy"], .cancelbill, .deletebill):hover {
	background-color: var(--color-danger-hover);
}

/* The row menu trigger: a 32 px button with the three-dot icon. The
   background shorthand clears the pictogram of the other themes. */
html[data-theme="minimal"] .absence-entry-group .menu-button,
html[data-theme="minimal"] .accordion .menu-button, html[data-theme="minimal"] .item .menu-button {
	position: relative;
	float: none;
	flex: 0 0 32px;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	min-width: 32px;
	height: 32px;
	border-radius: var(--radius-md);
	background: none;
	color: var(--color-text-secondary);
}

html[data-theme="minimal"] .absence-entry-group .menu-button > .menu-trigger,
html[data-theme="minimal"] .accordion .menu-button > .menu-trigger, html[data-theme="minimal"] .item .menu-button > .menu-trigger {
	width: 32px;
	height: 32px;
	border-radius: var(--radius-md);
	font-size: 0;
	color: transparent;
	background-color: var(--color-text-secondary);
	-webkit-mask: url(/icons/ui/more.svg) center / 18px no-repeat;
	mask: url(/icons/ui/more.svg) center / 18px no-repeat;
}

html[data-theme="minimal"] .absence-entry-group .menu-button:hover,
html[data-theme="minimal"] .accordion .menu-button:hover, html[data-theme="minimal"] .item .menu-button:hover,
html[data-theme="minimal"] .accordion .menu-button.open, html[data-theme="minimal"] .item .menu-button.open {
	background-color: var(--color-background-quaternary);
}

html[data-theme="minimal"] .absence-entry-group .menu-button:hover > .menu-trigger,
html[data-theme="minimal"] .accordion .menu-button:is(:hover, .open) > .menu-trigger,
html[data-theme="minimal"] .item .menu-button:is(:hover, .open) > .menu-trigger {
	background-color: var(--color-text-primary);
}

/* The mask hides an outline, so the focus ring is on the wrapper. */
html[data-theme="minimal"] .accordion .menu-button:has(> .menu-trigger:focus-visible),
html[data-theme="minimal"] .item .menu-button:has(> .menu-trigger:focus-visible) {
	outline: 2px solid var(--color-focus);
	outline-offset: 0;
}

/* The language entry of the user menu (details.header-language-control):
   an entry like the others with a 16 px globe, the current language and a
   chevron that turns down when the list is open; the languages follow as
   entries indented to the text, the current one in 600 with a check in the
   accent ink. The flags go (the names are enough). */
html[data-theme="minimal"] header .menu .header-language-control {
	margin: 0;
	padding: 0;
	border: 0;
}

html[data-theme="minimal"] header .menu .header-language-control > summary {
	display: flex;
	align-items: center;
	gap: var(--space-sm);
	box-sizing: border-box;
	min-height: 34px;
	padding: 7px var(--space-md);
	border-radius: var(--radius-sm);
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	line-height: 20px;
	list-style: none;
	cursor: pointer;
}

html[data-theme="minimal"] header .menu .header-language-control > summary::-webkit-details-marker {
	display: none;
}

html[data-theme="minimal"] header .menu .header-language-control > summary::before {
	content: "";
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	background-color: var(--color-text-secondary);
	-webkit-mask: url(/icons/ui/globe.svg) center / 16px no-repeat;
	mask: url(/icons/ui/globe.svg) center / 16px no-repeat;
}

/* The border, margin and turn reset the drawn chevron of the other themes
   (style.css), which the icon replaces. */
html[data-theme="minimal"] header .menu .header-language-control > summary::after {
	content: "";
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	margin: 0 0 0 auto;
	border: 0;
	background-color: var(--color-text-secondary);
	transform: none;
	-webkit-mask: url(/icons/ui/chevron-right.svg) center / 16px no-repeat;
	mask: url(/icons/ui/chevron-right.svg) center / 16px no-repeat;
	transition: transform var(--motion-base) var(--ease-standard);
}

html[data-theme="minimal"] header .menu .header-language-control[open] > summary::after {
	transform: rotate(90deg);
}

html[data-theme="minimal"] header .menu .header-language-control[open] {
	margin-bottom: var(--space-2xs);
	padding-bottom: var(--space-2xs);
	border-bottom: 1px solid var(--color-ui-panel-border);
}

html[data-theme="minimal"] header .menu .header-language-control > summary:hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] header .menu .header-language-control > summary:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: -2px;
}

html[data-theme="minimal"] header .menu .header-language-control :is(.language-flag-circle, .language-flag),
html[data-theme="minimal"] .header-language-control--login :is(.language-flag-circle, .language-flag) {
	display: none;
}

html[data-theme="minimal"] header .menu .header-language-menu {
	position: static;
	display: flex;
	flex-direction: column;
	margin: 0;
	padding: 0;
	border: 0;
	background: transparent;
	box-shadow: none;
}

html[data-theme="minimal"] header .menu .header-language-menu button,
html[data-theme="minimal"] .header-language-control--login .header-language-menu button {
	display: flex;
	align-items: center;
	box-sizing: border-box;
	width: 100%;
	min-height: 34px;
	padding: 7px var(--space-md) 7px 34px;
	border: 0;
	border-radius: var(--radius-sm);
	background: transparent;
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	line-height: 20px;
	text-align: left;
	cursor: pointer;
}

html[data-theme="minimal"] header .menu .header-language-menu button:hover,
html[data-theme="minimal"] .header-language-control--login .header-language-menu button:hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] header .menu .header-language-menu button[aria-current="true"],
html[data-theme="minimal"] .header-language-control--login .header-language-menu button[aria-current="true"] {
	font-weight: 600;
}

html[data-theme="minimal"] header .menu .header-language-menu .language-current,
html[data-theme="minimal"] .header-language-control--login .header-language-menu .language-current {
	width: 16px;
	height: 16px;
	margin-left: auto;
	background-color: var(--color-button-confirm-ink);
	color: transparent;
	-webkit-mask: url(/icons/ui/check.svg) center / 16px no-repeat;
	mask: url(/icons/ui/check.svg) center / 16px no-repeat;
}

html[data-theme="minimal"][data-theme-variant="dark"] header .menu .header-language-menu .language-current,
html[data-theme="minimal"][data-theme-variant="dark"] .header-language-control--login .header-language-menu .language-current {
	background-color: var(--color-border-highlight);
}

/*------------------------------
=4 PAGE HEADER AND TOOLBAR (shell, shared with Skeleton)
Replaces: .content_header, .content_header_title h2, .content_header_menu,
.content_header_menu_item, .content_new_ressource (style.css =UI: CONTENT
SHELL).
------------------------------*/

html[data-theme="minimal"] .content_header {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-lg);
	min-height: var(--control-height);
	margin-bottom: var(--space-xl);
}

html[data-theme="minimal"] .content_header_title {
	flex: 1 1 auto;
	min-width: 0;
}

html[data-theme="minimal"] .content_header_title h2,
html[data-theme="minimal"] .dashboard-titlebar h2,
html[data-theme="minimal"] .settings-page > h2 {
	padding: 0;
	font-size: var(--font-size-3xl);
	font-weight: 600;
	line-height: 32px;
	letter-spacing: -.02em;
}

html[data-theme="minimal"] .content_header_menu {
	flex: 0 0 auto;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: normal;
	gap: var(--space-sm);
}

/* A view tool: a 32 px quiet button with a 16 px line icon and a label. */
html[data-theme="minimal"] .content_header_menu_item {
	display: inline-flex;
	flex: 0 1 auto;
	align-self: auto;
	align-items: center;
	justify-content: center;
	gap: var(--space-xs);
	box-sizing: border-box;
	min-width: 32px;
	max-width: none;
	height: var(--control-height);
	padding: 0 var(--space-md) 0 var(--space-sm);
	border: 1px solid var(--color-button-edge);
	border-radius: var(--radius-md);
	background-color: var(--color-ui-panel);
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
	white-space: nowrap;
	cursor: pointer;
	transition: background-color var(--motion-fast) ease, border-color var(--motion-fast) ease;
}

html[data-theme="minimal"] .content_header_menu_item:hover {
	border-color: var(--color-background-quaternary);
	background-color: var(--color-ui-hover);
	color: var(--color-text-primary);
}

html[data-theme="minimal"] .content_header_menu_item:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
}

/* A pressed tool (an archive view, a grouping, an active filter): the
   accent edge (5.41:1 on white), the accent tint and accent text. The edge
   changes from 1.26:1 to 5.41:1, so the state does not depend on hue. */
html[data-theme="minimal"] .content_header_menu_item:is([aria-pressed="true"], :has(> .icon.active)) {
	border-color: var(--color-border-highlight);
	background-color: var(--color-selected);
	color: var(--color-button-confirm-ink);
}

html[data-theme="minimal"][data-theme-variant="dark"] .content_header_menu_item:is([aria-pressed="true"], :has(> .icon.active)) {
	color: var(--color-border-highlight);
}

/* The icon is a mask in the text colour, so the opacity, the filters and
   the hover scale of the pictograms of the other themes do not apply. */
html[data-theme="minimal"] .content_header_menu_item > .icon.settings {
	flex: 0 0 16px;
	width: 16px;
	min-width: 16px;
	height: 16px;
	min-height: 16px;
	background-image: none;
	background-color: currentColor;
	opacity: 1;
	filter: none;
	transform: none;
	-webkit-mask: var(--tool-icon) center / 16px no-repeat;
	mask: var(--tool-icon) center / 16px no-repeat;
}

html[data-theme="minimal"] .content_header_menu_item > .icon.graph-black { --tool-icon: url(/icons/ui/chart.svg); }
html[data-theme="minimal"] .content_header_menu_item > .icon.archive-black { --tool-icon: url(/icons/ui/archive.svg); }
html[data-theme="minimal"] .content_header_menu_item > .icon.office-black { --tool-icon: url(/icons/ui/briefcase.svg); }
html[data-theme="minimal"] .content_header_menu_item > .icon.filter { --tool-icon: url(/icons/ui/filter.svg); }

/* The visible label of a view tool (style.css hides it in the other
   themes). */
html[data-theme="minimal"] .content_header_menu_label {
	display: inline-block;
	padding-right: var(--space-3xs);
	white-space: nowrap;
}

/* Some languages write a shared label in lower case ("par client"). */
html[data-theme="minimal"] .content_header_menu_label::first-letter {
	text-transform: uppercase;
}

/* The primary action of a page: the only filled button of the header. */
html[data-theme="minimal"] .content_new_ressource {
	display: inline-flex;
	flex: 0 1 auto;
	align-self: auto;
	align-items: center;
	gap: var(--space-xs);
	box-sizing: border-box;
	width: auto;
	min-width: auto;
	max-width: none;
	height: var(--control-height);
	min-height: auto;
	margin-top: 0;
	margin-left: var(--space-2xs);
	padding: 0 var(--space-lg) 0 var(--space-md);
	border: 0;
	border-radius: var(--radius-md);
	/* The shorthand also clears the circled "+" of the other themes. */
	background: var(--color-button-confirm);
	box-shadow: var(--shadow-xs);
	color: var(--color-button-confirm-text);
	font-size: var(--font-size-sm);
	font-weight: 600;
	line-height: 18px;
	white-space: nowrap;
	cursor: pointer;
	transition: background-color var(--motion-fast) ease;
}

html[data-theme="minimal"] .content_new_ressource::before {
	content: "";
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	background-color: currentColor;
	-webkit-mask: url(/icons/ui/plus.svg) center / 16px no-repeat;
	mask: url(/icons/ui/plus.svg) center / 16px no-repeat;
}

html[data-theme="minimal"] .content_new_ressource:hover {
	background-color: var(--color-button-confirm-hover);
}

html[data-theme="minimal"] .content_new_ressource:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
}

html[data-theme="minimal"] .content_new_ressource:active {
	transform: translateY(1px);
}

@media (max-width: 599px) {
	/* Two lines: the title and the primary action, then the view tools, which
	   keep their labels and wrap. */
	html[data-theme="minimal"] .content_header_menu {
		display: contents;
	}

	html[data-theme="minimal"] .content_header_title {
		flex: 1 1 0;
	}

	html[data-theme="minimal"] .content_header_title h2,
	html[data-theme="minimal"] .dashboard-titlebar h2 {
		font-size: var(--font-size-2xl);
		line-height: 28px;
	}

	html[data-theme="minimal"] .content_new_ressource {
		order: 1;
		margin-left: 0;
	}

	html[data-theme="minimal"] .content_header::after {
		content: "";
		order: 1;
		flex: 0 0 100%;
		height: 0;
	}

	html[data-theme="minimal"] .content_header_menu_item {
		order: 2;
	}

	html[data-theme="minimal"] .content_header {
		row-gap: var(--space-sm);
		column-gap: var(--space-sm);
	}
}

html[data-theme="minimal"] .dashboard-titlebar {
	min-height: 36px;
	margin-bottom: var(--space-xl);
}


/*------------------------------
=5 QUICK FILTER
Replaces: .resource-search-bar and .resource-search-bar .feedback-input.
------------------------------*/

html[data-theme="minimal"] .resource-search-bar {
	position: relative;
	display: flex;
	align-items: center;
	box-sizing: border-box;
	height: var(--field-height);
	margin: var(--space-3xl) 0;
	border: 1px solid var(--color-control);
	border-radius: var(--radius-md);
	background: var(--color-field);
	box-shadow: none;
	transition: border-color var(--motion-fast) ease;
}

/* Timesheets has a line break after the filter (mikrons/timesheets.erb); it
   would add a text line to the gap below. */
html[data-theme="minimal"] .resource-search-bar + br {
	display: none;
}

html[data-theme="minimal"] .resource-search-bar::before {
	content: "";
	position: absolute;
	top: 9px;
	left: var(--space-lg);
	width: 16px;
	height: 16px;
	background-color: var(--color-text-secondary);
	-webkit-mask: url(/icons/ui/search.svg) center / 16px no-repeat;
	mask: url(/icons/ui/search.svg) center / 16px no-repeat;
	pointer-events: none;
}

html[data-theme="minimal"] .resource-search-bar:hover {
	border-color: var(--color-text-secondary);
}

/* The quick filter has no focus edge: the caret shows the focus (UI-92). */
html[data-theme="minimal"] .resource-search-bar .feedback-input,
html[data-theme="minimal"] .resource-search-bar .feedback-input:focus {
	box-sizing: border-box;
	width: 100%;
	height: 34px;
	margin: 0;
	padding: 0 var(--space-lg) 0 40px;
	border: 0;
	outline: none;
	background: transparent;
	color: var(--color-text-primary);
	font-family: var(--font-ui-family);
	font-size: var(--font-size-md);
	font-weight: 400;
	line-height: 34px;
}

html[data-theme="minimal"] .resource-search-bar .feedback-input::placeholder {
	color: var(--color-placeholder);
	opacity: 1;
}

/*------------------------------
=6 ADD CONTROLS (the circled "+" is retired)
The page-level "+" became the primary action of the page header (family 4).
An add control inside a list or a box is a quiet row with a plus and a label.
Replaces: :is(.outerframe, .accordion-body) .content_new_ressource,
.resource-box-bottom and .resource-add.
------------------------------*/

html[data-theme="minimal"] :is(.outerframe, .accordion-body) .content_new_ressource,
html[data-theme="minimal"] .resource-box-bottom .resource-add {
	display: flex;
	align-items: center;
	gap: var(--space-sm);
	box-sizing: border-box;
	width: auto;
	min-width: 0;
	height: var(--control-height);
	min-height: 0;
	margin: 0;
	padding: 0 var(--space-sm);
	border: 0;
	border-radius: var(--radius-md);
	background: transparent;
	box-shadow: none;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
	cursor: pointer;
}

html[data-theme="minimal"] .resource-box-bottom .resource-add::before {
	content: "";
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	background-color: currentColor;
	-webkit-mask: url(/icons/ui/plus.svg) center / 16px no-repeat;
	mask: url(/icons/ui/plus.svg) center / 16px no-repeat;
}

html[data-theme="minimal"] :is(.outerframe, .accordion-body) .content_new_ressource:hover,
html[data-theme="minimal"] .resource-box-bottom .resource-add:hover {
	background-color: var(--color-ui-hover);
	color: var(--color-text-primary);
}

html[data-theme="minimal"] :is(.outerframe, .accordion-body) .content_new_ressource:focus-visible,
html[data-theme="minimal"] .resource-box-bottom .resource-add:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 0;
}

/*------------------------------
=7 LIST ROWS (accordion headers)
Replaces: .accordion, .accordion-header and its .clickarea, .title,
.subtitle, ::before and ::after rules; the entity bar colours of =UI:
RESOURCE LISTS.
------------------------------*/

html[data-theme="minimal"] .accordion {
	--row-mark: var(--entity-archived);
	color: var(--color-text-primary);
}

html[data-theme="minimal"] .accordion.client { --row-mark: var(--entity-client); }
html[data-theme="minimal"] .accordion.client.internal-client { --row-mark: var(--entity-finance); }
html[data-theme="minimal"] .accordion.timesheet { --row-mark: var(--entity-timesheet); }
html[data-theme="minimal"] .accordion.project { --row-mark: var(--entity-project); }
html[data-theme="minimal"] .accordion.task { --row-mark: var(--entity-task); }
html[data-theme="minimal"] .accordion.category { --row-mark: var(--entity-category); }
html[data-theme="minimal"] .accordion.bill { --row-mark: var(--entity-bill); }
html[data-theme="minimal"] .accordion.archived { --row-mark: var(--entity-archived); }

/* A list is one bordered surface: 48 px rows with hairline dividers and
   8 px outer corners. In Light the rows are grey on the white page, as the
   bars of the default themes stand on their page; the body of an open
   month is grey too and holds white rows (family 8, UI-88). */
html[data-theme="minimal"] .accordion-header {
	display: flex;
	align-items: center;
	gap: var(--space-2xs);
	box-sizing: border-box;
	min-height: var(--row-height);
	height: auto;
	margin-top: 0;
	padding: 0 var(--space-sm) 0 var(--space-lg);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: 0;
	background-color: var(--color-ui-panel);
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	transition: background-color var(--motion-fast) ease;
}

html[data-theme="minimal"] .accordion + .accordion > .accordion-header {
	margin-top: -1px;
}

html[data-theme="minimal"] .accordion:not(.accordion + .accordion) > .accordion-header {
	border-top-left-radius: var(--radius-lg);
	border-top-right-radius: var(--radius-lg);
}

html[data-theme="minimal"] .accordion:not(:has(+ .accordion)) > .accordion-header:not(:has(> .clickarea[aria-expanded="true"])) {
	border-bottom-left-radius: var(--radius-lg);
	border-bottom-right-radius: var(--radius-lg);
}

html[data-theme="minimal"] .accordion-header:hover {
	background-color: var(--color-ui-hover);
}

/* An open row has the sunken tint and a chevron that points down. */
html[data-theme="minimal"] .accordion-header:has(> .clickarea[aria-expanded="true"]) {
	background-color: var(--color-background-secondary);
}

/* A row without a menu keeps the room of the menu, so that the right edges
   of all rows line up. */
html[data-theme="minimal"] .accordion-header:not(:has(> .menu-button)) {
	padding-right: 44px;
}

html[data-theme="minimal"] .accordion-header .clickarea {
	display: flex;
	flex: 1 1 auto;
	align-items: center;
	gap: var(--space-sm);
	align-self: stretch;
	min-width: 0;
	min-height: calc(var(--row-height) - 2px);
	padding: 0;
	border-radius: var(--radius-md);
	cursor: pointer;
	overflow: hidden;
}

html[data-theme="minimal"] .accordion-header .clickarea:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: -2px;
}

/* The disclosure chevron. */
html[data-theme="minimal"] .accordion-header .clickarea::after {
	content: "";
	order: -2;
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	background-color: var(--color-text-secondary);
	-webkit-mask: url(/icons/ui/chevron-down.svg) center / 14px no-repeat;
	mask: url(/icons/ui/chevron-down.svg) center / 14px no-repeat;
	transform: rotate(-90deg);
	transition: transform var(--motion-base) var(--ease-standard);
}

html[data-theme="minimal"] .accordion-header .clickarea[aria-expanded="true"]::after {
	transform: rotate(0deg);
}

/* The entity marker: a 10 px square in the entity colour. A shared (guest)
   item has a hollow marker. */
html[data-theme="minimal"] .accordion-header .clickarea::before {
	content: "";
	order: -1;
	flex: 0 0 10px;
	width: 10px;
	height: 10px;
	box-sizing: border-box;
	border-radius: 3px;
	background-color: var(--row-mark);
}

html[data-theme="minimal"] .accordion:is(.guest-project, .guest-client) .accordion-header .clickarea::before {
	border: 2px solid var(--row-mark);
	background-color: transparent;
}

html[data-theme="minimal"] .accordion-header .title {
	flex: 0 1 auto;
	min-width: 0;
	max-width: none;
	padding: 0;
	overflow: hidden;
	color: var(--color-text-primary);
	font-weight: 550;
	line-height: 20px;
	text-overflow: ellipsis;
	white-space: nowrap;
}

/* The details follow the name after 12 px (the judges preferred inline
   details to a column in the direct comparison of rounds 7 and 8). They
   take the free width after the full name and give way first, so a name is
   cut only when it is longer than the row. */
html[data-theme="minimal"] .accordion-header .subtitle {
	flex: 1 1 0;
	min-width: 0;
	margin-left: var(--space-2xs);
	overflow: hidden;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-style: normal;
	line-height: 18px;
	text-overflow: ellipsis;
	white-space: nowrap;
}

html[data-theme="minimal"] .accordion.archived .accordion-header .title {
	color: var(--color-text-secondary);
}

@media (max-width: 599px) {
	/* The details move to a second line under the name. */
	html[data-theme="minimal"] .accordion-header .clickarea {
		flex-wrap: wrap;
		row-gap: 0;
		align-content: center;
		padding: var(--space-sm) 0;
	}

	/* The name wraps instead of being cut ("Sauerbach Architects — Taxes,
	   expenses and internal projects" needs 424 px). */
	html[data-theme="minimal"] .accordion-header .title {
		flex: 1 1 0;
		max-width: none;
		overflow: visible;
		text-overflow: clip;
		white-space: normal;
	}

	html[data-theme="minimal"] .accordion-header .subtitle {
		flex: 0 0 100%;
		margin-left: 0;
		padding-left: 42px;
		box-sizing: border-box;
		white-space: normal;
	}
}

/*------------------------------
=8 EXPANDED DETAIL PANELS
Replaces: the look of .accordion-body and .accordion-body-inner. The panels
(.accordion-flexcontainer, .accordion-innerflexbox, .resource-panel) keep
the layout of style.css (UI-78).
------------------------------*/

/* One surface under the open row: the page surface (charts are drawn on
   it), 24 px padding, no inner sheet. */
html[data-theme="minimal"] .accordion-body {
	position: relative;
	margin-top: -1px;
	padding: var(--space-3xl);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: 0;
	background: var(--color-background-primary);
	color: var(--color-text-primary);
	transition: opacity var(--motion-base) ease-out;
}

html[data-theme="minimal"] .accordion:not(:has(+ .accordion)) > .accordion-body {
	border-bottom-left-radius: var(--radius-lg);
	border-bottom-right-radius: var(--radius-lg);
}

/* Minimal Light (UI-88): the body of a bill month or a timesheet month
   holds only rows, so it is their grey container (the other open bodies
   stay on the page surface, UI-87). */
html[data-theme="minimal"]:not([data-theme-variant="dark"]) :is(#bills-months, #timesheets-months) > .accordion > .accordion-body {
	background: var(--color-ui-panel);
}

html[data-theme="minimal"] .accordion-body-inner {
	display: flex;
	flex-direction: column;
	gap: var(--space-3xl);
	padding: 0;
	background: transparent;
}

/* The notice at the top of a client panel (the internal client, a client that
   is another Treetops organization): the gap under it equals the gap above
   it (UI-94). The panel is a flex column with its own gap, so the notice
   keeps no bottom margin, and the <br> that client.erb writes after it for
   the other themes (an extra flex item with a line of height, between two
   gaps) is not drawn. */
html[data-theme="minimal"] .accordion.client .accordion-body-inner > .accordion-notice {
	margin-bottom: 0;
}

html[data-theme="minimal"] .accordion.client .accordion-body-inner > .accordion-notice + br {
	display: none;
}

/* Under 600 px the body padding (the gap above) is 16 px and the panel gap
   is 24 px: a negative bottom margin takes the 8 px off. */
@media (max-width: 599px) {
	html[data-theme="minimal"] .accordion.client .accordion-body-inner > .accordion-notice {
		margin-bottom: calc(var(--space-xl) - var(--space-3xl));
	}
}

/* The panels of an open body have the layout of the default themes
   (style.css: their flex parts, minimum widths, heights and order; Treetops
   decision UI-78). This family gives the look. */

/* Loading: a body that waits for its content shows three skeleton lines. */
html[data-theme="minimal"] .accordion-body:empty::before {
	content: "";
	display: block;
	height: 72px;
	border-radius: var(--radius-sm);
	background:
		linear-gradient(var(--color-skeleton), var(--color-skeleton)) 0 0 / 40% 12px no-repeat,
		linear-gradient(var(--color-skeleton), var(--color-skeleton)) 0 28px / 70% 12px no-repeat,
		linear-gradient(var(--color-skeleton), var(--color-skeleton)) 0 56px / 55% 12px no-repeat;
	animation: ds-pulse 1.2s ease-in-out infinite alternate;
}

@keyframes ds-pulse {
	from { opacity: 1; }
	to { opacity: .5; }
}

@media (prefers-reduced-motion: reduce) {
	html[data-theme="minimal"] .accordion-body:empty::before {
		animation: none;
	}
}

@media (max-width: 599px) {
	html[data-theme="minimal"] .accordion-body {
		padding: var(--space-xl);
	}
}

/*------------------------------
=8 (continued) THE MIKRON ROWS OF A TIMESHEET MONTH
Replaces: .ts_mikron_wrapper, .ts_mikron, .ts_mikron_seperatorline,
.reviewstatus, .reviewsymbol, .processed, .ts_flex, .mikron.info, .mikron.date,
.mikron.desc, .ts_mikron_fwd, .mikron_directforwardarrow.
------------------------------*/

/* The rows of a month form one list: 56 px rows with dividers, on the
   row surface. */
html[data-theme="minimal"] .ts_mikron_wrapper {
	border-top: 1px solid var(--color-ui-panel-border);
	background: var(--color-background-item);
}

html[data-theme="minimal"] .ts_mikron_wrapper:first-child {
	border-top: 0;
}

html[data-theme="minimal"] .ts_mikron_seperatorline {
	display: none;
}

html[data-theme="minimal"] .ts_mikron {
	margin: 0;
	padding: var(--space-sm) var(--space-sm) var(--space-sm) var(--space-lg);
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
	transition: background-color var(--motion-fast) ease;
}

html[data-theme="minimal"] .ts_mikron:hover {
	background-color: var(--color-ui-hover);
}

/* Minimal Light (UI-88): in the grey body of the month the rows are white
   cards 4 px apart, with a hairline and 6 px corners. The divider stays
   as a transparent edge, so a row keeps its height, and makes the 3 px
   margin a 4 px gap; the ring is on the row inside the wrapper, so that
   its hover keeps it. */
html[data-theme="minimal"]:not([data-theme-variant="dark"]) .ts_mikron_wrapper {
	border-top-color: transparent;
	border-radius: var(--radius-md);
	background-clip: padding-box;
}

html[data-theme="minimal"]:not([data-theme-variant="dark"]) .ts_mikron_wrapper + .ts_mikron_wrapper {
	margin-top: calc(var(--space-2xs) - 1px);
}

html[data-theme="minimal"]:not([data-theme-variant="dark"]) .ts_mikron {
	border-radius: var(--radius-md);
	box-shadow: inset 0 0 0 1px var(--color-ui-panel-border);
}

html[data-theme="minimal"] .ts_mikron > div {
	align-items: flex-start;
	gap: var(--space-lg);
}

/* The review state: a 24 x 24 px button with a 16 px mark in its centre.
   Open: a ring; accepted: a green disc with a check; rejected: a red disc
   with a cross. The shapes differ, so the state does not depend on hue.
   Processed in a bill: a neutral disc with a check, not a control (16 px).
   The button is the target; the mark is drawn by ::before and ::after.
   The column stacks its items, as in the classic themes: a row of the bill
   editor can show its own state, the state of the receiving organisation
   and the help button of an ignored Mikron. In a row, the 30 px column of
   a compact row squeezed the buttons to slivers (UX-256). */
html[data-theme="minimal"] .ts_mikron .reviewstatus {
	flex: 0 0 24px;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	min-height: 24px;
}

html[data-theme="minimal"] .ts_mikron .reviewstatus .reviewsymbol {
	position: relative;
	display: block;
	box-sizing: border-box;
	width: 24px;
	height: 24px;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: var(--radius-sm);
	background: transparent;
	cursor: pointer;
}

html[data-theme="minimal"] .ts_mikron .reviewstatus .reviewsymbol:hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] .ts_mikron .reviewstatus .processed {
	position: relative;
	display: block;
	box-sizing: border-box;
	width: 16px;
	height: 16px;
	margin: 0;
	border: 0;
	border-radius: 50%;
	background-color: var(--color-text-secondary);
	background-image: none;
	cursor: default;
}

/* The 16 px mark of the button. */
html[data-theme="minimal"] .ts_mikron .reviewstatus .reviewsymbol::before {
	content: "";
	position: absolute;
	inset: 4px;
	box-sizing: border-box;
	border-radius: 50%;
}

html[data-theme="minimal"] .ts_mikron .reviewstatus .reviewsymbol.open::before {
	border: 2px solid var(--color-control);
}

html[data-theme="minimal"] .ts_mikron .reviewstatus .reviewsymbol.accepted::before { background-color: var(--color-success-dark); }
html[data-theme="minimal"] .ts_mikron .reviewstatus .reviewsymbol.rejected::before { background-color: var(--color-error-dark); }

/* The check or the cross: 10 px, in the page colour, inside the disc. */
html[data-theme="minimal"] .ts_mikron .reviewstatus :is(.reviewsymbol.accepted, .reviewsymbol.rejected, .processed)::after {
	content: "";
	position: absolute;
	background-color: var(--color-background-primary);
	-webkit-mask: var(--review-mark) center / 10px no-repeat;
	mask: var(--review-mark) center / 10px no-repeat;
}

html[data-theme="minimal"] .ts_mikron .reviewstatus :is(.reviewsymbol.accepted, .reviewsymbol.rejected)::after {
	inset: 7px;
}

html[data-theme="minimal"] .ts_mikron .reviewstatus .processed::after {
	inset: 3px;
}

html[data-theme="minimal"] .ts_mikron .reviewstatus :is(.reviewsymbol.accepted, .processed) { --review-mark: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 10'%3E%3Cpath d='M1.5 5.2 4 7.5 8.5 2.5' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }
html[data-theme="minimal"] .ts_mikron .reviewstatus .reviewsymbol.rejected { --review-mark: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 10'%3E%3Cpath d='M2.5 2.5 7.5 7.5M7.5 2.5 2.5 7.5' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E"); }

html[data-theme="minimal"] .ts_mikron .reviewstatus .reviewsymbol:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 0;
}

html[data-theme="minimal"] .ts_mikron .ts_flex {
	display: flex;
	flex: 1 1 auto;
	gap: var(--space-3xl);
	min-width: 0;
	cursor: pointer;
}

html[data-theme="minimal"] .ts_mikron .ts_flex:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
	border-radius: var(--radius-sm);
}

/* Who and what: the project (500), the category and the member (13 px). */
html[data-theme="minimal"] .ts_mikron .mikron.info {
	flex: 0 0 240px;
	min-width: 0;
	font-size: var(--font-size-sm);
	line-height: 18px;
	color: var(--color-text-secondary);
}

html[data-theme="minimal"] .ts_mikron .mikron.info .project {
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	font-weight: 500;
	line-height: 20px;
}

html[data-theme="minimal"] .ts_mikron .mikron.date {
	flex: 0 0 112px;
	color: var(--color-text-primary);
	font-size: var(--font-size-sm);
	font-variant-numeric: tabular-nums;
	line-height: 20px;
}

html[data-theme="minimal"] .ts_mikron .mikron.date > div + div {
	color: var(--color-text-secondary);
	line-height: 18px;
}

html[data-theme="minimal"] .ts_mikron .mikron.desc {
	display: flex;
	flex: 1 1 auto;
	gap: var(--space-sm);
	min-width: 0;
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	line-height: 20px;
}

/* A forwarded Mikron shows a 14 px forward arrow and the review state of
   the receiving organisation in the shapes of the review mark (ring, check
   disc, cross disc) at the end of the description. */
html[data-theme="minimal"] .ts_mikron_fwd {
	flex: 0 0 auto;
	min-width: 0;
	max-width: none;
	height: 0;
	margin: 0;
	background: none;
}

html[data-theme="minimal"] .ts_mikron_fwd:is(.open, .accepted, .rejected) {
	display: inline-flex;
	align-items: center;
	gap: var(--space-2xs);
	height: 20px;
	min-width: 0;
	max-width: none;
	margin: 0;
	background: none;
}

html[data-theme="minimal"] .ts_mikron_fwd:is(.open, .accepted, .rejected)::before {
	content: "";
	width: 14px;
	height: 14px;
	background-color: var(--color-text-secondary);
	-webkit-mask: url(/icons/ui/send.svg) center / 14px no-repeat;
	mask: url(/icons/ui/send.svg) center / 14px no-repeat;
}

html[data-theme="minimal"] .ts_mikron_fwd:is(.open, .accepted, .rejected)::after {
	content: "";
	box-sizing: border-box;
	width: 14px;
	height: 14px;
	border-radius: 50%;
}

html[data-theme="minimal"] .ts_mikron_fwd.open::after { border: 2px solid var(--color-control); }
html[data-theme="minimal"] .ts_mikron_fwd.accepted::after { background: var(--color-success-dark) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'%3E%3Cpath d='M4 7.3 6 9.3 10 4.8' fill='none' stroke='white' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 14px no-repeat; }
html[data-theme="minimal"] .ts_mikron_fwd.rejected::after { background: var(--color-error-dark) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'%3E%3Cpath d='M4.5 4.5 9.5 9.5M9.5 4.5 4.5 9.5' fill='none' stroke='white' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E") center / 14px no-repeat; }

/* A copy of a forwarded Mikron: a dashed left edge instead of the zigzag. */
html[data-theme="minimal"] .ts_mikron.ts_mikron_forwarded {
	box-shadow: inset 3px 0 0 -1px var(--color-control);
	background-image: none;
}

/* Minimal Light (UI-88): the copy keeps the hairline of a white row card
   (family 8 above) beside its left edge. */
html[data-theme="minimal"]:not([data-theme-variant="dark"]) .ts_mikron.ts_mikron_forwarded {
	box-shadow: inset 3px 0 0 -1px var(--color-control), inset 0 0 0 1px var(--color-ui-panel-border);
}

html[data-theme="minimal"] .mikron_directforwardarrow {
	flex: 0 0 28px;
	width: 28px;
	height: 28px;
	border-radius: var(--radius-md);
	background-image: none;
	background-color: transparent;
	position: relative;
	cursor: pointer;
}

html[data-theme="minimal"] .mikron_directforwardarrow::before {
	content: "";
	position: absolute;
	inset: 6px;
	background-color: var(--color-text-secondary);
	-webkit-mask: url(/icons/ui/send.svg) center / 16px no-repeat;
	mask: url(/icons/ui/send.svg) center / 16px no-repeat;
}

html[data-theme="minimal"] .mikron_directforwardarrow:hover {
	background-color: var(--color-ui-hover);
}

@media (max-width: 899px) {
	html[data-theme="minimal"] .ts_mikron .ts_flex {
		flex-wrap: wrap;
		gap: var(--space-2xs) var(--space-lg);
	}

	html[data-theme="minimal"] .ts_mikron .mikron.info {
		flex: 1 1 100%;
	}

	html[data-theme="minimal"] .ts_mikron .mikron.date {
		flex: 0 0 auto;
		display: flex;
		gap: var(--space-sm);
	}

	html[data-theme="minimal"] .ts_mikron .mikron.desc {
		flex: 1 1 100%;
	}
}

/*------------------------------
=9 MEMBERS: MASTER-DETAIL
Replaces: .member-workspace, .memberlist, button.dashboard, .memberlist
member rows, #member.
------------------------------*/

html[data-theme="minimal"] .member-workspace {
	display: flex;
	align-items: stretch;
	width: 100%;
	height: 100%;
	min-height: 0;
}

/* The list column: 280 px, its own scroll area with a visible thumb. */
html[data-theme="minimal"] .memberlist {
	display: flex;
	flex: 0 0 280px;
	flex-direction: column;
	box-sizing: border-box;
	min-height: 0;
	border-right: 1px solid var(--color-ui-panel-border);
	background: var(--color-background-primary);
}

/* The list takes the width of the column with its padding (style.css
   gives it 100 % in content-box, so its rows stood 7 px past the column;
   UI-88 gives the rows a surface, which showed this). */
html[data-theme="minimal"] .memberlist > .resource-box-body-list {
	flex: 1 1 auto;
	box-sizing: border-box;
	min-height: 0;
	max-height: none;
	margin: 0;
	padding: var(--space-2xs) var(--space-sm);
	overflow-y: auto;
	scrollbar-width: thin;
}

/* The member dashboard is the first entry of the list. */
html[data-theme="minimal"] .memberlist > button.dashboard {
	display: flex;
	align-items: center;
	gap: var(--space-md);
	box-sizing: border-box;
	width: calc(100% - 2 * var(--space-sm));
	height: 40px;
	margin: var(--space-sm) var(--space-sm) var(--space-2xs);
	padding: 0 var(--space-lg);
	border: 0;
	border-radius: var(--radius-md);
	background: transparent;
	color: var(--color-text-primary);
	font: inherit;
	font-weight: 500;
	cursor: pointer;
}

html[data-theme="minimal"] .memberlist > button.dashboard::before {
	content: "";
	flex: 0 0 18px;
	width: 18px;
	height: 18px;
	background-color: var(--color-text-secondary);
	-webkit-mask: url(/icons/ui/dashboard.svg) center / 18px no-repeat;
	mask: url(/icons/ui/dashboard.svg) center / 18px no-repeat;
}

html[data-theme="minimal"] .memberlist > button.dashboard > span {
	display: inline;
	margin: 0;
	color: inherit;
	font-size: var(--font-size-md);
	font-weight: inherit;
	text-align: left;
}

html[data-theme="minimal"] .memberlist > button.dashboard:hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] .memberlist > button.dashboard.selected {
	position: relative;
	background-color: var(--color-selected);
	font-weight: 600;
}

html[data-theme="minimal"] .memberlist > button.dashboard.selected::after,
html[data-theme="minimal"] .memberlist .memberlist-member.selected::before {
	content: "";
	position: absolute;
	top: 8px;
	bottom: 8px;
	left: 0;
	width: 3px;
	border-radius: 0 3px 3px 0;
	background-color: var(--color-selected-mark);
}

html[data-theme="minimal"] .memberlist > button.dashboard:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: -2px;
}

html[data-theme="minimal"] .memberlist .memberlist-member {
	position: relative;
	margin: 0;
	border: 0;
	border-radius: var(--radius-md);
	box-shadow: none;
	background: transparent;
}

html[data-theme="minimal"] .memberlist .memberlist-member + .memberlist-member {
	margin-top: var(--space-3xs);
}

html[data-theme="minimal"] .memberlist .memberlist-member:hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] .memberlist .memberlist-member.selected {
	background-color: var(--color-selected);
}

html[data-theme="minimal"] .memberlist .memberlist-member.selected .resource-box-item-title h5 {
	font-weight: 600;
}

html[data-theme="minimal"] .memberlist .resource-box-bottom {
	border-top: 1px solid var(--color-ui-panel-border);
}

html[data-theme="minimal"] #member {
	flex: 1 1 auto;
	box-sizing: border-box;
	min-width: 0;
	min-height: 0;
	padding: var(--space-3xl) var(--page-gutter) 50px;
	overflow-y: auto;
	background: var(--color-background-primary);
}

@media (max-width: 899px) {
	/* One column. The list becomes a strip of member chips above the
	   detail; the strip scrolls sideways and the page scrolls down. */
	html[data-theme="minimal"] .member-workspace {
		flex-direction: column;
		height: auto;
	}

	/* The strip takes the full width: max-width: none lifts the 280 px
	   column limit of style.css. */
	html[data-theme="minimal"] .memberlist {
		flex: 0 0 auto;
		max-width: none;
		border-right: 0;
		border-bottom: 1px solid var(--color-ui-panel-border);
	}

	html[data-theme="minimal"] .memberlist > button.dashboard {
		display: none;
	}

	html[data-theme="minimal"] .memberlist > .resource-box-body-list {
		display: flex;
		gap: var(--space-sm);
		padding: var(--space-sm) var(--page-gutter);
		overflow-x: auto;
		overflow-y: hidden;
	}

	/* A chip is at most 260 px; its name and role wrap instead of being
	   cut ("Employee, 2 projects" needed 129 px of 122 px at 220 px). */
	html[data-theme="minimal"] .memberlist .memberlist-member {
		flex: 0 0 auto;
		max-width: 260px;
		border: 1px solid var(--color-ui-panel-border);
	}

	html[data-theme="minimal"] .memberlist .memberlist-member :is(h5, .resource-box-item-info-role) {
		overflow: visible;
		white-space: normal;
	}

	html[data-theme="minimal"] .memberlist .memberlist-member + .memberlist-member {
		margin-top: 0;
	}

	html[data-theme="minimal"] .memberlist .resource-box-item-info-icons {
		display: none;
	}

	html[data-theme="minimal"] .memberlist .resource-box-bottom {
		display: none;
	}

	html[data-theme="minimal"] #member {
		overflow: visible;
	}
}

/* The account mode of a member under the name: a quiet link button
   (replaces the inline style in members/member.erb). The 13 px text stands
   in a 24 px high target. */
html[data-theme="minimal"] .member-account-mode {
	display: inline-flex;
	align-items: center;
	align-self: flex-start;
	box-sizing: border-box;
	min-height: 24px;
	margin: var(--space-3xs) 0 0;
	padding: 0;
	border: 0;
	border-radius: var(--radius-sm);
	background: transparent;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
	text-align: left;
	text-decoration: underline;
	text-underline-offset: 2px;
	cursor: pointer;
}

html[data-theme="minimal"] .member-account-mode:hover {
	color: var(--color-text-primary);
}

html[data-theme="minimal"] .member-account-mode:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
}

/* The member dashboard (no member selected): the time-and-leave tiles of
   today as stat tiles that open their overview, the "Time and leave
   details" button (secondary), the member information as groups of
   key-value rows, and the open invitations as box rows with a quiet
   Revoke. */
html[data-theme="minimal"] .member-current-absence-summary {
	display: flex;
	flex-wrap: wrap;
	align-items: stretch;
	gap: var(--space-lg);
	margin: 0 0 var(--space-3xl);
}

html[data-theme="minimal"] .member-current-absence-card {
	display: flex;
	flex: 0 1 220px;
	flex-direction: column-reverse;
	align-items: flex-start;
	justify-content: flex-end;
	gap: var(--space-2xs);
	box-sizing: border-box;
	min-height: 72px;
	padding: var(--space-lg) var(--space-xl);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
	color: var(--color-text-primary);
	font: inherit;
	text-align: left;
	cursor: pointer;
}

html[data-theme="minimal"] .member-current-absence-card:hover {
	border-color: var(--color-control);
}

html[data-theme="minimal"] .member-current-absence-card:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
}

html[data-theme="minimal"] .member-current-absence-card > :is(img, .member-time-leave-symbol) {
	display: none;
}

html[data-theme="minimal"] .member-current-absence-card > strong {
	font-size: var(--font-size-2xl);
	font-weight: 600;
	line-height: 28px;
	font-variant-numeric: tabular-nums;
}

html[data-theme="minimal"] .member-current-absence-card > span {
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-weight: 500;
	line-height: 16px;
}

html[data-theme="minimal"] .member-current-absence-summary > .member-time-leave-report-launch {
	align-self: center;
}

/* The member information as groups of dl lists (markup since rollout
   job 8; a row with a link is a target as a whole, style.css). */
html[data-theme="minimal"] .member-information-summary {
	display: flex;
	flex-wrap: wrap;
	gap: var(--space-3xl);
	margin: 0 0 var(--space-4xl);
}

html[data-theme="minimal"] .member-information-group {
	flex: 1 1 260px;
	min-width: 0;
	max-width: 480px;
}

html[data-theme="minimal"] .member-information-group > h5 {
	margin: 0 0 var(--space-sm);
	padding: 0;
	font-size: var(--font-size-md);
	font-weight: 600;
	line-height: 20px;
}

html[data-theme="minimal"] .member-information-group > dl {
	margin: 0;
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
}

html[data-theme="minimal"] .member-information-group > dl > div {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: var(--space-lg);
	box-sizing: border-box;
	min-height: 40px;
	padding: var(--space-sm) var(--space-xl);
	border-top: 1px solid var(--color-ui-panel-border);
	font-size: var(--font-size-md);
	line-height: 20px;
}

html[data-theme="minimal"] .member-information-group > dl > div:first-child {
	border-top: 0;
}

html[data-theme="minimal"] .member-information-group dt {
	color: var(--color-text-secondary);
}

html[data-theme="minimal"] .member-information-group dd {
	margin: 0;
	font-weight: 600;
	font-variant-numeric: tabular-nums;
}

/* The link covers the whole row (with its padding), and the focus ring is
   the ring of family 9's rows on that cover. */
html[data-theme="minimal"] .member-information-group dt {
	position: static;
}

html[data-theme="minimal"] .member-information-group dt > a::after {
	right: 0;
	width: auto;
}

html[data-theme="minimal"] .member-information-group dt > a:focus-visible::after {
	outline: 2px solid var(--color-focus);
	outline-offset: -2px;
}

/* A count above zero in "Needs attention" is in the warning ink. */
html[data-theme="minimal"] .member-information-group dd.is-attention {
	color: var(--color-warning-dark);
}

/* An open invitation: the name, the type and date, and the action in one
   row that wraps. */
html[data-theme="minimal"] .openinvitation {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-sm) var(--space-xl);
}

/* An invitation of the user organisation dashboard takes the full width
   (760 px in style.css; UX-73 brings these pages into the Minimal themes). */
html[data-theme="minimal"] .user-organization-dashboard-invitation {
	max-width: none;
}

/* The open invitations of the member dashboard stand as box rows, at most
   720 px wide (the inline styles of the view became classes in rollout
   job 8; the 50 px height and the 600 px width of the other themes are
   scoped to them in style.css). */
html[data-theme="minimal"] .member-invitation {
	box-sizing: border-box;
	max-width: 720px;
	margin: 0 0 var(--space-sm);
	padding: var(--space-md) var(--space-xl);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
}

html[data-theme="minimal"] .member-invitations-empty {
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

html[data-theme="minimal"] .openinvitation > .openinvitation-name {
	flex: 1 1 260px;
	min-width: 0;
	font-size: var(--font-size-md);
	font-weight: 500;
	overflow-wrap: anywhere;
}

html[data-theme="minimal"] .organization-invitation-info {
	flex: 0 1 220px;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

html[data-theme="minimal"] .organization-invitation-info small {
	display: block;
	font-size: var(--font-size-xs);
	line-height: 16px;
	font-variant-numeric: tabular-nums;
}

/*------------------------------
=9 (continued) TIME AND LEAVE OF A MEMBER
Replaces: .member-time-leave-summary, -group, -group-title, -range,
.member-time-leave-rows, .member-time-leave-row and its chevron.
------------------------------*/

/* The groups stand side by side or one above the other as in the default
   themes (style.css, UI-78); this block gives only their look. */
html[data-theme="minimal"] .member-time-leave-summary-group-title {
	display: flex;
	align-items: baseline;
	gap: var(--space-sm);
	margin: 0 0 var(--space-sm);
	padding: 0;
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	font-weight: 600;
	line-height: 20px;
}

html[data-theme="minimal"] .member-time-leave-range {
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-weight: 400;
	font-variant-numeric: tabular-nums;
}

/* A list of key-value rows that open a detail: one bordered list, the
   value right-aligned and tabular, a chevron at the end. The rows keep the
   60 px minimum height of the default themes (UI-78). */
html[data-theme="minimal"] .member-time-leave-rows {
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
	overflow: hidden;
}

html[data-theme="minimal"] .member-time-leave-row {
	display: flex;
	align-items: center;
	gap: var(--space-sm);
	box-sizing: border-box;
	width: 100%;
	padding: var(--space-sm) var(--space-sm) var(--space-sm) var(--space-xl);
	border: 0;
	background: var(--color-row-fill);
	color: var(--color-text-primary);
	font: inherit;
	text-align: left;
	cursor: pointer;
}

html[data-theme="minimal"] .member-time-leave-row + .member-time-leave-row {
	border-top: 1px solid var(--color-ui-panel-border);
}

html[data-theme="minimal"] .member-time-leave-row:hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] .member-time-leave-row:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: -2px;
}

html[data-theme="minimal"] .member-time-leave-row::after {
	content: "";
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	background-color: var(--color-text-secondary);
	-webkit-mask: url(/icons/ui/chevron-down.svg) center / 14px no-repeat;
	mask: url(/icons/ui/chevron-down.svg) center / 14px no-repeat;
	transform: rotate(-90deg);
}

/* The row draws its chevron with ::after; the text chevron of the markup is
   for the other themes. */
html[data-theme="minimal"] .member-time-leave-chevron {
	display: none;
}

html[data-theme="minimal"] .member-time-leave-row-body {
	flex: 1 1 auto;
	min-width: 0;
}

html[data-theme="minimal"] .member-time-leave-label {
	font-size: var(--font-size-md);
	font-weight: 400;
	line-height: 20px;
}

html[data-theme="minimal"] .member-time-leave-value {
	font-size: var(--font-size-md);
	font-weight: 600;
	line-height: 20px;
}

/* The leave track: taken (the absence colour), planned (its lighter
   share), left (the track). */
html[data-theme="minimal"] .absence-progress-row .absence-progress-taken {
	flex: 0 0 var(--target-progress-base);
	background: var(--color-absence-progress-taken);
}

html[data-theme="minimal"] .absence-progress-row .absence-progress-planned {
	flex: 0 0 var(--absence-progress-planned, 0%);
	background: color-mix(in srgb, var(--color-absence-progress-taken) 45%, var(--color-background-quaternary));
}

/* The parts of the leave as value and label pairs with a swatch of their
   track colour ("6 taken", "3 planned", "13 left"), instead of one string
   joined with middle dots. */
html[data-theme="minimal"] .project-target-progress-status:has(> .absence-progress-part) {
	display: inline-flex;
	flex-wrap: wrap;
	gap: 0 var(--space-lg);
}

/* Hidden on screen, kept for a screen reader and the keyboard: the " · "
   between the parts (treetops.members.js), so the parts do not read as one
   word (the gap separates them on screen), and the button of a ticket row
   (family 18): it keeps the Tab order and the name of the ticket, and its
   focus draws the ring on the row; the row shows the name as text. */
html[data-theme="minimal"] :is(.absence-progress-separator, .mikron-timer-bar-separator, .ticket-open) {
	position: absolute;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip-path: inset(50%);
	white-space: nowrap;
}

html[data-theme="minimal"] .absence-progress-part {
	display: inline-flex;
	align-items: center;
	gap: var(--space-xs);
}

html[data-theme="minimal"] .absence-progress-part::before {
	content: "";
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: var(--color-background-quaternary);
	box-shadow: var(--shadow-marker);
}

html[data-theme="minimal"] .absence-progress-part.is-taken::before {
	background: var(--color-absence-progress-taken);
}

html[data-theme="minimal"] .absence-progress-part.is-planned::before {
	background: color-mix(in srgb, var(--color-absence-progress-taken) 45%, var(--color-background-quaternary));
}

html[data-theme="minimal"] .absence-legend {
	display: inline-flex;
	gap: var(--space-sm);
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-weight: 400;
}

/* Absences keep both panels in the existing shared-height flex stack.
   Their surface belongs to the dialog, including the selected tab. */
html[data-theme="minimal"] .absence-tabs .tab-content {
	background: transparent;
}

html[data-theme="minimal"] .absence-tabs .tab-links li.activetab a,
html[data-theme="minimal"] .absence-tabs .tab-links li.activetab a:hover {
	border-color: transparent;
	background: transparent;
}

/* The year stepper and the date row of the recording form sit in one row
   with a button beside the field. The stack margin under a field (family 25)
   does not belong there: it made the year field and the arrow buttons
   different heights and put "Preview dates" 14 px below the fields (UX-241). */
html[data-theme="minimal"] :is(.absence-year-stepper, .absence-range-form) .organization-input {
	margin-bottom: 0;
}

/* A button beside a field has the field height (block 23). */
html[data-theme="minimal"] .absence-range-form .absence-preview-button {
	height: var(--field-height);
}

html[data-theme="minimal"] .member-absence-body :is(.absence-period-title, .absence-entry-total, .absence-preview-reason, .project-target-progress-numbers),
html[data-theme="minimal"] .member-absence-overview-body :is(.member-absence-overview-person, .member-absence-overview-usage, .member-absence-overview-range) {
	min-width: 0;
	white-space: normal;
	overflow-wrap: anywhere;
}

html[data-theme="minimal"] .member-absence-overview-person {
	flex-wrap: wrap;
}

html[data-theme="minimal"] .member-absence-overview-usage {
	flex-shrink: 1;
}

/* The head of a member page: the layout is in style.css. The 50 px repeat the
   rule there because the avatar rule of section 22 (28 px) is more specific.
   The picture is centred on the two lines of text (UX-283): from the top of
   the name's capital letters down to the underline of the account mode, the
   lines take about 6 to 52 px of the head, so the middle is at 29 px and the
   offset is 4 px. Under 600 px the name is 28 px high, so the lines take about
   5 to 48 px and the offset is 2 px; the head keeps 2 px of spare height. */
html[data-theme="minimal"] .member-head > .memberlist-picture {
	width: 50px;
	height: 50px;
	margin-top: 4px;
}

@media (max-width: 599px) {
	html[data-theme="minimal"] .member-head > .memberlist-picture {
		margin-top: 2px;
	}
}

/* The account mode stands directly under the name, without the 2 px margin of
   its own rule in section 9 (UX-283). The text is then 3 px below the top of
   its 24 px high target. */
html[data-theme="minimal"] .member-head-text > .member-account-mode {
	margin-top: 0;
}

html[data-theme="minimal"] .member-head > .memberlist-picture .ticket-member-fallback {
	letter-spacing: -.04em;
}

/*------------------------------
=10 DETAIL HEAD: CUSTOMER NUMBER, ADDRESS, DESCRIPTION
Replaces: .client-identity, .client-identifier-badge, .client-description,
.accordion-description, .field-caption, .description-source,
.description-result, .description-prompt, .autosave-status.
------------------------------*/

html[data-theme="minimal"] .client-identity {
	flex: 0 0 auto;
}

html[data-theme="minimal"] .client-identifier-badge {
	display: inline-flex;
	align-items: center;
	height: 28px;
	padding: 0 var(--space-sm);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-sm);
	background: var(--color-background-secondary);
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	font-weight: 600;
	font-variant-numeric: tabular-nums;
	line-height: 20px;
}

html[data-theme="minimal"] .client-address {
	flex: 1 1 220px;
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	line-height: 20px;
}

/* The caption above the description is the field caption of family 25
   (13 px, 500, text 2); here it keeps 4 px to the text. */
html[data-theme="minimal"] .accordion-description .field-caption,
html[data-theme="minimal"] .client-description .field-caption {
	margin-bottom: var(--space-2xs);
}

html[data-theme="minimal"] .client-description,
html[data-theme="minimal"] .accordion-description .accordion-innerflexbox {
	position: relative;
	flex: 2 1 320px;
	min-width: 0;
	min-height: 0;
	margin: 0;
}

html[data-theme="minimal"] .accordion-description {
	margin: 0;
}

/* The shown text is a quiet click target: on hover it gets the row hover
   surface; the edit field has the same box (the edges of the column), the
   same text position, font and line height (UI-37, UX-292): the text does not
   move when the field opens.
   Only an editable text is a target: its edit field (.markupsource) stands
   directly before it, which is how treetops.js finds the field. Read-only
   text gets no hover, also not master's .markupresult:hover. */
html[data-theme="minimal"] .description-result {
	padding: var(--space-2xs) var(--space-sm);
	border-radius: var(--radius-md);
	font-size: var(--font-size-md);
	line-height: 20px;
	min-height: 20px;
}

html[data-theme="minimal"] .description-result > p {
	margin: 0;
}

html[data-theme="minimal"] .markupsource + .description-result {
	cursor: text;
}

html[data-theme="minimal"] .markupsource + .description-result:hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] .description-result:not(.markupsource + *):hover {
	background-color: transparent;
}

html[data-theme="minimal"] .description-prompt,
html[data-theme="minimal"] .description-prompt em {
	color: var(--color-placeholder);
	font-style: normal;
}

/* The edit field has the edges of the column of the caption, so it starts and
   ends where the box row below it does (UX-292; width and margin: style.css). */
html[data-theme="minimal"] .description-source {
	box-sizing: border-box;
	padding: 3px 7px;
	border: 1px solid var(--color-border-highlight);
	border-radius: var(--radius-md);
	box-shadow: inset 0 0 0 1px var(--color-border-highlight);
	background: var(--color-field);
	color: var(--color-text-primary);
	font: inherit;
	font-size: var(--font-size-md);
	line-height: 20px;
	resize: vertical;
}

html[data-theme="minimal"] .autosave-status {
	height: auto;
	min-height: 16px;
	font-size: var(--font-size-xs);
	line-height: 16px;
}

html[data-theme="minimal"] .client-description > .autosave-status,
html[data-theme="minimal"] .accordion-description .autosave-status {
	position: absolute;
	top: 0;
	right: 0;
}

html[data-theme="minimal"] .autosave-status-pending {
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
}

html[data-theme="minimal"] .autosave-status-saved {
	color: var(--color-success-dark);
	font-size: var(--font-size-xs);
}


/*------------------------------
=11 STAT TILES
Replaces: .greybox, .mg-stat-card, .mg-stats-grid, .greybox_num,
.mg-stat-value, .greybox_desc, .mg-stat-label and the sub-value rules
(d3Classes.css), .timesheet-stats.
------------------------------*/

/* The tiles of a row form one strip: one panel surface with a hairline
   edge and 8 px corners, the tiles divided by hairlines (not a card per
   tile). Each tile draws its divider at its left and top edge 1 px
   outside itself; the strip clips the dividers at its own edge, so a tile
   that starts a wrapped line has no stray line at the left. */
html[data-theme="minimal"] .mg-stats-grid,
html[data-theme="minimal"] .timesheet-stats {
	display: flex;
	flex-wrap: wrap;
	gap: 0;
	padding: 0;
	overflow: hidden;
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background-color: var(--color-ui-panel);
}

/* One tile: the label above, the value below, left-aligned. The script
   writes the value before the label; the column runs in reverse. The tiles
   of a row are as high as the highest one (the row stretches them), the
   label stands at the top and the value at the bottom, so that the values
   of a row share one baseline when a label takes two lines (UX-272). */
html[data-theme="minimal"] .greybox,
html[data-theme="minimal"] .mg-stat-card {
	display: flex;
	flex: 1 1 140px;
	flex-direction: column-reverse;
	justify-content: space-between;
	align-items: stretch;
	gap: var(--space-2xs);
	box-sizing: border-box;
	min-width: 112px;
	max-width: none;
	height: auto;
	min-height: 72px;
	margin: -1px 0 0 -1px;
	padding: var(--space-lg) var(--space-xl);
	border: 0;
	border-top: 1px solid var(--color-ui-panel-border);
	border-left: 1px solid var(--color-ui-panel-border);
	border-radius: 0;
	background-color: transparent;
	box-shadow: none;
	text-align: left;
	container-type: normal;
}

/* The lead figure: the first value of a strip is the key number of the
   page (32/36 px, tabular). The first tile of Timesheets takes a larger
   share of its row; the first tile of a chart does not (see below). */
html[data-theme="minimal"] .timesheet-stats > :first-child {
	flex: 2 1 200px;
}

html[data-theme="minimal"] :is(.mg-stats-grid, .timesheet-stats) > :first-child :is(.mg-stat-value, .greybox_num),
html[data-theme="minimal"] :is(.mg-stats-grid, .timesheet-stats) > :first-child .mg-stat-value .mg-total-main {
	font-size: var(--font-size-display);
	letter-spacing: -.02em;
	line-height: 36px;
}

/* The tiles of a chart share the row by the width of their values
   (UX-254). A tile starts at the width of its value, which does not
   break, or of its longest label word, and 112 px at the least (UX-216),
   so that the lead (32 px) and three tiles take one line in a project
   panel beside its box of budgets and quotas on the iPad in landscape
   (1180 px: a strip of 552 px), and the five tiles of a client panel or of
   the Clients page take one line there with a figure such as
   "-1,051,125 EUR". The free room goes to all tiles in equal parts, the lead
   included. When the values need more than the strip, the tiles wrap to
   a second line; a value never breaks. Under 600 px the tiles keep their
   half-width bases and a value may break. The tiles of Timesheets keep
   their bases. :where() keeps the rule weaker than the rules of the widths
   under 600 px. */
html[data-theme="minimal"] .mg-stats-grid > :where(.mg-stat-card) {
	flex-basis: min-content;
}

@media (min-width: 600px) {
	html[data-theme="minimal"] :is(.greybox_num, .mg-stat-value) {
		white-space: nowrap;
	}
}

html[data-theme="minimal"][data-theme-variant="dark"] :is(.greybox, .mg-stat-card) {
	background-color: transparent;
}

html[data-theme="minimal"] .greybox::before,
html[data-theme="minimal"] .stat_greybox::before,
html[data-theme="minimal"] .ts_greybox::before {
	content: none;
}

html[data-theme="minimal"] .greybox_num,
html[data-theme="minimal"] .mg-stat-value {
	display: block;
	flex: 0 0 auto;
	align-self: stretch;
	color: var(--color-text-primary);
	font-family: var(--font-ui-family);
	font-size: var(--font-size-2xl);
	font-weight: 600;
	font-variant-numeric: tabular-nums;
	letter-spacing: -.01em;
	line-height: 28px;
	text-shadow: none;
	overflow-wrap: anywhere;
}

html[data-theme="minimal"] .greybox_desc,
html[data-theme="minimal"] .mg-stat-label {
	position: static;
	flex: 0 0 auto;
	max-width: none;
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-weight: 500;
	line-height: 16px;
	text-align: left;
	overflow-wrap: anywhere;
}

/* A sub-value follows the value on its baseline in 13 px and names
   itself: "23" then "10 billable", "6" then "1 overdue" in the error ink
   (master: "23 (10)" and "6 (1)", with the meaning in the label; new
   texts, see the spec). */
html[data-theme="minimal"] .mg-stat-value .mg-total-main {
	line-height: 28px;
}

/* The number and its sub-value stand side by side, left-aligned, so the number
   stays on the baseline of the row. The value is as wide as both (max-width
   keeps it inside the tile), so the tile starts at that width and the strip
   wraps it to the next line when the line has no room. Only a tile that is
   alone on its line and wider than the strip shrinks, and then the sub-value
   stands under the number; no other number shares its line (UX-293). */
html[data-theme="minimal"] .mg-stat-value:has(> .mg-total-sub) {
	display: flex;
	flex-direction: row;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: flex-start;
	column-gap: var(--space-xs);
	margin: 0;
	width: max-content;
	max-width: 100%;
}

html[data-theme="minimal"] .mg-stat-value > :is(.mg-total-main, .mg-total-sub) {
	display: inline;
	flex: 0 1 auto;
	min-width: 0;
	white-space: normal;
}

html[data-theme="minimal"] .mg-stat-value .mg-total-sub {
	margin: 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
	opacity: 1;
	overflow-wrap: normal;
}

html[data-theme="minimal"] .mg-stat-value .mg-total-sub-billable {
	margin: 0;
	color: var(--color-text-secondary);
}

html[data-theme="minimal"] .mg-stat-value .mg-total-sub-overdue {
	color: var(--color-error-dark);
	font-weight: 600;
}

@media (max-width: 599px) {
	html[data-theme="minimal"] .greybox,
	html[data-theme="minimal"] .mg-stat-card {
		flex-basis: calc(50% - var(--space-sm));
		min-width: 0;
	}

	/* The lead figure takes the first line of the strip. */
	html[data-theme="minimal"] :is(.mg-stats-grid, .timesheet-stats) > :first-child {
		flex-basis: 100%;
	}

	/* A tile with a sub-value starts at the width of its number and sub-value
	   (from 600 px the rule of the tiles of a chart does this), so the strip
	   wraps it instead of putting the sub-value under its number while the
	   neighbour has none (UX-293). The lead keeps its own line. */
	html[data-theme="minimal"] .mg-stats-grid > .mg-stat-card:not(:first-child):has(> .mg-stat-value > .mg-total-sub) {
		flex-basis: min-content;
	}
}

/*------------------------------
=12 CHARTS
Replaces: the chart frame and chrome of d3Classes.css: .mg-wrapper,
.graph-container, .mg-y-label, .axis, .gridlines, .mp-settings-icon,
.legend-wrapper, .custom-constant-label, .d3-chart-tip, .graph-tooltip, and
the empty chart action .dashboard-graph-empty-action. The series colours stay
in public/chart_palettes.css.
------------------------------*/

/* A chart card: no fill (the series are checked against the page surface,
   chart_palettes.css), a hairline edge, 8 px corners, 16 px padding. */
html[data-theme="minimal"] .mg-wrapper {
	position: relative;
	box-sizing: border-box;
	padding: var(--space-xl);
	padding-bottom: calc(var(--space-xl) + var(--chart-legend-room, 0px));
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: transparent;
}

/* A chart inside an open panel or the member detail has no card of its
   own: it stands on the page surface of the panel, under the tile strip
   (one surface, not a card inside a panel). The settings button keeps the
   top right corner. */
html[data-theme="minimal"] :is(.accordion-body, #member) .mg-wrapper {
	padding: var(--space-xl) 0 var(--chart-legend-room, 0px);
	border: 0;
	border-radius: 0;
}

html[data-theme="minimal"] :is(.accordion-body, #member) .mg-wrapper > .mp-settings-icon {
	top: 0;
	right: 0;
}

html[data-theme="minimal"] .mg-wrapper .graph-container text,
html[data-theme="minimal"] .mg-wrapper .axis text {
	fill: var(--color-text-secondary);
	font-family: var(--font-ui-family);
	font-size: var(--font-size-xs);
	font-variant-numeric: tabular-nums;
}

html[data-theme="minimal"] .mg-wrapper .axis path,
html[data-theme="minimal"] .mg-wrapper .axis line {
	stroke: var(--color-control);
}

html[data-theme="minimal"] .mg-wrapper .gridlines line {
	stroke: var(--color-ui-panel-border);
	stroke-dasharray: none;
}

html[data-theme="minimal"] .mg-wrapper .gridlines path {
	stroke: none;
}

/* The zero line of a chart with values below zero (bills, clients, members) is
   the x axis of its bars. It has the colour of the axis lines, not the hairline
   of the other gridlines, so it stays visible on the card (UX-264). */
html[data-theme="minimal"] .mg-wrapper .gridlines .tick.zero line {
	stroke: var(--color-control);
}

html[data-theme="minimal"] .mg-wrapper .mg-y-label {
	fill: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-weight: 500;
}

/* The value of a budget or quota line ("173.71 h") stands in a 64 px gutter
   at the right of the plot, 8 px after the end of its line and level with
   it, so it never covers a bar (a label on a plate inside the plot hid the
   bars under it), and the legend names the line with its value ("Monthly
   hour quota: 97.83 h"). mighty-graph.js reads --chart-line-labels (below)
   and then keeps the gutter and writes the shorter label. The text is
   the primary text (17.74:1 and 14.28:1 on the page); the signal colour is
   on the 2 px line only, which needs 3:1 (the signal colours have 3.68:1 to
   4.57:1 on the page, but 12 px text in them would need 4.5:1). This rule
   overrides the fill attribute that mighty-graph.js writes. */
html[data-theme="minimal"] .mg-wrapper text.custom-constant-label {
	fill: var(--color-text-primary);
	font-size: var(--font-size-xs);
	font-weight: 600;
	font-variant-numeric: tabular-nums;
}

/* The chart settings: a 32 px quiet icon button in the top right corner. */
html[data-theme="minimal"] .mp-settings-icon {
	position: absolute;
	top: var(--space-sm);
	right: var(--space-sm);
	display: flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	width: var(--control-height);
	height: var(--control-height);
	border: 1px solid var(--color-button-edge);
	border-radius: var(--radius-md);
	background: var(--color-ui-panel);
	box-shadow: none;
	color: var(--color-text-secondary);
	cursor: pointer;
}

/* The settings button of a graph (mighty-graph.js) is .d3-settings-icon in
   the chart menu (.control-panels), which keeps it in the top right corner.
   It has the look of the button above. */
html[data-theme="minimal"] .control-panels .d3-settings-icon {
	box-sizing: border-box;
	width: var(--control-height);
	height: var(--control-height);
	border: 1px solid var(--color-button-edge);
	border-radius: var(--radius-md);
	background: var(--color-ui-panel);
	box-shadow: none;
	color: var(--color-text-secondary);
}

/* The icon, the hover and the focus of both buttons. The edge and the
   shadow stay on hover; d3Classes.css changes them in the other themes. */
html[data-theme="minimal"] .mp-settings-icon::before {
	content: "";
}

html[data-theme="minimal"] :is(.mp-settings-icon, .control-panels .d3-settings-icon)::before {
	width: 16px;
	height: 16px;
	background-color: currentColor;
	-webkit-mask: url(/icons/ui/settings.svg) center / 16px no-repeat;
	mask: url(/icons/ui/settings.svg) center / 16px no-repeat;
	opacity: 1;
}

html[data-theme="minimal"] :is(.mp-settings-icon, .control-panels .d3-settings-icon):hover {
	border-color: var(--color-button-edge);
	background: var(--color-ui-hover);
	box-shadow: none;
	color: var(--color-text-primary);
}

html[data-theme="minimal"] :is(.mp-settings-icon, .control-panels .d3-settings-icon):focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
}

/* The legend: one row of 10 px swatches with 12 px names that wraps, always
   under the chart (UI-55, answer 9). It replaces the draggable floating
   .legend-wrapper panel (a mighty-graph.js change). It shows by default;
   the checkbox "Legend" in the chart settings panel sets the hidden
   attribute to hide it. */
html[data-theme="minimal"] .chart-legend {
	display: flex;
	flex-wrap: wrap;
	gap: var(--space-2xs) var(--space-lg);
	margin-top: var(--space-sm);
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	line-height: 16px;
}

/* A legend without entries (the chart of an opened project or member) takes
   no room under the chart. */
html[data-theme="minimal"] .chart-legend:is([hidden], :not(:has(li, .legend-item))) {
	display: none;
}

html[data-theme="minimal"] .chart-legend .legend-item {
	display: inline-flex;
	align-items: center;
	gap: var(--space-xs);
}

/* The 10 px swatch: .legend-swatch of the sheet and .bg-color of the
   application's legend (mighty-graph.js). */
html[data-theme="minimal"] .chart-legend :is(.legend-swatch, .bg-color) {
	flex: 0 0 10px;
	width: 10px;
	height: 10px;
	border-radius: 2px;
}

/* A line series has a 12 x 2 px stroke as its legend mark. */
html[data-theme="minimal"] .chart-legend .legend-swatch.is-line,
html[data-theme="minimal"] .mg-wrapper:has(> .graph-container path.line:not(.balance)) > .chart-legend .bg-color {
	height: 2px;
	width: 12px;
	flex-basis: 12px;
	border-radius: 1px;
}

/* mighty-graph.js reads these properties. With --chart-legend: inline it
   builds the legend inside the chart card under the plot (the inline form),
   shown by default; in the other themes it keeps the floating legend panel
   of the chart menu. With --chart-line-labels: gutter it keeps the 64 px
   gutter for the values of the budget and quota lines, and the legend names
   each line. */
html[data-theme="minimal"] {
	--chart-legend: inline;
	--chart-line-labels: gutter;
}

/* The application's legend stands inside the chart card, under the plot
   and the x axis title, at the bottom of the card's padding box less its
   bottom padding. The plot keeps its full height and the card grows by the
   legend (UI-73): see the room under the plot below. It stands above the
   plot box (z-index 1), so that its entries take clicks (C21); the chart
   menu and the tooltip of d3Classes.css stay above it. The legend of the
   sheet stands in the flow of its card. */
html[data-theme="minimal"] .mg-wrapper:has(> .graph-container) > .chart-legend {
	position: absolute;
	z-index: 1;
	right: var(--space-xl);
	bottom: var(--space-xl);
	left: var(--space-xl);
	box-sizing: border-box;
	margin: 0;
	padding-top: var(--space-sm);
}

/* Under 600 px a chart with a round chart is a column with the round chart
   under the plot (d3Classes.css): the legend follows the round chart in the
   flow, so that it does not cover the ring. */
@media (max-width: 600px) {
	html[data-theme="minimal"] .mg-wrapper:has(> .pie-container) > .chart-legend {
		position: static;
		order: 3;
		margin-top: var(--space-xl);
	}
}

/* A chart without a card of its own has no padding at the sides and the
   bottom. */
html[data-theme="minimal"] :is(.accordion-body, #member, .dashboard-lead) .mg-wrapper:has(> .graph-container) > .chart-legend {
	right: 0;
	bottom: 0;
	left: 0;
}

/* The room under the plot (UI-73): a legend under a chart does not take
   height from the plot. mighty-graph.js measures the room that the x axis
   title and the legend take under the plot and sets it on the host as
   --chart-legend-room. These rules add the room to the bottom padding of
   the host (the rules of the chart card above and of the dashboard below)
   and to every height that sizes a chart host, so that the content box and
   the plot keep their size and the card grows by the room. The heights are
   those of d3Classes.css (400 px, the expanded chart's least 180 px) and
   style.css (the 400 px of a chart in a panel). A host of a fixed height,
   the expanded chart in its dialog, gives the room from its plot. */
html[data-theme="minimal"] .mg-wrapper {
	height: calc(400px + var(--chart-legend-room, 0px));
}

html[data-theme="minimal"] #MightyGraph.expanded {
	height: calc(400px + var(--chart-legend-room, 0px));
}

html[data-theme="minimal"] .client-d3stats > :is(.client-stats, .project-stats) > .mg-wrapper {
	flex-basis: calc(400px + var(--chart-legend-room, 0px));
	min-height: calc(400px + var(--chart-legend-room, 0px));
}

html[data-theme="minimal"] .mg-expanded-dialog .mg-expanded-host {
	min-height: calc(180px + var(--chart-legend-room, 0px));
}

@media (max-width: 600px) {
	html[data-theme="minimal"] .resource-chart-panel .mg-wrapper {
		flex-basis: calc(400px + var(--chart-legend-room, 0px));
		min-height: calc(400px + var(--chart-legend-room, 0px));
	}
}

/* The application's legend: a list per column with a heading, each entry a
   button that hides or shows its series (aria-pressed). Under the chart the
   entries form one row; the heading stays for screen readers. */
html[data-theme="minimal"] .chart-legend :is(.item-container, ul) {
	display: contents;
}

html[data-theme="minimal"] .chart-legend h4 {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: 0;
	padding: 0;
	overflow: hidden;
	clip-path: inset(50%);
	white-space: nowrap;
}

/* An entry has the class .item, so the rules of the bill rows (style.css,
   family 19) reach it; the entry sets their width, edge and surfaces back. */
html[data-theme="minimal"] .chart-legend li.item {
	display: inline-flex;
	align-items: center;
	gap: var(--space-xs);
	width: auto;
	min-height: 0;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: var(--radius-sm);
	background: transparent;
	cursor: pointer;
}

html[data-theme="minimal"] .chart-legend li.item:hover {
	background: transparent;
	color: var(--color-text-primary);
}

html[data-theme="minimal"] .chart-legend li.item:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
}

/* A hidden series: the entry is muted and struck through. */
html[data-theme="minimal"] .chart-legend li.item.off {
	opacity: .6;
}

html[data-theme="minimal"] .chart-legend li.item.off .desc {
	text-decoration: line-through;
}

html[data-theme="minimal"] .chart-legend .bg-color {
	display: inline-block;
	font-size: 0;
}

/* The chart tooltip uses the tooltip surface of family 34. */
html[data-theme="minimal"] .d3-chart-tip,
html[data-theme="minimal"] .graph-tooltip {
	padding: var(--space-sm) var(--space-md);
	border: 0;
	border-radius: var(--radius-md);
	background: var(--color-tooltip-bg);
	box-shadow: var(--shadow-md);
	color: var(--color-tooltip-text);
	font-size: var(--font-size-xs);
	line-height: 16px;
}

/* Empty: one sentence and one action, centred in a 160 px card. The empty
   notice of mighty-graph.js (.mg-request-state) has the class too. */
html[data-theme="minimal"] .chart-empty {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: var(--space-lg);
	min-height: 160px;
	color: var(--color-text-secondary);
	font-size: var(--font-size-md);
	line-height: 20px;
	text-align: center;
}

/* Loading: a 160 px skeleton of bars. The loading notice of mighty-graph.js
   (.mg-request-state) has the class too. */
html[data-theme="minimal"] .chart-loading {
	height: 160px;
	border-radius: var(--radius-sm);
	background:
		linear-gradient(to top, var(--color-skeleton) 45%, transparent 45%) 0 100% / 8% 100% no-repeat,
		linear-gradient(to top, var(--color-skeleton) 70%, transparent 70%) 12% 100% / 8% 100% no-repeat,
		linear-gradient(to top, var(--color-skeleton) 55%, transparent 55%) 24% 100% / 8% 100% no-repeat,
		linear-gradient(to top, var(--color-skeleton) 85%, transparent 85%) 36% 100% / 8% 100% no-repeat,
		linear-gradient(to top, var(--color-skeleton) 60%, transparent 60%) 48% 100% / 8% 100% no-repeat,
		linear-gradient(to top, var(--color-skeleton) 75%, transparent 75%) 60% 100% / 8% 100% no-repeat,
		linear-gradient(to top, var(--color-skeleton) 40%, transparent 40%) 72% 100% / 8% 100% no-repeat,
		linear-gradient(to top, var(--color-skeleton) 65%, transparent 65%) 84% 100% / 8% 100% no-repeat,
		linear-gradient(to top, var(--color-skeleton) 50%, transparent 50%) 96% 100% / 8% 100% no-repeat;
	animation: ds-pulse 1.2s ease-in-out infinite alternate;
}

/* The loading notice of the application is the skeleton across the content
   box of its chart, in the middle, on the surface of the chart (the page;
   the lead surface in the dashboard lead, below). It covers the last
   drawing while a new range loads; its sentence stays for screen readers. */
html[data-theme="minimal"] .mg-request-state.chart-loading {
	right: var(--space-xl);
	left: var(--space-xl);
	max-width: none;
	padding: 0;
	background-color: var(--color-background-primary);
	transform: translateY(-50%);
}

html[data-theme="minimal"] .dashboard-lead .mg-request-state.chart-loading {
	background-color: var(--color-lead-surface);
}

html[data-theme="minimal"] .mg-request-state.chart-loading > * {
	position: absolute;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip-path: inset(50%);
	white-space: nowrap;
}

html[data-theme="minimal"] .mg-wrapper.dashboard-graph {
	min-height: 0;
}

/* The dashboard chart is 300 px high (style.css gives the other themes
   400 px) and grows by the room under its plot (family 12); the line break
   after it goes. */
html[data-theme="minimal"] #dashboard-graph {
	height: calc(300px + var(--chart-legend-room, 0px));
}

html[data-theme="minimal"] .dashboard-chart-pair ~ br {
	display: none;
}

/* An empty chart of the application is the empty state above: the notice
   of mighty-graph.js (.mg-request-state.chart-empty, "No chart data for
   this selection.") stands in the middle of a 160 px card, and the empty axes and
   the legend are hidden. The dashboard chart also counts as empty when it
   has rows but no bars, lines or areas; it shows the sentence of its
   data-empty-label. Under the sentence of the dashboard stands the action
   "Add Mikron" (the link after the chart). */
/* min-height, not height: under 600 px d3Classes.css sets the height of a
   chart with a round chart to auto with !important. */
html[data-theme="minimal"] .mg-wrapper:has(> .mg-request-state.chart-empty),
html[data-theme="minimal"] #dashboard-graph:has(> .graph-container svg):not(:has(> .graph-container :is(rect, path.line, path.area))) {
	height: auto;
	min-height: 160px;
	flex: 0 0 auto;
}

html[data-theme="minimal"] .mg-wrapper:has(> .mg-request-state.chart-empty) > :is(.graph-container, .pie-container, .mg-y-label, .mg-x-label),
html[data-theme="minimal"] #dashboard-graph:has(> .graph-container svg):not(:has(> .graph-container :is(rect, path.line, path.area))) > :is(.graph-container, .pie-container, .mg-y-label, .mg-x-label),
html[data-theme="minimal"] .mg-wrapper:has(> .mg-request-state.chart-empty) > .chart-legend,
html[data-theme="minimal"] #dashboard-graph:has(> .graph-container svg):not(:has(> .graph-container :is(rect, path.line, path.area))) > .chart-legend {
	display: none;
}

html[data-theme="minimal"] .mg-request-state.chart-empty,
html[data-theme="minimal"] #dashboard-graph:has(> .graph-container svg):not(:has(> .graph-container :is(rect, path.line, path.area), > .mg-request-state))::after {
	padding: 0;
	background: transparent;
	color: var(--color-text-secondary);
	font-size: var(--font-size-md);
	line-height: 20px;
	text-align: center;
}

html[data-theme="minimal"] #dashboard-graph:has(> .graph-container svg):not(:has(> .graph-container :is(rect, path.line, path.area), > .mg-request-state))::after {
	content: attr(data-empty-label);
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
}

/* With the action, the sentence moves up by half the action and its gap. */
html[data-theme="minimal"] .dashboard-chart-pair:has(~ .dashboard-graph-empty-action) > #dashboard-graph > .mg-request-state.chart-empty,
html[data-theme="minimal"] .dashboard-chart-pair:has(~ .dashboard-graph-empty-action) > #dashboard-graph:has(> .graph-container svg):not(:has(> .graph-container :is(rect, path.line, path.area), > .mg-request-state))::after {
	top: calc(50% - 22px);
}

/* The action of an empty chart: a secondary button of family 23 with the
   plus icon. Outside an empty chart it is hidden. */
html[data-theme="minimal"] .dashboard-graph-empty-action {
	display: inline-flex;
	align-items: center;
	gap: var(--space-xs);
	box-sizing: border-box;
	height: var(--control-height);
	padding: 0 var(--space-lg);
	border: 1px solid var(--color-button-edge);
	border-radius: var(--radius-md);
	background: var(--color-ui-panel);
	color: var(--color-text-primary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
	text-decoration: none;
}

html[data-theme="minimal"] .dashboard-graph-empty-action::before {
	content: "";
	width: 16px;
	height: 16px;
	background-color: currentColor;
	-webkit-mask: url(/icons/ui/plus.svg) center / 16px no-repeat;
	mask: url(/icons/ui/plus.svg) center / 16px no-repeat;
}

html[data-theme="minimal"] .dashboard-graph-empty-action:hover {
	border-color: var(--color-button-edge-hover);
	background: var(--color-ui-hover);
}

html[data-theme="minimal"] .dashboard-graph-empty-action:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
}

html[data-theme="minimal"] .dashboard-chart-pair ~ .dashboard-graph-empty-action {
	display: none;
}

/* In the 160 px card the action stands 12 px under the sentence, 80 px from
   the top; the margins keep the card's height in the flow. */
html[data-theme="minimal"] .dashboard-chart-pair:has(> #dashboard-graph > .mg-request-state.chart-empty) ~ .dashboard-graph-empty-action,
html[data-theme="minimal"] .dashboard-chart-pair:has(> #dashboard-graph > .graph-container svg):not(:has(> #dashboard-graph > .graph-container :is(rect, path.line, path.area))) ~ .dashboard-graph-empty-action {
	position: relative;
	z-index: 25;
	display: flex;
	width: max-content;
	margin: -80px auto 48px;
}

/* The round chart beside the dashboard chart: the ring of family 13 at
   160 px with a 16 px stroke, its parts touching, the total in the centre
   (20 px, 600) with the range under it. It has no legend of its own: the
   legend of the chart names its parts (UI-67). It stands at the right of
   the bars (280 px), centred in its column, when the pair has room for
   both: 520 px for the bars, the gap of the lead (24 px) and the card,
   824 px in all (UX-214: the iPad in landscape, 1180 px, has 874 px). In a
   narrower pair the card follows the bars. The pair is a size container
   (dashboard-chart-pair), so the rules below ask for the width of the pair,
   not of the window. In the application mighty-graph.js reads --chart-pie of the
   chart host and then draws its round chart in this card after the chart
   (UI-62): the ring with the property values of the card, the hours of the
   range that the chart shows, and "Whole range" under the total. */
html[data-theme="minimal"] .dashboard-chart-pair {
	--chart-pie: card;
	container: dashboard-chart-pair / inline-size;
	display: flex;
	flex-wrap: wrap;
	gap: var(--space-xl);
	align-items: flex-start;
}

html[data-theme="minimal"] .dashboard-chart-pair > .mg-wrapper:first-child {
	flex: 1 1 520px;
	min-width: 0;
}

html[data-theme="minimal"] .chart-ring-card {
	--chart-ring-size: 160;
	--chart-ring-width: 16;
	--chart-ring-margin: 2;
	position: relative;
	display: flex;
	flex: 0 1 280px;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: var(--space-xl);
	box-sizing: border-box;
	min-width: 240px;
	padding: var(--space-xl);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
}

@container dashboard-chart-pair (width < 824px) {
	html[data-theme="minimal"] .chart-ring-card {
		flex: 1 1 100%;
		flex-direction: row;
		flex-wrap: wrap;
		justify-content: center;
	}
}

/* An expanded chart takes its round chart into the dialog
   (mighty-graph.js): the card follows the chart without a frame. */
html[data-theme="minimal"] .mg-expanded-dialog .mg-expanded-body > .chart-ring-card {
	flex: 0 0 auto;
	flex-direction: row;
	flex-wrap: wrap;
	align-self: center;
	justify-content: center;
	padding: 0;
	border: 0;
}

/* The centre of the application's ring (mighty-graph.js): the total over
   the range. */
html[data-theme="minimal"] .chart-ring-card text.chart-ring-total {
	fill: var(--color-text-primary);
	font-size: var(--font-size-2xl);
	font-weight: 600;
	font-variant-numeric: tabular-nums;
}

html[data-theme="minimal"] .chart-ring-card text.chart-ring-caption {
	fill: var(--color-text-secondary);
	font-size: var(--font-size-xs);
}

/* An empty dashboard chart has no round chart. */
html[data-theme="minimal"] .dashboard-chart-pair:has(> #dashboard-graph > .mg-request-state.chart-empty) > .chart-ring-card,
html[data-theme="minimal"] .dashboard-chart-pair:has(> #dashboard-graph > .graph-container svg):not(:has(> #dashboard-graph > .graph-container :is(rect, path.line, path.area))) > .chart-ring-card {
	display: none;
}

/* The lead of the dashboard: one panel holds the lead figure (the hours of
   the last 30 days, 32/40 px, tabular) over the bars and the round chart,
   which lose their own cards inside it; the round chart is divided from
   the bars by a hairline. The sections under the lead stay quiet: their
   headings, no frame of their own. New text "Hours in the last 30 days"
   (see the spec). */
html[data-theme="minimal"] .dashboard-lead {
	display: flex;
	flex-direction: column;
	gap: var(--space-xl);
	box-sizing: border-box;
	margin: 0 0 var(--space-5xl);
	padding: var(--space-3xl);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-lead-surface);
}

html[data-theme="minimal"] .dashboard-lead-head {
	display: flex;
	flex-direction: column;
	gap: var(--space-2xs);
}

/* The application fills the figure after the page loads
   (treetops.organizations.js); the head waits hidden until then. */
html[data-theme="minimal"] .dashboard-lead-head[hidden] {
	display: none;
}

html[data-theme="minimal"] .dashboard-lead-label {
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
}

html[data-theme="minimal"] .dashboard-lead-figure {
	color: var(--color-text-primary);
	font-size: var(--font-size-display);
	font-weight: 600;
	font-variant-numeric: tabular-nums;
	letter-spacing: -.02em;
	line-height: 40px;
}

html[data-theme="minimal"] .dashboard-lead .dashboard-chart-pair {
	gap: var(--space-3xl);
}

html[data-theme="minimal"] .dashboard-lead .mg-wrapper,
html[data-theme="minimal"] .dashboard-lead .chart-ring-card {
	padding: 0;
	border: 0;
	border-radius: 0;
}

html[data-theme="minimal"] .dashboard-lead .mg-wrapper {
	padding-top: var(--space-xl);
	padding-bottom: var(--chart-legend-room, 0px);
}

html[data-theme="minimal"] .dashboard-lead .mg-wrapper > .mp-settings-icon {
	top: 0;
	right: 0;
}

@container dashboard-chart-pair (width >= 824px) {
	html[data-theme="minimal"] .dashboard-lead .chart-ring-card {
		align-self: stretch;
		padding-left: var(--space-3xl);
		border-left: 1px solid var(--color-ui-panel-border);
	}
}

@media (max-width: 599px) {
	html[data-theme="minimal"] .dashboard-lead {
		margin-bottom: var(--space-4xl);
		padding: var(--space-xl);
	}

}

/* The chart settings panel (.mp-control-panels): a popover of family 34
   (the raised surface) under the settings button, 300 px: groups with a 12 px caption and a
   segmented switch (resolution, graph style) or two date fields (the
   range). It replaces the floating control panels of d3Classes.css. */
html[data-theme="minimal"] .chart-settings-panel {
	display: flex;
	flex-direction: column;
	gap: var(--space-xl);
	box-sizing: border-box;
	width: 300px;
	max-width: calc(100vw - 16px);
	padding: var(--space-xl);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-raised-surface);
	box-shadow: var(--shadow-md);
}

html[data-theme="minimal"] .chart-settings-panel > h4 {
	margin: 0;
	padding: 0;
	font-size: var(--font-size-md);
	font-weight: 600;
	line-height: 20px;
}

html[data-theme="minimal"] .chart-settings-group {
	display: flex;
	flex-direction: column;
	gap: var(--space-xs);
}

html[data-theme="minimal"] .chart-settings-group .segmented {
	align-self: flex-start;
	max-width: 100%;
	overflow-x: auto;
}

/* The two rules that waited for families 25 and 26 (rollout job 6): a
   group caption is 12 px, and the segments of a group are narrower. */
html[data-theme="minimal"] .chart-settings-group > .field-caption {
	font-size: var(--font-size-xs);
	line-height: 16px;
}

html[data-theme="minimal"] .chart-settings-group .segmented > :is(a, button) {
	min-width: 0;
	padding: 0 var(--space-sm);
}

/* The panel of mighty-graph.js (.control-panels .mods.chart-settings-panel)
   keeps its markup: the groups are .menu-group and .controls with an h4,
   the graph style is a radio group, Legend and the categories are
   checkboxes with a label, the resolution and the column subsets are
   selects with a label (.control-row), the range two date fields. These
   rules give that markup the panel of the sheet. The panel opens with the
   settings button (.control-panels.expanded), under it at the right. */
html[data-theme="minimal"] .control-panels:not(.expanded) .chart-settings-panel {
	display: none;
}

html[data-theme="minimal"] .control-panels .mods.chart-settings-panel {
	top: 40px;
	right: 0;
	left: auto;
	flex-wrap: nowrap;
	align-items: stretch;
	max-height: min(68vh, 520px);
	backdrop-filter: none;
}

html[data-theme="minimal"] .control-panels .chart-settings-panel > .display-radio-group {
	display: contents;
}

html[data-theme="minimal"] .control-panels .chart-settings-group:is(.menu-group, .controls) {
	flex: none;
	align-items: stretch;
	min-width: 0;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: none;
}

html[data-theme="minimal"] .control-panels .chart-settings-group:is(.menu-group, .controls).is-empty {
	display: none;
}

html[data-theme="minimal"] .control-panels .chart-settings-group > h4 {
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-weight: 500;
	line-height: 16px;
	letter-spacing: 0;
	text-transform: none;
	white-space: normal;
}

/* Legend, the pie and the categories: a checkbox of family 25 with its
   label as the target (the other themes hide the box and draw pills). */
html[data-theme="minimal"] .control-panels .chart-settings-group .menu-group-controls:not(.segmented) {
	flex-direction: column;
	gap: var(--space-xs);
}

html[data-theme="minimal"] .control-panels .chart-settings-group :is(.toggle-legend, .checkbox-wrapper) {
	display: flex;
	align-items: center;
	gap: var(--space-sm);
	min-height: 24px;
	margin: 0;
}

html[data-theme="minimal"] .control-panels .chart-settings-group :is(.toggle-legend, .checkbox-wrapper) > input[type="checkbox"] {
	position: static;
	opacity: 1;
	pointer-events: auto;
}

html[data-theme="minimal"] .control-panels .chart-settings-group :is(.toggle-legend, .checkbox-wrapper) > label {
	min-height: 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: none;
	box-shadow: none;
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	font-weight: 400;
	line-height: 20px;
	cursor: pointer;
}

html[data-theme="minimal"] .control-panels .chart-settings-group.categories .category {
	margin: 0 0 var(--space-sm);
	padding-left: var(--space-sm);
}

/* The group boxes show the 18 px box of family 25: ticked, the group is one
   entry; unticked, each entry of the group is shown on its own (UX-136).
   The line under "Groups" says this. d3Classes.css hides the box only in
   the other themes. */
html[data-theme="minimal"] .control-panels .chart-settings-group .chart-groups-hint {
	margin: 0 0 var(--space-xs);
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	line-height: 16px;
}

/* "Show pie": the secondary button of family 23 (aria-pressed). */
html[data-theme="minimal"] .control-panels .chart-settings-group .pie-mod > span {
	box-sizing: border-box;
	min-height: 0;
	height: var(--control-height);
	padding: 0 var(--space-lg);
	border: 1px solid var(--color-button-edge);
	border-radius: var(--radius-md);
	background: var(--color-ui-panel);
	box-shadow: none;
	color: var(--color-text-primary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
}

html[data-theme="minimal"] .control-panels .chart-settings-group .pie-mod > span.pie-visible {
	border-color: var(--color-border-highlight);
	background: var(--color-selected);
	color: var(--color-text-primary);
	font-weight: 600;
}

/* The graph style: the segmented switch of family 26; the radio buttons
   stay hidden, the label of the checked one is the current segment. */
html[data-theme="minimal"] .control-panels .chart-settings-group .menu-group-controls.segmented {
	flex-direction: row;
	flex-wrap: nowrap;
	gap: 0;
	width: auto;
}

html[data-theme="minimal"] .control-panels .chart-settings-group .segmented > .rg-label {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	min-height: 0;
	height: 26px;
	padding: 0 var(--space-sm);
	border: 1px solid transparent;
	border-radius: var(--radius-sm);
	background: transparent;
	box-shadow: none;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
}

html[data-theme="minimal"] .control-panels .chart-settings-group .segmented > .rg-label::before {
	content: none;
}

html[data-theme="minimal"] .control-panels .chart-settings-group .segmented > .rg-label:hover {
	color: var(--color-text-primary);
}

html[data-theme="minimal"] .control-panels .chart-settings-group .segmented > input[type="radio"]:checked + .rg-label {
	border-color: var(--color-ui-panel-border);
	background: var(--color-field);
	box-shadow: var(--shadow-xs);
	color: var(--color-text-primary);
	font-weight: 600;
}

html[data-theme="minimal"] .control-panels .chart-settings-group .segmented > input[type="radio"]:focus-visible + .rg-label {
	outline: 2px solid var(--color-focus);
	outline-offset: 0;
}

/* The selects and the dates are fields of family 25 (mighty-graph.js
   gives them the class .field), with the caption above (13 px, 500, the
   secondary text). */
html[data-theme="minimal"] .control-panels .chart-settings-group :is(.control-row, .date-wrapper, .date-field) {
	display: flex;
	flex-direction: column;
	flex-wrap: nowrap;
	align-items: stretch;
	gap: var(--space-xs);
	min-width: 0;
}

html[data-theme="minimal"] .control-panels .chart-settings-group :is(.control-row > label, .date-field > span) {
	flex: none;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
	text-transform: none;
}

/* The selects and the date fields are fields of family 25 (the class
   .field); d3Classes.css keeps its own field rules to the other themes. The
   dates have tabular figures. */
html[data-theme="minimal"] .control-panels .chart-settings-group .date-wrapper .field {
	font-variant-numeric: tabular-nums;
}


/*------------------------------
=13 BUDGET AND QUOTA RINGS
Replaces: .mp-center text, .mp-ring path.arc-item.is-remaining,
.project-budget-chartblock, .project-budget-chartlabel (d3Classes.css). The
dashboard strips (.ring-strip, .ring-tile, UI-91) have their layout in
style.css for every theme; this family gives them the Minimal look.
------------------------------*/

/* A tile of a dashboard strip: the box of family 15 (the panel surface, a
   hairline edge, 8 px radius); hover darkens the edge to the control
   colour. In Minimal Light the tiles are grey on the white page (UI-84). */
html[data-theme="minimal"] .ring-tile {
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
	transition: border-color var(--motion-fast) ease;
}

html[data-theme="minimal"] .ring-tile:hover {
	border-color: var(--color-control);
}

html[data-theme="minimal"] .ring-tile:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
}

/* The "Left" dot of the key: the quiet surface of the ring track
   (.mp-ring path.arc-item.is-remaining below). */
html[data-theme="minimal"] .org-dashboard-section[data-section] {
	--ring-track-colour: var(--color-background-quaternary);
}

/* The arrows are bordered icon buttons of family 24; at an end of the
   strip an arrow is aria-disabled (it keeps the focus). */
html[data-theme="minimal"] .ring-strip-arrow[aria-disabled="true"] {
	opacity: .4;
	cursor: default;
}

html[data-theme="minimal"] .ring-strip-arrow[aria-disabled="true"]:hover {
	background-color: var(--color-ui-panel);
	color: var(--color-text-secondary);
}

/* The filter is the segmented switch of family 26; its counts have
   tabular figures. */
html[data-theme="minimal"] .ring-strip-filter > button {
	font-variant-numeric: tabular-nums;
}

/* While a page loads, the sentinel shows as a skeleton tile. */
html[data-theme="minimal"] .ring-strip > .ring-strip-sentinel.is-loading {
	border-radius: var(--radius-lg);
	background: var(--color-skeleton);
}

/* The ring track (the unused part) and the centre labels. */
html[data-theme="minimal"] .mp-ring path.arc-item.is-remaining {
	fill: var(--color-background-quaternary);
}

/* The centre labels. The other themes fill them with !important in
   d3Classes.css; those rules are scoped to the other themes. */
html[data-theme="minimal"] .mp-center text:first-child {
	fill: var(--color-text-primary);
	font-size: var(--font-size-xs);
	font-weight: 600;
	font-variant-numeric: tabular-nums;
}

html[data-theme="minimal"] .mp-center text + text {
	fill: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-weight: 500;
	font-variant-numeric: tabular-nums;
}

/* In a project or client panel the rings stand on top of each other, each
   in its block with its caption, as in the classic themes (UI-78, UI-85,
   UX-163): d3Classes.css places the blocks. The theme removes the frame of
   a block and centres the ring under the caption: the ring keeps 88 px
   (UI-55 answer 3) and the title stands in the flow, so the theme centres
   them; the classic themes draw the ring to the host size. */
html[data-theme="minimal"] .project-budget-chartblock {
	align-items: center;
	gap: var(--space-sm);
	padding: 0;
	border: 0;
	background: transparent;
}

html[data-theme="minimal"] .project-budget-chartlabel {
	align-self: stretch;
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-weight: 500;
	line-height: 16px;
	text-align: left;
}

html[data-theme="minimal"] .mp-bottom-title {
	position: static;
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	line-height: 16px;
	text-align: center;
	white-space: normal;
}

/* One ring size: 88 px with an 8 px stroke, so that the value fits inside
   the ring. mighty-pie.js reads the three properties at each draw: the size
   of the drawing, the stroke and the margin around the ring (the other
   themes set none and keep the options of the chart). A chart with two
   rings keeps the inner ring at this size and puts the second ring around
   it, so that its value fits too (owner correction C6): mighty-pie.js
   writes the size of the drawing as --chart-ring-box on the host (88, or
   112 with two rings). The ring host takes its size from it, so a theme
   switch resizes the host and the pie redraws; the boxes around the host
   follow the host. The properties stand on the ring block, so that the host
   inherits them. */
html[data-theme="minimal"] .project-budget-chartblock {
	--chart-ring-size: 88;
	--chart-ring-width: 8;
	--chart-ring-margin: 2;
}

html[data-theme="minimal"] .project-budget-chartblock .mp-wrapper {
	flex: 0 0 calc(var(--chart-ring-box, var(--chart-ring-size)) * 1px);
	width: calc(var(--chart-ring-box, var(--chart-ring-size)) * 1px);
	height: calc(var(--chart-ring-box, var(--chart-ring-size)) * 1px);
	min-height: 0;
}

/* The ring of the component sheet stands in the host without the
   container of mighty-pie.js. */
html[data-theme="minimal"] .project-budget-chartblock .mp-wrapper > svg {
	width: calc(var(--chart-ring-size) * 1px);
	height: calc(var(--chart-ring-size) * 1px);
}

/* In a project or client panel a ring has its chart menu (.mp-control-panels
   of mighty-pie.js, with the settings button and the view switch) and its
   title inside the ring host. The menu stands at the top right of the
   block, level with the caption; the title stands centred under the ring.
   The host fills the block under the caption, as in the classic themes
   (UI-85, UX-163), and the ring (88 px, 112 px with two rings) and its
   title stand in the middle of it: the ring keeps 88 px (UI-55 answer 3)
   and the title stands in the flow, so the theme centres them; the classic
   themes draw the ring to the host size. */
html[data-theme="minimal"] .project-budget-chartblock .mp-wrapper:has(> .mp-container) {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	width: 100%;
	height: auto;
}

html[data-theme="minimal"] .project-budget-chartblock .mp-container {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: var(--space-sm);
}

/* In a panel the ring grows with its block (UX-201, UI-93). The project
   panel and the client panel render the box from one partial
   (projects/partial_budgets_quotas_box.erb), so the same rules apply to
   both (UX-252). The box is at least 560 px high (style.css); in the
   ordinary case a block is 241 px high when the box shows Budgets and
   Quotas, and 494 px when it shows one of them. The ring takes its step from the number of
   blocks that show (the client script hides a block without targets):
   - two blocks: 132 px with a 12 px stroke (164 px with two rings, C6);
   - one block: 176 px with a 16 px stroke (216 px with two rings, two
     times 88 px), the maximum.
   The component sheet has no box body and keeps 88 px (UI-55 answer 3).
   mighty-pie.js reads the size at each draw and draws again when the host
   changes its size. */
html[data-theme="minimal"] .budgetsquotas .project-budget-chartblock .mp-wrapper {
	--chart-ring-size: 176;
	--chart-ring-width: 16;
}

html[data-theme="minimal"] .budgetsquotas .project-budget-chartstack:has(> .project-budget-chartblock:not([hidden]) ~ .project-budget-chartblock:not([hidden])) .mp-wrapper {
	--chart-ring-size: 132;
	--chart-ring-width: 12;
}

/* The title under a ring can be longer than two lines: in a client panel
   it adds the note on unknown work costs to the scope and the measure, and
   the scope of a task or category has its name. d3Classes.css lets the ring
   and the title shrink, and the title clips its text. Here they do not
   shrink, and the box grows from 560 px by the room that its blocks need
   (style.css, UX-252). The blocks share the height equally. Measured with
   two blocks, two rings, a task scope and the de-DE note: the box is 642 px
   high in a 300 px panel, 610 px at 380 px and 578 px at 560 px; without
   the note it stays 560 px. */
html[data-theme="minimal"] .budgetsquotas .project-budget-chartstack {
	height: auto;
	min-height: auto;
}

html[data-theme="minimal"] .budgetsquotas .project-budget-chartblock {
	flex: 1 1 0;
	min-height: auto;
}

html[data-theme="minimal"] .budgetsquotas .project-budget-chartblock .mp-wrapper:has(> .mp-container) {
	min-height: auto;
}

html[data-theme="minimal"] .budgetsquotas .mp-container > :is(svg, .mp-bottom-title) {
	flex-shrink: 0;
}

/* The value and the percentage in the ring grow with the ring: mighty-pie.js
   writes their size (14 px and 10 px) for the 88 px ring, and the scale
   works around the centre of the ring (the origin of the group in the
   drawing of mighty-pie.js, the svg.canvas). The component sheet draws its
   rings at their size. */
html[data-theme="minimal"] .project-budget-chartblock svg.canvas .mp-center {
	scale: calc(var(--chart-ring-size) / 88);
}

/* The settings button stands at the right end of the caption row (the
   16 px caption and the 8 px gap above the ring host), so that it does not
   cover a ring with two rings (owner correction C6). */
html[data-theme="minimal"] .project-budget-chartblock .mp-control-panels {
	top: calc(-16px - var(--space-sm));
	right: 0;
}

html[data-theme="minimal"] .project-budget-chartblock .mp-settings-icon {
	position: static;
}

/* Under a ring: the measure ("Budget hours") and the range ("Whole
   range") as two lines instead of one string joined with a middle dot
   (mighty-pie.js writes each part in its own span). */
html[data-theme="minimal"] .mp-bottom-title > span {
	display: block;
}

html[data-theme="minimal"] .mp-bottom-title > span:first-child {
	color: var(--color-text-primary);
	font-weight: 500;
}

/*------------------------------
=14 LABELLED PROGRESS
Replaces: .project-target-progress*, .client-target-progress*,
.ticket-progress, the leave bar of .member-time-leave-row.
------------------------------*/

/* Rows stand 12 px apart: from one track to the next label (the overview
   list of treetops.project_targets.js had no gap, so a track touched the
   next name). */
html[data-theme="minimal"] .project-target-progress,
html[data-theme="minimal"] .project-overview-target-list {
	display: flex;
	flex-direction: column;
	gap: var(--space-lg);
}

html[data-theme="minimal"] .project-target-progress-row {
	display: flex;
	flex-direction: column;
	gap: var(--space-xs);
}

html[data-theme="minimal"] .project-target-progress-row.is-child {
	padding-left: var(--space-xl);
}

html[data-theme="minimal"] .project-target-progress-row-heading {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: space-between;
	gap: var(--space-2xs) var(--space-lg);
}

html[data-theme="minimal"] .project-target-progress-name {
	display: flex;
	align-items: baseline;
	gap: var(--space-xs);
	min-width: 0;
	color: var(--color-text-primary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
}

html[data-theme="minimal"] .project-target-progress-completion {
	color: var(--color-text-secondary);
	font-weight: 400;
}

html[data-theme="minimal"] .project-target-progress-values {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 0 var(--space-lg);
	color: var(--color-text-primary);
	font-size: var(--font-size-sm);
	font-variant-numeric: tabular-nums;
	line-height: 18px;
}

/* The percentage stands apart from the amount as its own value (no middle
   dot between them): one decimal, 500 weight. */
html[data-theme="minimal"] .project-target-progress-percent {
	font-weight: 500;
}

html[data-theme="minimal"] .project-target-progress-status {
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	line-height: 16px;
}

html[data-theme="minimal"] .project-target-progress-row.is-over .project-target-progress-status {
	color: var(--color-error-dark);
	font-weight: 600;
}

/* The track: 6 px, round ends. The fill is the neutral signal of the chart
   palette, an exceeded part the negative signal, a task fill the task teal.
   A 2 px gap separates the parts, so a fill borders only the surface around
   the track (its 3:1 is checked against the page), never the track colour. */
html[data-theme="minimal"] .project-target-progress-track {
	display: flex;
	gap: 2px;
	height: 6px;
	overflow: hidden;
	border-radius: var(--radius-pill);
	background: transparent;
}

html[data-theme="minimal"] .project-target-progress-segment.is-base {
	flex: 0 0 var(--target-progress-base);
	background: var(--color-target-progress-base);
}

html[data-theme="minimal"] .project-target-progress-segment.is-remainder {
	flex: 0 0 var(--target-progress-remainder);
	background: var(--color-background-quaternary);
}

html[data-theme="minimal"] .project-target-progress-segment {
	min-width: 0;
}

html[data-theme="minimal"] .project-target-progress-segment.is-delta {
	flex: 0 0 var(--target-progress-delta);
	background: var(--color-target-progress-over);
}

html[data-theme="minimal"] .project-target-progress-row.is-task .project-target-progress-segment.is-base {
	background: var(--color-target-progress-task);
}

/* A group heading inside the overview ("Project scope", "Tasks"). */
html[data-theme="minimal"] :is(.project-overview-scope-heading, .client-target-scope-heading, .client-target-detail-section-heading) {
	margin: 0 0 var(--space-sm);
	padding: 0;
	border: 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-weight: 600;
	letter-spacing: .02em;
	line-height: 16px;
	text-transform: none;
}

/* The slim track of a ticket row: 48 px, 4 px high, with the percentage
   8 px after it, both at the left of the cell. Family 18 gives the cell
   its width (the details column of the row). */
html[data-theme="minimal"] .ticket-progress {
	display: flex;
	align-items: center;
	gap: var(--space-sm);
}

html[data-theme="minimal"] .ticket-progress progress {
	flex: 0 0 48px;
	width: 48px;
	height: 4px;
	border: 0;
	border-radius: var(--radius-pill);
	background: var(--color-background-quaternary);
	overflow: hidden;
}

html[data-theme="minimal"] .ticket-progress progress::-webkit-progress-bar {
	border-radius: var(--radius-pill);
	background: var(--color-background-quaternary);
}

html[data-theme="minimal"] .ticket-progress progress::-webkit-progress-value {
	border-radius: var(--radius-pill);
	background: var(--color-target-progress-task);
}

html[data-theme="minimal"] .ticket-progress progress::-moz-progress-bar {
	border-radius: var(--radius-pill);
	background: var(--color-target-progress-task);
}

html[data-theme="minimal"] .ticket-progress-value {
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-variant-numeric: tabular-nums;
	line-height: 16px;
	white-space: nowrap;
}

/*------------------------------
=15 RESOURCE BOXES
Replaces: .resource-box, .resource-box-top, -top-info, -top-center,
-top-right, .resource-box-body, .resource-box-body-list,
.resource-box-bottom, .resource-box-modal, .icon.tooltip.help inside a box.
------------------------------*/

/* The box has the layout of the default themes (style.css; Treetops
   decision UI-78): its height, width and minimum width come from there. Its
   list scrolls inside the box, so loading rows does not move the head or
   foot. This block gives the look. */
html[data-theme="minimal"] .resource-box {
	overflow: hidden;
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background-color: var(--color-ui-panel);
	box-shadow: none;
	font-size: var(--font-size-md);
}

/* The head: the title at the left (it wraps, it is never cut), the help
   button right after it, the box tools at the right. */
html[data-theme="minimal"] .resource-box-top {
	display: flex;
	flex-shrink: 0;
	align-items: center;
	gap: var(--space-2xs);
	box-sizing: border-box;
	min-height: 44px;
	height: auto;
	padding: var(--space-sm) var(--space-sm) var(--space-sm) var(--space-xl);
	border-bottom: 1px solid var(--color-ui-panel-border);
	border-radius: 0;
	background: transparent;
	line-height: 44px;
}

html[data-theme="minimal"] .resource-box-top-center {
	order: 0;
	flex: 0 1 auto;
	width: auto;
	min-width: 0;
	overflow: visible;
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	font-weight: 600;
	line-height: 20px;
	text-align: left;
	text-overflow: clip;
	white-space: normal;
}

html[data-theme="minimal"] .resource-box-top-info {
	order: 1;
	flex: 0 0 auto;
	display: flex;
	justify-content: flex-start;
	width: auto;
	min-width: 0;
}

html[data-theme="minimal"] .resource-box-top-right {
	order: 2;
	display: flex;
	flex: 0 0 auto;
	min-width: 0;
	gap: var(--space-2xs);
	margin-left: auto;
}

/* The help button: a 24 px target with a 16 px line icon. */
html[data-theme="minimal"] .resource-box-top-info .tooltip,
html[data-theme="minimal"] .org-dashboard-section-header .tooltip {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 24px;
	height: 24px;
	border-radius: var(--radius-sm);
}

html[data-theme="minimal"] .resource-box-top-info .tooltip:hover,
html[data-theme="minimal"] .org-dashboard-section-header .tooltip:hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] .resource-box-top-info .tooltip:focus-visible,
html[data-theme="minimal"] .org-dashboard-section-header .tooltip:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 0;
}

/* The help icon of a help button (family 24) and of Skeleton's help links:
   16 px in the secondary ink. The small icon of master (a repeated
   non-working day) is the same icon. */
html[data-theme="minimal"] .icon.tooltip.help,
html[data-theme="minimal"] .help-button > .icon.tooltip-small.help {
	width: 16px;
	min-width: 16px;
	height: 16px;
	min-height: 16px;
	margin: 0;
	background-image: none;
	background-color: var(--color-text-secondary);
	-webkit-mask: url(/icons/ui/help.svg) center / 16px no-repeat;
	mask: url(/icons/ui/help.svg) center / 16px no-repeat;
}

/* A box tool (reload, filter, download, the picker): a 28 px quiet icon
   button with a 16 px icon. */
/* Markup change: the tools become buttons with an aria-label (they were
   divs with a title and tabindex="-1" or none; markup: job 5). */
html[data-theme="minimal"] .resource-box-top-right .resource-box-icon,
html[data-theme="minimal"] .org-dashboard-section-tools .resource-box-icon {
	display: inline-flex;
	box-sizing: border-box;
	width: 28px;
	min-width: 28px;
	height: 28px;
	min-height: 0;
	padding: 0;
	border: 0;
	border-radius: var(--radius-md);
	background-image: none;
	background-color: transparent;
	cursor: pointer;
	position: relative;
}

html[data-theme="minimal"] .resource-box-top-right .resource-box-icon::before,
html[data-theme="minimal"] .org-dashboard-section-tools .resource-box-icon::before {
	content: "";
	margin: auto;
	width: 16px;
	height: 16px;
	background-color: var(--color-text-secondary);
	-webkit-mask: var(--box-icon) center / 16px no-repeat;
	mask: var(--box-icon) center / 16px no-repeat;
}

html[data-theme="minimal"] .resource-box-top-right .resource-box-icon:hover,
html[data-theme="minimal"] .org-dashboard-section-tools .resource-box-icon:hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] :is(.resource-box-top-right, .org-dashboard-section-tools) .redo-circle-grey { --box-icon: url(/icons/ui/refresh.svg); }
html[data-theme="minimal"] :is(.resource-box-top-right, .org-dashboard-section-tools) .filter-circle-grey { --box-icon: url(/icons/ui/filter.svg); }
html[data-theme="minimal"] :is(.resource-box-top-right, .org-dashboard-section-tools) .download-circle-grey { --box-icon: url(/icons/ui/download.svg); }
html[data-theme="minimal"] :is(.resource-box-top-right, .org-dashboard-section-tools) .stack-circle-grey { --box-icon: url(/icons/ui/archive.svg); }

html[data-theme="minimal"] .resource-box-body {
	background: transparent;
}

/* A list fills its body (style.css), then scrolls with a thin thumb.
   An 8 px shade at the top or bottom edge shows that more rows are hidden
   there. Here it is painted on the list (background-attachment: local
   keeps a 16 px cover at the ends of the list), and the rows of Dark let
   it through. */
html[data-theme="minimal"] .resource-box-body-list {
	padding: 0;
	overflow-y: auto;
	list-style: none;
	scrollbar-width: thin;
	background:
		linear-gradient(var(--color-ui-panel), var(--color-ui-panel)) top / 100% 16px no-repeat local,
		linear-gradient(var(--color-ui-panel), var(--color-ui-panel)) bottom / 100% 16px no-repeat local,
		linear-gradient(rgba(17, 19, 26, .10), transparent) top / 100% 8px no-repeat scroll,
		linear-gradient(transparent, rgba(17, 19, 26, .10)) bottom / 100% 8px no-repeat scroll;
	background-color: var(--color-ui-panel);
}

/* Minimal Light (UI-88): the rows are white cards that would hide the
   shade of the list, so two sticky pseudo-elements draw it above the
   rows. The scroll position of the list fades them (a scroll-driven
   animation): the top shade comes in over the first 16 px of scrolling,
   the bottom shade goes out over the last 16 px, and a list that does not
   scroll shows none. A browser without scroll-driven animations keeps the
   shade under the rows, as above. The member strip under 900 px scrolls
   sideways and has no shade. */
@supports (animation-timeline: scroll()) {
	html[data-theme="minimal"]:not([data-theme-variant="dark"]) .resource-box-body-list {
		background: var(--color-ui-panel);
	}

	html[data-theme="minimal"]:not([data-theme-variant="dark"]) .resource-box-body-list:not(:empty)::before {
		content: "";
		position: sticky;
		top: 0;
		z-index: 1;
		display: block;
		height: 8px;
		margin-bottom: -8px;
		background: linear-gradient(rgba(17, 19, 26, .10), transparent);
		opacity: 0;
		pointer-events: none;
		animation: list-shade-in linear both;
		animation-timeline: scroll(nearest block);
		animation-range: 0 16px;
	}

	html[data-theme="minimal"]:not([data-theme-variant="dark"]) .resource-box-body-list:not(:empty)::after {
		content: "";
		position: sticky;
		bottom: 0;
		z-index: 1;
		display: block;
		height: 8px;
		margin-top: -8px;
		background: linear-gradient(transparent, rgba(17, 19, 26, .10));
		opacity: 0;
		pointer-events: none;
		animation: list-shade-out linear both;
		animation-timeline: scroll(nearest block);
		animation-range: calc(100% - 16px) 100%;
	}
}

@media (max-width: 899px) {
	html[data-theme="minimal"]:not([data-theme-variant="dark"]) .memberlist > .resource-box-body-list::before,
	html[data-theme="minimal"]:not([data-theme-variant="dark"]) .memberlist > .resource-box-body-list::after {
		content: none;
	}
}

@keyframes list-shade-in {
	from { opacity: 0; }
	to { opacity: 1; }
}

@keyframes list-shade-out {
	from { opacity: 1; }
	to { opacity: 0; }
}

/* Empty: a quiet sentence in the body (new text per box, see the spec).
   The application writes it as li.resource-box-list-empty.resource-box-empty
   in the list of the box; style.css hides it beside a row. */
html[data-theme="minimal"] .resource-box-empty {
	padding: var(--space-3xl) var(--space-xl);
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
	text-align: center;
}

/* The foot holds only the add control; read-only users get no foot. The
   views leave white space in a foot without its button, so the test is "no
   child element", not :empty. */
html[data-theme="minimal"] .resource-box-bottom {
	display: flex;
	flex-shrink: 0;
	align-items: center;
	box-sizing: border-box;
	min-height: 44px;
	height: auto;
	padding: var(--space-2xs) var(--space-sm);
	border-top: 1px solid var(--color-ui-panel-border);
	background: transparent;
}

html[data-theme="minimal"] .resource-box-bottom:not(:has(> *)) {
	display: none;
}

/*------------------------------
=16 TWO-COLUMN LIST AND DETAIL INSIDE A BOX
Replaces: .resource-split-panel, .resource-box-body-flexcontainer,
.resource-box-body.resource-box-content, .client-projectsettings panes.
------------------------------*/

/* The columns are those of the default themes (style.css, UI-78): the list
   takes one part (200 to 300 px), the detail two parts, and only a box
   under 240 px on a phone puts the list above the detail. This family gives
   the look: a hairline after the list instead of before the detail, and the
   inner space of the detail. */
html[data-theme="minimal"] .resource-box-body-flexcontainer > .resource-box-body:first-child {
	border-right: 1px solid var(--color-ui-panel-border);
}

/* The selected detail scrolls within the stable box height. Its surface
   is white in Light, so that it stands apart from the grey list column
   (UI-90). */
html[data-theme="minimal"] .resource-box-body.resource-box-content {
	padding: var(--space-xl);
	border-left: 0;
	overflow: auto;
	background: var(--color-box-detail);
}

/* In Light a project card of the target summary (no project selected) is
   a grey card with a hairline on the white detail, as a card on the page.
   In Dark it has no fill and shows the box, as before. */
html[data-theme="minimal"]:not([data-theme-variant="dark"]) .client-target-summary-project {
	background: var(--color-ui-panel);
}

/* On a phone the list of a box with a list and a detail is 100 px wide
   (style.css). Its rows put their action under the text, so the name keeps
   the width of the row. */
@media (max-width: 600px) {
	html[data-theme="minimal"] .resource-split-panel .resource-box-body-flexcontainer > .resource-box-body:first-child .resourcelist-resource {
		flex-wrap: wrap;
	}

	html[data-theme="minimal"] .resource-split-panel .resource-box-body-flexcontainer > .resource-box-body:first-child .resource-row-action {
		margin-left: auto;
	}
}

/* The phone condition of the stacked list in style.css: the hairline goes
   under the list. */
@media (max-width: 600px) {
	@container resource-split-panel (max-width: 239px) {
		html[data-theme="minimal"] .resource-box-body-flexcontainer > .resource-box-body:first-child {
			border-right: 0;
			border-bottom: 1px solid var(--color-ui-panel-border);
		}
	}
}

/*------------------------------
=17 ROWS INSIDE BOXES (formerly cards)
Replaces: .resourcelist-resource, .resource-box-item-container, -title,
-info, -info-role, -info-icons, .selected, .expense, .expense-status-badge,
.budget-list, .budget-details, the 15 px action strip
(--resource-action-collapsed-width) and .member-title.
------------------------------*/

/* One row anatomy for members, rates, expenses, budgets and organisations:
   a lead (avatar or marker), a primary line, a secondary line, trailing
   values or icons, and trailing actions. */
html[data-theme="minimal"] .resource-box-body-list > .resourcelist-resource,
html[data-theme="minimal"] .memberlist .resourcelist-resource {
	position: relative;
	display: flex;
	flex-direction: row;
	flex-wrap: nowrap;
	align-items: center;
	gap: var(--space-sm);
	box-sizing: border-box;
	transition: background-color var(--motion-fast) ease;
}

/* A row in a box keeps the space of the default themes (style.css:
   10 px inside, 10 px above, 5 px at the sides and below; Treetops
   decision UI-78). Its look: the row fill (white on the grey box in
   Light, UI-88; none in Dark, where the box shows through) and a 1 px edge in the border
   colour, so a single row stands apart from the box. */
html[data-theme="minimal"] .resource-box-body-list > .resourcelist-resource {
	border: 0;
	border-radius: var(--radius-md);
	background: var(--color-row-fill);
	box-shadow: inset 0 0 0 1px var(--color-ui-panel-border);
}

/* The member list (family 9): rows with hairlines between them over the
   list (Dark); in Light white cards 4 px apart from 900 px (below). */
html[data-theme="minimal"] .memberlist .resourcelist-resource {
	min-height: var(--box-row-height);
	margin: 0;
	padding: var(--space-sm) var(--space-sm) var(--space-sm) var(--space-lg);
	border: 0;
	border-radius: 0;
	background: var(--color-row-fill);
	box-shadow: none;
}

html[data-theme="minimal"] .memberlist .resourcelist-resource + .resourcelist-resource {
	border-top: 1px solid var(--color-ui-panel-border);
}

/* Minimal Light (UI-88): in the grey list of the column the member rows
   are white cards with a hairline and 6 px corners, so the empty part of
   the list stays grey; under 900 px the same cards are the chips of the
   strip (family 9). The divider stays as a transparent edge, so a row
   keeps its height; from 900 px the rows stand 4 px apart (a 3 px margin
   and the 1 px divider). */
html[data-theme="minimal"]:not([data-theme-variant="dark"]) .memberlist .resourcelist-resource {
	border-color: transparent;
	border-radius: var(--radius-md);
	background-clip: padding-box;
	box-shadow: inset 0 0 0 1px var(--color-ui-panel-border);
}

@media (min-width: 900px) {
	html[data-theme="minimal"]:not([data-theme-variant="dark"]) .memberlist .resourcelist-resource + .resourcelist-resource {
		margin-top: calc(var(--space-2xs) - 1px);
	}
}

html[data-theme="minimal"] .resource-box-body-list > .resourcelist-resource:hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] .resource-box-body-list > .resourcelist-resource.selected {
	background-color: var(--color-selected);
}

html[data-theme="minimal"] .resource-box-body-list > .resourcelist-resource.selected::before {
	content: "";
	position: absolute;
	top: 8px;
	bottom: 8px;
	left: 0;
	width: 3px;
	border-radius: 0 3px 3px 0;
	background-color: var(--color-selected-mark);
}

html[data-theme="minimal"] .resource-box-body-list > .resourcelist-resource.selected .resource-box-item-title {
	font-weight: 600;
}

html[data-theme="minimal"] .resource-box-item-container {
	display: flex;
	flex: 1 1 auto;
	flex-wrap: wrap;
	align-items: center;
	gap: 2px var(--space-lg);
	width: auto;
	min-width: 0;
}

html[data-theme="minimal"] .resource-box-item-title {
	display: flex;
	flex: 1 1 auto;
	width: auto;
	padding: 0;
	align-items: center;
	gap: var(--space-sm);
	min-width: 0;
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	font-weight: 500;
	line-height: 20px;
}

html[data-theme="minimal"] .resource-box-item-title h5 {
	margin: 0;
	padding: 0;
	font-size: inherit;
	font-weight: inherit;
	line-height: inherit;
}

html[data-theme="minimal"] .member-title,
html[data-theme="minimal"] .memberlist-member-open {
	display: flex;
	align-items: center;
	gap: var(--space-md);
	min-width: 0;
	color: inherit;
	text-decoration: none;
}

/* The secondary line spans the row under the title, indented to the text
   when the row has an avatar. */
html[data-theme="minimal"] .resource-box-item-info {
	display: flex;
	flex: 1 1 100%;
	flex-direction: row;
	flex-wrap: nowrap;
	align-items: center;
	gap: var(--space-sm);
	min-width: 0;
}

html[data-theme="minimal"] .member-title ~ .resource-box-item-info,
html[data-theme="minimal"] .resource-box-item-container:has(.member-title, .memberlist-member-open) > .resource-box-item-info {
	padding-left: 38px;
}

html[data-theme="minimal"] .resource-box-item-info-role {
	flex: 1 1 auto;
	min-width: 0;
	overflow: hidden;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-style: normal;
	line-height: 18px;
	text-overflow: ellipsis;
	white-space: nowrap;
}

html[data-theme="minimal"] .resource-box-item-info-icons {
	display: flex;
	flex: 0 0 auto;
	align-items: center;
	gap: var(--space-xs);
}

html[data-theme="minimal"] .resource-box-item-info-icons > div[style] {
	display: none;
}

/* Role and state icons: 16 px line icons in the secondary text colour,
   with a title: superuser a crown (new, /icons/ui/crown.svg), manager the
   briefcase and accountant the receipt of public/icons/ui/. The old
   filled pictograms (*_circle_grey.svg) go. Every icon of a row is drawn
   in one way: ::before masks the icon --role-icon in the colour of the
   element, so an icon with a count keeps its count visible beside it. */
html[data-theme="minimal"] .icon.resource-box-item-info-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 16px;
	min-width: 16px;
	height: 16px;
	min-height: 16px;
	margin: 0;
	background: none;
	color: var(--color-text-secondary);
	/* style.css masks some pictograms on the element itself (for example
	   .icon.organization-managed); such a mask would cut the glyph. */
	-webkit-mask: none;
	mask: none;
}

html[data-theme="minimal"] .icon.resource-box-item-info-icon::before {
	content: "";
	flex: 0 0 16px;
	height: 16px;
	background-color: currentColor;
	-webkit-mask: var(--role-icon) center / 16px no-repeat;
	mask: var(--role-icon) center / 16px no-repeat;
}

html[data-theme="minimal"] .icon.resource-box-item-info-icon.superuser-grey { --role-icon: url(/icons/ui/crown.svg); }
html[data-theme="minimal"] .icon.resource-box-item-info-icon.manager-grey { --role-icon: url(/icons/ui/briefcase.svg); }
html[data-theme="minimal"] .icon.resource-box-item-info-icon.accountant-grey { --role-icon: url(/icons/ui/receipt.svg); }
html[data-theme="minimal"] .icon.resource-box-item-info-icon.organization-managed { --role-icon: url(/icons/ui/building.svg); }

html[data-theme="minimal"] .icon.resource-box-item-info-icon.attention-red {
	--role-icon: url(/icons/ui/alert-circle.svg);
	color: var(--color-error-dark);
}

/* The member count stands beside the users icon (C13). */
html[data-theme="minimal"] .icon.resource-box-item-info-icon.user-grey {
	--role-icon: url(/icons/ui/users.svg);
	gap: var(--space-2xs);
	width: auto;
}

html[data-theme="minimal"] .icon.resource-box-item-info-icon.user-grey > span {
	position: static;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 16px;
}

/* The name of a row with a trailing value (a rate): one line from 600 px,
   cut only when it is longer than the row. Replaces the inline style of
   the name span (markup change: the class .resource-row-name). */
html[data-theme="minimal"] .resource-row-name {
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

@media (max-width: 599px) {
	/* Under 600 px the name wraps above the rate; the actions stay at the
	   right of the row. Nothing is cut. */
	html[data-theme="minimal"] .resource-box-item-title:has(> .resource-row-name) {
		flex-wrap: wrap;
		row-gap: 2px;
	}

	/* The selector is stronger than the first-child and one-line rules of
	   the row title in style.css. */
	html[data-theme="minimal"] .resourcelist-resource .resource-box-item-title > .resource-row-name {
		flex: 1 1 100%;
		overflow: visible;
		white-space: normal;
	}

	html[data-theme="minimal"] .resource-box-item-info-role {
		overflow: visible;
		white-space: normal;
	}
}

/* A value at the end of a row (a rate, an amount): tabular, primary text.
   Money is not a status, so a rate is not green. */
html[data-theme="minimal"] .resource-box-item-title .rate-mainrate-rate,
html[data-theme="minimal"] .resourcelist-resource .rate-value {
	margin-left: auto;
	color: var(--color-text-primary);
	font-weight: 500;
	font-variant-numeric: tabular-nums;
	white-space: nowrap;
}

/* The expense row: dates with the status as their last line (UX-194,
   UI-90), then the cost (negative, error ink) over the billable amount
   (success ink), then the description. */
html[data-theme="minimal"] .resourcelist-resource.expense .expense-details {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	gap: 2px;
	min-width: 0;
	padding: 0;
	border: 0;
	background: transparent;
	color: inherit;
	font: inherit;
	text-align: left;
	cursor: pointer;
}

html[data-theme="minimal"] .resourcelist-resource.expense .expense-summary {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: var(--space-lg);
}

html[data-theme="minimal"] .resourcelist-resource.expense .expense-dates {
	color: var(--color-text-primary);
	font-variant-numeric: tabular-nums;
}

html[data-theme="minimal"] .resourcelist-resource.expense .expense-amounts {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	font-weight: 500;
	font-variant-numeric: tabular-nums;
}

html[data-theme="minimal"] .resourcelist-resource.expense .expense-description {
	overflow: hidden;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
	text-overflow: ellipsis;
	white-space: nowrap;
}

/* A future expense is muted by its text colour (the view writes #aaa). */
html[data-theme="minimal"] .resourcelist-resource.expense [style*="#aaa" i] {
	color: var(--color-text-secondary) !important;
}

/* Row actions (archive, remove): 28 px quiet icon buttons that are always
   visible; hover gives the meaning colour. */
html[data-theme="minimal"] .resource-row-action {
	display: inline-flex;
	flex: 0 0 28px;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	padding: 0;
	border: 0;
	border-radius: var(--radius-md);
	background: transparent;
	color: var(--color-text-secondary);
	cursor: pointer;
}

html[data-theme="minimal"] .resource-row-action::before {
	content: "";
	width: 16px;
	height: 16px;
	background-color: currentColor;
	-webkit-mask: var(--row-action-icon) center / 16px no-repeat;
	mask: var(--row-action-icon) center / 16px no-repeat;
}

/* The views keep the wrapper of the action strip of the other themes
   (div.resource-action, style.css); here it has no box of its own, and the
   button shows its icon instead of its text "×". In a rate row the action
   stands at the end of the first line. */
html[data-theme="minimal"] .resource-action:has(> .resource-row-action) {
	display: contents;
}

html[data-theme="minimal"] .resource-action > .resource-row-action {
	font-size: 0;
}

html[data-theme="minimal"] .resource-row-action.is-archive { --row-action-icon: url(/icons/ui/archive.svg); }
html[data-theme="minimal"] .resource-row-action.is-remove { --row-action-icon: url(/icons/ui/x.svg); }

html[data-theme="minimal"] .resource-row-action.is-archive:hover {
	background-color: var(--color-warning-bright);
	color: var(--color-warning-dark);
}

html[data-theme="minimal"] .resource-row-action.is-remove:hover {
	background-color: var(--color-error-bright);
	color: var(--color-error-dark);
}

html[data-theme="minimal"] .resource-row-action:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 0;
}

/*------------------------------
=17 (continued) RATE ROWS
The rows of the rate lists of Treetops (the member, project and tax rates
of the resource panels; Skeleton has none): the row of family 17 with its
editor (.ratedetails) and its actions. The rows are not in the block that
Skeleton copies.
------------------------------*/

/* A rate editor opens below its full-width summary, never beside it. */
html[data-theme="minimal"] .resource-box-body-list > .resourcelist-resource.ratelistelement {
	flex-direction: column;
	align-items: stretch;
	gap: 0;
}

/* The inner space of a row of the default themes (10 px) is on the summary,
   so the editor below it takes the full width of the row. */
html[data-theme="minimal"] .ratelistelement > .resource-box-item-container {
	flex: 0 0 auto;
	padding: var(--space-md);
	background: transparent;
}

html[data-theme="minimal"] .ratelistelement > .ratedetails {
	box-sizing: border-box;
	width: 100%;
	min-width: 0;
	padding: var(--space-sm);
	/* The end of the editor is the end of the row content, so the cross of
	   Clear stands in the column of the remove crosses of the rows above. */
	padding-inline-end: var(--space-md);
}

/* The rate stands before the icons of the row. */
html[data-theme="minimal"] .ratelistelement > .resource-box-item-container > .resource-box-item-info {
	order: 1;
}

/* Save and Clear of a rate: 28 px targets with the 16 px check and cross
   glyphs of the role icons above (C13). */
html[data-theme="minimal"] .rate-action.icon.resource-box-item-info-icon {
	width: 28px;
	min-width: 28px;
	height: 28px;
	min-height: 28px;
	padding: 0;
	border: 0;
	border-radius: var(--radius-md);
}

/* Save and Clear are heavier than the other icons (a 2.8 stroke), and the
   two buttons touch: the glyphs stand 12 px apart (UX-245). */
html[data-theme="minimal"] .rate-icons {
	gap: 0;
}

html[data-theme="minimal"] .rate-action:is(.check-grey, .check-green) { --role-icon: url(/icons/ui/check-bold.svg); }
html[data-theme="minimal"] .rate-action:is(.cancel-grey, .cancel-red) { --role-icon: url(/icons/ui/x-bold.svg); }
/* The Save and Delete buttons of salary and tax entries and the billable
   setting of a client project draw the same mask; without it the mask shows
   as a grey square (UX-243). */
html[data-theme="minimal"] :is(.salary-action, .tax-action, .projectsetting-billable-post):is(.check-grey, .check-green) { --role-icon: url(/icons/ui/check.svg); }
html[data-theme="minimal"] :is(.salary-action, .tax-action, .projectsetting-billable-post):is(.cancel-grey, .cancel-red) { --role-icon: url(/icons/ui/x.svg); }
/* The count of categories with their own tax rate stands beside a tag, set
   like the member count beside the users icon (UX-289). */
html[data-theme="minimal"] .icon.resource-box-item-info-icon.category-grey {
	--role-icon: url(/icons/ui/tag.svg);
	gap: var(--space-2xs);
	width: auto;
}

html[data-theme="minimal"] .icon.resource-box-item-info-icon.category-grey > span {
	position: static;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 16px;
}

/* The "make new default" button of a VAT rate (blue; light grey for the
   current default) draws a star. Without a mask icon it showed as a grey
   square (UX-284); the classic themes keep their attention circle (UX-289). */
html[data-theme="minimal"] .tax-action:is(.attention-blue, .attention-lightgrey) { --role-icon: url(/icons/ui/star.svg); }
html[data-theme="minimal"] .tax-action.attention-blue { color: var(--color-focus); }
html[data-theme="minimal"] .tax-action.attention-lightgrey { color: var(--color-placeholder); }
html[data-theme="minimal"] :is(.rate-action, .salary-action, .tax-action, .projectsetting-billable-post).check-green { color: var(--color-success-dark); }
html[data-theme="minimal"] :is(.rate-action, .salary-action, .tax-action, .projectsetting-billable-post).cancel-red { color: var(--color-error-dark); }

html[data-theme="minimal"] :is(.rate-action, .salary-action).icon.resource-box-item-info-icon:hover {
	background-color: var(--color-ui-hover);
}

/* The gear of the member panel is a plain span, not an .icon.settings: it
   needs the same 16 px mask, else the span has no width and no icon shows. */
html[data-theme="minimal"] .content_header_menu_item > .member-settings-icon {
	flex: 0 0 16px;
	width: 16px;
	min-width: 16px;
	height: 16px;
	min-height: 16px;
	background: currentColor;
	-webkit-mask: url(/icons/ui/settings.svg) center / 16px no-repeat;
	mask: url(/icons/ui/settings.svg) center / 16px no-repeat;
}

/*------------------------------
=17 (continued) EXPENSE ROWS
The row of a client expense (Treetops only): its amounts end at the button
that deletes the expense. In a box of 300 px the row keeps its three lines
(badge, dates and amounts, description) with an amount of "-12,345.67 €"
(UX-271). The rule of the row is in the block of family 17 that Skeleton
copies, so these rules come after it with the same specificity.
------------------------------*/

html[data-theme="minimal"] .resourcelist-resource.expense .expense-summary {
	column-gap: var(--space-sm);
}

/* The amounts have no padding at their end, and the row has no gap before
   the button (the button has 6 px of its own around its icon). */
html[data-theme="minimal"] .resourcelist-resource.expense .expense-amounts > .rate-mainrate-rate {
	padding-right: 0;
}

html[data-theme="minimal"] .resourcelist-resource.expense > .resource-box-item-container {
	column-gap: 0;
}

/*------------------------------
=17 (continued) SALARY ROWS
The salary and work schedule entries of the member dialog (style.css
=SALARIES; Treetops only, not in the block that Skeleton copies). An entry
is not a row of family 17: it is a card with its fields in a column, on the
second surface, so that it differs from the head of the box (UI-70). The
block also holds the two rules of the member dialog that follow the field
margin rules of "25 (continued)" (UX-275, see the comments).
------------------------------*/

html[data-theme="minimal"] .resource-box-body-list > .resourcelist-resource.salarylistelement {
	flex-direction: column;
	align-items: stretch;
	gap: 0;
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-md);
	background: var(--color-background-secondary);
	/* The frame is the edge; no second ring of family 17. */
	box-shadow: none;
}

/* The tick box of a weekday keeps the small gap above its hour field (UX-244).
   The rule of every checkbox of this theme sets margin 0 and comes later with
   the same specificity, so this selector is one class stronger. */
html[data-theme="minimal"] .salary-work-schedule .salary-work-schedule-day input.salary-schedule-working-day[type="checkbox"] {
	margin: 0 0 var(--space-xs);
}

/* A hidden-label caption stands out of flow at the end of the margin above
   it. After the title of a section of the member dialog (the "Member role"
   select) the 10 px margin of the title collapses into the 24 px above the
   block field, so the caption would cover the top of the field. The title
   gives up its margin: the caption stands 18 px above the field with the 6 px
   gap of the other captions (UX-275). The rule stands here, outside the
   blocks that Skeleton copies. It is the twin of the .field-action-row rule
   of "25 (continued)": UX-66 (dev/REMAINING_WORK.md) takes the dialogs out of
   Minimal's field margin rules; then revisit this rule. */
html[data-theme="minimal"] .member-edit-section-title:has(+ label.visually-hidden + .organization-input) {
	margin-bottom: 0;
}

/* The buttons after the salary field stay level with the middle of the field
   (UX-275). The field of this theme has the 10 px margin of the other
   fields under it (the rule of style.css has 5 px), so the column of the
   buttons takes off 10 px at the bottom. UX-66 (dev/REMAINING_WORK.md) takes
   the dialogs out of that margin rule; then this padding must follow the new
   margin. The 14 px top padding in style.css assumes a field label of one
   line. */
html[data-theme="minimal"] .salary-actions {
	padding-bottom: var(--space-md);
}

/*------------------------------
=18 TICKET ROWS AND TASK GROUPS
Replaces the look of: .outerframe, .tickets-project-title, .ticket,
.ticket-title, .ticket-pin-toggle, .ticket-name, .ticket-name-text,
.ticket-project-label, .ticket-priority-badge, .ticket-low-badge,
.ticket-difficulty, .ticket-due, .ticket-overdue, .ticket-labels,
.ticket-label, .ticket-members-container, .ticket-low-priority and
.ticket-high-priority. style.css keeps the columns and the line count of
the row (UX-327). Here are only the values that follow the look: the
people column (--ticket-people-column), the difficulty bars
(--ticket-difficulty-width), the floors of the details and the due date
on three lines (--ticket-details-floor, --ticket-due-floor) and the
height of .ticket-center-block.
------------------------------*/

/* A project on the Tickets page is one box: the project title, the task
   rows, the ticket rows, the add row. */
html[data-theme="minimal"] .outerframe.project {
	box-sizing: border-box;
	margin: 0 0 var(--space-xl);
	padding: var(--space-lg) var(--space-xl) var(--space-sm);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
	box-shadow: none;
}

html[data-theme="minimal"] .tickets-project-title {
	padding: var(--space-2xs) 0 var(--space-lg);
	color: var(--color-text-primary);
	font-size: var(--font-size-lg);
	font-weight: 600;
	line-height: 24px;
	letter-spacing: -.01em;
	text-align: left;
}

/* The box holds no empty strips: the list of loose tickets shows only with
   tickets, and the line break between the parts takes no room. The last
   task row has a divider under it, above the tickets and the add row. */
html[data-theme="minimal"] .outerframe > br,
html[data-theme="minimal"] .outerframe > .items:not(:has(> *)) {
	display: none;
}

html[data-theme="minimal"] .outerframe > .accordion.task:not(:has(+ .accordion)) {
	border-bottom: 1px solid var(--color-ui-panel-border);
}

/* In Dark the loose tickets draw their own divider at the top, so the last
   task row draws none above them: two dividers 1 px apart read as a 2 px
   bar. */
html[data-theme="minimal"][data-theme-variant="dark"] .outerframe > .accordion.task:not(:has(+ .accordion)):has(~ .items > .ticket) {
	border-bottom: 0;
}

/* Task rows inside a project box: rows with a divider, no own frame, with
   the row fill (white in the grey box in Light, UI-88; none in Dark). */
html[data-theme="minimal"] .outerframe .accordion.task > .accordion-header {
	margin-top: 0;
	padding-left: var(--space-sm);
	border-width: 1px 0 0;
	border-radius: 0;
	background: var(--color-row-fill);
}

html[data-theme="minimal"] .outerframe .accordion.task > .accordion-header:hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] .outerframe .accordion.task > .accordion-header:has(> .clickarea[aria-expanded="true"]) {
	background: var(--color-row-fill);
}

/* In Light the open task row is a white card, so its hover must win over
   the rule above (UI-88). Dark keeps its look. */
html[data-theme="minimal"]:not([data-theme-variant="dark"]) .outerframe .accordion.task > .accordion-header:has(> .clickarea[aria-expanded="true"]):hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] .outerframe .accordion.task > .accordion-body {
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: transparent;
}

/* The tickets of an open task are set in (owner, 2026-11-17, UX-318), as
   in the classic themes, with the look of Minimal. They stand in a well
   that hangs from the task row (owner, 2026-11-17: "attached to the task
   (like in the classic themes)"): no gap, the bottom corners of the task
   row are square, and the well has 6 px corners only at the bottom. The
   well has a hairline and the sunken surface of the theme (lighter than
   the box in Light, darker in Dark). In Light the bottom hairline of the
   white task card is the line between the two; in Dark the task row gets
   the frame of the well at its top and sides, and the top hairline of the
   well is the line between the two. The tickets are 4 px under the top
   edge of the well and 8 px in from its sides and its bottom. In Light the
   tickets are white cards 4 px apart. In Dark the first ticket draws no
   divider at the top edge, and the 4 px at the top and under the well keep
   two hairlines apart (also when the quick filter hides the first ticket).
   A task shows the well only while it is open and while one of its
   tickets is visible: a closed task, an open task without tickets and a
   task whose tickets the quick filter hides keep a task row with round
   corners. */
html[data-theme="minimal"] .outerframe .accordion.task > .accordion-body:has(> .ticket:not([style*="display: none"])) {
	margin-top: 0;
	padding: var(--space-2xs) var(--ticket-set-in) var(--space-sm);
	border: 1px solid var(--color-ui-panel-border);
	border-top-width: 0;
	border-radius: 0 0 var(--radius-md) var(--radius-md);
	background: var(--color-background-secondary);
}

html[data-theme="minimal"] .outerframe .accordion.task:has(> .accordion-header > .clickarea[aria-expanded="true"]):has(> .accordion-body > .ticket:not([style*="display: none"])) > .accordion-header {
	border-bottom-right-radius: 0;
	border-bottom-left-radius: 0;
}

html[data-theme="minimal"][data-theme-variant="dark"] .outerframe .accordion.task:has(> .accordion-header > .clickarea[aria-expanded="true"]):has(> .accordion-body > .ticket:not([style*="display: none"])) > .accordion-header {
	border: 1px solid var(--color-ui-panel-border);
	border-bottom-width: 0;
	border-radius: var(--radius-md) var(--radius-md) 0 0;
}

html[data-theme="minimal"][data-theme-variant="dark"] .outerframe .accordion.task > .accordion-body:has(> .ticket:not([style*="display: none"])) {
	margin-bottom: var(--space-2xs);
	border-top-width: 1px;
}

html[data-theme="minimal"] .outerframe .accordion.task > .accordion-body > .ticket:first-child {
	border-top-color: transparent;
}

html[data-theme="minimal"] .outerframe .items {
	border: 0;
	border-radius: 0;
	background: transparent;
}

/* The loose tickets of a project box stand as far in as the tickets in the
   well (its 8 px padding and its hairline), as the bands of the classic
   themes do. So all ticket rows of a box have one width and the same
   column edges (UX-318). */
html[data-theme="minimal"] .outerframe {
	--ticket-set-in: var(--space-sm);
}

html[data-theme="minimal"] .outerframe.project > .items {
	padding-inline: calc(var(--ticket-set-in) + 1px);
}

/* A ticket row: at least 44 px (10 px above and below the 24 px cells).
   The row is not a control: the name is the button that opens the ticket,
   and the pin is its sibling (markup change, see the spec). A click
   elsewhere on the row opens the ticket through the handler of
   treetops.tickets.js, which serves every theme. An overlay over the row
   would cover the avatars and their full-name tooltips. The row keeps the
   pointer cursor and the hover colour of a target.
   style.css owns the columns and the line count of the row in every theme
   (UX-327): the pin, the code, the title, the details, the due date and the
   people, their widths and how they grow. Here are the look and the
   vertical spacing: the cells align to the top of the row, the lines of a
   row are 6 px apart, the difficulty bars take 16 px, and four pictures
   take 116 px (see the people below). The row shows every
   label (UI-55, answer 22). The title wraps when the name, the badge and
   the labels do not fit, and the row grows. */
html[data-theme="minimal"] .ticket {
	--ticket-difficulty-width: 16px;
	--ticket-people-column: 116px;
	/* The floors of the three-line row (style.css). The details do not
	   shrink: the lead, the difficulty of 16 px, the margin, the 48 px bar,
	   its gap of 8 px and "100% fertig" (68.3 px in Inter 12 px) fill the
	   column of 164 px. The widest date in 13 px Inter with tabular figures
	   is 77.1 px. */
	--ticket-details-floor: var(--ticket-details-column);
	--ticket-due-floor: 80px;
	position: relative;
	align-items: flex-start;
	row-gap: var(--space-xs);
	box-sizing: border-box;
	min-height: var(--box-row-height);
	margin: 0;
	padding-block: 10px;
	border: 0;
	border-top: 1px solid var(--color-ui-panel-border);
	background: var(--color-row-fill);
	color: var(--color-text-primary);
	cursor: pointer;
	transition: background-color var(--motion-fast) ease;
}

html[data-theme="minimal"] .ticket:hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] .ticket:has(.ticket-open:focus-visible) {
	outline: 2px solid var(--color-focus);
	outline-offset: -2px;
	border-radius: var(--radius-md);
}

/* The open button keeps the keyboard and the screen readers (hidden on
   screen, see the rule of the hidden parts). It needs no face of its own:
   its focus draws the ring on the row. */
html[data-theme="minimal"] .ticket-open {
	padding: 0;
	border: 0;
	background: transparent;
	color: inherit;
	font: inherit;
}

html[data-theme="minimal"] .ticket-open:focus-visible {
	outline: none;
}

/* Priority: a priority word instead of a row tint. High: the red
   "Critical" badge; low: the neutral "Low" badge (new markup, see the
   spec). The row keeps the row fill. */
html[data-theme="minimal"] .ticket.ticket-low-priority,
html[data-theme="minimal"] .ticket.ticket-high-priority {
	background: var(--color-row-fill);
}

/* In Light a priority ticket is a white card: its hover wins over the rule
   above (UI-88). Dark keeps its look. */
html[data-theme="minimal"]:not([data-theme-variant="dark"]) .ticket:is(.ticket-low-priority, .ticket-high-priority):hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] .ticket.ticket-low-priority .ticket-name-text {
	color: var(--color-text-secondary);
}

/* The title column is one line of text (owner, 2026-11-17: "All in one
   long line that breaks at whatever element does not fit the line"): the
   name as plain text, which wraps word by word, then the priority badge and
   each label, which follow the last word of the name and go to a new line
   only when they do not fit. The lines are 24 px high, so a line of labels
   has the height of a line of text, and the pin and the code stand in the
   middle of the first line. The word spaces of the markup separate the
   parts (3.9 px in Inter 14 px). The name and the badge add a right margin
   of 4 px: 8 px separate the name, the badge and the first label, 4 px the
   labels, and a part that starts a line stands at the left edge of the
   column. On two lines the title has 2 px above and below it. */
html[data-theme="minimal"] .ticket-title {
	--ticket-title-top: calc(var(--ticket-two-lines, 0) * 2px);
	display: block;
	min-height: 24px;
	margin: 0;
	padding-block: var(--ticket-title-top);
	font-size: var(--font-size-md);
	line-height: 24px;
}

/* The name: plain text that wraps inside the title column and is never cut
   (owner, 2026-11-17: the title and its labels may make the row taller).
   An archived ticket is struck through in the secondary text. */
html[data-theme="minimal"] .ticket-name-text {
	margin-right: var(--space-2xs);
	overflow-wrap: anywhere;
	font-weight: 500;
}

html[data-theme="minimal"] .ticket-name-text.is-archived {
	color: var(--color-text-secondary);
	text-decoration: line-through;
}

/* The project code of the dashboard, in the code column of style.css:
   "AAAA-BBBB" is 78.5 px in Inter 13 px. It stands at the top of the
   first line. */
html[data-theme="minimal"] .ticket-project-label {
	top: var(--ticket-title-top);
	display: block;
	margin: 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-variant-numeric: tabular-nums;
}

/* The pin: a 24 px toggle in the middle of the pin column of style.css, at
   the first line (also beside a name of several lines, like the other
   cells); a pinned ticket shows the filled star in the accent ink, an
   unpinned one shows it only on row hover or focus. */
html[data-theme="minimal"] .ticket-pin-toggle {
	display: inline-flex;
	top: var(--ticket-title-top);
	align-items: center;
	justify-content: center;
	width: 24px;
	height: 24px;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: var(--radius-sm);
	background: transparent;
	color: var(--color-text-secondary);
	font-size: var(--font-size-md);
	line-height: 1;
	opacity: 0;
	cursor: pointer;
}

html[data-theme="minimal"] .ticket:is(:hover, :focus-within) .ticket-pin-toggle,
html[data-theme="minimal"] .ticket-pin-toggle.active,
html[data-theme="minimal"] .ticket-pin-toggle:focus-visible {
	opacity: 1;
}

/* A touch screen has no hover: the pin is always visible there. */
@media (hover: none) {
	html[data-theme="minimal"] .ticket-pin-toggle {
		opacity: 1;
	}
}

html[data-theme="minimal"] .ticket-pin-toggle.active {
	color: var(--color-button-confirm-ink);
}

html[data-theme="minimal"][data-theme-variant="dark"] .ticket-pin-toggle.active {
	color: var(--color-border-highlight);
}

html[data-theme="minimal"] .ticket-pin-toggle:hover {
	background-color: var(--color-background-quaternary);
}

html[data-theme="minimal"] .ticket-pin-toggle:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 0;
}

/* The details column and the due-date column of style.css: the cells
   stand in the middle of the first line of 24 px. */
html[data-theme="minimal"] .ticket-center-block {
	min-height: 24px;
}

/* Difficulty: three bars of rising height; the number of filled bars is
   the level (easy 1, medium 2, advanced 3), the colour repeats it. */
html[data-theme="minimal"] .ticket-difficulty {
	display: flex;
	align-items: flex-end;
	gap: 2px;
	height: 14px;
}

html[data-theme="minimal"] .ticket-difficulty-bar {
	width: 4px;
	float: none;
	margin: 0;
	border-radius: 1px;
}

html[data-theme="minimal"] .ticket-difficulty-bar:nth-child(1) { height: 6px; }
html[data-theme="minimal"] .ticket-difficulty-bar:nth-child(2) { height: 10px; }
html[data-theme="minimal"] .ticket-difficulty-bar:nth-child(3) { height: 14px; }

html[data-theme="minimal"] .ticket-due {
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-variant-numeric: tabular-nums;
	line-height: 18px;
}

/* Overdue: the error ink and semibold, so it does not depend on hue. */
html[data-theme="minimal"] .ticket-due.ticket-overdue {
	color: var(--color-error-dark);
	font-weight: 600;
}

/* Labels show their names: a pill with a 8 px dot in the label colour.
   They follow the name and the badge (markup change); all of them show.
   Each label is a part of the line of the title (see there), so it goes to
   a new line on its own when it does not fit. A pill of 22 px stands in the
   middle of a line of 24 px. */
html[data-theme="minimal"] .ticket-labels {
	display: inline;
}

html[data-theme="minimal"] .ticket-label {
	display: inline-flex;
	align-items: center;
	gap: var(--space-xs);
	box-sizing: border-box;
	width: auto;
	margin: 1px 0;
	height: 22px;
	vertical-align: top;
	padding: 0 var(--space-sm) 0 var(--space-xs);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-pill);
	background: var(--color-ui-panel);
	color: var(--color-text-primary);
	font-size: var(--font-size-xs);
	font-weight: 500;
	line-height: 16px;
	white-space: nowrap;
}

html[data-theme="minimal"] .ticket-label::before {
	content: "";
	flex: 0 0 8px;
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: var(--label-colour);
	box-shadow: var(--shadow-marker);
}

/* People: 24 px avatars with a 4 px gap; the assignee first, with a 2 px
   accent ring outside a 2 px panel gap. Four avatars take 116 px (the
   assignee with its 4 px margins and three others): the people column of
   the row (--ticket-people-column). From the fifth
   avatar the people wrap to another line, 8 px under the first (the
   assignee ring keeps its gap), and the row grows. So the people never
   cover the due date (owner correction C7; owner, 2026-11-17: "4 member
   icons per line, then wrap"). */
html[data-theme="minimal"] .ticket-members-container {
	flex-direction: row;
	align-content: flex-start;
	gap: var(--space-sm) var(--space-2xs);
	min-height: 24px;
}

html[data-theme="minimal"] .ticket-members-container > .ticket-members {
	width: 24px;
	height: 24px;
	box-shadow: 0 0 0 2px var(--color-background-item);
}

html[data-theme="minimal"] .ticket-members-container > .ticket-members + .ticket-members {
	margin-left: 0;
}

html[data-theme="minimal"] .ticket-members-container > .ticket-members.assignee {
	order: -1;
	box-shadow: 0 0 0 2px var(--color-background-item), 0 0 0 4px var(--color-border-highlight);
	margin: 0 var(--space-2xs);
}

/* The initials keep the 12 px floor of the type scale in the 24 px avatar
   (family 22); a tighter spacing fits two letters. */
html[data-theme="minimal"] .ticket-members-container .ticket-member-fallback {
	font-size: var(--font-size-xs);
	letter-spacing: -.04em;
}

@media (max-width: 899px) {
	html[data-theme="minimal"] .outerframe.project {
		padding-left: var(--space-lg);
		padding-right: var(--space-lg);
	}
}

/* The badges write the words of the priority select ("Critical", "Low").
   In the line of the title a badge of 20 px stands in the middle of a line
   of 24 px, with the right margin of 4 px (see the title). */
html[data-theme="minimal"] .ticket-title > :is(.ticket-priority-badge, .ticket-low-badge) {
	margin: 2px var(--space-2xs) 2px 0;
	vertical-align: top;
}

/*------------------------------
=19 DASHBOARD SECTIONS, BILL ROWS AND THE ACTIVITY LOG
Replaces: .org-dashboard-section*, .dashboard-titlebar, .items, .item,
the look of the .bill rows (their layout is the layout of style.css),
.bill .triangle, .billcanceled, .logbookentry, the bill month totals.
------------------------------*/

html[data-theme="minimal"] .org-dashboard-section {
	margin: 0 0 var(--space-4xl);
}

html[data-theme="minimal"] .org-dashboard-section-header {
	display: flex;
	align-items: center;
	gap: var(--space-2xs);
	min-height: var(--control-height);
	margin-bottom: var(--space-lg);
}

/* The section toggle is a button that looks like a heading: the title and
   a chevron; hover gives the quiet surface. */
html[data-theme="minimal"] .org-dashboard-section-toggle {
	display: inline-flex;
	align-items: center;
	gap: var(--space-xs);
	height: var(--control-height);
	margin-left: calc(-1 * var(--space-sm));
	padding: 0 var(--space-sm);
	border: 0;
	border-radius: var(--radius-md);
	background: transparent;
	color: var(--color-text-primary);
	cursor: pointer;
}

html[data-theme="minimal"] .org-dashboard-section-toggle:hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] .org-dashboard-section-toggle:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 0;
}

html[data-theme="minimal"] .org-dashboard-section-title {
	font-size: var(--font-size-lg);
	font-weight: 600;
	letter-spacing: -.01em;
	line-height: 24px;
}

html[data-theme="minimal"] .org-dashboard-section-chevron {
	width: 16px;
	height: 16px;
	font-size: 0;
	background-color: var(--color-text-secondary);
	-webkit-mask: url(/icons/ui/chevron-down.svg) center / 14px no-repeat;
	mask: url(/icons/ui/chevron-down.svg) center / 14px no-repeat;
	transform: rotate(-90deg);
	transition: transform var(--motion-base) var(--ease-standard);
}

html[data-theme="minimal"] .org-dashboard-section-toggle[aria-expanded="true"] .org-dashboard-section-chevron {
	transform: rotate(0deg);
}

/* Section tools stand at the right end of the section header (the activity
   log: reload, filter, download; an empty log keeps only the reload). */
html[data-theme="minimal"] .org-dashboard-section-tools {
	display: flex;
	gap: var(--space-2xs);
	margin-left: auto;
}

/* The application: the view writes the help and the tools of the log
   twice, in the section header for these themes and in the head of the
   box for the others (organization.erb); the box head goes here. An empty
   log has nothing to filter or download, so only the reload stays (it also
   loads the log again after an error); an empty log with a filter in force
   also keeps the filter, so that the filter can be changed (UI-71). The
   script marks the list busy while it loads (treetops.organizations.js), so
   a reload, which empties the list first, keeps the tools and the focus. */
html[data-theme="minimal"] .org-dashboard-section[data-section="latest-activity"] .resource-box > .resource-box-top {
	display: none;
}

html[data-theme="minimal"] .org-dashboard-section:has(.logbooks:empty:not([aria-busy="true"])) .org-dashboard-section-tools > :not(.logbooks-reload, .logbooks-filter.is-filtered) {
	display: none;
}

/* The application: master's section body has 20 px margins (style.css);
   here the header keeps 12 px to the content. */
html[data-theme="minimal"] .org-dashboard-section-body {
	margin: 0;
}

/* A list of items: one bordered surface with dividers. The rules name the
   parent of a row (a list of items, or the body of a bill month), so that
   they do not reach the entries of a chart legend (li.item, family 12);
   :where() keeps their specificity. In the application the rows of a bill
   month stand in the body of the month without a list element (the
   accordion of family 8 loads bills_timeframe.erb into it), so each row
   draws its part of the frame. */
html[data-theme="minimal"] .items {
	display: flex;
	flex-direction: column;
	align-items: stretch;
	overflow: visible;
	padding: 0;
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
}

html[data-theme="minimal"] :where(.items, .accordion-body) > .item {
	position: relative;
	display: flex;
	align-items: center;
	width: auto;
	min-width: 0;
	margin: 0;
	background-color: var(--color-row-fill);
	cursor: pointer;
}

html[data-theme="minimal"] :where(.items, .accordion-body) > .item + .item {
	border-top: 1px solid var(--color-ui-panel-border);
}

html[data-theme="minimal"] :where(.items, .accordion-body) > .item:first-child {
	border-top-left-radius: var(--radius-lg);
	border-top-right-radius: var(--radius-lg);
}

html[data-theme="minimal"] :where(.items, .accordion-body) > .item:last-child {
	border-bottom-left-radius: var(--radius-lg);
	border-bottom-right-radius: var(--radius-lg);
}

html[data-theme="minimal"] :where(.items, .accordion-body) > .item:hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] .accordion-body > .item {
	border-right: 1px solid var(--color-ui-panel-border);
	border-left: 1px solid var(--color-ui-panel-border);
	background-color: var(--color-background-item);
}

/* In Light a bill row of an open month is a white card: its hover wins over
   the rule above (UI-88). Dark keeps its look. */
html[data-theme="minimal"]:not([data-theme-variant="dark"]) .accordion-body > .item:hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] .accordion-body > .item:first-child {
	border-top: 1px solid var(--color-ui-panel-border);
}

html[data-theme="minimal"] .accordion-body > .item:last-of-type {
	border-bottom: 1px solid var(--color-ui-panel-border);
	border-bottom-left-radius: var(--radius-lg);
	border-bottom-right-radius: var(--radius-lg);
}

/* Minimal Light (UI-88): white rows in a grey container, as in the
   classic themes. The rows of these lists are white cards 4 px apart, with
   a hairline and 6 px corners, as the rows of a box (family 17): the bill
   rows of the dashboard and of a bill month, the task and ticket rows of
   the dashboard and of a project box on Tickets, and the time-and-leave
   rows of a member (family 9). The Mikron rows of a month (family 8) and
   the member list (family 9, shared with Skeleton) have their own rules.
   A row keeps its borders as transparent edges, so it keeps its height and
   its columns; the gap is a 3 px margin and the 1 px transparent divider
   above it. A list of the dashboard and the time-and-leave list grow
   outwards by their 6 px of grey, so their rows keep their place and
   width. */
html[data-theme="minimal"]:not([data-theme-variant="dark"]) .org-dashboard-section-body > .items,
html[data-theme="minimal"]:not([data-theme-variant="dark"]) .member-time-leave-rows {
	margin-right: calc(-1 * var(--space-xs));
	margin-left: calc(-1 * var(--space-xs));
	padding: var(--space-xs);
	border-radius: calc(var(--radius-lg) + var(--space-xs));
}

html[data-theme="minimal"]:not([data-theme-variant="dark"]) :is(.items, .accordion-body) > .item,
html[data-theme="minimal"]:not([data-theme-variant="dark"]) .ticket,
html[data-theme="minimal"]:not([data-theme-variant="dark"]) .outerframe .accordion.task > .accordion-header,
html[data-theme="minimal"]:not([data-theme-variant="dark"]) .member-time-leave-row {
	border-color: transparent;
	border-radius: var(--radius-md);
	background-clip: padding-box;
	box-shadow: inset 0 0 0 1px var(--color-ui-panel-border);
}

html[data-theme="minimal"]:not([data-theme-variant="dark"]) :is(.items, .accordion-body) > .item + .item,
html[data-theme="minimal"]:not([data-theme-variant="dark"]) .ticket:not(:first-child),
html[data-theme="minimal"]:not([data-theme-variant="dark"]) .outerframe .ticket,
html[data-theme="minimal"]:not([data-theme-variant="dark"]) .outerframe .accordion.task + .accordion.task > .accordion-header,
html[data-theme="minimal"]:not([data-theme-variant="dark"]) .member-time-leave-row + .member-time-leave-row {
	margin-top: calc(var(--space-2xs) - 1px);
}

html[data-theme="minimal"]:not([data-theme-variant="dark"]) .outerframe > .accordion.task:not(:has(+ .accordion)) {
	border-bottom-color: transparent;
}

/* The bill rows have the layout of the default themes (UX-134, UI-78):
   style.css sets the cells, their widths, the line count and what is
   visible. These rules give only the look of the theme: the colours, the
   type, the focus ring and the separators of the list (above). The row is
   a button: it takes the font of the theme, and its focus ring follows the
   round corners of the first and the last row. */
html[data-theme="minimal"] .item.bill > .item-content {
	border-radius: inherit;
	font-family: inherit;
}

html[data-theme="minimal"] .item.bill > .item-content:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: -2px;
}

html[data-theme="minimal"] .bill .triangle {
	font-size: var(--font-size-xs);
}

/* Direction marks keep 3:1 or more, also on a cancelled bill. */
html[data-theme="minimal"] .bill .triangle.outgoing { color: var(--color-success-dark); }
html[data-theme="minimal"] .bill .triangle.incoming { color: var(--color-error-dark); }

html[data-theme="minimal"] .bill .triangle:has(+ .properties.billcanceled) {
	color: var(--color-text-secondary);
}

/* The text of a bill row is 13 px (the sm token of these themes): Inter
   is wider than the fonts of the default themes, and at 14 px a generated
   number ("SA-BMB-202609", 115 px) and an English date ("received at
   30/09/2026", 158 px) do not fit the columns of the default themes (112
   and 150 px). The number cell keeps 14 px, so that its width of 8em stays
   the 112 px of the default themes; the text in it is 13 px. */
html[data-theme="minimal"] .bill .properties :is(.billnumber-text, .center, .billamount) {
	font-size: var(--font-size-sm);
}

/* The number in 500 weight, without tabular figures (with them it needs
   114 px at 13 px). A longer number ends with an ellipsis (wide layout),
   and its title gives the full number (bills_timeframe.erb). */
html[data-theme="minimal"] .bill .properties .billnumber {
	font-weight: 500;
}

html[data-theme="minimal"] .bill .properties .center .centercenter,
html[data-theme="minimal"] .bill .properties .center .righthandside.billprocessed {
	color: var(--color-text-secondary);
}

html[data-theme="minimal"] .bill .properties .billamount {
	font-weight: 600;
	font-variant-numeric: tabular-nums;
}

/* The menu trigger of family 3 (32 px) stands in the middle of the 40 px
   menu column of the default themes. */
html[data-theme="minimal"] .item.bill .menu-button {
	margin: 0 var(--space-2xs);
}

/* An overdue date in the second date cell: the view writes #E74C3C inline
   (3.82:1 on white, 3.90:1 on the Dark panel); the error ink of the theme
   replaces it (5.23:1 and 5.89:1). The app maps only the first date cell
   (.lefthandside span). */
html[data-theme="minimal"] .bill .billprocessed [style*="#e74c3c" i] {
	color: var(--color-error-dark) !important;
}

/* A cancelled bill: muted text, the number and the amount struck. Master's
   rule strikes the whole row (style.css). */
html[data-theme="minimal"] .bill .properties.billcanceled {
	color: var(--color-text-secondary);
	text-decoration: none;
}

html[data-theme="minimal"] .bill .properties.billcanceled .billnumber > .billnumber-text {
	text-decoration: line-through;
}

/* The status colours of the amounts (UI-55, answer 4). The view writes
   bright colours inline (bills_timeframe.erb); the status inks of the theme
   replace them, 4.5:1 or more on the row. Only !important wins over the
   inline colour. The default themes keep the bright colours of master. */
html[data-theme="minimal"] .bill .billamount[style*="#ffa500" i] {
	color: var(--color-warning-dark) !important;
}

html[data-theme="minimal"] .bill .billamount[style*="#2ecc71" i] {
	color: var(--color-success-dark) !important;
}

html[data-theme="minimal"] .bill .billamount[style*="#a020f0" i] {
	color: var(--color-bill-purple) !important;
}

/* The status "Paid by recipient" of a bill (FIN-53): a blue ink with
   4.5:1 or more on the row in Light and in Dark. The tokens stand here,
   because the token rules and minimal-dark.css are copies of Skeleton's. */
html[data-theme="minimal"] {
	--color-status-reported: #1d4ed8;
}

html[data-theme="minimal"][data-theme-variant="dark"] {
	--color-status-reported: #7cb4ff;
}

html[data-theme="minimal"] .bill .billamount[style*="#3498db" i] {
	color: var(--color-status-reported) !important;
}

html[data-theme="minimal"] .bill :is(.billamount, .lefthandside span)[style*="#e74c3c" i] {
	color: var(--color-error-dark) !important;
}

html[data-theme="minimal"] .bill .billamount[style*="#999" i] {
	color: var(--color-text-secondary) !important;
}

html[data-theme="minimal"] .bill .properties.billcanceled .billamount {
	color: var(--color-text-secondary) !important;
	text-decoration: line-through;
}

/* The menu of a bill row and of a bill month hangs under its trigger
   (family 3). The cut rule of .bill div (style.css: one line, overflow
   hidden) would clip it in the menu box, in the row, and in the header and
   the body of the month (the month is an .accordion.bill). These boxes
   therefore show what overflows them. The default themes place the menu
   with position: fixed, which these boxes do not clip. */
html[data-theme="minimal"] .accordion.bill > :is(.accordion-header, .accordion-body),
html[data-theme="minimal"] .bill .item.bill,
html[data-theme="minimal"] .bill .menu-button,
html[data-theme="minimal"] .bill .menu-button > .menu {
	overflow: visible;
}

/* The totals of a bill month: a summary row under the list. In the
   application the totals are a paragraph with one span per line and line
   breaks for the default themes; master's rule gives it a right margin. */
html[data-theme="minimal"] .bill-totals {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: 2px;
	margin: var(--space-lg) 0 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-variant-numeric: tabular-nums;
	line-height: 18px;
}

html[data-theme="minimal"] .bill-totals strong {
	color: var(--color-text-primary);
	font-weight: 600;
}

html[data-theme="minimal"] .bill-totals > br {
	display: none;
}

/* A line of the totals wraps in a narrow window instead of running out
   at the left. The month is an .accordion.bill, so the cell rule of the bill
   rows (.bill span: one line, cut with an ellipsis) reaches the totals. */
html[data-theme="minimal"] .bill-totals,
html[data-theme="minimal"] .bill-totals span {
	white-space: normal;
}

html[data-theme="minimal"] .bill-totals > span {
	max-width: 100%;
	overflow: visible;
	text-align: right;
}

/* The activity log: a 16 px state ring, the time in 12 px tabular, the
   message. An entry with an error has the error ring. */
html[data-theme="minimal"] .resource-box-body-list > .logbookentry,
html[data-theme="minimal"] .logbookentry {
	display: flex;
	flex-direction: row;
	flex-wrap: nowrap;
	align-items: flex-start;
	gap: var(--space-lg);
	padding: var(--space-md) var(--space-xl);
}

html[data-theme="minimal"] .logbookentry .errorclass {
	flex: 0 0 10px;
	width: 10px;
	height: 10px;
	margin: 5px 0 0;
	box-sizing: border-box;
	border: 2px solid var(--color-control);
	border-radius: 50%;
	background: transparent;
}

html[data-theme="minimal"] .logbookentry .errorclass.is-error,
html[data-theme="minimal"] .logbookentry .errorclass.critical-red {
	border-color: var(--color-error-dark);
	background: var(--color-error-dark);
}

html[data-theme="minimal"] .logbookentry .logdate {
	flex: 0 0 168px;
	padding: 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-variant-numeric: tabular-nums;
	line-height: 20px;
}

/* The dash that the other themes show between the date and the message
   (treetops.organizations.js): the columns separate them here. */
html[data-theme="minimal"] .logbookentry .logdate-separator {
	display: none;
}

html[data-theme="minimal"] .logbookentry .logmessage {
	flex: 1 1 auto;
	min-width: 0;
	overflow: visible;
	text-overflow: clip;
	white-space: normal;
	font-size: var(--font-size-md);
	line-height: 20px;
}

@media (max-width: 599px) {
	html[data-theme="minimal"] .resource-box-body-list > .logbookentry,
	html[data-theme="minimal"] .logbookentry {
		flex-wrap: wrap;
		row-gap: 0;
	}

	/* The date shares the first line with the ring; the message takes the
	   full width under them. */
	html[data-theme="minimal"] .logbookentry .logdate {
		flex: 1 1 0;
		min-width: 0;
	}

	html[data-theme="minimal"] .logbookentry .logmessage {
		flex-basis: 100%;
		padding-left: 22px;
	}
}

/* The application: treetops.organizations.js marks an error entry with
   .critical-red (the sheet: .is-error). An empty log says so instead of
   showing an empty box (the text is data-empty-label of the list); a list
   that is loading is not empty yet. */
html[data-theme="minimal"] .resource-box-body-list.logbooks:empty:not([aria-busy="true"])::before {
	content: attr(data-empty-label);
	display: block;
	padding: var(--space-xl);
	color: var(--color-text-secondary);
	font-size: var(--font-size-md);
	text-align: center;
}

/*------------------------------
=20 BADGES AND PILLS
Replaces: .expense-status-badge, .absence-status-badge,
.project-target-progress-badge, .ticket-priority-badge, .mikron-entry-badge,
.member-lifecycle-badge, the "Direction unknown" badge.
------------------------------*/

html[data-theme="minimal"] .expense-status-badge,
html[data-theme="minimal"] .absence-status-badge,
html[data-theme="minimal"] .project-target-progress-badge,
html[data-theme="minimal"] .ticket-priority-badge,
html[data-theme="minimal"] .status-badge {
	display: inline-flex;
	align-items: center;
	box-sizing: border-box;
	height: 20px;
	padding: 0 var(--space-xs);
	border: 1px solid transparent;
	border-radius: var(--radius-sm);
	background: var(--color-background-secondary);
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-style: normal;
	font-weight: 500;
	line-height: 16px;
	white-space: nowrap;
	vertical-align: middle;
}

html[data-theme="minimal"] .status-badge.is-neutral,
html[data-theme="minimal"] .expense-status-badge.expense-status-closed,
html[data-theme="minimal"] .expense-interval.expense-status-closed {
	border-color: var(--color-ui-panel-border);
}

/* The interval badge of a recurring expense takes the colours of the status
   badge of its expense (UX-237): open in the warning tint, closed neutral
   with the hairline. The frame keeps the size of the badge. */
html[data-theme="minimal"] .expense-interval {
	box-sizing: border-box;
	border: 1px solid transparent;
}

html[data-theme="minimal"] .expense-interval.expense-status-closed {
	background: var(--color-background-secondary);
	color: var(--color-text-secondary);
}

/* Each status badge takes the badge ink of its status (=TOKENS), so the word
   has 4.5:1 on the tint while the text inks of the page stay unchanged. */
html[data-theme="minimal"] .status-badge.is-success { background: var(--color-success-bright); color: var(--color-badge-success-ink); }
html[data-theme="minimal"] .status-badge.is-warning,
html[data-theme="minimal"] .expense-status-badge.expense-status-open,
html[data-theme="minimal"] .expense-interval.expense-status-open { background: var(--color-warning-bright); color: var(--color-badge-warning-ink); }
html[data-theme="minimal"] .status-badge.is-danger,
html[data-theme="minimal"] .ticket-priority-badge { background: var(--color-error-bright); color: var(--color-badge-danger-ink); }
html[data-theme="minimal"] .status-badge.is-lost { background: var(--color-status-lost-bright); color: var(--color-status-lost); }

/* A type badge (Budget, Quota) is outlined and neutral: it names a kind,
   not a state. */
html[data-theme="minimal"] .status-badge.is-type {
	border-color: var(--color-control);
	background: transparent;
	color: var(--color-text-primary);
}

/* A badge at the start of a row title keeps its own width. */
html[data-theme="minimal"] .resource-box-item-title > .status-badge {
	flex: 0 0 auto;
}

/* The application: the kind of a budget row and of a planning row
   (.budget-kind, projects/partial_project_budget.erb and
   clients/client_projectsettings.erb) is the type badge. Master's rule draws
   it as a filled pill in capitals with a minimum width. */
html[data-theme="minimal"] .budget-kind.status-badge {
	min-width: 0;
	letter-spacing: normal;
	text-align: left;
	text-transform: none;
}

/* Further variants of step 2: the draft marker of a Mikron card (neutral),
   the member lifecycle states, a count in a tab or a heading
   (.status-badge.is-count: tabular, round ends). The old badge classes join
   the shared rule. */
html[data-theme="minimal"] .mikron-entry-badge,
html[data-theme="minimal"] .member-lifecycle-badge {
	display: inline-flex;
	align-items: center;
	box-sizing: border-box;
	height: 20px;
	padding: 0 var(--space-xs);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-sm);
	background: var(--color-background-secondary);
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-style: normal;
	font-weight: 500;
	line-height: 16px;
	white-space: nowrap;
}

html[data-theme="minimal"] .status-badge.is-count {
	min-width: 20px;
	justify-content: center;
	padding: 0 var(--space-xs);
	border-radius: var(--radius-pill);
	font-variant-numeric: tabular-nums;
}

/*------------------------------
=21 CHIPS AND LABELS
Replaces: .label-container, .label-action, .label-name, .label-center,
.mikron-bookmark-labels .label, .modal-ticket-preliminary-resource,
.preliminary-label, .preliminary-member, the select2 choice chips and
.active-filter-chips (style.css =UI: LABELS and the ticket card rules).
------------------------------*/

/* One chip for every "tag with a remove button": a ticket label, a
   subscriber, a selected value of a multiple select and an active filter.
   28 px, the panel surface, a hairline edge, round ends. A label colour is
   only an 8 px dot: the name is always in the text colour (master and
   decision UI-32 wrote white text on the label colour). */
html[data-theme="minimal"] .chip,
html[data-theme="minimal"] .modal-ticket-preliminary-resource,
html[data-theme="minimal"] .active-filter-chip {
	display: inline-flex;
	align-items: center;
	gap: var(--space-xs);
	box-sizing: border-box;
	max-width: 100%;
	margin: 0;
	height: 28px;
	padding: 0 var(--space-2xs) 0 var(--space-lg);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-pill);
	background: var(--color-ui-panel);
	color: var(--color-text-primary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
	white-space: nowrap;
	cursor: default;
}

/* The neutral layer of the branch chip is not needed any more. */
html[data-theme="minimal"] .modal-ticket-preliminary-resource.preliminary-label::after {
	content: none;
}

/* A chip without a remove button keeps the same inner space at both ends. */
html[data-theme="minimal"] .chip:not(:has(> .remove)) {
	padding-right: var(--space-lg);
}

html[data-theme="minimal"] .chip > .name,
html[data-theme="minimal"] .modal-ticket-preliminary-resource > .name {
	min-width: 0;
	padding: 0;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* The label colour: an 8 px dot before the name. The view writes the colour
   to the custom property --label-colour instead of a background colour. */
html[data-theme="minimal"] .chip.is-label::before,
html[data-theme="minimal"] .modal-ticket-preliminary-resource.preliminary-label::before {
	content: "";
	flex: 0 0 8px;
	width: 8px;
	height: 8px;
	border-radius: var(--radius-pill);
	background: var(--label-colour, var(--color-control));
	box-shadow: var(--shadow-marker);
}

/* A person chip starts with a 20 px avatar instead of the dot. */
html[data-theme="minimal"] .chip.is-person,
html[data-theme="minimal"] .modal-ticket-preliminary-resource.preliminary-member {
	padding-left: var(--space-2xs);
}

html[data-theme="minimal"] .chip.is-person > .ticket-members {
	width: 20px;
	height: 20px;
}

html[data-theme="minimal"] .chip.is-person > .ticket-members .ticket-member-fallback {
	font-size: var(--font-size-xs);
	letter-spacing: -.04em;
}

/* The assignee chip of the ticket dialog has the accent tint. */
html[data-theme="minimal"] .modal-ticket-preliminary-resource.preliminary-assignee {
	border-color: color-mix(in srgb, var(--color-button-confirm) 45%, var(--color-ui-panel-border));
	background-color: color-mix(in srgb, var(--color-button-confirm) 10%, var(--color-ui-panel));
}

/* The assignee chip carries the 2 px accent ring of the ticket rows. */
html[data-theme="minimal"] .modal-ticket-preliminary-resource.preliminary-assignee > .ticket-members {
	box-shadow: 0 0 0 2px var(--color-ui-panel), 0 0 0 3px var(--color-border-highlight);
}

/* The remove button: a 24 px target with a 14 px cross (the judges measured
   a 12 px hit area in the climb). */
html[data-theme="minimal"] .chip > .remove,
html[data-theme="minimal"] .modal-ticket-preliminary-resource > .remove,
html[data-theme="minimal"] .active-filter-chip > button {
	display: inline-flex;
	flex: 0 0 24px;
	align-items: center;
	justify-content: center;
	width: 24px;
	height: 24px;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: var(--radius-pill);
	background: transparent;
	opacity: 1;
	color: var(--color-text-secondary);
	-webkit-mask: none;
	mask: none;
	cursor: pointer;
}

html[data-theme="minimal"] .modal-ticket-preliminary-resource > .remove[hidden] {
	display: none;
}

html[data-theme="minimal"] .chip > .remove::before,
html[data-theme="minimal"] .modal-ticket-preliminary-resource > .remove::before,
html[data-theme="minimal"] .active-filter-chip > button::before {
	content: "";
	width: 14px;
	height: 14px;
	background-color: currentColor;
	-webkit-mask: url(/icons/ui/x.svg) center / 14px no-repeat;
	mask: url(/icons/ui/x.svg) center / 14px no-repeat;
}

html[data-theme="minimal"] .chip > .remove:hover,
html[data-theme="minimal"] .modal-ticket-preliminary-resource > .remove:hover,
html[data-theme="minimal"] .active-filter-chip > button:hover {
	background-color: var(--color-ui-hover);
	color: var(--color-text-primary);
}

html[data-theme="minimal"] .chip > .remove:focus-visible,
html[data-theme="minimal"] .modal-ticket-preliminary-resource > .remove:focus-visible,
html[data-theme="minimal"] .active-filter-chip > button:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: -2px;
}

/* A clickable chip (a filter chip that opens its filter, a label in the
   settings) has the row hover. */
html[data-theme="minimal"] :is(a, button).chip:hover {
	background-color: var(--color-ui-hover);
}

/* A list of chips wraps with 6 px gaps. (The "Add" chip of step 2 is gone:
   the ticket dialog keeps its aside buttons, UI-55.) */
html[data-theme="minimal"] .chip-list,
html[data-theme="minimal"] .modal-ticket-preliminary-resource-container,
html[data-theme="minimal"] .active-filter-chips {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-xs);
	min-width: 0;
}

html[data-theme="minimal"] :is(a, button).chip:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
}

/* An archived label in the settings list: the name in the secondary text
   colour and a hollow dot. */
html[data-theme="minimal"] .chip.is-label.is-archived {
	color: var(--color-text-secondary);
}

html[data-theme="minimal"] .chip.is-label.is-archived::before {
	background: transparent;
	box-shadow: inset 0 0 0 2px var(--label-colour, var(--color-control));
}

/*------------------------------
=22 AVATARS AND THE ORGANISATION LOGO (shared with Skeleton)
Replaces: .ticket-members, .memberlist-picture, .ticket-member-fallback,
.ticket-member-logo-image sizes, .img-circle.
------------------------------*/

html[data-theme="minimal"] .ticket-members,
html[data-theme="minimal"] .memberlist-picture {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	width: 28px;
	height: 28px;
	margin: 0;
	overflow: hidden;
	border: 0;
	border-radius: var(--radius-pill);
	background: var(--color-background-quaternary);
	box-shadow: none;
	font-weight: 600;
}

html[data-theme="minimal"] .ticket-member-fallback {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	border: 0;
	border-radius: var(--radius-pill);
	background: transparent;
	color: var(--color-text-primary);
	font-size: var(--font-size-xs);
	font-weight: 600;
	letter-spacing: -.02em;
	line-height: 16px;
}

html[data-theme="minimal"] .ticket-member-logo-image {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

/* Sizes: 20 px in a chip, 24 px in ticket rows and stacked people, 28 px
   in rows (the default), 40 px for the organisation logo of the side menu
   and the picture of the user settings preview. A photo has an inset 1 px
   ring, so a white photo keeps its edge on the panel. The initials are on
   the track colour in the primary text (13.08:1 and 8.91:1). */
html[data-theme="minimal"] .ticket-member-logo-image,
html[data-theme="minimal"] .member-picture-image {
	box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .08);
}

html[data-theme="minimal"] .avatar-40 {
	width: 40px;
	height: 40px;
}

html[data-theme="minimal"] .avatar-40 .ticket-member-fallback {
	font-size: var(--font-size-md);
}

/*------------------------------
=23 BUTTONS (shell, shared with Skeleton)
Replaces: .button_standard and its states, .button_wide, .upload_button,
.button_red, .button_yellow, .button_neutral (style.css =UI: BUTTONS), the
bracketed text links "[Show older]" and the circled "+" buttons.
------------------------------*/

/* The buttons that style.css gives a generic sans-serif take the UI font.
   Only the family changes, so the size rules of style.css still apply. */
html[data-theme="minimal"] :where(button:where(.button_standard, .wizard-inline-action, .wizard-row-remove, .logout-button, .menu-action,
	.greybox, .member-current-absence-card, .member-time-leave-member-open, .member-time-leave-daily-open,
	.member-time-leave-absence-open, .salary-action, .org-dashboard-section-toggle, .ticket-pin-toggle,
	.header-language-menu button, [class*="ui-"])) {
	font-family: var(--font-ui-family);
}

/* Four looks, one box. Every button is 32 px high (UI-38) with a 13 px
   label; a button beside a field has the field height (36 px). Primary:
   the accent fill and a white label, one per view. Secondary: the panel
   surface, a hairline edge and the primary text (Cancel, Back, Upload,
   Export, Load more). Quiet: no fill and no edge, the secondary text (Add
   rows, toolbar links). Danger: the danger fill for the confirming button
   of a destructive question; a quiet danger (red text, no fill) for the
   button that asks the question (Delete, Revoke). */
html[data-theme="minimal"] .button_standard,
html[data-theme="minimal"] .upload_button,
html[data-theme="minimal"] .button,
html[data-theme="minimal"] .additem {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: var(--space-xs);
	box-sizing: border-box;
	min-width: 32px;
	height: var(--control-height);
	margin: 0;
	padding: 0 var(--space-lg);
	border: 1px solid var(--color-button-confirm);
	border-radius: var(--radius-md);
	background-color: var(--color-button-confirm);
	box-shadow: var(--shadow-xs);
	color: var(--color-button-confirm-text);
	font-family: var(--font-ui-family);
	font-size: var(--font-size-sm);
	font-weight: 600;
	line-height: 18px;
	text-align: center;
	text-decoration: none;
	white-space: nowrap;
	cursor: pointer;
	-webkit-appearance: none;
	transition: background-color var(--motion-fast) ease, border-color var(--motion-fast) ease, color var(--motion-fast) ease;
}

html[data-theme="minimal"] .button_standard:hover {
	border-color: var(--color-button-confirm-hover);
	background-color: var(--color-button-confirm-hover);
	color: var(--color-button-confirm-text);
}

/* A button made from an input keeps the corners: the input rule of
   style.css (0,2,1, later in the cascade) sets them to 0. */
html[data-theme="minimal"] input:is(.button_standard, .button) {
	border-radius: var(--radius-md);
}

/* A click leaves no ring; the keyboard focus shows the 2 px ring (UI-38). */
html[data-theme="minimal"] :is(.button_standard, .upload_button, .button, .additem):focus {
	outline: none;
}

html[data-theme="minimal"] :is(.button_standard, .upload_button, .button, .additem):focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
}

html[data-theme="minimal"] :is(.button_standard, .upload_button, .button):active:not(:disabled) {
	position: static;
	top: auto;
	transform: translateY(1px);
}

/* A leading 16 px icon (--button-icon on the button). */
html[data-theme="minimal"] :is(.button_standard, .upload_button, .button).has-icon {
	padding-left: var(--space-md);
}

html[data-theme="minimal"] :is(.button_standard, .upload_button, .button).has-icon::before {
	content: "";
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	background-color: currentColor;
	-webkit-mask: var(--button-icon) center / 16px no-repeat;
	mask: var(--button-icon) center / 16px no-repeat;
}

/* Secondary: Cancel, Back, Upload image file, Export, Load more, Show
   older (.additem; family 35 sets its width and margin). */
html[data-theme="minimal"] .button_standard.button_neutral,
html[data-theme="minimal"] .button_standard.button_yellow,
html[data-theme="minimal"] .button_standard.login-card-alt-button,
html[data-theme="minimal"] .upload_button,
html[data-theme="minimal"] .button.is-secondary,
html[data-theme="minimal"] .additem {
	border-color: var(--color-button-edge);
	background-color: var(--color-ui-panel);
	box-shadow: none;
	color: var(--color-text-primary);
	font-weight: 500;
}

html[data-theme="minimal"] .button_standard.button_neutral:hover,
html[data-theme="minimal"] .button_standard.button_yellow:hover,
html[data-theme="minimal"] .button_standard.login-card-alt-button:hover,
html[data-theme="minimal"] .upload_button:hover,
html[data-theme="minimal"] .button.is-secondary:hover,
html[data-theme="minimal"] .additem:hover {
	border-color: var(--color-button-edge-hover);
	background-color: var(--color-ui-hover);
	color: var(--color-text-primary);
}

/* Quiet: no fill and no edge until hover. */
html[data-theme="minimal"] .button_standard.button_quiet,
html[data-theme="minimal"] .button.is-quiet {
	border-color: transparent;
	background-color: transparent;
	box-shadow: none;
	color: var(--color-text-secondary);
	font-weight: 500;
}

html[data-theme="minimal"] .button_standard.button_quiet:hover,
html[data-theme="minimal"] .button.is-quiet:hover {
	border-color: transparent;
	background-color: var(--color-ui-hover);
	color: var(--color-text-primary);
}

/* Danger, filled: only the confirming button of a destructive question.
   White on the danger fill: 5.23:1 (Light) and 5.23:1 (Dark). */
html[data-theme="minimal"] .button_standard.button_red {
	border-color: var(--color-action-danger);
	background-color: var(--color-action-danger);
	color: var(--color-action-danger-text);
}

html[data-theme="minimal"] .button_standard.button_red:hover {
	border-color: var(--color-action-danger-hover);
	background-color: var(--color-action-danger-hover);
	color: var(--color-action-danger-text);
}

/* Danger, quiet: the button that asks (Delete, Revoke, Delete logo). The
   error ink on the panel: 4.72:1 (Light) and 5.89:1 (Dark); the trash
   icon is the second signal. Hover: the danger hover surface (4.70:1 and 6.06:1). */
html[data-theme="minimal"] .button_standard.button_red.button_quiet,
html[data-theme="minimal"] .button_standard.settings-delete-image {
	--button-icon: url(/icons/ui/trash.svg);
	border-color: transparent;
	background-color: transparent;
	box-shadow: none;
	color: var(--color-action-danger-ink);
	font-weight: 500;
}

html[data-theme="minimal"] .button_standard.button_red.button_quiet:hover,
html[data-theme="minimal"] .button_standard.settings-delete-image:hover {
	border-color: transparent;
	background-color: var(--color-danger-hover);
	color: var(--color-action-danger-ink);
}

/* The wide button ends a form column (log in, sign up): the field height
   and the column width. */
html[data-theme="minimal"] .button_standard.button_wide {
	width: 100%;
	height: var(--field-height);
	font-size: var(--font-size-md);
}

/* Disabled: the sunken surface, a hairline edge and the placeholder text
   (4.78:1 on the sunken surface in Light, 5.74:1 in Dark). WCAG does not
   require contrast for a disabled control; the label stays readable on
   purpose (master had 1.18:1). The same look for every variant. */
html[data-theme="minimal"] :is(.button_standard, .upload_button, .button):disabled,
html[data-theme="minimal"] :is(.button_standard, .upload_button, .button)[aria-disabled="true"],
html[data-theme="minimal"] :is(.button_standard, .upload_button, .button):disabled:hover {
	border-color: var(--color-ui-panel-border);
	background-color: var(--color-background-secondary);
	box-shadow: none;
	color: var(--color-placeholder);
	cursor: not-allowed;
}

/* Busy: the button keeps its size. The label and the icon stay in place
   but are not painted (the text fill is transparent, so the label is still
   the name of the button); a 14 px ring in the label colour turns in the
   centre. The script sets aria-busy="true" while the request runs. */
html[data-theme="minimal"] :is(.button_standard, .upload_button, .button)[aria-busy="true"],
html[data-theme="minimal"] :is(.button_standard, .upload_button, .button)[aria-busy="true"]:active:not(:disabled) {
	position: relative;
	-webkit-text-fill-color: transparent;
	cursor: progress;
}

html[data-theme="minimal"] :is(.button_standard, .upload_button, .button).has-icon[aria-busy="true"]::before {
	visibility: hidden;
}

html[data-theme="minimal"] :is(.button_standard, .upload_button, .button)[aria-busy="true"]::after {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	box-sizing: border-box;
	width: 14px;
	height: 14px;
	margin: -7px 0 0 -7px;
	border: 2px solid currentColor;
	border-right-color: transparent;
	border-radius: var(--radius-pill);
	animation: button-busy-turn .8s linear infinite;
}

@keyframes button-busy-turn {
	to {
		transform: rotate(360deg);
	}
}

@media (prefers-reduced-motion: reduce) {
	html[data-theme="minimal"] :is(.button_standard, .upload_button, .button)[aria-busy="true"]::after {
		animation-duration: 2.4s;
	}
}

/* A row of buttons: 8 px apart; the primary button last. */
html[data-theme="minimal"] .button-row {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-sm);
}

html[data-theme="minimal"] .button-row > .button-row-start {
	margin-right: auto;
}

/* A label element styled as a button (file upload) keeps its hidden input
   out of the flow. */
html[data-theme="minimal"] label.upload_button input[type="file"] {
	position: absolute;
	width: 1px;
	height: 1px;
	opacity: 0;
}

/*------------------------------
=24 ICON BUTTONS AND THE HELP BUTTON (shell, shared with Skeleton)
Replaces: .icon.tooltip (40 px target), .icon.help, .btnClose, the gear,
cross, tick and stack pictograms, .mp-settings-icon (d3Classes.css).
------------------------------*/

/* One icon button in three sizes: 32 px (the dialog close, the row menu,
   the chart settings), 28 px (box tools, row actions, comment actions) and
   24 px (help, pin, the chip remove). The icon is a 16 px line mask in the
   secondary text colour (5.41:1 and 6.89:1 on the panel); hover gives the
   row hover surface and the primary text; the focus ring is 2 px. Every
   icon button has an aria-label and the same text as its title. */
html[data-theme="minimal"] .icon-button,
html[data-theme="minimal"] .btnClose {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	width: 32px;
	height: 32px;
	padding: 0;
	border: 0;
	border-radius: var(--radius-md);
	background: transparent;
	color: var(--color-text-secondary);
	font-size: 0;
	line-height: 0;
	cursor: pointer;
	transition: background-color var(--motion-fast) ease, color var(--motion-fast) ease;
}

html[data-theme="minimal"] .icon-button::before,
html[data-theme="minimal"] .btnClose::before {
	content: "";
	width: 16px;
	height: 16px;
	background-color: currentColor;
	-webkit-mask: var(--icon, url(/icons/ui/x.svg)) center / 16px no-repeat;
	mask: var(--icon, url(/icons/ui/x.svg)) center / 16px no-repeat;
}

/* The close button stands in the top right corner of its dialog or
   panel; family 28 sets its place in a dialog. */
html[data-theme="minimal"] .btnClose {
	top: var(--space-lg);
	right: var(--space-lg);
	margin-top: 0;
	text-align: center;
}

html[data-theme="minimal"] .icon-button:hover,
html[data-theme="minimal"] .btnClose:hover {
	background-color: var(--color-ui-hover);
	color: var(--color-text-primary);
}

html[data-theme="minimal"] .icon-button:focus-visible,
html[data-theme="minimal"] .btnClose:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 0;
}

html[data-theme="minimal"] .icon-button.is-28 {
	width: 28px;
	height: 28px;
}

html[data-theme="minimal"] .icon-button.is-24 {
	width: 24px;
	height: 24px;
	border-radius: var(--radius-sm);
}

/* A pressed icon button (a toggle) has the pressed look of a view tool. */
html[data-theme="minimal"] .icon-button[aria-pressed="true"] {
	background-color: var(--color-selected);
	color: var(--color-button-confirm-ink);
}

html[data-theme="minimal"][data-theme-variant="dark"] .icon-button[aria-pressed="true"] {
	color: var(--color-border-highlight);
}

/* A bordered icon button stands in a row of secondary buttons (the arrows
   of the calendar). */
html[data-theme="minimal"] .icon-button.is-bordered {
	border: 1px solid var(--color-button-edge);
	background-color: var(--color-ui-panel);
}

/* The box tools and row actions of step 1 are icon buttons of this family:
   they get the same keyboard focus ring. */
html[data-theme="minimal"] .resource-box-top-right .resource-box-icon:focus-visible,
html[data-theme="minimal"] .org-dashboard-section-tools .resource-box-icon:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 0;
}

/* The help button: a 24 px target with the 16 px help icon. The views
   write it with partials/help_button.erb: a button that the Tab key
   reaches (master had links with tabindex="-1") and that holds the icon
   element of master. A click or Enter opens the help popover of family 34.
   The :has(> .icon.tooltip.help) selectors of this family serve the help
   links that Skeleton's views still have; they go when the port of the
   shared shell (rollout job 10) gives Skeleton the partial. */
html[data-theme="minimal"] :is(a, button).tooltip:has(> .icon.tooltip.help),
html[data-theme="minimal"] .help-button {
	display: inline-flex;
	flex: 0 0 24px;
	align-items: center;
	justify-content: center;
	width: 24px;
	height: 24px;
	padding: 0;
	border: 0;
	border-radius: var(--radius-sm);
	background: transparent;
	color: var(--color-text-secondary);
	vertical-align: middle;
	cursor: pointer;
}

html[data-theme="minimal"] :is(a, button).tooltip:has(> .icon.tooltip.help):hover,
html[data-theme="minimal"] .help-button:hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] :is(a, button).tooltip:has(> .icon.tooltip.help):focus-visible,
html[data-theme="minimal"] .help-button:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 0;
}

/*------------------------------
=25 FORM FIELDS
Replaces: the field block of style.css (=UI: INPUT FIELDS: .organization-input,
.organization-input-small, captions, .field-action-row, focus, invalid,
disabled), the select arrow, .feedback-input outside the quick filter, the
browser checkboxes and radio buttons, the range slider of the Mikron card,
the colour field, the upload area and .flextable rows.
------------------------------*/

/* One field: 36 px, the field surface (--color-field: white in Light, the
   panel in Dark), the control edge (3.85:1 on the white field in Light,
   3.72:1 in Dark), 6 px corners, 14 px text, no shadow. A compact
   field (.organization-input-small) is 32 px and is used only inside
   table rows (the bill editor lines, rate rows). The fields of the login
   page (family 36) are fields of this family. */
html[data-theme="minimal"] .organization-input,
html[data-theme="minimal"] .organization-input-small,
html[data-theme="minimal"] .field,
html[data-theme="minimal"] .login-form .feedback-input {
	display: block;
	box-sizing: border-box;
	width: 100%;
	min-width: 0;
	height: var(--field-height);
	margin: 0;
	padding: 0 var(--space-lg);
	border: 1px solid var(--color-control);
	border-radius: var(--radius-md);
	background-color: var(--color-field);
	box-shadow: none;
	color: var(--color-text-primary);
	font-family: var(--font-ui-family);
	font-size: var(--font-size-md);
	font-weight: 400;
	line-height: 20px;
	transition: border-color var(--motion-fast) ease, box-shadow var(--motion-fast) ease;
}

html[data-theme="minimal"] .organization-input-small {
	height: var(--control-height);
	padding: 0 var(--space-sm);
}

html[data-theme="minimal"] input:is(.organization-input, .organization-input-small, .field):not([type="checkbox"], [type="radio"]) {
	border-radius: var(--radius-md);
}

html[data-theme="minimal"] :is(.organization-input, .organization-input-small, .field):hover,
html[data-theme="minimal"] .login-form .feedback-input:hover {
	border-color: var(--color-text-secondary);
}

/* The focus: a 2 px accent edge (1 px border and a 1 px inner ring), 5.41:1
   (Light) and 7.15:1 (Dark) on a field. The text does not move. */
html[data-theme="minimal"] :is(.organization-input, .organization-input-small, .field):focus,
html[data-theme="minimal"] :is(.organization-input, .organization-input-small, .field):focus-visible,
html[data-theme="minimal"] .login-form .feedback-input:focus {
	border-color: var(--color-border-highlight);
	outline: none;
	box-shadow: inset 0 0 0 1px var(--color-border-highlight);
	background-color: var(--color-field);
}

html[data-theme="minimal"] :is(.organization-input, .organization-input-small, .field)::placeholder,
html[data-theme="minimal"] .login-form .feedback-input::placeholder {
	color: var(--color-placeholder);
	opacity: 1;
}

/* Disabled: the sunken surface, a hairline edge, the secondary text. */
html[data-theme="minimal"] :is(.organization-input, .organization-input-small, .field):disabled,
html[data-theme="minimal"] .login-form .feedback-input:disabled {
	border-color: var(--color-ui-panel-border);
	background-color: var(--color-background-secondary);
	color: var(--color-text-secondary);
	cursor: not-allowed;
}

/* Read-only: the sunken surface and the primary text; the value can be
   selected and copied. */
html[data-theme="minimal"] :is(.organization-input, .organization-input-small, .field):read-only:not(select, :disabled, [type="checkbox"], [type="radio"]),
html[data-theme="minimal"] .login-form .feedback-input:read-only:not(:disabled) {
	border-color: var(--color-ui-panel-border);
	background-color: var(--color-background-secondary);
}

/* Invalid (the script sets aria-invalid="true"): a 2 px edge in the error
   ink (5.23:1 and 5.89:1 on a field), also while the field has the
   focus. The message under the field names the problem. */
html[data-theme="minimal"] :is(.organization-input, .organization-input-small, .field)[aria-invalid="true"],
html[data-theme="minimal"] :is(.organization-input, .organization-input-small, .field)[aria-invalid="true"]:focus,
html[data-theme="minimal"] .login-form .feedback-input[aria-invalid="true"],
html[data-theme="minimal"] .login-form .feedback-input[aria-invalid="true"]:focus {
	border-color: var(--color-error-dark);
	outline: none;
	box-shadow: inset 0 0 0 1px var(--color-error-dark);
}

/* The browser marks :invalid before the user typed; only aria-invalid
   shows an error. The login fields are not in this list: they are
   required, and the first one has the focus when the page opens; this
   rule comes after the focus rule and would take its inner ring away. */
html[data-theme="minimal"] :is(.organization-input, .organization-input-small, .field):invalid {
	box-shadow: none;
}

/* Textarea: three lines high, grows with its text (the scripts of the
   views), resizes vertically. */
html[data-theme="minimal"] textarea:is(.organization-input, .field) {
	height: auto;
	min-height: 84px;
	padding: var(--space-sm) var(--space-lg);
	resize: vertical;
}

/* Select: the field with a 16 px chevron at the right. A select that shows
   its empty first option ("Project", "Unassigned") has the placeholder
   colour. */
html[data-theme="minimal"] select:is(.organization-input, .organization-input-small, .field) {
	padding-right: 36px;
	background-image: none;
	-webkit-appearance: none;
	appearance: none;
	text-overflow: ellipsis;
	cursor: pointer;
}

html[data-theme="minimal"] .select-wrap {
	position: relative;
	display: block;
	min-width: 0;
}

html[data-theme="minimal"] .select-wrap::after {
	content: "";
	position: absolute;
	top: 50%;
	right: var(--space-lg);
	width: 16px;
	height: 16px;
	margin-top: -8px;
	background-color: var(--color-text-secondary);
	-webkit-mask: url(/icons/ui/chevron-down.svg) center / 16px no-repeat;
	mask: url(/icons/ui/chevron-down.svg) center / 16px no-repeat;
	pointer-events: none;
}

html[data-theme="minimal"] select:is(.organization-input, .organization-input-small, .field):has(> option[value=""]:checked) {
	color: var(--color-placeholder);
}

/* Multiple select (select2 4.1, the filter dialogs: treetops.js upgrades
   every select[multiple] of .js-filter-multiselect): the field box with the
   chips of family 21 inside. Select2 writes its markup after the hidden
   select: .select2-container > .selection > .select2-selection--multiple
   with the chips (ul.select2-selection__rendered > li.select2-selection__choice:
   the remove button, then the name) and the inline search (a textarea). The
   field grows with its chips (at least 36 px: 3 px, a 28 px chip, 3 px).
   These rules replace the .modalContainer select2 rules of style.css; they
   are not scoped to dialogs, because select2 also opens on the page. */
html[data-theme="minimal"] .select2-container--default {
	max-width: 100%;
	font-family: var(--font-ui-family);
}

html[data-theme="minimal"] .select2-container--default .select2-selection--multiple {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-2xs);
	box-sizing: border-box;
	min-height: var(--field-height);
	padding: 3px var(--space-sm) 3px 3px;
	border: 1px solid var(--color-control);
	border-radius: var(--radius-md);
	background-color: var(--color-field);
	box-shadow: none;
	cursor: text;
	transition: border-color var(--motion-fast) ease, box-shadow var(--motion-fast) ease;
}

html[data-theme="minimal"] .select2-container--default .select2-selection--multiple:hover {
	border-color: var(--color-text-secondary);
}

/* The chips and the search field share the wrapping row of the field. */
html[data-theme="minimal"] .select2-container--default .select2-selection--multiple .select2-selection__rendered {
	display: contents;
	margin: 0;
	padding: 0;
	list-style: none;
}

/* A chosen value is the chip of family 21: 28 px, the panel surface, a
   hairline edge, round ends, 13 px 500 in the primary text; the remove
   button (first in the markup) stands after the name. */
html[data-theme="minimal"] .select2-container--default .select2-selection--multiple .select2-selection__choice {
	position: static;
	display: inline-flex;
	align-items: center;
	gap: var(--space-xs);
	box-sizing: border-box;
	max-width: 100%;
	height: 28px;
	margin: 0;
	padding: 0 var(--space-2xs) 0 var(--space-lg);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-pill);
	background: var(--color-ui-panel);
	color: var(--color-text-primary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
	white-space: nowrap;
	vertical-align: middle;
}

html[data-theme="minimal"] .select2-container--default .select2-selection--multiple .select2-selection__choice__display {
	min-width: 0;
	padding: 0;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* The remove button: a 24 px target with the 14 px cross of the chips (the
   "×" text of select2 is hidden; the button keeps its aria-label). */
html[data-theme="minimal"] .select2-container--default .select2-selection--multiple .select2-selection__choice__remove {
	position: static;
	display: inline-flex;
	flex: 0 0 24px;
	order: 1;
	align-items: center;
	justify-content: center;
	width: 24px;
	height: 24px;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: var(--radius-pill);
	background: transparent;
	color: var(--color-text-secondary);
	font-size: 0;
	cursor: pointer;
}

html[data-theme="minimal"] .select2-container--default .select2-selection--multiple .select2-selection__choice__remove > span {
	display: none;
}

html[data-theme="minimal"] .select2-container--default .select2-selection--multiple .select2-selection__choice__remove::before {
	content: "";
	width: 14px;
	height: 14px;
	background-color: currentColor;
	-webkit-mask: url(/icons/ui/x.svg) center / 14px no-repeat;
	mask: url(/icons/ui/x.svg) center / 14px no-repeat;
}

html[data-theme="minimal"] .select2-container--default .select2-selection--multiple .select2-selection__choice__remove:hover,
html[data-theme="minimal"] .select2-container--default .select2-selection--multiple .select2-selection__choice__remove:focus {
	background-color: var(--color-ui-hover);
	color: var(--color-text-primary);
}

html[data-theme="minimal"] .select2-container--default .select2-selection--multiple .select2-selection__choice__remove:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: -2px;
}

/* The search field takes the rest of the line; empty, it shows the
   placeholder (the empty first option: "All projects"). Select2 sets its
   width by the typed text. */
html[data-theme="minimal"] .select2-container--default .select2-search--inline {
	display: flex;
	flex: 1 1 32px;
	min-width: 32px;
}

html[data-theme="minimal"] .select2-container--default .select2-search--inline .select2-search__field {
	box-sizing: border-box;
	height: 28px;
	margin: 0;
	padding: 0 0 0 var(--space-sm);
	border: 0;
	background: transparent;
	color: var(--color-text-primary);
	font-family: var(--font-ui-family);
	font-size: var(--font-size-md);
	line-height: 28px;
	overflow: hidden;
	resize: none;
}

html[data-theme="minimal"] .select2-container--default .select2-search--inline .select2-search__field::placeholder {
	color: var(--color-placeholder);
	opacity: 1;
}

/* Focus and open: the 2 px accent edge of every field. The corners stay
   round when the list opens. */
html[data-theme="minimal"] .select2-container--default:is(.select2-container--focus, .select2-container--open) .select2-selection--multiple {
	border-color: var(--color-border-highlight);
	border-radius: var(--radius-md);
	box-shadow: inset 0 0 0 1px var(--color-border-highlight);
	outline: none;
}

/* Disabled: the sunken surface, a hairline edge; the chips in the
   secondary text without their remove buttons. */
html[data-theme="minimal"] .select2-container--default.select2-container--disabled .select2-selection--multiple {
	border-color: var(--color-ui-panel-border);
	background-color: var(--color-background-secondary);
	cursor: not-allowed;
}

html[data-theme="minimal"] .select2-container--default.select2-container--disabled .select2-selection__choice {
	padding-right: var(--space-lg);
	color: var(--color-text-secondary);
}

html[data-theme="minimal"] .select2-container--default.select2-container--disabled .select2-selection__choice__remove {
	display: none;
}

/* The list: the menu surface of family 3 (the raised surface, hairline,
   6 px corners, the menu shadow) 4 px under the field; 34 px options.
   Highlighted: the hover surface. Chosen: a 16 px check at the right in the accent ink and
   the label in 500 (the check is the signal, not the colour). */
html[data-theme="minimal"] .select2-container--default .select2-dropdown {
	box-sizing: border-box;
	margin-top: var(--space-2xs);
	overflow: hidden;
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-md);
	background-color: var(--color-raised-surface);
	box-shadow: var(--shadow-md);
}

html[data-theme="minimal"] .select2-container--default .select2-dropdown--above {
	margin-top: 0;
	margin-bottom: var(--space-2xs);
}

html[data-theme="minimal"] .select2-container--default .select2-results > .select2-results__options {
	max-height: 240px;
	margin: 0;
	padding: var(--space-2xs);
	overflow-y: auto;
	list-style: none;
	background: transparent;
	scrollbar-width: thin;
}

html[data-theme="minimal"] .select2-container--default .select2-results__option {
	display: flex;
	align-items: center;
	gap: var(--space-sm);
	box-sizing: border-box;
	min-height: 34px;
	padding: 7px var(--space-md);
	border-radius: var(--radius-sm);
	background: transparent;
	box-shadow: none;
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	line-height: 20px;
	cursor: pointer;
}

html[data-theme="minimal"] .select2-container--default .select2-results__option--selected {
	font-weight: 500;
}

html[data-theme="minimal"] .select2-container--default .select2-results__option--selected::after {
	content: "";
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	margin-left: auto;
	background-color: var(--color-button-confirm-ink);
	-webkit-mask: url(/icons/ui/check.svg) center / 16px no-repeat;
	mask: url(/icons/ui/check.svg) center / 16px no-repeat;
}

html[data-theme="minimal"][data-theme-variant="dark"] .select2-container--default .select2-results__option--selected::after {
	background-color: var(--color-border-highlight);
}

html[data-theme="minimal"] .select2-container--default .select2-results__option--highlighted.select2-results__option--selectable {
	background-color: var(--color-ui-hover);
	color: var(--color-text-primary);
}

html[data-theme="minimal"] .select2-container--default .select2-results__option[aria-disabled="true"],
html[data-theme="minimal"] .select2-container--default .select2-results__message {
	color: var(--color-text-secondary);
	cursor: default;
}

/* A date: the field with a 16 px calendar icon at the right; an empty date
   ("No due date") shows the placeholder. At least 140 px: the edge, 12 px,
   a full date (15/11/2026 or 15.11.2026: 83 px at 14 px, tabular), 8 px,
   the icon and 12 px, with room to spare. The field does not shrink below
   it; a row of fields wraps instead (.form-row, the scales of the ticket
   dialog). */
html[data-theme="minimal"] .field-date {
	position: relative;
	display: block;
	min-width: 140px;
}

html[data-theme="minimal"] .field-date > input {
	padding-right: 36px;
	font-variant-numeric: tabular-nums;
}

html[data-theme="minimal"] .field-date::after {
	content: "";
	position: absolute;
	top: 50%;
	right: var(--space-lg);
	width: 16px;
	height: 16px;
	margin-top: -8px;
	background-color: var(--color-text-secondary);
	-webkit-mask: url(/icons/ui/calendar.svg) center / 16px no-repeat;
	mask: url(/icons/ui/calendar.svg) center / 16px no-repeat;
	pointer-events: none;
}

/* A number with a unit: the value right-aligned and tabular, the unit
   ("h", "€", "%") inside the field at the right in the secondary text. The
   Mikron hours have no unit (UI-39). */
html[data-theme="minimal"] .field-unit {
	position: relative;
	display: block;
	min-width: 0;
}

html[data-theme="minimal"] .field-unit > input {
	padding-right: 40px;
	font-variant-numeric: tabular-nums;
	text-align: right;
}

html[data-theme="minimal"] .field-unit > .unit {
	position: absolute;
	top: 0;
	right: var(--space-lg);
	color: var(--color-text-secondary);
	font-size: var(--font-size-md);
	line-height: var(--field-height);
	pointer-events: none;
}

html[data-theme="minimal"] input[type="number"]:is(.organization-input, .organization-input-small, .field) {
	font-variant-numeric: tabular-nums;
}

/* A field and its caption: the caption 13 px, 500, in the secondary text,
   6 px above the field (it replaces the out-of-flow captions of the branch
   and the 12 px description caption of step 1). */
html[data-theme="minimal"] .form-field {
	display: flex;
	flex-direction: column;
	gap: var(--space-xs);
	min-width: 0;
}

html[data-theme="minimal"] .form-field > .field-caption,
html[data-theme="minimal"] .field-caption {
	display: block;
	margin: 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
}

/* A caption in front of the field (UI-37: Project, Task and Assignment of
   the ticket dialog; the dates of the Mikron card and the bill editor): one
   caption width per form, the caption centred on the field. Under a form
   width of 280 px the caption goes above the field. */
html[data-theme="minimal"] .form-field.is-inline {
	flex-direction: row;
	align-items: center;
	gap: var(--space-lg);
}

html[data-theme="minimal"] .form-field.is-inline > .field-caption {
	flex: 0 0 var(--caption-width, 96px);
	overflow-wrap: anywhere;
}

html[data-theme="minimal"] .form-field.is-inline > :not(.field-caption) {
	flex: 1 1 auto;
}

@container form (max-width: 279px) {
	html[data-theme="minimal"] .form-field.is-inline {
		flex-direction: column;
		align-items: stretch;
		gap: var(--space-xs);
	}

	html[data-theme="minimal"] .form-field.is-inline > .field-caption {
		flex-basis: auto;
	}
}

/* A group of fields: one column, 16 px apart; .form-row puts fields side by
   side and wraps them (each at least 140 px). */
html[data-theme="minimal"] .form-stack {
	display: flex;
	flex-direction: column;
	gap: var(--space-xl);
	min-width: 0;
	container: form / inline-size;
}

html[data-theme="minimal"] .form-row {
	display: flex;
	flex-wrap: wrap;
	gap: var(--space-xl);
	min-width: 0;
}

html[data-theme="minimal"] .form-row > * {
	flex: 1 1 140px;
}

html[data-theme="minimal"] .form-row.is-wide > * {
	flex-basis: 260px;
}

/* A hint under a field: 12 px, the secondary text. An error: 13 px, the
   error ink and 500, after a 16 px alert icon. The field points to both
   with aria-describedby. */
html[data-theme="minimal"] .field-hint {
	margin: 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	line-height: 16px;
}

html[data-theme="minimal"] .field-error {
	display: flex;
	align-items: flex-start;
	gap: var(--space-xs);
	margin: 0;
	color: var(--color-error-dark);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
}

html[data-theme="minimal"] .field-error::before {
	content: "";
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	margin-top: 1px;
	background-color: currentColor;
	-webkit-mask: url(/icons/ui/alert-circle.svg) center / 16px no-repeat;
	mask: url(/icons/ui/alert-circle.svg) center / 16px no-repeat;
}

/* A button beside a field has the top, the bottom and the height of the
   field (UI-38). */
html[data-theme="minimal"] .field-action-row {
	display: flex;
	align-items: center;
	gap: var(--space-sm);
	min-width: 0;
}

html[data-theme="minimal"] .field-action-row > :is(input, select, .select-wrap, .field-date, .field-unit) {
	flex: 1 1 auto;
	min-width: 0;
}

html[data-theme="minimal"] .field-action-row > :is(.button_standard, .upload_button, .button) {
	flex: 0 0 auto;
	height: var(--field-height);
}

/* Checkbox and radio: 18 px marks with the control edge; checked: the
   accent fill and a white mark (5.41:1 and 5.00:1). The label wraps the
   input, so the whole row (at least 24 px) is the target. */
html[data-theme="minimal"] .check-field {
	display: inline-flex;
	align-items: flex-start;
	gap: var(--space-sm);
	min-height: 24px;
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	line-height: 20px;
	cursor: pointer;
}

html[data-theme="minimal"] .check-field > input {
	margin-top: 1px;
}

html[data-theme="minimal"] .check-field .field-hint {
	display: block;
	margin-top: var(--space-3xs);
}

html[data-theme="minimal"] input:is([type="checkbox"], [type="radio"]):not(.visually-hidden, [hidden], .ticket-attachments-input) {
	flex: 0 0 18px;
	box-sizing: border-box;
	width: 18px;
	height: 18px;
	margin: 0;
	border: 1px solid var(--color-control);
	border-radius: var(--radius-sm);
	background: var(--color-field);
	-webkit-appearance: none;
	appearance: none;
	vertical-align: -3px;
	cursor: pointer;
	transition: background-color var(--motion-fast) ease, border-color var(--motion-fast) ease;
}

html[data-theme="minimal"] input[type="radio"]:not(.visually-hidden, [hidden]) {
	border-radius: var(--radius-pill);
}

html[data-theme="minimal"] input:is([type="checkbox"], [type="radio"]):not(:disabled):hover {
	border-color: var(--color-text-secondary);
}

html[data-theme="minimal"] input[type="checkbox"]:checked:not(.visually-hidden, [hidden]),
html[data-theme="minimal"] input[type="checkbox"]:indeterminate:not(.visually-hidden, [hidden]) {
	border-color: var(--color-button-confirm);
	background-color: var(--color-button-confirm);
	background-image: none;
}

html[data-theme="minimal"] input[type="checkbox"]:checked:not(.visually-hidden, [hidden], [role="switch"])::before,
html[data-theme="minimal"] input[type="checkbox"]:indeterminate:not(.visually-hidden, [hidden])::before {
	content: "";
	display: block;
	width: 16px;
	height: 16px;
	background-color: var(--color-button-confirm-text);
	-webkit-mask: url(/icons/ui/check.svg) center / 14px no-repeat;
	mask: url(/icons/ui/check.svg) center / 14px no-repeat;
}

html[data-theme="minimal"] input[type="checkbox"]:indeterminate:not(.visually-hidden, [hidden])::before {
	-webkit-mask: none;
	mask: none;
	width: 8px;
	height: 2px;
	margin: 7px 0 0 4px;
}

html[data-theme="minimal"] input[type="radio"]:checked:not(.visually-hidden, [hidden]) {
	border: 5px solid var(--color-button-confirm);
	background-color: var(--color-field);
}

html[data-theme="minimal"] input:is([type="checkbox"], [type="radio"]):focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
}

html[data-theme="minimal"] input:is([type="checkbox"], [type="radio"]):disabled {
	border-color: var(--color-background-quaternary);
	background-color: var(--color-background-secondary);
	cursor: not-allowed;
}

html[data-theme="minimal"] input:is([type="checkbox"], [type="radio"]):disabled:checked {
	border-color: var(--color-background-quaternary);
	background-color: var(--color-background-quaternary);
}

/* A switch (an on/off setting that takes effect at once, without Save):
   a 32 x 18 px track. Off: the control colour (3.85:1 and 3.72:1 on the
   panel) with a white knob; on: the accent with the knob at the right. The
   knob position is the second signal. */
html[data-theme="minimal"] input[type="checkbox"][role="switch"]:not(.visually-hidden, [hidden]) {
	position: relative;
	flex: 0 0 32px;
	width: 32px;
	height: 18px;
	border: 0;
	border-radius: var(--radius-pill);
	background-color: var(--color-control);
}

html[data-theme="minimal"] input[type="checkbox"][role="switch"]::after {
	content: "";
	position: absolute;
	top: 2px;
	left: 2px;
	width: 14px;
	height: 14px;
	border-radius: var(--radius-pill);
	background: var(--color-knob);
	box-shadow: 0 1px 2px rgba(0, 0, 0, .25);
	transition: transform var(--motion-base) var(--ease-standard);
}

html[data-theme="minimal"] input[type="checkbox"][role="switch"]:checked {
	background-color: var(--color-button-confirm);
}

html[data-theme="minimal"] input[type="checkbox"][role="switch"]:checked::after {
	transform: translateX(14px);
}

/* The range slider of the Mikron card: a 4 px track, the filled part in the
   accent edge colour, a 16 px white knob with the control edge. The input
   is 24 px high, so the target is 24 px. The organisation colour is not
   used any more. */
html[data-theme="minimal"] input[type="range"] {
	--range-fill: 0%;
	flex: 1 1 auto;
	min-width: 0;
	height: 24px;
	margin: 0;
	background: transparent;
	-webkit-appearance: none;
	appearance: none;
	cursor: pointer;
}

html[data-theme="minimal"] input[type="range"]::-webkit-slider-runnable-track {
	height: 4px;
	border-radius: var(--radius-pill);
	background: linear-gradient(to right, var(--color-border-highlight) var(--range-fill), var(--color-background-quaternary) var(--range-fill));
}

html[data-theme="minimal"] input[type="range"]::-moz-range-track {
	height: 4px;
	border-radius: var(--radius-pill);
	background: var(--color-background-quaternary);
}

html[data-theme="minimal"] input[type="range"]::-moz-range-progress {
	height: 4px;
	border-radius: var(--radius-pill);
	background: var(--color-border-highlight);
}

html[data-theme="minimal"] input[type="range"]::-webkit-slider-thumb {
	width: 16px;
	height: 16px;
	margin-top: -6px;
	border: 1px solid var(--color-control);
	border-radius: var(--radius-pill);
	background: var(--color-knob);
	box-shadow: var(--shadow-xs);
	-webkit-appearance: none;
}

html[data-theme="minimal"] input[type="range"]::-moz-range-thumb {
	box-sizing: border-box;
	width: 16px;
	height: 16px;
	border: 1px solid var(--color-control);
	border-radius: var(--radius-pill);
	background: var(--color-knob);
}

html[data-theme="minimal"] input[type="range"]:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
	border-radius: var(--radius-sm);
}

/* The colour field: a 36 px square button with the swatch inside (a
   hairline ring keeps a pale colour visible). */
html[data-theme="minimal"] input[type="color"]:is(.organization-input, .organization-input-small, .field) {
	flex: 0 0 var(--field-height);
	width: var(--field-height);
	padding: var(--space-2xs);
	cursor: pointer;
}

html[data-theme="minimal"] input[type="color"]::-webkit-color-swatch-wrapper {
	padding: 0;
}

html[data-theme="minimal"] input[type="color"]::-webkit-color-swatch {
	border: 0;
	border-radius: var(--radius-sm);
	box-shadow: var(--shadow-marker);
}

/* The upload area (logo, picture): the current image on the sunken
   surface with a dashed control edge, and the actions under it. The logo
   and picture areas of the settings pages (family 37) have this look. */
html[data-theme="minimal"] .upload-area {
	display: flex;
	flex-direction: column;
	gap: var(--space-lg);
	min-width: 0;
}

html[data-theme="minimal"] .upload-area-drop,
html[data-theme="minimal"] :is(.organization-settings-logo-preview, .user-settings-picture-preview) {
	display: flex;
	align-items: center;
	gap: var(--space-xl);
	box-sizing: border-box;
	min-height: 88px;
	padding: var(--space-xl);
	border: 1px dashed var(--color-control);
	border-radius: var(--radius-lg);
	background: var(--color-background-secondary);
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

html[data-theme="minimal"] .upload-area-drop > img,
html[data-theme="minimal"] .upload-area-drop > .upload-area-image {
	flex: 0 0 56px;
	width: 56px;
	height: 56px;
	border-radius: var(--radius-lg);
	object-fit: cover;
}

html[data-theme="minimal"] .upload-area-drop.is-over {
	border-color: var(--color-border-highlight);
	background: var(--color-selected);
}

/* A table of settings (.flextable): the label takes the free width, the
   control stands at the right, the help after it. 56 px rows with hairline
   dividers inside a box. */
html[data-theme="minimal"] .settings-list {
	margin: 0;
	padding: 0;
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
	list-style: none;
}

html[data-theme="minimal"] .settings-row {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-sm) var(--space-xl);
	box-sizing: border-box;
	min-height: 56px;
	padding: var(--space-lg) var(--space-xl);
	border-top: 1px solid var(--color-ui-panel-border);
}

html[data-theme="minimal"] .settings-row:first-child {
	border-top: 0;
}

html[data-theme="minimal"] .settings-row-text {
	display: flex;
	flex: 1 1 280px;
	flex-direction: column;
	gap: var(--space-3xs);
	min-width: 0;
}

html[data-theme="minimal"] .settings-row-label {
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	font-weight: 500;
	line-height: 20px;
}

html[data-theme="minimal"] .settings-row-hint {
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

html[data-theme="minimal"] .settings-row-control {
	display: flex;
	flex: 0 0 auto;
	align-items: center;
	gap: var(--space-sm);
}

html[data-theme="minimal"] .settings-row-control > :is(select, .select-wrap) {
	width: 240px;
}

/* A setting with a checkbox: the name is a label element for the checkbox,
   and the checkbox stands in a 32 x 32 px label cell. Both are targets of
   at least 24 px (the 18 px mark alone is not). */
html[data-theme="minimal"] label.settings-row-label {
	cursor: pointer;
}

html[data-theme="minimal"] .settings-row-control.settings-row-check {
	justify-content: center;
	box-sizing: border-box;
	width: 32px;
	height: 32px;
	margin: calc(-1 * var(--space-2xs)) calc(-1 * var(--space-2xs)) calc(-1 * var(--space-2xs)) 0;
	border-radius: var(--radius-md);
	cursor: pointer;
}

html[data-theme="minimal"] .settings-row-control.settings-row-check:hover {
	background-color: var(--color-ui-hover);
}

/*------------------------------
=25 (continued) FORM FIELDS IN THE APPLICATION
The rules that the application needs until its forms have the markup of
family 25 (.form-stack, .form-field, .select-wrap). The component sheet
uses that markup, so these rules do not reach it. Each rule names the
item or the condition that deletes it.
------------------------------*/

/* A field keeps the 10 px under it of the other themes where its form has
   no gap of its own yet: the dialogs (their fields are not .form-field
   yet; the frame of family 28 spaces only the children of the body), the
   forms of the settings pages (family 37; job 8 laid out the pages but
   kept their field markup) and the other forms with the out-of-flow
   captions of style.css. The forms of
   family 25, the Mikron card, the ticket dialog, the bill editor, the foot
   of a box, a row with a button beside the field, the search bar of a
   list (.resource-search-bar) and the chart settings panel
   (.chart-settings-panel) set their own spacing. UX-66 takes the dialogs
   and the settings out of it (their field markup); the rule stays while
   other views (the member page, the rate and expense forms, the project
   settings of a client) have fields without that markup. */
html[data-theme="minimal"] :is(.organization-input, .organization-input-small):where(:not(.form-stack *, .form-row *, .form-field *, .select-wrap > *, .field-date > *, .field-unit > *, .field-action-row > *, .resource-box-bottom *, .mikron_box *, .mikron_body *, .modal-ticket-dialog *, .billgen *, .resource-search-bar *, .chart-settings-panel *)) {
	margin-bottom: var(--space-md);
}

/* A select without the .select-wrap of family 25 draws the chevron as its
   background: two 4 px diagonal strokes in the secondary text, 12 px from
   the right edge (the place and the colour of the 16 px chevron icon). The
   selects of the ticket dialog get the icon from their wrapper. This rule
   goes when no select without .select-wrap is left: after UX-66 (the
   dialogs and the settings) still the member page, the rate and expense
   forms and the project settings of a client. */
html[data-theme="minimal"] select:is(.organization-input, .organization-input-small, .field):not([multiple], [size], .select-wrap > *, .ticket-modal-field > *, .ticket-assignment-control > *) {
	background-image:
		linear-gradient(45deg, transparent calc(50% - 1px), var(--color-text-secondary) calc(50% - .75px) calc(50% + .75px), transparent calc(50% + 1px)),
		linear-gradient(-45deg, transparent calc(50% - 1px), var(--color-text-secondary) calc(50% - .75px) calc(50% + .75px), transparent calc(50% + 1px));
	background-position: calc(100% - 20px) 50%, calc(100% - 16px) 50%;
	background-size: 4px 4px;
	background-repeat: no-repeat;
}

/* The rows of the non-working days keep the column widths of style.css:
   the field-action-row rule of family 25 gives every field of a row the
   free width and no minimum, so the date and the name would collapse
   beside the checkbox and the button. These rules go when the rows of
   organizations/partial_non_working_days.erb get the field markup of
   family 25 (UX-66). */
html[data-theme="minimal"] .field-action-row > :is(.non-working-day-date, .non-working-day-new-date) {
	flex: 0 0 155px;
}

html[data-theme="minimal"] .field-action-row > :is(.non-working-day-name, .non-working-day-new-name) {
	flex: 1 1 280px;
	min-width: 120px;
}

@media (max-width: 720px) {
	html[data-theme="minimal"] .field-action-row > :is(.non-working-day-date, .non-working-day-new-date) {
		flex: 1 1 110px;
		min-width: 0;
	}

	html[data-theme="minimal"] .field-action-row > :is(.non-working-day-name, .non-working-day-new-name) {
		flex: 2 1 120px;
		min-width: 0;
	}
}

/* The captions of style.css (a hidden label shown above its field, and the
   visible captions of the dialogs) have the type of the field caption:
   13/18 px, 500, the secondary text. The 24 px above the field stay: the
   18 px caption and the 6 px gap. The field markup of the dialogs (UX-66)
   deletes the dialog captions (the second selector and the h4 rule under
   it) and, with the settings pages, the rest. */
html[data-theme="minimal"] label.visually-hidden:not(.flextable *):has(+ .organization-input:not([type="checkbox"], [type="radio"], [type="color"], [type="file"])),
html[data-theme="minimal"] :is(.wizard-field > span:first-child, .modalContainer .member-credentials-field label, .modalBody label:not(.visually-hidden):has(+ div > .organization-input:first-child), .modalBody h4:has(+ .organization-input)) {
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
}

html[data-theme="minimal"] .modalBody h4:has(+ .organization-input) {
	margin: 0 0 var(--space-xs);
}

/* A caption of style.css stands out of flow at the end of the margin
   above it. After a row with a button beside its field, that margin
   (10 px) collapses into the 24 px above the next field, so the caption
   would cover the top of the field; the row gives up its margin there
   (the bill scheme and template rows of the settings pages). The field
   markup of the settings pages (UX-66) deletes this rule. */
html[data-theme="minimal"] .field-action-row:has(+ label.visually-hidden + .organization-input) {
	margin-bottom: 0;
}

/* A field is a block in Minimal (inline-block in the other themes), so
   its 24 px top margin collapses through a plain wrapper whose first
   child is the hidden-label caption, and the caption lands on the field
   (the "Date scope" of the bill filter dialog). A wrapper without a class
   starts a block formatting context, which keeps the margin inside it.
   UX-66 takes the dialogs and the settings out of it (their field
   markup); the rule stays while other views have such wrappers. */
html[data-theme="minimal"] div:not([class]):has(> label.visually-hidden:first-child + .organization-input) {
	display: flow-root;
}

/*------------------------------
=26 MIKRON FORM, TIMER BAR AND THE FORM | CALENDAR SWITCH
Replaces: #content.mikrons-new-content, .mikron_container, .mikron_box, the
copy button and the entry badge of the card, the timer bars,
the segment switch, the day summary (style.css =MIKRONS).
------------------------------*/

/* The page: the page header of family 4 with the view switch and the
   Templates tool, a one-line introduction, the timer bar, the cards, and a
   foot with the day summary and the actions. No grey panel behind the
   cards. */
html[data-theme="minimal"] .mikron-intro {
	max-width: 72ch;
	margin: calc(var(--space-sm) * -1) 0 var(--space-xl);
	color: var(--color-text-secondary);
	font-size: var(--font-size-md);
	line-height: 20px;
}

/* The segmented switch (Form | Calendar, Day | Week, the chart settings):
   a 32 px group of segments on the sunken surface with a hairline edge; the
   current segment is raised on the field surface (--color-field) with a
   hairline edge and text 1 in 600. Pages are links with aria-current="page"; choices are buttons
   with aria-pressed. */
html[data-theme="minimal"] .segmented {
	display: inline-flex;
	flex: 0 0 auto;
	box-sizing: border-box;
	height: var(--control-height);
	padding: 2px;
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-md);
	background: var(--color-background-secondary);
}

html[data-theme="minimal"] .segmented > :is(a, button) {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: var(--space-xs);
	box-sizing: border-box;
	min-width: 56px;
	height: 26px;
	padding: 0 var(--space-lg);
	border: 1px solid transparent;
	border-radius: var(--radius-sm);
	background: transparent;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
	text-decoration: none;
	white-space: nowrap;
	cursor: pointer;
}

html[data-theme="minimal"] .segmented > :is(a, button):hover {
	color: var(--color-text-primary);
}

html[data-theme="minimal"] .segmented > :is([aria-current="page"], [aria-pressed="true"]) {
	border-color: var(--color-ui-panel-border);
	background: var(--color-field);
	box-shadow: var(--shadow-xs);
	color: var(--color-text-primary);
	font-weight: 600;
}

html[data-theme="minimal"] .segmented > :is(a, button):focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 0;
}

/* The state text of the timer bars: a state dot (idle: a ring in the control
   colour) and the text; the bar rules below set the bars themselves. */
html[data-theme="minimal"] .mikron-timer-state {
	display: flex;
	flex: 1 1 auto;
	align-items: center;
	gap: var(--space-sm);
	min-width: 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
	font-variant-numeric: tabular-nums;
}

html[data-theme="minimal"] .mikron-timer-state::before {
	content: "";
	flex: 0 0 10px;
	width: 10px;
	height: 10px;
	box-sizing: border-box;
	border: 2px solid var(--color-control);
	border-radius: var(--radius-pill);
}

/* The cards: each card 320 px, 16 px apart. The "Add Mikron" button
   follows the last card, at the top of the row. Up to 600 px the cards
   wrap into one column at the full width (style.css also sets the column
   direction up to 600 px), and the container does not scroll. The 12 px
   top padding holds the draft badge on the top edge of a card. */
html[data-theme="minimal"] .mikron_container {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-start;
	gap: var(--space-xl);
	margin: 0 0 var(--space-3xl);
	padding: var(--space-lg) 0 0;
	overflow: visible;
	background: transparent;
}

/* Wider than 600 px the cards stand in one line that scrolls sideways,
   as in the other themes (UI-78, UX-215): the cards do not wrap and do not
   shrink. The scrolling container clips at its edges: the badge stays in
   the 12 px top padding, and 4 px of padding at the sides and the bottom
   hold the focus rings (at most 4 px outside a control). The negative
   margin keeps the cards in line with the page. */
@media (min-width: 601px) {
	html[data-theme="minimal"] .mikron_container {
		flex-wrap: nowrap;
		margin-right: calc(var(--space-2xs) * -1);
		margin-left: calc(var(--space-2xs) * -1);
		padding: var(--space-lg) var(--space-2xs) var(--space-2xs);
		overflow-x: auto;
		overflow-y: hidden;
	}

	html[data-theme="minimal"] .mikron_container > .mikron_box {
		flex-shrink: 0;
	}
}

/* The width of the card, and the distance of its fields from its edge: the
   16 px padding and the 1 px border. The edit dialog of a saved Mikron and
   its copy take the same width and distance (UI-80, UX-158, 26 (continued)).
   The body of the "Ticket to Mikron" dialog is also a .mikron_box; it keeps
   the card width of style.css as its maximum width (UX-143). */
html[data-theme="minimal"] :is(.mikron_box:not(.ticket-mikron-body), .mikron-edit-dialog) {
	--mikron-card-width: 320px;
	--mikron-card-inset: calc(var(--space-xl) + 1px);
}

/* The card: the box surface, 16 px padding, the fields without captions
   (UI-39), 8 px apart. */
html[data-theme="minimal"] .mikron_box {
	position: relative;
	display: flex;
	flex: 0 1 var(--mikron-card-width);
	flex-direction: column;
	gap: var(--space-sm);
	box-sizing: border-box;
	min-width: 0;
	margin: 0;
	padding: var(--space-xl);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	overflow: visible;
	background: var(--color-ui-panel);
	box-shadow: none;
	--caption-width: 56px;
}

/* The hours row: the slider and an 88 px number field (title "Hours").
   The sheet writes .mikron-hours-row, the application
   .mikron-duration-control with .mikron-slider-input (=26 continued). */
html[data-theme="minimal"] :is(.mikron-hours-row, .mikron-duration-control) {
	display: flex;
	align-items: center;
	gap: var(--space-lg);
	padding: var(--space-2xs) 0;
}

html[data-theme="minimal"] .mikron-hours-row > input[type="number"],
html[data-theme="minimal"] .mikron-duration-control > .mikron-slider-input {
	flex: 0 0 88px;
	width: 88px;
	text-align: right;
}

/* The times: captions in front (Date, From, To), the values right-aligned
   and tabular. */
html[data-theme="minimal"] .mikron_box .form-field.is-inline input {
	font-variant-numeric: tabular-nums;
	text-align: right;
}

/* The draft badge takes no room (UI-47): it stands on the card's top edge
   at the right. In the application the card, not the body, is its
   containing block; the second selector beats the place that style.css
   gives the badge of a card body. The remove button stands in the top
   right corner under it. */
html[data-theme="minimal"] .mikron-entry-badge,
html[data-theme="minimal"] .mikron_box > .mikron_body > .mikron-entry-badge {
	position: absolute;
	top: -10px;
	right: var(--space-lg);
	left: auto;
}

/* The copy and remove actions of a card: 28 px icon buttons in the card's
   top right corner (the copy opens a new card beside it). */
html[data-theme="minimal"] .mikron-card-actions {
	display: flex;
	justify-content: flex-end;
	gap: var(--space-3xs);
	margin: calc(var(--space-sm) * -1) calc(var(--space-sm) * -1) 0 0;
}

html[data-theme="minimal"] .mikron-add-card {
	flex: 0 0 auto;
	align-self: flex-start;
}

/* The foot: the day summary at the left, Clear drafts and Save at the
   right. The question of Clear drafts takes a line of its own under them
   ("27 (continued)", C1). */
html[data-theme="minimal"] .mikron-foot {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-lg) var(--space-3xl);
	padding: var(--space-xl) 0 0;
	border-top: 1px solid var(--color-ui-panel-border);
}

/* The sheet writes .button-row, the application .mikron-entry-actions
   (=26 continued). */
html[data-theme="minimal"] .mikron-foot > :is(.button-row, .mikron-entry-actions) {
	margin-left: auto;
}

html[data-theme="minimal"] .mikron-day-summary {
	display: flex;
	flex: 0 1 320px;
	flex-direction: column;
	gap: var(--space-xs);
	min-width: 0;
	max-width: 480px;
}

html[data-theme="minimal"] .mikron-day-summary-head {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: var(--space-lg);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

html[data-theme="minimal"] .mikron-day-summary-head > strong {
	font-weight: 600;
}

html[data-theme="minimal"] .mikron-day-summary-head > span {
	color: var(--color-text-secondary);
	font-variant-numeric: tabular-nums;
}

@media (max-width: 599px) {
	html[data-theme="minimal"] .mikron_box {
		flex-basis: 100%;
	}

	html[data-theme="minimal"] .mikron-foot > :is(.button-row, .mikron-entry-actions) {
		flex: 1 1 100%;
		justify-content: flex-end;
	}
}

/*------------------------------
=26 (continued) THE MIKRON FORM IN THE APPLICATION
The pages for new Mikrons (mikrons/mikrons.erb, calendar.erb), the cards
(mikron.erb, partial_mikron_selectors.erb, partial_mikron_entry_times.erb)
and the edit dialog keep the markup that their scripts read. These rules
give that markup the look of the sheet: the timer bars of
partial_mikron_timer_bar.erb are the timer box, the label column and the
field column of the times are the captions in front, .mikron-duration-control
is the hours row, and the remove button that the script writes is the
28 px icon button.
------------------------------*/

/* The views write the timer bars under the page header and its
   introduction in every theme, as the sheet shows them (UI-61). The empty
   lines of the views take no room. */
html[data-theme="minimal"] #content.mikrons-new-content > br,
html[data-theme="minimal"] #new_mikron_form > br,
html[data-theme="minimal"] .mikron-foot > br {
	display: none;
}

html[data-theme="minimal"] .content_header_menu_item > .icon.bookmark-black { --tool-icon: url(/icons/ui/bookmark.svg); }

/* The switch keeps the space of the other themes to the Templates tool. */
html[data-theme="minimal"] .mikron-entry-view-switch.segmented {
	align-self: center;
	margin-right: var(--space-sm);
}

html[data-theme="minimal"] .mikron-entry-view-switch.segmented > a {
	margin-left: 0;
}

/* The timer box: the idle bar (a ring and "Start timer") and the bar of a
   running timer (a filled dot, the state text and "Stop timer"). The
   running bar stays sticky at the top of the page, as in the other
   themes. The idle bar is grey, the panel colour of each variant. The bar
   of a running timer is black (#000000, UX-259 and UX-290) in Minimal and in
   Minimal Dark, so its text, its dot and the focus ring use light colours of
   its own (the text tokens of Minimal Light are dark): the text 16.8:1
   (#ececf0) and the filled dot at least 3.9:1 (the accent edge colour of
   Minimal Light). */
html[data-theme="minimal"] :is(.mikron-timer-start, .mikron-timer-bar) {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-sm) var(--space-lg);
	box-sizing: border-box;
	min-height: 44px;
	margin: 0 0 var(--space-xl);
	padding: var(--space-2xs) var(--space-sm) var(--space-2xs) var(--space-xl);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
	color: var(--color-text-primary);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

html[data-theme="minimal"] .mikron-timer-bar {
	--timer-bar-ink: #ececf0;
	border-color: #3d3f47;
	background: #000000;
	color: var(--timer-bar-ink);
}

html[data-theme="minimal"] :is(.mikron-timer-start, .mikron-timer-bar)[hidden] {
	display: none;
}

html[data-theme="minimal"] :is(.mikron-timer-start-dot, .mikron-timer-bar-dot, .mikron-timer-dot) {
	flex: 0 0 10px;
	box-sizing: border-box;
	width: 10px;
	height: 10px;
	border: 2px solid var(--color-control);
	border-radius: var(--radius-pill);
	background: transparent;
	box-shadow: none;
	opacity: 1;
	animation: none;
}

html[data-theme="minimal"] :is(.mikron-timer-bar-dot, .mikron-timer-dot) {
	border-color: var(--color-border-highlight);
	background: var(--color-border-highlight);
}

/* The project and the category of the running timer stand 12 px apart (no
   middle dot on screen; the separator span is hidden visually, see the
   leave parts of family 14). */
html[data-theme="minimal"] .mikron-timer-bar-label {
	display: inline-flex;
	flex: 0 1 auto;
	flex-wrap: wrap;
	gap: 0 var(--space-lg);
	font-weight: 500;
}

/* The state text ("No timer is running.", "Running since 09:12 (1:24)") takes
   the place of the clock. The bars have their own dot, so the dot of the
   sheet's state text is not drawn here. */
html[data-theme="minimal"] .mikron-timer-bar-clock {
	display: none;
}

html[data-theme="minimal"] :is(.mikron-timer-start, .mikron-timer-bar) .mikron-timer-state::before {
	content: none;
}

html[data-theme="minimal"] .mikron-timer-bar .mikron-timer-state {
	color: var(--timer-bar-ink);
	font-weight: 500;
}

/* The running bar sticks at the top of the window. style.css offsets it by
   the 30 px top padding of #content, so that no scrolled content shows above
   it; the Minimal themes have 24 px of padding, and 30 px would clip the bar
   by 6 px. */
html[data-theme="minimal"] .mikron-timer-bar {
	top: calc(-1 * var(--space-3xl));
}

/* On a phone the running bar is as tall as the idle bar (44 px), so that a
   start or a stop does not move the page. From 441 to 600 px it has one
   line, and the project and the category and the state text end with "…"
   when they are too long. Up to 440 px the line has no room for the project
   next to the state text ("Running since 09:12 (1:24)") and "Stop timer", so
   the running bar has two short lines (see the block below). */
@media (max-width: 600px) {
	html[data-theme="minimal"] .mikron-timer-bar {
		flex-wrap: nowrap;
		gap: var(--space-sm) var(--space-md);
	}

	html[data-theme="minimal"] .mikron-timer-bar-label {
		flex: 1 1 0;
		flex-wrap: nowrap;
		min-width: 0;
	}

	html[data-theme="minimal"] .mikron-timer-bar-label > .mikron-timer-bar-part,
	html[data-theme="minimal"] .mikron-timer-bar .mikron-timer-state {
		min-width: 0;
		overflow: hidden;
		text-overflow: ellipsis;
		white-space: nowrap;
	}

	html[data-theme="minimal"] .mikron-timer-bar .mikron-timer-state {
		flex: 0 1 auto;
	}
}

/* Up to 440 px the running bar has two lines of 16 px in the 44 px of the
   idle bar: the project and the category (cut with "…", one line, as in the
   other themes) over the state text, and "Stop timer" at the right. The two
   lines are the column .mikron-timer-bar-text. The buttons of both bars keep
   their width (flex: none), so the column of the running bar and the state
   text of the idle bar take the shortage and end with "…" (the state text is
   a block here, as the ellipsis needs). The dot of both bars stands in the
   left edge, level with the middle of the bar, and the running bar
   indents its lines by the dot, so that a start does not move the dot. The
   idle bar keeps one line and its height at 320 px, where its text and
   "Start timer" would wrap. */
@media (max-width: 440px) {
	html[data-theme="minimal"] .mikron-timer-start {
		flex-wrap: nowrap;
		gap: var(--space-sm);
	}

	html[data-theme="minimal"] .mikron-timer-bar {
		gap: 0 var(--space-sm);
		line-height: 16px;
	}

	html[data-theme="minimal"] :is(.mikron-timer-start, .mikron-timer-bar) .mikron-timer-state {
		display: block;
		min-width: 0;
		overflow: hidden;
		text-overflow: ellipsis;
		white-space: nowrap;
	}

	html[data-theme="minimal"] .mikron-timer-start .mikron-timer-state {
		flex: 0 1 auto;
	}

	html[data-theme="minimal"] .mikron-timer-bar .mikron-timer-state {
		flex: 0 0 auto;
	}

	/* A button label that is wider than 140 px (the French ones) takes two
	   lines of 15 px in the 32 px of the button. */
	html[data-theme="minimal"] :is(.mikron-timer-toggle, .mikron-timer-bar-stop) {
		flex: none;
		max-width: 140px;
		padding-block: 0;
		line-height: 15px;
		white-space: normal;
	}

	/* The dot level with the middle of the bar (50% of the 42 px inside the
	   border, less half of the 10 px of the dot), where the dot of the idle
	   bar stands. */
	html[data-theme="minimal"] .mikron-timer-bar-dot {
		position: absolute;
		top: calc(50% - 5px);
		left: var(--space-xl);
	}

	html[data-theme="minimal"] .mikron-timer-bar-text {
		display: flex;
		flex: 1 1 0;
		flex-direction: column;
		justify-content: center;
		min-width: 0;
		padding-left: calc(10px + var(--space-sm));
	}

	/* The label is the containing block of the separator, which is hidden
	   visually and absolute: it stays inside the clipped label and does not
	   widen the bar. */
	html[data-theme="minimal"] .mikron-timer-bar-label {
		display: block;
		position: relative;
		flex: 0 0 auto;
		overflow: hidden;
		text-overflow: ellipsis;
		white-space: nowrap;
	}

	html[data-theme="minimal"] .mikron-timer-bar-label > .mikron-timer-bar-part {
		display: inline;
	}

	html[data-theme="minimal"] .mikron-timer-bar-label > .mikron-timer-bar-separator + .mikron-timer-bar-part {
		margin-inline-start: var(--space-lg);
	}
}

/* At 360 px and narrower both bars have a 10 px edge and no dot (it has no
   room next to the state text), and the buttons have no icon and 8 px of
   padding, so that the state text and the button stay whole at 320 px; a
   button label of more than 100 px takes two lines. */
@media (max-width: 360px) {
	html[data-theme="minimal"] :is(.mikron-timer-start, .mikron-timer-bar) {
		padding-left: var(--space-md);
	}

	html[data-theme="minimal"] :is(.mikron-timer-start-dot, .mikron-timer-bar-dot) {
		display: none;
	}

	html[data-theme="minimal"] .mikron-timer-bar-text {
		padding-left: 0;
	}

	html[data-theme="minimal"] :is(.mikron-timer-start, .mikron-timer-bar) :is(.mikron-timer-toggle, .mikron-timer-bar-stop).has-icon {
		max-width: 100px;
		padding-inline: var(--space-sm);
	}

	html[data-theme="minimal"] :is(.mikron-timer-start, .mikron-timer-bar) :is(.mikron-timer-toggle, .mikron-timer-bar-stop).has-icon::before {
		content: none;
	}
}

/* "Start timer" and "Stop timer" are the secondary button of family 23
   (.button.is-secondary.has-icon) with a coloured fill (UX-290): "Start
   timer" on the grey idle bar is the green confirm fill of family 23 with its
   white label and its hover and a play icon; "Stop timer" on the black bar of
   the running timer is the danger fill with its white label and its hover and
   the record icon (a filled circle). They stand at the right of the box. The
   views may not write inline styles, so the icons are set here. The focus
   ring of the black bar is light; the ring of the grey bar is the one of the
   theme. */
html[data-theme="minimal"] :is(.mikron-timer-toggle, .mikron-timer-bar-stop) {
	margin-left: auto;
}

/* The two class names after the list give these rules more weight than the
   secondary button (.button.is-secondary) of family 23. */
html[data-theme="minimal"] .mikron-timer-toggle.button.is-secondary {
	border-color: var(--color-button-confirm);
	background-color: var(--color-button-confirm);
	color: var(--color-button-confirm-text);
}

html[data-theme="minimal"] .mikron-timer-toggle.button.is-secondary:hover {
	border-color: var(--color-button-confirm-hover);
	background-color: var(--color-button-confirm-hover);
	color: var(--color-button-confirm-text);
}

html[data-theme="minimal"] .mikron-timer-bar-stop.button.is-secondary {
	border-color: var(--color-action-danger);
	background-color: var(--color-action-danger);
	color: var(--color-action-danger-text);
}

html[data-theme="minimal"] .mikron-timer-bar-stop.button.is-secondary:hover {
	border-color: var(--color-action-danger-hover);
	background-color: var(--color-action-danger-hover);
	color: var(--color-action-danger-text);
}

html[data-theme="minimal"] .mikron-timer-bar-stop:focus-visible {
	outline-color: var(--timer-bar-ink);
}

html[data-theme="minimal"] .mikron-timer-toggle { --button-icon: url(/icons/ui/play.svg); }
html[data-theme="minimal"] .mikron-timer-bar-stop { --button-icon: url(/icons/ui/record.svg); }
html[data-theme="minimal"] :is(#addButtonDiv.mikron-add-card, .mikron-calendar-add) { --button-icon: url(/icons/ui/plus.svg); }

/* "Clear drafts" of both pages is the secondary button of family 23
   (.button.is-secondary). Its markup keeps .button_red, because the other
   themes, also the decorative ones, draw it red. The danger fill of
   family 23 has the specificity of .button.is-secondary and comes later
   (it sets only the three colours), and family 23 is shell code shared
   with Skeleton, so this rule gives the enabled button the secondary
   colours again; a disabled one has the disabled look of family 23. */
html[data-theme="minimal"] .button.is-secondary.button_red.mikron-drafts-clear:not(:disabled) {
	border-color: var(--color-button-edge);
	background-color: var(--color-ui-panel);
	color: var(--color-text-primary);
}

html[data-theme="minimal"] .button.is-secondary.button_red.mikron-drafts-clear:hover:not(:disabled) {
	border-color: var(--color-button-edge-hover);
	background-color: var(--color-ui-hover);
	color: var(--color-text-primary);
}

/* The running timer inside a draft card or the calendar pane. */
html[data-theme="minimal"] .mikron-timer-status {
	gap: var(--space-sm);
	margin: 0;
	padding: var(--space-2xs) var(--space-sm);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-md);
	background: var(--color-background-secondary);
	color: var(--color-text-primary);
	font-size: var(--font-size-sm);
	font-variant-numeric: tabular-nums;
}

/* The card row has no width of its own and no grey panel. */
html[data-theme="minimal"] #content.mikrons-new-content .mikron_container {
	width: auto;
	max-width: none;
}

/* The fields of a card: the column of family 26, 8 px apart, without the
   inner padding of the other themes (the card has 16 px). In the edit
   dialog the form stands between the card and its fields (mikrons.erb;
   C20: without the second selector the fields touched each other). */
html[data-theme="minimal"] .mikron_box > .mikron_body,
html[data-theme="minimal"] .mikron-edit-dialog .mikron_box > form > .mikron_body {
	display: flex;
	flex-direction: column;
	position: static;
	gap: var(--space-sm);
	padding: 0;
	transition: none;
}

html[data-theme="minimal"] .mikron_body > label:has(> .mikronDescription),
html[data-theme="minimal"] .mikron_body > div:has(> label > .mikronDescription) {
	display: block;
}

html[data-theme="minimal"] .mikronDescription,
html[data-theme="minimal"] :is(.mikron_box, .mikron-calendar-draft) .mikron_body > .mikron_selector:first-of-type {
	margin: 0;
}

/* The lists of the Mikron templates dialog stand apart with the field gap of that dialog (10 px, the
   gap of .mikron-bookmark-meta). The zero margin of the field rule would let them touch (UX-240). */
html[data-theme="minimal"] .mikron-bookmark-form-pane .mikron_body > .mikron_selector {
	margin-bottom: var(--space-md);
}

/* The caption "Description" stands out of flow at the end of the margin above
   it. The last list gives up its margin, so the 24 px above the description
   hold the caption and its gap and the caption does not cover the box
   (UX-250; see the field-action-row rule of family 25). */
html[data-theme="minimal"] .mikron-bookmark-form-pane .mikron_body > .mikron_selector:has(+ label.visually-hidden) {
	margin-bottom: 0;
}

html[data-theme="minimal"] .mikron-task-requirement:not(.is-visible) {
	display: none;
}

html[data-theme="minimal"] .mikron-task-requirement {
	margin: 0;
	font-size: var(--font-size-sm);
	line-height: 18px;
}

/* The hours row of family 26 (the shared rules are there) without the
   margins of the other themes; the hours are tabular. */
html[data-theme="minimal"] .mikron-duration-control {
	margin: 0;
}

html[data-theme="minimal"] .mikron-duration-control > .mikron-slider-input {
	margin: 0;
	font-variant-numeric: tabular-nums;
}

/* The slider of the other themes has a frame, a fill in the organisation
   colour and a dark knob on hover; family 25 draws the track and the knob. */
html[data-theme="minimal"] .mikron-slider {
	width: auto;
	margin: 0;
	border: 0;
	border-radius: 0;
}

html[data-theme="minimal"] .mikron-slider::-webkit-slider-thumb:hover {
	background: var(--color-knob);
}

html[data-theme="minimal"] .mikron-slider::-moz-range-thumb:hover {
	background: var(--color-knob);
}

/* Date, From, (End date) and To: the label column is the 56 px caption
   column in front of the field column; each label is as high as its
   field (36 px) and the rows are 8 px apart. A hidden end date hides its
   label and its field. */
html[data-theme="minimal"] .mikron-entry-times {
	display: flex;
	gap: var(--space-lg);
	margin: 0;
}

html[data-theme="minimal"] .mikron-entry-times > .mikronDate {
	display: flex;
	flex: 0 0 var(--caption-width, 56px);
	flex-direction: column;
	gap: var(--space-sm);
	width: auto;
	height: auto;
	padding: 0;
	float: none;
	text-align: left;
}

html[data-theme="minimal"] .mikron-entry-times > .mikronTime {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	gap: var(--space-sm);
	min-width: 0;
}

html[data-theme="minimal"] .mikronDateText {
	margin: 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: var(--field-height);
	text-align: left;
	white-space: nowrap;
}

html[data-theme="minimal"] .mikronTime > div:has(> .mikron-time-field > .hidden-from-user) {
	display: none;
}

/* A hidden end-date caption stays in the caption column with its width but
   without height: the column grows to its widest caption (the automatic
   minimum width of a flex item is larger than the 56 px basis; German
   "Enddatum" is 64 px), and the negative top margin cancels the gap of the
   column. The hidden field keeps its own hidden label. So the fields of a
   card, of the calendar pane and of "Ticket to Mikron" stand where they
   stand in the edit dialog, which shows the end date, and they do not move
   when the end date shows (UI-80, UX-158). */
html[data-theme="minimal"] .mikronDate > .mikron-end-date-label.hidden-from-user {
	position: static;
	width: auto;
	height: 0;
	margin: calc(-1 * var(--space-sm)) 0 0;
	clip: auto;
	visibility: hidden;
}

html[data-theme="minimal"] .mikron-time-field {
	display: block;
}

/* The time and date fields; a checkbox among them (the manual hour
   override of the bill editor, C11) keeps the checkbox of family 25. The
   :where() keeps the specificity of the rule. */
html[data-theme="minimal"] .mikronTime input:not(:where([type="checkbox"])) {
	height: var(--field-height);
	margin: 0;
	padding: 0 var(--space-lg);
	font-variant-numeric: tabular-nums;
	text-align: right;
}

/* The remove control of a card is the 28 px icon button of family 24 with
   the cross (the script writes .icon-button.is-28); it stands in the top
   right corner of the card. */
html[data-theme="minimal"] .mikron_box > .btnMikronDelete {
	position: absolute;
	top: var(--space-sm);
	right: var(--space-sm);
	z-index: 1;
}

/* Every card of the form keeps the row of the card actions above the
   fields (16 px padding, the 28 px button 8 px higher, 8 px gap), also
   while it has no remove button: the script adds the button on the first
   edit, and the fields must not move then (UI-47). */
html[data-theme="minimal"] #new_mikron_form .mikron_container > .mikron_box {
	padding-top: 44px;
}

/* The foot: the day summary at the left, Clear drafts and Save at the
   right (the views write Save first; family 26 puts the actions at the
   right). */
html[data-theme="minimal"] .mikron-foot > .mikron-entry-actions {
	flex-wrap: wrap;
	gap: var(--space-sm);
}

html[data-theme="minimal"] .mikron-entry-actions > .mikron-drafts-clear {
	order: -1;
}

html[data-theme="minimal"] .mikron-day-summary h4 {
	margin: 0;
	padding: 0;
	font-size: var(--font-size-sm);
	font-weight: 600;
	line-height: 18px;
}

html[data-theme="minimal"] .mikron-day-summary :is(.mikron-day-summary-today, .mikron-day-summary-list, .mikron-day-summary-unavailable) {
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
	font-variant-numeric: tabular-nums;
}

/* The edit dialog (mikrons.erb) and its copy show the card without its
   frame: the dialog is the frame. It has the width of the card. Its header,
   body and footer have the distance of the card's fields from the card's
   edge at the sides, so the fields stand where they stand on the card
   (UI-80, UX-158). The dialog is at most as wide as the space in the
   container. The footer of family 28 holds Delete at the left, the ⊕ copy
   button (UI-47) and Save, on one row; it has no Cancel (UX-220). These rules are more specific than the rules of
   the frame and of the footer of family 28, which come later in the file.
   The rules of family 28 for a pair of dialogs are more specific: the
   rules below reset them for the Mikron pair. */
html[data-theme="minimal"] .modalDialog.mikron-edit-dialog {
	flex: 0 1 var(--mikron-card-width);
	width: var(--mikron-card-width);
	max-width: min(var(--mikron-card-width), 100%);
}

html[data-theme="minimal"] .mikron-edit-dialog .modalHeader {
	padding-left: var(--mikron-card-inset);
}

html[data-theme="minimal"] .mikron-edit-dialog .modalBody {
	padding-right: var(--mikron-card-inset);
	padding-left: var(--mikron-card-inset);
}

/* The hairline of the footer stands under the description with the 8 px
   field gap of the card, not the 24 px of family 28 (UX-220). The script
   adds an empty status of the lists at the end of the fields of an
   editable dialog; empty, it takes back the gap of the column above it. */
html[data-theme="minimal"] .mikron-edit-dialog .modalBody .modalFooter {
	margin-top: var(--space-sm);
	margin-right: calc(-1 * var(--mikron-card-inset));
	margin-left: calc(-1 * var(--mikron-card-inset));
	padding-right: var(--mikron-card-inset);
	padding-left: var(--mikron-card-inset);
}

html[data-theme="minimal"] .mikron-edit-dialog .mikron_body > .mikron-resource-status:empty {
	margin-top: calc(-1 * var(--space-sm));
}

/* The copy stands beside its dialog from 760 px, as in the other themes
   (UI-78), and the two line up at the top. Family 28 (shared with Skeleton)
   stacks a pair of dialogs below 900 px at the full width and without a
   maximum height. The pair of two cards fits from 760 px, so from 760 to
   899 px the rules below put the dialogs side by side again, with the width
   of the card and at most the height of the window: the header stays, and
   the body and the footer scroll, as from 900 px. The rules of the
   ticket pair (28 MODALS: THE TICKET DIALOG) do the same. Below 760 px the
   copy stands under its dialog, centred; the max-width above keeps both at
   the width of the card. */
html[data-theme="minimal"] .modalContainer:has(> .modalDialog.mikron-edit-dialog + .modalDialog.mikron-edit-dialog) {
	align-items: flex-start;
	align-content: safe center;
}

@media (min-width: 760px) and (max-width: 899px) {
	html[data-theme="minimal"] .modalContainer:has(> .modalDialog.mikron-edit-dialog + .modalDialog.mikron-edit-dialog) {
		flex-direction: row;
		flex-wrap: wrap;
		justify-content: center;
	}

	html[data-theme="minimal"] .modalContainer:has(> .modalDialog.mikron-edit-dialog + .modalDialog.mikron-edit-dialog) > .modalDialog.mikron-edit-dialog {
		flex: 0 1 var(--mikron-card-width);
		width: var(--mikron-card-width);
		max-height: 100%;
	}
}

@media (max-width: 759px) {
	html[data-theme="minimal"] .modalContainer:has(> .modalDialog.mikron-edit-dialog + .modalDialog.mikron-edit-dialog) {
		align-items: center;
	}
}

html[data-theme="minimal"] .modalDialog.mikron-edit-dialog .mikron_box {
	flex: none;
	width: auto;
	max-width: 100%;
	margin: 0;
	padding: 0;
	border: 0;
	background: none;
}

html[data-theme="minimal"] .mikron-edit-dialog .mikron_body {
	padding: 0;
}

/* The ⊕ copy button is the 32 px bordered icon button of family 24 with
   the plus-circle icon. */
html[data-theme="minimal"] .mikron-copyarrow {
	--icon: url(/icons/ui/plus-circle.svg);
}

/* A disabled Delete (the Mikron of another member) has the disabled look of
   family 23 (C19). The quiet danger rule of family 23 is stronger than its
   disabled rule, and family 23 is shell code that Skeleton copies, so this
   rule states the disabled look again for this button. Remove with UX-102. */
html[data-theme="minimal"] .button_standard.button_red.button_quiet.mikron-delete-open:disabled,
html[data-theme="minimal"] .button_standard.button_red.button_quiet.mikron-delete-open:disabled:hover {
	border-color: var(--color-ui-panel-border);
	background-color: var(--color-background-secondary);
	box-shadow: none;
	color: var(--color-placeholder);
}

/*------------------------------
=27 MIKRON CALENDAR
Replaces: .mikron-calendar and its state colours, the ec-* variable map,
the event shapes, the week totals, the details pane and the draft bar
(style.css =MIKRON CALENDAR). The calendar library (event-calendar.min.js)
keeps its markup; these rules style its classes.
------------------------------*/

/* The toolbar: the arrows and Today as one group of secondary buttons, the
   range title (16 px, 600), the Day | Week switch and "Add entry" (a
   secondary button with the plus icon; the page's primary action is Save
   in the draft bar). */
html[data-theme="minimal"] .mikron-calendar-toolbar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-sm) var(--space-lg);
	margin: 0 0 var(--space-lg);
}

html[data-theme="minimal"] .mikron-calendar-nav {
	display: flex;
	gap: var(--space-2xs);
}

html[data-theme="minimal"] .mikron-calendar-range {
	flex: 1 1 auto;
	min-width: 0;
	margin: 0;
	padding: 0;
	font-size: var(--font-size-lg);
	font-weight: 600;
	line-height: 24px;
	font-variant-numeric: tabular-nums;
}

/* The layout: the grid takes the free width (at least 560 px), the details
   pane 352 px at the right. When both do not fit (the 1024 px window), the
   pane goes under the grid at 352 px; under 900 px it takes the full
   width. */
html[data-theme="minimal"] .mikron-calendar-layout {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-start;
	gap: var(--space-3xl);
}

html[data-theme="minimal"] .mikron-calendar-grid {
	flex: 1 1 560px;
	min-width: 0;
	overflow: hidden;
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
}

/* The pane is a box of family 15 (the padding and the sunken surface of
   the branch go). Its footer is the dialog footer of family 28 with the
   12 x 16 px padding of a box foot: Delete at the left, the ⊕ copy button
   (UI-47: a 32 px bordered icon button, .mikron-copyarrow) and Apply at
   the right. They need about 210 px, so they stand on one line in every
   pane width (at least 320 px, or the width of the column in a window
   narrower than 340 px). */
html[data-theme="minimal"] .mikron-calendar-pane {
	flex: 0 1 352px;
	min-width: min(320px, 100%);
	height: auto;
	padding: 0;
	overflow: hidden;
	background-color: var(--color-ui-panel);
	border-radius: var(--radius-lg);
}

html[data-theme="minimal"] .mikron-calendar-pane > .mikron-calendar-pane-foot {
	padding: var(--space-lg) var(--space-xl);
}

@media (max-width: 899px) {
	html[data-theme="minimal"] .mikron-calendar-pane {
		flex: 1 1 100%;
	}
}

/* The grid of the sheet specimen (the library draws the same parts with
   its ec-* classes): a head row of days, a time column, hour rows with
   hairlines and half-hour rows with a dashed hairline. */
html[data-theme="minimal"] .cal-head,
html[data-theme="minimal"] .cal-foot {
	display: flex;
	border-bottom: 1px solid var(--color-ui-panel-border);
	background: var(--color-background-secondary);
}

html[data-theme="minimal"] .cal-foot {
	border-top: 1px solid var(--color-ui-panel-border);
	border-bottom: 0;
}

html[data-theme="minimal"] .cal-head > div,
html[data-theme="minimal"] .cal-foot > div {
	flex: 1 1 0;
	box-sizing: border-box;
	min-width: 0;
	padding: var(--space-sm) var(--space-xs);
	border-left: 1px solid var(--color-ui-panel-border);
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
	text-align: center;
	font-variant-numeric: tabular-nums;
	white-space: nowrap;
}

html[data-theme="minimal"] .cal-foot > div {
	color: var(--color-text-primary);
	font-weight: 600;
}

html[data-theme="minimal"] .cal-foot > div.is-empty {
	color: var(--color-text-secondary);
	font-weight: 400;
}

html[data-theme="minimal"] .cal-head > .cal-time,
html[data-theme="minimal"] .cal-foot > .cal-time,
html[data-theme="minimal"] .cal-body > .cal-time {
	flex: 0 0 56px;
	border-left: 0;
}

html[data-theme="minimal"] .cal-head > .is-today {
	color: var(--color-button-confirm-ink);
	font-weight: 600;
}

html[data-theme="minimal"][data-theme-variant="dark"] .cal-head > .is-today {
	color: var(--color-border-highlight);
}

html[data-theme="minimal"] .cal-body {
	position: relative;
	display: flex;
}

html[data-theme="minimal"] .cal-body > .cal-time {
	display: flex;
	flex-direction: column;
}

html[data-theme="minimal"] .cal-body > .cal-time > span {
	box-sizing: border-box;
	height: 48px;
	padding: 0 var(--space-sm) 0 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	line-height: 16px;
	text-align: right;
	font-variant-numeric: tabular-nums;
	transform: translateY(-8px);
}

html[data-theme="minimal"] .cal-body > .cal-time > span:first-child {
	transform: none;
}

html[data-theme="minimal"] .cal-day {
	position: relative;
	flex: 1 1 0;
	min-width: 0;
	border-left: 1px solid var(--color-ui-panel-border);
	background-image: repeating-linear-gradient(to bottom, transparent 0 23px, color-mix(in srgb, var(--color-ui-panel-border) 60%, transparent) 23px 24px, transparent 24px 47px, var(--color-ui-panel-border) 47px 48px);
}

/* Today: a quiet accent tint on the column and the day name in accent
   ink; the now line is a 2 px line in the accent edge colour with an 8 px
   dot. */
html[data-theme="minimal"] .cal-day.is-today {
	background-color: color-mix(in srgb, var(--color-selected) 60%, transparent);
}

html[data-theme="minimal"] .cal-now {
	position: absolute;
	right: 0;
	left: -4px;
	height: 2px;
	background: var(--color-border-highlight);
}

html[data-theme="minimal"] .cal-now::before {
	content: "";
	position: absolute;
	top: -3px;
	left: 0;
	width: 8px;
	height: 8px;
	border-radius: var(--radius-pill);
	background: var(--color-border-highlight);
}

/* An entry: the project colour as a 3 px edge at the left and a 12 %
   tint; the time (600, tabular), the project and category codes, the
   description in text 2. Text is 12/16 in the primary text. An entry shows
   only lines that fit whole: its parts are items of a column that wraps,
   so a part without room moves to a second column, which the entry clips
   (no line is cut in half). The entry is a size container; its width and
   height decide what it shows:
   - 80 px wide or more: everything that fits;
   - 40 to 79 px (two entries side by side in a week column): the start
     time only;
   - under 40 px wide or under 16 px high (an entry of 15 minutes): only
     the colour edge and the tint.
   The title (the browser tooltip) and the aria-label of the entry carry
   the whole text in every case; the details pane shows it when the entry
   is selected. */
html[data-theme="minimal"] .cal-event {
	position: absolute;
	right: 3px;
	left: 3px;
	display: flex;
	flex-direction: column;
	flex-wrap: wrap;
	align-content: flex-start;
	box-sizing: border-box;
	overflow: hidden;
	padding: 2px 0;
	border-left: 3px solid var(--event-colour, var(--entity-project));
	border-radius: var(--radius-sm);
	background: color-mix(in srgb, var(--event-colour, var(--entity-project)) 12%, var(--color-ui-panel));
	color: var(--color-text-primary);
	font-size: var(--font-size-xs);
	line-height: 16px;
	cursor: pointer;
	container: cal-event / size;
}

html[data-theme="minimal"] .cal-event > * {
	display: block;
	flex: 0 0 auto;
	box-sizing: border-box;
	width: 100%;
	padding: 0 var(--space-2xs) 0 var(--space-xs);
}

html[data-theme="minimal"] .cal-event > b {
	font-weight: 600;
	font-variant-numeric: tabular-nums;
}

/* The parts of the time and of the codes do not break inside; a long word
   of the description breaks rather than being cut at the edge. */
html[data-theme="minimal"] .cal-event > :is(b, .cal-event-code) > span {
	display: inline-block;
	white-space: nowrap;
}

/* The project and the category code: two words 6 px apart without a
   separator; each stays whole and the second wraps under the first when
   the entry is narrow (a middle dot was left alone at a line end). */
html[data-theme="minimal"] .cal-event > .cal-event-code {
	display: flex;
	flex-wrap: wrap;
	column-gap: var(--space-xs);
}

html[data-theme="minimal"] .cal-event > .cal-event-desc {
	color: var(--color-text-secondary);
	overflow-wrap: break-word;
}

@container cal-event (max-width: 79px) {
	html[data-theme="minimal"] .cal-event > :is(.cal-event-code, .cal-event-desc),
	html[data-theme="minimal"] .cal-event > b > span:nth-child(2) {
		display: none;
	}

	html[data-theme="minimal"] .cal-event > * {
		padding: 0 2px 0 var(--space-2xs);
	}
}

@container cal-event (max-width: 39px) or (max-height: 15px) {
	html[data-theme="minimal"] .cal-event > * {
		display: none;
	}
}

html[data-theme="minimal"] .cal-event:hover {
	background: color-mix(in srgb, var(--event-colour, var(--entity-project)) 20%, var(--color-ui-panel));
}

/* A draft: a dashed control edge around the entry (it is not saved yet). */
html[data-theme="minimal"] .cal-event.is-draft {
	border-top: 1px dashed var(--color-control);
	border-right: 1px dashed var(--color-control);
	border-bottom: 1px dashed var(--color-control);
}

/* An entry that cannot be saved: an error edge and an alert icon. */
html[data-theme="minimal"] .cal-event.is-invalid {
	box-shadow: inset 0 0 0 1px var(--color-error-dark);
}

html[data-theme="minimal"] .cal-event.is-invalid > b::after {
	content: "";
	display: inline-block;
	width: 12px;
	height: 12px;
	margin-left: var(--space-2xs);
	background-color: var(--color-error-dark);
	-webkit-mask: url(/icons/ui/alert-circle.svg) center / 12px no-repeat;
	mask: url(/icons/ui/alert-circle.svg) center / 12px no-repeat;
	vertical-align: -1px;
}

/* The selected entry: a 2 px ring in the focus colour. */
html[data-theme="minimal"] .cal-event.is-selected,
html[data-theme="minimal"] .cal-event:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 1px;
}

/* The week total and the draft bar under the grid. */
html[data-theme="minimal"] .mikron-calendar-week {
	padding: var(--space-lg) 0 0;
	font-size: var(--font-size-md);
	font-weight: 600;
	line-height: 20px;
	font-variant-numeric: tabular-nums;
}

html[data-theme="minimal"] .mikron-calendar-savebar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-lg);
	margin: var(--space-3xl) 0 0;
	padding: var(--space-lg) var(--space-lg) var(--space-lg) var(--space-xl);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
}

html[data-theme="minimal"] .mikron-calendar-savebar > p {
	flex: 1 1 auto;
	margin: 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
}

/*------------------------------
=27 (continued) THE MIKRON CALENDAR IN THE APPLICATION
The calendar page (mikrons/calendar.erb) keeps the markup of the
EventCalendar library and of treetops.mikrons_calendar.js. The sheet draws
the same parts with .cal-*; these rules give them to the ec-* classes: the
toolbar (.ec-toolbar), the frame (.ec-main), the day heads (.ec-header),
the time column (.ec-sidebar), today (.ec-today), the now line
(.ec-now-indicator) and the entries (.ec-event); the totals row
(.mikron-calendar-foot), the pane (.mikron-calendar-pane) and the draft
bar (.mikron-calendar-savebar) are the application's own.
------------------------------*/

html[data-theme="minimal"] .mikron-calendar .ec {
	--ec-bg-color: var(--color-ui-panel);
	--ec-text-color: var(--color-text-primary);
	--ec-border-color: var(--color-ui-panel-border);
	--ec-today-bg-color: color-mix(in srgb, var(--color-selected) 60%, var(--color-ui-panel));
	--ec-highlight-color: var(--color-selected);
	--ec-now-indicator-color: var(--color-border-highlight);
	--ec-popup-bg-color: var(--color-ui-panel);
	font-family: var(--font-ui-family);
}

/* The layout: the grid takes the free width (at least 560 px), the side
   column with the pane 352 px; under 900 px the pane takes the full
   width under the grid. */
html[data-theme="minimal"] .mikron-calendar-main {
	gap: var(--space-3xl);
}

html[data-theme="minimal"] .mikron-calendar-grid-column {
	flex: 1 1 560px;
}

html[data-theme="minimal"] .mikron-calendar-side {
	flex: 0 1 352px;
	min-width: 320px;
}

html[data-theme="minimal"] .mikron-calendar .mikron-calendar-grid {
	flex: none;
	overflow: visible;
	border: 0;
	border-radius: 0;
	background: transparent;
}

@media (max-width: 899px) {
	html[data-theme="minimal"] .mikron-calendar-side {
		flex: 1 1 100%;
		min-width: 0;
	}
}

/* The toolbar: the arrows (32 px bordered icon buttons) and Today as one
   group, the range title (16/24 px, 600), and the Day | Week switch. */
html[data-theme="minimal"] .mikron-calendar .ec-toolbar {
	flex-wrap: wrap;
	gap: var(--space-sm) var(--space-lg);
	margin: 0 0 var(--space-lg);
}

html[data-theme="minimal"] .mikron-calendar .ec-toolbar > .ec-start {
	gap: var(--space-2xs);
}

html[data-theme="minimal"] .mikron-calendar .ec-toolbar > .ec-start > .ec-button-group {
	gap: var(--space-2xs);
}

html[data-theme="minimal"] .mikron-calendar .ec-toolbar > .ec-center {
	flex: 1 1 auto;
	min-width: 0;
}

html[data-theme="minimal"] .mikron-calendar .ec-title {
	margin: 0;
	padding: 0;
	font-size: var(--font-size-lg);
	font-weight: 600;
	line-height: 24px;
	font-variant-numeric: tabular-nums;
}

/* The arrows and Today: the family 23 secondary button, restated, because
   the calendar library writes these buttons. */
html[data-theme="minimal"] .mikron-calendar .ec-toolbar > .ec-start .ec-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	min-width: 32px;
	height: var(--control-height);
	margin: 0;
	padding: 0 var(--space-lg);
	border: 1px solid var(--color-button-edge);
	border-radius: var(--radius-md);
	background: var(--color-ui-panel);
	color: var(--color-text-primary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
}

html[data-theme="minimal"] .mikron-calendar .ec-toolbar > .ec-start .ec-button-group > .ec-button {
	width: 32px;
	padding: 0;
	color: var(--color-text-secondary);
}

html[data-theme="minimal"] .mikron-calendar .ec-toolbar > .ec-start .ec-button:not(:disabled):hover {
	border-color: var(--color-button-edge-hover);
	background: var(--color-ui-hover);
	color: var(--color-text-primary);
}

/* Day | Week: the segmented switch of family 26. */
html[data-theme="minimal"] .mikron-calendar .ec-toolbar > .ec-end > .ec-button-group {
	box-sizing: border-box;
	height: var(--control-height);
	padding: 2px;
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-md);
	background: var(--color-background-secondary);
}

html[data-theme="minimal"] .mikron-calendar .ec-toolbar > .ec-end .ec-button {
	box-sizing: border-box;
	min-width: 56px;
	height: 26px;
	margin: 0;
	padding: 0 var(--space-lg);
	border: 1px solid transparent;
	border-radius: var(--radius-sm);
	background: transparent;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
}

html[data-theme="minimal"] .mikron-calendar .ec-toolbar > .ec-end .ec-button:not(:disabled):hover {
	border-color: transparent;
	background: transparent;
	color: var(--color-text-primary);
}

html[data-theme="minimal"] .mikron-calendar .ec-toolbar > .ec-end .ec-button.ec-active {
	border-color: var(--color-ui-panel-border);
	background: var(--color-field);
	box-shadow: var(--shadow-xs);
	color: var(--color-text-primary);
	font-weight: 600;
}

html[data-theme="minimal"] .mikron-calendar .ec-toolbar .ec-button:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 0;
}

/* The grid: the panel surface in a hairline frame with 8 px corners; the
   totals row closes it at the bottom. The day heads 13 px 500 in the
   secondary text on the sunken surface; today in the accent ink and 600.
   The time column 56 px with 12 px tabular times. */
html[data-theme="minimal"] .mikron-calendar .ec-main {
	border: 1px solid var(--color-ui-panel-border);
	border-bottom: 0;
	border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

html[data-theme="minimal"] .mikron-calendar .ec-header,
html[data-theme="minimal"] .mikron-calendar .ec-body {
	border-width: 0;
}

html[data-theme="minimal"] .mikron-calendar .ec-header {
	overflow: hidden;
	background-color: var(--color-background-secondary);
	border-bottom: 1px solid var(--color-ui-panel-border);
	border-radius: 7px 7px 0 0;
	--ec-bg-color: var(--color-background-secondary);
	--ec-today-bg-color: var(--color-background-secondary);
}

html[data-theme="minimal"] .mikron-calendar .ec-header .ec-col-head {
	padding: var(--space-sm) var(--space-xs);
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
	font-variant-numeric: tabular-nums;
}

html[data-theme="minimal"] .mikron-calendar .ec-header .ec-col-head.ec-today {
	color: var(--color-button-confirm-ink);
	font-weight: 600;
}

html[data-theme="minimal"][data-theme-variant="dark"] .mikron-calendar .ec-header .ec-col-head.ec-today {
	color: var(--color-border-highlight);
}

html[data-theme="minimal"] .mikron-calendar .ec-time-grid .ec-sidebar {
	box-sizing: border-box;
	width: 56px;
	min-width: 56px;
	padding-inline: 0 var(--space-sm);
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	line-height: 16px;
	font-variant-numeric: tabular-nums;
}

/* The now line: 2 px in the accent edge colour (the other themes: red). */
html[data-theme="minimal"] .mikron-calendar .ec-now-indicator {
	border-top-width: 2px;
}

/* An entry: the project colour as a 3 px edge at the left and a 12 % tint
   (a saved Mikron has no project colour in the calendar data: the
   secondary text); the time 600 and tabular, the project and the
   description in 12/16 px, the description in the secondary text. */
html[data-theme="minimal"] .mikron-calendar .ec-event:is(.mikron-calendar-saved, .mikron-calendar-draft-event) {
	--mikron-minimal-event: var(--mikron-event-project, var(--color-text-secondary));
	--ec-event-bg-color: color-mix(in srgb, var(--mikron-minimal-event) 12%, var(--color-ui-panel));
	--ec-event-text-color: var(--color-text-primary);
	border: 0;
	border-left: 3px solid var(--mikron-minimal-event);
	border-radius: var(--radius-sm);
	box-shadow: none;
	padding: 2px var(--space-3xs) 2px var(--space-2xs);
	font-size: var(--font-size-xs);
	line-height: 16px;
}

html[data-theme="minimal"] .mikron-calendar .ec-event:is(.mikron-calendar-saved, .mikron-calendar-draft-event):hover {
	--ec-event-bg-color: color-mix(in srgb, var(--mikron-minimal-event) 20%, var(--color-ui-panel));
}

html[data-theme="minimal"] .mikron-calendar .ec-event.mikron-calendar-draft-event.has-pale-marker::before {
	content: none;
}

/* An entry shows only whole lines (B8). The time, the codes and the
   description stand in one block (.mikron-calendar-event-lines), which is
   as high as the whole lines of 16 px that the body of the entry has room
   for. The block is a flex column that wraps: the time and the codes keep
   their height, and a part without room moves to a second column, which
   the block clips. The description takes the lines that are left after
   the time and the codes (UI-74). It is a size container, and its text
   ends with "…" at its last line (-webkit-line-clamp; a step of 16 px is
   one line, up to 12 lines, because -webkit-line-clamp takes no calculated
   count). A taller description has no limit for the count; the block cuts
   it after a whole line. The "…" ends only the description: the time and
   the codes are not in the clamped text. Where no line is left, the
   description does not show. A time shows only whole: the body of the
   entry is a size container, and its width decides which time it shows.
   - The range shows when it fits. The range of the library is 74.6 px
     wide in English ("12:00–14:00"), 81 px in French ("12:00 – 14:00")
     and 98.8 px in German ("12:00–14:00 Uhr"), in the 600 weight with
     tabular figures, so the range gives way to the start time under 75,
     82 and 99 px.
   - Under 66 px the codes, the description and the review status do not
     show either.
   - Under 35 px (the start time "12:00" is 34.3 px) or under one line of
     16 px in height (an entry of 15 or 20 minutes), the entry shows only
     the colour edge and the tint.
   The body is 9 px narrower than the entry (the 3 px edge and the padding
   of 4 and 2 px; a draft has 1 px of padding beside its 1 px dashed
   edge) and 4 px lower (a draft: 6 px, for its dashed edge). At
   1440 px two entries side by side in a week column are about 45 px wide,
   so their body (36 px) has room for the start time, also with a classic
   scrollbar. The title (the browser tooltip) and the aria-label of the
   entry carry the whole text (treetops.mikrons_calendar.js); the test
   minimal_calendar_times_show_only_whole of
   frontend_ui_phase4_mikron_test.js checks the widths. */
html[data-theme="minimal"] .mikron-calendar .ec-event:is(.mikron-calendar-saved, .mikron-calendar-draft-event) > .ec-event-body {
	flex-direction: column;
	min-width: 0;
	overflow: hidden;
	container: mikron-event / size;
}

html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-lines {
	display: flex;
	flex: none;
	flex-direction: column;
	flex-wrap: wrap;
	align-content: flex-start;
	box-sizing: border-box;
	width: 100%;
	height: round(down, 100cqh, 16px);
	overflow: hidden;
}

html[data-theme="minimal"] .mikron-calendar :is(.mikron-calendar-event-time, .mikron-calendar-event-title, .mikron-calendar-event-detail) {
	box-sizing: border-box;
	width: 100%;
	font-size: var(--font-size-xs);
	line-height: 16px;
	white-space: normal;
	text-overflow: clip;
}

html[data-theme="minimal"] .mikron-calendar :is(.mikron-calendar-event-time, .mikron-calendar-event-title) {
	flex: none;
	overflow: visible;
}

html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-time {
	font-weight: 600;
	font-variant-numeric: tabular-nums;
}

/* The parts of the time and the codes do not break inside; a long word of
   the description breaks rather than being cut at the edge. A project
   without a short name shows its name, which ends with an ellipsis when it
   is wider than the entry. */
html[data-theme="minimal"] .mikron-calendar :is(.mikron-calendar-event-time-range, .mikron-calendar-event-time-start, .mikron-calendar-event-code) {
	display: inline-block;
	max-width: 100%;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	vertical-align: top;
}

/* The project and the category code: two words 6 px apart without a
   separator; the second wraps under the first in a narrow entry. */
html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-title {
	display: flex;
	flex-wrap: wrap;
	column-gap: var(--space-xs);
}

/* The description fills the height that the time and the codes leave in
   the block (a multiple of 16 px). Its text (one inner span) is clamped
   by the container queries on mikron-detail below. */
html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-detail {
	flex: 1 1 0;
	min-height: 0;
	overflow: hidden;
	color: var(--color-text-secondary);
	overflow-wrap: break-word;
	container: mikron-detail / size;
}

html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-detail-text {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

/* The start time alone shows only in a narrow entry, instead of the
   range. */
html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-time-start {
	display: none;
}

@container mikron-event (width < 75px) {
	html[data-theme="minimal"]:not(:lang(de), :lang(fr)) .mikron-calendar .mikron-calendar-event-time-range {
		display: none;
	}

	html[data-theme="minimal"]:not(:lang(de), :lang(fr)) .mikron-calendar .mikron-calendar-event-time-start {
		display: inline-block;
	}
}

@container mikron-event (width < 82px) {
	html[data-theme="minimal"]:lang(fr) .mikron-calendar .mikron-calendar-event-time-range {
		display: none;
	}

	html[data-theme="minimal"]:lang(fr) .mikron-calendar .mikron-calendar-event-time-start {
		display: inline-block;
	}
}

@container mikron-event (width < 99px) {
	html[data-theme="minimal"]:lang(de) .mikron-calendar .mikron-calendar-event-time-range {
		display: none;
	}

	html[data-theme="minimal"]:lang(de) .mikron-calendar .mikron-calendar-event-time-start {
		display: inline-block;
	}
}

@container mikron-event (width < 66px) {
	html[data-theme="minimal"] .mikron-calendar :is(.mikron-calendar-event-title, .mikron-calendar-event-detail, .mikron-calendar-event-status) {
		display: none;
	}
}

@container mikron-detail (height >= 16px) {
	html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-detail-text {
		-webkit-line-clamp: 1;
	}
}

@container mikron-detail (height >= 32px) {
	html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-detail-text {
		-webkit-line-clamp: 2;
	}
}

@container mikron-detail (height >= 48px) {
	html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-detail-text {
		-webkit-line-clamp: 3;
	}
}

@container mikron-detail (height >= 64px) {
	html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-detail-text {
		-webkit-line-clamp: 4;
	}
}

@container mikron-detail (height >= 80px) {
	html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-detail-text {
		-webkit-line-clamp: 5;
	}
}

@container mikron-detail (height >= 96px) {
	html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-detail-text {
		-webkit-line-clamp: 6;
	}
}

@container mikron-detail (height >= 112px) {
	html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-detail-text {
		-webkit-line-clamp: 7;
	}
}

@container mikron-detail (height >= 128px) {
	html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-detail-text {
		-webkit-line-clamp: 8;
	}
}

@container mikron-detail (height >= 144px) {
	html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-detail-text {
		-webkit-line-clamp: 9;
	}
}

@container mikron-detail (height >= 160px) {
	html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-detail-text {
		-webkit-line-clamp: 10;
	}
}

@container mikron-detail (height >= 176px) {
	html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-detail-text {
		-webkit-line-clamp: 11;
	}
}

@container mikron-detail (height >= 192px) {
	html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-detail-text {
		-webkit-line-clamp: 12;
	}
}

@container mikron-detail (height >= 208px) {
	html[data-theme="minimal"] .mikron-calendar .mikron-calendar-event-detail-text {
		-webkit-line-clamp: none;
	}
}

@container mikron-event (width < 35px) or (height < 16px) {
	html[data-theme="minimal"] .mikron-calendar .ec-event-body > * {
		display: none;
	}
}

/* A draft: a dashed control edge (it is not saved yet). A draft that
   needs changes: the dashed edge in the warning colour. A draft that
   cannot be saved (a refusal of the server, an overlap): a 1 px error
   edge and an alert icon after the time. A running timer: the accent edge.
   The selected entry: the 2 px focus ring, 1 px away. */
html[data-theme="minimal"] .mikron-calendar .ec-event.mikron-calendar-draft-event {
	border-top: 1px dashed var(--color-control);
	border-right: 1px dashed var(--color-control);
	border-bottom: 1px dashed var(--color-control);
	padding-right: 1px;
}

html[data-theme="minimal"] .mikron-calendar .ec-event.mikron-calendar-draft-event.is-incomplete {
	border-top-color: var(--mikron-calendar-warning-border);
	border-right-color: var(--mikron-calendar-warning-border);
	border-bottom-color: var(--mikron-calendar-warning-border);
}

html[data-theme="minimal"] .mikron-calendar .ec-event.mikron-calendar-draft-event.is-failed {
	border-width: 0 0 0 3px;
	box-shadow: inset 0 0 0 1px var(--color-error-dark);
}

html[data-theme="minimal"] .mikron-calendar .ec-event.mikron-calendar-draft-event.is-failed .mikron-calendar-event-time::after {
	content: "";
	display: inline-block;
	width: 12px;
	height: 12px;
	margin-left: var(--space-2xs);
	background-color: var(--color-error-dark);
	-webkit-mask: url(/icons/ui/alert-circle.svg) center / 12px no-repeat;
	mask: url(/icons/ui/alert-circle.svg) center / 12px no-repeat;
	vertical-align: -1px;
}

html[data-theme="minimal"] .mikron-calendar .ec-event.mikron-calendar-draft-event.is-running {
	--mikron-minimal-event: var(--color-border-highlight);
}

html[data-theme="minimal"] .mikron-calendar .ec-event.mikron-calendar-draft-event.is-focused,
html[data-theme="minimal"] .mikron-calendar .ec-event:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 1px;
}

/* The totals row under the grid: a 36 px row on the sunken surface,
   13 px 600 and tabular; it closes the frame. A day that reaches or misses
   its hours keeps the coloured top edge of the other themes. The week
   total under it: 14 px 600, without a box. */
html[data-theme="minimal"] .mikron-calendar-foot {
	border: 1px solid var(--color-ui-panel-border);
	border-radius: 0 0 var(--radius-lg) var(--radius-lg);
	background: var(--color-background-secondary);
}

html[data-theme="minimal"] .mikron-calendar-foot-day {
	min-height: 36px;
	padding: var(--space-sm) var(--space-3xs);
	border-top: 2px solid transparent;
	border-right: 1px solid var(--color-ui-panel-border);
	background: transparent;
	color: var(--color-text-primary);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

html[data-theme="minimal"] .mikron-calendar-foot-day:first-child {
	border-left: 1px solid var(--color-ui-panel-border);
}

html[data-theme="minimal"] .mikron-calendar-foot-day:last-child {
	border-right: 0;
}

html[data-theme="minimal"] .mikron-calendar-foot-total {
	font-size: var(--font-size-sm);
	font-weight: 600;
	line-height: 18px;
}

html[data-theme="minimal"] .mikron-calendar-foot-day:is(.is-reached, .is-short) {
	background: transparent;
}

html[data-theme="minimal"] .mikron-calendar-week-total {
	margin-top: 0;
	padding: var(--space-lg) 0 0;
	border: 0;
	background: transparent;
	font-size: var(--font-size-md);
	font-weight: 600;
	line-height: 20px;
}

html[data-theme="minimal"] .mikron-calendar-today {
	margin-top: var(--space-xl);
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

/* "Add entry" over the pane is the secondary button of family 23 with the
   plus icon (.button.is-secondary.has-icon). */
html[data-theme="minimal"] .mikron-calendar-side-actions {
	padding: 0;
}

/* The pane "Entry details": a box of family 15 with a head, the quiet
   sentence or the card of the draft, and under the card the footer of the
   pane (family 27): "Discard draft" (the quiet danger button of family 23,
   with the trash icon) at the left and "Apply" (secondary) at the right. */
html[data-theme="minimal"] .mikron-calendar-pane {
	box-sizing: border-box;
	border: 1px solid var(--color-ui-panel-border);
}

html[data-theme="minimal"] .mikron-calendar-pane > h3 {
	display: flex;
	align-items: center;
	gap: var(--space-sm);
	margin: 0;
	padding: var(--space-lg) var(--space-xl);
	border-bottom: 1px solid var(--color-ui-panel-border);
	font-size: var(--font-size-md);
	font-weight: 600;
	line-height: 20px;
}

html[data-theme="minimal"] .mikron-calendar-pane .mikron-entry-badge {
	position: static;
}

html[data-theme="minimal"] .mikron-calendar-pane > :is(.mikron-calendar-hint, .mikron-calendar-untimed) {
	margin: 0;
	padding: var(--space-xl);
	color: var(--color-text-secondary);
	font-size: var(--font-size-md);
	line-height: 20px;
}

html[data-theme="minimal"] .mikron-calendar-draft {
	display: flex;
	flex-direction: column;
}

html[data-theme="minimal"] .mikron-calendar-draft > :is(.mikron-calendar-draft-messages:not(:empty), .mikron-timer-status) {
	margin: var(--space-xl) var(--space-xl) 0;
}

html[data-theme="minimal"] .mikron-calendar-draft > .mikron_body {
	display: flex;
	flex-direction: column;
	gap: var(--space-sm);
	padding: var(--space-xl);
	border-radius: 0;
	background: transparent;
	box-shadow: none;
	--caption-width: 56px;
}

/* The footer of the pane in the application: the draft (.mikron-calendar-draft)
   holds it under its card. The 12 x 16 px padding of a box foot (the sheet's
   rule names the footer as a child of the pane). */
html[data-theme="minimal"] .mikron-calendar-draft > .mikron-calendar-pane-foot {
	padding: var(--space-lg) var(--space-xl);
}

/* The draft bar: Clear drafts before Save (family 26). */
html[data-theme="minimal"] .mikron-calendar-savebar > .mikron-entry-actions {
	gap: var(--space-sm);
}

/* The question of "Clear drafts" (family 30) opens after the actions of the
   form's foot and of the draft bar, both wrapping rows. As a 640 px item it
   fitted beside the actions and pushed "Clear drafts" and "Save" to the left
   (C1). It takes a line of its own under the row instead: the 100 % basis
   and the margin do not fit beside another item, and the item shrinks to
   640 px at the right, under its trigger (the full width under 640 px). The
   actions keep their place. */
html[data-theme="minimal"] :is(.mikron-foot, .mikron-calendar-savebar) > .inline-confirm {
	flex: 0 1 100%;
	max-width: none;
	margin: 0 0 0 max(0px, 100% - 640px);
}

/*------------------------------
=28 MODALS (frame shared with Skeleton)
Replaces: .modalContainer, .modalDialog and its width rules, .modalHeader,
.modalBody, .modalAside, .modalFooter, .modalSubmit, .modal-columns,
.modalDialog-columns, .modalDialog-wide, .modal-ticket-dialog widths,
.resource-box-modal (style.css =MODAL, =UI: WIZARDS, the ticket card).
------------------------------*/

/* The five dialog widths are tokens (=TOKENS): S, M, L, XL and Full. The
   views write L as .modalDialog-columns (master's two-column dialogs) or
   .modalDialog-large, and XL as .modalDialog-wide or .modalDialog-xl; the
   new names have no rule in the other themes, so the views keep their
   width there. */

/* The scrim of the Minimal themes (the page stays visible behind it);
   the dialog is centred and keeps 24 px to the window edges. */
html[data-theme="minimal"] .modalContainer {
	position: fixed;
	inset: 0;
	z-index: 1000;
	display: flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	padding: var(--space-3xl);
	overflow: hidden;
	background: var(--color-scrim);
	backdrop-filter: blur(2px);
	/* treetops.modal.js sets the opacity (1 when open, 0 when it closes). */
	transition: opacity var(--motion-base) ease;
}

/* The empty spacer divs of the views take no room. */
html[data-theme="minimal"] .modalContainer > div:empty {
	display: none;
}

/* The frame: the panel surface, 12 px corners, the large shadow. The
   header and the footer stay; the body scrolls when the dialog is taller
   than the window. */
html[data-theme="minimal"] .modalDialog {
	position: relative;
	display: flex;
	flex: 0 1 var(--dialog-s);
	flex-direction: column;
	box-sizing: border-box;
	width: var(--dialog-s);
	max-width: 100%;
	max-height: 100%;
	margin: 0;
	overflow: hidden;
	border-radius: var(--radius-2xl);
	background: var(--color-ui-panel);
	box-shadow: var(--shadow-lg);
	color: var(--color-text-primary);
	animation: dialog-in var(--motion-base) var(--ease-standard);
}

html[data-theme="minimal"] .modalDialog.modalDialog-medium { flex-basis: var(--dialog-m); width: var(--dialog-m); }
html[data-theme="minimal"] .modalDialog.modalDialog-columns,
html[data-theme="minimal"] .modalDialog.modalDialog-large,
html[data-theme="minimal"] .modalDialog.modal-ticket-dialog { flex-basis: var(--dialog-l); width: var(--dialog-l); max-width: 100%; }
html[data-theme="minimal"] .modalDialog.modalDialog-wide,
html[data-theme="minimal"] .modalDialog.modalDialog-xl { flex-basis: var(--dialog-xl); width: var(--dialog-xl); max-width: 100%; }
html[data-theme="minimal"] .modalDialog.modalDialog-full { flex-basis: var(--dialog-full); width: var(--dialog-full); }

@keyframes dialog-in {
	from { opacity: 0; transform: translateY(8px); }
}

/* The header: the title (18/26, 600, left-aligned) and an optional subtitle
   (13 px, the secondary text); the 32 px close button in the top right
   corner. The title keeps 56 px free at the right, so it never runs under
   the close button. */
html[data-theme="minimal"] .modalHeader {
	flex: 0 0 auto;
	min-height: 0;
	margin: 0;
	padding: var(--space-3xl) 56px var(--space-lg) var(--space-3xl);
	border: 0;
	border-radius: 0;
	background: transparent;
}

html[data-theme="minimal"] .modalHeader > h2,
html[data-theme="minimal"] .modalHeader > h3 {
	margin: 0;
	padding: 0;
	font-size: var(--font-size-xl);
	font-weight: 600;
	line-height: 26px;
	letter-spacing: -.01em;
	text-align: left;
	overflow-wrap: anywhere;
}

/* The subtitle under the title. The views write it as .sender (the member
   of a Mikron), .member-lifecycle-subtitle (the member of the account
   lifecycle) and .member-modal-subtitle (the email of a member); this rule
   replaces their margins, size and centring of style.css. */
html[data-theme="minimal"] .modalHeader > :is(.modal-subtitle, .sender, .member-lifecycle-subtitle, .member-modal-subtitle) {
	margin: var(--space-3xs) 0 0;
	padding: 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-style: normal;
	line-height: 18px;
	text-align: left;
}

html[data-theme="minimal"] .modalDialog > .btnClose,
html[data-theme="minimal"] .modalType > .btnClose,
html[data-theme="minimal"] .modalDialog > .tabs .btnClose {
	position: absolute;
	top: var(--space-lg);
	right: var(--space-lg);
	z-index: 2;
}

/* The body: 24 px at the sides, the fields 16 px apart. It scrolls with a
   visible thin thumb. The body is the containing block of its out-of-flow parts (the field captions and the
   help buttons beside the fields), so that they scroll with their fields
   (UX-249). */
html[data-theme="minimal"] .modalBody {
	position: relative;
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	gap: var(--space-xl);
	min-height: 0;
	margin: 0;
	padding: var(--space-2xs) var(--space-3xl) var(--space-3xl);
	overflow-y: auto;
	border: 0;
	border-radius: 0;
	background: transparent;
	font-size: var(--font-size-md);
	line-height: 20px;
	scrollbar-width: thin;
	scrollbar-color: var(--color-background-quaternary) transparent;
}

html[data-theme="minimal"] .modalBody > p {
	margin: 0;
}

/* A section inside the body: a 14 px heading, 8 px above its content and
   24 px below the previous section. */
html[data-theme="minimal"] .modal-section {
	display: flex;
	flex-direction: column;
	gap: var(--space-sm);
	min-width: 0;
}

html[data-theme="minimal"] .modal-section + .modal-section {
	margin-top: var(--space-sm);
}

html[data-theme="minimal"] .modal-section > h4 {
	margin: 0;
	padding: 0;
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	font-weight: 600;
	line-height: 20px;
}

/* A form with an aside (L): the form takes the free width, the aside
   240 px at the right with a hairline between; under 720 px dialog width
   the aside follows the form. */
html[data-theme="minimal"] .modal-columns,
html[data-theme="minimal"] .modal-split {
	display: flex;
	flex-wrap: wrap;
	gap: var(--space-3xl);
	min-width: 0;
}

html[data-theme="minimal"] .modal-columns > div,
html[data-theme="minimal"] .modal-split > .modal-split-main {
	flex: 1 1 360px;
	min-width: 0;
}

html[data-theme="minimal"] .modalAside,
html[data-theme="minimal"] .modal-split > .modal-split-aside {
	display: flex;
	flex: 0 1 240px;
	flex-direction: column;
	gap: var(--space-lg);
	min-width: 200px;
	padding: 0 0 0 var(--space-3xl);
	border-left: 1px solid var(--color-ui-panel-border);
}

/* A group heading of the aside: 12 px, 600, sentence case, like the other
   group headings ("Project scope", "Tasks"); no capitals and no tracking. */
html[data-theme="minimal"] .modalAside > h3,
html[data-theme="minimal"] .modal-aside-title {
	margin: 0;
	padding: 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-weight: 600;
	line-height: 16px;
	letter-spacing: 0;
	text-transform: none;
}

html[data-theme="minimal"] .modalAside .button,
html[data-theme="minimal"] .modalAside .button_standard {
	justify-content: flex-start;
	width: 100%;
}

/* The footer: a hairline above, 16 px by 24 px; the actions at the right
   (Cancel, then the primary button), a destructive quiet button or a
   checkbox at the left. It stays visible while the body scrolls. */
html[data-theme="minimal"] .modalFooter,
html[data-theme="minimal"] .mikron-calendar-pane-foot {
	display: flex;
	flex: 0 0 auto;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-sm) var(--space-sm);
	margin: 0;
	justify-content: flex-end;
	padding: var(--space-xl) var(--space-3xl);
	border-top: 1px solid var(--color-ui-panel-border);
	background: inherit;
	text-align: left;
}

html[data-theme="minimal"] :is(.modalFooter, .mikron-calendar-pane-foot) > .modal-footer-start {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-sm) var(--space-lg);
	margin-right: auto;
	min-width: 0;
}

/* Cancel and the main action stay together on one row. The footer places
   its children from the right, the last one first, and wraps upwards: when
   the start group does not fit beside the buttons, it takes the row above,
   at the left. The order values of style.css (.modalFooter > *) reverse
   the source order for this; the focus order stays the source order. */
html[data-theme="minimal"] .modalFooter {
	flex-direction: row-reverse;
	flex-wrap: wrap-reverse;
	align-items: start;
	justify-content: flex-start;
}

/* openInlineConfirmation opens the delete question after Delete, inside
   the start group: the group then takes the full row above Cancel and the
   main action, and the question the full width of the group. The question
   takes the place of Delete, so that the footer grows by about one
   question; closeInlineConfirmation removes the question before it
   returns the focus to Delete. */
html[data-theme="minimal"] .modalFooter > .modal-footer-start:has(> .inline-confirm) {
	flex: 1 1 100%;
}

html[data-theme="minimal"] .modalFooter > .modal-footer-start:has(> .inline-confirm) > :not(.inline-confirm) {
	display: none;
}

html[data-theme="minimal"] .modalFooter > .modal-footer-start > .inline-confirm {
	flex: 1 1 100%;
	max-width: none;
	margin: 0;
}

html[data-theme="minimal"] .modalSubmit {
	max-width: none;
	margin: 0;
}

/* A box inside a dialog (.resource-box-modal: a picker list): the box of
   family 15 without a head (the dialog title names it). Its list fills the
   box of style.css and then scrolls (Treetops decision UI-78). */
html[data-theme="minimal"] .resource-box-modal {
	box-shadow: none;
}

html[data-theme="minimal"] .resource-box-modal .resourcelist-resource {
	cursor: pointer;
}

html[data-theme="minimal"] .resource-box-modal .resourcelist-resource > .resource-box-item-container {
	align-items: center;
}

/* The ⊕ copy button of the Mikron edit dialog (UI-47) is a 32 px bordered
   icon button (family 24) with the plus-circle icon, named "Copy Mikron";
   it stands between Save and Delete (Delete at the left, then ⊕, Cancel
   and Save at the right). The copy that opens beside the dialog has no copy
   button (copyMikron() removes it). */
html[data-theme="minimal"] .modalFooter > .mikron-copyarrow,
html[data-theme="minimal"] .mikron-calendar-pane-foot > .mikron-copyarrow {
	flex: 0 0 32px;
}

html[data-theme="minimal"] .modalFooter > .mikron-copyarrow::after,
html[data-theme="minimal"] .mikron-calendar-pane-foot > .mikron-copyarrow::after {
	content: none;
}

/* Stacked dialogs: a dialog opened from a dialog stands above it with its
   own scrim (the lower dialog stays visible, dimmed); Escape closes the top
   dialog only and the focus returns to the button that opened it. The copy
   of a Mikron opens beside its dialog (UI-47): from 900 px (in Treetops
   the Mikron pair from 760 px) the two S dialogs stand side by side, 16 px apart. */
html[data-theme="minimal"] .modalContainer + .modalContainer {
	z-index: 1010;
	background: var(--color-scrim-light);
	backdrop-filter: none;
}

html[data-theme="minimal"] .modal-pair {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: flex-start;
	gap: var(--space-xl);
	max-height: 100%;
}

/* Loading: the body shows three skeleton lines of family 7 until the
   content is in. */
html[data-theme="minimal"] .modalBody.is-loading::before {
	content: "";
	display: block;
	height: 72px;
	border-radius: var(--radius-sm);
	background: repeating-linear-gradient(to bottom, var(--color-skeleton) 0 12px, transparent 12px 24px);
}

@media (max-width: 1199px) {
	html[data-theme="minimal"] .modalContainer {
		padding: var(--space-xl);
	}
}

/* Phones: the dialog fills the window but 8 px (on the sheet; the views:
   see 28 continued); the footer stays at the bottom of the window, its
   buttons share the width. */
@media (max-width: 599px) {
	html[data-theme="minimal"] .modalContainer {
		align-items: stretch;
		padding: var(--space-sm);
	}

	html[data-theme="minimal"] .modalDialog,
	html[data-theme="minimal"] .modalDialog:is(.modalDialog-medium, .modalDialog-columns, .modalDialog-large, .modal-ticket-dialog, .modalDialog-wide, .modalDialog-xl, .modalDialog-full) {
		flex: 1 1 auto;
		width: auto;
		max-height: 100%;
	}

	html[data-theme="minimal"] .modalHeader {
		padding: var(--space-xl) 52px var(--space-sm) var(--space-xl);
	}

	html[data-theme="minimal"] .modalBody {
		padding: var(--space-2xs) var(--space-xl) var(--space-xl);
	}

	html[data-theme="minimal"] .modalAside,
	html[data-theme="minimal"] .modal-split > .modal-split-aside {
		flex: 1 1 100%;
		padding: var(--space-xl) 0 0;
		border-top: 1px solid var(--color-ui-panel-border);
		border-left: 0;
	}

	html[data-theme="minimal"] :is(.modalFooter, .mikron-calendar-pane-foot) {
		padding: var(--space-lg) var(--space-xl);
	}

	html[data-theme="minimal"] :is(.modalFooter, .mikron-calendar-pane-foot) > .modal-footer-start {
		flex: 1 1 100%;
	}

	html[data-theme="minimal"] :is(.modalFooter, .mikron-calendar-pane-foot) > :is(.button_standard, .button):not(.button_quiet, .is-quiet) {
		flex: 1 1 0;
	}

	/* A label longer than half the row breaks into two lines. */
	html[data-theme="minimal"] .modalFooter > :is(.button_standard, .button):not(.button_quiet, .is-quiet) {
		height: auto;
		min-height: var(--control-height);
		padding-top: var(--space-xs);
		padding-bottom: var(--space-xs);
		white-space: normal;
	}
}

@media (prefers-reduced-motion: reduce) {
	html[data-theme="minimal"] .modalContainer {
		transition: none;
	}

	html[data-theme="minimal"] .modalDialog {
		animation: none;
	}
}

/*------------------------------
=28 (continued) THE MODAL FRAME IN THE APPLICATION
The rules that the dialog views need beside the frame above. The sheet
writes the footer after the body; the views write it at the end of the
dialog's form, inside the body, because treetops.modal.js submits a dialog
form through its .modal-post button, which therefore stays in the form.
The close button stands in the header; master's position rule and the
place of family 24 put it in the top right corner of the dialog.
------------------------------*/

/* The footer stands at the end of the form and scrolls with the body
   (UI-70: no button row floats over the content). Its hairline and
   surface reach the sides of the dialog. The body has no padding under
   it; the 24 px above the footer are its margin (a field's margin
   collapses into it). */
html[data-theme="minimal"] .modalBody:has(.modalFooter) {
	padding-bottom: 0;
}

html[data-theme="minimal"] .modalBody .modalFooter {
	margin: var(--space-3xl) calc(-1 * var(--space-3xl)) 0;
	background: var(--color-ui-panel);
}

/* A footer that is a child of the body has the 16 px gap of the body above
   it; the margin adds the rest of the 24 px. */
html[data-theme="minimal"] .modalBody > .modalFooter {
	margin-top: var(--space-sm);
}

/* The footer buttons have the width of their label. style.css gives the
   buttons of the Mikron footer 100 px (.mikron-edit-actions
   .button_standard); Delete stands in the start group, so the rule takes
   every button of the footer, not only its children. */
html[data-theme="minimal"] .mikron-edit-actions .button_standard {
	width: auto;
}

/* A form or a panel between the dialog and its body (the filter dialogs,
   the expense and tax dialogs) passes the height on, so that the body
   scrolls between the header and the footer. A panel with an aside beside
   its body (the Processing aside of the expense dialog, UX-160, UI-82)
   keeps the row of style.css; its dialog scrolls as a whole, as in the
   classic themes. */
html[data-theme="minimal"] .modalDialog > :is(form, .modalType):has(> .modalBody):not(:has(> .modalBody + aside)) {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	min-width: 0;
	min-height: 0;
}

/* A dialog whose body stands deeper (the tabbed dialogs of family 29, the
   bill preview) or beside an aside scrolls as a whole, the footer at its
   end. */
html[data-theme="minimal"] .modalDialog:not(:has(> .modalBody, > :is(form, .modalType) > .modalBody), .modal-ticket-dialog),
html[data-theme="minimal"] .modalDialog:has(> :is(form, .modalType) > .modalBody + aside) {
	overflow-y: auto;
	scrollbar-width: thin;
	scrollbar-color: var(--color-background-quaternary) transparent;
}

html[data-theme="minimal"] .modalDialog:not(:has(> .modalBody, > :is(form, .modalType) > .modalBody), .modal-ticket-dialog) .modalBody {
	flex: 0 0 auto;
	overflow: visible;
}

/* The body beside an aside does not scroll in a box of its own; the dialog
   scrolls. Its flex values are those of style.css (a row). */
html[data-theme="minimal"] .modalDialog > :is(form, .modalType) > .modalBody:has(+ aside) {
	overflow: visible;
}

/* The copy of a Mikron opens beside its dialog (UI-47); the views write
   the two dialogs into one container (no .modal-pair). From 900 px they
   stand side by side, 16 px apart (in Treetops the Mikron pair from 760 px,
   rule =26 (continued) of its minimal.css); below, the copy stands under its
   dialog, in the source order, so that the reading and focus order are
   the visual order (copyMikron scrolls the copy into view). */
html[data-theme="minimal"] .modalContainer:has(> .modalDialog + .modalDialog) {
	flex-wrap: wrap;
	align-content: center;
	gap: var(--space-xl);
	overflow-y: auto;
}

html[data-theme="minimal"] .modalDialog.mikron-edit-dialog + .modalDialog.mikron-edit-dialog {
	margin: 0;
}

@media (max-width: 899px) {
	html[data-theme="minimal"] .modalContainer:has(> .modalDialog + .modalDialog) {
		flex-direction: column;
		flex-wrap: nowrap;
		align-items: center;
		justify-content: flex-start;
	}

	html[data-theme="minimal"] .modalContainer:has(> .modalDialog + .modalDialog) > .modalDialog {
		flex: 0 0 auto;
		width: 100%;
		max-height: none;
		margin: 0;
	}
}

/* A field of the views with a help button beside it (.right-field-button,
   placed after the field) leaves 32 px for the 24 px button, so that the
   button stays inside the body, also with the 16 px padding of a phone. */
html[data-theme="minimal"] .modalBody :is(.organization-input, .organization-input-small, label):has(+ .right-field-button) {
	width: calc(100% - 32px);
}

/* The project dialog (L): the form and the box of ticket labels beside it,
   24 px apart; the box follows the form when the dialog is narrow. */
html[data-theme="minimal"] .project-modal-columns {
	display: flex;
	flex-wrap: wrap;
	gap: var(--space-3xl);
}

html[data-theme="minimal"] .project-modal-form {
	flex: 1 1 360px;
	min-width: 0;
}

html[data-theme="minimal"] .project-modal-aside {
	flex: 1 1 280px;
	min-width: 0;
}

/* The bill preview shows the paper of the bill: the width of the scaled
   paper and the padding of style.css (C26: one whole page fits the window;
   treetops.bills.js sets the scale). A bill of more pages scrolls in the
   dialog (family 28: a dialog whose body stands deeper scrolls as a whole). */
html[data-theme="minimal"] .modalDialog.bill-preview-dialog {
	flex: 0 1 auto;
	width: 100%;
	max-width: min(calc(var(--bill-paper-width) * var(--bill-preview-scale, 1) + 80px), 100%);
	padding: var(--space-5xl);
	background: var(--color-background-secondary);
}

@media (max-width: 599px) {
	/* The footer stands at the end of the form inside the body, so it
	   cannot reach the bottom of a dialog that fills the window. A dialog
	   of the views therefore has the height of its content (at most the
	   window, then the body scrolls, and the footer with it).
	   The Mikron dialog and its copy keep their heights; the container
	   scrolls. */
	html[data-theme="minimal"] .modalContainer:has(.modalBody .modalFooter):not(:has(> .modalDialog + .modalDialog)) {
		align-items: center;
	}

	html[data-theme="minimal"] .modalContainer:has(.modalBody .modalFooter):not(:has(> .modalDialog + .modalDialog)) > .modalDialog {
		flex: 1 1 auto;
		max-height: 100%;
	}

	html[data-theme="minimal"] .modalBody .modalFooter {
		margin-right: calc(-1 * var(--space-xl));
		margin-left: calc(-1 * var(--space-xl));
	}

	/* The preview has the height of its scaled paper. */
	html[data-theme="minimal"] .modalDialog.bill-preview-dialog {
		align-self: center;
		padding: var(--space-sm);
	}
}

/*------------------------------
=28 MODALS: THE TICKET DIALOG
The ticket dialog of family 28 (rollout job 4), in the frame above.
The layout of the dialog is in style.css (=TICKETS: MODAL) and serves
every theme (UI-63); this section gives it the colours, borders and type of
the Minimal themes.
------------------------------*/

/* The ticket dialog and the Mikron dialog of "Ticket to Mikron" (UX-143, UI-78).
   They have the layout of the other themes (style.css, =TICKETS: MODAL): side
   by side from 760 px, the Mikron dialog 360 px wide, and below 760 px one
   under the other, 360 px at most and centred. The rules of the pair of the
   copy (28 (continued), shared with Skeleton) wrap the pair and stack it
   below 900 px at the full width; the rules below, of the same specificity
   and later in the file, take the ticket pair back to that layout. */
html[data-theme="minimal"] .modalContainer:has(> .modal-ticket-dialog ~ .modalDialog) {
	flex-wrap: nowrap;
	overflow-y: auto;
}

@media (min-width: 760px) and (max-width: 899px) {
	html[data-theme="minimal"] .modalContainer:has(> .modal-ticket-dialog ~ .modalDialog) {
		flex-direction: row;
		align-items: center;
		justify-content: center;
	}

	html[data-theme="minimal"] .modalContainer:has(> .modal-ticket-dialog ~ .modalDialog) > .modal-ticket-dialog {
		flex: 0 1 var(--dialog-l);
		width: var(--dialog-l);
		max-height: 100%;
	}

	html[data-theme="minimal"] .modalContainer:has(> .modal-ticket-dialog ~ .modalDialog) > .modalDialog:not(.modal-ticket-dialog) {
		flex: 0 0 360px;
		width: 360px;
		max-height: 100%;
	}
}

@media (max-width: 759px) {
	html[data-theme="minimal"] .modalContainer:has(> .modal-ticket-dialog ~ .modalDialog) > .modalDialog:not(.modal-ticket-dialog) {
		width: min(360px, 100%);
	}
}

/* The ticket dialog (L): the markup of tickets/modal_ticket_edit.erb and
   its partials sets the layout (style.css, =TICKETS: MODAL): the face with
   the "Title" caption, Description, Project, Task, Assignment, the scales
   and the chip lists; the aside with Add, Actions, Small change with its
   hint, Save and Delete; the record line with the Textile quick reference
   link; the discussion. There is no footer strip: Save is in the aside,
   and the whole content scrolls inside the frame. */
html[data-theme="minimal"] .modal-ticket-dialog > .modalType {
	position: relative;
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	min-height: 0;
	overflow-y: auto;
	scrollbar-width: thin;
	scrollbar-color: var(--color-background-quaternary) transparent;
}

/* The captions: the field caption of family 25 ("Title", UI-21). */
html[data-theme="minimal"] .modal-ticket-face .title-field > span,
html[data-theme="minimal"] .modal-ticket-face .modalBody > .field-caption,
html[data-theme="minimal"] .modal-ticket-resource-container :is(.ticket-assignment-field, .ticket-modal-field) > span:first-child {
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
}

/* The title is an editable heading: the field has the box, the font and
   the line height of the heading, so a click does not move it (UI-37);
   hover shows the hover surface, the focus the accent edge. */
html[data-theme="minimal"] .modal-ticket-dialog .title-text {
	display: block;
	box-sizing: border-box;
	width: calc(100% + var(--space-sm));
	min-height: 34px;
	margin: 0 0 0 calc(var(--space-sm) * -1);
	padding: var(--space-2xs) var(--space-sm);
	border: 1px solid transparent;
	border-radius: var(--radius-md);
	outline: none;
	background: transparent;
	box-shadow: none;
	color: var(--color-text-primary);
	font: 600 var(--font-size-xl)/26px var(--font-ui-family);
	letter-spacing: -.01em;
	resize: none;
}

html[data-theme="minimal"] .modal-ticket-dialog .title-text:hover {
	background: var(--color-ui-hover);
}

html[data-theme="minimal"] .modal-ticket-dialog .title-text:focus {
	border-color: var(--color-border-highlight);
	outline: none;
	box-shadow: inset 0 0 0 1px var(--color-border-highlight);
	background: var(--color-field);
}

/* The body has no surface of its own. */
html[data-theme="minimal"] .modal-ticket-face .modalBody {
	border: 0;
	background: transparent;
}

/* The description: the rendered text in the box of a field, so it reads
   as editable; the text area has the same box (UI-37). An empty
   description shows its prompt in the placeholder colour. */
html[data-theme="minimal"] .modal-ticket-face .modalBody > :is(.markupresult, .modal-description) {
	padding: var(--space-sm) var(--space-md);
	border: 1px solid var(--color-control);
	border-radius: var(--radius-md);
	background: var(--color-field);
	font: inherit;
	font-size: var(--font-size-md);
	line-height: 20px;
	cursor: text;
}

html[data-theme="minimal"] .modal-ticket-face .modalBody > .markupresult > :first-child { margin-top: 0; }
html[data-theme="minimal"] .modal-ticket-face .modalBody > .markupresult > :last-child { margin-bottom: 0; }

html[data-theme="minimal"] .modal-ticket-face .modalBody > .markupresult:hover {
	border-color: var(--color-text-secondary);
}

html[data-theme="minimal"] .modal-ticket-face .modalBody > .modal-description:focus {
	border-color: var(--color-border-highlight);
	outline: none;
	box-shadow: inset 0 0 0 1px var(--color-border-highlight);
}

html[data-theme="minimal"] .modal-ticket-face .modalBody > .markupresult:has(> p:only-child > em:only-child) {
	color: var(--color-placeholder);
}

/* The fields of the dialog are the 36 px fields of family 25 (the view
   writes the compact class); a select gets the chevron of family 25 from
   its wrapper (the control span of Project, Task and Assignment, the field
   label of a scale). */
html[data-theme="minimal"] .modal-ticket-resource-container :is(.ticket-assignment-field, .ticket-modal-field) :is(select, input) {
	height: var(--field-height);
	padding-left: var(--space-lg);
}

html[data-theme="minimal"] .modal-ticket-resource-container :is(.ticket-assignment-control, .ticket-modal-field):has(> select)::after {
	content: "";
	position: absolute;
	right: var(--space-lg);
	bottom: 10px;
	width: 16px;
	height: 16px;
	background-color: var(--color-text-secondary);
	-webkit-mask: url(/icons/ui/chevron-down.svg) center / 16px no-repeat;
	mask: url(/icons/ui/chevron-down.svg) center / 16px no-repeat;
	pointer-events: none;
}

/* The member chips have no avatar (the markup of the dialog), so they
   start with the 12 px inner space. */
html[data-theme="minimal"] .modal-ticket-face .modal-ticket-preliminary-resource.preliminary-member {
	padding-left: var(--space-md);
}

/* The aside has no edge of its own: the face draws the hairline. */
html[data-theme="minimal"] .modal-ticket-resource-container > .modalAside {
	border-left: 0;
}

/* An aside button is the secondary button of family 23 (32 px, a 16 px
   line icon, the label at the left) at the full aside width. The view's
   inner button covers the box, so the whole box is the target; its focus
   ring is the ring of the box. */
html[data-theme="minimal"] .modal-ticket-resource-container .modalAsideButton {
	position: relative;
	display: flex;
	align-items: center;
	gap: var(--space-sm);
	min-height: var(--control-height);
	padding: 0 var(--space-md);
	border: 1px solid var(--color-button-edge);
	border-radius: var(--radius-md);
	background: var(--color-ui-panel);
	box-shadow: none;
	color: var(--color-text-primary);
	font: inherit;
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
	text-align: left;
	cursor: pointer;
}

html[data-theme="minimal"] .modal-ticket-resource-container .modalAsideButton:hover {
	border-color: var(--color-button-edge-hover);
	background: var(--color-ui-hover);
}

html[data-theme="minimal"] .modal-ticket-resource-container .modalAsideButton:is(:focus-visible, :has(> .modal-ticket-asidebutton:focus-visible)) {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
}

html[data-theme="minimal"] .modal-ticket-resource-container .modalAsideButton::before {
	content: "";
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	background-color: var(--color-text-secondary);
	-webkit-mask: var(--aside-icon, url(/icons/ui/plus.svg)) center / 16px no-repeat;
	mask: var(--aside-icon, url(/icons/ui/plus.svg)) center / 16px no-repeat;
}

html[data-theme="minimal"] .modal-ticket-resource-container .modalAsideButton:has(> [data-target="members"]) { --aside-icon: url(/icons/ui/user-plus.svg); }
html[data-theme="minimal"] .modal-ticket-resource-container .modalAsideButton:has(> [data-target="labels"]) { --aside-icon: url(/icons/ui/tag.svg); }
html[data-theme="minimal"] .modal-ticket-resource-container .modalAsideButton:has(> .ticket-attachments-upload-trigger) { --aside-icon: url(/icons/ui/paperclip.svg); }
html[data-theme="minimal"] .modal-ticket-resource-container .modalAsideButton:has(> .togglecomplete) { --aside-icon: url(/icons/ui/check-circle.svg); }
html[data-theme="minimal"] .modal-ticket-resource-container .modalAsideButton.ticket-to-mikron { --aside-icon: url(/icons/ui/clock.svg); }

html[data-theme="minimal"] .modal-ticket-resource-container .modalAsideButton > .modal-ticket-asidebutton {
	position: absolute;
	inset: 0;
	width: auto;
	height: auto;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: inherit;
	outline: none;
	background: transparent;
	cursor: pointer;
}

html[data-theme="minimal"] .modal-ticket-resource-container .ticket-attachment-limit {
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	line-height: 16px;
}

/* The foot of the aside: the full-width Save (the wide primary button,
   36 px), Small change with its hint (indented to the text of the
   checkbox), Delete. */
html[data-theme="minimal"] .modal-ticket-resource-container .ticket-aside-commit > .resource-small-change {
	min-height: 24px;
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	font-weight: 500;
	line-height: 20px;
	cursor: pointer;
}

html[data-theme="minimal"] .modal-ticket-resource-container .ticket-aside-commit > .ticket-small-change-hint {
	margin-left: 26px;
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	line-height: 16px;
}

html[data-theme="minimal"] .modal-ticket-resource-container .ticket-aside-save > .button_standard {
	justify-content: center;
	min-height: var(--field-height);
	height: var(--field-height);
	font-size: var(--font-size-md);
}

/* Delete is the quiet danger button of family 23 with the trash icon. */
html[data-theme="minimal"] .modal-ticket-resource-container #deleteresource .resource_delete > .button_red {
	display: inline-flex;
	align-items: center;
	gap: var(--space-sm);
	width: auto;
	min-height: var(--control-height);
	margin: var(--space-xs) 0 0;
	padding: 0 var(--space-md);
	border-color: transparent;
	background: transparent;
	box-shadow: none;
	color: var(--color-action-danger-ink);
	font-size: var(--font-size-sm);
	font-weight: 500;
	text-align: left;
}

html[data-theme="minimal"] .modal-ticket-resource-container #deleteresource .resource_delete > .button_red:hover {
	background: var(--color-danger-hover);
	color: var(--color-action-danger-ink);
}

html[data-theme="minimal"] .modal-ticket-resource-container #deleteresource .resource_delete > .button_red::before {
	content: "";
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	background-color: currentColor;
	-webkit-mask: url(/icons/ui/trash.svg) center / 16px no-repeat;
	mask: url(/icons/ui/trash.svg) center / 16px no-repeat;
}

/* The record line: the ID and "Created ..." (12 px, text 2) at the left,
   the Textile quick reference at the right as a link (UI-37) whose tooltip
   has the normal tooltip size and the left alignment of family 34. */
html[data-theme="minimal"] .modal-ticket-resource-information {
	background: transparent;
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	line-height: 18px;
	font-variant-numeric: tabular-nums;
}

html[data-theme="minimal"] button.tooltip.modal-ticket-textile-help {
	display: inline-flex;
	align-items: center;
	min-height: 24px;
	padding: 0;
	border: 0;
	background: transparent;
	color: var(--color-text-secondary);
	font: inherit;
	font-size: var(--font-size-xs);
	cursor: help;
}

html[data-theme="minimal"] button.tooltip.modal-ticket-textile-help > span {
	text-decoration: underline;
	text-underline-offset: 2px;
}

html[data-theme="minimal"] button.tooltip.modal-ticket-textile-help:hover {
	color: var(--color-text-primary);
}

html[data-theme="minimal"] button.tooltip.modal-ticket-textile-help:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
	border-radius: var(--radius-sm);
}

/* The help text has lines of its own (the view's text keeps its line
   breaks); it opens above the link, right-aligned to it. */
html[data-theme="minimal"] button.tooltip.modal-ticket-textile-help:not(:has(> .icon.tooltip.help))::after {
	white-space: pre-line;
}

html[data-theme="minimal"] button.tooltip.modal-ticket-textile-help:is(:hover, :focus-visible)::after {
	right: 0;
	left: auto;
}

/* The discussion on the sunken surface: comments with the author and the
   date in 12 px, the text 14 px in a box on the panel, reactions as 24 px
   pills; the comment field with the 32 px send button at its right. */
html[data-theme="minimal"] .modal-ticket-comments {
	background: var(--color-background-secondary);
}

html[data-theme="minimal"] .modal-ticket-comment-meta {
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	line-height: 16px;
}

html[data-theme="minimal"] .modal-ticket-comment-message {
	box-sizing: border-box;
	min-height: 40px;
	padding: var(--space-sm) var(--space-md);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-md);
	background: var(--color-ui-panel);
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	line-height: 20px;
}

html[data-theme="minimal"] .modal-ticket-comment-message > p {
	margin: 0;
}

/* The picture of the author (and of the viewer at the comment field) is
   level with the centre of the first text line: the 1 px border and the
   padding of the box, half a 20 px line, less half the 28 px picture. A box
   of one line has its text there; a box with more lines keeps the picture at
   this place (the row aligns it to the top). The margin changes with the
   padding of the two boxes (UX-253). */
html[data-theme="minimal"] :is(.modal-ticket-comment-row, .modal-ticket-comments > form) > .memberlist-picture {
	margin-top: calc(1px + var(--space-sm) + (20px - 28px) / 2);
}

/* The own comment is editable: the field edge on hover. */
html[data-theme="minimal"] .modal-ticket-comment-message.markupresult:hover {
	border-color: var(--color-control);
	cursor: text;
}

html[data-theme="minimal"] .modal-ticket-comment-actions {
	display: flex;
	flex: 0 0 auto;
	gap: var(--space-3xs);
}

/* The comment actions (react, delete) show on hover and on keyboard focus
   of their comment, so the discussion stays calm (the screenshot of
   UI-55); on a touch screen they always show. */
html[data-theme="minimal"] .modal-ticket-comment-container .modal-ticket-comment-actions {
	opacity: 0;
	transition: opacity var(--motion-fast) ease;
}

html[data-theme="minimal"] .modal-ticket-comment-container:is(:hover, :focus-within) .modal-ticket-comment-actions {
	opacity: 1;
}

@media (hover: none) {
	html[data-theme="minimal"] .modal-ticket-comment-container .modal-ticket-comment-actions {
		opacity: 1;
	}
}

html[data-theme="minimal"] .modal-ticket-comment-reactions-container {
	display: flex;
	flex-wrap: wrap;
	gap: var(--space-2xs);
}

html[data-theme="minimal"] .modal-ticket-comment-reactions-container:empty {
	display: none;
}

html[data-theme="minimal"] .modal-ticket-comment-reaction {
	display: inline-flex;
	align-items: center;
	gap: var(--space-2xs);
	box-sizing: border-box;
	height: 24px;
	padding: 0 var(--space-sm);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-pill);
	background: var(--color-ui-panel);
	color: var(--color-text-secondary);
	font-size: var(--font-size-md);
	line-height: 16px;
	cursor: pointer;
}

html[data-theme="minimal"] .modal-ticket-comment-reaction:hover {
	background: var(--color-ui-hover);
}

html[data-theme="minimal"] .modal-ticket-comment-reaction-active {
	border-color: var(--color-border-highlight);
	background: var(--color-selected);
	color: var(--color-text-primary);
}

/* The view shows the new comment as its rendered preview until a click
   (treetops.js swaps it with the text area); the preview has the box of the
   field and shows the prompt while it is empty (style.css). */
html[data-theme="minimal"] .modal-ticket-comments > form > :is(textarea, .markupresult) {
	padding: var(--space-sm) var(--space-md);
	border: 1px solid var(--color-control);
	border-radius: var(--radius-md);
	background: var(--color-field);
	color: var(--color-text-primary);
	font: inherit;
	font-size: var(--font-size-md);
	line-height: 20px;
	resize: vertical;
}

html[data-theme="minimal"] .modal-ticket-comments > form > textarea:focus {
	border-color: var(--color-border-highlight);
	outline: none;
	box-shadow: inset 0 0 0 1px var(--color-border-highlight);
}

/* The send button: a 32 px round icon button, quiet while the field is
   empty; with text in the field it takes the accent fill (white icon,
   5.41:1 and 5.00:1). */
html[data-theme="minimal"] .modal-ticket-comments-send > .icon-button {
	border-radius: var(--radius-pill);
	background: var(--color-background-quaternary);
}

html[data-theme="minimal"] .modal-ticket-comments-send > .icon-button.is-ready {
	background: var(--color-button-confirm);
	color: var(--color-button-confirm-text);
}

/* The group headings of the aside: 12 px, 600, sentence case. */
html[data-theme="minimal"] .modal-ticket-resource-container > .modalAside > h3 {
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-weight: 600;
	line-height: 16px;
	letter-spacing: 0;
	text-transform: none;
}

/* The comment actions of the view (react, delete) are the 28 px icon
   buttons of family 24, with the plus and trash icons. */
html[data-theme="minimal"] .modal-ticket-comment-actions > :is(.comment-react, .comment-delete) {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	width: 28px;
	min-width: 0;
	height: 28px;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: var(--radius-md);
	background: transparent;
	color: var(--color-text-secondary);
	cursor: pointer;
}

html[data-theme="minimal"] .modal-ticket-comment-actions > :is(.comment-react, .comment-delete)::before {
	content: "";
	width: 16px;
	height: 16px;
	background-color: currentColor;
	-webkit-mask: url(/icons/ui/plus.svg) center / 16px no-repeat;
	mask: url(/icons/ui/plus.svg) center / 16px no-repeat;
}

html[data-theme="minimal"] .modal-ticket-comment-actions > .comment-delete::before {
	-webkit-mask-image: url(/icons/ui/trash.svg);
	mask-image: url(/icons/ui/trash.svg);
}

html[data-theme="minimal"] .modal-ticket-comment-actions > :is(.comment-react, .comment-delete):hover {
	background-color: var(--color-ui-hover);
	color: var(--color-text-primary);
}

html[data-theme="minimal"] .modal-ticket-comment-actions > :is(.comment-react, .comment-delete):focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 0;
}

/* The send button of the view: the 32 px round icon button of the sheet;
   treetops.tickets.js marks a field with text with .message-send-green. */
html[data-theme="minimal"] .modal-ticket-comments-send > .icon.messenger {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	width: 32px;
	height: 32px;
	padding: 0;
	border: 0;
	border-radius: var(--radius-pill);
	background: var(--color-background-quaternary);
	color: var(--color-text-secondary);
	-webkit-mask: none;
	mask: none;
	cursor: pointer;
}

html[data-theme="minimal"] .modal-ticket-comments-send > .icon.messenger::before {
	content: "";
	width: 16px;
	height: 16px;
	background-color: currentColor;
	-webkit-mask: url(/icons/ui/send.svg) center / 16px no-repeat;
	mask: url(/icons/ui/send.svg) center / 16px no-repeat;
}

html[data-theme="minimal"] .modal-ticket-comments-send > .icon.messenger.message-send-green {
	background: var(--color-button-confirm);
	color: var(--color-button-confirm-text);
}

html[data-theme="minimal"] .modal-ticket-comments-send > .icon.messenger:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
}

/* The pickers of the ticket dialog (the subscription, label and reaction
   lists that open from "Add" and from the smiley) are menus of family 3: the
   raised surface with the hairline, the 6 px corners and the menu shadow, a
   220 px panel with 4 px padding, entries with 4 px corners, the row hover
   surface and a 2 px inset focus ring. The entries keep the size and the
   space of the other themes (UI-78). The close button keeps its function and
   stands in the top right corner above the entries (26 px of room, and the
   10 px top margin of the first entry; 46 px for the reaction list, whose
   button has an inline top margin of 10 px). The place of the panel, the
   markup and the script stay (UX-255). */
html[data-theme="minimal"] .modal-ticket-assignresource {
	box-sizing: border-box;
	width: 220px;
	max-width: calc(100vw - 20px);
	padding: 26px var(--space-2xs) var(--space-2xs);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-md);
	background: var(--color-raised-surface);
	box-shadow: var(--shadow-md);
	color: var(--color-text-primary);
	font-weight: 400;
	line-height: 20px;
}

html[data-theme="minimal"] .modal-ticket-comment-actions .modal-ticket-assignresource {
	padding-top: 46px;
}

/* The picker of the aside hangs below its button, as a menu of family 3 does
   (UX-260). The aside button is a flex box in the Minimal themes, so a panel
   without an offset stood in the middle of its button; a long list then
   reached above the top edge of the dialog, where the dialog cannot scroll to
   it. Below the button, the panel only grows downwards and the dialog scrolls
   to the end of it; the list scrolls inside the panel (maximum height of the
   panel and of its list in style.css). */
html[data-theme="minimal"] .modalAsideButton > .modal-ticket-assignresource {
	top: 100%;
}

html[data-theme="minimal"] .modal-ticket-assignresource > .btnClose {
	top: var(--space-2xs);
	right: var(--space-2xs);
}

/* The list lies on the panel: no panel colour and no 16 px covers of the
   list of family 4 behind the entries. */
html[data-theme="minimal"] .modal-ticket-assignresource .resource-box-body-list {
	background: none;
}

html[data-theme="minimal"] .modal-ticket-comment-actions .modal-ticket-assignresource .resource-box-body-list {
	padding: var(--space-2xs);
}

/* An entry of a list keeps the size and the space of the other themes (UI-78:
   a row has no layout of its own in Minimal); it takes the corners of a menu
   entry. */
html[data-theme="minimal"] .modal-ticket-assignresource .resource-box-body-list > .resourcelist-resource {
	border-radius: var(--radius-sm);
}

html[data-theme="minimal"] .modal-ticket-assignresource .resource-box-body-list > .resourcelist-resource:is(.preliminary-member, .preliminary-label) {
	background: transparent;
	box-shadow: none;
	color: inherit;
	font-weight: 400;
}

html[data-theme="minimal"] .modal-ticket-assignresource .resource-box-body-list > .resourcelist-resource:is(.preliminary-member, .preliminary-label):hover {
	background-color: var(--color-ui-hover);
}

html[data-theme="minimal"] .modal-ticket-assignresource .resource-box-body-list > .resourcelist-resource:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: -2px;
}

/* A label of the label picker looks like the label chip of the same dialog
   (family 21): an 8 px dot in its colour (the view writes the colour to
   --label-colour of the entry) before the name in normal text on the menu
   surface, with the row hover; it has no fill and no ring. */
html[data-theme="minimal"] .modal-ticket-assignresource .resource-box-body-list > .resourcelist-resource.preliminary-label::before {
	content: "";
	flex: 0 0 8px;
	width: 8px;
	height: 8px;
	border-radius: var(--radius-pill);
	background: var(--label-colour, var(--color-control));
	box-shadow: var(--shadow-marker);
}

/*------------------------------
=29 WIZARD STEPS, TABS AND CHOICE CARDS
Replaces: .wizard-progress, .wizard-choice, .tab-links, .tab, .activetab
(style.css =UI: WIZARDS, =TABS).
------------------------------*/

/* The steps: a 24 px circle with the number and the label, joined by a
   hairline. Done: an accent-edged circle with a check. Current: the accent
   fill with a white number and the label in 600. Upcoming: a circle in
   the control colour (3.85:1) and the label in the secondary text. Under
   600 px only the current label shows, with "Step 2 of 4". */
html[data-theme="minimal"] .wizard-progress {
	display: flex;
	align-items: center;
	gap: var(--space-sm);
	margin: 0 0 var(--space-sm);
	padding: 0;
	list-style: none;
	counter-reset: wizard;
}

html[data-theme="minimal"] .wizard-progress li {
	display: flex;
	flex: 1 1 auto;
	align-items: center;
	gap: var(--space-sm);
	min-width: 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
	white-space: nowrap;
}

html[data-theme="minimal"] .wizard-progress li:last-child {
	flex: 0 0 auto;
}

html[data-theme="minimal"] .wizard-progress li:not(:last-child)::after {
	content: "";
	flex: 1 1 16px;
	min-width: 16px;
	height: 1px;
	background: var(--color-ui-panel-border);
}

html[data-theme="minimal"] .wizard-progress li span {
	display: inline-flex;
	flex: 0 0 24px;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	width: 24px;
	height: 24px;
	border: 1px solid var(--color-control);
	border-radius: var(--radius-pill);
	background: var(--color-ui-panel);
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-weight: 600;
	font-variant-numeric: tabular-nums;
}

html[data-theme="minimal"] .wizard-progress li.is-active {
	color: var(--color-text-primary);
	font-weight: 600;
}

html[data-theme="minimal"] .wizard-progress li.is-active span {
	border-color: var(--color-button-confirm);
	background: var(--color-button-confirm);
	color: var(--color-button-confirm-text);
}

html[data-theme="minimal"] .wizard-progress li.is-done {
	color: var(--color-text-primary);
}

html[data-theme="minimal"] .wizard-progress li.is-done span {
	border-color: var(--color-border-highlight);
	color: transparent;
	background-color: var(--color-ui-panel);
	position: relative;
}

html[data-theme="minimal"] .wizard-progress li.is-done span::before {
	content: "";
	position: absolute;
	inset: 3px;
	background-color: var(--color-border-highlight);
	-webkit-mask: url(/icons/ui/check.svg) center / 14px no-repeat;
	mask: url(/icons/ui/check.svg) center / 14px no-repeat;
}

html[data-theme="minimal"] .wizard-step-count {
	display: none;
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	line-height: 16px;
}

/* Under 600 px the progress is one row: the circles of the other steps
   without their labels and without the connecting lines, and the label of
   the current step, which wraps. The views write a label as bare text after
   the number, so a font size of 0 hides it; the number has its own size.
   The organisation setup (eight steps) does not wrap its row here. */
@media (max-width: 599px) {
	html[data-theme="minimal"] .wizard-progress {
		flex-wrap: nowrap;
	}

	html[data-theme="minimal"] .wizard-progress li:not(.is-active) {
		flex: 0 0 auto;
		gap: 0;
		font-size: 0;
	}

	html[data-theme="minimal"] .wizard-progress li.is-active {
		flex: 1 1 auto;
		white-space: normal;
	}

	html[data-theme="minimal"] .wizard-progress li:not(:last-child)::after {
		display: none;
	}

	/* Under the progress row (its 8 px margin above); a negative margin
	   put it on the label of the current step. */
	html[data-theme="minimal"] .wizard-step-count {
		display: block;
		margin: 0 0 var(--space-xl);
	}
}

/* The heading of a step: 16 px, 600, with an introduction in 14 px. */
html[data-theme="minimal"] .wizard-step-title {
	margin: 0;
	padding: 0;
	font-size: var(--font-size-lg);
	font-weight: 600;
	line-height: 24px;
}

/* Choice cards: radio cards in a row that wraps (each at least 240 px). A
   card: the panel, a hairline edge, 8 px corners, the radio at the top
   left, the title (14 px, 600) and a description (13 px, the secondary
   text). Hover: the control edge. Selected: a 2 px accent edge and the
   selected tint; the checked radio is the second signal. The whole card
   is the target. */
html[data-theme="minimal"] .wizard-choices {
	display: flex;
	flex-wrap: wrap;
	gap: var(--space-lg);
}

html[data-theme="minimal"] .wizard-choice {
	display: flex;
	flex: 1 1 240px;
	align-items: flex-start;
	gap: var(--space-lg);
	box-sizing: border-box;
	min-width: 0;
	min-height: 64px;
	margin: 0;
	padding: var(--space-lg) var(--space-xl);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
	cursor: pointer;
	transition: border-color var(--motion-fast) ease, background-color var(--motion-fast) ease;
}

/* Where the views stack the cards (style.css: .wizard-choice-grid is a
   column under 621 px), the 240 px basis would be their height. */
@media (max-width: 620px) {
	html[data-theme="minimal"] .wizard-choice-grid > .wizard-choice {
		flex: 0 0 auto;
	}
}

html[data-theme="minimal"] .wizard-choice:hover {
	border-color: var(--color-control);
}

html[data-theme="minimal"] .wizard-choice:has(input:checked) {
	border-color: var(--color-border-highlight);
	background: var(--color-selected);
	box-shadow: inset 0 0 0 1px var(--color-border-highlight);
}

html[data-theme="minimal"] .wizard-choice:has(input:focus-visible) {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
}

html[data-theme="minimal"] .wizard-choice input:focus-visible {
	outline: none;
}

html[data-theme="minimal"] .wizard-choice > span {
	display: flex;
	flex-direction: column;
	gap: var(--space-3xs);
	min-width: 0;
}

html[data-theme="minimal"] .wizard-choice strong {
	font-size: var(--font-size-md);
	font-weight: 600;
	line-height: 20px;
}

html[data-theme="minimal"] .wizard-choice small {
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

/* A choice card that starts an action at once (the bill start): a button
   with a 20 px icon and no radio. */
html[data-theme="minimal"] .wizard-choice.is-action {
	align-items: center;
	color: var(--color-text-primary);
	font: inherit;
	text-align: left;
}

html[data-theme="minimal"] .wizard-choice.is-action::before {
	content: "";
	flex: 0 0 20px;
	width: 20px;
	height: 20px;
	background-color: var(--color-text-secondary);
	-webkit-mask: var(--choice-icon) center / 20px no-repeat;
	mask: var(--choice-icon) center / 20px no-repeat;
}

html[data-theme="minimal"] .wizard-choice.is-action:hover {
	background: var(--color-ui-hover);
}

html[data-theme="minimal"] .wizard-choice.is-action:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
}

/* Tabs: 40 px tabs, 14 px 500 in the secondary text; the selected tab in
   the primary text, 600, with a 2 px accent bar at the bottom (the bar and
   the weight carry the state). The arrow keys move between tabs
   (role="tablist"). The markup is the one that treetops.modal.js sets up
   (initializeModalTabs): .tabs > .tab-links > li > a[href], and
   .tabs > .tab-content > .tab panes; the script marks the selected link
   with aria-selected and its li with .activetab. */
html[data-theme="minimal"] .tab-links {
	display: flex;
	gap: var(--space-xs);
	margin: 0;
	padding: 0;
	border-bottom: 1px solid var(--color-ui-panel-border);
	list-style: none;
	overflow-x: auto;
	scrollbar-width: none;
}

/* The clearfix of the floated tabs is not needed in the flex row. */
html[data-theme="minimal"] .tab-links::after {
	content: none;
}

html[data-theme="minimal"] .tab-links > li {
	flex: 0 0 auto;
	float: none;
	margin: 0;
}

html[data-theme="minimal"] .tab-links :is(a, button) {
	position: relative;
	display: inline-flex;
	align-items: center;
	box-sizing: border-box;
	width: auto;
	min-width: 0;
	height: 40px;
	padding: 0 var(--space-lg);
	border: 0;
	border-radius: var(--radius-md) var(--radius-md) 0 0;
	background: transparent;
	color: var(--color-text-secondary);
	font-size: var(--font-size-md);
	font-weight: 500;
	line-height: 20px;
	text-decoration: none;
	white-space: nowrap;
	cursor: pointer;
}

html[data-theme="minimal"] .tab-links :is(a, button):hover {
	background: var(--color-ui-hover);
	color: var(--color-text-primary);
}

html[data-theme="minimal"] .tab-links :is(a, button):focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: -2px;
}

html[data-theme="minimal"] .tab-links :is(li.activetab > a, [aria-selected="true"]) {
	background: transparent;
	color: var(--color-text-primary);
	font-weight: 600;
}

html[data-theme="minimal"] .tab-links :is(li.activetab > a, [aria-selected="true"])::after {
	content: "";
	position: absolute;
	right: var(--space-lg);
	bottom: 0;
	left: var(--space-lg);
	height: 2px;
	border-radius: 2px 2px 0 0;
	background: var(--color-selected-mark);
}

/* A tabbed dialog (modal_member_add.erb, modal_ticket_new.erb, the expense
   and tax rate dialogs): the .tabs block is the first child of the dialog
   and the tab row is its header row (master showed the tabs above the
   frame, over the dimmed page). The panes fill the rest of the dialog:
   each holds its close button, its body (which scrolls) and its footer.
   The close button stands in the top right corner of the dialog, as in a
   dialog with a title. */
html[data-theme="minimal"] .modalDialog > .tabs {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	min-height: 0;
}

/* The text of the first tab aligns with the body (24 px; 16 px on phones). */
html[data-theme="minimal"] .modalDialog > .tabs > .tab-links {
	flex: 0 0 auto;
	padding: var(--space-lg) 56px 0 var(--space-lg);
}

html[data-theme="minimal"] .modalDialog > .tabs > .tab-content {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	min-height: 0;
	border: 0;
	border-radius: 0;
	background: transparent;
}

html[data-theme="minimal"] .modalDialog > .tabs > .tab-content > .tab.activetab:not([hidden]) {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	min-height: 0;
}

html[data-theme="minimal"] .modalDialog > .tabs .modalBody {
	padding-top: var(--space-xl);
}

@media (max-width: 599px) {
	html[data-theme="minimal"] .modalDialog > .tabs > .tab-links {
		padding: var(--space-sm) 52px 0 var(--space-2xs);
	}
}

/*------------------------------
=30 CONFIRMATION PANELS
Replaces: .inline-confirm, the question modals of archive and delete. The
host families own the placements of the question: the foot of the Mikron
form and the draft bar of the calendar in "27 (continued)" (a line of its
own under the actions, C1), the dialog footer in family 28 (in place of
Delete).
------------------------------*/

/* The one confirmation pattern (UI-12): the question in the page, after its
   trigger. The error tint, a hairline in the error ink at 30 %, 8 px
   corners; the question 14 px 600, the detail 13 px in the secondary text
   (5.10:1 and 7.09:1 on the tint); the red confirm button, then Cancel
   (secondary, UI-30). role="alertdialog"; the focus moves to the confirm
   button. */
html[data-theme="minimal"] .inline-confirm {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-sm);
	box-sizing: border-box;
	max-width: 640px;
	margin: var(--space-sm) 0 0;
	padding: var(--space-lg) var(--space-xl);
	border: 1px solid color-mix(in srgb, var(--color-error-dark) 30%, var(--color-error-bright));
	border-radius: var(--radius-lg);
	background: var(--color-error-bright);
	color: var(--color-text-primary);
	list-style: none;
}

html[data-theme="minimal"] .inline-confirm > p {
	flex: 1 1 100%;
	margin: 0;
	font-size: var(--font-size-md);
	line-height: 20px;
}

html[data-theme="minimal"] .inline-confirm > .inline-confirm-question {
	font-weight: 600;
}

html[data-theme="minimal"] .inline-confirm > .inline-confirm-detail {
	margin-top: calc(var(--space-sm) * -1 + var(--space-3xs));
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

html[data-theme="minimal"] .inline-confirm > p:last-of-type {
	margin-bottom: var(--space-2xs);
}

html[data-theme="minimal"] .inline-confirm:focus {
	outline: none;
}

/* Inside a menu (the leave question of UI-41 after a side-menu entry) the
   panel is compact: 13 px and 10 by 12 px padding, the buttons wrap. The
   rule repeats the edge and the tint, because the plain list items of the
   side menu (family 2, #cssmenu-body ul li) are stronger than the panel
   rule above. */
html[data-theme="minimal"] :is(#cssmenu, .menu) .inline-confirm {
	margin: var(--space-2xs) 0 var(--space-sm);
	padding: var(--space-md) var(--space-lg);
	border: 1px solid color-mix(in srgb, var(--color-error-dark) 30%, var(--color-error-bright));
	background: var(--color-error-bright);
}

html[data-theme="minimal"] :is(#cssmenu, .menu) .inline-confirm > p {
	font-size: var(--font-size-sm);
	line-height: 18px;
}

/* A question dialog (archive, delete): S, the question as the title, one
   paragraph, the footer with Cancel and the confirming button (danger for
   a delete, primary for an archive). Master had no Cancel. The 24 px under
   the paragraph stand above a footer after the body (the sheet); the views
   write the footer at the end of the form inside the body, and its margin
   gives the 24 px there (family 28 continued), so the body keeps no padding
   under the footer. */
html[data-theme="minimal"] .modal-question .modalBody:not(:has(.modalFooter)) {
	padding-bottom: var(--space-3xl);
}

/*------------------------------
=31 NOTIFICATIONS AND PANEL NOTICES (notifications shared with Skeleton)
Replaces: #tt-notifications, .flashmessages, .flash-message, .flash-dismiss
(style.css), and the panel notices .warning (guest projects, the internal
client, the bill editor).
------------------------------*/

/* Messages stand at the top right under the header (they covered the page
   title as full-width bars): a 360 px stack, 8 px apart. Errors (role
   alert) above notices and warnings (role status). The fixed column of
   style.css (#tt-notifications, #tt-errors, #tt-toasts) holds the stack;
   "31 (continued)" fits it to the page of the application. */
html[data-theme="minimal"] #tt-notifications {
	top: 60px;
	right: var(--space-xl);
	gap: var(--space-sm);
	width: min(360px, calc(100vw - 32px));
}

/* A message: the raised surface, a hairline, 8 px corners, the menu shadow; a 16 px
   icon in the status ink, the text 14 px in the primary text (17.74:1 and
   12.64:1; master had 1.77:1 to 2.18:1 in Light), the 24 px dismiss button.
   The icon shape (check, triangle, circle) is the second signal. */
html[data-theme="minimal"] .flash-message {
	display: flex;
	align-items: flex-start;
	gap: var(--space-sm);
	box-sizing: border-box;
	padding: var(--space-lg) var(--space-sm) var(--space-lg) var(--space-lg);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-raised-surface);
	box-shadow: var(--shadow-md);
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	line-height: 20px;
	text-align: left;
	pointer-events: auto;
	animation: dialog-in var(--motion-base) var(--ease-standard);
}

html[data-theme="minimal"] .flash-message::before {
	content: "";
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	margin-top: 2px;
	background-color: var(--flash-ink);
	-webkit-mask: var(--flash-icon) center / 16px no-repeat;
	mask: var(--flash-icon) center / 16px no-repeat;
}

html[data-theme="minimal"] .flash-message.notice { --flash-ink: var(--color-success-dark); --flash-icon: url(/icons/ui/check-circle.svg); }
html[data-theme="minimal"] .flash-message.warning { --flash-ink: var(--color-warning-dark); --flash-icon: url(/icons/ui/alert-triangle.svg); }
html[data-theme="minimal"] .flash-message.error { --flash-ink: var(--color-error-dark); --flash-icon: url(/icons/ui/alert-circle.svg); }

html[data-theme="minimal"] .flash-content {
	flex: 1 1 auto;
	min-width: 0;
	padding: 0;
	overflow-wrap: anywhere;
}

/* The dismiss button stands beside the first line of the text (style.css
   places it over the padding only in the other themes). */
html[data-theme="minimal"] .flash-dismiss {
	flex: 0 0 24px;
	margin: -2px 0 -2px auto;
}

html[data-theme="minimal"] .flash-leaving {
	opacity: 0;
	transition: opacity var(--motion-base) ease;
}

@media (max-width: 599px) {
	html[data-theme="minimal"] #tt-notifications {
		top: 56px;
		right: var(--space-sm);
		width: calc(100vw - 16px);
	}
}

/*------------------------------
=31 (continued) THE MESSAGES IN THE APPLICATION
The fits of the stack to the page of the application. The views write
the stack as a child of the body (partials/errors.erb); the component
sheet shows it inside a specimen, so these rules do not reach it.
------------------------------*/

/* The stack of style.css spans the window from left: 0, so the rule sets
   left to auto. treetops.ajax.js writes the top inline (the bottom of the
   header, or 0 under a dialog); the margin keeps the cards 8 px below
   it. */
html[data-theme="minimal"] body > #tt-notifications {
	left: auto;
	margin-top: var(--space-sm);
}

/* A panel notice (.warning; new class .panel-notice for the other kinds): a
   message that belongs to a panel and stays (a guest project, the internal
   client, "no billable project" in the bill editor). .panel-notice and its
   kinds (.is-info, .is-error, .is-success) are the sheet only; the views:
   UX-61. The status tint, a
   hairline in the status ink at 30 %, 8 px corners, a 16 px icon in the
   ink, the text 14 px in the primary text (15.09:1 to 16.19:1 Light,
   12.28:1 to 13.00:1 Dark on the tints). Info: the sunken surface and the
   info icon in the secondary text. The icon stands in the left padding, so
   that it keeps its place and size also in a block box: jQuery .show() and
   .toggle() write display: block (the role warnings of the member dialog,
   the warning of the manual override in the bill editor). */
html[data-theme="minimal"] :is(div, p).warning:not(.flash-message),
html[data-theme="minimal"] .panel-notice {
	--notice-ink: var(--color-warning-dark);
	--notice-tint: var(--color-warning-bright);
	--notice-icon: url(/icons/ui/alert-triangle.svg);
	position: relative;
	display: flex;
	align-items: flex-start;
	box-sizing: border-box;
	margin: 0 0 var(--space-xl);
	padding: var(--space-lg) var(--space-xl) var(--space-lg) calc(var(--space-xl) + 16px + var(--space-sm));
	border: 1px solid color-mix(in srgb, var(--notice-ink) 30%, var(--notice-tint));
	border-radius: var(--radius-lg);
	background: var(--notice-tint);
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	font-style: normal;
	line-height: 20px;
}

html[data-theme="minimal"] :is(div, p).warning:not(.flash-message)::before,
html[data-theme="minimal"] .panel-notice::before {
	content: "";
	position: absolute;
	top: calc(var(--space-lg) + 2px);
	left: var(--space-xl);
	width: 16px;
	height: 16px;
	background-color: var(--notice-ink);
	-webkit-mask: var(--notice-icon) center / 16px no-repeat;
	mask: var(--notice-icon) center / 16px no-repeat;
}

html[data-theme="minimal"] :is(div, p).warning.hidden,
html[data-theme="minimal"] .panel-notice.hidden {
	display: none;
}

html[data-theme="minimal"] :is(div, p).warning strong,
html[data-theme="minimal"] .panel-notice strong {
	font-weight: 600;
}

/* A short inline warning (span or small) is text in the warning ink. */
html[data-theme="minimal"] :is(span, small).warning {
	color: var(--color-warning-dark);
	font-size: var(--font-size-sm);
}

html[data-theme="minimal"] .panel-notice.is-info {
	--notice-ink: var(--color-text-secondary);
	--notice-tint: var(--color-background-secondary);
	--notice-icon: url(/icons/ui/info.svg);
}

html[data-theme="minimal"] .panel-notice.is-error {
	--notice-ink: var(--color-error-dark);
	--notice-tint: var(--color-error-bright);
	--notice-icon: url(/icons/ui/alert-circle.svg);
}

html[data-theme="minimal"] .panel-notice.is-success {
	--notice-ink: var(--color-success-dark);
	--notice-tint: var(--color-success-bright);
	--notice-icon: url(/icons/ui/check-circle.svg);
}

/*------------------------------
=32 TABLES
Replaces: .member-time-leave-report-table, .member-time-leave-daily-table and
their cells, the inline table styles of mikrons/modal_timesheets_details.erb,
--color-table-border, the rotated column labels.
------------------------------*/

/* One data table: 13/18 text; the head 12 px 500 in the secondary text on
   the sunken surface; 40 px rows with hairline dividers; numbers
   right-aligned and tabular; a group divider in the control colour; the
   totals row in 600 under a control-colour line. No zebra rows, no rotated
   labels: a long head wraps on up to three lines. The wrapper keeps its
   height in the flex column of a scrolling dialog body (its sideways
   overflow would let it shrink to nothing). */
html[data-theme="minimal"] .data-table-wrap {
	flex: 0 0 auto;
	max-width: 100%;
	overflow-x: auto;
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
	scrollbar-width: thin;
}

html[data-theme="minimal"] .data-table {
	width: 100%;
	border-collapse: separate;
	border-spacing: 0;
	color: var(--color-text-primary);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

html[data-theme="minimal"] .data-table :is(th, td) {
	box-sizing: border-box;
	height: 40px;
	padding: var(--space-sm) var(--space-lg);
	border-bottom: 1px solid var(--color-ui-panel-border);
	text-align: left;
	vertical-align: middle;
}

html[data-theme="minimal"] .data-table thead th {
	height: 36px;
	max-width: 112px;
	background: var(--color-background-secondary);
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-weight: 500;
	line-height: 16px;
	vertical-align: bottom;
	white-space: normal;
}

html[data-theme="minimal"] .data-table :is(th, td).is-number {
	text-align: right;
	font-variant-numeric: tabular-nums;
	white-space: nowrap;
}

html[data-theme="minimal"] .data-table thead th.is-number {
	min-width: 72px;
	white-space: normal;
}

html[data-theme="minimal"] .data-table tbody th[scope="row"],
html[data-theme="minimal"] .data-table tfoot th[scope="row"] {
	min-width: 160px;
}

html[data-theme="minimal"] .data-table :is(th, td).is-zero {
	color: var(--color-text-secondary);
}

html[data-theme="minimal"] .data-table :is(th, td).is-group-start {
	border-left: 1px solid var(--color-control);
}

html[data-theme="minimal"] .data-table tbody tr:hover > * {
	background: var(--color-ui-hover);
}

html[data-theme="minimal"] .data-table tbody th {
	font-weight: 500;
}

html[data-theme="minimal"] .data-table tfoot :is(th, td) {
	border-top: 1px solid var(--color-control);
	border-bottom: 0;
	font-weight: 600;
}

/* The first column stays in view when the table scrolls sideways. A table
   with two header rows marks the second one (.member-time-leave-metric-headers
   of the time and leave report): its first cell lies beside a head that spans
   both rows and does not stick. */
html[data-theme="minimal"] .data-table :where(tr:not(.member-time-leave-metric-headers)) > :is(th, td):first-child {
	position: sticky;
	left: 0;
	z-index: 1;
	background: var(--color-ui-panel);
}

html[data-theme="minimal"] .data-table thead :is(th, td):first-child {
	background: var(--color-background-secondary);
}

/* Time and leave: automatic columns keep translated headings and warnings
   inside their cells. Wide tables scroll inside the dialog body. */
html[data-theme="minimal"] .member-time-leave-report-table {
	table-layout: auto;
	min-width: 1040px;
}

html[data-theme="minimal"] :is(.member-time-leave-report-table, .member-time-leave-daily-table) th,
html[data-theme="minimal"] .member-time-leave-report-table td:not(.is-number),
html[data-theme="minimal"] :is(.member-time-leave-configuration-warning, .member-time-leave-metric-range) {
	white-space: normal;
	overflow-wrap: anywhere;
}

/* Metric buttons keep the row hover surface when the pointer crosses them. */
html[data-theme="minimal"] .member-time-leave-report-table button:is(:hover, :focus-visible) {
	background: transparent;
}

html[data-theme="minimal"] .member-time-leave-report-table button:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
}

@media (max-width: 720px) {
	html[data-theme="minimal"] .member-time-leave-report-actions {
		flex-wrap: wrap;
	}
}

/*------------------------------
=33 EMPTY STATES
Replaces: .empty-state (style.css), the empty "None" texts of the user
pages, the empty draft bar text.
------------------------------*/

/* A list without rows: a box of its own, apart from the rows above it
   (UI-42), centred: one sentence (14 px, the primary text) and, where the
   user can act, one action. Empty: the page's add action (secondary, with
   the plus). Filtered: "Clear all filters". The actions are the sheet
   only; the views: UX-68. Archive and quick filter: no action. The count
   line under the list hides while the empty state of the server shows; the
   empty state of the quick filter keeps it, because "Load more" can load
   rows that match. */
html[data-theme="minimal"] .empty-state {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: var(--space-lg);
	box-sizing: border-box;
	margin: var(--space-xl) 0 0;
	padding: var(--space-3xl) var(--space-3xl);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
	color: var(--color-text-primary);
	text-align: center;
}

html[data-theme="minimal"] .empty-state > p {
	max-width: 48ch;
	margin: 0;
	font-size: var(--font-size-md);
	line-height: 20px;
}

html[data-theme="minimal"] .empty-state > p + p {
	margin-top: calc(var(--space-sm) * -1);
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

html[data-theme="minimal"] .empty-state[hidden] {
	display: none;
}

html[data-theme="minimal"] .resource-list-pages:has(~ .empty-state:not([hidden], .quick-filter-empty)),
html[data-theme="minimal"] .empty-state:not([hidden], .quick-filter-empty) ~ .resource-list-pages {
	display: none;
}

/* Inside a box or a dialog the empty state is the quiet sentence of
   family 15. */
html[data-theme="minimal"] :is(.resource-box, .modalBody) .empty-state {
	margin: 0;
	padding: var(--space-3xl) var(--space-xl);
	border: 0;
	background: transparent;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
}

/*------------------------------
=34 TOOLTIPS AND HELP POPOVERS
Replaces: :is(a, button).tooltip::after and its hover and focus rules
(style.css). The Textile quick reference stays a link with a tooltip
(UI-37, UI-55; its rules are in family 28).
------------------------------*/

/* A tooltip names an icon button or explains a short value: the tooltip
   surface, 12/16 white (17.74:1 and 14.11:1), 6 by 8 px, 6 px corners, at
   most 280 px. It shows on hover and on keyboard focus. */
html[data-theme="minimal"] :is(a, button, span).tooltip:not(:has(> .icon.tooltip.help))::after,
html[data-theme="minimal"] .tooltip-bubble {
	box-sizing: border-box;
	max-width: min(280px, calc(100vw - 16px));
	padding: var(--space-xs) var(--space-sm);
	border-radius: var(--radius-md);
	background: var(--color-tooltip-bg);
	box-shadow: var(--shadow-md);
	color: var(--color-tooltip-text);
	font-size: var(--font-size-xs);
	font-weight: 400;
	line-height: 16px;
	text-align: left;
	white-space: normal;
}

html[data-theme="minimal"] .tooltip-bubble {
	display: inline-block;
}

/* A help popover opens from a help button (click, Enter or tap; Escape or
   a click outside closes it): the raised surface, a hairline edge, 8 px corners,
   the menu shadow, 12 by 16 px, at most 320 px; an optional 13 px title in
   600, the text 13/20 in the primary text, left-aligned. It does not cover
   its button. It stands above a stacked dialog (1010) and under the
   messages (1100). */
html[data-theme="minimal"] .help-popover {
	box-sizing: border-box;
	width: max-content;
	max-width: min(320px, calc(100vw - 16px));
	overflow-y: auto;
	overscroll-behavior: contain;
	padding: var(--space-lg) var(--space-xl);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-raised-surface);
	box-shadow: var(--shadow-md);
	color: var(--color-text-primary);
	font-size: var(--font-size-sm);
	font-weight: 400;
	line-height: 20px;
	text-align: left;
}

html[data-theme="minimal"] .help-popover > strong {
	display: block;
	margin: 0 0 var(--space-2xs);
	font-weight: 600;
}

html[data-theme="minimal"] .help-popover > p {
	margin: 0;
}

html[data-theme="minimal"] .help-popover > p + p {
	margin-top: var(--space-sm);
}

html[data-theme="minimal"] .help-popover code {
	padding: 0 var(--space-2xs);
	border-radius: var(--radius-sm);
	background: var(--color-background-secondary);
	font-size: var(--font-size-xs);
}

/* Rules that only the application needs. The help buttons of the views
   open their help as this popover: treetops.js reads --help-popover (the
   other themes keep the hover tooltip of master). */
html[data-theme="minimal"] {
	--help-popover: on;
}

/* A help button opens the popover, so it has no hover tooltip. */
html[data-theme="minimal"] .help-button::after {
	content: none;
}

/*------------------------------
=34 (continued) TOOLTIP BUBBLES IN TREETOPS
------------------------------*/

html[data-theme="minimal"] .viewport-tooltip {
	width: min(280px, calc(100vw - 16px));
}

/*------------------------------
=35 PAGINATION AND COUNTS
Replaces: .resource-list-pages, .resource-list-more, .resource-list-count,
.additem (with .has-label, "Show older") and the bracketed "[Show older]"
links.
------------------------------*/

/* Under a list: "Load more" (a secondary 32 px button) and the count
   (12 px, the secondary text, tabular) on one line at the left (the judges
   asked for a left-aligned count instead of a centred one). The status
   (loading, error) follows the count; an error is in the error ink with
   Retry. */
html[data-theme="minimal"] .resource-list-pages {
	display: flex;
	flex-direction: row;
	flex-wrap: wrap;
	align-items: center;
	justify-content: flex-start;
	gap: var(--space-sm) var(--space-lg);
	margin: var(--space-lg) 0 0;
	text-align: left;
}

html[data-theme="minimal"] .resource-list-pages > .resource-list-more {
	order: -1;
}

html[data-theme="minimal"] .resource-list-count,
html[data-theme="minimal"] .resource-list-status {
	margin: 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	line-height: 16px;
	font-variant-numeric: tabular-nums;
}

html[data-theme="minimal"] .resource-list-status.is-error {
	color: var(--color-error-dark);
	font-size: var(--font-size-sm);
	font-weight: 500;
}

/* "Load more budgets", "Show older": the secondary button of family 23,
   16 px under the list, as wide as its label. */
html[data-theme="minimal"] .additem {
	width: auto;
	margin: var(--space-lg) 0 0;
}

/*------------------------------
=36 LOG IN, PASSWORD RESET AND SIGN-UP (shared with Skeleton's login.erb)
Replaces: the inline layout of views/login.erb (classes since rollout
job 8, with master's look in style.css for the other themes),
.password-input, #name and #email (the field icons; the fields are
family 25), .login-website-links, .header-language-control--login.
------------------------------*/

/* The page keeps its photograph (UI-55, answer 12): the aurora photograph
   of master covers the window. A scrim of 60 % near-black lies under the
   top bar (the first 64 px) and fades to 20 % at 160 px, so the white
   links and the language button keep 4.5:1 or more on the brightest part
   of the photograph at every width (measured at 390, 1024, 1440 and
   2000 px: 7.12:1 or more), while the aurora stays bright. On the
   photograph: the top bar and one 400 px card with the wordmark inside it
   (over the aurora a white wordmark had only 2.5:1). The card is the panel
   of the theme (white in Light, the Dark panel in Dark), so its content is
   the same as on every other page. The fields have no captions (UI-36):
   the placeholder and the aria-label name them. */
html[data-theme="minimal"] .login-page {
	display: flex;
	flex-direction: column;
	box-sizing: border-box;
	min-height: 100vh;
	margin: 0;
	background: linear-gradient(to bottom, rgba(6, 10, 14, .6) 0, rgba(6, 10, 14, .6) 64px, rgba(6, 10, 14, .2) 160px), url(/images/aurora.jpg) center / cover no-repeat fixed;
	background-color: #0b1218;
	color: var(--color-text-primary);
	font-family: var(--font-ui-family);
}

html[data-theme="minimal"] .login-topbar {
	display: flex;
	align-items: center;
	gap: var(--space-lg);
	box-sizing: border-box;
	padding: var(--space-lg) var(--space-3xl);
}

html[data-theme="minimal"] .login-website-links {
	position: static;
	z-index: auto;
	display: flex;
	flex: 1 1 auto;
	gap: var(--space-xl);
	font-size: var(--font-size-sm);
}

/* The links are 24 px high targets (the 13 px text with 3 px above and
   below; they were 18 px). They are white on the photograph in both
   themes, as on master, without the text shadow. */
html[data-theme="minimal"] .login-website-links a {
	display: inline-flex;
	align-items: center;
	min-height: 24px;
	color: #ffffff;
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
	text-decoration: none;
	text-shadow: none;
}

html[data-theme="minimal"] .login-website-links a:hover {
	text-decoration: underline;
	text-underline-offset: 2px;
}

/* The language is a quiet white button with a globe and the name of the
   current language (the flag goes); it opens the language list under it.
   The hover is a light veil. */
html[data-theme="minimal"] .header-language-control--login {
	position: relative;
	top: auto;
	right: auto;
	z-index: 100;
	margin: 0;
}

html[data-theme="minimal"] .header-language-control--login > summary {
	display: inline-flex;
	align-items: center;
	gap: var(--space-xs);
	box-sizing: border-box;
	width: auto;
	height: var(--control-height);
	padding: 0 var(--space-md);
	border-radius: var(--radius-md);
	color: #ffffff;
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
	white-space: nowrap;
}

html[data-theme="minimal"] .header-language-control--login > summary::before {
	content: "";
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	background-color: currentColor;
	-webkit-mask: url(/icons/ui/globe.svg) center / 16px no-repeat;
	mask: url(/icons/ui/globe.svg) center / 16px no-repeat;
}

html[data-theme="minimal"] .header-language-control--login > summary:hover {
	background-color: rgba(255, 255, 255, .14);
	transform: none;
}

html[data-theme="minimal"] .login-topbar :focus-visible {
	outline: 2px solid #ffffff;
	outline-offset: 2px;
}

/* The language list: the menu of family 3, as a box under the button. */
html[data-theme="minimal"] .header-language-control--login .header-language-menu {
	top: calc(var(--control-height) + var(--space-2xs));
	padding: var(--space-2xs);
	border-radius: var(--radius-lg);
	background: var(--color-raised-surface);
	box-shadow: var(--shadow-md);
}

/* The entries are those of family 3 (its selector lists name the login
   control), without the 34 px indent of the account menu. */
html[data-theme="minimal"] .header-language-control--login .header-language-menu button {
	padding-left: var(--space-md);
}

/* The card stands in the middle of the window, 24 px under the top bar at
   least and 80 px over the bottom edge. The round logo and the side
   spacers of the other themes go. */
html[data-theme="minimal"] .login-page #content {
	display: flex;
	flex-direction: column;
	justify-content: center;
	padding: var(--space-3xl) var(--space-xl) 80px;
}

html[data-theme="minimal"] .login-layout {
	display: flex;
	justify-content: center;
}

html[data-theme="minimal"] .login-spacer,
html[data-theme="minimal"] .login-logo,
html[data-theme="minimal"] .login-form br,
html[data-theme="minimal"] .login-card-alt-rule {
	display: none;
}

html[data-theme="minimal"] .login-card {
	display: flex;
	flex-direction: column;
	gap: var(--space-xl);
	box-sizing: border-box;
	width: 100%;
	max-width: 400px;
	padding: var(--space-4xl) var(--space-4xl) var(--space-3xl);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-2xl);
	background: var(--color-ui-panel);
	box-shadow: var(--shadow-lg);
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	line-height: 20px;
}

/* The wordmark heads the card, in the accent ink (5.89:1 on the Light
   panel, the accent edge 7.15:1 on the Dark panel). */
html[data-theme="minimal"] .login-wordmark {
	color: var(--color-button-confirm-ink);
	font-family: "Pacifico", cursive;
	font-size: 34px;
	line-height: 40px;
	text-align: center;
}

html[data-theme="minimal"][data-theme-variant="dark"] .login-wordmark {
	color: var(--color-border-highlight);
}

/* The form: the title, the fields 12 px apart, the wide primary button,
   the links and the sign-up block. */
html[data-theme="minimal"] .login-form {
	display: flex;
	flex-direction: column;
	gap: var(--space-lg);
	min-width: 0;
	margin: 0;
	padding: 0;
}

html[data-theme="minimal"] .login-title {
	margin: 0 0 var(--space-2xs);
	padding: 0;
	color: var(--color-text-primary);
	font-family: var(--font-ui-family);
	font-size: var(--font-size-2xl);
	font-weight: 600;
	line-height: 28px;
	letter-spacing: -.01em;
}

html[data-theme="minimal"] .login-intro {
	margin: 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

/* The mail, user and lock icons of the fields go. */
html[data-theme="minimal"] .login-form :is(#name, #email, .password-input) {
	margin: 0;
	background: none;
}

/* The fields are the fields of family 25 (its selector lists name
   .login-form .feedback-input). */

/* The password policy is the hint under the sign-up fields. */
html[data-theme="minimal"] .login-form .password-policy {
	margin: calc(var(--space-sm) * -1) 0 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	line-height: 16px;
}

/* "Forgot your password?" and "Back to login": 13 px accent links, 24 px
   high targets. The links keep their place after the button, so the Tab
   order follows the screen. */
html[data-theme="minimal"] .login-form a.login-card-link {
	display: inline-flex;
	align-items: center;
	align-self: flex-end;
	min-height: 24px;
	color: var(--color-button-confirm-ink);
	font-size: var(--font-size-sm);
	font-weight: 500;
	line-height: 18px;
	text-decoration: none;
}

html[data-theme="minimal"] .login-form a.login-card-link.login-back {
	align-self: center;
}

html[data-theme="minimal"][data-theme-variant="dark"] .login-form a.login-card-link {
	color: var(--color-border-highlight);
}

html[data-theme="minimal"] .login-form a.login-card-link:hover {
	text-decoration: underline;
	text-underline-offset: 2px;
}

html[data-theme="minimal"] .login-form a.login-card-link:focus-visible {
	outline: 2px solid var(--color-focus);
	outline-offset: 2px;
	border-radius: var(--radius-sm);
}

/* "No account yet?" under a hairline, with the secondary button (family
   23 draws .login-card-alt-button as secondary). */
html[data-theme="minimal"] .login-card-alt {
	display: flex;
	flex-direction: column;
	gap: var(--space-sm);
	padding: var(--space-xl) 0 0;
	border-top: 1px solid var(--color-ui-panel-border);
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
	text-align: center;
}

@media (max-width: 599px) {
	html[data-theme="minimal"] .login-topbar {
		padding: var(--space-sm) var(--space-xl);
	}

	html[data-theme="minimal"] .login-page #content {
		justify-content: flex-start;
		padding: var(--space-3xl) var(--space-xl);
	}

	html[data-theme="minimal"] .login-card {
		padding: var(--space-3xl) var(--space-xl);
	}
}

/*------------------------------
=37 SETTINGS PAGES AND USER PAGES
Replaces: the layout of organizations/organization_settings.erb and
users/user_settings.erb (the page title and the line breaks, the columns,
the inline heights of the boxes, the inline styles of the user settings,
which became classes in rollout job 8), .flextable as a settings table,
the logo and picture areas.
------------------------------*/

/* A settings page: the title, then sections 40 px apart in one column.
   A section: the heading (16/24, 600), an optional sentence (13 px, the
   secondary text), and its content: a settings list (family 25), a form
   box, or boxes of family 15. Each form ends with its own "Save changes"
   at the right (disabled until a change, family 23). The line breaks of
   the views go. */
html[data-theme="minimal"] .settings-page {
	display: flex;
	flex-direction: column;
	gap: var(--space-5xl);
	max-width: 1040px;
}

/* A figure without the page frame (the component sheet) is at most
   1040 px wide. On the page the column fills the content width, so the
   page has no fixed width and no horizontal scroll (owner correction C5). */
html[data-theme="minimal"] #content.settings-page {
	max-width: none;
	min-width: 0;
}

html[data-theme="minimal"] .settings-page > br,
html[data-theme="minimal"] .settings-section-head br,
html[data-theme="minimal"] .settings-form br {
	display: none;
}

/* The title of the page has the type of the page header of family 4 (its
   selector list names it), without the margin of the h2. */
html[data-theme="minimal"] .settings-page > h2 {
	margin: 0;
}

html[data-theme="minimal"] .settings-section {
	display: flex;
	flex-direction: column;
	gap: var(--space-lg);
	min-width: 0;
}

/* The first selector serves the sheet's danger zone figure, which has no
   .settings-page around it. */
html[data-theme="minimal"] .settings-section-head > h3,
html[data-theme="minimal"] .settings-page h3 {
	margin: 0;
	padding: 0;
	font-size: var(--font-size-lg);
	font-weight: 600;
	line-height: 24px;
}

html[data-theme="minimal"] .settings-section-head p {
	max-width: 72ch;
	margin: var(--space-2xs) 0 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

/* A form box: the panel with a hairline and 24 px padding. A heading
   inside the box heads it. A form with the field markup of family 25
   stacks its rows 16 px apart: today only the component sheet has it;
   the views get it with UX-66. Until then the forms of the views keep the
   spacing of "25 (continued)" and the 16 px above the foot below. */
html[data-theme="minimal"] .settings-form {
	padding: var(--space-3xl);
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
}

html[data-theme="minimal"] .settings-form:has(> :is(.form-field, .form-row)) {
	display: flex;
	flex-direction: column;
	gap: var(--space-xl);
}

html[data-theme="minimal"] .settings-form:has(> :is(.form-field, .form-row)) > .settings-form-foot {
	margin-top: 0;
}

html[data-theme="minimal"] .settings-form h3 {
	margin: var(--space-3xl) 0 var(--space-sm);
}

html[data-theme="minimal"] .settings-form > h3:first-of-type,
html[data-theme="minimal"] .settings-form > div:first-child > h3:first-child {
	margin-top: 0;
}

/* The foot of a form: a hairline and the save button at the right. Under
   a settings list it has no hairline (the list has its frame). */
html[data-theme="minimal"] .settings-form-foot {
	display: flex;
	justify-content: flex-end;
	gap: var(--space-sm);
	padding: var(--space-xl) 0 0;
	border-top: 1px solid var(--color-ui-panel-border);
}

/* In a form of the views the foot keeps 16 px from the last field: the
   views until UX-66 gives the settings forms the field markup of family
   25; then this rule and the :has() condition above go. */
html[data-theme="minimal"] .settings-form > .settings-form-foot {
	margin-top: var(--space-xl);
}

html[data-theme="minimal"] form > .settings-list ~ .settings-form-foot {
	margin-top: var(--space-lg);
	padding-top: 0;
	border-top: 0;
}

/* Boxes side by side (the address and the financial details, the three
   administrative account boxes, the user's details and app settings):
   each at least 300 px. */
html[data-theme="minimal"] .settings-boxes {
	display: flex;
	flex-wrap: wrap;
	gap: var(--space-xl);
}

html[data-theme="minimal"] .settings-boxes > * {
	flex: 1 1 300px;
	min-width: 0;
}

/* The basis of a form box includes its padding (C5). */
html[data-theme="minimal"] .settings-boxes > .settings-form {
	box-sizing: border-box;
}

/* The columns of the views lose the width, the margins and the right
   padding of style.css; a column that is a form box keeps the padding of
   the form box (C5). */
html[data-theme="minimal"] .settings-boxes > :is(.organization-settings-column, .accordion-innerflexbox) {
	max-width: none;
	margin: 0;
}

html[data-theme="minimal"] .settings-boxes > :is(.organization-settings-column, .accordion-innerflexbox):not(.settings-form) {
	padding-right: 0;
}

/* A settings row of the organisation rules: the help button after the
   control (a long help keeps its help button). */
html[data-theme="minimal"] .settings-row-help {
	flex: 0 0 auto;
}

/* The boxes keep the layout of style.css and their lists scroll (Treetops
   decision UI-78); a box with one list has no hairline after its list. */
html[data-theme="minimal"] :is(.organization-settings-account-box, .organization-non-working-days-box, .organization-settings-labels-box) .resource-box-body-flexcontainer > .resource-box-body:first-child {
	border-right: 0;
}

html[data-theme="minimal"] .organization-settings-media-column {
	gap: var(--space-3xl);
}

html[data-theme="minimal"] .organization-settings-media-column > .grow-1 {
	flex: 0 0 auto;
}

/* The rules list of the identity column is narrower than a page row: a
   select takes 180 px, so its help button stays on its line. */
html[data-theme="minimal"] .organization-settings-identity-form .settings-row-text {
	flex-basis: 160px;
}

html[data-theme="minimal"] .organization-settings-identity-form .settings-row-control > .select-wrap {
	width: 180px;
}

/* The non-working days fill the width of the column. */
html[data-theme="minimal"] .settings-section > .organization-non-working-days {
	max-width: none;
}

html[data-theme="minimal"] .settings-section .organization-non-working-days-box {
	box-sizing: border-box;
	width: 100%;
}

/* The icons of the box heads: the archive toggle of the labels and the
   role of each administrative box (the role icons of family 17). A role
   icon is a picture, not a tool: no hover, no pointer. */
html[data-theme="minimal"] .resource-box-top-right .archive-grey { --box-icon: url(/icons/ui/archive.svg); }
html[data-theme="minimal"] .resource-box-top-right .superuser-grey { --box-icon: url(/icons/ui/crown.svg); }
html[data-theme="minimal"] .resource-box-top-right .manager-grey { --box-icon: url(/icons/ui/briefcase.svg); }
html[data-theme="minimal"] .resource-box-top-right .accountant-grey { --box-icon: url(/icons/ui/receipt.svg); }

html[data-theme="minimal"] .resource-box-top-right div.resource-box-icon:is(.superuser-grey, .manager-grey, .accountant-grey),
html[data-theme="minimal"] .resource-box-top-right div.resource-box-icon:is(.superuser-grey, .manager-grey, .accountant-grey):hover {
	background-color: transparent;
	cursor: default;
}

/* The logo and the picture: the upload area of family 25 (its selector
   list names them), the full width of the column and the height of the
   content instead of the 98 % and 85 px of style.css; the actions under
   it at the right. */
html[data-theme="minimal"] :is(.organization-settings-logo-preview, .user-settings-picture-preview) {
	width: 100%;
	height: auto;
}

html[data-theme="minimal"] :is(.organization-settings-logo-actions, .user-settings-picture-actions) {
	display: flex;
	align-items: center;
	gap: var(--space-sm);
	justify-content: flex-end;
	padding: var(--space-lg) 0 0;
}

/* The user settings: the details and the app settings as two form boxes
   (the other themes keep the fixed 400 px columns of the inline styles,
   with which the page ran 102 px off a 390 px window). */
html[data-theme="minimal"] .user-settings-login-column {
	flex: 1 1 auto;
}

html[data-theme="minimal"] .user-settings-app-settings {
	padding-top: var(--space-3xl);
}

html[data-theme="minimal"] .settings-form :is(.user-settings-account-mode, .user-settings-lock-note, .user-settings-password-policy) {
	margin: 0 0 var(--space-md);
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

html[data-theme="minimal"] .settings-form .user-settings-password-policy {
	margin-top: calc(var(--space-2xs) * -1);
	font-size: var(--font-size-xs);
	line-height: 16px;
}

html[data-theme="minimal"] .settings-form .user-settings-intro {
	margin: var(--space-lg) 0 var(--space-sm);
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

html[data-theme="minimal"] .settings-form .user-settings-release-notice {
	margin: 0 0 var(--space-lg);
	padding: var(--space-md) var(--space-lg);
	border-radius: var(--radius-md);
	background: var(--color-warning-bright);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

html[data-theme="minimal"] .user-settings-login-foot {
	margin-top: var(--space-xl);
	padding-top: var(--space-xl);
}

html[data-theme="minimal"] .user-settings-notifications {
	margin: 0;
	padding: 0 0 0 var(--space-xl);
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

/* The danger zone (delete the account or the organisation): a box with an
   edge in the error ink at 30 %, a sentence and the quiet danger button
   (it opens the question of family 30). */
html[data-theme="minimal"] .settings-danger {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-lg) var(--space-3xl);
	padding: var(--space-xl) var(--space-3xl);
	border: 1px solid color-mix(in srgb, var(--color-error-dark) 30%, var(--color-ui-panel));
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
}

html[data-theme="minimal"] .settings-danger > :is(p, .user-settings-managed-note) {
	flex: 1 1 320px;
	margin: 0;
	color: var(--color-text-secondary);
	font-size: var(--font-size-sm);
	line-height: 18px;
}

@media (max-width: 599px) {
	html[data-theme="minimal"] .settings-page {
		gap: var(--space-3xl);
	}

	html[data-theme="minimal"] .settings-page > h2 {
		font-size: var(--font-size-2xl);
		line-height: 28px;
	}

	html[data-theme="minimal"] .settings-form {
		padding: var(--space-xl);
	}

	/* A select takes the full width under its label; a checkbox stays at
	   the right of the text. */
	html[data-theme="minimal"] .settings-row-control:has(select),
	html[data-theme="minimal"] .settings-row-control > :is(select, .select-wrap) {
		width: 100%;
	}

	html[data-theme="minimal"] .settings-row-control:has(select) {
		flex: 1 1 100%;
	}

	html[data-theme="minimal"] .settings-row-text {
		flex-basis: 0;
		flex-grow: 1;
	}
}

/*------------------------------
=37 (continued) TREETOPS SETTINGS LAYOUT
The Treetops settings pages only (Skeleton has none of these fields): the
optional address lines and the help buttons of the organisation settings.
------------------------------*/

/* The year field in the header of the non-working days has the height and the
   centre line of the "Import ICS" button beside it: the control height, and
   none of the 10 px under a field that the rule of family 25 (continued)
   gives (UX-242). */
html[data-theme="minimal"] .organization-non-working-days-year-control .organization-input {
	height: var(--control-height);
	margin: 0;
}

/* Each action has its own containing block, also on an optional address
   line. A validation error inserted after the input cannot move it. */
html[data-theme="minimal"] .settings-page :is(#namefield, #streetfield),
html[data-theme="minimal"] .settings-page :is(#namefield, #streetfield) > div:has(> .right-field-button) {
	position: relative;
	padding-right: 0;
}

html[data-theme="minimal"] .settings-page :is(#namefield, #streetfield) .organization-input {
	width: calc(100% - 36px);
}

html[data-theme="minimal"] .settings-page :is(#namefield, #streetfield) .right-field-button {
	position: absolute;
	top: calc(var(--space-3xl) + 4px);
	right: 0;
	width: 28px;
	min-width: 28px;
	height: 28px;
	/* The 40 px minimum height of the buttons would win over the height
	   and put the icon 6 px under the centre of the field. */
	min-height: 28px;
	margin: 0;
	padding: 0;
}

/* The bill-scheme and template help buttons take a place in their row,
   inside the form padding, instead of the default right: -40px offset. */
html[data-theme="minimal"] .settings-page .field-action-row > .right-field-button {
	position: static;
	flex: 0 0 24px;
	margin: 0;
}

html[data-theme="minimal"] .settings-page :is(.organization-settings-columns, .user-settings-columns) {
	min-width: 0;
}

html[data-theme="minimal"] .user-settings-picture-actions {
	flex-wrap: wrap;
}

/*------------------------------
=39 TIME LIST OF A TIME FIELD
Replaces: the plugin's own look of .ui-timepicker-wrapper
(jquery.timepicker.css) in the Minimal themes. Every dialog and page with a
time field uses it: the Mikron card, the Mikron dialogs, the calendar pane and
the ticket dialog (treetops.modal.js, treetops.mikrons.js, treetops.tickets.js).
------------------------------*/

/* The menu surface of family 3 (the raised surface, 6 px corners, the menu
   shadow); the edge and the entry colours come from the shared rules in
   style.css. The chosen entry has the hover surface, the label in 500 and a
   2 px edge in the accent (the hover surface alone is 1.22:1 on white),
   shown when the mouse is not over the list. */
html[data-theme="minimal"] body .ui-timepicker-wrapper {
	background-color: var(--color-raised-surface);
	border-radius: var(--radius-md);
	box-shadow: var(--shadow-md);
	scrollbar-width: thin;
}

html[data-theme="minimal"] .ui-timepicker-wrapper .ui-timepicker-list li.ui-timepicker-selected {
	font-weight: 500;
}

html[data-theme="minimal"] .ui-timepicker-wrapper .ui-timepicker-list:not(:hover) li.ui-timepicker-selected {
	background: var(--color-ui-hover);
	box-shadow: inset 2px 0 0 var(--color-border-highlight);
}

/*------------------------------
=38 BILL START AND THE BILL EDITOR FRAME
Replaces: .biggreything and its label and icons (the 370 px start panel),
.billgen-container, .billgen-meta, .billgen-mikrons, .billgen-content,
.billgen-heading, .billgen-table-*, .billgen-subtotal, .billgen-summary,
.closebillgenerator, .billgen .actions (style.css =BILLS: GENERATOR).
------------------------------*/

/* The bill start: an area under the quick filter (UI-65) on its own
   surface, --color-bill-start-surface: the sunken surface in Dark, the grey
   card in Light (owner correction C10: a white box under the quick filter
   was easy to miss). Its layout is the same in every theme (style.css, UI-78):
   the heading at the top left, the close button at the top right and the
   choice in the middle of a panel of at least 370 px. Here it has the look
   of the sheet: a hairline edge, 8 px corners and the heading of the
   editor; its two choices are action cards (family 29). */
html[data-theme="minimal"] .bill-start {
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-bill-start-surface);
}

html[data-theme="minimal"] .bill-start > h3 {
	letter-spacing: -.01em;
}

/* The editor: centred in the content (UI-40, UI-46). A head with the
   title and the close button, then the layout of every theme (style.css,
   UX-269): at its full width of 1380 px two columns, the details and the
   Mikron list (360 px) and the lines, totals and actions; in a narrower
   editor the details and the Mikron list on top and the lines under them.
   Here the parts have padding and hairlines between them. */
html[data-theme="minimal"] .billgen {
	box-sizing: border-box;
	width: 100%;
	height: auto;
	margin: 0 auto var(--space-3xl);
	padding: 0;
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
}

html[data-theme="minimal"] .billgen-head {
	display: flex;
	align-items: center;
	gap: var(--space-lg);
	padding: var(--space-xl) var(--space-sm) var(--space-xl) var(--space-3xl);
	border-bottom: 1px solid var(--color-ui-panel-border);
}

html[data-theme="minimal"] .billgen-head > .btnClose {
	position: static;
}

html[data-theme="minimal"] .billgen-title {
	flex: 1 1 auto;
	min-width: 0;
	margin: 0;
	padding: 0;
	font-size: var(--font-size-2xl);
	font-weight: 600;
	line-height: 28px;
	letter-spacing: -.01em;
}

html[data-theme="minimal"] .billgen-side {
	gap: var(--space-3xl);
	padding: var(--space-3xl);
	border-bottom: 1px solid var(--color-ui-panel-border);
	--caption-width: 112px;
}

html[data-theme="minimal"] .billgen-content {
	display: flex;
	flex-direction: column;
	gap: var(--space-3xl);
	box-sizing: border-box;
	min-width: 0;
	padding: var(--space-3xl);
}

/* In the two columns the hairline stands between them. */
@container bill-composer (width >= 1380px) {
	html[data-theme="minimal"] .billgen-side {
		border-right: 1px solid var(--color-ui-panel-border);
		border-bottom: 0;
	}
}

html[data-theme="minimal"] .billgen-heading {
	margin: 0 0 var(--space-sm);
	padding: 0;
	font-size: var(--font-size-md);
	font-weight: 600;
	line-height: 20px;
}

html[data-theme="minimal"] .billgen-meta {
	display: flex;
	flex-direction: column;
	gap: var(--space-sm);
	margin: 0;
	padding: 0;
}

html[data-theme="minimal"] .billgen-meta input:not([type="checkbox"]) {
	font-variant-numeric: tabular-nums;
}

/* The Mikron list of the bill: the Mikron rows of family 8 in compact form
   in a box that scrolls above 480 px, with the count as its foot. */
html[data-theme="minimal"] .billgen-mikrons {
	display: flex;
	flex-direction: column;
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	overflow: hidden;
}

html[data-theme="minimal"] .billgen-mikronlist {
	max-height: 480px;
	overflow-y: auto;
	scrollbar-width: thin;
}

html[data-theme="minimal"] .billgen-mikronstats {
	padding: var(--space-sm) var(--space-xl);
	border-top: 1px solid var(--color-ui-panel-border);
	background: var(--color-background-secondary);
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	line-height: 16px;
	font-variant-numeric: tabular-nums;
}

/* The Mikron row of the bill: the date in text 2. The layout of the row is
   the same in every theme (style.css, UX-269): in a list under 480 px the
   review column floats in front of the text. A wider list, such as the
   one column of the iPad (UX-219), keeps the row of the classic themes
   (UI-78): the review mark, the names and the date on one line, the
   description under the names: it starts after the review column of a
   compact row (30 px, style.css) and the gap of the row. */
html[data-theme="minimal"] .billgen-mikronlist .ts_mikron .date {
	color: var(--color-text-secondary);
}

@container billgen-mikronlist (width >= 480px) {
	html[data-theme="minimal"] .billgen-mikronlist .ts_mikron .desc {
		padding-left: calc(30px + var(--space-3xl));
	}
}

/* A Mikron that the bill ignores (open or rejected): the text in text 2. */
html[data-theme="minimal"] .billgen-mikronlist .ts_mikron.invalid .ts_flex {
	color: var(--color-text-secondary);
}

html[data-theme="minimal"] .billgen-mikronlist .ts_mikron.invalid :is(.project, .date, .desc) {
	color: var(--color-text-secondary);
}

/* The lines of the bill: the data table of family 32 with editable cells
   (compact 32 px fields); a project heading row and a subtotal row per
   project; "Add item" as a quiet add row. */
html[data-theme="minimal"] .billgen-lines .data-table td {
	height: 44px;
}

html[data-theme="minimal"] .billgen-lines .data-table td .organization-input-small {
	min-width: 64px;
}

/* Tokens and project tokens stay on one line. */
html[data-theme="minimal"] .billgen-lines .data-table td:first-child,
html[data-theme="minimal"] .billgen-lines .data-table td:nth-child(3):not(.is-number) {
	white-space: nowrap;
}

html[data-theme="minimal"] .billgen-lines .billgen-project-row > th {
	background: var(--color-ui-panel);
	color: var(--color-text-primary);
	font-size: var(--font-size-sm);
	font-weight: 600;
}

html[data-theme="minimal"] .billgen-lines .billgen-subtotal-row > * {
	color: var(--color-text-primary);
	font-weight: 600;
}

/* The totals: right-aligned key-value rows, the net and the gross total
   in 600, the gross total 16 px. */
html[data-theme="minimal"] .billgen-summary {
	display: flex;
	flex-direction: column;
	align-self: flex-end;
	gap: var(--space-2xs);
	width: min(100%, 360px);
	font-size: var(--font-size-sm);
	line-height: 18px;
	font-variant-numeric: tabular-nums;
}

html[data-theme="minimal"] .summary-row {
	display: flex;
	justify-content: space-between;
	gap: var(--space-xl);
	padding: var(--space-2xs) 0;
	color: var(--color-text-secondary);
}

html[data-theme="minimal"] .summary-row > .summary-value {
	color: var(--color-text-primary);
	text-align: right;
}

html[data-theme="minimal"] .summary-row.top {
	margin-top: var(--space-sm);
	padding-top: var(--space-sm);
	border-top: 1px solid var(--color-ui-panel-border);
	color: var(--color-text-primary);
	font-weight: 600;
}

/* The gross total is the lead figure of the editor: the label above, the
   amount at 32/40 px, right-aligned. */
html[data-theme="minimal"] .summary-row.is-total {
	flex-wrap: wrap;
	align-items: baseline;
	padding-top: var(--space-sm);
	border-top: 1px solid var(--color-control);
	color: var(--color-text-primary);
	font-size: var(--font-size-md);
	font-weight: 600;
	line-height: 20px;
}

html[data-theme="minimal"] .summary-row.is-total > .summary-value {
	margin-left: auto;
	font-size: var(--font-size-display);
	letter-spacing: -.02em;
	line-height: 40px;
}

/* The actions: Preview (secondary) and Save bill (primary) in the foot of
   the editor, right-aligned under the lines (owner correction C11: a fixed
   place, not a bar that floats at the bottom of the window; UI-70 made it
   so in every theme). */
html[data-theme="minimal"] .billgen-actions {
	display: flex;
	justify-content: flex-end;
	gap: var(--space-sm);
	padding: var(--space-lg) var(--space-3xl);
	border-top: 1px solid var(--color-ui-panel-border);
	border-radius: 0 0 var(--radius-lg) var(--radius-lg);
	background: var(--color-ui-panel);
}

/* The application. The start and the editor keep the classes of the
   default themes (bills.erb, bill_new.erb), and these rules give them the
   look of the sheet: the start panel is the box above, its two choices are
   the action cards of family 29 (the markup has their classes since
   rollout job 7b); the details are the fields of family 25 with the caption in
   front (bill_new.erb: .form-field.is-inline in a .form-stack, since
   rollout job 6); the lines keep the flex rows of master (the data table
   of family 32 needs a change of the reads of treetops.bills.js: UX-65). */

/* The two choices are the action cards of family 29 (.wizard-choice.is-action);
   these rules undo the column of master's pictogram cards and name the icons. */
html[data-theme="minimal"] .bill-start .biggreything-flexcontainer {
	flex-direction: row;
	justify-content: flex-start;
}

html[data-theme="minimal"] .bill-start .userbill {
	--choice-icon: url(/icons/ui/user.svg);
}

html[data-theme="minimal"] .bill-start .clientbill {
	--choice-icon: url(/icons/ui/building.svg);
}

html[data-theme="minimal"] .bill-start .biggreything-icon-container {
	display: none;
}

html[data-theme="minimal"] .bill-start .biggreything-flexcontainer > .label {
	padding: 0;
	font-size: var(--font-size-md);
	font-weight: 600;
	line-height: 20px;
}

/* Under 600 px a page header has its title and the add button on the
   first line (32 px, family 4). The bills page hides "Create bill" while
   the start or the editor is open; the title line keeps the height of the
   button, so the header and the filter do not move. */
@media (max-width: 599px) {
	html[data-theme="minimal"] #content.bills > .content_header > .content_header_title {
		display: flex;
		align-items: center;
		min-height: var(--control-height);
	}
}

/* The composer (.new_bill_ajax) stands under the quick filter, as in the
   other themes (bills.erb, UI-65), 16 px under it and 16 px above the
   bill months: not the 40 px of style.css. It is a flex container
   (style.css centres the editor in it), so the bottom margin of the editor
   would add to its own: in the composer it has none. */
html[data-theme="minimal"] .new_bill_ajax {
	margin: var(--space-xl) 0;
}

html[data-theme="minimal"] .new_bill_ajax > .billgen {
	margin-bottom: 0;
}

/* The editor: .biggreything makes it a centred flex row and the container
   has the padding of master; the head, the columns and the foot have
   their own padding here. The close button comes first in the markup
   (master places it from there) and stands at the end of the head. */
html[data-theme="minimal"] .billgen {
	display: block;
}

html[data-theme="minimal"] .billgen .billgen-container {
	padding: 0;
}

html[data-theme="minimal"] .billgen-head > .btnClose {
	order: 1;
}

html[data-theme="minimal"] .billgen-side #date-range {
	display: contents;
}

/* A row of the details is .form-field.is-inline (family 25 sets the 112 px
   caption, the 12 px gap and the caption type); master's row margin and the
   hyphens of its caption go. */
html[data-theme="minimal"] .billgen-side .billgen-meta-row {
	min-height: 32px;
	margin: 0;
}

html[data-theme="minimal"] .billgen-side .billgen-meta-label {
	hyphens: manual;
}

html[data-theme="minimal"] .billgen-side .billgen-meta-value {
	flex: 1 1 0;
	min-width: 0;
	justify-content: flex-start;
}

html[data-theme="minimal"] .billgen-side .billgen-meta-value input:not([type="checkbox"]) {
	width: 100%;
}

html[data-theme="minimal"] .billgen .billgen-mikronlist {
	flex: 0 1 auto;
	border: 0;
	border-radius: 0;
}

html[data-theme="minimal"] .billgen .billgen-mikronstats {
	text-align: left;
}

html[data-theme="minimal"] .billgen-mikronlist .ts_mikron_seperatorline {
	display: none;
}

html[data-theme="minimal"] .billgen .billgen-actions {
	margin: 0;
}

@media (max-width: 599px) {
	html[data-theme="minimal"] .billgen-head,
	html[data-theme="minimal"] .billgen-side,
	html[data-theme="minimal"] .billgen-content,
	html[data-theme="minimal"] .billgen-actions {
		padding-right: var(--space-xl);
		padding-left: var(--space-xl);
	}
}

/*------------------------------
=THE ORGANIZATIONS PAGE (UI-86, UI-89)
The page has one markup and one layout for every theme: the classic tiles of
organizations.erb (=ORGANIZATIONS PAGE of style.css). Here the tile gets the look of the
organization card of UI-86: the panel surface with a hairline and 8 px
corners, a 3 px top edge in the organization colour instead of the filled
tile, the type of the design system, and labelled shortcuts. The outer box of
the tile stays the 320 px of the classic tile (300 px and a 10 px border), so
the tiles stand at the same places as in the other themes.
------------------------------*/

/* The open invitations: a box of family 15 with a 44 px head. */
html[data-theme="minimal"] .organization-invitations {
	margin: 0 0 var(--space-3xl);
	overflow: hidden;
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background: var(--color-ui-panel);
}

html[data-theme="minimal"] .organization-invitations-title {
	margin: 0;
	padding: var(--space-lg) var(--space-xl);
	border-bottom: 1px solid var(--color-ui-panel-border);
	font-size: var(--font-size-md);
	font-weight: 600;
	line-height: 20px;
}

html[data-theme="minimal"] .organization-invitations .user-organization-dashboard-invitation {
	max-width: none;
	padding: var(--space-md) var(--space-xl);
}

html[data-theme="minimal"] .organization-invitations .user-organization-dashboard-invitation + .user-organization-dashboard-invitation {
	border-top: 1px solid var(--color-ui-panel-border);
}

/* The row of buttons takes its whole width and the buttons share it; on a
   phone they share the width (the rule for 900 px and less). */
html[data-theme="minimal"] .organization-invitations .user-organization-dashboard-invitation-actions {
	flex: 0 0 auto;
}

html[data-theme="minimal"] .organization-invitations .user-organization-dashboard-invitation-actions .button_standard {
	flex: 1 1 auto;
}

/* The tile as a card: 320 px outside, as the classic tile. */
html[data-theme="minimal"] .organization-box {
	position: relative;
	box-sizing: border-box;
	width: 320px;
	height: 320px;
	overflow: hidden;
	border: 1px solid var(--color-ui-panel-border);
	border-radius: var(--radius-lg);
	background-color: var(--color-ui-panel);
	box-shadow: none;
}

html[data-theme="minimal"] .organization-box:hover {
	opacity: 1;
}

/* The organization colour is data: a 3 px top edge only, never behind text
   (UI-86 extends the header edge of UI-55, answer 23, to this card). */
html[data-theme="minimal"] .organization-box::before {
	content: "";
	position: absolute;
	top: 0;
	right: 0;
	left: 0;
	height: 3px;
	background-color: var(--organization-color);
	pointer-events: none;
}

/* The 1 px marker line under the edge when the colour has less than 3:1 on
   the card surface (--p-ui-panel), as on the header of family 1
   (data-org-edge: org_edge_rings with ORG_CARD_SURFACE_COLORS). */
html[data-theme="minimal"]:not([data-theme-variant="dark"]) .organization-box[data-org-edge~="ring-light"]::before,
html[data-theme="minimal"][data-theme-variant="dark"] .organization-box[data-org-edge~="ring-dark"]::before {
	box-shadow: inset 0 -1px 0 var(--color-control);
}

/* The head: the 16 px of the card, plus 2 px for the edge at the top. The
   tile has a fixed height: a long text is cut in the head, never the
   shortcuts under it. */
html[data-theme="minimal"] .organization-box-mainlink {
	min-height: 0;
	overflow: hidden;
	padding: calc(var(--space-xl) + 2px) var(--space-xl) var(--space-xl);
	color: var(--color-text-primary);
}

html[data-theme="minimal"] .organization-box-mainlink:hover {
	color: var(--color-text-primary);
}

html[data-theme="minimal"] .organization-box-mainlink:hover .organization-box-name {
	text-decoration: underline;
	text-underline-offset: 3px;
}

html[data-theme="minimal"] .organization-box-mainlink:focus-visible {
	outline: 2px solid var(--color-text-primary);
	outline-offset: -2px;
}

html[data-theme="minimal"] .organization-box-name {
	margin-bottom: var(--space-2xs);
	padding-bottom: 0;
	font-size: var(--font-size-lg);
	font-weight: 600;
	line-height: 24px;
	text-align: left;
	overflow-wrap: anywhere;
	/* A long name ends after two lines with "…"; its title holds the whole name. */
	display: -webkit-box;
	overflow: hidden;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	line-clamp: 2;
}

/* The role and the members in text 2, as the line under the name of the
   card; then one count on each line. */
html[data-theme="minimal"] .organization-box-items {
	padding-top: 0;
	color: var(--color-text-primary);
	font-size: var(--font-size-sm);
	line-height: 20px;
}

html[data-theme="minimal"] .organization-box-role,
html[data-theme="minimal"] .organization-box-members {
	color: var(--color-text-secondary);
}

html[data-theme="minimal"] .organization-box-members {
	margin-bottom: var(--space-sm);
}

html[data-theme="minimal"] .organization-box-role:has(+ .organization-box-count) {
	margin-bottom: var(--space-sm);
}

html[data-theme="minimal"] .organization-box-count {
	font-variant-numeric: tabular-nums;
}

/* The shortcuts: the quiet look of family 23 with a label under the icon (the
   label of the link). The strip keeps its 60 px. */
html[data-theme="minimal"] .organization-box-shortcuts {
	flex-shrink: 0;
	box-sizing: border-box;
	gap: var(--space-3xs);
	padding: var(--space-xs) var(--space-sm);
	border-top: 1px solid var(--color-ui-panel-border);
}

html[data-theme="minimal"] .organization-box-shortcuts a {
	align-items: center;
	gap: var(--space-3xs);
	border-radius: var(--radius-md);
	background-color: transparent;
	color: var(--color-text-secondary);
	font-size: var(--font-size-xs);
	font-weight: 500;
	line-height: 16px;
	text-decoration: none;
}

html[data-theme="minimal"] .organization-box-shortcuts a::after {
	content: attr(aria-label);
}

html[data-theme="minimal"] .organization-box-shortcuts a:hover {
	background-color: var(--color-ui-hover);
	color: var(--color-text-primary);
	opacity: 1;
}

html[data-theme="minimal"] .organization-box-shortcuts a:focus-visible {
	outline: 2px solid var(--color-text-primary);
	outline-offset: -2px;
}

/* The icon of the shortcut in the ink of its label (the 16 px icons of the
   design system instead of the grey discs). */
html[data-theme="minimal"] .icon.organization-shortcut-icon {
	min-width: 16px;
	min-height: 16px;
	background-image: none;
	background-color: currentColor;
	opacity: 1;
	-webkit-mask: var(--organization-shortcut-icon) center / 16px no-repeat;
	mask: var(--organization-shortcut-icon) center / 16px no-repeat;
}

html[data-theme="minimal"] .icon.organization-shortcut-icon.manager-grey { --organization-shortcut-icon: url(/icons/ui/clock.svg); }
html[data-theme="minimal"] .icon.organization-shortcut-icon.ticket-grey { --organization-shortcut-icon: url(/icons/ui/ticket.svg); }
html[data-theme="minimal"] .icon.organization-shortcut-icon.accountant-grey { --organization-shortcut-icon: url(/icons/ui/receipt.svg); }
