:root {
  --bg: #F3F5F4;
  --card: #FFFFFF;
  --card-2: #F7F8F8;
  --line: #E7EAE9;
  --text: #17201C;
  --text-2: #5B6662;
  --text-3: #95A09B;
  --brand: #1F9D6B;
  --brand-2: #E6F5EE;
  --brand-ink: #127A51;
  --expense: #17201C;
  --income: #2F6FDB;
  --save: #7048E8;
  --danger: #E5484D;
  --warn: #F59E0B;
  --warn-2: #FFF6E3;
  --shadow: 0 1px 2px rgba(16, 24, 20, .04), 0 4px 16px rgba(16, 24, 20, .05);
  --radius: 20px;
  --nav-h: 64px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0E1211; --card: #171C1A; --card-2: #1E2422; --line: #29302D;
    --text: #EEF2F0; --text-2: #A7B1AD; --text-3: #6E7A75;
    --brand: #34C285; --brand-2: #173328; --brand-ink: #5BD9A1;
    --expense: #EEF2F0; --income: #6EA2FF; --save: #A98BFF; --warn-2: #33290F;
    --shadow: none; color-scheme: dark;
  }
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; padding: 0; background: var(--bg); color: var(--text); }
body {
  font-family: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", sans-serif;
  font-size: 15px; line-height: 1.45; letter-spacing: -0.01em; -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}
button, input, select, textarea { font: inherit; color: inherit; letter-spacing: inherit; }
button { cursor: pointer; border: 0; background: none; padding: 0; }
input, select, textarea { outline: none; }
.num { font-variant-numeric: tabular-nums; }

/* ---------- 레이아웃 ---------- */
.shell { max-width: 640px; margin: 0 auto; min-height: 100dvh; padding: calc(var(--safe-t) + 8px) 16px calc(var(--nav-h) + var(--safe-b) + 88px); }
.topbar { display: flex; align-items: center; justify-content: space-between; padding: 8px 2px 14px; }
.month-switch { display: flex; align-items: center; gap: 2px; }
.month-switch h1 { font-size: 22px; font-weight: 800; margin: 0 4px; letter-spacing: -0.03em; }
.icon-btn { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; color: var(--text-2); }
.icon-btn:active { background: var(--card-2); }
.icon-btn svg { width: 22px; height: 22px; }
.hh-name { font-size: 13px; color: var(--text-3); font-weight: 600; }

.card { background: var(--card); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); margin-bottom: 12px; }
.card h3 { margin: 0 0 12px; font-size: 15px; font-weight: 700; display: flex; justify-content: space-between; align-items: center; }
.card h3 .more { font-size: 13px; color: var(--text-3); font-weight: 600; }
.muted { color: var(--text-3); }
.sub { color: var(--text-2); font-size: 13px; }

/* ---------- 하단 탭 ---------- */
.nav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  background: color-mix(in srgb, var(--card) 92%, transparent); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid var(--line); padding-bottom: var(--safe-b);
}
.nav-inner { max-width: 640px; margin: 0 auto; display: grid; grid-template-columns: repeat(5, 1fr); height: var(--nav-h); }
.nav button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; font-size: 11px; font-weight: 600; color: var(--text-3); position: relative; }
.nav button svg { width: 24px; height: 24px; }
.nav button.on { color: var(--text); }
.nav .badge-dot { position: absolute; top: 10px; left: calc(50% + 8px); min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px; background: var(--danger); color: #fff; font-size: 10px; display: grid; place-items: center; }

.fab {
  position: fixed; z-index: 21; right: max(18px, calc(50% - 320px + 18px)); bottom: calc(var(--nav-h) + var(--safe-b) + 16px);
  width: 58px; height: 58px; border-radius: 20px; background: var(--brand); color: #fff; display: grid; place-items: center;
  box-shadow: 0 8px 24px rgba(31, 157, 107, .35); transition: transform .15s;
}
.fab:active { transform: scale(.94); }
.fab svg { width: 28px; height: 28px; }



/* ---------- 요약 ---------- */
.summary .label { font-size: 13px; color: var(--text-2); font-weight: 600; }
.summary .big { font-size: 32px; font-weight: 800; letter-spacing: -0.035em; margin: 2px 0 14px; }
.summary .row { display: flex; gap: 10px; }
.summary .mini { flex: 1; background: var(--card-2); border-radius: 14px; padding: 10px 12px; }
.summary .mini b { display: block; font-size: 16px; margin-top: 2px; }
.bar { height: 8px; background: var(--card-2); border-radius: 99px; overflow: hidden; }
.bar > i { display: block; height: 100%; background: var(--brand); border-radius: 99px; transition: width .4s; }
.bar.warn > i { background: var(--warn); } .bar.over > i { background: var(--danger); }
.budget-line { display: flex; justify-content: space-between; font-size: 13px; color: var(--text-2); margin: 14px 0 6px; }

.banner { display: flex; align-items: center; gap: 12px; background: var(--warn-2); border-radius: 16px; padding: 14px 16px; margin-bottom: 12px; width: 100%; text-align: left; }
.banner .ic { font-size: 22px; }
.banner b { display: block; font-size: 15px; }
.banner span { font-size: 13px; color: var(--text-2); }
.banner .chev { margin-left: auto; color: var(--text-3); }

.split { display: flex; height: 10px; border-radius: 99px; overflow: hidden; background: var(--card-2); margin: 4px 0 12px; }
.split i { display: block; height: 100%; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 13px; }
.legend span { display: inline-flex; align-items: center; gap: 6px; color: var(--text-2); }
.legend b { color: var(--text); }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex: none; }

.cat-row { display: grid; grid-template-columns: 36px 1fr auto; gap: 10px; align-items: center; padding: 8px 0; }
.cat-row .em { width: 36px; height: 36px; border-radius: 12px; background: var(--card-2); display: grid; place-items: center; font-size: 18px; }
.cat-row .nm { font-weight: 600; font-size: 14px; display: flex; justify-content: space-between; gap: 8px; }
.cat-row .bar { height: 6px; margin-top: 6px; }
.cat-row .amt { font-weight: 700; font-size: 14px; text-align: right; }
.cat-row .amt small { display: block; font-weight: 500; color: var(--text-3); font-size: 12px; }

/* ---------- 거래 목록 ---------- */
.day-head { display: flex; justify-content: space-between; align-items: baseline; padding: 16px 4px 6px; font-size: 13px; font-weight: 700; color: var(--text-2); }
.day-head .num { color: var(--text-3); font-weight: 600; }
.list { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.tx { display: grid; grid-template-columns: 42px 1fr auto; gap: 12px; align-items: center; padding: 12px 16px; width: 100%; text-align: left; position: relative; }
.tx + .tx::before { content: ""; position: absolute; top: 0; left: 70px; right: 16px; border-top: 1px solid var(--line); }
.tx:active { background: var(--card-2); }
.tx .em { width: 42px; height: 42px; border-radius: 14px; background: var(--card-2); display: grid; place-items: center; font-size: 20px; position: relative; }
.tx .em .who { position: absolute; right: -2px; bottom: -2px; width: 14px; height: 14px; border-radius: 50%; border: 2.5px solid var(--card); }
.tx .t1 { font-weight: 600; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tx .t2 { font-size: 12.5px; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 1px; }
.tx .amt { font-weight: 700; font-size: 15px; text-align: right; white-space: nowrap; }
.tx .amt.income { color: var(--income); }
.tx .amt.transfer { color: var(--text-3); }
.tx.cancelled .t1, .tx.cancelled .amt { text-decoration: line-through; color: var(--text-3); }
.tag { display: inline-block; font-size: 11px; font-weight: 700; padding: 2px 6px; border-radius: 6px; vertical-align: 1px; margin-left: 4px; }
.tag.review { background: var(--warn-2); color: #B7791F; }
.tag.auto { background: var(--brand-2); color: var(--brand-ink); }
.tag.gray { background: var(--card-2); color: var(--text-3); }
.empty { text-align: center; padding: 48px 16px; color: var(--text-3); }
.empty .big { font-size: 40px; margin-bottom: 8px; }

.search { display: flex; align-items: center; gap: 8px; background: var(--card); border-radius: 14px; padding: 0 14px; height: 44px; box-shadow: var(--shadow); margin-bottom: 10px; }
.search input { flex: 1; border: 0; background: none; height: 100%; }
.search svg { width: 18px; height: 18px; color: var(--text-3); }
.chips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding: 2px 0 4px; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: none; padding: 7px 13px; border-radius: 99px; background: var(--card); font-size: 13.5px; font-weight: 600; color: var(--text-2); box-shadow: var(--shadow); display: inline-flex; align-items: center; gap: 6px; }
.chip.on { background: var(--text); color: var(--card); }
.list-total { display: flex; gap: 14px; font-size: 13px; color: var(--text-2); padding: 8px 4px 0; }
.list-total b { color: var(--text); }

/* ---------- 달력 ---------- */
.cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.cal .wd { text-align: center; font-size: 12px; color: var(--text-3); font-weight: 600; padding: 4px 0 8px; }
.cal .wd:first-child { color: var(--danger); } .cal .wd:last-child { color: var(--income); }
.cal .d { min-height: 62px; border-radius: 12px; padding: 6px 2px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 1px; }
.cal .d .n { font-size: 13px; font-weight: 600; width: 24px; height: 24px; display: grid; place-items: center; border-radius: 50%; }
.cal .d.today .n { background: var(--brand); color: #fff; }
.cal .d.sel { background: var(--card-2); }
.cal .d .e { font-size: 11px; font-weight: 700; color: var(--text); }
.cal .d .i { font-size: 11px; font-weight: 700; color: var(--income); }
.cal .d.out { visibility: hidden; }
.cal .d.sun .n { color: var(--danger); } .cal .d.sat .n { color: var(--income); }
.cal .d.today.sun .n, .cal .d.today.sat .n { color: #fff; }

/* ---------- 통계 ---------- */
.seg { display: inline-flex; background: var(--card-2); border-radius: 12px; padding: 3px; gap: 2px; }
.seg button { padding: 7px 14px; border-radius: 9px; font-size: 14px; font-weight: 600; color: var(--text-2); }
.seg button.on { background: var(--card); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,.08); }
.seg.full { display: flex; } .seg.full button { flex: 1; }
.donut-wrap { display: flex; align-items: center; gap: 18px; }
.donut-wrap svg { flex: none; }
.donut-center { font-size: 12px; fill: var(--text-3); }
.donut-total { font-size: 17px; font-weight: 800; fill: var(--text); }
.bars { display: flex; align-items: flex-end; gap: 10px; height: 150px; padding-top: 18px; }
.bars .b { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; justify-content: flex-end; }
.bars .b i { display: block; width: 100%; max-width: 36px; background: var(--card-2); border-radius: 8px 8px 4px 4px; min-height: 4px; }
.bars .b.cur i { background: var(--brand); }
.bars .b span { font-size: 12px; color: var(--text-3); font-weight: 600; }
.bars .b small { font-size: 11px; color: var(--text-2); font-weight: 700; }
.compare { font-size: 14px; color: var(--text-2); margin-top: 4px; }
.compare b.up { color: var(--danger); } .compare b.down { color: var(--brand-ink); }

/* ---------- 설정 ---------- */
.menu { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; margin-bottom: 12px; }
.menu .item { display: flex; align-items: center; gap: 12px; padding: 15px 16px; width: 100%; text-align: left; position: relative; }
.menu .item + .item::before { content: ""; position: absolute; top: 0; left: 56px; right: 0; border-top: 1px solid var(--line); }
.menu .item:active { background: var(--card-2); }
.menu .item .ic { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; font-size: 16px; background: var(--card-2); flex: none; }
.menu .item .tt { flex: 1; font-weight: 600; }
.menu .item .val { color: var(--text-3); font-size: 14px; }
.menu .item .chev { color: var(--text-3); }
.sec-title { font-size: 13px; font-weight: 700; color: var(--text-3); margin: 20px 6px 8px; }
.profile-card { display: flex; align-items: center; gap: 14px; }
.avatar { width: 48px; height: 48px; border-radius: 16px; display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 19px; flex: none; }

/* ---------- 시트(모달) ---------- */
.backdrop { position: fixed; inset: 0; background: rgba(8, 12, 10, .45); z-index: 50; animation: fade .18s ease; }
.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 51; max-height: 92dvh; overflow-y: auto; overscroll-behavior: contain;
  background: var(--card); border-radius: 24px 24px 0 0; padding: 8px 18px calc(18px + var(--safe-b));
  animation: up .24s cubic-bezier(.2, .9, .3, 1); max-width: 640px; margin: 0 auto;
}
@media (min-width: 700px) {
  .sheet { bottom: auto; top: 50%; transform: translateY(-50%); border-radius: 24px; max-width: 520px; animation: pop .2s ease; padding-bottom: 18px; }
}
.sheet .grip { width: 40px; height: 5px; background: var(--line); border-radius: 99px; margin: 2px auto 10px; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; gap: 8px; }
.sheet-head h2 { font-size: 19px; margin: 0; font-weight: 800; }
@keyframes up { from { transform: translateY(100%); } }
@keyframes pop { from { opacity: 0; transform: translateY(-46%); } }
@keyframes fade { from { opacity: 0; } }

.field { margin-bottom: 14px; }
.field > label { display: block; font-size: 13px; color: var(--text-2); font-weight: 600; margin-bottom: 6px; }
.input, .select, .textarea {
  width: 100%; height: 48px; border-radius: 14px; background: var(--card-2); border: 1.5px solid transparent; padding: 0 14px; font-size: 16px;
}
.textarea { height: auto; min-height: 90px; padding: 12px 14px; resize: vertical; font-size: 14px; }
.input:focus, .select:focus, .textarea:focus { border-color: var(--brand); background: var(--card); }
.select { appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2395A09B' stroke-width='3'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 36px; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.amount-input { display: flex; align-items: baseline; gap: 4px; border-bottom: 2px solid var(--line); padding: 6px 2px 8px; margin-bottom: 8px; }
.amount-input:focus-within { border-color: var(--brand); }
.amount-input input { flex: 1; min-width: 0; border: 0; background: none; font-size: 34px; font-weight: 800; letter-spacing: -0.03em; padding: 0; }
.amount-input span { font-size: 22px; font-weight: 700; color: var(--text-2); }
.quick { display: flex; gap: 6px; margin-bottom: 16px; flex-wrap: wrap; }
.quick button { padding: 6px 11px; border-radius: 10px; background: var(--card-2); font-size: 13px; font-weight: 600; color: var(--text-2); }
.cat-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin-bottom: 16px; }
.cat-grid button { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 2px; border-radius: 14px; font-size: 11.5px; font-weight: 600; color: var(--text-2); border: 1.5px solid transparent; }
.cat-grid button .e { font-size: 22px; line-height: 1; }
.cat-grid button.on { background: var(--brand-2); color: var(--brand-ink); border-color: var(--brand); }
.cat-grid button span:last-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.toggle-row { display: flex; align-items: center; justify-content: space-between; padding: 6px 0 14px; }
.switch { width: 50px; height: 30px; border-radius: 99px; background: var(--line); position: relative; transition: background .2s; flex: none; }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: transform .2s; }
.switch.on { background: var(--brand); } .switch.on::after { transform: translateX(20px); }
.who-pick { display: flex; gap: 8px; flex-wrap: wrap; }
.who-pick button { padding: 9px 14px; border-radius: 12px; background: var(--card-2); font-weight: 600; font-size: 14px; display: inline-flex; gap: 6px; align-items: center; border: 1.5px solid transparent; }
.who-pick button.on { border-color: var(--text); background: var(--card); }
.colors { display: flex; gap: 10px; flex-wrap: wrap; }
.colors button { width: 34px; height: 34px; border-radius: 50%; border: 3px solid transparent; outline: 2px solid transparent; }
.colors button.on { outline-color: var(--text); border-color: var(--card); }

.btn { height: 52px; border-radius: 16px; font-weight: 700; font-size: 16px; width: 100%; display: flex; align-items: center; justify-content: center; gap: 8px; }
.btn.primary { background: var(--brand); color: #fff; }
.btn.primary:disabled { opacity: .45; }
.btn.ghost { background: var(--card-2); color: var(--text); }
.btn.danger { background: transparent; color: var(--danger); }
.btn.small { height: 40px; font-size: 14px; border-radius: 12px; width: auto; padding: 0 14px; }
.btn-row { display: flex; gap: 8px; margin-top: 6px; }
.btn-row .btn { flex: 1; }
.link-btn { color: var(--brand-ink); font-weight: 700; font-size: 14px; }

/* ---------- 확인함 ---------- */
.inbox-item { background: var(--card); border-radius: 18px; padding: 14px 16px; box-shadow: var(--shadow); margin-bottom: 10px; }
.inbox-item .top { display: flex; justify-content: space-between; gap: 10px; }
.inbox-item .top b { font-size: 15px; }
.inbox-item .raw { font-size: 12.5px; color: var(--text-2); background: var(--card-2); border-radius: 10px; padding: 8px 10px; margin: 10px 0; white-space: pre-wrap; word-break: break-all; max-height: 96px; overflow: hidden; }
.quick-cats { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin-top: 10px; }
.quick-cats::-webkit-scrollbar { display: none; }
.quick-cats button { flex: none; padding: 7px 11px; border-radius: 11px; background: var(--card-2); font-size: 13px; font-weight: 600; }
.quick-cats button:active { background: var(--brand-2); }

.code-box { display: flex; align-items: center; gap: 8px; background: var(--card-2); border-radius: 12px; padding: 10px 12px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12.5px; word-break: break-all; }
.code-box span { flex: 1; }
.steps { margin: 6px 0 0; padding-left: 20px; color: var(--text-2); font-size: 14px; }
.steps li { margin-bottom: 6px; }
.steps b { color: var(--text); }
.parse-result { background: var(--card-2); border-radius: 14px; padding: 12px 14px; font-size: 14px; margin-top: 10px; }
.parse-result div { display: flex; justify-content: space-between; padding: 3px 0; gap: 10px; }
.parse-result div span:first-child { color: var(--text-3); flex: none; }
.parse-result div span:last-child { text-align: right; font-weight: 600; }

/* ---------- 로그인 ---------- */
.auth { max-width: 400px; margin: 0 auto; padding: calc(var(--safe-t) + 10vh) 22px 40px; }
.logo-mark { width: 72px; height: 72px; display: block; filter: drop-shadow(0 10px 22px rgba(11,138,94,.28)); }
.auth h1 { font-size: 26px; margin: 22px 0 6px; letter-spacing: -0.03em; }
.auth p.lead { color: var(--text-2); margin: 0 0 28px; }
.auth .switch-mode { text-align: center; margin-top: 18px; font-size: 14px; color: var(--text-2); }
.err { color: var(--danger); font-size: 13.5px; margin: -4px 0 12px; }
.choice { display: block; width: 100%; text-align: left; background: var(--card); border-radius: 18px; padding: 18px; box-shadow: var(--shadow); margin-bottom: 10px; border: 2px solid transparent; }
.choice.on { border-color: var(--brand); }
.choice b { font-size: 16px; display: block; margin-bottom: 2px; }
.choice span { color: var(--text-2); font-size: 14px; }
.splash { position: fixed; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px; background: #14A372; color: #fff; z-index: 100; }
.splash img { width: 132px; height: 132px; animation: splash-in .5s ease both; }
.splash b { font-size: 17px; font-weight: 700; letter-spacing: -0.01em; opacity: .92; animation: splash-in .5s .08s ease both; }
@keyframes splash-in { from { opacity: 0; transform: scale(.94); } }

/* ---------- 토스트 ---------- */
#toast-root { position: fixed; left: 0; right: 0; top: calc(var(--safe-t) + 12px); z-index: 60; display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; }
.toast { background: rgba(23, 32, 28, .92); color: #fff; padding: 11px 16px; border-radius: 14px; font-size: 14px; font-weight: 600; max-width: 90vw; animation: toastIn .25s ease; box-shadow: 0 6px 20px rgba(0,0,0,.2); }
@keyframes toastIn { from { opacity: 0; transform: translateY(-8px); } }
.spin { width: 22px; height: 22px; border: 3px solid var(--line); border-top-color: var(--brand); border-radius: 50%; animation: rot .8s linear infinite; margin: 30px auto; }
@keyframes rot { to { transform: rotate(360deg); } }
.hide { display: none !important; }

/* =================== v2 추가 =================== */
.side { display: none; }
.mobile-only { }
.hint { font-size: 11px; font-weight: 600; color: var(--text-3); background: var(--card-2); padding: 1px 6px; border-radius: 6px; margin-left: 4px; }
.kpis { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 12px; }
.kpis .card { margin-bottom: 0; }
.kpi .label { font-size: 13px; color: var(--text-2); font-weight: 600; }
.kpi .big { font-size: 30px; font-weight: 800; letter-spacing: -0.035em; margin-top: 2px; }
.kpi .mid { font-size: 19px; font-weight: 800; letter-spacing: -0.02em; margin-top: 4px; }
.kpi.main { grid-column: 1 / -1; }
.top-extra { display: flex; align-items: center; gap: 6px; }
.today-chip { padding: 5px 10px; font-size: 12.5px; margin-left: 6px; box-shadow: none; background: var(--card-2); }
.banner.invite { align-items: flex-start; background: var(--brand-2); }
.banner-actions { display: flex; gap: 6px; margin-top: 10px; }
.banner-actions .btn { background: var(--card); }
.list-tools { margin-bottom: 4px; }
.chip-select { flex: none; appearance: none; -webkit-appearance: none; border: 0; padding: 7px 28px 7px 13px; border-radius: 99px; background: var(--card) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 24 24' fill='none' stroke='%2395A09B' stroke-width='3'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 11px center; font-size: 13.5px; font-weight: 600; color: var(--text-2); box-shadow: var(--shadow); max-width: 170px; }
.chip-select.on { background-color: var(--text); color: var(--card); }
.day-head .income, .income { color: var(--income); }
.tip { background: var(--brand-2); color: var(--text); border-radius: 14px; padding: 11px 13px; font-size: 13.5px; line-height: 1.5; margin: 0 0 12px; }
.tip .link-btn { font-size: 13.5px; margin-left: 4px; }
.rec-row, .sub-pick { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; margin: -4px 0 14px; }
.rec-label { font-size: 12px; font-weight: 700; color: var(--brand-ink); background: var(--brand-2); padding: 4px 8px; border-radius: 8px; }
.rec-row button, .sub-pick button { padding: 7px 11px; border-radius: 11px; background: var(--card-2); font-size: 13px; font-weight: 600; border: 1.5px solid transparent; }
.rec-row button.on, .sub-pick button.on { border-color: var(--brand); background: var(--brand-2); color: var(--brand-ink); }
.sub-pick { margin: 6px 0 0; padding: 10px; background: var(--card-2); border-radius: 14px; }
.sub-pick button { background: var(--card); }
.sub-pick button.add, .sub-list button.add { color: var(--brand-ink); background: transparent; border: 1.5px dashed var(--line); }
.sug { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.sug button { padding: 6px 10px; border-radius: 10px; background: var(--card-2); font-size: 13px; font-weight: 600; }
.sug button .muted { font-weight: 500; font-size: 11.5px; }
.on-ic { background: var(--brand-2) !important; outline: 2px solid var(--brand); }
.quick-cats button.rec { background: var(--brand-2); color: var(--brand-ink); }
.quick-cats button em { font-style: normal; font-size: 10.5px; font-weight: 800; background: var(--brand); color: #fff; border-radius: 5px; padding: 1px 4px; margin-right: 4px; }
.seg.mini { padding: 2px; border-radius: 10px; flex: none; }
.seg.mini button { padding: 5px 9px; font-size: 12.5px; border-radius: 8px; }
.pm-item { gap: 10px; }
.pm-item .tt { min-width: 0; overflow: hidden; }
.step-card { display: flex; gap: 12px; background: var(--card-2); border-radius: 16px; padding: 14px; margin-bottom: 10px; }
.step-n { width: 26px; height: 26px; border-radius: 50%; background: var(--brand); color: #fff; font-weight: 800; display: grid; place-items: center; flex: none; font-size: 14px; }
.step-card > div:last-child { min-width: 0; flex: 1; }
.url-box { font-family: ui-monospace, Menlo, monospace; font-size: 11.5px; word-break: break-all; background: var(--card); border-radius: 10px; padding: 8px 10px; margin: 8px 0; color: var(--text-2); }
.mini-steps { font-size: 13px; color: var(--text-2); margin-top: 8px; line-height: 1.55; }
.mini-steps i { font-style: normal; font-weight: 700; color: var(--text); }
code { background: var(--card); padding: 1px 5px; border-radius: 5px; font-size: 12px; }
.adv { margin: -4px 0 14px; }
.adv summary { font-size: 13px; color: var(--text-2); font-weight: 600; cursor: pointer; padding: 6px 0; }
.stat-ctrl { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.tab-stats .topbar { flex-wrap: wrap; gap: 8px; }
.legend-row { display: flex; align-items: center; gap: 8px; font-size: 13.5px; padding: 3px 0; }
.legend-row span { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.caret { font-size: 9px; color: var(--text-3); margin-left: 6px; }
.sub-rows { background: var(--card-2); border-radius: 14px; padding: 4px 10px; margin: 2px 0 8px 46px; }
.sub-row { display: grid; grid-template-columns: 1fr auto 44px; gap: 8px; align-items: center; width: 100%; text-align: left; padding: 8px 2px; font-size: 13.5px; }
.sub-row + .sub-row { border-top: 1px solid var(--line); }
.sub-row small { color: var(--text-3); text-align: right; }
.sub-row.all span { color: var(--brand-ink); font-weight: 700; font-size: 13px; }
.merch-row { display: flex; align-items: center; gap: 10px; padding: 7px 0; font-size: 14px; }
.merch-row .rank { width: 22px; height: 22px; border-radius: 7px; background: var(--card-2); display: grid; place-items: center; font-size: 12px; font-weight: 800; color: var(--text-2); flex: none; }
.merch-row .nm { display: flex; justify-content: space-between; margin-bottom: 4px; font-weight: 600; }
.bars.two .pair { display: flex; gap: 2px; align-items: flex-end; height: 100%; width: 100%; justify-content: center; }
.bars.two .pair i { max-width: 12px; flex: 1; background: var(--brand); opacity: .85; }
.bars.two .pair i.inc { background: var(--income); opacity: .55; }
.bars.two { gap: 4px; }
.bars.two .b { gap: 4px; }
.bars.two .b small { font-size: 10px; }
.tbl-card { padding: 0; overflow: hidden; }
.tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
.tbl th { text-align: left; font-size: 12.5px; color: var(--text-3); font-weight: 700; padding: 11px 14px; border-bottom: 1px solid var(--line); background: var(--card-2); position: sticky; top: 0; }
.tbl td { padding: 10px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl .r { text-align: right; }
.tbl tr.row { cursor: pointer; }
.tbl tr.row:hover td { background: var(--card-2); }
.tbl tr.grp td { background: var(--bg); font-size: 13px; padding: 8px 14px; }
.tbl tr.grp td .num { float: right; color: var(--text-2); font-weight: 600; }
.tbl .amt { font-weight: 700; white-space: nowrap; }
.tbl .amt.income { color: var(--income); } .tbl .amt.transfer { color: var(--text-3); }
.tbl tr.cancelled td b, .tbl tr.cancelled .amt { text-decoration: line-through; color: var(--text-3); }
.tbl .memo { display: block; font-size: 12.5px; color: var(--text-3); margin-top: 1px; }
.tbl tr.sum td { font-weight: 800; background: var(--brand-2); }
.tbl .neg { color: var(--danger); } .tbl .pos { color: var(--brand-ink); }
.month-tbl td, .month-tbl th { padding: 9px 14px; }
.cat-pill { display: inline-flex; gap: 4px; align-items: center; font-size: 13px; white-space: nowrap; }
.who-chip { display: inline-flex; align-items: center; gap: 5px; font-size: 13px; color: var(--text-2); }
.sub-list { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 16px 12px 58px; }
.sub-list button { padding: 5px 10px; border-radius: 9px; background: var(--card-2); font-size: 12.5px; font-weight: 600; }
.inbox-grid, .settings-grid { display: block; }
.sheet.wide { max-width: 720px; }

/* =================== PC 화면 =================== */
  html.desk body { font-size: 15px; }
  html.desk .nav, html.desk .fab, html.desk .mobile-only { display: none !important; }
  html.desk .side { display: flex; flex-direction: column; position: fixed; top: 0; bottom: 0; left: 0; width: 232px; background: var(--card); border-right: 1px solid var(--line); padding: 22px 14px; z-index: 20; }
  html.desk .side-brand { display: flex; align-items: center; gap: 10px; padding: 0 6px 18px; }
  html.desk .side-brand b { display: block; font-size: 16px; }
  html.desk .side-brand span { font-size: 12.5px; color: var(--text-3); }
  html.desk .logo-mark.sm { width: 40px; height: 40px; filter: none; }
  html.desk .side-add { height: 46px; margin-bottom: 18px; font-size: 15px; }
  html.desk .side-add svg { width: 20px; height: 20px; }
  html.desk .side nav { display: flex; flex-direction: column; gap: 2px; }
  html.desk .side nav button { display: flex; align-items: center; gap: 12px; padding: 11px 12px; border-radius: 12px; font-weight: 600; color: var(--text-2); text-align: left; }
  html.desk .side nav button svg { width: 20px; height: 20px; }
  html.desk .side nav button:hover { background: var(--card-2); }
  html.desk .side nav button.on { background: var(--brand-2); color: var(--brand-ink); }
  html.desk .side nav button em { margin-left: auto; font-style: normal; background: var(--danger); color: #fff; font-size: 11.5px; font-weight: 700; border-radius: 99px; padding: 1px 8px; }
  html.desk .side-foot { margin-top: auto; display: flex; flex-direction: column; gap: 6px; padding: 0 8px; }
  html.desk .shell { max-width: none; margin: 0; padding: 26px 36px 48px calc(232px + 36px); }
  html.desk .shell > * { max-width: 1240px; }
  html.desk .topbar { padding-top: 0; }
  html.desk .month-switch h1 { font-size: 26px; }
  html.desk .kpis { grid-template-columns: minmax(0, 1.7fr) repeat(3, minmax(0, 1fr)); gap: 12px; }
  html.desk .kpi.main { grid-column: auto; }
  html.desk .kpi .big { font-size: 26px; }
  html.desk .kpi .mid { font-size: 22px; }
  html.desk .grid-2 { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 16px; align-items: start; }
  html.desk .grid-cal { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(320px, 1fr); gap: 16px; align-items: start; }
  html.desk .day-panel { position: sticky; top: 20px; max-height: calc(100vh - 40px); overflow: auto; }
  html.desk .day-panel .day-head:first-of-type { padding-top: 4px; }
  html.desk .day-panel-head { display: flex; justify-content: space-between; align-items: center; padding: 4px 4px 2px; font-size: 16px; }
  html.desk .cal.big { gap: 0; border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
  html.desk .cal.big .wd { border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 8px 0; background: var(--card-2); }
  html.desk .cal.big .d { min-height: 112px; border-radius: 0; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); align-items: stretch; text-align: right; padding: 6px 8px; gap: 2px; }
  html.desk .cal.big .d .n { align-self: flex-start; }
  html.desk .cal.big .d .e, html.desk .cal.big .d .i { font-size: 12.5px; }
  html.desk .cal.big .d .it { font-size: 11.5px; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-align: left; }
  html.desk .cal.big .d .it.more { color: var(--brand-ink); font-weight: 600; }
  html.desk .cal.big .d:hover { background: var(--card-2); }
  html.desk .cal.big .d.sel { background: var(--brand-2); }
  html.desk .list-tools { display: flex; gap: 10px; align-items: center; margin-bottom: 8px; }
  html.desk .list-tools .search { width: 340px; margin: 0; flex: none; }
  html.desk .tbl th { top: 0; }
  html.desk .inbox-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: start; }
  html.desk .settings-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: start; }
  html.desk .settings-grid .sec-title:first-child { margin-top: 0; }
  html.desk #toast-root { top: 20px; }

.tx .em .rep { position: absolute; left: -3px; top: -3px; font-style: normal; font-size: 10px; background: var(--card); color: var(--text-3); border-radius: 50%; width: 15px; height: 15px; display: grid; place-items: center; box-shadow: 0 0 0 1.5px var(--line); }
.cal .d .tr { font-size: 10.5px; font-weight: 600; color: var(--text-3); }

.tbl .save, .num.save { color: var(--save); }
.row2.flow { grid-template-columns: 1fr 1fr; }
optgroup { font-weight: 700; }
 html:not(.desk) .kpis .kpi:last-child { grid-column: 1 / -1; } 

.fav { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: -4px 0 12px; align-items: center; }
.fav::-webkit-scrollbar { display: none; }
.fav button { flex: none; padding: 7px 11px; border-radius: 11px; background: var(--card-2); font-size: 13px; font-weight: 600; white-space: nowrap; }
.fav .rec-label { flex: none; }
.who-row { display: flex; align-items: center; gap: 8px; margin: -2px 0 12px; flex-wrap: wrap; }
.who-row .who-pick button { padding: 7px 12px; font-size: 13.5px; }
.more-box { background: var(--card-2); border-radius: 14px; padding: 12px 14px; margin-bottom: 12px; }
.more-box summary { list-style: none; cursor: pointer; font-size: 13.5px; color: var(--text-2); display: flex; gap: 8px; align-items: center; }
.more-box summary::-webkit-details-marker { display: none; }
.more-box summary .chg { margin-left: auto; color: var(--brand-ink); font-weight: 700; flex: none; }
.more-box[open] summary .chg { display: none; }
.more-box .input, .more-box .select { background: var(--card); }
.save-bar { position: sticky; bottom: calc(-18px - var(--safe-b)); background: var(--card); padding: 10px 0 calc(4px + var(--safe-b)); margin-top: 4px; }
.pm-ctrls { display: flex; flex-direction: column; gap: 6px; align-items: flex-end; flex: none; }
.pill { padding: 4px 10px; border-radius: 99px; font-size: 12px; font-weight: 700; background: var(--card-2); color: var(--text-2); }
.pill.on { background: var(--brand-2); color: var(--brand-ink); }
.who-mini { display: flex; gap: 6px; margin-top: 10px; }
.who-mini button { padding: 5px 10px; border-radius: 99px; background: var(--card-2); font-size: 12.5px; font-weight: 600; display: inline-flex; align-items: center; gap: 5px; border: 1.5px solid transparent; }
.who-mini button.on { border-color: var(--text); background: var(--card); }
.tx .t2 .who-txt { font-weight: 700; }
.memo-field { margin-top: -6px; }
.memo-field .input { height: 42px; font-size: 14.5px; }
.m-pick .item { cursor: pointer; }
.m-pick input { width: 20px; height: 20px; accent-color: var(--brand); flex: none; }
.ok-box { background: var(--card-2); border-radius: 14px; padding: 14px; text-align: center; color: var(--text-2); font-size: 14px; }

/* =================== 작은 PC·노트북·태블릿 가로 (880~1279px) =================== */
  html.compact .side { width: 84px; padding: 18px 10px; align-items: center; }
  html.compact .side-brand { padding: 0 0 14px; }
  html.compact .side-brand > div:last-child, html.compact .side-add span, html.compact .side nav button span, html.compact .side-foot { display: none; }
  html.compact .side-add { width: 52px; height: 52px; padding: 0; border-radius: 16px; }
  html.compact .side nav button { justify-content: center; padding: 12px; position: relative; flex-direction: column; gap: 4px; }
  html.compact .side nav button span { display: block; font-size: 11px; }
  html.compact .side nav button em { position: absolute; top: 4px; right: 4px; margin: 0; padding: 0 6px; font-size: 10.5px; }
  html.compact .shell { padding: 22px 24px 40px calc(84px + 24px); }
  html.compact .kpis { grid-template-columns: repeat(2, 1fr); }
  html.compact .kpi .big { font-size: 24px; }
  html.compact .tbl td, html.compact .tbl th { padding-left: 10px; padding-right: 10px; }
  html.compact .tbl td { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 180px; }
  html.compact .list-tools { flex-wrap: wrap; }
  html.compact .grid-cal { grid-template-columns: minmax(0, 1fr); }
  html.compact .day-panel { position: static; max-height: none; }
  html.compact .cal.big { grid-template-columns: repeat(7, minmax(0, 1fr)); }
  html.compact .cal.big .d { min-height: 96px; }


/* PC 홈: 요약 4칸 + 예산 카드 */
.kpis-d { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 12px; }
.kpis-d .card { margin-bottom: 0; }
.kd .label, .bud-d .label { font-size: 13px; color: var(--text-2); font-weight: 600; }
.kd .v { font-size: 24px; font-weight: 800; letter-spacing: -0.03em; margin: 4px 0 2px; white-space: nowrap; }
.kd .sub { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bud-d { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 24px; row-gap: 18px; align-items: end; margin-bottom: 16px; }
.bud-d .v { font-size: 30px; font-weight: 800; letter-spacing: -0.035em; margin: 4px 0 4px; white-space: nowrap; }
.bud-d .v small { font-size: 16px; font-weight: 700; color: var(--text-2); }
.bud-stats { display: flex; gap: 28px; align-items: flex-end; }
.bud-stats > div { display: flex; flex-direction: column; gap: 2px; text-align: right; }
.bud-stats span { font-size: 12.5px; color: var(--text-3); white-space: nowrap; }
.bud-stats b { font-size: 17px; white-space: nowrap; }
.bud-stats .link-btn { margin: 0 0 2px; white-space: nowrap; }
.bud-bar { grid-column: 1 / -1; position: relative; height: 12px; background: var(--card-2); border-radius: 99px; margin-bottom: 14px; }
.bud-bar > i { display: block; height: 100%; background: var(--brand); border-radius: 99px; transition: width .4s; }
.bud-bar.warn > i { background: var(--warn); } .bud-bar.over > i { background: var(--danger); }
.bud-bar em { position: absolute; top: -4px; bottom: -4px; width: 2px; background: var(--text); border-radius: 2px; transform: translateX(-1px); }
.bud-bar em span { position: absolute; top: 22px; left: 50%; transform: translateX(-50%); font-size: 11px; font-style: normal; color: var(--text-3); white-space: nowrap; }
.bud-empty { display: flex; align-items: center; gap: 14px; width: 100%; text-align: left; margin-bottom: 16px; }
.bud-empty > span:first-child { font-size: 26px; }
.bud-empty b { display: block; font-size: 15px; } .bud-empty div span { font-size: 13px; color: var(--text-3); }
.bud-empty .chev { margin-left: auto; color: var(--text-3); }
  html.compact .kpis-d { gap: 10px; }
  html.compact .kpis-d .card { padding: 16px; }
  html.compact .kd .v { font-size: 20px; }
  html.compact .bud-d { grid-template-columns: minmax(0, 1fr); }
  html.compact .bud-stats { justify-content: flex-start; flex-wrap: wrap; row-gap: 10px; }
  html.compact .bud-stats > div { text-align: left; }


/* 태블릿 세로·폴드 펼침 (600~879px): 한 단으로, 표는 핵심 열만 */
  html.narrow .shell { padding: 18px 16px 32px calc(84px + 16px); }
  html.narrow .grid-2, html.narrow .grid-cal, html.narrow .inbox-grid, html.narrow .settings-grid { display: block; }
  html.narrow .tbl th:nth-child(4), html.narrow .tbl td:nth-child(4) { display: none; }
  html.narrow .tbl td { max-width: 150px; }
  html.narrow .list-tools .search { width: 100%; }
  html.narrow .kd .v { font-size: 18px; }
  html.narrow .kpis-d .card { padding: 14px; }
  html.narrow .cal.big .d { min-height: 84px; padding: 4px 5px; }

/* 폭 700px 미만 넓은 화면 (작은 폴드 등) */
html.slim .kpis-d { grid-template-columns: repeat(2, minmax(0, 1fr)); }
html.slim .shell { padding-left: calc(76px + 12px); padding-right: 12px; }
html.slim .side { width: 76px; }
html.slim .tbl th:nth-child(2), html.slim .tbl td:nth-child(2) { display: none; }
.banner.push-ask { align-items: flex-start; background: var(--brand-2); }
.banner.push-ask .banner-actions .btn.primary { background: var(--brand); color: #fff; }
.menu .item .switch { margin-left: auto; }
.who-tag { display: inline-block; font-size: 11.5px; font-weight: 700; line-height: 1.5; padding: 0 6px; margin-right: 5px; border-radius: 6px; color: var(--c); background: color-mix(in srgb, var(--c) 13%, transparent); vertical-align: 1px; }
.merge-sug { background: var(--brand-2); box-shadow: none; margin-bottom: 12px; }
.merge-sug .btn-row { display: flex; gap: 6px; }
.merge-sug .btn.ghost { background: var(--card); }
/* 캡처로 입력 */
.head-btns { display: flex; gap: 4px; }
.cap-wait { text-align: center; padding: 28px 8px 18px; }
.cap-banner { display: flex; align-items: center; justify-content: space-between; gap: 10px; background: var(--brand-2); border-radius: 14px; padding: 12px 14px; margin-bottom: 10px; }
.cap-banner b { display: block; font-size: 14.5px; } .cap-banner span { font-size: 12.5px; color: var(--text-2); }
.cap-banner .btn { background: var(--card); flex: none; }
.cap-warn { font-size: 13px; line-height: 1.5; background: #FFF6E5; color: #8A5A00; border-radius: 12px; padding: 10px 12px; margin-bottom: 10px; }
.cap-warn.pm { background: #EEF4FF; color: #2F4F8A; }
@media (prefers-color-scheme: dark) { .cap-warn { background: #3A2E14; color: #F5D38A; } .cap-warn.pm { background: #1C2840; color: #A9C2F5; } }
/* 메모 추천 */
.memo-rec { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; margin-top: 8px; }
.memo-rec button { padding: 6px 11px; border-radius: 99px; background: var(--card-2); font-size: 13px; font-weight: 600; }
.memo-auto { margin-top: 6px; color: var(--brand-ink); }
/* 자산(결제수단) 고르기 */
.pm-btn { width: 100%; display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 14px; background: var(--card); box-shadow: 0 0 0 1px var(--line); text-align: left; min-height: 52px; }
.pm-btn .ic { font-size: 20px; } .pm-btn .tt { flex: 1; min-width: 0; font-weight: 700; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pm-btn .tt small { display: block; font-weight: 500; font-size: 12px; color: var(--text-3); }
.pm-btn.empty .tt { color: var(--text-3); font-weight: 600; } .pm-btn .chev { color: var(--text-3); }
.pm-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 6px; }
.pm-card { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 12px; border-radius: 14px; background: var(--card-2); border: 2px solid transparent; text-align: left; min-height: 84px; }
.pm-card .ic { font-size: 22px; margin-bottom: 2px; } .pm-card b { font-size: 14.5px; line-height: 1.3; word-break: keep-all; } .pm-card small { font-size: 12px; color: var(--text-3); }
.pm-card.on { border-color: var(--brand); background: var(--brand-2); }
.pm-card.add { border: 2px dashed var(--line); background: transparent; }
@media (min-width: 600px) { .pm-grid { grid-template-columns: repeat(3, 1fr); } }
/* 자산 */
.asset-box { background: var(--card-2); border-radius: 14px; padding: 12px 12px 10px; margin-bottom: 14px; }
.asset-box .field { margin-bottom: 8px; } .asset-box .select, .asset-box .input { background: var(--card); }
.asset-sum { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.asset-sum span { display: block; font-size: 12.5px; color: var(--text-2); font-weight: 600; } .asset-sum b { font-size: 17px; white-space: nowrap; }
.num.neg { color: var(--danger); }
.asset-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 8px; }
.asset-item { background: var(--card); border-radius: 16px; padding: 14px; box-shadow: var(--shadow); }
.asset-item .top { display: flex; align-items: center; gap: 10px; } .asset-item .ic { font-size: 22px; }
.asset-item .tt { flex: 1; min-width: 0; } .asset-item .tt b { display: block; font-size: 15px; } .asset-item .tt small { font-size: 12px; color: var(--text-3); }
.asset-item .big { font-size: 17px; white-space: nowrap; } .asset-item .r { text-align: right; } .asset-item .r small { display: block; font-size: 11.5px; color: var(--text-3); }
.asset-sub { font-size: 13px; color: var(--text-2); margin: 8px 0 0 32px; }
.asset-acts { display: flex; gap: 6px; margin: 10px 0 0 32px; } .asset-acts button { padding: 6px 11px; border-radius: 99px; background: var(--card-2); font-size: 12.5px; font-weight: 600; }
.warn-t { color: #B7791F; }
.asset-due { display: block; width: 100%; text-align: left; background: #FFF6E5; color: #8A5A00; border-radius: 12px; padding: 10px 12px; font-size: 13px; margin-bottom: 8px; }
.asset-mini .asset-row { display: flex; align-items: center; gap: 8px; padding: 7px 0; } .asset-mini .nm { flex: 1; min-width: 0; font-weight: 600; } .asset-mini .nm small { color: var(--text-3); font-weight: 500; margin-left: 4px; }
.asset-mini .asset-sub { margin: -4px 0 4px 28px; font-size: 12.5px; }
.asset-empty { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; } .asset-empty > span:first-child { font-size: 24px; } .asset-empty b { display: block; } .asset-empty div span { font-size: 13px; color: var(--text-3); } .asset-empty .chev { margin-left: auto; color: var(--text-3); }
.emo-ic { width: 20px; text-align: center; font-size: 16px; }
@media (prefers-color-scheme: dark) { .asset-due { background: #3A2E14; color: #F5D38A; } }
/* 홈: 남은 생활비 */
.hero { padding: 20px 20px 18px; }
.hero-top { display: flex; justify-content: space-between; align-items: center; }
.hero-top .label { font-size: 14px; font-weight: 700; color: var(--text-2); }
.hero-top .link-btn { margin: 0; font-size: 13px; }
.hero-big { font-size: 34px; font-weight: 800; letter-spacing: -0.035em; margin: 4px 0 14px; }
.hero-big.neg { color: var(--danger); }
.hero .bud-bar { margin-bottom: 8px; }
.hero .bud-bar em span { display: none; }
.hero-meta { display: flex; justify-content: space-between; font-size: 13px; color: var(--text-2); }
.hero-tip { margin-top: 12px; font-size: 14px; background: var(--card-2); border-radius: 12px; padding: 10px 12px; }
.hero-note { margin-top: 8px; font-size: 12.5px; color: var(--text-3); }
html.desk .hero-big { font-size: 40px; }
.pw-wrap { position: relative; } .pw-wrap .input { padding-right: 64px; }
.pw-eye { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); font-size: 13px; font-weight: 600; color: var(--text-2); padding: 6px 8px; border-radius: 8px; }
