/* ==========================================================================
   Socle visuel des pages intégrées d'après les maquettes validées du 26/11/2026.
   Jetons : Documentation/SEO/refonte-2026/maquettes/validees/00-charte/ds/toofrench/tokens.json
   Les familles ajoutent leurs sections dans assets/css/maquettes-<famille>.css,
   avec les variables ci-dessous (jamais de couleur en dur hors de cette liste).
   Point de rupture unique : 768px (planche mobile = 390px).
   ========================================================================== */

:root {
  --tf-marine: #0F172A;
  --tf-emeraude: #059669;
  --tf-emeraude-fonce: #047857;
  --tf-emeraude-pale: #ECFDF5;
  --tf-encre: #1E293B;
  --tf-encre-secondaire: #475569;
  --tf-encre-tertiaire: #64748B;
  --tf-fond: #FFFFFF;
  --tf-fond-doux: #F8FAFC;
  --tf-bordure: #CBD5E1;
  --tf-bordure-claire: #E2E8F0;
  --tf-ambre-pale: #FEF3C7;
  --tf-pied-texte: #CBD5E1;
  --tf-pied-discret: #94A3B8;
  --tf-pied-filet: #334155;

  --tf-police: Inter, -apple-system, system-ui, "Segoe UI", Roboto, Arial, sans-serif;
  --tf-largeur: 1312px;     /* contenu 1184px + 2 × 64px */
  --tf-gouttiere: 64px;
  --tf-rayon-sm: 8px;
  --tf-rayon-md: 10px;
  --tf-rayon-lg: 20px;
  --tf-rayon-pilule: 999px;
  --tf-section: 96px;       /* espace vertical entre grandes sections (ordinateur) */
}
@media (max-width: 767px) {
  :root { --tf-gouttiere: 20px; --tf-section: 56px; }
}

/* ---------- Enveloppe ---------- */
.tfm { font-family: var(--tf-police); color: var(--tf-encre); background: var(--tf-fond); }
.tfm *, .tfm *::before, .tfm *::after { box-sizing: border-box; }
.tfm a { color: var(--tf-emeraude-fonce); }
.tfm a:hover { color: var(--tf-marine); }
.tfm img { max-width: 100%; height: auto; }

/* Conteneur centré : à poser sur un bloc Groupe (className « tfm-wrap »). */
.tfm-wrap { max-width: var(--tf-largeur); margin-left: auto; margin-right: auto; padding-left: var(--tf-gouttiere); padding-right: var(--tf-gouttiere); }
.tfm-wrap--etroit { max-width: calc(880px + 2 * var(--tf-gouttiere)); }

/* Sections : bloc Groupe pleine largeur (className « tfm-section » + variante). */
.tfm-section { padding-top: var(--tf-section); padding-bottom: var(--tf-section); }
.tfm-section--doux { background: var(--tf-fond-doux); }
.tfm-section--pale { background: var(--tf-emeraude-pale); }
.tfm-section--marine { background: var(--tf-marine); color: #FFFFFF; }
.tfm .tfm-section--marine h1, .tfm .tfm-section--marine h2, .tfm .tfm-section--marine h3, .tfm .tfm-section--marine h4, .tfm .tfm-section--marine strong { color: #FFFFFF; }
.tfm-section--marine p { color: var(--tf-pied-texte); }
.tfm-section--marine a { color: #FFFFFF; }
.tfm-section--serre { padding-top: 48px; padding-bottom: 48px; }

/* WordPress ajoute des marges de bloc : on les neutralise dans les pages intégrées. */
.tfm .wp-block-group, .tfm .wp-block-columns { margin-top: 0; margin-bottom: 0; }
.tfm .wp-block-columns { gap: 40px; }
/* Thème classique : WordPress enveloppe l'intérieur de chaque bloc Groupe dans
   .wp-block-group__inner-container. On l'efface pour que grilles et flex voient les vrais enfants. */
.tfm .wp-block-group__inner-container { display: contents; }

/* ---------- Typographie (planche ordinateur → mobile) ---------- */
.tfm h1, .tfm h2, .tfm h3, .tfm h4 { font-family: var(--tf-police); color: var(--tf-marine); margin: 0; font-weight: 900; }
.tfm h1 { font-size: 68px; line-height: 1; letter-spacing: -0.045em; }
.tfm h2 { font-size: 44px; line-height: 48px; letter-spacing: -0.04em; }
.tfm h3 { font-size: 26px; line-height: 30px; letter-spacing: -0.03em; }
.tfm h4 { font-size: 20px; line-height: 26px; font-weight: 800; letter-spacing: -0.01em; }
.tfm p, .tfm li { font-size: 18px; line-height: 29px; }
.tfm p { margin: 0; }
.tfm p + p, .tfm h2 + p, .tfm h3 + p { margin-top: 14px; }
.tfm ul, .tfm ol { margin: 14px 0 0; padding-left: 1.2em; }
.tfm strong { font-weight: 800; color: var(--tf-marine); }

.tfm-surtitre { display: inline-block; font-size: 13px; line-height: 16px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--tf-emeraude-fonce); }
.tfm-surtitre--pastille { background: var(--tf-emeraude-pale); padding: 8px 14px; border-radius: var(--tf-rayon-pilule); }
.tfm-chapo { font-size: 21px !important; line-height: 32px !important; color: var(--tf-encre-secondaire); }
.tfm-petit { font-size: 14px !important; line-height: 21px !important; color: var(--tf-encre-tertiaire); }
.tfm-surligne { background: var(--tf-ambre-pale); padding: 0 4px; border-radius: 4px; }

@media (max-width: 767px) {
  .tfm h1 { font-size: 35px; line-height: 37px; }
  .tfm h2 { font-size: 30px; line-height: 34px; }
  .tfm h3 { font-size: 22px; line-height: 27px; }
  .tfm p, .tfm li { font-size: 17px; line-height: 27px; }
  .tfm-chapo { font-size: 18px !important; line-height: 28px !important; }
}

/* ---------- Bouton unique « Commencer gratuitement » ---------- */
.tfm-btn, .tfm a.tfm-btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 0 28px;
  border-radius: var(--tf-rayon-pilule); background: var(--tf-emeraude-fonce); color: #FFFFFF;
  font-family: var(--tf-police); font-size: 17px; font-weight: 800; letter-spacing: -0.01em; line-height: 1.2;
  text-decoration: none; white-space: nowrap; transition: background .15s ease;
}
.tfm-btn:hover, .tfm a.tfm-btn:hover { background: var(--tf-marine); color: #FFFFFF; }
.tfm-btn--large, .tfm a.tfm-btn--large { min-height: 60px; padding: 0 36px; font-size: 19px; }
.tfm-section--marine .tfm-btn:hover { background: var(--tf-emeraude); }
.tfm-btn:focus-visible { outline: 3px solid var(--tf-marine); outline-offset: 3px; }
@media (max-width: 767px) { .tfm-btn, .tfm a.tfm-btn { width: 100%; white-space: normal; text-align: center; } }

/* Lien texte avec flèche (« Le niveau B1 → ») */
.tfm-lien-fleche { font-weight: 800; text-decoration: none; }
.tfm-lien-fleche:hover { text-decoration: underline; }

/* Texte d'un lien vers une page pas encore créée (règle 1.5) : rien ne le distingue du texte. */
.tfm-sans-lien { color: inherit; font-weight: inherit; }

/* ---------- Cartes et encadrés ---------- */
.tfm-carte { background: var(--tf-fond); border: 1px solid var(--tf-bordure); border-radius: var(--tf-rayon-lg); padding: 32px; }
.tfm-carte--doux { background: var(--tf-fond-doux); border-color: var(--tf-bordure-claire); }
.tfm-encadre { background: var(--tf-emeraude-pale); border-radius: var(--tf-rayon-md); padding: 24px 28px; }
.tfm-grille { display: grid; gap: 24px; }
.tfm-grille--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.tfm-grille--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.tfm-grille--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 767px) {
  .tfm-carte { padding: 22px; border-radius: 16px; }
  .tfm-grille--2, .tfm-grille--3, .tfm-grille--4 { grid-template-columns: 1fr; }
}

/* Tableaux (bloc Tableau, className « tfm-tableau ») */
.tfm-tableau table { width: 100%; border-collapse: collapse; font-size: 16px; }
.tfm-tableau th, .tfm-tableau td { text-align: left; padding: 14px 16px; border-bottom: 1px solid var(--tf-bordure); vertical-align: top; }
.tfm-tableau th { background: var(--tf-fond-doux); color: var(--tf-marine); font-weight: 800; }
@media (max-width: 767px) { .tfm-tableau { overflow-x: auto; } .tfm-tableau table { min-width: 520px; font-size: 15px; } }

/* ---------- FAQ : bloc Détails (core/details) className « tfm-faq-item » ---------- */
.tfm-faq-item { border-bottom: 1px solid var(--tf-bordure); padding: 24px 0; }
.tfm-faq-item > summary { cursor: pointer; list-style: none; font-size: 21px; line-height: 28px; font-weight: 800; color: var(--tf-marine); display: flex; justify-content: space-between; gap: 24px; }
.tfm-faq-item > summary::-webkit-details-marker { display: none; }
.tfm-faq-item > summary::after { content: "+"; flex: none; font-size: 26px; line-height: 28px; color: var(--tf-emeraude-fonce); }
.tfm-faq-item[open] > summary::after { content: "−"; }
.tfm-faq-item > :not(summary) { margin-top: 14px; }
@media (max-width: 767px) {
  .tfm-faq-item { padding: 18px 0; }
  .tfm-faq-item > summary { min-height: 44px; font-size: 18px; line-height: 24px; }
}

/* ---------- Fil d'Ariane [tf_fil_ariane] ---------- */
.tfm-fil ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; font-size: 15px; line-height: 22px; }
.tfm-fil li { font-size: 15px; line-height: 22px; color: var(--tf-encre-secondaire); }
.tfm-fil li + li::before { content: "›"; margin-right: 6px; color: var(--tf-encre-tertiaire); }
.tfm-fil a { color: var(--tf-encre-secondaire); text-decoration: none; font-weight: 600; }
.tfm-fil a:hover { color: var(--tf-emeraude-fonce); text-decoration: underline; }
.tfm-fil [aria-current] { color: var(--tf-marine); font-weight: 700; }

/* ---------- Signature [tf_signature] ---------- */
.tfm-signature { font-size: 15px !important; line-height: 22px !important; color: var(--tf-encre-secondaire); font-weight: 600; }
.tfm-signature a { font-weight: 800; }

/* ---------- Photos d'illustration ---------- */
.tfm-photo img { border-radius: var(--tf-rayon-lg); display: block; }
.tfm-photo figcaption { font-size: 13px; line-height: 18px; color: var(--tf-encre-tertiaire); margin-top: 8px; }

/* Ancres : le titre visé ne se cache pas sous l'en-tête. */
.tfm [id] { scroll-margin-top: 110px; }
