/* Kitna design system — "calm money".
   Paper surfaces and one ink colour for everything you press. The marigold coin lives in the logo.
   Green only for money in, red only for problems, amber only for a heads-up.
   Light by default, dark automatically when the phone is in dark mode.
   No neon, no glows, no gradients. System fonts so it feels native on iPhone and Android. */
:root {
  color-scheme: light;
  --bg: #f6f5f2;
  --surface: #ffffff;
  --surface-2: #f0efeb;
  --surface-3: #e5e3de;
  --line: #e6e4df;
  --line-2: #d6d3cd;
  --text: #17171a;
  --muted: #5c5a57;
  --faint: #6b6965;
  /* One ink colour for everything you press. Green = money in, red = errors, amber = heads-up.
     The marigold coin lives only in the logo. No lavender, no pastels. */
  --brand: #17171a;
  --brand-hover: #000000;
  --brand-ink: #ffffff;
  --brand-soft: #ecebe7;
  --accent: #f2a93b;
  --green: #18794e;
  --green-soft: #e6f2eb;
  --amber: #8f5500;
  --amber-soft: #f8efdf;
  --red: #b3261e;
  --red-soft: #fbe9e7;
  --blue: #5c5a57;
  --blue-soft: #f0efeb;
  --overlay: rgba(23, 23, 26, .45);
  --shadow: none;
  --radius: 16px;
  --radius-sm: 12px;
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Noto Sans", "Noto Sans Devanagari", sans-serif;
  --mono: "SF Mono", ui-monospace, Menlo, Consolas, monospace;
  --maxw: 1120px;
  /* avatars: one neutral style for everyone */
  --t0b: #ecebe7; --t0f: #17171a;
  --t1b: #ecebe7; --t1f: #17171a;
  --t2b: #ecebe7; --t2f: #17171a;
  --t3b: #ecebe7; --t3f: #17171a;
  --t4b: #ecebe7; --t4f: #17171a;
  --t5b: #ecebe7; --t5f: #17171a;
}
@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --bg: #111113;
    --surface: #1a1a1d;
    --surface-2: #222226;
    --surface-3: #2c2c31;
    --line: #2a2a2f;
    --line-2: #3a3a40;
    --text: #f2f1ee;
    --muted: #b5b3ae;
    --faint: #8f8d88;
    --brand: #f2f1ee;
    --brand-hover: #ffffff;
    --brand-ink: #111113;
    --brand-soft: #2a2a2f;
    --accent: #f2a93b;
    --green: #6cc497;
    --green-soft: #18271f;
    --amber: #e0ae5a;
    --amber-soft: #2a2316;
    --red: #ee8b80;
    --red-soft: #2d1b19;
    --blue: #b5b3ae;
    --blue-soft: #222226;
    --overlay: rgba(0, 0, 0, .6);
    --shadow: none;
    --t0b: #2a2a2f; --t0f: #f2f1ee;
    --t1b: #2a2a2f; --t1f: #f2f1ee;
    --t2b: #2a2a2f; --t2f: #f2f1ee;
    --t3b: #2a2a2f; --t3f: #f2f1ee;
    --t4b: #2a2a2f; --t4f: #f2f1ee;
    --t5b: #2a2a2f; --t5f: #f2f1ee;
  }
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body { font-family: var(--font); background: var(--bg); color: var(--text); font-size: 16px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; line-height: 1.2; letter-spacing: -0.01em; }
h1 { font-size: 30px; font-weight: 700; }
h2 { font-size: 17px; font-weight: 650; }
h3 { font-size: 15px; font-weight: 600; }
p { margin: 0; }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.small { font-size: 13px; }
.tiny { font-size: 12px; }
.num { font-variant-numeric: tabular-nums; }
.green { color: var(--green); }
.red { color: var(--red); }
.amber { color: var(--amber); }
.brand { color: var(--brand); }
.hidden { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 8px; }
::selection { background: var(--brand-soft); color: var(--text); }

/* ─── Top bar ────────────────────────────────────────────── */
.topbar { position: sticky; top: 0; z-index: 50; background: var(--surface); border-bottom: 1px solid var(--line); }
.topbar-in { max-width: var(--maxw); margin: 0 auto; padding: 14px 24px; display: flex; align-items: center; gap: 28px; }
.logo { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 19px; letter-spacing: -0.01em; }
.logo-mark { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: var(--brand); color: var(--brand-ink); font-size: 16px; font-weight: 800; }
.nav { display: flex; gap: 2px; flex: 1; }
.nav a { padding: 8px 12px; border-radius: 999px; color: var(--muted); font-weight: 600; font-size: 14px; display: flex; align-items: center; gap: 7px; }

.nav a.active { color: var(--brand); background: var(--brand-soft); }
.nav svg { width: 16px; height: 16px; }
.top-actions { display: flex; align-items: center; gap: 6px; }
.icon-link { width: 36px; height: 36px; border-radius: 999px; display: grid; place-items: center; color: var(--muted); border: 0; background: transparent; cursor: pointer; }
 .icon-link.active { background: var(--surface-2); color: var(--text); }
.icon-link svg { width: 18px; height: 18px; }
.avatar { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; background: var(--brand-soft); color: var(--text); font-size: 12px; flex-shrink: 0; letter-spacing: 0.02em; }

.main { max-width: var(--maxw); margin: 0 auto; padding: 32px 24px 140px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 28px; flex-wrap: wrap; }
.page-head p { margin-top: 6px; }
.eyebrow { font-size: 15px; font-weight: 500; color: var(--muted); }
.actions { display: flex; gap: 10px; flex-wrap: wrap; }

.grid { display: grid; gap: 14px; align-items: start; }
.grid.stretch { align-items: stretch; }
.g-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g-main { grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); }
.stack { display: flex; flex-direction: column; gap: 14px; }
.row { display: flex; align-items: center; gap: 12px; }
.between { justify-content: space-between; }
.wrap { flex-wrap: wrap; }

/* ─── Hero (big number) ──────────────────────────────────── */
.hero { padding: 4px 0 8px; display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; }
.hero .big { font-size: clamp(44px, 6vw, 60px); font-weight: 700; letter-spacing: -0.03em; line-height: 1; font-variant-numeric: tabular-nums; }
.hero .big .dec { color: var(--faint); font-size: 0.5em; letter-spacing: -0.02em; }
.hero .sub { margin-top: 10px; color: var(--muted); font-size: 15px; }
.delta { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: 13px; padding: 4px 10px; border-radius: 999px; background: var(--surface-2); }

/* ─── Cards ──────────────────────────────────────────────── */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.card.flat { background: transparent; }
.card.tap { cursor: pointer; transition: border-color .15s; }

.card-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; gap: 10px; }
.card-head h2 { font-size: 15px; }
.stat .label { color: var(--muted); font-size: 13px; font-weight: 600; }
.stat .value { font-size: 26px; font-weight: 700; margin-top: 8px; font-variant-numeric: tabular-nums; letter-spacing: -0.03em; }
.stat .sub { font-size: 12px; color: var(--faint); margin-top: 6px; }
.empty { text-align: center; padding: 28px 12px; color: var(--muted); font-size: 14px; }
.empty b { color: var(--text); display: block; margin-bottom: 4px; font-size: 15px; }
.link { color: var(--brand); font-weight: 650; font-size: 13px; }


/* ─── Buttons & forms ────────────────────────────────────── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid var(--line-2); background: var(--surface); padding: 10px 18px; border-radius: 12px; font-weight: 600; font-size: 14px; cursor: pointer; transition: background .15s, border-color .15s; white-space: nowrap; }

.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.primary { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }

.btn.light { background: var(--text); border-color: var(--text); color: var(--surface); }

.btn.ghost { background: transparent; border-color: transparent; color: var(--muted); }

.btn.danger { background: var(--red-soft); border-color: transparent; color: var(--red); }
.btn.sm { padding: 7px 13px; font-size: 13px; }
.btn.lg { padding: 14px 24px; font-size: 16px; }
.btn.block { width: 100%; }
.btn svg { width: 17px; height: 17px; }
.icon-btn { padding: 7px; min-width: 40px; min-height: 40px; border-radius: 999px; background: transparent; border: 0; color: var(--faint); cursor: pointer; display: grid; place-items: center; }

.icon-btn svg { width: 16px; height: 16px; }

label.field { display: flex; flex-direction: column; gap: 7px; font-size: 13px; color: var(--muted); font-weight: 600; }
.input, select.input, textarea.input { width: 100%; background: var(--surface); border: 1px solid var(--line-2); border-radius: var(--radius-sm); padding: 11px 13px; font-size: 15px; outline: none; transition: border-color .15s; }
.input:focus { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
.input.big { font-size: 32px; font-weight: 700; padding: 12px 14px; letter-spacing: -0.02em; }
textarea.input { resize: vertical; min-height: 120px; line-height: 1.45; font-size: 14px; }
select.input { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 32px; }
input[type=number]::-webkit-outer-spin-button, input[type=number]::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
input[type=number] { -moz-appearance: textfield; }
.form { display: flex; flex-direction: column; gap: 14px; }
.seg { display: inline-flex; background: var(--surface-2); border: 1px solid var(--line-2); border-radius: 999px; padding: 3px; }
.seg button { border: 0; background: transparent; padding: 7px 15px; border-radius: 999px; cursor: pointer; color: var(--muted); font-weight: 650; font-size: 14px; }
.seg button.on { background: var(--surface); color: var(--text); box-shadow: var(--shadow); }
.seg button.on.exp { color: var(--red); }
.seg button.on.inc { color: var(--green); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { border: 1px solid var(--line-2); background: transparent; padding: 7px 12px; border-radius: 999px; font-size: 13px; cursor: pointer; color: var(--muted); font-weight: 550; }
.chip.on { border-color: var(--brand); color: var(--brand); background: var(--brand-soft); }

/* ─── Lists & tables ─────────────────────────────────────── */
.tx-list { display: flex; flex-direction: column; }
.tx { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.tx:last-child { border-bottom: 0; }
.tx-icon { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-size: 15px; font-weight: 700; flex-shrink: 0; background: var(--surface-2); color: var(--muted); }
.tx-icon svg { width: 18px; height: 18px; }
.tint-0 { background: var(--t0b); color: var(--t0f); } .tint-1 { background: var(--t1b); color: var(--t1f); } .tint-2 { background: var(--t2b); color: var(--t2f); }
.tint-3 { background: var(--t3b); color: var(--t3f); } .tint-4 { background: var(--t4b); color: var(--t4f); } .tint-5 { background: var(--t5b); color: var(--t5f); }
.tx-main { flex: 1; min-width: 0; }
.tx-edit { cursor: pointer; border-radius: 8px; }
 .tx-edit:focus-visible .tx-title { text-decoration: underline; text-underline-offset: 3px; }
.tx-title { font-weight: 600; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tx-sub { font-size: 12px; color: var(--faint); margin-top: 2px; }
.tx-amt { font-weight: 650; font-variant-numeric: tabular-nums; white-space: nowrap; font-size: 15px; }
.badge { display: inline-block; font-size: 11px; padding: 2px 8px; border-radius: 999px; background: var(--surface-2); color: var(--muted); font-weight: 650; vertical-align: 1px; }
.badge.voice { background: var(--brand-soft); color: var(--brand); }
.badge.import, .badge.sms { background: var(--blue-soft); color: var(--blue); }
.badge.upi { background: var(--brand-soft); color: var(--brand); }
.badge.autosave, .badge.invest { background: var(--green-soft); color: var(--green); }
.badge.practice { background: var(--amber-soft); color: var(--amber); }
table.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th { text-align: left; color: var(--faint); font-weight: 600; font-size: 13px; padding: 8px 10px; border-bottom: 1px solid var(--line); }
.table td { padding: 11px 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table .right { text-align: right; }
.table-wrap { overflow-x: auto; }

/* ─── Progress ───────────────────────────────────────────── */
.bar { height: 8px; background: var(--surface-3); border-radius: 99px; overflow: hidden; }
.bar > i { display: block; height: 100%; background: var(--text); border-radius: 99px; transition: width .5s ease; }
.bar.ok > i { background: var(--green); }
.bar.ahead > i { background: var(--amber); }
.bar.over > i { background: var(--red); }
.bar.brand > i { background: var(--brand); }
.pill { font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 99px; }
.pill.ok { background: var(--green-soft); color: var(--green); }
.pill.ahead { background: var(--amber-soft); color: var(--amber); }
.pill.over { background: var(--red-soft); color: var(--red); }
.budget-row { padding: 13px 0; border-bottom: 1px solid var(--line); }
.budget-row:last-child { border-bottom: 0; }

/* ─── Charts ─────────────────────────────────────────────── */
.chart { width: 100%; display: block; }
.chart text { fill: var(--faint); font-size: 10px; font-family: var(--font); }
.legend { display: flex; flex-direction: column; gap: 9px; font-size: 13px; }
.legend .dot { width: 9px; height: 9px; border-radius: 3px; display: inline-block; margin-right: 9px; }
.score-ring { position: relative; width: 132px; height: 132px; flex-shrink: 0; }
.score-ring .center { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; }
.score-ring .big { font-size: 34px; font-weight: 700; line-height: 1; letter-spacing: -0.03em; }

/* ─── Toasts / modal / notices ───────────────────────────── */
.toasts { position: fixed; top: 16px; right: 16px; display: flex; flex-direction: column; gap: 10px; z-index: 90; max-width: min(380px, calc(100vw - 32px)); }
.toast { background: var(--text); color: var(--surface); border-radius: 14px; padding: 12px 16px; display: flex; gap: 14px; align-items: flex-start; font-size: 14px; font-weight: 550; animation: rise .18s ease; }
.toast.err { background: var(--red); color: #fff; }
.toast .t-body { flex: 1; }
.toast button { background: none; border: 0; color: var(--brand-soft); font-weight: 700; text-decoration: underline; cursor: pointer; padding: 0; }
.toast.err button { color: #fff; }
@keyframes rise { from { transform: translateY(-6px); opacity: 0; } to { transform: none; opacity: 1; } }
.modal-bg { position: fixed; inset: 0; background: var(--overlay); display: grid; place-items: center; z-index: 80; padding: 16px; animation: fade .12s; }
.modal { background: var(--surface); border: 1px solid var(--line-2); border-radius: 22px; width: min(480px, 100%); padding: 26px; max-height: 92vh; overflow: auto; }
.modal h2 { margin-bottom: 18px; font-size: 21px; font-weight: 700; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; margin-top: 20px; }
@keyframes fade { from { opacity: 0; } }
.notice { border-radius: 14px; padding: 12px 14px; font-size: 14px; display: flex; gap: 10px; align-items: flex-start; line-height: 1.45; }
.notice.caution { background: var(--amber-soft); color: var(--amber); }
.notice.stop { background: var(--red-soft); color: var(--red); }
.notice.ok { background: var(--green-soft); color: var(--green); }
.notice.info { background: var(--surface-2); color: var(--muted); }
.notice b { color: var(--text); }
.notice > svg { width: 18px; height: 18px; flex-shrink: 0; margin-top: 2px; }

/* ─── Voice assistant (flat, no glow) ────────────────────── */
.mic-fab { position: fixed; right: 24px; bottom: 24px; width: 60px; height: 60px; border-radius: 50%; border: 0; cursor: pointer; background: var(--brand); color: var(--brand-ink); display: grid; place-items: center; z-index: 70; transition: transform .12s; box-shadow: 0 4px 14px rgba(0,0,0,.18); }

.mic-fab svg { width: 26px; height: 26px; }
.mic-fab.wake::after { content: ""; position: absolute; top: 6px; right: 6px; width: 10px; height: 10px; border-radius: 50%; background: var(--green); border: 2px solid var(--brand); }
.mic-hint { position: fixed; right: 96px; bottom: 42px; font-size: 13px; font-weight: 600; color: var(--muted); z-index: 69; pointer-events: none; background: var(--surface-2); padding: 6px 12px; border-radius: 999px; }
.voice-overlay { position: fixed; inset: 0; z-index: 85; display: flex; align-items: flex-end; justify-content: center; background: var(--overlay); animation: fade .12s; }
.voice-sheet { width: min(640px, 100%); background: var(--surface); border: 1px solid var(--line-2); border-bottom: 0; border-radius: 26px 26px 0 0; padding: 26px 24px 30px; display: flex; flex-direction: column; gap: 16px; position: relative; }
.v-top { display: flex; align-items: center; gap: 14px; }
.v-mic { width: 58px; height: 58px; border-radius: 50%; border: 0; background: var(--surface-3); color: var(--text); display: grid; place-items: center; cursor: pointer; flex-shrink: 0; }
.v-mic svg { width: 24px; height: 24px; }
.v-mic.listening { background: var(--brand); color: var(--brand-ink); }
.v-mic.thinking { background: var(--text); color: var(--surface); }
.v-state { font-size: 13px; color: var(--faint); font-weight: 600; }
.eq { display: none; gap: 3px; align-items: center; height: 18px; margin-left: 6px; }
.eq i { width: 3px; background: var(--brand); border-radius: 2px; animation: eq .9s ease-in-out infinite; }
.eq i:nth-child(2) { animation-delay: .15s; } .eq i:nth-child(3) { animation-delay: .3s; } .eq i:nth-child(4) { animation-delay: .45s; }
.listening-on .eq { display: inline-flex; }
@keyframes eq { 0%, 100% { height: 4px; } 50% { height: 18px; } }
.v-heard { font-size: 22px; font-weight: 700; letter-spacing: -0.02em; min-height: 30px; line-height: 1.2; }
.v-heard.interim { color: var(--faint); }
.v-reply { font-size: 16px; color: var(--muted); min-height: 22px; line-height: 1.5; }
.v-reply b { color: var(--text); }
.v-suggest { display: flex; flex-wrap: wrap; gap: 6px; }
.v-type { display: flex; gap: 8px; }
.v-close { position: absolute; top: 14px; right: 14px; }

/* ─── Pay ────────────────────────────────────────────────── */
.payee { display: flex; align-items: center; gap: 14px; }
.payee .avatar { width: 48px; height: 48px; font-size: 16px; }


/* ─── Auth / marketing ───────────────────────────────────── */
.auth-wrap { min-height: 100vh; display: grid; grid-template-columns: 1.05fr 1fr; }
.auth-side { background: var(--brand); color: var(--brand-ink); padding: 48px; display: flex; flex-direction: column; justify-content: space-between; }
.auth-side .logo-mark { background: var(--brand-ink); color: var(--brand); }
.auth-side h1 { font-size: clamp(36px, 4.4vw, 54px); letter-spacing: -0.03em; line-height: 1.05; font-weight: 700; }
.auth-main { display: grid; place-items: center; padding: 32px; }
.auth-card { width: min(400px, 100%); }
.otp { letter-spacing: 14px; text-align: center; font-size: 28px; font-weight: 700; }
.divider { display: flex; align-items: center; gap: 12px; color: var(--faint); font-size: 12px; margin: 6px 0; }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--line-2); }

.lp { max-width: 1240px; margin: 0 auto; padding: 0 28px; }
.lp-nav { display: flex; align-items: center; justify-content: space-between; padding: 22px 0; }
.lp-hero { padding: 64px 0 56px; display: grid; grid-template-columns: 1.15fr .85fr; gap: 56px; align-items: center; }
.lp-hero h1 { font-size: clamp(38px, 5.4vw, 64px); font-weight: 700; letter-spacing: -0.035em; line-height: 1.05; }
.lp-hero h1 em { font-style: normal; color: var(--brand); }
.lp-hero p.lead { font-size: 19px; color: var(--muted); margin: 26px 0 32px; max-width: 540px; line-height: 1.5; }
.lp-section { padding: 72px 0; border-top: 1px solid var(--line); }
.lp-section h2 { font-size: clamp(28px, 3.4vw, 40px); font-weight: 700; letter-spacing: -0.03em; margin-bottom: 14px; line-height: 1; }
.lp-stat { font-size: 52px; font-weight: 700; letter-spacing: -0.03em; line-height: 1; color: var(--brand); }
.feature .ico { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; margin-bottom: 14px; background: var(--brand-soft); color: var(--brand); }
.feature .ico svg { width: 20px; height: 20px; }
.feature h3 { font-size: 18px; margin-bottom: 8px; font-weight: 650; }
.phone { background: var(--surface); border: 1px solid var(--line-2); border-radius: 34px; padding: 22px; box-shadow: var(--shadow); }
.bubble { padding: 11px 15px; border-radius: 18px; font-size: 14px; max-width: 86%; margin-bottom: 10px; line-height: 1.45; }
.bubble.me { background: var(--brand); color: var(--brand-ink); margin-left: auto; border-bottom-right-radius: 6px; }
.bubble.kitna { background: var(--surface-2); color: var(--text); border-bottom-left-radius: 6px; }
.footer { padding: 36px 0; border-top: 1px solid var(--line); color: var(--faint); font-size: 13px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; }
.steps { display: flex; gap: 6px; margin-bottom: 26px; }
.steps i { flex: 1; height: 4px; border-radius: 4px; background: var(--surface-3); }
.steps i.on { background: var(--brand); }
.coach-log { display: flex; flex-direction: column; gap: 4px; max-height: 480px; overflow-y: auto; padding-right: 4px; }
.skeleton { background: var(--surface-2); border-radius: 10px; min-height: 16px; animation: pulse 1.2s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .55; } }

/* ─── Mobile ─────────────────────────────────────────────── */
.bottom-nav { display: none; }
@media (max-width: 1100px) { .g-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g-main { grid-template-columns: 1fr; } .nav a span { display: none; } }
@media (max-width: 860px) {
  .nav { display: none; }
  .topbar-in { padding: 12px 16px; justify-content: space-between; }
  .main { padding: 20px 16px 140px; }
  .g-3, .g-2 { grid-template-columns: 1fr; }
  .bottom-nav { display: flex; position: fixed; bottom: 0; left: 0; right: 0; background: var(--surface); border-top: 1px solid var(--line); justify-content: space-around; padding: 8px 4px calc(8px + env(safe-area-inset-bottom)); z-index: 60; }
  .bottom-nav a { display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 10px; font-weight: 650; color: var(--faint); padding: 4px 6px; min-width: 52px; }
  .bottom-nav a.active { color: var(--brand); }
  .bottom-nav svg { width: 21px; height: 21px; }
  .mic-fab { bottom: 92px; right: 16px; width: 54px; height: 54px; }
  .mic-hint { display: none; }
  .auth-wrap { grid-template-columns: 1fr; }
  .auth-side { display: none; }
  .lp-hero { grid-template-columns: 1fr; padding-top: 28px; }
  h1 { font-size: 26px; }
  .stat .value { font-size: 22px; }
  .voice-sheet { border-radius: 22px 22px 0 0; padding: 22px 18px calc(24px + env(safe-area-inset-bottom)); }
}
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* ─── Calm-money additions ───────────────────────────────── */
.narrow { max-width: 760px; margin: 0 auto; width: 100%; }
.hero-card { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 22px 22px 20px; box-shadow: var(--shadow); }
.hero-label { font-size: 14px; color: var(--muted); font-weight: 500; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 12px; font-size: 14px; color: var(--muted); }
.hero-meta b { color: var(--text); font-weight: 600; }
.hero-meta .ok { color: var(--green); display: inline-flex; align-items: center; gap: 4px; }
.hero-meta .ok svg { width: 15px; height: 15px; }
.hero-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 18px; }
.hero-actions .btn { padding: 13px 14px; font-size: 15px; }
.section-title { font-size: 17px; font-weight: 650; margin: 6px 2px 10px; display: flex; justify-content: space-between; align-items: baseline; }
.section-title .link { font-size: 14px; }
.kv { display: flex; justify-content: space-between; align-items: baseline; padding: 12px 0; border-bottom: 1px solid var(--line); gap: 12px; }
.kv:last-child { border-bottom: 0; }
.kv .k { color: var(--muted); font-size: 15px; }
.kv .k small { display: block; color: var(--faint); font-size: 12px; margin-top: 2px; }
.kv .v { font-weight: 650; font-variant-numeric: tabular-nums; font-size: 16px; white-space: nowrap; }
.setup { display: flex; flex-direction: column; }
.setup-step { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.setup-step:last-child { border-bottom: 0; }
.setup-step .tick { width: 26px; height: 26px; border-radius: 50%; border: 2px solid var(--line-2); display: grid; place-items: center; flex-shrink: 0; color: transparent; }
.setup-step.done .tick { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.setup-step .tick svg { width: 14px; height: 14px; }
.setup-step .s-main { flex: 1; min-width: 0; }
.setup-step .s-title { font-weight: 600; font-size: 15px; }
.setup-step.done .s-title { color: var(--faint); text-decoration: line-through; }
.setup-step .s-sub { font-size: 13px; color: var(--faint); margin-top: 1px; }
.progress-text { font-size: 13px; color: var(--muted); }
@media (max-width: 860px) {
  .hero-card { padding: 18px; border-radius: 18px; }
}

/* ─── Reminders bell, friends ───────────────────────────── */
.icon-link.bell { position: relative; }
.bell-dot { position: absolute; top: 6px; right: 6px; width: 8px; height: 8px; border-radius: 50%; background: #d0603a; border: 2px solid var(--surface); }
.bell-dot[hidden] { display: none; }
.owed-row .tx-amt.in { color: var(--green, #2f7d67); }
.chip-row { display: flex; gap: 8px; flex-wrap: wrap; }
.toggle-row { display: flex; align-items: flex-start; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.toggle-row:last-child { border-bottom: 0; }
.toggle-row input { margin-top: 3px; }
@media (max-width: 860px) { .bottom-nav a { min-width: 0; padding: 4px 2px; flex: 1; } }
@media (max-width: 860px) {
  .table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .raw-text { display: none; }
  .table td.right { white-space: nowrap; }
}

img.logo-mark { background: none; padding: 0; object-fit: contain; }

/* Kitna wordmark (the logo): takes the text colour; the coin dot stays marigold */
.logo-wm { height: 26px; width: auto; display: block; color: var(--text); }
.lp-nav .logo-wm { height: 30px; }
.auth-side .logo-wm { height: 34px; color: #fff; }
.tagline { color: var(--brand); font-weight: 700; letter-spacing: -0.01em; }

.bar.brand > i { background: var(--brand); }

/* Bigger tap areas without moving anything (44 px is the guideline for fingers) */
.link { display: inline-block; padding: 12px 6px; margin: -12px -6px; }
.logo { min-height: 44px; }
@media (max-width: 860px) { .icon-btn { min-width: 44px; min-height: 44px; } }
a.small.muted[href="/app/friends"] { padding: 8px 0; margin: -2px 0; }
summary { padding: 10px 0; }

/* A list row with its buttons on a line of their own, so names and amounts never get squeezed */
.tx-item { border-bottom: 1px solid var(--line); }
.tx-item:last-child { border-bottom: 0; }
.tx-item > .tx { border-bottom: 0; padding-bottom: 6px; }
.item-actions { display: flex; flex-wrap: wrap; gap: 8px; padding: 0 0 12px 54px; }
.item-actions .btn.sm { min-height: 40px; }
.tx-title.wrap { white-space: normal; overflow: visible; }

/* Coach: the question box first on phones (that's what the Ask tab is for), beside the report on laptops */
.coach-layout { display: grid; gap: 20px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 1100px) { .coach-layout { grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr); align-items: start; } .coach-layout > .card:first-child { position: sticky; top: 84px; order: 2; } }
.stack > div:empty { display: none; }

/* Landing: real app screenshots in a simple phone frame */
.shot-wrap { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.shot { width: 100%; max-width: 300px; height: auto; border-radius: 34px; border: 7px solid #1c1b22; box-shadow: 0 18px 40px rgba(28, 27, 34, .16); background: #fff; }
.hero-shot .shot { max-width: 320px; }
.shots { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; margin-top: 32px; align-items: start; }
.shots figcaption { font-size: 14px; color: var(--muted); max-width: 300px; line-height: 1.5; }
.shots figcaption b { display: block; color: var(--text); font-size: 16px; margin-bottom: 4px; }
.chat-wrap .phone { width: 100%; max-width: 300px; }
@media (max-width: 860px) { .shots { grid-template-columns: minmax(0, 1fr); gap: 44px; } .hero-shot { margin-top: 12px; } }

/* ═══ Simple Kitna (Nov 2026): fewer things, more room ══════════════════════════
   Four tabs + More, flat cards, one big number, short words. */
.card, .hero-card { box-shadow: none; }
.page-head { align-items: center; margin-bottom: 18px; }
.page-head h1 { font-size: 26px; letter-spacing: -0.02em; }
@media (max-width: 860px) {
  .page-head p { display: none; }         /* phones: the screen explains itself */
  .page-head { flex-wrap: nowrap; }
  .page-head .actions { flex-wrap: nowrap; }
  .page-head h1 { font-size: 24px; }
}

/* Top bar: logo, tabs (laptop), bell, you */
button.avatar { border: 0; cursor: pointer; padding: 0; }
.topbar { background: var(--bg); border-bottom-color: var(--line); }
@media (max-width: 860px) { .top-actions .avatar { display: none; } .topbar-in { padding: 10px 16px; } }

/* Bottom tabs: Home · Activity · Pay · Friends · More */
@media (max-width: 860px) {
  .bottom-nav { display: grid; grid-template-columns: repeat(4, 1fr); padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); }
  .bottom-nav a { gap: 4px; font-size: 11px; font-weight: 600; color: var(--muted); padding: 4px 0; min-width: 0; }
  .bottom-nav a svg { width: 22px; height: 22px; padding: 0; }
  .bottom-nav a.active { color: var(--text); }
  .main { padding: 14px 16px 120px; }
}

/* More menu: a sheet from the bottom on phones */
.sheet { padding: 18px; }
.sheet-me { display: flex; align-items: center; gap: 12px; padding: 4px 4px 14px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.sheet-me .avatar { width: 42px; height: 42px; font-size: 14px; }
.menu-list { display: flex; flex-direction: column; }
.menu-item { display: flex; align-items: center; gap: 14px; padding: 11px 6px; border-radius: 12px; width: 100%; text-align: left; background: none; border: 0; cursor: pointer; color: var(--text); }

.menu-item > svg { width: 18px; height: 18px; color: var(--faint); margin-left: auto; flex-shrink: 0; }
.menu-ic { width: 38px; height: 38px; border-radius: 12px; background: var(--surface-2); display: grid; place-items: center; color: var(--brand); flex-shrink: 0; }
.menu-ic svg { width: 19px; height: 19px; }
.menu-text { display: flex; flex-direction: column; min-width: 0; }
.menu-text b { font-weight: 600; font-size: 15px; }
.menu-text span { font-size: 12.5px; color: var(--faint); }
.menu-item.plain { margin-bottom: 8px; }
@media (max-width: 860px) {
  .sheet-bg { place-items: end stretch; padding: 0; }
  .sheet { width: 100%; border-radius: 22px 22px 0 0; border-bottom: 0; padding: 18px 16px calc(14px + env(safe-area-inset-bottom)); animation: up .18s ease-out; }
}
@keyframes up { from { transform: translateY(24px); opacity: 0; } }
.menu-pop { position: relative; }
.menu-pop > summary { list-style: none; padding: 10px 12px; }
.menu-pop > summary::-webkit-details-marker { display: none; }
.menu-pop-in { position: absolute; right: 0; top: calc(100% + 6px); background: var(--surface); border: 1px solid var(--line-2); border-radius: 14px; padding: 6px; z-index: 20; min-width: 180px; }
.menu-pop-in .menu-item { margin: 0; padding: 10px 12px; font-size: 14px; }

/* Home */
.greet { font-size: 15px; color: var(--muted); font-weight: 500; margin: 2px 2px -6px; }
.hero-card { padding: 20px 20px 16px; }
.hero-top { display: flex; align-items: center; justify-content: space-between; }
.hero-label { font-size: 14px; color: var(--muted); font-weight: 550; }
.why-btn { width: 36px; height: 36px; margin: -8px -8px -8px 0; border: 0; background: none; color: var(--faint); border-radius: 999px; display: grid; place-items: center; cursor: pointer; }
 .why-btn[aria-expanded=true] { background: var(--surface-2); color: var(--brand); }
.why-btn svg { width: 18px; height: 18px; }
.hero-num { font-size: clamp(46px, 13vw, 60px); font-weight: 750; letter-spacing: -0.04em; line-height: 1.05; margin-top: 6px; font-variant-numeric: tabular-nums; }
.hero-num.amber { color: var(--amber); }
.hero-sub { color: var(--muted); font-size: 14px; margin-top: 4px; }
.why { margin-top: 14px; padding: 12px 14px; background: var(--surface-2); border-radius: 14px; display: flex; flex-direction: column; gap: 6px; }
.why-total { border-top: 1px solid var(--line-2); padding-top: 8px; }
.quick-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); }
.quick { display: flex; flex-direction: column; align-items: center; gap: 7px; background: none; border: 0; cursor: pointer; font-size: 12px; font-weight: 600; color: var(--text); padding: 4px 0; border-radius: 14px; }
.quick-ic { width: 48px; height: 48px; border-radius: 16px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand); }
.quick:first-child .quick-ic { background: var(--brand); color: var(--brand-ink); }
.quick-ic svg { width: 22px; height: 22px; }

.setup-card { padding: 6px 16px; position: relative; }
.setup-head { display: flex; align-items: center; gap: 14px; width: 100%; padding: 10px 56px 10px 0; background: none; border: 0; cursor: pointer; text-align: left; color: var(--text); }
.setup-head .s-main { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.setup-head .s-main b { font-weight: 600; font-size: 15px; }
.setup-head > svg { width: 18px; height: 18px; color: var(--faint); transition: transform .15s; }
.setup-head[aria-expanded=true] > svg { transform: rotate(90deg); }
.setup-later { position: absolute; right: 40px; top: 12px; }
.ring { --p: 0; width: 40px; height: 40px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center;
  background: conic-gradient(var(--brand) calc(var(--p) * 1%), var(--surface-3) 0); }
.ring > span { width: 32px; height: 32px; border-radius: 50%; background: var(--surface); display: grid; place-items: center; font-size: 11px; font-weight: 700; }
.month-card { display: grid; grid-template-columns: repeat(auto-fit, minmax(90px, 1fr)); gap: 12px; padding: 16px 20px; }
.month-v { font-size: 20px; font-weight: 700; letter-spacing: -0.02em; margin: 2px 0; }

/* Activity */
.seg.full { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; width: 100%; }
.seg.full button { padding: 8px 4px; font-size: 13.5px; }
.filters { display: flex; flex-direction: column; gap: 8px; }
.filters[hidden] { display: none; }
.list-card { padding: 2px 18px 10px; }
.day-head { font-size: 12px; font-weight: 650; color: var(--faint); text-transform: uppercase; letter-spacing: .04em; padding: 16px 0 4px; border-bottom: 1px solid var(--line); }
.icon-link.active { color: var(--brand); background: var(--brand-soft); }

/* Scan & Pay */
.people { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 4px; }
.person { display: flex; flex-direction: column; align-items: center; gap: 6px; background: none; border: 0; cursor: pointer; font-size: 12px; color: var(--muted); min-width: 64px; padding: 4px; border-radius: 12px; }
.person .avatar { width: 46px; height: 46px; font-size: 15px; }
[hidden] { display: none !important; }
.setup-head { padding-right: 0; }
.btn.danger-text { color: var(--red); margin-right: auto; }
.modal-foot { flex-wrap: wrap; }
.friends-totals { display: grid; grid-template-columns: 1fr 1fr; gap: 0; padding: 0; }
.friends-totals > div { padding: 16px 18px; }
.friends-totals > div + div { border-left: 1px solid var(--line); }
.friends-totals .v { font-size: 24px; font-weight: 700; letter-spacing: -0.02em; margin: 4px 0 2px; }
@media (max-width: 860px) { .g-2.keep { grid-template-columns: 1fr 1fr; } }
.done-btn { width: 36px; height: 36px; border-radius: 50%; border: 2px solid var(--line-2); background: none; color: var(--faint); display: grid; place-items: center; cursor: pointer; flex-shrink: 0; }

.done-btn svg { width: 16px; height: 16px; }
@media (max-width: 860px) { .done-btn { width: 40px; height: 40px; } }
button.link { background: none; border: 0; cursor: pointer; font: inherit; }
.link-inline { background: none; border: 0; padding: 0; font: inherit; color: var(--brand); font-weight: 650; cursor: pointer; text-decoration: underline; text-underline-offset: 2px; }
.owed-row .item-actions { flex-wrap: nowrap; align-items: center; }

/* ═══ Polish pass: one spacing system (4/8/12/16/24), real tab bar metrics, calm motion ═══ */
html { -webkit-tap-highlight-color: transparent; }
body { text-rendering: optimizeLegibility; }
.num, .tx-amt, .hero-num, .month-v { font-variant-numeric: tabular-nums; font-feature-settings: "tnum" 1; }

/* Tab bar (Material 3 / iOS metrics): 24px icons in a 56×32 pill, 12px labels on one baseline.
   The Pay circle rises out of its slot, so its label lines up with the others. */
@media (max-width: 860px) {
  .bottom-nav { height: calc(68px + env(safe-area-inset-bottom)); padding: 0 4px env(safe-area-inset-bottom); align-items: stretch;
    box-shadow: 0 -1px 0 var(--line), 0 -6px 24px rgba(28, 27, 34, .04); border-top: 0; user-select: none; -webkit-user-select: none; }
  .bottom-nav a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: 6px 0 4px; color: var(--muted); font-size: 12px; line-height: 16px; font-weight: 550; }
  .bottom-nav a .ni { position: relative; width: 56px; height: 32px; border-radius: 16px; display: grid; place-items: center; transition: background-color .15s; }
  .bottom-nav a svg { width: 24px; height: 24px; padding: 0; background: none; border-radius: 0; box-sizing: border-box; }
  .bottom-nav a.active { color: var(--text); font-weight: 700; }
  .bottom-nav a.active .ni { background: var(--brand-soft); color: var(--brand); }
  .bottom-nav a:active .ni { transform: scale(.94); }
  .main { padding: 12px 16px calc(104px + env(safe-area-inset-bottom)); }
  .topbar-in { min-height: 56px; padding: 8px 16px; }
  .logo-wm { height: 24px; }
}
@media (prefers-color-scheme: dark) { .bottom-nav { box-shadow: 0 -1px 0 var(--line); } }

/* Sheets: every dialog slides up from the bottom on phones, like the system ones */
@media (max-width: 860px) {
  .modal-bg { place-items: end stretch; padding: 0; }
  .modal { width: 100%; max-width: none; border-radius: 22px 22px 0 0; border-bottom: 0; padding: 26px 18px calc(18px + env(safe-area-inset-bottom)); max-height: 90vh; animation: up .2s ease-out; position: relative; }
  .modal::before { content: ""; position: absolute; top: 8px; left: 50%; transform: translateX(-50%); width: 36px; height: 4px; border-radius: 2px; background: var(--line-2); }
  .modal h2 { font-size: 19px; margin-bottom: 16px; }
  .modal-foot .btn { flex: 1; min-height: 48px; }
  .modal-foot .btn.danger-text { flex: 0 0 auto; }
  .toasts { top: auto; bottom: calc(84px + env(safe-area-inset-bottom)); left: 16px; right: 16px; max-width: none; }
}

/* Press feedback: things you tap give way a little */
.btn, .quick-ic, .menu-item, .person, .done-btn, .why-btn, .icon-link { transition: transform .08s ease, background-color .15s, border-color .15s; }
.btn:active, .done-btn:active { transform: scale(.98); }
.quick:active .quick-ic, .person:active .avatar { transform: scale(.94); }
.menu-item:active, .tx-edit:active { background: var(--surface-2); }
.btn { min-height: 44px; border-radius: 12px; }
.btn.sm { min-height: 36px; }
.btn.lg { min-height: 52px; border-radius: 14px; }

/* Lists: 64px rows, 40px avatars, amounts right-aligned on one grid */
.tx { min-height: 64px; gap: 12px; }
.tx .avatar, .tx-icon { width: 40px; height: 40px; }
.tx-sub { font-size: 12.5px; margin-top: 3px; }
.tx-amt { font-size: 15px; font-weight: 650; text-align: right; }
.tx-amt.green { color: var(--green); }

/* Home */
.home { gap: 16px; }
.hero-num { display: flex; align-items: flex-start; gap: 2px; }
.hero-num .cur { font-size: .6em; font-weight: 600; color: var(--muted); margin-top: .14em; }
.hero-num.amber .cur { color: inherit; }
.as-of { display: flex; align-items: center; gap: 6px; margin-top: 10px; font-size: 12px; color: var(--faint); }
.dot-live { width: 6px; height: 6px; border-radius: 50%; background: var(--green); flex-shrink: 0; }
.dot-live.wait { background: var(--amber); animation: pulse 1.2s ease-in-out infinite; }
.dot-live.off { background: var(--red); }
.trust { display: flex; align-items: center; justify-content: center; gap: 8px; font-size: 12.5px; color: var(--faint); padding: 8px 12px 4px; text-align: left; }
.trust svg { width: 16px; height: 16px; color: var(--green); flex-shrink: 0; }
.trust b { color: var(--muted); font-weight: 600; }
.section-title { font-size: 16px; margin: 8px 2px 8px; }
.hero-card { border-radius: 20px; }
.card { border-radius: 16px; }

/* Pay */
.trust { min-height: 44px; }

/* No hover effects and no soft, blurry shadows: crisp lines only. */
:root { --shadow: none; }
@media (prefers-color-scheme: dark) { :root { --shadow: none; } }
.seg button.on { box-shadow: none; border: 1px solid var(--line-2); }
.shot { box-shadow: none; }
@media (max-width: 860px) {
  .bottom-nav { box-shadow: none; border-top: 1px solid var(--line); }
}

/* ═══ No AI-template tells: no glows, no tinted boxes behind icons, one ink colour ═══ */
.input:focus, select.input:focus, textarea.input:focus { box-shadow: none; border-color: var(--text); }
:focus-visible { outline: 2px solid var(--text); outline-offset: 2px; box-shadow: none; }
.btn.primary { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.link { color: var(--text); text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 3px; }
.section-title .link { text-decoration: none; color: var(--muted); font-weight: 600; }
.badge, .badge.autosave, .badge.upi, .badge.voice, .badge.import, .badge.sms { background: transparent; border: 1px solid var(--line-2); color: var(--muted); }
/* Quick actions: plain circles, the main one filled */
.quick-ic { border-radius: 50%; background: var(--surface); border: 1px solid var(--line-2); color: var(--text); }
.quick:first-child .quick-ic { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
/* Menus: the icon sits in the line, no little box behind it */
.menu-ic { width: 24px; height: 24px; background: none; border-radius: 0; color: var(--text); }
.menu-item { gap: 16px; padding: 13px 8px; }
/* Website feature cards: icon in line with the heading, no rounded square */
.feature .ico { width: auto; height: auto; background: none; border-radius: 0; color: var(--text); margin-bottom: 10px; display: block; }
.feature .ico svg { width: 22px; height: 22px; }
/* Tabs: neutral pill, ink icon */
@media (max-width: 860px) {
  .bottom-nav a.active .ni { background: var(--surface-3); color: var(--text); }
}
.nav a.active { background: var(--surface-3); color: var(--text); }
/* Laptop: logo left, tabs in the exact middle (Pay in the centre), bell and you on the right */
@media (min-width: 861px) {
  .topbar-in { display: grid; grid-template-columns: 1fr auto 1fr; gap: 24px; }
  .topbar-in .nav { flex: none; justify-self: center; }
  .topbar-in .top-actions { justify-self: end; }
  .nav a[href="/app/pay"] { background: var(--brand); color: var(--brand-ink); }
  .nav a[href="/app/pay"].active { background: var(--brand); color: var(--brand-ink); outline: 2px solid var(--line-2); outline-offset: 2px; }
}
.notice.info { background: var(--surface-2); color: var(--text); border-color: var(--line); }
.tagline { color: var(--text); }
.auth-side .logo-wm { color: var(--brand-ink); }
/* Text boxes show focus with their border only, never an extra outline */
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: none; }

/* ═══ Kitna, made simple (major redesign) ════════════════════════════════════
   Bigger text, one idea per block, pictures for categories, big buttons. */
body { font-size: 16px; }
.tx-title { font-size: 16px; font-weight: 600; }
.tx-sub { font-size: 13.5px; color: var(--faint); }
.tx-amt { font-size: 16px; font-weight: 700; }
.section-title { font-size: 18px; font-weight: 700; margin: 12px 2px 10px; }
.section-title .link { font-size: 15px; }
.btn { font-size: 16px; }
.small { font-size: 14px; }
.tiny { font-size: 13px; }

/* Category pictures */
.cat-ic { width: 44px; height: 44px; border-radius: 50%; background: var(--surface-2); color: var(--text); display: grid; place-items: center; flex-shrink: 0; }
.cat-ic svg { width: 22px; height: 22px; }
.cat-ic.in { background: var(--green-soft); color: var(--green); }
.tx { min-height: 68px; gap: 14px; }

/* Home: greeting, the one sentence, big buttons */
.greet { font-size: 22px; font-weight: 700; color: var(--text); margin: 4px 2px 0; letter-spacing: -0.01em; }
.today { background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: 22px 22px 16px; }
.today-label { font-size: 17px; font-weight: 600; color: var(--muted); }
.today-num { display: flex; align-items: flex-start; gap: 2px; font-size: clamp(54px, 15vw, 68px); font-weight: 800; letter-spacing: -0.045em; line-height: 1.05; margin: 6px 0 4px; }
.today-num .cur { font-size: .55em; font-weight: 650; color: var(--muted); margin-top: .16em; }
.today.careful .today-num { color: var(--amber); }
.today-sub { font-size: 16px; color: var(--muted); }
.today-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.today-foot .as-of { margin: 0; font-size: 13px; }
.today-how { background: none; border: 0; padding: 8px 0 8px 12px; font: inherit; font-size: 15px; font-weight: 650; color: var(--text); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; min-height: 44px; }
.today .btn { margin-top: 16px; }
.big-acts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.big-act { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 14px 4px 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; cursor: pointer; color: var(--text); font: inherit; }
.big-ic { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); }
.big-ic svg { width: 26px; height: 26px; }
.big-act.main .big-ic { background: var(--brand); color: var(--brand-ink); }
.big-label { font-size: 13.5px; font-weight: 650; line-height: 1.2; text-align: center; }
.big-act:active { transform: scale(.97); }
.next-step { display: flex; align-items: stretch; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; }
.next-main { flex: 1; display: flex; align-items: center; gap: 14px; padding: 14px 6px 14px 16px; background: none; border: 0; cursor: pointer; text-align: left; color: var(--text); font: inherit; min-width: 0; }
.next-main > svg { width: 20px; height: 20px; color: var(--faint); flex-shrink: 0; }
.next-ic { width: 44px; height: 44px; border-radius: 50%; background: var(--brand); color: var(--brand-ink); display: grid; place-items: center; flex-shrink: 0; }
.next-ic svg { width: 22px; height: 22px; }
.next-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.next-text b { font-size: 16px; }
.next-text span { font-size: 14px; color: var(--muted); }
.next-x { width: 48px; background: none; border: 0; color: var(--faint); cursor: pointer; display: grid; place-items: center; }
.next-x svg { width: 18px; height: 18px; }
.how { display: flex; flex-direction: column; gap: 10px; }
.how-row { display: flex; justify-content: space-between; gap: 12px; font-size: 15.5px; }
.how-row span { color: var(--muted); }
.how-total { border-top: 1px solid var(--line); padding-top: 10px; }

/* Sheets: title row with a close button */
.modal-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.modal-head h2 { margin: 0 !important; font-size: 20px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.modal-x { width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--surface-2); color: var(--text); display: grid; place-items: center; cursor: pointer; flex-shrink: 0; }
.modal-x svg { width: 18px; height: 18px; }

/* Add / edit a payment */
.add-form { gap: 14px; }
.amount-wrap { display: flex; align-items: center; justify-content: center; gap: 2px; padding: 6px 0 2px; }
.amount-wrap span { font-size: 40px; font-weight: 600; color: var(--faint); }
.amount-in { border: 0; background: none; outline: none; font-size: 56px; font-weight: 800; letter-spacing: -0.04em; color: var(--text); padding: 0; width: auto; min-width: 2ch; font-family: inherit; }
.amount-in::placeholder { color: var(--line-2); }
.amount-in::-webkit-outer-spin-button, .amount-in::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.add-check { text-align: center; color: var(--muted); min-height: 20px; }
.add-check.caution { color: var(--amber); }
.add-check.stop { color: var(--red); }
.field-label { font-size: 15px; font-weight: 650; }
.cat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.cat-pick { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 2px 8px; border: 1.5px solid transparent; border-radius: 16px; background: none; cursor: pointer; color: var(--text); font: inherit; }
.cat-pick span { font-size: 12.5px; font-weight: 600; line-height: 1.15; text-align: center; }
.cat-pick.on { border-color: var(--text); background: var(--surface-2); }
.cat-pick.on .cat-ic { background: var(--brand); color: var(--brand-ink); }
.day-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.day-row .input { width: auto; }
.edit-sum { text-align: center; padding: 4px 0 6px; }
.edit-amt { font-size: 40px; font-weight: 800; letter-spacing: -0.03em; }
.edit-amt.green { color: var(--green); }
@media (max-width: 860px) { .modal { max-height: 92vh; overflow-y: auto; } }
/* The main button of a sheet is always visible at the bottom */
@media (max-width: 860px) {
  .modal { padding-bottom: 0; }
  .modal-foot { position: sticky; bottom: 0; background: var(--surface); margin: 0 -18px; padding: 12px 18px calc(12px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); z-index: 2; }
}
.big-acts { grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* Plain headings and lists (no ALL-CAPS labels, no identical icon cards) */
.day-head { text-transform: none; letter-spacing: 0; font-size: 14px; font-weight: 700; color: var(--muted); }
.lp-list { list-style: none; padding: 0; margin: 28px 0 0; max-width: 760px; }
.lp-list li { padding: 18px 0; border-top: 1px solid var(--line); font-size: 17px; line-height: 1.55; }
.lp-list li:last-child { border-bottom: 1px solid var(--line); }
.lp-list b { color: var(--text); }

/* ═══ Flat, not boxed ═════════════════════════════════════════════════════════
   Only the main number sits on a surface. Lists sit on the page with thin lines
   between rows. One small radius scale (8 / 10 / 14) instead of ovals and pills. */
:root { --radius: 14px; --radius-sm: 10px; }
.card { border-radius: 14px; }
/* list-card styling lives in the iOS layer below */
.list-card .tx { border-bottom: 1px solid var(--line); }
.list-card .tx:last-child { border-bottom: 0; }
.list-card .day-head { border-bottom: 1px solid var(--line); padding-left: 0; }
.today { border-radius: 14px; }
.big-acts { gap: 4px; }
.big-act { background: none; border: 0; border-radius: 10px; padding: 6px 2px; }
.next-step { background: none; border: 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); border-radius: 0; }
.next-main { padding-left: 0; }
.friends-totals { background: none; border: 0; border-radius: 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.friends-totals > div { padding: 14px 0; }
.friends-totals > div + div { padding-left: 18px; }
/* Controls: squared-off, one radius each */
.btn, .input, select.input, textarea.input { border-radius: 10px; }
.btn.lg { border-radius: 12px; }
.btn.sm { border-radius: 8px; }
.seg { border-radius: 10px; padding: 3px; }
.seg button { border-radius: 8px; }
.chip { border-radius: 8px; }
.badge, .pill { border-radius: 6px; }
.nav a { border-radius: 8px; }
.icon-btn, .icon-link { border-radius: 10px; }
.cat-pick { border-radius: 12px; }
.modal { border-radius: 14px; }
@media (max-width: 860px) { .modal, .sheet { border-radius: 16px 16px 0 0; } }
.menu-pop-in { border-radius: 10px; }
.toast { border-radius: 10px; }
/* Tabs: the active tab is shown by ink colour and a bold label, no oval behind it */
@media (max-width: 860px) {
  .bottom-nav a.active .ni, .bottom-nav a .ni { background: none; }
  .bottom-nav a.active { color: var(--text); }
}
.nav a.active { background: none; color: var(--text); box-shadow: inset 0 -2px 0 var(--text); border-radius: 0; }
.nav a[href="/app/pay"], .nav a[href="/app/pay"].active { border-radius: 8px; box-shadow: none; }
/* Motion: only what explains something (sheets sliding up, loading rows) */
.big-act:active, .quick:active .quick-ic, .person:active .avatar { transform: none; }


/* ═══════════════════════════════════════════════════════════════════════════
   Kitna 2.0 · iOS look
   Grouped grey page, white rounded groups, large titles, a frosted tab bar
   and one indigo for everything you can press. Green = money in, red = problem,
   amber = heads-up. This block is the only colour source: earlier themes removed.
   ═══════════════════════════════════════════════════════════════════════════ */
:root, html[data-theme="light"] {
  color-scheme: light;
  --bg: #F2F2F7; --surface: #FFFFFF; --surface-2: #F2F2F7; --surface-3: #E5E5EA;
  --line: #E3E3E8; --line-2: #D1D1D6; --fill: rgba(118, 118, 128, .12);
  --text: #0B0B0F; --muted: #6C6C72; --faint: #6C6C72;
  --brand: #4F46E5; --brand-hover: #4338CA; --brand-ink: #FFFFFF; --brand-soft: #EEEDFD;
  --accent: #F2A93B;
  --green: #1A7F45; --green-soft: #E3F4EA; --red: #C8302A; --red-soft: #FDECEB;
  --amber: #8F5600; --amber-soft: #FDF1DC; --blue: #4F46E5; --blue-soft: #EEEDFD;
  --overlay: rgba(0, 0, 0, .32); --bar: rgba(249, 249, 251, .82);
  --t0b: #EEEDFD; --t0f: #3730A3; --t1b: #E3F4EA; --t1f: #14653A; --t2b: #FDF1DC; --t2f: #7A4A00;
  --t3b: #FDECEB; --t3f: #A3241F; --t4b: #E6F0FA; --t4f: #1D5C91; --t5b: #F1ECFA; --t5f: #5B3A8C;
  --radius: 14px; --radius-sm: 10px; --shadow: none;
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", "Segoe UI", Roboto, "Noto Sans", "Noto Sans Devanagari", sans-serif;
  --display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Inter", "Segoe UI", Roboto, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --bg: #000000; --surface: #1C1C1E; --surface-2: #2C2C2E; --surface-3: #3A3A3C;
    --line: #2E2E31; --line-2: #48484A; --fill: rgba(118, 118, 128, .24);
    --text: #F5F5F7; --muted: #A1A1A8; --faint: #A1A1A8;
    --brand: #8E8AFF; --brand-hover: #A19EFF; --brand-ink: #0B0A1F; --brand-soft: #24224A;
    --green: #3DD68C; --green-soft: #12301F; --red: #FF6B63; --red-soft: #3A1715;
    --amber: #FFB547; --amber-soft: #33260E; --blue: #8E8AFF; --blue-soft: #24224A;
    --overlay: rgba(0, 0, 0, .55); --bar: rgba(22, 22, 24, .82);
    --t0b: #24224A; --t0f: #C9C7FF; --t1b: #12301F; --t1f: #7BE3AE; --t2b: #33260E; --t2f: #FFCF85;
    --t3b: #3A1715; --t3f: #FF9A93; --t4b: #12263A; --t4f: #8CC4F2; --t5b: #2A1F3D; --t5f: #CDB3F5;
  }
}
html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #000000; --surface: #1C1C1E; --surface-2: #2C2C2E; --surface-3: #3A3A3C;
  --line: #2E2E31; --line-2: #48484A; --fill: rgba(118, 118, 128, .24);
  --text: #F5F5F7; --muted: #A1A1A8; --faint: #A1A1A8;
  --brand: #8E8AFF; --brand-hover: #A19EFF; --brand-ink: #0B0A1F; --brand-soft: #24224A;
  --green: #3DD68C; --green-soft: #12301F; --red: #FF6B63; --red-soft: #3A1715;
  --amber: #FFB547; --amber-soft: #33260E; --blue: #8E8AFF; --blue-soft: #24224A;
  --overlay: rgba(0, 0, 0, .55); --bar: rgba(22, 22, 24, .82);
  --t0b: #24224A; --t0f: #C9C7FF; --t1b: #12301F; --t1f: #7BE3AE; --t2b: #33260E; --t2f: #FFCF85;
  --t3b: #3A1715; --t3f: #FF9A93; --t4b: #12263A; --t4f: #8CC4F2; --t5b: #2A1F3D; --t5f: #CDB3F5;
}

body { background: var(--bg); font-family: var(--font); -webkit-font-smoothing: antialiased; letter-spacing: -0.01em; }
h1, h2, h3, .today-num, .large-title h1 { font-family: var(--display); }

/* Navigation bar: frosted, hairline, no heavy logo row */
.topbar { background: var(--bar); -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px); border-bottom: .5px solid var(--line-2); }
.topbar .avatar { background: var(--brand-soft); color: var(--brand); }

/* Large titles, like Settings and Wallet */
.large-title { margin: 6px 2px 2px; }
.large-title h1, .page-head h1 { font-size: 34px; line-height: 41px; font-weight: 700; letter-spacing: .01em; margin: 0; }
.lt-date { font-size: 13px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .02em; }
.page-head { margin-bottom: 18px; align-items: flex-end; }
.page-head p { font-size: 15px; }
.section-title { font-size: 20px; font-weight: 700; letter-spacing: -0.01em; }
.section-title .link, .link { color: var(--brand); font-weight: 500; font-size: 15px; text-decoration: none; }

/* Groups: white rounded blocks on grey, no borders */
.card, .today, .big-act, .next-step { background: var(--surface); border: 0; border-radius: var(--radius); box-shadow: none; }
.card.flat { background: transparent; }
.list-card { padding: 0 0 0 16px; }
.list-card .tx { padding-right: 16px; border-bottom: .5px solid var(--line-2); min-height: 60px; }
.list-card .tx:last-child { border-bottom: 0; }
.list-card .empty { padding: 28px 16px 28px 0; }

/* Today's number */
.today { padding: 20px 20px 14px; border-radius: 20px; }
.today-label { font-size: 15px; font-weight: 600; color: var(--muted); }
.today-num { font-size: clamp(56px, 16vw, 72px); font-weight: 700; letter-spacing: -0.035em; color: var(--text); }
.today-num .cur { color: var(--muted); }
.today.careful .today-num { color: var(--amber); }
.today-sub { font-size: 15px; color: var(--muted); }
.today-foot { border-top: .5px solid var(--line-2); }
.today-how { color: var(--brand); text-decoration: none; font-weight: 600; }
.dot-live { background: var(--green); }

/* Quick actions: three, the main one filled */
.big-acts.three { grid-template-columns: repeat(3, 1fr); gap: 10px; }
.big-act { padding: 14px 4px 12px; border-radius: 16px; }
.big-ic { background: var(--brand-soft); color: var(--brand); width: 48px; height: 48px; }
.big-ic svg { width: 24px; height: 24px; }
.big-act.main .big-ic { background: var(--brand); color: var(--brand-ink); }
.big-label { font-size: 13px; font-weight: 600; }
.next-ic { background: var(--brand); color: var(--brand-ink); }

/* Buttons: filled indigo, grey tinted, or plain text */
.btn { border: 0; background: var(--fill); color: var(--text); border-radius: 12px; font-weight: 600; font-size: 15px; }
.btn.primary { background: var(--brand); color: var(--brand-ink); }
.btn.primary:hover { background: var(--brand-hover); }
.btn.ghost { background: transparent; color: var(--brand); }
.btn.danger { background: var(--red-soft); color: var(--red); }
.btn.lg { border-radius: 14px; font-size: 17px; }
.link-inline { color: var(--brand); }

/* Fields */
.input, select.input, textarea.input { background: var(--surface); border: .5px solid var(--line-2); border-radius: 10px; font-size: 17px; }
.input:focus { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }

/* Segmented control */
.seg { background: var(--fill); border: 0; border-radius: 9px; padding: 2px; }
.seg button { border-radius: 7px; font-weight: 600; font-size: 13px; color: var(--text); }
.seg button.on { background: var(--surface); box-shadow: 0 3px 8px rgba(0, 0, 0, .12), 0 3px 1px rgba(0, 0, 0, .04); }
@media (prefers-color-scheme: dark) { .seg button.on { background: #636366; } }
html[data-theme="dark"] .seg button.on { background: #636366; }

/* Lists and category icons */
.tx-title { font-weight: 500; font-size: 16px; }
.tx-sub { color: var(--muted); font-size: 13px; }
.tx-amt { font-weight: 600; font-size: 16px; }
.tx-amt.green, .green { color: var(--green); }
.cat-ic { background: var(--brand-soft); color: var(--brand); border-radius: 50%; }
.cat-ic.in { background: var(--green-soft); color: var(--green); }
.cat-ic.save { background: var(--blue-soft); color: var(--blue); }
.cat-pick.on { border-color: var(--brand); background: var(--brand-soft); }
.cat-pick.on .cat-ic { background: var(--brand); color: var(--brand-ink); }
.avatar { background: var(--brand-soft); color: var(--brand); }

/* Notices: a soft tint, no border */
.notice { border-radius: 14px; }
.notice.info { background: var(--surface); color: var(--muted); }

/* Sheets */
.modal { border: 0; border-radius: 14px; }
.menu-ic { background: var(--brand); color: var(--brand-ink); border-radius: 8px; width: 30px; height: 30px; }
.menu-ic svg { width: 17px; height: 17px; }
.menu-list { background: var(--surface-2); border-radius: 12px; padding: 0 0 0 12px; margin: 6px 0 12px; }
.menu-item { border-radius: 0; padding: 12px 12px 12px 0; border-bottom: .5px solid var(--line-2); }
.menu-item:last-child { border-bottom: 0; }
.menu-item.plain { background: var(--surface-2); border-radius: 12px; padding-left: 12px; border-bottom: 0; }
.menu-text b { font-weight: 500; font-size: 16px; }
.menu-text span { font-size: 13px; color: var(--muted); }
.sheet-me { border-bottom: 0; }
@media (prefers-color-scheme: dark) { .modal { background: var(--surface); } .menu-list, .menu-item.plain { background: var(--surface-2); } }

/* Settings: grouped, like the phone's own Settings */
.settings-list { display: flex; flex-direction: column; gap: 22px; max-width: 720px; }
.settings-list > .card { background: var(--surface); border-radius: var(--radius); padding: 16px; margin: 0; grid-column: auto !important; }
.settings-list > .card h2 { font-size: 17px; font-weight: 600; margin: 0 0 4px; }
.settings-list > .card > p { margin: 0 0 12px; font-size: 14px; color: var(--muted); }
.settings-list .card .card { background: var(--surface-2); }

/* Tab bar: frosted, five equal slots, Scan raised in the middle */
@media (max-width: 860px) {
  .bottom-nav { background: var(--bar); -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px);
    box-shadow: none; border-top: .5px solid var(--line-2); height: calc(58px + env(safe-area-inset-bottom)); }
  .bottom-nav a { font-size: 10px; font-weight: 500; color: var(--muted); gap: 2px; padding-top: 6px; justify-content: flex-start; }
  .bottom-nav a .ni { width: 32px; height: 28px; border-radius: 0; }
  .bottom-nav a svg { width: 25px; height: 25px; }
  .bottom-nav a.active { color: var(--brand); font-weight: 600; }
  .bottom-nav a.active .ni { background: none; color: var(--brand); }
  .main { padding: 8px 16px calc(96px + env(safe-area-inset-bottom)); }
  .topbar-in { min-height: 48px; padding: 6px 16px; }
  .logo-wm { height: 22px; }
  .modal { border-radius: 14px 14px 0 0; }
}

/* Scan: full-bleed camera, rounded */

/* Laptop: active tab in indigo */
.nav a.active { color: var(--brand); box-shadow: inset 0 -2px 0 var(--brand); }
.page-head .menu-pop { display: none; }
.home { gap: 14px; }
.home .as-of { display: flex; }
.big-acts { align-items: start; }
.big-acts .big-act { height: auto; min-height: 0; align-self: start; justify-content: flex-start; }
.card.list-card { padding: 0 0 0 16px; }
.card.list-card .day-head { padding: 14px 16px 6px 0; border-bottom: .5px solid var(--line-2); font-size: 13px; font-weight: 600; color: var(--muted); }
.card.list-card .tx { padding-right: 16px; border-bottom: .5px solid var(--line-2); }
.card.list-card .tx:last-child { border-bottom: 0; }
.big-acts .big-act.main { padding: 14px 4px 12px; max-width: none; margin: 0; }
.setup-card > summary { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 12px; cursor: pointer; }
.setup-card > summary::-webkit-details-marker { display: none; }
.setup-sum { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.setup-sum b { font-size: 17px; font-weight: 600; }
.setup-sum span { font-size: 14px; color: var(--muted); }
.setup-card[open] > summary .link { visibility: hidden; }
.auto-more > summary { cursor: pointer; color: var(--brand); font-weight: 600; font-size: 15px; padding: 8px 0; list-style: none; }
.auto-more > summary::-webkit-details-marker { display: none; }

/* Kitna helper (support chat) */
.help-sheet { display: flex; flex-direction: column; height: min(640px, 86vh); padding: 14px 14px calc(10px + env(safe-area-inset-bottom)); }
.help-head { display: flex; align-items: center; gap: 8px; padding: 4px 2px 10px; border-bottom: .5px solid var(--line-2); }
.help-title { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.help-title b { font-size: 17px; }
.help-title span { font-size: 12px; color: var(--muted); }
.help-lang { background: var(--fill); border: 0; border-radius: 8px; padding: 6px 8px; font: inherit; font-size: 13px; color: var(--text); max-width: 110px; }
.help-speak { background: var(--fill); border: 0; border-radius: 8px; width: 34px; height: 32px; cursor: pointer; opacity: .55; }
.help-speak.on { background: var(--brand-soft); opacity: 1; }
.help-msgs { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; padding: 12px 2px; }
.help-msg { display: flex; flex-direction: column; max-width: 86%; gap: 6px; }
.help-msg.me { align-self: flex-end; align-items: flex-end; }
.help-bubble { padding: 9px 13px; border-radius: 18px; font-size: 15.5px; line-height: 1.4; white-space: pre-wrap; background: var(--surface-2); color: var(--text); }
.help-msg.me .help-bubble { background: var(--brand); color: var(--brand-ink); border-bottom-right-radius: 6px; }
.help-msg.bot .help-bubble { border-bottom-left-radius: 6px; }
.help-msg.typing .help-bubble { color: var(--muted); letter-spacing: .2em; }
.help-links { display: flex; gap: 6px; flex-wrap: wrap; }
.help-links .btn { background: var(--brand-soft); color: var(--brand); }
.help-starters { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.help-starters .chip { background: var(--surface); border: .5px solid var(--line-2); border-radius: 16px; padding: 7px 12px; font: inherit; font-size: 13.5px; color: var(--brand); cursor: pointer; }
.help-form { display: flex; gap: 6px; align-items: center; padding-top: 8px; }
.help-input { flex: 1; border-radius: 20px; padding: 9px 14px; font-size: 16px; }
.help-send, .help-mic { width: 40px; height: 40px; min-height: 40px; padding: 0; border-radius: 50%; flex-shrink: 0; }
.help-mic.on { background: var(--red); color: #fff; }
.help-foot { text-align: center; margin: 6px 0 0; }
@media (min-width: 861px) { .help-sheet { width: min(460px, 100%); } }
.how-row b { text-align: right; min-width: 0; overflow-wrap: anywhere; }
.how-row span { flex-shrink: 0; }
.modal { overflow-x: hidden; }
.admin-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* Floating helper button */
.help-fab { position: fixed; right: 18px; bottom: calc(24px + env(safe-area-inset-bottom)); z-index: 55; width: 56px; height: 56px; border-radius: 50%;
  border: 0; background: var(--brand); color: var(--brand-ink); display: grid; place-items: center; cursor: pointer;
  box-shadow: 0 8px 24px rgba(79, 70, 229, .35), 0 2px 6px rgba(0, 0, 0, .12); transition: transform .12s ease; }
.help-fab:active { transform: scale(.92); }
.help-fab svg { width: 27px; height: 27px; fill: currentColor; }
.help-fab svg circle { fill: var(--brand); }
.help-fab-dot { position: absolute; top: 6px; right: 6px; width: 12px; height: 12px; border-radius: 50%; background: #F2A93B; border: 2px solid var(--brand); }
.help-fab.seen .help-fab-dot { display: none; }
@media (max-width: 860px) { .help-fab { right: 14px; bottom: calc(76px + env(safe-area-inset-bottom)); width: 52px; height: 52px; } }
@media (prefers-color-scheme: dark) { .help-fab { box-shadow: 0 8px 24px rgba(0, 0, 0, .5); } }

/* Scan & Pay: how to finish in the UPI app */

/* ── Today: "Just paid" — sort auto-logged payments with one tap ── */
.sort-card { padding: 0; overflow: hidden; }
.sort-row { padding: 14px 16px; display: flex; flex-direction: column; gap: 10px; transition: opacity .2s; }
.sort-row + .sort-row { border-top: 0.5px solid var(--line, rgba(60,60,67,.18)); }
.sort-row.sorting { opacity: .4; pointer-events: none; }
.sort-top { display: flex; align-items: center; gap: 12px; }
.sort-top .tx-amt { font-weight: 600; font-size: 17px; }
.sort-top .tx-amt.in { color: var(--good, #34C759); }
.sort-name { height: 38px; font-size: 15px; }
.sort-chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 0 -16px; padding: 0 16px 2px; }
.sort-chips::-webkit-scrollbar { display: none; }
.sort-chips .cat-grid { width: 100%; }
.sort-chip { flex: none; display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px 0 6px;
  border-radius: 17px; border: 0; background: var(--fill, rgba(118,118,128,.12)); color: inherit; font: inherit; font-size: 14px; cursor: pointer; }
.sort-chip:last-child { padding-left: 12px; }
.sort-chip .cat-ic { width: 24px; height: 24px; }
.sort-chip.on { box-shadow: inset 0 0 0 1.5px var(--brand, #4F46E5); }
.sort-chip:active { transform: scale(.97); }
.quick-row { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-top: 4px; }
.chip-btn { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: 18px; border: 0;
  background: var(--card, #fff); color: var(--brand, #4F46E5); font: inherit; font-size: 14px; font-weight: 500; cursor: pointer; }
.chip-btn svg { width: 16px; height: 16px; }

/* ── Kitna Rent (owners) and the tenant page ── */
.rent-pitch h2 { font-size: 20px; margin: 0 0 12px; letter-spacing: -0.01em; }
.how-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.how-list li { display: flex; gap: 10px; align-items: flex-start; font-size: 15px; line-height: 1.4; }
.how-list li svg { width: 18px; height: 18px; flex: none; margin-top: 2px; color: var(--good, #34C759); }
.rent-sum .of { font-size: 20px; font-weight: 500; color: var(--muted); letter-spacing: 0; margin-left: 4px; }
.rent-sum .bar .fill { height: 100%; background: var(--good, #34C759); border-radius: 99px; transition: width .4s; }
.rent-pills { display: flex; gap: 8px; flex-wrap: wrap; }
.rent-pill { display: inline-flex; align-items: center; gap: 2px; height: 26px; padding: 0 10px; border-radius: 13px; font-size: 13px;
  background: var(--fill, rgba(118,118,128,.12)); color: var(--muted); white-space: nowrap; }
.rent-pill b { color: inherit; font-weight: 700; }
.rent-pill.late { background: rgba(255, 59, 48, .12); color: var(--red, #FF3B30); }
.rent-pill.due { background: rgba(255, 149, 0, .14); color: #B25E00; }
.rent-pill.paid { background: rgba(52, 199, 89, .14); color: #1E8E3E; }
[data-theme="dark"] .rent-pill.due { color: #FFB340; } [data-theme="dark"] .rent-pill.paid { color: #4CD964; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .rent-pill.due { color: #FFB340; } :root:not([data-theme="light"]) .rent-pill.paid { color: #4CD964; } }
.tx-sub.red, .tx-amt.red { color: var(--red, #FF3B30); }
.ok-tick svg { width: 20px; height: 20px; color: var(--good, #34C759); }
.plan-banner { width: 100%; border: 0; cursor: pointer; font: inherit; color: inherit; text-align: left; }
.tenant-head { text-align: center; padding: 4px 0; }
.tenant-bal { font-size: 40px; font-weight: 750; letter-spacing: -0.03em; margin: 4px 0; }
.month-rows { display: flex; flex-direction: column; }
.month-row { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; font-size: 15px; }
.list-card .month-row { padding: 12px 16px 12px 0; }
.month-row + .month-row { border-top: 0.5px solid var(--line, rgba(60,60,67,.18)); }
.plan-card { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; padding: 14px; border-radius: 14px; cursor: pointer;
  border: 1.5px solid var(--line-2, rgba(60,60,67,.25)); background: var(--card, #fff); color: inherit; font: inherit; text-align: left; }
.plan-card.best { border-color: var(--brand, #4F46E5); box-shadow: 0 0 0 3px var(--brand-soft, rgba(79,70,229,.12)); }
.plan-card:active { transform: scale(.98); }
.plan-price { font-size: 26px; font-weight: 750; letter-spacing: -0.02em; }
.tenant-page { padding-top: calc(20px + env(safe-area-inset-top)); padding-bottom: calc(40px + env(safe-area-inset-bottom)); }
.upi-box { display: flex; align-items: center; gap: 12px; justify-content: space-between; padding: 12px 14px; border-radius: 12px; background: var(--fill, rgba(118,118,128,.12)); }
.upi-id { font-size: 17px; font-weight: 650; word-break: break-all; }
.pay-how { margin: 0; padding-left: 20px; line-height: 1.7; color: var(--muted); }
.pay-how b { color: var(--text, inherit); }
.qr-wrap { display: grid; place-items: center; padding: 14px; margin-top: 10px; background: #fff; border-radius: 16px; }
.qr-wrap img { width: 220px; height: 220px; }
@media print {
  .tenant-page .card:not(.list-card), .tenant-page section.card, .tenant-page .today, .tenant-page .link { display: none !important; }
  body { background: #fff; }
}
.rent .sort-chip { padding: 0 14px; }
.rent-sum .bar { margin: 14px 0 12px !important; }
