﻿
.bt-page {
    direction: rtl;
    width: 100%;
    min-width: 0;
}

.bt-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 14px;
}

.bt-stat {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 72px;
    padding: 12px 14px;
    border: 1px solid #d7dee5;
    border-radius: 12px;
    background: #fff;
    cursor: pointer;
    transition: border-color .15s, background .15s, box-shadow .15s;
    user-select: none;
}

    .bt-stat:hover {
        box-shadow: 0 3px 10px rgba(4, 68, 100, .08);
    }

    .bt-stat.is-active {
        box-shadow: inset 0 0 0 1px currentColor;
    }

.bt-stat--all.is-active {
    border-color: #044464;
    background: #f2f7fa;
}

.bt-stat--action {
    border-color: #044464;
    background: #f2f7fa;
}

    .bt-stat--action.is-active {
        border-color: #d97706;
        background: #fff8eb;
    }

.bt-stat--out {
    border-color: #b8d4e8;
}

    .bt-stat--out.is-active {
        border-color: #187bbf;
        background: #eef6fb;
    }

.bt-stat--in {
    border-color: #c5ddd0;
}

    .bt-stat--in.is-active {
        border-color: #2f8f6b;
        background: #eef8f3;
    }

.bt-stat__icon {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
}

.bt-stat--all .bt-stat__icon {
    color: #044464;
    background: rgba(4, 68, 100, .1);
}

.bt-stat--action .bt-stat__icon {
    color: #b45309;
    background: rgba(245, 158, 11, .16);
}

.bt-stat--out .bt-stat__icon {
    color: #0b5f8f;
    background: rgba(24, 123, 191, .12);
}

.bt-stat--in .bt-stat__icon {
    color: #1f6b4f;
    background: rgba(47, 143, 107, .12);
}

.bt-stat__meta {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
}

.bt-stat__value {
    font-size: 1.4rem;
    font-weight: 700;
    line-height: 1;
    color: #044464;
}

.bt-stat--action .bt-stat__value {
    color: #b45309;
}

.bt-stat--out .bt-stat__value {
    color: #0b5f8f;
}

.bt-stat--in .bt-stat__value {
    color: #1f6b4f;
}

.bt-stat__label {
    font-size: .8rem;
    color: #64748b;
    font-weight: 500;
}

.bt-panel {
    border: 1px solid rgba(4, 68, 100, .12);
    border-radius: 14px;
    background: #fff;
    overflow: hidden;
}

.bt-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    padding: 12px 16px;
    border-bottom: 1px solid rgba(4, 68, 100, .08);
    background: #f7f9fb;
}

.bt-toolbar__search {
    flex: 1 1 220px;
    min-width: 180px;
    max-width: 380px;
}

    .bt-toolbar__search .mud-input-control {
        margin: 0;
    }

.bt-toolbar__info {
    font-size: .78rem;
    color: #64748b;
    white-space: nowrap;
}

.bt-table-wrap {
    width: 100%;
    overflow-x: auto;
}

.bt-table__head,
.bt-table__row {
    display: grid;
    grid-template-columns: minmax(88px, 0.75fr) minmax(88px, 0.8fr) minmax(118px, 1.05fr) minmax(120px, 1fr) minmax(62px, 0.5fr) minmax(100px, 1.15fr) 148px;
    gap: 8px 12px;
    align-items: center;
    padding: 10px 14px;
}

.bt-table__head {
    background: #f7f9fb;
    border-bottom: 1px solid rgba(4, 68, 100, .1);
    font-size: .74rem;
    font-weight: 700;
    color: #64748b;
}

    .bt-table__head span,
    .bt-table__row > div {
        min-width: 0;
    }

    .bt-table__head .bt-col-actions,
    .bt-col-actions {
        text-align: center;
    }

.bt-table__row {
    border-bottom: 1px solid rgba(4, 68, 100, .07);
    font-size: .82rem;
    color: #334155;
    transition: background .12s;
}

    .bt-table__row:last-child {
        border-bottom: none;
    }

    .bt-table__row:hover {
        background: rgba(4, 68, 100, .028);
    }

    .bt-table__row.is-actionable {
        background: rgba(24, 123, 191, .04);
    }

        .bt-table__row.is-actionable:hover {
            background: rgba(24, 123, 191, .07);
        }

.bt-table__title {
    font-weight: 700;
    color: #044464;
    line-height: 1.4;
    word-break: break-word;
}

.bt-table__route {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: .78rem;
    color: #475569;
    min-width: 0;
}

    .bt-table__route span {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

.bt-table__route-arrow {
    color: #94a3b8;
    flex-shrink: 0;
    font-size: .7rem;
}

.bt-table__meta {
    font-size: .76rem;
    color: #64748b;
    white-space: nowrap;
}

.bt-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: .72rem;
    font-weight: 600;
    white-space: nowrap;
}

.bt-badge--out {
    color: #0b5f8f;
    background: rgba(24, 123, 191, .1);
}

.bt-badge--in {
    color: #1f6b4f;
    background: rgba(47, 143, 107, .1);
}

.bt-badge--warn {
    color: #9a6700;
    background: rgba(245, 158, 11, .14);
}

.bt-badge--info {
    color: #0b5f8f;
    background: rgba(24, 123, 191, .1);
}

.bt-badge--ok {
    color: #166534;
    background: rgba(34, 197, 94, .12);
}

.bt-badge--err {
    color: #b91c1c;
    background: rgba(239, 68, 68, .1);
}

.bt-badge--muted {
    color: #64748b;
    background: rgba(100, 116, 139, .1);
}

.bt-actions {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

    .bt-actions .mud-button-root {
        min-height: 30px;
        height: 30px;
        padding: 0 10px;
        font-size: .74rem;
        white-space: nowrap;
    }

.bt-actions__row {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
    justify-content: center;
}

.bt-error {
    grid-column: 1 / -1;
    font-size: .76rem;
    color: #b91c1c;
    background: rgba(239, 68, 68, .06);
    border: 1px solid rgba(239, 68, 68, .14);
    border-radius: 8px;
    padding: 6px 10px;
    margin: 0 16px 8px;
}

.bt-empty {
    text-align: center;
    padding: 48px 20px;
}

.bt-empty__icon {
    font-size: 2.4rem;
    color: #187bbf;
    opacity: .85;
    margin-bottom: 10px;
}

@media (max-width: 960px) {
    .bt-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 768px) {
    .bt-table__head {
        display: none;
    }

    .bt-table__row {
        grid-template-columns: 1fr;
        gap: 6px;
        padding: 12px 14px;
    }

        .bt-table__row .bt-col-actions {
            order: -1;
            padding-bottom: 8px;
            margin-bottom: 4px;
            border-bottom: 1px dashed rgba(4, 68, 100, .12);
        }

    .bt-actions {
        justify-content: flex-start;
    }
}

@media (max-width: 520px) {
    .bt-stats {
        grid-template-columns: 1fr;
    }
}

.layout-theme.theme-dark .bt-stat--action {
    background: #1a2836 !important;
    border-color: rgba(150, 191, 218, 0.28);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.04);
}

.layout-theme.theme-dark .bt-stat {
    background: #1a2836 !important;
    border-color: rgba(150, 191, 218, 0.28);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.04);
}

.layout-theme.theme-dark .bt-stat__label {
    color: #b6cae8;
}

.layout-theme.theme-dark .bt-stat__value {
    color: #addcf4;
}

.layout-theme.theme-dark .bt-stat--in .bt-stat__icon {
    color: #4ad8a3;
}

.layout-theme.theme-dark .bt-stat--out .bt-stat__icon {
    color: #a5daf8;
}

.layout-theme.theme-dark .bt-stat--action .bt-stat__icon {
    color: #e09a64;
}

.layout-theme.theme-dark .bt-stat--all .bt-stat__icon {
    color: #57b9ea;
}

.layout-theme.theme-dark .bt-toolbar {
    background: #1a2836;
    border-bottom: 1px solid rgb(255 255 255 / 8%);
}

.layout-theme.theme-dark .bt-panel {
    background: #1a2836 !important;
}

.layout-theme.theme-dark .bt-toolbar__info {
    color: rgb(170 204 220);
}
.layout-theme.theme-dark .mud-drawer .mud-drawer-content {
    background: #0D3A50;
    background: linear-gradient(180deg,rgba(9, 39, 53, 1) 20%, rgba(11, 48, 67, 1) 50%, rgba(121, 103, 57, 1) 100%) !important;
}