/* ==========================================================================
   Rapport PDF du diagnostic cyber : plaquette recto-verso de 2 pages A4, sur le
   modèle du rapport de Domain Check (recto : bande, chiffres clés, cartes ;
   verso : priorités, colonnes-cartes, grande bande finale).
   Feuille chargée avec media="print". Elle ne vise que #print-report (construit
   par report.js) : l'impression d'une page sans résultat n'est pas modifiée.
   Aucun liseré de couleur (bordure gauche, barre verticale d'accent).
   ========================================================================== */
@page { size: A4; margin: 0; }

body:has(#print-report) { display: block; min-height: 0; margin: 0; background: #fff; }
body:has(#print-report) > :not(#print-report) { display: none !important; }

#print-report {
  display: block;
  font-family: var(--font-text);
  font-size: 10pt;
  line-height: 1.4;
  color: var(--ink-2);
  text-align: left;
}
#print-report,
#print-report *,
#print-report *::before,
#print-report *::after {
  box-sizing: border-box;
  print-color-adjust: exact;
  -webkit-print-color-adjust: exact;
  animation: none !important;
  transition: none !important;
}
:where(#print-report) :where(p, h2, ul, ol, li) { margin: 0; padding: 0; list-style: none; }
:where(#print-report) a { color: inherit; text-decoration: underline; text-decoration-thickness: 0.2mm; text-underline-offset: 0.5mm; }
:where(#print-report) .pr-ico { display: block; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* --- Pages A4 ------------------------------------------------------------------------------------ */
.pr-page {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 210mm;
  height: 297mm;
  overflow: hidden;
  background: #fff;
  break-inside: avoid;
  break-after: page;
}
.pr-page:last-child { break-after: auto; }

/* Titres de section et sous-titres (communs aux deux pages) */
.pr-h { flex: none; margin: 0 14mm; font-family: var(--font-title); font-size: 17pt; font-weight: 800; line-height: 1.15; color: var(--navy); }
.pr-sub { flex: none; margin: 1.2mm 14mm 0; font-size: 10pt; line-height: 1.4; color: var(--ink-2); }

/* Point d'état coloré (couleur du niveau) */
.pr-dot { display: inline-block; flex: none; width: 2.6mm; height: 2.6mm; background: var(--level, #8a9bb0); border-radius: 50%; }

/* ==========================================================================
   Recto
   ========================================================================== */

/* --- Bande bleu nuit : logo, pastille, titre, accroche, date --------------------------------------- */
.pr-band {
  position: relative;
  z-index: 0;
  flex: none;
  padding: 11mm 14mm 9.5mm;
  overflow: hidden;
  color: #fff;
  background: linear-gradient(160deg, var(--navy) 0%, var(--blue) 70%);
}
.pr-band__disc {
  position: absolute;
  z-index: -1;
  top: -50mm;
  right: -30mm;
  width: 92mm;
  height: 92mm;
  background: var(--cyan);
  border-radius: 50%;
}
.pr-band__top { display: flex; align-items: center; justify-content: space-between; gap: 8mm; }
.pr-band__logo { width: auto; height: 11mm; }
.pr-title {
  margin-top: 10mm;
  font-family: var(--font-title);
  font-size: 46pt;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.02em;
  color: #fff;
}
.pr-title__accent { color: var(--cyan); }
.pr-rule { display: block; width: 26mm; height: 1.6mm; margin-top: 5mm; background: var(--cyan); border-radius: 1mm; }
.pr-hook { margin-top: 5.5mm; font-family: var(--font-title); font-size: 17pt; font-weight: 700; line-height: 1.25; color: #fff; overflow-wrap: anywhere; }
.pr-hook--long { font-size: 14pt; line-height: 1.3; }
.pr-hook__company { color: var(--cyan-light); }
.pr-lead { display: -webkit-box; margin-top: 3mm; overflow: hidden; font-size: 12pt; line-height: 1.45; color: #dbe8f4; overflow-wrap: anywhere; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; }
.pr-band__prudence { margin-top: 1.6mm; font-size: 9pt; font-style: italic; line-height: 1.4; color: #b9cfe4; }

/* --- 4 chiffres clés, séparés par des filets verticaux ----------------------------------------------- */
.pr-kpis { display: grid; flex: none; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: auto 14mm 0; padding-top: 8.5mm; }
.pr-kpi { display: flex; flex-direction: column; align-items: center; padding: 0 3mm; text-align: center; border-left: 0.3mm solid var(--mist); }
.pr-kpi:first-child { border-left: 0; }
.pr-kpi__value {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  min-height: 13mm;
  font-family: var(--font-title);
  font-size: 36pt;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--navy);
}
.pr-kpi--score .pr-kpi__value { color: var(--level); }
.pr-kpi--text .pr-kpi__value { padding-bottom: 1mm; font-size: 13.5pt; line-height: 1.15; letter-spacing: 0; text-wrap: balance; overflow-wrap: anywhere; }
.pr-kpi__label { margin-top: 2.2mm; font-family: var(--font-title); font-size: 9pt; font-weight: 500; line-height: 1.3; color: var(--ink-2); }

/* --- Ce que révèle le diagnostic : 6 cartes sur 2 colonnes ----------------------------------------- */
/* La place libre du recto est répartie à parts égales au-dessus des chiffres clés, du titre et de la bande de pied. */
.pr-h--reveal { margin-top: auto; padding-top: 8.5mm; }
.pr-cards { display: grid; flex: 0 1 auto; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 3.5mm; min-height: 0; margin: 4.5mm 14mm 0; overflow: hidden; }
.pr-card { display: flex; gap: 4.5mm; padding: 4.2mm 5mm; background: var(--ice); border-radius: 10px; }
.pr-card__icon { display: grid; flex: none; place-items: center; width: 11mm; height: 11mm; color: #fff; background: var(--navy); border-radius: 50%; }
.pr-card__icon .pr-ico { width: 5.6mm; height: 5.6mm; }
.pr-card__body { flex: 1; min-width: 0; }
.pr-card__head { display: flex; align-items: baseline; justify-content: space-between; gap: 3mm; font-family: var(--font-title); font-weight: 800; color: var(--navy); }
.pr-card__name { font-size: 12pt; line-height: 1.2; }
.pr-card__score { font-size: 13pt; line-height: 1.2; white-space: nowrap; color: var(--level); }
.pr-card__score small { font-size: 8pt; font-weight: 600; color: var(--ink-2); }
.pr-card__state { display: flex; align-items: center; gap: 1.8mm; margin-top: 0.6mm; font-family: var(--font-title); font-size: 8.5pt; font-weight: 600; color: var(--ink-2); }
.pr-card__text { margin-top: 1.6mm; font-size: 9.2pt; line-height: 1.4; color: var(--ink-2); }
.pr-card__text strong { font-weight: 700; color: var(--navy); }

/* --- Bande de pied (filet cyan au-dessus) --------------------------------------------------------- */
.pr-foot {
  display: flex;
  flex: none;
  align-items: center;
  justify-content: space-between;
  gap: 6mm;
  margin-top: auto;
  padding: 7mm 14mm;
  font-family: var(--font-title);
  color: #fff;
  background: linear-gradient(90deg, var(--navy) 0%, var(--blue) 100%);
  border-top: 1.4mm solid var(--cyan);
}
.pr-page--front .pr-cards { margin-bottom: 7mm; }
.pr-foot__left { font-size: 11pt; font-weight: 800; }
.pr-foot__right { font-size: 10pt; font-weight: 700; white-space: nowrap; }


/* ==========================================================================
   Verso : contenu calé sur le pire cas (5 priorités, 16 « Je ne sais pas », bande Sentinel) ;
   la place libre des cas plus légers est répartie par les marges automatiques
   (au-dessus des pastilles, du titre des bonnes pratiques et de la grande bande).
   ========================================================================== */
.pr-page--back::before { content: ""; display: block; flex: none; height: 2mm; background: var(--cyan); }

/* --- Bandeau clair : logo couleur, filet vertical, titre ------------------------------------------- */
.pr-head { display: flex; flex: none; align-items: center; gap: 4.5mm; padding: 4mm 14mm; background: var(--ice); border-bottom: 0.3mm solid var(--mist); }
.pr-head__logo { width: auto; height: 9.5mm; }
.pr-head__sep { flex: none; width: 0.35mm; height: 8.5mm; background: var(--mist); }
.pr-head__title { display: -webkit-box; flex: 1; min-width: 0; overflow: hidden; font-family: var(--font-title); font-size: 11pt; font-weight: 700; line-height: 1.3; color: var(--blue); overflow-wrap: anywhere; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; }

/* --- Vos priorités : pastilles cyan numérotées --------------------------------------------------- */
.pr-page--back .pr-h { font-size: 16pt; }
.pr-page--back .pr-sub { font-size: 9.5pt; }
.pr-h--prios { margin-top: 5.5mm; }
.pr-prios { display: grid; flex: 0 1 auto; gap: 2.6mm; min-height: 0; margin: 3.5mm 14mm 0; overflow: hidden; }
.pr-prio { display: grid; grid-template-columns: 7.5mm minmax(0, 1fr); gap: 3.5mm; align-items: start; }
.pr-prio__num {
  display: grid;
  place-items: center;
  width: 7.5mm;
  height: 7.5mm;
  font-family: var(--font-title);
  font-size: 10pt;
  font-weight: 800;
  color: var(--navy-900);
  background: var(--cyan);
  border-radius: 50%;
}
.pr-prio__num .pr-ico { width: 4.2mm; height: 4.2mm; stroke-width: 3; }
.pr-prio__body { padding-top: 0.9mm; }
.pr-prio__title { font-family: var(--font-title); font-size: 10pt; font-weight: 700; line-height: 1.25; color: var(--navy); }
.pr-prio__text { margin-top: 0.5mm; font-size: 8.7pt; line-height: 1.38; color: var(--ink-2); }
.pr-prio__text a { font-weight: 700; color: var(--blue); }
/* Note de 100 : la carte « Continuez ainsi » (ALL_GOOD) sur fond bleu très clair, coche dans la pastille. */
.pr-prio--good { align-items: center; padding: 4.5mm 5mm; background: var(--ice); border-radius: 10px; }
.pr-prio--good .pr-prio__body { padding-top: 0; }

/* --- À vérifier : la phrase puis les pastilles à bord fin neutre, sur un même flux ----------------- */
.pr-unknown { flex: none; margin: auto 14mm 0; padding: 3.6mm 5mm 3.8mm; background: var(--ice); border-radius: 10px; }
.pr-unknown__head { display: flex; align-items: center; gap: 3mm; }
.pr-unknown__head > .pr-mark { width: 7mm; height: 7mm; }
.pr-unknown__title { font-family: var(--font-title); font-size: 10pt; font-weight: 700; line-height: 1.25; color: var(--navy); }
.pr-unknown__sub { margin-top: 0.4mm; font-size: 8.5pt; line-height: 1.35; color: var(--ink-2); }
.pr-unknown__list { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.3mm 4mm; margin-top: 2.8mm; padding-top: 2.6mm; border-top: 0.25mm solid var(--mist); }
.pr-unknown__item { display: flex; align-items: flex-start; gap: 1.6mm; font-size: 8pt; line-height: 1.3; color: var(--ink); }
.pr-unknown__item > .pr-mark { margin-top: 0.15mm; }

/* --- 16 bonnes pratiques : 6 colonnes-cartes ------------------------------------------------------ */
.pr-h--checks { margin-top: auto; padding-top: 5mm; }
.pr-cols { display: grid; flex: none; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 2mm; margin: 3mm 12mm 0; }
.pr-col { display: flex; flex-direction: column; overflow: hidden; background: var(--ice); border-radius: 9px; }
.pr-col__head { padding: 2.3mm 2.4mm 2.1mm; background: var(--blue); }
.pr-col__name { font-family: var(--font-title); font-size: 9.5pt; font-weight: 800; line-height: 1.2; color: #fff; }
.pr-col__score { display: flex; align-items: center; gap: 1.3mm; margin-top: 0.6mm; font-family: var(--font-title); font-size: 8pt; font-weight: 700; color: #cfe0ef; }
.pr-col__score .pr-dot { width: 2.3mm; height: 2.3mm; }
.pr-col__score.level--critique { --level: #f87171; color: #fecaca; }
.pr-col__score.level--fragile { --level: #fb923c; color: #fed7aa; }
.pr-col__score.level--correct { --level: #93c5fd; color: #dbeafe; }
.pr-col__score.level--solide { --level: #4ade80; color: #bbf7d0; }
.pr-col__list { display: grid; align-content: start; gap: 1.6mm; padding: 2.5mm 2mm 2.8mm; }
.pr-col__list li { display: flex; gap: 1.3mm; align-items: flex-start; font-size: 7.6pt; line-height: 1.28; color: var(--ink); overflow-wrap: break-word; }
.pr-col__list li span { min-width: 0; }

/* Repères de réponse : ✓ vert, ◐ orange, ✗ rouge, ? gris */
.pr-mark { display: block; flex: none; width: 3.3mm; height: 3.3mm; }
.pr-mark__disc { fill: var(--mark); stroke: var(--mark); stroke-width: 1.5; }
.pr-mark__sign { fill: none; stroke: #fff; stroke-width: 2.8; stroke-linecap: round; stroke-linejoin: round; }
.pr-mark__half { fill: var(--mark); }
.pr-mark--oui { --mark: var(--ok); }
.pr-mark--non { --mark: var(--ko); }
.pr-mark--nsp { --mark: #7c8ea3; }
.pr-mark--partiel { --mark: #d97706; }
.pr-mark--partiel .pr-mark__disc { fill: #fff; stroke-width: 2.4; }

.pr-legend { display: flex; flex: none; flex-wrap: wrap; justify-content: center; gap: 1.5mm 6mm; margin: 2.8mm 14mm 4.5mm; font-family: var(--font-title); font-size: 8pt; font-weight: 600; color: var(--ink-2); }
.pr-legend li { display: flex; gap: 1.5mm; align-items: center; }

/* --- Grande bande finale : Sentinel Audit365 ou aide SF2i, puis contact et prudence ---------------- */
.pr-cta {
  flex: none;
  margin-top: auto;
  padding: 6mm 14mm 4.5mm;
  color: #dbe8f4;
  background: linear-gradient(160deg, var(--navy) 0%, var(--blue) 100%);
}
.pr-cta__title { font-family: var(--font-title); font-size: 14.5pt; font-weight: 800; line-height: 1.2; color: #fff; }
.pr-cta__lead { margin-top: 1.2mm; font-family: var(--font-title); font-size: 10pt; font-weight: 700; line-height: 1.35; color: var(--cyan-light); }
.pr-cta__steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5mm; margin-top: 3.6mm; }
.pr-cta__steps li { display: flex; gap: 2.6mm; align-items: flex-start; }
.pr-cta__num {
  display: grid;
  flex: none;
  place-items: center;
  width: 7.5mm;
  height: 7.5mm;
  font-family: var(--font-title);
  font-size: 10pt;
  font-weight: 800;
  color: var(--navy-900);
  background: var(--cyan);
  border-radius: 50%;
}
.pr-cta__steps p { padding-top: 0.6mm; font-size: 8.4pt; line-height: 1.38; color: #dbe8f4; }
.pr-cta__steps strong { display: block; font-family: var(--font-title); font-size: 9.5pt; font-weight: 700; line-height: 1.25; color: #fff; }
.pr-cta__steps strong + span { display: block; margin-top: 0.5mm; }
.pr-cta__bottom {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 6mm;
  margin-top: 3.4mm;
  padding-top: 2.8mm;
  border-top: 0.3mm solid rgb(255 255 255 / 0.25);
}
.pr-cta__contact { font-family: var(--font-title); font-size: 10.5pt; font-weight: 800; color: #fff; white-space: nowrap; }
.pr-cta__territories { font-size: 9pt; color: #dbe8f4; text-align: right; }
.pr-cta__prudence { margin-top: 1.5mm; font-size: 7.8pt; font-style: italic; line-height: 1.35; color: #a9bfd4; }

/* --- Variante compacte (report.js, versoLoad) : verso très chargé, espacements resserrés --------------- */
.pr-page--compact .pr-head { padding-top: 3.2mm; padding-bottom: 3.2mm; }
.pr-page--compact .pr-h--prios { margin-top: 4.5mm; }
.pr-page--compact .pr-prios { gap: 1.8mm; margin-top: 3mm; }
.pr-page--compact .pr-prio__text { margin-top: 0.3mm; line-height: 1.32; }
.pr-page--compact .pr-unknown { padding: 2.8mm 4.5mm 3mm; }
.pr-page--compact .pr-unknown__list { gap: 1mm 4mm; margin-top: 2.2mm; padding-top: 2mm; }
.pr-page--compact .pr-unknown__item { font-size: 7.6pt; }
.pr-page--compact .pr-h--checks { padding-top: 4mm; }
.pr-page--compact .pr-cols { margin-top: 2.6mm; }
.pr-page--compact .pr-col__list { gap: 1.2mm; padding: 2mm 2mm 2.4mm; }
.pr-page--compact .pr-col__list li { font-size: 7.3pt; line-height: 1.25; }
.pr-page--compact .pr-legend { margin: 2.2mm 14mm 3.6mm; }
.pr-page--compact .pr-cta { padding-top: 5mm; padding-bottom: 4mm; }
.pr-page--compact .pr-cta__steps { margin-top: 3mm; }
.pr-page--compact .pr-cta__bottom { margin-top: 2.8mm; padding-top: 2.4mm; }