/* ========================================
   SHOP_SW2 - 쇼핑몰 리뷰 스와이퍼 (TOTAL_REVIEW1)
   ======================================== */

/* === 관리자 뱃지 === */
.SHOP_SW2 .sw_shop_badge {
  position: absolute;
  top: -8px;
  left: 10px;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  color: #fff;
  font-size: 12px;
  padding: 4px 10px;
  border-radius: 12px;
  cursor: pointer;
  z-index: 10;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  opacity: 0;
  transition: opacity 0.2s;
}
.SHOP_SW2.admin_div:hover .sw_shop_badge { opacity: 1; }

/* === 헤더 (제목 + 더보기) === */
.SHOP_SW2 .sw_bbs1_header {
  position: relative;
  float: left;
  width: 100%;
  margin-bottom: clamp(16px, calc(1.09vw + 12.5px), 30px);
}
.SHOP_SW2 .sw_bbs1_more {
  position: absolute;
  right: 0;
  bottom: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
  color: inherit;
  z-index: 2;
}
.SHOP_SW2 .sw_more_txt {
  font-size: 14px;
  color: #666;
}
.SHOP_SW2 .sw_more_circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid #ddd;
  color: #666;
  font-size: 16px;
  transition: all 0.2s;
}
.SHOP_SW2 .sw_bbs1_more:hover .sw_more_circle {
  border-color: #999;
  color: #333;
  transform: translateX(2px);
}

/* hymore_wrap 기본 위치 (MORE 스타일 사용 시) */
.SHOP_SW2 .sw_bbs1_header .hymore_wrap {
  position: absolute;
  right: 0;
  bottom: 0;
}

/* 데코 라인 — sw_bbs1_titles 안에 ::after로 배치 */
.SHOP_SW2 .sw_bbs1_header[data-deco-line] .sw_bbs1_titles {
  position: relative;
}
.SHOP_SW2 .sw_bbs1_header[data-deco-line] .sw_bbs1_titles::after {
  content: '';
  position: absolute;
  left: var(--dl-left, 30%);
  right: var(--dl-right, 70px);
  top: var(--dl-top, auto);
  bottom: var(--dl-bottom, 0);
  height: var(--dl-h, 1px);
  background: var(--dl-color, #ddd);
  pointer-events: none;
  z-index: 1;
}

/* 데코 도트 */
.SHOP_SW2 .sw_bbs1_header[data-deco-dot] .sw_bbs1_titles::before {
  content: '';
  position: absolute;
  width: var(--dl-dot-size, 4px);
  height: var(--dl-dot-size, 4px);
  border-radius: 50%;
  background: var(--dl-dot-color, #222);
  left: var(--dl-left, 30%);
  top: var(--dl-top, auto);
  bottom: var(--dl-bottom, 0);
  transform: translate(var(--dl-dot-x, -6px), var(--dl-dot-y, 0px));
  z-index: 2;
  pointer-events: none;
}
/* 데코 라인 모바일 숨김 */
@media (max-width: 768px) {
  .SHOP_SW2 .sw_bbs1_header[data-deco-line-mo-hide] .sw_bbs1_titles::after,
  .SHOP_SW2 .sw_bbs1_header[data-deco-line-mo-hide] .sw_bbs1_titles::before { display: none !important; }
}

/* ================================================
   더보기 위치 프리셋 (data-more-pos)
   ================================================ */

/* 제목 밑 */
.SHOP_SW2 .sw_bbs1_header[data-more-pos="below"] {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.SHOP_SW2 .sw_bbs1_header[data-more-pos="below"] .sw_bbs1_titles {
  float: none;
}
.SHOP_SW2 .sw_bbs1_header[data-more-pos="below"] .sw_bbs1_more,
.SHOP_SW2 .sw_bbs1_header[data-more-pos="below"] .hymore_wrap {
  position: static;
  margin-top: clamp(8px, calc(0.47vw + 6.5px), 14px);
}

/* 우측 상단 */
.SHOP_SW2 .sw_bbs1_header[data-more-pos="right_top"] .sw_bbs1_more,
.SHOP_SW2 .sw_bbs1_header[data-more-pos="right_top"] .hymore_wrap {
  top: 0;
  bottom: auto;
}

/* 우측 중앙 */
.SHOP_SW2 .sw_bbs1_header[data-more-pos="right_center"] .sw_bbs1_more,
.SHOP_SW2 .sw_bbs1_header[data-more-pos="right_center"] .hymore_wrap {
  top: 50%;
  bottom: auto;
  transform: translateY(-50%);
}
.SHOP_SW2 .sw_bbs1_header[data-more-pos="right_center"] .sw_bbs1_more:hover .sw_more_circle {
  transform: translateX(2px);
}

/* 우측 하단 (기본과 동일하지만 명시) */
.SHOP_SW2 .sw_bbs1_header[data-more-pos="right_bottom"] .sw_bbs1_more,
.SHOP_SW2 .sw_bbs1_header[data-more-pos="right_bottom"] .hymore_wrap {
  right: 0;
  bottom: 0;
  top: auto;
}

/* 커스텀 오프셋 (CSS변수 오버라이드) */
.SHOP_SW2 .sw_bbs1_header[style*="--mt"] .sw_bbs1_more,
.SHOP_SW2 .sw_bbs1_header[style*="--mt"] .hymore_wrap {
  top: var(--mt, auto);
}
.SHOP_SW2 .sw_bbs1_header[style*="--mr"] .sw_bbs1_more,
.SHOP_SW2 .sw_bbs1_header[style*="--mr"] .hymore_wrap {
  right: var(--mr, 0);
}
.SHOP_SW2 .sw_bbs1_header[style*="--mb"] .sw_bbs1_more,
.SHOP_SW2 .sw_bbs1_header[style*="--mb"] .hymore_wrap {
  bottom: var(--mb, auto);
}
.SHOP_SW2 .sw_bbs1_header[style*="--ml"] .sw_bbs1_more,
.SHOP_SW2 .sw_bbs1_header[style*="--ml"] .hymore_wrap {
  left: var(--ml, auto);
}

/* === 스와이퍼 래퍼 === */
.SHOP_SW2 .sw_review_swiper_wrap {
  position: relative;
  float: left;
  width: 100%;
  overflow-x: clip;
  overflow-y: visible;
}
/* Swiper 오버플로 해제 → 호버 그림자/이동이 잘리지 않음 */
.SHOP_SW2 .content-swiper.swiper-initialized {
  overflow: visible;
}

/* === Swiper 초기화 전 레이아웃 (FOUC 방지) === */
.SHOP_SW2 .content-swiper:not(.swiper-initialized) { overflow: hidden; }
.SHOP_SW2 .content-swiper:not(.swiper-initialized) .swiper-wrapper { display: flex; gap: var(--sw-gap, 20px); }
.SHOP_SW2 .content-swiper:not(.swiper-initialized) .swiper-slide {
  flex-shrink: 0;
  width: calc((100% - var(--sw-gap, 20px) * (var(--slides-pc, 3) - 1)) / var(--slides-pc, 3));
}
@media screen and (max-width: 1023px) {
  .SHOP_SW2 .content-swiper:not(.swiper-initialized) .swiper-slide {
    width: calc((100% - min(var(--sw-gap, 20px), 20px) * (var(--slides-tablet, 2) - 1)) / var(--slides-tablet, 2));
  }
}
@media screen and (max-width: 767px) {
  .SHOP_SW2 .content-swiper:not(.swiper-initialized) .swiper-slide {
    width: calc((100% - min(var(--sw-gap, 15px), 15px) * (var(--slides-mo, 1) - 1)) / var(--slides-mo, 1));
  }
}

/* ========================================
   리뷰 카드 (TOTAL_REVIEW1 디자인)
   ======================================== */
.SHOP_SW2 .rv_card {
  display: flex;
  flex-direction: var(--card-direction, row);
  background: var(--card-bg, #1a1a1a);
  border-radius: var(--card-radius, 16px);
  padding: var(--card-outer-padding, 0);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  height: 100%;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* === 호버 효과 === */
/* 이미지 확대 */
.SHOP_SW2.hover-img_scale .rv_card:hover .rv_img_in img { transform: scale(1.06); }
/* 카드 확대 */
.SHOP_SW2.hover-card_scale .rv_card:hover { transform: scale(1.03); }
/* 위로 올라감 */
.SHOP_SW2.hover-card_up .rv_card:hover { transform: translateY(-6px); }
/* 그림자만 */
.SHOP_SW2.hover-shadow .rv_card:hover { box-shadow: 0 8px 24px rgba(0,0,0,0.12); }
/* 올라감+그림자 */
.SHOP_SW2.hover-up_shadow .rv_card:hover { transform: translateY(-6px); box-shadow: 0 12px 32px rgba(0,0,0,0.15); }
/* 카드확대+그림자 */
.SHOP_SW2.hover-scale_shadow .rv_card:hover { transform: scale(1.03); box-shadow: 0 8px 24px rgba(0,0,0,0.12); }
/* 이미지확대+그림자 */
.SHOP_SW2.hover-img_shadow .rv_card:hover .rv_img_in img { transform: scale(1.06); }
.SHOP_SW2.hover-img_shadow .rv_card:hover { box-shadow: 0 8px 24px rgba(0,0,0,0.12); }

/* ========================================
   엑티브 슬라이드 효과
   ======================================== */
.SHOP_SW2.has-active-effect .content-swiper {
  overflow: visible;
}
.SHOP_SW2.has-active-effect .layout-inner .content-swiper {
  overflow: visible;
}
.SHOP_SW2.has-active-effect .swiper-slide {
  transition: transform 0.4s ease, opacity 0.4s ease, filter 0.4s ease;
}
.SHOP_SW2.has-active-effect .swiper-slide:not(.swiper-slide-active) {
  transform: scale(var(--inactive-scale, 1));
  opacity: var(--inactive-opacity, 1);
  filter: var(--inactive-filter, none);
}
.SHOP_SW2.has-active-effect .swiper-slide:not(.swiper-slide-active):hover {
  opacity: 1;
  filter: none;
}
.SHOP_SW2.has-active-effect .swiper-slide-active {
  transform: scale(var(--active-scale, 1));
  z-index: 2;
}

/* === 상품 이미지 (좌측) === */
.SHOP_SW2 .rv_img {
  flex: 0 0 var(--thumb-width-pct, 35%);
  max-width: var(--thumb-width-pct, 35%);
  overflow: hidden;
  border-radius: var(--img-radius, 0);
}
.SHOP_SW2 .rv_img_in {
  width: 100%;
  height: 100%;
}
/* 세로 모드일 때 이미지 영역 전체 폭 */
.SHOP_SW2 .rv_card[style*="--card-direction:column"] .rv_img,
.SHOP_SW2[style*="--card-direction:column"] .rv_img {
  flex: none;
  max-width: 100%;
  width: 100%;
}
.SHOP_SW2 .rv_img_in img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

/* === 텍스트 영역 (우측) === */
.SHOP_SW2 .rv_info {
  flex: 1;
  padding: var(--card-padding, 20px);
  display: flex;
  flex-direction: column;
  justify-content: var(--card-valign, center);
  gap: clamp(6px, calc(0.47vw + 4.5px), 12px);
  min-width: 0;
}

/* === 별점 === */
.SHOP_SW2 .rv_stars {
  display: flex;
  gap: 2px;
  font-size: clamp(14px, calc(0.31vw + 13px), 18px);
  line-height: 1;
}
.SHOP_SW2 .rv_star {
  color: rgba(255,255,255,0.2);
  line-height: 1;
}
.SHOP_SW2 .rv_star.filled {
  color: var(--rv-star-color, #fbbf24);
}

/* === 상품명 === */
.SHOP_SW2 .rv_product_name {
  font-size: var(--rv-title-size, clamp(14px, calc(0.23vw + 13.3px), 17px));
  font-weight: 600;
  color: var(--rv-title-color, #ffffff);
  line-height: 1.4;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

/* === 리뷰 내용 === */
.SHOP_SW2 .rv_content {
  font-size: var(--rv-content-size, clamp(12px, calc(0.16vw + 11.5px), 14px));
  color: var(--rv-content-color, rgba(255,255,255,0.7));
  line-height: 1.6;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

/* === 작성자 === */
.SHOP_SW2 .rv_author {
  font-size: var(--rv-author-size, clamp(11px, calc(0.08vw + 10.75px), 12px));
  color: var(--rv-author-color, rgba(255,255,255,0.5));
  margin-top: auto;
}

/* === 빈 상태 === */
.SHOP_SW2 .empty_li {
  text-align: center;
  color: #999;
  padding: 40px 0;
  font-size: 14px;
  width: 100%;
}

/* ========================================
   페이징 네비게이션
   ======================================== */
.SHOP_SW2 .paging-wrap {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: var(--sw-nav-gap, clamp(16px, calc(1.09vw + 12.5px), 30px));
  float: left;
  width: 100%;
}
.SHOP_SW2 .btn-wrap {
  display: flex;
  gap: var(--sw-arrow-gap, 8px);
  flex-shrink: 0;
}
.SHOP_SW2 .btn-prev,
.SHOP_SW2 .btn-next {
  width: var(--sw-arrow-size, 36px);
  height: var(--sw-arrow-size, 36px);
  border-radius: var(--sw-arrow-radius, 50%);
  border: 1px solid var(--sw-arrow-border-color, #ddd);
  background: var(--sw-arrow-bg, #fff);
  color: var(--sw-arrow-color, #555);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: var(--sw-arrow-icon-size, 18px);
  transition: all 0.2s;
  flex-shrink: 0;
}
.SHOP_SW2 .btn-prev i,
.SHOP_SW2 .btn-next i {
  line-height: 1;
  display: block;
}
.SHOP_SW2 .btn-prev i { transform: translate(-1px, -1px); }
.SHOP_SW2 .btn-next i { transform: translate(1px, -1px); }
.SHOP_SW2 .btn-prev:hover,
.SHOP_SW2 .btn-next:hover {
  border-color: var(--sw-arrow-border-color-hover, #999);
  color: var(--sw-arrow-color-hover, #222);
  background: var(--sw-arrow-bg-hover, var(--sw-arrow-bg, #fff));
}
.SHOP_SW2 .swiper-button-disabled {
  opacity: 0.35;
  cursor: default;
}

/* --- arrows_bar --- */
.SHOP_SW2 .paging-arrows_bar .swiper-pagination {
  position: relative;
  flex: 1;
  height: 3px;
  background: #eee;
  border-radius: 2px;
}
.SHOP_SW2 .swiper-pagination-progressbar-fill {
  background: var(--sw-nav-active-color, #222);
  border-radius: 2px;
}

/* --- 도트 공통 --- */
.SHOP_SW2 .paging-arrows_dots .swiper-pagination,
.SHOP_SW2 .paging-dots_only .swiper-pagination,
.SHOP_SW2 .paging-arrows_dots_inline .swiper-pagination {
  position: relative;
  display: flex;
  gap: 6px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  height: auto;
  background: transparent;
  width: auto;
}
.SHOP_SW2 .swiper-pagination-bullet {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ddd;
  opacity: 1;
  transition: all 0.3s;
  cursor: pointer;
  flex-shrink: 0;
  margin: 0 !important;
}
.SHOP_SW2 .swiper-pagination-bullet-active {
  background: var(--sw-nav-active-color, #222);
  width: 24px;
  border-radius: 4px;
}

/* --- arrows_dots --- */
.SHOP_SW2 .paging-arrows_dots .swiper-pagination { flex: 1; }

/* --- dots_only --- */
.SHOP_SW2 .paging-dots_only .swiper-pagination { flex: 0 1 auto; }
.SHOP_SW2 .paging-dots_only.dots-center { justify-content: center; }
.SHOP_SW2 .paging-dots_only.dots-left { justify-content: flex-start; }
.SHOP_SW2 .paging-dots_only.dots-right { justify-content: flex-end; }

/* --- arrows_dots_inline --- */
.SHOP_SW2 .paging-arrows_dots_inline { justify-content: center; gap: 16px; }
.SHOP_SW2 .paging-arrows_dots_inline .swiper-pagination { flex: 0 1 auto; }
.SHOP_SW2 .paging-arrows_dots_inline .btn-prev,
.SHOP_SW2 .paging-arrows_dots_inline .btn-next {
  width: 48px;
  height: 48px;
  font-size: 24px;
}

/* === 화살표 바깥쪽 모드 === */
.SHOP_SW2 .arrows-outer {
  --arrow-size: var(--sw-arrow-size, 44px);
  --arrow-gap: 12px;
  --arrow-offset: calc(var(--arrow-size) + var(--arrow-gap));
}
.SHOP_SW2:has(.arrows-outer) .contentContainer { overflow: visible; }
.SHOP_SW2 .arrows-outer .btn-wrap {
  position: absolute;
  top: 0;
  left: calc(var(--arrow-offset) * -1);
  width: calc(100% + var(--arrow-offset) * 2);
  height: 100%;
  display: block;
  pointer-events: none;
  z-index: 5;
}
.SHOP_SW2 .arrows-outer .btn-prev,
.SHOP_SW2 .arrows-outer .btn-next {
  position: absolute;
  width: var(--arrow-size);
  height: var(--arrow-size);
  pointer-events: auto;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}
.SHOP_SW2 .arrows-outer .btn-prev { left: 0; }
.SHOP_SW2 .arrows-outer .btn-next { right: 0; }
.SHOP_SW2 .arrows-outer.arrows-vcenter .btn-prev,
.SHOP_SW2 .arrows-outer.arrows-vcenter .btn-next {
  top: 50%;
  transform: translateY(-50%);
}
.SHOP_SW2 .arrows-outer.arrows-vtop .btn-prev,
.SHOP_SW2 .arrows-outer.arrows-vtop .btn-next {
  top: 0;
}
.SHOP_SW2 .arrows-outer .paging-wrap {
  position: static;
  justify-content: center;
}
.SHOP_SW2 .arrows-outer .paging-arrows_bar .swiper-pagination {
  max-width: 200px;
  margin: 0 auto;
}

/* ========================================
   슬라이드 레이아웃 모드
   ======================================== */
/* full: 기본 */
/* inner: overflow hidden */
.SHOP_SW2 .layout-inner .content-swiper {
  overflow: hidden;
}
/* right: 우측 확장 */
.SHOP_SW2:has(.layout-right) {
  overflow-x: clip;
}
.SHOP_SW2 .layout-right {
  overflow: visible;
}
.SHOP_SW2 .layout-right .content-swiper {
  overflow: visible;
  width: calc(100vw - var(--sw-left, 0px));
  max-width: none;
}

/* ========================================
   반응형
   ======================================== */
@media screen and (max-width: 768px) {
  .SHOP_SW2 .paging-wrap {
    gap: 10px;
  }
}
@media screen and (max-width: 480px) {
  .SHOP_SW2 .rv_card {
    flex-direction: column;
  }
  .SHOP_SW2 .rv_img {
    flex: none;
    max-width: 100%;
    width: 100%;
  }
  .SHOP_SW2 .rv_img_in {
    aspect-ratio: var(--thumb-ratio-mo, 16/9);
  }
  .SHOP_SW2 .rv_info {
    padding: clamp(12px, calc(0.63vw + 10px), 16px);
  }
  .SHOP_SW2 .rv_product_name {
    font-size: 14px;
    -webkit-line-clamp: 1;
  }
  .SHOP_SW2 .rv_content {
    -webkit-line-clamp: 2;
  }
}
