.sr-only { position:absolute; width:1px; height:1px; overflow:hidden; clip-path:inset(50%); }
.bar .brand { text-decoration:none; }
.brand img { border-radius:9px; }
.site-actions { margin-left:auto; }
.site-nav { display:flex; justify-content:center; gap:6px; padding:7px 12px; background:#fff; border-bottom:1px solid var(--line); }
.site-nav a, .cta { display:inline-flex; align-items:center; justify-content:center; min-height:44px; padding:9px 16px; border-radius:10px; text-decoration:none; font-weight:700; text-align:center; }
.site-nav a[aria-current="page"] { background:var(--light); }
.cta { color:white; background:var(--green); border:1px solid transparent; }
.cta.secondary { background:white; border-color:var(--line); color:var(--green); }
.hero { display:grid; grid-template-columns:minmax(0,1fr) 28%; align-items:center; gap:28px; background:var(--green); color:white; border-radius:24px; padding:clamp(24px,6vw,68px); }
.hero h1 { max-width:13ch; }
.hero .eyebrow { color:#c6e5ca; }
.hero-copy { max-width:40ch; font-size:1.08rem; color:#eef7ee; }
.hero-actions,.account-actions { display:flex; flex-wrap:wrap; gap:8px; margin-top:18px; }
.hero .cta { background:#dbedcc; color:var(--dark); }
.hero .cta.secondary { background:transparent; border-color:#94b99d; color:white; }
.hero-art { text-align:center; }
.hero-art img { display:block; margin:auto; width:min(100%,190px); height:auto; border-radius:25%; box-shadow:0 12px 28px #08291f88; }
.landing,.dashboard,.account { margin-top:22px; }
.features-title { margin-top:24px; }
.features { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; }
.features p { margin:0; }
.account { max-width:490px; margin-inline:auto; }
.account button, .account input { min-height:44px; }
.account #import-budget { margin-top:16px; }
#account-status { margin:12px 0 0; }
#account-status:empty { margin:0; }
#account-email { overflow-wrap:anywhere; }
#budget-mode { padding:12px 16px; margin:0; }
#budget-mode button { margin-left:8px; }
button:disabled { cursor:wait; opacity:.65; }
@media(max-width:620px) {
    body { padding-bottom:calc(68px + env(safe-area-inset-bottom)); }
    .site-nav { position:fixed; inset:auto 0 0; z-index:5; display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); border-top:1px solid var(--line); border-bottom:0; padding-bottom:calc(7px + env(safe-area-inset-bottom)); }
    .site-nav a { padding-inline:5px; }
    .landing,.dashboard,.account { margin-top:12px; }
    .hero { grid-template-columns:1fr; gap:0; border-radius:18px; }
    .hero h1 { font-size:clamp(2.3rem,11vw,3.5rem); }
    .hero-art { display:none; }
    .hero-actions { display:grid; }
    .features { grid-template-columns:1fr; gap:8px; }
    .tabs { position:static; }
    .view h2 { scroll-margin-top:16px; }
}

#password-checklist { margin-top:10px; padding:12px; border-radius:10px; background:var(--light); font-size:.875rem; }
#password-checklist p { margin:0 0 6px; }
#password-checklist ul { list-style:none; margin:0; padding:0; }
#password-checklist li { display:flex; gap:8px; align-items:baseline; }
#password-checklist li + li { margin-top:4px; }
.password-indicator { flex:0 0 1em; font-weight:750; }
.password-indicator::before { content:"○"; color:var(--muted); }
.password-indicator[data-met="true"]::before { content:"✓"; color:var(--green); }

.password-input { position:relative; }
.password-input input { padding-inline-end:52px; }
#toggle-password { position:absolute; inset-block-start:50%; inset-inline-end:1px; transform:translateY(-50%); display:grid; place-items:center; width:44px; min-height:44px; padding:0; border:0; border-radius:8px; background:transparent; color:var(--green); }
#toggle-password[hidden] { display:none; }
#toggle-password:hover { background:var(--light); }
#toggle-password:focus-visible { outline:2px solid var(--green); outline-offset:-3px; }
.password-eye-slash { display:none; }
#toggle-password[data-visible="true"] .password-eye-slash { display:inline; }

.account { max-width:530px; padding:clamp(20px,4vw,34px); }
.account-header { display:flex; align-items:flex-start; gap:14px; margin-bottom:22px; }
.account-header img { flex:none; border-radius:12px; }
.account-header h2 { margin:0 0 4px; line-height:1.2; }
.account-header p { margin:0; }
.account-switch { display:grid; grid-template-columns:1fr 1fr; gap:4px; background:var(--light); padding:4px; border-radius:12px; margin-bottom:18px; }
.account-switch button { background:transparent; color:var(--green); }
.account-switch button[aria-pressed="true"] { background:white; box-shadow:0 1px 3px #12392820; }
#auth-submit { width:100%; }
.account-help { display:flex; flex-wrap:wrap; gap:4px 16px; margin-top:12px; }
.account-help button { text-align:left; border:0; background:transparent; padding-inline:0; }
.account-identity { background:var(--light); padding:14px; border-radius:12px; }
.account-identity p { margin:0; }
#account-email { font-weight:650; }
#account-status:not(:empty) { padding:12px; border-radius:10px; background:var(--light); }
@media(max-width:620px) {
    .site-nav { grid-template-columns:repeat(2,minmax(0,1fr)); }
    .site-nav.has-budget { grid-template-columns:repeat(3,minmax(0,1fr)); }
}

.settings-group { padding:16px 0; border-top:1px solid var(--line); }
.settings-group input { max-width:24rem; margin-bottom:8px; }
#settings-status:not(:empty) { background:var(--light); border-radius:10px; padding:12px; }
.notification-link { display:inline-flex; align-items:center; justify-content:center; gap:5px; font-size:.85rem; font-weight:700; min-height:44px; }
.notification-count { background:var(--green); color:white; padding:1px 6px; border-radius:12px; }
.notification-list { list-style:none; padding:0; margin:0; }
.notification-list li { background:var(--light); padding:12px; border-radius:10px; margin-bottom:8px; }
@media(max-width:430px) {
    .site-actions:has(.notification-link:not([hidden])) { width:100%; justify-content:space-between; }
    .bar:has(.notification-link:not([hidden])) { flex-wrap:wrap; }
}

.account-tabs { display:flex; gap:6px; padding:4px; margin:0 0 18px; border-radius:12px; background:var(--light); }
.account-tabs a { flex:1; display:grid; place-items:center; min-height:44px; border-radius:9px; text-decoration:none; font-weight:700; }
.account-tabs a[aria-current="page"] { background:white; box-shadow:0 1px 3px #12392820; }
#delete-account-dialog,.app-dialog { color:var(--ink); border:1px solid var(--line); border-radius:16px; padding:22px; width:min(440px,calc(100% - 32px)); }
#delete-account-dialog::backdrop,.app-dialog::backdrop { background:#10251f88; }
.danger-button { background:#8b2926; color:white; }
#delete-account-status:not(:empty) { color:#8b2926; margin:9px 0 0; }

.account .account-budget { margin-top:18px; }
.account .account-budget .account-actions { margin-top:12px; }
.account .account-budget #import-budget { margin-top:0; }

.budget-preview { margin-top:16px; }
.budget-preview summary { cursor:pointer; font-weight:750; color:var(--green); }
.budget-preview-content { padding-top:12px; }
.budget-preview-fields { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:10px; }
.budget-preview-fields input { width:100%; }
#preview-balance { display:block; background:var(--light); border-radius:10px; color:var(--green); padding:12px; font-weight:750; margin:12px 0; }
@media(max-width:480px) { .budget-preview-fields { grid-template-columns:1fr; } }

.app-dialog h2 { margin:0; }
.app-dialog .account-actions { justify-content:flex-end; }
.reviews { margin-top:24px; }
.reviews p { margin-bottom:0; }
#signup-terms h3 { margin:0 0 8px; }
#terms-text { max-height:8rem; overflow:auto; padding:12px; border:1px solid var(--line); border-radius:10px; background:var(--light); }
#terms-text p { margin:0 0 12px; }
#terms-text p:last-child { margin-bottom:0; }
.terms-check { display:flex; align-items:flex-start; gap:10px; }
.terms-check input { width:1.15rem; height:1.15rem; margin:2px 0 0; flex:none; accent-color:var(--green); }

#student-review { margin-top:14px; }
#review-message { font:inherit; width:100%; padding:10px 12px; border:1px solid var(--line); border-radius:10px; color:var(--ink); resize:vertical; }
#review-help { margin-top:4px; }
#review-status:empty { display:none; }

#open-activity { margin-top:12px; }

@media (min-width:761px) { .tabs { grid-template-columns:repeat(7,minmax(0,1fr)); } }
#planning .stack { gap:12px; }
#planning h3, #planning p { margin:0; }
#planning .planning-result { background:var(--light); padding:12px 14px; border-radius:10px; color:var(--green); font-weight:700; }
#planning .bill-actions { display:flex; flex-wrap:wrap; gap:8px; }
#planning .bill-actions button { padding:8px 12px; }
#limit-list p { margin:4px 0; }
#limit-list progress { width:100%; }

#open-planning { display:flex; align-items:center; justify-content:space-between; gap:12px; width:100%; padding:12px 16px; text-align:left; background:var(--light); border-color:var(--line); color:var(--green); }
#open-planning small { display:block; margin-top:2px; color:var(--muted); font-weight:500; line-height:1.35; }
#open-planning [aria-hidden] { font-size:1.2rem; }

#activity .bill-actions, .goal-actions { display:flex; flex-wrap:wrap; gap:8px; }
#savings-list progress { width:100%; }
#savings-list .bill-actions { margin-top:8px; }
#afford-result { margin:0; }

#planning .trash-button { width:44px; height:44px; flex:0 0 44px; padding:0; display:inline-grid; place-items:center; color:#8b3229; }
#planning .trash-button:hover { background:#f9ece9; }
.planning-item-actions { display:flex; align-items:center; gap:10px; }
.planning-item-actions > p { flex:1; }

#planning .planning-tool { padding-block:0; }
.planning-tool > summary { cursor:pointer; padding-block:14px; color:var(--green); }
.planning-tool > summary h3 { display:inline; }
.planning-tool-body { padding-bottom:16px; }

#support-message { width:100%; min-height:120px; padding:12px; font:inherit; border:1px solid var(--line); border-radius:10px; resize:vertical; }
#demo-notice { margin:12px; background:var(--light); border-color:var(--green); }
#help details > summary { cursor:pointer; color:var(--green); font-weight:700; }
.footer-brand { flex-wrap:wrap; }
.footer-brand > a { margin-left:12px; }

.balance.is-negative { background:linear-gradient(135deg,#8b2926,#5d1c1a); }
.budget-warning-dialog { border:2px solid #b33b32; background:#fff5f2; }
.budget-warning-dialog h2 { color:#79251f; }
