/**
 * 엔스타일투어 리뉴얼 - 여행상품 상세 (/{지역}/prod/view)
 * base.css → prod.css 다음에 로드
 * 테마: 지역 테마 (body[data-region="{지역}"])
 * 이미지: 대표 사진 980 x 460 (확대하지 않음), 일정 / 호텔 / 포토스토리 사진은 칸 폭에 맞춰 축소
 */

/* ==========================================================
   1. 위치 / 상단 (대표 사진 + 상품 요약)
   ========================================================== */
/* 갤러리 색 (대표 사진 액자 · 포토 & 스토리 벽 공통)
   - 순검정 대신 따뜻한 차콜 → 사진은 돋보이고 화면 전체(아이보리 톤)와도 어울림
   - 바꿀 때는 여기 두 값만 수정 */
body {
  --gallery-wall: #3a3631;  /* 액자 / 벽 */
  --gallery-mat: #2e2b27;   /* 사진 뒤 (사진이 늦게 뜰 때 보이는 면) */
}

.pv-crumb { display: flex; align-items: center; gap: 0.4rem; padding-top: 1.25rem; padding-bottom: 1.25rem; font-size: 0.82rem; color: var(--text-tertiary); }
.pv-crumb a:hover { color: var(--text-primary); text-decoration: underline; text-underline-offset: 3px; }
.pv-crumb a:last-child { color: var(--text-secondary); font-weight: 700; }
.pv-crumb .icon { width: 12px; height: 12px; }

/* 상단 배치
   PC   : [사진 액자]  [상품 요약]   (요약은 왼쪽 두 줄 높이 전체 → 좌우 높이 맞춤)
          [버튼·전화]  [        ]
   모바일: 사진 → 요약 → 버튼 */
.pv-top {
  display: grid;
  grid-template-columns: minmax(0, 980px) minmax(340px, 1fr);
  grid-template-areas: "photo summary" "cta summary";
  gap: 1.25rem 3rem;
  align-items: stretch;
  padding-bottom: 3rem;
}

/* 대표 사진 : 미술관 전시처럼 (포토 & 스토리와 같은 표현)
   - 벽 : 차콜 + 위쪽에서 비추는 은은한 조명 + 안쪽 금색 실선 테두리
   - 사진 : 크림색 매트(여백)를 두른 작품 (원본 980 x 460, 확대하지 않음)
   - Tip : 작품 설명 라벨처럼 사진 아래 가운데 (지역 색 사용 안 함) */
.pv-photo {
  position: relative;
  grid-area: photo;
  margin: 0;
  padding: 38px 38px 0;
  background:
    radial-gradient(ellipse 65% 60% at 50% 0%, rgba(255, 236, 205, 0.14) 0%, rgba(255, 236, 205, 0) 100%),
    var(--gallery-wall);
  box-shadow: 0 24px 50px -30px rgba(40, 32, 22, 0.45);
}

.pv-photo::before {
  content: '';
  position: absolute;
  inset: 12px;
  border: 1px solid rgba(212, 188, 138, 0.28);
  pointer-events: none;
}

.pv-photo-frame {
  position: relative;
  overflow: hidden;
  padding: 10px; /* 크림색 매트 */
  background: #f4efe6;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.18), 0 26px 46px -22px rgba(0, 0, 0, 0.72);
}

.pv-photo-frame img { display: block; width: 100%; height: auto; aspect-ratio: 980 / 460; object-fit: cover; background: var(--gallery-mat); }
/* 사진이 없을 때 : 매트 안쪽에 기본 이미지(사진과 같은 비율) */
.pv-photo-frame.is-noimg { background: #f4efe6; }
.pv-photo-frame.is-noimg > .prod-noimg { position: relative; inset: auto; aspect-ratio: 980 / 460; gap: 0.5rem; }
.pv-photo-frame .prod-noimg-orn { width: 88px; }
.pv-photo-frame .prod-noimg-en { font-size: clamp(1.5rem, 3vw, 2.2rem); }
.pv-photo-frame .prod-noimg-sub { font-size: 0.66rem; letter-spacing: 4px; }

.pv-tip {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.55rem;
  max-width: 760px;
  margin: 0 auto;
  padding: 1.5rem 0.5rem 1.85rem;
  text-align: center;
  color: rgba(243, 238, 230, 0.86);
}

/* 라벨 : ── Travel Tip ── */
.pv-tip .label {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--font-serif);
  font-size: 1rem;
  font-style: italic;
  font-weight: 600;
  letter-spacing: 0.8px;
  color: var(--gold-light);
  white-space: nowrap;
}

.pv-tip .label::before, .pv-tip .label::after { content: ''; width: 26px; height: 1px; background: var(--gold-light); opacity: 0.6; }
.pv-tip .text { font-size: 0.92rem; line-height: 1.75; letter-spacing: -0.2px; }
.pv-photo:not(:has(.pv-tip)) { padding-bottom: 38px; }

/* 사진 아래 : 버튼 + 전화 / 공유 */
.pv-cta { grid-area: cta; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem 1.5rem; }

.pv-summary { grid-area: summary; display: flex; flex-direction: column; }
.pv-summary .pv-notes { margin-top: auto; } /* 안내 문구를 아래로 → 왼쪽(사진 + 버튼) 높이와 맞춤 */
.pv-summary .pv-price { margin-bottom: 1.25rem; }
/* 상품코드 : 문의할 때 바로 찾을 수 있게 [상품코드 | N20258] 꼬리표 형태 */
.pv-code { display: inline-flex; align-self: flex-start; align-items: stretch; border: 1px solid var(--region); line-height: 1; }
.pv-code .label { display: inline-flex; align-items: center; padding: 0.4rem 0.6rem; background: var(--region); font-size: 0.74rem; font-weight: 700; letter-spacing: 0.3px; color: var(--white); }
.pv-code .code { display: inline-flex; align-items: center; padding: 0.4rem 0.7rem; background: var(--white); font-size: 0.95rem; font-weight: 800; letter-spacing: 1px; font-variant-numeric: tabular-nums; color: var(--text-primary); }
.pv-title { margin-top: 0.8rem; font-size: 1.65rem; font-weight: 800; letter-spacing: -0.8px; line-height: 1.4; }
.pv-route { display: flex; gap: 0.35rem; margin-top: 0.75rem; font-size: 0.82rem; line-height: 1.65; color: var(--region); }
.pv-route .icon { flex: none; width: 15px; height: 15px; margin-top: 0.2rem; }

/* 요금 */
.pv-price { margin-top: 1.5rem; border-top: 2px solid var(--ink); }
.pv-price .row { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; padding: 0.7rem 0; border-bottom: 1px solid var(--line); }
.pv-price dt { font-size: 0.88rem; font-weight: 700; }
.pv-price dt small { font-size: 0.76rem; font-weight: 400; color: var(--text-tertiary); }
.pv-price dd { font-size: 0.88rem; color: var(--text-secondary); }
.pv-price .is-main dd strong { font-size: 1.55rem; font-weight: 800; letter-spacing: -0.5px; color: var(--text-primary); }
.pv-price dd.ask { font-size: 0.86rem; }
.pv-price .is-main dd.ask { font-size: 1rem; font-weight: 700; color: var(--text-primary); }

/* 안내 */
.pv-notes { display: grid; gap: 0.35rem; margin-top: 1.1rem; padding: 0.95rem 1.1rem; background: var(--ivory); font-size: 0.8rem; line-height: 1.65; color: var(--text-secondary); }
.pv-notes li { position: relative; padding-left: 0.8rem; }
.pv-notes li::before { content: ''; position: absolute; left: 0; top: 0.65em; width: 3px; height: 3px; border-radius: 50%; background: currentColor; }
.pv-notes .is-strong { font-weight: 700; color: var(--region); }

/* 버튼 */
.pv-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.pv-actions > .btn-primary { height: 50px; padding: 0 1.8rem; font-size: 0.92rem; }
.pv-actions .is-closed { background: var(--line-strong); border-color: var(--line-strong); box-shadow: none; cursor: not-allowed; }
.pv-actions-sub { display: flex; gap: 0.5rem; }
.pv-actions-sub .btn-line { height: 50px; padding: 0 1.4rem; }

.pv-utils { display: flex; align-items: center; gap: 1.25rem; }
.pv-tel { font-size: 1rem; font-weight: 800; letter-spacing: 0.5px; color: var(--text-primary); }
.pv-tel span { margin-right: 0.35rem; font-size: 0.78rem; font-weight: 400; letter-spacing: 0; color: var(--text-tertiary); }
.pv-share { display: flex; gap: 0.3rem; }

.pv-share button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--text-secondary);
  transition: color var(--transition-fast), border-color var(--transition-fast);
}

/* 마우스가 있는 기기에서만 (터치 기기는 누른 뒤 hover 가 남아 상태가 바뀐 것처럼 보임) */
@media (hover: hover) and (pointer: fine) {
  .pv-share button:hover { border-color: var(--region); color: var(--region); }
}
.pv-share svg { width: 16px; height: 16px; }

/* 찜 (하트) : 찜한 상품은 붉은 색으로 채움, 누르면 살짝 튀어 오름
   - 마우스를 올렸을 때는 다른 버튼과 같은 색 (붉은 색은 '찜한 상태'에만 써서, 로그인 안내를 닫은 뒤 찜된 것처럼 보이지 않게) */
.pv-share .pv-fav svg { transition: fill var(--transition-fast), transform 0.25s var(--ease); }
.pv-share .pv-fav.is-on, .pv-share .pv-fav.is-on:hover { border-color: #c0392b; background: #fbf0ee; color: #c0392b; }
.pv-share .pv-fav.is-on svg { fill: currentColor; animation: pv-fav-pop 0.35s var(--ease); }
.pv-share .pv-fav.is-pending { opacity: 0.6; pointer-events: none; }
@keyframes pv-fav-pop { 0% { transform: scale(0.7); } 60% { transform: scale(1.2); } 100% { transform: scale(1); } }

/* 짧은 안내 (찜 목록에 담았습니다 / 뺐습니다) */
.pv-toast {
  position: fixed;
  left: 50%;
  bottom: 2rem;
  z-index: 1400;
  padding: 0.7rem 1.2rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.22); /* 어두운 배경(푸터) 위에서도 구분되게 */
  background: rgba(22, 19, 15, 0.92);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.35);
  font-size: 0.86rem;
  color: var(--white);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 10px);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.pv-toast.is-show { opacity: 1; transform: translate(-50%, 0); }

@media (prefers-reduced-motion: reduce) {
  .pv-share .pv-fav.is-on svg { animation: none; }
}

/* ==========================================================
   2. 섹션 메뉴 (상단 메뉴 아래 고정)
   ========================================================== */
.pv-tabs {
  position: sticky;
  top: var(--header-h);
  z-index: 50;
  background: var(--white);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.pv-tabs .container { display: flex; gap: 2rem; overflow-x: auto; scrollbar-width: none; }
.pv-tabs .container::-webkit-scrollbar { display: none; }

.pv-tabs a {
  position: relative;
  flex: none;
  padding: 1.05rem 0;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-tertiary);
  white-space: nowrap;
  transition: color var(--transition-fast);
}

.pv-tabs a:hover { color: var(--text-primary); }
.pv-tabs a.is-active { color: var(--text-primary); }
.pv-tabs a.is-active::after { content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--region); }

/* ==========================================================
   3. 본문 + 오른쪽 정보 영역
   ========================================================== */
.pv-layout {
  display: grid;
  grid-template-columns: minmax(0, 980px) minmax(300px, 1fr);
  gap: 3rem;
  align-items: start;
  padding-bottom: 5rem;
}

.pv-main { min-width: 0; }

.pv-sec { padding-top: 3.5rem; scroll-margin-top: calc(var(--header-h) + 60px); }
.pv-sec-title { display: flex; align-items: baseline; gap: 0.75rem; margin-bottom: 1.5rem; font-size: 1.35rem; font-weight: 800; letter-spacing: -0.5px; }
.pv-sec-title .en { font-family: var(--font-serif); font-size: 1.45rem; font-style: italic; font-weight: 500; color: var(--region); }
.pv-sec-note { margin-bottom: 1.25rem; font-size: 0.82rem; color: var(--text-tertiary); }

/* 관리자 등록 HTML 내용 */
.pv-html { font-size: 0.93rem; line-height: 1.85; color: var(--text-secondary); word-break: break-word; overflow-wrap: anywhere; }
.pv-html img { display: inline-block; max-width: 100%; height: auto !important; vertical-align: top; }
.pv-html table { max-width: 100%; }
.pv-html a { color: var(--region); text-decoration: underline; text-underline-offset: 3px; }
.pv-html p + p { margin-top: 0.5rem; }

.pv-benefit { margin-top: 1.5rem; padding: 1.4rem 1.6rem; border-left: 3px solid var(--region); background: var(--region-sub); }
.pv-benefit h3 { margin-bottom: 0.5rem; font-size: 0.98rem; font-weight: 800; color: var(--region); }

/* 강조 표시 (관리자 설정: 굵게 / 색 / 배경) */
.is-bold { font-weight: 700; color: var(--text-primary); }
.is-important { color: var(--region); }
.is-bg { padding: 0.5rem 0.75rem; background: var(--region-sub); }

/* ==========================================================
   4. 요금 달력
   ========================================================== */
.pv-options { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 1.25rem; }
.pv-cal { border: 1px solid var(--line); background: var(--white); }
.pv-cal-nav { display: flex; align-items: center; justify-content: center; gap: 1.25rem; padding: 0.9rem; border-bottom: 1px solid var(--line); }
.pv-cal-nav strong { min-width: 8rem; font-size: 1.05rem; text-align: center; }
.pv-cal-nav button { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 50%; color: var(--text-secondary); }
.pv-cal-nav button:hover { border-color: var(--ink); color: var(--text-primary); }
.pv-cal-nav .icon { width: 14px; height: 14px; }

.pv-cal-table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.pv-cal-table th { padding: 0.6rem 0; background: var(--ivory); font-size: 0.8rem; font-weight: 700; color: var(--text-secondary); }
.pv-cal-table th.sun, .pv-cal-table td.sun .d { color: #c0392b; }
.pv-cal-table th.sat, .pv-cal-table td.sat .d { color: #2f5d9a; }
.pv-cal-table td { height: 74px; padding: 0.45rem 0.5rem; border: 1px solid var(--line); vertical-align: top; }
.pv-cal-table td .d { display: block; font-size: 0.82rem; font-weight: 700; color: var(--text-tertiary); }
.pv-cal-table td .p { display: block; margin-top: 0.45rem; font-size: 0.78rem; font-weight: 700; letter-spacing: -0.2px; color: var(--gold-deep); text-align: right; } /* 금액 : 날짜(검정·빨강·파랑)와 구분되는 짙은 금색 */
.pv-cal-table td .p .short { display: none; }
.pv-cal-table td.is-on { cursor: pointer; transition: background var(--transition-fast); }
.pv-cal-table td.is-on .d { color: var(--text-primary); }
/* 토·일 색 : 출발 가능한 날짜도 같게 (위의 진한 글자색보다 우선, 선택한 날짜는 흰 글자 유지) */
.pv-cal-table td.is-on.sun:not(.is-picked) .d { color: #c0392b; }
.pv-cal-table td.is-on.sat:not(.is-picked) .d { color: #2f5d9a; }
.pv-cal-table td.sun:not(.is-on) .d, .pv-cal-table td.sat:not(.is-on) .d { opacity: 0.55; } /* 출발 없는 토·일은 옅게 (평일 회색 날짜와 맞춤) */
.pv-cal-table td.is-on:hover { background: var(--region-sub); }
.pv-cal-table td.is-picked { background: var(--region); }
.pv-cal-table td.is-picked .d, .pv-cal-table td.is-picked .p { color: var(--white); }
.pv-cal-help { padding: 0.75rem 1rem; border-top: 1px solid var(--line); font-size: 0.78rem; color: var(--text-tertiary); }

/* ==========================================================
   5. 포함 / 불포함 / 안내 목록
   ========================================================== */
.pv-incl { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
.pv-incl-col { padding: 1.5rem 1.6rem; background: var(--ivory); }
.pv-incl-col h3 { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.9rem; font-size: 1rem; font-weight: 800; }
.pv-incl-col h3::before { content: ''; width: 18px; height: 18px; border-radius: 50%; background: var(--region) center / 11px no-repeat; }
.pv-incl-col.is-in h3::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5 9-10'/%3E%3C/svg%3E"); }
.pv-incl-col.is-out h3::before { background-color: var(--text-tertiary); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round'%3E%3Cpath d='M6 6l12 12M18 6 6 18'/%3E%3C/svg%3E"); }
.pv-incl-col ul { display: grid; gap: 0.45rem; }
.pv-incl-col li { position: relative; padding-left: 0.9rem; font-size: 0.9rem; line-height: 1.7; color: var(--text-secondary); }
.pv-incl-col li::before { content: ''; position: absolute; left: 0; top: 0.72em; width: 4px; height: 4px; border-radius: 50%; background: var(--line-strong); }
.pv-incl-note { margin-top: 0.9rem; padding-top: 0.9rem; border-top: 1px dashed var(--line-strong); font-size: 0.85rem; }

.pv-info-list { margin-top: 1.5rem; border-top: 1px solid var(--line); }
.pv-sec-title + .pv-info-list { margin-top: 0; }
.pv-info { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 1.5rem; padding: 1.4rem 0; border-bottom: 1px solid var(--line); }
.pv-info h3 { font-size: 0.95rem; font-weight: 800; color: var(--text-primary); }
/* 유의사항 : 본문보다 작게 (관리자 편집기에서 글자 크기를 지정한 내용도 같은 크기로) */
.pv-html.is-caution { font-size: 0.84rem; line-height: 1.8; }
.pv-html.is-caution [style*="font-size"], .pv-html.is-caution font[size] { font-size: inherit !important; }
.pv-link { display: inline-flex; align-items: center; gap: 0.35rem; margin-top: 0.6rem; font-weight: 700; }

.pv-terms-note { margin-top: 1.5rem; padding: 1.25rem 1.4rem; background: var(--ivory); font-size: 0.82rem; line-height: 1.75; color: var(--text-secondary); }
.pv-terms-note strong { display: block; margin-bottom: 0.4rem; color: var(--text-primary); }
.pv-terms-note ol { padding-left: 1.2rem; list-style: decimal; }

/* ==========================================================
   6. 추천일정 (일자별 타임라인)
   ========================================================== */
.pv-days { display: grid; gap: 1.25rem; }
.pv-day { border: 1px solid var(--line); background: var(--white); }
.pv-day-head { display: flex; align-items: baseline; gap: 0.9rem; padding: 0.9rem 1.4rem; background: var(--region-sub); }
.pv-day-head .num { font-family: var(--font-serif); font-size: 1.3rem; font-style: italic; font-weight: 600; letter-spacing: 0.5px; color: var(--region); }
.pv-day-head .date { font-size: 0.86rem; font-weight: 700; color: var(--text-secondary); }

/* 일정 한 줄 (기존 PC 화면 구조) : [아이콘] [지역] [교통편] [시간] [내용] */
.pv-iti-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.pv-steps { padding: 1.1rem 1.4rem 1rem; --iti-accent: var(--gold); }

.pv-step {
  display: grid;
  grid-template-columns: 22px 150px 112px 60px minmax(0, 1fr);
  column-gap: 0.85rem;
  align-items: start;
  padding: 0.45rem 0;
  font-size: 0.88rem;
  line-height: 1.75;
}

.pv-step-pin { grid-column: 1; grid-row: 1; display: flex; justify-content: center; padding-top: 0.12rem; }
.pv-step-pin .icon { width: 18px; height: 18px; color: var(--region); --iti-accent: var(--gold-light); }
.pv-step-region { grid-column: 2; grid-row: 1; font-size: 0.92rem; font-weight: 800; color: var(--text-primary); word-break: keep-all; }
.pv-step-tt { display: contents; }
.pv-step-tt .trans { grid-column: 3; grid-row: 1; font-weight: 600; color: var(--text-secondary); word-break: break-word; }
.pv-step-tt .time { grid-column: 4; grid-row: 1; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--text-primary); }
.pv-step-body { grid-column: 5; grid-row: 1; min-width: 0; color: var(--text-secondary); }
.pv-step-text { word-break: break-word; }
.pv-step-img { display: block; max-width: 100%; height: auto; margin-top: 0.6rem; }

/* 식사 · 숙소 : 그날 마지막 일정 내용 아래 (PC 좌우, 모바일 위아래) */
.pv-day-foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.6rem 1.5rem;
  margin-top: 1rem;
  padding-top: 0.9rem;
  border-top: 1px dashed var(--line-strong);
  font-size: 0.84rem;
  line-height: 1.6;
  color: var(--text-secondary);
}

.pv-day-foot .meal, .pv-day-foot .hotel { display: flex; align-items: center; gap: 0.65rem; min-width: 0; }
.pv-day-foot .icon { flex: none; width: 28px; height: 28px; color: var(--text-primary); }
.pv-day-foot .items { display: flex; flex-wrap: wrap; gap: 0.15rem 0.9rem; min-width: 0; }
.pv-day-foot b { margin-right: 0.25rem; color: var(--text-primary); }

/* ==========================================================
   7. 호텔정보 / 관련 지역정보
   ========================================================== */
.pv-picker { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem; margin-bottom: 1.4rem; }
.pv-picker-group { margin: 0 0.2rem 0 0.6rem; font-size: 0.78rem; font-weight: 800; color: var(--region); }
.pv-picker-group:first-child { margin-left: 0; }

/* 도시별 한 줄 (호텔 목록) : [도시 이름 | 호텔 버튼들], 호텔이 많으면 버튼 영역 안에서 줄바꿈 */
.pv-picker.is-rows { display: grid; gap: 0.6rem; }
.pv-picker-row { display: grid; grid-template-columns: 6.5rem minmax(0, 1fr); gap: 0.75rem; align-items: start; }
.pv-picker-row .pv-picker-group { margin: 0; padding-top: 0.45rem; }
.pv-picker-list { display: flex; flex-wrap: wrap; gap: 0.4rem; }

.pv-chip {
  display: inline-flex;
  align-items: center;
  height: 34px;
  padding: 0 0.9rem;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--white);
  font-size: 0.82rem;
  color: var(--text-secondary);
  transition: border-color var(--transition-fast), color var(--transition-fast), background var(--transition-fast);
}

.pv-chip:hover { border-color: var(--ink); color: var(--text-primary); }
.pv-chip.is-active { border-color: var(--region); background: var(--region); color: var(--white); font-weight: 700; }

/* 호텔 정보 : [사진 | 설명], 설명 영역 높이는 사진 높이에 맞춤 (설명이 길면 줄임표, 줄 수는 스크립트에서 계산) */
/* 호텔 정보 상자 : 아이보리 바탕 + 안쪽 금색 실선 테두리, 사진은 흰 여백을 두른 작품처럼 */
.pv-detail {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 1.5rem 2.25rem;
  align-items: stretch;
  margin-top: 1.25rem;
  padding: 30px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, #fbf9f4 0%, var(--ivory) 100%);
  box-shadow: 0 24px 44px -34px rgba(40, 32, 22, 0.4);
}

.pv-detail::before {
  content: '';
  position: absolute;
  inset: 8px;
  border: 1px solid rgba(179, 146, 86, 0.3);
  pointer-events: none;
}

.pv-detail > * { position: relative; } /* 금색 테두리 위로 */
#hotelDetail #hotelGallery { align-self: start; padding: 6px; background: var(--white); box-shadow: 0 2px 4px rgba(40, 32, 22, 0.08), 0 16px 30px -20px rgba(40, 32, 22, 0.45); }
.pv-detail-body { padding: 0.4rem 0.2rem 0.2rem; }
.pv-detail-body { display: flex; flex-direction: column; min-height: 0; overflow: hidden; contain: size; } /* 내용 길이가 줄 높이를 늘리지 않음 → 사진 높이 기준 */
.pv-detail-body > .btn-line { flex: none; align-self: flex-start; margin-top: auto; } /* 버튼은 영역 맨 아래 */
.pv-detail-grade { font-size: 0.76rem; font-weight: 700; letter-spacing: 1.5px; color: var(--gold-deep); }
.pv-detail-name { margin-top: 0.45rem; font-size: 1.4rem; font-weight: 800; letter-spacing: -0.5px; line-height: 1.4; }
.pv-detail-en { margin-top: 0.25rem; font-family: var(--font-serif); font-size: 0.98rem; font-style: italic; color: var(--text-tertiary); }
.pv-detail-en::after { content: ''; display: block; width: 32px; height: 1px; margin-top: 1rem; background: var(--gold); } /* 이름 아래 짧은 금색 선 */
/* 설명 높이는 보이는 줄 수만큼만 (상자를 늘리면 줄임표 아래 줄이 비쳐 보임), 줄 수는 스크립트에서 계산 */
.pv-detail-desc { flex: none; margin: 1rem 0 1.25rem; display: -webkit-box; overflow: hidden; white-space: pre-line; -webkit-box-orient: vertical; -webkit-line-clamp: 8; }
.pv-detail-note { grid-column: 1 / -1; padding-top: 1rem; border-top: 1px dashed var(--line-strong); font-size: 0.76rem; color: var(--text-tertiary); }

/* 사진 넘기기
   - 그리드 칸 안에서 사진 원래 폭만큼 칸이 늘어나지 않게 (min-width: 0)
   - 호텔 사진 720 x 500, 포토스토리 670 x 420 → 확대하지 않도록 최대 폭 제한 */
.pv-gallery { position: relative; min-width: 0; overflow: hidden; background: var(--ivory-2); }
.pv-gallery-track { display: flex; min-width: 0; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.pv-gallery-track::-webkit-scrollbar { display: none; }
.pv-gallery-item { flex: 0 0 100%; min-width: 0; scroll-snap-align: start; }
.pv-gallery-item img { display: block; width: 100%; max-width: none; aspect-ratio: 36 / 25; object-fit: cover; }
.pv-gallery-item figcaption { padding: 0.8rem 1rem; background: var(--white); font-size: 0.86rem; line-height: 1.7; color: var(--text-secondary); }

#hotelGallery { max-width: 720px; }

/* 포토 & 스토리 : 영역 전체를 갤러리 벽처럼 (대표 사진 액자와 같은 색), 사진(670 x 420)은 벽 가운데 */
/* 포토 & 스토리 : 미술관 전시처럼
   - 벽 : 액자와 같은 차콜 + 위쪽에서 비추는 은은한 조명 + 안쪽 금색 실선 테두리
   - 사진 : 크림색 매트(여백)를 두른 작품처럼 벽 가운데 (원본 670 x 420, 확대하지 않음)
   - 설명 : 작품 설명 라벨처럼 사진 아래 가운데, 번호는 사진 위 오른쪽 */
.pv-story {
  position: relative;
  padding: 3.5rem 5rem 2.75rem; /* 좌우 여백 = 바깥쪽 이전·다음 버튼 자리 */
  background:
    radial-gradient(ellipse 60% 55% at 50% 0%, rgba(255, 236, 205, 0.13) 0%, rgba(255, 236, 205, 0) 100%),
    var(--gallery-wall);
}

.pv-story::before {
  content: '';
  position: absolute;
  inset: 12px;
  border: 1px solid rgba(212, 188, 138, 0.28);
  pointer-events: none;
}

.pv-gallery.is-story { max-width: 670px; margin: 0 auto; overflow: visible; background: none; container-type: inline-size; }
.pv-gallery.is-story .pv-gallery-track { overflow-y: hidden; padding-bottom: 28px; margin-bottom: -28px; } /* 사진 그림자가 잘리지 않게 */

.pv-gallery.is-story .pv-gallery-item img {
  aspect-ratio: 670 / 420;
  padding: 10px; /* 크림색 매트 */
  background: #f4efe6;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.18), 0 22px 40px -20px rgba(0, 0, 0, 0.7);
}

.pv-gallery.is-story .pv-gallery-item figcaption {
  max-width: 540px;
  margin: 0 auto;
  padding: 1.6rem 0.5rem 0;
  background: none;
  font-size: 0.88rem;
  line-height: 1.8;
  letter-spacing: -0.2px;
  text-align: center;
  color: rgba(243, 238, 230, 0.86);
}

.pv-gallery.is-story .pv-gallery-item figcaption::before { content: ''; display: block; width: 28px; height: 1px; margin: 0 auto 1rem; background: var(--gold-light); opacity: 0.7; } /* 라벨 위 짧은 금색 선 */

/* 이전·다음 : 벽 위의 얇은 원형 버튼 (사진 높이의 가운데, 폭 기준 계산) */
.pv-gallery.is-story .pv-gallery-btn {
  top: calc(100cqw * 420 / 670 / 2);
  width: 44px;
  height: 44px;
  border: 1px solid rgba(243, 238, 230, 0.4);
  background: rgba(255, 255, 255, 0.02);
  color: rgba(243, 238, 230, 0.9);
  box-shadow: none;
  transition: border-color var(--transition-fast), color var(--transition-fast), background var(--transition-fast);
}

.pv-gallery.is-story .pv-gallery-btn:hover { border-color: var(--gold-light); background: rgba(212, 188, 138, 0.12); color: var(--gold-light); }
.pv-gallery.is-story .pv-gallery-btn.is-prev { left: -4rem; }
.pv-gallery.is-story .pv-gallery-btn.is-next { right: -4rem; }

/* 번호 : 사진 위 오른쪽, 이탤릭 세리프 */
.pv-gallery.is-story .pv-gallery-count {
  top: -2.1rem;
  right: 0;
  padding: 0;
  border-radius: 0;
  background: none;
  font-family: var(--font-serif);
  font-size: 0.95rem;
  font-style: italic;
  letter-spacing: 1px;
  color: var(--gold-light);
}

.pv-gallery-btn {
  position: absolute;
  top: 40%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  color: var(--text-primary);
  transform: translateY(-50%);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.pv-gallery-btn.is-prev { left: 0.75rem; }
.pv-gallery-btn.is-next { right: 0.75rem; }
.pv-gallery-btn .icon { width: 16px; height: 16px; }
.pv-gallery-count { position: absolute; top: 0.75rem; right: 0.75rem; padding: 0.2rem 0.6rem; border-radius: 999px; background: rgba(0, 0, 0, 0.55); font-size: 0.74rem; color: var(--white); }

.pv-area { display: grid; grid-template-columns: minmax(0, 1fr); gap: 2.5rem; }
.pv-area > * { min-width: 0; }
.pv-detail > * { min-width: 0; }
.pv-area-block h3 { display: flex; align-items: baseline; gap: 0.6rem; margin-bottom: 1rem; font-size: 1.05rem; font-weight: 800; }
.pv-area-block h3 span { font-size: 0.8rem; font-weight: 400; color: var(--text-tertiary); }
.pv-area .blog-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.pv-spots { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.pv-spot { display: block; overflow: hidden; aspect-ratio: 12 / 5; background: var(--ivory-2); }
.pv-spot img { width: 100%; height: 100%; object-fit: cover; }
.pv-area-empty { padding: 3rem 0; color: var(--text-tertiary); text-align: center; background: var(--ivory); }

/* ==========================================================
   8. 오른쪽 정보 영역 (예약·문의 + 최근 본 상품)
   ========================================================== */
.pv-side { position: sticky; top: calc(var(--header-h) + 76px); display: grid; gap: 1.75rem; padding-top: 3.5rem; }
/* 예약·문의 + 최근 본 상품을 한 카드로 */
.pv-side-box { padding: 1.4rem; border: 1px solid var(--line); border-top: 3px solid var(--region); background: var(--white); }
.pv-side-actions { display: grid; gap: 0.5rem; }
.pv-side-box .btn-primary, .pv-side-box .btn-line { width: 100%; height: 46px; padding: 0; }
.pv-side-tel { margin-top: 0.3rem; font-size: 0.82rem; font-weight: 700; color: var(--text-secondary); text-align: center; }

.pv-recent { margin-top: 1.4rem; padding-top: 1.25rem; border-top: 1px solid var(--line); }
/* 최근 본 상품 : 상품 내용보다 눈에 띄지 않게 (작은 사진 + 제목만, 가격 없음) */
.pv-recent-head { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; margin-bottom: 0.75rem; }
.pv-recent-title { font-size: 0.84rem; font-weight: 700; color: var(--text-secondary); }
.pv-recent-clear { padding: 0.15rem 0; border: 0; background: none; font-size: 0.72rem; color: var(--text-tertiary); cursor: pointer; }
.pv-recent-clear:hover, .pv-recent-clear:focus-visible { color: var(--text-primary); text-decoration: underline; text-underline-offset: 2px; }
.pv-recent-list { display: grid; gap: 0.6rem; }
.pv-recent-list li { position: relative; }
.pv-recent-list a { display: grid; grid-template-columns: 60px minmax(0, 1fr); gap: 0.7rem; align-items: center; padding-right: 1.6rem; } /* 오른쪽은 삭제 버튼 자리 */
/* 삭제 버튼 : 평소엔 흐리게, 항목에 마우스를 올리거나 초점이 가면 또렷하게 */
.pv-recent-del { position: absolute; top: 50%; right: 0; display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; padding: 0; border: 0; border-radius: 50%; background: none; color: var(--text-tertiary); opacity: 0.55; transform: translateY(-50%); cursor: pointer; transition: opacity 0.2s ease, background-color 0.2s ease, color 0.2s ease; }
.pv-recent-del .icon { width: 14px; height: 14px; }
.pv-recent-list li:hover .pv-recent-del, .pv-recent-del:focus-visible { opacity: 1; }
.pv-recent-del:hover, .pv-recent-del:focus-visible { background: var(--line); color: var(--text-primary); }
.pv-recent-list .thumb { overflow: hidden; aspect-ratio: 4 / 3; background: var(--region-sub); }
.pv-recent-list .thumb img { width: 100%; height: 100%; object-fit: cover; filter: saturate(0.55) brightness(1.04) contrast(0.92); opacity: 0.82; transition: filter 0.4s ease, opacity 0.4s ease; } /* 톤 다운 : 채도·대비를 낮춰 부드럽게 */
.pv-recent-list a:hover .thumb img { filter: none; opacity: 1; } /* 마우스를 올리면 원래 색 */
/* 최근 본 상품 사진이 없을 때 : 작은 칸이라 장식(◇)만, 다른 사진처럼 흐리게 */
.pv-recent-list .thumb { position: relative; }
.pv-recent-list .thumb.is-noimg > .prod-noimg { opacity: 0.82; }
.pv-recent-list .thumb.is-noimg > .prod-noimg::before { inset: 3px; }
.pv-recent-list .thumb .prod-noimg-orn { width: 30px; }
.pv-recent-list .thumb .prod-noimg-en, .pv-recent-list .thumb .prod-noimg-sub { display: none; }
.pv-recent-list .body { display: grid; gap: 0.15rem; min-width: 0; }
.pv-recent-list .region { font-size: 0.7rem; font-weight: 600; color: var(--text-tertiary); }
.pv-recent-list .title { display: -webkit-box; overflow: hidden; font-size: 0.78rem; font-weight: 600; line-height: 1.45; color: var(--text-secondary); -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.pv-recent-list a:hover .title { color: var(--text-primary); text-decoration: underline; text-underline-offset: 2px; }

/* 모바일 하단 고정 바 (모바일만) */
.pv-mbar { display: none; }

/* ==========================================================
   9. 반응형
   ========================================================== */
@media (max-width: 1280px) {
  .pv-top { grid-template-columns: minmax(0, 1fr) 340px; gap: 1.25rem 2rem; }
  .pv-photo { padding: 28px 28px 0; }
  .pv-photo:not(:has(.pv-tip)) { padding-bottom: 28px; }
  .pv-layout { grid-template-columns: minmax(0, 1fr) 280px; gap: 2rem; }
  .pv-area .blog-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 1024px) {
  .pv-top { grid-template-columns: minmax(0, 1fr); grid-template-areas: "photo" "summary" "cta"; gap: 1.75rem; }
  .pv-summary .pv-notes { margin-top: 1.1rem; }
  .pv-summary .pv-price { margin-bottom: 0; }
  .pv-cta { display: grid; gap: 1rem; }
  .pv-actions { display: grid; }
  .pv-actions > .btn-primary { width: 100%; height: 54px; }
  .pv-actions-sub { display: grid; grid-template-columns: 1fr 1fr; }
  .pv-actions-sub .btn-line { padding: 0; }
  .pv-utils { flex-wrap: wrap; justify-content: space-between; row-gap: 0.75rem; } /* 글자를 키워도 화면 밖으로 밀리지 않게 줄바꿈 */
  .pv-layout { grid-template-columns: 1fr; }
  .pv-side { position: static; padding-top: 3rem; }
  .pv-side-actions { display: none; } /* 예약·문의는 모바일 하단 바로 대신 */
  .pv-side-box { padding: 0; border: 0; background: none; }
  .pv-side-box:not(:has(.pv-recent:not([hidden]))) { display: none; }
  .pv-recent { margin-top: 0; padding-top: 0; border-top: 0; }
  .pv-recent-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pv-detail { grid-template-columns: 1fr; gap: 1.25rem; padding: 22px; }
  .pv-detail::before { inset: 6px; }
  .pv-detail-body { contain: none; overflow: visible; }
  .pv-detail-desc { flex: none; max-height: calc(1.85em * 6); -webkit-line-clamp: 6 !important; } /* 한 줄 배치: 사진 아래 6줄까지 (높이 상한도 함께) */

  .pv-mbar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 900;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.65rem var(--gutter) calc(0.65rem + env(safe-area-inset-bottom));
    background: var(--white);
    box-shadow: 0 -6px 20px rgba(0, 0, 0, 0.12);
  }

  /* 버튼 3개 : 맞춤여행 · 상품 문의 (같은 폭) + 상품 예약 (조금 넓게) */
  .pv-mbar .btn-line, .pv-mbar .btn-primary { flex: 1 1 0; justify-content: center; min-width: 0; height: 46px; padding: 0 0.5rem; font-size: 0.88rem; white-space: nowrap; }
  .pv-mbar .btn-primary { flex-grow: 1.35; }
  .pv-mbar .is-closed { background: var(--line-strong); border-color: var(--line-strong); box-shadow: none; cursor: not-allowed; }
  body:has(.pv-mbar) .site-footer { padding-bottom: 72px; }
  body:has(.pv-mbar) .to-top { bottom: calc(76px + env(safe-area-inset-bottom)); } /* 하단 고정 바와 겹치지 않게 */
  .pv-toast { bottom: calc(84px + env(safe-area-inset-bottom)); }
}

@media (max-width: 768px) {
  .pv-detail { padding: 16px; }
  .pv-detail::before { inset: 5px; }
  #hotelDetail #hotelGallery { padding: 4px; }
  .pv-detail-name { font-size: 1.25rem; }

  .pv-crumb { padding-top: 1rem; padding-bottom: 1rem; }
  .pv-photo { margin: 0 calc(var(--gutter) * -1); padding: 20px 20px 0; }
  /* 포토 & 스토리 : 화면 끝까지 벽, 이전·다음은 사진 안쪽 */
  .pv-story { margin: 0 calc(var(--gutter) * -1); padding: 2.6rem calc(var(--gutter) + 6px) 1.9rem; }
  .pv-story::before { inset: 7px; }
  .pv-gallery.is-story .pv-gallery-item img { padding: 6px; }
  .pv-gallery.is-story .pv-gallery-item figcaption { padding-top: 1.2rem; font-size: 0.84rem; }
  .pv-gallery.is-story .pv-gallery-item figcaption::before { margin-bottom: 0.75rem; }
  .pv-gallery.is-story .pv-gallery-count { top: -1.8rem; font-size: 0.86rem; }
  /* 이전·다음 : 사진 안쪽 (사진 위라 어두운 반투명 바탕) */
  .pv-gallery.is-story .pv-gallery-btn { width: 34px; height: 34px; border-color: rgba(255, 255, 255, 0.55); background: rgba(20, 18, 15, 0.38); color: var(--white); }
  .pv-gallery.is-story .pv-gallery-btn.is-prev { left: 0.6rem; }
  .pv-gallery.is-story .pv-gallery-btn.is-next { right: 0.6rem; }
  .pv-photo:not(:has(.pv-tip)) { padding-bottom: 20px; }
  .pv-photo::before { inset: 7px; }
  .pv-photo-frame { padding: 5px; }
  .pv-tip { gap: 0.4rem; padding: 1.1rem 0.4rem 1.35rem; }
  .pv-tip .label { font-size: 0.92rem; }
  .pv-tip .label::before, .pv-tip .label::after { width: 18px; }
  .pv-tip .text { font-size: 0.86rem; }
  .pv-title { font-size: 1.35rem; }
  .pv-tabs .container { gap: 1.4rem; }
  .pv-tabs a { padding: 0.9rem 0; font-size: 0.86rem; }

  .pv-sec { padding-top: 2.5rem; }
  .pv-sec-title { font-size: 1.15rem; }
  .pv-sec-title .en { font-size: 1.2rem; }

  .pv-cal-table td { height: 58px; padding: 0.3rem; }
  .pv-cal-table td .d { font-size: 0.74rem; }
  .pv-cal-table td .p { margin-top: 0.3rem; font-size: 0.72rem; letter-spacing: -0.3px; text-align: left; }
  .pv-cal-table td .p .full { display: none; }
  .pv-cal-table td .p .short { display: inline; }

  .pv-incl { grid-template-columns: 1fr; }
  .pv-incl-col { padding: 1.25rem; }
  .pv-info { grid-template-columns: 1fr; gap: 0.5rem; padding: 1.1rem 0; }

  .pv-day-head { padding: 0.8rem 1rem; }
  /* 일정 (기존 모바일 화면 구조) : [아이콘] [지역] / [교통편 시간] / [내용] */
  .pv-steps { padding: 0.9rem 1rem 0.9rem; }
  .pv-step { grid-template-columns: 20px minmax(0, 1fr); column-gap: 0.6rem; padding: 0.5rem 0; }
  .pv-step-pin .icon { width: 17px; height: 17px; }
  .pv-step-region { grid-column: 2; grid-row: auto; }
  .pv-step-region:empty { display: none; }
  .pv-step-tt { grid-column: 2; display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.1rem 0.6rem; }
  .pv-step-tt .trans, .pv-step-tt .time { grid-column: auto; grid-row: auto; }
  .pv-step-tt .time:empty, .pv-step-tt .trans:empty { display: none; }
  .pv-step-body { grid-column: 2; grid-row: auto; }
  .pv-day-foot { flex-direction: column; gap: 0.55rem; }
  .pv-day-foot .icon { width: 26px; height: 26px; }

  .pv-area .blog-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pv-spots { grid-template-columns: 1fr; }
  .pv-picker-row { grid-template-columns: 1fr; gap: 0.4rem; } /* 모바일: 도시 이름 한 줄, 그 아래 호텔 */
  .pv-picker-row .pv-picker-group { padding-top: 0.35rem; }
  .pv-recent-list { grid-template-columns: 1fr; }
}
