/*
Theme Name: Débat Grand Paris
Theme URI: https://debat-grandparis.com/
Author: La rédaction de Débat Grand Paris
Author URI: https://debat-grandparis.com/a-propos/
Description: Thème sur-mesure du média local indépendant Débat Grand Paris — urbanisme, logement, mobilité, transition écologique et débats citoyens en Île-de-France. Code pur, sans page-builder, fonts self-hosted.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: debat-grandparis
*/

/* ==========================================================================
   Fontes self-hosted (P-086) — Newsreader (serif éditoriale) + IBM Plex Sans
   ========================================================================== */
@font-face {
  font-family: 'Newsreader';
  src: url('assets/fonts/newsreader-latin-400-normal.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Newsreader';
  src: url('assets/fonts/newsreader-latin-400-italic.woff2') format('woff2');
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: 'Newsreader';
  src: url('assets/fonts/newsreader-latin-700-normal.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'IBM Plex Sans';
  src: url('assets/fonts/ibmplexsans-latin-400-normal.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'IBM Plex Sans';
  src: url('assets/fonts/ibmplexsans-latin-600-normal.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

/* ==========================================================================
   Design tokens — 1 fond neutre + 1 accent (P-116)
   Contraste vérifié clair ET sombre, >= 4.5:1 (P-110)
   ========================================================================== */
:root {
  /* Mode clair */
  --dgp-fond: #f4f3f7;             /* fond neutre : gris lilas très pâle */
  --dgp-surface: #ffffff;          /* cartes / encarts */
  --dgp-encre: #1d1a26;            /* texte principal sur fond (15.2:1) */
  --dgp-encre-2: #55506b;          /* texte secondaire sur fond (6.4:1) */
  --dgp-filet: #d9d6e3;            /* filets, bordures */
  --dgp-accent: #5b2ea6;           /* violet tribune — accent unique (7.9:1 sur fond) */
  --dgp-accent-contraste: #ffffff; /* texte posé SUR l'accent (8.8:1) */
  --dgp-accent-fonce: #472383;     /* hover de l'accent */
  --dgp-bloc-sombre: #1d1a26;      /* sections inversées */
  --dgp-bloc-sombre-texte: #ece9f2;
  --dgp-bloc-sombre-accent: #b9a6f3;

  --dgp-serif: 'Newsreader', 'Iowan Old Style', Georgia, serif;
  --dgp-sans: 'IBM Plex Sans', 'Helvetica Neue', Arial, sans-serif;
  --dgp-mesure: 68ch;
  --dgp-gouttiere: 1.25rem;
  --dgp-rayon: 4px;
}

@media (prefers-color-scheme: dark) {
  :root {
    /* Mode sombre */
    --dgp-fond: #17141f;
    --dgp-surface: #221e2e;
    --dgp-encre: #ece9f2;            /* 14.6:1 sur fond sombre */
    --dgp-encre-2: #aaa3c0;          /* 7.6:1 */
    --dgp-filet: #39334a;
    --dgp-accent: #b9a6f3;           /* violet éclairci (8.4:1 sur fond sombre) */
    --dgp-accent-contraste: #17141f; /* texte posé SUR l'accent sombre (8.4:1) */
    --dgp-accent-fonce: #cbbcf7;
    --dgp-bloc-sombre: #221e2e;
    --dgp-bloc-sombre-texte: #ece9f2;
    --dgp-bloc-sombre-accent: #b9a6f3;
  }
}

/* Socle minimal — le détail vit dans assets/css/dgp.css */
html {
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  background: var(--dgp-fond);
  color: var(--dgp-encre);
  font-family: var(--dgp-serif);
  font-size: 1.0625rem;
  line-height: 1.65;
}
