/* METAMEAL — 모바일 우선, 큰 글자·큰 버튼, 대비 4.5:1 이상 */
:root {
  --ink: #1b1f23; --muted: #4d5560; --line: #d5dae0; --bg: #f6f7f5; --card: #fff;
  --brand: #1f6b4a; --brand-ink: #fff; --warn: #8a4b00; --warn-bg: #fff4e0;
  --err: #a1201b; --err-bg: #fdeceb; --ok-bg: #e7f4ec; --focus: #1a4fd6;
  --r: 10px; --tap: 48px;
}
* { box-sizing: border-box; }
html { font-size: 112.5%; } /* 0.47.0 브라우저 글자 크기 설정을 따름(18px 기준) */
body { margin: 0; font-family: "Pretendard", "Apple SD Gothic Neo", "Malgun Gothic", system-ui, sans-serif; color: var(--ink); background: var(--bg); line-height: 1.6; }
a { color: var(--brand); }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, summary:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.skip { position: absolute; left: -999px; top: 0; background: #fff; padding: .5rem 1rem; z-index: 10; }
.skip:focus { left: .5rem; }

.top { background: var(--brand); color: var(--brand-ink); }
.top-inner { max-width: 1100px; margin: 0 auto; padding: .6rem 1rem; display: flex; flex-wrap: wrap; gap: .5rem 1rem; align-items: center; }
.top a { color: var(--brand-ink); text-decoration: none; font-weight: 600; }
.top .logo { font-size: 1.15rem; letter-spacing: .02em; margin-right: auto; }
.top .who { font-size: .85rem; opacity: .95; }
.top form { margin: 0; }
.top .link-btn { background: none; border: 1px solid rgba(255,255,255,.7); color: #fff; min-height: 36px; padding: 0 .8rem; border-radius: 6px; font: inherit; font-size: .85rem; cursor: pointer; }

main { max-width: 1100px; margin: 0 auto; padding: 1rem; }
h1 { font-size: 1.5rem; margin: .4rem 0 1rem; }
h2 { font-size: 1.2rem; margin: 1.4rem 0 .6rem; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 1rem; margin-bottom: 1rem; }
.grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.stat b { display: block; font-size: 1.8rem; }
.muted { color: var(--muted); font-size: .9rem; }
.flash { background: var(--ok-bg); border: 1px solid #a9d5b9; padding: .7rem 1rem; border-radius: var(--r); margin-bottom: 1rem; }
.error { background: var(--err-bg); color: var(--err); border: 1px solid #f0b8b5; padding: .7rem 1rem; border-radius: var(--r); margin-bottom: 1rem; }
.notice { background: var(--warn-bg); color: var(--warn); border: 1px solid #f1cf94; padding: .7rem 1rem; border-radius: var(--r); margin-bottom: 1rem; }
.code-box { font-size: 2rem; letter-spacing: .25em; font-weight: 700; background: #fff; border: 2px dashed var(--brand); padding: .6rem 1rem; display: inline-block; border-radius: var(--r); }

label { display: block; font-weight: 600; margin: .8rem 0 .25rem; }
input[type=text], input[type=email], input[type=password], input[type=date], input[type=tel], input[type=file], input[type=number], input[type=search], input[type=url], input[type=time], input[type=month], select, textarea {
  width: 100%; min-height: var(--tap); font: inherit; padding: .5rem .7rem; border: 1px solid #8a939d; border-radius: 8px; background: #fff; color: var(--ink);
}
textarea { min-height: 120px; }
.check { display: flex; gap: .6rem; align-items: flex-start; font-weight: 500; margin: .5rem 0; }
.check input { width: 24px; height: 24px; margin-top: .2rem; flex: none; }
.btn, button.btn { display: inline-flex; align-items: center; justify-content: center; min-height: var(--tap); padding: 0 1.2rem; border-radius: 8px; border: 1px solid var(--brand); background: var(--brand); color: var(--brand-ink); font: inherit; font-weight: 700; text-decoration: none; cursor: pointer; }
.btn.secondary { background: #fff; color: var(--brand); }
.btn.danger { background: #fff; color: var(--err); border-color: var(--err); }
.btn.armed { background: var(--err); color: #fff; border-color: var(--err); }
.btn.block { width: 100%; }
.actions { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 1rem; }
.inline { display: inline; }

table { width: 100%; border-collapse: collapse; background: #fff; }
th, td { text-align: left; padding: .55rem .6rem; border-bottom: 1px solid var(--line); vertical-align: top; font-size: .92rem; }
th { background: #eef1ee; font-weight: 700; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); }
.tag { display: inline-block; padding: .05rem .5rem; border-radius: 999px; font-size: .8rem; font-weight: 700; border: 1px solid currentColor; }
.tag.ok { color: #1f6b4a; } .tag.no { color: #8a4b00; } .tag.off { color: #5b6470; }
dl.kv { display: grid; grid-template-columns: 8rem 1fr; gap: .3rem 1rem; margin: 0; }
dl.kv dt { color: var(--muted); }
dl.kv dd { margin: 0; }
pre.doc { white-space: pre-wrap; font-family: inherit; background: #fafbfa; border: 1px solid var(--line); padding: .8rem; border-radius: 8px; font-size: .92rem; }
.narrow { max-width: 480px; margin: 2rem auto; }
.foot { max-width: 1100px; margin: 2rem auto; padding: 0 1rem 2rem; color: var(--muted); font-size: .85rem; }

@media (min-width: 900px) {
  html { font-size: 106.25%; }
}
@media print {
  .top, .foot, .actions, form, .no-print { display: none !important; }
  body { background: #fff; }
}

/* 주소(카카오 우편번호) */
fieldset.address-box { border: 1px solid var(--line); border-radius: var(--r); padding: .4rem 1rem 1rem; margin: 1rem 0; }
fieldset.address-box legend { font-weight: 700; padding: 0 .3rem; }
.zip-row { display: flex; gap: .5rem; }
.zip-row input { max-width: 9rem; }
input[readonly] { background: #f1f3f1; }
.postcode-layer { border: 2px solid var(--brand); border-radius: var(--r); margin-top: .6rem; background: #fff; }
.postcode-head { display: flex; justify-content: space-between; align-items: center; padding: .4rem .6rem; border-bottom: 1px solid var(--line); font-weight: 700; }
.postcode-frame { height: 460px; }
[hidden] { display: none !important; }

/* 식단 계획 */
.meal { border-top: 1px solid var(--line); padding: .6rem 0; }
.meal:first-of-type { border-top: 0; }
.meal p { margin: .2rem 0; }
h3 { font-size: 1.05rem; margin: .2rem 0 .4rem; }

/* 0.6.0 끼니 기록(모바일) */
.care-list { display: grid; gap: .5rem; }
.care-item { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; padding: 1rem; border: 1px solid #d9dee5; border-radius: 12px; background: #fff; text-decoration: none; color: inherit; min-height: 56px; }
.choice-row { display: flex; flex-wrap: wrap; gap: .5rem; }
.choice { display: inline-flex; align-items: center; gap: .3rem; padding: .6rem .9rem; border: 1px solid #d9dee5; border-radius: 10px; min-height: 48px; }
.intake-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: .5rem; }
.btn.intake { min-height: 64px; font-size: 1.15rem; padding: 0; }
details { margin: .5rem 0; }

/* 0.9.0 상담 메시지 */
.msg { background: #f4f6f4; border-radius: 10px; padding: .5rem .8rem; margin: .4rem 0; max-width: 85%; }
.msg.mine { background: #e8f1ec; margin-left: auto; }
.pre { white-space: pre-wrap; }

/* 0.10.0 추이 그래프 */
.chart { margin: .6rem 0 1rem; }
.chart svg { width: 100%; height: auto; display: block; }
.chart .bar { fill: var(--brand, #2f7d57); opacity: .85; }
.chart .axis { stroke: #c9d1cb; stroke-width: 1; }
.chart .target { stroke: #c0392b; stroke-width: 1.5; stroke-dasharray: 5 4; }
.chart .tick { font-size: 11px; fill: #6b756e; }
.recall-row { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; padding: .4rem 0; border-bottom: 1px solid #eef1ee; }
.recall-row select { width: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* 0.13.0 라벨·사진 */
.label-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: .6rem; }
.card.label { break-inside: avoid; }
.photo-row { display: flex; flex-wrap: wrap; gap: .5rem; }
.photo-row img { width: 140px; height: 105px; object-fit: cover; border-radius: 8px; border: 1px solid #d9dee5; }

/* 일반인 첫 화면·3분 문진 (0.24.0) */
.hero { padding: 2rem 0 1rem; }
.hero h1 { font-size: clamp(1.7rem, 5vw, 2.4rem); line-height: 1.3; margin: 0 0 .6rem; }
.hero p { font-size: 1.05rem; max-width: 40rem; }
.btn.big { min-height: 56px; font-size: 1.08rem; padding: 0 1.6rem; }
.btn.small { min-height: 36px; padding: 0 .8rem; font-size: .9rem; }
.top .btn.small { background: #fff; color: var(--brand); border-color: #fff; }
.public-nav { display: flex; gap: .9rem; align-items: center; flex-wrap: wrap; margin-left: auto; }
.steps-list { list-style: none; padding: 0; counter-reset: s; display: grid; gap: .6rem; }
.steps-list li { counter-increment: s; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: .8rem 1rem .8rem 3.2rem; position: relative; }
.steps-list li::before { content: counter(s); position: absolute; left: 1rem; top: .8rem; width: 1.6rem; height: 1.6rem; border-radius: 50%; background: var(--brand); color: var(--brand-ink); display: flex; align-items: center; justify-content: center; font-weight: 700; }
.steps-list strong { display: block; }
.step { border: 0; padding: 0; margin: 0 0 1rem; }
.step > legend { font-size: 1.2rem; font-weight: 700; margin-bottom: .2rem; }
.step-progress { font-weight: 700; color: var(--brand); margin: 0 0 .6rem; }
.step-progress .bar { display: block; height: 6px; background: var(--line); border-radius: 3px; margin-top: .3rem; overflow: hidden; }
.step-progress .bar i { display: block; height: 100%; background: var(--brand); }
.choices { border: 0; padding: 0; margin: .8rem 0; }
.choices > legend { font-weight: 600; margin-bottom: .4rem; }
.choice-row { display: flex; gap: .5rem; margin: .6rem 0; }
.choice { display: inline-flex; align-items: center; gap: .4rem; min-height: var(--tap); padding: .3rem .9rem; margin: 0 .4rem .4rem 0; border: 1px solid var(--line); border-radius: 999px; background: #fff; cursor: pointer; }
.choice input { width: 1.1rem; height: 1.1rem; margin: 0; }
.choice:has(input:checked) { border-color: var(--brand); background: var(--ok-bg); font-weight: 600; }
.step-nav { display: flex; gap: .6rem; justify-content: space-between; margin-top: 1rem; }
.big-number { margin: 0 0 .4rem; }
.big-number span { display: block; color: var(--muted); }
.big-number b { font-size: 2.4rem; color: var(--brand); }
.today-goal { margin: .2rem 0 .6rem; }
.notice-card { border-color: var(--brand); background: var(--ok-bg); }
.step > legend:focus { outline: none; }
.field-label { font-weight: 600; margin: .8rem 0 .2rem; }
.entry-chips { display: flex; flex-wrap: wrap; gap: .2rem; margin-bottom: 1rem; }
.entry-chips .choice { text-decoration: none; color: var(--ink); }
.share-box .actions { flex-wrap: wrap; }
.micro-q fieldset { border: 1px dashed var(--line, #ccc); border-radius: 8px; padding: .5rem; margin: .5rem 0; }
.micro-q legend { font-weight: 600; padding: 0 .3rem; }
.micro-q .choice { cursor: pointer; }
progress { width: 100%; height: 1rem; }
.social-btns { display: grid; gap: .5rem; margin: .5rem 0; }
.social-btns .social-kakao { background: #fee500; color: #191919; border-color: #fee500; }
.social-btns .social-naver { background: #03c75a; color: #fff; border-color: #03c75a; }
.consent-req { border: 1px solid var(--line, #ccc); border-radius: 8px; padding: .6rem; margin: .6rem 0; }
.consent-req legend { font-weight: 700; padding: 0 .3rem; }
.consent-item { border-top: 1px solid var(--line, #eee); padding: .4rem 0; }
.consent-sum { display: grid; grid-template-columns: auto 1fr; gap: .1rem .6rem; margin: .3rem 0 .3rem 1.6rem; font-size: .92rem; }
.consent-sum dt { color: var(--muted, #666); }
.consent-sum dd { margin: 0; }
/* 큰 글씨 모드 */
.text-toggle { color: var(--brand-ink); text-decoration: none; border: 1px solid rgba(255,255,255,.7); border-radius: 6px; padding: .1rem .5rem; font-size: .85rem; margin-right: .5rem; white-space: nowrap; }
html.big-text { font-size: 137.5%; }
html.big-text body { line-height: 1.75; }
html.big-text .btn { min-height: 56px; }
html.big-text .muted { color: #333; }
html.big-text input, html.big-text select, html.big-text textarea { font-size: 1.05rem; min-height: 52px; }
/* 첫 화면 큰 단추 3개 */
.big3 { display: grid; gap: .6rem; grid-template-columns: 1fr; margin: .8rem 0 1.2rem; }
@media (min-width: 640px) { .big3 { grid-template-columns: repeat(3, 1fr); } }
.big3 a { display: flex; flex-direction: column; justify-content: center; min-height: 96px; padding: .8rem 1rem; border-radius: 12px; background: var(--brand); color: var(--brand-ink); text-decoration: none; font-weight: 700; font-size: 1.15rem; }
.big3 a small { font-weight: 400; font-size: .85rem; opacity: .95; }
.big3 a.alt { background: #fff; color: var(--brand); border: 2px solid var(--brand); }
.voice-row { align-items: center; }

/* 0.41.0 영양성분표 초안 */
.nutri-label { border: 2px solid currentColor; border-radius: var(--r); padding: .6rem .8rem; }
.nutri-label table td:last-child, .nutri-label table th:last-child { text-align: right; }
/* 0.42.0 표시 초안 인쇄 */
.nutri-print { max-width: 22rem; background: #fff; color: #000; }
.nutri-print table { width: 100%; border-collapse: collapse; }
.nutri-print td, .nutri-print th { border-top: 1px solid #000; padding: .2rem .3rem; font-size: .9rem; }
.nutri-head { display: flex; justify-content: space-between; gap: .5rem; border-bottom: 3px solid #000; padding-bottom: .3rem; }
.nutri-foot { font-size: .75rem; margin-top: .3rem; }
.allergen-box { display: inline-block; border: 1px solid #000; padding: .2rem .5rem; }
.mission { margin: .3rem 0; }

/* 0.44.0 영양사 도구 */
.pre { white-space: pre-line; }
.receipt table th[scope="row"] { text-align: left; width: 8rem; }


/* ───────── 0.47.0 UX·접근성 개편 ───────── */
:root { --ease: cubic-bezier(.2, .7, .2, 1); --dur: .18s; --shadow: 0 6px 24px rgba(20, 40, 30, .14); --tabbar-h: 60px; }

/* 움직임: 부드럽게, 줄이기 설정이면 끔 */
.btn, button.btn, .choice, .care-item, .big3 a, .nav-panel a, .tabbar a, .mainnav summary, .account summary { transition: background-color var(--dur) var(--ease), color var(--dur) var(--ease), border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease), transform var(--dur) var(--ease); }
.btn:hover { box-shadow: 0 2px 8px rgba(31, 107, 74, .25); }
.btn:active, .big3 a:active, .care-item:active, .tabbar a:active { transform: scale(.97); }
.btn.secondary:hover { background: var(--ok-bg); }
.care-item:hover, .big3 a.alt:hover { border-color: var(--brand); }
@keyframes mm-rise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@keyframes mm-drop { from { opacity: 0; transform: translateY(-4px) scale(.98); } to { opacity: 1; transform: none; } }
main > * { animation: mm-rise .28s var(--ease) both; }
main > *:nth-child(2) { animation-delay: .03s; } main > *:nth-child(3) { animation-delay: .06s; } main > *:nth-child(n+4) { animation-delay: .09s; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
html { scroll-behavior: smooth; }
main:focus { outline: none; }

/* 누르는 곳 44px 이상 · 지금 위치 표시 */
.top-inner { gap: .4rem .8rem; min-height: 56px; }
.top .logo { margin-right: 0; }
.mainnav { margin-right: auto; }
.nav-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .15rem .3rem; align-items: center; }
.nav-list > li > a, .mainnav summary, .account summary, .public-nav a:not(.btn) { display: inline-flex; align-items: center; min-height: 44px; padding: 0 .6rem; border-radius: 8px; color: var(--brand-ink); text-decoration: none; font-weight: 600; cursor: pointer; }
.nav-list > li > a:hover, .mainnav summary:hover, .account summary:hover, .public-nav a:not(.btn):hover { background: rgba(255, 255, 255, .14); }
.nav-list > li > a[aria-current="page"], .mainnav summary.is-current, .public-nav a[aria-current="page"] { background: rgba(255, 255, 255, .2); box-shadow: inset 0 -3px 0 #fff; }
.top a:focus-visible, .top summary:focus-visible, .top button:focus-visible { outline: 3px solid #fff; outline-offset: 1px; box-shadow: 0 0 0 6px var(--focus); }
summary { list-style: none; }
summary::-webkit-details-marker { display: none; }
.mainnav summary::after, .account summary::after { content: ""; width: .45em; height: .45em; margin-left: .45em; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: translateY(-2px) rotate(45deg); transition: transform var(--dur) var(--ease); }
details[open] > summary::after { transform: translateY(1px) rotate(-135deg); }
.nav-group, .account { position: relative; }
.nav-panel { list-style: none; margin: 0; padding: .35rem; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); }
.nav-panel a, .nav-panel .link-btn { display: flex; align-items: center; justify-content: space-between; gap: .5rem; min-height: 44px; padding: 0 .8rem; border-radius: 8px; color: var(--ink) !important; text-decoration: none; font-weight: 500; white-space: nowrap; }
.nav-panel a:hover, .nav-panel .link-btn:hover { background: var(--ok-bg); }
.nav-panel a[aria-current="page"] { background: var(--ok-bg); color: var(--brand) !important; font-weight: 700; box-shadow: inset 3px 0 0 var(--brand); }
.nav-panel form { margin: 0; }
.nav-panel .link-btn { width: 100%; background: none; border: 0; font: inherit; cursor: pointer; text-align: left; }
.account summary { max-width: 16rem; font-size: .9rem; }
.account-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 9rem; }
.account-role { opacity: .9; white-space: nowrap; }

/* 메뉴 찾기 */
.nav-search { position: relative; margin: .2rem 0; }
.nav-search input { min-height: 40px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .6); background: rgba(255, 255, 255, .95); padding: .3rem 1rem; }
.nav-results { list-style: none; margin: .3rem 0 0; padding: .35rem; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); position: absolute; left: 0; right: 0; z-index: 30; animation: mm-drop .16s var(--ease); }
.nav-results a { display: flex; justify-content: space-between; min-height: 44px; align-items: center; padding: 0 .8rem; border-radius: 8px; color: var(--ink) !important; text-decoration: none; }
.nav-results a small { color: var(--muted); font-weight: 400; }
.nav-results a.is-active, .nav-results a:hover { background: var(--ok-bg); }
.nav-results .empty { padding: .6rem .8rem; color: var(--muted); }

.nav-toggle { display: inline-flex; align-items: center; gap: .4rem; min-height: 44px; padding: 0 .8rem; border-radius: 8px; border: 1px solid rgba(255, 255, 255, .7); background: transparent; color: #fff; font: inherit; font-weight: 700; cursor: pointer; }
.nav-toggle-icon, .nav-toggle-icon::before, .nav-toggle-icon::after { display: block; width: 18px; height: 2px; background: currentColor; border-radius: 2px; position: relative; transition: transform var(--dur) var(--ease), opacity var(--dur); }
.nav-toggle-icon::before, .nav-toggle-icon::after { content: ""; position: absolute; left: 0; }
.nav-toggle-icon::before { top: -6px; } .nav-toggle-icon::after { top: 6px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-icon { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-icon::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-icon::after { transform: translateY(-6px) rotate(-45deg); }

/* 데스크톱: 묶음은 펼침 목록 */
@media (min-width: 900px) {
  .nav-toggle { display: none !important; }
  .nav-panel { position: absolute; top: calc(100% + 6px); left: 0; min-width: 13rem; z-index: 40; animation: mm-drop .16s var(--ease); }
  .nav-panel.right { left: auto; right: 0; }
  .nav-search { width: 11rem; order: 99; }
  .top .mainnav { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
  .top-inner { max-width: 1280px; }
  .nav-account { display: none; }
}
/* 휴대폰·태블릿: 메뉴 단추로 열고 닫음 */
@media (max-width: 899.98px) {
  .top-inner { padding: .4rem .75rem; }
  .top .logo { margin-right: auto; }
  .top .mainnav { display: none; }
  .top .mainnav.is-open { display: block; animation: mm-drop .2s var(--ease); }
  .mainnav { order: 10; flex-basis: 100%; padding: .4rem 0 .8rem; }
  .nav-list { flex-direction: column; align-items: stretch; gap: .2rem; }
  .nav-list > li > a, .mainnav summary { display: flex; justify-content: space-between; width: 100%; min-height: 48px; padding: 0 .8rem; background: rgba(255, 255, 255, .08); }
  .nav-panel { margin: .25rem 0 .4rem .5rem; box-shadow: none; }
  .top .account { display: none; }
  .nav-account { margin-top: .6rem; padding-top: .6rem; border-top: 1px solid rgba(255, 255, 255, .3); }
  .nav-account p { margin: 0 0 .3rem .2rem; font-size: .9rem; opacity: .95; }
  .text-toggle { order: 2; }
  .nav-toggle { order: 3; }
  .public-nav { flex-basis: 100%; gap: .1rem .2rem; }
}

/* 휴대폰 아래쪽 빠른 메뉴 */
.tabbar { display: none; }
@media (max-width: 899.98px) {
  body.has-tabbar { padding-bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); }
  .tabbar { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; background: #fff; border-top: 1px solid var(--line); box-shadow: 0 -4px 16px rgba(20, 40, 30, .08); padding-bottom: env(safe-area-inset-bottom); }
  .tabbar a, .tabbar button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: var(--tabbar-h); color: var(--muted); text-decoration: none; font: inherit; font-size: .78rem; font-weight: 600; background: none; border: 0; cursor: pointer; }
  .tabbar a[aria-current="page"] { color: var(--brand); }
  .tabbar a[aria-current="page"] .ico { background-color: var(--ok-bg); }
  html.big-text .tabbar a, html.big-text .tabbar button { font-size: .8rem; }
}
.ico { display: block; width: 40px; height: 26px; border-radius: 13px; background-repeat: no-repeat; background-position: center; background-size: 22px; transition: background-color var(--dur) var(--ease); }
.ico-home { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231f6b4a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 11l9-7 9 7v9a1 1 0 0 1-1 1h-5v-6h-6v6H4a1 1 0 0 1-1-1z'/%3E%3C/svg%3E"); }
.ico-plus { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231f6b4a' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 8v8M8 12h8'/%3E%3C/svg%3E"); }
.ico-plate { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231f6b4a' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='8'/%3E%3Ccircle cx='12' cy='12' r='4'/%3E%3C/svg%3E"); }
.ico-bag { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231f6b4a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 8h14l-1 12H6z'/%3E%3Cpath d='M9 8a3 3 0 0 1 6 0'/%3E%3C/svg%3E"); }
.ico-people { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231f6b4a' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='9' cy='8' r='3'/%3E%3Cpath d='M3 20a6 6 0 0 1 12 0M16 11a3 3 0 1 0 0-6M21 20a6 6 0 0 0-4-5.6'/%3E%3C/svg%3E"); }
.ico-bell { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231f6b4a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 16V11a6 6 0 0 1 12 0v5l2 2H4z'/%3E%3Cpath d='M10 20a2 2 0 0 0 4 0'/%3E%3C/svg%3E"); }
.ico-check { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231f6b4a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='4' y='4' width='16' height='16' rx='3'/%3E%3Cpath d='M8 12l3 3 5-6'/%3E%3C/svg%3E"); }
.ico-menu { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231f6b4a' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M4 7h16M4 12h16M4 17h16'/%3E%3C/svg%3E"); }

/* 안내 상자: 성공·오류 구분(색만으로 구분하지 않게 아이콘·머리말) */
.flash { display: flex; gap: .6rem; align-items: flex-start; animation: mm-rise .3s var(--ease) both; }
.flash:focus { outline: 3px solid var(--focus); outline-offset: 2px; }
.flash-text { flex: 1; }
.flash-icon { flex: none; width: 1.4rem; height: 1.4rem; margin-top: .1rem; border-radius: 50%; background: var(--brand) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12l4 4 8-8'/%3E%3C/svg%3E") center / 70% no-repeat; }
.flash.is-error { background: var(--err-bg); border-color: #f0b8b5; color: var(--err); }
.flash.is-error .flash-icon { background: var(--err) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round'%3E%3Cpath d='M12 6v8M12 18h.01'/%3E%3C/svg%3E") center / 70% no-repeat; }
.flash-close { flex: none; min-width: 44px; min-height: 44px; margin: -.6rem -.8rem -.6rem 0; border: 0; background: none; color: inherit; font: inherit; font-size: 1.3rem; cursor: pointer; border-radius: 8px; }
.flash-close:hover { background: rgba(0, 0, 0, .06); }

/* 짧은 알림(복사됨 등) */
.toast { position: fixed; left: 50%; bottom: calc(1.2rem + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 60; background: #1b1f23; color: #fff; padding: .7rem 1.1rem; border-radius: 999px; box-shadow: var(--shadow); max-width: calc(100% - 2rem); animation: mm-rise .2s var(--ease) both; }
body.has-tabbar .toast { bottom: calc(var(--tabbar-h) + 1rem + env(safe-area-inset-bottom)); }

/* 입력 칸: 잘못 넣은 칸은 보낸 뒤에만 빨갛게 */
input:user-invalid, select:user-invalid, textarea:user-invalid { border-color: var(--err); box-shadow: 0 0 0 1px var(--err); }
input:focus, select:focus, textarea:focus { border-color: var(--brand); }
label:has(+ input[required])::after, label:has(+ select[required])::after, label:has(+ textarea[required])::after { content: " *"; color: var(--err); }
.req-note { font-size: .85rem; color: var(--muted); }
.char-count { display: block; text-align: right; font-size: .82rem; color: var(--muted); margin-top: .2rem; }
.char-count.is-near { color: var(--warn); font-weight: 700; }
.pw-wrap { position: relative; }
.pw-wrap input { padding-right: 5.2rem; }
.pw-toggle { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); min-height: 40px; padding: 0 .7rem; border: 0; border-radius: 6px; background: #eef1ee; color: var(--ink); font: inherit; font-size: .85rem; font-weight: 600; cursor: pointer; }

/* 보내는 중: 두 번 누르지 않게 */
button.is-busy, .btn.is-busy { position: relative; color: transparent !important; pointer-events: none; }
button.is-busy::after, .btn.is-busy::after { content: ""; position: absolute; width: 1.1rem; height: 1.1rem; border: 2px solid currentColor; border-color: var(--brand) transparent var(--brand) transparent; border-radius: 50%; animation: mm-spin .7s linear infinite; }
.btn:not(.secondary):not(.danger).is-busy::after { border-color: #fff transparent #fff transparent; }
@keyframes mm-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { button.is-busy::after, .btn.is-busy::after { animation: none !important; border-color: currentColor; } }

/* 파일 끌어 놓기 */
.dropzone { position: relative; display: block; border: 2px dashed #9aa5ae; border-radius: 12px; padding: 1rem; background: #fbfcfb; text-align: center; cursor: pointer; transition: border-color var(--dur) var(--ease), background-color var(--dur) var(--ease), transform var(--dur) var(--ease); }
.dropzone input[type=file] { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; min-height: 0; }
.dropzone:focus-within { outline: 3px solid var(--focus); outline-offset: 2px; }
.dropzone.is-over { border-color: var(--brand); background: var(--ok-bg); transform: scale(1.01); }
.dropzone.is-bad { border-color: var(--err); background: var(--err-bg); }
.dropzone-title { font-weight: 700; display: block; }
.dropzone-hint { color: var(--muted); font-size: .85rem; display: block; }
.dropzone-files { list-style: none; padding: 0; margin: .5rem 0 0; font-size: .9rem; text-align: left; }
.dropzone-files li { display: flex; justify-content: space-between; gap: .5rem; padding: .25rem .5rem; background: #fff; border: 1px solid var(--line); border-radius: 8px; margin-top: .25rem; }

/* 표: 옆으로 넘치면 안내 + 키보드로도 밀 수 있게 */
.table-wrap { position: relative; background: linear-gradient(to right, #fff 30%, rgba(255,255,255,0)) left / 2rem 100% no-repeat local, linear-gradient(to left, #fff 30%, rgba(255,255,255,0)) right / 2rem 100% no-repeat local, radial-gradient(farthest-side at 0 50%, rgba(0,0,0,.14), transparent) left / .8rem 100% no-repeat scroll, radial-gradient(farthest-side at 100% 50%, rgba(0,0,0,.14), transparent) right / .8rem 100% no-repeat scroll; }
.table-wrap table { background: transparent; }
.table-wrap:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.scroll-hint { font-size: .82rem; color: var(--muted); margin: .2rem 0 0; }
tbody tr:hover td { background: #fafcfa; }

/* 카드·제목 다듬기 */
.card { box-shadow: 0 1px 2px rgba(20, 40, 30, .04); }
.card > h2:first-child { margin-top: 0; }
h1 { letter-spacing: -.01em; line-height: 1.35; }
@media (max-width: 599.98px) {
  main { padding: .75rem; }
  .card { padding: .85rem; border-radius: 12px; }
  .actions .btn { flex: 1 1 auto; }
  dl.kv { grid-template-columns: 1fr; }
  dl.kv dt { margin-top: .4rem; }
  .msg { max-width: 100%; }
}
.foot a { color: var(--muted); }
@media print { .tabbar, .toast, .nav-toggle, .account, .skip { display: none !important; } }
/* 고대비 모드(윈도) */
@media (forced-colors: active) {
  .nav-list > li > a[aria-current="page"], .nav-panel a[aria-current="page"], .tabbar a[aria-current="page"] { outline: 2px solid CanvasText; }
  .flash-icon, .ico { forced-color-adjust: none; }
  button.is-busy { color: ButtonText !important; }
}
.nav-list details, .account { margin: 0; }
.top .nav-panel .link-btn { border: 0; min-height: 44px; padding: 0 .8rem; font-size: 1rem; justify-content: flex-start; color: var(--ink); border-radius: 8px; }
.account-role { margin-left: .3em; }
label:has(+ .pw-wrap input[required])::after, label:has(+ .dropzone input[required])::after { content: " *"; color: var(--err); }
@media (max-width: 899.98px) { .public-nav { order: 10; } }
.tabbar a span:last-child, .tabbar button span:last-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; line-height: 1.2; }
html.big-text { --tabbar-h: 64px; }

/* ───────── 0.48.0 AARRR: 첫 화면·활성화·유지·추천 ───────── */
:root { --brand-2: #2f8a62; --mint: #e9f5ee; --sun: #fff3d6; --ink-soft: #33403a; }
.w0 { width: 0; } .w10 { width: 10%; } .w20 { width: 20%; } .w30 { width: 30%; } .w40 { width: 40%; } .w50 { width: 50%; } .w60 { width: 60%; } .w70 { width: 70%; } .w80 { width: 80%; } .w90 { width: 90%; } .w100 { width: 100%; }

/* 첫 화면 */
.lp-hero { display: grid; gap: 1.5rem; align-items: center; padding: 1.5rem 0 1rem; }
@media (min-width: 860px) { .lp-hero { grid-template-columns: 1.15fr .85fr; gap: 2.5rem; padding: 2.5rem 0 1.5rem; } }
.lp-eyebrow { display: inline-block; margin: 0 0 .6rem; padding: .2rem .75rem; border-radius: 999px; background: var(--mint); color: var(--brand); font-weight: 700; font-size: .9rem; }
.lp-hero h1 { font-size: clamp(1.75rem, 5.2vw, 2.7rem); line-height: 1.25; margin: 0 0 .8rem; letter-spacing: -.02em; }
.lp-mark { background: linear-gradient(transparent 62%, #ffe08a 62%); padding: 0 .1em; }
.lp-lead { font-size: 1.08rem; color: var(--ink-soft); max-width: 36rem; margin: 0 0 1rem; }
.lp-cta { display: flex; flex-wrap: wrap; gap: .6rem; }
.lp-cta .btn { flex: 0 1 auto; }
@media (max-width: 599.98px) { .lp-cta .btn { flex: 1 1 100%; } }
.lp-assure { list-style: none; padding: 0; margin: 1rem 0 0; display: flex; flex-wrap: wrap; gap: .3rem 1rem; color: var(--muted); font-size: .9rem; }
.lp-assure li::before { content: "✓ "; color: var(--brand); font-weight: 700; }
.lp-preview { margin: 0; background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 1.1rem 1.2rem; box-shadow: 0 18px 40px rgba(31, 107, 74, .14); position: relative; animation: mm-rise .5s var(--ease) both .1s; }
.lp-preview-tag { font-size: .8rem; color: var(--muted); margin-bottom: .4rem; }
.lp-pv-big { margin: 0 0 .6rem; } .lp-pv-big span { display: block; color: var(--muted); font-size: .9rem; } .lp-pv-big b { font-size: 2.6rem; color: var(--brand); letter-spacing: -.02em; }
.lp-pv-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: .4rem; margin-bottom: .8rem; }
.lp-pv-grid p { margin: 0; background: var(--mint); border-radius: 10px; padding: .45rem .55rem; } .lp-pv-grid span { display: block; font-size: .75rem; color: var(--muted); } .lp-pv-grid b { font-size: .92rem; }
.lp-pv-bars { list-style: none; padding: 0; margin: 0 0 .7rem; display: grid; gap: .35rem; }
.lp-pv-bars li { display: grid; grid-template-columns: 2.6rem 1fr 2.6rem; align-items: center; gap: .5rem; font-size: .85rem; }
.lp-pv-bars i { display: block; height: 10px; border-radius: 6px; background: linear-gradient(90deg, var(--brand), var(--brand-2)); animation: mm-grow .9s var(--ease) both .4s; transform-origin: left; }
.lp-pv-bars b { text-align: right; color: var(--muted); font-weight: 600; }
@keyframes mm-grow { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.lp-pv-rec { margin: 0; padding-top: .6rem; border-top: 1px dashed var(--line); font-size: .92rem; } .lp-pv-rec strong { display: block; color: var(--brand); font-size: .82rem; }
.lp-proof { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .6rem; margin: 1rem 0 1.5rem; }
.lp-proof-item { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: .9rem 1rem; }
.lp-proof-item b { display: block; font-size: 1.7rem; color: var(--brand); letter-spacing: -.02em; line-height: 1.2; }
.lp-proof-item span { display: block; font-weight: 700; } .lp-proof-item small { color: var(--muted); font-size: .8rem; }
.lp-chips .choice { background: #fff; }
.lp-features { display: grid; gap: .8rem; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.lp-f { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 1.1rem 1.1rem 1rem; transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease); }
.lp-f:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.lp-f h3 { margin: .5rem 0 .3rem; font-size: 1.08rem; } .lp-f p { margin: 0; color: var(--ink-soft); font-size: .95rem; }
.lp-ico { display: block; width: 46px; height: 46px; border-radius: 14px; background-color: var(--mint); background-size: 26px; background-position: center; background-repeat: no-repeat; }
.lp-journey-wrap { margin-top: 1.5rem; }
.lp-journey { list-style: none; padding: 0; margin: 0; display: grid; gap: .6rem; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); counter-reset: j; }
.lp-journey li { position: relative; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: .9rem 1rem; }
.lp-journey li b { display: inline-block; font-size: .8rem; background: var(--brand); color: #fff; border-radius: 999px; padding: .05rem .6rem; margin-bottom: .35rem; }
.lp-journey strong { display: block; } .lp-journey span { color: var(--muted); font-size: .9rem; }
.lp-center { justify-content: center; }
.lp-biz h3 { margin-top: 0; }
.lp-faq details { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 0 1rem; margin: .4rem 0; }
.lp-faq summary { min-height: 52px; display: flex; align-items: center; justify-content: space-between; font-weight: 700; cursor: pointer; }
.lp-faq summary::after { content: "+"; font-size: 1.3rem; color: var(--brand); transition: transform var(--dur) var(--ease); }
.lp-faq details[open] summary::after { transform: rotate(45deg); }
.lp-faq details p { margin: 0 0 1rem; color: var(--ink-soft); }
.lp-final { margin: 2rem 0 .5rem; padding: 2rem 1.2rem; border-radius: 20px; text-align: center; color: #fff; background: radial-gradient(120% 140% at 0% 0%, #2f8a62 0%, var(--brand) 55%, #174f37 100%); }
.lp-final h2 { margin: 0 0 .4rem; font-size: 1.5rem; } .lp-final p { margin: 0; opacity: .95; }
.btn.lp-invert { background: #fff; color: var(--brand); border-color: #fff; }
.btn.lp-invert-2 { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .8); }
.btn.lp-invert-2:hover { background: rgba(255, 255, 255, .12); }

/* 결과 저장 막대 */
.save-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 45; display: flex; align-items: center; justify-content: space-between; gap: .8rem; padding: .7rem 1rem calc(.7rem + env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid var(--line); box-shadow: 0 -6px 20px rgba(20, 40, 30, .12); animation: mm-rise .3s var(--ease) both .6s; }
.save-bar p { margin: 0; line-height: 1.3; } .save-bar strong { display: block; color: var(--warn); font-size: .92rem; } .save-bar span { font-size: .85rem; color: var(--muted); }
body:has(.save-bar) { padding-bottom: 84px; }
body.has-tabbar .save-bar { bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom)); padding-bottom: .7rem; }
@media (max-width: 899.98px) { body.has-tabbar:has(.save-bar) { padding-bottom: calc(var(--tabbar-h) + 84px); } }
.unlock { list-style: none; padding: 0; margin: .3rem 0 .6rem; }
.unlock li { padding: .2rem 0 .2rem 1.6rem; position: relative; } .unlock li::before { content: "✓"; position: absolute; left: .3rem; color: var(--brand); font-weight: 800; }

/* 시작 단계 */
.onboard { border-color: var(--brand); background: linear-gradient(180deg, var(--mint), #fff 60%); }
.onboard-head { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem 1rem; }
.onboard-head h2 { margin: 0; } .onboard-count { color: var(--brand); }
.meter { flex: 1 1 10rem; height: 10px; background: #d9e8df; border-radius: 6px; overflow: hidden; }
.meter i { display: block; height: 100%; background: linear-gradient(90deg, var(--brand), var(--brand-2)); border-radius: 6px; animation: mm-grow .8s var(--ease) both; transform-origin: left; }
.onboard-steps { list-style: none; padding: 0; margin: .8rem 0 0; display: grid; gap: .3rem; }
.onboard-steps li { display: flex; align-items: center; gap: .6rem; min-height: 48px; padding: .2rem .4rem; border-radius: 10px; }
.onboard-steps li a { display: flex; flex-direction: column; text-decoration: none; color: var(--ink); flex: 1; }
.onboard-steps small { color: var(--muted); }
.onboard-steps li.is-next { background: #fff; box-shadow: inset 0 0 0 2px var(--brand); }
.onboard-steps li.is-done { color: var(--muted); } .onboard-steps li.is-done strong { text-decoration: line-through; text-decoration-color: rgba(0,0,0,.25); font-weight: 600; }
.ob-mark { flex: none; width: 24px; height: 24px; border-radius: 50%; border: 2px solid #9aa5ae; background: #fff; }
.is-done .ob-mark { border-color: var(--brand); background: var(--brand) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12l4 4 8-8'/%3E%3C/svg%3E") center / 70% no-repeat; }
.is-next .ob-mark { border-color: var(--brand); }

/* 연속 기록 · 이번 주 */
.streak { background: var(--sun); border-radius: 14px; padding: .7rem .8rem; margin: .5rem 0; }
.streak-head { display: flex; align-items: center; gap: .7rem; margin: 0 0 .5rem; }
.streak-head small { display: block; color: var(--ink-soft); font-size: .85rem; }
.streak-num { flex: none; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; background: #fff; color: #b5560b; font-size: 1.3rem; font-weight: 800; box-shadow: inset 0 0 0 3px #f3b25a; }
.week-dots { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(7, 1fr); gap: .3rem; }
.week-dots li { display: grid; place-items: center; height: 34px; border-radius: 10px; background: #fff; color: var(--muted); font-size: .82rem; font-weight: 700; border: 1px solid #f0dcb4; }
.week-dots li.on { background: #f39c2c; color: #fff; border-color: #f39c2c; }
.week-dots li.today { box-shadow: 0 0 0 2px var(--ink); }
.week-dots li.future { opacity: .55; }
.welcome-back { background: var(--mint); border-left: 4px solid var(--brand); padding: .6rem .8rem; border-radius: 8px; margin: .5rem 0; }
.today-left { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; margin: .4rem 0; }
.chip { display: inline-flex; align-items: center; min-height: 40px; padding: 0 .8rem; border-radius: 999px; border: 1px solid var(--brand); color: var(--brand); text-decoration: none; font-weight: 700; font-size: .9rem; background: #fff; }
.chip:hover { background: var(--mint); }
.invite-card { background: linear-gradient(135deg, #fff, var(--sun)); }

/* 성장 지표 */
.seg { display: inline-flex; gap: .2rem; background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: .2rem; margin-bottom: .6rem; }
.seg a { min-height: 40px; display: inline-flex; align-items: center; padding: 0 .9rem; border-radius: 999px; text-decoration: none; font-weight: 700; color: var(--ink); }
.seg a[aria-current="page"] { background: var(--brand); color: #fff; }
.funnel { list-style: none; padding: 0; margin: 0 0 1rem; display: grid; gap: .5rem; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.funnel-step { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: .8rem .9rem; display: flex; flex-direction: column; gap: .1rem; position: relative; }
.funnel-step b { font-size: 1.8rem; color: var(--brand); line-height: 1.1; }
.funnel-k { font-size: .7rem; letter-spacing: .08em; color: var(--muted); font-weight: 700; }
.funnel-step small { color: var(--muted); }
.funnel-step.is-leak { border-color: var(--warn); box-shadow: inset 0 0 0 2px #f1cf94; } .funnel-step.is-leak b { color: var(--warn); }
code { background: #eef1ee; padding: .05rem .35rem; border-radius: 4px; font-size: .9em; }
.funnel-k { text-transform: uppercase; }

/* ───────── 0.49.0 체감 속도 ───────── */
/* 화면 사이 부드러운 전환(지원하는 브라우저만, 움직임 줄이기면 끔) */
@media (prefers-reduced-motion: no-preference) {
  @view-transition { navigation: auto; }
  ::view-transition-old(root), ::view-transition-new(root) { animation-duration: .16s; }
}
/* 0.3초 넘게 걸리는 이동에만 보이는 위쪽 진행 막대 */
.nav-progress { position: fixed; top: 0; left: 0; height: 3px; width: 0; z-index: 100; background: linear-gradient(90deg, #ffd166, #fff); box-shadow: 0 0 6px rgba(0, 0, 0, .2); }
.nav-progress.is-going { animation: mm-progress 8s cubic-bezier(.1, .7, .2, 1) forwards; }
@keyframes mm-progress { 0% { width: 0; } 20% { width: 45%; } 60% { width: 75%; } 100% { width: 92%; } }
@media (prefers-reduced-motion: reduce) { .nav-progress.is-going { animation: none !important; width: 60%; } }
/* 화면 밖 긴 영역은 보일 때 그림(첫 화면 그리기 빨라짐) */
.lp-faq, .lp-biz, .lp-journey-wrap, .invite-card { content-visibility: auto; contain-intrinsic-size: auto 400px; }
img { max-width: 100%; height: auto; }
.filter-bar { display: grid; gap: .5rem 1rem; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); align-items: end; }
.filter-bar .actions { margin: 0; }
.pager { display: flex; gap: .8rem; align-items: center; justify-content: center; margin: 1rem 0; }
.pager a { min-height: 44px; display: inline-flex; align-items: center; padding: 0 1rem; border: 1px solid var(--line); border-radius: 999px; background: #fff; text-decoration: none; font-weight: 700; }

/* 0.50.0 경쟁 비교 5차: 시그니처·적용 제안 */
.daily-tip { margin: .5rem 0 1rem; padding: .7rem 1rem; border-left: 4px solid var(--brand); background: var(--mint); border-radius: 8px; }
.daily-tip strong { margin-right: .4rem; }
.guard-card { border-left: 4px solid #d98b2b; }
.broth-saved { margin: .4rem 0 .8rem; padding: .5rem .8rem; border-radius: 8px; background: #eef6ff; }
.btn.broth-on { background: #2f6db5; color: #fff; }
.cost-card .lead b, .window-card .lead { font-variant-numeric: tabular-nums; }
.filter-line { margin: .3rem 0 .8rem; }
.chips { display: flex; flex-wrap: wrap; gap: .4rem; margin: .4rem 0; }
.chip-form { margin: 0; }
.shopping-table tr.at-home td { opacity: .7; }
.lesson-list { list-style: none; padding: 0; }
.lesson-list .locked { opacity: .6; }
fieldset.scale { display: flex; flex-wrap: wrap; gap: .3rem .8rem; align-items: center; }
.triage summary { cursor: pointer; }
.plain-list { list-style: none; padding: 0; }
.plain-list li { padding: .35rem 0; border-bottom: 1px solid var(--line, #e5e7eb); }
.share-list { list-style: none; padding: 0; margin: .5rem 0; }
.share-list > li { padding: .6rem 0; border-bottom: 1px solid var(--line, #e5e7eb); }
.share-pct { float: right; font-weight: 800; font-size: 1.15rem; color: var(--brand); }

/* 0.51.0 어두운 화면(바닥글에서 켜고 끔, 쿠키 mm_theme) — 대비 4.5:1 이상 */
:root[data-theme="dark"] {
  --ink: #e7eaed; --muted: #b3bcc5; --line: #3b444c; --bg: #121618; --card: #1b2024;
  --brand: #7fd6ad; --brand-ink: #0f1f17; --warn: #f3c27a; --warn-bg: #33260f;
  --err: #ff9a93; --err-bg: #3a1b1a; --ok-bg: #173327; --focus: #8fb3ff;
  --brand-2: #7fd6ad; --mint: #1d3329; --sun: #33290f; --ink-soft: #d0d6db;
  color-scheme: dark;
}
:root[data-theme="dark"] .top { background: #133a28; color: #fff; }
:root[data-theme="dark"] .top a, :root[data-theme="dark"] .top .link-btn { color: #fff; }
:root[data-theme="dark"] .skip, :root[data-theme="dark"] .code-box, :root[data-theme="dark"] .btn.secondary, :root[data-theme="dark"] .btn.danger,
:root[data-theme="dark"] table, :root[data-theme="dark"] .postcode-layer, :root[data-theme="dark"] .choice, :root[data-theme="dark"] .big3 a.alt,
:root[data-theme="dark"] .nav-panel, :root[data-theme="dark"] .nav-results, :root[data-theme="dark"] .lp-preview, :root[data-theme="dark"] .lp-proof-item,
:root[data-theme="dark"] .lp-chips .choice, :root[data-theme="dark"] .lp-f, :root[data-theme="dark"] .lp-journey li, :root[data-theme="dark"] .lp-faq details,
:root[data-theme="dark"] .onboard-steps li.is-next, :root[data-theme="dark"] .ob-mark, :root[data-theme="dark"] .week-dots li, :root[data-theme="dark"] .chip,
:root[data-theme="dark"] .seg, :root[data-theme="dark"] .funnel-step, :root[data-theme="dark"] .tabbar, :root[data-theme="dark"] .pw-toggle,
:root[data-theme="dark"] .dropzone, :root[data-theme="dark"] .dropzone-files li, :root[data-theme="dark"] .save-bar, :root[data-theme="dark"] .pager a,
:root[data-theme="dark"] .care-item { background: var(--card); color: var(--ink); }
:root[data-theme="dark"] input, :root[data-theme="dark"] select, :root[data-theme="dark"] textarea { background: #11161a; color: var(--ink); border-color: #66717c; }
:root[data-theme="dark"] input[readonly] { background: #232a2f; }
:root[data-theme="dark"] th, :root[data-theme="dark"] code { background: #242b30; }
:root[data-theme="dark"] tbody tr:hover td { background: #20272b; }
:root[data-theme="dark"] pre.doc, :root[data-theme="dark"] .msg { background: #20262a; }
:root[data-theme="dark"] .msg.mine { background: #1d3329; }
:root[data-theme="dark"] .broth-saved { background: #172838; }
:root[data-theme="dark"] .btn.broth-on { background: #8fb8ea; color: #0c1622; }
:root[data-theme="dark"] .week-dots li.on { background: #f3a94a; color: #1b1205; }
:root[data-theme="dark"] .btn.lp-invert, :root[data-theme="dark"] .top .btn.small { background: var(--card); color: var(--brand); }
:root[data-theme="dark"] img { opacity: .92; }
@media print { :root[data-theme="dark"] { --ink: #1b1f23; --bg: #fff; --card: #fff; --line: #d5dae0; --muted: #4d5560; --brand: #1f6b4a; } }
.theme-toggle { margin-left: .3rem; }
/* 0.51.0 배지·편의점 조합·동네 밥상·프로필 순서 */
.badges { display: flex; flex-wrap: wrap; gap: .4rem; margin: .4rem 0; padding: 0; list-style: none; }
.badges li { padding: .2rem .7rem; border-radius: 999px; background: var(--sun, #fff3d6); font-weight: 700; font-size: .85rem; }
.badges li.new { box-shadow: 0 0 0 2px #f39c2c; }
.order-btns { display: inline-flex; gap: .3rem; margin-left: .4rem; vertical-align: middle; }
.order-btns .btn { min-height: 36px; padding: 0 .6rem; }
[draggable="true"] { cursor: grab; }
.dragging { opacity: .5; }
.drop-before { box-shadow: 0 -3px 0 var(--brand); }

/* 0.52.0 기기 설정이 어두우면 따름(밝게를 고른 사람은 제외) — 위 어두운 화면 규칙과 같음 */
@media screen and (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ink: #e7eaed; --muted: #b3bcc5; --line: #3b444c; --bg: #121618; --card: #1b2024;
    --brand: #7fd6ad; --brand-ink: #0f1f17; --warn: #f3c27a; --warn-bg: #33260f;
    --err: #ff9a93; --err-bg: #3a1b1a; --ok-bg: #173327; --focus: #8fb3ff;
    --brand-2: #7fd6ad; --mint: #1d3329; --sun: #33290f; --ink-soft: #d0d6db;
    color-scheme: dark;
  }
  :root:not([data-theme="light"]) .top { background: #133a28; color: #fff; }
  :root:not([data-theme="light"]) .top a, :root:not([data-theme="light"]) .top .link-btn { color: #fff; }
  :root:not([data-theme="light"]) .skip, :root:not([data-theme="light"]) .code-box, :root:not([data-theme="light"]) .btn.secondary, :root:not([data-theme="light"]) .btn.danger,
  :root:not([data-theme="light"]) table, :root:not([data-theme="light"]) .postcode-layer, :root:not([data-theme="light"]) .choice, :root:not([data-theme="light"]) .big3 a.alt,
  :root:not([data-theme="light"]) .nav-panel, :root:not([data-theme="light"]) .nav-results, :root:not([data-theme="light"]) .lp-preview, :root:not([data-theme="light"]) .lp-proof-item,
  :root:not([data-theme="light"]) .lp-chips .choice, :root:not([data-theme="light"]) .lp-f, :root:not([data-theme="light"]) .lp-journey li, :root:not([data-theme="light"]) .lp-faq details,
  :root:not([data-theme="light"]) .onboard-steps li.is-next, :root:not([data-theme="light"]) .ob-mark, :root:not([data-theme="light"]) .week-dots li, :root:not([data-theme="light"]) .chip,
  :root:not([data-theme="light"]) .seg, :root:not([data-theme="light"]) .funnel-step, :root:not([data-theme="light"]) .tabbar, :root:not([data-theme="light"]) .pw-toggle,
  :root:not([data-theme="light"]) .dropzone, :root:not([data-theme="light"]) .dropzone-files li, :root:not([data-theme="light"]) .save-bar, :root:not([data-theme="light"]) .pager a,
  :root:not([data-theme="light"]) .care-item { background: var(--card); color: var(--ink); }
  :root:not([data-theme="light"]) input, :root:not([data-theme="light"]) select, :root:not([data-theme="light"]) textarea { background: #11161a; color: var(--ink); border-color: #66717c; }
  :root:not([data-theme="light"]) input[readonly] { background: #232a2f; }
  :root:not([data-theme="light"]) th, :root:not([data-theme="light"]) code { background: #242b30; }
  :root:not([data-theme="light"]) tbody tr:hover td { background: #20272b; }
  :root:not([data-theme="light"]) pre.doc, :root:not([data-theme="light"]) .msg { background: #20262a; }
  :root:not([data-theme="light"]) .msg.mine { background: #1d3329; }
  :root:not([data-theme="light"]) .broth-saved { background: #172838; }
  :root:not([data-theme="light"]) .btn.broth-on { background: #8fb8ea; color: #0c1622; }
  :root:not([data-theme="light"]) .week-dots li.on { background: #f3a94a; color: #1b1205; }
  :root:not([data-theme="light"]) .btn.lp-invert, :root:not([data-theme="light"]) .top .btn.small { background: var(--card); color: var(--brand); }
  :root:not([data-theme="light"]) img { opacity: .92; }
}
.theme-pick strong { font-weight: 800; }
.ux-vote { max-width: 1100px; margin: 1rem auto 0; padding: .6rem 1rem; display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; justify-content: center; font-size: .9rem; color: var(--muted); }
.ux-vote .btn { min-height: 40px; padding: 0 .9rem; }
.kmap { width: 100%; height: 360px; border-radius: var(--r); border: 1px solid var(--line); margin: .6rem 0; }
.ab-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: .8rem; }

/* 0.62.0 큰 글씨 조리 화면 · 장보기 종이 */
.cook .cook-step { font-size: 1.5rem; line-height: 1.6; }
.paper-list { list-style: none; padding: 0; font-size: 1.25rem; line-height: 2; }
@media print { .noprint { display: none !important; } .paper-list { font-size: 16pt; } }

/* 0.68.0 세 공간 · 대화함 · 주문 뒤 */
.space-tag { display: inline-block; font-size: .8rem; font-weight: 700; padding: .1rem .6rem; border-radius: 999px; background: rgba(255,255,255,.18); border: 1px solid rgba(255,255,255,.6); }
.top .space-partner { background: #0f4a8a; } .top .space-admin { background: #5a2a7a; }
.space-card { border-top: 6px solid var(--brand); }
.space-card.space-partner { border-top-color: #0f4a8a; } .space-card.space-admin { border-top-color: #5a2a7a; }
.space-card .space-tag { color: var(--ink); background: var(--bg); border-color: var(--line); }
.inbox-list { list-style: none; padding: 0; margin: 0; }
.inbox-list .badge { margin-left: .3rem; }
.badge.new { background: #fff3d6; color: #8a4b00; } .badge.warn { background: var(--err-bg); color: var(--err); }
.inbox-allergy { border-left: 6px solid var(--err); }
.chat { list-style: none; padding: 0; margin: 0 0 1rem; display: flex; flex-direction: column; gap: .6rem; }
.chat-msg { max-width: 85%; padding: .6rem .9rem; border-radius: 14px; background: var(--card); border: 1px solid var(--line); }
.chat-msg.mine { align-self: flex-end; background: #fef01b33; border-color: #e5d200; }
.chat-msg.theirs { align-self: flex-start; }
.chat-msg p { margin: .2rem 0; }
.chat-body { white-space: pre-line; word-break: break-word; }
.big-tap { min-height: 64px; font-size: 1.15rem; padding: 0 1.4rem; }
.milestones { list-style: none; padding: 0; }
.milestones li { padding: .7rem .9rem; border: 1px solid var(--line); border-radius: var(--r); margin-bottom: .5rem; background: var(--card); }
.milestones li.done { background: var(--ok-bg); border-color: var(--brand); }
.rule-ok { color: #1f6b4a; font-weight: 600; } .rule-over { color: var(--warn); font-weight: 600; } .rule-check { color: var(--muted); }
.btn.link { background: none; border: none; color: var(--brand); text-decoration: underline; min-height: auto; padding: 0; font-size: .9rem; }
