/**
 * @file
 * Visual styles for Base+'s tables.
 */
table {
  border-collapse: separate;
  border-spacing: 0;
  width: 100%;
  margin: 0 0 40px;
  border-style: solid;
  border-width: 1px;
}
table:not(.table-responsive) {
  overflow: hidden;
}
.table-responsive {
  margin-bottom: 40px;
}
.table-responsive table {
  margin-bottom: 0;
}
table tr th {
  border-style: solid;
  border-width: 0;
  padding: 20px 26px;
  font-weight: 700;
  color: var(--mt-color-high-contrast);
}
.region--default-background {
  --mt-table-head-background-color: rgba(var(--mt-color-default-contrast-value), 0.03);
}
.region--bright-background {
  --mt-table-head-background-color: rgba(var(--mt-color-bright-contrast-value), 0.03);
}
.region--accent-background {
  --mt-table-head-background-color: rgba(var(--mt-color-accent-contrast-value), 0.03);
}
.region--tint-background {
  --mt-table-head-background-color: rgba(var(--mt-color-tint-contrast-value), 0.1);
}
.region--shade-background {
  --mt-table-head-background-color: rgba(var(--mt-color-shade-contrast-value), 0.1);
}
.region--colored-background {
  --mt-table-head-background-color: rgba(var(--mt-color-colored-contrast-value), 0.1);
}
.region--dark-colored-background {
  --mt-table-head-background-color: rgba(var(--mt-color-dark-colored-contrast-value), 0.1);
}
.region--dark-background {
  --mt-table-head-background-color: rgba(var(--mt-color-dark-contrast-value), 0.1);
}
table tr th {
  background-color: var( --mt-table-head-background-color);
}
.region--pattern table tr th {
  background-color: #f9f9f9;
}
.region--pattern table tr td {
  background-color: var(--mt-color-pattern);
}
.region--default-background {
  --mt-table-border-color: var(--mt-form-border);
}
.region--bright-background {
  --mt-table-border-color: var(--mt-form-border);
}
.region--accent-background {
  --mt-table-border-color: rgba(var(--mt-color-accent-contrast-value), 0.1);
}
.region--tint-background {
  --mt-table-border-color: rgba(var(--mt-color-tint-contrast-value), 0.1);
}
.region--shade-background {
  --mt-table-border-color: var(--mt-form-border-contrast);
}
.region--colored-background {
  --mt-table-border-color: var(--mt-form-border-contrast);
}
.region--dark-colored-background {
  --mt-table-border-color: var(--mt-form-border-contrast);
}
.region--dark-background {
  --mt-table-border-color: var(--mt-form-border-contrast);
}
.region--pattern {
  --mt-table-border-color: var(--mt-form-border);
}
table {
  border-color: var(--mt-table-border-color);
}


@media (max-width: 767px) {
  .table-responsive table {
    border-width: 0;
  }
  .table-responsive {
    border-width: 1px;
    border-style: solid;
  }
  .table-responsive {
    border-color: var(--mt-table-border-color);
  }
  .region--default-background .table-responsive table tr td {
    background-color: var(--mt-color-default);
  }
  .region--shade-background .table-responsive table tr td {
    background-color: var(--mt-color-shade);
  }
  .region--colored-background .table-responsive table tr td {
    background-color: transparent;
  }
  .region--dark-colored-background .table-responsive table tr td {
    background-color: var(--mt-color-dark-colored);
  }
  .region--dark-background .table-responsive table tr td {
    background-color: var(--mt-color-dark);
  }
}
.headings-wide-spacing-enabled table tr th {
  letter-spacing: var(--mt-headings-letter-spacing);
  text-transform: uppercase;
}
table thead tr:first-child th {
  border-bottom-width: 0;
}
table tr td {
  border-style: solid;
  border-width: 0;
  padding: 12px 26px;
  font-weight: 400;
}
table tr:last-child td {
  padding-bottom: 16px;
}
table thead + tbody tr:first-child th,
table thead + tbody tr:first-child td {
  padding-top: 24px;
  border-top-width: 0;
}
table tr th:first-child,
table tr td:first-child {
  border-left-width: 0px;
}
table tr th:last-child,
table tr td:last-child {
  border-right-width: 0px;
}
td.is-active {
  background-color: var(--mt-active-cell);
}

/* Table caption */
table caption {
  padding: 10px 0;
  font-size: 16px;
  color: inherit;
}

/* layout builder */
#layout-builder-modal table tr td {
  padding: 12px 15px;
}
