:root,
[data-theme="dark-premium"] {
    --page-bg: #f3f6f8;
    --surface: #ffffff;
    --surface-strong: #eef4f6;
    --border: rgba(23, 101, 118, .28);
    --border-soft: rgba(29, 48, 60, .12);
    --text: #1c2f3a;
    --text-muted: #526877;
    --text-soft: #82919b;
    --accent: #176576;
    --accent-strong: #124e5c;
    --success: #247a58;
    --warning: #a66b00;
    --danger: #b94343;
    --violet: #6256a8;
    --gold: #b7791f;
}

/* Wiki: controle de visibilidade e compartilhamento externo */
.knowledge-field-label {
    display: block;
    margin-bottom: 8px;
    color: #35516a;
    font-size: 13px;
}

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

.knowledge-visibility-option {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    min-height: 86px;
    padding: 14px;
    border: 1px solid #c9dce7;
    border-radius: 12px;
    background: #fff;
    cursor: pointer;
    transition: border-color .18s ease, background .18s ease, box-shadow .18s ease;
}

.knowledge-visibility-option:hover {
    border-color: #73bdca;
    background: #f8fcfd;
}

.knowledge-visibility-option:has(input:checked) {
    border-color: #08768a;
    background: #eefafb;
    box-shadow: 0 0 0 2px rgba(8, 118, 138, .09);
}

.knowledge-visibility-option.is-disabled {
    opacity: .55;
    cursor: not-allowed;
}

.knowledge-visibility-option input {
    flex: 0 0 auto;
    width: 18px;
    height: 18px;
    margin: 2px 0 0;
    accent-color: #08768a;
}

.knowledge-visibility-option span,
.knowledge-visibility-option b,
.knowledge-visibility-option small {
    display: block;
}

.knowledge-visibility-option b {
    color: #133b53;
    font-size: 14px;
}

.knowledge-visibility-option small {
    margin-top: 5px;
    color: #63798a;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.4;
}

.knowledge-role-access {
    margin-top: 10px;
    padding: 14px;
    border: 1px solid #c9dce7;
    border-radius: 12px;
    background: #f8fbfc;
}

.knowledge-role-access[hidden] {
    display: none;
}

.knowledge-role-access > strong {
    display: block;
    margin-bottom: 10px;
    color: #23475e;
    font-size: 13px;
}

.knowledge-role-access > div {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.knowledge-role-access label {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 8px 11px;
    border: 1px solid #d3e2ea;
    border-radius: 999px;
    background: #fff;
    color: #31546a;
    cursor: pointer;
}

.knowledge-role-access input {
    width: 16px;
    height: 16px;
    margin: 0;
    accent-color: #08768a;
}

.knowledge-visibility-badge {
    max-width: 128px;
    overflow: hidden;
    color: #496779 !important;
    background: #edf4f7 !important;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.knowledge-visibility-badge.is-shared_link {
    color: #08715f !important;
    background: #ddf7ee !important;
}

.knowledge-visibility-badge.is-restricted {
    color: #72510a !important;
    background: #fff3d5 !important;
}

.knowledge-share-panel {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 14px;
    align-items: start;
    margin-top: 16px;
    padding: 17px;
    border: 1px solid #a9dcd4;
    border-radius: 14px;
    background: linear-gradient(135deg, #f0fbf8, #f7fbfc);
}

.knowledge-share-panel.is-inactive {
    border-color: #d5e1e7;
    background: #f8fafb;
}

.knowledge-share-icon {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: #087b72;
    color: #fff;
    font-size: 22px;
    font-weight: 800;
}

.knowledge-share-copy > span,
.knowledge-share-copy > strong,
.knowledge-share-copy > small {
    display: block;
}

.knowledge-share-copy > span {
    color: #087568;
    font-size: 11px;
    font-weight: 850;
    letter-spacing: .09em;
    text-transform: uppercase;
}

.knowledge-share-copy > strong {
    margin-top: 4px;
    color: #173d51;
}

.knowledge-share-copy > small {
    margin-top: 3px;
    color: #647b89;
}

.knowledge-share-url {
    display: grid;
    grid-template-columns: minmax(180px, 1fr) auto auto;
    gap: 8px;
    margin-top: 12px;
}

.knowledge-share-url input {
    min-width: 0;
    height: 38px;
    padding: 0 11px;
    border: 1px solid #bdd6df;
    border-radius: 9px;
    background: #fff;
    color: #35566a;
}

.knowledge-share-actions {
    display: flex;
    gap: 7px;
}

@media (max-width: 920px) {
    .knowledge-visibility-options {
        grid-template-columns: 1fr;
    }

    .knowledge-visibility-option {
        min-height: 0;
    }

    .knowledge-share-panel {
        grid-template-columns: auto minmax(0, 1fr);
    }

    .knowledge-share-actions {
        grid-column: 2;
        flex-wrap: wrap;
    }
}

@media (max-width: 640px) {
    .knowledge-share-panel {
        grid-template-columns: 1fr;
    }

    .knowledge-share-icon {
        display: none;
    }

    .knowledge-share-actions {
        grid-column: 1;
    }

    .knowledge-share-url {
        grid-template-columns: 1fr;
    }
}

/* Contracts fake flow */
.contracts-shell {
    background: #eef4f8;
}

.contracts-page-header {
    align-items: center;
}

.contracts-page-header .page-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
}

.contracts-page-header .page-actions form {
    display: inline-flex;
    margin: 0;
}

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

.contract-metrics article,
.contract-filter-panel,
.contract-table-card,
.contract-card,
.contract-hero-card,
.contract-state-strip,
.contract-history-box {
    border: 1px solid #dbe6ef;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 36px rgba(24, 45, 70, .06);
}

.contract-metrics article {
    display: grid;
    gap: 8px;
    min-height: 106px;
    padding: 18px;
    border-top-width: 3px;
}

.contract-metrics span,
.contract-section-kicker {
    color: #0067c7;
    font-size: .74rem;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.contract-metrics strong {
    color: #001b3d;
    font-size: 1.9rem;
    line-height: 1;
}

.contract-metrics small,
.contract-table small,
.contract-table em,
.contract-card small,
.contract-hero-card p,
.contract-hero-card small,
.contract-cycle-card p,
.contract-interaction-list p,
.contract-history-box p {
    color: #46617f;
    font-size: .82rem;
}

.contract-metric-blue {
    border-top-color: #2563eb;
}

.contract-metric-red {
    border-top-color: #ef4444;
}

.contract-metric-orange {
    border-top-color: #f59e0b;
}

.contract-metric-green {
    border-top-color: #10b981;
}

.contract-filter-panel {
    display: grid;
    grid-template-columns: minmax(260px, 2fr) minmax(180px, 1fr) minmax(180px, 1fr) auto auto;
    gap: 12px;
    align-items: end;
    margin-bottom: 18px;
    padding: 16px;
}

.contract-clear-filter {
    white-space: nowrap;
}

.contract-filter-panel label,
.contract-fields-grid label {
    display: grid;
    gap: 7px;
    color: #516680;
    font-size: .78rem;
    font-weight: 800;
}

.contract-filter-panel input,
.contract-filter-panel select,
.contract-fields-grid input,
.contract-fields-grid select,
.contract-fields-grid textarea {
    width: 100%;
    min-height: 42px;
    min-width: 0;
    border: 1px solid #cfdae8;
    border-radius: 8px;
    background: #fff;
    color: #001b3d;
    font-weight: 800;
    padding: 9px 12px;
    text-overflow: ellipsis;
}

.contract-fields-grid textarea {
    min-height: 86px;
    resize: vertical;
}

.contract-table-card,
.contract-card {
    padding: 18px;
}

.contract-table-wrap {
    overflow-x: auto;
    padding-bottom: 14px;
}

.contract-table {
    width: 100%;
    min-width: 1160px;
    border-collapse: separate;
    border-spacing: 0 10px;
}

.contract-table th {
    background: #f1f6fb;
    color: #001b3d;
    font-size: .72rem;
    padding: 12px;
    text-align: left;
    text-transform: uppercase;
    white-space: nowrap;
}

.contract-table td {
    background: #fff;
    border-top: 1px solid #dfe8f1;
    border-bottom: 1px solid #dfe8f1;
    padding: 14px 12px;
    vertical-align: middle;
}

.contract-table td:first-child {
    border-left: 1px solid #dfe8f1;
    border-radius: 8px 0 0 8px;
}

.contract-table td:last-child {
    border-right: 1px solid #dfe8f1;
    border-radius: 0 8px 8px 0;
}

.contract-table tbody tr td {
    transition: background .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.contract-table tbody tr:hover td {
    background: #fbfdff;
    border-color: #b8d2e6;
    box-shadow: 0 12px 24px rgba(7, 86, 106, .08);
}

.contract-table tbody tr:hover td:first-child {
    box-shadow: 0 12px 24px rgba(7, 86, 106, .08), inset 3px 0 0 #0aa6bd;
}

.contract-table tbody tr:last-child td {
    border-bottom-color: #dfe8f1;
    box-shadow: inset 0 -1px 0 #dfe8f1;
}

.contract-table tbody tr:last-child:hover td {
    box-shadow: 0 12px 24px rgba(7, 86, 106, .08), inset 0 -1px 0 #dfe8f1;
}

.contract-table tbody tr:last-child:hover td:first-child {
    box-shadow: 0 12px 24px rgba(7, 86, 106, .08), inset 3px 0 0 #0aa6bd, inset 0 -1px 0 #dfe8f1;
}

.contract-table th:nth-child(7) {
    min-width: 150px;
}

.contract-table-footer {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    border-top: 1px solid #dfe8f1;
    margin-top: 14px;
    padding-top: 14px;
    color: #46617f;
    font-size: .86rem;
}

.contract-table-footer > div {
    display: flex;
    gap: 8px;
    align-items: center;
}

.contract-table-footer a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    border: 1px solid #c9dbe8;
    border-radius: 8px;
    background: #fff;
    color: #07566a;
    font-weight: 800;
    padding: 6px 11px;
    text-decoration: none;
}

.contract-table-footer a.is-active {
    border-color: #07566a;
    background: #07566a;
    color: #fff;
}

.contract-table-footer a.is-disabled {
    opacity: .55;
    pointer-events: none;
}

.contract-table strong,
.contract-client-cell strong,
.contract-card h2,
.contract-cycle-card h3,
.contract-interaction-list strong,
.contract-document-list strong {
    color: #001b3d;
}

.contract-table small,
.contract-table em,
.contract-client-cell small {
    display: block;
    margin-top: 4px;
}

.contract-id-chip {
    display: inline-grid;
    min-width: 42px;
    min-height: 34px;
    place-items: center;
    border-radius: 8px;
    background: #edf4ff;
    color: #063d87;
    font-weight: 900;
}

.contract-progress-line {
    display: grid;
    gap: 4px;
    margin-top: 8px;
}

.contract-progress-line span,
.contract-status-meter b {
    display: block;
    height: 7px;
    overflow: hidden;
    border-radius: 99px;
    background: #d9e4f2;
}

.contract-progress-line b,
.contract-status-meter i {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #2563eb, #12b981);
    transition: width .28s ease;
}

.contract-progress-line em {
    color: #0067c7;
    font-size: .72rem;
    font-style: normal;
    font-weight: 800;
}

.contract-status-pill,
.contract-attention-pill,
.contract-cycle-status,
.contract-service-chip,
.contract-document-badge,
.contract-draft-count-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    border-radius: 999px;
    padding: 5px 10px;
    font-size: .72rem;
    font-weight: 900;
}

.contract-status-pill.signed,
.contract-status-pill.vigente,
.contract-status-pill.renovado,
.contract-attention-pill.ok,
.contract-cycle-status.concluido,
.contract-document-badge {
    background: #dff8ee;
    color: #007a51;
}

.contract-status-pill.sent_client,
.contract-status-pill.negotiation,
.contract-status-pill.waiting_client_signature,
.contract-status-pill.waiting_internal_signature,
.contract-status-pill.assinatura,
.contract-attention-pill.acompanhar,
.contract-cycle-status.pendente {
    background: #fff1d8;
    color: #b35a00;
}

.contract-draft-count-pill {
    margin-top: 6px;
    background: #eaf7fb;
    color: #07566a;
}

.contract-status-pill.draft,
.contract-status-pill.internal_validation,
.contract-status-pill.replaced,
.contract-status-pill.closed,
.contract-status-pill.canceled,
.contract-status-pill.substituido,
.contract-attention-pill.historico {
    background: #edf1f5;
    color: #516071;
}

.contract-attention-pill.reajuste {
    background: #fff1d8;
    color: #b35a00;
}

.contract-hero-card,
.contract-state-strip {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 16px;
    padding: 18px;
}

.contract-hero-card {
    border-top: 3px solid #2563eb;
}

.contract-hero-card h2,
.contract-card h2 {
    margin: 6px 0;
    font-size: 1.15rem;
}

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

.contract-record-id {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    border: 1px solid #fecaca;
    border-radius: 4px;
    padding: 4px 10px;
    color: #dc2626;
    font-size: .82rem;
    font-weight: 800;
    white-space: nowrap;
}

.contract-client-picker {
    position: relative;
}

.contract-client-results {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    z-index: 30;
    display: grid;
    max-height: 260px;
    overflow-y: auto;
    border: 1px solid #9fd6e5;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 38px rgba(15, 35, 55, .16);
}

.contract-client-results[hidden] {
    display: none;
}

.contract-client-results button {
    display: grid;
    gap: 2px;
    width: 100%;
    border: 0;
    border-bottom: 1px solid #e4f0f5;
    padding: 11px 12px;
    background: #fff;
    color: var(--text);
    text-align: left;
    cursor: pointer;
}

.contract-client-results button[hidden] {
    display: none;
}

.contract-client-results button:last-child {
    border-bottom: 0;
}

.contract-client-results button:hover,
.contract-client-results button.is-active {
    background: #e8f7fb;
}

.contract-client-results strong {
    font-weight: 900;
}

.contract-client-results span {
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 700;
}

.contract-fields-grid input[readonly],
.contract-fields-grid textarea[readonly],
.contract-readonly-input {
    border-color: #cbdbe5;
    background: #eef4f8;
    color: #486172;
    cursor: default;
}

.contract-fields-grid .contract-client-highlight {
    border-color: #86efac;
    background: #f0fdf4;
}

.contract-fields-grid input.contract-client-highlight[readonly] {
    border-color: #86efac;
    background: #f0fdf4;
    color: #0f3d2e;
}

.contract-fields-grid .contract-value-input {
    border-color: #fca5a5;
    background: #fff1f2;
}

.contract-fields-grid .contract-value-label {
    color: #dc2626;
}

.contract-fields-grid .contract-date-input {
    border-color: #7dd3fc;
    background: #e0f2fe;
}

.contract-fields-grid .contract-date-label {
    color: #0369a1;
}

.contract-fields-grid .contract-soft-date-input {
    border-color: #bae6fd;
    background: #e8f8ff;
}

.contract-fields-grid .contract-soft-date-label {
    color: #0b7894;
}

.contract-hero-card aside,
.contract-state-strip > div {
    display: grid;
    align-content: center;
    gap: 8px;
}

.contract-state-strip {
    background: linear-gradient(90deg, #eefcff, #fff);
    align-items: center;
}

.contract-state-strip span {
    color: #516680;
    font-size: .72rem;
    font-weight: 800;
    text-transform: uppercase;
}

.contract-top-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    align-content: center;
    align-items: center;
    gap: 8px;
}

.contract-top-actions form {
    margin: 0;
}

.contract-state-strip > .contract-top-actions {
    display: flex;
}

.contract-closure-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(130px, 1fr));
    gap: 10px;
    margin: 8px 0 0;
}

.contract-closure-summary div {
    border: 1px solid #cfe2ff;
    border-radius: 8px;
    background: rgba(255, 255, 255, .72);
    padding: 10px 12px;
}

.contract-closure-summary dt,
.contract-closure-summary dd {
    margin: 0;
}

.contract-closure-summary dt {
    color: #516680;
    font-size: .72rem;
    font-weight: 900;
    text-transform: uppercase;
}

.contract-closure-summary dd {
    margin-top: 4px;
    color: #001b3d;
    font-size: .88rem;
    font-weight: 800;
}

.contract-closure-summary-full {
    grid-column: 1 / -1;
}

.contract-closure-modal,
.contract-cycle-modal {
    width: min(760px, calc(100vw - 32px));
    max-height: calc(100vh - 48px);
    overflow-y: auto;
    border: 1px solid #b7dce8;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 28px 70px rgba(15, 35, 55, .24);
}

.contract-closure-modal header,
.contract-closure-modal footer,
.contract-cycle-modal header,
.contract-cycle-modal footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 18px 20px;
}

.contract-closure-modal header,
.contract-cycle-modal header {
    border-bottom: 1px solid #d8e6ee;
}

.contract-closure-modal header h2,
.contract-cycle-modal header h2 {
    margin: 2px 0 0;
    color: var(--text);
    font-size: 1.28rem;
}

.contract-closure-modal header a,
.contract-cycle-modal header a {
    color: #516680;
    font-size: 1.2rem;
    font-weight: 900;
    text-decoration: none;
}

.contract-closure-modal p {
    margin: 0;
    padding: 18px 20px 0;
    color: #294969;
}

.contract-closure-modal .contract-fields-grid,
.contract-cycle-modal .contract-fields-grid {
    padding: 18px 20px;
}

.contract-closure-modal footer,
.contract-cycle-modal footer {
    border-top: 1px solid #d8e6ee;
}

.contract-form-grid {
    display: grid;
    gap: 16px;
    margin-bottom: 16px;
}

.contract-card + .contract-form-grid {
    margin-top: 16px;
}

.contract-form-grid.two {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.contract-fields-grid {
    display: grid;
    gap: 12px;
    margin-top: 14px;
}

.contract-fields-grid.two {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.contract-fields-grid.three {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.contract-fields-grid.four {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.contract-fields-grid .contract-full-field {
    grid-column: 1 / -1;
}

.contract-status-meter {
    display: grid;
    gap: 8px;
    margin-top: 14px;
    border: 1px solid #cfe2ff;
    border-radius: 8px;
    background: #f7fbff;
    padding: 12px;
}

.contract-status-meter span {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    color: #516680;
    font-size: .78rem;
    font-weight: 800;
}

.contract-status-meter em {
    color: #004dff;
    font-style: normal;
}

.contract-product-row {
    display: grid;
    grid-template-columns: minmax(280px, 420px) minmax(260px, 1fr);
    align-items: start;
    gap: 12px;
    margin-top: 14px;
}

.contract-product-row article {
    border: 1px solid #cfe2ff;
    border-radius: 8px;
    background: #f5f8ff;
    padding: 14px;
}

.contract-primary-product p {
    margin: 0 0 10px;
    color: #516680;
    font-size: .82rem;
    font-weight: 800;
}

.contract-product-row label,
.contract-service-adder label {
    display: grid;
    gap: 7px;
    color: #516680;
    font-size: .78rem;
    font-weight: 800;
}

.contract-product-select {
    width: 100%;
    min-height: 42px;
    min-width: 0;
    border: 1px solid #cfdae8;
    border-radius: 8px;
    background: #fff;
    color: #001b3d;
    padding: 9px 12px;
    font-weight: 800;
}

.contract-service-adder {
    display: grid;
    grid-template-columns: minmax(180px, 1fr) auto;
    gap: 10px;
    align-items: end;
}

.contract-services-panel {
    display: grid;
    gap: 14px;
    align-content: start;
}

.contract-service-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    min-height: 34px;
}

.contract-service-chip {
    border: 1px solid #bdebdc;
    background: #eafff7;
    color: #007a51;
    gap: 8px;
}

.contract-service-chip button {
    display: inline-grid;
    place-items: center;
    width: 20px;
    height: 20px;
    border: 1px solid rgba(0, 122, 81, .22);
    border-radius: 999px;
    background: #fff;
    color: #007a51;
    cursor: pointer;
    font-size: .78rem;
    font-weight: 900;
    line-height: 1;
}

.contract-service-chip button:hover,
.contract-service-chip button:focus-visible {
    border-color: #00a36c;
    background: #dff8ee;
}

.contract-cycle-list,
.contract-document-list,
.contract-interaction-list {
    display: grid;
    gap: 11px;
    margin-top: 14px;
}

.contract-cycle-card,
.contract-document-list article {
    display: grid;
    align-items: center;
    border: 1px solid #dfe8f1;
    border-radius: 8px;
    transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease, background .18s ease;
}

.contract-cycle-card {
    grid-template-columns: 46px minmax(0, 1fr) auto auto;
    gap: 11px;
    padding: 10px 13px;
}

.contract-cycle-card.is-expanded {
    border-color: #9fc0ff;
    background: #f8fbff;
    padding-block: 12px;
}

.contract-cycle-card > strong {
    display: grid;
    min-height: 34px;
    min-width: 42px;
    place-items: center;
    border-radius: 8px;
    background: #edf4ff;
    color: #004dff;
    font-size: .84rem;
}

.contract-cycle-card h3 {
    font-size: .95rem;
    line-height: 1.2;
    margin: 0 0 4px;
}

.contract-cycle-card p {
    font-size: .8rem;
    line-height: 1.25;
    margin: 0;
}

.contract-cycle-card .contract-cycle-status {
    min-height: 24px;
    padding: 4px 9px;
    font-size: .68rem;
}

.contract-cycle-card > .button-small {
    min-height: 30px;
    padding: 5px 10px;
    font-size: .8rem;
}

.contract-document-list article {
    align-items: stretch;
    gap: 8px;
    grid-template-columns: minmax(0, 1fr);
    padding: 14px 16px;
}

.contract-cycle-expanded {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    border-top: 1px solid #dbe6ef;
    padding-top: 14px;
}

.contract-cycle-expanded article {
    display: grid;
    gap: 6px;
    border: 1px solid #dfe8f1;
    border-radius: 8px;
    background: #fff;
    padding: 12px;
}

.contract-cycle-expanded span {
    color: #516680;
    font-size: .72rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.contract-cycle-linked-list {
    display: grid;
    gap: 5px;
    min-width: 0;
}

.contract-cycle-linked-list a,
.contract-cycle-linked-list strong {
    color: #001b3d;
    font-size: .88rem;
    line-height: 1.25;
    overflow-wrap: anywhere;
}

.contract-cycle-linked-list a {
    text-decoration: none;
}

.contract-cycle-linked-list a:hover,
.contract-cycle-linked-list a:focus-visible {
    color: #0057c2;
    text-decoration: underline;
}

.contract-cycle-expanded-actions {
    grid-column: 1 / -1;
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.contract-cycle-meta-line {
    color: #365775;
    display: block;
    font-size: .74rem;
    line-height: 1.25;
    margin-top: 4px;
    overflow-wrap: anywhere;
}

.contract-document-row-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
    align-items: start;
}

.contract-document-row-head > div:first-child {
    min-width: 0;
}

.contract-document-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
    max-width: 100%;
}

.contract-document-summary {
    display: grid;
    gap: 4px;
    min-width: 0;
    padding-right: 4px;
}

.contract-document-name {
    color: #001b3d;
    display: block;
    font-size: 1rem;
    font-weight: 900;
    line-height: 1.25;
    text-decoration: none;
}

a.contract-document-name:hover,
a.contract-document-name:focus-visible {
    color: #0057c2;
    text-decoration: underline;
}

.contract-document-badge {
    align-self: start;
    border-radius: 999px;
    background: #dff8ee;
    color: #007a51;
    font-size: .76rem;
    font-weight: 900;
    padding: 7px 12px;
    white-space: nowrap;
}

.contract-cycle-badge {
    align-items: center;
    border: 1px solid #8bb7ff;
    border-radius: 999px;
    background: #edf5ff;
    color: #004dff;
    display: inline-flex;
    font-size: .76rem;
    font-weight: 900;
    justify-self: start;
    line-height: 1.15;
    min-height: 26px;
    padding: 5px 10px;
    white-space: nowrap;
}

.contract-document-description {
    color: #163b5c;
    font-size: .86rem;
    line-height: 1.4;
    margin: 0;
    max-width: 62ch;
}

.contract-document-description b {
    color: #001b3d;
    font-weight: 900;
}

.contract-document-meta {
    color: #365775;
    display: block;
    font-size: .8rem;
    line-height: 1.35;
}

.contract-document-list nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    align-items: center;
    gap: 8px;
    margin-top: 6px;
    padding-top: 8px;
}

.contract-file-type-badge {
    align-items: center;
    border-radius: 8px;
    background: #dff8ee;
    color: #007a51;
    display: inline-flex;
    font-size: .72rem;
    font-weight: 900;
    min-height: 38px;
    padding: 8px 12px;
}

.contract-document-list .inline-action-form {
    display: inline-flex;
}

.contract-empty-state {
    margin: 0;
    border: 1px dashed #bfd0df;
    border-radius: 8px;
    background: #f8fbff;
    color: #516680;
    padding: 14px;
}

.contract-document-list strong,
.contract-document-list small,
.contract-document-list p {
    overflow-wrap: anywhere;
}

.contract-interaction-list article {
    display: grid;
    gap: 7px;
    border-left: 3px solid #8fb8ff;
    border-radius: 0 8px 8px 0;
    background: #f4f7fc;
    padding: 12px 14px;
    transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease, background .18s ease;
}

.contract-interaction-list article strong,
.contract-interaction-list article p,
.contract-interaction-list article small {
    margin: 0;
}

.contract-interaction-row-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    align-items: start;
}

.contract-interaction-row-head strong {
    min-width: 0;
    overflow-wrap: anywhere;
}

.contract-interaction-file-badge {
    display: inline-flex;
    align-items: center;
    justify-self: start;
    max-width: 100%;
    min-height: 30px;
    border: 1px solid #38bdf8;
    border-radius: 999px;
    background: #e0f7ff;
    color: #006899;
    font-size: .78rem;
    font-weight: 900;
    overflow-wrap: anywhere;
    padding: 6px 12px;
    text-decoration: none;
}

.contract-interaction-file-badge:hover,
.contract-interaction-file-badge:focus-visible {
    border-color: #0284c7;
    background: #cff1ff;
    color: #004f75;
    box-shadow: 0 0 0 3px rgba(2, 132, 199, .14);
}

.contract-cycle-card:hover,
.contract-cycle-card:focus-within,
.contract-document-list article:hover,
.contract-document-list article:focus-within,
.contract-interaction-list article:hover,
.contract-interaction-list article:focus-within {
    border-color: #8fc4d6;
    background: #fbfeff;
    box-shadow: 0 16px 34px rgba(7, 86, 106, .12);
    transform: translateY(-1px);
}

.contract-inline-form {
    display: grid;
    gap: 14px;
    margin: 14px 0;
    border: 1px solid #9be7f5;
    border-radius: 8px;
    background: linear-gradient(135deg, #effdff, #fff);
    padding: 14px;
}

.contract-inline-form > div:first-child {
    display: grid;
    gap: 4px;
}

.contract-inline-form > div:first-child strong {
    color: #001b3d;
}

.contract-fake-file {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    border: 1px solid #c7ecf4;
    border-radius: 8px;
    background: #f8feff;
    padding: 10px;
}

.contract-fake-file > span {
    display: grid;
    width: 44px;
    height: 44px;
    place-items: center;
    border-radius: 8px;
    background: #dff8ee;
    color: #007a51;
    font-size: .72rem;
    font-weight: 900;
}

.contract-file-input {
    width: 100%;
    color: #34506b;
    font-size: .9rem;
}

.contract-file-input::file-selector-button {
    min-height: 38px;
    margin-right: 12px;
    border: 1px solid #9fc7df;
    border-radius: 8px;
    background: #fff;
    color: #004f6f;
    cursor: pointer;
    font-weight: 800;
    padding: 8px 14px;
    transition: border-color .18s ease, background .18s ease, color .18s ease, box-shadow .18s ease;
}

.contract-file-input:hover::file-selector-button,
.contract-file-input:focus-visible::file-selector-button {
    border-color: #0096c7;
    background: #e9fbff;
    color: #003f5c;
    box-shadow: 0 8px 18px rgba(0, 122, 160, .12);
}

.contract-inline-form footer {
    display: flex;
    justify-content: flex-end;
}

.contract-checkbox-line {
    display: flex;
    gap: 10px;
    align-items: center;
    border: 1px solid #dfe8f1;
    border-radius: 8px;
    background: #f8fafc;
    padding: 11px 12px;
    color: #516680;
    font-size: .82rem;
    font-weight: 800;
}

.contract-checkbox-line input {
    width: 16px;
    height: 16px;
}

.contract-history-box {
    margin: 16px 0;
    padding: 0;
}

.contract-history-box summary {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    cursor: pointer;
    padding: 16px 18px;
}

.contract-history-box p {
    margin: 0;
    padding: 0 18px 18px;
}

.contract-bottom-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-bottom: 24px;
}

@media (max-width: 1100px) {
    .contract-metrics,
    .contract-form-grid.two {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .contract-filter-panel,
    .contract-fields-grid.three,
    .contract-fields-grid.four {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 760px) {
    .contract-metrics,
    .contract-filter-panel,
    .contract-form-grid.two,
    .contract-fields-grid.two,
    .contract-fields-grid.three,
    .contract-fields-grid.four {
        grid-template-columns: 1fr;
    }

    .contract-hero-card,
    .contract-state-strip,
    .contract-status-meter span,
    .contract-history-box summary {
        display: grid;
    }

    .contract-top-actions,
    .contract-bottom-actions {
        display: grid;
        grid-template-columns: 1fr;
    }

    .contract-top-actions .button,
    .contract-bottom-actions .button {
        width: 100%;
    }

    .contract-card-head {
        display: grid;
    }

    .contract-card-head .button,
    .contract-card-head .contract-record-id {
        width: 100%;
    }

    .contracts-page-header {
        gap: 18px;
    }

    .contracts-page-header .page-actions {
        display: grid;
        grid-template-columns: 1fr;
        gap: 10px;
        width: 100%;
        margin-top: 6px;
    }

    .contracts-page-header .page-actions form {
        width: 100%;
    }

    .contracts-page-header .page-actions .button,
    .contracts-page-header .page-actions button {
        width: 100%;
        min-height: 44px;
    }

    .contract-cycle-card,
    .contract-document-list article {
        grid-template-columns: 1fr;
    }

    .contract-document-row-head,
    .contract-interaction-row-head {
        grid-template-columns: 1fr;
    }

    .contract-document-badges {
        justify-content: flex-start;
    }

    .contract-table-footer {
        display: grid;
    }

    .contract-table-footer > div {
        justify-content: stretch;
    }

    .contract-table-footer a {
        flex: 1;
    }

    .contract-cycle-expanded,
    .contract-fake-file,
    .contract-product-row,
    .contract-service-adder {
        grid-template-columns: 1fr;
    }

    .contract-cycle-expanded-actions,
    .contract-inline-form footer {
        display: grid;
        grid-template-columns: 1fr;
    }

    .contract-cycle-expanded-actions .button,
    .contract-inline-form footer .button {
        width: 100%;
    }
}

.campaigns-shell {
    display: grid;
    gap: 18px;
    background: #f2f7fa;
    min-width: 0;
    overflow-x: hidden;
}

.campaigns-shell *,
.campaigns-shell *::before,
.campaigns-shell *::after {
    box-sizing: border-box;
}

.campaigns-hero {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    min-width: 0;
}

.presentations-shell {
    display: grid;
    gap: 18px;
    background: #f2f7fa;
    min-width: 0;
    overflow-x: hidden;
}

.presentations-shell *,
.presentations-shell *::before,
.presentations-shell *::after {
    box-sizing: border-box;
}

.presentations-hero {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    min-width: 0;
}

.presentations-hero h1,
.presentation-card h2,
.presentation-next-panel h2 {
    margin: 4px 0;
    color: #082c40;
}

.presentations-hero h1 {
    font-size: 2rem;
    line-height: 1.05;
}

.presentations-hero p,
.presentation-card p,
.presentation-next-panel p {
    margin: 0;
    color: #39546a;
    line-height: 1.5;
}

.presentations-hero p {
    max-width: 820px;
}

.presentation-kicker {
    display: inline-flex;
    color: #0a6f85;
    font-size: .78rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.presentations-actions,
.presentation-card-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px;
}

.presentation-summary-grid,
.presentation-card-grid {
    display: grid;
    gap: 14px;
}

.presentation-summary-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.presentation-summary-grid article,
.presentation-filter-panel,
.presentation-card,
.presentation-next-panel,
.presentation-empty {
    border: 1px solid #bdd7e4;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 12px 34px rgba(10, 45, 67, .04);
}

.presentation-summary-grid article {
    padding: 16px 18px;
}

.presentation-summary-grid span,
.presentation-summary-grid small {
    display: block;
    color: #445f72;
}

.presentation-summary-grid span {
    font-size: .78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.presentation-summary-grid strong {
    display: block;
    margin: 4px 0;
    color: #0d6175;
    font-size: 1.45rem;
}

.presentation-filter-panel {
    padding: 14px;
}

.presentation-filter-panel form {
    display: grid;
    grid-template-columns: minmax(240px, 1fr) minmax(180px, 220px) auto;
    align-items: end;
    gap: 12px;
}

.presentation-filter-panel label {
    display: grid;
    gap: 6px;
    color: #38556a;
    font-size: .82rem;
    font-weight: 800;
}

.presentation-filter-panel input,
.presentation-filter-panel select {
    width: 100%;
    min-width: 0;
    border: 1px solid #bdd7e4;
    border-radius: 8px;
    padding: 10px 12px;
    color: #0a2d43;
    background: #fbfdfe;
    font: inherit;
}

.presentation-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.presentation-card {
    display: grid;
    align-content: start;
    gap: 14px;
    min-width: 0;
    padding: 20px;
}

.presentation-card header,
.presentation-card footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.presentation-card footer {
    color: #526b7c;
    font-size: .82rem;
}

.presentation-card-badges,
.presentation-section-badges {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 8px;
    min-width: 0;
}

.presentation-card h2 {
    font-size: 1.2rem;
}

.presentation-icon {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 8px;
    color: #0a2d43;
    font-weight: 900;
}

.presentation-icon.is-blue {
    background: #e8f2ff;
    color: #145ac8;
}

.presentation-icon.is-green {
    background: #e5f8f1;
    color: #04705e;
}

.presentation-icon.is-violet {
    background: #efeaff;
    color: #6231c7;
}

.presentation-icon.is-gold {
    background: #fff2d8;
    color: #8f5d00;
}

.presentation-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    padding: 6px 10px;
    font-size: .76rem;
    font-weight: 900;
}

.presentation-status.is-published {
    border: 1px solid #88dfb0;
    background: #dcf9e8;
    color: #08743e;
}

.presentation-status.is-draft {
    border: 1px solid #f0ca70;
    background: #fff4d8;
    color: #9b5d00;
}

.presentation-status.is-archived {
    border: 1px solid #c8d5de;
    background: #eef4f7;
    color: #52606b;
}

.presentation-status.is-preview {
    border: 1px solid #8dc8ff;
    background: #e8f3ff;
    color: #0e62ad;
}

.presentation-meta-list {
    display: grid;
    gap: 8px;
    margin: 0;
}

.presentation-meta-list div {
    display: grid;
    grid-template-columns: minmax(70px, .3fr) minmax(0, 1fr);
    gap: 10px;
    border: 1px solid #e0ebf1;
    border-radius: 8px;
    padding: 8px 10px;
    background: #fbfdfe;
}

.presentation-meta-list dt,
.presentation-meta-list dd {
    min-width: 0;
    margin: 0;
}

.presentation-meta-list dt {
    color: #617487;
    font-size: .75rem;
}

.presentation-meta-list dd {
    overflow: hidden;
    color: #0a2d43;
    font-weight: 800;
    text-align: right;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.presentation-step-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.presentation-step-strip span {
    border: 1px solid #bdd7e4;
    border-radius: 999px;
    background: #f2f8fb;
    color: #285268;
    padding: 6px 10px;
    font-size: .76rem;
    font-weight: 800;
}

.presentation-card-actions {
    justify-content: flex-start;
}

.presentation-empty {
    grid-column: 1 / -1;
    display: grid;
    gap: 4px;
    padding: 20px;
    color: #38556a;
}

.presentation-next-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(240px, 320px);
    gap: 18px;
    padding: 22px;
}

.presentation-next-panel ol {
    display: grid;
    align-content: start;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.presentation-next-panel li {
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    padding: 10px 12px;
    background: #fbfdfe;
    color: #0a2d43;
    font-weight: 900;
}

.presentation-form-hero,
.presentation-section-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    min-width: 0;
}

.presentation-form-hero h1,
.presentation-form-panel h2,
.presentation-assist-panel h2,
.presentation-mini-browser h2,
.presentation-flow-card h2 {
    margin: 4px 0;
    color: #082c40;
}

.presentation-form-hero h1 {
    font-size: 2rem;
    line-height: 1.05;
}

.presentation-form-hero .presentations-actions {
    min-width: 430px;
}

.presentation-form-hero p,
.presentation-section-head p,
.presentation-assist-panel p,
.presentation-mini-browser p {
    margin: 0;
    color: #39546a;
    line-height: 1.5;
}

.presentation-info-note,
.presentation-form-panel,
.presentation-form-aside,
.presentation-assist-panel {
    border: 1px solid #bdd7e4;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 12px 34px rgba(10, 45, 67, .04);
}

.presentation-info-note {
    display: grid;
    gap: 10px;
    padding: 18px;
    background: #eef7ff;
}

.presentation-info-note strong {
    color: #082c40;
}

.presentation-info-note span {
    color: #2f4d63;
}

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

.presentation-form-panel,
.presentation-form-aside,
.presentation-assist-panel {
    display: grid;
    gap: 16px;
    padding: 20px;
}

.presentation-step-badge {
    display: inline-flex;
    flex: 0 0 auto;
    border: 1px solid #bdd7e4;
    border-radius: 999px;
    background: #eef8fc;
    color: #0a5f76;
    padding: 6px 10px;
    font-size: .76rem;
    font-weight: 900;
}

.presentation-id-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    border: 1px solid #bdd7e4;
    border-radius: 999px;
    background: #f7fbfd;
    color: #0a5f76;
    padding: 6px 10px;
    font-size: .76rem;
    font-weight: 900;
}

.presentation-main-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.presentation-main-form label {
    display: grid;
    gap: 6px;
    color: #38556a;
    font-size: .82rem;
    font-weight: 800;
}

.presentation-main-form .is-wide {
    grid-column: 1 / -1;
}

.presentation-main-form input,
.presentation-main-form select,
.presentation-main-form textarea {
    width: 100%;
    min-width: 0;
    border: 1px solid #bdd7e4;
    border-radius: 8px;
    padding: 11px 12px;
    color: #0a2d43;
    background: #fbfdfe;
    font: inherit;
}

.presentation-main-form textarea {
    resize: vertical;
}

.presentation-mini-browser {
    overflow: hidden;
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    background: #fff;
}

.presentation-mini-browser > header {
    display: flex;
    gap: 6px;
    border-bottom: 1px solid #d7e5ec;
    padding: 12px;
    background: #eef4fb;
}

.presentation-mini-browser > header span {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: #ff6b57;
}

.presentation-mini-browser > header span:nth-child(2) {
    background: #ffbe2e;
}

.presentation-mini-browser > header span:nth-child(3) {
    background: #2ac05a;
}

.presentation-mini-browser > div {
    display: grid;
    gap: 12px;
    padding: 20px;
}

.presentation-mini-browser strong {
    color: #586b8c;
    line-height: 1.35;
}

.presentation-side-meta {
    display: grid;
    gap: 8px;
    margin: 0;
}

.presentation-side-meta div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    border: 1px solid #e0ebf1;
    border-radius: 8px;
    padding: 9px 10px;
    background: #fbfdfe;
}

.presentation-side-meta dt,
.presentation-side-meta dd {
    margin: 0;
}

.presentation-side-meta dt {
    color: #617487;
    font-size: .75rem;
}

.presentation-side-meta dd {
    min-width: 0;
    overflow: hidden;
    color: #0a2d43;
    font-weight: 900;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.presentation-flow-card {
    display: grid;
    gap: 12px;
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    background: #f8fcfd;
    padding: 14px;
}

.presentation-flow-card ol {
    display: grid;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.presentation-flow-card li {
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    background: #fff;
    color: #0a2d43;
    padding: 10px 12px;
    font-weight: 900;
}

.presentation-flow-card li.is-active {
    border-color: #89d7c8;
    background: #e3f8f2;
    color: #007368;
}

.presentation-assist-panel {
    grid-template-columns: minmax(0, .7fr) minmax(320px, 1fr);
    align-items: start;
}

.presentation-assist-options {
    display: grid;
    gap: 12px;
}

.presentation-assist-options label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    border: 1px solid #e0ebf1;
    border-radius: 8px;
    background: #fbfdfe;
    padding: 12px;
    color: #0a2d43;
}

.presentation-assist-options input {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    accent-color: #16a085;
}

.presentation-assist-options strong,
.presentation-assist-options small {
    display: block;
}

.presentation-assist-options small {
    margin-top: 3px;
    color: #587083;
}

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

.presentation-upload-main {
    display: grid;
    gap: 16px;
    min-width: 0;
}

.presentation-upload-panel,
.presentation-generated-panel {
    display: grid;
    gap: 16px;
    border: 1px solid #bdd7e4;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 12px 34px rgba(10, 45, 67, .04);
    padding: 20px;
}

.presentation-dropzone {
    position: relative;
    display: grid;
    place-items: center;
    min-height: 170px;
    border: 1px dashed #7fbde8;
    border-radius: 8px;
    background: linear-gradient(135deg, #f7fbff, #f1fbf7);
    color: #21465d;
    padding: 24px;
    text-align: center;
}

.presentation-dropzone input {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.presentation-dropzone span {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border-radius: 8px;
    background: #fff;
    color: #145ac8;
    font-size: 1.4rem;
    font-weight: 900;
}

.presentation-dropzone strong,
.presentation-dropzone small {
    display: block;
}

.presentation-dropzone strong {
    margin-top: 12px;
    color: #0a2d43;
    font-size: 1.1rem;
}

.presentation-dropzone small {
    margin-top: 4px;
    color: #587083;
}

.presentation-upload-options {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.presentation-upload-options label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    border: 1px solid #e0ebf1;
    border-radius: 8px;
    background: #fbfdfe;
    padding: 12px;
    color: #0a2d43;
}

.presentation-upload-options input {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    accent-color: #16a085;
}

.presentation-upload-options strong,
.presentation-upload-options small {
    display: block;
}

.presentation-upload-options small {
    margin-top: 3px;
    color: #587083;
}

.presentation-selected-files {
    display: grid;
    gap: 14px;
    border: 1px solid #bdd7e4;
    border-radius: 8px;
    background: #fbfdfe;
    padding: 16px;
}

.presentation-selected-files[hidden] {
    display: none;
}

.presentation-selected-files > header {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: flex-start;
}

.presentation-selected-files h3 {
    margin: 2px 0 4px;
    color: #082c40;
    font-size: 1.15rem;
}

.presentation-selected-files p {
    margin: 0;
    color: #38556a;
}

.presentation-selected-files > header > span {
    flex: 0 0 auto;
    border: 1px solid #a9d7ef;
    border-radius: 999px;
    background: #eaf7fd;
    color: #075f7c;
    padding: 7px 10px;
    font-weight: 900;
}

.presentation-generated-empty {
    display: grid;
    gap: 4px;
    border: 1px dashed #bdd7e4;
    border-radius: 8px;
    background: #fbfdfe;
    padding: 18px;
    color: #38556a;
    text-align: center;
}

.presentation-generated-list {
    display: grid;
    gap: 10px;
}

.presentation-generated-list article {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    background: #fff;
    padding: 10px;
    transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

.presentation-generated-list article:hover {
    border-color: #7cc7ee;
    box-shadow: 0 10px 22px rgba(10, 45, 67, .08);
    transform: translateY(-1px);
}

.presentation-generated-list article.is-updating {
    opacity: .6;
    pointer-events: none;
}

.presentation-generated-list em,
.presentation-generated-list strong,
.presentation-generated-list small {
    display: block;
    min-width: 0;
}

.presentation-generated-list em {
    width: fit-content;
    border: 1px solid #a9d7ef;
    border-radius: 999px;
    background: #e4f6fd;
    color: #08627e;
    padding: 4px 8px;
    font-size: .7rem;
    font-style: normal;
    font-weight: 900;
}

.presentation-generated-list strong {
    margin-top: 6px;
    color: #082c40;
}

.presentation-generated-list small {
    color: #587083;
}

.presentation-thumb {
    display: block;
    width: 84px;
    height: 52px;
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    background:
        linear-gradient(90deg, rgba(255, 255, 255, .88), rgba(255, 255, 255, .2)),
        repeating-linear-gradient(0deg, rgba(10, 45, 67, .08), rgba(10, 45, 67, .08) 4px, transparent 4px, transparent 10px);
}

.presentation-thumb.is-blue {
    background-color: #dcebff;
}

.presentation-thumb.is-green {
    background-color: #dff8ed;
}

.presentation-thumb.is-violet {
    background-color: #ede7ff;
}

.presentation-thumb.is-gold {
    background-color: #ffe3b5;
}

.presentation-thumb.is-rose {
    background-color: #ffdede;
}

.presentation-thumb-button {
    display: block;
    width: 84px;
    height: 52px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    padding: 0;
    cursor: pointer;
}

.presentation-thumb-image {
    display: block;
    width: 84px;
    height: 52px;
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    background: #f4f8fa;
    object-fit: cover;
}

.presentation-thumb-button:hover .presentation-thumb-image,
.presentation-thumb-button:focus-visible .presentation-thumb-image {
    border-color: #5ab7e8;
    box-shadow: 0 0 0 3px rgba(90, 183, 232, .16);
}

.presentation-reorder-actions {
    display: flex;
    gap: 8px;
}

.presentation-reorder-actions button {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border: 1px solid #bdd7e4;
    border-radius: 999px;
    background: #fff;
    color: #0a2d43;
    font: inherit;
    font-weight: 900;
    cursor: pointer;
}

.presentation-reorder-actions .is-preview {
    width: auto;
    min-width: 96px;
    border-radius: 8px;
    padding: 0 12px;
    color: #0a5f76;
}

.presentation-reorder-actions .is-preview:hover {
    background: #eef8fc;
}

.presentation-reorder-actions button:hover,
.presentation-reorder-actions button:focus-visible {
    border-color: #7cc7ee;
    background: #eef8fc;
}

.presentation-reorder-actions button:disabled {
    cursor: not-allowed;
    opacity: .45;
}

.presentation-image-modal[hidden] {
    display: none;
}

.presentation-image-modal {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: grid;
    place-items: center;
    padding: 16px;
}

.presentation-image-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(10, 32, 45, .62);
    backdrop-filter: blur(5px);
}

.presentation-image-modal__panel {
    position: relative;
    z-index: 1;
    display: grid;
    gap: 14px;
    box-sizing: border-box;
    width: min(960px, calc(100vw - 32px));
    max-height: 92vh;
    border: 1px solid #bdd7e4;
    border-radius: 8px;
    background: #fff;
    padding: 16px;
    box-shadow: 0 28px 70px rgba(10, 45, 67, .28);
}

@media (max-width: 520px) {
    .presentation-image-modal {
        align-items: center;
        padding: 12px;
    }

    .presentation-image-modal__panel {
        width: calc(100vw - 24px);
        padding: 14px;
    }
}

.presentation-image-modal__panel header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.presentation-image-modal__panel h2 {
    margin: 0;
    color: #082c40;
    font-size: 1.1rem;
}

.presentation-image-modal__panel header button {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border: 1px solid #bdd7e4;
    border-radius: 999px;
    background: #fff;
    color: #0a2d43;
    cursor: pointer;
    font: inherit;
    font-weight: 900;
}

.presentation-image-modal__panel div {
    overflow: auto;
    max-height: calc(92vh - 88px);
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    background: #f4f8fa;
}

.presentation-image-modal__panel img {
    display: block;
    width: 100%;
    height: auto;
}

.presentation-image-modal__nav {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
}

.presentation-image-modal__nav button {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border: 1px solid #bdd7e4;
    border-radius: 999px;
    background: #fff;
    color: #0a2d43;
    cursor: pointer;
    font: inherit;
    font-size: 1.45rem;
    font-weight: 900;
}

.presentation-image-modal__nav button:hover,
.presentation-image-modal__nav button:focus-visible {
    border-color: #7cc7ee;
    background: #eef8fc;
}

.presentation-image-modal__nav button:disabled {
    cursor: not-allowed;
    opacity: .45;
}

.presentation-image-modal__nav span {
    color: #486275;
    font-size: .86rem;
    font-weight: 800;
}

.presentation-upload-preview > div {
    min-height: 150px;
    place-items: center;
    background: #071925;
    color: #c9daea;
    text-align: center;
}

.presentation-validation-panel {
    align-content: start;
}

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

.presentation-validation-summary article {
    display: grid;
    gap: 4px;
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    background: #fbfdfe;
    padding: 14px;
}

.presentation-validation-summary strong {
    color: #082c40;
    font-size: 1.35rem;
    line-height: 1;
}

.presentation-validation-summary span {
    color: #587083;
    font-size: .82rem;
}

.presentation-policy-note {
    border: 1px dashed #9ac7ef;
    border-radius: 8px;
    background: #f7fbff;
    color: #486880;
    padding: 12px;
    font-size: .88rem;
}

.presentation-validation-list {
    display: grid;
    gap: 8px;
}

.presentation-validation-list article {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    background: #fcfffd;
    padding: 12px;
}

.presentation-validation-list article.is-rejected {
    border-color: #f1b7b7;
    background: #fff8f8;
}

.presentation-validation-list strong,
.presentation-validation-list span {
    display: block;
}

.presentation-validation-list strong {
    color: #082c40;
}

.presentation-validation-list span {
    margin-top: 4px;
    color: #587083;
    font-size: .82rem;
}

.presentation-file-status {
    text-align: right;
    white-space: nowrap;
}

.presentation-file-status strong {
    color: #0a6d4f;
}

.presentation-optimization-card {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    background: #fbfdfe;
    padding: 12px;
    color: #0a2d43;
}

.presentation-optimization-card input {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    accent-color: #16a085;
}

.presentation-optimization-card strong,
.presentation-optimization-card small {
    display: block;
}

.presentation-optimization-card small {
    margin-top: 3px;
    color: #587083;
}

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

.presentation-upload-modal[hidden] {
    display: none;
}

.presentation-upload-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(8, 28, 43, .52);
    backdrop-filter: blur(3px);
}

.presentation-upload-modal__panel {
    position: relative;
    z-index: 1;
    display: grid;
    gap: 14px;
    width: min(520px, 100%);
    border: 1px solid #bdd7e4;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 24px 70px rgba(8, 28, 43, .22);
    padding: 26px;
}

.presentation-upload-modal__panel h2,
.presentation-upload-modal__panel p {
    margin: 0;
}

.presentation-upload-modal__panel h2 {
    color: #082c40;
    font-size: 1.4rem;
}

.presentation-upload-modal__panel p {
    color: #39546a;
    line-height: 1.45;
}

.presentation-upload-modal__meter {
    overflow: hidden;
    height: 12px;
    border: 1px solid #bdd7e4;
    border-radius: 999px;
    background: #eef8fc;
}

.presentation-upload-modal__meter span {
    display: block;
    width: 0;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #0b6b89, #18b99f);
    transition: width .22s ease;
}

.presentation-upload-modal__summary,
.presentation-upload-modal__actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.presentation-upload-modal__summary strong {
    color: #082c40;
    font-size: 1.05rem;
}

.presentation-upload-modal__summary span {
    color: #0a5f76;
    font-weight: 900;
}

.presentation-upload-modal__success {
    display: grid;
    gap: 4px;
    border: 1px solid #88dfb0;
    border-radius: 8px;
    background: #dcf9e8;
    color: #08743e;
    padding: 12px;
}

.presentation-upload-modal__success[hidden] {
    display: none;
}

.presentation-upload-modal__success strong,
.presentation-upload-modal__success span {
    display: block;
}

.presentation-upload-modal__success span {
    color: #24634a;
    font-size: .88rem;
}

.presentation-upload-modal__actions {
    justify-content: flex-end;
    margin-top: 4px;
}

.presentation-upload-modal__actions [hidden] {
    display: none;
}

.presentation-editor-layout {
    display: grid;
    grid-template-columns: minmax(250px, 310px) minmax(0, 1fr) minmax(290px, 340px);
    gap: 16px;
    align-items: start;
}

.presentation-editor-main {
    width: auto;
    min-width: 0;
    margin: 0;
    scroll-margin-top: 24px;
}

.presentation-editor-steps,
.presentation-editor-panel {
    display: grid;
    gap: 16px;
    align-content: start;
    align-self: start;
    border: 1px solid #bdd7e4;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 12px 34px rgba(10, 45, 67, .04);
    padding: 20px;
}

.presentation-editor-step-list {
    display: grid;
    gap: 10px;
}

.presentation-editor-step-list article,
.presentation-editor-step-list a {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    background: #fff;
    color: inherit;
    text-decoration: none;
    padding: 10px;
    cursor: pointer;
    transition: background-color .16s ease, border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

.presentation-editor-step-list article.is-selected,
.presentation-editor-step-list a.is-selected {
    border-color: #7fbde8;
    background: #f2f9ff;
}

.presentation-editor-step-list article:hover,
.presentation-editor-step-list article:focus-within,
.presentation-editor-step-list a:hover,
.presentation-editor-step-list a:focus-visible {
    border-color: #67bce8;
    background: #f5fbff;
    box-shadow: 0 10px 22px rgba(10, 45, 67, .08);
    transform: translateY(-1px);
}

.presentation-editor-step-list article.is-selected:hover,
.presentation-editor-step-list article.is-selected:focus-within,
.presentation-editor-step-list a.is-selected:hover,
.presentation-editor-step-list a.is-selected:focus-visible {
    border-color: #2f9fe3;
    background: #eaf6ff;
}

.presentation-editor-step-list em,
.presentation-editor-step-list strong,
.presentation-editor-step-list small {
    display: block;
    min-width: 0;
}

.presentation-editor-step-list em {
    width: fit-content;
    border: 1px solid #a9d7ef;
    border-radius: 999px;
    background: #e4f6fd;
    color: #08627e;
    padding: 4px 8px;
    font-size: .68rem;
    font-style: normal;
    font-weight: 900;
}

.presentation-editor-step-list strong {
    margin-top: 6px;
    color: #082c40;
}

.presentation-editor-step-list small {
    color: #587083;
    font-size: .78rem;
}

.presentation-stage {
    border-radius: 8px;
    background: #071925;
    padding: 22px;
}

.presentation-stage-screen {
    display: grid;
    place-items: center;
    min-height: 300px;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 8px;
    background:
        linear-gradient(90deg, rgba(7, 25, 37, .98), rgba(7, 25, 37, .9) 18%, rgba(255, 255, 255, .08) 18%, rgba(255, 255, 255, .08) 82%, rgba(7, 25, 37, .9) 82%, rgba(7, 25, 37, .98)),
        linear-gradient(135deg, rgba(255, 255, 255, .08), rgba(255, 255, 255, 0));
}

.presentation-stage-screen.is-blue {
    background-color: #0b335c;
}

.presentation-stage-screen.is-green {
    background-color: #063b37;
}

.presentation-stage-screen.is-violet {
    background-color: #2d2559;
}

.presentation-stage-screen.is-gold {
    background-color: #543808;
}

.presentation-stage-screen.is-rose {
    background-color: #5a2532;
}

.presentation-stage-window {
    width: min(480px, 82%);
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 36px rgba(0, 0, 0, .24);
    overflow: hidden;
}

.presentation-stage-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-bottom: 1px solid #e0ebf1;
    background: #f7fbff;
    padding: 12px 14px;
    color: #0a2d43;
}

.presentation-stage-topbar span {
    border: 1px solid #a7e3d4;
    border-radius: 8px;
    background: #e7faf3;
    color: #007368;
    padding: 5px 8px;
    font-size: .72rem;
    font-weight: 800;
}

.presentation-stage-content {
    display: grid;
    gap: 12px;
    padding: 28px;
    color: #0a2d43;
}

.presentation-stage-content span {
    width: fit-content;
    border: 1px solid #a9d7ef;
    border-radius: 999px;
    background: #e4f6fd;
    color: #08627e;
    padding: 4px 8px;
    font-size: .72rem;
    font-weight: 900;
}

.presentation-stage-content h3,
.presentation-stage-content p {
    margin: 0;
}

.presentation-stage-content button {
    justify-self: start;
    border: 0;
    border-radius: 8px;
    background: #0b5db8;
    color: #fff;
    padding: 10px 14px;
    font: inherit;
    font-weight: 900;
}

.presentation-stage-image-frame {
    width: min(620px, 92%);
    aspect-ratio: 16 / 9;
    display: grid;
    place-items: center;
    border-radius: 8px;
    background: rgba(255, 255, 255, .08);
    box-shadow: 0 18px 36px rgba(0, 0, 0, .24);
    overflow: hidden;
}

.presentation-stage-preview-button {
    border: 0;
    padding: 0;
    color: inherit;
    cursor: zoom-in;
}

.presentation-stage-preview-button:hover,
.presentation-stage-preview-button:focus-visible {
    outline: 2px solid #7cc7ee;
    outline-offset: 3px;
}

.presentation-stage-image-frame img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #061722;
}

.presentation-editor-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.presentation-editor-form label {
    display: grid;
    gap: 7px;
    color: #21465d;
    font-size: .82rem;
    font-weight: 800;
}

.presentation-editor-form .is-wide {
    grid-column: 1 / -1;
}

.presentation-editor-form input,
.presentation-editor-form select,
.presentation-editor-form textarea {
    width: 100%;
    border: 1px solid #bdd7e4;
    border-radius: 8px;
    background: #fbfdfe;
    color: #0a2d43;
    font: inherit;
    font-weight: 700;
    padding: 10px 12px;
}

.presentation-editor-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px;
}

.presentation-editor-preview > div {
    gap: 10px;
}

@media (max-width: 1500px) {
    .presentation-editor-layout {
        grid-template-columns: minmax(250px, 310px) minmax(0, 1fr);
    }

    .presentation-editor-aside {
        grid-column: 1 / -1;
    }

    .presentation-preview-layout {
        grid-template-columns: minmax(0, 1fr);
    }
}

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

.presentation-preview-main {
    width: auto;
    min-width: 0;
    margin: 0;
}

.presentation-premium-card {
    display: grid;
    gap: 24px;
    border: 1px solid #bdd7e4;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 16px 42px rgba(10, 45, 67, .06);
    padding: 20px;
}

.presentation-premium-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    border-bottom: 1px solid #dce8ef;
    padding-bottom: 18px;
}

.presentation-premium-topbar div,
.presentation-premium-topbar nav {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.presentation-premium-topbar strong {
    color: #082c40;
    font-size: 1.1rem;
}

.presentation-premium-topbar div span {
    border-left: 1px solid #d7e5ec;
    color: #536c80;
    padding-left: 10px;
    font-size: .82rem;
}

.presentation-premium-topbar nav span {
    border: 1px solid #bdd7e4;
    border-radius: 999px;
    background: #eef8fc;
    color: #0a5f76;
    padding: 7px 12px;
    font-size: .82rem;
    font-weight: 900;
}

.presentation-premium-topbar nav span:last-child {
    border-color: #8ddcc8;
    background: #e3f8f2;
    color: #007368;
}

.presentation-premium-body {
    display: grid;
    grid-template-columns: minmax(240px, .8fr) minmax(0, 1.25fr);
    gap: 28px;
    align-items: center;
}

.presentation-premium-copy {
    display: grid;
    gap: 18px;
    min-width: 0;
}

.presentation-premium-copy h2 {
    margin: 0;
    color: #101828;
    font-size: clamp(2.2rem, 4vw, 4rem);
    line-height: 1.04;
}

.presentation-premium-copy strong {
    color: #5f6f8b;
    font-size: 1.15rem;
    line-height: 1.35;
}

.presentation-premium-copy p {
    margin: 0;
    color: #2f4d63;
    line-height: 1.65;
}

.presentation-premium-display {
    position: relative;
    display: grid;
    gap: 14px;
    min-width: 0;
}

.presentation-premium-display .presentation-stage {
    box-shadow: 0 18px 44px rgba(10, 45, 67, .16);
}

.presentation-premium-caption {
    display: grid;
    gap: 6px;
}

.presentation-premium-caption span {
    width: fit-content;
    border: 1px solid #a9d7ef;
    border-radius: 999px;
    background: #e4f6fd;
    color: #08627e;
    padding: 4px 8px;
    font-size: .72rem;
    font-weight: 900;
}

.presentation-premium-caption h3,
.presentation-premium-caption p {
    margin: 0;
}

.presentation-premium-caption h3 {
    color: #082c40;
    font-size: 1.35rem;
}

.presentation-premium-caption p {
    color: #39546a;
    line-height: 1.45;
}

.presentation-premium-nav {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.presentation-premium-nav a,
.presentation-premium-nav span,
.presentation-premium-nav button {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border: 1px solid #d7e5ec;
    border-radius: 999px;
    background: #fff;
    color: #0a5f76;
    font: inherit;
    font-size: 1.35rem;
    font-weight: 900;
    text-decoration: none;
}

.presentation-premium-nav span {
    opacity: .45;
}

.presentation-premium-strip {
    display: grid;
    grid-template-columns: repeat(5, minmax(120px, 1fr));
    gap: 10px;
    overflow-x: auto;
    padding: 2px 0;
}

.presentation-premium-strip article {
    display: grid;
    gap: 8px;
    min-width: 120px;
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    background: #f8fcfd;
    padding: 10px;
    cursor: pointer;
    transition: background-color .16s ease, border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

.presentation-premium-strip article a {
    display: grid;
    gap: 8px;
    color: inherit;
    text-decoration: none;
}

.presentation-premium-strip article.is-selected {
    border-color: #5aaeff;
    background: #e7f2ff;
    box-shadow: inset 0 -3px 0 #216bff;
}

.presentation-premium-strip article:hover,
.presentation-premium-strip article:focus-within {
    border-color: #67bce8;
    background: #f5fbff;
    box-shadow: 0 10px 22px rgba(10, 45, 67, .08);
    transform: translateY(-1px);
}

.presentation-premium-strip article.is-selected:hover,
.presentation-premium-strip article.is-selected:focus-within {
    border-color: #2f9fe3;
    background: #eaf6ff;
    box-shadow: inset 0 -3px 0 #216bff, 0 10px 22px rgba(10, 45, 67, .08);
}

.presentation-premium-strip .presentation-thumb {
    width: 100%;
    height: 52px;
}

.presentation-premium-strip strong {
    overflow: hidden;
    color: #082c40;
    font-size: .82rem;
    text-align: center;
    text-overflow: ellipsis;
    white-space: nowrap;
}

@media (max-width: 1500px) {
    .presentation-preview-layout {
        grid-template-columns: minmax(0, 1fr);
    }
}

.presentation-public-link-card {
    display: grid;
    gap: 12px;
    border: 1px solid #d2e4ee;
    border-radius: 8px;
    background: #f8fcfe;
    padding: 16px;
}

.presentation-public-link-card h2 {
    margin: 0;
    color: #082c40;
    font-size: 1.05rem;
}

.presentation-public-link-card p,
.presentation-card-public-link span {
    margin: 0;
    color: #3f5b6f;
    font-size: .9rem;
    line-height: 1.45;
}

.presentation-public-link-card label,
.presentation-card-public-link label {
    display: grid;
    gap: 6px;
    min-width: 0;
    color: #38556a;
    font-size: .78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.presentation-public-link-card input,
.presentation-card-public-link input {
    width: 100%;
    min-width: 0;
    border: 1px solid #bdd7e4;
    border-radius: 7px;
    background: #ffffff;
    color: #082c40;
    font: inherit;
    font-size: .82rem;
    padding: 10px 11px;
}

.presentation-public-link-actions,
.presentation-card-public-link {
    display: flex;
    flex-wrap: wrap;
    align-items: end;
    gap: 8px;
    min-width: 0;
}

.presentation-public-link-actions form {
    margin: 0;
}

.presentation-card-public-link {
    align-items: center;
    border: 1px solid #dbe9f0;
    border-radius: 8px;
    background: #f8fcfe;
    padding: 10px;
}

.presentation-card-public-link label {
    flex: 1 1 260px;
    text-transform: none;
}

.presentation-public-page {
    min-height: 100vh;
    margin: 0;
    background: #fdfefe;
    color: #1f2937;
}

.presentation-public-shell {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto auto;
    gap: 20px;
    min-height: 100svh;
    width: min(1320px, calc(100% - 96px));
    max-width: none;
    margin: 0 auto;
    padding: 26px 0 22px;
}

.presentation-public-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    border-bottom: 1px solid #dde8ef;
    padding-bottom: 12px;
}

.presentation-public-header div,
.presentation-public-header nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

.presentation-public-header strong {
    color: #082c40;
    font-size: 1.18rem;
}

.presentation-public-header span,
.presentation-public-header nav span {
    color: #38556a;
}

.presentation-public-header nav span {
    border: 1px solid #9fd8e5;
    border-radius: 999px;
    background: #eefaff;
    color: #075c73;
    font-weight: 800;
    padding: 8px 15px;
}

.presentation-public-header nav span:last-child {
    border-color: #8ddacb;
    background: #e9fbf5;
    color: #07715d;
}

.presentation-public-stage {
    display: grid;
    grid-template-columns: minmax(320px, 410px) minmax(560px, 840px);
    justify-content: space-between;
    gap: clamp(40px, 5vw, 76px);
    align-items: center;
    min-width: 0;
    padding: clamp(4px, 2.2vh, 24px) 0 0;
}

.presentation-public-copy {
    display: grid;
    gap: 12px;
    align-content: center;
}

.presentation-public-copy span,
.presentation-public-caption span,
.presentation-public-step-summary span {
    color: #0a6f85;
    font-size: .82rem;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.presentation-public-copy h1 {
    margin: 0;
    color: #172033;
    font-size: clamp(2.8rem, 4.4vw, 4.65rem);
    line-height: 1.04;
}

.presentation-public-copy strong {
    color: #52637c;
    font-size: 1.08rem;
    line-height: 1.45;
}

.presentation-public-copy p {
    margin: 0;
    color: #3f4e63;
    font-size: .98rem;
    line-height: 1.58;
}

.presentation-public-media {
    display: grid;
    gap: 14px;
    min-width: 0;
    filter: drop-shadow(0 28px 56px rgba(23, 42, 64, .15));
}

.presentation-public-window {
    overflow: hidden;
    border: 1px solid #d5e1e8;
    border-radius: 22px;
    background: #eef3f6;
}

.presentation-public-window header {
    display: flex;
    align-items: center;
    gap: 7px;
    height: 32px;
    border-bottom: 1px solid #d8e5ec;
    background: #f2f7fa;
    padding: 0 16px;
}

.presentation-public-window header span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #ff7a45;
}

.presentation-public-window header span:nth-child(2) {
    background: #ffbf45;
}

.presentation-public-window header span:nth-child(3) {
    background: #35bd64;
}

.presentation-public-image-button {
    display: block;
    width: 100%;
    border: 0;
    background: transparent;
    padding: 0;
    cursor: zoom-in;
}

.presentation-public-image-button:focus-visible {
    outline: 3px solid #7ab7ff;
    outline-offset: -3px;
}

.presentation-public-media img {
    display: block;
    width: 100%;
    height: min(50vh, 500px);
    max-height: 500px;
    object-fit: contain;
    background: #071320;
}

.presentation-public-placeholder {
    display: grid;
    place-items: center;
    min-height: 360px;
    border-radius: 12px;
    background: #eef7fb;
    text-align: center;
}

.presentation-public-placeholder h2 {
    margin: 8px 0 0;
    color: #082c40;
}

.presentation-public-step-summary {
    display: grid;
    gap: 5px;
    max-width: 760px;
}

.presentation-public-step-summary h2 {
    margin: 0;
    color: #082c40;
    font-size: 1.34rem;
    line-height: 1.2;
}

.presentation-public-step-summary p {
    margin: 0;
    color: #38556a;
    font-size: .98rem;
    line-height: 1.48;
}

.presentation-public-caption {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    border-top: 1px solid #e1edf3;
    padding-top: 14px;
}

.presentation-public-caption h2 {
    margin: 4px 0 0;
    color: #082c40;
    font-size: 1.22rem;
}

.presentation-public-caption nav {
    display: flex;
    gap: 10px;
}

.presentation-public-caption a,
.presentation-public-caption nav span {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #e6f1ff;
    color: #0c63b7;
    font-size: 2rem;
    font-weight: 800;
    text-decoration: none;
}

.presentation-public-caption nav span {
    opacity: .45;
}

.presentation-public-strip {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(176px, 202px);
    gap: 12px;
    overflow-x: auto;
    padding: 0 0 8px;
    scroll-snap-type: x proximity;
}

.presentation-public-strip a {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 76px;
    align-items: stretch;
    gap: 10px;
    min-height: 68px;
    border: 2px solid transparent;
    border-radius: 16px;
    background: #eef7fb;
    color: #1f2937;
    padding: 10px;
    text-decoration: none;
    scroll-snap-align: start;
}

.presentation-public-strip a.is-selected {
    border-color: #2b7cff;
    background: #dbeafe;
}

.presentation-public-strip img {
    order: 2;
    width: 76px;
    height: 48px;
    object-fit: cover;
    align-self: center;
    border-radius: 10px;
}

.presentation-public-strip span {
    display: -webkit-box;
    align-self: center;
    min-width: 0;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    font-size: .92rem;
    font-weight: 700;
    line-height: 1.2;
}

.presentation-public-zoom-modal .presentation-image-modal__panel {
    width: min(1480px, calc(100vw - 32px));
    border-radius: 12px;
}

.presentation-public-zoom-modal .presentation-image-modal__panel > div {
    max-height: calc(92vh - 132px);
    background: #071320;
}

.presentation-public-zoom-modal .presentation-image-modal__panel img {
    width: 100%;
    height: auto;
}

.presentation-public-zoom-heading {
    display: grid;
    gap: 3px;
}

.presentation-public-zoom-heading span {
    color: #0a6f85;
    font-size: .78rem;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.presentation-public-zoom-modal .presentation-image-modal__nav {
    justify-content: space-between;
}

.presentation-public-zoom-modal .presentation-image-modal__nav p {
    flex: 1;
    margin: 0;
    color: #38556a;
    font-size: .94rem;
    line-height: 1.45;
}

.presentation-public-empty {
    display: grid;
    place-content: center;
    min-height: 100vh;
    padding: 28px;
    text-align: center;
}

.presentation-public-empty span {
    color: #0a6f85;
    font-size: .82rem;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.presentation-public-empty h1 {
    margin: 8px 0;
    color: #082c40;
}

.presentation-public-empty p {
    margin: 0;
    color: #52637c;
}

@media (max-width: 900px) {
    .presentation-public-shell {
        gap: 22px;
        width: min(100% - 28px, 760px);
        padding: 18px 0;
    }

    .presentation-public-header,
    .presentation-public-caption {
        align-items: flex-start;
        flex-direction: column;
    }

    .presentation-public-stage {
        grid-template-columns: minmax(0, 1fr);
        gap: 22px;
        padding: 4px 0;
    }

    .presentation-public-media img {
        height: auto;
        max-height: 48vh;
    }

    .presentation-public-strip {
        grid-auto-columns: minmax(170px, 76vw);
    }
}

.campaigns-hero h1 {
    margin: 4px 0 4px;
    color: #082c40;
    font-size: 2rem;
    line-height: 1.1;
}

.campaigns-hero p {
    margin: 0;
    max-width: 760px;
    color: #39546a;
    overflow-wrap: anywhere;
}

.campaign-kicker {
    display: inline-flex;
    color: #0a6f85;
    font-size: .78rem;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.campaigns-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px;
    min-width: 0;
}

.campaign-summary-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.campaign-summary-grid article,
.campaigns-sidebar,
.campaign-detail,
.campaign-panel,
.campaign-audience-panel {
    border: 1px solid #bdd7e4;
    border-radius: 8px;
    background: #fff;
}

.campaign-summary-grid article {
    padding: 16px 18px;
}

.campaign-summary-grid span,
.campaign-summary-grid small,
.campaign-metrics span,
.campaign-metrics small {
    display: block;
    color: #445f72;
}

.campaign-summary-grid span,
.campaign-metrics span {
    font-size: .78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.campaign-summary-grid strong,
.campaign-metrics strong {
    display: block;
    margin: 4px 0;
    color: #0d6175;
    font-size: 1.6rem;
    line-height: 1;
}

.campaigns-workbench {
    display: grid;
    grid-template-columns: minmax(280px, 340px) minmax(0, 1fr);
    gap: 16px;
    align-items: start;
    min-width: 0;
}

.campaigns-sidebar {
    display: grid;
    gap: 14px;
    min-width: 0;
    padding: 16px;
}

.campaigns-sidebar h2,
.campaign-detail h2,
.campaign-section-head h3 {
    margin: 0;
    color: #082c40;
}

.campaigns-sidebar p,
.campaign-detail-header p,
.campaign-section-head p {
    margin: 4px 0 0;
    color: #405b6d;
}

.campaign-filter {
    display: grid;
    gap: 10px;
}

.campaign-filter label,
.campaign-form-grid label,
.campaign-field {
    display: grid;
    gap: 6px;
    color: #38556a;
    font-size: .86rem;
    font-weight: 700;
}

.campaign-filter input,
.campaign-filter select,
.campaign-form-grid input,
.campaign-form-grid select,
.campaign-field input,
.campaign-field textarea,
.campaign-field select {
    width: 100%;
    min-width: 0;
    border: 1px solid #bdd7e4;
    border-radius: 7px;
    background: #f9fcfd;
    color: #05263a;
    font: inherit;
    padding: 11px 12px;
}

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

.campaign-item {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    min-height: 74px;
    border: 1px solid #d6e4eb;
    border-radius: 8px;
    color: #082c40;
    padding: 12px;
    text-decoration: none;
    min-width: 0;
}

.campaign-item:hover,
.campaign-item.is-active {
    border-color: #79cfe0;
    background: #e9f9fc;
}

.campaign-item strong,
.campaign-item small {
    display: block;
    min-width: 0;
}

.campaign-item strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.campaign-item small {
    color: #39546a;
    font-size: .78rem;
}

.campaign-item-badges {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
}

.campaign-avatar {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border: 1px solid #91d8ce;
    border-radius: 50%;
    background: #d8f5ef;
    color: #007b72;
    font-weight: 800;
}

.campaign-status,
.campaign-type,
.campaign-id-badge,
.campaign-section-head > span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: max-content;
    border-radius: 999px;
    padding: 5px 10px;
    font-size: .78rem;
    font-style: normal;
    font-weight: 800;
    max-width: 100%;
}

.campaign-status.is-draft {
    border: 1px solid #f0ca70;
    background: #fff4d8;
    color: #9b5d00;
}

.campaign-status.is-review {
    border: 1px solid #8dc8ff;
    background: #e8f3ff;
    color: #0e62ad;
}

.campaign-status.is-ready {
    border: 1px solid #88dfb0;
    background: #dcf9e8;
    color: #08743e;
}

.campaign-status.is-sent {
    border: 1px solid #a9d7ef;
    background: #e4f6fd;
    color: #08627e;
}

.campaign-type,
.campaign-id-badge,
.campaign-section-head > span {
    border: 1px solid #bdd7e4;
    background: #f2f8fb;
    color: #285268;
}

.campaign-empty {
    border: 1px dashed #bdd7e4;
    border-radius: 8px;
    padding: 16px;
    color: #4a6172;
}

.campaign-detail {
    display: grid;
    gap: 16px;
    min-width: 0;
    padding: 18px;
}

.campaign-detail-header,
.campaign-section-head,
.campaign-preview-toolbar {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.campaign-detail-badges {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.campaign-stage-row {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
}

.campaign-stage-row span,
.campaign-stage-row button {
    border: 1px solid #d7e5ec;
    border-radius: 7px;
    background: #f7fafc;
    color: #526979;
    cursor: pointer;
    font: inherit;
    font-weight: 800;
    padding: 10px 12px;
    text-align: center;
}

.campaign-stage-row span.is-done,
.campaign-stage-row button.is-done {
    border-color: #89d7c8;
    background: #e3f8f2;
    color: #007368;
}

.campaign-stage-row button.is-active {
    box-shadow: inset 0 0 0 1px #16a085;
}

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

.campaign-metrics article {
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    background: #fbfdfe;
    padding: 14px;
}

.campaign-editor-grid,
.campaign-preview-grid,
.campaign-draft-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 14px;
    align-items: start;
}

.campaign-draft-grid {
    grid-template-columns: minmax(430px, 1.08fr) minmax(360px, .92fr);
    grid-template-areas:
        "config config"
        "message audience";
    min-width: 0;
}

.campaign-config-panel {
    grid-area: config;
}

.campaign-message-panel {
    grid-area: message;
}

.campaign-audience-panel-draft {
    grid-area: audience;
}

.campaign-panel,
.campaign-audience-panel {
    display: grid;
    align-content: start;
    gap: 14px;
    min-width: 0;
    padding: 16px;
}

.campaign-config-panel {
    gap: 12px;
}

.campaign-config-panel .campaign-form-grid {
    grid-template-columns: minmax(220px, 1.2fr) minmax(150px, .75fr) minmax(230px, 1.1fr) minmax(150px, .75fr);
}

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

.campaign-channel-box {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    background: #f7fafc;
    padding: 12px;
}

.campaign-config-panel .campaign-channel-box {
    min-height: 0;
    padding: 11px 12px;
}

.campaign-channel-box label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #0d3144;
    font-weight: 800;
}

.campaign-channel-box .is-disabled {
    color: #8aa0ad;
}

.campaign-draft-form.is-locked input[readonly],
.campaign-draft-form.is-locked textarea[readonly],
.campaign-draft-form.is-locked select:disabled {
    background: #eef4f7;
    color: #486172;
    cursor: not-allowed;
}

.campaign-draft-form.is-locked input[type="checkbox"]:disabled {
    cursor: not-allowed;
}

.campaign-lock-note {
    margin: 0;
    border: 1px solid #bdd7e4;
    border-radius: 8px;
    background: #f7fbfd;
    color: #38556a;
    padding: 10px 12px;
    font-size: .86rem;
    line-height: 1.4;
}

.campaign-message-group {
    display: grid;
    gap: 12px;
    min-width: 0;
    border-left: 4px solid #8dc3dc;
    padding-left: 12px;
}

.campaign-message-group + .campaign-message-group {
    margin-top: 2px;
    padding-top: 14px;
    border-top: 1px solid #dbeaf1;
}

.campaign-message-group-sms {
    border-left-color: #32b79f;
}

.campaign-message-group-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    min-width: 0;
}

.campaign-message-group-head span {
    border: 1px solid #bdd7e4;
    border-radius: 999px;
    background: #eef8fc;
    color: #075f78;
    padding: 4px 10px;
    font-size: .76rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.campaign-message-group-sms .campaign-message-group-head span {
    border-color: #9fe2d4;
    background: #edfbf7;
    color: #04705e;
}

.campaign-message-group-head strong {
    min-width: 0;
    color: #1f4055;
    font-size: .88rem;
    font-weight: 900;
    text-align: right;
}

.campaign-field small {
    justify-self: end;
    color: #637889;
    font-weight: 700;
}

.campaign-editor-tools {
    display: inline-flex;
    width: max-content;
    overflow: hidden;
    border: 1px solid #bdd7e4;
    border-radius: 7px;
    background: #f7fbfd;
}

.campaign-editor-tools button {
    display: grid;
    place-items: center;
    width: 38px;
    height: 34px;
    border: 0;
    border-right: 1px solid #d7e5ec;
    background: transparent;
    color: #0b3145;
    font-weight: 900;
    cursor: pointer;
}

.campaign-editor-tools button:last-child {
    border-right: 0;
}

.campaign-editor-tools button:hover {
    background: #e7f6fb;
}

.campaign-preview-open {
    justify-self: start;
}

.campaign-preview-toolbar {
    border-bottom: 1px solid #d7e5ec;
    padding-bottom: 10px;
}

.campaign-preview-toolbar span {
    max-width: 55%;
    overflow: hidden;
    color: #50697b;
    font-size: .86rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.campaign-email-stage {
    display: grid;
    place-items: center;
    min-height: 360px;
    border-radius: 8px;
    background: #eef7f0;
    padding: 20px;
}

.campaign-email-stage article {
    width: min(100%, 560px);
    border-top: 5px solid #18a567;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 34px rgba(5, 28, 44, .08);
    padding: 26px 28px;
}

.campaign-email-stage small {
    color: #00744a;
    font-weight: 900;
}

.campaign-email-stage h3 {
    margin: 12px 0;
    color: #04284b;
    font-size: 1.55rem;
    line-height: 1.2;
}

.campaign-email-stage p {
    color: #082c40;
    line-height: 1.55;
}

.campaign-preview-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 8px 0 14px;
    border-radius: 7px;
    background: #1764f5;
    color: #fff;
    font-weight: 900;
    padding: 12px 18px;
    text-decoration: none;
}

.campaign-preview-support {
    border: 1px solid #b9d8ff;
    border-radius: 8px;
    background: #eef6ff;
    padding: 14px 16px;
}

.campaign-email-stage dl {
    display: grid;
    gap: 8px;
    margin: 24px 0 0;
}

.campaign-email-stage div {
    display: grid;
    grid-template-columns: 86px minmax(0, 1fr);
    gap: 10px;
}

.campaign-email-stage dt {
    color: #4d6578;
    font-weight: 800;
}

.campaign-email-stage dd {
    margin: 0;
}

.campaign-email-stage footer {
    margin: 22px -28px -26px;
    border-top: 1px solid #d7e5ec;
    border-radius: 0 0 8px 8px;
    background: #f4f8fb;
    color: #415c70;
    font-size: .82rem;
    line-height: 1.45;
    padding: 16px 28px;
}

.campaign-preview-modal[hidden] {
    display: none;
}

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

.campaign-preview-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(18, 34, 48, .58);
}

.campaign-preview-modal-card {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    width: min(760px, calc(100vw - 32px));
    max-height: min(820px, calc(100vh - 32px));
    overflow: hidden;
    border: 1px solid #bdd7e4;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 24px 70px rgba(4, 30, 48, .28);
}

.campaign-preview-modal-card > header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    border-bottom: 1px solid #d7e5ec;
    padding: 16px 18px;
}

.campaign-preview-modal-card h2 {
    margin: 2px 0 0;
    color: #082c40;
}

.campaign-preview-modal-card .modal-close {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border: 1px solid #bdd7e4;
    border-radius: 7px;
    background: #f8fcfd;
    color: #0c4155;
    font-weight: 900;
    cursor: pointer;
}

.campaign-email-stage-modal {
    max-height: 700px;
    overflow: auto;
    border-radius: 0;
}

.campaign-audience-list {
    display: grid;
    gap: 10px;
}

.campaign-audience-list div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    padding: 12px;
}

.campaign-audience-list strong,
.campaign-audience-list small {
    display: block;
}

.campaign-audience-list small {
    color: #496273;
}

.campaign-audience-list em {
    flex: 0 0 auto;
    border-radius: 999px;
    background: #e8f4ff;
    color: #0d61a4;
    font-size: .78rem;
    font-style: normal;
    font-weight: 800;
    padding: 5px 9px;
}

.campaign-review-box {
    display: grid;
    gap: 8px;
    margin-top: auto;
    border: 1px solid #a8e0c0;
    border-radius: 8px;
    background: #eefbf3;
    padding: 14px;
}

.campaign-review-box p {
    margin: 0;
    color: #335365;
}

.campaign-stage-panel[hidden] {
    display: none;
}

.campaign-review-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(320px, .85fr);
    gap: 14px;
    align-items: start;
}

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

.campaign-review-summary article,
.campaign-review-content article,
.campaign-send-card {
    border: 1px solid #d7e5ec;
    border-radius: 8px;
    background: #fbfdfe;
    padding: 14px;
}

.campaign-review-summary span,
.campaign-review-content span,
.campaign-send-card span {
    display: block;
    color: #12627b;
    font-size: .78rem;
    font-weight: 900;
    text-transform: uppercase;
}

.campaign-review-summary strong,
.campaign-send-card strong {
    display: block;
    margin-top: 6px;
    color: #0a2d43;
    font-size: 1.35rem;
    line-height: 1.1;
}

.campaign-review-summary small {
    display: block;
    margin-top: 8px;
    color: #526b7c;
}

.campaign-review-content {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(220px, .65fr);
    gap: 12px;
}

.campaign-review-content strong {
    display: block;
    margin-top: 8px;
    color: #0a2d43;
}

.campaign-review-content p {
    margin: 8px 0 0;
    color: #334f63;
    line-height: 1.5;
}

.campaign-review-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px;
}

.campaign-test-form {
    display: grid;
    gap: 10px;
}

.campaign-test-form .button {
    width: 100%;
}

.campaign-sms-test {
    border-color: #cab8ff;
    background: #f2edff;
    color: #6231c7;
}

.campaign-warning-note {
    border: 1px solid #edc66b;
    border-radius: 8px;
    background: #fff7db;
    color: #795000;
    font-weight: 800;
    margin: 0;
    padding: 12px 14px;
}

.campaign-ready-panel,
.campaign-sent-panel {
    gap: 16px;
}

.campaign-send-button {
    justify-self: start;
    min-width: 280px;
    background: #139b68;
}

.campaign-card-link {
    justify-self: start;
    border: 0;
    background: transparent;
    color: #006986;
    cursor: pointer;
    font: inherit;
    font-size: .82rem;
    font-weight: 900;
    padding: 2px 0 0;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.campaign-send-modal[hidden] {
    display: none;
}

.campaign-history-modal[hidden] {
    display: none;
}

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

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

.campaign-send-modal-card {
    position: relative;
    z-index: 1;
    display: grid;
    gap: 16px;
    width: min(760px, calc(100vw - 32px));
    max-height: min(760px, calc(100vh - 32px));
    overflow: auto;
    border: 1px solid #bdd7e4;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 24px 70px rgba(4, 30, 48, .28);
    padding: 22px;
}

.campaign-send-modal-card > form {
    display: contents;
}

.campaign-history-modal-card {
    width: min(820px, calc(100vw - 32px));
}

.campaign-history-search {
    display: grid;
    gap: 6px;
    color: #334f63;
    font-size: .86rem;
    font-weight: 800;
}

.campaign-history-search input {
    width: 100%;
    border: 1px solid #bdd7e4;
    border-radius: 8px;
    background: #f8fcfd;
    color: #082c40;
    font: inherit;
    padding: 12px 14px;
}

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

.campaign-history-list article {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    border: 1px solid #d6e4eb;
    border-radius: 8px;
    background: #fbfdfe;
    padding: 12px;
}

.campaign-history-list article[hidden] {
    display: none;
}

.campaign-history-list strong,
.campaign-history-list small {
    display: block;
    min-width: 0;
}

.campaign-history-list small {
    color: #476174;
    font-size: .82rem;
}

.campaign-history-empty {
    border: 1px dashed #bdd7e4;
    border-radius: 8px;
    background: #f8fcfd;
    color: #4b6171;
    padding: 14px;
}

.campaign-send-modal-card > header,
.campaign-send-modal-card > form > header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
}

.campaign-send-modal-card h2 {
    margin: 2px 0 0;
    color: #082c40;
}

.campaign-send-modal-card p {
    margin: 0;
    color: #334f63;
    line-height: 1.5;
}

.campaign-send-modal-card .modal-close {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border: 1px solid #bdd7e4;
    border-radius: 7px;
    background: #f8fcfd;
    color: #0c4155;
    font-weight: 900;
    cursor: pointer;
}

.campaign-confirm-check {
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid #edc66b;
    border-radius: 8px;
    background: #fff7db;
    color: #624100;
    font-weight: 900;
    padding: 12px 14px;
}

.campaign-confirm-check input {
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
}

@media screen and (max-width: 1180px) {
    .campaign-summary-grid,
    .campaign-metrics,
    .presentation-summary-grid,
    .presentation-card-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .campaigns-workbench,
    .campaign-editor-grid,
    .campaign-preview-grid,
    .presentation-next-panel,
    .presentation-form-layout,
    .presentation-assist-panel,
    .presentation-upload-layout,
    .presentation-editor-layout,
    .presentation-preview-layout,
    .presentation-premium-body {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 720px) {
    .campaigns-shell {
        gap: 14px;
    }

    .campaigns-hero,
    .presentations-hero,
    .presentation-form-hero,
    .presentation-section-head,
    .campaign-detail-header,
    .campaign-section-head,
    .campaign-preview-toolbar {
        display: grid;
        min-width: 0;
    }

    .campaigns-actions,
    .presentations-actions,
    .campaign-detail-badges {
        display: grid;
        justify-content: stretch;
        width: 100%;
    }

    .campaigns-actions .button,
    .presentations-actions .button {
        min-width: 0;
        width: 100%;
    }

    .presentation-form-hero .presentations-actions {
        min-width: 0;
    }

    .campaign-summary-grid,
    .presentation-summary-grid,
    .presentation-card-grid,
    .presentation-validation-summary,
    .campaign-metrics,
    .campaign-stage-row,
    .campaign-form-grid,
    .presentation-filter-panel form,
    .presentation-main-form,
    .presentation-upload-options {
        grid-template-columns: 1fr;
    }

    .campaigns-workbench,
    .campaign-draft-grid,
    .campaign-review-layout,
    .campaign-review-content,
    .presentation-next-panel,
    .presentation-form-layout,
    .presentation-assist-panel,
    .presentation-upload-layout,
    .presentation-editor-layout,
    .presentation-editor-form,
    .presentation-preview-layout,
    .presentation-premium-body {
        grid-template-columns: minmax(0, 1fr);
    }

    .campaign-draft-grid {
        grid-template-areas:
            "config"
            "message"
            "audience";
    }

    .campaign-config-panel .campaign-form-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .campaign-review-summary,
    .campaign-test-actions {
        grid-template-columns: minmax(0, 1fr);
    }

    .campaigns-sidebar,
    .campaign-detail,
    .campaign-panel,
    .campaign-audience-panel,
    .presentation-card,
    .presentation-next-panel,
    .presentation-form-panel,
    .presentation-form-aside,
    .presentation-assist-panel,
    .presentation-upload-panel,
    .presentation-generated-panel,
    .presentation-editor-steps,
    .presentation-editor-panel,
    .presentation-premium-card {
        padding: 14px;
    }

    .presentation-main-form .is-wide,
    .presentation-editor-form .is-wide {
        grid-column: auto;
    }

    .presentation-side-meta div {
        align-items: flex-start;
        flex-direction: column;
    }

    .presentation-side-meta dd {
        white-space: normal;
    }

    .presentation-generated-list article {
        grid-template-columns: auto minmax(0, 1fr);
    }

    .presentation-validation-list article {
        align-items: flex-start;
        flex-direction: column;
    }

    .presentation-file-status {
        text-align: left;
        white-space: normal;
    }

    .presentation-reorder-actions {
        grid-column: 2;
        flex-wrap: wrap;
    }

    .presentation-stage {
        padding: 12px;
    }

    .presentation-stage-screen {
        min-height: 240px;
    }

    .presentation-stage-window {
        width: min(100%, 420px);
    }

    .presentation-stage-topbar,
    .presentation-premium-topbar,
    .presentation-editor-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .presentation-editor-actions .button {
        width: 100%;
    }

    .presentation-card header,
    .presentation-card footer,
    .presentation-card-actions {
        align-items: flex-start;
        flex-direction: column;
    }

    .presentation-card-actions .button {
        width: 100%;
    }

    .presentation-meta-list div {
        grid-template-columns: minmax(0, 1fr);
    }

    .presentation-meta-list dd {
        text-align: left;
        white-space: normal;
    }

    .campaign-item {
        grid-template-columns: auto minmax(0, 1fr);
    }

    .campaign-item-badges {
        grid-column: 2;
        align-items: flex-start;
        flex-direction: row;
        flex-wrap: wrap;
    }

    .campaign-status,
    .campaign-type,
    .campaign-id-badge,
    .campaign-section-head > span {
        width: fit-content;
        max-width: 100%;
        white-space: normal;
        overflow-wrap: anywhere;
    }

    .campaign-channel-box {
        align-items: flex-start;
        gap: 10px;
    }

    .campaign-channel-box strong {
        flex: 0 0 100%;
    }

    .campaign-field textarea {
        resize: vertical;
    }

    .campaign-preview-open {
        width: 100%;
    }

    .campaign-preview-modal {
        padding: 10px;
    }

    .campaign-preview-modal-card {
        width: min(100%, calc(100vw - 20px));
        max-height: calc(100vh - 20px);
    }

    .campaign-send-modal {
        padding: 10px;
    }

    .campaign-history-modal {
        padding: 10px;
    }

    .campaign-send-modal-card {
        width: min(100%, calc(100vw - 20px));
        max-height: calc(100vh - 20px);
        padding: 16px;
    }

    .campaign-history-list article {
        grid-template-columns: auto minmax(0, 1fr);
    }

    .campaign-history-list .campaign-status {
        grid-column: 2;
    }

    .campaign-send-button,
    .campaign-review-actions .button,
    .campaign-test-actions .button {
        width: 100%;
        min-width: 0;
    }

    .campaign-review-actions form {
        width: 100%;
    }

    .campaign-email-stage {
        min-height: 0;
        padding: 14px;
    }

    .campaign-email-stage article {
        padding: 22px;
    }

    .campaign-email-stage div {
        grid-template-columns: 1fr;
        gap: 2px;
    }

    .campaign-audience-list div {
        align-items: flex-start;
        flex-direction: column;
    }
}

/* Rental invoices */
.rental-invoices-page,
.rental-invoice-form-page { max-width: 1408px; margin: 0 auto; }
.rental-invoice-filter { grid-template-columns: minmax(190px, .7fr) minmax(320px, 2fr) auto auto; }
.rental-invoice-list-summary { display: grid; gap: 2px; padding: 14px 16px; border-bottom: 1px solid #d8e2ea; }
.rental-invoice-list-summary small,
.rental-invoice-table td small { display: block; color: #62758d; }
.rental-invoice-table td { vertical-align: middle; }
.rental-invoice-table td:nth-child(2) { min-width: 280px; }
.rental-invoice-table td:nth-child(2) strong,
.rental-invoice-table td:nth-child(2) span { display: block; }
.rental-invoice-table td:last-child { text-align: right; }
.receivable-action-menu .rental-delivery-menu-action { display: block; width: 100%; }
.receivable-action-menu .rental-delivery-menu-action.email { color: #087b58; }
.receivable-action-menu .rental-delivery-menu-action.sms { color: #b316a3; }
.receivable-action-menu .rental-delivery-menu-action.whatsapp { color: #087b58; font-weight: 800; }
.receivable-action-menu .rental-delivery-menu-block--whatsapp { background: #f0fdf6; }
.receivable-action-menu .rental-delivery-menu-action:disabled {
    color: #91a0ad;
    cursor: not-allowed;
    opacity: .7;
}
.receivable-action-menu .rental-delivery-menu-block {
    display: grid;
    gap: 2px;
    padding: 5px 0 9px;
    border-bottom: 1px solid #e3edf2;
}
.receivable-action-menu .rental-delivery-menu-block:first-of-type { padding-top: 2px; }
.receivable-action-menu .rental-delivery-menu-block small,
.receivable-action-menu .rental-delivery-menu-block span {
    padding: 0 10px;
    color: #65788b;
    font-size: .72rem;
    line-height: 1.35;
    text-align: left;
    overflow-wrap: anywhere;
}
.receivable-action-menu .rental-delivery-menu-block span { color: #344f63; }
.rental-delivery-modal[hidden] { display: none; }
.rental-delivery-modal {
    position: fixed;
    inset: 0;
    z-index: 120;
    display: grid;
    place-items: center;
    padding: 22px;
}
.rental-delivery-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(8, 31, 47, .62);
    backdrop-filter: blur(3px);
}
.rental-delivery-modal-card {
    position: relative;
    display: grid;
    width: min(880px, 96vw);
    max-height: calc(100dvh - 24px);
    overflow-x: hidden;
    overflow-y: auto;
    scrollbar-width: none;
    border: 1px solid #b9d7e1;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 28px 80px rgba(4, 31, 48, .28);
}
.rental-delivery-modal-card::-webkit-scrollbar { width: 0; height: 0; }
.rental-delivery-modal-card > * { min-width: 0; }
.rental-delivery-modal-card > header {
    display: flex;
    justify-content: space-between;
    gap: 22px;
    padding: 22px 24px;
    border-bottom: 1px solid #d9e7ed;
    background: linear-gradient(135deg, #f4fbfd, #edf6fb);
}
.rental-delivery-modal-card > header span {
    color: #06758b;
    font-size: .74rem;
    font-weight: 900;
    letter-spacing: .07em;
}
.rental-delivery-modal-card > header h2 { margin: 5px 0; font-size: 1.45rem; }
.rental-delivery-modal-card > header p { margin: 0; color: #596f84; }
.rental-delivery-modal-card > header button {
    flex: 0 0 38px;
    height: 38px;
    border: 1px solid #bad3dd;
    border-radius: 10px;
    background: #fff;
    color: #173c4c;
    font-size: 1.25rem;
    cursor: pointer;
}
.rental-delivery-recipient {
    display: grid;
    grid-template-columns: 1fr 1.2fr .8fr;
    gap: 10px;
    padding: 18px 24px 0;
}
.rental-delivery-recipient article,
.rental-delivery-subject {
    display: grid;
    gap: 5px;
    min-width: 0;
    padding: 13px 15px;
    border: 1px solid #cfe1e8;
    border-radius: 11px;
    background: #f7fbfd;
}
.rental-delivery-recipient small,
.rental-delivery-subject small,
.rental-delivery-sms-preview small {
    color: #61788b;
    font-size: .7rem;
    font-weight: 900;
    letter-spacing: .05em;
}
.rental-delivery-recipient strong { overflow-wrap: anywhere; }
.rental-delivery-recipient [data-rental-delivery-stage].is-due-today { color: #1d4ed8; }
.rental-delivery-recipient [data-rental-delivery-stage].is-overdue { color: #e11d48; }
.rental-delivery-recipient [data-rental-delivery-stage].is-before-due { color: #087b58; }
.rental-delivery-subject { margin: 10px 24px 0; background: #fff; }
.financial-delivery-recipients { display:grid; gap:8px; margin:10px 24px 0; padding:13px 15px; border:1px solid #cfe1e8; border-radius:11px; background:#f7fbfd; }
.financial-delivery-recipients > small { color:#61788b; font-size:.7rem; font-weight:900; letter-spacing:.05em; }
.financial-delivery-recipients-content { display:grid; grid-template-columns:minmax(150px,.7fr) minmax(0,1.5fr); gap:8px; }
.financial-delivery-destinations { display:grid; grid-template-columns:repeat(auto-fit,minmax(min(280px,100%),1fr)); gap:8px; min-width:0; }
.financial-delivery-recipients article { display:grid; gap:3px; min-width:0; padding:9px 11px; border-radius:8px; background:#fff; }
.financial-delivery-recipients article small { color:#65788b; font-size:.72rem; }
.financial-delivery-recipients article strong { overflow-wrap:anywhere; }
.financial-delivery-party strong { color:#173c4c; }
.financial-delivery-issues { margin:10px 24px 0; padding:13px 15px; border:1px solid #fecdd3; border-radius:11px; background:#fff1f2; color:#9f1239; }
.financial-delivery-issues[hidden] { display:none; }
.financial-delivery-issues ul { margin:7px 0 0; padding-left:20px; }
.financial-delivery-modal-card button:disabled { cursor:not-allowed; opacity:.58; }
.financial-delivery-modal-card.is-email {
    height: min(840px, 92vh);
    overflow: hidden;
    grid-template-rows: auto auto auto auto auto minmax(0, 1fr) auto;
}
.financial-delivery-modal-card.is-email > header { grid-row: 1; }
.financial-delivery-modal-card.is-email > .financial-delivery-summary { grid-row: 2; }
.financial-delivery-modal-card.is-email > .financial-delivery-recipients { grid-row: 3; }
.financial-delivery-modal-card.is-email > .financial-delivery-issues { grid-row: 4; }
.financial-delivery-modal-card.is-email > .rental-delivery-subject { grid-row: 5; }
.financial-delivery-modal-card.is-email > .rental-delivery-preview {
    grid-row: 6;
    display: flex;
    min-height: 0;
    overflow: hidden;
}
.financial-delivery-modal-card.is-email > form { grid-row: 7; }
.financial-delivery-modal-card.is-email .rental-delivery-preview iframe {
    flex: 1 1 auto;
    height: 100%;
    min-height: 0;
}
.rental-delivery-preview { padding: 14px 24px 20px; }
.rental-delivery-preview [hidden],
.rental-delivery-subject[hidden] { display: none; }
.rental-delivery-preview iframe {
    width: 100%;
    height: 390px;
    border: 1px solid #cbdde5;
    border-radius: 12px;
    background: #eff7fa;
}
.rental-delivery-sms-preview {
    display: grid;
    gap: 12px;
    padding: 24px;
    border: 1px solid #d9c9f3;
    border-radius: 14px;
    background: linear-gradient(145deg, #faf7ff, #f4f9fd);
}
.rental-delivery-sms-preview p {
    width: min(520px, 90%);
    margin: 0;
    padding: 16px 18px;
    border-radius: 16px 16px 16px 4px;
    background: #fff;
    box-shadow: 0 8px 24px rgba(54, 37, 90, .1);
    color: #25394a;
    line-height: 1.55;
}
.rental-delivery-sms-preview span { color: #65778b; font-size: .78rem; }
.rental-delivery-modal-card form footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 16px 24px;
    border-top: 1px solid #d9e7ed;
    background: #f8fbfd;
}
.rental-delivery-modal-card.is-whatsapp { width: min(1080px, 96vw); }
.rental-delivery-modal-card.is-whatsapp > header {
    border-top: 4px solid #20a85b;
    background: linear-gradient(135deg, #f1fcf6, #f4fbfd 60%, #eef7fb);
}
.rental-delivery-modal-card.is-whatsapp > header span { color: #087b58; }
.rental-whatsapp-preview {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 26px;
    align-items: start;
    padding: 4px 0 8px;
}
.rental-whatsapp-details { display: grid; gap: 12px; min-width: 0; }
.rental-whatsapp-safety,
.rental-whatsapp-template-card,
.rental-whatsapp-variables,
.rental-whatsapp-issues {
    border: 1px solid #cfe1e8;
    border-radius: 13px;
    background: #fff;
}
.rental-whatsapp-safety { display: flex; gap: 11px; align-items: center; padding: 13px 15px; border-color: #a9ddc0; background: #effcf5; }
.rental-whatsapp-safety > span { display: grid; flex: 0 0 31px; width: 31px; height: 31px; place-items: center; border-radius: 50%; background: #20a85b; color: #fff; font-weight: 900; }
.rental-whatsapp-safety strong { display: block; color: #087b58; }
.rental-whatsapp-safety p { margin: 2px 0 0; color: #4f6d60; font-size: .8rem; }
.rental-whatsapp-template-card { display: grid; gap: 5px; padding: 14px 16px; background: #f7fbfd; }
.rental-whatsapp-template-card small,
.rental-whatsapp-variables header small,
.rental-whatsapp-phone-stage > small { color: #087b58; font-size: .69rem; font-weight: 900; letter-spacing: .07em; }
.rental-whatsapp-template-card strong { color: #173c4c; overflow-wrap: anywhere; }
.rental-whatsapp-template-card code { color: #567187; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: .75rem; overflow-wrap: anywhere; }
.rental-whatsapp-variables { overflow: hidden; }
.rental-whatsapp-variables > header { display: flex; justify-content: space-between; gap: 10px; padding: 12px 14px; border-bottom: 1px solid #d9e7ed; background: #f7fbfd; }
.rental-whatsapp-variables > header span { color: #718398; font-size: .72rem; }
.rental-whatsapp-variables > div { display: grid; grid-template-columns: 1fr 1fr; }
.rental-whatsapp-variables article { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 9px; align-items: start; padding: 11px 13px; border-bottom: 1px solid #e5eef2; }
.rental-whatsapp-variables article:nth-child(odd) { border-right: 1px solid #e5eef2; }
.rental-whatsapp-variables article:last-child { grid-column: 1 / -1; border-bottom: 0; border-right: 0; }
.rental-whatsapp-variables code { padding: 2px 5px; border-radius: 5px; background: #e7f7ee; color: #087b58; font-weight: 800; }
.rental-whatsapp-variables article span { color: #2d485b; font-size: .8rem; line-height: 1.4; overflow-wrap: anywhere; }
.rental-whatsapp-issues { padding: 13px 15px; border-color: #fecdd3; background: #fff1f2; color: #9f1239; }
.rental-whatsapp-issues[hidden] { display: none; }
.rental-whatsapp-issues ul { margin: 6px 0 0; padding-left: 19px; font-size: .82rem; }
.rental-whatsapp-phone-stage { display: grid; justify-items: center; gap: 9px; }
.rental-whatsapp-phone {
    position: relative;
    box-sizing: border-box;
    width: min(320px, 100%);
    height: 520px;
    padding: 12px;
    border: 2px solid #2b3a48;
    border-radius: 44px;
    background: linear-gradient(145deg, #273746, #0e1821);
    box-shadow: 0 20px 44px rgba(7, 34, 46, .24), inset 0 0 0 1px rgba(255,255,255,.12);
}
.rental-whatsapp-phone::before,
.rental-whatsapp-phone::after { content: ''; position: absolute; left: -5px; width: 4px; border-radius: 3px 0 0 3px; background: #253645; }
.rental-whatsapp-phone::before { top: 105px; height: 45px; }
.rental-whatsapp-phone::after { top: 162px; height: 68px; }
.rental-whatsapp-phone__speaker { position: absolute; z-index: 3; top: 18px; left: 50%; width: 78px; height: 20px; transform: translateX(-50%); border-radius: 20px; background: #101a22; }
.rental-whatsapp-phone__screen { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; height: 100%; overflow: hidden; border-radius: 33px; background: #efeae2; }
.rental-whatsapp-phone__topbar { display: flex; gap: 8px; align-items: center; min-height: 69px; padding: 22px 12px 9px; background: #075e54; color: #fff; }
.rental-whatsapp-phone__back { font-size: 1.7rem; line-height: 1; }
.rental-whatsapp-phone__avatar { display: grid; flex: 0 0 34px; width: 34px; height: 34px; place-items: center; border-radius: 50%; background: linear-gradient(145deg, #f5fff8, #bfe8cf); color: #087b58; font-weight: 900; }
.rental-whatsapp-phone__contact { display: grid; min-width: 0; line-height: 1.1; }
.rental-whatsapp-phone__contact strong { font-size: .83rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rental-whatsapp-phone__contact small { margin-top: 3px; color: #d7ece7; font-size: .62rem; }
.rental-whatsapp-phone__verified { display: grid; flex: 0 0 18px; width: 18px; height: 18px; place-items: center; border-radius: 50%; background: #1da1f2; font-size: .65rem; font-weight: 900; }
.rental-whatsapp-phone__chat {
    position: relative;
    overflow: auto;
    padding: 20px 12px 15px;
    background-color: #efeae2;
    background-image: radial-gradient(circle at 15px 15px, rgba(7,94,84,.045) 1.5px, transparent 1.6px);
    background-size: 30px 30px;
    scrollbar-width: none;
}
.rental-whatsapp-phone__chat::-webkit-scrollbar { width: 0; height: 0; }
.rental-whatsapp-phone__date { display: table; margin: 0 auto 13px; padding: 4px 9px; border-radius: 6px; background: #e1f3fb; color: #55717d; font-size: .58rem; font-weight: 800; box-shadow: 0 1px 2px rgba(0,0,0,.08); }
.rental-whatsapp-phone__bubble { position: relative; margin: 0 18px 0 0; padding: 11px 10px 7px; border-radius: 4px 9px 9px 9px; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.13); }
.rental-whatsapp-phone__bubble::before { content: ''; position: absolute; top: 0; left: -8px; border-top: 9px solid #fff; border-left: 9px solid transparent; }
.rental-whatsapp-phone__bubble p { margin: 0; color: #15242d; font-size: .72rem; line-height: 1.48; white-space: pre-wrap; }
.rental-whatsapp-phone__bubble footer { display: flex; justify-content: flex-end; gap: 4px; align-items: center; margin-top: 3px; color: #829099; font-size: .57rem; }
.rental-whatsapp-phone__bubble footer span { color: #1d9bf0; font-weight: 900; letter-spacing: -3px; }
.rental-whatsapp-phone__composer { display: flex; gap: 7px; align-items: center; padding: 8px; background: #f0f2f5; }
.rental-whatsapp-phone__composer > span { color: #77868f; font-size: 1.1rem; }
.rental-whatsapp-phone__composer div { flex: 1; padding: 9px 12px; border-radius: 18px; background: #fff; color: #95a0a6; font-size: .7rem; }
.rental-whatsapp-phone__composer b { display: grid; width: 33px; height: 33px; place-items: center; border-radius: 50%; background: #00a884; color: #fff; font-size: 1.2rem; }
.rental-whatsapp-phone__home { position: absolute; bottom: 5px; left: 50%; width: 88px; height: 3px; transform: translateX(-50%); border-radius: 5px; background: rgba(255,255,255,.55); }
.rental-whatsapp-footer-note { align-self: center; margin-right: auto; color: #567187; font-size: .75rem; font-weight: 700; }
.rental-whatsapp-simulation-button { border-color: #128c60; background: #128c60; color: #fff; }
.rental-whatsapp-simulation-button:hover { border-color: #087b58; background: #087b58; }
.rental-whatsapp-simulation-button:disabled { cursor: not-allowed; opacity: .5; }
.rental-whatsapp-real-button,
.rental-whatsapp-real-submit { border-color: #075e54; background: #075e54; color: #fff; }
.rental-whatsapp-real-button:hover:not(:disabled),
.rental-whatsapp-real-submit:hover:not(:disabled) { border-color: #064e47; background: #064e47; }
.rental-whatsapp-real-button:disabled { border-color: #c8d9df; background: #edf3f5; color: #657a86; }
.rental-whatsapp-real-confirm {
    position: fixed;
    z-index: 1300;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 18px;
}
.rental-whatsapp-real-confirm[hidden] { display: none; }
.rental-whatsapp-real-confirm__backdrop { position: absolute; inset: 0; background: rgba(8, 30, 40, .68); backdrop-filter: blur(3px); }
.rental-whatsapp-real-confirm > article {
    position: relative;
    width: min(520px, 100%);
    overflow: hidden;
    border: 1px solid #a9cbd4;
    border-top: 4px solid #e59a18;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 28px 80px rgba(4, 31, 48, .38);
}
.rental-whatsapp-real-confirm > article > header { display: flex; justify-content: space-between; gap: 18px; padding: 19px 21px; border-bottom: 1px solid #d9e7ed; background: #f7fbfd; }
.rental-whatsapp-real-confirm > article > header span { color: #a05c00; font-size: .69rem; font-weight: 900; letter-spacing: .08em; }
.rental-whatsapp-real-confirm > article > header h3 { margin: 4px 0 0; color: #173c4c; font-size: 1.2rem; }
.rental-whatsapp-real-confirm > article > header button { flex: 0 0 36px; height: 36px; border: 1px solid #bfd5dd; border-radius: 9px; background: #fff; color: #173c4c; font-size: 1.2rem; cursor: pointer; }
.rental-whatsapp-real-warning { margin: 18px 20px 0; padding: 14px 15px; border: 1px solid #f4c36d; border-radius: 11px; background: #fff8e8; color: #704310; }
.rental-whatsapp-real-warning strong { display: block; margin-bottom: 3px; }
.rental-whatsapp-real-warning p { margin: 0; font-size: .82rem; line-height: 1.45; }
.rental-whatsapp-real-confirm dl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; margin: 12px 20px; }
.rental-whatsapp-real-confirm dl div { min-width: 0; padding: 11px 12px; border: 1px solid #d6e5ea; border-radius: 9px; background: #f8fbfc; }
.rental-whatsapp-real-confirm dl div:last-child { grid-column: 1 / -1; }
.rental-whatsapp-real-confirm dt { color: #667d8b; font-size: .68rem; font-weight: 900; letter-spacing: .05em; text-transform: uppercase; }
.rental-whatsapp-real-confirm dd { margin: 4px 0 0; color: #173c4c; font-weight: 800; overflow-wrap: anywhere; }
.rental-whatsapp-real-confirm form > label { display: flex; gap: 10px; align-items: flex-start; margin: 15px 20px; color: #344f5f; font-size: .85rem; line-height: 1.45; cursor: pointer; }
.rental-whatsapp-real-confirm form > label input { flex: 0 0 auto; margin-top: 3px; }
.communication-real-send-gate { display: flex; gap: 12px; align-items: flex-start; margin-top: 14px; padding: 14px 16px; border: 1px solid #f2c873; border-radius: 12px; background: #fff9ec; cursor: pointer; }
.communication-real-send-gate input { flex: 0 0 auto; margin-top: 3px; }
.communication-real-send-gate span { display: grid; gap: 3px; }
.communication-real-send-gate strong { color: #6f450d; }
.communication-real-send-gate small { color: #75634c; line-height: 1.4; }
.communication-real-send-gate { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 22px; align-items: center; padding: 16px 18px; background: linear-gradient(135deg, #fff9ec, #fffdf7); }
.communication-real-send-gate__content { display: grid; gap: 3px; min-width: 0; }
.communication-real-send-gate__content b { color: #a5630a; font-size: .68rem; letter-spacing: .08em; text-transform: uppercase; }
.communication-real-send-gate strong { color: #6f450d; font-size: 1rem; }
.communication-real-send-gate.is-disabled { border-color: #d4e0e4; background: #f6f9fa; cursor: not-allowed; }
.communication-real-send-gate.is-disabled .communication-real-send-gate__content b,
.communication-real-send-gate.is-disabled strong { color: #607581; }
.communication-toggle { position: relative; display: block !important; width: 54px; height: 30px; }
.communication-toggle input { position: absolute; width: 1px !important; height: 1px !important; margin: 0 !important; opacity: 0; }
.communication-toggle i { position: absolute; inset: 0; border: 1px solid #aebfc7; border-radius: 999px; background: #cad6db; box-shadow: inset 0 1px 3px rgba(20, 52, 65, .12); transition: .18s ease; }
.communication-toggle i::after { content: ''; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 2px 6px rgba(20, 52, 65, .28); transition: .18s ease; }
.communication-toggle input:checked + i { border-color: #087b58; background: #16a36d; }
.communication-toggle input:checked + i::after { transform: translateX(24px); }
.communication-toggle input:focus-visible + i { outline: 3px solid color-mix(in srgb, #0a8ca8 28%, transparent); outline-offset: 3px; }
.communication-toggle input:disabled + i { opacity: .58; }
.rental-invoice-page-header { max-width: 1408px; margin-left: auto; margin-right: auto; }
.rental-invoice-metrics { margin-bottom: 16px; }
.rental-invoice-main-form { display: grid; gap: 14px; }

@media (max-width: 720px) {
    .rental-delivery-modal { padding: 6px; }
    .rental-delivery-recipient { grid-template-columns: 1fr; }
    .rental-delivery-preview iframe { height: 330px; }
    .rental-delivery-modal-card form footer { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .rental-delivery-modal-card form footer .button { min-width: 0; width: 100%; white-space: normal; }
    .rental-delivery-modal-card.is-whatsapp { width: 100%; max-height: calc(100dvh - 12px); }
    .rental-delivery-modal-card.is-whatsapp .rental-delivery-preview { padding: 12px 14px 18px; }
    .rental-whatsapp-preview { grid-template-columns: 1fr; }
    .rental-whatsapp-phone-stage { min-width: 0; }
    .rental-whatsapp-phone { width: min(310px, 100%); height: 520px; }
    .rental-whatsapp-footer-note { grid-column: 1 / -1; margin: 0; text-align: center; }
    .rental-whatsapp-real-button { grid-column: 1 / -1; }
    .rental-whatsapp-real-confirm { padding: 10px; }
    .rental-whatsapp-real-confirm dl { grid-template-columns: 1fr; }
    .rental-whatsapp-real-confirm dl div:last-child { grid-column: auto; }
    .financial-delivery-modal-card.is-email {
        height: auto;
        max-height: none;
        min-height: 100dvh;
        width: 100%;
        overflow: visible;
        border: 0;
        border-radius: 0;
        grid-template-rows: none;
    }
    .financial-delivery-modal-card.is-email > * { grid-row: auto; }
    .financial-delivery-modal-card.is-email > .rental-delivery-preview { display: block; overflow: visible; }
    .financial-delivery-modal-card.is-email .rental-delivery-preview iframe {
        height: 330px;
        min-height: 330px;
    }
    .financial-delivery-modal {
        place-items: start center;
        padding: 0;
        overflow-x: hidden;
        overflow-y: auto;
        overscroll-behavior: contain;
        -webkit-overflow-scrolling: touch;
        touch-action: pan-y;
    }
    .financial-delivery-modal .financial-delivery-modal-card > form footer {
        position: sticky;
        bottom: 0;
        z-index: 2;
    }
    .financial-delivery-recipients-content { grid-template-columns:1fr; }
    .financial-delivery-destinations { grid-template-columns:1fr; }
    .financial-delivery-recipients article strong { font-size:.92rem; }
}

@media (max-width: 480px) {
    .rental-whatsapp-variables > div { grid-template-columns: 1fr; }
    .rental-whatsapp-variables article,
    .rental-whatsapp-variables article:nth-child(odd),
    .rental-whatsapp-variables article:last-child { grid-column: auto; border-right: 0; }
    .rental-whatsapp-variables article:last-child { border-bottom: 0; }
}
.rental-invoice-primary-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; align-items: stretch; }
.rental-invoice-primary-grid > .receivable-form-card { margin: 0; height: 100%; }
.rental-invoice-party-card,
.rental-invoice-data-card,
.rental-invoice-recurrence,
.rental-invoice-reminders,
.rental-invoice-notes,
.rental-invoice-payments { padding: 16px; }
.rental-invoice-party-card > header,
.rental-invoice-data-card > header,
.rental-invoice-recurrence > header,
.rental-invoice-reminders > header,
.rental-invoice-notes > header,
.rental-invoice-payments > header {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 14px;
}
.rental-invoice-party-card header h2,
.rental-invoice-data-card header h2,
.rental-invoice-recurrence header h2,
.rental-invoice-reminders header h2,
.rental-invoice-notes header h2,
.rental-invoice-payments header h2 { margin: 2px 0; font-size: 18px; }
.rental-invoice-party-card header small,
.rental-invoice-data-card header small,
.rental-invoice-recurrence header small,
.rental-invoice-reminders header small,
.rental-invoice-notes header small,
.rental-invoice-payments header small { color: #0066c8; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; }
.rental-invoice-party-card header em,
.rental-invoice-data-card header em { color: #586c84; font-style: normal; font-weight: 700; }
.rental-invoice-party-snapshot { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 14px; }
.rental-invoice-party-snapshot article {
    display: grid;
    gap: 3px;
    min-height: 90px;
    padding: 12px;
    border: 1px solid #dbe5ed;
    border-radius: 12px;
    background: #f8fbfd;
}
.rental-invoice-party-snapshot article:last-child { grid-column: 1 / -1; min-height: 72px; }
.rental-invoice-party-snapshot span,
.rental-invoice-party-snapshot small { color: #65758b; }
.rental-invoice-contract-warning {
    display: none;
    align-items: flex-start;
    gap: 10px;
    margin-top: 12px;
    padding: 12px;
    border: 1px solid #f0bc67;
    border-radius: 10px;
    background: #fff8e9;
    color: #7b5312;
}
.rental-invoice-contract-warning.is-visible { display: flex; }
.rental-invoice-contract-warning input { width: auto; margin-top: 3px; }
.rental-invoice-contract-warning span { display: grid; gap: 2px; }
.rental-invoice-recurrence-grid { display: grid; grid-template-columns: repeat(2, minmax(190px, .7fr)) minmax(300px, 1.4fr); gap: 14px; align-items: end; }
.rental-invoice-recurrence-grid > div { display: grid; gap: 3px; min-height: 44px; padding: 10px 14px; border: 1px solid #bcebdc; border-radius: 10px; background: #effcf6; color: #087b58; }
.rental-invoice-automation-stack { margin: 0; }
.rental-invoice-automation-stack .rental-invoice-recurrence { margin: 0; }
.rental-invoice-reminder-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; align-items: center; }
.rental-invoice-reminder-grid label:first-child,
.rental-invoice-reminder-grid label:nth-child(2) { display: flex; flex-direction: row; align-items: center; gap: 8px; min-height: 44px; }
.rental-invoice-reminder-grid input[type="checkbox"] { width: auto; }
.rental-invoice-notes textarea { width: 100%; resize: vertical; border-radius: 12px; }
.rental-invoice-payment-form { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; align-items: end; }
.rental-invoice-payment-form .wide { grid-column: span 2; }
.rental-invoice-reconciled { display: flex !important; flex-direction: row !important; align-items: center; gap: 8px; min-height: 44px; }
.rental-invoice-reconciled input { width: auto !important; }
.rental-invoice-payment-history { display: grid; gap: 8px; margin-top: 16px; }
.rental-invoice-payment-history article { display: flex; justify-content: space-between; gap: 14px; align-items: center; padding: 12px 14px; border: 1px solid #dde7ee; border-radius: 11px; }
.rental-invoice-payment-history article > div { display: grid; gap: 3px; }
.rental-invoice-payment-history span,
.rental-invoice-payment-history small { color: #61738a; }
.rental-invoice-document-grid { display: grid; grid-template-columns: minmax(320px, .85fr) minmax(0, 1.35fr); gap: 16px; align-items: start; }
.rental-invoice-document-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; padding: 16px; border: 1px solid #d7e3ea; border-radius: 12px; background: #f8fbfd; }
.rental-invoice-document-form label { display: grid; gap: 6px; }
.rental-invoice-document-form .wide { grid-column: 1 / -1; }
.rental-invoice-document-list { display: grid; gap: 10px; }
.rental-invoice-document-list article { display: flex; justify-content: space-between; gap: 14px; padding: 14px; border: 1px solid #c7e6f0; border-radius: 12px; background: #f0fbff; }
.rental-invoice-document-list article > div:first-child { display: grid; gap: 3px; }
.rental-invoice-document-list article span,
.rental-invoice-document-list article small { color: #61738a; }
.rental-invoice-document-list .actions { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.rental-invoice-secondary-grid {
    align-items: stretch;
    margin-top: 14px;
}
.rental-invoice-secondary-grid > .receivable-form-card {
    height: 100%;
    margin: 0;
}
.rental-invoice-secondary-grid.is-notes-only > .receivable-form-card {
    grid-column: 1 / -1;
}
.rental-invoice-secondary-grid .rental-invoice-document-grid {
    grid-template-columns: minmax(0, 1fr);
}
.rental-invoice-secondary-grid .rental-invoice-documents > header {
    margin-bottom: 2px;
}
.rental-invoice-secondary-grid .rental-invoice-documents > header p {
    margin: 4px 0 0;
    line-height: 1.35;
}
.rental-invoice-secondary-grid .rental-invoice-document-form {
    padding: 14px;
}
.rental-invoice-secondary-grid .rental-invoice-document-form .receivable-file-input::file-selector-button {
    min-height: 30px;
    margin-right: 12px;
    padding: 0 13px;
    border: 1px solid #9fd1df;
    border-radius: 8px;
    background: #f4fbfd;
    color: var(--primary);
    cursor: pointer;
    font: inherit;
    font-weight: 900;
}
.rental-invoice-secondary-grid .rental-invoice-document-form .receivable-file-input:hover::file-selector-button {
    border-color: var(--primary);
    background: #e8f7fb;
}
.rental-invoice-secondary-grid .rental-invoice-document-list .empty {
    min-height: 0;
    padding: 2px 0;
    border: 0;
    border-radius: 0;
    background: transparent;
}
.rental-invoice-secondary-grid .rental-invoice-notes {
    grid-template-rows: auto minmax(0, 1fr);
}
.rental-invoice-secondary-grid .rental-invoice-notes .receivable-textarea-label {
    min-height: 0;
}
.rental-invoice-secondary-grid .rental-invoice-notes textarea {
    flex: 1 1 auto;
    min-height: 180px;
}
.rental-invoice-bottom-actions {
    width: 100%;
    max-width: 1408px;
    margin: 16px auto 0;
    justify-content: flex-end;
}
.rental-contract-invoice-summary {
    display: grid;
    grid-template-columns: minmax(130px, .55fr) repeat(2, minmax(190px, 1fr));
    gap: 10px;
    margin-top: 14px;
}
.rental-contract-invoice-summary article {
    display: grid;
    gap: 3px;
    padding: 13px 15px;
    border: 1px solid #d7e5ec;
    border-radius: 11px;
    background: #f8fbfd;
}
.rental-contract-invoice-summary article.is-received {
    border-color: #bfe4d5;
    background: #f1fbf7;
}
.rental-contract-invoice-summary article.is-open {
    border-color: #cce5ee;
    background: #f2fafd;
}
.rental-contract-invoice-summary span,
.rental-contract-invoice-summary small {
    color: #5f7487;
    font-size: .74rem;
}
.rental-contract-invoice-summary strong { font-size: 1.08rem; }
.rental-contract-invoice-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}
.rental-contract-invoice-filters button {
    display: inline-flex;
    gap: 7px;
    align-items: center;
    min-height: 34px;
    padding: 7px 12px;
    border: 1px solid #c8dce5;
    border-radius: 9px;
    background: #fff;
    color: #315066;
    font: inherit;
    font-size: .8rem;
    font-weight: 800;
    cursor: pointer;
}
.rental-contract-invoice-filters button b {
    display: inline-grid;
    min-width: 22px;
    min-height: 22px;
    place-items: center;
    border-radius: 999px;
    background: #e8f3f7;
    color: #17687d;
    font-size: .7rem;
}
.rental-contract-invoice-filters button:hover,
.rental-contract-invoice-filters button:focus-visible {
    border-color: #68b9ca;
}
.rental-contract-invoice-filters button.is-active {
    border-color: #0c6c7e;
    background: #0c6c7e;
    color: #fff;
}
.rental-contract-invoice-filters button.is-active b {
    background: rgba(255, 255, 255, .2);
    color: #fff;
}
.rental-contract-invoice-groups { display: grid; gap: 10px; margin-top: 13px; }
.rental-contract-invoice-group {
    overflow: hidden;
    border: 1px solid #d8e6ed;
    border-radius: 12px;
    background: #fff;
}
.rental-contract-invoice-group > header {
    display: flex;
    gap: 16px;
    align-items: center;
    justify-content: space-between;
    min-height: 54px;
    padding: 10px 13px;
    background: #f7fbfd;
}
.rental-contract-invoice-group[data-rental-contract-invoice-group="open"] > header {
    border-left: 4px solid #2a91aa;
}
.rental-contract-invoice-group[data-rental-contract-invoice-group="open"].has-late > header {
    border-left-color: #ef476f;
}
.rental-contract-invoice-group[data-rental-contract-invoice-group="received"] > header {
    border-left: 4px solid #7c62d6;
}
.rental-contract-invoice-group[data-rental-contract-invoice-group="inactive"] > header {
    border-left: 4px solid #8a99a8;
}
.rental-contract-invoice-group > header div { display: grid; gap: 2px; }
.rental-contract-invoice-group > header span {
    color: #526a7e;
    font-size: .7rem;
    font-weight: 900;
    letter-spacing: .06em;
    text-transform: uppercase;
}
.rental-contract-invoice-group > header strong { font-size: .82rem; }
.rental-contract-invoice-list { display: grid; gap: 8px; padding: 9px; }
.rental-contract-invoice-list[hidden],
.rental-contract-invoice-group[hidden],
.rental-contract-invoice-more[hidden] { display: none; }
.rental-contract-invoice-list article {
    display: grid;
    grid-template-columns: minmax(280px, 1.6fr) minmax(150px, .7fr) auto auto;
    gap: 14px;
    align-items: center;
    padding: 13px 14px;
    border: 1px solid #dce7ee;
    border-radius: 12px;
    background: #fff;
    transition: border-color .18s ease, background-color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.rental-contract-invoice-list article:hover,
.rental-contract-invoice-list article:focus-within {
    border-color: #8cc7d5;
    background: #f8fcfd;
    box-shadow: 0 7px 18px rgba(17, 78, 96, .09);
    transform: translateY(-1px);
}
.rental-contract-invoice-list article > div { display: grid; gap: 3px; }
.rental-contract-invoice-list article span,
.rental-contract-invoice-list article small { color: #62758d; }
.rental-contract-invoice-more {
    display: block;
    width: calc(100% - 18px);
    margin: 0 9px 9px;
    padding: 9px 12px;
    border: 1px dashed #9fc9d6;
    border-radius: 9px;
    background: #f5fbfd;
    color: #0d6b7d;
    font: inherit;
    font-size: .8rem;
    font-weight: 800;
    cursor: pointer;
}
.rental-contract-invoice-more:hover,
.rental-contract-invoice-more:focus-visible {
    border-style: solid;
    background: #eaf7fb;
}
.rental-contract-invoice-empty {
    margin: 13px 0 0;
    padding: 18px;
    border: 1px dashed #cbdde5;
    border-radius: 11px;
    color: #62758d;
    text-align: center;
}
@media (prefers-reduced-motion: reduce) {
    .rental-contract-invoice-list article {
        transition: none;
    }
    .rental-contract-invoice-list article:hover,
    .rental-contract-invoice-list article:focus-within {
        transform: none;
    }
}

@media (max-width: 980px) {
    .rental-invoice-filter,
    .rental-invoice-primary-grid,
    .rental-invoice-recurrence-grid,
    .rental-invoice-reminder-grid { grid-template-columns: 1fr; }
    .rental-invoice-payment-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 720px) {
    .rental-invoice-page-header .page-actions,
    .rental-invoice-bottom-actions { display: grid; grid-template-columns: 1fr; }
    .rental-invoice-page-header .button,
    .rental-invoice-bottom-actions .button { width: 100%; }
    .rental-invoice-party-snapshot,
    .rental-invoice-payment-form { grid-template-columns: 1fr; }
    .rental-contract-invoice-summary { grid-template-columns: 1fr; }
    .rental-contract-invoice-filters { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .rental-contract-invoice-filters button { justify-content: center; }
    .rental-contract-invoice-list article { grid-template-columns: 1fr; }
    .rental-contract-invoice-list article .button { width: 100%; }
    .rental-invoice-party-snapshot article:last-child,
    .rental-invoice-payment-form .wide { grid-column: auto; }
    .rental-invoice-document-grid,
    .rental-invoice-document-form { grid-template-columns: 1fr; }
    .rental-invoice-secondary-grid.is-notes-only > .receivable-form-card { grid-column: auto; }
    .rental-invoice-document-form .wide { grid-column: auto; }
    .rental-invoice-document-list article { display: grid; }
}

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

.security-hero,
.security-panel,
.security-summary article {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #f8fdff;
}

.security-hero {
    padding: 22px;
}

.security-hero span,
.security-panel header span,
.security-summary span {
    color: #0057d8;
    font-size: .76rem;
    font-weight: 900;
    letter-spacing: .05em;
    text-transform: uppercase;
}

.security-hero h1,
.security-panel h2 {
    margin: 6px 0;
    color: var(--text);
}

.security-hero p,
.security-panel small,
.security-summary small,
.security-table small {
    color: var(--text-muted);
}

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

.security-summary article {
    display: grid;
    gap: 6px;
    padding: 16px;
}

.security-summary strong {
    color: var(--text);
    font-size: 1.6rem;
    line-height: 1;
}

.security-panel {
    overflow: hidden;
}

.security-panel > header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 18px;
    border-bottom: 1px solid var(--border);
}

.security-panel-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
}

.security-panel-actions form {
    margin: 0;
}

.security-help {
    display: grid;
    gap: 4px;
    margin: 18px 22px 14px;
    padding: 14px 16px;
    border: 1px solid #bfe2ee;
    border-radius: 8px;
    background: #eefcff;
    color: var(--text-muted);
    font-size: .86rem;
    line-height: 1.45;
}

.security-help strong {
    color: var(--text);
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.security-table-shell {
    border: 0;
    border-radius: 0;
}

.security-table {
    width: 100%;
    min-width: 840px;
    border-collapse: collapse;
}

.security-table th,
.security-table td {
    padding: 14px;
    border-bottom: 1px solid #d7e3ec;
    text-align: left;
    vertical-align: middle;
}

.security-table th {
    background: #e7edf3;
    color: var(--text);
    font-size: .76rem;
    font-weight: 900;
    text-transform: uppercase;
}

.security-table tr:last-child td {
    border-bottom: 0;
}

.security-table tr.is-current {
    background: #eefcff;
}

.security-table strong,
.security-table small {
    display: block;
}

.security-pill {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 0 12px;
    border-radius: 999px;
    background: #dcfce7;
    color: #047857;
    font-size: .76rem;
    font-weight: 900;
}

.security-pill.is-current {
    background: #c9fbff;
    color: #07576a;
}

.security-current-note {
    color: var(--text-muted);
    font-size: .84rem;
    font-weight: 800;
}

.security-table form {
    margin: 0;
}

@media screen and (max-width: 760px) {
    .security-hero,
    .security-panel > header,
    .security-summary article {
        padding: 14px;
    }

    .security-summary {
        grid-template-columns: 1fr;
    }

    .security-panel > header {
        display: grid;
        grid-template-columns: 1fr;
        align-items: start;
        gap: 6px;
    }

    .security-panel-actions {
        align-items: stretch;
        justify-content: stretch;
        flex-direction: column;
    }

    .security-panel-actions .button {
        width: 100%;
    }

    .security-panel > header small {
        font-size: .86rem;
    }

    .security-help {
        margin: 12px 12px 0;
        padding: 12px 14px;
    }

    .security-table-shell {
        overflow: visible;
    }

    .security-table {
        display: block;
        min-width: 0;
    }

    .security-table thead {
        display: none;
    }

    .security-table tbody,
    .security-table tr,
    .security-table td {
        display: block;
        width: 100%;
    }

    .security-table tbody {
        padding: 12px;
        box-sizing: border-box;
    }

    .security-table tr {
        margin: 0 0 14px;
        box-sizing: border-box;
        overflow: hidden;
        border: 1px solid var(--border);
        border-radius: 8px;
        background: #fff;
    }

    .security-table tr:last-child {
        margin-bottom: 0;
    }

    .security-table td[colspan] {
        display: block;
    }

    .security-table td[colspan]::before {
        display: none;
    }

    .security-table td[colspan] .empty {
        margin: 0;
        padding: 18px;
        text-align: left;
    }

    .security-table tr.is-current {
        background: #eefcff;
        box-shadow: inset 4px 0 0 #19c4df;
    }

    .security-table td {
        display: grid;
        grid-template-columns: minmax(112px, .46fr) minmax(0, 1fr);
        gap: 12px;
        min-width: 0;
        box-sizing: border-box;
        padding: 11px 12px;
        align-items: start;
    }

    .security-table td::before {
        content: attr(data-label);
        color: var(--text-muted);
        font-size: .72rem;
        font-weight: 900;
        line-height: 1.25;
        text-transform: uppercase;
    }

    .security-table strong,
    .security-table small {
        min-width: 0;
        overflow-wrap: anywhere;
    }

    .security-table .button {
        width: 100%;
    }
}

@media print {
    @page {
        margin: 14mm;
        size: A4;
    }

    body {
        background: #fff !important;
        color: #061b35 !important;
    }

    .authenticated-layout {
        display: none !important;
    }

    .request-print-report {
        display: block !important;
        color: #061b35;
        font-family: Arial, sans-serif;
        font-size: 12px;
    }

    .request-print-head {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 24px;
        padding-bottom: 22px;
        border-bottom: 3px solid #0ea5e9;
    }

    .request-print-brand {
        display: flex;
        align-items: center;
        gap: 12px;
    }

    .request-print-mark {
        width: 38px;
        height: 38px;
        border: 3px solid #06a6d8;
        border-radius: 11px;
        transform: rotate(-14deg);
    }

    .request-print-brand strong {
        display: block;
        font-size: 18px;
    }

    .request-print-brand small,
    .request-print-meta small {
        display: block;
        color: #37506a;
    }

    .request-print-meta {
        display: grid;
        gap: 8px;
        justify-items: end;
    }

    .request-print-meta span {
        padding: 5px 12px;
        border-radius: 999px;
        background: #cffafe;
        color: #005ea8;
        font-weight: 800;
    }

    .request-print-title {
        margin: 24px 0;
    }

    .request-print-title h1 {
        margin: 0 0 8px;
        font-size: 25px;
        line-height: 1.15;
    }

    .request-print-title p {
        margin: 0;
        color: #334e68;
        font-size: 15px;
    }

    .request-print-summary,
    .request-print-card {
        margin-bottom: 18px;
        overflow: hidden;
        border: 1px solid #d7e3ec;
        border-radius: 14px;
        break-inside: avoid;
    }

    .request-print-summary {
        padding: 18px;
        background: #f8ffff;
    }

    .request-print-summary h2 {
        margin: 0 0 8px;
        font-size: 18px;
    }

    .request-print-summary p {
        margin: 0 0 16px;
        color: #334e68;
        font-size: 14px;
    }

    .request-print-summary > div {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 10px;
    }

    .request-print-summary article,
    .request-print-production article {
        border: 1px solid #d7e3ec;
        border-radius: 12px;
        background: #fff;
    }

    .request-print-summary article {
        padding: 12px;
    }

    .request-print-summary article span,
    .request-print-grid article span,
    .request-print-card header span {
        display: block;
        color: #5d7189;
        font-size: 10px;
        font-weight: 900;
        letter-spacing: .04em;
        text-transform: uppercase;
    }

    .request-print-summary article strong {
        display: block;
        margin-top: 5px;
        font-size: 17px;
    }

    .request-print-card header {
        padding: 16px;
        border-bottom: 1px solid #d7e3ec;
        background: #f0f4f8;
    }

    .request-print-card header h2 {
        margin: 3px 0 0;
        font-size: 16px;
    }

    .request-print-grid {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        padding: 14px 18px;
    }

    .request-print-grid article {
        min-height: 42px;
        padding: 9px 4px;
        border-bottom: 1px solid #edf2f7;
    }

    .request-print-grid article strong {
        display: block;
        margin-top: 5px;
    }

    .request-print-description {
        min-height: 80px;
        padding: 16px 18px;
        line-height: 1.55;
    }

    .request-print-timeline,
    .request-print-production {
        display: grid;
        gap: 10px;
        padding: 14px 16px;
    }

    .request-print-timeline article {
        padding: 12px 14px;
        border-left: 4px solid #2563eb;
        border-radius: 0 12px 12px 0;
        background: #f5f8fc;
        break-inside: avoid;
    }

    .request-print-timeline article strong {
        display: block;
        margin-bottom: 6px;
    }

    .request-print-timeline article p {
        margin: 0 0 8px;
        color: #243b53;
        line-height: 1.45;
    }

    .request-print-timeline article small {
        color: #486581;
    }

    .request-print-production article {
        display: grid;
        grid-template-columns: 110px 90px minmax(0, 1fr);
        gap: 18px;
        align-items: center;
        min-height: 42px;
        padding: 12px;
    }

    .request-print-production article b {
        color: #1d4ed8;
        font-size: 15px;
    }

    .request-print-footer {
        display: flex;
        justify-content: space-between;
        margin-top: 24px;
        padding-top: 12px;
        border-top: 1px solid #d7e3ec;
        color: #334e68;
        font-size: 11px;
    }
}

/* Rental invoices — final cascade adjustments */
body .rental-invoices-page,
body .rental-invoice-form-page {
    width: 100%;
}

body .rental-invoice-page-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    width: 100%;
}

body .rental-invoice-page-header .page-actions {
    display: flex;
    flex: 0 0 auto;
    gap: 8px;
}

body .receivable-filter-panel.rental-invoice-filter {
    grid-template-columns: 220px 120px minmax(300px, 1fr) auto auto auto;
}

body .rental-invoice-table-card {
    overflow: hidden;
}

body .rental-invoice-table-card .table-scroll {
    overflow-x: auto;
}

body .receivable-table.rental-invoice-table {
    min-width: 1220px;
    table-layout: auto;
}

body .rental-invoice-list-toolbar {
    min-height: 64px;
}

body .rental-invoice-list-toolbar > div:first-child {
    display: grid;
    gap: 2px;
}

body .rental-invoice-list-toolbar nav {
    display: flex;
    align-items: center;
    gap: 8px;
}

body .rental-invoice-list-total {
    display: grid;
    gap: 2px;
    text-align: right;
}

body .rental-invoice-table .check-col,
body .rental-invoice-table .check-cell {
    width: 42px;
    min-width: 42px;
    text-align: center;
}

body .rental-invoice-table .check-col input,
body .rental-invoice-table .check-cell input {
    width: 16px;
    height: 16px;
    margin: 0;
}

body .rental-invoice-table .rental-invoice-id-col {
    width: 58px;
}

body .rental-invoice-table .rental-invoice-id-cell {
    width: 58px;
    min-width: 58px;
}

body .rental-invoice-table .rental-invoice-party-col {
    width: 320px;
}

body .rental-invoice-table .rental-invoice-party-cell {
    width: 320px;
    min-width: 280px;
}

body .rental-invoice-table .rental-invoice-document-col {
    width: 205px;
}

body .rental-invoice-table .rental-invoice-document-cell {
    width: 205px;
    min-width: 180px;
}

body .rental-invoice-table .rental-invoice-installment-col {
    width: 62px;
}

body .rental-invoice-table .rental-invoice-installment-cell {
    width: 62px;
    min-width: 62px;
}

body .rental-invoice-table .rental-invoice-money-col {
    width: 105px;
}

body .rental-invoice-table .rental-invoice-money-cell {
    width: 105px;
    min-width: 105px;
}

body .rental-invoice-table .rental-invoice-date-col {
    width: 105px;
}

body .rental-invoice-table .rental-invoice-date-cell {
    width: 105px;
    min-width: 105px;
}

body .rental-invoice-table .rental-invoice-frequency-col {
    width: 82px;
}

body .rental-invoice-table .rental-invoice-frequency-cell {
    width: 82px;
    min-width: 82px;
}

body .rental-invoice-table .rental-invoice-attachment-col,
body .rental-invoice-table .rental-invoice-attachment-cell {
    width: 68px;
    min-width: 68px;
    text-align: center;
}

body .rental-invoice-attachment-count {
    display: inline-flex;
    min-width: 28px;
    min-height: 28px;
    align-items: center;
    justify-content: center;
    padding: 3px 8px;
    border: 1px solid #c9dbe5;
    border-radius: 999px;
    background: #f3f8fb;
    color: #3f5f75;
    font-size: .76rem;
    font-weight: 900;
}

body .rental-invoice-table .rental-invoice-status-col {
    width: 115px;
}

body .rental-invoice-table .rental-invoice-status-cell {
    width: 115px;
    min-width: 115px;
}

body .rental-invoice-table .rental-invoice-actions-col {
    width: 128px;
}

body .rental-invoice-table .rental-invoice-actions-cell {
    width: 128px;
    min-width: 128px;
}

body .rental-invoice-table th,
body .rental-invoice-table td {
    vertical-align: middle;
    white-space: nowrap;
}

body .rental-invoice-table .rental-invoice-party-cell,
body .rental-invoice-table .rental-invoice-document-cell {
    white-space: normal;
}

body .rental-invoice-party-cell strong,
body .rental-invoice-party-cell span,
body .rental-invoice-document-cell strong {
    display: block;
}

body .rental-invoice-table .empty {
    margin: 16px 0;
    text-align: center;
}

body .rental-invoice-table-card > .requests-footer-controls {
    justify-content: space-between;
    width: 100%;
    margin-left: 0;
    padding: 16px;
    border-top: 1px solid var(--border);
}

body .rental-invoice-footer {
    align-items: center;
}

body .rental-invoice-footer .requests-footer-controls {
    padding: 0;
    border: 0;
}

body .rental-invoice-table-card > .requests-footer-controls nav {
    display: flex;
    align-items: center;
    gap: 10px;
}

body .rental-invoice-primary-grid > .receivable-form-card {
    align-content: start;
}

body .rental-invoice-contract-warning {
    display: none;
}

body .rental-invoice-contract-warning[hidden] {
    display: none !important;
}

body .rental-invoice-contract-warning.is-visible {
    display: flex;
}

body .rental-invoice-contract-warning input[type="checkbox"],
body .rental-invoice-reminder-grid input[type="checkbox"] {
    flex: 0 0 18px;
    width: 18px;
    min-height: 18px;
    height: 18px;
    margin: 2px 0 0;
    padding: 0;
}

body .rental-invoice-recurrence-grid label,
body .rental-invoice-reminder-grid label {
    display: grid;
    gap: 7px;
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 800;
}

body .rental-invoice-recurrence-grid select,
body .rental-invoice-reminder-grid input[type="number"] {
    width: 100%;
    min-height: 42px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    padding: 0 12px;
    font: inherit;
    font-weight: 700;
}

body .rental-invoice-reminder-grid label:first-child,
body .rental-invoice-reminder-grid label:nth-child(2) {
    display: flex;
    align-items: center;
    min-height: 42px;
    padding: 0 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #f8fbfd;
}

body .rental-invoice-advance-control {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px;
}

body .rental-invoice-advance-control em {
    color: var(--text-muted);
    font-style: normal;
    font-weight: 800;
}

body .rental-invoice-metrics .receivable-status-pill {
    display: inline-flex;
    width: fit-content;
}

body .rental-invoice-payments > header,
body .rental-invoice-documents > header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}

body .rental-invoice-documents > header small {
    color: #0066c8;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .05em;
}

body .rental-invoice-documents > header h2 {
    margin: 2px 0;
    font-size: 18px;
}

body .rental-invoice-documents > header em {
    flex: 0 0 auto;
    padding: 5px 10px;
    border: 1px solid #cfe1eb;
    border-radius: 999px;
    background: #f4f9fc;
    color: #526a80;
    font-style: normal;
    font-size: .78rem;
    font-weight: 800;
}

body .rental-invoice-payment-form label,
body .rental-invoice-document-form label {
    display: grid;
    gap: 6px;
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 800;
}

body .rental-invoice-payment-form input:not([type="checkbox"]),
body .rental-invoice-payment-form select,
body .rental-invoice-document-form input:not([type="file"]),
body .rental-invoice-document-form select {
    width: 100%;
    min-height: 42px;
    padding: 0 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    font: inherit;
}

body .rental-invoice-document-form input[type="file"] {
    width: 100%;
    min-height: 44px;
    padding: 5px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text-muted);
    font: inherit;
}

body .rental-invoice-document-form input[type="file"]::file-selector-button {
    min-height: 32px;
    margin-right: 10px;
    padding: 0 13px;
    border: 0;
    border-radius: 7px;
    background: var(--primary);
    color: #fff;
    cursor: pointer;
    font-weight: 800;
}

body .rental-invoice-payment-form .rental-invoice-reconciled {
    grid-column: span 2;
    min-height: 42px;
    padding: 0 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #f8fbfd;
}

body .rental-invoice-payment-form .rental-invoice-reconciled input {
    flex: 0 0 18px;
    width: 18px !important;
    min-height: 18px;
    height: 18px;
    margin: 0;
}

body .rental-invoice-payment-form > .button {
    grid-column: span 2;
    width: 100%;
    min-height: 42px;
}

body .rental-invoice-payment-history .empty,
body .rental-invoice-document-list .empty {
    display: grid;
    align-items: center;
    min-height: 82px;
    margin: 0;
    padding: 16px;
    border: 1px dashed #bfd4df;
    border-radius: 10px;
    color: var(--text-muted);
}

body .rental-invoice-party-card {
    background:
        linear-gradient(#fff, #fff) padding-box,
        linear-gradient(180deg, #fff 0%, #f5fafc 100%) border-box;
}

@media (min-width: 981px) and (max-width: 1280px) {
    body .receivable-filter-panel.rental-invoice-filter {
        grid-template-columns: 220px 120px minmax(260px, 1fr) auto;
    }

    body .rental-invoice-filter .financial-period-shortcuts {
        grid-column: 1 / 4;
        justify-self: start;
    }

    body .rental-invoice-filter .receivable-more-filters {
        grid-column: 4;
    }
}

@media (max-width: 980px) {
    body .receivable-filter-panel.rental-invoice-filter {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    body .rental-invoice-filter .filter-grow,
    body .rental-invoice-filter .financial-period-shortcuts,
    body .rental-invoice-filter .receivable-more-filters {
        grid-column: 1 / -1;
    }

    body .rental-invoice-filter .financial-period-shortcuts {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    body .rental-invoice-filter .receivable-more-filters > summary {
        width: 100%;
    }
}

@media (max-width: 720px) {
    body .rental-invoice-page-header,
    body .rental-invoice-page-header .page-actions,
    body .receivable-filter-panel.rental-invoice-filter,
    body .rental-invoice-list-toolbar,
    body .rental-invoice-table-card > .requests-footer-controls,
    body .rental-invoice-table-card > .requests-footer-controls nav {
        display: grid;
        grid-template-columns: 1fr;
    }

    body .rental-invoice-page-header .button,
    body .rental-invoice-table-card > .requests-footer-controls .button {
        width: 100%;
    }

    body .rental-invoice-filter .filter-grow {
        grid-column: auto;
    }

    body .rental-invoice-filter .financial-period-shortcuts,
    body .rental-invoice-filter .receivable-more-filters {
        grid-column: auto;
    }

    body .rental-invoice-list-total {
        text-align: left;
    }

    body .receivable-table.rental-invoice-table {
        min-width: 1220px;
    }

    body .rental-invoice-payment-form .rental-invoice-reconciled,
    body .rental-invoice-payment-form > .button {
        grid-column: auto;
    }

    body .rental-invoice-payments > header,
    body .rental-invoice-documents > header {
        display: grid;
        grid-template-columns: 1fr;
    }

    body .rental-invoice-documents > header em {
        justify-self: start;
    }
}

/* Requests operational CRUD */
.requests-shell {
    background: #eef5fb;
}

.requests-page,
.request-edit-page {
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-width: 1480px;
    margin: 0 auto;
}

.request-edit-page {
    padding-top: 0;
}

.requests-hero,
.request-edit-hero {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
}

.request-edit-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    min-height: 108px;
}

.requests-title-block h1,
.request-edit-hero h1 {
    margin: 0;
    color: var(--text);
    font-size: 2rem;
    line-height: 1.15;
}

.requests-title-block p,
.request-edit-hero p {
    margin: 8px 0 0;
    color: var(--text-muted);
}

.requests-hero-actions,
.request-edit-actions,
.request-bottom-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-end;
}

.request-bottom-actions {
    justify-content: space-between;
    align-items: center;
}

.request-bottom-danger,
.request-bottom-primary {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.request-bottom-danger form {
    margin: 0;
}

.receivable-bottom-actions {
    margin-top: 4px;
    padding-top: 16px;
    border-top: 1px solid #d8e8ef;
}

.payable-bottom-actions {
    align-items: center;
    justify-content: space-between;
}

.payable-bottom-actions > form {
    margin: 0;
}

.payable-bottom-actions .receivable-bottom-primary-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-end;
    margin-left: auto;
}

.requests-metrics-row {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.request-metric-card {
    min-height: 96px;
    padding: 18px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.request-metric-card span,
.request-metric-card small {
    display: block;
    color: var(--text-muted);
    font-weight: 700;
}

.request-metric-card strong {
    display: block;
    margin: 6px 0;
    color: var(--text);
    font-size: 1.75rem;
    line-height: 1;
}

.request-metric-card.metric-blue {
    background: linear-gradient(135deg, #fff, #eff6ff);
}

.request-metric-card.metric-green {
    background: linear-gradient(135deg, #fff, #ecfdf5);
}

.request-metric-card.metric-orange {
    background: linear-gradient(135deg, #fff, #fff7ed);
}

.request-metric-card.metric-purple {
    background: linear-gradient(135deg, #fff, #f5f3ff);
}

.proposals-page {
    display: flex;
    flex-direction: column;
    gap: 18px;
    min-width: 0;
    max-width: 1480px;
    margin: 0 auto;
    padding: 28px 0 44px;
}

.proposals-hero {
    display: grid;
    grid-template-columns: minmax(280px, 1fr) minmax(520px, .95fr);
    gap: 18px;
    align-items: stretch;
    padding: 18px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.proposals-title-block {
    padding-left: 14px;
    border-left: 4px solid #2563eb;
}

.proposals-title-block span,
.proposal-section-head span {
    display: block;
    color: #0057d8;
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.proposals-title-block h1,
.proposal-section-head h2 {
    margin: 8px 0 6px;
    color: var(--text);
}

.proposals-title-block p,
.proposal-section-head p,
.proposal-offer-cell small,
.proposals-summary small {
    margin: 0;
    color: var(--text-muted);
}

.proposals-summary {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
}

.proposals-summary article {
    min-height: 78px;
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #f8fcff;
}

.proposals-summary span {
    display: block;
    color: var(--text-muted);
    font-size: .76rem;
    font-weight: 800;
}

.proposals-summary strong {
    display: block;
    margin-top: 6px;
    color: var(--text);
    font-size: 1.55rem;
    line-height: 1.1;
}

.proposals-summary .summary-text {
    font-size: .9rem;
    overflow-wrap: anywhere;
}

.proposal-offers-panel,
.proposal-sent-panel {
    display: flex;
    flex-direction: column;
    gap: 14px;
    min-width: 0;
    padding: 14px;
    border: 1px solid #ff9c55;
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.proposal-sent-panel {
    border-color: #48d7ef;
    background: #f8fdff;
}

.proposal-search-panel,
.proposal-section-head,
.proposal-footer,
.proposal-pagination {
    display: flex;
    gap: 12px;
    align-items: center;
}

.proposal-search-panel,
.proposal-section-head {
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #f8fcff;
}

.proposal-search-panel input {
    flex: 1 1 auto;
    min-width: 0;
    width: 100%;
    min-height: 42px;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 0 12px;
    color: var(--text);
    font: inherit;
    font-weight: 700;
}

.proposal-section-head {
    justify-content: space-between;
}

.proposal-history-head h2 {
    display: flex;
    align-items: center;
    gap: 8px;
}

.proposal-history-head h2 strong {
    display: inline-grid;
    min-width: 24px;
    height: 24px;
    place-items: center;
    border-radius: 999px;
    background: #dcfaff;
    color: #005e8a;
    font-size: .82rem;
}

.proposal-history-head p {
    margin: 0;
    color: #466176;
    font-size: .82rem;
    font-weight: 700;
}

.proposal-history-filters {
    align-items: flex-end;
}

.proposal-history-filters > input[type="search"] {
    flex: 1 1 420px;
}

.proposal-history-filters label {
    display: flex;
    flex: 0 0 140px;
    flex-direction: column;
    gap: 4px;
    color: var(--text-muted);
    font-size: .76rem;
    font-weight: 800;
}

.proposal-history-filters label input {
    min-height: 42px;
    font-weight: 800;
}

.proposal-per-page label {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 800;
    white-space: nowrap;
}

.proposal-per-page select {
    min-height: 36px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    padding: 0 8px;
    font: inherit;
    font-weight: 700;
}

.proposal-table-shell {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.proposal-offer-table {
    width: 100%;
    min-width: 980px;
    border-collapse: collapse;
}

.proposal-offer-table th,
.proposal-offer-table td {
    padding: 14px 12px;
    border-bottom: 1px solid #d7e3ec;
    text-align: left;
    vertical-align: middle;
}

.proposal-offer-table th {
    background: #e7edf3;
    color: var(--text);
    font-size: .78rem;
    font-weight: 900;
    text-transform: uppercase;
}

.proposal-offer-table tr:last-child td {
    border-bottom: 0;
}

.proposal-offer-table tbody tr {
    transition: background-color .16s ease, box-shadow .16s ease;
}

.proposal-offer-table tbody tr:hover:not(.proposal-review-row) {
    background: #f0fbff;
}

.proposal-offer-table tbody tr.is-selected,
.proposal-offer-table tbody tr.is-review-open {
    background: #eefcff;
    box-shadow: inset 4px 0 0 #19c4df;
}

.proposal-offer-cell strong,
.proposal-offer-cell small {
    display: block;
}

.proposal-group-pill,
.proposal-document-pill,
.proposal-status-pill {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 0 12px;
    border-radius: 999px;
    font-size: .76rem;
    font-weight: 900;
    white-space: nowrap;
}

.proposal-group-pill {
    border: 1px solid #94e9f2;
    background: #c9fbff;
    color: #07576a;
}

.proposal-document-pill.is-ready,
.proposal-status-pill.is-active {
    background: #dcfce7;
    color: #047857;
}

.proposal-document-pill.is-pending {
    background: #eef2f7;
    color: #52677a;
}

.proposal-status-pill.is-inactive {
    background: #fee2e2;
    color: #b91c1c;
}

.proposal-status-pill.is-draft {
    background: #e8eff5;
    color: #43556a;
}

.proposal-status-pill.is-sent {
    background: #e6f0ff;
    color: #005cce;
}

.proposal-status-pill.is-cancelled {
    background: #ffe7eb;
    color: #c21d3a;
}

.proposal-link-pending {
    color: #0060bd;
    font-weight: 800;
}

.proposal-public-link {
    color: #0057d8;
    font-weight: 900;
    text-decoration: none;
}

.proposal-public-link:hover,
.proposal-public-link:focus {
    text-decoration: underline;
}

.proposal-row-actions {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.proposal-row-actions form {
    margin: 0;
}

.proposal-delete-disabled,
.proposal-delete-disabled:hover,
.proposal-delete-disabled:focus {
    cursor: not-allowed;
    opacity: .58;
    box-shadow: none;
}

.proposal-footer {
    justify-content: space-between;
    padding-top: 4px;
}

.proposal-pagination .is-disabled {
    pointer-events: none;
    opacity: .55;
}

.button-proposal-start {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 0 14px;
    border: 1px solid #7ed9ff;
    border-radius: 8px;
    background: #e8fbff;
    color: #075f85;
    font-weight: 900;
    text-decoration: none;
}

.button-proposal-start:hover,
.button-proposal-start:focus {
    outline: none;
    border-color: #2ebff0;
    background: #d6f6ff;
    color: #064f70;
    box-shadow: 0 0 0 2px rgba(46, 191, 240, .14);
}

.proposal-modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 60;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 24px;
    background: rgba(15, 23, 42, .48);
    overflow: auto;
}

.proposal-modal {
    display: flex;
    flex-direction: column;
    width: min(980px, 100%);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 24px 70px rgba(15, 23, 42, .25);
    overflow: visible;
}

.proposal-modal > form {
    display: flex;
    flex-direction: column;
    min-height: 0;
    border-radius: inherit;
    background: #fff;
}

.proposal-modal-head,
.proposal-modal-footer {
    display: flex;
    flex-shrink: 0;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 20px 22px;
    border-bottom: 1px solid #d7e3ec;
}

.proposal-modal-footer {
    justify-content: flex-end;
    border-top: 1px solid #d7e3ec;
    border-bottom: 0;
}

.proposal-modal-head span,
.proposal-material-card span,
.proposal-form-section span {
    display: block;
    color: #0057d8;
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.proposal-modal-head h2 {
    margin: 8px 0;
    color: var(--text);
    font-size: 1.65rem;
}

.proposal-modal-head p,
.proposal-material-card p,
.proposal-form-section p,
.proposal-form-section small {
    margin: 0;
    color: var(--text-muted);
}

.proposal-material-card p {
    font-size: .82rem;
    font-weight: 700;
}

.proposal-modal-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text);
    font-weight: 900;
    text-decoration: none;
}

.proposal-modal-body {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    gap: 16px;
    min-height: 0;
    padding: 20px 22px;
    overflow: visible;
}

.proposal-form-section,
.proposal-identity-card {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    padding: 16px;
    border: 1px solid #b9e6f0;
    border-radius: 8px;
    background: #f4fdff;
}

.proposal-material-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px;
    gap: 12px 18px;
    padding: 16px;
    border: 1px solid #b9e6f0;
    border-radius: 8px;
    background: #f4fdff;
}

.proposal-check-option,
.proposal-identity-card label {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text);
    font-weight: 800;
}

.proposal-default-file-card {
    display: grid;
    gap: 5px;
    max-width: 560px;
    min-height: 66px;
    padding: 11px 14px;
    border: 1px solid #b8dcff;
    border-radius: 8px;
    background: linear-gradient(135deg, #f8fbff, #eaf4ff);
    color: var(--text);
    text-decoration: none;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .85);
}

.proposal-default-file-card:hover,
.proposal-default-file-card:focus {
    outline: none;
    border-color: #66b8ff;
    background: linear-gradient(135deg, #fff, #dff0ff);
    box-shadow: 0 0 0 2px rgba(102, 184, 255, .14);
}

.proposal-default-file-card span {
    color: #0057d8;
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: 0;
    text-transform: none;
}

.proposal-default-file-card strong {
    color: var(--text);
    overflow-wrap: anywhere;
}

.proposal-default-file-card small {
    color: var(--text-muted);
    font-weight: 700;
}

.proposal-default-file-card.is-empty {
    background: #f8fafc;
}

.proposal-specific-file {
    display: none;
    grid-column: 1 / -1;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
    padding-top: 12px;
    border-top: 1px solid #d7e3ec;
}

.proposal-material-card:has(.proposal-check-option input:checked) .proposal-specific-file {
    display: flex;
}

.proposal-specific-file-name {
    display: inline-flex;
    min-height: 34px;
    align-items: center;
    max-width: min(420px, 100%);
    padding: 0 12px;
    border: 1px solid #b8dcff;
    border-radius: 8px;
    background: #eef7ff;
    color: #075985;
    font-weight: 900;
    overflow-wrap: anywhere;
}

.proposal-specific-file [hidden],
.proposal-specific-file-name[hidden] {
    display: none;
}

.proposal-form-section {
    display: block;
    border-color: #c9d7ff;
    background: #f5f7ff;
}

.proposal-form-section h3 {
    margin: 8px 0 4px;
    color: var(--text);
}

.proposal-form-section label,
.proposal-recipient-grid label,
.proposal-full-field,
.proposal-text-preview {
    display: flex;
    flex-direction: column;
    gap: 7px;
    margin-top: 14px;
    color: var(--text);
    font-size: .82rem;
    font-weight: 900;
}

.proposal-form-section input,
.proposal-recipient-grid input,
.proposal-full-field input {
    width: 100%;
    min-height: 42px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    padding: 0 12px;
    font: inherit;
    font-weight: 700;
}

.proposal-recipient-grid input[readonly] {
    background: #eef4f8;
    color: #486175;
    border-color: #b7ccda;
}

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

.proposal-identity-card {
    align-items: center;
    border-color: #c9d7ff;
    background: #f5f7ff;
}

.proposal-identity-card [hidden] {
    display: none;
}

.proposal-simple-editor .request-editor-surface {
    min-height: 120px;
}

.proposal-simple-editor {
    min-height: 0;
    overflow: visible;
    resize: none;
}

.proposal-preview-panel {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 52px 18px 28px;
    background: rgba(15, 23, 42, .34);
    overflow: auto;
}

.proposal-preview-panel[hidden] {
    display: none;
}

.proposal-preview-dialog {
    width: min(760px, 100%);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 24px 72px rgba(15, 23, 42, .26);
    overflow: hidden;
}

.proposal-preview-head,
.proposal-preview-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px;
    border-bottom: 1px solid #d7e3ec;
}

.proposal-preview-footer {
    justify-content: flex-end;
    border-top: 1px solid #d7e3ec;
    border-bottom: 0;
}

.proposal-preview-head span {
    display: block;
    color: #0057d8;
    font-size: .76rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.proposal-preview-head h3 {
    margin: 6px 0 0;
    color: var(--text);
}

.proposal-preview-body {
    padding: 28px 44px;
    background: #eef5fb;
}

.proposal-preview-mail {
    padding: 18px;
    border: 1px solid #d7e3ec;
    border-radius: 8px;
    background: #fff;
    color: var(--text);
}

.proposal-preview-mail.is-premium {
    border-top: 5px solid #2563eb;
    box-shadow: 0 12px 28px rgba(37, 99, 235, .12);
}

.proposal-preview-mail > span {
    display: block;
    color: #0057d8;
    font-size: .76rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.proposal-preview-mail h4 {
    margin: 8px 0 18px;
    color: var(--text);
    font-size: 1.35rem;
}

.proposal-preview-mail div {
    color: var(--text);
    line-height: 1.55;
}

.proposal-review-modal {
    width: min(860px, 100%);
}

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

.proposal-review-grid article,
.proposal-review-link {
    min-width: 0;
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #f8fcff;
}

.proposal-review-grid span,
.proposal-review-link span {
    display: block;
    color: #0057d8;
    font-size: .74rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.proposal-review-grid strong,
.proposal-review-link strong {
    display: block;
    margin-top: 8px;
    color: var(--text);
    overflow-wrap: anywhere;
}

.proposal-review-grid small,
.proposal-review-link small {
    display: block;
    margin-top: 4px;
    color: var(--text-muted);
    overflow-wrap: anywhere;
}

.proposal-review-link {
    background: #f3fbff;
}

.proposal-timeline {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.proposal-timeline summary {
    display: flex;
    min-height: 48px;
    cursor: pointer;
    list-style: none;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 0 14px;
    color: #0057d8;
    font-size: .76rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.proposal-timeline summary::-webkit-details-marker {
    display: none;
}

.proposal-timeline summary::before {
    content: '+';
    display: inline-grid;
    width: 22px;
    height: 22px;
    flex: 0 0 22px;
    place-items: center;
    border: 1px solid var(--border);
    border-radius: 999px;
    color: #005e8a;
    font-size: 1rem;
    line-height: 1;
}

.proposal-timeline[open] summary::before {
    content: '-';
}

.proposal-timeline summary span {
    flex: 1;
}

.proposal-timeline summary strong {
    display: inline-grid;
    min-width: 24px;
    height: 24px;
    place-items: center;
    border-radius: 999px;
    background: #dcfaff;
    color: #005e8a;
    font-size: .78rem;
}

.proposal-timeline ol {
    display: grid;
    gap: 0;
    margin: 0;
    padding: 0 14px 14px 42px;
    list-style: none;
}

.proposal-timeline li {
    position: relative;
    padding: 12px 0 12px 16px;
    border-left: 1px solid var(--border);
}

.proposal-timeline li::before {
    content: '';
    position: absolute;
    top: 18px;
    left: -5px;
    width: 9px;
    height: 9px;
    border-radius: 999px;
    background: #19c4df;
}

.proposal-timeline time {
    display: block;
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 800;
}

.proposal-timeline li strong {
    display: block;
    margin-top: 4px;
    color: var(--text);
    font-size: .92rem;
}

.proposal-timeline li p {
    margin: 4px 0 0;
    color: var(--text-muted);
    font-size: .84rem;
    line-height: 1.45;
}

.proposal-offer-table tr.is-review-open td {
    border-bottom-color: transparent;
}

.proposal-review-row > td {
    padding: 0;
    background: #eefcff;
}

.proposal-review-inline {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 160px;
    gap: 14px;
    padding: 16px;
    border-left: 4px solid #19c4df;
    background: #eefcff;
}

.proposal-review-main {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 12px;
}

.proposal-review-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.proposal-review-title span,
.proposal-review-field {
    color: #0057d8;
    font-size: .76rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.proposal-review-title h3 {
    margin: 6px 0 0;
    color: var(--text);
    font-size: 1.2rem;
}

.proposal-review-edit-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.proposal-review-edit-actions .button-warning {
    border-color: #f0a83a;
    background: #fff7e8;
    color: #8a4a00;
}

.proposal-review-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.proposal-review-field input {
    min-height: 42px;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 0 12px;
    color: var(--text);
    font: inherit;
    font-weight: 800;
}

.proposal-review-field input[readonly] {
    background: #f8fafc;
}

.proposal-review-identity {
    margin: 0;
}

.proposal-review-body {
    min-height: 260px;
    padding: 18px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    line-height: 1.55;
}

.proposal-review-body.is-premium {
    border-top: 5px solid #2563eb;
}

.proposal-review-side {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.proposal-review-side .button {
    width: 100%;
    justify-content: center;
}

.proposal-public-page {
    min-height: 100vh;
    margin: 0;
    background: #eef7fb;
    color: var(--text);
}

.proposal-public-shell {
    width: min(980px, calc(100% - 32px));
    margin: 0 auto;
    padding: 36px 0;
}

.proposal-public-card {
    padding: 28px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.proposal-public-card.is-premium {
    border-top: 5px solid #2563eb;
}

.proposal-public-card > span,
.proposal-public-head span,
.proposal-public-meta span {
    display: block;
    color: #0057d8;
    font-size: .74rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.proposal-public-card h1 {
    margin: 8px 0 10px;
    font-size: clamp(1.8rem, 3vw, 2.4rem);
}

.proposal-public-card p {
    margin: 0;
    color: var(--text-muted);
    line-height: 1.55;
}

.proposal-public-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
}

.proposal-public-head-badges {
    display: flex;
    align-items: flex-end;
    flex-direction: column;
    gap: 8px;
}

.proposal-public-head-badges strong {
    display: inline-flex;
    min-height: 30px;
    align-items: center;
    padding: 0 12px;
    border-radius: 999px;
    background: #dcfaff;
    color: #005e8a;
    font-size: .82rem;
}

.proposal-public-meta {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 12px;
    margin-top: 24px;
}

.proposal-public-meta article {
    min-width: 0;
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #f8fcff;
}

.proposal-public-meta strong,
.proposal-public-meta small {
    display: block;
    margin-top: 7px;
    overflow-wrap: anywhere;
}

.proposal-public-meta small {
    color: var(--text-muted);
}

.proposal-public-body {
    margin-top: 22px;
    padding-top: 22px;
    border-top: 1px solid var(--border);
    line-height: 1.65;
}

.proposal-public-material {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-top: 24px;
    padding: 16px 18px;
    border: 1px solid #b7e8c7;
    border-radius: 8px;
    background: #ecfdf3;
}

.proposal-public-material span {
    display: block;
    color: #047857;
    font-size: .74rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.proposal-public-material strong {
    display: block;
    margin-top: 8px;
    color: #001b44;
    overflow-wrap: anywhere;
}

.proposal-public-material a {
    flex: 0 0 auto;
    padding: 11px 18px;
    border-radius: 7px;
    background: #16a34a;
    color: #fff;
    font-weight: 900;
    text-decoration: none;
}

.request-filter-panel {
    display: grid;
    grid-template-columns: 230px 180px 78px minmax(220px, 1fr) auto auto auto;
    gap: 14px;
    align-items: end;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.request-filter-panel .button {
    min-height: 42px;
    white-space: nowrap;
}

.request-filter-panel .button.is-active {
    border-color: #0f6476;
    background: #e6fbff;
    color: #064f5f;
    box-shadow: inset 0 0 0 1px rgba(15, 100, 118, .12);
}

.request-filter-panel .filter-id input {
    text-align: center;
}

.request-filter-panel label,
.request-form-grid label,
.interaction-compose label,
.exam-entry-preview label,
.request-document-form label,
.request-total-field {
    display: flex;
    flex-direction: column;
    gap: 7px;
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 800;
}

.request-filter-panel input,
.request-filter-panel select,
.request-form-grid input,
.request-form-grid select,
.request-form-grid textarea,
.interaction-compose input,
.interaction-compose select,
.interaction-compose textarea,
.exam-entry-preview input,
.request-document-form input,
.request-total-field input {
    width: 100%;
    min-height: 42px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    padding: 0 12px;
    font: inherit;
    font-weight: 700;
}

.request-form-grid input[readonly],
.request-form-grid textarea[readonly],
.interaction-compose input[readonly],
.interaction-compose textarea[readonly] {
    border-color: #d6e6ef;
    background: #f5f9fc;
    color: #355064;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .64);
    cursor: default;
}

.request-form-grid input[readonly]:focus,
.request-form-grid textarea[readonly]:focus,
.interaction-compose input[readonly]:focus,
.interaction-compose textarea[readonly]:focus {
    outline: none;
    border-color: #b9d7e5;
}

.request-filter-panel input:focus,
.request-filter-panel select:focus,
.request-form-grid input:focus,
.request-form-grid select:focus,
.request-form-grid textarea:focus,
.interaction-compose input:focus,
.interaction-compose select:focus,
.interaction-compose textarea:focus,
.exam-entry-preview input:focus,
.request-document-form input:focus,
.request-production-demand input:focus,
.request-total-field input:focus {
    outline: none;
    border-color: #1b93aa;
    box-shadow: 0 0 0 3px rgba(27, 147, 170, .12);
}

.request-form-grid textarea,
.interaction-compose textarea {
    min-height: 150px;
    padding-top: 12px;
    resize: vertical;
}

.request-table-card,
.request-form-card,
.request-technical-history {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.request-table-card {
    overflow: hidden;
}

.request-technical-history {
    overflow: hidden;
}

.request-technical-history-head {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: flex-start;
    padding: 16px 18px;
    cursor: pointer;
    list-style: none;
}

.request-technical-history-head::-webkit-details-marker {
    display: none;
}

.request-technical-history-head span {
    color: var(--primary);
    font-size: .76rem;
    font-weight: 900;
    letter-spacing: .04em;
}

.request-technical-history-head h2 {
    margin: 4px 0 0;
    color: var(--text);
    font-size: 1rem;
}

.request-technical-history-head strong {
    color: var(--text-muted);
    font-size: .78rem;
    white-space: nowrap;
}

.request-technical-history-head strong::after {
    content: " - Mostrar";
    color: var(--primary);
}

.request-technical-history[open] .request-technical-history-head {
    border-bottom: 1px solid var(--border);
}

.request-technical-history[open] .request-technical-history-head strong::after {
    content: " - Ocultar";
}

.request-technical-history-list {
    display: grid;
    margin: 14px 18px 18px;
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
    background: #f7fbff;
}

.request-technical-history-list article {
    display: grid;
    grid-template-columns: 170px minmax(0, 1fr);
    gap: 14px;
    align-items: center;
    padding: 11px 14px;
    border-bottom: 1px solid var(--border);
}

.request-technical-history-list article:last-child {
    border-bottom: 0;
}

.request-technical-history-list time {
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 900;
}

.request-technical-history-list p {
    margin: 0;
    color: var(--text);
    font-size: .84rem;
}

.requests-table-shell {
    overflow-x: auto;
}

.request-operational-table {
    width: 100%;
    min-width: 1180px;
    table-layout: fixed;
    border-collapse: collapse;
}

.request-operational-table th,
.request-operational-table td {
    padding: 14px 12px;
    border-bottom: 1px solid var(--border);
    text-align: left;
    vertical-align: middle;
}

.request-operational-table thead th {
    background: #e9eef5;
    color: var(--text);
    font-size: .78rem;
    font-weight: 900;
}

.request-operational-table tbody tr {
    background: #fff;
    transition: background-color .15s ease;
}

.request-operational-table tbody tr:hover {
    background: #f4fbfd;
}

.request-operational-table tbody tr.is-selected-row {
    background: #eaf8fb;
}

.request-operational-table tbody tr:hover td:first-child {
    box-shadow: inset 4px 0 0 rgba(23, 101, 118, .38);
}

.request-operational-table tbody tr.is-selected-row td:first-child {
    box-shadow: inset 4px 0 0 var(--accent);
}

.request-operational-table .check-col,
.request-operational-table .check-cell {
    width: 42px;
    text-align: center;
}

.request-operational-table .id-col {
    width: 60px;
}

.request-operational-table .client-main-col {
    width: 260px;
}

.request-operational-table .author-col {
    width: 145px;
}

.request-operational-table th:last-child,
.request-operational-table td:last-child {
    width: 205px;
}

.client-cell strong {
    display: block;
    overflow: hidden;
    color: var(--text);
    font-weight: 900;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.client-cell small,
.production-cell small {
    display: block;
    margin-top: 4px;
    overflow: hidden;
    color: var(--text-muted);
    font-size: .76rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.request-category-pill,
.request-status-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    padding: 5px 10px;
    border-radius: 999px;
    font-size: .74rem;
    font-weight: 900;
    white-space: nowrap;
}

.request-category-pill {
    border: 1px solid #a5f3fc;
    background: #cffafe;
    color: #0e7490;
}

.request-status-pill.new {
    background: #dbeafe;
    color: #1d4ed8;
}

.request-status-pill.progress {
    background: #d1fae5;
    color: #047857;
}

.request-status-pill.waiting {
    background: #ffedd5;
    color: #b45309;
}

.request-status-pill.validation {
    background: #ede9fe;
    color: #6d28d9;
}

.request-status-pill.paused {
    background: #e5e7eb;
    color: #475569;
}

.request-status-pill.done {
    background: #dcfce7;
    color: #166534;
}

.request-table-actions {
    display: flex;
    flex-wrap: nowrap;
    gap: 7px;
    align-items: center;
    white-space: nowrap;
}

.request-table-actions form {
    margin: 0;
}

.request-table-actions .button {
    min-width: 82px;
    justify-content: center;
}

.request-disabled-action,
.request-disabled-action:hover,
.request-disabled-action:focus {
    border-color: #d7dee8;
    background: #eef2f7;
    color: #94a3b8;
    box-shadow: none;
    cursor: not-allowed;
    opacity: 1;
}

.requests-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    border-top: 1px solid var(--border);
    padding: 16px 20px;
}

.requests-footer-controls {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-left: auto;
}

.requests-footer-controls label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-muted);
    font-weight: 800;
    white-space: nowrap;
}

.requests-footer-controls select {
    width: 58px;
    min-height: 38px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    padding: 0 8px;
    font: inherit;
    font-weight: 800;
}

.pagination-position {
    white-space: nowrap;
}

.pagination-goto {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--text-muted);
    white-space: nowrap;
}

.pagination-goto input[type="number"] {
    width: 72px;
    min-height: 38px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    padding: 0 8px;
    text-align: center;
    font: inherit;
    font-weight: 800;
}

.pagination-goto .button {
    min-height: 38px;
    padding-inline: 12px;
}

@media (min-width: 1401px) {
    .receivable-footer .requests-footer-controls {
        flex-wrap: nowrap;
    }
}

@media (max-width: 760px) {
    .pagination-goto {
        display: grid;
        grid-template-columns: auto minmax(64px, 1fr) auto;
        width: 100%;
    }

    .pagination-goto input[type="number"] {
        width: 100%;
    }
}

/* Receivables visual prototype */
.receivables-shell {
    background: #eef5fb;
}

.receivables-page {
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-width: 1480px;
    margin: 0 auto;
}

.receivables-hero {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
}

.financial-hero-tools {
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    gap: 18px;
}

.financial-context-preview {
    display: grid;
    gap: 5px;
}

.financial-context-preview > small {
    color: var(--text-muted);
    font-size: .68rem;
    font-weight: 900;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.financial-context-options {
    display: inline-flex;
    padding: 3px;
    border: 1px solid #d7e0e8;
    border-radius: 10px;
    background: #f5f7f9;
}

.financial-context-option {
    position: relative;
    min-width: 78px;
    padding: 8px 12px;
    border-radius: 7px;
    color: #506578;
    font-size: .76rem;
    font-weight: 800;
    text-align: center;
    cursor: pointer;
    text-decoration: none;
    user-select: none;
}

.financial-context-option:hover,
.financial-context-option:focus-visible {
    background: #e5edf4;
    color: #123e53;
    outline: none;
}

.financial-context-option.is-active {
    background: #087f9d;
    color: #fff;
    box-shadow: 0 4px 10px rgba(8, 127, 157, .2);
}

.financial-form-context {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 4px 10px;
    border: 1px solid #b9d8e2;
    border-radius: 999px;
    background: #eaf6f9;
    color: #12657a;
    font-size: .72rem;
    font-weight: 900;
    letter-spacing: .04em;
    vertical-align: middle;
}

.financial-form-context.personal {
    border-color: #d5c6ee;
    background: #f3effb;
    color: #65459a;
}

.receivables-metrics-row .request-metric-card strong {
    font-size: 1.55rem;
}

.receivable-late-card {
    background: linear-gradient(135deg, #fff, #fff1f2);
}

.receivable-filter-panel {
    display: grid;
    grid-template-columns: 220px 120px minmax(240px, 1fr) auto auto auto;
    gap: 14px;
    align-items: end;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.rental-tenant-filter-panel {
    grid-template-columns: minmax(280px, 1fr) 160px 180px auto auto;
}

.financial-period-shortcuts {
    display: inline-flex;
    min-height: 42px;
    padding: 3px;
    border: 1px solid #d7e2eb;
    border-radius: 10px;
    background: #f2f6fa;
}

.financial-period-shortcut {
    min-width: 78px;
    padding: 0 11px;
    border: 0;
    border-radius: 7px;
    background: transparent;
    color: #4e6480;
    font: inherit;
    font-size: .74rem;
    font-weight: 850;
    white-space: nowrap;
    cursor: pointer;
    transition: background .15s ease, color .15s ease, box-shadow .15s ease;
}

.financial-period-shortcut:hover,
.financial-period-shortcut:focus-visible {
    background: #fff;
    color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 2px rgba(14, 116, 135, .12);
}

.financial-period-shortcut.is-active {
    background: #0e8295;
    color: #fff;
    box-shadow: 0 4px 10px rgba(14, 130, 149, .22);
}

.financial-active-period {
    justify-self: start;
    margin-bottom: 3px;
    padding: 4px 8px;
    border: 1px solid #bfe4e8;
    border-radius: 999px;
    background: #effafb;
    color: #146778;
    font-size: .7rem;
    font-weight: 850;
}

.receivable-filter-panel label,
.receivable-more-filter-grid label {
    display: flex;
    flex-direction: column;
    gap: 7px;
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 800;
}

.receivable-filter-panel input,
.receivable-filter-panel select {
    width: 100%;
    min-height: 42px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    padding: 0 12px;
    font: inherit;
    font-weight: 700;
}

.receivable-filter-panel input:focus,
.receivable-filter-panel select:focus {
    outline: none;
    border-color: #1b93aa;
    box-shadow: 0 0 0 3px rgba(27, 147, 170, .12);
}

.receivable-filter-panel .button,
.receivable-more-filters > summary {
    min-height: 42px;
    white-space: nowrap;
}

.receivable-more-filters {
    position: relative;
}

.receivable-more-filters > summary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-width: 126px;
    padding: 0 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--primary);
    font-weight: 800;
    cursor: pointer;
    list-style: none;
}

.receivable-more-filters > summary::-webkit-details-marker {
    display: none;
}

.receivable-more-filters > summary::before {
    content: "+";
    font-weight: 900;
}

.receivable-more-filters[open] > summary::before {
    content: "-";
}

.receivable-more-filter-grid {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    z-index: 12;
    display: grid;
    grid-template-columns: repeat(4, minmax(150px, 1fr));
    gap: 14px;
    width: min(980px, calc(100vw - 300px));
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 36px rgba(15, 40, 60, .14);
}

.receivable-more-filter-grid .button {
    align-self: end;
    justify-content: center;
}

.receivable-table-card {
    overflow: visible;
}

.receivable-list-toolbar {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
    background: #f8fcfe;
}

.receivable-list-toolbar div {
    display: grid;
    gap: 2px;
    min-width: 0;
}

.receivable-list-toolbar strong {
    color: var(--text);
    font-size: .9rem;
}

.receivable-list-toolbar small {
    color: var(--text-muted);
    font-size: .78rem;
}

.receivable-list-toolbar nav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
}

.receivable-list-toolbar .button:disabled {
    opacity: .55;
    cursor: not-allowed;
}

.account-selection-summary {
    position: relative;
    display: inline-flex;
}

.account-selection-summary-panel {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    z-index: 22;
    display: grid;
    width: 210px;
    gap: 6px;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    box-shadow: 0 16px 32px rgba(15, 40, 60, .18);
    text-align: left;
    white-space: normal;
}

.account-selection-summary-panel[hidden] {
    display: none;
}

.account-selection-summary-panel strong {
    color: var(--text);
    font-size: .84rem;
}

.account-selection-summary-panel span {
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 700;
}

.account-selection-summary-panel b {
    color: var(--primary);
    font-weight: 900;
}

.receivable-table-shell {
    overflow-x: auto;
    border-radius: 0;
}

.receivable-table {
    width: 100%;
    min-width: 1360px;
    table-layout: fixed;
    border-collapse: collapse;
}

.receivable-table th,
.receivable-table td {
    padding: 13px 10px;
    border-bottom: 1px solid var(--border);
    text-align: left;
    vertical-align: middle;
}

.receivable-table thead th {
    background: #e9eef5;
    color: var(--text);
    font-size: .76rem;
    font-weight: 900;
    text-transform: uppercase;
}

.receivable-table tbody tr {
    background: #fff;
    transition: background-color .15s ease;
}

.receivable-table tbody td {
    transition: background-color .15s ease, box-shadow .15s ease;
}

.receivable-table tbody tr:last-child td {
    border-bottom: 0;
}

.receivable-table tbody tr:hover {
    background: #eef8fb;
}

.receivable-table tbody tr:hover td {
    background: #eef8fb;
}

.receivable-table tbody tr:hover td:first-child {
    box-shadow: inset 4px 0 0 rgba(23, 101, 118, .38);
}

.receivable-table tbody tr.is-selected-row {
    background: #eaf8fb;
}

.receivable-table tbody tr.is-selected-row td:first-child {
    box-shadow: inset 4px 0 0 var(--accent);
}

.receivable-table .check-col,
.receivable-table .check-cell {
    width: 42px;
    text-align: center;
}

.receivable-table .check-col input,
.receivable-table .check-cell input {
    cursor: pointer;
}

.receivable-table .id-col {
    width: 68px;
}

.receivable-table .client-col {
    width: 230px;
}

.receivable-table .document-col {
    width: 210px;
}

.receivable-table th:nth-child(5),
.receivable-table td:nth-child(5) {
    width: 66px;
}

.receivable-table th:nth-child(6),
.receivable-table td:nth-child(6),
.receivable-table th:nth-child(7),
.receivable-table td:nth-child(7) {
    width: 112px;
}

.receivable-table th:nth-child(8),
.receivable-table td:nth-child(8),
.receivable-table th:nth-child(9),
.receivable-table td:nth-child(9) {
    width: 104px;
}

.receivable-table th:nth-child(10),
.receivable-table td:nth-child(10) {
    width: 92px;
    text-align: center;
}

.receivable-table th:nth-child(11),
.receivable-table td:nth-child(11) {
    width: 126px;
}

.receivable-table th:last-child,
.receivable-table td:last-child {
    width: 154px;
}

.document-cell {
    overflow: hidden;
    color: var(--text);
    font-weight: 500;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.money-received {
    color: #00845f;
}

.account-balance-hint {
    position: relative;
    display: inline-flex;
    align-items: center;
    cursor: help;
    outline: none;
}

.account-balance-popover {
    position: absolute;
    left: 50%;
    bottom: calc(100% + 8px);
    z-index: 20;
    display: none;
    width: 178px;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    box-shadow: 0 16px 32px rgba(15, 40, 60, .18);
    text-align: left;
    transform: translateX(-50%);
}

.account-balance-hint:hover .account-balance-popover,
.account-balance-hint:focus .account-balance-popover,
.account-balance-hint:focus-within .account-balance-popover {
    display: grid;
    gap: 6px;
}

.account-balance-popover::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 100%;
    width: 10px;
    height: 10px;
    border-right: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    background: #fff;
    transform: translate(-50%, -5px) rotate(45deg);
}

.account-balance-popover strong {
    color: var(--text);
    font-size: .82rem;
}

.account-balance-popover span {
    color: var(--text-muted);
    font-size: .76rem;
    font-weight: 700;
}

.account-balance-popover b {
    color: var(--primary);
    font-size: .94rem;
    font-weight: 900;
}

.payables-table {
    min-width: 1220px;
}

.payables-table .payable-check-col {
    width: 42px;
}

.payables-table .payable-id-col {
    width: 64px;
}

.payables-table .payable-supplier-col {
    width: 210px;
}

.payables-table .payable-document-col {
    width: 205px;
}

.payables-table .payable-installment-col {
    width: 70px;
}

.payables-table .payable-money-col {
    width: 105px;
}

.payables-table .payable-date-col,
.payables-table .payable-frequency-col {
    width: 104px;
}

.payables-table .payable-attachments-col {
    width: 92px;
}

.payables-table .payable-status-col {
    width: 132px;
}

.payables-table .payable-actions-col {
    width: 135px;
}

.payables-table th:nth-child(9),
.payables-table td:nth-child(9) {
    text-align: center;
}

.payables-table th:last-child,
.payables-table td:last-child,
.payable-actions-cell {
    text-align: center;
}

.payables-table .receivable-status-pill {
    max-width: 118px;
    white-space: nowrap;
}

.account-info-stack {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    white-space: nowrap;
}

.account-info-help {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    cursor: help;
    outline: none;
    white-space: nowrap;
    font-size: .7rem;
}

.account-info-help::after {
    content: "?";
    display: inline-flex;
    width: 14px;
    height: 14px;
    align-items: center;
    justify-content: center;
    border: 1px solid #a8d9e5;
    border-radius: 999px;
    background: #e8faff;
    color: var(--primary);
    font-size: .62rem;
    font-weight: 900;
    line-height: 1;
}

.account-info-help-popover {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    z-index: 25;
    display: none;
    width: min(340px, calc(100vw - 36px));
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    box-shadow: 0 16px 32px rgba(15, 40, 60, .18);
    text-align: left;
    text-transform: none;
}

.account-info-cell-popover {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    z-index: 20;
    display: none;
    width: min(335px, calc(100vw - 36px));
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    box-shadow: 0 16px 32px rgba(15, 40, 60, .18);
    text-align: left;
}

.account-info-cell-popover.is-open-up {
    top: auto;
    bottom: calc(100% + 8px);
}

.account-info-help:hover .account-info-help-popover,
.account-info-help:focus .account-info-help-popover,
.account-info-help:focus-within .account-info-help-popover {
    display: grid;
    gap: 7px;
}

.account-info-cell:hover .account-info-cell-popover,
.account-info-cell:focus .account-info-cell-popover,
.account-info-cell:focus-within .account-info-cell-popover {
    display: grid;
    gap: 7px;
}

.account-info-cell.is-dismissed .account-info-cell-popover {
    display: none;
}

.account-info-help-popover strong,
.account-info-cell-popover strong {
    color: var(--text);
    font-size: .82rem;
}

.account-info-help-popover span,
.account-info-cell-popover span {
    display: flex;
    gap: 6px;
    align-items: center;
    color: var(--text-muted);
    font-size: .76rem;
    font-weight: 700;
    line-height: 1.3;
}

.account-info-help-popover span {
    white-space: nowrap;
}

.account-info-help-popover b {
    min-width: 17px;
    color: var(--text);
    text-align: center;
}

.account-info-cell-popover span {
    display: block;
}

.account-info-cell-popover .account-info-popover-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    color: var(--text);
}

.account-info-popover-close {
    display: inline-flex;
    width: 26px;
    height: 26px;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    border: 1px solid #9fd6e3;
    border-radius: 7px;
    background: #f4fbfd;
    color: var(--primary);
    cursor: pointer;
    font-size: .72rem;
    font-weight: 900;
    line-height: 1;
}

.account-info-popover-close:hover,
.account-info-popover-close:focus {
    border-color: var(--primary);
    background: #e6f8fc;
    outline: none;
}

.account-info-cell-popover .account-info-delivery-line {
    padding-top: 2px;
    white-space: normal;
}

.account-info-cell-popover .account-info-delivery-line.email {
    color: #007c89;
}

.account-info-cell-popover .account-info-delivery-line.sms {
    color: #8a3ffc;
}

.account-attachment-count {
    display: inline-flex;
    min-width: 14px;
    justify-content: center;
    color: var(--text);
    font-size: .78rem;
    font-weight: 800;
}

.account-reminder-mini {
    display: inline-flex;
    width: 17px;
    height: 17px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    border: 1px solid transparent;
    font-size: .62rem;
    font-weight: 900;
    line-height: 1;
}

.account-reminder-mini.active {
    border-color: #8ee6a8;
    background: #dcfce7;
    color: #166534;
}

.account-reminder-mini.paused {
    border-color: #fde68a;
    background: #fef3c7;
    color: #92400e;
}

.account-reminder-mini.invalid {
    border-color: #fecdd3;
    background: #ffe4e6;
    color: #be123c;
}

.account-reminder-mini.off {
    border-color: #d8e4ec;
    background: #f3f7fa;
    color: #7d91a0;
}

.receivable-status-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 30px;
    padding: 6px 11px;
    border-radius: 8px;
    font-size: .74rem;
    font-weight: 900;
    white-space: nowrap;
}

.receivable-status-pill.upcoming {
    background: #dcfce7;
    color: #166534;
}

.receivable-status-pill.today {
    background: #dbeafe;
    color: #1d4ed8;
}

.receivable-status-pill.negotiation {
    gap: 6px;
    background: #ffedd5;
    color: #b45309;
}

.receivable-status-pill.negotiation.is-negotiation-expired {
    box-shadow: inset 0 0 0 1px #e11d48, 0 0 0 2px #fff1f2;
}

.negotiation-expired-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    border-radius: 999px;
    background: #e11d48;
    color: #fff;
    font-size: .66rem;
    font-style: normal;
    line-height: 1;
}

.receivable-status-pill.late {
    border: 1px solid #fecdd3;
    background: #ffe4e6;
    color: #e11d48;
}

.receivable-status-pill.received,
.receivable-status-pill.paid {
    background: #ede9fe;
    color: #5b21b6;
}

.receivable-row-actions {
    display: flex;
    align-items: center;
    gap: 7px;
    white-space: nowrap;
}

.receivable-row-actions .button {
    min-width: 78px;
    justify-content: center;
}

.receivable-action-menu {
    position: relative;
}

@media (min-width: 761px) {
    .receivable-action-menu[data-floating-action-menu] > div {
        position: fixed;
    }
}

.receivable-action-menu > summary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    min-height: 38px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--primary);
    font-weight: 900;
    cursor: pointer;
    list-style: none;
}

.receivable-action-menu > summary::-webkit-details-marker {
    display: none;
}

.receivable-action-menu > div {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    z-index: 15;
    display: grid;
    gap: 2px;
    min-width: 190px;
    padding: 8px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 16px 32px rgba(15, 40, 60, .16);
}

.receivable-action-menu header {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    align-items: center;
    padding: 4px 4px 8px;
    border-bottom: 1px solid #e2edf3;
}

.receivable-action-menu header strong {
    color: var(--text);
    font-size: .86rem;
}

.receivable-action-menu header button {
    display: inline-flex;
    width: 30px;
    height: 30px;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #f8fbfd;
    color: var(--text);
    font-weight: 900;
    cursor: pointer;
}

.receivable-action-menu header button:hover,
.receivable-action-menu header button:focus {
    border-color: #94c7d8;
    background: #eef8fb;
}

.receivable-action-menu a,
.receivable-action-menu button {
    padding: 9px 10px;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: var(--text);
    font-size: .84rem;
    font-weight: 800;
    font-family: inherit;
    text-align: left;
    text-decoration: none;
    cursor: pointer;
}

.receivable-action-menu form {
    margin: 0;
}

.receivable-action-menu form button {
    display: block;
    width: 100%;
}

.receivable-action-menu a:hover,
.receivable-action-menu a:focus,
.receivable-action-menu button:hover,
.receivable-action-menu button:focus {
    background: #eef8fb;
}

.receivable-action-menu a.danger,
.receivable-action-menu button.danger {
    color: #dc2626;
}

.receivable-footer {
    align-items: center;
}

.receivable-footer .requests-footer-controls {
    margin-left: auto;
}

.receivable-totals {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 18px;
    align-items: center;
    color: var(--text-muted);
}

.receivable-totals strong {
    color: var(--text);
}

.receivable-form-shell {
    background: #eef5fb;
}

.receivable-form-page {
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-width: 1480px;
    margin: 0 auto;
}

.receivable-duplicate-page {
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-width: 1480px;
    margin: 0 auto;
}

.receivable-duplicate-hero {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.receivable-duplicate-hero nav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    color: #55708e;
    font-size: 0.82rem;
    font-weight: 700;
}

.receivable-duplicate-hero nav a {
    color: #007c99;
    text-decoration: none;
}

.receivable-duplicate-hero nav span::before,
.receivable-duplicate-hero nav strong::before {
    content: ">";
    margin-right: 8px;
    color: #9bb0c7;
}

.receivable-duplicate-hero > div {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: flex-start;
}

.receivable-duplicate-hero h1 {
    margin: 0;
    color: #08233a;
    font-size: clamp(1.65rem, 2.4vw, 2.25rem);
}

.receivable-duplicate-hero p {
    margin: 8px 0 0;
    color: #36526f;
}

.receivable-duplicate-banner {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 16px;
    align-items: center;
    padding: 16px;
    border: 1px solid #9be7c3;
    border-radius: 8px;
    background: #ecfdf5;
}

.receivable-duplicate-banner > span {
    display: grid;
    width: 46px;
    height: 46px;
    place-items: center;
    border: 1px solid #7ddfb1;
    border-radius: 50%;
    background: #d1fae5;
    color: #009875;
    font-size: 1.4rem;
    font-weight: 900;
}

.receivable-duplicate-banner h2 {
    margin: 0;
    color: #08233a;
    font-size: 1.08rem;
}

.receivable-duplicate-banner p {
    margin: 6px 0 0;
    color: #36526f;
}

.receivable-duplicate-banner strong,
.receivable-duplicate-card header em {
    padding: 7px 12px;
    border: 1px solid #9be7c3;
    border-radius: 999px;
    background: #d1fae5;
    color: #007c72;
    font-size: 0.78rem;
    font-weight: 900;
    white-space: nowrap;
}

.receivable-duplicate-metrics,
.receivable-duplicate-grid {
    display: grid;
    gap: 14px;
}

.receivable-duplicate-metrics {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.receivable-duplicate-metrics article {
    min-height: 96px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #ffffff;
    box-shadow: var(--shadow-sm);
}

.receivable-duplicate-metrics span {
    display: block;
    color: #58708c;
    font-size: 0.78rem;
    font-weight: 900;
    text-transform: uppercase;
}

.receivable-duplicate-metrics strong {
    display: block;
    margin-top: 8px;
    color: #08233a;
    font-size: 1.35rem;
}

.receivable-duplicate-metrics small {
    display: block;
    margin-top: 6px;
    color: #36526f;
}

.receivable-duplicate-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.receivable-duplicate-grid-single {
    grid-template-columns: 1fr;
}

.receivable-duplicate-card header {
    align-items: flex-start;
}

.receivable-duplicate-note,
.receivable-duplicate-rule {
    margin-top: 14px;
    padding: 14px;
    border-radius: 8px;
}

.receivable-duplicate-note {
    border: 1px solid #fed7aa;
    background: #fff7ed;
}

.receivable-duplicate-note strong {
    color: #d97706;
}

.receivable-duplicate-note p,
.receivable-duplicate-note small,
.receivable-duplicate-rule p {
    display: block;
    margin: 6px 0 0;
    color: #36526f;
}

.receivable-duplicate-note small {
    color: #008f6d;
    font-weight: 800;
}

.receivable-duplicate-rule {
    border: 1px solid #a7f3d0;
    background: #ecfdf5;
}

.receivable-duplicate-rule strong {
    color: #007c72;
}

.receivable-duplicate-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.receivable-edit-hero {
    padding-top: 0;
}

.receivable-title-with-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.receivable-title-with-badges .receivable-status-pill,
.receivable-summary-row .receivable-status-pill {
    min-height: 28px;
    font-size: .72rem;
}

.receivable-fixed-badge {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 5px 11px;
    border: 1px solid #a5f3fc;
    border-radius: 999px;
    background: #cffafe;
    color: #0e7490;
    font-size: .72rem;
    font-weight: 900;
    white-space: nowrap;
}

.receivable-summary-row {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.receivable-duplicate-alert {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: center;
    margin-bottom: 16px;
    padding: 18px;
    border: 1px solid #8bd3e6;
    border-radius: 8px;
    background: linear-gradient(135deg, #f0fbff 0%, #f8fdff 100%);
    box-shadow: 0 14px 28px rgba(12, 104, 128, 0.08);
}

.receivable-duplicate-alert span {
    display: block;
    margin-bottom: 6px;
    color: #0d6f87;
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.receivable-duplicate-alert h2 {
    margin: 0;
    color: #08233a;
    font-size: 1.08rem;
}

.receivable-duplicate-alert p {
    margin: 8px 0 0;
    color: #36526f;
}

.receivable-duplicate-alert strong {
    flex: 0 0 auto;
    padding: 12px 16px;
    border-radius: 8px;
    background: #ffffff;
    color: #007c99;
    font-size: 1.15rem;
    box-shadow: inset 0 0 0 1px #c7eaf3;
}

.receivable-summary-row article,
.receivable-payment-panel,
.receivable-form-card {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.receivable-summary-row article {
    min-height: 98px;
    padding: 18px;
}

.receivable-summary-row article.is-open {
    border-color: #fed7aa;
    background: #fffaf0;
}

.receivable-summary-row span,
.receivable-form-card header span {
    display: block;
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 900;
}

.receivable-summary-row strong {
    display: block;
    margin: 8px 0 6px;
    color: var(--text);
    font-size: 1.45rem;
    line-height: 1;
}

.receivable-summary-row small {
    display: block;
    overflow: hidden;
    color: var(--text-muted);
    text-overflow: ellipsis;
    white-space: nowrap;
}

.receivable-summary-row em {
    margin-top: 10px;
    font-style: normal;
}

.receivable-payment-panel {
    display: grid;
    gap: 0;
    padding: 0;
    overflow: hidden;
    border-color: #a9d6e5;
    background: #f8fcff;
    box-shadow: 0 12px 30px rgba(15, 40, 60, .08);
}

.receivable-payment-panel summary {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: center;
    padding: 18px;
    background: linear-gradient(180deg, #f9fdff 0%, #eef8fb 100%);
    cursor: pointer;
    list-style: none;
}

.receivable-payment-panel summary::-webkit-details-marker {
    display: none;
}

.receivable-payment-panel summary span {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    padding: 6px 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--primary);
    font-weight: 900;
    white-space: nowrap;
}

.receivable-payment-panel[open] summary {
    border-bottom: 1px solid var(--border);
}

.receivable-payment-panel[open] summary span {
    font-size: 0;
}

.receivable-payment-panel[open] summary span::before {
    content: "Recolher";
    font-size: .86rem;
}

.receivable-payment-body {
    display: grid;
    gap: 14px;
    padding: 18px;
    background: #fff;
}

.receivable-payment-intro {
    display: none;
}

.receivable-payment-panel h2,
.receivable-form-card h2 {
    margin: 0;
    color: var(--text);
    font-size: 1.08rem;
}

.receivable-payment-panel p,
.receivable-inline-note {
    margin: 5px 0 0;
    color: var(--text-muted);
}

.receivable-payment-feedback {
    margin: 0;
    border: 1px solid #bbf7d0;
    border-radius: 8px;
    background: #f0fdf4;
    color: #047857;
    font-weight: 800;
    padding: 10px 12px;
}

.receivable-payment-feedback.is-error {
    border-color: #fecaca;
    background: #fff1f2;
    color: #b91c1c;
}

.receivable-payment-feedback[hidden] {
    display: none;
}

.receivable-document-feedback {
    margin: 0;
    border: 1px solid #fed7aa;
    border-radius: 8px;
    background: #fff7ed;
    color: #c2410c;
    font-weight: 800;
    padding: 10px 12px;
}

.receivable-document-feedback[hidden] {
    display: none;
}

.premium-toast-stack {
    position: fixed;
    top: 86px;
    right: 24px;
    z-index: 80;
    display: grid;
    gap: 10px;
    width: min(420px, calc(100vw - 32px));
    pointer-events: none;
}

.premium-toast {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    border: 1px solid #b7dce8;
    border-left: 4px solid var(--primary);
    border-radius: 8px;
    background: rgba(255, 255, 255, .98);
    box-shadow: 0 18px 44px rgba(11, 42, 61, .18);
    color: var(--text);
    padding: 13px 14px;
    pointer-events: auto;
}

.premium-toast > span {
    display: inline-grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 8px;
    background: color-mix(in srgb, var(--primary) 12%, #fff);
    color: var(--primary);
    font-size: .74rem;
    font-weight: 900;
}

.premium-toast > span::before {
    content: "OK";
}

.premium-toast strong,
.premium-toast small {
    display: block;
}

.premium-toast strong {
    font-size: .92rem;
}

.premium-toast small {
    margin-top: 3px;
    color: var(--text-muted);
    font-size: .78rem;
}

.premium-toast button {
    display: inline-grid;
    place-items: center;
    width: 30px;
    height: 30px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text-muted);
    font-weight: 900;
    cursor: pointer;
}

.premium-toast.success {
    border-left-color: #059669;
}

.premium-toast.success > span {
    background: #dcfce7;
    color: #047857;
}

.premium-toast.error {
    border-left-color: #dc2626;
}

.premium-toast.error > span {
    background: #fee2e2;
    color: #b91c1c;
}

.premium-toast.error > span::before {
    content: "!";
}

.premium-confirm-backdrop {
    position: fixed;
    inset: 0;
    z-index: 90;
    display: grid;
    place-items: start center;
    background: rgba(10, 31, 45, .52);
    padding: 72px 16px 16px;
}

.premium-confirm {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 14px;
    width: min(460px, 100%);
    border: 1px solid #b7dce8;
    border-top: 4px solid var(--primary);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 24px 70px rgba(7, 33, 49, .28);
    color: var(--text);
    padding: 18px;
}

.premium-confirm--medium {
    width: min(620px, 100%);
}

.premium-confirm > span {
    display: inline-grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 8px;
    background: #e8f7fb;
    color: var(--primary);
    font-weight: 900;
}

.premium-confirm > span::before {
    content: "?";
}

.premium-confirm h2,
.premium-confirm p,
.premium-confirm ul {
    margin: 0;
}

.premium-confirm h2 {
    font-size: 1.02rem;
}

.premium-confirm p {
    margin-top: 5px;
    color: var(--text-muted);
}

.premium-confirm ul {
    display: grid;
    gap: 8px;
    margin-top: 12px;
    color: #38556a;
    line-height: 1.45;
    padding-left: 18px;
}

.premium-confirm li::marker {
    color: var(--primary);
}

.premium-confirm footer {
    grid-column: 1 / -1;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 4px;
}

.receivable-payment-grid {
    display: grid;
    grid-template-columns: 150px repeat(3, minmax(100px, .72fr)) minmax(220px, 1.25fr) minmax(110px, .72fr) auto;
    gap: 12px;
    align-items: end;
}

.receivable-payment-description-field {
    min-width: 0;
}

.receivable-description-control,
.receivable-copy-field {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    align-items: center;
}

.receivable-description-control .button,
.receivable-copy-field .button {
    min-height: 42px;
}

.receivable-payment-history {
    margin-top: 10px;
    border: 1px solid #d8e8ef;
    border-radius: 8px;
    background: #f7fbfd;
}

.receivable-payment-history div,
.receivable-payment-history p {
    margin: 0;
    padding: 12px 14px;
}

.receivable-payment-history div {
    display: grid;
    grid-template-columns: 110px 110px 110px 110px 110px minmax(280px, 1fr) auto;
    gap: 12px;
    align-items: center;
}

.receivable-payment-history-head {
    border-bottom: 1px solid #d8e8ef;
    background: #eef6fa;
}

.receivable-payment-history-head strong {
    color: var(--text-muted);
    font-size: .74rem;
    text-transform: uppercase;
}

.receivable-payment-history span {
    color: #00845f;
    font-weight: 900;
}

.receivable-payment-history small {
    color: var(--text-muted);
    min-width: 0;
    overflow-wrap: anywhere;
}

.receivable-payment-history button {
    display: inline-flex;
    width: 34px;
    height: 34px;
    align-items: center;
    justify-content: center;
    border: 1px solid #fecaca;
    border-radius: 8px;
    background: #fff1f2;
    color: #dc2626;
    font-weight: 900;
    cursor: pointer;
}

.receivable-form-grid,
.receivable-secondary-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 16px;
    align-items: start;
}

.receivable-form-grid {
    align-items: stretch;
}

.receivable-form-grid > *,
.receivable-secondary-grid > * {
    min-width: 0;
}

.receivable-form-card {
    display: grid;
    gap: 16px;
    padding: 18px;
    min-width: 0;
}

.receivable-form-card header {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: flex-start;
    min-width: 0;
}

.receivable-form-card header > div {
    min-width: 0;
}

.receivable-form-card header h2,
.receivable-form-card header p {
    overflow-wrap: anywhere;
}

.receivable-form-card header em {
    display: inline-flex;
    min-height: 28px;
    align-items: center;
    padding: 4px 10px;
    border: 1px solid #cfe5ef;
    border-radius: 999px;
    background: #f5fbfd;
    color: var(--text-muted);
    font-size: .76rem;
    font-style: normal;
    font-weight: 900;
    white-space: nowrap;
}

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

.receivable-fields-grid.compact {
    grid-template-columns: repeat(2, minmax(0, 220px));
}

.receivable-fields-grid .wide {
    grid-column: 1 / -1;
}

.receivable-file-label {
    min-width: 0;
}

.receivable-fields-grid[hidden],
.receivable-inline-note[hidden] {
    display: none;
}

.receivable-payment-grid label,
.receivable-fields-grid label,
.receivable-form-card > label,
.receivable-textarea-label {
    display: flex;
    flex-direction: column;
    gap: 7px;
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 800;
}

.receivable-payment-grid input,
.receivable-fields-grid input,
.receivable-fields-grid select,
.receivable-form-card > label input,
.receivable-form-card textarea,
.receivable-channel-select {
    width: 100%;
    min-height: 42px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    padding: 0 12px;
    font: inherit;
    font-weight: 700;
}

.receivable-payment-grid input[readonly],
.receivable-fields-grid input[readonly],
.receivable-readonly-input {
    border-color: #cbdbe5;
    background: #eef4f8;
    color: #486172;
    cursor: default;
}

.receivable-fields-grid .receivable-due-input {
    border-color: #7dd3fc;
    background: #e8f8ff;
}

.receivable-fields-grid .receivable-due-label {
    color: #0369a1;
}

.receivable-fields-grid .receivable-value-input {
    border-color: #fca5a5;
    background: #fff1f2;
}

.receivable-fields-grid .receivable-value-label {
    color: #dc2626;
}

.receivable-fields-grid .receivable-negotiation-input {
    border-color: #fed7aa;
    background: #fff7ed;
}

.receivable-fields-grid .receivable-negotiation-label {
    color: #c2410c;
}

.receivable-fields-grid .receivable-negotiation-label.is-expired {
    color: #be123c;
}

.receivable-fields-grid .receivable-negotiation-label.is-expired .receivable-negotiation-input {
    border-color: #fb7185;
    background: #fff1f2;
    box-shadow: 0 0 0 2px rgba(225, 29, 72, .08);
}

.negotiation-expired-hint {
    display: block;
    margin-top: 5px;
    color: #be123c;
    font-size: .72rem;
    font-weight: 800;
    line-height: 1.35;
}

.receivable-fields-grid .receivable-client-highlight {
    border-color: #86efac;
    background: #f0fdf4;
}

.rental-association-picker .rental-invoice-contract-highlight {
    border-color: #86efac;
    background: #f0fdf4;
}

.receivable-party-summary {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px 18px;
    align-items: center;
    min-height: 44px;
    padding: 11px 14px;
    border: 1px solid #86efac;
    border-radius: 8px;
    background: #f0fdf4;
    color: #047857;
}

.receivable-party-summary strong,
.receivable-party-summary span {
    min-width: 0;
    overflow-wrap: anywhere;
}

.receivable-party-summary strong {
    font-size: .82rem;
    font-weight: 900;
}

.receivable-party-summary span {
    text-align: right;
    font-size: .8rem;
    font-weight: 800;
}

.receivable-party-summary.is-pending {
    border-color: #bae6fd;
    background: #f0f9ff;
    color: #0369a1;
}

.receivable-client-picker {
    position: relative;
}

.receivable-client-results {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    z-index: 30;
    display: grid;
    max-height: 260px;
    overflow-y: auto;
    border: 1px solid #b7d7e5;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 14px 32px rgba(15, 40, 60, .16);
}

.receivable-client-results[hidden] {
    display: none;
}

.receivable-client-results button {
    display: grid;
    gap: 2px;
    width: 100%;
    border: 0;
    border-bottom: 1px solid #e4f0f5;
    background: #fff;
    color: var(--text);
    cursor: pointer;
    padding: 10px 12px;
    text-align: left;
    font: inherit;
}

.receivable-client-results button[hidden] {
    display: none;
}

.receivable-client-results button:last-child {
    border-bottom: 0;
}

.receivable-client-results button:hover,
.receivable-client-results button.is-active {
    background: #e8f7fb;
}

.receivable-client-results strong {
    font-weight: 900;
}

.receivable-client-results span {
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 700;
}

.receivable-file-input {
    display: flex;
    align-items: center;
    padding: 6px 10px !important;
    color: var(--text-muted) !important;
    font-weight: 800 !important;
}

.receivable-file-input::file-selector-button {
    min-height: 30px;
    margin-right: 12px;
    border: 1px solid #9fd1df;
    border-radius: 8px;
    background: #f4fbfd;
    color: var(--primary);
    cursor: pointer;
    font: inherit;
    font-weight: 900;
    padding: 0 13px;
}

.receivable-file-input:hover::file-selector-button {
    border-color: var(--primary);
    background: #e8f7fb;
}

.receivable-form-card textarea {
    min-height: 150px;
    padding-top: 12px;
    resize: vertical;
}

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

.receivable-summary-grid > div {
    display: grid;
    gap: 4px;
    min-width: 0;
    border: 1px solid #cfe5ef;
    border-radius: 8px;
    background: #f5fbfd;
    padding: 12px;
}

.receivable-summary-grid span,
.receivable-payment-item span,
.receivable-payment-item small {
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 800;
}

.receivable-summary-grid strong {
    color: var(--text);
    font-size: 1.2rem;
    font-weight: 900;
}

.receivable-payments-list {
    display: grid;
    gap: 10px;
}

.receivable-payment-item {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    min-width: 0;
    border: 1px solid #d8e8ef;
    border-radius: 8px;
    background: #fff;
    padding: 12px;
}

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

.receivable-payment-item strong {
    color: #00856f;
    font-size: 1.05rem;
    font-weight: 900;
}

.receivable-payment-grid input:focus,
.receivable-fields-grid input:focus,
.receivable-fields-grid select:focus,
.receivable-form-card textarea:focus,
.receivable-form-card > label input:focus,
.receivable-channel-select:focus {
    outline: none;
    border-color: #1b93aa;
    box-shadow: 0 0 0 3px rgba(27, 147, 170, .12);
}

.receivable-switch {
    display: inline-flex;
    flex: 0 0 auto;
    gap: 8px;
    align-items: center;
    color: var(--text);
    cursor: pointer;
    font-weight: 900;
    white-space: nowrap;
}

.receivable-switch input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.receivable-switch i {
    position: relative;
    display: inline-flex;
    width: 54px;
    height: 30px;
    border-radius: 999px;
    background: #94a3b8;
    cursor: pointer;
    box-shadow: 0 8px 18px rgba(15, 40, 60, .18);
    transition: background-color .16s ease;
}

.receivable-switch i::after {
    content: "";
    position: absolute;
    top: 4px;
    left: 4px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 5px rgba(15, 40, 60, .24);
    transition: transform .16s ease;
}

.receivable-switch input:checked + i {
    background: #8ee6df;
}

.receivable-switch input:checked + i::after {
    transform: translateX(24px);
}

.receivable-inline-note {
    min-width: 0;
    max-width: 100%;
    overflow-wrap: anywhere;
    padding: 12px;
    border: 1px solid #bbf7d0;
    border-radius: 8px;
    background: #f0fdf4;
    color: #166534;
    font-weight: 800;
    line-height: 1.45;
}

.receivable-inline-note strong {
    display: inline;
    margin-right: 4px;
}

.receivable-inline-note strong::before {
    content: "";
    display: inline-block;
    width: 8px;
    height: 8px;
    margin-right: 8px;
    border-radius: 50%;
    background: #10b981;
}

.receivable-recurrence-card header h2 {
    display: flex;
    gap: 8px;
    align-items: center;
}

.receivable-recurrence-card header h2 b {
    display: inline-flex;
    width: 24px;
    height: 24px;
    align-items: center;
    justify-content: center;
    border: 1px solid #67e8f9;
    border-radius: 50%;
    background: #ecfeff;
    color: #0891b2;
    font-size: .8rem;
}

.receivable-recurrence-card header p {
    margin: 6px 0 0;
    color: var(--text-muted);
    line-height: 1.35;
}

.receivable-installments-panel {
    display: grid;
    gap: 12px;
    padding: 16px;
    border: 1px solid #d8e8ef;
    border-radius: 8px;
    background: #fff;
}

.receivable-installments-panel[hidden] {
    display: none;
}

.receivable-installments-panel label {
    display: grid;
    gap: 8px;
    color: var(--text);
    font-weight: 900;
}

.receivable-installments-panel input {
    width: 100%;
    min-height: 42px;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 0 12px;
    font: inherit;
    font-weight: 700;
}

.receivable-installments-panel p {
    margin: 0;
    color: var(--text-muted);
    line-height: 1.45;
}

.receivable-reminder-card {
    gap: 0;
}

.receivable-reminder-card summary {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: flex-start;
    margin: -18px;
    padding: 18px;
    cursor: pointer;
    list-style: none;
}

.receivable-reminder-card summary::-webkit-details-marker {
    display: none;
}

.receivable-reminder-card summary p {
    margin: 4px 0 0;
    color: var(--text-muted);
    font-size: .84rem;
}

.receivable-reminder-card summary em {
    display: inline-flex;
    min-height: 34px;
    align-items: center;
    padding: 7px 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--primary);
    font-size: .86rem;
    font-style: normal;
    font-weight: 900;
    white-space: nowrap;
}

.receivable-reminder-card[open] {
    gap: 16px;
}

.receivable-reminder-card[open] summary {
    margin-bottom: 0;
    border-bottom: 1px solid var(--border);
}

.receivable-reminder-card[open] summary em {
    font-size: 0;
}

.receivable-reminder-card[open] summary em::before {
    content: "Recolher";
    font-size: .86rem;
}

.receivable-reminder-controls {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.receivable-reminder-controls label {
    display: grid;
    align-content: start;
    gap: 7px;
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 800;
}

.receivable-reminder-controls select,
.receivable-channel-select {
    width: 100%;
    min-height: 44px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    padding: 0 12px;
    font: inherit;
    font-weight: 700;
}

.receivable-reminder-controls select:disabled,
.receivable-channel-select:disabled {
    border-color: #d6e2ea;
    background: #eef4f8;
    color: #647887;
    cursor: default;
}

.receivable-reminder-list {
    display: grid;
    gap: 10px;
    margin-top: 10px;
}

.receivable-reminder-list label {
    display: grid;
    grid-template-columns: 34px minmax(120px, .8fr) minmax(160px, 1fr) auto auto auto;
    gap: 10px;
    align-items: center;
    padding: 10px 12px;
    border: 1px solid #d8e8ef;
    border-radius: 8px;
    background: #f7fbfd;
    color: var(--text);
    font-weight: 900;
    min-width: 0;
}

.receivable-reminder-list strong,
.receivable-reminder-list small {
    min-width: 0;
    overflow-wrap: anywhere;
}

.receivable-reminder-list b[hidden] {
    display: none;
}

.receivable-reminder-card[data-channel="none"] .receivable-reminder-list label {
    opacity: .62;
}

.rental-invoice-reminder-card {
    margin-top: 14px;
}

.rental-invoice-reminder-channel-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin-top: 12px;
}

.rental-invoice-reminder-channel-grid > label {
    display: grid;
    grid-template-columns: 24px minmax(0, 1fr);
    gap: 10px;
    align-items: center;
    min-width: 0;
    padding: 12px 13px;
    border: 1px solid #d8e8ef;
    border-radius: 9px;
    background: #f7fbfd;
    cursor: pointer;
}

.rental-invoice-reminder-channel-grid > label:has(input:checked) {
    border-color: #63c5af;
    background: #effcf6;
    box-shadow: inset 0 0 0 1px rgba(16, 185, 129, .08);
}

.rental-invoice-reminder-channel-grid > label.is-whatsapp:has(input:checked) {
    border-color: #25a96f;
    background: #ecfdf5;
}

.rental-invoice-reminder-channel-grid input {
    width: 22px;
    height: 22px;
    margin: 0;
    accent-color: #10b981;
}

.rental-invoice-reminder-channel-grid span {
    display: grid;
    gap: 3px;
    min-width: 0;
}

.rental-invoice-reminder-channel-grid strong {
    color: var(--text);
    font-size: .9rem;
}

.rental-invoice-reminder-channel-grid small {
    color: var(--text-muted);
    font-size: .74rem;
    font-weight: 700;
    line-height: 1.35;
}

.financial-reminder-premium {
    grid-column: 1 / -1;
    min-width: 0;
}

.financial-reminder-channel-grid > label.is-pending {
    border-color: #ead7a2;
    background: #fffbeb;
    cursor: not-allowed;
}

.financial-reminder-channel-grid > label.is-pending input {
    opacity: .48;
}

.financial-reminder-channel-grid > label.is-pending strong,
.financial-reminder-channel-grid > label.is-pending small {
    color: #8a6510;
}

.financial-reminder-contact-section {
    margin-top: 14px;
}

.financial-reminder-contact-section[hidden] {
    display: none;
}

.financial-reminder-contact-section h4 {
    margin: 0;
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 900;
}

.rental-invoice-reminder-controls {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr);
    gap: 14px;
    align-items: stretch;
}

.rental-invoice-reminder-controls > label {
    display: grid;
    gap: 7px;
    align-content: start;
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 800;
}

.rental-invoice-reminder-controls select {
    width: 100%;
    min-height: 44px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    padding: 0 12px;
    font: inherit;
    font-weight: 700;
}

.rental-invoice-reminder-recipient {
    display: grid;
    grid-template-columns: minmax(130px, .35fr) minmax(180px, .45fr) minmax(260px, 1fr);
    gap: 10px;
    align-items: center;
    padding: 11px 13px;
    border: 1px solid #d8e8ef;
    border-radius: 8px;
    background: #f7fbfd;
}

.rental-invoice-reminder-recipient span,
.rental-invoice-reminder-recipient small {
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 700;
}

.rental-invoice-reminder-recipient strong {
    color: var(--text);
    font-size: .9rem;
}

.rental-invoice-reminder-contact-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin-top: 12px;
}

.rental-invoice-reminder-contact-grid article {
    display: grid;
    gap: 4px;
    min-width: 0;
    padding: 11px 13px;
    border: 1px solid #bdebd8;
    border-radius: 8px;
    background: #effcf6;
}

.rental-invoice-reminder-contact-grid span {
    color: #547080;
    font-size: .75rem;
    font-weight: 800;
}

.rental-invoice-reminder-contact-grid strong {
    overflow-wrap: anywhere;
    color: #047857;
    font-size: .86rem;
}

.rental-invoice-reminder-contact-grid article.is-unavailable {
    border-color: #f5c4a0;
    background: #fff7ed;
}

.rental-invoice-reminder-contact-grid article.is-unavailable strong {
    color: #b45309;
}

.rental-invoice-reminder-contact-grid article.is-pending {
    border-color: #ead7a2;
    background: #fffbeb;
}

.rental-invoice-reminder-contact-grid article.is-pending strong,
.rental-invoice-reminder-contact-grid article.is-pending small {
    color: #8a6510;
}

.rental-invoice-reminder-contact-grid article.is-pending small {
    font-size: .7rem;
    font-weight: 800;
}

.receivable-reminder-list input {
    width: 22px;
    height: 22px;
    accent-color: #10b981;
}

.receivable-reminder-list strong {
    color: var(--text);
}

.receivable-reminder-list small {
    color: var(--text-muted);
    font-weight: 700;
}

.receivable-reminder-list b {
    padding: 4px 8px;
    border-radius: 999px;
    background: #dff8ee;
    color: #047857;
    font-size: .72rem;
}

.receivable-automation-stack {
    grid-template-columns: minmax(0, 1fr);
}

.receivable-automation-stack .receivable-recurrence-card {
    grid-template-columns: minmax(0, 1.4fr) minmax(380px, .85fr);
    grid-template-rows: auto minmax(64px, 1fr);
    align-items: start;
    min-height: 164px;
    box-sizing: border-box;
}

.receivable-automation-stack .receivable-recurrence-card > header {
    grid-column: 1 / -1;
    grid-row: 1;
    align-items: center;
    padding-bottom: 12px;
    border-bottom: 1px solid #e1ebf1;
}

.receivable-automation-stack .receivable-recurrence-card > .receivable-fields-grid {
    grid-column: 2;
    grid-row: 2;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-self: end;
}

.receivable-automation-stack .receivable-recurrence-card > .receivable-inline-note {
    grid-column: 1;
    grid-row: 2;
    margin: 0;
    align-self: end;
}

.receivable-automation-stack .receivable-recurrence-card > .receivable-installments-panel {
    grid-column: 1 / -1;
    grid-row: 2;
    grid-template-columns: minmax(0, 1.4fr) minmax(380px, .85fr);
    grid-template-areas:
        "guidance count"
        "action count";
    gap: 8px 18px;
    align-self: end;
    align-items: stretch;
    padding: 0;
    border: 0;
    background: transparent;
}

.receivable-automation-stack .receivable-installments-panel label {
    grid-area: count;
}

.receivable-automation-stack .receivable-installments-panel p {
    grid-area: guidance;
    align-self: end;
    margin: 0;
}

.receivable-automation-stack .receivable-installments-panel .button {
    grid-area: action;
    width: min(100%, 240px);
}

.receivable-notes-card textarea {
    min-height: 180px;
}

@media screen and (max-width: 900px) {
    .receivable-automation-stack .receivable-recurrence-card {
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: auto;
        min-height: 0;
    }

    .receivable-automation-stack .receivable-recurrence-card > header,
    .receivable-automation-stack .receivable-recurrence-card > .receivable-fields-grid,
    .receivable-automation-stack .receivable-recurrence-card > .receivable-installments-panel,
    .receivable-automation-stack .receivable-recurrence-card > .receivable-inline-note {
        grid-column: 1;
        grid-row: auto;
    }

    .receivable-automation-stack .receivable-recurrence-card > .receivable-installments-panel {
        grid-template-columns: minmax(0, 1fr);
        grid-template-areas:
            "count"
            "guidance"
            "action";
    }

    .receivable-automation-stack .receivable-installments-panel .button {
        width: 100%;
    }
}

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

.receivable-document-list div {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 6px 10px;
    align-items: center;
    padding: 13px 14px;
    border: 1px solid #c7e6f0;
    border-radius: 8px;
    background: #f0fbff;
}

.receivable-document-list strong {
    overflow: hidden;
    color: var(--text);
    text-overflow: ellipsis;
    white-space: nowrap;
}

.receivable-document-list small {
    color: var(--text-muted);
    grid-column: 1 / 2;
}

.receivable-document-list span {
    grid-column: 2 / 3;
    grid-row: 1 / 3;
    padding: 8px 10px;
    border: 1px solid #bbf7d0;
    border-radius: 8px;
    background: #ecfdf5;
    color: #047857;
    font-size: .72rem;
    font-weight: 900;
}

.receivable-document-list nav {
    display: flex;
    grid-column: 3 / 4;
    grid-row: 1 / 3;
    gap: 8px;
    align-items: center;
}

.receivable-document-list .button {
    min-height: 36px;
    white-space: nowrap;
}

.receivable-document-list .button.danger {
    border-color: #fecaca;
    background: #fff1f2;
    color: #dc2626;
}

.receivable-client-history {
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.receivable-client-history summary {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: center;
    padding: 18px;
    cursor: pointer;
    list-style: none;
}

.receivable-client-history summary::-webkit-details-marker {
    display: none;
}

.receivable-client-history summary strong {
    display: block;
    color: var(--text);
    font-size: 1.08rem;
}

.receivable-client-history summary small {
    display: block;
    margin-top: 5px;
    color: var(--text-muted);
}

.receivable-client-history summary em {
    display: inline-flex;
    min-height: 38px;
    align-items: center;
    padding: 8px 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--primary);
    font-style: normal;
    font-weight: 900;
    white-space: nowrap;
}

.receivable-client-history[open] summary {
    border-bottom: 1px solid var(--border);
}

.receivable-client-history[open] summary em {
    font-size: 0;
}

.receivable-client-history[open] summary em::before {
    content: "Ocultar historico";
    font-size: .9rem;
}

.receivable-client-history-body {
    display: grid;
    gap: 14px;
    padding: 18px;
}

.receivable-client-history-scroll {
    max-height: 320px;
    overflow: auto;
    border: 1px solid #d8e8ef;
    border-radius: 8px;
}

.receivable-client-history table {
    width: 100%;
    min-width: 980px;
    border-collapse: collapse;
}

.receivable-client-history th,
.receivable-client-history td {
    padding: 12px 14px;
    border-bottom: 1px solid #e2edf3;
    text-align: left;
    vertical-align: middle;
}

.receivable-client-history th {
    position: sticky;
    top: 0;
    z-index: 1;
    background: #eef6fa;
    color: var(--text-muted);
    font-size: .76rem;
    text-transform: uppercase;
}

.receivable-client-history tbody tr:last-child td {
    border-bottom: 0;
}

.receivable-history-indicator {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 30px;
    padding: 5px 10px;
    border: 1px solid #d8e8ef;
    border-radius: 999px;
    background: #f7fbfd;
    color: var(--text-muted);
    font-size: .82rem;
    font-weight: 900;
    white-space: nowrap;
}

.receivable-history-indicator b {
    display: inline-grid;
    place-items: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #e2e8f0;
    color: #334155;
    font-size: .8rem;
}

.receivable-history-indicator.up {
    border-color: #bbf7d0;
    background: #f0fdf4;
    color: #166534;
}

.receivable-history-indicator.up b {
    background: #dcfce7;
    color: #15803d;
}

.receivable-history-indicator.down {
    border-color: #fecaca;
    background: #fff1f2;
    color: #b91c1c;
}

.receivable-history-indicator.down b {
    background: #fee2e2;
    color: #dc2626;
}

.receivable-description-modal[hidden] {
    display: none;
}

.receivable-installments-modal[hidden] {
    display: none;
}

.receivable-description-modal {
    position: fixed;
    inset: 0;
    z-index: 90;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 22px;
    background: rgba(15, 34, 48, .58);
    backdrop-filter: blur(3px);
}

.receivable-installments-modal {
    position: fixed;
    inset: 0;
    z-index: 92;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 22px;
    background: rgba(15, 23, 42, .48);
    backdrop-filter: blur(2px);
}

.receivable-installments-dialog {
    display: grid;
    gap: 14px;
    width: min(760px, 100%);
    max-height: min(780px, calc(100dvh - 44px));
    overflow: auto;
    border: 1px solid #c7dbe7;
    border-radius: 14px;
    background: #fff;
    padding: 20px;
    box-shadow: 0 26px 60px rgba(15, 23, 42, .26);
}

.receivable-installments-dialog header,
.receivable-installments-dialog footer {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: center;
}

.receivable-installments-dialog h2 {
    margin: 0;
    color: var(--text);
    font-size: 1.35rem;
}

.receivable-installments-dialog p {
    margin: 6px 0 0;
    color: var(--text-muted);
}

.receivable-installments-dialog header button {
    display: inline-flex;
    width: 42px;
    height: 42px;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    font-size: 1.2rem;
    cursor: pointer;
}

.receivable-installments-table {
    display: grid;
    gap: 10px;
}

.receivable-installments-head,
.receivable-installments-row {
    display: grid;
    grid-template-columns: 120px minmax(180px, 1fr) 150px 150px;
    gap: 12px;
    align-items: center;
}

.receivable-installments-head {
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 900;
}

.receivable-installments-row {
    padding: 12px;
    border: 1px solid #d8e8ef;
    border-radius: 8px;
    background: #f8fcff;
}

.receivable-installments-row strong {
    display: inline-flex;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    border: 1px solid #a5e7f5;
    border-radius: 8px;
    background: #e8f8ff;
    color: #007c99;
}

.receivable-installments-row input,
.receivable-installments-row select {
    width: 100%;
    min-height: 44px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    padding: 0 12px;
    font: inherit;
    font-weight: 700;
}

.receivable-installments-warning {
    padding: 13px 14px;
    border: 1px solid #fde68a;
    border-radius: 8px;
    background: #fffbeb;
    color: #92400e;
}

.receivable-installments-warning strong {
    display: block;
    margin-bottom: 4px;
}

.receivable-installments-warning p {
    margin: 0;
    color: #92400e;
}

.receivable-installments-total {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: center;
    padding: 18px;
    border: 1px solid #d8e8ef;
    border-radius: 8px;
    background: #f7fbfd;
}

.receivable-installments-total span {
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 900;
    text-transform: uppercase;
}

.receivable-installments-total strong {
    color: #0085a3;
    font-size: 1.55rem;
}

.receivable-installments-dialog footer {
    padding-top: 14px;
    border-top: 1px solid #e2edf3;
}

.receivable-description-panel {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
    width: min(720px, 100%);
    max-height: min(720px, calc(100dvh - 44px));
    overflow: hidden;
    border: 1px solid #c6dce6;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 28px 70px rgba(15, 34, 48, .28);
}

.receivable-description-panel header,
.receivable-description-panel footer {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    padding: 20px 22px;
}

.receivable-description-panel header {
    border-bottom: 1px solid #d8e7ed;
    background:
        linear-gradient(135deg, rgba(232, 248, 252, .92), rgba(255, 255, 255, .98) 58%),
        #fff;
}

.receivable-description-panel header > div {
    min-width: 0;
}

.receivable-description-panel h2 {
    margin: 3px 0 0;
    color: var(--text);
    font-size: 1.35rem;
    line-height: 1.2;
}

.receivable-description-kicker {
    color: #006a83;
    font-size: .72rem;
    font-weight: 900;
    letter-spacing: .08em;
}

.receivable-description-panel header p {
    margin: 7px 0 0;
    color: var(--text-muted);
    line-height: 1.45;
}

.receivable-description-panel header button {
    display: inline-flex;
    flex: 0 0 40px;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    border: 1px solid #bfd5df;
    border-radius: 10px;
    background: #fff;
    color: #31566a;
    font-size: 1.25rem;
    font-weight: 900;
    cursor: pointer;
    transition: border-color .16s ease, background .16s ease, transform .16s ease;
}

.receivable-description-panel header button:hover,
.receivable-description-panel header button:focus-visible {
    border-color: #77b7c8;
    background: #edf9fc;
    outline: 3px solid rgba(0, 157, 190, .12);
    transform: translateY(-1px);
}

.receivable-description-options {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    overflow: auto;
    padding: 18px 22px 20px;
    background: #f7fbfd;
}

.receivable-description-options strong {
    grid-column: 1 / -1;
    margin-bottom: 2px;
    color: #31566a;
    font-size: .76rem;
    font-weight: 900;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.receivable-description-options button {
    position: relative;
    min-height: 58px;
    border: 1px solid #d1e2e9;
    border-radius: 10px;
    background: #fff;
    color: var(--text);
    padding: 11px 42px 11px 14px;
    text-align: left;
    font: inherit;
    line-height: 1.35;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(15, 65, 85, .04);
    transition: border-color .16s ease, background .16s ease, box-shadow .16s ease, transform .16s ease;
}

.receivable-description-options button::after {
    content: "›";
    position: absolute;
    top: 50%;
    right: 14px;
    display: inline-flex;
    width: 24px;
    height: 24px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: #eaf7fa;
    color: #007b96;
    font-size: 1.15rem;
    font-weight: 900;
    transform: translateY(-50%);
}

.receivable-description-options button:hover,
.receivable-description-options button:focus-visible {
    border-color: #62bdd1;
    background: #f0fbfd;
    box-shadow: 0 8px 18px rgba(0, 112, 137, .1);
    outline: none;
    transform: translateY(-1px);
}

.receivable-description-panel footer {
    justify-content: space-between;
    border-top: 1px solid #e2e8f0;
    background: #fff;
}

.receivable-description-panel footer > span {
    color: var(--text-muted);
    font-size: .84rem;
}

@media (max-width: 640px) {
    .receivable-description-modal {
        align-items: flex-end;
        padding: 12px;
    }

    .receivable-description-panel {
        max-height: calc(100dvh - 24px);
        border-radius: 16px;
    }

    .receivable-description-panel header,
    .receivable-description-panel footer {
        padding: 16px;
    }

    .receivable-description-panel header p {
        font-size: .88rem;
    }

    .receivable-description-options {
        grid-template-columns: 1fr;
        padding: 16px;
    }

    .receivable-description-panel footer {
        align-items: stretch;
        flex-direction: column;
    }

    .receivable-description-panel footer .button {
        width: 100%;
    }
}

@media (min-width: 1181px) {
    .receivable-table-shell {
        overflow: visible;
    }
}

.module-kicker,
.request-section-title > div > span {
    color: #005ea8;
    font-size: .76rem;
    font-weight: 900;
    text-transform: uppercase;
}

.module-kicker {
    display: inline-flex;
    margin-bottom: 8px;
    padding: 4px 10px;
    border: 1px solid #a5f3fc;
    border-radius: 999px;
    background: #cffafe;
}

.request-edit-actions-row {
    justify-content: flex-end;
    margin-top: 0;
}

.request-edit-page > form[id^="request-control-"] {
    display: none;
}

.request-form-card {
    padding: 16px;
}

.request-section-title {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 14px;
}

.request-section-title h2 {
    margin: 4px 0 0;
    color: var(--text);
    font-size: 1.15rem;
}

.request-id-badge {
    display: inline-flex;
    min-height: 30px;
    align-items: center;
    padding: 0 12px;
    border-radius: 999px;
    background: #f8fafc;
    color: var(--text);
    font-size: .78rem;
    font-weight: 900;
}

.request-record-state {
    display: flex;
    align-items: center;
    gap: 12px;
}

.request-form-grid {
    display: grid;
    grid-template-columns: minmax(130px, .5fr) minmax(220px, .78fr) minmax(290px, 1.08fr) minmax(260px, 1fr) minmax(260px, 1fr);
    gap: 14px;
}

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

.request-editor-field {
    display: grid;
    gap: 7px;
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 800;
}

.request-editor-field > span::after,
.request-editor-field-head > span::after {
    content: " *";
}

.request-editor-field-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

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

.request-template-actions strong {
    color: var(--text-muted);
    font-size: .76rem;
    font-weight: 900;
}

.request-simple-editor {
    overflow: auto;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    resize: vertical;
    min-height: 160px;
}

.request-editor-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px;
    border-bottom: 1px solid var(--border-soft);
    background: #f0fdfa;
}

.request-editor-toolbar button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    min-height: 32px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    cursor: pointer;
    font: inherit;
    font-weight: 900;
}

.request-editor-toolbar button:hover,
.request-editor-toolbar button:focus {
    outline: none;
    border-color: #1b93aa;
    box-shadow: 0 0 0 2px rgba(27, 147, 170, .12);
}

.request-color-button span {
    display: block;
    width: 16px;
    height: 16px;
    border-radius: 999px;
}

.request-editor-surface {
    min-height: 108px;
    padding: 16px;
    background: #fff;
    color: var(--text);
    line-height: 1.55;
}

.request-editor-surface[contenteditable="true"] {
    min-height: 230px;
}

.request-editor-surface[contenteditable="true"]:focus {
    outline: 2px solid rgba(10, 164, 196, .22);
}

.request-editor-surface.is-invalid {
    outline: 2px solid rgba(185, 65, 65, .42);
    background: #fff7f7;
}

.request-simple-editor.proposal-simple-editor {
    min-height: 0;
    overflow: visible;
    resize: none;
}

.request-simple-editor.proposal-simple-editor .request-editor-surface,
.request-simple-editor.proposal-simple-editor .request-editor-surface[contenteditable="true"] {
    min-height: 0;
    height: auto;
    overflow: visible;
}

.request-switch-line {
    display: inline-flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 10px;
    color: var(--text);
    min-height: 34px;
    font-size: .78rem;
    font-weight: 900;
}

.request-switch-compact {
    align-items: center;
    gap: 8px;
    min-height: 30px;
    padding: 0 6px 0 10px;
    border-radius: 999px;
    background: #f0fdfa;
    color: #31586b;
}

.request-switch-line input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.request-switch-control {
    position: relative;
    display: inline-flex;
    width: 42px;
    height: 24px;
    flex: 0 0 auto;
    border: 1px solid #9dc9d7;
    border-radius: 999px;
    background: #dbe7ee;
    transition: background .18s ease, border-color .18s ease;
}

.request-switch-control::after {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 16px;
    height: 16px;
    border-radius: 999px;
    background: #fff;
    box-shadow: 0 2px 6px rgba(15, 23, 42, .2);
    transition: transform .18s ease;
}

.request-switch-line input:checked + .request-switch-control {
    border-color: #00a5bd;
    background: #12c7d8;
}

.request-switch-line input:checked + .request-switch-control::after,
.request-switch-line input:checked ~ .request-switch-control::after {
    transform: translateX(18px);
}

.request-switch-line input:checked ~ .request-switch-control {
    border-color: #00a5bd;
    background: #12c7d8;
}

.request-switch-line input:focus + .request-switch-control,
.request-switch-line input:focus ~ .request-switch-control {
    box-shadow: 0 0 0 3px rgba(18, 199, 216, .18);
}

.request-owner-strip {
    grid-column: 1 / -1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border: 1px solid #a5f3fc;
    border-radius: 8px;
    background: #f0fdfa;
}

.request-current-owner {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 6px;
}

.request-owner-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 14px;
}

.request-client-picker {
    position: relative;
}

.request-client-picker input {
    padding-right: 38px;
}

.request-client-results {
    position: absolute;
    z-index: 20;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    display: grid;
    gap: 8px;
    max-height: 320px;
    overflow: auto;
    padding: 10px;
    border: 1px solid #88b2ff;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 40px rgba(15, 23, 42, .16);
}

.request-client-results[hidden] {
    display: none;
}

.request-client-option[hidden] {
    display: none;
}

.request-client-option {
    display: grid;
    gap: 6px;
    width: 100%;
    padding: 13px 14px;
    border: 1px solid #cfe3ea;
    border-radius: 8px;
    background: #eef4ff;
    color: var(--text);
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.request-client-option:hover,
.request-client-option:focus,
.request-client-option.is-active {
    outline: none;
    border-color: #2563eb;
    background: #e0ebff;
    box-shadow: 0 0 0 2px rgba(37, 99, 235, .12);
}

.request-client-option strong {
    color: var(--text);
    font-weight: 900;
}

.request-client-option span {
    color: #5c7890;
    font-size: .82rem;
    font-weight: 700;
}

.request-client-option small {
    color: #496a82;
    font-size: .82rem;
    font-weight: 700;
}

.request-owner-strip span {
    display: inline;
    color: var(--text-muted);
    font-size: .76rem;
    font-weight: 800;
}

.request-management-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
    width: 100%;
}

.request-transfer-control {
    position: relative;
}

.request-transfer-control summary {
    list-style: none;
    cursor: pointer;
}

.request-transfer-control summary::-webkit-details-marker {
    display: none;
}

.request-transfer-panel {
    position: absolute;
    z-index: 25;
    top: calc(100% + 8px);
    right: 0;
    display: grid;
    grid-template-columns: minmax(190px, 1fr) auto;
    gap: 8px;
    min-width: 340px;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 16px 38px rgba(15, 23, 42, .18);
}

.request-transfer-panel select {
    min-height: 36px;
}

.request-control-note {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    min-height: 30px;
    padding: 5px 13px;
    border-radius: 999px;
    background: #e7eef3;
    color: var(--text-muted);
    font-size: .82rem;
    font-weight: 900;
    line-height: 1;
    text-align: center;
}

.request-control-note > span,
.request-control-owned > span,
.request-control-paused > span {
    display: block;
    transform: translateY(1px);
}

.request-control-owned {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    min-height: 30px;
    padding: 5px 13px;
    border: 1px solid #86efac;
    border-radius: 999px;
    background: #dcfce7;
    color: #047857;
    font-size: .82rem;
    font-weight: 900;
    line-height: 1;
    text-align: center;
}

.request-control-paused {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    min-height: 30px;
    padding: 5px 13px;
    border: 1px solid #facc15;
    border-radius: 999px;
    background: #fef3c7;
    color: #92400e;
    font-size: .82rem;
    font-weight: 900;
    line-height: 1;
    text-align: center;
}

.request-work-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(380px, .95fr);
    gap: 16px;
}

.interaction-compose {
    display: grid;
    gap: 12px;
    margin-bottom: 14px;
    padding: 14px;
    border: 1px solid #a5f3fc;
    border-radius: 8px;
    background: #f0fffe;
}

.interaction-compose[hidden] {
    display: none;
}

.interaction-compose-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.interaction-compose-header strong {
    color: var(--text);
    font-size: 1rem;
}

.interaction-form-grid,
.exam-entry-preview,
.request-document-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    align-items: end;
}

.interaction-compose-actions {
    display: flex;
    justify-content: flex-end;
}

.interaction-attachment-option {
    display: flex !important;
    flex-direction: row !important;
    align-items: center;
    gap: 10px !important;
    min-height: 50px;
    padding: 0 14px;
    border: 1px solid #9eeaf6;
    border-radius: 8px;
    background: #ecfeff;
    color: var(--text);
    font-weight: 900 !important;
}

.interaction-attachment-option input {
    width: 18px !important;
    min-height: 18px !important;
    accent-color: #0e7490;
}

.interaction-attachment-picker {
    display: grid;
    gap: 10px;
}

.interaction-attachment-picker[hidden],
.interaction-file-preview[hidden] {
    display: none;
}

.interaction-file-select {
    display: grid !important;
    grid-template-columns: auto minmax(0, 1fr);
    grid-template-rows: auto auto;
    gap: 4px 10px !important;
    align-items: center;
    padding: 12px;
    border: 1px dashed #8bdce8;
    border-radius: 8px;
    background: #f7ffff;
    color: var(--text);
    cursor: pointer;
}

.interaction-file-select input {
    position: absolute;
    width: 1px !important;
    min-height: 1px !important;
    opacity: 0;
    pointer-events: none;
}

.interaction-file-select span {
    display: inline-flex;
    grid-row: 1 / 3;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 0 14px;
    border: 1px solid #9dc9d7;
    border-radius: 8px;
    background: #fff;
    color: #00556f;
    font-weight: 900;
}

.interaction-file-select small {
    overflow: hidden;
    color: var(--text-muted);
    font-size: .82rem;
    font-weight: 800;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.interaction-file-select:hover,
.interaction-file-select:focus-within {
    border-color: #1b93aa;
    box-shadow: 0 0 0 3px rgba(27, 147, 170, .12);
}

.interaction-file-preview {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border: 1px solid #9eeaf6;
    border-radius: 8px;
    background: #fff;
}

.interaction-file-preview > span,
.timeline-document-chip span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: #d1fae5;
    color: #047857;
    font-size: .78rem;
    font-weight: 900;
}

.interaction-file-preview > span {
    width: 52px;
    height: 52px;
}

.interaction-file-preview strong,
.interaction-file-preview small {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.interaction-file-preview strong {
    color: var(--text);
}

.interaction-file-preview small {
    margin-top: 4px;
    color: var(--text-muted);
}

.interaction-pending {
    display: grid;
    gap: 6px;
    margin-bottom: 14px;
    padding: 16px;
    border: 1px dashed #a5cbd8;
    border-radius: 8px;
    background: #f8fbfd;
    color: var(--text-muted);
}

.interaction-pending strong {
    color: var(--text);
}

.request-count-badge {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 10px;
    border-radius: 999px;
    background: #f0fdfa;
    color: #0f6b78;
    font-size: .78rem;
    font-weight: 900;
}

.timeline-preview,
.exam-history-preview,
.request-files-preview {
    display: grid;
    gap: 12px;
}

.timeline-item,
.exam-history-preview article,
.request-file-card {
    padding: 14px;
    border: 1px solid #c7e8ef;
    border-radius: 8px;
    background: #f8ffff;
}

.timeline-item {
    display: grid;
    grid-template-columns: 22px minmax(0, 1fr);
    gap: 12px;
    background: #f7ffff;
}

.timeline-item:first-child {
    border-color: #67e8f9;
    background: #efffff;
}

.timeline-dot {
    width: 14px;
    height: 14px;
    margin-top: 3px;
    border: 4px solid #cffafe;
    border-radius: 999px;
    background: #0aa4c4;
}

.timeline-item header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
}

.timeline-item header span::before {
    content: "- ";
}

.timeline-item header em {
    margin-left: auto;
    padding: 4px 10px;
    border-radius: 999px;
    background: #d1fae5;
    color: #047857;
    font-size: .72rem;
    font-style: normal;
    font-weight: 900;
}

.timeline-item strong,
.request-file-card strong {
    color: var(--text);
}

.timeline-item small,
.exam-history-preview small,
.request-file-card small {
    display: block;
    margin-top: 4px;
    color: var(--text-muted);
}

.timeline-item p {
    margin: 10px 0 0;
    color: var(--text);
    line-height: 1.5;
}

.timeline-body.is-collapsed {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 4;
}

.timeline-read-more {
    display: inline-flex;
    width: fit-content;
    margin-top: 8px;
    border: 0;
    background: transparent;
    color: #00769a;
    cursor: pointer;
    font: inherit;
    font-size: .82rem;
    font-weight: 900;
    padding: 0;
}

.timeline-read-more[hidden] {
    display: none;
}

.timeline-read-more:hover,
.timeline-read-more:focus {
    outline: none;
    color: #004d63;
    text-decoration: underline;
}

.timeline-document-chip {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    max-width: 100%;
    width: fit-content;
    align-items: center;
    gap: 7px;
    margin-top: 10px;
    padding: 6px 10px;
    border: 1px solid #67e8f9;
    border-radius: 999px;
    background: #ecfeff;
    color: #005ea8;
    font-size: .82rem;
    font-weight: 900;
    text-decoration: none;
}

.timeline-document-chip {
    word-break: break-word;
}

.timeline-document-chip span {
    min-width: 28px;
    min-height: 22px;
    padding: 0 6px;
}

.timeline-document-chip:hover,
.timeline-document-chip:focus {
    outline: none;
    border-color: #1b93aa;
    box-shadow: 0 0 0 3px rgba(27, 147, 170, .12);
}

.timeline-document-name {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-height: 1.25;
}

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

.exam-progress-grid div {
    min-height: 84px;
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: linear-gradient(135deg, #fff, #f6fdff);
}

.exam-progress-grid span {
    display: block;
    color: var(--text-muted);
    font-size: .76rem;
    font-weight: 800;
}

.exam-progress-grid strong {
    display: block;
    margin-top: 4px;
    color: var(--text);
    font-size: 1.5rem;
}

.request-production-head {
    gap: 16px;
}

.request-production-demand {
    display: flex;
    align-items: end;
    gap: 10px;
    margin-left: auto;
}

.request-production-demand label {
    display: grid;
    gap: 4px;
    color: var(--text-muted);
    font-size: .76rem;
    font-weight: 800;
}

.request-production-demand input {
    width: 132px;
    min-height: 38px;
    padding: 8px 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    font: inherit;
    font-weight: 800;
}

.request-production-demand input[readonly] {
    background: #f3f8fb;
    color: var(--text-muted);
}

.request-production-demand .button {
    min-height: 38px;
}

.request-production-demand .button[disabled] {
    cursor: not-allowed;
    opacity: .55;
}

.exam-entry-preview,
.request-document-form {
    margin: 12px 0;
}

.request-document-form {
    align-items: stretch;
    padding: 14px;
    border: 1px solid #a5f3fc;
    border-radius: 8px;
    background: #f0fffe;
}

.request-document-form[hidden] {
    display: none;
}

.request-document-form .interaction-compose-header,
.request-document-form .interaction-file-select,
.request-document-form .interaction-file-preview,
.request-document-form .interaction-compose-actions {
    grid-column: 1 / -1;
}

.request-document-form .interaction-compose-actions {
    margin-top: 2px;
}

.request-production-note {
    margin-bottom: 12px;
    padding: 12px 14px;
    border: 1px solid #d6e6ef;
    border-radius: 8px;
    background: #f5f9fc;
    color: #4d6477;
    font-size: .84rem;
    font-weight: 700;
    line-height: 1.45;
}

.exam-entry-preview {
    grid-template-columns: minmax(140px, .75fr) minmax(140px, .7fr) minmax(170px, 1fr) auto;
    align-items: end;
}

.exam-entry-preview .exam-description,
.request-document-form label:nth-child(3) {
    grid-column: auto;
}

.exam-entry-preview .button {
    min-height: 44px;
    white-space: nowrap;
}

.exam-description > button {
    align-self: flex-start;
    margin: -24px 0 0 74px;
    border: 0;
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
    font: inherit;
    font-size: .7rem;
    font-weight: 800;
    padding: 0;
    white-space: nowrap;
}

.exam-description > button:hover,
.exam-description > button:focus {
    outline: none;
    color: #005ea8;
    text-decoration: underline;
}

.request-production-history-title {
    margin: 14px 0 10px;
    color: #005ea8;
    font-size: .82rem;
    font-weight: 900;
    text-transform: uppercase;
}

.exam-history-preview article {
    display: grid;
    grid-template-columns: minmax(110px, .8fr) minmax(140px, .95fr) minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    min-height: 52px;
    background: #fff;
}

.exam-history-preview article strong {
    color: #00916e;
    font-weight: 900;
}

.exam-history-preview article span {
    color: var(--text);
    font-size: .82rem;
    font-weight: 900;
}

.exam-history-preview article small {
    margin: 0;
}

.exam-history-preview article form {
    margin: 0;
}

.request-production-delete {
    display: inline-flex;
    width: 30px;
    height: 30px;
    align-items: center;
    justify-content: center;
    border: 1px solid #fecaca;
    border-radius: 8px;
    background: #fff7f7;
    color: #b42318;
    cursor: pointer;
    font: inherit;
    font-size: 1rem;
    line-height: 1;
}

.request-production-delete:hover,
.request-production-delete:focus {
    outline: none;
    border-color: #fca5a5;
    background: #fee2e2;
    box-shadow: 0 0 0 3px rgba(185, 65, 65, .12);
}

.request-file-card {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    padding: 14px;
    border: 1px solid #c7e8ef;
    border-radius: 8px;
    background: #f8ffff;
}

.request-file-card > span {
    display: inline-flex;
    width: 52px;
    height: 52px;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: #d1fae5;
    color: #047857;
    font-weight: 900;
}

.request-file-card strong,
.request-file-card small {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

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

.request-file-actions form {
    margin: 0;
}

.request-print-report {
    display: none;
}

body.has-request-print-modal {
    overflow: hidden;
}

.request-print-modal[hidden] {
    display: none;
}

.request-print-modal {
    position: fixed;
    inset: 0;
    z-index: 1200;
    display: grid;
    place-items: center;
    padding: 32px;
    background: rgba(8, 22, 34, .62);
}

.request-print-modal-panel {
    display: grid;
    grid-template-rows: auto auto minmax(0, 1fr) auto;
    width: min(1180px, 100%);
    height: min(92vh, 980px);
    overflow: hidden;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 28px 70px rgba(7, 24, 35, .34);
}

.request-print-modal-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px;
    border-bottom: 1px solid var(--border-soft);
    color: #061b35;
    font-size: 13px;
    font-weight: 900;
    letter-spacing: .04em;
}

.request-print-modal-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 10px 16px;
    background: #2d2d2d;
    color: #fff;
}

.request-print-modal-body {
    overflow: auto;
    padding: 26px;
    background: #2f3133;
}

.request-print-modal-footer {
    display: flex;
    justify-content: flex-end;
    padding: 12px 16px;
    border-top: 1px solid var(--border-soft);
}

.request-print-modal .request-print-report {
    display: block;
    width: min(100%, 860px);
    min-height: 1120px;
    margin: 0 auto;
    padding: 52px;
    background: #fff;
    color: #061b35;
    font-family: Arial, sans-serif;
    font-size: 12px;
    box-shadow: 0 18px 42px rgba(0, 0, 0, .28);
}

.request-print-modal .request-print-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    padding-bottom: 22px;
    border-bottom: 3px solid #0ea5e9;
}

.request-print-modal .request-print-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.request-print-modal .request-print-mark {
    width: 38px;
    height: 38px;
    border: 3px solid #06a6d8;
    border-radius: 11px;
    transform: rotate(-14deg);
}

.request-print-modal .request-print-brand strong {
    display: block;
    font-size: 18px;
}

.request-print-modal .request-print-brand small,
.request-print-modal .request-print-meta small {
    display: block;
    color: #37506a;
}

.request-print-modal .request-print-meta {
    display: grid;
    gap: 8px;
    justify-items: end;
}

.request-print-modal .request-print-meta span {
    padding: 5px 12px;
    border-radius: 999px;
    background: #cffafe;
    color: #005ea8;
    font-weight: 800;
}

.request-print-modal .request-print-title {
    margin: 24px 0;
}

.request-print-modal .request-print-title h1 {
    margin: 0 0 8px;
    font-size: 25px;
    line-height: 1.15;
}

.request-print-modal .request-print-title p {
    margin: 0;
    color: #334e68;
    font-size: 15px;
}

.request-print-modal .request-print-summary,
.request-print-modal .request-print-card {
    margin-bottom: 18px;
    overflow: hidden;
    border: 1px solid #d7e3ec;
    border-radius: 14px;
}

.request-print-modal .request-print-summary {
    padding: 18px;
    background: #f8ffff;
}

.request-print-modal .request-print-summary h2 {
    margin: 0 0 8px;
    font-size: 18px;
}

.request-print-modal .request-print-summary p {
    margin: 0 0 16px;
    color: #334e68;
    font-size: 14px;
}

.request-print-modal .request-print-summary > div {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

.request-print-modal .request-print-summary article,
.request-print-modal .request-print-production article {
    border: 1px solid #d7e3ec;
    border-radius: 12px;
    background: #fff;
}

.request-print-modal .request-print-summary article {
    padding: 12px;
}

.request-print-modal .request-print-summary article span,
.request-print-modal .request-print-grid article span,
.request-print-modal .request-print-card header span {
    display: block;
    color: #5d7189;
    font-size: 10px;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.request-print-modal .request-print-summary article strong {
    display: block;
    margin-top: 5px;
    font-size: 17px;
}

.request-print-modal .request-print-card header {
    padding: 16px;
    border-bottom: 1px solid #d7e3ec;
    background: #f0f4f8;
}

.request-print-modal .request-print-card header h2 {
    margin: 3px 0 0;
    font-size: 16px;
}

.request-print-modal .request-print-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    padding: 14px 18px;
}

.request-print-modal .request-print-grid article {
    min-height: 42px;
    padding: 9px 4px;
    border-bottom: 1px solid #edf2f7;
}

.request-print-modal .request-print-grid article strong {
    display: block;
    margin-top: 5px;
}

.request-print-modal .request-print-description {
    min-height: 80px;
    padding: 16px 18px;
    line-height: 1.55;
}

.request-print-modal .request-print-timeline,
.request-print-modal .request-print-production {
    display: grid;
    gap: 10px;
    padding: 14px 16px;
}

.request-print-modal .request-print-timeline article {
    padding: 12px 14px;
    border-left: 4px solid #2563eb;
    border-radius: 0 12px 12px 0;
    background: #f5f8fc;
}

.request-print-modal .request-print-timeline article strong {
    display: block;
    margin-bottom: 6px;
}

.request-print-modal .request-print-timeline article p {
    margin: 0 0 8px;
    color: #243b53;
    line-height: 1.45;
}

.request-print-modal .request-print-timeline article small {
    color: #486581;
}

.request-print-modal .request-print-production article {
    display: grid;
    grid-template-columns: 110px 90px minmax(0, 1fr);
    gap: 18px;
    align-items: center;
    min-height: 42px;
    padding: 12px;
}

.request-print-modal .request-print-production article b {
    color: #1d4ed8;
    font-size: 15px;
}

.request-print-modal .request-print-footer {
    display: flex;
    justify-content: space-between;
    margin-top: 24px;
    padding-top: 12px;
    border-top: 1px solid #d7e3ec;
    color: #334e68;
    font-size: 11px;
}

.request-print-modal .receivable-print-report {
    width: min(100%, 980px);
}

.request-print-modal .receivable-print-table-wrap {
    overflow: hidden;
}

.request-print-modal .receivable-print-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 11px;
}

.request-print-modal .receivable-print-table th,
.request-print-modal .receivable-print-table td {
    padding: 9px 8px;
    border-bottom: 1px solid #e2e8f0;
    text-align: left;
    vertical-align: top;
}

.request-print-modal .receivable-print-table th {
    background: #f0f4f8;
    color: #334e68;
    font-size: 9px;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.request-print-modal .receivable-print-table td:nth-child(5),
.request-print-modal .receivable-print-table td:nth-child(6) {
    white-space: nowrap;
}

.request-print-modal .receivable-print-table small {
    color: #5d7189;
    font-weight: 700;
}

@media screen and (max-width: 1180px) {
    .proposals-hero,
    .proposals-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .requests-metrics-row,
    .receivables-metrics-row,
    .request-work-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .request-filter-panel,
    .receivable-filter-panel {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .request-filter-panel .filter-grow,
    .receivable-filter-panel .filter-grow {
        grid-column: 1 / -1;
    }

    .financial-period-shortcuts {
        width: 100%;
    }

    .financial-period-shortcut {
        flex: 1 1 0;
    }

    .receivable-more-filters {
        position: static;
    }

    .receivable-more-filter-grid {
        width: min(100%, 760px);
        right: auto;
        left: 0;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .request-form-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .request-owner-actions {
        align-items: flex-end;
        flex-direction: column;
    }
}

@media screen and (max-width: 760px) {
    .proposals-shell {
        overflow-x: hidden;
    }

    .proposals-page {
        width: 100%;
        max-width: 100%;
        padding: 14px 10px 32px;
    }

    .proposals-hero,
    .proposals-summary,
    .proposal-search-panel,
    .proposal-section-head,
    .proposal-footer,
    .proposal-pagination {
        display: grid;
        grid-template-columns: 1fr;
        align-items: stretch;
    }

    .proposal-per-page label {
        align-items: stretch;
    }

    .proposal-offers-panel,
    .proposal-search-panel,
    .proposal-section-head {
        padding: 12px;
    }

    .proposal-search-panel .button {
        width: 100%;
    }

    .proposal-section-head h2 {
        font-size: 1.45rem;
        line-height: 1.16;
    }

    .proposal-section-head p {
        line-height: 1.45;
    }

    .proposal-per-page label {
        display: grid;
        grid-template-columns: 1fr auto;
    }

    .proposal-table-shell {
        margin-inline: 0;
        scrollbar-width: thin;
    }

    .proposal-offer-table {
        min-width: 760px;
    }

    .proposal-offer-table th,
    .proposal-offer-table td {
        padding: 12px 10px;
    }

    .proposal-offer-table th:nth-child(4),
    .proposal-offer-table td:nth-child(4),
    .proposal-offer-table th:nth-child(5),
    .proposal-offer-table td:nth-child(5) {
        min-width: 120px;
    }

    .proposal-offer-cell {
        min-width: 250px;
    }

    .proposal-sent-panel .proposal-table-shell {
        overflow: visible;
        border: 0;
        background: transparent;
    }

    .proposal-sent-panel .proposal-history-table {
        display: block;
        min-width: 0;
        border-collapse: separate;
    }

    .proposal-sent-panel .proposal-history-table thead {
        display: none;
    }

    .proposal-sent-panel .proposal-history-table tbody,
    .proposal-sent-panel .proposal-history-table tr,
    .proposal-sent-panel .proposal-history-table td {
        display: block;
        width: 100%;
    }

    .proposal-sent-panel .proposal-history-table tr {
        margin-bottom: 12px;
        overflow: hidden;
        border: 1px solid var(--border);
        border-radius: 8px;
        background: #fff;
    }

    .proposal-sent-panel .proposal-history-table tr.is-review-open {
        background: #eefcff;
        box-shadow: inset 4px 0 0 #19c4df;
    }

    .proposal-sent-panel .proposal-history-table td {
        display: grid;
        grid-template-columns: minmax(88px, .38fr) minmax(0, 1fr);
        gap: 10px;
        min-width: 0;
        padding: 10px 12px;
        border-bottom: 1px solid #d7e3ec;
    }

    .proposal-sent-panel .proposal-history-table td::before {
        content: attr(data-label);
        color: var(--text-muted);
        font-size: .72rem;
        font-weight: 900;
        text-transform: uppercase;
    }

    .proposal-sent-panel .proposal-history-table td:last-child {
        border-bottom: 0;
    }

    .proposal-sent-panel .proposal-history-table .proposal-offer-cell {
        min-width: 0;
    }

    .proposal-sent-panel .proposal-history-table .proposal-review-row {
        border-color: #35c8df;
    }

    .proposal-sent-panel .proposal-history-table .proposal-review-row > td {
        display: block;
        padding: 0;
    }

    .proposal-sent-panel .proposal-history-table .proposal-review-row > td::before {
        display: none;
    }

    .proposal-sent-panel .proposal-row-actions,
    .proposal-sent-panel .proposal-row-actions form,
    .proposal-sent-panel .proposal-row-actions .button {
        display: grid;
        width: 100%;
    }

    .proposal-modal-backdrop {
        align-items: stretch;
        padding: 12px;
    }

    .proposal-modal {
        max-height: calc(100dvh - 24px);
        overflow: hidden;
    }

    .proposal-modal > form {
        max-height: inherit;
    }

    .proposal-modal-body {
        overflow: auto;
        -webkit-overflow-scrolling: touch;
    }

    .proposal-modal-head,
    .proposal-modal-footer,
    .proposal-material-card,
    .proposal-identity-card {
        display: grid;
        grid-template-columns: 1fr;
        align-items: stretch;
    }

    .proposal-recipient-grid {
        grid-template-columns: 1fr;
    }

    .proposal-review-inline,
    .proposal-review-grid {
        grid-template-columns: 1fr;
    }

    .proposal-review-side {
        order: -1;
    }

    .proposal-public-shell {
        width: min(100% - 24px, 980px);
        padding: 20px 0;
    }

    .proposal-public-card {
        padding: 20px;
    }

    .proposal-public-head,
    .proposal-public-meta {
        grid-template-columns: 1fr;
    }

    .proposal-public-head {
        display: grid;
    }

    .proposal-public-head-badges {
        align-items: flex-start;
    }

    .proposal-public-material {
        align-items: stretch;
        flex-direction: column;
    }

    .proposal-public-material a {
        text-align: center;
    }

    .requests-hero,
    .receivables-hero,
    .request-owner-strip,
    .requests-footer {
        flex-direction: column;
        align-items: stretch;
    }

    .request-edit-hero {
        grid-template-columns: 1fr;
        min-height: 0;
    }

    .request-edit-hero h1 {
        max-width: 100%;
        overflow-wrap: anywhere;
    }

    .request-section-title {
        align-items: flex-start;
    }

    .request-production-head,
    .request-production-demand {
        display: grid;
        grid-template-columns: 1fr;
        align-items: stretch;
        margin-left: 0;
        width: 100%;
    }

    .request-production-demand input {
        width: 100%;
    }

    .request-record-state {
        flex: 0 0 auto;
        gap: 8px;
        margin-right: 0;
        transform: translateX(-20px);
    }

    .requests-hero-actions,
    .request-edit-actions,
    .request-management-actions,
    .requests-footer-controls {
        display: grid;
        grid-template-columns: 1fr;
        justify-content: stretch;
        margin-left: 0;
    }

    .request-bottom-actions {
        display: flex;
        flex-direction: column-reverse;
        align-items: stretch;
    }

    .request-bottom-danger,
    .request-bottom-primary {
        display: grid;
        grid-template-columns: 1fr;
    }

    .payable-bottom-actions {
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
        align-items: stretch;
    }

    .payable-bottom-actions > form {
        justify-self: start;
    }

    .payable-bottom-actions .receivable-bottom-primary-actions {
        display: grid;
        grid-template-columns: 1fr;
        gap: 10px;
        width: 100%;
        margin-left: 0;
    }

    .payable-bottom-actions .receivable-bottom-primary-actions .button {
        width: 100%;
        justify-content: center;
    }

    .request-bottom-danger .button,
    .request-bottom-primary .button {
        width: 100%;
    }

    .request-technical-history-head {
        display: grid;
        grid-template-columns: 1fr;
        gap: 10px;
        padding: 16px;
    }

    .request-technical-history-head strong {
        white-space: normal;
    }

    .request-technical-history-list {
        margin: 12px 16px 16px;
    }

    .request-technical-history-list article {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .request-owner-actions {
        display: grid;
        grid-template-columns: 1fr;
        justify-items: stretch;
    }

    .request-transfer-control {
        position: static;
    }

    .request-transfer-panel {
        position: static;
        grid-template-columns: 1fr;
        min-width: 0;
        margin-top: 8px;
    }

    .requests-metrics-row,
    .receivables-metrics-row,
    .request-filter-panel,
    .receivable-filter-panel,
    .request-form-grid,
    .request-work-grid,
    .interaction-form-grid,
    .exam-entry-preview,
    .request-document-form,
    .exam-progress-grid {
        grid-template-columns: 1fr;
    }

    .financial-hero-tools {
        display: grid;
        grid-template-columns: 1fr;
        align-items: stretch;
    }

    .financial-context-options {
        display: flex;
    }

    .financial-context-option {
        flex: 1 1 0;
    }

    .receivable-filter-panel .button,
    .receivable-more-filters > summary,
    .receivable-more-filter-grid .button {
        width: 100%;
    }

    .receivable-list-toolbar {
        align-items: stretch;
    }

    .receivable-list-toolbar nav {
        display: grid;
        grid-template-columns: 1fr;
        width: min(100%, 180px);
    }

    .receivable-list-toolbar nav .button,
    .account-selection-summary {
        width: 100%;
    }

    .account-selection-summary {
        display: grid;
    }

    .account-selection-summary-panel {
        right: 0;
        width: 230px;
    }

    .receivable-more-filters {
        position: static;
    }

    .receivable-more-filter-grid {
        position: static;
        width: 100%;
        grid-template-columns: 1fr;
        margin-top: 10px;
        box-shadow: none;
    }

    .receivable-duplicate-alert {
        display: grid;
        grid-template-columns: 1fr;
        align-items: stretch;
    }

    .receivable-duplicate-alert strong {
        text-align: center;
    }

    .receivable-duplicate-hero > div,
    .receivable-duplicate-footer {
        display: grid;
        grid-template-columns: 1fr;
    }

    .receivable-duplicate-banner,
    .receivable-duplicate-metrics,
    .receivable-duplicate-grid {
        grid-template-columns: 1fr;
    }

    .receivable-duplicate-banner strong {
        text-align: center;
    }

    .receivable-table {
        min-width: 1180px;
    }

    .receivable-action-menu > div {
        position: fixed;
        top: auto;
        right: 16px;
        bottom: 18px;
        left: 16px;
        z-index: 60;
        min-width: 0;
        padding: 12px;
        box-shadow: 0 18px 42px rgba(15, 40, 60, .24);
    }

    .receivable-action-menu a {
        min-height: 42px;
        display: flex;
        align-items: center;
    }

    .receivable-footer,
    .receivable-totals {
        display: grid;
        grid-template-columns: 1fr;
        align-items: stretch;
    }

    .receivable-footer .requests-footer-controls {
        margin-left: 0;
    }

    .receivable-summary-row,
    .receivable-summary-grid,
    .receivable-form-grid,
    .receivable-secondary-grid,
    .receivable-payment-grid,
    .receivable-fields-grid,
    .receivable-fields-grid.compact {
        grid-template-columns: 1fr;
    }

    .receivable-form-card header,
    .receivable-payment-item,
    .receivable-payment-history div {
        display: grid;
        grid-template-columns: 1fr;
    }

    .receivable-reminder-card summary {
        display: grid;
        grid-template-columns: 1fr;
    }

    .receivable-reminder-card summary em {
        justify-content: center;
    }

    .receivable-client-history summary {
        display: grid;
        grid-template-columns: 1fr;
    }

    .receivable-client-history summary em {
        justify-content: center;
    }

    .receivable-client-history-scroll {
        max-height: 260px;
    }

    .receivable-reminder-controls,
    .receivable-reminder-list label {
        grid-template-columns: 1fr;
    }

    .rental-invoice-reminder-controls,
    .rental-invoice-reminder-recipient,
    .rental-invoice-reminder-channel-grid,
    .rental-invoice-reminder-contact-grid {
        grid-template-columns: 1fr;
    }

    .rental-invoice-reminder-recipient {
        align-items: start;
    }

    .rental-invoice-reminder-contact-grid article {
        min-height: 64px;
    }

    .receivable-party-summary {
        grid-template-columns: 1fr;
    }

    .receivable-party-summary span {
        text-align: left;
    }

    .receivable-document-list div {
        grid-template-columns: 1fr;
        padding-right: 14px;
    }

    .receivable-document-list span {
        justify-self: start;
        grid-column: 1;
        grid-row: auto;
    }

    .receivable-document-list nav {
        display: grid;
        grid-column: 1;
        grid-row: auto;
        grid-template-columns: 1fr;
    }

    .receivable-installments-modal {
        align-items: stretch;
        padding: 12px;
    }

    .receivable-installments-dialog {
        max-height: calc(100dvh - 24px);
    }

    .receivable-installments-dialog header,
    .receivable-installments-dialog footer,
    .receivable-installments-total,
    .receivable-installments-head,
    .receivable-installments-row {
        display: grid;
        grid-template-columns: 1fr;
    }

    .receivable-installments-head {
        display: none;
    }

    .receivable-installments-dialog footer .button {
        width: 100%;
    }

    .request-operational-table {
        min-width: 1120px;
    }

    .timeline-item {
        position: relative;
        grid-template-columns: 1fr;
        padding-left: 28px;
    }

    .timeline-dot {
        position: absolute;
        top: 17px;
        left: 10px;
    }

    .timeline-document-chip {
        width: 100%;
        border-radius: 8px;
        align-items: flex-start;
    }

    .timeline-document-chip span {
        min-width: 42px;
    }

    .exam-history-preview article {
        grid-template-columns: 1fr auto;
    }

    .exam-history-preview article strong,
    .exam-history-preview article span,
    .exam-history-preview article small {
        grid-column: 1;
    }

    .exam-history-preview article form {
        grid-column: 2;
        grid-row: 1 / span 3;
        align-self: center;
    }

    .request-file-card {
        grid-template-columns: 52px minmax(0, 1fr);
    }

    .request-file-actions {
        grid-column: 1 / -1;
        justify-content: flex-end;
    }

    .request-print-modal {
        padding: 10px;
    }

    .request-print-modal-panel {
        height: 94vh;
    }

    .request-print-modal-body {
        padding: 14px;
    }

    .request-print-modal .request-print-report {
        width: 760px;
        min-height: 990px;
        padding: 36px;
    }
}

@media print {
    .request-print-modal,
    .request-print-modal[hidden] {
        position: static !important;
        display: block !important;
        padding: 0 !important;
        background: #fff !important;
    }

    .request-print-modal-panel,
    .request-print-modal-body {
        display: block !important;
        width: auto !important;
        height: auto !important;
        max-width: none !important;
        overflow: visible !important;
        padding: 0 !important;
        background: #fff !important;
        box-shadow: none !important;
    }

    .request-print-modal-head,
    .request-print-modal-toolbar,
    .request-print-modal-footer {
        display: none !important;
    }

    .request-print-modal .request-print-report {
        width: auto !important;
        min-height: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        box-shadow: none !important;
    }
}

@media print {
    body:has(.receivables-page) {
        background: #fff !important;
    }

    body:has(.receivables-page) .app-sidebar,
    body:has(.receivables-page) .authenticated-sidebar,
    body:has(.receivables-page) .app-topbar,
    body:has(.receivables-page) .authenticated-topbar,
    body:has(.receivables-page) .receivables-hero .requests-hero-actions,
    body:has(.receivables-page) .receivables-metrics-row,
    body:has(.receivables-page) .receivable-filter-panel,
    body:has(.receivables-page) .receivable-list-toolbar nav,
    body:has(.receivables-page) .requests-footer-controls,
    body:has(.receivables-page) .receivable-table .check-col,
    body:has(.receivables-page) .receivable-table .check-cell,
    body:has(.receivables-page) .receivable-table th:last-child,
    body:has(.receivables-page) .receivable-table td:last-child {
        display: none !important;
    }

    body:has(.receivables-page) .app-main,
    body:has(.receivables-page) .authenticated-main,
    body:has(.receivables-page) .receivables-page {
        display: block !important;
        max-width: none !important;
        margin: 0 !important;
        padding: 0 !important;
        background: #fff !important;
    }

    body:has(.receivables-page) .receivable-table-card,
    body:has(.receivables-page) .receivable-table-shell {
        overflow: visible !important;
        border: 0 !important;
        box-shadow: none !important;
    }

    body:has(.receivables-page) .receivable-table {
        min-width: 0 !important;
        font-size: 10px !important;
    }

    body:has(.receivables-page) .receivable-table th,
    body:has(.receivables-page) .receivable-table td {
        padding: 7px 6px !important;
    }

    body:has(.receivables-page) .receivable-totals {
        margin-top: 10px;
    }
}

.communication-shell {
    display: grid;
    gap: 18px;
}

.communication-page-head,
.communication-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
}

.communication-page-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 18px;
    align-items: center;
    padding: 22px;
}

.communication-page-head-sms {
    grid-template-columns: 1fr;
}

.communication-page-head-whatsapp {
    grid-template-columns: 1fr;
}

.communication-page-head > div:first-child {
    display: grid;
    gap: 5px;
}

.communication-page-head span,
.communication-card-hero small,
.communication-health-grid b {
    color: var(--accent);
    font-size: .76rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.communication-page-head h1,
.communication-card-hero h2 {
    margin: 0;
    color: var(--text);
}

.communication-page-head p,
.communication-card-hero p,
.communication-health-grid small,
.communication-secret small,
.communication-test-form small {
    margin: 0;
    color: var(--text-muted);
}

.communication-kpis {
    display: grid;
    grid-template-columns: repeat(3, minmax(130px, 1fr));
    gap: 10px;
}

.communication-kpis-four {
    grid-template-columns: repeat(4, minmax(130px, 1fr));
}

.communication-kpis-five {
    grid-template-columns: repeat(5, minmax(130px, 1fr));
}

.communication-kpis article,
.communication-health-grid article {
    background: color-mix(in srgb, var(--accent) 6%, var(--surface));
    border: 1px solid color-mix(in srgb, var(--accent) 18%, var(--border));
    border-radius: 8px;
    padding: 13px 14px;
}

.communication-kpis small {
    display: block;
    color: var(--accent);
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.communication-kpis strong {
    display: block;
    margin-top: 6px;
    color: var(--text);
    font-size: 1rem;
}

.communication-balance-kpi {
    min-width: 170px;
}

.communication-balance-kpi > div {
    display: flex;
    gap: 8px;
    align-items: flex-end;
    justify-content: space-between;
    margin-top: 5px;
}

.communication-balance-kpi p {
    max-width: 190px;
    font-size: .68rem;
    line-height: 1.25;
}

.communication-balance-kpi a {
    color: var(--accent);
    font-size: .7rem;
    font-weight: 800;
    text-decoration: none;
}

.communication-balance-kpi a:hover,
.communication-balance-kpi a:focus-visible {
    text-decoration: underline;
}

.communication-balance-kpi.is-available {
    border-color: color-mix(in srgb, #059669 42%, var(--border));
    background: color-mix(in srgb, #059669 8%, var(--surface));
}

.communication-balance-kpi.is-stale,
.communication-balance-kpi.is-unavailable {
    border-color: color-mix(in srgb, #d97706 44%, var(--border));
    background: color-mix(in srgb, #d97706 8%, var(--surface));
}

.communication-card {
    padding: 16px;
}

.communication-card-email {
    border-top: 3px solid #05a7b5;
}

.communication-card-sms {
    border-top: 3px solid #8b5cf6;
}

.communication-card-whatsapp {
    border-top: 3px solid #16a34a;
}

.communication-card-hero {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 14px;
    align-items: center;
    background: color-mix(in srgb, var(--accent) 5%, var(--surface));
    border: 1px solid color-mix(in srgb, var(--accent) 18%, var(--border));
    border-radius: 8px;
    padding: 14px;
}

.communication-card-hero em {
    justify-self: end;
    background: color-mix(in srgb, var(--accent) 14%, #fff);
    border: 1px solid color-mix(in srgb, var(--accent) 28%, var(--border));
    border-radius: 999px;
    color: var(--accent);
    font-size: .78rem;
    font-style: normal;
    font-weight: 800;
    padding: 8px 12px;
    white-space: nowrap;
}

.communication-avatar {
    display: inline-grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 8px;
    background: #0ea5e9;
    color: #fff;
    font-weight: 900;
}

.communication-avatar-sms {
    background: #8b5cf6;
}

.communication-avatar-whatsapp {
    background: #16a34a;
}

.communication-form {
    display: grid;
    gap: 14px;
    margin-top: 14px;
}

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

.communication-grid-four {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.communication-form label {
    display: grid;
    gap: 7px;
    color: var(--text);
    font-size: .86rem;
    font-weight: 700;
}

.communication-form input,
.communication-form select,
.communication-form textarea {
    min-height: 38px;
    width: 100%;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: color-mix(in srgb, var(--accent) 5%, #fff);
    color: var(--text);
    font: inherit;
    padding: 9px 11px;
}

.communication-form textarea {
    min-height: 78px;
    resize: vertical;
}

.communication-inner-panel {
    display: grid;
    gap: 12px;
    background: color-mix(in srgb, var(--accent) 4%, #fff);
    border: 1px solid color-mix(in srgb, var(--accent) 18%, var(--border));
    border-radius: 8px;
    padding: 12px;
}

.communication-secret {
    max-width: 430px;
}

.communication-check {
    display: flex !important;
    grid-template-columns: none;
    align-items: center;
    gap: 10px !important;
    width: fit-content;
}

.communication-check input {
    width: auto;
    min-height: 0;
}

.communication-actions {
    display: flex;
    justify-content: flex-end;
}

.communication-template-panel {
    gap: 14px;
}

.communication-template-panel .communication-section-head p {
    margin: 5px 0 0;
    color: var(--text-muted);
    font-size: .78rem;
}

.communication-template-head-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 9px;
    flex-wrap: wrap;
}

.communication-template-head-actions > span,
.communication-template-head-actions > a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    border: 1px solid var(--border-strong);
    border-radius: 999px;
    padding: 7px 12px;
    background: color-mix(in srgb, var(--accent) 5%, #fff);
    color: var(--accent);
    font-size: .75rem;
    font-weight: 900;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
}

.communication-template-head-actions > a:hover,
.communication-template-head-actions > a:focus {
    border-color: var(--accent);
    background: color-mix(in srgb, var(--accent) 11%, #fff);
    outline: none;
}

a[data-click-once].is-loading {
    cursor: wait;
    opacity: .68;
    pointer-events: none;
}

.communication-template-group {
    display: grid;
    gap: 9px;
}

.communication-template-group h3 {
    margin: 0;
    color: var(--text);
    font-size: .92rem;
}

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

.communication-template-grid label {
    align-content: start;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 13px;
}

.communication-template-grid label > span {
    color: var(--text);
    font-weight: 800;
}

.communication-template-grid code {
    color: var(--accent);
    font-size: .72rem;
}

.communication-template-grid b {
    color: var(--text-muted);
    font-size: .72rem;
}

.communication-template-grid b.is-configured {
    color: #15803d;
}

.communication-template-approval {
    display: inline-flex;
    width: fit-content;
    margin-top: 4px;
    border-radius: 999px;
    padding: 4px 8px;
    font-size: .7rem;
    font-style: normal;
    font-weight: 900;
}

.communication-template-approval.is-approved {
    background: #dcfce7;
    color: #15803d;
}

.communication-template-approval.is-pending {
    background: #fef3c7;
    color: #a16207;
}

.communication-template-approval.is-rejected {
    background: #fee2e2;
    color: #b91c1c;
}

.communication-template-rejection {
    color: #b91c1c !important;
    overflow-wrap: anywhere;
}

.communication-template-note,
.communication-foundation-note p {
    margin: 0;
    color: var(--text-muted);
    font-size: .82rem;
    line-height: 1.5;
}

.communication-foundation-note > div {
    display: grid;
    gap: 6px;
}

.communication-foundation-note small {
    color: var(--accent);
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.communication-foundation-note h2 {
    margin: 0;
    color: var(--text);
    font-size: 1.05rem;
}

.communication-test-form {
    grid-template-columns: minmax(220px, .7fr) minmax(220px, 1fr) auto;
    align-items: end;
    margin-top: 0;
}

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

.communication-health-grid-four {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.communication-health-grid article {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 6px 10px;
}

.communication-health-grid b {
    display: inline-grid;
    grid-row: span 2;
    place-items: center;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: color-mix(in srgb, var(--accent) 12%, #fff);
    letter-spacing: 0;
}

.communication-health-grid strong {
    color: var(--text);
}

.communication-health-detail {
    display: flex;
    min-width: 0;
    align-items: flex-end;
    justify-content: space-between;
    gap: 8px;
}

.communication-health-detail a {
    flex: none;
    color: var(--accent);
    font-size: .7rem;
    font-weight: 800;
    text-decoration: none;
}

.communication-health-detail a:hover,
.communication-health-detail a:focus-visible {
    text-decoration: underline;
}

.communication-health-grid .communication-health-balance.is-available {
    border-color: color-mix(in srgb, #059669 42%, var(--border));
    background: color-mix(in srgb, #059669 8%, var(--surface));
}

.communication-health-grid .communication-health-balance.is-stale,
.communication-health-grid .communication-health-balance.is-unavailable {
    border-color: color-mix(in srgb, #d97706 44%, var(--border));
    background: color-mix(in srgb, #d97706 8%, var(--surface));
}

.communication-health-grid .is-active {
    border-color: color-mix(in srgb, #059669 42%, var(--border));
}

.communication-health-grid .is-warning {
    border-color: color-mix(in srgb, #d97706 44%, var(--border));
    background: color-mix(in srgb, #d97706 7%, var(--surface));
}

.communication-alert {
    margin: 0;
}

.communication-shell [hidden] {
    display: none !important;
}

.communication-readiness {
    display: grid;
    gap: 8px;
    background: #fff8ec;
    border: 1px solid rgba(183, 119, 31, .38);
    border-radius: 8px;
    color: var(--text);
    padding: 13px 14px;
}

.communication-readiness strong {
    color: #7b3f00;
}

.communication-readiness p {
    margin: 0;
    color: var(--text-muted);
}

.communication-readiness div {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.communication-readiness span {
    background: #fff;
    border: 1px solid rgba(183, 119, 31, .35);
    border-radius: 999px;
    color: #8a4500;
    font-size: .78rem;
    font-weight: 800;
    padding: 6px 9px;
}

.communication-section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 12px;
}

.communication-section-head small {
    color: var(--accent);
    font-size: .74rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.communication-section-head h2 {
    margin: 4px 0 0;
    color: var(--text);
    font-size: 1.05rem;
}

.communication-section-head span,
.communication-section-head a {
    background: color-mix(in srgb, var(--accent) 10%, #fff);
    border: 1px solid color-mix(in srgb, var(--accent) 26%, var(--border));
    border-radius: 999px;
    color: var(--accent);
    font-size: .78rem;
    font-weight: 800;
    padding: 7px 11px;
    text-decoration: none;
    white-space: nowrap;
}

.communication-section-head a:hover,
.communication-section-head a:focus {
    background: color-mix(in srgb, var(--accent) 16%, #fff);
    outline: none;
}

.communication-history-list {
    display: grid;
    gap: 8px;
}

.communication-history-list article {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 12px;
    align-items: center;
    background: color-mix(in srgb, var(--accent) 4%, #fff);
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 11px 12px;
}

.communication-history-list strong,
.communication-history-list small {
    display: block;
}

.communication-history-list strong {
    color: var(--text);
}

.communication-history-list small,
.communication-history-list em {
    color: var(--text-muted);
    font-style: normal;
}

.communication-history-item-summary {
    display: -webkit-box !important;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow-wrap: anywhere;
}

.communication-history-list span {
    background: color-mix(in srgb, var(--accent) 9%, #fff);
    border-radius: 999px;
    color: var(--accent);
    font-size: .76rem;
    font-weight: 800;
    padding: 6px 9px;
    white-space: nowrap;
}

.communication-history-state {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
}

.communication-history-state form {
    margin: 0;
}

.communication-history-state button {
    min-height: 28px;
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 5px 9px;
    background: #fff;
    color: var(--accent);
    cursor: pointer;
    font-size: .74rem;
    font-weight: 800;
}

.communication-history-state button:hover,
.communication-history-state button:focus {
    border-color: var(--accent);
    background: color-mix(in srgb, var(--accent) 7%, #fff);
    outline: none;
}

.communication-history-state button:disabled,
.communication-history-modal-actions button:disabled {
    cursor: wait;
    opacity: .68;
}

.communication-history-note {
    margin: 10px 0 0;
    color: var(--text-muted);
    font-size: .82rem;
}

.communication-empty {
    margin: 0;
    color: var(--text-muted);
}

.agenda-shell {
    display: grid;
    gap: 18px;
}

.agenda-page-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 18px;
    align-items: center;
}

.agenda-page-head span,
.agenda-section-head small,
.agenda-side small {
    color: var(--accent);
    font-size: .76rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.agenda-page-head h1,
.agenda-section-head h2,
.agenda-side h2 {
    margin: 0;
    color: var(--text);
}

.agenda-page-head p,
.agenda-section-head p,
.agenda-side p,
.agenda-side span {
    margin: 0;
    color: var(--text-muted);
}

.agenda-actions {
    display: flex;
    gap: 12px;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
}

.agenda-actions .button[disabled] {
    opacity: .68;
    cursor: not-allowed;
}

.agenda-view-switch {
    display: inline-flex;
    gap: 4px;
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 4px;
}

.agenda-view-switch a {
    border-radius: 6px;
    color: var(--text-muted);
    font-size: .85rem;
    font-weight: 800;
    padding: 9px 14px;
    text-decoration: none;
}

.agenda-view-switch a.is-active {
    background: color-mix(in srgb, var(--accent) 10%, #fff);
    border: 1px solid color-mix(in srgb, var(--accent) 32%, var(--border));
    color: var(--accent);
}

.agenda-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(300px, 360px);
    gap: 16px;
}

.agenda-layout-list {
    grid-template-columns: 1fr;
}

.agenda-main-card,
.agenda-side section {
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: 8px;
}

.agenda-main-card {
    padding: 18px;
    min-width: 0;
}

.agenda-section-head {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
    align-items: start;
    margin-bottom: 16px;
    padding-right: 150px;
}

.agenda-section-head > div {
    display: grid;
    gap: 5px;
}

.agenda-period-actions {
    display: inline-flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    position: absolute;
    top: 0;
    right: 0;
    gap: 8px;
    align-items: center;
    justify-content: flex-end;
    width: max-content;
    min-width: 150px;
    white-space: nowrap;
}

.agenda-period-actions a {
    display: inline-grid;
    place-items: center;
    min-width: 42px;
    min-height: 38px;
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    color: var(--accent);
    font-weight: 800;
    text-decoration: none;
    flex: 0 0 auto;
}

.agenda-month-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(92px, 1fr));
    gap: 6px;
    overflow-x: auto;
}

.agenda-grid-heading {
    color: var(--text);
    font-size: .78rem;
    padding: 6px 8px;
    text-align: center;
    text-transform: uppercase;
}

.agenda-day-cell {
    position: relative;
    display: grid;
    align-content: start;
    gap: 6px;
    min-height: 106px;
    background: color-mix(in srgb, var(--surface) 88%, var(--page-bg));
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 9px;
}

.agenda-day-create-link {
    position: absolute;
    inset: 0;
    z-index: 0;
    border-radius: 8px;
}

.agenda-day-create-link:hover,
.agenda-day-create-link:focus {
    outline: 2px solid color-mix(in srgb, var(--accent) 35%, transparent);
    outline-offset: -2px;
}

.agenda-day-cell.is-muted {
    opacity: .58;
}

.agenda-day-cell.is-today {
    background: color-mix(in srgb, var(--accent) 7%, #fff);
    border-color: #05a7b5;
    box-shadow: inset 0 0 0 1px #05a7b5;
}

.agenda-day-cell.is-today b {
    color: var(--accent);
    font-weight: 900;
}

.agenda-day-cell b {
    position: relative;
    z-index: 1;
    color: var(--text);
    font-size: .88rem;
}

.agenda-event {
    position: relative;
    z-index: 2;
    display: grid;
    gap: 3px;
    background: #dff7fb;
    border: 1px solid #89ddec;
    border-radius: 6px;
    color: var(--text);
    padding: 7px 8px;
    text-decoration: none;
}

.agenda-event strong {
    color: inherit;
    font-size: .78rem;
    line-height: 1.25;
}

.agenda-event span {
    color: var(--text-muted);
    font-size: .72rem;
}

.agenda-event-green,
.agenda-event-operational {
    background: #def8ea;
    border-color: #9de0bd;
}

.agenda-event-blue {
    background: #dff7fb;
    border-color: #89ddec;
}

.agenda-event-orange,
.agenda-event-sms {
    background: #fff2d7;
    border-color: #f1c36f;
}

.agenda-week-grid {
    display: grid;
    grid-template-columns: 54px repeat(7, minmax(92px, 1fr));
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    overflow-x: hidden;
    overflow-y: visible;
}

.agenda-week-grid > * {
    min-height: 72px;
    border-right: 1px solid var(--border-soft);
    border-bottom: 1px solid var(--border-soft);
    padding: 10px;
}

.agenda-week-grid > strong,
.agenda-week-grid > b {
    background: color-mix(in srgb, var(--accent) 5%, var(--surface));
    color: var(--text);
    font-size: .76rem;
}

.agenda-week-slot {
    position: relative;
    display: grid;
    align-content: start;
    gap: 6px;
}

.agenda-week-slot.is-today {
    background: color-mix(in srgb, var(--accent) 5%, #fff);
}

.agenda-week-create-link {
    position: absolute;
    inset: 0;
    z-index: 0;
    border-radius: 6px;
}

.agenda-week-create-link:hover,
.agenda-week-create-link:focus {
    outline: 2px solid color-mix(in srgb, var(--accent) 35%, transparent);
    outline-offset: -2px;
}

.agenda-week-mobile-list {
    display: none;
}

.agenda-day-list {
    display: grid;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    overflow: hidden;
}

.agenda-day-list article {
    position: relative;
    display: grid;
    grid-template-columns: 80px minmax(0, 1fr);
    min-height: 66px;
    border-bottom: 1px solid var(--border-soft);
}

.agenda-day-slot:hover,
.agenda-day-slot:focus-within {
    background: color-mix(in srgb, var(--accent) 5%, #fff);
}

.agenda-day-slot:hover .agenda-day-create-link,
.agenda-day-slot:focus-within .agenda-day-create-link {
    outline: 2px solid color-mix(in srgb, var(--accent) 25%, transparent);
    outline-offset: -2px;
}

.agenda-day-slot .agenda-day-create-link {
    z-index: 1;
}

.agenda-day-list article:last-child {
    border-bottom: 0;
}

.agenda-day-list b,
.agenda-day-list > article > div {
    position: relative;
    z-index: 2;
    padding: 14px;
    pointer-events: none;
}

.agenda-day-list .agenda-event {
    pointer-events: auto;
}

.agenda-day-list b {
    color: var(--text);
}

.agenda-day-list > article > div {
    display: grid;
    gap: 8px;
}

.agenda-day-list > article > div > span {
    color: var(--text-soft);
    font-weight: 700;
}

.agenda-list-filters {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) minmax(180px, .28fr) minmax(180px, .28fr) auto;
    gap: 10px;
    align-items: end;
    margin-bottom: 16px;
}

.agenda-list-filters label {
    display: grid;
    gap: 6px;
    color: var(--text-muted);
    font-size: .82rem;
    font-weight: 700;
}

.agenda-list-filters input,
.agenda-list-filters select {
    min-height: 42px;
    border: 1px solid var(--border);
    border-radius: 7px;
    color: var(--text);
    padding: 0 12px;
}

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

.agenda-table {
    width: 100%;
    border-collapse: collapse;
}

.agenda-table th,
.agenda-table td {
    border-bottom: 1px solid var(--border-soft);
    color: var(--text);
    padding: 14px 10px;
    text-align: left;
}

.agenda-table th {
    background: color-mix(in srgb, var(--accent) 5%, var(--surface));
    font-size: .75rem;
    text-transform: uppercase;
}

.agenda-table-row:hover {
    background: color-mix(in srgb, var(--accent) 5%, #fff);
}

.agenda-table td small {
    display: block;
    color: var(--text-muted);
    margin-top: 4px;
}

.agenda-table th:last-child,
.agenda-table td:last-child {
    width: 92px;
    text-align: right;
}

.agenda-edit-action {
    min-height: 34px;
    padding: 8px 12px;
}

.agenda-status {
    display: inline-flex;
    background: #fff2d7;
    border-radius: 999px;
    color: var(--warning);
    font-size: .76rem;
    font-weight: 800;
    padding: 6px 10px;
}

.agenda-side {
    display: grid;
    align-content: start;
    gap: 16px;
}

.agenda-side section {
    display: grid;
    gap: 14px;
    padding: 18px;
}

.agenda-side article,
.agenda-side .agenda-upcoming-item {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 4px 10px;
    border-left: 4px solid #05a7b5;
    padding-left: 10px;
    color: inherit;
    text-decoration: none;
}

.agenda-side article b {
    display: inline-grid;
    place-items: center;
    width: 34px;
    height: 34px;
    background: color-mix(in srgb, var(--accent) 10%, #fff);
    border-radius: 50%;
    color: var(--accent);
    grid-row: span 2;
}

.agenda-side article strong {
    color: var(--text);
}

.agenda-side .agenda-upcoming-item {
    grid-template-columns: 1fr;
    gap: 4px;
}

.agenda-side .agenda-upcoming-item strong {
    line-height: 1.25;
}

.agenda-side .agenda-upcoming-item em {
    color: var(--accent);
    font-size: .78rem;
    font-style: normal;
    font-weight: 800;
}

.agenda-side .agenda-upcoming-item:hover,
.agenda-side .agenda-upcoming-item:focus {
    background: color-mix(in srgb, var(--accent) 7%, #fff);
    outline: 2px solid color-mix(in srgb, var(--accent) 32%, transparent);
    outline-offset: 4px;
}

.agenda-side article.is-muted {
    opacity: .65;
}

.agenda-summary-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
}

.agenda-summary-state {
    display: inline-flex;
    align-items: center;
    border: 1px solid var(--border);
    border-radius: 999px;
    color: var(--text-muted);
    font-size: .72rem;
    font-weight: 900;
    padding: 5px 9px;
}

.agenda-summary-state.is-active {
    border-color: color-mix(in srgb, #00a875 35%, var(--border));
    background: color-mix(in srgb, #00a875 10%, #fff);
    color: #007652;
}

.agenda-summary-form {
    display: grid;
    gap: 10px;
}

.agenda-summary-toggle,
.agenda-summary-channels label {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 5px 9px;
    align-items: start;
    border: 1px solid var(--border-soft);
    border-radius: 7px;
    color: var(--text);
    padding: 10px;
}

.agenda-summary-toggle input,
.agenda-summary-channels input {
    width: 17px;
    height: 17px;
    margin: 1px 0 0;
    accent-color: #00a875;
}

.agenda-summary-toggle span,
.agenda-summary-channels span {
    display: grid;
    gap: 2px;
    min-width: 0;
}

.agenda-summary-toggle small,
.agenda-summary-channels small {
    overflow-wrap: anywhere;
    color: var(--text-muted);
    font-size: .72rem;
    font-weight: 500;
    letter-spacing: 0;
    text-transform: none;
}

.agenda-summary-channels {
    display: grid;
    gap: 8px;
}

.agenda-summary-channels label:has(input:checked) {
    border-color: color-mix(in srgb, #00a875 38%, var(--border));
    background: color-mix(in srgb, #00a875 7%, #fff);
}

.agenda-summary-channels label.is-unavailable {
    opacity: .58;
}

.agenda-summary-warning {
    color: var(--warning) !important;
    font-size: .74rem;
}

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

.agenda-diagnostic-link {
    width: 100%;
    justify-content: center;
}

.agenda-modal {
    position: fixed;
    inset: 0;
    z-index: 90;
    display: grid;
    place-items: center;
    height: 100vh;
    height: 100dvh;
    box-sizing: border-box;
    overflow: hidden;
    background: rgba(15, 31, 43, .44);
    padding: 22px;
}

.agenda-modal-panel {
    width: min(980px, 100%);
    max-height: calc(100vh - 44px);
    max-height: calc(100dvh - 44px);
    overflow: auto;
    overscroll-behavior: contain;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    box-shadow: 0 26px 80px rgba(13, 35, 48, .24);
    padding: 22px;
}

.agenda-modal-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 16px;
    align-items: start;
    margin-bottom: 16px;
}

.agenda-modal-head small {
    color: var(--accent);
    font-size: .76rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.agenda-modal-head h2 {
    margin: 6px 0 6px;
    color: var(--text);
    font-size: 1.45rem;
}

.agenda-modal-head p {
    margin: 0;
    color: var(--text-muted);
}

.agenda-modal-close {
    display: inline-grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    color: var(--text-muted);
    font-weight: 900;
    text-decoration: none;
}

.agenda-modal-errors {
    margin-bottom: 14px;
}

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

.agenda-modal-form label {
    display: grid;
    gap: 7px;
    color: var(--text-muted);
    font-size: .84rem;
    font-weight: 700;
}

.agenda-modal-form input,
.agenda-modal-form select,
.agenda-modal-form textarea {
    width: 100%;
    min-height: 42px;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: color-mix(in srgb, var(--accent) 5%, #fff);
    color: var(--text);
    font: inherit;
    padding: 10px 12px;
}

.agenda-modal-form textarea {
    min-height: 96px;
    resize: vertical;
}

.agenda-modal-full {
    grid-column: 1 / -1;
}

.agenda-reminder-box {
    display: flex;
    flex-wrap: wrap;
    gap: 14px 18px;
    align-items: center;
    min-height: 48px;
    margin: 4px 0 10px;
    background: color-mix(in srgb, var(--accent) 8%, #fff);
    border: 1px solid color-mix(in srgb, var(--accent) 28%, var(--border));
    border-radius: 8px;
    padding: 12px 14px;
}

.agenda-reminder-box legend {
    margin-right: 8px;
    color: var(--text);
    font-size: .84rem;
    font-weight: 900;
}

.agenda-reminder-box label {
    display: inline-flex;
    grid-template-columns: none;
    align-items: center;
    gap: 7px;
    color: var(--text);
    font-weight: 800;
}

.agenda-reminder-box input {
    width: 16px;
    min-height: 0;
    height: 16px;
    padding: 0;
    accent-color: var(--accent);
}

.agenda-reminder-box .is-disabled {
    color: var(--text-soft);
}

.agenda-reminder-box span {
    color: var(--text-soft);
    font-size: .78rem;
}

.agenda-modal-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-top: 1px solid var(--border-soft);
    padding-top: 16px;
}

.agenda-modal-actions > div {
    display: flex;
    gap: 10px;
}

.agenda-diagnostic-panel {
    width: min(940px, 100%);
}

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

.agenda-diagnostic-card {
    display: grid;
    gap: 8px;
    min-width: 0;
    padding: 14px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: color-mix(in srgb, var(--accent) 4%, var(--surface));
}

.agenda-diagnostic-full {
    grid-column: 1 / -1;
}

.agenda-diagnostic-card small {
    color: var(--accent);
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.agenda-diagnostic-card strong {
    color: var(--text);
}

.agenda-diagnostic-card span,
.agenda-diagnostic-card p,
.agenda-diagnostic-card em {
    margin: 0;
    color: var(--text-muted);
    font-size: .86rem;
    font-style: normal;
}

.agenda-diagnostic-card code {
    display: block;
    min-width: 0;
    padding: 10px;
    overflow-wrap: anywhere;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: var(--surface);
    color: var(--text);
    font-size: .82rem;
}

.agenda-diagnostic-card article {
    display: grid;
    gap: 4px;
    padding-top: 8px;
    border-top: 1px solid var(--border-soft);
}

.agenda-diagnostic-card article:first-of-type {
    padding-top: 0;
    border-top: 0;
}

.agenda-diagnostic-actions form {
    margin: 0;
}

@media (max-width: 1100px) {
    .communication-page-head,
    .communication-card-hero,
    .communication-test-form {
        grid-template-columns: 1fr;
    }

    .communication-kpis,
    .communication-kpis-four,
    .communication-kpis-five,
    .communication-grid,
    .communication-grid-four,
    .communication-template-grid,
    .communication-health-grid,
    .communication-health-grid-four,
    .communication-history-list article {
        grid-template-columns: 1fr;
    }

    .communication-card-hero em {
        justify-self: start;
    }

    .agenda-page-head,
    .agenda-section-head,
    .agenda-layout,
    .agenda-list-filters {
        grid-template-columns: 1fr;
    }

    .agenda-section-head {
        padding-right: 0;
    }

    .agenda-period-actions {
        position: static;
        justify-content: flex-start;
    }

    .agenda-actions {
        justify-content: flex-start;
    }

    .agenda-view-switch {
        width: 100%;
        overflow-x: auto;
    }

    .agenda-view-switch a {
        flex: 1 0 auto;
        text-align: center;
    }

    .agenda-month-grid {
        grid-template-columns: repeat(7, minmax(118px, 1fr));
    }

    .agenda-side {
        grid-template-columns: 1fr;
    }

    .agenda-modal {
        align-items: start;
        padding: 14px 14px calc(14px + env(safe-area-inset-bottom));
    }

    .agenda-modal-panel {
        max-height: calc(100vh - 28px);
        max-height: calc(100dvh - 28px - env(safe-area-inset-bottom));
        padding: 18px;
    }

    .agenda-modal-head,
    .agenda-modal-form,
    .agenda-modal-actions {
        grid-template-columns: 1fr;
    }

    .agenda-modal-actions {
        display: grid;
        justify-items: stretch;
        position: sticky;
        bottom: -18px;
        z-index: 3;
        margin: 0 -18px -18px;
        padding: 14px 18px calc(18px + env(safe-area-inset-bottom));
        background: var(--surface);
        box-shadow: 0 -12px 24px color-mix(in srgb, var(--text) 10%, transparent);
    }

    .agenda-modal-actions > div {
        display: grid;
        gap: 10px;
    }

    .agenda-modal-actions .button {
        width: 100%;
        justify-content: center;
    }

    .agenda-diagnostic-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    .agenda-week-grid {
        display: none;
    }

    .agenda-week-mobile-list {
        display: grid;
        gap: 10px;
    }

    .agenda-week-mobile-day {
        position: relative;
        display: grid;
        gap: 10px;
        border: 1px solid var(--border-soft);
        border-radius: 8px;
        background: var(--surface);
        padding: 12px;
    }

    .agenda-week-mobile-day:hover,
    .agenda-week-mobile-day:focus-within {
        border-color: color-mix(in srgb, var(--accent) 38%, var(--border));
        background: color-mix(in srgb, var(--accent) 4%, #fff);
    }

    .agenda-week-mobile-day.is-today {
        background: color-mix(in srgb, var(--accent) 7%, #fff);
        border-color: #05a7b5;
        box-shadow: inset 0 0 0 1px #05a7b5;
    }

    .agenda-week-mobile-day header {
        position: relative;
        z-index: 1;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
    }

    .agenda-week-mobile-day header strong {
        color: var(--text);
        font-size: .9rem;
    }

    .agenda-week-mobile-day header span {
        color: var(--text-muted);
        font-weight: 800;
    }

    .agenda-week-mobile-day > div {
        position: relative;
        z-index: 1;
        display: grid;
        gap: 8px;
    }

    .agenda-week-mobile-day p {
        margin: 0;
        color: var(--text-soft);
        font-weight: 800;
    }
}

@media (max-width: 760px) {
    .communication-shell,
    .communication-shell > *,
    .communication-page-head > *,
    .communication-card > *,
    .communication-card-hero > *,
    .communication-form > *,
    .communication-inner-panel > *,
    .communication-template-grid > *,
    .communication-health-grid > *,
    .communication-history-list > * {
        min-width: 0;
        max-width: 100%;
    }

    .communication-shell {
        width: 100%;
        overflow-x: clip;
        gap: 14px;
    }

    .communication-page-head {
        gap: 15px;
        padding: 18px 16px;
    }

    .communication-page-head h1 {
        font-size: clamp(1.75rem, 9vw, 2.1rem);
        line-height: 1.08;
        overflow-wrap: anywhere;
    }

    .communication-page-head p,
    .communication-card-hero p,
    .communication-foundation-note p,
    .communication-template-note,
    .communication-history-note {
        overflow-wrap: anywhere;
    }

    .communication-kpis article,
    .communication-balance-kpi {
        min-width: 0;
        width: 100%;
    }

    .communication-balance-kpi > div {
        align-items: center;
        flex-wrap: wrap;
    }

    .communication-balance-kpi p {
        max-width: none;
        min-width: 0;
    }

    .communication-card {
        width: 100%;
        padding: 12px;
        overflow: hidden;
    }

    .communication-card-hero {
        gap: 12px;
        padding: 14px;
        overflow: hidden;
    }

    .communication-card-hero h2 {
        font-size: 1.45rem;
        line-height: 1.12;
        overflow-wrap: anywhere;
    }

    .communication-card-hero em {
        max-width: 100%;
        justify-self: start;
        white-space: normal;
    }

    .communication-form,
    .communication-grid,
    .communication-template-grid,
    .communication-health-grid {
        width: 100%;
    }

    .communication-form label,
    .communication-form input,
    .communication-form select,
    .communication-form textarea {
        min-width: 0;
        max-width: 100%;
    }

    .communication-secret {
        width: 100%;
        max-width: none;
    }

    .communication-inner-panel {
        width: 100%;
        padding: 11px;
        overflow: hidden;
    }

    .communication-section-head {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        align-items: start;
        justify-items: start;
        gap: 12px;
    }

    .communication-section-head > div,
    .communication-template-head-actions {
        width: 100%;
        min-width: 0;
    }

    .communication-template-head-actions {
        justify-content: flex-start;
    }

    .communication-template-head-actions > span,
    .communication-template-head-actions > a,
    .communication-section-head > a {
        width: fit-content;
        max-width: 100%;
        white-space: normal;
        text-align: center;
    }

    .communication-template-grid label {
        min-width: 0;
        overflow: hidden;
        padding: 12px;
    }

    .communication-template-grid small,
    .communication-template-grid code,
    .communication-template-grid b {
        min-width: 0;
        overflow-wrap: anywhere;
        word-break: break-word;
    }

    .communication-real-send-gate {
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 12px;
        padding: 14px;
    }

    .communication-health-grid article {
        min-width: 0;
        padding: 12px;
    }

    .communication-health-grid strong,
    .communication-health-grid small {
        min-width: 0;
        overflow-wrap: anywhere;
    }

    .communication-actions {
        width: 100%;
    }

    .communication-actions .button {
        width: 100%;
        justify-content: center;
        white-space: normal;
    }

    .communication-history-list article {
        gap: 10px;
        padding: 12px;
    }

    .communication-history-state {
        justify-content: flex-start;
    }

    .communication-history-state span,
    .communication-history-state button {
        max-width: 100%;
        white-space: normal;
        text-align: center;
    }
}

[data-theme="light-executive"] {
    --page-bg: #f4f7fb;
    --surface: #ffffff;
    --surface-strong: #edf3f8;
    --border: rgba(32, 107, 137, .25);
    --border-soft: rgba(35, 65, 83, .12);
    --text: #172b3a;
    --text-muted: #516779;
    --text-soft: #748596;
    --accent: #166985;
    --accent-strong: #145b72;
    --success: #157a52;
    --warning: #9c6a00;
    --danger: #b94141;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    background: var(--page-bg);
    color: var(--text);
    font-family: Arial, sans-serif;
    scrollbar-color: var(--accent-strong) var(--surface);
    scrollbar-width: thin;
}

* {
    scrollbar-color: var(--accent-strong) var(--surface);
    scrollbar-width: thin;
}

::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--surface);
}

::-webkit-scrollbar-thumb {
    border: 2px solid var(--surface);
    border-radius: 999px;
    background: var(--accent-strong);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent);
}

::-webkit-scrollbar-corner {
    background: var(--surface);
}

main {
    width: min(1120px, calc(100% - 48px));
    margin: 48px auto;
}

.main-form {
    width: min(560px, calc(100% - 48px));
}

.main-form-wide {
    width: min(860px, calc(100% - 48px));
}

a {
    color: var(--accent);
}

h1 {
    margin-bottom: 6px;
    color: var(--accent);
}

h2 {
    margin-top: 30px;
    color: var(--text);
}

p {
    color: var(--text-muted);
    line-height: 1.5;
}

.app-shell {
    width: min(1120px, calc(100% - 48px));
    margin: 48px auto;
}

.app-shell-narrow {
    width: min(680px, calc(100% - 48px));
}

.page-header {
    display: grid;
    gap: 12px;
    margin-bottom: 22px;
}

.back-link {
    width: fit-content;
    color: var(--text-muted);
    text-decoration: none;
}

.back-link:hover {
    color: var(--accent);
}

.page-title {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 14px 20px;
}

.page-title h1 {
    margin: 0;
}

.page-subtitle {
    margin: 0;
    color: var(--text-muted);
}

.action-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 18px 0;
}

.form-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-top: 22px;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th,
td {
    padding: 14px 16px;
    border-bottom: 1px solid var(--border-soft);
    text-align: left;
    vertical-align: top;
}

th {
    color: var(--accent);
    font-size: .86rem;
    text-transform: uppercase;
}

td {
    color: var(--text);
}

tbody tr:last-child td {
    border-bottom: 0;
}

.request-operational-table tbody tr:last-child td {
    border-bottom: 1px solid var(--border);
}

.table-wrap tbody tr {
    transition: background-color .15s ease;
}

.table-wrap tbody tr:hover {
    background: rgba(16, 243, 239, .035);
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 15px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--accent-strong);
    color: #fff;
    text-decoration: none;
    cursor: pointer;
    line-height: 1.15;
}

.button:hover,
.button:focus {
    border-color: var(--accent);
}

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

.button-secondary {
    background: var(--surface);
    color: var(--accent);
}

.button-edit {
    border-color: color-mix(in srgb, var(--warning) 58%, var(--surface));
    background: color-mix(in srgb, var(--warning) 7%, var(--surface));
    color: var(--warning);
    font-weight: 700;
    transition: border-color .16s ease, background-color .16s ease, color .16s ease, box-shadow .16s ease;
}

.button-edit:hover,
.button-edit:focus-visible {
    border-color: var(--warning);
    background: color-mix(in srgb, var(--warning) 14%, var(--surface));
    color: color-mix(in srgb, var(--warning) 82%, var(--text));
    box-shadow: 0 7px 16px color-mix(in srgb, var(--warning) 13%, transparent);
}

.button-success {
    border-color: rgba(128, 245, 204, .55);
    background: #116c58;
    color: #fff;
}

.button-warning {
    border-color: rgba(255, 209, 102, .65);
    background: #5f4a16;
    color: var(--warning);
}

.button-danger {
    border-color: rgba(220, 38, 38, .28);
    background: #fff;
    color: #dc2626;
}

.button-danger:hover,
.button-danger:focus {
    border-color: rgba(220, 38, 38, .45);
    background: rgba(254, 242, 242, .95);
    color: #b91c1c;
    box-shadow: 0 10px 22px rgba(220, 38, 38, .12);
}

.button-small {
    min-height: 36px;
    padding: 8px 12px;
    font-size: .9rem;
}

.button-small.button-proposal-start {
    min-height: 34px;
    padding: 7px 13px;
    border-color: #7ed9ff;
    background: #e8fbff;
    color: #075f85;
}

.button-small.button-proposal-start:hover,
.button-small.button-proposal-start:focus {
    border-color: #2ebff0;
    background: #d6f6ff;
    color: #064f70;
}

.inline-action-form {
    display: contents;
}

.button:disabled,
.button[aria-disabled="true"] {
    border-color: var(--border-soft);
    background: var(--surface);
    color: var(--text-soft);
    cursor: not-allowed;
}

.form-card {
    padding: 24px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
}

.form-card label {
    display: grid;
    gap: 7px;
    margin-top: 16px;
    color: var(--text-muted);
}

.form-card label:first-child {
    margin-top: 0;
}

.form-card input,
.form-card select {
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 12px;
    background: #fff;
    color: var(--text);
}

.form-card input[readonly] {
    color: var(--text-soft);
    cursor: not-allowed;
}

.password-field {
    position: relative;
    display: block;
}

.password-field input {
    width: 100%;
    padding-right: 92px;
}

.password-toggle {
    position: absolute;
    top: 50%;
    right: 8px;
    width: auto;
    min-width: 70px;
    margin: 0;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 7px 9px;
    background: var(--surface-strong);
    color: var(--accent);
    font-size: .78rem;
    line-height: 1;
    cursor: pointer;
    transform: translateY(-50%);
}

.password-toggle:hover,
.password-toggle:focus {
    border-color: var(--border);
}

.form-card button {
    margin-top: 22px;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 12px 16px;
    background: var(--accent-strong);
    color: #fff;
    cursor: pointer;
}

.form-card .form-actions button,
.form-card .form-actions .button {
    margin-top: 0;
}

.form-card .button-secondary {
    background: var(--surface);
    color: var(--accent);
}

.form-card .button-success {
    border-color: rgba(128, 245, 204, .55);
    background: #116c58;
    color: #fff;
}

.form-card .button-warning {
    border-color: rgba(255, 209, 102, .65);
    background: #5f4a16;
    color: var(--warning);
}

.form-card .button-danger {
    border-color: rgba(255, 155, 155, .65);
    background: #5a1f2a;
    color: var(--danger);
}

.form-card .password-toggle {
    width: auto;
    min-width: 70px;
    margin: 0;
    border-color: var(--border-soft);
    padding: 7px 9px;
    background: var(--surface-strong);
    color: var(--accent);
    font-size: .78rem;
    line-height: 1;
}

.choice-list label {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 4px 12px;
    padding: 13px 0;
    border-bottom: 1px solid var(--border-soft);
    color: var(--text);
}

.choice-list label:last-of-type {
    border-bottom: 0;
}

.choice-list input {
    margin-top: 3px;
}

.choice-list small {
    color: var(--text-soft);
}

.table-wrap {
    overflow-x: auto;
    margin-top: 24px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    scrollbar-color: var(--accent) var(--surface-strong);
}

.table-wrap th,
.table-wrap td {
    white-space: nowrap;
}

.table-wrap::-webkit-scrollbar-track {
    border-radius: 0 0 8px 8px;
    background: var(--surface-strong);
}

.table-wrap::-webkit-scrollbar-thumb {
    border-color: var(--surface-strong);
    background: var(--accent);
}

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

.table-medium {
    min-width: 760px;
}

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

.list-toolbar {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
    margin-top: 20px;
    padding: 14px 16px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: var(--surface);
    color: var(--text-muted);
}

.filter-toolbar {
    display: grid;
    grid-template-columns: minmax(220px, 1.35fr) repeat(auto-fit, minmax(150px, 1fr));
    align-items: end;
    gap: 14px 12px;
    margin-top: 20px;
    padding: 14px 16px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: var(--surface);
    color: var(--text-muted);
}

.filter-toolbar label {
    display: grid;
    gap: 7px;
    min-width: 0;
}

.filter-toolbar input,
.filter-toolbar select {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 11px 12px;
    background: var(--page-bg);
    color: var(--text);
}

.filter-toolbar .button {
    min-width: 112px;
    padding-right: 14px;
    padding-left: 14px;
    text-align: center;
}

.list-toolbar form,
.pagination form {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
}

.list-toolbar select {
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 10px;
    background: var(--page-bg);
    color: var(--text);
}

.pagination {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 18px;
    color: var(--text-muted);
}

.pagination .summary {
    margin-right: auto;
    color: var(--text-soft);
}

.pagination a,
.pagination button {
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 10px 13px;
    background: var(--surface);
    color: var(--accent);
    text-decoration: none;
}

.pagination .disabled {
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 10px 13px;
    color: var(--text-soft);
}

.pagination input {
    width: 72px;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 10px;
    background: var(--page-bg);
    color: var(--text);
    text-align: center;
    appearance: textfield;
}

.pagination input::-webkit-outer-spin-button,
.pagination input::-webkit-inner-spin-button {
    margin: 0;
    appearance: none;
}

.inline-form {
    display: inline;
}

.inline-form button {
    margin-left: 8px;
    border: 0;
    padding: 0;
    background: transparent;
    color: var(--accent);
    text-decoration: underline;
    cursor: pointer;
}

.table-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    margin: 2px 4px 2px 0;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 7px 10px;
    background: var(--surface-strong);
    color: var(--accent);
    font-size: .9rem;
    line-height: 1;
    text-decoration: none;
    cursor: pointer;
    white-space: nowrap;
}

.table-action:hover,
.table-action:focus {
    border-color: var(--accent);
    color: var(--text);
}

.table-action-warning {
    border-color: rgba(255, 209, 102, .55);
    color: var(--warning);
}

.table-action-danger {
    border-color: rgba(255, 155, 155, .55);
    color: var(--danger);
}

.inline-form .table-action {
    margin-left: 0;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 7px 10px;
    background: var(--surface-strong);
    text-decoration: none;
}

.inline-form .table-action-warning {
    border-color: rgba(255, 209, 102, .55);
    color: var(--warning);
}

.table-actions {
    display: flex;
    flex-wrap: nowrap;
    gap: 6px;
    align-items: center;
}

.table-actions .table-action {
    min-width: 86px;
}

.muted {
    color: var(--text-soft);
}

.empty {
    padding: 28px 16px;
    border: 1px dashed var(--border);
    border-radius: 8px;
    background: var(--surface);
    color: var(--text-muted);
}

.notice {
    color: var(--success);
}

.warning {
    color: var(--warning);
}

.error {
    color: var(--danger);
}

.alert {
    margin: 14px 0;
    padding: 12px 14px;
    border: 1px solid currentColor;
    border-radius: 8px;
    background: #fff;
}

.toast-stack {
    position: fixed;
    top: 88px;
    right: 18px;
    z-index: 80;
    display: grid;
    gap: 10px;
    width: min(420px, calc(100% - 36px));
}

.toast-message {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: start;
    gap: 12px;
    padding: 14px 14px 14px 16px;
    border: 1px solid currentColor;
    border-radius: 8px;
    background: var(--surface);
    box-shadow: 0 16px 44px rgba(0, 0, 0, .28);
}

.toast-message p {
    margin: 0;
    color: currentColor;
}

.toast-message button {
    width: 28px;
    height: 28px;
    border: 1px solid currentColor;
    border-radius: 999px;
    background: transparent;
    color: currentColor;
    cursor: pointer;
    line-height: 1;
}

.toast-message--leaving {
    opacity: 0;
    transform: translateY(-6px);
    transition: opacity .2s ease, transform .2s ease;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 4px 9px;
    border: 1px solid currentColor;
    border-radius: 999px;
    font-size: .86rem;
    line-height: 1;
    white-space: nowrap;
}

.status-success {
    color: var(--success);
}

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

.status-danger,
.status-muted {
    color: var(--text-soft);
}

.summary {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 28px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    color: var(--text-muted);
}

.summary strong {
    color: var(--accent);
}

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

.confirm-modal[hidden] {
    display: none;
}

.confirm-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, .58);
}

.confirm-modal__panel {
    position: relative;
    z-index: 1;
    width: min(500px, 100%);
    padding: 26px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: 0 20px 70px rgba(0, 0, 0, .35);
}

.confirm-modal__panel h2 {
    margin: 0 0 10px;
}

.confirm-modal__panel p {
    margin: 0;
}

.confirm-modal__details {
    display: grid;
    gap: 8px;
    margin: 18px 0 0;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: color-mix(in srgb, var(--surface-muted) 72%, var(--surface));
}

.confirm-modal__details[hidden] {
    display: none;
}

.confirm-modal__details div {
    display: grid;
    grid-template-columns: 124px minmax(0, 1fr);
    gap: 12px;
    align-items: start;
}

.confirm-modal__details-separator {
    margin-top: 4px;
    padding-top: 10px;
    border-top: 1px solid color-mix(in srgb, var(--border) 72%, var(--accent));
}

.confirm-modal__details dt {
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .02em;
    text-transform: uppercase;
    color: var(--accent);
}

.confirm-modal__details dd {
    min-width: 0;
    margin: 0;
    overflow-wrap: anywhere;
    color: var(--text);
    font-weight: 700;
}

.confirm-modal__actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 22px;
}

.home-panel {
    padding: 32px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
}

.authenticated-layout {
    display: block;
    min-height: 100vh;
}

.authenticated-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 20;
    display: flex;
    flex-direction: column;
    width: 260px;
    height: 100vh;
    padding: 16px 18px;
    border-right: 1px solid var(--border-soft);
    background: var(--surface);
    overflow: hidden;
}

.authenticated-sidebar__header,
.topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.brand-link,
.topbar-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--text);
    text-decoration: none;
}

.brand-link strong,
.topbar-brand > span:last-child {
    display: block;
    color: var(--text);
    font-weight: 700;
}

.brand-link small {
    display: block;
    margin-top: 2px;
    color: var(--text-soft);
}

.brand-mark {
    width: 30px;
    height: 30px;
    border: 3px solid var(--accent);
    border-radius: 8px;
    background: linear-gradient(135deg, rgba(36, 122, 88, .22), rgba(183, 121, 31, .16));
    transform: rotate(32deg);
}

.sidebar-close {
    display: none;
}

.sidebar-nav {
    flex: 1 1 auto;
    min-height: 0;
    display: grid;
    align-content: start;
    gap: 5px;
    margin-top: 26px;
    overflow-x: hidden;
    overflow-y: auto;
    padding-right: 4px;
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.sidebar-nav::-webkit-scrollbar {
    width: 0;
    height: 0;
}

.sidebar-group {
    display: grid;
    gap: 5px;
}

.sidebar-label {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    margin: 12px 0 2px;
    border: 0;
    background: transparent;
    color: var(--text-soft);
    font: inherit;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .08em;
    padding: 5px 4px;
    text-align: left;
    text-transform: uppercase;
    cursor: pointer;
}

.sidebar-label span {
    min-width: 0;
    flex: 1 1 auto;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sidebar-label em {
    width: 8px;
    height: 8px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg) translateY(-2px);
    transition: transform .18s ease;
}

.sidebar-group.is-open .sidebar-label em {
    transform: rotate(225deg) translateY(-1px);
}

.sidebar-label:hover,
.sidebar-label:focus-visible {
    color: var(--text-muted);
}

.sidebar-section-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 22px;
    min-height: 20px;
    border: 1px solid rgba(14, 165, 183, .35);
    border-radius: 999px;
    padding: 2px 6px;
    background: #e7faff;
    color: var(--accent);
    font-size: .68rem;
    letter-spacing: 0;
    line-height: 1;
}

.sidebar-group__items {
    display: grid;
    gap: 5px;
}

.sidebar-group__items[hidden] {
    display: none;
}

.sidebar-nav a,
.shortcut-link {
    position: relative;
    display: flex;
    align-items: center;
    gap: 11px;
    min-height: 42px;
    border: 1px solid transparent;
    border-radius: 8px;
    padding: 10px 12px;
    color: var(--text-muted);
    text-decoration: none;
    max-width: 100%;
}

.sidebar-nav a {
    width: calc(100% - 5px);
}

.sidebar-nav a span:last-child {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sidebar-nav a > span:nth-child(2) {
    min-width: 0;
    flex: 1 1 auto;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sidebar-nav-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    min-height: 22px;
    border: 1px solid rgba(14, 165, 183, .35);
    border-radius: 999px;
    padding: 2px 7px;
    background: #e7faff;
    color: var(--accent);
    font-size: .72rem;
    font-weight: 900;
    line-height: 1;
}

.sidebar-nav a:hover,
.sidebar-nav a:focus,
.sidebar-nav a.is-active,
.shortcut-link:hover,
.shortcut-link:focus {
    border-color: var(--border);
    background: var(--surface-strong);
    color: var(--text);
}

.sidebar-nav a.is-disabled,
.shortcut-link.is-disabled {
    color: var(--text-soft);
    cursor: default;
}

.sidebar-nav a.is-disabled:hover,
.sidebar-nav a.is-disabled:focus,
.shortcut-link.is-disabled:hover,
.shortcut-link.is-disabled:focus {
    border-color: transparent;
    background: transparent;
    color: var(--text-soft);
}

.nav-icon {
    display: inline-grid;
    place-items: center;
    width: 24px;
    height: 24px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    color: var(--accent);
    font-size: .78rem;
    font-weight: 700;
}

.sidebar-user {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 10px;
    align-items: center;
    margin-top: auto;
    padding-top: 14px;
    border-top: 1px solid var(--border-soft);
}

.sidebar-user strong,
.sidebar-user small {
    display: block;
}

.sidebar-user small {
    margin-top: 3px;
    color: var(--text-soft);
}

.user-avatar {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 999px;
    background: var(--accent-strong);
    color: #fff;
    font-weight: 700;
}

.sidebar-logout {
    margin-top: 10px;
}

.sidebar-logout .button {
    width: 100%;
    text-align: center;
}

.authenticated-main {
    min-width: 0;
    margin-left: 260px;
}

.topbar {
    display: flex;
    align-items: center;
    gap: 16px;
    min-height: 74px;
    padding: 12px 28px;
    border-bottom: 1px solid var(--border-soft);
    background: var(--surface);
}

.topbar-brand {
    display: none;
}

.topbar-context {
    display: grid;
    min-width: 0;
}

.topbar-context strong {
    min-width: 0;
    color: var(--text);
    font-size: 1.18rem;
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.topbar-account {
    position: relative;
    margin-left: auto;
}

.topbar-user {
    display: flex;
    align-items: center;
    gap: 10px;
    border: 0;
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
    font: inherit;
    padding: 6px 8px;
    border-radius: 8px;
}

.topbar-user:hover,
.topbar-user:focus {
    outline: none;
    background: #f0f7fb;
    box-shadow: 0 0 0 1px var(--border);
}

.topbar-user strong,
.topbar-user small {
    display: block;
    line-height: 1.2;
}

.topbar-user strong {
    color: var(--text);
    font-size: .9rem;
}

.topbar-user small {
    margin-top: 2px;
    color: var(--text-soft);
    font-size: .78rem;
}

.topbar-avatar {
    display: inline-grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 999px;
    background: var(--accent);
    color: #fff;
    font-size: .86rem;
    font-weight: 800;
}

.account-menu {
    position: absolute;
    z-index: 40;
    top: calc(100% + 10px);
    right: 0;
    width: min(320px, calc(100vw - 24px));
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 20px 46px rgba(15, 23, 42, .16);
}

.account-menu[hidden] {
    display: none;
}

.account-menu header {
    display: flex;
    gap: 10px;
    align-items: center;
    padding-bottom: 12px;
    border-bottom: 1px solid #d7e3ec;
}

.account-menu header strong,
.account-menu header small {
    display: block;
    overflow-wrap: anywhere;
}

.account-menu header small {
    margin-top: 2px;
    color: var(--text-muted);
    font-size: .78rem;
}

.account-menu dl {
    display: grid;
    gap: 10px;
    margin: 12px 0;
}

.account-menu dl div {
    display: grid;
    gap: 3px;
}

.account-menu dt {
    color: #005b78;
    font-size: .72rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.account-menu dd {
    margin: 0;
    color: var(--text);
    font-weight: 800;
}

.account-menu-actions {
    display: grid;
    grid-template-columns: 1fr 90px;
    gap: 8px;
}

.account-menu-actions form {
    margin: 0;
}

.account-menu-actions .button {
    width: 100%;
}

.account-password-shell {
    background: #eef5fb;
}

.account-password-page {
    display: grid;
    gap: 18px;
}

.account-password-head,
.account-password-card {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.account-password-head {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: flex-start;
    padding: 22px;
}

.account-password-head span {
    color: #005b78;
    font-size: .76rem;
    font-weight: 900;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.account-password-head h1 {
    margin: 7px 0 6px;
    color: var(--text);
}

.account-password-head p,
.account-password-card p {
    margin: 0;
    color: var(--text-muted);
}

.account-password-card {
    display: grid;
    gap: 16px;
    padding: 22px;
}

.account-password-card label {
    display: grid;
    gap: 7px;
    color: var(--text);
    font-weight: 900;
}

.account-password-card input {
    width: 100%;
}

.account-password-card .password-field input {
    min-height: 44px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    padding: 0 96px 0 12px;
    font: inherit;
    font-weight: 700;
}

.account-password-card .password-field input:focus {
    outline: none;
    border-color: #1b93aa;
    box-shadow: 0 0 0 2px rgba(27, 147, 170, .14);
}

.account-password-card .password-toggle {
    right: 8px;
    min-height: 30px;
    border-color: #c9dbe5;
    background: #eef6f9;
}

.account-password-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.menu-toggle,
.sidebar-close {
    width: 44px;
    height: 44px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface-strong);
    color: var(--accent);
    cursor: pointer;
}

.menu-toggle {
    display: none;
    gap: 5px;
    place-items: center;
    padding: 10px;
}

.menu-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    background: currentColor;
}

.app-content.dashboard-shell {
    display: flex;
    flex-direction: column;
    width: min(1440px, calc(100% - 40px));
    margin: 26px auto 0;
    min-height: calc(100vh - 100px);
}

.app-content {
    width: min(1440px, calc(100% - 56px));
    margin: 36px auto 48px;
}

.app-content.main-form {
    width: min(560px, calc(100% - 56px));
}

.app-content.main-form-wide {
    width: min(860px, calc(100% - 56px));
}

.app-content.users-shell {
    width: min(1480px, calc(100% - 36px));
}

.users-shell .page-title-actions {
    margin: 0;
}

.users-shell .user-id-col,
.users-shell .user-id-cell {
    width: 54px;
    color: var(--text-muted);
    font-size: .78rem;
    white-space: nowrap;
}

.users-shell .table-actions {
    flex-wrap: nowrap;
}

.user-edit-id {
    margin-left: 8px;
    vertical-align: middle;
}

.dashboard-hero,
.dashboard-actions {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(500px, .9fr);
    gap: 20px;
    align-items: stretch;
    padding: 20px 26px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
}

.dashboard-hero h1,
.dashboard-actions h2 {
    margin: 0;
    color: var(--accent);
}

.dashboard-hero h1 {
    font-size: 1.9rem;
    line-height: 1.05;
}

.dashboard-hero p,
.dashboard-actions p {
    margin-bottom: 0;
}

.mobile-title {
    display: none;
}

.dashboard-context {
    display: grid;
    grid-template-columns: minmax(120px, .7fr) minmax(230px, 1.2fr) minmax(120px, .75fr);
    gap: 9px 12px;
    margin: 0;
}

.context-item {
    min-width: 0;
    padding: 0 0 8px;
    border-bottom: 1px solid var(--border-soft);
}

.context-item-database {
    grid-column: span 2;
}

.dashboard-context .context-item:nth-last-child(-n + 2) {
    border-bottom: 0;
}

.dashboard-context dt {
    color: var(--accent);
    font-size: .72rem;
    font-weight: 700;
    text-transform: uppercase;
}

.dashboard-context dd {
    margin: 4px 0 0;
    color: var(--text);
    overflow-wrap: break-word;
}

.context-item-email dd {
    font-size: .94rem;
    line-height: 1.25;
    word-break: normal;
    overflow-wrap: anywhere;
}

.dashboard-context dd small {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 6px;
    margin-top: 3px;
    color: var(--text-soft);
    line-height: 1.25;
}

.context-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    width: fit-content;
    min-height: 22px;
    border: 1px solid rgba(36, 122, 88, .22);
    border-radius: 999px;
    padding: 2px 8px;
    background: rgba(36, 122, 88, .08);
    color: var(--success);
    font-size: .9rem;
}

.context-status::before {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: var(--success);
}

.context-pill {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    min-height: 20px;
    border: 1px solid rgba(23, 101, 118, .2);
    border-radius: 999px;
    padding: 2px 7px;
    background: var(--surface-strong);
    color: var(--accent);
    font-size: .78rem;
    line-height: 1;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    margin-top: 14px;
}

.metric-card {
    min-height: 128px;
    padding: 16px 20px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: var(--surface);
}

.metric-card h2 {
    margin: 12px 0 6px;
    color: var(--text);
    font-size: 1.45rem;
}

.metric-card p {
    margin: 0;
}

.metric-card small {
    display: block;
    margin-top: 9px;
    color: var(--text-soft);
    line-height: 1.4;
}

.dashboard-actions {
    grid-template-columns: minmax(300px, .72fr) minmax(0, 1.28fr);
    margin-top: 14px;
    align-items: center;
}

.shortcut-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 7px 10px;
    align-content: start;
}

.shortcut-link {
    align-items: center;
    min-height: 48px;
    padding: 7px 9px;
    border-color: var(--border-soft);
    background: rgba(238, 244, 246, .42);
}

.shortcut-link-copy {
    min-width: 0;
    flex: 1 1 auto;
}

.shortcut-link strong,
.shortcut-link small {
    display: block;
}

.shortcut-link small {
    margin-top: 2px;
    color: var(--text-soft);
    font-size: .78rem;
    line-height: 1.18;
}

.shortcut-link strong {
    color: var(--text-muted);
    font-size: .93rem;
    line-height: 1.1;
}

.shortcut-link.has-alert {
    border-color: rgba(245, 158, 11, .68);
    background: rgba(255, 251, 235, .48);
}

.shortcut-link.has-alert:hover,
.shortcut-link.has-alert:focus {
    border-color: rgba(217, 119, 6, .82);
    background: rgba(255, 247, 237, .72);
}

.shortcut-alert-badge {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    min-height: 22px;
    border: 1px solid rgba(217, 119, 6, .34);
    border-radius: 999px;
    padding: 2px 7px;
    background: #fff7ed;
    color: #b45309;
    font-size: .72rem;
    font-weight: 900;
    line-height: 1;
}

.dashboard-notes {
    display: none;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    margin-top: 18px;
}

.dashboard-notes article {
    padding: 20px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: var(--surface);
}

.dashboard-notes h2 {
    margin: 0 0 8px;
    color: var(--text);
    font-size: 1rem;
}

.dashboard-notes p {
    margin: 0;
}

.dashboard-tech-footer {
    display: flex;
    flex-wrap: nowrap;
    align-items: stretch;
    width: min(1280px, 100%);
    margin: auto auto 0;
    border: 1px solid var(--border);
    border-radius: 8px 8px 0 0;
    background: var(--surface);
    box-shadow: var(--shadow-soft);
    overflow: hidden;
}

.dashboard-tech-footer span {
    display: inline-flex;
    flex: 0 1 auto;
    align-items: center;
    gap: 6px;
    min-width: 0;
    min-height: 34px;
    padding: 7px 12px;
    border-right: 1px solid var(--border-soft);
    color: var(--text-muted);
    font-size: .78rem;
    line-height: 1.2;
    white-space: nowrap;
}

.dashboard-tech-key {
    margin-left: auto;
}

.dashboard-tech-footer span:last-child {
    border-right: 0;
}

.dashboard-tech-footer strong {
    color: var(--accent-strong);
    font-size: .7rem;
    text-transform: uppercase;
}

.dashboard-tech-footer em {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    min-height: 20px;
    border: 1px solid rgba(23, 101, 118, .18);
    border-radius: 999px;
    padding: 2px 7px;
    background: var(--surface-strong);
    color: var(--accent);
    font-size: .72rem;
    font-style: normal;
    line-height: 1;
}

.dashboard-tech-footer em.is-local {
    border-color: rgba(36, 122, 88, .22);
    background: rgba(36, 122, 88, .08);
    color: var(--success);
}

.dashboard-tech-footer em.is-online {
    border-color: rgba(37, 99, 235, .2);
    background: rgba(37, 99, 235, .08);
    color: #2563eb;
}

.trainings-shell {
    width: min(1500px, calc(100% - 40px));
    margin: 22px auto 30px;
}

.training-filter-panel {
    display: grid;
    grid-template-columns: minmax(150px, .75fr) minmax(170px, .8fr) minmax(170px, .8fr) minmax(280px, 1.35fr) auto auto;
    gap: 12px;
    align-items: end;
    margin-bottom: 18px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
}

.training-filter-panel label,
.training-form-grid label {
    display: grid;
    gap: 7px;
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 700;
}

.training-filter-panel input,
.training-filter-panel select,
.training-form-grid input,
.training-form-grid select,
.training-form-grid textarea {
    width: 100%;
    min-height: 38px;
    border: 1px solid var(--border);
    border-radius: 7px;
    padding: 8px 10px;
    background: #fff;
    color: var(--text);
}

.training-form-grid input[readonly] {
    background: #f7fbfc;
    color: var(--text-muted);
}

.training-workspace {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    align-items: start;
}

.training-list-card,
.training-detail-card {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    overflow: hidden;
}

.training-list-card {
    padding: 18px;
}

.training-list-card .panel-inline-head {
    margin-bottom: 14px;
}

.training-table-wrap {
    border: 1px solid var(--border-soft);
    border-radius: 8px;
}

.training-table {
    min-width: 1040px;
}

.training-table th,
.training-table td {
    padding: 12px 10px;
    vertical-align: middle;
}

.training-table tbody tr {
    border-left: 4px solid transparent;
    background: #fff;
    transition: background-color .15s ease, border-color .15s ease;
}

.training-table tbody tr:hover {
    border-left-color: rgba(23, 101, 118, .38);
    background: #f4fbfd;
}

.training-table tbody tr.is-selected-row {
    border-left-color: var(--accent);
    background: #eaf8fb;
}

.training-table .training-empty-row {
    padding: 28px 16px;
    color: var(--text-muted);
    font-weight: 700;
    text-align: center;
}

.training-progress {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    border: 1px solid rgba(37, 99, 235, .18);
    border-radius: 999px;
    padding: 5px 11px;
    background: rgba(37, 99, 235, .08);
    color: #0b63ff;
    font-size: .82rem;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
}

.training-progress.is-overdue {
    border-color: rgba(220, 38, 38, .2);
    background: rgba(220, 38, 38, .08);
    color: #dc2626;
}

.training-progress.is-today {
    border-color: rgba(37, 99, 235, .18);
    background: rgba(37, 99, 235, .08);
    color: #0b63ff;
}

.training-progress.is-upcoming {
    border-color: rgba(36, 122, 88, .2);
    background: rgba(36, 122, 88, .08);
    color: var(--success);
}

.training-author-cell strong,
.training-author-cell small {
    display: block;
}

.training-author-cell strong {
    color: var(--text);
    font-size: .9rem;
    line-height: 1.2;
}

.training-author-cell small {
    margin-top: 2px;
    color: var(--text-muted);
    font-size: .76rem;
    line-height: 1.2;
}

.training-status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 26px;
    border-radius: 999px;
    padding: 5px 10px;
    font-size: .74rem;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
}

.training-status-badge.is-active-status {
    border: 1px solid rgba(36, 122, 88, .24);
    background: rgba(36, 122, 88, .1);
    color: var(--success);
}

.training-status-badge.is-inactive-status {
    border: 1px solid rgba(100, 116, 139, .2);
    background: rgba(100, 116, 139, .08);
    color: var(--text-muted);
}

.training-table-actions {
    display: flex;
    flex-wrap: nowrap;
    gap: 6px;
}

.training-record-head {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    border-bottom: 1px solid var(--border-soft);
}

.training-detail-card {
    max-width: 1180px;
    margin: 0 auto;
}

.training-form-card {
    max-width: none;
}

.training-form-shell {
    width: min(1180px, calc(100% - 40px));
}

.training-record-head h2 {
    margin: 4px 0 2px;
    color: var(--text);
    font-size: 1.35rem;
}

.training-record-head p {
    margin: 0;
    color: var(--text-muted);
}

.training-detail-section {
    position: relative;
    padding: 18px;
    border-bottom: 1px solid var(--border-soft);
}

.training-detail-section::before {
    content: "";
    position: absolute;
    left: 0;
    top: 18px;
    bottom: 18px;
    width: 4px;
    border-radius: 0 999px 999px 0;
    background: rgba(23, 101, 118, .32);
}

.training-section-client::before {
    background: #14b8a6;
}

.training-section-schedule::before {
    background: #2563eb;
}

.training-section-control::before {
    background: #f59e0b;
}

.training-section-notes::before {
    background: #64748b;
}

.training-section-email::before {
    background: #0e7490;
}

.training-detail-section:last-child {
    border-bottom: 0;
}

.training-detail-section h3 {
    margin: 0 0 14px;
    color: var(--accent);
    font-size: .9rem;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.training-section-note {
    margin: -8px 0 14px;
    color: var(--text-muted);
    font-size: .86rem;
}

.training-rule-note {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: -4px 0 14px;
    padding: 11px 12px;
    border: 1px solid rgba(37, 99, 235, .16);
    border-radius: 8px;
    background: rgba(37, 99, 235, .05);
    color: var(--text-muted);
    font-size: .84rem;
}

.training-rule-note strong {
    color: var(--accent);
    font-size: .78rem;
    letter-spacing: .06em;
    text-transform: uppercase;
    white-space: nowrap;
}

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

.training-wide-field {
    grid-column: span 2;
}

.training-client-search-action {
    display: flex;
    align-items: end;
}

.training-client-search-action .button {
    width: 100%;
    min-height: 38px;
}

.training-selected-client {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 82px;
    border: 1px solid rgba(23, 101, 118, .22);
    border-left: 4px solid var(--accent);
    border-radius: 8px;
    padding: 14px 16px;
    background: #f4fbfd;
}

.training-selected-client div {
    display: grid;
    gap: 4px;
    min-width: 0;
}

.training-selected-client span {
    color: var(--accent);
    font-size: .74rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.training-selected-client strong {
    color: var(--text);
    font-size: 1.08rem;
    line-height: 1.2;
}

.training-selected-client small {
    color: var(--text-muted);
    font-size: .82rem;
    overflow-wrap: anywhere;
}

.training-client-results {
    grid-column: 1 / -1;
    display: grid;
    gap: 10px;
    padding: 12px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: #f8fcfd;
}

.training-client-results-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.training-client-results-head strong {
    color: var(--accent);
    font-size: .78rem;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.training-client-results-head span,
.training-client-empty {
    color: var(--text-muted);
    font-size: .82rem;
}

.training-client-empty {
    margin: 0;
}

.training-client-options {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.training-client-option {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    min-height: 62px;
    border: 1px solid var(--border-soft);
    border-left: 4px solid transparent;
    border-radius: 8px;
    padding: 10px 12px;
    background: #fff;
    color: var(--text);
    text-decoration: none;
    transition: border-color .15s ease, background-color .15s ease, transform .15s ease;
}

.training-client-option:hover,
.training-client-option:focus-visible {
    border-left-color: rgba(23, 101, 118, .45);
    background: #f4fbfd;
    transform: translateY(-1px);
}

.training-client-option.is-selected-client {
    border-color: rgba(23, 101, 118, .25);
    border-left-color: var(--accent);
    background: #eaf8fb;
}

.training-client-pick {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border: 1px solid rgba(23, 101, 118, .18);
    border-radius: 8px;
    background: #fff;
    color: var(--accent);
    font-weight: 900;
    line-height: 1;
    justify-self: end;
}

.training-client-option.is-selected-client .training-client-pick {
    border-color: rgba(36, 122, 88, .22);
    background: rgba(36, 122, 88, .1);
    color: var(--success);
    font-size: .7rem;
}

.training-client-text {
    display: grid;
    gap: 3px;
    min-width: 0;
}

.training-client-text strong,
.training-client-text small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.training-client-text strong {
    color: var(--text);
    font-size: .9rem;
}

.training-client-text small {
    color: var(--text-muted);
    font-size: .78rem;
}

.training-full-field {
    grid-column: 1 / -1;
}

.training-form-grid textarea {
    min-height: 96px;
    resize: vertical;
}

.training-email-preview {
    display: grid;
    gap: 10px;
    padding: 14px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: #f8fcfd;
}

.training-email-preview strong {
    color: var(--text);
}

.training-email-preview p {
    margin: 0;
    color: var(--text-muted);
    line-height: 1.4;
}

.training-email-preview .button {
    width: fit-content;
}

.training-form-footer-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    padding: 16px 18px;
    border-top: 1px solid var(--border-soft);
    background: #fff;
}

.training-modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: grid;
    place-items: center;
    padding: 18px;
    background: rgba(15, 23, 42, .46);
}

.training-mini-modal,
.training-quick-client-modal {
    width: min(420px, 100%);
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 22px 55px rgba(15, 23, 42, .22);
}

.training-mini-modal {
    padding: 24px;
    text-align: center;
}

.training-mini-modal h2,
.training-quick-client-modal h2 {
    margin: 0;
    color: var(--text);
    font-size: 1.05rem;
}

.training-mini-modal p {
    margin: 8px 0 18px;
    color: var(--text-muted);
}

.training-modal-actions {
    display: flex;
    justify-content: center;
    gap: 8px;
}

.training-quick-client-modal {
    width: min(760px, 100%);
    overflow: hidden;
}

.training-quick-client-modal header,
.training-quick-client-modal footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
    background: #f8fafc;
}

.training-quick-client-modal header {
    border-bottom: 1px solid var(--border-soft);
}

.training-quick-client-modal footer {
    justify-content: flex-end;
    border-top: 1px solid var(--border-soft);
}

.training-quick-client-modal header a {
    color: var(--text-muted);
    font-size: 1rem;
    font-weight: 800;
    text-decoration: none;
}

.training-quick-client-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    padding: 16px;
}

.training-quick-client-grid label {
    display: grid;
    gap: 6px;
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 700;
}

.training-quick-client-grid input,
.training-quick-client-grid select {
    min-height: 38px;
    border: 1px solid var(--border);
    border-radius: 7px;
    padding: 8px 10px;
    background: #fff;
    color: var(--text);
}

.training-quick-client-grid small,
.training-quick-client-alert {
    color: #dc2626;
    font-size: .78rem;
}

.training-quick-client-wide {
    grid-column: 1 / -1;
}

.training-quick-client-alert {
    margin: 14px 16px 0;
    border: 1px solid rgba(220, 38, 38, .18);
    border-radius: 8px;
    padding: 10px 12px;
    background: rgba(220, 38, 38, .06);
    font-weight: 700;
}

.clients-shell,
.categories-shell {
    width: min(1440px, calc(100% - 40px));
    margin: 22px auto 28px;
}

@media (min-width: 761px) {
    .authenticated-layout-clients .clients-shell,
    .authenticated-layout-clients .categories-shell,
    .authenticated-layout-clients .locations-shell {
        margin-top: 22px;
    }
}

.clients-header {
    margin-bottom: 18px;
}

.clients-header .eyebrow {
    margin: 0 0 6px;
    color: var(--accent);
    font-size: .76rem;
    font-weight: 800;
    letter-spacing: .1em;
}

.clients-header .page-title {
    align-items: center;
}

.clients-header h1 {
    margin: 0;
}

.category-page-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
}

.category-page-header .page-actions {
    margin-top: 24px;
}

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

.client-summary-strip article {
    display: grid;
    align-content: center;
    gap: 7px;
    min-height: 96px;
    padding: 16px 18px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: var(--surface);
}

.client-summary-strip span {
    color: var(--text-muted);
    font-size: .82rem;
    font-weight: 700;
    text-transform: uppercase;
}

.client-summary-strip strong {
    color: var(--accent);
    font-size: 1.62rem;
    line-height: 1;
}

.client-summary-strip small {
    color: var(--text-muted);
    font-size: .78rem;
    line-height: 1.2;
}

.category-record-head {
    align-items: center;
    padding: 22px 24px;
}

.category-record-head > em,
.record-head-badges > em {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 26px;
    border-radius: 999px;
    padding: 5px 10px;
    font-size: .74rem;
    font-style: normal;
    font-weight: 800;
    line-height: 1;
}

.category-detail-panel .client-section {
    padding: 24px;
}

.category-detail-panel .category-guidance {
    margin-top: 0;
    margin-bottom: 18px;
    padding: 16px 18px;
}

.record-head-badges {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 8px;
    margin-left: auto;
}

.record-id-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 26px;
    border: 1px solid var(--border-soft);
    border-radius: 999px;
    padding: 5px 10px;
    background: #fff;
    color: var(--text-muted);
    font-size: .72rem;
    font-weight: 900;
    letter-spacing: .02em;
}

.category-detail-panel .category-field-grid {
    grid-template-columns: minmax(0, 1fr);
    max-width: 720px;
}

.suppliers-shell .category-detail-panel .category-field-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: none;
}

.suppliers-shell .category-detail-panel .category-field-grid .wide {
    grid-column: 1 / -1;
}

.category-detail-panel .category-field-grid textarea {
    min-height: 136px;
}

.rentals-shell .category-detail-panel .rental-property-form .category-field-grid,
.rentals-shell .category-detail-panel .rental-document-form .category-field-grid {
    grid-template-columns: repeat(12, minmax(0, 1fr));
    max-width: none;
    gap: 14px;
}

.rental-property-form .rental-span-1,
.rental-document-form .rental-span-1 {
    grid-column: span 1;
}

.rental-property-form .rental-span-2,
.rental-document-form .rental-span-2 {
    grid-column: span 2;
}

.rental-property-form .rental-span-3,
.rental-document-form .rental-span-3 {
    grid-column: span 3;
}

.rental-property-form .rental-span-4,
.rental-document-form .rental-span-4 {
    grid-column: span 4;
}

.rental-property-form .rental-span-5,
.rental-document-form .rental-span-5 {
    grid-column: span 5;
}

.rental-property-form .rental-span-6,
.rental-document-form .rental-span-6 {
    grid-column: span 6;
}

.rental-property-form .rental-span-8,
.rental-document-form .rental-span-8 {
    grid-column: span 8;
}

.rental-property-form .rental-span-9,
.rental-document-form .rental-span-9 {
    grid-column: span 9;
}

.rental-property-form .rental-span-10,
.rental-document-form .rental-span-10 {
    grid-column: span 10;
}

.rental-property-form .rental-span-12,
.rental-document-form .rental-span-12 {
    grid-column: 1 / -1;
}

.rentals-shell .rental-notes-grid {
    margin-bottom: 4px;
}

.rentals-shell .rental-notes-grid textarea {
    min-height: 124px;
}

.rentals-shell .rental-property-form {
    gap: 16px;
}

.rentals-shell .rental-form-section {
    display: grid;
    gap: 14px;
    margin: 0;
    padding: 18px;
    border: 1px solid var(--border-soft);
    border-radius: 9px;
    background: #fbfdfe;
}

.rentals-shell .rental-form-section-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
}

.rentals-shell .rental-form-section-head .client-section-label {
    margin: 0;
}

.rentals-shell .rental-form-section-head > span {
    color: var(--text-muted);
    font-size: .82rem;
    text-align: right;
}

.rentals-shell .rental-form-section .category-guidance {
    margin: 0;
}

.rentals-shell .rental-availability-option {
    display: flex;
    align-items: center;
    flex-direction: row;
    gap: 10px;
    min-height: 48px;
    padding: 9px 12px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: #fff;
}

.rentals-shell .rental-availability-option input {
    width: 18px;
    height: 18px;
    margin: 0;
}

.rentals-shell .rental-availability-option span {
    display: grid;
    gap: 2px;
}

.rentals-shell .rental-availability-option small {
    color: var(--text-muted);
    font-weight: 500;
}

.rentals-shell .rental-property-documents {
    margin-top: 20px;
}

.rentals-shell .rental-document-form {
    padding: 0;
}

.rentals-shell .rental-document-submit {
    display: flex;
    align-items: end;
}

.rentals-shell .rental-document-submit .button {
    width: 100%;
}

.rentals-shell .rental-document-list {
    margin-top: 2px;
}

.rentals-shell .rental-tenant-tabs {
    display: flex;
    gap: 8px;
    padding: 0 24px;
    border-bottom: 1px solid var(--border-soft);
    background: #fff;
}

.rentals-shell .rental-tenant-tabs a {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 14px 16px 12px;
    border-bottom: 3px solid transparent;
    color: var(--text-muted);
    font-size: .86rem;
    font-weight: 850;
    text-decoration: none;
}

.rentals-shell .rental-tenant-tabs a.is-active {
    border-bottom-color: var(--accent);
    color: var(--accent);
}

.rentals-shell .rental-tenant-tabs a.is-disabled {
    cursor: not-allowed;
    opacity: .48;
}

.rentals-shell .rental-tenant-tabs b {
    min-width: 22px;
    padding: 3px 6px;
    border-radius: 999px;
    background: #e6f5f7;
    text-align: center;
}

.rentals-shell .rental-guarantor-toolbar {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 14px;
}

.rentals-shell .rental-link-guarantor-form {
    display: flex;
    align-items: end;
    gap: 10px;
}

.rentals-shell .rental-link-guarantor-form label {
    display: grid;
    gap: 6px;
    min-width: 300px;
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 800;
}

.rentals-shell .rental-link-guarantor-form select {
    min-height: 42px;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 0 12px;
    background: #fff;
    font: inherit;
}

.rentals-shell .rental-guarantor-editor {
    padding: 16px;
    border: 1px solid #bcdce1;
    border-radius: 9px;
    background: #f4fbfc;
}

.rentals-shell .rental-guarantor-editor-heading {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin-bottom: 14px;
    color: var(--text-muted);
}

.rentals-shell .rental-guarantor-editor-heading strong {
    color: var(--text);
}

.rentals-shell .rental-guarantor-groups {
    display: grid;
    gap: 14px;
}

.rentals-shell .rental-guarantor-group {
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.rentals-shell .rental-guarantor-group-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 12px;
}

.rentals-shell .rental-guarantor-group-head .client-section-label {
    margin: 0;
}

.rentals-shell .rental-guarantor-group-head > span {
    color: var(--text-muted);
    font-size: .78rem;
    text-align: right;
}

.rentals-shell .rental-guarantor-notes-start {
    grid-column: 1 / span 6;
}

.rentals-shell .rental-guarantor-editor-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 14px;
}

.rentals-shell .rental-guarantor-list {
    display: grid;
    gap: 10px;
}

.rentals-shell .rental-tenant-document-form {
    margin-bottom: 16px;
}

.rentals-shell .rental-document-owner-groups {
    display: grid;
    gap: 14px;
}

.rentals-shell .rental-document-owner-group {
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 9px;
    background: #fff;
}

.rentals-shell .rental-document-owner-group > header,
.rentals-shell .rental-document-owner-group > header > div {
    display: flex;
    align-items: center;
    gap: 10px;
}

.rentals-shell .rental-document-owner-group > header {
    justify-content: space-between;
    margin-bottom: 10px;
}

.rentals-shell .rental-document-owner-group > header strong,
.rentals-shell .rental-document-owner-group > header small {
    display: block;
}

.rentals-shell .rental-document-owner-group > header small {
    margin-top: 2px;
    color: var(--text-muted);
}

.rentals-shell .rental-document-owner-group > header b {
    min-width: 26px;
    padding: 4px 8px;
    border-radius: 999px;
    background: #e6f5f7;
    color: var(--accent-strong);
    text-align: center;
}

.rentals-shell .rental-document-expiry.is-expired {
    color: var(--danger);
    font-weight: 800;
}

.rentals-shell .rental-document-expiry.is-soon {
    color: #9a6700;
    font-weight: 800;
}

.rentals-shell .rental-guarantor-editing-note {
    margin: 0;
    padding: 12px 14px;
    border: 1px dashed var(--border);
    border-radius: 8px;
    background: #fff;
}

.rentals-shell .rental-table-secondary {
    display: block;
    margin-top: 4px;
    color: var(--text-muted);
}

.rentals-shell .rental-form-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: 18px;
    padding-top: 18px;
    border-top: 1px solid var(--border-soft);
}

.rentals-shell .rental-form-footer-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
}

.rentals-shell .rental-table-wrap {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    -webkit-overflow-scrolling: touch;
}

.rentals-shell .rental-property-filter {
    grid-template-columns: minmax(220px, 1.3fr) 120px minmax(140px, .8fr) 130px 160px auto auto;
}

.rentals-shell .rental-property-table {
    width: 100%;
    min-width: 1080px;
}

.rentals-shell .rental-property-table th:nth-child(2),
.rentals-shell .rental-property-table td:nth-child(2) {
    min-width: 300px;
    width: 30%;
}

.rentals-shell .rental-property-table th:nth-child(5),
.rentals-shell .rental-property-table td:nth-child(5) {
    min-width: 135px;
    white-space: nowrap;
}

.rentals-shell .rental-table-wrap:focus-visible {
    outline: 2px solid rgba(23, 101, 118, .45);
    outline-offset: -2px;
}

.rentals-shell .rental-property-row td {
    transition: background-color .16s ease, box-shadow .16s ease;
}

.rentals-shell .rental-property-row:hover td,
.rentals-shell .rental-property-row:focus-within td {
    background: #eef8fb;
}

.rentals-shell .rental-property-row:hover td:first-child,
.rentals-shell .rental-property-row:focus-within td:first-child {
    box-shadow: inset 4px 0 0 rgba(23, 101, 118, .46);
}

.rental-property-name-link {
    display: block;
    color: var(--text);
    font-weight: 800;
    text-decoration: none;
}

.rental-property-name-link:hover,
.rental-property-name-link:focus {
    color: var(--accent);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.rental-property-address {
    display: block;
    margin-top: 3px;
    color: var(--text-muted);
    line-height: 1.35;
}

.rental-property-tenant {
    display: block;
    margin-top: 4px;
    color: #526779;
    font-size: .82rem;
    line-height: 1.35;
}

.rental-property-tenant strong {
    color: #17324d;
    font-weight: 700;
}

.rentals-shell .status-badge.is-rented {
    border-color: #8ddac1;
    background: #e9f8f2;
    color: #087457;
}

.rentals-shell .status-badge.is-vacant {
    border-color: #cbd7df;
    background: #f4f7f9;
    color: #526779;
}

.rentals-shell .status-badge.is-contracting {
    border-color: #f0c982;
    background: #fff5df;
    color: #9a5800;
}

.rental-pagination-footer {
    border-top: 1px solid var(--border-soft);
    padding: 0 16px 16px;
}

.rental-pagination {
    margin-top: 14px;
}

.rental-pagination form {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.rental-pagination .button-small {
    min-height: 42px;
}

@media screen and (max-width: 1100px) {
    .rentals-shell .rental-property-filter {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .rentals-shell .category-detail-panel .rental-property-form .category-field-grid,
    .rentals-shell .category-detail-panel .rental-document-form .category-field-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .rental-property-form .rental-span-1,
    .rental-property-form .rental-span-2,
    .rental-property-form .rental-span-3,
    .rental-property-form .rental-span-4,
    .rental-property-form .rental-span-5,
    .rental-property-form .rental-span-6,
    .rental-property-form .rental-span-8,
    .rental-property-form .rental-span-9,
    .rental-property-form .rental-span-10,
    .rental-document-form .rental-span-1,
    .rental-document-form .rental-span-2,
    .rental-document-form .rental-span-3,
    .rental-document-form .rental-span-4,
    .rental-document-form .rental-span-5,
    .rental-document-form .rental-span-6,
    .rental-document-form .rental-span-8,
    .rental-document-form .rental-span-9,
    .rental-document-form .rental-span-10 {
        grid-column: span 1;
    }

    .rental-property-form .rental-span-12,
    .rental-document-form .rental-span-12 {
        grid-column: 1 / -1;
    }

    .rental-pagination {
        justify-content: flex-start;
    }

    .rental-pagination .summary {
        flex-basis: 100%;
    }
}

@media screen and (max-width: 680px) {
    .rentals-shell .rental-property-filter {
        grid-template-columns: minmax(0, 1fr);
    }

    .rentals-shell .category-detail-panel .rental-property-form .category-field-grid,
    .rentals-shell .category-detail-panel .rental-document-form .category-field-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .rental-property-form .rental-span-12,
    .rental-document-form .rental-span-12 {
        grid-column: auto;
    }

    .rentals-shell .rental-form-section {
        padding: 14px;
    }

    .rentals-shell .rental-form-section-head {
        align-items: flex-start;
        flex-direction: column;
        gap: 5px;
    }

    .rentals-shell .rental-form-section-head > span {
        text-align: left;
    }

    .rentals-shell .rental-form-footer {
        align-items: stretch;
        flex-direction: column-reverse;
    }

    .rentals-shell .rental-form-footer-actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .rentals-shell .rental-form-footer-actions .button,
    .rentals-shell .rental-form-footer > div:first-child .button {
        width: 100%;
    }

    .rentals-shell .rental-table-wrap {
        display: block;
    }

    .rentals-shell .rental-tenant-tabs {
        display: grid;
        grid-template-columns: 1fr;
        padding: 0 14px;
    }

    .rentals-shell .rental-tenant-tabs a {
        justify-content: center;
    }

    .rentals-shell .rental-guarantor-toolbar,
    .rentals-shell .rental-link-guarantor-form {
        align-items: stretch;
        flex-direction: column;
    }

    .rentals-shell .rental-link-guarantor-form label {
        min-width: 0;
    }

    .rentals-shell .rental-guarantor-editor-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 3px;
    }

    .rentals-shell .rental-guarantor-group {
        padding: 14px;
    }

    .rentals-shell .rental-guarantor-group-head {
        flex-direction: column;
        gap: 5px;
    }

    .rentals-shell .rental-guarantor-group-head > span {
        text-align: left;
    }
}

.category-module-options {
    display: grid;
    gap: 10px;
    padding: 14px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: #f8fcfd;
}

.category-module-options legend {
    padding: 0 6px;
    color: var(--text-muted);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.category-module-options label {
    display: flex;
    align-items: center;
    flex-direction: row;
    gap: 8px;
    min-height: auto;
    font-weight: 700;
}

.category-module-options input {
    width: 16px;
    height: 16px;
}

.knowledge-base-workspace {
    align-items: start;
}

.knowledge-base-search {
    display: grid;
    gap: 12px;
    margin-bottom: 14px;
}

.knowledge-base-search .button {
    width: fit-content;
    min-height: 40px;
}

.knowledge-base-directory .client-filter-pills {
    margin-bottom: 14px;
}

.knowledge-base-directory .client-directory-list {
    gap: 10px;
}

.knowledge-base-directory .client-directory-item {
    align-items: center;
    gap: 12px;
    min-height: 126px;
    padding: 14px 12px;
}

.knowledge-base-directory .client-directory-item > span:nth-child(2) {
    gap: 6px;
}

.knowledge-base-directory .client-directory-item em {
    margin-left: 4px;
}

.knowledge-base-directory .client-directory-item small {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.knowledge-base-field-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.knowledge-base-field-grid .knowledge-base-field-full {
    grid-column: 1 / -1;
}

.knowledge-base-field-grid textarea {
    min-height: 92px;
    resize: vertical;
}

.knowledge-base-field-grid textarea:focus {
    outline: 2px solid rgba(9, 127, 151, .16);
    border-color: var(--brand);
}

.knowledge-base-editor-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    margin-top: 18px;
}

.knowledge-base-editor .request-editor-surface {
    min-height: 220px;
}

.knowledge-base-reader {
    display: grid;
    gap: 16px;
}

.knowledge-base-reader-summary,
.knowledge-base-reader-facts,
.knowledge-base-reader-grid > section {
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: #fff;
}

.knowledge-base-reader-summary {
    padding: 18px;
    background: #f8fcfd;
}

.knowledge-base-reader-summary span,
.knowledge-base-reader-facts strong,
.knowledge-base-reader-grid h3 > span {
    color: var(--brand-strong);
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.knowledge-base-reader-summary p {
    margin: 8px 0 0;
    color: var(--text);
    font-size: 1rem;
    line-height: 1.55;
}

.knowledge-base-reader-facts {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0;
    overflow: hidden;
}

.knowledge-base-reader-facts span {
    display: grid;
    gap: 6px;
    min-width: 0;
    padding: 14px 16px;
    border-right: 1px solid var(--border-soft);
    color: var(--text);
    font-weight: 800;
    overflow-wrap: anywhere;
}

.knowledge-base-reader-facts span:last-child {
    border-right: 0;
}

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

.knowledge-base-reader-grid > section {
    overflow: hidden;
}

.knowledge-base-reader-grid h3 {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 0;
    padding: 14px 16px;
    border-bottom: 1px solid var(--border-soft);
    background: #eefcff;
}

.knowledge-base-reader-grid h3 > span {
    min-width: 0;
    overflow-wrap: anywhere;
}

.knowledge-base-reader-grid h3 .button {
    flex: 0 0 auto;
    min-height: 32px;
    white-space: nowrap;
}

.knowledge-base-reader-body {
    min-height: 260px;
    padding: 18px;
    color: var(--text);
    font-weight: 700;
    line-height: 1.58;
    overflow-wrap: anywhere;
}

.knowledge-base-reader-body p:first-child,
.knowledge-base-reader-body ol:first-child,
.knowledge-base-reader-body ul:first-child {
    margin-top: 0;
}

.knowledge-base-reader-body img {
    max-width: 100%;
    height: auto;
}

.knowledge-search-mark {
    border-radius: 4px;
    background: #fff2a8;
    color: var(--text);
    box-shadow: 0 0 0 2px #fff2a8;
}

.knowledge-base-inline-image {
    margin: 12px 0;
}

.knowledge-base-inline-image img {
    display: block;
    max-width: 100%;
    height: auto;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    box-shadow: 0 10px 24px rgba(15, 63, 104, .1);
}

.knowledge-base-inline-image.is-selected img {
    outline: 3px solid rgba(25, 196, 223, .34);
    outline-offset: 3px;
}

.knowledge-image-toolbar {
    position: absolute;
    z-index: 90;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 14px 34px rgba(15, 23, 42, .18);
}

.knowledge-image-toolbar[hidden] {
    display: none;
}

.knowledge-image-toolbar span {
    color: var(--text-muted);
    font-size: .74rem;
    font-weight: 900;
    text-transform: uppercase;
}

.knowledge-image-toolbar button {
    min-height: 28px;
    padding: 0 10px;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: #f8fcfd;
    color: var(--brand-strong);
    cursor: pointer;
    font-size: .78rem;
    font-weight: 900;
}

.knowledge-image-toolbar button:hover,
.knowledge-image-toolbar button:focus {
    border-color: var(--brand);
    background: #eefcff;
}

.knowledge-base-assets {
    display: grid;
    grid-template-columns: minmax(160px, .7fr) minmax(240px, 1.4fr) minmax(160px, .7fr);
    gap: 12px;
    margin-top: 18px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 14px;
    background: #f8fcfd;
}

.knowledge-base-assets > div {
    display: grid;
    align-content: center;
    gap: 4px;
    min-height: 72px;
}

.knowledge-base-assets strong {
    color: var(--text);
    font-size: .9rem;
}

.knowledge-base-cleanup-form {
    margin: 4px 0 0;
}

.knowledge-base-assets span,
.knowledge-base-assets small {
    color: var(--text-muted);
    font-size: .8rem;
    line-height: 1.45;
}

.knowledge-base-dropzone {
    justify-items: center;
    border: 1px dashed var(--border);
    border-radius: 8px;
    padding: 14px;
    background: #fff;
    text-align: center;
    transition: border-color .16s ease, background .16s ease, box-shadow .16s ease;
}

.knowledge-base-dropzone.is-dragging {
    border-color: var(--brand);
    background: #eefcff;
    box-shadow: inset 0 0 0 1px rgba(9, 127, 151, .14);
}

.knowledge-base-dropzone b {
    color: var(--brand-strong);
    font-size: .9rem;
}

.knowledge-base-dropzone .button {
    margin-top: 6px;
}

.knowledge-base-dropzone small.is-error {
    color: var(--danger);
    font-weight: 700;
}

.knowledge-base-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 20px;
    margin-bottom: 16px;
    padding: 10px 0 14px;
    border-bottom: 1px solid var(--border-soft);
    color: var(--text-muted);
    font-size: .82rem;
}

.knowledge-base-meta span {
    border: 1px solid var(--border-soft);
    border-radius: 999px;
    padding: 8px 12px;
    background: #fff;
    line-height: 1.25;
}

.knowledge-base-actions .button[disabled] {
    cursor: not-allowed;
    opacity: .58;
}

.is-draft-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #f3d38c;
    border-radius: 999px;
    padding: 5px 9px;
    background: #fff7db;
    color: #8a5a00;
    font-size: .72rem;
    font-style: normal;
    font-weight: 800;
}

@media (max-width: 920px) {
    .knowledge-base-field-grid,
    .knowledge-base-editor-grid,
    .knowledge-base-reader-grid,
    .knowledge-base-reader-facts,
    .knowledge-base-assets {
        grid-template-columns: 1fr;
    }

    .knowledge-base-reader-facts span {
        border-right: 0;
        border-bottom: 1px solid var(--border-soft);
    }

    .knowledge-base-reader-facts span:last-child {
        border-bottom: 0;
    }

    .knowledge-base-reader-grid h3 {
        align-items: stretch;
        gap: 10px;
    }

    .knowledge-base-reader-grid h3 .button {
        width: 100%;
        min-width: 0;
    }

    .knowledge-base-assets {
        align-items: stretch;
    }
}

.category-form-actions {
    margin: 18px 0 0;
    padding-top: 18px;
}

.ready-response-summary article:nth-child(2) {
    background: linear-gradient(135deg, #ffffff 0%, #effcf7 100%);
}

.ready-response-summary article:nth-child(3) {
    background: linear-gradient(135deg, #ffffff 0%, #fff7e8 100%);
}

.ready-response-summary article:nth-child(4) {
    background: linear-gradient(135deg, #ffffff 0%, #f4f0ff 100%);
}

.ready-response-workspace {
    grid-template-columns: minmax(310px, 390px) minmax(0, 1fr);
}

.ready-response-search {
    display: grid;
    gap: 10px;
}

.ready-response-search select {
    width: 100%;
    min-height: 40px;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 10px 38px 10px 12px;
    background:
        linear-gradient(45deg, transparent 50%, var(--accent) 50%) calc(100% - 18px) 17px / 6px 6px no-repeat,
        linear-gradient(135deg, var(--accent) 50%, transparent 50%) calc(100% - 13px) 17px / 6px 6px no-repeat,
        #fff;
    color: var(--text);
    font: inherit;
    appearance: none;
}

.ready-response-search select:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(8, 145, 178, .12);
    outline: none;
}

.ready-response-item small {
    line-height: 1.35;
}

.ready-response-field-grid {
    grid-template-columns: minmax(0, 1.4fr) minmax(180px, .35fr) minmax(160px, .3fr);
}

.ready-response-body-field,
.ready-response-notes-field {
    grid-column: 1 / -1;
}

.ready-response-area-guidance {
    grid-column: 2 / -1;
    display: grid;
    align-content: center;
    gap: 5px;
    min-height: 74px;
    padding: 12px 14px;
    border: 1px solid #b9dfea;
    border-radius: 8px;
    background: #f1fbfd;
    color: var(--text-muted);
    font-size: .82rem;
    line-height: 1.4;
}

.ready-response-area-guidance strong {
    color: var(--brand-strong);
    font-size: .84rem;
}

.ready-response-area-guidance b {
    color: var(--text);
}

.ready-response-editor .request-editor-surface {
    min-height: 260px;
    line-height: 1.65;
}

.ready-response-notes-field textarea {
    min-height: 110px;
}

.ready-response-reader {
    display: grid;
    gap: 16px;
}

.ready-response-reader-facts,
.ready-response-reader-card,
.ready-response-reader-note {
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: #fff;
}

.ready-response-reader-facts {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    overflow: hidden;
}

.ready-response-reader-facts span {
    display: grid;
    gap: 6px;
    min-width: 0;
    padding: 14px 16px;
    border-right: 1px solid var(--border-soft);
    color: var(--text);
    font-weight: 800;
    overflow-wrap: anywhere;
}

.ready-response-reader-facts span:last-child {
    border-right: 0;
}

.ready-response-reader-facts strong,
.ready-response-reader-card header span,
.ready-response-reader-note span {
    color: var(--brand-strong);
    font-size: .78rem;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.ready-response-reader-card {
    overflow: hidden;
}

.ready-response-reader-card header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
    border-bottom: 1px solid var(--border-soft);
    background: #eefcff;
}

.ready-response-reader-card header .button {
    min-height: 32px;
}

.ready-response-reader-body {
    min-height: 260px;
    padding: 18px;
    color: var(--text);
    font-weight: 700;
    line-height: 1.65;
    overflow-wrap: anywhere;
}

.ready-response-reader-body p:first-child,
.ready-response-reader-body ol:first-child,
.ready-response-reader-body ul:first-child {
    margin-top: 0;
}

.ready-response-reader-note {
    padding: 14px 16px;
    background: #f8fcfd;
}

.ready-response-reader-note p {
    margin: 8px 0 0;
    color: var(--text-muted);
    line-height: 1.5;
}

.internal-messages-shell {
    max-width: 1440px;
}

.internal-message-summary article:nth-child(2) {
    background: linear-gradient(135deg, #ffffff 0%, #fff8e6 100%);
}

.internal-message-summary article:nth-child(3) {
    background: linear-gradient(135deg, #ffffff 0%, #eef8ff 100%);
}

.internal-message-summary article:nth-child(4) {
    background: linear-gradient(135deg, #ffffff 0%, #fff1f2 100%);
}

.internal-message-item.is-unread strong {
    font-weight: 900;
}

.internal-message-field-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.internal-message-body-field,
.internal-message-alerts {
    grid-column: 1 / -1;
}

.internal-message-alerts {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 12px 14px;
    background: rgba(10, 208, 239, .08);
}

.internal-message-alerts legend {
    padding: 0 6px;
    color: var(--accent);
    font-size: .76rem;
    font-weight: 900;
    text-transform: uppercase;
}

.internal-message-alerts label {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--text);
    font-size: .88rem;
    font-weight: 800;
}

.internal-message-editor .request-editor-surface {
    min-height: 260px;
}

.internal-message-reader-card {
    margin-top: 18px;
}

.internal-message-reader-card header small {
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 800;
}

.internal-message-facts {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.internal-message-thread {
    display: grid;
    gap: 12px;
    margin-top: 18px;
}

.internal-message-thread h3 {
    margin: 0;
    color: var(--accent);
    font-size: .88rem;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.internal-message-thread article {
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 14px 16px;
    background: #fff;
}

.internal-message-thread article strong,
.internal-message-thread article small {
    display: block;
}

.internal-message-thread article small {
    margin-top: 3px;
    color: var(--text-muted);
    font-size: .76rem;
}

.internal-message-thread article div {
    margin-top: 12px;
    color: var(--text);
    line-height: 1.65;
}

.ready-response-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 22px 0 10px;
    color: var(--muted);
    font-size: .86rem;
}

.ready-response-meta span {
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 8px 10px;
    background: #f8fbfd;
}

@media (max-width: 920px) {
    .ready-response-field-grid,
    .ready-response-reader-facts {
        grid-template-columns: 1fr;
    }

    .ready-response-reader-facts span {
        border-right: 0;
        border-bottom: 1px solid var(--border-soft);
    }

    .ready-response-reader-facts span:last-child {
        border-bottom: 0;
    }

    .ready-response-area-guidance {
        grid-column: 1 / -1;
    }

    .ready-response-reader-card header {
        align-items: stretch;
    }

    .ready-response-reader-card header .button {
        width: 100%;
    }
}

.communication-history-shell {
    max-width: 1440px;
}

.communication-history-header {
    margin-top: 20px;
    margin-bottom: 22px;
}

.communication-history-summary article:nth-child(2) {
    background: linear-gradient(135deg, #ffffff 0%, #eef8ff 100%);
}

.communication-history-summary article:nth-child(3) {
    background: linear-gradient(135deg, #ffffff 0%, #f4f0ff 100%);
}

.communication-history-summary article:nth-child(4) {
    background: linear-gradient(135deg, #ffffff 0%, #fff7e8 100%);
}

.communication-history-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0 0 16px;
}

.communication-history-tabs a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 38px;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 8px 14px;
    background: #fff;
    color: var(--accent);
    font-weight: 900;
    text-decoration: none;
}

.communication-history-tabs a.is-active {
    border-color: var(--accent);
    background: var(--accent);
    color: #fff;
}

.communication-history-tabs span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    min-height: 24px;
    border-radius: 999px;
    background: rgba(8, 145, 178, .12);
    font-size: .78rem;
}

.communication-history-tabs a.is-active span {
    background: rgba(255, 255, 255, .2);
}

.communication-history-layout {
    display: block;
}

.communication-history-main {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow-sm);
}

.communication-history-main {
    overflow: hidden;
}

.communication-history-filter {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 220px;
    gap: 12px;
    padding: 16px;
    border-bottom: 1px solid var(--border-soft);
}

.communication-history-filter label {
    display: grid;
    gap: 6px;
    color: var(--text-muted);
    font-size: .82rem;
}

.communication-history-filter input,
.communication-history-filter select {
    width: 100%;
    min-height: 42px;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 10px 12px;
    background: #fff;
    color: var(--text);
    font: inherit;
}

.communication-history-filter select {
    padding-right: 38px;
    background:
        linear-gradient(45deg, transparent 50%, var(--accent) 50%) calc(100% - 18px) 18px / 6px 6px no-repeat,
        linear-gradient(135deg, var(--accent) 50%, transparent 50%) calc(100% - 13px) 18px / 6px 6px no-repeat,
        #fff;
    appearance: none;
}

.communication-history-filter input:focus,
.communication-history-filter select:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(8, 145, 178, .12);
    outline: none;
}

.communication-history-table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-color: color-mix(in srgb, var(--accent) 55%, #9aa9b4) #edf3f6;
    scrollbar-width: thin;
}

.communication-history-table-wrap.is-all-channels {
    height: clamp(360px, calc(100vh - 430px), 620px);
    overflow: auto;
    scrollbar-gutter: stable;
}

.communication-history-table-wrap.is-all-channels .communication-history-table th {
    position: sticky;
    z-index: 2;
    top: 0;
    box-shadow: 0 1px 0 var(--border-soft);
}

.communication-history-table-wrap::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

.communication-history-table-wrap::-webkit-scrollbar-track {
    background: #edf3f6;
}

.communication-history-table-wrap::-webkit-scrollbar-thumb {
    border: 2px solid #edf3f6;
    border-radius: 999px;
    background: color-mix(in srgb, var(--accent) 55%, #9aa9b4);
}

.communication-history-table {
    width: 100%;
    min-width: 1040px;
    border-collapse: separate;
    border-spacing: 0;
}

.communication-history-table th,
.communication-history-table td {
    padding: 16px 12px;
    border-bottom: 1px solid var(--border-soft);
    text-align: left;
    vertical-align: top;
}

.communication-history-table th {
    background: color-mix(in srgb, var(--accent) 5%, var(--surface));
    color: var(--text-muted);
    font-size: .75rem;
    text-transform: uppercase;
}

.communication-history-table tbody tr {
    transition: background .16s ease, box-shadow .16s ease;
}

.communication-history-table tbody tr:hover {
    background: #f5fbfd;
}

.communication-history-table tbody tr.is-selected {
    background: #e9fbff;
}

.communication-history-table tbody tr.is-selected td:first-child {
    box-shadow: inset 4px 0 0 var(--accent);
}

.communication-history-table th:nth-child(1),
.communication-history-table td:nth-child(1) {
    width: 72px;
}

.communication-history-table th:nth-child(2),
.communication-history-table td:nth-child(2) {
    width: 118px;
}

.communication-history-table th:nth-child(3),
.communication-history-table td:nth-child(3) {
    width: 230px;
}

.communication-history-table th:nth-child(4),
.communication-history-table td:nth-child(4) {
    width: 170px;
}

.communication-history-table th:nth-child(5),
.communication-history-table td:nth-child(5) {
    width: 92px;
}

.communication-history-table th:nth-child(6),
.communication-history-table td:nth-child(6) {
    width: auto;
}

.communication-history-table th:nth-child(7),
.communication-history-table td:nth-child(7) {
    width: 140px;
}

.communication-history-table th:nth-child(8),
.communication-history-table td:nth-child(8) {
    width: 130px;
}

.communication-history-table th:nth-child(9),
.communication-history-table td:nth-child(9) {
    width: 120px;
}

.communication-history-id {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    border: 1px solid var(--border-soft);
    border-radius: 999px;
    padding: 3px 8px;
    background: #fff;
    color: var(--text-muted);
    font-size: .72rem;
    font-weight: 900;
    line-height: 1;
}

.communication-history-table td strong {
    display: block;
    line-height: 1.25;
}

.communication-history-view-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 36px;
    border: 1px solid rgba(10, 164, 196, .38);
    border-radius: 8px;
    padding: 8px 14px;
    background: rgba(10, 208, 239, .08);
    color: var(--accent);
    font-weight: 800;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
}

.communication-history-view-button:hover,
.communication-history-view-button:focus {
    border-color: rgba(10, 164, 196, .62);
    background: rgba(10, 208, 239, .18);
    color: #075f70;
    outline: none;
}

.communication-history-table .is-active-status,
.communication-history-modal .is-active-status,
.is-danger-status,
.is-warning-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 26px;
    border-radius: 999px;
    padding: 5px 10px;
    font-size: .74rem;
    font-style: normal;
    font-weight: 800;
    line-height: 1;
}

.communication-history-table .is-active-status,
.communication-history-modal .is-active-status {
    width: fit-content;
}

.is-danger-status {
    border: 1px solid #fecaca;
    background: #fff1f2;
    color: #b91c1c;
}

.is-warning-status {
    border: 1px solid #fde68a;
    background: #fffbeb;
    color: #92400e;
}

.communication-history-pagination {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: center;
    padding: 14px 16px;
    color: var(--text-muted);
}

.communication-history-pagination > div {
    display: flex;
    gap: 10px;
    align-items: center;
}

.communication-history-pagination .is-disabled {
    pointer-events: none;
    opacity: .55;
}

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

.communication-history-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, .46);
    backdrop-filter: blur(1px);
}

.communication-history-modal-panel {
    position: relative;
    z-index: 1;
    display: flex;
    width: min(940px, 100%);
    max-height: min(92vh, 820px);
    overflow: hidden;
    flex-direction: column;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: 0 24px 70px rgba(15, 23, 42, .24);
}

.communication-history-modal-head {
    display: flex;
    flex: 0 0 auto;
    justify-content: space-between;
    gap: 16px;
    padding: 16px 20px 14px;
    border-bottom: 1px solid var(--border);
}

.communication-history-modal-head span {
    color: #2563eb;
    font-size: .76rem;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.communication-history-modal-head h2 {
    margin: 6px 0 6px;
    font-size: 1.2rem;
    line-height: 1.2;
}

.communication-history-modal-head p {
    margin: 0;
    color: var(--text-muted);
}

.communication-history-modal-close {
    display: inline-grid;
    place-items: center;
    width: 36px;
    min-width: 36px;
    height: 36px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #f8fbfd;
    color: var(--text);
    font-weight: 900;
    text-decoration: none;
}

.communication-history-modal-close:hover,
.communication-history-modal-close:focus {
    border-color: var(--accent);
    color: var(--accent);
    outline: none;
}

.communication-history-modal-content {
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
    flex: 1 1 auto;
    min-height: 0;
    gap: 12px;
    overflow: hidden;
    padding: 0;
    background: #eef5fb;
}

.communication-history-modal-message {
    display: flex;
    min-height: 0;
    flex-direction: column;
    margin: 14px 20px 0;
    border: 1px solid #cfe0ea;
    border-radius: 8px;
    background: #eaf3fb;
    overflow: hidden;
}

.communication-history-modal-message span {
    display: block;
    padding: 12px 14px 0;
    color: #2563eb;
    font-size: .75rem;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.communication-history-modal-message strong {
    display: block;
    padding: 4px 14px 4px;
}

.communication-history-modal-subject {
    margin: 0;
    padding: 0 14px 12px;
    color: var(--text);
    font-size: .86rem;
    line-height: 1.45;
}

.communication-history-modal-subject b {
    font-weight: 900;
}

.communication-history-modal-message-body {
    flex: 1 1 auto;
    min-height: 170px;
    max-height: 300px;
    overflow-x: hidden;
    overflow-y: auto;
    scrollbar-gutter: stable;
    margin: 0;
    border-top: 1px solid #d7e6ee;
    padding: 16px;
    background: #eaf3fb;
    color: var(--text);
    line-height: 1.65;
}

.communication-history-modal-message-body > table {
    width: calc(100% - 28px) !important;
    max-width: 760px;
    margin-right: auto;
    margin-left: auto;
}

.communication-history-modal-message-body p {
    margin: 0 0 12px;
}

.communication-history-modal-message-body p:last-child {
    margin-bottom: 0;
}

.communication-history-modal-message-body a {
    color: #0057d8;
    font-weight: 800;
    overflow-wrap: anywhere;
}

.communication-history-modal-message-body span {
    display: inline;
    padding: 0;
    color: var(--text-muted);
    font-size: inherit;
    font-weight: inherit;
    letter-spacing: 0;
    text-transform: none;
}

.communication-history-modal-meta {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
    margin: 0;
    padding: 0 20px 14px;
}

.communication-history-modal-meta div:nth-child(n + 5) {
    grid-column: span 2;
}

.communication-history-modal-meta div {
    min-height: 62px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 10px;
    background: #f8fbfd;
}

.communication-history-modal-meta dt {
    color: var(--text-muted);
    font-size: .72rem;
    font-weight: 900;
    text-transform: uppercase;
}

.communication-history-modal-meta dd {
    margin: 6px 0 0;
    overflow-wrap: anywhere;
    font-weight: 800;
    line-height: 1.35;
}

.communication-history-modal-actions {
    display: flex;
    flex: 0 0 auto;
    justify-content: flex-end;
    gap: 10px;
    padding: 12px 20px 14px;
    border-top: 1px solid var(--border-soft);
}

.product-price-ranges {
    margin-top: 16px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(10, 208, 239, .045), rgba(255, 255, 255, .86));
    overflow: hidden;
}

.product-price-ranges summary {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    padding: 16px 18px;
    cursor: pointer;
    border-bottom: 1px solid var(--border-soft);
}

.product-price-ranges summary span {
    color: var(--accent);
    font-size: .8rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.product-price-ranges summary small {
    color: var(--text-muted);
    font-size: .78rem;
    text-align: right;
}

.product-price-range-table {
    padding: 16px 18px 18px;
}

.product-price-range-actions {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 14px;
}

.product-price-range-head,
.product-price-range-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1fr) 44px;
    gap: 10px 12px;
    align-items: center;
}

.product-price-range-head {
    padding: 0 10px 8px;
}

.product-price-range-head strong {
    color: var(--text-muted);
    font-size: .74rem;
    text-transform: uppercase;
}

.product-price-range-rows {
    display: grid;
    gap: 10px;
}

.product-price-range-row {
    padding: 10px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: rgba(255, 255, 255, .8);
}

.product-price-range-row label {
    display: grid;
    gap: 6px;
}

.product-price-range-row input {
    width: 100%;
    min-height: 38px;
    padding: 9px 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(10, 208, 239, .08);
    color: var(--text);
    font: inherit;
}

.product-price-range-row input:focus {
    outline: 2px solid rgba(10, 164, 196, .22);
    border-color: rgba(10, 164, 196, .58);
    background: #fff;
}

.product-price-range-row input[readonly],
.product-price-range-row input:disabled {
    border-color: rgba(10, 164, 196, .3);
    background: rgba(10, 208, 239, .12);
    color: var(--text);
}

.product-price-range-row label span {
    display: none;
}

.product-price-range-remove {
    display: inline-grid;
    place-items: center;
    width: 36px;
    min-width: 36px;
    height: 36px;
    border: 1px solid rgba(185, 28, 28, .22);
    border-radius: 8px;
    background: rgba(254, 226, 226, .82);
    color: #991b1b;
    cursor: pointer;
    font-weight: 900;
}

.product-price-range-remove:hover:not(:disabled) {
    border-color: rgba(185, 28, 28, .42);
    background: rgba(254, 202, 202, .92);
}

.product-price-range-remove:disabled {
    cursor: not-allowed;
    opacity: .45;
}

.product-tabs {
    padding: 0 24px;
}

.product-detail-panel .product-profile-tabs {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 4px;
    padding: 10px 12px 0;
    background: linear-gradient(180deg, #fbfdfe, #f7fafb);
}

.product-detail-panel .product-profile-tabs a {
    position: relative;
    display: flex;
    min-width: 0;
    min-height: 66px;
    align-items: center;
    gap: 10px;
    border: 0;
    border-radius: 10px 10px 0 0;
    padding: 10px 14px 13px;
    text-align: left;
}

.product-detail-panel .product-profile-tabs a::after {
    position: absolute;
    right: 14px;
    bottom: -1px;
    left: 14px;
    height: 3px;
    border-radius: 3px 3px 0 0;
    background: transparent;
    content: "";
}

.product-detail-panel .product-profile-tabs a:hover,
.product-detail-panel .product-profile-tabs a:focus {
    background: #f0f6f8;
}

.product-detail-panel .product-profile-tabs a.is-active {
    background: #fff;
}

.product-detail-panel .product-profile-tabs a.is-active::after {
    background: linear-gradient(90deg, #087f88, #10a18f);
}

.product-profile-tab-icon {
    display: grid;
    flex: 0 0 32px;
    width: 32px;
    height: 32px;
    place-items: center;
    border: 1px solid #cfe1e7;
    border-radius: 9px;
    background: #f4fafb;
    color: #137283;
    font-size: .66rem;
    font-weight: 900;
}

.product-profile-tabs a.is-active .product-profile-tab-icon {
    border-color: #a8dcd5;
    background: #e7f7f3;
    color: #0a786e;
}

.product-profile-tab-copy {
    min-width: 0;
}

.product-profile-tab-copy strong,
.product-profile-tab-copy small {
    display: block;
}

.product-profile-tab-copy strong {
    color: inherit;
    font-size: .84rem;
    line-height: 1.15;
}

.product-profile-tab-copy small {
    margin-top: 3px;
    color: #81919c;
    font-size: .66rem;
    font-weight: 500;
    line-height: 1.15;
}

.product-detail-panel .product-profile-tabs b {
    flex: 0 0 auto;
    margin-left: 2px;
}

@media (max-width: 760px) {
    .product-detail-panel .product-profile-tabs {
        grid-template-columns: 1fr;
        gap: 7px;
        padding: 10px;
    }

    .product-detail-panel .product-profile-tabs a {
        width: 100%;
        min-height: 56px;
        border: 1px solid #d8e5e9;
        border-radius: 10px;
        padding: 10px 12px;
    }

    .product-detail-panel .product-profile-tabs a::after {
        top: 8px;
        right: auto;
        bottom: 8px;
        left: -1px;
        width: 3px;
        height: auto;
        border-radius: 0 3px 3px 0;
    }

    .product-detail-panel .product-profile-tabs a.is-active {
        border-color: #a9dcd7;
        background: #effaf8;
    }

    .product-detail-panel .product-profile-tabs b {
        margin-left: auto;
    }
}

.file-policy-shell {
    max-width: 1420px;
}

.file-policy-shell > .page-header {
    align-items: end;
    margin-top: 20px;
    margin-bottom: 34px;
}

.file-policy-shell > .page-header > div:first-child {
    padding-top: 10px;
}

.file-policy-shell .page-actions {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 12px;
    margin-top: 0;
}

.file-policy-shell .page-actions form {
    margin: 0;
}

.file-policy-shell .page-actions .button {
    min-width: 138px;
    white-space: nowrap;
}

.file-policy-alert {
    margin-bottom: 18px;
}

.file-policy-summary small {
    overflow: hidden;
    max-width: 100%;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.file-policy-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 18px;
    align-items: start;
}

.file-policy-card {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow-sm);
}

.file-policy-form {
    padding: 18px;
}

.file-policy-field-grid {
    margin-top: 18px;
}

.file-policy-field-grid label:nth-child(3),
.file-policy-field-grid label:nth-child(4) {
    grid-column: span 2;
}

.file-policy-switch-list {
    display: grid;
    gap: 10px;
    margin-top: 18px;
}

.file-policy-switch-list label {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 54px;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.file-policy-switch-list strong,
.file-policy-switch-list small {
    display: block;
}

.file-policy-switch-list small {
    margin-top: 3px;
    color: var(--text-muted);
    font-size: .8rem;
}

.file-policy-switch-list input[type="checkbox"] {
    position: absolute;
    right: 12px;
    width: 46px;
    height: 26px;
    flex: 0 0 auto;
    cursor: pointer;
    opacity: 0;
}

.file-policy-switch-list i {
    position: relative;
    display: inline-block;
    width: 46px;
    min-width: 46px;
    height: 26px;
    border: 1px solid #cbd5e1;
    border-radius: 999px;
    background: #e2e8f0;
    box-shadow: inset 0 1px 2px rgba(15, 23, 42, .12);
    transition: background .18s ease, border-color .18s ease;
}

.file-policy-switch-list i::after {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 6px rgba(15, 23, 42, .24);
    content: "";
    transition: transform .18s ease;
}

.file-policy-switch-list input[type="checkbox"]:checked + i {
    border-color: rgba(8, 145, 178, .48);
    background: linear-gradient(135deg, #2dd4bf, #0891b2);
}

.file-policy-switch-list input[type="checkbox"]:checked + i::after {
    transform: translateX(20px);
}

.file-policy-switch-list input[type="checkbox"]:focus-visible + i {
    outline: 3px solid rgba(14, 165, 233, .22);
    outline-offset: 2px;
}

.file-policy-side {
    display: grid;
    gap: 18px;
}

.file-policy-side .file-policy-card {
    padding: 18px;
}

.file-policy-side h2 {
    margin: 0 0 10px;
    font-size: 1.02rem;
}

.file-policy-status {
    display: grid;
    gap: 6px;
    padding: 16px;
    border: 1px solid #bbf7d0;
    border-radius: 8px;
    background: #f0fdf4;
    color: #14532d;
}

.file-policy-status span {
    font-size: .85rem;
}

.file-policy-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.file-policy-tags span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 5px 9px;
    border: 1px solid #fecaca;
    border-radius: 8px;
    background: #fff1f2;
    color: #e11d48;
    font-weight: 800;
    font-size: .78rem;
}

.storage-shell {
    max-width: 1420px;
}

.storage-page-header {
    align-items: end;
    margin-top: 20px;
    margin-bottom: 28px;
}

.storage-page-header .page-actions {
    display: flex;
    gap: 12px;
    margin-top: 0;
}

.storage-summary small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.storage-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 18px;
    align-items: start;
}

.storage-main-card,
.storage-card {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow-sm);
}

.storage-main-card {
    padding: 18px;
}

.storage-main-card .panel-inline-head > span {
    color: #059669;
    font-size: .82rem;
    font-weight: 800;
}

.storage-meter {
    display: grid;
    gap: 10px;
    margin: 16px 0;
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.storage-meter > div {
    display: flex;
    justify-content: space-between;
    gap: 14px;
}

.storage-meter span {
    font-weight: 800;
}

.storage-meter b,
.storage-row-meter {
    display: block;
    overflow: hidden;
    height: 12px;
    border-radius: 999px;
    background: #e8eef3;
}

.storage-meter i,
.storage-row-meter i {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #14b8a6, #0891b2);
}

.storage-meter small {
    color: var(--text-muted);
}

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

.storage-table {
    width: 100%;
    border-collapse: collapse;
}

.storage-table th,
.storage-table td {
    padding: 14px 10px;
    border-bottom: 1px solid var(--border-soft);
    text-align: left;
}

.storage-table th {
    background: color-mix(in srgb, var(--accent) 5%, var(--surface));
    color: var(--text-muted);
    font-size: .75rem;
    text-transform: uppercase;
}

.storage-table td strong,
.storage-table td small {
    display: block;
}

.storage-table td small {
    margin-top: 4px;
    color: var(--text-muted);
}

.storage-row-meter {
    display: inline-block;
    width: 72px;
    height: 8px;
    margin-right: 8px;
    vertical-align: middle;
}

.storage-total-row td {
    border-bottom: 0;
    font-weight: 900;
}

.storage-side {
    display: grid;
    gap: 18px;
}

.storage-card {
    padding: 18px;
}

#storage-details {
    scroll-margin-top: 18px;
}

.storage-card h2 {
    margin: 0 0 10px;
    font-size: 1.03rem;
}

.storage-card > p {
    margin: 0 0 12px;
    color: var(--text-muted);
}

.storage-health {
    display: grid;
    gap: 6px;
    padding: 18px;
    border: 1px solid #bbf7d0;
    border-radius: 8px;
    background: #f0fdf4;
    color: #14532d;
    text-align: center;
}

.storage-detail-list {
    display: grid;
    gap: 10px;
    max-height: 460px;
    overflow: auto;
}

.storage-detail-list article {
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.storage-detail-list strong,
.storage-detail-list span,
.storage-detail-list small {
    display: block;
}

.storage-detail-list span {
    margin-top: 4px;
}

.storage-detail-list small {
    margin-top: 4px;
    color: var(--text-muted);
}

.storage-detail-backdrop {
    position: fixed;
    inset: 0;
    z-index: 80;
    background: rgba(15, 23, 42, .54);
}

.storage-detail-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    z-index: 81;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto;
    width: min(760px, calc(100vw - 32px));
    max-height: min(760px, calc(100vh - 44px));
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: 0 24px 70px rgba(15, 23, 42, .26);
    transform: translate(-50%, -50%);
}

.storage-detail-modal header,
.storage-detail-modal footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 18px;
    border-bottom: 1px solid var(--border-soft);
}

.storage-detail-modal footer {
    justify-content: flex-end;
    border-top: 1px solid var(--border-soft);
    border-bottom: 0;
}

.storage-detail-modal header span {
    color: var(--accent);
    font-size: .76rem;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.storage-detail-modal h2 {
    margin: 4px 0;
    font-size: 1.35rem;
}

.storage-detail-modal .button-square {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    padding: 0;
    font-weight: 900;
    text-transform: lowercase;
}

.storage-detail-modal p {
    margin: 0;
    color: var(--text-muted);
}

.storage-detail-list-modal {
    max-height: none;
    overflow: auto;
    padding: 18px;
    background: color-mix(in srgb, var(--accent) 4%, var(--surface));
}

.storage-detail-list-modal article {
    background: var(--surface);
}

.parameters-shell {
    max-width: 1420px;
}

.parameters-page-header {
    align-items: end;
    margin-top: 20px;
    margin-bottom: 28px;
}

.parameters-page-header .page-actions {
    display: flex;
    gap: 12px;
    margin-top: 0;
}

.parameters-page-header .page-actions form {
    margin: 0;
}

.parameters-summary {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.parameters-summary small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.client-summary-strip .parameters-sender-summary {
    display: block;
    overflow: hidden;
    max-width: 100%;
    font-size: clamp(1.05rem, 1.25vw, 1.28rem);
    line-height: 1.15;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.parameters-alert {
    margin-bottom: 18px;
}

.parameters-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 18px;
    align-items: start;
}

.parameters-card {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow-sm);
}

.parameters-form,
.parameters-side .parameters-card {
    padding: 18px;
}

.parameters-field-grid {
    margin-top: 18px;
}

.parameters-field-grid label:nth-child(4) {
    grid-column: span 2;
}

.parameters-field-grid textarea {
    min-height: 96px;
}

.parameters-automation-card {
    display: grid;
    gap: 16px;
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px solid var(--border);
}

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

.parameters-toggle-list label {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 14px;
    align-items: center;
    min-height: 104px;
    padding: 15px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #f8fbff;
}

.parameters-toggle-list label.is-disabled {
    background: #f4f6f8;
    color: var(--text-muted);
}

.parameters-toggle-list strong,
.parameters-toggle-list small {
    display: block;
}

.parameters-toggle-list strong {
    color: var(--text);
    font-weight: 900;
}

.parameters-toggle-list small {
    margin-top: 5px;
    color: var(--text-muted);
    line-height: 1.35;
}

.parameters-toggle-list input[type="checkbox"] {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.parameters-toggle-list i {
    position: relative;
    display: inline-block;
    width: 52px;
    height: 30px;
    border: 1px solid #bdd3df;
    border-radius: 999px;
    background: #d8e5ec;
}

.parameters-toggle-list i::after {
    position: absolute;
    top: 4px;
    left: 4px;
    width: 20px;
    height: 20px;
    border-radius: 999px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.24);
    content: "";
    transition: transform 0.18s ease;
}

.parameters-toggle-list input[type="checkbox"]:checked + i {
    border-color: #00a6c8;
    background: #00c2df;
}

.parameters-toggle-list input[type="checkbox"]:checked + i::after {
    transform: translateX(22px);
}

.parameters-toggle-list input[type="checkbox"]:focus-visible + i {
    outline: 3px solid rgba(0, 166, 200, 0.28);
    outline-offset: 2px;
}

.parameters-toggle-list input[type="checkbox"]:disabled + i {
    opacity: 0.62;
}

.parameters-private-notes {
    display: grid;
    gap: 16px;
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px solid var(--border);
}

.parameters-session-card { display: grid; gap: 16px; margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--border); }
.parameters-session-setting { display: grid; grid-template-columns: minmax(260px, .8fr) minmax(320px, 1.2fr); gap: 14px; }
.parameters-session-setting > label, .parameters-session-note { display: grid; align-content: center; gap: 8px; min-height: 122px; padding: 16px; border: 1px solid #bee3f8; border-radius: 10px; background: #f8fbff; }
.parameters-session-setting > label > span:first-child, .parameters-session-note strong { color: var(--text); font-weight: 900; }
.parameters-session-input { display: flex; align-items: center; gap: 9px; }
.parameters-session-input input { width: 112px; min-height: 46px; font-size: 1.15rem; font-weight: 900; text-align: center; }
.parameters-session-input strong { color: #005b78; font-size: .84rem; text-transform: uppercase; }
.parameters-session-setting small, .parameters-session-note span, .parameters-session-footnote { color: var(--text-muted); font-size: .82rem; line-height: 1.45; }
.parameters-session-note { border-color: #d9e2ec; background: #fff; }
.parameters-session-timeline { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 10px; margin: 0; padding: 0; list-style: none; }
.parameters-session-timeline li { position: relative; display: grid; gap: 4px; min-height: 96px; padding: 14px 12px 12px 35px; border: 1px solid #d9e2ec; border-radius: 10px; background: #fff; }
.parameters-session-timeline i { position: absolute; top: 18px; left: 14px; width: 10px; height: 10px; border-radius: 50%; background: #23bd8b; box-shadow: 0 0 0 5px rgba(35,189,139,.12); }
.parameters-session-timeline .is-warning i, .parameters-session-timeline .is-modal i { background: #f5a524; box-shadow: 0 0 0 5px rgba(245,165,36,.13); }
.parameters-session-timeline .is-danger i { background: #e7505a; box-shadow: 0 0 0 5px rgba(231,80,90,.12); }
.parameters-session-timeline strong { color: var(--text); font-size: .84rem; }
.parameters-session-timeline span { color: var(--text-muted); font-size: .76rem; line-height: 1.35; }
.parameters-session-footnote { margin: 0; padding: 11px 13px; border-radius: 8px; background: #eef8fd; }

/* Backup administrativo do banco */
.database-backup-layout { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(300px, .55fr); gap: 16px; }
.database-backup-card { padding: 20px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); box-shadow: var(--shadow-soft); }
.database-backup-side { display: grid; align-content: start; gap: 16px; }
.database-backup-card > h2 { margin: 0 0 14px; font-size: 1rem; }
.database-backup-scope { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 18px; }
.database-backup-scope > div { min-height: 116px; padding: 16px; border: 1px solid #cfe0e6; border-radius: 10px; background: #f7fafb; }
.database-backup-scope strong, .database-backup-scope span { display: block; }
.database-backup-scope strong { margin-bottom: 7px; color: var(--text); }
.database-backup-scope span { color: var(--text-muted); font-size: .82rem; line-height: 1.48; }
.database-backup-action { display: flex; align-items: center; gap: 13px; margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--border-soft); }
.database-backup-action small { color: var(--text-muted); font-size: .78rem; }
.database-backup-sensitive-note { margin: 14px 0 0; color: var(--text-muted); font-size: .78rem; line-height: 1.45; }
.database-backup-checklist { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.database-backup-checklist li { position: relative; padding-left: 24px; color: var(--text-muted); font-size: .82rem; line-height: 1.35; }
.database-backup-checklist li::before { content: '✓'; position: absolute; left: 0; top: -1px; display: grid; place-items: center; width: 17px; height: 17px; border-radius: 50%; background: #e8f8f1; color: var(--success); font-size: .7rem; font-weight: 900; }
.database-backup-last { display: grid; gap: 10px; margin: 0; }
.database-backup-last > div { display: grid; gap: 3px; padding-bottom: 9px; border-bottom: 1px solid var(--border-soft); }
.database-backup-last > div:last-child { padding-bottom: 0; border-bottom: 0; }
.database-backup-last dt { color: var(--text-muted); font-size: .72rem; font-weight: 800; text-transform: uppercase; }
.database-backup-last dd { margin: 0; overflow-wrap: anywhere; color: var(--text); font-size: .84rem; font-weight: 750; }

@media (max-width: 920px) {
    .database-backup-layout, .database-backup-scope { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
    .database-backup-action { align-items: stretch; flex-direction: column; }
    .database-backup-action .button { width: 100%; }
}

.parameters-private-notes-locked {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 16px;
    border: 1px solid #bee3f8;
    border-radius: 8px;
    background: #f8fbff;
}

.parameters-private-notes-locked strong,
.parameters-private-notes-locked small,
.parameters-private-notes-editor small {
    display: block;
}

.parameters-private-notes-locked strong {
    color: var(--text);
    font-weight: 900;
}

.parameters-private-notes-locked small,
.parameters-private-notes-editor small {
    margin-top: 5px;
    color: var(--text-muted);
    line-height: 1.35;
}

.parameters-private-notes-editor {
    display: grid;
    gap: 8px;
}

.parameters-private-notes-locked[hidden],
.parameters-private-notes-editor[hidden],
.parameters-private-notes-modal[hidden],
.parameters-private-notes-error[hidden] {
    display: none;
}

.parameters-private-notes-editor label {
    display: grid;
    gap: 8px;
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 800;
}

.parameters-private-notes-editor textarea {
    min-height: 170px;
    padding: 12px 14px;
    border: 1px solid #b9d3e2;
    border-radius: 8px;
    background: #f8fcff;
    color: var(--text);
    font: inherit;
    line-height: 1.5;
    resize: vertical;
}

.parameters-private-notes-modal {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: grid;
    place-items: center;
    padding: 20px;
    background: rgba(15, 23, 42, 0.48);
}

.parameters-private-notes-dialog {
    position: relative;
    width: min(100%, 440px);
    padding: 30px 24px 24px;
    border: 1px solid #c4d8e4;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 22px 70px rgba(15, 23, 42, 0.28);
}

.parameters-private-notes-close {
    position: absolute;
    top: 16px;
    right: 16px;
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border: 1px solid #b9d3e2;
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    font: inherit;
    font-size: 1.05rem;
    font-weight: 900;
    cursor: pointer;
}

.parameters-private-notes-close:hover,
.parameters-private-notes-close:focus {
    border-color: var(--primary);
    color: var(--primary);
    outline: none;
}

.parameters-private-notes-dialog h2 {
    margin: 0 0 8px;
    color: var(--text);
    font-size: 1.35rem;
}

.parameters-private-notes-dialog p {
    margin: 0 0 18px;
    color: var(--text-muted);
    line-height: 1.45;
}

.parameters-private-notes-dialog form,
.parameters-private-notes-dialog label {
    display: grid;
    gap: 10px;
}

.parameters-private-notes-dialog label {
    color: var(--text-muted);
    font-weight: 800;
}

.parameters-private-notes-dialog input {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #b9d3e2;
    border-radius: 8px;
    background: #f8fcff;
    color: var(--text);
    font: inherit;
}

.parameters-private-notes-dialog footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 8px;
}

.parameters-private-notes-error {
    padding: 10px 12px;
    border: 1px solid #fecaca;
    border-radius: 8px;
    background: #fff1f2;
    color: #991b1b;
    font-weight: 800;
}

.parameters-side {
    display: grid;
    gap: 18px;
}

.parameters-side h2 {
    margin: 0 0 10px;
    font-size: 1.03rem;
}

.parameters-side p {
    margin: 0 0 14px;
    color: var(--text-muted);
}

.parameters-note {
    display: grid;
    gap: 5px;
    padding: 14px;
    border: 1px solid #bbf7d0;
    border-radius: 8px;
    background: #f0fdf4;
    color: #14532d;
}

.parameters-flow {
    display: grid;
    gap: 10px;
}

.parameters-flow span {
    display: block;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    font-weight: 800;
}

.product-proposal-panel,
.product-documents-panel {
    display: grid;
    gap: 18px;
}

.product-detail-panel:has(#product-documents:not([hidden])) .product-form-actions {
    display: none;
}

.product-proposal-hero,
.product-proposal-document {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 16px;
    align-items: center;
    padding: 16px;
    border: 1px solid rgba(10, 208, 239, .28);
    border-radius: 8px;
    background: rgba(10, 208, 239, .06);
}

.product-proposal-hero h3,
.product-proposal-document strong {
    margin: 4px 0 0;
    color: var(--text);
}

.product-proposal-hero span,
.product-proposal-document span {
    display: block;
    margin-top: 5px;
    color: var(--text-muted);
    font-size: .82rem;
}

.product-proposal-document-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px;
}

.product-proposal-hero em {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 12px;
    border-radius: 999px;
    background: rgba(10, 208, 239, .14);
    color: var(--accent);
    font-size: .76rem;
    font-style: normal;
    font-weight: 800;
}

.product-editor-label {
    display: block;
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 700;
}

.product-simple-editor {
    border: 1px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
    background: rgba(10, 208, 239, .08);
}

.product-editor-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px;
    border-bottom: 1px solid var(--border-soft);
    background: rgba(255, 255, 255, .82);
}

.product-editor-toolbar button {
    min-height: 32px;
    padding: 0 11px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: var(--surface-strong);
    color: var(--text);
    cursor: pointer;
    font-weight: 800;
}

.product-editor-surface {
    min-height: 190px;
    padding: 16px;
    color: var(--text);
    line-height: 1.55;
}

.product-editor-surface[contenteditable="true"]:focus {
    outline: 2px solid rgba(10, 164, 196, .22);
    background: #fff;
}

.product-document-list .client-document-card {
    background: rgba(255, 255, 255, .78);
}

.client-filter-bar {
    display: grid;
    grid-template-columns: minmax(260px, 1.4fr) minmax(150px, .6fr) minmax(170px, .75fr) auto;
    gap: 10px;
    align-items: end;
    margin-bottom: 12px;
    padding: 12px 14px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: var(--surface);
}

.client-filter-bar label {
    display: grid;
    gap: 6px;
    color: var(--text-muted);
    font-size: .86rem;
}

.client-filter-bar input,
.client-filter-bar select {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 10px 11px;
    background: #fff;
    color: var(--text);
}

.client-filter-actions {
    display: flex;
    justify-content: flex-end;
}

.clients-workspace {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(360px, .65fr);
    gap: 14px;
    align-items: start;
}

.client-table-panel,
.client-detail-panel {
    min-width: 0;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: var(--surface);
}

.client-table-panel {
    padding: 14px;
}

.client-detail-panel {
    position: sticky;
    top: 78px;
    padding: 16px;
}

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

.panel-inline-head h2 {
    margin: 0;
    color: var(--text);
    font-size: 1.35rem;
}

.panel-inline-head p {
    margin: 3px 0 0;
}

.client-table-wrap {
    max-height: calc(100vh - 330px);
    min-height: 360px;
    margin-top: 0;
}

.client-table {
    min-width: 980px;
}

.client-table th,
.client-table td {
    padding: 11px 12px;
}

.client-table tbody tr.is-selected {
    background: rgba(23, 101, 118, .07);
}

.client-table small,
.client-row-link small {
    display: block;
    margin-top: 3px;
    color: var(--text-soft);
    line-height: 1.25;
}

.client-row-link {
    color: var(--text);
    text-decoration: none;
}

.client-row-link:hover strong,
.client-row-link:focus strong {
    color: var(--accent);
}

.client-definition-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 12px;
    margin: 0;
}

.client-definition-grid div {
    min-width: 0;
    padding-bottom: 9px;
    border-bottom: 1px solid var(--border-soft);
}

.client-definition-grid dt {
    color: var(--accent);
    font-size: .72rem;
    font-weight: 700;
    text-transform: uppercase;
}

.client-definition-grid dd {
    margin: 4px 0 0;
    color: var(--text);
    overflow-wrap: anywhere;
}

.client-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 14px 0;
}

.client-tabs a {
    min-height: 30px;
    border: 1px solid var(--border-soft);
    border-radius: 999px;
    padding: 6px 10px;
    color: var(--text-muted);
    font-size: .86rem;
    text-decoration: none;
}

.client-tabs a.is-active,
.client-tabs a:hover,
.client-tabs a:focus {
    border-color: var(--border);
    background: var(--surface-strong);
    color: var(--accent);
}

.client-section {
    margin-top: 14px;
}

.client-section h3 {
    margin: 0 0 10px;
    color: var(--text);
    font-size: 1rem;
}

.client-section p {
    margin: 0;
}

.client-product-list {
    display: grid;
    gap: 8px;
}

.client-product-list article {
    padding: 10px 12px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: var(--surface-strong);
}

.client-product-list strong,
.client-product-list span {
    display: block;
}

.client-product-list span {
    margin-top: 4px;
    color: var(--text-muted);
    font-size: .88rem;
}

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

.client-directory-panel,
.client-rich-detail-panel,
.category-detail-panel {
    min-width: 0;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
}

.client-directory-panel {
    display: flex;
    flex-direction: column;
    padding: 16px;
}

.client-directory-search {
    margin-bottom: 10px;
}

.client-directory-search label {
    display: grid;
    gap: 6px;
    color: var(--text-muted);
    font-size: .82rem;
}

.client-directory-search input,
.client-directory-search select {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 11px 12px;
    background: #fff;
    color: var(--text);
    font: inherit;
}

.client-directory-search select {
    min-height: 42px;
    cursor: pointer;
}

.client-directory-search input:focus,
.client-directory-search select:focus {
    outline: 2px solid rgba(9, 127, 151, .16);
    border-color: var(--brand);
}

.client-filter-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

.client-filter-pills a {
    min-height: 34px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 8px 12px;
    background: #fff;
    color: var(--text);
    font-size: .86rem;
    text-decoration: none;
}

.client-filter-pills a.is-active,
.client-filter-pills a:hover,
.client-filter-pills a:focus {
    border-color: rgba(10, 164, 196, .5);
    background: rgba(10, 164, 196, .08);
    color: var(--accent);
}

.client-directory-list {
    display: grid;
    gap: 9px;
    padding-right: 2px;
}

.client-directory-item {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 10px;
    align-items: center;
    min-height: 74px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 10px;
    background: #fff;
    color: var(--text);
    text-decoration: none;
}

.client-directory-item.is-selected,
.client-directory-item:hover,
.client-directory-item:focus {
    border-color: rgba(10, 164, 196, .45);
    background: rgba(10, 208, 239, .08);
}

.client-directory-item strong,
.client-directory-item small {
    display: block;
}

.client-directory-item strong {
    color: var(--text);
    font-size: .9rem;
    line-height: 1.2;
}

.client-directory-item small {
    margin-top: 4px;
    color: var(--text-muted);
    font-size: .76rem;
    line-height: 1.28;
}

.directory-item-badges {
    display: grid;
    justify-items: end;
    gap: 6px;
}

.directory-item-badges b {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 22px;
    border: 1px solid var(--border-soft);
    border-radius: 999px;
    padding: 3px 8px;
    background: #fff;
    color: var(--text-muted);
    font-size: .68rem;
    font-weight: 900;
    line-height: 1;
    white-space: nowrap;
}

.client-directory-item .product-document-signal {
    display: inline-flex;
    width: fit-content;
    margin-top: 6px;
    border: 1px solid var(--border-soft);
    border-radius: 999px;
    padding: 3px 7px;
    background: #fff;
    color: var(--text-muted);
    font-size: .68rem;
    font-weight: 800;
    line-height: 1;
}

.client-directory-item .product-document-signal.has-proposal {
    border-color: rgba(0, 133, 111, .24);
    background: rgba(0, 133, 111, .08);
    color: var(--success);
}

.client-directory-item .product-document-signal.has-documents {
    border-color: rgba(10, 164, 196, .26);
    background: rgba(10, 208, 239, .08);
    color: var(--accent);
}

.client-directory-item .product-document-signal.missing-proposal {
    border-color: rgba(185, 65, 65, .2);
    background: rgba(185, 65, 65, .04);
    color: var(--danger);
}

.client-directory-pagination {
    display: grid;
    grid-template-columns: 38px 1fr 38px;
    align-items: center;
    gap: 10px;
    margin-top: 12px;
}

.client-directory-pagination a {
    display: inline-grid;
    place-items: center;
    min-height: 38px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: #fff;
    color: var(--accent);
    font-size: 1.1rem;
    line-height: 1;
    text-decoration: none;
}

.client-directory-pagination a:hover,
.client-directory-pagination a:focus {
    border-color: var(--border);
    background: var(--surface-strong);
}

.client-directory-pagination a.is-disabled {
    border-color: var(--border-soft);
    color: var(--text-soft);
    pointer-events: none;
}

.client-directory-pagination span {
    color: var(--text-muted);
    font-size: .9rem;
    text-align: center;
}

.client-directory-total {
    display: block;
    margin-top: 8px;
    color: var(--text-soft);
    font-size: .76rem;
}

.client-avatar {
    display: inline-grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border: 1px solid rgba(21, 122, 82, .22);
    border-radius: 999px;
    background: rgba(32, 201, 151, .13);
    color: #047857;
    font-size: .82rem;
    font-weight: 700;
}

.client-avatar-large {
    width: 46px;
    height: 46px;
    font-size: .86rem;
}

.client-directory-item em,
.client-status-pill {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    min-height: 26px;
    border-radius: 999px;
    padding: 5px 9px;
    font-size: .72rem;
    font-style: normal;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
}

.is-active-status {
    border: 1px solid rgba(10, 164, 196, .35);
    background: rgba(10, 208, 239, .14);
    color: #00738a;
}

.is-inactive-status {
    border: 1px solid rgba(166, 107, 0, .25);
    background: rgba(255, 214, 153, .32);
    color: var(--warning);
}

.client-rich-detail-panel,
.category-detail-panel {
    overflow: hidden;
}

.client-record-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding: 20px 20px 16px;
    border-bottom: 1px solid var(--border-soft);
}

.selected-client-title {
    display: flex;
    gap: 12px;
    align-items: center;
    min-width: 0;
}

.selected-client-title h2 {
    margin: 0;
    color: var(--text);
    font-size: 1.32rem;
    line-height: 1.2;
}

.selected-client-title p {
    margin: 4px 0 0;
    color: var(--text-muted);
    font-size: .9rem;
    line-height: 1.3;
}

.client-rich-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 0;
    padding: 0 18px;
    border-bottom: 1px solid var(--border-soft);
}

.client-rich-tabs a {
    min-height: 46px;
    border-bottom: 2px solid transparent;
    padding: 14px 14px 11px;
    color: var(--text-muted);
    font-size: .87rem;
    font-weight: 700;
    text-decoration: none;
}

.client-rich-tabs a.is-active,
.client-rich-tabs a:hover,
.client-rich-tabs a:focus {
    border-bottom-color: var(--accent);
    color: var(--accent);
}

.client-rich-tabs b {
    display: inline-grid;
    place-items: center;
    min-width: 18px;
    height: 18px;
    margin-left: 4px;
    border-radius: 999px;
    background: rgba(10, 208, 239, .17);
    color: var(--accent);
    font-size: .7rem;
}

.clients-shell .client-profile-tabs {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 4px;
    padding: 10px 12px 0;
    background: linear-gradient(180deg, #fbfdfe, #f7fafb);
}

.clients-shell .client-profile-tabs a {
    position: relative;
    display: flex;
    min-width: 0;
    min-height: 66px;
    align-items: center;
    gap: 8px;
    border: 0;
    border-radius: 10px 10px 0 0;
    padding: 10px 9px 13px;
    text-align: left;
}

.clients-shell .client-profile-tabs a::after {
    position: absolute;
    right: 10px;
    bottom: -1px;
    left: 10px;
    height: 3px;
    border-radius: 3px 3px 0 0;
    background: transparent;
    content: "";
}

.clients-shell .client-profile-tabs a:hover,
.clients-shell .client-profile-tabs a:focus {
    background: #f0f6f8;
}

.clients-shell .client-profile-tabs a.is-active {
    background: #fff;
}

.clients-shell .client-profile-tabs a.is-active::after {
    background: linear-gradient(90deg, #087f88, #10a18f);
}

.client-profile-tab-icon {
    display: grid;
    flex: 0 0 30px;
    width: 30px;
    height: 30px;
    place-items: center;
    border: 1px solid #cfe1e7;
    border-radius: 9px;
    background: #f4fafb;
    color: #137283;
    font-size: .64rem;
    font-weight: 900;
}

.client-profile-tabs a.is-active .client-profile-tab-icon {
    border-color: #a8dcd5;
    background: #e7f7f3;
    color: #0a786e;
}

.client-profile-tab-copy {
    min-width: 0;
}

.client-profile-tab-copy strong,
.client-profile-tab-copy small {
    display: block;
}

.client-profile-tab-copy strong {
    overflow: hidden;
    color: inherit;
    font-size: .76rem;
    line-height: 1.15;
    text-overflow: ellipsis;
}

.client-profile-tab-copy small {
    margin-top: 3px;
    overflow: hidden;
    color: #81919c;
    font-size: .61rem;
    font-weight: 500;
    line-height: 1.15;
    text-overflow: ellipsis;
}

.clients-shell .client-profile-tabs b {
    flex: 0 0 auto;
    margin-left: auto;
}

@media (max-width: 1500px) and (min-width: 761px) {
    .clients-shell .client-profile-tabs {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .clients-shell .client-profile-tabs {
        grid-template-columns: 1fr;
        gap: 7px;
        padding: 10px;
    }

    .clients-shell .client-profile-tabs a {
        width: 100%;
        min-height: 56px;
        border: 1px solid #d8e5e9;
        border-radius: 10px;
        padding: 10px 12px;
    }

    .clients-shell .client-profile-tabs a::after {
        top: 8px;
        right: auto;
        bottom: 8px;
        left: -1px;
        width: 3px;
        height: auto;
        border-radius: 0 3px 3px 0;
    }

    .clients-shell .client-profile-tabs a.is-active {
        border-color: #a9dcd7;
        background: #effaf8;
    }

    .client-profile-tab-copy strong {
        font-size: .84rem;
    }

    .client-profile-tab-copy small {
        font-size: .66rem;
    }
}

.client-section {
    margin-top: 0;
    padding: 18px 20px 20px;
}

.client-section + .client-section {
    padding-top: 18px;
}

.client-tab-panel[hidden] {
    display: none;
}

.client-section .client-section-label {
    display: inline-flex;
    width: fit-content;
    margin: 2px 0 18px;
    color: var(--accent);
    font-size: .7rem;
    font-weight: 800;
    letter-spacing: .06em;
    line-height: 1;
    text-transform: uppercase;
}

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

.client-field-grid label,
.operational-key-card label {
    display: grid;
    gap: 7px;
    min-width: 0;
    color: var(--text-muted);
    font-size: .82rem;
}

.client-field-grid input,
.client-field-grid select,
.client-field-grid textarea,
.operational-key-card input,
.operational-key-card select {
    width: 100%;
    border: 1px solid rgba(31, 68, 96, .16);
    border-radius: 8px;
    padding: 11px 12px;
    background: #fff;
    color: var(--text);
    font: inherit;
}

.client-field-grid input[type="file"] {
    padding: 8px;
    background: rgba(10, 208, 239, .045);
    color: var(--text-muted);
}

.client-field-grid input[type="file"]::file-selector-button {
    min-height: 34px;
    margin-right: 10px;
    border: 1px solid rgba(10, 164, 196, .36);
    border-radius: 8px;
    padding: 7px 12px;
    background: var(--accent);
    color: #fff;
    cursor: pointer;
    font: inherit;
    font-size: .82rem;
    font-weight: 800;
}

.client-field-grid input[type="file"]::file-selector-button:hover {
    filter: brightness(.96);
}

.client-field-grid label small {
    color: var(--text-muted);
    font-size: .74rem;
    line-height: 1.35;
}

.client-field-grid textarea {
    min-height: 92px;
    resize: vertical;
}

.client-field-grid input[readonly],
.client-field-grid textarea[readonly],
.operational-key-card input[readonly],
.operational-key-card select:disabled {
    border-color: rgba(10, 164, 196, .3);
    background: rgba(10, 208, 239, .09);
    color: var(--text-muted);
    cursor: default;
    opacity: 1;
}

.client-form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    align-items: center;
    margin: 0 20px 20px;
    padding: 18px 0 0;
    border-top: 1px solid var(--border-soft);
}

.operational-key-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(160px, .55fr) minmax(210px, .8fr);
    gap: 12px;
    align-items: end;
    margin-top: 2px;
    margin-bottom: 20px;
    border: 1px solid rgba(10, 164, 196, .18);
    border-radius: 8px;
    padding: 12px;
    background: rgba(10, 208, 239, .035);
}

.operational-key-hint {
    min-height: 40px;
    padding-left: 4px;
}

.operational-key-hint strong,
.operational-key-hint small {
    display: block;
}

.operational-key-hint strong {
    color: var(--accent);
    font-size: .82rem;
}

.operational-key-hint small {
    margin-top: 6px;
    color: var(--text-muted);
    font-size: .78rem;
    line-height: 1.35;
}

.client-address-disclosure {
    margin-top: 2px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: rgba(238, 244, 246, .45);
}

.client-address-disclosure summary {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 12px;
    align-items: center;
    padding: 13px 14px;
    color: var(--accent);
    cursor: pointer;
}

.client-address-disclosure summary span {
    font-size: .82rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.client-address-disclosure summary small {
    color: var(--text-muted);
    font-size: .78rem;
}

.client-address-disclosure .client-field-grid {
    margin: 0;
    padding: 0 14px 14px;
}

.client-tab-heading {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 16px;
}

.client-tab-heading h3 {
    margin: 0;
    color: var(--text);
    font-size: 1.12rem;
}

.client-tab-heading p {
    margin: 5px 0 0;
    color: var(--text-muted);
    font-size: .86rem;
}

.client-tab-heading .button-primary {
    border-color: rgba(10, 164, 196, .45);
    background: var(--accent);
    box-shadow: none;
}

.client-field-grid input.is-empty-value {
    color: var(--text-soft);
    font-style: italic;
}

.client-field-grid .client-field-full {
    grid-column: 1 / -1;
}

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

.client-contact-list {
    display: grid;
    gap: 10px;
}

.client-contact-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    align-items: center;
    min-height: 68px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 12px;
    background: #fff;
    color: inherit;
    text-decoration: none;
}

.client-contact-item:hover,
.client-contact-item:focus,
.client-contact-item.is-selected {
    border-color: rgba(10, 164, 196, .45);
    background: rgba(10, 208, 239, .08);
}

.client-contact-item strong,
.client-contact-item small {
    display: block;
}

.client-contact-item strong {
    color: var(--text);
    line-height: 1.2;
}

.client-contact-item small {
    margin-top: 5px;
    color: var(--text-muted);
    font-size: .82rem;
}

.client-contact-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 8px;
}

.client-contact-meta em {
    display: inline-flex;
    align-items: center;
    min-height: 20px;
    border: 1px solid rgba(10, 164, 196, .25);
    border-radius: 999px;
    padding: 3px 7px;
    background: rgba(10, 208, 239, .1);
    color: var(--accent);
    font-size: .68rem;
    font-style: normal;
    font-weight: 700;
    line-height: 1;
}

.contact-status-pill {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    min-height: 24px;
    border-radius: 999px;
    padding: 5px 8px;
    font-size: .72rem;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
}

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

.client-linked-product-item {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    min-height: 68px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 12px;
    background: #fff;
    color: var(--text);
    text-decoration: none;
}

.client-linked-product-item.is-selected,
.client-linked-product-item:hover,
.client-linked-product-item:focus {
    border-color: rgba(10, 164, 196, .45);
    background: rgba(10, 208, 239, .08);
}

.client-product-icon {
    display: inline-grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: rgba(10, 208, 239, .12);
    color: var(--accent);
    font-size: .72rem;
    font-weight: 800;
}

.client-linked-product-item strong,
.client-linked-product-item small {
    display: block;
}

.client-linked-product-item strong {
    color: var(--text);
    line-height: 1.2;
}

.client-linked-product-item small {
    margin-top: 5px;
    color: var(--text-muted);
    font-size: .78rem;
    line-height: 1.25;
}

.client-linked-product-item em {
    display: inline-flex;
    width: fit-content;
    margin-top: 7px;
    border: 1px solid rgba(10, 164, 196, .25);
    border-radius: 999px;
    padding: 3px 7px;
    background: rgba(10, 208, 239, .1);
    color: var(--accent);
    font-size: .68rem;
    font-style: normal;
    font-weight: 700;
    line-height: 1;
}

.client-product-link-card {
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 16px;
    background: rgba(238, 244, 246, .38);
}

.client-product-link-actions {
    margin-top: 10px;
}

.client-product-link-card .client-field-grid {
    margin-bottom: 14px;
}

.client-product-link-card .client-field-grid-compact {
    margin-bottom: 0;
}

.client-section .client-product-link-subtitle {
    margin: 4px 0 16px;
    color: var(--accent);
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .06em;
    line-height: 1;
    text-transform: uppercase;
}

.client-document-list {
    display: grid;
    gap: 14px;
}

.client-document-card {
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 16px;
    background: #fff;
    overflow: hidden;
}

.client-document-card.is-selected,
.client-document-card:hover {
    border-color: rgba(10, 164, 196, .45);
    background: rgba(10, 208, 239, .06);
}

.client-document-summary {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 14px;
    align-items: start;
    border: 1px solid rgba(10, 164, 196, .24);
    border-radius: 8px;
    padding: 14px;
    background: rgba(10, 208, 239, .07);
}

.client-document-icon {
    display: inline-grid;
    place-items: center;
    width: 52px;
    height: 52px;
    border: 1px solid rgba(10, 164, 196, .28);
    border-radius: 8px;
    background: rgba(10, 208, 239, .08);
    color: var(--accent);
    font-size: .88rem;
    font-weight: 800;
}

.client-document-summary strong,
.client-document-summary p,
.client-document-summary small {
    display: block;
    min-width: 0;
    overflow-wrap: anywhere;
}

.client-document-summary strong {
    color: var(--text);
    font-size: 1rem;
    line-height: 1.25;
}

.client-document-summary p {
    margin: 5px 0 0;
    color: var(--text-muted);
    font-size: .88rem;
    line-height: 1.35;
}

.client-document-meta {
    display: block;
    margin-top: 7px;
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 700;
    line-height: 1.35;
}

.client-document-summary small {
    margin-top: 8px;
    color: var(--success);
    font-size: .82rem;
    font-weight: 700;
}

.client-document-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 12px;
    align-items: center;
}

.client-document-actions a,
.client-document-actions button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    min-width: 44px;
    border: 1px solid rgba(10, 164, 196, .28);
    border-radius: 999px;
    padding: 5px 10px;
    background: rgba(10, 208, 239, .08);
    color: var(--accent);
    cursor: pointer;
    font: inherit;
    font-size: .74rem;
    font-weight: 800;
    line-height: 1;
    text-decoration: none;
}

.client-document-actions button {
    border-color: rgba(185, 65, 65, .28);
    background: rgba(185, 65, 65, .05);
    color: var(--danger);
}

.client-document-actions a:hover,
.client-document-actions a:focus,
.client-document-actions button:hover,
.client-document-actions button:focus {
    border-color: var(--accent);
}

.client-document-guidance {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 14px;
    margin-top: 16px;
    padding: 12px 14px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: rgba(15, 91, 106, .035);
    color: var(--text-muted);
    font-size: .84rem;
    line-height: 1.45;
}

.client-document-guidance strong {
    color: var(--accent);
}

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

.client-note-group {
    display: grid;
    align-content: start;
    gap: 12px;
}

.client-note-group h4 {
    margin: 0;
    color: var(--accent);
    font-size: .92rem;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.client-note-list {
    display: grid;
    gap: 10px;
}

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

.client-note-card {
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 14px;
    background: #fff;
    color: inherit;
    text-decoration: none;
}

.client-note-card:hover,
.client-note-card:focus,
.client-note-card.is-selected {
    border-color: rgba(10, 164, 196, .45);
    background: rgba(10, 208, 239, .08);
}

.client-note-card.is-alert {
    border-color: rgba(185, 65, 65, .32);
    background: rgba(185, 65, 65, .045);
}

.client-note-card strong,
.client-note-card p,
.client-note-card small,
.client-note-card em {
    display: block;
}

.client-note-card strong {
    color: var(--text);
    font-size: .96rem;
}

.client-note-card > span {
    display: inline-flex;
    width: fit-content;
    margin-bottom: 8px;
    border: 1px solid rgba(10, 164, 196, .22);
    border-radius: 999px;
    padding: 3px 7px;
    color: var(--accent);
    font-size: .68rem;
    font-weight: 800;
    line-height: 1;
    text-transform: uppercase;
}

.client-note-card.is-alert strong {
    color: var(--danger);
}

.client-note-card.is-alert > span {
    border-color: rgba(185, 65, 65, .28);
    color: var(--danger);
}

.client-note-card p {
    margin: 7px 0 0;
    color: var(--text-muted);
    font-size: .9rem;
    line-height: 1.4;
}

.client-note-card small {
    margin-top: 10px;
    color: var(--text-soft);
    font-size: .78rem;
}

.client-note-card em {
    margin-top: 10px;
    color: var(--accent);
    font-size: .74rem;
    font-style: normal;
    font-weight: 800;
}

.client-note-card-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 12px;
}

.client-note-card-actions a,
.client-note-card-actions button {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    border: 1px solid rgba(10, 164, 196, .28);
    border-radius: 999px;
    padding: 5px 9px;
    background: rgba(10, 208, 239, .08);
    color: var(--accent);
    cursor: pointer;
    font: inherit;
    font-size: .74rem;
    font-weight: 800;
    line-height: 1;
    text-decoration: none;
}

.client-note-card-actions button {
    border-color: rgba(185, 65, 65, .28);
    background: rgba(185, 65, 65, .05);
    color: var(--danger);
}

.client-note-guidance {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 14px;
    margin-top: 16px;
    padding: 12px 14px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: rgba(15, 91, 106, .035);
    color: var(--text-muted);
    font-size: .84rem;
    line-height: 1.45;
}

.client-note-guidance strong,
.client-note-guidance b {
    color: var(--accent);
}

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

.client-request-card {
    display: grid;
    grid-template-columns: 58px minmax(0, 1fr) minmax(190px, .34fr) auto;
    gap: 12px;
    align-items: center;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 16px 14px;
    background: #fff;
}

.client-request-card:hover,
.client-request-card:focus-within {
    border-color: rgba(10, 164, 196, .45);
    background: rgba(10, 208, 239, .055);
}

.client-request-id {
    display: grid;
    place-items: center;
    min-width: 54px;
    min-height: 54px;
    border-radius: 8px;
    background: rgba(10, 208, 239, .1);
    color: var(--accent);
}

.client-request-id span,
.client-request-id strong {
    display: block;
    line-height: 1;
}

.client-request-id span {
    font-size: .66rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.client-request-id strong {
    margin-top: 5px;
    font-size: .96rem;
}

.client-request-main,
.client-request-meta {
    min-width: 0;
}

.client-request-title-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.client-request-title-row strong,
.client-request-description,
.client-request-facts,
.client-request-meta small {
    overflow-wrap: anywhere;
}

.client-request-title-row strong {
    color: var(--text);
    font-size: .98rem;
    line-height: 1.25;
}

.client-request-description {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    margin: 6px 0 0;
    color: var(--text-muted);
    font-size: .86rem;
    line-height: 1.38;
}

.client-request-facts {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 7px;
}

.client-request-facts span {
    display: inline-flex;
    align-items: center;
    min-height: 22px;
    border-radius: 999px;
    padding: 4px 8px;
    background: rgba(238, 244, 246, .8);
    color: var(--text-soft);
    font-size: .72rem;
    font-weight: 700;
    line-height: 1;
}

.client-request-meta {
    display: grid;
    gap: 6px;
}

.client-request-meta .client-request-priority {
    display: inline-flex;
    width: fit-content;
    border: 1px solid rgba(10, 164, 196, .24);
    border-radius: 999px;
    padding: 4px 8px;
    background: rgba(10, 208, 239, .08);
    color: var(--accent);
    font-size: .7rem;
    font-weight: 800;
    line-height: 1;
}

.client-request-meta small {
    display: grid;
    gap: 2px;
    color: var(--text-muted);
    font-size: .75rem;
    line-height: 1.25;
}

.client-request-meta small b {
    color: var(--text-soft);
    font-size: .66rem;
    letter-spacing: .04em;
    line-height: 1;
    text-transform: uppercase;
}

.client-note-detail-card {
    display: grid;
    gap: 14px;
    position: relative;
    z-index: 2;
    width: min(760px, calc(100vw - 36px));
    max-height: calc(100vh - 56px);
    overflow: auto;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 18px;
    background: var(--surface);
    box-shadow: 0 24px 70px rgba(13, 32, 43, .24);
}

.client-detail-kicker {
    margin: 0 0 -4px;
    color: var(--accent);
    font-size: .74rem;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.client-note-detail-card header {
    display: flex;
    justify-content: space-between;
    gap: 12px;
}

.client-note-detail-card h3 {
    margin: 0;
    color: var(--text);
    font-size: 1.1rem;
}

.client-note-detail-card header p {
    margin: 5px 0 0;
    color: var(--text-muted);
    font-size: .86rem;
}

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

.client-note-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(11, 28, 38, .32);
    backdrop-filter: blur(2px);
}

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

.client-note-modal-close {
    display: inline-grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border: 1px solid var(--border-soft);
    border-radius: 999px;
    color: var(--text-muted);
    font-size: .9rem;
    font-weight: 800;
    line-height: 1;
    text-decoration: none;
}

.client-note-modal-close:hover,
.client-note-modal-close:focus {
    border-color: rgba(10, 164, 196, .36);
    color: var(--accent);
}

.client-note-form {
    display: grid;
    gap: 14px;
}

.client-note-read {
    border: 1px solid rgba(10, 164, 196, .18);
    border-radius: 8px;
    padding: 14px;
    background: rgba(10, 208, 239, .045);
}

.client-note-read p {
    margin: 0;
    color: var(--text);
    font-size: .94rem;
    line-height: 1.5;
}

.client-note-read small {
    display: block;
    margin-top: 12px;
    color: var(--text-muted);
    font-size: .78rem;
}

.locations-shell {
    width: min(1440px, calc(100% - 40px));
    margin: 10px auto 28px;
}

.summary-strip {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    margin: 18px 0;
}

.summary-strip article {
    display: grid;
    align-content: center;
    gap: 7px;
    min-height: 96px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 16px 18px;
    background: var(--surface);
}

.summary-strip span,
.summary-strip small {
    display: block;
    color: var(--text-muted);
}

.summary-strip span {
    font-size: .82rem;
    font-weight: 700;
    text-transform: uppercase;
}

.summary-strip strong {
    display: block;
    color: var(--accent);
    font-size: 1.62rem;
    line-height: 1;
}

.summary-strip small {
    font-size: .78rem;
    line-height: 1.2;
}

.segmented-tabs {
    display: inline-flex;
    gap: 4px;
    margin: 4px 0 16px;
    padding: 5px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: var(--surface);
}

.segmented-tabs a {
    min-width: 110px;
    border-radius: 7px;
    padding: 11px 18px;
    color: var(--text-muted);
    text-align: center;
    text-decoration: none;
    font-weight: 700;
}

.segmented-tabs a.is-active {
    background: rgba(10, 208, 239, .08);
    color: var(--accent);
}

.location-workspace {
    display: grid;
    grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
    gap: 18px;
}

.directory-panel,
.detail-panel {
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 18px;
    background: var(--surface);
}

.detail-panel {
    min-height: 430px;
}

.directory-panel h2,
.detail-panel h2 {
    margin: 0;
}

.directory-search {
    display: grid;
    gap: 10px;
    margin: 16px 0;
}

.directory-search input,
.directory-search select {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 11px 12px;
    background: #fff;
    color: var(--text);
}

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

.directory-list a {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 12px;
    color: var(--text);
    text-decoration: none;
    outline: 0;
    box-shadow: none;
}

.directory-list strong {
    color: var(--text);
    font-weight: 700;
}

.directory-list a.is-active,
.directory-list a:hover,
.directory-list a:focus,
.directory-list a:focus-visible {
    border-color: #78dff0;
    background: rgba(10, 208, 239, .08);
    outline: 0;
    box-shadow: 0 0 0 1px rgba(10, 164, 196, .22);
}

.location-avatar {
    display: inline-grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border: 1px solid rgba(18, 173, 136, .28);
    border-radius: 999px;
    background: rgba(18, 173, 136, .12);
    color: #007f68;
    font-size: .84rem;
    font-weight: 700;
}

.directory-list span,
.directory-list small {
    display: block;
}

.directory-list .location-avatar {
    display: inline-grid;
    place-items: center;
}

.directory-list small {
    margin-top: 4px;
    color: var(--text-muted);
}

.directory-list .directory-item-badges {
    display: grid;
    justify-items: end;
    gap: 6px;
}

.location-form {
    display: grid;
    gap: 16px;
    margin-top: 16px;
    padding: 22px 24px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
}

.location-form label {
    display: grid;
    gap: 7px;
    color: var(--text-muted);
}

.location-form input,
.location-form select {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 12px;
    background: #fff;
    color: var(--text);
}

.location-form input[readonly],
.location-form select:disabled {
    border-color: rgba(10, 164, 196, .3);
    background: rgba(10, 208, 239, .09);
    color: var(--text-muted);
    cursor: default;
    opacity: 1;
}

.location-guidance {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 14px;
    padding: 12px 14px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    background: rgba(15, 91, 106, .035);
    color: var(--text-muted);
    font-size: .84rem;
    line-height: 1.45;
}

.location-guidance strong {
    color: var(--accent);
}

.location-detail-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 -18px;
    padding: 0 18px 14px;
    border-bottom: 1px solid var(--border-soft);
}

.location-detail-head .location-avatar {
    display: inline-grid;
    place-items: center;
    flex: 0 0 auto;
}

.location-detail-head p {
    margin: 4px 0 0;
    color: var(--text-muted);
    font-size: .9rem;
}

.location-detail-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    margin: 18px 18px 0;
    padding-top: 18px;
    border-top: 1px solid var(--border-soft);
}

.location-detail-actions .button,
.location-detail-actions button {
    width: auto;
    min-width: 132px;
}

.location-detail-actions .button-danger {
    border-color: rgba(220, 38, 38, .5);
    background: #fff;
    color: #b42318;
}

.location-detail-actions .button-danger:hover,
.location-detail-actions .button-danger:focus {
    border-color: rgba(220, 38, 38, .7);
    background: rgba(220, 38, 38, .06);
    color: #991b1b;
}

.client-contact-card {
    min-width: 0;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 16px;
    background: rgba(238, 244, 246, .38);
}

.client-contact-card header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 16px;
}

.client-contact-card h3 {
    margin: 0;
    color: var(--text);
    font-size: 1.22rem;
}

.client-contact-card header p {
    margin: 4px 0 0;
    color: var(--text-muted);
    font-size: .9rem;
}

.client-contact-flags {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: 2px;
    border: 1px solid rgba(10, 164, 196, .24);
    border-radius: 8px;
    padding: 10px;
    background: rgba(10, 208, 239, .07);
}

.client-contact-flags section {
    display: grid;
    align-content: start;
    gap: 7px;
}

.client-contact-flags section > strong {
    color: var(--text-muted);
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.client-contact-flags section > div {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.client-contact-flag-admin,
.client-contact-flag-communication {
    min-width: 0;
}

.client-contact-flags .client-contact-flag-admin > div,
.client-contact-flags .client-contact-flag-communication > div {
    display: grid;
    grid-template-columns: 1fr;
    align-items: center;
}

.client-contact-flags span {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    min-height: 28px;
    color: var(--text-muted);
    font-size: .82rem;
}

.client-contact-flags span::before {
    content: "";
    display: inline-grid;
    place-items: center;
    width: 14px;
    height: 14px;
    border: 1px solid var(--border-soft);
    border-radius: 4px;
    background: #fff;
}

.client-contact-flags span.is-enabled {
    color: var(--text);
}

.client-contact-flags span.is-enabled::before {
    content: "✓";
    border-color: rgba(10, 164, 196, .45);
    background: var(--accent);
    color: #fff;
    font-size: .68rem;
    font-weight: 700;
    line-height: 1;
}

.client-rich-detail-panel .client-product-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.client-contact-form {
    display: grid;
    gap: 14px;
}

.client-contact-option-groups {
    display: grid;
    gap: 10px;
}

.client-contact-option-groups fieldset {
    display: grid;
    gap: 8px;
    border: 1px solid rgba(10, 164, 196, .24);
    border-radius: 8px;
    margin: 0;
    padding: 10px;
    background: rgba(10, 208, 239, .07);
}

.client-contact-option-groups legend {
    color: var(--text-muted);
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .04em;
    padding: 0 6px;
    text-transform: uppercase;
}

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

.client-checkbox-grid label {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 38px;
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 8px 10px;
    background: #fff;
    color: var(--text);
    font-size: .84rem;
    font-weight: 700;
}

.client-checkbox-grid input {
    width: 16px;
    height: 16px;
    accent-color: var(--accent);
}

.client-contact-option-group-admin .client-checkbox-grid,
.client-contact-option-group-communication .client-checkbox-grid {
    grid-template-columns: 1fr;
}

.client-field-grid .client-checkbox-line,
.client-checkbox-line {
    display: inline-flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    width: fit-content;
    min-height: 42px;
    color: var(--text);
    font-weight: 700;
}

.client-checkbox-line span {
    white-space: nowrap;
}

.client-field-grid .client-checkbox-line input,
.client-checkbox-line input {
    width: 16px;
    height: 16px;
    min-height: 0;
    padding: 0;
    accent-color: var(--accent);
}

.client-inline-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px;
    padding-top: 14px;
    border-top: 1px solid var(--border-soft);
}

.client-rich-detail-panel .alert {
    margin-bottom: 0;
}

.sidebar-backdrop {
    display: none;
}

.auth-page {
    display: grid;
    place-items: center;
    padding: 28px 0;
}

.auth-page-split {
    padding: 48px 0;
}

.auth-shell {
    display: grid;
    grid-template-columns: minmax(360px, 520px) minmax(320px, 1fr);
    align-items: center;
    gap: 24px;
    width: min(1060px, calc(100% - 48px));
    margin: 0 auto;
}

.auth-panel {
    width: min(460px, calc(100% - 48px));
    margin: 0 auto;
    padding: 32px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
}

.auth-panel-wide {
    width: min(560px, calc(100% - 48px));
}

.auth-panel-login {
    width: 100%;
}

.auth-brand {
    display: inline-flex;
    align-items: center;
    gap: 11px;
    margin-bottom: 18px;
}

.auth-brand-name {
    color: var(--text);
    font-size: 1.16rem;
    font-weight: 800;
    letter-spacing: .025em;
}

.auth-brand-name span:last-child {
    color: #0b8f87;
}

.auth-input-field {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 42px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    transition: border-color .16s ease, box-shadow .16s ease;
}

.auth-input-field:focus-within {
    border-color: #4e9aaa;
    box-shadow: 0 0 0 3px rgba(23, 101, 118, .12);
}

.auth-input-icon {
    display: grid;
    flex: 0 0 42px;
    width: 42px;
    align-self: stretch;
    place-items: center;
    border-right: 1px solid var(--border-soft);
    border-radius: 7px 0 0 7px;
    background: var(--surface-strong);
    color: var(--accent);
}

.auth-input-icon svg {
    width: 19px;
    height: 19px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.9;
}

.form-card .auth-input-field input {
    min-width: 0;
    width: 100%;
    border: 0;
    padding: 12px;
    outline: 0;
}

.form-card .auth-input-field input:focus {
    outline: 0;
}

.form-card .auth-input-field.password-field input {
    padding-right: 92px;
}

.auth-page-centered {
    min-height: 100vh;
    padding: 32px 0;
}

.auth-shell-centered {
    grid-template-columns: minmax(320px, 460px);
    justify-content: center;
}

.auth-panel-centered {
    width: 100%;
    text-align: center;
}

.auth-panel-centered > p:not(.auth-kicker):not(.alert) {
    margin-right: auto;
    margin-left: auto;
    max-width: 380px;
}

.auth-panel-centered .form-card {
    text-align: left;
}

.auth-forgot-link {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    width: fit-content;
    margin: 14px auto 0;
    padding: 7px 11px;
    border: 1px solid transparent;
    border-radius: 999px;
    color: #38617a;
    font-size: .88rem;
    font-weight: 700;
    text-decoration: none;
    transition: border-color .16s ease, background .16s ease, color .16s ease, transform .16s ease;
}

.auth-forgot-link::before { display: grid; width: 20px; height: 20px; place-items: center; border-radius: 50%; background: #e8f1f5; color: #15596b; content: '?'; font-size: .72rem; font-weight: 900; }
.auth-forgot-link:hover { border-color: #c8dce5; background: #f3f8fa; color: #0b596d; text-decoration: none; transform: translateY(-1px); }
.auth-forgot-link:focus-visible { border-color: #6da7b7; outline: 3px solid rgba(39, 133, 154, .17); text-decoration: none; }

.auth-form-actions {
    display: grid;
    gap: 12px;
    margin-top: 24px;
}

.auth-action-form input[readonly] {
    border-color: #cbd5e1;
    background: #eef3f6;
    color: #526477;
}

.auth-security-notice {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 18px;
    padding: 12px 14px;
    border: 1px solid #a7dfd5;
    border-radius: 8px;
    background: #effcf8;
    color: #0f6659;
}

.auth-security-notice[hidden] { display: none; }
.auth-security-notice > span { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: #19a78c; color: #fff; font-weight: 800; }
.auth-security-notice strong, .auth-security-notice small { display: block; }
.auth-security-notice small { margin-top: 2px; color: #38786f; }

.security-two-factor-form { padding: 18px 22px 22px; }
.security-two-factor-toggle { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 16px 18px; border: 1px solid var(--border); border-radius: 10px; background: #fff; cursor: pointer; }
.security-two-factor-toggle strong, .security-two-factor-toggle small { display: block; }
.security-two-factor-toggle small { margin-top: 4px; color: var(--text-muted); }
.security-two-factor-toggle input { position: absolute; right: 18px; width: 52px; height: 28px; opacity: 0; cursor: pointer; }
.security-two-factor-toggle i { position: relative; flex: 0 0 52px; width: 52px; height: 28px; border: 1px solid #cbd5e1; border-radius: 999px; background: #e2e8f0; transition: .18s ease; }
.security-two-factor-toggle i::after { position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 2px 6px rgba(15, 23, 42, .24); content: ""; transition: transform .18s ease; }
.security-two-factor-toggle input:checked + i { border-color: #06a7c4; background: linear-gradient(135deg, #19c5ae, #08a5c7); }
.security-two-factor-toggle input:checked + i::after { transform: translateX(24px); }
.security-two-factor-toggle input:focus-visible + i { outline: 3px solid rgba(14, 165, 233, .22); outline-offset: 3px; }
.security-two-factor-actions { display: flex; justify-content: flex-end; margin-top: 14px; }

.contract-drafts-filter {
    grid-template-columns: minmax(260px, 1.5fr) minmax(170px, .7fr) minmax(220px, 1fr) auto auto;
}

.contract-drafts-table td strong,
.contract-drafts-table td small {
    display: block;
}

.contract-drafts-table td small {
    margin-top: 4px;
    color: var(--text-muted);
}

.contract-draft-center-actions {
    display: grid;
    gap: 7px;
    min-width: 126px;
}

@media (max-width: 1100px) {
    .contract-drafts-filter { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.auth-panel h1 {
    margin-top: 0;
}

.auth-panel form {
    margin-top: 24px;
}

.auth-panel .button,
.auth-panel button {
    width: 100%;
}

.auth-panel .password-toggle {
    width: auto;
}

.auth-remember-option {
    display: flex !important;
    align-items: center;
    gap: 10px;
    width: fit-content;
    color: var(--text-muted);
    font-size: .9rem;
    cursor: pointer;
}

.auth-remember-option input {
    flex: 0 0 auto;
    width: auto;
    margin: 0;
}

.auth-info-panel {
    padding: 40px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
}

.auth-info-panel h2 {
    max-width: 420px;
    margin: 0;
    color: var(--text);
    font-size: 2.3rem;
    line-height: 1.08;
}

.auth-info-panel p {
    max-width: 460px;
}

.auth-kicker {
    margin: 0 0 18px;
    color: var(--accent);
    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.auth-feature-list {
    display: grid;
    gap: 14px;
    margin: 28px 0 0;
    padding: 0;
    list-style: none;
}

.auth-feature-list li {
    padding-top: 14px;
    border-top: 1px solid var(--border-soft);
}

.auth-feature-list strong,
.auth-feature-list span {
    display: block;
}

.auth-feature-list strong {
    color: var(--accent);
}

.auth-feature-list span {
    margin-top: 5px;
    color: var(--text-muted);
    line-height: 1.45;
}

.definition-grid {
    display: grid;
    grid-template-columns: 150px 1fr;
    gap: 10px;
    color: var(--text-muted);
}

.definition-grid dt {
    color: var(--accent);
}

code {
    color: var(--accent);
}

/* Dashboard daily summary */
.dashboard-welcome {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    padding: 2px 4px 0;
}

.dashboard-welcome h1 {
    margin: 0;
    color: var(--text);
    font-size: 1.85rem;
    line-height: 1.15;
}

.dashboard-welcome p {
    margin: 6px 0 0;
    color: var(--text-muted);
}

.dashboard-welcome time {
    padding-bottom: 2px;
    color: var(--text-muted);
    font-size: .82rem;
    font-weight: 700;
    white-space: nowrap;
}

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

.dashboard-summary-card {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr);
    gap: 14px;
    align-items: center;
    min-height: 112px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 9px;
    background: var(--surface);
    color: var(--text);
    text-decoration: none;
    box-shadow: var(--shadow-sm);
    transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}

.dashboard-summary-card:hover,
.dashboard-summary-card:focus-visible {
    border-color: #8fbec8;
    box-shadow: 0 12px 24px rgba(15, 64, 75, .1);
    outline: none;
    transform: translateY(-1px);
}

.dashboard-summary-card > span:last-child {
    display: grid;
    min-width: 0;
}

.dashboard-summary-card small {
    color: var(--text-muted);
    font-size: .78rem;
    font-weight: 800;
}

.dashboard-summary-card strong {
    margin-top: 4px;
    color: var(--text);
    font-size: 1.55rem;
    line-height: 1.05;
    white-space: nowrap;
}

.dashboard-summary-card em {
    margin-top: 7px;
    color: #168394;
    font-size: .72rem;
    font-style: normal;
    font-weight: 800;
    line-height: 1.25;
}

.dashboard-summary-card.is-orange em {
    color: #c97816;
}

.dashboard-summary-icon {
    display: grid;
    place-items: center;
    width: 50px;
    height: 50px;
    border: 1px solid rgba(15, 139, 156, .22);
    border-radius: 999px;
    background: rgba(15, 139, 156, .07);
    color: #0f8495;
    font-size: 1rem;
    font-weight: 900;
}

.dashboard-summary-card.is-orange .dashboard-summary-icon {
    border-color: rgba(232, 147, 43, .25);
    background: rgba(245, 158, 11, .08);
    color: #d47b14;
}

.dashboard-summary-icon.is-arrow {
    font-size: 1.55rem;
    font-weight: 500;
}

.dashboard-middle-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
    gap: 14px;
    margin-top: 16px;
}

.dashboard-info-panel {
    display: flex;
    min-width: 0;
    flex-direction: column;
    border: 1px solid var(--border);
    border-radius: 9px;
    background: var(--surface);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
}

.dashboard-info-panel > header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    min-height: 68px;
    padding: 15px 17px 12px;
    border-bottom: 1px solid var(--border-soft);
}

.dashboard-info-panel > header h2 {
    margin: 0;
    color: var(--text);
    font-size: .98rem;
}

.dashboard-info-panel > header p {
    margin: 4px 0 0;
    color: var(--text-muted);
    font-size: .74rem;
}

.dashboard-agenda-panel > header > span {
    flex: 0 0 auto;
    padding: 4px 8px;
    border: 1px solid #c9dce4;
    border-radius: 999px;
    background: #f5fafc;
    color: var(--text-muted);
    font-size: .68rem;
    font-weight: 850;
}

.dashboard-status-list {
    display: grid;
}

.dashboard-status-list > a,
.dashboard-status-list > div {
    display: grid;
    grid-template-columns: 36px minmax(0, 1fr) auto;
    gap: 10px;
    align-items: center;
    min-height: 58px;
    padding: 8px 16px;
    border-bottom: 1px solid var(--border-soft);
    color: var(--text);
    text-decoration: none;
}

.dashboard-status-list > :last-child {
    border-bottom: 0;
}

.dashboard-status-list > a:hover,
.dashboard-status-list > a:focus-visible {
    background: #f7fbfc;
    outline: none;
}

.dashboard-status-list > .is-future {
    background: #fafbfc;
}

.dashboard-status-list > a > span:nth-child(2),
.dashboard-status-list > div > span:nth-child(2) {
    display: grid;
    min-width: 0;
    gap: 2px;
}

.dashboard-status-list strong {
    color: var(--text-muted);
    font-size: .82rem;
}

.dashboard-status-list small {
    color: var(--text-soft);
    font-size: .69rem;
    line-height: 1.2;
}

.dashboard-status-icon {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border: 1px solid #c7e2e7;
    border-radius: 9px;
    background: #f0fafb;
    color: #128295;
    font-size: .7rem;
    font-weight: 900;
}

.dashboard-status-list em {
    min-width: 72px;
    padding: 5px 8px;
    border: 1px solid transparent;
    border-radius: 999px;
    font-size: .67rem;
    font-style: normal;
    font-weight: 900;
    text-align: center;
}

.dashboard-status-list em.is-active {
    border-color: #aee2d1;
    background: #eaf9f3;
    color: #08775e;
}

.dashboard-status-list em.is-inactive {
    border-color: #d8e0e6;
    background: #f3f5f7;
    color: #71808d;
}

.dashboard-status-list em.is-upcoming {
    border-color: #cddcf0;
    background: #f2f6fc;
    color: #60738d;
}

.dashboard-status-list em.is-unknown {
    border-color: #efd7a9;
    background: #fff9ed;
    color: #94631a;
}

.dashboard-agenda-list {
    display: grid;
}

.dashboard-agenda-list > a {
    position: relative;
    display: grid;
    grid-template-columns: 94px minmax(0, 1fr);
    gap: 14px;
    align-items: center;
    min-height: 58px;
    padding: 8px 16px 8px 22px;
    border-bottom: 1px solid var(--border-soft);
    color: var(--text);
    text-decoration: none;
}

.dashboard-agenda-list > a::before {
    position: absolute;
    left: 12px;
    width: 7px;
    height: 7px;
    border-radius: 999px;
    background: #13879a;
    content: "";
}

.dashboard-agenda-list > a:hover,
.dashboard-agenda-list > a:focus-visible {
    background: #f7fbfc;
    outline: none;
}

.dashboard-agenda-list time,
.dashboard-agenda-list > a > span {
    display: grid;
    min-width: 0;
    gap: 2px;
}

.dashboard-agenda-list time small {
    color: #128295;
    font-size: .66rem;
    font-weight: 850;
}

.dashboard-agenda-list time strong,
.dashboard-agenda-list > a > span strong {
    color: var(--text-muted);
    font-size: .8rem;
}

.dashboard-agenda-list > a > span small {
    color: var(--text-soft);
    font-size: .68rem;
}

.dashboard-agenda-empty {
    display: grid;
    place-content: center;
    flex: 1 1 auto;
    min-height: 136px;
    gap: 5px;
    padding: 24px;
    color: var(--text-muted);
    text-align: center;
}

.dashboard-agenda-empty strong {
    color: var(--text);
}

.dashboard-agenda-empty span {
    font-size: .78rem;
}

.dashboard-agenda-panel > footer {
    margin-top: auto;
    padding: 11px 16px;
    border-top: 1px solid var(--border-soft);
}

.dashboard-agenda-panel > footer a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: #11798a;
    font-size: .76rem;
    font-weight: 850;
    text-decoration: none;
}

.dashboard-agenda-panel > footer a span {
    font-size: 1.15rem;
}

.dashboard-shortcuts-panel {
    margin-top: 16px;
    padding: 17px 18px 18px;
    border: 1px solid var(--border);
    border-radius: 9px;
    background: var(--surface);
    box-shadow: var(--shadow-sm);
}

.dashboard-shortcuts-panel > header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 12px;
}

.dashboard-shortcuts-panel h2 {
    margin: 0;
    color: var(--text);
    font-size: 1rem;
}

.dashboard-shortcuts-panel p {
    margin: 0;
    color: var(--text-muted);
    font-size: .78rem;
}

.shortcut-grid.dashboard-shortcut-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 8px 10px;
}

.dashboard-shortcut-grid .shortcut-link {
    min-height: 46px;
    padding: 8px 10px;
    background: #fbfdfe;
}

.dashboard-shortcut-grid .shortcut-link strong {
    color: var(--text-muted);
    font-size: .82rem;
}

@media (max-width: 1180px) {
    .dashboard-summary-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .shortcut-grid.dashboard-shortcut-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 1000px) {
    .dashboard-middle-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 1400px) and (min-width: 761px) {
    .dashboard-tech-footer {
        flex-wrap: wrap;
        width: 100%;
        margin-top: 18px;
        border-radius: 8px;
        overflow: hidden;
    }

    .dashboard-tech-footer span {
        flex: 1 1 auto;
        white-space: normal;
        overflow-wrap: anywhere;
    }

    .dashboard-tech-key {
        margin-left: 0;
    }
}

@media (max-width: 760px) {
    .dashboard-welcome {
        display: grid;
        align-items: start;
        gap: 8px;
        padding: 0;
    }

    .dashboard-welcome h1 {
        font-size: 1.55rem;
    }

    .dashboard-welcome time {
        grid-row: 1;
        padding: 0;
        font-size: .74rem;
    }

    .dashboard-summary-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .dashboard-summary-card {
        min-height: 102px;
    }

    .dashboard-middle-grid {
        gap: 10px;
        margin-top: 10px;
    }

    .dashboard-info-panel > header {
        min-height: 0;
    }

    .dashboard-status-list > a,
    .dashboard-status-list > div {
        grid-template-columns: 36px minmax(0, 1fr);
        padding: 10px 14px;
    }

    .dashboard-status-list em {
        grid-column: 2;
        justify-self: start;
        min-width: 0;
    }

    .dashboard-agenda-list > a {
        grid-template-columns: 82px minmax(0, 1fr);
    }

    .dashboard-shortcuts-panel {
        padding: 15px;
    }

    .dashboard-shortcuts-panel > header {
        display: grid;
        gap: 5px;
    }

    .shortcut-grid.dashboard-shortcut-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    main,
    .app-shell,
    .main-form,
    .main-form-wide,
    .app-shell-narrow {
        width: min(100% - 28px, 1120px);
        margin: 28px auto;
    }

    .home-panel {
        padding: 22px;
    }

    .authenticated-layout {
        display: block;
    }

    .authenticated-main {
        margin-left: 0;
    }

    .authenticated-sidebar {
        position: fixed;
        inset: 0 auto 0 0;
        z-index: 25;
        width: min(284px, calc(100% - 52px));
        min-height: 100vh;
        height: 100vh;
        overflow: hidden;
        transform: translateX(-100%);
        transition: transform .18s ease;
    }

    .authenticated-layout.sidebar-open .authenticated-sidebar {
        transform: translateX(0);
    }

    .authenticated-layout.sidebar-open .sidebar-backdrop {
        position: fixed;
        inset: 0;
        z-index: 24;
        display: block;
        background: rgba(0, 0, 0, .55);
    }

    .sidebar-close {
        display: block;
    }

    .menu-toggle {
        display: grid;
        order: 2;
        margin-left: auto;
    }

    .topbar {
        min-height: 66px;
        padding: 10px 14px;
        justify-content: flex-start;
    }

    .topbar-brand {
        display: inline-flex;
        order: 1;
    }

    .topbar-context {
        display: none;
    }

    .topbar-account,
    .topbar-user {
        display: none;
    }

    .dashboard-shell {
        display: flex;
        flex-direction: column;
        min-height: auto;
        width: min(100% - 28px, 1120px);
        margin: 24px auto 36px;
    }

    .dashboard-actions {
        order: 1;
    }

    .dashboard-hero {
        order: 2;
    }

    .dashboard-grid {
        order: 3;
    }

    .dashboard-notes {
        order: 4;
    }

    .dashboard-tech-footer {
        order: 5;
        display: grid;
        grid-template-columns: 1fr;
        width: 100%;
        margin: 16px 0 0;
        border-radius: 8px;
        box-shadow: none;
    }

    .dashboard-tech-footer span {
        justify-content: flex-start;
        min-width: 0;
        min-height: 30px;
        border-right: 0;
        border-bottom: 1px solid var(--border-soft);
        white-space: normal;
        overflow-wrap: anywhere;
    }

    .dashboard-tech-key {
        margin-left: 0;
    }

    .dashboard-tech-footer span:last-child {
        border-bottom: 0;
    }

    .app-content,
    .app-content.main-form,
    .app-content.main-form-wide {
        width: min(100% - 28px, 1120px);
        margin: 24px auto 36px;
    }

    .dashboard-hero,
    .dashboard-actions,
    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-context {
        grid-template-columns: 1fr;
        gap: 12px;
        margin-top: 18px;
    }

    .dashboard-context .context-item,
    .dashboard-context .context-item:nth-last-child(-n + 2) {
        min-width: 0;
        padding: 0 0 12px;
        border-bottom: 1px solid var(--border-soft);
    }

    .dashboard-context .context-item:last-child {
        border-bottom: 0;
        padding-bottom: 0;
    }

    .context-item-database {
        grid-column: auto;
    }

    .dashboard-context dt,
    .dashboard-context dd {
        display: block;
        width: 100%;
        min-width: 0;
    }

    .dashboard-context dd {
        word-break: normal;
        overflow-wrap: anywhere;
    }

    .dashboard-context dd small {
        display: flex;
        max-width: 100%;
    }

    .training-filter-panel,
    .training-workspace,
    .training-form-grid {
        grid-template-columns: 1fr;
    }

    .training-filter-panel {
        padding: 14px;
    }

    .trainings-page-header .page-actions {
        display: grid;
        gap: 10px;
        width: 100%;
        margin-top: 4px;
    }

    .training-list-card,
    .training-detail-card {
        border-radius: 8px;
    }

    .training-list-card {
        padding: 14px;
    }

    .training-form-grid-client {
        align-items: stretch;
    }

    .training-form-grid-client .training-wide-field,
    .training-form-grid-client .training-client-search-action,
    .training-form-grid-client .training-client-results {
        grid-column: 1 / -1;
    }

    .training-client-search-action .button {
        width: 100%;
    }

    .training-client-results {
        padding: 10px;
    }

    .training-client-results-head {
        align-items: flex-start;
    }

    .training-client-results-head strong {
        max-width: 130px;
    }

    .training-table-wrap {
        border: 0;
        overflow: visible;
    }

    .training-table {
        display: block;
        min-width: 0;
        width: 100%;
    }

    .training-table thead {
        display: none;
    }

    .training-table tbody {
        display: grid;
        gap: 12px;
    }

    .training-table tbody tr {
        display: grid;
        gap: 8px;
        padding: 13px;
        border: 1px solid var(--border-soft);
        border-left: 4px solid transparent;
        border-radius: 8px;
        background: #fff;
    }

    .training-table tbody tr.is-selected-row {
        border-left-color: var(--accent);
        background: #eaf8fb;
    }

    .training-table th,
    .training-table td {
        padding: 0;
        border-bottom: 0;
    }

    .training-table td {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 12px;
        color: var(--text);
        font-size: .9rem;
        text-align: right;
    }

    .training-table td::before {
        flex: 0 0 86px;
        color: var(--accent);
        content: attr(data-label);
        font-size: .72rem;
        font-weight: 900;
        letter-spacing: .04em;
        text-align: left;
        text-transform: uppercase;
    }

    .training-table td.client-cell {
        display: grid;
        grid-template-columns: 86px minmax(0, 1fr);
        text-align: left;
    }

    .training-table td.client-cell::before {
        align-self: start;
    }

    .training-table td.client-cell strong,
    .training-table td.client-cell small,
    .training-author-cell strong,
    .training-author-cell small {
        overflow-wrap: anywhere;
    }

    .training-table td[data-label="Acoes"] {
        display: block;
        padding-top: 4px;
    }

    .training-table td[data-label="Acoes"]::before {
        display: none;
    }

    .training-table-actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
        width: 100%;
    }

    .training-table-actions .button {
        width: 100%;
    }

    .training-empty-state {
        border-left-color: transparent !important;
    }

    .training-table .training-empty-row {
        display: block;
        padding: 18px 12px;
        text-align: center;
    }

    .training-table .training-empty-row::before {
        display: none;
    }

    .training-selected-client {
        align-items: stretch;
        flex-direction: column;
    }

    .training-selected-client .button {
        width: 100%;
    }

    .training-client-options {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .training-client-option {
        grid-template-columns: minmax(0, 1fr) auto;
        min-height: 54px;
        padding: 9px 10px;
    }

    .training-client-text strong {
        font-size: .86rem;
    }

    .training-client-text small {
        font-size: .74rem;
    }

    .training-record-head {
        align-items: flex-start;
    }

    .training-rule-note {
        align-items: flex-start;
        flex-direction: column;
        gap: 4px;
    }

    .training-form-footer-actions {
        flex-direction: column-reverse;
        padding: 14px 16px;
    }

    .training-form-footer-actions .button {
        width: 100%;
    }

    .training-detail-section {
        padding: 16px;
    }

    .training-modal-backdrop {
        align-items: start;
        padding: 14px;
        overflow-y: auto;
    }

    .training-modal-actions,
    .training-quick-client-modal footer {
        display: grid;
        grid-template-columns: 1fr;
    }

    .training-quick-client-grid {
        grid-template-columns: 1fr;
    }

    .training-quick-client-modal footer .button,
    .training-modal-actions .button {
        width: 100%;
    }

    .context-status,
    .context-pill {
        max-width: 100%;
        white-space: normal;
    }

    .shortcut-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-hero,
    .dashboard-actions {
        padding: 22px;
    }

    .client-summary-strip,
    .client-filter-bar,
    .communication-history-layout,
    .communication-history-filter,
    .category-workspace,
    .clients-rich-workspace,
    .clients-workspace,
    .client-definition-grid,
    .client-field-grid,
    .client-contacts-workspace,
    .client-notes-grid,
    .client-linked-product-list,
    .operational-key-card,
    .summary-strip,
    .location-workspace {
        grid-template-columns: 1fr;
    }

    .client-detail-panel {
        position: static;
    }

    .client-table-wrap {
        max-height: none;
        min-height: 0;
    }

    .desktop-title {
        display: none;
    }

    .mobile-title {
        display: inline;
    }

    .auth-page-split {
        padding: 28px 0;
    }

    .auth-shell {
        grid-template-columns: 1fr;
        width: min(100% - 28px, 560px);
        margin: 0 auto;
    }

    .auth-panel,
    .auth-panel-wide {
        width: min(100% - 28px, 560px);
        padding: 22px;
    }

    .auth-panel-login {
        width: 100%;
    }

    .auth-info-panel {
        padding: 22px;
    }

    .auth-info-panel h2 {
        font-size: 1.7rem;
    }

    .confirm-modal__actions {
        display: grid;
        grid-template-columns: 1fr;
        justify-items: stretch;
    }

    .confirm-modal__details div {
        grid-template-columns: 1fr;
        gap: 3px;
    }

    .confirm-modal__actions .button {
        width: 100%;
    }

    .toast-stack {
        top: 14px;
        right: 14px;
        width: calc(100% - 28px);
    }

    .list-toolbar {
        justify-content: flex-start;
    }

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

    .pagination {
        justify-content: flex-start;
    }

    .pagination .summary {
        width: 100%;
        margin-right: 0;
    }

    .suppliers-shell .category-detail-panel .category-field-grid {
        grid-template-columns: 1fr;
    }

    .definition-grid {
        grid-template-columns: 1fr;
        gap: 4px;
    }

    .client-tab-heading {
        align-items: flex-start;
    }

    .client-request-card {
        grid-template-columns: 1fr;
        align-items: stretch;
    }

    .client-request-id {
        place-items: start;
        min-height: 0;
        padding: 10px 12px;
    }

    .client-request-id span,
    .client-request-id strong {
        display: inline;
    }

    .client-request-id strong {
        margin-top: 0;
        margin-left: 6px;
    }

    .client-request-card .button {
        width: 100%;
    }

    .category-page-header {
        display: grid;
    }

    .category-page-header .page-actions {
        margin-top: 0;
    }

    .knowledge-base-shell .category-page-header .page-actions,
    .internal-messages-shell .category-page-header .page-actions,
    .categories-shell:not(.products-shell) .category-page-header .page-actions,
    .products-shell .product-page-header .page-actions,
    .locations-shell .category-page-header .page-actions {
        display: grid;
        gap: 10px;
    }

    .ready-responses-shell .category-page-header .page-actions {
        display: grid;
        gap: 10px;
    }

    .category-page-header .button {
        width: 100%;
    }

    .file-policy-shell > .page-header {
        align-items: stretch;
        margin-top: 8px;
        margin-bottom: 22px;
    }

    .file-policy-shell .page-actions {
        display: grid;
        grid-template-columns: 1fr;
        gap: 10px;
        width: 100%;
    }

    .file-policy-shell .page-actions .button,
    .file-policy-shell .page-actions form {
        width: 100%;
    }

    .category-record-head {
        align-items: flex-start;
        padding: 18px;
    }

    .category-record-head .selected-client-title {
        align-items: flex-start;
    }

    .category-detail-panel .client-section {
        padding: 18px;
    }

    .category-detail-panel .category-form-actions {
        display: grid;
        grid-template-columns: 1fr;
        gap: 10px;
        width: 100%;
        margin-right: 0;
        margin-left: 0;
        justify-items: stretch;
    }

    .category-detail-panel .category-form-actions form,
    .category-detail-panel .category-form-actions .inline-action-form {
        display: block;
        width: 100%;
    }

    .category-detail-panel .category-form-actions .button,
    .category-detail-panel .category-form-actions button {
        display: flex;
        justify-content: center;
        max-width: none;
        min-width: 0;
        width: 100%;
    }

    .product-price-ranges summary {
        grid-template-columns: 1fr;
    }

    .file-policy-grid,
    .file-policy-field-grid,
    .storage-layout,
    .parameters-layout,
    .parameters-summary,
    .parameters-field-grid,
    .parameters-toggle-list {
        grid-template-columns: 1fr;
    }

    .storage-page-header,
    .parameters-page-header {
        align-items: stretch;
        margin-top: 8px;
    }

    .storage-page-header .page-actions,
    .parameters-page-header .page-actions {
        display: grid;
        grid-template-columns: 1fr;
        gap: 10px;
        width: 100%;
    }

    .storage-page-header .button,
    .parameters-page-header .button,
    .parameters-page-header form {
        width: 100%;
    }

    .parameters-field-grid label:nth-child(4) {
        grid-column: auto;
    }

    .storage-meter > div {
        display: grid;
    }

    .storage-main-card,
    .storage-card {
        overflow: hidden;
    }

    .storage-main-card .panel-inline-head {
        align-items: flex-start;
    }

    .storage-main-card .panel-inline-head > span {
        text-align: left;
    }

    .storage-table-wrap {
        overflow: visible;
    }

    .storage-table,
    .storage-table thead,
    .storage-table tbody,
    .storage-table tr,
    .storage-table th,
    .storage-table td {
        display: block;
        width: 100%;
    }

    .storage-table thead {
        display: none;
    }

    .storage-table tr {
        display: grid;
        gap: 8px;
        padding: 14px 0;
        border-bottom: 1px solid var(--border-soft);
    }

    .storage-table td {
        display: grid;
        grid-template-columns: minmax(90px, .42fr) minmax(0, 1fr);
        gap: 10px;
        padding: 0;
        border-bottom: 0;
        overflow-wrap: anywhere;
    }

    .storage-table td::before {
        color: var(--text-muted);
        font-size: .72rem;
        font-weight: 800;
        text-transform: uppercase;
        content: attr(data-label);
    }

    .storage-table td:last-child {
        grid-template-columns: 1fr;
    }

    .storage-table td:last-child::before {
        display: none;
    }

    .storage-table td:last-child .button {
        width: 100%;
    }

    .storage-total-row td:last-child {
        display: none;
    }

    .storage-row-meter {
        width: 100%;
        max-width: 120px;
        margin-right: 0;
    }

    .storage-health {
        text-align: left;
    }

    .communication-history-header {
        margin-top: 8px;
    }

    .communication-history-tabs a {
        flex: 1 1 calc(50% - 8px);
        justify-content: center;
    }

    .communication-history-main {
        overflow: hidden;
    }

    .communication-history-table-wrap {
        overflow-x: auto;
        scrollbar-width: thin;
    }

    .communication-history-table-wrap.is-all-channels {
        height: auto;
        max-height: none;
        overflow-x: auto;
    }

    .communication-history-table-wrap.is-all-channels .communication-history-table th {
        position: static;
        box-shadow: none;
    }

    .communication-history-table {
        min-width: 940px;
    }

    .communication-history-pagination,
    .communication-history-pagination > div {
        display: grid;
        grid-template-columns: 1fr;
        text-align: center;
    }

    .communication-history-modal {
        padding: 14px;
        place-items: stretch;
    }

    .communication-history-modal-panel {
        align-self: center;
        max-height: calc(100vh - 28px);
        overflow: auto;
    }

    .communication-history-modal-head,
    .communication-history-modal-actions {
        padding-right: 16px;
        padding-left: 16px;
    }

    .communication-history-modal-meta {
        grid-template-columns: 1fr;
    }

    .file-policy-field-grid label:nth-child(3),
    .file-policy-field-grid label:nth-child(4) {
        grid-column: auto;
    }

    .file-policy-switch-list label {
        align-items: flex-start;
    }

    .product-price-ranges summary small {
        text-align: left;
    }

    .product-price-range-head {
        display: none;
    }

    .product-price-range-row {
        grid-template-columns: 1fr;
    }

    .product-price-range-actions {
        justify-content: stretch;
    }

    .product-price-range-actions .button {
        width: 100%;
    }

    .product-price-range-row label span {
        display: block;
        color: var(--text-muted);
        font-size: .76rem;
    }

    .product-price-range-remove {
        width: 100%;
    }

    .product-tabs {
        padding: 0 18px;
    }

    .product-proposal-hero,
    .product-proposal-document {
        grid-template-columns: 1fr;
    }

    .product-proposal-document .button {
        width: 100%;
    }

    .location-detail-actions {
        display: grid;
        grid-template-columns: 1fr;
        gap: 10px;
        width: 100%;
        margin: 18px 0 0;
        justify-items: stretch;
    }

    .location-detail-actions .button,
    .location-detail-actions button {
        display: flex;
        justify-content: center;
        max-width: none;
        min-width: 0;
        width: 100%;
    }

    .client-tab-heading .button-primary {
        width: auto;
    }

    .client-contact-flags {
        grid-template-columns: 1fr;
    }

    .client-contact-flag-communication > div,
    .client-contact-option-group-communication .client-checkbox-grid {
        grid-template-columns: 1fr;
    }

    .client-checkbox-grid {
        grid-template-columns: 1fr;
    }

    .client-checkbox-grid label {
        justify-content: flex-start;
        min-height: 44px;
        line-height: 1.2;
        text-align: left;
    }

    .client-checkbox-grid input {
        flex: 0 0 auto;
    }

    .client-document-card {
        padding: 14px;
    }

    .client-document-summary {
        grid-template-columns: 1fr;
        justify-items: center;
        gap: 10px;
        padding: 14px 12px;
        text-align: center;
    }

    .client-document-icon {
        width: 50px;
        height: 50px;
    }

    .client-document-summary strong {
        font-size: .96rem;
    }

    .client-document-summary p {
        font-size: .84rem;
    }

    .client-document-summary small {
        font-size: .8rem;
    }

    .client-document-actions {
        justify-content: center;
        gap: 8px;
    }

    .client-document-actions a,
    .client-document-actions button {
        min-width: 58px;
        padding-right: 12px;
        padding-left: 12px;
    }

    .client-document-guidance {
        display: grid;
        gap: 8px;
    }

    .client-note-modal {
        align-items: center;
        padding: 14px;
    }

    .client-note-detail-card {
        max-height: calc(100vh - 28px);
        overflow: auto;
    }

    .client-note-detail-card header {
        align-items: flex-start;
    }

    .client-note-modal-head-actions {
        flex-shrink: 0;
    }

    .client-rich-detail-panel .client-inline-actions {
        display: grid;
        grid-template-columns: 1fr;
        justify-items: stretch;
    }

    .client-rich-detail-panel .client-inline-actions .button {
        width: 100%;
    }

    .client-note-read + .client-inline-actions {
        display: grid;
        grid-template-columns: 1fr;
        justify-items: stretch;
    }

    .client-note-read + .client-inline-actions .button {
        width: 100%;
    }

    .client-note-read .form-actions {
        display: grid;
        justify-items: stretch;
    }

    .client-note-read .form-actions .button {
        width: 100%;
    }
}
.contract-template-metrics {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 18px;
}

.contract-template-metrics article,
.contract-template-hero {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    box-shadow: var(--shadow-sm);
}

.contract-template-metrics article {
    padding: 18px;
}

.contract-template-metrics span,
.contract-template-hero span {
    display: block;
    color: var(--accent);
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.contract-template-metrics strong {
    display: block;
    margin-top: 6px;
    color: var(--text);
    font-size: 1.9rem;
}

.contract-template-metrics small,
.contract-template-hero small,
.contract-template-list p,
.contract-template-side p {
    color: var(--text-muted);
}

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

.contract-template-row {
    display: grid;
    grid-template-columns: minmax(0, 1.16fr) minmax(460px, .84fr) minmax(122px, auto);
    align-items: center;
    gap: 18px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    transition: background .18s ease, border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

.contract-template-row:hover,
.contract-template-row:focus-within {
    border-color: #b8d2e6;
    background: #fbfdff;
    box-shadow: 0 12px 24px rgba(7, 86, 106, .08);
}

.contract-template-row h3 {
    margin: 4px 0 6px;
    color: var(--text);
    font-size: 1.05rem;
}

.contract-template-row p {
    margin: 0;
    line-height: 1.5;
}

.contract-template-row dl {
    display: grid;
    grid-template-columns: repeat(5, minmax(68px, 1fr));
    gap: 10px 14px;
    margin: 0;
}

.contract-template-row dt {
    color: var(--text-soft);
    font-size: .7rem;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.contract-template-row dd {
    margin: 3px 0 0;
    color: var(--text);
    font-weight: 800;
}

.contract-template-status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    border-radius: 999px;
    padding: 5px 10px;
    font-size: .72rem;
    font-weight: 900;
    line-height: 1;
    white-space: nowrap;
}

.contract-template-status-badge.active,
.contract-template-status-badge.approved {
    background: #dff8ee;
    color: #007a51;
}

.contract-template-status-badge.draft,
.contract-template-status-badge.review {
    background: #fff1d8;
    color: #b35a00;
}

.contract-template-status-badge.inactive {
    background: #edf1f5;
    color: #516071;
}

.contract-template-row-actions {
    display: grid;
    gap: 8px;
}

.contract-template-row-actions form {
    display: grid;
    margin: 0;
}

.contract-minute-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 18px;
    align-items: start;
}

.contract-minute-main,
.contract-minute-variable-list {
    min-width: 0;
}

.contract-minute-existing-card {
    margin-bottom: 18px;
}

.contract-minute-flow-card {
    position: relative;
    overflow: hidden;
}

.contract-minute-flow-card::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 4px;
    background: #12a7c2;
}

.contract-minute-create-card::before {
    background: #2563eb;
}

.contract-minute-template-row .button[disabled] {
    cursor: not-allowed;
    opacity: .68;
}

.contract-minute-variable-list {
    display: grid;
    gap: 8px;
    margin-top: 14px;
}

.contract-minute-variable-list article {
    display: grid;
    gap: 3px;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.contract-minute-variable-list strong {
    color: var(--accent);
    font-size: .82rem;
}

.contract-minute-variable-list span {
    color: var(--text);
    font-size: .78rem;
    font-weight: 800;
}

.contract-minute-variable-list small {
    color: var(--text-muted);
    line-height: 1.35;
}

.contract-template-section-actions .button-warning {
    border-color: rgba(245, 158, 11, .42);
    background: #fff8e8;
    color: #a16207;
}

.contract-template-section-actions .button-warning:hover,
.contract-template-section-actions .button-warning:focus {
    border-color: rgba(245, 158, 11, .65);
    background: #fef3c7;
    color: #854d0e;
    box-shadow: 0 10px 22px rgba(245, 158, 11, .14);
}

.contract-template-section-heading {
    display: grid;
    gap: 4px;
}

.contract-section-kicker small {
    color: #dc2626;
    font-size: .74rem;
    font-weight: 800;
    letter-spacing: 0;
    text-transform: none;
}

.contract-section-inline-notice {
    min-height: 18px;
    color: #a16207;
    font-size: .78rem;
    font-weight: 800;
    opacity: 0;
    transition: opacity .18s ease;
}

.contract-section-inline-notice.is-visible {
    opacity: 1;
}

.contract-template-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(260px, 330px);
    align-items: center;
    gap: 18px;
    margin-bottom: 18px;
    padding: 20px;
}

.contract-template-hero h2 {
    margin: 5px 0 6px;
    color: var(--text);
    font-size: 1.35rem;
}

.contract-template-hero p {
    margin: 0;
    color: var(--text-muted);
    line-height: 1.55;
}

.contract-template-hero aside {
    display: grid;
    gap: 5px;
    justify-items: end;
    text-align: right;
}

.contract-template-hero aside strong {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 130px;
    border-radius: 999px;
    padding: 7px 14px;
    background: #e6fff2;
    color: #047857;
}

.contract-template-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 18px;
    align-items: start;
}

.contract-template-main,
.contract-template-side,
.contract-template-sections,
.contract-template-variable-groups {
    display: grid;
    gap: 14px;
}

.contract-template-side {
    position: sticky;
    top: 18px;
    max-height: calc(100vh - 36px);
    overflow-x: hidden;
    overflow-y: auto;
    padding-right: 4px;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
}

.contract-template-section {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) 96px;
    gap: 12px;
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.contract-template-section.is-inactive {
    opacity: .58;
}

.contract-template-section.is-inactive .contract-template-section-fields {
    filter: grayscale(.25);
}

.contract-template-section-order {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 8px;
    background: #eef6ff;
    color: var(--accent);
    font-weight: 900;
}

.contract-template-section-fields {
    display: grid;
    gap: 10px;
}

.contract-template-section-fields label,
.contract-template-side label {
    display: grid;
    gap: 6px;
    color: var(--text-soft);
    font-size: .78rem;
    font-weight: 800;
}

.contract-template-section-fields input,
.contract-template-section-fields select,
.contract-template-section-fields textarea {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 11px 12px;
    color: var(--text);
    font: inherit;
    font-size: .92rem;
}

.contract-template-section-fields textarea {
    min-height: 128px;
    line-height: 1.55;
    resize: vertical;
}

.contract-template-signature-preview {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px 34px;
    margin-top: 4px;
    border: 1px dashed rgba(14, 116, 144, .35);
    border-radius: 8px;
    padding: 18px;
    background: #fbfdff;
}

.contract-template-signature-preview .contract-preview-signature-date {
    grid-column: 1 / -1;
    color: var(--text-muted);
    font-size: .82rem;
    margin: 0;
    text-align: center;
}

.contract-template-signature-preview .contract-preview-signature-entry {
    display: grid;
    gap: 5px;
    min-height: 54px;
    padding-top: 7px;
    text-align: center;
}

.contract-template-signature-preview .contract-preview-signature-entry.wide {
    grid-column: 1 / -1;
    max-width: 520px;
    justify-self: center;
    width: 100%;
}

.contract-template-signature-preview .contract-preview-signature-entry > span {
    display: block;
    border-top: 1px solid #1f2937;
    min-height: 1px;
}

.contract-template-signature-preview strong {
    color: var(--text);
    font-size: .78rem;
}

.contract-template-signature-preview .contract-preview-signature-label strong,
.contract-template-signature-preview .contract-preview-signature-label em {
    display: inline;
}

.contract-template-signature-preview .contract-preview-signature-label strong + em::before {
    content: ": ";
}

.contract-template-signature-preview em,
.contract-template-signature-preview small {
    color: var(--text-muted);
    font-size: .74rem;
    font-style: normal;
}

.contract-template-signature-preview em {
    color: var(--text);
}

.contract-template-signature-preview small {
    display: block;
}

.contract-template-section-actions {
    display: grid;
    align-content: start;
    gap: 7px;
}

.contract-template-section-flag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 30px;
    border: 1px solid rgba(14, 116, 144, .24);
    border-radius: 999px;
    padding: 4px 8px;
    background: #eefaff;
    color: var(--accent);
    font-size: .72rem;
    font-weight: 800;
}

.contract-template-variable-groups article {
    display: grid;
    gap: 8px;
}

.contract-template-variable-groups h3 {
    margin: 0;
    color: var(--text);
    font-size: .9rem;
}

.contract-template-variable-groups button {
    display: grid;
    gap: 3px;
    width: 100%;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 9px 10px;
    background: #fff;
    color: var(--text);
    text-align: left;
    cursor: pointer;
    transition: background .18s ease, border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}

.contract-template-variable-groups button:hover,
.contract-template-variable-groups button:focus {
    border-color: #89bfd3;
    background: #f0fbff;
    box-shadow: 0 8px 18px rgba(7, 86, 106, .1);
    outline: none;
    transform: translateY(-1px);
}

.contract-template-variable-groups button strong {
    color: var(--accent);
    font-size: .82rem;
}

.contract-template-variable-groups button span {
    color: var(--text-muted);
    font-size: .76rem;
}

.contract-template-appearance {
    gap: 10px;
}

.contract-template-appearance select {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 10px 11px;
    color: var(--text);
    font: inherit;
    font-size: .86rem;
}

.contract-template-paper-preview {
    display: grid;
    gap: 8px;
    min-height: 150px;
    margin-top: 2px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    overflow: hidden;
}

.contract-template-paper-preview span {
    display: block;
    height: 28px;
    background: linear-gradient(135deg, #dff4ff, #7bbde6 52%, #ecf8ff);
}

.contract-template-paper-preview strong,
.contract-template-paper-preview small {
    padding: 0 14px;
}

.contract-template-paper-preview strong {
    align-self: end;
    color: var(--text);
    font-size: .86rem;
    line-height: 1.35;
    text-align: center;
}

.contract-template-paper-preview small {
    color: var(--text-muted);
    font-size: .74rem;
    text-align: center;
}

.contract-template-paper-preview em {
    display: block;
    align-self: end;
    height: 24px;
    margin: 0 14px 12px auto;
    width: 86px;
    border: 1px dashed rgba(14, 116, 144, .35);
    border-radius: 6px;
    background: #f8fcff;
}

.contract-template-notes p {
    margin-bottom: 0;
}

.contract-format-help-trigger {
    width: 100%;
    margin-top: 8px;
    border: 1px solid rgba(14, 116, 144, .26);
    border-radius: 6px;
    padding: 11px 12px;
    background: #f3fbff;
    color: var(--accent);
    font: inherit;
    font-size: .82rem;
    font-weight: 800;
    text-align: left;
    cursor: pointer;
}

.contract-format-help-trigger:hover,
.contract-format-help-trigger:focus {
    border-color: rgba(14, 116, 144, .46);
    background: #eaf8ff;
    outline: none;
}

.contract-template-bottom-actions {
    padding-top: 22px;
    padding-bottom: 28px;
}

.contract-template-preview-modal {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: grid;
    place-items: center;
    padding: 22px;
    background: rgba(15, 23, 42, .42);
}

.contract-template-preview-modal[hidden] {
    display: none;
}

.contract-template-preview-modal > section {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    width: min(900px, 100%);
    max-height: min(860px, calc(100vh - 44px));
    border-radius: 8px;
    background: #eef5f8;
    box-shadow: 0 24px 70px rgba(15, 23, 42, .24);
    overflow: hidden;
}

.rental-minute-preview-modal > section {
    grid-template-rows: auto auto minmax(0, 1fr);
}

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

.contract-template-preview-modal h2 {
    margin: 3px 0 0;
    color: var(--text);
    font-size: 1.15rem;
}

.contract-template-preview-modal header button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    cursor: pointer;
}

.contract-preview-pending-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 10px 18px;
    border-bottom: 1px solid #efd38b;
    background: #fffbeb;
    color: #744210;
}

.contract-preview-pending-nav[hidden] {
    display: none;
}

.contract-preview-pending-summary {
    display: grid;
    gap: 2px;
    min-width: 0;
}

.contract-preview-pending-summary strong {
    font-size: .86rem;
}

.contract-preview-pending-summary span {
    color: #8a641a;
    font-size: .76rem;
}

.contract-preview-pending-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
}

.contract-preview-pending-actions .button {
    min-height: 34px;
    border-color: #dfbd68;
    background: #fff;
    color: #744210;
    white-space: nowrap;
}

.contract-preview-pending-actions .button:hover:not(:disabled),
.contract-preview-pending-actions .button:focus-visible {
    border-color: #b7791f;
    background: #fff8dc;
}

.contract-preview-pending-position {
    min-width: 54px;
    color: #744210;
    font-size: .8rem;
    font-weight: 800;
    text-align: center;
}

.contract-preview-pending {
    border-radius: 3px;
    padding: 0 .12em;
    background: #fff0ad;
    box-shadow: inset 0 -2px 0 #d97706;
    color: inherit;
    font-weight: 700;
    text-decoration: none;
}

.contract-preview-pending.is-current,
.contract-preview-pending:focus {
    background: #ffd35c;
    outline: 3px solid rgba(180, 83, 9, .28);
    outline-offset: 2px;
}

.contract-format-help-modal > section {
    width: min(620px, 100%);
    max-height: min(720px, calc(100vh - 44px));
}

.contract-format-help-body {
    display: grid;
    gap: 14px;
    padding: 18px;
    overflow-y: auto;
    background: #fff;
}

.contract-format-help-body p {
    margin: 0;
    color: var(--text-muted);
    line-height: 1.5;
}

.contract-format-help-body article {
    display: grid;
    gap: 7px;
}

.contract-format-help-body h3 {
    margin: 0;
    color: var(--text);
    font-size: .92rem;
}

.contract-format-help-body pre {
    margin: 0;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 12px;
    background: #f8fcff;
    color: var(--text);
    font: 800 .82rem/1.55 Consolas, 'Courier New', monospace;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.contract-template-preview-paper {
    display: grid;
    gap: 22px;
    align-content: start;
    margin: 18px auto;
    width: min(720px, calc(100% - 36px));
    min-height: 760px;
    padding: 52px 58px;
    background: #fff;
    color: #111827;
    box-shadow: 0 12px 40px rgba(15, 23, 42, .14);
    overflow-y: auto;
}

.contract-template-preview-paper article {
    display: grid;
    gap: 10px;
}

.contract-template-preview-paper h3 {
    margin: 0;
    color: #111827;
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 1rem;
    text-align: center;
}

.contract-template-preview-paper p {
    margin: 0;
    font-family: Georgia, 'Times New Roman', serif;
    font-size: .96rem;
    line-height: 1.65;
    text-align: justify;
}

.contract-template-preview-paper p strong {
    font-weight: 800;
}

.contract-preview-table-wrap {
    margin: 10px 0 16px;
    overflow-x: auto;
}

.contract-preview-table {
    width: 100%;
    border: 1px solid #111827;
    border-collapse: collapse;
    font-family: Georgia, 'Times New Roman', serif;
    font-size: .92rem;
    line-height: 1.35;
}

.contract-preview-table th,
.contract-preview-table td {
    border: 1px solid #111827;
    padding: 5px 7px;
    color: #111827;
    vertical-align: top;
}

.contract-preview-table th {
    background: #f8fafc;
    font-weight: 800;
    text-align: left;
}

.contract-preview-table tbody tr:last-child td {
    border-bottom: 1px solid #111827;
}

.contract-preview-table td:last-child,
.contract-preview-table th:last-child {
    text-align: right;
}

.contract-template-preview-signatures {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px 36px;
    margin-top: 18px;
}

.contract-template-preview-signatures h3,
.contract-template-preview-signatures p {
    grid-column: 1 / -1;
}

.contract-template-preview-signatures .contract-preview-signature-date {
    margin-top: 8px;
    text-align: center;
}

.contract-template-preview-signatures .contract-preview-signature-entry {
    display: grid;
    gap: 5px;
    align-content: start;
    min-height: 106px;
    padding-top: 28px;
    border-top: 1px solid #111827;
    text-align: center;
}

.contract-template-preview-signatures .contract-signature-table {
    grid-column: 1 / -1;
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
}

.contract-template-preview-signatures .contract-signature-table td {
    width: 50%;
    padding: 0 18px;
    border: 0;
    vertical-align: top;
}

.contract-template-preview-signatures .contract-signature-table td[colspan="2"] {
    width: 100%;
}

.contract-template-preview-signatures .wide {
    grid-column: 1 / -1;
    justify-self: center;
    width: min(520px, 100%);
}

.contract-template-preview-signatures strong {
    font-size: .78rem;
}

.contract-template-preview-signatures .contract-preview-signature-label {
    font-size: .78rem;
    line-height: 1.35;
}

.contract-template-preview-signatures .contract-preview-signature-label strong,
.contract-template-preview-signatures .contract-preview-signature-label em {
    display: inline;
}

.contract-template-preview-signatures .contract-preview-signature-label strong + em::before {
    content: ": ";
}

.contract-template-preview-signatures em,
.contract-template-preview-signatures small {
    color: #526877;
    font-family: Georgia, 'Times New Roman', serif;
    font-size: .78rem;
    font-style: normal;
    line-height: 1.35;
}

.contract-template-preview-signatures em {
    color: #111827;
}

.contract-template-preview-signatures small {
    display: block;
}

.contract-document-body {
    margin: 0;
    background: #e8f0f4;
    color: var(--text);
}

.contract-document-toolbar {
    position: sticky;
    top: 0;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px 24px;
    border-bottom: 1px solid var(--border);
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 10px 28px rgba(15, 23, 42, .08);
}

.contract-document-toolbar h1 {
    margin: 3px 0;
    color: var(--text);
    font-size: 1.15rem;
}

.contract-document-toolbar p {
    margin: 0;
    color: var(--text-muted);
}

.contract-document-toolbar > div:last-child {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
}

.contract-document-actions small {
    flex-basis: 100%;
    color: var(--text-muted);
    font-size: .78rem;
    text-align: right;
}

.contract-document-stage {
    padding: 26px 18px 42px;
}

.contract-document-paper {
    width: min(210mm, calc(100% - 18px));
    min-height: 297mm;
    overflow: visible;
}

.contract-document-institutional-band {
    margin: -52px -58px 28px;
}

.contract-document-institutional-band img {
    display: block;
    width: 100%;
    height: 42px;
    object-fit: cover;
}

.contract-document-footer-logo {
    display: flex;
    justify-content: flex-end;
    margin-top: 32px;
}

.contract-document-footer-logo img {
    display: block;
    width: 116px;
    height: auto;
}

@media print {
    @page {
        size: A4;
        margin: 18mm 16mm;
    }

    html,
    body {
        width: 210mm;
        min-height: 297mm;
    }

    * {
        print-color-adjust: exact;
        -webkit-print-color-adjust: exact;
    }

    .contract-document-toolbar {
        display: none;
    }

    .contract-document-body,
    .contract-document-stage {
        background: #fff;
        padding: 0;
    }

    .contract-document-paper {
        width: auto;
        min-height: 0;
        margin: 0;
        padding: 0;
        box-shadow: none;
        overflow: visible;
    }

    .contract-document-institutional-band {
        margin: -8mm 0 4mm;
    }

    .contract-document-institutional-band img {
        height: 8mm;
    }

    .contract-document-footer-logo {
        display: flex;
        justify-content: flex-end;
        margin-top: 0;
        opacity: .9;
    }

    .contract-document-footer-logo img {
        width: 21mm;
        transform: translateY(6mm);
    }


    .contract-template-preview-paper {
        display: block;
        gap: 0;
    }

    .contract-template-preview-paper article {
        break-inside: auto;
        page-break-inside: auto;
        margin-bottom: 12px;
    }

    .contract-template-preview-paper h3 {
        break-after: avoid;
        page-break-after: avoid;
    }

    .contract-template-preview-paper p {
        orphans: 3;
        widows: 3;
    }

    .contract-preview-table-wrap,
    .contract-template-preview-signatures {
        break-inside: avoid-page;
        page-break-inside: avoid;
    }

    .contract-preview-table {
        break-inside: auto;
    }

    .contract-preview-table tr {
        break-inside: avoid;
        page-break-inside: avoid;
    }

    .contract-template-preview-signatures {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .contract-template-preview-signatures h3,
    .contract-template-preview-signatures p,
    .contract-template-preview-signatures .wide {
        grid-column: 1 / -1;
    }
}

@media (max-width: 1180px) {
    .contract-template-metrics,
    .contract-template-row dl {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .contract-template-row,
    .contract-template-layout,
    .contract-minute-layout {
        grid-template-columns: 1fr;
    }

    .contract-template-side {
        position: static;
        max-height: none;
        overflow: visible;
        padding-right: 0;
    }
}

@media (max-width: 760px) {
    .contract-template-metrics,
    .contract-template-hero,
    .contract-template-row dl,
    .contract-template-section,
    .contract-template-signature-preview,
    .contract-template-preview-signatures {
        grid-template-columns: 1fr;
    }

    .contract-template-signature-preview .wide,
    .contract-template-preview-signatures h3,
    .contract-template-preview-signatures p {
        grid-column: auto;
    }

    .contract-template-hero aside {
        justify-items: start;
        text-align: left;
    }

    .contract-template-section-actions {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .contract-card-head [data-contract-template-add-section] {
        margin-bottom: 14px;
    }

    .contract-template-preview-paper {
        width: calc(100% - 22px);
        min-height: 620px;
        padding: 34px 24px;
    }

    .contract-preview-pending-nav {
        align-items: stretch;
        flex-direction: column;
        gap: 9px;
        padding: 10px 12px;
    }

    .contract-preview-pending-actions {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        justify-content: stretch;
    }

    .contract-preview-pending-actions .button {
        justify-content: center;
        min-width: 0;
        padding-inline: 8px;
    }

    .contract-preview-pending-position {
        grid-column: 1 / -1;
        grid-row: 2;
        justify-self: center;
    }
}

@media (max-width: 920px) {
    .parameters-session-setting,
    .parameters-session-timeline { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 560px) {
    .parameters-session-setting,
    .parameters-session-timeline { grid-template-columns: 1fr; }
}

/* Rental contracts */
.rental-contracts-page { max-width: 1420px; margin: 0 auto; }
.rental-contract-filter { grid-template-columns: minmax(280px, 1.8fr) minmax(190px, 1fr) minmax(190px, 1fr) auto auto; }
.rental-contract-list { display: grid; gap: 10px; padding: 14px 18px 18px; }
.rental-contract-list-head {
    display: grid;
    grid-template-columns: 56px minmax(280px, 2fr) minmax(130px, .8fr) minmax(150px, .8fr) minmax(140px, .8fr) auto;
    gap: 18px;
    padding: 0 16px 2px;
    color: #65758b;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
}
.rental-contract-list-head span:last-child { text-align: right; }
.rental-contract-list-item {
    display: grid;
    grid-template-columns: 56px minmax(280px, 2fr) minmax(130px, .8fr) minmax(150px, .8fr) minmax(140px, .8fr) auto;
    align-items: center;
    gap: 18px;
    min-height: 92px;
    padding: 14px 16px;
    border: 1px solid #dfe6ef;
    border-radius: 16px;
    background: #fff;
    transition: background .18s ease, border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.rental-contract-list-item:hover,
.rental-contract-list-item:focus-within {
    border-color: #b8d2e6;
    background: #eef8fb;
    box-shadow: inset 4px 0 0 rgba(23, 101, 118, .38), 0 12px 24px rgba(7, 86, 106, .08);
    transform: translateY(-1px);
}
.rental-contract-list-item > div { display: grid; gap: 4px; }
.rental-contract-list-item small { color: #61728a; }
.rental-contract-id {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    border-radius: 14px;
    color: #155bd7;
    background: #edf3ff;
    font-weight: 800;
}
.rental-contract-party strong { color: #071c35; font-size: 15px; }
.rental-contract-status.draft { background: #eef1f5; color: #42536a; }
.rental-contract-status.review,
.rental-contract-status.signature,
.rental-contract-status.ending { background: #fff1d8; color: #a45700; }
.rental-contract-status.active { background: #dcf8ef; color: #007b55; }
.rental-contract-status.closed,
.rental-contract-status.canceled { background: #eef1f5; color: #5c6878; }
.rental-contract-list-item .rental-contract-status {
    width: max-content;
    max-width: 100%;
    justify-self: start;
}
.rental-contract-mobile-status { display: none; }
.rental-contract-page-header { max-width: 1408px; margin-left: auto; margin-right: auto; }
.rental-contract-hero {
    max-width: 1408px;
    margin: 0 auto 18px;
    padding: 20px 22px;
    border: 1px solid #dbe3ec;
    border-top: 4px solid #2c66f5;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 16px 38px rgba(18, 48, 84, .08);
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 24px;
}
.rental-contract-hero h2 { margin: 6px 0; color: #071c35; font-size: 21px; }
.rental-contract-hero p { margin: 0 0 9px; color: #5d7089; }
.rental-contract-hero dl { margin: 0; display: grid; grid-template-columns: repeat(2, minmax(130px, 1fr)); gap: 14px 26px; text-align: right; }
.rental-contract-hero dt { color: #65758b; font-size: 12px; font-weight: 700; }
.rental-contract-hero dd { margin: 3px 0 0; color: #071c35; font-weight: 800; }
.rental-contract-lock-note { margin-left: 8px; color: #6b7482; font-size: 12px; }
.rental-contract-status-actions { display: inline-flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 0 10px; vertical-align: middle; }
.rental-contract-status-help {
    display: block;
    max-width: 760px;
    margin-top: 9px;
    color: #65758b;
    line-height: 1.45;
}
.rental-contract-detail { max-width: 1408px; margin-left: auto; margin-right: auto; }
.rental-contract-tabs { margin-bottom: 16px; }
.rental-contract-tabs a { white-space: nowrap; }
.rental-contract-main-form { display: grid; gap: 16px; padding: 0 16px 16px; }
.rental-contract-form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.rental-contract-form-grid > .rental-form-section,
.rental-contract-notes,
.rental-contract-document-layout > *,
.rental-contract-attachments-layout > * { margin: 0; }
.rental-contract-form-grid > .rental-form-section { align-content: start; }
[data-rental-guarantor-field][hidden],
[data-rental-deposit-field][hidden] { display: none !important; }
.rental-association-picker { position: relative; }
.rental-picker-results { z-index: 30; }
.rental-contract-fixed-party {
    display: grid;
    gap: 5px;
    min-height: 82px;
    padding: 14px;
    border: 1px solid #dce5ef;
    border-radius: 12px;
    background: #f8fafc;
}
.rental-contract-fixed-party span,
.rental-contract-fixed-party small { color: #65758b; font-size: 12px; }
.rental-contract-fixed-party strong { color: #09203a; }
.rental-contract-checkbox { display: flex !important; flex-direction: row !important; align-items: center; gap: 8px; min-height: 44px; }
.rental-contract-checkbox input { width: auto !important; }
.rental-contract-responsibilities { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
.rental-contract-responsibilities label {
    display: grid;
    grid-template-columns: minmax(72px, 1fr) minmax(100px, 120px);
    align-items: center;
    gap: 10px;
    padding: 9px 10px;
    border: 1px solid #d8e3ec;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 1px 2px rgba(15, 42, 63, .04);
}
.rental-contract-responsibilities label > span { color: #17324d; font-size: 13px; font-weight: 700; }
.rental-contract-responsibilities select {
    width: 100%;
    min-width: 0;
    min-height: 38px;
    padding: 7px 30px 7px 10px;
    border: 1px solid #cbd9e5;
    border-radius: 9px;
    background-color: #f8fbfd;
    color: #17324d;
    font: inherit;
}
.rental-contract-notes textarea,
.rental-contract-document-editor textarea { width: 100%; resize: vertical; }
.rental-contract-notes textarea {
    min-height: 112px;
    padding: 12px 14px;
    border: 1px solid #cbd9e5;
    border-radius: 12px;
    background: #fff;
    color: #17324d;
    font: inherit;
    line-height: 1.5;
}
.rental-contract-notes textarea:focus {
    outline: 2px solid rgba(9, 127, 151, .16);
    border-color: var(--brand);
}
.rental-contract-document-layout { display: grid; grid-template-columns: minmax(0, 2.4fr) minmax(280px, .8fr); gap: 14px; padding: 0 16px 16px; }
.rental-document-workspace,
.rental-contract-document-side { min-width: 0; display: grid; gap: 14px; align-content: start; }
.rental-contract-model-card {
    padding: 16px;
    border: 1px solid #c7d9e5;
    border-radius: 14px;
    background: #fff;
}
.rental-contract-model-card > header,
.rental-minute-editor-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
}
.rental-contract-model-card h2,
.rental-minute-editor-head h2 { margin: 3px 0 0; font-size: 20px; }
.rental-contract-model-badge {
    padding: 7px 11px;
    border-radius: 999px;
    background: #edf2f6;
    color: #17324d;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
}
.rental-contract-model-controls {
    display: grid;
    grid-template-columns: minmax(210px, .9fr) minmax(240px, 1.15fr) auto;
    gap: 14px;
    align-items: center;
    margin-top: 14px;
    padding: 13px;
    border: 1px solid #bfe5ed;
    border-radius: 13px;
    background: #f2fbfd;
}
.rental-contract-model-check { display: flex; align-items: center; gap: 10px; cursor: pointer; }
.rental-contract-model-check input { width: 17px; height: 17px; accent-color: var(--brand); }
.rental-contract-model-check span,
.rental-contract-model-name { display: grid; gap: 3px; min-width: 0; }
.rental-contract-model-check small,
.rental-contract-model-name small,
.rental-contract-model-name span { color: #65758b; }
.rental-contract-model-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
.rental-contract-export-form { display: none; }
.rental-contract-export-guidance {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 12px;
    margin: 10px 2px 0;
    color: #65758b;
    font-size: 12px;
    line-height: 1.45;
}
.rental-contract-export-guidance strong { color: #8a6114; }
.contract-export-state-mark {
    margin: 0 0 28px;
    padding: 9px 12px;
    border: 2px solid #9a741d;
    border-radius: 6px;
    color: #80600f;
    font: 800 18px/1.2 Arial, sans-serif;
    letter-spacing: .18em;
    text-align: center;
}
.contract-export-state-mark.canceled {
    border-color: #b13a3a;
    color: #a12626;
}
.rental-contract-export-paper,
.rental-contract-export-paper h3,
.rental-contract-export-paper p,
.rental-contract-export-paper table { color: #000; }
.rental-contract-minute-editor {
    padding: 16px;
    border: 1px solid #c7d9e5;
    border-radius: 14px;
    background: #fff;
}
.rental-contract-minute-editor fieldset {
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
}
.rental-contract-minute-editor fieldset:disabled { opacity: .72; }
.rental-contract-minute-editor .contract-template-sections { margin-top: 14px; }
.rental-contract-minute-empty { margin: 0; }
.rental-contract-minute-empty p { margin: 6px 0 0; color: #65758b; line-height: 1.55; }
.rental-contract-document-side { position: sticky; top: 18px; }
.rental-contract-document-editor textarea {
    margin-top: 14px;
    padding: 18px;
    border: 1px solid #d8e2ed;
    border-radius: 14px;
    background: #fcfdff;
    color: #13263e;
    font: 14px/1.7 Consolas, "Courier New", monospace;
}
.rental-contract-snapshot-panel { align-self: start; display: grid; gap: 10px; }
.rental-contract-snapshot-panel article { display: grid; gap: 4px; padding: 12px; border: 1px solid #e1e7ef; border-radius: 12px; }
.rental-contract-snapshot-panel small,
.rental-contract-snapshot-panel span { color: #65758b; }
.rental-contract-minute-variables { min-width: 0; }
.rental-contract-minute-variables .contract-template-variable-groups {
    max-height: 52vh;
    overflow: auto;
    padding-right: 4px;
}
.rental-contract-minute-variables button:disabled { cursor: not-allowed; opacity: .58; }
.rental-contract-format-help h2 { margin: 4px 0 8px; font-size: 18px; }
.rental-contract-format-help p { margin: 0; color: #65758b; line-height: 1.5; }
.rental-contract-bottom-actions {
    margin: 4px 16px 18px;
    padding-top: 18px;
    border-top: 1px solid #e1e7ef;
}
.rental-contract-attachments-layout { display: grid; grid-template-columns: minmax(420px, .95fr) minmax(0, 1.55fr); gap: 14px; align-items: start; padding: 0 16px 16px; }
.rental-contract-attachments-layout .rental-document-form { padding: 18px; }
.rental-contract-document-list { display: grid; gap: 10px; }
.rental-contract-document-description {
    display: block;
    margin-top: 8px;
    padding: 8px 10px;
    border-left: 3px solid rgba(10, 164, 196, .42);
    border-radius: 0 7px 7px 0;
    background: rgba(255, 255, 255, .72);
    color: #425970;
    font-size: .84rem;
    line-height: 1.45;
    overflow-wrap: anywhere;
}
.rental-contract-future-panel { min-height: 250px; margin: 0 16px 16px; }
.rental-contract-history { min-height: 250px; margin: 0 16px 16px; }
.rental-contract-timeline { display: grid; gap: 0; margin-top: 8px; }
.rental-contract-timeline article { display: grid; grid-template-columns: 18px 1fr; gap: 12px; padding-bottom: 18px; position: relative; }
.rental-contract-timeline article > span { width: 12px; height: 12px; margin-top: 4px; border-radius: 50%; background: #12a8c8; box-shadow: 0 0 0 4px #e4f8fc; }
.rental-contract-timeline article::after { content: ""; position: absolute; left: 5px; top: 20px; bottom: 2px; width: 2px; background: #dce7ee; }
.rental-contract-timeline article:last-child::after { display: none; }
.rental-contract-timeline p { margin: 4px 0; color: #53667e; }
.rental-contract-timeline small { color: #7a8899; }

@media (max-width: 1100px) {
    .rental-contract-filter { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .rental-contract-list-head { display: none; }
    .rental-contract-list-item { grid-template-columns: 48px minmax(220px, 1.5fr) repeat(2, minmax(120px, .7fr)) auto; }
    .rental-contract-list-item > div:nth-of-type(4) { display: none; }
    .rental-contract-form-grid,
    .rental-contract-document-layout,
    .rental-contract-attachments-layout { grid-template-columns: 1fr; }
    .rental-contract-document-side { position: static; }
    .rental-contract-model-controls { grid-template-columns: 1fr; }
    .rental-contract-model-actions { justify-content: flex-start; }
}
@media (max-width: 760px) {
    .rental-contract-list-item { grid-template-columns: 44px 1fr auto; gap: 10px; }
    .rental-contract-list-item > div:not(.rental-contract-party) { display: none; }
    .rental-contract-mobile-status {
        display: flex;
        margin-top: 5px;
    }
    .rental-contract-hero { grid-template-columns: minmax(0, 1fr); }
    .rental-contract-hero > div { min-width: 0; }
    .rental-contract-lock-note {
        display: block;
        max-width: 100%;
        margin: 8px 0 0;
        line-height: 1.4;
        overflow-wrap: anywhere;
    }
    .rental-contract-status-actions {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        width: 100%;
        margin: 12px 0 0;
    }
    .rental-contract-status-actions form,
    .rental-contract-status-actions .button {
        width: 100%;
    }
    .rental-contract-status-actions .button {
        justify-content: center;
        white-space: normal;
    }
    .rental-contract-status-help {
        width: 100%;
        max-width: 100%;
        overflow-wrap: anywhere;
    }
    .rental-contract-model-actions .button,
    .rental-contract-bottom-actions .button {
        flex: 1 1 140px;
    }
    .rental-contract-export-guidance { display: grid; }
    .rental-contract-export-body .contract-document-toolbar {
        align-items: stretch;
        flex-direction: column;
    }
    .rental-contract-export-body .contract-document-actions {
        justify-content: stretch;
    }
    .rental-contract-export-body .contract-document-actions .button {
        flex: 1 1 100%;
    }
    .rental-contract-hero dl { text-align: left; }
    .rental-contract-tabs { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 6px; }
    .rental-contract-responsibilities { grid-template-columns: 1fr; }
}

.rentals-shell .rental-contract-tabs {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 4px;
    margin-bottom: 16px;
    padding: 10px 12px 0;
    overflow: visible;
    background: linear-gradient(180deg, #fbfdfe, #f7fafb);
}

.rentals-shell .rental-contract-tabs a {
    position: relative;
    display: flex;
    min-width: 0;
    min-height: 66px;
    align-items: center;
    justify-content: flex-start;
    gap: 9px;
    border: 0;
    border-radius: 10px 10px 0 0;
    padding: 10px 12px 13px;
    white-space: normal;
    text-align: left;
}

.rentals-shell .rental-contract-tabs a::after {
    position: absolute;
    right: 12px;
    bottom: -1px;
    left: 12px;
    height: 3px;
    border-radius: 3px 3px 0 0;
    background: transparent;
    content: "";
}

.rentals-shell .rental-contract-tabs a:hover,
.rentals-shell .rental-contract-tabs a:focus {
    background: #f0f6f8;
}

.rentals-shell .rental-contract-tabs a.is-active {
    background: #fff;
}

.rentals-shell .rental-contract-tabs a.is-active::after {
    background: linear-gradient(90deg, #087f88, #10a18f);
}

.rental-contract-tab-icon {
    display: grid;
    flex: 0 0 32px;
    width: 32px;
    height: 32px;
    place-items: center;
    border: 1px solid #cfe1e7;
    border-radius: 9px;
    background: #f4fafb;
    color: #137283;
    font-size: .66rem;
    font-weight: 900;
}

.rental-contract-tabs a.is-active .rental-contract-tab-icon {
    border-color: #a8dcd5;
    background: #e7f7f3;
    color: #0a786e;
}

.rental-contract-tab-copy {
    min-width: 0;
}

.rental-contract-tab-copy strong,
.rental-contract-tab-copy small {
    display: block;
}

.rental-contract-tab-copy strong {
    color: inherit;
    font-size: .82rem;
    line-height: 1.15;
}

.rental-contract-tab-copy small {
    margin-top: 3px;
    color: #81919c;
    font-size: .64rem;
    font-weight: 500;
    line-height: 1.15;
}

.rentals-shell .rental-contract-tabs b {
    flex: 0 0 auto;
    margin-left: 2px;
    color: var(--accent);
    font-size: .7rem;
}

@media (max-width: 1350px) and (min-width: 761px) {
    .rentals-shell .rental-contract-tabs {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .rentals-shell .rental-contract-tabs {
        grid-template-columns: 1fr;
        gap: 7px;
        padding: 10px;
        overflow: visible;
    }

    .rentals-shell .rental-contract-tabs a {
        width: 100%;
        min-height: 56px;
        border: 1px solid #d8e5e9;
        border-radius: 10px;
        padding: 10px 12px;
    }

    .rentals-shell .rental-contract-tabs a::after {
        top: 8px;
        right: auto;
        bottom: 8px;
        left: -1px;
        width: 3px;
        height: auto;
        border-radius: 0 3px 3px 0;
    }

    .rentals-shell .rental-contract-tabs a.is-active {
        border-color: #a9dcd7;
        background: #effaf8;
    }

    .rentals-shell .rental-contract-tabs b {
        margin-left: auto;
    }

    .rental-contract-tab-copy strong {
        font-size: .84rem;
    }

    .rental-contract-tab-copy small {
        font-size: .66rem;
    }
}

@media print {
    .contract-export-state-mark {
        margin-bottom: 8mm;
        padding: 2.5mm;
        border-radius: 0;
        font-size: 13pt;
    }
}
