/* ============================
   리뷰 전체 컨테이너
============================ */
.review-container {
    background: #fff;
    border-radius: 12px;
    padding: 12px;
    margin: 12px 0;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
    font-family: 'Apple SD Gothic Neo', 'Noto Sans KR', sans-serif;
}

/* ============================
   리뷰 요약 (헤더 + 평점)
============================ */
.review-summary {
    border-bottom: 1px solid #eee;
    padding-bottom: 8px;
    margin-bottom: 12px;
}

.review-summary-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

.review-summary-header h3 {
    font-size: 14px;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 4px;
}

.review-summary-header h3::before {
    content: "⭐";
    margin-right: 3px;
    color: #ffb400;
}

.review-all-link {
    font-size: 13px;
    color: #007bff;
    text-decoration: none;
}
.review-all-link:hover { text-decoration: underline; }

.avg-rating {
    font-size: 13px;
    color: #ff6f00;
    display: flex;
    align-items: center;
    gap: 4px;
}

.avg-rating .score {
    font-weight: bold;
    color: #ff6f00;
}

.avg-rating .stars {
    color: #ffc107;
    font-size: 13px;
}

/* ============================
   리뷰 아이템
============================ */
.review-item {
    display: flex;
    align-items: flex-start;
    padding: 10px;
    margin-bottom: 10px;
    border: 1px solid #eee;
    border-radius: 6px;
    background: #fff;
    flex-direction: column;
}

.review-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    width: 100%;
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}

.review-writer { font-weight: bold; margin-right: 6px; }
.review-rating { color: #ff9500; font-size: 12px; }
.review-date   { color: #888; font-size: 11px; }

.review-collapsible {
    max-height: 130px;
    overflow: hidden;
    transition: max-height 0.3s ease;
}
.review-collapsible.expanded {
    max-height: 1000px;
}

.review-content {
    font-size: 13px;
    line-height: 1.4;
    color: #444;
    white-space: pre-line;
    word-break: break-word;
    margin-top: 4px;
}

.expand-btn {
    display: none;
    font-size: 13px;
    font-weight: 500;
    color: #555;
    cursor: pointer;
    width: 100%;
    text-align: center;
    padding: 6px 0;
    margin-top: 4px;
    background: #f4f4f4;
    border-top: 1px solid #ddd;
    border-radius: 0 0 6px 6px;
    transition: background 0.25s ease, color 0.25s ease;
}
.expand-btn:hover {
    background: #e9e9e9;
    color: #333;
}

/* ============================
   리뷰 이미지
============================ */
.review-images {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 4px;
}
.review-thumbnail {
    width: calc(33% - 3px);
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border-radius: 6px;
    background: #f8f8f8;
}
.review-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* ============================
   리뷰 전체보기 하단바
============================ */
.review-more-bar {
    margin-top: 8px;
    text-align: center;
    border-top: 1px solid #ddd;
    border-radius: 0 0 12px 12px;
    overflow: hidden;
}
.review-more-bar a {
    display: block;
    padding: 12px 0;
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    background: #007aff;
    text-decoration: none;
    transition: background 0.25s ease;
}
.review-more-bar a:hover { background: #005ecb; }

/* ============================
   리뷰 없음 메시지
============================ */
.no-review {
    text-align: center;
    color: #aaa;
    font-size: 13px;
    padding: 16px 0;
}

/* 모달 이미지 영역 */
.modal-slide-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
}

.modal-slide-wrapper img {
    max-width: 90%;
    max-height: 90%;
    display: block !important;  /* ✅ 강제로 보이게 */
    margin: auto;
    object-fit: contain;
    z-index: 10000;
}

.modal-slide {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
    display: block !important;  /* 무조건 보이게 */
    margin: auto;
    z-index: 10001;
}


/* 모달 전체 */
.image-modal {
    display: none; 
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(120,120,120,0.9);  /* ✅ 전체 배경은 회색 */
    justify-content: center;
    align-items: center;
}

/* 모달 컨텐츠 */
.image-modal .modal-content {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    background: #fff;      /* ✅ 이미지 박스는 흰색 */
    border-radius: 10px;   /* 모서리 둥글게 */
    padding: 20px;
    max-width: 80%;
    max-height: 80%;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2); /* 박스 그림자 */
}

/* 모달 이미지 */
.modal-slide-wrapper img {
    max-width: 100%;   
    max-height: 100%;
    object-fit: contain;
    display: block;
    margin: auto;
    border-radius: 6px;
}

/* 닫기 버튼 */
.image-modal .close {
    position: absolute;
    top: 10px;
    right: 15px;
    color: #333;
    font-size: 32px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10001;
}

/* 좌우 버튼 */
.image-modal .prev,
.image-modal .next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.6);
    border: none;
    color: #fff;
    font-size: 28px;
    padding: 8px 12px;
    cursor: pointer;
    border-radius: 50%;
    z-index: 10001;
}

.image-modal .prev { left: -40px; }   /* ✅ 박스 기준으로 바깥쪽 */
.image-modal .next { right: -40px; }  /* ✅ 박스 기준으로 바깥쪽 */

.image-modal .prev:hover,
.image-modal .next:hover {
    background: rgba(0,0,0,0.8);
}
