:root {
    --table-scrollbar-width: 17px;
    --window-scrollbar-width: 17px;
    --sdad-table-thead-bg-color: #f1f1f1;
}


.sdad-table-panel {
    border-style: solid;
    border-width: 1px 0 0 0;
    background-color: white;
    border-color: var(--input-border-color);
}

/*Both Above&Bellow Table Container*/
.sdad-table-panel > div.sdad-table-top-toolbar {
    display: flex;
    align-items: center;
    padding: 1ex;
    text-align: left;
    font-weight: normal;
    box-sizing: border-box;
    border-style: solid;
    border-color: inherit;

}

/*Above Table Container*/
.sdad-table-panel > div.sdad-table-top-toolbar:first-child {
    justify-content: space-between;
    border-width: 0 1px 1px 1px;
    border-color: inherit;

}

/*Bellow Table Container*/
.sdad-table-panel > div.sdad-table-top-toolbar:last-child {
    justify-content: end;
    border-width: 0 1px 1px 1px;
    border-color: inherit;

}

.sdad-table-panel > div.sdad-table-top-toolbar > div {
    display: flex;
}

.sdad-top-action {
    margin-left: 4px;
}

.sdad-top-action .sdad-icon-button {
    font-size: 16px;
    width: 28px;
    height: 28px;
    background-color: var(--gov-green-button);
    color: white;
    border-color: var(--gov-green-button) !important;
}

.sdad-top-action .sdad-icon-button:hover {
    background-color: var(--gov-green-button-hover);
    color: white !important;
}

.sdad-table-panel > div.sdad-table-top-toolbar .sdad-table-toggle {
    font-weight: 700;
    text-decoration: none;
    font-size: 14px;
}

/*
.sdad-top-action .sdad-icon-button {
    width: 24px;
    height: 24px;

}

 */

.sdad-sorting-column {
    cursor: pointer;
    vertical-align: middle;
    text-align: left;
    border: none;
    background-color: inherit;
    font-weight: 700;
    color: var(--text-color);
    width: 100%;
    padding: 0;
}

.sdad-sorting-column:hover {
    background-color: var(--gov-green-button);
    color: white;
}

.sol01-datatable table {
    box-sizing: border-box;
    border-collapse: separate;
    border-spacing: 0;
    border-width: 0 1px 1px 1px;
    border-style: solid;
    border-color: var(--input-border-color);
    width: 100%;
    font-weight: 400;
}

.sol01-datatable table > thead, .sol01-datatable table > tbody {
    border-width: 0 1px 1px 1px;
    border-style: solid;
    border-color: var(--input-border-color);
}

.sol01-datatable table th {
    position: sticky;
    top: calc(var(--navbar-height) + var(--navbar-border-bottom));
    background-color: var(--sdad-table-thead-bg-color);
    border-width: 0;
    border-bottom-width: 1px;
    border-left-width: 1px;
    border-style: solid;
    border-color: var(--input-border-color);
    text-align: left;
    vertical-align: top;
    padding: 4px 8px;
}

.sol01-datatable table th:first-child {
    border-left-width: 0;
}

.sol01-datatable tbody td {
    border-width: 0;
    border-bottom-width: 1px;
    border-left-width: 1px;
    border-style: solid;
    border-color: var(--input-border-color);
    vertical-align: top;
    padding: 4px 8px;
}

.sol01-datatable tbody td:first-child {
    border-left: 0;
    border-left-style: none;
}

.sol01-datatable tfoot {
    border-width: 0 1px 1px 1px;
    border-style: solid;
    border-color: var(--input-border-color);
}


.sol01-navigator {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    padding: 8px 12px 8px 0;

}

.sol01-page-item a {
    border-radius: var(--input-border-radius);
}

.sol01-navigator-label {
    display: flex;
    align-items: center;
    padding: 8px 4px;
}

.sol01-navigation-padding {
    margin-right: 4px;
}

.norecords-td {
    padding: 8px 4px;
}

.navigation td {
    padding-left: 8px;
}

.sdad-data-table tr {
    border-bottom: 1px solid var(--input-border-color);
}

.sdad-data-table tr:nth-child(even) {
    background-color: #fafafa;
}


.sdad-table-top-toolbar {
    background-color: #f1f1f1;
}

.sdad-data-table thead {
    background-color: var(--sdad-table-thead-bg-color);
}

/* tree */

.tree-content {
    display: block;
    padding: 4px;
}

td.tree {
    padding: 0 !important;
}

.tree-junction, .tree-junction-expanded, .tree-junction-collapsed {
    background-position-y: -985px !important;
    height: 24px !important;
    background-size: auto;
}

.w3-modal-content .sol01-datatable table th {
    /* `sticky` in modals does not behave well, so we override it */
    position: static;
}

/* sdad-table-2 is a simpler table without header-footer */
.sdad-table-2 {
    border-collapse: separate;
    border-width: 0 0 1px 1px;
    border-style: solid;
    border-color: var(--input-border-color);
    border-spacing: 0;
}

.sdad-table-2 thead {
    background-color: var(--sdad-table-thead-bg-color);
    font-weight: 700;
}

.sdad-table-2 tbody, .sdad-table-2 tfoot {
    font-weight: normal;
}

.sdad-table-2 td, .sdad-table-2 th {
    border-width: 1px 1px 0 0;
    border-style: solid;
    border-color: var(--input-border-color);
    vertical-align: top;
    padding: 4px 8px;
}

/* Tables with striped rows */
.sdad-table-striped tbody tr:nth-child(even) {
    background-color: #fafafa;
}

/* Tables without column borders */
table.sdad-table-horizontal {
    border-collapse: separate;
    border-width: 1px 1px 0 1px;
    border-style: solid;
    border-color: var(--input-border-color);
    border-spacing: 0;
}

.sdad-table-horizontal td, .sdad-table-horizontal th {
    border-width: 0 0 1px 0;
    border-style: solid;
    border-color: var(--input-border-color);
}


.sol01-datatable table th.sdad-column-centered {
    text-align: center;
}

.sol01-datatable table td.sdad-column-centered {
    text-align: center;
}

.sol01-datatable table th.sdad-column-centered .sdad-sorting-column {
    text-align: center;
}


.sol01-datatable table th.sdad-column-right {
    text-align: right;
}

.sol01-datatable table td.sdad-column-right {
    text-align: right;
}

.sol01-datatable table th.sdad-column-right .sdad-sorting-column {
    text-align: right;
}

/* Utility class that forces a column to become as small as possible. Not sure if white-space: nowrap is need... */
.sdad-column-narrow {
    width: 1%;
    white-space: nowrap;
}

/*
css for tree branches to have height 100% so that we have no gaps in lines
see https://stackoverflow.com/questions/3215553/make-a-div-fill-an-entire-table-cell
 */
.sdad-table-tree {
    height: 1px;
}

.sdad-table-tree td.tree {
    height: 100%;
}

.sdad-table-tree td.tree div {
    height: 100%;
}


/* Styles for when using SdadColumnDecorator and wanting a flex layout */
.sdad-column-decorator-wrapper-flex {
    display: flex;
}

.sdad-column-decorator-wrapper-flex .sdad-column-decorator-content {
    flex: 1;
}

