/*
 * OS MAPPE : feuille de variables commune.
 * Source unique : depot portail, public/os-mappe/os-mappe.css.
 * Les copies presentes dans les applications sont generees par
 * scripts/copier-os-mappe.mjs. Ne pas modifier une copie a la main.
 */

/* Police Rubik auto-hebergee (SIL Open Font License 1.1, voir polices/LICENCE-OFL.txt). */
@font-face {
  font-family: "Rubik";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("./polices/rubik-latin-ext-400-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Rubik";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("./polices/rubik-latin-400-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Rubik";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("./polices/rubik-latin-ext-500-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Rubik";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("./polices/rubik-latin-500-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Rubik";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("./polices/rubik-latin-ext-600-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Rubik";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("./polices/rubik-latin-600-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Rubik";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("./polices/rubik-latin-ext-700-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Rubik";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("./polices/rubik-latin-700-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  /* Charte */
  --mappe-bleu: #003399; /* boutons principaux, liens, accents */
  --mappe-marine: #1a2e6c; /* fond du bandeau, en-tetes */
  --mappe-texte: #1a1a2e;
  --mappe-texte-secondaire: #5a6178;
  --mappe-jaune: #ffcc00; /* pastilles de compteur, avatar */
  --mappe-fond: #f5f6fa; /* fond de page */
  --mappe-bordure: #e3e6ef;
  --mappe-carte: #ffffff;
  --mappe-rayon: 12px;

  /* Derivee, hors charte : survol du bouton principal (bleu marque assombri). */
  --mappe-bleu-survol: #002a80;

  /* Etats : couleur de texte et couleur de fond */
  --mappe-erreur: #a8201a;
  --mappe-erreur-fond: #fdecea;
  --mappe-alerte: #8a4200;
  --mappe-alerte-fond: #fff1e0;
  --mappe-info: #1a2e6c;
  --mappe-info-fond: #e8ecf7;
  --mappe-succes: #0b6b55;
  --mappe-succes-fond: #e3f4ee;

  /* Police */
  --mappe-police: "Rubik", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

  /* Couleurs d'application (icone du lanceur, lisere du bandeau) */
  --mappe-app-pilote: #0f8b6e;
  --mappe-app-ariane: #6d4ab0;
  --mappe-app-hermes: #c2611a;
  --mappe-app-maat: #4e7a22;
  --mappe-app-themis: #a3324a;
  --mappe-app-iris: #b83d78;
  --mappe-app-subveo: #9a7200;
  --mappe-app-csf-fsue: #c2502e;
  --mappe-app-nestor: #4a5a6a;
  --mappe-app-milo: #1f7a9c;
  --mappe-app-csf-assistant: #7a5c3a;
  --mappe-app-portail: #8a94b8;

  /*
   * Reperes de mise en forme (chantier 2, harmonisation). Voir docs/HARMONISATION.md.
   * Ce ne sont pas des composants : chaque application garde les siens et les regle
   * sur ces valeurs.
   */
  --mappe-controle-hauteur: 40px; /* boutons et champs de saisie */
  --mappe-controle-hauteur-petit: 32px; /* boutons de ligne, dans une liste ou une grille */
  --mappe-controle-rayon: 10px; /* boutons et champs */
  --mappe-controle-taille: 0.875rem; /* texte des boutons et des champs (14 px) */
  --mappe-champ-bordure: #a4a8b5; /* bordure d'un champ : derivee du texte secondaire, lisible sur blanc */
  --mappe-titre-page-taille: 1.5rem; /* titre de page : 24 px, graisse 600, marine */
  --mappe-titre-page-graisse: 600;
  --mappe-titre-section-taille: 1.125rem; /* titre de bloc : 18 px, graisse 600, marine */
  --mappe-badge-taille: 0.75rem; /* badge d'etat : 12 px, graisse 500, pilule */
  --mappe-badge-rayon: 999px;
  --mappe-page-marge: 32px; /* marge interieure de la zone de contenu (16 px sous 640 px) */
  --mappe-carte-marge: 24px; /* marge interieure d'une carte */
  /* Bandeau */
  --mappe-bandeau-largeur: 248px;
  --mappe-bandeau-largeur-replie: 76px;
}

/* Reserve la place du bandeau avant le chargement du composant (evite le saut de mise en page). */
mappe-bandeau:not(:defined) {
  display: block;
  flex: none;
  box-sizing: border-box;
  width: var(--mappe-bandeau-largeur);
  height: 100vh;
  background: var(--mappe-marine);
  border-right: 6px solid var(--mappe-bordure);
}
mappe-bandeau:not(:defined) > * {
  display: none;
}
