/* ════════════════════════════════════════════════════════════
   formation-fiche.css — Pages fiche formation individuelles
   Dépend de home.css (variables CSS), nav-unified.css et
   blog-article.css (layout .article-page, .article-title, …)
   ════════════════════════════════════════════════════════════ */

/* ── Compensation de la navbar fixe (72px) ─────────────────
   Chaque gabarit du site compense lui-même la navbar `position:
   fixed`. Sans cette règle, le fil d'Ariane passe sous le logo. */
body:has(.fiche-breadcrumb) .article-page {
  padding-top: calc(72px + 2rem);
}

/* ── Bandeau de caractéristiques ───────────────────────────
   Exactement 3 colonnes : les 6 specs remplissent 2 rangées
   pleines. Avec `auto-fit`, les cellules manquantes de la
   dernière rangée laissaient apparaître le fond du conteneur. */
.fiche-specs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin: 2rem 0 2.5rem;
}
.fiche-spec {
  background: var(--white);
  padding: 1rem 1.25rem;
}
.fiche-spec-label {
  display: block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.3rem;
}
.fiche-spec-value {
  display: block;
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
}

/* ── Corps de la fiche ─────────────────────────────────────── */
.fiche-body {
  max-width: 760px;
}
.fiche-lead {
  font-size: 1.075rem;
  line-height: 1.75;
  color: var(--text);
  margin-bottom: 2.5rem;
}
.fiche-section {
  margin-bottom: 2.75rem;
}
.fiche-section > h2 {
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 1rem;
  color: var(--text);
}

/* ── Objectifs ─────────────────────────────────────────────── */
.fiche-objectifs {
  list-style: none;
  display: grid;
  gap: 0.75rem;
}
.fiche-objectifs li {
  position: relative;
  padding-left: 1.85rem;
  line-height: 1.65;
}
.fiche-objectifs li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.5em;
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 50%;
  background: var(--purple);
  box-shadow: 0 0 0 4px var(--purple-light);
}

/* ── Programme ─────────────────────────────────────────────── */
.fiche-programme {
  list-style: none;
  counter-reset: module;
  display: grid;
  gap: 0.75rem;
}
.fiche-module {
  counter-increment: module;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 1.1rem 1.25rem 1.1rem 3.6rem;
  position: relative;
  background: var(--white);
  transition: box-shadow var(--transition);
}
.fiche-module:hover {
  box-shadow: var(--shadow-card);
}
.fiche-module::before {
  content: counter(module);
  position: absolute;
  left: 1.1rem;
  top: 1.05rem;
  width: 1.75rem;
  height: 1.75rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--purple-light);
  color: var(--purple);
  font-size: 0.8rem;
  font-weight: 800;
}
.fiche-module h3 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.3rem;
}
.fiche-module p {
  font-size: 0.925rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin: 0;
}

/* ── Informations pratiques ────────────────────────────────── */
.fiche-infos {
  display: grid;
  gap: 1.25rem;
}
.fiche-infos > div {
  border-left: 3px solid var(--purple-light);
  padding-left: 1rem;
}
.fiche-infos dt {
  font-weight: 700;
  margin-bottom: 0.25rem;
}
.fiche-infos dd {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.65;
}

/* ── Avertissement ─────────────────────────────────────────── */
.fiche-avertissement {
  border: 1px solid var(--border);
  border-left: 3px solid var(--gold);
  background: #FFFBF3;
  border-radius: var(--radius-sm);
  padding: 1rem 1.25rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-top: 1.5rem;
}

/* ── FAQ ───────────────────────────────────────────────────── */
.fiche-faq {
  display: grid;
  gap: 1.25rem;
}
.fiche-faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 1.35rem 1.5rem;
}
.fiche-faq-item h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 0.6rem;
  color: var(--text);
}
.fiche-faq-item p {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.7;
}

/* ── Fil d'Ariane visible ──────────────────────────────────── */
.fiche-breadcrumb {
  font-size: 0.825rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}
.fiche-breadcrumb ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  padding: 0;
}
.fiche-breadcrumb li:not(:last-child)::after {
  content: "›";
  margin-left: 0.4rem;
  color: var(--border);
}
.fiche-breadcrumb a {
  color: var(--text-muted);
  text-decoration: none;
}
.fiche-breadcrumb a:hover {
  color: var(--purple);
}
.fiche-breadcrumb [aria-current="page"] {
  color: var(--text);
  font-weight: 600;
}

/* ── Formations liées ──────────────────────────────────────── */
.fiche-related {
  margin-top: 4rem;
  padding-top: 2.5rem;
  border-top: 1px solid var(--border);
}
.fiche-related-heading {
  font-size: 1.35rem;
  font-weight: 800;
  margin-bottom: 1.25rem;
}
.fiche-related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}
.fiche-related-card {
  display: block;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 1.15rem 1.25rem;
  text-decoration: none;
  transition: box-shadow var(--transition), transform var(--transition);
}
.fiche-related-card:hover {
  box-shadow: var(--shadow-card);
  transform: translateY(-2px);
}
.fiche-related-cat {
  display: block;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--purple);
  margin-bottom: 0.4rem;
}
.fiche-related-title {
  display: block;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.5rem;
}
.fiche-related-meta {
  display: block;
  font-size: 0.825rem;
  color: var(--text-muted);
}

@media (max-width: 900px) {
  body:has(.fiche-breadcrumb) .article-page {
    padding-top: calc(64px + 1.5rem);
  }
}

@media (max-width: 640px) {
  .fiche-specs {
    grid-template-columns: repeat(2, 1fr);
  }
}
