﻿.customers-it-page {
    padding: 22px;
    min-height: 100vh;
    background: linear-gradient(180deg,#f4f7fc 0%,#eef3f9 100%);
}

.customers-it-header {
    background: #fff;
    border: 1px solid #dbe4f0;
    border-radius: 24px;
    padding: 22px;
    margin-bottom: 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    box-shadow: 0 14px 34px rgba(15,23,42,.06);
}

    .customers-it-header h1 {
        margin: 0;
        font-size: 36px;
        color: #0f172a;
        letter-spacing: -.04em;
    }

    .customers-it-header p {
        margin: 4px 0 0;
        color: #64748b;
        font-size: 14px;
    }

.customer-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.bc-card-btn {
    height: 42px;
    border: 0;
    border-radius: 14px;
    padding: 0 16px;
    background: #eef2f7;
    color: #0f172a;
    font-weight: 900;
    cursor: pointer;
}

    .bc-card-btn:first-child {
        background: linear-gradient(135deg,#2563eb,#1d4ed8);
        color: white;
        box-shadow: 0 10px 22px rgba(37,99,235,.22);
    }

.customers-it-toolbar {
    background: #fff;
    border: 1px solid #dbe4f0;
    border-radius: 20px;
    padding: 14px;
    margin-bottom: 14px;
    display: grid;
    grid-template-columns: 1.4fr 1fr auto auto auto;
    gap: 12px;
    align-items: center;
    box-shadow: 0 10px 26px rgba(15,23,42,.04);
}

    .customers-it-toolbar input[type="text"],
    .customers-it-toolbar input:not([type]) {
        width: 100%;
        height: 44px;
        border: 1px solid #dbe4f0;
        border-radius: 14px;
        padding: 0 14px;
        outline: none;
        font-weight: 700;
    }

    .customers-it-toolbar input:focus {
        border-color: #2563eb;
        box-shadow: 0 0 0 3px rgba(37,99,235,.12);
    }

    .customers-it-toolbar label {
        display: inline-flex;
        align-items: center;
        gap: 7px;
        color: #475569;
        font-size: 13px;
        font-weight: 900;
        white-space: nowrap;
    }

    .customers-it-toolbar button {
        height: 44px;
        border: 0;
        border-radius: 14px;
        padding: 0 18px;
        background: linear-gradient(135deg,#2563eb,#1d4ed8);
        color: white;
        font-weight: 900;
        cursor: pointer;
    }

.customers-it-grid {
    display: grid;
    gap: 14px;
}

    .customers-it-grid.with-list {
        grid-template-columns: 38% 62%;
    }

    .customers-it-grid.card-only {
        grid-template-columns: 1fr;
    }

.customers-it-table,
.customers-it-card,
.bc26-empty-card {
    background: white;
    border: 1px solid #dbe4f0;
    border-radius: 24px;
    box-shadow: 0 14px 34px rgba(15,23,42,.06);
}

.customers-it-table {
    overflow: auto;
    max-height: calc(100vh - 210px);
}

    .customers-it-table table {
        width: 100%;
        border-collapse: collapse;
        min-width: 900px;
    }

    .customers-it-table th {
        position: sticky;
        top: 0;
        z-index: 5;
        background: #f8fafc;
        color: #64748b;
        font-size: 12px;
        font-weight: 950;
        text-align: left;
        padding: 13px 14px;
        border-bottom: 1px solid #e5edf7;
    }

    .customers-it-table td {
        padding: 13px 14px;
        border-bottom: 1px solid #eef2f7;
        color: #0f172a;
        font-size: 13px;
    }

    .customers-it-table tr {
        cursor: pointer;
    }

        .customers-it-table tr:hover {
            background: #f8fbff;
        }

        .customers-it-table tr.active {
            background: #e8f0ff;
        }

.debt {
    color: #b91c1c;
    font-weight: 950;
    white-space: nowrap;
}

.badge {
    display: inline-flex;
    justify-content: center;
    min-width: 74px;
    padding: 6px 11px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 950;
}

    .badge.ok {
        background: #dcfce7;
        color: #166534;
        border: 1px solid #bbf7d0;
    }

    .badge.danger {
        background: #fee2e2;
        color: #991b1b;
        border: 1px solid #fecaca;
    }

.customers-it-card {
    overflow: hidden;
}

.nav-ribbon {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    padding: 14px 18px;
    border-bottom: 1px solid #e8edf5;
    background: #f8fafc;
}

.nav-ribbon-btn {
    height: 38px;
    border: 0;
    border-radius: 12px;
    padding: 0 14px;
    background: #eef2f7;
    color: #0f172a;
    font-size: 12px;
    font-weight: 900;
    cursor: pointer;
}

    .nav-ribbon-btn:first-child {
        background: linear-gradient(135deg,#16a34a,#15803d);
        color: white;
    }

    .nav-ribbon-btn.danger {
        background: #fee2e2;
        color: #991b1b;
    }

.nav-card-title {
    padding: 20px 24px;
    border-bottom: 1px solid #e8edf5;
    font-size: 30px;
    color: #0f172a;
    font-weight: 950;
}

.nav-card-layout {
    display: grid;
    grid-template-columns: minmax(0,1fr) 280px;
}

.nav-card-main {
    padding: 22px 24px;
}

.nav-section {
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 18px;
    margin-bottom: 18px;
}

.nav-section-title {
    margin-bottom: 14px;
    color: #0f172a;
    font-size: 16px;
    font-weight: 950;
}

.nav-form-grid {
    display: grid;
    grid-template-columns: 170px minmax(0,1fr) 170px minmax(0,1fr);
    gap: 12px 18px;
    align-items: center;
}

    .nav-form-grid label {
        display: contents;
        color: #64748b;
        font-size: 12px;
        font-weight: 900;
    }

    .nav-form-grid input {
        height: 40px;
        border: 1px solid #dbe4f0;
        border-radius: 12px;
        padding: 0 12px;
        outline: none;
        font-weight: 700;
        color: #0f172a;
    }

        .nav-form-grid input:focus {
            border-color: #2563eb;
            box-shadow: 0 0 0 3px rgba(37,99,235,.10);
        }

        .nav-form-grid input:disabled {
            background: #f1f5f9;
            color: #475569;
        }

        .nav-form-grid input[type="checkbox"] {
            width: 20px;
            height: 20px;
            accent-color: #2563eb;
        }

.nav-factbox {
    background: #f8fafc;
    border-left: 1px solid #e5edf7;
    padding-bottom: 16px;
}

.factbox-title {
    padding: 14px 16px;
    border-bottom: 1px solid #e5edf7;
    color: #0f172a;
    font-size: 13px;
    font-weight: 950;
}

.bc26-picture {
    height: 130px;
    display: grid;
    place-items: center;
    font-size: 68px;
    color: #cbd5e1;
    border-bottom: 1px solid #e5edf7;
}

.factbox-row {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding: 12px 16px;
    border-bottom: 1px solid #e5edf7;
    font-size: 13px;
}

    .factbox-row span {
        color: #64748b;
        font-weight: 800;
    }

    .factbox-row b {
        color: #2563eb;
        text-align: right;
        font-weight: 950;
    }

.negative-balance {
    color: #dc2626 !important;
}

.nav-actions-bottom {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 18px;
}

.nav-save,
.nav-cancel {
    height: 42px;
    min-width: 110px;
    border: 0;
    border-radius: 14px;
    font-weight: 950;
    cursor: pointer;
}

.nav-save {
    background: linear-gradient(135deg,#2563eb,#1d4ed8);
    color: white;
}

.nav-cancel {
    background: #eef2f7;
    color: #0f172a;
}

.msg-ok,
.msg-error {
    margin-top: 14px;
    padding: 13px 15px;
    border-radius: 14px;
    font-weight: 900;
}

.msg-ok {
    background: #ecfdf3;
    color: #027a48;
    border: 1px solid #abefc6;
}

.msg-error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

.bc26-empty-card {
    padding: 28px;
    color: #64748b;
    font-weight: 800;
}

@media (max-width: 1200px) {
    .customers-it-grid.with-list {
        grid-template-columns: 1fr;
    }

    .customers-it-table {
        max-height: 420px;
    }

    .nav-card-layout {
        grid-template-columns: 1fr;
    }

    .nav-factbox {
        border-left: 0;
        border-top: 1px solid #e5edf7;
    }
}

@media (max-width: 760px) {
    .customers-it-page {
        padding: 10px;
    }

    .customers-it-header {
        flex-direction: column;
        align-items: stretch;
        border-radius: 20px;
        padding: 18px;
    }

        .customers-it-header h1 {
            font-size: 28px;
        }

    .customer-actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .bc-card-btn {
        width: 100%;
    }

    .customers-it-toolbar {
        grid-template-columns: 1fr;
        border-radius: 18px;
    }

    .customers-it-table table {
        min-width: 850px;
    }

    .nav-card-title {
        font-size: 24px;
        padding: 18px;
    }

    .nav-ribbon {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .nav-card-main {
        padding: 18px;
    }

    .nav-form-grid {
        grid-template-columns: 1fr;
        gap: 7px;
    }

        .nav-form-grid label {
            display: flex;
            flex-direction: column;
            gap: 6px;
        }

    .nav-actions-bottom {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }
}
.customer-view-card {
    padding: 28px;
}

.customer-view-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 28px;
}

.customer-view-label {
    color: #64748b;
    font-size: 13px;
    margin-bottom: 8px;
    font-weight: 700;
}

.customer-view-title {
    font-size: 42px;
    font-weight: 900;
    color: #0f172a;
    line-height: 1.1;
}

.customer-view-no {
    margin-top: 10px;
    color: #2563eb;
    font-size: 30px;
    font-weight: 900;
}

.customer-view-sections {
    display: grid;
    gap: 26px;
}

.customer-view-section {
    border-top: 1px solid #e2e8f0;
    padding-top: 18px;
}

    .customer-view-section h4 {
        margin: 0 0 16px;
        color: #0f172a;
        font-size: 16px;
        font-weight: 900;
    }

.customer-view-grid {
    display: grid;
    grid-template-columns: repeat(2,minmax(0,1fr));
    gap: 14px;
}

.detail-box {
    background: #f8fafc;
    border: 1px solid #e5edf7;
    border-radius: 14px;
    padding: 14px;
}

.detail-caption {
    color: #64748b;
    font-size: 12px;
    font-weight: 800;
    margin-bottom: 7px;
}

.detail-value {
    color: #0f172a;
    font-size: 15px;
    font-weight: 900;
    word-break: break-word;
}

@media(max-width:900px) {

    .customer-view-grid {
        grid-template-columns: 1fr;
    }

    .customer-view-title {
        font-size: 28px;
    }

    .customer-view-no {
        font-size: 22px;
    }

    .customer-view-top {
        flex-direction: column;
    }
}
.detail-box span {
    display: block;
    color: #64748b;
    font-size: 12px;
    font-weight: 800;
    margin-bottom: 7px;
}

.detail-box b {
    display: block;
    color: #0f172a;
    font-size: 15px;
    font-weight: 900;
    min-height: 20px;
}