@charset "UTF-8";

/* map.css 현수막 광고 게시대 지역별 위치 CSS */

/* 밝은 비주얼 위에서도 메뉴가 보이도록 지도 페이지는 헤더를 항상 검정 배경으로 */
body[data-region] #header_area header { background: #000; }
body[data-region] #m_header_area #m_header { background: #000; }

.map_hero *, .map_area *, .map_hero *::before, .map_area *::before, .map_hero *::after, .map_area *::after { box-sizing: border-box; }
.map_inner { max-width: 1400px; width: 92%; margin: 0 auto; position: relative; }

/* ===== 상단 비주얼 ===== */
/* 배경 이미지: /map/images/main.png — 고정 헤더(PC 90px / 모바일 56px)에 윗부분이 가리지 않도록 헤더 높이만큼 아래에서 시작 */
.map_hero { position: relative; margin-top: 40px; padding: 110px 0 130px; background: url(../map/images/main.png) no-repeat center top / cover, linear-gradient(180deg, #cfe6fb 0%, #e8f3fd 60%, #f4f9fe 100%); }
.map_hero .map_inner { padding: 0 100px; }

.map_breadcrumb { display: flex; align-items: center; gap: 10px; font-size: 0.875rem; color: #333; margin-bottom: 40px; }
.map_breadcrumb a { color: #333; display: inline-flex; align-items: center; gap: 6px; transition: 0.2s; }
.map_breadcrumb a:hover { color: #1d4ed8; }
.map_breadcrumb > i { font-size: 0.7rem; color: #555; }
.map_breadcrumb strong { font-weight: 700; color: #111; }

/* smn11(현수막 광고)로 돌아가는 뒤로가기 버튼 — 정보 패널의 지정게시대 제목 위 (경기도 선택 페이지는 비주얼 우측 상단) */
.map_back_btn { display: flex; width: fit-content; align-items: center; gap: 8px; margin: 0 0 18px auto; padding: 7px 16px; border: 1px solid #1d5fe0; border-radius: 30px; background: #fff; font-size: 0.9rem; font-weight: 700; color: #1d5fe0; transition: 0.2s; }
.map_hero .map_back_btn { position: absolute; top: 0; right: 100px; margin: 0; background: rgba(255,255,255,0.9); }
.map_back_btn:hover { background: #1554d1; border-color: #1554d1; color: #fff; }

.map_hero_region { font-size: 1.75rem; font-weight: 500; color: #111; margin-bottom: 4px; }
.map_hero_city { font-size: 4rem; font-weight: 800; color: #1d5fe0; letter-spacing: 0.15em; line-height: 1.2; margin-bottom: 24px; }
.map_hero_desc { font-size: 1rem; line-height: 1.6; color: #222; min-height: 4.8em; }

/* ===== 지도 + 정보 카드 ===== */
.map_area { display: flow-root; overflow: visible; background: #fff; padding-bottom: 100px; } /* main.css의 section{overflow:hidden} 해제 — 그래야 위로 올린 카드가 잘리지 않음 */
.map_area .map_inner { margin-top: -80px; z-index: 2; }

.wrapper { display: flex; height: 600px; background: #fff; border: 1px solid #e3e8f0; border-radius: 10px; overflow: hidden; box-shadow: 0 10px 30px -10px rgba(30, 58, 138, 0.15); }

/* 좌측 지도 영역 */
.map-side { flex: 0 0 52%; background: linear-gradient(160deg, #e6f0fc 0%, #f3f7fd 100%); border-right: 1px solid #e3e8f0; display: flex; justify-content: center; align-items: center; padding: 30px; overflow: hidden; height: 100%; position: relative; }

/* 지도 우측 상단 탭 메뉴 (전체/북부/남부 등) */
.region-tabs { position: absolute; top: 20px; right: 20px; display: flex; background: rgba(255,255,255,0.8); padding: 4px; border-radius: 8px; z-index: 10; box-shadow: 0 2px 6px rgba(30, 58, 138, 0.08); }
.tab-btn { background: transparent; border: none; padding: 8px 16px; font-family: inherit; font-size: 13px; font-weight: 600; color: #64748b; cursor: pointer; border-radius: 6px; transition: all 0.2s; }
.tab-btn.active { background: #1d5fe0; color: #fff; box-shadow: 0 2px 4px rgba(37, 99, 235, 0.2); }

#map-container { width: 100%; height: 100%; max-width: 100%; touch-action: none; }
#map-container svg { width: 100%; height: 100%; background: transparent; filter: drop-shadow(0 6px 10px rgba(30, 58, 138, 0.14)); overflow: visible; }
#map-container svg * { transition: all 0.15s ease; }
#map-container svg > g { transition: none; }

.province-bg { pointer-events: none; }
.province-boundary { pointer-events: none; }
.municipality-boundary { pointer-events: auto; transition: all 0.15s ease; }
.municipality-boundary, .province-boundary { vector-effect: non-scaling-stroke; }
.municipality-boundary:focus { outline: none; }
.municipality-boundary:focus-visible { outline: 2.5px solid #1e40af; outline-offset: 1px; }
/* 호버·클릭(선택) 시 지역이 살짝 들리는 효과 (js/map.js liftCity 가 만드는 복제본) */
.city-lift { fill: #dbeafe; stroke: #2563eb; stroke-width: 2; vector-effect: non-scaling-stroke; pointer-events: none; transform-box: fill-box; transform-origin: center; animation: cityLift 0.2s ease-out forwards; }
@keyframes cityLift { from { transform: translateY(0); filter: drop-shadow(0 0 0 rgba(30, 58, 138, 0)); } to { transform: translateY(-4px); filter: drop-shadow(0 6px 6px rgba(30, 58, 138, 0.3)); } }
.city-lift.no-anim { animation: none; transform: translateY(-4px); filter: drop-shadow(0 6px 6px rgba(30, 58, 138, 0.3)); }
@media (prefers-reduced-motion: reduce) { .city-lift { animation: none; transform: translateY(-4px); filter: drop-shadow(0 6px 6px rgba(30, 58, 138, 0.3)); } }

.region-label { font-size: 16px; font-weight: 600; fill: #1e2a55; pointer-events: auto; text-anchor: middle; dominant-baseline: middle; paint-order: stroke; stroke: rgba(255,255,255,0.7); stroke-width: 3px; stroke-linejoin: round; cursor: pointer; user-select: none; -webkit-user-select: none; }
.region-label:focus { outline: none; }
.region-label:focus-visible { outline: 2px solid #1e40af; outline-offset: 2px; }
body[data-region="seoul"] .region-label { font-size: 14px; }

/* 우측 정보 패널 */
.info-side { flex: 1; background: #fff; padding: 20px 55px 55px 55px; display: flex; flex-direction: column; justify-content: center; overflow-y: auto; height: 100%; }
.info-content { width: 100%; }

.info_title { font-size: 2rem; font-weight: 800; color: #111; padding-bottom: 18px; margin-bottom: 26px; position: relative; }
.info_title::after { content: ""; position: absolute; left: 0; bottom: 0; width: 60px; height: 3px; background: #1d5fe0; }

.info_rows { display: flex; flex-direction: column; gap: 8px; }
.info_row { display: flex; align-items: center; gap: 12px; }
.info_label { flex: 0 0 110px; white-space: nowrap; display: flex; align-items: center; gap: 8px; padding-left: 10px; font-size: 1.25rem; font-weight: 500; color: #1d4ed8; }
.info_label img { flex-shrink: 0; width: 18px; height: 20px; object-fit: contain; } /* 아이콘: /map/images/icon01~05.png */
.info_value { flex: 1; display: flex; align-items: center; justify-content: space-between; min-height: 34px; padding: 4px 10px 4px 24px; background: #fff; border: 1px solid #e3e8f0; border-radius: 20px; font-size: 1rem; font-weight: 700; color: #111; }

.info_row.is_alert { background: #fff0f2; border-radius: 8px; }
.info_row.is_alert .info_label,
.info_row.is_alert .info_value { color: #e5222d; }
.info_row.is_alert .info_value { background: transparent; border-color: transparent; }
.info_badge { font-style: normal; font-size: 1rem; font-weight: 700; color: #fff; background: #e5222d; padding: 3px 10px; border-radius: 20px; white-space: nowrap; }

.info_note { text-align: right; font-size: 1rem; color: #e5222d; margin: 18px 0 26px; line-height: 1.3;}

.info_btns { display: flex; gap: 10px; }
.info_btn { flex: 1; display: flex; align-items: center; justify-content: center; gap: 8px; height: 42px; padding: 0 10px; border: 1px solid #1d5fe0; border-radius: 4px; background: #fff; font-family: inherit; font-size: 1.15rem; font-weight: 700; color: #1e3a8a; white-space: nowrap; cursor: pointer; transition: 0.2s; }
.info_btn:hover { background: #1554d1; border-color: #1554d1; color: #fff; } /* 기본: 흰 배경 + 파란 테두리, 호버: 파란 배경 */
.info_btn img { flex-shrink: 0; width: 22px; height: 24px; object-fit: contain; transition: 0.2s; } /* 아이콘: /map/images/icon06~08.png */
.info_btn:hover img { filter: brightness(0) invert(1); } /* 호버 시 파란 아이콘을 흰색으로 */

/* 지도 대신 보여줄 지역 목록 (1024px 이하에서만 표시) */
.mobile-district-list { display: none; }
.mobile-district-item { flex-shrink: 0; white-space: nowrap; padding: 10px 16px; border-radius: 999px; border: 1.5px solid #e2e8f0; background: #ffffff; font-family: inherit; font-size: 14px; font-weight: 600; color: #0f172a; cursor: pointer; transition: all 0.15s ease; }
.mobile-district-item:hover { border-color: #94a3b8; background: #f8fafc; }
.mobile-district-item.active { border-color: #2563eb; background: #dbeafe; color: #1e3a8a; }

/* ===== 경기도 선택 허브 (남부/북부 페이지 이동) ===== */
.hub-wrapper { display: flex; align-items: center; justify-content: center; padding: 50px 30px; background: #fff; border: 1px solid #e3e8f0; border-radius: 10px; box-shadow: 0 10px 30px -10px rgba(30, 58, 138, 0.15); }
.hub-cards { display: flex; gap: 24px; flex-wrap: wrap; justify-content: center; max-width: 720px; }
.hub-card { width: 300px; background: #ffffff; border: 1px solid #e2e8f0; border-radius: 16px; padding: 32px 28px; text-decoration: none; box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05); transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease; }
.hub-card:hover { transform: translateY(-4px); border-color: #93c5fd; box-shadow: 0 12px 24px -8px rgba(37, 99, 235, 0.25); }
.hub-card-icon { width: 48px; height: 48px; border-radius: 12px; background: #dbeafe; color: #2563eb; display: flex; align-items: center; justify-content: center; margin-bottom: 20px; }
.hub-card-icon svg { width: 24px; height: 24px; }
.hub-card-title { font-size: 20px; font-weight: 700; color: #0f172a; margin-bottom: 8px; }
.hub-card-desc { font-size: 14px; color: #64748b; line-height: 1.5; margin-bottom: 16px; }
.hub-card-arrow { font-size: 14px; font-weight: 600; color: #2563eb; }

@media (max-width: 1279px) {
  .map_hero .map_back_btn { right: 40px; }
  .map_hero .map_inner { padding: 0 40px; }
  .info-side { padding: 40px 35px; }
  .info_title { font-size: 1.6rem; }
  .info_btns { flex-wrap: wrap; }
  .info_btn_primary { flex-basis: 100%; }
}

@media (max-width: 1024px) {
  .map_hero .map_back_btn { right: 0; }
  /* 1024px 이하에서는 지도를 숨기고, 그 자리에 지역 목록을 대신 보여준다 */
  .map_hero { margin-top: 76px; padding: 25px 0 120px; }
  .map_hero .map_inner { padding: 0; }
  .wrapper { flex-direction: column; height: auto; }
  .map-side { display: none; }
  .mobile-district-list { display: flex; flex-wrap: nowrap; overflow-x: auto; -webkit-overflow-scrolling: touch; gap: 10px; padding: 20px; background: #f3f7fd; border-bottom: 1px solid #e3e8f0; }
  .info-side { height: auto; padding: 30px 24px; }
}

@media (max-width: 767px) {
  .map_back_btn { padding: 5px 12px; font-size: 0.8rem; }
  .map_hero { padding: 20px 0 100px; }
  .map_breadcrumb { margin-bottom: 24px; font-size: 0.8rem; }
  .map_hero_region { font-size: 1.25rem; }
  .map_hero_city { font-size: 2.75rem; margin-bottom: 16px; }
  .map_hero_desc { font-size: 0.875rem; }
  .map_hero_desc br { display: none; }
  .map_area .map_inner { margin-top: -60px; }
  .info_title { font-size: 1.4rem; }
  .info_label { flex-basis: 92px; padding-left: 6px; font-size: 0.875rem; }
  .info_value { padding-left: 14px; font-size: 0.875rem; }
  .info_badge { font-size: 0.7rem; padding: 2px 7px; }
  .info_btn { font-size: 0.8rem; }
}
