/* ============================================================
   CFE Énergies — Thème Tabler.io
   À charger APRÈS tabler.min.css :
     <link href="…/tabler.min.css" rel="stylesheet">
     <link href="theme/cfe-tabler.css" rel="stylesheet">
   Remappe les variables --tblr-* sur la charte CFE Énergies.
   ============================================================ */
:root,
[data-bs-theme="light"] {
  /* — Typographie — */
  --tblr-font-sans-serif: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  --tblr-font-monospace:  'IBM Plex Mono', ui-monospace, SFMono-Regular, Menlo, monospace;

  /* — Couleur d'action = magenta CFE (CTA, focus, éléments actifs) — */
  --tblr-primary:     #e2007a;
  --tblr-primary-rgb: 226, 0, 122;

  /* — Secondaire = bleu ardoise — */
  --tblr-secondary:     #405888;
  --tblr-secondary-rgb: 64, 88, 136;

  /* — Surfaces sombres (sidebar / navbar) = bleu nuit — */
  --tblr-dark:     #002060;
  --tblr-dark-rgb: 0, 32, 96;

  /* — États fonctionnels (distincts de la marque) — */
  --tblr-success: #1f8a5b;  --tblr-success-rgb: 31, 138, 91;
  --tblr-warning: #a96a00;  --tblr-warning-rgb: 169, 106, 0;
  --tblr-danger:  #cc2b2b;  --tblr-danger-rgb:  204, 43, 43;
  --tblr-info:    #405888;  --tblr-info-rgb:    64, 88, 136;

  /* — Couleurs nommées remappées sur la marque (utilitaires .bg-pink, .text-blue…) — */
  --tblr-pink: #e2007a;  --tblr-pink-rgb: 226, 0, 122;
  --tblr-blue: #002060;  --tblr-blue-rgb: 0, 32, 96;

  /* — Liens en bleu ardoise : le magenta reste réservé aux actions — */
  --tblr-link-color:       #405888;
  --tblr-link-hover-color: #002060;

  /* — Texte, fonds, bordures — */
  --tblr-body-color:     #404040;  --tblr-body-color-rgb: 64, 64, 64;
  --tblr-body-bg:        #fbfbfc;  --tblr-body-bg-rgb:    251, 251, 252;
  --tblr-heading-color:  #002060;
  --tblr-border-color:   #e4e6ec;
  --tblr-border-color-translucent: rgba(0, 32, 96, .12);

  /* — Rayons : un peu plus doux que le défaut Tabler — */
  --tblr-border-radius:    .625rem; /* 10px — boutons, champs */
  --tblr-border-radius-sm: .5rem;   /* 8px  */
  --tblr-border-radius-lg: 1rem;    /* 16px — cartes */
}

/* Titres en Archivo (la couleur est gérée par --tblr-heading-color,
   restez sur .text-white sur fond sombre). */
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6,
.navbar-brand, .card-title, .page-title {
  font-family: 'Archivo', var(--tblr-font-sans-serif);
  letter-spacing: -.01em;
}

/* Étiquettes techniques / métadonnées en monospace */
.subheader, .text-mono, .datagrid-title {
  font-family: 'IBM Plex Mono', var(--tblr-font-monospace);
}

/* Halo de focus rose pâle (rappel du moodboard) */
.form-control:focus,
.form-select:focus,
.form-check-input:focus {
  border-color: #e2007a;
  box-shadow: 0 0 0 .25rem rgba(248, 191, 222, .65);
}

/* Item de navigation actif : filet magenta sur la sidebar bleu nuit */
.navbar-vertical .nav-link.active {
  box-shadow: inset 3px 0 0 #e2007a;
}
