/* pa-views.css · step 6b (27 Nov 2026, WAT). WEB views: filter bar (W9), ⌘K (W10), Overview (W11), directories (W12), partner page
   and drawer peek (W13). Admin tokens only: no new colours, fonts or radii. Kit pieces reused: .toolbar.p2-fl filter line, .pt/.pp
   period, .mnu menus, .p2-flsh sheet, .dt tiles, .ovc cards, .drawer/.dw peek. */

/* ── W9 Filter bar: sticky one line under the head ── */
.pa-fb { position: sticky; top: 0; z-index: 12; margin: var(--space-4) calc(-1 * var(--pad)) var(--space-4); padding: 8px var(--pad) !important; border: 0 !important; border-bottom: 1px solid var(--color-border-subtle) !important; border-radius: 0 !important; background: var(--color-bg-canvas); }
.pa-fb__row { display: flex; align-items: center; gap: var(--space-2) var(--space-3); min-width: 0; flex-wrap: wrap; width: 100%; }
.pa-fb__desk { display: contents; }
.pa-fb__sep { width: 1px; height: 20px; background: var(--color-border-subtle); flex: none; }
.pa-fb__k { font-size: var(--tiny); color: var(--color-text-tertiary); }
.pa-fb__f { min-width: 0; }
.pa-fb .p2-fl__f.is-on .msel.sel, .pa-fb .p2-fl__f.is-on .p2-fl__mb { background-color: var(--color-lilac-50); }
.pa-fb .p2-fl__f.is-on .msel.sel b, .pa-fb .p2-fl__f.is-on .p2-fl__mb b { color: var(--color-lilac-700); }
.pa-fb__mb { display: inline-flex; align-items: center; border-radius: var(--radius-xs); color: var(--color-text-secondary); }
.pa-fb__end { display: inline-flex; align-items: center; gap: var(--space-4); margin-left: auto; }
.pa-fb__saved { display: inline-flex; align-items: center; gap: 6px; border-radius: var(--radius-xs); }
.pa-fb__sheet { display: none; }
.pa-fb__sheet.is-on { border-color: var(--color-lilac-300); color: var(--color-lilac-700); background: var(--color-lilac-50); }
.pa-pt { height: 32px; }
.pa-pt .pa-pt__n { font-weight: var(--font-weight-semibold); }
.pa-pt .pt__range { color: var(--color-text-secondary); font-weight: var(--font-weight-regular); }
.pa-pt:focus-visible, .pa-fb__sheet:focus-visible, .pa-fb__mb:focus-visible { outline: 2px solid var(--color-border-focus); outline-offset: 1px; }
@media (max-width: 760px) {
  .pa-fb__desk, .pa-fb__k, .pa-fb__saved { display: none !important; }
  .pa-fb__sheet { display: inline-flex; height: 32px; }
  .pa-fb .pa-pt { width: auto; padding: 0 var(--space-2) 0 var(--space-3); justify-content: flex-start; max-width: 62vw; }
  .pa-fb .pa-pt .pt__t { display: inline-flex; min-width: 0; overflow: hidden; }
  .pa-fb .pa-pt .pt__range { display: none; }
  .pa-fb .pa-pt .pt__chev { display: block; }
  .pa-fb__end { gap: var(--space-2); }
}
/* period popover additions */
.pa-ppop { max-width: calc(100vw - 16px); max-height: calc(100vh - 16px); overflow: auto; }
.pa-lnkb { padding: 0; border: 0; background: none; font: inherit; color: var(--color-text-accent); text-decoration: underline; text-underline-offset: 2px; cursor: pointer; }
.pa-lnkb:focus-visible { outline: 2px solid var(--color-border-focus); outline-offset: 2px; }
/* phone sheet */
.pa-flsh .pa-flsh__set { margin: 0; padding: 0; border: 0; display: grid; gap: 6px; }
.pa-flsh legend { margin-bottom: 6px; font-size: var(--font-size-12); font-weight: var(--font-weight-medium); color: var(--color-text-secondary); }
.pa-rad { display: flex; align-items: center; gap: var(--space-3); min-height: 44px; padding: 0 var(--space-3); border: 1px solid var(--color-border-default); border-radius: var(--radius-sm); font-size: var(--font-size-14); cursor: pointer; }
.pa-rad:has(input:checked) { border-color: var(--color-lilac-600); background: var(--color-lilac-50); }
.pa-rad.is-off { color: var(--color-text-tertiary); cursor: not-allowed; }
.pa-rad small { display: block; font-size: var(--font-size-12); color: var(--color-text-tertiary); }
.pa-rad input { accent-color: var(--color-lilac-700); width: 16px; height: 16px; }
.pa-rad:focus-within { outline: 2px solid var(--color-border-focus); outline-offset: 1px; }
.pa-flsh select { width: 100%; height: 44px; }
.pa-flsh .p2-flsh__ft { align-items: center; gap: var(--space-4); }
.pa-flsh .p2-flsh__ft .b { flex: 1; }
.pa-svl { margin: 0; padding: 0; list-style: none; display: grid; gap: var(--space-2); }
.pa-svl li { display: flex; align-items: center; gap: var(--space-2); }
.pa-svl li .field { flex: 1; margin: 0; }
.pa-svl li.is-del input { text-decoration: line-through; color: var(--color-text-tertiary); }

/* ── Card seg groups (series + Day | Week | Month) ── */
.pa-segs { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: var(--space-2); }
.pa-seg button[aria-disabled="true"] { color: var(--color-text-disabled); cursor: not-allowed; }
.pa-seg button:focus-visible { outline: 2px solid var(--color-border-focus); outline-offset: 1px; }
@container page (max-width: 560px) { .pa-card .ovc-h { flex-wrap: wrap; } .pa-card .ovc-r { width: 100%; justify-content: flex-start; } .pa-segs { justify-content: flex-start; } }

/* ── W11 Overview ── */
.pa-now-line { display: flex; flex-wrap: wrap; gap: 4px var(--space-2); margin: 0 0 var(--space-3); font-size: var(--font-size-13); color: var(--color-text-secondary); font-variant-numeric: tabular-nums; }
.pa-now-line b { color: var(--color-text-primary); font-weight: var(--font-weight-semibold); }
.pa-tile .pa-seg { margin-top: var(--space-2); }
.pa-tile .ovc-tog button { min-height: 24px; }
.pa-needs { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2) var(--space-5); margin: calc(-1 * var(--space-px, 1px)) 0 var(--space-5); padding: var(--space-3) var(--space-5); border: 1px solid var(--color-border-subtle); border-top: 0; border-radius: 0 0 var(--radius-md) var(--radius-md); background: var(--color-bg-canvas); font-size: var(--font-size-13); }
.pa-tiles + .pa-needs { margin-top: -1px; }
.pa-needs__h { color: var(--color-text-tertiary); }
.pa-needs ul { display: contents; list-style: none; }
.pa-needs li { min-width: 0; }
.pa-needs a { display: inline-flex; align-items: center; gap: var(--space-2); color: var(--color-text-secondary); text-decoration: none; border-radius: var(--radius-xs); }
.pa-needs a b { color: var(--color-text-primary); font-weight: var(--font-weight-semibold); }
.pa-needs a .gi { flex: none; image-rendering: pixelated; }
@media (hover: hover) and (pointer: fine) { .pa-needs a:hover b { text-decoration: underline; text-underline-offset: 2px; } }
.pa-ovg { margin-top: var(--space-5); }
.pa-tiles:not(:has(+ .pa-needs)) { margin-bottom: var(--space-5); }
.pa-prow__g { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: var(--space-8); align-items: start; }
.pa-prow .ovpay .ovpb { margin: var(--space-4) 0 0 !important; }
@container page (max-width: 900px) { .pa-prow__g { grid-template-columns: minmax(0, 1fr); gap: var(--space-5); } }
.pa-stat { margin: var(--space-3) 0 0; font-size: var(--font-size-13); color: var(--color-text-secondary); font-variant-numeric: tabular-nums; }
.pa-stat b { color: var(--color-text-primary); font-weight: var(--font-weight-semibold); }
.pa-tiles--in { margin: 0; }

/* ── W12 Directories ── */
.pa-dir { margin-top: var(--space-5); border: 1px solid var(--color-border-subtle); border-radius: var(--radius-md); background: var(--color-bg-canvas); overflow: hidden; }
.pa-dir > .pa-tiles { border: 0; border-bottom: 1px solid var(--color-border-subtle); border-radius: 0; margin: 0; }
.pa-ftile { cursor: pointer; text-align: left; font: inherit; border: 0; }
.pa-ftile[aria-pressed="true"] { box-shadow: inset 0 -2px 0 var(--color-text-primary); }
.pa-ftile:focus-visible { outline: 2px solid var(--color-border-focus); outline-offset: -2px; }
.pa-dir__bar { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2) var(--space-4); padding: 8px var(--space-4); border-bottom: 1px solid var(--color-border-subtle); font-size: var(--font-size-13); color: var(--color-text-secondary); }
.pa-dir__bar .search { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 8px; border: 1px solid var(--color-border-default); border-radius: var(--radius-sm); min-width: 0; }
.pa-dir__bar .search svg { width: 14px; height: 14px; color: var(--color-text-tertiary); flex: none; }
.pa-dir__bar .search input { border: 0; outline: 0; background: none; font: inherit; width: 200px; max-width: 40vw; color: var(--color-text-primary); }
.pa-dir__bar .search:focus-within { outline: 2px solid var(--color-border-focus); outline-offset: 1px; }
.pa-dir__bar .end { margin-left: auto; display: inline-flex; align-items: center; gap: var(--space-3); }
.pa-dir .pa-tw { border: 0; }
.pa-dir .pa-ts { border-radius: 0; }
.pa-tick { width: 16px; height: 16px; margin: 0 var(--space-2) 0 0; vertical-align: -3px; accent-color: var(--color-lilac-700); }
.pa-tick:focus-visible { outline: 2px solid var(--color-border-focus); outline-offset: 2px; }
.pa-ini { display: inline-grid; place-items: center; width: 22px; height: 22px; margin-right: var(--space-2); border-radius: var(--radius-xs); background: var(--color-bg-surface); color: var(--color-text-secondary); font-size: 11px; font-weight: var(--font-weight-semibold); vertical-align: middle; }
.pa-cellsub { display: block; font-size: 11px; color: var(--color-text-tertiary); font-weight: var(--font-weight-regular); }
.pa-tbl .st { height: 20px; }
.pa-tbl td .st + .st { margin-left: 4px; }
.pa-dirgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-4); margin-top: var(--space-5); }
.pa-dirgrid > .pa-card { margin: 0; }
@container page (max-width: 900px) { .pa-dirgrid { grid-template-columns: minmax(0, 1fr); } }
.pa-dir .empty { padding: var(--space-8) var(--space-5); }
.pa-tbl a:focus-visible, .pa-tbl button:focus-visible { outline: 2px solid var(--color-border-focus); outline-offset: 2px; }
.pa-rowbtn { padding: 0; border: 0; background: none; font: inherit; color: inherit; text-align: left; cursor: pointer; text-decoration: underline; text-decoration-color: var(--color-border-default); text-underline-offset: 3px; }

/* ── W13 Partner page ── */
.pa-ehead { display: inline-flex; align-items: center; gap: var(--space-2); }
.pa-ehead .pa-pick .msel.sel { height: 36px; padding: 0 26px 0 0; border: 0; background-color: transparent; font-family: var(--font-family-display); font-size: 22px; font-weight: var(--font-weight-semibold); letter-spacing: -0.01em; color: var(--color-text-primary); }
.pa-ehead .pa-pick .msel.sel:focus-visible { outline: 2px solid var(--color-border-focus); outline-offset: 2px; }
.pa-stepper { display: inline-flex; gap: 2px; }
.pa-stepper .b--icon { width: 28px; height: 28px; }
.pa-stepper .b--icon svg { width: 16px; height: 16px; }
.pa-crumb { display: block; margin: 0 0 var(--space-1); font-size: var(--tiny); color: var(--color-text-tertiary); text-decoration: none; }
.pa-crumb:hover { color: var(--color-text-primary); }
.pa-ptiles { margin-top: var(--space-1); }
.pa-blocks2 { margin-top: var(--space-5); }
.pa-camp-tbl .pa-tag { margin-left: 4px; }
.pa-wc { display: inline-flex; align-items: center; height: 20px; padding: 0 6px; margin-left: var(--space-2); border-radius: var(--radius-xs); background: var(--color-bg-surface); font-size: 11px; font-weight: var(--font-weight-medium); color: var(--color-text-secondary); }
/* drawer peek */
.pa-dw .dw-who { padding-right: 150px; }
.pa-dw .dw-figs { margin-top: var(--space-4); }
.pa-dw .dw-sec .pa-rows { margin-top: var(--space-2); }
.pa-dw .dw-acts { flex-wrap: wrap; }
.pa-dw .dw-meta { white-space: normal; }
.pa-dw h2:focus-visible { outline: 2px solid var(--color-border-focus); outline-offset: 2px; }
.pa-dw .dw-nav .b--icon svg { width: 16px; height: 16px; }
@media (max-width: 760px) { .pa-dw .dw-who { padding-right: 0; padding-top: 32px; } }

/* ── W10 ⌘K palette (K06) ── */
#dlg.pa-cmdk { width: min(600px, calc(100vw - 32px)); padding: 0; }
.pa-cmdk__q { display: flex; align-items: center; gap: var(--space-2); padding: var(--space-3) var(--space-4); border-bottom: 1px solid var(--color-border-subtle); }
.pa-cmdk__q svg { width: 16px; height: 16px; color: var(--color-text-tertiary); flex: none; }
.pa-cmdk__q input { flex: 1; min-width: 0; height: 32px; border: 0; outline: 0; background: none; font: inherit; font-size: var(--font-size-16); color: var(--color-text-primary); }
.pa-cmdk__l { max-height: min(420px, 60vh); overflow: auto; padding: var(--space-2); }
.pa-cmdk__g { margin: var(--space-2) var(--space-2) 4px; font-size: 11px; color: var(--color-text-tertiary); }
.pa-cmdk__i { display: flex; align-items: center; gap: var(--space-3); min-height: 40px; padding: 0 var(--space-3); border-radius: var(--radius-sm); cursor: pointer; font-size: var(--font-size-14); }
.pa-cmdk__i .gi { image-rendering: pixelated; flex: none; }
.pa-cmdk__i small { margin-left: auto; color: var(--color-text-tertiary); font-size: var(--font-size-12); }
.pa-cmdk__i[aria-selected="true"] { background: var(--color-bg-surface); }
.pa-cmdk__f { padding: var(--space-2) var(--space-4); border-top: 1px solid var(--color-border-subtle); font-size: 11px; color: var(--color-text-tertiary); }
.pa-cmdk__none { padding: var(--space-5) var(--space-3); color: var(--color-text-tertiary); font-size: var(--font-size-13); }
.pa-kbd { display: inline-flex; align-items: center; height: 20px; padding: 0 6px; border: 1px solid var(--color-border-default); border-radius: var(--radius-xs); font-size: 11px; color: var(--color-text-tertiary); }
.pa-find { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 var(--space-2); border: 1px solid var(--color-border-default); border-radius: var(--radius-sm); background: none; color: var(--color-text-secondary); font: inherit; font-size: var(--font-size-13); cursor: pointer; }
.pa-find svg { width: 14px; height: 14px; }
.pa-find:focus-visible { outline: 2px solid var(--color-border-focus); outline-offset: 1px; }
@media (max-width: 760px) { .pa-find span, .pa-find .pa-kbd { display: none; } .pa-find { width: 44px; height: 44px; justify-content: center; border: 0; } }

@media (prefers-reduced-motion: reduce) { .pa-ppop, .pa-flsh { transition: none !important; animation: none !important; } }

/* linked tiles (pa-cards.js tile): the label is the link, stretched over the tile; the ⓘ sits above it */
.pa-tile--link { cursor: pointer; }
.pa-tile--link .pa-tile-a { color: inherit; text-decoration: none; }
.pa-tile--link .pa-tile-a::after { content: ""; position: absolute; inset: 0; z-index: 0; }
.pa-tile--link .pa-i { position: relative; z-index: 1; }
.pa-tile--link:has(.pa-tile-a:focus-visible) { outline: 2px solid var(--color-border-focus); outline-offset: -2px; }
.pa-tile--link .pa-tile-a:focus-visible { outline: none; }
@media (hover: hover) and (pointer: fine) { .pa-tile--link:hover { background: var(--color-bg-surface) !important; } }
/* peek figures: two across so long values never collide */
.pa-dw .dw-figs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: var(--space-3); }
.pa-dw .dw-figs > div { padding: 0 var(--space-4) 0 0; border: 0 !important; }
.pa-dw .dw-figs dd { white-space: normal; }
.pa-dw h2[tabindex="-1"]:focus { outline: none; }
.pa-ehead .pa-pick .msel.sel { max-width: none; width: auto; min-width: 0; background-position: right 4px center; }
.pa-ehead .pa-pick .msel__t { overflow: visible; }
.pa-ptiles .dt-l { white-space: normal; overflow: visible; text-overflow: clip; line-height: 1.25; }
@container page (max-width: 1180px) { .pa-ptiles { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; } }
@container page (max-width: 560px) { .pa-ehead .pa-pick .msel.sel { font-size: 18px; } }
/* W17: a locked action's reason, in sight on the partner page */
.pa-lockline { display: inline-flex; align-items: center; gap: 6px; color: var(--color-text-secondary); }
.pa-lockline .pa-lock { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.75; }
/* the period popover stays under its trigger: presets and calendar shortcuts two across */
.pa-ph .pa-tags { min-width: 0; }
.pa-lockline { flex-basis: 100%; white-space: normal; min-width: 0; }
/* the head's action column sizes to its buttons on desktop (a wrapping row let a locked label spill past the page) */
@media (min-width: 761px) { .pa-ph > .acts { min-width: max-content; } .pa-ph .pa-acts { flex-wrap: nowrap; } }
/* hd.css sizes column 1 to max-content: tags span both columns so a long lock reason can't widen it */
.pa-ph .pa-tags { grid-column: 1 / -1 !important; }

/* ── Fix pass 1 (27 Nov) ── */
/* polish S7: Needs a look is a box of its own under the strip, with its lid */
.pa-needs, .pa-tiles + .pa-needs { margin: var(--space-3) 0 var(--space-5); border: 1px solid var(--color-border-subtle); border-radius: var(--radius-sm); align-items: baseline; }
/* UX W02: the pace line under the gauge centre, above the stat boxes */
.pa-pace--mid { justify-content: center; margin: var(--space-2) 0 0; text-align: center; }
.pa-pace--mid b { color: var(--color-text-primary); font-weight: var(--font-weight-semibold); }
.pa-prow .ovgg { max-width: 280px; }
/* polish B2 + UX W12: the entity title (partner and location) sits at the page-title size and is never clipped; it may wrap */
.pa-ph .msel .msel__t, .pa-ehead .pa-pick .msel__t { overflow: visible; text-overflow: clip; white-space: normal; gap: 6px; }
.pa-ehead .pa-pick .msel.sel, .pa-ph .ap-title .msel.sel { font-size: var(--font-size-24); height: auto; min-height: 36px; max-width: min(60ch, 100%); }
@container page (max-width: 560px) { .pa-ehead .pa-pick .msel.sel, .pa-ph .ap-title .msel.sel { font-size: var(--font-size-20); } .pa-ehead { flex-wrap: wrap; } }
/* polish S9: every partner figure starts on one line; 1180 and under: 4 across with the lead tile on two, so no empty cell */
.pa-ptiles .dt-h { min-height: 34px; align-items: flex-start; }
@container page (max-width: 1180px) { .pa-ptiles > :first-child { grid-column: span 2; } }
/* UX W01 / polish B1 (Q57): at phone width two across, the lead tile full width, then six tiles in three rows */
@container page (max-width: 560px) {
  .pa-ptiles { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
  .pa-ptiles > :first-child { grid-column: 1 / -1; }
  .pa-ptiles .dt-h { min-height: 0; }
  /* polish S11: no dead band under the card head at phone width */
  .pa-card .ovc-h { flex-wrap: nowrap; }
  .pa-card .ovc-r:empty { display: none; }
  .pa-card .ovc-h:has(.pa-segs, .ovc-tog) { flex-wrap: wrap; }
  .pa-card .ovc-r:not(:has(.pa-segs, .ovc-tog)) { width: auto; margin-left: auto; }
  /* UX W18: the ⌘K row puts the category under the name */
  .pa-cmdk__i { flex-wrap: wrap; padding: 6px var(--space-3); }
  .pa-cmdk__i small { margin-left: 28px; flex-basis: 100%; }
}
/* data QA S8: long names wrap to two lines in a table; the number columns keep their width */
.pa-tbl .pa-td-1 { white-space: normal; min-width: 180px; max-width: 320px; overflow-wrap: anywhere; line-height: 1.3; }
.pa-tbl .pa-td-1 > a, .pa-tbl .pa-td-1 > .pa-rowbtn { display: -webkit-inline-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; vertical-align: middle; max-width: calc(100% - 28px); }
@container page (max-width: 560px) { .pa-tbl .pa-td-1 { min-width: 140px; max-width: 200px; } }
/* 30 Nov: the directory name cell (PA.charts.lead). Takes the name's own width on one line; only a name past the cap wraps, under itself */
.pa-tbl .pa-td-1:has(> .pa-lead) { min-width: 0; padding-top: 4px; padding-bottom: 4px; }
.pa-lead { display: flex; align-items: center; gap: var(--space-3); width: max-content; max-width: 288px; line-height: 1.3; }
.pa-lead__tick { position: relative; display: grid; place-items: center; flex: none; width: 16px; height: 16px; cursor: pointer; }
.pa-lead__tick::after { content: ''; position: absolute; inset: -10px -6px -10px -14px; }
.pa-lead__tick .pa-tick { margin: 0; cursor: pointer; }
.pa-lead__t { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; min-width: 0; }
.pa-lead__a { display: flex; align-items: center; gap: var(--space-2); min-width: 0; max-width: 100%; }
.pa-lead__a .pa-ini { flex: none; margin: 0; }
.pa-lead__n { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-width: 0; overflow-wrap: anywhere; }
.pa-lead__a:focus-visible { outline: 2px solid var(--color-border-focus); outline-offset: 2px; border-radius: var(--radius-xs); }
.pa-tbl tbody tr:has(.pa-tick:checked) > * { background: var(--color-bg-surface); }
@media (hover: hover) and (pointer: fine) { .pa-tbl tbody tr:hover .pa-ini { background: var(--color-bg-canvas); } }
@container page (max-width: 560px) { .pa-lead { max-width: 172px; gap: var(--space-2); } }
/* UX W05: Compare at phone width: the Measure column stays put and the card says the table scrolls; numbers are never cut */
.pa-cmp__more { display: none; }
@container page (max-width: 560px) { .pa-cmp__more { display: flex; } .pa-cmp td { min-width: 104px; } }
/* UX W18: a tile title wraps at phone width rather than "New registrat…" */
@container page (max-width: 560px) { .pa-tiles .dt-l { white-space: normal; overflow: visible; text-overflow: clip; line-height: 1.25; } }
/* polish N10: specimen code never breaks */
.pa-spec code, .pa-card code { white-space: nowrap; }
/* the entity title keeps its natural width (the ‹ › stepper wraps first); the card head wraps whenever its right side holds more than ↗ */
.pa-ehead .pa-pick { flex-shrink: 0; max-width: 100%; }
@container page (max-width: 560px) { .pa-card .ovc-h:has(.ovc-r > :not(.ovc-go)) { flex-wrap: wrap; } .pa-card .ovc-h:has(.ovc-r > :not(.ovc-go)) .ovc-r { width: 100%; justify-content: flex-start; margin-left: 0; } }
/* the entity title stays on one line on desktop (it wraps only at phone width, for very long names) */
.pa-ph .msel .msel__t, .pa-ehead .pa-pick .msel__t { white-space: nowrap; }
.pa-ph .ap-title .msel.sel, .pa-ehead .pa-pick .msel.sel { width: max-content; }
@container page (max-width: 560px) { .pa-ph .msel .msel__t, .pa-ehead .pa-pick .msel__t { white-space: normal; } .pa-ph .ap-title .msel.sel, .pa-ehead .pa-pick .msel.sel { width: auto; } }
/* UX W05 (Q57): at phone width Compare turns the matrix round: one block per measure, a row per item, nothing cut. Screen readers keep
   the real table (it stays in the page, visually hidden), so the phone blocks are aria-hidden */
.pa-cmp__ph { display: none; }
@container page (max-width: 560px) {
  .pa-cmp__desk { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .pa-cmp__ph { display: grid; gap: var(--space-4); }
  .pa-cmp__b dl { margin: 0; display: grid; gap: 4px; }
  .pa-cmp__b dl > div { display: flex; justify-content: space-between; gap: var(--space-3); padding: 6px 0; border-bottom: 1px solid var(--color-border-subtle); font-size: var(--font-size-13); }
  .pa-cmp__b dt { color: var(--color-text-secondary); min-width: 0; }
  .pa-cmp__b dd { margin: 0; text-align: right; font-weight: var(--font-weight-semibold); color: var(--color-text-primary); }
}
/* polish N8: the partner title's chevron keeps the same 6px gap as the location title */
.pa-ehead .pa-pick .msel.sel { padding-right: 30px; background-position: right 6px center; }
/* Final pass (27 Nov): the partner name stays on one line at every width. The switcher shrinks and ends in an ellipsis (the full
   name is in its title and aria-label); the previous / next chevrons never shrink, so both stay in reach. */
.pa-ph .ap-title:has(.pa-ehead) { display: block; min-width: 0; max-width: 100%; }
.pa-ehead { display: flex; flex-wrap: nowrap; max-width: 100%; min-width: 0; }
.pa-ehead .pa-pick { flex: 0 1 auto; min-width: 0; }
.pa-ph .ap-title .pa-ehead .pa-pick .msel.sel { width: auto; max-width: calc(100% + 6px); }   /* + its -6px optical margin, or the box shrinks under its own text */
.pa-ehead .pa-pick .msel__t { display: block; min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.pa-ehead .pa-stepper { flex: none; }
@container page (max-width: 560px) { .pa-ehead { flex-wrap: nowrap; } .pa-ehead .pa-pick .msel__t { white-space: nowrap; } .pa-ehead .pa-pick .msel.sel { width: auto; } }

/* ── 30 Nov: no table scrolls sideways. Paired columns share a cell; what still can't fit stacks (is-stack, set by bindPane) ── */
body:not(.rp-body) .pa-tw > .pa-ts { overflow: visible; }
.pa-tbl :is(th, td) { padding-left: var(--space-2); padding-right: var(--space-2); }
.pa-tbl :is(thead th:first-child, .pa-td-1) { padding-left: var(--space-4); }
.pa-tbl :is(thead th, td):last-child { padding-right: var(--space-4); }
.pa-tbl thead th { height: 48px; vertical-align: middle; }
.pa-tbl thead th .pa-sort { height: auto; min-height: 20px; line-height: 1.2; }
.pa-tbl thead th.r .pa-sort { width: max-content; max-width: 104px; white-space: normal; text-align: right; justify-content: flex-end; }
.pa-tbl thead .pa-sort svg { flex: none; }
.pa-tbl .pa-hsub { display: flex; align-items: center; gap: 6px; font-weight: var(--font-weight-regular); font-size: 11px; color: var(--color-text-tertiary); }
.pa-tbl th.r .pa-hsub { justify-content: flex-end; }
.pa-tbl .pa-hsub .pa-sort { color: inherit; }
.pa-tbl thead .pa-sort.is-on { color: var(--color-text-primary); }
[aria-sort] .pa-sort svg { opacity: .6; }
.pa-tbl .pa-sort.is-on svg { opacity: 1; }
[aria-sort="ascending"] .pa-sort:not(.is-on), [aria-sort="descending"] .pa-sort:not(.is-on) { color: inherit; }
.pa-hsub > i, .pa-under > i { font-style: normal; color: var(--color-text-tertiary); }
.pa-under { display: flex; align-items: center; gap: 4px; margin-top: 1px; font-variant-numeric: tabular-nums; color: var(--color-text-secondary); white-space: nowrap; }
.pa-tbl td.r .pa-under { justify-content: flex-end; }
.pa-tbl .pa-under .faint { color: inherit; }
.pa-tbl tbody :is(td, .pa-td-1) { padding-top: 6px; padding-bottom: 6px; }
.pa-tbl tr:has(.pa-tick:checked) .pa-ini { background: var(--color-bg-canvas); }
.pa-tbl td :is(.pa-st-completed, .pa-st-ended, .pa-st-scheduled) { background: var(--color-bg-surface); color: var(--color-text-secondary); }
.pa-tbl .pa-sksp { width: 96px; min-width: 96px; }
.pa-stset { display: inline-flex; flex-direction: column; align-items: flex-start; gap: 3px; }
.pa-tbl .pa-stset .st { margin: 0; }
.pa-spcell { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 4px; width: max-content; max-width: 256px; }
.pa-tbl .pa-spcell .st + .st { margin-left: 0; }
.pa-spcell .st { max-width: 100%; min-width: 0; }
.pa-spcell .st::before { flex: none; }
.pa-spcell .st > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.pa-evn { width: max-content; max-width: 260px; white-space: normal; line-height: 1.3; }
.pa-ssort { display: none; }

/* stacked rows */
.pa-tw.is-stack > .pa-ssort { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); padding: var(--space-3) var(--space-4); border-bottom: 1px solid var(--color-border-subtle); font-size: var(--font-size-13); color: var(--color-text-secondary); }
.pa-ssort select { height: 36px; max-width: 190px; margin-left: 6px; padding: 0 8px; border: 1px solid var(--color-border-default); border-radius: var(--radius-sm); background: var(--color-bg-canvas); color: var(--color-text-primary); font: inherit; font-weight: var(--font-weight-medium); }
.pa-ssort select:focus-visible { outline: 2px solid var(--color-border-focus); outline-offset: 1px; }
.is-stack .pa-tbl, .is-stack .pa-tbl tbody { display: block; }
.is-stack .pa-tbl thead { display: none; }
.is-stack .pa-tbl tbody tr { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(132px, 100%), 1fr)); gap: var(--space-3) var(--space-4); padding: var(--space-4); border-bottom: 1px solid var(--color-border-subtle); }
.is-stack .pa-tbl tbody tr:last-child { border-bottom: 0; }
.is-stack .pa-tbl tbody :is(th, td) { display: block; height: auto; min-width: 0; max-width: none; padding: 0; border: 0; text-align: left; white-space: normal; overflow-wrap: anywhere; background: none; }
.is-stack .pa-tbl .pa-td-1 { position: static; grid-column: 1 / -1; }
.is-stack .pa-tbl td::before, .is-stack .pa-tbl td .pa-under > [data-l]::before { content: attr(data-l); display: block; margin-bottom: 2px; font-size: 11px; font-weight: var(--font-weight-regular); color: var(--color-text-tertiary); }
.is-stack .pa-tbl td .pa-under { display: block; margin-top: 6px; font-size: var(--row); color: var(--color-text-primary); white-space: normal; }
.is-stack .pa-tbl td .pa-under > i { display: none; }
.is-stack .pa-lead, .is-stack .pa-evn { width: auto; max-width: 100%; }
.is-stack .pa-lead__n { -webkit-line-clamp: none; }
.is-stack .pa-lead .pa-under { flex-wrap: wrap; white-space: normal; }
.is-stack .pa-lead .pa-ini { display: inline-grid; }
.is-stack .pa-spcell { width: auto; max-width: 100%; }
.is-stack .pa-tbl td:has(.pa-spcell) { grid-column: 1 / -1; }
body:not(.rp-body) .is-stack .pa-tbl td { position: static; padding: 0; }
body:not(.rp-body) .is-stack .pa-tbl td .pa-inl { display: none; }
@media (hover: hover) and (pointer: fine) { .is-stack .pa-tbl tbody tr:hover, .is-stack .pa-tbl tbody tr:hover > * { background: none; } }
.is-stack .pa-tbl tbody tr:has(.pa-tick:checked) { background: var(--color-bg-surface); }
.pa-td-1 .pa-under { flex-wrap: wrap; max-width: 272px; white-space: normal; overflow-wrap: anywhere; }
@container page (max-width: 560px) { .is-stack .pa-tbl tbody tr { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px var(--space-3); } }
.pa-lead > .pa-ini { flex: none; width: 28px; height: 28px; margin: 0; }
.pa-lead > .gi { flex: none; }
.pa-lead { gap: 10px; }
.pa-tbl td .pa-stset .st + .st { margin-left: 0; }
.is-stack .pa-tbl td:has(.pa-stset) { grid-column: 1 / -1; }
.is-stack .pa-stset { flex-direction: row; flex-wrap: wrap; }
.pa-ssort label { display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.pa-ssort select { margin-left: 0; }
.pa-ssort .b { white-space: nowrap; }
@container page (max-width: 560px) { .pa-ssort select { max-width: 132px; } }
.pa-tw--dense .pa-tbl tbody :is(th, td) { height: 52px; }
.is-stack .pa-tbl tbody :is(th, td) { height: auto !important; }
