/**
 * Fiche produit et pages catalogue (planches du 28/09/2026).
 */

/* ---------------- fiche produit ---------------- */

.ats-fiche2 { padding: 22px 0 10px; }
.ats-fiche2 .ats-ariane { margin-bottom: 22px; }
.ats-fiche2__haut { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, 1fr); gap: 34px; align-items: start; }
.ats-galerie { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 16px; }
.ats-galerie__vignettes { display: flex; flex-direction: column; gap: 10px; max-height: 540px; overflow: hidden; }
.ats-galerie__vignettes.est-deplie { max-height: none; }
.ats-galerie__vign { padding: 4px; width: 84px; height: 84px; border: 1px solid var(--m-trait); border-radius: 6px; background: #fff; cursor: pointer; flex: none; }
.ats-galerie__vign img { width: 100%; height: 100%; object-fit: contain; }
.ats-galerie__vign.est-actif { border: 2px solid var(--m-petrole); }
.ats-galerie__plus { background: none; border: 0; padding: 4px; cursor: pointer; color: var(--m-encre); }
.ats-galerie__principale { position: relative; border: 1px solid var(--m-trait); border-radius: 8px; background: #fff; aspect-ratio: 1 / .9; display: flex; align-items: center; justify-content: center; padding: 24px; box-sizing: border-box; }
.ats-galerie__img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; cursor: zoom-in; }
.ats-galerie__zoom { position: absolute; right: 14px; bottom: 14px; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--m-trait); background: #fff; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; color: var(--m-encre); }
.ats-galerie__zoom .ats-ico { width: 20px; height: 20px; }
.ats-visionneuse { position: fixed; inset: 0; z-index: 300; background: rgba(20, 30, 36, .88); display: flex; align-items: center; justify-content: center; padding: 30px; }
.ats-visionneuse[hidden] { display: none; }
.ats-visionneuse img { max-width: 92vw; max-height: 88vh; background: #fff; border-radius: 8px; }
.ats-visionneuse__fermer { position: absolute; top: 18px; right: 18px; background: #fff; border: 0; border-radius: 50%; width: 44px; height: 44px; cursor: pointer; }

.ats-fiche2__marque { margin: 0 0 4px; }
.ats-fiche2__marque a { color: var(--m-petrole) !important; font-weight: 700; font-size: 17px; text-decoration: none !important; }
.ats-fiche2__titre { margin: 0 0 10px !important; font-size: clamp(26px, 2.2vw, 33px) !important; line-height: 1.18 !important; font-weight: 800 !important; color: var(--m-encre); letter-spacing: -.01em; }
.ats-fiche2__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0 0 14px; font-size: 14.5px; color: var(--m-doux); }
.ats-fiche2__sep { color: #C9D2D3; }
.ats-stock { display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: 999px; font-weight: 600; font-size: 14px; }
.ats-stock--oui { background: #E3F2EA; color: #1C6B45; }
.ats-stock--oui .ats-ico { width: 16px; height: 16px; color: #1F9A62; }
.ats-stock--non { background: #F7EEDC; color: #8A5A07; }
.ats-fiche2__resume { margin: 0 0 18px; color: var(--m-texte); font-size: 16.5px; line-height: 1.6; }
.ats-tarif { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 18px; border-radius: 8px; background: #F1F6F6; margin-bottom: 16px; }
.ats-tarif__titre { margin: 0; font-weight: 700; font-size: 16px; color: var(--m-encre); }
.ats-tarif__prix { margin: 2px 0 0; font-size: 26px; font-weight: 800; color: #0A3E47; }
.ats-tarif__prix small { font-size: 15px; font-weight: 600; color: var(--m-doux); }
.ats-tarif__txt { margin: 4px 0 0; font-size: 14px; color: var(--m-doux); }
.ats-tarif .ats-bouton { flex: none; background: #fff; min-height: 46px; }
.ats-fiche2 .wy-pro-paliers { margin: 0 0 16px; }

.ats-fiche2__panier { display: flex; gap: 12px; align-items: stretch; margin-bottom: 12px; }
.ats-fiche2__panier form.cart { display: flex; gap: 12px; align-items: stretch; flex-wrap: wrap; width: 100%; margin: 0 !important; }
.ats-fiche2__panier form.variations_form { display: block; }
.ats-fiche2__panier .variations { width: 100%; margin-bottom: 12px; }
.ats-fiche2__panier .variations select { min-height: 44px; padding: 0 12px; border: 1px solid #D5DEDF; border-radius: 5px; font: inherit; }
.ats-fiche2__panier .woocommerce-variation-add-to-cart { display: flex; gap: 12px; width: 100%; }
.ats-fiche2__panier .quantity, .ats-qte { display: inline-flex; align-items: stretch; border: 1px solid #D5DEDF; border-radius: 6px; overflow: hidden; background: #fff; flex: none; }
.ats-fiche2__panier .quantity input.qty { width: 54px; border: 0 !important; text-align: center; font: 600 17px 'Archivo', Arial, sans-serif; -moz-appearance: textfield; }
.ats-fiche2__panier .quantity input.qty::-webkit-inner-spin-button { -webkit-appearance: none; }
.ats-qte-b, .ats-qte button { width: 48px; border: 0; background: #F6F8F8; font-size: 22px; cursor: pointer; color: var(--m-encre); display: inline-flex; align-items: center; justify-content: center; }
.ats-qte span { display: inline-flex; align-items: center; justify-content: center; width: 54px; font-weight: 600; font-size: 17px; }
.ats-fiche2__panier .single_add_to_cart_button, .ats-fiche2__ajout { flex: 1; min-height: 56px !important; font-size: 18px !important; border-radius: 6px !important; }
.ats-fiche2__ajout .ats-ico { width: 24px; height: 24px; }
.ats-fiche2__secondaires { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 18px; }
.ats-fiche2__secondaires .ats-bouton { min-height: 54px; font-size: 16px; }
.ats-bouton--wa { color: var(--m-petrole) !important; }
.ats-fiche2__rassure { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.ats-fiche2__rassure li { display: flex; gap: 12px; align-items: flex-start; }
.ats-fiche2__rassure .ats-ico { width: 32px; height: 32px; color: var(--m-encre); }
.ats-fiche2__rassure b { display: block; font-size: 14.5px; color: var(--m-encre); }
.ats-fiche2__rassure span span { font-size: 13.5px; color: var(--m-doux); line-height: 1.35; }

.ats-atouts-fiche { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: 28px; }
.ats-atouts-fiche > div { display: flex; gap: 18px; align-items: center; padding: 20px 22px; border: 1px solid var(--m-trait); border-radius: 6px; background: #fff; }
.ats-atouts-fiche .ats-ico { width: 38px; height: 38px; color: var(--m-encre); flex: none; }
.ats-atouts-fiche b { display: block; font-size: 16px; color: var(--m-encre); }
.ats-atouts-fiche span span { font-size: 14.5px; color: var(--m-doux); line-height: 1.4; }

.ats-onglets-sec { border-top: 1px solid var(--m-trait); margin-top: 22px; padding-bottom: 14px; }
.ats-onglets { display: flex; gap: 6px; border-bottom: 1px solid var(--m-trait); margin-bottom: 20px; }
.ats-onglets button { background: none; border: 0; border-bottom: 3px solid transparent; padding: 16px 28px; font: 500 17px 'Archivo', Arial, sans-serif; color: var(--m-encre); cursor: pointer; margin-bottom: -1px; }
.ats-onglets button[aria-selected="true"] { color: var(--m-petrole); font-weight: 700; border-bottom-color: var(--m-petrole); }
.ats-onglet { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 40px; border: 1px solid var(--m-trait); border-radius: 8px; padding: 26px 28px; }
.ats-onglet[hidden] { display: none; }
.ats-onglet__texte h2 { margin: 0 0 12px !important; font-size: 21px !important; font-weight: 700 !important; }
.ats-onglet__texte p { color: var(--m-texte); font-size: 16px; line-height: 1.65; margin: 0 0 12px; }
.ats-plus-produit { background: #F1F6F6; border-radius: 8px; padding: 22px 24px; }
.ats-plus-produit__titre { margin: 0 0 12px; font-size: 21px; font-weight: 700; color: var(--m-encre); }
.ats-caracs { grid-column: 1 / -1; width: 100%; border-collapse: collapse; }
.ats-caracs th, .ats-caracs td { padding: 11px 14px; border-bottom: 1px solid var(--m-trait); text-align: left; font-size: 15.5px; }
.ats-caracs th { width: 34%; color: var(--m-encre); font-weight: 600; background: #F8FAFA; }
.ats-caracs td { color: var(--m-texte); }
#pan-car, #pan-liv { grid-template-columns: 1fr; }

/* ---------------- catalogue ---------------- */

.ats-hero3--catalogue .ats-hero3__in { min-height: 300px; }
.ats-hero3__desc p { font-size: 18px; line-height: 1.5; color: var(--m-texte); margin: 0 0 8px; max-width: 640px; }
.ats-chips-sec { margin-top: -24px; position: relative; z-index: 2; }
.ats-chips { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); background: #fff; border: 1px solid var(--m-trait); border-radius: 8px; box-shadow: 0 10px 30px rgba(27, 42, 51, .06); padding: 12px; gap: 0; }
.ats-chips a { display: flex; align-items: center; gap: 14px; padding: 6px 14px; border-left: 1px solid var(--m-trait); text-decoration: none !important; color: var(--m-encre) !important; font-weight: 600; font-size: 16px; }
.ats-chips a:first-child { border-left: 0; }
.ats-chips a .ats-petit { margin-left: auto; }
.ats-chips a:hover { color: var(--m-petrole) !important; }

.ats-catalogue { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 24px; align-items: start; }
.ats-filtres { background: #F6F8F8; border-radius: 8px; padding: 16px 18px; position: sticky; top: 80px; }
.ats-filtres__tete { display: flex; justify-content: space-between; align-items: baseline; padding-bottom: 10px; border-bottom: 1px solid var(--m-trait); }
.ats-filtres__tete p { margin: 0; font-size: 18px; font-weight: 700; color: var(--m-encre); }
.ats-filtres__tete a { color: var(--m-petrole) !important; font-size: 14.5px; }
.ats-filtre { border-bottom: 1px solid var(--m-trait); padding: 6px 0; }
.ats-filtre:last-of-type { border-bottom: 0; }
.ats-filtre summary { list-style: none; display: flex; justify-content: space-between; align-items: center; padding: 10px 0; font-size: 16px; font-weight: 700; color: var(--m-encre); cursor: pointer; }
.ats-filtre summary::-webkit-details-marker { display: none; }
.ats-filtre__chev { width: 18px !important; height: 18px !important; transition: transform .15s ease; transform: rotate(180deg); }
.ats-filtre:not([open]) .ats-filtre__chev { transform: none; }
.ats-filtre ul { list-style: none; margin: 0 0 8px; padding: 0; }
.ats-filtre li { margin: 8px 0; }
.ats-filtre label { display: flex; align-items: center; gap: 10px; font-size: 15px; color: var(--m-texte); cursor: pointer; }
.ats-filtre label span { color: var(--m-doux); }
.ats-filtre input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--m-petrole); margin: 0; }

.ats-catalogue__tete { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }
.ats-catalogue__tete h2 { margin: 0 !important; font-size: 26px !important; font-weight: 800 !important; }
.ats-catalogue__tete h2 span { font-size: 17px; font-weight: 400; color: var(--m-texte); }
.ats-tri { display: flex; align-items: center; gap: 10px; font-size: 15px; color: var(--m-texte); }
.ats-tri select { min-height: 42px; padding: 0 36px 0 14px; border: 1px solid #D5DEDF; border-radius: 5px; font: 15px 'Archivo', Arial, sans-serif; background: #fff; }
.ats-selection--catalogue { grid-template-columns: repeat(4, 1fr); gap: 12px; }
.ats-vide p { margin: 0 0 6px; color: var(--m-texte); }
.ats-pagination { display: flex; justify-content: center; gap: 8px; margin: 22px 0 6px; }
.ats-pagination a, .ats-pagination span { display: inline-flex; align-items: center; justify-content: center; min-width: 40px; height: 40px; padding: 0 8px; border: 1px solid var(--m-trait); border-radius: 5px; background: #fff; color: var(--m-encre) !important; text-decoration: none !important; font-weight: 600; box-sizing: border-box; }
.ats-pagination span[aria-current] { background: var(--m-petrole); border-color: var(--m-petrole); color: #fff !important; }
.ats-pagination a:first-child .ats-inverse { transform: rotate(180deg); }
.ats-pagination .ats-ico { width: 18px; height: 18px; color: var(--m-petrole); }
.ats-avant__liste--boite { border: 1px solid var(--m-trait); border-radius: 8px; padding: 18px 20px; background: #fff; }

@media (max-width: 1100px) {
  .ats-fiche2__haut { grid-template-columns: 1fr; }
  .ats-atouts-fiche, .ats-selection--catalogue { grid-template-columns: repeat(2, 1fr); }
  .ats-catalogue { grid-template-columns: 1fr; }
  .ats-filtres { position: static; }
  .ats-chips { grid-template-columns: repeat(2, 1fr); row-gap: 10px; }
}
@media (max-width: 700px) {
  .ats-galerie { grid-template-columns: 1fr; }
  .ats-galerie__vignettes { flex-direction: row; order: 2; max-height: none; overflow-x: auto; }
  .ats-galerie__vign { width: 64px; height: 64px; }
  .ats-fiche2__secondaires, .ats-fiche2__rassure, .ats-atouts-fiche { grid-template-columns: 1fr; }
  .ats-tarif { flex-direction: column; align-items: flex-start; }
  .ats-onglet { grid-template-columns: 1fr; padding: 18px; gap: 20px; }
  .ats-onglets button { padding: 12px 14px; font-size: 15.5px; }
  .ats-chips { grid-template-columns: 1fr; }
  .ats-chips a { border-left: 0; }
}

.ats-galerie__img { width: 86% !important; height: auto !important; max-height: 100%; }
.ats-carte2__prix--plage { font-size: 17px !important; white-space: nowrap; }
.ats-selection--6 .ats-carte2__prix--plage { font-size: 14px !important; }

/* Filtres repliés sous 1100 px */
.ats-filtres__ouvrir { display: none; }
@media (max-width: 1100px) {
  .ats-filtres { padding: 0; background: none; }
  .ats-filtres__ouvrir { display: inline-flex; align-items: center; gap: 8px; padding: 11px 18px; border: 1px solid var(--m-petrole); border-radius: 6px; background: #fff; color: var(--m-petrole); font: inherit; font-weight: 600; font-size: 15.5px; cursor: pointer; }
  .ats-filtres__ouvrir .ats-ico { width: 18px; height: 18px; }
  .ats-filtres__ouvrir span { background: var(--m-petrole); color: #fff; border-radius: 10px; padding: 0 7px; font-size: 13px; }
  .ats-filtres__tete, .ats-filtre { display: none; }
  .ats-filtres.est-ouvert { background: #F6F8F8; padding: 16px 18px; border-radius: 8px; }
  .ats-filtres.est-ouvert .ats-filtres__ouvrir { margin-bottom: 12px; }
  .ats-filtres.est-ouvert .ats-filtres__tete { display: flex; }
  .ats-filtres.est-ouvert .ats-filtre { display: block; }
}
@media (max-width: 700px) {
  .ats-hero3--catalogue .ats-hero3__visuel { min-height: 200px; }
  .ats-hero3--catalogue .ats-hero3__texte { padding-bottom: 0; }
  .ats-selection--catalogue .ats-carte2__prix--plage { font-size: 14px !important; }
}

/* Message d'accès sous le bouton de la fiche */
.ats-fiche2__panier { flex-wrap: wrap; }
.ats-fiche2__acces { flex-basis: 100%; margin: 4px 0 0; font-size: 14.5px; line-height: 1.5; color: var(--m-texte); }
.ats-fiche2__acces a { color: var(--m-petrole) !important; font-weight: 600; }
.ats-fiche2__panier .wy-pro-acces { flex-basis: 100%; }

/* Familles du catalogue : autant de colonnes que de familles, sur une ligne */
.ats-chips { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); }
@media (max-width: 1100px) { .ats-chips { grid-auto-flow: row; grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 700px) { .ats-chips { grid-template-columns: 1fr; } }
/* Le bandeau des familles mord sur le hero : la composition s'arrête au-dessus */
.ats-hero3--catalogue .ats-hero3__visuel .ats-compo { inset: 14px 0 40px; }
@media (max-width: 1100px) { .ats-selection--catalogue { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.ats-carte2 { min-width: 0; }
.ats-carte2 h3, .ats-carte2__lignes { overflow-wrap: anywhere; }

/* Petits écrans (360 px) */
@media (max-width: 1100px) { .ats-hero3__in { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 700px) {
  .ats-onglets { overflow-x: auto; scrollbar-width: none; }
  .ats-onglets button { flex: 0 0 auto; }
}
@media (max-width: 400px) {
  .ats-onglets button { padding: 12px 10px; font-size: 14.5px; }
  .ats-selection--catalogue { gap: 10px; }
  .ats-selection--catalogue .ats-carte2__pied { gap: 6px; }
  .ats-selection--catalogue .ats-carte2__prix { font-size: 16px !important; }
  .ats-selection--catalogue .ats-carte2__prix--plage { font-size: 13px !important; white-space: normal; }
  .ats-selection--catalogue .ats-carte2__panier { width: 36px; height: 36px; flex: 0 0 36px; }
}
.ats-hero3--catalogue .ats-hero3__visuel .ats-compo { inset: 14px 0 40px auto; }
.ats-hero3--catalogue .ats-hero3__in { min-height: 330px; }
@media (max-width: 1100px) { .ats-hero3--catalogue .ats-hero3__visuel .ats-compo { inset: 0 0 26px auto; } .ats-hero3--catalogue .ats-hero3__visuel:has(.ats-compo) { aspect-ratio: 2.1 / 1; } }
