/* ============================================================
   Guide IFAS 2021 — N'oublie Jamais
   Feuille de style principale (dérivée du guide IFSI 2026, dominante rose NJ)
   Arrêté du 10 juin 2021 modifié — NOR : SSAH2110960A
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=DM+Sans:opsz,wght@9..40,300;9..40,400;9..40,500;9..40,600;9..40,700;9..40,800&display=swap');

/* ========== VARIABLES ========== */
:root {
  /* Marque NJ — la filière IFAS est identifiée par le rose (IFSI = bleu) */
  --nj: #F01B59;
  --nj-dark: #C4154A;      /* texte sur fond clair (contraste) */
  --nj-bg: #FFF1F5;
  --nj-blue: #0343E5;
  --nj-pink: #F01B59;
  --nj-violet: #4915D8;

  /* Blocs — couleurs principales, fonds, textes */
  --da: #0343E5;  --da-bg: #EAEEFE;  --da-text: #032B96;
  --db: #F01B59;  --db-bg: #FEE8F2;  --db-text: #A01040;
  --dc: #0EA676;  --dc-bg: #E4F7F1;  --dc-text: #087354;
  --dd: #F5A623;  --dd-bg: #FEF5E4;  --dd-text: #A06E10;
  --de: #5B2D8E;  --de-bg: #F0EAF9;  --de-text: #3D1D60;
  --ds: #4A5568;  --ds-bg: #EEF0F3;  --ds-text: #2D3748;
  --dacc: #64748B; --dacc-bg: #F1F5F9; --dacc-text: #334155;

  /* Neutres */
  --bg: #FFFFFF;
  --bg-soft: #F9FAFB;
  --text: #1A1A2E;
  --text-mid: #3A3A4E;
  --text-light: #6B7280;
  --border: #E5E7EB;
  --border-light: #F3F4F6;

  /* Bloc courant — surchargé par chaque page */
  --domain: var(--nj);
  --domain-bg: var(--nj-bg);
  --domain-text: var(--nj-dark);
}

/* ========== RESET / BASE ========== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: 'DM Sans', sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 0.95rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
ul, ol { list-style: none; }
strong { font-weight: 700; }

/* ========== HEADER ========== */
.site-header {
  position: sticky; top: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between; gap: 0.5rem;
  padding: 0.6rem 1rem;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}
.site-header .brand { display: flex; align-items: center; gap: 0.5rem; text-decoration: none; line-height: 0; flex-shrink: 0; }
.site-header .brand-text { font-size: 0.78rem; font-weight: 800; color: var(--nj); line-height: 1.1; }
.site-header .brand-text small { display: block; font-weight: 500; color: var(--text-light); font-size: 0.66rem; }
.main-nav { display: none; gap: 0.25rem; }
.main-nav a, .nav-btn {
  font-size: 0.85rem; font-weight: 500; color: var(--text-mid); text-decoration: none;
  padding: 0.4rem 0.7rem; border-radius: 6px; border: none; background: none; cursor: pointer;
  font-family: inherit; display: flex; align-items: center; gap: 0.25rem; white-space: nowrap;
  transition: background 0.15s, color 0.15s;
}
.main-nav a:hover, .main-nav a.active, .nav-dropdown:hover .nav-btn, .nav-dropdown.active .nav-btn { background: var(--bg-soft); color: var(--nj); }
.search-icon-btn { color: var(--nj); font-size: 1.2rem; text-decoration: none; line-height: 1; flex-shrink: 0; }
.nav-chevron { font-size: 0.65rem; opacity: 0.6; }
.nav-dropdown { position: relative; }
.nav-dropdown-panel {
  display: none; position: absolute; top: calc(100% + 6px); left: 50%; transform: translateX(-50%);
  background: #fff; border: 1px solid var(--border); border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.12); z-index: 9999; min-width: 300px; padding: 0.4rem;
}
.nav-dropdown-panel.nj-open { display: block; animation: nav-dd-in 0.15s ease; }
@keyframes nav-dd-in { from { opacity: 0; transform: translateX(-50%) translateY(-6px); } to { opacity: 1; transform: translateX(-50%) translateY(0); } }
.nav-dd-item { display: flex; align-items: center; gap: 0.6rem; padding: 0.45rem 0.7rem; border-radius: 8px; text-decoration: none; color: var(--text); font-size: 0.82rem; }
.nav-dd-item:hover { background: var(--bg-soft); color: var(--nj); }
.nav-dd-badge { width: 24px; height: 24px; border-radius: 5px; display: flex; align-items: center; justify-content: center; font-size: 0.68rem; font-weight: 700; flex-shrink: 0; color: #fff; }
.nav-dd-divider { height: 1px; background: var(--border-light); margin: 0.3rem 0.5rem; }
.nav-dd-wide { min-width: 520px; }
.nav-dd-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.2rem 0.6rem; }

/* ========== BREADCRUMB ========== */
.breadcrumb {
  padding: 0.6rem 1rem; font-size: 0.75rem; color: var(--text-light);
  overflow-x: auto; white-space: nowrap; background: var(--bg-soft); border-bottom: 1px solid var(--border-light);
}
.breadcrumb a { color: var(--text-light); text-decoration: none; }
.breadcrumb a:hover { color: var(--domain); text-decoration: underline; }
.breadcrumb .current { color: var(--text-mid); font-weight: 600; }
.breadcrumb span.sep { margin: 0 0.3rem; }

/* ========== LAYOUT ========== */
.page { max-width: 800px; margin: 0 auto; padding: 1.5rem 1rem 3rem; }
.page p { color: var(--text-mid); }

/* ========== HERO GÉNÉRIQUE ========== */
.hero {
  background: linear-gradient(135deg, #FF4D7D 0%, var(--nj) 45%, #C8102E 100%); /* rose NJ -> rouge carmin, sans violet */
  color: #fff; border-radius: 1rem; padding: 2rem 1.5rem; margin-bottom: 1.75rem; text-align: center;
}
.hero .nj-badge { display: inline-block; background: rgba(255,255,255,0.2); border-radius: 2rem; padding: 0.25rem 0.8rem; font-size: 0.76rem; font-weight: 600; margin-bottom: 0.75rem; letter-spacing: 0.04em; }
.hero h1 { font-size: 1.9rem; font-weight: 800; margin: 0 0 0.5rem; line-height: 1.2; }
.hero .subtitle { opacity: 0.9; font-size: 0.98rem; margin: 0 0 1.25rem; line-height: 1.55; }
.hero-badges { display: flex; flex-wrap: wrap; gap: 0.5rem; justify-content: center; }
.hero-badge { background: rgba(255,255,255,0.18); border: 1px solid rgba(255,255,255,0.3); border-radius: 2rem; padding: 0.3rem 0.9rem; font-size: 0.8rem; font-weight: 600; text-decoration: none; color: #fff; }
a.hero-badge:hover { background: rgba(255,255,255,0.32); }
.hero.dark { background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%); text-align: left; }
.hero.dark h1 { font-size: 1.5rem; }
.hero.dark .label { display: inline-block; background: rgba(255,255,255,0.15); font-size: 0.76rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; padding: 0.25rem 0.75rem; border-radius: 2rem; margin-bottom: 0.75rem; }

/* ========== CHIFFRES CLÉS ========== */
.key-numbers { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.75rem; margin-bottom: 2rem; }
@media (min-width: 640px) { .key-numbers { grid-template-columns: repeat(4, 1fr); } }
.kn-card { text-align: center; padding: 1rem 0.5rem; border: 1px solid var(--border); border-radius: 0.65rem; background: var(--bg); }
.kn-value { font-size: 1.8rem; font-weight: 800; color: var(--nj); line-height: 1; margin-bottom: 0.3rem; }
.kn-label { font-size: 0.78rem; color: var(--text-light); line-height: 1.3; }

/* Barre segmentée des volumes */
.vol-bar { display: flex; height: 26px; border-radius: 6px; overflow: hidden; margin: 0.5rem 0 0.4rem; font-size: 0.7rem; font-weight: 700; color: #fff; }
.vol-bar div { display: flex; align-items: center; justify-content: center; min-width: 0; white-space: nowrap; overflow: hidden; }
.vol-legend { display: flex; flex-wrap: wrap; gap: 0.3rem 1rem; font-size: 0.76rem; color: var(--text-light); margin-bottom: 1.5rem; }
.vol-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 0.3rem; vertical-align: -1px; }

/* ========== TITRES DE SECTION ========== */
.section-title {
  font-size: 1.1rem; font-weight: 700; color: var(--text); margin: 1.75rem 0 1rem; padding-bottom: 0.4rem;
  border-bottom: 2px solid var(--border-light); display: flex; align-items: center; gap: 0.5rem;
}
.title-icon { display: inline-block; width: 4px; height: 1.1rem; background: var(--domain); border-radius: 2px; flex-shrink: 0; }
.section-title:first-child { margin-top: 0; }

/* ========== CARTES DE NAVIGATION (accueil) ========== */
.nav-cards { display: grid; grid-template-columns: 1fr; gap: 1rem; margin-bottom: 2rem; }
@media (min-width: 640px) { .nav-cards { grid-template-columns: 1fr 1fr; } }
.nav-card { display: flex; flex-direction: column; border-radius: 0.75rem; overflow: hidden; border: 1px solid var(--border); text-decoration: none; color: inherit; transition: box-shadow 0.15s; }
.nav-card:hover { box-shadow: 0 4px 16px rgba(240,27,89,0.14); }
.nav-card-top { padding: 1rem 1.25rem; font-size: 0.82rem; color: #fff; font-weight: 600; display: flex; align-items: center; gap: 0.6rem; }
.nav-card-icon { font-size: 1.4rem; }
.nav-card-body { padding: 0.9rem 1.25rem; flex: 1; }
.nav-card-title { font-weight: 700; font-size: 1rem; margin: 0 0 0.3rem; }
.nav-card-desc { font-size: 0.85rem; color: var(--text-light); margin: 0; line-height: 1.5; }
.nav-card-arrow { padding: 0.6rem 1.25rem; font-size: 0.82rem; font-weight: 600; border-top: 1px solid var(--border); }

/* Blocs en grille */
.blocs-quick { display: grid; grid-template-columns: 1fr; gap: 0.6rem; margin-bottom: 2rem; }
@media (min-width: 640px) { .blocs-quick { grid-template-columns: 1fr 1fr; } }
.bloc-quick-card { display: flex; align-items: center; gap: 0.8rem; padding: 0.8rem 1rem; border-radius: 0.65rem; text-decoration: none; color: var(--text); border: 1px solid var(--border); transition: transform 0.15s; }
.bloc-quick-card:hover { transform: translateY(-1px); }
.bq-num { width: 2.4rem; height: 2.4rem; border-radius: 0.5rem; display: flex; align-items: center; justify-content: center; font-size: 1.1rem; font-weight: 800; color: #fff; flex-shrink: 0; }
.bq-info { flex: 1; min-width: 0; }
.bq-name { display: block; font-size: 0.86rem; font-weight: 600; line-height: 1.3; }
.bq-meta { display: block; font-size: 0.72rem; color: var(--text-light); }

/* Chips modules */
.chips { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 2rem; }
.chip { display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.3rem 0.7rem; border-radius: 0.4rem; font-size: 0.8rem; font-weight: 600; text-decoration: none; border: 1px solid var(--border); transition: opacity 0.15s; }
.chip:hover { opacity: 0.75; }
.chip small { font-weight: 500; opacity: 0.75; }

/* ========== BADGES ========== */
.badge { display: inline-block; font-size: 0.72rem; font-weight: 600; padding: 2px 8px; border-radius: 4px; }
.h-badge { background: var(--domain); color: white; }
.outline-badge { background: transparent; color: var(--text-light); border: 1px solid var(--border); }
.spec-badge { background: var(--nj-bg); color: var(--nj-dark); border: 1px solid #F9C4D3; }
.commun-badge { background: var(--dacc-bg); color: var(--dacc-text); border: 1px solid #CBD5E1; }

/* ========== HERO BLOC / MODULE ========== */
.domain-hero { background: var(--domain-bg); border-left: 4px solid var(--domain); border-radius: 0 8px 8px 0; padding: 1.2rem; margin-bottom: 1.75rem; }
.domain-letter { font-size: 2.2rem; font-weight: 800; color: var(--domain); line-height: 1; margin-bottom: 0.2rem; }
.domain-letter small { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; display: block; margin-bottom: 0.15rem; }
.domain-hero h1 { font-size: 1.3rem; font-weight: 700; color: var(--domain-text); line-height: 1.3; margin-bottom: 0.5rem; }
.domain-desc { font-size: 0.85rem; color: var(--text-mid); line-height: 1.5; margin-bottom: 0.8rem; }
.domain-hero .badges { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.domain-hero .comp-refs { font-size: 0.78rem; color: var(--text-mid); margin-top: 0.6rem; }
.domain-hero .comp-refs a { color: var(--domain); text-decoration: none; font-weight: 600; }
.domain-hero .comp-refs a:hover { text-decoration: underline; }

/* ========== COMPÉTENCES (pages Bloc) ========== */
.competence-card { background: var(--bg); border: 1px solid var(--border); border-radius: 8px; padding: 1rem 1.2rem; margin-bottom: 1rem; scroll-margin-top: 4rem; }
.comp-header { display: flex; align-items: flex-start; gap: 0.6rem; margin-bottom: 0.6rem; }
.comp-num { display: inline-flex; align-items: center; justify-content: center; min-width: 2.4rem; height: 1.6rem; background: var(--domain); color: white; font-size: 0.72rem; font-weight: 700; border-radius: 4px; flex-shrink: 0; text-decoration: none; }
a.comp-num:hover { opacity: 0.75; }
.comp-header h3 { font-size: 0.9rem; font-weight: 600; color: var(--text); line-height: 1.4; }
.comp-links { font-size: 0.75rem; color: var(--text-light); margin-bottom: 0.6rem; }
.comp-links a { color: var(--domain); text-decoration: none; font-weight: 500; }
.comp-links a:hover { text-decoration: underline; }
.comp-sub { font-size: 0.74rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-light); margin: 0.6rem 0 0.3rem; }
.comp-list { padding: 0; }
.comp-list li { font-size: 0.83rem; color: var(--text-mid); padding: 0.18rem 0 0.18rem 1.5rem; position: relative; line-height: 1.45; }
.comp-list li .n { position: absolute; left: 0; font-weight: 700; color: var(--domain); }
.crit-list { padding: 0; }
.crit-list > li { font-size: 0.83rem; color: var(--text); padding: 0.3rem 0; border-top: 1px solid var(--border-light); line-height: 1.45; }
.crit-list > li:first-child { border-top: none; }
.crit-list details summary { cursor: pointer; font-weight: 600; list-style: none; display: flex; gap: 0.5rem; align-items: baseline; }
.crit-list details summary::-webkit-details-marker { display: none; }
.crit-list details summary .n { display: inline-flex; align-items: center; justify-content: center; min-width: 1.4rem; height: 1.4rem; border-radius: 50%; background: var(--domain-bg); color: var(--domain-text); font-size: 0.68rem; font-weight: 700; flex-shrink: 0; }
.crit-list details summary::after { content: '▾'; margin-left: auto; color: var(--text-light); font-size: 0.8rem; }
.crit-list details[open] summary::after { content: '▴'; }
.crit-list details ul { margin: 0.4rem 0 0.3rem 1.9rem; }
.crit-list details ul li { font-size: 0.78rem; color: var(--text-mid); padding: 0.12rem 0 0.12rem 0.9rem; position: relative; line-height: 1.4; }
.crit-list details ul li::before { content: '–'; position: absolute; left: 0; color: var(--text-light); }

/* ========== CARTES LIEN MODULE (pages Bloc) ========== */
.ue-link-card { display: flex; align-items: center; gap: 0.8rem; padding: 0.8rem 1rem; background: var(--bg); border: 1px solid var(--border); border-left: 4px solid var(--domain); border-radius: 0 8px 8px 0; text-decoration: none; color: var(--text); margin-bottom: 0.6rem; transition: background 0.15s; }
.ue-link-card:hover { background: var(--domain-bg); }
.ue-code { font-size: 1rem; font-weight: 800; color: var(--domain); flex-shrink: 0; min-width: 2.6rem; }
.ue-info { flex: 1; min-width: 0; }
.ue-name { display: block; font-size: 0.88rem; font-weight: 600; line-height: 1.3; margin-bottom: 0.15rem; }
.ue-meta { display: block; font-size: 0.72rem; color: var(--text-light); }
.ue-link-card .arrow { font-size: 1.1rem; color: var(--text-light); flex-shrink: 0; transition: transform 0.15s; }
.ue-link-card:hover .arrow { transform: translateX(3px); color: var(--domain); }

/* ========== BLOCS DE CONTENU (pages Module) ========== */
.content-block { border-left: 4px solid; border-radius: 0 8px 8px 0; padding: 1rem 1.2rem; margin-bottom: 1.5rem; }
.content-block.specific { border-color: var(--domain); background: var(--domain-bg); }
.content-block.neutral { border-color: var(--border); background: var(--bg-soft); }
.content-block.nj { border-color: var(--nj); background: var(--nj-bg); }
.block-label { display: inline-block; font-size: 0.68rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; padding: 2px 7px; border-radius: 3px; margin-bottom: 0.7rem; color: white; }
.block-label.specific { background: var(--domain); }
.block-label.neutral { background: var(--text-light); }
.block-label.nj { background: var(--nj); }
.content-block ul { list-style: none; padding: 0; }
.content-block ul li { font-size: 0.85rem; color: var(--text-mid); padding: 0.2rem 0 0.2rem 1rem; position: relative; line-height: 1.5; }
.content-block ul li::before { content: '›'; position: absolute; left: 0; color: var(--domain); font-weight: 600; }
.content-block ul li.sub { padding-left: 2rem; }
.content-block ul li.sub::before { content: '–'; left: 1rem; color: var(--text-light); }
.content-block ul li.head { font-weight: 600; color: var(--text); margin-top: 0.3rem; }
.content-block p { font-size: 0.85rem; color: var(--text-mid); line-height: 1.6; margin-bottom: 0.5rem; }
.content-block p:last-child { margin-bottom: 0; }

/* ========== ÉVALUATION ========== */
.eval-card { background: var(--bg); border: 1px solid var(--border); border-radius: 8px; padding: 0.8rem 1rem; margin-bottom: 0.6rem; display: flex; align-items: flex-start; gap: 0.7rem; }
.eval-num { display: inline-flex; align-items: center; justify-content: center; min-width: 1.6rem; height: 1.6rem; background: var(--domain); color: white; font-size: 0.72rem; font-weight: 700; border-radius: 4px; flex-shrink: 0; }
.eval-card p { font-size: 0.85rem; color: var(--text-mid); line-height: 1.4; }

/* ========== INFO BOX ========== */
.info-box { background: var(--bg-soft); border: 1px solid var(--border); border-radius: 8px; padding: 0.8rem 1rem; margin: 1.5rem 0; font-size: 0.82rem; color: var(--text-mid); line-height: 1.6; }
.info-box strong { color: var(--text); }
.info-box a { color: var(--domain); text-decoration: none; font-weight: 500; }
.info-box a:hover { text-decoration: underline; }
.info-box.warn { background: #FFF9E6; border-color: #F5A623; color: #6b4f00; }
.info-box.warn strong { color: #5a4200; }
.info-box.nj { background: var(--nj-bg); border-color: #F9C4D3; }
.info-box.nj strong { color: var(--nj-dark); }

/* ========== NAVIGATION BAS DE PAGE ========== */
.page-nav { display: flex; justify-content: space-between; align-items: center; margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid var(--border); font-size: 0.82rem; flex-wrap: wrap; gap: 0.5rem; }
.page-nav a { color: var(--text-mid); text-decoration: none; font-weight: 500; }
.page-nav a:hover { color: var(--nj); }
.page-nav .up { color: var(--text-light); }

/* ========== TABLEAUX ========== */
.tbl-wrap { overflow-x: auto; border-radius: 8px; border: 1px solid var(--border); margin-bottom: 1.5rem; }
.tbl { width: 100%; border-collapse: collapse; font-size: 0.84rem; }
.tbl th { background: var(--domain-bg); color: var(--domain-text); text-align: left; padding: 0.55rem 0.7rem; font-weight: 600; font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.04em; border-bottom: 2px solid var(--domain); white-space: nowrap; }
.tbl td { padding: 0.55rem 0.7rem; vertical-align: top; border-bottom: 1px solid var(--border-light); line-height: 1.45; color: var(--text-mid); }
.tbl tr:last-child td { border-bottom: none; }
.tbl td.num, .tbl th.num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.tbl td.k { font-weight: 600; color: var(--text); white-space: nowrap; }
.tbl tr.total td { font-weight: 700; color: var(--text); background: var(--bg-soft); border-top: 2px solid var(--border); }
.tbl.compact td, .tbl.compact th { padding: 0.4rem 0.5rem; font-size: 0.78rem; }
.ctag { display: inline-block; padding: 1px 7px; border-radius: 20px; font-size: 0.7rem; font-weight: 700; white-space: nowrap; color: #fff; text-decoration: none; background: var(--domain); }
.ctag:hover { opacity: 0.82; }

/* ========== TUILES (index arrêté, modules) ========== */
.menu-tiles { display: flex; flex-direction: column; gap: 0.6rem; margin-bottom: 1.5rem; }
.tile { display: flex; align-items: center; gap: 0.9rem; padding: 0.9rem 1rem; background: var(--bg); border: 1px solid var(--border); border-radius: 10px; text-decoration: none; color: var(--text); transition: border-color 0.15s, background 0.15s; }
.tile:hover { border-color: var(--nj); background: var(--nj-bg); }
.tile-icon { display: flex; align-items: center; justify-content: center; width: 2.6rem; height: 2.6rem; border-radius: 8px; font-size: 1.2rem; flex-shrink: 0; }
.tile-icon.blue { background: var(--da-bg); } .tile-icon.pink { background: var(--db-bg); } .tile-icon.green { background: var(--dc-bg); }
.tile-icon.amber { background: var(--dd-bg); } .tile-icon.purple { background: var(--de-bg); } .tile-icon.grey { background: var(--ds-bg); }
.tile-body { flex: 1; min-width: 0; }
.tile-title { font-size: 0.9rem; font-weight: 700; line-height: 1.25; margin-bottom: 0.1rem; }
.tile-desc { font-size: 0.74rem; color: var(--text-light); line-height: 1.35; }
.tile .arrow { font-size: 1rem; color: var(--text-light); flex-shrink: 0; transition: transform 0.15s; }
.tile:hover .arrow { transform: translateX(3px); color: var(--nj); }
.section-label { font-size: 0.7rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-light); margin: 1.4rem 0 0.6rem; padding-bottom: 0.3rem; border-bottom: 1px solid var(--border-light); }

/* ========== VUE D'ENSEMBLE ========== */
.vue-hero { text-align: center; padding: 1rem 0 1.5rem; }
.vue-hero h1 { font-size: 1.5rem; font-weight: 800; margin: 0 0 0.35rem; line-height: 1.25; }
.vue-hero .lead { font-size: 0.9rem; color: var(--text-light); margin: 0 0 1.2rem; }
.kpi-bar { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.5rem 1rem; }
.kpi-group { display: flex; align-items: center; gap: 0.5rem; }
.kpi-op { font-size: 1.05rem; font-weight: 800; color: var(--text-light); }
.kpi-item { background: var(--bg-soft); border: 1px solid var(--border); border-radius: 8px; padding: 0.45rem 0.85rem; min-width: 5.5rem; }
.kpi-num { display: block; font-size: 1.05rem; font-weight: 800; color: var(--nj); line-height: 1.2; }
.kpi-lbl { display: block; font-size: 0.68rem; color: var(--text-light); line-height: 1.3; }
.domaine-bloc { border-radius: 10px; border: 1px solid var(--border); margin-bottom: 1.5rem; overflow: hidden; }
.domaine-bloc-head { display: flex; align-items: center; gap: 1rem; padding: 0.9rem 1.1rem; }
.domaine-lettre { width: 2.6rem; height: 2.6rem; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 1.2rem; color: #fff; flex-shrink: 0; }
.domaine-bloc-head h2 { font-size: 0.95rem; font-weight: 700; margin: 0 0 0.2rem; line-height: 1.3; }
.domaine-ects-line { font-size: 0.76rem; color: var(--text-light); }
.artic-section { border-top: 1px solid var(--border); }
.artic-row { display: grid; grid-template-columns: 9rem 1fr; border-bottom: 1px solid var(--border-light); }
.artic-row:last-child { border-bottom: none; }
.artic-ue { padding: 0.6rem 0.8rem; background: var(--bg-soft); border-right: 1px solid var(--border-light); display: flex; flex-direction: column; justify-content: center; gap: 2px; }
.artic-ue a { font-size: 0.85rem; font-weight: 700; text-decoration: none; }
.artic-ue a:hover { text-decoration: underline; }
.artic-ue-ects { font-size: 0.7rem; color: var(--text-light); }
.artic-comps { padding: 0.65rem 0.8rem; display: flex; flex-direction: column; gap: 0.35rem; justify-content: center; }
.artic-comp-link { display: flex; align-items: baseline; gap: 0.4rem; font-size: 0.83rem; color: var(--text); text-decoration: none; line-height: 1.35; }
.artic-comp-link:hover { color: var(--text-mid); }
.cbadge { display: inline-block; padding: 1px 7px; border-radius: 20px; font-size: 0.68rem; font-weight: 700; white-space: nowrap; flex-shrink: 0; color: #fff; line-height: 1.5; }
.artic-note { padding: 0.45rem 0.8rem; font-size: 0.75rem; color: var(--text-light); font-style: italic; background: var(--bg-soft); border-top: 1px solid var(--border-light); }
.voir-domaine { display: block; padding: 0.7rem 1.1rem; text-align: right; font-size: 0.84rem; font-weight: 600; text-decoration: none; border-top: 1px solid var(--border-light); background: var(--bg-soft); }
.voir-domaine:hover { background: var(--border-light); }
@media (max-width: 479px) {
  .artic-row { grid-template-columns: 1fr; }
  .artic-ue { border-right: none; border-bottom: 1px solid var(--border-light); flex-direction: row; align-items: center; gap: 0.5rem; }
}

/* ========== STAGES ========== */
.typo-grid { display: grid; grid-template-columns: 1fr; gap: 0.8rem; margin-bottom: 1rem; }
@media (min-width: 640px) { .typo-grid { grid-template-columns: 1fr 1fr; } }
.typo-card { background: var(--bg); border: 1px solid var(--border); border-radius: 8px; padding: 0.9rem 1rem; }
.typo-card .typo-num { display: inline-flex; align-items: center; justify-content: center; width: 1.9rem; height: 1.9rem; background: var(--ds); color: white; border-radius: 4px; font-size: 0.8rem; font-weight: 700; margin-bottom: 0.5rem; }
.typo-card h3 { font-size: 0.86rem; font-weight: 700; color: var(--text); line-height: 1.35; margin-bottom: 0.3rem; }
.typo-card p { font-size: 0.78rem; color: var(--text-light); line-height: 1.4; }
.role-list li { display: flex; gap: 0.6rem; padding: 0.6rem 0; border-bottom: 1px solid var(--border-light); font-size: 0.85rem; color: var(--text-mid); line-height: 1.5; }
.role-list li:last-child { border-bottom: none; }
.role-list .role { font-weight: 600; color: var(--text); min-width: 10rem; flex-shrink: 0; }
@media (max-width: 479px) { .role-list li { flex-direction: column; gap: 0.1rem; } }

/* ========== TEXTE DE L'ARRÊTÉ ========== */
.arrete-text h2 { font-size: 1.05rem; font-weight: 800; margin: 2rem 0 0.6rem; padding-top: 1rem; border-top: 1px solid var(--border); scroll-margin-top: 4rem; }
.arrete-text h2.titre { font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--nj-dark); border-top: none; margin-top: 2.2rem; }
.arrete-text h3 { font-size: 0.9rem; font-weight: 700; margin: 1.4rem 0 0.5rem; color: var(--text); scroll-margin-top: 4rem; }
.arrete-text h4 { font-size: 0.84rem; font-weight: 700; margin: 1rem 0 0.3rem; color: var(--text-mid); }
.arrete-text p { font-size: 0.86rem; line-height: 1.65; margin-bottom: 0.6rem; color: var(--text-mid); }
.arrete-text p.meta { font-size: 0.72rem; color: var(--text-light); margin-bottom: 0.3rem; }
.arrete-text ul, .arrete-text ol { margin: 0.2rem 0 0.7rem 1.2rem; }
.arrete-text ul { list-style: disc; } .arrete-text ol { list-style: decimal; }
.arrete-text li { font-size: 0.85rem; line-height: 1.55; color: var(--text-mid); margin-bottom: 0.2rem; }
.arrete-text .cell { padding-left: 0.8rem; border-left: 2px solid var(--border-light); }
.toc { background: var(--bg-soft); border: 1px solid var(--border); border-radius: 8px; padding: 0.8rem 1rem; margin-bottom: 1.5rem; font-size: 0.8rem; }
.toc a { display: inline-block; margin: 0.15rem 0.6rem 0.15rem 0; color: var(--nj-dark); text-decoration: none; }
.toc a:hover { text-decoration: underline; }
.nor-header { background: linear-gradient(135deg, var(--nj) 0%, #D91651 100%); color: white; border-radius: 12px; padding: 1.2rem 1.4rem; margin-bottom: 1.4rem; text-align: center; }
.nor-header h1 { font-size: 1.15rem; font-weight: 700; margin-bottom: 0.3rem; }
.nor-header p { font-size: 0.8rem; opacity: 0.9; line-height: 1.45; margin-bottom: 0.2rem; color: #fff; }
.nor-badge { display: inline-block; margin-top: 0.6rem; background: rgba(255,255,255,0.2); border: 1px solid rgba(255,255,255,0.35); border-radius: 20px; padding: 0.2rem 0.7rem; font-size: 0.72rem; font-weight: 600; letter-spacing: 0.03em; }

/* ========== RECHERCHE ========== */
.search-box { display: flex; align-items: center; gap: 0.5rem; background: var(--bg); border: 2px solid var(--nj); border-radius: 10px; padding: 0.5rem 0.8rem; margin-bottom: 1.2rem; }
.search-box input { flex: 1; border: none; outline: none; font-family: inherit; font-size: 1rem; color: var(--text); background: transparent; }
.search-hint, .results-count { font-size: 0.78rem; color: var(--text-light); margin-bottom: 0.8rem; }
.result-item { display: block; text-decoration: none; color: var(--text); padding: 0.75rem 0.9rem; border: 1px solid var(--border); border-radius: 8px; margin-bottom: 0.5rem; }
.result-item:hover { border-color: var(--nj); background: var(--nj-bg); }
.result-title { font-size: 0.9rem; font-weight: 700; margin-bottom: 0.2rem; }
.result-desc { font-size: 0.75rem; color: var(--text-light); line-height: 1.4; }
.result-url { font-size: 0.68rem; color: var(--nj-dark); margin-top: 0.2rem; font-family: monospace; }
.no-results { text-align: center; padding: 2rem 1rem; color: var(--text-light); font-size: 0.88rem; }
mark { background: #FFF3CD; color: var(--text); border-radius: 2px; padding: 0 2px; }

/* ========== CONFIDENTIALITÉ ========== */
.resume { background: var(--nj-bg); border: 1px solid #F9C4D3; border-radius: 0.65rem; padding: 1rem 1.25rem; margin-bottom: 1.5rem; color: var(--text-mid); font-size: 0.9rem; line-height: 1.6; }
.resume strong.t { display: block; color: var(--nj-dark); margin-bottom: 0.3rem; }
.resume ul { padding-left: 1.1rem; list-style: disc; }
.prose h2 { font-size: 1.05rem; font-weight: 700; margin: 2rem 0 0.7rem; padding-bottom: 0.3rem; border-bottom: 2px solid var(--border-light); }
.prose p, .prose li { font-size: 0.88rem; line-height: 1.65; color: var(--text-mid); }
.prose p { margin-bottom: 0.7rem; }
.prose ul { padding-left: 1.2rem; margin-bottom: 0.7rem; list-style: disc; }
.prose a { color: var(--nj-dark); }
.optout { border: 1px solid var(--border); border-radius: 0.75rem; padding: 1rem 1.25rem; background: var(--bg-soft); }
.optout .etat { font-weight: 700; color: var(--text); margin-bottom: 0.6rem; font-size: 0.9rem; }
.optout button { font-family: inherit; font-size: 0.88rem; font-weight: 600; cursor: pointer; background: var(--nj); color: #fff; border: none; border-radius: 0.5rem; padding: 0.6rem 1rem; }
.optout .note { margin: 0.7rem 0 0; font-size: 0.78rem; color: var(--text-light); }
.btn { display: inline-flex; align-items: center; gap: 0.5rem; background: var(--nj); color: #fff; font-weight: 700; padding: 0.7rem 1.4rem; border-radius: 0.6rem; text-decoration: none; font-size: 0.95rem; }
.btn.light { background: #fff; color: var(--nj-dark); }

/* ========== FOOTER ========== */
.site-footer { background: var(--bg-soft); border-top: 1px solid var(--border); padding: 1.5rem 1rem; font-size: 0.75rem; color: var(--text-light); text-align: center; line-height: 1.8; }
.site-footer a { color: var(--nj-dark); text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.footer-brand { font-weight: 800; color: var(--nj); font-size: 0.85rem; margin-bottom: 0.2rem; }
.footer-cta { display: inline-block; margin: 0.3rem 0 0.6rem; background: var(--nj); color: #fff !important; font-weight: 700; padding: 0.4rem 0.9rem; border-radius: 2rem; font-size: 0.78rem; }
.footer-links { margin-bottom: 0.4rem; }
.footer-links a, .footer-links span { margin: 0 0.5rem; }
.footer-legal { font-size: 0.7rem; }

/* ========== RESPONSIVE ========== */
@media (min-width: 768px) {
  .site-header { padding: 0.6rem 2rem; }
  .main-nav { display: flex; }
  .breadcrumb { padding: 0.6rem 2rem; }
  .page { padding: 2rem 2rem 4rem; }
  .bottom-nav { display: none !important; }
}
@media (min-width: 1024px) { .page { padding: 2.5rem 2rem 5rem; } }

/* ========== BOTTOM NAV (mobile) ========== */
.bottom-nav { display: none; }
@media (max-width: 767px) {
  .bottom-nav {
    display: flex; position: fixed; bottom: 0; left: 0; right: 0; height: 56px;
    background: var(--bg); border-top: 1px solid var(--border); z-index: 200;
    justify-content: space-around; align-items: stretch; padding-bottom: env(safe-area-inset-bottom);
    box-shadow: 0 -2px 8px rgba(0,0,0,0.06);
  }
  .bn-item { display: flex; flex-direction: column; align-items: center; justify-content: center; flex: 1; gap: 2px; text-decoration: none; color: var(--text-light); font-size: 0.6rem; font-weight: 500; padding: 6px 2px; }
  .bn-item.active { color: var(--nj); }
  .bn-icon { font-size: 1.25rem; line-height: 1; display: inline-block; padding: 2px 10px; border-radius: 8px; }
  .bn-item.active .bn-icon { background: #FDD9E3; }
  .bn-label { line-height: 1; white-space: nowrap; }
  body { padding-bottom: calc(56px + env(safe-area-inset-bottom)); }
}
