/* ==========================================================================
   오솔킹 (OSOLKING) 이번주 어디갈까? 전용 스타일
   ========================================================================== */

.recommend-page {
  background-color: #f8fafc;
}

/* --------------------------------------------------------------------------
   1. 헤더 & 필터 바
   -------------------------------------------------------------------------- */
.recommend-header {
  margin-bottom: 20px;
}

.recommend-header .header-nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.recommend-stats-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background-color: #ecfdf5;
  border: 1px solid #a7f3d0;
  border-radius: 9999px;
  color: #065f46;
  font-size: 12.5px;
  font-weight: 700;
}

.recommend-filter-section {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  padding: 16px 20px;
  margin-bottom: 20px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
}

.recommend-filter-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.recommend-filter-row:last-child {
  margin-bottom: 0;
}

.filter-row-label {
  font-size: 13px;
  font-weight: 800;
  color: #1e293b;
  min-width: 72px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.filter-pills-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  flex: 1;
}

.rec-pill {
  padding: 5px 12px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 9999px;
  color: #475569;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.rec-pill:hover {
  background: #e2e8f0;
  color: #0f172a;
}

.rec-pill.is-active {
  background: #1e3a8a;
  border-color: #1e3a8a;
  color: #ffffff;
  box-shadow: 0 2px 4px rgba(30, 58, 138, 0.2);
}

.rec-pill[data-diff="초급"].is-active {
  background: #16a34a;
  border-color: #16a34a;
}

.rec-pill[data-diff="초중급"].is-active,
.rec-pill[data-diff="중급"].is-active {
  background: #2563eb;
  border-color: #2563eb;
}

.rec-pill[data-diff="중상급"].is-active,
.rec-pill[data-diff="상급"].is-active {
  background: #dc2626;
  border-color: #dc2626;
}

/* --------------------------------------------------------------------------
   2. 메인 2단 분할 레이아웃 (지도 vs 상세 뷰어)
   -------------------------------------------------------------------------- */
.recommend-layout-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-bottom: 40px;
}

@media (min-width: 960px) {
  .recommend-layout-grid {
    grid-template-columns: 1.15fr 0.85fr;
    align-items: start;
  }
}

/* 좌측: 대한민국 전체 지도 카드 */
.map-explore-card {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.03);
  position: relative;
  display: flex;
  flex-direction: column;
}

.map-card-header {
  padding: 14px 18px;
  background: #ffffff;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  z-index: 5;
}

.map-header-title {
  font-size: 14px;
  font-weight: 800;
  color: #0f172a;
  display: flex;
  align-items: center;
  gap: 6px;
}

.map-header-tools {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-reset-map {
  padding: 5px 10px;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  color: #334155;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all 0.15s;
}

.btn-reset-map:hover {
  background: #e2e8f0;
  color: #0f172a;
}

/* GPS 검색 및 추출 도구 링크 버튼 */
.btn-gps-tool-link {
  height: 28px;
  padding: 0 10px;
  background: #f0fdf4;
  border: 1px solid #86efac;
  color: #166534;
  border-radius: 6px;
  font-size: 11.5px;
  font-weight: 800;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all 0.15s ease;
}

.btn-gps-tool-link:hover {
  background: #dcfce7;
  color: #14532d;
  transform: translateY(-1px);
}

.map-container-wrap {
  position: relative;
  width: 100%;
  height: 540px;
  background: #e2e8f0;
}

@media (min-width: 960px) {
  .map-container-wrap {
    height: 640px;
  }
}

#all-spots-map {
  width: 100%;
  height: 100%;
}

/* 지도 클릭 시 나타나는 플로팅 GPS HUD */
.map-clicked-gps-hud {
  position: absolute;
  bottom: 14px;
  left: 14px;
  right: 14px;
  background: rgba(15, 23, 42, 0.94);
  backdrop-filter: blur(8px);
  color: #ffffff;
  padding: 10px 14px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 50;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.28);
  border: 1px solid rgba(56, 189, 248, 0.35);
  font-size: 13px;
  gap: 10px;
  animation: slideUpGps 0.2s ease-out;
}

@keyframes slideUpGps {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.gps-hud-left {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.gps-hud-left strong {
  color: #38bdf8;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 13.5px;
}

.gps-hud-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.btn-copy-gps {
  background: #0284c7;
  color: #ffffff;
  border: none;
  padding: 5px 12px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-copy-gps:hover {
  background: #0369a1;
  transform: scale(1.02);
}

.btn-close-gps {
  background: transparent;
  color: #94a3b8;
  border: none;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  transition: all 0.15s;
}

.btn-close-gps:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
}

/* 지도 위 클릭 핀 말풍선 오버레이 */
.clicked-coord-bubble {
  background: #0f172a;
  color: #ffffff;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 12px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
  border: 1.5px solid #38bdf8;
  white-space: nowrap;
  display: flex;
  flex-direction: column;
  gap: 4px;
  align-items: center;
  pointer-events: auto;
}

.coord-bubble-title {
  font-size: 11.5px;
  font-weight: 800;
  color: #38bdf8;
  display: flex;
  align-items: center;
  gap: 4px;
}

.coord-bubble-val {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 12px;
  color: #e2e8f0;
}

.coord-bubble-val strong {
  color: #ffffff;
}

.btn-bubble-copy {
  margin-top: 4px;
  background: #0284c7;
  color: #ffffff;
  border: none;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  cursor: pointer;
  transition: all 0.15s;
}

.btn-bubble-copy:hover {
  background: #0369a1;
}

/* 지도 범례 */
.map-legend-bar {
  padding: 10px 16px;
  background: #f8fafc;
  border-top: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: #64748b;
  flex-wrap: wrap;
  gap: 6px;
}

.legend-items {
  display: flex;
  align-items: center;
  gap: 12px;
}

.legend-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-weight: 600;
}

.legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
}

.dot-easy { background-color: #10b981; }
.dot-medium { background-color: #2563eb; }
.dot-hard { background-color: #ef4444; }

/* --------------------------------------------------------------------------
   3. 지도 커스텀 마커 & 툴팁
   -------------------------------------------------------------------------- */
.custom-spot-marker {
  position: relative;
  cursor: pointer;
  transition: transform 0.15s ease;
}

.custom-spot-marker:hover {
  transform: scale(1.35);
  z-index: 1000 !important;
}

.spot-pin-circle {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2.5px solid #ffffff;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.spot-pin-circle.diff-easy { background-color: #10b981; }
.spot-pin-circle.diff-medium { background-color: #2563eb; }
.spot-pin-circle.diff-hard { background-color: #ef4444; }

/* 활성 마커 펄스 효과 */
.custom-spot-marker.is-active .spot-pin-circle {
  transform: scale(1.4);
  box-shadow: 0 0 0 6px rgba(37, 99, 235, 0.4), 0 4px 8px rgba(0, 0, 0, 0.4);
  border-color: #facc15;
}

/* 마우스 호버 커스텀 툴팁 */
.spot-hover-tooltip {
  position: absolute;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(15, 23, 42, 0.95);
  color: #ffffff;
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 12px;
  white-space: nowrap;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
  pointer-events: none;
  z-index: 1001;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.spot-hover-tooltip::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 50%;
  transform: translateX(-50%);
  border-width: 5px 5px 0 5px;
  border-style: solid;
  border-color: rgba(15, 23, 42, 0.95) transparent transparent transparent;
}

.tooltip-top-line {
  display: flex;
  align-items: center;
  gap: 6px;
}

.tooltip-no {
  font-weight: 800;
  color: #60a5fa;
  font-size: 11px;
}

.tooltip-name {
  font-weight: 700;
  color: #ffffff;
  font-size: 12.5px;
}

.tooltip-sub {
  font-size: 11px;
  color: #cbd5e1;
}

/* --------------------------------------------------------------------------
   4. 우측: 카카오맵 길찾기 및 트레킹 코스 상세 뷰어
   -------------------------------------------------------------------------- */
.detail-route-card {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 20px;
  padding: 22px;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.03);
  position: sticky;
  top: 24px;
}

/* 빈 상태 (선택 전) */
.route-empty-state {
  text-align: center;
  padding: 60px 20px;
}

.empty-icon {
  font-size: 48px;
  margin-bottom: 14px;
}

.empty-title {
  font-size: 17px;
  font-weight: 800;
  color: #0f172a;
  margin-bottom: 8px;
}

.empty-desc {
  font-size: 13.5px;
  color: #64748b;
  line-height: 1.5;
  max-width: 320px;
  margin: 0 auto;
}

/* 선택 후 상세 컨텐츠 */
.route-detail-wrap {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* 헤더 뱃지 및 제목 */
.detail-header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.detail-spot-title {
  font-size: 20px;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.3;
}

.detail-spot-location {
  font-size: 13px;
  color: #64748b;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
}



/* 단계별 코스 타임라인 */
.route-timeline-box {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 14px;
}

.timeline-title {
  font-size: 12px;
  font-weight: 800;
  color: #475569;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 5px;
}

.timeline-steps {
  display: flex;
  flex-direction: column;
  gap: 8px;
  position: relative;
  padding-left: 10px;
}

.timeline-step-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  color: #1e293b;
}

.step-node-icon {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 800;
  flex-shrink: 0;
}

.node-start { background: #dbeafe; color: #1d4ed8; }
.node-via { background: #fef3c7; color: #b45309; }
.node-dest { background: #fee2e2; color: #dc2626; }

/* 주소 박스 */
.detail-addr-boxes {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.addr-card-item {
  background: #f8fafc;
  border: 1px solid #f1f5f9;
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 12.5px;
  line-height: 1.4;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.addr-text-wrap {
  display: flex;
  align-items: flex-start;
  gap: 6px;
  word-break: break-all;
}

.btn-copy-addr {
  background: none;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 600;
  color: #475569;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.15s;
}

.btn-copy-addr:hover {
  background: #ffffff;
  color: #0f172a;
  border-color: #94a3b8;
}

/* 주요 매력 및 팁 */
.detail-attraction-box {
  background: #f0fdf4;
  border-left: 3px solid #22c55e;
  padding: 8px 12px;
  border-radius: 0 8px 8px 0;
  font-size: 12.5px;
  color: #166534;
  line-height: 1.45;
  font-weight: 500;
}

.detail-tip-box {
  background: #fffbeb;
  border: 1px solid #fef3c7;
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 12px;
  color: #92400e;
  line-height: 1.45;
}

/* 액션 버튼 그룹 */
.detail-actions-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}

.btn-trekking-kakao {
  width: 100%;
  height: 46px;
  background-color: #fee500;
  color: #000000;
  border: none;
  border-radius: 12px;
  font-size: 13.5px;
  font-weight: 800;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
  transition: all 0.2s ease;
  box-sizing: border-box;
}

.btn-trekking-kakao:hover {
  background-color: #fdd835;
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.12);
}

.btn-trekking-naver {
  width: 100%;
  height: 44px;
  background-color: #03c75a;
  color: #ffffff;
  border: none;
  border-radius: 12px;
  font-size: 13.5px;
  font-weight: 800;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(3, 199, 90, 0.2);
  transition: all 0.2s ease;
  box-sizing: border-box;
}


.btn-trekking-naver:disabled,
.btn-trekking-naver.is-disabled {
  background-color: #f1f5f9;
  color: #94a3b8;
  cursor: not-allowed;
  box-shadow: none;
  border: 1px solid #cbd5e1;
  transform: none !important;
  opacity: 0.85;
}

.btn-trekking-naver:hover:not(:disabled) {
  background-color: #02b350;
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(3, 199, 90, 0.3);
}


.btn-sub-action:disabled,
.btn-sub-action.is-disabled {
  background-color: #f1f5f9 !important;
  color: #94a3b8 !important;
  border-color: #cbd5e1 !important;
  cursor: not-allowed !important;
  box-shadow: none !important;
  pointer-events: none !important;
  opacity: 0.85;
}

.sub-actions-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.btn-sub-action {
  height: 38px;
  background-color: #f1f5f9;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 700;
  color: #334155;
  text-decoration: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  transition: all 0.15s;
  box-sizing: border-box;
}

.btn-sub-action:hover {
  background-color: #e2e8f0;
  color: #0f172a;
}

.btn-sub-weather {
  height: 38px;
  background-color: #2563eb;
  color: #ffffff;
  border: none;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  transition: all 0.15s;
  box-sizing: border-box;
}

.btn-sub-weather:hover {
  background-color: #1d4ed8;
}

/* --------------------------------------------------------------------------
   우측 상세 코스 미니맵 & 커스텀 마커 / HUD 스타일
   -------------------------------------------------------------------------- */
.route-map-container {
  width: 100%;
  border-radius: 14px;
  border: 1px solid #cbd5e1;
  overflow: hidden;
  background: #f8fafc;
  position: relative;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.route-map-header-hud {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: #ffffff;
  border-bottom: 1px solid #e2e8f0;
  font-size: 13px;
  font-weight: 700;
  color: #0f172a;
}

.hud-route-title {
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hud-arrow {
  color: #94a3b8;
  font-size: 12px;
}

.hud-route-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.hud-badge {
  background: #f1f5f9;
  color: #475569;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 11.5px;
  font-weight: 700;
}

.hud-badge-diff {
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 11.5px;
  font-weight: 800;
}

#route-kakao-map {
  width: 100%;
  height: 300px;
}

.route-map-legend {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 8px 12px;
  background: #f8fafc;
  border-top: 1px solid #e2e8f0;
  font-size: 11.5px;
  font-weight: 700;
  color: #475569;
}

.leg-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.leg-start {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #2563eb;
  border: 2px solid #ffffff;
  box-shadow: 0 0 0 1px #2563eb;
}

.leg-dest {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #dc2626;
  border: 2px solid #ffffff;
  box-shadow: 0 0 0 1px #dc2626;
}

.leg-line {
  width: 18px;
  height: 3px;
  background: #ef4444;
  border-radius: 2px;
}

/* 커스텀 핀 (말풍선 배지) */
.trek-custom-pin {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  cursor: pointer;
  transform: translate3d(0, 0, 0);
  transition: transform 0.2s ease;
}

.trek-custom-pin:hover {
  transform: scale(1.08) translateY(-2px);
  z-index: 100 !important;
}

.trek-custom-pin .pin-bubble {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 9px;
  border-radius: 20px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.25);
  white-space: nowrap;
  font-size: 12px;
  font-weight: 800;
}

.trek-custom-pin.pin-start .pin-bubble {
  background: #1e40af;
  color: #ffffff;
  border: 2px solid #60a5fa;
}

.trek-custom-pin.pin-dest .pin-bubble {
  background: #991b1b;
  color: #ffffff;
  border: 2px solid #f87171;
}

.trek-custom-pin.pin-via .pin-bubble {
  background: #854d0e;
  color: #ffffff;
  border: 2px solid #fde047;
}

.pin-bubble .bubble-badge {
  font-size: 10px;
  padding: 2px 5px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.25);
  letter-spacing: -0.2px;
}

.pin-bubble .bubble-title {
  font-weight: 800;
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.pin-marker-arrow {
  width: 0;
  height: 0;
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  margin-top: -1px;
}

.trek-custom-pin.pin-start .pin-marker-arrow {
  border-top: 7px solid #1e40af;
}

.trek-custom-pin.pin-dest .pin-marker-arrow {
  border-top: 7px solid #991b1b;
}

.trek-custom-pin.pin-via .pin-marker-arrow {
  border-top: 7px solid #854d0e;
}

/* 타임라인 항목 클릭 가능 스타일 */
.timeline-step-item {
  cursor: pointer;
  padding: 6px 8px;
  border-radius: 8px;
  transition: background 0.15s;
}

.timeline-step-item:hover {
  background: #f1f5f9;
}

.step-text-group {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.step-role-tag {
  font-size: 10.5px;
  color: #64748b;
  font-weight: 700;
}

.step-name-text {
  font-size: 13.5px;
  color: #0f172a;
}



