/* Wyplatanki Reviews — public reviews list ([wr_reviews] shortcode) */

/* ── List container ─────────────────────────────────────── */

.wr-reviews-list {
    font-family: inherit;
}

/* ── Review card ─────────────────────────────────────────── */

.wr-review-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 20px 24px;
    margin-bottom: 14px;
}

/* ── Header row (name · stars · date) ───────────────────── */

.wr-review-header {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 12px;
    margin-bottom: 12px;
}

.wr-review-name {
    font-weight: 700;
    font-size: 15px;
    color: #1a1a1a;
}

.wr-review-date {
    font-size: 13px;
    color: #9ca3af;
    margin-left: auto;
}

/* ── Verified purchase badge ──────────────────────────────── */

.wr-verified-badge {
    position: relative;
    display: inline-flex;
    align-items: center;
    cursor: default;
    vertical-align: middle;
}

.wr-verified-badge::before {
    content: '';
    display: inline-block;
    width: 15px;
    height: 15px;
    background-color: var(--wr-badge-color, #f59e0b);
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='black' fill-rule='evenodd' d='M8 0a8 8 0 1 0 0 16A8 8 0 0 0 8 0ZM3 7.5L6.5 13L12.5 4.5L11.5 5.5L7 11L5 8.5Z'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath fill='black' fill-rule='evenodd' d='M8 0a8 8 0 1 0 0 16A8 8 0 0 0 8 0ZM3 7.5L6.5 13L12.5 4.5L11.5 5.5L7 11L5 8.5Z'/%3E%3C/svg%3E");
    -webkit-mask-size: contain;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    flex-shrink: 0;
}

.wr-verified-badge::after {
    content: attr(data-tip);
    position: absolute;
    bottom: calc(100% + 6px);
    left: 50%;
    transform: translateX(-50%);
    background: #1a1a1a;
    color: #fff;
    font-size: 11px;
    font-weight: 500;
    padding: 4px 8px;
    border-radius: 4px;
    white-space: nowrap;
    pointer-events: none;
    opacity: 0;
    transition: opacity .15s ease;
    z-index: 10;
}

.wr-verified-badge:hover::after { opacity: 1; }

/* ── Share buttons ───────────────────────────────────────── */

.wr-share-buttons {
    display: flex;
    gap: 8px;
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid #f3f4f6;
}

.wr-share-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-decoration: none;
    transition: opacity .15s;
    line-height: 1;
}

.wr-share-btn:hover { opacity: .82; }

.wr-share-btn--fb {
    background: #1877f2;
    color: #fff;
}

.wr-share-btn--tw {
    background: #000;
    color: #fff;
}

/* ── Recommendation badge ────────────────────────────────── */

.wr-rec-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 20px;
}

.wr-rec-badge--yes {
    color: #16a34a;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
}

.wr-rec-badge--no {
    color: #dc2626;
    background: #fef2f2;
    border: 1px solid #fecaca;
}

/* ── Review title ─────────────────────────────────────────── */

.wr-review-title {
    display: block;
    font-size: 15px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 6px;
}

/* ── Comment text ─────────────────────────────────────────── */

.wr-review-comment {
    margin: 0 0 10px;
    font-size: 15px;
    color: #374151;
    line-height: 1.65;
}

/* ── Product sub-ratings ─────────────────────────────────── */

.wr-review-products {
    list-style: none;
    margin: 10px 0 0;
    padding: 12px 0 0;
    border-top: 1px solid #f3f4f6;
}

.wr-review-products li {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px 8px;
    margin-bottom: 6px;
    font-size: 13px;
}

.wr-review-products li:last-child {
    margin-bottom: 0;
}

.wr-review-product-name {
    font-weight: 600;
    color: #374151;
}

.wr-review-product-comment {
    color: #6b7280;
    font-style: italic;
    flex-basis: 100%;
    padding-left: 2px;
}

/* ── Admin reply block ───────────────────────────────────── */

.wr-review-reply {
    margin-top: 14px;
    padding: 12px 16px;
    background: #fefce8;
    border-left: 3px solid #8B6914;
    border-radius: 0 6px 6px 0;
}

.wr-review-reply-label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .5px;
    color: #8B6914;
    margin-bottom: 6px;
}

.wr-review-reply p {
    margin: 0 0 6px;
    font-size: 14px;
    color: #374151;
    line-height: 1.6;
}

.wr-review-reply-date {
    font-size: 12px;
    color: #9ca3af;
}

/* ── Empty state ─────────────────────────────────────────── */

.wr-reviews-empty {
    color: #9ca3af;
    font-style: italic;
    text-align: center;
    padding: 36px 0;
    font-size: 15px;
}

/* ── Pagination ──────────────────────────────────────────── */

.wr-pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    justify-content: center;
    margin-top: 28px;
}

.wr-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 10px;
    border-radius: 6px;
    font-size: 14px;
    text-decoration: none;
    border: 1px solid #e5e7eb;
    color: #374151;
    transition: border-color .15s, color .15s;
}

.wr-pagination .page-numbers:hover {
    border-color: #8B6914;
    color: #8B6914;
}

.wr-pagination .page-numbers.current {
    background: #8B6914;
    border-color: #8B6914;
    color: #fff;
}

/* ── Photo gallery ───────────────────────────────────────── */

.wr-review-photos {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}

.wr-photo-link { display: block; flex-shrink: 0; }

.wr-photo-grid-thumb {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 4px;
    border: 1px solid #e5e7eb;
    cursor: pointer;
    transition: opacity .15s, transform .15s;
}

.wr-photo-grid-thumb:hover {
    opacity: .85;
    transform: scale(1.04);
}

/* ── CSS :target lightbox ────────────────────────────────── */

.wr-lightbox {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 9999;
    align-items: center;
    justify-content: center;
}

.wr-lightbox:target {
    display: flex;
}

.wr-lightbox-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.75);
}

.wr-lightbox-inner {
    position: relative;
    z-index: 1;
    max-width: min(90vw, 900px);
    max-height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wr-lightbox-img {
    display: block;
    max-width: 100%;
    max-height: 90vh;
    border-radius: 4px;
    object-fit: contain;
}

.wr-lightbox-close {
    position: absolute;
    top: -36px;
    right: 0;
    color: #fff;
    font-size: 28px;
    line-height: 1;
    text-decoration: none;
    opacity: .8;
}

.wr-lightbox-close:hover { opacity: 1; }

/* ── Video gallery ───────────────────────────────────────── */

.wr-review-videos {
    margin-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.wr-review-video {
    display: block;
    max-width: 100%;
    width: 340px;
    border-radius: 6px;
    border: 1px solid #e5e7eb;
    background: #000;
}

/* ── Responsive ──────────────────────────────────────────── */

@media (max-width: 600px) {
    .wr-review-card { padding: 16px; }
    .wr-review-date { margin-left: 0; flex-basis: 100%; }
}


/* ── Review tags ──────────────────────────────────────────── */

.wr-review-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 10px;
    margin-bottom: 2px;
}

.wr-tag {
    display: inline-block;
    padding: 3px 10px;
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    font-size: 12px;
    color: #6b7280;
    background: #f9fafb;
    line-height: 1.5;
}

/* ── Helpfulness voting ──────────────────────────────────── */

.wr-vote-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 12px;
}

.wr-vote-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 12px;
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    background: #f9fafb;
    color: #6b7280;
    font-size: 12px;
    cursor: pointer;
    transition: border-color .15s, background .15s, color .15s;
}

.wr-vote-btn:hover {
    border-color: #8B6914;
    color: #8B6914;
    background: #fefce8;
}

.wr-vote-btn--active {
    border-color: #8B6914;
    background: #fefce8;
    color: #8B6914;
    font-weight: 600;
}

.wr-vote-btn:disabled {
    opacity: .5;
    cursor: default;
}

.wr-vote-icon { font-size: 13px; line-height: 1; }
.wr-vote-count { font-weight: 600; }

/* ===== Criteria sub-ratings ===== */
.wr-criteria-list {
    margin-top: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 4px 20px;
}

.wr-crit-row {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
}

.wr-crit-label {
    color: #6b7280;
}

.wr-crit-stars {
    color: #f59e0b;
    letter-spacing: 1px;
}
