/* ========================================
   استایل بخش نظرات
   ======================================== */

.reviews-section {
    margin-top: 30px;
    padding: 20px;
    background: #fff;
    border-radius: 12px;
    border: 1px solid #e9ecef;
}

.reviews-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #ffcc00;
}

.reviews-summary {
    display: flex;
    align-items: center;
    gap: 10px;
}

.avg-rating {
    font-size: 24px;
    font-weight: 700;
    color: #1a1a2e;
}

.stars {
    font-size: 20px;
    letter-spacing: 2px;
}

.total-reviews {
    font-size: 14px;
    color: #888;
}

.btn-review {
    background: #ffcc00;
    color: #1a1a2e;
    border: none;
    padding: 10px 25px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-review:hover {
    background: #e6b800;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(255, 204, 0, 0.4);
}

/* ===== آیتم نظرات ===== */
.review-item {
    padding: 15px;
    margin-bottom: 15px;
    background: #f8f9fa;
    border-radius: 10px;
    border-right: 3px solid #ffcc00;
}

.review-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.review-name {
    font-weight: 600;
    color: #1a1a2e;
    font-size: 15px;
}

.review-rating {
    font-size: 16px;
    letter-spacing: 1px;
}

.review-date {
    font-size: 12px;
    color: #aaa;
}

.review-text {
    font-size: 14px;
    color: #555;
    line-height: 1.8;
}

/* ===== پاسخ‌ها ===== */
.reply-item {
    margin-top: 10px;
    margin-right: 30px;
    padding: 12px 15px;
    background: #e9ecef;
    border-radius: 8px;
    border-right: 3px solid #2dbe6c;
}

.reply-name {
    font-weight: 600;
    color: #2dbe6c;
    font-size: 13px;
    display: block;
    margin-bottom: 4px;
}

.reply-text {
    font-size: 14px;
    color: #555;
}

/* ===== مودال ===== */
.review-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}

.review-modal-content {
    position: relative;
    margin: 5% auto;
    width: 90%;
    max-width: 500px;
    background: #fff;
    border-radius: 16px;
    padding: 30px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: modalSlide 0.3s ease;
}

@keyframes modalSlide {
    from {
        transform: translateY(-30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.close-modal {
    position: absolute;
    top: 15px;
    left: 20px;
    font-size: 28px;
    cursor: pointer;
    color: #888;
    transition: all 0.3s;
    background: none;
    border: none;
}

.close-modal:hover {
    color: #e91e63;
    transform: rotate(90deg);
}

.review-modal h3 {
    text-align: center;
    color: #1a1a2e;
    margin-bottom: 20px;
    font-size: 20px;
}

.review-modal input,
.review-modal textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 14px;
    margin-bottom: 12px;
    transition: border 0.3s;
    box-sizing: border-box;
}

.review-modal input:focus,
.review-modal textarea:focus {
    border-color: #ffcc00;
    outline: none;
}

.review-modal textarea {
    height: 100px;
    resize: vertical;
}

.rating-input {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 10px 0;
}

.stars-input .star {
    font-size: 28px;
    cursor: pointer;
    transition: all 0.2s;
    color: #ccc;
}

.stars-input .star:hover {
    transform: scale(1.2);
}

.review-modal button[type="button"] {
    width: 100%;
    padding: 12px;
    background: #ffcc00;
    color: #1a1a2e;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.review-modal button[type="button"]:hover {
    background: #e6b800;
}

/* ===== ریسپانسیو ===== */
@media (max-width: 768px) {
    .reviews-header {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }
    
    .btn-review {
        width: 100%;
        text-align: center;
    }
    
    .review-modal-content {
        margin: 10% auto;
        padding: 20px;
        width: 95%;
    }
    
    .reply-item {
        margin-right: 10px;
    }
}