/**
 * Bocolis — panier et page de commande [BOC-025] (ex-snippets 25, 38, 60).
 * Chargé seulement sur le panier et la page de commande.
 */

/* Panier : encart Sous-total collant au défilement */
@media (min-width: 1025px) {
	.woocommerce-cart .e-cart__column-end,
	.woocommerce-cart .cart-collaterals { position: sticky; top: 170px; align-self: flex-start; }
}

/* Panier : page masquée le temps de revenir à la même hauteur (voir panier.js) */
html.bocolis-restaure { scroll-behavior: auto !important; }
html.bocolis-restaure body { opacity: 0; }

/* Messages d'information : l'icône WooCommerce n'est pas chargée sur le site (carré vide), on la retire */
.woocommerce-cart .woocommerce-info::before,
.woocommerce-checkout .woocommerce-info::before { content: none; }
.woocommerce-cart .woocommerce-info,
.woocommerce-checkout .woocommerce-info { padding-left: 24px; }

/* « Il vous manque … € » : le texte reste une seule phrase, le montant dans la ligne */
.bocolis-minimum__texte { flex: 1 1 auto; }
.bocolis-minimum .woocommerce-Price-amount { display: inline-block; white-space: nowrap; margin: 0 2px; }

/* Page de commande : chaque mode de livraison est une carte */
.woocommerce ul#shipping_method{margin:0;padding:0}
.woocommerce ul#shipping_method li{position:relative;margin:0 0 8px;padding:0;background:#fff;border:1px solid #dde7da;border-radius:12px;line-height:1.3;transition:border-color .15s,background-color .15s,box-shadow .15s}
.woocommerce ul#shipping_method li:hover{border-color:#a9cfa2}
.woocommerce ul#shipping_method li:has(input:checked){border-color:#108501;background:#f2f9f0;box-shadow:0 0 0 1px #108501}
.woocommerce ul#shipping_method li input.shipping_method{position:absolute;left:14px;top:50%;transform:translateY(-50%);margin:0;width:18px;height:18px;accent-color:#108501;cursor:pointer}
.woocommerce ul#shipping_method li label{display:block;padding:11px 14px 11px 44px;margin:0;cursor:pointer;color:#1d2b1d;font-weight:400}
.bocolis-mode{display:flex;flex-direction:column;gap:2px}
.bocolis-mode__type{font-size:11px;font-weight:700;letter-spacing:.07em;text-transform:uppercase;color:#108501}
.bocolis-mode__heure{font-size:17px;font-weight:700;color:#1d2b1d}
.bocolis-mode__lieu{font-size:13px;color:#667366}
.woocommerce ul#shipping_method li:has(.bocolis-jour){margin-top:38px;padding-top:0}
.woocommerce ul#shipping_method li:first-child:has(.bocolis-jour){margin-top:30px}
.woocommerce ul#shipping_method .bocolis-jour{position:absolute;top:-27px;left:0;right:0;display:flex;align-items:center;gap:10px;font-size:12.5px;font-weight:800;letter-spacing:.12em;color:#0b5a01}
.woocommerce ul#shipping_method .bocolis-jour::after{content:"";flex:1;height:1px;background:#dde7da}
@media (max-width:767px){
.woocommerce-checkout-review-order-table,.woocommerce-checkout-review-order-table thead,.woocommerce-checkout-review-order-table tbody,.woocommerce-checkout-review-order-table tfoot{display:block;width:100%}
.woocommerce-checkout-review-order-table tr{display:flex;width:100%}
.woocommerce-checkout-review-order-table tr>*{flex:1 1 50%;display:block}
.woocommerce-checkout-review-order-table tr.woocommerce-shipping-totals{flex-wrap:wrap}
.woocommerce-checkout-review-order-table tr.woocommerce-shipping-totals>*{flex:1 1 100%;width:100%;max-width:none!important;padding-right:0}
.woocommerce-checkout-review-order-table tr.woocommerce-shipping-totals th{padding-bottom:0}
}

/* [BOC-033] Encart « Proposer un nouveau site » : icône du site à la place de l'emoji. */
.bocolis-nouveau-site-box p::before {
	content: "";
	display: inline-block;
	width: 16px;
	height: 16px;
	margin: 0 7px -2px 0;
	background: #108501;
	-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' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 21V5a1 1 0 0 1 1-1h9a1 1 0 0 1 1 1v16M15 10h4a1 1 0 0 1 1 1v10M2 21h20M8 8h3M8 12h3M8 16h3'/%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' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 21V5a1 1 0 0 1 1-1h9a1 1 0 0 1 1 1v16M15 10h4a1 1 0 0 1 1 1v10M2 21h20M8 8h3M8 12h3M8 16h3'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* [BOC-098] Adresse hors zone de livraison à domicile */
.bocolis-hors-zone-ligne td,
.bocolis-hors-zone-ligne:hover td { padding: 0 0 14px !important; border: 0 !important; background: none !important; }
.woocommerce .bocolis-hors-zone,
.bocolis-hors-zone {
	margin: 0 !important; padding: 12px 14px !important; border: 1px solid #DCEAD7 !important; border-radius: 12px;
	background: #fff !important; color: #24301F !important; font-size: 14px; line-height: 1.45; text-align: left;
}
.bocolis-hors-zone::before { display: none !important; }
.bocolis-hors-zone a { color: #108501 !important; font-weight: 600; text-decoration: underline; }
