/* =====================================================
   INRADR — Toolbar — view and nested DxToolbar metrics
   inradr-feature layer (adapter): DevExpress / XAF / vendor selectors and tokens only.
   Maps inradr-design values (var(--inradr-*)) onto the framework; no new base values and
   no hex literals. Internal --dxbl-* tokens are set on the element that declares them and
   carry "re-verify on DX upgrade" (full list: inradr-feature/README.md).
   Never target a bare .dxbl-modal (it also matches the XAF skip link).
   ===================================================== */

/* DOM (26.1 List snapshot, popup captures): div.inradr-content-toolbar / div.nested-toolbar /
   div.dxbl-modal-footer > dxbl-toolbar.dxbl-toolbar > div.dxbl-btn-toolbar > div.dxbl-btn-group >
   dxbl-toolbar-item > button.dxbl-btn (split buttons: div.dxbl-btn-split > two buttons; the ellipsis:
   dxbl-toolbar-item.dxbl-btn-group.dxbl-toolbar-btn-ellipsis > button). A sibling
   div.dxbl-virtual-toolbar.dxbl-btn-toolbar measures the adaptive layout and gets the same rules.
   Button colours live in inradr-feature-button.css, icon colours in inradr-feature-icon.css. The
   height stays the Fluent medium 32px (OQ-09); the focus ring stays Fluent (OQ-02 a), so the toolbar
   focus tokens are not touched. Header and footer toolbars are excluded (their adapters own them). */

/* ── Empty content toolbar (ClickUp 124ca7cqp1p) ──────────────────
   XAF's DxToolbarAdapter renders nothing while no action of the view is visible, and the switch slot
   (.inradr-switch-actions) then holds only a Blazor comment node, so the row stayed a 32px blank band
   (min-height and padding, inradr-shell.css) under the caption of the dashboards, the overview, the
   administration hub and masks without actions. The row counts as filled while it holds the DevExpress
   toolbar or a rendered switch; :has() follows every re-render, so the row returns as soon as an
   action becomes visible. Same pattern as the empty nested toolbar (inradr-feature-listview.css). A
   rendered dxbl-toolbar is never hidden, so its adaptive layout always measures a visible row. One
   class plus :has() beats the base rule of inradr-shell.css without !important. */
.inradr-content-toolbar:not(:has(dxbl-toolbar, .inradr-action-switch)) {
    display: none;
}

/* ── 25.2 metrics (OQ-10) ─────────────────────────────────────────
   26.1.4 tightened the group spacing (8 -> 6px) and the icon-to-text gap (8 -> 4px). Both tokens are
   declared on '.dxbl-toolbar' (core.min.css 26.1.4) and resolved further down
   ('.dxbl-toolbar>.dxbl-btn-toolbar{--dxbl-btn-toolbar-spacing:var(--dxbl-toolbar-group-spacing)}',
   '.dxbl-toolbar .dxbl-btn{--dxbl-btn-image-spacing-m:var(--dxbl-toolbar-btn-image-spacing-m)}'), so
   they are set on the toolbar element. Same specificity as DX, later in the cascade. Small toolbars
   (.dxbl-sm, 0,2,0) keep their own DX metrics. Re-verify on DX upgrade. */
.dxbl-toolbar:where(:not(.inradr-app-header *, .inradr-footer *)) {
    --dxbl-toolbar-group-spacing: var(--inradr-gap-btn-action);
    --dxbl-toolbar-btn-image-spacing-m: var(--inradr-space-xs);
}

/* ── Icon-only actions 36px wide ──────────────────────────────────
   DS icon button 36x36 at the 32px toolbar height (A: global 'button{min-width:36px!important}', which
   also widened DX-internal buttons). Scoped to toolbar buttons; the chevron half of a split button and
   buttons inside an editor in the toolbar (full-text search) keep their DX width. */
.dxbl-toolbar:where(:not(.inradr-app-header *, .inradr-footer *)) > .dxbl-btn-toolbar .dxbl-btn:not(.dxbl-btn-split-dropdown, .dxbl-text-edit *) {
    min-width: var(--inradr-height-control);
}
