/* ============================================================
   Reviews — frontend CSS (v1.5.45+).
   Compact slider format for placement under product description /
   price area, NOT the previous full-tab layout. All scoped to
   .wlpp-reviews so nothing leaks out.

   Three parts:
     1. Toolbar — subtle "Write a review" trigger button (top-right)
     2. Slider — horizontal scroll-snap row of review cards
     3. Modal — popup for the submission form
   ============================================================ */

.wlpp-reviews {
    font-family: 'Geologica', sans-serif;
    color: #1f1f1f;
    margin: 0;
    padding: 8px 0;
}


/* ============================================================
   TOOLBAR — prev/next arrows (when more than one review) + a
   subtle "Write a review" trigger.
   ============================================================ */
.wlpp-reviews-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}
.wlpp-reviews-toolbar:not(:has(.wlpp-reviews-nav)) {
    justify-content: flex-end;
}

.wlpp-reviews-nav {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.wlpp-reviews-arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid rgba(0, 0, 0, 0.10);
    background: #fff;
    color: #1f1f1f;
    cursor: pointer;
    padding: 0;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.12s ease;
}
.wlpp-reviews-arrow:hover:not(:disabled) {
    background: #f8f5f1;
    color: #851625;
    border-color: rgba(133, 22, 37, 0.3);
    transform: scale(1.04);
}
.wlpp-reviews-arrow:disabled,
.wlpp-reviews-arrow.is-disabled {
    opacity: 0.35;
    cursor: default;
}

.wlpp-reviews-write-trigger {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: transparent;
    border: 1px solid rgba(133, 22, 37, 0.3);
    border-radius: 999px;
    padding: 6px 14px;
    font: 600 12.5px/1 'Geologica', sans-serif;
    color: #851625;
    cursor: pointer;
    letter-spacing: 0.01em;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}
.wlpp-reviews-write-trigger:hover,
.wlpp-reviews-write-trigger:focus-visible {
    background: rgba(133, 22, 37, 0.08);
    border-color: #851625;
    color: #6e1220;
    outline: 0;
}


/* ============================================================
   DISPLAY STARS — SVG-based for review cards (Unicode &#9733;
   wasn't rendering on this Divi theme, same root cause as the
   modal rating input).
   ============================================================ */
.wlpp-reviews-stars {
    display: inline-flex !important;
    align-items: center !important;
    gap: 2px;
    line-height: 1;
}
.wlpp-reviews-star {
    display: inline-block !important;
    width: 16px !important;
    height: 16px !important;
    flex-shrink: 0;
    vertical-align: middle;
}
.wlpp-reviews-star.is-filled { color: #851625 !important; }
.wlpp-reviews-star.is-empty  { color: #d6d2cd !important; }


/* ============================================================
   SLIDER — horizontal scroll-snap, always.
   ============================================================ */
.wlpp-reviews-list {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding-bottom: 4px;
    margin: 0;
}
.wlpp-reviews-list::-webkit-scrollbar { display: none; }

.wlpp-review {
    flex: 0 0 100%;        /* 1-up on desktop now (v1.5.48) */
    max-width: 100%;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 14px;
    padding: 18px 22px;
    scroll-snap-align: start;
    transition: box-shadow 0.2s ease;
    box-sizing: border-box;
}
.wlpp-review:hover {
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.05);
}

/* Head: author on the LEFT, stars on the RIGHT. */
.wlpp-review-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
}
.wlpp-review-author {
    font-family: 'Geologica', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: #1f1f1f;
    line-height: 1.3;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.wlpp-review-title {
    font-family: 'Geologica', sans-serif;
    font-size: 14px;
    font-weight: 700;
    color: #1f1f1f;
    line-height: 1.35;
    margin: 0 0 6px 0;
}

.wlpp-review-body {
    font-size: 14px;
    line-height: 1.55;
    color: #555;
    margin: 0;
}
.wlpp-review-body p { margin: 0 0 0.5em; }
.wlpp-review-body p:last-child { margin-bottom: 0; }

/* Short / full toggle — server-side char truncation at 100 chars,
   JS swaps which span is visible when Read more is clicked. */
.wlpp-review-body-short,
.wlpp-review-body-full {
    display: block;
}
.wlpp-review-body-short[hidden],
.wlpp-review-body-full[hidden] {
    display: none;
}

.wlpp-review-readmore {
    background: none;
    border: 0;
    padding: 4px 0 0;
    margin: 0;
    cursor: pointer;
    color: #851625;
    font: 600 12.5px/1.4 'Geologica', sans-serif;
    letter-spacing: 0.01em;
}
.wlpp-review-readmore:hover { text-decoration: underline; }


/* Empty state — sits inline inside the toolbar (where the nav
   arrows would render) so it doesn't take up its own row.
   Italic + 12.5px on both breakpoints per design ask. */
.wlpp-reviews-empty {
    font-size: 12.5px !important;
    color: #6b6359 !important;
    padding: 0 !important;
    margin: 0 !important;
    font-style: italic !important;
    line-height: 1.4 !important;
}
.wlpp-reviews-empty em {
    font-style: italic;
}


/* ============================================================
   MOBILE — full-width card, native swipe. Hide arrows on
   mobile (swipe gesture replaces them).
   ============================================================ */
@media (max-width: 768px) {
    .wlpp-review {
        flex: 0 0 100%;
        max-width: 100%;
        padding: 16px;
    }

    /* Mobile edge arrows.
       Anchor to the section so the arrows can float over the
       slider edges as scroll hints. The toolbar nav wrapper
       collapses to 0 because both children are absolute-positioned.
       Desktop keeps the in-toolbar layout (default rules above). */
    .wlpp-reviews { position: relative; }
    .wlpp-reviews-toolbar { justify-content: flex-end; }
    .wlpp-reviews-nav {
        position: static;
        gap: 0;
    }
    .wlpp-reviews-arrow-prev,
    .wlpp-reviews-arrow-next {
        position: absolute;
        top: 50%;
        transform: translateY(-50%);
        z-index: 3;
        width: 30px;
        height: 30px;
        background: rgba(255, 255, 255, 0.78);
        box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
        border-color: rgba(0, 0, 0, 0.04);
        opacity: 0.85;
    }
    /* Pull arrows further out — half the arrow sits outside the
       slider rail so it stops covering the first/last character of
       the review body. Combined with the softer opacity above, the
       arrows now read as scroll hints, not buttons in the text. */
    .wlpp-reviews-arrow-prev { left: -18px; }
    .wlpp-reviews-arrow-next { right: -18px; }
    /* Soft fade-out when the slider is at the edge — keeps the
       affordance visible (so the user knows there's more) without
       implying it's interactable. */
    .wlpp-reviews-arrow:disabled,
    .wlpp-reviews-arrow.is-disabled {
        opacity: 0.45;
    }
}


/* ============================================================
   MODAL POPUP — submission form.
   ============================================================ */
.wlpp-review-modal[hidden] { display: none !important; }

.wlpp-review-modal {
    position: fixed;
    inset: 0;
    /* Above Divi's fixed top menu (typically 99999) and any sticky
       header stacking contexts. Combined with JS that portals the
       modal to <body> on first open so no ancestor stacking context
       can pin it underneath. */
    z-index: 2147483647;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    animation: wlpp-modal-fade 0.18s ease;
}

.wlpp-review-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(31, 31, 31, 0.55);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
}

.wlpp-review-modal-panel {
    position: relative;
    background: #fff;
    border-radius: 16px;
    max-width: 560px;
    width: 100%;
    /* min-height (v1.5.69) — guarantees the guest-locked-out state
       (just a notice + login CTA, otherwise ~200px tall) still has
       enough room for the points tooltip to fully render below the
       "ⓘ" trigger without being clipped by overflow:auto. */
    min-height: 380px;
    max-height: 90vh;
    overflow-y: auto;
    padding: 32px 32px 36px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.25);
    animation: wlpp-modal-rise 0.22s cubic-bezier(0.18, 0.89, 0.32, 1.28);
}

.wlpp-review-modal-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 0;
    background: rgba(0, 0, 0, 0.04);
    color: #1f1f1f;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.15s ease;
}
.wlpp-review-modal-close:hover { background: rgba(0, 0, 0, 0.10); }

.wlpp-review-modal-title {
    font-family: 'Geologica', sans-serif;
    font-size: 20px;
    font-weight: 700;
    color: #1f1f1f;
    margin: 0 0 12px;
    letter-spacing: -0.01em;
}

/* Points earn line — sits right below the modal title, gives the
   shopper a heads-up of what they'll earn before they start typing.
   Burgundy accent + star icon to read as a reward, not an alert. */
.wlpp-review-modal-points {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: -4px 0 14px;
    padding: 6px 12px;
    background: rgba(133, 22, 37, 0.08);
    color: #851625;
    border-radius: 999px;
    font: 600 12.5px/1.3 'Geologica', sans-serif;
    letter-spacing: 0.01em;
}
.wlpp-review-modal-points svg { color: #851625; }

/* Tooltip trigger — small "ⓘ" next to the badge. Native browser
   `title` covers desktop hover + mobile long-press. The CSS hover
   bubble below is the polished desktop fallback for browsers that
   honour CSS attribute selectors on the data-wlpp-tip attribute. */
.wlpp-review-modal-points-info {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    margin-left: 2px;
    border-radius: 50%;
    color: #851625;
    cursor: help;
    transition: background 0.15s ease;
}
.wlpp-review-modal-points-info:hover,
.wlpp-review-modal-points-info:focus-visible {
    background: rgba(133, 22, 37, 0.15);
    outline: 0;
}
/* Tooltip — sits BELOW the icon and is right-anchored so it always
   grows leftward into the modal, never past the modal's right edge.
   (v1.5.63 anchored it to the icon's centre via translateX(-50%) which
   clipped when the icon was near the modal's right edge — the
   modal-panel's overflow-y: auto implicitly clips overflow-x too.) */
.wlpp-review-modal-points-info::after {
    content: attr(data-wlpp-tip);
    position: absolute;
    top: calc(100% + 10px);
    right: -6px;
    left: auto;
    transform: none;
    min-width: 220px;
    max-width: 280px;
    padding: 10px 14px;
    background: #1f1f1f;
    color: #fff;
    font: 500 11.5px/1.55 'Geologica', sans-serif;
    border-radius: 8px;
    white-space: pre-line;
    text-align: left;
    letter-spacing: 0.01em;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.15s ease;
    z-index: 5;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}
.wlpp-review-modal-points-info::before {
    content: "";
    position: absolute;
    top: calc(100% + 4px);
    right: 2px;
    left: auto;
    transform: none;
    border: 6px solid transparent;
    border-bottom-color: #1f1f1f;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.15s ease;
    z-index: 5;
}
/* Focus path — works on tap (mobile) AND keyboard focus. Hover path
   is gated behind (hover: hover) so it only applies to actual pointer
   devices, sidestepping iOS/Android "sticky hover" where a tapped
   element keeps :hover state until the next tap. */
.wlpp-review-modal-points-info:focus::after,
.wlpp-review-modal-points-info:focus::before {
    opacity: 1;
}
@media (hover: hover) and (pointer: fine) {
    .wlpp-review-modal-points-info:hover::after,
    .wlpp-review-modal-points-info:hover::before {
        opacity: 1;
    }
}

/* Mobile tightening — keep the tooltip in-modal (same anchor as
   desktop) but narrower + snugger against the right edge so it stays
   inside the panel. v1.5.68 tried a bottom-of-viewport toast which
   was clearer but visually disconnected from the trigger; the user
   prefers the in-modal positioning. The modal-panel min-height: 380px
   guarantees there's vertical room for the tooltip below the icon
   even in the short guest-locked-out state. */
@media (max-width: 600px) {
    .wlpp-review-modal-points-info::after {
        right: 0;
        max-width: 230px;
        min-width: 200px;
        font-size: 11px;
        padding: 8px 12px;
    }
    .wlpp-review-modal-points-info::before {
        right: 4px;
    }
}

/* Default state — block-flow so inline <a> + text wrap correctly.
   The verified variant (with the leading icon) needs flex, scoped
   to .is-verified only. v1.5.51 fix: previous global display:flex
   was breaking the guest notice's mixed text + inline anchor by
   making each text node and the <a> its own horizontal flex item. */
.wlpp-review-form-notice {
    font-size: 12.5px !important;
    line-height: 1.5 !important;
    background: #f8f5f1 !important;
    color: #5e574f !important;
    border-radius: 8px !important;
    padding: 8px 12px !important;
    margin: 0 0 14px !important;
    display: block !important;
}
.wlpp-review-form-notice a {
    color: #851625;
    text-decoration: underline;
    font-weight: 500;
}
.wlpp-review-form-notice a:hover {
    color: #6e1220;
}
.wlpp-review-form-notice.is-verified {
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    background: rgba(133, 22, 37, 0.06) !important;
    color: #851625 !important;
    font-weight: 500 !important;
}


/* Login CTA — replaces the form entirely when guest_behavior =
   require_login and the visitor isn't logged in. */
.wlpp-review-form-actions--login {
    margin-top: 8px;
}
.wlpp-review-login-cta {
    display: inline-block;
    text-decoration: none !important;
    text-align: center;
}

.wlpp-review-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.wlpp-review-form-field { display: flex; flex-direction: column; gap: 4px; }
.wlpp-review-form-field > label,
.wlpp-review-form-field > legend {
    font-size: 12.5px;
    font-weight: 600;
    color: #1f1f1f;
    padding: 0;
}
.wlpp-review-form-field input[type="text"],
.wlpp-review-form-field input[type="email"],
.wlpp-review-form-field textarea {
    font: 14px/1.5 'Geologica', sans-serif;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 8px;
    padding: 10px 12px;
    background: #fff;
    color: #1f1f1f;
    width: 100%;
    box-sizing: border-box;
}
.wlpp-review-form-field input:focus,
.wlpp-review-form-field textarea:focus {
    outline: 2px solid rgba(133, 22, 37, 0.3);
    outline-offset: 2px;
    border-color: #851625;
}

/* Live character counter under the body textarea. Two states:
   is-warning (red copy = still short of the minimum) and is-ok
   (green = threshold met). Inline-sized for a quiet, helpful tone. */
.wlpp-review-counter {
    margin: 4px 0 0;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.4;
    color: #6b6359;
}
.wlpp-review-counter.is-warning {
    color: #b3261e;
}
.wlpp-review-counter.is-ok {
    color: #4f7a4a;
}
/* Approaching max — softer amber so the user notices without
   feeling told off. Still allowed to type. */
.wlpp-review-counter.is-ok.is-near-max {
    color: #b97a06;
}

/* Privacy opt-in (hide-my-name checkbox) — smaller, low-key styling
   so it reads as a secondary preference, not a form field. */
.wlpp-review-privacy label {
    font-size: 13px;
    color: #2e2e2e;
}


/* ============================================================
   Photo upload picker (v1.5.56+)
   ============================================================ */
.wlpp-review-photo-field { gap: 6px; }
.wlpp-review-photo-label {
    font-size: 12.5px;
    font-weight: 600;
    color: #1f1f1f;
}
.wlpp-review-photo-picker {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.wlpp-review-photo-trigger {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    align-self: flex-start;
    padding: 9px 14px;
    background: #fff;
    border: 1px dashed #b9aea5;
    border-radius: 10px;
    color: #851625;
    font: 600 13px/1 'Geologica', sans-serif;
    cursor: pointer;
    transition: border-color 0.18s ease, background 0.18s ease;
}
.wlpp-review-photo-trigger:hover {
    border-color: #851625;
    background: #fffbf1;
}
.wlpp-review-photo-trigger:disabled {
    opacity: 0.6;
    cursor: progress;
}
.wlpp-review-photo-preview {
    position: relative;
    align-self: flex-start;
    width: 96px;
    height: 96px;
    border-radius: 10px;
    overflow: hidden;
    background: #f0ede8;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}
.wlpp-review-photo-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.wlpp-review-photo-remove {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.55);
    color: #fff;
    border: 0;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.wlpp-review-photo-remove:hover { background: rgba(0, 0, 0, 0.78); }
.wlpp-review-photo-hint {
    margin: 2px 0 0;
    color: #8a7f78;
    font-size: 11.5px;
}
.wlpp-review-photo-error {
    margin: 2px 0 0;
    color: #b3261e;
    font-size: 12px;
    font-weight: 500;
}


/* ============================================================
   Review card with photo (v1.5.56+)
   Layout: 72×72 square thumb on the left, content stack to the right.
   Falls back to single-column when there's no photo (has-photo class
   absent → .wlpp-review-content takes the whole card width via
   the default block flow).
   ============================================================ */
.wlpp-review.has-photo {
    display: flex;
    align-items: flex-start;
    gap: 14px;
}
.wlpp-review.has-photo .wlpp-review-content {
    flex: 1 1 auto;
    min-width: 0;
}
.wlpp-review-photo {
    flex: 0 0 auto;
    width: 72px;
    height: 72px;
    border-radius: 10px;
    overflow: hidden;
    background: #f0ede8;
    padding: 0;
    border: 0;
    cursor: zoom-in;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.05);
    transition: transform 0.18s ease;
}
.wlpp-review-photo:hover {
    transform: scale(1.03);
}
.wlpp-review-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.wlpp-review-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.wlpp-required { color: #851625; font-weight: 700; }


/* ============================================================
   Star RATING INPUT — CSS-only radio toggle, reversed source
   order. v1.5.47: switched from Unicode &#9733; labels to inline
   SVG icons (the Unicode glyph was getting blanked by Divi's
   form CSS even with !important overrides on color/font-size;
   SVG sidesteps font + content rendering entirely).

   The colour is driven via fill: currentColor on the SVG so the
   :checked ~ label rule still cascades — burgundy on selected
   + hover, gray otherwise.
   ============================================================ */

/* Parent fieldset / wrapper safety — some themes collapse
   fieldsets / blank legend siblings. Re-establish layout. */
.wlpp-review-form-field.is-rating {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    border: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
}
.wlpp-review-form-field.is-rating > legend {
    display: block !important;
    visibility: visible !important;
    width: auto !important;
    float: none !important;
    position: static !important;
    height: auto !important;
    margin: 0 0 4px 0 !important;
    padding: 0 !important;
    font-size: 12.5px !important;
    font-weight: 600 !important;
    color: #1f1f1f !important;
}

.wlpp-review-stars-input {
    display: inline-flex !important;
    flex-direction: row-reverse !important;
    justify-content: flex-end !important;
    align-items: center !important;
    gap: 6px !important;
    line-height: 1 !important;
    margin-top: 6px !important;
    position: relative !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* Screen-reader-only radios — accessible, invisible, no layout. */
.wlpp-review-stars-input input[type="radio"] {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
    opacity: 0 !important;
}

.wlpp-review-stars-input label {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: #d6d2cd !important;
    cursor: pointer !important;
    transition: color 0.12s ease, transform 0.1s ease !important;
    user-select: none;
    line-height: 1 !important;
    padding: 0 !important;
    margin: 0 !important;
    background: none !important;
    border: 0 !important;
    width: 36px !important;
    height: 36px !important;
    min-height: 0 !important;
    min-width: 0 !important;
    font-weight: normal !important;
    visibility: visible !important;
    opacity: 1 !important;
}

.wlpp-review-stars-input label svg {
    display: block !important;
    width: 32px !important;
    height: 32px !important;
    fill: currentColor !important;
    pointer-events: none;
    vertical-align: middle;
}

.wlpp-review-stars-input label:hover { transform: scale(1.08); }

.wlpp-review-stars-input input[type="radio"]:checked ~ label,
.wlpp-review-stars-input label:hover,
.wlpp-review-stars-input label:hover ~ label {
    color: #851625 !important;
}


/* ============================================================
   Form actions — Cancel + Submit row.
   Submit gets brand-burgundy styling inlined directly (the
   .ws-btn-primary class is admin-only — never loads on the
   frontend, which is why the button was unstyled before).
   ============================================================ */
.wlpp-review-form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 8px;
}
.wlpp-review-cancel {
    background: transparent;
    border: 0;
    color: #6b6359;
    cursor: pointer;
    font: 600 13px/1 'Geologica', sans-serif;
    padding: 10px 16px;
    border-radius: 6px;
    transition: color 0.15s ease, background-color 0.15s ease;
}
.wlpp-review-cancel:hover { color: #1f1f1f; background: rgba(0, 0, 0, 0.04); }

.wlpp-review-submit,
.wlpp-review-submit.ws-btn-primary {
    background: #851625 !important;
    color: #fff !important;
    border: 1px solid #851625 !important;
    padding: 10px 24px !important;
    border-radius: 6px !important;
    font-family: 'Geologica', sans-serif !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    line-height: 1 !important;
    letter-spacing: 0.02em !important;
    cursor: pointer !important;
    box-shadow: none !important;
    text-shadow: none !important;
    transition: background 0.15s ease, border-color 0.15s ease, transform 0.1s ease !important;
}
.wlpp-review-submit:hover,
.wlpp-review-submit:focus-visible,
.wlpp-review-submit.ws-btn-primary:hover,
.wlpp-review-submit.ws-btn-primary:focus-visible {
    background: #6e1220 !important;
    border-color: #6e1220 !important;
    color: #fff !important;
    outline: none !important;
}
.wlpp-review-submit:active { transform: translateY(1px); }

body.wlpp-modal-locked {
    overflow: hidden;
}

@keyframes wlpp-modal-fade {
    from { opacity: 0; }
    to   { opacity: 1; }
}
@keyframes wlpp-modal-rise {
    from { opacity: 0; transform: translateY(12px) scale(0.98); }
    to   { opacity: 1; transform: translateY(0)    scale(1); }
}


@media (max-width: 600px) {
    .wlpp-review-modal { padding: 12px; }
    .wlpp-review-modal-panel {
        padding: 24px 18px 18px;
        border-radius: 14px;
        min-height: 340px;
    }
    .wlpp-review-modal-title { font-size: 17px; }
    .wlpp-review-form-row { grid-template-columns: 1fr; }
}


/* ============================================================
   Masonry gallery — `[wlpp_reviews_gallery]` shortcode (v1.5.56+)
   Sits below "How to use" on the PDP. Three columns desktop,
   two columns mobile. Cards size to their content — masonry via
   CSS columns (no JS lib needed).
   ============================================================ */
.wlpp-reviews-gallery {
    margin: 32px 0 24px;
    font-family: 'Geologica', sans-serif;
    color: #1f1f1f;
}
.wlpp-reviews-gallery-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 14px;
    flex-wrap: wrap;
}
.wlpp-reviews-gallery-title {
    font-size: 22px;
    font-weight: 700;
    margin: 0;
    color: #1f1f1f;
}
.wlpp-reviews-gallery-count {
    margin: 0;
    color: #6b6359;
    font-size: 13px;
}

/* Filter bar */
.wlpp-reviews-gallery-filters {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    background: #fffbf1;
    border: 1px solid rgba(133, 22, 37, 0.08);
    border-radius: 12px;
    margin-bottom: 16px;
}
.wlpp-rg-filter-sort {
    display: flex;
    align-items: center;
    gap: 8px;
}
.wlpp-rg-filter-sort label {
    font-size: 12px;
    font-weight: 600;
    color: #6b6359;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.wlpp-rg-filter-sort select {
    font: 500 13px/1.2 'Geologica', sans-serif;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 8px;
    padding: 7px 26px 7px 10px;
    color: #1f1f1f;
    cursor: pointer;
}
.wlpp-rg-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.10);
    border-radius: 999px;
    font: 500 13px/1.2 'Geologica', sans-serif;
    color: #2e2e2e;
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease;
}
.wlpp-rg-chip:hover { border-color: #851625; }
.wlpp-rg-chip input { accent-color: #851625; }
.wlpp-rg-chip input:checked + span { color: #851625; font-weight: 600; }

/* Two-column masonry of cards. Each card is itself a 2-column grid
   (photo left, text right) — v1.5.59 layout matches the compact
   slider card's image-on-left treatment. */
.wlpp-reviews-gallery-grid {
    column-count: 2;
    column-gap: 14px;
}
.wlpp-rg-card {
    break-inside: avoid;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: 12px;
    margin-bottom: 14px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.03);
    padding: 18px 18px;
    width: 100%;
    box-sizing: border-box;
}
/* No-photo cards get extra vertical room so they don't read as
   cramped next to photo cards in the same masonry column. */
.wlpp-rg-card:not(.has-photo) {
    padding: 26px 22px;
}

/* With-photo cards lay photo + text side by side, photo locked to
   160px square on the left. Larger than v1.5.58's 120px so the
   shopper can actually see what the customer photographed. */
.wlpp-rg-card.has-photo {
    display: grid;
    grid-template-columns: 160px 1fr;
    grid-template-areas:
        "photo text";
    gap: 16px;
    align-items: start;
}
.wlpp-rg-card.has-photo .wlpp-rg-photo     { grid-area: photo; }
.wlpp-rg-card.has-photo .wlpp-rg-card-text { grid-area: text; min-width: 0; }

.wlpp-rg-photo {
    width: 160px;
    height: 160px;
    border-radius: 10px;
    overflow: hidden;
    background: #f0ede8;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
    flex-shrink: 0;
}
.wlpp-rg-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.wlpp-rg-card-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 8px;
    margin-bottom: 8px;
}
.wlpp-rg-author {
    font-size: 13.5px;
    font-weight: 600;
    color: #1f1f1f;
    line-height: 1.3;
}
.wlpp-rg-card-head .wlpp-reviews-stars {
    line-height: 0;
    margin-left: auto;
}
.wlpp-rg-verified {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 9.5px;
    font-weight: 600;
    color: #4f7a4a;
    background: #f0f4ec;
    border: 1px solid #cfd9c5;
    border-radius: 999px;
    padding: 1px 6px;
    letter-spacing: 0.02em;
    white-space: nowrap;
    line-height: 1.4;
}

.wlpp-rg-card-body {
    font-size: 13.5px;
    line-height: 1.55;
    color: #2e2e2e;
}
.wlpp-rg-card-body p { margin: 0 0 8px; }
.wlpp-rg-card-body p:last-child { margin-bottom: 0; }

/* Empty state — uplifted in v1.5.58: icon + headline + dimmer hint
   so a filtered-to-zero result no longer reads as an accidentally
   broken page. Spans the full masonry width via column-span. */
.wlpp-rg-empty {
    column-span: all;
    -webkit-column-span: all;
    text-align: center;
    color: #6b6359;
    padding: 32px 20px;
    margin: 8px 0;
    background: #fdfaf4;
    border: 1px dashed rgba(133, 22, 37, 0.18);
    border-radius: 12px;
}
.wlpp-rg-empty svg {
    color: #b9aea5;
    margin: 0 auto 8px;
    display: block;
}
.wlpp-rg-empty-title {
    margin: 0 0 4px;
    font-size: 14.5px;
    font-weight: 600;
    color: #2e2e2e;
}
.wlpp-rg-empty-hint {
    margin: 0;
    font-size: 13px;
    color: #8a7f78;
}

/* Footer row — load-more (when more pages) + write-a-review CTA. */
.wlpp-reviews-gallery-foot {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 16px;
    flex-wrap: wrap;
}
.wlpp-reviews-gallery-more[hidden] { display: none; }
.wlpp-rg-load-more {
    display: inline-flex;
    align-items: center;
    padding: 11px 26px;
    background: #fff;
    color: #851625;
    border: 1.5px solid #851625;
    border-radius: 999px;
    font: 600 13.5px/1 'Geologica', sans-serif;
    letter-spacing: 0.02em;
    cursor: pointer;
    transition: background 0.18s ease, color 0.18s ease;
}
.wlpp-rg-load-more:hover { background: #851625; color: #fff; }
.wlpp-rg-load-more:disabled { opacity: 0.6; cursor: progress; }

/* Primary CTA — opens the shared review modal via the slider's
   data-wlpp-open-modal handler (reviews.js attaches the listener at
   the document level for all matching triggers). */
.wlpp-rg-write {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 22px;
    background: #851625;
    color: #fff;
    border: 1.5px solid #851625;
    border-radius: 999px;
    font: 600 13.5px/1 'Geologica', sans-serif;
    letter-spacing: 0.02em;
    cursor: pointer;
    transition: background 0.18s ease, border-color 0.18s ease;
}
.wlpp-rg-write:hover,
.wlpp-rg-write:focus-visible {
    background: #6e1220;
    border-color: #6e1220;
    color: #fff;
    outline: 0;
}

/* Mobile — one card per row, photo stays on the left but shrinks. */
@media (max-width: 768px) {
    .wlpp-reviews-gallery-grid { column-count: 1; column-gap: 0; }
    .wlpp-rg-card { margin-bottom: 10px; padding: 14px 14px; }
    .wlpp-rg-card:not(.has-photo) { padding: 22px 16px; }
    .wlpp-rg-card.has-photo {
        grid-template-columns: 110px 1fr;
        gap: 12px;
    }
    .wlpp-rg-photo { width: 110px; height: 110px; }
    .wlpp-rg-card-body { font-size: 13px; }
    .wlpp-reviews-gallery-title { font-size: 19px; }
}
@media (max-width: 480px) {
    .wlpp-reviews-gallery-filters { padding: 10px; }
    .wlpp-rg-chip { padding: 5px 10px; font-size: 12.5px; }
}
