:root {
    --z-index-overlay: 10000;
    --z-index-menu: 99999;
    --brand-color-gray: #8d8d8d;
    --brand-color-yellow: #ae6d00;
    --brand-color-green: #479f76;
    --brand-color-red: #e35d6a;
}

html {
    position: relative;
    min-height: 100%;
    margin: 0;
    padding: 0;
    font-size: 14px;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

body {
    margin: 0;
    padding: 0;
}

/* brand colors */

.brand-color-gray {
    color: var(--brand-color-gray);
}

.brand-color-yellow {
    color: var(--brand-color-yellow);
}

.brand-color-green {
    color: var(--brand-color-green);
}

.brand-color-red {
    color: var(--brand-color-red);
}

/* end brand colors */

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

.main-content {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    overflow-x: hidden;
}

footer {
    position: relative;
    padding-top: 1rem;
    padding-bottom: 1rem;
}

.pagination {
    margin-bottom: 0;
}

.input-group-custom {
    position: relative;
}

    .input-group-custom .input-group-icon {
        position: absolute;
        top: 50%;
        left: 10px;
        transform: translateY(-50%);
    }

        .input-group-custom .input-group-icon svg {
            width: 1em;
            height: 1em;
            vertical-align: unset;
        }

    .input-group-custom .form-control, .input-group-custom .form-select {
        padding-left: 2.1rem;
    }

.progress-custom {
    font-size: 1rem;
    height: 2.3rem;
}

    .progress-custom .progress-bar {
        overflow: visible;
        color: black;
    }

    .progress-custom .progress-value {
        padding: 0 0.75rem;
    }

    .progress-custom .bg-green {
        background-color: #4cad80;
    }

    .progress-custom .bg-yellow {
        background-color: #febd5e;
    }

#toast-container {
    position: absolute;
}

    #toast-container.toast-bottom-right {
        right: 0.75rem;
        bottom: 0.75rem;
    }

    #toast-container.toast-bottom-footer-right {
        right: 0.75rem;
        bottom: 3.75rem;
    }

    #toast-container > div {
        padding: 15px 15px 16px 50px;
        opacity: 1;
        border-radius: 0.5rem;
        box-shadow: 0 5px 5px rgba(0, 0, 0, 0.15);
    }

        #toast-container > div:hover {
            box-shadow: 0 5px 5px rgba(0, 0, 0, 0.3);
        }

    #toast-container > .toast {
        background-image: none !important;
    }

    #toast-container .toast-title {
        font-size: 1.2rem;
    }

    #toast-container .toast-message {
        font-size: 1rem;
    }

    #toast-container > .toast:before {
        position: fixed;
        font-family: 'Bootstrap-icons';
        font-size: 22px;
        float: left;
        color: #FFF;
        margin: -0.2rem 0 0 -2rem;
    }

    #toast-container > .toast-success {
        background-color: #4cad80;
        background: linear-gradient(90deg, #0aaf79, #0fb780) !important;
        border: none;
    }

        #toast-container > .toast-success:before {
            content: "\F26A";
        }

    #toast-container > .toast-error {
        background-color: #4cad80;
        background: linear-gradient(90deg, #ef4447, #ee4668) !important;
        border: none;
    }

        #toast-container > .toast-error:before {
            content: "\F622";
        }

.dt-container > .row {
    margin: 0 !important;    
}

    .dt-container > .row > * {
        padding-left: 0;
        padding-right: 0;
    }

.tab-header > .tab-pane,
.tab-footer > .tab-pane {
    display: none;
}

.tab-header > .active,
.tab-footer > .active {
    display: block;
}

footer .dt-search {
    margin-right: auto;
}

    footer .dt-search label {
        display: flex;
    }

    footer .dt-search input {
        margin-left: 1rem;
    }

.dt-length,
.dt-search {
    display: none;
}

.manage-column {
    min-width: 5.5rem;
}

.bound-entities {
    display: flex;
}

@media (max-width: 768px) {
    .bound-entities {
        display: block;
    }
}

.bound-entity-card {
    border: 1px solid #e9e9e9;
    padding: 1rem 1rem;
    border-radius: 15px;
    margin: 0.5rem 1rem 0 0;
    min-width: 25rem;
    max-width: 30rem;
    min-height: calc(100px + 2rem);
}

    .bound-entity-card:hover {
        box-shadow: 9px 0 10px -3px rgba(0, 0, 0, 0.08);
    }

    .bound-entity-card .card-title {
        font-weight: 600;
        margin-bottom: 1rem;
        text-transform: uppercase;
    }

.link-primary {
    cursor: pointer;
}

.pointer-row-table td:not(.dataTables_empty) {
    cursor: pointer;
}

#editFormDiv img.qr {
    width: max-content;
    max-width: 100%;
    align-self: center;
    border-radius: var(--bs-border-radius);
}

.bound-entity-card img.qr {
    float: right;
    width: 100px;
    border-radius: var(--bs-border-radius);
}

.img-aligned-right-side img.qr {
    position: absolute;
    right: 4px;
    height: 100%;
    max-height: 130px;
    top: 50%;
    transform: translateY(-50%);
    border-radius: var(--bs-border-radius);
}

.card-body:has(.img-aligned-right-side) {
    width: 70%;
}

.w-fixed-200 {
    width: 12rem !important;
}

.breadcrumb-item {
    white-space: nowrap;
}

.button-panel > * {
    margin-left: 0.25rem;
}

.title {
    min-height: 3rem; /* To avoid shaking when switching from page without buttons to page with buttons */
}

.ui-timepicker .ui-menu-item a {
    font-size: 0.9rem;
    padding-left: 0;
}

.online-status-label {
    color: var(--brand-color-green);
}

.offline-status-label {
    color: var(--brand-color-red);
}

.modal .modal-body {
    max-height: 70vh;
}

.title-sm {
    display: none;
}

@media only screen and (max-width: 481px) {

    .nav-item i.nav-chevron {
        display: block !important;
        position: absolute;
        right: 0;
        font-size: 16px;
    }

        .nav-item i.nav-chevron:before {
            font-weight: 600 !important;
        }

    nav.d-flex {
        overflow: hidden;
        z-index: 999 !important;
        height: 65px !important;
        width: 100% !important;
    }

        nav.d-flex.expanded {
            overflow: hidden;
            z-index: var(--z-index-menu) !important;
            height: 100% !important;
            width: 100% !important;
        }

    nav + div {
        padding-top: 65px;
    }

    .dt-container .justify-content-between:first-child {
        display: none;
    }

    form.search {
        margin-left: 0 !important;
    }

    nav .nav-item {
        font-size: 16px;
    }

    .nav-item i {
        margin-right: 1.4rem !important;
    }

    .nav-logo {
        margin: 0.5rem !important;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

        .nav-logo img {
            width: 100px;
        }

        .nav-logo i.bi-list {
            font-size: 25px;
            color: white;
        }

    .breadcrumb-item:not(.active) {
        display: none;
    }

    .breadcrumb-item.active {
        padding: 0;
        color: var(--bs-body-color);
    }

        .breadcrumb-item.active:before {
            content: none;
        }

    .dtr-data > div {
        display: inline-block !important;
    }

    .expand-collapse-button i:before {
        font-weight: 800 !important;
    }

    .expand-collapse-button {
        text-align: center;
    }

    .main-content .title {
        margin-bottom: 0.4rem !important;
    }

    .show-more-params {
        display: flex !important;
    }

        .show-more-params input.form-control {
            width: 100% !important;
        }

        .show-more-params button#query {
            width: 150% !important;
        }

    #commandHistoryTabContent #cancelLastCommand {
        margin: 0 !important;
        width: 100% !important;
    }

    #currentStateTabContent .w-fixed-200 {
        width: unset !important;
    }

    .nav-tabs .nav-link.active {
        isolation: isolate;
    }

    #currentStateTabContent .table thead {
        display: none;
    }

    #currentStateTabContent .table tr {
        border-bottom: 1px solid #dfdfdf;
    }

    #currentStateTabContent .table td {
        display: flex;
        flex-direction: column;
        border: none;
    }

    #currentStateTabContent .table tr .title-sm {
        display: block;
        font-weight: bold;
        margin-bottom: 10px;
        margin-right: 10px;
    }

        #currentStateTabContent .table tr .title-sm:only-child:after {
            content: '-';
            margin-left: 10px;
        }

    #currentStateTabContent .bound-entity-card {
        width: 100%;
        min-width: unset;
    }

        #currentStateTabContent .bound-entity-card img.qr {
            float: left;
            border-radius: var(--bs-border-radius);
            margin-right: 1rem;
        }

        #currentStateTabContent td.controls button, #currentStateTabContent td.controls select {
            width: 100% !important;
        }

    span.dtr-data div {
        margin-right: 5px;
        padding: 0.2rem !important;
    }
}

@media only screen and (min-width: 481px) {
    .root-container {
        padding-left: 17rem;
    }

    .nav-logo i.bi-list {
        display: none;
    }
}

.spinner-buttons {
    display: none;
}

@media (max-width: 768px) {
    .spinner-buttons {
        display: inline-block;
    }
}

.spinner-container {
    display: flex;
    align-items: center;
}

.bs-actionsbox .btn-group {
    width: 100% !important;
}

.driver-zone-cell,
.cabinet-location-cell
{
    vertical-align: middle;
}

.private-checkbox,
.business-checkbox {
    width: 1.2rem;
    height: 1.2rem;
}

.zone-private-icon,
.zone-business-icon,
.location-private-icon,
.location-business-icon {
    font-size: 1.2rem;
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.7);
    z-index: var(--z-index-overlay);
}

    .overlay .spinner-border {
        width: 3rem;
        height: 3rem;
    }

/* fix arrow-down in data tables */
html.dark table.dataTable tr.dt-hasChild td.dt-control:before,
:root[data-bs-theme=dark] table.dataTable tr.dt-hasChild td.dt-control:before {
    border-left-color: transparent !important;
}

table.dataTable th.dt-center {
    text-align: center !important;
}

details.empty > summary {
    list-style: none;
}

.ws-nowrap {
    white-space: nowrap !important;
}

.maintenance-alert {
    display: none;
}

.maintenance-alert.visible {
    display: block;
}

.mappable--suggest-item-control__title {
    color: var(--bs-black);
}

.mappable--hint-subtitle {
    white-space: normal;
}

.mappable--popup-marker_container {
    background-color: unset !important;
    transform: translate(-50%, -50%) !important;
    box-shadow: unset !important;
}

.mappable--popup-marker_tail {
    display: none !important;
}

.dropdown-menu.show {
    max-width: -webkit-fill-available;
 }

.token-search {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .25rem;
    padding: .375rem .5rem;
    min-height: calc(2.25rem + 2px);
    border: 1px solid #ced4da;
    border-radius: .375rem;
    background: var(--bs-body-bg);
    position: relative;
}

    .token-search:focus-within {
        border-color: #86b7fe;
        box-shadow: 0 0 0 .25rem rgba(13,110,253,.15);
    }

.ts-chip {
    display: inline-flex;
    align-items: center;
    gap: .25rem;
    padding: .25rem .5rem;
    border-radius: 999px;
    background: #e9ecef;
    color: #212529;
    font-size: .875rem;
    border: 1px solid #dee2e6;
    cursor: pointer;
}

    .ts-chip .x {
        cursor: pointer;
        margin-left: .25rem;
        font-weight: 700;
    }

.ts-input {
    flex: 1 0 160px;
    min-width: 120px;
    border: 0;
    outline: 0;
    background: transparent;
}

.ts-clear {
    position: absolute;
    right: .25rem;
    top: 50%;
    /*transform: translateY(-50%);*/
}

.ts-menu {
    position: absolute;
    z-index: var(--z-index-menu);
    background: var(--bs-body-bg);
    border: 1px solid #ced4da;
    border-radius: .375rem;
    box-shadow: 0 .5rem 1rem rgba(0,0,0,.15);
    padding: .25rem 0;
    max-height: 320px;
    overflow: auto;
    min-width: 360px;
}

.ts-item {
    padding: .375rem .75rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

    .ts-item:hover, .ts-item.active {
        background: var(--bs-secondary);
    }

.ts-title {
    padding: .375rem .75rem;
    font-weight: 600;
    cursor: default;
}

.ts-actions {
    position: sticky;
    bottom: 0;
    background: var(--bs-body-bg);
    padding: .5rem;
    border-top: 1px solid #eee;
    display: flex;
    gap: .5rem;
}

pre#val {
    min-height: 140px;
}

.ui-timepicker-container {
    z-index: 100000 !important;
}