/* Keep wide DataTables inside the application content column. */
.main-content,
.page-content,
.container-fluid,
.row > [class*="col-"],
.card,
.card-body {
    min-width: 0;
    max-width: 100%;
}

.main-content,
.page-content {
    overflow-x: hidden;
}

div.dataTables_wrapper {
    display: block;
    width: 100% !important;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
}

div.dataTables_wrapper > .row {
    min-width: 0;
    margin-left: 0;
    margin-right: 0;
}

div.dataTables_wrapper table.dataTable {
    width: 100% !important;
    max-width: none;
    margin: 0 !important;
    border-collapse: separate !important;
    border-spacing: 0;
}

table.dataTable > tbody > tr.child ul.dtr-details {
    width: 100%;
}

table.dataTable > tbody > tr.child ul.dtr-details > li {
    display: flex;
    flex-wrap: wrap;
    gap: .35rem;
    overflow-wrap: anywhere;
    white-space: normal;
}

table.dataTable > tbody > tr.child .dtr-title,
table.dataTable > tbody > tr.child .dtr-data {
    min-width: 0;
    overflow-wrap: anywhere;
}

@media (max-width: 767.98px) {
    div.dataTables_wrapper .dt-buttons,
    div.dataTables_wrapper .dataTables_length,
    div.dataTables_wrapper .dataTables_filter,
    div.dataTables_wrapper .dataTables_info,
    div.dataTables_wrapper .dataTables_paginate {
        float: none !important;
        width: 100%;
        margin-bottom: .75rem;
        text-align: left !important;
    }

    div.dataTables_wrapper .dataTables_filter label,
    div.dataTables_wrapper .dataTables_filter input {
        width: 100%;
        margin-left: 0 !important;
    }

    div.dataTables_wrapper .dt-buttons .btn {
        margin-bottom: .25rem;
    }
}
