/*
* Based on https://cdn.datatables.net/1.10.20/css/jquery.dataTables.min.css
*/
/*
 * Table
 */
.ecl-editor table.dataTable {
  border-width: 1px;
}
table.dataTable tr:not(last-of-type) {
  border-width: 0 0 1px 0;
}
table.dataTable td:not(last-of-type),
table.dataTable th:not(last-of-type) {
  border-width: 0 1px 0 0;
}

table.dataTable thead,
table.dataTable tfoot {
  background-color: rgb(227, 227, 227);
}

table.dataTable thead,
table.dataTable.no-footer {
  border-bottom: rgb(212,212,212) 1px solid;
}

table.dataTable tbody th,
table.dataTable tbody td {
  padding: 1.5rem 10px;
}

/*
 * Sorting
 */
table.dataTable thead .sorting_asc,
table.dataTable thead .sorting_desc {
  background-image: none;
}
.sorting:after,
.sorting_asc:after,
.sorting_desc:after,
.paginate_enabled_previous:before,
.paginate_enabled_next:after {
  display: inline-block;
  font-family: EuropaIcons;
  -moz-osx-font-smoothing: grayscale;
  -webkit-font-smoothing: antialiased;
  font-style: normal;
  font-variant: normal;
  font-weight: 400;
  line-height: 1;
  margin-left: 4px;
  speak: none;
  text-decoration: none;
  text-transform: none;
  position: relative;
}

.sorting_asc:after,
.sorting_desc:after {
  content: "\e81f";
}

.sorting_desc:after {
  -webkit-transform: rotate(180deg);
  -ms-transform: rotate(180deg);
  transform: rotate(180deg);
}
/* header */
.dataTables_length,
.dataTables_filter {
  padding-bottom: 0.5em;
}

/* fix header */
table[aria-hidden=true] {
  display: table;
}

table.no-footer.fixedHeader-floating {
  border-width: 1px 0 2px  1px;
  border-bottom-color: rgb(212,212,212);
}

@media (max-width: 768px) {

  body.node-type-ema-general .ecl-editor table.dataTable {
    table-layout: fixed;
    width: 100%;
  }

  .ecl-editor table.dataTable thead,
  .ecl-editor table.dataTable thead tr,
  .ecl-editor table.dataTable tfoot tr,
  .ecl-editor table.dataTable thead tr th,
  .ecl-editor table.dataTable tfoot tr td,
  table.dataTable.fixedHeader-floating thead,
  table.dataTable.fixedHeader-floating thead tr,
  table.dataTable.fixedHeader-floating thead tr th {
    display: block;
    border: none;
  }
  .ecl-editor table.dataTable thead tr th,
  table.dataTable.fixedHeader-floating thead tr th {
    width: auto !important;
  }

  .ecl-editor table.dataTable td {
    border: none;
  }

  table.no-footer.fixedHeader-floating {
    border-width: 1px 1px 2px  1px;
  }

  table.dataTable.fixedHeader-floating thead tr th {
    text-align: left;
  }

  .ecl-editor table.dataTable thead tr:last-of-type {
    border-bottom: rgb(212,212,212) 1px solid;
  }

}

/* EMA-2017: Searchable and sortable tables - mobile view fix. */
@media screen and (max-width: 640px) {
  .dataTables_wrapper .dataTables_length,
  .dataTables_wrapper .dataTables_filter {
    text-align: left;
  }
}
