@import url("https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;450;500;550;600;650;700&family=Manrope:wght@400;500;600;650;700;750;800&display=swap");
:root {
  --bg: #f8f7f4;
  --surface: #fffefa;
  --ink: #292c25;
  --muted: #77796f;
  --line: #e7e6de;
  --accent: #bd5132;
  --accent-soft: #f7e9e0;
  --sage: #eaf0e4;
  --green: #637c50;
  --amber: #a16b12;
  --amber-bg: #fbf0da;
  --red: #b54c35;
  --shadow: 0 8px 30px -16px #3c402926;
  color-scheme: light;
}
[data-theme="dark"] {
  --bg: #1f241f;
  --surface: #282e26;
  --ink: #f0efe6;
  --muted: #b1b6a8;
  --line: #3c4438;
  --accent: #f0ad8a;
  --accent-soft: #413429;
  --sage: #35432e;
  --green: #b2cd95;
  --amber: #eac077;
  --amber-bg: #423b28;
  --red: #f2a18d;
  --shadow: none;
  color-scheme: dark;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font:
    14px/1.6 "DM Sans",
    sans-serif;
  -webkit-font-smoothing: antialiased;
}
button,
input,
select {
  font: inherit;
}
button,
a,
input,
select {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
  color: inherit;
}
button:disabled {
  cursor: wait;
  opacity: 0.6;
}
button,
a {
  touch-action: manipulation;
}
a {
  color: inherit;
  text-decoration: none;
}
h1,
h2,
h3,
p {
  margin: 0;
}
h1,
h2,
h3 {
  font-family: "Manrope", sans-serif;
}
h1 {
  font-size: 42px;
  line-height: 1.2;
  letter-spacing: -1.8px;
  font-weight: 650;
}
h2 {
  font-size: 17px;
  letter-spacing: -0.5px;
  font-weight: 700;
}
h3 {
  font-size: 16px;
  letter-spacing: -0.3px;
}
svg {
  width: 21px;
  height: 21px;
  display: block;
  flex-shrink: 0;
}
button svg {
  pointer-events: none;
}
button {
  border: 0;
  background: none;
}
input,
select {
  min-width: 0;
  accent-color: var(--accent);
}
button,
input,
select,
a {
  outline-offset: 4px;
}
:focus-visible {
  outline: 2px solid var(--accent);
}
::selection {
  background: #efc8ad;
  color: #292c25;
}
[hidden] {
  display: none !important;
}
.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;
}
.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  transform: translateY(-180%);
  background: var(--ink);
  color: var(--bg);
  padding: 10px 20px;
  z-index: 100;
}
.skip-link:focus {
  transform: none;
}
.app-header {
  height: 88px;
  display: flex;
  align-items: center;
  gap: 30px;
  max-width: 1320px;
  margin: auto;
  padding: 0 48px;
  border-bottom: 1px solid var(--line);
}
.brand {
  display: inline-flex;
  align-items: center;
  font-family: "Manrope", sans-serif;
  font-weight: 800;
  font-size: 27px;
  letter-spacing: -1.2px;
  white-space: nowrap;
}
.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  background: #c65838;
  color: #fff8ed;
  font:
    500 34px/1 "DM Sans",
    sans-serif;
  border-radius: 11px;
  margin-right: 10px;
  transform: rotate(-8deg);
  padding-bottom: 4px;
}
.brand-dot {
  color: var(--accent);
}
.header-tagline {
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.1px;
}
.header-tools {
  display: flex;
  align-items: center;
  gap: 13px;
  margin-left: auto;
}
.icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  color: var(--muted);
  flex-shrink: 0;
  transition: background 0.2s;
}
.icon-button:hover {
  background: var(--line);
  color: var(--ink);
}
.avatar {
  width: 36px;
  height: 36px;
  border: 1px solid #d9d5c8;
  border-radius: 50%;
  background: #ece6d7;
  color: #6f6855;
  font-size: 12px;
  font-weight: 700;
}
.dashboard {
  max-width: 1224px;
  margin: auto;
  padding: 48px 48px 160px;
}
.page-intro {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 43px;
}
.eyebrow {
  font-size: 9px;
  font-weight: 650;
  letter-spacing: 1.7px;
  color: var(--accent);
  margin-bottom: 13px;
}
.page-intro h1 span {
  color: var(--accent);
}
.intro-copy {
  color: var(--muted);
  margin-top: 12px;
  font-size: 13px;
}
.intro-copy strong {
  color: var(--ink);
  font-weight: 600;
}
.month-stamp {
  display: flex;
  align-items: center;
  gap: 9px;
  border: 1px solid var(--line);
  border-radius: 100px;
  padding: 9px 15px;
  white-space: nowrap;
  background: var(--surface);
  font-size: 11px;
  color: var(--muted);
}
.month-stamp svg {
  width: 16px;
  height: 16px;
}
.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  margin-bottom: 20px;
}
.heading-inline {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.text-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  color: var(--muted);
  font-size: 11px;
  min-height: 40px;
  padding: 5px 0;
}
.text-button svg {
  width: 16px;
  height: 16px;
}
.text-button:hover {
  color: var(--accent);
}
.caps-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 15px;
}
.cap-card {
  position: relative;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 17px;
  padding: 21px 20px 17px;
  min-width: 0;
  box-shadow: 0 3px 5px #2f331901;
}
.cap-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}
.category-icon {
  width: 39px;
  height: 39px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  font-size: 19px;
  background: #f4e5d8;
}
.tone-sage {
  background: #e8ecdf;
}
.tone-blue {
  background: #e3ebef;
}
.tone-lavender {
  background: #eee6f3;
}
.cap-edit {
  width: 30px;
  height: 30px;
}
.cap-edit svg {
  width: 15px;
  height: 15px;
}
.cap-name {
  font-size: 12px;
  font-weight: 550;
  margin-bottom: 6px;
}
.cap-amount {
  font-family: "Manrope", sans-serif;
  font-size: 25px;
  letter-spacing: -1px;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
  line-height: 1.5;
}
.cap-amount small {
  font-family: "DM Sans", sans-serif;
  font-weight: 400;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0;
  white-space: nowrap;
}
.cap-track {
  height: 5px;
  background: var(--line);
  border-radius: 20px;
  margin: 18px 0 11px;
  overflow: hidden;
}
.cap-track > span {
  display: block;
  height: 100%;
  border-radius: 20px;
  background: #91a77c;
  transition: width 0.35s;
}
.cap-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 10px;
  color: var(--muted);
}
.cap-bottom strong {
  font-weight: 500;
  color: var(--green);
}
.cap-card[data-state="near"] .cap-track > span {
  background: #d4a14c;
}
.cap-card[data-state="near"] .cap-bottom strong {
  color: var(--amber);
}
.cap-card[data-state="over"] .cap-track > span {
  background: #ca755a;
}
.cap-card[data-state="over"] .cap-bottom strong {
  color: var(--red);
}
.cap-flex {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}
.cap-flex p {
  font-size: 10px;
  color: var(--muted);
  margin-bottom: 7px;
}
.cap-flex-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.cap-flex button {
  padding: 6px 8px;
  font-size: 10px;
  min-height: 32px;
  border: 1px solid var(--line);
  border-radius: 7px;
}
.cap-flex button:first-child {
  color: var(--accent);
  background: var(--accent-soft);
}
.streak {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 9px;
  font-weight: 500;
  color: var(--green);
  background: var(--sage);
  padding: 4px 8px;
  border-radius: 20px;
}
.streak-celebrate {
  animation: reward 0.5s ease-out;
}
.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr);
  gap: 38px;
  margin-top: 42px;
}
.count-badge {
  font-family: "DM Sans", sans-serif;
  color: var(--muted);
  border: 1px solid var(--line);
  padding: 1px 6px;
  font-size: 10px;
  border-radius: 6px;
}
.spend-feed {
  border-top: 1px solid var(--line);
}
.spend-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}
.merchant-icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--surface);
  border: 1px solid var(--line);
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  flex-shrink: 0;
}
.spend-info {
  min-width: 0;
  flex: 1;
}
.spend-info strong {
  display: block;
  font-size: 12px;
  font-weight: 550;
  overflow-wrap: anywhere;
}
.spend-info p {
  font-size: 10px;
  color: var(--muted);
  margin-top: 3px;
}
.spend-amount {
  font-family: "Manrope", sans-serif;
  font-size: 13px;
  font-weight: 650;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.spend-row .icon-button {
  width: 32px;
  height: 36px;
}
.spend-row .icon-button svg {
  width: 15px;
  height: 15px;
}
.day-label {
  font-size: 9px;
  color: var(--muted);
  letter-spacing: 1px;
  padding: 16px 0 0;
}
.quiet-label {
  font-size: 8px;
  color: var(--muted);
  letter-spacing: 1px;
}
.pace-card {
  background: #eeeee6;
  border: 1px solid #e3e5d9;
  border-radius: 17px;
  padding: 25px;
}
.pace-card-top {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 19px;
}
.spark {
  font-size: 29px;
  line-height: 1;
  color: #82946e;
}
.pace-select {
  border: 0;
  border-bottom: 1px solid #cdd2be;
  background: transparent;
  color: var(--ink);
  font-size: 11px;
  padding: 7px 22px 7px 0;
  max-width: 100%;
  cursor: pointer;
}
.pace-message {
  font-family: "Manrope", sans-serif;
  font-size: 24px;
  line-height: 1.4;
  font-weight: 500;
  letter-spacing: -0.8px;
  margin: 16px 0 10px;
  text-wrap: balance;
}
.muted {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.75;
}
.spending-chart {
  height: 92px;
  display: flex;
  align-items: flex-end;
  gap: 4px;
  position: relative;
  margin-top: 28px;
  border-bottom: 1px solid #d0d6c2;
}
.chart-bar {
  flex: 1;
  min-width: 0;
  background: #bac7a7;
  border-radius: 2px 2px 0 0;
  min-height: 2px;
}
.chart-bar:last-child {
  background: #7e9268;
}
.chart-cap-line {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  border-top: 1px dashed #8e9b7e;
}
.chart-cap-line span {
  position: absolute;
  right: 0;
  top: -18px;
  color: var(--muted);
  font-size: 8px;
}
.chart-axis {
  display: flex;
  justify-content: space-between;
  font-size: 8px;
  color: var(--muted);
  padding-top: 8px;
}
.pace-footnote {
  display: flex;
  gap: 6px;
  align-items: center;
  font-size: 9px;
  color: var(--muted);
  border-top: 1px solid #d8ddcc;
  margin-top: 22px;
  padding-top: 15px;
}
.pace-footnote svg {
  width: 13px;
  height: 13px;
}
.gentle-note {
  font-size: 10px;
  line-height: 1.9;
  color: var(--muted);
  text-align: center;
  margin: 20px 0;
}
.workspace-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  font-size: 10px;
  color: var(--muted);
  margin-top: 43px;
}
.mini-mark {
  color: var(--accent);
  font-size: 20px;
}
.capture-dock {
  position: fixed;
  z-index: 20;
  bottom: max(21px, env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%);
  width: min(740px, calc(100% - 36px));
}
.magic-form {
  display: flex;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: 0 10px 45px #343a2320;
  border-radius: 18px;
  padding: 10px;
}
.magic-form input {
  flex: 1;
  min-width: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  font-size: 13px;
  outline: none;
  height: 40px;
}
.magic-form:focus-within {
  border-color: #c9b7a0;
  box-shadow:
    0 10px 45px #343a2320,
    0 0 0 3px #c9b7a020;
}
.magic-form input::placeholder {
  color: var(--muted);
}
.camera-button {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  border-radius: 12px;
  background: var(--accent-soft);
  color: var(--accent);
}
.send-button {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--surface);
  flex-shrink: 0;
}
.send-button svg {
  width: 18px;
  height: 18px;
}
.dock-divider {
  width: 1px;
  height: 25px;
  background: var(--line);
}
.manual-button {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 10px;
  white-space: nowrap;
  padding: 0 10px;
  min-height: 42px;
}
.manual-button svg {
  width: 16px;
  height: 16px;
}
.capture-dock > p {
  text-align: center;
  font-size: 9px;
  color: var(--muted);
  margin-top: 9px;
}
.capture-dock.is-busy .camera-button svg {
  animation: reward 0.7s infinite alternate;
}
.search-input {
  width: 100%;
  border: 1px solid var(--line);
  background: var(--surface);
  padding: 12px;
  border-radius: 10px;
  color: var(--ink);
  margin-bottom: 15px;
}
.show-more {
  display: flex;
  margin: 10px auto;
}
.connection-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 20px;
  padding: 90px 20px;
  color: var(--muted);
}
.loading-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse 1s infinite alternate;
}
.notice {
  font-size: 12px;
  background: var(--amber-bg);
  padding: 15px 20px;
  border-radius: 12px;
  margin-bottom: 25px;
}
.empty-state {
  padding: 48px 20px;
  text-align: center;
  border: 1px dashed var(--line);
  border-radius: 16px;
}
.empty-state .empty-symbol {
  font-size: 32px;
  color: var(--green);
  margin-bottom: 12px;
}
.empty-state h3 {
  font-size: 17px;
  margin-bottom: 8px;
}
.empty-state p {
  font-size: 12px;
  color: var(--muted);
  max-width: 300px;
  margin: 0 auto 20px;
}
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 46px;
  padding: 11px 22px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 12px;
  font-weight: 600;
  transition:
    transform 0.2s,
    background 0.2s;
}
.button:hover {
  transform: translateY(-1px);
}
.button-primary {
  background: #bd5132;
  color: #fff8f0;
  border-color: #bd5132;
}
.button-quiet {
  background: var(--bg);
}
.button-full {
  width: 100%;
}
.button-danger {
  color: var(--red);
}
.sheet {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  border-radius: 23px;
  width: min(480px, calc(100vw - 32px));
  max-height: calc(100dvh - 48px);
  padding: 28px;
  box-shadow: 0 30px 100px #161f1830;
  overscroll-behavior: contain;
}
.sheet::backdrop {
  background: #222b245e;
  backdrop-filter: blur(5px);
}
.sheet[open] {
  animation: sheet-in 0.2s ease-out;
}
.sheet-header {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 15px;
  margin-bottom: 24px;
}
.sheet-header .eyebrow {
  font-size: 8px;
  margin-bottom: 9px;
}
.sheet-header h2 {
  font-size: 25px;
  letter-spacing: -0.8px;
}
.sheet-header .icon-button {
  margin: -8px -8px 0 0;
}
.sheet-body-copy {
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 20px;
}
.form-field {
  display: block;
  margin-bottom: 18px;
}
.form-label {
  display: block;
  font-size: 11px;
  font-weight: 550;
  margin-bottom: 7px;
}
.field-input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px;
  background: var(--bg);
  color: var(--ink);
  min-height: 45px;
}
.amount-entry {
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid var(--line);
  padding: 8px 0 15px;
  margin-bottom: 22px;
}
.amount-entry > span {
  font-size: 29px;
  color: var(--muted);
}
.amount-entry input {
  width: 100%;
  font-family: "Manrope", sans-serif;
  font-size: 43px;
  font-weight: 600;
  letter-spacing: -1.5px;
  border: 0;
  background: none;
  color: var(--ink);
  outline: none;
}
.chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 9px 0 22px;
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--line);
  border-radius: 100px;
  padding: 9px 13px;
  min-height: 42px;
  font-size: 11px;
  background: var(--surface);
}
.chip[aria-pressed="true"] {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--accent);
}
.cap-setup-row {
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid var(--line);
  padding: 14px 0;
}
.cap-setup-row > span {
  font-size: 11px;
  flex: 1;
}
.cap-setup-row input {
  width: 105px;
  text-align: right;
  padding: 8px;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--bg);
  color: var(--ink);
  font-size: 14px;
}
.setup-rows {
  margin-bottom: 25px;
}
.field-error {
  font-size: 12px;
  color: var(--red);
  padding: 10px 0;
}
.sheet-actions {
  display: flex;
  gap: 10px;
  margin-top: 20px;
}
.sheet-actions > * {
  flex: 1;
}
.sheet-hint {
  font-size: 10px;
  color: var(--muted);
  text-align: center;
  margin-top: 13px;
}
.upload-zone {
  border: 1px dashed #b6bfaa;
  background: var(--bg);
  border-radius: 14px;
  padding: 30px 18px;
  text-align: center;
}
.upload-zone.is-dragging {
  background: var(--sage);
  border-color: var(--green);
}
.upload-zone > svg {
  margin: 0 auto 15px;
  width: 32px;
  height: 32px;
  color: var(--green);
}
.upload-zone h3 {
  font-size: 16px;
}
.upload-zone p {
  font-size: 11px;
  color: var(--muted);
  margin: 10px 0 20px;
}
.upload-buttons {
  display: flex;
  justify-content: center;
  gap: 10px;
}
.upload-buttons .button {
  font-size: 11px;
  padding: 10px 14px;
}
.receipt-preview {
  display: block;
  max-height: 200px;
  max-width: 100%;
  border-radius: 10px;
  margin: 0 auto 18px;
  object-fit: contain;
}
.account-email {
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 22px;
  overflow-wrap: anywhere;
}
.account-actions {
  display: grid;
  gap: 10px;
}
.flex-summary {
  display: flex;
  justify-content: space-between;
  background: var(--bg);
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 20px;
  font-size: 12px;
}
.flex-summary strong {
  font-size: 20px;
}
.toast {
  position: fixed;
  z-index: 100;
  left: 50%;
  bottom: 130px;
  transform: translateX(-50%);
  background: var(--ink);
  color: var(--bg);
  border-radius: 12px;
  box-shadow: var(--shadow);
  max-width: calc(100vw - 32px);
  width: max-content;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px 16px;
  font-size: 12px;
}
.toast button {
  color: inherit;
  font-weight: 600;
  min-height: 32px;
  flex-shrink: 0;
}
.toast #toast-action {
  color: #efba91;
  text-decoration: underline;
  text-underline-offset: 4px;
}
.toast #toast-close {
  font-size: 20px;
  opacity: 0.6;
}
.toast > span {
  overflow-wrap: anywhere;
}
.inline-status {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 11px;
  margin-top: 14px;
  color: var(--muted);
}
.welcome-page {
  min-height: 100dvh;
}
.welcome-main {
  width: min(1140px, calc(100% - 80px));
  margin: 70px auto 80px;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  align-items: center;
  gap: 70px;
}
.welcome-main h1 {
  font-size: clamp(50px, 5.7vw, 77px);
  letter-spacing: -3.8px;
  line-height: 1.12;
}
.welcome-main h1 em {
  font-family: Georgia, serif;
  font-weight: 400;
  color: var(--accent);
}
.welcome-description {
  font-size: 15px;
  color: var(--muted);
  max-width: 370px;
  margin: 25px 0;
  line-height: 1.9;
}
.welcome-actions {
  display: flex;
  align-items: center;
  gap: 22px;
}
.welcome-actions .button {
  border-radius: 100px;
  padding-inline: 26px;
}
.welcome-small {
  font-size: 10px;
  color: var(--muted);
  margin-top: 22px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.welcome-small svg {
  width: 15px;
  height: 15px;
}
.welcome-preview {
  position: relative;
  background: #edece2;
  border: 1px solid #e2e0d1;
  padding: 30px;
  border-radius: 24px;
  transform: rotate(-2deg);
}
.welcome-preview::after {
  content: "✳";
  position: absolute;
  right: -23px;
  top: -47px;
  color: #bc7050;
  font-size: 85px;
}
.preview-label {
  font-size: 9px;
  letter-spacing: 1.1px;
  color: #77796f;
  margin-bottom: 22px;
  display: flex;
  justify-content: space-between;
}
.welcome-preview h2 {
  font-size: 23px;
  letter-spacing: -0.8px;
  margin-bottom: 20px;
}
.preview-caps {
  display: grid;
  gap: 12px;
}
.preview-caps .cap-card {
  background: #fffefa;
  color: #292c25;
  border-color: #e7e6de;
}
.preview-caps .cap-top {
  margin-bottom: 12px;
}
.preview-caps .cap-top > strong {
  margin-right: auto;
  margin-left: 12px;
  font-size: 12px;
}
.preview-caps .cap-amount {
  font-size: 19px;
}
.preview-caps .cap-track {
  margin-top: 12px;
}
.preview-capture {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #fffefa;
  border: 1px solid #e7e6de;
  padding: 15px;
  border-radius: 13px;
  font-size: 11px;
  color: #77796f;
  margin-top: 20px;
}
.preview-capture svg {
  color: #bd5132;
}
.preview-capture svg:last-child {
  margin-left: auto;
}
.welcome-principles {
  width: min(1140px, calc(100% - 80px));
  margin: 0 auto 45px;
  border-top: 1px solid var(--line);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 45px;
  padding-top: 38px;
}
.welcome-principles article > span {
  color: var(--accent);
  font-size: 11px;
}
.welcome-principles h3 {
  margin: 12px 0 8px;
  font-size: 17px;
}
.welcome-principles p {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.8;
  max-width: 280px;
}
.site-footer {
  max-width: 1140px;
  margin: 30px auto;
  padding: 20px 0;
  color: var(--muted);
  font-size: 10px;
  display: flex;
  justify-content: space-between;
  gap: 20px;
}
.auth-main {
  display: grid;
  grid-template-columns: 1fr 430px;
  gap: 90px;
  align-items: center;
  max-width: 1050px;
  margin: 60px auto;
  padding: 0 30px;
}
.auth-story h1 {
  font-size: 52px;
  letter-spacing: -2.5px;
  line-height: 1.2;
}
.auth-story h1 em {
  color: var(--accent);
  font-family: Georgia, serif;
  font-weight: 400;
}
.auth-story > p {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.9;
  margin-top: 20px;
  max-width: 310px;
}
.auth-story .spark {
  color: var(--accent);
  display: block;
  font-size: 65px;
  margin-bottom: 30px;
}
.auth-card {
  padding: 32px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 22px;
  box-shadow: var(--shadow);
}
.auth-card h2 {
  font-size: 26px;
  margin-bottom: 8px;
}
.auth-card > p {
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 25px;
}
.auth-card .form-field {
  margin-bottom: 16px;
}
.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font-size: 10px;
  margin: 20px 0;
}
.auth-divider::before,
.auth-divider::after {
  content: "";
  height: 1px;
  background: var(--line);
  flex: 1;
}
.auth-switch {
  text-align: center;
  font-size: 11px !important;
  margin-top: 25px;
  margin-bottom: 0 !important;
}
.auth-switch a {
  color: var(--accent);
  font-weight: 600;
}
.auth-helper {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.auth-helper .text-button {
  min-height: 28px;
  font-size: 10px;
}
.google-g {
  font-weight: 700;
  font-size: 18px;
  color: #4285f4;
}
.onboarding-intro {
  text-align: center;
}
.onboarding-intro .spark {
  display: block;
  font-size: 50px;
  color: var(--accent);
  margin-bottom: 15px;
}
.onboarding-intro p {
  font-size: 12px;
  color: var(--muted);
  margin: 12px 0 20px;
}
[data-theme="dark"] .pace-card {
  background: #303a2b;
  border-color: #424c39;
}
[data-theme="dark"] .pace-footnote {
  border-color: #4b563e;
}
[data-theme="dark"] .category-icon {
  background: #4c3c2c;
}
[data-theme="dark"] .tone-sage {
  background: #3d4b31;
}
[data-theme="dark"] .tone-blue {
  background: #334550;
}
[data-theme="dark"] .tone-lavender {
  background: #46394d;
}
[data-theme="dark"] .welcome-preview {
  background: #323c2d;
  border-color: #434d3a;
}
[data-theme="dark"] .welcome-preview h2 {
  color: #f0efe6;
}
[data-theme="dark"] .preview-label {
  color: #b9bfac;
}
@keyframes sheet-in {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes pulse {
  to {
    opacity: 0.3;
  }
}
@keyframes reward {
  50% {
    transform: scale(1.08);
  }
}
@media (min-width: 1400px) {
  .dashboard {
    padding-top: 58px;
  }
  .page-intro {
    margin-bottom: 48px;
  }
}
@media (max-width: 1050px) {
  .app-header {
    padding-inline: 32px;
  }
  .dashboard {
    padding-inline: 32px;
  }
  .caps-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .content-grid {
    gap: 26px;
  }
  .header-tagline {
    display: none;
  }
  .cap-top {
    margin-bottom: 16px;
  }
  .welcome-main {
    gap: 40px;
  }
  .welcome-main h1 {
    font-size: 58px;
  }
  .auth-main {
    gap: 45px;
    grid-template-columns: 1fr 400px;
  }
  .auth-story h1 {
    font-size: 45px;
  }
  .site-footer {
    margin-inline: 40px;
  }
}
@media (max-width: 767px) {
  .app-header {
    height: 73px;
    padding-inline: 22px;
  }
  .brand {
    font-size: 24px;
  }
  .brand-mark {
    width: 30px;
    height: 30px;
    font-size: 30px;
  }
  .header-tools {
    gap: 7px;
  }
  .dashboard {
    padding: 32px 22px 150px;
  }
  .page-intro {
    align-items: start;
    flex-direction: column;
    gap: 18px;
    margin-bottom: 28px;
  }
  .page-intro h1 {
    font-size: 33px;
    letter-spacing: -1.4px;
  }
  .eyebrow {
    font-size: 8px;
    margin-bottom: 12px;
  }
  .intro-copy {
    font-size: 12px;
  }
  .month-stamp {
    font-size: 10px;
    padding: 6px 12px;
  }
  .section-heading {
    margin-bottom: 14px;
    gap: 10px;
  }
  .section-heading h2 {
    font-size: 16px;
  }
  .text-button {
    font-size: 10px;
    gap: 5px;
  }
  .heading-inline {
    gap: 7px;
  }
  .caps-grid {
    gap: 11px;
  }
  .cap-card {
    border-radius: 15px;
    padding: 16px 14px;
  }
  .cap-top {
    margin-bottom: 17px;
  }
  .category-icon {
    width: 34px;
    height: 34px;
    font-size: 17px;
    border-radius: 10px;
  }
  .cap-amount {
    font-size: 23px;
  }
  .cap-amount small {
    display: block;
    font-size: 10px;
    margin-top: 2px;
  }
  .cap-name {
    font-size: 11px;
  }
  .cap-track {
    margin-top: 15px;
  }
  .cap-bottom {
    font-size: 9px;
    flex-wrap: wrap;
    gap: 3px;
  }
  .content-grid {
    grid-template-columns: 1fr;
    gap: 30px;
    margin-top: 30px;
  }
  .pace-section {
    order: 0;
  }
  .pace-card {
    padding: 22px;
  }
  .pace-message {
    font-size: 24px;
    max-width: 300px;
  }
  .spend-row {
    padding: 15px 0;
    gap: 10px;
  }
  .spend-info strong {
    font-size: 12px;
  }
  .spend-row .icon-button {
    width: 30px;
    min-height: 44px;
  }
  .spend-amount {
    font-size: 12px;
  }
  .gentle-note {
    font-size: 10px;
  }
  .capture-dock {
    bottom: calc(10px + env(safe-area-inset-bottom));
    width: calc(100% - 24px);
  }
  .magic-form {
    padding: 8px;
    gap: 8px;
    border-radius: 15px;
  }
  .magic-form input {
    font-size: 16px;
    height: 42px;
  }
  .camera-button {
    width: 41px;
    height: 43px;
    border-radius: 10px;
  }
  .send-button {
    width: 32px;
    height: 32px;
  }
  .manual-button {
    padding: 0 3px;
    min-width: 30px;
  }
  .manual-button > span:last-child {
    display: none;
  }
  .manual-button svg {
    width: 20px;
    height: 20px;
  }
  .dock-divider {
    height: 22px;
  }
  .capture-dock > p {
    font-size: 8px;
    margin-top: 6px;
    background: var(--bg);
    width: max-content;
    max-width: 100%;
    padding-inline: 6px;
    border-radius: 5px;
    margin-inline: auto;
  }
  .sheet {
    width: calc(100vw - 20px);
    max-height: calc(100dvh - 30px);
    padding: 24px;
    border-radius: 20px;
  }
  .field-input,
  .cap-setup-row input,
  .pace-select {
    font-size: 16px;
  }
  .sheet-header h2 {
    font-size: 23px;
  }
  .chip {
    font-size: 11px;
    min-height: 44px;
  }
  .toast {
    bottom: 115px;
    font-size: 11px;
  }
  .welcome-main {
    grid-template-columns: 1fr;
    width: calc(100% - 44px);
    margin-block: 45px;
    gap: 55px;
  }
  .welcome-copy {
    text-align: center;
  }
  .welcome-main h1 {
    font-size: clamp(48px, 10vw, 66px);
    letter-spacing: -2.8px;
  }
  .welcome-description {
    margin-inline: auto;
    font-size: 14px;
  }
  .welcome-actions,
  .welcome-small {
    justify-content: center;
  }
  .welcome-preview {
    width: min(440px, calc(100% - 16px));
    margin: auto;
    padding: 22px;
    transform: rotate(-1deg);
  }
  .welcome-preview::after {
    right: -10px;
    font-size: 60px;
    top: -35px;
  }
  .welcome-principles {
    width: calc(100% - 44px);
    grid-template-columns: 1fr;
    gap: 25px;
    padding-top: 25px;
  }
  .welcome-principles article {
    display: grid;
    grid-template-columns: 25px 1fr;
    gap: 0 14px;
  }
  .welcome-principles article > span {
    grid-row: 1/3;
    padding-top: 5px;
  }
  .welcome-principles h3 {
    margin: 0 0 8px;
  }
  .welcome-principles p {
    max-width: none;
  }
  .site-footer {
    margin-inline: 22px;
  }
  .auth-main {
    grid-template-columns: 1fr;
    width: min(440px, 100%);
    gap: 25px;
    padding: 0 22px;
    margin: 32px auto;
  }
  .auth-story {
    text-align: center;
  }
  .auth-story h1 {
    font-size: 35px;
    letter-spacing: -1.4px;
  }
  .auth-story .spark {
    font-size: 38px;
    margin-bottom: 20px;
  }
  .auth-story > p {
    display: none;
  }
  .auth-card {
    padding: 25px;
  }
  .welcome-page .header-tools > .text-button {
    font-size: 12px;
  }
  .streak {
    font-size: 8px;
  }
  .pace-select {
    font-size: 12px;
  }
}
@media (max-width: 360px) {
  .app-header {
    padding-inline: 16px;
  }
  .dashboard {
    padding-inline: 16px;
  }
  .page-intro h1 {
    font-size: 30px;
  }
  .cap-card {
    padding: 14px 12px;
  }
  .cap-amount {
    font-size: 21px;
  }
  .cap-flex button {
    font-size: 9px;
  }
  .section-heading h2 {
    font-size: 14px;
  }
  .sheet {
    padding: 20px;
  }
  .welcome-actions {
    gap: 15px;
  }
  .welcome-actions .button {
    padding-inline: 18px;
  }
  .spend-amount {
    font-size: 11px;
  }
  .merchant-icon {
    width: 34px;
    height: 34px;
  }
  .header-tools {
    gap: 3px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

.empty-symbol svg {
  margin-inline: auto;
}
@media (max-width: 600px) {
  .cap-edit {
    width: 44px;
    height: 44px;
    min-width: 44px;
  }
}
