/* ========== 基础布局与通用样式 ========== */
.review-head,
.line-summary {
    display: flex;
    justify-content: center;
    align-items: center;
}

.review-head {
    margin: 70px 0;
    font-size: 20px;
    color: #2c2c2c;
}

.line-summary {
    gap: 10px;
    margin-bottom: 40px;
}

.line-score {
    font-family: Urbanist;
    font-weight: 300;
    font-size: 48px;
    color: #2e4f7c;
}

.line-stars {
    display: flex;
}

.line-stars img {
    width: 24px;
}

.line-text {
    font-family: Urbanist;
    font-size: 14px;
    color: #2c2c2c;
}

.page-head {
    padding-bottom: 20px;
    border-bottom: 2px solid rgb(234,234,234);
}

.page-head span {
    font-family: Urbanist;
    border-bottom: 1px solid #2c2c2c;
    color: #2c2c2c;
}

.page-head span:hover {
    color: #3E3E3E;
    box-shadow: inset 0 0 200px rgb(0 0 0 / .1);
    cursor: pointer;
}

.reviews-item {
    border-bottom: 2px solid rgb(234,234,234);
}

/* ========== 评价项结构 ========== */
.item-head {
    display: flex;
    flex-wrap: wrap;
    margin: 40px 0 50px;
}

.item-left {
    display: flex;
    flex-basis: 18%;
}

.item-left .user {
    width: 40px;
    margin-right: 8px;
}

.verified .username {
    font-family: 'Urbanist';
    color: #2c2c2c;
}

.verified .verified-text {
    font-size: 13px;
    color: #2e4f7c;
}

.item-center {
    flex-basis: 63%;
    padding: 0 15px;
}

.item-right {
    flex-basis: 19%;
    text-align: end;
}

.center-head {
    display: flex;
    margin-bottom: 16px;
}

.center-head .reviews-title {
    font-family: Urbanist;
    font-weight: 300;
    font-size: 18px;
    margin-left: 10px;
    padding-top: 3px;
}

.review-images img {
    border: 2px solid transparent !important;
}

.review-images img:hover {
    border-color: #2e4f7c !important;
}

.center-foot {
    margin-top: 12px;
    font-size: 12px;
    color: #373330;
}

.center-foot a {
    font-weight: 600;
}

.center-foot a:hover {
    text-decoration: underline;
}

.item-foot {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 10px;
}

.help-text {
    margin-right: 8px;
}

.votes {
    display: flex;
    align-items: center;
    gap: 3px;
    margin-right: 7px;
}

.vote-btn {
    height: 19px;
    padding: 0;
    background-color: #fff;
    cursor: pointer;
    border: none;
}

.vote-btn img {
    width: 15px;
}

.vote-btn:hover {
    box-shadow: none;
}

.downp {
    transform: rotate(180deg);
}

.read-more {
    color:#2e4f7c;
}

/* ========== 分页样式 ========== */
.pagination {
    margin: 40px 0 70px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

.pagination ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    gap: 5px;
}

.pagination li {
    display: inline-flex;
}

.pagination a,
.pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 30px;
    padding: 0 12px;
    font-family: Urbanist;
    font-size: 16px;
    color: #2c2c2c;
    background-color: #fff;
    border-radius: 4px;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pagination a:hover {
    background-color: #2e4f7c;
    border-color: #2e4f7c;
    color: #fff;
}

.pagination .current {
    background-color: #2e4f7c;
    border-color: #2e4f7c;
    color: #fff;
}

.pagination .current:hover {
    opacity: 0.8;
}

.pagination .disabled {
    opacity: 0.3;
    cursor: not-allowed;
    pointer-events: none;
}

.pagination .prev-btn,
.pagination .next-btn {
    font-size: 30px;
}

.pagination .prev-btn:hover,
.pagination .next-btn:hover {
    background-color: rgba(241,241,241,0.682);
    color: #2c2c2c;
}

/* ========== 加载状态与骨架屏 ========== */
.loading-reviews {
    min-height: 200px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 60px;
}

.loading-skeleton {
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

@keyframes skeletonShine {
    0% { background-position: -200px 0; }
    100% { background-position: calc(200px + 100%) 0; }
}

.skeleton-avatar,
.skeleton-line,
.skeleton-stars,
.skeleton-date,
.skeleton-vote-btn,
.skeleton-vote-count {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200px 100%;
    animation: skeletonShine 1.5s infinite;
    border-radius: 4px;
}

.skeleton-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
}

.skeleton-stars {
    width: 120px;
    height: 20px;
}

.skeleton-date {
    width: 80px;
    height: 14px;
    margin-left: auto;
}

.skeleton-vote-btn {
    width: 20px;
    height: 19px;
    border-radius: 3px;
}

.skeleton-vote-btn.downp {
    transform: rotate(180deg);
}

.skeleton-vote-count {
    width: 15px;
    height: 14px;
    border-radius: 2px;
}

/* 骨架屏布局 */
.loading-skeleton .item-head {
    display: flex;
    flex-wrap: wrap;
    margin: 40px 0 50px;
}

.loading-skeleton .item-left {
    display: flex;
    flex-basis: 18%;
}

.loading-skeleton .item-center {
    flex-basis: 63%;
    padding: 0 15px;
}

.loading-skeleton .item-right {
    flex-basis: 19%;
    text-align: end;
}

.loading-skeleton .center-head {
    display: flex;
    margin-bottom: 16px;
    align-items: center;
}

.loading-skeleton .item-foot {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 20px;
    margin-bottom: 10px;
}

.loading-skeleton .votes {
    display: flex;
    align-items: center;
    gap: 3px;
    margin-right: 7px;
}

.loading-skeleton .help-text {
    margin-right: 8px;
    color: transparent;
}

/* ========== 评价图片弹窗 ========== */
.review-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.85);
    z-index: 9999;
    display: none;
    justify-content: center;
    align-items: center;
}

.review-modal-content {
    position: relative;
    background-color: #fff;
    border-radius: 8px;
    max-width: 90%;
    max-height: 90%;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
    animation: modalFadeIn 0.3s ease-out;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.review-modal-close {
    position: absolute;
    top: 4px;
    right: 8px;
    font-size: 32px;
    font-weight: 300;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    line-height: 30px;
    z-index: 10;
    transition: color 0.2s;
}

.review-modal-body {
    display: flex;
    gap: 40px;
    width: 977px;
    height: 100%;
    padding: 40px;
}

.review-modal-left {
    position: relative;
    display: flex;
    justify-content: center;
    width: 100%;
    height: 502px;
    background-color: #ececec;
}

.review-modal-image {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
}

.modal-prev-btn,
.modal-next-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s;
    z-index: 5;
    filter: invert(1) hue-rotate(180deg);
    opacity: 0.7;
}

.modal-prev-btn {
    left: 6px;
}

.modal-next-btn {
    right: 6px;
}

.modal-prev-btn.hidden,
.modal-next-btn.hidden {
    display: none;
}

.review-modal-right {
    width: 380px;
    overflow-y: auto;
    background-color: #fff;
    flex-shrink: 0;
}

.modal-review-header {
    display: flex;
    margin-bottom: 20px;
}

.modal-review-header .item-left {
    display: flex;
    align-items: center;
    flex-basis: 100%;
}

.modal-review-header .user img {
    width: 50px;
    margin-right: 12px;
}

.modal-review-header .username {
    font-family: Urbanist;
    font-weight: 300;
    color: #2c2c2c;
    font-size: 16px;
}

.modal-review-header .verified-text {
    font-family: Urbanist;
    font-weight: 300;
    font-size: 13px;
    color: #2e4f7c;
}

.modal-review-header .item-right {
    font-size: 12px;
}

.modal-review-stars {
    margin-bottom: 10px;
}

.modal-review-title {
    font-family: Urbanist;
    font-weight: 300;
    font-size: 16px;
    color: #2c2c2c;
    margin-bottom: 18px;
}

.modal-review-images-gallery {
    display: flex;
    gap: 8px;
    margin-bottom: 18px;
}

.modal-review-images-gallery img {
    width: 80px;
    height: 80px !important;
    object-fit: cover;
    border: 2px solid transparent !important;
    cursor: pointer;
    transition: border-color 0.2s;
}

.modal-review-images-gallery img:hover,
.modal-review-images-gallery img.active {
    border-color: #2e4f7c !important;
}

.modal-review-content {
    font-family: Urbanist;
    font-weight: 300;
    font-size: 16px;
    line-height: 1.6;
    color: #2c2c2c;
    margin-bottom: 20px;
}

/* ========== 响应式设计 ========== */
@media (max-width: 768px) {
    .item-head {
        flex-wrap: wrap;
    }
    
    .item-left {
        flex-basis: 100%;
        margin-bottom: 10px;
    }
    
    .item-center {
        flex-basis: 100%;
        order: 3;
    }
    
    .item-right {
        flex-basis: 100%;
        text-align: start;
        order: 2;
        margin-bottom: 10px;
    }
    
    .pagination {
        gap: 4px;
    }
    
    .pagination a,
    .pagination span {
        min-width: 32px;
        height: 32px;
        padding: 0 10px;
        font-size: 13px;
    }
    
    .review-modal-body {
        flex-direction: column;
        width: auto;
        height: auto;
    }
    
    .review-modal-right {
        width: 100%;
        max-height: 40vh;
    }
    
    .review-modal-left {
        height: auto;
        max-height: 50vh;
    }
}

/* ========== 交互状态 ========== */
.vote-btn.voted {
    filter: brightness(1.3);
    opacity: 0.4;
}

.vote-btn.processing {
    pointer-events: none;
}

.error-msg {
    text-align: center;
    padding: 40px;
    color: #d9534f;
}

.error-msg button {
    margin-top: 15px;
    padding: 6px 16px;
    background: #2e4f7c;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}