.table:not(.table-row-headings) th {
  white-space: nowrap;
}
.table th,
.table td {
  border: none;
}
.table thead + tbody {
  border-top: 1px solid var(--color-border-strong);
}
.table tr:not(:last-of-type) td,
.table tr:not(:last-of-type) th {
  border-bottom: 1px solid var(--color-border-weak);
}

.table td,
.table th {
  padding: 1em 1em;
}
.table td:first-child,
.table th:first-child {
  padding-left: 1em;
}
.table td:last-child,
.table th:last-child {
  padding-right: 1em;
}

.table {
  position: relative;
}
.table:before {
  content: "";
  pointer-events: none;
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  border: 1px solid var(--color-border-strong);
  border-radius: var(--bs-border-radius);
}

@media (max-width:500px) {
  .table-row-headings th, 
  .table-row-headings td {
    display: block;
    width: 100% !important;
  }
  .table-row-headings th {
    padding-bottom: 0 !important;
    border-bottom: none !important;
  }
}

/* When defining django-table2 columns, prefer `cell-` classes for styling table columns for more 
   consistent styling between tables e.g.                                                         
   num_indicators = tables.Column(_("Indicators"), attrs={"cell": {"class": "cell-number"}})      */
.cell-number {
  text-align: right;
}
.cell-date {
  white-space: nowrap;
}
.cell-nowrap {
  white-space: nowrap;
}
.cell-medium {
  min-width: 20ch;
}
/* Field specific styling */
.table [data-field="email"],
.table [data-field="name"],
.table [data-field="facilitator"],
.table [data-field="username"] {
  max-width: 20ch;
  overflow-wrap: break-word;
}