:root{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,sans-serif;color:#17281d;background:#f8f4ec;font-synthesis:none;--green:#1e5638;--sage:#e8edde;--orange:#ee7c24;--paper:#fbf7f0;--muted:#718073;--line:#e7e5dc}*{box-sizing:border-box}body{margin:0}button,input,select,textarea{font:inherit}button{cursor:pointer}button:disabled{cursor:not-allowed;opacity:.55}button:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible{outline:3px solid #e8a84a;outline-offset:2px}h1,h2,h3,p{margin-top:0}h1{font-size:1.2rem}h2{font-size:1rem}p{line-height:1.55;color:#5e6c60}small{color:#718073}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.welcome,.auth-page{max-width:440px;min-height:100dvh;margin:auto;display:flex;flex-direction:column;align-items:center;justify-content:center;padding:24px}.welcome{text-align:center}.mark,.auth-mark{width:72px;height:72px;display:grid;place-items:center;border-radius:22px;background:var(--green);color:#fff;font-size:38px;font-weight:700}.welcome h1{font-size:30px;margin-bottom:0}.notice{width:100%;margin-top:35px;padding:20px;border-radius:16px;background:var(--sage);text-align:left}.auth-brand{text-align:center}.auth-mark{margin:auto}.auth-brand h1{font-size:1.9rem;margin:.65rem 0 .2rem}.auth-card{width:100%;background:#fffdf8;border:1px solid var(--line);border-radius:20px;padding:24px;box-shadow:0 8px 24px #4056430d}.auth-card h2{font-size:1.25rem}label{display:block;font-size:.88rem;color:#3b5041}label input:not([type=radio]):not([type=checkbox]),label select,label textarea{display:block;width:100%;border:1px solid #d9e0d4;border-radius:10px;background:#fffdfa;color:#1a2b1e;padding:10px 12px;margin:.35rem 0 1rem;min-height:44px}.primary-button,.secondary-button,.danger-button{border-radius:11px;min-height:44px;padding:10px 15px;font-weight:600}.primary-button{border:0;background:var(--orange);color:#fff}.secondary-button{border:1px solid #6c9272;background:#f4f8ec;color:var(--green)}.danger-button{border:1px solid #d56d48;background:#fff7f0;color:#ad492b}.auth-card .primary-button,.ledger-picker .primary-button,.ledger-picker .secondary-button{width:100%}.auth-links{display:flex;justify-content:space-between;margin-top:16px}.auth-links button{border:0;background:transparent;color:var(--green)}.auth-error,.error-banner{color:#a43c28;font-size:.9rem}.auth-notice{color:var(--green);font-size:.9rem}.app-page,.page{height:100dvh;max-width:560px;margin:auto;background:var(--paper);display:flex;flex-direction:column;overflow:hidden}.page{min-height:100dvh;height:auto;overflow:visible}.page-scroll,.editor-scroll{overflow-y:auto;overscroll-behavior:contain;flex:1;min-height:0;padding:0 16px 24px}.page-header{position:relative;display:flex;align-items:center;justify-content:center;min-height:62px;padding:12px 16px;background:var(--green);color:#fff}.page-header h1{margin:0}.icon-button{position:absolute;left:15px;border:0;background:transparent;color:inherit;font-size:2rem;line-height:1}.panel{background:#fffdf8;border:1px solid var(--line);border-radius:15px;padding:16px;margin:12px 0}.panel h2{margin-bottom:10px}.empty{text-align:center;color:#7a897d;padding:18px 8px}.error-banner{padding:10px 14px;background:#fff1eb;border-radius:10px}.home-header{height:62px;display:flex;align-items:center;gap:8px;padding:0 18px}.ledger-switch,.sync-button{border:0;background:transparent;color:var(--green)}.ledger-switch{font-size:1.15rem;font-weight:700;padding:4px 0}.sync-button{font-size:1.5rem}.summary-card{position:relative;background:linear-gradient(125deg,#215d3a,#184c31);border-radius:16px;color:#fff;padding:16px 18px;margin-bottom:12px;overflow:hidden}.summary-main{display:flex;align-items:baseline;gap:14px}.summary-main span,.summary-small{font-size:.86rem}.summary-main strong{font-size:1.38rem}.summary-small{display:flex;gap:18px;margin-top:10px}.summary-decoration{position:absolute;right:18px;top:4px;font-size:4rem;color:#e6a15c;opacity:.6}.calendar-card,.recent-entries{background:#fffdf8;border:1px solid var(--line);border-radius:16px;padding:10px;margin-bottom:12px}.month-switch{display:flex;justify-content:center;align-items:center;gap:32px;height:36px;font-size:.9rem}.month-switch button{border:0;background:transparent;color:var(--green);font-size:1.5rem}.calendar-grid{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:2px;text-align:center}.weekday{font-size:.78rem;color:var(--green);padding:5px}.calendar-day{min-width:0;min-height:47px;border:0;border-radius:9px;background:transparent;display:flex;flex-direction:column;align-items:center;justify-content:center;color:#203025;font-size:.88rem}.calendar-day small{font-size:clamp(.52rem,2vw,.65rem);white-space:nowrap;color:#536455}.calendar-day.selected{background:var(--green);color:#fff}.calendar-day.selected small{color:#fff}.entry-row,.detail-row{width:100%;display:flex;align-items:center;gap:10px;border:0;border-bottom:1px solid #f0eee8;background:transparent;text-align:left;padding:10px 3px;color:inherit}.entry-icon{width:39px;height:39px;flex:none;display:grid;place-items:center;border-radius:12px;background:#edf2e3;color:var(--green);font-size:1.2rem}.entry-description{flex:1;min-width:0;display:flex;flex-direction:column;gap:3px}.entry-description strong{font-size:.92rem}.entry-description small{font-size:.75rem}.entry-amount{color:#191d19;white-space:nowrap;font-size:.95rem}.view-all{display:block;border:0;background:transparent;color:var(--green);margin:10px auto 0}.bottom-nav{flex:none;display:flex;justify-content:space-around;align-items:center;height:74px;padding-bottom:env(safe-area-inset-bottom);background:#fffdf8;border-top:1px solid var(--line)}.bottom-nav button{min-width:68px;border:0;background:transparent;color:var(--green);display:flex;flex-direction:column;align-items:center;gap:1px;font-size:.77rem}.bottom-nav button span{font-size:1.45rem;line-height:1}.bottom-nav .active{color:var(--orange);font-weight:700}.bottom-nav .add-button{width:54px;height:54px;min-width:54px;border-radius:50%;background:var(--orange);color:#fff;font-size:2rem;line-height:1;justify-content:center}.ledger-list{padding:12px 16px 0}.ledger-picker .panel{margin:12px 16px}.ledger-card,.member-row{display:flex;align-items:center;justify-content:space-between;gap:10px;background:#fffdf8;border:1px solid var(--line);border-radius:14px;padding:14px;margin-bottom:10px}.ledger-card p{margin:.25rem 0 0;font-size:.78rem}.ledger-card button,.member-row button,.invite-box button{border:1px solid #b8cfb8;background:#f2f7eb;color:var(--green);border-radius:9px;padding:8px 10px}.ledger-actions{display:flex;gap:6px}.member-row{border:0;border-radius:0;border-bottom:1px solid var(--line);margin:0;padding:10px 0;justify-content:flex-start}.member-row>span:nth-child(2){flex:1;display:flex;flex-direction:column}.member-avatar{background:#dce9d6;border-radius:50%;width:36px;height:36px;display:grid;place-items:center}.manager-page .page-scroll{padding-top:4px}.manager-page>.danger-button{margin:12px}.invite-box textarea{font-size:.75rem;resize:none;min-height:80px}.editor-header{position:relative;min-height:62px;display:flex;justify-content:center;align-items:center;background:var(--green);color:#fff}.ledger-select select{color:#fff!important;font-weight:700;background:transparent!important;border:0!important;text-align:center;margin:0!important;padding:8px 24px!important}.editor-scroll{padding-top:4px}.entry-tabs,.period-tabs{display:flex;justify-content:space-around;border-bottom:1px solid var(--line);margin-bottom:10px}.entry-tabs button,.period-tabs button{position:relative;flex:1;padding:10px;border:0;background:transparent;font-size:1rem;color:#4b5b4d}.entry-tabs button[aria-selected=true],.period-tabs button[aria-selected=true]{font-weight:700;color:var(--green)}.entry-tabs button[aria-selected=true]:after,.period-tabs button[aria-selected=true]:after{content:"";position:absolute;bottom:0;left:35%;right:35%;height:3px;background:var(--green);border-radius:2px}.entry-preview{display:flex;align-items:center;gap:10px;border:1px solid var(--line);border-radius:12px;background:#fffdf8;padding:10px;margin-bottom:12px}.entry-preview>span:nth-child(2){display:flex;flex:1;flex-direction:column;gap:4px}.category-section{position:relative}.category-section h2,.tag-section h2{font-size:.9rem;margin:10px 0 8px}.category-scroller{height:228px;overflow-y:auto;scroll-snap-type:y mandatory}.category-section.short .category-scroller{height:53px}.category-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));grid-template-rows:repeat(4,53px);gap:5px;min-height:228px;scroll-snap-align:start}.short .category-grid{grid-template-rows:53px;min-height:53px}.category-grid button,.category-add{border:1px solid transparent;border-radius:9px;background:var(--sage);color:var(--green);display:flex;align-items:center;justify-content:center;flex-direction:column;min-width:0}.category-grid button[aria-pressed=true]{border-color:var(--green);background:#fff1d7}.category-grid button span{font-size:1.1rem;line-height:1}.category-grid button small{font-size:clamp(.57rem,2.4vw,.7rem);color:#28392b;line-height:1.1;margin-top:2px;overflow:hidden;text-overflow:ellipsis;max-width:100%;white-space:nowrap}.category-add{position:absolute;bottom:0;right:0;width:calc((100% - 20px)/5);height:53px;font-size:.72rem}.tag-section h2 small{font-weight:400}.tag-list{display:flex;gap:6px;overflow-x:auto}.tag-list button{white-space:nowrap;border:1px solid #d7ded0;background:transparent;border-radius:20px;padding:6px 11px;color:#405244;font-size:.78rem}.tag-list button[aria-pressed=true]{background:#c8dabd;border-color:#c8dabd}.inline-add{display:flex;align-items:center;gap:5px}.inline-add label{flex:1}.inline-add button{border:0;background:var(--sage);padding:8px}.compact-field{display:flex;align-items:center;gap:12px;border:1px solid var(--line);border-radius:9px;padding:0 10px;margin-top:7px;background:#fffdf8}.compact-field input{margin:0!important;border:0!important;padding:7px!important;min-height:34px!important}.expression-field{display:flex;align-items:center;gap:10px;margin-top:10px}.expression-field input{margin:0!important;text-align:right}.calculator{display:grid;grid-template-columns:repeat(5,1fr);gap:5px;margin-top:8px}.calculator button{min-height:42px;border:1px solid #e4e6dc;background:#fffdf8;border-radius:8px;color:#25372b;font-size:1.1rem}.calculator .calc-operator{background:var(--sage);color:var(--green)}.calculator .calc-save{background:var(--orange);border:0;color:#fff;font-weight:700}.details-controls{display:flex;align-items:center;justify-content:space-between;gap:8px}.details-controls label{display:flex;align-items:center;gap:6px}.details-controls input{margin:0!important;min-height:36px!important;padding:5px!important}.details-controls button{border:0;border-radius:15px;background:var(--sage);padding:9px;color:var(--green)}.details-totals{display:flex;justify-content:space-between;gap:4px;font-size:clamp(.7rem,3vw,.85rem);padding:16px 0}.detail-divider{display:flex;justify-content:space-between;gap:6px;background:#f6f3eb;border-radius:6px;color:#5b695d;font-size:.72rem;padding:7px}.detail-note{font-weight:400;color:#5b695d}.floating-add{position:absolute;align-self:flex-end;bottom:calc(20px + env(safe-area-inset-bottom));margin-right:16px;background:var(--orange);color:#fff;border:0;border-radius:25px;padding:12px 18px;box-shadow:0 4px 14px #b15d2433}.details-page{position:relative}.sheet-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;background:#10291d80;display:flex;justify-content:center;align-items:flex-end;z-index:10}.filter-sheet,.confirm-dialog{background:var(--paper);border-radius:20px 20px 0 0;padding:20px;width:min(100%,560px);max-height:85dvh;overflow:auto}.confirm-dialog{border-radius:18px;margin:16px;align-self:center}.confirm-dialog button{display:block;width:100%;margin:8px 0;padding:10px}.filter-sheet fieldset{border:0;padding:6px 0;display:flex;gap:10px;flex-wrap:wrap}.filter-sheet legend{font-weight:700;font-size:.9rem}.filter-sheet label,.filter-options label{display:inline-flex;gap:4px;align-items:center;padding:6px}.sheet-actions{display:flex;gap:8px;margin-top:14px}.sheet-actions button{flex:1;padding:9px}.conflict-columns{display:grid;grid-template-columns:1fr 1fr;gap:8px}.conflict-snapshot{background:#f2f5e9;border-radius:10px;padding:8px;min-width:0}.conflict-snapshot h3{font-size:.9rem}.conflict-snapshot dl{margin:0;font-size:.78rem}.conflict-snapshot dt{color:#6a7b6d}.conflict-snapshot dd{margin:0 0 6px;overflow-wrap:anywhere}.report-month input{margin:8px 0!important}.report-summary{background:var(--sage);border-radius:14px;padding:15px;display:flex;flex-direction:column;gap:6px}.report-summary strong{font-size:1.4rem}.report-chart{display:flex;align-items:center;gap:16px}.donut{width:130px;height:130px;flex:none;border-radius:50%;display:grid;place-items:center}.donut div{width:72px;height:72px;border-radius:50%;display:grid;place-items:center;background:#fffdf8;font-size:.8rem}.chart-legend{flex:1}.chart-legend p{display:flex;align-items:center;gap:6px;font-size:.77rem;margin:6px 0}.chart-legend p span{width:9px;height:9px;border-radius:50%}.chart-legend strong{margin-left:auto}.report-row{display:flex;gap:10px;align-items:center;padding:8px 0;border-bottom:1px solid var(--line)}.report-row strong{margin-left:auto}.profile-hero{display:flex;align-items:center;gap:14px;padding:22px 8px}.profile-hero h2,.profile-hero p{margin:0}.profile-hero p{font-size:.78rem}.profile-avatar{width:64px;height:64px;display:grid;place-items:center;border-radius:50%;background:#dce9d6;font-size:2rem;overflow:hidden}.profile-avatar img{width:100%;height:100%;object-fit:cover}.settings-list{background:#fffdf8;border:1px solid var(--line);border-radius:14px;padding:0 14px}.settings-list>button,.settings-list>div{display:flex;align-items:center;justify-content:space-between;width:100%;min-height:51px;border:0;border-bottom:1px solid var(--line);background:transparent;text-align:left;color:#263a2c}.settings-list>div span{color:#718073;font-size:.85rem}.settings-list .signout{color:#b45235}.settings-list>p{font-size:.8rem;margin:6px}.avatar-options{display:flex;gap:8px}.confirm-dialog .avatar-options button{width:52px;font-size:1.6rem}.editor-delete{width:100%;margin-top:12px}.ledger-picker>.error-banner{margin:10px 16px}.compact-field>span,.expression-field>span{flex:0 0 2.4em;white-space:nowrap}.compact-field>input,.expression-field>input{flex:1;min-width:0}.editor-page .editor-scroll{scroll-padding-bottom:18px}
