:root{font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#172e2a;background:#f6f8f5}*{box-sizing:border-box}body{margin:0}button,input,textarea{font:inherit}button{cursor:pointer;border:0}button:focus-visible,input:focus-visible,textarea:focus-visible{outline:3px solid #7dc4a2;outline-offset:2px}[hidden]{display:none!important}.auth{min-height:100vh;display:grid;place-items:center;padding:24px;background:linear-gradient(145deg,#e8f5ee,#f8faf5)}.auth-card{width:min(100%,420px);background:white;padding:32px;border-radius:24px;box-shadow:0 20px 60px #173a2b17}.auth-card h1{margin:16px 0 4px;font-size:28px}.auth-card p{color:#667772;line-height:1.5}.logo{display:grid;place-items:center;width:48px;height:48px;background:#156d50;color:white;border-radius:14px;font-size:29px;font-weight:700}.logo.small{width:38px;height:38px;font-size:23px;border-radius:11px}.tabs{display:flex;background:#f1f5f2;border-radius:12px;padding:4px;margin:24px 0}.tabs button{flex:1;background:transparent;padding:11px;border-radius:9px;color:#60716b;font-weight:650}.tabs button.active{background:white;color:#166b50;box-shadow:0 2px 8px #142e1e12}label{display:block;font-size:13px;font-weight:650;color:#41554d;margin:14px 0}input,textarea,select{display:block;width:100%;margin-top:7px;padding:12px 13px;border:1px solid #dce5df;border-radius:10px;background:white;color:#183129}textarea{resize:vertical;min-height:85px}button.primary,button.secondary{min-height:44px;padding:11px 17px;border-radius:10px;font-weight:700}.primary{background:#157451;color:white}.primary:hover{background:#0f6243}.secondary{background:#e9f4ed;color:#176a4d}.secondary:hover{background:#dceee2}.auth-card .primary,.modal-head~div+.error+.primary{width:100%}.error{color:#bd3b35;min-height:18px;font-size:13px}header{height:72px;background:white;border-bottom:1px solid #e6ebe6;display:flex;align-items:center;justify-content:space-between;padding:0 max(24px,calc((100vw - 1180px)/2))}.brand{display:flex;gap:11px;align-items:center}.brand strong,.brand small{display:block}.brand strong{font-size:16px}.brand small{font-size:12px;color:#7b8d83;margin-top:2px}.text-btn,.link{background:transparent;color:#267154;font-weight:650}.text-btn{padding:10px}main{max-width:1180px;margin:auto;padding:34px 24px 70px}.heading{display:flex;justify-content:space-between;align-items:center;gap:20px}.eyebrow{font-size:11px;letter-spacing:.15em;color:#4a9674;font-weight:800}.heading h1{font-size:30px;margin:5px 0}.heading p{color:#78877e;margin:6px 0}.actions{display:flex;gap:10px}.stats{display:grid;grid-template-columns:repeat(3,1fr);gap:16px;margin:30px 0}.stats article,.panel{background:white;border:1px solid #e7eee8;border-radius:17px;box-shadow:0 5px 20px #102b1708}.stats article{padding:22px;min-height:145px;display:flex;flex-direction:column}.stats span{font-size:13px;color:#63776a;font-weight:650}.stats strong{font-size:30px;margin:14px 0 6px;letter-spacing:-.04em}.stats small{color:#95a49a}.nav{display:flex;gap:25px;border-bottom:1px solid #e2e9e3;margin-bottom:22px;overflow:auto}.nav button{padding:13px 3px;background:none;color:#718477;white-space:nowrap;font-weight:650;border-bottom:3px solid transparent}.nav button.active{color:#176c4d;border-color:#176c4d}.two-col{display:grid;grid-template-columns:1fr 1fr;gap:20px}.panel{padding:22px;min-height:210px}.panel-head{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-bottom:16px}.panel h2{font-size:18px;margin:0}.panel-head span{font-size:13px;color:#829187}.search{margin:0 0 12px;background:#f9fbf9}.row{display:flex;justify-content:space-between;align-items:center;gap:12px;border-top:1px solid #edf1ed;padding:14px 0;background:white;width:100%;text-align:left}.row.clickable:hover{background:#f8fcf9}.person{display:flex;gap:11px;align-items:center;min-width:0}.avatar{width:37px;height:37px;flex:none;display:grid;place-items:center;border-radius:11px;background:#e7f3ea;color:#227553;font-weight:700}.row strong,.row small{display:block}.row strong{font-size:14px}.row small{color:#8b9a90;font-size:12px;margin-top:4px}.amount{text-align:right;white-space:nowrap;color:#173e30;font-weight:750}.amount.negative{color:#b8793f}.tag{display:inline-block;background:#e7f5eb;color:#267554;border-radius:7px;padding:4px 7px;font-size:11px;font-weight:750}.tag.debt{background:#fff0e6;color:#b96b30}.empty{padding:30px 10px;text-align:center;color:#91a096}.report-form{display:flex;align-items:end;flex-wrap:wrap;gap:10px;margin-bottom:22px}.report-form label{margin:0;min-width:150px}.report-form input{margin-top:5px}.report-summary{display:flex;gap:10px;flex-wrap:wrap;margin-bottom:14px}.report-summary span{padding:10px 12px;background:#f2f8f3;border-radius:9px;font-size:13px}.report-summary strong{display:block;font-size:17px;margin-top:5px}dialog{border:0;border-radius:20px;padding:24px;width:min(95vw,480px);max-height:90vh;overflow:auto;box-shadow:0 30px 90px #152d2250}dialog::backdrop{background:#102b20a3}.modal-head{display:flex;justify-content:space-between;align-items:center}.modal-head h2{margin:0;font-size:21px}.modal-head button{background:none;font-size:28px;color:#6b8175}.detail-summary{padding:16px;background:#f0f8f2;border-radius:12px;margin:16px 0}.detail-summary strong{font-size:23px}.detail-actions{display:flex;gap:8px;margin:14px 0}#toast{position:fixed;bottom:20px;left:50%;transform:translateX(-50%);background:#173e30;color:white;border-radius:10px;padding:11px 16px;opacity:0;pointer-events:none;transition:opacity .2s}#toast.show{opacity:1}@media(max-width:750px){header{padding:0 16px}main{padding:25px 16px 80px}.heading{align-items:flex-start;flex-direction:column}.heading h1{font-size:26px}.actions{width:100%}.actions button{flex:1}.stats{grid-template-columns:1fr 1fr;gap:10px;margin:22px 0}.stats article{padding:16px;min-height:125px}.stats article:first-child{grid-column:1/-1;min-height:110px}.stats strong{font-size:25px;margin:10px 0 3px}.two-col{grid-template-columns:1fr}.panel{padding:17px}.report-form label{flex:1;min-width:130px}.report-form button{flex:1}.auth-card{padding:25px}}

.report-groups{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin:20px 0}.report-group{border:1px solid #e7eee8;border-radius:12px;padding:15px;min-width:0}.report-group h3,.section-title{font-size:15px;margin:0 0 10px}.report-group h3 small{color:#84968a;margin-left:5px}.report-group .row{padding:10px 0}.report-group .row strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.section-title{margin:24px 0 10px}@media(max-width:750px){.report-groups{grid-template-columns:1fr}}

.export-all{border-top:1px solid #e7eee8;margin-top:28px;padding-top:18px}.export-all h3{font-size:16px;margin:0 0 5px}.export-all p{font-size:13px;color:#748679;margin:0 0 14px}.export-actions{display:flex;flex-wrap:wrap;gap:9px}

.detail-actions{flex-wrap:wrap}.detail-actions button{flex:1;white-space:nowrap}

.help-text{font-size:12px;line-height:1.45;color:#718579;margin:3px 0 12px}

.auth-hint{font-size:13px;color:#477760!important;background:#f1f8f2;border-radius:9px;padding:10px 12px;margin:0 0 13px!important}

.actions{flex-wrap:wrap}.actions button{white-space:nowrap}.payment-summary{margin:13px 0}.payment-summary small{display:block;color:#688072;margin-top:4px}.payment-summary.no-debt{background:#fff4eb;color:#a45b2a}
.global-setting{display:flex;align-items:end;gap:12px;flex-wrap:wrap;max-width:520px;margin-top:20px}.global-setting label{flex:1;min-width:220px;margin:0}.global-setting button{min-width:110px}@media(max-width:750px){.global-setting button{width:100%}}
.tag.interest{background:#fff1d6;color:#92610a}

.due-actions{display:flex;gap:10px;flex-wrap:wrap;margin:0 0 18px}.due-actions button{display:flex;align-items:center;justify-content:space-between;gap:16px}.due-actions strong{background:#fff;border-radius:999px;min-width:24px;padding:2px 7px;text-align:center}@media(max-width:750px){.due-actions button{flex:1;min-width:180px}}
.payment-search-results{max-height:190px;overflow:auto;border:1px solid #dce5df;border-radius:10px;margin-top:-8px;background:white;box-shadow:0 8px 20px #102b1717}.payment-search-results button{display:flex;justify-content:space-between;align-items:center;gap:12px;width:100%;padding:12px 14px;text-align:left;background:white;color:#183129;border-bottom:1px solid #edf1ed}.payment-search-results button:hover,.payment-search-results button:focus{background:#f0f8f2}.payment-search-results small{color:#718579}.payment-search-results .empty{padding:14px}.date-field{display:flex;align-items:center;gap:8px}.date-field input{min-width:0;flex:1}.date-ok{flex:none;min-height:44px;margin-top:7px;padding:10px 14px;border-radius:10px;font-weight:700}
.global-setting{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-items:start;max-width:540px}.global-setting label{display:flex;flex-direction:column;justify-content:flex-end;min-width:0;height:100%}.global-setting select,.global-setting input{height:46px}.global-setting button{grid-column:1/-1;justify-self:start}@media(max-width:750px){.global-setting{grid-template-columns:1fr;max-width:100%}.global-setting button{width:100%}}
