/* 모두의 장지 - 프리미엄 디자인 시스템 스타일시트 */

/* 1. 디자인 시스템 변수 정의 */
:root {
  --primary-color: #1b4332;       /* Deep Forest Green (평온함, 신뢰) */
  --primary-hover: #0f2a1f;
  --secondary-color: #c5a880;     /* Antique Gold / Bronze (고급스러움) */
  --secondary-hover: #b4966d;
  --accent-color: #2d6a4f;        /* Accent Green */
  --danger-color: #b00020;
  
  --bg-warm-ivory: #fcfbfa;       /* 메인 배경색 */
  --bg-soft-gray: #f4f1ea;        /* 카드 및 레이어 배경색 */
  --text-dark: #2c3531;           /* 주요 텍스트 */
  --text-muted: #5e6b65;          /* 부가 설명 텍스트 */
  --text-light: #ffffff;
  
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 8px 20px rgba(27, 67, 50, 0.08);
  --shadow-lg: 0 15px 35px rgba(27, 67, 50, 0.15);
  --shadow-inset: inset 0 2px 4px rgba(0, 0, 0, 0.06);
  
  --border-radius-sm: 8px;
  --border-radius-md: 16px;
  --border-radius-lg: 24px;
  
  --transition-smooth: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  --transition-fast: all 0.15s ease-in-out;
  
  --font-serif: 'Noto Serif KR', Georgia, serif;
  --font-sans: 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, Roboto, sans-serif;
}

/* 2. 기본 리셋 및 전역 스타일 */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-warm-ivory);
  color: var(--text-dark);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 600;
  color: var(--primary-color);
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: var(--font-sans);
  outline: none;
}

ul {
  list-style: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* 3. 헤더 및 내비게이션 */
.main-header {
  background: rgba(252, 251, 250, 0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(27, 67, 50, 0.08);
  position: sticky;
  top: 0;
  z-index: 100;
  height: 80px;
}

.header-container {
  max-width: 1400px;
  margin: 0 auto;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
}

.logo-icon {
  font-size: 28px;
  color: var(--primary-color);
}

.logo h1 {
  font-size: 24px;
  display: flex;
  align-items: flex-end;
  gap: 6px;
}

.logo-sub {
  font-size: 13px;
  background: var(--secondary-color);
  color: var(--text-light);
  padding: 2px 6px;
  border-radius: 4px;
  font-family: var(--font-sans);
  font-weight: 500;
  margin-bottom: 3px;
}

.main-nav ul {
  display: flex;
  gap: 10px;
}

.nav-item {
  padding: 10px 18px;
  border-radius: var(--border-radius-sm);
  font-weight: 500;
  font-size: 15px;
  color: var(--text-muted);
  transition: var(--transition-fast);
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.nav-item i {
  font-size: 16px;
}

.nav-item:hover {
  background: var(--bg-soft-gray);
  color: var(--primary-color);
}

.nav-item.active {
  background: var(--primary-color);
  color: var(--text-light);
}

.btn-header-call {
  background: linear-gradient(135deg, var(--secondary-color), var(--secondary-hover));
  color: var(--text-light);
  padding: 12px 20px;
  border-radius: var(--border-radius-sm);
  font-weight: 600;
  font-size: 14px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-smooth);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-header-call:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(197, 168, 128, 0.4);
}

/* 4. 메인 콘텐츠 및 탭 전환 관리 */
.content-wrapper {
  max-width: 1400px;
  margin: 0 auto;
  padding: 24px;
  min-height: calc(100vh - 180px);
}

.tab-content {
  display: none;
  animation: fadeIn 0.4s ease;
}

.tab-content.active-section {
  display: block;
}

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

/* 5. 메인 검색 탭 레이아웃 */
#search-section {
  display: none;
}
#search-section.active-section {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* 상단 필터바 */
.search-filter-bar {
  background: var(--text-light);
  border-radius: var(--border-radius-md);
  padding: 20px 24px;
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(27, 67, 50, 0.05);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 24px;
}

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

.btn-location-action {
  background: var(--primary-color);
  color: var(--text-light);
  padding: 12px 18px;
  border-radius: var(--border-radius-sm);
  font-weight: 600;
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition-fast);
}

.btn-location-action:hover {
  background: var(--primary-hover);
}

.location-search-wrapper {
  display: flex;
  align-items: center;
  border: 1.5px solid var(--bg-soft-gray);
  background-color: var(--bg-warm-ivory);
  border-radius: var(--border-radius-sm);
  overflow: hidden;
  transition: var(--transition-fast);
  width: 290px;
}

.location-search-wrapper:focus-within {
  border-color: var(--primary-color);
  background-color: var(--text-light);
  box-shadow: 0 0 0 3px rgba(27, 67, 50, 0.1);
}

.input-premium-address {
  border: none;
  background: transparent;
  padding: 11px 16px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-dark);
  outline: none;
  flex-grow: 1;
  width: 100%;
}

.btn-address-search-submit {
  border: none;
  background: transparent;
  padding: 0 16px;
  color: var(--primary-color);
  font-size: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-fast);
}

.btn-address-search-submit:hover {
  color: var(--secondary-color);
  transform: scale(1.1);
}

.filter-divider {
  width: 1px;
  height: 40px;
  background-color: rgba(27, 67, 50, 0.1);
}

.filter-options {
  display: flex;
  align-items: center;
  flex-grow: 1;
  gap: 32px;
  flex-wrap: wrap;
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.filter-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.checkbox-group {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.checkbox-premium {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  user-select: none;
}

.checkbox-premium input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

.checkbox-custom {
  position: relative;
  height: 18px;
  width: 18px;
  background-color: var(--bg-soft-gray);
  border-radius: 4px;
  border: 1.5px solid rgba(27, 67, 50, 0.2);
  transition: var(--transition-fast);
}

.checkbox-premium:hover input ~ .checkbox-custom {
  border-color: var(--primary-color);
}

.checkbox-premium input:checked ~ .checkbox-custom {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
}

.checkbox-custom:after {
  content: "";
  position: absolute;
  display: none;
  left: 5px;
  top: 1px;
  width: 5px;
  height: 10px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.checkbox-premium input:checked ~ .checkbox-custom:after {
  display: block;
}

/* 스플릿 레이아웃 */
.split-layout {
  display: flex;
  gap: 20px;
  height: 680px;
}

/* 좌측 리스트 패널 */
.list-panel {
  width: 420px;
  background: var(--text-light);
  border-radius: var(--border-radius-md);
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(27, 67, 50, 0.05);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  flex-shrink: 0;
}

.list-header {
  padding: 20px 24px;
  border-bottom: 1px solid rgba(27, 67, 50, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.list-header h3 {
  font-size: 18px;
}

.list-count {
  font-size: 14px;
  background: var(--bg-soft-gray);
  color: var(--primary-color);
  padding: 2px 8px;
  border-radius: 20px;
  font-family: var(--font-sans);
  font-weight: 700;
  margin-left: 6px;
}

.sort-indicator {
  font-size: 12px;
  color: var(--secondary-color);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
}

.cemetery-list-container {
  overflow-y: auto;
  flex-grow: 1;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* 리스트 아이템 카드 */
.cemetery-card {
  background: var(--bg-warm-ivory);
  border: 1px solid rgba(27, 67, 50, 0.06);
  border-radius: var(--border-radius-sm);
  padding: 16px;
  cursor: pointer;
  transition: var(--transition-smooth);
  display: flex;
  flex-direction: column;
  gap: 10px;
  position: relative;
}

.cemetery-card:hover {
  background: var(--text-light);
  border-color: var(--secondary-color);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.cemetery-card.active {
  background: var(--bg-soft-gray);
  border-color: var(--primary-color);
  box-shadow: var(--shadow-sm);
}

.card-top-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.card-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 20px;
  color: var(--text-light);
}

.card-badge.봉안당 { background-color: var(--secondary-color); }
.card-badge.수목장 { background-color: var(--accent-color); }
.card-badge.해양장 { background-color: #0077b6; }
.card-badge.기타 { background-color: #6c757d; }
.card-badge.종합 { background-color: #d81159; }

.card-badges-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.distance-badge {
  font-size: 13px;
  font-weight: 700;
  color: var(--primary-color);
  background: rgba(27, 67, 50, 0.08);
  padding: 2px 8px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  gap: 4px;
}

.cemetery-card h4 {
  font-size: 16px;
  color: var(--primary-color);
}

.card-address {
  font-size: 12px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 4px;
}

.card-price-summary {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-dark);
  border-top: 1px dashed rgba(27, 67, 50, 0.1);
  padding-top: 8px;
  margin-top: 4px;
}

.card-cta-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--secondary-color);
  font-weight: 700;
}

.card-duration-info {
  color: var(--accent-color);
  display: flex;
  align-items: center;
  gap: 4px;
}

.no-results {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-muted);
}

.no-results i {
  font-size: 40px;
  margin-bottom: 12px;
  opacity: 0.3;
}

/* 우측 지도 패널 */
.map-panel {
  flex-grow: 1;
  border-radius: var(--border-radius-md);
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(27, 67, 50, 0.05);
  overflow: hidden;
  position: relative;
}

#map {
  width: 100%;
  height: 100%;
  z-index: 1;
}

/* 지도 범례 */
.map-legend {
  position: absolute;
  bottom: 24px;
  left: 24px;
  z-index: 10;
  background: rgba(252, 251, 250, 0.95);
  backdrop-filter: blur(8px);
  padding: 12px 18px;
  border-radius: var(--border-radius-sm);
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(27, 67, 50, 0.1);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-dark);
}

.legend-icon {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  font-size: 11px;
}

.legend-icon.urn { background-color: var(--secondary-color); }
.legend-icon.tree { background-color: var(--accent-color); }
.legend-icon.wave { background-color: #0077b6; }
.legend-icon.pin { background-color: #6c757d; }
.legend-icon.complex { background-color: #d81159; }

/* 6. 지도 내 커스텀 마커 아이콘 */
.custom-marker {
  display: flex;
  align-items: center;
  justify-content: center;
  background: white;
  border-radius: 50%;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
  width: 40px;
  height: 40px;
  border: 3.5px solid;
  transition: all 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.custom-marker i {
  font-size: 14px;
  transition: var(--transition-fast);
}

.custom-marker.urn-marker {
  border-color: var(--secondary-color);
  color: var(--secondary-color);
}
.custom-marker.tree-marker {
  border-color: var(--accent-color);
  color: var(--accent-color);
}
.custom-marker.wave-marker {
  border-color: #0077b6;
  color: #0077b6;
}
.custom-marker.pin-marker {
  border-color: #6c757d;
  color: #6c757d;
}
.custom-marker.complex-marker {
  border-color: #d81159;
  color: #d81159;
}

.custom-marker:hover, .custom-marker.active-marker {
  transform: scale(1.2) translateY(-4px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.3);
  z-index: 1000 !important;
}

.custom-marker.active-marker {
  background: var(--primary-color);
}
.custom-marker.active-marker i {
  color: white;
}

/* 7. 장례/장지 가이드 탭 */
.section-header {
  text-align: center;
  max-width: 700px;
  margin: 20px auto 40px;
}

.section-header h2 {
  font-size: 32px;
  margin-bottom: 12px;
}

.section-header p {
  color: var(--text-muted);
  font-size: 16px;
}

.guide-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin-bottom: 40px;
}

.guide-card {
  background: var(--text-light);
  border-radius: var(--border-radius-md);
  padding: 32px;
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(27, 67, 50, 0.05);
  transition: var(--transition-smooth);
}

.guide-card:hover {
  transform: translateY(-5px);
  border-color: var(--secondary-color);
  box-shadow: var(--shadow-lg);
}

.guide-card-icon {
  font-size: 36px;
  color: var(--secondary-color);
  margin-bottom: 20px;
}

.guide-card h3 {
  font-size: 20px;
  margin-bottom: 12px;
}

.guide-card p {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.guide-card ul {
  border-top: 1px solid rgba(27, 67, 50, 0.08);
  padding-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.guide-card li {
  font-size: 13px;
  color: var(--text-dark);
}

/* 8. 1:1 상담 신청 탭 */
.consult-form-container {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 48px;
  background: var(--text-light);
  border-radius: var(--border-radius-md);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  border: 1px solid rgba(27, 67, 50, 0.05);
  margin-bottom: 40px;
}

.consult-info-block {
  background-color: var(--bg-soft-gray);
  padding: 48px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-right: 1px solid rgba(27, 67, 50, 0.05);
}

.consult-info-block h2 {
  font-size: 28px;
  margin-bottom: 8px;
}

.highlight-text {
  color: var(--accent-color);
  font-weight: 600;
  font-size: 16px;
  margin-bottom: 24px;
}

.consult-benefits {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.benefit-item {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.benefit-item i {
  color: var(--secondary-color);
  font-size: 20px;
  margin-top: 3px;
}

.benefit-item h4 {
  font-family: var(--font-sans);
  font-size: 16px;
  color: var(--primary-color);
  margin-bottom: 4px;
}

.benefit-item p {
  font-size: 13px;
  color: var(--text-muted);
}

.operator-call-card {
  margin-top: 32px;
  border-top: 1px solid rgba(27, 67, 50, 0.1);
  padding-top: 24px;
}

.call-desc {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.btn-large-call {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: var(--primary-color);
  color: var(--text-light);
  padding: 16px 24px;
  border-radius: var(--border-radius-sm);
  font-size: 16px;
  font-weight: 700;
  transition: var(--transition-smooth);
}

.btn-large-call:hover {
  background: var(--primary-hover);
  transform: translateY(-2px);
}

.consult-form-block {
  padding: 48px;
  position: relative;
}

.consult-form-block h3 {
  font-size: 22px;
  margin-bottom: 6px;
}

.form-sub-desc {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 24px;
}

/* 프리미엄 인풋 폼 공통 */
.premium-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

.required {
  color: var(--danger-color);
}

.premium-form input[type="text"],
.premium-form input[type="tel"],
.premium-form textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid rgba(27, 67, 50, 0.15);
  background-color: var(--bg-warm-ivory);
  border-radius: var(--border-radius-sm);
  font-size: 14px;
  font-family: var(--font-sans);
  color: var(--text-dark);
  outline: none;
  transition: var(--transition-fast);
}

.premium-form input:focus,
.premium-form textarea:focus {
  border-color: var(--secondary-color);
  background-color: var(--text-light);
  box-shadow: 0 0 0 3px rgba(197, 168, 128, 0.15);
}

.privacy-agreement {
  background: var(--bg-soft-gray);
  padding: 12px 16px;
  border-radius: var(--border-radius-sm);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.agreement-text {
  font-size: 13px;
  font-weight: 600;
}

.privacy-desc {
  font-size: 11px;
  color: var(--text-muted);
  padding-left: 26px;
}

.btn-submit-premium {
  background: linear-gradient(135deg, var(--secondary-color), var(--secondary-hover));
  color: var(--text-light);
  padding: 16px;
  border-radius: var(--border-radius-sm);
  font-size: 15px;
  font-weight: 700;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
}

.btn-submit-premium:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(197, 168, 128, 0.4);
}

.btn-submit-premium .btn-loading {
  display: none;
}

.btn-submit-premium.loading-state {
  pointer-events: none;
  opacity: 0.8;
}

.btn-submit-premium.loading-state .btn-text {
  display: none;
}

.btn-submit-premium.loading-state .btn-loading {
  display: inline-block;
}

/* 폼 전송 성공 오버레이 */
.form-success-overlay,
.panel-success-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(252, 251, 250, 0.98);
  backdrop-filter: blur(5px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 10;
  text-align: center;
  animation: fadeIn 0.3s ease;
}

.success-message {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  max-width: 320px;
}

.success-message i {
  font-size: 48px;
  color: var(--accent-color);
}

.success-message h3,
.success-message h4 {
  font-size: 22px;
}

.success-message p {
  font-size: 13px;
  color: var(--text-muted);
}

.btn-close-overlay {
  background: var(--primary-color);
  color: var(--text-light);
  padding: 10px 24px;
  border-radius: var(--border-radius-sm);
  font-weight: 600;
  font-size: 13px;
  transition: var(--transition-fast);
}

.btn-close-overlay:hover {
  background: var(--primary-hover);
}

/* 9. 고객 후기 및 FAQ 탭 */
.review-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
  margin-bottom: 60px;
}

.review-card {
  background: var(--text-light);
  border-radius: var(--border-radius-md);
  padding: 24px;
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(27, 67, 50, 0.05);
}

.review-rating {
  font-size: 16px;
  margin-bottom: 12px;
}

.review-text {
  font-size: 14px;
  color: var(--text-dark);
  font-style: italic;
  margin-bottom: 16px;
}

.review-author {
  font-size: 12px;
  border-top: 1px solid rgba(27, 67, 50, 0.06);
  padding-top: 12px;
  display: flex;
  justify-content: space-between;
}

.review-author span {
  color: var(--text-muted);
}

/* FAQ */
.faq-container {
  max-width: 800px;
  margin: 0 auto;
}

.faq-title {
  text-align: center;
  font-size: 24px;
  margin-bottom: 24px;
}

.faq-item {
  background: var(--text-light);
  border-radius: var(--border-radius-sm);
  padding: 16px 20px;
  margin-bottom: 12px;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(27, 67, 50, 0.04);
}

.faq-question {
  font-weight: 600;
  color: var(--primary-color);
  font-size: 15px;
}

.faq-answer {
  margin-top: 8px;
  font-size: 13px;
  color: var(--text-muted);
  padding-left: 18px;
}

/* 10. 동적 상세 슬라이드 아웃 패널 */
.detail-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 42, 31, 0.4);
  backdrop-filter: blur(3px);
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.detail-backdrop.active {
  opacity: 1;
  pointer-events: auto;
}

.detail-panel {
  position: fixed;
  top: 0;
  right: -480px; /* Hidden initially */
  width: 480px;
  height: 100vh;
  background-color: var(--bg-warm-ivory);
  box-shadow: -10px 0 30px rgba(15, 42, 31, 0.15);
  z-index: 1001;
  transition: right 0.35s cubic-bezier(0.25, 0.8, 0.25, 1);
  display: flex;
  flex-direction: column;
}

.detail-panel.active {
  right: 0;
}

.btn-close-panel {
  position: absolute;
  top: 20px;
  left: -50px;
  width: 36px;
  height: 36px;
  background: var(--text-light);
  border-radius: 50%;
  box-shadow: -4px 0 10px rgba(0, 0, 0, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-dark);
  font-size: 16px;
  transition: var(--transition-fast);
  z-index: 10;
}

.btn-close-panel:hover {
  color: var(--danger-color);
  transform: rotate(90deg);
}

.detail-panel-scroll {
  overflow-y: auto;
  flex-grow: 1;
}

/* 히어로 헤더 이미지 */
.detail-hero-section {
  height: 220px;
  background-size: cover;
  background-position: center;
  position: relative;
  display: flex;
  align-items: flex-end;
  padding: 24px;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to top, rgba(15, 42, 31, 0.85) 10%, rgba(15, 42, 31, 0.2) 100%);
}

.hero-title-group {
  position: relative;
  z-index: 2;
  color: var(--text-light);
}

.hero-title-group h2 {
  color: var(--text-light);
  font-size: 22px;
  margin-top: 6px;
}

.detail-badge {
  font-size: 10px;
  font-weight: 700;
  background: var(--secondary-color);
  color: var(--text-light);
  padding: 2px 8px;
  border-radius: 10px;
  text-transform: uppercase;
}

.detail-address-text {
  font-size: 12px;
  opacity: 0.8;
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 4px;
}

/* 거리 및 이동 소요시간 카드 */
.detail-proximity-card {
  margin: -20px 24px 20px;
  background: var(--text-light);
  border-radius: var(--border-radius-sm);
  padding: 16px 20px;
  box-shadow: var(--shadow-sm);
  display: flex;
  border: 1px solid rgba(27, 67, 50, 0.06);
  position: relative;
  z-index: 2;
}

.prox-item {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 12px;
}

.prox-item:first-child {
  border-right: 1px solid rgba(27, 67, 50, 0.1);
  padding-right: 12px;
}

.prox-item.highlight {
  padding-left: 16px;
}

.prox-icon {
  width: 36px;
  height: 36px;
  background: var(--bg-soft-gray);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-color);
  font-size: 16px;
}

.prox-item.highlight .prox-icon {
  background: rgba(45, 106, 79, 0.1);
  color: var(--accent-color);
}

.prox-text {
  display: flex;
  flex-direction: column;
}

.prox-text .label {
  font-size: 11px;
  color: var(--text-muted);
}

.prox-text strong {
  font-size: 15px;
  color: var(--text-dark);
}

.prox-item.highlight .prox-text strong {
  color: var(--accent-color);
}

/* 장지 소개 및 정보 */
.detail-info-section {
  padding: 0 24px 24px;
}

.detail-info-section h3,
.detail-video-section h3,
.form-header h3 {
  font-size: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.detail-desc {
  font-size: 13.5px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 16px;
}

.detail-price-box {
  background: var(--bg-soft-gray);
  padding: 12px 16px;
  border-radius: var(--border-radius-sm);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 16px;
  border-left: 4px solid var(--secondary-color);
}

.price-title {
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 4px;
}

.price-val {
  color: var(--primary-color);
  font-size: 14px;
  font-weight: 700;
}

.detail-tags-container {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.detail-tag {
  font-size: 11px;
  background: var(--text-light);
  border: 1px solid rgba(27, 67, 50, 0.1);
  color: var(--primary-color);
  padding: 4px 10px;
  border-radius: 4px;
  font-weight: 500;
}

/* 유튜브 동영상 임베드 */
.detail-video-section {
  padding: 24px;
  border-top: 1px solid rgba(27, 67, 50, 0.08);
}

.video-sub-title {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.video-wrapper {
  position: relative;
  padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
  height: 0;
  overflow: hidden;
  border-radius: var(--border-radius-sm);
  box-shadow: var(--shadow-sm);
  background-color: #000;
}

.video-wrapper iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* 상세 폼 영역 */
.detail-form-section {
  padding: 28px 24px 48px;
  background: var(--bg-soft-gray);
  border-top: 1px solid rgba(27, 67, 50, 0.08);
  position: relative;
}

.form-header {
  margin-bottom: 20px;
}

.form-header p {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.4;
}

.form-action-buttons {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}

.btn-panel-call {
  background: var(--text-light);
  border: 1.5px solid var(--primary-color);
  color: var(--primary-color);
  padding: 14px;
  border-radius: var(--border-radius-sm);
  font-size: 14px;
  font-weight: 700;
  text-align: center;
  transition: var(--transition-fast);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-panel-call:hover {
  background: rgba(27, 67, 50, 0.05);
}

/* 11. 푸터 */
.main-footer {
  background-color: var(--primary-color);
  color: var(--text-light);
  padding: 40px 24px;
  border-top: 4px solid var(--secondary-color);
  margin-top: auto;
}

.footer-container {
  max-width: 1400px;
  margin: 0 auto;
}

.footer-info {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 13px;
  opacity: 0.7;
}

.footer-info strong {
  opacity: 1;
  font-size: 15px;
}

.copyright {
  margin-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 16px;
  font-size: 11px;
}

/* 12. 반응형 레이아웃 미디어 쿼리 */
@media (max-width: 1024px) {
  .header-container {
    padding: 0 16px;
  }
  .logo h1 {
    font-size: 20px;
  }
  .main-nav ul {
    gap: 2px;
  }
  .nav-item {
    padding: 8px 12px;
    font-size: 13px;
  }
  .btn-header-call {
    padding: 10px 14px;
    font-size: 12px;
  }
  .split-layout {
    height: auto;
    flex-direction: column-reverse; /* 모바일은 리스트가 하단, 지도가 위로 */
  }
  .list-panel {
    width: 100%;
    height: 480px;
  }
  .map-panel {
    height: 350px;
  }
  .map-legend {
    display: none; /* 모바일에서는 상단 필터에서 색상을 보여주므로 범례 숨김 */
  }
  .consult-form-container {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .consult-info-block {
    border-right: none;
    border-bottom: 1px solid rgba(27, 67, 50, 0.05);
    padding: 32px;
  }
  .consult-form-block {
    padding: 32px;
  }
}

@media (max-width: 768px) {
  .main-header {
    height: auto;
    padding: 12px 0;
  }
  .header-container {
    flex-direction: column;
    gap: 12px;
    align-items: center;
  }
  .main-nav {
    width: 100%;
    overflow-x: auto;
    white-space: nowrap;
    padding-bottom: 4px;
  }
  .main-nav ul {
    justify-content: flex-start;
  }
  .header-contact {
    display: none; /* 모바일 헤더 전화 단축 */
  }
  .search-filter-bar {
    padding: 16px;
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
  }
  .filter-divider {
    display: none;
  }
  .location-setter {
    flex-direction: column;
    align-items: stretch;
  }
  .location-search-wrapper {
    width: 100%;
  }
  .filter-options {
    gap: 16px;
  }
  .detail-panel {
    width: 100vw;
    right: -100vw;
  }
  .btn-close-panel {
    left: auto;
    right: 20px;
    top: 20px;
    background: var(--text-light);
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
  }
  .section-header h2 {
    font-size: 24px;
  }
  .guide-grid {
    grid-template-columns: 1fr;
  }
}

/* 내 위치 전용 푸른색 마커 및 펄스 링 애니메이션 */
.custom-user-location-marker {
  position: relative;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.user-dot {
  width: 24px;
  height: 24px;
  background-color: #2196f3; /* Bright blue */
  border: 2px solid white;
  border-radius: 50%;
  color: white;
  font-size: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
  z-index: 5;
}

.pulse-ring {
  position: absolute;
  width: 30px;
  height: 30px;
  border: 3px solid #2196f3;
  border-radius: 50%;
  background-color: rgba(33, 150, 243, 0.2);
  animation: pulse-animation 2s infinite ease-out;
  z-index: 1;
  pointer-events: none;
}

@keyframes pulse-animation {
  0% {
    transform: scale(0.6);
    opacity: 1;
  }
  100% {
    transform: scale(2.2);
    opacity: 0;
  }
}

/* 상담 비활성화 시 안내 카드 */
.detail-consult-off-section {
  padding: 24px;
  background: var(--text-light);
  border-top: 1px solid rgba(27, 67, 50, 0.08);
}

.consult-off-box {
  background: var(--bg-soft-gray);
  border: 1px solid rgba(197, 168, 128, 0.3);
  border-radius: var(--border-radius-md);
  padding: 24px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  box-shadow: var(--shadow-sm);
}

.consult-off-box .off-icon {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: rgba(197, 168, 128, 0.15);
  color: var(--secondary-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  margin-bottom: 4px;
  animation: pulse-border 2s infinite;
}

@keyframes pulse-border {
  0% { box-shadow: 0 0 0 0 rgba(197, 168, 128, 0.4); }
  70% { box-shadow: 0 0 0 8px rgba(197, 168, 128, 0); }
  100% { box-shadow: 0 0 0 0 rgba(197, 168, 128, 0); }
}

.consult-off-box h4 {
  font-size: 16px;
  color: var(--primary-color);
  font-weight: 700;
  margin: 0;
}

.consult-off-box .off-desc {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.5;
  margin: 0;
}

.btn-off-call {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  background: linear-gradient(135deg, var(--secondary-color), var(--secondary-hover));
  color: var(--text-light);
  padding: 14px 20px;
  border-radius: var(--border-radius-sm);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-smooth);
}

.btn-off-call:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(197, 168, 128, 0.35);
}

.consult-off-box .off-tip {
  font-size: 11px;
  color: var(--accent-color);
  font-weight: 600;
}
