/* ==================================================================== *
 * Sections partagées par l'accueil pros, les pages particuliers,
 * hôtellerie et postes de secours : « Monter d'un niveau » et les grilles
 * de schémas, les figures illustrées, la FAQ rangée par thème. Chargée après hoummi-branches.css.
 * ==================================================================== */

/* --- Monter d'un niveau ---------------------------------------------- */

.hm-etage {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr);
  gap: clamp(28px, 4vw, 64px);
  align-items: start;
  margin-top: clamp(28px, 4vw, 48px);
}

.hm-etage__photo {
  margin: 0;
  position: sticky;
  top: calc(var(--nav) + 24px);
}

.hm-etage__photo img {
  display: block;
  width: 100%;
  height: auto;
}

.hm-etage__photo figcaption {
  margin-top: 10px;
  font-size: 13px;
  color: var(--hm-encre-tenue);
}

.hm-etage__schemas {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px 28px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.hm-etage__schema img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 520 / 340;
}

.hm-etage__schema h3 {
  margin: 8px 0 4px;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.3;
}

.hm-etage__schema p {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.45;
  color: var(--hm-encre-douce);
}

@media (max-width: 960px) {
  .hm-etage { grid-template-columns: minmax(0, 1fr); }
  .hm-etage__photo { position: static; }
}

@media (max-width: 480px) {
  .hm-etage__schemas { gap: 18px 14px; }
  .hm-etage__schema h3 { font-size: 15px; }
  .hm-etage__schema p { font-size: 13.5px; }
}

/* --- FAQ rangée par thème -------------------------------------------- */

.hm-faq-themes {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 24px 0 8px;
  padding: 0;
  list-style: none;
}

.hm-faq-themes a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid var(--hm-noir);
  border-radius: var(--hm-r);
  color: var(--hm-noir);
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  text-decoration: none;
}

.hm-faq-themes a:hover {
  background: var(--hm-noir);
  color: var(--hm-blanc);
}

.hm-faq-groupe {
  margin-top: clamp(28px, 4vw, 48px);
  scroll-margin-top: calc(var(--nav) + 16px);
}

.hm-faq-groupe__t {
  margin: 0 0 12px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--hm-vert-lisible);
}

/* --- Figures pleine largeur et schémas sur panneau blanc ------------- */

.hm-illu {
  margin: clamp(20px, 3vw, 36px) 0;
}

.hm-illu img {
  display: block;
  width: 100%;
  height: auto;
}

.hm-illu figcaption {
  margin-top: 10px;
  font-size: 13px;
  color: var(--hm-encre-tenue);
}

.hm-illu--large img {
  aspect-ratio: 2 / 1;
  object-fit: cover;
}

/* Schémas sur fond blanc : posés sur un panneau blanc, y compris dans la
   section noire, pour garder leurs traits lisibles. */
.hm-illu--panneau {
  background: var(--hm-blanc);
  padding: clamp(16px, 2.4vw, 32px);
}

.hm-illu--panneau img {
  max-height: 420px;
  object-fit: contain;
}

.hm-illu--petit { margin-top: 20px; }

.hm-illu--petit img { max-height: 320px; }

/* Six schémas sur trois colonnes, sans photo (hôtellerie, postes de secours). */
.hm-etage__schemas--trois {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: clamp(24px, 3vw, 40px);
}

@media (max-width: 960px) {
  .hm-etage__schemas--trois { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
