
/* OTT Simple Reviews Slider
   - Inspired by the provided Cafe24/Swiper markup structure
   - Scoped to .ott-review-slider
*/

.ott-review-slider{
  --font-color-base:#000;
  --font-color-heading:#000;
  --font-color-primary:#000;
  --font-color-secondary:#ef441f;
  --font-color-warn:#ec2a1d;
  --font-color-success:#0985df;
  --star-color:#000;

  font-size:13px;
  font-family:"Lato","Pretendard Variable","맑은 고딕","malgun gothic","돋움","dotum",sans-serif;
  color:var(--font-color-base);

  overflow:hidden;
  list-style:none;
  z-index:1;
  position:relative;

  padding:0 0 40px;
  padding-top:0;
  width:100%;
  margin:0 auto;

  transition:all .8s ease;
  transition-delay:.2s !important;

  opacity:0;
  transform:translateY(24px);
}
.ott-review-slider.is-inview{
  opacity:1;
  transform:translateY(0);
}

/* ✅ 텍스트는 전부 13px 통일 (테마/엘리멘터 기본값 간섭 방지) */
.ott-review-slider,
.ott-review-slider *{
  font-size:13px !important;
}

.ott-review-slider .swiper-wrapper{
  align-items:stretch;
}

.ott-review-slider .main-review__item{
  background:#fff;
  border:1px solid #ebebeb;
  display:flex;
  flex-direction:column;
  height:auto;
}

.ott-review-slider .thumb{
  position:relative;
  width:100%;
  aspect-ratio: 1 / 1;
  overflow:hidden;
  background:#f7f7f7;
}
.ott-review-slider .thumb__img{
  position:absolute;
  inset:0;
  background-size:cover;
  background-position:center;
  background-repeat:no-repeat;
}
.ott-review-slider .thumb__img--attach{
  opacity:1;
}
.ott-review-slider .description{
  padding:12px 12px 10px;
  text-align:left;
}
.ott-review-slider .description .subject{
  font-weight:700;
  font-size:14px;
  color:var(--font-color-heading);
  margin:0 0 6px;
  line-height:1.35;
}
.ott-review-slider .description .content{
  margin:0 0 8px;
  opacity:.9;
  line-height:1.45;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
}
.ott-review-slider .score{
  margin:0 0 6px;
  line-height:1;
}
.ott-review-slider .ott-stars{
  display:inline-block;
  vertical-align:middle;
  font-size:13px;
  letter-spacing:1px;
  color:var(--star-color);
}
.ott-review-slider .ott-stars::before{
  content:"★★★★★";
}
.ott-review-slider .ott-stars{
  /* show filled based on rating using width clipping */
  position:relative;
}
.ott-review-slider .ott-stars::before{
  position:relative;
  z-index:1;
}
.ott-review-slider .ott-stars::after{
  content:"★★★★★";
  position:absolute;
  left:0;
  top:0;
  width:100%;
  color:#ddd;
  z-index:0;
}
.ott-review-slider .ott-stars{
  --r: 5;
}
.ott-review-slider .ott-stars[data-rating="1"]{ --r:1; }
.ott-review-slider .ott-stars[data-rating="2"]{ --r:2; }
.ott-review-slider .ott-stars[data-rating="3"]{ --r:3; }
.ott-review-slider .ott-stars[data-rating="4"]{ --r:4; }
.ott-review-slider .ott-stars[data-rating="5"]{ --r:5; }

.ott-review-slider .ott-stars::before{
  /* filled stars width */
  clip-path: inset(0 calc((5 - var(--r)) * 20%) 0 0);
}

.ott-review-slider .writer{
  margin:0;
  font-size:13px;
  opacity:.75;
}

.ott-review-slider .prd-info{
  display:flex;
  gap:10px;
  align-items:center;
  padding:10px 12px 12px;
  border-top:1px solid #ebebeb;
  margin-top:auto;
}
.ott-review-slider .prd-thumb a{
  display:block;
  width:34px;
  height:34px;
  background-size:cover;
  background-position:center;
  border:1px solid #ebebeb;
}
.ott-review-slider .prd-name a{
  color:var(--font-color-primary);
  text-decoration:none;
  font-weight:500;
  line-height:1.2;
}
.ott-review-slider .prd-name a:hover{
  color:var(--font-color-secondary);
}

.ott-review-slider .ott-review-pagination{
  position:absolute;
  left:0;
  right:0;
  bottom:0;
  text-align:center;
}
.ott-review-slider .swiper-pagination-bullet{
  width:6px;
  height:6px;
  opacity:.35;
}
.ott-review-slider .swiper-pagination-bullet-active{
  opacity:1;
}

/* Review form fields (optional) */
.woocommerce .comment-form-ott-title input{
  width:100%;
  max-width:100%;
}
.woocommerce .comment-form-ott-images input[type="file"]{
  width:100%;
}
.woocommerce .comment-form-ott-images .ott-help{
  display:block;
  margin-top:6px;
  font-size:12px;
  opacity:.7;
}
/* =========================
   Review Detail Modal
   ========================= */
body.ott-rv-lock{
  overflow:hidden !important;
}

.ott-review-slider .ott-rv-open{
  cursor:pointer;
}

.ott-rv-modal{
  position:fixed;
  inset:0;
  z-index:999999;
  display:none;
  font-size:13px !important;
  font-family:"Lato","Pretendard Variable","맑은 고딕","malgun gothic","돋움","dotum",sans-serif !important;
  color:#000;
}

/* ✅ 팝업 내부 텍스트 전부 13px 유지 (테마 버튼/본문 폰트 간섭 방지) */
.ott-rv-modal *{
  font-size:inherit !important;
  font-family:inherit !important;
}
.ott-rv-modal.is-open{
  display:block;
}
.ott-rv-modal .ott-rv-overlay{
  position:absolute;
  inset:0;
  background:rgba(0,0,0,.65);
}
.ott-rv-modal .ott-rv-popup{
  position:relative;
  width:min(1300px, 96vw);
  height:min(760px, 92vh);
  margin:4vh auto;
  background:#fff;
  border-radius:0;
  overflow:hidden;
  display:flex;
  flex-direction:column;
  box-shadow:0 20px 60px rgba(0,0,0,.25);
}
/* ===== Header (Cafe24 style) ===== */
.ott-rv-modal .ott-rv-header{
  height:48px;
  display:flex;
  align-items:center;
  justify-content:center;
  border-bottom:1px solid #ebebeb;
  background:#fff;
  position:relative;
  flex:0 0 auto;
}
.ott-rv-modal .ott-rv-header-title{
  font-weight:700;
  letter-spacing:.02em;
}
.ott-rv-modal .ott-rv-header-close{
  position:absolute;
  right:8px;
  top:50%;
  transform:translateY(-50%);
  width:40px;
  height:40px;
  border:0 !important;
  background:transparent !important;
  border-radius:0 !important;
  color:#333 !important;
  padding:0;
  cursor:pointer;
  z-index:30;
  display:flex;
  align-items:center;
  justify-content:center;
}
.ott-rv-modal .ott-rv-header-close svg{
  width:22px;
  height:22px;
  fill:#333;
  display:block;
}
.ott-rv-modal .ott-rv-header-close:focus,
.ott-rv-modal .ott-rv-header-close:active{
  outline:0 !important;
  box-shadow:none !important;
}

/* Body wrapper */
.ott-rv-modal .ott-rv-body{
  flex:1 1 auto;
  display:flex;
  min-height:0;
}

/* Review-to-review navigation (left/right) */
.ott-rv-modal .ott-rv-review-nav{
  position:absolute;
  top:50%;
  transform:translateY(-50%);
  width:44px;
  height:44px;
  border:0 !important;
  background:transparent !important;
  cursor:pointer;
  z-index:25;
  opacity:1;
}
.ott-rv-modal .ott-rv-review-nav--prev{ left:10px; }
.ott-rv-modal .ott-rv-review-nav--next{ right:10px; }
.ott-rv-modal .ott-rv-review-nav::before{
  display:block;
  width:44px;
  height:44px;
  line-height:44px;
  text-align:center;
  font-size:40px !important;
  color:#111;
  content:"‹";
}
.ott-rv-modal .ott-rv-review-nav--next::before{ content:"›"; }
.ott-rv-modal .ott-rv-review-nav.is-disabled,
.ott-rv-modal .ott-rv-review-nav[aria-disabled="true"]{
  opacity:.25;
  pointer-events:none;
}

.ott-rv-modal .ott-rv-attached{
  flex: 1 1 55%;
  background:#000;
  position:relative;
}
.ott-rv-modal .ott-rv-img-container{
  width:100%;
  height:100%;
}
.ott-rv-modal .ott-rv-img-item img{
  width:100%;
  height:100%;
  object-fit:contain;
  background:#000;
}

.ott-rv-modal .ott-rv-img-item video{
  width:100%;
  height:100%;
  object-fit:contain;
  background:#000;
  display:block;
}


.ott-rv-modal .ott-rv-slide-nav{
  position:absolute;
  top:50%;
  transform:translateY(-50%);
  width:44px;
  height:44px;
  border-radius:999px;
  background:rgba(0,0,0,.35) !important;
  border:0 !important;
  outline:0 !important;
  user-select:none;
  -webkit-tap-highlight-color:transparent;
  opacity:1 !important;
  visibility:visible !important;
  display:flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
  z-index:10;
}
.ott-rv-modal .ott-rv-slide-nav--prev{ left:14px; }
.ott-rv-modal .ott-rv-slide-nav--next{ right:14px; }
.ott-rv-modal .ott-rv-slide-nav--prev::before{
  content:"‹";
  color:#fff;
  font-size:28px !important;
  line-height:1;
}
.ott-rv-modal .ott-rv-slide-nav--next::before{
  content:"›";
  color:#fff;
  font-size:28px !important;
  line-height:1;
}

.ott-rv-modal .ott-rv-slide-pagination{
  position:absolute;
  left:50%;
  bottom:14px;
  transform:translateX(-50%);
  padding:6px 10px;
  border-radius:999px;
  font-size:13px !important;
  color:#fff;
  background:rgba(0,0,0,.45);
  z-index:4;
}

.ott-rv-modal .ott-rv-info{
  flex: 1 1 45%;
  border-left:1px solid #ebebeb;
  background:#fff;
  min-height:0;
  display:flex;
}
.ott-rv-modal .ott-rv-scroll{
  flex:1 1 auto;
  overflow:auto;
  padding:22px 22px 18px;
}

.ott-rv-modal .ott-rv-prd-box{
  padding:0 0 14px;
  border-bottom:1px solid #ebebeb;
  margin-bottom:14px;
}
.ott-rv-modal .ott-rv-prd-link{
  display:flex;
  gap:12px;
  align-items:center;
  text-decoration:none;
  color:inherit;
}
.ott-rv-modal .ott-rv-prd-thumb img{
  width:44px;
  height:44px;
  object-fit:cover;
  border-radius:6px;
  background:#f2f2f2;
  display:block;
}
.ott-rv-modal .ott-rv-prd-meta{
  display:flex;
  flex-direction:column;
  gap:2px;
}
.ott-rv-modal .ott-rv-prd-name{
  font-weight:700;
}
.ott-rv-modal .ott-rv-prd-price{
  opacity:.75;
}

.ott-rv-modal .ott-rv-summary{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:10px 0 14px;
}
.ott-rv-modal .ott-rv-writing{
  display:flex;
  align-items:center;
  gap:10px;
  opacity:.85;
  font-size:12px;
}

.ott-rv-modal .ott-rv-detail{
  padding:4px 0 18px;
}
.ott-rv-modal .ott-rv-subject{
  font-weight:800;
  margin-bottom:8px;
}
.ott-rv-modal .ott-rv-content{
  line-height:1.6;
  opacity:.9;
}

.ott-rv-modal .ott-rv-other{
  margin-top:18px;
  padding-top:14px;
  border-top:1px solid #ebebeb;
}
.ott-rv-modal .ott-rv-other-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  margin-bottom:10px;
}
.ott-rv-modal .ott-rv-other-title{
  font-weight:800;
}
.ott-rv-modal .ott-rv-other-nav button{
  width:28px;
  height:28px;
  border:1px solid #ebebeb;
  background:#fff;
  cursor:pointer;
  border-radius:4px;

  /* ✅ 화살표만 교체 (기존 텍스트 ‹ › 숨김) */
  font-size:0 !important;
  line-height:26px;
  position:relative;
}
.ott-rv-modal .ott-rv-other-nav button::before{
  content:"";
  width:8px;
  height:8px;
  border-top:2px solid #333;
  border-left:2px solid #333;
  position:absolute;
  top:50%;
  left:50%;
  transform:translate(-50%,-50%) rotate(-45deg);
}
.ott-rv-modal .ott-rv-other-nav .ott-rv-other-next::before{
  border-left:0;
  border-right:2px solid #333;
  transform:translate(-50%,-50%) rotate(45deg);
}
.ott-rv-modal .ott-rv-other-track{
  display:flex;
  gap:8px;
  overflow-x:auto;
  padding-bottom:6px;
  scroll-behavior:smooth;
}
.ott-rv-modal .ott-rv-other-track::-webkit-scrollbar{
  height:0;
}
.ott-rv-modal .ott-rv-other-thumb{
  flex:0 0 auto;
  width:72px;
  height:72px;
  border:1px solid #ebebeb;
  background:#fff;
  padding:0;
  border-radius:6px;
  overflow:hidden;
  cursor:pointer;
}
.ott-rv-modal .ott-rv-other-thumb img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}

/* Stars (shared) */
.ott-rv-modal .ott-stars{
  display:inline-block;
  vertical-align:middle;
  font-size:13px;
  letter-spacing:1px;
  color: var(--star-color, #000);
  position:relative;
  --r: 5;
}
.ott-rv-modal .ott-stars::after{
  content:"★★★★★";
  position:absolute;
  left:0;
  top:0;
  width:100%;
  color:#ddd;
  z-index:0;
}
.ott-rv-modal .ott-stars::before{
  content:"★★★★★";
  position:relative;
  z-index:1;
  clip-path: inset(0 calc((5 - var(--r)) * 20%) 0 0);
}
.ott-rv-modal .ott-stars[data-rating="1"]{ --r:1; }
.ott-rv-modal .ott-stars[data-rating="2"]{ --r:2; }
.ott-rv-modal .ott-stars[data-rating="3"]{ --r:3; }
.ott-rv-modal .ott-stars[data-rating="4"]{ --r:4; }
.ott-rv-modal .ott-stars[data-rating="5"]{ --r:5; }

@media (max-width: 1024px){
  .ott-rv-modal .ott-rv-popup{
    width:min(980px, 96vw);
  }
}
@media (max-width: 767px){
  .ott-rv-modal .ott-rv-popup{
    width:94vw;
    height:92vh;
    margin:4vh auto;
  }
  .ott-rv-modal .ott-rv-body{
    flex-direction:column;
  }
  .ott-rv-modal .ott-rv-attached{
    flex:0 0 42vh;
  }
  .ott-rv-modal .ott-rv-info{
    border-left:0;
    border-top:1px solid #ebebeb;
    flex:1 1 auto;
  }
}


/* ===== v0.3.4 tweaks ===== */
.ott-review-slider .ott-rv-meta{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
}
.ott-review-slider .ott-rv-meta .score{
  margin:0;
}
.ott-review-slider .ott-rv-meta .writer{
  margin:0;
  text-align:right;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  max-width:60%;
}
