.expense-form-page {
    --ef-brand: #5548e8;
    --ef-text: #263244;
    --ef-muted: #7c8798;
    --ef-border: #e3e8ef;
    color: var(--ef-text);
    padding-bottom: 28px;
}

.expense-form-heading > span {
    align-items: center;
    background: #eff1ff;
    border-radius: 10px;
    color: var(--ef-brand);
    display: inline-flex;
    flex: 0 0 42px;
    font-size: 1.25rem;
    height: 42px;
    justify-content: center;
}

.expense-form-heading h1 {
    color: #1d2737;
    font-size: 1.45rem;
    font-weight: 800;
    letter-spacing: -.025em;
}

.expense-form-heading p { font-size: .82rem; }
.expense-form .btn-primary { --bs-btn-bg: var(--ef-brand); --bs-btn-border-color: var(--ef-brand); --bs-btn-hover-bg: #4437d3; --bs-btn-hover-border-color: #4437d3; }

.expense-form-card,
.expense-side-card {
    border: 1px solid var(--ef-border);
    border-radius: 12px;
    overflow: hidden;
}

.expense-form-card > .card-header,
.expense-side-card > .card-header {
    align-items: center;
    background: #fbfcfd;
    border-bottom: 1px solid #edf0f4;
    display: flex;
    gap: 11px;
    min-height: 52px;
    padding: 12px 18px;
}

.expense-form-card > .card-header h2,
.expense-side-card > .card-header h2 {
    color: #344053;
    font-size: .86rem;
    font-weight: 800;
    margin: 0;
}

.expense-form-card > .card-header p {
    color: var(--ef-muted);
    font-size: .72rem;
    margin: 2px 0 0;
}

.expense-form-card > .card-body { padding: 20px; }

.expense-form-card__icon {
    align-items: center;
    border-radius: 8px;
    display: inline-flex;
    flex: 0 0 28px;
    font-size: .9rem;
    height: 28px;
    justify-content: center;
}

.expense-form-card__icon.is-blue { background: #e9edff; color: #5a50e7; }
.expense-form-card__icon.is-green { background: #ddfaec; color: #099b6b; }
.expense-form-card__icon.is-violet { background: #f0e8ff; color: #8450e9; }
.expense-form-card__icon.is-amber { background: #fff2cb; color: #e29200; }

.expense-form .form-label {
    color: #596576;
    font-size: .72rem;
    font-weight: 700;
    margin-bottom: 6px;
}

.expense-form em { color: #ef4c57; font-style: normal; }
.expense-form .form-control,
.expense-form .form-select,
.expense-form .input-group-text {
    border-color: #dfe4eb;
    border-radius: 8px;
    font-size: .82rem;
    min-height: 40px;
}

.expense-form .input-group > :not(:first-child) { border-bottom-left-radius: 0; border-top-left-radius: 0; }
.expense-form .input-group > :not(:last-child) { border-bottom-right-radius: 0; border-top-right-radius: 0; }
.expense-form .input-group-text { background: #fafbfc; color: #8691a0; font-size: .7rem; }
.expense-form .form-control[readonly] { background: #f7f8fa; color: #697587; }
.expense-form textarea.form-control { min-height: 82px; resize: vertical; }
.expense-new-supplier { align-items: center; display: inline-flex; font-size: .75rem; font-weight: 700; white-space: nowrap; }

.expense-form-info {
    background: #edf5ff;
    border: 1px solid #d8e8ff;
    border-radius: 8px;
    color: #3975d3;
    font-size: .72rem;
    padding: 10px 12px;
}

.expense-dropzone {
    align-items: center;
    background: #fbfcfd;
    border: 2px dashed #dfe4eb;
    border-radius: 12px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 225px;
    padding: 28px;
    text-align: center;
    transition: border-color .15s ease, background-color .15s ease;
}

.expense-dropzone:hover,
.expense-dropzone.is-dragging { background: #f5f4ff; border-color: #958cef; }
.expense-dropzone.has-file { background: #f0fbf6; border-color: #82dcb7; }
.expense-dropzone.is-invalid { border-color: #dc3545; }
.expense-dropzone__icon { align-items: center; background: #fff; border: 1px solid #e3e7ed; border-radius: 10px; box-shadow: 0 3px 8px rgba(24, 32, 48, .06); color: #8e99a8; display: inline-flex; font-size: 1.25rem; height: 46px; justify-content: center; margin-bottom: 12px; width: 46px; }
.expense-dropzone strong { color: #4b5668; font-size: .82rem; }
.expense-dropzone small { color: #a0a9b6; font-size: .7rem; margin: 4px 0 12px; }
.expense-dropzone .btn { font-size: .75rem; margin-bottom: 2px; }
.expense-form-help { color: #9aa4b2; display: flex; font-size: .68rem; gap: 6px; margin: 12px 0 0; }

.expense-allocation-table {
    border: 1px solid var(--ef-border);
    border-radius: 10px;
}

.expense-allocation-table table { min-width: 760px; }
.expense-allocation-table thead th { background: #fafbfc; color: #7b8696; font-size: .65rem; font-weight: 800; padding: 10px 12px; text-transform: uppercase; white-space: nowrap; }
.expense-allocation-table td { border-color: #edf0f4; color: #556174; font-size: .78rem; padding: 10px 12px; }
.expense-allocation-table .ts-wrapper { min-width: 280px; }
.expense-allocation-table .ts-wrapper.single .ts-control {
    align-items: center;
    border-color: #dfe4eb;
    border-radius: 8px;
    box-shadow: none;
    display: flex;
    font-size: .78rem;
    min-height: 40px;
    padding: 8px 34px 8px 12px;
}
.expense-allocation-table .ts-wrapper.focus .ts-control { border-color: #958cef; box-shadow: 0 0 0 .2rem rgba(85, 72, 232, .12); }
.expense-allocation-table .ts-dropdown { border-color: #dfe4eb; border-radius: 8px; font-size: .78rem; overflow: hidden; }
.expense-allocation-table .ts-dropdown .option { padding: 9px 12px; }
.expense-allocation-table .ts-dropdown .active { background: #f1f0ff; color: #4437d3; }
.expense-allocation-table th:first-child { width: 55%; }
.expense-allocation-table th:nth-child(2) { width: 140px; }
.expense-allocation-table th:nth-child(3), .expense-allocation-table th:nth-child(4) { width: 135px; }

.expense-allocation-summary {
    background: #fafbfc;
    border: 1px solid var(--ef-border);
    border-radius: 10px;
    color: #546174;
    font-size: .72rem;
    padding: 14px;
}

.expense-allocation-summary .progress { background: #e7ebef; height: 7px; }
.expense-allocation-summary .progress-bar { background: #0dbf83; transition: width .2s ease; }
.expense-allocation-summary small, .expense-allocation-summary strong { display: block; }
.expense-allocation-summary small { color: #8b96a5; margin-bottom: 3px; }
.expense-allocation-summary strong { color: #394659; font-size: .8rem; }
.expense-progress-badge { background: #e8fbf3; border: 1px solid #a4e9cd; border-radius: 999px; color: #078d63; font-weight: 700; padding: 3px 8px; }

.expense-form-aside { position: sticky; top: 90px; }
.expense-side-card > .card-header { min-height: 50px; }
.expense-side-card > .card-header > i { color: #8a95a4; }
.expense-side-card > .card-body { padding: 16px; }
.expense-summary-list { display: grid; gap: 12px; margin: 0; }
.expense-summary-list > div { align-items: center; display: flex; justify-content: space-between; gap: 12px; }
.expense-summary-list dt { color: #818c9c; font-size: .7rem; font-weight: 500; }
.expense-summary-list dd { color: #4a5668; font-size: .72rem; font-weight: 700; margin: 0; text-align: right; }
.expense-summary-list .is-total { background: #e9faf3; border: 1px solid #b6ead5; border-radius: 8px; color: #087f5b; margin-top: 2px; padding: 10px; }
.expense-summary-list .is-total dt, .expense-summary-list .is-total dd { color: #087f5b; font-weight: 800; }
.expense-status-dot { background: #f1f2f4; border-radius: 999px; color: #667284; padding: 4px 8px; }
.expense-status-dot::before { background: currentColor; border-radius: 50%; content: ''; display: inline-block; height: 5px; margin-right: 5px; vertical-align: middle; width: 5px; }

.expense-impact-item {
    background: #fafbfc;
    border: 1px solid #edf0f4;
    border-radius: 8px;
    display: grid;
    grid-template-columns: 1fr auto;
    margin-bottom: 8px;
    padding: 10px 10px 10px 22px;
    position: relative;
}

.expense-impact-item::before { background: var(--impact-color); border-radius: 50%; content: ''; height: 6px; left: 10px; position: absolute; top: 14px; width: 6px; }
.expense-impact-item strong { color: #4c586a; font-size: .68rem; }
.expense-impact-item small { color: #909aa8; font-size: .65rem; grid-column: 1; }
.expense-impact-item b { align-self: center; color: #ef4d56; font-size: .7rem; grid-column: 2; grid-row: 1 / span 2; }
.expense-rules p { color: #6f7b8d; display: flex; font-size: .68rem; gap: 8px; line-height: 1.45; margin-bottom: 13px; }
.expense-rules p:last-child { margin-bottom: 0; }

.expense-form-footer {
    background: #fff;
    border: 1px solid var(--ef-border);
    border-radius: 10px;
    box-shadow: 0 4px 14px rgba(29, 39, 55, .06);
    margin-top: 8px;
    padding: 14px 18px;
}

.expense-form-footer p { color: #8b96a5; font-size: .68rem; }
.expense-form-footer .btn { font-size: .78rem; font-weight: 700; min-height: 40px; padding-inline: 15px; }

@media (max-width: 1199.98px) {
    .expense-form-aside { position: static; }
}

@media (max-width: 575.98px) {
    .expense-form-heading h1 { font-size: 1.2rem; }
    .expense-form-card > .card-body { padding: 15px; }
    .expense-new-supplier { font-size: 0; padding-inline: 12px; }
    .expense-new-supplier i { font-size: 1rem; }
    .expense-dropzone { min-height: 190px; padding: 20px 12px; }
    .expense-form-footer .btn { flex: 1 1 100%; justify-content: center; }
}
