/* Calm Finance shares Home's surface, typography and hit areas.
   Control roles below intentionally outrank the scoped native-button reset. */
#moplano-app #page[data-page="finance"] .finance-calm { display:grid; gap:12px; min-width:0; overflow-anchor:none; }
#moplano-app #page .finance-calm :where(button),#moplano-app .fo-detail :where(button) {
 appearance:none; -webkit-appearance:none; font:inherit; border:0; background:transparent; padding:0; margin:0;
 color:var(--ui-text,#252820); box-shadow:none; border-radius:0; touch-action:manipulation; -webkit-tap-highlight-color:transparent;
}
#moplano-app #page .fo-header { display:flex; align-items:center; justify-content:space-between; gap:12px; min-height:44px; margin:0; }
#moplano-app #page .fo-header h1 { margin:0; font-size:24px; line-height:1.25; letter-spacing:-.025em; font-weight:550; }
#moplano-app #page :is(.fo-add,.fo-eye) { display:grid; place-items:center; flex:none; width:44px; height:44px; min-height:44px; }
#moplano-app #page .fo-add svg { display:block; width:24px; height:24px; }
#moplano-app #page .fo-eye { color:var(--ui-muted,#777b70); }
#moplano-app #page .fo-card,#moplano-app .fo-detail-card {
 background:#fff; color:var(--ui-text,#252820); border:0; border-radius:var(--ui-radius,18px); padding:12px var(--ui-inset,16px);
 min-width:0; box-shadow:none; backdrop-filter:none; -webkit-backdrop-filter:none;
}
#moplano-app #page .fo-balance-top { display:flex; align-items:center; justify-content:space-between; gap:8px; color:var(--ui-muted,#777b70); font-size:12px; }
#moplano-app #page .fo-balance-value { display:block; color:var(--ui-text,#252820); font-size:clamp(27px,7.5vw,34px); line-height:1.2; font-weight:550; letter-spacing:-.035em; padding:0 0 7px; overflow-wrap:anywhere; font-variant-numeric:tabular-nums; }
#moplano-app #page .finance-calm .fo-link,#moplano-app .fo-detail .fo-link {
 display:inline-flex; gap:4px; align-items:center; justify-content:space-between; min-height:44px; text-align:left;
 font-size:12px; color:var(--ui-accent,#576f59); text-decoration:none; min-width:0;
}
#moplano-app :is(.finance-calm,.fo-detail) .fo-link svg { display:block; width:16px; height:16px; flex:0 0 16px; }
#moplano-app #page .fo-balance > .fo-link,#moplano-app #page .fo-period > .fo-link,#moplano-app #page .finance-calm > .fo-link { width:100%; }
#moplano-app #page .finance-calm > .fo-link { padding:0 3px; }
#moplano-app :is(.finance-calm,.fo-detail) .fo-section-head { display:flex; align-items:center; justify-content:space-between; gap:10px; min-height:40px; }
#moplano-app :is(.finance-calm,.fo-detail) .fo-section-head h2 { flex:1; min-width:0; margin:0; font-size:17px; line-height:1.35; font-weight:550; letter-spacing:-.02em; overflow-wrap:anywhere; }
#moplano-app #page .fo-totals { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; padding:8px 0 10px; }
#moplano-app #page .fo-totals span { display:block; font-size:12px; line-height:1.45; color:var(--ui-muted,#777b70); margin-bottom:4px; }
#moplano-app #page .fo-totals strong { font-size:clamp(14px,4.1vw,18px); line-height:1.4; letter-spacing:-.02em; font-weight:550; font-variant-numeric:tabular-nums; overflow-wrap:anywhere; }
#moplano-app #page .fo-totals .fo-income { color:var(--ui-accent,#576f59); }
#moplano-app :is(.finance-calm,.fo-detail) .fo-net { display:flex; align-items:baseline; justify-content:space-between; gap:12px; font-size:12px; line-height:1.5; color:var(--ui-muted,#777b70); padding:6px 0 9px; }
#moplano-app :is(.finance-calm,.fo-detail) .fo-net b { font-variant-numeric:tabular-nums; font-weight:500; text-align:right; color:var(--ui-text,#252820); overflow-wrap:anywhere; }
#moplano-app #page :is(.fo-budget,.fo-budget-unset) { border-top:1px solid var(--ui-line,#eeeee7); padding-top:7px; margin-top:5px; }
#moplano-app #page :is(.fo-budget > div:first-child,.fo-budget-unset) { display:flex; align-items:center; justify-content:space-between; gap:10px; font-size:12px; color:var(--ui-muted,#777b70); }
#moplano-app #page .fo-budget strong { color:var(--ui-text,#252820); font-weight:500; font-variant-numeric:tabular-nums; }
#moplano-app #page .fo-track { display:block; height:3px; border-radius:3px; overflow:hidden; margin-top:9px; background:var(--ui-line,#eeeee7); }
#moplano-app #page .fo-track > span { display:block; height:100%; background:var(--ui-accent,#576f59); opacity:.7; }
#moplano-app :is(.finance-calm,.fo-detail) :is(.fo-caption,.fo-empty,.fo-date,.fo-detail-period,.fo-currency-notice) { margin:0; font-size:12px; line-height:1.5; color:var(--ui-muted,#777b70); }
#moplano-app :is(.finance-calm,.fo-detail) .fo-empty { padding:10px 0; }
#moplano-app #page .fo-currency-notice { padding:0 3px; }
#moplano-app #page .finance-calm .fo-payment,#moplano-app .fo-detail .fo-payment { display:flex; align-items:center; gap:8px; min-height:64px; padding:10px 0; width:100%; text-align:left; }
#moplano-app #page .finance-calm .fo-payment + .fo-payment,#moplano-app .fo-detail .fo-payment + .fo-payment { border-top:1px solid var(--ui-line,#eeeee7); }
#moplano-app .fo-payment > span { flex:1; min-width:0; }
#moplano-app .fo-payment b { display:block; font-size:15px; line-height:1.4; font-weight:550; overflow-wrap:anywhere; }
#moplano-app .fo-payment small { display:block; font-size:12px; line-height:1.45; color:var(--ui-muted,#777b70); margin-top:3px; overflow-wrap:anywhere; }
#moplano-app .fo-payment strong { font-size:14px; font-weight:500; text-align:right; max-width:45%; font-variant-numeric:tabular-nums; overflow-wrap:anywhere; }
#moplano-app .fo-payment > svg { color:#a29d94; width:16px; height:16px; flex:none; }
#moplano-app #page .fo-transaction-list .transaction-row { display:flex; align-items:center; justify-content:space-between; gap:8px; min-height:64px; padding:10px 0 !important; background:transparent !important; border:0 !important; border-radius:0 !important; width:100%; box-shadow:none !important; }
#moplano-app #page .fo-transaction-list .transaction-row + .transaction-row { border-top:1px solid var(--ui-line,#eeeee7) !important; }
#moplano-app #page .fo-transaction-list .transaction-main { display:flex; align-items:center; min-width:0; gap:8px; flex:1; }
#moplano-app #page .fo-transaction-list .finance-v2-transaction-copy { min-width:0; flex:1; }
#moplano-app #page .fo-transaction-list .finance-v2-transaction-copy b { display:block; font-size:15px; font-weight:550; line-height:1.4; overflow-wrap:anywhere; }
#moplano-app #page .fo-transaction-list .finance-v2-transaction-copy small { display:block; font-size:12px; line-height:1.45; margin-top:3px; color:var(--ui-muted,#777b70); overflow-wrap:anywhere; }
#moplano-app #page .fo-transaction-list .transaction-icon { display:grid; place-items:center; width:32px; height:32px; flex:0 0 32px; border-radius:10px; background:var(--ui-soft,#f3f4f0); color:#7b8475; }
#moplano-app #page .fo-transaction-list .transaction-icon svg { width:20px; height:20px; }
#moplano-app #page .fo-transaction-list .transaction-side { display:flex; align-items:center; justify-content:flex-end; gap:4px; flex-wrap:wrap; max-width:47%; min-width:0; }
#moplano-app #page .fo-transaction-list .transaction-amount { font-size:14px; line-height:1.4; font-weight:500; font-variant-numeric:tabular-nums; white-space:normal; overflow-wrap:anywhere; }
#moplano-app #page .fo-transaction-list .transaction-amount.positive { color:var(--ui-accent,#576f59); }
#moplano-app #page .fo-transaction-list .transaction-amount:is(.negative,.neutral-money) { color:var(--ui-text,#252820); }
#moplano-app #page .fo-transaction-list :is(.finance-v2-auto-badge,.finance-v2-lock) { font-size:10px; padding:0; background:transparent; color:var(--ui-muted,#777b70); box-shadow:none; }
#moplano-app #page .fo-transaction-list .transaction-chevron { color:#a29d94; }
#moplano-app #page .fo-date { padding:4px 0 0; }
#moplano-app #page .fo-retry-inline { display:flex; justify-content:space-between; gap:8px; align-items:center; font-size:12px; color:var(--ui-muted,#777b70); padding:0 3px; }
#moplano-app #page .fo-skeleton { display:block; width:60%; height:12px; border-radius:6px; background:var(--ui-soft,#f3f4f0); margin:18px 0; }
#moplano-app .finance-overview-screen .entity-form-intro { display:none !important; }
#moplano-app .fo-detail { display:grid; gap:12px; min-width:0; }
#moplano-app .fo-detail .fo-link { min-height:44px; }
#moplano-app .fo-management .fo-link { width:100%; min-height:56px; font-size:14px; }
#moplano-app .fo-management .fo-link + .fo-link { border-top:1px solid var(--ui-line,#eeeee7); }
#moplano-app .fo-detail-add { display:block; min-height:44px; width:100%; text-align:left; color:var(--ui-accent,#576f59) !important; font-size:14px !important; margin-top:8px !important; }
#moplano-app .fo-detail .fo-detail-value { margin:5px 0 8px; font-size:24px; font-weight:550; font-variant-numeric:tabular-nums; }
#moplano-app .fo-target { padding:12px 0; }
#moplano-app .fo-target + .fo-target { border-top:1px solid var(--ui-line,#eeeee7); }
#moplano-app .fo-target > div { display:flex; align-items:baseline; gap:10px; justify-content:space-between; }
#moplano-app .fo-target b,#moplano-app .fo-target strong { font-size:14px; font-weight:500; }
#moplano-app .fo-target strong { font-variant-numeric:tabular-nums; }
#moplano-app .fo-target p,#moplano-app .fo-target small { display:block; margin:5px 0 0; color:var(--ui-muted,#777b70); font-size:12px; line-height:1.5; }
#moplano-app .fo-period-picker label { display:grid; gap:6px; color:var(--ui-muted,#777b70); font-size:13px; }
#moplano-app .fo-period-picker :is(input,select) { box-sizing:border-box; display:block; width:100%; min-width:0; min-height:44px; font:inherit; font-size:16px; padding:10px 12px; color:var(--ui-text,#252820); background:#fff; border:0; border-radius:10px; }
#moplano-app .fo-period-picker .fo-primary { display:block; min-height:44px; width:100%; text-align:center; border-radius:12px; padding:12px; background:#2f4034; color:#fff; }
#moplano-app .fo-period-picker .fo-primary:disabled { opacity:.5; }
#moplano-app .fo-picker-error { margin:0; font-size:13px; line-height:1.5; color:#9a5540; }
#moplano-app .fo-detail [hidden] { display:none !important; }
@media(max-width:360px) { #moplano-app #page .fo-totals { gap:8px; } #moplano-app #page .fo-card { padding-inline:14px; } }
