.crm-lead-page {
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-height: calc(100vh - 90px);
    background: #f4f7fb;
}

/* Contract module */
.crm-contract-page {
    min-height: calc(100vh - 92px);
}

.crm-contract-main,
.crm-contract-main > .container-fluid,
.crm-contract-main > .container-fluid > .row {
    min-height: 0;
}

.crm-contract-page .section-buttons,
.crm-contract-page .section_buttons_height_left {
    min-height: 46px;
}

.crm-contract-header-left .section_buttons_height_left {
    background: #0790ab;
}

.crm-contract-header-right,
.crm-contract-header-right .section-buttons,
.crm-contract-page .crm-campaign-header-titlebar {
    background: #015e70;
    border-bottom: 0;
}

.crm-contract-page .crm-campaign-header-title {
    min-width: 0;
    overflow: hidden;
    color: #ffffff;
    font-size: 1.05rem;
    font-weight: 800;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.crm-contract-header-right .button-theme_light {
    border-color: rgba(255, 255, 255, 0.45);
    background: rgba(255, 255, 255, 0.92);
    color: #12364a;
}

.crm-contract-main {
    padding: 5px 10px 0 5px;
    background: #f4f7fb;
}

.crm-contract-sidebar {
    padding-left: 0 !important;
}

@media (min-width: 1200px) {
    .crm-contract-page .crm-contract-master-col {
        width: 40%;
        max-width: 40%;
        flex: 0 0 40%;
    }

    .crm-contract-page .crm-contract-detail-col {
        width: 60%;
        max-width: 60%;
        flex: 0 0 60%;
    }

    .crm-contract-split-row {
        flex-wrap: nowrap;
    }
}

.crm-contract-sidebar .section-sidebar,
.crm-contract-workspace .section-information {
    min-height: 0;
}

.crm-contract-sidebar .tab-inner {
    min-height: 0;
}

.crm-contract-sidebar-table {
    min-height: 0;
    max-height: none;
    overflow-x: auto;
    overflow-y: visible;
}

.crm-contract-page .theme-table.theme-table_height.crm-contract-sidebar-table {
    height: auto;
    max-height: none;
    overflow-y: visible;
}

.crm-contract-sidebar-table .table {
    min-width: 580px;
    table-layout: fixed;
}

.crm-contract-sidebar-table .table th,
.crm-contract-sidebar-table .table td {
    padding: 7px 8px;
    vertical-align: middle;
}

.crm-contract-sidebar-table .table th {
    color: #60738a;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
}

.crm-contract-sidebar-table th:nth-child(1),
.crm-contract-sidebar-table td:nth-child(1) {
    width: 82px;
}

.crm-contract-sidebar-table th:nth-child(2),
.crm-contract-sidebar-table td:nth-child(2) {
    width: 90px;
}

.crm-contract-sidebar-table th:nth-child(4),
.crm-contract-sidebar-table td:nth-child(4) {
    width: 100px;
}

.crm-contract-sidebar-table th:nth-child(5),
.crm-contract-sidebar-table td:nth-child(5) {
    width: 86px;
}

.crm-contract-sidebar-cell--amount {
    color: #015e70;
    font-size: 0.78rem;
}

.crm-task-sidebar-cell {
    min-width: 0;
}

.crm-task-sidebar-code,
.crm-task-sidebar-title,
.crm-contract-sidebar-title {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.crm-task-sidebar-title {
    color: #183550;
    font-weight: 700;
}

.crm-contract-sidebar-cell--title small {
    display: block;
    min-width: 0;
    overflow: hidden;
    color: #6f8196;
    font-size: 0.72rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.crm-task-sidebar-status {
    display: inline-flex;
    max-width: 100%;
    min-height: 22px;
    align-items: center;
    padding: 2px 7px;
    border-radius: 4px;
    background: #eef3f8;
    color: #52657a;
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
}

.crm-task-sidebar-status--todo {
    background: #fff5dd;
    color: #99640d;
}

.crm-task-sidebar-status--in-progress {
    background: #dff5f7;
    color: #11606b;
}

.crm-task-sidebar-status--done {
    background: #e4f6e8;
    color: #246b37;
}

.crm-task-sidebar-status--canceled {
    background: #fde7e7;
    color: #a83c3c;
}

.crm-task-sidebar .row-clickable {
    cursor: pointer;
}

.crm-task-sidebar .row-clickable.table-active td,
.crm-task-sidebar .row-clickable:hover td {
    background: #f4fbfc;
}

.contract-page-counter {
    color: #61758a;
    font-size: 0.78rem;
    font-weight: 700;
    white-space: nowrap;
}

.crm-contract-workspace-inner {
    padding-top: 0;
}

.crm-contract-workspace-panel {
    min-height: 0;
    background: #ffffff;
}

.crm-campaign-main-tabs {
    min-height: 40px;
    padding: 0 10px;
    border-bottom: 1px solid #dbe6f0;
}

.crm-campaign-main-tabs .nav-link {
    border: 0;
    border-bottom: 2px solid transparent;
    color: #64748b;
    font-size: 0.86rem;
    font-weight: 700;
}

.crm-campaign-main-tabs .nav-link.active {
    border-bottom-color: #015e70;
    color: #015e70;
    background: transparent;
}

.crm-campaign-info-strip {
    padding: 8px 10px;
    border-bottom: 1px solid #c9d7e3;
    background: #f8fbfd;
}

.crm-campaign-info-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 1.15fr) minmax(0, 1fr) minmax(150px, auto);
    gap: 8px;
    align-items: start;
}

.crm-campaign-info-line {
    display: grid;
    grid-template-columns: 86px 12px minmax(0, 1fr);
    gap: 4px;
    min-width: 0;
    color: #183550;
    font-size: 0.82rem;
    line-height: 1.55;
}

.crm-campaign-info-label {
    color: #708299;
    font-weight: 700;
}

.crm-campaign-info-value {
    min-width: 0;
    overflow: hidden;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.crm-campaign-info-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    justify-content: flex-end;
}

.crm-campaign-info-actions a {
    text-decoration: none;
}

.crm-contract-upload-note {
    display: block;
    margin-top: 4px;
    color: #60738a;
    font-size: 0.75rem;
    line-height: 1.35;
}

.crm-contract-editor-file-hint {
    min-height: 38px;
    display: flex;
    align-items: center;
    padding: 7px 10px;
    border: 1px dashed #cbd9e6;
    border-radius: 4px;
    background: #f8fbfd;
    color: #60738a;
    font-size: 0.78rem;
}

.crm-contract-tab-toolbar,
.crm-contract-document-upload {
    display: flex;
    align-items: center;
    gap: 10px;
}

.crm-contract-tab-toolbar {
    justify-content: space-between;
}

.crm-contract-document-upload .theme-input {
    min-width: 280px;
}

.crm-contract-documents-table {
    max-height: 470px;
    overflow: auto;
}

.crm-contract-documents-table table {
    min-width: 760px;
}

.crm-contract-documents-table th:last-child,
.crm-contract-documents-table td:last-child {
    min-width: 180px;
}

.crm-contract-indicator-picker-table {
    max-height: 58vh;
    overflow: auto;
}

.crm-contract-indicator-picker-table table {
    min-width: 860px;
}

.crm-contract-indicator-picker-table th:last-child,
.crm-contract-indicator-picker-table td:last-child {
    width: 86px;
    min-width: 86px;
}

.crm-contract-indicator-action.button-theme {
    width: auto;
    min-width: 64px;
    font-family: inherit;
    font-size: 0.78rem;
    line-height: 1.2;
}

.crm-contract-price-input {
    min-width: 130px;
}

.crm-contract-body-scroll,
.crm-contract-dashboard-scroll {
    max-height: none;
    overflow: visible;
    padding: 8px 8px 10px;
}

.crm-task-dashboard-heading {
    display: flex;
    min-height: 82px;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px;
    border: 1px solid #dbe6f0;
    border-radius: 5px;
    background: #ffffff;
}

.crm-task-dashboard-heading h2 {
    margin: 0;
    color: #183550;
    font-size: 1.08rem;
    font-weight: 800;
}

.crm-task-dashboard-kicker,
.crm-task-dashboard-heading__meta span {
    color: #708299;
    font-size: 0.74rem;
    font-weight: 700;
    text-transform: uppercase;
}

.crm-task-dashboard-heading__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
}

.crm-task-dashboard-heading__meta span {
    padding: 5px 8px;
    border: 1px solid #dbe6f0;
    border-radius: 4px;
    background: #f8fbfd;
}

.crm-task-metric-grid,
.crm-contract-summary-grid {
    display: grid;
    gap: 8px;
}

.crm-task-metric-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
    margin-top: 10px;
}

.crm-contract-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.crm-task-metric,
.crm-detail-tile,
.crm-detail-panel {
    border: 1px solid #c9d7e3;
    border-radius: 3px;
    background: #ffffff;
}

.crm-task-metric {
    min-height: 104px;
    padding: 12px;
    border-left: 4px solid #8ba3b8;
}

.crm-task-metric span,
.crm-task-metric strong,
.crm-task-metric small {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.crm-task-metric span {
    color: #708299;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
}

.crm-task-metric strong {
    margin-top: 8px;
    color: #183550;
    font-size: 1.35rem;
    font-weight: 800;
}

.crm-task-metric small {
    color: #60738a;
    font-size: 0.78rem;
}

.crm-contract-metric--total,
.crm-task-metric--kpi {
    border-left-color: #183550;
}

.crm-task-metric--done {
    border-left-color: #2f9b55;
}

.crm-task-metric--warning {
    border-left-color: #d28b22;
}

.crm-task-metric--active {
    border-left-color: #015e70;
}

.crm-task-metric--new {
    border-left-color: #6786b8;
}

.crm-detail-tile {
    padding: 9px 10px;
}

.crm-detail-tile__header strong {
    color: #183550;
    font-size: 0.9rem;
}

.crm-detail-tile__metrics,
.crm-contract-detail-grid {
    display: grid;
    gap: 8px;
}

.crm-detail-tile__metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-top: 8px;
}

.crm-detail-tile__metrics div,
.crm-contract-detail-grid div {
    min-width: 0;
    padding: 7px 9px;
    border: 1px solid #d7e2eb;
    border-radius: 3px;
    background: #f8fbfd;
}

.crm-detail-tile__metrics span,
.crm-detail-tile__metrics strong,
.crm-contract-detail-grid span,
.crm-contract-detail-grid strong {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.crm-detail-tile__metrics span,
.crm-contract-detail-grid span,
.crm-contract-section-title {
    color: #708299;
    font-size: 0.74rem;
    font-weight: 700;
    text-transform: uppercase;
}

.crm-detail-tile__metrics strong,
.crm-contract-detail-grid strong {
    margin-top: 4px;
    color: #183550;
    font-size: 0.9rem;
    font-weight: 800;
}

.crm-detail-panel__body {
    padding: 9px 10px;
}

.crm-contract-detail-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.crm-contract-description {
    margin: 0;
    color: #183550;
    line-height: 1.5;
    white-space: pre-line;
}

.crm-contract-items-table,
.crm-contract-appendix-table {
    max-height: 430px;
    overflow: auto;
}

.crm-contract-items-table table,
.crm-contract-appendix-table table {
    min-width: 1050px;
    table-layout: fixed;
}

.crm-contract-appendix-toolbar,
.crm-quote-editor-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.crm-quote-editor-muted {
    color: #708299;
    font-size: 0.78rem;
    font-weight: 700;
}

.contract-quote-picker-modal {
    z-index: 1070;
}

.contract-quote-picker-backdrop {
    z-index: 1065;
}

.contract-quote-picker-modal .modal-dialog {
    width: min(760px, calc(100vw - 32px));
    max-width: 760px;
}

.contract-quote-picker-modal .modal-body {
    padding: 18px 16px;
}

.crm-contract-quote-picker-field {
    display: grid;
    gap: 6px;
    width: 100%;
    min-width: 0;
}

.crm-contract-quote-picker-field > .theme-label {
    width: 100%;
    min-width: 0;
}

.crm-contract-quote-combobox {
    position: relative;
    width: 100%;
    min-width: 0;
}

.crm-contract-quote-combobox > .position-relative,
.crm-contract-quote-combobox .theme-input {
    width: 100%;
    max-width: none !important;
}

.crm-contract-quote-spinner,
.crm-contract-quote-chevron {
    position: absolute;
    top: 50%;
    right: 14px;
    z-index: 2;
    color: #60738a;
    transform: translateY(-50%);
    pointer-events: none;
}

.crm-contract-quote-options {
    width: 100%;
    margin-top: 4px;
    max-height: 280px;
    overflow-y: auto;
    overflow-x: hidden;
    border: 1px solid #c9d7e3;
    border-radius: 4px;
    background: #fff;
    box-shadow: 0 10px 24px rgba(12, 34, 56, 0.18);
}

.crm-contract-quote-option {
    display: grid;
    grid-template-columns: minmax(90px, 0.7fr) minmax(0, 1.5fr) minmax(110px, 1fr);
    gap: 10px;
    width: 100%;
    min-width: 0;
    padding: 8px 10px;
    border: 0;
    border-bottom: 1px solid #e4ebf1;
    background: #fff;
    color: #183550;
    text-align: left;
}

.crm-contract-quote-option:last-child {
    border-bottom: 0;
}

.crm-contract-quote-option:hover,
.crm-contract-quote-option.active {
    background: #eaf4f7;
}

.crm-contract-quote-option strong,
.crm-contract-quote-option span,
.crm-contract-quote-option small {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.crm-contract-quote-option small,
.crm-contract-quote-empty {
    color: #708299;
}

.crm-contract-quote-empty {
    padding: 14px;
    text-align: center;
}

@media (max-width: 575.98px) {
    .contract-quote-picker-modal .modal-dialog {
        width: calc(100vw - 20px);
        margin-right: auto;
        margin-left: auto;
    }

    .crm-contract-quote-option {
        grid-template-columns: minmax(72px, 0.7fr) minmax(0, 1.3fr);
    }

    .crm-contract-quote-option small {
        grid-column: 1 / -1;
    }
}

.crm-contract-appendix-table th:last-child,
.crm-contract-appendix-table td:last-child {
    width: 54px;
}

.crm-contract-appendix-group td {
    background: #eaf3f8 !important;
    border-color: #c5d9e5 !important;
    color: #123b52;
    font-weight: 700;
    padding: 7px 10px !important;
}

.crm-contract-appendix-group__name {
    align-items: center;
    display: inline-flex;
    gap: 7px;
}

.crm-contract-appendix-group__count {
    color: #60788a;
    font-size: 0.75rem;
    font-weight: 600;
    margin-left: 10px;
}

.crm-quote-print-shell {
    background: #f5f8fb;
}

.crm-quote-print-actions {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 10px;
}

.crm-quote-print-content {
    max-width: 210mm;
    min-height: 297mm;
    margin: 0 auto;
    padding: 14mm;
    background: #ffffff;
    color: #111827;
    box-shadow: 0 18px 40px rgba(24, 53, 80, 0.12);
}

.crm-quote-print-title {
    text-align: center;
}

.crm-quote-print-title h1 {
    margin: 0 0 6px;
    color: #111827;
    font-size: 1.5rem;
    font-weight: 800;
}

.crm-quote-print-meta,
.crm-quote-print-customer,
.crm-quote-print-bottom {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
    margin-top: 14px;
}

.crm-quote-print-meta div,
.crm-quote-print-customer div,
.crm-quote-print-note div,
.crm-quote-print-total div {
    padding: 8px;
    border: 1px solid #d6dee8;
}

.crm-quote-print-meta span,
.crm-quote-print-customer span,
.crm-quote-print-note span,
.crm-quote-print-total span {
    display: block;
    color: #64748b;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
}

.crm-quote-print-meta strong,
.crm-quote-print-customer strong,
.crm-quote-print-total strong {
    display: block;
    margin-top: 4px;
}

.crm-quote-print-table {
    width: 100%;
    margin-top: 14px;
    border-collapse: collapse;
}

.crm-quote-print-table th,
.crm-quote-print-table td {
    padding: 7px 8px;
    border: 1px solid #111827;
}

.crm-quote-print-bottom {
    grid-template-columns: minmax(0, 1fr) 260px;
}

.crm-quote-print-signatures {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 40px;
    margin-top: 32px;
    text-align: center;
}

.crm-quote-print-signatures strong,
.crm-quote-print-signatures span {
    display: block;
}

@media print {
    body.quote-printing * {
        visibility: hidden !important;
    }

    body.quote-printing .quote-print-modal,
    body.quote-printing .quote-print-modal * {
        visibility: visible !important;
    }
}

.contract-editor-modal {
    z-index: 1060;
}

.contract-editor-modal + .modal-backdrop {
    z-index: 1055;
}

@media (max-width: 1200px) {
    .crm-contract-sidebar .section-sidebar,
    .crm-contract-workspace .section-information {
        min-height: auto;
    }

    .crm-contract-sidebar-table {
        max-height: 430px;
    }

    .crm-task-metric-grid,
    .crm-contract-detail-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .crm-campaign-info-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 768px) {
    .crm-contract-tab-toolbar,
    .crm-contract-document-upload {
        align-items: stretch;
        flex-direction: column;
    }

    .crm-contract-document-upload .theme-input {
        min-width: 0;
    }

    .crm-task-metric-grid,
    .crm-contract-summary-grid,
    .crm-contract-detail-grid,
    .crm-campaign-info-grid,
    .crm-quote-print-meta,
    .crm-quote-print-customer,
    .crm-quote-print-bottom {
        grid-template-columns: 1fr;
    }

    .crm-contract-body-scroll,
    .crm-contract-dashboard-scroll {
        max-height: none;
    }
}

.crm-lead-card__title-button {
    padding: 0;
    border: 0;
    background: transparent;
    color: #17324d;
    font-weight: 700;
    text-align: left;
}

.crm-lead-card__title-button:hover {
    color: var(--primary-color);
}

.crm-lead-card__action-group {
    display: flex;
    align-items: center;
    gap: 6px;
}

.crm-lead-detail-page {
    position: relative;
    min-height: calc(100vh - 90px);
    padding: 12px;
    background:
        radial-gradient(circle at top left, rgba(34, 197, 94, 0.10), transparent 28%),
        radial-gradient(circle at bottom right, rgba(59, 130, 246, 0.10), transparent 22%),
        #f3f7fb;
}

.crm-lead-detail {
    display: grid;
    grid-template-columns: minmax(320px, 390px) minmax(0, 1fr);
    gap: 16px;
    align-items: start;
}

.crm-lead-detail__sidebar {
    position: sticky;
    top: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.crm-lead-detail__content {
    display: flex;
    flex-direction: column;
    gap: 14px;
    min-width: 0;
}

.crm-lead-detail__state {
    padding: 48px 28px;
    border: 1px dashed #c8d6e6;
    border-radius: 5px;
    background: rgba(255, 255, 255, 0.92);
    color: #45607c;
    text-align: center;
    box-shadow: 0 20px 45px -36px rgba(15, 44, 88, 0.4);
}

.crm-detail-card,
.crm-detail-panel,
.crm-lead-quick__box {
    border: 1px solid rgba(199, 213, 224, 0.82);
    border-radius: 5px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 22px 50px -40px rgba(15, 44, 88, 0.48);
    backdrop-filter: blur(10px);
}

.crm-detail-card {
    padding: 16px;
}

.crm-detail-card--hero {
    background:
        linear-gradient(145deg, rgba(15, 118, 110, 0.04), transparent 55%),
        rgba(255, 255, 255, 0.95);
}

.crm-detail-card__breadcrumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 10px;
    color: #5f7390;
    font-size: 0.88rem;
}

.crm-detail-card__crumb {
    padding: 0;
    border: 0;
    background: transparent;
    color: #2b7de9;
}

.crm-detail-card__title-row {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 12px;
    margin-top: 12px;
}

.crm-detail-card__title {
    margin: 0;
    color: #183550;
    font-size: 1.7rem;
    line-height: 1.25;
}

.crm-detail-card__subtitle {
    margin: 6px 0 0;
    color: #61738a;
}

.crm-detail-card__section-title {
    margin-bottom: 14px;
    color: #1d3557;
    font-size: 1rem;
    font-weight: 700;
}

.crm-detail-card__stats {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
    margin-top: 12px;
}

.crm-detail-stat {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 10px;
    border-radius: 5px;
    background: #f8fbff;
    border: 1px solid #e2ebf3;
}

.crm-detail-stat--value {
    background: linear-gradient(135deg, #e7fff2 0%, #ecf8ff 100%);
}

.crm-detail-stat--quick {
    background: linear-gradient(180deg, #f8fbff 0%, #ffffff 100%);
}

.crm-detail-stat__label {
    color: #6b7d94;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.crm-detail-stat strong {
    color: #17324d;
    font-size: 1rem;
}

.crm-detail-info-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 0;
}

.crm-detail-info-list__row {
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 12px;
}

.crm-detail-info-list__row dt {
    color: #66788e;
    font-weight: 500;
}

.crm-detail-info-list__row dd {
    margin: 0;
    color: #183550;
    font-weight: 600;
}

.crm-detail-person {
    display: flex;
    gap: 12px;
}

.crm-detail-person__avatar {
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: linear-gradient(135deg, #fecaca 0%, #fca5a5 100%);
    color: #991b1b;
    font-weight: 700;
}

.crm-detail-person__content {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.crm-detail-person__content strong {
    color: #183550;
}

.crm-detail-person__content a,
.crm-detail-person__content span {
    color: #2b7de9;
    text-decoration: none;
    word-break: break-word;
}

.crm-detail-stagebar {
    position: relative;
    display: flex;
    align-items: stretch;
    gap: 10px;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
    overflow: visible;
}

.crm-detail-stagebar__flow {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    align-items: stretch;
    gap: 3px;
    overflow: visible;
    padding: 0;
    border-radius: 0;
    background: transparent;
}

.crm-detail-stagebar__item {
    position: relative;
    flex: 1 1 0;
    min-width: 0;
    min-height: 40px;
    padding: 0 24px 0 30px;
    border: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #cfdceb;
    color: #54687f;
    font-weight: 700;
    text-align: center;
    white-space: nowrap;
    box-shadow: none;
    clip-path: polygon(0 0, calc(100% - 18px) 0, 100% 50%, calc(100% - 18px) 100%, 0 100%, 18px 50%);
    transition: filter 0.18s ease, transform 0.18s ease;
}

.crm-detail-stagebar__item span {
    position: relative;
    z-index: 2;
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
}

.crm-detail-stagebar__item::before {
    display: none;
}

.crm-detail-stagebar__item::after {
    display: none;
}

.crm-detail-stagebar__item:first-child {
    padding-left: 20px;
    clip-path: polygon(0 0, calc(100% - 18px) 0, 100% 50%, calc(100% - 18px) 100%, 0 100%);
}

.crm-detail-stagebar__item + .crm-detail-stagebar__item {
    margin-left: 0;
}

.crm-detail-stagebar__item--completed {
    background: linear-gradient(180deg, #31c85b 0%, #27b74f 100%);
    color: #fff;
}

.crm-detail-stagebar__item--current {
    background: linear-gradient(180deg, #2fcf5d 0%, #25b74f 100%);
    color: #fff;
    box-shadow: none;
}

.crm-detail-stagebar__terminal {
    position: relative;
    flex: 0 0 232px;
}

.crm-detail-stagebar__terminal-trigger {
    width: 100%;
    min-height: 40px;
    padding: 0 16px 0 18px;
    border: 1px solid #d5e1ec;
    border-radius: 5px;
    background: #fff;
    color: #233548;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    box-shadow: none;
}

.crm-detail-stagebar__terminal-trigger--open {
    border-color: #c4d4e4;
}

.crm-detail-stagebar__terminal-trigger--won {
    border-color: #a7f3d0;
    background: #ecfdf5;
    color: #166534;
}

.crm-detail-stagebar__terminal-trigger--lost {
    border-color: #fecaca;
    background: #fef2f2;
    color: #b91c1c;
}

.crm-detail-stagebar__terminal-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    z-index: 15;
    width: 100%;
    padding: 8px;
    border: 1px solid #dbe6f0;
    border-radius: 5px;
    background: #fff;
    box-shadow: 0 24px 36px -28px rgba(15, 23, 42, 0.45);
}

.crm-detail-stagebar__terminal-option {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border: 0;
    border-radius: 5px;
    background: #fff;
    color: #1f2937;
    font-weight: 600;
    text-align: left;
}

.crm-detail-stagebar__terminal-option:hover {
    background: #f8fafc;
}

.crm-detail-stagebar__terminal-option--won .crm-detail-stagebar__terminal-dot {
    background: #22c55e;
}

.crm-detail-stagebar__terminal-option--lost .crm-detail-stagebar__terminal-dot {
    background: #ef4444;
}

.crm-detail-stagebar__terminal-option--current {
    background: #f8fafc;
    opacity: 0.72;
}

.crm-detail-stagebar__terminal-dot {
    width: 10px;
    height: 10px;
    flex: 0 0 10px;
    border-radius: 50%;
}

.crm-stage-outcome-modal {
    position: fixed;
    inset: 0;
    z-index: 1300;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(15, 23, 42, 0.32);
}

.crm-stage-outcome-modal__dialog {
    width: min(640px, 100%);
}

.crm-stage-outcome-modal__panel {
    overflow: hidden;
    border-radius: 5px;
    background: #fff;
    box-shadow: 0 34px 60px -34px rgba(15, 23, 42, 0.55);
}

.crm-stage-outcome-modal__header,
.crm-stage-outcome-modal__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 20px;
}

.crm-stage-outcome-modal__header {
    border-bottom: 1px solid #e5e7eb;
}

.crm-stage-outcome-modal__header strong {
    color: #1f2937;
    font-size: 1.05rem;
}

.crm-stage-outcome-modal__body {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 18px 20px;
}

.crm-stage-outcome-modal__field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.crm-stage-outcome-modal__field-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.crm-stage-outcome-modal__field label {
    color: #334155;
    font-weight: 600;
}

.crm-stage-outcome-modal__input-group {
    display: grid;
    grid-template-columns: 64px minmax(0, 1fr);
    align-items: stretch;
    border: 1px solid #dbe6f0;
    border-radius: 5px;
    overflow: hidden;
    background: #fff;
}

.crm-stage-outcome-modal__input-group span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #f8fafc;
    color: #64748b;
    font-weight: 700;
}

.crm-stage-outcome-modal__input-group input {
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.crm-stage-outcome-modal__footer {
    border-top: 1px solid #e5e7eb;
    justify-content: end;
}

.crm-stage-outcome-modal__close {
    width: 36px;
    height: 36px;
    border: 1px solid #dbe6f0;
    border-radius: 5px;
    background: #fff;
    color: #475569;
}

.crm-detail-panel {
    overflow: hidden;
}

.crm-detail-tabs {
    display: flex;
    gap: 4px;
    padding: 10px 12px 0;
    border-bottom: 1px solid #e3ebf3;
    overflow-x: auto;
}

.crm-detail-tabs__item {
    padding: 12px 14px;
    border: 0;
    border-bottom: 2px solid transparent;
    background: transparent;
    color: #183550;
    font-weight: 600;
    white-space: nowrap;
}

.crm-detail-tabs__item--active {
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.crm-detail-panel__body {
    padding: 16px;
    min-height: 420px;
}

/* Contracts follow the document flow: the browser page owns vertical scrolling. */
.crm-contract-page .crm-detail-panel {
    overflow: visible;
    border-color: #c9d7e3;
    border-radius: 3px;
    box-shadow: none;
}

.crm-contract-page .crm-detail-panel__body {
    min-height: 0;
    padding: 9px 10px;
}

.crm-contract-page .crm-contract-workspace-panel,
.crm-contract-page .crm-contract-sidebar .section-sidebar,
.crm-contract-page .crm-contract-workspace .section-information {
    min-height: 0;
    height: auto;
}

.crm-contract-page .crm-contract-body-scroll,
.crm-contract-page .crm-contract-dashboard-scroll {
    max-height: none;
    overflow: visible;
}

.crm-contract-page .theme-table.theme-table_height.crm-contract-sidebar-table {
    height: auto;
    max-height: none;
    overflow-x: auto;
    overflow-y: visible;
}

.crm-contract-page .crm-contract-documents-table,
.crm-contract-page .crm-contract-items-table,
.crm-contract-page .crm-contract-appendix-table {
    max-height: none;
    overflow-x: auto;
    overflow-y: visible;
}

.crm-detail-empty {
    min-height: 220px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 28px;
    border: 1px dashed #c9d7e5;
    border-radius: 5px;
    color: #5e7187;
    text-align: center;
    background: #fbfdff;
}

.crm-detail-empty--content {
    justify-content: flex-start;
    align-items: stretch;
    text-align: left;
}

.crm-detail-empty--action {
    min-height: 320px;
    border-style: solid;
    border-color: #d7e4f2;
    background:
        radial-gradient(circle at top, rgba(59, 130, 246, 0.08), transparent 42%),
        linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.crm-detail-empty--content p {
    margin: 0;
    color: #30485f;
    line-height: 1.7;
}

.crm-detail-empty__stack {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    max-width: 360px;
}

.crm-detail-empty__visual {
    width: 92px;
    height: 92px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #d8e4f1;
    border-radius: 24px;
    background: linear-gradient(180deg, #ffffff 0%, #eef5fc 100%);
    color: #8ca0b7;
    font-size: 2rem;
    box-shadow: inset 0 -10px 24px rgba(191, 219, 254, 0.28);
}

.crm-detail-empty__visual--quote {
    color: #7c3aed;
    box-shadow: inset 0 -10px 24px rgba(221, 214, 254, 0.35);
}

.crm-detail-empty__title {
    color: #183550;
    font-size: 1.65rem;
    line-height: 1.2;
}

.crm-detail-empty__hint {
    margin: 0;
    color: #71859b;
    line-height: 1.7;
}

.crm-detail-empty__action {
    padding: 10px 20px;
    border: 1px solid #1d8cf8;
    border-radius: 5px;
    background: #fff;
    color: #1d8cf8;
    font-weight: 700;
    box-shadow: 0 14px 24px -22px rgba(29, 140, 248, 0.55);
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.crm-detail-empty__action:hover {
    background: #eff6ff;
    transform: translateY(-1px);
}

.crm-detail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 14px;
}

.crm-detail-tile {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 16px;
    border: 1px solid #e3ebf4;
    border-radius: 5px;
    background: #fbfdff;
}

.crm-detail-tile__header {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 12px;
}

.crm-detail-tile__header strong {
    color: #183550;
}

.crm-detail-tile__header span,
.crm-detail-tile__description {
    color: #66788e;
}

.crm-detail-tile__description {
    margin: 0;
    line-height: 1.6;
}

.crm-detail-tile__metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.crm-detail-tile__metrics div {
    padding: 10px;
    border-radius: 5px;
    background: #f4f8fb;
}

.crm-detail-tile__metrics span {
    display: block;
    margin-bottom: 3px;
    color: #6b7d94;
    font-size: 0.78rem;
}

.crm-detail-tile__metrics strong {
    color: #183550;
    font-size: 0.95rem;
}

.crm-detail-file__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.crm-detail-file__footer span {
    color: #607389;
}

.crm-detail-timeline {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.crm-timeline-card {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr);
    gap: 14px;
    align-items: start;
}

.crm-timeline-card__icon {
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 1rem;
}

.crm-timeline-card__icon--blue { background: #dbeafe; color: #1d4ed8; }
.crm-timeline-card__icon--teal { background: #ccfbf1; color: #0f766e; }
.crm-timeline-card__icon--amber { background: #fef3c7; color: #b45309; }
.crm-timeline-card__icon--indigo { background: #e0e7ff; color: #4338ca; }
.crm-timeline-card__icon--green { background: #dcfce7; color: #15803d; }
.crm-timeline-card__icon--orange { background: #ffedd5; color: #c2410c; }
.crm-timeline-card__icon--slate { background: #e2e8f0; color: #475569; }
.crm-timeline-card__icon--yellow { background: #fef9c3; color: #a16207; }

.crm-timeline-card__body {
    padding: 16px 18px;
    border-radius: 5px;
    background: #fbfdff;
    border: 1px solid #e5edf5;
}

.crm-timeline-card__top {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 12px;
}

.crm-timeline-card__eyebrow {
    color: #6b7d94;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.crm-timeline-card__top h3 {
    margin: 4px 0 0;
    color: #183550;
    font-size: 1rem;
}

.crm-timeline-card__time,
.crm-timeline-card__meta,
.crm-timeline-card__description,
.crm-timeline-card__footer {
    color: #62758c;
}

.crm-timeline-card__meta,
.crm-timeline-card__description {
    margin: 10px 0 0;
    line-height: 1.6;
}

.crm-timeline-card__footer {
    margin-top: 12px;
    font-size: 0.9rem;
}

.crm-lead-quick {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
}

.crm-lead-quick__launcher {
    width: 58px;
    height: 58px;
    border: 0;
    border-radius: 50%;
    background: linear-gradient(135deg, #0f766e 0%, #2563eb 100%);
    color: #fff;
    font-size: 1.25rem;
    box-shadow: 0 24px 45px -24px rgba(15, 44, 88, 0.72);
}

.crm-lead-quick__menu {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(132px, 1fr));
    gap: 8px;
    width: 100%;
}

.crm-lead-quick__action {
    --quick-accent: #2563eb;
    --quick-soft: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    --quick-border: #bfdbfe;
    --quick-icon-bg: linear-gradient(135deg, #ffffff 0%, #eff6ff 100%);
    --quick-shadow: rgba(37, 99, 235, 0.34);
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border: 1px solid var(--quick-border);
    border-radius: 5px;
    background: var(--quick-soft);
    color: #183550;
    font-weight: 600;
    text-align: left;
    box-shadow: 0 12px 24px -22px var(--quick-shadow);
    transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}

.crm-lead-quick__action:hover {
    transform: translateY(-1px);
    filter: saturate(1.05);
    box-shadow: 0 16px 28px -22px var(--quick-shadow);
}

.crm-lead-quick__action-icon {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 5px;
    border: 1px solid var(--quick-border);
    background: var(--quick-icon-bg);
    color: var(--quick-accent);
}

.crm-lead-quick__action--mail {
    --quick-accent: #2563eb;
    --quick-soft: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    --quick-border: #bfdbfe;
    --quick-icon-bg: linear-gradient(135deg, #ffffff 0%, #e0ecff 100%);
    --quick-shadow: rgba(37, 99, 235, 0.34);
}

.crm-lead-quick__action--call {
    --quick-accent: #059669;
    --quick-soft: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
    --quick-border: #a7f3d0;
    --quick-icon-bg: linear-gradient(135deg, #ffffff 0%, #dcfce7 100%);
    --quick-shadow: rgba(5, 150, 105, 0.34);
}

.crm-lead-quick__action--file {
    --quick-accent: #7c3aed;
    --quick-soft: linear-gradient(135deg, #f5f3ff 0%, #ede9fe 100%);
    --quick-border: #ddd6fe;
    --quick-icon-bg: linear-gradient(135deg, #ffffff 0%, #f3e8ff 100%);
    --quick-shadow: rgba(124, 58, 237, 0.32);
}

.crm-lead-quick__action--note {
    --quick-accent: #ea580c;
    --quick-soft: linear-gradient(135deg, #fff7ed 0%, #ffedd5 100%);
    --quick-border: #fed7aa;
    --quick-icon-bg: linear-gradient(135deg, #ffffff 0%, #ffedd5 100%);
    --quick-shadow: rgba(234, 88, 12, 0.32);
}

.crm-lead-quick__action--activity {
    --quick-accent: #db2777;
    --quick-soft: linear-gradient(135deg, #fdf2f8 0%, #fce7f3 100%);
    --quick-border: #fbcfe8;
    --quick-icon-bg: linear-gradient(135deg, #ffffff 0%, #fce7f3 100%);
    --quick-shadow: rgba(219, 39, 119, 0.32);
}

.crm-lead-quick-modal {
    position: fixed;
    inset: 0;
    z-index: 1290;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(15, 23, 42, 0.32);
}

.crm-lead-quick-modal__dialog {
    width: min(820px, 100%);
}

.crm-lead-quick-modal .crm-lead-quick__box {
    width: 100%;
    border-radius: 5px;
    box-shadow: 0 34px 60px -34px rgba(15, 23, 42, 0.55);
}

.crm-lead-quick__box {
    width: 100%;
    overflow: hidden;
}

.crm-lead-quick__box-header,
.crm-lead-quick__box-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 18px;
}

.crm-lead-quick__box-header {
    border-bottom: 1px solid #e3ebf4;
}

.crm-lead-quick__box-header strong {
    display: block;
    color: #183550;
}

.crm-lead-quick__box-header span {
    color: #65788f;
}

.crm-lead-quick__box-body {
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 16px 18px;
    max-height: min(48vh, 520px);
    overflow: auto;
}

.crm-lead-quick-modal .crm-lead-quick__box-body {
    max-height: min(72vh, 680px);
}

.crm-lead-quick__box-footer {
    border-top: 1px solid #e3ebf4;
}

.crm-lead-quick__close {
    width: 34px;
    height: 34px;
    border: 1px solid #dbe6f0;
    border-radius: 5px;
    background: #f8fbff;
    color: #5d7187;
}

.crm-lead-quick__field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.crm-lead-quick__field label {
    color: #334155;
    font-weight: 600;
}

.crm-lead-quick__field-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.crm-lead-quick__hint {
    color: #607389;
    font-size: 0.84rem;
}

.crm-lead-quick__checklist {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.crm-lead-quick__check {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    border-radius: 5px;
    background: #f5f9fd;
    color: #183550;
}

.crm-lead-call__notice,
.crm-lead-call__number-card,
.crm-lead-call__metrics div {
    padding: 12px 14px;
    border: 1px solid #dbe6f0;
    border-radius: 5px;
    background: #fbfdff;
}

.crm-lead-call__number-card span,
.crm-lead-call__metrics span {
    display: block;
    color: #6b7d94;
    font-size: 0.78rem;
    text-transform: uppercase;
}

.crm-lead-call__number-card strong,
.crm-lead-call__metrics strong {
    color: #183550;
    font-size: 1rem;
}

.crm-lead-call__metrics {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.crm-lead-call__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

@media (max-width: 1199.98px) {
    .crm-lead-detail {
        grid-template-columns: 1fr;
    }

    .crm-lead-detail__sidebar {
        position: static;
    }
}

@media (max-width: 767.98px) {
    .crm-lead-detail-page {
        padding: 8px;
    }

    .crm-detail-card__stats,
    .crm-detail-tile__metrics,
    .crm-lead-call__metrics,
    .crm-lead-quick__field-grid {
        grid-template-columns: 1fr;
    }

    .crm-detail-info-list__row {
        grid-template-columns: 1fr;
        gap: 4px;
    }

    .crm-timeline-card {
        grid-template-columns: 1fr;
    }

    .crm-detail-stagebar {
        flex-direction: column;
        gap: 10px;
    }

    .crm-detail-stagebar__flow {
        flex-direction: column;
        gap: 8px;
    }

    .crm-detail-stagebar__item,
    .crm-detail-stagebar__item:first-child {
        padding: 10px 14px;
        border-radius: 5px;
        clip-path: none;
    }

    .crm-detail-stagebar__item::before,
    .crm-detail-stagebar__item::after {
        display: none;
    }

    .crm-detail-stagebar__item + .crm-detail-stagebar__item {
        margin-left: 0;
    }

    .crm-detail-stagebar__terminal {
        flex: 1 1 auto;
    }

    .crm-stage-outcome-modal__field-grid {
        grid-template-columns: 1fr;
    }

    .crm-lead-quick__menu,
    .crm-lead-quick__box {
        width: 100%;
    }

    .crm-lead-quick__menu {
        grid-template-columns: 1fr;
    }

    .crm-lead-quick-modal {
        padding: 12px;
    }

    .crm-stage-outcome-modal {
        padding: 12px;
    }

    .crm-detail-empty--action {
        min-height: 280px;
    }

    .crm-detail-empty__title {
        font-size: 1.35rem;
    }
}

.crm-lead-page__header {
    border-radius: 0;
    overflow: visible;
    background: transparent;
    box-shadow: none;
    margin: 0;
}

.crm-lead-page__header .container-fluid {
    padding: 0;
}

.crm-lead-page__toolbar {
    border: 1px solid #d8e2ea;
    border-radius: 8px;
    background: var(--bs-white);
    box-shadow: 0 8px 20px -16px rgba(24, 39, 75, 0.22);
}

.crm-lead-page__filters,
.crm-lead-page__summary {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

.crm-lead-page__filters {
    min-width: 0;
}

.crm-lead-page__toolbar-actions {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: nowrap;
    flex: 0 0 auto;
}

.crm-lead-page__search {
    min-width: 240px;
    flex: 1 1 320px;
}

.crm-lead-page__search .input-group-text {
    background: var(--bs-white);
    border: 1px solid #9f9f9f;
    border-right: 0;
    color: #6b7280;
}

.crm-lead-page__search .theme-input {
    border-left: 0;
}

.crm-lead-page__search .theme-input:focus {
    border-left: 0;
}

.crm-lead-page__select {
    min-width: 220px;
    flex: 0 0 220px;
}

.crm-lead-page__summary {
    justify-content: flex-end;
}

.crm-lead-page__summary-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 120px;
    margin: 5px;
    padding: 6px 10px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(6px);
}

.crm-lead-page__summary-label {
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.crm-lead-page__summary-value {
    color: var(--bs-white);
    font-size: 1rem;
    font-weight: 700;
}

.crm-lead-state {
    padding: 2rem;
    border: 1px dashed #b9c8db;
    border-radius: 8px;
    background: var(--bs-white);
    color: #4b5b70;
    text-align: center;
}

.crm-board-scroll {
    overflow-x: auto;
    padding-bottom: 4px;
}

.crm-board {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(290px, 320px);
    gap: 12px;
    align-items: start;
}

.crm-stage {
    display: flex;
    flex-direction: column;
    min-height: 68vh;
    background: var(--bs-white);
    border: 1px solid #d7e1ec;
    border-radius: 5px;
    box-shadow: 0 10px 24px -20px rgba(15, 44, 88, 0.28);
    transition: border-color var(--transition-default), box-shadow var(--transition-default);
}

.crm-stage--dragover {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(var(--primary-rgb), 0.16);
}

.crm-stage__header {
    padding: 12px;
    border-bottom: 1px solid #ebf1f7;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.crm-stage__title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.crm-stage__title {
    color: #163453;
    font-size: 0.95rem;
    font-weight: 700;
}

.crm-stage__add {
    width: 28px;
    height: 28px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: var(--primary-color);
}

.crm-stage__add:hover {
    background: rgba(var(--primary-rgb), 0.08);
}

.crm-stage__metrics {
    display: flex;
    flex-direction: column;
    gap: 6px;
    color: #1d3557;
    font-weight: 600;
}

.crm-stage__progress {
    width: 100%;
    height: 6px;
    border: 0;
    border-radius: 999px;
    overflow: hidden;
    background: #e8edf4;
}

.crm-stage__progress::-webkit-progress-bar {
    background: #e8edf4;
    border-radius: 999px;
}

.crm-stage__progress::-webkit-progress-value {
    background: linear-gradient(90deg, #10b981 0%, #34d399 100%);
    border-radius: 999px;
}

.crm-stage__progress::-moz-progress-bar {
    background: linear-gradient(90deg, #10b981 0%, #34d399 100%);
    border-radius: 999px;
}

.crm-stage__body {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 12px;
    min-height: 220px;
    transition: background-color var(--transition-default);
}

.crm-stage__body--dragover {
    background: #f2f8fb;
}

.crm-stage__empty {
    flex: 1;
    min-height: 300px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 10px;
    padding: 20px 16px;
    border: 1px dashed #d6e1ee;
    border-radius: 6px;
    color: #5c6b7f;
    text-align: center;
}

.crm-stage__empty-icon {
    width: 52px;
    height: 52px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(var(--primary-rgb), 0.08);
    color: var(--primary-color);
    font-size: 1.35rem;
}

.crm-stage__empty-title {
    margin: 0;
    color: #19324d;
    font-weight: 700;
}

.crm-stage__empty-text {
    margin: 0;
    max-width: 220px;
}

.crm-lead-card {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 10px;
    border: 1px solid #e3eaf3;
    border-radius: 8px;
    background: #fbfdff;
    box-shadow: 0 10px 20px -22px rgba(15, 44, 88, 0.45);
    cursor: grab;
    transition: border-color var(--transition-default), box-shadow var(--transition-default), transform var(--transition-default), opacity var(--transition-default);
}

.crm-lead-card:hover {
    border-color: #c6d5e3;
    box-shadow: 0 12px 24px -22px rgba(15, 44, 88, 0.55);
    transform: translateY(-1px);
}

.crm-lead-card:active {
    cursor: grabbing;
}

.crm-lead-card--dragging {
    opacity: 0.55;
    border-style: dashed;
    transform: rotate(1deg);
}

.crm-lead-card--moving {
    opacity: 0.65;
    pointer-events: none;
}

.crm-lead-card__header,
.crm-lead-card__footer {
    display: flex;
    align-items: center;
    gap: 8px;
}

.crm-avatar {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: linear-gradient(135deg, #fde68a 0%, #f59e0b 100%);
    color: #7c2d12;
    font-weight: 700;
}

.crm-lead-card__person {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    flex: 1;
}

.crm-lead-card__person strong,
.crm-lead-card__person span {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.crm-lead-card__person strong {
    color: #17324d;
    font-size: 0.96rem;
}

.crm-lead-card__person span,
.crm-lead-card__description,
.crm-lead-card__meta {
    color: #617286;
    font-size: 0.84rem;
}

.crm-lead-card__rotten {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #fee2e2;
    color: #dc2626;
    font-weight: 700;
}

.crm-lead-card__content {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.crm-lead-card__title {
    margin: 0;
    color: #17324d;
    font-weight: 700;
}

.crm-lead-card__description {
    margin: 0;
    line-height: 1.45;
}

.crm-lead-card__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.crm-lead-card__meta span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.crm-chip-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.crm-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px 10px;
    border-radius: 999px;
    background: #e5e7eb;
    color: #111827;
    font-size: 0.77rem;
    font-weight: 600;
}

.crm-chip--neutral {
    background: #edf2f7;
    color: #334155;
}

.crm-chip--money {
    background: #dbeafe;
    color: #1d4ed8;
}

.crm-lead-card__edit {
    white-space: nowrap;
}

.crm-lead-card__stage {
    min-width: 0;
    flex: 1;
}

.crm-entity-page {
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-height: calc(100vh - 90px);
    background: #f4f7fb;
}

.crm-entity-page__header,
.crm-entity-page__toolbar,
.crm-entity-page__table {
    border-radius: 8px;
    overflow: hidden;
}

.crm-entity-page__header {
    border-radius: 0;
    overflow: visible;
    background: transparent;
    box-shadow: none;
    margin: 0;
}

.crm-entity-page__toolbar,
.crm-entity-page__table {
    border: 1px solid #d8e2ea;
    background: var(--bs-white);
    box-shadow: 0 8px 20px -16px rgba(24, 39, 75, 0.22);
}

.crm-entity-page__header .container-fluid {
    padding: 0;
}

.crm-entity-page__header-strip {
    height: 100%;
}

.crm-entity-page__header-strip--title {
    display: flex;
    align-items: center;
    margin: 0;
}

.crm-entity-page__header-strip--actions {
    padding: 0;
}

.crm-entity-page__header-copy {
    display: flex;
    flex-direction: column;
    gap: 4px;
    justify-content: center;
    min-width: 0;
    color: var(--bs-white);
}

.crm-entity-page__header-copy p {
    margin: 0;
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.92rem;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.crm-entity-page__header-eyebrow {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    opacity: 0.8;
}

.crm-entity-page__actions,
.crm-entity-page__toolbar,
.crm-entity-page__toolbar-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.crm-entity-page__actions {
    margin-left: auto;
    justify-content: flex-end;
}

.crm-entity-page__actions .button-theme {
    white-space: nowrap;
}

.crm-entity-page__toolbar {
    padding: 12px 16px;
}

.crm-entity-page__search {
    min-width: 280px;
    flex: 1 1 360px;
}

.crm-entity-page__filter-select {
    min-width: 220px;
    flex: 0 0 220px;
}

.crm-import-hint {
    color: #5d6f83;
    font-size: 0.84rem;
}

.crm-entity-page__table {
    padding: 12px;
}

.crm-entity-page__table .theme-table,
.crm-entity-page__table table {
    margin-bottom: 0;
}

.crm-table-action-btn {
    width: 36px;
    height: 36px;
    padding: 0;
    border-radius: 3px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    box-shadow: 0 12px 22px -18px rgba(15, 23, 42, 0.48);
    transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}

.crm-table-action-btn--danger {
    box-shadow: 0 14px 24px -18px rgba(220, 53, 69, 0.68);
}

.crm-table-action-btn:hover,
.crm-table-action-btn:focus-visible,
.crm-receiver-delete-btn:hover,
.crm-receiver-delete-btn:focus-visible {
    transform: translateY(-1px);
    filter: saturate(1.04);
}

.crm-table-action-btn:hover,
.crm-table-action-btn:focus-visible {
    box-shadow: 0 16px 28px -20px rgba(15, 23, 42, 0.52);
}

.crm-table-action-btn--danger:hover,
.crm-table-action-btn--danger:focus-visible {
    box-shadow: 0 18px 30px -20px rgba(220, 53, 69, 0.76);
}

.crm-receiver-delete-btn {
    min-height: 34px;
    padding: 0 10px;
    border-radius: 3px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-size: 0.84rem;
    font-weight: 600;
    box-shadow: 0 14px 24px -18px rgba(220, 53, 69, 0.68);
    white-space: nowrap;
}

.crm-campaign-detail-page {
    position: relative;
    min-height: calc(100vh - 90px);
    padding: 12px;
    background:
        radial-gradient(circle at top left, rgba(14, 165, 233, 0.10), transparent 28%),
        radial-gradient(circle at bottom right, rgba(34, 197, 94, 0.10), transparent 24%),
        #f3f7fb;
}

.crm-campaign-detail__toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 16px;
    padding: 14px 16px;
    border: 1px solid #dbe6f0;
    border-radius: 5px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.crm-campaign-detail__toolbar-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.crm-campaign-detail__toolbar-info strong {
    color: #183550;
    font-size: 1rem;
}

.crm-campaign-detail__toolbar-info span {
    color: #61758d;
    line-height: 1.5;
}

.crm-campaign-detail__toolbar-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
}

.crm-campaign-detail__toolbar-actions .button-theme {
    white-space: nowrap;
}

.crm-campaign-detail__import-note {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 12px 14px;
    border: 1px solid #dbe6f0;
    border-radius: 5px;
    background: #f8fbff;
}

.crm-campaign-detail__import-note + .crm-campaign-detail__import-note {
    margin-top: 10px;
}

.crm-campaign-detail__import-note strong {
    color: #183550;
}

.crm-campaign-detail__import-note span {
    color: #64748b;
    line-height: 1.55;
}

.crm-template-variables {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 14px;
    border: 1px solid #dbe6f0;
    border-radius: 5px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.crm-template-variables__head {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.crm-template-variables__head strong {
    color: #183550;
}

.crm-template-variables__head span {
    color: #61758d;
    line-height: 1.55;
}

.crm-template-variables__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 10px;
}

.crm-template-variables__item {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-height: 100%;
    padding: 10px 12px;
    border: 1px solid #dbe6f0;
    border-radius: 4px;
    background: #ffffff;
}

.crm-template-variables__item code {
    color: #0f4c81;
    font-size: 0.78rem;
    font-weight: 700;
}

.crm-template-variables__item strong {
    color: #183550;
    font-size: 0.92rem;
}

.crm-template-variables__item span,
.crm-template-variables__item small {
    color: #64748b;
    line-height: 1.5;
}

.crm-campaign-receiver-modal {
    width: min(960px, 100%);
}

.crm-campaign-customer-modal {
    width: min(1120px, 100%);
}

.crm-campaign-receiver-modal__actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
}

.crm-campaign-receiver-modal__upload {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 12px 14px;
    border: 1px solid #dbe6f0;
    border-radius: 5px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.crm-campaign-receiver-modal__upload-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.crm-campaign-receiver-modal__upload-info strong,
.crm-campaign-receiver-modal__preview-head strong {
    color: #183550;
}

.crm-campaign-receiver-modal__upload-info span,
.crm-campaign-receiver-modal__preview-head span {
    color: #61758d;
    line-height: 1.5;
}

.crm-campaign-receiver-modal__preview-head {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.crm-customer-picker {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.crm-customer-picker__filters {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 240px auto;
    gap: 12px;
    align-items: end;
}

.crm-customer-picker__summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 14px;
    border: 1px solid #dbe6f0;
    border-radius: 3px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.crm-customer-picker__summary-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.crm-customer-picker__summary-text strong {
    color: #183550;
}

.crm-customer-picker__summary-text span {
    color: #64748b;
    line-height: 1.5;
}

.crm-customer-picker__status {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.crm-customer-picker__status strong {
    color: #183550;
    font-size: 0.86rem;
}

.crm-customer-picker__status span {
    color: #64748b;
    font-size: 0.75rem;
    line-height: 1.4;
}

.crm-customer-picker__empty {
    padding: 24px;
    border: 1px dashed #dbe6f0;
    border-radius: 3px;
    text-align: center;
    color: #64748b;
    background: #fbfdff;
}

.crm-customer-picker__pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.crm-customer-picker__pagination span {
    color: #52667c;
    font-size: 0.9rem;
}

@media (max-width: 1366px) {
    .crm-lead-page__summary {
        justify-content: flex-start;
    }
}

@media (max-width: 768px) {
    .crm-lead-page {
        padding: 8px;
    }

    .crm-campaign-detail-page {
        padding: 8px;
    }

    .crm-lead-page__search,
    .crm-lead-page__select,
    .crm-lead-page__toolbar,
    .crm-lead-card__footer,
    .crm-campaign-detail__toolbar-actions,
    .crm-entity-page__search,
    .crm-entity-page__filter-select,
    .crm-entity-page__actions,
    .crm-entity-page__toolbar-actions,
    .crm-entity-page__header-copy {
        width: 100%;
    }

    .crm-lead-page__filters,
    .crm-lead-card__footer,
    .crm-entity-page__actions,
    .crm-entity-page__toolbar-actions,
    .crm-entity-page__header .section-buttons_list {
        justify-content: stretch;
    }

    .crm-lead-page__filters .button-theme,
    .crm-lead-card__footer .button-theme,
    .crm-entity-page__actions .button-theme,
    .crm-entity-page__toolbar-actions .button-theme,
    .crm-lead-card__stage {
        flex: 1 1 auto;
    }

    .crm-entity-page {
        padding: 8px;
    }

    .crm-entity-page__header,
    .crm-entity-page__toolbar,
    .crm-entity-page__table {
        padding-left: 12px;
        padding-right: 12px;
    }

    .crm-entity-page__header {
        padding-left: 0;
        padding-right: 0;
    }

    .crm-entity-page__header .section-buttons_list__item {
        width: 100%;
        flex-wrap: wrap;
    }

    .crm-lead-page__header .section-buttons_list__item {
        width: 100%;
        flex-wrap: wrap;
    }

    .crm-campaign-detail__toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .crm-campaign-receiver-modal__upload,
    .crm-campaign-receiver-modal__actions,
    .crm-customer-picker__summary,
    .crm-customer-picker__pagination {
        flex-direction: column;
        align-items: stretch;
    }

    .crm-customer-picker__filters {
        grid-template-columns: 1fr;
    }
}

.crm-detail-tab-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 14px 16px;
    margin-bottom: 16px;
    border: 1px solid #dbe6f0;
    border-radius: 5px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.crm-detail-tab-actions__info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.crm-detail-tab-actions__info strong {
    color: #183550;
    font-size: 1rem;
}

.crm-detail-tab-actions__info span {
    color: #61758d;
    line-height: 1.5;
}

.crm-detail-tab-actions__button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border: 1px solid #0f6cbd;
    border-radius: 5px;
    background: linear-gradient(135deg, #ffffff 0%, #eff6ff 100%);
    color: #0f6cbd;
    font-weight: 700;
    box-shadow: 0 16px 28px -24px rgba(15, 108, 189, 0.55);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.crm-detail-tab-actions__button:hover {
    transform: translateY(-1px);
    box-shadow: 0 18px 30px -24px rgba(15, 108, 189, 0.62);
}

.crm-stage-outcome-modal__field-grid--triple {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.crm-detail-picker-note,
.crm-detail-quote-summary {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.crm-detail-picker-note {
    padding: 12px 14px;
    border: 1px solid #dbe6f0;
    border-radius: 5px;
    background: #f8fbff;
}

.crm-detail-picker-note strong,
.crm-detail-quote-summary strong {
    color: #183550;
}

.crm-detail-picker-note span,
.crm-detail-quote-summary span {
    color: #64748b;
}

.crm-detail-picker-note strong,
.crm-detail-picker-note span,
.crm-detail-quote-summary strong,
.crm-detail-quote-summary span {
    display: block;
}

.crm-detail-quote-summary {
    padding: 12px 14px;
    border: 1px solid #dbe6f0;
    border-radius: 5px;
    background: linear-gradient(180deg, #f8fbff 0%, #eef6ff 100%);
}

@media (max-width: 768px) {
    .crm-detail-tab-actions,
    .crm-detail-picker-note,
    .crm-detail-quote-summary {
        grid-template-columns: 1fr;
    }

    .crm-detail-tab-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .crm-detail-tab-actions__button {
        justify-content: center;
    }

    .crm-stage-outcome-modal__field-grid--triple {
        grid-template-columns: 1fr;
    }
}

/* EQC orders */
.eqc-order-page {
    min-height: calc(100vh - 64px);
    background: #f4f7fb;
}

.eqc-order-page .row {
    --bs-gutter-x: 0;
}

.eqc-order-header-left .section_buttons_height_left,
.eqc-order-header-right .section-buttons {
    min-height: 52px;
}

.eqc-order-header-counter {
    flex: 0 0 auto;
    color: #60738a;
    font-size: 0.78rem;
    font-weight: 700;
    white-space: nowrap;
}

.eqc-order-layout {
    padding: 5px 10px 0 5px;
}

.eqc-order-layout > .container-fluid,
.eqc-order-layout > .container-fluid > .row {
    flex: 1 1 auto;
    min-height: 0;
}

.eqc-order-sidebar {
    padding-left: 0 !important;
}

.eqc-order-sidebar .section-sidebar,
.eqc-order-workspace .section-information {
    min-height: calc(100vh - 112px);
}

.eqc-order-sidebar .section-sidebar {
    padding-right: 0;
}

.eqc-order-sidebar .tab-inner {
    min-height: 0;
    padding-right: 8px;
}

.eqc-order-sidebar-filter {
    display: grid;
    grid-template-columns: 1fr;
    gap: 6px;
    padding: 0 0 8px;
}

.eqc-order-sidebar-table {
    min-height: 0;
    max-height: calc(100vh - 250px);
    overflow: auto;
}

.eqc-order-sidebar-table .table {
    table-layout: fixed;
}

.eqc-order-sidebar-table .table th,
.eqc-order-sidebar-table .table td {
    padding: 7px 8px;
    vertical-align: middle;
    white-space: normal;
}

.eqc-order-sidebar-table .table th {
    background: #f6fafb;
    color: #30555d;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
}

.eqc-order-sidebar-table th:nth-child(1),
.eqc-order-sidebar-table td:nth-child(1) {
    width: 76px;
}

.eqc-order-sidebar-table th:nth-child(2),
.eqc-order-sidebar-table td:nth-child(2) {
    width: 88px;
}

.eqc-order-sidebar-row {
    cursor: pointer;
}

.eqc-order-sidebar-row:hover td,
.eqc-order-sidebar-row.table-active td {
    background: #e8f6f8;
}

.eqc-order-sidebar-cell--title span,
.eqc-order-sidebar-cell--title small {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.eqc-order-sidebar-cell--title small {
    color: #6f8196;
    font-size: 0.72rem;
}

.eqc-order-workspace {
    min-width: 0;
    background: #ffffff;
}

.eqc-order-workspace-inner {
    padding-top: 5px;
    padding-left: 0;
    background: #ffffff;
}

.eqc-order-workspace .section-information {
    background: #ffffff;
}

.eqc-order-workspace-panel {
    min-height: calc(100vh - 140px);
    background: #ffffff;
}

.eqc-order-info-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1fr);
}

.eqc-order-info-grid .crm-campaign-info-line {
    grid-template-columns: 78px 12px minmax(0, 1fr);
}

.eqc-order-body-scroll {
    max-height: calc(100vh - 235px);
    padding: 10px 10px 14px;
}

.eqc-order-summary-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.eqc-order-detail-panel {
    padding: 12px;
}

.eqc-order-panel-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    color: #183550;
    font-size: 0.9rem;
    font-weight: 800;
}

.eqc-order-panel-title i {
    color: #015e70;
}

.eqc-order-field-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.eqc-order-field {
    min-width: 0;
    padding: 9px 10px;
    border: 1px solid #e2ebf2;
    border-radius: 4px;
    background: #f8fbfd;
}

.eqc-order-field--wide {
    grid-column: span 2;
}

.eqc-order-field span,
.eqc-order-field strong {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.eqc-order-field span {
    color: #708299;
    font-size: 0.73rem;
    font-weight: 700;
    text-transform: uppercase;
}

.eqc-order-field strong {
    margin-top: 3px;
    color: #183550;
    font-size: 0.9rem;
}

.eqc-order-metric-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin-top: 0;
}

.eqc-order-progress {
    height: 8px;
    overflow: hidden;
    border-radius: 999px;
    background: #e6edf3;
}

.eqc-order-progress span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #015e70 0%, #28a0ad 100%);
}

.eqc-order-timeline {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.eqc-order-timeline-item {
    position: relative;
    padding: 0 0 0 18px;
}

.eqc-order-timeline-item::before {
    position: absolute;
    top: 6px;
    left: 0;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #015e70;
    content: "";
}

.eqc-order-timeline-item span,
.eqc-order-timeline-item strong,
.eqc-order-timeline-item small {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.eqc-order-timeline-item span {
    color: #708299;
    font-size: 0.73rem;
    font-weight: 700;
    text-transform: uppercase;
}

.eqc-order-timeline-item strong {
    color: #183550;
    font-size: 0.92rem;
}

.eqc-order-timeline-item small {
    color: #60738a;
}

@media (max-width: 1199.98px) {
    .eqc-order-info-grid,
    .eqc-order-summary-grid,
    .eqc-order-metric-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .eqc-order-sidebar-table {
        max-height: 360px;
    }
}

@media (max-width: 575.98px) {
    .eqc-order-info-grid,
    .eqc-order-summary-grid,
    .eqc-order-field-grid,
    .eqc-order-metric-grid {
        grid-template-columns: 1fr;
    }

    .eqc-order-field--wide {
        grid-column: auto;
    }
}

/* Make order */
.make-order-main {
    background: #f4f7fb;
}

.make-order-sidebar .tab-inner {
    padding-right: 8px;
}

.make-order-sidebar-tools {
    display: grid;
    grid-template-columns: 1fr;
    gap: 6px;
}

.make-order-step-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 6px;
    margin: 4px 0 2px;
}

.make-order-step {
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr);
    gap: 8px;
    align-items: center;
    min-height: 40px;
    padding: 6px 8px;
    border: 1px solid #dbe6f0;
    border-radius: 5px;
    background: #ffffff;
    color: #183550;
    text-align: left;
}

.make-order-step span {
    display: inline-flex;
    width: 24px;
    height: 24px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #eef4f8;
    color: #52677e;
    font-size: 0.78rem;
    font-weight: 800;
}

.make-order-step strong {
    min-width: 0;
    overflow: hidden;
    font-size: 0.82rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.make-order-step--active {
    border-color: #7fc3ce;
    background: #f1fbfc;
}

.make-order-step--active span {
    background: #015e70;
    color: #ffffff;
}

.make-order-recent-table {
    max-height: calc(100vh - 330px);
}

.make-order-recent-table .table {
    table-layout: fixed;
}

.make-order-recent-table th:nth-child(1),
.make-order-recent-table td:nth-child(1) {
    width: 76px;
}

.make-order-recent-table th:nth-child(2),
.make-order-recent-table td:nth-child(2) {
    width: 88px;
}

.make-order-workspace-panel {
    min-height: calc(100vh - 140px);
    background: #ffffff;
}

.make-order-info-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1fr) minmax(170px, auto);
}

.make-order-info-grid .crm-campaign-info-line {
    grid-template-columns: 76px 12px minmax(0, 1fr);
}

.make-order-info-total {
    min-width: 170px;
    padding: 8px 10px;
    border: 1px solid #dbe6f0;
    border-radius: 5px;
    background: #ffffff;
    text-align: right;
}

.make-order-info-total span,
.make-order-info-total strong {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.make-order-info-total span {
    color: #708299;
    font-size: 0.74rem;
    font-weight: 700;
    text-transform: uppercase;
}

.make-order-info-total strong {
    margin-top: 2px;
    color: #183550;
    font-size: 1rem;
    font-weight: 800;
}

.make-order-body-scroll {
    max-height: calc(100vh - 190px);
}

.make-order-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(290px, 340px);
    gap: 10px;
    align-items: start;
}

.make-order-form-stack {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 10px;
}

.make-order-section {
    overflow: hidden;
    border-left: 4px solid #ccd9e4;
    box-shadow: none;
}

.make-order-section--active {
    border-left-color: #015e70;
}

.make-order-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
}

.make-order-section-head div {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 8px;
}

.make-order-section-head span {
    display: inline-flex;
    width: 28px;
    height: 28px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #eef4f8;
    color: #52677e;
    font-size: 0.78rem;
    font-weight: 800;
}

.make-order-section--active .make-order-section-head span {
    background: #015e70;
    color: #ffffff;
}

.make-order-section-head strong,
.make-order-section-head small {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.make-order-section-head strong {
    color: #183550;
    font-size: 0.98rem;
    font-weight: 800;
}

.make-order-section-head small {
    flex: 0 0 auto;
    color: #708299;
    font-size: 0.78rem;
    font-weight: 700;
}

.make-order-preview {
    position: sticky;
    top: 10px;
    min-width: 0;
}

.make-order-preview-card {
    overflow: hidden;
    border-top: 4px solid #015e70;
    box-shadow: none;
}

.make-order-preview-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 10px;
}

.make-order-preview-title span,
.make-order-preview-title strong {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.make-order-preview-title span {
    color: #708299;
    font-size: 0.74rem;
    font-weight: 700;
    text-transform: uppercase;
}

.make-order-preview-title strong {
    color: #183550;
    font-size: 0.96rem;
    font-weight: 800;
}

.make-order-preview-list,
.make-order-money-box {
    display: grid;
    gap: 8px;
}

.make-order-preview-list {
    margin-bottom: 10px;
}

.make-order-preview-list div,
.make-order-money-box div {
    min-width: 0;
    padding: 8px 9px;
    border: 1px solid #e2ebf2;
    border-radius: 4px;
    background: #f8fbfd;
}

.make-order-preview-list span,
.make-order-preview-list strong,
.make-order-money-box span,
.make-order-money-box strong {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.make-order-preview-list span,
.make-order-money-box span {
    color: #708299;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
}

.make-order-preview-list strong,
.make-order-money-box strong {
    margin-top: 3px;
    color: #183550;
    font-size: 0.9rem;
    font-weight: 800;
}

.make-order-money-box {
    margin-bottom: 10px;
}

.make-order-money-box div:last-child {
    border-color: #f0d7a6;
    background: #fffaf0;
}

.make-order-money-box div:last-child strong {
    color: #9a6413;
}

.make-order-progress {
    height: 8px;
    overflow: hidden;
    margin-bottom: 12px;
    border-radius: 999px;
    background: #e6edf3;
}

.make-order-progress span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: #015e70;
}

@media (max-width: 1199.98px) {
    .make-order-grid {
        grid-template-columns: 1fr;
    }

    .make-order-preview {
        position: static;
    }

    .make-order-recent-table {
        max-height: 360px;
    }
}

@media (max-width: 768px) {
    .make-order-info-grid {
        grid-template-columns: 1fr;
    }

    .make-order-info-total {
        min-width: 0;
        text-align: left;
    }

    .make-order-section-head {
        align-items: flex-start;
        flex-direction: column;
    }

    .make-order-section-head small {
        flex: 1 1 auto;
        white-space: normal;
    }
}

/* Make order legacy layout */
.make-order-legacy-page {
    min-height: calc(100vh - 74px);
    padding: 0 0 10px;
    background: #ffffff;
    color: #001b33;
}

.make-order-system-strip {
    display: grid;
    grid-template-columns: 468px minmax(0, 1fr);
    min-height: 46px;
    margin-bottom: 8px;
}

.make-order-system-strip__left,
.make-order-system-strip__right {
    display: flex;
    min-width: 0;
    align-items: center;
}

.make-order-system-strip__left {
    padding: 0 14px;
    background: #0790ab;
    color: #ffffff;
}

.make-order-system-strip__left span {
    overflow: hidden;
    font-size: 1rem;
    font-weight: 800;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.make-order-system-strip__right {
    justify-content: flex-end;
    gap: 8px;
    padding: 0 12px;
    background: #015e70;
}

.make-order-system-strip__right .button-theme_light {
    border-color: rgba(255, 255, 255, 0.45);
    background: rgba(255, 255, 255, 0.92);
    color: #12364a;
}

.make-order-system-strip__right .button-theme {
    min-height: 32px;
    white-space: nowrap;
}

.make-order-legacy-loading {
    display: flex;
    min-height: 220px;
    align-items: center;
    justify-content: center;
    border: 1px solid #d5dce5;
    background: #f6f8fa;
    color: #40566f;
    font-weight: 700;
}

.make-order-legacy-layout {
    display: grid;
    grid-template-columns: 468px minmax(0, 1fr);
    align-items: start;
    gap: 6px;
}

.make-order-legacy-sidebar,
.make-order-legacy-workspace {
    min-width: 0;
}

.make-order-legacy-sidebar {
    border: 1px solid #cfd7e1;
    background: #f4f6f8;
}

.make-order-sidebar-search {
    padding: 8px;
    border-bottom: 1px solid #d5dce5;
    background: #f4f6f8;
}

.make-order-sidebar-search .form-control,
.make-order-info-panel .form-control,
.make-order-info-panel select.form-control,
.make-order-sample-table .form-control,
.make-order-service-table .form-control,
.make-order-sample-head-actions .form-control,
.make-order-total-bar .form-control {
    min-height: 28px;
    height: 28px;
    padding: 3px 6px;
    border-color: #c8d2dc;
    border-radius: 0;
    color: #001b33;
    font-size: 0.84rem;
    line-height: 20px;
}

.make-order-product-list {
    max-height: calc(100vh - 160px);
    overflow: auto;
}

.make-order-product-item {
    display: block;
    width: 100%;
    min-height: 32px;
    padding: 6px 6px;
    border: 0;
    border-bottom: 1px solid #dce2e9;
    background: transparent;
    color: #001b33;
    font-size: 0.88rem;
    font-weight: 800;
    text-align: left;
}

.make-order-product-item:hover {
    background: #e8f2fd;
    color: #0058a7;
}

.make-order-product-empty {
    padding: 12px;
    color: #60738a;
    font-size: 0.86rem;
    text-align: center;
}

.make-order-info-panel {
    padding: 28px 12px 20px;
    border: 1px solid #d5dce5;
    background: #f8f9fa;
}

.make-order-info-panel .col-form-label {
    margin: 0;
    padding-top: 0;
    padding-bottom: 0;
    color: #001b33;
    font-size: 0.86rem;
    font-weight: 500;
    line-height: 28px;
}

.make-order-customer-suggest,
.make-order-service-suggest,
.make-order-quote-suggest {
    position: absolute;
    z-index: 1000;
    right: 0;
    left: 0;
    max-height: 240px;
    overflow: auto;
    border-radius: 0;
    box-shadow: 0 10px 20px rgba(12, 34, 56, 0.16);
}

.make-order-customer-suggest {
    width: min(760px, calc(100vw - 48px));
    min-width: 100%;
}

.make-order-quote-suggest {
    right: 0;
    left: auto;
    width: min(660px, calc(100vw - 48px));
    min-width: 100%;
}

.make-order-quote-suggest .list-group-item {
    display: grid;
    grid-template-columns: 125px minmax(180px, 1fr) 145px;
    gap: 10px;
    align-items: center;
    padding: 6px 9px;
    font-size: 0.82rem;
    cursor: pointer;
}

.make-order-quote-suggest .list-group-item.text-muted {
    display: block;
}

.make-order-quote-suggest .list-group-item > span,
.make-order-quote-suggest .list-group-item > small,
.make-order-quote-suggest .list-group-item > strong {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.make-order-quote-suggest .list-group-item > small {
    text-align: right;
}

.make-order-customer-suggest .list-group-item {
    display: block;
    padding: 7px 10px;
    font-size: 0.82rem;
    white-space: normal;
}

.make-order-customer-suggest__name {
    display: block;
    overflow: visible;
    color: #16324a;
    font-size: 0.88rem;
    line-height: 1.35;
    overflow-wrap: anywhere;
    text-overflow: clip;
    white-space: normal;
}

.make-order-customer-suggest__details {
    display: grid;
    grid-template-columns: 0.75fr 1.15fr 0.75fr 1.6fr;
    gap: 4px 12px;
    margin-top: 3px;
    color: #627386;
}

.make-order-customer-suggest__details span,
.make-order-service-suggest__name,
.make-order-service-suggest > .list-group-item > strong {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}

.make-order-customer-suggest__details span {
    white-space: nowrap;
}

.make-order-customer-suggest__details small {
    color: #34495e;
    font-size: inherit;
    font-weight: 700;
}

.make-order-service-suggest .list-group-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 5px 8px;
    font-size: 0.84rem;
    cursor: pointer;
}

.make-order-table-wrap {
    border-right: 1px solid #d5dce5;
    border-left: 1px solid #d5dce5;
}

.make-order-sample-table,
.make-order-service-table {
    table-layout: fixed;
}

.make-order-sample-table th,
.make-order-sample-table td,
.make-order-service-table th,
.make-order-service-table td {
    padding: 3px 5px;
    border-color: #d5dce5;
    color: #001b33;
    font-size: 0.84rem;
    vertical-align: middle;
}

.make-order-sample-table thead th,
.make-order-service-table thead th {
    background: #e3f1ff;
    color: #001b33;
    font-weight: 800;
}

.make-order-sample-table th:nth-child(1),
.make-order-sample-table td:nth-child(1) {
    width: 64px;
}

.make-order-sample-table th:nth-child(3),
.make-order-sample-table td:nth-child(3) {
    width: 180px;
}

.make-order-sample-table th:nth-child(7),
.make-order-sample-table td:nth-child(7) {
    width: 114px;
}

.make-order-sample-table th:nth-child(8),
.make-order-sample-table td:nth-child(8) {
    width: 62px;
}

.make-order-trash {
    width: 34px;
    min-height: 28px;
    border-radius: 3px;
}

.make-order-sample-head-actions {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    margin-left: auto;
}

.make-order-sample-head-actions .form-control {
    width: 126px;
}

.make-order-sample-head-actions .btn {
    display: inline-flex;
    height: 28px;
    align-items: center;
    gap: 5px;
    padding: 3px 9px;
    border-radius: 2px;
    font-size: 0.82rem;
    font-weight: 700;
}

.make-order-service-table th:nth-child(1),
.make-order-service-table td:nth-child(1) {
    width: 100px;
}

.make-order-service-table th:nth-child(2),
.make-order-service-table td:nth-child(2) {
    width: 86px;
}

.make-order-service-table th:nth-child(4),
.make-order-service-table td:nth-child(4) {
    width: 32%;
}

.make-order-service-table th:nth-child(5),
.make-order-service-table td:nth-child(5) {
    width: 128px;
}

.make-order-service-table th:nth-child(6),
.make-order-service-table td:nth-child(6) {
    width: 156px;
}

.make-order-sample-group {
    background: #cceff3;
    cursor: pointer;
}

.make-order-sample-group--active {
    background: #bde8ef;
}

.make-order-sample-group b {
    margin-left: 8px;
}

.make-order-price-input {
    width: 120px;
    margin: 0 auto;
}

.make-order-total-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 8px;
    padding: 10px;
    border: 1px solid #d5dce5;
    background: #f8f9fa;
}

.make-order-total-fields {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 18px;
}

.make-order-total-fields > div {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.make-order-total-fields b {
    color: #001b33;
    font-size: 0.86rem;
    white-space: nowrap;
}

.make-order-total-fields .form-control {
    width: 120px;
}

.make-order-total-fields .make-order-discount-note .form-control {
    width: min(360px, 34vw);
}

.make-order-actions {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 8px;
}

.make-order-actions .btn {
    display: inline-flex;
    min-height: 32px;
    align-items: center;
    gap: 6px;
    border-radius: 3px;
    font-size: 0.86rem;
    font-weight: 700;
}

@media (max-width: 1399.98px) {
    .make-order-system-strip,
    .make-order-legacy-layout {
        grid-template-columns: 360px minmax(0, 1fr);
    }
}

@media (max-width: 991.98px) {
    .make-order-system-strip,
    .make-order-legacy-layout {
        grid-template-columns: 1fr;
    }

    .make-order-system-strip__left,
    .make-order-system-strip__right {
        min-height: 42px;
    }

    .make-order-product-list {
        max-height: 260px;
    }

    .make-order-customer-suggest {
        min-width: min(620px, 90vw);
    }

    .make-order-total-bar {
        align-items: stretch;
        flex-direction: column;
    }
}

/* Make order legacy page aligned with shared controls */
.make-order-legacy-page {
    padding-bottom: 14px;
    background: #f3f6fa;
}

.make-order-system-strip,
.make-order-legacy-layout {
    grid-template-columns: 312px minmax(0, 1fr);
    gap: 10px;
}

.make-order-system-strip {
    gap: 0;
    margin-bottom: 10px;
}

.make-order-legacy-layout {
    padding: 0 10px;
}

.make-order-legacy-sidebar,
.make-order-control-panel {
    overflow: hidden;
    border: 1px solid #d8e2ef;
    border-radius: 6px;
    background: #fff;
    box-shadow: 0 2px 6px rgb(15 23 42 / 4%);
}

.make-order-control-panel.make-order-customer-panel {
    position: relative;
    z-index: 10;
    overflow: visible;
}

.make-order-control-panel.make-order-service-panel {
    position: relative;
    z-index: 9;
    overflow: visible;
}

.make-order-service-search-row {
    display: grid;
    grid-template-columns: 170px minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    padding: 7px;
    border-bottom: 1px solid #d8e2ef;
    background: #fff;
}

.make-order-service-search-row > label {
    margin: 0;
    color: #344054;
    font-size: 12px;
    font-weight: 700;
}

.make-order-service-search-row .make-order-service-suggest {
    top: calc(100% + 3px);
    z-index: 1300;
    overflow-x: hidden;
    border: 1px solid #b8c5d4;
    border-radius: 4px;
    background: #fff;
    box-shadow: 0 12px 28px rgb(15 23 42 / 22%);
}

.make-order-customer-panel .make-order-panel-head {
    border-radius: 6px 6px 0 0;
}

.make-order-customer-panel .make-order-info-panel {
    border-radius: 0 0 6px 6px;
}

.make-order-customer-panel .make-order-customer-suggest {
    top: calc(100% + 3px);
    z-index: 1200;
    overflow-x: hidden;
    border: 1px solid #b8c5d4;
    border-radius: 4px;
    background: #fff;
    box-shadow: 0 12px 28px rgb(15 23 42 / 22%);
}

.make-order-customer-panel .make-order-customer-suggest .list-group-item {
    cursor: pointer;
}

.make-order-service-suggest__main {
    display: flex;
    min-width: 0;
    flex: 1 1 auto;
    align-items: center;
    gap: 12px;
    white-space: nowrap;
}

.make-order-service-suggest__name {
    max-width: 42%;
    flex: 0 1 auto;
    color: #1f3347;
    font-weight: 600;
    white-space: nowrap;
}

.make-order-service-suggest__meta {
    display: flex;
    min-width: 0;
    flex: 1 1 auto;
    flex-wrap: nowrap;
    gap: 4px 12px;
    overflow: hidden;
    color: #637487;
    font-size: 0.76rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.make-order-service-suggest__water {
    flex: 0 0 auto;
    color: #087789;
    font-weight: 700;
}

.make-order-service-suggest > .list-group-item > strong {
    flex: 0 0 auto;
    white-space: nowrap;
}

.make-order-service-suggest .list-group-item.active {
    z-index: 1;
    border-color: #79cbd8;
    background: #dff5f8;
    color: #12364a;
}

.make-order-service-suggest .list-group-item.active span,
.make-order-service-suggest .list-group-item.active strong {
    color: inherit;
}

.make-order-quote-suggest .list-group-item.active {
    z-index: 1;
    border-color: #79cbd8;
    background: #dff5f8;
    color: #12364a;
}

.make-order-quote-suggest .list-group-item.active > * {
    color: inherit;
}

.make-order-customer-panel .make-order-customer-suggest .list-group-item.active {
    z-index: 1;
    border-color: #9bd9e4;
    background: #dff5f8;
    color: #12364a;
}

.make-order-customer-panel .make-order-customer-suggest .list-group-item.active span,
.make-order-customer-panel .make-order-customer-suggest .list-group-item.active strong {
    color: inherit;
}

.make-order-customer-input .theme-input,
.make-order-quote-input .theme-input {
    padding-right: 34px;
}

.make-order-customer-input .theme-input[readonly],
.make-order-quote-input .theme-input[readonly] {
    background-color: #fff;
    cursor: default;
}

.make-order-quote-spinner {
    position: absolute;
    z-index: 2;
    top: 50%;
    right: 9px;
    width: 14px;
    height: 14px;
    transform: translateY(-50%);
    color: #078aa2;
}

@media (max-width: 767.98px) {
    .make-order-quote-suggest .list-group-item {
        grid-template-columns: 105px minmax(130px, 1fr);
    }

    .make-order-quote-suggest .list-group-item > small {
        grid-column: 1 / -1;
        text-align: left;
    }
}

.make-order-customer-clear {
    position: absolute;
    z-index: 2;
    top: 50%;
    right: 4px;
    display: inline-flex;
    width: 24px;
    height: 24px;
    align-items: center;
    justify-content: center;
    padding: 0;
    transform: translateY(-50%);
    border: 0;
    border-radius: 4px;
    background: transparent;
    color: #64748b;
    font-size: 12px;
}

.make-order-customer-clear:hover,
.make-order-customer-clear:focus-visible {
    background: #fee2e2;
    color: #dc2626;
    outline: 0;
}

.make-order-legacy-sidebar {
    position: sticky;
    top: 8px;
}

.make-order-panel-head {
    display: flex;
    min-height: 50px;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 10px;
    border-bottom: 1px solid #d8e2ef;
    background: #f8fafc;
}

.make-order-panel-head__title {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 9px;
}

.make-order-panel-head__title > div {
    display: flex;
    min-width: 0;
    flex-direction: column;
}

.make-order-panel-head__title strong {
    overflow: hidden;
    color: #172033;
    font-size: 14px;
    font-weight: 800;
    line-height: 1.3;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.make-order-panel-head__title small {
    overflow: hidden;
    color: #64748b;
    font-size: 11px;
    line-height: 1.3;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.make-order-panel-head__icon {
    display: inline-flex;
    width: 30px;
    height: 30px;
    flex: 0 0 30px;
    align-items: center;
    justify-content: center;
    border-radius: 7px;
    background: #e5f7fa;
    color: #047c91;
}

.make-order-panel-count {
    display: inline-flex;
    min-width: 28px;
    height: 24px;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    padding: 0 8px;
    border-radius: 999px;
    background: #e8eef6;
    color: #344054;
    font-size: 12px;
    font-weight: 800;
}

.make-order-sidebar-search {
    padding: 10px;
    border-bottom-color: #e2e8f0;
    background: #fff;
}

.make-order-legacy-page .theme-input {
    min-height: 32px;
    height: 32px;
    padding: 4px 8px;
    border-color: #9fabb8;
    border-radius: 4px;
    background-color: #fff;
    color: #172033;
    font-size: 13px;
    font-weight: 500;
    line-height: 22px;
}

.make-order-legacy-page .theme-input:focus {
    border-color: #0790ab;
    box-shadow: 0 0 0 2px rgb(7 144 171 / 14%);
}

.make-order-info-panel {
    padding: 12px;
    border: 0;
    background: #fff;
}

.make-order-info-panel .col-form-label {
    color: #344054;
    font-size: 12px;
    font-weight: 700;
    line-height: 32px;
}

.make-order-product-list {
    max-height: calc(100vh - 225px);
}

.make-order-product-item {
    min-height: 38px;
    padding: 8px 10px;
    border-bottom-color: #e6edf5;
    background: #fff;
    color: #273445;
    font-size: 13px;
    font-weight: 600;
}

.make-order-product-item:hover {
    background: #eaf6ff;
    color: #075f9a;
}

.make-order-table-wrap {
    border: 0;
}

.make-order-sample-table,
.make-order-service-table {
    margin: 0;
}

.make-order-sample-table {
    min-width: 1050px;
}

.make-order-service-table {
    min-width: 820px;
}

.make-order-sample-table th,
.make-order-sample-table td,
.make-order-service-table th,
.make-order-service-table td {
    padding: 5px 7px;
    border-color: #d8e2ef;
    color: #273445;
    font-size: 12px;
}

.make-order-sample-table thead th,
.make-order-service-table thead th {
    height: 34px;
    background: #e7f2fc;
    color: #243448;
    font-weight: 800;
}

.make-order-sample-group {
    background: #edf9fb;
}

.make-order-sample-group:hover,
.make-order-sample-group--active {
    background: #d9f2f6;
}

.make-order-sample-head-actions .theme-input {
    width: 145px;
}

.make-order-sample-head-actions .button-theme,
.make-order-actions .button-theme {
    min-height: 32px;
    height: 32px;
}

.make-order-sample-head-actions .button-theme {
    white-space: nowrap;
}

.make-order-trash {
    width: 32px;
    height: 32px;
    min-height: 32px;
    padding: 0;
}

.make-order-total-bar {
    margin: 0;
    padding: 12px;
    border: 0;
    background: #fff;
}

.make-order-total-fields {
    gap: 12px 18px;
}

.make-order-total-fields > div {
    padding: 4px 0;
}

.make-order-total-fields b {
    color: #344054;
    font-size: 12px;
}

.make-order-total-fields .theme-input {
    width: 132px;
}

.make-order-total-fields .make-order-discount-note .theme-input {
    width: min(360px, 32vw);
}

.make-order-payment-panel {
    margin-bottom: 0;
}

@media (max-width: 1399.98px) {
    .make-order-system-strip,
    .make-order-legacy-layout {
        grid-template-columns: 280px minmax(0, 1fr);
    }
}

@media (max-width: 991.98px) {
    .make-order-system-strip,
    .make-order-legacy-layout {
        grid-template-columns: 1fr;
    }

    .make-order-legacy-sidebar {
        position: static;
    }

    .make-order-product-list {
        max-height: 240px;
    }

    .make-order-info-panel .row > [class*="col-lg-"] + [class*="col-lg-"] {
        margin-top: 8px;
    }
}

@media (max-width: 575.98px) {
    .make-order-legacy-layout {
        padding: 0 6px;
    }

    .make-order-system-strip__right {
        flex-wrap: wrap;
        padding-top: 6px;
        padding-bottom: 6px;
    }

    .make-order-panel-head,
    .make-order-total-bar {
        align-items: stretch;
        flex-direction: column;
    }

    .make-order-total-fields,
    .make-order-actions {
        width: 100%;
    }

    .make-order-sample-head-actions {
        width: 100%;
        margin-left: 0;
    }

    .make-order-sample-head-actions .theme-input {
        width: auto;
        min-width: 0;
        flex: 1 1 auto;
    }

    .make-order-total-fields > div,
    .make-order-actions .button-theme {
        width: 100%;
    }

    .make-order-total-fields .theme-input,
    .make-order-total-fields .make-order-discount-note .theme-input {
        width: 100%;
    }
}

/* Make order new layout */
.make-order-new-page {
    min-height: calc(100vh - 74px);
    padding: 0 0 12px;
    background: #eef3f7;
    color: #001b33;
}

.make-order-new-strip {
    margin-bottom: 10px;
}

.make-order-new-shell {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(300px, 340px);
    gap: 10px;
    align-items: start;
    padding: 0 10px;
}

.make-order-new-workspace {
    display: grid;
    min-width: 0;
    gap: 10px;
}

.make-order-new-panel {
    min-width: 0;
    overflow: visible;
    border: 1px solid #d4dee8;
    border-radius: 6px;
    background: #ffffff;
}

.make-order-new-panel-head {
    display: flex;
    min-height: 44px;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px;
    border-bottom: 1px solid #e1e9f0;
    background: #f9fbfd;
}

.make-order-new-panel-head > div:first-child {
    display: inline-flex;
    min-width: 0;
    align-items: center;
    gap: 8px;
}

.make-order-new-panel-head > div:first-child > span:first-child {
    display: inline-flex;
    width: 26px;
    height: 26px;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #015e70;
    color: #ffffff;
    font-size: 0.78rem;
    font-weight: 800;
}

.make-order-new-panel-head strong,
.make-order-new-panel-head small {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.make-order-new-panel-head strong {
    color: #183550;
    font-size: 0.96rem;
    font-weight: 800;
}

.make-order-new-panel-head small {
    color: #64788d;
    font-size: 0.8rem;
    font-weight: 700;
}

.make-order-new-head-actions {
    display: flex;
    min-width: 0;
    flex: 0 1 auto;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
}

.make-order-new-sample-head-actions {
    flex: 1 1 auto;
}

.make-order-new-info-grid {
    display: grid;
    grid-template-columns: minmax(230px, 1.35fr) repeat(3, minmax(160px, 1fr));
    gap: 10px;
    padding: 12px;
}

.make-order-new-field {
    display: grid;
    min-width: 0;
    gap: 5px;
    margin: 0;
}

.make-order-new-field--wide {
    grid-column: span 2;
}

.make-order-new-field > span,
.make-order-new-money-box label > span,
.make-order-new-summary-list span,
.make-order-new-pay-amount span {
    min-width: 0;
    overflow: hidden;
    color: #61758a;
    font-size: 0.74rem;
    font-weight: 800;
    text-overflow: ellipsis;
    text-transform: uppercase;
    white-space: nowrap;
}

.make-order-new-field .form-control,
.make-order-new-field select.form-control,
.make-order-new-quantity-box .form-control,
.make-order-new-sample-table .form-control,
.make-order-new-service-table .form-control,
.make-order-new-money-box .form-control {
    min-height: 32px;
    border-color: #cbd7e3;
    border-radius: 4px;
    color: #001b33;
    font-size: 0.86rem;
}

.make-order-new-customer-suggest {
    min-width: min(720px, 84vw);
}

.make-order-new-quantity-box {
    display: grid;
    min-width: 0;
    grid-template-columns: minmax(86px, 110px) auto;
    align-items: center;
    gap: 6px;
}

.make-order-new-quantity-box .btn,
.make-order-new-summary-actions .btn {
    display: inline-flex;
    min-height: 34px;
    align-items: center;
    justify-content: center;
    gap: 6px;
    border-radius: 4px;
    font-size: 0.86rem;
    font-weight: 800;
}

.make-order-new-table-wrap {
    border-top: 1px solid #e1e9f0;
}

.make-order-new-sample-table,
.make-order-new-service-table {
    min-width: 980px;
    table-layout: fixed;
}

.make-order-new-sample-table th,
.make-order-new-sample-table td,
.make-order-new-service-table th,
.make-order-new-service-table td {
    padding: 5px 6px;
    border-color: #d8e2eb;
    color: #001b33;
    font-size: 0.84rem;
    vertical-align: middle;
}

.make-order-new-sample-table thead th,
.make-order-new-service-table thead th {
    background: #e8f2f8;
    color: #183550;
    font-weight: 800;
}

.make-order-new-sample-table th:nth-child(1),
.make-order-new-sample-table td:nth-child(1) {
    width: 46px;
}

.make-order-new-sample-table th:nth-child(2),
.make-order-new-sample-table td:nth-child(2) {
    width: 50px;
}

.make-order-new-sample-table th:nth-child(4),
.make-order-new-sample-table td:nth-child(4) {
    width: 170px;
}

.make-order-new-sample-table th:nth-child(8),
.make-order-new-sample-table td:nth-child(8) {
    width: 118px;
}

.make-order-new-sample-table th:nth-child(9),
.make-order-new-sample-table td:nth-child(9) {
    width: 56px;
}

.make-order-new-sample-row--selected {
    background: #f3fbfb;
}

.make-order-new-code-cell {
    color: #31556f;
    font-weight: 800;
}

.make-order-new-side-service {
    display: grid;
    gap: 10px;
    padding: 12px;
}

.make-order-new-product-list {
    display: grid;
    max-height: 184px;
    overflow: auto;
    margin-top: 8px;
    border: 1px solid #d8e2eb;
    border-radius: 5px;
}

.make-order-new-product-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    min-height: 34px;
    align-items: center;
    padding: 6px 8px;
    border: 0;
    border-bottom: 1px solid #e6edf3;
    background: #ffffff;
    color: #001b33;
    text-align: left;
}

.make-order-new-product-item:hover {
    background: #f1f8fb;
}

.make-order-new-product-item span,
.make-order-new-product-item strong {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.make-order-new-product-item span {
    font-size: 0.84rem;
    font-weight: 700;
}

.make-order-new-product-item strong {
    color: #8a5d11;
    font-size: 0.8rem;
}

.make-order-new-service-panel .make-order-new-product-list {
    max-height: 340px;
}

.make-order-new-service-table th:nth-child(1),
.make-order-new-service-table td:nth-child(1) {
    width: 58px;
}

.make-order-new-service-table th:nth-child(3),
.make-order-new-service-table td:nth-child(3) {
    width: 30%;
}

.make-order-new-service-table th:nth-child(4),
.make-order-new-service-table td:nth-child(4) {
    width: 120px;
}

.make-order-new-service-table th:nth-child(5),
.make-order-new-service-table td:nth-child(5) {
    width: 152px;
}

.make-order-new-sample-group {
    background: #d9f0f2;
    cursor: pointer;
}

.make-order-new-sample-group--active {
    background: #c7e9ee;
}

.make-order-new-sample-group td:last-child,
.make-order-new-sample-group td[colspan] {
    overflow: hidden;
}

.make-order-new-sample-group b,
.make-order-new-sample-group span {
    display: inline-block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    vertical-align: middle;
    white-space: nowrap;
}

.make-order-new-sample-group b {
    max-width: 58%;
    margin-left: 8px;
}

.make-order-new-sample-group span {
    max-width: 30%;
    margin-left: 10px;
    color: #46667d;
    font-size: 0.78rem;
    font-weight: 800;
}

.make-order-new-summary {
    position: sticky;
    top: 10px;
    display: grid;
    gap: 10px;
    min-width: 0;
}

.make-order-new-summary-panel {
    overflow: hidden;
}

.make-order-new-summary-list,
.make-order-new-money-box,
.make-order-new-summary-actions {
    display: grid;
    gap: 10px;
    padding: 12px;
}

.make-order-new-summary-list {
    padding-bottom: 0;
}

.make-order-new-summary-list div,
.make-order-new-money-box label,
.make-order-new-pay-amount {
    display: grid;
    min-width: 0;
    gap: 6px;
    padding: 9px;
    border: 1px solid #dce6ef;
    border-radius: 5px;
    background: #f9fbfd;
}

.make-order-new-summary-list strong {
    min-width: 0;
    overflow: hidden;
    color: #183550;
    font-size: 0.92rem;
    font-weight: 800;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.make-order-new-money-box label div {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 6px;
    align-items: center;
}

.make-order-new-money-box label b {
    color: #61758a;
}

.make-order-new-money-note {
    grid-column: 1 / -1;
}

.make-order-new-pay-amount {
    border-color: #f0d7a6;
    background: #fffaf0;
}

.make-order-new-pay-amount strong {
    color: #9a6413;
    font-size: 1.35rem;
    font-weight: 900;
}

.make-order-new-summary-actions {
    border-top: 1px solid #e1e9f0;
}

@media (max-width: 1399.98px) {
    .make-order-new-info-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 1199.98px) {
    .make-order-new-shell {
        grid-template-columns: 1fr;
    }

    .make-order-new-summary {
        position: static;
    }
}

@media (max-width: 991.98px) {
    .make-order-new-info-grid {
        grid-template-columns: 1fr;
    }

    .make-order-new-field--wide {
        grid-column: auto;
    }
}

@media (max-width: 575.98px) {
    .make-order-new-shell {
        padding: 0 6px;
    }

    .make-order-new-panel-head {
        align-items: flex-start;
        flex-direction: column;
    }

    .make-order-new-panel-head small {
        white-space: normal;
    }

    .make-order-new-head-actions {
        width: 100%;
        justify-content: space-between;
    }

    .make-order-new-sample-head-actions {
        flex-wrap: wrap;
    }

    .make-order-new-sample-head-actions small {
        flex: 1 1 100%;
    }

    .make-order-new-sample-head-actions .make-order-new-quantity-box {
        width: 100%;
        grid-template-columns: minmax(0, 1fr) auto;
    }
}
