/* TBE Google Reviews - Public Styling */

:root {
    --tbe-primary: #2271b1;
    --tbe-bg: #121414;
    --tbe-card-bg: #ffffff;
    --tbe-border: rgba(0, 0, 0, 0.08);
    --tbe-text: inherit; 
    --tbe-text-muted: rgba(100, 100, 100, 0.8);
    --tbe-star: #ffb400; /* HARDCODED STANDARD YELLOW */
    --tbe-radius: 12px;
}

.tbe-reviews-container {
    padding: 20px 0;
    font-family: inherit;
    color: var(--tbe-text);
    width: 100%;
    box-sizing: border-box;
}

/* Badge Base Styles */
.tbe-reviews-badge {
    display: flex;
    align-items: center;
    width: fit-content;
    max-width: 100%; 
    margin: 0 auto 40px;
    font-family: inherit;
    transition: all 0.3s ease;
    text-decoration: none !important;
    box-sizing: border-box;
}

.tbe-reviews-badge:hover {
    transform: translateY(-2px);
}

/* Badge Style: Boxed */
.tbe-reviews-badge.tbe-badge-boxed {
    background: var(--tbe-card-bg, #fff);
    border: 1px solid var(--tbe-border, #d1d1d1);
    border-radius: 15px;
    padding: 15px 25px;
    gap: 20px;
    color: #1d2327 !important;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
}

.tbe-badge-boxed .tbe-badge-logo-side {
    padding-right: 20px;
    border-right: 1px solid var(--tbe-border, #d1d1d1);
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.tbe-badge-boxed .tbe-badge-content-side {
    display: flex;
    flex-direction: column;
}

.tbe-badge-boxed .tbe-badge-title {
    font-weight: 700;
    font-size: clamp(1rem, 4vw, 1.25rem);
    margin: 2px 0;
    color: #1d2327;
}

/* Badge Style: Minimal */
.tbe-reviews-badge.tbe-badge-minimal {
    background: var(--tbe-card-bg, rgba(255, 255, 255, 0.05));
    border: 1px solid var(--tbe-border);
    border-radius: 50px;
    padding: 10px 25px;
    gap: 15px;
    backdrop-filter: blur(10px);
    color: inherit;
}

.tbe-badge-minimal .tbe-badge-google {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    font-size: 0.85rem;
    text-transform: uppercase;
}

.tbe-badge-minimal .tbe-badge-info {
    font-size: 0.8rem;
    border-left: 1px solid var(--tbe-border);
    padding-left: 15px;
}

/* Badge Style: Clean */
.tbe-reviews-badge.tbe-badge-clean {
    background: transparent;
    border: none;
    padding: 0;
    gap: 15px;
    color: inherit;
}

/* Badge Shared Components - ALWAYS YELLOW */
.tbe-badge-stars,
.tbe-rating {
    display: flex;
    gap: 2px;
    color: var(--tbe-star) !important; /* Force standard yellow */
}

.tbe-badge-stars .tbe-star,
.tbe-rating .tbe-star {
    color: var(--tbe-star) !important;
}

/* Unfilled stars (only in cards) */
.tbe-star:not(.filled) {
    color: rgba(0, 0, 0, 0.1);
}

.tbe-badge-rating-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.tbe-badge-score {
    font-weight: 700;
    color: inherit;
}

/* Layouts */
.tbe-reviews-grid-wrapper {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)) !important;
    gap: 25px !important;
}

/* Review Card */
.tbe-review-card {
    background: var(--tbe-card-bg, #fff);
    border: 1px solid var(--tbe-border);
    border-radius: var(--tbe-radius);
    padding: 30px;
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    height: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    color: inherit;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
}

.tbe-review-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 4px;
    background: var(--tbe-primary); /* Accent Color from Settings */
    opacity: 0;
    transition: opacity 0.3s ease;
}

.tbe-review-card:hover {
    transform: translateY(-5px);
    border-color: var(--tbe-primary);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}

.tbe-review-card:hover::before {
    opacity: 1;
}

/* Header */
.tbe-review-header {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.tbe-author-img img,
.tbe-author-initial {
    width: 48px; height: 48px; border-radius: 50%;
    object-fit: cover; margin-right: 15px;
}

.tbe-author-initial {
    background: var(--tbe-primary); /* Accent Color */
    color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-weight: 700;
}

.tbe-author-name {
    font-weight: 700; font-size: 1.05rem; margin-bottom: 2px;
}

.tbe-date {
    font-size: 0.8rem; color: var(--tbe-text-muted);
}

.tbe-google-icon {
    position: absolute;
    top: 25px;
    right: 25px;
    z-index: 2;
}

.tbe-google-icon svg {
    width: 26px !important;
    height: 26px !important;
    opacity: 0.9 !important;
}

/* Content */
.tbe-review-content {
    font-size: 0.95rem; line-height: 1.7; flex-grow: 1;
    position: relative;
}

.tbe-review-content.tbe-clamped .tbe-review-text {
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;  
    overflow: hidden;
}

.tbe-read-more-btn {
    background: none;
    border: none;
    color: var(--tbe-primary);
    padding: 0;
    font-weight: 600;
    cursor: pointer;
    margin-top: 8px;
    font-size: 0.9em;
    text-decoration: underline;
    transition: all 0.2s ease;
}

.tbe-read-more-btn:hover {
    text-decoration: none;
    color: var(--tbe-text);
}

/* Reply */
.tbe-review-reply {
    margin-top: 20px; padding: 20px;
    background: rgba(0, 0, 0, 0.02);
    border-radius: 10px;
    border-left: 3px solid var(--tbe-primary);
}

.tbe-reply-label {
    display: block; font-weight: 700; color: var(--tbe-primary);
    margin-bottom: 5px; font-size: 0.75rem;
    text-transform: uppercase; letter-spacing: 1px;
}

/* Swiper */
.tbe-reviews-swiper {
    padding: 20px 0 60px !important;
}

.tbe-reviews-swiper .swiper-button-next,
.tbe-reviews-swiper .swiper-button-prev {
    color: var(--tbe-primary) !important;
    background: #fff; width: 44px; height: 44px; border-radius: 50%;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* Responsive */
@media (max-width: 600px) {
    .tbe-reviews-badge.tbe-badge-boxed {
        flex-direction: column; padding: 25px; text-align: center;
    }
    .tbe-badge-boxed .tbe-badge-logo-side {
        border-right: none; border-bottom: 1px solid var(--tbe-border);
        padding-right: 0; padding-bottom: 15px; width: 100%; justify-content: center;
    }
    .tbe-reviews-badge.tbe-badge-minimal {
        padding: 12px 15px; gap: 10px; width: 100%;
    }
}
