#pfv-app {
  --pfv-bg: #09111f;
  --pfv-sidebar: #0b1526;
  --pfv-panel: #111d31;
  --pfv-panel-2: #16243a;
  --pfv-border: #283a55;
  --pfv-text: #f7f9fc;
  --pfv-muted: #9fb0c8;
  --pfv-primary: #5c8fff;
  --pfv-primary-2: #7b61ff;
  --pfv-green: #31d39a;
  --pfv-red: #ff6f7d;
  --pfv-amber: #f9bd58;
  --pfv-shadow: 0 16px 48px rgba(0, 0, 0, .24);
  width: 100%;
  max-width: none !important;
  min-height: 720px;
  margin: 0 !important;
  color: var(--pfv-text);
  background: var(--pfv-bg);
  border-radius: 18px;
  overflow: hidden;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 15px;
  line-height: 1.45;
}

#pfv-app, #pfv-app * { box-sizing: border-box; }
#pfv-app h1, #pfv-app h2, #pfv-app h3, #pfv-app h4, #pfv-app p { margin: 0; color: var(--pfv-text) !important; }
#pfv-app td, #pfv-app th, #pfv-app label, #pfv-app span, #pfv-app strong, #pfv-app b, #pfv-app small { color: inherit; }
#pfv-app button, #pfv-app input, #pfv-app select, #pfv-app textarea { font: inherit; }
#pfv-app button { cursor: pointer; }
#pfv-app button:disabled { opacity: .45; cursor: not-allowed; }
#pfv-app a { color: inherit; }
#pfv-app .negative { color: var(--pfv-red) !important; }
#pfv-app .positive { color: var(--pfv-green) !important; }
#pfv-app .overdue { color: var(--pfv-red) !important; }
#pfv-app .soon { color: var(--pfv-amber) !important; }

.pfv-shell { display: grid; grid-template-columns: 242px minmax(0, 1fr); min-height: 760px; }
.pfv-sidebar { background: linear-gradient(180deg, #0d192c 0%, #091321 100%); border-right: 1px solid var(--pfv-border); padding: 22px 16px; display: flex; flex-direction: column; gap: 24px; position: relative; z-index: 20; }
.pfv-brand { display: flex; align-items: center; gap: 12px; padding: 0 8px; }
.pfv-brandmark { width: 40px; height: 40px; border-radius: 13px; display: inline-grid; place-items: center; font-weight: 900; letter-spacing: -.04em; color: #fff; background: linear-gradient(135deg, var(--pfv-primary), var(--pfv-primary-2)); box-shadow: 0 8px 24px rgba(92, 143, 255, .28); }
.pfv-brandmark.large { width: 68px; height: 68px; border-radius: 20px; font-size: 24px; margin: 0 auto 16px; }
.pfv-brand strong { display: block; font-size: 15px; letter-spacing: -.01em; }
.pfv-brand small, .pfv-sidebar-foot small { display: block; color: var(--pfv-muted); font-size: 10px; margin-top: 2px; }
.pfv-sidebar nav { display: grid; gap: 6px; }
.pfv-sidebar nav button { width: 100%; display: flex; align-items: center; gap: 12px; color: var(--pfv-muted); border: 1px solid transparent; background: transparent; border-radius: 11px; padding: 11px 12px; text-align: left; font-size: 13px; font-weight: 760; transition: .16s ease; }
.pfv-sidebar nav button:hover { background: rgba(255,255,255,.045); color: #fff; }
.pfv-sidebar nav button.active { color: #fff; background: linear-gradient(135deg, rgba(92,143,255,.25), rgba(123,97,255,.13)); border-color: rgba(92,143,255,.28); box-shadow: inset 3px 0 0 var(--pfv-primary); }
.pfv-sidebar-foot { margin-top: auto; padding: 14px 8px 0; border-top: 1px solid var(--pfv-border); display: flex; align-items: center; gap: 10px; min-width: 0; }
.pfv-sidebar-foot > div:last-child { min-width: 0; }
.pfv-sidebar-foot b, .pfv-sidebar-foot small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pfv-userdot { width: 32px; height: 32px; border-radius: 50%; background: var(--pfv-panel-2); color: #fff; display: grid; place-items: center; font-weight: 800; flex: 0 0 auto; }

.pfv-workspace { min-width: 0; background: radial-gradient(circle at top right, rgba(92,143,255,.07), transparent 28%), var(--pfv-bg); }
.pfv-mobilebar { display: none; }
#pfv-main { padding: 28px; min-height: 760px; }
.pfv-pagehead { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 22px; }
.pfv-pagehead h1 { font-size: clamp(24px, 3vw, 34px); line-height: 1.08; letter-spacing: -.035em; font-weight: 850; }
.pfv-pagehead p { color: var(--pfv-muted); margin-top: 7px; font-size: 13px; }
.pfv-head-actions { display: flex; flex-wrap: wrap; gap: 10px; }

.pfv-button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border-radius: 10px; border: 1px solid var(--pfv-border); min-height: 40px; padding: 9px 14px; font-weight: 800; color: var(--pfv-text); background: var(--pfv-panel-2); transition: transform .14s ease, border-color .14s ease, background .14s ease; text-decoration: none; white-space: nowrap; }
.pfv-button:hover { transform: translateY(-1px); border-color: #466184; }
.pfv-button.primary { border-color: transparent; background: linear-gradient(135deg, var(--pfv-primary), var(--pfv-primary-2)); color: #fff; box-shadow: 0 8px 22px rgba(92,143,255,.24); }
.pfv-button.secondary { background: #15233a; }
.pfv-button.ghost { background: transparent; }
.pfv-textbtn { border: 0; background: transparent; color: #adc3e5; display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 800; padding: 4px; }
.pfv-iconbtn { width: 36px; height: 36px; min-width: 36px; display: inline-grid; place-items: center; border-radius: 10px; border: 1px solid var(--pfv-border); background: #152238; color: #c9d5e7; padding: 0; }
.pfv-iconbtn:hover { border-color: #55749c; color: #fff; }
.pfv-iconbtn.danger:hover { color: var(--pfv-red); border-color: rgba(255,111,125,.45); }
.pfv-icon { display: block; flex: 0 0 auto; }

.pfv-panel { background: rgba(17,29,49,.94); border: 1px solid var(--pfv-border); border-radius: 16px; box-shadow: 0 10px 34px rgba(0,0,0,.12); }
.pfv-dashboard-grid { display: grid; grid-template-columns: minmax(300px, 1.4fr) minmax(250px, .8fr) minmax(250px, .8fr); gap: 16px; margin-bottom: 16px; }
.pfv-balance-hero { border-radius: 18px; padding: 24px; min-height: 205px; color: #fff; background: radial-gradient(circle at 85% 10%, rgba(255,255,255,.2), transparent 28%), linear-gradient(135deg, #346edb 0%, #6354d9 58%, #7d4bc3 100%); box-shadow: 0 22px 50px rgba(66, 80, 200, .27); }
.pfv-hero-label { display: flex; justify-content: space-between; align-items: center; font-weight: 700; color: rgba(255,255,255,.82); }
.pfv-hero-label .pfv-iconbtn { background: rgba(255,255,255,.13); border-color: rgba(255,255,255,.2); color: #fff; }
.pfv-hero-amount { font-size: clamp(36px, 5vw, 58px); letter-spacing: -.055em; font-weight: 900; margin: 16px 0 22px; }
.pfv-balance-breakdown { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.pfv-balance-breakdown > div { border-left: 1px solid rgba(255,255,255,.22); padding-left: 12px; min-width: 0; }
.pfv-balance-breakdown > div:first-child { border-left: 0; padding-left: 0; }
.pfv-balance-breakdown span { display: block; font-size: 10px; text-transform: uppercase; letter-spacing: .08em; color: rgba(255,255,255,.64); }
.pfv-balance-breakdown b { display: block; margin-top: 4px; font-size: 14px; overflow: hidden; text-overflow: ellipsis; }
.pfv-month-card, .pfv-credit-card { padding: 20px; }
.pfv-card-title { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; margin-bottom: 18px; }
.pfv-card-title span { color: var(--pfv-muted); font-size: 11px; text-transform: uppercase; letter-spacing: .07em; font-weight: 800; }
.pfv-card-title h3 { font-size: 21px; margin-top: 5px; letter-spacing: -.025em; }
.pfv-chip { border: 1px solid var(--pfv-border); border-radius: 999px; padding: 5px 8px; color: #cbd9ed !important; background: #0d1728; white-space: nowrap; }
.pfv-month-line { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid rgba(40,58,85,.75); color: var(--pfv-muted); }
.pfv-month-line b { color: #fff; }
.pfv-month-line.net { border-bottom: 0; padding-top: 14px; font-size: 17px; color: #fff; }
.pfv-progress { height: 8px; border-radius: 999px; background: #0a1322; overflow: hidden; box-shadow: inset 0 0 0 1px rgba(255,255,255,.03); }
.pfv-progress span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--pfv-primary), var(--pfv-primary-2)); }
.pfv-progress.over span { background: linear-gradient(90deg, var(--pfv-amber), var(--pfv-red)); }
.pfv-credit-foot { display: flex; justify-content: space-between; color: var(--pfv-muted); margin-top: 15px; }
.pfv-credit-foot b { color: #fff; }
.pfv-two-column { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(320px, .7fr); gap: 16px; }
.pfv-section { padding: 20px; }
.pfv-sectionhead { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.pfv-sectionhead span { color: var(--pfv-muted); font-size: 10px; text-transform: uppercase; letter-spacing: .08em; font-weight: 800; }
.pfv-sectionhead h2 { font-size: 20px; margin-top: 3px; }
.pfv-billlist, .pfv-activitylist { display: grid; }
.pfv-billrow { display: grid; grid-template-columns: 50px minmax(160px,1fr) auto auto; gap: 12px; align-items: center; padding: 13px 0; border-top: 1px solid rgba(40,58,85,.72); }
.pfv-billrow:first-child { border-top: 0; }
.pfv-datebox { width: 44px; height: 44px; border-radius: 11px; background: #0b1627; border: 1px solid var(--pfv-border); display: grid; place-items: center; align-content: center; line-height: 1; }
.pfv-datebox b { font-size: 17px; }
.pfv-datebox small { color: var(--pfv-muted); font-size: 9px; text-transform: uppercase; margin-top: 3px; }
.pfv-billmain strong, .pfv-billmain span, .pfv-billamount strong, .pfv-billamount span { display: block; }
.pfv-billmain span, .pfv-billamount span { color: var(--pfv-muted); font-size: 12px; margin-top: 3px; }
.pfv-billamount { text-align: right; min-width: 105px; }
.pfv-activityrow { display: grid; grid-template-columns: 36px minmax(0,1fr) auto; gap: 10px; align-items: center; padding: 11px 0; border-top: 1px solid rgba(40,58,85,.72); }
.pfv-activityrow:first-child { border-top: 0; }
.pfv-activityicon { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; font-weight: 900; }
.pfv-activityicon.expense { background: rgba(255,111,125,.12); color: var(--pfv-red); }
.pfv-activityicon.income { background: rgba(49,211,154,.12); color: var(--pfv-green); }
.pfv-activityrow strong, .pfv-activityrow span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pfv-activityrow span { color: var(--pfv-muted); font-size: 11px; margin-top: 2px; }

.pfv-summary-grid, .pfv-budget-overview { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
.pfv-budget-overview { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.pfv-summary-card { padding: 17px; border-radius: 14px; border: 1px solid var(--pfv-border); background: var(--pfv-panel); position: relative; overflow: hidden; }
.pfv-summary-card::before { content: ''; position: absolute; inset: 0 auto 0 0; width: 3px; background: var(--pfv-primary); }
.pfv-summary-card.cleared::before { background: var(--pfv-green); }
.pfv-summary-card.uncleared::before { background: var(--pfv-amber); }
.pfv-summary-card.future::before { background: var(--pfv-primary-2); }
.pfv-summary-card span, .pfv-summary-card small { display: block; color: var(--pfv-muted); }
.pfv-summary-card span { font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .055em; }
.pfv-summary-card strong { display: block; margin: 8px 0 3px; font-size: clamp(20px, 2.2vw, 28px); letter-spacing: -.035em; }
.pfv-summary-card small { font-size: 11px; }
.pfv-skeleton { height: 104px; border-radius: 14px; background: linear-gradient(90deg, var(--pfv-panel) 25%, var(--pfv-panel-2) 50%, var(--pfv-panel) 75%); background-size: 220% 100%; animation: pfv-shimmer 1.3s infinite; }
@keyframes pfv-shimmer { to { background-position: -220% 0; } }

.pfv-toolbar { display: flex; align-items: center; gap: 10px; padding: 12px; margin-bottom: 14px; }
.pfv-toolbar.compact { padding: 0; margin: 0; background: transparent; border: 0; box-shadow: none; flex: 1; }
.pfv-search { min-width: 240px; flex: 1; display: flex; align-items: center; gap: 8px; color: var(--pfv-muted); background: #0a1424; border: 1px solid var(--pfv-border); border-radius: 10px; padding: 0 11px; }
.pfv-search input { border: 0 !important; background: transparent !important; padding-left: 0 !important; box-shadow: none !important; }
#pfv-app input, #pfv-app select, #pfv-app textarea { width: 100%; min-height: 42px; border: 1px solid var(--pfv-border); border-radius: 10px; padding: 10px 12px; background: #0a1424; color: var(--pfv-text); outline: none; margin: 0; }
#pfv-app textarea { resize: vertical; min-height: 90px; }
#pfv-app input:focus, #pfv-app select:focus, #pfv-app textarea:focus { border-color: var(--pfv-primary); box-shadow: 0 0 0 3px rgba(92,143,255,.12); }
#pfv-app input::placeholder, #pfv-app textarea::placeholder { color: #6f819b; }
#pfv-app select { min-width: 150px; }

.pfv-tablewrap { overflow: auto; border-radius: 14px; }
.pfv-table { width: 100%; border-collapse: separate; border-spacing: 0; margin: 0; color: var(--pfv-text); background: transparent; }
.pfv-table th, .pfv-table td { padding: 12px 13px; border: 0; border-bottom: 1px solid rgba(40,58,85,.72); text-align: left; vertical-align: middle; }
.pfv-table th { color: #c3d0e2; background: #0d182a; font-size: 11px; text-transform: uppercase; letter-spacing: .065em; font-weight: 850; position: sticky; top: 0; z-index: 2; white-space: nowrap; }
.pfv-table tbody tr:hover { background: rgba(255,255,255,.025); }
.pfv-table tbody tr:last-child td { border-bottom: 0; }
.pfv-table td strong, .pfv-table td small { display: block; }
.pfv-table td { font-size: 13px; }
.pfv-table td small { color: var(--pfv-muted); font-size: 11px; margin-top: 3px; max-width: 620px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pfv-register-table td:nth-child(1) { white-space: nowrap; }
.pfv-register-table td:nth-child(2) { min-width: 270px; }
.pfv-money { font-variant-numeric: tabular-nums; font-weight: 800; white-space: nowrap; }
.pfv-running { color: #dbe6f6; }
.pfv-future-row { background: rgba(123,97,255,.045); }
.pfv-mini-label { display: block; width: max-content; margin-top: 4px; padding: 2px 5px; border-radius: 5px; background: rgba(123,97,255,.16); color: #bfb2ff; font-size: 8px; text-transform: uppercase; letter-spacing: .06em; font-weight: 800; }
.pfv-rowactions { display: flex; gap: 5px; justify-content: flex-end; white-space: nowrap; }
.pfv-rowactions .pfv-iconbtn { width: 30px; min-width: 30px; height: 30px; border-radius: 8px; }
.pfv-status { display: inline-flex; align-items: center; border-radius: 999px; padding: 5px 9px; font-size: 10px; font-weight: 850; text-transform: uppercase; letter-spacing: .05em; }
.pfv-status.cleared { color: #79e5bd; background: rgba(49,211,154,.12); }
.pfv-status.posted { color: #9ec0ff; background: rgba(92,143,255,.12); }
.pfv-status.pending { color: #ffd283; background: rgba(249,189,88,.12); }
.pfv-status-button { border: 0; background: transparent; padding: 0; }
.pfv-pager { display: flex; align-items: center; justify-content: center; gap: 14px; padding: 16px 0 0; color: var(--pfv-muted); font-size: 11px; }
.pfv-pager button { color: #fff; background: var(--pfv-panel-2); border: 1px solid var(--pfv-border); border-radius: 9px; padding: 8px 12px; }


.pfv-account-filterbar { padding: 13px; margin-bottom: 12px; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.pfv-filter-tabs { display: inline-flex; gap: 5px; padding: 4px; border: 1px solid var(--pfv-border); border-radius: 12px; background: #0a1424; }
.pfv-filter-tabs button { display: inline-flex; align-items: center; gap: 7px; min-height: 36px; padding: 7px 10px; border: 0; border-radius: 8px; background: transparent; color: var(--pfv-muted); font-size: 12px; font-weight: 800; }
.pfv-filter-tabs button b { min-width: 22px; padding: 2px 6px; border-radius: 999px; background: rgba(255,255,255,.06); color: #d7e2f1; font-size: 10px; text-align: center; }
.pfv-filter-tabs button.active { color: #fff; background: linear-gradient(135deg, rgba(92,143,255,.32), rgba(123,97,255,.2)); box-shadow: inset 0 0 0 1px rgba(92,143,255,.3); }
.pfv-resultline { min-height: 24px; margin: 0 2px 8px; color: var(--pfv-muted); font-size: 12px; }
.pfv-resultline b { color: var(--pfv-text); }
.pfv-account-status { display: inline-flex; align-items: center; justify-content: center; border-radius: 999px; padding: 4px 8px; font-size: 9px !important; line-height: 1; font-weight: 900; text-transform: uppercase; letter-spacing: .05em; white-space: nowrap; }
.pfv-account-status.active { color: #7ce3bc !important; background: rgba(49,211,154,.12); border: 1px solid rgba(49,211,154,.2); }
.pfv-account-status.inactive { color: #a9b4c4 !important; background: rgba(159,176,200,.09); border: 1px solid rgba(159,176,200,.16); }
.pfv-schedule-chip { display: inline-flex; width: max-content; max-width: 100%; margin: 12px 0 -4px 48px; padding: 5px 8px; border-radius: 999px; color: #c9bcff; background: rgba(123,97,255,.11); border: 1px solid rgba(123,97,255,.18); font-size: 10px; font-weight: 800; }

.pfv-account-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(285px, 1fr)); gap: 14px; }
.pfv-account-card { min-width: 0; background: linear-gradient(180deg, rgba(22,36,58,.95), rgba(15,27,46,.95)); border: 1px solid var(--pfv-border); border-radius: 16px; padding: 17px; box-shadow: 0 10px 30px rgba(0,0,0,.12); position: relative; overflow: hidden; }
.pfv-account-card::before { content: ''; position: absolute; inset: 0 0 auto 0; height: 3px; background: var(--pfv-primary); }
.pfv-account-card.loan::before { background: var(--pfv-primary-2); }
.pfv-account-card.utility::before, .pfv-account-card.insurance::before { background: var(--pfv-amber); }
.pfv-account-card.checking::before, .pfv-account-card.savings::before { background: var(--pfv-green); }
.pfv-account-card.inactive { opacity: .74; filter: saturate(.72); }
.pfv-account-top { display: grid; grid-template-columns: 38px minmax(0,1fr) auto; align-items: center; gap: 10px; }
.pfv-account-icon { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 10px; background: rgba(92,143,255,.11); color: #9dbbff; }
.pfv-account-top > div:nth-child(2) > span { color: var(--pfv-muted); font-size: 10px; text-transform: uppercase; letter-spacing: .07em; font-weight: 800; }
.pfv-account-top h3 { font-size: 17px; line-height: 1.25; margin-top: 2px; overflow-wrap: anywhere; }
.pfv-status-dot { width: 9px; height: 9px; border-radius: 50%; background: #53627a; }
.pfv-status-dot.active { background: var(--pfv-green); box-shadow: 0 0 0 4px rgba(49,211,154,.1); }
.pfv-account-balance { margin: 18px 0 15px; }
.pfv-account-balance span { color: var(--pfv-muted); font-size: 10px; }
.pfv-account-balance strong { display: block; margin-top: 3px; font-size: 28px; letter-spacing: -.035em; }
.pfv-util { margin-bottom: 15px; }
.pfv-util > div:first-child, .pfv-account-meta { display: flex; justify-content: space-between; gap: 12px; }
.pfv-util span, .pfv-util small, .pfv-account-meta span { color: var(--pfv-muted); font-size: 11px; }
.pfv-util .pfv-progress { margin: 6px 0; height: 6px; }
.pfv-account-meta { border-top: 1px solid rgba(40,58,85,.72); padding-top: 12px; }
.pfv-account-meta > div { min-width: 0; }
.pfv-account-meta span, .pfv-account-meta b { display: block; }
.pfv-account-meta b { margin-top: 4px; font-size: 13px; }
.pfv-account-actions { display: grid; grid-template-columns: .75fr 1.25fr; gap: 8px; margin-top: 15px; }
.pfv-account-actions .pfv-button { min-width: 0; padding-left: 8px; padding-right: 8px; font-size: 12px; }

.pfv-budget-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 13px; }
.pfv-budget-card { background: var(--pfv-panel); border: 1px solid var(--pfv-border); border-radius: 14px; padding: 16px; }
.pfv-budget-title, .pfv-budget-foot { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.pfv-budget-title h3 { font-size: 15px; }
.pfv-budget-title span, .pfv-budget-foot span { color: var(--pfv-muted); font-size: 10px; }
.pfv-budget-card .pfv-progress { margin: 13px 0 8px; }
.pfv-budget-foot b { font-size: 11px; }
.pfv-recurring-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 13px; }
.pfv-recurring-card { display: grid; grid-template-columns: 42px minmax(0,1fr) auto; gap: 12px; align-items: center; background: var(--pfv-panel); border: 1px solid var(--pfv-border); border-radius: 14px; padding: 15px; }
.pfv-recurring-icon { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 12px; font-size: 22px; font-weight: 900; background: rgba(255,111,125,.12); color: var(--pfv-red); }
.pfv-recurring-card.income .pfv-recurring-icon { background: rgba(49,211,154,.12); color: var(--pfv-green); }
.pfv-recurring-card span, .pfv-recurring-card small { display: block; color: var(--pfv-muted); font-size: 9px; }
.pfv-recurring-card h3 { font-size: 14px; margin: 2px 0; }
.pfv-recurring-card strong { font-size: 18px; }

.pfv-unlock { width: min(470px, 100%); margin: 50px auto; padding: 30px; text-align: center; }
.pfv-unlock p { color: var(--pfv-muted); margin: 8px 0 18px; }
.pfv-unlock input { margin-bottom: 10px !important; }
.pfv-vault-icon { width: 66px; height: 66px; margin: 0 auto 14px; display: grid; place-items: center; border-radius: 20px; color: #b8caff; background: linear-gradient(135deg, rgba(92,143,255,.2), rgba(123,97,255,.17)); }
.pfv-vault-icon.small { width: 38px; height: 38px; margin: 0; border-radius: 11px; }
.pfv-vault-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(275px, 1fr)); gap: 12px; }
.pfv-vault-card { display: grid; grid-template-columns: 40px minmax(0,1fr) auto; align-items: center; gap: 10px; background: var(--pfv-panel); border: 1px solid var(--pfv-border); border-radius: 14px; padding: 14px; }
.pfv-vault-card h3 { font-size: 14px; }
.pfv-vault-card span { color: var(--pfv-muted); font-size: 10px; }
.pfv-secret { display: flex; gap: 9px; align-items: stretch; }
.pfv-secret code { flex: 1; background: #07101d; border: 1px solid var(--pfv-border); border-radius: 10px; padding: 12px; color: #fff; overflow-wrap: anywhere; }

.pfv-import-layout { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(280px, .7fr); gap: 16px; }
.pfv-import-card, .pfv-import-notes { padding: 22px; }
.pfv-import-icon { width: 52px; height: 52px; display: grid; place-items: center; border-radius: 15px; color: #b9caff; background: rgba(92,143,255,.13); margin-bottom: 14px; }
.pfv-import-card > p, .pfv-import-notes p, .pfv-import-notes li { color: var(--pfv-muted); font-size: 12px; }
.pfv-import-types { display: flex; flex-wrap: wrap; gap: 7px; margin: 16px 0; }
.pfv-import-types span { border: 1px solid var(--pfv-border); border-radius: 999px; padding: 5px 9px; color: #c4d2e6; font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; }
.pfv-filedrop { display: block; border: 1px dashed #4d6d99; border-radius: 13px; padding: 22px; text-align: center; background: rgba(92,143,255,.04); margin-bottom: 12px; cursor: pointer; }
.pfv-filedrop input { display: none; }
.pfv-filedrop b, .pfv-filedrop span { display: block; }
.pfv-filedrop span { color: var(--pfv-muted); font-size: 10px; margin-top: 3px; }
.pfv-import-notes h3 { margin: 8px 0; }
.pfv-import-notes ul { padding-left: 19px; margin: 0 0 18px; }
.pfv-selected-files, .pfv-import-progress { display: grid; gap: 7px; margin: 12px 0; }
.pfv-selected-files > div, .pfv-import-step { display: flex; justify-content: space-between; gap: 10px; border: 1px solid var(--pfv-border); border-radius: 10px; padding: 10px; background: #0c1728; }
.pfv-selected-files span, .pfv-import-step small { color: var(--pfv-muted); font-size: 10px; }
.pfv-import-step { justify-content: flex-start; align-items: flex-start; }
.pfv-import-step.done { color: var(--pfv-green); }
.pfv-import-step b, .pfv-import-step small { display: block; }
.pfv-success-callout, .pfv-error-callout, .pfv-info-callout { display: grid; gap: 3px; border-radius: 11px; padding: 12px; margin-top: 10px; }
.pfv-success-callout { color: #9ce9ca; background: rgba(49,211,154,.1); border: 1px solid rgba(49,211,154,.25); }
.pfv-error-callout { color: #ffb0b8; background: rgba(255,111,125,.1); border: 1px solid rgba(255,111,125,.25); }
.pfv-info-callout { color: #c4d6f4; background: rgba(92,143,255,.09); border: 1px solid rgba(92,143,255,.23); }
.pfv-info-callout span { color: var(--pfv-muted); font-size: 11px; }

.pfv-modal { position: fixed; inset: 0; background: rgba(3,8,15,.72); backdrop-filter: blur(5px); display: flex; justify-content: flex-end; visibility: hidden; opacity: 0; z-index: 999999; transition: .2s ease; }
.pfv-modal.open { visibility: visible; opacity: 1; }
.pfv-dialog { width: min(560px, 100%); height: 100%; overflow-y: auto; background: #0f1a2c; border-left: 1px solid var(--pfv-border); padding: 22px; box-shadow: -20px 0 50px rgba(0,0,0,.34); transform: translateX(25px); transition: transform .2s ease; color: var(--pfv-text); }
.pfv-modal.open .pfv-dialog { transform: translateX(0); }
html.pfv-modal-open { overflow: hidden; }
.pfv-dialog-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 20px; padding-bottom: 15px; border-bottom: 1px solid var(--pfv-border); }
.pfv-dialog-head > div > span { color: var(--pfv-muted); font-size: 10px; text-transform: uppercase; letter-spacing: .07em; font-weight: 800; }
.pfv-dialog-head h2 { font-size: 23px; letter-spacing: -.03em; margin-top: 3px; }
.pfv-form { display: grid; gap: 14px; }
.pfv-form > label, .pfv-form-grid > label { display: grid; gap: 6px; color: #bfcbdd; font-size: 11px; font-weight: 800; }
.pfv-form-grid { display: grid; gap: 12px; }
.pfv-form-grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.pfv-form-section { border: 1px solid var(--pfv-border); border-radius: 12px; padding: 13px; background: rgba(0,0,0,.08); }
.pfv-form-section h3 { font-size: 12px; margin-bottom: 10px !important; }
.pfv-form-help { color: var(--pfv-muted) !important; font-size: 10px; margin-top: 8px !important; }
.pfv-check-row { display: flex; flex-wrap: wrap; gap: 10px 18px; }
.pfv-check-row.stacked { display: grid; }
.pfv-check-row label, .pfv-checkbox { display: flex !important; align-items: center; gap: 8px; color: #c8d5e7; font-size: 11px; cursor: pointer; }
.pfv-check-row input, .pfv-checkbox input, .pfv-radio-card input, .pfv-segmented input { width: auto !important; min-height: 0 !important; }
.pfv-dialog-actions { display: flex; justify-content: flex-end; gap: 9px; padding-top: 8px; }
.pfv-segmented { display: grid; grid-template-columns: 1fr 1fr; border: 1px solid var(--pfv-border); border-radius: 11px; padding: 4px; background: #091321; }
.pfv-segmented label { position: relative; }
.pfv-segmented input { position: absolute; opacity: 0; }
.pfv-segmented span { display: block; text-align: center; padding: 9px; border-radius: 8px; color: var(--pfv-muted); font-weight: 800; cursor: pointer; }
.pfv-segmented input:checked + span { background: var(--pfv-panel-2); color: #fff; box-shadow: 0 3px 10px rgba(0,0,0,.18); }
.pfv-presets { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.pfv-presets button { display: grid; gap: 2px; text-align: left; border: 1px solid var(--pfv-border); border-radius: 10px; padding: 9px 10px; background: #101c2f; color: var(--pfv-muted); font-size: 9px; }
.pfv-presets button b { color: #fff; font-size: 12px; }
.pfv-presets button:hover, .pfv-presets button.selected { border-color: var(--pfv-primary); background: rgba(92,143,255,.11); }
.pfv-radio-card { display: flex !important; align-items: flex-start; gap: 9px !important; padding: 9px; border: 1px solid var(--pfv-border); border-radius: 10px; margin-top: 7px; cursor: pointer; }
.pfv-radio-card b, .pfv-radio-card small { display: block; }
.pfv-radio-card small { color: var(--pfv-muted); font-size: 9px; }
.pfv-status-options { display: grid; gap: 8px; }
.pfv-status-choice { display: flex; align-items: center; gap: 10px; border: 1px solid var(--pfv-border); border-radius: 11px; padding: 12px; background: #101c2f; color: var(--pfv-muted); text-align: left; }
.pfv-status-choice.selected, .pfv-status-choice:hover { border-color: var(--pfv-primary); }

.pfv-empty { display: grid; gap: 6px; place-items: center; text-align: center; min-height: 220px; padding: 28px; color: var(--pfv-muted); }
.pfv-empty h2, .pfv-empty b { color: #fff; }
.pfv-empty.compact { min-height: 90px; }
.pfv-empty.compact span { font-size: 11px; }
.pfv-loading-state { min-height: 160px; display: flex; gap: 10px; align-items: center; justify-content: center; color: var(--pfv-muted); }
.pfv-spinner { width: 18px; height: 18px; border: 2px solid rgba(255,255,255,.16); border-top-color: var(--pfv-primary); border-radius: 50%; animation: pfv-spin .7s linear infinite; flex: 0 0 auto; }
@keyframes pfv-spin { to { transform: rotate(360deg); } }
.pfv-toast { position: fixed; right: 22px; bottom: 22px; z-index: 1000000; display: flex; align-items: center; gap: 9px; max-width: min(420px, calc(100vw - 30px)); background: #15243a; color: #fff; border: 1px solid #345276; border-radius: 12px; padding: 12px 15px; box-shadow: var(--pfv-shadow); transform: translateY(20px); opacity: 0; transition: .2s ease; font-family: inherit; }
.pfv-toast.show { transform: translateY(0); opacity: 1; }
.pfv-toast > span { width: 22px; height: 22px; display: grid; place-items: center; border-radius: 50%; background: rgba(49,211,154,.14); color: var(--pfv-green); font-weight: 900; }
.pfv-toast.bad { border-color: rgba(255,111,125,.45); }
.pfv-toast.bad > span { background: rgba(255,111,125,.14); color: var(--pfv-red); }
.pfv-login { width: min(420px, calc(100% - 32px)); margin: 80px auto; padding: 30px; text-align: center; }
.pfv-login p { color: var(--pfv-muted); margin: 8px 0 18px; }

@media (max-width: 1180px) {
  .pfv-dashboard-grid { grid-template-columns: 1.2fr .8fr; }
  .pfv-credit-card { grid-column: 1 / -1; }
  .pfv-two-column { grid-template-columns: 1fr; }
}

@media (max-width: 860px) {
  #pfv-app { border-radius: 0; min-height: 100vh; }
  .pfv-shell { grid-template-columns: 1fr; min-height: 100vh; }
  .pfv-sidebar { position: fixed; inset: 0 auto 0 0; width: 260px; transform: translateX(-105%); transition: transform .2s ease; box-shadow: 20px 0 50px rgba(0,0,0,.4); }
  .pfv-sidebar.open { transform: translateX(0); }
  .pfv-mobilebar { display: flex; align-items: center; gap: 10px; height: 58px; padding: 0 14px; border-bottom: 1px solid var(--pfv-border); background: #0c1728; position: sticky; top: 0; z-index: 15; }
  #pfv-main { padding: 18px 14px 28px; min-height: calc(100vh - 58px); }
  .pfv-dashboard-grid { grid-template-columns: 1fr; }
  .pfv-credit-card { grid-column: auto; }
  .pfv-summary-grid, .pfv-budget-overview { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pfv-toolbar { flex-wrap: wrap; }
  .pfv-account-filterbar { align-items: stretch; }
  .pfv-filter-tabs { width: 100%; }
  .pfv-filter-tabs button { flex: 1; justify-content: center; }
  .pfv-search { flex-basis: 100%; }
  .pfv-toolbar select { flex: 1; }
  .pfv-import-layout { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
  .pfv-pagehead { align-items: flex-start; flex-direction: column; }
  .pfv-head-actions { width: 100%; }
  .pfv-head-actions .pfv-button { flex: 1; }
  .pfv-balance-breakdown { grid-template-columns: 1fr; gap: 7px; }
  .pfv-balance-breakdown > div { border-left: 0; padding-left: 0; display: flex; justify-content: space-between; }
  .pfv-billrow { grid-template-columns: 44px minmax(0,1fr) auto; }
  .pfv-billamount { grid-column: 2; text-align: left; }
  .pfv-billrow > .pfv-button { grid-column: 3; grid-row: 1 / span 2; align-self: center; }
  .pfv-summary-grid, .pfv-budget-overview { grid-template-columns: 1fr; }
  .pfv-form-grid.two { grid-template-columns: 1fr; }
  .pfv-presets { grid-template-columns: 1fr 1fr; }
  .pfv-dialog { padding: 17px; }
  .pfv-dialog-actions { display: grid; grid-template-columns: 1fr 1fr; }
  .pfv-account-grid, .pfv-budget-list, .pfv-recurring-grid, .pfv-vault-grid { grid-template-columns: 1fr; }
  .pfv-schedule-chip { margin-left: 0; }
  .pfv-table th, .pfv-table td { padding: 10px; }
  .pfv-register-table td:nth-child(2) { min-width: 220px; }
}

/* Budget command center v1.2 */
.pfv-budget-month-nav { display: inline-flex; align-items: center; gap: 7px; padding: 5px; border: 1px solid var(--pfv-border); border-radius: 13px; background: rgba(10,20,36,.85); }
.pfv-budget-month-nav .reverse svg { transform: rotate(180deg); }
.pfv-budget-month-label { min-width: 132px; border: 0; background: transparent; color: var(--pfv-text); padding: 2px 8px; text-align: center; }
.pfv-budget-month-label b, .pfv-budget-month-label small { display: block; }
.pfv-budget-month-label b { font-size: 12px; }
.pfv-budget-month-label small { color: var(--pfv-muted); font-size: 9px; margin-top: 1px; }

.pfv-budget-hero-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 13px; margin-bottom: 15px; }
.pfv-budget-kpi { min-width: 0; padding: 18px; border: 1px solid var(--pfv-border); border-radius: 16px; background: linear-gradient(180deg, rgba(22,36,58,.96), rgba(15,27,46,.96)); position: relative; overflow: hidden; }
.pfv-budget-kpi::before { content: ''; position: absolute; inset: 0 auto 0 0; width: 4px; background: var(--pfv-primary); }
.pfv-budget-kpi.income::before { background: var(--pfv-green); }
.pfv-budget-kpi.bills::before { background: var(--pfv-amber); }
.pfv-budget-kpi.flex::before { background: var(--pfv-primary); }
.pfv-budget-kpi.leftover::before { background: var(--pfv-primary-2); }
.pfv-budget-kpi > span { display: block; color: var(--pfv-muted); font-size: 10px; font-weight: 900; text-transform: uppercase; letter-spacing: .075em; }
.pfv-budget-kpi strong { display: block; margin: 8px 0 4px; font-size: clamp(22px,2.2vw,31px); letter-spacing: -.04em; line-height: 1; }
.pfv-budget-kpi small { display: block; color: var(--pfv-muted); font-size: 10px; line-height: 1.35; }

.pfv-budget-alert { display: flex; align-items: center; justify-content: space-between; gap: 16px; border-radius: 14px; padding: 14px 16px; margin-bottom: 15px; }
.pfv-budget-alert.warning { border: 1px solid rgba(249,189,88,.32); background: rgba(249,189,88,.09); }
.pfv-budget-alert b, .pfv-budget-alert span { display: block; }
.pfv-budget-alert b { color: #ffd68d; font-size: 13px; }
.pfv-budget-alert span { color: var(--pfv-muted); font-size: 10px; margin-top: 3px; }

.pfv-budget-setup-strip { display: grid; grid-template-columns: minmax(250px,.8fr) minmax(500px,1.2fr); gap: 20px; align-items: center; padding: 18px; margin-bottom: 16px; border: 1px solid var(--pfv-border); border-radius: 16px; background: radial-gradient(circle at right, rgba(49,211,154,.07), transparent 35%), var(--pfv-panel); }
.pfv-budget-setup-strip.needs-setup { background: radial-gradient(circle at right, rgba(92,143,255,.11), transparent 38%), var(--pfv-panel); border-color: rgba(92,143,255,.3); }
.pfv-setup-eyebrow, .pfv-section-head > div:first-child > span { display: block; color: #91b4f7; font-size: 9px; font-weight: 900; text-transform: uppercase; letter-spacing: .09em; margin-bottom: 4px; }
.pfv-setup-copy h2 { font-size: 18px; }
.pfv-setup-copy p { color: var(--pfv-muted) !important; font-size: 11px; margin-top: 5px !important; max-width: 620px; }
.pfv-setup-checks { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 8px; }
.pfv-setup-check { width: 100%; min-width: 0; display: flex; align-items: center; gap: 9px; padding: 10px; border: 1px solid var(--pfv-border); border-radius: 11px; color: var(--pfv-text); background: #0d192b; text-align: left; }
.pfv-setup-check:not(:disabled):hover { border-color: #5375a4; transform: translateY(-1px); }
.pfv-setup-check > span { width: 28px; height: 28px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 9px; color: var(--pfv-green); background: rgba(49,211,154,.11); }
.pfv-setup-check.open > span { color: #9bb9ff; background: rgba(92,143,255,.12); }
.pfv-setup-check b, .pfv-setup-check small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pfv-setup-check b { font-size: 10px; }
.pfv-setup-check small { color: var(--pfv-muted); font-size: 8px; margin-top: 2px; }

.pfv-budget-section { margin-top: 16px; padding: 18px; border: 1px solid var(--pfv-border); border-radius: 17px; background: rgba(17,29,49,.84); }
.pfv-section-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 14px; }
.pfv-section-head h2 { font-size: 18px; line-height: 1.2; }
.pfv-section-head p { color: var(--pfv-muted) !important; font-size: 10px; margin-top: 4px !important; max-width: 720px; }
.pfv-section-total { min-width: 115px; padding: 9px 12px; border-radius: 11px; background: #0c1728; border: 1px solid var(--pfv-border); text-align: right; }
.pfv-section-total span, .pfv-section-total b { display: block; }
.pfv-section-total span { color: var(--pfv-muted); font-size: 9px; text-transform: uppercase; font-weight: 850; }
.pfv-section-total b { margin-top: 2px; font-size: 17px; }
.pfv-section-actions { display: flex; flex-wrap: wrap; gap: 8px; }

.pfv-budget-bills { display: grid; gap: 8px; }
.pfv-budget-bill { display: grid; grid-template-columns: minmax(250px,1.35fr) minmax(130px,.55fr) minmax(210px,.8fr) auto; gap: 14px; align-items: center; padding: 13px; border: 1px solid var(--pfv-border); border-radius: 13px; background: linear-gradient(180deg, rgba(22,36,58,.9), rgba(13,25,43,.94)); }
.pfv-budget-bill.funded { border-color: rgba(49,211,154,.28); }
.pfv-budget-bill.needs-amount { border-color: rgba(249,189,88,.33); }
.pfv-budget-bill-main { display: grid; grid-template-columns: 38px minmax(0,1fr); align-items: center; gap: 10px; min-width: 0; }
.pfv-budget-bill-name { display: flex; align-items: center; gap: 7px; min-width: 0; }
.pfv-budget-bill-name h3 { font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pfv-budget-bill-main p { color: var(--pfv-muted) !important; font-size: 9px; margin-top: 3px !important; }
.pfv-mini-badge { flex: 0 0 auto; display: inline-flex; padding: 3px 6px; border-radius: 999px; color: #8be7c5; background: rgba(49,211,154,.11); border: 1px solid rgba(49,211,154,.18); font-size: 7px; font-weight: 900; text-transform: uppercase; letter-spacing: .05em; }
.pfv-budget-bill-money span, .pfv-budget-bill-money strong, .pfv-budget-bill-money small { display: block; }
.pfv-budget-bill-money span { color: var(--pfv-muted); font-size: 8px; text-transform: uppercase; font-weight: 850; }
.pfv-budget-bill-money strong { margin: 3px 0; font-size: 16px; }
.pfv-budget-bill-money small { color: var(--pfv-muted); font-size: 8px; }
.pfv-budget-bill-progress > div:first-child { display: flex; justify-content: space-between; gap: 8px; font-size: 9px; }
.pfv-budget-bill-progress > div:first-child span { color: var(--pfv-muted); }
.pfv-budget-bill-progress .pfv-progress { margin: 6px 0 4px; height: 6px; }
.pfv-budget-bill-progress > small { display: block; color: var(--pfv-muted); font-size: 8px; }
.pfv-budget-bill-actions { display: flex; gap: 7px; }
.pfv-budget-bill-actions .pfv-button { min-height: 35px; padding: 7px 10px; font-size: 10px; }

.pfv-budget-rec-columns { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 14px; }
.pfv-budget-subhead { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.pfv-budget-subhead h3 { font-size: 13px; }
.pfv-budget-subhead b { font-size: 14px; }
.pfv-budget-rec { display: grid; grid-template-columns: 38px minmax(0,1fr) auto; gap: 10px; align-items: center; padding: 11px; margin-top: 7px; border: 1px solid var(--pfv-border); border-radius: 12px; background: #0d192b; }
.pfv-budget-rec .pfv-recurring-icon { width: 36px; height: 36px; border-radius: 10px; font-size: 18px; }
.pfv-budget-rec.income .pfv-recurring-icon { color: var(--pfv-green); background: rgba(49,211,154,.11); }
.pfv-budget-rec span, .pfv-budget-rec small { display: block; color: var(--pfv-muted); font-size: 8px; }
.pfv-budget-rec h3 { font-size: 12px; margin: 2px 0; }
.pfv-budget-rec > strong { font-size: 14px; white-space: nowrap; }
.pfv-budget-rec.income > strong { color: var(--pfv-green); }
.pfv-budget-placeholder { display: grid; gap: 3px; min-height: 70px; place-content: center; padding: 13px; border: 1px dashed #365071; border-radius: 12px; background: rgba(92,143,255,.025); text-align: center; }
.pfv-budget-placeholder b { font-size: 11px; }
.pfv-budget-placeholder span { color: var(--pfv-muted); font-size: 9px; }

.pfv-setup-summary { display: grid; gap: 7px; margin-bottom: 14px; }
.pfv-setup-summary > div { display: grid; grid-template-columns: 30px minmax(0,1fr); gap: 9px; align-items: center; padding: 9px 11px; border: 1px solid var(--pfv-border); border-radius: 11px; background: #0c1728; }
.pfv-setup-summary > div > span { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 9px; color: var(--pfv-green); background: rgba(49,211,154,.1); }
.pfv-setup-summary p b, .pfv-setup-summary p small { display: block; }
.pfv-setup-summary p b { font-size: 11px; }
.pfv-setup-summary p small { color: var(--pfv-muted); font-size: 9px; margin-top: 2px; }
.pfv-form-section-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.pfv-suggestion-list { display: grid; gap: 7px; margin-top: 10px; max-height: 330px; overflow: auto; padding-right: 3px; }
.pfv-suggestion-row { display: grid !important; grid-template-columns: 20px minmax(0,1fr) 145px; align-items: center; gap: 10px; margin: 0 !important; padding: 10px; border: 1px solid var(--pfv-border); border-radius: 11px; background: #0b1627; cursor: pointer; }
.pfv-suggestion-row > input { width: 16px !important; height: 16px; margin: 0 !important; }
.pfv-suggestion-row > span b, .pfv-suggestion-row > span small { display: block; }
.pfv-suggestion-row > span b { font-size: 11px; }
.pfv-suggestion-row > span small { color: var(--pfv-muted); font-size: 8px; margin-top: 2px; }
.pfv-suggestion-row > div span { display: block; color: var(--pfv-muted); font-size: 8px; margin-bottom: 3px; }
.pfv-suggestion-row > div input { margin: 0 !important; min-height: 35px !important; padding: 7px 9px !important; text-align: right; }
.pfv-button.danger { color: #ff9da6; border-color: rgba(255,111,125,.28); }

@media (max-width: 1180px) {
  .pfv-budget-hero-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .pfv-budget-setup-strip { grid-template-columns: 1fr; }
  .pfv-budget-bill { grid-template-columns: minmax(240px,1.2fr) minmax(130px,.55fr) minmax(190px,.8fr); }
  .pfv-budget-bill-actions { grid-column: 1 / -1; justify-content: flex-end; }
}
@media (max-width: 820px) {
  .pfv-budget-month-nav { width: 100%; justify-content: space-between; }
  .pfv-budget-month-label { flex: 1; }
  .pfv-setup-checks { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .pfv-budget-bill { grid-template-columns: 1fr 1fr; }
  .pfv-budget-bill-main { grid-column: 1 / -1; }
  .pfv-budget-bill-actions { grid-column: 1 / -1; }
  .pfv-budget-rec-columns { grid-template-columns: 1fr; }
  .pfv-section-head { flex-direction: column; }
}
@media (max-width: 540px) {
  .pfv-budget-hero-grid { grid-template-columns: 1fr; }
  .pfv-budget-alert { align-items: stretch; flex-direction: column; }
  .pfv-setup-checks { grid-template-columns: 1fr; }
  .pfv-budget-bill { grid-template-columns: 1fr; }
  .pfv-budget-bill-main, .pfv-budget-bill-actions { grid-column: auto; }
  .pfv-budget-bill-actions .pfv-button { flex: 1; }
  .pfv-suggestion-row { grid-template-columns: 20px minmax(0,1fr); }
  .pfv-suggestion-row > div { grid-column: 2; }
}
.pfv-unplanned-block { margin-top: 16px; padding-top: 15px; border-top: 1px solid var(--pfv-border); }
.pfv-unplanned-block .pfv-budget-subhead { align-items: flex-end; }
.pfv-unplanned-block .pfv-budget-subhead span { color: var(--pfv-muted); font-size: 9px; }
.pfv-unplanned-grid { display: grid; grid-template-columns: repeat(auto-fill,minmax(240px,1fr)); gap: 9px; }
.pfv-unplanned-card { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px; border: 1px solid rgba(249,189,88,.23); border-radius: 12px; background: rgba(249,189,88,.045); }
.pfv-unplanned-card span, .pfv-unplanned-card h3, .pfv-unplanned-card b { display: block; }
.pfv-unplanned-card span { color: #ffd38a; font-size: 8px; font-weight: 900; text-transform: uppercase; letter-spacing: .06em; }
.pfv-unplanned-card h3 { margin: 2px 0 !important; font-size: 12px; }
.pfv-unplanned-card b { font-size: 10px; color: var(--pfv-muted); }
.pfv-unplanned-card .pfv-button { min-height: 34px; padding: 7px 10px; font-size: 10px; }


/* Version 1.3.0: higher contrast, register bulk tools, sortable headers, and payee history autocomplete */
#pfv-app {
  --pfv-bg: #0a1321;
  --pfv-sidebar: #101d30;
  --pfv-panel: #182942;
  --pfv-panel-2: #223954;
  --pfv-border: #456382;
  --pfv-text: #ffffff;
  --pfv-muted: #c4d2e4;
  --pfv-primary: #5794ff;
  --pfv-primary-2: #8a70ff;
  --pfv-green: #45dfa9;
  --pfv-red: #ff7e8c;
  --pfv-amber: #ffd06f;
  color-scheme: dark;
}
.pfv-sidebar { background: linear-gradient(180deg, #12223a 0%, #0d192a 100%); }
.pfv-workspace { background: radial-gradient(circle at top right, rgba(87,148,255,.10), transparent 32%), var(--pfv-bg); }
.pfv-panel, .pfv-budget-section { background: rgba(24,41,66,.97); }
#pfv-app input, #pfv-app select, #pfv-app textarea,
.pfv-search, .pfv-filter-tabs { background: #101e32; border-color: #4a6889; color: #fff; }
#pfv-app input::placeholder, #pfv-app textarea::placeholder { color: #9eafc5; opacity: 1; }
#pfv-app select option { background: #f8fbff; color: #101827; }
#pfv-app input[type="date"]::-webkit-calendar-picker-indicator { filter: invert(1) brightness(1.5); opacity: .9; }
.pfv-table th { color: #f2f7ff; background: #1d314c; border-bottom-color: #577392; }
.pfv-table td { color: #f8fbff; }
.pfv-table td small { color: #b8c8db; }
.pfv-table tbody tr:nth-child(even) { background: rgba(255,255,255,.018); }
.pfv-table tbody tr:hover { background: rgba(87,148,255,.10); }
.pfv-summary-card, .pfv-account-card, .pfv-budget-card, .pfv-recurring-card { border-color: #456382; }
.pfv-button.secondary, .pfv-iconbtn { background: #27405e; }
.pfv-button.ghost { background: #172942; }
.pfv-status.cleared { color: #8ff3cf; background: rgba(69,223,169,.17); }
.pfv-status.posted { color: #bed3ff; background: rgba(87,148,255,.19); }
.pfv-status.pending { color: #ffe2a2; background: rgba(255,208,111,.17); }

.pfv-combobox { position: relative; }
.pfv-field-hint { display: block; margin-top: 6px; color: var(--pfv-muted) !important; font-size: 11px; line-height: 1.35; }
.pfv-payee-results { position: absolute; z-index: 120; top: calc(100% + 6px); left: 0; right: 0; max-height: 330px; overflow-y: auto; padding: 6px; border: 1px solid #5a7899; border-radius: 12px; background: #14243a; box-shadow: 0 22px 50px rgba(0,0,0,.48); }
.pfv-payee-results[hidden] { display: none !important; }
.pfv-payee-option { width: 100%; display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: 14px; padding: 11px 12px; border: 1px solid transparent; border-radius: 9px; background: transparent; color: #fff; text-align: left; }
.pfv-payee-option:hover, .pfv-payee-option.active { border-color: #6389b4; background: #223a58; }
.pfv-payee-option-main, .pfv-payee-option-amount { min-width: 0; }
.pfv-payee-option-main strong, .pfv-payee-option-main small, .pfv-payee-option-amount b, .pfv-payee-option-amount small { display: block; }
.pfv-payee-option-main strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
.pfv-payee-option-main small { margin-top: 3px; color: #b9c9dc; font-size: 10px; }
.pfv-payee-option-amount { text-align: right; white-space: nowrap; }
.pfv-payee-option-amount b { font-size: 13px; }
.pfv-payee-option-amount small { margin-top: 3px; color: #a9b9cd; font-size: 9px; }
.pfv-payee-empty { padding: 14px 12px; color: #c8d6e8; font-size: 11px; text-align: center; }
.pfv-payee-empty.error { color: #ffb1b9; }
.pfv-spinner.small { width: 14px; height: 14px; margin-right: 7px; vertical-align: -2px; }
.pfv-field-flash { animation: pfv-field-flash .85s ease; }
@keyframes pfv-field-flash { 0% { box-shadow: 0 0 0 0 rgba(69,223,169,.7); } 55% { box-shadow: 0 0 0 5px rgba(69,223,169,.18); border-color: var(--pfv-green); } 100% { box-shadow: none; } }

.pfv-bulkbar { display: none; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 10px; padding: 11px 13px; border-color: rgba(87,148,255,.55); background: linear-gradient(135deg, rgba(87,148,255,.17), rgba(138,112,255,.10)), #182942; }
.pfv-bulkbar.active { display: flex; }
.pfv-bulkbar > div:first-child b, .pfv-bulkbar > div:first-child span { display: block; }
.pfv-bulkbar > div:first-child b { font-size: 13px; }
.pfv-bulkbar > div:first-child span { margin-top: 2px; color: var(--pfv-muted); font-size: 10px; }
.pfv-bulk-actions { display: flex; align-items: center; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }
.pfv-bulk-actions .pfv-button { min-height: 34px; padding: 7px 10px; font-size: 11px; }
.pfv-select-col, .pfv-select-cell { width: 46px; min-width: 46px; text-align: center !important; }
.pfv-actions-col { width: 120px; }
.pfv-table-check { display: inline-flex !important; align-items: center; justify-content: center; margin: 0; cursor: pointer; }
.pfv-table-check input { position: absolute; opacity: 0; pointer-events: none; }
.pfv-table-check span { width: 19px; height: 19px; display: grid; place-items: center; border: 1px solid #7793b2; border-radius: 5px; background: #102036; transition: .14s ease; }
.pfv-table-check input:checked + span { border-color: var(--pfv-primary); background: var(--pfv-primary); box-shadow: 0 0 0 3px rgba(87,148,255,.15); }
.pfv-table-check input:checked + span::after { content: '✓'; color: #fff; font-size: 13px; font-weight: 900; line-height: 1; }
.pfv-table-check input:indeterminate + span { border-color: var(--pfv-primary); background: #355f9d; }
.pfv-table-check input:indeterminate + span::after { content: '−'; color: #fff; font-size: 14px; font-weight: 900; line-height: 1; }
.pfv-row-selected { background: rgba(87,148,255,.13) !important; box-shadow: inset 3px 0 0 var(--pfv-primary); }
.pfv-sort-button { width: 100%; display: inline-flex; align-items: center; justify-content: space-between; gap: 8px; border: 0; padding: 0; background: transparent; color: inherit; font: inherit; font-size: inherit; font-weight: inherit; letter-spacing: inherit; text-transform: inherit; white-space: nowrap; }
.pfv-sort-button b { min-width: 15px; color: #8fa5c1; font-size: 13px; }
.pfv-sort-button:hover, .pfv-sort-button.active { color: #fff; }
.pfv-sort-button.active b { color: #9fc0ff; }

@media (max-width: 780px) {
  .pfv-bulkbar { align-items: stretch; flex-direction: column; }
  .pfv-bulk-actions { justify-content: flex-start; }
  .pfv-bulk-actions .pfv-button { flex: 1; }
  .pfv-payee-results { position: fixed; left: 14px; right: 14px; top: auto; bottom: 14px; max-height: 45vh; }
}
