.tch-brand-link,
.tch-mobile-brand {
    text-decoration: none;
}

.tch-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.875rem;
    color: #13233b;
}

.tch-brand--light {
    color: #ffffff;
}

.tch-brand--stacked {
    flex-direction: column;
    gap: 0.85rem;
    text-align: center;
}

.tch-brand--compact {
    gap: 0;
}

.tch-brand-mark {
    display: block;
    width: 2.5rem;
    height: 2.5rem;
    flex: 0 0 auto;
}

.tch-brand--light .tch-brand-mark {
    filter: brightness(0) invert(1);
}

.tch-brand--stacked .tch-brand-mark {
    width: 3.75rem;
    height: 3.75rem;
}

.tch-brand--compact .tch-brand-mark {
    width: 2rem;
    height: 2rem;
}

.tch-brand-name {
    display: block;
    color: currentColor;
    font-size: 1.3rem;
    font-weight: 700;
    letter-spacing: 0.015em;
    line-height: 1;
    white-space: nowrap;
}

.tch-brand--stacked .tch-brand-name {
    font-size: 1.55rem;
}

.tch-brand-link {
    display: flex;
    align-items: center;
    min-width: 0;
}

.tch-brand-link .logo-default,
.tch-brand-link .logo-minimize {
    align-items: center;
}

.tch-brand-link .logo-minimize {
    display: none;
}

[data-kt-aside-minimize="on"] .tch-brand-link .logo-default {
    display: none;
}

[data-kt-aside-minimize="on"] .tch-brand-link .logo-minimize {
    display: inline-flex;
}

.aside .aside-logo .tch-brand-name {
    font-size: 1.125rem;
}

.login-header .tch-brand {
    justify-content: center;
}

.login-header .tch-brand-name {
    font-size: 1.7rem;
}

.tch-mobile-brand .tch-brand-name {
    font-size: 1.2rem;
}

@media (max-width: 575.98px) {
    .tch-brand--stacked .tch-brand-name {
        font-size: 1.4rem;
    }

    .tch-brand--stacked .tch-brand-mark {
        width: 3.25rem;
        height: 3.25rem;
    }
}
.tch-dashboard-toolbar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tch-dashboard-toolbar .badge {
    min-height: 32px;
    padding: 0.55rem 0.75rem;
}

.tch-dashboard-search {
    min-height: 32px;
}

.tch-dashboard-search #search-input {
    width: 220px;
}

.tch-dashboard-content {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
}

.tch-map-shell {
    position: relative;
    width: 100%;
    height: calc(100vh - 120px);
    min-height: 620px;
    overflow: hidden;
    border: 0;
    background: #eef3f8;
}

#fleet-map {
    width: 100%;
    height: 100%;
    z-index: 1;
}

.tch-detail-map,
.tch-history-map {
    width: 100%;
    min-height: 360px;
    overflow: hidden;
    border: 1px solid #eff2f5;
    border-radius: 0.475rem;
    background: #eef3f8;
}

.tch-detail-map {
    height: 100%;
    min-height: 560px;
}

.tch-history-map {
    height: calc(100vh - 230px);
    min-height: 620px;
}

.tch-history-content {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
}

.tch-history-content #kt_toolbar_container {
    position: relative;
    flex-wrap: nowrap !important;
    gap: 0.75rem !important;
    overflow-x: auto;
}

.tch-toolbar-strip-loader {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 5;
    height: 3px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.15s ease;
}

.tch-toolbar-strip-loader::before {
    position: absolute;
    top: 0;
    left: 0;
    width: 30%;
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, rgba(0, 158, 247, 0), #009ef7 45%, #50cd89 100%);
    content: "";
    animation: tch-toolbar-strip-loader 1.05s ease-in-out infinite alternate;
}

.tch-toolbar-strip-loader.is-active {
    opacity: 1;
}

[data-history-download][aria-busy="true"] {
    opacity: 0.72;
    pointer-events: none;
}

@keyframes tch-toolbar-strip-loader {
    from {
        transform: translateX(-110%);
    }

    to {
        transform: translateX(335%);
    }
}

.tch-history-content #kt_toolbar .page-title {
    flex: 0 1 auto;
    min-width: 0;
    margin-bottom: 0 !important;
}

.tch-history-content #kt_toolbar .breadcrumb {
    flex-wrap: nowrap;
    overflow: hidden;
    white-space: nowrap;
}

.tch-history-content #kt_toolbar .breadcrumb-item {
    flex: 0 0 auto;
}

.tch-history-content #kt_toolbar_container > .d-flex:last-child {
    flex: 0 0 auto;
    flex-wrap: nowrap !important;
}

.tch-history-filter,
.tch-history-replay-controls {
    flex: 0 0 auto;
}

.tch-history-content #kt_post {
    min-height: 0;
    padding: 0;
}

.tch-history-content #kt_content_container {
    height: 100%;
}

.tch-history-map-shell {
    position: relative;
    width: 100%;
    height: calc(100vh - 120px);
    min-height: 620px;
    overflow: hidden;
    background: #eef3f8;
}

.tch-history-map-shell .tch-history-map {
    height: 100%;
    min-height: 0;
    border: 0;
    border-radius: 0;
}

.tch-history-empty {
    position: absolute;
    top: 16px;
    left: 16px;
    z-index: 900;
    max-width: min(460px, calc(100% - 32px));
    margin: 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.tch-replay-marker-icon {
    border: 0;
    background: transparent;
}

.tch-replay-marker {
    display: block;
    width: 18px;
    height: 18px;
    border: 3px solid #fff;
    border-radius: 50%;
    background: #f1416c;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.32);
}

.tch-map-loading {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 900;
    padding: 0.65rem 0.85rem;
    border: 1px solid #eff2f5;
    border-radius: 0.475rem;
    background: #fff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    color: #5e6278;
    font-size: 0.925rem;
    font-weight: 600;
}

.tch-map-loading.is-hidden {
    display: none;
}

.tch-vehicle-marker {
    border: 0;
    background: transparent;
}

.tch-device-map-icon {
    border: 0;
    background: transparent;
}

.tch-device-map-marker {
    position: relative;
    font-size: 24px;
    line-height: 1;
    filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.35));
}

.vehicle-marker {
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    border: 2px solid #fff;
    border-radius: 50% 50% 50% 0;
    background: #009ef7;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.24);
    transform: rotate(-45deg);
}

.vehicle-marker span {
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    line-height: 1;
    transform: rotate(45deg);
}

.vehicle-marker-online {
    background: #50cd89;
}

.vehicle-marker-idle {
    background: #ffc700;
}

.vehicle-marker-offline {
    background: #a1a5b7;
}

.tch-cluster {
    border: 0;
    border-radius: 50%;
    background: rgba(0, 158, 247, 0.16);
    box-shadow: 0 4px 14px rgba(0, 158, 247, 0.28);
}

.tch-cluster div {
    display: grid;
    place-items: center;
    width: 100%;
    height: 100%;
    border: 2px solid #fff;
    border-radius: 50%;
    background: #009ef7;
}

.tch-cluster span {
    color: #fff;
    font-size: 13px;
    font-weight: 700;
}

@media (max-width: 991.98px) {
    .tch-dashboard-toolbar {
        justify-content: flex-start;
    }

    .tch-map-shell {
        height: calc(100vh - 120px);
        min-height: 520px;
    }

    .tch-dashboard-search {
        width: 100%;
    }

    .tch-dashboard-search #search-input {
        width: auto;
        flex: 1;
    }

    .tch-history-map-shell {
        height: calc(100vh - 120px);
        min-height: 520px;
    }

    .tch-map-loading {
        right: 12px;
        top: 12px;
    }
}
