*{box-sizing:border-box}body{margin:0;background:#f7f8f5;color:#24312a;font-family:system-ui,-apple-system,"Noto Sans KR",sans-serif;padding-bottom:85px}button,input,select,textarea{font:inherit}button{cursor:pointer;border:1px solid #d9e1d8;border-radius:10px;background:#fff;padding:10px 14px;color:#25412c}button:hover{background:#f0f6ed}.primary{background:#34784d;border-color:#34784d;color:white;font-weight:700}.primary:hover{background:#28613d}.wrap{max-width:850px;margin:auto;padding:0 18px}header{background:#fff;border-bottom:1px solid #e7ebe5}.top{display:flex;justify-content:space-between;align-items:center;padding-top:17px;padding-bottom:17px}.logo{font-size:27px;color:#267447}.logo small{font-size:10px;letter-spacing:1px}.sub{color:#6f7b70;font-size:12px}.hero{background:linear-gradient(115deg,#337c51,#6ba26b);color:#fff;border-radius:18px;padding:28px;margin:20px 0}.hero h1{font-size:24px;margin:0 0 8px}.hero p{margin:0;color:#edf8ef}.controls{background:#fff;border:1px solid #e2e8df;border-radius:14px;padding:14px;display:grid;grid-template-columns:1.1fr 1fr 1fr auto;gap:10px;align-items:end}.controls label,form label{display:grid;gap:5px;font-size:13px;font-weight:650}input,select,textarea{width:100%;border:1px solid #d6dfd5;border-radius:9px;padding:10px;background:#fff;min-width:0}.tabs{display:flex;overflow:auto;gap:8px;margin:20px 0}.tabs button.active{background:#34784d;color:#fff}.bar{display:flex;align-items:center;justify-content:space-between}.bar h2{font-size:20px}.posts{display:grid;gap:12px}.post{background:#fff;border:1px solid #e1e9e0;border-radius:14px;padding:18px;cursor:pointer}.post h3{margin:10px 0;font-size:18px}.post p{color:#56635a;white-space:pre-wrap;overflow-wrap:anywhere}.meta,.foot{font-size:12px;color:#77827b}.tag{display:inline-block;background:#e8f3e8;color:#307047;padding:4px 9px;border-radius:30px;font-size:12px}.foot{display:flex;justify-content:space-between;margin-top:16px}.bottom{position:fixed;bottom:0;left:0;right:0;display:flex;justify-content:center;gap:8px;padding:10px;background:#fff;border-top:1px solid #e4e9e2;z-index:5}.bottom button{flex:1;max-width:145px;font-size:13px}dialog{border:0;border-radius:17px;padding:22px;width:min(94vw,600px);max-height:90vh;overflow:auto;box-shadow:0 18px 80px #0004}dialog::backdrop{background:#15291a99}form{display:grid;gap:14px}form h2{margin:0 0 4px}.actions{display:flex;justify-content:flex-end;gap:8px}.hint{font-size:12px;color:#68756b;margin:0}.viewer{min-height:120px}.close{float:right}.detail-body{white-space:pre-wrap;line-height:1.7;overflow-wrap:anywhere}.media-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:10px;margin:15px 0}.media-grid img,.media-grid video{width:100%;max-height:380px;object-fit:contain;background:#101010;border-radius:10px}.comment{border-top:1px solid #e7ece6;padding:12px 0}.comment p{white-space:pre-wrap;overflow-wrap:anywhere}.commentbox{display:grid;gap:10px;margin-top:16px}.error{color:#b22}.empty{text-align:center;color:#7d877f;padding:50px 0}@media(max-width:600px){.controls{grid-template-columns:1fr 1fr}.controls label:first-child{grid-column:1/-1}.controls button{grid-column:1/-1}.hero h1{font-size:21px}.bottom{gap:3px;padding:8px 4px}.bottom button{padding:10px 3px;font-size:12px}}
/* 게시판 메뉴: 가로 배치, 버튼 내 줄바꿈 방지 */
.tabs{display:flex;flex-wrap:wrap;overflow:visible;gap:8px;margin:20px 0}
.tabs button{flex:0 0 auto;white-space:nowrap;word-break:keep-all;min-width:max-content}

/* 위치 선택·지도: 기존 게시판 및 글쓰기 스타일 유지 */
.location-panel{background:#fff;border:1px solid #e2e8df;border-radius:14px;padding:14px;margin:12px 0}.location-header{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}.location-current{margin:4px 0 0;font-size:14px;color:#34784d;font-weight:700}.location-buttons{display:flex;flex-wrap:wrap;gap:7px}.location-buttons button{font-size:13px;padding:9px 11px}.location-hint{font-size:12px;color:#68756b;margin:10px 0 0;line-height:1.6}.location-panel .controls{margin-top:12px}.map-panel{margin-top:14px;border-top:1px solid #e2e8df;padding-top:8px}#neighborhoodMap{height:340px;min-height:260px;border-radius:12px;margin-top:10px;z-index:0}.location-panel [hidden]{display:none!important}@media(max-width:600px){.location-buttons{width:100%}.location-buttons button{flex:1;white-space:nowrap;font-size:12px}.location-header{align-items:flex-start}}


/* MASILDAM 지도 타일 표시 복구: 외부 Leaflet CSS 로딩 실패 시에도 기본 레이아웃 유지 */
#mapPanel, #neighborhoodMap { max-width:100%; }
#neighborhoodMap.leaflet-container {
  position:relative; overflow:hidden; isolation:isolate;
  width:100%; height:340px; min-height:260px;
  background:#e8ede6; outline:0;
  font:12px/1.5 Arial,Helvetica,sans-serif;
}
#neighborhoodMap .leaflet-pane,
#neighborhoodMap .leaflet-tile,
#neighborhoodMap .leaflet-marker-icon,
#neighborhoodMap .leaflet-marker-shadow,
#neighborhoodMap .leaflet-tile-container,
#neighborhoodMap .leaflet-pane > svg,
#neighborhoodMap .leaflet-pane > canvas,
#neighborhoodMap .leaflet-zoom-box,
#neighborhoodMap .leaflet-image-layer,
#neighborhoodMap .leaflet-layer {
  position:absolute; left:0; top:0;
}
#neighborhoodMap .leaflet-pane { z-index:400; }
#neighborhoodMap .leaflet-tile-pane { z-index:200; }
#neighborhoodMap .leaflet-overlay-pane { z-index:400; }
#neighborhoodMap .leaflet-shadow-pane { z-index:500; }
#neighborhoodMap .leaflet-marker-pane { z-index:600; }
#neighborhoodMap .leaflet-tooltip-pane { z-index:650; }
#neighborhoodMap .leaflet-popup-pane { z-index:700; }
#neighborhoodMap .leaflet-map-pane canvas { z-index:100; }
#neighborhoodMap .leaflet-map-pane svg { z-index:200; }
#neighborhoodMap .leaflet-tile { width:256px; height:256px; border:0; max-width:none!important; max-height:none!important; padding:0; margin:0; }
#neighborhoodMap .leaflet-tile-container { pointer-events:none; }
#neighborhoodMap .leaflet-zoom-animated { transform-origin:0 0; }
#neighborhoodMap .leaflet-control-container { position:relative; z-index:800; }
#neighborhoodMap .leaflet-top, #neighborhoodMap .leaflet-bottom { position:absolute; z-index:1000; pointer-events:none; }
#neighborhoodMap .leaflet-top { top:0; }
#neighborhoodMap .leaflet-right { right:0; }
#neighborhoodMap .leaflet-bottom { bottom:0; }
#neighborhoodMap .leaflet-left { left:0; }
#neighborhoodMap .leaflet-control { position:relative; z-index:800; pointer-events:auto; float:left; clear:both; }
#neighborhoodMap .leaflet-right .leaflet-control { float:right; }
#neighborhoodMap .leaflet-top .leaflet-control { margin-top:10px; }
#neighborhoodMap .leaflet-bottom .leaflet-control { margin-bottom:10px; }
#neighborhoodMap .leaflet-left .leaflet-control { margin-left:10px; }
#neighborhoodMap .leaflet-right .leaflet-control { margin-right:10px; }
#neighborhoodMap .leaflet-bar { box-shadow:0 1px 5px #0005; border-radius:4px; }
#neighborhoodMap .leaflet-bar a { display:block; width:30px; height:30px; line-height:30px; text-align:center; background:#fff; color:#222; text-decoration:none; border-bottom:1px solid #ccc; font:bold 20px Arial,sans-serif; }
#neighborhoodMap .leaflet-bar a:first-child { border-radius:4px 4px 0 0; }
#neighborhoodMap .leaflet-bar a:last-child { border-bottom:0; border-radius:0 0 4px 4px; }
#neighborhoodMap .leaflet-control-attribution { padding:0 5px; background:#fffd; font:11px/1.5 Arial,sans-serif; }
#neighborhoodMap .leaflet-control-attribution a { color:#12618c; }
#neighborhoodMap .leaflet-interactive { cursor:pointer; }
#neighborhoodMap .leaflet-container img { max-width:none!important; }
#neighborhoodMap .leaflet-container a { -webkit-tap-highlight-color:transparent; }
#neighborhoodMap .leaflet-popup { position:absolute; text-align:center; margin-bottom:20px; }
#neighborhoodMap .leaflet-popup-content-wrapper { background:#fff; border-radius:12px; box-shadow:0 3px 14px #0004; padding:1px; }
#neighborhoodMap .leaflet-popup-content { margin:13px 20px; line-height:1.4; }
#neighborhoodMap .leaflet-popup-tip-container { width:40px; height:20px; position:absolute; left:50%; margin-left:-20px; overflow:hidden; pointer-events:none; }
#neighborhoodMap .leaflet-popup-tip { width:17px; height:17px; background:#fff; box-shadow:0 3px 14px #0004; transform:translate(11px,-10px) rotate(45deg); }
#neighborhoodMap .leaflet-popup-close-button { position:absolute; right:0; top:0; width:24px; height:24px; text-align:center; text-decoration:none; color:#777; }

.region-filter-bar{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin:-6px 0 14px}.region-filter-bar button{font-size:13px;padding:7px 11px}.region-filter-bar .sub{overflow-wrap:anywhere}

/* 마실담 TV 전용 스타일: 기존 지도/게시판 스타일 보존 */
[hidden]{display:none!important}
.tv-section{margin:22px 0 32px}.tv-section .bar{gap:12px;flex-wrap:wrap}.tv-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,290px),1fr));gap:16px;margin-top:16px}.tv-card{background:white;border:1px solid #e1e9e0;border-radius:14px;padding:14px;min-width:0}.tv-card h3{font-size:17px;margin:12px 0 7px;overflow-wrap:anywhere}.tv-description{white-space:pre-wrap;overflow-wrap:anywhere;font-size:14px;color:#536459}.tv-player{position:relative;width:100%;aspect-ratio:16/9;background:#121b15;border-radius:10px;overflow:hidden}.tv-player iframe{position:absolute;inset:0;width:100%;height:100%;border:0}.tv-external{display:inline-block;margin-top:8px;color:#267447;font-size:13px}.tv-admin-item{padding:12px 0;border-bottom:1px solid #e1e9e0;display:flex;gap:8px;align-items:center;flex-wrap:wrap}.tv-admin-item strong{flex:1 1 180px}.tv-admin-item button{padding:6px 10px;font-size:12px}
.location-panel .controls{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;align-items:end}.location-panel .controls>label{grid-column:auto;min-width:0}.location-panel .controls>label:nth-of-type(3){display:flex;flex-direction:column;gap:5px}.location-panel .controls>label:nth-of-type(3)>input:not([hidden]){margin-top:6px}.location-panel .controls>.location-hint{grid-column:1/-1;margin:0}.location-panel .controls>#apply{grid-column:1/-1;justify-self:end}@media(max-width:600px){.location-panel .controls{grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;padding:9px}.location-panel .controls>label:first-child{grid-column:auto}.location-panel .controls>label{font-size:12px}.location-panel .controls select{font-size:12px;padding:8px 3px}.location-panel .controls>#apply{grid-column:1/-1;width:100%}}
.location-panel #town,.location-panel .controls>.location-hint{display:none!important}.location-panel .controls>label:nth-of-type(3)>input{display:none!important}.location-panel .controls>label:nth-of-type(3){align-self:end}
.location-panel #apply,.location-panel #town,.location-panel #townChoices+p,.location-panel .controls>.location-hint{display:none!important}
