/* 우리집 — 면 위주의 깔끔한 카드, 숫자는 크게, 사람 색(파랑·장미)으로 누가 했는지. 겹침 없이: 고정 막대만큼 본문 여백을 둔다. */
/* 색: 따뜻한 회색 바탕 + 짙은 세이지 그린 하나만 포인트. 사람·상태 색은 채도를 낮춰 차분하게. */
:root {
  --bg: #f5f5f2; --surface: #fff; --surface-2: #f8f8f5; --text: #1d2024; --text-2: #555b63; --mute: #8f949b;
  --line: #ebebe7; --fill: #f0f0ec; --fill-2: #e5e5e0; --star-off: #dcdcd6; --star: #e3a94a;
  --accent: #2e6b59; --accent-soft: #e9f1ed; --on-accent: #fff;
  --p-g: #4d6cc9; --p-g-soft: #eef1fa; --p-b: #c45a7a; --p-b-soft: #faeef2;
  --good: #3b8560; --good-soft: #ebf4ee; --mid: #b0832f; --mid-soft: #f7f0e1; --bad: #c8534d; --bad-soft: #f9ecea;
  --violet: #6e5fb3; --violet-soft: #f0eef8; --on-status: #fff;
  --r: 16px; --shadow: 0 1px 2px rgba(29, 32, 36, .04), 0 2px 12px rgba(29, 32, 36, .035);
  --top-h: 56px; --tab-h: 62px; --side-w: 232px; --gut: 16px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  color-scheme: light;
  font-family: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo', 'Malgun Gothic', system-ui, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #121315; --surface: #1a1c1f; --surface-2: #212327; --text: #ebebe9; --text-2: #b4b7bc; --mute: #81858c;
    --line: #2b2d31; --fill: #25272b; --fill-2: #2f3136; --star-off: #3c3f45; --star: #e0ac55;
    --accent: #79b8a2; --accent-soft: #1d2d28; --on-accent: #0f211b;
    --p-g: #93a8e8; --p-g-soft: #1e2436; --p-b: #e295ad; --p-b-soft: #34222a;
    --good: #7dbf98; --good-soft: #1b2b22; --mid: #d6b06a; --mid-soft: #30291a; --bad: #e4847e; --bad-soft: #36201f;
    --violet: #ab9fe0; --violet-soft: #26233a; --on-status: #14171a;
    --shadow: 0 0 0 1px rgba(255, 255, 255, .04);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font-size: 15px; line-height: 1.5; overflow-x: hidden; -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
h1, h2, h3, h4 { letter-spacing: -.01em; }
.boot { padding: 40px; text-align: center; color: var(--mute); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
[hidden] { display: none !important; }

/* 아이콘 */
.ic { display: inline-flex; align-items: center; justify-content: center; flex: none; }
.ic svg, .icon-btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ---- 화면 틀 ---------------------------------------------------------------- */
.app { min-height: 100dvh; }
.side { display: none; }
.shell { min-width: 0; }
.top {
  position: sticky; top: 0; z-index: 20; height: var(--top-h);
  display: flex; align-items: center; gap: 8px; padding: 0 8px 0 var(--gut);
  background: color-mix(in srgb, var(--bg) 90%, transparent); backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px);
}
.top-logo { flex: none; border-radius: 7px; }
.top-title { margin: 0; font-size: 18px; font-weight: 800; flex: 0 1 auto; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.save-state { font-size: 12px; color: var(--mute); flex: 0 1 auto; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.save-state.busy { color: var(--text-2); }
.save-state.bad { color: var(--bad); font-weight: 600; }
.top-acts { margin-left: auto; display: flex; align-items: center; gap: 2px; flex: none; }
.top-avatar { margin-left: 4px; display: inline-flex; }
main { padding: 8px var(--gut) calc(var(--tab-h) + var(--safe-b) + 28px); max-width: 1080px; margin: 0 auto; min-width: 0; }

.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  height: calc(var(--tab-h) + var(--safe-b)); padding-bottom: var(--safe-b);
  display: grid; grid-template-columns: repeat(6, minmax(0, 1fr));
  background: var(--surface); border-top: 1px solid var(--line);
}
.nav-item { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; color: var(--mute); text-decoration: none; font-size: 11px; font-weight: 600; min-width: 0; }
.nav-item .ic svg { width: 23px; height: 23px; }
.nav-item.on { color: var(--text); }
.nav-item.on .ic svg { stroke-width: 2.2; }
.nav-dot { display: none; position: absolute; top: 8px; left: calc(50% + 9px); width: 7px; height: 7px; border-radius: 50%; background: var(--bad); }
.nav-dot.show { display: block; }

@media (max-width: 420px) { .save-state:not(.busy):not(.bad) { display: none; } }

@media (min-width: 1024px) {
  :root { --gut: 32px; }
  .app { display: grid; grid-template-columns: var(--side-w) minmax(0, 1fr); }
  .side { display: flex; flex-direction: column; gap: 4px; position: sticky; top: 0; height: 100dvh; padding: 20px 14px; background: var(--surface); border-right: 1px solid var(--line); }
  .brand { display: flex; align-items: center; gap: 10px; padding: 4px 10px 18px; text-decoration: none; font-size: 19px; }
  .brand img { border-radius: 8px; }
  .side-nav { display: flex; flex-direction: column; gap: 2px; }
  .side-nav .nav-item { flex-direction: row; justify-content: flex-start; gap: 12px; padding: 10px 12px; border-radius: 10px; font-size: 15px; color: var(--text-2); }
  .side-nav .nav-item:hover { background: var(--fill); }
  .side-nav .nav-item.on { background: var(--fill); color: var(--text); }
  .side-nav .nav-dot { position: static; margin-left: auto; }
  .side-foot { margin-top: auto; display: flex; flex-direction: column; gap: 8px; }
  .side-link { position: relative; display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; text-decoration: none; color: var(--text-2); font-size: 14px; font-weight: 600; }
  .side-link:hover { background: var(--fill); }
  .side-link .nav-dot { position: static; margin-left: auto; }
  .side-me { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-top: 1px solid var(--line); }
  .side-me div { display: flex; flex-direction: column; line-height: 1.3; }
  .tabbar, .top-logo, .top-title, .top-avatar, .top .guide-btn { display: none; }
  .top { padding-right: var(--gut); background: color-mix(in srgb, var(--bg) 92%, transparent); }
  main { padding-bottom: 56px; }
}

/* ---- 공통 부품 ---------------------------------------------------------------- */
.page-head { display: flex; align-items: center; gap: 8px 10px; flex-wrap: wrap; margin: 4px 0 14px; min-height: 40px; }
.page-head .back { margin-left: -8px; }
.ph-title { flex: 1 1 180px; min-width: 0; }
.ph-title h2 { margin: 0; font-size: 22px; font-weight: 800; line-height: 1.3; overflow-wrap: anywhere; }
.ph-sub { margin: 2px 0 0; color: var(--mute); font-size: 13px; }

.card { display: block; background: var(--surface); border-radius: var(--r); padding: 16px; margin-bottom: 12px; box-shadow: var(--shadow); text-decoration: none; color: inherit; min-width: 0; }
a.card:hover, a.row-item:hover { background: color-mix(in srgb, var(--surface) 96%, var(--text)); }
.card-title { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 0 0 12px; font-size: 16px; font-weight: 700; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.card-head .card-title { margin: 0; }
.card-head select { width: auto; max-width: 100%; font-size: 14px; padding: 7px 10px; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 22px 0 10px; }
.section-head h3 { margin: 0; font-size: 17px; }

.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; min-width: 0; }
.field:last-child { margin-bottom: 0; }
.lab { font-size: 13px; font-weight: 600; color: var(--text-2); display: inline-flex; align-items: center; gap: 4px; }
.lab:empty { display: none; }
input, textarea, select {
  font: inherit; font-size: 16px; width: 100%; min-width: 0; padding: 11px 12px; border-radius: 10px;
  border: 1px solid transparent; background: var(--fill); color: var(--text); outline: none; transition: background .15s, border-color .15s, box-shadow .15s;
}
input::placeholder, textarea::placeholder { color: var(--mute); }
input:focus, textarea:focus, select:focus { background: var(--surface); border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
textarea { resize: vertical; min-height: 46px; line-height: 1.55; }
input[type=checkbox] { width: 20px; height: 20px; padding: 0; accent-color: var(--accent); flex: none; margin: 0; }
input[type=date], input[type=time] { min-height: 46px; }
.hint { font-size: 12px; color: var(--mute); }
.hint:empty { display: none; }
.hint.bad { color: var(--bad); }
.suffix-wrap { position: relative; display: flex; min-width: 0; }
.suffix-wrap input { padding-right: 38px; }
.suffix { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); color: var(--mute); font-size: 14px; pointer-events: none; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 12px; }
.grid3 { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr); gap: 0 10px; }
@media (max-width: 359px) { .grid2 { grid-template-columns: minmax(0, 1fr); } }
.grid2 > .field:last-child, .grid3 > .field:last-child { margin-bottom: 12px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 40px; padding: 9px 14px;
  border: 0; border-radius: 10px; background: var(--fill); color: var(--text); font: inherit; font-size: 14px; font-weight: 600;
  white-space: nowrap; text-decoration: none; cursor: pointer; transition: filter .15s, background .15s;
}
.btn:hover { filter: brightness(.97); }
.btn.small { min-height: 34px; padding: 6px 11px; font-size: 13px; }
.btn.primary { background: var(--accent); color: var(--on-accent); }
.btn.danger { background: var(--bad-soft); color: var(--bad); }
.btn.block { width: 100%; min-height: 48px; font-size: 16px; }
.btn:disabled { opacity: .5; cursor: default; }
.btn .ic svg { width: 17px; height: 17px; }
.icon-btn { position: relative; flex: none; width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 10px; background: transparent; color: var(--text-2); cursor: pointer; font: inherit; text-decoration: none; }
.icon-btn:hover { background: var(--fill); }
.icon-btn svg { width: 22px; height: 22px; }
.icon-btn.small { width: 34px; height: 34px; font-size: 15px; }
.icon-btn.small svg { width: 18px; height: 18px; }
.icon-btn.accent { color: var(--accent); }
.icon-btn.on { color: var(--star); }
.icon-btn:disabled { opacity: .35; }
.icon-btn.dot::after, .new-dot { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--bad); display: inline-block; flex: none; }
.icon-btn.dot::after { position: absolute; top: 8px; right: 8px; }
.link-btn { background: none; border: 0; padding: 4px 0; color: var(--accent); font: inherit; font-weight: 600; cursor: pointer; text-decoration: none; white-space: nowrap; }
.link-btn.small { font-size: 13px; }

.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 6px 13px; border: 0; border-radius: 999px;
  background: var(--fill); color: var(--text-2); font: inherit; font-size: 14px; font-weight: 600; white-space: nowrap; cursor: pointer;
}
.chip.on { background: var(--text); color: var(--surface); }
.chips.small .chip { min-height: 32px; padding: 4px 11px; font-size: 13px; }
.chips.filter { margin-bottom: 12px; }
.chips.scroll, .scroll-x { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-left: calc(-1 * var(--gut)); margin-right: calc(-1 * var(--gut)); padding: 0 var(--gut) 2px; }
.scroll-x { margin-bottom: 12px; }
.scroll-x .chips { flex-wrap: nowrap; }
.chips.scroll::-webkit-scrollbar, .scroll-x::-webkit-scrollbar, .tabs::-webkit-scrollbar { display: none; }
.count { display: inline-block; min-width: 20px; padding: 0 6px; border-radius: 999px; background: var(--fill-2); color: var(--text-2); font-size: 12px; font-weight: 700; text-align: center; line-height: 20px; }
.chip.on .count { background: color-mix(in srgb, var(--surface) 22%, transparent); color: inherit; }

.badge { display: inline-flex; align-items: center; padding: 2px 8px; border-radius: 6px; background: var(--fill); color: var(--text-2); font-size: 12px; font-weight: 700; white-space: nowrap; line-height: 1.5; }
.badge.mute { background: var(--fill); color: var(--mute); }
.badge.st-visit, .badge.ls-asked { background: var(--p-g-soft); color: var(--p-g); }
.badge.st-seen, .badge.ls-ok { background: var(--good-soft); color: var(--good); }
.badge.st-hold, .badge.ls-look { background: var(--mid-soft); color: var(--mid); }
.badge.st-drop, .badge.ls-no { background: var(--fill); color: var(--mute); text-decoration: line-through; }
.badge.st-deal, .badge.ls-pick, .badge.new { background: var(--accent); color: var(--on-accent); }
.badge.pu-live { background: var(--accent-soft); color: var(--accent); }
.badge.pu-invest { background: var(--violet-soft); color: var(--violet); }
.badge.pu-jeonse { background: var(--p-g-soft); color: var(--p-g); }
.badge.pu-monthly { background: var(--mid-soft); color: var(--mid); }
.safe-list { margin: 0; padding-left: 20px; line-height: 1.7; }
.safe-list li { margin-bottom: 6px; }
.badge.official { background: var(--p-g-soft); color: var(--p-g); }
.badge.impact { background: var(--bad-soft); color: var(--bad); }

.tabs { display: flex; gap: 2px; margin: 0 0 14px; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.tab { display: inline-flex; align-items: center; gap: 6px; padding: 10px 12px; margin-bottom: -1px; border: 0; border-bottom: 2px solid transparent; background: none; color: var(--mute); font: inherit; font-weight: 700; white-space: nowrap; text-decoration: none; cursor: pointer; }
.tab.on { color: var(--text); border-bottom-color: var(--text); }

.row { display: flex; align-items: center; gap: 8px; }
.row.end { justify-content: flex-end; margin-top: 12px; }
.row.wrap { flex-wrap: wrap; }
.row.center { justify-content: center; margin: 8px 0; }
.mute { color: var(--mute); }
.small { font-size: 13px; }
.center { text-align: center; }
.good { color: var(--good); }
.bad { color: var(--bad); }
.clamp { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.clamp2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.empty { padding: 32px 20px; margin-bottom: 12px; border-radius: var(--r); background: var(--surface); text-align: center; color: var(--text-2); }
.empty p { margin: 0 0 14px; line-height: 1.6; }
.empty p:last-child { margin: 0; }
.tip { margin: 12px 0; padding: 12px 14px; border-radius: 12px; background: var(--accent-soft); color: var(--text); font-size: 14px; line-height: 1.6; }
.tip::before { content: '💡 '; }
.example { margin: 8px 0; padding: 10px 12px; border-radius: 10px; background: var(--surface-2); font-size: 14px; }
.example b { display: block; margin-bottom: 4px; font-size: 12px; color: var(--accent); }
.example pre, .example p { margin: 0; font-family: inherit; white-space: pre-wrap; overflow-wrap: anywhere; }

/* 용어 i */
.term { display: inline-flex; align-items: center; gap: 4px; }
.ti {
  position: relative; flex: none; width: 17px; height: 17px; padding: 0; border: 1.5px solid currentColor; border-radius: 50%;
  background: none; color: var(--mute); font: italic 700 11px/1 Georgia, serif; display: inline-flex; align-items: center; justify-content: center; cursor: pointer;
}
.ti::before { content: ''; position: absolute; inset: -8px; }
.ti:hover { color: var(--accent); }
.term-body { margin: 0 0 10px; font-size: 16px; line-height: 1.65; }

/* 사람 */
.pdot, .fresh { display: inline-block; flex: none; width: 8px; height: 8px; border-radius: 50%; }
.p-g .pdot, .pdot.p-g, .fresh.p-g { background: var(--p-g); }
.p-b .pdot, .pdot.p-b, .fresh.p-b { background: var(--p-b); }
.who { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 700; }
.avatar { flex: none; width: 34px; height: 34px; border: 0; border-radius: 50%; display: inline-grid; place-items: center; color: #fff; font: inherit; font-size: 12px; font-weight: 800; cursor: pointer; }
.avatar.p-g { background: var(--p-g); }
.avatar.p-b { background: var(--p-b); }
.sc { font-weight: 700; }
.sc.p-g { color: var(--p-g); }
.sc.p-b { color: var(--p-b); }

.stars { display: inline-flex; color: var(--star-off); }
.stars > * { color: inherit; }
.stars .on { color: var(--star); }
.stars button { min-width: 34px; min-height: 34px; padding: 0; border: 0; background: none; font-size: 24px; line-height: 1; cursor: pointer; }
.stars span { font-size: 18px; line-height: 1; }
.stars.sm button, .stars.sm span { min-width: 22px; min-height: 26px; font-size: 17px; }
.stars.lg button { min-width: 46px; min-height: 46px; font-size: 34px; }

.opinions { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: 10px; margin-bottom: 12px; }
.op { padding: 12px; border-radius: 12px; background: var(--surface-2); }
.op.p-g { box-shadow: inset 3px 0 var(--p-g); }
.op.p-b { box-shadow: inset 3px 0 var(--p-b); }
.op-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-bottom: 6px; }
.op .field { margin: 0; }
.op-take { margin: 0; overflow-wrap: anywhere; }

/* 목록 */
.list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 12px; }
.row-item { display: flex; align-items: center; gap: 12px; min-width: 0; padding: 14px 16px; border-radius: 14px; background: var(--surface); box-shadow: var(--shadow); color: inherit; text-decoration: none; }
.list.flat { gap: 6px; margin-bottom: 0; }
.list.flat .row-item { padding: 11px 13px; background: var(--surface-2); box-shadow: none; }
.ri-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.ri-title { display: flex; align-items: center; gap: 6px 8px; flex-wrap: wrap; min-width: 0; }
.ri-title b { font-size: 16px; overflow-wrap: anywhere; }
.ri-sub { color: var(--text-2); font-size: 14px; overflow-wrap: anywhere; }
.ri-meta { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: 13px; color: var(--mute); }
.rate { color: var(--text); font-size: 15px; }
.date-box { flex: none; width: 48px; padding: 6px 0; border-radius: 12px; background: var(--accent-soft); color: var(--accent); display: flex; flex-direction: column; align-items: center; line-height: 1.15; }
.date-box b { font-size: 19px; }
.date-box span { font-size: 11px; font-weight: 700; }
.date-box.done { background: var(--fill); color: var(--text-2); }

.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 290px), 1fr)); gap: 12px; margin-bottom: 12px; }
.cards .card { margin: 0; }
.plan-card .row { flex-wrap: wrap; }
.plan-card h3 { flex: 1 1 140px; min-width: 0; margin: 0; font-size: 17px; display: flex; align-items: center; gap: 6px; overflow-wrap: anywhere; }
.kv-line { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-top: 8px; color: var(--text-2); font-size: 14px; }
.mini-list { display: flex; flex-direction: column; gap: 4px; margin-top: 10px; }
.mini { display: flex; justify-content: space-between; gap: 8px; padding: 7px 10px; border-radius: 8px; background: var(--surface-2); font-size: 14px; min-width: 0; }
.mini b { white-space: nowrap; }

/* 숫자 */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 140px), 1fr)); gap: 8px; }
.stat { display: flex; flex-direction: column; gap: 2px; min-width: 0; padding: 12px; border-radius: 12px; background: var(--surface-2); }
.stat .lab { font-size: 12px; }
.stat b { font-size: 18px; font-weight: 800; font-variant-numeric: tabular-nums; word-break: keep-all; overflow-wrap: break-word; letter-spacing: -.01em; }
.stat.big b { font-size: 22px; }
.stat.good b { color: var(--good); }
.stat.bad b { color: var(--bad); }
.result .stats + p { margin: 10px 0 0; }
.sum-line { display: flex; justify-content: space-between; align-items: baseline; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.sum-line b { font-size: 19px; font-variant-numeric: tabular-nums; }
.toggles { display: flex; flex-direction: column; gap: 2px; margin-bottom: 8px; }
.toggle { display: flex; align-items: center; gap: 10px; padding: 7px 0; cursor: pointer; }
.checks { display: flex; flex-direction: column; }
.check { display: flex; align-items: center; gap: 10px; padding: 9px 0; cursor: pointer; border-bottom: 1px solid var(--line); }
.check:last-child { border: 0; }

/* 빠른 추가 */
.quick-row { display: flex; align-items: flex-end; gap: 8px; }
.quick-row textarea, .quick-row input { flex: 1; resize: none; }
.quick-row .btn { min-height: 46px; }
.quick-preview { display: flex; flex-direction: column; gap: 4px; margin-top: 8px; }
.quick-preview:empty { display: none; }
.qp { display: flex; flex-wrap: wrap; gap: 4px 6px; font-size: 13px; color: var(--text-2); }
.qp b { color: var(--text); margin-right: 2px; }
.qp span { padding: 0 6px; border-radius: 6px; background: var(--fill); }
.quick-card > p { margin: 8px 0 0; }

/* 비교 표 */
.table-wrap { overflow-x: auto; margin-bottom: 8px; border-radius: var(--r); background: var(--surface); box-shadow: var(--shadow); }
table { border-collapse: separate; border-spacing: 0; min-width: 100%; font-size: 14px; }
th, td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: left; white-space: nowrap; vertical-align: middle; }
tr:last-child th, tr:last-child td { border-bottom: 0; }
thead th { font-weight: 800; }
thead th a { text-decoration: none; }
.compare tbody th { position: sticky; left: 0; z-index: 1; background: var(--surface); color: var(--text-2); font-weight: 600; box-shadow: 1px 0 var(--line); }
.compare thead th:first-child { position: sticky; left: 0; z-index: 2; background: var(--surface); }
td.best { background: var(--good-soft); color: var(--good); font-weight: 800; }
.swipe-hint { margin: -4px 0 8px; }
@media (min-width: 1024px) { .swipe-hint { display: none; } }
.sched td, .sched th { font-variant-numeric: tabular-nums; }

/* 목록 편집 */
.list-edit { display: flex; flex-direction: column; gap: 6px; }
.le-row { display: flex; align-items: center; gap: 6px; min-width: 0; }
.le-row input:not([type=checkbox]) { flex: 1; padding: 9px 11px; }
.le-text.done { text-decoration: line-through; color: var(--mute); }
.le-add { margin-top: 4px; }

/* 체크리스트 */
.checklist { display: flex; flex-direction: column; }
.ck { padding: 12px 0; border-bottom: 1px solid var(--line); }
.ck:last-of-type { border-bottom: 0; }
.ck-head { display: flex; align-items: center; gap: 8px 10px; flex-wrap: wrap; }
.ck-text { flex: 1 1 170px; min-width: 0; display: flex; flex-direction: column; }
.ck .field { margin: 8px 0 0; }
.ck .field input { padding: 8px 11px; }
.seg { display: inline-flex; gap: 2px; padding: 3px; border-radius: 10px; background: var(--fill); flex: none; }
.seg button { min-height: 32px; padding: 5px 10px; border: 0; border-radius: 8px; background: none; color: var(--text-2); font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; }
.seg button.good.on { background: var(--good); color: var(--on-status); }
.seg button.mid.on { background: var(--mid); color: var(--on-status); }
.seg button.bad.on { background: var(--bad); color: var(--on-status); }

/* 댓글·사진 */
.cmt { margin-bottom: 8px; padding: 10px 12px; border-radius: 12px; background: var(--surface-2); }
.cmt.p-g { box-shadow: inset 3px 0 var(--p-g); }
.cmt.p-b { box-shadow: inset 3px 0 var(--p-b); }
.cmt-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.cmt-head .link-btn { margin-left: auto; color: var(--mute); }
.cmt-body { margin: 4px 0 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.cmt-input { display: flex; align-items: flex-end; gap: 6px; margin-top: 10px; }
.cmt-input textarea { flex: 1; resize: none; }
.cmt-input .icon-btn { width: 46px; height: 46px; background: var(--accent-soft); }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 6px; }
.ph { padding: 0; border: 0; border-radius: 10px; overflow: hidden; background: var(--fill); cursor: pointer; aspect-ratio: 1; }
.photo-grid img { display: block; width: 100%; height: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 10px; }
.lightbox { position: fixed; inset: 0; z-index: 100; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 12px; background: rgba(0, 0, 0, .92); }
.lightbox img { max-width: 100%; max-height: calc(100dvh - 110px); object-fit: contain; border-radius: 8px; }
.lb-bar { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 8px; color: #fff; }
.lb-bar .mute { color: #ccc; }

/* 시트 */
.sheet-bg { position: fixed; inset: 0; z-index: 50; display: flex; align-items: flex-end; justify-content: center; background: rgba(12, 14, 18, .45); animation: fade .16s ease-out; }
.sheet-bg.out { opacity: 0; transition: opacity .16s; }
.sheet { display: flex; flex-direction: column; width: 100%; max-width: 560px; max-height: 90dvh; padding-bottom: var(--safe-b); border-radius: 22px 22px 0 0; background: var(--surface); animation: up .22s cubic-bezier(.2, .9, .3, 1); }
.sheet.wide { max-width: 760px; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 10px 4px 20px; }
.sheet-head h3 { margin: 0; font-size: 18px; }
.sheet-body { padding: 6px 20px 22px; overflow-y: auto; overscroll-behavior: contain; }
.sheet-body > textarea { margin-bottom: 4px; }
@media (min-width: 640px) { .sheet-bg { align-items: center; padding: 24px; } .sheet { border-radius: 22px; } }
@keyframes fade { from { opacity: 0; } }
@keyframes up { from { transform: translateY(24px); opacity: .6; } }
.menu { display: flex; flex-direction: column; gap: 2px; }
.menu-item { display: flex; align-items: center; gap: 12px; width: 100%; padding: 13px 12px; border: 0; border-radius: 12px; background: none; color: var(--text); font: inherit; font-size: 15px; font-weight: 600; text-align: left; text-decoration: none; cursor: pointer; }
.menu-item:hover { background: var(--fill); }
.menu-item.danger { color: var(--bad); }
.menu-item .new-dot { margin-left: auto; }
.menu-item.big > div { display: flex; flex-direction: column; }
.menu-item.big .ic { width: 42px; height: 42px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); }
.pick-group h4 { margin: 14px 0 2px; font-size: 13px; color: var(--mute); }
.confirm-msg { margin: 4px 0 8px; line-height: 1.65; }
.me-card { display: flex; align-items: center; gap: 12px; padding: 4px 4px 14px; }
.me-card .avatar { width: 46px; height: 46px; font-size: 15px; cursor: default; }
.me-card p { margin: 2px 0 0; }

.toast {
  position: fixed; left: 50%; bottom: calc(var(--tab-h) + var(--safe-b) + 12px); z-index: 70; transform: translateX(-50%);
  display: flex; align-items: center; gap: 14px; max-width: calc(100% - 32px); padding: 11px 16px; border-radius: 12px;
  background: #24272b; color: #f2f2ef; font-size: 14px; box-shadow: 0 10px 30px rgba(0, 0, 0, .2); animation: up .2s;
}
.toast button { flex: none; border: 0; background: none; color: #a9d6c4; font: inherit; font-weight: 800; cursor: pointer; padding: 0; }
.update-bar { position: fixed; top: 10px; left: 50%; z-index: 80; transform: translateX(-50%); display: flex; align-items: center; gap: 12px; max-width: calc(100% - 24px); padding: 8px 8px 8px 16px; border-radius: 12px; background: var(--surface); box-shadow: 0 8px 28px rgba(0, 0, 0, .16); font-size: 14px; font-weight: 600; }
@media (min-width: 1024px) { .toast { bottom: 24px; left: calc(50% + var(--side-w) / 2); } }

/* ---- 화면별 ---------------------------------------------------------------- */
.hello { margin: 4px 0 14px; }
.hello h2 { margin: 0 0 2px; font-size: 22px; font-weight: 800; }
.hello p { margin: 0; }
.start .card-title .count { background: var(--accent-soft); color: var(--accent); }
.steps { list-style: none; margin: 0 0 6px; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.steps li { display: flex; align-items: center; gap: 12px; }
.steps .num { flex: none; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: var(--fill); font-size: 13px; font-weight: 800; color: var(--text-2); }
.steps li.done .num { background: var(--accent); color: var(--on-accent); }
.steps li > a, .steps li > div { flex: 1; min-width: 0; display: flex; flex-direction: column; padding: 7px 0; text-decoration: none; color: inherit; cursor: pointer; }
.steps li.done b { color: var(--mute); text-decoration: line-through; }
.flow { margin: 0; padding-left: 20px; }
.flow li { margin-bottom: 8px; line-height: 1.6; }
.activity { list-style: none; margin: 0; padding: 0; }
.activity li { display: flex; align-items: baseline; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.activity li:last-child { border: 0; }
.activity .pdot { transform: translateY(-1px); }
.act-text { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.act-text a { font-weight: 700; text-decoration: none; }
.activity .mute { flex: none; }

.calc-card, .go-card { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.calc-card > div, .go-card > div { flex: 1 1 160px; min-width: 0; }
.calc-card p, .go-card p { margin: 2px 0 0; }
.ic.big { width: 44px; height: 44px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); }
.ic.big svg { width: 24px; height: 24px; }
.calc-peek { font-weight: 800; color: var(--accent); font-variant-numeric: tabular-nums; }
.go-card { background: var(--accent); color: var(--on-accent); }
.go-card .mute { color: inherit; opacity: .85; }
.go-card .ic.big { background: color-mix(in srgb, var(--on-accent) 18%, transparent); color: inherit; }
.go-arrow { font-size: 28px; line-height: 1; margin-left: auto; }
a.go-card:hover { background: var(--accent); filter: brightness(1.05); }

.search-wrap { position: relative; margin-bottom: 10px; }
.search-wrap .ic { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--mute); pointer-events: none; }
.search-wrap .ic + input { padding-left: 40px; }

/* 정책 */
.pol-list .day { margin: 16px 0 6px; font-size: 13px; font-weight: 800; color: var(--mute); }
.pol-list .day:first-child { margin-top: 4px; }
.pol { display: flex; gap: 10px; margin-bottom: 8px; padding: 14px 16px; border-radius: 14px; background: var(--surface); box-shadow: var(--shadow); min-width: 0; }
.pol.impact { box-shadow: inset 3px 0 var(--bad), var(--shadow); }
.pol.sel { outline: 2px solid var(--accent); outline-offset: -2px; }
.pol-pick { display: flex; padding-top: 2px; cursor: pointer; }
.pol-main { flex: 1; min-width: 0; }
.pol-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 8px; font-size: 12px; color: var(--text-2); font-weight: 600; }
.pol-meta .mute { font-weight: 500; }
.pol-title { display: block; margin: 6px 0 8px; font-size: 16px; font-weight: 700; line-height: 1.45; color: var(--text); text-decoration: none; overflow-wrap: anywhere; cursor: pointer; }
a.pol-title:hover { text-decoration: underline; }
.pol-foot { display: flex; align-items: center; justify-content: space-between; gap: 6px; flex-wrap: wrap; }
.pol-tags { display: flex; flex-wrap: wrap; gap: 4px; }
.tag { padding: 3px 9px; border: 0; border-radius: 6px; background: var(--fill); color: var(--text-2); font: inherit; font-size: 12px; font-weight: 600; cursor: pointer; }
.pol-acts { display: flex; gap: 0; margin-left: auto; }
.pick-bar { position: sticky; top: calc(var(--top-h) + 4px); z-index: 10; display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; padding: 10px 12px; border-radius: 12px; background: var(--surface); box-shadow: 0 6px 20px rgba(0, 0, 0, .1); }
.pick-bar b { margin-right: auto; }

/* 새 소식·용어 */
.news-head { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 10px; margin-bottom: 6px; }
.news-head h3 { flex: 1 1 160px; margin: 0; font-size: 18px; }
.news-item { padding: 14px 0 10px; border-top: 1px solid var(--line); }
.news-item h4 { margin: 0 0 4px; font-size: 16px; }
.news-item > p { margin: 0 0 6px; color: var(--text-2); line-height: 1.6; }
dl.terms { margin: 0; }
dl.terms dt { margin-top: 14px; font-size: 16px; font-weight: 800; scroll-margin-top: 70px; }
dl.terms dt:first-child { margin-top: 0; }
dl.terms dd { margin: 4px 0 0; color: var(--text-2); line-height: 1.6; }
dl.terms dd p { margin: 0 0 6px; }
.example-line { font-size: 14px; }

/* 로그인 */
.login { min-height: 100dvh; display: grid; place-items: center; padding: 24px 16px; }
.login-card { display: flex; flex-direction: column; gap: 12px; width: 100%; max-width: 360px; padding: 32px 24px; border-radius: 24px; background: var(--surface); box-shadow: var(--shadow); text-align: center; }
.login-card h1 { margin: 4px 0 0; font-size: 26px; font-weight: 800; }
.login-card > p { margin: 0 0 8px; }
.login-logo { margin: 0 auto; border-radius: 16px; }
.login-card .toggle { justify-content: flex-start; font-size: 14px; color: var(--text-2); }
.login-card .bad:empty { display: none; }

/* ---- 지도 ---------------------------------------------------------------- */
/* Leaflet은 z-index 400~1000을 쓴다 → 상자 안에 가둬서 위 막대·시트·토스트 위로 올라오지 않게 */
.map-box { position: relative; isolation: isolate; z-index: 0; overflow: hidden; border-radius: 14px; background: var(--fill); margin-bottom: 10px; }
.map-loading { position: absolute; inset: 0; display: grid; place-items: center; padding: 16px; text-align: center; color: var(--mute); font-size: 14px; }
.map-box .leaflet-container, .map-box.leaflet-container { font: inherit; background: var(--fill); }
/* OSM 기본 지도는 색이 진해서 앱 색감에 맞게 차분하게, 어두운 화면에서는 뒤집어서 어둡게 */
.map-box .leaflet-tile-pane { filter: saturate(.55) contrast(.92) brightness(1.03); }
@media (prefers-color-scheme: dark) {
  .map-box .leaflet-tile-pane { filter: invert(1) hue-rotate(180deg) saturate(.35) brightness(.82) contrast(.9); }
}
.map-box .leaflet-bar { border: 0; box-shadow: 0 2px 8px rgba(0, 0, 0, .14); border-radius: 10px; overflow: hidden; }
.map-box .leaflet-bar a { width: 34px; height: 34px; line-height: 34px; background: var(--surface); color: var(--text); border-color: var(--line); }
.map-box .leaflet-control-attribution { background: color-mix(in srgb, var(--surface) 82%, transparent); color: var(--mute); font-size: 10px; }
.map-box .leaflet-control-attribution a { color: var(--text-2); }
.map-box .leaflet-popup-content-wrapper, .map-box .leaflet-popup-tip { background: var(--surface); color: var(--text); box-shadow: 0 6px 20px rgba(0, 0, 0, .18); }
.map-box .leaflet-popup-content-wrapper { border-radius: 12px; }
.map-box .leaflet-popup-content { margin: 10px 14px; font-size: 14px; line-height: 1.45; }
.map-box a.leaflet-popup-close-button { color: var(--mute); }
.pop b { display: block; font-size: 15px; }
.pop p { margin: 2px 0 6px; color: var(--text-2); font-size: 13px; }
.pop .row { gap: 12px; }
.pop-photos { display: flex; gap: 4px; margin-bottom: 6px; }
.pop-photos img { width: 64px; height: 64px; object-fit: cover; border-radius: 8px; }
.mk-wrap { background: none !important; border: 0 !important; }
.mk {
  position: absolute; left: 0; top: 0; transform: translate(-50%, calc(-100% - 8px));
  display: flex; align-items: center; gap: 5px; padding: 4px 9px; border-radius: 10px; white-space: nowrap;
  background: var(--surface); color: var(--text); font-size: 12px; box-shadow: 0 2px 8px rgba(0, 0, 0, .2); cursor: pointer;
}
.mk::after { content: ''; position: absolute; left: 50%; bottom: -5px; width: 10px; height: 10px; background: inherit; transform: translateX(-50%) rotate(45deg); box-shadow: 2px 2px 3px rgba(0, 0, 0, .08); }
.mk b { font-weight: 800; }
.mk span { color: var(--text-2); font-weight: 600; }
.mk i, .map-legend i { width: 8px; height: 8px; border-radius: 50%; background: var(--mute); flex: none; display: inline-block; }
.st-visit > i, .map-legend i.st-visit { background: var(--p-g); }
.st-seen > i, .map-legend i.st-seen { background: var(--good); }
.st-hold > i, .map-legend i.st-hold { background: var(--mid); }
.st-deal > i, .map-legend i.st-deal { background: var(--accent); }
.mk.faded { opacity: .5; }
.mk.faded:hover { opacity: 1; }
.pin-dot { position: absolute; left: 0; top: 0; width: 18px; height: 18px; transform: translate(-50%, -50%); border: 3px solid #fff; border-radius: 50%; box-shadow: 0 1px 6px rgba(0, 0, 0, .35); cursor: pointer; }
.pin-dot.p-g { background: var(--p-g); }
.pin-dot.p-b { background: var(--p-b); }
.pin-label { position: absolute; left: 14px; top: -4px; padding: 1px 6px; border-radius: 6px; background: var(--surface); color: var(--text); font-size: 11px; font-weight: 700; white-space: nowrap; box-shadow: 0 1px 4px rgba(0, 0, 0, .18); }
.me-dot { position: absolute; left: 0; top: 0; width: 16px; height: 16px; transform: translate(-50%, -50%); border: 3px solid #fff; border-radius: 50%; background: #2f80ed; box-shadow: 0 0 0 6px rgba(47, 128, 237, .22); }
.map-legend { display: flex; flex-wrap: wrap; gap: 4px 12px; margin: 0 0 12px; font-size: 12px; color: var(--text-2); }
.map-legend span { display: inline-flex; align-items: center; gap: 5px; }
.map-acts { margin-top: 2px; }
.pins .pdot { width: 10px; height: 10px; }
.fm-map { margin-bottom: 8px; }
.fm-hint { margin: 0; }

/* ---- 앱으로 설치 ---------------------------------------------------------------- */
.install-card { display: flex; align-items: center; justify-content: space-between; gap: 10px 14px; flex-wrap: wrap; background: var(--accent-soft); box-shadow: none; }
.install-card > div:first-child { flex: 1 1 200px; min-width: 0; }
.install-card p { margin: 2px 0 0; }
.install-link { align-self: center; margin-top: 4px; }
.install-warn { margin: 0 0 12px; padding: 10px 12px; border-radius: 10px; background: var(--mid-soft); line-height: 1.6; }
.sheet .steps li > span:last-child { flex: 1; min-width: 0; padding: 6px 0; line-height: 1.5; }

/* ---- Claude에게 묻기 ---------------------------------------------------------------- */
.ask-link { display: inline-flex; align-items: center; gap: 6px; margin: 0 0 12px; padding: 6px 0; border: 0; background: none; color: var(--accent); font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; text-align: left; }
.ask-link .ic svg { width: 17px; height: 17px; }
.ask-examples { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; margin: 10px 0; }
.ask-examples .ex { max-width: 100%; padding: 8px 12px; border: 0; border-radius: 12px; background: var(--fill); color: var(--text-2); font: inherit; font-size: 14px; text-align: left; cursor: pointer; line-height: 1.45; }
.ask-examples .ex:hover { background: var(--fill-2); }
.ask-q p { margin: 10px 0 0; font-size: 16px; line-height: 1.55; white-space: pre-wrap; overflow-wrap: anywhere; }
.ask-q .row { flex-wrap: wrap; }
.ask-run .row { flex-wrap: wrap; gap: 10px; }
.ask-lines { list-style: none; margin: 12px 0 8px; padding: 0; display: flex; flex-direction: column; gap: 4px; font-size: 14px; color: var(--text-2); }
.ask-lines li { overflow-wrap: anywhere; }
.ask-lines li:last-child { color: var(--text); font-weight: 600; }
.spinner { width: 18px; height: 18px; border-radius: 50%; border: 2.5px solid var(--accent-soft); border-top-color: var(--accent); animation: spin .8s linear infinite; flex: none; }
@keyframes spin { to { transform: rotate(360deg); } }
.ask-summary { margin: 0 0 10px; font-size: 16px; font-weight: 700; line-height: 1.55; }
.ask-body { white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.7; color: var(--text); margin-bottom: 8px; }
.ask-cands { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.ask-cand { display: flex; gap: 12px; align-items: flex-start; padding: 12px; border-radius: 12px; background: var(--surface-2); cursor: pointer; }
.ask-cand input { margin-top: 3px; }
.ask-cand.done { opacity: .6; cursor: default; }
.ask-note { margin: 4px 0 2px; font-size: 13px; color: var(--text-2); white-space: pre-wrap; overflow-wrap: anywhere; }
.ask-tips, .ask-src { margin: 0; padding-left: 20px; line-height: 1.7; }
.ask-src a { overflow-wrap: anywhere; }
.ask-row { gap: 4px 16px; }
.ask-row .ask-link { margin-bottom: 4px; }
.table-wrap.flat { box-shadow: none; background: var(--surface-2); margin-bottom: 10px; }
.table-wrap.flat th, .table-wrap.flat td { white-space: normal; overflow-wrap: anywhere; }
.cu th { color: var(--text-2); font-weight: 600; }
.ask-memo { padding: 12px 0; border-top: 1px solid var(--line); }
.ask-memo:first-of-type { border-top: 0; padding-top: 0; }
.ask-memo b { display: block; margin-bottom: 4px; }
.ask-home .card-title .ic { color: var(--accent); }
.ask-home .row-item { margin-bottom: 10px; }

/* ---- 임장 모드 ---------------------------------------------------------------- */
body.in-field .top, body.in-field .tabbar { display: none; }
body.in-field main { max-width: 680px; padding: 0 0 calc(86px + var(--safe-b)); }
body.in-field .toast { bottom: calc(86px + var(--safe-b)); }
.field-mode { min-height: 100dvh; }
.fm-top { position: sticky; top: 0; z-index: 20; display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 4px 8px; padding: 8px 14px 10px 6px; background: var(--surface); border-bottom: 1px solid var(--line); }
.fm-title { display: flex; flex-direction: column; min-width: 0; line-height: 1.3; }
.fm-title b { font-size: 17px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fm-top > .live { grid-column: 1 / -1; display: flex; align-items: center; gap: 10px; padding-left: 8px; }
.fm-count { flex: none; font-size: 13px; font-weight: 800; color: var(--text-2); font-variant-numeric: tabular-nums; min-width: 40px; }
.fm-bar { flex: 1; height: 6px; border-radius: 3px; background: var(--fill); overflow: hidden; }
.fm-bar i { display: block; height: 100%; border-radius: 3px; background: var(--accent); transition: width .25s; }
.fm-tabs { margin: 0; padding: 0 10px; background: var(--surface); }
.fm-body { padding: 12px var(--gut); }
@media (min-width: 1024px) { .fm-body { padding: 16px 0; } }
.fm-list { display: flex; flex-direction: column; gap: 10px; }
.fm-item { padding: 14px; border-radius: 16px; background: var(--surface); box-shadow: var(--shadow); }
.fm-item.is-good { box-shadow: inset 4px 0 var(--good), var(--shadow); }
.fm-item.is-mid { box-shadow: inset 4px 0 var(--mid), var(--shadow); }
.fm-item.is-bad { box-shadow: inset 4px 0 var(--bad), var(--shadow); }
.fm-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.fm-head b { font-size: 17px; }
.fm-head p { margin: 2px 0 0; }
.fm-head .pdot { margin-top: 8px; width: 10px; height: 10px; }
.fm-btns { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.fm-btn { min-height: 54px; border: 0; border-radius: 12px; background: var(--fill); color: var(--text-2); font: inherit; font-size: 16px; font-weight: 800; cursor: pointer; transition: background .12s, transform .08s; }
.fm-btn:active { transform: scale(.97); }
.fm-btn.good.on { background: var(--good); color: var(--on-status); }
.fm-btn.mid.on { background: var(--mid); color: var(--on-status); }
.fm-btn.bad.on { background: var(--bad); color: var(--on-status); }
.fm-item > .link-btn { margin-top: 6px; }
.fm-memo { margin-top: 8px; }
.fm-memo .field { margin: 0; }
.fm-stars { display: flex; flex-direction: column; gap: 2px; margin-bottom: 10px; }
.fm-star-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.fm-notes { margin-top: 8px; }
.fm-notes p { margin: 6px 0 0; color: var(--text-2); overflow-wrap: anywhere; }
.fm-notes.big { margin-top: 12px; }
.fm-bar-bottom { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 8px; padding: 10px 12px calc(10px + var(--safe-b)); background: var(--surface); border-top: 1px solid var(--line); }
@media (min-width: 1024px) { .fm-bar-bottom { left: var(--side-w); } }
.fm-act { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 54px; border: 0; border-radius: 14px; background: var(--fill); color: var(--text); font: inherit; font-size: 15px; font-weight: 800; cursor: pointer; }
.fm-act.primary { background: var(--accent); color: var(--on-accent); }
.fm-act .ic svg { width: 22px; height: 22px; }
