/* Loaded after the Console theme styles to override the queue's fixed row
   heights, percentage columns and hidden horizontal scrollbar. */

/* Responsive overflow: the table scrolls inside its own wrap, never the page. */
body .operator-shell .console-v3 .focus-table-card .triage-table-scroll {
  overflow-x: auto;
  scrollbar-width: auto;
  overscroll-behavior-x: contain;
}

body .operator-shell .console-v3 .focus-table-card .triage-table-scroll::-webkit-scrollbar {
  display: block;
  height: 10px;
}

body .operator-shell .console-v3 .focus-table-card .triage-table-scroll:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: -2px;
}

body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable {
  --console-table-secondary: #c4d6cc;
  background-color: #0e1c18 !important;
  table-layout: fixed !important;
  width: 100% !important;
  min-width: 720px !important;
  max-width: none !important;
  height: auto !important;
  border-collapse: separate !important;
  border-spacing: 0 !important;
}

/* Stable column sizing: fixed tracks for compact data; the title takes the rest. */
body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable th:nth-child(1),
body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable td:nth-child(1) { width: 82px !important; }
body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable th:nth-child(2),
body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable td:nth-child(2) { width: 128px !important; }
body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable th:nth-child(3),
body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable td:nth-child(3) { width: auto !important; }
body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable th:nth-child(4),
body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable td:nth-child(4) { width: 80px !important; }
body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable th:nth-child(5),
body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable td:nth-child(5) { width: 116px !important; }
body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable th:nth-child(6),
body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable td:nth-child(6) { width: 156px !important; }

/* Content-driven row height. */
body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable tr.triage-table__row {
  height: auto !important;
  min-height: 0 !important;
}

body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable tbody td {
  height: auto !important;
  min-width: 0 !important;
  padding: 10px 12px !important;
  vertical-align: middle !important;
  overflow: hidden !important;
}

body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable td.triage-table__title-cell {
  vertical-align: top !important;
}

/* Two-line title clamp; long tokens (URLs, IDs) break instead of overflowing. */
body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable .triage-table__title-wrap {
  display: flex !important;
  flex-direction: column !important;
  gap: 4px !important;
  min-width: 0 !important;
  height: auto !important;
  position: static !important;
}

body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable .triage-table__title {
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
  min-height: 0 !important;
  max-height: none !important;
  height: auto !important;
  line-height: 1.32 !important;
  white-space: normal !important;
  overflow-wrap: anywhere !important;
  text-overflow: clip !important;
  position: static !important;
}

/* Legible secondary metadata: its own line below the title, wrapping by item. */
body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable .triage-table__subline {
  display: flex !important;
  flex-wrap: wrap !important;
  align-items: center !important;
  column-gap: 6px !important;
  row-gap: 2px !important;
  min-width: 0 !important;
  height: auto !important;
  max-height: none !important;
  margin: 0 !important;
  position: static !important;
  overflow: hidden !important;
  white-space: normal !important;
  font-size: 12px !important;
  line-height: 1.35 !important;
  font-weight: 500 !important;
  letter-spacing: 0.01em !important;
  color: var(--console-table-secondary) !important;
  opacity: 1 !important;
}

body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable .triage-table__subline > span {
  position: static !important;
  max-width: 100% !important;
  overflow: hidden !important;
  white-space: nowrap !important;
  text-overflow: ellipsis !important;
}

body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable .triage-table__source,
body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable .triage-table__category:not([style]) {
  color: inherit !important;
}

body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable .triage-table__dot {
  opacity: 0.55 !important;
}

/* Compact IDs: monospace, one line, ellipsis. The cell's title attribute
   holds the full ID. */
body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable .triage-table__id {
  display: block !important;
  max-width: 100% !important;
  overflow: hidden !important;
  white-space: nowrap !important;
  text-overflow: ellipsis !important;
  font-family: var(--font-mono, ui-monospace, SFMono-Regular, Menlo, Consolas, monospace) !important;
  font-size: 11px !important;
  line-height: 1.3 !important;
}

body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable .triage-table__team {
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
  white-space: normal !important;
  overflow-wrap: anywhere !important;
  line-height: 1.3 !important;
}

body[data-theme="daylight"] .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable {
  --console-table-secondary: #36463d;
  background-color: #f7f8f4 !important;
}

@media (max-width: 640px) {
  body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable {
    min-width: 680px !important;
  }

  body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable th:nth-child(2),
  body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable td:nth-child(2) {
    width: 104px !important;
  }

  body .operator-shell .console-v3 .focus-table-card table.triage-table.triage-table--readable tbody td {
    padding: 9px 10px !important;
  }
}
