:root { --ink: #edf4ff; --muted: #aebdd0; --line: #2a3a50; --surface: #121d2d; --canvas: #0b1421; --accent: #4aa3ff; --positive: #58d69b; --negative: #ff8585; --field: #19283a; --soft: #263851; }
* { box-sizing: border-box; } body { margin: 0; background: var(--canvas); color: var(--ink); font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; } .page-shell { max-width: 1120px; margin: 0 auto; padding: 42px 24px 90px; } header { display: flex; justify-content: space-between; gap: 20px; align-items: start; margin-bottom: 8px; } .header-actions { display: flex; gap: 8px; } .header-actions form { margin: 0; } .eyebrow { color: var(--accent); font-size: .74rem; font-weight: 800; letter-spacing: .13em; margin: 0 0 6px; } .title-input { border: 0; background: transparent; color: var(--ink); font-size: clamp(1.9rem, 5vw, 3rem); font-weight: 750; letter-spacing: -.04em; padding: 0; width: min(680px, 100%); } .title-input:focus { outline: 2px solid var(--accent); border-radius: 6px; } button { border: 0; border-radius: 9px; background: var(--accent); color: white; cursor: pointer; font: inherit; font-weight: 700; padding: 11px 16px; } .quiet-button { background: var(--soft); color: var(--ink); } .month-label { color: var(--muted); font-weight: 700; margin: 0 0 20px; } .summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 22px; } .summary div, .budget-card { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 6px 20px rgba(28, 58, 89, .05); } .summary div { padding: 18px 20px; } .summary span { display: block; color: var(--muted); font-size: .84rem; font-weight: 700; margin-bottom: 5px; } .summary strong { font-size: 1.45rem; } .balance strong { color: var(--positive); } .budget-grid { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(280px, 1fr); gap: 20px; } .budget-card { padding: 22px; } .card-heading { display: flex; justify-content: space-between; gap: 16px; align-items: start; margin-bottom: 18px; } .card-heading h2 { margin: 0; font-size: 1.25rem; } .card-heading p { color: var(--muted); margin: 5px 0 0; font-size: .9rem; } .card-heading code { background: var(--field); border-radius: 4px; padding: 2px 4px; } .card-heading span { color: var(--muted); font-size: .85rem; white-space: nowrap; } .entry-list { display: grid; gap: 8px; } .entry-row { display: grid; grid-template-columns: minmax(0, 1fr) 140px 30px; gap: 8px; align-items: center; } input:not(.title-input) { border: 1px solid transparent; border-radius: 7px; background: var(--field); color: var(--ink); font: inherit; padding: 10px; width: 100%; } input:not(.title-input):focus { border-color: var(--accent); outline: 0; } .entry-amount { color: var(--negative) !important; text-align: right; font-variant-numeric: tabular-nums; } .income-card .entry-amount { color: var(--positive) !important; } .remove-row { background: transparent; color: var(--muted); font-size: 1.4rem; line-height: 1; padding: 5px 8px; } .remove-row:hover { color: var(--negative); } .add-button { margin-top: 16px; } .income-summary { display: flex; justify-content: space-between; border-top: 1px solid var(--line); margin-top: 20px; padding-top: 17px; color: var(--muted); font-weight: 700; } .income-summary strong { color: var(--positive); font-size: 1.35rem; } .month-tabs { position: fixed; bottom: 0; left: 0; right: 0; padding: 12px 16px; background: color-mix(in srgb, var(--canvas) 92%, transparent); backdrop-filter: blur(12px); border-top: 1px solid var(--line); } .month-tabs > div { max-width: 1120px; margin: 0 auto; display: grid; grid-template-columns: repeat(12, 1fr); gap: 6px; } .month-tabs button { background: var(--soft); color: var(--muted); padding: 9px 4px; font-size: .78rem; } .month-tabs button.active { background: var(--accent); color: white; }
@media (max-width: 780px) { .page-shell { padding: 28px 14px 96px; } .summary, .budget-grid { grid-template-columns: 1fr; } .budget-card { padding: 16px; } .card-heading { display: block; } .card-heading span { display: block; margin-top: 10px; } .header-actions { flex-wrap: wrap; justify-content: end; } .month-tabs { overflow-x: auto; } .month-tabs > div { min-width: 620px; } .entry-row { grid-template-columns: minmax(0, 1fr) 120px 36px; } }
@media (max-width: 540px) { body { -webkit-tap-highlight-color: transparent; } .page-shell { padding: calc(20px + env(safe-area-inset-top)) 14px calc(104px + env(safe-area-inset-bottom)); } header { align-items: stretch; flex-direction: column; gap: 16px; } .header-actions { width: 100%; } .header-actions > *, .header-actions button { flex: 1; } .header-actions button { min-height: 46px; } .title-input { font-size: 2rem; } .month-label { margin-bottom: 16px; } .summary { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; margin-bottom: 14px; } .summary div { padding: 14px; } .summary div:last-child { grid-column: 1 / -1; } .summary strong { font-size: 1.25rem; } .budget-grid { gap: 14px; } .budget-card { border-radius: 12px; padding: 15px; } .card-heading h2 { font-size: 1.15rem; } .entry-list { gap: 10px; } .entry-row { grid-template-columns: minmax(0, 1fr) 44px; gap: 7px; } .entry-name { grid-column: 1 / -1; } .entry-amount { min-height: 46px; font-size: 16px; } input:not(.title-input) { font-size: 16px; min-height: 46px; } .remove-row { align-self: stretch; min-height: 46px; padding: 0; } .add-button { min-height: 48px; width: 100%; } .month-tabs { padding: 10px max(12px, env(safe-area-inset-right)) calc(10px + env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left)); } .month-tabs > div { display: flex; gap: 7px; min-width: max-content; } .month-tabs button { flex: 0 0 52px; min-height: 42px; } }

.auth-page { align-items: center; background: radial-gradient(circle at 50% 25%, #172944 0, #0b1421 52%); display: grid; justify-items: center; min-height: 100vh; padding: 28px; }
.auth-shell { background: #21344b; border-radius: 24px; box-shadow: 0 30px 90px rgba(0, 0, 0, .34); display: grid; grid-template-columns: 1.06fr .94fr; max-width: 1060px; min-height: 610px; overflow: hidden; width: 100%; }
.auth-welcome { background: #101b2d; color: #f8fbff; display: flex; flex-direction: column; justify-content: space-between; min-height: 610px; overflow: hidden; padding: 34px 40px 30px; position: relative; }
.auth-welcome::after { background: radial-gradient(circle, rgba(90, 167, 255, .24), transparent 66%); content: ""; height: 340px; left: -100px; position: absolute; top: -80px; width: 340px; }
.piggy-bank { align-self: center; border-radius: 18px; display: block; height: 330px; object-fit: cover; object-position: center; position: relative; width: 330px; z-index: 1; }
.welcome-copy { position: relative; z-index: 1; }.welcome-copy .eyebrow { color: #7fc1ff; }.welcome-copy h1 { font-size: clamp(2rem, 4vw, 3.25rem); letter-spacing: -.055em; line-height: 1.02; margin: 0 0 14px; }.welcome-copy p:last-child { color: #bed0e4; line-height: 1.55; margin: 0; max-width: 340px; }
.auth-card { align-self: center; color: #edf4ff; padding: 48px; }.auth-card h2 { font-size: 2rem; letter-spacing: -.04em; margin: 0 0 10px; }.auth-card .intro { color: #bed0e4; line-height: 1.5; margin: 0 0 25px; }.auth-card label { color: #e6f0fb; display: block; font-size: .88rem; font-weight: 800; margin: 16px 0; }.auth-card input { background: #17283b; border: 1px solid #39516d; border-radius: 10px; color: #edf4ff; display: block; font-size: 16px; margin-top: 7px; min-height: 48px; padding: 11px 12px; width: 100%; }.auth-card input:focus { background: #1b3048; border-color: #74b7ff; box-shadow: 0 0 0 3px rgba(116, 183, 255, .18); outline: 0; }.auth-card form button { display: flex; justify-content: space-between; margin-top: 24px; min-height: 50px; width: 100%; }.auth-card form button span { font-size: 1.25rem; line-height: .8; }.auth-note { color: #b3c4d8; font-size: .78rem; line-height: 1.45; margin: 22px 0 0; text-align: center; }.error { background: #522c39; border-radius: 9px; color: #ffd8de; font-size: .9rem; padding: 11px; }
@media (max-width: 720px) { .auth-page { align-items: start; padding: 0; }.auth-shell { border-radius: 0; display: block; min-height: 100vh; }.auth-welcome { align-items: center; flex-direction: row; min-height: 250px; padding: calc(24px + env(safe-area-inset-top)) 24px 22px; }.piggy-bank { height: 190px; margin-right: -42px; width: 190px; }.welcome-copy h1 { font-size: 1.8rem; }.welcome-copy p:last-child { font-size: .88rem; }.auth-card { padding: 34px 24px calc(36px + env(safe-area-inset-bottom)); }.auth-card h2 { font-size: 1.8rem; } }

/* Simplified budget header and totals. */
header { align-items: center; margin-bottom: 18px; }
.month-label { font-size: .9rem; margin: 0; }
.summary { grid-template-columns: minmax(0, 1.65fr) minmax(280px, 1fr); gap: 20px; }
@media (max-width: 780px) { .summary { grid-template-columns: 1fr; } }
@media (max-width: 540px) { header { align-items: center; flex-direction: row; gap: 16px; } .header-actions { width: auto; } .header-actions > *, .header-actions button { flex: initial; } .header-actions button { min-height: 42px; } .month-label { margin: 0; } .summary { grid-template-columns: repeat(2, minmax(0, 1fr)); } .summary div:last-child { grid-column: auto; } }

/* Expense rows can be reordered with the mouse or touch handle. */
.entry-row { grid-template-columns: 28px minmax(0, 1fr) 140px 30px; }
.entry-row.dragging { opacity: .18; }
.entry-row.drop-target { box-shadow: 0 -2px 0 var(--accent); }
.drag-preview { background: var(--surface); border: 1px solid var(--accent); border-radius: 9px; box-shadow: 0 14px 28px rgba(0, 0, 0, .38); opacity: .96; pointer-events: none; position: fixed; transform: scale(1.015); z-index: 20; }
.drag-handle { align-self: stretch; background: transparent; border: 1px solid var(--line); color: var(--muted); cursor: grab; font-size: 1rem; letter-spacing: -2px; padding: 0; touch-action: none; user-select: none; }
.drag-handle:active { cursor: grabbing; }
.drag-hint { color: var(--accent); display: inline !important; font-weight: 900; letter-spacing: -2px; white-space: normal; }
.income-card .entry-row { grid-template-columns: minmax(0, 1fr) 140px 30px; }
@media (max-width: 780px) { .entry-row { grid-template-columns: 28px minmax(0, 1fr) 120px 36px; } .income-card .entry-row { grid-template-columns: minmax(0, 1fr) 120px 36px; } }
@media (max-width: 540px) { .entry-row { grid-template-columns: 28px minmax(0, 1fr) 44px; } .drag-handle { grid-row: span 2; min-height: 99px; } .entry-name { grid-column: 2 / -1; } .entry-amount { grid-column: 2; } .remove-row { grid-column: 3; } .income-card .entry-row { grid-template-columns: minmax(0, 1fr) 44px; } .income-card .entry-name { grid-column: 1 / -1; } .income-card .entry-amount { grid-column: 1; } .income-card .remove-row { grid-column: 2; } }
