/* DrawingSearch: only what MudBlazor does not give (docs/04 §1). The palette comes from the MudTheme; these are the domain colours and the few custom parts. */

h1:focus { outline: none; }
.ds-native-comparison-legend { display: flex; gap: 1rem; font-size: .85rem; }
.ds-native-comparison-legend span::before { content: ""; display: inline-block; width: 1rem; height: .2rem; margin-right: .4rem; vertical-align: middle; background: var(--ds-source); }
.ds-native-comparison-legend span + span::before { background: var(--ds-result); }

/* ---- Fonts (self-hosted; CSP font-src 'self'). Roboto files go in wwwroot/fonts when available; until then the system UI font is used. ---- */
@font-face { font-family: "Roboto"; font-weight: 400; font-style: normal; font-display: swap; src: local("Roboto"), url("fonts/roboto-400.woff2") format("woff2"); }
@font-face { font-family: "Roboto"; font-weight: 500; font-style: normal; font-display: swap; src: local("Roboto Medium"), url("fonts/roboto-500.woff2") format("woff2"); }
@font-face { font-family: "Roboto"; font-weight: 700; font-style: normal; font-display: swap; src: local("Roboto Bold"), url("fonts/roboto-700.woff2") format("woff2"); }
html, body { font-family: Roboto, "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif; }

/* ---- Domain colours (docs/04 §1): blue source, orange result; the crease is told apart by dashes as well, so colour-blind users still see it. ---- */
:root {
    --ds-source: #0099ff;
    --ds-result: #e8590c;
    --ds-difference: #a21caf;
    --ds-line: #212121;
    --ds-line-crease: #c62828;
    --ds-line-perforation: #6a1b9a;
    --ds-line-other: #757575;
    --ds-waste: #26a69a;
    --ds-highlight: #ff6f00;
    /* Small accent titles (pane headers, section titles): the light primary #0099ff is about 3:1 on white, below AA, so a darker blue. */
    --ds-title: #0067b0;
}
html[data-theme="dark"], .mud-theme-dark { --ds-title: var(--mud-palette-primary); }
html[data-theme="dark"], .mud-theme-dark {
    --ds-source: #4fc3f7;
    --ds-result: #ff8a4c;
    --ds-difference: #f0abfc;
    --ds-line: #e0e0e0;
    --ds-line-crease: #ef5350;
    --ds-line-perforation: #ce93d8;
    --ds-line-other: #9e9e9e;
    --ds-waste: #4db6ac;
    --ds-highlight: #ffb74d;
}

/* Fase 6 (Jules): every preview is black, like the PackDesign canvas, in both themes; drawing colours use the dark palette there. */
/* Jules, 7 November 2026: "all backgrounds of .M previews black", so the large viewer canvas and its rulers too (rulers in the dark workbench tones). */
.ds-thumbnail, .ds-overlay__svg, .ds-verified-svg, .ds-viewer__canvas, .ds-thumbnail__canvas { background: #000 !important; }
.ds-viewer__canvas { --ds-ruler-background: #252525; --ds-ruler-foreground: #d6d6d6; --ds-ruler-line: #464646; }
/* Jules, 19-11-2026: the mode bars of Measure and Dimension show PackDesign's dark button bitmaps, so they are dark in both themes. */
.ds-viewer { --ds-modes-background: #252525; --ds-modes-hover: #3a3a3a; --ds-modes-pressed: #1b3a57; --ds-modes-separator: #464646; }
.ds-thumbnail, .ds-overlay__svg, .ds-verified-svg, .ds-viewer__canvas, .ds-thumbnail__canvas {
    --ds-source: #4fc3f7; --ds-result: #ff8a4c; --ds-difference: #f0abfc; --ds-line: #e0e0e0; --ds-line-crease: #ef5350;
    --ds-line-perforation: #ce93d8; --ds-line-other: #9e9e9e; --ds-waste: #4db6ac; --ds-highlight: #ffb74d;
}
.ds-thumbnail__placeholder { color: #9e9e9e; }
.ds-panzoom { cursor: grab; touch-action: none; }
.ds-panzoom--dragging { cursor: grabbing; }
.ds-verified-hint { margin-left: auto; }

.ds-mono { font-family: "Roboto Mono", Consolas, "Courier New", monospace; }

/* ---- Overlay (ShapeOverlay) ---- */
.ds-overlay { display: inline-block; max-width: 100%; }
.ds-overlay__svg { display: block; width: 100%; height: 100%; }
.ds-overlay__line { fill: none; stroke-width: 1.4; vector-effect: non-scaling-stroke; stroke-linejoin: round; stroke-linecap: round; }
.ds-overlay__source { stroke: var(--ds-source); }
.ds-overlay__result { stroke: var(--ds-result); }
.ds-overlay__crease { stroke-dasharray: 5 4; }
.ds-overlay__legend { display: flex; gap: 12px; align-items: center; font-size: .75rem; color: var(--mud-palette-text-secondary); margin-top: 4px; }
.ds-overlay__swatch { display: inline-block; width: 18px; height: 0; border-top: 3px solid; margin-right: 4px; }
.ds-overlay__swatch--source { border-color: var(--ds-source); }
.ds-overlay__swatch--result { border-color: var(--ds-result); }
.ds-overlay__swatch--crease { border-color: var(--mud-palette-text-secondary); border-top-style: dashed; }
.ds-compare__side { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

/* ---- Score bands (docs/04 §2) ---- */
.ds-result { cursor: pointer; border: 1px solid var(--mud-palette-lines-default); }
.ds-result--same { border: 2px solid var(--mud-palette-primary); }
.ds-result--selected { border-color: var(--mud-palette-primary); background: var(--mud-palette-primary-hover); }
.ds-result--weak .ds-result__name, .ds-result--weak .ds-result__score { color: var(--mud-palette-text-secondary); }
.ds-result:focus-visible { outline: 3px solid var(--mud-palette-primary); outline-offset: 2px; }
.ds-result__score { font-family: "Roboto Mono", Consolas, monospace; font-weight: 500; }
/* Fase 6: verdict first, similarity second; counts, progress and filter above the list. */
.ds-result__side { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; flex-shrink: 0; }
.ds-result__similarity { font-size: .75rem; color: var(--mud-palette-text-secondary); white-space: nowrap; }
.ds-results-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 12px; padding: 4px 2px 8px; }
.ds-results-bar__progress { flex-basis: 100%; }
.ds-count--equal { color: var(--mud-palette-success); font-weight: 500; }
.ds-count--different { color: var(--mud-palette-warning); font-weight: 500; }
.ds-results { max-height: calc(100vh - 290px); overflow: auto; }
.ds-verdict-box__detail { font-size: .8rem; opacity: .9; }
.ds-chip-source { border-color: var(--ds-source) !important; color: var(--ds-source) !important; }
.ds-chip-result { border-color: var(--ds-result) !important; color: var(--ds-result) !important; }

/* ---- Scope picker ---- */
.ds-picker__card { cursor: pointer; height: 100%; }
.ds-picker__card--selected { outline: 3px solid var(--mud-palette-primary); }
.ds-picker__card:focus-visible { outline: 3px solid var(--mud-palette-primary); }

/* ---- Viewer ---- */
.ds-viewer { position: relative; display: flex; flex-direction: column; border: 1px solid var(--mud-palette-lines-default); border-radius: 4px; background: var(--mud-palette-surface); min-height: 280px; }
.ds-viewer__toolbar { display: flex; align-items: center; gap: 4px; padding: 2px 6px; border-bottom: 1px solid var(--mud-palette-lines-default); flex-wrap: wrap; }
/* The viewer's tools (spec 2026-11-13 meten en selecteren §4.1): pressed is a filled button with a line under it, never colour alone. */
.ds-viewer__sep { width: 1px; align-self: stretch; margin: 3px 2px; background: var(--mud-palette-lines-default); }
.ds-viewer__group { display: inline-flex; align-items: center; gap: 2px; }
.ds-viewer__tool--on { background: var(--mud-palette-action-default-hover); color: var(--mud-palette-primary); box-shadow: inset 0 -2px 0 var(--mud-palette-primary); }
.ds-viewer__point { min-width: 24px; height: 24px; padding: 0 4px; border: 1px solid var(--mud-palette-lines-default); border-radius: 3px; background: transparent; color: inherit; font: 600 12px/1 Roboto, Arial, sans-serif; cursor: pointer; }
.ds-viewer__point--on { border-color: var(--mud-palette-primary); background: var(--mud-palette-primary); color: var(--mud-palette-primary-text); box-shadow: inset 0 -2px 0 var(--mud-palette-primary-darken); }
.ds-viewer__point:disabled { opacity: .4; cursor: default; }
.ds-viewer__point:focus-visible { outline: 2px solid var(--mud-palette-primary); outline-offset: 1px; }
.ds-viewer__pointname { margin-left: 4px; font-size: 12px; color: var(--mud-palette-text-secondary); white-space: nowrap; }
.ds-viewer__readout { margin-left: auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; font-variant-numeric: tabular-nums; }
.ds-viewer__readout--wrap { white-space: normal; }
/* Hover, selection and measurements are drawn on a layer of their own; the module lays it over the drawing canvas. */
/* Its size follows the viewer, never a measured pixel size: a stale size after a resize stuck out of the viewer, gave the page scroll
   bars, shrank the drawing and the screen kept jumping (Jules, 18-11-2026). The canvas is the viewer's last child, under the toolbar. */
.ds-viewer__overlay { position: absolute; left: 0; top: var(--ds-overlay-top, 0px); width: 100%; height: calc(100% - var(--ds-overlay-top, 0px)); pointer-events: none; }
.ds-viewer__canvas--measure { cursor: crosshair; }
/* A finger needs more than 24 px (docs/04 §1.1: touch targets at least 36 px). */
@media (pointer: coarse) { .ds-viewer__point { min-width: 36px; height: 36px; } }
.ds-viewer__native-controls { display: flex; align-items: center; gap: 4px; padding: 2px 6px; border-bottom: 1px solid var(--mud-palette-lines-default); flex-wrap: wrap; }
.ds-viewer__legend { margin-left: auto; display: flex; gap: 4px; flex-wrap: wrap; }
.ds-viewer__canvas { display: block; flex: 1 1 0; width: 100%; min-width: 0; min-height: 0; cursor: grab; touch-action: none; outline: none; }
.ds-viewer__canvas:focus-visible { outline: 3px solid var(--mud-palette-primary); outline-offset: -3px; }
.ds-boxtree .mud-treeview-item-label { min-width: 0; overflow-wrap: anywhere; }

/* Drawing detail (docs/ontwerp/tekening-detailpagina.md): key-figure tiles, viewer about 62 %, inspector about 38 %; stacked below 1100 px. */
/* The head is the one page head (.ds-viewhead) with the path after the name; the key figures are the one stat strip (.ds-stats). */
.ds-detail__head { min-width: 0; }
.ds-detail__head .ds-path-crumbs { flex: 0 1 auto; min-width: 0; }
.ds-detail__open { display: inline-flex; flex: 0 0 auto; }
.ds-detail__open--narrow { display: none; }
/* Open in PackDesign with its arrow (Download, Download and open; docs/ontwerp/download-en-open-plan.md): one button in two parts. */
.ds-open-split { display: inline-flex; align-items: center; flex: 0 0 auto; }
.ds-open-split .ds-open-split__more { align-self: stretch; }
.ds-open-split.mud-button-group-root .ds-open-split__more .mud-icon-button { min-width: 0; padding: 0 2px; border-radius: 0 var(--mud-default-borderradius) var(--mud-default-borderradius) 0; }
/* Filled: the arrow is part of the filled button, so its icon has the button's text colour (blue on blue until hovered, Jules 12-11-2026). */
.ds-open-split--filled .ds-open-split__more .mud-icon-button { color: var(--mud-palette-primary-text) !important; background-color: var(--mud-palette-primary); }
.ds-open-split--filled .ds-open-split__more .mud-icon-button:hover { background-color: var(--mud-palette-primary-darken); }
/* Jules, 12 November 2026: no key-figure bar and no fold-out search; the panes fill the window under the head. */
.ds-page-fill > .ds-detail { margin: 8px 12px 12px; }
/* Workbench panes (PackDesign WorkbenchStyles / ActionListManager): panes touch, hairline structure, the drawing gets the flexible
   column, the inspector a remembered pixel width behind a 3 px grip with a 1 px line that turns accent on hover, drag and focus. */
.ds-detail { display: grid; grid-template-columns: minmax(420px, 1fr) 3px var(--ds-inspector-width, 400px); grid-template-rows: minmax(0, 1fr); align-items: stretch; border: 1px solid var(--mud-palette-lines-default); }
.ds-detail--collapsed { grid-template-columns: minmax(0, 1fr) 3px 36px; }
.ds-detail__viewer { min-width: 0; min-height: 0; display: flex; flex-direction: column; }
.ds-detail__viewer .ds-viewer { flex: 1 1 0; min-height: 0; border: 0; border-radius: 0; }
/* The .E files beside the drawing (Jules, 19-11-2026): the drawing keeps the room, the carousel (DrawingExternalStrip) a narrow column right of it. */
.ds-detail__main { position: relative; flex: 1 1 0; min-width: 0; min-height: 0; display: flex; flex-direction: column; }
.ds-detail__viewer--split { flex-direction: row; }
/* A .E large (ExternalDrawingDialog): the viewer fills a fixed share of the window, edge to edge. */
.ds-edialog__content { display: flex; flex-direction: column; height: min(78vh, 900px); padding: 0 !important; margin: 0 !important; }
.ds-edialog__content .ds-viewer { flex: 1 1 0; min-height: 0; border: 0; border-radius: 0; }
/* An old version in the viewer (spec 2026-11-12 §4.10): the banner with the way back sits above the drawing and keeps its own height. */
.ds-detail__version { flex: none; border-radius: 0; }
.ds-grip { display: flex; justify-content: center; cursor: col-resize; touch-action: none; outline: none; }
.ds-grip::before { content: ""; width: 1px; background: var(--mud-palette-lines-default); }
.ds-grip:hover::before, .ds-grip--dragging::before, .ds-grip:focus-visible::before { width: 3px; background: var(--mud-palette-primary); }
.ds-detail--collapsed .ds-grip { cursor: default; pointer-events: none; }
.ds-pane { display: flex; flex-direction: column; min-width: 0; min-height: 0; overflow: hidden; background: var(--mud-palette-surface); }
.ds-pane__header { flex: 0 0 auto; }
.ds-detail__inspector .mud-tabs { flex: 1 1 0; min-height: 0; display: flex; flex-direction: column; }
.ds-detail__inspector .mud-tabs-panels { flex: 1 1 0; min-height: 0; overflow: auto; }
.ds-pane__header { display: flex; align-items: center; gap: 4px; height: 32px; padding: 0 4px 0 8px; border-bottom: 1px solid var(--mud-palette-lines-default); background: var(--mud-palette-background-gray); }
.ds-pane__title { flex: 1; min-width: 0; font-size: 13px; font-weight: 600; color: var(--ds-title); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* The export dialog is laid out like PackDesign's ExportManager: page rail, black preview, settings pane (docs/07 "Exporteren"). */
.ds-export-content { padding: 0 !important; overflow: hidden; }
.ds-export { display: grid; grid-template-columns: 56px minmax(0, 1fr) 400px; height: max(480px, calc(100vh - 190px)); border-top: 1px solid var(--mud-palette-lines-default); }
.ds-export__rail { display: flex; flex-direction: column; gap: 4px; padding-top: 8px; background: var(--mud-palette-background-gray); }
.ds-export__rail-button { display: flex; align-items: center; justify-content: center; width: 56px; height: 48px; border: 0; background: transparent; color: var(--mud-palette-text-secondary); cursor: pointer; }
.ds-export__rail-button:hover { background: var(--mud-palette-action-default-hover); }
.ds-export__rail-button--active, .ds-export__rail-button--active:hover { background: #00a2e8; color: #fff; }
.ds-export__preview { display: flex; align-items: center; justify-content: center; min-width: 0; overflow: hidden; background: #000; }
.ds-export__preview img { max-width: 100%; max-height: 100%; object-fit: contain; }
.ds-export__preview iframe { width: 100%; height: 100%; border: 0; background: #525659; }
.ds-export__hint { padding: 16px; color: #9e9e9e; font-size: 13px; text-align: center; }
.ds-export__settings { border-left: 1px solid var(--mud-palette-lines-default); }
.ds-export__scroll { flex: 1; min-height: 0; overflow-y: auto; padding: 4px 10px 10px; }
.ds-export__section { margin: 12px 0 6px; color: var(--mud-palette-primary); font-size: 11px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.ds-export__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.ds-export__pair { display: grid; grid-template-columns: 1fr 96px; gap: 4px; }
.ds-export__checks { display: flex; flex-direction: column; margin-top: 4px; }
.ds-export__checks--two { display: grid; grid-template-columns: 1fr 1fr; }
.ds-export__note { margin-top: 4px; color: var(--mud-palette-text-secondary); font-size: 12px; }
.ds-export__panels .mud-expand-panel { background: transparent; border-bottom: 1px solid var(--mud-palette-lines-default); }
.ds-export__status { flex: 1; min-width: 0; padding-left: 8px; overflow: hidden; color: var(--mud-palette-text-secondary); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.ds-export__status--error { color: var(--mud-palette-error); }
@media (max-width: 900px) { .ds-export { grid-template-columns: 56px minmax(0, 1fr); } .ds-export__preview { display: none; } }
/* The folded inspector only; the .E preview beside the drawing keeps its header row. */
.ds-detail--collapsed .ds-detail__inspector > .ds-pane__header { flex-direction: column-reverse; justify-content: flex-end; height: 100%; padding: 4px 0; border-bottom: 0; }
.ds-detail--collapsed .ds-detail__inspector > .ds-pane__header > .ds-pane__title { flex: 0 0 auto; writing-mode: vertical-rl; padding: 8px 0; }
.ds-detail__inspector .mud-tabs-tabbar { border-bottom: 1px solid var(--mud-palette-lines-default); }
.ds-detail__list { min-height: 0; }
/* Workbench strip under the pane header (38 px): product and unit choice for the whole page. */
.ds-pane__strip { flex: 0 0 auto; display: flex; align-items: center; gap: 6px; min-height: 38px; padding: 3px 8px; border-bottom: 1px solid var(--mud-palette-lines-default); background: var(--mud-palette-background-gray); overflow-x: auto; }
.ds-pane__strip .mud-toggle-item { min-width: 28px; padding: 0 6px; }
/* Information pane as PackDesign's DrawingDataInformationView (Jules, 7 November 2026): vertical icon tabs on the left, a blue title,
   a search row with "select in drawing", and list rows of a colour square, an italic code, the description and an orange count. */
.ds-ddiv { flex: 1 1 0; min-height: 0; display: flex; }
.ds-ddiv__rail { flex: 0 0 40px; display: flex; flex-direction: column; align-items: stretch; gap: 1px; padding: 4px 0; overflow-y: auto; background: var(--mud-palette-background-gray); border-right: 1px solid var(--mud-palette-lines-default); }
/* Icon colours of PackDesign's SvgImageIconStyle: #7f7f7f, the primary text colour on the chosen tab (and on hover, as the Workbench tabs). */
.ds-ddiv__tab { display: flex; align-items: center; justify-content: center; height: 32px; border: 0; border-left: 3px solid transparent; background: none; color: #7f7f7f; cursor: pointer; }
.ds-ddiv__tab:hover { background: var(--mud-palette-action-default-hover); color: var(--mud-palette-text-primary); }
.ds-ddiv__tab--active { border-left-color: var(--mud-palette-primary); color: var(--mud-palette-text-primary); background: var(--mud-palette-action-default-hover); }
/* The view's own SVGs as masks: only their shape counts, so fills and strokes become one colour, as OverrideFillColor/OverrideStrokeColor do. */
.ds-ddiv__icon { display: block; width: 20px; height: 20px; background-color: currentColor; -webkit-mask-position: center; mask-position: center; -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; -webkit-mask-size: contain; mask-size: contain; }
.ds-ddiv__icon--structure { -webkit-mask-image: url("images/ddiv/Box.svg"); mask-image: url("images/ddiv/Box.svg"); }
.ds-ddiv__icon--lineTypes { -webkit-mask-image: url("images/ddiv/LINETYPES.svg"); mask-image: url("images/ddiv/LINETYPES.svg"); }
.ds-ddiv__icon--materials { -webkit-mask-image: url("images/ddiv/MATERIALS.svg"); mask-image: url("images/ddiv/MATERIALS.svg"); }
.ds-ddiv__icon--parts { -webkit-mask-image: url("images/ddiv/PARTS.svg"); mask-image: url("images/ddiv/PARTS.svg"); }
.ds-ddiv__icon--wood { -webkit-mask-image: url("images/ddiv/WOODSELECTORS.svg"); mask-image: url("images/ddiv/WOODSELECTORS.svg"); }
.ds-ddiv__icon--pointages { -webkit-mask-image: url("images/ddiv/POINTAGES.svg"); mask-image: url("images/ddiv/POINTAGES.svg"); }
.ds-ddiv__icon--bridges { -webkit-mask-image: url("images/ddiv/BRIDGES.svg"); mask-image: url("images/ddiv/BRIDGES.svg"); }
.ds-ddiv__icon--bridgeLengths { -webkit-mask-image: url("images/ddiv/BRIDGESWIDTH.svg"); mask-image: url("images/ddiv/BRIDGESWIDTH.svg"); }
.ds-ddiv__icon--ties { -webkit-mask-image: url("images/ddiv/TIES.svg"); mask-image: url("images/ddiv/TIES.svg"); }
.ds-ddiv__icon--tieSizes { -webkit-mask-image: url("images/ddiv/TIESWIDTH2.svg"); mask-image: url("images/ddiv/TIESWIDTH2.svg"); }
.ds-ddiv__icon--products { -webkit-mask-image: url("images/ddiv/Products.svg"); mask-image: url("images/ddiv/Products.svg"); }
.ds-ddiv__icon--aux { -webkit-mask-image: url("images/ddiv/Placeholder.svg"); mask-image: url("images/ddiv/Placeholder.svg"); }
.ds-ddiv__icon--lineStyles { -webkit-mask-image: url("images/ddiv/LINESTYLES.svg"); mask-image: url("images/ddiv/LINESTYLES.svg"); }
.ds-ddiv__icon--depths { -webkit-mask-image: url("images/ddiv/DEPTHS.svg"); mask-image: url("images/ddiv/DEPTHS.svg"); }
.ds-ddiv__tab:focus-visible { outline: 2px solid var(--mud-palette-primary); outline-offset: -2px; }
.ds-ddiv__separator { height: 1px; margin: 4px 6px; background: var(--mud-palette-lines-default); }
.ds-ddiv__panel { flex: 1 1 0; min-width: 0; min-height: 0; overflow: auto; padding: 5px 8px 8px; }
.ds-ddiv__title { font-size: 16px; color: var(--mud-palette-primary); margin-bottom: 4px; }
.ds-ddiv__search { display: flex; align-items: center; gap: 5px; margin-bottom: 5px; }
.ds-ddiv__search-label { color: var(--mud-palette-primary); font-size: .85rem; }
.ds-ddiv__search-box { flex: 1 1 auto; min-width: 75px; height: 24px; padding: 2px 6px; font: inherit; font-size: .85rem; color: var(--mud-palette-text-primary); background: var(--mud-palette-surface); border: 1px solid var(--mud-palette-lines-inputs); border-radius: 0; }
.ds-ddiv__search-box:focus { outline: none; border-color: var(--mud-palette-primary); }
.ds-ddiv__toggle { display: flex; align-items: center; justify-content: center; width: 28px; height: 24px; border: 1px solid var(--mud-palette-lines-inputs); background: var(--mud-palette-surface); color: var(--mud-palette-text-secondary); cursor: pointer; }
.ds-ddiv__toggle--on { border-color: var(--mud-palette-primary); color: var(--mud-palette-primary); }
.ds-ddiv__toggle:focus-visible, .ds-ddiv__eye:focus-visible { outline: 2px solid var(--mud-palette-primary); }
.ds-ddiv__list { list-style: none; margin: 0; padding: 0; }
.ds-ddiv__row { display: flex; align-items: center; gap: 7px; min-height: 24px; padding: 1px 4px; cursor: pointer; font-size: .85rem; }
.ds-ddiv__row:hover { background: var(--mud-palette-action-default-hover); }
.ds-ddiv__row--selected, .ds-ddiv__row--selected:hover { background: var(--mud-palette-primary); color: #fff; }
.ds-ddiv__row--selected .ds-ddiv__count, .ds-ddiv__row--selected .ds-ddiv__detail, .ds-ddiv__row--selected .ds-ddiv__text--missing { color: #fff; }
.ds-ddiv__swatch { flex: 0 0 15px; height: 15px; outline: 1px solid rgba(255, 255, 255, .2); }
.ds-ddiv__code { font-style: italic; white-space: nowrap; }
.ds-ddiv__text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ds-ddiv__text--missing { color: var(--mud-palette-error); }
.ds-ddiv__count { color: #ffa500; white-space: nowrap; }
.ds-ddiv__detail { margin-left: auto; min-width: 0; flex: 0 1 auto; overflow: hidden; text-overflow: ellipsis; color: var(--mud-palette-text-secondary); font-size: .75rem; white-space: nowrap; }
.ds-ddiv__row > * { flex-shrink: 0; }
.ds-ddiv__row > .ds-ddiv__text, .ds-ddiv__row > .ds-ddiv__detail { flex-shrink: 1; }
.ds-ddiv__eye { flex: 0 0 auto; display: flex; border: 0; background: none; color: inherit; cursor: pointer; padding: 0 2px; }
.ds-ddiv__eye[aria-pressed="false"] { opacity: .5; }
.ds-ddiv__empty { color: var(--mud-palette-text-secondary); font-style: italic; font-size: .85rem; padding: 4px; }
.ds-ddiv__product, .ds-product-code { font-weight: 600; }
.ds-product--D { color: #4fc3f7; } .ds-product--R { color: #ff8a4c; } .ds-product--S { color: #81c784; } .ds-product--P { color: #f06292; } .ds-product--G { color: #ffd54f; }
.ds-ddiv__panel .ds-detail__list { min-height: 0; }
/* Fact lists of the Overview tab: caption left, value right, hairlines between groups. */
.ds-facts { padding: 4px 0 8px; border-bottom: 1px solid var(--mud-palette-lines-default); }
.ds-facts__title { font-size: 12px; font-weight: 600; color: var(--mud-palette-primary); padding: 6px 0 2px; }
.ds-facts__row { display: flex; justify-content: space-between; gap: 12px; width: 100%; padding: 2px 0; font-size: .85rem; }
.ds-facts__row > :first-child { color: var(--mud-palette-text-secondary); }
.ds-facts__row > :last-child { text-align: right; font-variant-numeric: tabular-nums; }
.ds-facts__product { border: 0; background: none; color: inherit; font: inherit; font-size: .85rem; text-align: left; cursor: pointer; padding: 3px 4px; border-radius: 2px; }
.ds-facts__product:hover:not(:disabled) { background: var(--mud-palette-action-default-hover); }
.ds-facts__product:disabled { opacity: .55; cursor: default; }
.ds-facts__product--active { outline: 1px solid var(--mud-palette-primary); }
.ds-facts__product:focus-visible { outline: 2px solid var(--mud-palette-primary); }
.ds-product-code { display: inline-block; min-width: 1.4em; color: var(--mud-palette-primary); }
/* Knife table (PackDesign DieBoard window): pointage groups with subtotal and share bar, numbers right-aligned. */
.ds-knife { width: 100%; border-collapse: collapse; font-size: .8rem; font-variant-numeric: tabular-nums; }
.ds-knife th, .ds-knife td { padding: 3px 4px; border-bottom: 1px solid var(--mud-palette-lines-default); text-align: right; white-space: nowrap; }
.ds-knife th:first-child, .ds-knife td:first-child { text-align: left; white-space: normal; }
.ds-knife thead th { position: sticky; top: 0; background: var(--mud-palette-surface); font-weight: 600; z-index: 1; }
.ds-knife__pointage th, .ds-knife__pointage td { background: var(--mud-palette-background-gray); font-weight: 600; }
.ds-knife__bar { display: block; height: 4px; background: var(--mud-palette-primary); border-radius: 2px; }
.ds-knife__lt { display: inline-block; min-width: 2.2em; color: var(--mud-palette-text-secondary); }
.ds-knife tfoot th, .ds-knife tfoot td { font-weight: 600; border-bottom: 0; }
.ds-legend { display: flex; align-items: flex-start; gap: 8px; padding: 2px 0; border-bottom: 1px solid var(--mud-palette-lines-default); }
.ds-legend .mud-checkbox { min-width: 130px; }
.ds-legend__types { display: flex; flex-wrap: wrap; gap: 4px 10px; padding-top: 8px; font-size: .8rem; color: var(--mud-palette-text-secondary); }
.ds-legend__type { display: inline-flex; align-items: center; gap: 4px; }
.ds-legend__swatch { display: inline-block; width: 14px; height: 3px; border-radius: 1px; outline: 1px solid #000; }
.ds-viewer--dragging { cursor: grabbing; }
.ds-viewer__line { fill: none; stroke-width: 1.2; vector-effect: non-scaling-stroke; stroke-linejoin: round; stroke-linecap: round; }
.ds-viewer__line--cut { stroke: var(--ds-line); }
.ds-viewer__line--crease { stroke: var(--ds-line-crease); stroke-dasharray: 6 4; }
.ds-viewer__line--perforation { stroke: var(--ds-line-perforation); stroke-dasharray: 2 3; }
.ds-viewer__line--other { stroke: var(--ds-line-other); }
.ds-viewer__line--dim { opacity: .22; }
.ds-viewer__line--highlight { stroke: var(--ds-highlight); stroke-width: 2.6; stroke-dasharray: none; opacity: 1; }
.ds-viewer__waste { fill: var(--ds-waste); fill-opacity: .14; stroke: var(--ds-waste); stroke-width: 1; vector-effect: non-scaling-stroke; cursor: pointer; }
.ds-viewer__waste--inner { fill-opacity: .08; stroke-dasharray: 3 3; }
.ds-viewer__waste--selected { fill: var(--ds-highlight); fill-opacity: .45; stroke: var(--ds-highlight); stroke-width: 2; stroke-dasharray: none; }
.ds-viewer__kind[aria-pressed="true"]::before { content: ""; display: inline-block; width: 14px; border-top: 3px solid currentColor; margin-right: 6px; }

/* ---- Shell ---- */
.ds-status-chip { cursor: pointer; }
.ds-flag { font-size: .9rem; font-weight: 700; line-height: 1; letter-spacing: .04em; }
.ds-logout-form { margin: 0; }
.ds-logout-form .mud-menu-item { width: 100%; }
.ds-name-search { max-width: 440px; width: 100%; margin-left: 16px; }
.ds-name-search .mud-input-control { margin: 0; }
/* In the 40 px bar the field is 30 px high, without a floating label. */
.ds-appbar .ds-name-search .mud-input.mud-input-outlined { height: 30px; font-size: 13px; }
.ds-appbar .ds-name-search .mud-input-outlined .mud-input-slot { padding-top: 4px; padding-bottom: 4px; }
.ds-appbar .ds-name-search .mud-input-adornment .mud-icon-root { font-size: 18px; }
.ds-appbar .ds-name-search input::placeholder { color: rgba(255, 255, 255, .75); opacity: 1; }
.ds-name-search .mud-input, .ds-name-search .mud-input-slot, .ds-name-search input { color: #fff !important; }
.ds-name-search .mud-input-outlined-border { border-color: rgba(255, 255, 255, .55) !important; }
.ds-name-search--page .mud-input, .ds-name-search--page .mud-input-slot, .ds-name-search--page input { color: inherit !important; }
.ds-name-search--page .mud-input-outlined-border { border-color: var(--mud-palette-lines-inputs) !important; }
.ds-name-search--page { max-width: none; margin-left: 0; }
/* MudMainContent is border-box with the app-bar height as padding-top, so 100vh already leaves room for the bar (fase-6 A1). */
.ds-main { min-height: 100vh; display: flex; flex-direction: column; padding-bottom: var(--ds-bottomnav-h); }
/* The browse page fills the window below the app bar, edge to edge (no footer and no page margins since 12 November 2026). */
:root { --ds-browse-height: calc(100vh - var(--mud-appbar-height)); --ds-browse-height: calc(100dvh - var(--mud-appbar-height)); }
.ds-page { padding: 12px 16px; }
.ds-main__body > .ds-page:has(> .ds-browse) { padding: 0; }
.ds-main:has(.ds-browse--wide) { height: 100vh; height: 100dvh; min-height: 0; overflow: hidden; }

/* Shell, dense like the Workbench: 40 px app bar, a hairline under it, the navigation pane with 28 px rows and small section titles. */
.ds-appbar.mud-appbar { border-bottom: 1px solid rgba(0, 0, 0, .18); }
/* Installed on a phone with a notch (spec 2026-11-18 §4.3): the toolbar starts below the top inset. The inset is part of --mud-appbar-height (DrawingSearchTheme),
   so the main content, the browse height and the bell panel move down with it; MudBlazor makes the toolbar 7/8 of that height on a portrait phone. */
.ds-appbar .mud-toolbar { gap: 4px; box-sizing: border-box; padding: env(safe-area-inset-top, 0px) max(8px, env(safe-area-inset-right)) 0 max(8px, env(safe-area-inset-left)); }
.ds-appbar .mud-icon-button { padding: 6px; }
.ds-drawer.mud-drawer { border-right: 1px solid var(--mud-palette-lines-default); }
.ds-nav .mud-nav-link { min-height: 28px; padding: 3px 12px 3px 14px; font-size: 12.5px; }
.ds-nav .mud-nav-link .mud-nav-link-icon { font-size: 18px; }
.ds-nav .mud-nav-link .mud-nav-link-text { margin-left: 10px; }
.ds-nav .mud-nav-link.active:not(.mud-nav-link-disabled) { box-shadow: inset 3px 0 0 var(--mud-palette-primary); }
.ds-nav .mud-divider { margin: 4px 0; }
.ds-nav__section { display: block; padding: 8px 14px 2px; font-size: 11px !important; font-weight: 600; letter-spacing: .02em; text-transform: none; color: var(--ds-title); }
/* ==== The one style (docs/04 §1.2; Jules, 12 November 2026: "one style so everything looks the same") ====
   Every page: a page head (.ds-viewhead, PageHeader.razor), then a body with 12/16 px padding and 12 px between parts. Content is grouped in
   panes (.ds-pane--box, Pane.razor: 32 px header, accent title, hairline border), tool strips are 38 px (.ds-pane__strip, .ds-querybar),
   key figures are one stat strip (.ds-stats/.ds-stat) and every list is one dense table (.ds-table, columns resizable). */
.ds-main__body > .ds-page:has(> .ds-view), .ds-main__body > .ds-page:has(> .ds-page-fill) { padding: 0; }
.ds-view { display: flex; flex-direction: column; min-width: 0; }
.ds-viewhead { flex: 0 0 auto; display: flex; align-items: center; gap: 8px; min-width: 0; min-height: 40px; padding: 4px 12px 4px 14px;
               background: var(--mud-palette-background-gray); border-bottom: 1px solid var(--mud-palette-lines-default); }
.ds-viewhead__icon { flex: 0 0 auto; color: var(--ds-title); font-size: 18px !important; }
.ds-viewhead__title { flex: 0 1 auto; min-width: 0; margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; font-weight: 600; line-height: 1.3; }
.ds-viewhead__spacer { flex: 1 1 auto; }
.ds-viewhead__actions { flex: 0 0 auto; display: flex; align-items: center; gap: 4px; }
.ds-viewhead__sep { flex: 0 0 auto; width: 1px; height: 20px; margin: 0 4px; background: var(--mud-palette-lines-default); }
.ds-viewhead > .mud-button-root.mud-button { flex: 0 0 auto; height: 28px; padding: 0 8px; font-weight: 400; color: var(--mud-palette-text-primary); }
.ds-viewhead > .mud-button-root.mud-button .mud-icon-root { font-size: 18px; }
.ds-viewhead .mud-chip { margin: 0; }
.ds-viewhead__back.mud-icon-button { padding: 3px; margin-left: -4px; }
.ds-viewhead .mud-breadcrumbs { flex: 0 1 auto; min-width: 0; padding: 0 0 0 6px; flex-wrap: nowrap; overflow: hidden; white-space: nowrap; font-size: 12px; border-left: 1px solid var(--mud-palette-lines-default); }
.ds-viewhead .mud-breadcrumb-item > a, .ds-viewhead .mud-breadcrumb-item { padding: 0 2px; color: var(--mud-palette-text-secondary); }
.ds-viewhead .mud-breadcrumb-item > a:hover { color: var(--mud-palette-primary); text-decoration: none; }
.ds-viewhead .mud-breadcrumb-item .mud-icon-root { font-size: 14px; margin-right: 2px; }
.ds-viewhead .mud-breadcrumb-separator { padding: 0 1px; }
/* The file's name is the title right before the path, so the path stops at its folder. */
.ds-viewhead .ds-path-crumbs--file > li:nth-last-child(-n+2) { display: none; }
.ds-view__body { display: flex; flex-direction: column; gap: 12px; min-width: 0; padding: 12px 16px; }
.ds-view__body--columns { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(420px, 100%), 1fr)); align-items: start; }
.ds-view__body > .mud-alert { margin: 0; }
.ds-pane--box { border: 1px solid var(--mud-palette-lines-default); border-radius: 3px; }
.ds-pane__body { padding: 10px 12px; min-width: 0; }
.ds-pane__body--flush { padding: 0; }
.ds-pane__header .mud-button-root.mud-button { height: 26px; padding: 0 8px; }
.ds-pane__header .mud-chip { margin: 0; }
.ds-pane__header > a.ds-pane__title { text-decoration: none; }
.ds-pane__header > a.ds-pane__title:hover { text-decoration: underline; }
/* Choices in a tool strip (Jules, 13-11-2026: Browse's filters were twice the toolbar's height): a segmented strip of 26 px buttons that looks
   like the toolbar's List | Compact | Tiles. The chosen one is filled and medium weight, so it is not colour alone. Plain buttons with
   aria-pressed instead of MudToggleGroup, which has no item for "no choice" (null). */
.ds-seg { display: inline-flex; min-width: 0; }
.ds-seg__item { display: inline-flex; align-items: center; height: 26px; margin: 0 0 0 -1px; padding: 0 8px; border: 1px solid var(--mud-palette-lines-inputs);
                border-radius: 0; background: none; color: var(--mud-palette-text-primary); font: inherit; font-size: 12.5px; white-space: nowrap; cursor: pointer; }
.ds-seg__item:first-child { margin-left: 0; border-radius: 3px 0 0 3px; }
.ds-seg__item:last-child { border-radius: 0 3px 3px 0; }
.ds-seg__item:hover { background: var(--mud-palette-action-default-hover); }
.ds-seg__item--on, .ds-seg__item--on:hover { position: relative; border-color: var(--mud-palette-primary); background: var(--mud-palette-primary); color: var(--mud-palette-primary-text); font-weight: 500; }
.ds-seg__item:focus-visible { position: relative; z-index: 1; outline: 2px solid var(--mud-palette-primary); outline-offset: 1px; }
/* A field in a tool strip: 28 px and 12.5 px (Browse's address row and filter panel, the notifications strip). On the field itself or on a
   wrapper round it, for components such as MudSelect that do not put their Class on the input control. */
.ds-field-dense.mud-input-control, .ds-field-dense .mud-input-control { margin: 0; }
.ds-field-dense .mud-input.mud-input-outlined { height: 28px; font-size: 12.5px; background: var(--mud-palette-background); }
.ds-field-dense .mud-input-outlined .mud-input-slot { padding-top: 3px; padding-bottom: 3px; }
.ds-field-dense .mud-input-adornment .mud-icon-root { font-size: 17px; }
.ds-stats { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(110px, 1fr); overflow-x: auto; background: var(--mud-palette-surface);
            border: 1px solid var(--mud-palette-lines-default); border-radius: 3px; scrollbar-width: thin; }
.ds-stat { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 1px; min-width: 0; min-height: 44px; padding: 4px 12px;
           border: 0; border-right: 1px solid var(--mud-palette-lines-default); background: none; color: var(--mud-palette-text-primary); font: inherit; text-align: left; }
.ds-stat:last-child { border-right: 0; }
.ds-stat--wide { grid-column: span 2; }
button.ds-stat { cursor: pointer; }
button.ds-stat:hover { background: var(--mud-palette-action-default-hover); }
button.ds-stat:focus-visible { outline: 2px solid var(--mud-palette-primary); outline-offset: -2px; }
.ds-stat__label { font-size: 10.5px; letter-spacing: .04em; text-transform: uppercase; color: var(--mud-palette-text-secondary); white-space: nowrap; }
.ds-stat__value { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13.5px; font-weight: 600; font-variant-numeric: tabular-nums; }
.ds-stat__value .mud-chip { margin: 0; }
/* Phones: the key figures in two columns instead of a row that scrolls sideways (the compact drawing page has its own sheet row). */
@media (max-width: 599.98px) {
    .ds-stats { grid-auto-flow: row; grid-template-columns: repeat(2, minmax(0, 1fr)); overflow: visible; }
    .ds-stats .ds-stat { border-bottom: 1px solid var(--mud-palette-lines-default); }
    .ds-stats .ds-stat:nth-child(2n) { border-right: 0; }
    .ds-stat--wide { grid-column: span 2; }
    .ds-view__body { padding: 10px 8px; gap: 10px; }
    .ds-viewhead { padding-left: 10px; padding-right: 8px; }
    .ds-querybar { padding: 4px 8px; gap: 6px 10px; }
    .ds-filters > .ds-filters__field { flex: 1 1 100%; }
    .ds-search .ds-results { max-height: 50vh; }
    /* The title gets the head; the path is a click away in the page itself (and on the drawing page the head is not shown at all). */
    .ds-viewhead .mud-breadcrumbs { display: none; }
    /* MudBlazor stacks a table into label/value rows here; values wrap instead of being cut off. */
    .ds-table .mud-table-body .mud-table-cell { height: auto; min-height: 30px; white-space: normal; overflow-wrap: anywhere; }
    .ds-table .mud-table-body .mud-table-cell .ds-truncate { max-width: 100%; white-space: normal; }
    .ds-audit__details { max-width: none; white-space: normal; overflow-wrap: anywhere; }
}
.ds-querybar { flex: 0 0 auto; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; min-height: 38px; padding: 3px 14px;
               background: var(--mud-palette-surface); border-bottom: 1px solid var(--mud-palette-lines-default); }
.ds-querybar .mud-switch { margin: 0; }
.ds-search, .ds-compare { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 12px; align-items: start; }
.ds-compare { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.ds-compare .ds-viewer { border: 0; border-radius: 0; }
/* Below 960 px the two panes stack: results above the chosen result, source above the result drawing. */
@media (max-width: 959.98px) { .ds-search, .ds-compare { grid-template-columns: minmax(0, 1fr); } }
.ds-search .ds-results { max-height: calc(100vh - 240px); }
.ds-search .ds-results-bar { padding: 3px 10px; }
.ds-search .ds-result { border-width: 0 0 1px; border-radius: 0; }
.ds-filters { flex-wrap: wrap; gap: 8px; padding-top: 6px; padding-bottom: 6px; }
.ds-filters .mud-input-control { margin: 0; }
.ds-filters__field { flex: 0 1 200px; min-width: 150px; }
.ds-filters__field--wide { flex-basis: 260px; }
/* A date range is two inputs and a separator in one field; it keeps room for both. */
.ds-filters__field--range { flex: 0 1 300px; }
.ds-pane__strip.ds-filters { overflow: visible; }
/* Field heights in strips: 32 px instead of MudBlazor's 40, so a strip of fields stays one tool strip high. */
.ds-filters .mud-input.mud-input-outlined { font-size: 13px; }
.ds-filters .mud-input-outlined .mud-input-slot { padding-top: 6px; padding-bottom: 6px; }
.ds-form .mud-input-control { margin-top: 0; }
/* MudForm is a flex column; a button keeps its own width there, as everywhere else. */
.ds-form > .mud-button-root { align-self: flex-start; }
/* The one table: Explorer's density for every MudTable/MudDataGrid with .ds-table (the file list has the same look as .ds-filegrid). */
.ds-table.mud-table { border-radius: 0; box-shadow: none; background: var(--mud-palette-surface); }
.ds-table .mud-table-head .mud-table-cell { height: 28px; padding: 0 8px; font-size: 12px; font-weight: 400; color: var(--mud-palette-text-secondary); background: var(--mud-palette-surface); border-bottom: 1px solid var(--mud-palette-lines-default); }
.ds-table .mud-table-head .mud-table-cell:not(:last-child) { border-right: 1px solid var(--mud-palette-divider-light); }
.ds-table .mud-table-body .mud-table-cell { height: 26px; padding: 2px 8px; font-size: 12.5px; border-bottom: 1px solid var(--mud-palette-divider-light); }
.ds-table .mud-table-body .mud-table-row:hover > td { background: var(--mud-palette-action-default-hover); }
.ds-table .mud-table-cell .mud-chip { height: 18px; margin: 0; font-size: 10.5px; }
.ds-table .mud-table-cell .mud-typography { font-size: inherit; }
.ds-table .mud-icon-button { padding: 3px; }
.ds-table .mud-resizer:hover, .ds-table .mud-resizer.mud-resizing { border-right: 2px solid var(--mud-palette-primary); }
.ds-table .mud-table-pagination { min-height: 32px; font-size: 12px; border-top: 1px solid var(--mud-palette-lines-default); }
.ds-table .mud-table-pagination-toolbar { min-height: 32px; height: 32px; }

/* The one dialog: a pane that floats (title bar as the page head, hairlines, actions in a strip at the foot). */
.mud-dialog { border: 1px solid var(--mud-palette-lines-default); border-radius: 3px; }
.mud-dialog .mud-dialog-title { min-height: 40px; padding: 8px 14px; background: var(--mud-palette-background-gray); border-bottom: 1px solid var(--mud-palette-lines-default); }
.mud-dialog .mud-dialog-title .mud-typography-h6 { font-size: 14px; font-weight: 600; }
.mud-dialog .mud-dialog-title .mud-button-close { top: 4px; right: 6px; padding: 6px; }
.mud-dialog .mud-dialog-content { padding: 12px 16px; }
.mud-dialog .mud-dialog-actions { padding: 6px 12px; gap: 6px; border-top: 1px solid var(--mud-palette-lines-default); }
.mud-popover .mud-list-item, .mud-menu-list .mud-list-item { min-height: 30px; padding-top: 3px; padding-bottom: 3px; font-size: 12.5px; }

/* The empty shape search: recent searches and the upload side by side, as Workbench panes. */
.ds-search-start { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(420px, 100%), 1fr)); gap: 12px; }
.ds-recent .mud-list-item { padding-top: 2px; padding-bottom: 2px; }
/* Audit log (fase-6 E1): long targets and JSON details stay on one line inside the table. */
.ds-nowrap { white-space: nowrap; }
.ds-truncate { display: inline-block; max-width: 340px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: middle; }
/* A percentage would follow the cell, which grows with the text; the window width (minus drawer and margins) bounds it. */
.ds-audit__details { max-width: calc(100vw - 340px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .75rem; color: var(--mud-palette-text-secondary); padding: 0 16px 6px; }
/* ---- File browser (docs/ontwerp/bestandsbrowser-volwaardig.md §4): wide = tree beside the list, compact and phone = the list alone ----
   Explorer in the Workbench style (Jules, 12 November 2026): the head (tabs, address row, tool strip) spans the window; below it the panes
   touch with hairlines between them, the list is the flexible column, and the whole page is one window high with scrolling inside the panes. */
.ds-browse { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0; }
.ds-browse__head { grid-column: 1 / -1; grid-row: 1; min-width: 0; }
.ds-browse > :not(.ds-browse__head) { grid-row: 2; }
.ds-browse--wide { grid-template-columns: auto minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); height: var(--ds-browse-height); }
/* The preview pane (bestandsbrowser stap 7): a third column of a fixed share, one window high like the others. */
.ds-browse--wide.ds-browse--preview { grid-template-columns: auto minmax(0, 1fr) clamp(260px, 22vw, 380px); }
.ds-browse__preview { min-height: 0; overflow-y: auto; box-sizing: border-box; border-left: 1px solid var(--mud-palette-lines-default); background: var(--mud-palette-surface); }
/* Three columns on a laptop: the tree starts narrower so the list keeps room (it can still be dragged wider). */
@media (max-width: 1599.98px) { .ds-browse--wide.ds-browse--preview .ds-folder-pane { width: 220px; } }
.ds-preview { display: flex; flex-direction: column; gap: 8px; padding: 8px 12px 12px; }
.ds-preview__head { display: flex; align-items: center; justify-content: space-between; }
.ds-preview__name { overflow-wrap: anywhere; font-weight: 500; }
.ds-preview__facts { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 2px 12px; margin: 0; font-size: .85rem; }
.ds-preview__facts dt { color: var(--mud-palette-text-secondary); }
.ds-preview__facts dd { margin: 0; overflow-wrap: anywhere; }
.ds-preview__folder { font-family: monospace; font-size: .78rem; }
.ds-preview__actions { display: flex; flex-wrap: wrap; gap: 6px; }
.ds-preview__empty { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 32px 8px; text-align: center; color: var(--mud-palette-text-secondary); }
.ds-bsheet--preview .ds-sheet-body { padding-top: 4px; }
.ds-browse__tree { min-width: 0; min-height: 0; display: flex; }
/* The tree can be made wider or narrower with its corner grip (CSS resize, no script) and folded away to a strip. */
.ds-browse--wide .ds-folder-pane { width: 260px; min-width: 180px; max-width: 45vw; height: 100%; overflow: auto; resize: horizontal; box-sizing: border-box;
                                   border-right: 1px solid var(--mud-palette-lines-default); background: var(--mud-palette-surface); }
.ds-folder-pane .ds-pane__header { position: sticky; top: 0; z-index: 2; }
.ds-folder-pane__tree { padding: 2px 0; }
.ds-folder-pane__section { padding: 8px 10px 2px; font-size: 11px; font-weight: 600; color: var(--ds-title); }
.ds-folder-pane .ds-pathlist { padding: 0 2px 6px; }
.ds-tree-strip { display: flex; flex-direction: column; align-items: center; padding-top: 4px; border-right: 1px solid var(--mud-palette-lines-default); background: var(--mud-palette-surface); }
.ds-browse-main { min-width: 0; display: flex; flex-direction: column; }
.ds-browse-files { display: flex; flex-direction: column; min-height: 120px; }
/* One window high; when the open filter panel leaves too little room for the list, the column scrolls instead of running over the window. */
.ds-browse--wide .ds-browse-main { min-height: 0; overflow-y: auto; background: var(--mud-palette-surface); }
.ds-browse--wide .ds-browse-files { flex: 1 1 0; min-height: 240px; }
/* A long folder list scrolls in its own box instead of pushing the drawings below the window. */
.ds-browse--wide .ds-browse-main > :not(.ds-browse-files) { flex: 0 0 auto; }
.ds-browse--wide .ds-folders { max-height: 34vh; overflow-y: auto; }
/* A folder with only subfolders: the folder rows get the whole column, the hint under them takes only its own height. */
.ds-browse--wide .ds-browse-main:has(.ds-browse-files > .mud-alert) .ds-folders { max-height: none; }
.ds-browse--wide .ds-browse-files:has(> .mud-alert) { flex: 1 1 auto; min-height: 0; }
.ds-browse--wide .ds-browse-files > .ds-filegrid, .ds-browse--wide .ds-browse-files > .ds-tile-viewport { flex: 1 1 0; min-height: 0; }
.ds-browse--wide .ds-browse-files > .ds-tiles { overflow-y: auto; }
.ds-browse:not(.ds-browse--wide) .ds-browse-files > .ds-filegrid, .ds-browse:not(.ds-browse--wide) .ds-browse-files > .ds-tile-viewport { height: 70vh; }
/* Room under the list for the floating button and the bars that float over the bottom of the screen. */
.ds-browse--phone, .ds-browse--compact { padding-bottom: 84px; }

/* The head: tab strip (32 px), address row (36 px), tool strip (38 px), all on the Workbench header grey with hairlines. */
.ds-whead { display: flex; flex-direction: column; background: var(--mud-palette-background-gray); border-bottom: 1px solid var(--mud-palette-lines-default); }
.ds-tabs { display: flex; align-items: flex-end; gap: 1px; height: 32px; padding: 0 6px; overflow-x: auto; overflow-y: hidden; scrollbar-width: none; }
.ds-tab { flex: 0 1 200px; min-width: 96px; display: flex; align-items: center; height: 28px; border: 1px solid transparent; border-bottom: 0; border-radius: 4px 4px 0 0; color: var(--mud-palette-text-secondary); }
.ds-tab:hover { background: var(--mud-palette-action-default-hover); }
.ds-tab--active, .ds-tab--active:hover { color: var(--mud-palette-text-primary); background: var(--mud-palette-surface); border-color: var(--mud-palette-lines-default); box-shadow: inset 0 2px 0 var(--mud-palette-primary); }
.ds-tab__btn { flex: 1; min-width: 0; display: flex; align-items: center; gap: 6px; height: 100%; padding: 0 4px 0 10px; border: 0; background: none; color: inherit; font: inherit; font-size: 12px; text-align: left; cursor: pointer; }
.ds-tab__icon { color: #e8a317; font-size: 16px !important; }
.ds-tab__name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ds-tab__close, .ds-tab__new { flex: 0 0 auto; display: grid; place-items: center; width: 22px; height: 22px; margin-right: 3px; padding: 0; border: 0; border-radius: 3px; background: none; color: inherit; cursor: pointer; }
.ds-tab__close .mud-icon-root, .ds-tab__new .mud-icon-root { font-size: 15px; }
.ds-tab__close:hover, .ds-tab__new:hover { background: var(--mud-palette-action-default-hover); color: var(--mud-palette-text-primary); }
.ds-tab__new { align-self: center; margin-left: 2px; color: var(--mud-palette-text-secondary); }
.ds-tab__btn:focus-visible, .ds-tab__close:focus-visible, .ds-tab__new:focus-visible { outline: 2px solid var(--mud-palette-primary); outline-offset: -2px; }
.ds-crumbrow { display: flex; align-items: center; gap: 2px; min-width: 0; min-height: 36px; padding: 2px 8px; background: var(--mud-palette-surface); border-top: 1px solid var(--mud-palette-lines-default); }
.ds-addressbox { flex: 1 1 auto; min-width: 0; display: flex; align-items: center; height: 28px; margin: 0 6px 0 4px; padding: 0 2px 0 8px; border: 1px solid var(--mud-palette-lines-default); border-radius: 3px; background: var(--mud-palette-background); }
.ds-addressbox:hover { border-color: var(--mud-palette-lines-inputs); }
.ds-addressbox:focus-within { border-color: var(--mud-palette-primary); }
.ds-crumbs { flex: 0 1 auto; min-width: 0; }
.ds-addressbox .ds-crumbs:has(.ds-address) { flex: 1 1 auto; }
.ds-addressbox__edit { flex: 1 1 24px; align-self: stretch; min-width: 24px; padding: 0; border: 0; background: none; cursor: text; }
.ds-addressbox__edit:focus-visible { outline: 2px solid var(--mud-palette-primary); outline-offset: -2px; }
.ds-addressbox .mud-breadcrumbs { flex-wrap: nowrap; overflow: hidden; white-space: nowrap; font-size: 12.5px; }
.ds-addressbox .mud-breadcrumb-item > a, .ds-addressbox .mud-breadcrumb-item { padding: 1px 3px; border-radius: 2px; color: var(--mud-palette-text-primary); }
.ds-addressbox .mud-breadcrumb-item > a:hover { background: var(--mud-palette-action-default-hover); text-decoration: none; }
.ds-addressbox .mud-breadcrumb-separator { padding: 0 1px; color: var(--mud-palette-text-secondary); }
.ds-addressbox .mud-breadcrumb-item .mud-icon-root { font-size: 15px; margin-right: 3px; }
.ds-addressbox__star.mud-icon-button { padding: 3px; }
.ds-cmdbar { display: flex; align-items: center; gap: 1px; min-height: 38px; padding: 3px 8px; overflow-x: auto; scrollbar-width: none; background: var(--mud-palette-surface); border-top: 1px solid var(--mud-palette-lines-default); }
.ds-cmdbar > * { flex: 0 0 auto; }
.ds-cmdbar .mud-button-root.mud-button { min-width: 0; height: 28px; padding: 0 8px; font-weight: 400; color: var(--mud-palette-text-primary); }
.ds-cmdbar .mud-button-text-primary { color: var(--mud-palette-primary) !important; }
.ds-cmdbar .mud-icon-button { padding: 5px; border-radius: 3px; }
.ds-cmdbar .mud-icon-button .mud-icon-root, .ds-cmdbar .mud-button .mud-icon-root { font-size: 18px; }
.ds-cmdbar__sep { width: 1px; height: 20px; margin: 0 6px; background: var(--mud-palette-lines-default); }
.ds-cmdbar__spacer { flex: 1 1 auto; min-width: 8px; }
.ds-cmdbar__note { padding: 0 6px; font-size: 12px; color: var(--mud-palette-text-secondary); white-space: nowrap; }
.ds-cmdbar .mud-toggle-group { height: 28px; }
.ds-cmdbar .mud-toggle-item { min-width: 30px; padding: 0 6px; font-size: 12px; }
.ds-cmdbar__switch { margin: 0 0 0 6px !important; }
.ds-cmdbar__switch .mud-typography { font-size: 12px; white-space: nowrap; }
.ds-cmdbar .mud-badge.mud-badge-overlap { font-size: 10px; height: 16px; min-width: 16px; padding: 0 4px; inset: auto auto calc(100% - 14px) calc(100% - 14px) !important; }
.ds-filterstrip { padding: 5px 10px; background: var(--mud-palette-surface); border-top: 1px solid var(--mud-palette-lines-default); }
.ds-viewrow, .ds-fs-toolbar, .ds-contextbar { gap: 8px; }
.ds-contextbar { display: flex; flex-wrap: wrap; align-items: center; margin: 0; padding: 2px 8px 2px 2px; background: color-mix(in srgb, var(--mud-palette-primary) 14%, var(--mud-palette-surface)); border-top: 1px solid var(--mud-palette-lines-default); }
.ds-activefilters { padding: 4px 10px 0; }
/* Explorer's status bar: one 24 px line with the counts and the selection under the list. */
.ds-statusline { flex: 0 0 auto; display: flex; align-items: center; min-height: 24px; padding: 0 10px; font-size: 12px; color: var(--mud-palette-text-secondary); border-top: 1px solid var(--mud-palette-lines-default); background: var(--mud-palette-background-gray); }
.ds-browse-main > .mud-alert { margin: 8px 10px; }
.ds-browse-files > .mud-alert { margin: 8px 10px; }
.ds-browse-files > .mud-progress-linear { margin: 0; }

/* The details list: Explorer row heights (26 px compact, 28 px with a header), 12 px headers, hairline rows, a tint for selection. */
.ds-filegrid.mud-table { border-radius: 0; box-shadow: none; background: var(--mud-palette-surface); }
.ds-filegrid .mud-table-head .mud-table-cell { height: 28px; padding: 0 8px; font-size: 12px; font-weight: 400; color: var(--mud-palette-text-secondary); background: var(--mud-palette-surface); border-bottom: 1px solid var(--mud-palette-lines-default); }
.ds-filegrid .mud-table-head .mud-table-cell:not(:last-child) { border-right: 1px solid var(--mud-palette-divider-light); }
.ds-filegrid .mud-table-body .mud-table-cell { padding: 3px 8px; font-size: 12.5px; border-bottom: 1px solid var(--mud-palette-divider-light); }
.ds-filegrid--compact .mud-table-body .mud-table-cell { height: 26px; padding-top: 0; padding-bottom: 0; }
.ds-filegrid .mud-table-body .mud-table-row:hover > td { background: var(--mud-palette-action-default-hover); }
.ds-filegrid .ds-sort-header { font-weight: 400; }
/* A column head can be dragged onto another (grid-columns.js); the head it would land on shows an accent bar on its left. */
.ds-filegrid .ds-colhead { display: inline-flex; align-items: center; max-width: 100%; cursor: grab; user-select: none; }
.ds-filegrid .ds-colhead:active { cursor: grabbing; }
.ds-filegrid th.ds-col-drop { box-shadow: inset 3px 0 0 var(--mud-palette-primary); background: color-mix(in srgb, var(--mud-palette-primary) 12%, transparent) !important; }
/* The column grip: a hairline that turns accent on hover, like the Workbench splitter. */
.ds-filegrid .mud-resizer:hover, .ds-filegrid .mud-resizer.mud-resizing { border-right: 2px solid var(--mud-palette-primary); }
/* MudLink paints its colour with !important (mud-primary-text); a file name reads as text, as in Explorer, and turns accent on hover. */
.ds-filegrid .ds-filename.mud-link { color: var(--mud-palette-text-primary) !important; }
.ds-filegrid .ds-filename.mud-link:hover { color: var(--mud-palette-primary) !important; }
.ds-filegrid .mud-icon-button { padding: 3px; }
.ds-filegrid .mud-icon-button .mud-icon-root { font-size: 18px; }
/* The action columns (Open in PackDesign, Download and open, the row menu): one icon button wide, the head an icon (download-en-open-plan.md). */
.ds-filegrid .mud-table-cell.ds-actioncol { width: 36px; padding-left: 4px; padding-right: 4px; text-align: center; }
.ds-filegrid .mud-table-head .mud-table-cell.ds-actioncol .mud-icon-root { font-size: 16px; vertical-align: middle; }
.ds-filegrid .ds-select, .ds-tile .ds-select { width: 14px; height: 14px; margin: 0; accent-color: var(--mud-palette-primary); }
.ds-filegrid .mud-table-cell .mud-chip { height: 18px; font-size: 10.5px; }

/* Tiles of a small folder: as many columns as fit the chosen tile width. */
.ds-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(var(--ds-tile-min, 280px), 100%), 1fr)); gap: 8px; align-content: start; padding: 8px; }
.ds-tile-wrap { height: 100%; }
.ds-tile--selected { outline: 2px solid var(--mud-palette-primary); outline-offset: -2px; }
.ds-tile__name { overflow-wrap: anywhere; }
.ds-tile.mud-card { border-radius: 3px; }
.ds-tile.mud-card:hover { border-color: var(--mud-palette-lines-inputs); }
.ds-tile .mud-card-content { padding: 6px 8px 8px; }
.ds-tile .mud-icon-button { padding: 3px; }
.ds-tile .mud-chip { height: 18px; font-size: 10.5px; margin: 4px 0 0; }

/* Phone: the folder title bar and the count line, then rows. */
.ds-mhead { display: flex; align-items: center; gap: 2px; min-height: 48px; }
/* A tint with the normal text colour: white on the light blue of the dark theme is about 2:1, below AA. */
.ds-mhead--selecting { padding-right: 8px; border-radius: 8px; box-shadow: inset 3px 0 0 var(--mud-palette-primary); background: color-mix(in srgb, var(--mud-palette-primary) 24%, var(--mud-palette-surface)); }
.ds-mhead__title { flex: 1; min-width: 0; }
.ds-mhead__folder { flex: 1; min-width: 0; display: flex; align-items: center; gap: 2px; justify-content: flex-start; min-height: 44px; padding: 0 4px; border: 0; border-radius: 6px; background: none; color: inherit; font: inherit; font-size: 1.1rem; font-weight: 500; text-align: left; cursor: pointer; }
.ds-mhead__folder:focus-visible { outline: 2px solid var(--mud-palette-primary); }
.ds-mhead__name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ds-mbar { display: flex; align-items: center; gap: 4px; margin-bottom: 4px; }
.ds-mbar__count { flex: 1; min-width: 0; display: block; min-height: 40px; padding: 0 4px; border: 0; background: none; color: var(--mud-palette-text-secondary); font: inherit; font-size: .85rem; text-align: left; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; cursor: pointer; }
.ds-browse--phone .ds-statusline { display: none; }
.ds-browse--phone .ds-folders { grid-template-columns: minmax(0, 1fr); gap: 0; border-top: 1px solid var(--mud-palette-lines-default); }
.ds-browse--phone .ds-folder-item { min-height: 52px; border-width: 0 0 1px; border-radius: 0; }
.ds-browse--phone .ds-subfolder { min-height: 52px; padding: 0 8px; font-size: .95rem; }
.ds-folder-item__go { color: var(--mud-palette-text-secondary); }
.ds-browse--phone .ds-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.ds-browse--phone .ds-tile .mud-card-content { padding: 8px; }
.ds-frows { display: flex; flex-direction: column; border-top: 1px solid var(--mud-palette-lines-default); }
.ds-frow { display: flex; align-items: center; gap: 8px; min-height: 80px; padding-left: 4px; border-bottom: 1px solid var(--mud-palette-lines-default); }
.ds-frows--compact .ds-frow { min-height: 52px; }
.ds-frow--selected { background: color-mix(in srgb, var(--mud-palette-primary) 16%, transparent); }
.ds-frow--placeholder { min-height: 80px; }
.ds-frow__open { flex: 1; min-width: 0; display: flex; align-items: center; justify-content: flex-start; gap: 12px; padding: 8px 0; border: 0; background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.ds-frow__open:focus-visible { outline: 2px solid var(--mud-palette-primary); outline-offset: -2px; }
.ds-frow__thumb { flex: 0 0 72px; width: 72px; }
.ds-frow__text { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.ds-frow__name { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; font-size: .95rem; font-weight: 500; }
.ds-frow__meta { font-size: .78rem; color: var(--mud-palette-text-secondary); }
.ds-frow__folder { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ds-frow__error { color: var(--mud-palette-error); }
.ds-frow .ds-select { flex: 0 0 22px; width: 22px; height: 22px; }

/* Sheets from below (phone) and the side panel (compact), over a scrim. */
.ds-backdrop { position: fixed; inset: 0; z-index: 1300; background: rgba(0, 0, 0, .45); animation: ds-fade-in .15s ease-out; }
.ds-bsheet { position: fixed; left: 0; right: 0; bottom: var(--ds-bottomnav-h); z-index: 1301; display: flex; flex-direction: column; max-width: 720px; max-height: calc(85dvh - var(--ds-bottomnav-h)); margin: 0 auto; padding-bottom: var(--ds-safe-b);
             border-radius: 14px 14px 0 0; color: var(--mud-palette-text-primary); background: var(--mud-palette-surface); box-shadow: 0 -4px 18px rgba(0, 0, 0, .35); animation: ds-sheet-up .22s cubic-bezier(.2, .8, .3, 1); }
.ds-sidepanel { position: fixed; top: 0; bottom: 0; left: 0; z-index: 1301; display: flex; flex-direction: column; width: min(340px, 86vw);
                color: var(--mud-palette-text-primary); background: var(--mud-palette-surface); box-shadow: 4px 0 18px rgba(0, 0, 0, .35); animation: ds-sheet-right .22s cubic-bezier(.2, .8, .3, 1); }
.ds-sheet-head { flex: 0 0 auto; display: flex; align-items: center; justify-content: space-between; padding: 8px 8px 4px 16px; border-bottom: 1px solid var(--mud-palette-lines-default); }
.ds-sheet-body { flex: 1 1 auto; min-height: 0; overflow-y: auto; padding: 8px 16px 16px; }
.ds-pathlist { display: flex; flex-direction: column; }
.ds-pathlist__row { display: flex; align-items: center; }
.ds-pathlist__item { flex: 1; min-width: 0; display: flex; align-items: center; justify-content: flex-start; gap: 10px; min-height: 44px; padding: 0 8px 0 calc(8px + var(--ds-depth, 0) * 14px); border: 0; border-radius: 6px; background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.ds-pathlist__item span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* Filters (bestandsbrowser stap 4). */
.ds-filterfield { flex: 0 1 260px; min-width: 160px; margin: 0 !important; }
/* The folder tree: Explorer's 24 px rows, a small chevron, an amber folder icon, a tint on the open folder. */
.ds-foldertree .mud-treeview-item-content { min-height: 24px; padding: 0 4px 0 0; border-radius: 0; }
.ds-foldertree .mud-treeview-item-content .mud-icon-button { padding: 2px; }
.ds-foldertree .mud-treeview-item-content .mud-icon-button .mud-icon-root { font-size: 16px; }
.ds-foldertree .mud-treeview-item-icon { margin-right: 6px; }
.ds-foldertree .mud-treeview-item-icon .mud-icon-root { font-size: 17px; color: #e8a317; }
.ds-foldertree .mud-treeview-item-label { font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ds-foldertree .mud-treeview-item-selected > .mud-treeview-item-content { background: color-mix(in srgb, var(--mud-palette-primary) 18%, transparent); }
.ds-mfilter .ds-filterfield { flex: none; width: 100%; }
.ds-mfilter { margin: 0 0 4px; }
.ds-activefilters { align-items: center; margin: 0 0 6px; }
/* Selection and keyboard (bestandsbrowser stap 5): selected rows are tinted, the item with the keyboard focus is outlined. */
.ds-filegrid tr.ds-row--selected > td { background: color-mix(in srgb, var(--mud-palette-primary) 14%, transparent); }
.ds-filegrid .mud-table-row { cursor: default; }
[data-nav-item]:focus-visible { outline: 2px solid var(--mud-palette-primary); outline-offset: 2px; border-radius: 2px; }
.ds-contextmenu__anchor { display: block; width: 0; height: 0; }
.ds-contextmenu { position: absolute; width: 0; height: 0; overflow: visible; }
/* Columns and groups (bestandsbrowser stap 6). */
.ds-filegrid .ds-num { text-align: right; font-variant-numeric: tabular-nums; }
/* Toolbar labels only where there is room for them; below 1600 px the icons (with a tooltip and an aria-label) stay. */
.ds-toggle-label { display: inline-flex; align-items: center; gap: 4px; }
@media (max-width: 1599.98px) { .ds-wide-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; } .ds-viewrow .mud-button-root .mud-button-icon-start { margin-right: 0; } }
.ds-group-head { display: flex; align-items: baseline; gap: 8px; margin: 12px 0 6px; padding-bottom: 2px; border-bottom: 1px solid var(--mud-palette-lines-default); }
.ds-group-label { font-weight: 500; }
.ds-group-count { margin-left: 6px; color: var(--mud-palette-text-secondary); font-size: .8rem; }
.ds-group-note { max-width: 260px; white-space: normal; color: var(--mud-palette-text-secondary); }
.ds-pathlist__item--dense { min-height: 24px; gap: 6px; padding: 0 8px; border-radius: 0; font-size: 12.5px; }
.ds-pathlist__item--dense .mud-icon-root { font-size: 16px; color: var(--mud-palette-text-secondary); }
.ds-pathlist__item--dense:hover { background: var(--mud-palette-action-default-hover); }
.ds-address { position: relative; flex: 1 1 auto; min-width: 0; }
.ds-address__list { max-height: 260px; overflow-y: auto; margin-top: 2px; border: 1px solid var(--mud-palette-lines-default); border-radius: 4px; background: var(--mud-palette-surface); }
.ds-browse--wide .ds-address__list, .ds-browse--compact .ds-address__list { position: absolute; left: 0; right: 0; z-index: 20; box-shadow: 0 4px 12px rgba(0, 0, 0, .3); }
.ds-pathlist__item--current { font-weight: 500; background: color-mix(in srgb, var(--mud-palette-primary) 16%, transparent); }
.ds-pathlist__item:focus-visible { outline: 2px solid var(--mud-palette-primary); outline-offset: -2px; }
.ds-chiprow { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 8px; }

/* Bars and the floating button over the bottom of a compact or phone screen. */
.ds-actionbar { position: fixed; left: 0; right: 0; bottom: var(--ds-bottomnav-h); z-index: 1200; display: flex; padding-bottom: var(--ds-safe-b); border-top: 1px solid var(--mud-palette-lines-default); background: var(--mud-palette-surface); box-shadow: 0 -2px 10px rgba(0, 0, 0, .25); }
.ds-actionbar__btn { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 56px; border: 0; background: none; color: inherit; font: inherit; font-size: .72rem; cursor: pointer; }
.ds-actionbar__btn span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ds-actionbar__btn:disabled { opacity: .4; cursor: default; }
.ds-actionbar__btn--danger { color: var(--mud-palette-error); }
.ds-pastebar { position: fixed; left: 12px; right: 12px; bottom: calc(12px + var(--ds-bottomnav-h) + var(--ds-safe-b)); z-index: 1200; display: flex; align-items: center; gap: 8px; max-width: 640px; margin: 0 auto; padding: 6px 6px 6px 14px;
               border-radius: 10px; color: var(--mud-palette-text-primary); background: var(--mud-palette-surface); box-shadow: 0 4px 14px rgba(0, 0, 0, .35); }
.ds-pastebar__text { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .875rem; }
.ds-browse-fab { position: fixed; right: 16px; bottom: calc(16px + var(--ds-bottomnav-h) + var(--ds-safe-b)); z-index: 1190; display: flex; flex-direction: column; align-items: center; gap: 12px; }
/* Bestandsbrowser stap 8: where a drag can land, the running operation, the upload list. */
.ds-drop-over { outline: 2px dashed var(--mud-palette-primary); outline-offset: -2px; background: color-mix(in srgb, var(--mud-palette-primary) 14%, transparent); }
.ds-oprogress { display: flex; flex-direction: column; gap: 2px; padding: 4px 2px 0; }
.ds-upload-list { max-height: 240px; overflow-y: auto; }
.ds-confirm-list { margin: 8px 0 0; padding-left: 20px; max-height: 200px; overflow-y: auto; }
.ds-browse-fab--raised { bottom: calc(76px + var(--ds-bottomnav-h) + var(--ds-safe-b)); }
.ds-picker-path { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* Subfolders as a compact grid of rows (fase-6 B3): a folder per drawing must not push the drawings below the fold. */
.ds-folders { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 2px; padding: 0 8px 6px; }
.ds-folders__title { padding: 6px 10px 3px; font-size: 11px; font-weight: 600; color: var(--ds-title); }
.ds-folder-item { display: flex; align-items: center; min-width: 0; height: 28px; border: 1px solid transparent; border-radius: 3px; }
.ds-folder-item:hover { background: var(--mud-palette-action-default-hover); border-color: var(--mud-palette-lines-default); }
.ds-folder-item .mud-icon-button { padding: 3px; opacity: .7; }
.ds-subfolder { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; height: 100%; padding: 0 6px; border: 0; background: none; color: inherit; font: inherit; font-size: 12.5px; text-align: left; cursor: pointer; }
.ds-subfolder > .mud-icon-root:first-child { font-size: 18px; color: #e8a317; }
.ds-subfolder:focus-visible { outline: 2px solid var(--mud-palette-primary); outline-offset: -2px; }
.ds-folder-item__name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ds-folder-item__count { color: var(--mud-palette-text-secondary); font-size: 11.5px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.ds-folder-item__path { display: none; }
/* A folder the service could not read in its last scan (Jules, 13-11-2026): greyed out (it can still be opened: its index stays), with a warning mark
   that keeps its own colour; the mark carries the text, so the state is never colour alone. */
.ds-folder-item--unreachable .ds-subfolder > :not(.ds-unreachable-mark) { opacity: .5; }
.ds-unreachable-mark { display: inline-flex; flex: none; align-items: center; }
.ds-unreachable-mark .mud-icon-root { font-size: 16px; }
.ds-foldertree .ds-tree-unreachable > .mud-treeview-item-content .mud-treeview-item-icon,
.ds-foldertree .ds-tree-unreachable > .mud-treeview-item-content .mud-treeview-item-label { opacity: .5; }
.ds-visually-hidden { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
/* Details view: the folders are rows of the list (name, then the drawing count right-aligned), as Explorer lists folders above the files. */
.ds-folders--rows { grid-template-columns: minmax(0, 1fr); gap: 0; padding: 0; border-bottom: 1px solid var(--mud-palette-lines-default); }
.ds-folders--rows .ds-folder-item { height: 26px; border: 0; border-bottom: 1px solid var(--mud-palette-divider-light); border-radius: 0; }
.ds-folders--rows .ds-folder-item:hover { border-color: var(--mud-palette-divider-light); }
.ds-folders--rows .ds-subfolder { padding: 0 8px 0 10px; }
.ds-folders--rows .ds-folder-item__count { min-width: 80px; text-align: right; }
.ds-roots { padding: 4px 0; }
.ds-roots .ds-folder-item { height: 32px; }
.ds-roots .ds-folder-item__path { display: block; flex: 2 1 0; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--mud-palette-text-secondary); font-size: 11.5px; }
.ds-roots .ds-folder-item__count { min-width: 120px; }
.ds-filegrid .ds-nowrap { white-space: nowrap; }
.ds-filegrid .ds-filename { overflow-wrap: anywhere; }
.ds-namecell { min-width: 180px; }
/* Column headers sort on the server (bestandsbrowser stap 1): a plain button with the arrow of the current order. */
.ds-sort-header { display: inline-flex; align-items: center; gap: 2px; padding: 0; border: 0; background: none; color: inherit; font: inherit; font-weight: 500; cursor: pointer; }
.ds-sort-header:focus-visible { outline: 2px solid var(--mud-palette-primary); outline-offset: 2px; border-radius: 2px; }
.ds-filegrid .ds-foldername { display: inline-block; max-width: 320px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: middle; }
.ds-main__body { flex: 1 1 auto; }
/* A page that fills the window (drawing page): shell exactly one window high, footer always in view, scrolling only inside the panes. */
.ds-main:has(.ds-page-fill) { height: 100vh; min-height: 0; overflow: hidden; }
.ds-main:has(.ds-page-fill) .ds-main__body { flex: 1 1 0; min-height: 0; overflow: auto; display: flex; flex-direction: column; }
.ds-main__body > .mud-container:has(> .ds-page-fill) { flex: 1 1 0; min-height: 0; display: flex; flex-direction: column; padding: 0; }
.ds-page-fill { flex: 1 1 0; min-height: 0; display: flex; flex-direction: column; }
.ds-page-fill > * { flex: 0 0 auto; }
.ds-page-fill > .ds-detail { flex: 1 1 0; min-height: 240px; }
.ds-tile { cursor: pointer; }
/* The preview of a drawing in the file browser: the real drawing on a canvas (docs/04 §8). */
.ds-thumbnail { position: relative; display: flex; align-items: center; justify-content: center; width: 100%; overflow: hidden; border: 1px solid var(--mud-palette-lines-default); border-radius: 4px; background: var(--mud-palette-surface); }
.ds-thumbnail__canvas { display: block; width: 100%; pointer-events: none; }
.ds-thumbnail__placeholder { opacity: .35; }
.ds-thumbnail__canvas[data-state] { opacity: 0; }
.ds-thumbnail__canvas[data-state="ready"] { opacity: 1; }
.ds-thumbnail__canvas[data-state] + .ds-thumbnail__placeholder { position: absolute; pointer-events: none; }
.ds-thumbnail__canvas[data-state="ready"] + .ds-thumbnail__placeholder { display: none; }
.ds-tile:focus-visible { outline: 3px solid var(--mud-palette-primary); }
.ds-pathlist__path { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }
/* US-26: the folders the service can reach, to pick a root. */
.ds-folder-picker { max-height: 340px; overflow-y: auto; border: 1px solid var(--mud-palette-lines-default); border-radius: 4px; }
.ds-folder-row { display: flex; align-items: center; gap: 8px; width: 100%; padding: 6px 10px; border: 0; background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.ds-folder-row:hover, .ds-folder-row:focus-visible { background: var(--mud-palette-action-default-hover); outline: none; }
.ds-folder-row:focus-visible { box-shadow: inset 0 0 0 2px var(--mud-palette-primary); }
.ds-folder-row:disabled { cursor: wait; opacity: .6; }
.ds-folder-row .ds-folder-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ds-dropzone {border: 2px dashed var(--mud-palette-lines-inputs); border-radius: 4px; padding: 20px; text-align: center; }
.ds-dropzone--over { border-color: var(--mud-palette-primary); background: var(--mud-palette-primary-hover); }

/* ---- Login: the vault (docs/04 §3.1; Jules, 6 November 2026). A static page: no MudBlazor styling script runs here, so it sets its own colours.
   Workbench look (dark surfaces #292929/#252525/#242424, hairlines, accent #00A2E8); gold is for the door's trim only. It follows the app's
   light/dark mode (html[data-theme], set by theme-init.js before the first paint), so the app after it does not change colour.
   wwwroot/js/vault-login.js sets the variables below every frame; the defaults are the shut door without script. ---- */
.login-page {
    --vault-ink: #e8e8e8; --vault-muted: #a0a0a0; --vault-accent: #00a2e8; --vault-accent-ink: #03131c; --vault-gold: #d9ad52; --vault-danger: #ff6b63;
    --vault-pane: #252525; --vault-pane-head: #292929; --vault-field: #1e1e1e; --vault-line: #3a3a3a; --vault-line-strong: #5a5a5a; --vault-ground: #242424;
    --vault-alert-bg: #2d1a1a; --vault-alert-ink: #f5c2bd; --vault-alert-line: #6b2a26; --vault-danger-ink: #ffb4ae; --vault-dot: #444;
    --cx: 40vw; --cy: 50vh; --D: min(105vh, 70vw); --T: 60px;
    --tz: 0px; --rotY: 0deg; --seam: 0; --swing: 0; --light: .04; --dolly: 0; --door-opacity: 1;
    position: fixed; inset: 0; overflow: hidden; color-scheme: dark;
    background: var(--vault-ground); color: var(--vault-ink);
    font: 400 15px/1.45 Roboto, "Segoe UI", system-ui, sans-serif;
}
/* Light mode: the Workbench light surfaces; the steel-and-gold door stays as it is. */
html[data-theme="light"] .login-page {
    --vault-ink: #1f1f1f; --vault-muted: #5c5c5c; --vault-accent-ink: #03131c;
    --vault-pane: #fafafa; --vault-pane-head: #f0f0f0; --vault-field: #ffffff; --vault-line: #d0d0d0; --vault-line-strong: #9e9e9e; --vault-ground: #e6e6e6;
    --vault-alert-bg: #fdeded; --vault-alert-ink: #5f2120; --vault-alert-line: #f1b2ad; --vault-danger-ink: #b3261e; --vault-dot: #bdbdbd;
    color-scheme: light;
}
.vault-shake { position: absolute; inset: 0; }
.vault-shake--go { animation: vault-shake .52s cubic-bezier(.36, .07, .19, .97); }
@keyframes vault-shake {
    10%, 90% { transform: translate3d(-2px, 0, 0); }
    20%, 80% { transform: translate3d(5px, 1px, 0); }
    30%, 50%, 70% { transform: translate3d(-9px, -1px, 0); }
    40%, 60% { transform: translate3d(9px, 1px, 0); }
}
.vault-scene {
    position: absolute; inset: 0; overflow: hidden;
    perspective: calc(var(--D) * 2.4); perspective-origin: var(--cx) var(--cy);
    transform: scale(calc(1 + var(--dolly) * 2.6)); transform-origin: var(--cx) var(--cy);
}
.vault-interior { position: absolute; inset: 0; background: #070707; overflow: hidden; }
.vault-boxes { position: absolute; inset: -40px; display: grid; gap: 6px; padding: 6px; grid-template-columns: repeat(auto-fill, 132px); grid-auto-rows: 86px; opacity: calc(.12 + var(--light) * .88); }
.vault-drawer {
    position: relative; border-radius: 2px; padding: 9px 10px; border: 1px solid #3c3c3c;
    background: linear-gradient(170deg, #303030, #222 70%); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .05);
    font: 500 10px/1.3 Consolas, ui-monospace, monospace; letter-spacing: .06em; color: #c2c2c2;
}
.vault-drawer small { display: block; color: #7a7a7a; }
.vault-drawer::after { content: ""; position: absolute; right: 11px; bottom: 12px; width: 9px; height: 9px; border-radius: 50%; background: #0d0d0d; box-shadow: 0 5px 0 -2px #0d0d0d, 0 0 0 2px #9a7634; }
.vault-light {
    position: absolute; inset: 0; mix-blend-mode: screen; opacity: var(--light);
    background: radial-gradient(circle calc(var(--D) * .75) at var(--cx) var(--cy), rgba(255, 244, 220, .95), rgba(217, 173, 82, .32) 42%, transparent 78%);
}
.vault-wall { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
/* Until the wall is drawn (no script, or a tab that is not laid out yet) the interior must not show through: no dark flash in light mode. */
.login-page:not([data-vault-wall]) .vault-interior { background: var(--vault-ground); }
.login-page:not([data-vault-wall]) .vault-boxes { display: none; }
.vault-bloom {
    position: absolute; pointer-events: none; border-radius: 50%; mix-blend-mode: screen;
    left: calc(var(--cx) - var(--D) / 2 - 3px); top: calc(var(--cy) - var(--D) / 2 - 3px); width: calc(var(--D) + 6px); height: calc(var(--D) + 6px);
    box-shadow: 0 0 calc(var(--D) * .035) calc(var(--D) * .006) rgba(255, 220, 150, .85), inset 0 0 calc(var(--D) * .02) rgba(255, 220, 150, .55);
    opacity: calc(var(--seam) * (1 - var(--swing)));
}
.login-page[data-vault="denied"] .vault-bloom {
    animation: vault-red-flash 1s ease-out;
    box-shadow: 0 0 calc(var(--D) * .04) calc(var(--D) * .008) rgba(255, 70, 60, .9), inset 0 0 calc(var(--D) * .02) rgba(255, 70, 60, .6);
}
@keyframes vault-red-flash { 0% { opacity: 0; } 12% { opacity: 1; } 100% { opacity: 0; } }
.vault-door {
    position: absolute; will-change: transform;
    left: calc(var(--cx) - var(--D) / 2); top: calc(var(--cy) - var(--D) / 2); width: var(--D); height: var(--D);
    transform-origin: 0 50%; transform: translate3d(0, 0, var(--tz)) rotateY(var(--rotY)); transform-style: preserve-3d;
    opacity: var(--door-opacity);
}
.vault-door > * { position: absolute; }
.vault-metal, .vault-edge, .vault-back { inset: 0; border-radius: 50%; }
.vault-metal {
    background:
        repeating-conic-gradient(from 0deg at 50% 50%, rgba(255, 255, 255, .035) 0deg .5deg, rgba(0, 0, 0, .04) .5deg 1.3deg),
        conic-gradient(from 210deg at 50% 50%, #50555b, #8f969d 45deg, #464a4f 120deg, #7a8086 200deg, #3f4347 285deg, #50555b);
    box-shadow: 0 calc(var(--D) * .02) calc(var(--D) * .06) rgba(0, 0, 0, .6);
}
.vault-edge { background: linear-gradient(90deg, #1c1d1f, #4a4e53 45%, #1c1d1f); transform: translateZ(calc(var(--i) * var(--T) * -1)); }
.vault-back {
    transform: translateZ(calc(var(--T) * -1));
    background: repeating-linear-gradient(90deg, transparent 0 18%, rgba(0, 0, 0, .35) 18% 19%), radial-gradient(circle at 50% 50%, #3b3e42 0 22%, #28292b 23% 60%, #1f2022 61%);
}
.vault-face { left: -12%; top: -12%; width: 124%; height: 124%; overflow: visible; }
.vault-numeral { font: 500 20px Consolas, ui-monospace, monospace; fill: #f3d98f; }
.vault-engraving { font: 500 19px Consolas, ui-monospace, monospace; letter-spacing: 6px; }
.vault-lamp { fill: #2b2b2b; transition: fill .25s; }
.vault-lamp--on { fill: var(--vault-accent); filter: url(#vault-lamp-glow); }
.login-page[data-vault="denied"] .vault-lamp { fill: var(--vault-danger); filter: url(#vault-lamp-glow); animation: vault-blink .3s steps(2) 3; }
@keyframes vault-blink { 50% { opacity: .25; } }

/* The sign-in form: a flat Workbench pane beside the wheel (32 px header with a semibold accent title, hairlines). */
.login-card {
    position: absolute; z-index: 2; box-sizing: border-box; right: max(32px, 6vw); top: 50%; translate: 0 -50%;
    width: min(360px, calc(100vw - 32px));
    background: var(--vault-pane); border: 1px solid var(--vault-line); border-radius: 2px; box-shadow: 0 18px 48px rgba(0, 0, 0, .6);
    transition: opacity .7s ease, transform .9s cubic-bezier(.2, .7, .2, 1), filter .7s ease;
}
.login-page[data-vault="leaving"] .login-card, .login-page[data-vault="returning"] .login-card { opacity: 0; transform: translateX(48px) scale(.97); filter: blur(8px); pointer-events: none; }
/* After signing out (data-vault-from="open") the door must not flash shut before vault-login.js opens it: scene and form wait, at most 1.5 s,
   until the script marks the page ready. Without script they simply show after that wait. */
.login-page[data-vault-from="open"]:not([data-vault-ready]) :is(.vault-scene, .login-card) { animation: vault-hold 1.5s; }
@keyframes vault-hold { from, to { opacity: 0; } }
.login-head { display: flex; align-items: center; gap: 8px; height: 32px; margin: 0; padding: 0 12px; background: var(--vault-pane-head); border-bottom: 1px solid var(--vault-line); font-size: 13px; font-weight: 500; color: var(--vault-accent); }
.login-head svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.4; flex: none; }
.login-body { padding: 20px 20px 16px; }
.login-brand { display: flex; align-items: center; gap: 12px; font-size: 1.6rem; letter-spacing: -.01em; }
.login-brand img { width: 36px; height: 36px; }
.login-brand b { font-weight: 700; }
.login-intro { margin: 4px 0 16px; color: var(--vault-muted); font-size: .88rem; }
.login-card form { display: grid; gap: 4px; }
.login-card label { font-size: 12px; font-weight: 500; color: var(--vault-muted); margin-top: 8px; }
.login-card input { box-sizing: border-box; width: 100%; padding: 9px 10px; font: inherit; color: var(--vault-ink); background: var(--vault-field); border: 1px solid var(--vault-line); border-radius: 2px; transition: border-color .15s; }
.login-card input:hover { border-color: var(--vault-line-strong); }
.login-card input:focus-visible { outline: none; border-color: var(--vault-accent); box-shadow: 0 0 0 1px var(--vault-accent); }
.login-card input:read-only { opacity: .6; }
.login-card form button { margin-top: 16px; padding: 9px 16px; font: inherit; font-weight: 500; color: var(--vault-accent-ink); background: var(--vault-accent); border: 0; border-radius: 2px; cursor: pointer; transition: filter .15s; }
.login-card form button:hover { filter: brightness(1.1); }
.login-card form button:focus-visible { outline: 2px solid var(--vault-ink); outline-offset: 2px; }
.login-card form button:disabled { cursor: progress; filter: saturate(.6) brightness(.85); }
.login-alert { margin: 0 0 8px; padding: 9px 12px; border: 1px solid var(--vault-alert-line); border-left: 3px solid var(--vault-danger); border-radius: 2px; background: var(--vault-alert-bg); color: var(--vault-alert-ink); font-size: .88rem; }
.login-alert[hidden] { display: none; }
.login-status { display: flex; align-items: center; gap: 9px; margin: 14px 0 0; min-height: 1.4em; font: 500 12px Consolas, ui-monospace, monospace; color: var(--vault-muted); }
.login-status::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--vault-dot); flex: none; transition: background .25s, box-shadow .25s; }
.login-page[data-vault="typing"] .login-status::before, .login-page[data-vault="checking"] .login-status::before { background: var(--vault-accent); box-shadow: 0 0 10px var(--vault-accent); }
.login-page[data-vault="checking"] .login-status::before { animation: vault-pulse .8s ease-in-out infinite; }
.login-page[data-vault="granted"] .login-status, .login-page[data-vault="leaving"] .login-status { color: var(--vault-ink); }
.login-page[data-vault="granted"] .login-status::before { background: #3ddc84; box-shadow: 0 0 10px #3ddc84; }
.login-page[data-vault="denied"] .login-status { color: var(--vault-danger-ink); }
.login-page[data-vault="denied"] .login-status::before { background: var(--vault-danger); box-shadow: 0 0 10px var(--vault-danger); }
@keyframes vault-pulse { 50% { opacity: .35; } }
.login-foot { display: flex; justify-content: space-between; gap: 12px; padding: 8px 12px; border-top: 1px solid var(--vault-line); background: var(--vault-pane-head); font-size: 12px; color: var(--vault-muted); }
.login-foot a { color: var(--vault-accent); margin-left: 8px; font-weight: 500; text-decoration: none; }
.login-foot a:focus-visible { outline: 2px solid var(--vault-accent); outline-offset: 2px; }
.login-foot__end { display: inline-flex; align-items: center; gap: 2px; }
.login-theme { display: inline-grid; place-items: center; width: 28px; height: 28px; margin-left: 6px; padding: 0; border: 1px solid transparent; border-radius: 2px; background: none; color: var(--vault-muted); cursor: pointer; }
.login-theme:hover { color: var(--vault-accent); border-color: var(--vault-line); }
.login-theme:focus-visible { outline: 2px solid var(--vault-accent); outline-offset: 1px; }
.login-theme[hidden] { display: none; }
.login-theme svg { width: 18px; height: 18px; fill: currentColor; }
/* Shows the mode a click switches to, like the app bar's button. */
html[data-theme="dark"] .login-theme__moon, html:not([data-theme="dark"]) .login-theme__sun { display: none; }
@media (max-width: 899.98px) {
    .login-page { --cx: 50vw; --cy: 34vh; --D: min(112vw, 72vh); }
    .login-card { right: auto; left: 50%; top: auto; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); translate: -50% 0; }
    .login-body { padding: 14px 16px 12px; }
    .login-intro, .login-foot > span:first-child { display: none; }
    .login-brand { font-size: 1.25rem; }
    .login-brand img { width: 28px; height: 28px; }
}
@media (prefers-reduced-motion: reduce) {
    .login-card { transition: opacity .4s ease; }
    .login-page[data-vault="leaving"] .login-card, .login-page[data-vault="returning"] .login-card { transform: none; filter: none; }
}

/* App-bar brand (the name top left; Jules, 6 November 2026: PackVault). */
.ds-brand { display: flex; align-items: center; gap: 8px; margin: 0 4px; color: inherit; text-decoration: none; font-size: 1.05rem; letter-spacing: -.01em; white-space: nowrap; }
.ds-brand b { font-weight: 700; }
.ds-brand__mark { width: 24px; height: 24px; display: block; }
.ds-brand:focus-visible { outline: 2px solid currentColor; outline-offset: 4px; border-radius: 2px; }

/* ==== Radial menu (spec 2026-11-19 radiaalmenu §2): PackDesign's RadialToolSelector, the same colours in both themes ==== */
:root {
    --ds-radial-fill: #242424; --ds-radial-line: #4a4a4a; --ds-radial-hover: #3a3a3a; --ds-radial-hover-line: #9aa0a6;
    --ds-radial-arc: #00a2e8; --ds-radial-back-line: #1a1a1a; --ds-radial-middle: #000; --ds-radial-middle-line: #20242b; --ds-radial-text: #d6d6d6;
}
.ds-radial { position: fixed; left: var(--ds-radial-x); top: var(--ds-radial-y); width: 400px; height: 400px; margin: -200px 0 0 -200px; z-index: 1500; pointer-events: none; user-select: none; font-family: "Segoe UI", Roboto, Arial, sans-serif; }
.ds-radial svg { display: block; overflow: visible; }
.ds-radial__back { fill: var(--ds-radial-fill); stroke: var(--ds-radial-back-line); stroke-width: 2; }
.ds-radial__slice { fill: var(--ds-radial-fill); stroke: var(--ds-radial-line); stroke-width: 1; }
.ds-radial__item--hover .ds-radial__slice { fill: var(--ds-radial-hover); stroke: var(--ds-radial-hover-line); }
.ds-radial__item--off { opacity: .5; }
.ds-radial__arc { fill: none; stroke: var(--ds-radial-arc); stroke-width: 2.5; stroke-linecap: round; }
.ds-radial__label { fill: var(--ds-radial-text); font-size: 11px; font-weight: 600; text-anchor: middle; dominant-baseline: central; }
.ds-radial__middle { fill: var(--ds-radial-middle); stroke: var(--ds-radial-middle-line); stroke-width: 2; }
.ds-radial__middle-text { fill: #fff; font-size: 14px; font-weight: 600; text-anchor: middle; }
.ds-radial__tip { position: absolute; left: calc(200px + var(--ds-radial-tip-x, 0px)); top: calc(200px + var(--ds-radial-tip-y, 0px)); display: none; padding: 3px 6px; border: 1px solid var(--ds-radial-line); border-radius: 3px; background: var(--ds-radial-fill); color: var(--ds-radial-text); font-size: 12px; white-space: nowrap; }
.ds-radial__tip--on { display: block; }

/* The phone's context bar under the drawing (spec 2026-11-19 radiaalmenu §5): only below 600 px, see Screen sizes. */
.ds-ctxbar { display: none; }

/* ==== Screen sizes (docs/04 §1.1; Jules, 7 November 2026: phones, foldables and tablets work as well as the desktop) ====
   Breakpoints are MudBlazor's: phone < 600, small tablet / foldable open 600–959, tablet landscape 960–1279, desktop from 1280.
   The drawing page fits the window only from 1100 wide and 600 high; smaller, the page scrolls and the panes get a fixed share of the screen.
   Components with their own markup keep their phone rule (599.98 px) in their .razor.css: the bell's full-width panel
   (Components/Layout/NotificationBell.razor.css) and the notifications page's strip and stacked rows
   (Components/Features/Notifications/NotificationsPage.razor.css); also ArchivePane, JobcardDialog and VerifiedGeometryView. */
.ds-appbar__close, .ds-appbar__search, .ds-appbar__narrow, .ds-status-chip__short { display: none; }

@media (max-width: 959.98px) {
    /* The name search folds into a button; it opens over the whole bar with a back arrow. */
    .ds-appbar .ds-name-search { display: none; }
    .ds-appbar__search { display: inline-flex; }
    .ds-appbar--search .mud-toolbar > * { display: none !important; }
    .ds-appbar--search .mud-toolbar > .ds-appbar__close { display: inline-flex !important; }
    .ds-appbar--search .mud-toolbar > .ds-name-search { display: block !important; flex: 1 1 auto; max-width: none; margin-left: 8px; }
    .ds-status-chip__long { display: none; }
    .ds-status-chip__short { display: inline; }
    .ds-footer { padding: 6px 16px !important; }
    .ds-footer .mud-typography { font-size: .75rem; }
    /* The file's own name is the title right below; the crumbs stay on one line and scroll sideways. */
    .ds-path-crumbs { flex-wrap: nowrap; overflow-x: auto; white-space: nowrap; scrollbar-width: none; }
    .ds-path-crumbs--file > li:nth-last-child(-n+2) { display: none; }
    .ds-detail__open--wide { display: none; }
    .ds-detail__open--narrow { display: inline-flex; }
}

/* Before the page has measured the screen it renders the wide layout; below 1100 px the tree column stays out of it until then. */
@media (max-width: 1099.98px) {
    .ds-browse--wide { grid-template-columns: minmax(0, 1fr); height: auto; }
    .ds-main:has(.ds-browse--wide) { height: auto; min-height: 100vh; overflow: visible; }
    .ds-browse--compact .ds-browse-main { background: var(--mud-palette-surface); }
    .ds-browse--phone { padding: 0 8px 84px; }
    .ds-browse--wide .ds-browse__tree, .ds-browse--wide .ds-tree-strip, .ds-browse--wide .ds-browse__preview { display: none; }
    .ds-browse--wide .ds-browse-main { height: auto; }
    .ds-browse--compact .ds-tabs { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
    .ds-browse--compact .ds-tab { flex: 0 0 auto; }
    .ds-crumbs.mud-breadcrumbs { flex-wrap: nowrap; overflow-x: auto; white-space: nowrap; scrollbar-width: none; }
}

@media (max-width: 599.98px) {
    .ds-brand__name { display: none; }
    /* Language and theme are in the user menu here; the index status is a dot in the state's colour, the user an icon. */
    .ds-appbar__wide { display: none !important; }
    .ds-appbar__narrow { display: block; }
    .ds-status-chip__short { display: none; }
    .ds-status-chip.mud-chip { width: 14px; height: 14px; min-width: 0; padding: 0; margin: 0 6px !important; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .7); }
    .ds-user-button__name { display: none; }
    .ds-user-button.mud-button-root { min-width: 0; padding: 6px; }
    .ds-user-button .mud-button-icon-start { margin: 0; }
    /* Segmented choices (filter panel, sort-and-view sheet) wrap here as separate buttons instead of one strip wider than the screen. */
    .ds-seg { flex-wrap: wrap; gap: 4px; }
    .ds-seg__item, .ds-seg__item:first-child, .ds-seg__item:last-child { margin-left: 0; border-radius: 3px; }
}

/* A wide but low window (laptop with a short browser): the page scrolls instead of squeezing the panes. */
@media (min-width: 1100px) and (max-height: 599.98px) {
    .ds-main:has(.ds-page-fill) { height: auto; min-height: 100vh; overflow: visible; }
    .ds-main:has(.ds-page-fill) .ds-main__body { flex: 1 1 auto; overflow: visible; display: block; }
    .ds-main__body > .mud-container:has(> .ds-page-fill) { display: block; }
    .ds-page-fill { display: block; }
    .ds-page-fill > .ds-detail { height: max(420px, calc(100svh - 96px)); min-height: 0; }
}

/* Compact (below 1100 px: phones, foldables, small tablets; Jules, 7 November 2026): the drawing fills the screen below the app bar, edge to
   edge, with nothing else on the page. A floating button opens a menu of overlays; each opens the information pane as a sheet from below
   (upright) or a panel on the right (landscape), and the drawing fits itself beside it so a highlight stays in view. */
@media (max-width: 1099.98px) {
    :root { --ds-sheet-open: min(62dvh, calc(100dvh - 190px - var(--ds-bottomnav-h))); }
    .ds-main:has(.ds-page-fill) { height: 100vh; height: 100dvh; }
    .ds-main:has(.ds-page-fill) .ds-footer { display: none !important; }
    .ds-main__body > .mud-container:has(> .ds-page-fill) { margin: 0 !important; padding: 0 !important; max-width: none; }
    .ds-page-fill > :not(.ds-detail) { display: none !important; }
    .ds-page-fill > .ds-detail { display: block; flex: 1 1 0; min-height: 160px; height: auto; margin: 0 !important; border: 0; }
    .ds-page-fill > .ds-detail:not(.ds-detail--collapsed) { margin-bottom: var(--ds-sheet-open) !important; }
    .ds-detail__viewer { position: relative; height: 100%; }
    .ds-grip { display: none; }
    .ds-detail__name-overlay { position: absolute; left: 24px; bottom: 10px; z-index: 2; max-width: calc(100% - 110px); padding: 2px 8px; border-radius: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
                               font-size: .8rem; color: #e6e6e6; background: rgba(0, 0, 0, .55); pointer-events: none; }

    /* The floating button and its menu: labelled round buttons stacked above it, over a light scrim. */
    .ds-fab { position: fixed; right: 16px; bottom: calc(16px + var(--ds-bottomnav-h) + var(--ds-safe-b)); z-index: 1160; display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
    .ds-fab__backdrop { position: fixed; inset: 0; z-index: -1; background: rgba(0, 0, 0, .4); animation: ds-fade-in .15s ease-out; }
    .ds-fab__menu { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; align-items: flex-end; gap: 8px; max-height: calc(100dvh - 160px - var(--ds-bottomnav-h)); overflow-y: auto; }
    .ds-fab__menu > li { animation: ds-fab-item .16s ease-out both; }
    .ds-fab__item { display: flex; align-items: center; gap: 10px; padding: 0; border: 0; background: none; color: inherit; font: inherit; cursor: pointer; }
    .ds-fab__item:disabled { opacity: .45; cursor: default; }
    .ds-fab__label { padding: 5px 10px; border-radius: 4px; font-size: .875rem; white-space: nowrap; color: var(--mud-palette-text-primary); background: var(--mud-palette-surface); box-shadow: 0 2px 6px rgba(0, 0, 0, .35); }
    .ds-fab__icon { display: grid; place-items: center; width: 40px; height: 40px; margin-right: 8px; border-radius: 50%; color: var(--mud-palette-primary); background: var(--mud-palette-surface); box-shadow: 0 2px 6px rgba(0, 0, 0, .35); }
    .ds-fab__item:focus-visible .ds-fab__icon { outline: 2px solid var(--mud-palette-primary); outline-offset: 2px; }

    /* The overlay itself; closed, it is not on screen at all. */
    .ds-detail--collapsed .ds-detail__inspector { display: none; }
    .ds-detail__inspector { position: fixed; left: 0; right: 0; bottom: var(--ds-bottomnav-h); z-index: 1150; height: var(--ds-sheet-open); max-width: 960px; margin: 0 auto; padding-bottom: var(--ds-safe-b);
                            border-radius: 14px 14px 0 0; box-shadow: 0 -4px 18px rgba(0, 0, 0, .35); border-top: 1px solid var(--mud-palette-lines-default); animation: ds-sheet-up .22s cubic-bezier(.2, .8, .3, 1); }
    .ds-sheet__handle { flex: 0 0 16px; display: flex; align-items: center; justify-content: center; width: 100%; padding: 0; border: 0; background: none; cursor: pointer; }
    .ds-sheet__handle::before { content: ""; width: 40px; height: 4px; border-radius: 2px; background: var(--mud-palette-text-disabled); }
    .ds-detail__inspector > .ds-pane__header { flex-direction: row; height: 36px; padding: 0 4px 0 12px; border-bottom: 0; background: none; }


    /* The tab rail becomes a row of tabs over the panel that scrolls sideways. */
    .ds-pane__strip { flex-wrap: wrap; row-gap: 4px; }
    .ds-ddiv { flex-direction: column; }
    .ds-ddiv__rail { flex: 0 0 auto; flex-direction: row; overflow-x: auto; overflow-y: hidden; padding: 0 4px; border-right: 0; border-bottom: 1px solid var(--mud-palette-lines-default); scrollbar-width: thin; }
    .ds-ddiv__tab { flex: 0 0 44px; height: 44px; border-left: 0; border-bottom: 3px solid transparent; }
    .ds-ddiv__tab--active { border-bottom-color: var(--mud-palette-primary); }
    .ds-ddiv__separator { flex: 0 0 1px; height: auto; margin: 8px 4px; }
}

/* A compact screen on its side (phone or tablet in landscape, an opened foldable): the overlay is a panel on the right, so the drawing keeps
   its height and fits itself on the left. */
@media (max-width: 1099.98px) and (min-width: 600px) and (orientation: landscape) {
    :root { --ds-sheet-side: min(420px, 48vw); }
    .ds-page-fill > .ds-detail:not(.ds-detail--collapsed) { margin-bottom: 0 !important; margin-right: var(--ds-sheet-side) !important; }
    .ds-detail__inspector { top: var(--mud-appbar-height); left: auto; right: 0; width: var(--ds-sheet-side); max-width: none; height: auto; margin: 0;
                            border-radius: 14px 0 0 0; box-shadow: -4px 0 18px rgba(0, 0, 0, .35); animation: ds-sheet-left .22s cubic-bezier(.2, .8, .3, 1); }
    .ds-sheet__handle { display: none; }
}

@keyframes ds-sheet-up { from { transform: translateY(40%); opacity: .4; } to { transform: none; opacity: 1; } }
@keyframes ds-sheet-left { from { transform: translateX(40%); opacity: .4; } to { transform: none; opacity: 1; } }
@keyframes ds-sheet-right { from { transform: translateX(-40%); opacity: .4; } to { transform: none; opacity: 1; } }
@keyframes ds-fade-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes ds-fab-item { from { transform: translateY(12px); opacity: 0; } to { transform: none; opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .ds-detail__inspector, .ds-fab__backdrop, .ds-fab__menu > li, .ds-bsheet, .ds-sidepanel, .ds-backdrop { animation: none !important; } }

/* Fingers instead of a mouse: bigger rows and fields (44 px is the usual minimum touch target). */
@media (pointer: coarse) {
    /* The dense Explorer head and list (12 November 2026) on a touch tablet: back to the 36 px minimum of docs/04 §1.1. */
    .ds-tabs { height: 42px; }
    .ds-tab { height: 38px; }
    .ds-tab__close, .ds-tab__new { width: 36px; height: 36px; }
    .ds-crumbrow { min-height: 46px; }
    .ds-addressbox { height: 36px; }
    .ds-crumbrow .mud-icon-button, .ds-cmdbar .mud-icon-button { padding: 9px; }
    .ds-cmdbar { min-height: 48px; }
    .ds-cmdbar .mud-button-root.mud-button, .ds-cmdbar .mud-toggle-group { height: 36px; }
    .ds-cmdbar .mud-toggle-item { min-width: 40px; }
    .ds-folder-item, .ds-folders--rows .ds-folder-item, .ds-roots .ds-folder-item { height: 40px; }
    .ds-filegrid--compact .mud-table-body .mud-table-cell { height: 40px; }
    .ds-foldertree .mud-treeview-item-content { min-height: 36px; }
    .ds-pathlist__item--dense { min-height: 36px; }
    .ds-nav .mud-nav-link { min-height: 40px; }
    .mud-popover .mud-list-item, .mud-menu-list .mud-list-item { min-height: 40px; }
    .ds-stat { min-height: 48px; }
    .ds-table .mud-table-body .mud-table-cell { height: 40px; }
    .ds-ddiv__row { min-height: 36px; }
    .ds-ddiv__search-box { height: 34px; }
    .ds-ddiv__toggle { width: 40px; height: 34px; }
    .ds-pane__strip .mud-toggle-item { min-width: 36px; min-height: 32px; }
    .ds-seg__item { height: 36px; padding: 0 10px; }
    .ds-field-dense .mud-input.mud-input-outlined { height: 36px; }
}

/* Navigation that is always in view (spec 2026-11-18 §4.1): the 44 px icon rail stands left under the app bar from 600 px wide; from 1280 px it
   gives way to the full menu while that is on (.ds-layout--menu-full, set by MainLayout). Below 1280 the menu opens over the page (MudDrawer). */
@media (max-width: 1279.98px) { .mud-layout:not(.ds-layout--overlay) .ds-drawer.mud-drawer { visibility: hidden; } }
.ds-rail { display: none; position: fixed; z-index: 1000; left: 0; top: var(--mud-appbar-height); bottom: 0; box-sizing: border-box;
    width: calc(44px + env(safe-area-inset-left)); padding: 4px 0 4px env(safe-area-inset-left); flex-direction: column; align-items: center; overflow-y: auto;
    background: var(--mud-palette-surface); border-right: 1px solid var(--mud-palette-lines-default); }
@media (min-width: 600px) {
    .ds-rail { display: flex; }
    .ds-main { padding-left: calc(44px + env(safe-area-inset-left)); }
}
@media (min-width: 1280px) {
    .ds-layout--menu-full .ds-rail { display: none; }
    .ds-layout--menu-full .ds-main { padding-left: 0; }
}

/* The phone tab bar (spec 2026-11-18 §4.1, BottomNav): below 600 px it stands at the foot of the screen, 44 px plus the safe area, and every bottom-anchored
   element (action bars, floating buttons, sheets, the drawing page's panel) adds --ds-bottomnav-h to its bottom. The bar carries the safe area itself,
   so --ds-safe-b (what those elements add for the notch) is 0 there. Back lives in the bar: the app bar's history buttons and the menu button give way. */
:root { --ds-bottomnav-h: 0px; --ds-safe-b: env(safe-area-inset-bottom, 0px); }
.ds-bottomnav { display: none; }
@media (max-width: 599.98px) {
    :root { --ds-bottomnav-h: calc(44px + env(safe-area-inset-bottom, 0px)); --ds-safe-b: 0px; }
    .ds-bottomnav { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 1250; box-sizing: border-box; height: var(--ds-bottomnav-h); padding-bottom: env(safe-area-inset-bottom, 0px);
        border-top: 1px solid var(--mud-palette-lines-default); background: var(--mud-palette-surface); }
    .ds-appbar__menu, .ds-appbar [data-testid=app-back], .ds-appbar [data-testid=app-forward] { display: none !important; }
}

#blazor-error-ui { background: lightyellow; bottom: var(--ds-bottomnav-h); box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2); display: none; left: 0; padding: 0.6rem 1.25rem 0.7rem 1.25rem; position: fixed; width: 100%; z-index: 1000; color: #000; }
#blazor-error-ui .dismiss { cursor: pointer; position: absolute; right: 0.75rem; top: 0.5rem; }
.blazor-error-boundary { background: #b32121; padding: 1rem 1rem 1rem 1rem; color: white; }
.blazor-error-boundary::after { content: "An error has occurred."; }

@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; } }

/* Spec 2026-11-19 radiaalmenu §5 (Jules: on the phone "een menu balk met opties wanneer nodig"): no toolbar over the drawing; the context
   bar sits above the tab bar while there is something to do, and the floating button moves up with it. */
@media (max-width: 599.98px) {
    /* .ds-viewer twice: ToolModeBar's scoped rule (.ds-viewer__modes[b-…]) has the same weight and its file comes after app.css. */
    .ds-viewer.ds-viewer--tools .ds-viewer__toolbar, .ds-viewer.ds-viewer--tools .ds-viewer__modes { display: none; }
    .ds-ctxbar { display: flex; position: fixed; left: 0; right: 0; bottom: var(--ds-bottomnav-h); z-index: 1140; }
    body:has(.ds-ctxbar) { --ds-ctxbar-h: 50px; }
    body:has(.ds-ctxbar__readout) { --ds-ctxbar-h: 68px; }
    .ds-fab { bottom: calc(16px + var(--ds-bottomnav-h) + var(--ds-safe-b) + var(--ds-ctxbar-h, 0px)); }
    /* The menu rises with the button; without this its first item slid under the app bar while the bar was in view. */
    .ds-fab__menu { max-height: calc(100dvh - 160px - var(--ds-bottomnav-h) - var(--ds-ctxbar-h, 0px)); }
}
