.loan-page{padding:0 0 28px;color:#101a30;font-size:14px}.loan-page h1{margin:0;font-size:24px;line-height:1.3;font-weight:750}.loan-page h2{font-size:14px}.loan-title-row{display:flex;align-items:flex-start;justify-content:space-between;gap:18px;margin-bottom:20px}.loan-title-row p{margin:3px 0 0;color:#6d7f9e}.loan-title-row small{display:block;margin-top:5px;color:#6d7f9e}.loan-actions{display:flex;flex-wrap:wrap;gap:8px;justify-content:flex-end}.loan-actions button{min-height:37px;padding:8px 16px;font-size:13px}.loan-actions .danger{color:#e02648;border-color:#ffbdc8}.loan-back{padding:0;margin:0 0 12px;border:0;background:transparent;color:#617493;cursor:pointer;font-size:13px}.loan-back:hover{color:#3865ef}.loan-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px;margin-bottom:20px}.loan-metric{display:flex;align-items:flex-start;justify-content:space-between;min-height:100px;padding:20px;border:1px solid #dce5f1;border-radius:16px;background:#fff;box-shadow:0 2px 4px #14233b0b}.loan-metric div{display:grid;gap:8px}.loan-metric small{font-size:11px;letter-spacing:.04em;text-transform:uppercase;color:#647899;font-weight:600}.loan-metric strong{font-size:24px;line-height:1.1}.loan-metric.blue strong,.loan-blue{color:#3865ef}.loan-metric.green strong,.loan-green{color:#199e69}.loan-metric.red strong,.loan-red{color:#e31d49}.loan-metric.purple strong{color:#8846f1}.loan-metric-icon{display:grid;place-items:center;width:44px;height:44px;border-radius:13px;font-size:24px;font-weight:750}.blue .loan-metric-icon{background:#eef4ff;color:#3865ef}.green .loan-metric-icon{background:#eafaf2;color:#199e69}.red .loan-metric-icon{background:#fff0f3;color:#e31d49}.purple .loan-metric-icon{background:#f4efff;color:#8846f1}.loan-filter-bar{display:flex;align-items:center;gap:12px;margin-bottom:20px;padding:15px;border:1px solid #dce5f1;border-radius:16px;background:#fff;box-shadow:0 2px 4px #14233b0b}.loan-filter-bar .loan-search{position:relative;flex:1;min-width:190px}.loan-search span{position:absolute;left:14px;top:9px;color:#6b7f9f;font-size:20px;line-height:1}.loan-search input{padding-left:37px}.loan-filter-bar input,.loan-filter-bar select{height:37px;min-width:0;border:1px solid #dce5f1;border-radius:10px;background:#fff;color:#1a2a44;font-size:13px}.loan-filter-bar select{flex:0 1 185px}.loan-filter-bar #loan-sort{margin-left:auto}.loan-table-card{border:1px solid #dce5f1;border-radius:16px;background:#fff;box-shadow:0 2px 4px #14233b0b;overflow:hidden}.loan-table-card>header,.loan-table-card>footer{display:flex;align-items:center;justify-content:space-between;padding:13px 16px;color:#7083a2;font-size:12px}.loan-table-card>header select{width:80px;margin:0 5px;height:33px}.loan-table-card>footer{border-top:1px solid #e0e7f2}.loan-table-card>footer>div{display:flex;align-items:center;gap:10px}.loan-table-card>footer button{width:32px;height:32px;border:1px solid #dce5f1;border-radius:9px;background:#fff;color:#5d7292;font-size:21px;cursor:pointer}.loan-table-card>footer button:disabled{opacity:.45;cursor:default}.loan-table-scroll{overflow-x:auto}.loan-table-card table{width:100%;border-collapse:collapse;font-size:13px}.loan-table-card th{padding:12px 16px;background:#f7f9fc;border-top:1px solid #e0e7f2;border-bottom:1px solid #e0e7f2;text-align:left;color:#647899;font-size:11px;font-weight:700;text-transform:uppercase;white-space:nowrap}.loan-table-card td{padding:13px 16px;border-bottom:1px solid #e0e7f2;white-space:nowrap}.loan-table-card tbody tr:last-child td{border-bottom:0}.loan-table-card tr[data-loan-open]{cursor:pointer}.loan-table-card tr[data-loan-open]:hover,.loan-table-card tr[data-loan-open]:focus-visible{background:#f4f7ff;outline:none}.loan-table-card td small{display:block;margin-top:2px;color:#8495ae}.loan-status{display:inline-flex;align-items:center;gap:5px;padding:4px 10px;border-radius:999px;background:#e6eeff;color:#3464ee;font-size:11px;font-weight:600;white-space:nowrap}.loan-status:before{content:'';width:6px;height:6px;border-radius:50%;background:currentColor}.loan-status.paid{background:#e5faed;color:#149b5b}.loan-status.overdue{background:#fff0f2;color:#d92b4f}.loan-status.cancelled{background:#eef1f5;color:#748197}.loan-detail .loan-title-row h1{display:flex;align-items:center;gap:10px}.loan-section-label{margin:2px 0 13px;text-transform:uppercase;letter-spacing:.04em;color:#6b7e9d}.loan-detail .loan-filter-bar{margin-bottom:16px}.loan-detail .loan-filter-bar .loan-search{max-width:520px}.loan-detail .loan-filter-bar select{margin-right:auto}.loan-empty{display:grid;place-items:center;gap:5px;min-height:118px;text-align:center;color:#15223a}.loan-empty span{color:#7083a2}.loan-modal{width:min(512px,100%);background:#f8faff}.loan-modal>header{border:0;padding:21px 24px 0}.loan-modal>form{padding:16px 24px 24px}.loan-modal .form-grid{gap:18px 12px}.loan-modal label{font-size:13px;font-weight:600;color:#26344e}.loan-modal input,.loan-modal select,.loan-modal textarea{margin-top:5px;min-height:36px;background:#f8faff;font-size:13px}.loan-modal textarea{min-height:77px}.loan-modal .form-actions{border:0;margin-top:16px;padding:0}.loan-modal .form-actions button{font-size:13px}.loan-modal .loan-borrower-hint{font-size:11px;color:#7083a2;font-weight:400}.loan-modal .loan-payroll-note{margin:0;color:#7083a2;font-size:11px;line-height:1.4}.loan-modal .loan-payroll-installment{display:none}.loan-modal.employee-loan .loan-payroll-installment{display:block}
.loan-metric-icon svg{width:23px;height:23px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}.loan-filter-bar .loan-search input{width:100%}
.loan-export-wrap{position:relative}.loan-export-menu{position:absolute;right:0;top:calc(100% + 6px);z-index:10;min-width:172px;padding:5px;border:1px solid #dce5f1;border-radius:10px;background:#fff;box-shadow:0 12px 30px #14233b22}.loan-export-menu button{display:block;width:100%;min-height:36px;padding:8px 10px;border:0;border-radius:6px;background:transparent;color:#23344f;text-align:left;cursor:pointer}.loan-export-menu button:hover,.loan-export-menu button:focus-visible{background:#eef3ff;color:#3865ef}
@media print{.loan-page .loan-actions,.loan-page .loan-filter-bar,.loan-page .loan-table-card>footer,.loan-page .loan-back{display:none!important}.loan-page .loan-table-scroll{overflow:visible}.loan-page .loan-table-card table{min-width:0}.loan-page .loan-metric{box-shadow:none}}
@media(max-width:900px){.loan-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.loan-filter-bar{flex-wrap:wrap}.loan-filter-bar .loan-search{flex-basis:100%}.loan-filter-bar select{flex:1 1 160px}.loan-filter-bar #loan-sort{margin-left:0}.loan-title-row{flex-wrap:wrap}}
@media(max-width:560px){.loan-metrics{gap:8px}.loan-metric{min-height:83px;padding:13px}.loan-metric strong{font-size:17px}.loan-metric small{font-size:9px}.loan-metric-icon{width:28px;height:28px;font-size:17px}.loan-actions{justify-content:flex-start}.loan-actions button{min-height:42px}.loan-modal>form{padding:15px}.loan-modal .form-grid{grid-template-columns:1fr}.loan-modal .form-grid label{grid-column:1/-1}.loan-table-card table{min-width:860px}}
.loan-detail .loan-title-row{margin-bottom:20px}.loan-detail .loan-title-row h1{margin-bottom:2px}.loan-detail .loan-actions button{display:inline-flex;align-items:center;justify-content:center;gap:9px}.loan-detail .loan-actions svg{width:16px;height:16px}.loan-detail .loan-metric{min-height:100px}.loan-detail .loan-metric-icon{position:relative}.loan-detail .loan-metric-icon:after{content:'';position:absolute;right:-3px;top:-3px;width:10px;height:10px;border:2px solid white;border-radius:50%;background:currentColor}.loan-detail .loan-section-label{margin:22px 0 13px}.loan-detail .loan-filter-bar{margin-bottom:16px}.loan-detail .loan-search{max-width:520px}.loan-detail .loan-search svg{position:absolute;left:14px;top:10px;width:17px;height:17px;color:#7083a2}.loan-detail .loan-search input{padding-left:40px}.loan-date-filter{position:relative;display:block;min-width:150px}.loan-date-filter svg{position:absolute;left:12px;top:10px;width:17px;height:17px;color:#7083a2;pointer-events:none}.loan-detail .loan-filter-bar .loan-date-filter select{width:100%;padding-left:38px}.loan-payments-card>header{min-height:56px}.loan-payments-card>header strong{color:#1b2942}.loan-payments-card th:nth-child(5),.loan-payments-card td:nth-child(5){text-align:center}.loan-payments-card .loan-payment-actions-heading{width:88px}.loan-payment-actions{text-align:right;white-space:nowrap}.loan-payment-actions button{width:30px;height:30px;padding:6px;border:0;border-radius:7px;background:transparent;color:#647899;cursor:pointer}.loan-payment-actions button:hover,.loan-payment-actions button:focus-visible{background:#edf3ff;color:#3865ef}.loan-payment-actions button[data-loan-payment-delete]{color:#ed3552}.loan-payment-actions button[data-loan-payment-delete]:hover,.loan-payment-actions button[data-loan-payment-delete]:focus-visible{background:#fff0f2}.loan-payment-actions svg{width:16px;height:16px}.loan-locked-payment{font-size:11px;color:#7083a2}.loan-payment-modal{width:min(448px,100%)}.loan-payment-modal .form-actions{justify-content:flex-end}.loan-payment-modal textarea{min-height:60px}.loan-payment-modal input:focus,.loan-payment-modal textarea:focus{border-color:#3865ef;box-shadow:0 0 0 2px #3865ef24}
@media(max-width:560px){.loan-payments-card>header{align-items:flex-start;gap:6px;flex-direction:column}.loan-payments-card table{min-width:640px}.loan-detail .loan-filter-bar .loan-search{max-width:none}.loan-date-filter{flex:1 1 150px}}
.loan-detail .loan-section-label{margin-bottom:10px}.loan-detail .loan-filter-bar{padding:14px}.loan-payments-card>header{height:56px;min-height:0;box-sizing:border-box}.loan-payments-card table{table-layout:auto}.loan-payments-card th{padding-top:10px;padding-bottom:10px}.loan-payments-card td{padding-top:10px;padding-bottom:10px;overflow:hidden;text-overflow:ellipsis}.loan-payments-card>footer{min-height:56px;box-sizing:border-box}
@media(max-width:560px){.loan-payments-card>header{height:auto;min-height:56px}}
.loan-payments-card th:nth-child(5),.loan-payments-card td:nth-child(5){text-align:left}.loan-payments-card td:last-child{overflow:visible;padding-left:0;padding-right:12px}
.loan-show-entries{display:inline-flex;align-items:center;gap:8px;white-space:nowrap;flex:none}.loan-show-entries>.modern-native-select{width:80px;flex:none}.loan-show-entries .modern-native-select-trigger{min-height:34px}.loan-date-filter{display:flex;align-items:center;flex:0 0 150px;min-width:150px}.loan-date-filter>.modern-native-select{width:100%}.loan-date-filter>svg{z-index:1}.loan-date-filter .modern-native-select-trigger{min-height:40px;padding-left:37px;font-size:13px}.loan-date-filter .modern-native-select-trigger svg{position:static;width:14px;height:14px;color:inherit;pointer-events:auto}
@media(max-width:560px){.loan-payments-card>header{gap:8px}.loan-date-filter{flex:1 1 150px}}
.loan-page:not(.loan-detail) .loan-metric.blue .loan-metric-icon{position:relative}
.loan-page:not(.loan-detail) .loan-metric.blue .loan-metric-icon:after{content:'';position:absolute;right:-3px;top:-3px;width:10px;height:10px;border:2px solid #fff;border-radius:50%;background:currentColor}

.loan-release-summary{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap;margin:12px 0;color:#64748b;font-size:12px}.loan-release-summary strong{color:var(--fc-ink,#172033)}

.loan-actions #loan-settings{display:inline-flex;align-items:center;justify-content:center;width:38px;padding:8px;flex:none}.loan-actions #loan-export,.loan-actions #new-loan{display:inline-flex;align-items:center;justify-content:center;gap:8px;white-space:nowrap}.loan-actions #loan-export svg,.loan-actions #new-loan svg{width:16px;height:16px;flex:none;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}.loan-actions #loan-export .loan-export-chevron{width:12px;height:12px}.loan-actions #loan-export{color:#172033;box-shadow:0 1px 2px #14233b08}.loan-actions #loan-export:hover{background:#f7f9fc}.loan-actions #loan-export[aria-expanded=true] .loan-export-chevron{transform:rotate(180deg)}
@media(max-width:560px){.loan-title-row>.loan-actions{gap:8px}.loan-actions #loan-settings{width:42px}.loan-actions #loan-export,.loan-actions #new-loan{padding:8px 12px;font-size:12px}}

.loan-borrower-field{display:grid;gap:6px;min-width:0}.loan-borrower-picker{position:relative;min-width:0}.loan-borrower-control{display:flex;align-items:center;border:1px solid var(--fc-line,#dce5f1);border-radius:10px;background:var(--fc-surface,#fff);transition:border-color .15s,box-shadow .15s}.loan-borrower-control:focus-within{border-color:#5274ff;box-shadow:0 0 0 3px #5274ff20}.loan-borrower-control>input{width:100%;min-width:0;flex:1;height:40px;border:0!important;outline:none!important;box-shadow:none!important;background:transparent!important;padding:10px 12px;border-radius:10px;color:inherit}.loan-borrower-control>.loan-borrower-toggle{display:grid;place-items:center;flex:none;width:38px;height:38px;border:0;border-radius:8px;background:transparent;color:#7083a2;cursor:pointer}.loan-borrower-toggle svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}.loan-borrower-toggle[aria-expanded=true] svg{transform:rotate(180deg)}.loan-borrower-toggle:disabled{cursor:default;opacity:.4}.loan-borrower-options{position:absolute;z-index:30;left:0;right:0;top:calc(100% + 6px);max-height:min(280px,40dvh);overflow-y:auto;overscroll-behavior:contain;padding:5px;border:1px solid var(--fc-line,#dce5f1);border-radius:12px;background:var(--fc-surface,#fff);box-shadow:0 12px 28px #14233b20;text-align:left}.loan-borrower-options[hidden]{display:none}.loan-borrower-options-heading{display:flex;align-items:center;justify-content:space-between;padding:7px 9px 9px;color:#7083a2;font-size:11px;font-weight:600}.loan-borrower-options-heading span{border-radius:10px;background:#edf3ff;padding:1px 7px;color:#3865ef}.loan-borrower-options>.loan-borrower-option{display:flex;width:100%;align-items:center;gap:10px;min-height:50px;padding:8px 9px;border:0;border-radius:8px;background:transparent;color:var(--fc-ink,#172033);text-align:left;cursor:pointer}.loan-borrower-option:hover,.loan-borrower-option.active{background:#edf3ff;color:#3865ef}.loan-borrower-option>span:nth-child(2){display:grid;min-width:0;gap:2px}.loan-borrower-option strong{font-size:13px;font-weight:600;overflow-wrap:anywhere}.loan-borrower-option small{color:#7083a2;font-size:10px;font-weight:400}.loan-borrower-avatar{display:grid;place-items:center;flex:none;width:30px;height:30px;border-radius:50%;background:#edf3ff;color:#3865ef;font-size:12px;font-weight:700}.loan-borrower-check{margin-left:auto;flex:none;color:#3865ef}.loan-borrower-option.loan-borrower-other{border-top:1px solid var(--fc-line,#dce5f1);border-radius:0 0 8px 8px;margin-top:4px;padding-top:10px}.loan-borrower-empty{padding:12px 9px;color:#7083a2;font-size:12px}
html[data-theme=dark] .loan-borrower-control,html[data-theme=dark] .loan-borrower-options{background:var(--fc-surface,#182438)}html[data-theme=dark] .loan-borrower-control:focus-within{border-color:#7891ff}html[data-theme=dark] .loan-borrower-option:hover,html[data-theme=dark] .loan-borrower-option.active{background:#263958;color:#a8bcff}html[data-theme=dark] .loan-borrower-avatar,html[data-theme=dark] .loan-borrower-options-heading span{background:#263958;color:#a8bcff}
