/**
 * Fiche produit — design dédié.
 * Layout 2 colonnes sticky, pills de variations, qty stepper, animations.
 */

/* ============================================================
 * Cadre général
 * ============================================================ */
.sfc-product-page {
    background: var(--color-cream);
    color: var(--color-text);
    padding-bottom: 80px;
}

.sfc-product-page .sfc-container {
    max-width: var(--container-max);
    margin-inline: auto;
    padding-inline: clamp(16px, 4vw, 48px);
    width: 100%;
}

/* On désactive le wrapper shop générique sur les pages produit */
.single-product .sfc-shop-wrap {
    padding-block: 0;
    background: transparent;
}

/* ============================================================
 * Hero (breadcrumb + catégorie eyebrow)
 * ============================================================ */
.sfc-product-page__hero {
    padding: 32px 0 16px;
    position: relative;
    overflow: hidden;
}

.sfc-product-page__hero::before {
    content: "";
    position: absolute;
    inset: -40% -10% auto auto;
    width: 380px;
    height: 380px;
    background: radial-gradient(circle, rgba(201, 169, 97, 0.12), transparent 65%);
    pointer-events: none;
    z-index: 0;
    animation: sfc-float-soft 14s ease-in-out infinite;
}

.sfc-product-page__hero > * {
    position: relative;
    z-index: 1;
}

.sfc-product-page__hero .sfc-breadcrumb,
.sfc-product-page__hero .woocommerce-breadcrumb {
    margin-bottom: 8px;
    font-family: var(--font-body);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--color-text-muted);
}

.sfc-product-page__hero .storefront-breadcrumb {
    margin: 0;
    padding: 0;
    background: transparent;
    border: 0;
}

.sfc-product-page__hero .storefront-breadcrumb > .col-full {
    margin: 0;
    padding: 0;
    max-width: none;
}

.sfc-product-page__hero .woocommerce-breadcrumb a {
    color: var(--color-text-muted);
    text-decoration: none;
    transition: var(--transition-base);
}

.sfc-product-page__hero .woocommerce-breadcrumb a:hover {
    color: var(--color-primary);
}

.sfc-product-page__hero .breadcrumb-separator {
    color: var(--color-gold);
    margin: 0 8px;
}

.sfc-product-page__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-body);
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--color-gold);
}

.sfc-product-page__eyebrow::before {
    content: "";
    width: 28px;
    height: 1px;
    background: var(--color-gold);
}

/* ============================================================
 * Grille 2 colonnes
 * ============================================================ */
.sfc-product-page__grid {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    gap: clamp(32px, 5vw, 72px);
    padding: 32px 0 64px;
    align-items: start;
}

/* ============================================================
 * Colonne média (galerie)
 * ============================================================ */
.sfc-product-page__media {
    position: sticky;
    top: 110px;
    align-self: start;
}

.woocommerce div.product .woocommerce-product-gallery {
    position: relative;
    margin: 0;
    float: none;
    width: 100% !important;
}

.woocommerce div.product .woocommerce-product-gallery__wrapper {
    border-radius: 12px;
    overflow: hidden;
    background: var(--color-white);
    box-shadow:
        0 1px 2px rgba(26, 38, 64, 0.06),
        0 20px 50px -20px rgba(26, 38, 64, 0.18);
    transition: box-shadow 400ms ease, transform 400ms ease;
}

.woocommerce div.product .woocommerce-product-gallery__wrapper:hover {
    box-shadow:
        0 1px 2px rgba(26, 38, 64, 0.06),
        0 30px 70px -20px rgba(26, 38, 64, 0.28);
}

.woocommerce div.product .woocommerce-product-gallery .woocommerce-product-gallery__image img {
    border-radius: 0;
    background: var(--color-white);
    display: block;
    width: 100%;
    height: auto;
    transition: transform 800ms cubic-bezier(0.22, 1, 0.36, 1);
}

.woocommerce div.product .woocommerce-product-gallery__wrapper:hover .woocommerce-product-gallery__image img {
    transform: scale(1.04);
}

/* Trigger zoom (loupe en haut à droite) */
.woocommerce div.product .woocommerce-product-gallery__trigger {
    top: 16px;
    right: 16px;
    background: var(--color-white);
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(26, 38, 64, 0.18);
    font-size: 0;
    text-indent: 0;
    color: var(--color-primary);
    transition: var(--transition-base);
    z-index: 5;
}

.woocommerce div.product .woocommerce-product-gallery__trigger::before {
    content: "";
    width: 18px;
    height: 18px;
    border: 2px solid currentColor;
    border-radius: 50%;
}

.woocommerce div.product .woocommerce-product-gallery__trigger::after {
    content: "";
    position: absolute;
    width: 8px;
    height: 2px;
    background: currentColor;
    transform: rotate(45deg);
    top: calc(50% + 6px);
    left: calc(50% + 4px);
    border-radius: 2px;
}

.woocommerce div.product .woocommerce-product-gallery__trigger:hover {
    background: var(--color-primary);
    color: var(--color-cream);
    transform: scale(1.06);
}

/* Sale flash repositionné */
.woocommerce span.onsale,
.sfc-badge--selection {
    position: absolute;
    top: 16px;
    left: 16px;
    z-index: 4;
    background: var(--color-accent);
    color: var(--color-white);
    font-family: var(--font-body);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    padding: 8px 16px;
    border-radius: 100px;
    min-height: auto;
    min-width: auto;
    line-height: 1;
    margin: 0;
    box-shadow: 0 6px 18px rgba(201, 116, 86, 0.35);
}

/* Thumbnails sous la galerie */
.woocommerce div.product .woocommerce-product-gallery .flex-control-thumbs {
    display: flex;
    gap: 10px;
    margin-top: 16px;
    padding: 0;
    list-style: none;
}

.woocommerce div.product .woocommerce-product-gallery .flex-control-thumbs li {
    width: calc((100% - 30px) / 4) !important;
    margin: 0 !important;
    float: none !important;
}

.woocommerce div.product .woocommerce-product-gallery .flex-control-thumbs li img {
    border-radius: 8px;
    opacity: 0.55;
    border: 2px solid transparent;
    transition: var(--transition-base);
    cursor: pointer;
}

.woocommerce div.product .woocommerce-product-gallery .flex-control-thumbs li img.flex-active,
.woocommerce div.product .woocommerce-product-gallery .flex-control-thumbs li img:hover {
    opacity: 1;
    border-color: var(--color-gold);
    transform: translateY(-2px);
}

/* ============================================================
 * Colonne résumé
 * ============================================================ */
.sfc-product-page__summary {
    position: sticky;
    top: 110px;
    align-self: start;
}

.woocommerce div.product .summary {
    margin: 0 !important;
    float: none !important;
    width: 100% !important;
    background: var(--color-white);
    border-radius: 12px;
    padding: clamp(24px, 3vw, 40px);
    box-shadow:
        0 1px 2px rgba(26, 38, 64, 0.06),
        0 20px 40px -24px rgba(26, 38, 64, 0.16);
    position: relative;
}

.woocommerce div.product .summary::before {
    content: "";
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 64px;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--color-gold), transparent);
    border-radius: 100px;
}

/* Titre */
.woocommerce div.product .product_title {
    font-family: var(--font-heading);
    font-size: clamp(28px, 3vw, 40px);
    font-weight: 600;
    color: var(--color-primary);
    line-height: 1.15;
    margin: 0 0 12px;
    letter-spacing: -0.01em;
}

/* Prix */
.woocommerce div.product p.price,
.woocommerce div.product span.price,
.woocommerce-variation-price .price {
    font-family: var(--font-heading);
    font-size: clamp(24px, 2.4vw, 32px);
    font-weight: 600;
    color: var(--color-accent);
    margin: 0 0 20px;
    display: block;
    transition: transform 250ms ease, color 250ms ease;
}

.woocommerce div.product p.price ins,
.woocommerce div.product span.price ins {
    background: transparent;
    color: var(--color-accent);
    text-decoration: none;
    font-weight: 600;
}

.woocommerce div.product p.price del,
.woocommerce div.product span.price del {
    opacity: 0.5;
    font-size: 0.7em;
    margin-right: 10px;
    color: var(--color-text-muted);
}

/* Animation prix au changement de variation */
.is-flashing {
    animation: sfc-price-flash 500ms ease;
}

@keyframes sfc-price-flash {
    0%   { transform: scale(1); }
    35%  { transform: scale(1.06); color: var(--color-gold); }
    100% { transform: scale(1); }
}

/* Excerpt */
.woocommerce div.product .woocommerce-product-details__short-description {
    font-family: var(--font-body);
    font-size: 15px;
    line-height: 1.65;
    color: var(--color-text-muted);
    padding-bottom: 20px;
    margin-bottom: 24px;
    border-bottom: 1px solid rgba(26, 38, 64, 0.08);
}

.woocommerce div.product .woocommerce-product-details__short-description p:last-child {
    margin-bottom: 0;
}

/* ============================================================
 * Table de variations → pills (via JS)
 * ============================================================ */
.woocommerce div.product form.variations_form {
    margin: 0 0 8px;
}

.woocommerce div.product form.cart .variations {
    margin: 0 0 20px;
    border: 0;
    table-layout: fixed;
    width: 100%;
}

.woocommerce div.product form.cart .variations tr,
.woocommerce div.product form.cart .variations td {
    display: block;
    border: 0;
    padding: 0;
    background: transparent;
}

.woocommerce div.product form.cart .variations label {
    font-family: var(--font-body);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--color-text-muted);
    padding: 0 0 10px;
    display: block;
}

.woocommerce div.product form.cart .variations .value {
    padding: 0;
}

.woocommerce div.product form.cart .reset_variations {
    display: inline-block;
    font-size: 12px;
    color: var(--color-text-muted);
    margin-top: 10px;
    text-decoration: underline;
    text-decoration-color: rgba(0, 0, 0, 0.2);
    text-underline-offset: 3px;
    transition: var(--transition-base);
}

.woocommerce div.product form.cart .reset_variations:hover {
    color: var(--color-accent);
    text-decoration-color: currentColor;
}

/* Pills */
.sfc-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.sfc-pill {
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    background: var(--color-cream);
    color: var(--color-primary);
    font-family: var(--font-body);
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.02em;
    padding: 10px 18px;
    border: 1.5px solid transparent;
    border-radius: 100px;
    transition:
        transform 220ms cubic-bezier(0.34, 1.56, 0.64, 1),
        background-color 220ms ease,
        color 220ms ease,
        border-color 220ms ease,
        box-shadow 220ms ease;
    position: relative;
    overflow: hidden;
    min-width: 64px;
    text-align: center;
}

.sfc-pill:hover:not(:disabled) {
    background: var(--color-white);
    border-color: var(--color-gold);
    transform: translateY(-2px);
    box-shadow: 0 6px 14px -4px rgba(201, 169, 97, 0.4);
}

.sfc-pill.is-active {
    background: var(--color-primary);
    color: var(--color-cream);
    border-color: var(--color-primary);
    box-shadow:
        0 0 0 4px rgba(26, 38, 64, 0.08),
        0 8px 20px -6px rgba(26, 38, 64, 0.35);
}

.sfc-pill.is-active::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, transparent 30%, rgba(201, 169, 97, 0.25) 50%, transparent 70%);
    animation: sfc-pill-shine 1.4s ease;
    pointer-events: none;
}

@keyframes sfc-pill-shine {
    0%   { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.sfc-pill:disabled,
.sfc-pill[aria-disabled="true"] {
    opacity: 0.4;
    cursor: not-allowed;
    text-decoration: line-through;
}

.sfc-pill:focus-visible {
    outline: 2px solid var(--color-gold);
    outline-offset: 3px;
}

/* WC variation price block (apparait après sélection) */
.woocommerce-variation {
    margin-bottom: 16px;
}

.woocommerce-variation-availability {
    font-family: var(--font-body);
    font-size: 13px;
    color: var(--color-forest);
    margin-top: 8px;
}

.woocommerce-variation-availability .stock.out-of-stock {
    color: var(--color-accent);
}

/* ============================================================
 * Quantity stepper + bouton ATC
 * ============================================================ */
.woocommerce div.product form.cart {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: stretch;
    margin: 4px 0 24px;
}

.woocommerce div.product form.cart .quantity {
    margin: 0;
    display: inline-flex;
    align-items: center;          /* center au lieu de stretch — pas de jeu vertical */
    justify-content: center;
    flex: 0 0 auto;               /* ne se rétracte pas dans un flex parent */
    width: fit-content;
    background: var(--color-cream);
    border: 1px solid color-mix(in srgb, var(--color-primary) 16%, transparent);
    border-radius: 100px;
    overflow: hidden;
    height: 52px;
    position: relative;            /* contexte stacking pour l'input */
}

.woocommerce div.product form.cart .quantity .qty {
    /* Largeur fixe ET min-width pour ne JAMAIS s'écraser sur mobile.
       16px évite le zoom iOS Safari au focus (≥16px requis). */
    width: 56px;
    min-width: 56px;
    flex: 0 0 56px;
    height: 100%;
    background: transparent;
    border: 0;
    text-align: center;
    font-family: var(--font-body);
    font-size: 16px;
    font-weight: 600;
    color: var(--color-primary);
    padding: 0;
    -moz-appearance: textfield;
    appearance: none;
    position: relative;             /* + z-index pour ne jamais passer sous le bouton */
    z-index: 1;
    touch-action: manipulation;     /* évite le double-tap zoom iOS */
}

.woocommerce div.product form.cart .quantity .qty::-webkit-outer-spin-button,
.woocommerce div.product form.cart .quantity .qty::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.sfc-qty-btn {
    appearance: none;
    -webkit-appearance: none;
    border: 0;
    background: transparent;
    cursor: pointer;
    /* 44px = mini target Apple HIG, confortable au pouce. */
    width: 44px;
    min-width: 44px;
    flex: 0 0 44px;
    height: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: 500;
    line-height: 1;
    color: var(--color-primary);
    transition: background 220ms ease, color 220ms ease;
    user-select: none;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

/* Hover réservé aux pointeurs précis (souris) — évite le « sticky :hover »
   iOS Safari qui laisse le bouton en rose plein après tap. */
@media (hover: hover) and (pointer: fine) {
    .sfc-qty-btn:hover {
        background: var(--color-primary);
        color: var(--color-cream);
    }
}

/* Feedback tactile discret sur mobile (pression visible mais légère). */
.sfc-qty-btn:active {
    background: color-mix(in srgb, var(--color-primary) 14%, transparent);
}

.sfc-qty-btn:focus-visible {
    outline: 2px solid var(--color-gold);
    outline-offset: -4px;
}

/* Bouton "Ajouter au panier" */
.woocommerce div.product form.cart .single_add_to_cart_button {
    flex: 1;
    min-width: 220px;
    height: 52px;
    padding: 0 32px !important;
    font-family: var(--font-body) !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    letter-spacing: 0.22em !important;
    text-transform: uppercase !important;
    border-radius: 100px !important;
    background: var(--color-accent) !important;
    color: var(--color-white) !important;
    border: 0 !important;
    transition: transform 250ms ease, box-shadow 250ms ease, background-color 250ms ease !important;
    position: relative;
    overflow: hidden;
    box-shadow: 0 10px 24px -8px rgba(201, 116, 86, 0.55);
}

.woocommerce div.product form.cart .single_add_to_cart_button::before {
    content: "";
    position: absolute;
    top: 0;
    left: -75%;
    width: 50%;
    height: 100%;
    background: linear-gradient(120deg, transparent, rgba(255, 255, 255, 0.35), transparent);
    transform: skewX(-20deg);
    transition: left 600ms ease;
}

.woocommerce div.product form.cart .single_add_to_cart_button:hover {
    background: var(--color-primary) !important;
    transform: translateY(-2px);
    box-shadow: 0 14px 32px -8px rgba(26, 38, 64, 0.45);
}

.woocommerce div.product form.cart .single_add_to_cart_button:hover::before {
    left: 125%;
}

.woocommerce div.product form.cart .single_add_to_cart_button:active {
    transform: translateY(0);
}

.woocommerce div.product form.cart .single_add_to_cart_button.disabled,
.woocommerce div.product form.cart .single_add_to_cart_button[disabled] {
    opacity: 0.5;
    cursor: not-allowed;
    box-shadow: none;
}

/* ============================================================
 * Bandeau réassurance fiche produit (sfc-trust-row)
 * Refonte liquid glass — 4 items en grid 2x2 dans la colonne summary.
 * Distinct du `.sfc-trust` du homepage (qui est la section partenaires).
 * ============================================================ */
.sfc-trust-row {
    list-style: none;
    margin: 28px 0 0;
    padding: 20px;
    background: color-mix(in srgb, var(--color-white) 70%, transparent);
    -webkit-backdrop-filter: blur(16px) saturate(1.15);
            backdrop-filter: blur(16px) saturate(1.15);
    border: 1px solid color-mix(in srgb, var(--color-primary, #d4a8b7) 16%, transparent);
    border-radius: var(--radius-lg, 16px);
    box-shadow:
        0 1px 0 0 color-mix(in srgb, var(--color-white) 90%, transparent) inset,
        0 12px 30px -18px color-mix(in srgb, var(--color-primary-deep, #8a4d62) 18%, transparent);
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px 16px;
}

.sfc-trust-row__item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-family: var(--font-body);
    font-size: 12px;
    line-height: 1.5;
    color: var(--color-ink-soft, var(--color-text-muted));
}

.sfc-trust-row__icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-primary-deep, #8a4d62);
    background:
        radial-gradient(circle at 30% 30%,
            color-mix(in srgb, var(--color-white) 100%, transparent) 0%,
            color-mix(in srgb, var(--color-primary, #d4a8b7) 14%, var(--color-white)) 100%);
    box-shadow:
        inset 0 1px 0 0 color-mix(in srgb, var(--color-white) 100%, transparent),
        0 4px 10px -4px color-mix(in srgb, var(--color-primary, #d4a8b7) 30%, transparent);
    transition: transform 400ms cubic-bezier(0.22, 1, 0.36, 1), color 300ms ease;
}

.sfc-trust-row__item:hover .sfc-trust-row__icon {
    transform: scale(1.08) rotate(-4deg);
    color: var(--color-primary);
}

.sfc-trust-row__icon svg {
    width: 20px;
    height: 20px;
}

.sfc-trust-row__body {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.sfc-trust-row__body strong {
    font-family: var(--font-display, var(--font-heading));
    font-style: italic;
    font-weight: 400;
    font-size: 14px;
    color: var(--color-ink, var(--color-primary));
    letter-spacing: 0;
}

/* Meta (SKU, catégorie, tags) — masqué intégralement, info non pertinente sur fiche MH */
.woocommerce div.product .product_meta,
.woocommerce div.product .summary .product_meta {
    display: none !important;
}

/* ============================================================
 * Bloc « points forts » (sfc-highlights) — refonte liquid glass MH
 * Fond cream avec halos rose/or, 3 cards glass blur en grid.
 * ============================================================ */
.sfc-highlights {
    position: relative;
    isolation: isolate;
    padding: clamp(56px, 8vw, 96px) 0;
    margin: clamp(40px, 6vw, 72px) 0;
    background: linear-gradient(180deg,
        color-mix(in srgb, var(--color-cream) 70%, var(--color-white)) 0%,
        var(--color-cream) 100%);
    overflow: hidden;
}

.sfc-highlights__halo {
    position: absolute;
    z-index: -1;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
    opacity: 0.5;
}

.sfc-highlights__halo--rose {
    top: -120px;
    left: -80px;
    width: 380px;
    height: 380px;
    background: radial-gradient(circle, var(--color-primary) 0%, transparent 70%);
    animation: sfc-float-soft 14s ease-in-out infinite;
}

.sfc-highlights__halo--gold {
    bottom: -100px;
    right: -60px;
    width: 320px;
    height: 320px;
    background: radial-gradient(circle,
        color-mix(in srgb, var(--color-gold, #c9a55c) 70%, transparent) 0%,
        transparent 70%);
    opacity: 0.35;
    animation: sfc-float-soft 18s ease-in-out infinite reverse;
}

.sfc-highlights__inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: clamp(20px, 3vw, 36px);
}

.sfc-highlight {
    position: relative;
    text-align: center;
    padding: clamp(28px, 4vw, 40px) clamp(20px, 3vw, 28px);
    background: color-mix(in srgb, var(--color-white) 78%, transparent);
    -webkit-backdrop-filter: blur(20px) saturate(1.15);
            backdrop-filter: blur(20px) saturate(1.15);
    border: 1px solid color-mix(in srgb, var(--color-primary) 18%, transparent);
    border-radius: var(--radius-xl, 22px);
    box-shadow:
        0 1px 0 0 color-mix(in srgb, var(--color-white) 90%, transparent) inset,
        0 24px 60px -30px color-mix(in srgb, var(--color-primary-deep, #8a4d62) 25%, transparent);
    transition:
        transform 500ms cubic-bezier(0.22, 1, 0.36, 1),
        box-shadow 500ms cubic-bezier(0.22, 1, 0.36, 1),
        border-color 400ms ease-out;
}

.sfc-highlight:hover {
    transform: translateY(-6px);
    border-color: color-mix(in srgb, var(--color-primary) 32%, transparent);
    box-shadow:
        0 1px 0 0 color-mix(in srgb, var(--color-white) 95%, transparent) inset,
        0 30px 80px -30px color-mix(in srgb, var(--color-primary-deep, #8a4d62) 38%, transparent);
}

.sfc-highlight__icon {
    width: 64px;
    height: 64px;
    margin: 0 auto var(--space-4, 16px);
    border-radius: 50%;
    background:
        radial-gradient(circle at 30% 30%,
            color-mix(in srgb, var(--color-white) 100%, transparent) 0%,
            color-mix(in srgb, var(--color-primary) 12%, var(--color-white)) 100%);
    color: var(--color-primary-deep, #8a4d62);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow:
        inset 0 1px 0 0 color-mix(in srgb, var(--color-white) 100%, transparent),
        0 8px 20px -8px color-mix(in srgb, var(--color-primary) 35%, transparent);
    transition:
        transform 500ms cubic-bezier(0.22, 1, 0.36, 1),
        background 400ms ease-out,
        color 400ms ease-out;
}

.sfc-highlight:hover .sfc-highlight__icon {
    transform: scale(1.06) rotate(-3deg);
    color: var(--color-primary);
    background:
        radial-gradient(circle at 30% 30%,
            color-mix(in srgb, var(--color-white) 100%, transparent) 0%,
            color-mix(in srgb, var(--color-primary) 22%, var(--color-white)) 100%);
}

.sfc-highlight__icon svg {
    width: 28px;
    height: 28px;
}

.sfc-highlight__title {
    font-family: var(--font-display, var(--font-heading));
    font-style: italic;
    font-weight: 400;
    font-size: clamp(1.125rem, 1.6vw, 1.375rem);
    line-height: 1.2;
    color: var(--color-ink, var(--color-primary));
    margin: 0 0 var(--space-2, 8px);
}

.sfc-highlight__text {
    font-family: var(--font-body);
    font-size: var(--text-sm, 14px);
    line-height: 1.6;
    color: var(--color-ink-soft, var(--color-text-muted));
    margin: 0;
}

/* ============================================================
 * Onglets — surcharges spécifiques (les bases sont dans woocommerce.css)
 * ============================================================ */
.sfc-product-page__after .woocommerce-tabs {
    margin-top: 0;
}

.woocommerce div.product .woocommerce-tabs ul.tabs {
    justify-content: center;
    margin-bottom: 24px;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li a {
    position: relative;
    padding: 16px 28px;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li a::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: -2px;
    width: 0;
    height: 2px;
    background: var(--color-gold);
    transform: translateX(-50%);
    transition: width 350ms cubic-bezier(0.22, 1, 0.36, 1);
}

.woocommerce div.product .woocommerce-tabs ul.tabs li.active a::after,
.woocommerce div.product .woocommerce-tabs ul.tabs li a:hover::after {
    width: 60%;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li.active a {
    border-bottom-color: transparent;
}

.woocommerce div.product .woocommerce-tabs .panel {
    background: var(--color-white);
    border-radius: 12px;
    padding: 40px clamp(24px, 4vw, 56px) !important;
    box-shadow: 0 1px 2px rgba(26, 38, 64, 0.05);
    max-width: 920px;
    margin: 0 auto;
    animation: sfc-tab-fade 400ms ease;
}

@keyframes sfc-tab-fade {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}

.woocommerce div.product .woocommerce-tabs .panel h2 {
    text-align: center;
    margin-bottom: 24px;
    position: relative;
    padding-bottom: 16px;
}

.woocommerce div.product .woocommerce-tabs .panel h2::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 2px;
    background: var(--color-gold);
}

/* ============================================================
 * Related & upsells
 * ============================================================ */
.sfc-product-page__after .related,
.sfc-product-page__after .upsells {
    margin-top: 80px;
}

.sfc-product-page__after .related > h2,
.sfc-product-page__after .upsells > h2 {
    font-family: var(--font-heading);
    font-size: clamp(24px, 2.6vw, 34px);
    font-weight: 600;
    color: var(--color-primary);
    text-align: center;
    margin-bottom: 32px;
    position: relative;
    padding-bottom: 16px;
}

.sfc-product-page__after .related > h2::after,
.sfc-product-page__after .upsells > h2::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 48px;
    height: 2px;
    background: var(--color-gold);
}

/* ============================================================
 * Produits similaires / ventes incitatives — grille alignée + cards normalisées.
 * woocommerce-shop.css (qui normalise .sfc-product-card) n'est pas chargé sur la
 * fiche produit : on reprend ici l'essentiel pour éviter le déséquilibre dû à la
 * 2e image qui s'empile, et on centre la rangée incomplète. Même logique que la
 * grille « Les objets de cette table » des single look.
 * ============================================================ */
.sfc-product-page__after .related ul.products,
.sfc-product-page__after .upsells ul.products {
    display: flex;
    flex-wrap: wrap;
    justify-content: center; /* rangée incomplète centrée */
    gap: clamp(20px, 2.4vw, 32px);
    margin: 0;
    padding: 0;
    list-style: none;
}

/* Clearfix WooCommerce/Storefront (::before/::after, content:""; display:table) :
 * en flex/grid ils deviennent des items VIDES (cellule fantôme) → neutralisés. */
.sfc-product-page__after .related ul.products::before,
.sfc-product-page__after .related ul.products::after,
.sfc-product-page__after .upsells ul.products::before,
.sfc-product-page__after .upsells ul.products::after {
    content: none;
    display: none;
}

/* Cards : base ~240px, plafonnées → rangées pleines alignées, rangée incomplète
 * centrée. width/float !important écrasent la largeur % (layout float Storefront). */
.sfc-product-page__after .related ul.products > li.product,
.sfc-product-page__after .upsells ul.products > li.product {
    flex: 1 1 240px;
    max-width: 300px;
    width: auto !important;
    float: none !important;
    margin: 0 !important;
}

/* Média en ratio carré fixe : la 2e image se SUPERPOSE au lieu de s'empiler
 * → hauteurs homogènes, plus de déséquilibre 1 image vs 2 images. */
.sfc-product-page__after .related .sfc-product-card__media,
.sfc-product-page__after .upsells .sfc-product-card__media {
    display: block; /* le média est un <span> (inline par défaut) → sans ça, width/aspect-ratio ignorés */
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: var(--color-cream);
}
.sfc-product-page__after .related .sfc-product-card__media img,
.sfc-product-page__after .upsells .sfc-product-card__media img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    margin: 0;
    padding: 0;
}

/* ============================================================
 * Reveal animations
 * ============================================================ */
.sfc-reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 700ms cubic-bezier(0.22, 1, 0.36, 1), transform 700ms cubic-bezier(0.22, 1, 0.36, 1);
}

.sfc-reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ANIM-20 — Galerie produit : entrée SANS fondu d'opacité (slide seul). L'image
 * principale est l'élément LCP de la fiche : on la garde peinte immédiatement
 * (opacity:1) pour ne PAS retarder le LCP ; elle glisse simplement en place.
 * Le zoom au survol + le slider/lightbox WC restent inchangés. */
.sfc-product-page__media.sfc-reveal {
    opacity: 1;
}

@keyframes sfc-float-soft {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50%      { transform: translate(20px, -10px) scale(1.05); }
}

@media (prefers-reduced-motion: reduce) {
    .sfc-reveal { opacity: 1; transform: none; transition: none; }
    .sfc-product-page__hero::before,
    .sfc-highlights__halo { animation: none; }
    .sfc-highlight,
    .sfc-highlight:hover { transform: none; transition: none; }
    .sfc-pill.is-active::after { animation: none; }
    .is-flashing { animation: none; }
}

/* ============================================================
 * Responsive
 * ============================================================ */
@media (max-width: 1024px) {
    .sfc-product-page__grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .sfc-product-page__media,
    .sfc-product-page__summary {
        position: static;
    }

    .sfc-product-page__media {
        max-width: 640px;
        margin-inline: auto;
    }

    .sfc-highlights__inner {
        grid-template-columns: repeat(2, 1fr);
    }

    .sfc-highlight + .sfc-highlight::before { display: none; }
}

@media (max-width: 640px) {
    .sfc-product-page { padding-bottom: 48px; }
    .sfc-product-page__hero { padding: 20px 0 8px; }
    .sfc-product-page__grid { padding: 24px 0 40px; }

    .woocommerce div.product .summary { padding: 24px 20px; }
    .woocommerce div.product .product_title { font-size: 26px; }

    .sfc-trust-row { grid-template-columns: 1fr; gap: 12px; padding: 16px; }

    .sfc-highlights { padding: 48px 0; margin: 24px 0 48px; }
    .sfc-highlights__inner { grid-template-columns: 1fr; gap: 12px; }

    .woocommerce div.product form.cart {
        flex-direction: column;
        align-items: stretch;
    }

    .woocommerce div.product form.cart .single_add_to_cart_button {
        width: 100%;
        flex: none;
    }
}

/* --- Bandeau info plateaux froids (délai 48h / livraison Lyon / Click & Collect) --- */
.sfc-platter-notice {
    margin: 20px 0 24px;
    padding: 16px 20px;
    background: var(--color-cream);
    border-top: 3px solid var(--color-gold);
    border-radius: var(--radius-ui);
}

.sfc-platter-notice__title {
    margin: 0 0 8px;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: var(--color-primary);
}

.sfc-platter-notice__list {
    margin: 0;
    padding-left: 1.1em;
    list-style: disc;
}

.sfc-platter-notice__list li {
    margin: 2px 0;
    color: var(--color-text);
}

.sfc-platter-notice__list strong {
    color: var(--color-primary);
}

/* ============================================================
 * Phase 3.2 — Bouton wishlist sur fiche produit + polish tabs MH
 * ============================================================ */

/* Wishlist bouton fiche (gros, avec label) — sous le bouton "Add to cart" */
.sfc-single-wishlist {
    display: inline-flex;
    align-items: center;
    gap: var(--space-3);
    margin-top: var(--space-4);
    padding-top: var(--space-4);
    border-top: 1px solid var(--color-rule);
    width: 100%;
}

.sfc-single-wishlist .sfc-wishlist-toggle {
    position: static;
    opacity: 1;
    transform: none;
    width: 44px;
    height: 44px;
}

.sfc-single-wishlist__label {
    font-family: var(--font-body);
    font-size: var(--text-sm);
    color: var(--color-ink-soft);
    letter-spacing: var(--tracking-wide);
}

/* Tabs Madame's Home — underline rose poudré au lieu de l'or Yvonne */
.woocommerce div.product .woocommerce-tabs ul.tabs li a {
    font-family: var(--font-display);    /* Frank Ruhl Libre */
    color: var(--color-ink-soft);
}

.woocommerce div.product .woocommerce-tabs ul.tabs li.active a {
    color: var(--color-primary);
}

.woocommerce div.product .woocommerce-tabs ul.tabs li a::after {
    background: var(--color-primary);
}

.woocommerce div.product .woocommerce-tabs .panel {
    font-family: var(--font-body);
    color: var(--color-ink);
    line-height: var(--leading-normal);
}

.woocommerce div.product .woocommerce-tabs .panel h2 {
    font-family: var(--font-display);
    font-style: italic;
    color: var(--color-ink);
}

.woocommerce div.product .woocommerce-tabs .panel h2::after {
    background: var(--color-primary);
}

/* ============================================================================
 * STICKY CART BAR MOBILE — fiche produit
 * Liquid glass MH : capsule fixée juste au-dessus de la bottom-nav (≤1024px).
 * Mécanique :
 *  - Hauteur estimée bottom-nav : ~70 px (item 56 + padding 12 + border 2)
 *    + offset 12 px du fond + safe-area iOS → on se pose ~94 px plus haut
 *  - Animation slide synchronisée avec la bottom-nav via `body.sfc-scroll-down`
 *    (handler unique dans main.js) + même cubic-bezier/durée pour un mouvement
 *    uniforme : on descend → les deux glissent ensemble vers le bas ;
 *    on remonte → les deux réapparaissent en même temps.
 *  - Capsule à bords arrondis (pas full-width) pour matcher la bottom-nav.
 * ============================================================================ */
.sfc-product-sticky {
    display: none;
}

@media (max-width: 1024px) {
    .sfc-product-sticky {
        display: block;
        position: fixed;
        /* Capsule alignée avec la bottom-nav (gauche/droite 12 px). */
        left: 12px;
        right: 12px;
        /* Au-dessus de la bottom-nav : safe-area + offset bn (12) + hauteur bn (~70) + gap (8). */
        bottom: calc(12px + env(safe-area-inset-bottom, 0px) + 70px + 8px);
        z-index: 149; /* juste sous la bottom-nav (150) pour ne jamais la couvrir */
        padding: 10px 14px;
        background: color-mix(in srgb, var(--color-white) 70%, transparent);
        -webkit-backdrop-filter: blur(24px) saturate(1.4);
                backdrop-filter: blur(24px) saturate(1.4);
        border: 1px solid color-mix(in srgb, var(--color-primary, #d4a8b7) 28%, transparent);
        border-radius: 20px; /* même radius que la bottom-nav */
        box-shadow:
            0 1px 0 0 color-mix(in srgb, var(--color-white) 95%, transparent) inset,
            0 12px 30px -8px color-mix(in srgb, var(--color-primary-deep, #8a4d62) 25%, transparent);
        transform: translateY(0);
        /* Même cubic-bezier et durée que la bottom-nav → glissement uniforme. */
        transition: transform 280ms cubic-bezier(.4, 0, .2, 1);
    }

    /* Scroll-down : glisse vers le bas (matched avec la bottom-nav). */
    body.sfc-scroll-down .sfc-product-sticky {
        transform: translateY(calc(100% + 12px + env(safe-area-inset-bottom, 0px) + 70px + 8px));
    }

    /* Liseré doré subtil (signature MH) en sommet de la capsule. */
    .sfc-product-sticky::before {
        content: "";
        position: absolute;
        top: -1px;
        left: 20%;
        right: 20%;
        height: 1px;
        background: linear-gradient(90deg,
            transparent 0%,
            color-mix(in srgb, var(--color-gold, #c9a55c) 70%, transparent) 50%,
            transparent 100%);
        border-radius: 1px;
        pointer-events: none;
    }

    .sfc-product-sticky__inner {
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .sfc-product-sticky__info {
        flex: 1;
        min-width: 0;
        display: flex;
        flex-direction: column;
        gap: 2px;
    }

    .sfc-product-sticky__name {
        font-family: var(--font-body);
        font-size: 12px;
        letter-spacing: 0.02em;
        color: var(--color-ink-soft, #6b5a5d);
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .sfc-product-sticky__price {
        font-family: var(--font-display);
        font-style: italic;
        font-size: 18px;
        line-height: 1.1;
        color: var(--color-primary-deep, #8a4d62);
    }

    .sfc-product-sticky__price .amount,
    .sfc-product-sticky__price bdi {
        color: inherit;
        font-family: inherit;
        font-size: inherit;
    }

    .sfc-product-sticky__price del {
        opacity: 0.5;
        margin-right: 6px;
        font-size: 0.85em;
    }

    .sfc-product-sticky__actions {
        display: flex;
        align-items: center;
        gap: 8px;
        flex-shrink: 0;
    }

    /* Bouton wishlist du sticky bar — un peu plus discret que sur card. */
    .sfc-product-sticky .sfc-wishlist-toggle.sfc-product-sticky__wishlist {
        width: 44px;
        height: 44px;
        background: color-mix(in srgb, var(--color-white) 88%, transparent);
        border: 1px solid color-mix(in srgb, var(--color-primary, #d4a8b7) 20%, transparent);
        backdrop-filter: blur(8px);
    }

    /* Bouton add-to-cart : pill rose poudré pleine, lisible. */
    .sfc-product-sticky__add {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        padding: 12px 22px;
        border-radius: 999px;
        font-family: var(--font-body);
        font-size: 14px;
        font-weight: 500;
        letter-spacing: 0.04em;
        text-transform: uppercase;
        white-space: nowrap;
        cursor: pointer;
        transition: transform 250ms ease-out, box-shadow 300ms ease-out;
        box-shadow: 0 8px 24px -6px color-mix(in srgb, var(--color-primary-deep, #8a4d62) 35%, transparent);
    }

    .sfc-product-sticky__add:hover {
        transform: translateY(-1px);
        box-shadow: 0 12px 30px -8px color-mix(in srgb, var(--color-primary-deep, #8a4d62) 50%, transparent);
    }

    .sfc-product-sticky__add:active {
        transform: translateY(0);
    }

    .sfc-product-sticky__add[disabled] {
        opacity: 0.55;
        cursor: not-allowed;
        box-shadow: none;
    }

    /* Pousser le contenu pour qu'il ne soit pas recouvert par la capsule + bottom-nav.
       (bottom-nav 70 + offset 12 + gap 8 + sticky bar ~64 + safe-area + marge) */
    body.single-product {
        padding-bottom: calc(170px + env(safe-area-inset-bottom, 0px));
    }
}

@media (max-width: 480px) {
    .sfc-product-sticky__name { font-size: 11px; }
    .sfc-product-sticky__price { font-size: 16px; }
    .sfc-product-sticky__add { padding: 10px 16px; font-size: 13px; }
    .sfc-product-sticky .sfc-wishlist-toggle.sfc-product-sticky__wishlist { width: 40px; height: 40px; }
}

@media (prefers-reduced-motion: reduce) {
    .sfc-product-sticky,
    .sfc-product-sticky__add { transition: none; }
}
