/* Sheet (0.35.0): the kit popup docked to the right edge, full height, for a record opened over the list it came
   from. `<dialog class="ui-modal ui-sheet">` with the popup's own head / body / foot (ui.css; the head's subtitle and
   actions are kit-plain.css). (0,2,1) over `dialog.ui-modal` (kit-plain.css) and `.ui-modal` (ui.css), whatever order
   the sheets load in. It lays itself out (no padding, a column whose body scrolls under a head that stays) rather than
   lean on kit-plain.css for that: a full-height panel whose body cannot scroll hides the record (review #4062, on a
   surface that loads ui.css alone). Open it with showModal(), never the `open` attribute (no scrim, page not inert).
   `<dialog class="ui-modal ui-sheet" aria-labelledby="t" tabindex="-1"><div class="ui-modal__head"><div
   class="ui-modal__title"><span id="t">Jane Doe</span><span class="ui-modal__subtitle">CRO agency</span></div><div
   class="ui-modal__actions"><a class="ui-btn" href="/people/1">Open full profile</a></div><button type="button"
   class="ui-modal__close" aria-label="Close">…</button></div><div class="ui-modal__body">…</div></dialog>` */
dialog.ui-modal.ui-sheet {
  margin: 0 0 0 auto; inset-block: 0; padding: 0; box-sizing: border-box;
  width: min(560px, 100%); max-width: 100%;
  height: 100dvh; max-height: 100dvh;
  border-width: 0 0 0 1px; border-radius: 0;
}
dialog.ui-modal.ui-sheet.ui-sheet--wide { width: min(760px, 100%); }
dialog.ui-modal.ui-sheet[open] { display: flex; flex-direction: column; animation: ui-sheet-in 200ms cubic-bezier(0.2, 0.8, 0.2, 1); }
dialog.ui-modal.ui-sheet > .ui-modal__head, dialog.ui-modal.ui-sheet > .ui-modal__foot { flex: none; }
/* Scrolling past the end of the record does not scroll the list behind it. */
dialog.ui-modal.ui-sheet > .ui-modal__body { flex: 1 1 auto; min-height: 0; overflow: auto; overscroll-behavior: contain; }
/* The panel takes focus on open (Sheet); a ring round the whole screen edge says nothing the title does not. */
dialog.ui-modal.ui-sheet:focus { outline: none; }
/* The list it was opened from stays readable beside it: its own scrim, and NOT the centred popup's frost (dialog.css, 13/11/2026),
   which is there so that only the popup reads. */
dialog.ui-modal.ui-sheet::backdrop { background: rgba(0, 0, 0, 0.3); -webkit-backdrop-filter: none; backdrop-filter: none; }
/* The subtitle beside the title (Sheet `subtitleBeside`, GemX ubl-PL-2): one line, the name first, where the record sits at its end in the
   subtitle's muted caption; the name wraps before the subtitle moves under it. */
dialog.ui-modal.ui-sheet--beside > .ui-modal__head > .ui-modal__title { display: flex; flex-wrap: wrap; align-items: baseline; column-gap: 12px; }
dialog.ui-modal.ui-sheet--beside > .ui-modal__head > .ui-modal__title > .ui-modal__subtitle { margin: 0 0 0 auto; }
/* The list behind holds still: `html:has(dialog.ui-modal:modal)` in kit-plain.css, one rule for every modal kit popup. */
@keyframes ui-sheet-in { from { transform: translateX(100%); } }
@media (prefers-reduced-motion: reduce) { dialog.ui-modal.ui-sheet[open] { animation: none; } }
/* Under 768: the whole screen, so no edge line. */
@media (max-width: 47.9975em) {
  dialog.ui-modal.ui-sheet, dialog.ui-modal.ui-sheet.ui-sheet--wide { width: 100%; border-left-width: 0; }
}
