/* 채소테스트 화면
   어르신 기준: 본문 20px 이상, 버튼 56px 이상, 글자 대비 4.5:1 이상(큰 글자 3:1), 눌러도 되는 곳은 테두리로 분명하게
   움직임: 들어올 때 투명도 + 12px + 흐림 4px(글자만), 나갈 때 150ms로 짧게, 누를 때 0.96,
   '동작 줄이기'를 켠 기기에서는 움직임을 뺀다(맨 아래) */
:root {
  --ink: #2b2630; --muted: #5f5a66; --line: #d6ccb8; --bg: #FBF6EC; --card: #fff;
  --c: #3E9B5F; --t: #EEF6EF; --d: #2C7446;
  --ease: cubic-bezier(0.2, 0, 0, 1);
  --ease-io: cubic-bezier(0.45, 0, 0.25, 1);
  --lift: 0 0 0 1px rgb(0 0 0 / .05), 0 1px 2px -1px rgb(0 0 0 / .08), 0 10px 22px -14px rgb(70 45 10 / .28);
  --font: 'Pretendard Variable', Pretendard, 'Malgun Gothic', 'Apple SD Gothic Neo', 'Noto Sans KR', sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--font); font-size: 21px; line-height: 1.55; word-break: keep-all; }
main { max-width: 540px; margin: 0 auto; padding: 16px 16px 56px; min-height: 100vh; }
h1, h2, p { margin: 0; }
h1, h2 { text-wrap: balance; }
p, li { text-wrap: pretty; }
button { font-family: inherit; color: inherit; cursor: pointer; -webkit-tap-highlight-color: transparent; }
a { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 4px solid #1f6feb; outline-offset: 3px; }
/* 화면이 바뀔 때 읽어 주기 기능을 위해 제목으로 초점을 옮긴다(app.js focusTitle). 누르는 곳이 아니라 테두리는 감춘다 */
h1[tabindex="-1"]:focus { outline: none; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ── 화면 바뀜: 새 화면은 아래에서 살짝 떠오르고, 떠나는 화면은 짧게 흐려진다 ── */
.screen { animation: screenIn .3s var(--ease) both; }
.screen.from-back { animation-name: screenInBack; }
.screen.hero { animation: none; }
.screen.hero.fade { animation: fadeIn .3s ease-out both; }
.screen.leaving, .screen.hero.leaving, .screen.hero.fade.leaving { animation: screenOut .15s ease-out both; pointer-events: none; }
@keyframes screenIn { from { opacity: 0; transform: translateY(12px); } }
@keyframes screenInBack { from { opacity: 0; transform: translateY(-12px); } }
@keyframes screenOut { to { opacity: 0; transform: translateY(-8px); } }
@keyframes fadeIn { from { opacity: 0; } }

/* 크게 한 번 등장하는 화면(표지·결과)은 조각마다 100ms씩 차례로 */
.st { animation: rise .55s var(--ease) both; animation-delay: calc(var(--i, 0) * 100ms); }
.st.big { animation-name: riseSoft; animation-duration: .7s; }
@keyframes rise { from { opacity: 0; transform: translateY(12px); filter: blur(4px); } }
@keyframes riseSoft { from { opacity: 0; transform: translateY(16px); } }

/* 아래쪽 조각은 화면에 들어올 때 떠오른다 (app.js observeReveal) */
.rv { opacity: 0; transform: translateY(14px); transition: opacity .5s var(--ease) var(--rd, 0ms), transform .5s var(--ease) var(--rd, 0ms); }
.rv.in { opacity: 1; transform: none; }

/* ── 표지 ── */
.cover { text-align: center; padding-top: 10px; }
.tag { display: inline-block; font-size: 18px; font-weight: 700; color: var(--d); background: #fff; border-radius: 40px; padding: 7px 18px; box-shadow: inset 0 0 0 2px var(--c), 0 6px 14px -10px var(--d); }
.cover h1 { font-size: 40px; line-height: 1.22; margin: 16px 0 10px; letter-spacing: -1.2px; font-weight: 800; }
.cover h1 span { color: var(--d); }
.cover .sub { font-size: 22px; font-weight: 700; color: #4a4450; letter-spacing: -.3px; }
.cover .meta { font-size: 19px; color: var(--muted); margin-top: 4px; }
.friend { background: var(--t); border-radius: 18px; padding: 12px 16px; font-size: 19px; font-weight: 700; color: var(--d); margin: 14px auto 0; box-shadow: inset 0 0 0 2px var(--c); }
.hero-bowl { position: relative; margin: 8px -8px 0; }
.hero-bowl::before, .hero-pic::before {
  content: ''; position: absolute; left: 50%; top: 52%; width: 86%; aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(closest-side, rgb(255 255 255 / .95), rgb(255 255 255 / .55) 62%, rgb(255 255 255 / 0));
  transform: translate(-50%, -50%); animation: glowIn 1s var(--ease) both; pointer-events: none;
}
@keyframes glowIn { from { opacity: 0; transform: translate(-50%, -50%) scale(.6); } }

/* ── 그릇 무대: 빈 그릇 위에 채소를 하나씩 올린다 ── */
.stage { position: relative; width: 100%; height: 0; padding-top: 65%; container-type: inline-size; }
.stage > .bowl { position: absolute; left: 0; bottom: 0; display: block; width: 100%; height: auto; }
/* 그릇과 채소 밑 그림자(그림에는 그림자가 없다) */
.stage::before { content: ''; position: absolute; left: 20%; right: 20%; bottom: -2%; height: 6%; border-radius: 50%; background: radial-gradient(closest-side, rgb(70 45 10 / .2), rgb(70 45 10 / 0)); }
.veg { position: absolute; isolation: isolate; }
.veg::after { content: ''; position: absolute; z-index: -1; left: 27%; right: 27%; top: 88%; height: 7%; border-radius: 50%; background: radial-gradient(closest-side, rgb(70 45 10 / .25), rgb(70 45 10 / 0)); }
.veg svg, .veg img { display: block; width: 100%; height: auto; }
.bob { will-change: transform; }
/* 표지: 채소가 뒷줄부터 차례로 그릇에 올라온 뒤, 아주 천천히 흔들린다 */
.stage.pop .veg { animation: popIn .6s var(--ease) both; animation-delay: calc(450ms + var(--i) * 70ms); }
@keyframes popIn { from { opacity: 0; transform: translateY(18px) scale(.9); } }
.stage.float .bob { animation: float 3.4s var(--ease-io) infinite alternate; animation-delay: calc(var(--i) * -.45s); }
@keyframes float { to { transform: translateY(-4px); } }
/* 결과를 찾는 동안: 채소들이 차례로 뛴다 */
.stage.hop .bob { animation: hop 1.2s var(--ease-io) infinite; animation-delay: calc(var(--i) * 110ms); }
@keyframes hop { 0%, 50%, 100% { transform: none; } 22% { transform: translateY(-16%); } }
/* 비빔밥 모으기: 모은 채소가 위에서 톡 떨어져 담기고, 빈자리는 세 번 숨 쉰다 */
.stage.collect .veg { opacity: 0; }
.in .stage.collect .veg { animation: dropIn .6s var(--ease) both; animation-delay: calc(var(--rd, 0ms) + 250ms + var(--i) * 90ms); }
@keyframes dropIn { from { opacity: 0; transform: translateY(-22px); } to { opacity: 1; transform: none; } }
.slot { position: absolute; height: 0; border-radius: 50%; background: rgb(255 255 255 / .9); box-shadow: inset 0 0 0 2.5px var(--sc); animation: breathe 2.4s var(--ease-io) 1.2s 3; }
.slot span { position: absolute; inset: 0; display: grid; place-items: center; font-weight: 800; color: var(--sc); font-size: 20px; font-size: clamp(14px, 5cqw, 28px); }
@keyframes breathe { 50% { transform: scale(1.08); opacity: .75; } }

/* ── 버튼 ── */
.primary { display: flex; align-items: center; justify-content: center; width: 100%; min-height: 72px; margin-top: 22px; border: 0; border-radius: 40px;
  background: var(--d); color: #fff; font-size: 26px; font-weight: 800; letter-spacing: -.3px; text-decoration: none; text-align: center;
  box-shadow: 0 1px 2px rgb(0 0 0 / .12), 0 12px 22px -14px var(--d);
  transition-property: transform, box-shadow, filter; transition-duration: .15s; transition-timing-function: ease-out; }
.primary:active { transform: scale(.96); filter: brightness(.94); }
.ghost { display: block; width: 100%; min-height: 60px; margin-top: 12px; border: 2px solid var(--line); border-radius: 40px; background: #fff; font-size: 21px; font-weight: 700;
  transition-property: transform, border-color; transition-duration: .15s; transition-timing-function: ease-out; }
.ghost:active { transform: scale(.96); }
@media (hover: hover) { .ghost:hover { border-color: #bfb298; } .primary:hover { filter: brightness(1.06); } }

/* ── 문항 ── */
.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 56px; }
.back { min-height: 56px; min-width: 96px; border: 0; background: none; font-size: 20px; font-weight: 700; color: var(--muted); text-align: left; padding: 0 4px; border-radius: 12px; }
.count { font-size: 19px; font-weight: 700; color: var(--muted); font-variant-numeric: tabular-nums; }
.track { position: relative; padding-top: 40px; margin: 0 0 26px; }
.track.plain { padding-top: 10px; }
.bar { height: 12px; background: #ebe3d3; border-radius: 6px; overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--c); border-radius: 6px; transform-origin: left center; transition: transform .55s var(--ease); }
.runner { position: absolute; top: 0; width: 40px; left: calc(var(--p, 0) * (100% - 40px)); transition: left .55s var(--ease); }
.runner svg, .runner img { display: block; width: 100%; height: auto; }
.intro { font-size: 20px; color: var(--muted); margin-bottom: 10px; }
.q { font-size: 31px; font-weight: 800; line-height: 1.32; letter-spacing: -.6px; }
.hint { font-size: 19px; color: var(--muted); margin-top: 8px; }
.choices { display: grid; gap: 14px; margin-top: 22px; }
.choice { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 84px; margin: 0; padding: 16px 18px;
  border: 2px solid var(--line); border-radius: 22px; background: var(--card); box-shadow: 0 1px 2px rgb(0 0 0 / .04), 0 10px 18px -14px rgb(70 45 10 / .35);
  font-size: 24px; font-weight: 700; text-align: left; line-height: 1.35;
  transition-property: transform, border-color, background-color, box-shadow; transition-duration: .15s; transition-timing-function: ease-out; }
.choice .lbl { text-wrap: balance; }
.choice .lbl small { display: block; font-size: 18px; font-weight: 500; color: var(--muted); margin-top: 2px; white-space: pre-line; }
.radio { flex: none; position: relative; width: 30px; height: 30px; border-radius: 50%; box-shadow: inset 0 0 0 2.5px #c9bca3;
  transition-property: background-color, box-shadow; transition-duration: .2s; transition-timing-function: ease-out; }
.radio svg { position: absolute; left: 5px; top: 5px; width: 20px; height: 20px; fill: none; stroke: #fff; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round;
  opacity: 0; transform: scale(.25); filter: blur(4px);
  transition-property: opacity, transform, filter; transition-duration: .3s; transition-timing-function: var(--ease); }
.choice.sel { border-color: var(--c); background: var(--t); }
.choice.sel .radio { background: var(--d); box-shadow: none; }
.choice.sel .radio svg { opacity: 1; transform: none; filter: blur(0); }
.choice:active { transform: scale(.96); }
@media (hover: hover) { .choice:not(.sel):not(:disabled):hover { border-color: #bfb298; } }

/* ── 결과를 찾는 동안 ── */
.loading { text-align: center; padding-top: 48px; }
.loading .stage { max-width: 440px; margin: 0 auto; }
.loading .q { margin-top: 20px; }
.dots { margin-top: 14px; }
.dots i { display: inline-block; width: 11px; height: 11px; margin: 0 5px; border-radius: 50%; background: var(--c); animation: dot 1.2s var(--ease-io) infinite; }
.dots i:nth-child(2) { animation-delay: .15s; }
.dots i:nth-child(3) { animation-delay: .3s; }
@keyframes dot { 0%, 60%, 100% { opacity: .3; transform: none; } 30% { opacity: 1; transform: translateY(-7px); } }

/* ── 결과 ── */
.result { text-align: center; }
.result .tag { margin-bottom: 4px; }
.hero-pic { position: relative; margin-top: 4px; }
.hero-pic::before { width: 80%; max-width: 340px; top: 50%; }
.hero-pic .pic { position: relative; }
.hero-pic .pic svg, .hero-pic .pic img { width: 62%; max-width: 250px; height: auto; }
.hero-pic.st { animation-name: picIn; animation-duration: .7s; }
@keyframes picIn { from { opacity: 0; transform: translateY(18px) scale(.9); } }
.result .grp { font-size: 19px; font-weight: 700; color: var(--d); }
.result .me { font-size: 22px; font-weight: 700; color: #4a4450; margin-top: 4px; }
.result h1 { font-size: 38px; line-height: 1.2; color: var(--d); letter-spacing: -1px; font-weight: 800; }
.result .line { font-size: 24px; font-weight: 700; margin-top: 10px; }
.result .meta { font-size: 19px; color: var(--muted); margin-top: 10px; text-align: center; }
.box { background: var(--card); border-radius: 24px; padding: 20px 20px; margin-top: 18px; text-align: left; box-shadow: var(--lift); }
.box h2 { font-size: 22px; margin-bottom: 8px; letter-spacing: -.3px; }
.box ul { margin: 0; padding-left: 1.1em; }
.box li { margin: 4px 0; }
.result .box p { margin: 0; }
.jobs { margin: 0; padding-left: 1.3em; }
.job { margin: 10px 0; }
.job b { font-size: 21px; }
.job small { display: block; font-size: 18px; color: var(--muted); }
.job .warn { color: #8a4b00; }
.org small, .job small, .job b { overflow-wrap: anywhere; }
.type { display: inline-block; font-size: 17px; font-weight: 700; color: var(--d); background: var(--t); border-radius: 20px; padding: 1px 10px; vertical-align: 2px; }
.note { font-size: 18px; color: var(--muted); margin-top: 10px !important; }
.later { background: var(--t); box-shadow: inset 0 0 0 2px var(--c); }
.partner { display: flex; gap: 12px; align-items: center; }
.partner .mini svg, .partner .mini img { display: block; width: 84px; height: auto; }
.check { background: #FFF8E6; box-shadow: inset 0 0 0 2px #E8C46A; }
.check h2 { color: #7a5200; }
.bowlbox { text-align: center; }
.bowlbox .stage { margin: 6px -4px 0; }
.bowlbox p { font-size: 19px; color: var(--muted); }
.num { font-variant-numeric: tabular-nums; }
.share { background: #FEE500; color: #3a1d1d; box-shadow: 0 1px 2px rgb(0 0 0 / .12), 0 12px 22px -14px #a58f00; }
.copied { font-size: 19px; color: var(--d); margin-top: 8px !important; font-weight: 700; }

/* ── 우리 동네에서 찾기 ── */
.picks { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 14px; }
.pick { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 68px; padding: 8px; border: 2px solid var(--line); border-radius: 18px; background: var(--card);
  font-size: 22px; font-weight: 700; overflow-wrap: anywhere; line-height: 1.3;
  box-shadow: 0 1px 2px rgb(0 0 0 / .04), 0 8px 14px -12px rgb(70 45 10 / .35);
  transition-property: transform, border-color, background-color; transition-duration: .15s; transition-timing-function: ease-out; }
.pick small { font-size: 16px; font-weight: 700; color: var(--d); font-variant-numeric: tabular-nums; }
.pick.zero small { color: var(--muted); font-weight: 500; }
.pick.sel { border-color: var(--c); background: var(--t); }
.pick:active { transform: scale(.96); }
@media (hover: hover) { .pick:not(.sel):hover { border-color: #bfb298; } }
.sample { background: #FFF1C2; color: #6b4a00; font-size: 18px; font-weight: 700; border-radius: 12px; padding: 8px 12px; margin-bottom: 12px; }
.sub-h { font-size: 21px; margin: 26px 0 0; }

/* ── 우리 동네에서 찾기 ①: 시·도 지도. 경계(Natural Earth) 위에 이름표가 누르는 곳. 색이 진할수록 맞는 기관이 많다 ── */
.kmap { position: relative; width: 100%; margin: 12px 0 4px; container-type: inline-size; }
.kmap-in { position: absolute; inset: 0; transform-origin: 0 0; transition: transform .48s var(--ease); }
.kmap svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.kmap .rg { fill: var(--c); stroke: #fff; stroke-width: 1.3; stroke-linejoin: round; vector-effect: non-scaling-stroke; cursor: pointer; transition-property: fill-opacity, opacity; transition-duration: .3s; }
.kmap .rg.sel { fill: var(--d); fill-opacity: .6 !important; }
/* 지도 넘김: 처음엔 살짝 커지며 나타나고, 고르면 그곳으로 확대해 들어간다(나머지는 흐려짐). 뒤로 오면 반대로 */
.kmap.enter { animation: mapIn .55s var(--ease) both; }
@keyframes mapIn { from { opacity: 0; transform: scale(.94); } }
.kmap.zooming { pointer-events: none; }
.kmap.zooming .rg:not(.focus) { opacity: .12; }
.kmap .rg.focus { fill: var(--d); fill-opacity: .55 !important; }
.kmap .pin, .kmap .tag { transition-property: transform, opacity, background-color; transition-duration: .25s; transition-timing-function: ease-out; }
.kmap.zooming .pin, .kmap.zooming .tag { opacity: 0; }
.kmap.instant .kmap-in, .kmap.instant .rg, .kmap.instant .pin, .kmap.instant .tag { transition: none !important; }
/* 시·군·구 지도: 흰 칸 없이 글자만(이름 아래 기관 수). 지도 모양이 보이게 */
.kmap .tag { position: absolute; transform: translate(-50%, -50%); display: flex; flex-direction: column; align-items: center; padding: 1px 2px; border: 0; background: none; box-shadow: none; color: var(--ink); line-height: 1.12;
  text-shadow: 0 0 2px #fff, 0 0 3px #fff, 0 0 5px #fff, 0 0 7px #fff; }
.kmap .tag b { font-size: clamp(11px, 4.25cqw, 16px); font-weight: 800; white-space: nowrap; letter-spacing: -.3px; }
.kmap .tag small { font-size: clamp(10px, 3.8cqw, 14px); font-weight: 800; color: var(--d); font-variant-numeric: tabular-nums; }
.kmap .tag.zero small { color: var(--muted); }
.kmap .tag.sel b { color: var(--d); }
.kmap .tag:active { transform: translate(-50%, -50%) scale(.96); }
.credit { font-size: 14px; color: var(--muted); text-align: right; margin: 0; }
.pin { position: absolute; transform: translate(-50%, -50%); display: flex; align-items: baseline; gap: 4px; min-height: 30px; padding: 3px 9px; white-space: nowrap;
  border: 2px solid var(--c); border-radius: 999px; background: #fff; color: var(--ink); line-height: 1.2; box-shadow: 0 1px 2px rgb(0 0 0 / .08), 0 5px 10px -7px rgb(40 30 10 / .45);
  transition-property: transform, background-color; transition-duration: .15s; transition-timing-function: ease-out; }
.pin b { font-size: 15px; font-weight: 800; }
.pin small { font-size: 14px; font-weight: 800; color: var(--d); font-variant-numeric: tabular-nums; }
.pin.zero { border-color: var(--line); }
.pin.zero small { color: var(--muted); }
.pin.sel { background: var(--d); border-color: var(--d); color: #fff; }
.pin.sel small { color: #fff; }
/* 아주 작은 휴대폰: 이름표가 겹치지 않게 이름만(숫자는 아래 목록에) */
@container (max-width: 318px) { .pin { min-height: 26px; padding: 2px 8px; } .pin b { font-size: 14px; } .pin small { display: none; } }
.pin:active { transform: translate(-50%, -50%) scale(.96); }
.lastplace { display: grid; grid-template-columns: 1fr auto; align-items: center; column-gap: 10px; width: 100%; margin-top: 14px; padding: 12px 16px; text-align: left;
  border: 2px solid var(--c); border-radius: 20px; background: var(--t); color: var(--ink); transition-property: transform; transition-duration: .15s; }
.lastplace small { grid-column: 1; font-size: 16px; font-weight: 600; color: var(--muted); }
.lastplace b { grid-column: 1; font-size: 21px; }
.lastplace span { grid-column: 2; grid-row: 1 / span 2; font-size: 18px; font-weight: 800; color: var(--d); }
.lastplace:active { transform: scale(.96); }
/* 채소 페이지(r/)의 "지난번 내 결과"는 링크다 */
a.lastplace { text-decoration: none; }
/* 60세 전 결과: 부모님께 보내 드리기 */
.result .family .hint { margin-top: 18px; }

/* ── 우리 동네에서 찾기 ③: 기관 카드. 이름·모집하는 일·전화번호를 한눈에 ── */
.near-sum { font-size: 21px; margin: 4px 0 2px; }
.near-sum b { font-size: 26px; color: var(--d); font-variant-numeric: tabular-nums; }
.jt { font-weight: 700; }
.jt .warn { font-size: 14px; color: #8a4b00; font-weight: 700; }
.agency { display: block; margin-top: 14px; padding: 18px 18px 16px; border-radius: 24px; background: var(--card); box-shadow: var(--lift); }
.agency[hidden] { display: none; }
.agency h2 { font-size: 23px; line-height: 1.3; letter-spacing: -.3px; overflow-wrap: anywhere; }
.agency .jts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.agency .jt { display: inline-flex; align-items: center; gap: 6px; padding: 3px 4px 3px 10px; border-radius: 12px; background: #f6f1e7; font-size: 17px; }
.agency .sub { font-size: 17px; color: var(--muted); margin-top: 8px; overflow-wrap: anywhere; }
a.dial { display: flex; align-items: center; gap: 10px; min-height: 60px; margin-top: 12px; padding: 10px 18px; border-radius: 18px; background: var(--d); color: #fff; text-decoration: none;
  transition-property: transform, filter; transition-duration: .15s; transition-timing-function: ease-out; }
a.dial svg { flex: none; width: 26px; height: 26px; fill: currentColor; }
a.dial .num { flex: 1; font-size: 24px; font-weight: 800; letter-spacing: .2px; font-variant-numeric: tabular-nums; white-space: nowrap; }
a.dial .txt { display: flex; flex-direction: column; min-width: 0; line-height: 1.2; }
a.dial .go { flex: none; font-size: 17px; font-weight: 700; opacity: .95; }
a.dial:active { transform: scale(.96); filter: brightness(.94); }
.orgs + .ghost { margin-top: 14px; }
.away ul { list-style: none; padding: 0; }
.away li { padding: 8px 0; border-top: 1px solid #eee7da; }
.away li:first-child { border-top: 0; }
.away li small { display: block; font-size: 17px; color: var(--muted); margin-top: 2px; }

/* ── '동작 줄이기'를 켠 기기: 움직임을 빼고 바로 보여 준다 ── */
/* ── 안내 글(web/guide/, tools/build-guide.js) — 긴 글을 편하게 읽게: 줄 간격 넓게, 단락 사이 여유 ── */
.gbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; max-width: 640px; margin: 0 auto; padding: 12px 16px 0; }
.gbar a { color: var(--ink); text-decoration: none; font-weight: 700; }
.gbar .brand { display: flex; align-items: center; gap: 6px; font-size: 18px; white-space: nowrap; }
.gbar .brand img { width: 30px; height: auto; }
.gbar .gl { font-size: 17px; color: var(--d); padding: 8px 14px; border-radius: 30px; background: #fff; box-shadow: inset 0 0 0 2px var(--line); white-space: nowrap; }
main.doc { max-width: 640px; min-height: 0; padding-top: 8px; }
.doc .crumb { font-size: 17px; margin: 6px 0 2px; }
.doc .crumb a { color: var(--muted); }
.doc h1 { font-size: 31px; line-height: 1.3; letter-spacing: -.8px; margin: 12px 0 14px; }
.doc h2 { font-size: 25px; line-height: 1.35; letter-spacing: -.4px; margin: 38px 0 10px; }
.doc h3 { font-size: 22px; margin: 26px 0 6px; }
.doc p { line-height: 1.75; margin: 12px 0; }
.doc ul, .doc ol { padding-left: 1.3em; margin: 10px 0; line-height: 1.7; }
.doc li { margin: 6px 0; }
.doc li ul { margin: 4px 0; }
.doc a { color: var(--d); text-underline-offset: 3px; }
.doc strong { color: #1f1b24; }
.doc .tip { background: #FFF6DE; border-radius: 18px; padding: 4px 18px; margin: 18px 0; box-shadow: inset 5px 0 0 #E2B33C; }
.doc .tip p, .doc .tip ul { margin: 12px 0; }
.doc .tip p > strong:first-child { display: block; color: #8a5a00; margin-bottom: 2px; }
.doc .tbl { overflow-x: auto; margin: 14px 0; border-radius: 16px; box-shadow: var(--lift); background: #fff; }
.doc table { width: 100%; border-collapse: collapse; font-size: 18px; line-height: 1.5; }
.doc th, .doc td { padding: 11px 12px; text-align: left; vertical-align: top; border-bottom: 1px solid #efe7d8; }
.doc th { background: var(--t); color: var(--d); font-weight: 700; }
.doc tr:last-child td { border-bottom: 0; }
.doc td.num { white-space: nowrap; font-variant-numeric: tabular-nums; font-weight: 700; text-align: right; }
.doc .stat td b { font-weight: 700; margin-right: 4px; }
.doc .stat th:last-child { white-space: nowrap; text-align: right; }
/* 칸이 많은 표는 휴대폰에서 줄마다 카드처럼: 칸 이름(data-th)을 위에 작게 */
@media (max-width: 559px) {
  .doc .tbl.stack { overflow: visible; background: none; box-shadow: none; }
  .doc .tbl.stack table, .doc .tbl.stack tbody, .doc .tbl.stack tr, .doc .tbl.stack td { display: block; width: 100%; }
  .doc .tbl.stack thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .doc .tbl.stack tr { background: #fff; border-radius: 18px; box-shadow: var(--lift); margin: 0 0 12px; padding: 6px 4px; }
  .doc .tbl.stack td { border-bottom: 1px solid #f1eadc; padding: 8px 12px; }
  .doc .tbl.stack td:first-child { font-size: 20px; font-weight: 700; color: var(--d); }
  .doc .tbl.stack td:not(:first-child)::before { content: attr(data-th); display: block; font-size: 15px; font-weight: 700; color: var(--muted); }
  .doc .tbl.stack tr td:last-child { border-bottom: 0; }
}
.ghero { position: relative; text-align: center; margin: 4px 0 6px; }
.ghero img { position: relative; display: block; margin: 0 auto; width: 52%; max-width: 230px; height: auto; }
.ghero::before { content: ''; position: absolute; left: 50%; top: 46%; width: 70%; max-width: 320px; aspect-ratio: 1; border-radius: 50%; transform: translate(-50%, -50%);
  background: radial-gradient(closest-side, rgb(255 255 255 / .95), rgb(255 255 255 / 0)); }
.ghero .grp { position: relative; display: inline-block; font-size: 17px; font-weight: 700; color: var(--d); background: var(--t); border-radius: 20px; padding: 3px 14px; margin: 0; }
.doc .stat { margin-top: 34px; }
.doc .stat h2 { margin-top: 0; }
.doc .stat .tbl { box-shadow: none; border: 1px solid #efe7d8; }
.doc .cta { margin-top: 40px; padding: 22px 20px; border-radius: 24px; background: var(--t); text-align: center; }
.doc .cta p { margin: 0; }
.doc .cta .primary { text-decoration: none; margin-top: 14px; }
.doc .cta .meta { font-size: 18px; color: var(--muted); margin-top: 8px; }
.doc .more ul, .hublist { list-style: none; padding: 0; margin: 8px 0; }
.doc .more li, .hublist li { margin: 0; border-bottom: 1px solid #e9e0cf; }
.doc .more a, .hublist a { display: block; padding: 14px 4px; font-weight: 700; text-decoration: none; color: var(--ink); }
.vgrid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; margin-top: 12px; }
@media (min-width: 560px) { .vgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.vlink { display: flex; align-items: center; gap: 8px; min-height: 64px; padding: 8px 10px; border-radius: 18px; background: #fff; box-shadow: var(--lift); text-decoration: none; color: var(--ink); }
.vlink img { flex: none; width: 50px; height: auto; }
.vlink span { min-width: 0; }
.vlink b { display: block; font-size: 18px; line-height: 1.3; }
.vlink small { display: block; font-size: 15px; color: var(--muted); line-height: 1.3; }
.gfoot { max-width: 640px; margin: 0 auto; padding: 26px 16px 48px; border-top: 1px solid #e3d9c5; font-size: 17px; line-height: 1.65; color: var(--muted); }
.gfoot p { margin: 0 0 8px; }
.gfoot a { color: var(--muted); }
/* 검사 화면 아래 링크(안내 글·사이트 소개·개인정보처리방침) */
.links { margin-top: 26px; font-size: 17px; color: var(--muted); text-align: center; line-height: 1.8; }
.links a { color: var(--muted); }
.more-link { display: inline-block; margin-top: 10px; font-size: 19px; font-weight: 700; color: var(--d); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important; animation-delay: 0ms !important; animation-iteration-count: 1 !important;
    transition-duration: .01ms !important; transition-delay: 0ms !important;
  }
  .rv { opacity: 1; transform: none; }
  .st, .rv, .choice .radio svg { filter: none !important; }
}

/* ── 첫 화면 아래 안내 (index.html 의 data-home, tools/build-web-data.js) ── */
/* 숨김(hidden)이 .gbar 의 display:flex 에 덮이지 않게 */
[data-home][hidden] { display: none !important; }
.home-bar { max-width: 540px; }
/* 표지에서는 아래 안내가 시작 버튼 바로 밑에 이어지게 */
body.at-cover main { min-height: 0; padding-bottom: 8px; }
.home-more { max-width: 540px; margin: 0 auto; padding: 4px 16px 20px; }
.home-more h2 { font-size: 25px; line-height: 1.35; letter-spacing: -.4px; margin: 34px 0 8px; }
.home-more > p, .home-fold > p { line-height: 1.7; margin: 8px 0; }
.home-more .hl { margin-top: 12px; line-height: 2; }
.vlist, .tlist { list-style: none; padding: 0; margin: 14px 0 0; display: grid; gap: 10px; }
.vlist a { display: flex; align-items: center; gap: 14px; min-height: 76px; padding: 10px 16px; background: var(--card); border-radius: 20px; box-shadow: var(--lift); color: var(--ink); text-decoration: none;
  transition: transform .15s ease-out; }
.vlist a:active { transform: scale(.98); }
.vlist img { width: 52px; height: auto; flex: none; }
.vlist b { display: block; font-size: 21px; }
.vlist small { display: block; font-size: 17px; line-height: 1.45; color: var(--muted); }
.tlist li { background: var(--card); border-radius: 20px; box-shadow: var(--lift); padding: 14px 18px; }
.tlist b { display: block; font-size: 21px; color: #2C7446; }
.tlist span { display: block; font-size: 19px; line-height: 1.6; margin-top: 2px; }
.steps { margin: 12px 0 0; padding-left: 1.4em; line-height: 1.7; }
.steps li { margin: 8px 0; }

/* 결과 화면 다듬기(2026-10-19): 일 이름 아래로 유형 표시, 신청 전 확인은 접어 두기, 그릇이 비었을 땐 한 줄 안내 */
/* 나에게 잘 맞는 일: 채소 무리 색 바탕 위에 흰 카드(이름 한 줄 + 유형 한 줄). 위 "이런 분이에요"(흰 상자)와 구분 */
.jobbox { background: var(--t); box-shadow: inset 0 0 0 2px var(--c); padding: 18px 14px 16px; }
.jobbox h2 { color: var(--d); padding: 0 4px; }
.jobbox .jobs { list-style: none; padding: 0; margin: 6px 0 0; display: grid; gap: 8px; }
.jobbox .job { margin: 0; background: #fff; border-radius: 16px; padding: 12px 14px; box-shadow: 0 1px 2px rgb(0 0 0 / .06); }
.jobbox .job b { display: block; font-size: 21px; line-height: 1.4; }
.jobbox .job .jm { display: block; font-size: 17px; font-weight: 700; color: var(--d); margin-top: 1px; }
.jobbox .job .jm .warn { color: #8a4b00; }
.jobbox .job small { margin-top: 1px; font-size: 17px; }
.jobbox .note, .jobbox .more-link { margin-left: 4px; margin-right: 4px; }
.fold summary { list-style: none; cursor: pointer; }
.fold summary::-webkit-details-marker { display: none; }
.fold summary { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 48px; }
.fold summary h2 { margin: 0; }
.fold summary .sum { display: block; font-size: 19px; line-height: 1.6; }
.fold .open { flex: none; display: inline-flex; align-items: center; min-height: 48px; padding: 0 18px; border-radius: 30px; background: #fff; box-shadow: inset 0 0 0 2px #E8C46A; font-size: 18px; font-weight: 700; color: #7a5200; }
.fold .open::after { content: ' ▾'; }
.fold[open] .open::after { content: ' ▴'; }
.fold ul { margin-top: 12px; }
.share-hint { font-size: 19px; color: var(--muted); text-align: center; margin: 26px 4px 0; line-height: 1.6; }
/* 잘 어울리는 채소: 그림 + 두 줄짜리 작은 상자 */
.partner { padding-top: 12px; padding-bottom: 12px; }
.partner .mini img { width: 56px; }
.result .partner p small { display: block; font-size: 17px; color: var(--muted); }
.result .partner p b { font-size: 21px; }
/* 동네 기관 카드(2026-10-19): 맞는 일은 한 줄 글로, 건수·인원은 짧게 */
.agency { padding: 16px 18px 14px; }
.agency .jl { font-size: 18px; line-height: 1.5; color: #4a4450; margin-top: 6px; }
.agency .jl > span:not(.warn) { white-space: nowrap; } /* 일 이름 중간에서 줄이 안 바뀌게 */
.agency .jl .warn { color: #8a4b00; font-size: 16px; }
.agency .sub { margin-top: 4px; }
.near-sum { margin-bottom: 4px; }
/* 전화 버튼: 전화 그림 + 번호를 가운데로. 11자리 번호도 좁은 폰(320px)에서 한 줄에 들어가게 글자 크기가 조금 줄어든다 */
a.dial { justify-content: center; padding: 10px 14px; }
a.dial .num { flex: none; font-size: clamp(20px, 6.4vw, 24px); }

/* ── 지역별 기관 페이지 (web/area/, tools/build-area.js) ── */
.area .doc .crumb span { color: var(--ink); }
.area .area-sub { margin: -6px 0 6px; font-size: 18px; color: var(--muted); }
.area .lead { font-size: 20px; line-height: 1.75; }
.area .lead b { color: var(--d); }
.jobrows, .arealist { list-style: none; padding: 0 !important; margin: 12px 0 0; display: grid; gap: 8px; }
.jobrows li, .arealist li { margin: 0; background: var(--card); border-radius: 16px; box-shadow: var(--lift); }
.jobrows li { padding: 12px 16px; }
.jobrows b { display: block; font-size: 20px; line-height: 1.4; }
.jobrows b a { color: var(--ink); }
.jobrows span { display: block; font-size: 17px; color: var(--muted); }
.arealist a { display: block; padding: 14px 16px; min-height: 56px; color: var(--ink); text-decoration: none; }
.arealist b { display: block; font-size: 21px; }
.arealist span { display: block; font-size: 17px; color: var(--muted); }
.arealist a:active { transform: scale(.98); }
.area .orgs .agency h3 { font-size: 22px; line-height: 1.3; letter-spacing: -.3px; margin: 0; overflow-wrap: anywhere; }
.area .doc .agency p { margin: 0; }
.area .doc .agency .jl { margin-top: 6px; }
.area .doc .agency .sub { margin-top: 4px; }
.area .doc a.dial { color: #fff; text-decoration: none; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips a { display: inline-flex; align-items: center; min-height: 48px; padding: 0 16px; border-radius: 30px; background: #fff; box-shadow: inset 0 0 0 2px var(--line); color: var(--ink); text-decoration: none; font-size: 18px; font-weight: 700; }
/* 광고 자리: 지금은 비어 있어서 보이지 않는다(광고 코드를 넣으면 생긴다). 전화 버튼과 떨어진 곳에만 둔다 */
.ad-slot:empty { display: none; }
.ad-slot { margin: 28px 0; }
/* 안내 글·지역 페이지의 큰 버튼: .doc a 의 글자색(초록)이 버튼 바탕과 같아 글자가 안 보이던 것 고침(2026-10-19) */
.doc a.primary { color: #fff; }
.morejobs { margin-top: 8px; }
.morejobs summary { display: flex; align-items: center; justify-content: center; min-height: 52px; border-radius: 30px; background: #fff; box-shadow: inset 0 0 0 2px var(--line); font-size: 18px; font-weight: 700; cursor: pointer; list-style: none; }
.morejobs summary::-webkit-details-marker { display: none; }
.morejobs[open] summary { display: none; }

/* ── 동네 기관 지도(카카오맵, web/app.js nearMap) ── */
.nmap-wrap { margin-top: 12px; }
.nmap-wrap[hidden] { display: none; }
.nmap { height: 300px; border-radius: 20px; overflow: hidden; box-shadow: var(--lift); background: #eae4d6; }
.locbtn { margin-top: 10px; }
.locbtn:disabled { opacity: .6; }
.loc-msg { font-size: 18px; color: var(--d); font-weight: 700; margin-top: 8px; }
.mpin { min-width: 36px; height: 36px; padding: 0 6px; border: 3px solid #fff; border-radius: 18px; background: var(--d); color: #fff; font-size: 18px; font-weight: 800; box-shadow: 0 2px 6px rgb(0 0 0 / .35); cursor: pointer; }
.mepin { padding: 4px 10px; border-radius: 14px; background: #1f6fd1; color: #fff; font-size: 15px; font-weight: 800; border: 2px solid #fff; box-shadow: 0 2px 6px rgb(0 0 0 / .35); white-space: nowrap; }
.agency .pin-no { display: inline-grid; place-items: center; min-width: 30px; height: 30px; margin-right: 8px; padding: 0 6px; border-radius: 15px; background: var(--d); color: #fff; font-size: 17px; font-weight: 800; vertical-align: 3px; }
.agency .dist { display: inline-block; margin-left: 8px; font-size: 17px; font-weight: 800; color: var(--d); white-space: nowrap; }
.agency .dist[hidden] { display: none; }
.agency .addr { font-size: 17px; color: var(--muted); margin-top: 4px; }
.agency.hl { box-shadow: 0 0 0 3px var(--c), var(--lift); }
/* 지도 핀을 작게(2026-10-19) */
.mpin { min-width: 26px; height: 26px; padding: 0 4px; border-width: 2px; border-radius: 13px; font-size: 14px; box-shadow: 0 1px 4px rgb(0 0 0 / .35); }
.mepin { padding: 3px 8px; font-size: 13px; border-radius: 12px; }
/* 문항 화면: 한 화면의 답 버튼 높이를 같게(한쪽만 두 줄이어도 나란히 보이게, 2026-10-19) */
.choices { grid-auto-rows: 1fr; }
/* 친구가 받은 결과(r/): "나도 해 보기"를 채소 소개 바로 아래에(2026-10-20) */
.go-top { margin-top: 18px; }
.go-top .meta { margin-top: 8px; }
/* 바닥 링크는 링크 중간에서 줄이 바뀌지 않게 */
.links a { white-space: nowrap; }
/* 좁은 휴대폰(360px 안팎): 상자 안쪽 여백을 줄여 한 줄 문구가 두 줄로 넘어가지 않게 */
@media (max-width: 374px) { .box { padding-left: 16px; padding-right: 14px; } }
/* 지역 페이지 숫자 상자(2026-10-20): 기관·공고·모집 인원을 한눈에 */
.stats { list-style: none; padding: 0 !important; margin: 10px 0 12px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.stats li { margin: 0; padding: 10px 4px; border-radius: 16px; background: var(--card); box-shadow: var(--lift); text-align: center; }
.stats b { display: block; font-size: clamp(19px, 5.6vw, 23px); font-weight: 800; color: var(--d); white-space: nowrap; font-variant-numeric: tabular-nums; }
.stats span { display: block; font-size: 16px; color: var(--muted); }
/* 전화번호가 없는 기관: 노인일자리여기로 가는 흰 버튼 */
a.dial.ghost-dial { background: #fff; color: var(--d); box-shadow: inset 0 0 0 2px var(--d); font-size: 19px; font-weight: 700; }
.area h1 .place { display: block; }
/* 지역 페이지 그림(2026-10-21): 숫자 상자 그림, 모집한 일 왼쪽에 어울리는 채소 */
.stats svg { display: block; width: 26px; height: 26px; margin: 0 auto 2px; fill: none; stroke: var(--d); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.jobrows li { display: flex; align-items: center; gap: 12px; }
.jobrows .vi { flex: none; display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; background: #f6f1e7; overflow: hidden; }
.jobrows .vi img { width: 42px; height: 46px; object-fit: contain; }
.jobrows .jt { min-width: 0; }
.area .area-sub + .stats { margin-top: 12px; }
.jobrows .vi.ic svg { width: 26px; height: 26px; fill: none; stroke: var(--d); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
/* 그림이 들어가 글 칸이 좁아진 만큼 그림·여백을 조금 줄여 긴 일 이름도 한 줄에 */
.area .jobrows li { padding: 10px 14px 10px 10px; gap: 10px; }
.area .jobrows .vi { width: 46px; height: 46px; }
.area .jobrows .vi img { width: 38px; height: 42px; }
.area .jobrows b { font-size: 19px; letter-spacing: -.3px; white-space: nowrap; }
@media (max-width: 340px) { .area .jobrows .jt > span, .area .arealist span { font-size: 15px; } }

/* ── 결과 화면 다시 짬(2026-10-26): 채소 → 맞는 일 → 동네 찾기 → 보내기, 나머지는 접기 ── */
.near-wrap .meta, .result .primary + .meta { margin-top: 8px; }
/* 결과 채소 그림을 조금 줄여 맞는 일·동네 찾기 버튼이 첫 화면에 더 들어오게 */
.result .hero-pic .pic img { width: 52%; max-width: 200px; }
.result .jobbox { margin-top: 14px; }
.result .share-hint { margin-top: 10px; }
.result a.primary { color: #fff; }
/* "이런 분이에요"는 접어 두고, 어울리는 채소는 그 안에 한 줄로 */
.fold.about .open { box-shadow: inset 0 0 0 2px var(--line); color: var(--d); }
.partner-line { display: flex; align-items: center; gap: 12px; margin-top: 14px !important; padding-top: 12px; border-top: 1px solid #efe7d8; }
.partner-line .mini img { display: block; width: 52px; height: auto; }
.partner-line small { display: block; font-size: 17px; color: var(--muted); }
.partner-line b { font-size: 21px; }
/* 아래 고정 버튼 줄: 본문의 동네 찾기 버튼이 위로 지나가면 나타난다(app.js stickyBar) */
.result-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; display: flex; gap: 10px; max-width: 540px; margin: 0 auto;
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: rgb(251 246 236 / .94); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  box-shadow: 0 -8px 20px -14px rgb(70 45 10 / .4); animation: barIn .3s var(--ease) both; }
.result-bar[hidden] { display: none; }
.result-bar .primary { margin-top: 0; min-height: 60px; font-size: 21px; }
.result-bar .primary:first-child { flex: 1 1 auto; }
.result-bar .share { flex: 0 0 auto; width: auto; padding: 0 22px; }
@keyframes barIn { from { opacity: 0; transform: translateY(12px); } }
body.has-bar main { padding-bottom: 110px; }

/* ── 첫 화면 시작 버튼 아래(2026-10-26): 버튼 3개만 보이고, 긴 안내는 접어 둔다(검색엔진은 접힌 글도 읽는다) ── */
.home-quick { list-style: none; padding: 0; margin: 10px 0 0; display: grid; gap: 10px; }
.home-quick a { display: flex; align-items: center; gap: 12px; min-height: 64px; padding: 8px 18px; border-radius: 20px; background: var(--card); box-shadow: var(--lift);
  color: var(--ink); text-decoration: none; font-size: 21px; font-weight: 700; transition: transform .15s ease-out; }
.home-quick a:active { transform: scale(.98); }
.home-quick img { width: 40px; height: auto; flex: none; }
.home-quick svg { width: 34px; height: 34px; flex: none; fill: none; stroke: var(--d); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.home-quick a::after { content: '→'; margin-left: auto; color: var(--d); font-weight: 800; }
.home-fold { margin-top: 18px; }
.home-fold summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 56px; padding: 6px 18px; border-radius: 20px; background: #fff; box-shadow: inset 0 0 0 2px var(--line); font-size: 19px; font-weight: 700; }
.home-fold summary::-webkit-details-marker { display: none; }
.home-fold summary::after { content: '▾'; color: var(--d); flex: none; }
.home-fold[open] summary::after { content: '▴'; }
.home-fold[open] summary { margin-bottom: 4px; }
.home-fold h2:first-of-type { margin-top: 20px; }
/* 안내·지역 페이지 위 줄: "← 처음으로" 와 오른쪽 버튼 */
.gbar .back-home { display: inline-flex; align-items: center; min-height: 48px; font-size: 18px; color: var(--muted); padding: 0 4px; }
