/*
============================================================
TTT_DISPATCH_DEMAND_OVERVIEW_WEB_V1
============================================================
*/


#ttt-demand-overview {
    margin-bottom: 14px;
}


.ttt-dov-cards {
    display: grid;

    grid-template-columns:
        repeat(
            4,
            minmax(0, 1fr)
        );

    gap: 10px;

    margin-bottom: 11px;
}


.ttt-dov-card {
    position: relative;

    overflow: hidden;

    min-height: 96px;

    padding: 13px 14px;

    border:
        1px solid
        #dfe5ec;

    border-radius: 12px;

    background: #fff;
}


.ttt-dov-card-label {
    color: #64748b;

    font-size: 11px;

    font-weight: 700;

    text-transform: uppercase;

    letter-spacing: .02em;
}


.ttt-dov-card-value {
    display: block;

    margin-top: 6px;

    font-size: 23px;

    font-weight: 850;

    line-height: 1.1;

    color: #182235;
}


.ttt-dov-card-sub {
    display: block;

    margin-top: 6px;

    color: #64748b;

    font-size: 11px;
}


.ttt-dov-progress-track {
    height: 7px;

    margin-top: 9px;

    overflow: hidden;

    border-radius: 99px;

    background: #e9eef4;
}


.ttt-dov-progress-bar {
    height: 100%;

    border-radius: inherit;

    background: #243754;
}


.ttt-dov-section {
    margin-bottom: 11px;

    padding: 12px;

    border:
        1px solid
        #e0e6ee;

    border-radius: 12px;

    background: #fff;
}


.ttt-dov-section-head {
    display: flex;

    align-items: center;

    justify-content: space-between;

    gap: 12px;

    margin-bottom: 10px;
}


.ttt-dov-section-head strong {
    font-size: 13px;

    color: #1e293b;
}


.ttt-dov-section-head small {
    color: #64748b;

    font-size: 11px;
}


.ttt-dov-vehicles {
    display: flex;

    flex-wrap: wrap;

    gap: 8px;
}


.ttt-dov-vehicle {
    min-width: 205px;

    padding: 9px 11px;

    border:
        1px solid
        #dce3eb;

    border-radius: 10px;

    background: #f8fafc;
}


.ttt-dov-vehicle strong {
    display: block;

    margin-bottom: 3px;

    font-size: 13px;
}


.ttt-dov-vehicle span {
    display: block;

    color: #475569;

    font-size: 11px;

    line-height: 1.55;
}


.ttt-dov-vehicle .ttt-dov-load {
    margin-top: 4px;

    color: #172033;

    font-weight: 750;
}


.ttt-dov-demand-table-wrap {
    overflow-x: auto;

    border:
        1px solid
        #e3e8ef;

    border-radius: 10px;
}


.ttt-dov-demand-table {
    width: 100%;

    min-width: 1120px;

    border-collapse: collapse;
}


.ttt-dov-demand-table th {
    padding: 8px 9px;

    border-bottom:
        1px solid
        #dde4ec;

    background: #f8fafc;

    color: #475569;

    font-size: 10px;

    text-align: left;

    white-space: nowrap;
}


.ttt-dov-demand-table td {
    padding: 9px;

    border-bottom:
        1px solid
        #edf1f5;

    font-size: 11px;

    vertical-align: top;
}


.ttt-dov-demand-table tr:last-child td {
    border-bottom: 0;
}


.ttt-dov-route strong {
    display: block;
}


.ttt-dov-route span {
    display: block;

    margin: 2px 0;

    color: #94a3b8;
}


.ttt-dov-number {
    font-weight: 800;

    white-space: nowrap;
}


.ttt-dov-demand-progress {
    min-width: 125px;
}


.ttt-dov-demand-progress-track {
    height: 6px;

    overflow: hidden;

    border-radius: 999px;

    background: #e8edf3;
}


.ttt-dov-demand-progress-bar {
    height: 100%;

    background: #243754;

    border-radius: inherit;
}


.ttt-dov-demand-progress small {
    display: block;

    margin-top: 4px;

    color: #64748b;
}


.ttt-dov-status {
    display: inline-flex;

    padding: 4px 7px;

    border-radius: 999px;

    font-size: 10px;

    font-weight: 750;

    white-space: nowrap;

    background: #fff0d2;

    color: #895800;
}


.ttt-dov-status.done {
    background: #e5f6eb;

    color: #167044;
}


.ttt-dov-status.partial {
    background: #e8eef9;

    color: #39588c;
}


.ttt-dov-trip-list {
    display: flex;

    flex-direction: column;

    gap: 4px;

    min-width: 190px;
}


.ttt-dov-trip-btn {
    display: block;

    width: 100%;

    padding: 6px 7px;

    border:
        1px solid
        #dfe5ec;

    border-radius: 7px;

    background: #f8fafc;

    color: #243044;

    font-size: 10px;

    text-align: left;

    cursor: pointer;
}


.ttt-dov-trip-btn:hover {
    background: #edf2f7;
}


.ttt-dov-trip-btn strong {
    display: block;
}


.ttt-dov-trip-btn span {
    display: block;

    margin-top: 2px;

    color: #64748b;
}


.ttt-dov-muted {
    color: #94a3b8;
}


.ttt-dov-loading,
.ttt-dov-error {
    padding: 16px;

    border:
        1px solid
        #e0e6ee;

    border-radius: 11px;

    background: #fff;

    color: #64748b;

    font-size: 12px;
}


.ttt-dov-error {
    border-color: #f0cece;

    background: #fff6f6;

    color: #a12a2a;
}


@media (
    max-width: 1000px
) {

    .ttt-dov-cards {
        grid-template-columns:
            repeat(
                2,
                minmax(0, 1fr)
            );
    }
}


@media (
    max-width: 600px
) {

    .ttt-dov-cards {
        grid-template-columns:
            1fr;
    }


    .ttt-dov-vehicle {
        width: 100%;
    }
}


/*
============================================================
TTT_DISPATCH_CUSTOMER_PROGRESS_V2
============================================================
*/


.ttt-dov-customer-row {
    cursor: default;
}


.ttt-dov-customer-row:hover td {
    background: #fbfcfe;
}


.ttt-dov-customer-row.expanded td {
    background: #f8fafc;
}


.ttt-dov-customer-toggle {
    display: inline-flex;

    align-items: center;

    gap: 7px;

    padding: 4px 5px;

    border: 0;

    border-radius: 7px;

    background: transparent;

    color: #172033;

    cursor: pointer;

    text-align: left;
}


.ttt-dov-customer-toggle:hover {
    background: #edf2f7;
}


.ttt-dov-customer-arrow {
    width: 14px;

    color: #64748b;

    font-size: 9px;

    text-align: center;
}


.ttt-dov-detail-button {
    border: 1px solid #d8e0e9;

    border-radius: 8px;

    padding: 6px 9px;

    background: #f8fafc;

    color: #334155;

    font-size: 10px;

    font-weight: 750;

    cursor: pointer;

    white-space: nowrap;
}


.ttt-dov-detail-button:hover {
    background: #e9eef4;
}


.ttt-dov-customer-remaining {
    color: #a46000;
}


.ttt-dov-customer-complete {
    color: #167044;
}


.ttt-dov-customer-detail > td {
    padding: 0 9px 12px !important;

    background: #f8fafc;
}


.ttt-dov-customer-detail-box {
    padding: 12px;

    border:
        1px solid
        #dce4ed;

    border-radius: 10px;

    background: #fff;
}


.ttt-dov-customer-detail-title {
    display: flex;

    align-items: center;

    justify-content: space-between;

    gap: 10px;

    margin-bottom: 9px;

    color: #334155;

    font-size: 11px;
}


.ttt-dov-customer-detail-title strong {
    font-size: 12px;
}


.ttt-dov-customer-detail-table-wrap {
    overflow-x: auto;
}


.ttt-dov-customer-detail-table {
    width: 100%;

    min-width: 1100px;

    border-collapse: collapse;
}


.ttt-dov-customer-detail-table th {
    padding: 7px 8px;

    border-bottom:
        1px solid
        #dfe6ee;

    background: #f8fafc;

    color: #64748b;

    font-size: 9px;

    text-align: left;

    white-space: nowrap;
}


.ttt-dov-customer-detail-table td {
    padding: 8px;

    border-bottom:
        1px solid
        #edf1f5;

    font-size: 10px;

    vertical-align: top;
}


.ttt-dov-customer-detail-table tr:last-child td {
    border-bottom: 0;
}


/*
============================================================
TTT_CUSTOMER_NESTED_PROPOSALS_V3

Proposal table cũ nằm toàn cục được ẩn.
Proposal giờ nằm trong từng khách hàng.
============================================================
*/


#ttt-demand-queue-overlay
.ttt-demand-table-wrap {
    display: none;
}


#ttt-demand-queue-overlay
#ttt-dq-summary {
    display: none;
}


.ttt-dov-proposal-table {
    min-width: 1350px;
}


.ttt-dov-demand-header-row > td {
    padding: 8px !important;

    background: #f1f5f9 !important;
}


.ttt-dov-demand-header {
    display: flex;

    align-items: center;

    justify-content: space-between;

    gap: 15px;

    padding: 5px 7px;
}


.ttt-dov-demand-header > div {
    min-width: 0;
}


.ttt-dov-demand-header strong {
    display: block;

    color: #172033;

    font-size: 11px;
}


.ttt-dov-demand-header span {
    display: block;

    margin-top: 3px;

    color: #64748b;

    font-size: 10px;
}


.ttt-dov-proposal-action {
    border: 0;

    border-radius: 7px;

    padding: 7px 10px;

    background: #172033;

    color: #fff;

    font-size: 10px;

    font-weight: 800;

    white-space: nowrap;

    cursor: pointer;
}


.ttt-dov-proposal-action.secondary {
    border:
        1px solid
        #d8e0e9;

    background: #f8fafc;

    color: #334155;
}


.ttt-dov-proposal-action:hover {
    opacity: .9;
}
