/* Bailleur Avisé — direction « fiche pratique », version adoucie.
   Jaune signalétique et blanc, illustrations au trait, coins arrondis, ombres légères.
   Polices auto-hébergées (aucun appel à un service tiers). */

@font-face { font-family: "Archivo"; font-weight: 400; font-display: swap; src: url("/assets/fonts/archivo-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Archivo"; font-weight: 600; font-display: swap; src: url("/assets/fonts/archivo-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Archivo"; font-weight: 800; font-display: swap; src: url("/assets/fonts/archivo-latin-800-normal.woff2") format("woff2"); }
@font-face { font-family: "Archivo"; font-weight: 900; font-display: swap; src: url("/assets/fonts/archivo-latin-900-normal.woff2") format("woff2"); }
@font-face { font-family: "Source Serif"; font-weight: 400; font-display: swap; src: url("/assets/fonts/source-serif-4-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Source Serif"; font-weight: 600; font-display: swap; src: url("/assets/fonts/source-serif-4-latin-600-normal.woff2") format("woff2"); }

:root {
  color-scheme: light;
  --jaune: #ffd23f;
  --jaune-doux: #fff3c4;
  --jaune-pale: #fffaf0;
  --encre: #1d1d1b;
  --papier: #ffffff;
  --fond: #f7f5ef;
  --gris: #57554f;
  --trait: #ebe7dc;
  --trait-fort: #d9d3c3;
  --ombre: 0 1px 2px rgba(29, 29, 27, .04), 0 10px 30px -12px rgba(29, 29, 27, .14);
  --ombre-forte: 0 2px 4px rgba(29, 29, 27, .05), 0 18px 40px -16px rgba(29, 29, 27, .22);
  --r: 16px;
  --r-sm: 10px;
  --font: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --doc: "Source Serif", Georgia, serif;
  --measure: 68ch;
  --ink: var(--encre);
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; font-size: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
body { margin: 0; background: var(--papier); color: var(--encre); font: 400 1.125rem/1.65 var(--font); }
h1, h2, h3 { text-wrap: balance; }
p, li { text-wrap: pretty; }
table { font-variant-numeric: tabular-nums; }
@media (prefers-reduced-motion: no-preference) { @view-transition { navigation: auto; } }
img, svg { max-width: 100%; height: auto; }
a { color: var(--encre); text-underline-offset: 4px; text-decoration-thickness: 1.5px; text-decoration-color: rgba(29, 29, 27, .45); }
a:hover { text-decoration-color: var(--jaune); text-decoration-thickness: 3px; }
:focus-visible { outline: 3px solid var(--encre); outline-offset: 3px; border-radius: 4px; }
p { margin: 0 0 1em; }

h1, h2, h3, .h3 { color: var(--encre); letter-spacing: -0.02em; }
h1 { font-weight: 900; font-size: clamp(2.1rem, 5vw, 3.6rem); line-height: 1.04; margin: 0 0 .4em; }
h2 { font-weight: 800; font-size: clamp(1.5rem, 3vw, 2.1rem); line-height: 1.12; margin: 2em 0 .6em; }
h3, .h3 { font-weight: 800; font-size: 1.2rem; line-height: 1.3; margin: 0 0 .3em; letter-spacing: -0.01em; }

.wrap { max-width: 1160px; margin: 0 auto; padding: 0 20px; }
.narrow { max-width: calc(var(--measure) + 40px); }
.muted { color: var(--gris); }
.small { font-size: .9rem; }
.lead { font-size: 1.2rem; max-width: 36em; }
.sr-only, .hp { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 8px; background: var(--jaune); padding: 8px 12px; z-index: 30; border-radius: 8px; }

/* ---------- En-tête ---------- */
.site-header { background: rgba(255, 255, 255, .94); border-bottom: 1px solid var(--trait); position: sticky; top: 0; z-index: 20; backdrop-filter: saturate(1.2) blur(8px); }
.header-inner { display: flex; justify-content: space-between; align-items: center; gap: 8px 28px; min-height: 66px; flex-wrap: wrap; padding-top: 8px; padding-bottom: 8px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--encre); font: 900 1.3rem/1 var(--font); letter-spacing: -0.02em; text-decoration: none; }
.brand::before { content: ""; width: 28px; height: 28px; border-radius: 8px; flex: none; background: var(--jaune) url("/assets/favicon-mark.svg?v=0b626b91") center / 17px no-repeat; }
.brand:hover { text-decoration: none; }
.site-header nav { display: flex; gap: 4px; flex-wrap: wrap; align-items: center; }
.menu-btn { display: none; font: 800 1rem var(--font); background: var(--jaune-doux); border: 0; border-radius: 999px; padding: 8px 16px; color: var(--encre); cursor: pointer; }
.menu-btn::after { content: ""; display: inline-block; width: .4em; height: .4em; margin-left: .5em; border-right: 2.5px solid currentColor; border-bottom: 2.5px solid currentColor; transform: rotate(45deg) translateY(-3px); }
.menu-open .menu-btn::after { transform: rotate(-135deg) translateY(-1px); }
@media (max-width: 860px) {
  .header-inner { flex-wrap: nowrap; min-height: 58px; }
  .js .menu-btn { display: inline-block; }
  .js .site-header nav { display: none; }
  .js.menu-open .site-header nav { display: flex; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; align-items: stretch; background: #fff; border-bottom: 1px solid var(--trait); padding: 8px 16px 16px; box-shadow: var(--ombre-forte); }
  .js.menu-open .site-header nav a { padding: 12px 14px; border-radius: var(--r-sm); }
  .brand { font-size: 1.15rem; }
}
.site-header nav a { color: var(--encre); font-weight: 600; text-decoration: none; padding: 7px 14px; border-radius: 999px; }
.site-header nav a:hover { background: var(--fond); }
.site-header nav a[aria-current] { background: var(--jaune-doux); }

/* ---------- Boutons ---------- */
.btn {
  display: inline-block; cursor: pointer; border: 1.5px solid var(--encre); background: var(--jaune); color: var(--encre);
  font: 800 1rem/1.2 var(--font); padding: 13px 22px; border-radius: 999px; text-decoration: none;
  box-shadow: 0 2px 0 var(--encre); transition: transform .12s, box-shadow .12s;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 3px 0 var(--encre); text-decoration: none; }
.btn:active { transform: translateY(1px); box-shadow: 0 1px 0 var(--encre); }
.btn-quiet, .band .btn, .result .btn, .cta .btn, .newsletter .btn { background: #fff; }
.btn[disabled] { opacity: .5; cursor: not-allowed; transform: none; }

/* ---------- Bandeau jaune ---------- */
.band { background: var(--jaune); position: relative; overflow: hidden; }
.band::after { content: ""; position: absolute; right: -120px; bottom: -180px; width: 440px; height: 440px; border-radius: 50%; background: rgba(255, 255, 255, .22); pointer-events: none; }
.band .wrap { padding-top: 52px; padding-bottom: 56px; position: relative; z-index: 1; }
.band h1 { max-width: 14em; }
.hero-grid > div { min-width: 0; }
@media (max-width: 600px) { .band h1 { font-size: clamp(1.85rem, 8.4vw, 2.4rem); } .band .wrap { padding-top: 32px; padding-bottom: 40px; } }
.band-slim .wrap { padding-top: 36px; padding-bottom: 40px; }
.band-slim h1 { margin-bottom: .25em; font-size: clamp(2rem, 4.4vw, 3rem); }
.band-slim .lead { margin-bottom: 0; }
.band-icon { display: flex; gap: 24px; align-items: center; justify-content: space-between; }
.band-icon img { width: 104px; flex: none; }
.band-icon .page-spot { width: 240px; }
.band-tool .lead { font-size: 1.1rem; }
.steps { display: flex; flex-wrap: wrap; gap: 6px 20px; list-style: none; counter-reset: s; padding: 0; margin: 14px 0 0; font-weight: 700; font-size: .95rem; }
.steps li { counter-increment: s; display: flex; align-items: center; gap: 8px; }
.steps li::before { content: counter(s); width: 26px; height: 26px; border-radius: 50%; background: #fff; display: grid; place-items: center; font-weight: 900; font-size: .85rem; }
.send-mode { margin: 10px 0 0; font-size: .95rem; }
@media (max-width: 700px) {
  .band-tool .wrap { padding-top: 20px; padding-bottom: 24px; }
  .band-tool h1 { font-size: 1.75rem; }
  .band-tool .lead { font-size: 1rem; margin-bottom: 0; }
  .band-tool .steps, .band-tool .crumbs { display: none; }
  .band::after { display: none; }
}
@media (max-width: 700px) { .band-icon img { display: none; } }

.hero-grid { display: grid; gap: 24px; align-items: center; }
@media (min-width: 960px) { .hero-grid { grid-template-columns: 1.3fr .7fr; } }
.hero-art { width: 100%; max-width: 400px; justify-self: center; }
@media (max-width: 959px) { .hero-art { display: none; } }

.search { position: relative; max-width: 660px; margin-top: 28px; }
.search-box { display: flex; border: 1.5px solid var(--encre); background: #fff; border-radius: 999px; overflow: hidden; box-shadow: var(--ombre); }
.search-box input { flex: 1; min-width: 0; border: 0; font: inherit; font-size: 1.05rem; padding: 15px 22px; color: var(--encre); background: #fff; }
.search-box input:focus { outline: none; }
.search-box:focus-within { box-shadow: 0 0 0 4px rgba(29, 29, 27, .25); }
.search-box button { border: 1.5px solid var(--encre); background: var(--jaune); color: var(--encre); font: 800 1rem var(--font); padding: 0 22px; cursor: pointer; border-radius: 999px; margin: 5px; flex: none; }
@media (max-width: 520px) { .search-box input { padding: 13px 16px; font-size: 1rem; } .search-box button { padding: 0 14px; } }
.search-results { position: absolute; z-index: 5; left: 0; right: 0; top: calc(100% + 8px); list-style: none; margin: 0; padding: 6px; background: #fff; border: 1px solid var(--trait-fort); border-radius: var(--r); box-shadow: var(--ombre-forte); }
.search-results li a { display: block; padding: 10px 14px; text-decoration: none; border-radius: var(--r-sm); }
.search-results li a:hover, .search-results li a[aria-selected="true"] { background: var(--jaune-doux); }
.search-results small { display: block; color: var(--gris); font-size: .85rem; }
.search-results .none { padding: 10px 14px; color: var(--gris); }

.shortcuts { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 18px; font-weight: 600; font-size: .95rem; }
.shortcuts span { margin-right: 4px; }
.shortcuts a { background: rgba(255, 255, 255, .75); border-radius: 999px; padding: 6px 14px; text-decoration: none; }
.shortcuts a:hover { background: #fff; }

.stamp { position: absolute; right: 24px; top: 28px; width: 124px; height: 124px; border-radius: 50%; background: #fff; display: grid; place-items: center; text-align: center; font-weight: 800; font-size: .85rem; line-height: 1.2; transform: rotate(-8deg); padding: 14px; box-shadow: var(--ombre); z-index: 2; }
.stamp b { display: block; font-size: 1.35rem; font-weight: 900; }
@media (max-width: 959px) { .stamp { display: none; } }

/* ---------- Sections ---------- */
.section { padding-top: 24px; }
.section-alt { background: var(--jaune-pale); margin-top: 64px; padding: 8px 0 56px; }
.icon { width: 52px; height: 52px; flex: none; }

.tools { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; }
.tool-card { border: 1px solid var(--trait); border-radius: var(--r); padding: 24px; text-decoration: none; display: grid; gap: 10px; align-content: start; background: var(--papier); box-shadow: var(--ombre); transition: transform .15s, box-shadow .15s; }
.tool-card:hover { transform: translateY(-2px); box-shadow: var(--ombre-forte); text-decoration: none; }
.tool-card h3 { margin: 0; font-size: 1.3rem; }
.tool-card p { margin: 0; color: var(--gris); }
.demo { background: var(--jaune-doux); border-radius: var(--r-sm); padding: 12px 16px; font-weight: 600; font-variant-numeric: tabular-nums; }
.demo strong { font-weight: 900; font-size: 1.4rem; }
.go { font-weight: 800; color: var(--encre); }
.go::after { content: ""; display: inline-block; width: .45em; height: .45em; margin-left: .45em; border-top: 2.5px solid currentColor; border-right: 2.5px solid currentColor; transform: rotate(45deg) translateY(-2px); }
.tools-small { margin-top: 20px; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.tools-small .tool-card { padding: 18px 20px; grid-template-columns: 48px 1fr; gap: 2px 14px; }
.tools-small .tool-card .icon { width: 48px; height: 48px; grid-row: span 2; }
.tools-small .tool-card h3 { font-size: 1.1rem; align-self: end; }

.guides { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 18px; }
.guide { position: relative; display: grid; grid-template-columns: 44px 1fr; gap: 4px 14px; align-content: start; background: var(--papier); border: 1px solid var(--trait); border-radius: var(--r); padding: 20px; transition: box-shadow .15s, border-color .15s; }
.guide:hover { box-shadow: var(--ombre); border-color: var(--trait-fort); }
.guide .icon { width: 44px; height: 44px; grid-row: span 4; }
.guide a { font-weight: 800; font-size: 1.1rem; line-height: 1.3; text-decoration: none; }
.guide a::after { content: ""; position: absolute; inset: 0; border-radius: var(--r); }
.guide p { margin: 0; color: var(--gris); font-size: .96rem; }
.guide time { color: var(--gris); font-size: .82rem; }
.cat { justify-self: start; background: var(--jaune-doux); font-size: .76rem; font-weight: 800; padding: 3px 10px; border-radius: 999px; }
.cat-head { display: flex; align-items: center; gap: 14px; margin: 48px 0 16px; }
.cat-head h2 { margin: 0; }
.cat-head a { text-decoration: none; }
.more { margin-top: 28px; }

.promise .wrap { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 28px; }
.promise h3 { font-weight: 900; margin: 0 0 6px; }
.promise p { margin: 0; color: var(--gris); }

/* ---------- Article ---------- */
.article-head { background: var(--jaune); position: relative; overflow: hidden; }
.article-head .wrap { padding-top: 28px; padding-bottom: 36px; }
.article-head h1 { max-width: 20em; font-size: clamp(2rem, 4.4vw, 3.1rem); }
.article-head .lead { margin-bottom: 16px; }
.crumbs { font-size: .92rem; font-weight: 600; margin-bottom: 14px; }
.crumbs a { text-decoration-color: rgba(29, 29, 27, .35); }
.byline { display: flex; flex-wrap: wrap; gap: 4px 18px; font-size: .95rem; margin: 0; }
.byline strong { font-weight: 800; }
.article-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 28px; padding-top: 40px; }
.article-layout > * { min-width: 0; }
@media (min-width: 980px) {
  .article-layout { grid-template-columns: 17rem minmax(0, var(--measure)); gap: 56px; }
  .toc { position: sticky; top: 90px; align-self: start; }
}
.toc { background: var(--fond); border-radius: var(--r); padding: 18px 20px; font-size: .95rem; }
.toc p { font-weight: 900; margin: 0 0 8px; }
.toc ol { margin: 0; padding-left: 1.3em; }
.toc li { margin-bottom: 7px; }
.toc a { text-decoration: none; }
.toc a:hover { text-decoration: underline; text-decoration-color: var(--jaune); text-decoration-thickness: 3px; }
.prose { max-width: var(--measure); }
.prose > :first-child { margin-top: 0; }
.prose h2 { scroll-margin-top: 90px; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin-bottom: .4em; }
.prose li::marker { color: #a07c00; }
.prose blockquote { margin: 1.5em 0; padding: 16px 20px; background: var(--jaune-doux); border-radius: var(--r-sm); font-weight: 600; border-left: 5px solid var(--jaune); }
.prose blockquote p:last-child { margin: 0; }
.prose img { display: block; width: 100%; margin: 1.6em 0 .5em; border: 1px solid var(--trait); border-radius: var(--r); padding: 14px; background: #fff; }
.prose .caption { font-size: .88rem; color: var(--gris); margin-top: 0; }
.table-wrap { overflow-x: auto; margin: 1.4em 0; border: 1px solid var(--trait); border-radius: var(--r-sm); }
table { border-collapse: collapse; width: 100%; font-size: .95rem; }
th, td { padding: 11px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--trait); }
tr:last-child td { border-bottom: 0; }
th { font-weight: 800; background: var(--fond); }
.notice, .disclosure { background: var(--fond); border-radius: var(--r-sm); padding: 14px 18px; font-size: .92rem; color: var(--gris); }
.notice { margin-top: 36px; }
.cta { background: var(--jaune); border-radius: var(--r); padding: 20px 24px; margin: 32px 0; display: flex; gap: 16px 24px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.cta-main { display: flex; gap: 16px; align-items: center; }
.cta strong { font-weight: 900; font-size: 1.12rem; }
.cta p { margin: 2px 0 0; }
.related { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.related li { border: 1px solid var(--trait); border-radius: var(--r-sm); }
.related a { display: block; padding: 12px 16px; font-weight: 700; text-decoration: none; border-radius: var(--r-sm); }
.related a:hover { background: var(--jaune-pale); }
.history { font-size: .88rem; color: var(--gris); }

/* ---------- Pages simples, rubriques, glossaire ---------- */
.page { padding-top: 40px; }
.intro-text { max-width: var(--measure); font-size: 1.05rem; }
.glossary dt { font-weight: 800; font-size: 1.08rem; margin-top: 1.3em; scroll-margin-top: 90px; }
.glossary dd { margin: .3em 0 0; }

/* ---------- Newsletter ---------- */
.newsletter { background: var(--jaune); margin-top: 72px; padding: 44px 0; }
.newsletter h2 { margin-top: 0; }
.nl-form { display: grid; gap: 12px; max-width: 36rem; }
.nl-form input[type=email] { font: inherit; padding: 13px 18px; border: 1.5px solid var(--encre); border-radius: 999px; background: #fff; color: var(--encre); }
.nl-consent { display: flex; gap: 10px; align-items: flex-start; font-size: .92rem; }
.nl-consent input { margin-top: 6px; accent-color: var(--encre); }
.nl-form .btn { justify-self: start; }

/* ---------- Pied de page ---------- */
.site-footer { background: var(--fond); color: var(--gris); margin-top: 72px; padding: 44px 0 28px; font-size: .95rem; }
.newsletter + .site-footer { margin-top: 0; }
.footer-inner { display: flex; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.footer-inner > div:first-child { max-width: 30rem; }
.site-footer .brand { font-size: 1.1rem; margin-bottom: 12px; }
.footer-cols { display: flex; gap: 48px; flex-wrap: wrap; }
.footer-cols nav { display: grid; gap: 6px; align-content: start; }
.footer-cols strong { color: var(--encre); display: block; margin-bottom: 4px; }
.copy { margin-top: 28px; }

/* ---------- Outils ---------- */
.tool { display: grid; grid-template-columns: minmax(0, 1fr); gap: 28px; padding-top: 36px; }
@media (min-width: 900px) { .tool { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); align-items: start; } }
.form-card { border: 1px solid var(--trait); border-radius: var(--r); padding: 6px 24px 12px; background: #fff; box-shadow: var(--ombre); }
.form-card fieldset { border: 0; padding: 0; margin: 0 0 12px; }
.form-card legend { font-weight: 900; font-size: 1.15rem; padding: 18px 0 8px; }
.field { display: grid; gap: 5px; margin-bottom: 14px; }
.field > label, .field-label { font-weight: 700; font-size: .95rem; }
.field input:not([type=radio]):not([type=checkbox]), .field select, .field textarea {
  font: inherit; font-size: 1rem; padding: 11px 14px; width: 100%;
  border: 1.5px solid var(--trait-fort); border-radius: var(--r-sm); background: #fff; color: var(--encre);
  transition: border-color .12s, box-shadow .12s;
}
.field input:not([type=radio]):not([type=checkbox]):hover, .field select:hover, .field textarea:hover { border-color: #b9b19c; }
.field input:not([type=radio]):not([type=checkbox]):focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--encre); box-shadow: 0 0 0 4px var(--jaune-doux); }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 480px) { .row2 { grid-template-columns: 1fr; } }
.hint { font-size: .95rem; color: #4a4843; font-weight: 400; line-height: 1.45; }
.check-line { display: flex; gap: 10px; align-items: flex-start; font-size: .95rem; font-weight: 600; margin: 6px 0; }
.check-line input { margin-top: 6px; width: auto; flex: none; accent-color: var(--encre); }
.result { background: var(--jaune-doux); border: 1.5px solid #f1dc8a; border-radius: var(--r); padding: 24px 26px; box-shadow: var(--ombre); }
.result.is-example { background: #fff; border-style: dashed; border-color: var(--trait-fort); }
.result.is-example .big { color: #6b675c; }
.example-tag { display: block; margin: 0 0 12px; font-size: .85rem; font-weight: 700; background: var(--fond); border-radius: 10px; padding: 6px 12px; color: var(--gris); }
.result .actions { margin-top: 14px; }
.flash { animation: flash .6s ease-out; }
@keyframes flash { from { box-shadow: 0 0 0 6px rgba(255, 210, 63, .7); } to { box-shadow: var(--ombre); } }
.field-error { margin: 2px 0 0; color: #b3261e; font-weight: 700; font-size: .88rem; }
[aria-invalid="true"] { border-color: #b3261e !important; }
.result .muted { color: #4a4636; }
.result .big { font: 900 2.8rem/1.05 var(--font); margin: 0 0 8px; letter-spacing: -0.03em; }
.result .formula { font-variant-numeric: tabular-nums; background: #fff; padding: 10px 14px; border-radius: var(--r-sm); overflow-x: auto; font-weight: 600; }
.result .error { color: var(--encre); }
.alert { background: #fff; border-radius: var(--r-sm); border-left: 5px solid var(--encre); padding: 10px 14px; margin: 0 0 14px; font-size: .95rem; }
.error { color: #b3261e; font-weight: 700; }
.errors { list-style: none; padding: 12px 16px; margin: 0 0 16px; border-radius: var(--r-sm); background: #fdecea; }
.actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }
.after-tool { margin-top: 28px; }
.panel { border: 1px solid var(--trait); border-radius: var(--r); padding: 18px 22px; background: #fff; }
.panel ul { padding-left: 1.2em; }
.tool-doc { margin-top: 64px; }

/* Encarts d'inscription et d'envoi */
.optin { border: 1px solid var(--trait); border-radius: var(--r); padding: 22px 24px; margin: 24px 0; background: var(--jaune-pale); position: relative; }
.optin::before { content: ""; position: absolute; left: 24px; top: -1px; width: 56px; height: 5px; background: var(--jaune); border-radius: 0 0 4px 4px; }
.optin h2 { margin: 0 0 6px; }
.optin p { color: var(--gris); }
.optin-form { display: grid; gap: 12px; }
.optin-row { display: flex; gap: 10px; flex-wrap: wrap; }
.optin-row input { flex: 1 1 220px; font: inherit; padding: 12px 18px; border: 1.5px solid var(--trait-fort); border-radius: 999px; background: #fff; color: var(--encre); }
.optin-row input:focus { outline: none; border-color: var(--encre); box-shadow: 0 0 0 4px var(--jaune-doux); }
.preview-note { margin: 0; font-size: .85rem; background: #fff; border-left: 4px solid var(--jaune); padding: 8px 12px; border-radius: 6px; color: var(--gris); }
.newsletter .preview-note { background: rgba(255, 255, 255, .7); }
.send-status:empty { display: none; }
.send-status { margin: 0; font-weight: 700; padding: 10px 14px; border-radius: var(--r-sm); }
.send-status.ok { background: #e8f4ea; }
.send-status.ko { color: #b3261e; background: #fdecea; }

/* ---------- Document quittance (aperçu et impression) ---------- */
.doc { background: #fff; color: #111; border: 1px solid var(--trait); border-radius: 6px; padding: 40px 44px; font: 15px/1.55 var(--doc); box-shadow: var(--ombre); }
.doc h2 { font: 600 1.4rem/1.2 var(--doc); text-align: center; margin: 0 0 4px; letter-spacing: 0; color: #111; }
.doc .doc-period { text-align: center; margin-bottom: 26px; color: #444; }
.doc .parties { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 20px; }
.doc .table-wrap { border: 0; border-radius: 0; }
.doc table { font-size: 15px; }
.doc th, .doc td { color: #111; border-bottom: 1px solid #cfcfcf; font-family: var(--doc); padding: 8px 0; background: none; }
.doc th { border-bottom: 1px solid #111; font-weight: 600; }
.doc .num { text-align: right; white-space: nowrap; }
.doc .sign { margin-top: 28px; display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.doc .legal { margin-top: 24px; font-size: 12px; color: #555; border-top: 1px solid #cfcfcf; padding-top: 10px; }
@media (max-width: 600px) { .doc { padding: 22px 16px; } .doc .parties { grid-template-columns: 1fr; } }

@media print {
  body { background: #fff; color: #111; }
  .site-header, .site-footer, .newsletter, .no-print, .skip, .tool-doc { display: none !important; }
  .wrap { max-width: none; padding: 0; }
  .tool { display: block; padding: 0; }
  .doc { border: 0; padding: 0; box-shadow: none; }
  @page { margin: 18mm; }
}

/* =====================================================================
   Refonte d'octobre 2026 : en-têtes blancs pour les guides, listes
   éditoriales, agenda, illustrations, aperçus d'exemple, lettres types.
   ===================================================================== */

/* ---------- En-tête blanc (guides, rubriques, pages) ---------- */
.page-head { border-bottom: 1px solid var(--trait); background: linear-gradient(var(--papier), var(--jaune-pale)); }
.page-head .wrap { padding-top: 28px; padding-bottom: 32px; }
.page-head-grid { display: grid; gap: 24px; align-items: center; }
@media (min-width: 900px) { .page-head-grid { grid-template-columns: minmax(0, 1fr) 280px; } }
.page-head h1 { font-size: clamp(1.9rem, 4.2vw, 3rem); max-width: 22em; position: relative; padding-bottom: .35em; }
.page-head h1::after { content: ""; position: absolute; left: 0; bottom: 0; width: 72px; height: 6px; border-radius: 3px; background: var(--jaune); }
.page-head .lead { max-width: 40em; }
.page-spot { width: 100%; max-width: 280px; justify-self: end; }
@media (max-width: 899px) { .page-head .page-spot { display: none; } }

/* Auteur */
.avatar { width: 48px; height: 48px; border-radius: 50%; flex: none; object-fit: cover; display: inline-grid; place-items: center;
  background: var(--jaune) url("/assets/favicon-mark.svg?v=0b626b91") center / 22px no-repeat; font: 900 1.05rem var(--font); color: var(--encre); border: 2px solid #fff; box-shadow: 0 0 0 1.5px var(--encre); }
span.avatar:not(:empty) { background-image: none; }
.byline { display: flex; align-items: center; gap: 14px; margin-top: 6px; }
.byline p { margin: 0; display: flex; flex-direction: column; font-size: .95rem; line-height: 1.45; }
.byline a { font-weight: 800; }
.byline span + span { color: var(--gris); }

/* Barre de lecture */
.progress { position: fixed; left: 0; right: 0; top: 0; height: 4px; background: var(--jaune); transform-origin: 0 50%; transform: scaleX(0); z-index: 40; pointer-events: none; }

/* Sommaire */
.toc details > summary { font-weight: 900; cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; }
.toc details > summary::-webkit-details-marker { display: none; }
.toc details > summary::after { content: ""; width: .5em; height: .5em; border-right: 2.5px solid currentColor; border-bottom: 2.5px solid currentColor; transform: rotate(45deg); margin-right: 4px; }
.toc details[open] > summary::after { transform: rotate(-135deg); }
.toc details[open] > summary { margin-bottom: 10px; }
.toc a[aria-current] { font-weight: 800; text-decoration: underline; text-decoration-color: var(--jaune); text-decoration-thickness: 3px; }
@media (min-width: 980px) { .toc details > summary { pointer-events: none; } .toc details > summary::after { display: none; } }

/* Encadrés typés */
.prose blockquote.callout { font-weight: 400; border-left-width: 5px; }
.callout-label { font-weight: 900; font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; margin: 0 0 4px !important; display: flex; align-items: center; gap: 8px; }
.callout-label::before { content: ""; width: 20px; height: 20px; flex: none; border-radius: 50%; background: var(--encre) no-repeat center / 12px; }
.callout-retenir { background: var(--jaune-doux); border-left-color: var(--jaune); }
.callout-retenir .callout-label::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2.5 6.2l2.3 2.3 4.7-5' fill='none' stroke='%23ffd23f' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }
.callout-attention { background: #fff1ec; border-left-color: #e2572c; }
.callout-attention .callout-label::before { background-color: #c2410c; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M6 2.5v4.2' stroke='%23fff' stroke-width='2' stroke-linecap='round'/%3E%3Ccircle cx='6' cy='9.2' r='1.1' fill='%23fff'/%3E%3C/svg%3E"); }
.callout-exemple { background: var(--fond); border-left-color: var(--trait-fort); }
.callout-exemple .callout-label::before { background-color: var(--encre); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Ctext x='6' y='9.3' font-family='Arial' font-weight='700' font-size='9' fill='%23fff' text-anchor='middle'%3E%E2%82%AC%3C/text%3E%3C/svg%3E"); }

/* FAQ dépliables */
details.faq { border: 1px solid var(--trait); border-radius: var(--r-sm); margin: 10px 0; background: #fff; }
details.faq > summary { cursor: pointer; padding: 14px 44px 14px 18px; font-weight: 800; position: relative; list-style: none; }
details.faq > summary::-webkit-details-marker { display: none; }
details.faq > summary::after { content: "+"; position: absolute; right: 18px; top: 50%; transform: translateY(-50%); font-size: 1.4rem; font-weight: 400; }
details.faq[open] > summary::after { content: "−"; }
details.faq > :not(summary) { padding: 0 18px; }
details.faq > :last-child { padding-bottom: 14px; margin-bottom: 0; }

/* Tableaux : chiffres alignés */
td.num, th.num { text-align: right; white-space: nowrap; }

/* Schémas : lisibles sur mobile (défilement horizontal plutôt que réduction) */
@media (max-width: 640px) {
  .prose p:has(> img[src*="schema-"]) { overflow-x: auto; margin: 1.4em -20px .4em; padding: 0 20px; }
  .prose img[src*="schema-"] { min-width: 600px; }
}

/* ---------- Accueil ---------- */
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.section-head h2 { margin-bottom: .4em; }
.tool-list { list-style: none; padding: 0; margin: 24px 0 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 4px 28px; }
.tool-list li { display: grid; grid-template-columns: 40px 1fr; gap: 0 14px; padding: 12px 0; border-bottom: 1px solid var(--trait); position: relative; }
.tool-list img { grid-row: span 2; width: 40px; height: 40px; }
.tool-list a { font-weight: 800; text-decoration: none; }
.tool-list a::after { content: ""; position: absolute; inset: 0; }
.tool-list li:hover a { text-decoration: underline; text-decoration-color: var(--jaune); text-decoration-thickness: 3px; }
.tool-list span { color: var(--gris); font-size: .95rem; }

.agenda { list-style: none; padding: 0; margin: 8px 0 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 0; border-top: 2px solid var(--encre); }
.agenda li { padding: 18px 22px 8px 0; position: relative; }
.agenda li::before { content: ""; position: absolute; top: -8px; left: 0; width: 14px; height: 14px; border-radius: 50%; background: var(--jaune); border: 2px solid var(--encre); }
.agenda time { display: block; font-weight: 900; font-size: 1.1rem; margin-top: 4px; }
.agenda strong { display: block; font-size: 1.05rem; line-height: 1.3; margin: 4px 0; }
.agenda p { color: var(--gris); font-size: .95rem; margin-bottom: 6px; }
.agenda a { font-weight: 700; font-size: .95rem; }

.rubriques { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
@media (min-width: 860px) { .rubriques { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; } }
@media (max-width: 420px) { .rubrique { padding: 8px 12px 14px; } .rubrique strong { font-size: 1.05rem; } .rubrique span { font-size: .88rem; } }
.rubrique { display: grid; gap: 4px; padding: 12px 18px 20px; background: #fff; border-radius: var(--r); border: 1px solid var(--trait); text-decoration: none; transition: transform .15s, box-shadow .15s; }
.rubrique:hover { transform: translateY(-2px); box-shadow: var(--ombre); }
.rubrique img { width: 100%; max-width: 200px; justify-self: center; }
.rubrique strong { font-size: 1.2rem; font-weight: 900; }
.rubrique span { color: var(--gris); font-size: .95rem; }

.essentials { list-style: none; counter-reset: e; padding: 0; margin: 0; columns: 2 320px; column-gap: 40px; }
.essentials li { counter-increment: e; break-inside: avoid; display: grid; grid-template-columns: 44px 1fr; padding: 12px 0; border-bottom: 1px solid var(--trait); }
.essentials li::before { content: counter(e, decimal-leading-zero); font: 900 1.3rem/1.2 var(--font); color: #b38f00; grid-row: span 2; }
.essentials a { font-weight: 800; text-decoration: none; line-height: 1.3; }
.essentials a:hover { text-decoration: underline; text-decoration-color: var(--jaune); text-decoration-thickness: 3px; }

.letters-band { display: grid; gap: 12px 40px; align-items: center; background: var(--jaune-pale); border: 1px solid var(--trait); border-radius: var(--r); padding: 24px 28px; }
@media (min-width: 820px) { .letters-band { grid-template-columns: 260px 1fr; } }
.letters-band img { width: 100%; max-width: 260px; justify-self: center; }
.letters-band h2 { margin-top: 0; }
.letters-band ul { padding-left: 1.2em; margin: 0; columns: 2 260px; }
.letters-band li { margin-bottom: 6px; }

.signed { display: grid; grid-template-columns: 64px 1fr; gap: 20px; max-width: 46rem; padding: 28px 0; border-top: 1px solid var(--trait); }
.signed .avatar { width: 64px; height: 64px; font-size: 1.3rem; background-size: 28px; }
.signed h2 { margin: 0 0 8px; }
.signed .signature { font-weight: 800; margin-top: 8px; }
.signed .signature::before { content: "— "; }

/* ---------- Listes de guides ---------- */
.guide-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 0 36px; }
.guide-list li { padding: 16px 0; border-bottom: 1px solid var(--trait); position: relative; }
.guide-list a { font-weight: 800; font-size: 1.1rem; line-height: 1.3; text-decoration: none; }
.guide-list a::after { content: ""; position: absolute; inset: 0; }
.guide-list li:hover a { text-decoration: underline; text-decoration-color: var(--jaune); text-decoration-thickness: 3px; }
.guide-list p { margin: 4px 0 0; color: var(--gris); font-size: .95rem; }
.guide-list time { display: block; color: var(--gris); font-size: .82rem; margin-top: 4px; }
.jump { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.jump a { background: var(--jaune-doux); border-radius: 999px; padding: 6px 14px; font-weight: 700; text-decoration: none; font-size: .95rem; }
.jump a:hover { background: var(--jaune); }
.cat-block { scroll-margin-top: 80px; }
.cat-head img { width: 120px; flex: none; }
.cat-head p { margin: 2px 0 0; }
@media (max-width: 520px) { .cat-head img { width: 84px; } }

/* ---------- Ce qui change ---------- */
.veille h2 { border-bottom: 2px solid var(--encre); padding-bottom: 6px; }
.veille h3 { margin-top: 1.8em; font-size: 1.15rem; }
.status { display: inline-block; font-size: .8rem !important; font-weight: 800; border-radius: 999px; padding: 3px 12px; margin: 0 0 8px !important; }
.status-en-vigueur { background: #e3f1e5; color: #1e5b2a; }
.status-a-venir { background: var(--jaune-doux); color: #6a5300; }
.status-en-discussion { background: #eef0f7; color: #384266; }

/* ---------- Outils : aperçu, exemple, mobile ---------- */
.tools-grid { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.letter-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; }
.letter-grid .tool-card h2 { margin: 0; }
@media (min-width: 900px) {
  .tool-sticky .preview-col { position: sticky; top: 84px; }
}
.example-note { background: var(--fond); border-radius: var(--r-sm); padding: 10px 14px; font-size: .92rem; margin: 0 0 12px; }
.doc { position: relative; overflow: hidden; }
.doc.is-example::before { content: "EXEMPLE"; position: absolute; left: 50%; top: 42%; transform: translate(-50%, -50%) rotate(-24deg); font: 900 5.5rem/1 var(--font); color: rgba(29, 29, 27, .06); letter-spacing: .1em; pointer-events: none; white-space: nowrap; }
mark.ex { background: var(--jaune-doux); color: inherit; border-radius: 3px; padding: 0 2px; -webkit-box-decoration-break: clone; box-decoration-break: clone; }
.after-grid { display: grid; gap: 20px; margin-top: 32px; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); align-items: start; }
.after-grid .optin { margin: 0; }
.mobile-bar { display: none; }
@media (max-width: 899px) {
  .mobile-bar { display: flex; gap: 10px; position: sticky; bottom: 0; z-index: 15; background: rgba(255, 255, 255, .96); backdrop-filter: blur(6px); border-top: 1px solid var(--trait); padding: 10px 20px; margin: 20px -20px 0; }
  .mobile-bar .btn { flex: 1; text-align: center; padding: 12px 10px; }
  .form-card { border: 0; box-shadow: none; padding: 0; }
  .preview-col { scroll-margin-top: 70px; }
}

/* ---------- Lettre ---------- */
.doc.letter { font-size: 15px; line-height: 1.6; }
.letter-from { margin-bottom: 26px; }
.letter-to { margin: 0 0 26px 52%; }
.letter-date { text-align: right; margin-bottom: 18px; }
.letter-mode { font-weight: 600; margin-bottom: 6px; }
.letter-object { margin-bottom: 20px; }
.letter-sign { margin-top: 28px; margin-left: 52%; }
@media (max-width: 600px) { .letter-to, .letter-sign { margin-left: 0; } }

@media print {
  .doc.letter { font-size: 12pt; }
  .doc.is-example::before { display: none; }
  .mobile-bar, .after-grid, .progress, .example-note { display: none !important; }
  mark.ex { background: none; box-shadow: none; }
}

.panel li { margin-bottom: 8px; }
.table-wrap:focus-visible, .schema-scroll:focus-visible { outline-offset: 2px; }

@media (max-width: 700px) {
  .agenda { border-top: 0; border-left: 2px solid var(--encre); margin-left: 7px; }
  .agenda li { padding: 4px 0 18px 22px; }
  .agenda li::before { top: 8px; left: -9px; }
}
.result .note { background: #fff; border-radius: var(--r-sm); padding: 10px 14px; font-size: .95rem; }
.tool-hint { background: rgba(255, 255, 255, .7); border-radius: var(--r-sm); padding: 10px 14px; font-size: .95rem; margin: 14px 0 0; max-width: 40em; }

/* ---------- Recherche dans l'en-tête ---------- */
.search-toggle { display: inline-flex; align-items: center; gap: 6px; font: 700 1rem var(--font); background: none; border: 0; color: var(--encre); padding: 7px 12px; border-radius: 999px; cursor: pointer; margin-left: auto; }
.search-toggle:hover, .search-toggle[aria-expanded="true"] { background: var(--jaune-doux); }
.header-inner { gap: 8px 16px; }
.header-search { border-top: 1px solid var(--trait); background: #fff; padding: 12px 0 16px; }
.header-search .search { margin-top: 0; max-width: 720px; }
@media (max-width: 860px) { .search-toggle-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); } .search-toggle { padding: 8px 10px; } }
.search-results .none { font-size: .92rem; }

/* ---------- Corrections de l'audit n° 2 ---------- */
.check-line input, .nl-consent input, .field input[type=radio], .field input[type=checkbox] { width: 22px !important; height: 22px; margin-top: 2px; }
.check-line { align-items: center; }
.actions-top { margin: 0 0 14px; align-items: center; }
.actions-top .small { flex: 1 1 200px; }
.rubrique { min-width: 0; }
.rubrique strong, .rubrique span { overflow-wrap: anywhere; hyphens: auto; }

/* Tableaux en fiches sur téléphone */
@media (max-width: 600px) {
  .table-wrap:has(table.stack) { border: 0; overflow: visible; }
  table.stack thead, table.stack tr:first-child th { display: none; }
  table.stack, table.stack tbody, table.stack tr, table.stack td { display: block; width: 100%; }
  table.stack tr { border: 1px solid var(--trait); border-radius: var(--r-sm); margin-bottom: 10px; padding: 6px 12px; background: #fff; }
  table.stack td { border: 0; padding: 6px 0; text-align: left !important; white-space: normal; }
  table.stack td::before { content: attr(data-label); display: block; font-weight: 800; font-size: .8rem; color: var(--gris); text-transform: uppercase; letter-spacing: .03em; }
}

/* Pastille « voir le résultat » sur téléphone */
.result-pill { position: fixed; left: 50%; bottom: 14px; transform: translateX(-50%); z-index: 30; background: var(--encre); color: #fff; border: 0; border-radius: 999px; padding: 12px 20px; font: 800 1rem var(--font); box-shadow: var(--ombre-forte); cursor: pointer; max-width: calc(100% - 32px); }
.result-pill[hidden] { display: none; }

/* Action rapide en tête de guide */
.quick-actions { display: flex; flex-wrap: wrap; gap: 8px 10px; align-items: center; background: var(--jaune-pale); border: 1px solid var(--trait); border-radius: var(--r-sm); padding: 12px 16px; margin: 0 0 24px; font-size: .95rem; }
.quick-actions strong { margin-right: 4px; }
.quick-actions a { background: #fff; border: 1.5px solid var(--encre); border-radius: 999px; padding: 6px 14px; font-weight: 700; text-decoration: none; }
.quick-actions a:hover { background: var(--jaune); }

/* Filtres de « Ce qui change » */
.veille-filters { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 8px; }
.veille-filters button { font: 700 .95rem var(--font); border: 1.5px solid var(--trait-fort); background: #fff; color: var(--encre); border-radius: 999px; padding: 7px 14px; cursor: pointer; }
.veille-filters button[aria-pressed="true"] { background: var(--jaune); border-color: var(--encre); }

.toc-desktop { display: none; }
@media (min-width: 980px) { .toc-mobile { display: none; } .toc-desktop { display: block; } }
.nl-consent input, .check-line input { flex: none; }

/* ---------- Mise en page des outils (octobre 2026, v3) ---------- */
/* Champs côte à côte : libellés, champs et aides alignés sur les mêmes lignes. */
.row2 { grid-template-rows: auto auto auto; row-gap: 0; align-items: start; }
.row2 > .field { display: grid; grid-row: span 3; grid-template-rows: subgrid; row-gap: 5px; margin-bottom: 14px; }
.row2 > .field > label, .row2 > .field > .field-label { align-self: end; }
@media (max-width: 480px) { .row2 > .field { grid-row: auto; grid-template-rows: none; } }
/* Le résultat suit la saisie sur ordinateur. */
@media (min-width: 900px) { .tool-sticky .preview-col { position: sticky; top: 84px; align-self: start; } }
.after-grid { margin-top: 36px; }
.after-grid .panel, .after-grid .optin { height: 100%; }
/* Documentation de l'outil : bandeau pleine largeur, texte centré. */
.tool-doc { margin-top: 64px; background: var(--jaune-pale); border-top: 1px solid var(--trait); padding: 48px 0 56px; }
.tool-doc .prose { margin: 0 auto; }
.tool-doc .prose > h2:first-child { margin-top: 0; }
.after-grid { align-items: stretch; }
main:has(> .tool-doc:last-child) + .site-footer { margin-top: 0; }
@media (min-width: 900px) { .after-grid { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 28px; } }
.panel-stack { display: grid; gap: 20px; align-content: start; }
.after-grid .panel-stack .panel { height: auto; }

/* ---------- Outils : une seule carte, moins de cadres (v4) ---------- */
.tool { background: #fff; border: 1px solid var(--trait); border-radius: var(--r); box-shadow: var(--ombre); gap: 0; margin-top: 36px; padding: 0; }
.tool > .form-card { border: 0; box-shadow: none; border-radius: 0; background: none; padding: 8px 28px 20px; }
.preview-col { background: var(--jaune-pale); border-top: 1px solid var(--trait); border-radius: 0 0 var(--r) var(--r); padding: 24px 28px 28px; }
@media (min-width: 900px) {
  .tool { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); align-items: stretch; }
  .tool > .form-card { padding: 8px 32px 24px; }
  .preview-col { border-top: 0; border-left: 1px solid var(--trait); border-radius: 0 var(--r) var(--r) 0; padding: 28px 32px; }
  .tool-sticky .preview-col { position: static; align-self: stretch; }
  .tool-sticky .preview-inner { position: sticky; top: 84px; }
}
@media (max-width: 899px) { .tool { margin-left: -4px; margin-right: -4px; } .tool > .form-card { padding: 4px 18px 16px; } .preview-col { padding: 20px 18px 22px; } }

/* Le résultat n'est plus une boîte : il occupe la zone jaune pâle de la carte. */
.preview-col .result, .preview-col .result.is-example { background: none; border: 0; box-shadow: none; padding: 0; border-radius: 0; }
.preview-col .result.is-example .big { color: #6b675c; }
.preview-col .result .formula { background: none; padding: 2px 0 2px 12px; border-left: 3px solid var(--jaune); border-radius: 0; }
.preview-col .example-tag { background: #fff; }
.preview-col .example-note { background: #fff; }
.preview-col .doc { box-shadow: 0 1px 3px rgba(29, 29, 27, .08); }

/* Sous la carte : sections simples, séparées par un filet, sans cadre. */
.after-grid { border-top: 0; margin-top: 44px; gap: 28px 56px; }
.after-grid .optin, .after-grid .panel { background: none; border: 0; border-top: 1px solid var(--trait-fort); border-radius: 0; padding: 20px 0 0; box-shadow: none; margin: 0; height: auto; }
.after-grid .optin::before { display: none; }
.after-grid .panel-stack { gap: 28px; }
@media (min-width: 900px) { .after-grid { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); } }

/* Questions fréquentes : des lignes, pas des boîtes. */
details.faq { border: 0; border-bottom: 1px solid var(--trait-fort); border-radius: 0; background: none; margin: 0; }
details.faq:first-of-type { border-top: 1px solid var(--trait-fort); }
details.faq > summary { padding: 16px 40px 16px 0; }
details.faq > summary::after { right: 4px; }
details.faq > :not(summary) { padding: 0; }

/* ---------- Pied de page (v2) ---------- */
.site-footer { background: var(--fond); color: var(--encre); margin-top: 72px; padding: 0; font-size: 1rem; border-top: 6px solid var(--jaune); }
.site-footer .wrap { padding-top: 48px; padding-bottom: 28px; }
.footer-top { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px 48px; flex-wrap: wrap; padding-bottom: 32px; border-bottom: 1px solid var(--trait-fort); }
.footer-brand { max-width: 34rem; }
.site-footer .footer-brand .brand { font-size: 1.45rem; margin-bottom: 12px; }
.site-footer .footer-brand .brand::before { width: 34px; height: 34px; background-size: 20px; }
.footer-brand p { margin: 0; color: var(--gris); }
.footer-actions { display: flex; align-items: center; gap: 12px 24px; flex-wrap: wrap; }
.footer-link-strong { font-weight: 700; }
.footer-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px 40px; padding: 36px 0; }
.footer-grid h2 { font-size: .8rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: var(--gris); margin: 0 0 14px; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.footer-grid a { text-decoration: none; font-weight: 600; font-size: .98rem; }
.footer-grid a:hover { text-decoration: underline; text-decoration-color: var(--jaune); text-decoration-thickness: 3px; }
.footer-trust { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px 40px; background: #fff; border-radius: var(--r-sm); padding: 16px 20px; font-size: .92rem; color: var(--gris); }
.footer-trust p { margin: 0; }
.footer-trust strong { color: var(--encre); }
.footer-bottom { display: flex; align-items: center; gap: 12px 28px; flex-wrap: wrap; padding-top: 24px; font-size: .92rem; color: var(--gris); }
.footer-bottom p { margin: 0; }
.footer-bottom ul { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 22px; margin: 0; padding: 0; }
.footer-bottom a { color: var(--gris); }
.to-top { margin-left: auto; font-weight: 700; color: var(--encre) !important; text-decoration: none; }
@media (max-width: 900px) { .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .footer-trust { grid-template-columns: 1fr; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: 1fr 1fr; gap: 28px 20px; } .footer-actions .btn { width: 100%; text-align: center; } .to-top { margin-left: 0; } }
@media (max-width: 600px) {
  .site-footer .wrap { padding-top: 36px; }
  .footer-top { padding-bottom: 24px; }
  .footer-grid { padding: 28px 0; }
  .footer-grid ul { gap: 2px; }
  .footer-grid a { display: block; padding: 5px 0; font-size: .95rem; line-height: 1.35; }
}

/* ---------- Logo « l'étiquette » : porte-étiquette du trousseau ---------- */
.brand { gap: 9px; font-weight: 800; letter-spacing: -.025em; }
.brand::before { width: 46px; height: 30px; border-radius: 0; background: url("/assets/logo-mark.svg?v=0b626b91") center / contain no-repeat; }
.wm { text-transform: lowercase; }

/* ---------- Pied de page (v3, sur fond jaune) ---------- */
.newsletter { background: var(--jaune-doux); }
.site-footer { background: var(--jaune); color: var(--encre); border-top: 0; margin-top: 72px; padding: 0; position: relative; overflow: hidden; }
.site-footer::before { content: ""; position: absolute; right: -70px; top: 40px; width: 460px; height: 300px; background: url("/assets/logo-mark-blanc.svg?v=0b626b91") center / contain no-repeat; opacity: .45; transform: rotate(-14deg); pointer-events: none; }
.footer-hero { position: relative; }
.footer-hero-inner { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px 48px; flex-wrap: wrap; padding-top: 56px !important; padding-bottom: 36px !important; }
/* Cartouche du pied de page : le nom écrit sur l'étiquette, l'anneau passe dans l'œillet. */
.brand-tag { position: relative; display: inline-block; padding: 5.4px 0 0 25.1px; margin-bottom: 26px; color: var(--encre); text-decoration: none; }
.brand-tag:hover { text-decoration: none; }
.bt-body { position: relative; z-index: 1; display: flex; align-items: center; box-sizing: border-box; height: 71.5px; padding: 0 23px 0 35.25px;
  background: #fff; border: 5.5px solid var(--encre); border-radius: 35.75px 12.75px 12.75px 35.75px; font: 800 32px/1 var(--font); letter-spacing: -.025em; }
.bt-ring { position: absolute; left: 2.25px; top: 2.25px; width: 49.5px; height: 49.5px; box-sizing: border-box; border: 5.5px solid var(--encre); border-radius: 50%; }
.bt-front { position: absolute; z-index: 2; left: 0; top: 0; overflow: visible; }
.brand-tag:focus-visible { outline: 3px solid var(--encre); outline-offset: 6px; border-radius: 12px; }
@media (max-width: 420px) { .brand-tag { zoom: .82; } }
.footer-claim { font: 900 clamp(2.2rem, 5vw, 3.6rem)/1 var(--font); letter-spacing: -.03em; margin: 0 0 12px; }
.footer-sub { margin: 0; max-width: 34rem; font-size: 1.05rem; }
.footer-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.btn-ghost { background: transparent !important; box-shadow: none; }
.btn-ghost:hover { background: rgba(255, 255, 255, .5) !important; box-shadow: none; }
.site-footer .wrap { position: relative; padding-top: 0; padding-bottom: 28px; }
.footer-grid { padding: 40px 0 36px; border-top: 1px solid rgba(29, 29, 27, .18); }
.footer-grid h2 { color: var(--encre); opacity: .7; }
.footer-grid a { color: var(--encre); }
.footer-grid a:hover { text-decoration-color: var(--encre); }
.footer-trust { background: rgba(255, 255, 255, .7); color: #3a382f; }
.footer-bottom { color: #3a382f; border-top: 1px solid rgba(29, 29, 27, .18); margin-top: 24px; }
.footer-bottom a { color: var(--encre); text-decoration-color: rgba(29, 29, 27, .4); }
.newsletter + .site-footer, main:has(> .tool-doc:last-child) + .site-footer { margin-top: 0; }
@media (max-width: 600px) { .site-footer::before { display: none; } .footer-actions .btn { flex: 1 1 100%; text-align: center; } }

/* ---------- Simulateur de crédit ---------- */
.seg { border: 0; padding: 0; margin: 0 0 6px; }
.seg legend { font-weight: 800; margin-bottom: 10px; }
.seg-options { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; background: var(--jaune-pale); border: 1px solid var(--trait); border-radius: 999px; }
.seg-options label { position: relative; display: block; cursor: pointer; }
.seg-options input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.seg-options span { display: block; text-align: center; padding: 10px 12px; border-radius: 999px; font-weight: 700; line-height: 1.2; }
.seg-options input:checked + span { background: #fff; box-shadow: 0 0 0 1.5px var(--encre); }
.seg-options input:focus-visible + span { outline: 3px solid var(--encre); outline-offset: 2px; }
legend .opt { font-weight: 400; color: var(--gris); }
.kv { display: grid; grid-template-columns: 1fr auto; gap: 8px 16px; margin: 18px 0; padding: 14px 0; border-top: 1px solid var(--trait); border-bottom: 1px solid var(--trait); }
.kv dt { color: var(--gris); }
.kv dd { margin: 0; text-align: right; font-variant-numeric: tabular-nums; }
.ratio { margin: 18px 0; }
.ratio-head { display: flex; justify-content: space-between; align-items: baseline; margin: 0 0 8px; }
.ratio-head strong { font-size: 1.35rem; font-variant-numeric: tabular-nums; }
.ratio-bar { position: relative; height: 10px; border-radius: 999px; background: #fff; border: 1px solid var(--trait-fort); overflow: hidden; margin-bottom: 10px; }
.ratio-bar span { display: block; height: 100%; width: 0; background: var(--jaune); transition: width .25s; }
.ratio-bar i { position: absolute; top: -1px; bottom: -1px; left: 70%; width: 2px; background: var(--encre); }
.ratio.is-over .ratio-bar span { background: #f2a33a; }
@media (prefers-reduced-motion: reduce) { .ratio-bar span { transition: none; } }
.amort { margin-top: 18px; border: 1px solid var(--trait); border-radius: var(--r); background: #fff; }
.amort > summary { cursor: pointer; padding: 16px 22px; font-weight: 800; list-style-position: inside; }
.amort > summary:hover { background: var(--jaune-pale); border-radius: var(--r); }
.amort[open] > summary { border-bottom: 1px solid var(--trait); border-radius: var(--r) var(--r) 0 0; }
#k-amort { padding: 6px 22px 16px; }
.amort-table { width: 100%; border-collapse: collapse; font-size: .92rem; font-variant-numeric: tabular-nums; }
.amort-table th, .amort-table td { padding: 8px 10px; text-align: right; border-bottom: 1px solid var(--trait); white-space: nowrap; }
.amort-table th:first-child { text-align: left; }
.amort-table thead th { font-size: .8rem; text-transform: uppercase; letter-spacing: .04em; color: var(--gris); }

/* ---------- Document remis par e-mail : aperçu tronqué ---------- */
.doc.gated { max-height: 270px; overflow: hidden; -webkit-user-select: none; user-select: none;
  -webkit-mask-image: linear-gradient(to bottom, #000 62%, transparent 100%);
          mask-image: linear-gradient(to bottom, #000 62%, transparent 100%); }
.doc.letter.gated { max-height: 300px; }
.gate-card { position: relative; margin: -28px 0 0; background: #fff; box-shadow: var(--ombre-forte); scroll-margin-top: 96px; }
.gate-card h2 { margin: 0 0 4px; }
.gate-head { display: flex; gap: 16px; align-items: flex-start; }
.gate-head img { flex: none; }
.gate-head p { margin: 0; }
.gate-list { list-style: none; padding: 0; margin: 16px 0 18px; display: grid; gap: 8px; font-size: .95rem; }
.gate-list li { position: relative; padding-left: 28px; }
.gate-list li::before { content: ""; position: absolute; left: 0; top: .2em; width: 18px; height: 18px; border-radius: 50%; background: var(--jaune) url("/assets/img/coche.svg?v=0b626b91") center / 12px no-repeat; }
@media print { .doc.gated, .gate-card { display: none !important; } }

/* Formulaire d'envoi : e-mail, cases facultatives bien visibles, puis bouton. */
.send-form .send-email { margin: 0; }
.send-form .send-email label { font-weight: 700; display: block; margin-bottom: 6px; }
.send-form .send-email input { width: 100%; font: inherit; padding: 12px 18px; border: 1.5px solid var(--trait-fort); border-radius: 999px; background: #fff; color: var(--encre); }
.send-form .send-email input:focus { outline: none; border-color: var(--encre); box-shadow: 0 0 0 4px var(--jaune-doux); }
.consent-opt { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border: 1.5px solid var(--trait); border-radius: var(--r-sm); background: var(--jaune-pale); cursor: pointer; font-size: .9rem; line-height: 1.45; color: var(--gris); }
.consent-opt:hover { border-color: var(--trait-fort); }
.consent-opt:has(input:checked) { border-color: var(--encre); background: var(--jaune-doux); }
.consent-opt input { flex: none; width: 22px; height: 22px; margin-top: 1px; accent-color: var(--encre); }
.consent-opt strong { display: block; color: var(--encre); font-size: .97rem; margin-bottom: 2px; }
.consent-offers { display: flex; gap: 10px; align-items: flex-start; padding: 0 14px; cursor: pointer; font-size: .8rem; line-height: 1.45; color: var(--gris); }
.consent-offers input { flex: none; width: 18px; height: 18px; margin-top: 1px; accent-color: var(--encre); }
.consent-offers-row { font-size: .8rem; color: var(--gris); }
.btn-block { display: block; width: 100%; text-align: center; }
.send-nudge { margin: 10px 0 0; padding: 12px 14px; border-radius: var(--r-sm); background: var(--jaune-doux); font-size: .92rem; }
.send-nudge p { margin: 0 0 10px; }
.send-nudge .send-status { margin: 8px 0 0; }
.send-nudge .send-status:empty { display: none; }
.btn-small { padding: 9px 18px; font-size: .92rem; }
@media (max-width: 600px) { .gate-head { flex-direction: column; gap: 10px; } .gate-head img { width: 44px; height: 44px; } }
.after-grid > :only-child { grid-column: 1 / -1; }

/* ---------- Rentabilité : sections repliables ---------- */
details.adv { border: 1px solid var(--trait); border-radius: var(--r-sm); margin: 14px 0 0; background: var(--jaune-pale); }
details.adv > summary { cursor: pointer; padding: 12px 16px; font-weight: 700; }
details.adv[open] > summary { border-bottom: 1px solid var(--trait); }
details.adv > :not(summary) { margin-left: 16px; margin-right: 16px; }
details.adv > :last-child { margin-bottom: 14px; }
details.adv .row2:first-of-type, details.adv > .field:first-of-type { margin-top: 12px; }
.res-block { border-top: 1px solid var(--trait); padding: 4px 0; }
.res-block > summary { cursor: pointer; padding: 10px 0; font-weight: 700; }
.res-block .kv { margin: 4px 0 10px; border: 0; padding: 0; }
.result .alert { margin: 12px 0; }

/* ---------- Outils en cartes (accueil, page Outils) ---------- */
.tcards { list-style: none; padding: 0; margin: 18px 0 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; }
@media (min-width: 640px) { .tcards { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; } }
@media (min-width: 980px) { .tcards { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; } }
.tcards > li { display: flex; }
.tcard { display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto 1fr auto; grid-template-areas: "ico" "txt" "go"; width: 100%; color: var(--encre); text-decoration: none; background: #fff; border: 1px solid var(--trait); border-radius: var(--r); overflow: hidden; box-shadow: var(--ombre); transition: transform .15s, box-shadow .15s, border-color .15s; }
.tcard-ico { grid-area: ico; display: block; width: 56px; height: 56px; margin: 22px 22px 0; }
.tcard-txt { grid-area: txt; padding: 14px 22px 22px; }
.tcard-title { margin: 0; font-size: 1.25rem; font-weight: 800; line-height: 1.25; letter-spacing: -.015em; }
.tcard-teaser { margin: 6px 0 0; color: var(--gris); font-size: 1rem; line-height: 1.55; }
.tcard-go { grid-area: go; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 16px 13px 22px; background: var(--jaune-pale); border-top: 1px solid var(--trait); font-weight: 800; font-size: 1rem; line-height: 1.3; transition: background .15s; }
.tcard-arrow { flex: none; position: relative; width: 32px; height: 32px; border-radius: 50%; background: var(--jaune); transition: background .15s; }
.tcard-arrow::after { content: ""; position: absolute; left: 50%; top: 50%; width: 8px; height: 8px; margin: -4px 0 0 -6px; border-top: 2.5px solid var(--encre); border-right: 2.5px solid var(--encre); transform: rotate(45deg); }
.tcard:hover { transform: translateY(-3px); box-shadow: var(--ombre-forte); border-color: var(--trait-fort); text-decoration: none; }
.tcard:hover .tcard-go { background: var(--jaune); }
.tcard:hover .tcard-arrow { background: #fff; }
.tcard:focus-visible { outline: 3px solid var(--encre); outline-offset: 3px; }
@media (max-width: 639px) {
  .tcard { grid-template-columns: auto minmax(0, 1fr); grid-template-rows: auto auto; grid-template-areas: "ico txt" "go go"; }
  .tcard-ico { width: 48px; height: 48px; margin: 18px 0 0 18px; }
  .tcard-txt { padding: 16px 18px 18px 14px; }
  .tcard-title { font-size: 1.15rem; }
  .tcard-go { padding: 11px 14px 11px 18px; }
}
@media (prefers-reduced-motion: reduce) { .tcard, .tcard-go, .tcard-arrow { transition: none; } .tcard:hover { transform: none; } }
