/* Polices auto-hébergées.
 *
 * Aucune n'est chargée depuis un CDN tiers (ni Google Fonts, ni jsDelivr) :
 * une requête vers un serveur extérieur à chaque ouverture de conversation
 * révélerait l'usage du produit à ce serveur et ferait dépendre la lisibilité
 * du texte d'un enfant d'une connexion internet. Les fichiers sont servis par
 * Altaïr AI, depuis polices/.
 *
 * Les fichiers ne sont pas versionnés : ils se récupèrent avec
 *     node scripts/recuperer-polices.mjs
 * qui vérifie chaque téléchargement et met à jour polices/LICENSES.md.
 * Licences et sources : voir ce fichier et le NOTICE à la racine.
 *
 * font-display: block plutôt que swap. `swap` afficherait d'abord la police
 * système puis basculerait sur la police choisie : un changement de mise en
 * page sous les yeux de l'enfant, exactement le saut visuel que le produit
 * s'interdit pour les profils TDAH. Les fichiers étant locaux, la période
 * d'attente se compte en millisecondes.
 */

/* ---------- OpenDyslexic — SIL OFL 1.1 ---------- */

@font-face {
  font-family: 'OpenDyslexic';
  src: url('polices/OpenDyslexic-Regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: block;
}

@font-face {
  font-family: 'OpenDyslexic';
  src: url('polices/OpenDyslexic-Bold.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: block;
}

@font-face {
  font-family: 'OpenDyslexic';
  src: url('polices/OpenDyslexic-Italic.woff2') format('woff2');
  font-weight: 400;
  font-style: italic;
  font-display: block;
}

@font-face {
  font-family: 'OpenDyslexic';
  src: url('polices/OpenDyslexic-BoldItalic.woff2') format('woff2');
  font-weight: 700;
  font-style: italic;
  font-display: block;
}

/* ---------- Lexend (police variable) — SIL OFL 1.1 ----------
 *
 * Un seul fichier couvre toutes les graisses de 100 à 900 : le palier de
 * contraste « Élevé » (500) et « Maximum » (600) n'ajoutent donc aucun
 * téléchargement.
 */

@font-face {
  font-family: 'Lexend';
  src: url('polices/Lexend-Variable.woff2') format('woff2-variations');
  font-weight: 100 900;
  font-style: normal;
  font-display: block;
}

/* ---------- Atkinson Hyperlegible — SIL OFL 1.1 ---------- */

@font-face {
  font-family: 'Atkinson Hyperlegible';
  src: url('polices/AtkinsonHyperlegible-Regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: block;
}

@font-face {
  font-family: 'Atkinson Hyperlegible';
  src: url('polices/AtkinsonHyperlegible-Bold.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: block;
}

@font-face {
  font-family: 'Atkinson Hyperlegible';
  src: url('polices/AtkinsonHyperlegible-Italic.woff2') format('woff2');
  font-weight: 400;
  font-style: italic;
  font-display: block;
}

@font-face {
  font-family: 'Atkinson Hyperlegible';
  src: url('polices/AtkinsonHyperlegible-BoldItalic.woff2') format('woff2');
  font-weight: 700;
  font-style: italic;
  font-display: block;
}
