:root{--bg:#f4f5f2;--surface:#fff;--line:#dce3df;--line-soft:#edf1ee;--ink:#1c2825;--muted:#54635e;--primary:#1f5f5b;--primary-dark:#16413e;--soft:#e6f0ed;--income:#176b4b;--expense:#a54b09;--radius:12px}
*{box-sizing:border-box} [hidden]{display:none!important} html{background:var(--bg)} body{margin:0;font:15px/1.5 "Segoe UI",system-ui,-apple-system,sans-serif;color:var(--ink);background:var(--bg)} button,input,select,textarea{font:inherit} button{cursor:pointer} a{color:var(--primary)} h1,h2,h3{line-height:1.25;text-wrap:balance}h1{font-size:clamp(25px,2vw,30px);margin:0 0 8px;letter-spacing:-.02em}h2{font-size:17px;margin:0 0 14px}h3{font-size:15px;margin:24px 0 10px}p{line-height:1.55}small,.muted{color:var(--muted)}
header{display:flex;align-items:center;gap:10px;background:#fff;border-bottom:1px solid var(--line);min-height:76px;padding:16px 24px}header .brand-mark{display:grid;place-items:center;width:37px;height:37px;flex:none;color:#fff;background:var(--primary);border-radius:9px;font-size:24px;line-height:1}header .brand-text{display:flex;flex-direction:column;line-height:1.25}header .brand-text strong{font-size:15px}header .brand-text small{font-size:12px}#who{font-size:12px;color:var(--muted);margin-left:auto}#menuToggle{display:none}
main{max-width:1120px;margin:auto;padding:28px}section{background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);padding:24px;margin:0 0 20px}.card{background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);padding:20px}.grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(190px,1fr));gap:16px}.number{font-size:clamp(21px,2vw,27px);font-weight:700;line-height:1.2;font-variant-numeric:tabular-nums;overflow-wrap:anywhere}.scroll{overflow-x:auto;-webkit-overflow-scrolling:touch}table{border-collapse:collapse;width:100%;font-size:14px}th,td{text-align:left;padding:12px;border-bottom:1px solid var(--line-soft);vertical-align:top}th{color:var(--muted);font-size:12px;font-weight:650;white-space:nowrap}td{min-width:100px}td:last-child{white-space:nowrap}button{border:1px solid transparent;border-radius:8px;background:var(--primary);color:white;min-height:42px;padding:9px 16px;font-weight:600;transition:background-color .15s ease}button:hover{background:var(--primary-dark)}button:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible,summary:focus-visible,a:focus-visible{outline:3px solid #3f8f81;outline-offset:2px}button:disabled{opacity:.65;cursor:wait}button.secondary{background:#fff;border-color:#cbd6d0;color:var(--ink)}button.secondary:hover{background:#f1f6f3}label{display:block;font-size:14px;font-weight:600;color:#344b43;margin:15px 0 6px}input:not([type=checkbox]),select,textarea{width:100%;min-height:44px;padding:10px 12px;border:1px solid #b6c4bd;border-radius:8px;background:#fff;color:var(--ink)}input[type=checkbox]{width:18px;height:18px;vertical-align:middle;accent-color:var(--primary)}input::placeholder,textarea::placeholder{color:#687c72}form{max-width:650px}form p{margin:18px 0}#msg:empty,[role=status]:empty{display:none}#msg:not(:empty),#worshipMsg:not(:empty){background:#edf6f0;border-left:3px solid var(--primary);padding:12px 14px;border-radius:6px;color:#16483b}#login{max-width:450px;margin:9vh auto;padding:32px}#login h1{margin-bottom:8px}#login>p{color:var(--muted)}
body:has(#app:not([hidden])) header{position:fixed;z-index:3;left:0;top:0;width:240px;height:82px;border-bottom:0;border-right:1px solid var(--line);padding:20px}body:has(#app:not([hidden])) header #who{position:fixed;left:20px;bottom:17px;max-width:195px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;margin:0;background:#f3f7f4;border-radius:8px;padding:9px 12px;width:200px}body:has(#app:not([hidden])) main{margin-left:240px;max-width:none;padding:32px clamp(20px,3vw,42px);min-height:100vh}#app>nav{position:fixed;z-index:2;left:0;top:82px;bottom:0;width:240px;overflow:auto;background:#fff;border-right:1px solid var(--line);padding:2px 14px 85px;display:flex;flex-direction:column;gap:2px}#app>nav .nav-label{font-size:11px;letter-spacing:.06em;font-weight:700;color:#64736d;text-transform:uppercase;padding:15px 11px 5px}#app>nav button{display:flex;align-items:center;gap:11px;width:100%;text-align:left;background:transparent;color:#384c45;border:0;padding:9px 11px;min-height:40px;font-size:14px;font-weight:550}#app>nav button:hover{background:#eff5f1}#app>nav button.is-active{background:var(--primary);color:#fff}#app>nav button .nav-icon{width:20px;text-align:center;font-size:17px;line-height:1;flex:none}#app>nav #logout{margin-top:8px;color:#52655c}#app>nav #logout:hover{background:#f4efed}#app>section{max-width:1400px}#app>section>p:first-of-type{color:var(--muted)}
#home{background:transparent;border:0;padding:0}.dashboard-head{display:flex;justify-content:space-between;align-items:flex-end;gap:20px;margin-bottom:22px;flex-wrap:wrap}.dashboard-head .eyebrow{color:var(--muted);font-size:13px}.dashboard-head h1{margin:2px 0}.dashboard-actions{display:flex;gap:10px;flex-wrap:wrap}.dashboard-grid .card{min-height:116px}.dashboard-grid .card small{display:block;margin-bottom:10px}.dashboard-grid .hero{background:var(--primary);border-color:var(--primary);color:#fff}.dashboard-grid .hero small,.dashboard-grid .hero .stat-note{color:#dcece7}.stat-note{display:block;margin-top:9px;color:var(--muted);font-size:12px}.income{color:var(--income)}.expense{color:var(--expense)}.dashboard-columns{display:grid;grid-template-columns:minmax(260px,.8fr) minmax(300px,1.2fr);gap:16px;margin-top:18px}.dashboard-panel{background:#fff;border:1px solid var(--line);border-radius:var(--radius);padding:20px;min-width:0}.dashboard-panel header{position:static!important;width:auto!important;height:auto!important;padding:0!important;border:0!important;min-height:0;margin:0 0 12px;justify-content:space-between}.dashboard-panel header h2{margin:0}.dashboard-panel header button{min-height:30px;padding:4px 8px;font-size:12px}.balance-list p{margin:0;padding:9px 0;border-bottom:1px solid var(--line-soft);display:flex;align-items:flex-start;justify-content:space-between;gap:12px}.balance-list p:last-child{border:0}.balance-list p b{text-align:right;white-space:nowrap;font-variant-numeric:tabular-nums}.dashboard-recent{margin-top:16px}.dashboard-empty{color:var(--muted);padding:8px 0}.dashboard-link{font-size:13px;color:var(--primary)}
#worshipApp nav{display:flex;gap:6px;flex-wrap:wrap;margin:18px 0;border-bottom:1px solid var(--line);padding-bottom:8px}#worshipApp nav button{min-height:40px}#worshipApp .card{margin:12px 0}#budgetSummary,#reportsummary{background:var(--soft);color:var(--primary-dark);padding:12px 15px;border-radius:8px;margin:16px 0;font-weight:600}#budgetCategories,#budgetMonthly{margin:24px 0}#budgetRows td{min-width:125px}#budgetRows td:first-child{min-width:240px;white-space:normal}#budgetRows details{margin-top:8px;color:var(--muted);font-size:13px}#budgetRows details p{margin:4px 0}#userlist p,#masterlist p,#categories p{display:flex;gap:10px;align-items:center;flex-wrap:wrap;border-bottom:1px solid var(--line-soft);padding:8px 0;margin:0}#userlist select{width:auto;max-width:200px}#selectedMonthOptions{display:flex;gap:6px 14px;flex-wrap:wrap}#selectedMonthOptions label{margin:5px 0}summary{cursor:pointer;color:var(--primary);font-weight:600}
@media(max-width:860px){body:has(#app:not([hidden])) header{position:sticky;width:auto;height:auto;min-height:68px;border-right:0;border-bottom:1px solid var(--line);padding:12px 16px}body:has(#app:not([hidden])) header #who{position:static;width:auto;max-width:115px;background:none;padding:0;margin-left:auto;font-size:11px}body:has(#app:not([hidden])) main{margin:0;padding:20px 16px}body:has(#app:not([hidden])) #menuToggle{display:inline-flex;align-items:center;background:white;border:1px solid #b9c9c1;color:var(--ink);min-height:40px;padding:7px 12px}#app>nav{display:none;position:fixed;top:68px;bottom:0;left:0;width:min(300px,85vw);box-shadow:6px 0 18px #152b2620;padding-bottom:30px}body.menu-open #app>nav{display:flex}.dashboard-columns{grid-template-columns:1fr}.dashboard-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.dashboard-actions button{flex:1}section{padding:20px 16px}}
@media(max-width:420px){.dashboard-grid{gap:10px}.dashboard-grid .card{padding:15px;min-height:108px}.dashboard-actions{width:100%}.dashboard-actions button{font-size:13px;padding:9px}.dashboard-columns{gap:12px}header .brand-text small{display:none}}
@media print{header,#app>nav,.dashboard-actions,button,#reportform,#years,.screen-only{display:none!important}body:has(#app:not([hidden])) main{margin:0;padding:0}section{border:0;padding:0}body{background:#fff}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{transition:none!important;scroll-behavior:auto!important}}

header img.brand-mark{display:block;background:#fff;object-fit:contain;border-radius:0;width:44px;height:44px}
.xlsx-panel{margin:16px 0 24px;padding:18px;background:#f5f9f6;border:1px solid #dce8e1;border-radius:10px}.xlsx-panel h2{margin-bottom:8px}.xlsx-panel>p{color:#42574c;margin:8px 0}.xlsx-actions{display:flex;flex-wrap:wrap;gap:10px;margin:14px 0}.action-link{display:inline-flex;align-items:center;min-height:42px;padding:9px 14px;border:1px solid #aebfb5;border-radius:8px;background:#fff;color:#174f46;text-decoration:none;font-weight:600}.action-link:hover{background:#e6f0ed}.xlsx-result{margin:12px 0}.xlsx-result td:last-child{white-space:normal;min-width:220px}.xlsx-status:not(:empty){margin:12px 0;color:#194f43;font-weight:600}.xlsx-upload>input{max-width:600px}#maintenanceApp{margin-top:28px;border-top:1px solid #dce3df;padding-top:24px}
#dashboardInsights{margin-top:30px}.insights-heading{display:flex;justify-content:space-between;gap:18px;align-items:flex-end;flex-wrap:wrap;margin-bottom:18px}.insights-heading h2{font-size:22px;margin:3px 0}.insights-heading p{margin:4px 0;color:var(--muted)}.insights-heading .eyebrow{font-size:13px;color:var(--muted)}.insights-filter{display:flex;align-items:flex-end;gap:10px;flex-wrap:wrap}.insights-filter label{margin:0 0 5px}.insights-filter select{min-width:140px}.insights-filter input{width:110px}.insight-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:14px}.insight-card{background:#fff;border:1px solid var(--line);border-radius:12px;padding:18px}.insight-label{font-size:13px;color:var(--muted)}.insight-value{font-size:23px;font-weight:700;font-variant-numeric:tabular-nums;margin:8px 0}.insight-compare{font-size:13px;color:var(--primary-dark)}.insight-hint,.insight-note{font-size:12px;color:var(--muted)}.insight-hint{margin-top:7px}.insight-panel{margin-top:16px}.insight-panel>p{margin:5px 0 14px}.insight-panel th,.insight-panel td{white-space:nowrap}.insight-note{line-height:1.5}.insight-demo{display:inline-block;font-size:11px;background:#fff3d9;color:#754309;border-radius:5px;padding:2px 6px}.insight-card-heading{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap}.insight-card-heading h2{margin:0}.insight-card-heading button{min-height:34px;font-size:13px}.insight-card-heading+.scroll{margin-top:14px}#insightStatus:not(:empty){color:#385349}@media(max-width:600px){.insight-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.insight-card{padding:14px}.insight-value{font-size:19px;overflow-wrap:anywhere}.insights-filter{width:100%}.insights-filter div:first-child{flex:1}.insights-filter select{min-width:0}}
