/* =========================================================
   Partenaires de savoirs · Boîte à outils HES-SO
   Charte : bleu HES-SO (Pantone 3015, #00609C) et Warm Gray 7 (#968B83)
   Version 0.1 · prototype
   ========================================================= */

:root {
  /* Couleurs institutionnelles */
  --hes-blue: #00609c;
  --hes-blue-dark: #004a78;
  --hes-blue-deep: #00314f;
  --hes-blue-tint: #e6eff5;
  --hes-blue-tint-2: #cfe0ec;
  --hes-gray: #968b83;          /* décoratif uniquement (contraste < 4.5:1) */
  --hes-gray-text: #5f5750;     /* gris chaud lisible (AA) */
  --hes-gray-tint: #f4f2f0;
  --hes-gray-line: #ddd8d3;

  /* Fonctionnel */
  --ink: #1d1d1b;
  --ink-soft: #45413d;
  --paper: #ffffff;
  --warn: #8a4b00;
  --warn-bg: #fdf3e4;
  --ok: #2d6a3e;
  --ok-bg: #e9f4ec;

  --font: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  --radius: 4px;
  --shadow: 0 1px 2px rgba(0,0,0,.06), 0 4px 16px rgba(0,49,79,.06);
  --max: 72rem;
  --gutter: clamp(1rem, 4vw, 2rem);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
}

img { max-width: 100%; height: auto; }

a { color: var(--hes-blue); text-underline-offset: 2px; }
a:hover { color: var(--hes-blue-dark); }

:focus-visible {
  outline: 3px solid var(--hes-blue);
  outline-offset: 2px;
}

h1, h2, h3, h4 { line-height: 1.25; color: var(--hes-blue-deep); margin: 0 0 .6em; }
h1 { font-size: clamp(1.75rem, 3.5vw, 2.5rem); font-weight: 700; letter-spacing: -.01em; }
h2 { font-size: clamp(1.35rem, 2.4vw, 1.75rem); font-weight: 700; margin-top: 2.2em; }
h3 { font-size: 1.2rem; font-weight: 650; margin-top: 1.6em; }
h4 { font-size: 1.05rem; font-weight: 650; }
p, ul, ol { margin: 0 0 1em; }
li { margin-bottom: .35em; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; left: .5rem; top: -3rem; z-index: 100;
  background: var(--hes-blue); color: #fff; padding: .5rem 1rem; border-radius: var(--radius);
}
.skip-link:focus { top: .5rem; color: #fff; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.narrow { max-width: 46rem; }

/* ---------- En-tête ---------- */
.site-header {
  border-bottom: 1px solid var(--hes-gray-line);
  background: #fff;
  position: sticky; top: 0; z-index: 50;
}
.site-header .wrap {
  display: flex; align-items: center; gap: 1.25rem; min-height: 4.25rem;
}
.brand {
  display: flex; align-items: center; gap: .9rem; text-decoration: none; color: var(--ink);
  flex-shrink: 0;
}
.brand-logo { height: 34px; width: auto; display: block; }
.brand-wordmark {
  font-weight: 800; font-size: 1.3rem; letter-spacing: .02em; color: var(--hes-blue);
  border: 2px dashed var(--hes-gray); padding: .05rem .5rem; border-radius: 3px;
}
.brand-sep { width: 1px; height: 30px; background: var(--hes-gray-line); }
.brand-title { font-size: .9rem; line-height: 1.2; color: var(--ink-soft); }
.brand-title strong { display: block; color: var(--hes-blue-deep); font-size: 1rem; }

.main-nav { margin-left: auto; }
.main-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: .1rem; }
.main-nav li { margin: 0; }
.main-nav a {
  display: block; padding: .5rem .55rem; border-radius: var(--radius); white-space: nowrap;
  text-decoration: none; color: var(--ink-soft); font-size: .93rem; font-weight: 500;
}
.main-nav a:hover { background: var(--hes-blue-tint); color: var(--hes-blue-deep); }
.main-nav a[aria-current="page"] { color: var(--hes-blue); box-shadow: inset 0 -3px 0 var(--hes-blue); border-radius: 0; }
.main-nav .num {
  display: inline-grid; place-items: center; width: 1.35rem; height: 1.35rem; border-radius: 50%;
  border: 1.5px solid currentColor; font-size: .75rem; font-weight: 700; margin-right: .3rem;
}
.nav-toggle {
  display: none; margin-left: auto; background: none; border: 1px solid var(--hes-gray-line);
  border-radius: var(--radius); padding: .45rem .7rem; font: inherit; color: var(--ink); cursor: pointer;
}

@media (max-width: 80rem) { .brand-title, .brand-sep { display: none; } }
@media (max-width: 62rem) {
  .nav-toggle { display: block; }
  .main-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: #fff; border-bottom: 1px solid var(--hes-gray-line); }
  .main-nav.open { display: block; }
  .main-nav ul { flex-direction: column; gap: 0; padding: .5rem var(--gutter) 1rem; }
  .main-nav a[aria-current="page"] { box-shadow: inset 3px 0 0 var(--hes-blue); }
}

/* ---------- Fil du parcours (4 moments) ---------- */
.journey {
  background: var(--hes-gray-tint); border-bottom: 1px solid var(--hes-gray-line);
  font-size: .9rem;
}
.journey ol {
  list-style: none; margin: 0 auto; padding: .6rem var(--gutter); max-width: var(--max);
  display: flex; gap: .25rem; flex-wrap: wrap; align-items: center;
}
.journey li { margin: 0; display: flex; align-items: center; gap: .25rem; color: var(--hes-gray-text); }
.journey li + li::before { content: ""; width: 1.25rem; height: 1px; background: var(--hes-gray); margin-right: .25rem; }
.journey a { color: inherit; text-decoration: none; padding: .15rem .35rem; border-radius: 3px; }
.journey a:hover { color: var(--hes-blue-deep); background: #fff; }
.journey .is-current a { color: var(--hes-blue); font-weight: 650; background: #fff; }
.journey .label-transversal { margin-left: auto; }
.journey .label-transversal::before { display: none; }

/* ---------- Zones ---------- */
main { display: block; }
.page-head { padding: clamp(2rem, 6vw, 3.5rem) 0 1.5rem; }
.eyebrow {
  display: inline-block; font-size: .8rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: var(--hes-blue); margin-bottom: .6rem;
}
.lead { font-size: 1.2rem; color: var(--ink-soft); max-width: 44rem; }
.section { padding: 1rem 0 2.5rem; }
.section-alt { background: var(--hes-gray-tint); padding: 2.5rem 0; margin: 1.5rem 0; }
.section-alt h2:first-child { margin-top: 0; }

.grid { display: grid; gap: 1.25rem; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 20rem), 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr)); }

/* ---------- Composants ---------- */
.card {
  background: #fff; border: 1px solid var(--hes-gray-line); border-radius: var(--radius);
  padding: 1.25rem 1.35rem; box-shadow: var(--shadow);
}
.card h3:first-child, .card h4:first-child { margin-top: 0; }
.card-link { display: block; text-decoration: none; color: inherit; transition: border-color .15s, transform .15s; }
.card-link:hover { border-color: var(--hes-blue); color: inherit; transform: translateY(-2px); }
@media (prefers-reduced-motion: reduce) { .card-link:hover { transform: none; } }
.card-link .more { color: var(--hes-blue); font-weight: 600; font-size: .95rem; }
.card .meta { font-size: .85rem; color: var(--hes-gray-text); }

.tag {
  display: inline-block; font-size: .78rem; font-weight: 650; letter-spacing: .03em;
  padding: .1rem .5rem; border-radius: 999px; background: var(--hes-blue-tint); color: var(--hes-blue-deep);
}
.tag-gray { background: var(--hes-gray-tint); color: var(--hes-gray-text); border: 1px solid var(--hes-gray-line); }

.callout {
  border-left: 4px solid var(--hes-blue); background: var(--hes-blue-tint);
  padding: 1rem 1.25rem; border-radius: 0 var(--radius) var(--radius) 0; margin: 1.25rem 0;
}
.callout p:last-child { margin-bottom: 0; }
.callout-title { font-weight: 700; color: var(--hes-blue-deep); display: block; margin-bottom: .25rem; }
.callout-warn { border-color: var(--warn); background: var(--warn-bg); }
.callout-warn .callout-title { color: var(--warn); }
.callout-gray { border-color: var(--hes-gray); background: var(--hes-gray-tint); }
.callout-gray .callout-title { color: var(--hes-gray-text); }

.notice-proto {
  font-size: .9rem; border: 1px dashed var(--warn); color: var(--warn); background: var(--warn-bg);
  padding: .6rem .9rem; border-radius: var(--radius); margin: 1rem 0;
}

.btn {
  display: inline-flex; align-items: center; gap: .5rem; cursor: pointer;
  font: inherit; font-weight: 600; font-size: 1rem; line-height: 1.2;
  padding: .7rem 1.2rem; border-radius: var(--radius); border: 2px solid var(--hes-blue);
  background: var(--hes-blue); color: #fff; text-decoration: none;
}
.btn:hover { background: var(--hes-blue-dark); border-color: var(--hes-blue-dark); color: #fff; }
.btn-ghost { background: #fff; color: var(--hes-blue); }
.btn-ghost:hover { background: var(--hes-blue-tint); color: var(--hes-blue-deep); }
.btn-small { padding: .4rem .8rem; font-size: .9rem; border-width: 1.5px; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.btn-row { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; }

/* Tableaux */
.table-wrap { overflow-x: auto; margin: 1rem 0 1.5rem; border: 1px solid var(--hes-gray-line); border-radius: var(--radius); }
table { border-collapse: collapse; width: 100%; font-size: .95rem; }
th, td { text-align: left; vertical-align: top; padding: .7rem .85rem; border-bottom: 1px solid var(--hes-gray-line); }
thead th { background: var(--hes-blue-tint); color: var(--hes-blue-deep); font-weight: 650; }
tbody th { font-weight: 650; color: var(--hes-blue-deep); background: #fbfaf9; min-width: 10rem; }
tbody tr:last-child th, tbody tr:last-child td { border-bottom: 0; }

/* Accordéons (details) */
details.acc {
  border: 1px solid var(--hes-gray-line); border-radius: var(--radius); background: #fff; margin: .6rem 0;
}
details.acc > summary {
  cursor: pointer; list-style: none; padding: .9rem 1.1rem; font-weight: 600; color: var(--hes-blue-deep);
  display: flex; align-items: center; gap: .75rem;
}
details.acc > summary::-webkit-details-marker { display: none; }
details.acc > summary::after {
  content: ""; margin-left: auto; width: .55rem; height: .55rem; flex-shrink: 0;
  border-right: 2px solid var(--hes-blue); border-bottom: 2px solid var(--hes-blue);
  transform: rotate(45deg); transition: transform .15s;
}
details.acc[open] > summary::after { transform: rotate(-135deg); }
details.acc > .acc-body { padding: 0 1.1rem 1.1rem; }
details.acc .acc-num {
  display: inline-grid; place-items: center; min-width: 1.8rem; height: 1.8rem; border-radius: 50%;
  background: var(--hes-blue-tint); color: var(--hes-blue-deep); font-size: .85rem; font-weight: 700;
}

/* Listes de contrôle */
.checklist { list-style: none; padding: 0; margin: 0 0 1.25rem; }
.checklist li { margin: 0; border-bottom: 1px solid var(--hes-gray-line); }
.checklist li:last-child { border-bottom: 0; }
.checklist label { display: flex; gap: .75rem; align-items: flex-start; padding: .65rem .25rem; cursor: pointer; }
.checklist input[type="checkbox"] { width: 1.2rem; height: 1.2rem; margin-top: .2rem; flex-shrink: 0; accent-color: var(--hes-blue); }
.checklist input:checked + span { color: var(--hes-gray-text); }
.checklist-progress { font-size: .85rem; color: var(--hes-gray-text); margin: -.5rem 0 1rem; }

/* Modèles à copier */
.template {
  position: relative; background: #fbfaf9; border: 1px solid var(--hes-gray-line); border-radius: var(--radius);
  padding: 1.1rem 1.25rem; white-space: pre-wrap; font-size: .95rem; line-height: 1.6; margin: .5rem 0 1rem;
}
.template .ph { background: var(--hes-blue-tint); color: var(--hes-blue-deep); padding: 0 .2rem; border-radius: 2px; }
.copy-btn { position: absolute; top: .6rem; right: .6rem; }

/* Formulaires */
.field { margin-bottom: 1rem; }
.field label, .field .label { display: block; font-weight: 600; font-size: .95rem; margin-bottom: .3rem; color: var(--ink); }
.field .hint { display: block; font-weight: 400; font-size: .85rem; color: var(--hes-gray-text); margin-bottom: .35rem; }
input[type="text"], input[type="date"], input[type="number"], select, textarea {
  width: 100%; font: inherit; font-size: 1rem; padding: .55rem .7rem; color: var(--ink);
  border: 1px solid #b5ada6; border-radius: var(--radius); background: #fff;
}
textarea { min-height: 5rem; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--hes-blue); outline: 2px solid var(--hes-blue-tint-2); outline-offset: 0; }
fieldset { border: 0; padding: 0; margin: 0 0 1rem; }
legend { font-weight: 600; padding: 0; margin-bottom: .4rem; }

.choice-list { display: grid; gap: .6rem; }
.choice {
  display: flex; gap: .85rem; align-items: flex-start; padding: .9rem 1rem; cursor: pointer;
  border: 1.5px solid var(--hes-gray-line); border-radius: var(--radius); background: #fff;
  transition: border-color .12s, background .12s;
}
.choice:hover { border-color: var(--hes-blue); }
.choice input { width: 1.15rem; height: 1.15rem; margin-top: .2rem; accent-color: var(--hes-blue); flex-shrink: 0; }
.choice:has(input:checked) { border-color: var(--hes-blue); background: var(--hes-blue-tint); }
.choice small { display: block; color: var(--hes-gray-text); font-size: .85rem; }

/* Onglets */
.tabs [role="tablist"] { display: flex; flex-wrap: wrap; gap: .25rem; border-bottom: 2px solid var(--hes-gray-line); margin-bottom: 1.25rem; }
.tabs [role="tab"] {
  font: inherit; font-size: .95rem; font-weight: 600; background: none; border: 0; cursor: pointer;
  padding: .6rem 1rem; color: var(--ink-soft); border-bottom: 3px solid transparent; margin-bottom: -2px;
}
.tabs [role="tab"]:hover { color: var(--hes-blue-deep); }
.tabs [role="tab"][aria-selected="true"] { color: var(--hes-blue); border-bottom-color: var(--hes-blue); }

/* ---------- Niveaux : pictogrammes & cartes ---------- */
.lvl-icon { width: 2.5rem; height: 2.5rem; color: var(--hes-blue); flex-shrink: 0; }
.lvl-code {
  display: inline-grid; place-items: center; font-weight: 800; font-size: .85rem; letter-spacing: .03em;
  width: 2.2rem; height: 2.2rem; border-radius: 50%; border: 2px solid var(--hes-blue); color: var(--hes-blue);
}

.flip-grid { display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr)); }
.flip { perspective: 1200px; }
.flip-inner {
  position: relative; width: 100%; height: 100%; display: grid; transition: transform .55s cubic-bezier(.3,.7,.3,1);
  transform-style: preserve-3d;
}
.flip.is-flipped .flip-inner { transform: rotateY(180deg); }
.flip-face {
  grid-area: 1 / 1; min-height: 21rem; backface-visibility: hidden; -webkit-backface-visibility: hidden;
  border: 1.5px solid var(--hes-gray-line); border-radius: 8px; background: #fff; box-shadow: var(--shadow);
  padding: 1.35rem; display: flex; flex-direction: column;
}
.flip-front { border-top: 6px solid var(--hes-blue); }
.flip-front .lvl-icon { width: 3.5rem; height: 3.5rem; margin: .5rem 0 1rem; }
.flip-front h3 { margin: 0 0 .5rem; font-size: 1.35rem; }
.flip-front .prise { font-size: .95rem; color: var(--ink-soft); }
.flip-front .prise strong { display: block; font-size: .78rem; letter-spacing: .06em; text-transform: uppercase; color: var(--hes-gray-text); }
.flip-back { visibility: hidden; transition: visibility 0s .28s; }
.flip.is-flipped .flip-back { visibility: visible; }
.flip.is-flipped .flip-front { visibility: hidden; transition: visibility 0s .28s; }
.flip-back { transform: rotateY(180deg); background: var(--hes-blue-deep); color: #fff; border-color: var(--hes-blue-deep); font-size: .92rem; }
.flip-back h3 { color: #fff; font-size: 1.1rem; margin: 0 0 .5rem; }
.flip-back dl { margin: 0; }
.flip-back dt { font-size: .74rem; letter-spacing: .07em; text-transform: uppercase; opacity: .8; margin-top: .6rem; }
.flip-back dd { margin: .1rem 0 0; }
.flip-toggle {
  margin-top: auto; align-self: flex-start; font: inherit; font-size: .9rem; font-weight: 600; cursor: pointer;
  background: none; border: 1.5px solid currentColor; border-radius: 999px; padding: .35rem .9rem; color: var(--hes-blue);
}
.flip-back .flip-toggle { color: #fff; margin-top: 1rem; }
.flip-toggle:hover { background: var(--hes-blue-tint); }
.flip-back .flip-toggle:hover { background: rgba(255,255,255,.12); }
@media (prefers-reduced-motion: reduce) {
  .flip-inner { transition: none; }
}

/* Comparateur */
.compare-pickers { display: flex; flex-wrap: wrap; gap: 1rem; align-items: end; margin-bottom: 1rem; }
.compare-pickers .field { margin: 0; min-width: 12rem; flex: 1; }
.compare-table td, .compare-table th { width: 33%; }

/* ---------- Boussole ---------- */
.compass-layout { display: grid; gap: 2rem; grid-template-columns: minmax(0, 1fr) 19rem; align-items: start; }
@media (max-width: 56rem) { .compass-layout { grid-template-columns: 1fr; } }

.compass-panel { position: sticky; top: 5.5rem; }
@media (max-width: 56rem) { .compass-panel { position: static; order: -1; } }

.gauge { display: grid; gap: .5rem; }
.gauge-item {
  display: flex; align-items: center; gap: .75rem; padding: .6rem .75rem; border-radius: var(--radius);
  border: 1.5px solid var(--hes-gray-line); background: #fff; transition: opacity .25s, border-color .25s, background .25s;
}
.gauge-item .lvl-icon { width: 1.9rem; height: 1.9rem; }
.gauge-item .g-name { font-weight: 650; font-size: .95rem; line-height: 1.2; }
.gauge-item .g-why { display: block; font-size: .78rem; color: var(--hes-gray-text); font-weight: 400; }
.gauge-item.is-locked { opacity: .5; border-style: dashed; background: var(--hes-gray-tint); }
.gauge-item.is-locked .lvl-icon { color: var(--hes-gray); }
.gauge-item.is-target { border-color: var(--hes-blue); background: var(--hes-blue-tint); }
.gauge-item .lock { margin-left: auto; width: 1rem; height: 1rem; color: var(--hes-gray-text); }

.q-progress { display: flex; gap: .3rem; margin-bottom: 1.25rem; }
.q-progress span { flex: 1; height: 5px; border-radius: 3px; background: var(--hes-gray-line); }
.q-progress span.done { background: var(--hes-blue); }
.q-progress span.current { background: var(--hes-blue-tint-2); }

.q-card { min-height: 22rem; }
.q-card .q-num { font-size: .85rem; font-weight: 700; color: var(--hes-blue); letter-spacing: .06em; text-transform: uppercase; }
.q-card h2 { margin-top: .3rem; font-size: 1.4rem; }
.q-reading { font-size: .92rem; color: var(--ink-soft); margin-top: 1rem; }

.result-hero {
  display: flex; gap: 1.25rem; align-items: center; padding: 1.5rem; border-radius: 8px;
  background: var(--hes-blue-deep); color: #fff; margin-bottom: 1.25rem;
}
.result-hero .lvl-icon { width: 4rem; height: 4rem; color: #fff; }
.result-hero h2 { color: #fff; margin: 0; font-size: 1.6rem; }
.result-hero p { margin: .2rem 0 0; opacity: .9; }

/* Fiche de niveau (détails) */
.lvl-sheet { border-top: 5px solid var(--hes-blue); }

/* Grille d'évaluation interactive */
.rubric td.selectable { cursor: pointer; }
.rubric td.selectable:hover { background: var(--hes-blue-tint); }
.rubric td.is-selected { background: var(--hes-blue-tint-2); box-shadow: inset 0 0 0 2px var(--hes-blue); }
.rubric .n3-only { font-size: .75rem; }

/* Domaines */
.domain-picker { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1.25rem; }
.domain-picker button {
  font: inherit; font-size: .92rem; font-weight: 600; cursor: pointer; padding: .5rem .95rem;
  border: 1.5px solid var(--hes-gray-line); background: #fff; border-radius: 999px; color: var(--ink-soft);
}
.domain-picker button:hover { border-color: var(--hes-blue); color: var(--hes-blue-deep); }
.domain-picker button[aria-pressed="true"] { background: var(--hes-blue); border-color: var(--hes-blue); color: #fff; }

/* Glossaire */
dl.glossary dt { font-weight: 700; color: var(--hes-blue-deep); margin-top: 1.1rem; }
dl.glossary dd { margin: .2rem 0 0; }

/* Hero accueil */
.hero { padding: clamp(2.5rem, 7vw, 4.5rem) 0 2rem; }
.hero h1 { max-width: 40rem; font-size: clamp(2rem, 4.5vw, 3rem); }
.hero .lead { margin-bottom: 1.75rem; }
.moments { counter-reset: m; display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr)); margin: 1.5rem 0; padding: 0; list-style: none; }
.moments > li { margin: 0; }
.moments .card { height: 100%; position: relative; padding-top: 3.25rem; }
.moments .card::before {
  counter-increment: m; content: counter(m);
  position: absolute; top: 1rem; left: 1.35rem; width: 1.9rem; height: 1.9rem; border-radius: 50%;
  display: grid; place-items: center; background: var(--hes-blue); color: #fff; font-weight: 700; font-size: .95rem;
}
.moments .card h3 { margin-top: 0; }
.moments .comp { font-size: .8rem; font-weight: 700; color: var(--hes-gray-text); letter-spacing: .05em; }

.warning-big {
  border: 2px solid var(--hes-blue); border-radius: 8px; padding: 1.25rem 1.5rem; background: #fff;
  display: flex; gap: 1rem; align-items: flex-start;
}
.warning-big svg { width: 2rem; height: 2rem; color: var(--hes-blue); flex-shrink: 0; margin-top: .15rem; }
.warning-big p { margin: 0; }
.warning-big strong { color: var(--hes-blue-deep); }

/* ---------- Pied de page ---------- */
.site-footer {
  margin-top: 4rem; background: var(--hes-blue-deep); color: #dfe9f0; font-size: .88rem; padding: 2.5rem 0;
}
.site-footer a { color: #fff; }
.site-footer .wrap { display: grid; gap: 1.5rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); }
.site-footer strong { color: #fff; }
.site-footer p { margin: 0 0 .5rem; }

/* Toast */
.toast {
  position: fixed; bottom: 1.25rem; left: 50%; transform: translateX(-50%) translateY(150%);
  background: var(--ink); color: #fff; padding: .7rem 1.1rem; border-radius: var(--radius); font-size: .92rem;
  transition: transform .2s; z-index: 200; max-width: calc(100% - 2rem);
}
.toast.show { transform: translateX(-50%) translateY(0); }

/* ---------- Impression ---------- */
@media print {
  .site-header, .journey, .site-footer, .btn, .btn-row, .nav-toggle, .copy-btn, .no-print, .skip-link { display: none !important; }
  body { font-size: 11pt; }
  details.acc { break-inside: avoid; }
  details.acc:not([open]) > .acc-body { display: block; }
  .card { box-shadow: none; }
  a { color: inherit; text-decoration: none; }
  textarea, input, select { border: 1px solid #999; }
  .print-only { display: block !important; }
}
.print-only { display: none; }

details.acc > summary:has([data-count])::after { margin-left: .75rem; }

/* Mobile : jauge compacte et fil du parcours défilant */
@media (max-width: 56rem) {
  .compass-panel .card { padding: .9rem; }
  .compass-panel .card > p.meta { display: none; }
  .compass-panel h2 { font-size: .95rem !important; margin-bottom: .6rem !important; }
  .gauge { grid-template-columns: repeat(4, 1fr); gap: .35rem; }
  .gauge-item { flex-direction: column; gap: .2rem; padding: .45rem .2rem; text-align: center; }
  .gauge-item .g-name { font-size: .78rem; }
  .gauge-item .g-name .g-label, .gauge-item .g-why { display: none; }
  .gauge-item .lock { position: absolute; margin: 0; width: .8rem; height: .8rem; top: .3rem; right: .3rem; }
  .gauge-item { position: relative; }
}
@media (max-width: 40rem) {
  .journey ol { flex-wrap: nowrap; overflow-x: auto; white-space: nowrap; scrollbar-width: none; }
  .journey .label-transversal { margin-left: 0; }
  .journey .label-transversal::before { display: block; }
}
