/* ════════════════════════════════════════════════════════════════════
   LK DRYFRUITS — SINGLE PRODUCT TEMPLATE STYLES v12.0
   ──────────────────────────────────────────────────────────────────
   The front page's design language is brought here too:
       • Fonts: Instrument Sans (single family for display and body)
       • Colors: brand var(--ss-brand), brand-deep var(--ss-brand-deep), brand-soft var(--ss-brand-soft)
                 ink var(--ss-ink), muted-fg var(--ss-muted), accent var(--ss-border)
       • Cards: white surface, 24px radius, a light 1px brand-tinted ring
       • Shadow: soft shadow 0 10px 40px -20px color-mix(in srgb, var(--ss-ink) 25%, transparent)

   Scope: .fm-* classes and overrides inside .single-product #primary.
   Header, footer and mobile bottom-bar are untouched (they belong to the parent theme).

   Upload to: wp-content/themes/your-child-theme/inc/single-product-styles.css
   ════════════════════════════════════════════════════════════════════ */

*, *::before, *::after { box-sizing: border-box; }

/* ─── DESIGN TOKENS (LK Dryfruits design variables) ───────────────────────────────── */
:root {
        /* Brand */
        --fm-primary:        var(--ss-brand);
        --fm-primary-dk:     var(--ss-brand-deep);
        --fm-primary-soft:   var(--ss-brand-soft);
        --fm-primary-10:     color-mix(in srgb, var(--ss-ink) 8%, transparent);
        --fm-primary-30:     color-mix(in srgb, var(--ss-ink) 25%, transparent);

        /* Surfaces */
        --fm-card:           var(--ss-white);
        --fm-cream:          var(--ss-cream);
        --fm-muted:          var(--ss-cream);
        --fm-muted-fg:       var(--ss-muted);
        --fm-border:         var(--ss-cream);
        --fm-border-soft:    color-mix(in srgb, var(--ss-ink) 8%, transparent);
        --fm-fg:             var(--ss-ink);
        --fm-ink-70:         color-mix(in srgb, var(--ss-ink) 70%, transparent);
        --fm-ink-80:         color-mix(in srgb, var(--ss-ink) 82%, transparent);

        /* Accents */
        --fm-accent:         var(--ss-border);
        --fm-amber:          var(--ss-brand);
        --fm-yellow:         var(--ss-brand);       /* purane stars ke liye alias */
        --fm-rust:           var(--ss-badge-sale, var(--ss-brand));
        --fm-info:           var(--ss-brand);
        --fm-info-10:        color-mix(in srgb, var(--ss-brand) 10%, transparent);

        /* Geometry */
        --fm-radius-sm:      .75rem;
        --fm-radius:         1.25rem;       /* 20px — soft cards */
        --fm-radius-lg:      1.5rem;        /* 24px — main panel */
        --fm-radius-xl:      2rem;          /* 32px — hero / gallery */

        --fm-shadow-sm:      0 2px 14px color-mix(in srgb, var(--ss-ink) 6%, transparent);
        --fm-shadow:         0 10px 40px -20px color-mix(in srgb, var(--ss-ink) 25%, transparent);
        --fm-shadow-lg:      0 24px 60px color-mix(in srgb, var(--ss-ink) 14%, transparent);

        /* Typography */
        --fm-font-display:   var(--ss-font-display);
        --fm-font-sans:      var(--ss-font-sans);
        --fm-font-script:    var(--ss-font-sans);
}

/* ─── STOREFRONT LAYOUT RESET (content only, footer stays as-is) ─── */
html:has(body.single-product) { overflow-x: clip !important; }
body.single-product            { overflow-x: clip !important; width: 100% !important; }

body.single-product #page,
body.single-product .site,
body.single-product .site-inner,
body.single-product .col-full,
body.single-product .site-content,
body.single-product .hentry,
body.single-product article {
        width: 100% !important;
        max-width: 100% !important;
        overflow-x: clip !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        box-sizing: border-box !important;
}

body.single-product #secondary           { display: none !important; }
body.single-product #primary,
body.single-product #content,
body.single-product #main,
body.single-product .site-main,
body.single-product .content-area {
        width: 100% !important;
        max-width: 100% !important;
        float: none !important;
        padding: 0 !important;
        margin: 0 !important;
        overflow-x: clip !important;
        box-sizing: border-box !important;
}
body.single-product .entry-header        { display: none !important; }
body.single-product .storefront-breadcrumb,
body.single-product .storefront-sorting  { display: none !important; }

body.single-product .woocommerce-notices-wrapper { max-width: 80rem; margin: 0 auto; padding: 0 1.25rem; }
body.single-product .woocommerce-notices-wrapper:empty { display: none !important; padding: 0 !important; margin: 0 !important; }

/* Body shell — fonts will match front-page-styles if loaded.
   Redeclared here so the template works correctly on its own too. */
body.single-product #primary {
        font-family: var(--fm-font-sans);
        color: var(--fm-fg);
        background: var(--ss-white);
}
body.single-product #primary h1,
body.single-product #primary h2,
body.single-product #primary h3,
body.single-product #primary h4 {
        font-family: var(--fm-font-display);
        letter-spacing: -.02em;
        color: var(--fm-fg);
}

/* Keyboard focus ring (disabled for mouse clicks via JS) */
.single-product #primary *:focus,
.single-product #primary *:focus-visible {
        outline: 2px solid var(--fm-primary-30);
        outline-offset: 2px;
        border-radius: 4px;
}

/* ════════════════════════════════════════════════════════════════════
   BREADCRUMB (path indicator link)
   ════════════════════════════════════════════════════════════════════ */
.fm-breadcrumb {
        max-width: 80rem;
        margin: 0 auto;
        padding: 1.5rem 1.25rem .25rem;
}
.fm-breadcrumb .woocommerce-breadcrumb {
        font-size: 14px;
        font-weight: 500;
        color: var(--fm-muted-fg);
        margin: 0 !important;
        letter-spacing: .01em;
}
.fm-breadcrumb .woocommerce-breadcrumb a {
        color: var(--fm-muted-fg);
        text-decoration: none;
        transition: color .15s ease;
}
.fm-breadcrumb .woocommerce-breadcrumb a:hover { color: var(--fm-primary); }
.fm-breadcrumb .woocommerce-breadcrumb .delimiter,
.fm-breadcrumb .woocommerce-breadcrumb > *:not(:last-child):not(:first-child)::before {
        color: var(--fm-border);
}

/* ════════════════════════════════════════════════════════════════════
   PAGE WRAPPER (Poore page ka dabba)
   ════════════════════════════════════════════════════════════════════ */
.fm-wrap {
        max-width: 80rem;
        margin: 0 auto;
        padding: .5rem 1.25rem 4rem;
        width: 100%;
        box-sizing: border-box;
}

/* ════════════════════════════════════════════════════════════════════
   PRODUCT TOP — Gallery (Tasveeron ka sangrah) aur Jaankari (desktop pe 2-col, mobile pe stack)
   ════════════════════════════════════════════════════════════════════ */
.fm-product-top {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        gap: 2.5rem;
        padding: 0;
        margin: 1.5rem 0 0;
        background: transparent;
        border: none;
        box-shadow: none;
}
@media (max-width: 900px) {
        .fm-product-top {
                grid-template-columns: 1fr;
                gap: 1.5rem;
        }
}
.fm-gallery, .fm-info { min-width: 0; width: 100%; }

/* ─── Gallery (Tasveeron ka sangrah) ──────────────────────────────────────────────────── */
.fm-gallery .woocommerce-product-gallery {
        margin: 0 !important;
        float: none !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
}
.fm-gallery .woocommerce-product-gallery .flex-viewport {
        width: 100% !important;
        max-width: 100% !important;
        overflow: hidden !important;
        border-radius: var(--fm-radius-xl);
}
.fm-gallery .woocommerce-product-gallery__image {
        border-radius: var(--fm-radius-xl);
        overflow: hidden;
        background: var(--fm-primary-soft);
        max-width: 100% !important;
        position: relative;
}
.fm-gallery .woocommerce-product-gallery__image img {
        width: 100% !important;
        max-width: 100% !important;
        aspect-ratio: 1 / 1;
        height: auto !important;
        display: block;
        object-fit: cover;
        transition: transform .5s ease;
        opacity: 1 !important;
        filter: none !important;
        visibility: visible !important;
}
.fm-gallery .woocommerce-product-gallery__image:hover img { transform: scale(1.03); }
.fm-gallery .woocommerce-product-gallery__trigger { display: none !important; }

/* FIX: disable WooCommerce zoom.js overlay — without hovering, a blurry
   image remained instead of the sharp one.
   Hiding the trigger prevents zoom from starting; this CSS blocks
   any theme or plugin that tries to re-enable it. */
.fm-gallery .woocommerce-product-gallery .zoomImg {
        display: none !important;
}
.fm-gallery .woocommerce-product-gallery__image > a {
        display: block;
        cursor: default !important;
        pointer-events: none;
}

/* Thumbnails — 4-col grid, chaukor (square) aur soft */
.fm-gallery .flex-control-nav.flex-control-thumbs {
        display: grid !important;
        grid-template-columns: repeat(4, minmax(0, 72px)) !important;
        gap: .5rem !important;
        list-style: none !important;
        padding: .75rem 0 0 !important;
        margin: 0 !important;
}
.fm-gallery .flex-control-thumbs li {
        margin: 0 !important;
        padding: 0 !important;
        width: 100% !important;
        float: none !important;
}
.fm-gallery .flex-control-thumbs li img {
        width: 100% !important;
        aspect-ratio: 1 / 1 !important;
        height: auto !important;
        object-fit: cover !important;
        border-radius: 10px !important;
        border: 2px solid transparent !important;
        background: var(--fm-primary-soft);
        display: block !important;
        opacity: .85;
        cursor: pointer;
        transition: all .2s ease;
}
.fm-gallery .flex-control-thumbs li img:hover { opacity: 1; }
.fm-gallery .flex-control-thumbs li img.flex-active {
        border-color: var(--fm-primary) !important;
        opacity: 1;
        box-shadow: 0 0 0 3px color-mix(in srgb, var(--ss-ink) 12%, transparent);
}

/* ─── Info panel ───────────────────────────────────────────────── */
.fm-cat-badge {
        display: inline-block;
        background: var(--fm-primary-soft);
        color: var(--fm-primary-dk);
        font-family: var(--fm-font-sans);
        font-size: 12px;
        font-weight: 500;
        letter-spacing: 0;
        text-transform: none;
        padding: 5px 12px;
        border-radius: 9999px;
        margin-bottom: .875rem;
}
.fm-cat-badge + .fm-cat-badge { margin-left: .375rem; }

.fm-info .product_title,
.fm-product-title {
        font-family: var(--fm-font-display) !important;
        font-size: clamp(1.875rem, 4.5vw, 2.75rem) !important;
        font-weight: 500 !important;
        color: var(--fm-fg) !important;
        line-height: 1.05 !important;
        letter-spacing: -.02em !important;
        margin: 0 0 .75rem !important;
        word-break: break-word;
}

.fm-info .woocommerce-product-rating {
        display: flex !important;
        align-items: center !important;
        gap: .625rem !important;
        margin: 0 0 1rem !important;
        flex-wrap: wrap;
}
.fm-info .star-rating { font-size: 15px !important; }
.fm-info .star-rating::before,
.fm-info .star-rating span::before { color: var(--fm-amber) !important; }
.fm-info .woocommerce-review-link {
        font-size: 14px;
        color: var(--fm-muted-fg);
        text-decoration: none;
        transition: color .15s ease;
}
.fm-info .woocommerce-review-link:hover { color: var(--fm-primary); }

.fm-divider {
        height: 1px;
        background: var(--fm-border);
        margin: 1.25rem 0;
}

/* ─── Price (Keemat) ─────────────────────────────────────────────────────── */
.fm-info .price {
        display: flex !important;
        align-items: baseline !important;
        gap: .625rem !important;
        margin: 0 0 .5rem !important;
        flex-wrap: wrap;
}
.fm-info .price ins,
.fm-info .price .woocommerce-Price-amount {
        font-family: var(--fm-font-display) !important;
        font-size: clamp(1.875rem, 4vw, 2.25rem) !important;
        font-weight: 500 !important;
        color: var(--fm-fg) !important;
        text-decoration: none !important;
        letter-spacing: -.01em !important;
}
.fm-info .price del { opacity: 1 !important; font-size: 1.0625rem !important; }
.fm-info .price del .woocommerce-Price-amount {
        color: var(--fm-muted-fg) !important;
        font-size: 1.0625rem !important;
        font-weight: 500 !important;
}
.fm-sale-badge {
        display: inline-block;
        background: var(--ss-brand);
        color: var(--ss-white);
        font-family: var(--fm-font-sans);
        font-size: 14px;
        font-weight: 500;
        letter-spacing: .02em;
        padding: 5px 12px;
        border-radius: 9999px;
        margin-left: .5rem;
        vertical-align: middle;
        white-space: nowrap;
}
.fm-info .woocommerce-variation-price { margin: .25rem 0 .5rem !important; }
.fm-info .woocommerce-variation-price .price { margin-bottom: 0 !important; }

/* ─── Variation chips (size chunne ke liye) ──────────────────────────── */
.fm-info .variations { width: 100%; border: none !important; margin: 1.25rem 0 0 !important; }
.fm-info .variations tr { display: block !important; margin-bottom: 1rem !important; }
.fm-info .variations .label { display: block !important; }
.fm-info .variations .label label {
        font-family: var(--fm-font-sans);
        font-size: 14px;
        font-weight: 500;
        color: var(--fm-fg);
        margin-bottom: .5rem;
        display: block;
        letter-spacing: .01em;
}
.fm-info .variations .value { display: block !important; }
.fm-info .variations select { display: none !important; }

.fm-info .variable-items-wrapper,
.fm-info .tawcvs-swatches {
        display: flex !important;
        gap: .5rem !important;
        flex-wrap: wrap !important;
        margin: 0 !important;
        padding: 0 !important;
}
.fm-info .variable-item,
.fm-info .tawcvs-swatches .swatch {
        border: 2px solid var(--fm-border) !important;
        border-radius: 9999px !important;
        padding: 9px 18px !important;
        font-family: var(--fm-font-sans) !important;
        font-size: 14px !important;
        font-weight: 500 !important;
        color: var(--fm-fg) !important;
        background: var(--ss-white) !important;
        cursor: pointer !important;
        transition: all .2s ease !important;
        min-width: unset !important;
        height: auto !important;
        line-height: 1.3 !important;
        box-shadow: none !important;
        outline: none !important;
}
.fm-info .variable-item:hover,
.fm-info .tawcvs-swatches .swatch:hover {
        border-color: var(--fm-fg) !important;
}
.fm-info .variable-item.selected,
.fm-info .variable-item.active,
.fm-info .tawcvs-swatches .swatch.selected {
        border-color: var(--fm-fg) !important;
        background: var(--fm-fg) !important;
        color: var(--ss-white) !important;
}
.fm-info .reset_variations {
        display: inline-block !important;
        font-size: 14px !important;
        color: var(--fm-muted-fg) !important;
        margin-top: .5rem !important;
        text-decoration: underline !important;
        text-underline-offset: 3px !important;
}

/* ─── Custom Quantity widget (Maatra chunne ke liye) ───────────────────────────────────── */
.fm-info .woocommerce-variation-add-to-cart .quantity,
.fm-info form.cart .quantity { display: none !important; }

#fm-qty-mount { margin: 1.25rem 0 .25rem; }
#fm-qty-mount:empty { display: none; }

.fm-qty-label {
        font-family: var(--fm-font-sans);
        font-size: 14px;
        font-weight: 500;
        color: var(--fm-fg);
        display: block;
        margin-bottom: .5rem;
        letter-spacing: .01em;
}
.fm-qty-row {
        display: inline-flex;
        align-items: center;
        gap: 4px;
        padding: 4px;
        background: var(--ss-white);
        border: 1px solid var(--fm-border);
        border-radius: 9999px;
}
.fm-qty-btn {
        width: 38px; height: 38px;
        border-radius: 50%;
        border: none;
        background: transparent;
        font-family: var(--fm-font-sans);
        font-size: 1.125rem;
        font-weight: 500;
        display: flex; align-items: center; justify-content: center;
        cursor: pointer;
        color: var(--fm-fg);
        transition: background .15s ease;
        outline: none !important;
        flex-shrink: 0;
        -webkit-tap-highlight-color: transparent;
}
.fm-qty-btn:hover { background: var(--fm-muted); }
.fm-qty-btn:active { background: var(--fm-primary-soft); }
.fm-qty-num {
        width: 2.5rem;
        text-align: center;
        font-family: var(--fm-font-sans);
        font-size: 15px;
        font-weight: 500;
        color: var(--fm-fg);
}

/* ─── Add-to-Cart button — LK Dryfruits pill ───────────────────── */
@keyframes fm-shimmer {
        0%   { left: -100%; opacity: 0; }
        15%  { opacity: 1; }
        100% { left: 160%; opacity: 0; }
}
@keyframes fm-pop {
        0%   { transform: scale(1); }
        35%  { transform: scale(.96); }
        65%  { transform: scale(1.02); }
        100% { transform: scale(1); }
}
.fm-info .single_add_to_cart_button {
        position: relative !important;
        overflow: hidden !important;
        width: 100% !important;
        max-width: 24rem !important;
        padding: .875rem 1.5rem !important;
        background: var(--fm-primary-dk) !important;
        color: var(--ss-white) !important;
        border: none !important;
        border-radius: 9999px !important;
        font-family: var(--fm-font-sans) !important;
        font-size: .9375rem !important;
        font-weight: 500 !important;
        letter-spacing: .01em !important;
        cursor: pointer !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: .5rem !important;
        transition: background .25s ease,
                    box-shadow .25s ease,
                    transform .18s cubic-bezier(.34,1.56,.64,1) !important;
        box-shadow: 0 8px 24px -8px color-mix(in srgb, var(--ss-ink) 28%, transparent) !important;
        outline: none !important;
        margin-top: 1rem !important;
        isolation: isolate;
        -webkit-tap-highlight-color: transparent;
}
.fm-info .single_add_to_cart_button::after {
        content: '' !important;
        position: absolute !important;
        top: 0 !important;
        left: -100% !important;
        width: 60% !important;
        height: 100% !important;
        background: linear-gradient(120deg, transparent 20%, color-mix(in srgb, var(--ss-cream) 28%, transparent) 50%, transparent 80%) !important;
        pointer-events: none !important;
        opacity: 0 !important;
        z-index: 0 !important;
}
.fm-info .single_add_to_cart_button:hover {
        background: var(--fm-fg) !important;
        transform: translateY(-2px) !important;
        box-shadow: 0 14px 36px -10px color-mix(in srgb, var(--ss-ink) 38%, transparent) !important;
}
.fm-info .single_add_to_cart_button:hover::after { animation: fm-shimmer .65s ease !important; }
.fm-info .single_add_to_cart_button:active {
        animation: fm-pop .3s cubic-bezier(.34,1.56,.64,1) !important;
        transform: scale(.98) translateY(0) !important;
}
.fm-info .single_add_to_cart_button.loading,
.fm-info .single_add_to_cart_button.is-loading {
        pointer-events: none !important;
        opacity: .92 !important;
}
.fm-info .single_add_to_cart_button.added,
.fm-info .single_add_to_cart_button.is-added {
        background: var(--fm-primary) !important;
        animation: fm-pop .38s cubic-bezier(.34,1.56,.64,1) !important;
}
.fm-info .single_add_to_cart_button:disabled,
.fm-info .single_add_to_cart_button.disabled {
        opacity: .5 !important;
        cursor: not-allowed !important;
        transform: none !important;
        animation: none !important;
}

/* ─── Stock indicator ──────────────────────────────────────────── */
.fm-info .stock.in-stock {
        display: inline-flex !important;
        align-items: center;
        gap: 7px;
        color: var(--fm-primary) !important;
        font-family: var(--fm-font-sans) !important;
        font-size: 14px !important;
        font-weight: 500 !important;
        margin: 1rem 0 0 !important;
        background: var(--fm-primary-soft);
        padding: 6px 12px;
        border-radius: 9999px;
}
.fm-info .stock.out-of-stock {
        color: var(--fm-rust) !important;
        font-size: 14px !important;
        font-weight: 500 !important;
        margin: 1rem 0 0 !important;
}
.fm-stock-dot {
        width: 7px; height: 7px;
        background: var(--fm-primary);
        border-radius: 50%;
        display: inline-block;
        flex-shrink: 0;
        animation: fm-pulse 2s ease-in-out infinite;
}
@keyframes fm-pulse {
        0%, 100% { opacity: 1; transform: scale(1); }
        50%      { opacity: .55; transform: scale(.8); }
}

.fm-info .product_meta {
        margin-top: 1.25rem;
        font-size: 14px;
        color: var(--fm-muted-fg);
        padding-top: 1rem;
        border-top: 1px dashed var(--fm-border);
}
.fm-info .product_meta > span { display: block; margin-bottom: 3px; }
.fm-info .product_meta a { color: var(--fm-primary); text-decoration: none; }
.fm-info .product_meta a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* ════════════════════════════════════════════════════════════════════
   SECTION CARD  (generic — accordion, reviews, carousel)
   ════════════════════════════════════════════════════════════════════ */
.fm-section {
        margin: 3.5rem 0 0;
        padding: 0;
        background: transparent;
        border: none;
        box-shadow: none;
        width: 100%;
        display: block;
        float: none !important;
        clear: both !important;
}
.fm-section-title {
        font-family: var(--fm-font-display);
        font-size: clamp(1.5rem, 3vw, 2.125rem);
        font-weight: 500;
        color: var(--fm-fg);
        letter-spacing: -.02em;
        margin: 0 0 1.5rem;
        line-height: 1.1;
}

/* ════════════════════════════════════════════════════════════════════
   ACCORDION — Product Details
   ════════════════════════════════════════════════════════════════════ */
.fm-section:has(> .fm-acc-item) {
        background: var(--ss-white);
        border-radius: var(--fm-radius-lg);
        border: 1px solid var(--fm-border);
        padding: .5rem 1.5rem;
        box-shadow: var(--fm-shadow-sm);
}
.fm-acc-item { border-bottom: 1px solid var(--fm-border); }
.fm-acc-item:last-child { border-bottom: none; }

.fm-acc-trigger {
        width: 100%;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 1rem;
        padding: 1.25rem 0;
        font-family: var(--fm-font-display);
        font-size: 1.0625rem;
        font-weight: 500;
        color: var(--fm-fg);
        letter-spacing: -.01em;
        text-align: left;
        background: none;
        border: none;
        cursor: pointer;
        transition: color .2s;
        outline: none !important;
        box-shadow: none !important;
        -webkit-tap-highlight-color: transparent;
}
.fm-acc-trigger:hover { color: var(--fm-primary); }
.fm-acc-chevron {
        width: 18px; height: 18px;
        flex-shrink: 0;
        fill: none;
        stroke: var(--fm-muted-fg);
        stroke-width: 2.2;
        stroke-linecap: round;
        stroke-linejoin: round;
        transition: transform .3s ease, stroke .2s;
}
.fm-acc-item.open .fm-acc-chevron {
        transform: rotate(180deg);
        stroke: var(--fm-primary);
}
.fm-acc-body {
        overflow: hidden;
        max-height: 0;
        transition: max-height .4s ease;
}
.fm-acc-inner {
        padding: 0 0 1.25rem;
        font-family: var(--fm-font-sans);
        font-size: .9375rem;
        color: var(--fm-ink-80);
        line-height: 1.7;
}
.fm-acc-inner p { margin: 0 0 .625rem; }
.fm-acc-inner p:last-child { margin-bottom: 0; }
.fm-acc-inner ul { padding-left: 1.25rem; margin: 0 0 .5rem; }
.fm-acc-inner ul li { margin-bottom: .35rem; }
.fm-acc-inner strong { color: var(--fm-fg); font-weight: 500; }
.fm-acc-item.open .fm-acc-body { max-height: 1600px; }

/* Attribute table */
.fm-acc-inner table.shop_attributes {
        width: 100%;
        border-collapse: separate;
        border-spacing: 0;
        border-radius: 12px;
        overflow: hidden;
        font-size: 14px;
        border: 1px solid var(--fm-border);
}
.fm-acc-inner table.shop_attributes th,
.fm-acc-inner table.shop_attributes td {
        padding: 10px 14px;
        border-bottom: 1px solid var(--fm-border);
        text-align: left;
}
.fm-acc-inner table.shop_attributes tr:last-child th,
.fm-acc-inner table.shop_attributes tr:last-child td { border-bottom: none; }
.fm-acc-inner table.shop_attributes th {
        background: var(--fm-muted);
        font-weight: 500;
        color: var(--fm-fg);
        width: 40%;
}

/* Nutrition grid (custom meta) */
.fm-nutrition-grid {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: .625rem;
}
.fm-nutrition-item {
        display: flex;
        justify-content: space-between;
        align-items: center;
        background: var(--fm-primary-soft);
        padding: .625rem .875rem;
        border-radius: 12px;
        font-size: .875rem;
}
.fm-nutrition-item span:first-child { color: var(--fm-muted-fg); }
.fm-nutrition-item span:last-child { font-weight: 500; color: var(--fm-fg); }

/* ════════════════════════════════════════════════════════════════════
   RELATED PRODUCTS CAROUSEL
   ════════════════════════════════════════════════════════════════════ */
.fm-carousel-outer {
        display: flex;
        align-items: center;
        gap: 12px;
}
.fm-carousel-arrow {
        flex-shrink: 0;
        width: 44px; height: 44px;
        border-radius: 50%;
        background: var(--ss-white);
        border: 1px solid var(--fm-border);
        box-shadow: var(--fm-shadow-sm);
        cursor: pointer;
        display: flex; align-items: center; justify-content: center;
        padding: 0;
        transition: all .2s ease;
        outline: none !important;
        -webkit-tap-highlight-color: transparent;
}
.fm-carousel-arrow:hover {
        border-color: var(--fm-fg);
        transform: scale(1.06);
        box-shadow: 0 6px 20px color-mix(in srgb, var(--ss-ink) 18%, transparent);
}
.fm-carousel-arrow svg { width: 14px; height: 14px; display: block; flex-shrink: 0; }
.fm-carousel-arrow svg path { stroke: var(--fm-fg); transition: stroke .2s; }
.fm-carousel-arrow.fm-hidden { opacity: 0; pointer-events: none; }

.fm-carousel-track {
        flex: 1;
        display: flex;
        gap: 1.125rem;
        overflow-x: auto;
        cursor: grab;
        touch-action: pan-y;
        scroll-snap-type: none !important;
        scroll-behavior: auto !important;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        -ms-overflow-style: none;
        min-width: 0;
        padding: 4px;     /* allow hover lift without clipping shadow */
        margin: -4px;
}
.fm-carousel-track.is-dragging {
        cursor: grabbing;
        user-select: none;
        scroll-behavior: auto !important;
        scroll-snap-type: none !important;
}
.fm-carousel-track::-webkit-scrollbar { display: none; }

.fm-carousel-item {
        flex: 0 0 calc(25% - .85rem);
        min-width: 0;
        scroll-snap-align: none;
         /* Keep the carousel wrapper transparent; shared card styles control
            the square image, category pill, name, and price. */
        display: flex;
        flex-direction: column;
}
@media (max-width: 1024px) { .fm-carousel-item { flex-basis: calc(33.333% - 1rem); } }
@media (max-width: 768px)  { .fm-carousel-item { flex-basis: calc(46% - .6rem); } }
@media (max-width: 540px) {
        /* Hide arrows on small screens — touch swipe handles navigation */
        .fm-carousel-arrow { display: none !important; }
        .fm-carousel-outer { gap: 0; }
        .fm-carousel-track {
                padding: 4px 1px !important;
                margin: -4px -1px !important;
                gap: .75rem;
        }
        .fm-carousel-item { flex-basis: calc(48% - .375rem); }
}
@media (max-width: 400px) {
        .fm-carousel-item { flex-basis: calc(72% - .375rem); }
}

/* ── Card inside the related carousel — inherit .ss-fcard look ──
   .ss-fcard's container/typography all come from the shared
   inc/ss-shop-card.css (same file the front page + shop use) so
   "You might also like" matches those cards. We only
   add the flex-fit sizing needed to make the card fill the carousel
   slot — do not redeclare background/border/radius/padding here, that
   would drift out of sync with the shared card again. */
.fm-carousel-item .ss-card-wrap,
.fm-carousel-item .ss-card-wrap--related {
        display: flex;
        flex: 1;
        min-width: 0;
        width: 100%;
}
.fm-carousel-item .ss-fcard {
        flex: 1;
        width: 100%;
}
.fm-carousel-item .ss-fcard:hover {
        transform: none;
}


/* ════════════════════════════════════════════════════════════════════
   REVIEWS
   ════════════════════════════════════════════════════════════════════ */
.fm-review-summary {
        display: grid;
        grid-template-columns: minmax(180px, 240px) 1fr;
        gap: 2rem;
        align-items: center;
        padding: 1.75rem;
        margin: 0 0 1.75rem;
        background: var(--fm-primary-soft);
        border-radius: var(--fm-radius-lg);
        border: 1px solid color-mix(in srgb, var(--ss-ink) 8%, transparent);
}
@media (max-width: 640px) {
        .fm-review-summary {
                grid-template-columns: 1fr;
                gap: 1.25rem;
                padding: 1.25rem;
        }
}
.fm-review-avg {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: .25rem;
}
.fm-review-avg-num {
        font-family: var(--fm-font-display);
        font-size: 3.5rem;
        font-weight: 500;
        color: var(--fm-primary-dk);
        line-height: 1;
        letter-spacing: -.04em;
}
.fm-review-avg-stars { display: flex; gap: 2px; margin: .5rem 0 .25rem; }
.fm-avg-star { width: 18px; height: 18px; fill: var(--fm-amber); }
.fm-avg-star.empty { fill: color-mix(in srgb, var(--ss-ink) 15%, transparent); }
.fm-review-avg-count {
        font-size: .8125rem;
        color: var(--fm-muted-fg);
        font-weight: 500;
}

.fm-review-breakdown {
        display: flex;
        flex-direction: column;
        gap: .5rem;
}
.fm-breakdown-row {
        display: flex;
        align-items: center;
        gap: .625rem;
        font-size: .8125rem;
}
.fm-breakdown-row > span:first-child {
        width: 1rem;
        text-align: right;
        color: var(--fm-fg);
        font-weight: 500;
}
.fm-bd-star { width: 12px; height: 12px; fill: var(--fm-amber); flex-shrink: 0; }
.fm-breakdown-bar-wrap {
        flex: 1;
        height: 8px;
        background: color-mix(in srgb, var(--ss-cream) 70%, transparent);
        border-radius: 9999px;
        overflow: hidden;
}
.fm-breakdown-bar-fill {
        height: 100%;
        background: var(--fm-primary);
        border-radius: 9999px;
        transition: width .4s ease;
}
.fm-breakdown-count {
        width: 2rem;
        font-size: .75rem;
        color: var(--fm-muted-fg);
        text-align: right;
}

.fm-write-review-btn {
        display: inline-flex;
        align-items: center;
        gap: .5rem;
        border: 1px solid var(--fm-border);
        border-radius: 9999px;
        padding: .75rem 1.5rem;
        font-family: var(--fm-font-sans);
        font-size: .875rem;
        font-weight: 500;
        color: var(--fm-fg);
        background: var(--ss-white);
        cursor: pointer;
        transition: all .2s ease;
        margin-bottom: 1.5rem;
        text-decoration: none;
        -webkit-tap-highlight-color: transparent;
}
.fm-write-review-btn:hover {
        border-color: var(--fm-fg);
        background: var(--fm-fg);
        color: var(--ss-white);
        transform: translateY(-1px);
}

/* WooCommerce review output overrides */
.fm-reviews-wrap #reviews {
        padding: 0 !important;
        border: none !important;
        background: transparent !important;
}
.fm-reviews-wrap #reviews .woocommerce-Reviews-title { display: none !important; }

.fm-reviews-wrap .woocommerce-noreviews::before,
.fm-reviews-wrap .woocommerce-info::before {
        display: none !important;
        content: '' !important;
}
.fm-reviews-wrap .woocommerce-noreviews,
.fm-reviews-wrap .woocommerce-info {
        background: var(--fm-primary-soft) !important;
        border: none !important;
        border-left: 3px solid var(--fm-primary) !important;
        color: var(--fm-primary-dk) !important;
        border-radius: 12px !important;
        padding: .875rem 1.125rem !important;
        font-size: .875rem !important;
        font-weight: 500 !important;
        list-style: none !important;
        margin: 0 0 1.5rem !important;
        display: block !important;
}

/* Review list — card-style */
.fm-reviews-wrap #comments ol.commentlist {
        list-style: none !important;
        padding: 0 !important;
        margin: 0 0 2rem !important;
        display: flex !important;
        flex-direction: column;
        gap: 1rem;
}
.fm-reviews-wrap #comments ol.commentlist li {
        list-style: none !important;
        display: block !important;
        margin: 0 !important;
        padding: 0 !important;
}
.fm-reviews-wrap #comments ol.commentlist li .comment_container {
        display: flex !important;
        gap: 1rem !important;
        align-items: flex-start !important;
        background: var(--ss-white);
        border: 1px solid var(--fm-border);
        border-radius: var(--fm-radius);
        padding: 1.25rem;
        transition: border-color .2s ease, box-shadow .2s ease;
}
.fm-reviews-wrap #comments ol.commentlist li .comment_container:hover {
        border-color: color-mix(in srgb, var(--ss-ink) 30%, transparent);
        box-shadow: var(--fm-shadow-sm);
}
.fm-reviews-wrap #comments ol.commentlist li .comment_container img.avatar {
        width: 44px !important;
        height: 44px !important;
        border-radius: 50% !important;
        flex-shrink: 0 !important;
        border: none !important;
        background: var(--fm-primary-soft) !important;
        object-fit: cover !important;
        position: static !important;
        margin: 0 !important;
        padding: 0 !important;
}
.fm-reviews-wrap #comments ol.commentlist li .comment-text {
        flex: 1 1 0 !important;
        min-width: 0 !important;
        max-width: 100% !important;
        border: none !important;
        border-radius: 0 !important;
        padding: 0 !important;
        background: transparent !important;
        margin: 0 !important;
        position: relative !important;
}

/* Star rating — keep WC's overlay technique, just style cleanly */
.fm-reviews-wrap #comments .star-rating,
.fm-reviews-wrap .commentlist .star-rating {
        float: none !important;
        clear: both !important;
        position: relative !important;
        display: block !important;
        overflow: hidden !important;
        margin: 0 0 .5rem !important;
        right: auto !important; top: auto !important;
        font-size: 14px !important;
}
.fm-reviews-wrap #comments .star-rating > span,
.fm-reviews-wrap .commentlist .star-rating > span {
        position: absolute !important;
        top: 0 !important; left: 0 !important;
        float: none !important;
}
.fm-reviews-wrap #comments .star-rating::before,
.fm-reviews-wrap #comments .star-rating span::before { color: var(--fm-amber) !important; }

/* Meta row layout */
.fm-reviews-wrap #comments .comment-text .meta {
        display: flex !important;
        flex-wrap: wrap !important;
        align-items: baseline !important;
        gap: .375rem .625rem !important;
        margin: 0 0 .5rem !important;
        font-size: .8125rem !important;
        color: var(--fm-muted-fg) !important;
        line-height: 1.4 !important;
        word-break: break-word !important;
}
@media (min-width: 561px) {
        .fm-reviews-wrap #comments .comment-text .star-rating {
                display: inline-block !important;
                vertical-align: middle !important;
                margin: 0 .75rem 0 0 !important;
                float: left !important;
                clear: none !important;
        }
        .fm-reviews-wrap #comments .comment-text .meta {
                display: flex !important;
                flex-wrap: nowrap !important;
                align-items: center !important;
                justify-content: flex-end !important;
                gap: .75rem !important;
                width: auto !important;
                overflow: hidden !important;
        }
        .fm-reviews-wrap #comments .comment-text .meta strong,
        .fm-reviews-wrap #comments .comment-text .meta .woocommerce-review__author {
                margin-left: auto !important;
                white-space: nowrap !important;
                flex-shrink: 0 !important;
        }
        .fm-reviews-wrap #comments .comment-text .meta time,
        .fm-reviews-wrap #comments .comment-text .meta .woocommerce-review__published-date {
                white-space: nowrap !important;
                flex-shrink: 0 !important;
        }
}
.fm-reviews-wrap #comments .comment-text .meta strong,
.fm-reviews-wrap #comments .comment-text .meta .woocommerce-review__author {
        font-weight: 500 !important;
        color: var(--fm-fg) !important;
        font-style: normal !important;
        font-family: var(--fm-font-sans) !important;
}
.fm-reviews-wrap #comments .comment-text .meta .woocommerce-review__dash { display: none !important; }
.fm-reviews-wrap #comments .comment-text .meta time,
.fm-reviews-wrap #comments .comment-text .meta .woocommerce-review__published-date {
        font-size: .7rem !important;
        color: var(--fm-muted-fg) !important;
        text-transform: none;
        letter-spacing: 0;
        font-weight: 500;
}

/* Verified Purchase badge (JS-injected) */
.fm-reviews-wrap .woocommerce-review__verified,
.fm-reviews-wrap .verified { display: none !important; }
.fm-verified-badge {
        display: inline-flex !important;
        align-items: center !important;
        gap: 4px !important;
        background: var(--fm-primary-soft) !important;
        color: var(--fm-primary-dk) !important;
        font-family: var(--fm-font-sans) !important;
        font-size: .7rem !important;
        font-weight: 500 !important;
        padding: 3px 10px !important;
        border-radius: 9999px !important;
        border: none !important;
        white-space: nowrap !important;
        line-height: 1.4 !important;
        letter-spacing: .02em !important;
        vertical-align: middle !important;
        margin: 4px 0 6px 0 !important;
        text-transform: none !important;
}
@media (min-width: 561px) {
        .fm-verified-badge {
                float: left !important;
                clear: left !important;
                margin: 2px .75rem 4px 0 !important;
        }
}

.fm-reviews-wrap #comments .comment-text .description {
        font-family: var(--fm-font-sans) !important;
        font-size: .9375rem !important;
        color: var(--fm-ink-80) !important;
        line-height: 1.65 !important;
        word-break: break-word !important;
}
.fm-reviews-wrap #comments .comment-text .description p { margin: 0 0 .5rem !important; }
.fm-reviews-wrap #comments .comment-text .description p:last-child { margin-bottom: 0 !important; }

@media (max-width: 560px) {
        .fm-reviews-wrap #comments ol.commentlist li .comment_container { gap: .75rem !important; padding: 1rem !important; }
        .fm-reviews-wrap #comments ol.commentlist li .comment_container img.avatar { width: 38px !important; height: 38px !important; }
        .fm-reviews-wrap #comments .comment-text .meta {
                flex-direction: column !important;
                align-items: flex-start !important;
                gap: .15rem !important;
        }
}

/* Photo review images */
.fm-reviews-wrap .cr-images-container,
.fm-reviews-wrap .woocommerce-review-images {
        display: flex !important;
        gap: .5rem !important;
        flex-wrap: wrap !important;
        margin-top: .75rem !important;
}
.fm-reviews-wrap .cr-images-container img,
.fm-reviews-wrap .woocommerce-review-images img {
        width: 72px !important;
        height: 72px !important;
        border-radius: 12px !important;
        object-fit: cover !important;
        border: 1px solid var(--fm-border) !important;
        cursor: pointer;
        transition: transform .2s ease;
}
.fm-reviews-wrap .cr-images-container img:hover,
.fm-reviews-wrap .woocommerce-review-images img:hover { transform: scale(1.05); }

/* ─── Review FORM ──────────────────────────────────────────────── */
.fm-reviews-wrap #respond,
.fm-reviews-wrap #review_form_wrapper {
        background: transparent !important;
        border: none !important;
        border-radius: 0 !important;
        box-shadow: none !important;
        padding: 0 !important;
        margin: 0 !important;
}
.fm-reviews-wrap #review_form_wrapper {
        margin-top: 2rem !important;
        padding: 1.75rem !important;
        background: var(--ss-white) !important;
        border: 1px solid var(--fm-border) !important;
        border-radius: var(--fm-radius-lg) !important;
        box-shadow: var(--fm-shadow-sm) !important;
}
.fm-reviews-wrap #review_form_wrapper h3 {
        font-family: var(--fm-font-display) !important;
        font-size: 1.375rem !important;
        font-weight: 500 !important;
        color: var(--fm-fg) !important;
        letter-spacing: -.02em !important;
        margin: 0 0 1.25rem !important;
}
/* Review form — proper 2-col grid so Name/Email sit side-by-side
   and cookies-consent never floats outside the box.
   Strategy: ALL children span both columns by default;
   only Name + Email are carved out as one column each. */
.fm-reviews-wrap #review_form #commentform {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        column-gap: 1rem !important;
}
/* Every direct child spans full width … */
.fm-reviews-wrap #review_form #commentform > * {
        grid-column: 1 / -1 !important;
        float: none !important;
        width: auto !important;
        min-width: 0 !important;
        box-sizing: border-box !important;
}
/* … except Name and Email, which each occupy one column */
.fm-reviews-wrap #review_form #commentform > .comment-form-author,
.fm-reviews-wrap #review_form #commentform > .comment-form-email {
        grid-column: auto !important;
}
/* On mobile stack Name + Email to full width */
@media (max-width: 600px) {
        .fm-reviews-wrap #review_form #commentform > .comment-form-author,
        .fm-reviews-wrap #review_form #commentform > .comment-form-email {
                grid-column: 1 / -1 !important;
        }
}

.fm-reviews-wrap #review_form .comment-form-rating,
.fm-reviews-wrap #review_form .comment-form-comment,
.fm-reviews-wrap #review_form .comment-form-author,
.fm-reviews-wrap #review_form .comment-form-email { margin-bottom: 1rem; }

.fm-reviews-wrap #review_form .comment-form-rating label,
.fm-reviews-wrap #review_form .comment-form-comment label,
.fm-reviews-wrap #review_form .comment-form-author label,
.fm-reviews-wrap #review_form .comment-form-email label {
        font-family: var(--fm-font-sans) !important;
        font-size: .8125rem !important;
        font-weight: 500 !important;
        color: var(--fm-fg) !important;
        display: block !important;
        margin-bottom: .375rem !important;
        letter-spacing: .01em !important;
}

.fm-reviews-wrap #review_form .stars { margin: 0 !important; }
.fm-reviews-wrap #review_form .stars a,
.fm-reviews-wrap #review_form .stars a:link,
.fm-reviews-wrap #review_form .stars a:visited,
.fm-reviews-wrap #review_form .stars a:focus,
.fm-reviews-wrap #review_form .stars a:active {
        font-size: 1.5rem !important;
        color: var(--fm-border) !important;
        text-decoration: none !important;
        transition: color .15s;
        letter-spacing: 3px;
        background: transparent !important;
        box-shadow: none !important;
        outline: none !important;
}
.fm-reviews-wrap #review_form .stars:hover a { color: var(--fm-amber) !important; }
.fm-reviews-wrap #review_form .stars a:hover ~ a { color: var(--fm-border) !important; }
.fm-reviews-wrap #review_form .stars.selected a.active,
.fm-reviews-wrap #review_form .stars.selected a.active ~ a { color: var(--fm-border) !important; }
.fm-reviews-wrap #review_form .stars.selected a:not(.active),
.fm-reviews-wrap #review_form .stars.selected a.active { color: var(--fm-amber) !important; }

.fm-reviews-wrap #review_form input[type="text"],
.fm-reviews-wrap #review_form input[type="email"],
.fm-reviews-wrap #review_form textarea {
        width: 100% !important;
        background: var(--ss-white) !important;
        border: 1.5px solid var(--fm-border) !important;
        border-radius: 12px !important;
        padding: .75rem 1rem !important;
        font-family: var(--fm-font-sans) !important;
        font-size: .9375rem !important;
        color: var(--fm-fg) !important;
        transition: border-color .15s ease, box-shadow .15s ease !important;
        outline: none !important;
        box-shadow: none !important;
}
.fm-reviews-wrap #review_form input[type="text"]:focus,
.fm-reviews-wrap #review_form input[type="email"]:focus,
.fm-reviews-wrap #review_form textarea:focus {
        border-color: var(--fm-primary) !important;
        box-shadow: 0 0 0 4px color-mix(in srgb, var(--ss-ink) 10%, transparent) !important;
}
.fm-reviews-wrap #review_form textarea { min-height: 120px; resize: vertical; }

/* Submit button */
.fm-reviews-wrap #review_form .form-submit input[type="submit"],
.fm-reviews-wrap #review_form input#submit {
        background: var(--fm-primary-dk) !important;
        color: var(--ss-white) !important;
        border: none !important;
        border-radius: 9999px !important;
        padding: .875rem 2rem !important;
        font-family: var(--fm-font-sans) !important;
        font-size: .9375rem !important;
        font-weight: 500 !important;
        letter-spacing: .02em !important;
        cursor: pointer !important;
        transition: all .2s ease !important;
        box-shadow: var(--fm-shadow) !important;
        outline: none !important;
        -webkit-tap-highlight-color: transparent !important;
}
.fm-reviews-wrap #review_form .form-submit input[type="submit"]:hover,
.fm-reviews-wrap #review_form input#submit:hover {
        background: var(--fm-fg) !important;
        transform: translateY(-2px) !important;
        box-shadow: 0 14px 50px -16px color-mix(in srgb, var(--ss-ink) 40%, transparent) !important;
}

/* "Choose Files" file input (review photo upload) */
.fm-reviews-wrap #review_form input[type="file"] { font-family: var(--fm-font-sans) !important; font-size: .8125rem !important; }
.fm-reviews-wrap #review_form input[type="file"]::file-selector-button {
        background: var(--fm-primary-soft) !important;
        color: var(--fm-primary-dk) !important;
        border: none !important;
        border-radius: 9999px !important;
        padding: .5rem 1rem !important;
        font-family: var(--fm-font-sans) !important;
        font-size: .8125rem !important;
        font-weight: 500 !important;
        cursor: pointer !important;
        margin-right: .75rem !important;
        transition: background .15s ease !important;
}
.fm-reviews-wrap #review_form input[type="file"]::file-selector-button:hover {
        background: var(--fm-primary) !important;
        color: var(--ss-white) !important;
}

/* Cookie / comment-cookies-consent + privacy notice */
.fm-reviews-wrap #review_form .comment-form-cookies-consent {
        display: flex !important;
        align-items: flex-start !important;
        gap: .5rem !important;
        font-size: .8125rem !important;
        color: var(--fm-muted-fg) !important;
        margin: 1rem 0 1.25rem !important;
}
.fm-reviews-wrap #review_form .comment-form-cookies-consent input { margin-top: 3px; flex-shrink: 0; accent-color: var(--fm-primary); }
.fm-reviews-wrap #review_form .comment-form-cookies-consent label {
        flex: 1 !important;
        min-width: 0 !important;
        word-break: break-word !important;
        white-space: normal !important;
        line-height: 1.5 !important;
}

.fm-reviews-wrap .comment-notes,
.fm-reviews-wrap .logged-in-as {
        font-size: .8125rem !important;
        color: var(--fm-muted-fg) !important;
        margin: 0 0 1rem !important;
}
.fm-reviews-wrap .logged-in-as a { color: var(--fm-primary) !important; text-decoration: none !important; }
.fm-reviews-wrap .logged-in-as a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* ════════════════════════════════════════════════════════════════════
   MOBILE TUNING
   ════════════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
        .fm-wrap { padding: .5rem 1rem 3rem; }
        .fm-section { margin-top: 2.5rem; }
        .fm-section:has(> .fm-acc-item) { padding: .25rem 1.25rem; }
        .fm-acc-trigger { padding: 1.125rem 0; font-size: 1rem; }
        .fm-info .single_add_to_cart_button { padding: .8125rem 1.25rem !important; font-size: .875rem !important; max-width: 100% !important; }
}
@media (max-width: 480px) {
        .fm-product-title { font-size: 1.75rem !important; }
        .fm-info .price ins,
        .fm-info .price .woocommerce-Price-amount { font-size: 1.625rem !important; }
        .fm-review-avg-num { font-size: 2.75rem; }
}

/* ════════════════════════════════════════════════════════════════════
   v12.1 PATCH — Gallery sizing, variation dropdown fallback,
   related-card fallback, gallery badge polish.
   This block sits at the end of the file so its specificity
   overrides the earlier rules. Nothing removed, only overrides added.
   ════════════════════════════════════════════════════════════════════ */

/* ─── GALLERY: max-width + centered so it doesn't dominate desktop ─── */
.fm-product-top {
        grid-template-columns: minmax(0, 1.05fr) minmax(0, 1.15fr) !important;
        gap: 3rem !important;
        align-items: start !important;
}
@media (max-width: 1024px) {
        .fm-product-top {
                grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
                gap: 2rem !important;
        }
}
@media (max-width: 820px) {
        .fm-product-top {
                grid-template-columns: 1fr !important;
                gap: 1.25rem !important;
        }
}

.fm-gallery {
        max-width: 520px;
        width: 100%;
        margin: 0 auto;
        position: sticky;
        top: 1rem;
        align-self: start;
}
@media (max-width: 820px) {
        .fm-gallery { position: static; max-width: 100%; }
}

/* Main image: soft radius, NO border/padding — image fills the whole tile
   (previously a 1px border + 1.25rem padding + object-fit:contain made
   the image look like it had a frame border around it). */
.fm-gallery .woocommerce-product-gallery .flex-viewport,
.fm-gallery .woocommerce-product-gallery__image {
        border-radius: 1.25rem !important;
        border: 0 !important;
        background: var(--fm-primary-soft) !important;
        overflow: hidden !important;
}
.fm-gallery .woocommerce-product-gallery__image img {
        aspect-ratio: 1 / 1 !important;
        object-fit: cover !important;
        object-position: center !important;
        padding: 0 !important;
        border: 0 !important;
        border-radius: 1.25rem !important;
        background: transparent !important;
}

/* Thumbnails: consistent size on mobile too, horizontal scroll if many */
.fm-gallery .flex-control-nav.flex-control-thumbs {
        grid-template-columns: repeat(auto-fill, minmax(64px, 72px)) !important;
        gap: .5rem !important;
        justify-content: start !important;
        overflow-x: auto;
        padding: .75rem 2px 4px !important;
        scrollbar-width: thin;
}
@media (max-width: 480px) {
        .fm-gallery .flex-control-nav.flex-control-thumbs {
                grid-template-columns: repeat(auto-fill, minmax(56px, 64px)) !important;
        }
}

/* ─── GALLERY BADGE (NEW only) ────────────────────────────────────── */
.fm-gallery .ss-fcard-badge {
        display: inline-block;
        font-family: var(--fm-font-sans);
        font-size: 12px;
        font-weight: 500;
        letter-spacing: 0;
        text-transform: none;
        padding: 5px 11px;
        border-radius: 9999px;
        background: var(--fm-primary-dk, var(--ss-ink));
        color: var(--ss-white);
        box-shadow: 0 4px 14px -4px color-mix(in srgb, var(--ss-ink) 35%, transparent);
}
.fm-gallery .ss-badge-new { background: var(--fm-primary-dk, var(--ss-ink)); color: var(--ss-white); }

/* ─── VARIATION DROPDOWN FALLBACK ─────────────────────────────────────
 * Original rule `.fm-info .variations select { display: none }` only
 * works correctly with the swatches plugin. Without the plugin, users
 * couldn't select a variation (screenshot showed an empty "weight"
 * label). Now: only hide the select when a swatches wrapper is found;
 * otherwise style the native select to match the brand.
 */
.fm-info .variations select { display: block !important; }
.fm-info .variations td.value:has(.variable-items-wrapper) select,
.fm-info .variations td.value:has(.tawcvs-swatches) select {
        display: none !important;
}
.fm-info .variations select {
        appearance: none;
        -webkit-appearance: none;
        width: 100%;
        max-width: 22rem;
        padding: .7rem 2.25rem .7rem 1rem;
        font-family: var(--fm-font-sans);
        font-size: 14px;
        font-weight: 500;
        color: var(--fm-fg);
        background: var(--ss-white)
                url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'><path fill='none' stroke='%232f5f3f' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' d='M1 1l5 5 5-5'/></svg>")
                no-repeat right 1rem center;
        border: 1.5px solid var(--fm-border);
        border-radius: 9999px;
        cursor: pointer;
        transition: border-color .15s ease, box-shadow .15s ease;
}
.fm-info .variations select:hover,
.fm-info .variations select:focus {
        border-color: var(--fm-primary);
        box-shadow: 0 0 0 3px color-mix(in srgb, var(--ss-ink) 12%, transparent);
        outline: none;
}
/* Ensure the .value cell has some breathing room */
.fm-info .variations td.value { padding-top: .25rem !important; }
.fm-info .variations .label label { text-transform: capitalize; }

/* ─── FALLBACK RELATED-PRODUCT CARD ───────────────────────────────── */
.ss-rel-card {
        display: flex;
        flex-direction: column;
        background: var(--ss-white);
        border: 1px solid var(--fm-border);
        border-radius: 1rem;
        overflow: hidden;
        transition: border-color .2s ease;
        width: 220px;
        min-width: 220px;
        height: 100%;
}
.ss-rel-card:hover {
        transform: none;
        border-color: var(--fm-primary-30);
}
.ss-rel-imgwrap {
        display: block;
        position: relative;
        aspect-ratio: 1 / 1;
        background: var(--fm-muted);
        overflow: hidden;
}
.ss-rel-imgwrap img,
.ss-rel-imgwrap .ss-rel-img {
        width: 100% !important;
        height: 100% !important;
        object-fit: contain;
        padding: .75rem;
        display: block;
        transition: none;
}
.ss-rel-card:hover .ss-rel-imgwrap img { transform: none; }
.ss-rel-sale {
        position: absolute;
        top: 8px; right: 8px;
        background: var(--fm-rust);
        color: var(--ss-white);
        font-size: 12px;
        font-weight: 500;
        letter-spacing: 0;
        padding: 3px 8px;
        border-radius: 9999px;
}
.ss-rel-body {
        display: flex;
        flex-direction: column;
        gap: .375rem;
        padding: .75rem .875rem 1rem;
        flex: 1;
}
.ss-rel-title {
        font-family: var(--fm-font-sans);
        font-size: 14px;
        font-weight: 500;
        color: var(--fm-fg);
        text-decoration: none;
        line-height: 1.3;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
}
.ss-rel-title:hover { color: var(--fm-primary); }
.ss-rel-price {
        font-family: var(--fm-font-display);
        font-size: 15px;
        font-weight: 500;
        color: var(--fm-fg);
}
.ss-rel-price .woocommerce-Price-amount { font-weight: 500; }
.ss-rel-price del { color: var(--fm-muted-fg); font-size: 14px; margin-left: .35rem; font-weight: 500; }
.ss-rel-btn {
        margin-top: auto;
        align-self: flex-start;
        background: var(--fm-primary-dk);
        color: var(--ss-white) !important;
        font-family: var(--fm-font-sans);
        font-size: 14px;
        font-weight: 500;
        letter-spacing: 0;
        padding: 8px 16px;
        border-radius: 9999px;
        text-decoration: none;
        transition: background .15s ease, transform .15s ease;
}
.ss-rel-btn:hover { background: var(--fm-primary); transform: translateY(-1px); }

/* Carousel item spacing for fallback cards */
.fm-carousel-track .fm-carousel-item { min-width: 220px; }
@media (max-width: 480px) {
        .ss-rel-card { width: 180px; min-width: 180px; }
        .fm-carousel-track .fm-carousel-item { min-width: 180px; }
}

/* ─── FRONTEND: hide any leftover PHP notice HTML ──────────────────── */
body.single-product .xdebug-error,
body.single-product .xe-warning,
body.single-product .xdebug-var-dump { display: none !important; }

/* NOTE: old .fm-reviews-wrap #comments rules (built for the default
   WooCommerce/CusRev comment markup) were removed — reviews now render
   via the WiserReview shortcode inside #fm-reviews, which has its own
   styling. Add overrides here targeting WiserReview's own CSS classes
   if you need to tweak its look. */

/* ════════════════════════════════════════════════════════════════════
   V12.2 — CLEAN PREMIUM PRODUCT PAGE
   Square, uncropped gallery; compact info hierarchy; flat description
   accordion; and a quiet, modern purchase control.
   ════════════════════════════════════════════════════════════════════ */
body.single-product #primary .fm-product-top {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
        gap: clamp(1.5rem, 4vw, 3.5rem) !important;
        align-items: start !important;
}

.fm-gallery {
        max-width: 100%;
        position: sticky;
        top: 1rem;
}

.fm-gallery .woocommerce-product-gallery .flex-viewport,
.fm-gallery .woocommerce-product-gallery__image {
        aspect-ratio: 1 / 1;
        border-radius: 4px !important;
        background: var(--ss-cream) !important;
}

.fm-gallery .woocommerce-product-gallery__image img {
        display: block !important;
        width: 100% !important;
        height: auto !important;
        aspect-ratio: 1 / 1 !important;
        object-fit: contain !important;
        object-position: center !important;
        padding: clamp(12px, 3vw, 28px) !important;
        border-radius: 4px !important;
        background: var(--ss-cream) !important;
        transform: none !important;
}

.fm-gallery .flex-control-nav.flex-control-thumbs {
        display: flex !important;
        flex-wrap: nowrap !important;
        justify-content: flex-start !important;
        gap: 9px !important;
        overflow-x: auto !important;
        overflow-y: hidden !important;
        padding: 10px 0 3px !important;
        scrollbar-width: none !important;
        -webkit-overflow-scrolling: touch;
}
.fm-gallery .flex-control-nav.flex-control-thumbs::-webkit-scrollbar { display: none !important; }
.fm-gallery .flex-control-thumbs li {
        flex: 0 0 54px !important;
        width: 54px !important;
}
.fm-gallery .flex-control-thumbs li img {
        display: block !important;
        width: 54px !important;
        height: 54px !important;
        aspect-ratio: 1 / 1 !important;
        object-fit: contain !important;
        padding: 2px !important;
        border: 1px solid var(--ss-cream) !important;
        border-radius: 4px !important;
        background: var(--ss-cream) !important;
        opacity: .8 !important;
        box-shadow: none !important;
}
.fm-gallery .flex-control-thumbs li img.flex-active {
        border: 1.5px solid var(--ss-ink) !important;
        opacity: 1 !important;
        box-shadow: none !important;
}

.fm-info .fm-cat-badge,
.fm-info .product_meta {
        display: none !important;
}
.fm-info .product_title,
.fm-info .fm-product-title {
        max-width: 36rem;
        margin: 0 0 .6rem !important;
        font-size: clamp(1.5rem, 2.4vw, 2rem) !important;
        font-weight: 650 !important;
        line-height: 1.2 !important;
        letter-spacing: -.025em !important;
}
.fm-info .woocommerce-product-rating {
        gap: .5rem !important;
        margin: 0 0 .5rem !important;
}
.fm-info .woocommerce-product-rating .star-rating::before,
.fm-info .woocommerce-product-rating .star-rating span::before {
        color: var(--ss-ink) !important;
}
.fm-info .woocommerce-review-link {
        color: var(--ss-ink) !important;
        font-size: 13px !important;
}
.fm-info .fm-short-description {
        max-width: 38rem;
        margin: .5rem 0 1rem;
        color: var(--ss-ink);
        font-size: 14px;
        line-height: 1.65;
}
.fm-info .fm-short-description p { margin: 0 0 .5rem !important; }
.fm-info .fm-short-description p:last-child { margin-bottom: 0 !important; }
.fm-info .fm-divider {
        height: 1px;
        margin: 1rem 0 !important;
        background: var(--ss-cream);
}

.fm-info .price,
.fm-info .woocommerce-variation-price .price {
        gap: .5rem !important;
        margin: .5rem 0 .25rem !important;
}
.fm-info .price .woocommerce-Price-amount,
.fm-info .price ins,
.fm-info .woocommerce-variation-price .woocommerce-Price-amount,
.fm-info .woocommerce-variation-price ins {
        color: var(--ss-ink) !important;
        font-size: 1.65rem !important;
        font-weight: 650 !important;
        letter-spacing: -.02em !important;
}
.fm-info .price del,
.fm-info .price del .woocommerce-Price-amount {
        color: var(--ss-ink) !important;
        font-size: 1rem !important;
        font-weight: 400 !important;
}
.fm-info .fm-sale-badge {
        margin-left: 0 !important;
        padding: 5px 10px !important;
        border-radius: 999px !important;
        background: var(--ss-cream) !important;
        color: var(--ss-ink) !important;
        font-size: 12px !important;
        font-weight: 600 !important;
}

.fm-info .variations {
        margin: .5rem 0 .75rem !important;
}
.fm-info .variations .label label {
        margin-bottom: .6rem !important;
        color: var(--ss-ink) !important;
        font-size: 13px !important;
        font-weight: 600 !important;
        letter-spacing: .01em !important;
}
.fm-info .variable-items-wrapper,
.fm-info .tawcvs-swatches {
        gap: .625rem !important;
}
.fm-info .variable-item,
.fm-info .tawcvs-swatches .swatch {
        min-height: 46px !important;
        padding: 11px 16px !important;
        border: 1px solid var(--ss-border) !important;
        border-radius: 12px !important;
        background: var(--ss-cream) !important;
        color: var(--ss-ink) !important;
        font-size: 14px !important;
        font-weight: 600 !important;
        box-shadow: 0 1px 2px color-mix(in srgb, var(--ss-ink) 4%, transparent) !important;
}
.fm-info .variable-item:hover,
.fm-info .tawcvs-swatches .swatch:hover {
        border-color: var(--ss-ink) !important;
        background: var(--ss-cream) !important;
}
.fm-info .variable-item.selected,
.fm-info .variable-item.active,
.fm-info .tawcvs-swatches .swatch.selected {
        border-color: var(--ss-ink) !important;
        background: var(--ss-cream) !important;
        color: var(--ss-ink) !important;
        box-shadow: inset 0 0 0 1px var(--ss-ink) !important;
}
.fm-info .variations select {
        max-width: 100% !important;
        min-height: 48px;
        border: 1px solid var(--ss-border) !important;
        border-radius: 12px !important;
        background-color: var(--ss-cream) !important;
        color: var(--ss-ink) !important;
        font-size: 14px !important;
}
.fm-info .reset_variations {
        font-size: 12px !important;
}

#fm-qty-mount {
        margin: .35rem 0 .75rem !important;
}
.fm-qty-label {
        margin-bottom: .45rem !important;
        color: var(--ss-ink) !important;
        font-size: 13px !important;
        font-weight: 600 !important;
}
.fm-qty-row {
        min-height: 46px;
        padding: 3px !important;
        border: 1px solid var(--ss-border) !important;
        border-radius: 12px !important;
        background: var(--ss-cream) !important;
}
.fm-qty-btn {
        width: 38px !important;
        height: 38px !important;
        border-radius: 9px !important;
}
.fm-qty-btn:hover { background: var(--ss-cream) !important; }
.fm-qty-num { font-weight: 600 !important; }
.fm-info .woocommerce-variation-add-to-cart { margin-top: .5rem !important; }
.fm-info .single_add_to_cart_button {
        max-width: 100% !important;
        min-height: 50px;
        margin-top: .5rem !important;
        border-radius: 12px !important;
        background: var(--ss-ink) !important;
        box-shadow: none !important;
        font-size: 15px !important;
        font-weight: 600 !important;
}
.fm-info .single_add_to_cart_button:hover {
        background: var(--ss-ink) !important;
        box-shadow: none !important;
        transform: translateY(-1px) !important;
}
.fm-info .stock.in-stock {
        margin-top: .75rem !important;
        padding: 0 !important;
        background: transparent !important;
        color: var(--ss-ink) !important;
        font-size: 13px !important;
}

#fm-product-details.fm-section {
        margin-top: 2.5rem !important;
        padding: 0 !important;
        border: 0 !important;
        border-top: 1px solid var(--ss-border) !important;
        border-bottom: 1px solid var(--ss-border) !important;
        border-radius: 0 !important;
        background: transparent !important;
        box-shadow: none !important;
}
#fm-product-details .fm-acc-item {
        border-bottom: 1px solid var(--ss-border) !important;
}
#fm-product-details .fm-acc-item:last-child { border-bottom: 0 !important; }
#fm-product-details .fm-acc-trigger {
        min-height: 50px;
        padding: 1rem .25rem !important;
        color: var(--ss-ink) !important;
        font-family: var(--fm-font-sans) !important;
        font-size: 12px !important;
        font-weight: 700 !important;
        letter-spacing: .035em !important;
        text-transform: uppercase;
}
#fm-product-details .fm-acc-trigger:hover { color: var(--ss-ink) !important; }
#fm-product-details .fm-acc-chevron {
        width: 15px !important;
        height: 15px !important;
        stroke: var(--ss-ink) !important;
        stroke-width: 1.7 !important;
        transform: none !important;
}
#fm-product-details .fm-acc-item.open .fm-acc-chevron {
        transform: rotate(45deg) !important;
        stroke: var(--ss-ink) !important;
}
#fm-product-details .fm-acc-inner {
        padding: 0 .25rem 1rem !important;
        color: var(--ss-ink) !important;
        font-size: 14px !important;
        line-height: 1.7 !important;
}

@media (max-width: 820px) {
        body.single-product #primary .fm-product-top {
                grid-template-columns: minmax(0, 1fr) !important;
                gap: 1.25rem !important;
        }
        .fm-gallery { position: static; max-width: 100%; }
        .fm-gallery .flex-control-thumbs li,
        .fm-gallery .flex-control-thumbs li img {
                flex-basis: 50px !important;
                width: 50px !important;
                height: 50px !important;
        }
}

@media (max-width: 480px) {
        .fm-info .product_title,
        .fm-info .fm-product-title { font-size: 1.5rem !important; }
        .fm-info .price .woocommerce-Price-amount,
        .fm-info .price ins,
        .fm-info .woocommerce-variation-price .woocommerce-Price-amount,
        .fm-info .woocommerce-variation-price ins { font-size: 1.5rem !important; }
        #fm-product-details.fm-section { margin-top: 2rem !important; }
}

/* v12.3 — stable sale badge, no reset link, matched clickable rating row */
.fm-info .woocommerce-product-rating .star-rating {
        flex: 0 0 auto;
        width: 5.4em !important;
        height: 1em;
        margin: 0 !important;
        font-size: 17px !important;
        line-height: 1 !important;
        cursor: pointer;
}
.fm-info .woocommerce-product-rating .woocommerce-review-link {
        color: var(--ss-ink) !important;
        font-size: 17px !important;
        font-weight: 400 !important;
        line-height: 1.15 !important;
        text-decoration: none !important;
        cursor: pointer;
}
.fm-info .woocommerce-product-rating .woocommerce-review-link:hover {
        color: var(--ss-ink) !important;
        text-decoration: underline !important;
        text-underline-offset: 3px;
}
.fm-info .woocommerce-product-rating .star-rating:focus-visible {
        outline: 2px solid var(--ss-ink) !important;
        outline-offset: 4px;
        border-radius: 2px;
}
.fm-info .variations a.reset_variations {
        display: none !important;
}
.fm-info #fm-save-badge {
        display: none;
        margin: .25rem 0 .5rem !important;
        vertical-align: middle;
}
#fm-reviews { scroll-margin-top: 96px; }

@media (max-width: 480px) {
        .fm-info .woocommerce-product-rating .star-rating,
        .fm-info .woocommerce-product-rating .woocommerce-review-link {
                font-size: 17px !important;
        }
}

/* v12.4 — tighter page rhythm, reference-style gallery, mobile thumb arrows */
.fm-breadcrumb {
        padding: .6rem 1.25rem .35rem !important;
}
.fm-wrap {
        padding-top: 0 !important;
}
body.single-product #primary .fm-product-top {
        margin-top: 0 !important;
        gap: clamp(1.25rem, 3vw, 2.75rem) !important;
}

.fm-gallery .woocommerce-product-gallery .flex-viewport,
.fm-gallery .woocommerce-product-gallery__image {
        aspect-ratio: 1 / 1 !important;
        overflow: hidden !important;
        border: 0 !important;
        border-radius: 4px !important;
        background: var(--ss-cream) !important;
}
.fm-gallery .woocommerce-product-gallery__image img {
        width: 100% !important;
        height: auto !important;
        aspect-ratio: 1 / 1 !important;
        object-fit: cover !important;
        object-position: center !important;
        padding: 0 !important;
        border-radius: 4px !important;
        background: transparent !important;
}

.fm-gallery-thumb-rail {
        display: flex;
        align-items: center;
        gap: 0;
        width: 100%;
        min-width: 0;
        margin-top: 9px;
}
.fm-gallery-thumb-rail .flex-control-nav.flex-control-thumbs {
        flex: 1 1 auto;
        width: auto !important;
        min-width: 0;
        margin: 0 !important;
        padding: 2px 0 4px !important;
        gap: 8px !important;
        overflow-x: auto !important;
        scroll-behavior: smooth;
        scrollbar-width: none !important;
}
.fm-gallery-thumb-rail .flex-control-nav.flex-control-thumbs::-webkit-scrollbar {
        display: none !important;
}
.fm-gallery-thumb-rail .flex-control-thumbs li,
.fm-gallery-thumb-rail .flex-control-thumbs li img {
        flex: 0 0 58px !important;
        width: 58px !important;
        height: 58px !important;
}
.fm-gallery-thumb-rail .flex-control-thumbs li img {
        object-fit: cover !important;
        padding: 0 !important;
        border: 1px solid var(--ss-cream) !important;
        border-radius: 4px !important;
        background: var(--ss-cream) !important;
}
.fm-gallery-thumb-rail .flex-control-thumbs li img.flex-active {
        border: 2px solid var(--ss-ink) !important;
        box-shadow: none !important;
}
.fm-gallery-thumb-arrow {
        display: none !important;
        flex: 0 0 28px;
        width: 28px;
        height: 44px;
        align-items: center;
        justify-content: center;
        padding: 0 !important;
        border: 0 !important;
        border-radius: 0 !important;
        background: transparent !important;
        color: var(--ss-ink) !important;
        box-shadow: none !important;
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
}
.fm-gallery-thumb-arrow[hidden] { display: none !important; }
.fm-gallery-thumb-arrow:disabled { opacity: .35 !important; cursor: default; }
.fm-gallery-thumb-arrow svg {
        width: 18px;
        height: 18px;
        fill: none;
        stroke: currentColor;
        stroke-width: 1.8;
        stroke-linecap: round;
        stroke-linejoin: round;
}

.fm-info .woocommerce-product-rating {
        max-width: 100%;
        gap: .45rem !important;
        overflow: visible !important;
        flex-wrap: wrap !important;
}
.fm-info .woocommerce-product-rating .star-rating,
.fm-info .woocommerce-product-rating .woocommerce-review-link {
        font-size: 15px !important;
}
.fm-info .woocommerce-product-rating .star-rating {
        width: 5.35em !important;
        flex: 0 0 auto;
}
.fm-info .woocommerce-product-rating .woocommerce-review-link {
        max-width: 100%;
        white-space: normal;
}

/* The site uses green for positive stock signals; keep the pulse, not the berry-red token. */
.fm-info .fm-stock-dot {
        background: var(--ss-ink) !important;
        box-shadow: 0 0 0 3px color-mix(in srgb, var(--ss-ink) 12%, transparent);
}

/* Remove WordPress-rendered smiley image icons from product copy. */
body.single-product .fm-info img.wp-smiley,
body.single-product .fm-acc-inner img.wp-smiley,
body.single-product .fm-info img.emoji,
body.single-product .fm-acc-inner img.emoji {
        display: none !important;
}

@media (max-width: 820px) {
        .fm-breadcrumb {
                padding: .55rem 20px .4rem !important;
        }
        .fm-wrap {
                padding: 0 20px 3rem !important;
        }
        .fm-gallery-thumb-rail {
                gap: 5px;
        }
        .fm-gallery-thumb-arrow {
                display: inline-flex !important;
        }
        .fm-gallery-thumb-rail .flex-control-thumbs li,
        .fm-gallery-thumb-rail .flex-control-thumbs li img {
                flex-basis: 56px !important;
                width: 56px !important;
                height: 56px !important;
        }
}

@media (max-width: 480px) {
        .fm-gallery-thumb-arrow {
                flex-basis: 24px;
                width: 24px;
        }
}

/* v12.5 — tighter mobile top, unclipped rating, selected-variation offer */
@media (max-width: 820px) {
        body.single-product .fm-breadcrumb {
                display: none !important;
        }
        body.single-product .fm-wrap {
                margin-top: 0 !important;
                padding: 0 16px 2.5rem !important;
        }
        body.single-product #content,
        body.single-product .site-content,
        body.single-product #main,
        body.single-product .site-main {
                margin-top: 0 !important;
                padding-top: 0 !important;
        }
        body.single-product #primary .fm-product-top {
                margin-top: 0 !important;
        }
}

.fm-info .woocommerce-product-rating {
        display: flex !important;
        align-items: center !important;
        width: 100%;
        max-width: 100%;
        gap: .4rem !important;
        overflow: visible !important;
        flex-wrap: wrap !important;
}
.fm-info .woocommerce-product-rating .star-rating,
.fm-info .woocommerce-product-rating .woocommerce-review-link {
        font-size: 12px !important;
}
.fm-info .woocommerce-product-rating .star-rating {
        width: 5.4em !important;
        min-width: 5.4em;
        height: 1em;
        flex: 0 0 auto !important;
        line-height: 1 !important;
}
.fm-info .woocommerce-product-rating .woocommerce-review-link {
        flex: 0 1 auto;
        min-width: 0;
        max-width: 100%;
        white-space: normal !important;
        line-height: 1.25 !important;
}

/* Discount sits beside the live variation price, not below it. */
.fm-info form.variations_form .single_variation_wrap {
        display: flex !important;
        align-items: center;
        flex-wrap: wrap;
        column-gap: 10px;
        row-gap: 0;
}
.fm-info form.variations_form .single_variation_wrap > .single_variation {
        flex: 0 1 auto;
        width: auto !important;
        min-width: 0;
        margin: 0 !important;
}
.fm-info form.variations_form .single_variation_wrap > #fm-save-badge {
        flex: 0 0 auto;
        margin: 0 0 .25rem !important;
        align-self: center;
}
.fm-info form.variations_form .single_variation_wrap > .woocommerce-variation-add-to-cart {
        flex: 1 0 100%;
        min-width: 0;
        margin-top: .25rem !important;
}

/* Don't show Woo/plugin's separate percentage sticker over the gallery.
   The selected variation's real discount is shown once, beside its price. */
.fm-gallery .onsale,
.fm-gallery .ss-fcard-badge.ss-badge-sale {
        display: none !important;
}

@media (max-width: 480px) {
        .fm-info .woocommerce-product-rating .star-rating,
        .fm-info .woocommerce-product-rating .woocommerce-review-link {
                font-size: 12px !important;
        }
}

/* v12.6 — keep the full rating row visible; use one price-accurate offer. */
body.single-product .fm-info .woocommerce-product-rating {
        display: flex !important;
        float: none !important;
        clear: both !important;
        align-items: center !important;
        flex-wrap: wrap !important;
        width: max-content !important;
        max-width: 100% !important;
        min-height: 16px;
        height: auto !important;
        overflow: visible !important;
        gap: 5px !important;
}
body.single-product .fm-info .woocommerce-product-rating .star-rating {
        display: block !important;
        float: none !important;
        flex: 0 0 5.4em !important;
        width: 5.4em !important;
        min-width: 5.4em !important;
        height: 1.25em !important;
        margin: 0 !important;
        font-size: 10px !important;
        line-height: 1.25 !important;
}
body.single-product .fm-info .woocommerce-product-rating .woocommerce-review-link {
        display: inline-block !important;
        flex: 0 1 auto !important;
        max-width: 100% !important;
        margin: 0 !important;
        font-size: 11px !important;
        line-height: 1.25 !important;
        white-space: normal !important;
}
body.single-product .fm-product-top .onsale,
body.single-product .fm-product-top .ss-badge-sale,
body.single-product .fm-wrap > .onsale {
        display: none !important;
}

/* v12.7 — replace WooCommerce's clipped star-font row with clean SVG stars. */
body.single-product .fm-info .fm-product-rating {
        display: flex !important;
        align-items: center !important;
        flex-wrap: wrap !important;
        gap: 5px !important;
        width: max-content !important;
        max-width: 100% !important;
        height: auto !important;
        min-height: 0 !important;
        margin: 0 0 .5rem !important;
        overflow: visible !important;
}
body.single-product .fm-info .fm-rating-stars {
        display: inline-flex !important;
        flex: 0 0 auto !important;
        align-items: center !important;
        gap: 1px !important;
        width: auto !important;
        height: auto !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: visible !important;
        line-height: 0 !important;
        text-decoration: none !important;
        -webkit-tap-highlight-color: transparent;
}
body.single-product .fm-info .fm-rating-star {
        display: block !important;
        flex: 0 0 11px !important;
        width: 11px !important;
        height: 11px !important;
        overflow: visible !important;
}
body.single-product .fm-info .fm-rating-stars:focus-visible {
        outline: 2px solid var(--ss-ink) !important;
        outline-offset: 3px;
        border-radius: 2px;
}
body.single-product .fm-info .fm-product-rating .woocommerce-review-link {
        display: inline-block !important;
        flex: 0 1 auto !important;
        min-width: 0 !important;
        max-width: 100% !important;
        margin: 0 !important;
        font-size: 11px !important;
        line-height: 1.25 !important;
        white-space: normal !important;
}

/* v13.0.3 — Lined closed state; soft borderless box when expanded. */
#fm-product-details.fm-section {
        box-sizing: border-box !important;
        width: 100% !important;
        margin: 2.5rem 0 0 !important;
        padding: 0 !important;
        border: 0 !important;
        border-radius: 0 !important;
        background: transparent !important;
        box-shadow: none !important;
        overflow: visible;
}
#fm-product-details .fm-acc-item {
        margin: 0 !important;
        border: 0 !important;
        border-top: 1px solid var(--ss-border) !important;
        border-bottom: 1px solid var(--ss-border) !important;
        border-radius: 0 !important;
        background: transparent !important;
}
#fm-product-details .fm-acc-item.open {
        margin: 8px 0 !important;
        border: 0 !important;
        border-radius: 12px !important;
        background: var(--ss-cream-soft, var(--ss-cream)) !important;
}
#fm-product-details .fm-acc-trigger {
        appearance: none !important;
        -webkit-appearance: none !important;
        box-sizing: border-box !important;
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        width: 100% !important;
        min-height: 56px !important;
        margin: 0 !important;
        padding: 16px 16px !important;
        border: 0 !important;
        border-radius: 0 !important;
        background: var(--ss-cream) !important;
        box-shadow: none !important;
        color: var(--ss-brand-deep) !important;
        font-family: var(--fm-font-sans) !important;
        font-size: 14px !important;
        font-weight: 600 !important;
        letter-spacing: .045em !important;
        line-height: 1.4 !important;
        text-align: left !important;
        text-transform: uppercase !important;
        cursor: pointer;
}
#fm-product-details .fm-acc-trigger:hover {
        color: var(--ss-brand) !important;
        background: var(--ss-cream) !important;
}
#fm-product-details .fm-acc-item.open .fm-acc-trigger {
        background: transparent !important;
}
#fm-product-details .fm-acc-trigger:focus-visible {
        outline: 2px solid var(--ss-brand) !important;
        outline-offset: 2px;
}
#fm-product-details .fm-acc-chevron,
#fm-product-details .fm-acc-item.open .fm-acc-chevron {
        width: 18px !important;
        height: 18px !important;
        transform: none !important;
        stroke: var(--ss-brand) !important;
        stroke-width: 1.8 !important;
        transition: stroke .18s ease;
}
#fm-product-details .fm-acc-body {
        overflow: hidden;
        max-height: 0;
        transition: max-height .35s ease;
}
#fm-product-details .fm-acc-icon-vertical {
        opacity: 1;
        transition: opacity .16s ease;
}
#fm-product-details .fm-acc-item.open .fm-acc-icon-vertical {
        opacity: 0;
}
#fm-product-details .fm-acc-inner {
        padding: 2px 16px 18px !important;
        color: var(--ss-ink-soft) !important;
        font-family: var(--fm-font-sans) !important;
        font-size: 14px !important;
        font-weight: 400 !important;
        line-height: 1.65 !important;
}
#fm-product-details .fm-acc-inner p {
        margin: 0 0 1rem !important;
}
#fm-product-details .fm-acc-inner p:last-child {
        margin-bottom: 0 !important;
}
#fm-product-details .fm-acc-inner ul {
        margin: 0 0 .75rem !important;
        padding-left: 1.25rem !important;
}
#fm-product-details .fm-acc-inner li {
        margin: 0 0 .35rem !important;
}

@media (max-width: 820px) {
        #fm-product-details.fm-section {
                width: auto !important;
                margin: 2rem 12px 0 !important;
                padding: 0 !important;
        }
        #fm-product-details .fm-acc-trigger {
                min-height: 52px !important;
                padding: 12px 14px !important;
                font-size: 13px !important;
        }
        #fm-product-details .fm-acc-inner {
                padding: 2px 14px 16px !important;
                font-size: 14px !important;
                line-height: 1.65 !important;
        }
}
