:root{font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#172d29;background:#f6f7f3;font-size:14px;--green:#123f36;--muted:#73817c;--line:#e1e7df;--red:#b33a3a}*{box-sizing:border-box}body{margin:0}button,input,select,textarea{font:inherit}button,a,input,select,textarea{touch-action:manipulation}button{cursor:pointer;border:1px solid var(--line);border-radius:9px;background:#fff;color:var(--green);padding:10px 14px;font-weight:600;min-height:40px}button:hover{background:#f1f5ec}button:disabled{opacity:.5;cursor:wait}button.primary{background:var(--green);border-color:var(--green);color:#fff}button.primary:hover{background:#21584b}button.danger{color:var(--red)}button.icon{padding:6px 9px;min-height:32px}a{color:#2b6a59}input,select,textarea{padding:10px 11px;border:1px solid #cdd7ce;border-radius:8px;min-height:42px;background:#fff;color:#172d29;width:100%;font-size:16px}input[type=checkbox]{width:20px;min-height:20px;height:20px;accent-color:var(--green)}input[type=color]{padding:3px;min-height:44px}textarea{min-height:90px;resize:vertical}h1,h2,h3,p{margin-top:0}h1{font-size:30px;letter-spacing:-1px;margin-bottom:8px;font-weight:650}h2{font-size:18px;font-weight:650;letter-spacing:-.3px}h3{font-size:15px}small,.muted{color:var(--muted)}small{font-size:12px}label{display:block}.shell{display:grid;grid-template-columns:220px minmax(0,1fr);min-height:100vh}.sidebar{background:#fff;border-right:1px solid var(--line);padding:26px 16px;position:sticky;top:0;height:100dvh;display:flex;flex-direction:column;gap:26px}.brand{display:flex;align-items:center;gap:10px;font-size:17px;font-weight:700;padding:0 10px}.brand img{width:35px;height:35px}.brand span{overflow:hidden;text-overflow:ellipsis;max-width:145px}.nav{display:grid;gap:4px}.nav button{border:0;background:none;text-align:left;color:#6c7a73;font-weight:500;display:flex;align-items:center;gap:10px;padding:12px}.nav button.active{background:#edf4e8;color:var(--green);font-weight:700}.nav .mark{width:22px;text-align:center;font-size:15px}.sidebar-footer{margin-top:auto;padding:8px;display:grid;gap:10px}.main{padding:28px 36px 50px;max-width:1550px;width:100%;margin:0 auto}.topbar{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:28px;padding-bottom:19px;border-bottom:1px solid var(--line)}.topbar .eyebrow,.eyebrow{text-transform:uppercase;letter-spacing:1.5px;font-size:10px;font-weight:700;color:#7d8b80;margin-bottom:7px}.topbar select{max-width:290px;font-size:14px}.topbar input[type=month]{width:160px}.page-head{display:flex;justify-content:space-between;align-items:flex-start;gap:20px;margin-bottom:24px}.actions{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.kpis{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-bottom:22px}.card,.panel{background:#fff;border:1px solid var(--line);border-radius:14px;padding:20px;min-width:0}.card h3{font-size:12px;color:#6a7971;margin-bottom:15px;font-weight:500}.card .value{font-size:25px;letter-spacing:-.8px;font-variant-numeric:tabular-nums;font-weight:650;overflow-wrap:anywhere}.card small{display:block;margin-top:10px;font-size:11px}.card.featured{background:var(--green);border-color:var(--green);color:#f2f6ee}.card.featured h3,.card.featured small{color:#c3d8c6}.card.featured .value{font-size:32px}.negative{color:var(--red)!important}.featured .negative{color:#ffcccc!important}.grid2{display:grid;grid-template-columns:1.6fr 1fr;gap:20px;margin-bottom:20px}.panel-title{display:flex;justify-content:space-between;gap:12px;align-items:center;margin-bottom:15px}.panel-title h2{margin:0}.progress{height:6px;border-radius:6px;background:#edf1e8;overflow:hidden;margin-top:10px}.progress i{display:block;height:100%;border-radius:6px;background:#779d76}.progress i.over{background:#cf7164}.category{padding:12px 0;border-bottom:1px solid #edf0ea}.category:last-child{border:0}.category .line{display:flex;justify-content:space-between;gap:15px;font-size:13px}.badge{display:inline-flex;padding:4px 8px;border-radius:6px;font-size:11px;font-weight:600;white-space:nowrap}.table-wrap{overflow-x:auto;width:100%}table{width:100%;border-collapse:collapse;text-align:left;font-size:13px;white-space:nowrap}th{font-size:10px;text-transform:uppercase;letter-spacing:.7px;color:#7b8880;font-weight:600;padding:12px 10px;border-bottom:1px solid var(--line);text-align:left}td{padding:13px 10px;border-bottom:1px solid #edf0ea;vertical-align:middle}td.num,th.num{text-align:right;font-variant-numeric:tabular-nums}tr:last-child td{border-bottom:0}td.title{font-weight:550;max-width:280px;white-space:normal}td .sub{display:block;font-size:11px;color:#839087;margin-top:3px}.mini{display:flex;justify-content:space-between;padding:10px 0;gap:18px;border-bottom:1px solid #edf0ea}.mini:last-child{border:0}.mini strong{font-variant-numeric:tabular-nums}.group-title{margin-top:26px;margin-bottom:12px;display:flex;justify-content:space-between;align-items:center}.group-title h2{margin:0}.empty{padding:40px 20px;text-align:center;color:#758277;line-height:1.8}.notice{background:#f0f4e9;border:1px solid #dbe6cd;border-radius:10px;padding:14px 16px;line-height:1.6;margin:16px 0;color:#41563f}.notice.warn{background:#fff7e5;border-color:#eddfba;color:#755d23}.notice.error{background:#fff0ed;border-color:#f0d5d0;color:#a13e35}.cards-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;margin-bottom:24px}.goal-card{background:#fff;border:1px solid var(--line);border-radius:14px;padding:20px}.goal-card .amount{font-size:25px;margin:18px 0 5px;letter-spacing:-1px}.goal-card .meta{display:flex;justify-content:space-between;margin:12px 0;color:#78867d;font-size:12px}.section-tabs{display:flex;gap:6px;flex-wrap:wrap;margin-bottom:20px}.section-tabs button.active{background:var(--green);color:white}.formgrid{display:grid;grid-template-columns:1fr 1fr;gap:16px}.field span{display:block;font-size:12px;font-weight:600;margin-bottom:7px}.field.full{grid-column:1/-1}.field small{display:block;line-height:1.5;margin-top:5px}.checkfield{display:flex;gap:10px;align-items:center;min-height:42px;padding-top:24px}.checkfield span{margin:0}.dialog-head{display:flex;justify-content:space-between;align-items:flex-start;gap:10px;margin-bottom:24px}.dialog-head h2{font-size:23px;margin:0}.dialog-footer{display:flex;justify-content:flex-end;gap:8px;margin-top:24px;padding-top:18px;border-top:1px solid var(--line)}dialog{border:0;border-radius:16px;padding:26px;width:min(740px,calc(100% - 28px));max-height:90dvh;color:inherit;box-shadow:0 30px 100px #10241e33}dialog::backdrop{background:#16302866;backdrop-filter:blur(3px)}.auth-wrap{min-height:100dvh;display:grid;place-items:center;padding:24px;background:radial-gradient(ellipse at 20% 20%,#dce8ce,transparent 50%),#f6f7f3}.auth{width:420px;max-width:100%;background:white;border:1px solid var(--line);border-radius:18px;padding:34px}.auth .brand{padding:0;margin-bottom:28px}.auth h1{font-size:27px}.auth label{margin-top:16px}.auth button.primary{width:100%;margin-top:22px}.auth p{line-height:1.65;color:#78877d}.error-text{color:var(--red);white-space:pre-wrap}.loading{padding:60px;color:#778578}.mobile-header,.bottomnav{display:none}.toolbar{display:flex;gap:12px;align-items:end;flex-wrap:wrap;margin-bottom:20px}.toolbar label{flex:1;min-width:145px;max-width:280px}.toolbar label span{font-size:11px;display:block;margin-bottom:6px;color:#748277}pre{white-space:pre-wrap;overflow-wrap:anywhere;font-family:ui-monospace,monospace;font-size:12px;background:#f1f4ee;padding:16px;border-radius:8px;max-height:450px;overflow:auto}.schema-details{margin-top:20px;border-top:1px solid var(--line);padding-top:15px}.inline-help{font-size:12px;line-height:1.7;color:#7a887d}.linkbutton{background:none;border:0;color:#2d6c55;padding:5px 0;text-decoration:underline}#toast{position:fixed;bottom:24px;right:24px;padding:14px 20px;border-radius:10px;background:#123f36;color:white;box-shadow:0 6px 30px #123f3630;display:none;z-index:20;max-width:min(500px,90vw)}.schedule-summary{display:grid;grid-template-columns:repeat(3,1fr);gap:14px;margin-bottom:20px}.divider{height:1px;background:var(--line);margin:22px 0}.archive-grid td{max-width:350px;white-space:normal;word-break:break-word}.search{max-width:300px}.toggle-side{font-size:20px;border:0;background:none}.user-tag{font-size:12px;color:#7b887e}.detail-list{list-style:none;padding:0;margin:0}.detail-list li{padding:11px 0;border-bottom:1px solid var(--line);line-height:1.6}.reportlist{max-height:300px;overflow:auto}.reportlist li{margin-bottom:8px;font-size:12px;line-height:1.6}.pill{font-size:10px;text-transform:uppercase;letter-spacing:1px;color:#74816f;background:#eef2e8;padding:5px 8px;border-radius:20px}.amount-input{font-variant-numeric:tabular-nums}
@media(min-width:1600px){.main{padding-top:35px}}@media(max-width:1150px){.shell{grid-template-columns:185px minmax(0,1fr)}.sidebar{padding:24px 10px}.main{padding:24px}.kpis{grid-template-columns:repeat(2,minmax(0,1fr))}.cards-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.grid2{grid-template-columns:1fr}.brand{font-size:15px}}@media(max-width:720px){.shell{display:block}.sidebar{display:none;position:fixed;width:250px;z-index:12;box-shadow:0 0 0 100vmax #16302866}.sidebar.open{display:flex}.main{padding:15px 16px 100px}.mobile-header{display:flex;justify-content:space-between;align-items:center;padding-bottom:16px}.mobile-header .brand{padding:0}.topbar{margin-bottom:22px;padding-bottom:16px;align-items:flex-start}.topbar .eyebrow{display:none}.topbar select{max-width:220px;font-size:13px}.topbar .user-tag{font-size:11px}.page-head{margin-bottom:18px;gap:10px}.page-head .actions{justify-content:flex-end}.page-head .actions button{font-size:11px;padding:9px}.page-head p{font-size:12px;line-height:1.6}h1{font-size:25px}.kpis{gap:10px}.card{padding:15px;border-radius:12px}.card .value{font-size:21px}.card.featured .value{font-size:26px}.card h3{font-size:11px;margin-bottom:12px}.card small{font-size:10px;line-height:1.5}.panel{padding:15px;border-radius:12px}.cards-grid{grid-template-columns:1fr}.formgrid{grid-template-columns:1fr}.field.full{grid-column:auto}.checkfield{padding-top:0}.bottomnav{display:grid;grid-template-columns:repeat(5,1fr);position:fixed;bottom:0;left:0;right:0;background:#fff;border-top:1px solid var(--line);padding:8px 4px max(8px,env(safe-area-inset-bottom));z-index:10}.bottomnav button{border:0;padding:7px 2px;display:flex;flex-direction:column;gap:3px;font-size:10px;font-weight:500;color:#7a887d;align-items:center}.bottomnav button.active{color:#174c3c;font-weight:750}.bottomnav .mark{font-size:17px}.schedule-summary{grid-template-columns:1fr}.toolbar label{max-width:none}.toolbar{gap:10px}#toast{bottom:90px;left:16px;right:16px;max-width:none}.auth{padding:26px}.dialog-head h2{font-size:21px}dialog{padding:20px}.group-title small{max-width:150px;text-align:right}.table-wrap{margin:0 -5px;width:calc(100% + 10px)}th,td{padding:10px 8px}td.title{min-width:140px}.notice{font-size:12px}.topbar input[type=month]{width:145px}.legend{font-size:11px}}
.positive{color:#287248!important;font-variant-numeric:tabular-nums}.featured .positive{color:#d1f2cf!important}.goal-complete{background:#f0f7ed;border-color:#bbd8b3}.goal-complete .progress i{background:#428350}.goal-inactive{background:#f0f1ef;border-color:#d8ddd7;color:#657167}.goal-inactive .amount,.goal-inactive h2{color:#788179}.goal-inactive .progress i{background:#a8b1a7}.title-button{background:none;border:0;padding:0;text-align:left;font:inherit;color:inherit;cursor:pointer;white-space:normal}.title-button:hover{text-decoration:underline}.title-button:focus-visible{outline:2px solid #287248;outline-offset:5px}.loan-card{transition:border-color .15s}.loan-card:hover{border-color:#9cb49b}.month-navigation{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin-bottom:20px}.budget-section{margin-bottom:16px}.section-totals{font-size:12px;color:#6a7971;text-align:right;line-height:1.7}.simulation-assumptions{margin:18px 0;padding:14px;background:#f5f7f2;border-radius:8px}.simulation-assumptions summary{cursor:pointer;font-weight:600}.archive-toggle{display:flex;gap:9px;align-items:center;margin:12px 0 18px;font-size:13px}.grouping{margin-top:20px}button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible{outline:2px solid #527d55;outline-offset:2px}@media(max-width:720px){.budget-section .panel-title{align-items:flex-start;flex-direction:column}.section-totals{text-align:left;font-size:11px}.month-navigation button{font-size:12px;padding:9px}.month-navigation .pill{width:100%;text-align:center;order:-1}.section-tabs{gap:5px}.section-tabs button{font-size:12px}}
.inline-plan{width:105px;min-width:90px;padding:7px 8px;text-align:right;font-variant-numeric:tabular-nums;border:1px solid #dce4d8;background:#fcfdfb}.inline-plan:disabled{background:#eff1ed}.inline-plan:focus{border-color:#527d55;background:#fff}
.inline-type{width:130px;min-width:115px;padding:7px 8px;font-size:12px;border:1px solid #d8dfd3}.row-skipped{background:#f1f2ef;color:#7d857c}.row-skipped td.title{color:#7d857c}.row-skipped input,.row-skipped select{background:#e8ebe5!important;color:#7d857c;border-color:#dce0d8}.row-skipped button{color:#7d857c}.goal-switch{display:flex;align-items:center;gap:9px;margin-top:14px;font-size:12px}.goal-switch input{appearance:none;-webkit-appearance:none;width:37px;height:22px;min-width:37px;border-radius:15px;background:#c7cec3;border:0;position:relative;cursor:pointer;transition:background .15s;margin:0}.goal-switch input::before{content:'';position:absolute;top:3px;left:3px;width:16px;height:16px;border-radius:50%;background:#fff;box-shadow:0 1px 3px #0002;transition:transform .15s}.goal-switch input:checked{background:#397954}.goal-switch input:checked::before{transform:translateX(15px)}.goal-switch input:disabled{opacity:.6;cursor:wait}.expense-history{margin:24px 0;scroll-margin-top:20px;border-color:#8aab88}.expense-summary{display:flex;gap:22px;flex-wrap:wrap;margin:14px 0;padding:12px 0;border-top:1px solid #e5eadf;border-bottom:1px solid #e5eadf;font-size:13px}.expense-summary strong{margin-left:6px}@media(max-width:720px){.expense-summary{gap:12px}.expense-history .panel-title{align-items:flex-start;flex-direction:column}.inline-type{width:115px}}
.inline-execution{width:145px;min-width:110px;padding:7px 8px;text-align:right;font-variant-numeric:tabular-nums;background:#fcfdfb;border:1px solid #dce4d8}.execution-result{display:block;color:#778575;font-size:10px;margin-top:4px}.inline-execution:focus{border-color:#527d55;background:white}.row-skipped .execution-result{color:#8b9287}.budget-section .panel-title>.actions{justify-content:flex-end}@media(max-width:720px){.budget-section .panel-title>.actions{justify-content:flex-start}.inline-execution{width:120px}}

.row-complete td{background:#edf7ee;color:#285f3b}.row-complete .inline-plan,.row-complete .inline-execution{background:#f6fcf5;border-color:#c6dfc6}.row-complete .title:before{content:"✓ ";color:#39834c}.row-complete .negative{color:var(--red)!important}

.row-overbudget td{background:#fff0db;color:#835116}.row-overbudget .inline-plan,.row-overbudget .inline-execution{background:#fff8ed;border-color:#e6bb7e}.row-overbudget .title:before{content:"! ";color:#bf7317;font-weight:700}

.action-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(230px,1fr));gap:14px;margin-bottom:22px}.action-card{padding:18px;border:1px solid #d9e5d3;border-radius:13px;background:#f0f5eb}.action-card.attention{background:#fff3e2;border-color:#edcfaa}.action-card h3{margin-bottom:8px}.action-card p{font-size:13px;line-height:1.6;min-height:38px}.planner-section{margin-top:20px;scroll-margin-top:20px}.chart-budget-row{padding:11px 0}.chart-budget-row .line{display:flex;justify-content:space-between;gap:12px;font-size:12px;margin-bottom:7px}.bar-track{height:11px;background:#f3f5f0;border-radius:5px;margin-top:4px;overflow:hidden}.bar-track i{display:block;height:100%;border-radius:5px}.bar-plan{background:#d5ded0}.bar-actual{background:#4f8163}.bar-warning{background:#d89542}.chart-key{display:flex;flex-wrap:wrap;gap:14px;font-size:11px;color:#64746b}.chart-key span{display:flex;align-items:center;gap:6px}.chart-key i{width:12px;height:8px;border-radius:3px;display:inline-block}.donut-layout{display:flex;align-items:center;gap:20px;padding:20px 0}.spending-donut{width:180px;max-width:40%;flex-shrink:0}.donut-legend{display:grid;gap:15px;flex:1;min-width:0}.donut-legend>div{display:grid;grid-template-columns:12px minmax(55px,1fr) auto;gap:7px;align-items:center;font-size:12px}.donut-legend i{width:12px;height:12px;border-radius:3px}.donut-legend small{grid-column:2/4}@media(max-width:720px){.donut-layout{gap:12px}.spending-donut{width:120px}.action-grid{grid-template-columns:1fr}.chart-budget-row .line{flex-wrap:wrap}}

.planning-panel{margin:20px 0}.planning-category{display:flex;gap:14px;justify-content:space-between;font-size:11px;padding:7px 0;white-space:normal}.planning-panel details{margin-top:6px;font-weight:400}.planning-panel summary{font-size:11px;cursor:pointer}

.bar-limit{background:#93adbf}

.inline-due{width:145px;min-width:130px;padding:7px 8px;background:#fcfdfb;border:1px solid #dce4d8;font-size:12px}.inline-due:focus{border-color:#527d55;background:#fff}.inline-due:disabled{background:#eff1ed}.row-complete .inline-due{background:#f6fcf5;border-color:#c6dfc6}.row-overbudget .inline-due{background:#fff8ed;border-color:#e6bb7e}

.bar-approved{background:#75a97a!important}.planning-panel .title .badge{display:block;width:fit-content;margin-top:6px}.planning-panel .title button{margin-top:6px}

/* Loan tools keep their actions inside the viewport; tables are desktop detail. */
.main,.topbar>div,.page-head>div{min-width:0}.panel-title{flex-wrap:wrap}.loan-schedule-panel .panel-title{align-items:flex-start}.loan-schedule-panel .panel-title>.actions{flex:1;justify-content:flex-end}.loan-schedule-panel details{margin:12px 0}.form-section{grid-column:1/-1;padding-top:16px;margin:0;border-top:1px solid var(--line)}.field[hidden]{display:none!important}.loan-preview{margin-top:20px;padding-top:18px;border-top:1px solid var(--line)}.loan-mobile-schedule{display:none}.loan-payment-card{border:1px solid var(--line);border-radius:12px;padding:16px;margin-top:12px;background:#fff}.loan-payment-card.is-paid{background:#edf7ee}.loan-payment-heading{display:flex;justify-content:space-between;align-items:center;gap:8px;flex-wrap:wrap}.loan-payment-amount{font-size:25px;font-weight:700;margin:12px 0;font-variant-numeric:tabular-nums}.loan-payment-breakdown{display:grid;gap:9px;font-size:13px}.loan-payment-breakdown>span{display:flex;justify-content:space-between;gap:12px}.loan-payment-card details{font-size:12px;line-height:1.6}.loan-payment-card .actions{margin-top:14px}.loan-payment-card .actions button{flex:1}.loan-desktop-schedule{max-width:100%;min-width:0}
@media(max-width:720px){.loan-mobile-schedule{display:block}.loan-desktop-schedule{display:none}.loan-schedule-panel .panel-title{display:block}.loan-schedule-panel .panel-title>.actions{justify-content:flex-start;margin-top:12px}.loan-schedule-panel .panel-title button{flex:1 1 145px}.loan-schedule-panel .kpis{grid-template-columns:repeat(2,minmax(0,1fr))}.topbar .actions{min-width:0;max-width:60%}.topbar select{width:100%;min-width:0}.page-head{flex-wrap:wrap}.page-head .actions{justify-content:flex-start}.badge{white-space:normal}.loan-preview .kpis{grid-template-columns:1fr 1fr}dialog .form-section{padding-top:12px}.dialog-footer{flex-wrap:wrap}.loan-target .toolbar label{max-width:100%}}

/* v0.9.1: compact month actions, due dates only when present, dark appearance */
.month-actions{display:flex;flex-wrap:wrap;align-items:center;gap:9px;margin:18px 0 22px}.month-actions>button,.month-actions>.action-menu{flex:0 1 auto}.action-menu{position:relative;min-width:0}.action-menu>summary{list-style:none;cursor:pointer;border:1px solid var(--line);padding:10px 13px;border-radius:9px;background:var(--surface,#fff);color:var(--green);font-weight:650;min-height:40px;display:flex;gap:9px;align-items:center;justify-content:center}.action-menu>summary::-webkit-details-marker{display:none}.action-menu[open]>summary{outline:2px solid #7f9b83;outline-offset:1px}.action-menu-content{position:absolute;z-index:8;right:0;top:calc(100% + 5px);width:min(285px,calc(100vw - 42px));display:grid;gap:4px;padding:8px;border-radius:12px;border:1px solid var(--line);background:var(--surface,#fff);box-shadow:0 12px 32px #091e162e}.action-menu-content button{text-align:left;width:100%;min-height:42px;white-space:normal}.row-action-cell{min-width:105px}.row-menu>summary{padding:7px 9px;min-height:35px;font-size:12px}.row-menu .action-menu-content{position:static;margin-top:7px;box-shadow:none;width:min(230px,100%)}.row-due-label{display:block;font-size:11px;white-space:normal;margin-top:6px;color:var(--muted)}.theme-picker{display:grid;gap:6px;font-size:12px;color:var(--muted);margin:10px 0}.theme-picker select{width:100%;font-size:13px}.budget-section .table-wrap{overflow-x:auto}.budget-section td,.budget-section th{white-space:normal}.budget-section td:last-child{min-width:125px}
@media(max-width:720px){.month-actions{display:grid;grid-template-columns:1fr 1fr}.month-actions .action-menu{grid-column:1/-1}.month-actions .action-menu>summary{justify-content:space-between}.month-actions .action-menu-content{position:static;width:100%;box-shadow:none;margin-top:7px}.budget-section .table-wrap{overflow:visible;margin:0;width:100%}.budget-section table,.budget-section tbody,.budget-section tr,.budget-section td{display:block;width:100%;min-width:0}.budget-section thead{display:none}.budget-section tr{border:1px solid var(--line);border-radius:12px;padding:10px 12px;margin:12px 0;background:var(--surface,#fff)}.budget-section td{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:7px 1px;border:0;min-height:35px;text-align:right}.budget-section td:before{display:block;flex:0 0 92px;content:'';text-align:left;color:var(--muted);font-size:11px}.budget-section td:nth-child(1):before{content:'Pozycja'}.budget-section td:nth-child(2):before{content:'Typ'}.budget-section td:nth-child(3):before{content:'Plan'}.budget-section td:nth-child(4):before{content:'Wykonano'}.budget-section td:nth-child(5):before{content:'Pozostało'}.budget-section td:nth-child(6):before{content:'Zamknięte'}.budget-section td:nth-child(7):before{content:'Operacje'}.budget-section td.title{font-weight:650;align-items:flex-start}.budget-section td .sub{display:block}.budget-section td.row-action-cell{align-items:flex-start}.budget-section .row-menu{flex:1}.budget-section .row-menu>summary{justify-content:space-between}.budget-section .row-menu .action-menu-content{width:100%}.budget-section input.inline-execution,.budget-section input.inline-plan,.budget-section select.inline-type{max-width:185px;min-width:0}.row-due-label{max-width:90px}.budget-section .row-complete td,.budget-section .row-overbudget td{background:transparent}}
:root[data-theme="dark"]{color-scheme:dark;--green:#9ed9bb;--muted:#adbbb3;--line:#3b5147;--red:#ff908b;--surface:#24362d;color:#e6f1e9;background:#111d18}
:root[data-theme="dark"] body,:root[data-theme="dark"] .main,:root[data-theme="dark"] .shell{background:#111d18;color:#e6f1e9}
:root[data-theme="dark"] .sidebar,:root[data-theme="dark"] .topbar,:root[data-theme="dark"] .panel,:root[data-theme="dark"] .card:not(.featured),:root[data-theme="dark"] .bottomnav,:root[data-theme="dark"] dialog,:root[data-theme="dark"] .loan-payment-card,:root[data-theme="dark"] .action-card,:root[data-theme="dark"] .auth{background:#203128;color:#e6f1e9;border-color:var(--line)}
:root[data-theme="dark"] button:not(.primary),:root[data-theme="dark"] input,:root[data-theme="dark"] select,:root[data-theme="dark"] textarea,:root[data-theme="dark"] .action-menu>summary,:root[data-theme="dark"] .action-menu-content{background:#283e32;color:#edf6ef;border-color:#4b6254}
:root[data-theme="dark"] button:hover{background:#375545}:root[data-theme="dark"] .badge,:root[data-theme="dark"] .pill,:root[data-theme="dark"] pre,:root[data-theme="dark"] .simulation-assumptions{background:#34483b!important;color:#e8f0e9!important}
:root[data-theme="dark"] .row-complete td,:root[data-theme="dark"] .goal-complete{background:#244634;color:#b9eac4}:root[data-theme="dark"] .row-overbudget td,:root[data-theme="dark"] .notice.warn{background:#523e25;color:#ffdda5}:root[data-theme="dark"] .row-skipped td,:root[data-theme="dark"] .goal-inactive{background:#2a322c;color:#b4bcb4}
:root[data-theme="dark"] .inline-plan,:root[data-theme="dark"] .inline-execution,:root[data-theme="dark"] .inline-due,:root[data-theme="dark"] .row-complete input,:root[data-theme="dark"] .row-overbudget input{background:#283e32;color:#edf6ef;border-color:#4b6254}:root[data-theme="dark"] .positive{color:#9fe5af!important}:root[data-theme="dark"] .negative{color:#ffaaa5!important}
:root[data-theme="dark"] .nav button.active,:root[data-theme="dark"] .bottomnav button.active{color:#b1eed0}:root[data-theme="dark"] .bar-track,:root[data-theme="dark"] .progress{background:#435447}:root[data-theme="dark"] .donut-legend,:root[data-theme="dark"] .chart-key{color:#d4e1d8}
@media(max-width:720px){:root[data-theme="dark"] .budget-section tr{background:#24362d}:root[data-theme="dark"] .budget-section .row-complete{background:#244634}:root[data-theme="dark"] .budget-section .row-overbudget{background:#523e25}}

/* v0.9.2 — VS Code-inspired navy dark theme. All components, including
   inline-colored category selectors, must retain accessible foregrounds. */
:root[data-theme="dark"]{
 color-scheme:dark;
 --green:#79c0ff;--muted:#a8b6cb;--line:#34465f;--red:#ff858e;
 --surface:#1b283b;--navy-base:#0d1726;--navy-surface:#172438;
 --navy-raised:#23334b;--navy-text:#e6edf7;
 background:var(--navy-base);color:var(--navy-text);
}
:root[data-theme="dark"] body,:root[data-theme="dark"] .shell,:root[data-theme="dark"] .main{background:#0d1726;color:#e6edf7}
:root[data-theme="dark"] .sidebar,:root[data-theme="dark"] .topbar,:root[data-theme="dark"] .panel,:root[data-theme="dark"] .card:not(.featured),:root[data-theme="dark"] .bottomnav,:root[data-theme="dark"] dialog,:root[data-theme="dark"] .loan-payment-card,:root[data-theme="dark"] .action-card,:root[data-theme="dark"] .auth,:root[data-theme="dark"] .budget-section{background:#172438;color:#e6edf7;border-color:#34465f}
:root[data-theme="dark"] input,:root[data-theme="dark"] select,:root[data-theme="dark"] textarea,:root[data-theme="dark"] button:not(.primary),:root[data-theme="dark"] .action-menu>summary,:root[data-theme="dark"] .action-menu-content{background:#23334b;color:#e6edf7;border-color:#425875}
:root[data-theme="dark"] input::placeholder,:root[data-theme="dark"] textarea::placeholder{color:#a8b6cb;opacity:1}
:root[data-theme="dark"] select option,:root[data-theme="dark"] select optgroup{background:#23334b;color:#f1f6ff}
:root[data-theme="dark"] .inline-type{background:#23334b!important;color:#f1f6ff!important;border:1px solid #577193!important;-webkit-text-fill-color:#f1f6ff;opacity:1}
:root[data-theme="dark"] .inline-type option{background:#23334b!important;color:#f1f6ff!important;-webkit-text-fill-color:#f1f6ff}
:root[data-theme="dark"] .inline-type:focus-visible{outline:2px solid #79c0ff;outline-offset:2px}
:root[data-theme="dark"] :is(input,select,textarea):disabled{background:#1b283b!important;color:#b5c2d6!important;opacity:1;-webkit-text-fill-color:#b5c2d6}
:root[data-theme="dark"] .row-complete td,:root[data-theme="dark"] .goal-complete{background:#183a3e;color:#b8eddb}
:root[data-theme="dark"] .row-overbudget td,:root[data-theme="dark"] .notice.warn{background:#49372f;color:#ffe1ba}
:root[data-theme="dark"] .row-skipped td,:root[data-theme="dark"] .goal-inactive{background:#202b3c;color:#b9c5d6}
:root[data-theme="dark"] .row-skipped input,:root[data-theme="dark"] .row-skipped select{background:#28354a!important;color:#c1cee0!important;-webkit-text-fill-color:#c1cee0;border-color:#455a75}
:root[data-theme="dark"] .row-complete .inline-type,:root[data-theme="dark"] .row-overbudget .inline-type,:root[data-theme="dark"] .row-skipped .inline-type{background:#23334b!important;color:#f1f6ff!important;-webkit-text-fill-color:#f1f6ff}
:root[data-theme="dark"] :is(.inline-plan,.inline-execution,.inline-due){background:#23334b!important;color:#e6edf7!important;border-color:#425875!important}
:root[data-theme="dark"] button:not(.primary):hover,:root[data-theme="dark"] .action-menu>summary:hover{background:#304562;color:#fff}
:root[data-theme="dark"] .badge,:root[data-theme="dark"] .pill,:root[data-theme="dark"] pre,:root[data-theme="dark"] .simulation-assumptions{background:#263850!important;color:#e6edf7!important}
:root[data-theme="dark"] .nav button.active,:root[data-theme="dark"] .bottomnav button.active{color:#90c9ff;background:#223b59}
:root[data-theme="dark"] .bar-track,:root[data-theme="dark"] .progress{background:#344760}
:root[data-theme="dark"] .positive{color:#8be6bd!important}
:root[data-theme="dark"] .negative{color:#ff919d!important}
:root[data-theme="dark"] .featured{background:#183452;color:#f2f7ff}
:root[data-theme="dark"] :is(.title,.eyebrow,.section-totals,.group-title,.panel-title,.sub,.inline-help,.execution-result,.row-due-label){color:inherit}
@media(max-width:720px){:root[data-theme="dark"] .budget-section tr{background:#1b2b41;color:#e6edf7}:root[data-theme="dark"] .budget-section tr.row-complete{background:#183a3e}:root[data-theme="dark"] .budget-section tr.row-overbudget{background:#49372f}:root[data-theme="dark"] .budget-section tr.row-skipped{background:#202b3c}}

:root[data-theme="dark"] .inline-type{box-shadow:inset 5px 0 0 var(--type-color,#79c0ff);padding-left:12px}

/* v0.9.3 — unify obligation / savings cards with the navy theme.
   .goal-card was deliberately white in the light layout and had not been
   covered by the original .card/.panel dark overrides. */
:root[data-theme="dark"] .goal-card{
  background:#172438;
  border-color:#34465f;
  color:#e6edf7;
}
:root[data-theme="dark"] .goal-card h2,
:root[data-theme="dark"] .goal-card .amount,
:root[data-theme="dark"] .goal-card .title-button,
:root[data-theme="dark"] .goal-card .mini strong{
  color:#f1f6ff;
}
:root[data-theme="dark"] .goal-card small,
:root[data-theme="dark"] .goal-card .meta,
:root[data-theme="dark"] .goal-card .mini>span{
  color:#afc0d8;
}
:root[data-theme="dark"] .goal-card .mini{border-bottom-color:#34465f}
:root[data-theme="dark"] .loan-card:hover{border-color:#79c0ff}
:root[data-theme="dark"] .goal-card.goal-complete{background:#183a3e;border-color:#326b66}
:root[data-theme="dark"] .goal-card.goal-inactive{background:#202b3c;border-color:#34465f}
:root[data-theme="dark"] .goal-card.goal-inactive .amount,
:root[data-theme="dark"] .goal-card.goal-inactive h2{color:#b9c5d6}


/* v0.9.4 — dark mode must cover unauthenticated pages as well.
   The login layout has its own light radial background, outside .shell. */
:root[data-theme="dark"] .auth-wrap{
  background:radial-gradient(ellipse at 22% 16%,#1c324d 0%,transparent 52%),
             radial-gradient(ellipse at 85% 88%,#14263c 0%,transparent 55%),
             #0d1726;
  color:#e6edf7;
}
:root[data-theme="dark"] .auth{
  background:#172438;
  border:1px solid #34465f;
  color:#e6edf7;
  box-shadow:0 24px 75px #050b1590;
}
:root[data-theme="dark"] .auth h1,
:root[data-theme="dark"] .auth label{color:#e6edf7}
:root[data-theme="dark"] .auth p{color:#b5c5da}
:root[data-theme="dark"] .auth .error-text{color:#ff919d}
:root[data-theme="dark"] .auth input{background:#23334b;color:#f1f6ff;border-color:#425875}
:root[data-theme="dark"] .auth input:focus-visible{outline:2px solid #79c0ff;outline-offset:2px}

/* 0.9.5: decision dashboard and remaining navy surfaces */
.decision-row{display:flex;align-items:center;gap:12px;flex-wrap:wrap;padding:12px 0;border-bottom:1px solid var(--line)}
.decision-row>span{flex:1;min-width:120px}.decision-row strong{font-variant-numeric:tabular-nums}
.decision-group{padding:16px;margin-bottom:12px;border:1px solid var(--line);border-radius:10px}
.decision-group .line{display:flex;justify-content:space-between;gap:12px;flex-wrap:wrap}
.decision-amount{font-size:24px;font-weight:650;margin:10px 0;color:#237451}
.decision-group.needs-attention{border-left:4px solid #cc7725}.needs-attention .decision-amount{color:#a55d13}
.decision-panels .notice p{margin:8px 0 0}.decision-panels .mini{flex-wrap:wrap}
:root[data-theme="dark"] :is(.notice,.loan-calendar-info,.expense-summary,.schedule-summary,.form-section-title){background:#20334d;color:#dce8fa;border-color:#3c5270}
:root[data-theme="dark"] .notice.error{background:#442738;color:#ffb6c3;border-color:#865064}
:root[data-theme="dark"] :is(.notice.warn,.action-card.attention){background:#42352b;color:#ffdcaa;border-color:#876139}
:root[data-theme="dark"] :is(.category,td,.mini,.expense-row,.decision-row){border-color:#34465f}
:root[data-theme="dark"] :is(th,.card h3,.toolbar label span,.empty,.loading,.user-tag,.nav button){color:#b5c5da}
:root[data-theme="dark"] :is(a,.linkbutton,.title-button){color:#90c9ff}
:root[data-theme="dark"] button.danger{color:#ff9dab}
:root[data-theme="dark"] .section-tabs button.active{background:#285581;color:#fff;border-color:#6191c0}
:root[data-theme="dark"] .decision-amount{color:#8be6bd}
:root[data-theme="dark"] .needs-attention .decision-amount{color:#ffcf94}
:root[data-theme="dark"] input::placeholder,:root[data-theme="dark"] textarea::placeholder{color:#9cacc3;opacity:1}
:root[data-theme="dark"] dialog::backdrop{background:#030b18b8}
:root[data-theme="dark"] :is(button,input,select,textarea,summary):focus-visible{outline:2px solid #90c9ff;outline-offset:3px}
@media(max-width:900px){.decision-panels{grid-template-columns:1fr}}

/* v0.9.8 — organizacja i szybkie zamykanie planu */
.month-filters{display:flex;gap:12px;flex-wrap:wrap;align-items:end}.month-filters label{display:grid;gap:5px;min-width:135px;font-size:12px}.month-filters label.hidden-toggle{display:flex;align-items:center;min-width:0;gap:8px;padding-bottom:8px}.month-filters input[type=search]{min-width:135px;max-width:210px}.item-title-line{display:inline-flex;align-items:center;gap:7px}.pin-item{border:0!important;background:transparent!important;padding:2px 4px!important;min-width:25px;min-height:25px;color:var(--muted);font-size:19px;line-height:1}.pin-item.is-pinned{color:#d19b36!important}.close-controls{display:flex;align-items:center;justify-content:center;gap:8px}.pay-close-btn{padding:5px 8px!important;font-size:11px!important;min-height:27px!important;white-space:nowrap;border-radius:7px!important}.row-skipped .pay-close-btn{opacity:.8}@media(max-width:720px){.month-filters{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}.month-filters label{min-width:0}.month-filters select,.month-filters input[type=search]{width:100%;max-width:100%;min-width:0}.close-controls{justify-content:flex-end}}:root[data-theme="dark"] .pin-item.is-pinned{color:#ffd17c!important}

/* 0.9.9: Odkrywanie ukrytych pozycji tylko w obrębie sekcji. */
.section-hidden-btn{font-size:12px!important;padding:6px 10px!important;white-space:nowrap;border:1px solid var(--line)!important;background:var(--surface)!important;color:var(--text)!important;border-radius:8px!important}
.section-hidden-btn:hover{filter:brightness(.94)}
:root[data-theme="dark"] .section-hidden-btn:hover{filter:brightness(1.22)}

.drag-handle{touch-action:none;cursor:grab;padding:6px;min-width:36px}.drop-target{outline:2px solid #60a5fa;outline-offset:-2px}.savings-chart{display:grid;grid-template-columns:200px 1fr;gap:24px;align-items:center;margin-top:24px}.savings-chart svg{max-width:200px;width:100%}@media(max-width:650px){.savings-chart{grid-template-columns:1fr}.savings-chart svg{margin:auto}.savings-chart .mini{flex-wrap:wrap}}
/* Independent project lists, responsive and theme-aware. */
.project-list{display:grid;gap:12px}.project-row{padding:16px;border:1px solid var(--line);border-radius:12px}.project-item-title{display:flex;align-items:center;gap:10px}.project-item-title strong{overflow-wrap:anywhere}.project-amounts{display:flex;flex-wrap:wrap;gap:12px;margin:12px 0}.project-notes{white-space:pre-wrap;overflow-wrap:anywhere}.project-row .actions{flex-wrap:wrap}.project-row.row-skipped{opacity:.55}.project-row.row-complete{background:var(--success-bg,#edf7ee)}[data-theme="dark"] .project-row.row-complete{background:#16372d}.project-row.row-overbudget{background:#fff0db}[data-theme="dark"] .project-row.row-overbudget{background:#49331d}
/* Compact plans: shared columns, direct inputs, expandable details. */
.project-index{padding:0;overflow:visible}.project-index-head,.project-index-row{display:grid;grid-template-columns:minmax(220px,2.2fr) minmax(70px,.65fr) repeat(3,minmax(110px,1fr));gap:18px;align-items:center;padding:14px 18px}.project-index-head{color:var(--muted);font-size:12px;border-bottom:1px solid var(--line)}.project-index-row+.project-index-row{border-top:1px solid var(--line)}.project-index-row.is-archived{opacity:.6}.project-title-link{border:0;background:transparent!important;color:inherit;text-align:left;padding:0;min-height:32px;overflow-wrap:anywhere}.project-index-row .progress{margin:6px 0 0;height:4px}.project-summary{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));border:1px solid var(--line);border-radius:12px;padding:14px 18px;gap:16px}.project-summary>div{display:grid;gap:5px}.project-summary>div>span{color:var(--muted);font-size:12px}.project-summary strong{font-size:20px}.project-toolbar{display:flex;justify-content:space-between;align-items:center;gap:12px;margin:12px 0}.project-help{font-size:12px;max-width:580px}.project-help summary{cursor:pointer;color:var(--muted)}.project-help>div{padding:10px 0;line-height:1.6}.compact-project-section{padding:12px 16px}.compact-project-section .panel-title{margin-bottom:8px}.compact-project-section h2{font-size:16px}.compact-project-section .project-list{gap:0}.project-columns,.compact-project-row{display:grid;grid-template-columns:minmax(180px,1fr) 64px 105px 115px 110px 115px 40px;gap:12px;align-items:center}.project-columns{font-size:12px;color:var(--muted);padding:8px}.compact-project-row{padding:8px;border:0;border-top:1px solid var(--line);border-radius:0}.compact-project-row .project-item-title{gap:8px;min-width:0}.compact-project-row .project-item-title>input{flex-shrink:0}.project-name{min-width:0}.project-name strong{font-size:14px}.project-inline{padding:6px 8px;min-height:36px;text-align:right;font-size:14px;width:100%;min-width:0}.project-quantity,.project-unit,.project-spent{margin:0;min-width:0}.project-planned{text-align:right;font-size:13px}.project-planned .sub{font-size:11px;margin-top:3px}.compact-project-row .drag-handle{padding:4px;min-height:32px;min-width:26px;flex-shrink:0}.project-grip-spacer{width:26px;flex-shrink:0}.project-row-menu .action-menu>summary{padding:5px 10px;min-height:34px}.project-item-note{font-size:12px;margin-top:3px}.project-item-note summary{cursor:pointer;color:var(--muted)}.project-item-note p{margin:6px 0}.project-row .mobile-label,.project-index .mobile-label{display:none}.project-row-menu .action-menu-content{right:0;left:auto}
@media(max-width:1100px){.project-columns,.compact-project-row{grid-template-columns:minmax(150px,1fr) 55px 85px 100px 90px 100px 36px;gap:8px}.project-index-head,.project-index-row{gap:10px;grid-template-columns:minmax(170px,1.5fr) 65px repeat(3,minmax(85px,1fr))}}
@media(max-width:1000px){.project-index-head,.project-columns{display:none}.project-index-row{grid-template-columns:1fr 1fr;padding:12px}.project-index-row>div:first-child{grid-column:1/-1}.project-index .mobile-label,.project-row .mobile-label{display:block;font-size:11px;color:var(--muted);margin-bottom:4px}.project-summary{grid-template-columns:1fr 1fr;padding:12px;gap:12px}.project-summary strong{font-size:18px}.project-toolbar{align-items:flex-start;flex-wrap:wrap}.compact-project-section{padding:10px}.compact-project-row{grid-template-columns:60px minmax(80px,1fr) minmax(95px,1fr) 36px;gap:10px;padding:10px 0}.compact-project-row .project-item-title{grid-column:1/4;grid-row:1}.project-row-menu{grid-column:4;grid-row:1}.project-quantity{grid-column:1;grid-row:2}.project-unit{grid-column:2;grid-row:2}.project-spent{grid-column:3/5;grid-row:2}.project-planned{grid-column:1/-1;grid-row:3;text-align:left;display:flex;align-items:baseline;gap:8px;flex-wrap:wrap}.project-planned .mobile-label{margin:0}.project-planned .sub{margin:0 0 0 auto}.project-inline{font-size:16px;min-height:40px}.compact-project-row .drag-handle{min-height:40px}.project-grip-spacer{display:none}}

.project-difference{text-align:right;font-size:13px;white-space:nowrap}.project-columns>span:not(:first-child){text-align:right}
@media(max-width:1000px){.project-planned{grid-column:1/3;grid-row:3}.project-difference{grid-column:3/5;grid-row:3;display:flex;justify-content:flex-end;gap:8px;align-items:baseline;flex-wrap:wrap}.project-difference .mobile-label{margin:0}}

.mfa-qr{display:block;max-width:100%;width:260px;height:auto;margin:16px auto;background:white}.mfa-secret,.recovery-codes{display:block;overflow-wrap:anywhere;white-space:pre-wrap;user-select:all;font-size:14px;line-height:1.7}.auth details{margin:12px 0}.auth #mfa-back{margin-top:12px;width:100%}

/* Savings and project forecast readability */
.project-index-head,.project-index-row{grid-template-columns:minmax(190px,2fr) minmax(70px,.6fr) minmax(95px,.8fr) minmax(100px,.85fr) minmax(205px,1.35fr)}
.project-index-row>div{min-width:0}.project-forecast{display:grid;gap:5px;min-width:0}.project-forecast-total{font-size:19px;line-height:1.25;overflow-wrap:anywhere}.project-forecast-row{display:flex;justify-content:space-between;gap:10px;align-items:baseline;font-size:12px;color:var(--muted);line-height:1.45}.project-forecast-row span:last-child{font-variant-numeric:tabular-nums;text-align:right;color:inherit}
.savings-goals-panel{margin-bottom:16px}.savings-goal-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,280px),1fr));gap:12px}.savings-goal-card{min-width:0;border:1px solid var(--line);background:rgba(120,140,120,.045);border-radius:12px;padding:16px;display:flex;flex-direction:column;gap:12px}.savings-goal-top{display:flex;justify-content:space-between;align-items:flex-start;gap:10px}.savings-goal-top h3{font-size:16px;margin:0 0 4px;overflow-wrap:anywhere}.savings-goal-top .muted{font-size:12px}.savings-include{white-space:nowrap;min-height:34px;padding:5px 9px;font-size:12px}.savings-goal-balance{display:flex;justify-content:space-between;align-items:baseline;gap:10px}.savings-goal-balance strong{font-size:22px;font-variant-numeric:tabular-nums;overflow-wrap:anywhere}.savings-goal-balance span,.savings-goal-meta{font-size:12px;color:var(--muted)}.savings-goal-card .progress{margin:-7px 0}.savings-goal-meta{display:flex;justify-content:space-between;gap:8px;line-height:1.45}.savings-goal-deadline{border-top:1px solid var(--line);padding-top:9px}.savings-goal-actions{margin-top:auto;display:flex;flex-wrap:wrap;gap:7px}.savings-goal-actions button{flex:1 1 auto}.savings-filters{display:grid;grid-template-columns:minmax(180px,1.5fr) minmax(150px,.8fr) minmax(180px,1fr) auto;gap:10px;align-items:end;margin:12px 0 16px}.savings-filters label{margin:0}.savings-filters label>span{display:block;font-size:12px;color:var(--muted);margin-bottom:5px}.savings-filters input,.savings-filters select{width:100%;min-width:0}
@media(max-width:1100px){.project-index-head,.project-index-row{grid-template-columns:minmax(155px,1.5fr) 60px minmax(78px,.8fr) minmax(84px,.8fr) minmax(165px,1.3fr);gap:9px}}
@media(max-width:1000px){.project-index-row{grid-template-columns:1fr 1fr}.project-index-row>div:not(:first-child){min-width:0}.project-forecast{grid-column:1/-1;border-top:1px solid var(--line);padding-top:9px}.savings-filters{grid-template-columns:1fr 1fr}.savings-filters label:first-child{grid-column:1/-1}}
@media(max-width:520px){.savings-filters{grid-template-columns:1fr}.savings-filters label:first-child{grid-column:auto}.savings-goal-grid{grid-template-columns:1fr}.savings-goal-card{padding:13px}.savings-goal-actions button{min-width:calc(50% - 7px)}}

/* 0.9.22: payment agenda and a readable month-end forecast. */
.payment-agenda{padding:0;overflow:hidden;margin-bottom:22px}
.payment-agenda>summary{display:flex;justify-content:space-between;align-items:center;gap:14px;padding:17px 20px;cursor:pointer;list-style:none}
.payment-agenda>summary::-webkit-details-marker{display:none}
.payment-agenda>summary::after{content:'⌄';font-size:19px;color:var(--muted)}
.payment-agenda[open]>summary::after{content:'⌃'}
.payment-agenda>summary strong{font-size:16px}
.payment-agenda>summary span{font-size:12px;color:var(--muted);text-align:right}
.payment-agenda-content{padding:0 20px 18px;border-top:1px solid var(--line)}
.payment-agenda-content h3{margin:17px 0 8px}
.payment-agenda-content h3.attention-title{color:var(--red)}
.forecast-result{display:flex;justify-content:space-between;align-items:baseline;gap:14px;padding:15px 16px;margin:14px 0;background:#edf4e8;border-radius:10px}
.forecast-result span{font-size:13px;color:var(--muted)}
.forecast-result strong{font-size:24px;font-variant-numeric:tabular-nums;text-align:right}
.forecast-breakdown{padding:4px 0}
.forecast-breakdown .mini{padding:7px 0;border-bottom:1px solid var(--line)}
@media(max-width:600px){.payment-agenda>summary{align-items:flex-start;flex-wrap:wrap}.payment-agenda>summary span{order:3;text-align:left;width:100%}.forecast-result{align-items:flex-start;flex-direction:column}.forecast-result strong{text-align:left}}

/* 0.9.23: readable dark forecast, backup controls and recoverable deletion. */
:root[data-theme="dark"] .forecast-result{background:#203a32;color:#edf7ee;border:1px solid #365847}
:root[data-theme="dark"] .forecast-result span{color:#bed0c5}
.backup-download{display:inline-flex;align-items:center;justify-content:center;padding:10px 14px;border-radius:9px;background:var(--green);color:#fff;text-decoration:none;font-weight:650}
.backup-download:hover{filter:brightness(1.12)}
.trash-row{align-items:flex-start;gap:14px;border-bottom:1px solid var(--line)}
.trash-row>span{min-width:0}.trash-row .actions{justify-content:flex-end}

/* Ujednolicone tabele i wyniki */
.table-wrap table{font-variant-numeric:tabular-nums;line-height:1.45}
.table-wrap th,.table-wrap td{vertical-align:middle}
.table-wrap th{height:44px}
.table-wrap td{min-height:48px}
.payment-agenda-table{table-layout:fixed;width:100%;min-width:680px}
.payment-agenda-table th:nth-child(1),.payment-agenda-table td:nth-child(1){width:36%;white-space:normal;overflow-wrap:anywhere}
.payment-agenda-table th:nth-child(2),.payment-agenda-table td:nth-child(2){width:20%}
.payment-agenda-table th:nth-child(3),.payment-agenda-table td:nth-child(3){width:18%;text-align:right}
.payment-agenda-table th:nth-child(4),.payment-agenda-table td:nth-child(4){width:26%}
.payment-agenda-table td:nth-child(4) button{width:100%;white-space:normal;line-height:1.25}
.payment-agenda-table td:nth-child(3){font-variant-numeric:tabular-nums}

/* Przełącznik aktywności */
.active-toggle{display:flex;align-items:center;gap:12px;min-height:58px;padding:12px 14px;border:1px solid var(--line);border-radius:10px;background:var(--surface,#fff);cursor:pointer}
.active-toggle>input{position:absolute;opacity:0;width:1px;height:1px;min-height:1px}
.active-toggle .toggle-track{position:relative;flex:0 0 42px;width:42px;height:24px;border-radius:20px;background:#b8c1ba;transition:background .16s}
.active-toggle .toggle-track:after{content:'';position:absolute;left:3px;top:3px;width:18px;height:18px;border-radius:50%;background:#fff;box-shadow:0 1px 3px #0003;transition:transform .16s}
.active-toggle input:checked+.toggle-track{background:#25804b}
.active-toggle input:checked+.toggle-track:after{transform:translateX(18px)}
.active-toggle input:focus-visible+.toggle-track{outline:2px solid #528e62;outline-offset:3px}
.active-toggle .toggle-copy{display:grid;gap:3px}
.active-toggle .toggle-copy strong{font-size:13px;color:var(--muted)}
.active-toggle.is-active .toggle-copy strong{color:#25804b}
.active-toggle .toggle-copy small{line-height:1.4}

/* Wybór elementów w koszu */
.trash-row{padding:14px 0;border-bottom:1px solid var(--line)}
.trash-row:last-child{border-bottom:0}
.trash-row-head{display:flex;justify-content:space-between;align-items:center;gap:16px}
.trash-row-head>span{min-width:0}
.trash-selection{margin-top:12px;padding:12px;border-radius:9px;background:var(--soft,#f4f6f2)}
.trash-selection summary{cursor:pointer;font-weight:600;color:var(--green);font-size:12px}
.trash-select-list{display:grid;gap:5px;margin:10px 0}
.trash-select-list label{display:flex;align-items:flex-start;gap:10px;padding:9px;border-radius:7px;background:var(--surface,#fff);font-size:13px}
.trash-select-list input{width:18px;height:18px;min-height:18px;flex:0 0 auto;margin-top:1px}
.trash-select-list span{min-width:0;overflow-wrap:anywhere}
.trash-select-list .sub{font-weight:400}
@media(max-width:720px){.payment-agenda-table{min-width:650px}.trash-row-head{align-items:flex-start;flex-direction:column}.active-toggle{padding:10px 12px}}
.status-switch{display:inline-flex;align-items:center;gap:8px;margin-top:8px;font-size:12px;color:var(--muted);cursor:pointer}
.status-switch input{position:absolute;opacity:0;width:1px;height:1px;min-height:1px}
.status-switch .status-track{width:38px;height:22px;border-radius:14px;background:#aeb8b0;position:relative;transition:background .16s}
.status-switch .status-track:after{content:'';position:absolute;left:3px;top:3px;width:16px;height:16px;border-radius:50%;background:#fff;transition:transform .16s}
.status-switch input:checked+.status-track{background:#25804b}
.status-switch input:checked+.status-track:after{transform:translateX(16px)}
.status-switch input:focus-visible+.status-track{outline:2px solid #528e62;outline-offset:3px}
.status-switch.is-active strong,.goal-switch:has(input:checked){color:#25804b;font-weight:700}
.trash-selection{background:color-mix(in srgb,var(--surface,#fff) 72%,var(--line))}
@media(max-width:720px){.status-switch{margin:8px 0 0}}
:root[data-theme="dark"] .status-switch.is-active strong,:root[data-theme="dark"] .goal-switch:has(input:checked),:root[data-theme="dark"] .active-toggle.is-active .toggle-copy strong{color:#78d399}
.project-index-primary{display:grid;justify-items:start;gap:7px;min-width:0}
.project-index-primary .project-title-link{font-size:16px;font-weight:700;line-height:1.35;max-width:100%;white-space:normal}
.project-index-primary .project-title-link span{color:var(--muted);font-size:14px}
.project-deadline{display:inline-flex;align-items:center;min-height:24px;padding:3px 9px;border-radius:999px;background:color-mix(in srgb,var(--green) 9%,transparent);color:var(--green);font-size:11px;font-weight:650;line-height:1.3}
.project-deadline.is-late{background:#fbe9e6;color:#a53c32}.project-deadline.is-today{background:#fff2d9;color:#795714}.project-deadline.is-muted{background:color-mix(in srgb,var(--muted) 12%,transparent);color:var(--muted)}
.project-status-control{margin:1px 0 0;padding:7px 10px;border:1px solid var(--line);border-radius:11px;background:color-mix(in srgb,var(--surface,#fff) 80%,var(--line));gap:9px;min-width:145px;min-height:46px;transition:border-color .16s,background .16s;}
.project-status-control:hover{border-color:#83aa88;background:color-mix(in srgb,#25804b 7%,var(--surface,#fff))}
.project-status-control .status-track{width:42px;height:24px;flex:0 0 42px}
.project-status-control .status-track:after{width:18px;height:18px;top:3px;left:3px}
.project-status-control input:checked+.status-track:after{transform:translateX(18px)}
.project-status-control .status-copy{display:grid;gap:1px;line-height:1.2}
.project-status-control .status-copy strong{font-size:12px;color:var(--muted)}
.project-status-control .status-copy small{font-size:10px;color:var(--muted)}
.project-status-control.is-active{border-color:color-mix(in srgb,#25804b 35%,var(--line));background:color-mix(in srgb,#25804b 7%,var(--surface,#fff))}
.project-status-control.is-active .status-copy strong{color:#25804b}
.project-status-control.is-saving{opacity:.72;cursor:wait}
.project-status-control.is-disabled{opacity:.6;cursor:not-allowed}
.project-completion{display:grid;gap:5px;width:min(100%,240px);margin-top:1px}
.project-completion-copy{display:flex;justify-content:space-between;gap:8px;align-items:baseline;font-size:10px;color:var(--muted)}
.project-completion-copy strong{font-size:10px;color:var(--text,#172d29);font-variant-numeric:tabular-nums;white-space:nowrap}
.project-progress{height:6px;background:color-mix(in srgb,var(--muted) 18%,transparent);border-radius:99px;overflow:hidden}
.project-progress i{display:block;height:100%;background:#25804b;border-radius:inherit;transition:width .2s}
@media(max-width:1000px){.project-completion{width:min(100%,360px)}.project-index-primary{gap:8px}.project-index-primary .project-status-control{margin-top:1px}}
@media(max-width:600px){.project-index-primary .project-title-link{font-size:15px}.project-status-control{min-width:145px}.project-deadline{white-space:normal}}
:root[data-theme="dark"] .project-deadline{background:color-mix(in srgb,#78d399 16%,transparent);color:#a5e5b8}
:root[data-theme="dark"] .project-deadline.is-late{background:#552a29;color:#ffaaa0}
:root[data-theme="dark"] .project-deadline.is-today{background:#4b3d20;color:#f6d88a}
:root[data-theme="dark"] .project-deadline.is-muted{background:color-mix(in srgb,#a6b0aa 15%,transparent);color:#b5c0b8}
:root[data-theme="dark"] .project-status-control.is-active .status-copy strong{color:#78d399}
:root[data-theme="dark"] .project-status-control.is-active{background:color-mix(in srgb,#25804b 18%,var(--surface,#fff))}
