/* modele-lettre-motivation.fr : bureau de poste, papeterie. Mobile d'abord, aucune requête externe. */
@font-face { font-family: "Fraunces"; font-style: normal; font-weight: 400 800; font-display: swap; src: url(/assets/fonts/fraunces-latin.woff2) format("woff2"); }
@font-face { font-family: "Fraunces"; font-style: italic; font-weight: 400 600; font-display: swap; src: url(/assets/fonts/fraunces-italic-latin.woff2) format("woff2"); }

:root {
  --bg: #f4f3ee;          /* blanc cassé froid */
  --paper: #fffefb;       /* feuille */
  --kraft: #eadfc8;       /* enveloppe kraft */
  --kraft-2: #d8c7a3;
  --ink: #13234a;         /* encre bleu marine */
  --ink-2: #33415f;
  --muted: #545f78;
  --rule: #c9cdd8;        /* filets */
  --rule-2: #e2e3e6;
  --red: #b42d17;         /* tampon vermillon, avec parcimonie */
  --mark: #fbe8a2;
  --ok: #1c7445;
  --warn: #9c5200;
  --bad: #b02d18;
  --serif: "Fraunces", "Iowan Old Style", Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --letter: Calibri, Carlito, "Segoe UI", Arial, sans-serif;
  --airmail: repeating-linear-gradient(135deg, var(--red) 0 9px, transparent 9px 16px, var(--ink) 16px 25px, transparent 25px 32px);
  --sheet-shadow: 0 1px 0 #e6e4dc, 0 2px 0 #fff, 0 3px 0 #e1ded4, 0 14px 30px -12px rgba(19, 35, 74, .28);
  color-scheme: light;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 108px; }
body { -webkit-tap-highlight-color: rgba(180, 45, 23, .15); margin: 0; background: var(--bg); color: var(--ink); font: 17px/1.62 var(--sans); overflow-x: hidden; }
body { display: flex; flex-direction: column; min-height: 100vh; }
main { flex: 1 0 auto; }
img, svg { max-width: 100%; }
a, button, select, summary, .btn { touch-action: manipulation; }
[id] { scroll-margin-top: 112px; }
a { color: var(--ink); text-decoration-color: var(--red); text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
a:hover { color: var(--red); }
:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; }
.wrap { width: 100%; max-width: 1160px; margin: 0 auto; padding: 0 16px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 12px; z-index: 99; }
.skip:focus { left: 8px; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- titres ---------- */
h1, h2, h3, .cta-title, .entry-title, .desk-t, .brand-name { font-family: var(--serif); font-optical-sizing: auto; }
h1, h2, h3 { text-wrap: balance; color: var(--ink); line-height: 1.12; letter-spacing: -.012em; font-weight: 650; }
h1 { font-size: clamp(32px, 8.4vw, 60px); margin: 0 0 14px; font-weight: 700; letter-spacing: -.02em; }
h1 em, h2 em { font-style: italic; font-weight: 500; }
h2 { font-size: clamp(25px, 5.6vw, 34px); margin: 48px 0 14px; }
h3 { font-size: 21px; margin: 28px 0 8px; font-weight: 600; }
.lead { font-size: 18px; color: var(--ink-2); margin: 0 0 20px; max-width: 60ch; }
.kicker { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 12px; font-size: 12.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--red); }
.kicker::before { content: ""; width: 22px; height: 2px; background: currentColor; }

/* ---------- en-tête compact ---------- */
.site-head { position: sticky; top: 0; z-index: 20; background: var(--bg); border-bottom: 1px solid var(--rule); }
.site-head::before { content: ""; display: block; height: 4px; background: var(--airmail); }
.head-row { display: grid; grid-template-columns: 1fr auto; grid-template-areas: "brand cta" "nav nav"; align-items: center; column-gap: 12px; padding-top: 8px; }
.brand { grid-area: brand; display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; min-width: 0; }
.brand:hover { color: var(--ink); }
.logo { flex: none; color: var(--ink); }
.brand-name { font-size: 16px; font-weight: 650; line-height: 1.05; letter-spacing: -.01em; max-width: 9.5em; }
.brand-name em { color: var(--red); font-weight: 600; }
.head-cta { grid-area: cta; display: inline-flex; align-items: center; min-height: 44px; padding: 0 14px; background: var(--ink); color: #fff; text-decoration: none; font: 700 14.5px/1 var(--sans); border-radius: 3px; }
.head-cta:hover { background: #0a1735; color: #fff; }
.main-nav { grid-area: nav; display: flex; justify-content: space-between; margin-top: 6px; border-top: 1px solid var(--rule-2); }
.main-nav a { color: var(--ink-2); text-decoration: none; font-size: 14.5px; padding: 10px 2px; min-height: 44px; display: inline-flex; align-items: center; border-bottom: 2px solid transparent; }
.main-nav a:hover { color: var(--ink); border-bottom-color: var(--ink); }
.main-nav a[aria-current="page"] { color: var(--ink); font-weight: 650; border-bottom-color: var(--red); }

/* ---------- boutons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 44px; padding: 10px 16px; border-radius: 3px; border: 1.5px solid var(--ink); background: transparent; color: var(--ink); font: 650 15px/1.2 var(--sans); text-decoration: none; cursor: pointer; transition: background .15s, color .15s; }
.btn:hover { background: var(--ink); color: #fff; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--ink); color: #fff; }
.btn-primary:hover { background: #0a1735; }
.btn-lg { min-height: 52px; padding: 12px 22px; font-size: 16.5px; }
.btn-ghost { border-color: transparent; background: transparent; color: var(--muted); min-height: 40px; padding: 8px 4px; text-decoration: underline; }
.btn-ghost:hover { background: transparent; color: var(--red); }
.btn.is-done { background: var(--ok); border-color: var(--ok); color: #fff; }
.fields-clear { grid-column: 1 / -1; justify-self: start; }

/* ---------- formulaires ---------- */
select, input[type=text], input[type=email], input[type=tel], textarea { width: 100%; font: 16px/1.4 var(--sans); color: var(--ink); background: var(--paper); border: 1.5px solid #a9b0c2; border-radius: 3px; padding: 11px 12px; min-height: 48px; }
select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--ink) 50%), linear-gradient(135deg, var(--ink) 50%, transparent 50%); background-position: calc(100% - 20px) 21px, calc(100% - 14px) 21px; background-size: 6px 6px; background-repeat: no-repeat; padding-right: 36px; }
select:focus, input:focus, textarea:focus { border-color: var(--ink); outline: 3px solid rgba(196, 49, 27, .35); outline-offset: 0; }
.step-n { display: inline-grid; place-items: center; width: 24px; height: 24px; margin-right: 8px; border: 1.5px solid var(--red); border-radius: 50%; color: var(--red); font: 700 13px/1 var(--sans); vertical-align: 1px; }

/* ---------- accueil : hero ---------- */
.hero { padding: 26px 0 30px; border-bottom: 1px solid var(--rule); background: linear-gradient(var(--bg), var(--bg)) padding-box; }
.hero-grid { display: grid; gap: 28px; }
.quick-pick { background: var(--paper); border: 1.5px solid var(--ink); padding: 14px; position: relative; }
.quick-pick::after { content: ""; position: absolute; inset: 4px; border: 1px solid var(--rule); pointer-events: none; }
.quick-pick > * { position: relative; z-index: 1; }
.quick-pick label { display: block; font-weight: 700; margin-bottom: 10px; font-size: 15.5px; }
.quick-row { display: grid; gap: 10px; }
.quick-alt { margin: 10px 0 0; font-size: 15px; color: var(--muted); }
.quick-alt a { font-weight: 650; }
.proof { list-style: none; padding: 0; margin: 14px 0 0; display: flex; flex-wrap: wrap; gap: 4px 0; font-size: 13.5px; color: var(--ink-2); }
.proof li { margin-right: 14px; }
.proof li::before { content: "✓ "; color: var(--ok); font-weight: 800; }

.hero-desk { position: relative; max-width: 420px; margin: 0 auto 4px; padding: 0 8px; }
.hero-desk::before { content: ""; position: absolute; inset: 50px -14px -22px -6px; background: var(--kraft); border: 7px solid transparent; border-image: var(--airmail) 7; transform: rotate(4deg); box-shadow: 0 10px 24px -14px rgba(19, 35, 74, .35); }
.sheet { position: relative; background: var(--paper); box-shadow: var(--sheet-shadow); padding: 26px 24px 30px 30px; font: 13px/1.55 var(--letter); color: #1d1d1d; transform: rotate(-1.2deg); }
.sheet::before { content: ""; position: absolute; top: 0; bottom: 0; left: 16px; width: 1px; background: rgba(196, 49, 27, .35); }
.sheet p { margin: 0 0 10px; }
.sheet-date { text-align: right; }
.sheet-fade { opacity: .45; margin-bottom: 0 !important; }
.fill { padding: 0 2px; border-radius: 2px; }
.fill.is-done { background: #e2f1e6; }
.fill.is-empty { background: var(--mark); }
.fill.is-typing { background: #e2f1e6; box-shadow: inset 0 -2px 0 var(--ink); }
.typed { display: inline-block; vertical-align: bottom; white-space: nowrap; overflow: hidden; border-right: 2px solid var(--ink); animation: typing 2.2s steps(20, end) .8s both, caret .8s step-end 6; max-width: 11.2em; }
@keyframes typing { from { max-width: 0; } to { max-width: 11.2em; } }
@keyframes caret { 50% { border-color: transparent; } }
.postmark { position: absolute; right: -6px; bottom: -26px; width: 112px; height: 112px; color: var(--red); opacity: .88; transform: rotate(-14deg); font-family: var(--sans); mix-blend-mode: multiply; }

.quick-jobs { display: grid; gap: 8px; }
.quick-jobs-t { margin: 0; font-size: 12.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.quick-jobs ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.quick-jobs a { display: inline-flex; align-items: center; min-height: 40px; padding: 6px 12px; border: 1px solid var(--rule); background: var(--paper); color: var(--ink); text-decoration: none; font-size: 15px; border-radius: 2px; }
.quick-jobs a:hover { border-color: var(--ink); color: var(--ink); }
.quick-jobs .more-jobs { border-style: dashed; }

/* ---------- listes à filets (registre) ---------- */
.entries { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--ink); counter-reset: entry; }
.entries > li { border-bottom: 1px solid var(--rule); counter-increment: entry; }
.entry { position: relative; display: grid; gap: 2px; padding: 14px 34px 14px 0; color: var(--ink); text-decoration: none; }
.entry::after { content: "→"; position: absolute; right: 6px; top: 14px; font-size: 18px; color: var(--muted); transition: transform .15s, color .15s; }
.entry:hover { color: var(--ink); background: linear-gradient(90deg, rgba(19, 35, 74, .04), transparent); }
.entry:hover::after { color: var(--red); transform: translateX(4px); }
.entry-title { font-size: 19.5px; font-weight: 600; line-height: 1.25; }
.entry:hover .entry-title { text-decoration: underline; text-decoration-color: var(--red); text-decoration-thickness: 1.5px; text-underline-offset: 4px; }
.entry-text { color: var(--ink-2); font-size: 15px; line-height: 1.5; }
.entry-tag { font-size: 11.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--red); }
.entries.numbered .entry { padding-left: 46px; }
.entries.numbered .entry::before { content: counter(entry, decimal-leading-zero); position: absolute; left: 0; top: 15px; font: 600 15px/1.4 var(--serif); color: var(--muted); }

.home-sec { margin: 40px 0; }
.sec-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px; margin-bottom: 12px; }
.sec-head h2 { margin: 0; }
.sec-more { font-weight: 650; font-size: 15.5px; }

/* outils : guichets numérotés */
.desks { margin: 48px 0; }
.desks h2 { margin-top: 0; }
.desk-list { list-style: none; margin: 0; padding: 0; display: grid; border: 1.5px solid var(--ink); background: var(--paper); }
.desk-list li + li { border-top: 1px solid var(--rule); }
.desk { display: grid; grid-template-columns: auto 1fr; column-gap: 14px; row-gap: 2px; padding: 18px 16px; color: var(--ink); text-decoration: none; height: 100%; }
.desk:hover { background: var(--ink); color: #fff; }
.desk:hover .desk-x, .desk:hover .desk-n { color: #d6dbea; }
.desk-n { grid-row: span 2; font: 600 30px/1 var(--serif); color: var(--red); padding-top: 2px; }
.desk-t { font-size: 24px; font-weight: 650; line-height: 1.15; }
.desk-x { color: var(--ink-2); font-size: 15.5px; line-height: 1.5; }

/* ---------- fil d'Ariane, en-têtes de page ---------- */
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 2px 0; padding: 0; margin: 18px 0 10px; font-size: 13px; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.crumbs li + li::before { content: "/"; margin: 0 8px; color: var(--rule); }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--red); text-decoration: underline; }
.crumbs [aria-current] { color: var(--ink); }
.page-head { padding: 8px 0 18px; border-bottom: 1px solid var(--rule); margin-bottom: 24px; }
.page-head .lead { margin-bottom: 0; }
.jump ul { list-style: none; margin: 0 0 8px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.jump a { display: inline-flex; gap: 6px; align-items: center; min-height: 40px; padding: 6px 12px; border: 1px solid var(--rule); background: var(--paper); text-decoration: none; font-size: 14.5px; border-radius: 2px; }
.jump a span { color: var(--red); font-weight: 700; }
.hub-group h2 { display: flex; align-items: baseline; gap: 12px; }
.hub-count { font: 700 13px/1 var(--sans); color: var(--red); border: 1.5px solid var(--red); border-radius: 2px; padding: 5px 7px; transform: translateY(-4px); }

/* ---------- articles ---------- */
.article-wrap { max-width: 860px; }
.article-head { margin-bottom: 22px; padding-bottom: 18px; border-bottom: 1px solid var(--rule); }
.byline { font-size: 14px; color: var(--muted); margin: 0; }
.byline a { color: var(--muted); }
.tpl-jump { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 24px; }
#modele { scroll-margin-top: 16px; }
.toc { margin: 0 0 28px; padding: 14px 0 6px; border-top: 2px solid var(--ink); border-bottom: 1px solid var(--rule); }
.toc-title { margin: 0 0 6px; font-size: 12.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--red); }
.toc ol { margin: 0; padding: 0; list-style: none; counter-reset: toc; font-size: 15.5px; }
.toc li { counter-increment: toc; border-top: 1px dotted var(--rule); }
.toc li:first-child { border-top: 0; }
.toc a { display: flex; gap: 12px; padding: 8px 0; text-decoration: none; color: var(--ink); }
.toc a::before { content: counter(toc); flex: none; width: 1.4em; font: 600 15px/1.5 var(--serif); color: var(--muted); }
.toc a:hover { color: var(--red); }
.prose { font-size: 17.5px; }
.prose p, .prose li { max-width: 68ch; }
.prose ul, .prose ol { padding-left: 22px; }
.prose li { margin: 6px 0; }
.prose ul li::marker { color: var(--red); }
.prose > p:first-child { font-size: clamp(17.5px, 2.4vw, 19px); color: var(--ink); }
.prose h2 { padding-top: 14px; border-top: 1px solid var(--rule); }
.prose blockquote { margin: 20px 0; padding: 4px 0 4px 18px; border-left: 3px solid var(--ink); font-family: var(--serif); font-style: italic; font-size: 18.5px; color: var(--ink-2); }
.prose blockquote p { margin: 6px 0; }
.prose code { background: #e9e8e2; padding: 1px 5px; border-radius: 2px; font-size: .92em; }
.table-wrap { overflow-x: auto; margin: 20px 0; border-top: 2px solid var(--ink); border-bottom: 2px solid var(--ink); }
table { border-collapse: collapse; width: 100%; font-size: 15.5px; }
th, td { text-align: left; padding: 10px 12px 10px 0; border-bottom: 1px solid var(--rule); vertical-align: top; }
th { font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); }
td:first-child { font-weight: 600; }
tr:last-child td { border-bottom: 0; }
.callout { position: relative; margin: 24px 0; padding: 16px 16px 14px; background: var(--paper); border: 1px solid var(--rule); border-top: 3px solid var(--ink); }
.callout::before { display: block; margin-bottom: 6px; font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-2); }
.callout p:first-child { margin-top: 0; }
.callout p:last-child { margin-bottom: 0; }
.callout-reponse { font-size: 18px; }
.callout-reponse::before { content: "La réponse courte"; color: var(--red); }
.callout-astuce { border-top-color: var(--ok); }
.callout-astuce::before { content: "Astuce"; color: var(--ok); }
.callout-attention { border-top-color: var(--warn); }
.callout-attention::before { content: "Attention"; color: var(--warn); }
.faq { border-bottom: 1px solid var(--rule); margin: 0; }
h2 + .faq, .prose .faq:first-of-type { border-top: 2px solid var(--ink); }
.faq summary { cursor: pointer; padding: 14px 40px 14px 0; font: 600 18px/1.35 var(--serif); list-style: none; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 8px; top: 9px; font: 400 26px/1 var(--sans); color: var(--red); }
.faq[open] summary::after { content: "×"; }
.faq > p, .faq > ul, .faq > ol { margin: 0 0 14px; }

/* ---------- la feuille (lettre) ---------- */
.paper { position: relative; background: var(--paper); box-shadow: var(--sheet-shadow); padding: 24px 18px 26px 26px; font: 15.5px/1.6 var(--letter); color: #161616; }
.paper::before { content: ""; position: absolute; top: 0; bottom: 0; left: 13px; width: 1px; background: rgba(196, 49, 27, .3); }
.paper p, .prose .paper p { margin: 0 0 12px; max-width: none; }
.paper p:last-child { margin-bottom: 0; }
.paper .ph { background: var(--mark); border-radius: 2px; padding: 0 2px; }
.paper .ph.filled { background: #e2f1e6; }
.hint { background: #e2e8f8; color: #1d2c6b; border-radius: 2px; padding: 0 2px; }
.f-note { grid-column: 1 / -1; margin: 0; }
.paper[contenteditable]:focus { outline: 2px dashed var(--ink); outline-offset: 4px; }

.letter { margin: 28px 0; padding: 0; }
.letter figcaption { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.letter figcaption::after { content: ""; flex: 1; height: 6px; background: var(--airmail); opacity: .8; }
.letter-label { display: inline-block; font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--red); border: 1.5px solid var(--red); padding: 4px 8px; border-radius: 2px; }
.letter-fields { display: grid; gap: 10px; background: var(--kraft); border: 1px solid var(--kraft-2); padding: 14px; margin-bottom: 16px; }
.letter-fields .f-title { margin: 0; font-weight: 700; font-size: 15px; }
.field label { display: block; font-size: 14px; font-weight: 650; color: var(--ink-2); margin-bottom: 4px; }
.fields-toggle { justify-self: start; background: var(--paper); }
.letter-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 16px; }
.letter-actions .btn { flex: 1 1 auto; }
.letter-meta { width: 100%; font-size: 13px; color: var(--muted); }

/* ---------- outils ---------- */
.tool-head { border-bottom: 0; margin-bottom: 8px; }
.gen-pick label, .gen-step { display: flex; align-items: center; font-weight: 700; margin: 0 0 10px; font-size: 16px; }
.gen-step-hint { font-weight: 400; color: var(--muted); font-size: 14px; margin-left: 6px; }
.gen { margin: 8px 0 40px; border-top: 2px solid var(--ink); padding-top: 16px; }
.gen-pick { max-width: 520px; }
.gen-grid { display: grid; gap: 20px; margin-top: 20px; }
.gen-form { background: var(--kraft); border: 1px solid var(--kraft-2); padding: 14px; }
.gen-form [data-gen-fields] { display: grid; gap: 10px; }
.gen .paper { min-height: 320px; }
@media (max-width: 899px) {
  .gen-grid { gap: 14px; }
  .gen-grid .step-n { display: none; }
  .gen-out { order: -1; position: sticky; top: 107px; z-index: 5; background: var(--bg); padding: 6px 0 8px; border-bottom: 1px solid var(--rule); }
  .gen .paper { min-height: 0; max-height: 34vh; overflow: auto; padding: 14px 14px 14px 24px; font-size: 14px; box-shadow: 0 0 0 1px var(--rule); }
  .gen .letter-actions { margin-top: 8px; }
  .gen .letter-actions .btn { min-height: 44px; padding: 8px 10px; font-size: 14px; }
  .gen .letter > .small { display: none; }
}
.checker, .counter { margin: 8px 0 40px; border-top: 2px solid var(--ink); padding-top: 16px; }
.checker textarea { min-height: 280px; font-family: var(--letter); background: var(--paper) repeating-linear-gradient(transparent 0 27px, #e8e9ee 27px 28px); background-attachment: local; line-height: 28px; padding-top: 6px; }
.chk-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 12px; }
.chk-result { margin-top: 24px; }
.score { display: flex; align-items: center; gap: 18px; margin-bottom: 16px; }
.score-num { width: 96px; height: 96px; flex: none; border-radius: 50%; display: grid; place-items: center; text-align: center; font: 700 32px/1 var(--serif); color: #fff; box-shadow: inset 0 0 0 4px rgba(255, 255, 255, .9), inset 0 0 0 6px currentColor; transform: rotate(-8deg); }
.score-num small { display: block; font: 600 12px/1.2 var(--sans); opacity: .9; }
.checks { list-style: none; padding: 0; margin: 0; border-top: 2px solid var(--ink); }
.checks li { padding: 12px 4px 12px 36px; border-bottom: 1px solid var(--rule); position: relative; font-size: 15.5px; }
.checks li::before { position: absolute; left: 6px; top: 11px; font-weight: 800; }
.checks .ok::before { content: "✓"; color: var(--ok); }
.checks .warn::before { content: "!"; color: var(--warn); left: 10px; }
.checks .bad::before { content: "✕"; color: var(--bad); }
.checks li b { display: block; }
.cnt-top { display: grid; gap: 6px; margin-bottom: 12px; }
.cnt-gauge { height: 10px; background: var(--rule-2); overflow: hidden; }
.cnt-bar { height: 100%; width: 0; background: var(--ok); transition: width .15s; }
.cnt-bar.near { background: var(--warn); }
.cnt-bar.over { background: var(--bad); }
.cnt-left { font-weight: 700; margin: 8px 0 12px; min-height: 1.4em; }
.counter textarea { min-height: 240px; }
.cnt-stats { display: grid; grid-template-columns: repeat(2, 1fr); margin-top: 16px; border-top: 2px solid var(--ink); }
.cnt-stat { padding: 12px 8px 12px 0; display: grid; border-bottom: 1px solid var(--rule); }
.cnt-num { font-variant-numeric: tabular-nums; font: 650 28px/1.1 var(--serif); }
.cnt-lab { font-size: 13.5px; color: var(--ink-2); }

/* ---------- enveloppe d'appel à l'action ---------- */
.related { margin: 48px 0 0; }
.cta-band { position: relative; display: grid; gap: 16px; align-items: center; margin: 48px 0; padding: 26px 20px 22px; background: var(--kraft); color: var(--ink); border: 1px solid var(--kraft-2); }
.cta-band::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 7px; background: var(--airmail); }
.cta-title { font-size: 25px; font-weight: 650; margin: 0 0 4px; line-height: 1.2; }
.cta-band p { margin: 0; }

/* ---------- pied de page ---------- */
.site-foot { margin-top: 64px; background: var(--ink); color: #d4d9e6; font-size: 15px; }
.site-foot::before { content: ""; display: block; height: 6px; background: var(--airmail); }
.site-foot a { color: #e9ecf4; text-decoration-color: rgba(255, 255, 255, .35); }
.site-foot a:hover { color: #fff; text-decoration-color: #fff; }
.site-foot :focus-visible { outline-color: #fff; }
.foot-top { display: grid; gap: 10px; padding: 32px 0 22px; border-bottom: 1px solid rgba(255, 255, 255, .18); }
.brand-foot, .brand-foot:hover { grid-area: auto; color: #fff; }
.brand-foot .logo { color: #fff; --paper: var(--ink); }
.brand-foot .brand-name { font-size: 22px; max-width: none; }
.brand-foot .brand-name em { color: #ff9a85; }
.foot-pitch { margin: 0; max-width: 56ch; font-family: var(--serif); font-size: 18px; color: #e9ecf4; }
.foot-row { display: grid; gap: 6px; padding: 14px 0; border-bottom: 1px solid rgba(255, 255, 255, .12); }
.foot-title { margin: 0; font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: #ffb3a3; }
.site-foot ul { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 0 4px; }
.site-foot li { display: inline-flex; }
.site-foot li a { display: inline-block; padding: 6px 10px 6px 0; }
.site-foot li:not(:last-child)::after { content: "·"; color: rgba(255, 255, 255, .4); padding-right: 6px; align-self: center; }
.foot-bottom { margin: 0; padding: 18px 0 30px; font-size: 13px; color: #b3bbd0; }

@media (max-width: 639px) {
  .kicker { letter-spacing: .08em; font-size: 12px; }
  .lead { font-size: 16.5px; }
  .postmark { right: -4px; bottom: -62px; width: 96px; height: 96px; }
  .hero-desk { margin-bottom: 40px; }
  .tpl-jump .btn { flex: 1 1 100%; }
  .hero-desk::before { inset: 50px 0 -18px 4px; }
  /* tableaux empilés : une fiche par ligne, plus de défilement latéral */
  .table-wrap { overflow: visible; }
  .table-wrap table, .table-wrap tbody, .table-wrap tr, .table-wrap td { display: block; width: 100%; }
  .table-wrap thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .table-wrap tr { padding: 10px 0; border-bottom: 1px solid var(--rule); }
  .table-wrap tr:last-child { border-bottom: 0; }
  .table-wrap td { border: 0; padding: 2px 0; }
  .table-wrap td:first-child { font-family: var(--serif); font-size: 18px; }
  .table-wrap td[data-label]:not(:first-child)::before { content: attr(data-label); display: block; font-size: 11.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-top: 6px; }
}

/* ---------- tablette ---------- */
@media (min-width: 640px) {
  .quick-row { grid-template-columns: 1fr auto; }
  .entries.cols { columns: 2; column-gap: 40px; column-rule: 1px solid var(--rule-2); }
  .entries.cols > li { break-inside: avoid; }
  .letter-actions .btn { flex: 0 0 auto; }
  .letter-meta { width: auto; margin-left: auto; }
  .letter-fields { grid-template-columns: 1fr 1fr; }
  .letter-fields .f-title, .letter-fields .fields-toggle { grid-column: 1 / -1; }
  .paper { padding: 44px 48px 48px 58px; }
  .paper::before { left: 34px; }
  .cta-band { grid-template-columns: 1fr auto; padding: 32px 32px 28px; }
  .foot-row { grid-template-columns: 120px 1fr; align-items: baseline; }
  .cnt-stats { grid-template-columns: repeat(3, 1fr); }
  .cnt-top { grid-template-columns: auto 260px; align-items: center; justify-content: start; gap: 12px; }
  .brand-name { max-width: none; font-size: 18px; }
}

/* ---------- bureau ---------- */
@media (min-width: 900px) {
  html { scroll-padding-top: 84px; }
  body { font-size: 17.5px; }
  .head-row { grid-template-columns: auto 1fr auto; grid-template-areas: "brand nav cta"; padding: 0; min-height: 64px; column-gap: 28px; }
  .main-nav { margin: 0; border: 0; justify-content: flex-end; gap: 22px; align-self: stretch; }
  .main-nav a { min-height: 64px; padding: 0; font-size: 15.5px; }
  .head-cta { padding: 0 18px; font-size: 15px; }
  .hero { padding: 52px 0 0; }
  .tool-head h1 { font-size: 50px; }
  .hero-grid { grid-template-columns: 1.1fr .9fr; align-items: center; gap: 56px; }
  .hero-desk { max-width: 460px; margin-right: 10px; }
  .sheet { font-size: 14px; padding: 36px 34px 40px 44px; }
  .sheet::before { left: 26px; }
  .postmark { width: 128px; height: 128px; right: -34px; bottom: -58px; }
  .hero-grid { grid-template-areas: "text desk" "jobs desk"; row-gap: 26px; padding-bottom: 44px; }
  .hero-text { grid-area: text; }
  .quick-jobs { grid-area: jobs; }
  .hero-desk { grid-area: desk; }
  .desk-list { grid-template-columns: repeat(3, 1fr); }
  .desk-list li + li { border-top: 0; border-left: 1px solid var(--rule); }
  .desk { grid-template-columns: 1fr; padding: 24px 22px; }
  .desk-n { grid-row: auto; margin-bottom: 10px; }
  .gen-grid { grid-template-columns: 360px 1fr; align-items: start; gap: 32px; }
  .gen-out { position: sticky; top: 84px; }
  .gen .paper { padding: 48px 52px 52px 64px; }
  .gen .paper::before { left: 38px; }
}

/* impression = PDF propre de la lettre seule */
@media print {
  @page { margin: 18mm 20mm; }
  body { background: #fff; }
  body.print-letter * { visibility: hidden; }
  body.print-letter .printing, body.print-letter .printing * { visibility: visible; }
  body.print-letter .printing { position: absolute; left: 0; top: 0; width: 100%; border: 0; box-shadow: none; padding: 0; font-size: 11.5pt; }
  body.print-letter .printing::before { display: none; }
  body.print-letter .printing .ph, body.print-letter .printing .hint { background: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .typed { max-width: none; border-right: 0; }
}
