/**
NGX DataTable tweaks
 */

div.card-body.card-datatable .ngx-datatable.material {
  background: $theme-white-base;
  border: 0px;
  box-shadow: unset;
}

.table-header-primary thead {
  background-color: $theme-color-primary;
  color: white !important;
}

.ngx-datatable.material.single-selection .datatable-body-row.active,
.ngx-datatable.material.single-selection .datatable-body-row.active .datatable-row-group,
.ngx-datatable.material.multi-selection .datatable-body-row.active,
.ngx-datatable.material.multi-selection .datatable-body-row.active .datatable-row-group,
.ngx-datatable.material.multi-click-selection .datatable-body-row.active,
.ngx-datatable.material.multi-click-selection .datatable-body-row.active .datatable-row-group {
  background-color: $theme-grey-dark !important;
  color: $theme-white-base !important;
}

.ngx-datatable.material.single-selection .datatable-body-row.active,
.ngx-datatable.material.single-selection .datatable-body-row.active .datatable-row-group,
.ngx-datatable.material.multi-selection .datatable-body-row.active,
.ngx-datatable.material.multi-selection .datatable-body-row.active .datatable-row-group,
.ngx-datatable.material.multi-click-selection .datatable-body-row.active,
.ngx-datatable.material.multi-click-selection .datatable-body-row.active .datatable-row-group .datatable-body-cell {
  color: $theme-white-base !important;
}

ngx-datatable {

  .ngx-datatable.material.single-selection .datatable-body-row.active,
  .ngx-datatable.material.single-selection .datatable-body-row.active .datatable-row-group,
  .ngx-datatable.material.multi-selection .datatable-body-row.active,
  .ngx-datatable.material.multi-selection .datatable-body-row.active .datatable-row-group,
  .ngx-datatable.material.multi-click-selection .datatable-body-row.active,
  .ngx-datatable.material.multi-click-selection .datatable-body-row.active .datatable-row-group {
    background-color: $theme-color-primary !important;
    color: $theme-white-base !important;
  }

  .datatable-row-detail {
    padding-bottom: 30px;
    background-color: $theme-white-base;
  }

  .datatable-row-wrapper:not(:last-child) {
    border-bottom: $theme-border-secondary-width $theme-border-secondary-style $theme-border-secondary-color;
  }

  .datatable-header-cell-label {
    font-size: 14px;
  }
}
