/* WooCommerce Reviews Manager Frontend Styles */

/* Reviews Section */
.wrm-reviews-section {
    margin-top: 30px;
}

/* Reviews Summary */
.wrm-reviews-summary {
    margin-bottom: 40px;
}

.wrm-reviews-summary h2 {
    margin-bottom: 20px;
    font-size: 24px;
}

.wrm-summary-container {
    display: flex;
    gap: 40px;
    align-items: flex-start;
    flex-wrap: wrap;
}

.wrm-average-rating {
    text-align: center;
    min-width: 150px;
}

.wrm-rating-number {
    font-size: 48px;
    font-weight: bold;
    color: #333;
    line-height: 1;
}

.wrm-stars {
    margin: 10px 0;
}

.wrm-stars .star-rating {
    font-size: 20px;
    margin: 0 auto;
}

.wrm-rating-text {
    color: #666;
    font-size: 14px;
}

.wrm-rating-bars {
    flex: 1;
    min-width: 300px;
}

.wrm-rating-bar-row {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
    gap: 10px;
}

.wrm-rating-label {
    min-width: 50px;
    font-size: 14px;
}

.wrm-rating-bar {
    flex: 1;
    height: 16px;
    background: #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
}

.wrm-rating-bar-fill {
    height: 100%;
    background: #ffb900;
    border-radius: 8px;
    transition: width 0.3s ease;
}

.wrm-rating-percentage {
    min-width: 40px;
    text-align: right;
    font-size: 14px;
    color: #666;
}

.wrm-no-reviews-yet {
    padding: 20px;
    background: #f8f9fa;
    border-radius: 5px;
    text-align: center;
    color: #666;
}

/* Review Form */
.wrm-review-form-section {
    background: #f8f9fa;
    padding: 30px;
    border-radius: 5px;
    margin-bottom: 40px;
}

.wrm-review-form-section h3 {
    margin-bottom: 20px;
    font-size: 20px;
}

.wrm-login-notice,
.wrm-purchase-notice {
    color: #666;
}

.wrm-login-notice a {
    color: #0073aa;
    text-decoration: underline;
}

.wrm-form-row {
    margin-bottom: 20px;
}

.wrm-form-row label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
}

.wrm-form-row .required {
    color: #dc3232;
}

/* Star Rating Input */
.wrm-star-rating-input {
    display: flex;
    flex-direction: row-reverse;
    justify-content: flex-end;
    gap: 5px;
}

.wrm-star-rating-input input[type="radio"] {
    display: none;
}

.wrm-star-rating-input label {
    cursor: pointer;
    margin: 0;
}

.wrm-star-rating-input .dashicons {
    font-size: 24px;
    color: #ddd;
    transition: color 0.2s;
}

.wrm-star-rating-input input[type="radio"]:checked ~ label .dashicons,
.wrm-star-rating-input label:hover .dashicons,
.wrm-star-rating-input label:hover ~ label .dashicons {
    color: #ffb900;
}

/* Form Fields */
.wrm-form-row input[type="text"],
.wrm-form-row textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.wrm-form-row textarea {
    resize: vertical;
    min-height: 100px;
}

.wrm-submit-review {
    background: #0073aa;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.2s;
}

.wrm-submit-review:hover {
    background: #005a87;
}

.wrm-form-spinner {
    display: none;
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #0073aa;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    vertical-align: middle;
    margin-left: 10px;
}

.wrm-form-spinner.active {
    display: inline-block;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.wrm-form-message {
    margin-top: 15px;
    padding: 10px;
    border-radius: 4px;
    display: none;
}

.wrm-form-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.wrm-form-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Reviews List */
.wrm-reviews-list {
    margin-top: 40px;
}

.wrm-reviews-list h3 {
    margin-bottom: 20px;
    font-size: 20px;
}

.wrm-review-items {
    list-style: none;
    margin: 0;
    padding: 0;
}

.wrm-review-item {
    border-bottom: 1px solid #e0e0e0;
    padding: 20px 0;
}

.wrm-review-item:last-child {
    border-bottom: none;
}

.wrm-review-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.wrm-review-author {
    display: flex;
    gap: 15px;
}

.wrm-reviewer-name {
    display: block;
    font-size: 16px;
    margin-bottom: 5px;
}

.wrm-verified-badge {
    display: inline-block;
    background: #46b450;
    color: white;
    font-size: 12px;
    padding: 2px 8px;
    border-radius: 3px;
    margin-bottom: 5px;
}

.wrm-review-date {
    color: #666;
    font-size: 14px;
}

.wrm-review-rating .star-rating {
    margin: 0;
}

.wrm-review-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 10px;
}

.wrm-review-content {
    color: #333;
    line-height: 1.6;
}

.wrm-no-reviews {
    padding: 20px;
    background: #f8f9fa;
    border-radius: 5px;
    text-align: center;
    color: #666;
}

/* Responsive */
@media screen and (max-width: 768px) {
    .wrm-summary-container {
        flex-direction: column;
        gap: 20px;
    }
    
    .wrm-average-rating {
        width: 100%;
    }
    
    .wrm-rating-bars {
        min-width: auto;
        width: 100%;
    }
    
    .wrm-review-header {
        flex-direction: column;
        gap: 10px;
    }
    
    .wrm-star-rating-input .dashicons {
        font-size: 20px;
    }
}