/* WC Products Enhancements Plus - Frontend Styles */

/* ==========================================================================
   Live Viewers Counter
   ========================================================================== */

.wcpep-live-viewers {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 12px 20px;
    margin-bottom: 15px;
    font-size: 15px;
    color: #333;
    /* display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: nowrap;
    white-space: nowrap; */
}

.wcpep-live-dot {
    width: 10px;
    height: 10px;
    background: #28a745;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
    animation: wcpep-pulse 1.5s infinite;
}

@keyframes wcpep-pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(40, 167, 69, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(40, 167, 69, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(40, 167, 69, 0);
    }
}

.wcpep-live-count {
    font-weight: 700;
    color: #333;
}

.wcpep-live-viewers strong {
    font-weight: 700;
}

/* ==========================================================================
   Store Leader Badge
   ========================================================================== */

.wcpep-store-leader-card {
    background: #ffffff;
    border: 1px solid #e5e5e5;
    border-radius: 12px;
    padding: 20px;
    margin-top: 15px;
    margin-bottom: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

/* Header */
.wcpep-sl-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.wcpep-sl-badge-leader {
    flex-shrink: 0;
}

.wcpep-sl-badge-leader img {
    width: 60px;
    height: 60px;
    object-fit: contain;
}

.wcpep-sl-title-wrapper {
    flex: 1;
}

.wcpep-sl-title {
    font-size: 18px;
    font-weight: 700;
    color: #00a650;
    margin: 0 0 4px 0;
    line-height: 1.2;
}

.wcpep-sl-subtitle {
    font-size: 14px;
    color: #333;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 900;
}

.wcpep-sl-verified-inline {
    width: 18px;
    height: 18px;
    object-fit: contain;
}

.wcpep-sl-store-icon {
    flex-shrink: 0;
}

.wcpep-sl-store-icon img {
    width: 50px;
    height: 50px;
    object-fit: contain;
}

/* Progress Bar */
.wcpep-sl-progress-bar {
    height: 6px;
    background: #e5e5e5;
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 15px;
}

.wcpep-sl-progress-fill {
    height: 100%;
    background: linear-gradient(to right, #ff6b6b, #ff8e53, #feca57, #48dbfb, #00d2d3, #1dd1a1);
    width: 100%;
    border-radius: 3px;
    animation: wcpep-sl-progress-animation 2s ease-in-out infinite;
}

@keyframes wcpep-sl-progress-animation {
    0%, 100% {
        opacity: 0.8;
    }
    50% {
        opacity: 1;
    }
}

/* Stats */
.wcpep-sl-stats {
    display: flex;
    gap: 20px;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e5e5e5;
}

.wcpep-sl-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 8px;
}

.wcpep-sl-stat:first-child {
    align-items: flex-start;
    text-align: left;
}

.wcpep-sl-stat-value {
    font-size: 20px;
    font-weight: 700;
    color: #333;
}

.wcpep-sl-stat-icon img {
    width: 40px;
    height: 40px;
    object-fit: contain;
}

.wcpep-sl-stat-label {
    font-size: 12px;
    color: #666;
    line-height: 1.3;
}

/* Footer */
.wcpep-sl-footer {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.wcpep-sl-footer-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 13px;
    color: #666;
    line-height: 1.4;
}

.wcpep-sl-footer-icon {
    width: 20px;
    height: 20px;
    object-fit: contain;
    flex-shrink: 0;
    margin-top: 2px;
}

.wcpep-sl-footer-link {
    color: #3483fa;
    text-decoration: none;
    font-weight: 500;
}

.wcpep-sl-footer-link:hover {
    text-decoration: underline;
}

.wcpep-sl-footer-text {
    color: #666;
}

/* Responsive */
@media (max-width: 768px) {
    .wcpep-store-leader-card {
        padding: 15px;
    }
    
    .wcpep-sl-header {
        gap: 10px;
    }
    
    .wcpep-sl-badge-leader img {
        width: 50px;
        height: 50px;
    }
    
    .wcpep-sl-store-icon img {
        width: 40px;
        height: 40px;
    }
    
    .wcpep-sl-title {
        font-size: 16px;
    }
    
    .wcpep-sl-subtitle {
        font-size: 13px;
    }
    
    .wcpep-sl-stats {
        gap: 15px;
        flex-wrap: wrap;
    }
    
    .wcpep-sl-stat-value {
        font-size: 18px;
    }
    
    .wcpep-sl-stat-icon img {
        width: 32px;
        height: 32px;
    }
    
    .wcpep-sl-stat-label {
        font-size: 11px;
    }
    
    .wcpep-sl-footer-item {
        font-size: 12px;
    }
}

/* ==========================================================================
   FAQs Section
   ========================================================================== */

.wcpep-faqs-container {
    padding: 40px 20px;
    margin: 40px 0;
    border-radius: 12px;
}

.wcpep-faqs-card {
    max-width: 900px;
    margin: 0 auto;
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08);
}

.wcpep-faqs-title {
    text-align: center;
    font-size: 24px;
    font-weight: 700;
    margin: 0 0 10px 0;
    letter-spacing: 0.5px;
}

.wcpep-faqs-subtitle {
    text-align: center;
    font-size: 16px;
    margin: 0 0 30px 0;
}

.wcpep-faqs-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.wcpep-faq-dropdown {
    border-bottom: 1px solid #e0e0e0;
}

.wcpep-faq-dropdown:last-child {
    border-bottom: none;
}

.wcpep-faq-question {
    width: 100%;
    background: transparent;
    border: none;
    padding: 18px 0;
    text-align: left;
    font-size: 16px;
    font-weight: 500;
    color: #333;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: color 0.3s ease;
}

.wcpep-faq-question:hover {
    color: #0073aa;
}

.wcpep-faq-question span {
    flex: 1;
    padding-right: 15px;
}

.wcpep-faq-icon {
    transition: transform 0.3s ease;
    color: #999;
    flex-shrink: 0;
}

.wcpep-faq-dropdown.active .wcpep-faq-icon {
    transform: rotate(180deg);
}

.wcpep-faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
}

.wcpep-faq-dropdown.active .wcpep-faq-answer {
    max-height: 500px;
}

.wcpep-faq-answer-content {
    padding: 0 0 18px 0;
    color: #555;
    line-height: 1.6;
    font-size: 15px;
}

/* ==========================================================================
   Reviews Section
   ========================================================================== */

.wcpep-reviews-section {
    margin: 60px 0;
    padding: 0 15px;
}

.wcpep-reviews-main-title {
    text-align: center;
    font-size: 28px;
    font-weight: 700;
    color: #1e3a5f;
    margin: 0 0 40px 0;
    letter-spacing: 1px;
}

/* New Review Card */
.wcpep-new-review-card {
    background: #f8f9fa;
    border-radius: 16px;
    padding: 40px;
    margin-bottom: 30px;
    max-width: 1000px;
    margin-left: auto;
    margin-right: auto;
}

.wcpep-new-review-title {
    text-align: center;
    font-size: 22px;
    font-weight: 600;
    color: #333;
    margin: 0 0 30px 0;
}

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

.wcpep-form-row-inline {
    display: flex;
    gap: 20px;
    align-items: center;
    flex-wrap: wrap;
}

.wcpep-rating-select {
    display: flex;
    align-items: center;
    gap: 10px;
}

.wcpep-rating-select label {
    font-weight: 500;
    color: #666;
}

.wcpep-stars-input {
    display: flex;
    gap: 5px;
}

.wcpep-stars-input .wcpep-star {
    font-size: 28px;
    color: #ddd;
    cursor: pointer;
    transition: color 0.2s ease, transform 0.2s ease;
}

.wcpep-stars-input .wcpep-star:hover,
.wcpep-stars-input .wcpep-star.active {
    color: #ffc107;
    transform: scale(1.1);
}

.wcpep-email-input {
    flex: 1;
    min-width: 250px;
}

.wcpep-email-input input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 15px;
    transition: border-color 0.3s ease;
}

.wcpep-email-input input:focus {
    outline: none;
    border-color: #0073aa;
}

.wcpep-form-row-content {
    display: flex;
    gap: 20px;
    align-items: stretch;
}

.wcpep-comment-area {
    flex: 1;
}

.wcpep-comment-area textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 15px;
    resize: vertical;
    min-height: 150px;
    transition: border-color 0.3s ease;
}

.wcpep-comment-area textarea:focus {
    outline: none;
    border-color: #0073aa;
}

.wcpep-image-upload-area {
    width: 180px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.wcpep-image-preview {
    background: #e9ecef;
    border-radius: 8px;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

.wcpep-image-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.wcpep-preview-text {
    color: #999;
    font-size: 14px;
}

.wcpep-preview-count {
    position: absolute;
    bottom: 5px;
    right: 5px;
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 12px;
}

.wcpep-upload-btn {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 10px 15px;
    font-size: 13px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s ease;
}

.wcpep-upload-btn:hover {
    background: #f8f9fa;
    border-color: #0073aa;
    color: #0073aa;
}

.wcpep-form-submit {
    text-align: center;
    margin-top: 20px;
}

.wcpep-submit-review-btn {
    background: #0073aa;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 14px 40px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.2s ease;
}

.wcpep-submit-review-btn:hover {
    background: #005a87;
    transform: translateY(-2px);
}

.wcpep-submit-review-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

/* Reviews Filter */
.wcpep-reviews-filter {
    margin-bottom: 25px;
}

.wcpep-reviews-filter label {
    font-size: 15px;
    color: #555;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.wcpep-reviews-filter input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

/* Reviews Wall - Masonry */
.wcpep-reviews-wall {
    column-count: 4;
    column-gap: 20px;
}

.wcpep-review-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 20px;
    break-inside: avoid;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.wcpep-review-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.12);
}

.wcpep-review-images {
    position: relative;
    width: 100%;
    overflow: hidden;
}

.wcpep-review-images img {
    width: 100%;
    height: auto;
    display: block;
}

/* Image Slider */
.wcpep-image-slider {
    position: relative;
    width: 100%;
}

.wcpep-slide {
    display: none;
}

.wcpep-slide.active {
    display: block;
}

.wcpep-slider-prev,
.wcpep-slider-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 16px;
    color: #333;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease;
    z-index: 10;
}

.wcpep-slider-prev:hover,
.wcpep-slider-next:hover {
    background: #fff;
}

.wcpep-slider-prev {
    left: 10px;
}

.wcpep-slider-next {
    right: 10px;
}

.wcpep-slider-dots {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    z-index: 10;
}

.wcpep-dot {
    width: 8px;
    height: 8px;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    cursor: pointer;
    transition: background 0.3s ease;
}

.wcpep-dot.active {
    background: #fff;
}

.wcpep-review-content {
    padding: 15px;
}

.wcpep-review-rating {
    margin-bottom: 10px;
}

.wcpep-review-rating .wcpep-star {
    font-size: 18px;
}

.wcpep-review-rating .wcpep-star.filled {
    color: #ffc107;
}

.wcpep-review-rating .wcpep-star.empty {
    color: #ddd;
}

.wcpep-review-text {
    color: #333;
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 10px;
}

.wcpep-view-more {
    color: #0073aa;
    text-decoration: none;
    font-weight: 500;
    font-size: 13px;
}

.wcpep-view-more:hover {
    text-decoration: underline;
}

.wcpep-review-date {
    color: #999;
    font-size: 13px;
}

.wcpep-no-reviews {
    text-align: center;
    color: #999;
    font-size: 16px;
    padding: 40px 0;
}

/* ==========================================================================
   Responsive Styles
   ========================================================================== */

@media (max-width: 1200px) {
    .wcpep-reviews-wall {
        column-count: 3;
    }
}

@media (max-width: 992px) {
    .wcpep-reviews-wall {
        column-count: 2;
    }
    
    .wcpep-faqs-card {
        padding: 30px;
    }
}

@media (max-width: 768px) {
    .wcpep-new-review-card {
        padding: 25px;
    }
    
    .wcpep-form-row-inline {
        flex-direction: column;
        align-items: stretch;
    }
    
    .wcpep-form-row-content {
        flex-direction: column;
    }
    
    .wcpep-image-upload-area {
        width: 100%;
        flex-direction: row;
        align-items: center;
    }
    
    .wcpep-image-preview {
        width: 120px;
        height: 80px;
    }
    
    .wcpep-upload-btn {
        flex: 1;
    }
    
    .wcpep-faqs-card {
        padding: 20px;
    }
    
    .wcpep-faqs-title {
        font-size: 20px;
    }
    
    .wcpep-reviews-main-title {
        font-size: 22px;
    }
}

@media (max-width: 576px) {
    .wcpep-reviews-wall {
        column-count: 2;
        column-gap: 15px;
    }
    
    .wcpep-review-card {
        margin-bottom: 15px;
    }
    
    .wcpep-live-viewers {
        font-size: 14px;
        padding: 10px 15px;
    }
}

/* ==========================================================================
   Loading States
   ========================================================================== */

.wcpep-loading {
    opacity: 0.6;
    pointer-events: none;
}

.wcpep-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #0073aa;
    border-radius: 50%;
    animation: wcpep-spin 1s linear infinite;
}

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

/* ==========================================================================
   Messages
   ========================================================================== */

.wcpep-message {
    padding: 12px 20px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-size: 14px;
}

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

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