@font-face {
    font-family: "IBM Plex Sans Arabic";
    src: url("fonts/IPSArabic/IBMPlexSansArabic-Regular.ttf") format("truetype");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "IBM Plex Sans Arabic";
    src: url("fonts/IPSArabic/IBMPlexSansArabic-Medium.ttf") format("truetype");
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "IBM Plex Sans Arabic";
    src: url("fonts/IPSArabic/IBMPlexSansArabic-SemiBold.ttf") format("truetype");
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "IBM Plex Sans Arabic";
    src: url("fonts/IPSArabic/IBMPlexSansArabic-Bold.ttf") format("truetype");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

:root {
    --bg: #f5f7fa;
    --surface: #ffffff;
    --surface-soft: #f8fafc;
    --line: #d9e0e8;
    --line-strong: #c8d1dc;
    --text: #182230;
    --muted: #667085;
    --accent: #0f766e;
    --accent-strong: #0b5f59;
    --accent-soft: #e8f6f3;
    --accent-2: #b45309;
    --info: #0369a1;
    --info-soft: #edf8ff;
    --warning: #b45309;
    --warning-soft: #fff7ed;
    --success: #0f766e;
    --success-soft: #e8f6f3;
    --danger: #be123c;
    --danger-soft: #fff1f2;
    --radius-sm: 6px;
    --radius-md: 8px;
    --space-xs: 6px;
    --space-sm: 10px;
    --space-md: 16px;
    --shadow-sm: 0 2px 10px rgba(15, 23, 42, 0.06);
    --app-header-height: 88px;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: "IBM Plex Sans Arabic", Tahoma, Arial, sans-serif;
    line-height: 1.6;
}

a {
    color: inherit;
}

.app-shell {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    grid-template-rows: auto minmax(0, 1fr);
    min-height: 100vh;
}

.sidebar {
    position: sticky;
    top: 0;
    grid-row: 2;
    height: calc(100vh - var(--app-header-height));
    overflow-y: auto;
    padding: 20px 18px;
    background: var(--surface);
    border-left: 1px solid var(--line);
}

.sidebar-mobile-head {
    display: none;
}

.side-nav,
.nav-group {
    display: grid;
    gap: 8px;
}

.side-nav {
    gap: 18px;
}

.nav-group span {
    color: var(--muted);
    font-size: 12px;
    font-weight: 600;
}

.nav-group a {
    min-height: 38px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 12px;
    border-radius: 6px;
    color: var(--text);
    text-decoration: none;
}

.nav-group a:hover {
    background: #eef2f6;
}

.nav-group a.is-active {
    background: #e6f4f1;
    color: var(--accent);
    font-weight: 600;
}

.nav-icon {
    width: 18px;
    height: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 18px;
}

.nav-icon svg {
    width: 18px;
    height: 18px;
    display: block;
}

.main-area {
    grid-row: 2;
    min-width: 0;
}

.app-header {
    display: flex;
    grid-column: 1 / -1;
    grid-row: 1;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    min-height: var(--app-header-height);
    padding: 14px 28px;
    background: var(--surface);
    border-bottom: 1px solid var(--line);
}

.app-header h1 {
    font-size: 22px;
    margin: 0;
}

.app-header p {
    margin: 2px 0 0;
    color: var(--muted);
    font-size: 13px;
}

.userbox {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--muted);
    font-size: 14px;
}

.button,
.link,
.small-button {
    min-height: 36px;
    display: inline-flex;
    align-items: center;
    padding: 0 12px;
    border-radius: var(--radius-sm);
    text-decoration: none;
    border: 1px solid var(--line);
    background: var(--surface);
    font: inherit;
    line-height: 1.2;
    font-weight: 500;
    transition: background-color 0.16s ease, border-color 0.16s ease, color 0.16s ease, box-shadow 0.16s ease;
}

.button {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

.button:hover {
    background: var(--accent-strong);
    border-color: var(--accent-strong);
}

.button.secondary {
    background: #1d4ed8;
    border-color: #1d4ed8;
    color: #fff;
}

.button.secondary:hover {
    background: #1e40af;
    border-color: #1e40af;
}

.link:hover,
.small-button:hover {
    background: var(--surface-soft);
    border-color: var(--line-strong);
}

.small-button {
    min-height: 32px;
    cursor: pointer;
}

.small-button.danger {
    color: #991b1b;
    border-color: #f1b8b8;
    background: #fff6f6;
}

.app-home-button,
.global-home-button {
    color: #fff;
    border-color: var(--accent);
    background: var(--accent);
    font-weight: 800;
    box-shadow: 0 10px 22px rgba(37, 99, 235, 0.18);
}

.app-home-button:hover,
.global-home-button:hover {
    color: #fff;
    border-color: var(--accent-strong);
    background: var(--accent-strong);
}

.global-home-button {
    position: fixed;
    top: 16px;
    left: 16px;
    z-index: 80;
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 16px;
    border-radius: var(--radius-sm);
    text-decoration: none;
}

.with-icon {
    gap: 8px;
}

.shell {
    width: min(1180px, calc(100% - 40px));
    margin: 24px auto;
}

.mobile-menu-button,
.mobile-sidebar-close,
.mobile-sidebar-backdrop {
    display: none;
}

.page-head,
.panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}

h1,
h2,
p {
    margin-top: 0;
}

h1 {
    font-size: 28px;
    margin-bottom: 4px;
}

h2 {
    font-size: 18px;
}

.page-head p,
.empty,
.muted {
    color: var(--muted);
}

.tabs-nav {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.tab-link {
    min-height: 36px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0 14px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface);
    text-decoration: none;
    color: var(--text);
}

.tab-counter {
    min-width: 24px;
    height: 24px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: #eef2ff;
    color: #3730a3;
    font-size: 12px;
    line-height: 1;
    padding: 0 6px;
}

.tab-link.active {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.tab-link.active .tab-counter {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
}

.metrics {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 18px;
}

.metric,
.panel {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    padding: 16px;
    box-shadow: var(--shadow-sm);
}

.metric.info {
    border-inline-start: 4px solid var(--info);
    background: var(--info-soft);
}

.metric.warning {
    border-inline-start: 4px solid var(--warning);
    background: var(--warning-soft);
}

.metric.success {
    border-inline-start: 4px solid var(--success);
    background: var(--success-soft);
}

.metric.danger {
    border-inline-start: 4px solid var(--danger);
    background: var(--danger-soft);
}

.alert {
    border-radius: var(--radius-md);
    padding: 12px 14px;
    margin-bottom: 16px;
    border: 1px solid var(--line);
    background: var(--surface);
}

.alert.success {
    color: var(--accent);
    border-color: #a9d8d1;
    background: var(--success-soft);
}

.alert.error {
    color: var(--danger);
    border-color: #f1b8b8;
    background: var(--danger-soft);
}

.form {
    display: grid;
    gap: 14px;
    max-width: 720px;
}

.form.compact {
    max-width: none;
    grid-template-columns: minmax(220px, 1fr) minmax(220px, 1fr) auto;
    align-items: end;
}

.form.filters {
    max-width: none;
    grid-template-columns: 1.4fr 1fr 1.4fr auto auto;
    align-items: end;
}

.form label {
    display: grid;
    gap: 6px;
    color: var(--muted);
    font-size: 13px;
}

input,
select,
textarea {
    width: 100%;
    min-height: 38px;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 8px 10px;
    font: inherit;
    color: var(--text);
    background: #fff;
}

input:focus,
select:focus,
textarea:focus {
    outline: 0;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.12);
}

textarea {
    resize: vertical;
}

.inline-form {
    margin-top: 14px;
}

.actions {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

.actions form {
    display: flex;
    gap: 6px;
    align-items: center;
}

.actions input {
    min-width: 140px;
}

.metric span {
    color: var(--muted);
    font-size: 13px;
}

.metric strong {
    display: block;
    font-size: 28px;
    margin-top: 8px;
}

.payment-metrics {
    margin-bottom: 12px;
}

.payment-guide {
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 12px 14px;
    background: #fff;
    margin-bottom: 14px;
}

.payment-guide p {
    margin: 0;
}

.payment-guide p + p {
    margin-top: 6px;
}

.payments-page {
    display: grid;
    gap: 16px;
}

.payments-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 16px;
    align-items: stretch;
    padding: 18px;
    border: 1px solid #bfd7d2;
    border-radius: 8px;
    background: linear-gradient(135deg, #f0faf8 0%, #ffffff 52%, #f8fafc 100%);
    box-shadow: var(--shadow-sm);
}

.payments-hero-copy {
    display: grid;
    align-content: center;
    gap: 6px;
}

.section-kicker {
    color: var(--accent);
    font-size: 12px;
    font-weight: 800;
}

.payments-hero h2,
.payment-create-card h2,
.payment-rules-card h2,
.payments-section-head h2 {
    margin: 0;
}

.payments-hero p {
    max-width: 760px;
    margin: 0;
    color: var(--muted);
    font-size: 15px;
}

.payments-hero-status {
    display: grid;
    align-content: center;
    gap: 8px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.payments-hero-status span,
.payment-stat-card span,
.fee-amount-grid span,
.payment-history-item span {
    color: var(--muted);
    font-size: 12px;
    font-weight: 700;
}

.payments-hero-status strong {
    font-size: 32px;
    line-height: 1.1;
}

.payment-progress {
    height: 10px;
    overflow: hidden;
    border-radius: 999px;
    background: #e5e7eb;
}

.payment-progress span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--accent), #1d4ed8);
}

.payment-stat-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.payment-stat-card {
    display: grid;
    gap: 8px;
    min-height: 112px;
    padding: 15px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.payment-stat-card strong {
    font-size: 24px;
    line-height: 1.2;
    overflow-wrap: anywhere;
}

.payment-stat-card.total {
    border-inline-start: 4px solid #1d4ed8;
    background: #eff6ff;
}

.payment-stat-card.paid {
    border-inline-start: 4px solid var(--success);
    background: var(--success-soft);
}

.payment-stat-card.remaining {
    border-inline-start: 4px solid var(--warning);
    background: var(--warning-soft);
}

.payment-stat-card.count {
    border-inline-start: 4px solid #7c3aed;
    background: #f5f3ff;
}

.payments-workspace {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 16px;
    align-items: start;
}

.payments-main-panel,
.payments-side-panel {
    min-width: 0;
}

.payments-side-panel {
    display: grid;
    gap: 16px;
    position: sticky;
    top: 88px;
}

.payments-section-head {
    align-items: center;
    margin-bottom: 14px;
}

.payments-section-head > div {
    display: grid;
    gap: 4px;
}

.payments-count-badge {
    min-height: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 10px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #f8fafc;
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
}

.fee-card-list {
    display: grid;
    gap: 12px;
}

.fee-card {
    display: grid;
    gap: 14px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.fee-card-head {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 12px;
}

.fee-card-head h3 {
    margin: 0;
    font-size: 18px;
}

.fee-card-head p {
    margin: 4px 0 0;
    color: var(--muted);
}

.fee-amount-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.fee-amount-grid > div {
    display: grid;
    gap: 4px;
    padding: 10px;
    border: 1px solid #edf0f4;
    border-radius: 8px;
    background: #fbfcfe;
}

.fee-amount-grid strong {
    font-size: 17px;
    overflow-wrap: anywhere;
}

.fee-progress {
    height: 8px;
}

.fee-action-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 12px;
    padding-top: 12px;
    border-top: 1px solid #edf0f4;
}

.fee-action-form {
    display: grid;
    gap: 8px;
    align-content: start;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #f8fafc;
}

.fee-action-form.shamcash {
    background: #eff6ff;
    border-color: #bfdbfe;
}

.fee-action-form strong {
    font-size: 14px;
}

.payment-locked-note,
.empty-state-card {
    padding: 12px;
    border: 1px dashed var(--line-strong);
    border-radius: 8px;
    background: #f8fafc;
    color: var(--muted);
}

.empty-state-card {
    display: grid;
    gap: 4px;
    text-align: center;
}

.empty-state-card strong {
    color: var(--text);
}

.payment-create-card,
.payment-rules-card {
    display: grid;
    gap: 12px;
}

.payment-create-form {
    display: grid;
    gap: 10px;
}

.payment-create-form label {
    display: grid;
    gap: 6px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
}

.payment-create-button {
    justify-content: center;
    min-height: 44px;
    font-weight: 800;
}

.payment-rules-card {
    background: #fff7ed;
    border-color: #fed7aa;
}

.payment-rules-card ol {
    margin: 0;
    padding-inline-start: 22px;
    color: #7c2d12;
}

.payment-rules-card li + li {
    margin-top: 6px;
}

.payment-history-panel {
    display: grid;
    gap: 12px;
}

.payment-history-list {
    display: grid;
    gap: 10px;
}

.payment-history-item {
    display: grid;
    grid-template-columns: 1.4fr 0.8fr 0.8fr 1fr 1fr;
    gap: 12px;
    align-items: center;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.payment-history-item > div {
    display: grid;
    gap: 2px;
    min-width: 0;
}

.payment-history-item strong,
.payment-history-item time {
    overflow-wrap: anywhere;
}

.payment-history-item time {
    color: var(--muted);
    font-size: 13px;
}

.grid.two {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.deadline-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 16px;
    align-items: start;
}

.deadline-metrics {
    margin-bottom: 14px;
}

.deadline-list-panel {
    min-width: 0;
}

.deadline-create-panel {
    position: sticky;
    top: 98px;
}

.deadline-list {
    display: grid;
    gap: 12px;
}

.deadline-item {
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 18px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.06);
    border-inline-start-width: 5px;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.deadline-item:hover {
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12);
    transform: translateY(-1px);
}

.deadline-item-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
}

.deadline-item-head h3 {
    margin: 0 0 6px;
    font-size: 20px;
    line-height: 1.4;
}

.deadline-item-head p {
    display: flex;
    gap: 10px;
    align-items: center;
    margin: 0;
    color: var(--muted);
    font-size: 13px;
}

.deadline-text {
    margin-bottom: 12px;
    color: var(--text);
    line-height: 1.7;
}

.deadline-text-same_day {
    background: #fff8d6;
    border: 1px solid #f3df93;
    border-radius: 6px;
    padding: 10px 12px;
}

.deadline-text-hours {
    background: #eafaf6;
    border: 1px solid #b7e9db;
    border-radius: 6px;
    padding: 10px 12px;
}

.deadline-text-days {
    background: #fff4e8;
    border: 1px solid #f7d4b0;
    border-radius: 6px;
    padding: 10px 12px;
}

.deadline-text-months {
    background: #f4f0ff;
    border: 1px solid #d9cafc;
    border-radius: 6px;
    padding: 10px 12px;
}

.deadline-text-variable {
    background: #fff1f2;
    border: 1px solid #f3c0ca;
    border-radius: 6px;
    padding: 10px 12px;
}

.deadline-badge {
    font-size: 15px;
    min-height: 36px;
    padding: 0 14px;
    font-weight: 600;
}

.deadline-create-hint {
    margin-bottom: 14px;
}

.deadline-unit-same_day {
    border-inline-start-color: #0369a1;
    background: #f0f9ff;
}

.deadline-unit-hours {
    border-inline-start-color: #0f766e;
    background: #eefaf7;
}

.deadline-unit-days {
    border-inline-start-color: #b45309;
    background: #fff7ed;
}

.deadline-unit-months {
    border-inline-start-color: #6d28d9;
    background: #f5f3ff;
}

.deadline-unit-variable {
    border-inline-start-color: #be123c;
    background: #fff1f2;
}

.deadline-edit-form {
    display: grid;
    grid-template-columns: 1.2fr 1.2fr 110px 150px;
    gap: 10px;
    align-items: end;
}

.deadline-edit-form label {
    display: grid;
    gap: 6px;
    color: var(--muted);
    font-size: 13px;
}

.deadline-edit-form .full-row,
.deadline-options {
    grid-column: 1 / -1;
}

.deadline-options {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    padding-top: 4px;
}

.deadline-save-button {
    justify-self: start;
    min-height: 40px;
    padding: 0 18px;
    font-weight: 600;
    box-shadow: 0 2px 10px rgba(15, 118, 110, 0.24);
}

.table-wrap {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    min-width: 760px;
}

table.compact-table {
    min-width: 360px;
}

table.wide-table {
    min-width: 1320px;
}

th,
td {
    text-align: right;
    border-bottom: 1px solid var(--line);
    padding: 11px 10px;
    vertical-align: top;
}

th {
    color: var(--muted);
    font-weight: 600;
    font-size: 13px;
    position: sticky;
    top: 0;
    z-index: 1;
    background: #f8fafc;
}

tbody tr:nth-child(even) {
    background: #fcfdff;
}

tbody tr:hover {
    background: #f4f8fc;
}

.status {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    background: var(--success-soft);
    color: var(--accent);
    font-size: 13px;
    white-space: nowrap;
}

.status.large {
    min-height: 38px;
    font-size: 15px;
}

.status-draft,
.status-pending {
    background: #eef2ff;
    color: #3730a3;
}

.status-submitted,
.status-under_review {
    background: var(--warning-soft);
    color: var(--warning);
}

.status-missing_documents,
.status-rejected {
    background: var(--danger-soft);
    color: var(--danger);
}

.status-approved {
    background: var(--success-soft);
    color: var(--accent);
}

.status-sent {
    background: #eaf1ff;
    color: #1d4ed8;
}

.status-active {
    background: var(--success-soft);
    color: var(--accent);
}

.status-inactive {
    background: #f1f5f9;
    color: #475569;
}

.status-locked {
    background: var(--danger-soft);
    color: var(--danger);
}

.status-archived {
    background: #f1f5f9;
    color: #475569;
}

.status-unpaid {
    background: var(--danger-soft);
    color: var(--danger);
}

.status-partial {
    background: var(--warning-soft);
    color: var(--warning);
}

.status-paid {
    background: var(--success-soft);
    color: var(--accent);
}

.status-cancelled {
    background: #f1f5f9;
    color: #475569;
}

code {
    font-family: Menlo, Consolas, monospace;
    font-size: 12px;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.details {
    display: grid;
    grid-template-columns: 130px 1fr;
    gap: 10px 14px;
    margin: 0;
}

.details dt {
    color: var(--muted);
}

.details dd {
    margin: 0;
}

.list {
    margin: 0;
    padding: 0 20px 0 0;
}

.missing-documents-panel {
    border-color: #f5c2c7;
    background: #fff8f8;
}

.missing-documents-panel h2 {
    color: #9f1239;
}

.documents-command-center {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 260px;
    gap: 16px;
    align-items: stretch;
    margin-bottom: 16px;
}

.documents-command-copy,
.documents-progress-card {
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.documents-command-copy {
    padding: 18px;
    background:
        linear-gradient(135deg, rgba(15, 118, 110, 0.1), rgba(255, 255, 255, 0.92)),
        #fff;
}

.documents-command-copy h2 {
    margin: 6px 0 8px;
    font-size: 24px;
    color: var(--text);
}

.documents-command-copy p {
    margin: 0;
    color: var(--muted);
}

.section-kicker.danger {
    color: var(--danger);
    background: var(--danger-soft);
}

.documents-progress-card {
    display: grid;
    gap: 8px;
    align-content: center;
    padding: 18px;
    background:
        linear-gradient(135deg, rgba(3, 105, 161, 0.1), rgba(255, 255, 255, 0.95)),
        #fff;
}

.documents-progress-card span {
    color: var(--muted);
    font-weight: 700;
}

.documents-progress-card strong {
    color: var(--info);
    font-size: 34px;
    line-height: 1;
}

.document-progress-bar {
    height: 10px;
    overflow: hidden;
    border-radius: 999px;
    background: #e2e8f0;
}

.document-progress-bar span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--accent), var(--info));
}

.document-filter-tabs {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 16px;
}

.document-filter-tab {
    display: flex;
    min-height: 74px;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 12px;
    color: var(--text);
    background: #fff;
    text-decoration: none;
    box-shadow: var(--shadow-sm);
}

.document-filter-tab span {
    color: var(--muted);
    font-weight: 800;
}

.document-filter-tab strong {
    display: inline-flex;
    min-width: 34px;
    min-height: 34px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: #f1f5f9;
    font-size: 18px;
}

.document-filter-tab.active {
    border-color: var(--accent);
    background: var(--accent-soft);
}

.document-filter-tab.missing.active {
    border-color: var(--danger);
    background: var(--danger-soft);
}

.document-filter-tab.pending.active {
    border-color: #c2410c;
    background: #fff7ed;
}

.document-filter-tab.approved.active {
    border-color: var(--success);
    background: var(--success-soft);
}

.document-filter-tab.rejected.active {
    border-color: var(--danger);
    background: var(--danger-soft);
}

.missing-documents-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin: 14px 0 0;
    padding: 0;
    list-style: none;
}

.missing-documents-list li {
    position: relative;
    min-height: 46px;
    padding: 10px 38px 10px 12px;
    border: 1px solid #fecdd3;
    border-radius: 10px;
    color: #9f1239;
    background: #fff1f2;
    font-weight: 800;
}

.missing-documents-list li::before {
    content: "!";
    position: absolute;
    top: 10px;
    right: 12px;
    display: inline-flex;
    width: 20px;
    height: 20px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #fff;
    background: var(--danger);
    font-size: 13px;
    font-weight: 900;
}

.required-document-board,
.uploaded-documents-panel {
    margin-bottom: 16px;
}

.required-document-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.required-document-card {
    display: grid;
    gap: 12px;
    min-height: 230px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
}

.required-document-card.state-missing {
    border-color: #fecdd3;
    background: #fff7f8;
}

.required-document-card.state-pending {
    border-color: #fed7aa;
    background: #fffbf5;
}

.required-document-card.state-approved {
    border-color: #a7f3d0;
    background: #f2fbf7;
}

.required-document-card.state-rejected {
    border-color: #fecaca;
    background: #fff7f7;
}

.required-document-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.document-state-icon {
    display: inline-flex;
    width: 34px;
    height: 34px;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: #f1f5f9;
}

.state-missing .document-state-icon {
    background: #ffe4e6;
}

.state-missing .document-state-icon::before {
    content: "!";
    color: var(--danger);
    font-weight: 900;
}

.state-pending .document-state-icon {
    background: #ffedd5;
}

.state-pending .document-state-icon::before {
    content: "...";
    color: #c2410c;
    font-weight: 900;
}

.state-approved .document-state-icon {
    background: #d1fae5;
}

.state-approved .document-state-icon::before {
    content: "✓";
    color: var(--success);
    font-weight: 900;
}

.state-rejected .document-state-icon {
    background: #fee2e2;
}

.state-rejected .document-state-icon::before {
    content: "×";
    color: var(--danger);
    font-weight: 900;
}

.required-document-card h3 {
    margin: 0;
    font-size: 18px;
    line-height: 1.5;
}

.required-document-card dl {
    display: grid;
    grid-template-columns: 72px 1fr;
    gap: 6px 10px;
    margin: 0;
}

.required-document-card dt {
    color: var(--muted);
    font-weight: 700;
}

.required-document-card dd {
    margin: 0;
    color: var(--text);
}

.required-document-card footer {
    display: grid;
    gap: 2px;
    align-self: end;
    padding-top: 10px;
    border-top: 1px solid rgba(148, 163, 184, 0.28);
}

.required-document-card footer span {
    font-weight: 800;
}

.required-document-card footer small {
    color: var(--muted);
    overflow-wrap: anywhere;
}

.documents-empty-state {
    padding: 18px;
    border: 1px dashed var(--line-strong);
    border-radius: 12px;
    color: var(--muted);
    background: var(--surface-soft);
    text-align: center;
    font-weight: 800;
}

.documents-review-table .document-row-pending {
    background: #fffaf3;
}

.documents-review-table .document-row-rejected {
    background: #fff7f7;
}

.documents-review-table .document-row-approved {
    background: #f7fdf9;
}

.document-file-name {
    display: inline-block;
    max-width: 240px;
    overflow-wrap: anywhere;
    color: var(--muted);
    font-weight: 700;
}

.compact-filter {
    margin-bottom: 12px;
}

.scan-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.upload-intro {
    margin-bottom: 10px;
}

.upload-form {
    display: grid;
    gap: 12px;
}

.upload-form-grid {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) minmax(220px, 1fr);
    gap: 12px;
}

.upload-form .scan-actions .button {
    min-width: 130px;
}

.document-upload-entry .panel-head {
    align-items: center;
}

.transaction-primary-action {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
    padding: 16px 18px;
    border: 1px solid #b7d8d4;
    border-radius: 12px;
    background: linear-gradient(135deg, #ecfdf5 0%, #ffffff 100%);
    box-shadow: var(--shadow);
}

.transaction-primary-action h2 {
    margin: 0 0 4px;
    color: var(--accent);
    font-size: 20px;
}

.transaction-primary-action p {
    margin: 0;
}

.transaction-primary-action .button {
    min-width: 150px;
}

.transaction-primary-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.document-upload-entry h2 {
    margin-bottom: 4px;
}

.upload-entry-hint {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 14px;
}

.upload-entry-hint span {
    display: inline-flex;
    min-height: 34px;
    align-items: center;
    padding: 4px 12px;
    border: 1px solid #b7d8d4;
    border-radius: 999px;
    color: var(--accent);
    background: var(--accent-soft);
    font-weight: 700;
}

.document-upload-modal {
    position: fixed;
    inset: 0;
    z-index: 960;
    display: grid;
    place-items: center;
    padding: 24px;
}

.document-upload-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.58);
    backdrop-filter: blur(7px);
}

.document-upload-dialog {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    width: min(820px, 100%);
    max-height: calc(100vh - 48px);
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 36px 110px rgba(15, 23, 42, 0.34);
}

.document-upload-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    padding: 22px 24px;
    border-bottom: 1px solid var(--border);
    background: linear-gradient(135deg, #f8fafc 0%, #ecfdf5 100%);
}

.document-upload-header span {
    display: inline-flex;
    min-height: 28px;
    align-items: center;
    padding: 2px 10px;
    border-radius: 999px;
    color: var(--accent);
    background: var(--accent-soft);
    font-size: 13px;
    font-weight: 800;
}

.document-upload-header h2 {
    margin: 8px 0 4px;
    color: var(--text);
    font-size: 28px;
}

.document-upload-header p {
    margin: 0;
    color: var(--muted);
}

.document-upload-body {
    min-height: 0;
    overflow: auto;
    padding: 24px;
}

.required-documents-modal {
    position: fixed;
    inset: 0;
    z-index: 955;
    display: grid;
    place-items: center;
    padding: 24px;
}

.required-documents-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.58);
    backdrop-filter: blur(7px);
}

.required-documents-dialog {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    width: min(960px, 100%);
    max-height: calc(100vh - 48px);
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 36px 110px rgba(15, 23, 42, 0.34);
}

.required-documents-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    padding: 22px 24px;
    border-bottom: 1px solid var(--border);
    background: linear-gradient(135deg, #f8fafc 0%, #eff6ff 100%);
}

.required-documents-header span {
    display: inline-flex;
    min-height: 28px;
    align-items: center;
    padding: 2px 10px;
    border-radius: 999px;
    color: #1d4ed8;
    background: #eff6ff;
    font-size: 13px;
    font-weight: 800;
}

.required-documents-header h2 {
    margin: 8px 0 4px;
    color: var(--text);
    font-size: 28px;
}

.required-documents-header p {
    margin: 0;
    color: var(--muted);
}

.required-documents-body {
    min-height: 0;
    overflow: auto;
    padding: 24px;
}

.quick-scan-panel {
    margin-top: 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    padding: 12px;
}

.quick-scan-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.quick-scan-head h3 {
    margin: 0;
    font-size: 15px;
}

.quick-scan-video {
    width: 100%;
    max-height: 360px;
    border-radius: 8px;
    border: 1px solid var(--line);
    object-fit: cover;
    background: #0f172a;
}

.quick-scan-tools {
    display: flex;
    gap: 8px;
    margin-top: 10px;
}

.hidden {
    display: none !important;
}

.preview-modal {
    position: fixed;
    inset: 0;
    z-index: 90;
}

.preview-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
}

.preview-modal-dialog {
    position: relative;
    width: min(1280px, calc(100% - 24px));
    height: min(92vh, 880px);
    margin: 4vh auto;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.16);
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
}

.preview-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 12px 14px;
    background: #fff;
    border-bottom: 1px solid var(--line);
}

.preview-modal-head-text {
    display: flex;
    align-items: center;
}

.preview-modal-head-text strong {
    font-size: 16px;
}

.preview-modal-head-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.preview-modal-frame {
    width: 100%;
    height: 100%;
    border: 0;
    background: #f8fafc;
}

.preview-modal-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    background: #f8fafc;
}

.preview-modal-body {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    grid-template-areas: "preview side";
    min-height: 0;
    overflow: hidden;
    direction: ltr;
}

.preview-side-panel {
    grid-area: side;
    direction: rtl;
    border-left: 1px solid var(--line);
    padding: 12px;
    background: #fcfdff;
    display: grid;
    align-content: start;
    gap: 10px;
    overflow-y: auto;
}

.preview-side-panel h3 {
    margin: 0;
    font-size: 15px;
}

.preview-content-panel {
    grid-area: preview;
    direction: rtl;
    padding: 12px;
    background: #f3f6fa;
    min-width: 0;
    min-height: 0;
    overflow: auto;
}

.preview-review-panel {
    padding: 0;
    display: grid;
    gap: 8px;
}

.preview-action-card {
    display: grid;
    grid-template-columns: 1fr;
    align-items: end;
    gap: 8px;
    border: 0;
    border-radius: 0;
    padding: 0;
}

.preview-action-card.approve {
    background: transparent;
}

.preview-action-card.reject {
    background: transparent;
}

.preview-review-panel label {
    display: grid;
    gap: 6px;
    color: var(--muted);
    font-size: 13px;
}

.preview-modal-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 14px;
    border-top: 1px solid var(--line);
    background: #fff;
}

@media (max-width: 760px) {
    .preview-modal-dialog {
        width: calc(100% - 12px);
        height: calc(100vh - 12px);
        margin: 6px auto;
        border-radius: 8px;
    }

    .preview-modal-header {
        align-items: stretch;
        flex-direction: column;
    }

    .preview-modal-head-actions {
        justify-content: space-between;
    }

    .preview-modal-frame {
        height: 100%;
    }

    .preview-modal-footer {
        flex-direction: column;
        align-items: stretch;
    }
}

.document-review-modal {
    position: fixed;
    inset: 0;
    z-index: 120;
}

.document-review-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.52);
}

.document-review-dialog {
    position: relative;
    width: min(1360px, calc(100vw - 32px));
    height: min(92vh, 900px);
    margin: 4vh auto;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 8px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.28);
}

.document-review-header,
.document-review-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 12px 16px;
    background: #fff;
}

.document-review-header {
    border-bottom: 1px solid var(--line);
}

.document-review-footer {
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-size: 13px;
}

.document-review-title {
    display: grid;
    gap: 2px;
    min-width: 0;
}

.document-review-title strong {
    font-size: 17px;
    line-height: 1.4;
    overflow-wrap: anywhere;
}

.document-review-title span {
    color: var(--muted);
    font-size: 13px;
}

.document-review-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 0 0 auto;
}

.document-review-body {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    min-height: 0;
    overflow: hidden;
    direction: ltr;
}

.document-review-viewer {
    min-width: 0;
    min-height: 0;
    padding: 14px;
    background: #eef2f6;
    overflow: auto;
    direction: rtl;
}

.document-review-canvas {
    width: 100%;
    min-height: 100%;
    display: grid;
    place-items: center;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 8px;
    overflow: hidden;
}

.document-review-image {
    width: 100%;
    height: 100%;
    max-height: calc(92vh - 132px);
    object-fit: contain;
    display: block;
    background: #fff;
}

.document-review-frame {
    width: 100%;
    height: calc(92vh - 132px);
    min-height: 520px;
    border: 0;
    background: #fff;
}

.document-review-panel {
    min-width: 0;
    min-height: 0;
    padding: 16px;
    display: grid;
    align-content: start;
    gap: 16px;
    overflow-y: auto;
    direction: rtl;
    border-right: 1px solid var(--line);
    background: #fbfcfe;
}

.document-review-panel-head {
    display: grid;
    gap: 6px;
}

.document-review-panel-head h3 {
    margin: 0;
    font-size: 18px;
}

.document-review-panel-head p {
    margin: 0;
    color: var(--muted);
}

.document-review-actions,
.document-review-action {
    display: grid;
    gap: 12px;
}

.document-review-action {
    padding-top: 14px;
    border-top: 1px solid var(--line);
}

.document-review-action:first-child {
    padding-top: 0;
    border-top: 0;
}

.document-review-action label {
    display: grid;
    gap: 6px;
    color: var(--muted);
    font-size: 13px;
}

.document-review-action button {
    justify-self: start;
}

.assistant-shell {
    display: grid;
    gap: 12px;
}

.assistant-messages {
    min-height: 340px;
    max-height: 62vh;
    overflow-y: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #f8fafc;
    padding: 10px;
    display: grid;
    align-content: start;
    gap: 10px;
}

.assistant-message {
    max-width: min(100%, 780px);
    padding: 10px 12px;
    border-radius: 8px;
    line-height: 1.7;
    white-space: pre-wrap;
}

.assistant-message-bot {
    justify-self: start;
    background: #fff;
    border: 1px solid var(--line);
}

.assistant-message-user {
    justify-self: end;
    background: #e6f4f1;
    border: 1px solid #b7e4dc;
}

.assistant-message-actions {
    margin-top: 8px;
    display: flex;
    gap: 8px;
}

.assistant-extra {
    margin-top: 10px;
    display: grid;
    gap: 8px;
}

.assistant-extra-item {
    margin: 0;
}

.assistant-citizen-reply {
    margin: 0;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: #fff;
    font-family: inherit;
    white-space: pre-wrap;
}

.assistant-guardrail {
    margin: 0;
    padding: 8px 10px;
    border: 1px solid #f5d0d6;
    border-radius: 6px;
    background: #fff1f2;
    color: #9f1239;
    font-size: 13px;
}

.assistant-workflow-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.small-button-primary {
    background: #1f6feb;
    border-color: #1f6feb;
    color: #ffffff;
}

.small-button-danger {
    background: #fff5f5;
    border-color: #ef9a9a;
    color: #b71c1c;
}

.assistant-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
}

.learning-quality-form {
    display: grid;
    gap: 6px;
    min-width: 220px;
}

.landing-body {
    min-height: 100vh;
    background: var(--bg);
}

.landing-page {
    width: min(1160px, calc(100% - 32px));
    margin: 0 auto;
    padding: 28px 0;
}

.landing-hero {
    min-height: 58vh;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 20px;
    align-items: stretch;
}

.landing-hero-content,
.landing-status-panel,
.landing-service-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.landing-hero-content {
    display: grid;
    align-content: center;
    padding: clamp(22px, 5vw, 54px);
}

.landing-product-mark {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    width: fit-content;
    max-width: 100%;
    padding: 10px 12px;
    margin-bottom: 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.landing-product-mark img {
    width: 48px;
    height: 48px;
    object-fit: contain;
    flex: 0 0 48px;
}

.landing-product-mark div {
    display: grid;
    gap: 2px;
    min-width: 0;
}

.landing-product-mark strong {
    font-size: 15px;
    line-height: 1.3;
}

.landing-product-mark span {
    color: var(--muted);
    font-size: 13px;
    font-weight: 600;
}

.landing-kicker {
    margin-bottom: 10px;
    color: var(--accent);
    font-weight: 700;
}

.landing-hero h1 {
    max-width: 760px;
    font-size: 42px;
    line-height: 1.22;
}

.landing-hero p {
    max-width: 700px;
    color: var(--muted);
    font-size: 17px;
}

.landing-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 12px;
}

.whatsapp-button {
    min-height: 36px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0 13px;
    border: 1px solid #16a34a;
    border-radius: var(--radius-sm);
    color: #fff;
    background: #16a34a;
    text-decoration: none;
    font-weight: 700;
}

.whatsapp-button:hover {
    background: #15803d;
    border-color: #15803d;
}

.whatsapp-icon {
    width: 22px;
    height: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    font-size: 14px;
    line-height: 1;
}

.whatsapp-icon svg {
    width: 17px;
    height: 17px;
    fill: currentColor;
}

.landing-status-panel {
    display: grid;
    align-content: center;
    gap: 10px;
    padding: 20px;
}

.landing-status-panel strong {
    font-size: 18px;
}

.landing-status-panel a {
    min-height: 44px;
    display: flex;
    align-items: center;
    padding: 0 12px;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    background: var(--surface-soft);
    text-decoration: none;
}

.landing-status-panel a:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.landing-services {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-top: 18px;
}

.landing-service-card {
    display: grid;
    align-content: start;
    gap: 8px;
    padding: 16px;
}

.landing-service-card span {
    color: var(--accent);
    font-size: 13px;
    font-weight: 700;
}

.landing-service-card h2 {
    margin: 0;
}

.landing-service-card p {
    color: var(--muted);
    margin-bottom: 8px;
}

.legal-page {
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
    padding: 28px 0 44px;
}

.legal-hero,
.legal-card,
.legal-toc {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.legal-hero {
    padding: clamp(22px, 5vw, 46px);
    margin-bottom: 18px;
    background: linear-gradient(135deg, #eefaf7 0%, #fff 58%, #eff6ff 100%);
}

.legal-hero h1 {
    max-width: 840px;
}

.legal-hero p {
    max-width: 820px;
    color: var(--muted);
    font-size: 17px;
}

.legal-layout {
    display: grid;
    grid-template-columns: 260px minmax(0, 1fr);
    gap: 16px;
    align-items: start;
}

.legal-toc {
    position: sticky;
    top: 18px;
    display: grid;
    gap: 6px;
    padding: 14px;
}

.legal-toc a {
    min-height: 34px;
    display: flex;
    align-items: center;
    padding: 0 10px;
    border-radius: 6px;
    color: var(--muted);
    text-decoration: none;
    font-weight: 700;
}

.legal-toc a:hover {
    color: var(--accent);
    background: var(--accent-soft);
}

.legal-content {
    display: grid;
    gap: 12px;
    min-width: 0;
}

.legal-card {
    padding: 18px;
    scroll-margin-top: 24px;
}

.legal-card h2 {
    margin-bottom: 8px;
}

.legal-card p,
.legal-card li {
    color: var(--muted);
}

.legal-card ul {
    margin: 0;
    padding-inline-start: 24px;
}

.legal-card li + li {
    margin-top: 6px;
}

.legal-updated {
    display: inline-flex;
    margin-top: 10px;
    padding: 8px 10px;
    border-radius: 999px;
    color: var(--accent) !important;
    background: var(--accent-soft);
    font-weight: 700;
}

.staff-login-page {
    min-height: 100vh;
    width: min(1080px, calc(100% - 32px));
    display: grid;
    align-items: center;
    margin: 0 auto;
    padding: 28px 0;
}

.staff-login-card {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(340px, 0.95fr);
    gap: 18px;
}

.staff-login-intro,
.staff-login-form {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.staff-login-intro {
    display: grid;
    align-content: center;
    gap: 12px;
    padding: clamp(22px, 5vw, 46px);
}

.staff-login-intro h1 {
    max-width: 620px;
    font-size: 38px;
    line-height: 1.25;
}

.staff-login-intro p {
    max-width: 620px;
    color: var(--muted);
    font-size: 16px;
}

.staff-login-hints {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 4px;
}

.staff-login-hints span {
    min-height: 30px;
    display: inline-flex;
    align-items: center;
    padding: 0 10px;
    border-radius: 999px;
    color: var(--accent);
    background: var(--accent-soft);
    font-size: 13px;
    font-weight: 600;
}

.staff-login-form {
    display: grid;
    align-content: center;
    gap: 14px;
    padding: clamp(18px, 4vw, 34px);
}

.staff-login-form h2 {
    margin-bottom: 4px;
    font-size: 24px;
}

.staff-login-form p {
    margin-bottom: 0;
    color: var(--muted);
}

.staff-login-form label {
    display: grid;
    gap: 6px;
    color: var(--muted);
    font-size: 13px;
}

.staff-login-form .button {
    min-height: 44px;
    justify-content: center;
}

.staff-login-links {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding-top: 4px;
    color: var(--muted);
    font-size: 13px;
}

.staff-login-links a {
    text-decoration: none;
}

.staff-login-links a:hover {
    color: var(--accent);
}

.portal-body {
    min-height: 100vh;
    background: #eef2f6;
}

.portal-shell {
    width: min(1040px, calc(100% - 28px));
    margin: 0 auto;
    padding: 22px 0;
}

.portal-login {
    min-height: calc(100vh - 44px);
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 420px);
    gap: 20px;
    align-items: center;
}

.portal-brand {
    display: grid;
    gap: 10px;
}

.portal-brand span,
.portal-header span,
.portal-summary span {
    color: var(--muted);
    font-size: 13px;
    font-weight: 600;
}

.portal-brand h1,
.portal-header h1 {
    margin: 0;
    font-size: 34px;
    line-height: 1.25;
}

.portal-brand p,
.portal-header p {
    max-width: 620px;
    margin: 0;
    color: var(--muted);
}

.portal-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 16px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
}

.portal-login-form {
    display: grid;
    gap: 14px;
}

.portal-login-form label {
    display: grid;
    gap: 6px;
    color: var(--muted);
    font-size: 13px;
}

.portal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}

.portal-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 16px;
}

.portal-summary div {
    display: grid;
    gap: 6px;
    padding: 12px;
    border-radius: 8px;
    background: #f8fafc;
}

.portal-summary strong {
    font-size: 20px;
}

.portal-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.portal-account-layout {
    display: grid;
    grid-template-columns: 320px minmax(0, 1fr);
    gap: 14px;
    align-items: start;
}

.portal-account-details {
    min-width: 0;
    display: grid;
    gap: 14px;
}

.portal-transactions-list {
    position: sticky;
    top: 16px;
    display: grid;
    gap: 10px;
}

.portal-transactions-list h2 {
    margin: 0;
}

.portal-transactions-list form {
    margin: 0;
}

.portal-transactions-list button {
    width: 100%;
    display: grid;
    gap: 4px;
    padding: 12px;
    text-align: right;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--surface-soft);
    color: var(--text);
    font: inherit;
    cursor: pointer;
}

.portal-transactions-list button.is-selected {
    border-color: var(--accent);
    background: var(--accent-soft);
}

.portal-transactions-list button strong {
    font-size: 14px;
}

.portal-transactions-list button span,
.portal-transactions-list button em {
    color: var(--muted);
    font-size: 12px;
    font-style: normal;
}

.portal-list {
    margin: 0;
    padding: 0 18px 0 0;
}

.portal-list li + li {
    margin-top: 8px;
}

.portal-list small {
    display: block;
    color: var(--muted);
}

.portal-money {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 8px 14px;
    margin: 0;
}

.portal-money dt {
    color: var(--muted);
}

.portal-money dd {
    margin: 0;
    font-weight: 600;
}

.portal-chat {
    grid-column: 1 / -1;
}

.portal-chat-messages {
    min-height: 160px;
    max-height: 300px;
    overflow-y: auto;
    display: grid;
    align-content: start;
    gap: 8px;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #f8fafc;
    margin-bottom: 10px;
}

.portal-chat-messages p {
    margin: 0;
    padding: 8px 10px;
    border-radius: 8px;
    background: #fff;
    border: 1px solid #edf0f4;
    white-space: pre-wrap;
}

.portal-chat-user {
    justify-self: end;
    background: #e6f4f1 !important;
}

.portal-chat form {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
}

@media (max-width: 900px) {
    .legal-layout {
        grid-template-columns: 1fr;
    }

    .legal-toc {
        position: static;
    }

    .document-review-dialog {
        width: calc(100vw - 16px);
        height: calc(100vh - 16px);
        margin: 8px auto;
    }

    .document-review-body {
        grid-template-columns: 1fr;
        grid-template-rows: auto minmax(0, 1fr);
    }

    .document-review-panel {
        border-right: 0;
        border-bottom: 1px solid var(--line);
        max-height: 320px;
    }

    .document-review-viewer {
        padding: 10px;
    }

    .document-review-frame,
    .document-review-image {
        height: 100%;
        min-height: 360px;
        max-height: none;
    }
}

@media (max-width: 640px) {
    .document-review-header,
    .document-review-footer {
        align-items: stretch;
        flex-direction: column;
    }

    .document-review-header-actions {
        justify-content: space-between;
    }
}

@media (max-width: 560px) {
    .preview-modal-body {
        grid-template-columns: 1fr;
        grid-template-areas:
            "side"
            "preview";
        grid-template-rows: auto minmax(0, 1fr);
    }

    .preview-side-panel {
        border-left: 0;
        border-bottom: 1px solid var(--line);
    }
}

.ok {
    color: var(--accent);
    margin: 0;
}

.timeline {
    margin: 0;
    padding: 0 22px 0 0;
}

.timeline li {
    margin-bottom: 12px;
}

.timeline span {
    color: var(--muted);
    font-size: 13px;
    margin-inline-start: 8px;
}

.timeline p {
    margin: 4px 0 0;
}

.workflow-strip {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 16px;
}

.workflow-step {
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 10px 12px;
    background: #fff;
}

.workflow-step strong {
    display: block;
    font-size: 14px;
}

.workflow-step span {
    color: var(--muted);
    font-size: 12px;
}

.workflow-step.active {
    border-color: var(--accent);
    background: #eefaf7;
}

.hint-box {
    border: 1px solid #cde0f7;
    background: #f5f9ff;
    border-radius: 8px;
    padding: 10px 12px;
    margin-bottom: 12px;
}

.inline-actions {
    display: flex;
    gap: 8px;
    align-items: center;
    min-width: 220px;
}

.small-input {
    max-width: 82px;
}

.stacked-actions {
    display: grid;
    gap: 8px;
    min-width: 320px;
}

.checkline {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--muted);
    font-size: 13px;
}

.checkline input {
    width: auto;
    min-height: auto;
}

.status-required {
    background: #e6f4f1;
    color: var(--accent);
}

.status-optional {
    background: #eef2ff;
    color: #3730a3;
}

@media (max-width: 760px) {
    body {
        background: #f4f6f8;
    }

    body.mobile-menu-open {
        overflow: hidden;
    }

    .app-shell {
        display: block;
    }

    .mobile-menu-button {
        position: fixed;
        top: 14px;
        right: 14px;
        z-index: 80;
        width: 44px;
        height: 44px;
        display: inline-grid;
        place-items: center;
        gap: 4px;
        padding: 10px;
        border: 1px solid var(--line);
        border-radius: 8px;
        background: #fff;
        color: var(--text);
        box-shadow: 0 8px 18px rgba(15, 23, 42, 0.12);
    }

    .mobile-menu-button span {
        width: 20px;
        height: 2px;
        display: block;
        border-radius: 999px;
        background: currentColor;
    }

    .mobile-sidebar-backdrop {
        position: fixed;
        inset: 0;
        z-index: 70;
        display: block;
        pointer-events: none;
        opacity: 0;
        background: rgba(15, 23, 42, 0.42);
        transition: opacity 0.2s ease;
    }

    body.mobile-menu-open .mobile-sidebar-backdrop {
        pointer-events: auto;
        opacity: 1;
    }

    .sidebar {
        position: fixed;
        top: 0;
        right: 0;
        bottom: 0;
        z-index: 75;
        width: min(86vw, 340px);
        height: 100vh;
        max-height: none;
        padding: 16px;
        border-left: 0;
        border-bottom: 0;
        box-shadow: -14px 0 34px rgba(15, 23, 42, 0.2);
        transform: translateX(105%);
        transition: transform 0.22s ease;
    }

    body.mobile-menu-open .sidebar {
        transform: translateX(0);
    }

    .sidebar-mobile-head {
        display: flex;
        align-items: center;
        justify-content: flex-start;
        gap: 10px;
        margin-bottom: 10px;
        padding-bottom: 10px;
        border-bottom: 1px solid var(--line);
    }

    .mobile-sidebar-close {
        width: 36px;
        height: 36px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border: 1px solid var(--line);
        border-radius: 8px;
        background: #fff;
        color: var(--text);
        font: inherit;
        font-size: 24px;
        line-height: 1;
    }

    .side-nav {
        display: grid;
        gap: 14px;
        overflow-x: visible;
        padding-bottom: 0;
        scroll-snap-type: none;
    }

    .nav-group {
        min-width: 0;
        scroll-snap-align: none;
        gap: 6px;
    }

    .nav-group span {
        font-size: 11px;
    }

    .nav-group a {
        min-height: 42px;
        padding: 0 10px;
        background: #f8fafc;
        border: 1px solid #edf0f4;
    }

    .app-header,
    .page-head,
    .panel-head {
        align-items: stretch;
        flex-direction: column;
    }

    .app-header {
        min-height: auto;
        display: grid;
        gap: 10px;
        padding: 14px 68px 14px 16px;
    }

    .app-header > div {
        min-width: 0;
    }

    .app-header h1 {
        font-size: 20px;
        line-height: 1.35;
        overflow-wrap: anywhere;
    }

    .app-header p {
        font-size: 12px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .userbox {
        width: 100%;
        padding-top: 8px;
        border-top: 1px solid #edf0f4;
        justify-content: space-between;
        gap: 10px;
    }

    .userbox > span {
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .userbox .small-button {
        flex: 0 0 auto;
    }

    .shell {
        width: min(100% - 16px, 1180px);
        margin: 12px auto 18px;
    }

    h1 {
        font-size: 24px;
    }

    h2 {
        font-size: 17px;
    }

    .page-head .button,
    .page-head .link,
    .panel-head .button,
    .panel-head .link {
        width: 100%;
        justify-content: center;
    }

    .page-head {
        gap: 8px;
        padding: 2px 0;
    }

    .page-head h1 {
        line-height: 1.3;
    }

    .page-head p {
        margin-bottom: 0;
        font-size: 15px;
        line-height: 1.75;
    }

    .panel,
    .metric {
        padding: 12px;
        border-radius: 8px;
    }

    input,
    select,
    textarea {
        font-size: 16px;
    }

    .button,
    .small-button,
    .link {
        min-height: 40px;
    }

    .metrics,
    .grid.two,
    .workflow-strip,
    .deadline-layout,
    .upload-form-grid,
    .payments-hero,
    .payment-stat-grid,
    .payments-workspace,
    .fee-action-grid,
    .fee-amount-grid,
    .form.compact,
    .form.filters {
        grid-template-columns: 1fr;
    }

    .payments-hero {
        padding: 14px;
    }

    .payments-hero-status strong {
        font-size: 28px;
    }

    .payments-side-panel {
        position: static;
        order: -1;
    }

    .fee-card-head,
    .payment-history-item {
        align-items: stretch;
        grid-template-columns: 1fr;
    }

    .fee-card-head {
        flex-direction: column;
    }

    .payment-history-item {
        gap: 10px;
    }

    .payment-stat-card {
        min-height: auto;
    }

    .form.filters .button,
    .form.filters .link,
    .form.compact .button,
    .form.compact .link {
        width: 100%;
        justify-content: center;
    }

    .deadline-create-panel {
        position: static;
    }

    .deadline-item-head {
        align-items: stretch;
        flex-direction: column;
    }

    .deadline-edit-form {
        grid-template-columns: 1fr;
    }

    .tabs-nav {
        display: grid;
        grid-template-columns: 1fr;
    }

    .tab-link {
        width: 100%;
        justify-content: space-between;
    }

    .details {
        grid-template-columns: 1fr;
        gap: 6px;
    }

    .status.large {
        align-self: flex-start;
    }

    table {
        min-width: 540px;
    }

    table.wide-table {
        min-width: 780px;
    }

    .table-wrap {
        -webkit-overflow-scrolling: touch;
    }

    table.mobile-card-table,
    table.mobile-card-table thead,
    table.mobile-card-table tbody,
    table.mobile-card-table tr,
    table.mobile-card-table th,
    table.mobile-card-table td {
        display: block;
        width: 100%;
        min-width: 0;
    }

    table.mobile-card-table {
        min-width: 0;
        border-collapse: separate;
        border-spacing: 0;
    }

    table.mobile-card-table thead {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        white-space: nowrap;
    }

    table.mobile-card-table tbody {
        display: grid;
        gap: 10px;
    }

    table.mobile-card-table tbody tr {
        border: 1px solid var(--line);
        border-radius: 8px;
        background: #fff;
        overflow: hidden;
        box-shadow: 0 2px 10px rgba(15, 23, 42, 0.05);
    }

    table.mobile-card-table tbody tr:nth-child(even),
    table.mobile-card-table tbody tr:hover {
        background: #fff;
    }

    table.mobile-card-table td {
        min-height: 42px;
        display: grid;
        grid-template-columns: minmax(92px, 38%) minmax(0, 1fr);
        gap: 10px;
        align-items: start;
        border-bottom: 1px solid #edf0f4;
        padding: 10px 12px;
        overflow-wrap: anywhere;
    }

    table.mobile-card-table td:last-child {
        border-bottom: 0;
    }

    table.mobile-card-table td::before {
        content: attr(data-label);
        color: var(--muted);
        font-size: 12px;
        font-weight: 600;
    }

    table.mobile-card-table.compact-table td {
        grid-template-columns: minmax(90px, 42%) minmax(0, 1fr);
    }

    .assistant-messages {
        min-height: 260px;
        max-height: 54vh;
    }

    .assistant-form {
        grid-template-columns: 1fr;
    }

    .assistant-form .button {
        width: 100%;
        justify-content: center;
    }

    .assistant-workflow-actions .small-button,
    .assistant-message-actions .small-button {
        width: 100%;
        justify-content: center;
    }

    .actions,
    .actions form,
    .inline-actions,
    .stacked-actions {
        width: 100%;
        min-width: 0;
    }

    .actions .button,
    .actions .small-button,
    .actions .link,
    .actions form .small-button,
    .actions form .button {
        width: 100%;
        justify-content: center;
    }

    .actions input,
    .small-input {
        max-width: 100%;
        min-width: 0;
    }

    .inline-actions {
        display: grid;
        grid-template-columns: 1fr;
        gap: 6px;
        min-width: 0;
    }

    .inline-actions select,
    .inline-actions input,
    .inline-actions .small-button,
    .inline-actions .button {
        width: 100%;
        max-width: 100%;
    }

    td code {
        white-space: normal;
        overflow-wrap: anywhere;
    }

    .quick-scan-tools {
        flex-direction: column;
    }

    .quick-scan-tools .button,
    .quick-scan-tools .small-button {
        width: 100%;
        justify-content: center;
    }

    .document-upload-entry .panel-head {
        align-items: stretch;
        flex-direction: column;
    }

    .document-upload-entry .panel-head .button {
        width: 100%;
    }

    .transaction-primary-action {
        align-items: stretch;
        flex-direction: column;
        padding: 14px;
    }

    .transaction-primary-action .button {
        width: 100%;
    }

    .transaction-primary-buttons {
        display: grid;
        grid-template-columns: 1fr;
    }

    .documents-command-center {
        grid-template-columns: 1fr;
    }

    .documents-command-copy h2 {
        font-size: 20px;
    }

    .document-filter-tabs {
        grid-template-columns: 1fr;
    }

    .document-filter-tab {
        min-height: 58px;
    }

    .missing-documents-list,
    .required-document-grid {
        grid-template-columns: 1fr;
    }

    .required-document-card {
        min-height: auto;
    }

    .required-document-card dl {
        grid-template-columns: 1fr;
    }

    .document-file-name {
        max-width: 100%;
    }

    .document-upload-modal {
        align-items: end;
        padding: 10px;
    }

    .required-documents-modal {
        align-items: end;
        padding: 10px;
    }

    .document-upload-dialog {
        max-height: calc(100vh - 20px);
        border-radius: 20px 20px 0 0;
    }

    .required-documents-dialog {
        max-height: calc(100vh - 20px);
        border-radius: 20px 20px 0 0;
    }

    .document-upload-header {
        padding: 16px;
    }

    .required-documents-header {
        padding: 16px;
    }

    .document-upload-header h2 {
        font-size: 23px;
    }

    .required-documents-header h2 {
        font-size: 23px;
    }

    .document-upload-body {
        padding: 16px;
    }

    .required-documents-body {
        padding: 16px;
    }

    .portal-shell {
        width: min(100% - 16px, 1040px);
        padding: 12px 0;
    }

    .portal-login,
    .portal-account-layout,
    .portal-grid,
    .portal-summary {
        grid-template-columns: 1fr;
    }

    .portal-transactions-list {
        position: static;
    }

    .portal-summary {
        margin-bottom: 0;
    }

    .portal-login {
        min-height: calc(100vh - 24px);
        align-items: stretch;
    }

    .portal-brand h1,
    .portal-header h1 {
        font-size: 26px;
    }

    .portal-header {
        align-items: stretch;
        flex-direction: column;
    }

    .portal-header .small-button,
    .portal-login-form .button,
    .portal-chat .button {
        width: 100%;
        justify-content: center;
    }

    .portal-card {
        padding: 14px;
    }

    .portal-chat form {
        grid-template-columns: 1fr;
    }

    .landing-page {
        width: min(100% - 16px, 1160px);
        padding: 12px 0;
    }

    .legal-page {
        width: min(100% - 16px, 1120px);
        padding: 12px 0 28px;
    }

    .legal-hero,
    .legal-card {
        padding: 14px;
    }

    .landing-hero,
    .landing-services {
        grid-template-columns: 1fr;
    }

    .landing-hero {
        min-height: auto;
        gap: 12px;
    }

    .landing-hero-content {
        padding: 20px;
    }

    .landing-hero h1 {
        font-size: 29px;
    }

    .landing-hero p {
        font-size: 15px;
    }

    .landing-actions .button,
    .landing-actions .link,
    .landing-actions .whatsapp-button,
    .landing-service-card .small-button {
        width: 100%;
        justify-content: center;
    }

    .landing-product-mark {
        width: 100%;
    }

    .landing-status-panel {
        padding: 14px;
    }

    .staff-login-page {
        width: min(100% - 16px, 1080px);
        min-height: auto;
        padding: 12px 0;
    }

    .staff-login-card {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .staff-login-intro,
    .staff-login-form {
        padding: 18px;
    }

    .staff-login-intro h1 {
        font-size: 28px;
    }

    .staff-login-hints {
        display: grid;
        grid-template-columns: 1fr;
    }

    .staff-login-hints span {
        justify-content: center;
    }

    .staff-login-links {
        flex-direction: column;
        align-items: center;
    }
}

@media (max-width: 420px) {
    .brand {
        align-items: flex-start;
        flex-direction: column;
    }

    .brand span {
        max-width: 100%;
        text-align: right;
    }

    .nav-group {
        min-width: 0;
    }

    table.mobile-card-table td,
    table.mobile-card-table.compact-table td {
        grid-template-columns: 1fr;
        gap: 4px;
    }

    table.mobile-card-table td::before {
        font-size: 11px;
    }

    .metric strong {
        font-size: 23px;
    }
}

body.modal-open {
    overflow: hidden;
}

.privacy-modal[aria-hidden="true"] {
    display: none;
}

.privacy-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: grid;
    place-items: center;
    padding: 24px;
}

.privacy-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.62);
    backdrop-filter: blur(7px);
}

.privacy-modal-window {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-rows: auto 1fr;
    width: min(1120px, 100%);
    height: min(860px, calc(100vh - 48px));
    overflow: hidden;
    border: 1px solid rgba(219, 228, 238, 0.9);
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 36px 110px rgba(15, 23, 42, 0.34);
}

.privacy-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border);
    background: #fff;
}

.privacy-modal-header span {
    display: block;
    color: var(--muted);
    font-size: 14px;
    font-weight: 700;
}

.privacy-modal-header h2 {
    margin: 4px 0 0;
    color: var(--text);
    font-size: 24px;
}

.privacy-modal-close {
    min-height: 46px;
    padding: 8px 18px;
    border: 1px solid var(--border);
    border-radius: 14px;
    color: var(--text);
    background: #fff;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.privacy-modal-body {
    min-height: 0;
    background: #f3f7fb;
}

.privacy-modal-body iframe {
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
    background: #fff;
}

@media (max-width: 720px) {
    .privacy-modal {
        padding: 10px;
    }

    .privacy-modal-window {
        height: calc(100vh - 20px);
        border-radius: 18px;
    }

    .privacy-modal-header {
        align-items: flex-start;
        padding: 14px;
    }

    .privacy-modal-header h2 {
        font-size: 20px;
    }
}

.transaction-create-modal.hidden {
    display: none;
}

.transaction-create-modal {
    position: fixed;
    inset: 0;
    z-index: 950;
    display: grid;
    place-items: center;
    padding: 24px;
}

.transaction-create-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.58);
    backdrop-filter: blur(7px);
}

.transaction-create-dialog {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    width: min(760px, 100%);
    max-height: calc(100vh - 48px);
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 36px 110px rgba(15, 23, 42, 0.34);
}

.transaction-create-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    padding: 22px 24px;
    border-bottom: 1px solid var(--border);
    background: linear-gradient(135deg, #f8fafc 0%, #ecfdf5 100%);
}

.transaction-create-header span {
    display: inline-flex;
    min-height: 28px;
    align-items: center;
    padding: 2px 10px;
    border-radius: 999px;
    color: var(--accent);
    background: var(--accent-soft);
    font-size: 13px;
    font-weight: 800;
}

.transaction-create-header h2 {
    margin: 8px 0 4px;
    color: var(--text);
    font-size: 28px;
}

.transaction-create-header p {
    margin: 0;
    color: var(--muted);
}

.transaction-create-body {
    min-height: 0;
    overflow: auto;
    padding: 24px;
}

.transaction-create-form {
    gap: 16px;
}

.transaction-create-form .button {
    min-height: 48px;
    font-size: 16px;
}

@media (max-width: 720px) {
    .transaction-create-modal {
        padding: 10px;
        align-items: end;
    }

    .transaction-create-dialog {
        width: 100%;
        max-height: calc(100vh - 20px);
        border-radius: 20px 20px 0 0;
    }

    .transaction-create-header {
        padding: 16px;
    }

    .transaction-create-header h2 {
        font-size: 23px;
    }

    .transaction-create-body {
        padding: 16px;
    }
}
