/* ══════════════════════════════════════
   라원 안내도 — dgw (donggungwon widget)
   ══════════════════════════════════════ */

:root {
  --gold: #FFD23C;
  --pink: #FF6987;
  --bg: #eef0f4;
  --white: #ffffff;
  --dark: #1a2236;
  --text: #2d3748;
  --muted: #8896aa;
  --border: #dde2ea;
  --panel: #f4f6f9;
}


/* ── Card header (세이지 그린 파스텔) ── */

.dgw-card-head {
  flex-shrink: 0;
  background: var(--dg-primary-gradient);
  border-radius: 14px;
  padding: .5rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: 0 2px 12px rgba(0,0,0,.06);
  border-bottom: none;
}

.dgw-head-icon {
  width: 38px; height: 38px;
  background: rgba(45,74,30,.10);
  border: none;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; flex-shrink: 0; color: #2d4a1e;
}

.dgw-head-text {
  display: flex; flex-direction: column; gap: 2px; min-width: 0;
}

.dgw-head-eyebrow {
  font-size: 10px; font-weight: 700;
  color: rgba(45,74,30,.5);
  letter-spacing: 1.6px; text-transform: uppercase;
}

.dgw-head-title {
  font-size: 20px; font-weight: 800; color: #2d4a1e;
  letter-spacing: -0.3px; line-height: 1.15;
  font-family: 'Noto Serif KR', serif;
}

.dgw-head-desc {
  font-size: 12px; color: rgba(45,74,30,.5); margin-top: 2px;
}

.dgw-head-pills {
  margin-left: auto; display: flex; gap: 6px; flex-wrap: wrap;
  justify-content: flex-end;
}

.dgw-pill {
  padding: 5px 14px; border-radius: 20px;
  font-size: 11px; font-weight: 700; letter-spacing: .3px;
  display: inline-flex; align-items: center; gap: 5px;
}
.dgw-pill-pink {
  background: #FF6987; border: none; color: #fff;
}
.dgw-pill-gold {
  background: #e6a817; border: none; color: #fff;
}
.dgw-pill-dot { width: 6px; height: 6px; border-radius: 50%; }
.dgw-pill-pink .dgw-pill-dot { background: #fff; }
.dgw-pill-gold .dgw-pill-dot { background: #fff; }


/* ── Main body (지도 + 사이드바 좌우) ── */

.dgw-card-body {
  display: flex; gap: 12px; overflow: hidden;
  align-items: stretch;
}


/* ── 지도 영역 ── */

.dgw-map-col {
  flex: 1; min-width: 0;
  position: relative; overflow: hidden;
  border-radius: 14px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.10);
}

.dgw-map-inner {
  position: relative;
  display: inline-block;
  line-height: 0;
  min-width: 100%;
}

.dgw-map-img {
  display: block; width: 100%; height: auto;
}


/* ── 번호 마커 (전시+시설 스팟) ── */

.dgw-spot {
  position: absolute; transform: translate(-50%,-50%);
  cursor: pointer; z-index: 10;
}

.dgw-spot-ring {
  width: 44px; height: 44px;
  background: rgba(255,105,135,0.18);
  border: 2px solid rgba(255,105,135,0.52);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  transition: all .22s;
  animation: pulse 3.2s ease-in-out infinite;
}

.dgw-spot:hover .dgw-spot-ring {
  background: rgba(255,105,135,0.55);
  border-color: #FF6987;
  transform: scale(1.22); animation: none;
}

.dgw-spot-num {
  width: 22px; height: 22px; background: #FF6987;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 10px; font-weight: 700; color: #fff;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}

@keyframes pulse {
  0%,100% { box-shadow: 0 0 0 0 rgba(255,105,135,0.45); }
  50%     { box-shadow: 0 0 0 8px rgba(255,105,135,0); }
}


/* ── 편의시설 마커 (골드 아이콘만) ── */

.dgw-util {
  position: absolute; transform: translate(-50%,-50%);
  cursor: pointer; z-index: 11;
}

.dgw-util-badge {
  width: 26px; height: 26px; background: #FFD23C;
  border-radius: 5px;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.25);
  transition: transform .18s;
}
.dgw-util:hover .dgw-util-badge { transform: scale(1.28); }
.dgw-util-badge i { font-size: 13px; color: #1a1a1a; }


/* ── 지도 위 텍스트 라벨 ── */

.dgw-label {
  position: absolute; transform: translate(-50%,-50%);
  z-index: 8;
  font-size: 12px; font-weight: 700;
  color: rgba(255,255,255,.92);
  text-shadow: 0 1px 4px rgba(0,0,0,.6), 0 0 2px rgba(0,0,0,.4);
  white-space: nowrap; pointer-events: none;
  letter-spacing: .3px; text-align: center; line-height: 1.4;
  font-family: 'Noto Sans KR', sans-serif;
}


/* ── 툴팁 ── */

.dgw-tip {
  position: absolute; bottom: calc(100% + 7px); left: 50%;
  transform: translateX(-50%);
  background: rgba(26,34,54,0.95);
  border: 1px solid rgba(255,105,135,0.4);
  color: #fff; padding: 4px 10px; border-radius: 7px;
  font-size: 11px; font-weight: 600; white-space: nowrap;
  opacity: 0; pointer-events: none; transition: opacity .15s;
  z-index: 60;
}
.dgw-tip::after {
  content: ''; position: absolute; top: 100%; left: 50%;
  transform: translateX(-50%);
  border: 4px solid transparent;
  border-top-color: rgba(255,105,135,0.4);
}
.dgw-spot:hover .dgw-tip,
.dgw-util:hover .dgw-tip { opacity: 1; }


/* ── 사이드바 ── */

.dgw-sidebar {
  width: 340px; flex-shrink: 0;
  display: flex; flex-direction: column;
  gap: 10px; overflow: hidden;
  align-self: stretch;
}


/* ── 섹션 카드 공통 ── */

.dgw-sec-card {
  background: var(--white);
  border-radius: 14px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.07);
  display: flex; flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--border);
}

.dgw-sec-head {
  display: flex; align-items: center; gap: 8px;
  padding: 11px 14px 10px;
  background: var(--panel);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.dgw-sec-bar {
  width: 3px; height: 15px; border-radius: 2px; flex-shrink: 0;
}
.dgw-sec-bar.dgw-pink { background: #FF6987; }
.dgw-sec-bar.dgw-gold { background: #FFD23C; }

.dgw-sec-title {
  font-size: 13.5px; font-weight: 700;
  color: var(--text); letter-spacing: .2px;
}

.dgw-sec-badge {
  margin-left: auto;
  font-size: 10px; font-weight: 700; color: var(--muted);
  background: var(--bg);
  border: 1px solid var(--border);
  padding: 2px 8px; border-radius: 10px;
}


/* ══════════════════════════════════════
   디테일 카드 (사이드바 상단)
   ══════════════════════════════════════ */

.dgw-detail-card {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-height: 0;
}

.dgw-detail-img-wrap {
  position: relative;
  flex-shrink: 0;
  height: 200px;
  overflow: hidden;
}

.dgw-detail-img {
  display: block; width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.dgw-detail-card:hover .dgw-detail-img {
  transform: scale(1.03);
}

.dgw-detail-img-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to bottom, transparent 40%, rgba(10,14,26,0.75) 100%);
  pointer-events: none;
}

.dgw-detail-badge-wrap {
  position: absolute; bottom: 12px; left: 12px;
  display: flex; align-items: center; gap: 7px;
}

.dgw-detail-num {
  width: 26px; height: 26px;
  background: #FF6987; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700; color: #fff;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(0,0,0,0.35);
}
.dgw-detail-num:empty { display: none; }

.dgw-detail-hall {
  font-size: 11px; font-weight: 700;
  color: rgba(255,255,255,0.9);
  letter-spacing: 0.3px;
  text-shadow: 0 1px 4px rgba(0,0,0,0.5);
}

.dgw-detail-body {
  flex: 1;
  padding: 16px 16px 12px;
  display: flex; flex-direction: column; gap: 10px;
  overflow-y: auto; min-height: 0;
}
.dgw-detail-body::-webkit-scrollbar { width: 3px; }
.dgw-detail-body::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }

.dgw-detail-time-row {
  display: flex; align-items: center; gap: 6px;
  font-size: 11px; font-weight: 700; color: #FF6987;
}
.dgw-detail-time-row i { font-size: 9px; }

.dgw-detail-title {
  font-size: 14.5px; font-weight: 700;
  color: var(--text); line-height: 1.5; letter-spacing: -0.2px;
}

.dgw-detail-divider {
  height: 1px; background: var(--border); flex-shrink: 0;
}

.dgw-detail-desc {
  font-size: 12.5px; color: var(--muted);
  line-height: 1.7; font-weight: 400;
}

.dgw-detail-hint {
  flex-shrink: 0;
  padding: 9px 14px;
  background: var(--panel);
  border-top: 1px solid var(--border);
  font-size: 10.5px; color: var(--muted);
  display: flex; align-items: center; gap: 6px;
}
.dgw-detail-hint i { color: #8ca078; font-size: 11px; }

/* 페이드 트랜지션 */
.dgw-detail-img,
.dgw-detail-title,
.dgw-detail-desc,
.dgw-detail-time-row,
.dgw-detail-hall,
.dgw-detail-num {
  transition: opacity 0.25s ease;
}
.dgw-detail-card.dgw-updating .dgw-detail-img,
.dgw-detail-card.dgw-updating .dgw-detail-title,
.dgw-detail-card.dgw-updating .dgw-detail-desc,
.dgw-detail-card.dgw-updating .dgw-detail-time-row,
.dgw-detail-card.dgw-updating .dgw-detail-hall,
.dgw-detail-card.dgw-updating .dgw-detail-num {
  opacity: 0;
}


/* ══════════════════════════════════════
   편의시설 (사이드바 하단)
   ══════════════════════════════════════ */

.dgw-sidebar .dgw-amenity {
  flex-shrink: 0;
}

.dgw-amenity-body { padding: 8px 10px; }

.dgw-amenity-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}

.dgw-a-item {
  display: flex; align-items: center; gap: 8px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 8px; padding: 7px 9px;
  cursor: pointer;
  transition: background .15s, border-color .15s;
}
.dgw-a-item:hover {
  background: rgba(255,210,60,0.08);
  border-color: rgba(255,210,60,0.4);
}
.dgw-a-item.dgw-active {
  background: rgba(255,210,60,0.18);
  border-color: rgba(255,210,60,0.7);
}

.dgw-a-icon {
  width: 26px; height: 26px; background: #FFD23C;
  border-radius: 5px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.dgw-a-icon i { font-size: 13px; color: #1a1a1a; }

.dgw-a-name {
  font-size: 12px; color: var(--text);
  font-weight: 500; line-height: 1.25;
}


/* ══════════════════════════════════════
   반응형 — 태블릿 (≤ 900px)
   ══════════════════════════════════════ */

@media (max-width: 900px) {

  html, body { overflow-x: hidden !important; }

  .dgw-card-head { padding: 10px 14px; gap: 10px; }
  .dgw-head-pills { display: none; }
  .dgw-head-desc  { display: none; }
  .dgw-head-title { font-size: 16px; }
  .dgw-head-icon  { width: 32px; height: 32px; font-size: 18px; }

  .dgw-card-body {
    flex-direction: column !important;
    align-items: stretch !important;
    overflow: hidden !important;
    gap: 10px;
  }

  .dgw-map-col {
    flex: none !important;
    width: 100% !important;
    height: 420px !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    -webkit-overflow-scrolling: touch;
    border-radius: 10px;
  }
  .dgw-map-img {
    width: auto !important;
    height: 420px !important;
    min-width: 900px !important;
    max-width: none !important;
  }

  .dgw-sidebar {
    width: 100% !important;
    overflow: hidden !important;
    gap: 8px;
  }

  .dgw-sec-card {
    width: 100% !important;
    border-radius: 10px;
  }

  .dgw-amenity-grid {
    grid-template-columns: repeat(3, 1fr) !important;
  }

  .dgw-label { font-size: 11px; }

  .dgw-tip {
    white-space: nowrap !important;
    z-index: 9999 !important;
  }

  .dgw-detail-img-wrap { height: 160px; }
  .dgw-detail-body { padding: 12px 12px 10px; }
}

/* ── 시설 마커 (이름 표시, 틸 컬러) ── */
.dgw-fspot {
  position: absolute; transform: translate(-50%,-50%);
  cursor: pointer; z-index: 10;
  display: flex; flex-direction: column;
  align-items: center; gap: 3px;
}
.dgw-fspot-badge {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 10px;
  background: rgba(38,166,154,.85);
  border: 2px solid rgba(38,166,154,.5);
  border-radius: 16px;
  box-shadow: 0 2px 8px rgba(0,0,0,.25);
  transition: all .22s;
  animation: fpulse 3.2s ease-in-out infinite;
}
.dgw-fspot:hover .dgw-fspot-badge {
  background: rgba(38,166,154,.95);
  border-color: #26a69a;
  transform: scale(1.1);
  animation: none;
}
.dgw-fspot-badge i {
  font-size: 11px; color: #fff;
}
.dgw-fspot-name {
  font-size: 10px; font-weight: 700;
  color: #fff; white-space: nowrap;
  letter-spacing: .2px;
}
@keyframes fpulse {
  0%,100% { box-shadow: 0 0 0 0 rgba(38,166,154,0.45); }
  50%     { box-shadow: 0 0 0 8px rgba(38,166,154,0); }
}

/* 툴팁 — 시설 마커 */
.dgw-fspot .dgw-tip {
  border-color: rgba(38,166,154,0.4);
}
.dgw-fspot .dgw-tip::after {
  border-top-color: rgba(38,166,154,0.4);
}
.dgw-fspot:hover .dgw-tip { opacity: 1; }

/* 반응형 */
@media (max-width: 900px) {
  .dgw-fspot-badge { padding: 3px 8px; }
  .dgw-fspot-badge i { font-size: 10px; }
  .dgw-fspot-name { font-size: 9px; }
}
@media (max-width: 480px) {
  .dgw-fspot-badge { padding: 2px 6px; gap: 3px; }
  .dgw-fspot-name { font-size: 8px; }
}

/* ══════════════════════════════════════
   반응형 — 모바일 (≤ 480px)
   ══════════════════════════════════════ */

@media (max-width: 480px) {

  .dgw-head-title { font-size: 15px; }

  .dgw-amenity-grid {
    grid-template-columns: repeat(3, 1fr) !important;
  }

  .dgw-spot-ring  { width: 30px; height: 30px; }
  .dgw-spot-num   { width: 17px; height: 17px; font-size: 8px; }
  .dgw-util-badge { width: 20px; height: 20px; }
  .dgw-util-badge i { font-size: 10px; }

  .dgw-tip   { font-size: 10px; padding: 3px 8px; }
  .dgw-label { font-size: 10px; }
}