/* 화천 산천어축제 외국인 안전 안내 — 화면 모양 (Figma 확정 시안 3안)
   색은 경찰 제복 남색 위주. 금색은 휘장, 연두는 야광 조끼(현재 구역)에만.
   외부 글꼴 없음: 휴대폰 기본 글꼴을 씁니다. */
:root {
  --navy-900: #0a1e3f;
  --navy-700: #1f3b6e;
  --navy-050: #eaeff6;
  --gold: #b8932f;
  --vest: #d4f03a;
  --reflect: #c7cdd6;
  --red: #b3121f;
  --ink: #0f172a;
  --ink-2: #475569;
  --line: #c5cdd8;
  --page: #f3f5f8;
  --white: #ffffff;
  --r: 6px;
  --font: -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic",
    "Noto Sans", "Noto Sans Thai", "Noto Sans SC", "Noto Sans TC", "Noto Sans JP", "Segoe UI", Roboto, sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--navy-900); }
body {
  margin: 0; background: var(--page); color: var(--ink);
  font-family: var(--font); font-size: 16px; line-height: 1.5;
  word-break: keep-all; overflow-wrap: anywhere;
}
:lang(th), :lang(vi) { word-break: normal; }
:lang(ko) { word-break: keep-all; }
main { display: block; max-width: 560px; margin: 0 auto; }
img { display: block; }
a { color: inherit; }
button { font: inherit; color: inherit; }
.ico { width: 22px; height: 22px; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.ico--sm { width: 18px; height: 18px; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

/* ── 머리띠 ── */
.top { display: flex; align-items: center; gap: 12px; padding: 14px 16px; padding-top: calc(14px + env(safe-area-inset-top)); background: var(--navy-900); color: var(--white); }
.top__ci { width: 44px; height: 44px; flex: none; }
.top__org { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.top__name { font-size: 19px; font-weight: 700; line-height: 1.3; }
.top__en { font-size: 11px; letter-spacing: .03em; opacity: .75; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.langbtn {
  flex: none; display: flex; align-items: center; gap: 6px; min-height: 48px; padding: 0 10px 0 12px;
  background: transparent; color: var(--white); border: 1.5px solid var(--white); border-radius: 4px;
  font-size: 16px; font-weight: 500; cursor: pointer;
}
.langbtn .ico { width: 20px; height: 20px; }
.goldline { height: 3px; background: var(--gold); flex: none; }
.official { display: flex; align-items: center; gap: 8px; margin: 0; padding: 10px 16px; background: var(--navy-050); color: var(--navy-900); font-size: 14px; font-weight: 500; line-height: 1.4; }
.official .ico { width: 18px; height: 18px; color: var(--navy-700); }

/* ── 현재 구역 (야광 조끼) ── */
.zone { display: flex; align-items: center; gap: 12px; padding: 14px 16px; background: var(--vest); color: var(--navy-900); border-top: 6px solid var(--reflect); border-bottom: 6px solid var(--reflect); }
.zone[hidden] { display: none; }
.zone__ico { width: 36px; height: 36px; flex: none; fill: none; stroke: currentColor; stroke-width: 2; }
.zone__label { font-size: 14px; font-weight: 500; }
.zone__name { font-size: 40px; font-weight: 900; line-height: 1.1; letter-spacing: -.02em; }

/* ── 인사 ── */
.hello { background: var(--white); padding: 22px 16px 16px 20px; }
.hello h1 { margin: 0 0 4px; font-size: 26px; line-height: 1.3; }
.hello__row { display: flex; align-items: flex-end; gap: 8px; }
.hello__row p { flex: 1; margin: 0; color: var(--ink-2); }
.hello__chars { display: flex; align-items: flex-end; flex: none; }
.char--san { width: 84px; height: auto; }
.char--su { width: 62px; height: auto; }

/* ── 구역 묶음 ── */
.block { padding: 28px 20px; background: var(--white); }
.block--grey { background: var(--page); }
.block--tight { padding-top: 8px; }
.block > h2 { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin: 0 0 12px; font-size: 21px; line-height: 1.35; }
.block > h2::before { content: ""; width: 4px; height: 22px; background: var(--navy-900); }
.lead { margin: -6px 0 8px; color: var(--ink-2); }
.tag { display: inline-block; padding: 1px 6px; border: 1px dashed var(--ink-2); border-radius: 2px; color: var(--ink-2); font-size: 13px; font-weight: 500; line-height: 1.4; }
body:not(.is-draft) .draft-only { display: none !important; }

/* ── 긴급 버튼 ── */
.btn { display: flex; flex-direction: column; gap: 12px; padding: 18px 20px; margin-bottom: 12px; border-radius: var(--r); text-decoration: none; }
.btn__row { display: flex; align-items: center; gap: 12px; }
.btn__ico { width: 36px; height: 36px; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.btn__num { font-size: 56px; font-weight: 900; line-height: 1; letter-spacing: -.02em; }
.btn__num--md { font-size: 40px; }
.btn__name { display: flex; flex-direction: column; line-height: 1.35; }
.btn__name b { font-size: 19px; }
.btn__name small { font-size: 16px; font-weight: 400; }
.btn__note { display: flex; gap: 10px; padding-top: 12px; border-top: 1px solid rgba(255,255,255,.25); font-weight: 500; }
.btn--112 { background: var(--navy-900); color: var(--white); }
.btn--112 .btn__ico, .btn--112 .btn__note .ico { color: var(--vest); }
.btn--sms { background: var(--white); color: var(--navy-900); border: 2px solid var(--navy-900); }
.btn--sms .btn__name small { color: var(--ink-2); }
.btn__text { color: var(--ink); }
.btn__preview { display: flex; flex-direction: column; gap: 4px; padding: 10px 12px; background: var(--navy-050); border-radius: 4px; font-weight: 500; }
.btn__preview small { color: var(--ink-2); font-size: 14px; }
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.pair .btn { margin: 0; padding: 16px; gap: 4px; }
.pair .btn__row { gap: 8px; }
.pair .ico { width: 24px; height: 24px; }
.btn__small { font-weight: 500; line-height: 1.4; }
.btn--119 { background: var(--red); color: var(--white); }
.btn--1330 { background: var(--white); color: var(--navy-900); border: 2px solid var(--line); }

/* ── 목록 ── */
.list { list-style: none; margin: 0; padding: 0; }
.row {
  display: flex; align-items: center; gap: 14px; width: 100%; min-height: 64px; padding: 16px 4px;
  background: none; border: 0; border-bottom: 1px solid var(--line); text-align: left; cursor: pointer;
}
.row__ico svg { display: block; width: 28px; height: 28px; fill: none; stroke: var(--navy-700); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.row__ico img { width: 28px; height: 28px; }
.row__text { flex: 1; display: flex; flex-direction: column; font-size: 19px; font-weight: 700; line-height: 1.35; }
.row__ko { font-size: 14px; font-weight: 500; color: var(--ink-2); }
.row__chev { width: 24px; height: 24px; flex: none; fill: none; stroke: var(--ink-2); stroke-width: 2; }
.list--info .row { align-items: flex-start; cursor: default; }
.row__name { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.row__where { font-size: 16px; font-weight: 400; color: var(--ink-2); }

/* ── 경찰 정책홍보 포스터 (10초마다 넘김) ── */
.posters { margin: 0 -20px; }
.posters__track { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 20px 8px; scroll-padding: 0 20px; scrollbar-width: none; overscroll-behavior-x: contain; }
.posters__track::-webkit-scrollbar { display: none; }
.poster { flex: 0 0 78%; max-width: 340px; scroll-snap-align: center; margin: 0; }
.poster img { width: 100%; height: auto; aspect-ratio: 1 / 1.414; object-fit: cover; background: var(--navy-050); border: 1px solid var(--line); }
.posters__nav { display: flex; align-items: center; justify-content: center; gap: 4px; padding: 4px 20px 0; }
.posters__dots { display: flex; gap: 2px; margin: 0 4px; }
.posters__dots button { width: 32px; height: 44px; padding: 0; background: none; border: 0; cursor: pointer; display: grid; place-items: center; }
.posters__dots button::after { content: ""; width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--navy-900); }
.posters__dots button[aria-current="true"]::after { width: 24px; border-radius: 5px; background: var(--navy-900); }
.video { margin: 20px 0 0; }
.video__cap { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 17px; color: var(--navy-900); margin: 0 0 10px; }
.video__frame { position: relative; background: var(--navy-900); border-radius: 4px; overflow: hidden; aspect-ratio: 16 / 9; }
.video__frame video { display: block; width: 100%; height: 100%; object-fit: contain; background: var(--navy-900); }
.video__bar { display: flex; justify-content: space-between; gap: 8px; margin-top: 10px; }
.vbtn { display: inline-flex; align-items: center; gap: 6px; min-width: 44px; height: 44px; padding: 0 14px; justify-content: center; background: var(--white); color: var(--navy-900); border: 1.5px solid var(--line); border-radius: 4px; font: inherit; font-size: 15px; font-weight: 700; cursor: pointer; }
.vbtn--sound[aria-pressed="true"] { background: var(--navy-900); color: var(--white); border-color: var(--navy-900); }
.pbtn { display: grid; place-items: center; width: 44px; height: 44px; background: var(--white); border: 1.5px solid var(--line); border-radius: 4px; color: var(--navy-900); cursor: pointer; }

/* ── 배치도 카드 ── */
.mapcard {
  display: flex; flex-direction: column; align-items: center; gap: 8px; width: 100%; padding: 20px 16px;
  background: var(--white); border: 1.5px dashed var(--line); border-radius: 4px; cursor: pointer; text-align: center;
}
.mapcard__thumb { width: 100%; max-height: 140px; overflow: hidden; display: block; }
.mapcard__thumb:empty { display: none; }
.mapcard__thumb img { width: 100%; height: 140px; object-fit: cover; }
.mapcard__title { font-weight: 500; color: var(--ink-2); }
.mapcard__hint { font-size: 14px; color: var(--ink-2); }
.mapcard__btn { display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 16px; background: var(--navy-900); color: var(--white); border-radius: 4px; font-size: 19px; font-weight: 700; }
.mapcard__btn .ico { width: 20px; height: 20px; }

/* ── 홍보 · SNS ── */
.promo { margin: 0 0 14px; }
.sub { margin: 0 0 8px; font-size: 14px; color: var(--ink-2); }
.sns { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 14px; }
.sns a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; min-height: 72px; border: 1.5px solid var(--line); border-radius: 4px; color: var(--navy-900); font-size: 14px; font-weight: 500; text-decoration: none; text-align: center; }
.sns .ico { width: 26px; height: 26px; }
.homelink { display: flex; align-items: center; gap: 12px; padding: 12px 16px; background: var(--navy-050); border-radius: 4px; color: var(--navy-900); text-decoration: none; }
.homelink img { width: 32px; height: 32px; flex: none; }
.homelink span { flex: 1; display: flex; flex-direction: column; line-height: 1.35; }
.homelink b { font-size: 19px; }
.homelink small { font-size: 14px; color: var(--ink-2); }

/* ── 안심 문구 ── */
.safe { display: flex; gap: 12px; padding: 16px; background: var(--navy-050); border-left: 5px solid var(--navy-900); }
.safe__ico { width: 32px; height: 32px; flex: none; fill: none; stroke: var(--navy-900); stroke-width: 2; }
.safe h2 { margin: 0 0 4px; font-size: 19px; color: var(--navy-900); }
.safe p { margin: 0; font-weight: 500; }
.safe .safe__check { margin-top: 4px; font-size: 14px; color: var(--ink-2); }

/* ── 하단 ── */
.foot { padding: 22px 20px calc(28px + env(safe-area-inset-bottom)); background: var(--navy-900); color: var(--white); }
.foot p { margin: 0 0 10px; }
.foot__org { display: flex; align-items: center; gap: 10px; font-size: 19px; font-weight: 700; white-space: pre; }
.foot__org img { width: 36px; height: 36px; }
.foot a { color: var(--white); text-underline-offset: 3px; }
.visits { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 16px; padding: 10px 0; margin: 4px 0 12px !important; border-top: 1px solid rgba(255,255,255,.2); border-bottom: 1px solid rgba(255,255,255,.2); font-size: 14px; }
.visits b { font-size: 13px; letter-spacing: .08em; opacity: .8; margin-right: 2px; }
.visits strong { font-size: 17px; font-variant-numeric: tabular-nums; margin-left: 2px; }
.tag--dark { border-color: rgba(255,255,255,.7); color: var(--white); }
.foot__small { font-size: 14px; opacity: .7; margin: 0 !important; }

/* ── 위 막대 (보여주기·배치도) ── */
.bar { display: flex; align-items: center; gap: 12px; padding: 10px 16px 10px 12px; padding-top: calc(10px + env(safe-area-inset-top)); background: var(--navy-900); color: var(--white); flex: none; }
.barbtn { display: flex; align-items: center; gap: 8px; min-height: 52px; padding: 0 16px 0 12px; background: transparent; color: var(--white); border: 1.5px solid var(--white); border-radius: 4px; font-size: 19px; font-weight: 700; cursor: pointer; }
.barbtn small { font-size: 16px; font-weight: 400; }
.bar__title { font-size: 21px; font-weight: 700; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; background: var(--vest); color: var(--navy-900); border-radius: 4px; font-size: 19px; font-weight: 700; }
.chip[hidden] { display: none; }
.chip .ico { width: 20px; height: 20px; }
.bar .chip { margin-left: auto; }

/* ── 보여주기 화면 ── */
.show, .mapview { position: fixed; inset: 0; z-index: 20; display: flex; flex-direction: column; }
.show[hidden], .mapview[hidden], .sheet-wrap[hidden] { display: none; }
.show { background: var(--white); }
.show__body { flex: 1; overflow-y: auto; padding: 28px 24px 16px; display: flex; flex-direction: column; gap: 20px; }
.show__badge { align-self: flex-start; padding: 4px 10px; background: var(--navy-050); color: var(--navy-900); border-radius: 2px; font-size: 14px; font-weight: 500; }
.show__ko { margin: 0; font-size: clamp(34px, 11vw, 48px); font-weight: 900; line-height: 1.25; letter-spacing: -.02em; }
.show__please { margin: -8px 0 0; font-size: 26px; font-weight: 700; }
.show__info { margin: 0; padding: 14px 16px; background: var(--page); border-left: 5px solid var(--navy-900); display: flex; flex-direction: column; gap: 8px; }
.show__info div { display: flex; gap: 12px; }
.show__info dt { width: 72px; flex: none; color: var(--ink-2); }
.show__info dd { margin: 0; font-size: 19px; font-weight: 700; line-height: 1.35; }
.show__orig { padding-top: 20px; border-top: 1px solid var(--line); }
.show__orig[hidden] { display: none; }
.show__orig small { color: var(--ink-2); font-size: 14px; }
.show__orig p { margin: 4px 0 0; font-size: 20px; font-weight: 700; }
.show__orig .show__hint { font-size: 16px; font-weight: 400; color: var(--ink-2); }
.show__foot { padding: 12px 24px calc(20px + env(safe-area-inset-bottom)); }
.btn--slim { margin: 0; padding: 14px 20px; }
.btn--slim .btn__row { justify-content: center; }
.btn--slim b { font-size: 19px; }
.btn--slim .btn__ico { width: 28px; height: 28px; }

/* ── 배치도 크게 보기 ── */
.mapview { background: var(--ink); }
.mapview__area { flex: 1; overflow: auto; background: var(--white); }
.mapview__area img { width: 100%; height: auto; }
.mapview__foot { flex: none; padding: 12px 16px calc(20px + env(safe-area-inset-bottom)); background: var(--navy-900); color: var(--white); }
.mapview__foot p { margin: 6px 0 0; }
.grid { padding: 8px 10px 16px; }
.grid__note { display: inline-block; margin-bottom: 8px; }
.grid__cells { display: grid; grid-template-columns: repeat(var(--cols), minmax(0, 1fr)); }
.cell { min-width: 0; height: 78px; overflow: hidden; border: 1px solid var(--line); margin: 0 -1px -1px 0; padding: 4px 6px; font-size: 14px; color: var(--ink-2); display: flex; flex-direction: column; align-items: center; }
.cell > span { align-self: flex-start; line-height: 1.3; }
.cell svg { width: 22px; height: 22px; fill: none; stroke: var(--navy-900); stroke-width: 2; margin-top: 2px; }
.cell img { width: 22px; height: 22px; margin-top: 2px; }
.cell em { font-style: normal; font-size: 11px; max-width: 100%; font-weight: 500; color: var(--navy-900); text-align: center; line-height: 1.2; }
.cell--here { position: relative; background: var(--vest); outline: 3px solid var(--navy-900); outline-offset: -3px; color: var(--navy-900); z-index: 1; }
.cell--here em { font-weight: 700; }

/* ── 언어 선택 ── */
.sheet-wrap { position: fixed; inset: 0; z-index: 30; }
.sheet-dim { position: absolute; inset: 0; background: var(--navy-900); opacity: .6; }
.sheet { position: absolute; left: 0; right: 0; bottom: 0; max-width: 560px; margin: 0 auto; max-height: 90vh; overflow-y: auto; padding: 20px 20px calc(28px + env(safe-area-inset-bottom)); background: var(--white); border-radius: 12px 12px 0 0; }
.sheet__head { display: flex; align-items: center; gap: 8px; padding-bottom: 8px; }
.sheet__head > .ico { width: 24px; height: 24px; color: var(--navy-900); }
.sheet__head h2 { flex: 1; margin: 0; font-size: 21px; }
.sheet__x { display: grid; place-items: center; width: 48px; height: 48px; background: none; border: 1.5px solid var(--line); border-radius: 4px; cursor: pointer; }
.sheet__list button { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 60px; padding: 0 16px; background: none; border: 0; border-bottom: 1px solid var(--line); font-size: 19px; font-weight: 700; text-align: left; cursor: pointer; }
.sheet__list button[aria-current="true"] { background: var(--navy-050); border: 2px solid var(--navy-900); border-radius: 4px; }
.sheet__list button span { flex: 1; }
.sheet__list .ico { color: var(--navy-900); }
.sheet__note { margin: 8px 0 0; font-size: 14px; color: var(--ink-2); }

/* 넓은 화면(태블릿·PC)에서는 가운데 한 줄로 */
@media (min-width: 600px) {
  body { background: var(--navy-900); }
  .top, .official, .zone, .foot, body > .goldline { max-width: 560px; margin-left: auto; margin-right: auto; }
  main { background: var(--page); }
}
@media (prefers-reduced-motion: no-preference) {
  .btn, .row, .sns a, .mapcard { transition: transform .08s ease; }
  .btn:active, .row:active, .sns a:active, .mapcard:active { transform: scale(.985); }
}
