/*
Theme Name: MickaCarpe28
Theme URI: https://mikacarpe28.fr/
Description: Thème blanc et sobre pour la boutique MickaCarpe28, compatible WooCommerce. Accueil animé avec les meilleures ventes et les rayons, modifiables depuis Apparence > Personnaliser.
Version: 1.4.1
Requires at least: 6.0
Requires PHP: 7.4
WC requires at least: 7.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: mickacarpe28
*/

/* Page blanche et simple, comme le site d'origine, avec du mouvement. Thème clair uniquement. */
:root {
	--bg: #ffffff;
	--soft: #f4f5f3;
	--ink: #161816;
	--muted: #5e635e;
	--line: #e3e5e2;
	--green: #3f5b2e;
	--f-head: "Archivo", "Helvetica Neue", Arial, sans-serif;
	--f-body: "Source Sans 3", system-ui, -apple-system, "Segoe UI", sans-serif;
	color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { background: var(--bg); color: var(--ink); font: 400 17px/1.6 var(--f-body); margin: 0; overflow-x: hidden; }
a { color: inherit; }
img { max-width: 100%; height: auto; }
h1, h2, h3, h4 { font-family: var(--f-head); text-wrap: balance; margin: 0 0 .5em; line-height: 1.15; font-weight: 700; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); white-space: nowrap; }
.skip-link:focus { position: fixed; top: 8px; left: 8px; z-index: 100; background: var(--ink); color: #fff; padding: 10px 14px; width: auto; height: auto; clip: auto; }

.wrap { max-width: 1120px; margin: 0 auto; padding-inline: clamp(16px, 4vw, 32px); }

/* En-tête */
.site-header { position: sticky; top: 0; z-index: 20; background: rgba(255, 255, 255, .94); backdrop-filter: blur(8px); border-bottom: 1px solid transparent; transition: border-color .2s, box-shadow .2s; }
.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .site-header { top: 0; } }
.site-header.is-scrolled { border-color: var(--line); box-shadow: 0 6px 20px -14px rgba(0, 0, 0, .25); }
.site-header__bar { display: flex; align-items: center; gap: 24px; padding-block: 16px; transition: padding .2s; }
.site-header.is-scrolled .site-header__bar { padding-block: 10px; }
.site-logo { font: 800 21px/1 var(--f-head); text-decoration: none; display: inline-flex; align-items: center; gap: 10px; }
.site-logo img { max-height: 44px; width: auto; }
.main-nav { margin-left: auto; }
.main-nav ul { display: flex; gap: 22px; list-style: none; margin: 0; padding: 0; flex-wrap: wrap; }
.main-nav a { text-decoration: none; font-size: 16px; color: var(--muted); position: relative; }
.main-nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 2px; background: var(--ink); transform: scaleX(0); transform-origin: left; transition: transform .2s; }
.main-nav a:hover, .main-nav .current-menu-item > a { color: var(--ink); }
.main-nav a:hover::after, .main-nav .current-menu-item > a::after { transform: scaleX(1); }
.main-nav .sub-menu { display: none; }
.cart-link { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; font-weight: 600; }
.cart-count { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 99px; background: var(--ink); color: #fff; font-size: 12px; }
.cart-count.bump { animation: mc-bump .4s ease; }
@keyframes mc-bump { 50% { transform: scale(1.35); } }
.menu-toggle { display: none; margin-left: auto; background: none; border: 1px solid var(--line); border-radius: 4px; padding: 8px 12px; font: inherit; cursor: pointer; }
@media (max-width: 760px) {
	.menu-toggle { display: inline-block; }
	.main-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: #fff; border-bottom: 1px solid var(--line); padding: 8px clamp(16px, 4vw, 32px) 16px; }
	.main-nav.is-open { display: block; }
	.main-nav ul { flex-direction: column; gap: 12px; }
	.cart-link { margin-left: 0; }
}

/* Boutons */
.btn, .woocommerce a.button, .woocommerce button.button, .woocommerce input.button, .woocommerce #respond input#submit,
.woocommerce a.button.alt, .woocommerce button.button.alt {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none;
	font: 600 16px/1 var(--f-body); padding: 13px 20px; border-radius: 4px; border: 0;
	background: var(--ink); color: #fff; transition: background .2s, transform .15s; cursor: pointer;
}
.btn:hover, .woocommerce a.button:hover, .woocommerce button.button:hover, .woocommerce a.button.alt:hover, .woocommerce button.button.alt:hover {
	background: var(--green); color: #fff; transform: translateY(-2px);
}
.btn .arr { transition: transform .2s; }
.btn:hover .arr { transform: translateX(4px); }
.link { font-weight: 600; text-underline-offset: 4px; }

/* Accueil */
.hero { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 5vw, 56px); align-items: center; padding-block: clamp(36px, 6vw, 72px); }
.hero h1 { font-size: clamp(32px, 4.6vw, 50px); margin-bottom: 16px; }
.hero p { color: var(--muted); margin: 0 0 24px; max-width: 50ch; }
.hero__art { width: 100%; max-width: 460px; justify-self: center; }
.hero__art svg { width: 100%; height: auto; display: block; }
.hero__img { display: block; width: 100%; height: auto; mix-blend-mode: multiply; animation: mc-float 6s ease-in-out infinite; }
@keyframes mc-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
.draw path { stroke-dasharray: var(--len, 0); stroke-dashoffset: var(--len, 0); animation: mc-draw 1.8s ease forwards; }
@keyframes mc-draw { to { stroke-dashoffset: 0; } }
.swim1 { animation: mc-swim 6s ease-in-out infinite; }
.swim2 { animation: mc-swim 7s ease-in-out -2s infinite reverse; }
@keyframes mc-swim { 0%, 100% { transform: translate(0, 0) rotate(0); } 50% { transform: translate(-8px, 5px) rotate(-1.5deg); } }
.tail { transform-box: fill-box; transform-origin: left center; animation: mc-tail 1.4s ease-in-out infinite; }
@keyframes mc-tail { 0%, 100% { transform: rotate(-6deg); } 50% { transform: rotate(6deg); } }
.bubble { fill: none; stroke: var(--muted); stroke-width: 1.5; animation: mc-bub 4s ease-in infinite; opacity: 0; }
.bubble:nth-of-type(2) { animation-delay: 1.3s; }
.bubble:nth-of-type(3) { animation-delay: 2.6s; }
@keyframes mc-bub { 0% { transform: translateY(0); opacity: 0; } 15% { opacity: .8; } 100% { transform: translateY(-60px); opacity: 0; } }
@media (max-width: 760px) { .hero { grid-template-columns: 1fr; } .hero__art { max-width: 320px; order: -1; } }

.section { padding-block: clamp(36px, 5vw, 60px); }
.section--tight { padding-top: 0; }
.section__head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 24px; }
.section__head h2 { font-size: clamp(26px, 3vw, 34px); margin: 0; }

/* Apparition au défilement : visible au repos, léger glissement seulement */
.reveal { transition: transform .7s cubic-bezier(.2, .7, .2, 1); }
.js .reveal.is-pending { transform: translateY(18px); }

/* Cartes produits de l'accueil */
.prods { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 28px 20px; }
.pcard { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.pcard__pic { position: relative; display: block; aspect-ratio: 1 / 1; background: var(--soft); border-radius: 4px; overflow: hidden; }
.pcard__pic img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s cubic-bezier(.2, .7, .2, 1), opacity .25s; }
.pcard:hover .pcard__pic img { transform: scale(1.06); }
.pcard__pic img.is-swapping { opacity: .3; }
.pcard__flag { position: absolute; left: 10px; top: 10px; font-size: 12px; font-weight: 600; background: var(--ink); color: #fff; border-radius: 3px; padding: 3px 8px; z-index: 1; }
.pcard__cat { font-size: 14px; color: var(--muted); }
.pcard h3 { font-size: 19px; margin: 0; }
.pcard h3 a { text-decoration: none; }
.pcard__price { font-weight: 600; }
.pcard__price del { color: var(--muted); font-weight: 400; margin-right: 6px; }
.pcard__price ins { text-decoration: none; }
.pcard__desc { font-size: 15px; color: var(--muted); margin: 0; }
.swatches { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.swatch { width: 26px; height: 26px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 1px var(--line); cursor: pointer; padding: 0; background: #9a9d98; transition: transform .15s, box-shadow .15s; }
.swatch:hover { transform: scale(1.12); }
.swatch[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--ink); }
.swatch--gravier { background: #8e8c84; }
.swatch--noir { background: #262726; }
.swatch--sable { background: #cdb98f; }
.swatch--vert-camou { background: #58633c; }
.swatches__name { font-size: 14px; color: var(--muted); margin-left: 4px; }
.weights { font-size: 14px; color: var(--muted); margin: 0; }
.pcard .button, .pcard .btn { margin-top: auto; }
.pcard .added_to_cart { font-size: 14px; font-weight: 600; text-align: center; }

/* Rayons */
.cat-search { display: flex; align-items: center; gap: 10px; border: 1px solid var(--line); border-radius: 4px; padding: 10px 14px; margin-bottom: 18px; max-width: 420px; transition: border-color .2s; }
.cat-search:focus-within { border-color: var(--ink); }
.cat-search input { border: 0; outline: 0; font: inherit; flex: 1; min-width: 0; background: transparent; color: var(--ink); }
.cats { columns: 3 220px; column-gap: 32px; margin: 0; padding: 0; list-style: none; }
.cats li { break-inside: avoid; border-bottom: 1px solid var(--line); }
.cats li[hidden] { display: none; }
.cats a { display: flex; justify-content: space-between; gap: 12px; padding: 12px 2px; text-decoration: none; transition: padding .2s, color .2s; }
.cats a:hover { color: var(--green); padding-left: 8px; }
.cats a::after { content: "→"; color: var(--muted); transition: transform .2s; }
.cats a:hover::after { transform: translateX(4px); color: var(--green); }
.cats__count { color: var(--muted); font-size: 14px; margin-left: auto; }
.cats mark { background: #e4ebd9; color: inherit; border-radius: 2px; }
.cats-empty { color: var(--muted); margin: 0; }

/* Contact */
.contact-band { background: var(--soft); }
.contact-band .wrap { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; }
.contact-band h2 { font-size: clamp(22px, 2.6vw, 28px); margin-bottom: 6px; }
.contact-band p { margin: 0; color: var(--muted); }

/* Pied de page */
.site-footer { border-top: 1px solid var(--line); padding-block: 32px 44px; font-size: 15px; color: var(--muted); }
.site-footer .wrap { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.site-footer ul { display: flex; gap: 18px; list-style: none; margin: 0; padding: 0; flex-wrap: wrap; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--ink); text-decoration: underline; }

.to-top { position: fixed; right: 16px; bottom: 16px; width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--ink); color: #fff; font-size: 18px; cursor: pointer; transform: translateY(80px); transition: transform .3s; z-index: 20; }
.to-top.is-visible { transform: none; }

/* Pages classiques et WooCommerce */
.page-content { padding-block: clamp(28px, 5vw, 56px); }
.page-content > h1 { font-size: clamp(28px, 4vw, 42px); }
/* Texte limité en largeur pour la lecture, mais les blocs de constructeurs (Elementor, Spectra…) gardent toute la largeur */
.entry-content > p, .entry-content > ul, .entry-content > ol, .entry-content > h2, .entry-content > h3, .entry-content > blockquote { max-width: 72ch; }

/* Page Contact */
.contact-page { text-align: center; }
.contact-page__head { max-width: 560px; margin: 0 auto clamp(28px, 4vw, 44px); }
.contact-page__head h1 { font-size: clamp(32px, 4.6vw, 48px); margin-bottom: 10px; }
.contact-page__head p { color: var(--muted); margin: 0; font-size: 18px; }
.contact-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; max-width: 980px; margin: 0 auto; }
.contact-card { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 32px 24px 28px; background: var(--soft); border-radius: 8px; min-width: 0; transition: transform .2s; }
.contact-card:hover { transform: translateY(-3px); }
.contact-card__icon { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; background: #fff; margin-bottom: 4px; }
.contact-card__icon svg { width: 26px; height: 26px; fill: none; stroke: var(--ink); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.contact-card h2 { font-size: 15px; font-family: var(--f-body); font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; margin: 0; }
.contact-card__value { font: 600 19px/1.4 var(--f-head); margin: 0 0 8px; overflow-wrap: anywhere; }
.contact-card__actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.contact-card .btn { margin-top: auto; }
.btn--ghost { background: #fff; color: var(--ink); box-shadow: inset 0 0 0 1px var(--line); }
.btn--ghost:hover { background: #fff; color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.contact-form { max-width: 640px; margin: clamp(36px, 5vw, 56px) auto 0; text-align: left; }
.contact-form h2 { text-align: center; font-size: clamp(22px, 2.6vw, 28px); }
.contact-form input:not([type="submit"]):not([type="checkbox"]):not([type="radio"]), .contact-form textarea, .contact-form select { width: 100%; font: inherit; border: 1px solid var(--line); border-radius: 4px; padding: 10px 12px; }
.contact-form input[type="submit"], .contact-form button[type="submit"] { font: 600 16px/1 var(--f-body); padding: 13px 20px; border-radius: 4px; border: 0; background: var(--ink); color: #fff; cursor: pointer; }
.contact-page__shop { margin-top: clamp(32px, 5vw, 48px); color: var(--muted); }
.contact-page__shop a { color: var(--ink); font-weight: 600; text-underline-offset: 4px; }
@media (max-width: 600px) {
	.contact-card { padding: 26px 18px 22px; }
	.contact-card .btn, .contact-card__actions { width: 100%; }
	.contact-card__actions .btn { flex: 1; }
}
.woocommerce span.onsale { background: var(--green); border-radius: 3px; min-height: 0; min-width: 0; padding: 4px 10px; line-height: 1.4; }

/* Boutique : en-tête, rayons, barre d'outils */
.shop__head { margin-block: 8px 20px; }
.shop__head h1 { font-size: clamp(30px, 4.4vw, 46px); margin: 0 0 8px; }
.shop__head .term-description, .shop__head .page-description { color: var(--muted); max-width: 65ch; }
.shop__head .term-description p { margin: 0; }

.cat-chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 10px; margin-bottom: 18px; scrollbar-width: thin; scroll-snap-type: x proximity; }
.cat-chip { flex: none; scroll-snap-align: start; text-decoration: none; font-size: 15px; padding: 8px 14px; border: 1px solid var(--line); border-radius: 99px; white-space: nowrap; transition: border-color .2s, background .2s, color .2s; }
.cat-chip:hover { border-color: var(--ink); }
.cat-chip.is-active { background: var(--ink); border-color: var(--ink); color: #fff; }

.shop__toolbar { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; padding-block: 14px; border-block: 1px solid var(--line); margin-bottom: 18px; }
.shop__toolbar .woocommerce-product-search { display: flex; gap: 8px; flex: 1 1 260px; max-width: 420px; }
.shop__toolbar .woocommerce-product-search input[type="search"] { flex: 1; min-width: 0; font: inherit; border: 1px solid var(--line); border-radius: 4px; padding: 9px 12px; }
.shop__toolbar .woocommerce-product-search input[type="search"]:focus { border-color: var(--ink); outline: 0; }
.shop__toolbar .woocommerce-product-search button { font: 600 15px/1 var(--f-body); background: var(--ink); color: #fff; border: 0; border-radius: 4px; padding: 0 16px; cursor: pointer; }
.shop__sort { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.woocommerce .shop__sort .woocommerce-result-count, .woocommerce .shop__sort .woocommerce-ordering { float: none; margin: 0; color: var(--muted); font-size: 15px; }
.shop__sort select { font: inherit; font-size: 15px; border: 1px solid var(--line); border-radius: 4px; padding: 8px 10px; background: #fff; color: var(--ink); }

.color-filter { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 24px; }
.color-filter__label { font-size: 14px; color: var(--muted); margin-right: 4px; }
.color-chip { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; font-size: 15px; padding: 5px 12px 5px 6px; border: 1px solid var(--line); border-radius: 99px; transition: border-color .2s; }
.color-chip .swatch { width: 20px; height: 20px; cursor: inherit; }
.color-chip:hover, .color-chip.is-active { border-color: var(--ink); }
.color-chip.is-active { font-weight: 600; }
.color-filter__reset { font-size: 14px; color: var(--muted); margin-left: 4px; }

.prods--shop { margin-bottom: 36px; }
.pcard.is-out .pcard__pic img { filter: grayscale(.8); opacity: .7; }
.shop__empty { text-align: center; padding-block: 48px; }
.shop__empty p { color: var(--muted); }

.woocommerce nav.woocommerce-pagination ul { border: 0; display: inline-flex; gap: 6px; }
.woocommerce nav.woocommerce-pagination ul li { border: 0; }
.woocommerce nav.woocommerce-pagination ul li a, .woocommerce nav.woocommerce-pagination ul li span { min-width: 40px; padding: 10px; border: 1px solid var(--line); border-radius: 4px; color: var(--ink); }
.woocommerce nav.woocommerce-pagination ul li span.current, .woocommerce nav.woocommerce-pagination ul li a:hover { background: var(--ink); border-color: var(--ink); color: #fff; }

/* Grilles WooCommerce (produits similaires, ventes croisées) */
.woocommerce ul.products { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 28px 20px; margin: 0 0 32px; }
.woocommerce ul.products::before, .woocommerce ul.products::after { display: none; }
.woocommerce ul.products li.product { width: auto !important; float: none !important; margin: 0 !important; display: flex; flex-direction: column; gap: 6px; }
.woocommerce ul.products li.product a img { border-radius: 4px; background: var(--soft); margin: 0 0 8px; transition: transform .4s; }
.woocommerce ul.products li.product:hover a img { transform: translateY(-4px); }
.woocommerce ul.products li.product .woocommerce-loop-product__title { font-family: var(--f-head); font-size: 17px; padding: 0; color: var(--ink); }
.woocommerce ul.products li.product .price { color: var(--ink); font-weight: 600; font-size: 16px; }
.woocommerce ul.products li.product .button { margin-top: auto; }

/* Fiche produit */
.product-page .woocommerce-breadcrumb { margin-bottom: 20px; }
.woocommerce div.product div.images img { border-radius: 4px; background: var(--soft); }
.woocommerce div.product .product_title { font-size: clamp(28px, 3.6vw, 40px); }
.woocommerce div.product p.price, .woocommerce div.product span.price { color: var(--ink); font-weight: 600; font-size: 22px; }
.woocommerce div.product .woocommerce-product-details__short-description { color: var(--muted); }
.woocommerce div.product form.cart .variations { margin-bottom: 12px; }
.woocommerce div.product form.cart .variations th, .woocommerce div.product form.cart .variations td { display: block; padding: 0; text-align: left; line-height: 1.4; }
.woocommerce div.product form.cart .variations th label { font-weight: 600; font-size: 15px; }
.woocommerce div.product form.cart .variations td { padding-bottom: 16px; }
.woocommerce div.product form.cart .variations select { font: inherit; border: 1px solid var(--line); border-radius: 4px; padding: 9px 10px; background: #fff; min-width: 200px; }
.variations select.is-swatched { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
/* Boutons d'une extension de pastilles : masqués seulement quand ceux du thème sont en place */
.variations .mc28-swatched .variable-items-wrapper,
.variations .mc28-swatched .cfvsw-swatches-container,
.variations .mc28-swatched .tawcvs-swatches,
.variations .mc28-swatched .wcboost-variation-swatches { display: none !important; }

/* Bouton "Ajouter au panier" désactivé tant qu'aucune option n'est choisie (au lieu du violet WooCommerce) */
.woocommerce button.button.alt.disabled, .woocommerce button.button.alt:disabled, .woocommerce button.button.alt:disabled[disabled],
.woocommerce button.button.alt.disabled:hover, .woocommerce button.button.alt:disabled:hover {
	background: var(--ink); color: #fff; opacity: .35; transform: none; cursor: not-allowed;
}
.vswatches { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 8px; }
.vswatches .swatch { width: 32px; height: 32px; }
.vswatches button { cursor: pointer !important; }
.vswatches .is-unavailable { opacity: .35; }
.vchip.is-unavailable { text-decoration: line-through; }
.vswatches__name { font-size: 15px; color: var(--muted); margin-left: 4px; }
.vchip { font: 600 15px/1 var(--f-body); padding: 9px 12px; border: 1px solid var(--line); border-radius: 4px; background: #fff; color: var(--ink); cursor: pointer; transition: border-color .15s, background .15s; }
.vchip:hover:not(:disabled) { border-color: var(--ink); }
.vchip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.woocommerce div.product form.cart .reset_variations { font-size: 14px; color: var(--muted); }
.woocommerce .quantity .qty { font: inherit; width: 4.5em; padding: 10px 6px; border: 1px solid var(--line); border-radius: 4px; }
.woocommerce div.product form.cart .button { padding-inline: 28px; }
.product-help { font-size: 15px; color: var(--muted); }
.woocommerce div.product .product_meta { font-size: 14px; color: var(--muted); }
.woocommerce div.product .woocommerce-tabs ul.tabs { padding: 0; border-bottom: 1px solid var(--line); }
.woocommerce div.product .woocommerce-tabs ul.tabs::before { display: none; }
.woocommerce div.product .woocommerce-tabs ul.tabs li { background: none; border: 0; border-radius: 0; margin: 0 20px 0 0; padding: 0; }
.woocommerce div.product .woocommerce-tabs ul.tabs li::before, .woocommerce div.product .woocommerce-tabs ul.tabs li::after { display: none; }
.woocommerce div.product .woocommerce-tabs ul.tabs li a { padding: 10px 0; font-weight: 600; color: var(--muted); }
.woocommerce div.product .woocommerce-tabs ul.tabs li.active a { color: var(--ink); box-shadow: inset 0 -2px 0 var(--ink); }
.woocommerce div.product .woocommerce-tabs .panel { max-width: 72ch; }
.related.products > h2, .upsells.products > h2 { font-size: clamp(22px, 2.6vw, 28px); margin-top: 24px; }
.woocommerce div.product .stock { color: var(--green); font-weight: 600; }
.woocommerce div.product .stock.out-of-stock { color: #a33a2b; }
.woocommerce-message, .woocommerce-info { border-top-color: var(--green); }
.woocommerce-message::before, .woocommerce-info::before { color: var(--green); }
.woocommerce .woocommerce-breadcrumb { color: var(--muted); }

/* Photos produits : toutes carrées et à la même taille, partout.
   --img-fit vaut "cover" (remplir) ou "contain" (photo entière), réglable dans le Customizer. */
body { --img-fit: cover; --img-pad: 0px; }
body.mc28-fit-contain { --img-fit: contain; --img-pad: 6%; }
.pcard__pic img,
.woocommerce ul.products li.product a img,
.woocommerce div.product div.images .woocommerce-product-gallery__image img,
.woocommerce div.product div.images .flex-control-thumbs li img,
.woocommerce-cart-form .product-thumbnail img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 1 / 1;
	object-fit: var(--img-fit);
	object-position: center;
	background: var(--soft);
}
.pcard__pic img { height: 100%; }
body.mc28-fit-contain .pcard__pic img,
body.mc28-fit-contain .woocommerce ul.products li.product a img,
body.mc28-fit-contain .woocommerce div.product div.images .woocommerce-product-gallery__image img { padding: var(--img-pad); }
.woocommerce div.product div.images .woocommerce-product-gallery__image img { border-radius: 4px; }
.woocommerce div.product div.images .flex-control-thumbs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 8px; }
.woocommerce div.product div.images .flex-control-thumbs li { width: auto; float: none; }
.woocommerce div.product div.images .flex-control-thumbs li img { border-radius: 3px; }
.woocommerce-cart-form .product-thumbnail img { width: 72px; border-radius: 3px; }
.woocommerce-mini-cart img { aspect-ratio: 1 / 1; object-fit: var(--img-fit); background: var(--soft); }

/* ===== Responsive ===== */

/* Fiche produit : photos et infos côte à côte, puis l'un sous l'autre sur petit écran */
.woocommerce div.product { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px clamp(24px, 4vw, 48px); align-items: start; }
.woocommerce div.product > * { grid-column: 1 / -1; min-width: 0; }
.woocommerce div.product > div.images,
.woocommerce div.product > div.summary { width: auto !important; float: none !important; margin: 0 !important; }
.woocommerce div.product > div.images { grid-column: 1; grid-row: 1; }
.woocommerce div.product > div.summary { grid-column: 2; grid-row: 1; }
.woocommerce div.product > span.onsale { grid-column: 1; grid-row: 1; justify-self: start; align-self: start; position: relative; z-index: 2; margin: 10px; }
.woocommerce div.product form.cart:not(.variations_form), .woocommerce div.product .woocommerce-variation-add-to-cart { display: flex; gap: 10px; flex-wrap: wrap; }
.woocommerce div.product form.cart .quantity { float: none; margin: 0; }
.woocommerce div.product form.cart .button { float: none; }
.woocommerce div.product .woocommerce-tabs ul.tabs { display: flex; overflow-x: auto; white-space: nowrap; scrollbar-width: none; }

@media (max-width: 820px) {
	.woocommerce div.product { grid-template-columns: minmax(0, 1fr); }
	.woocommerce div.product > div.images, .woocommerce div.product > div.summary { grid-column: 1; }
	.woocommerce div.product > div.summary { grid-row: 2; }
	.woocommerce div.product .woocommerce-variation-add-to-cart .button,
	.woocommerce div.product form.cart:not(.variations_form) .button { flex: 1; }
	.woocommerce div.product div.images .flex-control-thumbs { grid-template-columns: repeat(5, 1fr); gap: 6px; }
	.vswatches .swatch { width: 36px; height: 36px; }
	.vchip { padding: 11px 14px; }
}

/* Boutique : barre d'outils empilée sur téléphone */
@media (max-width: 640px) {
	.shop__toolbar { flex-direction: column; align-items: stretch; }
	.shop__toolbar .woocommerce-product-search { max-width: none; }
	.shop__sort { justify-content: space-between; }
	.shop__sort select { max-width: 60vw; }
	.cat-chips { margin-inline: calc(-1 * clamp(16px, 4vw, 32px)); padding-inline: clamp(16px, 4vw, 32px); }
}

/* Grilles produits : 2 colonnes sur téléphone, cartes compactes */
@media (max-width: 600px) {
	.prods, .woocommerce ul.products { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 12px; }
	.pcard { gap: 6px; }
	.pcard h3, .woocommerce ul.products li.product .woocommerce-loop-product__title { font-size: 15px; }
	.pcard__price, .woocommerce ul.products li.product .price { font-size: 15px; }
	.pcard__desc, .pcard__cat { display: none; }
	.pcard__flag { font-size: 11px; left: 6px; top: 6px; }
	.swatches { gap: 6px; }
	.swatch { width: 24px; height: 24px; }
	.swatches__name { display: none; }
	.weights { font-size: 13px; line-height: 1.4; }
	.pcard .button, .woocommerce ul.products li.product .button { width: 100%; font-size: 14px; padding: 11px 8px; }
	.hero { padding-block: 28px 36px; }
	.section__head { margin-bottom: 16px; }
	.contact-band .wrap { flex-direction: column; align-items: stretch; text-align: left; }
	.contact-band .btn { justify-content: center; }
	.site-footer .wrap { flex-direction: column; }
}

/* Très petits écrans : une seule colonne */
@media (max-width: 360px) {
	.prods, .woocommerce ul.products { grid-template-columns: minmax(0, 1fr); }
}

/* Panier sur téléphone */
@media (max-width: 768px) {
	.woocommerce table.shop_table_responsive tr td::before { font-weight: 600; }
	.woocommerce-cart .cart-collaterals .cart_totals { width: 100%; float: none; }
	.woocommerce-cart .wc-proceed-to-checkout .checkout-button { width: 100%; }
	.woocommerce table.cart td.actions .coupon { display: flex; gap: 8px; }
	.woocommerce table.cart td.actions .coupon .input-text { flex: 1; width: auto !important; }
}

@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation: none !important; transition: none !important; }
	.draw path { stroke-dashoffset: 0; }
	.js .reveal.is-pending { transform: none; }
	html { scroll-behavior: auto; }
}
