/* ============================================================
   Product Detail 페이지 — mobile-first
   Figma: 296:7015
   ============================================================ */

/* ── 레이아웃 ─────────────────────────────────────────────── */
.pd-layout {
  grid-template-columns: 1fr;
  gap: 0;
  padding: 0 0 20px;
}

/* ── 갤러리 ──────────────────────────────────────────────── */
.pd-gallery__main {
  border-radius: 0;
  margin-bottom: 16px;
}

/* ── 구매 영역 ────────────────────────────────────────────── */
.pd-buy {
  padding: 0 4px;
}

.pd-buy__badge {
  font-size: var(--fs-xs);
  padding: 3px 8px;
  margin-bottom: 8px;
}

.pd-buy h1 {
  font-size: var(--fs-lg);
  margin-bottom: 10px;
}

.pd-buy__rating {
  font-size: var(--fs-xs);
  margin-bottom: 8px;
}

.pd-buy__soldout-badge {
  display: inline-block;
  background: #e53e3e;
  color: #fff;
  font-size: var(--fs-sm);
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 4px;
  margin-bottom: 8px;
}

.pd-buy__price {
  font-size: var(--fs-xl);
  margin-bottom: 12px;
}

.pd-buy__ship {
  font-size: var(--fs-xs);
  margin-bottom: 16px;
}

/* ── 옵션 셀렉트 ──────────────────────────────────────────── */
.pd-select {
  margin-bottom: 12px;
}

.pd-select label {
  font-size: var(--fs-xs);
  margin-bottom: 4px;
}

.pd-select select {
  padding: 10px;
  font-size: var(--fs-base);
}

/* ── 합계 줄 ────────────────────────────────────────────── */
.pd-line {
  padding: 10px;
  font-size: var(--fs-xs);
}

.pd-total {
  font-size: var(--fs-lg);
  margin: 16px 0;
}

/* ── 액션 버튼 ───────────────────────────────────────────── */
.pd-actions {
  gap: 8px;
}

.pd-actions .btn {
  flex: 1;
  min-width: 0;
  padding: 14px 10px;
  font-size: var(--fs-base);
}

/* ── 탭 ──────────────────────────────────────────────────── */
.pd-tabs {
  gap: 20px;
  margin: 24px 0;
  padding-bottom: 12px;
}

.pd-tabs a {
  font-size: var(--fs-base);
}

/* ── 상세 이미지 ─────────────────────────────────────────── */
.pd-detail-images {
  gap: 0;
  margin-top: 0;
}

.pd-detail-images img {
  border-radius: 0;
}

/* ── 리뷰 ────────────────────────────────────────────────── */
.pd-reviews__score {
  font-size: 2rem;
}

.pd-reviews-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-top: 8px;
}

.pd-review-card {
  display: flex;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--line-1, #eee);
  border-radius: 6px;
  background: #fff;
}

.pd-review-card__thumb {
  width: 80px;
  height: 125px;
  flex-shrink: 0;
  border-radius: 4px;
  overflow: hidden;
  background: #f5f5f5;
}

.pd-review-card__thumb img,
.pd-review-card__thumb video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.pd-review-card__body {
  flex: 1;
  min-width: 0;
}

.pd-review-card__option {
  margin: 0 0 6px;
  font-size: 13px;
  color: #555;
}

.pd-review-card__text {
  margin: 0 0 10px;
  font-size: 14px;
  line-height: 1.55;
  color: #333;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.pd-review-card__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
  font-size: 12px;
  color: #777;
}

.pd-review-card__stars {
  color: #e74c3c;
  letter-spacing: 1px;
}

.pd-review-card__cert {
  font-size: 11px;
  color: #555;
  background: #f5f5f5;
  padding: 2px 6px;
  border-radius: 3px;
}

.pd-reviews__more-wrap {
  margin-top: 20px;
}

.pd-reviews__more-btn {
  display: block;
  width: 100%;
  padding: 10px;
  border: 1px solid var(--line-1, #ddd);
  background: #fff;
  font-size: 14px;
  color: #555;
  cursor: pointer;
  border-radius: 4px;
  text-align: center;
}

.pd-reviews__more-btn:hover {
  background: #f9f9f9;
}

.pd-reviews__more-btn:disabled {
  opacity: 0.6;
  cursor: wait;
}

.pd-review-item {
  padding: 16px 0;
}

.pd-review-item__media {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.pd-review-item__thumb {
  width: 72px;
  height: 72px;
  border-radius: 6px;
  overflow: hidden;
  background: var(--muted-bg, #f3f4f6);
}

.pd-review-item__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.pd-review-item__thumb--vid video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ── 데스크탑 오버라이드 ─────────────────────────────────── */
@media (min-width: 1280px) {
  .pd-layout {
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    padding: 50px 0;
  }

  .pd-gallery__main {
    border-radius: 10px;
    margin-bottom: 0;
  }

  .pd-buy {
    padding: 0;
  }

  .pd-buy__badge {
    font-size: 12px;
    padding: 4px 8px;
    margin-bottom: 12px;
  }

  .pd-buy h1 {
    font-size: 22px;
    margin-bottom: 16px;
  }

  .pd-buy__rating {
    font-size: var(--fs-sm);
    margin-bottom: 12px;
  }

  .pd-buy__price {
    font-size: 24px;
    margin-bottom: 20px;
  }

  .pd-buy__ship {
    font-size: 14px;
    margin-bottom: 24px;
  }

  .pd-select {
    margin-bottom: 16px;
  }

  .pd-select label {
    font-size: 14px;
    margin-bottom: 6px;
  }

  .pd-select select {
    padding: 12px;
  }

  .pd-line {
    padding: 12px;
    font-size: 14px;
  }

  .pd-total {
    font-size: 18px;
    margin: 20px 0;
  }

  .pd-actions {
    gap: 10px;
  }

  .pd-actions .btn {
    flex: none;
    min-width: 140px;
    padding: 14px 24px;
    font-size: 16px;
  }

  .pd-tabs {
    gap: 40px;
    margin: 40px 0;
    padding-bottom: 16px;
  }

  .pd-tabs a {
    font-size: 16px;
  }

  .pd-detail-images img {
    border-radius: 0;
  }

  .pd-reviews__score {
    font-size: 2.5rem;
  }

  .pd-reviews-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .pd-review-item {
    padding: 20px 0;
  }
}

/* ── Figma Frame 92 / 111 — 브레드크럼, 배송, 포토리뷰, 옵션 라인 ─ */
.pd-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 6px;
  font-size: 12px;
  color: var(--mute-3, #999);
  margin-bottom: 12px;
}

.pd-breadcrumb a {
  color: var(--mute-3, #999);
  text-decoration: none;
}

.pd-breadcrumb a:hover {
  color: var(--mute-1, #333);
}

.pd-breadcrumb__sep {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-right: 1px solid #ccc;
  border-bottom: 1px solid #ccc;
  transform: rotate(-45deg);
  margin: 0 2px;
  opacity: 0.6;
}

.pd-breadcrumb__current {
  color: var(--mute-1, #333);
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pd-buy__rating-text {
  margin-left: 6px;
}

.pd-buy__rating-link {
  margin-left: 10px;
  padding: 0;
  border: none;
  background: none;
  font-size: inherit;
  color: var(--accent, #2563eb);
  cursor: pointer;
  text-decoration: underline;
}

.pd-buy__ship-rows {
  margin: 0 0 16px;
  padding: 0;
  font-size: 13px;
}

.pd-buy__ship-row {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 8px 12px;
  padding: 8px 0;
  border-bottom: 1px solid var(--mute-6, #eee);
}

.pd-buy__ship-row dt {
  margin: 0;
  font-weight: 600;
  color: var(--mute-1, #333);
}

.pd-buy__ship-row dd {
  margin: 0;
  color: var(--mute-2, #666);
  word-break: keep-all;
}

.pd-photo-reviews {
  margin-top: 16px;
}

.pd-photo-reviews__title {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  margin-bottom: 10px;
  color: var(--mute-1, #333);
}

.pd-photo-reviews__strip {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.pd-photo-reviews__thumb {
  flex: 0 0 128px;
  width: 128px;
  height: 128px;
  padding: 0;
  border: none;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  background: var(--mute-7, #f5f5f5);
}

.pd-photo-reviews__thumb img,
.pd-photo-reviews__thumb .pd-photo-reviews__thumb-media {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  vertical-align: middle;
}

.pd-photo-reviews__thumb .pd-photo-reviews__thumb-media {
  pointer-events: none;
  background: #222;
}

.pd-gallery__main-video {
  border-radius: inherit;
}

.pd-select--hidden {
  display: none !important;
}

.btn--block {
  width: 100%;
  display: block;
  box-sizing: border-box;
}

.pd-addon-block {
  margin-bottom: 16px;
  padding-top: 8px;
  border-top: 1px solid var(--mute-6, #eee);
}

.pd-addon-block__title {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 8px;
}

.pd-addon-option-wrap--hidden {
  display: none !important;
}

.pd-addon-add {
  margin-top: 10px;
}

.pd-option-lines {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
}

.pd-opt-line {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  padding: 15px 12px;
  background: #f8f8f8;
  border-radius: 4px;
}

.pd-opt-line__left {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.pd-opt-line__name {
  font-size: 16px;
  color: #111;
  line-height: 1.5;
}

.pd-opt-line__opts {
  font-size: 14px;
  color: var(--mute-3, #999);
  line-height: 1.5;
}

.pd-opt-line__qty {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  width: auto;
  box-sizing: border-box;
  border: 1px solid var(--mute-6, #eee);
  background: #fff;
  border-radius: 2px;
}

.pd-opt-line__qtybtn {
  flex: 0 0 32px;
  width: 32px;
  height: 32px;
  border: none;
  background: #fff;
  cursor: pointer;
  font-size: 16px;
  line-height: 1;
  color: var(--mute-1, #333);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.pd-opt-line__qtynum {
  flex: 0 0 auto;
  width: 40px;
  min-width: 28px;
  padding: 0 4px;
  text-align: center;
  font-size: 14px;
  font-weight: 500;
  border: 0;
  border-left: 1px solid var(--mute-6, #eee);
  border-right: 1px solid var(--mute-6, #eee);
  background: #fff;
  -moz-appearance: textfield;
}

.pd-opt-line__qtynum::-webkit-inner-spin-button,
.pd-opt-line__qtynum::-webkit-outer-spin-button {
  -webkit-appearance: none;
}

.pd-opt-line__right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: space-between;
  min-height: 56px;
}

.pd-opt-line__del {
  border: none;
  background: none;
  color: var(--mute-3, #999);
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
  padding: 0 0 4px;
}

.pd-opt-line__sub {
  font-size: 16px;
  color: var(--mute-1, #333);
  white-space: nowrap;
}

/* ── 모바일 수정 (260422_mob_design_issues) ─────────────── */
@media (max-width: 1279px) {
  /* Issue 6: 모바일 브레드크럼 숨김 (4단계로 두 줄 넘침) */
  .pd-breadcrumb {
    display: none;
  }

  /* Issue 3: SNS 버튼 침범 방지 */
  .pd-buy {
    padding-right: 56px;
  }
}
