/* Pattern: Pillars — rangée d'avantages icône + titre + description */
/* Fidèle maquette v2 (.pillars / .pillar) : 4 colonnes, icône carrée à gauche, */
/* titre + description à droite. Section bas de page Contact.                    */

.mau-pillars-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--wp--preset--spacing--24);
}

/* Réemploi 6-items (hub-indep, #38) : repeat(4,1fr) est hardcodé pour le bloc
   4-piliers de la page Contact et produit un 4+2 avec 6 items. Override scopé
   :has() (même patron que le fix escalier mau-included.css) : si un 5e .mau-pillar
   enfant direct existe, la grille bascule à 3 colonnes (2 rangées de 3). Le cas
   Contact (4 items, pas de 5e enfant) n'est pas affecté. */
.mau-pillars-grid:has(> .mau-pillar:nth-child(5)) {
  grid-template-columns: repeat(3, 1fr);
}

.mau-pillar {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.mau-pillar__icon {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--wp--preset--color--accent);
}

.mau-pillar__icon svg {
  width: 20px;
  height: 20px;
}

.mau-pillar__title {
  margin: 0 0 6px;
  font-family: var(--wp--preset--font-family--inter);
  font-size: 17px;
  font-weight: 600;
  line-height: 1.3;
  color: var(--wp--preset--color--ink);
}

.mau-pillar__desc {
  margin: 0;
  font-size: 13px;
  line-height: 1.55;
  color: var(--wp--preset--color--slate);
}

/* Sur fond sombre (sections ink : hub-indep #38, particulier-frontalier #39), le
   titre ink devient invisible (encre sur encre) → passe en paper. Le desc slate
   reste lisible. Scopé au contexte ink pour ne pas toucher les pillars sur fond
   clair (page Contact) où color:ink est correct. */
.has-ink-background-color .mau-pillar__title {
  color: var(--wp--preset--color--paper);
}

@media (min-width: 768px) and (max-width: 1099px) {
  .mau-pillars-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: var(--wp--preset--spacing--24);
  }
  .mau-pillars-grid:has(> .mau-pillar:nth-child(5)) {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 767px) {
  /* Maquette mobile : 2 colonnes, gap 20px, icône au-dessus, texte centré */
  .mau-pillars-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--wp--preset--spacing--20);
  }

  .mau-pillar {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: var(--wp--preset--spacing--12);
  }

  .mau-pillar__title { font-size: 15px; }
  .mau-pillar__desc  { font-size: 12px; }
}
