/* remplacer-chaudiere-gaz.fr — charte « Bleu » (spec §12). Chargé après bootstrap.min.css. */

@font-face {
  font-family: 'Archivo';
  src: url('../fonts/archivo-wdth.woff2') format('woff2-variations');
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
}
@font-face { font-family: 'Figtree'; src: url('../fonts/figtree-400.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Figtree'; src: url('../fonts/figtree-500.woff2') format('woff2'); font-weight: 500; font-display: swap; }
@font-face { font-family: 'Figtree'; src: url('../fonts/figtree-600.woff2') format('woff2'); font-weight: 600; font-display: swap; }
@font-face { font-family: 'Figtree'; src: url('../fonts/figtree-700.woff2') format('woff2'); font-weight: 700; font-display: swap; }
@font-face { font-family: 'Figtree'; src: url('../fonts/figtree-800.woff2') format('woff2'); font-weight: 800; font-display: swap; }

:root {
  --ground: #F5F8FD;
  --surface: #FFFFFF;
  --line: #DCE4F2;
  --field: #AFBDD6;
  --ink: #0E1F3D;
  --text2: #3A4A66;
  --muted: #4B5A7A;
  --brand: #2373F4;
  --primary: #1A5FD3;
  --primary-hover: #154FB0;
  --soft: #E6EFFE;
  --dark: #0E1F3D;
  --dark-sub: #C9D3E6;
  --dark-chip: #1B3260;
  --dark-label: #9FC1F7;
  --cta: #F2F7A0;
  --cta-hover: #E8EE7E;
  --pac-dark: #65D0F4;
  --gas: #AFBDD6;
  --gas-dark: #8C9AB3;
  --note: #FBFCE3;
  --note-line: #E3EA7A;
  --note-text: #3D3F12;
  --focus: #F2A900;
  --danger: #B42318;
  --display: 'Archivo', 'Arial Narrow', sans-serif;
  --body: 'Figtree', system-ui, -apple-system, 'Segoe UI', sans-serif;

  --bs-body-font-family: var(--body);
  --bs-body-color: var(--ink);
  --bs-body-bg: var(--ground);
  --bs-link-color-rgb: 26, 95, 211;
  --bs-link-hover-color-rgb: 21, 79, 176;
  --bs-border-color: var(--line);
}

body { font-family: var(--body); color: var(--ink); background: var(--ground); font-size: 1rem; line-height: 1.55; }
h1, h2, h3, .display { font-family: var(--display); font-stretch: 112%; font-weight: 800; letter-spacing: -0.015em; color: var(--ink); }
h1, h2 { text-wrap: balance; }
h1 { font-size: clamp(2rem, 4vw, 3.1rem); line-height: 1.08; letter-spacing: -0.02em; }
h2 { font-size: clamp(1.6rem, 2.6vw, 2rem); line-height: 1.15; margin-bottom: 1.25rem; }
h3 { font-family: var(--body); font-stretch: normal; font-size: 1.2rem; font-weight: 700; letter-spacing: 0; }
a { color: var(--primary); }
a:hover { color: var(--primary-hover); }
.num { font-variant-numeric: tabular-nums; }
.text-2 { color: var(--text2); }
.text-muted-2 { color: var(--muted); }
.lead-text { font-size: 1.125rem; color: var(--text2); max-width: 36rem; }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.skip-link { position: absolute; left: -9999px; top: 0; background: var(--ink); color: #fff; padding: .5rem 1rem; z-index: 100; }
.skip-link:focus { left: 1rem; top: 1rem; }

.wrap { max-width: 1200px; margin: 0 auto; padding-left: 1rem; padding-right: 1rem; }
@media (min-width: 768px) { .wrap { padding-left: 1.5rem; padding-right: 1.5rem; } }
.wrap-narrow { max-width: 860px; }
.section { padding-top: 3.5rem; padding-bottom: 1.5rem; }

/* ---------- Header / footer ---------- */
.site-header { background: var(--surface); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem 1.5rem; padding-top: .85rem; padding-bottom: .85rem; }
.brand { display: flex; align-items: center; gap: .6rem; text-decoration: none; color: var(--ink); }
.brand:hover { color: var(--ink); }
.brand-name { display: block; font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 1.15rem; line-height: 1.1; letter-spacing: -0.01em; }
.brand-name span { color: var(--brand); }
.brand-tag { display: block; font-size: .75rem; color: var(--muted); font-weight: 500; }
.main-nav { display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; font-weight: 600; font-size: .95rem; }
.main-nav a { color: var(--text2); text-decoration: none; }
.main-nav a:hover { color: var(--primary); text-decoration: underline; }
.main-nav { align-items: center; }
.main-nav a[aria-current="page"] { color: var(--primary); }
.nav-menu { position: relative; }
.nav-menu summary { list-style: none; cursor: pointer; color: var(--text2); }
.nav-menu summary::-webkit-details-marker { display: none; }
.nav-menu summary::after { content: ""; display: inline-block; width: .4em; height: .4em; margin-left: .4em; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: translateY(-.2em) rotate(45deg); transition: transform .15s; }
.nav-menu[open] summary::after { transform: translateY(0) rotate(-135deg); }
.nav-menu summary:hover { color: var(--primary); }
.nav-panel { position: absolute; z-index: 20; top: calc(100% + .6rem); right: 0; min-width: 17rem; max-width: calc(100vw - 2rem); display: flex; flex-direction: column; padding: .4rem; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 12px 32px rgba(14, 31, 61, .12); font-weight: 500; }
.nav-panel::before { content: ""; position: absolute; left: 0; right: 0; top: -.7rem; height: .7rem; }
.nav-panel a { padding: .55rem .75rem; border-radius: 8px; }
.nav-panel a:hover { background: var(--soft); text-decoration: none; }
.header-actions { display: none; }
/* Mobile et tablette : bouton « Faire le test » + burger, menu en panneau pleine largeur */
@media (max-width: 991.98px) {
  .site-header { position: relative; z-index: 30; }
  .site-header .wrap { flex-wrap: nowrap; padding-top: .7rem; padding-bottom: .7rem; }
  .header-actions { display: flex; align-items: center; gap: .5rem; flex: none; }
  .header-test { display: inline-flex; align-items: center; min-height: 42px; padding: 0 .9rem; border-radius: 10px; background: var(--cta); color: var(--ink); font-weight: 800; font-size: .9rem; text-decoration: none; white-space: nowrap; }
  .header-test:hover { background: var(--cta-hover); color: var(--ink); }
  .burger { width: 44px; height: 44px; flex: none; display: inline-flex; align-items: center; justify-content: center; padding: 0; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); cursor: pointer; }
  .burger svg { fill: none; stroke: var(--ink); stroke-width: 2.2; stroke-linecap: round; }
  .burger-close, .menu-ouvert .burger-open { display: none; }
  .menu-ouvert .burger-close { display: block; }
  .main-nav { display: none; }
  .menu-ouvert .main-nav { display: flex; flex-direction: column; align-items: stretch; gap: 0; position: absolute; top: 100%; left: 0; right: 0; max-height: calc(100vh - 70px); overflow-y: auto; padding: .25rem 1rem 1rem; background: var(--surface); border-top: 1px solid var(--line); box-shadow: 0 16px 32px rgba(14, 31, 61, .14); font-size: 1rem; }
  .menu-ouvert .main-nav > a, .menu-ouvert .nav-menu summary { display: block; padding: .8rem .25rem; border-bottom: 1px solid var(--line); color: var(--ink); font-weight: 700; text-decoration: none; }
  .menu-ouvert .main-nav > a[aria-current="page"] { color: var(--primary); }
  .menu-ouvert .main-nav > a:last-child { border-bottom: 0; }
  .menu-ouvert .nav-menu { position: static; border-bottom: 1px solid var(--line); }
  .menu-ouvert .nav-menu summary { border-bottom: 0; padding-bottom: .3rem; pointer-events: none; }
  .menu-ouvert .nav-menu summary::after { display: none; }
  .menu-ouvert .nav-panel { position: static; min-width: 0; max-width: none; padding: 0 0 .5rem .75rem; border: 0; border-radius: 0; box-shadow: none; background: none; }
  .menu-ouvert .nav-panel::before { display: none; }
  .menu-ouvert .nav-panel a { padding: .5rem .25rem; color: var(--text2); }
  .menu-ouvert .nav-panel a[aria-current="page"] { color: var(--primary); font-weight: 700; }
}
@media (max-width: 575.98px) {
  .brand-tag { display: none; }
  .brand-name { font-size: 1rem; }
  .brand svg { width: 30px; height: 30px; }
}

.site-footer { background: var(--dark); color: var(--dark-sub); margin-top: 4rem; }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1.5rem; padding-top: 2.5rem; padding-bottom: 2.5rem; font-size: .9rem; }
.site-footer a { color: var(--dark-sub); }
.site-footer a:hover { color: #fff; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; }
.site-footer .footer-guides { flex-direction: column; gap: .45rem; flex-basis: 100%; }
@media (min-width: 768px) { .site-footer .footer-guides { flex-basis: auto; } }
.footer-title { color: #fff; font-weight: 700; font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; }
.footer-brand { font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 1.1rem; color: #fff; }
.footer-brand span { color: var(--dark-label); }

/* ---------- Composants ---------- */
.pill { display: inline-flex; align-items: center; gap: .5rem; font-size: .875rem; font-weight: 700; color: var(--primary); background: var(--soft); padding: .35rem .75rem; border-radius: 999px; }
.card-x { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 1.5rem; }
.grid-auto { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1.5rem; }
.step-num { font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 1.75rem; color: var(--primary); line-height: 1; }
.top-rule { border-top: 4px solid var(--dark); padding-top: 1rem; }
.note { background: var(--note); border: 1px solid var(--note-line); color: var(--note-text); border-radius: 16px; padding: 1.15rem 1.5rem; display: flex; gap: .85rem; align-items: flex-start; }
.note svg { flex: 0 0 auto; margin-top: 2px; }
.trust { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.trust .wrap { display: flex; flex-wrap: wrap; gap: .75rem 2.5rem; padding-top: 1.25rem; padding-bottom: 1.25rem; color: var(--text2); font-size: .95rem; }
.trust .item { display: flex; align-items: center; gap: .6rem; }

.table-x { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; min-width: 540px; }
.table-x th, .table-x td { padding: .85rem 1.25rem; text-align: left; }
.table-x thead tr { background: var(--soft); }
.table-x tbody tr { border-top: 1px solid var(--line); }
.table-scroll { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; }

/* Boutons */
.btn-x { display: inline-flex; align-items: center; justify-content: center; gap: .6rem; min-height: 54px; padding: 0 1.4rem; border: 0; border-radius: 12px; font-family: var(--body); font-weight: 800; font-size: 1.05rem; text-decoration: none; cursor: pointer; transition: background-color .15s; }
.btn-primary-x { background: var(--primary); color: #fff; }
.btn-primary-x:hover { background: var(--primary-hover); color: #fff; }
.btn-cta { background: var(--cta); color: var(--ink); width: 100%; }
.btn-cta:hover { background: var(--cta-hover); color: var(--ink); }
.btn-ghost { background: var(--surface); color: var(--ink); border: 1px solid var(--line); min-height: 44px; font-weight: 700; }
.btn-x[disabled] { background: var(--line); color: var(--muted); cursor: not-allowed; }

/* Champs */
.field { display: flex; flex-direction: column; gap: .35rem; }
.field label, .field .label { font-weight: 700; font-size: .95rem; }
.field .hint { font-size: .82rem; color: var(--muted); }
.field .error { font-size: .85rem; color: var(--danger); font-weight: 600; }
.input-x { width: 100%; border: 1px solid var(--field); border-radius: 10px; padding: .85rem 1rem; font-size: 1.1rem; font-family: var(--body); color: var(--ink); background: #fff; font-variant-numeric: tabular-nums; }
.input-x.small { font-size: 1rem; padding: .8rem .9rem; }
.input-x[aria-invalid="true"] { border-color: var(--danger); }
.input-unit { display: flex; align-items: center; border: 1px solid var(--field); border-radius: 10px; background: #fff; }
.input-unit .input-x { border: 0; }
.input-unit span { padding: 0 1rem; color: var(--muted); font-weight: 500; white-space: nowrap; }
.input-unit:focus-within { outline: 3px solid var(--focus); outline-offset: 2px; }
.input-unit .input-x:focus-visible { outline: none; }
.check { display: flex; gap: .75rem; align-items: flex-start; font-size: .9rem; color: var(--text2); }
.check input { width: 22px; height: 22px; flex: 0 0 auto; margin-top: 2px; accent-color: var(--primary); }

/* ---------- Accueil : estimation express ---------- */
.hero { padding-top: 3rem; padding-bottom: 2.5rem; }
.hero-grid { display: flex; flex-wrap: wrap; gap: 2.5rem; align-items: flex-start; }
.hero-text { flex: 1 1 480px; min-width: 0; display: flex; flex-direction: column; gap: 1.5rem; }
.estimate { flex: 1 1 380px; min-width: 0; background: var(--dark); color: #fff; border-radius: 20px; padding: 1.75rem; display: flex; flex-direction: column; gap: 1.25rem; }
.estimate .over { font-size: .85rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--dark-label); }
.estimate .chip { font-size: .8rem; color: var(--dark-sub); background: var(--dark-chip); padding: .25rem .65rem; border-radius: 999px; }
.estimate .sub { color: var(--dark-sub); font-size: .95rem; }
.estimate .big { font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: clamp(2rem, 3.5vw, 2.6rem); line-height: 1.1; font-variant-numeric: tabular-nums; color: #fff; }
.bar-row { display: flex; flex-direction: column; gap: .35rem; }
.bar-row .labels { display: flex; justify-content: space-between; font-size: .875rem; gap: .5rem; }
.bar-track { height: 12px; background: var(--dark-chip); border-radius: 6px; overflow: hidden; }
.bar-fill { height: 12px; border-radius: 6px; transition: width .3s; }
.bar-gas { background: var(--gas-dark); }
.bar-pac { background: var(--pac-dark); }

/* ---------- Questionnaire ---------- */
.quiz { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; max-width: 640px; margin: 0 auto; overflow: hidden; }
.quiz-head { padding: 1rem 1.25rem .85rem; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: .75rem; }
.quiz-head .row-x { display: flex; align-items: center; justify-content: space-between; }
.quiz-back { width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--line); border-radius: 12px; background: #fff; color: var(--ink); }
.progress-x { height: 8px; background: #E2E9F5; border-radius: 4px; }
.progress-x div { height: 8px; background: var(--brand); border-radius: 4px; transition: width .25s; }
.quiz-body { padding: 1.5rem 1.25rem; display: flex; flex-direction: column; gap: 1.1rem; }
.quiz-body h2 { font-size: 1.6rem; margin: 0; }
.options { display: flex; flex-direction: column; gap: .6rem; border: 0; padding: 0; margin: 0; }
.option { display: flex; align-items: center; gap: .9rem; min-height: 60px; padding: .75rem 1rem; border: 2px solid var(--line); border-radius: 14px; background: #fff; cursor: pointer; }
.option input { position: absolute; opacity: 0; pointer-events: none; }
.option .dot { flex: 0 0 auto; width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--gas-dark); background: #fff; }
.option .t { display: block; font-weight: 700; font-size: 1.05rem; }
.option .s { display: block; font-size: .82rem; color: var(--muted); }
.option:has(input:checked) { border-color: var(--primary); background: var(--soft); }
.option:has(input:checked) .dot { border: 6px solid var(--primary); }
.option:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; }
.quiz-foot { padding: .9rem 1.25rem 1.25rem; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: .75rem; }
.quiz-foot .est { display: flex; justify-content: space-between; align-items: baseline; gap: .5rem; }
.stepper { display: flex; align-items: center; gap: .75rem; }
.stepper button { width: 52px; height: 52px; border: 1px solid var(--field); border-radius: 12px; background: #fff; font-size: 1.5rem; color: var(--ink); }
.stepper output { min-width: 48px; text-align: center; font-family: var(--display); font-stretch: 112%; font-size: 1.9rem; font-weight: 800; }
.profil-box { background: var(--soft); border-radius: 12px; padding: .85rem 1rem; }
.profil-box strong { color: var(--primary); font-size: 1.05rem; }

/* ---------- Résultat ---------- */
.verdict-badge { display: inline-flex; align-items: center; gap: .5rem; font-weight: 800; font-size: .95rem; padding: .35rem .9rem; border-radius: 999px; background: var(--cta); color: var(--ink); }
.verdict-badge.neutre { background: var(--soft); color: var(--primary); }
.verdict-badge.alerte { background: #FDE8D7; color: #7A2E0B; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1rem; }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 1.25rem; display: flex; flex-direction: column; gap: .3rem; }
.kpi .k { font-size: .9rem; color: var(--text2); }
.kpi .v { font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 1.75rem; font-variant-numeric: tabular-nums; }
.kpi .d { font-size: .82rem; color: var(--muted); }
.kpi.dark { background: var(--dark); border-color: var(--dark); color: #fff; }
.kpi.dark .k, .kpi.dark .d { color: var(--dark-sub); }
.kpi.dark .v { color: #fff; }
.chart { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: .85rem .75rem; align-items: center; font-variant-numeric: tabular-nums; }
.chart .y { font-weight: 700; font-size: .9rem; }
.chart .bars { display: flex; flex-direction: column; gap: .25rem; }
.chart .b { display: flex; align-items: center; gap: .5rem; font-size: .82rem; }
.chart .b i { display: block; height: 14px; border-radius: 3px; }
.chart .g i { background: var(--gas); }
.chart .p i { background: var(--brand); }
.legend { display: flex; flex-wrap: wrap; gap: 1.25rem; font-size: .875rem; }
.legend span { display: inline-flex; align-items: center; gap: .5rem; }
.legend i { width: 14px; height: 14px; border-radius: 3px; display: inline-block; }
.aides-table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.aides-table th, .aides-table td { padding: .7rem 0; }
.aides-table th { font-weight: 500; text-align: left; }
.aides-table td { text-align: right; font-weight: 800; }
.aides-table tr + tr { border-top: 1px solid var(--line); }
.aides-table .muted th, .aides-table .muted td { color: var(--muted); font-weight: 500; }
.tag-couleur { display: inline-block; margin-left: .35rem; font-size: .75rem; font-weight: 800; padding: .1rem .5rem; border-radius: 999px; }
.tag-bleu { background: #D6E4FF; color: #0E2E6E; }
.tag-jaune { background: #F7E7A6; color: #4D3B00; }
.tag-violet { background: #E8DCFA; color: #3E1A78; }
.tag-rose { background: #FADCE8; color: #6E0F3A; }
.devis { background: var(--dark); color: #fff; border-radius: 24px; padding: 1.75rem; display: flex; flex-wrap: wrap; gap: 2rem; }
@media (min-width: 768px) { .devis { padding: 2.25rem; } }
.devis h2 { color: #fff; }
.devis .intro { flex: 1 1 280px; display: flex; flex-direction: column; gap: 1rem; color: var(--dark-sub); }
.devis form, .devis .form-box { flex: 2 1 460px; min-width: 0; background: #fff; color: var(--ink); border-radius: 18px; padding: 1.5rem; display: flex; flex-direction: column; gap: 1rem; }
.chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.chips span { font-size: .875rem; background: var(--soft); padding: .35rem .75rem; border-radius: 999px; }
.form-msg { border-radius: 12px; padding: 1rem; font-weight: 600; }
.form-msg.ok { background: #E3F4EA; color: #14532D; }
.form-msg.ko { background: #FDE8E7; color: #7A1A12; }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
details.hyp { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: .25rem 1.5rem; }
details.hyp summary { cursor: pointer; padding: 1rem 0; font-weight: 700; }

/* ---------- FAQ ---------- */
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; margin-bottom: .75rem; }
.faq summary { list-style: none; cursor: pointer; min-height: 56px; display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 1rem 1.25rem; font-weight: 700; font-size: 1.05rem; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; font-size: 1.4rem; color: var(--primary); }
.faq details[open] summary::after { content: '−'; }
.faq details p { padding: 0 1.25rem 1.1rem; margin: 0; color: var(--text2); }

/* ---------- Bloc auteur ---------- */
.author { display: flex; flex-wrap: wrap; gap: 1.25rem; align-items: center; }
.author .ico { width: 56px; height: 56px; border-radius: 14px; background: var(--soft); display: flex; align-items: center; justify-content: center; flex: 0 0 auto; }

/* ---------- Pages de texte ---------- */
.prose { max-width: 760px; }
.prose h2 { font-size: 1.5rem; margin-top: 2.25rem; margin-bottom: .75rem; }
.prose p, .prose li { color: var(--text2); }
.prose table { width: 100%; border-collapse: collapse; margin: 1rem 0; font-variant-numeric: tabular-nums; }
.prose th, .prose td { border-top: 1px solid var(--line); padding: .6rem .5rem; text-align: left; vertical-align: top; }
.prose thead th { background: var(--soft); border-top: 0; }
.breadcrumb-x { font-size: .875rem; color: var(--muted); margin-bottom: 1rem; }
.breadcrumb-x a { color: var(--muted); }

[hidden] { display: none !important; }

/* ---------- Impression / PDF du résultat ---------- */
.print-only { display: none; }
@media print {
  @page { margin: 14mm; }
  body { background: #fff; font-size: 11pt; }
  .skip-link, .main-nav, .header-actions, .site-footer, .no-print, #devis, #devis-discret { display: none !important; }
  .print-only { display: block !important; }
  .site-header { border-bottom: 2px solid var(--ink); }
  .wrap { max-width: none; padding-left: 0; padding-right: 0; }
  .card-x, .kpi, .note, details.hyp, figure, section { break-inside: avoid; }
  .kpi.dark { background: #fff !important; border: 2px solid var(--ink) !important; }
  .kpi.dark .k, .kpi.dark .d, .kpi.dark .v { color: var(--ink) !important; }
  .chart i, .legend i, .verdict-badge, .tag-couleur, .pill { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  a { color: inherit; text-decoration: none; }
  details.hyp summary { list-style: none; }
}

/* ===== Composants éditoriaux (pages piliers) ===== */
.tldr { background: var(--soft); border: 1px solid #C9DAFB; border-left: 5px solid var(--brand); border-radius: 16px; padding: 1.15rem 1.5rem; margin: 1.5rem 0; }
.prose .tldr-title { font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 1.15rem; color: var(--ink); margin: 0 0 .5rem; }
.tldr ul { margin: 0; padding: 0; list-style: none; }
.prose .tldr li { position: relative; padding-left: 1.6rem; margin: .35rem 0; color: var(--ink); }
.tldr li::before { content: ""; position: absolute; left: 0; top: .3rem; width: 1.05rem; height: 1.05rem; border-radius: 50%; background: var(--brand) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center/70% no-repeat; }

.callout { border-radius: 14px; padding: 1rem 1.25rem 1rem 3.25rem; margin: 1.25rem 0; position: relative; border: 1px solid; }
.callout::before { content: ""; position: absolute; left: 1.05rem; top: 1.05rem; width: 1.4rem; height: 1.4rem; background: center/contain no-repeat; }
.callout-title { display: block; font-weight: 800; margin-bottom: .25rem; color: var(--ink); }
.prose .callout p, .prose .callout li { color: var(--ink); }
.callout p:last-child, .callout ul:last-child { margin-bottom: 0; }
.callout--retenir { background: #EEF4FF; border-color: #C9DAFB; }
.callout--retenir::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231A5FD3' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 2l2.9 6.3 6.9.7-5.2 4.6 1.5 6.8L12 17l-6.1 3.4 1.5-6.8L2.2 9l6.9-.7z'/%3E%3C/svg%3E"); }
.callout--attention { background: #FEF3F2; border-color: #F6C8C3; }
.callout--attention::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23B42318' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3l10 18H2z'/%3E%3Cpath d='M12 10v5M12 18h.01'/%3E%3C/svg%3E"); }
.callout--attention .callout-title { color: var(--danger); }
.callout--savoir { background: var(--note); border-color: var(--note-line); }
.callout--savoir::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%233D3F12' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 8v.01M12 11v5'/%3E%3C/svg%3E"); }
.callout--exemple { background: var(--surface); border-color: var(--line); }
.callout--exemple::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231A5FD3' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 11l9-7 9 7v9a1 1 0 0 1-1 1h-5v-6h-6v6H4a1 1 0 0 1-1-1z'/%3E%3C/svg%3E"); }

.case-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1rem; margin: 1.25rem 0; }
.case-card { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 1.15rem 1.25rem; display: flex; flex-direction: column; }
.case-card h3 { font-size: 1.05rem; margin: 0 0 .35rem; }
.case-card .case-detail { font-size: .92rem; color: var(--muted); margin: 0 0 .75rem; }
.case-card dl { margin: 0; font-size: .95rem; font-variant-numeric: tabular-nums; }
.case-card dl div { display: flex; justify-content: space-between; gap: .75rem; padding: .3rem 0; border-top: 1px solid var(--line); }
.case-card dt { font-weight: 500; color: var(--text2); }
.case-card dd { margin: 0; font-weight: 700; color: var(--ink); text-align: right; white-space: nowrap; }
.case-card .case-rac { margin-top: auto; padding-top: .75rem; }
.case-card .case-rac span { display: block; font-size: .85rem; color: var(--muted); }
.case-card .case-rac strong { font-family: var(--display); font-stretch: 112%; font-size: 1.7rem; color: var(--primary); }

.qcm { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 1.5rem; margin: 2rem 0; }
.prose .qcm-head { font-family: var(--display); font-stretch: 112%; font-weight: 800; font-size: 1.3rem; margin: 0 0 .25rem; color: var(--ink); }
.qcm-q { border-top: 1px solid var(--line); padding: 1rem 0; }
.qcm-q:first-of-type { border-top: 0; }
.prose .qcm-q-title { font-weight: 700; color: var(--ink); margin: 0 0 .6rem; }
.qcm-opts { display: grid; gap: .5rem; }
.qcm-opt { text-align: left; background: var(--ground); border: 1.5px solid var(--line); border-radius: 12px; padding: .7rem .9rem; font: inherit; color: var(--ink); cursor: pointer; min-height: 44px; }
.qcm-opt:hover:not([disabled]) { border-color: var(--primary); }
.qcm-opt:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.qcm-opt[disabled] { cursor: default; }
.qcm-opt.is-right { background: #ECFDF3; border-color: #2E9E5B; }
.qcm-opt.is-wrong { background: #FEF3F2; border-color: var(--danger); }
.qcm-expl { margin: .6rem 0 0; font-size: .95rem; color: var(--text2); }
.qcm.qcm-ready .qcm-expl { display: none; }
.qcm.qcm-ready .qcm-q.is-done .qcm-expl { display: block; }
.qcm-result { display: none; margin-top: 1rem; padding: 1rem 1.25rem; border-radius: 14px; background: var(--soft); }
.qcm-result.is-visible { display: block; }
.prose .qcm-result p { margin: 0 0 .75rem; color: var(--ink); font-weight: 600; }
.prose p.short { max-width: 40rem; }

/* ---------- À lire aussi ---------- */
.lire-aussi { margin-top: 1.5rem; padding: 1rem 1.25rem; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; }
.lire-aussi-titre { margin: 0 0 .4rem; font-weight: 700; color: var(--ink); }
.lire-aussi ul { margin: 0; padding-left: 1.1rem; }
.lire-aussi li { margin: .25rem 0; }

/* ---------- Évolution (flèches) ---------- */
.evo { position: relative; display: inline-flex; align-items: center; gap: .35rem; font-weight: 700; white-space: nowrap; }
.evo svg { fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.evo--hausse { color: var(--danger); }
.evo--baisse { color: #157F3D; }
.evo--baisse svg { transform: scaleY(-1); }
.evo--stable { color: var(--muted); font-weight: 600; }
.visually-hidden { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; border: 0 !important; }

/* ---------- Guides sur grand écran : sommaire fixe à droite ---------- */
.toc-cta { display: none; }
@media (min-width: 1200px) {
  .prose:has(> .toc) { max-width: none; display: grid; grid-template-columns: minmax(0, 760px) 290px; column-gap: 4rem; justify-content: space-between; }
  .prose:has(> .toc) > * { grid-column: 1; }
  .prose:has(> .toc) > .toc { grid-column: 2; grid-row: 1 / span 400; align-self: start; position: sticky; top: 1.5rem; margin-top: 0 !important; max-height: calc(100vh - 3rem); overflow-y: auto; font-size: .92rem; }
  .prose:has(> .toc) > h2 { margin-top: 1.5rem; }
  .toc ol { padding-left: 1.2rem; }
  .toc li { margin: .3rem 0; }
  .toc a { text-decoration: none; }
  .toc a:hover { text-decoration: underline; }
  .toc a.is-active { color: var(--primary); font-weight: 700; }
  .toc-cta { display: flex; width: 100%; margin-top: 1rem; min-height: 46px; font-size: .95rem; }
}

/* Arrivée sur le simulateur depuis un bouton « Faire le test » */
@keyframes express-flash { 0% { box-shadow: 0 0 0 0 rgba(35, 115, 244, .55); } 70% { box-shadow: 0 0 0 14px rgba(35, 115, 244, 0); } 100% { box-shadow: 0 0 0 0 rgba(35, 115, 244, 0); } }
.express-flash { animation: express-flash 1.2s ease-out 2; }
@media (prefers-reduced-motion: reduce) { .express-flash { animation: none; } }

/* Statut d'une mesure (calendrier réglementaire) */
.statut { display: inline-block; padding: .15rem .55rem; border-radius: 999px; font-size: .8rem; font-weight: 700; white-space: nowrap; }
.statut--en_vigueur { background: #E5F4E4; color: #14532D; }
.statut--publie { background: var(--soft); color: var(--primary-hover); }
.statut--annonce { background: #F9EEDA; color: #7A4B00; }
.statut--objectif { background: #F0EFEC; color: var(--text2); }
.case-grid--2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)) !important; }
.statut + br { line-height: 2; }
.table-x--fluide { min-width: 0; }
@media (max-width: 575.98px) { .table-x--fluide th, .table-x--fluide td { padding: .7rem .6rem; } .table-x--fluide td:first-child { width: 6.5rem; } }
