:root{--ink:#18364b;--muted:#687f8b;--teal:#007d86;--line:#dae5ea;--bg:#f1f5f7;--green:#eaf5ee;--red:#8A4B08;font:15px system-ui,-apple-system,"Noto Sans SC",sans-serif;color:var(--ink);background:var(--bg)}*{box-sizing:border-box}body{margin:0;padding:env(safe-area-inset-top) 0 calc(85px + env(safe-area-inset-bottom));font-variant-numeric:tabular-nums}header{max-width:1000px;margin:auto;padding:20px 20px 8px;display:flex;align-items:center;justify-content:space-between}header small{font-size:11px;color:var(--muted)}h1{font-size:20px;margin:5px 0}h1 span{font-size:10px;font-weight:500;color:var(--muted)}h2{font-size:18px;margin:0 0 16px}h3{font-size:15px;margin:0 0 12px}p{line-height:1.6}small,.muted{color:var(--muted);font-size:12px}button,input,select,textarea{font:inherit;color:inherit}button{min-height:44px;border:1px solid var(--line);border-radius:10px;background:white;padding:8px 13px;cursor:pointer;white-space:nowrap}button:disabled{opacity:.5;cursor:wait}.primary,button.active{color:white;background:var(--ink);border-color:var(--ink)}button.danger{color:var(--red)}input,select,textarea{width:100%;min-height:44px;border:1px solid #cddde4;border-radius:10px;background:white;padding:10px;min-width:0}input[type=checkbox]{width:20px;min-height:20px;margin:0 8px 0 0}label{display:block;color:var(--muted);font-size:12px}label>input,label>select,label>textarea{margin-top:6px;color:var(--ink);font-size:15px}label.check{display:flex;align-items:center;min-height:44px}form{display:grid;grid-template-columns:1fr 1fr;gap:14px}.wide{grid-column:1/-1}.actions{display:flex;gap:8px;flex-wrap:wrap;align-items:center}.right{margin-left:auto}.card{background:white;border:1px solid var(--line);border-radius:16px;padding:18px;margin-bottom:14px;min-width:0}main{max-width:1000px;margin:auto;padding:12px 16px}.goal{background:linear-gradient(120deg,#eaf4ed,#f6faf6);border-color:#d8e7dc}.summary{display:grid;grid-template-columns:repeat(2,1fr);gap:14px}.metric small{display:block;margin-bottom:6px}.metric strong{display:block;font-size:24px}.metric.accent strong{color:var(--teal);font-size:28px}.metric.negative strong,.negative{color:var(--red)}progress{width:100%;height:5px;accent-color:var(--teal)}.toolbar{display:grid;grid-template-columns:80px 1fr 115px;gap:8px;margin-bottom:14px}.toolbar input,.toolbar select{font-size:12px;padding:8px;min-height:40px}.row{display:grid;grid-template-columns:45px minmax(0,1fr) auto 44px;align-items:center;gap:8px;min-height:48px;border-bottom:1px solid var(--line);font-size:12px}.row .main{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.row .amount{font-size:15px;font-weight:650}.row button{border:0;background:none;padding:0;width:44px}.category{padding:12px 0;border-bottom:1px solid var(--line)}.category .head{display:flex;gap:10px;align-items:center;justify-content:space-between}.category .remaining{font-size:20px;font-weight:750;color:var(--teal)}.category .remaining.negative{color:var(--red)}.category small{font-size:11px}.segments{display:flex;gap:4px;background:#eaf0f4;padding:4px;border-radius:12px;margin-bottom:16px}.segments button{flex:1;border:0;background:transparent}.segments button.active{background:var(--ink)}#syncStatus{max-width:960px;margin:0 auto;padding:2px 16px;font-size:11px;color:var(--muted);min-height:22px}#nav{position:fixed;bottom:0;left:0;right:0;display:flex;background:rgba(255,255,255,.97);border-top:1px solid var(--line);padding:6px 12px calc(6px + env(safe-area-inset-bottom));z-index:10}#nav button{flex:1;border:0;background:transparent;font-size:13px}#nav button.active{color:var(--teal);background:#e8f4f1}.amount-input{font-size:32px;font-weight:650;min-height:68px}.split{display:grid;grid-template-columns:1fr 1fr;gap:14px}.privacy .money{filter:blur(8px);user-select:none}.privacy input[data-money]{color:transparent;text-shadow:0 0 9px var(--ink)}details>summary{cursor:pointer;min-height:44px;display:flex;align-items:center;font-size:13px;font-weight:600;gap:8px}details[open]>summary{margin-bottom:14px}dialog{max-width:650px;width:calc(100% - 30px);max-height:86dvh;overflow:auto;border:1px solid var(--line);border-radius:18px;padding:22px;color:var(--ink)}dialog::backdrop{background:#18364b66}dialog form{margin-bottom:16px}#toast{position:fixed;bottom:92px;left:16px;right:16px;margin:auto;max-width:700px;padding:12px 16px;border-radius:12px;background:var(--ink);color:white;z-index:30;font-size:13px;box-shadow:0 4px 20px #0002}.bad{background:#fff2e8;padding:10px;border-radius:10px;font-size:12px}.empty{padding:20px 0;color:var(--muted);font-size:13px}.editor-row{display:grid;grid-template-columns:minmax(0,1fr) 105px;gap:8px;margin:8px 0}.note{font-size:12px;line-height:1.65;color:var(--muted)}table{width:100%;border-collapse:collapse;font-size:12px}th,td{text-align:right;border-bottom:1px solid var(--line);padding:10px 3px}th:first-child,td:first-child{text-align:left}.scroll{overflow:auto}#closeModal{width:100%;margin-top:14px}a{color:var(--teal)}@media(min-width:720px){.summary{grid-template-columns:repeat(3,1fr)}.home-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px;align-items:start}.home-grid>.card{margin-bottom:0}.toolbar{grid-template-columns:110px 180px 150px;justify-content:end}.entry-card{max-width:650px;margin:auto}#nav{left:50%;transform:translateX(-50%);max-width:1000px;border-radius:16px 16px 0 0}}@media(max-width:380px){header{padding-left:16px;padding-right:16px}h1{font-size:18px}.card{padding:14px}.metric strong{font-size:21px}.metric.accent strong{font-size:25px}form{gap:10px}.toolbar{grid-template-columns:65px 1fr 100px}.toolbar input{font-size:11px}.row{gap:5px;grid-template-columns:39px minmax(0,1fr) auto 44px}}

.goal .summary{grid-template-columns:repeat(4,1fr)}.goal .metric strong{font-size:20px}.goal .metric small{font-size:11px}.goal .metric strong small{display:inline;margin-left:4px;font-size:12px}@media(max-width:719px){.goal .summary{grid-template-columns:1fr 1fr}}
#nav button{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;padding:4px 0;font-size:11px;min-width:0}#nav button span{font-size:20px;line-height:24px}.three{grid-template-columns:repeat(3,minmax(0,1fr))}.three .metric strong{font-size:21px}.compact h2{margin:0}.compact .summary{margin-top:14px}.entry-layout{display:grid;gap:14px}.entry-card{max-width:none;width:100%;margin:0 0 14px}.entry-layout .ledger{align-self:start}.filter-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:8px 0 14px}.filter-grid select,.filter-grid input{font-size:12px}.toolbar{grid-template-columns:64px minmax(0,1fr) 110px}.toolbar input:nth-last-child(2),.toolbar input:last-child{min-width:0}.toolbar:has(#start){grid-template-columns:64px minmax(0,1fr) 110px}.toolbar #start{grid-column:1/3}.toolbar #last{grid-column:3}.chart-grid{display:grid;gap:24px;margin:20px 0}.bar-row{display:grid;grid-template-columns:80px minmax(15px,1fr) 78px;gap:8px;border:0;border-radius:0;width:100%;padding:3px 0;align-items:center;font-size:11px;text-align:left;white-space:normal}.bar-row b{text-align:right}.bar-track{display:block;background:#edf2f4;height:10px;border-radius:5px;overflow:hidden}.bar-track i{display:block;min-width:1px;height:100%;border-radius:5px}.ring{width:180px;height:180px;display:block;margin:auto}.ring circle{cursor:pointer}.legend{display:flex;justify-content:center;flex-wrap:wrap;gap:5px 14px;font-size:11px;color:var(--teal)}.legend button{border:0;padding:2px 5px;display:flex;gap:6px;align-items:center;font-size:11px}.legend i{width:8px;height:8px;border-radius:50%}.trend{width:100%;max-height:260px}.asset-row{display:flex;width:100%;align-items:center;justify-content:space-between;text-align:left;white-space:normal;border:0;border-bottom:1px solid var(--line);border-radius:0;padding:12px 0;gap:10px}.asset-row small{display:block;font-size:10px;margin-top:6px}.asset-row strong{white-space:nowrap}.privacy .bar-track,.privacy .ring,.privacy .trend{filter:blur(8px)}h2{margin-bottom:12px}#app>.toolbar{margin-left:auto}.card .actions h2,.card .actions h3{margin-bottom:0}.card .actions{margin-bottom:12px}#ledgerFilter[hidden]{display:none}.ledger .row .main small{font-size:10px}#ledgerRows{max-height:600px;overflow:auto}#clearDraft{font-size:11px}#assetForm label{min-width:0}@media(min-width:768px){.entry-layout{grid-template-columns:1fr 1fr;align-items:start}.chart-grid{grid-template-columns:1fr 1fr}.toolbar,.toolbar:has(#start){grid-template-columns:64px 160px 130px;max-width:620px}.toolbar:has(#start){grid-template-columns:64px 140px 130px 140px 140px;max-width:100%}.toolbar #start,.toolbar #last{grid-column:auto}}@media(max-width:380px){.three .metric strong{font-size:17px}.three{gap:8px}.toolbar{grid-template-columns:55px minmax(0,1fr) 100px}.bar-row{grid-template-columns:70px minmax(10px,1fr) 73px}.row .amount{font-size:13px}}
.glyph{width:22px;height:22px;flex:none;vertical-align:middle}button>.glyph{margin-right:7px}#nav .glyph{width:22px;height:22px;margin:0;stroke:currentColor}button.selected{outline:2px solid var(--teal);outline-offset:-2px;background:var(--green)}.day-head{display:flex;justify-content:space-between;gap:8px;padding:15px 0 6px;align-items:center;font-size:11px}.day-head small{font-size:10px}.row{grid-template-columns:28px minmax(0,1fr) auto 44px}.row>.glyph{width:20px;height:20px}.choice-button{display:flex;align-items:center;width:100%;margin-top:6px;white-space:normal;text-align:left;font-size:13px}.sr-control{position:absolute!important;width:1px!important;height:1px!important;min-height:0!important;padding:0!important;opacity:0;pointer-events:none}.category-picker{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;margin-bottom:16px}.category-picker button{display:flex;flex-direction:column;gap:8px;align-items:center;padding:10px 4px;white-space:normal;font-size:11px;min-width:0}.category-picker button .glyph{margin:0;width:25px;height:25px}.pace{display:flex;gap:10px;flex-wrap:wrap;font-size:11px;color:var(--muted);padding:12px 0 0}.pace span{background:var(--green);padding:7px 10px;border-radius:8px}.icon-grid{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:6px}.icon-grid button{padding:5px;min-width:0}.icon-grid .glyph{margin:0}.editor-page .editor-row{grid-template-columns:minmax(0,1fr) 90px auto;align-items:center}.editor-page .editor-row button{font-size:11px;white-space:normal;text-align:left;padding:4px}.editor-row>div{display:flex}.editor-row>div button{min-width:44px;padding:4px!important}.editor-page .actions button{font-size:12px}.sticky-actions{position:sticky;bottom:72px;z-index:3;padding:12px;background:var(--bg);border:1px solid var(--line);border-radius:12px;margin-top:16px}#app>.editor-page{max-width:850px;margin:auto}.skin-options{display:grid;grid-template-columns:1fr 1fr;gap:12px}.skin-options button{display:flex;flex-direction:column;gap:12px;white-space:normal;font-size:12px;align-items:center}.skin-preview{width:100%;height:45px;border-radius:8px;display:block;background:linear-gradient(130deg,#18364b 25%,#eaf5ee 25%,#f1f5f7 80%)}.skin-preview.mint{background:linear-gradient(130deg,#48ab93 25%,#e8f5ef 25%,#f3f8f5 80%)}.asset-group-title{display:flex;align-items:center;gap:8px;margin:18px 0 4px;padding-top:10px;border-top:1px solid var(--line);font-size:12px}.asset-row{font-size:13px}.asset-row strong{font-size:15px}.rank-title{margin-top:20px}.import-list{max-height:45vh;overflow:auto;margin:14px 0}.import-list label{border-bottom:1px solid var(--line);padding:8px 0}.import-list small{display:block;margin-top:4px;font-size:11px}.chart-switch{margin-top:16px}#periodCompare[hidden],#ring[hidden],#trend[hidden]{display:none}.category .head button{display:flex;align-items:center;min-width:0;white-space:normal;text-align:left;font-size:13px}.editor-page h2{margin:0}.privacy .day-head .money{filter:blur(8px)}
:root[data-theme=mint]{--ink:#263e36;--muted:#788c81;--teal:#38967e;--line:#e1ece5;--bg:#f3f8f5;--green:#e8f5ef;--red:#8A4B08;color:var(--ink);background:var(--bg)}[data-theme=mint] .card{border-radius:13px;border-color:#e1ece5;box-shadow:0 3px 16px #305e4105}[data-theme=mint] .primary,[data-theme=mint] button.active{background:#48ab93;border-color:#48ab93;color:#fff}[data-theme=mint] .segments{background:#eff6f1}[data-theme=mint] .segments button.active{background:#48ab93}[data-theme=mint] .goal{background:linear-gradient(120deg,#e9f5ef,#f8fcf9);border-color:#daebe0}[data-theme=mint] .compact{background:linear-gradient(110deg,#e8f5ef,#fff)}[data-theme=mint] #nav button.active{background:#e8f5ef;color:#38967e}[data-theme=mint] input,[data-theme=mint] select,[data-theme=mint] textarea{border-color:#dce8e0}[data-theme=mint] #toast{background:#315e4c}[data-theme=mint] .bar-track{background:#edf5ef}[data-theme=mint] .bad{background:#fcf2e9}[data-theme=mint] #closeModal{background:#eff6f1}[data-theme=mint] .row .main{font-size:12px}[data-theme=mint] .day-head{color:#788c81}[data-theme=mint] .metric.accent strong{color:#38967e}@media(max-width:380px){.editor-page .editor-row{grid-template-columns:minmax(0,1fr) 75px}.editor-row>div{grid-column:1/-1;justify-content:end}.category-picker{grid-template-columns:repeat(3,minmax(0,1fr))}.row{grid-template-columns:24px minmax(0,1fr) auto 44px}}@media(min-width:768px){.icon-grid{grid-template-columns:repeat(9,minmax(0,1fr))}.category-picker{grid-template-columns:repeat(5,minmax(0,1fr))}}
.budget-summary .metric.accent{grid-column:1/-1}.budget-summary .metric.accent strong{font-size:32px}.budget-summary .metric:not(.accent) strong{font-size:22px}@media(min-width:768px){.budget-summary{grid-template-columns:repeat(3,minmax(0,1fr))}.budget-summary .metric.accent{grid-column:auto}}
progress::-webkit-progress-bar{background:var(--line);border-radius:6px}progress::-webkit-progress-value{background:var(--teal);border-radius:6px}progress{border:0;border-radius:6px;appearance:none}

/* Accounting phase and device-local adaptive launcher choices. */
.book-phase{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 14px;border-radius:12px;background:#edf4ef;border:1px solid #d8e5dc;margin-bottom:12px;font-size:13px}.book-phase.trial{background:#fff7e7;border-color:#ecdcb8}.book-phase span{min-width:0}.book-phase b{display:block;font-size:13px}.book-phase small{display:block;color:var(--muted);font-size:11px;margin-top:3px}.book-phase select{width:112px;min-width:112px;height:44px;font-size:12px;padding:6px}.launcher-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.launcher-options button{display:flex;flex-direction:column;align-items:center;gap:8px;padding:12px 6px;font-size:12px}.launcher-options img{width:64px;height:64px;border-radius:17px}.launcher-options .selected{border:2px solid var(--teal);background:var(--green)}

/* Fast row actions keep a 44px tap area without oversized glyphs. */
.row{grid-template-columns:24px minmax(0,1fr) max-content 44px 44px;gap:3px;align-items:center}.row .row-main{width:100%;display:block;text-align:left;min-width:0;padding:0;border:0;background:none;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;font-size:13px}.row .row-main small{display:inline;font-size:10px}.row .row-action{height:44px;width:44px;min-width:44px;padding:11px;border:0;background:none;display:grid;place-items:center}.row .row-action .glyph{width:18px;height:18px;stroke:currentColor}.row .amount{font-size:13px;white-space:nowrap}.row .row-action:disabled{opacity:.3}
.budget-category .head{display:grid;grid-template-columns:minmax(0,1fr) minmax(80px,max-content) minmax(75px,max-content);gap:6px;align-items:center}.budget-category [data-budget-detail]{min-width:0;text-align:left;padding:0;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.budget-amount{padding:4px 7px;min-height:44px;text-align:right;font-size:13px;background:var(--bg);border:1px solid var(--line)}.budget-amount small{display:block;font-size:10px}.budget-amount .glyph{width:12px;height:12px;margin-left:4px}.budget-category .remaining{font-size:16px;text-align:right;white-space:nowrap}.budget-category .remaining:before{content:'剩余';display:block;font-size:10px;font-weight:400;color:var(--muted)}
.icon-tools{display:grid;grid-template-columns:minmax(0,1fr) 125px;gap:8px;margin:10px 0}.icon-tools input,.icon-tools select{min-width:0;font-size:12px}.icon-chooser .icon-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(64px,1fr));gap:5px;max-height:330px;overflow-y:auto}.icon-grid button{min-height:60px;padding:6px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px}.icon-grid button[hidden]{display:none}.icon-grid small{font-size:10px;line-height:1.2}.icon-grid .glyph{width:24px;height:24px}#nav .glyph{stroke:currentColor;width:23px;height:23px}#quickBudgetError:empty{display:none}
@media(min-width:768px){.row .row-main,.row .amount{font-size:14px}.row .row-main small{font-size:11px}}

/* One original plan amount, now an inline edit target. */
.budget-category .head{grid-template-columns:minmax(0,1fr) minmax(75px,max-content)}
.budget-meta{display:flex;align-items:center;flex-wrap:wrap;gap:0 3px}
.budget-amount{display:inline-flex;align-items:center;justify-content:flex-start;vertical-align:middle;font:inherit;font-weight:600;min-height:44px;padding:0 3px;border:0;border-radius:4px;background:transparent;color:var(--muted);text-decoration:underline;text-decoration-style:dotted;text-underline-offset:4px}
.budget-amount:hover,.budget-amount:focus-visible{color:var(--teal);background:var(--green)}
.budget-amount:disabled{opacity:1;cursor:default;text-decoration:none}
.header-tools{display:flex;gap:4px}.header-tools button{border:0;background:transparent;width:44px;padding:8px;font-size:22px}
#uiStatus{max-width:960px;margin:0 auto;padding:4px 16px;display:flex;gap:8px;align-items:center;justify-content:space-between;font-size:11px;color:var(--teal)}
#uiStatus[hidden],#applyUi[hidden]{display:none}#uiStatus button{font-size:12px;padding:5px 10px;flex:none}body{overscroll-behavior-y:contain}

/* Compact common context; each page keeps its own primary task. */
header{padding:10px 16px 2px}header small{font-size:10px}h1{font-size:19px;margin:3px 0}#syncStatus{min-height:18px;font-size:10px}
#contextBar{max-width:1000px;margin:auto;padding:0 16px 3px;display:flex;align-items:center;gap:5px;min-width:0}
#contextBar[hidden],#rangeBadge[hidden],#customDates[hidden],#anchorDate[hidden]{display:none}
#contextBar button{min-height:44px;max-width:100%;padding:4px 8px;border:0;border-radius:8px;background:transparent;font-size:11px;color:var(--muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
#contextBar #phaseBadge{color:var(--teal);flex:none}#phaseBadge[data-phase=trial]{color:#99692f}#rangeBadge{margin-left:auto;text-align:right}
.range-presets{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px}.range-presets button{font-size:12px;padding:5px}.sheet-save{margin-top:20px;width:100%}
.date-chip{font-size:10px;color:var(--muted);border:0;padding:4px 0;background:transparent;min-height:44px;white-space:normal;text-align:right;line-height:1.5}
.card .actions:has(#statRange){display:grid;grid-template-columns:auto minmax(0,1fr);gap:6px}.card .actions #statRange{margin-left:0;justify-self:end}
.budget-footer{display:flex;justify-content:flex-end;gap:8px;flex-wrap:wrap;padding-top:12px}.budget-footer button{background:transparent;font-size:12px;padding:5px 10px;border-color:var(--line)}
.page-heading{display:flex;align-items:center;gap:8px;margin:0 0 12px}.page-heading h2{margin:0;font-size:17px}.back-button{width:44px;min-width:44px;padding:9px;border:0;background:transparent}.back-button .glyph{transform:rotate(180deg);margin:0}
.profile-row{display:flex;align-items:center;gap:12px;width:100%;padding:14px 4px 20px;border:0;background:transparent;text-align:left}.avatar{display:grid;place-items:center;width:46px;height:46px;border-radius:15px;background:var(--green);color:var(--teal);font-size:22px}.profile-row b{display:block;font-size:17px}.profile-row small{display:block;font-size:11px;margin-top:5px}.chevron{margin-left:auto!important;width:16px;height:16px;opacity:.55}
.settings-menu{padding:4px 14px;margin-bottom:12px}.settings-menu h3{font-size:10px;font-weight:500;color:var(--muted);margin:12px 0 3px}
.settings-row{display:flex;align-items:center;gap:12px;width:100%;min-height:64px;padding:10px 0;text-align:left;white-space:normal;border:0;border-bottom:1px solid var(--line);border-radius:0;background:transparent}.settings-row:last-child{border-bottom:0}.settings-row>.glyph:first-child{width:21px;height:21px;margin:0;color:var(--teal)}.settings-row b{display:block;font-size:14px;font-weight:550}.settings-row small{display:block;font-size:10px;line-height:1.5;margin-top:4px}.setting-toggle{width:100%;text-align:left;font-size:13px}
/* Refresh feedback is fixed in view while sync/download is working. */
#refreshFeedback{position:fixed;z-index:40;top:calc(8px + env(safe-area-inset-top));left:12px;right:12px;max-width:750px;margin:auto;display:flex;align-items:center;gap:10px;min-height:58px;padding:12px 14px 15px;border:1px solid var(--line);border-radius:14px;background:white;color:var(--ink);box-shadow:0 5px 24px #18364b25;font-size:12px;overflow:hidden}
#refreshFeedback[hidden]{display:none}#refreshFeedback .refresh-symbol{width:22px;height:22px;flex:none}#refreshFeedback .refresh-symbol .glyph{width:22px;height:22px;margin:0;stroke:currentColor}#refreshFeedback span{line-height:1.45;flex:1}#refreshFeedback button{font-size:12px;padding:4px 10px;flex:none}#refreshFeedback button[hidden]{display:none}
#refreshFeedback i{position:absolute;bottom:0;left:0;width:100%;height:3px;background:var(--teal)}
#refreshFeedback[data-stage=busy] .glyph,#refreshFeedback[data-stage=checking] .glyph,#refreshFeedback[data-stage=downloading] .glyph,#refreshFeedback[data-stage=applying] .glyph,.refreshing{animation:refresh-spin 1.1s linear infinite}
#refreshFeedback[aria-busy=true] i{width:35%;animation:refresh-line 1.2s ease-in-out infinite}#refreshFeedback[data-stage=failed]{color:var(--red)}#refreshFeedback[data-stage=failed] i{background:var(--red)}
#refreshFeedback[data-stage=pull]{position:relative;top:auto;left:auto;right:auto;margin:6px 16px;box-shadow:none;min-height:44px;padding:7px 12px}#refreshFeedback[data-stage=pull] i{display:none}
#uiStatus{font-size:11px}#uiStatus>span{display:none}#uiStatus:has(button[hidden]){display:none}
@keyframes refresh-spin{to{transform:rotate(360deg)}}@keyframes refresh-line{0%{transform:translateX(-100%)}100%{transform:translateX(390%)}}
@media(prefers-reduced-motion:reduce){#refreshFeedback .glyph,#refreshFeedback i,.refreshing{animation:none!important}}
@media(min-width:768px){.settings-menu,.profile-row,.page-heading{max-width:700px;margin-left:auto;margin-right:auto}#contextBar{padding-bottom:0}#rangeForm{gap:16px}}

#refreshFeedback[data-stage=ready],#refreshFeedback[data-stage=blocked]{position:relative;top:auto;left:auto;right:auto;margin:6px auto;box-shadow:none;width:calc(100% - 32px)}#refreshDismiss{font-size:11px!important;background:transparent;border:0;color:var(--muted);min-width:44px;padding:4px!important}

/* v2.6.1: explicit touch affordances and a shorter daily form. */
button:focus-visible,summary:focus-visible,select:focus-visible{outline:2px solid var(--teal);outline-offset:2px}
#contextBar{gap:8px;padding-top:3px;padding-bottom:5px}
#contextBar button,.date-chip{display:inline-flex;align-items:center;justify-content:center;gap:7px;border:1px solid var(--line);background:white;border-radius:10px;padding:6px 10px;color:var(--ink);min-height:44px;font-size:11px;box-shadow:0 1px 2px #18364b05}
#contextBar button::after,.date-chip::after,.entry-form .choice-button::after{content:'';display:block;flex:none;width:5px;height:5px;border-right:1.5px solid currentColor;border-bottom:1.5px solid currentColor;transform:rotate(45deg);margin:0 2px 3px;opacity:.65}
#contextBar #phaseBadge{background:var(--green);border-color:var(--line)}#contextBar #phaseBadge[data-phase=trial]{background:#fff7e7;border-color:#ebd9b3;color:#8b622a}
#contextBar button:hover,.date-chip:hover{border-color:var(--teal)}#rangeBadge{overflow:hidden}#statRange{white-space:nowrap;font-size:10px}
.entry-card{padding:14px}.entry-form{gap:9px 10px}.entry-top{display:flex;align-items:center;justify-content:space-between;gap:8px;min-width:0}.entry-top .segments{margin:0;flex:1;max-width:280px;padding:3px}.entry-top .segments button{font-size:12px;padding:4px 10px;min-height:44px}
.entry-form .reverse-choice{flex:none;font-size:11px;gap:0;white-space:nowrap;color:var(--muted)}.reverse-choice input[type=checkbox]{width:16px;height:16px;min-height:16px;margin-right:5px;accent-color:var(--teal)}
.entry-form>label:not(.amount-field):not(.memo-field){font-size:10px}.entry-form label>select,.entry-form label>input,.entry-form .choice-button{margin-top:4px;font-size:13px;padding:8px;min-height:44px;height:44px;border-radius:9px}.entry-form .choice-button{gap:5px;white-space:nowrap;overflow:hidden}.entry-form .choice-button .glyph{width:18px;height:18px;margin:0}.entry-form .choice-button::after{margin-left:auto}.entry-form .sr-control{height:1px!important}
.entry-form .amount-field{position:relative;display:flex;align-items:center;margin:0;background:var(--bg);border:1px solid var(--line);border-radius:10px;padding:0 11px;gap:8px}.amount-field>span{font-size:18px;color:var(--muted)}.entry-form .amount-field>input{background:transparent;margin:0;padding:8px 0;min-height:52px;height:52px;font-size:26px;font-weight:650;border:0;outline-offset:0}.amount-field input::-webkit-inner-spin-button{-webkit-appearance:none}
.entry-form .memo-field{display:grid;grid-template-columns:28px minmax(0,1fr);align-items:center;gap:7px;font-size:11px}.entry-form .memo-field textarea{margin:0;min-height:44px;height:44px;padding:11px 9px;resize:vertical;font-size:12px;line-height:20px;border-radius:9px}.entry-submit{display:flex;align-items:center;justify-content:flex-end;gap:8px}.entry-submit button{font-size:12px;padding:7px 14px}.entry-submit .quiet{margin-right:auto;padding:7px 0;border:0;background:transparent;color:var(--muted);font-size:11px}.entry-note{margin:8px 0 0;font-size:10px;line-height:1.5}.edit-indicator{font-size:10px;color:var(--teal)}
.budget-overview{padding:14px}.budget-overview h2{font-size:16px;margin-bottom:8px}.budget-overview .segments{margin-bottom:8px}.budget-overview .segments button{font-size:12px;min-height:44px;padding:5px 9px}.budget-overview>.note{font-size:10px;margin:7px 0 10px;line-height:1.5}.budget-overview .budget-summary{grid-template-columns:repeat(3,minmax(0,1fr));gap:9px}.budget-overview .budget-summary .metric.accent{grid-column:auto}.budget-overview .budget-summary .metric small{font-size:10px;margin-bottom:4px}.budget-overview .budget-summary .metric strong{font-size:21px;white-space:nowrap}.budget-overview .budget-summary .metric.accent strong{font-size:23px}.budget-overview .pace{padding-top:9px;gap:4px 10px;font-size:10px}.budget-overview .pace span{background:transparent;padding:2px 0}.budget-help>summary{font-size:10px;font-weight:400;color:var(--muted);min-height:44px}.budget-help>summary::after{content:'⌄';margin-left:auto}.budget-help[open]>summary{margin-bottom:0}.budget-help p{margin:0 0 4px}
.analytics{padding:14px}.analysis-tabs{display:flex;border-bottom:1px solid var(--line);gap:14px;margin:0 0 10px}.analysis-tabs button{position:relative;flex:1;padding:6px 0;border:0;border-radius:0;background:transparent;font-size:13px;color:var(--muted);min-height:44px}.analysis-tabs button.active{color:var(--teal);background:transparent;border:0;font-weight:650}.analysis-tabs button.active::after{content:'';position:absolute;bottom:-1px;height:3px;left:15%;right:15%;background:var(--teal);border-radius:2px}
.analysis-filters{display:grid;grid-template-columns:28px minmax(0,1fr) minmax(0,1fr);align-items:center;gap:7px}.analysis-filters>span{font-size:10px;color:var(--muted)}.analysis-filters select{height:44px;min-height:44px;padding:7px;font-size:11px;background:var(--bg);border-radius:8px}.analysis-filters select:disabled{opacity:.5;cursor:default}
.chart-heading{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-top:12px}.chart-heading h3{font-size:14px;margin:0}.view-switch{display:flex;gap:0;padding:2px;border:1px solid var(--line);border-radius:9px;background:var(--bg)}.view-switch button{font-size:10px;min-height:44px;min-width:44px;padding:5px 9px;border:0;background:transparent;border-radius:6px;color:var(--muted)}.view-switch button.active{background:white;color:var(--teal);box-shadow:0 1px 4px #18364b18;font-weight:600}.chart-caption{font-size:10px;line-height:1.6;color:var(--muted);margin:7px 0 10px}.analytics .rank-title{font-size:12px;margin-top:16px}.goal summary .right{display:inline-flex;align-items:center;border:1px solid var(--line);padding:6px 10px;min-height:36px;border-radius:8px;color:var(--teal);background:#ffffff99;font-size:10px}.goal summary .right::after{content:'⌄';margin-left:5px}.goal details[open] summary .right::after{transform:rotate(180deg)}
@media(max-width:380px){.budget-overview .budget-summary .metric strong{font-size:18px}.budget-overview .budget-summary .metric.accent strong{font-size:20px}.entry-top .segments button{padding:4px 7px}.entry-form .reverse-choice{font-size:10px}.analysis-tabs{gap:9px}.view-switch button{padding:5px 6px}.chart-heading h3{font-size:13px}}
/* Keep full annual amounts separated on narrow screens. */
.budget-overview .budget-summary .metric strong{font-size:clamp(14px,4.1vw,21px)}.budget-overview .budget-summary .metric.accent strong{font-size:clamp(15px,4.4vw,23px)}
/* The budget overview is one compact strip, with rules behind the help button. */
.budget-top{display:flex;align-items:center;gap:8px;margin-bottom:10px}.budget-top .segments{flex:1;margin:0}.budget-top .icon-help{width:44px;height:44px;min-width:44px;padding:0;border-radius:50%;font-size:13px;color:var(--muted);background:transparent}.budget-overview .pace{padding-top:6px}.budget-overview{padding:12px 14px}.budget-overview .pace span{font-size:9px}.budget-overview .budget-summary{gap:8px}

/* v2.7.1 · daily ledger first, page-local filters, calm status feedback. */
main{transform:translateY(var(--pull-offset,0px));transition:transform .26s ease;will-change:auto}
main.pull-dragging{transition:none;will-change:transform}
main.pull-released{transition:transform .3s ease}
#refreshFeedback[data-stage=pull]{position:relative;max-width:968px;margin:5px auto;background:var(--green);border-color:var(--line);font-size:12px}
#refreshFeedback[data-stage=pull] .refresh-symbol{transform:rotate(calc(var(--pull-progress,0)*180deg));transition:none}
#contextBar{padding-top:0;padding-bottom:0}#contextBar #rangeBadge{display:none}
#contextBar #phaseBadge{min-height:44px;font-size:11px;padding:4px 10px;background:transparent;border:0;box-shadow:none}
#contextBar #phaseBadge::before{content:'';width:6px;height:6px;border-radius:50%;background:currentColor}
main:has(.month-hero){padding-top:5px}
.month-hero{background:var(--green);border-color:var(--line);padding:12px 16px 16px}
.month-heading{display:flex;align-items:center;justify-content:space-between;gap:8px;color:var(--muted);font-size:11px;margin-bottom:6px}
.month-heading .date-chip{padding:2px 8px;min-height:44px;font-size:11px;background:#ffffff99;border-color:transparent;white-space:nowrap}
.month-heading .date-chip::after{display:none}.month-heading .glyph{width:14px;height:14px;margin:0}
.month-secondary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.month-secondary small{display:block;font-size:11px;color:var(--muted);margin-bottom:6px}
.month-secondary strong{font-size:clamp(15px,4.3vw,21px);font-weight:600;white-space:nowrap;letter-spacing:-.3px}
.month-expense{padding-top:20px}.month-expense>small{color:var(--muted);font-size:12px;display:block;margin-bottom:4px}.month-expense small span{font-size:10px;margin-left:4px}
.month-expense>strong{font-size:clamp(34px,9vw,44px);font-weight:650;letter-spacing:-1px;color:var(--teal);line-height:1.2;font-variant-numeric:tabular-nums}
.restricted-note,.record-note{display:block;font-size:10px;color:var(--muted);margin-top:9px}
.new-entry{display:flex;align-items:center;justify-content:center;width:100%;gap:9px;min-height:50px;font-size:15px;margin:0 0 14px;border-radius:12px}
.new-entry .glyph{width:22px;height:22px;stroke:currentColor;margin:0}
.ledger{padding:12px 16px}.ledger>.actions:first-child{margin-bottom:2px}.ledger h3{font-size:14px}.ledger #toggleLedgerFilter{border:0;background:transparent;font-size:11px;padding:4px 8px}
.ledger .day-head{padding-top:12px}.ledger .actions:last-child{margin-bottom:0;margin-top:8px}.ledger #csv,.ledger #excel{font-size:10px;padding:4px 8px;background:transparent;border:0;color:var(--muted)}
.section-toolbar{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:6px}.section-toolbar h2{font-size:15px;margin:0}.section-toolbar .date-chip{font-size:10px;padding:3px 8px;white-space:nowrap}
.icon-more{display:inline-flex;align-items:center;justify-content:center;flex:none;width:44px;height:44px;min-width:44px;border:0;padding:10px;background:transparent;border-radius:9px;color:var(--muted)}
.icon-more .glyph{width:19px;height:19px;stroke:currentColor;margin:0}
.budget-top .segments{min-width:0}.budget-top .icon-more{margin-left:auto}.budget-top{gap:4px}
.budget-overview{padding:10px 14px}.budget-overview .budget-top{margin-bottom:7px}.budget-overview .budget-top .segments button{font-size:11px;padding:4px 6px}
.budget-category{display:grid;grid-template-columns:minmax(86px,1fr) minmax(90px,max-content) minmax(76px,max-content);align-items:center;column-gap:6px;padding:4px 0;position:relative;min-height:64px}
.budget-category .head{display:contents}.budget-category [data-budget-detail]{grid-column:1;grid-row:1;min-height:44px;border:0;border-radius:0;background:transparent;box-shadow:none;padding:0;white-space:nowrap;font-size:12px}
.budget-category [data-budget-detail] .glyph{width:20px;height:20px;margin-right:6px}
.budget-category .budget-meta{grid-column:2;grid-row:1;display:block;font-size:9px;line-height:1.1;white-space:nowrap;text-align:right;color:var(--muted)}
.budget-category .budget-meta>span{display:block}.budget-category .budget-amount{font-size:10px;padding:0 2px;min-height:44px}
.budget-category .remaining{grid-column:3;grid-row:1;font-size:17px;font-weight:750;white-space:nowrap;color:var(--teal);align-self:center}
.budget-category .remaining.negative{color:var(--red)}.budget-category .remaining::before{font-size:9px;margin-bottom:4px}.budget-category progress{grid-column:1/-1;height:2px;margin:2px 0 0;opacity:.6}
.budget-footer{padding-top:6px}.budget-footer button{font-size:11px}
.composer-heading{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:8px}.composer-heading h2{font-size:15px;margin:0}
dialog:has(#entry){padding:16px;max-width:580px}dialog:has(#entry) .entry-card{padding:0;margin:0}dialog:has(#entry) #closeModal{display:none}dialog:has(#entry) form{margin-bottom:8px}
.statistics-time{padding:10px 14px 12px}.stat-period-tabs{display:flex;gap:4px;border-bottom:1px solid var(--line);padding-bottom:6px}.stat-period-tabs button{flex:1;border:0;background:transparent;font-size:13px;padding:5px 8px;color:var(--muted)}
.stat-period-tabs button.active{background:var(--teal);color:white;border-radius:9px}
.stat-time-tools{display:grid;grid-template-columns:44px minmax(0,1fr) 44px minmax(85px,110px);gap:2px;align-items:center;margin-top:6px}.stat-time-tools .date-chip{min-width:0;font-size:11px;padding:5px;border:0;background:transparent;text-align:center;white-space:normal;box-shadow:none}
.stat-time-tools select{font-size:11px;padding:6px;height:44px;background:var(--bg);border:0}.stat-time-tools .previous-arrow{transform:rotate(180deg)}
.stat-shortcuts{display:flex;gap:5px;align-items:center;overflow:auto;margin-bottom:8px}.stat-shortcuts button{flex:none;border:0;font-size:10px;padding:4px 9px;background:transparent;color:var(--muted)}.stat-shortcuts button.selected{outline:0;background:var(--green);color:var(--teal);font-weight:600}
.stat-summary{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px 20px;padding:15px;background:var(--green);border-radius:11px}.stat-summary small{display:block;font-size:10px;color:var(--muted);margin-bottom:4px}.stat-summary strong{display:block;font-size:23px;font-weight:650;font-variant-numeric:tabular-nums}.stat-summary>div:first-child strong{color:var(--teal)}
.stat-summary-note{display:flex;justify-content:space-between;flex-wrap:wrap;gap:6px;font-size:9px;color:var(--muted);margin-top:9px}.stat-summary-note b{font-weight:500}
@media(max-width:600px){dialog:has(#entry){margin:auto 0 0;width:100%;max-width:none;max-height:94dvh;border-radius:20px 20px 0 0;padding:12px 16px max(16px,env(safe-area-inset-bottom));border-bottom:0}.composer-heading{margin-bottom:5px}}
@media(min-width:768px){.month-hero{padding:16px 24px 20px}.month-secondary strong{font-size:24px}.month-expense>strong{font-size:42px}.stat-summary{grid-template-columns:repeat(4,minmax(0,1fr))}.stat-time-tools{grid-template-columns:44px minmax(160px,1fr) 44px 140px}.budget-category{grid-template-columns:1fr 220px 160px}.budget-category .budget-meta{display:flex;justify-content:flex-end;align-items:center;gap:10px}.budget-category .budget-meta>span{display:inline}.budget-category [data-budget-detail]{font-size:13px}}
@media(prefers-reduced-motion:reduce){main{transition:none!important}.pull-dragging,#refreshFeedback[data-stage=pull] .refresh-symbol{transition:none!important}}
/* v2.7.2: hidden notices must stay collapsed across mobile WebView styles. */
#refreshFeedback[hidden],#toast[hidden],#updateState[hidden],#syncStatus[hidden],#applyUiPage[hidden]{display:none!important}
#refreshFeedback #applyUi{font-size:11px;padding:5px 9px}
/* v2.7.2 · a quiet shared toolbar, compact page controls and stable pull overlay. */
#topbar{max-width:1000px;margin:0 auto;padding:4px 16px;display:flex;align-items:center;justify-content:flex-end;min-height:52px}
#topbar[hidden]{display:none}#topbar #contextBar{margin:0 auto 0 0;padding:0;flex:1;min-width:0}
#topbar .header-tools{flex:none;margin-left:auto;gap:0}#topbar .header-tools button{display:grid;place-items:center;width:44px;height:44px;min-height:44px;padding:11px;color:var(--teal)}
#topbar .header-tools .glyph{width:21px;height:21px;margin:0;stroke:currentColor}
#topbar #phaseBadge{display:inline-flex;align-items:center;gap:6px;font-size:12px;font-weight:550;padding:4px 8px 4px 0;background:transparent;min-width:0}
#topbar #phaseBadge::after{content:'⌄';font-size:13px;opacity:.65;margin-left:3px}
#pullIndicator{position:fixed;z-index:35;top:8px;left:50%;transform:translate(-50%,min(var(--pull-offset,0px),54px));pointer-events:none;display:flex;align-items:center;gap:7px;background:var(--green);color:var(--teal);border:1px solid var(--line);border-radius:30px;padding:7px 14px;font-size:11px;box-shadow:0 2px 12px #18364b12;white-space:nowrap}
#pullIndicator[hidden]{display:none}#pullIndicator .pull-symbol{display:block;font-size:20px;line-height:1;transform:rotate(calc(var(--pull-progress,0)*270deg));transition:color .15s}#pullIndicator.armed{background:var(--teal);color:white}
main{overflow:clip;overflow-clip-margin:4px}.month-hero{padding:7px 14px 12px}.month-heading{margin-bottom:2px;font-size:10px}.month-heading .date-chip,.section-toolbar .date-chip{border:0;background:transparent;box-shadow:none;color:var(--muted);font-size:10px;padding:3px 0 3px 8px;display:inline-flex;align-items:center;gap:4px;min-height:44px}
.month-heading .date-chip:hover,.section-toolbar .date-chip:hover,.stat-time-header .date-chip:hover{background:var(--green)}.month-heading .date-chip .glyph{width:12px;height:12px;margin:0;opacity:.65}
.section-toolbar .date-chip::after{content:'⌄';font-size:12px;opacity:.65;margin-left:4px}
.month-secondary small{font-size:10px;margin-bottom:4px}.month-secondary strong{font-size:clamp(15px,4.2vw,20px)}.month-expense{padding-top:12px}.month-expense>small{font-size:11px;margin-bottom:1px}.month-expense>strong{font-size:clamp(30px,8.4vw,38px)}.record-note,.restricted-note{margin-top:5px;font-size:9px}
.ledger #ledgerFilter .filter-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:5px;margin:4px 0 8px}.ledger #ledgerFilter select{min-width:0;height:44px;min-height:44px;padding:6px;font-size:10px;background:var(--bg);border:0;border-radius:7px}
.ledger .row-main{line-height:44px;height:44px;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.ledger .row-main small{white-space:nowrap;line-height:inherit}
.budget-top{display:flex;justify-content:space-between;gap:4px}.budget-top .segments{display:inline-flex;flex:0 1 auto;min-width:0;gap:2px;margin:0;padding:3px}.budget-top .segments button{flex:none;min-width:0;padding:4px 9px;font-size:11px;white-space:nowrap}.budget-top .icon-more{margin-left:auto;padding:12px;width:44px;min-width:44px}.budget-top .icon-more .glyph{width:17px;height:17px}
.budget-overview .budget-summary{grid-template-columns:repeat(3,minmax(0,1fr));gap:6px}.budget-overview .budget-summary .metric.accent{grid-column:auto}.budget-overview .budget-summary .metric small{font-size:9px;margin-bottom:5px}.budget-overview .pace{padding-top:7px;gap:4px 10px}.budget-overview .pace span{padding:2px 0;background:transparent;border-radius:0;font-size:9px}
.stat-time-header{display:flex;align-items:center;justify-content:space-between;gap:4px}.stat-time-header .stat-period-tabs{flex:1;min-width:0;padding:0;border:0;gap:0}.stat-time-header .stat-period-tabs button{min-width:0;flex:1;font-size:12px;padding:5px 6px;white-space:nowrap}.stat-time-header .date-chip{display:flex;align-items:center;justify-content:flex-end;gap:2px;flex:none;font-size:10px;white-space:nowrap;padding:4px 0 4px 5px;border:0;background:transparent;box-shadow:none}.stat-time-header .date-chip .glyph{width:12px;height:12px;margin:0;opacity:.65}
.stat-shortcuts{margin:4px -4px 8px;gap:1px;scrollbar-width:none;overscroll-behavior-x:contain}.stat-shortcuts::-webkit-scrollbar{display:none}.stat-shortcuts button{min-height:44px;padding:4px 10px;font-size:11px;border-radius:0;position:relative}.stat-shortcuts button.selected{background:transparent;color:var(--teal);outline:none}.stat-shortcuts button.selected::after{content:'';position:absolute;width:0;height:0;border-left:4px solid transparent;border-right:4px solid transparent;border-bottom:4px solid var(--teal);bottom:3px;left:calc(50% - 4px)}.stat-shortcuts .icon-more{min-width:32px;width:32px;padding:8px}.stat-shortcuts .previous-arrow{transform:rotate(180deg)}
.custom-span{display:block;color:var(--muted);font-size:11px;margin:4px 0 10px;text-align:center;font-variant-numeric:tabular-nums}
.analysis-tabs{display:flex;align-items:center;gap:12px}.analysis-tabs>[data-statkind]{font-size:12px;white-space:nowrap;flex:none;padding:6px 0}.analysis-tabs #statFilterToggle{margin-left:auto;min-width:44px;width:44px;padding:12px;border-bottom:0;color:var(--muted)}.analysis-tabs #statFilterToggle .glyph{width:17px;height:17px;margin:0;stroke:currentColor}
.analysis-filters{grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;margin-top:7px}.analysis-filters[hidden]{display:none!important}.analysis-filters select{width:100%;font-size:11px}
.app-identity{background:var(--green);padding:16px}.app-identity small{font-size:10px}.app-identity h1{margin:5px 0;font-size:23px}.app-identity h1 span{font-size:12px;font-weight:400;color:var(--muted)}.app-identity .note{font-size:10px;margin:5px 0 0}.error-detail{color:var(--red)}
@media(min-width:768px){.month-hero{padding:8px 22px 14px}.month-expense>strong{font-size:38px}.month-secondary strong{font-size:23px}.stat-time-header .date-chip{font-size:12px}.stat-time-header .stat-period-tabs{flex:none;gap:5px}.stat-time-header .stat-period-tabs button{padding:5px 18px}.budget-top .segments button{padding:4px 15px}}
@media(max-width:380px){.stat-time-header .stat-period-tabs button{font-size:11px;padding:5px}.stat-time-header .date-chip{font-size:9px}.analysis-tabs{gap:11px}.analysis-tabs>[data-statkind]{font-size:11px}.budget-top .segments button{font-size:10px;padding:4px 8px}}
@media(prefers-reduced-motion:reduce){#pullIndicator .pull-symbol{transition:none}}
#topbar #phaseBadge::after,.section-toolbar .date-chip::after{display:inline-block;width:auto;height:auto;border:0;transform:none;margin:0 0 0 3px;line-height:1}
.stat-time-header .date-chip::after{display:none}
.retirement-toolbar{display:flex;align-items:center;gap:3px;margin-bottom:12px}.retirement-toolbar .segments{flex:1;margin:0;min-width:0;gap:0;padding:3px}.retirement-toolbar .segments button{min-width:0;font-size:11px;padding:5px 6px;white-space:nowrap}.retirement-full{width:100%;font-size:12px;background:transparent;color:var(--teal);border-color:var(--line)}.retirement-callout{padding:12px;margin:14px 0;background:var(--green);border-radius:10px}.retirement-callout>small{font-size:10px}.retirement-callout>strong{display:block;font-size:22px;margin-top:6px}.retirement-callout p{margin:6px 0 0}.retirement-rules p{font-size:12px;line-height:1.8;padding-bottom:10px;border-bottom:1px solid var(--line);color:var(--muted)}.retirement-path{margin-top:10px}
@media(max-width:380px){.retirement-toolbar .segments button{font-size:10px;padding:4px}}
/* v2.7.3 · one useful first row on every page, neutral ledger switch. */
#topbar{min-height:52px;gap:8px;padding:4px 16px}
#topbar .page-lead{display:flex;align-items:center;flex:1;gap:6px;min-width:0}
#topbar #contextBar{flex:none;margin:0;padding:0;min-width:0}
#topbar #pageTitle{font-size:17px;font-weight:650;line-height:1.3;margin:0;white-space:nowrap;flex:none}
#pageTitle[hidden],#budgetRange[hidden],#pageBack[hidden]{display:none!important}
#topbar #contextBar #phaseBadge,#topbar #contextBar #phaseBadge[data-phase=trial]{display:inline-flex;align-items:center;gap:7px;background:transparent;border:0;color:var(--ink);box-shadow:none;padding:0;min-height:44px;font-size:13px}
#topbar #phaseBadge::before,#topbar #phaseBadge::after{display:none}
#topbar #phaseBadge>.glyph:first-child{width:20px;height:20px;margin:0;stroke:var(--teal)}
#topbar #phaseBadge>.glyph:last-child{width:12px;height:12px;margin:0;stroke:var(--muted);opacity:.7}
#topbar #pageBack{display:grid;place-items:center;width:36px;min-width:36px;height:44px;padding:8px;margin-left:-8px;background:transparent;border:0}
#topbar #pageBack .glyph{width:21px;height:21px;margin:0;stroke:var(--teal);transform:rotate(180deg)}
#topbar #budgetRange{display:flex;align-items:center;justify-content:flex-end;gap:3px;margin-left:auto;min-width:0;max-width:210px;padding:4px 0;font-size:10px;color:var(--muted);background:transparent;border:0;box-shadow:none}
#topbar #budgetRange>span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
#topbar #budgetRange .glyph{width:12px;height:12px;margin:0;stroke:currentColor;flex:none}
#topbar #budgetRange::after{display:none}
#topbar .header-tools{margin-left:0;gap:0}#topbar .header-tools button{padding:12px}#topbar .header-tools .glyph{width:20px;height:20px}
main,main:has(.month-hero){padding-top:6px}
.profile-card{padding:14px 16px 6px;background:linear-gradient(110deg,var(--green),#fff);margin-bottom:12px}
.profile-account{display:flex;align-items:center;gap:11px;padding:0;width:100%;min-height:54px;border:0;border-radius:0;background:transparent;text-align:left}
.profile-account .avatar{width:42px;height:42px;border-radius:13px;flex:none;background:#ffffffb3;color:var(--teal);font-size:21px}
.profile-name{min-width:0;flex:1}.profile-name b{display:block;font-size:19px;line-height:1.3}.profile-name small{display:block;font-size:10px;margin-top:5px}
.profile-account .chevron{width:17px;height:17px;margin:0!important;stroke:var(--muted)}
.profile-app{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-top:12px;padding-bottom:9px;border-bottom:1px solid var(--line)}
.profile-app>span:first-child{min-width:0;display:flex;align-items:center;gap:7px}.profile-app b{font-size:12px;font-weight:600;white-space:nowrap}.profile-app small{font-size:9px;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.app-version{font-size:10px;color:var(--muted);flex:none}
.profile-sync{display:flex;align-items:center;gap:6px;min-height:38px;width:100%;padding:7px 0;border:0;background:transparent;text-align:left;color:var(--muted);font-size:10px}
.profile-sync span{flex:1;min-width:0;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.profile-sync .glyph{width:13px;height:13px;margin:0;stroke:currentColor}.profile-sync .glyph:last-child{width:11px;height:11px}
.profile-card .error-detail{font-size:10px;margin:0 0 8px}#app:has(>.profile-card)>.settings-menu{max-width:none}
@media(min-width:768px){#topbar #budgetRange{font-size:11px;max-width:300px;margin-right:12px}.profile-card{padding:16px 20px 8px}.profile-app small{font-size:11px}}
@media(max-width:380px){#topbar{gap:4px}#topbar #pageTitle{font-size:16px}#topbar #budgetRange{font-size:9px}#topbar .header-tools button{width:40px;min-width:40px;padding:11px}.profile-app small{font-size:9px}}

/* v2.7.4: equal primary tabs; compact columns retain both plan and remainder. */
.budget-overview .budget-top{display:grid;grid-template-columns:minmax(0,1fr) 44px;gap:2px;margin-bottom:6px}
.budget-overview .budget-top .segments{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));width:100%;padding:2px;gap:2px;max-width:none}
.budget-overview .budget-top .segments button{width:100%;min-height:44px;font-size:12px;padding:4px 0;text-align:center}
.budget-overview .budget-top .icon-more{width:44px;min-width:44px;padding:12px;margin:0;background:transparent;border:0}
.budget-list{padding-top:12px}.budget-list h3{margin:0 0 5px}
.budget-columns,.budget-list .budget-category{display:grid;grid-template-columns:minmax(0,1fr) minmax(74px,.68fr) minmax(80px,.72fr);column-gap:8px}
.budget-columns{font-size:10px;color:var(--muted);padding:0 0 3px;align-items:center}.budget-columns span:not(:first-child){text-align:right}
.budget-list .budget-category{min-height:50px;padding:2px 0 4px;align-items:center}
.budget-list [data-budget-detail]{grid-column:1;grid-row:1;display:flex;align-items:center;gap:6px;min-height:44px;font-size:12px;line-height:1.3;overflow:hidden}
.budget-list [data-budget-detail] .glyph{width:18px;height:18px;flex:none;margin:0}
.budget-list .category-name>span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.budget-list .category-name b{font-size:12px;font-weight:550;display:block;overflow:hidden;text-overflow:ellipsis}.budget-list .category-name small{display:block;font-size:9px;color:var(--muted);margin-top:2px;font-weight:400}
.budget-list .plan-cell{grid-column:2;grid-row:1;justify-content:flex-end;width:100%;min-height:44px;font-size:12px;color:var(--ink);padding:0;white-space:nowrap}
.budget-list .remaining{grid-column:3;grid-row:1;font-size:16px;line-height:1.2;text-align:right}.budget-list .remaining::before{display:none}
.budget-list progress{grid-column:1/-1;height:2px;margin:0;opacity:.45}
.amount-field #toggleCalculator{flex:none;min-width:44px;min-height:44px;border:0;background:transparent;padding:11px;color:var(--teal)}
.amount-field #toggleCalculator .glyph{width:22px;height:22px;margin:0}
.entry-form .amount-field>input{min-width:0;width:100%;font-variant-numeric:tabular-nums}
.amount-calculator{padding:8px;background:var(--bg);border:1px solid var(--line);border-radius:10px}
.calc-top{display:flex;justify-content:space-between;align-items:center;gap:6px}.calc-top output{font-size:13px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.calc-top button{min-height:44px;padding:3px 10px;border:0;background:transparent;font-size:11px}
.calc-keys{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:4px}.calc-keys button{min-height:44px;padding:4px;font-size:21px;border-color:var(--line);background:var(--card)}.calc-keys button:nth-child(4n){color:var(--teal);background:var(--green)}
.calc-actions{display:flex;align-items:center;gap:6px;margin-top:4px}.calc-actions small{flex:1;font-size:9px;color:var(--muted);line-height:1.4}.calc-actions button{min-height:44px;font-size:11px;padding:6px 10px}
.profile-card #profileDetails>summary{min-height:44px;list-style:none;cursor:pointer}.profile-card #profileDetails>summary::-webkit-details-marker{display:none}.profile-card #profileDetails[open]>summary>.glyph:last-child{transform:rotate(180deg)}
#profileDetailBody>.card{margin:0;padding:12px 0;border:0;border-top:1px solid var(--line);border-radius:0;background:transparent;box-shadow:none}
#profileDetailBody h2{font-size:13px}#profileDetailBody h3{font-size:12px}#profileDetailBody .actions{gap:5px}#profileDetailBody .actions button{font-size:11px;padding:6px 10px;min-height:44px}
[data-settings-page=updates] .actions{gap:6px}[data-settings-page=updates] .actions button{font-size:12px;min-height:44px;padding:7px 11px}
@media(min-width:768px){.budget-overview .budget-top .segments button{font-size:14px}.budget-columns,.budget-list .budget-category{grid-template-columns:minmax(0,1fr) 180px 180px}}
@media(max-width:380px){.budget-overview .budget-top .segments button{font-size:11px}.budget-columns,.budget-list .budget-category{column-gap:5px}.budget-list .remaining{font-size:15px}.budget-list .plan-cell{font-size:11px}}

/* v2.7.6: three independent tabs share the summary's full-width column grid. */
.budget-overview .budget-top{display:block;position:relative;margin-bottom:8px}
.budget-overview .budget-top .segments{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;padding:0;background:transparent;overflow:visible}
.budget-overview .budget-top .segments button{width:100%;min-height:44px;padding:6px 0;border:0;border-radius:10px;background:#e8f0f4;font-size:12px;font-weight:500}
.budget-overview .budget-top .segments button.active{background:var(--ink);color:white;font-weight:650}
.budget-overview .budget-top .segments button:last-child{padding-right:20px}
.budget-overview .budget-top .icon-more{position:absolute;top:0;right:-20px;width:44px;min-width:44px;height:44px;margin:0;padding:15px;border:0;background:transparent;display:grid;place-items:center;color:var(--muted)}
.budget-overview .budget-top .icon-more .glyph{width:14px;height:14px;margin:0;stroke:currentColor;stroke-width:2}
html[data-theme=mint] .budget-overview .budget-top .segments button:not(.active){background:#e9f3ee}
@media(min-width:768px){.budget-overview .budget-top .segments button{font-size:14px}}
.budget-overview .budget-summary{grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}

/* v2.7.7: category actions live with the heading; one progress separator per row. */
.budget-list-heading{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:2px}
.budget-list-heading h3{font-size:14px;line-height:1.3;margin:0}
.budget-list-heading #quickAddCategory{min-height:44px;padding:6px 0 6px 8px;border:0;background:transparent;color:var(--teal);font-size:11px;flex:none}
.budget-list .budget-category{min-height:48px;padding:0 0 2px;border:0}
.budget-list .budget-amount,.budget-list .budget-amount:disabled{text-decoration:none;border:0;box-shadow:none}
.budget-list .category-name{touch-action:pan-y;-webkit-touch-callout:none;user-select:none}
.budget-list .category-name.is-pressing{background:var(--green);border-radius:6px}
.stat-time-header{gap:6px}
.stat-time-header .stat-period-tabs{flex:1;display:flex;gap:3px;padding:3px;border:1px solid var(--line);border-radius:11px;background:var(--bg)}
.stat-time-header .stat-period-tabs button{min-height:44px;min-width:0;flex:1;padding:5px 6px;border:0;border-radius:8px;background:transparent;color:var(--ink);font-size:12px;font-weight:600}
.stat-time-header .stat-period-tabs button:last-child{flex:1.5}
.stat-time-header .stat-period-tabs button.active{background:var(--teal);color:#fff;font-weight:700}
.stat-shortcuts{margin-top:5px}.stat-shortcuts button{font-size:10px;font-weight:400;color:var(--muted)}
@media(min-width:768px){.stat-time-header .stat-period-tabs button{font-size:14px}.budget-list-heading h3{font-size:15px}}
@media(max-width:380px){.stat-time-header .stat-period-tabs button{font-size:11px;padding:5px 4px}}

/* v2.8 shared planning surfaces: compact tools, deliberate detail pages. */
.feature-tools{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:6px 0}.feature-tools button{min-height:44px;padding:6px 10px;font-size:12px}.feature-tools button span{font-variant-numeric:tabular-nums;font-size:11px;opacity:.8}.feature-tools svg{width:16px;height:16px}.feature-tools .right{margin-left:auto}
.plan-row,.bill-row{display:flex;align-items:center;gap:8px;padding:6px 0;border-bottom:1px solid var(--line)}.plan-row>button:first-child,.bill-row>div:first-child{flex:1;min-width:0;text-align:left}.plan-row small,.bill-row small,.plan-manage small{display:block;font-size:11px;color:var(--muted);font-weight:400}.plan-row button,.bill-row button{min-height:44px;font-size:12px;padding:6px 8px}.bill-row{flex-wrap:wrap}.bill-row>.feature-tools{flex-basis:100%;justify-content:flex-end;margin:0}.plan-manage{width:100%;text-align:left;margin:3px 0;min-height:44px}.bill-context{padding:5px 8px;background:var(--green);border-radius:8px}.bill-context button{font-size:11px;min-height:44px;padding:4px 8px}
.budget-planning-tools{border-top:0;justify-content:flex-end;margin-bottom:0}.budget-planning-tools button{border:0;background:transparent;color:var(--teal);font-size:11px}.report-switch{margin:0 0 8px}.report-switch .segments{width:100%}.report-switch .segments button{flex:1}.month-report .head{align-items:center;gap:8px}.month-report .head input{width:145px;min-height:44px;font-size:12px}.report-metrics{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;margin:8px 0 14px}.report-metrics>button,.report-metrics>div{padding:10px;text-align:left;background:var(--bg);border:0;border-radius:10px;min-width:0}.report-metrics small{display:block;color:var(--muted);font-size:11px}.report-metrics strong{font-size:17px;display:block;font-variant-numeric:tabular-nums}.report-line{display:flex;justify-content:space-between;align-items:center;gap:8px;min-height:44px;width:100%;padding:6px 0;border:0;border-radius:0;background:transparent;text-align:left;font-size:12px}.report-line>span{min-width:0}.report-line>strong{white-space:nowrap;font-variant-numeric:tabular-nums}.review-steps{padding-left:20px;font-size:12px;color:var(--muted)}.review-steps li{min-height:32px}.review-steps button{min-height:44px;padding:4px 8px;font-size:11px}
.trajectory-table{font-size:11px;overflow:hidden}.trajectory-table>div{display:grid;grid-template-columns:60px repeat(2,minmax(0,1fr)) minmax(0,1.4fr);gap:5px;align-items:center;min-height:44px}.trajectory-table small{display:block;color:var(--muted);font-size:10px}.trajectory-table .money{text-align:right;overflow-wrap:anywhere}.sync-stages{display:grid;gap:4px;color:var(--muted);font-size:11px;margin-top:8px}.activation-checks{font-size:12px}
@media(min-width:768px){.report-metrics{grid-template-columns:repeat(4,minmax(0,1fr))}.report-metrics strong{font-size:20px}.trajectory-table{font-size:12px}.bill-row>.feature-tools{flex-basis:auto;margin-left:auto}}
.feature-heading{display:flex;align-items:center;justify-content:space-between;gap:8px}.feature-heading h3{margin:0;flex:1}.feature-heading button{min-height:44px;padding:6px 8px;font-size:12px}.month-report .feature-heading input{width:145px;min-height:44px;font-size:12px}.goal .summary[role=button]{cursor:pointer}.goal .summary[role=button]:focus-visible{outline:2px solid var(--teal);outline-offset:4px}

/* One action per item keeps icons and labels aligned. */
.picker-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}.picker-heading h2{margin:0}.picker-heading .icon-more{flex:0 0 44px}.picker-heading .glyph{margin:0}
.category-picker.subitem-picker>button{height:88px;justify-content:center;gap:8px;padding:8px 4px}.subitem-picker>button .glyph{width:24px;height:24px}.subitem-picker>button span{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden;line-height:1.4;text-align:center;max-width:100%;overflow-wrap:anywhere}
/* The keypad belongs to the viewport bottom, above the Android system bar. */
#amountCalculator:not([hidden]){position:fixed;left:50%;bottom:0;transform:translateX(-50%);width:min(100%,580px);z-index:60;margin:0;padding:10px 12px max(10px,env(safe-area-inset-bottom));border-radius:16px 16px 0 0;box-shadow:0 -6px 24px #18364b1a}
dialog.calculator-open:has(#entry){margin-top:12px;margin-bottom:calc(var(--calculator-height,310px) + 8px);max-height:calc(100dvh - var(--calculator-height,310px) - 24px)}
#entryItemError:empty{display:none}

.category-year{display:flex;align-items:center;gap:12px;font-size:12px;color:var(--muted)}.category-year select{margin:0;min-width:120px;font-size:13px}.editor-page .segments{display:flex}.editor-page .segments button{flex:1}

.row.transaction-income .amount,.row.transaction-refund .amount{color:var(--money-income)}.row.transaction-expense .amount,.row.transaction-income_reversal .amount{color:var(--money-expense)}.transaction-type{font-size:10px;font-weight:600;margin-left:4px}.transaction-income .transaction-type,.transaction-refund .transaction-type{color:var(--money-income)}.transaction-expense .transaction-type,.transaction-income_reversal .transaction-type{color:var(--money-expense)}

/* Money roles stay consistent across skins and do not recolor chosen category icons. */
:root,:root[data-theme=mint]{--money-income:#007D86;--money-expense:#007D86;--money-remaining:#8A4B08;--money-surplus:#8A4B08;--money-warning:#8A4B08;--red:var(--money-warning)}
.money-income{color:var(--money-income)!important}
.money-expense{color:var(--money-expense)!important}
.money-remaining{color:var(--money-remaining)!important}
.money-surplus{color:var(--money-surplus)!important}
:is(.money-income,.money-expense,.money-remaining,.money-surplus).negative,.money-warning{color:var(--money-warning)!important}
.inline-children{padding:12px;background:var(--bg);border-radius:12px;margin:4px 0 12px}.inline-children h3{font-size:12px;margin:0 0 10px}.inline-children .category-picker{margin-bottom:8px}.inline-children .category-picker button{background:white}.inline-children>button{width:100%;font-size:12px}
.calendar-grid{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:4px;margin:12px 0 18px}.calendar-grid>small{text-align:center;font-size:11px;padding:4px 0}.calendar-grid>button{width:100%;min-width:0;min-height:52px;padding:5px 1px;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:5px;border-color:transparent;border-radius:8px;background:var(--bg)}.calendar-grid>button b{font-size:12px;font-weight:600}.calendar-grid>button .money{max-width:100%;font-size:11px;line-height:1.3;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.calendar-grid>button.selected{background:var(--green);outline-width:1px}.calendar-totals{display:flex;flex-wrap:wrap;gap:8px 14px;margin:8px 0 12px;font-size:11px}.calendar-totals span{white-space:nowrap}.calendar-totals b{font-weight:650}.calendar-grid~#calendarDayDetail h3{font-size:13px}

/* v2.9.3: clear labels and quiet, actionable low-budget reminders. */
.budget-list .category-name b{font-size:14px;font-weight:750;line-height:1.35;color:var(--ink)}
.budget-list .remaining.budget-alert{display:flex;align-items:center;justify-content:flex-end;gap:4px;min-height:44px;padding:0;border:0;background:transparent;box-shadow:none;font:inherit;font-size:17px;font-weight:750;color:var(--money-remaining,#8A4B08)}
.budget-list .remaining.budget-alert::before{display:none}
.budget-alert i{display:inline-flex;align-items:center;justify-content:center;flex:0 0 14px;width:14px;height:14px;border:1px solid currentColor;border-radius:50%;font-size:10px;font-weight:750;font-style:normal}
@media(max-width:380px){.budget-list .remaining.budget-alert{font-size:15px}.budget-list .category-name b{font-size:13px}}
@media(prefers-reduced-motion:no-preference){dialog[open]{animation:sheet-in .16s cubic-bezier(.2,.8,.2,1)}button{transition:background-color .12s ease,color .12s ease}button:active{filter:brightness(.97)}@keyframes sheet-in{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}}
