/* En-tête commun à toutes les pages Apting (catalogues, thématiques, fiches formation, parcours).
   Une seule source pour la typographie et les espacements : modifier une variable change toutes les pages.
   Chargé après la feuille propre à chaque modèle (pages.css / pages-cat.css) : à spécificité égale, ce fichier l'emporte. */

.apting-pg,
.apting-cat {
  --ap-h1-size: clamp(32px, 3.7vw, 50px);
  --ap-h1-weight: 500;
  --ap-h1-spacing: -.045em;
  --ap-h1-leading: 1.03;
  --ap-crumb-size: 13px;
  --ap-badge-border: 1px solid #ffffffe6;
  --ap-badge-padding: 8px 11px;
  --ap-lead-size: 15px;
  --ap-lead-weight: 500;
  --ap-lead-leading: 1.6;
  --ap-lead-width: 720px;
  --ap-accent: #e6007e;
}

/* Titre H1 */
.apting-pg .hero h1,
.apting-cat .catalogue-hero h1 {
  font-size: var(--ap-h1-size);
  font-weight: var(--ap-h1-weight);
  letter-spacing: var(--ap-h1-spacing);
  line-height: var(--ap-h1-leading);
}
.apting-pg .hero h1 { max-width: none; }
.apting-cat .catalogue-hero h1 strong { font-weight: var(--ap-h1-weight); }

/* Fil d'Ariane */
.apting-pg .hero .breadcrumbs,
.apting-cat .hero nav.catalogue-breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 8px;
  margin: 0;
  color: #fff;
  font-size: var(--ap-crumb-size);
  line-height: 1.5;
  opacity: .92;
  white-space: normal;
  overflow: visible;
}
.apting-pg .hero .breadcrumbs :is(a, span),
.apting-cat .hero nav.catalogue-breadcrumbs :is(a, span) { color: #fff; font-size: inherit; }
.apting-pg .hero .breadcrumbs svg,
.apting-cat .hero nav.catalogue-breadcrumbs svg { width: 12px; min-width: 12px; height: 12px; }

/* Rectangle d'étiquette (CATALOGUE / THÉMATIQUE / FORMATION / PARCOURS MÉTIER) */
.apting-pg .hero .level-label,
.apting-cat .catalogue-hero .catalogue-label {
  display: inline-flex;
  width: auto;
  padding: var(--ap-badge-padding);
  border: var(--ap-badge-border);
  background: transparent;
  color: #fff;
}
.apting-pg .hero .level-label { margin: 26px 0 14px; }
.apting-cat .catalogue-hero .catalogue-label { margin: 14px 0; padding-block: 7px; }

/* Description sous le titre */
.apting-pg .hero .lead,
.apting-cat .catalogue-hero .management-hero__lead {
  display: block;
  max-width: var(--ap-lead-width);
  color: #fff;
  opacity: 1;
  font-size: var(--ap-lead-size);
  font-weight: var(--ap-lead-weight);
  line-height: var(--ap-lead-leading);
}
.apting-pg .hero .lead { margin: 3px 0 0; padding-block: 24px; }
.apting-cat .catalogue-hero .management-hero__lead { margin: 27px 0 0; }

/* Espacements de l'en-tête */
.apting-pg .hero .hero-inner { padding: 32px 48px 9px 0; }
@media (max-width: 900px) { .apting-pg .hero .hero-inner { padding-right: 18px; } }
@media (max-width: 700px) { .apting-pg .hero .hero-inner { padding-right: 16px; } }
@media (max-width: 380px) { .apting-pg .hero .hero-inner { padding-right: 12px; } }
.apting-cat .catalogue-hero .catalogue-crumb-row { padding-top: 32px; }

/* Surtitres roses (« AU SEIN DE… », « DANS CE CATALOGUE ») */
.apting-pg .eyebrow,
.apting-cat .catalogue-eyebrow {
  margin: 0 0 14px;
  color: var(--ap-accent);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .15em;
}
.apting-cat .catalogue-overview { padding-top: 14px; }

/* En-tête sans photo (fiche formation, page Sectoriel) : une colonne, alignée sur le container, sans hauteur minimale */
.apting-pg--plain .hero { display: block; min-height: var(--ap-hero-min, 0) !important; /* les modèles historiques imposent une hauteur minimale en !important */ grid-template-columns: none; }
.apting-pg--plain .hero .hero-copy { width: 100%; max-width: none; padding-inline: max(24px, 50vw - 636px) 24px; }
.apting-pg--plain .hero .hero-inner { width: 100%; max-width: none; margin: 0; padding: 32px 0; }
.apting-pg--plain .hero .breadcrumbs { width: 100%; max-width: none; }
.apting-pg--plain .hero h1 { margin: 0; }
.apting-pg--plain .hero .level-label { margin: 26px 0 14px; }
.apting-pg--plain .hero .lead { margin-top: 27px; padding-block: 0; }
@media (max-width: 1000px) { .apting-pg--plain .hero .hero-copy { padding-inline: 18px; } }

/* Bas de page commun : « Réserver une séance », Financements, Nos forfaits (partials/bottom-blocks.php) */
.apting-pg .ap-book{display:flex;align-items:center;justify-content:space-between;gap:24px;margin:70px 0;padding:32px;background:#000;color:#fff}
.apting-pg .ap-book h2{margin:0;color:#fff;font-size:clamp(22px,2.4vw,30px);font-weight:700;line-height:1.2}
.apting-pg .ap-bottom{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-top:12px}
.apting-pg .ap-box{display:grid;align-content:start;gap:14px;padding:32px;border:1px solid #d7d7d7;border-left:5px solid var(--blue);background:#fff;color:#222}
.apting-pg .ap-box h2{margin:0;font-size:clamp(22px,2.2vw,28px);font-weight:700;line-height:1.2;color:#111}
.apting-pg .ap-box p{margin:0;font-size:15px;line-height:1.65}
.apting-pg .ap-box--dark{background:#000;border-color:#000;border-left-color:var(--blue);color:#fff}
.apting-pg .ap-box--dark h2,.apting-pg .ap-box--dark p{color:#fff}
.apting-pg main a.ap-btn,.apting-pg main a.ap-btn:hover,.apting-pg main a.ap-btn:focus{display:inline-flex;align-items:center;justify-content:center;gap:10px;justify-self:start;min-height:46px;padding:12px 24px;background:#d42f80;color:#fff;font-size:14px;font-weight:700;text-decoration:none}
.apting-pg main a.ap-btn--dark,.apting-pg main a.ap-btn--dark:hover{background:#000}
.apting-pg .ap-btn svg{width:16px;height:16px}
@media (max-width: 760px) { .apting-pg .ap-bottom { grid-template-columns: minmax(0, 1fr); } .apting-pg .ap-book { flex-direction: column; align-items: flex-start; padding: 24px 20px; } .apting-pg .ap-box { padding: 24px 20px; } }

/* Bloc de texte libre (page Sectoriel) */
.apting-pg .ap-seo { margin-top: 40px; padding: 28px 32px; border: 1px solid #d7d7d7; border-left: 5px solid var(--blue); background: #fff; }
.apting-pg .ap-seo__body > :first-child { margin-top: 0; }
.apting-pg .ap-seo__body > :last-child { margin-bottom: 0; }

/* Fenêtre « Voir le programme » : phrase d'introduction des parcours métiers (avant les objectifs) */
.apting-pg .career-program-modal__intro,
.apting-cat .career-program-modal__intro {
  margin: 0 0 16px;
  padding: 14px 16px;
  border-left: 3px solid var(--ap-accent);
  background: #f4f4f4;
  color: #222;
  font-size: 14px;
  line-height: 1.55;
}

/* Dans la boîte « Nos tarifs » (fond couleur du domaine), le bouton est blanc */
.apting-pg main .ap-box--accent a.ap-btn,
.apting-pg main .ap-box--accent a.ap-btn:is(:hover, :focus) { background: #fff; color: #111; }

/* Bande des chiffres clés (pages thématiques et catalogues) */
.ap-stats { display: grid; grid-template-columns: repeat(4, 1fr); margin: 0 0 56px; background: var(--band-color, #49a1ad); }
.ap-stats > div { display: flex; flex-direction: column; justify-content: center; gap: 9px; min-height: 120px; padding: 24px 30px; border-right: 1px solid rgba(255, 255, 255, .3); color: #fff; }
.ap-stats > div:last-child { border-right: 0; }
.ap-stats strong { font-size: clamp(26px, 3vw, 38px); font-weight: 700; line-height: 1; }
.ap-stats span { font-size: 13px; }
@media (max-width: 760px) {
  .ap-stats { grid-template-columns: 1fr 1fr; margin-bottom: 40px; }
  .ap-stats > div { min-height: 96px; padding: 18px 20px; border-right: 0; border-bottom: 1px solid rgba(255, 255, 255, .3); }
}

/* Le pied de page du site a une marge haute de 100 px (bande blanche) : sous nos pages elle est supprimée, le bloc noir suit directement le contenu */
.apting-pg ~ footer .elementor-element.elementor-element-89e8488,
.apting-cat ~ footer .elementor-element.elementor-element-89e8488 { --margin-top: 0px; margin-top: 0; }
