/*
 * TablePress in the look of Enfold.
 * The ID refers to themes/ricamsterdam/CUSTOMIZATIONS.md.
 *
 * TablePress 3 draws its tables from CSS variables on ".tablepress", in a stylesheet
 * that loads after this one; "#top" puts the values below ahead of its own. They come
 * from Enfold's variables, with the RIC values as fallback.
 */

/* P-08 RIC-style tables */
#top .tablepress {
  --head-bg-color: var(--enfold-main-color-primary, #e57200);
  --head-text-color: var(--enfold-main-color-constant-font, #ffffff);
  /* Sorting by a column keeps the header orange; the arrows show the order. */
  --head-active-bg-color: var(--head-bg-color);
  --border-color: var(--enfold-main-color-border, #e1e1e1);
}

/* Enfold sets header cells in bold capitals with letter spacing. */
#top .tablepress thead th {
  letter-spacing: normal;
  text-transform: none;
  vertical-align: top;
}
#top .tablepress thead th,
#top .tablepress tbody td {
  font-size: 98%;
  font-weight: 400;
  border: 1px solid var(--border-color);
}

/* A table wider than the screen scrolls on its own instead of widening the page.
   Tables with TablePress' "horizontal scrolling" already do. */
.dt-container .dt-layout-table > .dt-layout-cell {
  overflow-x: auto;
}

/* The search field next to its label. Enfold makes every search field full width,
   with a margin below it that would push the label down. */
#top .dt-container .dt-search {
  margin-bottom: 10px;
}
#top .dt-container .dt-search .dt-input {
  width: auto;
  margin-bottom: 0;
}

.tablepress.fixedHeader-floating,
.tablepress.fixedHeader-locked {
  z-index: 999;
}
