h1 {
    font-weight: normal;
    margin-top: 24px;
}

h2 {
    padding: 0 0 0.5em;
    font-size: 1.4em;
    font-weight: normal;
    color: var(--mainBlue);
}

.tableHeader {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#filterContainer {
    max-height: 0;
    transition: .5s;
    overflow: hidden;
}

#filterForm {
    display: flex;
    flex-wrap: wrap;
    max-width: 100%;
}

#filterForm p {
    margin: unset;
}

#filterForm.participantListForm p {
    flex-basis: 50%;
    display: flex;
}

#filterContainer.participantAdministration p:nth-child(3),
#filterContainer.evaluation p:nth-child(4),
#filterContainer.evaluation p:nth-child(5),
#filterContainer.evaluation p:nth-child(6),
#filterContainer.evaluation p:last-child {
    flex-basis: 100%;
}


#filterContainer.participantAdministration .criteria-container p:nth-child(3) label,
#filterContainer.evaluation .criteria-container p:nth-child(4) label,
#filterContainer.evaluation .criteria-container p:nth-child(5) label,
#filterContainer.evaluation .criteria-container p:nth-child(6) label,
#filterContainer.evaluation .criteria-container p:last-child label {
    flex-basis: calc(25% - 4px);
}

#filterContainer.participantAdministration .criteria-container p:nth-child(3) select,
#filterContainer.evaluation .criteria-container p:nth-child(4) select,
#filterContainer.evaluation .criteria-container p:nth-child(5) select,
#filterContainer.evaluation .criteria-container p:nth-child(6) select,
#filterContainer.evaluation .criteria-container p:last-child input {
    flex-basis: calc(75% + 4px);
    max-width: calc(75% + 4px);
}
#filterContainer.participantAdministration .criteria-container p:nth-child(4) select
{
    max-width: 73.3%;
}
#filterContainer p #id_number_of_employees_0,
#filterContainer p #id_number_of_employees_1,
#filterContainer p #id_created_at_0,
#filterContainer p #id_created_at_1,
#filterContainer p #id_participation_period_0,
#filterContainer p #id_participation_period_1 {
    flex-basis: calc(25% - 7px);
    width: calc(25% - 7px);
}

#filterContainer p #id_number_of_employees_0,
#filterContainer p #id_created_at_0,
#filterContainer p #id_participation_period_0 {
    margin-right: 4px;
}

#filterContainer p #id_number_of_employees_1,
#filterContainer p #id_created_at_1,
#filterContainer p #id_participation_period_1 {
    margin-left: 4px;
}

#showFilters {
    width: 25px;
    height: 28px;
    cursor: pointer;
    background-repeat: no-repeat;
    background-position: 0 5px;
    background-image: url("../images/menu_fields_close.png");
}

#showFilters.open {
    background-image: url("../images/menu_fields_open.png");
}

.filterButtons button {
    width: 100px;
}

.listContainer {
    padding: 24px 8px;
}

.listContainer .table-container {
    overflow-x: scroll;
}

.listContainer table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

.listContainer th.asc a::after,
.listContainer th.desc a::after {
    content: '';
    position: absolute;
    right: -17px;
    width: 13px;
    height: 100%;
    background-image: url("../images/item_sort_order.png");
    background-repeat: no-repeat;
    background-position: center center;
}

.listContainer th.desc a::after {
    transform: rotate(180deg);
}

.listContainer thead tr {
    background-color: var(--backgroundGrey);
}

.listContainer tbody tr {
    background-color: var(--backgroundTable);
}

.listContainer tbody tr:hover {
    background-color: var(--backgroundSubTabs);
}

.listContainer th {
    border: 1px solid var(--mainBlue);
    background-color: var(--lightGrey) !important;
    padding: 6px;
}

.listContainer th:not(:last-child) {
    border-right: none;
}

.listContainer td {
    border: 1px solid var(--borderGrey);
    padding: unset;
}

.listContainer:not(#participantListTable) td {
    padding: 6px;
}

.listContainer tr:first-child td {
    border-top: none;
}

.listContainer tr:not(:last-child) td {
    border-bottom: none;
}

.listContainer td:not(:last-child) {
    border-right: none;
}

#userAdministrationTable tr > :nth-child(-n+2),
#messageTable tr > :nth-child(-n+4),
#participantAdministrationTable tr > :first-child,
#evaluationTable tr > :first-child {
    width: 20px;
    text-align: center;
}

.listContainer ul.pagination {
    list-style: none;
    padding: unset;
    display: flex;
    justify-content: center;
    margin: 24px 0 0;
}

.listContainer ul.pagination > li:not(:last-child) {
    border-right: 1px solid var(--mainBlack);
}

.listContainer ul.pagination > li > a {
    padding: 0 8px;
    color: grey;
}

.listContainer ul.pagination > .active > a {
    color: initial;
    text-decoration: underline;
}

.paginationContainer {
    display: flex;
    align-items: center;
}

.paginationContainer.evaluationPagination {
    justify-content: space-between;
}

#entries_per_page {
    margin-right: 16px;
}

/* Participant List Table */

#participantListTable th:nth-child(1) {
    width: 60%;
}

#participantListTable th:not(:nth-child(1)) {
    width: 20%;
}

#participantListTable td a {
    display: block;
    color: black;
    padding: 6px;
}

/* UserAdministration Table */

#filterContainer.userAdministration.open {
    max-height: 350px;
}

#userAdministrationTable th:nth-child(3),
#userAdministrationTable th:nth-child(4),
#userAdministrationTable th:nth-child(5) {
    width: 12%;
}

#userAdministrationTable th:nth-child(n+7) {
    width: 13%;
}

/* ParticipantMessage Table */

#messageTable th:nth-child(5),
#messageTable th:nth-child(7) {
    width: 11%;
}

/* ParticipantAdministration Table */

#filterContainer.participantAdministration.open {
    max-height: 400px;
}

#participantAdministrationTable th:nth-child(2),
#participantAdministrationTable th:nth-child(4) {
    width: 5%;
}

#participantAdministrationTable th:nth-child(5) {
    width: 20%;
}

#participantAdministrationTable th:nth-child(6),
#participantAdministrationTable th:nth-child(7) {
    width: 11%;
}

/* Evaluation Table */

#filterContainer.evaluation.open {
    max-height: 800px;
}

#evaluationTable .noEntries  {
    padding: 8px 0;
    background-color: var(--backgroundSubTabs);
    color: var(--mainRed);
    font-weight: bold;
    text-align: center;
}

#evaluationTable th:nth-child(2),
#evaluationTable th:nth-child(4) {
    width: 5%;
}

#evaluationTable th:nth-child(3),
#evaluationTable th:nth-child(5) {
    width: 20%;
}

#evaluationTable th:nth-child(6),
#evaluationTable th:nth-child(8),
#evaluationTable th:nth-child(9) {
    width: 11%;
}

#evaluationTable th:nth-child(7) {
    width: 15%;
}

@media only screen and (max-width: 980px) {
    #filterContainer.userAdministration.open {
        max-height: 350px;
    }

    #filterContainer.participantAdministration.open {
        max-height: 500px;
    }

    #filterContainer.evaluation.open {
        max-height: 1130px;
    }

    #filterContainer p #id_number_of_employees_0, #filterContainer p #id_created_at_0, #filterContainer p #id_participation_period_0 {
        margin-right: unset;
    }

    #filterContainer p #id_number_of_employees_1, #filterContainer p #id_created_at_1, #filterContainer p #id_participation_period_1 {
        margin-left: unset;
    }
}

#cmp_content img.small {
    max-width: 1em;
    max-height: 1em;
    width: auto;
    height: auto;
    vertical-align: middle;
}
