*{box-sizing:border-box} :root{color-scheme:light;--bg:#f3f8fc;--paper:#fff;--ink:#243f54;--muted:#718596;--line:#dbe7ef;--accent:#326f9b;--danger:#a44e40;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:var(--ink);background:#e5e9ec;font-synthesis:none}html,body{height:100%;overflow:hidden}body{margin:0}#app{height:100vh;height:100dvh;overflow:hidden}button,input,select,textarea{font:inherit;color:inherit}button{cursor:pointer;border:0;background:none;touch-action:manipulation;-webkit-tap-highlight-color:transparent}button:disabled{opacity:.5;cursor:wait}button:focus-visible,input:focus-visible,textarea:focus-visible,select:focus-visible{outline:3px solid #8496a5;outline-offset:3px}.icon{width:20px;height:20px;flex-shrink:0;vertical-align:middle;stroke-width:1.65}.shell{max-width:620px;height:100vh;height:100dvh;min-height:0;background:var(--bg);margin:0 auto;display:flex;flex-direction:column;overflow:hidden}.topbar{display:flex;justify-content:space-between;align-items:center;padding:calc(21px + env(safe-area-inset-top)) 24px 17px;gap:16px}.brand{padding:0;display:flex;align-items:center;gap:10px;text-align:left}.brand-mark{width:36px;height:36px;display:grid;place-items:center;border:1px solid #c0c9d0;background:#e5eaee;border-radius:9px;font-size:21px;font-weight:500;letter-spacing:-1px}.brand-name{font-size:21px;letter-spacing:-.8px;font-weight:550}.brand-name small{display:block;font-size:8px;letter-spacing:1.7px;font-weight:500;color:var(--muted);margin-top:3px;text-transform:uppercase}.icon-button{display:grid;place-items:center;height:42px;width:42px;border:1px solid var(--line);background:var(--paper);border-radius:9px;flex-shrink:0}.sync-bar{padding:10px 24px 13px;display:flex;justify-content:space-between;gap:12px;align-items:center;border-bottom:1px solid var(--line);font-size:10px;color:var(--muted)}.sync-description{display:flex;align-items:center;gap:6px;line-height:1.5;min-width:0}.sync-description .icon{width:13px;height:13px}.sync-description.warning{color:#a46c3f}.sync-description.error{color:var(--danger)}.sync-action{font-size:10px;font-weight:600;padding:4px 0;min-height:28px;white-space:nowrap}.sync-action .icon{width:12px;height:12px;margin-left:3px}.topbar,.sync-bar{flex-shrink:0}main{flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:20px 24px;scrollbar-width:thin}.eyebrow{text-transform:uppercase;letter-spacing:1.6px;font-weight:600;font-size:9px;color:var(--muted);margin:0 0 12px;line-height:1.6}.hero{margin-bottom:27px}.hero h1{font-size:35px;line-height:1.12;letter-spacing:-1.55px;font-weight:450;margin:0 0 13px}.hero h1 span{color:#798895}.hero>p:last-child{font-size:12px;line-height:1.7;color:var(--muted);margin:0}.cards{display:grid;grid-template-columns:1fr 1fr;gap:13px}.main-card{padding:18px 16px;background:var(--paper);border:1px solid var(--line);border-radius:12px;display:flex;flex-direction:column;align-items:flex-start;text-align:left;min-height:166px;position:relative;overflow:hidden}.card-icon{height:37px;width:37px;border-radius:9px;background:var(--tint);color:var(--tone);display:grid;place-items:center;margin-bottom:22px}.main-card strong{font-size:14px;font-weight:600;line-height:1.35;letter-spacing:-.2px;max-width:125px}.main-card .card-summary{font-size:11px;color:var(--muted);margin-top:7px;line-height:1.6}.card-arrow{position:absolute;right:15px;top:20px;color:#9ca4aa;width:14px;height:14px}.card-caption{font-size:9px;color:var(--tone);font-weight:550;margin-top:5px;line-height:1.5}.section{margin-top:29px}.section-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:15px}.section-head h2{font-size:15px;font-weight:550;letter-spacing:-.3px;margin:0}.section-head>span{font-size:10px;color:var(--muted)}.text-button{display:inline-flex;align-items:center;gap:6px;font-size:11px;font-weight:550;color:var(--accent);min-height:35px;padding:5px 0}.text-button .icon{height:14px;width:14px}.list{border-top:1px solid var(--line)}.item{padding:17px 0;display:flex;align-items:center;gap:12px;width:100%;text-align:left;border-bottom:1px solid var(--line)}.item-icon{height:35px;width:35px;display:grid;place-items:center;background:#e8ecf0;border-radius:8px;color:#72818e;flex-shrink:0}.item-icon .icon{height:17px;width:17px}.item-body{display:flex;flex:1;min-width:0;flex-direction:column;gap:6px}.item-body strong{font-size:12px;font-weight:550;overflow-wrap:anywhere;line-height:1.5}.subline{font-size:10px;color:var(--muted);line-height:1.5;overflow-wrap:anywhere}.subline.overdue{color:var(--danger)}.item-end{font-size:12px;font-weight:550;white-space:nowrap;flex-shrink:0}.income{color:#53697b}.expense{color:#9b6854}.empty{padding:29px 17px;text-align:center;border:1px dashed #d2d9df;border-radius:10px;background:#ecf0f3}.empty>.icon{height:25px;width:25px;color:#8996a0;margin-bottom:13px}.empty strong{display:block;font-size:13px;font-weight:550;line-height:1.5}.empty p{font-size:11px;line-height:1.8;margin:9px auto 8px;color:var(--muted);max-width:275px}.local-note{display:flex;justify-content:center;align-items:center;gap:7px;font-size:9px;color:#868e94;margin-top:29px;line-height:1.5}.local-note .icon{height:12px;width:12px}.wordmark{text-align:center;font-size:8px;letter-spacing:2px;color:#abb3b9;font-weight:550;margin-top:26px}.bottom-nav{position:relative;bottom:auto;left:auto;transform:none;width:100%;flex-shrink:0;display:grid;grid-template-columns:1fr 1fr;gap:10px;padding:12px 24px calc(13px + env(safe-area-inset-bottom));background:#f5f7f8f7;backdrop-filter:blur(15px);border-top:1px solid var(--line);z-index:10}.bottom-nav button{display:flex;align-items:center;justify-content:center;gap:9px;border:1px solid transparent;border-radius:9px;min-height:44px;color:#858e95;font-size:11px;font-weight:550}.bottom-nav button.active{background:#e1e8ed;border-color:#d4dce3;color:#3c4b58}.bottom-nav .icon{width:18px;height:18px}.page-heading{display:flex;align-items:flex-start;gap:14px;margin-bottom:27px}.page-heading h1{font-size:27px;line-height:1.15;font-weight:450;letter-spacing:-1px;margin:0 0 7px}.page-heading p{margin:0;color:var(--muted);font-size:11px;line-height:1.7}.back{height:36px;width:36px;background:none}.back .icon{transform:rotate(180deg);height:17px;width:17px}.page-heading .heading-body{flex:1;min-width:0}.page-heading>.icon-button:last-child{background:var(--accent);color:white;border-color:var(--accent);height:38px;width:38px}.stat-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:9px;margin-bottom:21px}.stat{background:var(--paper);border:1px solid var(--line);border-radius:10px;padding:15px 10px;overflow:hidden}.stat>span{font-size:9px;color:var(--muted);display:block;margin-bottom:10px}.stat strong{display:block;font-size:18px;letter-spacing:-.7px;font-weight:500;overflow-wrap:anywhere}.stat.highlight{background:#e3eaf0;border-color:#d4dde5}.actions{display:flex;gap:9px;margin:17px 0 22px}.primary,.secondary{display:inline-flex;align-items:center;justify-content:center;gap:8px;border-radius:9px;min-height:44px;padding:12px 16px;font-size:12px;font-weight:550;line-height:1.4}.primary{background:var(--accent);color:white;border:1px solid var(--accent)}.primary .icon,.secondary .icon{height:16px;width:16px}.secondary{background:var(--paper);border:1px solid #d3dae0;color:var(--accent)}.actions>.primary,.actions>.secondary{flex:1}.month-select{display:flex;align-items:center;justify-content:space-between;margin:20px 0;font-size:13px;font-weight:500;text-transform:capitalize}.month-select>.icon-button{height:35px;width:35px;background:transparent}.month-select>.icon-button:first-child .icon{transform:rotate(180deg)}.filters{display:flex;gap:6px;margin-bottom:17px;flex-wrap:wrap}.filters button{border:1px solid var(--line);border-radius:7px;min-height:36px;padding:7px 12px;font-size:10px;background:#fff;color:var(--muted)}.filters button.active{border-color:#9aa9b5;background:#e3eaf0;color:var(--accent)}.scheduled-item{padding:17px 0;border-bottom:1px solid var(--line)}.scheduled-item>.item{padding:0;border:0}.scheduled-footer{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-left:47px;margin-top:10px}.scheduled-footer>span{font-size:9px;color:var(--muted)}.small-button{border:1px solid #c5cfd8;border-radius:7px;padding:8px 11px;min-height:35px;font-size:10px;background:#e3eaf0;color:var(--accent);white-space:nowrap}.paid-label{display:flex;align-items:center;gap:5px;color:#627687!important;font-weight:550}.paid-label .icon{height:12px;width:12px}.idea-note{background:var(--paper);border:1px solid var(--line);border-radius:10px;padding:19px;width:100%;text-align:left;margin-bottom:12px}.idea-note>span{display:flex;justify-content:space-between;gap:12px;font-size:9px;color:#8c959d;margin-bottom:13px}.idea-note strong{font-size:15px;font-weight:550;display:block;line-height:1.5;overflow-wrap:anywhere}.idea-note p{font-size:12px;line-height:1.9;color:#757d84;white-space:pre-wrap;overflow-wrap:anywhere;margin:10px 0 0}.month-card{background:#e3eaf0;border:1px solid #d2dce4;border-radius:12px;padding:23px;margin-bottom:26px}.month-card-header{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;margin-bottom:28px}.month-card h2{font-size:29px;font-weight:450;letter-spacing:-1.1px;line-height:1.1;text-transform:capitalize;margin:0}.month-card h2 small{font-size:13px;color:#71808d;font-weight:400;letter-spacing:0;display:block;margin-top:9px}.month-card-header>.icon{height:30px;width:30px;color:#8d9daa;stroke-width:1.2}.month-balance-label{font-size:9px;color:#72808b;margin-bottom:8px}.month-balance{font-size:39px;font-weight:450;letter-spacing:-1.5px;overflow-wrap:anywhere}.month-totals{display:grid;grid-template-columns:1fr 1fr;gap:18px;border-top:1px solid #c9d5df;margin-top:20px;padding-top:19px}.month-totals span{display:block;font-size:9px;color:#7c8b97;margin-bottom:7px}.month-totals strong{font-size:17px;font-weight:500;letter-spacing:-.5px}.month-future{background:#ffffff70;border:1px solid #ced9e2;border-radius:9px;padding:15px;margin-top:22px;display:flex;align-items:center;justify-content:space-between;gap:13px}.month-future span{font-size:10px;line-height:1.6;color:#728492}.month-future strong{font-size:16px;font-weight:500;white-space:nowrap}.info{display:flex;gap:9px;font-size:11px;line-height:1.8;color:var(--muted);border-left:2px solid #b2c0cb;padding:4px 0 4px 13px;margin:19px 0}.info .icon{width:16px;height:16px;margin-top:2px}.alert{background:#f6e9de;border:1px solid #ead4c2;border-radius:9px;padding:16px;font-size:12px;line-height:1.8;color:#986344;margin-bottom:20px}.alert strong{display:block;margin-bottom:7px}dialog{border:1px solid #d4dce3;max-width:100%;width:min(100%,540px);max-height:91dvh;background:var(--bg);color:var(--ink);padding:22px 24px calc(24px + env(safe-area-inset-bottom));position:fixed;bottom:0;top:auto;margin:0 auto;border-radius:12px 12px 0 0;box-shadow:0 10px 80px #19263030;overflow-y:auto;overscroll-behavior:contain}dialog::backdrop{background:#18242e60;backdrop-filter:blur(2px)}body:has(dialog[open]){overflow:hidden}.dialog-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:25px}.dialog-heading h2{font-size:24px;letter-spacing:-.7px;font-weight:450;margin:0}.dialog-heading .eyebrow{font-size:8px;margin-bottom:7px}.dialog-heading .icon-button{height:35px;width:35px;background:transparent}.field{display:flex;flex-direction:column;gap:9px;margin-bottom:18px;min-width:0}.field>span{font-size:11px;font-weight:550}.field input,.field textarea,.field select{width:100%;min-width:0;min-height:46px;border:1px solid #d5dce2;background:var(--paper);border-radius:8px;padding:12px;font-size:14px;appearance:auto}.field input::placeholder,.field textarea::placeholder{color:#a4acb2}.field textarea{resize:vertical;min-height:110px;line-height:1.8}.field .amount{font-size:29px;letter-spacing:-1px;padding:17px}.field-pair{display:grid;grid-template-columns:1fr 1fr;gap:12px}.field-help{font-size:10px;line-height:1.8;color:var(--muted);margin:8px 0 18px}.form-actions{display:flex;gap:10px;margin-top:23px}.form-actions>.primary{flex:1}.delete{height:45px;width:45px;border:1px solid #e9d6c8;background:#f4e9df;color:#a57659;border-radius:8px;flex-shrink:0}.delete .icon{height:18px;width:18px}.form-error{font-size:12px;color:var(--danger);line-height:1.7}.form-error:empty{display:none}.settings-section{padding-top:23px;margin-top:25px;border-top:1px solid var(--line)}.settings-section h3{font-size:13px;font-weight:550;display:flex;align-items:center;gap:8px;margin:0 0 12px}.settings-section h3 .icon{height:17px;width:17px}.settings-section>p{font-size:11px;line-height:1.9;color:var(--muted);overflow-wrap:anywhere}.settings-section>.primary{width:100%}.backup-actions{display:flex;gap:8px;flex-wrap:wrap}.danger-link{font-size:11px;color:var(--danger);padding:12px 0;min-height:40px}.danger{background:var(--danger);border-color:var(--danger)}.account-state{border:1px solid var(--line);border-radius:9px;background:#e7edf2;padding:15px;margin-bottom:19px;font-size:12px;line-height:1.8;overflow-wrap:anywhere}.account-state strong{display:block;font-size:13px}.auth-actions{display:grid;grid-template-columns:1fr 1fr;gap:9px}.auth-actions .primary,.auth-actions .secondary{padding-left:8px;padding-right:8px}.conflict{border:1px solid #e4d2bd;background:#f6eee3;border-radius:9px;padding:14px;margin:14px 0}.conflict>strong{font-size:12px;line-height:1.6;display:block;overflow-wrap:anywhere}.conflict>p{font-size:10px;line-height:1.8;color:#978269}.conflict .actions{margin:13px 0 0}.conflict .actions button{font-size:10px;padding:8px}.confirm-text{font-size:13px;line-height:1.9;color:var(--muted);margin:0 0 25px}.confirm-actions{display:flex;gap:9px}.confirm-actions>*{flex:1}#toast{position:fixed;bottom:calc(92px + env(safe-area-inset-bottom));left:50%;transform:translate(-50%,15px);background:#26343ff7;color:#f8fcff;border-radius:9px;padding:13px 17px;width:max-content;max-width:calc(100% - 32px);font-size:12px;line-height:1.6;opacity:0;pointer-events:none;transition:opacity .18s,transform .18s;z-index:50;box-shadow:0 5px 30px #17242e20}#toast.show{opacity:1;transform:translate(-50%,0)}.spinner .icon{animation:spin 1.5s linear infinite}@keyframes spin{to{transform:rotate(360deg)}}@media(min-width:500px){main{padding:24px 36px 20px}.topbar{padding-left:36px;padding-right:36px}.sync-bar{padding-left:36px;padding-right:36px}.hero h1{font-size:43px}.main-card{padding:24px;min-height:192px}.main-card strong{font-size:17px;max-width:none}.main-card .card-summary{font-size:12px}.card-icon{height:42px;width:42px;margin-bottom:25px}.card-arrow{right:23px;top:27px}.cards{gap:16px}.bottom-nav{padding-left:36px;padding-right:36px}.item-body strong{font-size:13px}.item-end{font-size:14px}.stat strong{font-size:22px}}@media(min-width:750px){.shell{margin:0 auto;border:1px solid #d4dce3;border-radius:12px 12px 0 0;box-shadow:0 18px 70px #26343f09}.topbar{padding-top:23px}.bottom-nav{border-left:1px solid #d4dce3;border-right:1px solid #d4dce3}dialog{bottom:24px;border-radius:12px}}@media(max-width:350px){main{padding-left:17px;padding-right:17px}.topbar,.sync-bar{padding-left:17px;padding-right:17px}.hero h1{font-size:31px}.main-card{min-height:158px;padding:16px 12px}.main-card strong{font-size:13px}.main-card .card-summary{font-size:10px}.stat{padding:13px 7px}.stat strong{font-size:16px}.stat>span{font-size:8px}.card-arrow{right:12px}.bottom-nav{padding-left:17px;padding-right:17px}}@media(prefers-reduced-motion:reduce){*{animation:none!important;transition:none!important}}

.brand-mark{overflow:hidden;background:#2f3d49;border-color:#2f3d49}.brand-rocket{display:block;width:100%;height:100%;object-fit:cover}

/* Every screen stays within the viewport; only detail lists may scroll. */
.main--general,.main--month{display:flex;flex-direction:column;overflow:hidden}
.main--general .hero{flex-shrink:0;margin-bottom:clamp(14px,2.6dvh,25px)}
.main--general .hero .eyebrow{margin-bottom:8px}
.main--general .hero h1{font-size:clamp(28px,4.7dvh,40px);line-height:1.1;margin:0}
.main--general .cards{flex:1;min-height:0;grid-template-rows:repeat(2,minmax(0,1fr))}
.main--general .main-card{min-height:0;height:100%;padding:clamp(13px,2.4dvh,22px) 16px;justify-content:center}
.main--general .card-icon{margin-bottom:clamp(12px,2.1dvh,22px)}
.main--general .main-card strong{max-width:none}
.main--month .hero{flex-shrink:0;margin:0 0 16px}
.main--month .hero .eyebrow{margin-bottom:6px}
.main--month .hero h1{font-size:clamp(24px,3.6dvh,32px);line-height:1.1;margin:0}
.main--month .month-card{flex:1;min-height:0;max-height:570px;display:flex;flex-direction:column;margin:0;padding:clamp(17px,3dvh,26px)}
.main--month .month-card-header{margin-bottom:clamp(18px,4dvh,38px)}
.main--month .month-totals{margin-top:auto}
.main--month .month-balance{font-size:clamp(31px,5dvh,45px)}
.main--month .month-future{flex-shrink:0}
dialog{max-height:calc(100dvh - 24px);scrollbar-width:thin}
@media(max-height:680px){
 .topbar{padding-top:calc(12px + env(safe-area-inset-top));padding-bottom:12px}
 main{padding-top:13px;padding-bottom:13px}
 .bottom-nav{padding-top:8px;padding-bottom:calc(8px + env(safe-area-inset-bottom))}
 .main--general .hero .eyebrow{font-size:8px;margin-bottom:5px}
 .main--general .hero h1{font-size:27px}
 .main--general .main-card{padding:12px}
 .main--general .card-icon{width:29px;height:29px;margin-bottom:9px}
 .main--general .card-icon .icon{width:17px;height:17px}
 .main--general .main-card .card-caption{display:none}
 .main--general .main-card .card-summary{margin-top:5px}
 .main--month .hero{margin-bottom:12px}
 .main--month .month-card{padding:17px}
 .main--month .month-card-header{margin-bottom:16px}
 .main--month .month-card h2{font-size:26px}
 .main--month .month-totals{padding-top:13px}
 .main--month .month-future{padding:11px;margin-top:14px}
}
@media(max-height:520px){
 .main--general .hero{display:none}
 .main--month .hero{display:none}
 .main--month .month-card-header{margin-bottom:10px}
 .main--month .month-card h2{font-size:22px}
 .main--month .month-card h2 small{font-size:11px;margin-top:4px}
 .main--month .month-totals{padding-top:9px}
 .main--month .month-future{margin-top:9px}
}

.main--month .month-card{overflow-y:auto;overscroll-behavior:contain}

/* A quiet blue calendar, with one shared scroll area for its day details. */
.topbar-actions .is-syncing>.icon{animation:pull-refresh-spin .85s linear infinite;transform-origin:center}
input[type=checkbox]{accent-color:var(--accent)}
.main--month{display:block;overflow-y:auto;scrollbar-gutter:stable}
.month-calendar{width:100%;min-width:0;padding-bottom:8px}
.calendar-heading{display:flex;justify-content:space-between;align-items:center;gap:12px}
.calendar-heading h1{font-size:26px;letter-spacing:-.8px;font-weight:450;margin:0}
.calendar-heading .text-button{padding:5px 12px;border:1px solid var(--line);border-radius:8px;background:var(--paper)}
.month-calendar .month-select{margin:12px 0 16px}
.calendar-weekdays,.calendar-grid{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:4px}
.calendar-weekdays{font-size:10px;text-align:center;color:var(--muted);margin-bottom:8px}
.calendar-day{position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;min-width:0;min-height:45px;padding:7px 0 4px;border:1px solid transparent;border-radius:9px;font-size:13px;font-weight:500}
.calendar-day.today{border-color:#a9cbe2;color:var(--accent);font-weight:650}
.calendar-day.selected{background:var(--accent);color:#fff;border-color:var(--accent)}
.calendar-dots{display:flex;justify-content:center;gap:3px;height:4px}
.calendar-dots i,.calendar-legend i{display:inline-block;width:4px;height:4px;border-radius:50%;background:#719ec4;flex-shrink:0}
.calendar-dots .deadline,.calendar-legend .deadline{background:#bd8b64}
.calendar-dots .scheduled,.calendar-legend .scheduled{background:#ad94b8}
.calendar-dots .finance,.calendar-legend .finance{background:#69a5ab}
.calendar-day.selected .calendar-dots i{background:#fff}
.calendar-legend{display:flex;flex-wrap:wrap;gap:7px 12px;font-size:8px;color:var(--muted);padding:13px 1px 17px;border-bottom:1px solid var(--line)}
.calendar-legend>span{display:flex;align-items:center;gap:5px}
.calendar-day-details{margin-top:18px}
.calendar-day-details h2{font-size:15px;font-weight:550;margin:0 0 12px;text-transform:capitalize}
.calendar-entry{display:flex;flex-direction:column;align-items:flex-start;gap:5px;width:100%;padding:13px;text-align:left;background:var(--paper);border:1px solid var(--line);border-radius:9px;margin-bottom:8px;overflow-wrap:anywhere}
.calendar-entry-kind{font-size:9px;color:var(--accent)}
.calendar-entry-kind.deadline{color:#986b47}
.calendar-entry-kind.scheduled{color:#8b7097}
.calendar-entry strong{font-size:12px;font-weight:550;line-height:1.5}
.calendar-entry>span:last-child,.calendar-no-items{font-size:11px;color:var(--muted);line-height:1.6}
.calendar-no-items{margin:0 0 7px}
.calendar-month-summary{margin-top:18px;padding:14px;background:#e8f2fa;border:1px solid var(--line);border-radius:10px}
.calendar-month-summary summary{cursor:pointer;display:flex;flex-wrap:wrap;gap:8px;justify-content:space-between;font-size:10px;line-height:1.5}
.calendar-month-summary summary strong{font-size:14px;font-weight:550}
.calendar-month-summary .month-totals{margin-top:15px;padding-top:13px;border-color:var(--line)}
.calendar-month-summary .month-future{margin-top:14px;border-color:var(--line)}
@media(max-width:360px){.calendar-day{min-height:40px;font-size:12px}.calendar-weekdays{font-size:9px}.calendar-legend{font-size:8px;gap:7px}.calendar-grid{gap:2px}}
@media(prefers-reduced-motion:reduce){.topbar-actions .is-syncing>.icon{animation-duration:1.8s}}
@media(max-height:400px){.main--general .card-icon{display:none}.main--general .main-card{padding:8px}.main--general .main-card strong{font-size:12px}.main--general .main-card .card-summary{font-size:10px;margin-top:4px}}

html,body{overscroll-behavior-y:none}
.header-actions{display:flex;gap:8px;flex-shrink:0}
.pull-refresh{position:fixed;z-index:1000;top:calc(12px + env(safe-area-inset-top));left:50%;width:42px;height:42px;display:grid;place-items:center;background:var(--paper,#f3f6f8);color:#2f3d49;border:1px solid #c5ced5;border-radius:12px;box-shadow:0 4px 16px #202c3622;transform:translate(-50%,-90px);opacity:0;pointer-events:none;transition:transform .12s,opacity .12s}
.pull-refresh.visible{opacity:1;transform:translate(-50%,0)}
.pull-refresh.ready{background:#dfe8ef;border-color:#6d8191}
.pull-refresh-icon{font-size:28px;line-height:1;transform:rotate(calc(var(--pull-progress,1)*180deg))}
.pull-refresh.loading .pull-refresh-icon{animation:pull-refresh-spin .75s linear infinite}
.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}
@keyframes pull-refresh-spin{to{transform:rotate(360deg)}}
@media(max-width:360px){.header-actions{gap:5px}.header-actions .icon-button{width:37px;height:37px}.brand-name small{font-size:7px;letter-spacing:1.2px}}

.quick-note{padding:0 24px 12px;flex-shrink:0}
.quick-note textarea{display:block;width:100%;height:62px;min-height:62px;max-height:62px;resize:none;padding:10px 12px;border:1px solid var(--line);border-radius:10px;background:var(--paper);font-size:13px;line-height:1.45;overflow-y:auto}
.quick-note textarea::placeholder{color:var(--muted)}
#sync-slot{flex-shrink:0}
.bottom-nav{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px}
.bottom-nav button{min-width:0;gap:6px;padding-left:5px;padding-right:5px;font-size:11px}
.bottom-nav .icon{width:18px;height:18px}
.deadline-actions{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:16px}
.deadline-group{margin-top:20px}
.deadline-group h2{font-size:13px;margin:0 0 8px}
.deadline-group.overdue h2{color:var(--danger)}
.deadline-row{display:flex;align-items:center;gap:8px;border-bottom:1px solid var(--line)}
.deadline-row .item{flex:1;min-width:0;border:0}
.deadline-row .item-body{min-width:0}
.deadline-row .item-body strong{overflow-wrap:anywhere}
.deadline-pay{font-size:10px;padding:9px;flex-shrink:0}
@media(max-width:360px){.quick-note{padding-left:18px;padding-right:18px}.bottom-nav button{gap:4px;font-size:10px}.deadline-pay{max-width:75px;white-space:normal}}
@media(max-height:520px){.quick-note{padding-bottom:8px}.quick-note textarea{height:46px;min-height:46px;max-height:46px}}

.deadline-paid{padding:8px;flex-shrink:0}

/* Quick capture and five cards stay inside the existing app frame. */
.capture-row{display:flex;align-items:stretch;gap:8px}
.capture-row textarea{flex:1;min-width:0}
.capture-send{align-self:center;background:var(--accent);color:white;border-color:var(--accent)}
.capture-preview{min-height:24px;padding:6px 1px 0;font-size:10px;line-height:1.35;color:var(--muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.capture-preview.capture-error{color:var(--danger)}
.capture-preview:empty{display:none}
.topbar-actions{display:flex;align-items:center;gap:8px}
.import-warnings{padding-left:20px;font-size:12px;line-height:1.6;color:var(--muted)}
.import-preview{margin-bottom:20px}
.bottom-nav{grid-template-columns:repeat(2,minmax(0,1fr))}
.main--general .cards{grid-template-rows:repeat(2,minmax(0,1fr)) minmax(62px,.65fr);gap:10px}
.main--general .hero{margin-bottom:8px}
.main--general .hero .eyebrow{margin-bottom:3px}
.main--general .main-card{padding:clamp(10px,1.7dvh,17px) 13px}
.main--general .card-icon{margin-bottom:clamp(7px,1.3dvh,13px)}
.main--general .main-card--wide{grid-column:1/-1;display:grid;grid-template-columns:36px 1fr;grid-template-rows:auto auto;column-gap:12px;align-content:center}
.main-card--wide .card-icon{grid-row:1/3;margin:0!important}
.main-card--wide .card-summary{grid-column:2;margin-top:4px}
.main-card--wide .card-caption{display:none}
.connections-entry{margin-bottom:22px}
.connections-panel p{font-size:12px;line-height:1.6;color:var(--muted)}
.connections-panel h3{font-size:16px}
.connections-panel a{color:var(--accent);overflow-wrap:anywhere}
.connections-panel input[readonly]{font-size:11px}
.connections-panel .actions{flex-wrap:wrap}
.health-options{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin:16px 0}
.health-options label{font-size:12px;display:flex;align-items:center;gap:6px}
.health-options input{width:18px;height:18px}
.light-option{padding:10px 0;border-bottom:1px solid var(--line);font-size:13px}
.light-option .actions{margin-top:8px}
@media(max-height:620px){.quick-note{padding-bottom:7px}.quick-note textarea{height:48px;min-height:48px;max-height:48px}.capture-preview{min-height:21px;font-size:9px}.main--general .cards{gap:8px;grid-template-rows:repeat(2,minmax(0,1fr)) minmax(56px,.65fr)}.main--general .card-icon{width:27px;height:27px;margin-bottom:6px}.main--general .main-card{padding:9px 11px}.main--general .main-card .card-summary{margin-top:4px}}

.general-tools{display:flex;align-items:center;justify-content:space-between;gap:8px}
.general-tools .eyebrow{min-width:0;line-height:1.4}
.general-tools .connections-shortcut{flex-shrink:0;padding:8px 10px;min-height:32px;font-size:11px;border-radius:8px}
.setup-steps{padding-left:19px;font-size:13px;line-height:1.65}
.setup-steps li{margin:8px 0}
.device-context{font-size:11px!important}
.technical-setup{margin-top:15px}
.technical-setup summary{cursor:pointer;font-size:12px;color:var(--accent);padding:10px 0}
@media(max-width:350px){.general-tools .connections-shortcut{font-size:10px;padding:7px 8px}.general-tools .eyebrow{font-size:8px;letter-spacing:1px}}

.health-actions{display:flex;gap:10px;flex-wrap:wrap;margin:14px 0}
.apk-download{display:inline-block;text-decoration:none;font-size:12px}
.health-sync-state{font-size:11px;line-height:1.5;color:var(--muted)}
.health-date{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:18px 0}
.health-date input{min-width:0;max-width:175px;border:1px solid var(--line);border-radius:8px;background:white;padding:10px;font-size:13px}
.health-date label{min-width:0}
.health-date [data-action="health-prev"] .icon{transform:rotate(180deg)}
.health-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.health-metric{display:flex;flex-direction:column;gap:9px;background:white;border:1px solid var(--line);border-radius:10px;padding:14px;min-width:0}
.health-metric>span{font-size:12px;color:var(--muted)}
.health-metric strong{font-size:21px;overflow-wrap:anywhere}
.health-metric small{font-size:9px;line-height:1.5;color:var(--muted)}
.health-workouts{margin-top:24px}
.health-workouts h2{font-size:16px}
.health-workout{display:flex;flex-direction:column;gap:6px;border-bottom:1px solid var(--line);padding:13px 0;font-size:12px}
.health-workout>span{font-size:11px;color:var(--muted)}
@media(max-width:350px){.health-metric{padding:11px}.health-metric strong{font-size:18px}}

/* The date sits under Lorenzo; movements use two direct home buttons. */
.brand{min-width:0}
.brand-mark{flex-shrink:0}
.brand-name .brand-date{display:block;margin-top:4px;font-size:11px;line-height:1.4;font-weight:700;letter-spacing:0;text-transform:none;color:var(--ink);white-space:nowrap}
.home-finance-actions{display:grid;grid-template-columns:1fr 1fr;gap:10px;flex-shrink:0;margin-bottom:12px}
.home-finance-actions>button{min-height:52px;font-size:14px}
.google-calendar-bar{display:flex;align-items:center;justify-content:space-between;gap:8px;flex-shrink:0;font-size:10px;color:var(--muted);padding:6px 0 12px}
.google-calendar-bar .text-button{font-size:10px;flex-shrink:0}
.google-calendar-connection{padding-bottom:16px;border-bottom:1px solid var(--line);margin-bottom:12px}
.google-event-source{font-size:12px;color:var(--accent);font-weight:600}
.google-event-notes{white-space:pre-wrap;overflow-wrap:anywhere;font-size:13px;line-height:1.6}
.main--general .cards{grid-template-rows:repeat(2,minmax(0,1fr));grid-template-columns:repeat(2,minmax(0,1fr))}
@media(max-width:360px){.topbar{gap:10px}.brand{gap:8px}.brand-name .brand-date{font-size:10px}.topbar-actions{gap:5px}.topbar-actions .icon-button{width:37px;height:37px}}
@media(max-height:620px){.home-finance-actions{margin-bottom:8px;gap:8px}.home-finance-actions>button{min-height:44px;padding:9px}}
