/* Main Container */
#skpk-review-system {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    color: #3c4043;
    max-width: 800px;
    margin: 40px auto;
    background: #fff;
    border: 1px solid #dadce0;
    padding: 24px;
    border-radius: 8px;
}

/* Summary Section */
.skpk-summary-container {
    padding-bottom: 20px;
    margin-bottom: 20px;
    border-bottom: 1px solid #e0e0e0;
}
.skpk-summary-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 16px;
}
.skpk-summary-header-left {
    display: flex;
    align-items: center;
    gap: 15px;
}
.skpk-summary-logo {
    width: 100px;
    height: 100px;
    object-fit: contain;
}
.skpk-summary-title {
    font-size: 18px;
    font-weight: 500;
    color: #202124;
    line-height: 1.4;
}
.skpk-summary-header-right #skpk-write-review-btn,
#skpk-load-more-btn {
    background-color: #1a73e8;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
    white-space: nowrap;
}
.skpk-summary-header-right #skpk-write-review-btn:hover,
#skpk-load-more-btn:hover {
    background-color: #185abc;
}
.skpk-summary-body {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}
.skpk-summary-left {
    flex: 1;
    min-width: 180px;
    text-align: left;
}
.skpk-average-rating {
    font-size: 35px;
    font-weight: 400;
    color: #202124;
}

#skpk-review-system .skpk-star-rating .skpk-star,
#skpk-review-system .skpk-star-rating-summary .skpk-star {
    font-size: 20px;
}
#skpk-review-system .skpk-star.filled {
    color: #ffb400 !important;
}
#skpk-review-system .skpk-star.empty {
    color: #d1d1d1 !important;
}

/* *** UPDATED: Total Reviews Count Style *** */
.skpk-total-reviews {
    font-size: 22px; /* Increased size */
    color: #3c4043;
    font-weight: 400; /* Made it bold */
    margin-top: 8px;
}
/* *** END OF UPDATE *** */

.skpk-summary-right {
    flex: 2;
    min-width: 250px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    justify-content: center;
}
.skpk-rating-bar-row {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
}
.skpk-rating-bar-row span:first-child {
    width: 15px;
    text-align: center;
}
.skpk-rating-bar {
    flex-grow: 1;
    height: 8px;
    background-color: #f1f3f4;
    border-radius: 4px;
    overflow: hidden;
}
.skpk-rating-bar-filled {
    height: 100%;
    background-color: #ffb400;
    border-radius: 4px;
}

/* Controls Section */
.skpk-controls {
    margin-bottom: 20px;
}
.skpk-actions {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}
.skpk-sort-label {
    font-weight: 500;
}
#skpk-sort-reviews {
    padding: 8px 12px;
    border-radius: 8px;
    border: 1px solid #ccc;
    background-color: #fff;
}

/* Review Card */
.skpk-review-card {
    padding: 20px 0;
    border-bottom: 1px solid #e0e0e0;
}
.skpk-review-card:last-child {
    border-bottom: none;
}
.skpk-review-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}
.skpk-user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 18px;
    overflow: hidden;
    background-color: #ccc;
}
.skpk-user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.skpk-user-avatar .skpk-initials {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}
.skpk-user-name {
    font-weight: 500;
}
.skpk-review-meta {
    display: flex;
    align-items: center;
    gap: 10px;
}
.skpk-review-meta .skpk-star-rating .skpk-star {
    font-size: 16px;
}
.skpk-review-date {
    font-size: 12px;
    color: #777;
}
.skpk-review-content p, .skpk-reply-content p {
    margin: 0;
    line-height: 1.6;
}
.skpk-review-gallery {
    margin-top: 15px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}
.skpk-review-gallery img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    cursor: pointer;
}
.skpk-review-footer {
    margin-top: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.skpk-like-btn {
    background: none;
    border: 1px solid #ccc;
    border-radius: 15px;
    padding: 5px 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 5px;
    color: #555;
}
.skpk-like-btn:hover {
    background-color: #f0f0f0;
}
.skpk-like-btn.liked {
    background-color: #d1eaff;
    border-color: #1a73e8;
    color: #1967d2;
}
.skpk-like-count {
    font-size: 14px;
    color: #555;
}

/* Admin Reply */
.skpk-admin-reply {
    background-color: #f7f7f7;
    border-radius: 8px;
    padding: 15px;
    margin-top: 15px;
    border-left: 3px solid #1a73e8;
}

/* Read More Styles */
.skpk-expandable-text {
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}
.skpk-expandable-text.expanded {
    -webkit-line-clamp: unset;
    overflow: visible;
}
.skpk-read-more-link {
    color: #1a73e8;
    font-weight: 500;
    cursor: pointer;
    display: block;
    margin-top: 5px;
    text-decoration: none;
}
.skpk-read-more-link:hover {
    text-decoration: underline;
}

/* Modal */
.skpk-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.5);
    animation: fadeIn 0.3s;
}
.skpk-modal-content {
    background-color: #fefefe;
    margin: 10% auto;
    padding: 30px;
    border: 1px solid #888;
    width: 80%;
    max-width: 500px;
    border-radius: 12px;
    position: relative;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    animation: slideIn 0.3s;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideIn { from { transform: translateY(-50px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

.skpk-modal-close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}
#skpk-review-form input[type="text"],
#skpk-review-form textarea {
    width: 100%;
    padding: 10px;
    margin-top: 5px;
    border: 1px solid #ccc;
    border-radius: 8px;
}
#skpk-review-form button {
    background-color: #1a73e8;
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 8px;
    font-weight: bold;
    cursor: pointer;
    width: 100%;
    margin-top: 10px;
}
.skpk-form-stars {
    display: inline-block;
    direction: rtl;
}
.skpk-form-stars input[type="radio"] {
    display: none;
}
.skpk-form-stars label {
    font-size: 30px;
    color: #ddd;
    cursor: pointer;
    padding: 0 2px;
    transition: color 0.2s;
}
.skpk-form-stars input[type="radio"]:checked ~ label,
.skpk-form-stars label:hover,
.skpk-form-stars label:hover ~ label {
    color: #ffb400;
}

/* Loader */
.skpk-loader {
    border: 4px solid #f3f3f3;
    border-radius: 50%;
    border-top: 4px solid #3498db;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Mobile Responsive Styles */
@media (max-width: 600px) {
    .skpk-summary-title {
        display: none; /* Hide the title on mobile */
    }
    .skpk-summary-logo {
        width: 70px; /* Adjust logo size for mobile */
        height: 70px;
    }
    .skpk-summary-body {
        flex-direction: column; /* Stack summary sections on mobile */
    }
    #skpk-review-system {
        padding: 15px; /* Reduce padding on mobile */
    }
}