﻿/*
 * Edge Capital CRM compatibility layer for the licensed Cake/W3CRM theme.
 * Cake owns the visual system. This file only composes CRM-specific layouts
 * from Cake tokens and intentionally does not override Cake shell components.
 */

.w3crm {
    --crm-border: #e6e6e6;
    --crm-muted: #595959;
    --crm-danger: #ff5e5e;
    --crm-warning: #ff9f00;
    --crm-success: #3ac977;
    --crm-surface: #fff;
    --crm-soft: #f8f9fc;
    color: #595959;
}

.w3crm .ec-skip-link {
    position: fixed;
    top: .75rem;
    left: .75rem;
    z-index: 99999;
    transform: translateY(-150%);
    padding: .55rem .85rem;
    border-radius: .375rem;
    background: var(--primary, #0d99ff);
    color: #fff;
    font-weight: 600;
    box-shadow: 0 .75rem 1.5rem rgba(0, 0, 0, .18);
}

.w3crm .ec-skip-link:focus,
.w3crm .ec-skip-link:focus-visible {
    transform: translateY(0);
    color: #fff;
}

.w3crm :where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
    outline: 2px solid #0b6fbf !important;
    outline-offset: 2px;
}

.w3crm .edge-brand-logo .brand-title {
    display: block;
    width: auto !important;
    max-width: 108px;
    height: auto !important;
    max-height: 42px;
    object-fit: contain;
    aspect-ratio: auto;
}

.w3crm .edge-brand-logo .logo-abbr {
    display: none;
    width: auto !important;
    max-width: 44px;
    height: auto !important;
    max-height: 24px;
    object-fit: contain;
    aspect-ratio: auto;
}

.w3crm .edge-brand-logo {
    overflow: visible;
}

.w3crm .edge-brand-logo img {
    flex: 0 0 auto;
}

.w3crm .nav-header .edge-brand-logo {
    align-items: center;
    justify-content: center;
    padding: .35rem .75rem;
}

.w3crm .nav-header .edge-brand-logo .brand-title {
    display: block;
}

.w3crm .header-profile-dropdown .profile-media .edge-header-avatar {
    width: 42px;
    height: 42px;
}

.w3crm .header-profile-dropdown .profile-head {
    align-items: center;
}

.w3crm .header-profile-dropdown .header-info {
    position: static;
    margin-left: .75rem;
    white-space: nowrap;
}

.w3crm .header-profile-dropdown .author-name {
    margin: 0;
}

.w3crm .page-title-toolbar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: .5rem;
}

.w3crm .edge-header-avatar {
    display: inline-flex;
    width: 2.75rem;
    height: 2.75rem;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    font-weight: 600;
}

.w3crm .edge-header-avatar-lg { width: 3.5rem; height: 3.5rem; }
.w3crm .edge-profile-card { min-width: 18rem; padding: 1rem; }
.w3crm .edge-profile-head { display: flex; align-items: center; gap: .75rem; padding-bottom: .75rem; border-bottom: 1px solid var(--crm-border); }
.w3crm .edge-profile-head h6,
.w3crm .edge-profile-head p { margin: 0; }
.w3crm .edge-profile-actions { padding-top: .5rem; }
.w3crm .edge-topbar-bell { position: relative; }
.w3crm .edge-topbar-bell .badge { position: absolute; right: 0; top: 0; }
.w3crm .edge-topbar-badge {
    position: absolute;
    top: .15rem;
    right: -.2rem;
    display: inline-grid;
    min-width: 1rem;
    height: 1rem;
    padding: 0 .2rem;
    place-items: center;
    border-radius: 50%;
    background: var(--crm-danger, #ff5e5e);
    color: #fff;
    font-size: .625rem;
    font-weight: 600;
    line-height: 1;
}

.w3crm .ec-dashboard-action-stack .ec-dashboard-section-head > .btn {
    min-height: 2rem;
    padding: .4rem .7rem;
    border-color: var(--rgba-primary-2);
    background: var(--rgba-primary-1);
    color: var(--primary);
    font-size: .75rem;
    font-weight: 500;
}
.w3crm .page-titles-toolbar { display: flex; align-items: center; flex-wrap: wrap; gap: .5rem; }

.w3crm .ec-shell,
.w3crm .ec-main { min-height: 100vh; }
.w3crm .ec-main-guest {
    display: grid;
    place-items: center;
    padding: 1.5rem 1rem;
    background:
        radial-gradient(circle at 50% 0%, rgba(13, 153, 255, .10), transparent 24rem),
        #f5f5f5;
}
.w3crm .ec-auth-shell { width: min(100%, 27.5rem); }
.w3crm .ec-auth-card {
    position: relative;
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--crm-border);
    border-radius: .5rem;
    padding: 1.75rem;
    box-shadow: 0 .75rem 1.75rem rgba(0,0,0,.05);
}
.w3crm .ec-auth-card::before {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    height: .25rem;
    background: var(--primary, #0d99ff);
}
.w3crm .ec-auth-intro { margin-bottom: 1.25rem; text-align: center; }
.w3crm .ec-auth-intro h1 {
    margin: 0 0 .35rem;
    color: var(--title);
    font-size: clamp(1.35rem, 3.5vw, 1.65rem);
    font-weight: 500;
    line-height: 1.15;
}
.w3crm .ec-auth-intro p { margin-bottom: 0; }
.w3crm .ec-login-logo-wrap { display: flex; justify-content: center; margin-bottom: 1rem; }
.w3crm .ec-login-logo { width: 8.75rem; height: auto; }
.w3crm .ec-auth-card-login .ec-form-stack { gap: .85rem; }
.w3crm .ec-auth-card-login .form-control-lg {
    min-height: 2.75rem;
    font-size: .875rem;
}
.w3crm .ec-auth-card-login .ec-inline-check { margin-top: .1rem; }
.w3crm .ec-login-footnote { margin-top: 1rem; margin-bottom: 0; text-align: center; color: var(--crm-muted); font-size: .82rem; }
.w3crm.edgecapital-guest .ec-auth-submit,
.w3crm.edgecapital-public-intake .ec-auth-submit {
    min-height: 2.875rem;
    background: var(--primary, #0d99ff) !important;
    border-color: var(--primary, #0d99ff) !important;
    color: #fff !important;
    font-weight: 500;
}
.w3crm.edgecapital-guest .ec-auth-submit:hover,
.w3crm.edgecapital-public-intake .ec-auth-submit:hover {
    background: var(--primary-hover, #0b86df) !important;
    border-color: var(--primary-hover, #0b86df) !important;
}

.w3crm .ec-page-head,
.w3crm .ec-stack-header,
.w3crm .ec-card-head,
.w3crm .ec-action-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.w3crm .ec-page-head,
.w3crm .ec-stack-header { margin-bottom: 1.5rem; }
.w3crm .ec-page-head h1,
.w3crm .ec-stack-header h1,
.w3crm .ec-card h2,
.w3crm .ec-card h3 { color: var(--title); margin-bottom: .35rem; }
.w3crm .ec-section-label { display: block; color: var(--primary); font-size: .75rem; font-weight: 600; text-transform: uppercase; letter-spacing: .025em; margin-bottom: .3rem; }
.w3crm .ec-muted,
.w3crm .ec-queue-subnote,
.w3crm .ec-form-note,
.w3crm .ec-modal-helper { color: var(--crm-muted); font-size: .8125rem; }

.w3crm .ec-grid { display: grid; gap: 1.25rem; }
.w3crm .ec-grid-two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.w3crm .ec-grid-three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.w3crm .ec-card-stack { display: grid; gap: 1rem; }

.w3crm .ec-card,
.w3crm .ec-panel,
.w3crm .ec-wizard-panel,
.w3crm .ec-report-card,
.w3crm .ec-application-summary-card,
.w3crm .ec-underwriting-mini-card {
    background: var(--crm-surface);
    border: 1px solid var(--crm-border);
    border-radius: .375rem;
    padding: 1.25rem;
}

.w3crm .ec-card-soft { background: var(--crm-soft); box-shadow: none; }
.w3crm .ec-card-head { margin-bottom: 1rem; }
.w3crm .ec-card-head-compact { margin-bottom: .65rem; }
.w3crm .ec-customer-search { width: min(100%, 34rem); }
.w3crm .ec-customer-search .form-control { min-width: 15rem; }
.w3crm .ec-task-workspace { display: grid; gap: 1.25rem; }
.w3crm .ec-task-workspace > .card { margin-bottom: 0; }
.w3crm .ec-task-summary-item { min-height: 5.5rem; }
.w3crm .ec-task-secondary-section { margin-bottom: 0; }
.w3crm .ec-task-row-actions { display: flex; justify-content: flex-end; gap: .4rem; flex-wrap: wrap; }
.w3crm .ec-task-description { display: block; max-width: 70ch; white-space: pre-line; overflow-wrap: anywhere; }
.w3crm .ec-task-table td { overflow-wrap: anywhere; }
.w3crm .ec-task-cancel-disclosure { padding-top: 1rem; border-top: 1px solid var(--crm-border); }
.w3crm .ec-task-cancel-disclosure summary { cursor: pointer; }
.w3crm .ec-task-form-wrap { max-width: 68rem; }

.w3crm .ec-payment-tracking-workspace {
    display: grid;
    gap: 1.25rem;
}

.w3crm .ec-payment-tracking-workspace > .card,
.w3crm .ec-payment-tracking-workspace .row > [class*="col-"] > .card {
    margin-bottom: 0;
}

.w3crm .ec-payment-filter-form {
    display: grid;
    grid-template-columns: repeat(6, minmax(9rem, 1fr)) auto;
    gap: 1rem;
    align-items: end;
}

.w3crm .ec-payment-filter-form .form-label {
    display: grid;
    gap: .4rem;
    margin-bottom: 0;
    color: var(--title);
    font-size: .8125rem;
    font-weight: 500;
}

.w3crm .ec-payment-search-field {
    grid-column: span 2;
}

.w3crm .ec-payment-filter-actions {
    display: flex;
    justify-content: flex-end;
    gap: .5rem;
}

.w3crm .ec-payment-tracking-table {
    min-width: 82rem;
}

.w3crm .ec-payment-ledger-table {
    min-width: 54rem;
}

.w3crm .ec-payment-tracking-table td,
.w3crm .ec-payment-ledger-table td {
    vertical-align: middle;
}

.w3crm .ec-payment-tracking-workspace .ec-payment-filter-form {
    grid-template-columns: repeat(6, minmax(9rem, 1fr)) auto !important;
    padding-top: 0;
    border-top: 0;
}

.w3crm .card-header-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: .5rem;
}

.w3crm .w3crm-details-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    cursor: pointer;
    list-style: none;
}

.w3crm .w3crm-details-summary::-webkit-details-marker {
    display: none;
}

.w3crm details[open] > .w3crm-details-summary {
    border-bottom: 1px solid var(--bs-border-color) !important;
}

.w3crm .ec-applications-workspace { display: grid; gap: 1.25rem; }
.w3crm .ec-applications-workspace > .card { margin-bottom: 0; }
.w3crm .ec-applications-hero .card-body { display: grid; gap: 1rem; }
.w3crm .ec-applications-hero__main { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.w3crm .ec-applications-hero__main > div { min-width: 0; }
.w3crm .ec-applications-hero h2 { color: var(--title); overflow-wrap: anywhere; }
.w3crm .ec-applications-hero__actions { display: flex; align-items: center; justify-content: flex-end; gap: .5rem; flex-wrap: wrap; }
.w3crm .ec-applications-filter-form { display: grid; grid-template-columns: minmax(18rem, 1fr) minmax(11rem, .25fr) minmax(11rem, .25fr) auto; gap: 1rem; align-items: end; padding-top: .75rem; border-top: 1px solid var(--crm-border); }
.w3crm .ec-applications-filter-actions { display: flex; gap: .5rem; justify-content: flex-end; flex-wrap: wrap; }
.w3crm .ec-applications-workspace .tbl-caption { padding: 1rem 1.25rem; border-bottom: 1px solid var(--crm-border); }
.w3crm .ec-applications-workspace .active-projects.table-responsive { overflow-x: visible; }
.w3crm .ec-applications-workspace .active-projects table.shorting { width: 100%; min-width: 0 !important; table-layout: fixed; }
.w3crm .ec-applications-workspace .active-projects table.shorting th,
.w3crm .ec-applications-workspace .active-projects table.shorting td { padding-left: .75rem; padding-right: .75rem; vertical-align: middle; overflow-wrap: anywhere; }
/* Column widths for the 7-column queue:
   Application | Applicant | Where It Stands | Collateral | Assigned | Last Activity | Actions */
.w3crm .ec-applications-workspace .active-projects table.shorting th:nth-child(1) { width: 14%; }
.w3crm .ec-applications-workspace .active-projects table.shorting th:nth-child(2) { width: 18%; }
.w3crm .ec-applications-workspace .active-projects table.shorting th:nth-child(3) { width: 14%; }
.w3crm .ec-applications-workspace .active-projects table.shorting th:nth-child(4) { width: 13%; }
.w3crm .ec-applications-workspace .active-projects table.shorting th:nth-child(5) { width: 12%; }
.w3crm .ec-applications-workspace .active-projects table.shorting th:nth-child(6) { width: 11%; }
.w3crm .ec-applications-workspace .active-projects table.shorting th:nth-child(7) { width: 13%; }
.w3crm .ec-applications-workspace .active-projects table.shorting td:nth-child(7) { white-space: nowrap; }
.w3crm .ec-applications-workspace .active-projects table.shorting .products > .avatar,
.w3crm .ec-applications-workspace .active-projects table.shorting .products > [class*="avatar"],
.w3crm .ec-applications-workspace .active-projects table.shorting .products > span:first-child { display: none !important; }
.w3crm .ec-applications-workspace .active-projects table.shorting .products { gap: 0 !important; }
.w3crm .ec-applications-workspace .active-projects table.shorting td:nth-child(6) .ec-light-sign { display: table; width: fit-content; max-width: 100%; white-space: normal; line-height: 1.25; margin-bottom: .25rem; }
.w3crm .ec-applications-workspace .active-projects table.shorting td:nth-child(6) .ec-light-sign:last-child { margin-bottom: 0; }
.w3crm .ec-applications-workspace .active-projects table.shorting td:nth-child(7) { white-space: normal !important; overflow: hidden; overflow-wrap: anywhere; line-height: 1.3; }
.w3crm .ec-applications-workspace .active-projects table.shorting td:last-child { white-space: nowrap; overflow-wrap: normal; }
.w3crm .ec-applications-workspace .active-projects table.shorting td:last-child .btn { padding: .4rem .55rem; }

.w3crm .ec-loans-workspace {
    display: grid;
    gap: 1.25rem;
}

.w3crm .ec-loans-workspace > .card {
    margin-bottom: 0;
}

.w3crm .ec-loans-workspace .active-projects.table-responsive {
    overflow-x: auto;
}

.w3crm .ec-loans-workspace table.shorting {
    width: 100%;
    min-width: 82rem;
    table-layout: auto;
}

.w3crm .ec-loans-workspace table.shorting th,
.w3crm .ec-loans-workspace table.shorting td {
    vertical-align: middle;
}

.w3crm .ec-loans-workspace table.shorting th:last-child,
.w3crm .ec-loans-workspace table.shorting td:last-child {
    min-width: 6.5rem;
    white-space: nowrap;
    text-align: right;
}

.w3crm .ec-underwriting-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1.25rem; align-items: start; }
.w3crm .ec-underwriting-layout > .card,
.w3crm .ec-underwriting-layout > main > .card { margin-bottom: 0; }
.w3crm .ec-underwriting-rail,
.w3crm .ec-underwriting-context,
.w3crm .ec-underwriting-panel > .card-body,
.w3crm .ec-underwriting-panel { min-width: 0; }
.w3crm .ec-underwriting-rail { display: grid; grid-template-columns: repeat(2, minmax(13rem, 26rem)); gap: .75rem; justify-content: start; padding: 1rem; }
.w3crm .ec-underwriting-context { display: grid; grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr)); gap: 0; overflow: hidden; }
.w3crm .ec-underwriting-panel .card-body { display: block; }
.w3crm .ec-underwriting-step { display: flex; align-items: center; gap: .75rem; min-height: 4rem; padding: .75rem .9rem; border: 1px solid var(--crm-border); border-radius: .375rem; color: var(--title); background: #fff; min-width: 0; }
.w3crm a.ec-underwriting-step:hover,
.w3crm a.ec-underwriting-step:focus { color: var(--primary); border-color: var(--rgba-primary-2); background: var(--rgba-primary-1); }
.w3crm .ec-underwriting-step.is-active { border-color: var(--primary); background: #fff; box-shadow: inset 0 0 0 1px var(--primary); }
.w3crm .ec-underwriting-step.is-locked { color: var(--crm-muted); background: var(--crm-soft); }
.w3crm .ec-underwriting-step__number { display: inline-grid; place-items: center; flex: 0 0 2.5rem; width: 2.5rem; height: 1.5rem; border-radius: .375rem; border: 0; background: var(--rgba-primary-1); color: var(--primary); font-size: .68rem; font-weight: 600; text-transform: uppercase; }
.w3crm .ec-underwriting-step__body { display: grid; gap: .2rem; min-width: 0; }
.w3crm .ec-underwriting-step__body strong,
.w3crm .ec-underwriting-step__body small { overflow-wrap: normal; }
.w3crm .ec-underwriting-summary { display: flex; align-items: center; flex-wrap: wrap; gap: .5rem .85rem; color: var(--crm-muted); }
.w3crm .ec-underwriting-summary strong { color: var(--title); }
.w3crm .ec-underwriting-grid,
.w3crm .ec-underwriting-review-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; margin-bottom: 1rem; }
.w3crm .ec-underwriting-review-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.w3crm .ec-underwriting-mini-card,
.w3crm .ec-underwriting-review-item { display: grid; align-content: start; gap: .35rem; min-height: 6.6rem; }
.w3crm .ec-underwriting-mini-card span,
.w3crm .ec-underwriting-review-item span { color: var(--crm-muted); font-size: .75rem; font-weight: 500; text-transform: uppercase; letter-spacing: .025em; }
.w3crm .ec-underwriting-mini-card strong,
.w3crm .ec-underwriting-review-item strong { color: var(--title); font-size: clamp(1rem, 1.2vw, 1.2rem); line-height: 1.2; overflow-wrap: anywhere; }
.w3crm .ec-underwriting-mini-card small,
.w3crm .ec-underwriting-review-item small { color: var(--crm-muted); overflow-wrap: anywhere; }
.w3crm .ec-underwriting-subpanel { display: grid; gap: 1rem; margin-bottom: 1rem; padding: 1.1rem; }
.w3crm .ec-underwriting-subpanel:last-child { margin-bottom: 0; }
.w3crm .ec-underwriting-subpanel h3 { color: var(--title); margin-bottom: .25rem; }
.w3crm .ec-underwriting-panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.w3crm .ec-underwriting-review-item { min-height: 5.5rem; padding: 1rem; border: 1px solid var(--crm-border); border-radius: .375rem; background: var(--crm-soft); }
.w3crm .ec-underwriting-step-actions { display: flex; align-items: center; justify-content: space-between; gap: .5rem; flex-wrap: wrap; }
.w3crm .ec-underwriting-context-block { padding: 1rem; border-top: 1px solid var(--crm-border); border-left: 1px solid var(--crm-border); }
.w3crm .ec-underwriting-context-block:first-of-type { border-left: 0; }
.w3crm .ec-underwriting-context-block strong { display: block; color: var(--title); margin-bottom: .35rem; }
.w3crm .ec-underwriting-context-block p { margin-bottom: 0; color: var(--crm-muted); }
.w3crm .ec-underwriting-list { display: grid; gap: .5rem; margin: 0; padding-left: 1rem; }
.w3crm .ec-underwriting-list li { overflow-wrap: anywhere; }
.w3crm .ec-underwriting-list small { display: block; color: var(--crm-muted); }
.w3crm .ec-underwriting-shortcuts { display: flex; flex-wrap: wrap; gap: .45rem; }
.w3crm .ec-underwriting-shortcuts a { display: inline-flex; padding: .35rem .55rem; border: 1px solid var(--crm-border); border-radius: .25rem; color: var(--primary); background: #fff; font-size: .75rem; font-weight: 500; }
.w3crm .ec-button:disabled,
.w3crm .ec-button[disabled] { opacity: .55; cursor: not-allowed; filter: grayscale(.1); }

.w3crm .ec-doc-workspace { display: grid; gap: 1.25rem; }
.w3crm .ec-doc-workspace > .card,
.w3crm .ec-doc-workspace > details,
.w3crm .ec-doc-two-col > details { margin-bottom: 0; }
.w3crm .ec-doc-hero .card-body { display: grid; gap: 1rem; }
.w3crm .ec-doc-hero__main { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.w3crm .ec-doc-hero__main > div { min-width: 0; }
.w3crm .ec-doc-hero h2 { color: var(--title); overflow-wrap: anywhere; }
.w3crm .ec-doc-status-strip { display: flex; flex-wrap: wrap; gap: .5rem; padding-top: .75rem; border-top: 1px solid var(--crm-border); }
.w3crm .ec-doc-filter-form { display: grid; grid-template-columns: minmax(18rem, 1fr) minmax(11rem, .28fr) minmax(11rem, .28fr) auto; gap: 1rem; align-items: end; }
.w3crm .ec-doc-filter-actions { display: flex; gap: .5rem; align-items: center; justify-content: flex-end; }
.w3crm .ec-doc-kpi-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.w3crm .ec-doc-kpi-card .card-body { display: grid; align-content: start; min-height: 7.5rem; }
.w3crm .ec-doc-kpi-card strong { color: var(--title); font-size: clamp(1.2rem, 1.8vw, 1.65rem); line-height: 1.1; overflow-wrap: anywhere; }
.w3crm .ec-doc-kpi-card small { color: var(--crm-muted); }
.w3crm .ec-doc-table-caption { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding: 1rem 1.25rem; border-bottom: 1px solid var(--crm-border); }
.w3crm .ec-doc-table-wrap { border: 0; }
.w3crm .ec-doc-table { min-width: 70rem; }
.w3crm .ec-doc-table td { overflow-wrap: anywhere; }
.w3crm .ec-doc-action-cell { text-align: right; white-space: nowrap; }
.w3crm .ec-doc-pagination { padding: 1rem 1.25rem; border-top: 1px solid var(--crm-border); }
.w3crm .ec-pagination-summary { display: inline-flex; align-items: center; min-height: 2rem; padding: 0 .5rem; color: var(--crm-muted); }
.w3crm .ec-pagination-link.is-disabled { opacity: .5; cursor: not-allowed; }
.w3crm .ec-text-link { color: var(--primary); font-weight: 500; }
.w3crm .ec-doc-section { margin-bottom: 0; }
.w3crm .ec-doc-section > .card-body { border-top: 1px solid var(--crm-border); }
.w3crm .ec-doc-profile { padding-bottom: 1rem; border-bottom: 1px solid var(--crm-border); }
.w3crm .ec-doc-profile:last-child { padding-bottom: 0; border-bottom: 0; }
.w3crm .ec-doc-profile h5 { color: var(--title); margin-bottom: .25rem; overflow-wrap: anywhere; }
.w3crm .ec-doc-readiness-list { margin-top: 1.25rem; padding-top: 1rem; border-top: 1px solid var(--crm-border); }

.w3crm .ec-report-workspace { display: grid; gap: 1.25rem; }
.w3crm .ec-report-workspace > .card { margin-bottom: 0; }
.w3crm .ec-report-hero .card-body { display: grid; gap: 1rem; }
.w3crm .ec-report-hero__main { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.w3crm .ec-report-hero__main > div { min-width: 0; }
.w3crm .ec-report-hero h2 { color: var(--title); overflow-wrap: anywhere; }
.w3crm .ec-report-hero__actions { display: flex; align-items: center; justify-content: flex-end; gap: .5rem; flex-wrap: wrap; }
.w3crm .ec-report-status-strip { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .75rem; padding-top: .75rem; border-top: 1px solid var(--crm-border); }
.w3crm .ec-report-status-strip span { min-width: 0; }
.w3crm .ec-report-status-strip strong,
.w3crm .ec-report-status-strip small { display: block; overflow-wrap: anywhere; }
.w3crm .ec-report-status-strip strong { color: var(--title); font-size: .8125rem; }
.w3crm .ec-report-status-strip small { color: var(--crm-muted); font-size: .75rem; }
.w3crm .ec-report-kpi-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.w3crm .ec-report-kpi-card .card-body { display: grid; align-content: start; min-height: 7.35rem; }
.w3crm .ec-report-kpi-card strong { color: var(--title); font-size: clamp(1.1rem, 1.55vw, 1.45rem); line-height: 1.15; overflow-wrap: anywhere; }
.w3crm .ec-report-kpi-card small { color: var(--crm-muted); }
.w3crm .ec-report-card > .card-body { display: grid; gap: 1rem; }
.w3crm .ec-report-library-list { display: grid; gap: .75rem; }
.w3crm .ec-report-reconciliation-list { margin-top: 1rem; }
.w3crm .ec-report-library-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(12rem, .38fr) auto; gap: 1rem; align-items: center; padding: 1rem; border: 1px solid var(--crm-border); border-radius: .375rem; background: #fff; }
.w3crm .ec-report-library-title { min-width: 0; }
.w3crm .ec-report-library-title h4 { color: var(--title); margin-bottom: .35rem; overflow-wrap: anywhere; }
.w3crm .ec-report-library-title p { margin-bottom: 0; max-width: 78ch; }
.w3crm .ec-report-library-meta { display: grid; gap: .35rem; color: var(--crm-muted); font-size: .78rem; }
.w3crm .ec-report-library-meta span { overflow-wrap: anywhere; }
.w3crm .ec-report-library-action { display: flex; justify-content: flex-end; }
.w3crm .ec-report-coverage-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.w3crm .ec-report-coverage-item { display: grid; gap: .45rem; align-content: start; min-height: 7.15rem; padding: 1rem; border: 1px solid var(--crm-border); border-radius: .375rem; background: #fff; }
.w3crm .ec-report-coverage-item strong { color: var(--title); font-size: 1.35rem; line-height: 1.1; overflow-wrap: anywhere; }
.w3crm .ec-report-coverage-item small { color: var(--crm-muted); overflow-wrap: anywhere; }
.w3crm .ec-portfolio-intelligence .ec-report-kpi-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.w3crm .ec-report-section { margin-bottom: 0; }
.w3crm .ec-report-section > .card-body { border-top: 1px solid var(--crm-border); }
.w3crm .ec-report-section-summary { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.w3crm .ec-report-section-summary strong,
.w3crm .ec-report-section-summary small { display: block; overflow-wrap: anywhere; }
.w3crm .ec-report-section-summary strong { color: var(--title); font-size: 1rem; }
.w3crm .ec-report-section-summary small { color: var(--crm-muted); font-size: .78rem; }
.w3crm .ec-report-split-grid { grid-template-columns: minmax(0, 1fr); }
.w3crm .ec-report-split-grid > details { margin-bottom: 0; min-width: 0; }
.w3crm .ec-report-table { min-width: 56rem; }
.w3crm .ec-report-table td strong,
.w3crm .ec-report-table td small { display: block; overflow-wrap: anywhere; }
.w3crm .ec-report-table td { overflow-wrap: anywhere; }

.w3crm .ec-collections-hero { margin-bottom: 1.25rem; }
.w3crm .ec-collections-hero .card-body { display: grid; gap: 1rem; }
.w3crm .ec-collections-hero__main { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.w3crm .ec-collections-hero__main > div { min-width: 0; }
.w3crm .ec-collections-hero h2 { color: var(--title); overflow-wrap: anywhere; }

.w3crm .ec-payment-desk { display: grid; gap: 1.25rem; }
.w3crm .ec-payment-desk > .card { margin-bottom: 0; }
.w3crm .ec-payment-hero .card-body { display: grid; gap: 1rem; }
.w3crm .ec-payment-hero__main { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.w3crm .ec-payment-hero__main > div { min-width: 0; }
.w3crm .ec-payment-hero h2 { color: var(--title); overflow-wrap: anywhere; }
.w3crm .ec-payment-hero__actions { display: flex; align-items: center; justify-content: flex-end; gap: .5rem; flex-wrap: wrap; }
.w3crm .ec-payment-desk .ec-payment-filter-form { display: flex; flex-wrap: wrap; gap: .75rem; align-items: end; padding-top: .65rem; border-top: 1px solid var(--crm-border); }
.w3crm .ec-payment-desk .ec-payment-filter-form > label { flex: 0 1 10rem; }
.w3crm .ec-payment-desk .ec-payment-filter-form > .ec-payment-search-compact { flex: 0 1 12rem; margin-left: auto; }
.w3crm .ec-payment-desk .ec-payment-filter-form > .ec-payment-filter-actions { flex: 0 0 auto; }
.w3crm .ec-payment-desk .ec-payment-hero-compact .card-body { gap: .65rem; padding: .9rem 1rem; }
.w3crm .ec-payment-desk .ec-payment-hero-compact h2 { margin-bottom: .2rem; }
.w3crm .ec-payment-desk .ec-payment-filter-form label { display: grid; gap: .4rem; color: var(--title); font-size: .8125rem; font-weight: 500; }
.w3crm .ec-payment-filter-form input,
.w3crm .ec-payment-filter-form select { width: 100%; min-height: 2.75rem; padding: .55rem .75rem; border: 1px solid #d7dae3; border-radius: .375rem; background: #fff; color: #2c2c2c; }
.w3crm .ec-payment-filter-actions { display: flex; gap: .5rem; justify-content: flex-end; flex-wrap: wrap; }
.w3crm .ec-payment-kpi-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 1rem; }
.w3crm .ec-payment-kpi-card .card-body { display: grid; align-content: start; min-height: 7.25rem; }
.w3crm .ec-payment-kpi-card strong { color: var(--title); font-size: clamp(1.15rem, 1.55vw, 1.5rem); line-height: 1.15; overflow-wrap: anywhere; }
.w3crm .ec-payment-kpi-card small { color: var(--crm-muted); }
.w3crm .ec-payment-card > .card-body { display: grid; gap: 1rem; }
.w3crm .ec-payment-queue-list,
.w3crm .ec-payment-receipt-list { display: grid; gap: .75rem; }
.w3crm .ec-payment-queue-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(10rem, .22fr) minmax(12rem, auto); gap: 1rem; align-items: center; padding: 1rem; border: 1px solid var(--crm-border); border-radius: .375rem; background: #fff; }
.w3crm .ec-payment-queue-row-danger { border-left: 3px solid var(--crm-danger, #dc3545); background: rgba(220, 53, 69, .06); }
.w3crm .ec-payment-queue-row-danger h4,
.w3crm .ec-payment-queue-row-danger strong { color: var(--crm-danger, #dc3545); }
.w3crm .ec-payment-search-compact { max-width: 190px; }
.w3crm .ec-payment-search-compact input { min-width: 0; }
.w3crm .ec-payment-queue-title { min-width: 0; }
.w3crm .ec-payment-queue-title h4 { color: var(--title); margin: .45rem 0 .25rem; overflow-wrap: anywhere; }
.w3crm .ec-payment-queue-title p { margin: 0; }
.w3crm .ec-payment-attempt-strip { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; margin-top: .65rem; color: var(--crm-muted); font-size: .8125rem; }
.w3crm .ec-payment-note { display: inline-flex; max-width: 100%; padding: .25rem .5rem; border: 1px solid var(--crm-border); border-radius: 999px; background: #f8fafc; color: var(--title); overflow-wrap: anywhere; }
.w3crm .ec-payment-queue-meta { display: grid; gap: .25rem; }
.w3crm .ec-payment-queue-meta span,
.w3crm .ec-payment-queue-meta small { color: var(--crm-muted); font-size: .78rem; }
.w3crm .ec-payment-queue-meta strong { color: var(--title); font-size: 1.25rem; overflow-wrap: anywhere; }
.w3crm .ec-payment-queue-actions { display: grid; gap: .5rem; justify-items: end; }
.w3crm .ec-inline-form { margin: 0; }
.w3crm .ec-payment-receipt-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(10rem, .25fr) auto; gap: 1rem; align-items: center; padding: .85rem 0; border-top: 1px solid var(--crm-border); }
.w3crm .ec-payment-receipt-row:first-child { padding-top: 0; border-top: 0; }
.w3crm .ec-payment-receipt-row strong,
.w3crm .ec-payment-receipt-row small { display: block; overflow-wrap: anywhere; }
.w3crm .ec-payment-receipt-row strong { color: var(--title); }
.w3crm .ec-payment-receipt-row small { color: var(--crm-muted); }

.w3crm .ec-sync-workspace { display: grid; gap: 1.25rem; }
.w3crm .ec-sync-workspace > .card { margin-bottom: 0; }
.w3crm .ec-sync-hero .card-body { display: grid; gap: 1rem; }
.w3crm .ec-sync-hero__main { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.w3crm .ec-sync-hero__main > div { min-width: 0; }
.w3crm .ec-sync-hero h2 { color: var(--title); }
.w3crm .ec-sync-run-now { display: grid; gap: .35rem; min-width: 12rem; }
.w3crm .ec-sync-status-strip { display: flex; flex-wrap: wrap; gap: .5rem; padding-top: .75rem; border-top: 1px solid var(--crm-border); }
.w3crm .ec-sync-flow { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.w3crm .ec-sync-flow-card .card-body { display: grid; align-content: start; min-height: 8.25rem; }
.w3crm .ec-sync-flow-card strong { color: var(--title); font-size: clamp(1rem, 1.4vw, 1.35rem); line-height: 1.2; overflow-wrap: anywhere; }
.w3crm .ec-sync-flow-card span:not(.ec-section-label) { color: var(--title); font-weight: 500; }
.w3crm .ec-sync-flow-card small { color: var(--crm-muted); }
.w3crm .ec-sync-operational-grid { align-items: stretch; }
.w3crm .ec-sync-operational-grid > .card,
.w3crm .ec-sync-operational-grid > details { margin-bottom: 0; }
.w3crm .ec-sync-secondary-section { margin-bottom: 0; }
.w3crm .ec-sync-secondary-section > .card-body,
.w3crm .ec-sync-secondary-section > .ec-card-head + .card-body { border-top: 1px solid var(--crm-border); }
.w3crm .ec-sync-mini-disclosure { border-top: 1px solid var(--crm-border); padding-top: .75rem; }
.w3crm .ec-sync-mini-disclosure summary { color: var(--title); cursor: pointer; font-weight: 500; }
.w3crm .ec-sync-review-row { padding: .85rem 0; border-top: 1px solid var(--crm-border); }
.w3crm .ec-sync-review-row:first-child { padding-top: 0; border-top: 0; }
.w3crm .ec-sync-review-row strong,
.w3crm .ec-sync-review-row small { display: block; overflow-wrap: anywhere; }
.w3crm .ec-sync-review-row p { margin: .35rem 0; color: #555; overflow-wrap: anywhere; }
.w3crm .ec-sync-workspace .tbl-caption { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding: 1rem 1.25rem; border-bottom: 1px solid var(--crm-border); }
.w3crm .ec-sync-workspace .active-projects table { min-width: 48rem; }

@media (max-width: 1199.98px) {
    .w3crm .ec-applications-workspace .active-projects.table-responsive { overflow-x: auto; }
    .w3crm .ec-applications-workspace .active-projects table.shorting { min-width: 1120px !important; table-layout: auto; }
    .w3crm .ec-underwriting-layout { grid-template-columns: minmax(12rem, .8fr) minmax(0, 2fr); }
    .w3crm .ec-underwriting-context { grid-column: 1 / -1; }
    .w3crm .ec-underwriting-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 575.98px) {
    .w3crm .ec-customer-search,
    .w3crm .ec-customer-search .form-control { width: 100%; min-width: 0; }
    .w3crm .ec-customer-search .input-group { display: grid; grid-template-columns: 1fr auto; }
    .w3crm .ec-customer-search .input-group .form-control { grid-column: 1 / -1; border-radius: .375rem .375rem 0 0; }
    .w3crm .ec-customer-search .input-group .btn:last-child { border-radius: 0 0 .375rem 0; }
    .w3crm .ec-doc-status-strip .ec-light-sign { white-space: normal; }
    .w3crm .ec-sync-run-now,
    .w3crm .ec-sync-run-now .btn { width: 100%; }
    .w3crm .ec-sync-status-strip .ec-light-sign { white-space: normal; }
}

/* Loan servicing workspace: compose the specialized desk from Cake cards. */
.w3crm .ec-loan-desk-grid {
    display: grid;
    grid-template-columns: minmax(13rem, .9fr) minmax(24rem, 1.55fr) minmax(15rem, .95fr);
    gap: 1.25rem;
    align-items: stretch;
}
.w3crm .ec-loan-desk-stack,
.w3crm .ec-loan-mini-rows,
.w3crm .ec-loan-field-grid { display: grid; gap: .75rem; }
.w3crm .ec-loan-desk-stack > .ec-card { height: 100%; }
.w3crm .ec-loan-account-title {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: .65rem;
    margin: .8rem 0 1.2rem;
    color: var(--title);
    font-size: clamp(1.5rem, 2.5vw, 2rem);
    font-weight: 600;
    line-height: 1.15;
}
.w3crm .ec-loan-account-title strong {
    color: var(--crm-success);
    font-weight: 500;
}
.w3crm .ec-loan-account-title strong.is-warning { color: var(--crm-warning); }
.w3crm .ec-loan-account-title strong.is-danger { color: var(--crm-danger); }
.w3crm .ec-loan-account-title strong.is-muted { color: var(--crm-muted); }
.w3crm .ec-loan-desk-stack > .ec-app-section { margin-bottom: 0; }
.w3crm .ec-loan-desk-party .ec-loan-party-block + .ec-loan-party-block { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--crm-border); }
.w3crm .ec-loan-party-block__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; margin-bottom: .6rem; }
.w3crm .ec-loan-party-block__head h3 { margin: 0; font-size: 1rem; }
.w3crm .ec-loan-field-grid,
.w3crm .ec-loan-mini-rows { margin: 0; }
.w3crm .ec-loan-field-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.w3crm .ec-loan-field-grid dt,
.w3crm .ec-loan-mini-rows dt { color: var(--crm-muted); font-size: .75rem; font-weight: 500; }
.w3crm .ec-loan-field-grid dd,
.w3crm .ec-loan-mini-rows dd { margin: .15rem 0 0; color: var(--title); font-weight: 500; overflow-wrap: anywhere; }
.w3crm .ec-loan-balance-table-wrap { max-width: 100%; overflow-x: auto; }
.w3crm .ec-loan-balance-table { width: 100%; min-width: 23rem; margin: .35rem 0 1rem; }
.w3crm .ec-loan-balance-table th,
.w3crm .ec-loan-balance-table td { padding: .65rem .45rem; border-bottom: 1px solid var(--crm-border); text-align: right; white-space: nowrap; }
.w3crm .ec-loan-balance-table th:first-child,
.w3crm .ec-loan-balance-table td:first-child { text-align: left; }
.w3crm .ec-loan-balance-card h3 {
    margin-bottom: 1rem;
    color: var(--title);
    text-align: center;
    font-size: clamp(1.2rem, 2vw, 1.55rem);
    font-weight: 500;
}
.w3crm .ec-loan-progress {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    color: var(--title);
    font-size: 1.15rem;
}
.w3crm .ec-loan-progress strong {
    color: var(--primary);
    font-weight: 600;
}
.w3crm .ec-loan-desk-bottom-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.25rem; margin-top: 1.25rem; }
.w3crm .ec-loan-mini-rows > div { display: flex; justify-content: space-between; gap: .75rem; padding-bottom: .45rem; border-bottom: 1px solid var(--crm-border); }
.w3crm .ec-loan-mini-rows dd { text-align: right; }
.w3crm .ec-loan-total-band { display: block; margin-top: 1rem; padding: .7rem .8rem; border-radius: .375rem; background: var(--crm-soft); color: var(--title); text-align: right; }
.w3crm .ec-loan-total-band.is-good { color: var(--crm-success); }
.w3crm .ec-loan-total-band.is-danger { color: var(--crm-danger); }
.w3crm .ec-loan-detail-grid,
.w3crm .ec-tab-panel > .ec-card { margin-bottom: 1.25rem; }
.w3crm .ec-tab-panel .table-responsive { border: 1px solid var(--crm-border); border-radius: .375rem; }

@media (max-width: 1399.98px) {
    .w3crm .ec-loan-desk-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .w3crm .ec-loan-desk-terms { grid-column: 1 / -1; }
    .w3crm .ec-loan-desk-bottom-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 767.98px) {
    .w3crm .ec-loan-desk-grid,
    .w3crm .ec-loan-desk-bottom-grid,
    .w3crm .ec-loan-field-grid { grid-template-columns: minmax(0, 1fr); }
    .w3crm .ec-loan-desk-terms { grid-column: auto; }
}

.w3crm .ec-kpi-card { position: relative; min-height: 8rem; overflow: hidden; }
.w3crm .ec-kpi-card::after { content: ""; position: absolute; right: 1rem; top: 1rem; width: 2.5rem; height: 2.5rem; border-radius: .625rem; background: var(--rgba-primary-1); }
.w3crm .ec-kpi-card strong { color: var(--title); font-size: 1.45rem; }

.w3crm .cake-dashboard-kpi-card { min-height: 8.125rem; }
.w3crm .cake-dashboard-kpi-card .depostit-card-media > div:first-child { flex: 1 1 auto; min-width: 0; padding-right: .45rem; }
.w3crm .cake-dashboard-kpi-card .depostit-card-media > div:last-child { flex: 0 0 auto; }
.w3crm .cake-dashboard-kpi-card h6 { min-height: 2.25rem; margin-bottom: .2rem; line-height: 1.25; }
.w3crm .cake-dashboard-kpi-card h3 { font-size: clamp(.9rem, 1vw, 1.2rem); line-height: 1.15; overflow-wrap: normal; white-space: nowrap; }
.w3crm .cake-dashboard-status-card { min-height: 0; }

@media (min-width: 1200px) {
    .w3crm .cake-dashboard-kpi-grid > .col {
        flex: 0 0 auto;
        width: 20%;
        min-width: 0;
    }
}

@media (min-width: 1600px) {
    .w3crm .cake-dashboard-kpi-column { flex: 0 0 auto; width: 75%; }
    .w3crm .cake-dashboard-status-column { flex: 0 0 auto; width: 25%; }
    .w3crm .cake-dashboard-status-card { min-height: 17.25rem; }
}

.w3crm .ec-inline-actions,
.w3crm .ec-modal-actions,
.w3crm .ec-action-row,
.w3crm .ec-status-inline { display: flex; align-items: center; gap: .5rem; }
.w3crm .ec-inline-actions-wrap,
.w3crm .ec-modal-actions { flex-wrap: wrap; }
.w3crm .ec-inline-actions-tight { gap: .3rem; }
.w3crm .ec-modal-actions { justify-content: flex-end; margin-top: 1rem; }
.w3crm .ec-inline-form { display: inline-flex; gap: .5rem; align-items: center; }

.w3crm .ec-button,
.w3crm .ec-cake-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .4rem;
    min-height: 2.5rem;
    padding: .55rem 1rem;
    border: 1px solid transparent;
    border-radius: .375rem;
    font-size: .875rem;
    font-weight: 500;
    line-height: 1.2;
    text-decoration: none;
    cursor: pointer;
    transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
.w3crm .ec-button-primary,
.w3crm .ec-button-brand { color: #fff; background: var(--primary); border-color: var(--primary); }
.w3crm .ec-button-primary:hover,
.w3crm .ec-button-brand:hover { color: #fff; background: var(--primary-hover); border-color: var(--primary-hover); }
.w3crm .ec-button-secondary,
.w3crm .ec-cake-button-secondary { color: var(--primary); background: var(--rgba-primary-1); border-color: var(--rgba-primary-2); }
.w3crm .ec-button-danger { color: #fff; background: var(--crm-danger); border-color: var(--crm-danger); }
.w3crm .ec-button-compact { min-height: 2rem; padding: .4rem .7rem; font-size: .8rem; }
.w3crm .ec-button-block { width: 100%; }
.w3crm .ec-button[disabled],
.w3crm .ec-button.is-disabled { opacity: .55; cursor: not-allowed; }

.w3crm .ec-form-grid { display: grid; gap: 1rem; }
.w3crm .ec-form-grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.w3crm .ec-form-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.w3crm .ec-form-grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.w3crm .ec-form-span-2 { grid-column: span 2; }
.w3crm .ec-form-stack { display: grid; gap: 1rem; }
.w3crm .ec-field,
.w3crm .ec-form-grid label,
.w3crm .ec-modal-form > label { display: grid; gap: .4rem; color: var(--title); font-size: .8125rem; font-weight: 500; }
.w3crm .ec-field input,
.w3crm .ec-field select,
.w3crm .ec-field textarea,
.w3crm .ec-form-grid input,
.w3crm .ec-form-grid select,
.w3crm .ec-form-grid textarea,
.w3crm .ec-modal-form > label input,
.w3crm .ec-modal-form > label select,
.w3crm .ec-modal-form > label textarea,
.w3crm .ec-form-stack input,
.w3crm .ec-form-stack select,
.w3crm .ec-form-stack textarea {
    width: 100%;
    min-height: 2.75rem;
    padding: .55rem .75rem;
    border: 1px solid #d7dae3;
    border-radius: .375rem;
    background: #fff;
    color: #2c2c2c;
    font: inherit;
}
.w3crm textarea { resize: vertical; }
.w3crm .ec-form-grid-readonly > div { padding: .75rem; border: 1px solid var(--crm-border); border-radius: .375rem; background: #fff; }
.w3crm .ec-form-grid-readonly span { display: block; color: var(--crm-muted); font-size: .75rem; }
.w3crm .ec-form-grid-readonly strong { color: var(--title); }
.w3crm .ec-inline-check,
.w3crm .ec-form-checkbox { display: flex !important; grid-template-columns: none !important; align-items: center; gap: .5rem; }
.w3crm .ec-inline-check input,
.w3crm .ec-form-checkbox input { width: auto; min-height: auto; }
.w3crm .ec-inline-choice { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; }
.w3crm .ec-password-field { position: relative; }
.w3crm .ec-password-toggle { position: absolute; right: .5rem; top: 50%; transform: translateY(-50%); border: 0; background: transparent; color: var(--primary); }

.w3crm .ec-table-wrap { width: 100%; overflow-x: auto; border: 1px solid var(--crm-border); border-radius: .375rem; background: #fff; }
.w3crm .ec-table { width: 100%; border-collapse: collapse; color: #888; }
.w3crm .ec-table th { padding: .75rem 1rem; background: #f4f7fb; color: #2c2c2c; font-size: .75rem; font-weight: 600; text-align: left; white-space: nowrap; }
.w3crm .ec-table td { padding: .8rem 1rem; border-top: 1px solid var(--crm-border); vertical-align: top; }
.w3crm .ec-table tbody tr:hover { background: #fafcff; }

.w3crm .active-projects.table-responsive { overflow-x: auto; }
.w3crm .active-projects table.shorting { min-width: 72rem; table-layout: auto; }
.w3crm .active-projects table.shorting th,
.w3crm .active-projects table.shorting td { vertical-align: middle; }
.w3crm .active-projects table.shorting th { white-space: nowrap; }
.w3crm .active-projects table.shorting td:nth-child(1),
.w3crm .active-projects table.shorting td:nth-child(2),
.w3crm .active-projects table.shorting td:nth-child(3) { min-width: 10rem; }
.w3crm .active-projects table.shorting th:nth-child(4),
.w3crm .active-projects table.shorting td:nth-child(4) { min-width: 6.5rem; }
.w3crm .active-projects table.shorting .badge { white-space: nowrap; }
.w3crm .active-projects table.shorting td:nth-last-child(1) { min-width: 6.5rem; white-space: nowrap; }

.w3crm .ec-key-value { display: grid; gap: 0; margin: 0; }
.w3crm .ec-key-value > div { display: flex; justify-content: space-between; gap: 1rem; padding: .7rem 0; border-bottom: 1px solid var(--crm-border); }
.w3crm .ec-key-value dt { color: var(--crm-muted); font-weight: 400; }
.w3crm .ec-key-value dd { margin: 0; color: var(--title); font-weight: 500; text-align: right; }

.w3crm .ec-loan-summary-card {
    border-color: var(--crm-border);
    box-shadow: 0 0.125rem 0.25rem rgba(30, 34, 40, .04);
}

.w3crm .ec-loan-command-card {
    border-color: var(--crm-border);
    background:
        linear-gradient(135deg, rgba(35, 156, 239, .06), rgba(255,255,255,0) 42%),
        #fff;
    box-shadow: 0 .25rem .75rem rgba(30, 34, 40, .045);
}

.w3crm .ec-loan-command-card h4 {
    color: var(--title);
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.2;
}

.w3crm .ec-loan-command-card .text-muted {
    font-size: .86rem;
}

.w3crm .ec-w3crm-mini-stat {
    min-height: 72px;
    padding: .85rem 1rem;
    border: 1px solid var(--crm-border);
    border-radius: .5rem;
    background: var(--crm-soft);
}

.w3crm .ec-w3crm-mini-stat span {
    display: block;
    color: var(--crm-muted);
    font-size: .72rem;
    font-weight: 600;
    letter-spacing: .025em;
    line-height: 1.2;
    text-transform: uppercase;
}

.w3crm .ec-w3crm-mini-stat strong {
    display: block;
    margin-top: .25rem;
    color: var(--title);
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.15;
    white-space: nowrap;
}

.w3crm .ec-loan-tab-card {
    border-color: var(--crm-border);
    box-shadow: none;
}

.w3crm .ec-tab-panel > .row > [class*="col-"] > .card {
    border-color: var(--crm-border);
    box-shadow: 0 0.125rem 0.25rem rgba(30, 34, 40, .035);
}

.w3crm .ec-key-value dd {
    max-width: 62%;
    overflow-wrap: anywhere;
}

.w3crm .ec-tab-panel {
    animation: ecFadeIn .16s ease-out;
}

.w3crm .ec-tab-panel .ec-grid {
    display: grid;
    gap: 1rem;
    margin-bottom: 1rem;
}

.w3crm .ec-tab-panel .ec-grid-two {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.w3crm .ec-tab-panel article.card.h-auto:not(:has(> .card-body)):not(:has(> .card-header)) {
    padding: 1.25rem;
}

.w3crm .ec-tab-panel article.card {
    border-color: var(--crm-border);
    box-shadow: 0 .125rem .25rem rgba(30, 34, 40, .035);
}

.w3crm .ec-tab-panel article.card > .text-primary,
.w3crm .ec-tab-panel .card-body > .text-primary {
    color: var(--primary) !important;
    font-size: .72rem;
    font-weight: 700 !important;
    letter-spacing: .025em;
}

.w3crm .ec-tab-panel article.card h2,
.w3crm .ec-tab-panel article.card h3 {
    color: var(--title);
    font-size: 1.35rem;
    font-weight: 600;
    letter-spacing: -.01em;
    line-height: 1.25;
    margin-bottom: .85rem;
}

.w3crm .ec-tab-panel article.card h5 {
    color: var(--title);
    font-size: 1rem;
    font-weight: 600;
}

.w3crm .ec-tab-panel .text-muted {
    color: var(--crm-muted) !important;
    line-height: 1.55;
}

.w3crm .ec-tab-panel .table-responsive {
    border: 1px solid var(--crm-border);
    border-radius: .375rem;
    background: #fff;
}

.w3crm .ec-tab-panel .table {
    color: #777;
}

.w3crm .ec-tab-panel .table thead th {
    background: #f4f7fb;
    color: var(--title);
    font-size: .75rem;
    font-weight: 700;
    text-transform: none;
    white-space: nowrap;
}

.w3crm .ec-tab-panel .table td,
.w3crm .ec-tab-panel .table th {
    padding: .8rem .9rem;
    vertical-align: middle;
}

.w3crm .ec-tab-panel .table td strong,
.w3crm .ec-tab-panel .table td small {
    display: block;
}

.w3crm .ec-tab-panel .ec-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .4rem;
    min-height: 2.25rem;
    padding: .45rem .9rem;
    border: 1px solid var(--primary);
    border-radius: .375rem;
    background: var(--primary);
    color: #fff;
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none;
    transition: all .16s ease;
}

.w3crm .ec-tab-panel .ec-button:hover {
    background: #0b88df;
    color: #fff;
}

.w3crm .ec-tab-panel .ec-button-secondary {
    border-color: var(--rgba-primary-2);
    background: var(--rgba-primary-1);
    color: var(--primary);
}

.w3crm .ec-tab-panel .ec-button-secondary:hover {
    border-color: var(--primary);
    background: var(--primary);
    color: #fff;
}

.w3crm .ec-tab-panel .ec-button-compact {
    min-height: 2rem;
    padding: .4rem .75rem;
    font-size: .8rem;
}

.w3crm .ec-tab-panel .ec-inline-actions,
.w3crm .ec-tab-panel .ec-inline-actions-wrap {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
}

.w3crm .ec-tab-panel .ec-stack-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.w3crm .ec-workbench-note {
    margin-bottom: 1rem;
    padding: .8rem .9rem;
    border: 1px solid var(--rgba-primary-2);
    border-left: 3px solid var(--primary);
    border-radius: .375rem;
    background: var(--rgba-primary-1);
    color: var(--title);
    line-height: 1.45;
}

.w3crm .ec-file-tabs {
    display: flex;
    flex-wrap: nowrap;
    gap: .125rem;
    margin: 0 0 1.25rem;
    border-bottom: 1px solid var(--crm-border);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.w3crm .ec-file-tabs::-webkit-scrollbar { display: none; }

.w3crm .ec-file-tabs__tab {
    padding: .6rem 1.1rem;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    color: var(--crm-muted);
    font-size: .8rem;
    font-weight: 500;
    text-decoration: none;
    white-space: nowrap;
}

.w3crm .ec-file-tabs__tab:hover {
    color: var(--primary, #0d99ff);
}

.w3crm .ec-file-tabs__tab.is-active {
    color: var(--primary, #0d99ff);
    border-bottom-color: var(--primary, #0d99ff);
    font-weight: 600;
}

.w3crm .ec-workspace-disclosure {
    margin-top: 1rem;
    border: 1px solid var(--crm-border);
    border-radius: .375rem;
    background: #fff;
}

.w3crm .ec-workspace-disclosure summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.25rem;
    cursor: pointer;
}

.w3crm .ec-workspace-disclosure summary strong {
    color: var(--title);
    font-weight: 600;
}

.w3crm .ec-workspace-disclosure summary small {
    display: block;
    color: var(--crm-muted);
    margin-top: .15rem;
}

.w3crm .ec-workspace-disclosure > div {
    padding: 0 1rem 1rem;
}

.w3crm .ec-report-library-list {
    display: grid;
    gap: .65rem;
}

.w3crm .ec-report-library-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding: .85rem 0;
    border-bottom: 1px solid var(--crm-border);
}

.w3crm .ec-report-library-row h3 {
    font-size: .95rem !important;
    margin: 0 .5rem .2rem 0 !important;
}

.w3crm .ec-loan-empty-state {
    display: grid;
    grid-template-columns: 2.75rem minmax(0, 1fr);
    gap: .35rem .8rem;
    align-items: center;
    max-width: 42rem;
    padding: 1rem;
    border: 1px dashed var(--crm-border);
    border-radius: .5rem;
    background: #fafcff;
    list-style: none;
}

.w3crm .ec-loan-empty-state i {
    grid-row: span 2;
    display: grid;
    place-items: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: .5rem;
    background: var(--rgba-primary-1);
    color: var(--primary);
    font-size: 1.15rem;
}

.w3crm .ec-loan-empty-state strong {
    color: var(--title);
    font-weight: 600;
}

.w3crm .ec-loan-empty-state span {
    color: var(--crm-muted);
    line-height: 1.45;
}

@keyframes ecFadeIn {
    from { opacity: .75; transform: translateY(3px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 1199.98px) {
    .w3crm .ec-tab-panel .ec-grid-two {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 767.98px) {
    .w3crm .ec-tab-panel article.card.h-auto:not(:has(> .card-body)):not(:has(> .card-header)) {
        padding: 1rem;
    }

    .w3crm .ec-tab-panel article.card h2 {
        font-size: 1.15rem;
    }

    .w3crm .ec-stack-header,
    .w3crm .ec-report-library-row {
        display: grid;
    }
}
.w3crm .ec-bullet-list { margin: 0; padding-left: 1.15rem; }
.w3crm .ec-bullet-list li + li { margin-top: .55rem; }

.w3crm .ec-callout { padding: .85rem 1rem; border: 1px solid var(--rgba-primary-2); border-left: 3px solid var(--primary); border-radius: .375rem; background: var(--rgba-primary-1); color: var(--title); }
.w3crm .ec-callout-warning { border-color: rgba(255,159,0,.25); border-left-color: var(--crm-warning); background: rgba(255,159,0,.08); }
.w3crm .ec-callout-danger { border-color: rgba(255,94,94,.25); border-left-color: var(--crm-danger); background: rgba(255,94,94,.08); }
.w3crm .ec-callout-success { border-color: rgba(58,201,119,.25); border-left-color: var(--crm-success); background: rgba(58,201,119,.08); }
.w3crm .ec-callout-compact { padding: .65rem .8rem; }

.w3crm.edgecapital-public-intake .ec-public-authorization { background: var(--rgba-primary-1, rgba(0,150,255,.06)); border: 2px solid var(--primary, #0096ff); border-radius: .5rem; margin-top: 1.125rem; padding: 1rem 1.125rem; }
.w3crm.edgecapital-public-intake .ec-public-authorization-heading { align-items: center; display: flex; justify-content: space-between; margin-bottom: .75rem; }
.w3crm.edgecapital-public-intake .ec-public-authorization-heading > strong { color: var(--title); font-size: 1rem; }
.w3crm.edgecapital-public-intake .ec-public-authorization-check { align-items: flex-start; cursor: pointer; display: flex; font-size: .875rem; line-height: 1.55; }
.w3crm.edgecapital-public-intake .ec-public-authorization-check input[type="checkbox"] { accent-color: var(--primary); cursor: pointer; flex: 0 0 1.5rem; height: 1.5rem; margin: .0625rem .125rem 0 0; width: 1.5rem; }
.w3crm.edgecapital-public-intake .ec-public-authorization-check span { color: var(--text); }
.w3crm.edgecapital-public-intake .ec-public-authorization-check span > strong { color: var(--primary); }

.w3crm .ec-light-sign { display: inline-flex; align-items: center; gap: .35rem; padding: .35rem .6rem; border-radius: .25rem; background: var(--rgba-primary-1); color: var(--primary); font-size: .75rem; font-weight: 500; white-space: nowrap; }
.w3crm .ec-light-sign__dot { width: .45rem; height: .45rem; border-radius: 50%; background: currentColor; }
.w3crm .ec-light-sign.is-good { color: var(--crm-success); background: rgba(58,201,119,.1); }
.w3crm .ec-light-sign.is-info { color: var(--primary); background: var(--rgba-primary-1); }
.w3crm .ec-light-sign.is-warning { color: #b87900; background: rgba(255,159,0,.1); }
.w3crm .ec-light-sign.is-danger { color: var(--crm-danger); background: rgba(255,94,94,.1); }
.w3crm .ec-light-sign.is-muted { color: #777; background: #f0f0f0; }
.w3crm .ec-light-sign-tiny { padding: .25rem .45rem; font-size: .7rem; }

.w3crm .ec-modal-backdrop { position: fixed; inset: 0; z-index: 1060; display: grid; place-items: center; padding: 1.5rem; background: rgba(19,19,19,.45); -webkit-backdrop-filter: blur(5px); backdrop-filter: blur(5px); overflow-y: auto; }
.w3crm .ec-modal-backdrop[hidden] { display: none !important; }
.w3crm .ec-modal-card { width: min(100%, 48rem); max-height: calc(100vh - 3rem); overflow-y: auto; background: #fff; border-radius: .5rem; box-shadow: 0 1.5rem 4rem rgba(0,0,0,.2); }
.w3crm .ec-modal-card-sm { width: min(100%, 34rem); }
.w3crm .ec-modal-card-xl { width: min(100%, 78rem); }
.w3crm .ec-modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--crm-border); }
.w3crm .ec-modal-title-block { display: flex; align-items: flex-start; gap: .75rem; }
.w3crm .ec-modal-title-icon { display: inline-grid; place-items: center; width: 2.5rem; height: 2.5rem; border-radius: .375rem; background: var(--rgba-primary-1); color: var(--primary); }
.w3crm .ec-modal-close { border: 0; background: transparent; color: #888; font-size: 1.75rem; line-height: 1; }
.w3crm .ec-modal-form,
.w3crm .ec-action-modal__content { padding: 1.5rem; }
.w3crm .ec-action-modal__content { display: grid; grid-template-columns: minmax(0,1fr) 18rem; gap: 1.25rem; }
.w3crm .ec-action-modal__side { display: grid; align-content: start; gap: 1rem; }
.w3crm .ec-w3crm-modal .modal-content {
    border: 1px solid var(--crm-border);
    border-radius: .375rem;
    box-shadow: 0 1rem 2.5rem rgba(0,0,0,.16);
}
.w3crm .ec-w3crm-modal .modal-dialog {
    max-width: min(1180px, calc(100vw - 2rem));
}
.w3crm .ec-w3crm-modal .modal-header {
    align-items: flex-start;
    gap: 1rem;
    padding: 1.25rem 1.5rem;
    border-bottom-color: var(--crm-border);
}
.w3crm .ec-w3crm-modal .modal-title {
    color: var(--title);
    font-size: 1.125rem;
    font-weight: 600;
}
.w3crm .ec-w3crm-modal .modal-body {
    color: #888;
    background: var(--crm-soft);
}
.w3crm .ec-w3crm-modal .btn-close {
    opacity: .65;
}
.w3crm .ec-w3crm-modal .ec-wizard-shell {
    display: grid;
    grid-template-columns: 17rem minmax(0, 1fr);
    min-height: 34rem;
    background: var(--crm-soft);
}
.w3crm .ec-w3crm-modal .ec-wizard-rail {
    display: grid;
    align-content: start;
    gap: 1rem;
    padding: 1.25rem;
    border-right: 1px solid var(--crm-border);
    background: #fff;
}
.w3crm .ec-w3crm-modal .ec-wizard-rail-head {
    padding-bottom: .85rem;
    border-bottom: 1px solid var(--crm-border);
}
.w3crm .ec-w3crm-modal .ec-wizard-rail-head p {
    margin-bottom: 0;
}
.w3crm .ec-w3crm-modal .ec-wizard-rail-list {
    display: grid;
    gap: .55rem;
}
.w3crm .ec-w3crm-modal .ec-wizard-rail-item {
    display: grid;
    grid-template-columns: 2rem minmax(0, 1fr) 1rem;
    align-items: center;
    gap: .65rem;
    padding: .65rem .7rem;
    border: 1px solid transparent;
    border-radius: .375rem;
    color: var(--crm-muted);
    background: transparent;
}
.w3crm .ec-w3crm-modal .ec-wizard-rail-item.is-current {
    border-color: var(--rgba-primary-2);
    background: var(--rgba-primary-1);
    color: var(--primary);
}
.w3crm .ec-w3crm-modal .ec-wizard-rail-item.is-complete {
    color: var(--crm-success);
}
/* Passed but its required data is still missing: never shown as Complete. */
.w3crm .ec-w3crm-modal .ec-wizard-rail-item.is-incomplete {
    color: #b87900;
}
.w3crm .ec-w3crm-modal .ec-wizard-rail-badge {
    display: inline-grid;
    width: 2rem;
    height: 2rem;
    place-items: center;
    border-radius: .375rem;
    background: var(--crm-soft);
    color: inherit;
    font-size: .75rem;
    font-weight: 600;
}
.w3crm .ec-w3crm-modal .ec-wizard-rail-item.is-current .ec-wizard-rail-badge {
    background: var(--primary);
    color: #fff;
}
.w3crm .ec-w3crm-modal .ec-wizard-rail-copy {
    display: grid;
    gap: .1rem;
    min-width: 0;
}
.w3crm .ec-w3crm-modal .ec-wizard-rail-copy strong {
    color: var(--title);
    font-size: .8125rem;
    line-height: 1.25;
}
.w3crm .ec-w3crm-modal .ec-wizard-rail-copy span {
    font-size: .72rem;
}
.w3crm .ec-w3crm-modal .ec-wizard-rail-check {
    visibility: hidden;
    font-size: .75rem;
}
.w3crm .ec-w3crm-modal .ec-wizard-rail-item.is-complete .ec-wizard-rail-check {
    visibility: visible;
}
.w3crm .ec-w3crm-modal .ec-wizard-stage {
    min-width: 0;
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
}
.w3crm .ec-w3crm-modal .ec-wizard-stage-body {
    min-width: 0;
    padding: 1.25rem;
}
.w3crm .ec-w3crm-modal .ec-wizard-panel {
    display: grid;
    gap: 1rem;
    border: 0;
    box-shadow: none;
}
.w3crm .ec-w3crm-modal .ec-wizard-panel[hidden] {
    display: none !important;
}
.w3crm .ec-w3crm-modal .ec-stack-header {
    margin-bottom: .35rem;
}
.w3crm .ec-w3crm-modal .ec-stack-header h3 {
    margin-bottom: .35rem;
    font-size: 1.45rem;
}
.w3crm .ec-w3crm-modal .ec-wizard-subsection {
    display: grid;
    gap: .9rem;
}
.w3crm .ec-w3crm-modal .ec-wizard-subsection h4 {
    margin-bottom: 0;
    color: var(--title);
    font-size: 1rem;
}
.w3crm .ec-w3crm-modal .ec-wizard-party-toggle {
    display: inline-grid;
    grid-template-columns: auto auto auto;
    align-items: center;
    gap: .5rem;
}
.w3crm .ec-w3crm-modal .ec-wizard-party-option {
    color: var(--crm-muted);
    font-size: .8125rem;
    font-weight: 500;
}
.w3crm .ec-w3crm-modal .ec-modal-actions {
    position: sticky;
    bottom: 0;
    z-index: 2;
    margin-top: 0;
    padding: 1rem 1.25rem;
    border-top: 1px solid var(--crm-border);
    background: #fff;
}
.w3crm .ec-w3crm-modal .ec-modal-actions-between {
    justify-content: space-between;
}
.w3crm .ec-w3crm-modal .ec-wizard-review-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}
.w3crm .ec-w3crm-modal .ec-wizard-review-card {
    padding: 1rem;
    border: 1px solid var(--crm-border);
    border-radius: .375rem;
    background: #fff;
}

.w3crm .ec-tab,
.w3crm .ec-tab-button { border: 1px solid var(--crm-border); border-radius: .375rem; padding: .55rem .85rem; background: #fff; color: #777; }
.w3crm .ec-tab.is-active,
.w3crm .ec-tab-button.is-active { border-color: var(--primary); background: var(--rgba-primary-1); color: var(--primary); }
.w3crm .ec-tab-panel[hidden] { display: none !important; }
.w3crm .ec-compressed-details { border: 1px solid var(--crm-border); border-radius: .375rem; background: #fff; }
.w3crm .ec-compressed-details + .ec-compressed-details { margin-top: 1rem; }
.w3crm .ec-compressed-summary { position: relative; cursor: pointer; padding: 1rem 3.25rem 1rem 1.25rem; list-style: none; user-select: none; }
.w3crm .ec-compressed-summary::-webkit-details-marker,
.w3crm .w3crm-details-summary::-webkit-details-marker { display: none; }
.w3crm .ec-compressed-summary::after,
.w3crm .w3crm-details-summary::after {
    content: "";
    position: absolute;
    right: 1.25rem;
    top: 50%;
    width: .6rem;
    height: .6rem;
    border-right: 2px solid var(--crm-muted);
    border-bottom: 2px solid var(--crm-muted);
    transform: translateY(-65%) rotate(45deg);
    transition: transform .18s ease, border-color .18s ease;
}
.w3crm details[open] > .ec-compressed-summary::after,
.w3crm details[open] > .w3crm-details-summary::after {
    transform: translateY(-35%) rotate(225deg);
    border-color: var(--primary);
}
.w3crm .ec-compressed-details[open] > .ec-compressed-summary { border-bottom: 1px solid var(--crm-border); }
.w3crm .ec-account-header-actions { display: flex; align-items: center; justify-content: flex-end; gap: .5rem; flex-wrap: wrap; }
.w3crm .ec-compact-metric-grid > div { display: grid; align-content: start; gap: .18rem; min-width: 0; }
.w3crm .ec-compact-metric-grid span,
.w3crm .ec-compact-metric-grid small { display: block; line-height: 1.25; }
.w3crm .ec-compact-metric-grid strong { display: block; color: var(--title); line-height: 1.15; overflow-wrap: anywhere; }

.w3crm .ec-pagination { display: flex; flex-wrap: wrap; gap: .35rem; }
.w3crm .ec-pagination-link { display: inline-grid; min-width: 2rem; height: 2rem; place-items: center; border: 1px solid var(--crm-border); border-radius: .25rem; color: var(--primary); background: #fff; }
.w3crm .ec-pagination-link.is-active { color: #fff; background: var(--primary); border-color: var(--primary); }

.w3crm .ec-sensitive-value {
    align-items: center;
    display: inline-flex;
    gap: .4rem;
}

.w3crm .ec-sensitive-reveal {
    align-items: center;
    display: inline-flex;
    height: 1.75rem;
    justify-content: center;
    min-width: 1.75rem;
    padding: 0;
}

.w3crm .ec-sensitive-reveal i {
    font-size: .85rem;
    line-height: 1;
}

.w3crm .ec-sensitive-reveal.is-loading {
    opacity: .72;
}

@media (max-width: 991.98px) {
    .w3crm .ec-grid-two,
    .w3crm .ec-grid-three,
    .w3crm .ec-form-grid-3,
    .w3crm .ec-form-grid-4,
    .w3crm .ec-action-modal__content { grid-template-columns: 1fr; }
    .w3crm .ec-form-span-2 { grid-column: auto; }
    .w3crm .ec-doc-filter-form,
    .w3crm .ec-applications-filter-form,
    .w3crm .ec-underwriting-layout,
    .w3crm .ec-underwriting-review-grid,
    .w3crm .ec-doc-kpi-grid,
    .w3crm .ec-report-kpi-grid,
    .w3crm .ec-portfolio-intelligence .ec-report-kpi-grid,
    .w3crm .ec-report-status-strip,
    .w3crm .ec-report-coverage-grid,
    .w3crm .ec-payment-filter-form,
    .w3crm .ec-payment-kpi-grid,
    .w3crm .ec-payment-queue-row,
    .w3crm .ec-payment-receipt-row { grid-template-columns: minmax(0, 1fr); }
    .w3crm .ec-doc-filter-actions,
    .w3crm .ec-applications-filter-actions { justify-content: flex-start; flex-wrap: wrap; }
    .w3crm .ec-applications-workspace .active-projects.table-responsive { overflow-x: auto; }
    .w3crm .ec-applications-workspace .active-projects table.shorting { min-width: 1120px !important; table-layout: auto; }
    .w3crm .ec-report-library-row { grid-template-columns: minmax(0, 1fr); align-items: start; }
    .w3crm .ec-report-library-action { justify-content: flex-start; }
    .w3crm .ec-payment-filter-actions,
    .w3crm .ec-payment-queue-actions { justify-content: flex-start; justify-items: start; }
    .w3crm .ec-sync-flow { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 575.98px) {
    .w3crm .ec-main-guest { padding: 1rem; }
    .w3crm .ec-auth-card,
    .w3crm .ec-card,
    .w3crm .ec-panel,
    .w3crm .ec-wizard-panel { padding: 1rem; }
    .w3crm .ec-grid-two,
    .w3crm .ec-form-grid-2 { grid-template-columns: 1fr; }
    .w3crm .ec-modal-backdrop { padding: .5rem; }
    .w3crm .ec-modal-card { max-height: calc(100vh - 1rem); }
    .w3crm .ec-modal-head,
    .w3crm .ec-modal-form,
    .w3crm .ec-action-modal__content { padding: 1rem; }
    .w3crm .ec-button { width: 100%; }
    .w3crm .ec-inline-actions,
    .w3crm .ec-modal-actions { align-items: stretch; flex-direction: column; }
    .w3crm .ec-doc-filter-actions { align-items: stretch; flex-direction: column; }
    .w3crm .ec-doc-filter-actions .btn { width: 100%; }
    .w3crm .ec-doc-table-caption,
    .w3crm .ec-doc-pagination { padding: 1rem; }
    .w3crm .ec-applications-hero__actions,
    .w3crm .ec-applications-filter-actions,
    .w3crm .ec-applications-filter-actions .btn { width: 100%; }
    .w3crm .ec-applications-hero__actions,
    .w3crm .ec-applications-filter-actions { align-items: stretch; flex-direction: column; }
    .w3crm .ec-applications-workspace .tbl-caption { padding: 1rem; }
    .w3crm .ec-applications-workspace .ec-light-sign,
    .w3crm .ec-collections-hero .ec-light-sign { white-space: normal; }
    .w3crm .ec-underwriting-grid { grid-template-columns: minmax(0, 1fr); }
    .w3crm .ec-underwriting-panel-head,
    .w3crm .ec-underwriting-step-actions,
    .w3crm .ec-underwriting-step-actions .ec-button { width: 100%; }
    .w3crm .ec-underwriting-panel-head,
    .w3crm .ec-underwriting-step-actions { align-items: stretch; flex-direction: column; }
    .w3crm .ec-underwriting-layout .ec-inline-actions .ec-button { width: 100%; }
    .w3crm .ec-underwriting-layout .ec-light-sign { white-space: normal; }
    .w3crm .ec-report-hero__actions,
    .w3crm .ec-report-library-action,
    .w3crm .ec-report-library-action .ec-button { width: 100%; }
    .w3crm .ec-report-hero__actions { align-items: stretch; flex-direction: column; }
    .w3crm .ec-report-workspace .ec-light-sign { white-space: normal; }
    .w3crm .ec-report-library-row,
    .w3crm .ec-report-coverage-item { padding: .9rem; }
    .w3crm .ec-payment-hero__actions,
    .w3crm .ec-payment-filter-actions,
    .w3crm .ec-payment-queue-actions,
    .w3crm .ec-payment-queue-actions .ec-button,
    .w3crm .ec-payment-queue-actions .btn,
    .w3crm .ec-payment-receipt-row .btn { width: 100%; }
    .w3crm .ec-payment-hero__actions,
    .w3crm .ec-payment-filter-actions { align-items: stretch; flex-direction: column; }
    .w3crm .ec-payment-desk .ec-light-sign { white-space: normal; }
    .w3crm .ec-payment-queue-row { padding: .9rem; }
    .w3crm .ec-sync-flow { grid-template-columns: minmax(0, 1fr); }
    .w3crm .ec-sync-workspace .tbl-caption { padding: 1rem; }
}
.ec-loan-tab-card {
    position: sticky;
    top: 102px;
    z-index: 6;
    border-color: #e6e6e6;
    box-shadow: none;
}

.ec-loan-tab-card .nav-tabs {
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
}

.ec-loan-tab-card .nav-link {
    flex: 0 0 auto;
    color: #717579;
    font-size: 0.8rem;
    white-space: nowrap;
}

.ec-loan-tab-card .nav-link.is-active {
    border-color: transparent transparent #0d99ff;
    color: #0d99ff;
}

.w3crm .ec-loan-payment-form .form-label {
    color: var(--title);
    font-size: .8125rem;
    font-weight: 500;
}

.w3crm .ec-loan-payment-form textarea.form-control {
    min-height: 6rem;
}

/* Collections split workspace: W3CRM collector mode */
.w3crm .ec-collections-workspace {
    --ec-rail-width: 360px;
    display: grid;
    grid-template-columns: var(--ec-rail-width) minmax(640px, 1fr);
    height: calc(100vh - 11.25rem);
    min-height: 42rem;
    overflow: hidden;
    border: 1px solid var(--crm-border);
    border-radius: .5rem;
    background: #fff;
}

.w3crm .ec-collections-rail {
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    min-width: 0;
    border-right: 1px solid var(--crm-border);
    background: #fff;
}

.w3crm .ec-collections-rail__head {
    position: sticky;
    top: 0;
    z-index: 2;
    display: grid;
    gap: .75rem;
    padding: 1rem;
    border-bottom: 1px solid var(--crm-border);
    background: #fff;
}

.w3crm .ec-collections-rail__title {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: .75rem;
}

.w3crm .ec-collections-rail__title h2,
.w3crm .ec-collection-account-head h2,
.w3crm .ec-collections-pane-empty h2 {
    margin: 0;
    color: var(--title);
    font-size: 1.25rem;
    font-weight: 600;
}

.w3crm .ec-collections-rail__title strong {
    color: var(--title);
    font-size: .8rem;
    white-space: nowrap;
}

.w3crm .ec-collections-filters {
    display: flex;
    gap: .35rem;
    overflow-x: auto;
    padding-bottom: .1rem;
}

.w3crm .ec-collections-filters a {
    flex: 0 0 auto;
    padding: .35rem .55rem;
    border: 1px solid var(--crm-border);
    border-radius: .35rem;
    color: var(--crm-muted);
    font-size: .72rem;
    font-weight: 500;
    background: #fff;
}

.w3crm .ec-collections-filters a.is-active,
.w3crm .ec-collections-filters a:hover {
    border-color: var(--primary);
    background: var(--rgba-primary-1);
    color: var(--primary);
}

.w3crm .ec-collections-summary-strip {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .5rem;
}

.w3crm .ec-collections-summary-strip span {
    display: grid;
    gap: .1rem;
    padding: .55rem .65rem;
    border: 1px solid var(--crm-border);
    border-radius: .375rem;
    background: var(--crm-soft);
    color: var(--crm-muted);
    font-size: .72rem;
}

.w3crm .ec-collections-summary-strip strong {
    color: var(--title);
    font-size: .95rem;
}

.w3crm .ec-collections-rail__body,
.w3crm .ec-collections-pane {
    min-height: 0;
    overflow-y: auto;
}

.w3crm .ec-collection-row {
    display: grid;
    grid-template-columns: .65rem minmax(0, 1fr);
    gap: .65rem;
    min-height: 72px;
    padding: .75rem .85rem;
    border-bottom: 1px solid var(--crm-border);
    color: var(--title);
    background: #fff;
}

.w3crm .ec-collection-row:hover,
.w3crm .ec-collection-row.is-selected {
    color: var(--title);
    background: var(--rgba-primary-1);
}

.w3crm .ec-collection-row.is-selected {
    box-shadow: inset 3px 0 0 var(--primary);
}

.w3crm .ec-collection-row__state {
    width: .5rem;
    height: .5rem;
    margin-top: .35rem;
    border-radius: 50%;
    background: var(--crm-warning);
}

.w3crm .ec-collection-row__state.is-danger { background: var(--crm-danger); }
.w3crm .ec-collection-row__state.is-warning { background: var(--crm-warning); }

.w3crm .ec-collection-row__main,
.w3crm .ec-collection-row__line {
    min-width: 0;
}

.w3crm .ec-collection-row__line {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
    line-height: 1.25;
}

.w3crm .ec-collection-row__line strong,
.w3crm .ec-collection-row__line span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.w3crm .ec-collection-row__note {
    margin-top: .2rem;
    color: var(--crm-muted);
    font-size: .72rem;
}

.w3crm .ec-collections-empty,
.w3crm .ec-collections-pane-empty {
    display: grid;
    align-content: center;
    justify-items: start;
    gap: .65rem;
    min-height: 16rem;
    padding: 1.25rem;
    color: var(--crm-muted);
}

.w3crm .ec-collections-pane {
    position: relative;
    background: #f8f9fc;
}

.w3crm .ec-collection-pane-card {
    min-height: 100%;
    padding: 1rem;
}

.w3crm .ec-collection-account-head {
    position: sticky;
    top: 0;
    z-index: 3;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem;
    border: 1px solid var(--crm-border);
    border-radius: .5rem;
    background: #fff;
    box-shadow: 0 .35rem 1rem rgba(0, 0, 0, .04);
}

.w3crm .ec-collection-account-head p {
    margin: .25rem 0 0;
    color: var(--crm-muted);
}

.w3crm .ec-collection-kpis {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: .85rem;
    margin-top: 1rem;
}

.w3crm .ec-collection-kpis > div {
    display: grid;
    gap: .25rem;
    min-height: 6.4rem;
    padding: 1rem;
    border: 1px solid var(--crm-border);
    border-radius: .5rem;
    background: #fff;
}

.w3crm .ec-collection-kpis span,
.w3crm .ec-collection-kpis small,
.w3crm .ec-collection-contact-card strong,
.w3crm .ec-collection-outcome label > span:first-child {
    color: var(--crm-muted);
    font-size: .72rem;
    font-weight: 600;
}

.w3crm .ec-collection-kpis span {
    text-transform: uppercase;
    letter-spacing: .025em;
}

.w3crm .ec-collection-kpis strong {
    color: var(--title);
    font-size: clamp(1.35rem, 2vw, 1.6rem);
    font-weight: 600;
    line-height: 1.1;
    overflow-wrap: anywhere;
}

.w3crm .ec-collection-contact-card,
.w3crm .ec-collection-outcome,
.w3crm .ec-collection-details {
    display: grid;
    gap: .85rem;
    margin-top: 1rem;
}

.w3crm .ec-collection-contact-card {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.w3crm .ec-collection-contact-card > div,
.w3crm .ec-collection-outcome {
    padding: 1rem;
    border: 1px solid var(--crm-border);
    border-radius: .5rem;
    background: #fff;
}

.w3crm .ec-collection-contact-card > div {
    display: grid;
    gap: .35rem;
}

.w3crm .ec-collection-contact-card span {
    color: var(--title);
    overflow-wrap: anywhere;
}

.w3crm .ec-collection-outcome-buttons {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: .45rem;
}

.w3crm .ec-collection-outcome-buttons label {
    cursor: pointer;
}

.w3crm .ec-collection-outcome-buttons input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.w3crm .ec-collection-outcome-buttons span {
    display: grid;
    min-height: 2.5rem;
    place-items: center;
    padding: .45rem .35rem;
    border: 1px solid var(--crm-border);
    border-radius: .375rem;
    color: var(--crm-muted);
    background: #fff;
    font-size: .75rem;
    font-weight: 600;
    text-align: center;
}

.w3crm .ec-collection-outcome-buttons input:checked + span,
.w3crm .ec-collection-outcome-buttons span:hover {
    border-color: var(--primary);
    background: var(--rgba-primary-1);
    color: var(--primary);
}

.w3crm .ec-collection-promise-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .75rem;
}

.w3crm .ec-collection-promise-fields:not([hidden]) {
    display: grid;
}

.w3crm .ec-collection-note {
    display: grid;
    gap: .4rem;
}

.w3crm .ec-collection-pane-actions {
    display: flex;
    justify-content: flex-end;
    gap: .5rem;
}

.w3crm .ec-collection-details .ec-compressed-details {
    margin: 0;
}

@media (max-width: 1199.98px) {
    .w3crm .ec-collections-workspace {
        grid-template-columns: 300px minmax(560px, 1fr);
    }

    .w3crm .ec-collection-outcome-buttons {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (max-width: 991.98px) {
    .w3crm .ec-collections-workspace {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        height: auto;
        overflow: visible;
    }

    .w3crm .ec-collections-rail,
    .w3crm .ec-collections-pane {
        max-height: none;
        overflow: visible;
    }

    .w3crm .ec-collection-contact-card,
    .w3crm .ec-collection-kpis {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 575.98px) {
    .w3crm .ec-collection-outcome-buttons,
    .w3crm .ec-collection-promise-fields:not([hidden]) {
        grid-template-columns: minmax(0, 1fr);
    }

    .w3crm .ec-collection-account-head,
    .w3crm .ec-collection-pane-actions {
        align-items: stretch;
        flex-direction: column;
    }
}
/* Public intake validation follows the W3CRM form language while making recovery obvious. */
.ec-public-intake-wrap :is(input, select, textarea).is-invalid,
.ec-public-intake-wrap label.is-invalid :is(input, select, textarea) {
    border-color: #dc3545 !important;
    box-shadow: 0 0 0 0.16rem rgba(220, 53, 69, 0.14) !important;
}

.ec-public-intake-wrap .ec-field-error,
.ec-public-intake-wrap .invalid-feedback {
    color: #dc3545;
    display: block;
    font-size: 0.78rem;
    margin-top: 0.35rem;
}

.ec-missing-field-links {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin-left: 0.4rem;
}

.ec-missing-field-links button,
.ec-public-error-list button {
    appearance: none;
    background: transparent;
    border: 0;
    color: #dc3545;
    cursor: pointer;
    font: inherit;
    font-weight: 600;
    padding: 0;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.ec-missing-field-links button:not(:last-child)::after {
    color: #9b9b9b;
    content: " |";
    text-decoration: none;
}

.ec-missing-field-links button:focus-visible,
.ec-public-error-list button:focus-visible {
    border-radius: 3px;
    outline: 2px solid #1598ef;
    outline-offset: 3px;
}

/* ------------------------------------------------------------------ */
/* Approved CRM-wide look (docs/UX_SIMPLIFICATION_PLAN.md decision #6):
   flat white cards on a soft canvas, hairline borders, quiet table
   headers - matching the Edge CRM Workflow mockup canvas. */

.w3crm .content-body {
    background: var(--crm-soft, #f8f9fc);
}

.w3crm .card,
.w3crm .ec-card,
.w3crm .ec-panel {
    border: 1px solid var(--crm-border);
    border-radius: .5rem;
    box-shadow: none;
}

.w3crm .table thead th {
    background: var(--crm-soft, #f8f9fc);
    color: #a3a9b0;
    font-size: .6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .4px;
    border-bottom: 1px solid var(--crm-border);
}

.w3crm .table tbody td {
    border-bottom: 1px solid #f0f0f0;
}

.w3crm .menu-title {
    color: #a3a9b0;
    font-size: .6875rem;
    letter-spacing: .4px;
}

/* ------------------------------------------------------------------ */
/* Typography & density pass: functional, clean, mockup-scale.
   Tighter headings and chrome; body copy stays readable. */

.w3crm .content-body h1, .w3crm .content-body .h1 { font-size: 1.35rem; }
.w3crm .content-body h2, .w3crm .content-body .h2 { font-size: 1.15rem; }
.w3crm .content-body h3, .w3crm .content-body .h3 { font-size: 1rem; }
.w3crm .content-body h4, .w3crm .content-body .h4 { font-size: .95rem; }
.w3crm .content-body h5, .w3crm .content-body .h5 { font-size: .875rem; }

.w3crm .content-body .card-body { padding: 1.25rem; }
.w3crm .content-body .card-header { padding: 1rem 1.25rem; }

.w3crm .content-body .table td,
.w3crm .content-body .table th { padding: .65rem .85rem; font-size: .8125rem; }

.w3crm .content-body .btn { font-size: .8125rem; }
.w3crm .content-body .btn-sm { font-size: .78rem; padding: .42rem .8rem; }
.w3crm .content-body .badge { font-size: .6875rem; }

.w3crm .content-body p { line-height: 1.55; }
.w3crm .content-body .text-muted { font-size: .8125rem; }

.w3crm .ec-file-tabs button.ec-file-tabs__tab {
    background: none;
    border-top: 0;
    border-left: 0;
    border-right: 0;
    cursor: pointer;
    font-family: inherit;
}

/* Application dossier: open, theme-consistent summary cards. */
.w3crm .ec-dossier { display: grid; gap: 1rem; }
.w3crm .ec-dossier-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.w3crm .ec-dossier-card { background: var(--crm-surface, #fff); border: 1px solid var(--crm-border); border-radius: .5rem; padding: 1.25rem; box-shadow: none; }
.w3crm .ec-dossier-card__head { display: flex; align-items: flex-start; justify-content: space-between; gap: .75rem; margin-bottom: .85rem; }
.w3crm .ec-dossier-card__title { display: flex; align-items: center; gap: .55rem; }
.w3crm .ec-dossier-card__title h3 { font-size: .875rem; font-weight: 600; margin: 0; color: var(--title, #2c2c2c); }
.w3crm .ec-dossier-card__icon { width: 30px; height: 30px; border-radius: .375rem; display: inline-flex; align-items: center; justify-content: center; background: rgba(13, 153, 255, .10); color: var(--primary, #0d99ff); }
.w3crm .ec-dossier-rows { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem .9rem; margin: 0; }
.w3crm .ec-dossier-rows div { min-width: 0; }
.w3crm .ec-dossier-rows dt { font-size: .6875rem; font-weight: 600; text-transform: uppercase; letter-spacing: .4px; color: #a3a9b0; margin-bottom: .1rem; }
.w3crm .ec-dossier-rows dd { font-size: .8125rem; font-weight: 500; color: var(--title, #2c2c2c); margin: 0; word-break: break-word; }
.w3crm .ec-dossier-wide { grid-column: 1 / -1; }
.w3crm .ec-dossier-footer { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .9rem; padding-top: .75rem; border-top: 1px solid #f0f0f0; }
@media (max-width: 991.98px) {
    .w3crm .ec-dossier-grid,
    .w3crm .ec-dossier-rows { grid-template-columns: minmax(0, 1fr); }
}

.w3crm .ec-applications-filter-form--bare { border-top: 0; padding-top: 0; }

/* Closing four-gate rail (per the approved Edge CRM Workflow mockup). */
.w3crm .ec-closing-layout { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 1rem; align-items: start; }
.w3crm .ec-closing-gates { position: sticky; top: 5.5rem; display: grid; gap: .5rem; }
.w3crm .ec-closing-gate { display: flex; align-items: center; gap: .7rem; padding: .8rem .9rem; background: var(--crm-surface, #fff); border: 1px solid var(--crm-border); border-radius: .5rem; text-decoration: none; }
.w3crm .ec-closing-gate.is-active { border-color: var(--primary, #0d99ff); box-shadow: 0 3px 10px rgba(13, 153, 255, .10); }
.w3crm .ec-closing-gate__state { width: .65rem; height: .65rem; border-radius: 50%; flex: none; background: #ced4da; }
.w3crm .ec-closing-gate__state.is-good { background: var(--crm-success, #3ac977); }
.w3crm .ec-closing-gate__state.is-warning { background: var(--crm-warning, #ff9f00); }
.w3crm .ec-closing-gate__body strong { display: block; color: var(--title, #2c2c2c); font-size: .85rem; }
.w3crm .ec-closing-gate__body small { display: block; color: var(--crm-muted); font-size: .72rem; line-height: 1.3; }
.w3crm .ec-closing-gates__note { margin: .25rem 0 0; padding: .7rem .8rem; border: 1px solid #ffe1c4; background: #fff7ee; border-radius: .5rem; font-size: .72rem; line-height: 1.45; color: #b25e00; }
@media (max-width: 1199.98px) {
    .w3crm .ec-closing-layout { grid-template-columns: minmax(0, 1fr); }
    .w3crm .ec-closing-gates { position: static; grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .w3crm .ec-closing-gates__note { grid-column: 1 / -1; }
}

/* Application file header - shared by every file screen via command-header
   (moved from the Summary-only stage-progress-board partial). */
.w3crm .ec-application-file-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin: 0 0 1.25rem !important; padding: .85rem 1rem !important; background: var(--crm-surface, #fff); border: 1px solid var(--crm-border); border-radius: var(--bs-border-radius, .375rem); box-shadow: none !important; }
.w3crm .ec-application-file-head__title-row { display: flex; align-items: center; gap: .5rem; }
.w3crm .ec-application-file-head__title-row h1 { margin: 0; font-size: 1.25rem; line-height: 1.25; }
.w3crm .ec-application-file-head__meta { display: flex; flex-wrap: wrap; gap: .25rem .85rem; margin-top: .25rem; font-size: .76rem; color: #888; }
.w3crm .ec-application-file-head .ec-inline-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .4rem; }
.w3crm .ec-application-file-head .btn { min-height: auto; padding: .42rem .7rem; border-radius: var(--bs-border-radius, .375rem); font-size: .78rem; box-shadow: none; }
@media (max-width: 991.98px) {
    .w3crm .ec-application-file-head { align-items: flex-start; flex-direction: column; }
    .w3crm .ec-application-file-head .ec-inline-actions { justify-content: flex-start; }
}

/* File progress checklist card (approved mockup). */
.w3crm .ec-file-progress { display: grid; gap: .65rem; margin: 0; padding: 0; list-style: none; }
.w3crm .ec-file-progress li { display: flex; align-items: center; gap: .6rem; font-size: .8125rem; color: var(--crm-muted); }
.w3crm .ec-file-progress li.is-complete { color: var(--title, #2c2c2c); }
.w3crm .ec-file-progress li.is-current { color: var(--title, #2c2c2c); font-weight: 600; }
.w3crm .ec-file-progress .bi { flex: none; font-size: 1rem; }
.w3crm .ec-file-progress li.is-complete .bi { color: var(--crm-success, #3ac977); }
.w3crm .ec-file-progress li.is-current .bi { color: var(--primary, #0d99ff); }
.w3crm .ec-file-progress li.is-upcoming .bi { color: #ced4da; }

/* Header on the light shell: icon color + collapsed-sidebar logo behavior. */
.w3crm .header-right .nav-link { color: #5b6472; }
.w3crm .menu-toggle .nav-header .edge-brand-logo .brand-title { display: none; }
.w3crm .menu-toggle .nav-header .edge-brand-logo .logo-abbr { display: block; margin: 0 auto; }

/* ===== One Clean Workflow R3: Complete-the-File workspace (rail + panels) ===== */
.w3crm .ec-file-work { display: grid; grid-template-columns: minmax(15rem, 19rem) minmax(0, 1fr); gap: 1.25rem; align-items: start; }
.w3crm .ec-file-rail { padding: 1rem; display: grid; gap: .5rem; margin-bottom: 0; }
.w3crm .ec-file-meter { padding: .75rem .9rem; border: 1px solid var(--crm-border, #e6e6e6); border-radius: .375rem; font-size: .8125rem; }
.w3crm .ec-file-meter__bar { height: 6px; background: var(--crm-border, #e6e6e6); border-radius: 4px; margin-top: .55rem; overflow: hidden; }
.w3crm .ec-file-meter__bar i { display: block; height: 100%; background: var(--primary, #0d99ff); border-radius: 4px; }
.w3crm .ec-file-rail__item { display: flex; align-items: center; gap: .65rem; padding: .65rem .8rem; border: 1px solid var(--crm-border, #e6e6e6); border-radius: .375rem; color: var(--title, #2c2c2c); min-width: 0; }
.w3crm a.ec-file-rail__item:hover,
.w3crm a.ec-file-rail__item:focus { color: var(--primary, #0d99ff); border-color: var(--rgba-primary-2, rgba(13, 153, 255, .2)); background: var(--rgba-primary-1, rgba(13, 153, 255, .1)); }
.w3crm .ec-file-rail__item.is-active { border-color: var(--primary, #0d99ff); box-shadow: inset 0 0 0 1px var(--primary, #0d99ff); }
.w3crm .ec-file-rail__text { display: grid; min-width: 0; }
.w3crm .ec-file-rail__text b { font-size: .8125rem; line-height: 1.25; }
.w3crm .ec-file-rail__text small { font-size: .72rem; color: var(--crm-muted, #7e7e7e); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.w3crm .ec-file-rail__note { margin: .35rem .2rem 0; font-size: .72rem; color: var(--crm-muted, #7e7e7e); }
.w3crm .ec-file-panels { display: grid; gap: 1rem; min-width: 0; }
.w3crm .ec-file-panels > .card { margin-bottom: 0; }
.w3crm .ec-file-doclist { display: grid; gap: .5rem; }
.w3crm .ec-file-docrow { display: flex; align-items: center; gap: .75rem; padding: .55rem .8rem; border: 1px solid var(--crm-border, #e6e6e6); border-radius: .375rem; }
.w3crm .ec-file-docrow > b { font-size: .8125rem; }
.w3crm .ec-file-gatefoot { border: 1px solid var(--rgba-primary-2, rgba(13, 153, 255, .2)); }
@media (max-width: 991.98px) {
    .w3crm .ec-file-work { grid-template-columns: minmax(0, 1fr); }
}

/* Summary dossier (locked prototype): three equal cards. */
.w3crm .ec-dossier-grid--summary { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 1199.98px) {
    .w3crm .ec-dossier-grid--summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 767.98px) {
    .w3crm .ec-dossier-grid--summary { grid-template-columns: minmax(0, 1fr); }
}

/* Compact intake grid (intake-wizard-fields): Bootstrap 5 .row/.col-* with the shared
   .ec-field label styling. Tighter gutters and 40px controls keep the key fields above
   the fold; radios and checkboxes keep their natural size via .ec-inline-check. */
.w3crm .ec-intake-grid { --bs-gutter-x: .875rem; --bs-gutter-y: .75rem; }
.w3crm .ec-intake-grid .ec-field { gap: .3rem; }
.w3crm .ec-intake-grid .ec-field input:not([type="radio"]):not([type="checkbox"]),
.w3crm .ec-intake-grid .ec-field select { min-height: 2.5rem; padding: .45rem .7rem; }
.w3crm .ec-intake-subhead { display: block; margin-top: .35rem; color: var(--crm-muted, #888); font-size: .7rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.w3crm .ec-inline-pair { display: flex; gap: .5rem; }
.w3crm .ec-inline-pair input { min-width: 0; }
.w3crm .ec-address-search { position: relative; display: block; }
.w3crm .ec-address-search > .bi { position: absolute; left: .7rem; top: 50%; transform: translateY(-50%); color: #9aa0ac; pointer-events: none; }
.w3crm .ec-intake-grid .ec-address-search input { padding-left: 2rem !important; }
.w3crm.edgecapital-public-intake .ec-wizard-panel .ec-stack-header { margin-bottom: .75rem; }
/* Google Places appends its suggestion list to <body> at z-index 1000, which is below the
   Bootstrap modal (1055); lift it so predictions show inside the office intake modal. */
.pac-container { z-index: 1070 !important; }

/* Public page header logo (/apply, /realtor-application, document upload, inspection pages).
   Without a size the image renders at its natural width and fills the screen. */
.w3crm .ec-public-intake-logo { display: block; width: 150px; max-width: 100%; height: auto; object-fit: contain; }

/* Restored from edgecapital-auth-shell.css, which the Cake UI release (f0f1f631) removed:
   realtor financing highlights, referral strip and the muted inline note. */
.w3crm .ec-inline-note { display: block; color: var(--crm-muted, #6c757d); font-size: .8125rem; line-height: 1.6; }
/* Centered reading column shared by /apply, /realtor-application, document upload and inspection pages. */
.w3crm .ec-public-intake-wrap { width: min(1280px, calc(100% - 32px)); margin: 0 auto; padding: 32px 0 48px; }
.w3crm .ec-realtor-highlight-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 1rem 0; }
.w3crm .ec-realtor-highlight-grid article { padding: 14px 16px; border: 1px solid rgba(20, 32, 49, .12); border-radius: 8px; background: #fff; box-shadow: 0 12px 32px rgba(20, 32, 49, .06); }
.w3crm .ec-realtor-highlight-grid span,
.w3crm .ec-realtor-referral-strip .ec-muted { color: #687488; font-size: .78rem; }
.w3crm .ec-realtor-highlight-grid strong { display: block; margin-top: 4px; color: #172335; font-size: 1.2rem; line-height: 1.15; }
.w3crm .ec-realtor-intro-note { margin-bottom: 1rem; }
.w3crm .ec-realtor-referral-strip { display: grid; gap: 14px; padding: 18px; border: 1px solid rgba(20, 32, 49, .14); border-radius: 8px; background: #f8fafc; }
.w3crm .ec-realtor-referral-strip strong { display: block; color: #172335; font-size: 1rem; }
@media (max-width: 767.98px) {
    .w3crm .ec-realtor-highlight-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .w3crm .ec-realtor-referral-strip { padding: 14px; }
}

/* Application module components (resources/views/components/app/*).
   x-app.section: compact card. x-app.detail-group / x-app.detail: the read-only twin of an
   intake row — a titled <dl class="row"> of dt (label) / dd (value) pairs. */
.w3crm .ec-app-section > .card-header { padding: 1rem 1.25rem 0; }
.w3crm .ec-app-section > .card-body { padding: .9rem 1.25rem 1rem; }
.w3crm .ec-app-section > .card-footer { padding: .7rem 1.25rem; background: transparent; border-top: 1px solid var(--crm-border, #eee); }
.w3crm .ec-detail-grid { --bs-gutter-x: 2rem; --bs-gutter-y: 1.1rem; }
.w3crm .ec-detail-group__title { margin: 0 0 .45rem; padding-bottom: .35rem; border-bottom: 1px solid var(--crm-border, #eee); color: var(--crm-muted, #888); font-size: .7rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.w3crm .ec-detail-list { --bs-gutter-x: .75rem; row-gap: .3rem; font-size: .8125rem; line-height: 1.4; }
.w3crm .ec-detail-list dt { font-weight: 400; }
.w3crm .ec-detail-list dd { margin-bottom: 0; color: var(--title, #2c2c2c); overflow-wrap: anywhere; }
.w3crm .ec-detail-list address { font-style: normal; }
.w3crm .ec-field-error { display: block; color: #dc3545; font-size: .75rem; }
/* x-app.status-badge: W3CRM badge light plus the status dot. */
.w3crm .ec-status-badge { display: inline-flex; align-items: center; gap: .35rem; font-weight: 500; white-space: nowrap; }
.w3crm .ec-status-badge__dot { flex: 0 0 auto; width: .45rem; height: .45rem; border-radius: 50%; background: currentColor; }
.w3crm .ec-applications-workspace .active-projects table.shorting td:nth-child(6) .ec-status-badge { white-space: normal; text-align: left; line-height: 1.25; }
