/* Sortbay workspace. Tokens follow the site design system (docs/DESIGN_SYSTEM.md) in light and dark; body and the
   app root both carry .uwapp-sortbay, so dialogs (appended to <body>) get the same tokens. No inline styles (CSP). */
.uwapp-sortbay {
  --sb-bg: var(--canvas); --sb-surface: var(--surface); --sb-surface-2: var(--surface-2); --sb-ink: var(--ink); --sb-muted: var(--muted);
  --sb-line: var(--line); --sb-control: var(--control); --sb-accent: #6d28d9; --sb-accent-ink: #5b21b6; --sb-on-accent: #fff;
  --sb-sel: #ede9fe; --sb-focus: var(--focus-color); --sb-danger: var(--danger); --sb-danger-bg: var(--danger-bg); --sb-ok: var(--success);
  --sb-unread: #6d28d9;
}
:root[data-theme="dark"] .uwapp-sortbay {
  --sb-bg: var(--d-canvas); --sb-surface: var(--d-surface-2); --sb-surface-2: var(--d-surface-3); --sb-ink: var(--d-ink); --sb-muted: var(--d-muted);
  --sb-line: var(--d-line-strong); --sb-control: var(--d-control); --sb-accent: #a78bfa; --sb-accent-ink: #c4b5fd; --sb-on-accent: #1e1033;
  --sb-sel: #2e2450; --sb-focus: var(--d-focus); --sb-danger: var(--d-danger); --sb-danger-bg: var(--d-danger-bg); --sb-ok: var(--d-success); --sb-unread: #c4b5fd;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .uwapp-sortbay {
    --sb-bg: var(--d-canvas); --sb-surface: var(--d-surface-2); --sb-surface-2: var(--d-surface-3); --sb-ink: var(--d-ink); --sb-muted: var(--d-muted);
    --sb-line: var(--d-line-strong); --sb-control: var(--d-control); --sb-accent: #a78bfa; --sb-accent-ink: #c4b5fd; --sb-on-accent: #1e1033;
    --sb-sel: #2e2450; --sb-focus: var(--d-focus); --sb-danger: var(--d-danger); --sb-danger-bg: var(--d-danger-bg); --sb-ok: var(--d-success); --sb-unread: #c4b5fd;
  }
}
.uwapp-root.uwapp-sortbay { background: var(--sb-bg); color: var(--sb-ink); font-family: var(--font-sans); display: flex; flex-direction: column; min-height: 0; }

/* Platform element defaults leak into app workspaces: reset them at zero specificity. */
:where(.sb-app, .sb-dialog) button { font: inherit; font-size: .9rem; font-weight: 600; padding: 0; border: 0; border-radius: 8px; background: none; color: inherit; cursor: pointer; width: auto; min-height: 0; margin: 0; }
:where(.sb-app, .sb-dialog) :is(input, select, textarea) { font: inherit; color: var(--sb-ink); background: var(--sb-surface); border: 1px solid var(--sb-control); border-radius: 8px; width: auto; margin: 0; }
:where(.sb-app, .sb-dialog) a { color: var(--sb-accent-ink); }
:where(.sb-app, .sb-dialog) :is(h1, h2, h3) { margin: 0; line-height: 1.25; color: var(--sb-ink); }
:where(.sb-app, .sb-dialog) :is(ul, ol) { margin: 0; padding: 0; }
:where(.sb-app, .sb-dialog) p { margin: .25rem 0; }
:where(.sb-app, .sb-dialog) table { border-collapse: collapse; width: 100%; }
:where(.sb-app, .sb-dialog) :is(th, td) { text-align: start; padding: 6px 8px; border-bottom: 1px solid var(--sb-line); color: var(--sb-ink); background: transparent; }
:where(.sb-app, .sb-dialog) th { font-weight: 700; border-bottom-width: 2px; }
.sb-keys thead th { background: transparent; color: var(--sb-ink); }
:where(.sb-app, .sb-dialog) kbd { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .85em; padding: 1px 6px; border: 1px solid var(--sb-control); border-bottom-width: 2px; border-radius: 5px; background: var(--sb-surface-2); white-space: nowrap; }
:where(.sb-app, .sb-dialog) fieldset { border: 1px solid var(--sb-line); border-radius: 10px; padding: .5rem .7rem; margin: 0; min-width: 0; }
:where(.sb-app, .sb-dialog) legend { font-weight: 700; font-size: .9rem; padding: 0 .3rem; }
.sb-app :focus-visible, .sb-dialog :focus-visible { outline: 3px solid var(--sb-focus); outline-offset: 2px; }

.sb-app { display: flex; flex-direction: column; flex: 1; min-height: 0; min-width: 0; background: var(--sb-bg); color: var(--sb-ink); }
.sb-app.sb-drop { outline: 3px dashed var(--sb-accent); outline-offset: -6px; }
.sb-sr { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; }
.sb-muted { color: var(--sb-muted); font-size: .86rem; }
.sb-small { font-size: .86rem; }
.sb-hint { color: var(--sb-muted); font-size: .85rem; }
.sb-icon { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.sb-icon.sb-big { width: 48px; height: 48px; color: var(--sb-accent-ink); stroke-width: 1.5; }

/* top bar */
.sb-top { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; padding: .5rem .75rem; border-bottom: 1px solid var(--sb-line); background: var(--sb-surface); }
.sb-tabs { display: flex; gap: .25rem; flex-wrap: wrap; }
.sb-tab { display: inline-flex; align-items: center; gap: .4rem; padding: .45rem .75rem !important; border-radius: 999px !important; color: var(--sb-ink); }
.sb-tab[aria-selected="true"] { background: var(--sb-accent) !important; color: var(--sb-on-accent); }
.sb-tab:not([aria-selected="true"]):hover { background: var(--sb-surface-2) !important; }
.sb-actions { display: flex; gap: .3rem; flex-wrap: wrap; margin-inline-start: auto; align-items: center; }
.sb-btn { display: inline-flex; align-items: center; justify-content: center; gap: .35rem; min-height: 36px !important; border: 1px solid var(--sb-control) !important; background: var(--sb-surface) !important; color: var(--sb-ink); }
.sb-btn-icon { width: 36px !important; }
.sb-btn-label { padding: .3rem .7rem !important; }
.sb-btn:hover:not(:disabled) { background: var(--sb-surface-2) !important; }
.sb-btn:disabled { opacity: .5; cursor: not-allowed; }
.sb-btn-primary { background: var(--sb-accent) !important; border-color: var(--sb-accent) !important; color: var(--sb-on-accent); }
.sb-btn-primary:hover:not(:disabled) { background: var(--sb-accent-ink) !important; }
.sb-btn-danger { background: var(--sb-danger) !important; border-color: var(--sb-danger) !important; color: #fff; }
.sb-pill { display: inline-block; min-width: 1.4em; padding: 0 .4em; border-radius: 999px; background: var(--sb-danger); color: #fff; font-size: .75rem; font-weight: 700; text-align: center; line-height: 1.5; }
.sb-pill-quiet { background: var(--sb-surface-2); color: var(--sb-ink); border: 1px solid var(--sb-line); }
.sb-tab[aria-selected="true"] .sb-pill { background: var(--sb-on-accent); color: var(--sb-accent-ink); }
.sb-notices:empty { display: none; }
.sb-notices { padding: 0 .75rem; }

.sb-panel { flex: 1; min-height: 0; display: flex; flex-direction: column; overflow: auto; }
.sb-statusbar { display: flex; justify-content: space-between; gap: .5rem; align-items: center; padding: .3rem .75rem; border-top: 1px solid var(--sb-line); background: var(--sb-surface); font-size: .85rem; min-height: 32px; flex-wrap: wrap; }

/* segments, filters */
.sb-seg { display: inline-flex; flex-wrap: wrap; border: 1px solid var(--sb-control); border-radius: 10px; overflow: hidden; }
.sb-seg-btn { display: inline-flex; gap: .35rem; align-items: center; padding: .35rem .7rem !important; border-radius: 0 !important; color: var(--sb-ink); }
.sb-seg-btn + .sb-seg-btn { border-inline-start: 1px solid var(--sb-control) !important; }
.sb-seg-btn[aria-pressed="true"] { background: var(--sb-sel) !important; color: var(--sb-ink); box-shadow: inset 0 -3px 0 var(--sb-accent); }
.sb-filters { display: flex; flex-wrap: wrap; gap: .5rem; align-items: end; }
.sb-filters .sb-field { margin: 0; }
.sb-filter-actions { display: flex; gap: .3rem; flex-wrap: wrap; }
.sb-input { padding: .35rem .5rem; min-height: 36px; max-width: 100%; box-sizing: border-box; }
.sb-search { min-width: 12rem; flex: 1 1 12rem; }
.sb-field { display: flex; flex-direction: column; gap: .2rem; min-width: 0; }
.sb-field > label { font-size: .85rem; font-weight: 600; }
.sb-field .sb-hint { margin: 0; }
.sb-row { display: flex; flex-wrap: wrap; gap: .6rem; align-items: end; }
.sb-row > .sb-field { flex: 1 1 10rem; }
.sb-row-tight { display: flex; gap: .3rem; flex-wrap: wrap; align-items: center; }
.sb-stack { display: flex; flex-direction: column; gap: .7rem; min-width: 0; }
.sb-check { display: inline-flex; gap: .5rem; align-items: center; }
.sb-section-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .5rem; }

/* notifications */
.sb-npane { display: flex; flex-direction: column; gap: .6rem; padding: .75rem; max-width: 1100px; width: 100%; box-sizing: border-box; margin: 0 auto; }
.sb-ntools { display: flex; flex-wrap: wrap; gap: .3rem; }
.sb-nlist, .sb-list { list-style: none; border: 1px solid var(--sb-line); border-radius: 12px; background: var(--sb-surface); overflow: hidden; }
.sb-nlist:focus-visible, .sb-list:focus-visible { outline: 3px solid var(--sb-focus); outline-offset: 2px; }
.sb-nitem { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: .6rem; padding: .6rem .75rem; border-bottom: 1px solid var(--sb-line); cursor: pointer; align-items: start; }
.sb-nitem:last-child, .sb-item:last-child { border-bottom: 0; }
.sb-nitem.sb-sel, .sb-item.sb-sel { background: var(--sb-sel); box-shadow: inset 4px 0 0 var(--sb-accent); }
.sb-nicon { color: var(--sb-accent-ink); padding-top: .1rem; }
.sb-nmain { display: flex; flex-direction: column; gap: .15rem; min-width: 0; }
.sb-nline { display: flex; align-items: center; gap: .4rem; min-width: 0; }
.sb-ntitle { overflow-wrap: anywhere; }
.sb-unread .sb-ntitle { font-weight: 700; }
.sb-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--sb-unread); flex: none; }
.sb-nmeta { display: flex; flex-wrap: wrap; gap: .25rem .6rem; font-size: .84rem; align-items: center; }
.sb-nref { font-style: italic; overflow-wrap: anywhere; }
.sb-gone { text-decoration: line-through; }
.sb-ntime { color: var(--sb-muted); font-size: .82rem; white-space: nowrap; }
.sb-app-tag { display: inline-block; padding: 0 .45em; border-radius: 6px; background: var(--sb-surface-2); border: 1px solid var(--sb-line); font-size: .78rem; font-weight: 600; }
.sb-empty { padding: 1.2rem; color: var(--sb-muted); }
.sb-empty-state { display: flex; flex-direction: column; align-items: center; text-align: center; gap: .6rem; padding: 2rem 1rem; max-width: 34rem; margin: 0 auto; }
.sb-count { margin: 0; }
.sb-assigned { border-top: 1px solid var(--sb-line); padding-top: .8rem; margin-top: .4rem; display: flex; flex-direction: column; gap: .4rem; }
.sb-alist { list-style: none; display: flex; flex-direction: column; gap: .35rem; }
.sb-alist li { display: flex; flex-wrap: wrap; gap: .3rem .7rem; align-items: center; padding: .45rem .6rem; border: 1px solid var(--sb-line); border-radius: 10px; background: var(--sb-surface); }
.sb-alink { display: inline-flex; gap: .4rem; align-items: center; min-width: 0; }
.sb-atitle { overflow-wrap: anywhere; }
.sb-choices { display: grid; gap: .4rem; }
.sb-choice { justify-content: space-between !important; flex-wrap: wrap; text-align: start; }
.sb-mutes { list-style: none; display: flex; flex-direction: column; gap: .3rem; }
.sb-mutes li { display: flex; justify-content: space-between; gap: .5rem; align-items: center; flex-wrap: wrap; }

/* team inbox */
.sb-ihead { display: flex; flex-direction: column; gap: .5rem; padding: .75rem .75rem .5rem; }
.sb-ititle { display: flex; flex-wrap: wrap; gap: .2rem .8rem; align-items: baseline; }
.sb-h1 { font-size: 1.25rem; }
.sb-split { display: grid; grid-template-columns: minmax(16rem, 2fr) minmax(0, 3fr); gap: .75rem; padding: 0 .75rem .75rem; flex: 1; min-height: 0; }
.sb-listpane { min-width: 0; min-height: 0; overflow: auto; }
.sb-item { display: flex; flex-direction: column; gap: .2rem; padding: .55rem .75rem; border-bottom: 1px solid var(--sb-line); cursor: pointer; }
.sb-item.sb-done .sb-isubj { color: var(--sb-muted); }
.sb-iline { display: flex; justify-content: space-between; gap: .5rem; }
.sb-ifrom { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.sb-isubj { overflow-wrap: anywhere; }
.sb-imeta { display: flex; flex-wrap: wrap; gap: .25rem .45rem; align-items: center; font-size: .8rem; }
.sb-imeta .sb-icon { width: 14px; height: 14px; }
.sb-owner { display: inline-flex; gap: .2rem; align-items: center; }
.sb-status { padding: 0 .45em; border-radius: 6px; font-weight: 700; border: 1px solid transparent; }
.sb-s-open { background: #dbeafe; color: #1e3a8a; }
.sb-s-waiting { background: #fef3c7; color: #713f12; }
.sb-s-done { background: #dcfce7; color: #14532d; }
.sb-due { color: var(--sb-ink); font-weight: 600; }
.sb-due-over { color: var(--sb-danger); }
.sb-label { display: inline-block; padding: 0 .45em; border-radius: 6px; font-weight: 600; font-size: .78rem; border: 1px solid transparent; }
.sb-c-blue { background: #dbeafe; color: #1e3a8a; } .sb-c-green { background: #dcfce7; color: #14532d; } .sb-c-amber { background: #fef3c7; color: #713f12; }
.sb-c-red { background: #fee2e2; color: #7f1d1d; } .sb-c-purple { background: #ede9fe; color: #4c1d95; } .sb-c-teal { background: #ccfbf1; color: #134e4a; }
.sb-c-pink { background: #fce7f3; color: #831843; } .sb-c-grey { background: #e5e7eb; color: #1f2937; }
:root[data-theme="dark"] :is(.sb-s-open, .sb-s-waiting, .sb-s-done, .sb-label, .sb-label-toggle) { background: transparent; color: var(--sb-ink); border-color: var(--sb-control); }
:root[data-theme="dark"] :is(.sb-s-open, .sb-c-blue) { border-color: #60a5fa; color: #bfdbfe; } :root[data-theme="dark"] :is(.sb-s-waiting, .sb-c-amber) { border-color: #fbbf24; color: #fde68a; }
:root[data-theme="dark"] :is(.sb-s-done, .sb-c-green) { border-color: #4ade80; color: #bbf7d0; } :root[data-theme="dark"] .sb-c-red { border-color: #f87171; color: #fecaca; }
:root[data-theme="dark"] .sb-c-purple { border-color: #a78bfa; color: #ddd6fe; } :root[data-theme="dark"] .sb-c-teal { border-color: #2dd4bf; color: #99f6e4; }
:root[data-theme="dark"] .sb-c-pink { border-color: #f472b6; color: #fbcfe8; } :root[data-theme="dark"] .sb-c-grey { border-color: #9ca3af; color: #e5e7eb; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) :is(.sb-s-open, .sb-s-waiting, .sb-s-done, .sb-label, .sb-label-toggle) { background: transparent; color: var(--sb-ink); border-color: var(--sb-control); }
  :root:not([data-theme="light"]) :is(.sb-s-open, .sb-c-blue) { border-color: #60a5fa; color: #bfdbfe; } :root:not([data-theme="light"]) :is(.sb-s-waiting, .sb-c-amber) { border-color: #fbbf24; color: #fde68a; }
  :root:not([data-theme="light"]) :is(.sb-s-done, .sb-c-green) { border-color: #4ade80; color: #bbf7d0; } :root:not([data-theme="light"]) .sb-c-red { border-color: #f87171; color: #fecaca; }
  :root:not([data-theme="light"]) .sb-c-purple { border-color: #a78bfa; color: #ddd6fe; } :root:not([data-theme="light"]) .sb-c-teal { border-color: #2dd4bf; color: #99f6e4; }
  :root:not([data-theme="light"]) .sb-c-pink { border-color: #f472b6; color: #fbcfe8; } :root:not([data-theme="light"]) .sb-c-grey { border-color: #9ca3af; color: #e5e7eb; }
}

.sb-detail { min-width: 0; overflow: auto; border: 1px solid var(--sb-line); border-radius: 12px; background: var(--sb-surface); padding: .8rem 1rem; display: flex; flex-direction: column; gap: .6rem; }
.sb-detail > * { flex: none; }
.sb-back { display: none !important; align-self: flex-start; }
.sb-dsubj { font-size: 1.15rem; overflow-wrap: anywhere; }
.sb-dmeta { display: flex; flex-wrap: wrap; gap: .3rem .7rem; align-items: center; font-size: .9rem; overflow-wrap: anywhere; }
.sb-dcontrols { display: grid; grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr)); gap: .6rem; }
.sb-dlabels { display: flex; flex-wrap: wrap; gap: .3rem; }
.sb-label-toggle { padding: .15rem .55rem !important; border-radius: 999px !important; border: 1px solid var(--sb-control) !important; font-size: .82rem !important; border-style: dashed !important; }
.sb-label-toggle[aria-pressed="true"] { border-style: solid !important; box-shadow: 0 0 0 2px var(--sb-accent); }
.sb-label-toggle[aria-pressed="true"]::before { content: "✓ "; }
.sb-dactions { display: flex; flex-wrap: wrap; gap: .35rem; }
.sb-body { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.55; background: var(--sb-bg); border: 1px solid var(--sb-line); border-radius: 10px; padding: .7rem .8rem; max-height: 28rem; overflow: auto; font-size: .95rem; }
.sb-atts ul, .sb-comments ul { list-style: none; display: flex; flex-direction: column; gap: .3rem; }
.sb-atts li { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; overflow-wrap: anywhere; }
.sb-atts h3, .sb-refs h3, .sb-comments h3 { font-size: 1rem; margin-bottom: .3rem; }
.sb-chips { display: flex; flex-wrap: wrap; gap: .35rem; }
.sb-chip { display: inline-flex; align-items: center; gap: .25rem; border: 1px solid var(--sb-line); border-radius: 999px; padding: .15rem .3rem .15rem .5rem; background: var(--sb-surface-2); max-width: 100%; }
.sb-chip-link { display: inline-flex; gap: .35rem; align-items: center; min-width: 0; overflow-wrap: anywhere; }
.sb-chip-x { width: 28px; height: 28px; display: inline-flex !important; align-items: center; justify-content: center; border-radius: 50% !important; }
.sb-comment { border-inline-start: 3px solid var(--sb-line); padding-inline-start: .6rem; }
.sb-cmeta { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; font-size: .84rem; color: var(--sb-muted); }
.sb-cmeta strong { color: var(--sb-ink); }
.sb-ctext { white-space: pre-wrap; overflow-wrap: anywhere; }
.sb-cform { display: flex; flex-direction: column; gap: .4rem; align-items: flex-start; margin-top: .4rem; }
.sb-cform .sb-field, .sb-cform textarea { width: 100%; }
.sb-linkbtn { text-decoration: underline; color: var(--sb-accent-ink) !important; font-weight: 500 !important; min-height: 24px !important; }
.sb-triage summary { cursor: pointer; font-weight: 600; font-size: .9rem; }
.sb-triage ul { padding-inline-start: 1.2rem; font-size: .86rem; }

/* rules */
.sb-rules { display: flex; flex-direction: column; gap: .6rem; padding: .75rem; max-width: 1000px; width: 100%; box-sizing: border-box; margin: 0 auto; }
.sb-rule-list { list-style: none; display: flex; flex-direction: column; gap: .5rem; }
.sb-rule { border: 1px solid var(--sb-line); border-radius: 12px; background: var(--sb-surface); padding: .6rem .8rem; }
.sb-rule.sb-off { border-style: dashed; }
.sb-rule-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .4rem; align-items: center; }
.sb-up .sb-icon { transform: rotate(180deg); }
.sb-threads { list-style: none; display: flex; flex-direction: column; gap: .25rem; }
.sb-conds { display: flex; flex-direction: column; gap: .4rem; }
.sb-cond { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr) minmax(0, 2fr) auto; gap: .35rem; align-items: center; }

/* dialogs */
.sb-dialog { border: 1px solid var(--sb-line); border-radius: 14px; padding: 0; width: min(32rem, calc(100vw - 1.5rem)); max-height: calc(100dvh - 2rem); background: var(--sb-surface); color: var(--sb-ink); box-shadow: 0 20px 60px rgb(0 0 0 / .3); }
.sb-dialog-wide { width: min(46rem, calc(100vw - 1.5rem)); }
.sb-dialog::backdrop { background: rgb(15 10 30 / .45); }
.sb-dialog-head { display: flex; justify-content: space-between; align-items: center; gap: .5rem; padding: .7rem .9rem .3rem; }
.sb-dialog-head h2 { font-size: 1.1rem; }
.sb-dialog > .sb-muted { padding: 0 .9rem; margin: 0; }
.sb-dialog-body { padding: .6rem .9rem; overflow: auto; max-height: calc(100dvh - 11rem); }
.sb-dialog-foot { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: .4rem; padding: .6rem .9rem .8rem; border-top: 1px solid var(--sb-line); }
.sb-dialog textarea { width: 100%; }
.sb-menu { list-style: none; display: flex; flex-direction: column; }
.sb-menu-h { font-size: .8rem; text-transform: uppercase; letter-spacing: .04em; color: var(--sb-muted); padding: .6rem .3rem .2rem; font-weight: 700; }
.sb-menu-item { width: 100% !important; text-align: start; padding: .5rem .6rem !important; border-radius: 8px !important; }
.sb-menu-item:hover:not(:disabled) { background: var(--sb-surface-2) !important; }
.sb-menu-item:disabled { opacity: .5; }
.sb-labels-list { list-style: none; display: flex; flex-direction: column; gap: .3rem; }
.sb-labels-list li { display: flex; justify-content: space-between; align-items: center; gap: .5rem; }
.sb-keys td:first-child { white-space: nowrap; }

/* team-inbox-badge.js (when an app shows the shared unread badge) */
.uw-inbox-badge { display: inline-block; min-width: 1.4em; margin-inline-start: .35em; padding: 0 .35em; border-radius: 999px; background: #b91c1c; color: #fff; font-size: .75rem; font-weight: 700; text-align: center; line-height: 1.5; }

@media (max-width: 760px) {
  .sb-split { grid-template-columns: minmax(0, 1fr); }
  .sb-split .sb-detail { display: none; }
  .sb-split.sb-show-detail .sb-listpane { display: none; }
  .sb-split.sb-show-detail .sb-detail { display: flex; }
  .sb-back { display: inline-flex !important; }
  .sb-top { padding: .4rem .5rem; }
  .sb-actions { margin-inline-start: 0; }
  .sb-tab span:not(.sb-pill) { font-size: .88rem; }
  .sb-cond { grid-template-columns: minmax(0, 1fr); }
  .sb-nitem { grid-template-columns: minmax(0, 1fr) auto; }
  .sb-nicon { display: none; }
  .sb-search { min-width: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .sb-app *, .sb-dialog * { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
