/* ==========================================================================
   Sens & Thérapie — boutique en ligne (WooCommerce)
   Catalogue, fiche produit, panier, commande, compte client.
   Chargé uniquement sur ces pages (inc/boutique.php). Les styles de
   WooCommerce restent chargés : ce fichier les surcharge.
   ========================================================================== */

/* ---------- Conteneur & héros ---------- */
.stw { background: #fff; border-top: 1px solid rgba(124, 74, 134, 0.06); }
.stw__inner { max-width: 1240px; margin: 0 auto; padding: 64px 40px 110px; }
.stw--product .stw__inner { padding-top: 48px; }
.stw--checkout, .stw--cart { background: var(--st-bg-soft); }

.stp-hero--boutique .stp-hero__inner { padding-bottom: 52px; }
.stp-hero--boutique .stp-hero__title { font-size: 52px; }
.stp-hero--compact .stp-hero__inner { padding: 30px 40px 6px; }
.stp-hero--compact .st-breadcrumb { margin-bottom: 18px; }

/* Typographie de base dans le contenu WooCommerce */
.stw, .stw input, .stw select, .stw textarea, .stw button { font-family: var(--st-sans); }
.stw h2, .stw h3 { font-family: var(--st-serif); font-weight: 600; color: var(--st-ink); }

/* ---------- Lien panier (barre supérieure) ---------- */
.st-cart-link { position: relative; }
.st-cart-link__count {
  display: inline-flex; align-items: center; justify-content: center; min-width: 19px; height: 19px;
  margin-left: 4px; padding: 0 6px; border-radius: 100px; background: var(--st-accent);
  color: #fff; font-size: 11px; font-weight: 800; line-height: 1;
}

/* ---------- Boutons ---------- */
:is(.woocommerce, .woocommerce-page) .stw a.button, :is(.woocommerce, .woocommerce-page) .stw button.button, :is(.woocommerce, .woocommerce-page) .stw input.button,
:is(.woocommerce, .woocommerce-page) .stw .button.alt, .woocommerce-page .stw a.button, .woocommerce-page .stw button.button,
.stw .wc-block-components-button:not(.is-link), .stw .wp-element-button,
.st-produit__btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  padding: 14px 26px; border: none; border-radius: 100px;
  background: var(--st-accent); color: #fff;
  font-family: var(--st-sans); font-size: 15px; font-weight: 700; line-height: 1.2; text-decoration: none;
  box-shadow: 0 16px 32px -18px rgba(139, 90, 142, 0.9);
  cursor: pointer; transition: background .2s ease, transform .2s ease;
}
:is(.woocommerce, .woocommerce-page) .stw a.button:hover, :is(.woocommerce, .woocommerce-page) .stw button.button:hover, :is(.woocommerce, .woocommerce-page) .stw input.button:hover,
:is(.woocommerce, .woocommerce-page) .stw .button.alt:hover, .woocommerce-page .stw a.button:hover, .woocommerce-page .stw button.button:hover,
.stw .wc-block-components-button:not(.is-link):hover, .stw .wp-element-button:hover,
.st-produit__btn:hover { background: var(--st-accent-deep); color: #fff; }
:is(.woocommerce, .woocommerce-page) .stw button.button:disabled, :is(.woocommerce, .woocommerce-page) .stw button.button.disabled { opacity: .5; }
:is(.woocommerce, .woocommerce-page) .stw a.button.loading, .st-produit__btn.loading { opacity: .65; }
:is(.woocommerce, .woocommerce-page) .stw a.button.loading::after, .st-produit__btn.loading::after { display: none; }

/* Lien « Voir le panier » ajouté après un ajout sans rechargement */
.woocommerce a.added_to_cart, a.added_to_cart {
  display: inline-flex; align-items: center; margin: 10px 0 0 4px; padding: 0;
  font-size: 13.5px; font-weight: 700; color: var(--st-accent-deep); text-decoration: underline; text-underline-offset: 3px;
}
.st-produit__btn.added::after { content: "✓"; margin-left: 2px; }

/* ---------- Messages ---------- */
.woocommerce-notices-wrapper:empty { display: none; }
:is(.woocommerce, .woocommerce-page) .stw .woocommerce-message, :is(.woocommerce, .woocommerce-page) .stw .woocommerce-info, :is(.woocommerce, .woocommerce-page) .stw .woocommerce-error,
.st-produits__notices .woocommerce-message, .st-produits__notices .woocommerce-info, .st-produits__notices .woocommerce-error,
.stw .wc-block-components-notice-banner {
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px;
  margin: 0 0 28px; padding: 18px 22px; border: 1px solid var(--st-line-strong); border-radius: 14px;
  background: var(--st-card); color: var(--st-text); font-size: 15px; line-height: 1.5; list-style: none;
}
:is(.woocommerce, .woocommerce-page) .stw .woocommerce-message::before, :is(.woocommerce, .woocommerce-page) .stw .woocommerce-info::before, :is(.woocommerce, .woocommerce-page) .stw .woocommerce-error::before,
.st-produits__notices .woocommerce-message::before { display: none; }
:is(.woocommerce, .woocommerce-page) .stw .woocommerce-message, .st-produits__notices .woocommerce-message { border-left: 4px solid var(--st-accent); }
:is(.woocommerce, .woocommerce-page) .stw .woocommerce-error, .stw .wc-block-components-notice-banner.is-error { border-left: 4px solid #B4475B; }
:is(.woocommerce, .woocommerce-page) .stw .woocommerce-message .button, .st-produits__notices .woocommerce-message .button { order: 2; margin-left: auto; padding: 10px 20px; font-size: 14px; }
.stw .wc-block-components-notice-banner > svg { fill: var(--st-accent); }

/* ---------- Grille produits (catalogue, produits liés) ---------- */
:is(.woocommerce, .woocommerce-page) .stw ul.products, .woocommerce-page .stw ul.products {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin: 0 0 40px; padding: 0;
}
:is(.woocommerce, .woocommerce-page) .stw ul.products::before, :is(.woocommerce, .woocommerce-page) .stw ul.products::after { display: none; }
:is(.woocommerce, .woocommerce-page) .stw ul.products li.product, .woocommerce-page .stw ul.products li.product {
  position: relative; display: flex; flex-direction: column; float: none; width: auto; margin: 0; padding: 0 0 24px;
  background: var(--st-card); border: 1px solid var(--st-line); border-radius: 16px; overflow: hidden;
  transition: transform .25s ease, box-shadow .25s ease;
}
:is(.woocommerce, .woocommerce-page) .stw ul.products li.product:hover { transform: translateY(-3px); box-shadow: 0 26px 52px -34px rgba(80, 46, 90, 0.42); }
:is(.woocommerce, .woocommerce-page) .stw ul.products li.product a.woocommerce-LoopProduct-link { display: flex; flex-direction: column; flex: 1; color: inherit; }
:is(.woocommerce, .woocommerce-page) .stw ul.products li.product a img {
  width: 100%; aspect-ratio: 1 / 1; object-fit: cover; margin: 0 0 20px; background: #EAE0EC;
}
:is(.woocommerce, .woocommerce-page) .stw ul.products li.product .st-produit__cat { padding: 0 24px; }
:is(.woocommerce, .woocommerce-page) .stw ul.products li.product .woocommerce-loop-product__title {
  padding: 0 24px; margin: 0 0 10px; font-family: var(--st-serif); font-weight: 600; font-size: 22px; line-height: 1.15; color: var(--st-ink);
}
:is(.woocommerce, .woocommerce-page) .stw ul.products li.product .price {
  display: block; padding: 0 24px; margin: 0 0 16px; color: var(--st-ink); font-size: 16px; font-weight: 700;
}
:is(.woocommerce, .woocommerce-page) .stw ul.products li.product .button { align-self: flex-start; margin: auto 24px 0; }
:is(.woocommerce, .woocommerce-page) .stw ul.products li.product a.added_to_cart { margin: 10px 24px 0; }
:is(.woocommerce, .woocommerce-page) .stw span.onsale, :is(.woocommerce, .woocommerce-page) .stw ul.products li.product .onsale {
  position: absolute; top: 14px; left: 14px; right: auto; z-index: 2; min-width: 0; min-height: 0; margin: 0;
  padding: 6px 12px; border-radius: 100px; background: var(--st-gold); color: #fff;
  font-size: 11px; font-weight: 700; line-height: 1.4; letter-spacing: .08em; text-transform: uppercase;
}

/* Prix barrés */
:is(.woocommerce, .woocommerce-page) .stw .price del, .st-produit__price del { color: var(--st-muted-4); font-weight: 500; font-size: .85em; opacity: 1; }
:is(.woocommerce, .woocommerce-page) .stw .price ins, .st-produit__price ins { text-decoration: none; font-weight: 700; }

/* Tri & pagination */
:is(.woocommerce, .woocommerce-page) .stw .woocommerce-ordering { float: none; display: flex; justify-content: flex-end; margin: 0 0 26px; }
.stw select, :is(.woocommerce, .woocommerce-page) .stw .woocommerce-ordering select {
  appearance: none; padding: 11px 40px 11px 16px; border: 1px solid var(--st-line-strong); border-radius: 100px;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none' stroke='%237C4A86' stroke-width='1.8'%3E%3Cpath d='M1 1.5l5 5 5-5'/%3E%3C/svg%3E") no-repeat right 16px center;
  color: var(--st-text); font-size: 14px;
}
:is(.woocommerce, .woocommerce-page) .stw nav.woocommerce-pagination ul { display: flex; justify-content: center; gap: 8px; border: none; }
:is(.woocommerce, .woocommerce-page) .stw nav.woocommerce-pagination ul li { border: none; }
:is(.woocommerce, .woocommerce-page) .stw nav.woocommerce-pagination ul li a, :is(.woocommerce, .woocommerce-page) .stw nav.woocommerce-pagination ul li span {
  display: inline-flex; align-items: center; justify-content: center; min-width: 42px; height: 42px; padding: 0 12px;
  border-radius: 100px; border: 1px solid var(--st-line-strong); color: var(--st-text); font-weight: 700;
}
:is(.woocommerce, .woocommerce-page) .stw nav.woocommerce-pagination ul li span.current, :is(.woocommerce, .woocommerce-page) .stw nav.woocommerce-pagination ul li a:hover { background: var(--st-accent); border-color: var(--st-accent); color: #fff; }
:is(.woocommerce, .woocommerce-page) .stw .woocommerce-info.woocommerce-no-products-found { justify-content: center; text-align: center; }

/* ---------- Fiche produit ---------- */
:is(.woocommerce, .woocommerce-page) .stw div.product {
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 0 64px; align-items: start; position: relative;
}
:is(.woocommerce, .woocommerce-page) .stw div.product div.images, :is(.woocommerce, .woocommerce-page) .stw div.product div.summary {
  float: none; width: auto; margin: 0;
}
:is(.woocommerce, .woocommerce-page) .stw div.product div.images { border-radius: 18px; overflow: hidden; background: #EAE0EC; }
:is(.woocommerce, .woocommerce-page) .stw div.product div.images img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
:is(.woocommerce, .woocommerce-page) .stw div.product div.images .flex-control-thumbs { display: flex; gap: 10px; padding: 12px; background: #fff; }
:is(.woocommerce, .woocommerce-page) .stw div.product div.images .flex-control-thumbs li { width: 76px; float: none; }
:is(.woocommerce, .woocommerce-page) .stw div.product div.images .flex-control-thumbs li img { border-radius: 10px; opacity: .6; aspect-ratio: 1 / 1; }
:is(.woocommerce, .woocommerce-page) .stw div.product div.images .flex-control-thumbs li img.flex-active { opacity: 1; }
:is(.woocommerce, .woocommerce-page) .stw div.product div.images .woocommerce-product-gallery__trigger { top: 14px; right: 14px; background: #fff; border-radius: 100px; }
:is(.woocommerce, .woocommerce-page) .stw div.product > span.onsale { top: 16px; left: 16px; }

:is(.woocommerce, .woocommerce-page) .stw div.product div.summary { padding-top: 8px; position: sticky; top: 120px; }
.st-product__kicker { margin-bottom: 14px; }
:is(.woocommerce, .woocommerce-page) .stw div.product .product_title {
  font-family: var(--st-serif); font-weight: 500; font-size: 46px; line-height: 1.05; letter-spacing: -0.01em; color: var(--st-ink); margin: 0 0 18px;
}
:is(.woocommerce, .woocommerce-page) .stw div.product p.price, :is(.woocommerce, .woocommerce-page) .stw div.product span.price {
  margin: 0 0 22px; color: var(--st-accent-deep); font-size: 26px; font-weight: 700;
}
:is(.woocommerce, .woocommerce-page) .stw div.product .woocommerce-product-details__short-description {
  margin: 0 0 28px; font-size: 16px; line-height: 1.7; color: var(--st-muted-2);
}
:is(.woocommerce, .woocommerce-page) .stw div.product .woocommerce-product-details__short-description p { margin: 0 0 10px; }

:is(.woocommerce, .woocommerce-page) .stw div.product form.cart {
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: 0 0 30px; padding: 22px;
  border: 1px solid var(--st-line); border-radius: 16px; background: var(--st-card);
}
:is(.woocommerce, .woocommerce-page) .stw div.product form.cart::before, :is(.woocommerce, .woocommerce-page) .stw div.product form.cart::after { display: none; }
:is(.woocommerce, .woocommerce-page) .stw div.product form.cart .button { flex: 1; min-width: 200px; padding: 16px 28px; font-size: 15.5px; }
:is(.woocommerce, .woocommerce-page) .stw div.product form.cart table.variations { width: 100%; margin: 0 0 6px; }
:is(.woocommerce, .woocommerce-page) .stw div.product form.cart table.variations th, :is(.woocommerce, .woocommerce-page) .stw div.product form.cart table.variations td { display: block; padding: 0 0 8px; text-align: left; }
:is(.woocommerce, .woocommerce-page) .stw div.product form.cart table.variations label { font-weight: 700; color: var(--st-ink); }
:is(.woocommerce, .woocommerce-page) .stw div.product form.cart .single_variation_wrap { width: 100%; }
:is(.woocommerce, .woocommerce-page) .stw div.product form.cart .woocommerce-variation-add-to-cart { display: flex; gap: 12px; flex-wrap: wrap; }
:is(.woocommerce, .woocommerce-page) .stw div.product p.stock { margin: 0 0 18px; font-size: 14px; font-weight: 700; color: var(--st-accent-deep); }
:is(.woocommerce, .woocommerce-page) .stw div.product p.stock.out-of-stock { color: #B4475B; }

/* Quantité */
:is(.woocommerce, .woocommerce-page) .stw .quantity .qty {
  width: 76px; height: 50px; padding: 0 8px; border: 1px solid var(--st-line-strong); border-radius: 100px;
  background: #fff; color: var(--st-ink); font-size: 16px; font-weight: 700; text-align: center;
}

/* Réassurance */
.st-product__reassurance { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; }
.st-product__reassurance li { display: flex; gap: 14px; align-items: flex-start; font-size: 14px; line-height: 1.5; color: var(--st-muted); }
.st-product__reassurance strong { display: block; color: var(--st-ink); font-size: 14.5px; }
.st-product__reassurance-icon {
  flex: none; display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px;
  border-radius: 100px; background: #F3E9EE; color: var(--st-accent-deep);
}

/* Onglets (description) */
:is(.woocommerce, .woocommerce-page) .stw div.product .woocommerce-tabs { grid-column: 1 / -1; margin-top: 72px; padding-top: 48px; border-top: 1px solid var(--st-line); }
:is(.woocommerce, .woocommerce-page) .stw div.product .woocommerce-tabs ul.tabs { display: flex; gap: 8px; margin: 0 0 26px; padding: 0; }
:is(.woocommerce, .woocommerce-page) .stw div.product .woocommerce-tabs ul.tabs::before, :is(.woocommerce, .woocommerce-page) .stw div.product .woocommerce-tabs ul.tabs::after { display: none; }
:is(.woocommerce, .woocommerce-page) .stw div.product .woocommerce-tabs ul.tabs li {
  margin: 0; padding: 0; border: 1px solid var(--st-line-strong); border-radius: 100px; background: #fff;
}
:is(.woocommerce, .woocommerce-page) .stw div.product .woocommerce-tabs ul.tabs li::before, :is(.woocommerce, .woocommerce-page) .stw div.product .woocommerce-tabs ul.tabs li::after { display: none; }
:is(.woocommerce, .woocommerce-page) .stw div.product .woocommerce-tabs ul.tabs li a { display: block; padding: 10px 20px; color: var(--st-text); font-weight: 700; font-size: 14px; }
:is(.woocommerce, .woocommerce-page) .stw div.product .woocommerce-tabs ul.tabs li.active { background: var(--st-accent); border-color: var(--st-accent); }
:is(.woocommerce, .woocommerce-page) .stw div.product .woocommerce-tabs ul.tabs li.active a { color: #fff; }
:is(.woocommerce, .woocommerce-page) .stw div.product .woocommerce-tabs .panel { max-width: 820px; font-size: 16px; line-height: 1.75; color: var(--st-muted-2); }
:is(.woocommerce, .woocommerce-page) .stw div.product .woocommerce-tabs .panel > h2:first-child { display: none; }
:is(.woocommerce, .woocommerce-page) .stw table.shop_attributes { border: none; }
:is(.woocommerce, .woocommerce-page) .stw table.shop_attributes th, :is(.woocommerce, .woocommerce-page) .stw table.shop_attributes td { padding: 12px 0; border-bottom: 1px solid var(--st-line); background: none; font-style: normal; }

/* Produits liés */
:is(.woocommerce, .woocommerce-page) .stw div.product .related, :is(.woocommerce, .woocommerce-page) .stw div.product .upsells { grid-column: 1 / -1; margin-top: 72px; }
:is(.woocommerce, .woocommerce-page) .stw div.product .related > h2, :is(.woocommerce, .woocommerce-page) .stw div.product .upsells > h2 { font-size: 36px; font-weight: 500; margin: 0 0 28px; }

/* ---------- Champs de formulaire (compte, paiement classique) ---------- */
:is(.woocommerce, .woocommerce-page) .stw form .form-row { margin: 0 0 16px; padding: 0; }
:is(.woocommerce, .woocommerce-page) .stw form .form-row label { font-size: 14px; font-weight: 700; color: var(--st-ink); margin-bottom: 6px; }
:is(.woocommerce, .woocommerce-page) .stw form .form-row input.input-text, :is(.woocommerce, .woocommerce-page) .stw form .form-row textarea,
:is(.woocommerce, .woocommerce-page) .stw form .form-row select, :is(.woocommerce, .woocommerce-page) .stw .woocommerce-Input {
  width: 100%; padding: 14px 16px; border: 1px solid var(--st-line-strong); border-radius: 12px;
  background: #fff; color: var(--st-ink); font-size: 15px; line-height: 1.4;
}
:is(.woocommerce, .woocommerce-page) .stw form .form-row input.input-text:focus, :is(.woocommerce, .woocommerce-page) .stw form .form-row textarea:focus {
  outline: none; border-color: var(--st-accent); box-shadow: 0 0 0 3px rgba(139, 90, 142, 0.14);
}
:is(.woocommerce, .woocommerce-page) .stw form .form-row .required { color: #B4475B; text-decoration: none; }

/* ---------- Panier & commande (blocs WooCommerce) ---------- */
.stw .wp-block-woocommerce-cart, .stw .wp-block-woocommerce-checkout { margin: 0; }
.stw .wc-block-components-sidebar-layout { gap: 0; }
.stw .wc-block-components-main { padding-right: 4% !important; }

/* Colonne des articles / étapes */
.stw .wc-block-cart__main .wc-block-cart-items,
.stw .wc-block-checkout__main .wc-block-components-checkout-step {
  background: #fff; border: 1px solid var(--st-line); border-radius: 18px;
}
.stw .wc-block-cart__main .wc-block-cart-items { border-collapse: separate; border-spacing: 0; overflow: hidden; }
.stw .wc-block-cart-items th { padding: 18px 22px !important; font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--st-muted-4); border-bottom: 1px solid var(--st-line) !important; }
.stw .wc-block-cart-items td { padding: 22px !important; border-top: 1px solid var(--st-line) !important; vertical-align: top; }
.stw .wc-block-cart-items .wc-block-cart-item__image img { border-radius: 12px; aspect-ratio: 1 / 1; object-fit: cover; }
.stw .wc-block-components-product-name { font-family: var(--st-serif); font-size: 21px !important; font-weight: 600; color: var(--st-ink) !important; text-decoration: none; }
.stw .wc-block-components-product-price, .stw .wc-block-cart-item__total { font-weight: 700; color: var(--st-ink); }
.stw .wc-block-components-product-metadata { color: var(--st-muted); font-size: 13.5px; }
.stw .wc-block-components-quantity-selector { border-radius: 100px !important; border-color: var(--st-line-strong) !important; overflow: hidden; }
.stw .wc-block-components-quantity-selector::after { border: none !important; }
.stw .wc-block-components-quantity-selector input { font-weight: 700; }
.stw .wc-block-cart-item__remove-link { color: var(--st-muted-4) !important; font-size: 13px !important; text-decoration: underline !important; }

/* Étapes de la commande */
.stw .wc-block-checkout__main .wc-block-components-checkout-step { padding: 26px 28px 10px !important; margin: 0 0 18px !important; }
.stw .wc-block-components-checkout-step::after { display: none !important; }
.stw .wc-block-components-checkout-step__heading { margin: 0 0 14px !important; }
.stw .wc-block-components-checkout-step__title {
  font-family: var(--st-serif) !important; font-size: 26px !important; font-weight: 600 !important; color: var(--st-ink);
}
.stw .wc-block-components-checkout-step__container::after, .stw .wc-block-components-checkout-step__container::before { display: none !important; }
.stw .wc-block-components-checkout-step__description { color: var(--st-muted); }

/* Champs des blocs */
.stw .wc-block-components-text-input input, .stw .wc-block-components-text-input textarea,
.stw .wc-blocks-components-select .wc-blocks-components-select__select, .stw .wc-block-components-combobox .wc-block-components-combobox-control input {
  border: 1px solid var(--st-line-strong) !important; border-radius: 12px !important; background: #fff !important; color: var(--st-ink) !important;
}
.stw .wc-block-components-text-input input:focus, .stw .wc-blocks-components-select .wc-blocks-components-select__select:focus {
  border-color: var(--st-accent) !important; box-shadow: 0 0 0 3px rgba(139, 90, 142, 0.14) !important; outline: none !important;
}
.stw .wc-block-components-text-input label, .stw .wc-blocks-components-select__label { color: var(--st-muted) !important; }
.stw .wc-block-components-checkbox .wc-block-components-checkbox__input[type="checkbox"] { border-radius: 6px; border-color: var(--st-line-strong); }
.stw .wc-block-components-checkbox .wc-block-components-checkbox__input[type="checkbox"]:checked { background: var(--st-accent); border-color: var(--st-accent); }
.stw .wc-block-components-checkbox .wc-block-components-checkbox__mark { fill: #fff; }

/* Moyens de paiement */
.stw .wc-block-components-radio-control-accordion-option, .stw .wc-block-components-radio-control__option {
  border-radius: 14px !important; border-color: var(--st-line-strong) !important;
}
.stw .wc-block-components-radio-control__option-checked, .stw .wc-block-components-radio-control-accordion-option--checked-option-highlighted {
  box-shadow: inset 0 0 0 2px var(--st-accent) !important; background: #FBF6FB;
}
.stw .wc-block-components-radio-control__input:checked { border-color: var(--st-accent) !important; }
.stw .wc-block-components-radio-control__input:checked::before { background: var(--st-accent) !important; }
.stw .wc-block-components-radio-control__label { font-weight: 700; color: var(--st-ink); }

/* Récapitulatif (colonne de droite) */
.stw .wc-block-cart__sidebar {
  align-self: flex-start; padding: 26px 26px 18px !important; background: #fff; border: 1px solid var(--st-line); border-radius: 18px;
  position: sticky !important; top: 120px;
}
/* Commande : le bloc récapitulatif porte déjà son cadre, il devient la carte. */
.stw .wc-block-checkout__sidebar { align-self: flex-start; position: sticky !important; top: 120px; }
.stw .wc-block-checkout__sidebar .wp-block-woocommerce-checkout-order-summary-block {
  padding: 8px 10px 4px; background: #fff; border: 1px solid var(--st-line) !important; border-radius: 18px;
}
.stw .wc-block-cart__totals-title, .stw .wc-block-components-checkout-order-summary__title-text {
  font-family: var(--st-serif) !important; font-size: 26px !important; font-weight: 600 !important; text-transform: none !important; letter-spacing: 0 !important; color: var(--st-ink) !important;
}
.stw .wc-block-components-totals-wrapper { border-color: var(--st-line) !important; }
.stw .wc-block-components-totals-item__label { color: var(--st-muted-2); }
.stw .wc-block-components-totals-footer-item .wc-block-components-totals-item__label,
.stw .wc-block-components-totals-footer-item .wc-block-components-totals-item__value { font-size: 20px !important; font-weight: 800 !important; color: var(--st-ink); }
.stw .wc-block-components-order-summary-item__quantity { background: var(--st-accent) !important; color: #fff !important; border: none !important; box-shadow: none !important; }
.stw .wc-block-components-order-summary-item__image img { border-radius: 10px; }
.stw .wc-block-components-panel__button { font-weight: 700; color: var(--st-accent-deep); }

/* Boutons « Valider » / « Commander » */
.stw .wc-block-cart__submit-button, .stw .wc-block-components-checkout-place-order-button {
  width: 100%; min-height: 56px; font-size: 16px !important; font-weight: 800 !important;
}
.stw .wc-block-components-checkout-place-order-button::before {
  content: ""; width: 16px; height: 16px; margin-right: 4px;
  background: currentColor; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2'%3E%3Crect x='5' y='10.5' width='14' height='10' rx='2.2'/%3E%3Cpath d='M8 10.5V7.5a4 4 0 018 0v3'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2'%3E%3Crect x='5' y='10.5' width='14' height='10' rx='2.2'/%3E%3Cpath d='M8 10.5V7.5a4 4 0 018 0v3'/%3E%3C/svg%3E") center / contain no-repeat;
}
.stw .wc-block-components-checkout-return-to-cart-button { color: var(--st-accent-deep) !important; font-weight: 700; }
.stw .wc-block-checkout__terms { font-size: 14px; color: var(--st-muted); }
.stw .wc-block-checkout__actions { padding: 6px 0 0; }

/* Panier vide */
.stw .wp-block-woocommerce-empty-cart-block { text-align: center; padding: 30px 0 10px; }
.stw .wp-block-woocommerce-empty-cart-block .wc-block-cart__empty-cart__title { font-family: var(--st-serif); font-size: 38px; font-weight: 500; color: var(--st-ink); margin: 0 0 8px; }
/* L'icône « visage triste » de WooCommerce ne correspond pas au ton du site. */
.stw .wp-block-woocommerce-empty-cart-block .wc-block-cart__empty-cart__title::before { display: none !important; }
.stw .wp-block-woocommerce-empty-cart-block > .wp-block-separator { display: none; }
.stw .wp-block-woocommerce-empty-cart-block > h2:not(.wc-block-cart__empty-cart__title) { font-size: 30px; font-weight: 500; margin: 56px 0 26px; }

/* Produits proposés dans le panier vide (bloc « nouveautés ») */
.stw .wc-block-grid__products { display: grid !important; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 22px; margin: 0 !important; }
.stw .wc-block-grid .wc-block-grid__product {
  width: auto !important; max-width: none !important; flex: none !important; margin: 0 !important; padding: 0 0 20px !important;
  border: 1px solid var(--st-line) !important; border-radius: 16px; overflow: hidden; background: var(--st-card);
}
.stw .wc-block-grid__product-image { margin: 0 0 16px !important; }
.stw .wc-block-grid__product-image img { aspect-ratio: 1 / 1; object-fit: cover; }
.stw .wc-block-grid__product-title { font-family: var(--st-serif); font-size: 20px !important; font-weight: 600; color: var(--st-ink); padding: 0 16px; }
.stw .wc-block-grid__product-price { color: var(--st-ink); font-weight: 700; }
.stw .wc-block-grid__product .wc-block-grid__product-add-to-cart.wp-block-button .wp-block-button__link {
  padding: 10px 20px; border-radius: 100px; background: var(--st-accent); color: #fff; font-size: 14px; font-weight: 700;
}
.stw .wc-block-grid__product .wc-block-grid__product-add-to-cart.wp-block-button .wp-block-button__link:hover { background: var(--st-accent-deep); }

/* ---------- Commande reçue / paiement (gabarits classiques) ---------- */
:is(.woocommerce, .woocommerce-page) .stw ul.order_details {
  display: flex; flex-wrap: wrap; gap: 12px; margin: 0 0 36px; padding: 0; list-style: none;
}
:is(.woocommerce, .woocommerce-page) .stw ul.order_details::before, :is(.woocommerce, .woocommerce-page) .stw ul.order_details::after { display: none; }
:is(.woocommerce, .woocommerce-page) .stw ul.order_details li {
  float: none; margin: 0; padding: 16px 20px; border: 1px solid var(--st-line); border-radius: 14px; background: #fff;
  font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--st-muted-4);
}
:is(.woocommerce, .woocommerce-page) .stw ul.order_details li strong { display: block; margin-top: 6px; font-size: 16px; letter-spacing: 0; text-transform: none; color: var(--st-ink); }
:is(.woocommerce, .woocommerce-page) .stw .woocommerce-thankyou-order-received {
  margin: 0 0 26px; padding: 18px 22px; border-radius: 14px; background: #F3E9EE; color: var(--st-accent-darker); font-weight: 700;
}
:is(.woocommerce, .woocommerce-page) .stw table.shop_table {
  border: 1px solid var(--st-line); border-radius: 16px; border-collapse: separate; overflow: hidden; background: #fff; margin: 0 0 32px;
}
:is(.woocommerce, .woocommerce-page) .stw table.shop_table th, :is(.woocommerce, .woocommerce-page) .stw table.shop_table td { padding: 16px 20px; border-color: var(--st-line); }
:is(.woocommerce, .woocommerce-page) .stw table.shop_table thead th { font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--st-muted-4); }
:is(.woocommerce, .woocommerce-page) .stw table.shop_table tfoot tr:last-child th, :is(.woocommerce, .woocommerce-page) .stw table.shop_table tfoot tr:last-child td { font-size: 17px; color: var(--st-ink); }
:is(.woocommerce, .woocommerce-page) .stw .woocommerce-order-details__title, :is(.woocommerce, .woocommerce-page) .stw .woocommerce-column__title { font-size: 30px; font-weight: 500; margin: 0 0 18px; }
:is(.woocommerce, .woocommerce-page) .stw .woocommerce-customer-details address {
  padding: 20px 22px; border: 1px solid var(--st-line); border-radius: 16px; background: #fff; font-style: normal; line-height: 1.7;
}
:is(.woocommerce, .woocommerce-page) .stw #payment, .woocommerce-page .stw #payment { background: var(--st-card); border-radius: 16px; }

/* ---------- Mon compte ---------- */
.woocommerce-account .stw .woocommerce { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 48px; align-items: start; }
.woocommerce-account .stw .woocommerce::before, .woocommerce-account .stw .woocommerce::after { display: none; }
.woocommerce-account .stw .woocommerce-MyAccount-navigation, .woocommerce-account .stw .woocommerce-MyAccount-content { float: none; width: auto; }
.woocommerce-account .stw .woocommerce-MyAccount-navigation ul {
  list-style: none; margin: 0; padding: 10px; border: 1px solid var(--st-line); border-radius: 18px; background: var(--st-card);
}
.woocommerce-account .stw .woocommerce-MyAccount-navigation li a {
  display: block; padding: 12px 16px; border-radius: 12px; color: var(--st-text); font-weight: 700; font-size: 14.5px;
}
.woocommerce-account .stw .woocommerce-MyAccount-navigation li.is-active a, .woocommerce-account .stw .woocommerce-MyAccount-navigation li a:hover {
  background: #fff; color: var(--st-accent-deep); box-shadow: 0 10px 24px -18px rgba(80, 46, 90, 0.6);
}
.woocommerce-account .stw .woocommerce-MyAccount-content { font-size: 16px; line-height: 1.7; color: var(--st-muted-2); }
/* Connexion (non connecté) : une seule colonne centrée */
.woocommerce-account:not(.logged-in) .stw .woocommerce { display: block; max-width: 520px; margin: 0 auto; }
:is(.woocommerce, .woocommerce-page) .stw form.login, :is(.woocommerce, .woocommerce-page) .stw form.register, :is(.woocommerce, .woocommerce-page) .stw form.lost_reset_password {
  margin: 0; padding: 32px; border: 1px solid var(--st-line); border-radius: 18px; background: var(--st-card);
}
:is(.woocommerce, .woocommerce-page) .stw form.login + p, :is(.woocommerce, .woocommerce-page) .stw .woocommerce-LostPassword { margin-top: 16px; font-size: 14px; }
.woocommerce-account .stw h2 { font-size: 34px; font-weight: 500; margin: 0 0 20px; }

/* ---------- Page « La Boutique » ---------- */
.st-produits__notices { margin-bottom: 26px; }
.st-produit__btn { margin-top: 16px; align-self: flex-start; padding: 11px 20px; font-size: 14px; }
.st-produits__more { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 14px 28px; margin-top: 44px; }
.st-produits__cart { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: 15px; color: var(--st-accent-deep); }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  :is(.woocommerce, .woocommerce-page) .stw ul.products { grid-template-columns: repeat(2, 1fr); }
  :is(.woocommerce, .woocommerce-page) .stw div.product { grid-template-columns: 1fr; gap: 32px; }
  :is(.woocommerce, .woocommerce-page) .stw div.product div.summary { position: static; }
  :is(.woocommerce, .woocommerce-page) .stw div.product .woocommerce-tabs, :is(.woocommerce, .woocommerce-page) .stw div.product .related { margin-top: 40px; }
  .stw .wc-block-cart__sidebar, .stw .wc-block-checkout__sidebar { position: static !important; }
  .woocommerce-account .stw .woocommerce { grid-template-columns: 1fr; gap: 24px; }
  .stw .wc-block-grid__products { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 680px) {
  .stw__inner { padding: 36px 22px 72px; }
  .stp-hero--compact .stp-hero__inner { padding: 22px 22px 0; }
  .stp-hero--boutique .stp-hero__title { font-size: 36px; }
  :is(.woocommerce, .woocommerce-page) .stw ul.products { grid-template-columns: 1fr; }
  :is(.woocommerce, .woocommerce-page) .stw div.product .product_title { font-size: 34px; }
  :is(.woocommerce, .woocommerce-page) .stw div.product form.cart { padding: 16px; }
  :is(.woocommerce, .woocommerce-page) .stw div.product form.cart .button { min-width: 0; }
  .stw .wc-block-components-main { padding-right: 0 !important; }
  .stw .wc-block-checkout__main .wc-block-components-checkout-step { padding: 20px 18px 6px !important; }
  .stw .wc-block-cart__sidebar { padding: 20px 18px 12px !important; }
  :is(.woocommerce, .woocommerce-page) .stw form.login, :is(.woocommerce, .woocommerce-page) .stw form.register { padding: 22px; }
}
