/* Shared controls for list tables: manual column widths and clear sort state. */
.onecup-list-table > thead > tr > th {
  position: relative;
}

.onecup-list-table.onecup-table-layout-fixed {
  table-layout: fixed;
  max-width: none;
}

.onecup-list-table.onecup-table-layout-fixed > thead > tr > th,
.onecup-list-table.onecup-table-layout-fixed > tbody > tr > td {
  overflow: hidden;
  text-overflow: ellipsis;
}

.onecup-list-table .onecup-sortable-column {
  cursor: pointer;
  padding-right: 34px !important;
  user-select: none;
}

.onecup-list-table .onecup-sortable-column:focus-visible {
  outline: 2px solid var(--onecup-primary, #1f7aec);
  outline-offset: -2px;
}

.onecup-list-table .onecup-sortable-column[aria-sort="none"]::after {
  content: "\2195";
  position: absolute;
  top: 50%;
  right: 17px;
  color: rgba(24, 26, 85, .36);
  font-size: 12px;
  line-height: 1;
  transform: translateY(-50%);
  pointer-events: none;
}

.onecup-list-table .onecup-sortable-column > i.fa-sort-amount-up-alt,
.onecup-list-table .onecup-sortable-column > i.fa-sort-amount-down-alt {
  right: 17px !important;
}

.onecup-column-resizer {
  position: absolute;
  z-index: 4;
  top: 0;
  right: -4px;
  width: 11px;
  height: 100%;
  min-height: 28px;
  cursor: col-resize;
  touch-action: none;
}

.onecup-column-resizer::before {
  content: "";
  position: absolute;
  top: 5px;
  bottom: 5px;
  left: 5px;
  width: 2px;
  border-radius: 2px;
  background: rgba(24, 26, 85, .18);
  transition: background-color .15s ease, box-shadow .15s ease;
}

.onecup-column-resizer:hover::before,
.onecup-column-resizer:focus-visible::before,
.onecup-column-resizer.is-resizing::before {
  background: var(--onecup-primary, #1f7aec);
  box-shadow: 0 0 0 2px rgba(31, 122, 236, .16);
}

.onecup-column-resizer:focus-visible {
  outline: none;
}

body.onecup-column-resizing,
body.onecup-column-resizing * {
  cursor: col-resize !important;
  user-select: none !important;
}

@media (pointer: coarse) {
  .onecup-column-resizer {
    right: -7px;
    width: 17px;
  }

  .onecup-column-resizer::before {
    left: 8px;
  }
}

