:root {
  --ink: #15171a;
  --ink-2: #3b3f45;
  --muted: #7b8088;
  --line: #ebe8e2;
  --card: #ffffff;
  --glass: rgba(255, 255, 255, .86);
  --soft: #f3f2ef;
  --mint: #dcf6fb;      /* 플로팅 버튼 */
  --mint-ink: #0f3f4a;
  --lime: #8ee36f;      /* 메인 CTA */
  --lime-ink: #10240a;
  --route: #1f8f3a;
  --me: #2f7bff;
  --warm: #fff6e0;
  --shadow: 0 6px 24px rgba(20, 24, 30, .14);
  --shadow-sm: 0 2px 10px rgba(20, 24, 30, .12);
  --dock-h: 170px;
  --safe-b: env(safe-area-inset-bottom);
  --safe-t: env(safe-area-inset-top);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }
html, body { margin: 0; height: 100%; }
body {
  font-family: "Pretendard", -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", "Segoe UI", sans-serif;
  background: #f4f1ea; color: var(--ink); overflow: hidden;
  -webkit-font-smoothing: antialiased;
}
button { font: inherit; cursor: pointer; color: inherit; }
svg { display: block; }
[data-icon] svg { width: 100%; height: 100%; }

/* ---------------- 지도 ---------------- */
#map { position: fixed; inset: 0; background: #eae6dd; }
.leaflet-container { font-family: inherit; }
.tiles-soft { filter: saturate(.5) brightness(1.05) contrast(.9) hue-rotate(-6deg); }
.leaflet-control-attribution { font-size: 10px; background: rgba(255,255,255,.6) !important; border-radius: 6px 0 0 0; }
.leaflet-bottom.leaflet-right { bottom: calc(var(--dock-h) - 6px); transition: bottom .3s; }

/* 마커 공통 */
.mk-wrap { background: none; border: none; }
.mk { position: relative; width: 100%; height: 100%; transition: transform .2s; transform-origin: 50% 100%; }
.mk-label {
  position: absolute; top: 100%; left: 50%; transform: translateX(-50%); margin-top: 3px;
  white-space: nowrap; font-size: 12.5px; font-weight: 700; color: var(--ink);
  text-shadow: 0 0 2px #fff, 0 0 3px #fff, 0 0 4px #fff, 0 0 6px #fff; pointer-events: none;
}
.labels-off .mk-label { display: none; }
.mk.on { transform: scale(1.18); z-index: 10; }
.mk.on .mk-label { font-size: 13.5px; }

/* 사진 마커 (현지인 사진) */
.mk-photo .mk-img {
  width: 100%; height: 100%; border-radius: 50%; background: #ddd center/cover no-repeat;
  border: 3px solid #fff; box-shadow: 0 3px 10px rgba(0,0,0,.3);
}
.mk-photo .mk-count {
  position: absolute; right: -4px; top: -4px; min-width: 20px; height: 20px; padding: 0 5px;
  border-radius: 10px; background: var(--ink); color: #fff; font-size: 11px; font-weight: 800;
  display: grid; place-items: center; border: 2px solid #fff;
}
.mk.on .mk-img { border-color: var(--lime); }

/* 사진 없는 장소: 다크 핀 */
.mk-pin .pin-body {
  width: 34px; height: 34px; border-radius: 50% 50% 50% 4px; transform: rotate(-45deg);
  background: var(--ink); display: grid; place-items: center; box-shadow: 0 3px 8px rgba(0,0,0,.3);
  border: 2px solid #fff;
}
.mk-pin .pin-body > span {
  transform: rotate(45deg); width: 22px; height: 22px; border-radius: 50%; background: #fff;
  display: grid; place-items: center; font-size: 13px;
}
.mk.on.mk-pin .pin-body { background: var(--route); }

/* 코스 번호 마커 */
.mk-num {
  width: 100%; height: 100%; border-radius: 50%; background: var(--ink); color: #fff;
  font-weight: 800; font-size: 14px; display: grid; place-items: center; border: 3px solid #fff;
  box-shadow: 0 3px 8px rgba(0,0,0,.3);
}

/* 내 위치 */
.me-dot { position: relative; width: 18px; height: 18px; border-radius: 50%; background: var(--me); border: 3px solid #fff; box-shadow: 0 1px 4px rgba(0,0,0,.35); }
.me-dot::after { content: ""; position: absolute; inset: -9px; border-radius: 50%; background: rgba(47,123,255,.25); animation: ping 2s infinite; z-index: -1; }
.me-dot.demo { background: #8a56ff; }
.me-dot.demo::after { background: rgba(138,86,255,.25); }
@keyframes ping { 0% { transform: scale(.6); opacity: 1; } 100% { transform: scale(1.6); opacity: 0; } }

/* ---------------- 상단 ---------------- */
.top { position: fixed; top: 0; left: 0; right: 0; z-index: 600; padding: calc(12px + var(--safe-t)) 0 0; pointer-events: none; }
.top > * { pointer-events: auto; }
.search {
  margin: 0 16px; height: 52px; display: flex; align-items: center; gap: 10px; padding: 0 8px 0 7px;
  background: var(--card); border-radius: 26px; box-shadow: var(--shadow);
}
.search-ico { width: 20px; height: 20px; flex: none; color: var(--ink); }
.search input { flex: 1; min-width: 0; border: none; outline: none; font: inherit; font-size: 17px; background: transparent; color: var(--ink); }
.search input::placeholder { color: var(--ink-2); }
.search input::-webkit-search-cancel-button { display: none; }
.search-btn { flex: none; width: 36px; height: 36px; border-radius: 50%; border: none; background: var(--soft); display: grid; place-items: center; padding: 9px; color: var(--ink-2); }
.search-btn.lang { width: auto; min-width: 36px; padding: 0 10px; border-radius: 18px; font-size: 12px; font-weight: 800; letter-spacing: .02em; }

.chips { display: flex; gap: 8px; padding: 12px 16px 8px; overflow-x: auto; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none; display: inline-flex; align-items: center; gap: 7px; height: 44px; padding: 0 18px;
  border-radius: 22px; border: 1.5px solid transparent; background: var(--glass);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  font-size: 15.5px; font-weight: 600; box-shadow: var(--shadow-sm); white-space: nowrap;
}
.chip .em { font-size: 18px; }
.chip.on { background: var(--card); border-color: var(--ink); }
.chip.course { background: rgba(220, 246, 251, .9); }
.chip.course.on { background: var(--card); }

/* ---------------- 오른쪽 레일 ---------------- */
.rail {
  position: fixed; right: 16px; top: calc(140px + var(--safe-t)); z-index: 550;
  display: flex; flex-direction: column; border-radius: 26px; overflow: hidden;
  background: var(--mint); box-shadow: var(--shadow-sm);
}
.rail-btn { width: 52px; height: 52px; border: none; background: transparent; display: grid; place-items: center; padding: 14px; color: var(--mint-ink); }
.rail-btn + .rail-btn { border-top: 1px solid rgba(15, 63, 74, .1); }
.rail-btn.on { background: var(--mint-ink); color: #fff; }

/* ---------------- 하단 플로팅 ---------------- */
.floaters {
  position: fixed; left: 16px; right: 16px; bottom: calc(var(--dock-h) + 14px); z-index: 550;
  display: flex; align-items: center; justify-content: space-between; pointer-events: none;
  transition: bottom .3s, opacity .2s;
}
.floaters > * { pointer-events: auto; }
.round-btn {
  width: 56px; height: 56px; border-radius: 50%; border: none; background: var(--mint); color: var(--mint-ink);
  display: grid; place-items: center; padding: 16px; box-shadow: var(--shadow-sm); flex: none;
}
.round-btn.sm { width: 42px; height: 42px; padding: 11px; background: var(--card); color: var(--ink); }
.round-btn.busy { animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.round-spacer { width: 56px; }
.cta {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px; height: 56px; padding: 0 26px;
  border-radius: 28px; border: none; background: var(--lime); color: var(--lime-ink);
  font-size: 18px; font-weight: 700; box-shadow: 0 6px 20px rgba(80, 170, 50, .35); white-space: nowrap; text-decoration: none;
}
.cta [data-icon] { width: 22px; height: 22px; }
.cta:active { transform: scale(.97); }
.cta.wide { width: 100%; }
.cta.dark { background: var(--ink); color: #fff; box-shadow: none; }
.cta.ghost { background: var(--soft); color: var(--ink); box-shadow: none; }
.cta.sm { height: 46px; font-size: 15.5px; padding: 0 18px; }
.cta.mic { background: var(--me); color: #fff; margin-top: 12px; box-shadow: none; font-size: 16px; }
.cta.mic.rec { background: #e0245e; animation: pulse 1s infinite; }
@keyframes pulse { 50% { opacity: .7; } }
body:not([data-sheet="peek"]) .floaters .cta { opacity: 0; pointer-events: none; transform: scale(.9); }
.cta { transition: opacity .2s, transform .2s; }

/* ---------------- 바텀 시트 ---------------- */
.dock { position: fixed; left: 0; right: 0; bottom: 0; z-index: 700; padding: 0 10px calc(10px + var(--safe-b)); pointer-events: none; }
.dock-card {
  pointer-events: auto; max-width: 640px; margin: 0 auto; background: var(--card); border-radius: 30px;
  box-shadow: 0 -4px 30px rgba(20, 24, 30, .16); display: flex; flex-direction: column; overflow: hidden;
}
.grab { border: none; background: none; padding: 10px 0 4px; display: grid; place-items: center; flex: none; }
.grab i { width: 40px; height: 5px; border-radius: 3px; background: #d6d3cd; }
.sheet-body { overflow-y: auto; overscroll-behavior: contain; padding: 0 18px; transition: max-height .3s ease; scrollbar-width: none; }
.sheet-body::-webkit-scrollbar { display: none; }
.dock[data-state="peek"] .sheet-body { max-height: 46px; overflow: hidden; }
.dock[data-state="open"] .sheet-body { max-height: min(46vh, 440px); }
.dock[data-state="full"] .sheet-body { max-height: calc(100vh - 210px - var(--safe-t)); }

.peek-line { height: 44px; display: flex; align-items: center; justify-content: center; font-size: 17px; font-weight: 600; }
.sheet-head { display: flex; align-items: center; gap: 10px; padding: 2px 0 10px; position: sticky; top: 0; background: var(--card); z-index: 2; }
.sheet-head h3 { margin: 0; font-size: 19px; flex: 1; }
.sheet-head .sub { color: var(--muted); font-size: 13.5px; font-weight: 500; }

/* 탭바 */
.tabbar { display: flex; margin: 8px 10px 10px; padding: 6px; background: var(--soft); border-radius: 26px; flex: none; }
.tab { flex: 1; border: none; background: none; border-radius: 20px; padding: 8px 2px 7px; display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 12px; font-weight: 600; color: var(--ink-2); min-width: 0; }
.tab [data-icon] { width: 24px; height: 24px; }
.tab span:last-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.tab.on { background: #e4e2de; color: var(--ink); }

/* 장소 리스트 카드 */
.spot-list { list-style: none; margin: 0; padding: 0 0 12px; display: grid; gap: 10px; }
.spot { display: flex; gap: 12px; align-items: center; padding: 8px; border-radius: 18px; background: var(--soft); cursor: pointer; }
.spot:active { background: #ebe9e4; }
.thumb { width: 64px; height: 64px; border-radius: 14px; flex: none; background: center/cover no-repeat; display: grid; place-items: center; font-size: 28px; position: relative; overflow: hidden; }
.thumb .n { position: absolute; left: 4px; top: 4px; width: 22px; height: 22px; border-radius: 50%; background: var(--ink); color: #fff; font-size: 12px; font-weight: 800; display: grid; place-items: center; }
.spot-main { flex: 1; min-width: 0; }
.spot-name { font-weight: 700; font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.spot-ko { color: var(--muted); font-size: 13px; }
.spot-meta { font-size: 13px; color: var(--ink-2); margin-top: 3px; display: flex; gap: 8px; flex-wrap: wrap; }
.spot-go { width: 40px; height: 40px; border-radius: 50%; border: none; background: var(--lime); color: var(--lime-ink); padding: 10px; flex: none; }
.empty { text-align: center; color: var(--muted); padding: 24px 12px 28px; line-height: 1.6; }

/* 그라데이션 대체 이미지 */
.ph-eats { background-image: linear-gradient(135deg, #ffd5b8, #ffb38a); }
.ph-cafe { background-image: linear-gradient(135deg, #f1e3cf, #d9bf9b); }
.ph-view { background-image: linear-gradient(135deg, #ffcfa8, #b9d3ff); }
.ph-walk { background-image: linear-gradient(135deg, #cdeccf, #9fd8b0); }
.ph-meet { background-image: linear-gradient(135deg, #d7e7ff, #b8cff7); }

/* ---------------- 상세 ---------------- */
.detail-top { display: flex; justify-content: space-between; align-items: center; padding: 0 0 10px; position: sticky; top: 0; z-index: 3; background: var(--card); }
.gallery { display: flex; gap: 8px; overflow-x: auto; scroll-snap-type: x mandatory; margin: 0 -18px; padding: 0 18px; scrollbar-width: none; }
.gallery::-webkit-scrollbar { display: none; }
.shot { position: relative; flex: none; width: 78%; max-width: 360px; aspect-ratio: 4/3; border-radius: 20px; overflow: hidden; scroll-snap-align: start; background: #eee center/cover no-repeat; border: none; padding: 0; }
.shot:only-child { width: 100%; max-width: none; aspect-ratio: 16/9; }
.shot .by { position: absolute; left: 10px; bottom: 10px; background: rgba(0,0,0,.55); color: #fff; font-size: 12px; font-weight: 600; padding: 5px 10px; border-radius: 12px; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.shot.add { display: grid; place-items: center; background: var(--soft); border: 2px dashed #d9d5ce; color: var(--ink-2); font-weight: 600; font-size: 14px; width: 42%; }
.shot.add.solo { width: 100%; aspect-ratio: 16/8; }
.shot.add .big { font-size: 40px; display: block; margin-bottom: 4px; }
.shot.add .big.emoji { filter: grayscale(.1); }

.d-title { margin: 14px 0 0; font-size: 24px; line-height: 1.25; letter-spacing: -.01em; }
.d-ko { color: var(--muted); font-size: 14.5px; margin-top: 2px; }
.d-meta { display: flex; flex-wrap: wrap; gap: 6px 12px; margin-top: 8px; font-size: 14px; color: var(--ink-2); }
.d-meta b { color: var(--ink); }

.act-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin: 16px 0 4px; }
.act { border: none; background: none; display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; color: var(--ink-2); padding: 0; }
.act .ic { width: 52px; height: 52px; border-radius: 50%; background: var(--soft); display: grid; place-items: center; padding: 14px; color: var(--ink); }
.act.primary .ic { background: var(--lime); color: var(--lime-ink); }
.act.on .ic { background: #ffe3e3; color: #e0245e; }

.sec-title { font-size: 16px; font-weight: 800; margin: 20px 0 10px; }
.feats { display: flex; flex-wrap: wrap; gap: 8px; }
.feat { display: inline-flex; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 14px; background: var(--soft); font-size: 14px; font-weight: 600; }
.desc { line-height: 1.6; font-size: 15.5px; margin: 0; color: var(--ink-2); }
.tip { background: var(--warm); border-radius: 16px; padding: 14px 16px; line-height: 1.55; font-size: 15px; margin-top: 12px; }
.tip b { display: block; font-size: 13px; margin-bottom: 4px; color: #8a5a00; }
.addr { display: flex; gap: 8px; align-items: flex-start; color: var(--muted); font-size: 14px; margin: 14px 0 18px; }
.addr [data-icon] { width: 16px; height: 16px; flex: none; margin-top: 2px; }

/* ---------------- 길찾기 ---------------- */
.route-card { background: var(--soft); border-radius: 20px; padding: 14px 16px; }
.route-ends { display: grid; grid-template-columns: 18px 1fr; gap: 4px 12px; align-items: center; font-size: 15px; }
.route-ends .dot { width: 12px; height: 12px; border-radius: 50%; background: var(--me); justify-self: center; border: 2px solid #fff; box-shadow: 0 0 0 1px var(--me); }
.route-ends .dot.demo { background: #8a56ff; box-shadow: 0 0 0 1px #8a56ff; }
.route-ends .line { width: 2px; height: 14px; background: repeating-linear-gradient(#bbb 0 3px, transparent 3px 6px); justify-self: center; }
.route-ends .flag { width: 14px; height: 14px; border-radius: 50% 50% 50% 2px; transform: rotate(-45deg); background: var(--ink); justify-self: center; }
.route-ends .lbl { color: var(--muted); font-size: 13px; }
.route-sum { display: flex; align-items: baseline; gap: 10px; margin: 16px 0 4px; }
.route-sum .big { font-size: 34px; font-weight: 800; letter-spacing: -.02em; }
.route-sum .sm { color: var(--ink-2); font-size: 15px; font-weight: 600; }
.route-note { color: var(--muted); font-size: 13px; }
.route-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 14px; }
.ask-box { margin-top: 16px; border-radius: 20px; padding: 16px; background: linear-gradient(135deg, #f0ffe9, #dcf6fb); display: flex; gap: 12px; align-items: center; cursor: pointer; border: none; text-align: left; width: 100%; }
.ask-box .em { font-size: 34px; }
.ask-box b { display: block; font-size: 16px; }
.ask-box span { font-size: 13.5px; color: var(--ink-2); }
.steps { list-style: none; padding: 0; margin: 0 0 18px; }
.steps li { display: flex; gap: 12px; align-items: center; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.steps li:last-child { border-bottom: none; }
.steps .arw { width: 34px; height: 34px; border-radius: 50%; background: var(--soft); display: grid; place-items: center; font-size: 17px; flex: none; }
.steps .txt { flex: 1; min-width: 0; }
.steps .dist { color: var(--muted); font-size: 13px; flex: none; }
.skeleton { height: 14px; border-radius: 7px; background: linear-gradient(90deg, #eee, #f6f6f6, #eee); background-size: 200% 100%; animation: shimmer 1.2s infinite; margin: 10px 0; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* ---------------- 사진 올리기 ---------------- */
.post-preview { width: 100%; aspect-ratio: 4/3; border-radius: 20px; background: #eee center/cover no-repeat; }
.field { width: 100%; height: 48px; border-radius: 14px; border: 1.5px solid var(--line); padding: 0 14px; font: inherit; font-size: 15.5px; margin: 12px 0 4px; outline: none; }
.field:focus { border-color: var(--ink); }

/* ---------------- 도움 요청 화면 ---------------- */
.help { position: fixed; inset: 0; z-index: 1000; background: #f7f5f0; overflow-y: auto; padding: 0 16px calc(32px + var(--safe-b)); }
.help-top { display: flex; gap: 12px; align-items: center; padding: calc(12px + var(--safe-t)) 0 12px; font-weight: 700; position: sticky; top: 0; background: #f7f5f0; z-index: 2; }
.help-picker { display: grid; gap: 8px; }
.help-picker h3 { margin: 4px 0 6px; }
.ko-card { background: var(--card); border-radius: 24px; padding: 20px; box-shadow: var(--shadow-sm); }
.ko-badge { display: inline-block; background: var(--lime); color: var(--lime-ink); font-weight: 800; font-size: 13px; padding: 5px 12px; border-radius: 12px; margin-bottom: 10px; }
.ko-big { font-size: 24px; line-height: 1.5; font-weight: 700; margin-bottom: 16px; word-break: keep-all; }
.ko-big .place { background: linear-gradient(transparent 60%, #c9f5b5 60%); }
.help-map { height: 230px; border-radius: 24px; margin-top: 12px; overflow: hidden; }
.help-dist { text-align: center; color: var(--ink-2); margin: 10px 0; font-size: 15px; font-weight: 600; }
.helper-title { font-weight: 800; font-size: 18px; margin: 16px 0 10px; }
.reply-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.reply-grid button { background: var(--card); border: 2px solid transparent; border-radius: 18px; padding: 16px 8px; font-size: 16px; font-weight: 700; word-break: keep-all; box-shadow: var(--shadow-sm); }
.reply-grid button:active { border-color: var(--lime); }

.reply { position: fixed; inset: 0; z-index: 1100; background: var(--ink); color: #fff; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; padding: 24px; cursor: pointer; }
.reply-label { opacity: .7; margin-bottom: 12px; }
.reply-main { font-size: 40px; font-weight: 800; line-height: 1.3; }
.reply-ko { margin-top: 16px; opacity: .7; font-size: 18px; }
.reply-hint { margin-top: 32px; opacity: .5; font-size: 14px; }

.viewer { position: fixed; inset: 0; z-index: 1150; background: rgba(0,0,0,.92); display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 16px; cursor: zoom-out; }
.viewer img { max-width: 100%; max-height: 80vh; border-radius: 12px; }
.viewer-cap { color: #fff; margin-top: 12px; font-weight: 600; }

.toast { position: fixed; top: calc(130px + var(--safe-t)); left: 50%; transform: translateX(-50%); z-index: 1200; background: var(--ink); color: #fff; padding: 11px 18px; border-radius: 16px; font-size: 14px; font-weight: 600; max-width: calc(100% - 32px); text-align: center; box-shadow: var(--shadow); }

@media (min-width: 700px) {
  .search { max-width: 520px; }
  .chips { max-width: 100%; }
}

/* 사진 없는 장소의 대체 배경 (.shot 기본 배경보다 우선) */
.shot.ph-eats, .thumb.ph-eats { background-image: linear-gradient(135deg, #ffd5b8, #ffb38a); }
.shot.ph-cafe, .thumb.ph-cafe { background-image: linear-gradient(135deg, #f1e3cf, #d9bf9b); }
.shot.ph-view, .thumb.ph-view { background-image: linear-gradient(135deg, #ffcfa8, #b9d3ff); }
.shot.ph-walk, .thumb.ph-walk { background-image: linear-gradient(135deg, #cdeccf, #9fd8b0); }
.shot.ph-meet, .thumb.ph-meet { background-image: linear-gradient(135deg, #d7e7ff, #b8cff7); }
.shot.add[class*="ph-"] { border-color: rgba(255,255,255,.7); color: var(--ink); }

/* =====================================================================
   오늘의 외출 가이드: 지역 · 날씨 · 안전 · 버스 · 브리핑
   ===================================================================== */
.region-btn { flex: none; display: inline-flex; align-items: center; gap: 5px; height: 38px; padding: 0 10px 0 11px; border-radius: 19px; border: none; background: var(--ink); color: #fff; font-size: 14.5px; }
.region-btn svg { width: 15px; height: 15px; opacity: .8; }
.search input { font-size: 16px; padding-left: 4px; }

/* 시트 공통 */
.detail-top h3 { margin: 0; font-size: 17px; flex: 1; text-align: center; }
.sec-row { display: flex; align-items: center; justify-content: space-between; }
.sec-row .sec-title { margin-bottom: 10px; }
.sec-title .count { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: var(--ink); color: #fff; font-size: 12px; margin-left: 4px; vertical-align: 2px; }
.link { border: none; background: none; color: var(--route); font-weight: 700; font-size: 14px; padding: 20px 0 10px; }
.hint-box { background: var(--soft); border-radius: 16px; padding: 14px 16px; color: var(--ink-2); font-size: 14.5px; line-height: 1.5; }
.note { color: var(--muted); font-size: 12.5px; text-align: center; padding: 14px 0 18px; }
.kv { display: flex; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.kv span { color: var(--muted); min-width: 64px; }
.h-scroll { display: flex; gap: 10px; overflow-x: auto; margin: 0 -18px; padding: 0 18px; scrollbar-width: none; }
.h-scroll::-webkit-scrollbar { display: none; }
.mini-spot { flex: none; width: 108px; border: none; background: none; padding: 0; text-align: left; font-size: 13.5px; font-weight: 600; }
.mini-spot .thumb { width: 108px; height: 84px; border-radius: 16px; margin-bottom: 6px; font-size: 34px; }
.mini-spot span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.spot.picked { outline: 2px solid var(--lime); }

/* 날씨 카드 */
.wx-card { background: linear-gradient(160deg, #eaf7ff 0%, #f3fbe9 100%); border-radius: 24px; padding: 18px; }
.wx-main { display: flex; align-items: center; gap: 14px; }
.wx-ico { font-size: 58px; line-height: 1; }
.wx-temp { font-size: 46px; font-weight: 800; letter-spacing: -.03em; line-height: 1; }
.wx-desc { font-weight: 700; margin-top: 4px; }
.wx-hl { color: var(--ink-2); font-size: 13.5px; margin-top: 2px; }
.metrics { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-top: 16px; }
.metric { background: rgba(255,255,255,.75); border-radius: 14px; padding: 9px 6px 8px; text-align: center; display: flex; flex-direction: column; gap: 2px; border-top: 4px solid var(--g); }
.metric .m-label { font-size: 11.5px; color: var(--ink-2); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.metric b { font-size: 18px; }
.metric .m-grade { font-size: 11.5px; font-weight: 700; color: var(--g); min-height: 14px; }
.metric.g-1 { --g: #adb5bd; }
.metric.g0 { --g: #2b8a3e; }
.metric.g1 { --g: #1c7ed6; }
.metric.g2 { --g: #f08c00; }
.metric.g3 { --g: #e03131; }
.hourly { display: flex; gap: 4px; overflow-x: auto; margin: 14px -6px 0; padding: 0 6px; scrollbar-width: none; }
.hourly::-webkit-scrollbar { display: none; }
.hr { flex: none; width: 46px; display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 12px; color: var(--ink-2); }
.hr-ico { font-size: 20px; }
.hr b { color: var(--ink); font-size: 14px; }
.hr-pop { font-size: 11px; min-height: 13px; color: #1c7ed6; }
.hr-pop.wet { font-weight: 800; }

/* AI 브리핑 버튼 */
.brief { width: 100%; margin-top: 12px; display: flex; align-items: center; gap: 12px; padding: 14px; border: none; border-radius: 22px; background: var(--ink); color: #fff; text-align: left; }
.brief-play { width: 46px; height: 46px; border-radius: 50%; background: var(--lime); color: var(--lime-ink); display: grid; place-items: center; padding: 13px 12px 13px 14px; flex: none; }
.brief-txt { flex: 1; min-width: 0; }
.brief-txt b { display: block; font-size: 16.5px; }
.brief-txt span { font-size: 13px; opacity: .75; }
.brief-tag { font-size: 10.5px; font-weight: 700; padding: 4px 8px; border-radius: 8px; background: rgba(255,255,255,.14); flex: none; }
.brief:active { transform: scale(.99); }

/* 안전 정보 */
.mk-hz { width: 34px; height: 34px; border-radius: 50%; background: #fff; border: 3px solid var(--c); display: grid; place-items: center; font-size: 15px; box-shadow: 0 2px 8px rgba(0,0,0,.25); transform-origin: 50% 50%; }
.mk-hz.danger::before { content: ""; position: absolute; inset: -8px; border-radius: 50%; border: 2px solid var(--c); animation: ping 1.6s infinite; }
.mk-hz.on { transform: scale(1.25); background: var(--c); }
.mk-bus { width: 28px; height: 28px; border-radius: 9px; background: #1c7ed6; color: #fff; padding: 5px; border: 2px solid #fff; box-shadow: 0 2px 6px rgba(0,0,0,.25); transform-origin: 50% 50%; }
.mk-bus .fav { position: absolute; right: -7px; top: -8px; font-style: normal; color: #f59f00; font-size: 14px; text-shadow: 0 0 2px #fff, 0 0 3px #fff; }
.mk-bus.on { transform: scale(1.3); background: var(--ink); }
.minor-off .mk-label.minor { display: none; }
.mk-label.minor { font-size: 11.5px; font-weight: 600; }

.type-row { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 10px; scrollbar-width: none; }
.type-row::-webkit-scrollbar { display: none; }
.type-chip { flex: none; border: 1.5px solid transparent; background: var(--soft); border-radius: 14px; padding: 8px 12px; font-size: 14px; font-weight: 600; white-space: nowrap; }
.type-chip b { color: var(--c); margin-left: 2px; }
.type-chip.on { border-color: var(--c); background: #fff; }
.hz-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.hz-item { display: flex; gap: 12px; align-items: center; padding: 10px; border-radius: 16px; background: var(--soft); cursor: pointer; }
.hz-ico { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; font-size: 19px; background: #fff; border: 2.5px solid var(--c); flex: none; }
.hz-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.hz-main b { font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hz-main span { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hz-side { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; flex: none; }
.hz-dist { font-size: 12px; color: var(--ink-2); }
.lvl { font-size: 11.5px; font-weight: 800; padding: 3px 8px; border-radius: 8px; }
.lvl.l1 { background: #e7f5ff; color: #1864ab; }
.lvl.l2 { background: #fff4e6; color: #d9480f; }
.lvl.l3 { background: #ffe3e3; color: #c92a2a; }
.hz-hero { display: flex; gap: 14px; align-items: flex-start; }
.hz-big { width: 60px; height: 60px; border-radius: 50%; background: #fff; border: 3px solid var(--c); display: grid; place-items: center; font-size: 28px; flex: none; }
.hz-type { font-weight: 800; color: var(--c); font-size: 14px; }
.warn-box, .ok-box { margin-top: 14px; border-radius: 18px; padding: 14px; font-size: 14.5px; }
.warn-box { background: #fff4e6; }
.warn-box > b { display: block; margin-bottom: 10px; color: #d9480f; }
.warn-box .hz-item { background: #fff; }
.ok-box { background: #ebfbee; color: #2b8a3e; font-weight: 600; }
.voice-btn { margin-left: auto; border: none; background: var(--soft); border-radius: 16px; padding: 8px 12px; font-size: 13px; font-weight: 700; white-space: nowrap; }

/* 버스 */
.stop-card { background: var(--soft); border-radius: 18px; padding: 12px 14px; margin-bottom: 8px; cursor: pointer; }
.stop-head { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; }
.stop-head b { font-size: 15.5px; }
.stop-meta { color: var(--muted); font-size: 12.5px; flex: 1; }
.star { border: none; background: none; width: 34px; height: 34px; padding: 6px; color: #adb5bd; margin: -6px -6px -6px auto; }
.star.on { color: #f59f00; }
.arr { display: flex; align-items: center; gap: 8px; padding: 7px 0; border-top: 1px solid rgba(0,0,0,.05); font-size: 14px; }
.stop-head + .arr { border-top: none; }
.rt { flex: none; min-width: 46px; text-align: center; padding: 3px 7px; border-radius: 8px; font-weight: 800; font-size: 13px; color: #fff; background: #495057; }
.rt-간선 { background: #1c64f2; }
.rt-지선 { background: #2f9e44; }
.rt-광역 { background: #e03131; }
.rt-마을 { background: #66a80f; }
.rt-순환 { background: #f08c00; }
.rt-급행 { background: #c2255c; }
.arr-dest { flex: 1; min-width: 0; color: var(--ink-2); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.arr-min { font-weight: 800; color: #e03131; flex: none; }
.arr-min.soon { animation: pulse 1.2s infinite; }
.arr-next { color: var(--muted); font-size: 12px; flex: none; min-width: 58px; text-align: right; }
.act-row.three { grid-template-columns: repeat(3, 1fr); }

/* 지역 선택 */
.region-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding-bottom: 18px; }
.region-card { border: 2px solid transparent; background: var(--soft); border-radius: 20px; padding: 14px; text-align: left; display: flex; flex-direction: column; gap: 4px; }
.region-card .r-em { font-size: 30px; }
.region-card b { font-size: 17px; }
.region-card .r-meta { font-size: 12.5px; color: var(--ink-2); }
.region-card.on { border-color: var(--ink); background: #fff; }

/* =====================================================================
   idea.md 최종본 반영: 이모지 정리 · 장소 설명 보강 · 음성 상태 · 반응형
   ===================================================================== */
/* 이미지 로딩 실패/사진 없음 → 플레이스홀더 색 */
.thumb, .shot { background-color: #e9e6e0; }
.ph-ic { width: 26px; height: 26px; color: rgba(21, 23, 26, .35); display: block; }
.thumb.ph-bus { background: #e7f0ff; color: #1c7ed6; padding: 20px; }
.thumb.ph-hz { background: #fff; color: var(--c); padding: 20px; border: 2px solid var(--c); }
.mk-pin .pin-body > span { width: 10px; height: 10px; }
.mk-hz .hz-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--c); display: block; }
.mk-hz.on .hz-dot { background: #fff; }
.hz-ico, .hz-big { color: var(--c); padding: 10px; }
.hz-big { padding: 14px; }
.cdot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; flex: none; }
.chip .cdot { margin-right: 1px; }
.type-chip .cdot { margin-right: 5px; vertical-align: 1px; }
.region-btn b { font-weight: 700; }
.ask-box .em { width: 38px; height: 38px; flex: none; color: var(--route); }
.cta svg, .voice-btn svg { width: 18px; height: 18px; }
.voice-btn { display: inline-flex; align-items: center; gap: 6px; }
.steps .arw { font-size: 16px; font-weight: 800; color: var(--ink-2); }

/* 장소 카드: 한두 문장 소개 */
.spot { align-items: flex-start; }
.spot .thumb { width: 76px; height: 76px; }
.spot-ko { font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.spot-desc { font-size: 13.5px; color: var(--ink-2); line-height: 1.45; margin-top: 4px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.spot-go { align-self: center; }
.spot-main { overflow: hidden; }
.spot-desc { overflow-wrap: anywhere; }

/* 상세: 출처 · 번역 바 · 해볼 것 · 음성 상태 */
.credit { font-size: 11.5px; color: var(--muted); margin-top: 6px; line-height: 1.5; }
.credit a { color: inherit; }
.tr-bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 12px; padding: 8px 8px 8px 14px; background: var(--soft); border-radius: 14px; font-size: 12.5px; color: var(--ink-2); }
.tr-btn { border: none; background: var(--card); border-radius: 10px; padding: 7px 12px; font-size: 13px; font-weight: 700; box-shadow: 0 1px 3px rgba(0,0,0,.08); white-space: nowrap; }
.exp { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.exp li { position: relative; padding: 10px 12px 10px 30px; background: var(--soft); border-radius: 12px; font-size: 14.5px; line-height: 1.45; }
.exp li::before { content: ""; position: absolute; left: 13px; top: 17px; width: 7px; height: 7px; border-radius: 50%; background: var(--route); }
.addr { margin-top: 0; }
.addr small { color: var(--muted); }
.act.voice.playing .ic { background: var(--ink); color: #fff; }
.act.voice.loading .ic, .cta.voice.loading { opacity: .6; }
.act.voice.loading .ic { animation: pulse 1s infinite; }
.cta.voice { gap: 8px; }
.cta.voice .ic { width: 18px; height: 18px; padding: 0; background: none; display: inline-flex; }
.cta.voice.playing { background: var(--route); }
.course-card { background: var(--soft); border-radius: 18px; padding: 14px; margin-bottom: 10px; }
.course-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; margin-bottom: 6px; }
.course-head span { color: var(--muted); font-size: 13px; white-space: nowrap; }
.course-card .desc { font-size: 14.5px; margin-bottom: 12px; }

/* ---------- 태블릿 세로 (700~899px): 확장형 하단 패널 ---------- */
@media (min-width: 600px) and (max-width: 767px) {
  .dock[data-state="open"] .sheet-body { max-height: min(52vh, 560px); }
  .dock-card { max-width: 760px; }
  .gallery .shot { width: 60%; }
}

/* ---------- 태블릿 가로 · 노트북 (768px~): 왼쪽 지도 + 오른쪽 상세 패널 ---------- */
@media (min-width: 768px) {
  :root { --panel-w: clamp(340px, 38vw, 520px); }
  #map { right: var(--panel-w); }
  .top { right: var(--panel-w); }
  .search { max-width: 560px; }
  .rail { right: calc(var(--panel-w) + 16px); }
  .floaters { right: calc(var(--panel-w) + 16px); bottom: 24px; }
  .leaflet-bottom.leaflet-right { bottom: 0; }
  .toast { left: calc((100% - var(--panel-w)) / 2); }
  .dock { left: auto; top: 0; right: 0; bottom: 0; width: var(--panel-w); padding: 12px 12px 12px 0; }
  .dock-card { height: 100%; max-width: none; border-radius: 24px; box-shadow: 0 4px 30px rgba(20, 24, 30, .14); }
  .grab { display: none; }
  .dock .sheet-body, .dock[data-state] .sheet-body { max-height: none; flex: 1; min-height: 0; overflow-y: auto; padding-top: 0; }
  .sheet-body > .detail-top { padding-top: 14px; }
  .sheet-body > .peek-line, .sheet-body > .sheet-head { padding-top: 14px; height: auto; min-height: 58px; }
  body .floaters .cta, body:not([data-sheet="peek"]) .floaters .cta { opacity: 1; pointer-events: auto; transform: none; }
  .gallery .shot { width: 85%; }
  .gallery .shot:only-child { aspect-ratio: 4/3; }
  .help { left: auto; width: min(560px, 100%); box-shadow: -8px 0 30px rgba(0,0,0,.12); }
}
@media (min-width: 1400px) {
  :root { --panel-w: 560px; }
}
