/* Only the detailed data grid: leave pinned identifiers, body cells and
   the existing sort/resize controls and column widths in place. */
html:root body #app main.cross-page .workbench>.table-wrap table thead th[data-column]:not([data-xl-fixed]){
  text-align:center!important;
  padding-inline:4px!important;
}

html:root body #app main.cross-page .workbench>.table-wrap thead th[data-column]>.xl-metric-sort327{
  position:relative;
  inline-size:100%!important;
  justify-content:center!important;
  gap:0!important;
  text-align:center!important;
}

html:root body #app main.cross-page .workbench>.table-wrap thead .xl-metric-sort327>span:first-child{
  min-inline-size:0;
  max-inline-size:calc(100% - 16px);
  white-space:normal;
  overflow-wrap:anywhere;
  text-align:center;
}

html:root body #app main.cross-page .workbench>.table-wrap thead .xl-metric-sort327>.xl-sort-arrows327{
  position:absolute;
  inset-inline-end:0;
  inline-size:8px!important;
  min-inline-size:0!important;
  padding:0!important;
  text-align:center;
  line-height:1;
  font-size:9px!important;
  pointer-events:none;
}

html:root body #app main.cross-page .workbench>.table-wrap thead .xl-history-sort-head351{
  container:xl-board-history/inline-size;
  display:grid;
  justify-items:center;
  grid-template-columns:minmax(0,1fr);
  gap:2px;
  text-align:center;
}

/* Keep the original one-line height when the history column has room for
   the sort select beside (not as part of) the centered heading. */
@container xl-board-history (min-width:210px){
  .xl-history-sort-head351>:is(span,select){grid-area:1/1}
  .xl-history-sort-head351>select{justify-self:end}
}

html:root[data-xl-mobile-board] body #app main.cross-page .workbench>.table-wrap table thead th[data-column]:not([data-xl-fixed]){
  padding-inline:2px!important;
}
