/* ==========================================================================
   Panier et commande : la livraison offerte en vue, une 2ème paire dans la même pointure
   (GG_Marque_Ventes, chargé sur le panier et la commande, après boutique.css).

   Mêmes jetons que boutique.css (`--b-*`, posés sur `.gg-boutique`). Chaque règle
   de bouton est préfixée `.gg-boutique` et qualifiée par l'élément : le reset
   du thème peint tout `button` en rose, une classe seule ne suffit pas.
   ========================================================================== */

/* ---------- La jauge de livraison offerte ---------- */

.gg-boutique .gg-livraison {
	display: grid;
	gap: 10px;
	margin: 0 0 14px;
	padding: 14px 16px 16px;
	border: 1px solid var(--b-filet);
	border-radius: var(--b-rayon);
	background: var(--b-carte);
	box-shadow: var(--b-ombre);
}

.gg-boutique .gg-livraison__texte {
	display: flex;
	align-items: center;
	gap: 12px;
	margin: 0;
	color: var(--b-texte);
	font-size: 15px;
	line-height: 1.35;
}

.gg-boutique .gg-livraison__texte strong {
	color: var(--b-encre);
	font-weight: 700;
	font-variant-numeric: tabular-nums;
}

.gg-boutique .gg-livraison__picto {
	flex: 0 0 38px;
	box-sizing: border-box;
	width: 38px;
	height: 38px;
	padding: 8px;
	border-radius: 50%;
	background: var(--b-vert-pale);
	fill: none;
	stroke: var(--b-vert);
	stroke-width: 1.7;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.gg-boutique .gg-livraison__jauge {
	position: relative;
	height: 8px;
	border-radius: 999px;
	background: var(--b-filet);
	overflow: hidden;
}

.gg-boutique .gg-livraison__jauge > span {
	display: block;
	width: var(--part, 0%);
	height: 100%;
	border-radius: inherit;
	background: var(--b-vert);
	transition: width 0.5s ease;
}

.gg-boutique .gg-livraison--atteinte {
	border-color: var(--b-filet-fort);
	background: var(--b-vert-pale);
}

.gg-boutique .gg-livraison--atteinte .gg-livraison__picto {
	background: var(--b-vert);
	stroke: #fff;
	stroke-width: 2.4;
}

.gg-boutique .gg-livraison--atteinte .gg-livraison__texte {
	color: var(--b-vert-profond);
}

/* ---------- La rangée « 2ème paire » ---------- */

.gg-boutique .gg-paire {
	margin: 6px 0 22px;
	/* Le lien « Ajouter une 2ème paire » de la commande y mène : la rangée ne se cache pas sous l'en-tête. */
	scroll-margin-top: 90px;
}

.gg-boutique .gg-paire__titre {
	margin: 0 0 4px;
	color: var(--b-encre);
	font-size: 19px;
	font-weight: 700;
	line-height: 1.3;
	letter-spacing: 0;
	text-transform: none;
}

.gg-boutique .gg-paire__sous {
	margin: 0 0 14px;
	color: var(--b-gris);
	font-size: 14.5px;
	line-height: 1.45;
}

.gg-boutique .gg-paire__liste {
	display: flex;
	flex-direction: column;
	gap: 10px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.gg-boutique .gg-carte-paire {
	display: grid;
	grid-template-columns: 84px minmax(0, 1fr);
	gap: 10px 14px;
	align-items: start;
	margin: 0;
	padding: 14px;
	border: 1px solid var(--b-filet);
	border-radius: var(--b-rayon);
	background: var(--b-carte);
}

.gg-boutique .gg-carte-paire__photo {
	display: block;
	width: 84px;
	height: 84px;
	border-radius: var(--b-rayon-petit);
	background: var(--b-fond);
	overflow: hidden;
}

.gg-boutique .gg-carte-paire__photo img {
	display: block;
	width: 100%;
	height: 100%;
	max-width: none;
	object-fit: cover;
}

.gg-boutique .gg-carte-paire__infos {
	min-width: 0;
}

.gg-boutique .gg-carte-paire__etiquette {
	display: inline-block;
	margin: 0 0 5px;
	padding: 2px 9px;
	border-radius: 999px;
	background: var(--b-or-pale);
	/* L'or sur son fond pâle n'atteint que 3,8:1 : le vert profond passe largement les 4,5:1. */
	color: var(--b-vert-profond);
	font-size: 12px;
	font-weight: 600;
	line-height: 1.5;
}

.gg-boutique a.gg-carte-paire__lien {
	color: inherit;
	text-decoration: none;
}

.gg-boutique .gg-carte-paire__nom a.gg-carte-paire__lien:hover {
	color: var(--b-vert-fonce);
	text-decoration: underline;
}

.gg-boutique .gg-carte-paire__nom {
	margin: 0;
	color: var(--b-encre);
	font-size: 15.5px;
	font-weight: 600;
	line-height: 1.3;
}

.gg-boutique .gg-carte-paire__detail {
	margin: 3px 0 0;
	color: var(--b-gris);
	font-size: 13.5px;
	line-height: 1.4;
}

/* Les coloris : des pastilles rondes, la photo du gant dans ce coloris. */
.gg-boutique .gg-carte-paire__coloris {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin: 9px 0 0;
	padding: 0;
	list-style: none;
}

.gg-boutique .gg-carte-paire__coloris li {
	margin: 0;
}

.gg-boutique .gg-paire button.gg-pastille {
	display: block;
	box-sizing: border-box;
	width: 36px;
	height: 36px;
	min-height: 0;
	padding: 2px;
	border: 2px solid transparent;
	border-radius: 50%;
	background: var(--b-carte);
	box-shadow: 0 0 0 1px var(--b-filet-fort);
	color: var(--b-texte);
	font-size: 11px;
	font-weight: 600;
	line-height: 1;
	cursor: pointer;
	overflow: hidden;
	transition: border-color 0.14s ease, box-shadow 0.14s ease;
}

.gg-boutique .gg-paire button.gg-pastille:hover {
	background: var(--b-carte);
	box-shadow: 0 0 0 1px var(--b-vert);
	color: var(--b-texte);
}

.gg-boutique .gg-paire button.gg-pastille[aria-pressed="true"] {
	border-color: var(--b-vert);
	box-shadow: 0 0 0 1px var(--b-vert);
}

/* Au doigt, la cible fait 44 px. */
@media (pointer: coarse) {
	.gg-boutique .gg-paire button.gg-pastille {
		width: 44px;
		height: 44px;
	}
}

.gg-boutique .gg-paire button.gg-pastille:focus-visible {
	outline: 2px solid var(--b-vert-profond);
	outline-offset: 2px;
}

.gg-boutique .gg-paire button.gg-pastille img {
	display: block;
	width: 100%;
	height: 100%;
	max-width: none;
	border-radius: 50%;
	object-fit: cover;
}

.gg-boutique .gg-carte-paire__coloris .gg-pastille-plus {
	display: flex;
	align-items: center;
	padding: 0 4px;
	color: var(--b-gris);
	font-size: 13px;
}

/* Prix et bouton : sous les infos sur téléphone, à droite sur grand écran. */
.gg-boutique .gg-carte-paire__achat {
	grid-column: 1 / -1;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px 14px;
}

.gg-boutique .gg-carte-paire__prix {
	margin: 0;
	color: var(--b-encre);
	font-size: 17px;
	font-weight: 700;
	font-variant-numeric: tabular-nums;
}

.gg-boutique .gg-carte-paire__prix small {
	display: block;
	margin-top: 2px;
	color: var(--b-vert);
	font-size: 12.5px;
	font-weight: 600;
	line-height: 1.3;
}

.gg-boutique .gg-paire a.gg-carte-paire__ajout {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	min-height: 44px;
	padding: 10px 18px;
	border: 1px solid var(--b-vert);
	border-radius: var(--b-rayon-petit);
	background: var(--b-carte);
	color: var(--b-vert);
	font-size: 14.5px;
	font-weight: 600;
	line-height: 1.2;
	text-decoration: none;
	cursor: pointer;
	transition: background-color 0.16s ease, color 0.16s ease;
}

.gg-boutique .gg-paire a.gg-carte-paire__ajout:hover {
	background: var(--b-vert);
	color: #fff;
}

.gg-boutique .gg-paire a.gg-carte-paire__ajout:focus-visible {
	outline: 2px solid var(--b-vert-profond);
	outline-offset: 2px;
}

/* Un clic vaut un ajout : le lien se grise le temps du rechargement, pas de double clic. */
.gg-boutique .gg-paire a.gg-carte-paire__ajout[aria-busy="true"] {
	border-color: var(--b-filet-fort);
	background: var(--b-fond);
	color: var(--b-gris);
	pointer-events: none;
}

@media (min-width: 640px) {
	.gg-boutique .gg-carte-paire {
		grid-template-columns: 96px minmax(0, 1fr) auto;
		align-items: center;
		padding: 14px 16px;
	}

	.gg-boutique .gg-carte-paire__photo {
		width: 96px;
		height: 96px;
	}

	.gg-boutique .gg-carte-paire__achat {
		grid-column: auto;
		flex-direction: column;
		align-items: flex-end;
		justify-content: center;
		gap: 8px;
		text-align: right;
	}
}

/* ---------- Sous le récapitulatif : livraison, retrait, paiement, avis ---------- */

.gg-boutique .gg-garanties {
	margin: 18px 0 0;
}

.gg-boutique .gg-garanties .gg-assurances {
	display: flex;
	flex-direction: column;
	gap: 12px;
	margin: 0;
	padding: 16px 0;
	border-top: 1px solid var(--b-filet);
	border-bottom: 1px solid var(--b-filet);
	list-style: none;
}

.gg-boutique .gg-garanties .gg-assurances li {
	display: flex;
	align-items: center;
	gap: 12px;
	margin: 0;
	color: var(--b-gris);
	font-size: 13.5px;
	line-height: 1.35;
}

.gg-boutique .gg-garanties .gg-assurances svg {
	flex: 0 0 26px;
	width: 26px;
	height: 26px;
	fill: none;
	stroke: var(--b-vert);
	stroke-width: 1.5;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.gg-boutique .gg-garanties .gg-assurances b {
	display: block;
	color: var(--b-encre);
	font-size: 14px;
	font-weight: 700;
}

.gg-boutique .gg-garanties__avis {
	margin: 14px 0 0;
	color: var(--b-gris);
	font-size: 13.5px;
	text-align: center;
}

.gg-boutique .gg-garanties__etoiles {
	color: var(--b-or);
	letter-spacing: 1px;
}

.gg-boutique .gg-garanties__avis strong {
	color: var(--b-encre);
}

/* ---------- Mise à jour automatique : le bouton n'a plus lieu d'être quand le script tourne ---------- */

/* Le bouton seul : la cellule garde le code promo quand la boutique en publie un. Sans code, elle est vide. */
html.gg-ventes-js .gg-boutique .woocommerce table.cart button[name="update_cart"] {
	display: none;
}

html.gg-ventes-js .gg-boutique .woocommerce table.cart td.actions:not(:has(.coupon)) {
	display: none;
}

/* ---------- Commande : la photo du gant dans le récapitulatif, le rappel de la livraison offerte ---------- */

.gg-boutique .woocommerce table.woocommerce-checkout-review-order-table td.product-name .gg-ligne__photo {
	float: left;
	width: 56px;
	height: 56px;
	margin: 0 12px 4px 0;
	border-radius: var(--b-rayon-petit);
	background: var(--b-fond);
	overflow: hidden;
}

.gg-boutique .woocommerce table.woocommerce-checkout-review-order-table td.product-name .gg-ligne__photo img {
	display: block;
	width: 100%;
	height: 100%;
	max-width: none;
	margin: 0;
	object-fit: cover;
}

/* La cellule contient la photo flottante : elle ne se referme qu'après elle. */
.gg-boutique .woocommerce table.woocommerce-checkout-review-order-table td.product-name::after {
	content: "";
	display: table;
	clear: both;
}

.gg-boutique .woocommerce table.woocommerce-checkout-review-order-table tfoot tr.gg-rappel-ligne td {
	padding: 4px 0 0;
	border-bottom: 0;
	text-align: left;
	font-weight: 400;
}

.gg-boutique .gg-rappel {
	margin: 0;
	padding: 10px 14px;
	border-radius: var(--b-rayon-petit);
	background: var(--b-vert-pale);
	color: var(--b-vert-profond);
	font-size: 14px;
	line-height: 1.4;
}

.gg-boutique .gg-rappel strong {
	font-weight: 700;
	font-variant-numeric: tabular-nums;
}

.gg-boutique .gg-rappel a {
	color: inherit;
	font-weight: 600;
	text-decoration: underline;
	text-underline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
	.gg-boutique .gg-livraison__jauge > span {
		transition: none;
	}
}
