/* ZS Autopart — boutique (maquette VAGParts). --zsa-brand vient du réglage « Widgets boutique ». */

.zsa-shop {
	--zsa-brand: #c8101e;
	--zsa-brand-d: color-mix(in srgb, var(--zsa-brand) 82%, #000);
	--zsa-bg: #f4f5f7;
	--zsa-ink: #161a20;
	--zsa-mut: #565f6d;
	--zsa-line: #e6e8ec;
	--zsa-navy: #0f172a;
	--zsa-ok: #15803d;
	--zsa-warn: #b45309;
	--zsa-danger: #dc2626;
	--zsa-sh: 0 1px 3px rgba(16, 24, 40, .06), 0 1px 2px rgba(16, 24, 40, .04);
	--zsa-sh-lg: 0 10px 30px rgba(16, 24, 40, .10);
	box-sizing: border-box;
	color: var(--zsa-ink);
	font-family: "Segoe UI", system-ui, Roboto, Arial, sans-serif;
	font-size: 15px;
	line-height: 1.5;
	text-align: left;
}
.zsa-shop *,
.zsa-shop *::before,
.zsa-shop *::after { box-sizing: border-box; }
.zsa-shop a { color: inherit; text-decoration: none; }
.zsa-shop img { max-width: 100%; height: auto; }
.zsa-shop h1,
.zsa-shop h2,
.zsa-shop h3 { color: var(--zsa-ink); font-family: inherit; font-weight: 700; letter-spacing: 0; text-transform: none; }
.zsa-shop b { font-weight: 700; }
.zsa-shop .zsa-muted { color: var(--zsa-mut); }
.zsa-shop .zsa-between { display: flex; justify-content: space-between; align-items: center; }
.zsa-shop .screen-reader-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* Boutons */
.zsa-shop .zsa-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 11px 18px; border: 1px solid transparent; border-radius: 8px; background: var(--zsa-brand); color: #fff; font: 600 15px/1.3 inherit; font-family: inherit; text-align: center; cursor: pointer; transition: background-color .15s, border-color .15s; }
.zsa-shop .zsa-btn:hover { background: var(--zsa-brand-d); color: #fff; }
.zsa-shop .zsa-btn:focus-visible { outline: 3px solid color-mix(in srgb, var(--zsa-brand) 35%, transparent); outline-offset: 2px; }
.zsa-shop .zsa-btn--navy { background: var(--zsa-navy); }
.zsa-shop .zsa-btn--navy:hover { background: #1e293b; }
.zsa-shop .zsa-btn--ghost { border-color: var(--zsa-line); background: #fff; color: var(--zsa-ink); }
.zsa-shop .zsa-btn--ghost:hover { border-color: #c7ccd4; background: #fff; color: var(--zsa-ink); }
.zsa-shop .zsa-btn--sm { padding: 7px 12px; font-size: 13px; }
.zsa-shop .zsa-btn--lg { padding: 15px; font-size: 16px; }
.zsa-shop .zsa-btn--block { width: 100%; }
.zsa-shop .zsa-btn.is-disabled,
.zsa-shop .zsa-btn:disabled { opacity: .45; cursor: not-allowed; }
.zsa-shop .zsa-btn.loading { opacity: .6; pointer-events: none; }
.zsa-shop .added_to_cart { display: none; } /* Lien « Voir le panier » de WooCommerce : le panier latéral s'ouvre à la place. */

/* Champs */
.zsa-shop input[type="text"],
.zsa-shop input[type="tel"],
.zsa-shop input[type="search"],
.zsa-shop select,
.zsa-shop textarea { width: 100%; min-height: 0; margin: 0; padding: 11px 12px; border: 1px solid var(--zsa-line); border-radius: 8px; background-color: #fff; color: var(--zsa-ink); font: 400 15px/1.4 inherit; font-family: inherit; box-shadow: none; }
.zsa-shop input:focus,
.zsa-shop select:focus,
.zsa-shop textarea:focus { outline: none; border-color: var(--zsa-brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--zsa-brand) 14%, transparent); }
.zsa-shop label,
.zsa-shop legend { display: block; margin: 0 0 6px; padding: 0; color: #374151; font-size: 13px; font-weight: 600; }

/* ---------- En-tête ---------- */
.zsa-header { position: sticky; top: 0; z-index: 30; background: #fff; border-bottom: 1px solid var(--zsa-line); box-shadow: var(--zsa-sh); }
.zsa-announce { padding: 10px; background: var(--zsa-navy); color: #fff; font-size: 13px; text-align: center; }
.zsa-navbar { display: flex; align-items: center; gap: 22px; max-width: 1180px; margin: auto; padding: 14px 20px; }
.zsa-shop .zsa-logo { display: flex; align-items: center; gap: 8px; font-size: 22px; font-weight: 900; letter-spacing: .3px; }
.zsa-logo span { padding: 3px 8px; border-radius: 7px; background: var(--zsa-brand); color: #fff; }
.zsa-logo b { color: var(--zsa-brand); }
.zsa-searchbox { position: relative; flex: 1; margin: 0; }
.zsa-shop .zsa-searchbox input { padding-left: 38px; background-color: var(--zsa-bg); }
.zsa-searchbox::before { content: "🔎"; position: absolute; top: 10px; left: 12px; opacity: .5; }
.zsa-nav { display: flex; gap: 4px; }
.zsa-shop .zsa-nav a { padding: 9px 14px; border-radius: 8px; color: #374151; font-size: 14px; font-weight: 600; }
.zsa-shop .zsa-nav a:hover,
.zsa-shop .zsa-nav a.is-active { background: var(--zsa-bg); color: var(--zsa-brand); }
.zsa-cart-btn { position: relative; }
.zsa-cart-count { position: absolute; top: -7px; right: -7px; padding: 1px 6px; border-radius: 20px; background: var(--zsa-brand); color: #fff; font-size: 11px; font-weight: 700; }

/* ---------- Accueil ---------- */
.zsa-hero { display: grid; grid-template-columns: 1.3fr 1fr; gap: 30px; align-items: center; max-width: 1180px; margin: 26px auto; padding: 46px; overflow: hidden; border-radius: 16px; background: linear-gradient(115deg, #0f172a, #20272f 60%, #3a1113); color: #fff; }
.zsa-shop.zsa-hero h1 { margin: 0 0 12px; color: #fff; font-size: 36px; line-height: 1.15; }
.zsa-hero h1 span { color: #ff5a63; }
.zsa-hero p { max-width: 480px; margin: 0 0 20px; color: #cbd5e1; }
.zsa-hero__pills { display: flex; flex-wrap: wrap; gap: 10px; }
.zsa-chip { padding: 7px 13px; border: 1px solid #ffffff22; border-radius: 20px; background: #ffffff18; font-size: 13px; }
.zsa-hero__art { font-size: 150px; line-height: 1; text-align: center; filter: drop-shadow(0 12px 24px rgba(0, 0, 0, .4)); }
.zsa-trust { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; max-width: 1180px; margin: 0 auto 30px; }
.zsa-trust__item { padding: 16px; border: 1px solid var(--zsa-line); border-radius: 12px; background: #fff; box-shadow: var(--zsa-sh); }
.zsa-trust__icon { font-size: 22px; }
.zsa-trust__item b { display: block; margin-top: 6px; }
.zsa-trust__item span { color: var(--zsa-mut); font-size: 13px; }

/* ---------- Grille ---------- */
.zsa-catalog { max-width: 1180px; margin: 0 auto; }
.zsa-sechead { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 18px; }
.zsa-shop .zsa-sechead h2 { margin: 0; font-size: 24px; }
.zsa-filters { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 20px; }
.zsa-shop .zsa-filters select { flex: 1; width: auto; min-width: 160px; max-width: 240px; }
.zsa-catalog__q { margin: -8px 0 16px; font-size: 14px; }
.zsa-shop .zsa-catalog__q a { color: var(--zsa-brand); text-decoration: underline; }
.zsa-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 18px; }
.zsa-card { display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--zsa-line); border-radius: 14px; background: #fff; box-shadow: var(--zsa-sh); transition: box-shadow .15s, transform .15s; }
.zsa-card:hover { box-shadow: var(--zsa-sh-lg); transform: translateY(-2px); }
.zsa-card__img { position: relative; display: flex; align-items: center; justify-content: center; height: 160px; background: linear-gradient(135deg, #f8fafc, #eef1f5); }
.zsa-shop .zsa-card__img img { width: 100%; height: 100%; object-fit: contain; }
.zsa-tag { position: absolute; top: 10px; left: 10px; padding: 3px 8px; border-radius: 6px; background: var(--zsa-navy); color: #fff; font-size: 11px; font-weight: 700; }
.zsa-tag--out { background: var(--zsa-danger); }
.zsa-tag--low { background: var(--zsa-warn); }
.zsa-card__body { display: flex; flex: 1; flex-direction: column; gap: 5px; padding: 14px; }
.zsa-card__ref { min-height: 18px; color: var(--zsa-mut); font-size: 12px; }
.zsa-shop .zsa-card__name { font-size: 15px; font-weight: 700; line-height: 1.3; }
.zsa-shop .zsa-card__name:hover { color: var(--zsa-brand); }
.zsa-card__price { margin-top: auto; font-size: 20px; font-weight: 800; }
.zsa-card__row { display: flex; gap: 8px; margin-top: 8px; }
.zsa-card__row .zsa-btn { flex: 1; }
.zsa-pages { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin: 26px 0 0; }
.zsa-shop .zsa-pages .page-numbers { min-width: 38px; padding: 8px 10px; border: 1px solid var(--zsa-line); border-radius: 8px; background: #fff; font-weight: 600; text-align: center; }
.zsa-shop .zsa-pages .page-numbers.current { border-color: var(--zsa-brand); background: var(--zsa-brand); color: #fff; }

/* ---------- Page produit ---------- */
.zsa-pdpwrap,
.zsa-checkoutwrap { max-width: 1180px; margin: 0 auto; }
.zsa-crumb { margin: 20px 0; color: var(--zsa-mut); font-size: 13px; }
.zsa-shop .zsa-crumb a:hover { color: var(--zsa-brand); }
.zsa-pdp { display: grid; grid-template-columns: 1fr 1fr; gap: 34px; margin-bottom: 30px; }
.zsa-pdp__gallery { display: flex; align-items: center; justify-content: center; height: 380px; overflow: hidden; border: 1px solid var(--zsa-line); border-radius: 16px; background: #fff; box-shadow: var(--zsa-sh); }
.zsa-shop .zsa-pdp__gallery img { width: 100%; height: 100%; object-fit: contain; }
.zsa-pdp__thumbs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.zsa-pdp__thumbs button { width: 64px; height: 64px; padding: 0; overflow: hidden; border: 1px solid var(--zsa-line); border-radius: 10px; background: #fff; cursor: pointer; }
.zsa-pdp__thumbs button:hover,
.zsa-pdp__thumbs button:focus-visible { border-color: var(--zsa-brand); }
.zsa-shop .zsa-pdp__thumbs img { width: 100%; height: 100%; object-fit: cover; }
.zsa-pdp__ref { font-size: 14px; }
.zsa-shop .zsa-pdp h1 { margin: 6px 0 4px; font-size: 28px; line-height: 1.2; }
.zsa-stockdot { font-size: 12px; font-weight: 700; }
.zsa-is-ok { color: var(--zsa-ok); }
.zsa-is-low { color: var(--zsa-warn); }
.zsa-is-out { color: var(--zsa-danger); }
.zsa-pdp__price { margin: 14px 0; color: var(--zsa-brand); font-size: 34px; font-weight: 800; }
.zsa-pdp__short p { margin: 0 0 8px; }
.zsa-pdp__specs { width: 100%; margin: 18px 0; overflow: hidden; border: 1px solid var(--zsa-line); border-radius: 12px; }
.zsa-pdp__specs div { display: flex; justify-content: space-between; gap: 16px; padding: 11px 14px; font-size: 14px; }
.zsa-pdp__specs div:nth-child(odd) { background: #fafbfc; }
.zsa-pdp__specs b { text-align: right; overflow-wrap: anywhere; }
.zsa-pdp__cta { display: flex; gap: 12px; margin-top: 20px; }
.zsa-shop .zsa-pdp__cta .zsa-btn { flex: 1; padding: 15px; }
.zsa-pdp__desc { margin: 0 0 40px; padding: 26px; border: 1px solid var(--zsa-line); border-radius: 16px; background: #fff; box-shadow: var(--zsa-sh); }
.zsa-shop .zsa-pdp__desc h2 { margin: 0 0 12px; font-size: 20px; }

/* ---------- Commande ---------- */
.zsa-shop .zsa-checkout__title { margin: 0 0 6px; font-size: 24px; }
.zsa-checkout__lead { margin: 0; }
.zsa-checkout { display: grid; grid-template-columns: 1.4fr 1fr; gap: 26px; align-items: start; margin: 24px 0 50px; }
.zsa-formcard,
.zsa-summary { padding: 26px; border: 1px solid var(--zsa-line); border-radius: 16px; background: #fff; box-shadow: var(--zsa-sh); }
.zsa-summary { position: sticky; top: 90px; }
.zsa-shop .zsa-formcard h3 { margin: 0 0 16px; font-size: 18px; }
.zsa-shop .zsa-summary h3 { margin: 0 0 14px; font-size: 18px; }
.zsa-field { margin: 0 0 16px; padding: 0; border: 0; }
.zsa-two { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.zsa-radio-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.zsa-shop .zsa-radio-tile { position: relative; margin: 0; padding: 14px; border: 1.5px solid var(--zsa-line); border-radius: 12px; cursor: pointer; transition: border-color .12s, background-color .12s; }
.zsa-radio-tile input { position: absolute; opacity: 0; }
.zsa-radio-tile.is-sel,
.zsa-radio-tile:has(input:checked) { border-color: var(--zsa-brand); background: color-mix(in srgb, var(--zsa-brand) 5%, #fff); }
.zsa-radio-tile:has(input:focus-visible) { box-shadow: 0 0 0 3px color-mix(in srgb, var(--zsa-brand) 20%, transparent); }
.zsa-radio-tile b { display: block; color: var(--zsa-ink); font-size: 15px; }
.zsa-radio-tile span { color: var(--zsa-mut); font-size: 13px; font-weight: 400; }
.zsa-hp { position: absolute; left: -9999px; }
.zsa-sumitems { max-height: 230px; margin-bottom: 10px; overflow: auto; }
.zsa-si { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--zsa-line); }
.zsa-si__img { flex: none; width: 42px; height: 42px; overflow: hidden; border-radius: 8px; background: var(--zsa-bg); }
.zsa-shop .zsa-si__img img { width: 100%; height: 100%; object-fit: contain; }
.zsa-si__text { flex: 1; min-width: 0; }
.zsa-si__text b { font-size: 14px; }
.zsa-si__text div { font-size: 12px; }
.zsa-sumline { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px dashed var(--zsa-line); font-size: 14px; }
.zsa-sumtotal { display: flex; justify-content: space-between; padding-top: 14px; font-size: 22px; font-weight: 800; }
.zsa-summary__pay { margin: 14px 0 0; font-size: 13px; }
.zsa-shop .woocommerce-error,
.zsa-shop .woocommerce-message,
.zsa-shop .woocommerce-info { margin: 16px 0 0; padding: 12px 16px; border: 1px solid #fecaca; border-radius: 10px; background: #fef2f2; color: #991b1b; list-style: none; font-size: 14px; }

/* ---------- Merci ---------- */
.zsa-thanks { max-width: 620px; margin: 60px auto; padding: 48px; border: 1px solid var(--zsa-line); border-radius: 20px; background: #fff; box-shadow: var(--zsa-sh-lg); text-align: center; }
.zsa-thanks__check { display: flex; align-items: center; justify-content: center; width: 84px; height: 84px; margin: 0 auto 22px; border-radius: 50%; background: #dcfce7; color: var(--zsa-ok); font-size: 44px; }
.zsa-shop.zsa-thanks h1 { margin: 0 0 8px; font-size: 28px; }
.zsa-thanks__ref { display: inline-block; margin: 16px 0; padding: 12px 22px; border: 1px dashed var(--zsa-line); border-radius: 10px; background: var(--zsa-bg); font-size: 20px; font-weight: 800; letter-spacing: 1px; }
.zsa-thanks__recap { margin: 20px 0; padding: 18px; border-radius: 12px; background: var(--zsa-bg); font-size: 14px; text-align: left; }
.zsa-thanks__recap div { display: flex; justify-content: space-between; gap: 16px; padding: 5px 0; }
.zsa-thanks__recap b { text-align: right; }
.zsa-thanks__recap .zsa-thanks__total { margin-top: 6px; padding-top: 8px; border-top: 1px solid var(--zsa-line); }
.zsa-thanks__total b { color: var(--zsa-brand); font-size: 18px; }

/* ---------- Panier latéral ---------- */
.zsa-backdrop { position: fixed; inset: 0; z-index: 99990; background: #0006; }
.zsa-backdrop[hidden] { display: none; }
.zsa-drawer { position: fixed; top: 0; right: 0; z-index: 99995; display: flex; flex-direction: column; width: 420px; max-width: 100%; height: 100%; background: #fff; box-shadow: var(--zsa-sh-lg); visibility: hidden; transform: translateX(105%); transition: transform .25s, visibility .25s; }
.zsa-drawer.is-open { visibility: visible; transform: none; }
body.admin-bar .zsa-drawer { top: 32px; height: calc(100% - 32px); } /* Administrateur connecté : sous la barre WordPress. */
.zsa-drawer.is-busy { opacity: .7; pointer-events: none; }
.zsa-shop.zsa-drawer h2 { display: flex; justify-content: space-between; align-items: center; margin: 0; padding: 18px 20px; border-bottom: 1px solid var(--zsa-line); font-size: 18px; }
.zsa-drawer__close { padding: 4px 8px; border: 0; background: none; color: var(--zsa-ink); font-size: 20px; cursor: pointer; }
.zsa-drawer__body { display: flex; flex: 1; flex-direction: column; min-height: 0; }
.zsa-drawer__items { flex: 1; padding: 12px 20px; overflow: auto; }
.zsa-citem { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--zsa-line); }
.zsa-citem__img { flex: none; width: 48px; height: 48px; overflow: hidden; border-radius: 10px; background: var(--zsa-bg); }
.zsa-shop .zsa-citem__img img { width: 100%; height: 100%; object-fit: contain; }
.zsa-citem__text { flex: 1; min-width: 0; }
.zsa-citem__text b { font-size: 14px; }
.zsa-citem__text div { color: var(--zsa-mut); font-size: 13px; }
.zsa-qty { display: flex; align-items: center; gap: 8px; }
.zsa-qty button { width: 28px; height: 28px; padding: 0; border: 1px solid var(--zsa-line); border-radius: 7px; background: var(--zsa-bg); color: var(--zsa-ink); font-size: 16px; line-height: 1; cursor: pointer; }
.zsa-drawer__foot { padding: 18px 20px; border-top: 1px solid var(--zsa-line); }
.zsa-drawer__total { font-size: 20px; }
.zsa-drawer__foot .zsa-btn { margin-top: 12px; }

@media (max-width: 860px) {
	.zsa-hero,
	.zsa-pdp,
	.zsa-checkout { grid-template-columns: 1fr; }
	.zsa-hero { padding: 30px 22px; }
	.zsa-hero__art { display: none; }
	.zsa-trust { grid-template-columns: 1fr 1fr; }
	.zsa-nav { display: none; }
	.zsa-navbar { flex-wrap: wrap; gap: 12px; padding: 12px 14px; }
	.zsa-searchbox { order: 3; flex: 1 1 100%; }
	.zsa-cart-btn { margin-left: auto; }
	.zsa-summary { position: static; }
	.zsa-pdp__gallery { height: 300px; }
}
@media (max-width: 520px) {
	.zsa-two,
	.zsa-radio-row { grid-template-columns: 1fr; }
	.zsa-pdp__cta { flex-direction: column; }
	.zsa-formcard,
	.zsa-summary,
	.zsa-thanks { padding: 20px; }
	.zsa-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; }
}
@media (prefers-reduced-motion: reduce) {
	.zsa-card,
	.zsa-drawer { transition: none; }
}
