.wdk-table {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100%;
}

.wdk-table .search-wrapper {
    display: inline-flex;
}

.table-400 {
    max-height: 400px !important;
}

.table-max-modal {
    max-height: calc(70vh - 100px);
}

/* Table Offset */
.wdk-table.table-offset {
    min-height: calc(-300px + 100vh);
}

.wdk-table.auto {
    height: auto;
}

/* .table-offset-175 {
    height: calc(100vh - 175px) !important;
}

.table-offset-200 {
    height: calc(100vh - 200px) !important;
}

.table-offset-232 {
    height: calc(100vh - 232px) !important;
}

.table-offset-256 {
    height: calc(100vh - 256px) !important;
} */

.table-max-offset-215 {
    max-height: calc(100vh - 215px) !important;
}

.table-max-offset-300 {
    max-height: calc(100vh - 300px) !important;
}

.table-max-offset-370 {
    max-height: calc(100vh - 370px) !important;
}

.wdk-table.table-offset .table-container table thead,
/* .wdk-table.table-offset-175 .table-container table thead,
.wdk-table.table-offset-200 .table-container table thead,
.wdk-table.table-offset-232 .table-container table thead,
.wdk-table.table-offset-256 .table-container table thead, */
.wdk-table.table-max-offset-215 .table-container table thead,
.wdk-table.table-max-offset-300 .table-container table thead,
.wdk-table.table-max-offset-370 .table-container table thead {
    position: sticky;
    top: -10px;
    z-index: 1;
    background-color: var(--background);
}

.wdk-table.table-400 .table-container table thead {
    position: sticky;
    top: -10px;
    z-index: 1;
    background-color: var(--white-01);
}

/* Fix on table-offset into Layout mini */
.wdk-layout-mini #divMain > .table-offset {
    height: calc(100vh - 126px) !important;
}

/* Table Offset - END */

.wdk-table.fullscreen {
    position: fixed;
    height: 100vh !important;
    max-height: initial !important;
    top: 0px;
    left: 0px;
    z-index: 99999999;
    background-color: var(--background);
    padding: 16px;
}

/* Filter */
.wdk-table-filter {
    display: inline-block;
}

.wdk-table.fullscreen .wdk-table-filter,
.wdk-table.fullscreen .wdk-table-filter a {
    opacity: 0;
    cursor: unset;
    width: 0;
    height: 0;
}

/* End filter */

.table-container {
    position: relative;
    width: 100%;
    overflow: auto visible;
    border-top: 1px solid var(--grey-02);
    padding-top: 8px;
    margin-top: 1.5rem;
    margin-right: -16px;
    flex: 1;
    transition: .3s;
    transition-delay: .3s;
}

    .table-container.clean {
        border-top: none !important;
        margin-top: 0 !important;
    }


#sidebar-trigger:checked ~ .wdk-layout .wdk-table .table-container {
    width: 100%;
    transition: .3s;
    transition-delay: .3s;
}

#sidebar-trigger:checked ~ .wdk-layout .wdk-table .table-container.container-wrapped {
    width: calc( 100vw - 58px - 48px - 36px ) !important;
}

.table-container {
	scrollbar-width: thin !important;
}

.table-container::-webkit-scrollbar-track {
	background-color: var(--white-02)  !important;
	-webkit-box-shadow: inset 0 0 6px var(--white-02)  !important;
    box-shadow: inset 0 0 6px var(--white-02)  !important;
}

.table-container::-webkit-scrollbar {
	background-color: var(--white-02) !important;
	width: 5px !important;
	height: 8px;
}

.table-container::-webkit-scrollbar-thumb {
	background-color: var(--scroll-thumb-light-custom-color) !important;
	border-radius: 10px;
}

@media(max-width: 992px) {
    #sidebar-trigger:checked ~ .wdk-layout .wdk-table .table-container
    /* Commented to fix a layout breaking in the second step on incident setting */
    /* #sidebar-trigger ~ .wdk-layout .wdk-table .table-container */
    {
        width: calc( 100vw - 32px) !important;
    }
}

.table {
    color: var(--table-body-text-color);
}

.table thead {
    height: 56px;
}

.table.header-white thead{
    background-color: #fff !important;
}

.table th,
.table td {
    position: relative;
    width: initial;
    padding: var(--table-padding) !important;
    border: none;
    font-size: var(--table-body-font-size);
    line-height: 1.25;
    font-family: 'Inter', sans-serif !important;
    vertical-align: middle;
    font-weight: 400;
}

.table td.ps-4 {
    padding-left: 32px !important;
}

.table th {
    font-size: var(--table-head-font-size);
    white-space: nowrap;
}

.table th.has-hidden-actions { width: 50px !important; }

.table thead th,
.tbl-default thead th {
    font-weight: 600;
    font-family: 'Inter', sans-serif !important;
    vertical-align: middle;
    color: var(--table-head-text-color);
    border-bottom: none;
}

.table tbody tr:nth-child(odd) td { background-color: var(--table-line-odd-background-color); }
.table tbody tr td:first-of-type { border-radius: var(--radius-mini) 0px 0px var(--radius-mini); }
.table tbody tr td:last-of-type { border-radius: 0px var(--radius-mini) var(--radius-mini) 0px; }

.table-detail.custom-pagination {
    margin-top: 6px;
    padding: 0 12px;
}

.table-detail.custom-pagination .btn-toolbar {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    gap: 10px !important;
}

.table-detail.custom-pagination .btn-toolbar select {
    margin-right: 8px;
    overflow: hidden;
}

.table-detail.custom-pagination .btn {
    display: inline-block;
    background-color: transparent !important;
    border: none;
    box-shadow: none;
    color: var(--primary) !important;
    font-size: var(--font-size) !important;
    font-weight: 600;
    padding: 6px 3px;
    height: 24px;
    min-width: 24px;
    text-align: center;
    line-height: 14px;
}

.table-detail.custom-pagination .btn.dropdown-toggle {
    border: 1px solid var(--primary);
}

.table-detail.custom-pagination .dropdown {
    margin-right: 6px;
}

.table-detail.custom-pagination .dropdown .dropdown-menu {
    min-width: 60px !important;
}

.table-detail.custom-pagination .btn.active {
    background-color: var(--primary) !important;
    color: var(--secondary) !important;
}

.table-detail.custom-pagination .btn:hover {
    background-color: var(--primary-dark) !important;
    color: var(--secondary) !important;
}

.table thead th.center,
.table tbody td.center,
.table tfoot td.center {
    text-align: -webkit-center !important;
}

.table thead th.right,
.table tbody td.right,
.table tfoot td.right {
    text-align: -webkit-right !important;
}

.table thead th.mnw120,
.table tbody td.mnw120 {
    min-width: 120px;
}

.table thead th.mnw140,
.table tbody td.mnw140 {
    min-width: 140px;
}

.table thead th.mnw200,
.table tbody td.mnw200 {
    min-width: 200px;
}

.table thead th.mnw280,
.table tbody td.mnw280 {
    min-width: 280px;
}

.table thead th.mnw320,
.table tbody td.mnw320 {
    min-width: 320px;
}

.table thead th.cw130,
.table tbody td.cw130 {
    width: 130px;
    min-width: 130px;
    max-width: 130px;
}

.table thead th i {
    margin-left: 6px;
    font-size: 16px;
    color: var(--table-head-sort-icon-color);
}

.table thead th i:hover {
    color: var(--table-head-sort-icon-color-hover);
    transition: .4s;
}

th.nosort i {
    display: none;
}

/* Custom expand columns */
.icon-column-expand.plus:before {
    content: "\e952";
    font-family: 'icomoon' !important;
}

.icon-column-expand.minus:before {
    content: "\eea5";
    font-family: 'icomoon' !important;
}

.table th.column-expand > a[data-show-hide].icon-column-expand {
    display: flex;
    position: relative;
    right: -8px;
    color: var(--table-head-expand-icon-color);
    font-size: var(--table-head-button-size);
    text-decoration: none;
}

.table th.column-expand > a[data-show-hide].icon-column-expand:after {
    content: "";
    position: relative;
    height: 20px;
    width: 1px;
    right: -8px;
    box-shadow: 1px 0px 2px 0px var(--table-head-expand-icon-color);
    background-color: var(--table-head-expand-icon-color);
}

.table th.column-expand > a[data-show-hide].icon-column-expand:hover {
    color: var(--table-head-expand-icon-color-hover) !important;
    transition: 0.3s;
}

th.column-expand {
    position: relative;
    cursor: pointer;
}

th.column-expand ~ th[class*="sh-"]{
    background-color: var(--table-line-odd-background-color);
}

th.column-expand + th[class*="sh-"] {
    border-top-right-radius: 6px !important;
}

th[class*="sh-"] + th[class*="sh-"] {
    border-top-right-radius: 6px !important;
}

th[class*="sh-"] {
    position: relative;
}

th[class*="sh-"] + th[class*="sh-"]:after {
    content: "";
    position: absolute;
    top: 0;
    left: -10px;
    height: 10px;
    width: 10px;
    background-color: var(--table-line-odd-background-color);
}

.table tbody tr:nth-child(-n+4) .wdk-actions-container {
    bottom: initial;
    top: 0;
}

.table tbody tr td:last-child .btn.btn-icon-tooltip .btn-tooltip {
    left: initial;
    transform: translateX(0);
    right: 0;
}

/* Table Draggable */
.table.table-draggable tbody tr td:first-of-type {
    padding-left: 48px !important;
    cursor: -webkit-grab;
}

    .table.table-draggable tbody tr td:first-of-type::before {
        content: "\eb41";
        width: 20px;
        height: 20px;
        margin-right: 12px;
        margin-left: 8px;
        font-size: 20px;
        cursor: -webkit-grab;
        font-family: 'icomoon' !important;
        position: absolute;
        left: 20px;
        top: 50%;
        transform: translate(-50%, -69%);
    }

.table.table-draggable tbody tr:hover td {
    background-color: var(--grey-02) ;
    transition: .3s;
    transition-delay: .1s;
}

.table.table-draggable thead tr th:first-child {
    padding-left: 40px !important;
}

.table.table-draggable tr.ui-sortable-helper td,
.table.table-draggable tr.ui-sortable-helper td .wdk-text,
.table.table-draggable tr.ui-sortable-helper td .btn-inline,
.table.table-draggable tr.ui-sortable-helper td a  {
    background-color: var(--primary) !important;
    color: var(--white-01) !important;
}

/* Table Checkbox */
.table.table-checkbox .form-check-input {
    position: relative;
    margin-left: 0;
}

.table.table-checkbox thead th:first-child {
    width: 40px !important;
}

.table.table-checkbox thead th:first-child i {
    display: none;
}

/* Table expand vertical */
.table.table-expand-vertical {
    border-collapse: initial !important;
    border-spacing: 0px 8px;
    scrollbar-width: thin !important;
}

.table.table-expand-vertical::-webkit-scrollbar-track {
	background-color: var(--white-02) !important;
	-webkit-box-shadow: inset 0 0 6px var(--white-02) !important;
    box-shadow: inset 0 0 6px var(--white-02) !important;
}
.table.table-expand-vertical::-webkit-scrollbar {
	background-color: var(--white-02) !important;
	width: 5px !important;
	height: 8px;
}
.table.table-expand-vertical::-webkit-scrollbar-thumb {
	background-color: var(--scroll-thumb-light-custom-color) !important;
	border-radius: 10px;
}

.table.table-expand-vertical thead tr th {
    font-size: 12px;
}

.table.table-expand-vertical tbody tr td {
    padding: 6px !important;
    font-size: 12px;
}

.table.table-expand-vertical.fs-14 thead tr th {
    font-size: var(--font-size);
}

.table.table-expand-vertical.fs-14 tbody tr td {
    padding: 8px !important;
    font-size: var(--font-size);
}

.table.table-expand-vertical tbody tr td a {
    color: var(--tertiary);
}

.table.table-expand-vertical tbody tr td a:hover {
    color: var(--tertiary-dark);
}

.table.table-expand-vertical tr[data-father="True"] a[data-father-toggle] {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: var(--primary);
    line-height: 1;
    padding: 0;
    height: initial;
    border: none;
    background-color: transparent;
    box-shadow: none;
    left: initial !important;
    margin-right: 6px !important;
}

.table.table-expand-vertical tbody tr[data-child="False"] td {
    background-color: var(--grey-01);
}

.table.table-expand-vertical tbody tr[data-child="True"] td {
    background-color: rgb(245, 245, 245);
}

.table.table-expand-vertical tr[data-father="True"] a[data-father-toggle]:hover {
    color: var(--tertiary);
    transition: 0.3s;
    text-decoration: none;
}

.table.table-expand-vertical tr[data-father="True"] a[data-father-toggle]:focus,
.table.table-expand-vertical tr[data-father="True"] a[data-father-toggle]:active,
.table.table-expand-vertical tr[data-father="True"] a[data-father-toggle]:focus-visible,
.table.table-expand-vertical tr[data-father="True"] a[data-father-toggle]:not(:disabled):not(.disabled):active {
    box-shadow: none;
    border: none !important;
    color: var(--tertiary) ;
    text-decoration: none;
}

.table.table-expand-vertical tbody tr[data-father="False"][data-child="False"] td:first-child {
    padding-left: 12px !important;
}

.table.table-expand-vertical tbody tr[data-father="False"][data-child="False"] td:first-child:before {
    content: "";
    vertical-align: inherit;
    display: inline-block;
    height: 14px;
    width: 14px;
    margin-right: 8px;
    border-radius: 100%;
    color: var(--grey-300);
    background-color: var(--grey-02);
}

.table.table-expand-vertical tbody tr[data-father="False"][data-child="True"] td:first-child {
    padding-left: 68px !important;
}

.table.table-expand-vertical tbody {
    max-height: initial !important;
    overflow: hidden !important;
}

.table.table-expand-vertical tr td:first-child,
.table.table-expand-vertical tr th:first-child {
    min-width: 210px !important;
}

.table.table-expand-vertical thead tr th:nth-child(1),
.table.table-expand-vertical thead tr th:nth-child(2) {
    background-color: var(--background);
}

.table.table-expand-vertical thead {
    display: table-header-group !important;
}

.table.table-expand-vertical tbody {
    display: table-row-group !important;
}
/* END - Table expand vertical */

.table-container.container-wrapped {
    width: calc( 100vw - var(--sidebar-expanded-width) - 84px);
}

#modalform .modal-content .modal-body .table-container.container-modal {
    width: 100% !important;
    overflow: auto;
}

/* Unify with the class above covering all situations  */
.table-container.container-overflow {
    width: 100% !important;
    overflow: auto;
}

.table-container.container-half {
    width: 100%;
    overflow: auto;
    height: calc(100vh - 336px) !important;
    min-height: 300px;
}

.table-container.container-half.offset-360 {
    height: calc(100vh - 360px) !important;
}

@media (max-width: 576px) {
    .table-container.container-half,
    .table-container.container-half.offset-360 {
        min-width: 100%;
        height: 300px !important;
        min-height: 300px;
    }
}

.container-actions {
    overflow: hidden auto;
    height: calc(100vh - 336px) !important;
    scrollbar-width: thin !important;
}

.container-actions::-webkit-scrollbar-track {
	background-color: var(--white-02)  !important;
	-webkit-box-shadow: inset 0 0 6px var(--white-02)  !important;
    box-shadow: inset 0 0 6px var(--white-02)  !important;
}

.container-actions::-webkit-scrollbar {
	background-color: var(--white-02) !important;
	width: 5px !important;
	height: 8px;
}

.container-actions::-webkit-scrollbar-thumb {
	background-color: var(--scroll-thumb-light-custom-color) !important;
	border-radius: 5px;
}

@media (max-width: 576px) {
    .container-actions {
        min-width: 100%;
        height: 229px !important;
    }
    .container-actions .btn-group-vertical {
        flex-direction: row;
        width: 100%;
        max-width: 100%;
        height: auto;
        flex-wrap: wrap;
    }
    .container-actions .btn-group-vertical button {
        width: initial;
        border-radius: 0;
        border: 1px solid var(--grey-01);
        box-shadow: none;
    }
    .container-actions .btn-group-vertical button:first-child {
        width: 100%;
    }

    .container-actions .btn-group-vertical #btnMoveAll,
    .container-actions .btn-group-vertical #btnMove,
    .container-actions .btn-group-vertical #btnRemoveAll,
    .container-actions .btn-group-vertical #btnRemove {
        width: 50%;
    }
    .container-actions .btn-group-vertical #btnMoveAll i,
    .container-actions .btn-group-vertical #btnMove i {
        transform: rotate(90deg);
    }
    .container-actions .btn-group-vertical #btnRemoveAll i,
    .container-actions .btn-group-vertical #btnRemove i {
        transform: rotate(90deg);
    }
}

/* Table in documents */
.table.table-associate {
    border-collapse: initial !important;
    border-spacing: 0px 8px;
    padding: 0 8px;
}

.table.table-associate {
    border-collapse: initial !important;
    border-spacing: 0px 8px;
    padding: 0 8px;
}

.table.table-associate thead {
    height: 40px;
}

.table.table-associate tbody tr td {
    background-color: var(--grey-01) !important;
}

.table-associate-wrap {
    height: 100%;
    overflow: hidden auto;
	scrollbar-width: thin !important;
}

.table-associate-wrap::-webkit-scrollbar-track {
	background-color: var(--white-02) !important;
	-webkit-box-shadow: inset 0 0 6px var(--white-02) !important;
    box-shadow: inset 0 0 6px var(--white-02) !important;
}

.table-associate-wrap::-webkit-scrollbar {
	background-color: var(--white-02) !important;
	width: 5px !important;
	height: 5px;
}

.table-associate-wrap::-webkit-scrollbar-thumb {
	background-color: var(--scroll-thumb-base-custom-color) !important;
	border-radius: 10px;
}

/* Mobile */
@media (max-width: 992px) {
    .accordion .accordion-body .wdk-table,
    .modal .modal-content .wdk-table {
        width: 100%;
        max-width: 100%;
        overflow: auto;
        height: initial;
    }
}

/* Fix modal journey precession */
.table .form-control.disabled,
.table  .form-control:disabled,
.table .form-control[readonly] {
    background-color: transparent;
}

/* Table background clean */
.table.table-clean.headline thead {
    border-bottom: 2px solid var(--primary-light);
    height: 0px !important;
}

.table.table-clean tbody tr td {
    border-top: 1px solid var(--grey-02);
}

.table.table-clean tbody tr:nth-child(odd) td {
    background-color: transparent;
}

/* tr disabled */
tr.disabled {
    color: rgba(0,0,0,0.5);
}
