/* Copie générée depuis design/design-system/tokens.css par scripts/sync-design-system-to-theme.ps1. Ne pas modifier ici. */
/*
 * FDR Design System - Design tokens
 * ==================================
 * Source de vérité unique pour couleurs, typographie, espacements, bordures,
 * ombres, mouvements et couches. Direction visuelle : "V4" (fond clair, angles
 * droits, aubergine + bordeaux, or réservé aux fonds sombres).
 *
 * Règle : aucun composant n'utilise de valeur brute (hex, px) - uniquement
 * des tokens. Les ratios de contraste ci-dessous sont calculés (WCAG 2.1).
 *
 * Breakpoints (non variabilisables en CSS) :
 *   sm  : 640px   (mobile large)
 *   md  : 960px   (tablette)
 *   lg  : 1200px  (desktop)
 */

:root {
	/* ===== 1. Couleurs - palette brute ===== */
	--fdr-aubergine-900: #24172f;   /* marque - 16,4:1 sur #fcfbf8 */
	--fdr-aubergine-800: #3a2850;   /* hover marque - 13,1:1 en texte blanc */
	--fdr-bordeaux-900:  #5a1716;   /* pressed - 13,4:1 en texte blanc */
	--fdr-bordeaux-700:  #6f1d1b;   /* accent - 10,9:1 sur #fcfbf8 */
	--fdr-bordeaux-600:  #8b2a22;   /* hover accent - 8,6:1 en texte blanc */
	--fdr-or-400:        #d3b066;   /* décoratif / sur fond sombre uniquement (8,2:1 sur aubergine) */
	--fdr-or-300:        #e1bf79;
	--fdr-sable-100:     #f3ece0;   /* surface chaude */
	--fdr-creme-200:     #efe3c8;
	--fdr-ivoire-50:     #fcfbf8;   /* fond de page */
	--fdr-blanc:         #ffffff;
	--fdr-encre-900:     #201914;   /* texte - 16,8:1 sur #fcfbf8 */
	--fdr-encre-700:     #4b4b4b;   /* texte secondaire - 8,4:1 */
	--fdr-encre-600:     #5b493e;   /* texte secondaire chaud - 8,2:1 (7,3:1 sur sable) */
	--fdr-encre-500:     #6f5c4c;   /* métadonnées - 6,1:1 (5,4:1 sur sable) */
	--fdr-gris-600:      #6b6470;   /* bordure de contrôle - 5,7:1 (>= 3:1 requis, WCAG 1.4.11) */

	/* ===== 2. Couleurs - rôles sémantiques (à utiliser dans les composants) ===== */
	--fdr-color-text:           var(--fdr-encre-900);
	--fdr-color-text-soft:      var(--fdr-encre-700);
	--fdr-color-text-muted:     var(--fdr-encre-500);
	--fdr-color-text-inverse:   var(--fdr-blanc);
	--fdr-color-text-on-dark-muted: var(--fdr-sable-100);

	--fdr-color-bg:             var(--fdr-ivoire-50);
	--fdr-color-surface:        var(--fdr-blanc);
	--fdr-color-surface-alt:    var(--fdr-sable-100);
	--fdr-color-surface-dark:   var(--fdr-aubergine-900);

	--fdr-color-brand:          var(--fdr-aubergine-900);
	--fdr-color-brand-hover:    var(--fdr-aubergine-800);
	--fdr-color-accent:         var(--fdr-bordeaux-700);
	--fdr-color-accent-hover:   var(--fdr-bordeaux-600);
	--fdr-color-accent-pressed: var(--fdr-bordeaux-900);
	--fdr-color-highlight:      var(--fdr-or-400);       /* fonds sombres uniquement */

	--fdr-color-link:           var(--fdr-bordeaux-700);
	--fdr-color-link-hover:     var(--fdr-aubergine-900);

	--fdr-color-border:         rgba(36, 23, 47, 0.14);  /* décoratif : séparateurs, cartes */
	--fdr-color-border-strong:  var(--fdr-gris-600);     /* fonctionnel : champs, cases, boutons outline */
	--fdr-color-border-on-dark: rgba(255, 255, 255, 0.2);

	/* États (texte sur fond clair >= 5:1, texte sur teinte >= 5:1) */
	--fdr-color-success:        #1e6b3a;
	--fdr-color-success-bg:     #e8f3ec;
	--fdr-color-warning:        #8a5a00;
	--fdr-color-warning-bg:     #fff4d6;
	--fdr-color-error:          #9b1c1c;
	--fdr-color-error-bg:       #fbeaea;
	--fdr-color-info:           #1a5276;
	--fdr-color-info-bg:        #e6eff5;

	/* Réseaux sociaux : variantes assombries pour texte blanc >= 4,5:1.
	   (Facebook officiel #1877f2 = 4,2:1 : refusé.) */
	--fdr-color-facebook:       #0d56c9;   /* 6,6:1 */
	--fdr-color-facebook-hover: #0a449f;
	--fdr-color-discord:        #404eed;   /* 6,0:1 */
	--fdr-color-discord-hover:  #2f3bc4;
	--fdr-color-instagram:      #a1281f;   /* 7,4:1 - pas de dégradé, pour rester lisible */
	--fdr-color-instagram-hover:#7f1f18;

	/* ===== 3. Focus (RGAA 10.7 / WCAG 2.4.7 + 2.4.11) ===== */
	--fdr-focus-color:          var(--fdr-bordeaux-700);
	--fdr-focus-color-on-dark:  var(--fdr-or-400);
	--fdr-focus-width:          3px;
	--fdr-focus-offset:         2px;

	/* ===== 4. Typographie ===== */
	--fdr-font-family:  "Public Sans", "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
	--fdr-font-weight-regular:  400;
	--fdr-font-weight-medium:   500;
	--fdr-font-weight-semibold: 600;
	--fdr-font-weight-bold:     700;
	--fdr-font-weight-heavy:    800;

	--fdr-text-xs:   0.75rem;    /* 12px - micro-labels MAJUSCULES uniquement */
	--fdr-text-sm:   0.875rem;   /* 14px - métadonnées */
	--fdr-text-base: 1rem;       /* 16px - corps */
	--fdr-text-md:   1.125rem;   /* 18px */
	--fdr-text-lg:   1.25rem;    /* 20px */
	--fdr-text-xl:   1.5rem;     /* 24px - h2 section */
	--fdr-text-2xl:  clamp(1.75rem, 1.2rem + 1.6vw, 2.25rem);  /* h1 page */
	--fdr-text-3xl:  clamp(2.25rem, 1.4rem + 3.2vw, 4rem);     /* h1 hero */

	--fdr-leading-tight:  1.1;
	--fdr-leading-snug:   1.3;
	--fdr-leading-normal: 1.6;

	--fdr-tracking-tight:   -0.02em;
	--fdr-tracking-normal:  0;
	--fdr-tracking-wide:    0.05em;   /* navigation, boutons */
	--fdr-tracking-wider:   0.12em;   /* eyebrows */

	--fdr-measure: 65ch;              /* longueur de ligne confortable */

	/* ===== 5. Espacements (échelle de 4px) ===== */
	--fdr-space-1:  0.25rem;   /*  4 */
	--fdr-space-2:  0.5rem;    /*  8 */
	--fdr-space-3:  0.75rem;   /* 12 */
	--fdr-space-4:  1rem;      /* 16 */
	--fdr-space-5:  1.25rem;   /* 20 */
	--fdr-space-6:  1.5rem;    /* 24 */
	--fdr-space-8:  2rem;      /* 32 */
	--fdr-space-10: 2.5rem;    /* 40 */
	--fdr-space-12: 3rem;      /* 48 */
	--fdr-space-16: 4rem;      /* 64 */

	--fdr-section-padding-y: var(--fdr-space-16);
	--fdr-gutter:            var(--fdr-space-10);   /* marges latérales desktop */

	/* ===== 6. Mise en page ===== */
	--fdr-container:        1200px;
	--fdr-container-wide:   1400px;
	--fdr-container-narrow: 800px;
	--fdr-grid-gap:         var(--fdr-space-5);

	/* ===== 7. Formes, bordures, ombres ===== */
	--fdr-radius:       0;          /* direction V4 : angles droits */
	--fdr-radius-round: 50%;        /* avatars uniquement */
	--fdr-border-width: 1px;
	--fdr-border:       var(--fdr-border-width) solid var(--fdr-color-border);
	--fdr-border-control: var(--fdr-border-width) solid var(--fdr-color-border-strong);

	--fdr-shadow-1: 0 1px 2px rgba(36, 23, 47, 0.08);            /* repos, cartes surélevées */
	--fdr-shadow-2: 0 8px 24px rgba(36, 23, 47, 0.12);           /* survol, menus */
	--fdr-shadow-3: 0 18px 40px rgba(36, 23, 47, 0.18);          /* modales */

	/* ===== 8. Dimensions d'interaction ===== */
	--fdr-target-min: 2.75rem;      /* 44px : zone tactile minimale */

	/* ===== 9. Mouvement ===== */
	--fdr-duration-fast: 150ms;
	--fdr-duration-base: 250ms;
	--fdr-ease: cubic-bezier(0.2, 0, 0, 1);

	/* ===== 10. Couches ===== */
	--fdr-z-sticky:  100;
	--fdr-z-banner:  900;
	--fdr-z-modal:   1000;
	--fdr-z-skip:    10000;
}

@media (max-width: 960px) {
	:root {
		--fdr-gutter: var(--fdr-space-6);
		--fdr-section-padding-y: var(--fdr-space-12);
	}
}

@media (max-width: 640px) {
	:root {
		--fdr-gutter: var(--fdr-space-4);
		--fdr-section-padding-y: var(--fdr-space-10);
	}
}
