/* Cart, checkout and order confirmation: WooCommerce's cart and checkout blocks in the prototype's
   language (the /commande/ page, scripts/generate-pages.mjs and page-system.css « checkout », ddf9b78;
   CP-05 calmer and more functional than editorial sections). Numbered steps between thin Noir lines,
   headings in the display serif, square fields with a Noir border, no boxed panels (DIR-08), the
   primary action as the Bronze button with its arrow, errors in Noir with a word, never a colour
   (CL-09). Only WooCommerce's own class names are targeted; its markup is unchanged. */
.shop-page .shop-intro { margin-bottom: var(--within-gap); }
.shop-page .shop-intro h1 { font-size: clamp(3.4rem, 6.4vw, 6.5rem); }
.shop-page .shop-block { margin: 0; }
.shop-page .wp-block-woocommerce-cart, .shop-page .wp-block-woocommerce-checkout { margin: 0; padding: 0; }

/* Fields: square, Noir border, the label inside (WooCommerce's floating label). */
.shop-page .wc-block-components-text-input input,
.shop-page .wc-block-components-select .wc-blocks-components-select__select,
.shop-page .wc-block-components-textarea,
.shop-page .wc-block-components-combobox .wc-block-components-combobox-control input { min-height: 50px; border: 1px solid var(--color-text) !important; border-radius: 0 !important; background: var(--color-surface); color: var(--color-text); box-shadow: none !important; font-family: var(--font-body); }
.shop-page .wc-block-components-text-input input:focus,
.shop-page .wc-block-components-select .wc-blocks-components-select__select:focus { outline: 3px solid var(--color-focus); outline-offset: 2px; }
.shop-page .wc-block-components-text-input label, .shop-page .wc-block-components-select label { color: var(--color-text-muted); font-family: var(--font-body); }
.shop-page .wc-block-components-checkbox .wc-block-components-checkbox__input[type="checkbox"] { border: 1px solid var(--color-text); border-radius: 0; }
.shop-page .wc-block-components-validation-error { color: var(--color-text); font-weight: 600; }
/* « Erreur : » in front of the message, on the same line; WooCommerce's red labels and icon go (CL-09). */
.shop-page .wc-block-components-validation-error svg { display: none; }
.shop-page .wc-block-components-validation-error > p::before { content: "Erreur : "; font-weight: 600; }
.shop-page .has-error label, .shop-page .has-error input::placeholder { color: var(--color-text) !important; }
.shop-page .has-error input, .shop-page .has-error select { border-width: 2px !important; }

/* Checkout steps: « 1. Vos coordonnées », « 2. Livraison », « 3. Paiement » — a thin Noir line above
   each, the number counted by CSS. */
.shop-page .wc-block-checkout__form { counter-reset: lea-step; }
.shop-page .wc-block-components-checkout-step { margin: 0; padding: 26px 0; border-top: 1px solid var(--color-text); counter-increment: lea-step; }
.shop-page .wc-block-components-checkout-step::after { display: none; }
.shop-page .wc-block-components-checkout-step__heading { margin: 0 0 20px; }
.shop-page .wc-block-components-checkout-step__title { margin: 0; font-family: var(--font-body); font-size: 2rem; font-weight: 600; line-height: 1.1; }
.shop-page .wc-block-components-checkout-step__title::before { content: counter(lea-step) ". "; }
.shop-page .wc-block-components-checkout-step__container, .shop-page .wc-block-components-checkout-step__content { padding: 0; }
.shop-page .wc-block-components-checkout-step__container::after { display: none; }
.shop-page .wc-block-components-checkout-step--with-step-number .wc-block-components-checkout-step__title::before { content: none; }
.shop-page .wc-block-checkout__order-notes, .shop-page .wc-block-checkout__terms { padding: 22px 0; border-top: 1px solid var(--color-text); }
.shop-page .wc-block-checkout__actions { padding-top: 22px; }
.shop-page .wc-block-checkout__terms { font-size: .92rem; }

/* Notices: theme.css (the same on every page). */

/* Buttons: the primary action is the Bronze pill with its arrow; secondary actions are text links. */
.shop-page :is(.wc-block-components-checkout-place-order-button, .wc-block-cart__submit-button) { white-space: nowrap; min-height: 52px; padding: .72rem 1.55rem; border: 0; border-radius: var(--radius-pill); background: var(--color-accent); color: var(--color-accent-text); font-family: var(--font-body); font-size: 19px; font-weight: 700; text-decoration: none; }
.shop-page :is(.wc-block-components-checkout-place-order-button, .wc-block-cart__submit-button):hover { background: var(--color-text); color: var(--color-text-inverse); }
.shop-page :is(.wc-block-components-checkout-place-order-button, .wc-block-cart__submit-button) .wc-block-components-button__text { display: inline-flex; align-items: center; }
.shop-page .wc-block-components-checkout-return-to-cart-button { color: var(--color-text); font-weight: 500; text-decoration: none; border-bottom: 1px solid var(--color-accent); }
.shop-page .wc-block-components-checkout-return-to-cart-button svg { display: none; }
.shop-page .wc-block-components-checkout-return-to-cart-button { padding-left: 0; }
.shop-page .wc-block-components-checkout-return-to-cart-button::before { content: "← "; }

/* Order summary (checkout) and cart totals: « Votre commande — Récapitulatif », thin lines, no box. */
.shop-page .wc-block-checkout__sidebar .wc-block-components-checkout-order-summary__content,
.shop-page .wp-block-woocommerce-checkout-order-summary-block { border: 0; border-radius: 0; }
.shop-page .wp-block-woocommerce-checkout-order-summary-block .wc-block-components-checkout-order-summary__title { display: block; margin: 0 0 12px; padding: 0; }
.shop-page .wc-block-components-checkout-order-summary__title-text,
.shop-page .wc-block-cart__totals-title { margin: 0 0 12px !important; padding: 0 !important; font-family: var(--font-body) !important; font-size: clamp(2.2rem, 3.4vw, 3rem) !important; font-weight: 600 !important; line-height: 1.05; letter-spacing: 0; text-transform: none !important; }
.shop-page .wc-block-components-checkout-order-summary__title::before,
.shop-page .wc-block-cart__totals-title::before { content: "Votre commande"; display: block; margin-bottom: 12px; font-family: var(--font-body); font-size: .86rem; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; }
.shop-page .wc-block-components-order-summary, .shop-page .wc-block-components-totals-wrapper, .shop-page .wc-block-components-panel, .shop-page .wc-block-components-totals-item, .shop-page .wc-block-components-totals-coupon { padding-inline: 0 !important; }
.shop-page .wc-block-components-sidebar { padding-left: 54px; }
@media (max-width: 699px) { .shop-page .wc-block-components-sidebar { padding-left: 0; } }
.shop-page .wc-block-components-totals-footer-item .wc-block-components-totals-item__label,
.shop-page .wc-block-components-totals-footer-item .wc-block-components-totals-item__value { font-weight: 600; }
.shop-page .wc-block-components-order-summary-item__quantity { border-color: var(--color-text); background: var(--color-text); color: var(--color-text-inverse); box-shadow: none; }
.shop-page .wc-block-components-product-metadata__description { display: none; }

/* Cart items: rows between thin Bronze lines, the cover contained (IM-05). */
.shop-page .wc-block-cart-items { border-bottom: 1px solid var(--color-accent); }
.shop-page .wc-block-cart-items__header { font-size: .78rem; letter-spacing: .14em; }
.shop-page .wc-block-cart-items__row { border-top: 1px solid var(--color-accent); }
.shop-page .wc-block-cart-item__image img { object-fit: contain; }
.shop-page .wc-block-components-checkout-order-summary__title-text { padding: 0 !important; text-align: left; }
.shop-page .wc-block-cart-item__product .wc-block-components-product-name, .shop-page .wc-block-components-product-name { font-family: var(--font-body); font-size: 1.35rem !important; font-weight: 600; line-height: 1.15; text-decoration: none; }
.shop-page .wc-block-components-quantity-selector { border: 1px solid var(--color-text); border-radius: var(--radius-pill); }
.shop-page .wc-block-components-quantity-selector::after { display: none; }
.shop-page .wc-block-cart-item__remove-link { color: var(--color-text); }

/* Empty cart (owner review 1): the house's empty state (inc/woocommerce.php) between thin lines, then
   « Dernières parutions » with the site's book cards, shown only once the cart block has rendered
   and is empty (WooCommerce removes « is-loading » when it has read the cart). */
.shop-page .lea-empty-cart { display: grid; justify-items: start; gap: 18px; max-width: 720px; padding: 30px 0 34px; border-top: 1px solid var(--color-text); }
.shop-page .lea-empty-cart > * { margin: 0; }
.shop-page .lea-empty-cart__title { font-family: var(--font-body); font-size: clamp(2.25rem, 4vw, 3.4rem); font-weight: 600; line-height: 1.05; }
.shop-page .lea-empty-cart p { font-size: 1.28rem; line-height: 1.55; }
.shop-page .lea-empty-cart .wp-block-button { margin-top: 6px; }
.shop-page--cart:not(:has(.wp-block-woocommerce-cart:not(.is-loading) > .wp-block-woocommerce-empty-cart-block)) .shop-cart-books { display: none; }
.shop-page .shop-cart-books { margin-top: var(--within-gap); }
.shop-cart-books__more { margin-top: var(--heading-gap) !important; }

/* Order confirmation: ✓, « Commande confirmée », « Merci pour votre commande. » */
.shop-page--confirmation .shop-confirmation { display: grid; justify-items: start; margin-bottom: var(--within-gap); }
.shop-page--confirmation .shop-confirmation > * { margin: 0; }
.shop-confirmation__mark { display: grid; place-items: center; width: 56px; height: 56px; margin-bottom: 24px !important; border: 1px solid var(--color-text); border-radius: 50%; font-size: 1.6rem; line-height: 1; }
.shop-page--confirmation .shop-confirmation h1 { font-size: clamp(3rem, 5.4vw, 4.6rem); line-height: 1.02; }
.shop-order { max-width: 820px; }
.shop-order > * { margin: 0 0 var(--heading-gap); }
.shop-order__heading { margin: 0 0 16px; padding-top: 22px; border-top: 1px solid var(--color-text); font-size: 2rem; }
.shop-order__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 28px; margin-top: var(--within-gap) !important; }
.shop-order__actions > * { margin: 0; }

@media (max-width: 900px) {
  .shop-page .wc-block-components-checkout-step__title { font-size: 1.7rem; }
}
/* Phones: WooCommerce repeats the order summary inside the form; no box there either (DIR-08). */
.shop-page .checkout-order-summary-block-fill, .shop-page .wc-block-components-checkout-order-summary__content, .shop-page .wc-block-checkout__main .wp-block-woocommerce-checkout-order-summary-block { border: 0 !important; border-radius: 0 !important; }
/* Confirmation: one H1 per page (TY-02): the theme's « Merci pour votre commande. » replaces the
   status block's own heading; the order table as thin lines, no box. */
.shop-order .wc-block-order-confirmation-status h1 { display: none; }
.shop-order .wc-block-order-confirmation-status { margin-top: 0; }
.shop-order .wc-block-order-confirmation-totals table { border: 0; border-collapse: collapse; }
.shop-order .wc-block-order-confirmation-totals :is(th, td) { padding: 14px 0; border: 0; border-bottom: 1px solid var(--color-accent); }
.shop-order .wc-block-order-confirmation-totals thead :is(th, td) { font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; }
