:root {
  --paper: #f4f1e9;
  --ink: #252520;
  --muted: #89867c;
  --line: rgba(37, 37, 32, 0.10);
  --card: rgba(255, 255, 255, 0.62);
  --accent: #e7643f;
  --shadow: 0 22px 70px rgba(53, 47, 33, 0.15);
}
* { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100vh;
  background: radial-gradient(circle at 20% 10%, #fff9e9 0, transparent 30%), #d9d5ca;
  color: var(--ink);
  font-family: "Manrope", "Gowun Dodum", sans-serif;
}
button, input { font: inherit; }
button { color: inherit; }
.phone-shell { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.app {
  position: relative; width: min(100%, 430px); height: min(900px, calc(100vh - 48px)); min-height: 720px;
  overflow: hidden; padding: 0; border-radius: 42px;
  background: var(--paper); box-shadow: var(--shadow); border: 1px solid rgba(255,255,255,.8);
}
.app-content { height: 100%; overflow-y: auto; scrollbar-width: none; padding: 20px 22px 120px; }
.app-content::-webkit-scrollbar { display: none; }
.view { display: none; animation: viewIn .28s ease both; }
.view.active { display: block; }
.page-header { min-height: 92px; display: flex; align-items: end; justify-content: space-between; padding: 8px 3px 18px; }
.page-header h1 { margin: 0; font-size: 34px; letter-spacing: -.05em; }
.round-action { width: 40px; height: 40px; border: 1px solid var(--line); border-radius: 50%; background: rgba(255,255,255,.45); font-size: 20px; cursor: pointer; }
.topbar { display: grid; grid-template-columns: 92px 1fr 40px; align-items: center; padding: 4px 0 18px; }
.icon-button, .month-switcher button, .text-button, .close-button { border: 0; background: transparent; cursor: pointer; }
.icon-button { width: 38px; height: 38px; border-radius: 50%; background: #e4ddcf; font-size: 12px; }
.household-button { height:38px; display:flex;align-items:center;gap:6px;padding:0;border:0;background:transparent;cursor:pointer }.household-button > span { width:30px;height:30px;display:grid;place-items:center;border-radius:10px;background:#2d2c27;color:white;font-size:12px }.household-button b { font-size:11px;white-space:nowrap }.household-button i { color:var(--muted);font-style:normal;font-size:10px }
.dots-menu { background: transparent; letter-spacing: 2px; }
.month-switcher { display: flex; align-items: center; justify-content: center; gap: 5px; }
.month-switcher button { padding: 5px 8px; font-size: 20px; color: var(--muted); }
.month-switcher .month-label { font-size: 14px; font-weight: 700; color: var(--ink); }
.hero { padding: 15px 4px 25px; }
.eyebrow { margin: 0 0 6px; color: var(--muted); font-size: 12px; letter-spacing: .04em; }
.hero h1 { margin: 0; font-size: 36px; letter-spacing: -0.05em; font-weight: 600; }
.budget-line { display: flex; justify-content: space-between; margin-top: 12px; font-size: 12px; color: var(--muted); }
.budget-line strong { color: var(--accent); }
.constellation-card { padding: 18px; border-radius: 30px; background: var(--card); border: 1px solid rgba(255,255,255,.8); box-shadow: 0 10px 35px rgba(56,48,30,.06); }
.card-title { display: flex; justify-content: space-between; font-size: 13px; font-weight: 700; }
.hint { color: var(--muted); font-size: 10px; font-weight: 500; }
.view-mode { border:0;background:transparent;color:var(--muted);font-size:9px;cursor:pointer }
.map-density{display:flex;justify-content:center;gap:3px;margin:12px auto 0;padding:3px;width:max-content;border-radius:20px;background:#ebe7de}.map-density button{border:0;border-radius:16px;padding:6px 10px;background:transparent;color:var(--muted);font-size:8px;cursor:pointer}.map-density button.active{background:#fff;color:var(--ink);box-shadow:0 2px 7px rgba(43,38,28,.07)}
.bubble-field { position: relative; height: 270px; margin-top: 8px; overflow: hidden; }
.bubble { position: absolute; border: 0; border-radius: 50%; display: grid; place-items: center; color: #fff; cursor: pointer; box-shadow: inset 0 1px 3px rgba(255,255,255,.35), 0 8px 20px rgba(38,35,27,.12); transition: transform .25s ease, filter .25s; animation: appear .5s both; }
.bubble::after { content: ""; position: absolute; inset: -6px; border: 1px solid currentColor; border-radius: 50%; opacity: 0; transition: opacity .2s; }
.bubble.active { transform: scale(1.08); filter: saturate(1.12); }
.bubble.active::after { opacity: .35; }
.bubble span { font-size: 10px; font-weight: 700; text-shadow: 0 1px 5px rgba(0,0,0,.18); }
.dot-map { position:relative;width:292px;height:316px;margin:12px auto 6px }
.map-dot { position:absolute;width:3.35px;height:3.35px;padding:0;border:0;border-radius:50%;background:#d8d4cb;cursor:pointer;transition:transform .18s ease,background .35s ease,opacity .35s ease;animation:dotIn .35s both }
.map-dot:hover,.map-dot:focus-visible { transform:scale(2.4);z-index:2;outline:0 }
.map-dot.used { box-shadow:0 .5px 2px rgba(48,42,30,.16) }.map-dot.selected { transform:scale(1.7);filter:saturate(1.25);z-index:1 }
.map-dot.admin-dot{width:5.5px;height:5.5px;margin:-1px 0 0 -1px}.map-dot.admin-dot.selected{transform:scale(1.9);box-shadow:0 0 0 2px var(--paper),0 0 0 3px currentColor;z-index:3}
.map-progress { display:flex;justify-content:space-between;margin:0 2px 12px;color:var(--muted);font-size:8px }.map-progress i{font-style:normal;color:var(--ink);font-weight:700}
.selection { min-height: 45px; padding: 12px 14px; display: flex; justify-content: space-between; align-items: center; background: rgba(244,241,233,.72); border-radius: 16px; font-size: 12px; }
.selection > div { display: flex; gap: 8px; align-items: center; }
.selection-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.region-section{padding-top:25px}.region-list{display:grid;grid-template-columns:1fr 1fr;gap:9px}.region-card{display:grid;grid-template-columns:62px 1fr;gap:9px;align-items:center;min-height:88px;padding:11px;border:0;border-radius:18px;background:rgba(255,255,255,.38);color:var(--ink);text-align:left;cursor:pointer}.region-mini-map{position:relative;width:60px;height:64px}.region-mini-map i{position:absolute;width:2.5px;height:2.5px;border-radius:50%;background:#d2cec5}.region-mini-map i.used{width:4px;height:4px;box-shadow:0 0 0 1.5px rgba(255,255,255,.8)}.region-card strong,.region-card small{display:block}.region-card strong{font-size:10px}.region-card small{margin-top:4px;color:var(--muted);font-size:8px;line-height:1.4}
.recent-section { padding-top: 27px; }
.section-heading { display: flex; justify-content: space-between; align-items: end; padding: 0 3px 12px; }
.section-heading h2, .sheet-header h2 { margin: 0; font-size: 18px; letter-spacing: -.025em; }
.text-button { font-size: 11px; color: var(--muted); padding: 5px; }
.transactions { display: grid; gap: 8px; }
.transaction { width:100%; display: grid; grid-template-columns: 42px 1fr auto; gap: 12px; align-items: center; padding: 12px 14px; border:0; background: rgba(255,255,255,.38); border-radius: 18px; color:var(--ink); text-align:left; cursor:pointer; }
.transaction-icon { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 14px; font-size: 17px; }
.transaction strong { display: block; font-size: 13px; margin-bottom: 3px; }
.transaction small { color: var(--muted); font-size: 10px; }
.transaction-amount { font-size: 12px; font-weight: 700; }
.transaction-amount.income { color:#4f8a68 }.empty-copy{margin:12px 2px;padding:22px;border-radius:18px;background:rgba(255,255,255,.3);color:var(--muted);font-size:10px;text-align:center}
.bottom-nav { position: absolute; z-index: 5; left: 12px; right: 12px; bottom: 12px; height: 72px; padding: 10px 12px; display: grid; grid-template-columns: repeat(5,1fr); align-items: center; background: rgba(250,248,242,.94); border: 1px solid rgba(255,255,255,.95); box-shadow: 0 10px 36px rgba(54,49,36,.13); border-radius: 25px; backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); }
.nav-item { border: 0; background: transparent; display: grid; place-items: center; gap: 4px; color: #aaa69c; cursor: pointer; font-size: 9px; }
.nav-item.active { color: var(--ink); }
.nav-symbol { font-size: 20px; line-height: 1; }
.add-button { width: 50px; height: 50px; place-self: center; border: 0; border-radius: 50%; background: var(--ink); color: white; font-size: 27px; cursor: pointer; box-shadow: 0 10px 20px rgba(37,37,32,.22); }
.sheet-backdrop { position: fixed; inset: 0; z-index: 20; display: grid; place-items: end center; background: rgba(37,34,27,.34); backdrop-filter: blur(5px); }
.sheet-backdrop[hidden] { display: none; }
.sheet { width: min(100%, 430px); padding: 9px 24px 30px; background: #f8f5ed; border-radius: 32px 32px 0 0; box-shadow: 0 -20px 60px rgba(0,0,0,.14); animation: rise .3s ease; }
.sheet-handle { width: 38px; height: 4px; border-radius: 5px; background: #d5d0c5; margin: 0 auto 18px; }
.sheet-header { display: flex; justify-content: space-between; align-items: start; }
.close-button { font-size: 25px; color: var(--muted); }
.amount-input { display: flex; justify-content: center; align-items: baseline; gap: 5px; margin: 26px 0; }
.amount-input span { font-size: 22px; color: var(--muted); }
.amount-input input { width: 220px; border: 0; outline: 0; background: transparent; text-align: center; font-size: 42px; font-weight: 600; color: var(--ink); }
.category-picker { display: flex; gap: 9px; overflow-x: auto; padding: 4px 0 18px; scrollbar-width: none; }
.scope-picker { display:grid;grid-template-columns:1fr 1fr;gap:4px;margin-bottom:14px;padding:4px;background:#e9e5dc;border-radius:14px }.scope-picker button { border:0;background:transparent;border-radius:11px;padding:9px;color:var(--muted);font-size:10px;cursor:pointer }.scope-picker button.active { background:#fff;color:var(--ink);box-shadow:0 3px 10px rgba(40,36,26,.07) }
.type-picker { display:flex;justify-content:center;gap:18px;margin:6px 0 2px }.type-picker button { border:0;border-bottom:2px solid transparent;padding:7px 10px;background:transparent;color:var(--muted);font-size:11px;cursor:pointer }.type-picker button.active { color:var(--ink);border-color:var(--ink);font-weight:700 }
.category-chip { flex: 0 0 auto; border: 1px solid var(--line); background: transparent; border-radius: 50px; padding: 9px 13px; cursor: pointer; font-size: 11px; }
.category-chip.active { background: var(--ink); color: white; }
.memo-field { display: block; margin: 5px 0 18px; padding: 13px 16px; background: #fff; border-radius: 16px; }
.memo-field span { display: block; font-size: 9px; color: var(--muted); margin-bottom: 5px; }
.memo-field input { width: 100%; padding: 0; border: 0; outline: 0; font-size: 13px; }
.memo-field select{width:100%;padding:0;border:0;outline:0;background:transparent;color:var(--ink);font-size:12px}
.save-button { width: 100%; border: 0; border-radius: 17px; padding: 16px; background: var(--accent); color: white; font-weight: 700; cursor: pointer; }
.delete-button { width:100%;margin-top:9px;padding:12px;border:0;background:transparent;color:#b45b4f;font-size:10px;cursor:pointer }
.toast { position: fixed; z-index: 30; left: 50%; bottom: 30px; transform: translate(-50%, 20px); opacity: 0; padding: 11px 17px; background: var(--ink); color: #fff; border-radius: 50px; font-size: 11px; transition: .25s; pointer-events: none; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
@keyframes appear { from { opacity: 0; transform: scale(.5); } }
@keyframes rise { from { transform: translateY(100%); } }
@keyframes viewIn { from { opacity: 0; transform: translateY(5px); } }

.calendar-card { padding: 18px 16px; background: rgba(255,255,255,.5); border-radius: 27px; border: 1px solid rgba(255,255,255,.8); }
.calendar-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.calendar-head button { border: 0; background: transparent; color: var(--muted); font-size: 20px; }
.calendar-head strong { font-size: 13px; }
.weekdays, .calendar-grid { display: grid; grid-template-columns: repeat(7,1fr); text-align: center; }
.weekdays { color: var(--muted); font-size: 9px; margin-bottom: 9px; }
.calendar-grid { row-gap: 7px; }
.calendar-day { position: relative; aspect-ratio: 1; border: 0; background: transparent; border-radius: 50%; font-size: 11px; cursor: pointer; }
.calendar-day.empty { pointer-events: none; }
.calendar-day.has-spend::after { content: ""; position: absolute; width: 4px; height: 4px; border-radius: 50%; background: #d48162; left: calc(50% - 2px); bottom: 4px; }
.calendar-day.selected { background: var(--ink); color: white; }
.calendar-day.selected::after { background: white; }
.journal-section { padding-top: 25px; }
.journal-date { display: flex; gap: 12px; align-items: center; margin: 0 3px 12px; }
.journal-date > span { font-size: 28px; font-weight: 500; }
.journal-date strong, .journal-date small { display: block; }
.journal-date strong { font-size: 11px; }.journal-date small { margin-top: 2px; font-size: 9px; color: var(--muted); }
.muted-date { margin-top: 25px; color: var(--muted); }
.memory-card { display: grid; grid-template-columns: 42px 1fr auto; align-items: center; gap: 12px; padding: 13px 14px; background: rgba(255,255,255,.38); border-radius: 18px; }
.memory-card > span { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 14px; background: #e8dfc8; }
.memory-card strong,.memory-card small { display:block; }.memory-card strong { font-size:12px }.memory-card small { color:var(--muted);font-size:9px;margin-top:3px }.memory-card b { font-size:11px }
.goal-hero { text-align: center; padding: 15px 0 28px; }
.progress-orbit { --progress: 64%; width: 170px; height: 170px; margin: 0 auto 18px; border-radius: 50%; display: grid; place-items: center; background: conic-gradient(var(--accent) var(--progress), #e1ddd3 0); position: relative; }
.progress-orbit::after { content:""; position:absolute; inset:10px; border-radius:50%; background:var(--paper); }
.progress-orbit > div { z-index:1; display:grid; }.progress-orbit strong { font-size:34px;letter-spacing:-.05em }.progress-orbit span { color:var(--muted);font-size:10px }
.goal-hero p { margin:0;color:var(--muted);font-size:11px }.goal-hero h2 { margin:5px 0 3px;font-size:21px }.goal-hero small { color:var(--muted);font-size:10px }
.goal-row { margin-bottom:10px; padding:14px 15px; border-radius:18px; background:rgba(255,255,255,.42); }
.goal-row-head { display:flex;justify-content:space-between;font-size:11px;margin-bottom:10px }.goal-row-head span { display:flex;align-items:center;gap:7px }.goal-row-head i { width:8px;height:8px;border-radius:50% }.goal-row-head b { font-size:10px }
.progress-track { height:5px;border-radius:5px;background:#dfdbd1;overflow:hidden }.progress-track span { display:block;height:100%;border-radius:5px }
.streak-card { display:flex;gap:14px;align-items:center;margin-top:22px;padding:17px;background:#292823;color:#fff;border-radius:21px }.streak-card > span { color:#e4b55a;letter-spacing:2px;font-size:9px }.streak-card strong,.streak-card small { display:block }.streak-card strong { font-size:11px }.streak-card small { margin-top:4px;color:#aaa79e;font-size:8px }
.profile-card { display:grid;grid-template-columns:54px 1fr auto;gap:13px;align-items:center;padding:17px;background:rgba(255,255,255,.5);border-radius:22px }.profile-mark { width:48px;height:48px;display:grid;place-items:center;border-radius:16px;background:#2e2d28;color:white;font-weight:700 }.profile-card strong,.profile-card small {display:block}.profile-card strong{font-size:12px}.profile-card small{margin-top:4px;color:var(--muted);font-size:9px}.profile-card button{width:34px;height:34px;border:1px solid var(--line);border-radius:50%;background:transparent;color:var(--ink);font-size:17px;cursor:pointer}.member-stack { display:flex;align-items:center }.member-stack span { width:34px;height:34px;display:grid;place-items:center;border:2px solid var(--paper);border-radius:50%;background:#2d2c27;color:white;font-size:9px }.member-stack span+span { margin-left:-12px;background:#d28469 }
.settings-group { margin-top:25px }.settings-group > p { margin:0 0 8px 5px;color:var(--muted);font-size:10px }.settings-group button { width:100%;display:flex;justify-content:space-between;align-items:center;padding:14px 12px;border:0;border-bottom:1px solid var(--line);background:transparent;cursor:pointer;font-size:11px }.settings-group button span {display:flex;align-items:center;gap:11px}.settings-group i { width:27px;height:27px;display:grid;place-items:center;border-radius:9px;background:#e6e1d7;font-style:normal }.settings-group b { color:var(--muted);font-size:9px;font-weight:500 }.settings-group .status-good { color:#548a69 }.version { text-align:center;color:#aaa69d;font-size:8px;margin-top:35px }
.popover { position:fixed;z-index:40;top:76px;left:50%;width:min(calc(100% - 40px),390px);transform:translateX(-50%);padding:12px;background:rgba(250,248,242,.97);border:1px solid rgba(255,255,255,.9);border-radius:21px;box-shadow:0 18px 55px rgba(40,35,25,.2);backdrop-filter:blur(20px) }.popover[hidden]{display:none}.popover>p{margin:3px 8px 8px;color:var(--muted);font-size:9px}.popover>button{width:100%;display:grid;grid-template-columns:36px 1fr 20px;gap:10px;align-items:center;padding:9px;border:0;border-radius:14px;background:transparent;text-align:left;cursor:pointer}.popover>button:hover{background:#efebe2}.popover>button>span{width:34px;height:34px;display:grid;place-items:center;border-radius:11px;background:#e3ded3;font-size:11px}.popover>button.active>span{background:var(--ink);color:#fff}.popover strong,.popover small{display:block}.popover strong{font-size:11px}.popover small{margin-top:2px;color:var(--muted);font-size:8px}.popover i{font-style:normal;color:#5c886b}
.invite-sheet{text-align:center;position:relative}.invite-close{position:absolute;right:22px;top:16px}.invite-visual{display:flex;justify-content:center;align-items:center;gap:12px;margin:22px 0}.invite-visual span{width:66px;height:66px;display:grid;place-items:center;border-radius:22px;background:#2d2c27;color:#fff;font-size:13px}.invite-visual span:last-child{background:#e7e1d6;color:var(--muted);border:1px dashed #aaa498}.invite-visual i{color:#bbb5aa;font-style:normal;letter-spacing:3px}.invite-sheet h2{margin:0;font-size:22px}.invite-copy{max-width:260px;margin:10px auto 24px;color:var(--muted);font-size:11px;line-height:1.65}.icloud-note{display:block;margin-top:12px;color:var(--muted);font-size:8px}
.photo-sheet{text-align:center;position:relative}.photo-sheet h2{margin:0;font-size:21px}.photo-orbit{position:relative;width:125px;height:105px;margin:17px auto 10px}.photo-orbit span{position:absolute;left:31px;top:12px;width:62px;height:62px;display:grid;place-items:center;border-radius:50%;background:var(--ink);color:#fff;font-size:25px}.photo-orbit i{position:absolute;width:9px;height:9px;border-radius:50%;background:#d48162}.photo-orbit i:nth-of-type(1){left:11px;top:29px}.photo-orbit i:nth-of-type(2){right:8px;top:19px;background:#668f87}.photo-orbit i:nth-of-type(3){right:24px;bottom:8px;background:#d1a34a}.privacy-points{display:flex;justify-content:center;gap:8px;flex-wrap:wrap;margin:-8px 0 20px}.privacy-points span{padding:6px 8px;border-radius:20px;background:#eae6dd;color:var(--muted);font-size:8px}
.region-sheet{position:relative;max-height:88vh;overflow-y:auto}.region-sheet h2{margin:0;font-size:24px}.region-detail-map{position:relative;width:240px;height:235px;margin:18px auto}.region-detail-map i{position:absolute;width:4px;height:4px;border-radius:50%;background:#d2cec5}.region-detail-map i.used{width:7px;height:7px;box-shadow:0 0 0 2px #f8f5ed}.region-detail-summary{display:flex;justify-content:space-between;align-items:end;padding:14px 2px;border-top:1px solid var(--line)}.region-detail-summary strong{font-size:20px}.region-detail-summary span{color:var(--muted);font-size:9px}.region-place-list{display:grid;gap:7px}.region-place{display:grid;grid-template-columns:32px 1fr auto;gap:9px;align-items:center;padding:10px 11px;border-radius:14px;background:#fff}.region-place i{width:31px;height:31px;display:grid;place-items:center;border-radius:10px;font-style:normal}.region-place strong,.region-place small{display:block}.region-place strong{font-size:10px}.region-place small{margin-top:3px;color:var(--muted);font-size:8px}.region-place b{font-size:9px}
.detail-admin-dot{position:absolute;width:8px;height:8px;padding:0;border:0;border-radius:50%;background:#d2cec5;cursor:pointer}.detail-admin-dot.used{width:11px;height:11px;box-shadow:0 0 0 2px #f8f5ed}.detail-admin-dot span{position:absolute;left:50%;top:12px;transform:translateX(-50%);display:none;padding:3px 5px;border-radius:6px;background:var(--ink);color:#fff;white-space:nowrap;font-size:7px;z-index:3}.detail-admin-dot:hover span,.detail-admin-dot:focus span{display:block}
@keyframes dotIn { from { opacity:0;transform:scale(.2) } }
@media (max-width: 520px) { .phone-shell { padding: 0; } .app { width: 100%; height: 100dvh; min-height: 660px; border-radius: 0; } .app-content { padding-top: max(20px, env(safe-area-inset-top)); padding-bottom: 124px; } .bottom-nav { bottom: max(10px, env(safe-area-inset-bottom)); } }

/* Receipt-first prototype: fixed geography, responsive reading and review. */
select { font: inherit; }
button:disabled { cursor: default; opacity: .5; }
button:focus-visible, select:focus-visible, input:focus-visible, summary:focus-visible { outline: 2px solid #4f776f; outline-offset: 3px; }
.app { min-height: 0; }
.app-content { overflow-x: hidden; }
.topbar { grid-template-columns: minmax(70px,92px) 1fr 30px; gap: 2px; }
.month-switcher { gap: 0; min-width: 0; }
.month-switcher .month-label { white-space: nowrap; font-size: 12px; padding-inline: 3px; }
.month-switcher button { min-height: 40px; padding-inline: 6px; }
.hero { padding-top: 4px; padding-bottom: 20px; }
.hero h1 { font-size: clamp(28px,8vw,36px); overflow-wrap: anywhere; }
.import-entry { width: 100%; display: flex; align-items: center; gap: 12px; border: 0; padding: 17px; background: #e8ede5; border-radius: 22px; text-align: left; cursor: pointer; }
.import-entry-icon { display: grid; place-items: center; width: 38px; height: 42px; border-radius: 12px; background: #4f776f; color: #fff; font-size: 24px; flex: 0 0 auto; }
.import-entry small,.import-entry strong { display: block; }
.import-entry small { color: #667467; font-size: 10px; margin-bottom: 4px; }
.import-entry strong { font-size: 13px; }
.import-entry b { margin-left: auto; color: #4f776f; }
.local-note { font-size: 10px; color: #76736a; margin: 9px 4px 20px; }
.dot-map { width: min(100%,292px); height: auto; aspect-ratio: 292 / 316; margin-top: 16px; }
.dot-map svg { width: 100%; height: 100%; display: block; cursor: pointer; }
.view-mode { font-size: 11px; min-height: 32px; }
.map-progress { font-size: 10px; gap: 8px; }
.map-explanation { font-size: 10px; color: #706c62; line-height: 1.6; margin: 8px 0; }
.map-legend { display: flex; gap: 7px 12px; flex-wrap: wrap; margin: 10px 0 14px; }
.map-legend span { display: flex; align-items: center; gap: 4px; font-size: 10px; color: #656358; }
.map-legend i { width: 6px; height: 6px; border-radius: 50%; }
.map-region-picker { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 10px; margin-bottom: 9px; color: #777267; }
.map-region-picker select { min-width: 0; max-width: 78%; border: 0; background: transparent; color: var(--ink); font-size: 11px; min-height: 36px; }
.selection { border: 0; width: 100%; cursor: pointer; gap: 8px; }
.selection > div { min-width: 0; }
.map-unlocated { font-size: 10px; line-height: 1.6; color: #777267; margin: 12px 2px 0; }
.region-list > .empty-copy { grid-column: 1/-1; }
.region-card { min-width: 0; grid-template-columns: 48px minmax(0,1fr); gap: 7px; padding: 10px 7px; }
.region-mini-map { transform: scale(.78); transform-origin: left center; width: 48px; }
.region-card strong { font-size: 11px; }
.region-card small { font-size: 10px; overflow-wrap: anywhere; }
.transaction { grid-template-columns: 34px minmax(0,1fr) auto; gap: 8px; padding-inline: 10px; }
.transaction-icon { width: 34px; height: 34px; }
.transaction strong { overflow-wrap: anywhere; }
.transaction-amount { font-size: 11px; }
.sheet { min-width: 0; max-height: calc(100dvh - 12px); overflow-y: auto; overscroll-behavior: contain; padding-bottom: max(24px,env(safe-area-inset-bottom)); }
.sheet-backdrop { overflow: hidden; }
.sheet-header h2 { font-size: 20px; }
.receipt-review .sheet-header { position: sticky; top: -9px; z-index: 1; background: #f8f5ed; padding-block: 8px; align-items: center; }
.receipt-review .sheet-header h2 { margin: 0; }
.close-button { min-width: 40px; min-height: 40px; }
.sheet input, .sheet select { font-size: 16px; min-width: 0; }
.sheet .amount-input input { font-size: 40px; max-width: 75%; }
.amount-input { margin-block: 18px; }
.memo-field { padding: 12px; margin-bottom: 12px; min-width: 0; }
.memo-field span { font-size: 11px; }
.category-picker { min-width: 0; max-width: 100%; }
.secondary-button { width: 100%; border: 1px solid var(--line); background: #fff9; border-radius: 16px; padding: 14px; cursor: pointer; font-size: 13px; }
.add-choice > p { font-size: 12px; color: #777267; line-height: 1.7; }
.add-choice .secondary-button { margin-top: 10px; }
.form-error { color: #a23e2f; font-size: 12px; line-height: 1.7; }
.form-error:empty { display: none; }
#viewReceipt { margin-bottom: 12px; }
.private-badge { padding: 7px 9px; background: #e5eadf; border-radius: 12px; color: #526650; font-size: 10px; margin-bottom: 8px; }
.receipt-intro { padding: 22px; border-radius: 26px; background: #e7ecdf; }
.receipt-intro > p { font-size: 11px; color: #61715b; margin: 0 0 8px; }
.receipt-intro h2 { font-size: 25px; letter-spacing: -.04em; line-height: 1.45; margin: 0 0 12px; }
.receipt-intro > small { display: block; font-size: 12px; line-height: 1.8; color: #62705d; }
.receipt-actions { display: flex; gap: 8px; margin-top: 20px; }
.receipt-actions .save-button { background: #4f776f; flex: 1; font-size: 13px; }
.receipt-actions .secondary-button { width: 68px; }
.receipt-help { font-size: 11px; line-height: 1.7; color: #747367; }
.receipt-intro .receipt-help { margin-bottom: 0; font-size: 10px; }
.import-feedback { margin: 16px 3px 22px; }
#importStatus { font-size: 12px; line-height: 1.8; color: #6e6d62; overflow-wrap: anywhere; }
#receiptProgress { width: 100%; height: 6px; accent-color: #4f776f; }
.receipt-empty { display: grid; justify-items: center; padding: 30px 10px; text-align: center; background: #fff5; border: 1px dashed #d6d2c7; border-radius: 22px; }
.receipt-empty > span { font-size: 34px; color: #758970; margin-bottom: 12px; }
.receipt-empty > strong { font-size: 14px; }
.receipt-empty p { font-size: 12px; color: #868075; line-height: 1.9; }
.receipt-row { display: flex; align-items: center; gap: 9px; padding: 12px 8px; margin-bottom: 8px; border-radius: 18px; background: #fff9; }
.receipt-select { min-width: 32px; min-height: 44px; display: grid; place-items: center; }
.receipt-select input { width: 18px; height: 18px; accent-color: #4f776f; }
.receipt-open { border: 0; background: none; text-align: left; flex: 1; min-width: 0; cursor: pointer; }
.receipt-open strong,.receipt-open small { display: block; overflow-wrap: anywhere; }
.receipt-open strong { font-size: 13px; margin: 6px 0; }
.receipt-open small { color: #797467; font-size: 11px; }
.receipt-status { font-size: 10px; color: #a56539; background: #f2e8d9; padding: 3px 6px; border-radius: 6px; }
.receipt-status.good { color: #4f776f; background: #e4ece2; }
.receipt-remove { width: 36px; min-height: 44px; background: none; border: 0; color: #82796c; font-size: 20px; cursor: pointer; }
.receipt-save { margin-top: 16px; font-size: 13px; }
.receipt-preview { display: block; width: 100%; max-height: 240px; object-fit: contain; background: #e8e5dd; border-radius: 16px; margin-top: 10px; }
.receipt-preview[hidden] { display: none; }
.review-notice { font-size: 12px; line-height: 1.7; padding: 10px; border-radius: 12px; background: #f0e7d5; color: #795e37; }
.review-fields { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 8px; }
.review-fields input { width: 100%; }
.duplicate-check { display: flex; align-items: start; gap: 8px; font-size: 12px; line-height: 1.7; margin: 12px 0; }
.duplicate-check[hidden] { display: none; }
.raw-details { font-size: 12px; margin: 16px 0; }
.raw-details summary { padding: 10px 0; cursor: pointer; }
.raw-details pre { white-space: pre-wrap; overflow-wrap: anywhere; max-height: 200px; overflow-y: auto; background: #fff8; padding: 12px; border-radius: 10px; }
body.dialog-open { overflow: hidden; }
.dialog-open .app-content { overflow-y: hidden; }
.version { font-size: 10px; line-height: 1.8; }
.toast { max-width: calc(100% - 24px); width: max-content; text-align: center; }
@media(max-width:520px) { .app { min-height: 0; height: 100dvh; } .app-content { padding-inline: 18px; } }
@media(max-height:600px) and (min-width:521px) { .phone-shell { padding: 0; } .app { height: 100dvh; border-radius: 0; } }
@media(prefers-reduced-motion:reduce) { *,*::before,*::after { animation: none !important; transition: none !important; } }
