/**
 * TexPrint Elementor Widgets — Product Card.
 * Design épuré, tokens pour couleurs (Elementor). Animation hover sur les cartes uniquement.
 */

/* ==========================================================================
   Product Card
   ========================================================================== */
.txp-pcard {
	--c-primary: var(--c-primary, var(--e-global-color-primary, #1a365d));
	--c-text: var(--c-text, var(--e-global-color-text, #0f172a));
	--c-accent: var(--c-accent, var(--e-global-color-accent, #d97706));
	--c-bg: var(--c-bg, #ffffff);
	--c-border: var(--c-border, #e2e8f0);
	box-sizing: border-box;
}

.txp-pcard *,
.txp-pcard *::before,
.txp-pcard *::after {
	box-sizing: inherit;
}

/* Toolbar tri : aligné à droite, au-dessus de la grille */
.txp-pcard__toolbar {
	display: flex;
	justify-content: flex-end;
	align-items: center;
	margin-bottom: 1.25rem;
	width: 100%;
}
.txp-pcard__sort-form {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	margin-left: auto;
	flex-shrink: 0;
	flex-wrap: nowrap;
}
.txp-pcard__sort-label {
	font-size: 0.9rem;
	color: var(--c-text);
	white-space: nowrap;
	flex-shrink: 0;
}
.txp-pcard__sort-select {
	display: inline-flex;
	align-items: center;
	min-height: 2.25rem;
	min-width: 220px;
	padding: 0 2rem 0 0.75rem;
	font-size: 0.9rem;
	font-family: inherit;
	color: var(--c-text);
	background: var(--c-bg);
	border: 1px solid var(--c-border);
	border-radius: 6px;
	cursor: pointer;
}
.txp-pcard__sort-select:hover,
.txp-pcard__sort-select:focus {
	border-color: var(--c-primary);
	outline: none;
}

/* Grille : gap large, pas de conteneur visible */
.txp-pcard__inner {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
	gap: 2.5rem;
}

/* Responsive : tablette 3 col, mobile 2 col */
@media (min-width: 768px) and (max-width: 1024px) {
	.txp-pcard__inner {
		grid-template-columns: repeat(3, 1fr);
	}
}

@media (max-width: 767px) {
	.txp-pcard__inner {
		grid-template-columns: repeat(2, 1fr);
		gap: 1.5rem;
	}
}

/* Carte : container (fond, bordure, radius pilotés par Elementor) + animation hover (spécificité élevée pour passer devant les styles Elementor) */
.txp-pcard.txp-pcard--grid .txp-pcard__card {
	display: flex;
	flex-direction: column;
	width: 100%;
	min-width: 0;
	overflow: hidden;
	background-color: var(--c-bg);
	border: 1px solid var(--c-border);
	transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.2s ease !important;
}
.txp-pcard.txp-pcard--grid .txp-pcard__card:hover {
	transform: translateY(-4px) !important;
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08), 0 2px 8px rgba(0, 0, 0, 0.04) !important;
	border-color: var(--c-border);
}
.txp-pcard.txp-pcard--grid .txp-pcard__card:active {
	transform: translateY(-2px) !important;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06) !important;
}
@media (prefers-reduced-motion: reduce) {
	.txp-pcard.txp-pcard--grid .txp-pcard__card {
		transition: none;
	}
	.txp-pcard.txp-pcard--grid .txp-pcard__card:hover,
	.txp-pcard.txp-pcard--grid .txp-pcard__card:active {
		transform: none;
	}
}

/* Zone image : 1:1 garanti via padding-bottom (insensible aux dimensions intrinsèques de l’image) */
.txp-pcard__image-wrap {
	position: relative;
	width: 100%;
	height: 0;
	padding-bottom: 100%; /* hauteur = 100% de la largeur → carré */
	background-color: #ffffff;
	overflow: hidden;
	flex-shrink: 0;
}

.txp-pcard__image-link {
	position: absolute;
	top: 0;
	left: 0;
	display: block;
	width: 100%;
	height: 100%;
	background-color: #ffffff;
}

.txp-pcard__img {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
	display: block;
	background-color: #ffffff;
	/* Zoom léger pour garantir couverture totale (évite barres blanches sur ~20 % des images) */
	transform: scale(1.08);
	transform-origin: center;
}

/* Images SOLO : scale 100% + contain (image entière visible, sans crop) */
.txp-pcard__card--solo .txp-pcard__img {
	object-fit: contain;
	object-position: center;
	transform: scale(1);
	transform-origin: center;
}

/* Badges : empilés en vertical (couleurs, tailles, stock) — fond blanc, bordure grise */
.txp-pcard__badges {
	position: absolute;
	top: 10px;
	left: 10px;
	z-index: 1;
	display: flex;
	flex-direction: column;
	flex-wrap: nowrap;
	justify-content: flex-start;
	align-items: flex-start;
	gap: 2px;
}

.txp-pcard__badge.txp-pcard__badge-pill {
	display: flex;
	align-items: center;
	gap: 6px;
	font-size: 12px;
	line-height: 1.2;
	white-space: nowrap;
	background-color: #fff;
	border: 1px solid var(--c-border);
	border-radius: 999px;
	padding: 5px 10px;
	color: var(--c-text);
}

.txp-pcard__badge-icon {
	display: inline-flex;
	flex-shrink: 0;
	color: currentColor;
	opacity: 0.85;
}

.txp-pcard__badge-svg {
	width: 14px;
	height: 14px;
}

/* Stock : texte vert, icône coche verte */
.txp-pcard__badge--stock .txp-pcard__badge-text,
.txp-pcard__badge--stock.txp-pcard__badge-pill {
	color: #15803d;
}

.txp-pcard__badge--stock .txp-pcard__badge-icon {
	opacity: 1;
	color: #15803d;
}

/* Rupture de stock : texte rouge, icône X */
.txp-pcard__badge--nostock .txp-pcard__badge-text,
.txp-pcard__badge--nostock.txp-pcard__badge-pill {
	color: #b91c1c;
}

.txp-pcard__badge--nostock .txp-pcard__badge-icon {
	opacity: 1;
	color: #b91c1c;
}

/* Badges mobile : taille réduite pour ne pas masquer l'image produit */
@media (max-width: 767px) {
	.txp-pcard__badges {
		top: 4px;
		left: 4px;
		gap: 2px;
	}
	.txp-pcard__badge.txp-pcard__badge-pill {
		font-size: 8px;
		line-height: 1.1;
		padding: 2px 4px;
		gap: 2px;
	}
	.txp-pcard__badge-svg {
		width: 8px;
		height: 8px;
	}
}

/* Zone détails : fond dédié (couleur changeable dans Elementor), aligné à gauche */
.txp-pcard__body {
	display: flex;
	flex-direction: column;
	flex-grow: 1;
	padding: 14px 16px;
	text-align: left;
	gap: 0.35rem;
	background-color: var(--c-bg);
}

/* Titre : :where() = spécificité 0 pour que la typo Elementor (1+ classes) override */
:where(.txp-pcard .txp-pcard__title) {
	margin: 0;
	font-size: 1.5rem;
	font-weight: 800;
	line-height: 1.3;
	text-transform: uppercase;
	color: var(--c-text);
	text-align: left;
}

:where(.txp-pcard .txp-pcard__title) a {
	text-decoration: none;
	color: inherit;
}

:where(.txp-pcard .txp-pcard__title) a:hover {
	opacity: 0.85;
}

/* Référence (SKU) : taille minimale lisible, gris très clair */
.txp-pcard__ref {
	font-size: 10px;
	line-height: 1.3;
	color: var(--c-text);
	opacity: 0.5;
	text-align: left;
}

/* Footer : prix au-dessus, bouton en dessous (pleine largeur), ancré en bas */
.txp-pcard__footer {
	display: flex;
	flex-direction: column;
	align-items: stretch;
	gap: 1rem;
	margin-top: auto;
	width: 100%;
}

/* Prix : poids normal, valeur en gras (Woo met le montant dans bdi) */
.txp-pcard__price {
	font-weight: 400;
	text-align: left;
	flex-shrink: 0;
}

.txp-pcard__price bdi,
.txp-pcard__price .amount {
	font-weight: 700;
}

/* Bouton "Voir le produit" : pleine largeur du footer */
.txp-pcard .txp-pcard__btn {
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	min-width: 0;
	padding: 12px 16px;
	text-align: left;
	text-decoration: none;
	border: none;
	cursor: pointer;
	gap: 10px;
	background-color: var(--c-primary);
	color: #fff;
	font-weight: 500;
}

.txp-pcard .txp-pcard__btn:hover {
	opacity: 0.92;
}

.txp-pcard__btn-icon {
	display: inline-flex;
	flex-shrink: 0;
}

.txp-pcard__cart-svg {
	width: 20px;
	height: 20px;
}

/* Header tri + pagination : styles isolés, n’affectent pas .txp-pcard__card */
.txp-pcard .txp-pcard__header {
	display: flex;
	justify-content: flex-end;
	align-items: center;
	margin-bottom: 1.5rem;
}

.txp-pcard .txp-pcard__spacer {
	flex: 1;
}

.txp-pcard .txp-pcard__sort-form {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	flex-shrink: 0;
	flex-wrap: nowrap;
}

.txp-pcard .txp-pcard__sort-label {
	font-size: 0.9rem;
	color: var(--c-text);
	opacity: 0.85;
	white-space: nowrap;
	flex-shrink: 0;
}

.txp-pcard .txp-pcard__sort-select {
	min-width: 220px;
	padding: 0.5rem 2rem 0.5rem 0.75rem;
	font-size: 0.9rem;
	color: var(--c-text);
	background-color: var(--c-bg);
	border: 1px solid var(--c-border);
	border-radius: 6px;
	cursor: pointer;
	appearance: auto;
}

.txp-pcard .txp-pcard__sort-select:hover,
.txp-pcard .txp-pcard__sort-select:focus {
	border-color: var(--c-primary);
	outline: none;
}

/* ==========================================================================
   Pagination — Centrage et style des boîtes
   Spécificité élevée pour contrer les overrides Elementor/theme (page-numbers)
   ========================================================================== */

/* Centrage : Flexbox sur le parent <nav> pour centrer la pagination au milieu de la page */
.txp-pcard nav.txp-pcard__pagination {
	margin-top: 2.5rem;
	display: flex;
	justify-content: center;
}

/* Liste : Flexbox horizontal, sans puces. !important pour contrer les overrides
   globaux (Elementor Kit, thème) qui ciblent .page-numbers */
.txp-pcard nav.txp-pcard__pagination ul.page-numbers {
	display: flex !important;
	flex-direction: row !important;
	flex-wrap: wrap;
	justify-content: center;
	align-items: stretch;
	list-style: none !important;
	list-style-type: none !important;
	margin: 0;
	padding: 0;
}

.txp-pcard nav.txp-pcard__pagination ul.page-numbers li {
	margin: 0;
	padding: 0;
	list-style: none !important;
	list-style-type: none !important;
}

/* Gestion des bordures : margin-left: -1px sur les éléments suivants pour éviter
   l'effet "double bordure" au milieu (les bordures adjacentes se superposent) */
.txp-pcard nav.txp-pcard__pagination ul.page-numbers li + li {
	margin-left: -1px;
}

/* Style des boîtes : bordure fine gris clair, typographie sans-serif */
.txp-pcard nav.txp-pcard__pagination ul.page-numbers a,
.txp-pcard nav.txp-pcard__pagination ul.page-numbers span {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 2.5rem;
	height: 2.5rem;
	padding: 0 0.75rem;
	font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
	font-size: 0.9rem;
	text-decoration: none;
	color: var(--c-text);
	background-color: #fff;
	border: 1px solid #e0e0e0;
	transition: background-color 0.2s ease;
}

/* Coins arrondis : premier élément (gauche), dernier élément (droite) */
.txp-pcard nav.txp-pcard__pagination ul.page-numbers li:first-child a,
.txp-pcard nav.txp-pcard__pagination ul.page-numbers li:first-child span {
	border-radius: 8px 0 0 8px;
}

.txp-pcard nav.txp-pcard__pagination ul.page-numbers li:last-child a,
.txp-pcard nav.txp-pcard__pagination ul.page-numbers li:last-child span {
	border-radius: 0 8px 8px 0;
}

/* État actif : texte orange, fond blanc pur */
.txp-pcard nav.txp-pcard__pagination ul.page-numbers .current {
	background-color: #fff;
	color: var(--c-accent, #d97706);
	border-color: #e0e0e0;
}

/* Flèches (prev/next) : gris bleuté discret */
.txp-pcard nav.txp-pcard__pagination ul.page-numbers .prev,
.txp-pcard nav.txp-pcard__pagination ul.page-numbers .next {
	color: #64748b;
}

/* Effet de survol : changement léger de couleur de fond */
.txp-pcard nav.txp-pcard__pagination ul.page-numbers a:hover {
	background-color: #f8fafc;
}

/* [hidden] doit toujours masquer — évite que display:flex du popover override */
.txp-cart-popover[hidden],
.txp-cart-sheet[hidden],
.txp-cart-dropdown[hidden] {
	display: none !important;
}

/* ==========================================================================
   TexPrint Cart Trigger — Panier header brandé
   Spécificité: .elementor-widget-txp_cart_trigger .txp-cart-trigger button.class (0-4-1)
   pour battre le Kit Elementor (.elementor-kit-xxx button = 0-1-1) et Hello reset.
   Règle Elementor-Button-CSS-Specificity : TOUTES les propriétés à redéclarer.
   ========================================================================== */
.elementor-widget-txp_cart_trigger .txp-cart-trigger {
	--c-primary: var(--c-primary, var(--e-global-color-primary, #1a365d));
	--c-text: var(--c-text, var(--e-global-color-text, #0f172a));
	--c-accent: var(--c-accent, var(--e-global-color-accent, #d97706));
	--c-bg: var(--c-bg, #ffffff);
	--c-border: var(--c-border, #e2e8f0);
	position: relative;
	display: inline-block;
	box-sizing: border-box;
	flex: 0 0 auto;
	align-self: center;
	width: auto;
	min-width: 0;
	/* Dropdown/popover sont portés vers body : ne jamais affecter le layout du header */
	overflow: visible;
}

.elementor-widget-txp_cart_trigger .txp-cart-trigger *,
.elementor-widget-txp_cart_trigger .txp-cart-trigger *::before,
.elementor-widget-txp_cart_trigger .txp-cart-trigger *::after {
	box-sizing: inherit;
}

/* Wrapper Elementor : pas de padding/margin parasite */
.elementor-element.elementor-widget-txp_cart_trigger .elementor-widget-container {
	padding: 0;
	margin: 0;
	line-height: 1;
}

/* Bouton : TOUTES les propriétés (Elementor-Button-CSS-Specificity) pour battre Kit + reset */
.elementor-element.elementor-widget-txp_cart_trigger .txp-cart-trigger button.txp-cart-trigger__btn,
.elementor-widget-txp_cart_trigger .txp-cart-trigger button.txp-cart-trigger__btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	padding: 6px 12px;
	width: auto;
	min-width: 0;
	max-width: none;
	background-color: transparent;
	color: var(--c-text);
	border: 1px solid #e2e8f0;
	border-style: solid;
	border-radius: 8px;
	font-family: inherit;
	font-size: 0.875rem;
	font-weight: 500;
	letter-spacing: 0;
	text-transform: none;
	line-height: 1.2;
	text-align: center;
	cursor: pointer;
	transition: background-color 0.2s ease, border-color 0.2s ease;
	flex: 0 0 auto;
}

.elementor-widget-txp_cart_trigger .txp-cart-trigger button.txp-cart-trigger__btn:hover {
	background-color: rgba(0, 0, 0, 0.04);
	border-color: #cbd5e1;
}

/* Mode compact : icône + badge uniquement, bouton plus petit */
.elementor-widget-txp_cart_trigger .txp-cart-trigger--compact button.txp-cart-trigger__btn {
	padding: 6px 10px;
	gap: 4px;
}

.elementor-widget-txp_cart_trigger .txp-cart-trigger--compact .txp-cart-trigger__icon svg {
	width: 20px;
	height: 20px;
}

.elementor-widget-txp_cart_trigger .txp-cart-trigger--compact span.txp-cart-trigger__badge {
	min-width: 18px;
	height: 18px;
	padding: 0 5px;
	font-size: 0.6875rem;
	color: #ffffff !important;
	background-color: #1a365d !important;
}

.elementor-widget-txp_cart_trigger .txp-cart-trigger button.txp-cart-trigger__btn:focus,
.elementor-widget-txp_cart_trigger .txp-cart-trigger button.txp-cart-trigger__btn:focus-visible {
	outline: none;
	box-shadow: none;
}

.txp-cart-trigger .txp-cart-trigger__icon {
	display: inline-flex;
	flex-shrink: 0;
	color: currentColor;
}

.txp-cart-trigger .txp-cart-trigger__icon svg {
	width: 22px;
	height: 22px;
}

/* Badge compteur — style B2B moderne, contraste garanti (bleu foncé + blanc) */
.elementor-widget-txp_cart_trigger .txp-cart-trigger span.txp-cart-trigger__badge,
.txp-cart-trigger span.txp-cart-trigger__badge {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 20px;
	height: 20px;
	padding: 0 6px;
	font-size: 0.75rem;
	font-weight: 700;
	line-height: 1;
	color: #ffffff !important;
	background-color: #1a365d !important;
	border-radius: 10px;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
	flex-shrink: 0;
}

.txp-cart-trigger .txp-cart-dropdown,
.txp-cart-trigger .txp-cart-popover {
	position: absolute;
	top: 100%;
	right: 0;
	margin-top: 6px;
	width: 360px;
	max-width: calc(100vw - 24px);
	background-color: var(--c-bg);
	border: 1px solid var(--c-border);
	border-radius: 12px;
	box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
	z-index: 99999;
	overflow: hidden;
}

.txp-cart-trigger .txp-cart-dropdown__inner,
.txp-cart-trigger .txp-cart-popover__inner {
	padding: 16px;
}

.txp-cart-trigger .txp-cart-empty {
	text-align: center;
	padding: 24px 0;
}

.txp-cart-trigger p.txp-cart-empty__text {
	margin: 0 0 16px;
	font-size: 0.9375rem;
	color: var(--c-text);
}

.txp-cart-trigger .txp-cart-items {
	max-height: 240px;
	overflow-y: auto;
	margin-bottom: 12px;
}

.txp-cart-trigger .txp-cart-footer {
	display: flex;
	flex-direction: column;
	gap: 8px;
	padding-top: 12px;
	border-top: 1px solid var(--c-border);
}

.elementor-widget-txp_cart_trigger .txp-cart-trigger a.txp-cart-cta {
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 10px 16px;
	font-size: 0.875rem;
	font-weight: 600;
	text-decoration: none;
	border-radius: 8px;
	transition: background-color 0.2s ease, opacity 0.2s ease;
	text-align: center;
}

.elementor-widget-txp_cart_trigger .txp-cart-trigger a.txp-cart-cta--primary {
	background-color: var(--c-primary);
	color: #fff;
}

.elementor-widget-txp_cart_trigger .txp-cart-trigger a.txp-cart-cta--primary:hover {
	opacity: 0.92;
}

.elementor-widget-txp_cart_trigger .txp-cart-trigger a.txp-cart-cta--secondary {
	background-color: transparent;
	color: var(--c-text);
	border: 1px solid var(--c-border);
}

.elementor-widget-txp_cart_trigger .txp-cart-trigger a.txp-cart-cta--secondary:hover {
	background-color: rgba(0, 0, 0, 0.04);
}

.elementor-widget-txp_cart_trigger .txp-cart-trigger a.txp-cart-cta--details {
	background-color: transparent;
	color: var(--c-primary);
	border: 1px solid var(--c-primary);
}

.txp-cart-trigger .txp-cart-popover__header,
.txp-cart-trigger .txp-cart-popover__footer {
	display: flex;
	align-items: center;
	gap: 12px;
}

.txp-cart-trigger .txp-cart-popover__header {
	justify-content: space-between;
	margin-bottom: 12px;
}

.txp-cart-trigger h3.txp-cart-popover__title {
	margin: 0;
	font-size: 1.125rem;
	font-weight: 600;
	color: var(--c-text);
}

.elementor-widget-txp_cart_trigger .txp-cart-trigger button.txp-cart-popover__close {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	padding: 0;
	background-color: transparent;
	border: none;
	border-radius: 6px;
	font-size: 1.5rem;
	line-height: 1;
	color: var(--c-text);
	cursor: pointer;
	transition: background-color 0.2s ease;
}

.elementor-widget-txp_cart_trigger .txp-cart-trigger button.txp-cart-popover__close:hover {
	background-color: rgba(0, 0, 0, 0.06);
}

.txp-cart-trigger .txp-cart-popover__footer {
	justify-content: flex-end;
	margin-top: 12px;
	padding-top: 12px;
	border-top: 1px solid var(--c-border);
}

.txp-cart-trigger .txp-cart-sheet {
	position: fixed;
	inset: 0;
	z-index: 99999;
	display: flex;
	align-items: flex-end;
	justify-content: center;
	pointer-events: none;
}

.txp-cart-trigger .txp-cart-sheet[aria-hidden="false"] {
	pointer-events: auto;
}

.txp-cart-trigger .txp-cart-sheet__backdrop {
	position: absolute;
	inset: 0;
	background-color: rgba(0, 0, 0, 0.4);
	opacity: 0;
	transition: opacity 0.25s ease;
}

.txp-cart-trigger .txp-cart-sheet[aria-hidden="false"] .txp-cart-sheet__backdrop {
	opacity: 1;
}

.txp-cart-trigger .txp-cart-sheet__panel {
	position: relative;
	width: 100%;
	max-height: 85vh;
	background-color: var(--c-bg);
	border-radius: 16px 16px 0 0;
	box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.15);
	transform: translateY(100%);
	transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
	overflow: hidden;
	display: flex;
	flex-direction: column;
}

.txp-cart-trigger .txp-cart-sheet[aria-hidden="false"] .txp-cart-sheet__panel {
	transform: translateY(0);
}

.txp-cart-trigger .txp-cart-sheet__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 16px 20px;
	border-bottom: 1px solid var(--c-border);
	flex-shrink: 0;
}

.txp-cart-trigger h3.txp-cart-sheet__title {
	margin: 0;
	font-size: 1.25rem;
	font-weight: 600;
	color: var(--c-text);
}

.elementor-widget-txp_cart_trigger .txp-cart-trigger button.txp-cart-sheet__close {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	padding: 0;
	background-color: transparent;
	border: none;
	border-radius: 8px;
	font-size: 1.5rem;
	line-height: 1;
	color: var(--c-text);
	cursor: pointer;
	transition: background-color 0.2s ease;
}

.elementor-widget-txp_cart_trigger .txp-cart-trigger button.txp-cart-sheet__close:hover {
	background-color: rgba(0, 0, 0, 0.06);
}

.txp-cart-trigger .txp-cart-sheet__body {
	flex: 1;
	overflow-y: auto;
	padding: 16px 20px;
}

.txp-cart-trigger .txp-cart-sheet__footer {
	display: flex;
	flex-direction: column;
	gap: 8px;
	padding: 16px 20px;
	border-top: 1px solid var(--c-border);
	flex-shrink: 0;
}

@media (max-width: 767px) {
	.txp-cart-trigger .txp-cart-dropdown,
	.txp-cart-trigger .txp-cart-popover {
		display: none;
	}
}

@media (min-width: 768px) {
	.txp-cart-trigger .txp-cart-sheet {
		display: none;
	}
	/* PC : uniquement le popover (hover + clic), pas le dropdown */
	.txp-cart-dropdown,
	body > .txp-cart-dropdown {
		display: none !important;
	}
}

.txp-cart-trigger .txp-cart-item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 8px 0;
	border-bottom: 1px solid var(--c-border);
}

.txp-cart-trigger .txp-cart-item:last-child {
	border-bottom: none;
}

.txp-cart-trigger .txp-cart-item__link {
	display: flex;
	align-items: center;
	gap: 12px;
	flex: 1;
	text-decoration: none;
	color: var(--c-text);
	min-width: 0;
}

.txp-cart-trigger .txp-cart-item__link:hover {
	color: var(--c-primary);
}

.txp-cart-trigger .txp-cart-item__img {
	width: 48px;
	height: 48px;
	object-fit: cover;
	border-radius: 6px;
	flex-shrink: 0;
}

.txp-cart-trigger .txp-cart-item__info {
	display: flex;
	flex-direction: column;
	gap: 2px;
	min-width: 0;
}

.txp-cart-trigger .txp-cart-item__name {
	font-size: 0.875rem;
	font-weight: 500;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.txp-cart-trigger .txp-cart-item__meta {
	font-size: 0.75rem;
	color: var(--c-text);
	opacity: 0.8;
}

.txp-cart-trigger .txp-cart-more {
	font-size: 0.8125rem;
	color: var(--c-text);
	opacity: 0.7;
	padding: 8px 0;
}

.txp-cart-trigger .txp-cart-item--popover {
	position: relative;
	padding-right: 32px;
}

.txp-cart-trigger .txp-cart-item__remove {
	position: absolute;
	right: 0;
	top: 50%;
	transform: translateY(-50%);
	width: 28px;
	height: 28px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 1.25rem;
	line-height: 1;
	color: var(--c-text);
	opacity: 0.6;
	text-decoration: none;
	border-radius: 6px;
	transition: opacity 0.2s ease, background-color 0.2s ease;
}

.txp-cart-trigger .txp-cart-item__remove:hover {
	opacity: 1;
	background-color: rgba(0, 0, 0, 0.06);
}

.txp-cart-trigger .txp-cart-totals-by-nature,
.txp-cart-trigger .txp-cart-totals-final {
	margin-top: 12px;
	padding-top: 12px;
	border-top: 1px solid var(--c-border);
}

.txp-cart-trigger .txp-cart-totals-row {
	display: flex;
	justify-content: space-between;
	align-items: center;
	font-size: 0.875rem;
	padding: 4px 0;
}

.txp-cart-trigger .txp-cart-totals-final .txp-cart-totals-row:last-child {
	font-weight: 600;
	font-size: 1rem;
}

/* ==========================================================================
   TexPrint Cart — Overlays portés dans body (indépendants du parent .txp-cart-trigger)
   Répète les styles nécessaires pour que dropdown/popover/sheet restent lisibles.
   ========================================================================== */
.txp-cart-dropdown,
.txp-cart-popover,
.txp-cart-sheet {
	--c-primary: var(--e-global-color-primary, #1a365d);
	--c-text: var(--e-global-color-text, #0f172a);
	--c-bg: #ffffff;
	--c-border: #e2e8f0;
	box-sizing: border-box;
	font-family: inherit;
}
.txp-cart-dropdown *,
.txp-cart-dropdown *::before,
.txp-cart-dropdown *::after,
.txp-cart-popover *,
.txp-cart-popover *::before,
.txp-cart-popover *::after,
.txp-cart-sheet *,
.txp-cart-sheet *::before,
.txp-cart-sheet *::after {
	box-sizing: inherit;
}

body.txp-cart-popover-open > .txp-cart-dropdown {
	display: none !important;
}

.txp-cart-dropdown,
.txp-cart-popover {
	background-color: var(--c-bg);
	border: 1px solid var(--c-border);
	border-radius: 12px;
	box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
	overflow: hidden;
	max-height: min(480px, 85vh);
	display: flex;
	flex-direction: column;
}
.txp-cart-popover .txp-cart-popover__inner {
	display: flex;
	flex-direction: column;
	max-height: inherit;
	overflow: hidden;
	padding: 16px;
}
.txp-cart-popover .txp-cart-popover__body {
	flex: 1;
	min-height: 0;
	overflow-y: auto;
}
.txp-cart-dropdown__inner {
	padding: 16px;
}
.txp-cart-empty {
	text-align: center;
	padding: 24px 0;
}
.txp-cart-dropdown p.txp-cart-empty__text,
.txp-cart-popover p.txp-cart-empty__text {
	margin: 0 0 16px;
	font-size: 0.9375rem;
	color: var(--c-text);
}
.txp-cart-dropdown .txp-cart-items,
.txp-cart-popover .txp-cart-popover-items,
.txp-cart-sheet .txp-cart-popover-items {
	max-height: 200px;
	overflow-y: auto;
	margin-bottom: 12px;
	-webkit-overflow-scrolling: touch;
}
.txp-cart-dropdown .txp-cart-footer,
.txp-cart-popover .txp-cart-popover__footer,
.txp-cart-sheet .txp-cart-popover__footer {
	display: flex;
	flex-direction: column;
	gap: 8px;
	padding-top: 12px;
	border-top: 1px solid var(--c-border);
}
.txp-cart-dropdown .txp-cart-popover__header,
.txp-cart-popover .txp-cart-popover__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 12px;
	gap: 12px;
}
.txp-cart-popover h3.txp-cart-popover__title {
	margin: 0;
	font-size: 1.125rem;
	font-weight: 600;
	color: var(--c-text);
}
.txp-cart-dropdown a.txp-cart-cta,
.txp-cart-popover a.txp-cart-cta,
.txp-cart-sheet a.txp-cart-cta {
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 10px 16px;
	font-size: 0.875rem;
	font-weight: 600;
	text-decoration: none;
	border-radius: 8px;
	transition: background-color 0.2s ease, opacity 0.2s ease;
	text-align: center;
	color: var(--c-text);
}
.txp-cart-dropdown a.txp-cart-cta--primary,
.txp-cart-popover a.txp-cart-cta--primary,
.txp-cart-sheet a.txp-cart-cta--primary {
	background-color: var(--c-primary);
	color: #fff;
}
.txp-cart-dropdown a.txp-cart-cta--secondary,
.txp-cart-popover a.txp-cart-cta--secondary,
.txp-cart-sheet a.txp-cart-cta--secondary {
	background-color: transparent;
	border: 1px solid var(--c-border);
}
.txp-cart-dropdown a.txp-cart-cta--details,
.txp-cart-popover a.txp-cart-cta--details {
	background-color: transparent;
	color: var(--c-primary);
	border: 1px solid var(--c-primary);
}
.txp-cart-dropdown .txp-cart-popover__footer,
.txp-cart-popover .txp-cart-popover__footer {
	justify-content: flex-end;
	margin-top: 12px;
	flex-direction: row;
	flex-wrap: wrap;
}
.txp-cart-dropdown button.txp-cart-popover__close,
.txp-cart-popover button.txp-cart-popover__close {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	padding: 0;
	background-color: transparent;
	border: none;
	border-radius: 6px;
	font-size: 1.5rem;
	line-height: 1;
	color: var(--c-text);
	cursor: pointer;
}
.txp-cart-dropdown .txp-cart-item,
.txp-cart-popover .txp-cart-item,
.txp-cart-sheet .txp-cart-item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 8px 0;
	border-bottom: 1px solid var(--c-border);
}
.txp-cart-dropdown .txp-cart-item:last-child,
.txp-cart-popover .txp-cart-item:last-child,
.txp-cart-sheet .txp-cart-item:last-child {
	border-bottom: none;
}
.txp-cart-dropdown .txp-cart-item__img,
.txp-cart-popover .txp-cart-item__img,
.txp-cart-sheet .txp-cart-item__img {
	width: 48px;
	height: 48px;
	object-fit: cover;
	border-radius: 6px;
	flex-shrink: 0;
}
.txp-cart-dropdown .txp-cart-item__info,
.txp-cart-popover .txp-cart-item__info,
.txp-cart-sheet .txp-cart-item__info {
	display: flex;
	flex-direction: column;
	gap: 2px;
	min-width: 0;
	flex: 1 1 auto;
}
.txp-cart-dropdown .txp-cart-item__name,
.txp-cart-popover .txp-cart-item__name,
.txp-cart-sheet .txp-cart-item__name {
	font-size: 0.875rem;
	font-weight: 500;
	white-space: normal;
	word-break: break-word;
	color: var(--c-text);
}
.txp-cart-dropdown .txp-cart-item__meta,
.txp-cart-popover .txp-cart-item__meta,
.txp-cart-sheet .txp-cart-item__meta {
	display: block;
	font-size: 0.75rem;
	color: var(--c-text);
	opacity: 0.85;
	line-height: 1.35;
}
.txp-cart-dropdown .txp-cart-item--popover,
.txp-cart-popover .txp-cart-item--popover,
.txp-cart-sheet .txp-cart-item--popover {
	position: relative;
	padding-right: 32px;
}
.txp-cart-dropdown .txp-cart-item__remove,
.txp-cart-popover .txp-cart-item__remove,
.txp-cart-sheet .txp-cart-item__remove {
	position: absolute;
	right: 0;
	top: 50%;
	transform: translateY(-50%);
	width: 28px;
	height: 28px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 1.25rem;
	line-height: 1;
	color: var(--c-text);
	opacity: 0.6;
	text-decoration: none;
	border-radius: 6px;
}
.txp-cart-dropdown .txp-cart-totals-by-nature,
.txp-cart-popover .txp-cart-totals-by-nature,
.txp-cart-sheet .txp-cart-totals-by-nature,
.txp-cart-dropdown .txp-cart-totals-final,
.txp-cart-popover .txp-cart-totals-final,
.txp-cart-sheet .txp-cart-totals-final {
	margin-top: 12px;
	padding-top: 12px;
	border-top: 1px solid var(--c-border);
}
.txp-cart-dropdown .txp-cart-totals-row,
.txp-cart-popover .txp-cart-totals-row,
.txp-cart-sheet .txp-cart-totals-row {
	display: flex;
	justify-content: space-between;
	align-items: center;
	font-size: 0.875rem;
	padding: 4px 0;
	color: var(--c-text);
	gap: 16px;
}
.txp-cart-dropdown .txp-cart-totals-final .txp-cart-totals-row:last-child,
.txp-cart-popover .txp-cart-totals-final .txp-cart-totals-row:last-child,
.txp-cart-sheet .txp-cart-totals-final .txp-cart-totals-row:last-child {
	font-weight: 600;
	font-size: 1rem;
}
.txp-cart-dropdown .txp-cart-more,
.txp-cart-popover .txp-cart-more {
	font-size: 0.8125rem;
	color: var(--c-text);
	opacity: 0.7;
	padding: 8px 0;
}

/* Sheet en body */
.txp-cart-sheet {
	position: fixed;
	inset: 0;
	z-index: 999999;
	display: flex;
	align-items: flex-end;
	justify-content: center;
	pointer-events: none;
}
.txp-cart-sheet[aria-hidden="false"] {
	pointer-events: auto;
}
.txp-cart-sheet__backdrop {
	position: absolute;
	inset: 0;
	background-color: rgba(0, 0, 0, 0.4);
	opacity: 0;
	transition: opacity 0.25s ease;
}
.txp-cart-sheet[aria-hidden="false"] .txp-cart-sheet__backdrop {
	opacity: 1;
}
.txp-cart-sheet__panel {
	position: relative;
	width: 100%;
	max-height: 85vh;
	background-color: var(--c-bg);
	border-radius: 16px 16px 0 0;
	box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.15);
	transform: translateY(100%);
	transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
	overflow: hidden;
	display: flex;
	flex-direction: column;
}
.txp-cart-sheet[aria-hidden="false"] .txp-cart-sheet__panel {
	transform: translateY(0);
}
.txp-cart-sheet__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 16px 20px;
	border-bottom: 1px solid var(--c-border);
	flex-shrink: 0;
}
.txp-cart-sheet h3.txp-cart-sheet__title {
	margin: 0;
	font-size: 1.25rem;
	font-weight: 600;
	color: var(--c-text);
}
.txp-cart-sheet button.txp-cart-sheet__close {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	padding: 0;
	background-color: transparent;
	border: none;
	border-radius: 8px;
	font-size: 1.5rem;
	line-height: 1;
	color: var(--c-text);
	cursor: pointer;
}
.txp-cart-sheet__body {
	flex: 1;
	overflow-y: auto;
	padding: 16px 20px;
}
.txp-cart-sheet__footer {
	display: flex;
	flex-direction: column;
	gap: 8px;
	padding: 16px 20px;
	border-top: 1px solid var(--c-border);
	flex-shrink: 0;
}
