/* Google Business Reviews - Frontend Styles */
/* Inherits fonts from theme - no font-family declarations */

.gbr-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

/* Business Header */
.gbr-business-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 30px;
    margin-bottom: 40px;
}

.gbr-business-info {
    flex: 1;
}

.gbr-business-name {
    font-size: 28px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 12px 0;
    letter-spacing: -0.02em;
}

.gbr-business-rating {
    display: flex;
    align-items: center;
    gap: 12px;
}

.gbr-stars {
    display: flex;
    gap: 2px;
}

.gbr-star {
    font-size: 20px;
    line-height: 1;
}

.gbr-star-full {
    color: #FDB241;
}

.gbr-star-half {
    color: #FDB241;
    position: relative;
}

.gbr-star-half::after {
    content: '★';
    position: absolute;
    left: 0;
    width: 50%;
    overflow: hidden;
    color: #ddd;
}

.gbr-star-empty {
    color: #ddd;
}

.gbr-rating-text {
    font-size: 16px;
    color: #1a1a1a;
}

.gbr-rating-text strong {
    font-weight: 600;
    margin-right: 4px;
}

.gbr-rating-count {
    color: #666;
}

.gbr-write-review {
    display: inline-block;
    padding: 12px 28px;
    background: #1a1a1a;
    color: #fff;
    text-decoration: none;
    border-radius: 0;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    letter-spacing: 0.02em;
}

.gbr-write-review:hover {
    background: #333;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Reviews Container */
.gbr-reviews {
    display: grid;
    gap: 18px;
}

.gbr-reviews.list {
    grid-template-columns: 1fr;
}

.gbr-reviews.grid {
    grid-template-columns: repeat(4, 1fr);
}

/* Grid responsive breakpoints: 4 cols → 2 cols → 1 col */
@media (max-width: 1200px) {
    .gbr-reviews.grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .gbr-reviews.grid {
        grid-template-columns: 1fr;
    }
}

/* Individual Review */
.gbr-review {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 0;
    padding: 24px;
    transition: all 0.3s ease;
}

.gbr-review:hover {
    border-color: #d0d0d0;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

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

.gbr-reviewer {
    display: flex;
    gap: 12px;
    align-items: center;
}

.gbr-reviewer-photo {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    align-self: flex-start;
}

.gbr-reviewer-initials {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: 600;
}

.gbr-reviewer-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.gbr-reviewer-name {
    font-size: 16px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0;
    line-height: 1;
}

.gbr-review-time {
    font-size: 13px;
    color: #999;
}

.gbr-review-rating {
    flex-shrink: 0;
}

.gbr-review-rating .gbr-star {
    font-size: 16px;
}

.gbr-review-content {
    line-height: 1.6;
}

.gbr-review-content p {
    margin: 0;
    color: #444;
    font-size: 15px;
}

/* Read more/less link styling */
.gbr-read-more {
    color: #fa3f55;
    text-decoration: none;
    font-weight: 500;
    cursor: pointer;
}

.gbr-read-more:hover {
    text-decoration: underline;
}

/* No Reviews Message */
.gbr-no-reviews {
    text-align: center;
    padding: 60px 20px;
    color: #999;
    font-size: 16px;
}

/* View All Reviews Button */
.gbr-view-all-container {
    text-align: center;
    margin-top: 40px;
    padding-top: 0;
}

.gbr-view-all-reviews {
    display: inline-block;
    padding: 14px 32px;
    background: #fff;
    color: #1a1a1a;
    text-decoration: none;
    border: 2px solid #1a1a1a;
    border-radius: 0;
    font-size: 15px;
    font-weight: 500;
    transition: all 0.3s ease;
    letter-spacing: 0.02em;
}

.gbr-view-all-reviews:hover {
    background: #1a1a1a;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.gbr-view-all-reviews:focus {
    outline: 2px solid #667eea;
    outline-offset: 2px;
}

/* Error Message */
.gbr-error {
    background: #fee;
    border: 1px solid #fcc;
    border-radius: 0;
    padding: 16px 20px;
    color: #c00;
    font-size: 14px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .gbr-business-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }
    
    .gbr-write-review {
        width: 100%;
        text-align: center;
    }
    
    .gbr-view-all-reviews {
        width: 100%;
        text-align: center;
        padding: 16px 20px;
    }
    
    .gbr-business-name {
        font-size: 24px;
    }
    
    .gbr-reviews.grid {
        grid-template-columns: 1fr;
    }
    
    .gbr-review {
        padding: 20px;
    }
    
    .gbr-review-header {
        flex-direction: column;
        gap: 12px;
    }
    
    .gbr-review-rating {
        align-self: flex-start;
    }
}

@media (max-width: 480px) {
    .gbr-container {
        padding: 30px 16px;
    }
    
    .gbr-business-name {
        font-size: 20px;
    }
    
    .gbr-reviewer-photo {
        width: 40px;
        height: 40px;
    }
    
    .gbr-reviewer-initials {
        font-size: 18px;
    }
    
    .gbr-review {
        padding: 16px;
    }
}

/* Loading State */
.gbr-container.loading {
    opacity: 0.6;
    pointer-events: none;
}

.gbr-container.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    margin: -20px 0 0 -20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #1a1a1a;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Accessibility */
.gbr-write-review:focus,
.gbr-review:focus-within {
    outline: 2px solid #667eea;
    outline-offset: 2px;
}

/* Print Styles */
@media print {
    .gbr-write-review {
        display: none;
    }
    
    .gbr-review {
        page-break-inside: avoid;
        box-shadow: none;
        border: 1px solid #ddd;
    }
}
