/* Carnet de Vigie : indigo profond, jaune soleil, vert sapin, géométrie de losanges. Polices système uniquement. */
:root {
  --indigo: #1c2268;
  --indigo-2: #2b3390;
  --deep: #12163f;
  --sun: #f5c518;
  --sun-dark: #a87a00;
  --sun-soft: #fff3bd;
  --fir: #1d5a43;
  --fir-soft: #e1eee7;
  --paper: #fbf8ef;
  --ink: #16193a;
  --muted: #53587a;
  --line: #d9d6c4;
  --red: #9b1c1c;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --lattice: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='28' height='14' viewBox='0 0 28 14'><path d='M14 1 26 7 14 13 2 7Z' fill='%23f5c518'/></svg>");
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 12px; }
body { margin: 0; font: 1rem/1.6 var(--sans); color: var(--ink); background: var(--paper); overflow-wrap: break-word; }
img, svg { max-width: 100%; height: auto; }
main, section, article, aside, nav, form, div, li { min-width: 0; }
a { color: var(--indigo-2); text-underline-offset: 3px; }
a:hover { color: var(--indigo); text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--sun); outline-offset: 2px; box-shadow: 0 0 0 5px var(--indigo); }
h1, h2, h3 { font-family: var(--serif); line-height: 1.2; color: var(--indigo); margin: 0 0 .6em; }
h2 { font-size: clamp(1.35rem, 3vw, 1.75rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
.wrap { width: 100%; max-width: 1120px; margin-inline: auto; padding-inline: 16px; }
form, .embedbox, .month td, .favbox, .finder, .toolbox { position: relative; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: 8px; top: -60px; background: var(--sun); color: var(--deep); padding: 10px 14px; z-index: 100; font-weight: 700; }
.skip:focus { top: 8px; }

/* En-tête */
.mast { background: var(--indigo); color: #fff; position: relative; z-index: 20; }
.mast-in { max-width: 1120px; margin: auto; padding: 12px 16px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 24px; }
.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: #fff; }
.logo:hover { color: var(--sun); }
.logo img { flex: none; }
.wm { font: 700 1.25rem/1 var(--serif); display: flex; flex-direction: column; }
.wm small { font: 600 .72rem/1.3 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--sun); }
.mast nav { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 6px; }
.mast nav a, .menu summary { color: #fff; text-decoration: none; padding: 8px 10px; font-weight: 600; font-size: .95rem; border-bottom: 3px solid transparent; display: inline-block; }
.mast nav a:hover, .menu summary:hover { border-bottom-color: var(--sun); color: #fff; }
.menu { position: relative; }
.menu summary { cursor: pointer; list-style: none; }
.menu summary::-webkit-details-marker { display: none; }
.menu summary::after { content: " ▾"; font-size: .8em; }
.menu[open] summary { border-bottom-color: var(--sun); }
.menu-panel { position: absolute; right: 0; top: 100%; z-index: 30; background: #fff; border: 2px solid var(--indigo); border-top: 4px solid var(--sun); min-width: 230px; max-width: calc(100vw - 32px); display: flex; flex-direction: column; box-shadow: 0 10px 24px rgba(18, 22, 63, .25); }
.mast nav .menu-panel a { color: var(--indigo); padding: 10px 14px; border-bottom: 1px solid var(--line); display: block; }
.mast nav .menu-panel a:hover { background: var(--sun-soft); border-bottom-color: var(--line); color: var(--indigo); }
.lattice { height: 14px; background: var(--lattice) repeat-x 0 0 / 28px 14px; background-color: var(--deep); }

/* Boutons et étiquettes */
.btn { display: inline-block; background: var(--indigo); color: #fff; border: 2px solid var(--indigo); padding: 11px 20px; border-radius: 4px; font: 700 1rem/1.2 var(--sans); text-decoration: none; cursor: pointer; text-align: center; }
.btn:hover { background: var(--sun); color: var(--deep); border-color: var(--deep); }
.btn.alt { background: transparent; color: var(--indigo); }
.btn.alt:hover { background: var(--sun); }
.btn.small { padding: 8px 14px; font-size: .92rem; }
.linkbtn { background: none; border: 0; color: var(--indigo-2); text-decoration: underline; cursor: pointer; font: inherit; padding: 8px 4px; }
.kicker { display: inline-block; margin: 0 0 14px; padding: 4px 12px; background: var(--sun); color: var(--deep); font-weight: 700; font-size: .82rem; letter-spacing: .06em; text-transform: uppercase; }
.note { color: var(--muted); font-size: .95rem; }
.rnote { color: var(--muted); font-size: .875rem; margin: 10px 0 0; }
.more { margin-top: 14px; font-weight: 600; }

/* Page d'accueil */
.cover { background: var(--paper); border-bottom: 2px solid var(--indigo); background-image: var(--lattice); background-size: 56px 28px; background-position: right top; }
.cover-in { display: grid; gap: 28px; padding-block: 40px 44px; align-items: center; background: linear-gradient(90deg, var(--paper) 60%, rgba(251, 248, 239, .86)); }
.cover h1 { font-size: clamp(2rem, 6vw, 3.4rem); margin-bottom: .4em; }
.cover mark { background: linear-gradient(transparent 62%, var(--sun) 62%); color: var(--indigo); padding: 0 2px; }
.cover .lead { font-size: 1.1rem; max-width: 56ch; }
.cta { display: flex; flex-wrap: wrap; gap: 12px; margin: 22px 0; }
.hero-art { width: 100%; max-width: 440px; justify-self: center; }
.byline { display: flex; align-items: center; gap: 10px; font-size: .9rem; color: var(--muted); margin: 10px 0 0; }
.seal { flex: none; width: 38px; height: 38px; display: grid; place-items: center; background: var(--sun); color: var(--deep); font: 700 .78rem var(--serif); clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); }
.byline a { color: inherit; }
.gestures { padding-block: 34px 6px; }
.gestures ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; counter-reset: g; }
.gestures li { counter-increment: g; background: #fff; border: 2px solid var(--indigo); padding: 18px 18px 18px 74px; position: relative; border-radius: 4px; }
.gestures li::before { content: counter(g); position: absolute; left: 14px; top: 14px; width: 46px; height: 46px; display: grid; place-items: center; background: var(--sun); color: var(--deep); font: 700 1.2rem var(--serif); clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); }
.gestures b { display: block; font: 700 1.2rem var(--serif); color: var(--indigo); margin-bottom: 4px; }
.gestures span { color: var(--muted); }

.shelf { padding-block: 30px 6px; }
.shelf > h2, .folio > h2 { position: relative; padding-left: 26px; }
.shelf > h2::before, .folio h2::before, .prose h2::before { content: ""; position: absolute; left: 2px; top: .38em; width: 13px; height: 13px; background: var(--sun); border: 2px solid var(--indigo); transform: rotate(45deg); }
.folio h2, .prose h2 { position: relative; padding-left: 26px; }

/* Cartes de rayons (étiquettes de colis) */
.crates, .slips, .labels { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.crates { grid-template-columns: repeat(auto-fill, minmax(min(100%, 215px), 1fr)); }
.crate { height: 100%; display: flex; flex-direction: column; gap: 4px; position: relative; padding: 16px 18px 16px 22px; background: #fff; border: 2px solid var(--indigo); border-left: 12px solid var(--c, var(--indigo)); border-radius: 3px; text-decoration: none; color: var(--ink); }
.crate::after { content: ""; position: absolute; right: 12px; top: 12px; width: 12px; height: 12px; border: 2px solid var(--indigo); border-radius: 50%; }
.crate:hover, .slip:hover, .label:hover { background: var(--sun-soft); color: var(--ink); }
.crate i, .slip i { font-style: normal; font-size: 1.5rem; line-height: 1; }
.crate b, .slip b { font: 700 1.05rem/1.25 var(--serif); color: var(--indigo); padding-right: 18px; }
.crate span, .slip span { color: var(--muted); font-size: .9rem; }
.slips { grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); }
.slip { height: 100%; display: flex; flex-direction: column; gap: 6px; padding: 16px 18px; background: #fff; border: 2px solid var(--indigo); border-top: 8px solid var(--sun); border-radius: 3px 18px 3px 18px; text-decoration: none; color: var(--ink); }

/* Annuaire : étiquettes de sites */
.labels { grid-template-columns: repeat(auto-fill, minmax(min(100%, 160px), 1fr)); gap: 10px; }
.labels > li { position: relative; display: block; }
.label { height: 100%; min-height: 104px; display: flex; flex-direction: column; justify-content: space-between; gap: 8px; background: #fff; border: 1.5px solid var(--indigo); border-radius: 3px; text-decoration: none; color: var(--ink); overflow: hidden; }
.lb-top { display: flex; align-items: center; gap: 8px; padding: 6px 40px 6px 10px; background: var(--c, var(--indigo)); color: #fff; border-bottom: 2px dashed rgba(255, 255, 255, .7); min-width: 0; }
.lb-top i { font-style: normal; flex: none; }
.lb-top em { font-style: normal; font-size: .68rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; line-height: 1.25; overflow-wrap: anywhere; }
.label b { padding: 0 10px; font-size: .98rem; line-height: 1.3; overflow-wrap: anywhere; color: var(--indigo); }
.lb-bar { display: block; height: 10px; margin: 0 10px 8px; opacity: .55; background: repeating-linear-gradient(90deg, var(--indigo) 0 2px, transparent 2px 5px, var(--indigo) 5px 6px, transparent 6px 10px); }
.fav { position: absolute; top: 3px; right: 3px; width: 36px; height: 36px; background: transparent; border: 0; color: #fff; font-size: 1.3rem; line-height: 1; cursor: pointer; z-index: 2; }
.fav[aria-pressed="true"] { color: var(--sun); text-shadow: 0 0 2px var(--deep); }
.finder { margin-bottom: 18px; }
.finder-row { position: relative; max-width: 560px; }
.finder input[type="search"] { width: 100%; font: 1rem var(--sans); padding: 12px 44px 12px 14px; border: 2px solid var(--indigo); border-radius: 4px; background: #fff; color: var(--ink); }
.finder-clear { position: absolute; right: 4px; top: 4px; width: 40px; height: 40px; border: 0; background: transparent; font-size: 1.1rem; cursor: pointer; color: var(--indigo); }
.chips { list-style: none; margin: 14px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chips button { font: 600 .88rem var(--sans); border: 2px solid var(--indigo); background: #fff; color: var(--indigo); padding: 6px 12px; border-radius: 999px; cursor: pointer; border-left: 8px solid var(--c, var(--indigo)); }
.chips button[aria-pressed="true"] { background: var(--indigo); color: #fff; }
.finder-count { color: var(--muted); font-size: .92rem; margin: 12px 0 0; }
.favbox { border: 2px solid var(--sun-dark); background: var(--sun-soft); padding: 14px 16px; margin-bottom: 20px; border-radius: 4px; }
.favbox h3 { margin-bottom: 10px; }
.favbox-actions { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 10px 0 0; }
.empty { text-align: center; padding: 30px 10px; border: 2px dashed var(--line); background: #fff; }

/* Bandeau des pages intérieures */
.banner { background: var(--indigo); color: #fff; border-bottom: 8px solid var(--c, var(--sun)); padding: 22px 0 28px; background-image: var(--lattice); background-size: 56px 28px; background-repeat: repeat-x; background-position: right bottom; }
.banner h1 { color: #fff; font-size: clamp(1.6rem, 4.5vw, 2.5rem); margin: 10px 0 .4em; }
.banner .lead { color: #e6e8ff; font-size: 1.05rem; max-width: 72ch; }
.banner .byline { color: #c9ccf2; }
.banner a { color: #fff; }
.banner .count { color: var(--sun); margin: 0 0 8px; }
.banner .ico { display: inline-block; font-size: .8em; background: var(--sun-soft); padding: .08em .3em; margin-right: .45rem; border-radius: 6px; vertical-align: .05em; }
.crumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 2px 0; font-size: .88rem; color: #c9ccf2; }
.crumbs li + li::before { content: "›"; margin: 0 8px; opacity: .8; }
.crumbs a { color: #fff; }
.author-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px; }
.portrait { width: 150px; height: 150px; display: grid; place-items: center; background: var(--sun); color: var(--deep); font: 700 2.6rem var(--serif); clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); flex: none; }

/* Outil, formulaires et résultats */
.panel { display: grid; gap: 22px; padding-block: 28px 8px; grid-template-columns: minmax(0, 1fr); align-items: start; }
.panel form, .modele-form, .matrix-top { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); gap: 14px; background: #fff; border: 2px solid var(--indigo); border-top: 8px solid var(--sun); padding: 18px; border-radius: 3px; align-content: start; }
.field { display: flex; flex-direction: column; gap: 5px; }
.field.wide { grid-column: 1 / -1; }
.field.check { flex-direction: row; align-items: center; gap: 10px; grid-column: 1 / -1; }
label { font-weight: 600; font-size: .92rem; color: var(--ink); }
input[type="number"], input[type="text"], input[type="date"], input[type="time"], select, textarea { width: 100%; font: 1rem var(--sans); padding: 10px 12px; border: 2px solid var(--indigo); border-radius: 4px; background: var(--paper); color: var(--ink); min-width: 0; }
input[type="checkbox"] { width: 22px; height: 22px; accent-color: var(--indigo); flex: none; }
textarea { resize: vertical; }
.result { background: #fff; border: 2px solid var(--fir); border-left: 12px solid var(--fir); padding: 16px 18px; border-radius: 3px; overflow-wrap: anywhere; min-width: 0; }
.res { margin: 0; display: grid; gap: 8px; }
.res > div { padding: 8px 10px; border-bottom: 1px dotted var(--line); }
.res dt { font-size: .84rem; color: var(--muted); font-weight: 600; }
.res dd { margin: 2px 0 0; font-weight: 700; font-size: 1.02rem; overflow-wrap: anywhere; }
.res > div.main { background: var(--sun-soft); border: 0; border-left: 5px solid var(--sun-dark); }
.res > div.main dd { font-size: 1.3rem; color: var(--deep); font-family: var(--serif); }
.err { color: var(--red); font-weight: 700; margin: 0; }
.conv-main { font: 700 1.3rem/1.3 var(--serif); color: var(--deep); background: var(--sun-soft); padding: 10px 12px; margin: 0 0 10px; border-left: 5px solid var(--sun-dark); overflow-wrap: anywhere; }
.swap { align-self: end; font: 700 .95rem var(--sans); padding: 10px 14px; border: 2px solid var(--indigo); background: #fff; color: var(--indigo); border-radius: 4px; cursor: pointer; }
.swap:hover { background: var(--sun); }
.controls { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 14px; }
.controls select { width: auto; }
.flags { list-style: none; padding: 0; margin: 12px 0 0; display: grid; gap: 6px; }
.flags li { padding: 8px 10px 8px 12px; border-left: 5px solid var(--sun-dark); background: var(--sun-soft); font-size: .95rem; }
.flags li.warn { border-left-color: var(--red); background: #fbe9e7; }
.example { background: #fff; border: 2px dashed var(--indigo); padding: 14px 16px; margin-bottom: 1em; }
.example ul { padding-left: 1.2em; }
.example .result { margin-top: 12px; }

@media (min-width: 900px) {
  .panel { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); }
  .panel .result, .panel > div:last-child { position: sticky; top: 14px; }
  .cover-in { grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); }
  .gestures ol { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Textes éditoriaux */
.folio { padding-block: 26px 40px; }
.folio.wrap { max-width: 880px; }
.folio.wide.wrap { max-width: 1120px; }
.folio ul, .folio ol, .prose ul, .prose ol { padding-left: 1.3em; }
.folio li, .prose li { margin-bottom: .35em; }
.qa details { background: #fff; border: 2px solid var(--indigo); border-radius: 3px; margin-bottom: 8px; }
.qa summary { cursor: pointer; padding: 12px 16px; font-weight: 700; color: var(--indigo); list-style: none; }
.qa summary::-webkit-details-marker { display: none; }
.qa summary::before { content: "+"; display: inline-block; width: 1.2em; font-weight: 700; color: var(--sun-dark); }
.qa details[open] summary::before { content: "−"; }
.qa details p { padding: 0 16px 14px; margin: 0; }
.faqbox { padding-bottom: 40px; }
.chiplist { list-style: none; padding: 0 !important; display: flex; flex-wrap: wrap; gap: 8px; }
.chiplist a { display: inline-block; padding: 8px 12px; border: 2px solid var(--indigo); background: #fff; border-radius: 3px; text-decoration: none; font-size: .92rem; color: var(--indigo); }
.chiplist a:hover { background: var(--sun-soft); }
.embedbox { background: #fff; border: 2px solid var(--indigo); border-left: 12px solid var(--sun); padding: 16px 18px; margin-bottom: 1em; }
.embedbox textarea { font: .85rem/1.4 ui-monospace, Menlo, Consolas, monospace; }
.status { min-height: 1.4em; color: var(--fir); font-weight: 600; margin: 8px 0 0; }
.facts { display: grid; grid-template-columns: minmax(0, 1fr); gap: 2px 20px; }
.facts dt { font-weight: 700; color: var(--indigo); margin-top: 10px; }
.facts dd { margin: 0; overflow-wrap: anywhere; }
@media (min-width: 700px) {
  .facts { grid-template-columns: minmax(160px, 260px) minmax(0, 1fr); }
  .facts dt, .facts dd { padding: 8px 0; margin: 0; border-bottom: 1px solid var(--line); }
}
.plain { list-style: none; padding: 0 !important; columns: 2 260px; }
.plain li { break-inside: avoid; }
.links { list-style: none; padding: 0 !important; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); gap: 10px; }
.links a { display: block; padding: 12px 14px; background: #fff; border: 2px solid var(--indigo); text-decoration: none; border-radius: 3px; }
.links b, .links span { display: block; }
.links span { color: var(--muted); font-size: .85rem; overflow-wrap: anywhere; }
.callout { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; background: #fff; border: 2px solid var(--indigo); border-left: 12px solid var(--c, var(--sun)); padding: 16px 18px; margin: 26px 0; }
.callout p { margin: 0; font-weight: 600; }

/* Guides */
.guide-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; padding-block: 26px 44px; }
.toc { background: #fff; border: 2px solid var(--indigo); padding: 14px 16px; align-self: start; font-size: .92rem; }
.toc ol { margin: 8px 0 0; padding-left: 1.2em; }
.toc a { text-decoration: none; }
.prose { max-width: 760px; }
.prose h2 { margin-top: 1.6em; }
.lead-in { font: 1.18rem/1.55 var(--serif); color: var(--indigo); border-left: 6px solid var(--sun); padding-left: 16px; }
.steps { list-style: none; padding: 0 !important; margin: 24px 0; counter-reset: s; }
.steps > li { counter-increment: s; position: relative; padding-left: 62px; margin-bottom: 24px; }
.steps > li::before { content: counter(s); position: absolute; left: 0; top: 0; width: 46px; height: 46px; display: grid; place-items: center; background: var(--indigo); color: #fff; font: 700 1.1rem var(--serif); clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); }
.steps h2 { margin: 0 0 .4em; padding-left: 0; font-size: 1.3rem; }
.steps h2::before { display: none; }
.alert { background: var(--sun-soft); border: 2px solid var(--sun-dark); border-left: 12px solid var(--sun-dark); padding: 14px 18px; margin: 26px 0; }
.alert b { display: block; text-transform: uppercase; letter-spacing: .08em; font-size: .82rem; color: var(--deep); margin-bottom: 4px; }
.alert b::before { content: "⚠ "; }
.alert p { margin: 0; }
.checklist { background: #fff; border: 2px solid var(--fir); padding: 8px 18px; }
.checklist ul { list-style: none; padding: 0; margin: 8px 0; }
.checklist li { padding: 6px 0 6px 34px; position: relative; border-bottom: 1px dotted var(--line); }
.checklist li:last-child { border-bottom: 0; }
.checklist li::before { content: ""; position: absolute; left: 4px; top: 10px; width: 17px; height: 17px; border: 2px solid var(--fir); border-radius: 3px; }
.guide-nav { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); }
.guide-nav a { display: block; padding: 14px 16px; background: #fff; border: 2px solid var(--indigo); text-decoration: none; font-weight: 700; border-radius: 3px; }
.guide-nav span { display: block; font-size: .78rem; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
@media (min-width: 980px) {
  .guide-layout { grid-template-columns: 230px minmax(0, 1fr); gap: 40px; }
  .toc { position: sticky; top: 14px; }
}

/* Modèles de documents */
.modele-grid { display: grid; gap: 22px; padding-block: 28px 8px; grid-template-columns: minmax(0, 1fr); align-items: start; }
.modele-form { grid-template-columns: minmax(0, 1fr); }
.modele-side h2 { margin-bottom: 10px; }
.paper { background: #fff; border: 1px solid var(--line); box-shadow: 0 6px 18px rgba(18, 22, 63, .12); padding: 26px 28px; font: 1rem/1.5 var(--serif); min-height: 340px; overflow-wrap: anywhere; }
.paper p { margin: 0 0 .35em; }
.dl-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
@media (min-width: 960px) { .modele-grid { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); } }

/* Agenda : calendriers et tableaux */
.tablewrap { position: relative; overflow-x: auto; max-width: 100%; margin: 0 0 1em; border: 1px solid var(--line); background: #fff; }
.evlist { border-collapse: collapse; width: 100%; min-width: 480px; font-size: .94rem; }
.evlist th, .evlist td { text-align: left; padding: 9px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.evlist thead th { background: var(--indigo); color: #fff; }
.evlist caption { text-align: left; padding: 8px 12px; font-weight: 700; }
.months { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 210px), 1fr)); gap: 14px; margin-bottom: 18px; }
.month table { border-collapse: collapse; width: 100%; background: #fff; font-size: .82rem; }
.month caption { font-weight: 700; text-align: left; padding: 6px 0; color: var(--indigo); text-transform: capitalize; }
.month th, .month td { text-align: center; padding: 4px 0; border: 1px solid var(--line); }
.month th { background: var(--paper); font-weight: 600; }
.month td.mk-fete { background: var(--sun); font-weight: 700; }
.month td.mk-promo { background: var(--fir); color: #fff; font-weight: 700; }
.month td.mk-ferie { background: #d9dcff; font-weight: 700; }

/* Balance des choix */
.matrix { padding-block: 26px 8px; }
.matrix .help, .help { color: var(--muted); font-size: .92rem; }
.names { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); gap: 12px; margin-bottom: 14px; }
.crit { border: 2px solid var(--indigo); background: #fff; padding: 12px 14px 14px; margin: 0 0 12px; display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); }
.crit legend { font-weight: 700; color: var(--indigo); padding: 0 6px; }
.crit .help, .crit .scores, .crit .linkbtn { grid-column: 1 / -1; }
.scores { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 150px), 1fr)); gap: 10px; }
.ranking { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 8px; }
.ranking li { display: grid; grid-template-columns: 2.6em minmax(0, 1fr) auto; gap: 4px 10px; align-items: center; padding: 8px 10px; background: var(--paper); border: 1px solid var(--line); }
.ranking .rk { font: 700 1.1rem var(--serif); color: var(--sun-dark); }
.ranking b { overflow-wrap: anywhere; }
.ranking .sc { font-weight: 700; white-space: nowrap; }
.ranking .bar { grid-column: 2 / -1; height: 8px; background: #e5e3d3; display: block; }
.ranking .bar i { display: block; height: 100%; background: var(--fir); }
.verdict { font-weight: 700; color: var(--deep); background: var(--sun-soft); padding: 10px 12px; border-left: 5px solid var(--sun-dark); margin: 0; }
.crit-list dt { margin-top: 12px; }
.fallback { background: #fff; border: 2px dashed var(--indigo); padding: 12px 14px; }

/* Pied de page */
.foot { background: var(--deep); color: #cfd2f0; margin-top: 40px; }
.foot .lattice { background-color: var(--indigo); }
.foot-grid { display: grid; gap: 28px 24px; padding-block: 36px 24px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 170px), 1fr)); }
.foot-about { grid-column: 1 / -1; max-width: 560px; }
.foot h3 { color: var(--sun); font: 700 .85rem var(--sans); letter-spacing: .1em; text-transform: uppercase; margin: 0 0 10px; }
.foot h3.sub { margin-top: 18px; }
.foot ul { list-style: none; margin: 0; padding: 0; }
.foot li { margin-bottom: 6px; }
.foot a { color: #fff; text-decoration: none; }
.foot a:hover { color: var(--sun); text-decoration: underline; }
.foot .logo { margin-bottom: 10px; }
.foot-bottom { border-top: 1px solid rgba(255, 255, 255, .15); padding: 14px 16px; text-align: center; font-size: .82rem; color: #aab0e0; }
.foot-bottom p { margin: 0; }
@media (min-width: 900px) { .foot-about { grid-column: auto; } .foot-grid { grid-template-columns: 1.6fr repeat(4, 1fr); } }

/* Pages intégrables */
body.embed { background: #fff; }
.embed-wrap { max-width: 640px; margin: 0 auto; padding: 12px; }
.embed-wrap h1 { font-size: 1.3rem; }
.embed .panel { grid-template-columns: minmax(0, 1fr); padding-block: 4px; }
.embed .panel .result { position: static; }
.embed-credit { text-align: right; font-size: .85rem; margin: 10px 0 0; }

/* Mobile */
@media (max-width: 699px) {
  .menu-panel { position: static; box-shadow: none; max-width: none; margin-top: 4px; }
  .menu { flex-basis: 100%; }
  .paper { padding: 18px 16px; }
  .cover-in { padding-block: 28px 32px; }
}

/* Impression des modèles */
@media print {
  .mast, .foot, .skip, .modele-form, .dl-actions, .banner, .crumbs, .folio, .shelf, nav { display: none !important; }
  body { background: #fff; }
  .modele-grid { display: block; padding: 0; }
  .paper { border: 0; box-shadow: none; padding: 0; }
  .modele-side h2 { display: none; }
}
