/* Riviu Overlay Styles */

.riviu-overlay-backdrop {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 99998;
    display: none;
    opacity: 0;
    transition: opacity 0.3s;
}
.riviu-overlay-backdrop.active {
    display: block;
    opacity: 1;
}

.riviu-overlay {
    position: fixed;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: 90%;
    max-width: 640px;
    max-height: 85vh;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    z-index: 99999;
    display: none;
    flex-direction: column;
    overflow: hidden;
}
.riviu-overlay.active {
    display: flex;
}

.riviu-overlay-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px 16px;
    border-bottom: 1px solid #eee;
}

.riviu-overlay-title {
    font-size: 18px;
    font-weight: 700;
    margin: 0;
}

.riviu-overlay-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #666;
    padding: 4px 8px;
    line-height: 1;
    border-radius: 4px;
}
.riviu-overlay-close:hover {
    background: #f0f0f0;
    color: #333;
}

.riviu-overlay-stats {
    padding: 12px 24px;
    background: #f9f9f9;
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.riviu-stats-avg {
    font-size: 28px;
    font-weight: 700;
}

.riviu-stats-count {
    color: #666;
    font-size: 14px;
}

.riviu-star-filters {
    display: flex;
    gap: 6px;
    margin-left: auto;
}

.riviu-star-filter-btn {
    padding: 4px 10px;
    border: 1px solid #ddd;
    background: #fff;
    border-radius: 16px;
    cursor: pointer;
    font-size: 13px;
}
.riviu-star-filter-btn.active,
.riviu-star-filter-btn:hover {
    background: #2271b1;
    color: #fff;
    border-color: #2271b1;
}

.riviu-overlay-body {
    overflow-y: auto;
    flex: 1;
    padding: 16px 24px;
}

.riviu-review-card {
    padding: 16px 0;
    border-bottom: 1px solid #eee;
}
.riviu-review-card:last-child {
    border-bottom: none;
}

.riviu-review-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.riviu-reviewer-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #e0e0e0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 16px;
    color: #555;
}

.riviu-reviewer-info {
    flex: 1;
}

.riviu-reviewer-name {
    font-weight: 600;
    font-size: 14px;
}

.riviu-reviewer-meta {
    display: flex;
    gap: 8px;
    color: #888;
    font-size: 12px;
    align-items: center;
}

.riviu-verified-badge {
    color: #0a0;
    font-size: 11px;
    display: flex;
    align-items: center;
    gap: 2px;
}

.riviu-review-title {
    font-weight: 600;
    margin: 6px 0 4px;
}

.riviu-review-text {
    font-size: 14px;
    line-height: 1.6;
    color: #333;
}

.riviu-review-image {
    margin-top: 10px;
}
.riviu-review-image img {
    max-width: 200px;
    border-radius: 6px;
    cursor: pointer;
}

.riviu-review-media {
    margin-top: 10px;
}

.riviu-owner-reply {
    margin-top: 12px;
    padding: 10px 14px;
    background: #f5f5f5;
    border-left: 3px solid #2271b1;
    border-radius: 4px;
    font-size: 13px;
}

.riviu-owner-reply-label {
    font-weight: 600;
    font-size: 12px;
    color: #2271b1;
    margin-bottom: 4px;
}

.riviu-featured-badge {
    background: #fff8e1;
    color: #f57c00;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 600;
}

.riviu-overlay-footer {
    padding: 12px 24px;
    border-top: 1px solid #eee;
    text-align: center;
}

.riviu-backlink-masked {
    cursor: pointer;
    text-decoration: underline;
    color: #2271b1;
}

.riviu-loading {
    text-align: center;
    padding: 40px;
    color: #888;
}

.riviu-no-reviews {
    text-align: center;
    padding: 40px;
    color: #888;
}

/* Mobile */
@media (max-width: 640px) {
    .riviu-overlay {
        width: 100%;
        height: 100%;
        max-height: 100vh;
        border-radius: 0;
        top: 0;
        left: 0;
        transform: none;
    }
    .riviu-star-filters {
        margin-left: 0;
        margin-top: 8px;
    }
    .riviu-overlay-stats {
        flex-direction: column;
        align-items: flex-start;
    }
}
