:root{font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#252528;background:#f5f5f7;font-synthesis:none;font-size:14px;--muted:#717178;--line:#e9e9ed;--blue:#0071e3}
*{box-sizing:border-box}body{margin:0}button,input,select{font:inherit}button,a,input,select{-webkit-tap-highlight-color:transparent}button{cursor:pointer}button:disabled{cursor:not-allowed;opacity:.5}button, input,select{transition:background .15s,border-color .15s,box-shadow .15s}button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible{outline:3px solid #86bdf4;outline-offset:3px}button svg,svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.65;stroke-linecap:round;stroke-linejoin:round;flex-shrink:0}h1,h2,h3,p{margin:0}h2{font-size:17px;font-weight:600;letter-spacing:-.35px}button{border:0}a{color:inherit;text-decoration:none}[hidden]{display:none!important}.icon-defs{position:absolute;width:0;height:0;overflow:hidden}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.topbar{height:80px;background:rgba(255,255,255,.8);border-bottom:1px solid var(--line)}.topbar-inner{max-width:1200px;height:100%;padding:0 36px;margin:auto;display:flex;align-items:center;gap:24px}.brand{font-size:27px;font-weight:700;letter-spacing:-1.5px;display:flex;align-items:center;gap:9px}.brand-dot{color:var(--blue);margin-left:-10px}.brand-mark{display:grid;place-items:center;background:#252528;border-radius:10px;width:35px;height:35px;color:white;margin-right:2px}.brand-mark svg{width:24px;height:24px;stroke-width:1.4}.brand-description{font-size:12px;color:var(--muted);padding-left:24px;border-left:1px solid #dedee3}.local-badge{margin-left:auto;font-size:11px;color:#727279;display:flex;align-items:center;gap:7px}.local-badge>span{height:6px;width:6px;background:#36865a;border-radius:50%}
main{max-width:1200px;margin:0 auto;padding:51px 36px 0}.page-heading{display:flex;justify-content:space-between;align-items:center;margin-bottom:45px;gap:20px}.eyebrow{font-size:10px;font-weight:650;letter-spacing:1.65px;color:#83838b;margin-bottom:13px}h1{font-size:36px;letter-spacing:-1.5px;line-height:1.15;font-weight:650}.subtitle{font-size:14px;color:var(--muted);margin-top:12px}.button{min-height:42px;border-radius:9px;display:inline-flex;justify-content:center;align-items:center;gap:8px;padding:11px 17px;font-size:12px;font-weight:550;white-space:nowrap}.primary{background:var(--blue);color:white;box-shadow:0 2px 4px #0071e318}.primary:hover{background:#0063c7}.secondary{background:white;border:1px solid #dedee4;color:#43434b}.secondary:hover{background:#f3f3f6}.text-button{background:transparent;color:#5e5e67}.text-button:hover{background:#e9e9ee}.button svg{height:16px;width:16px}.section-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:18px}.period-caption{font-weight:400;color:#8a8a91}.month-navigation{display:flex;align-items:center;gap:3px;padding:4px;background:white;border:1px solid #e3e3e8;border-radius:9px}.icon-button{height:32px;width:32px;display:inline-flex;justify-content:center;align-items:center;background:transparent;color:#82828a;border-radius:6px;flex-shrink:0}.icon-button:hover{background:#f0f0f4;color:#252528}.icon-button svg{width:16px;height:16px}.rotate{transform:rotate(180deg)}.month-label input{border:0;background:transparent;color:#45454c;font-size:12px;max-width:171px;padding:4px 7px;min-height:30px}.summary-grid{display:grid;grid-template-columns:1.15fr 1fr 1fr 1fr;gap:14px;margin-bottom:24px}.summary-card{position:relative;overflow:hidden;min-height:155px;background:white;border:1px solid var(--line);border-radius:14px;padding:23px 23px 20px;display:flex;flex-direction:column;align-items:flex-start;gap:16px}.featured{background:#edf4ff;border-color:#dce9fc}.metric-label{font-size:12px;color:#62626b;display:flex;align-items:center;gap:7px}.featured .metric-label{color:#38649b}.summary-card strong{font-size:clamp(21px,2.2vw,29px);letter-spacing:-1px;font-weight:600;line-height:1.1;font-variant-numeric:tabular-nums;overflow-wrap:anywhere;max-width:100%}.featured strong{color:#1262bf}.summary-card small{font-size:14px;font-weight:400;color:#8a8a93;letter-spacing:0}.metric-note{font-size:10px;color:#7c7c85;margin-top:auto}.featured .metric-note{color:#6c87aa}.status-dot{width:6px;height:6px;display:inline-block;border-radius:50%}.green{background:#429568}.amber{background:#d6a34b}.card-spark{position:absolute;right:20px;top:19px;color:#7fa6d7;font-size:20px;font-weight:300}
.panel{background:white;border:1px solid var(--line);border-radius:15px;margin-bottom:24px;overflow:hidden}.panel-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:24px 27px}.panel-heading p{font-size:11px;color:#8a8a91;margin-top:7px}.chart-legend{display:flex;align-items:center;gap:7px;color:#7a7a83;font-size:10px}.chart-legend i{width:7px;height:7px;background:#7aafea;border-radius:2px}.chart-scroll{padding:0 27px;overflow-x:auto}.chart{height:205px;position:relative;margin-top:5px;margin-bottom:10px;min-width:480px;padding:0 0 25px 66px}.chart-grid{position:absolute;inset:0 0 25px 66px;pointer-events:none}.grid-line{position:absolute;width:100%;border-top:1px dashed #ececf0}.grid-line span{position:absolute;right:calc(100% + 12px);transform:translateY(-50%);font-size:10px;color:#92929a;white-space:nowrap;font-variant-numeric:tabular-nums}.chart-bars{height:100%;display:flex;align-items:flex-end;gap:clamp(4px,.8vw,10px);position:relative}.chart-day{flex:1;height:100%;position:relative;min-width:0;display:flex;align-items:flex-end}.bar{width:100%;max-width:30px;margin:0 auto;background:#9bbfeb;border-radius:4px 4px 0 0;min-height:2px;position:relative}.bar.has-value{cursor:default;background:#77a9e6}.bar.has-value:hover,.bar.has-value:focus-visible{background:#2674d0;outline-offset:2px}.bar-zero{background:#e9edf3}.day-label{position:absolute;bottom:-22px;font-size:9px;color:#92929a;text-align:center;left:50%;transform:translateX(-50%)}.bar-tip{display:none;position:absolute;bottom:calc(100% + 8px);left:50%;transform:translateX(-50%);z-index:3;background:#252528;color:white;padding:7px 9px;font-size:10px;border-radius:6px;white-space:nowrap;box-shadow:0 3px 10px #0002}.bar:hover .bar-tip,.bar:focus-visible .bar-tip{display:block}.chart-day:first-child .bar-tip{left:0;transform:none}.chart-day:last-child .bar-tip{left:auto;right:0;transform:none}.chart-caption{font-size:10px;color:#85858e;padding:4px 27px 20px}.list-title{display:flex;align-items:center;gap:10px}.count-badge{font-size:10px;background:#f1f1f4;border:1px solid #e9e9ee;color:#74747d;padding:3px 7px;border-radius:5px}.small{font-size:11px}.muted{color:#85858e}.table-scroll{overflow:auto}table{width:100%;border-collapse:collapse;text-align:left;white-space:nowrap}thead{background:#fafafb}th{font-size:10px;color:#85858e;font-weight:500;padding:13px 20px;border-top:1px solid #f0f0f3;border-bottom:1px solid #eeeef2}th:first-child,td:first-child{padding-left:27px}th:last-child,td:last-child{padding-right:27px}td{padding:17px 20px;border-bottom:1px solid #f0f0f3;font-size:12px;color:#64646e}tbody tr:last-child td{border-bottom:0}tbody tr:hover{background:#fdfdfe}.customer-name{display:block;font-weight:550;color:#35353c;max-width:260px;overflow:hidden;text-overflow:ellipsis}.number{text-align:right;font-variant-numeric:tabular-nums}.amount-cell{font-weight:550;color:#3c3c44}.payment-badge{display:inline-flex;align-items:center;gap:5px;font-size:10px;padding:5px 8px;border-radius:5px}.payment-badge.paid{background:#edf7f0;color:#33714d}.payment-badge.pending{background:#fbf4e7;color:#926922}.payment-badge::before{content:"";width:4px;height:4px;border-radius:50%;background:currentColor}.row-actions{display:flex;align-items:center;justify-content:flex-end;gap:5px}.actions-heading{text-align:right}.paid-action{font-size:10px;color:#317250;background:#f2f8f3;padding:6px 8px;border-radius:5px;min-height:30px}.paid-action:hover{background:#e3f0e6}.delete-action:hover{color:#bc3939;background:#fff1f1}.empty-state{padding:22px 20px 35px;text-align:center}.empty-icon{display:grid;place-items:center;background:#f5f5f8;border:1px solid #ececf1;border-radius:15px;width:48px;height:48px;margin:0 auto 14px;color:#898996}.empty-icon svg{width:25px;height:25px}.empty-state h3{font-size:15px;letter-spacing:-.3px;font-weight:550}.empty-state p{color:#85858f;font-size:12px;line-height:1.8;margin:8px 0 19px}.empty-state .button{min-height:36px;font-size:11px}.backup-panel{display:flex;justify-content:space-between;align-items:center;gap:20px;padding:9px 1px 26px}.backup-copy{display:flex;align-items:flex-start;gap:14px}.backup-copy>svg{margin-top:3px;color:#95959e;width:21px;height:21px}.backup-copy h2{font-size:12px;font-weight:550;letter-spacing:0;color:#676771}.backup-copy p{font-size:10px;color:#85858f;line-height:1.9;margin-top:5px}.backup-actions{display:flex;align-items:center;gap:9px}.backup-actions .button{font-size:11px;min-height:36px;padding:9px 12px}footer{border-top:1px solid #e5e5eb;padding:21px 0 27px;display:flex;justify-content:space-between;color:#93939b;font-size:10px}
dialog{border:1px solid #e5e5eb;border-radius:19px;padding:29px;width:min(480px,calc(100% - 32px));color:#252528;box-shadow:0 24px 100px #15152926;max-height:calc(100dvh - 36px);overflow:auto}dialog::backdrop{background:#20212b48;backdrop-filter:blur(4px)}.dialog-heading{display:flex;justify-content:space-between;align-items:flex-start;margin-bottom:27px;gap:12px}.dialog-heading .eyebrow{font-size:9px;letter-spacing:1.3px;margin-bottom:9px}.dialog-heading h2,.confirm-dialog h2{font-size:24px;letter-spacing:-.8px}.field{display:flex;flex-direction:column;gap:8px;font-size:12px;font-weight:500;margin-top:18px}.field input,.field select{width:100%;min-width:0;background:#fafafb;border:1px solid #dcdce3;border-radius:8px;height:43px;padding:10px 12px;color:#35353d}.field input::placeholder{color:#a2a2ab}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:15px}.currency-input{position:relative}.currency-input>span{position:absolute;left:12px;top:14px;color:#82828c;font-weight:400}.currency-input input{padding-left:37px}.field-help{font-size:10px;color:#85858e;line-height:1.5;margin-top:9px}.dialog-footer{display:flex;justify-content:flex-end;gap:9px;margin-top:28px;padding-top:20px;border-top:1px solid var(--line)}.confirm-dialog p{font-size:13px;line-height:1.8;color:#72727b;margin-top:15px;overflow-wrap:anywhere}.danger{background:#c13e3e;color:white}.danger:hover{background:#a92e2e}.form-error,.confirm-dialog .form-error{font-size:12px;color:#ad3434;margin-top:15px;line-height:1.5}.error-banner{padding:16px 20px;background:#fff1ed;border:1px solid #f2d6ce;border-radius:10px;color:#914532;font-size:13px;line-height:1.6;margin-bottom:24px}.toast{position:fixed;bottom:25px;left:50%;transform:translateX(-50%);background:#26262c;color:white;border-radius:10px;padding:14px 22px;box-shadow:0 6px 25px #0002;font-size:12px;max-width:calc(100% - 32px);width:max-content;z-index:5;line-height:1.5}
@media(min-width:1450px){main{padding-top:65px}.page-heading{margin-bottom:49px}.chart{height:230px}.summary-card{min-height:165px}}
@media(max-width:1000px){.summary-grid{grid-template-columns:repeat(2,1fr)}.summary-card strong{font-size:29px}.backup-panel{align-items:flex-start}.backup-actions{flex-direction:column;align-items:stretch}.desktop-break{display:none}.customer-name{max-width:200px}td,th{padding-left:14px;padding-right:14px}}
@media(max-width:640px){.topbar{height:65px}.topbar-inner{padding:0 20px}.brand-description{display:none}.local-badge{font-size:10px}.brand{font-size:24px}main{padding:32px 18px 0}.page-heading{align-items:flex-start;flex-direction:column;margin-bottom:29px;gap:22px}h1{font-size:30px;letter-spacing:-1.1px}.subtitle{font-size:12px}.page-heading>.button{width:100%}.eyebrow{font-size:9px}.section-heading h2{font-size:14px}.period-caption{display:none}.month-navigation{gap:0}.month-label input{max-width:155px;font-size:11px}.summary-grid{gap:10px;margin-bottom:18px}.summary-card{padding:19px 15px;min-height:139px;gap:16px;border-radius:12px}.summary-card strong{font-size:23px}.metric-label{font-size:10px}.metric-note{font-size:9px}.card-spark{display:none}.panel{margin-bottom:18px}.panel-heading{padding:20px 18px}.panel-heading h2{font-size:15px}.chart-legend{font-size:9px}.chart-scroll{padding:0 18px}.chart-caption{padding-left:18px;padding-right:18px;line-height:1.6}.chart{height:190px}.backup-panel{flex-direction:column;padding:8px 3px 24px;gap:15px}.backup-actions{flex-direction:row;padding-left:34px;gap:3px}.backup-actions .button{font-size:10px}.backup-copy p{font-size:10px}footer{font-size:9px}.list-title{gap:7px}.small{font-size:10px}dialog{padding:24px 20px}.form-grid{gap:10px}.field{font-size:11px}}
.profit-grid{grid-template-columns:1.15fr 1fr 1fr;margin-top:-10px;margin-bottom:10px}.profit-grid .summary-card{min-height:135px}.profit-card{background:#eef6f0;border-color:#dcebe0}.profit-card .metric-label,.profit-card strong{color:#33714d}.profit-card strong.loss{color:#ad3434}.profit-explanation{font-size:11px;line-height:1.8;color:#777781;margin:0 2px 24px}.purchase-summary{display:flex;gap:36px;padding:0 27px 22px;font-size:11px;color:#80808a}.purchase-summary>span{display:flex;align-items:center;gap:10px}.purchase-summary strong{font-size:13px;color:#45454d;font-weight:550;font-variant-numeric:tabular-nums}.purchase-empty{border-top:1px solid var(--line);padding-top:25px;padding-bottom:22px}.purchase-empty p{margin-bottom:0}.purchase-preview{display:flex;justify-content:space-between;gap:15px;margin-top:24px;padding:16px;background:#f5f5f8;border-radius:9px;font-size:12px;color:#73737d}.purchase-preview strong{color:#35353d;font-weight:600;font-variant-numeric:tabular-nums}
@media(max-width:1000px){.profit-grid{grid-template-columns:repeat(3,1fr)}.profit-grid .summary-card strong{font-size:24px}}
@media(max-width:640px){.profit-grid{grid-template-columns:1fr 1fr;gap:10px;margin-top:-6px}.profit-grid .profit-card{grid-column:1/-1;min-height:120px}.profit-grid .summary-card strong{font-size:23px}.profit-explanation{font-size:10px;margin-bottom:18px}.purchases-panel .panel-heading{align-items:flex-start;flex-direction:column;gap:16px}.purchases-panel .panel-heading .button{width:100%}.purchase-summary{padding:0 18px 20px;gap:18px;align-items:flex-start;flex-wrap:wrap}.purchase-summary>span{flex-direction:column;align-items:flex-start;gap:7px}}
.period-notice{display:flex;align-items:center;justify-content:space-between;gap:15px;margin-bottom:18px;padding:12px 16px;border:1px solid #dce9fc;border-radius:10px;background:#edf4ff;color:#38649b;font-size:12px;line-height:1.6}.period-notice .button{color:#1262bf;font-size:11px;padding:8px;min-height:34px}.period-notice .button:hover{background:#dfeaff}@media(max-width:640px){.period-notice{align-items:flex-start;flex-direction:column;gap:5px;font-size:11px}.period-notice .button{padding-left:0}}
@media(prefers-reduced-motion:reduce){*{transition:none!important;scroll-behavior:auto!important}}
