/* diegemhistory.org — patrimoine de Diegem
   Ivoire, anthracite, vert profond, accents bordeaux. Titres à empattements, texte sans empattements. */

:root {
  --ivory: #F7F3EA;
  --paper: #FFFDF8;
  --line: #E2DACB;
  --ink: #26282A;
  --ink-soft: #55585B;
  --green: #1F4A3A;
  --green-soft: #E3EBE5;
  --green-line: #C7D3CB;
  --wine: #7A2632;
  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Source Sans 3", "Segoe UI", system-ui, sans-serif;
  --wrap: 1180px;
  --header: 72px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header) + 12px); -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--ivory); color: var(--ink); font: 400 1.0625rem/1.65 var(--sans); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--green); text-underline-offset: 3px; }
a:hover { color: var(--wine); }
:focus-visible { outline: 3px solid var(--wine); outline-offset: 3px; border-radius: 2px; }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.1; margin: 0; color: var(--ink); }
h2 { font-size: clamp(2rem, 4.4vw, 3.2rem); }
h3 { font-size: 1.55rem; }
p { margin: 0 0 1em; }
sup { line-height: 0; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
/* Les images ne doivent pas élargir les colonnes des grilles */
.hero-grid > *, .intro-grid > *, .memory-grid > *, .page-head-grid > *, .compare-grid > *, .tl-item > *, .tl-body > *, .foot-grid > * { min-width: 0; }
@media (max-width: 480px) { .wrap { padding: 0 16px; } }
.eyebrow { font: 600 .8rem/1.3 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--wine); margin: 0 0 14px; }
.lead { font-size: 1.2rem; color: var(--ink-soft); max-width: 62ch; }
.muted { color: var(--ink-soft); }
.section { padding: clamp(56px, 9vw, 120px) 0; }
.section-head { max-width: 720px; margin-bottom: 44px; }
.section-head p:last-child { color: var(--ink-soft); margin: 14px 0 0; }
.band { background: var(--paper); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--green); color: #fff; padding: 10px 16px; z-index: 100; }
.skip:focus { left: 8px; color: #fff; }

.btn { display: inline-block; background: var(--green); color: #fff; text-decoration: none; font-weight: 600; padding: 14px 26px; border-radius: 4px; border: 2px solid var(--green); transition: background .2s, color .2s; }
.btn:hover { background: transparent; color: var(--green); }
.frame { display: block; background: var(--paper); padding: 14px; border: 1px solid var(--line); box-shadow: 0 18px 40px -24px rgba(38, 40, 42, .45); }
figure { margin: 0; }
figcaption { font-size: .88rem; color: var(--ink-soft); margin-top: 10px; font-style: italic; }
.tag { font: 600 .72rem/1.2 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--wine); }

/* ---------- En-tête ---------- */
.site-header { position: sticky; top: 0; z-index: 40; background: rgba(247, 243, 234, .95); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 20px; height: var(--header); }
.brand { font-family: var(--serif); font-size: 1.5rem; font-weight: 600; color: var(--ink); text-decoration: none; white-space: nowrap; }
.brand span, .foot-brand span { color: var(--wine); font-style: italic; }
.nav { display: flex; align-items: center; gap: 34px; }
.nav ul { list-style: none; display: flex; gap: 30px; margin: 0; padding: 0; }
.nav ul a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: .98rem; padding: 6px 0; border-bottom: 2px solid transparent; }
.nav ul a:hover, .nav ul a[aria-current="true"] { border-color: var(--wine); color: var(--ink); }
.lang { display: flex; gap: 2px; border-left: 1px solid var(--line); padding-left: 22px; }
.lang a { font: 600 .8rem/1 var(--sans); letter-spacing: .08em; color: var(--ink-soft); text-decoration: none; padding: 7px 7px; border-radius: 3px; }
.lang a[aria-current="true"] { background: var(--green); color: #fff; }
.lang a:hover { color: var(--wine); }
.lang a[aria-current="true"]:hover { color: #fff; }
.menu-btn { display: none; align-items: center; gap: 10px; background: none; border: 1px solid var(--line); border-radius: 6px; padding: 9px 14px; font: 600 .95rem var(--sans); color: var(--ink); cursor: pointer; }
.menu-icon, .menu-icon::before, .menu-icon::after { display: block; width: 18px; height: 2px; background: currentColor; transition: transform .2s; }
.menu-icon { position: relative; }
.menu-icon::before, .menu-icon::after { content: ""; position: absolute; left: 0; }
.menu-icon::before { top: -6px; }
.menu-icon::after { top: 6px; }
.menu-btn[aria-expanded="true"] .menu-icon { background: transparent; }
.menu-btn[aria-expanded="true"] .menu-icon::before { transform: translateY(6px) rotate(45deg); }
.menu-btn[aria-expanded="true"] .menu-icon::after { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 1080px) {
  .menu-btn { display: inline-flex; }
  .brand { font-size: 1.3rem; }
  .nav { position: absolute; left: 0; right: 0; top: var(--header); display: none; flex-direction: column; align-items: stretch; gap: 0; background: var(--ivory); border-bottom: 1px solid var(--line); padding: 4px 24px 22px; max-height: calc(100vh - var(--header)); overflow-y: auto; }
  .nav.open { display: flex; }
  .nav ul { flex-direction: column; gap: 0; }
  .nav ul a { display: block; padding: 15px 0; border-bottom: 1px solid var(--line); font-size: 1.05rem; }
  .lang { border-left: 0; padding: 18px 0 0; gap: 8px; }
  .lang a { padding: 10px 14px; border: 1px solid var(--line); }
}
@media (max-width: 380px) { .brand span { display: none; } }

/* ---------- Accueil ---------- */
.hero { padding: clamp(36px, 7vw, 90px) 0 clamp(48px, 8vw, 100px); }
.hero-grid { display: grid; grid-template-columns: 1fr 1.15fr; gap: clamp(32px, 5vw, 72px); align-items: center; }
.hero h1 { font-size: clamp(2.6rem, 6.4vw, 5rem); line-height: 1.02; margin-bottom: 24px; }
.hero h1 em { color: var(--green); }
.hero .lead { margin-bottom: 32px; }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-top: clamp(44px, 6vw, 80px); }
.stat { padding: 26px 20px; border-left: 1px solid var(--line); }
.stat:first-child { border-left: 0; padding-left: 0; }
.stat b { display: block; font-family: var(--serif); font-size: 2.6rem; font-weight: 600; color: var(--green); line-height: 1; margin-bottom: 6px; }
.stat span { font-size: .92rem; color: var(--ink-soft); }
@media (max-width: 820px) {
  .hero-grid { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stat { padding: 20px 16px; }
  .stat:nth-child(odd) { border-left: 0; padding-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
  .stat b { font-size: 2.1rem; }
}

/* Présentation */
.intro-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(32px, 5vw, 72px); align-items: start; }
.intro-text h2 { margin-bottom: 28px; }
.intro-text .prose > p:first-child::first-letter { font-family: var(--serif); font-size: 3.6rem; float: left; line-height: .85; padding: 6px 10px 0 0; color: var(--wine); }
.intro-grid aside { position: sticky; top: calc(var(--header) + 28px); }
.links { display: flex; flex-wrap: wrap; gap: 8px 24px; font-weight: 600; font-size: .95rem; }
@media (max-width: 900px) { .intro-grid { grid-template-columns: 1fr; } .intro-grid aside { position: static; } }

/* Frise */
.timeline { position: relative; list-style: none; margin: 0; padding: 0; }
.timeline::before { content: ""; position: absolute; left: 150px; top: 6px; bottom: 6px; width: 1px; background: var(--line); }
.tl-item { display: grid; grid-template-columns: 150px 1fr; gap: 0 40px; padding: 0 0 44px; }
.tl-year { font-family: var(--serif); font-size: 1.7rem; font-weight: 600; color: var(--wine); line-height: 1.15; padding-right: 24px; text-align: right; }
.tl-body { position: relative; display: grid; grid-template-columns: 1fr 220px; gap: 28px; align-items: start; }
.tl-body::before { content: ""; position: absolute; left: -46px; top: 10px; width: 11px; height: 11px; border-radius: 50%; background: var(--ivory); border: 2px solid var(--green); }
.tl-body.noimg { grid-template-columns: 1fr; }
.tl-body h3 { font-size: 1.4rem; margin-bottom: 6px; }
.tl-body p { color: var(--ink-soft); margin: 0; max-width: 56ch; }
.tl-body img { width: auto; max-width: 100%; max-height: 240px; margin-left: auto; border: 1px solid var(--line); background: var(--paper); padding: 6px; }
.tl-more { display: inline-block; margin-top: 8px; font-weight: 600; font-size: .92rem; }
@media (max-width: 760px) {
  .timeline::before { left: 5px; }
  .tl-item { grid-template-columns: 1fr; padding-left: 30px; padding-bottom: 36px; }
  .tl-year { position: relative; text-align: left; padding: 0; margin-bottom: 6px; }
  .tl-year::before { content: ""; position: absolute; left: -30px; top: 10px; width: 11px; height: 11px; border-radius: 50%; background: var(--ivory); border: 2px solid var(--green); }
  .tl-body { grid-template-columns: 1fr; gap: 16px; }
  .tl-body::before { display: none; }
  .tl-body img { margin-left: 0; max-height: 260px; }
}

/* Patrimoine */
.heritage { background: var(--green-soft); }
.filters { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 36px; }
.filters button { font: 600 .92rem var(--sans); background: var(--paper); color: var(--ink); border: 1px solid var(--green-line); border-radius: 999px; padding: 9px 16px; cursor: pointer; }
.filters button:hover { border-color: var(--green); }
.filters button[aria-pressed="true"] { background: var(--green); border-color: var(--green); color: #fff; }
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 28px; }
.card { background: var(--paper); border: 1px solid var(--line); display: flex; flex-direction: column; color: inherit; text-decoration: none; transition: transform .25s, box-shadow .25s; }
.card:hover { color: inherit; transform: translateY(-3px); box-shadow: 0 16px 32px -22px rgba(38, 40, 42, .55); }
.card:hover h3 { color: var(--wine); }
.card[hidden] { display: none; }
.card .ph { aspect-ratio: 4 / 3; background: #EFE9DC; overflow: hidden; }
.card .ph img { width: 100%; height: 100%; object-fit: cover; }
.card .bd { padding: 20px 22px 24px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.card h3 { font-size: 1.5rem; transition: color .2s; }
.card p { font-size: .97rem; color: var(--ink-soft); margin: 0; }
.card .meta { margin-top: auto; padding-top: 8px; font-size: .85rem; font-weight: 600; color: var(--green); }
.noimg-list { margin-top: 56px; border-top: 1px solid var(--green-line); padding-top: 32px; }
.noimg-list h3 { font-size: 1.35rem; margin-bottom: 6px; }
.noimg-list > p { color: var(--ink-soft); margin-bottom: 18px; }
.noimg-list ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px 32px; }
.noimg-list li { padding-left: 16px; border-left: 2px solid var(--wine); font-size: .97rem; color: var(--ink-soft); }
.noimg-list li a { color: var(--ink); }
.noimg-list li[hidden] { display: none; }
@media (max-width: 420px) { .cards, .noimg-list ul { grid-template-columns: 1fr; } }

/* Galerie (accueil et pages) */
.gallery { columns: 4 240px; column-gap: 18px; }
.z-item { display: block; width: 100%; padding: 0; background: none; border: 0; font: inherit; color: inherit; text-align: left; cursor: zoom-in; }
.gallery .z-item { margin: 0 0 18px; padding: 10px 10px 12px; background: var(--paper); border: 1px solid var(--line); break-inside: avoid; transition: transform .25s, box-shadow .25s; }
.gallery .z-item:hover { transform: translateY(-2px); box-shadow: 0 14px 30px -20px rgba(38, 40, 42, .5); }
.gallery img { width: 100%; }
.z-item .cap { display: block; font-size: .86rem; line-height: 1.4; color: var(--ink-soft); margin-top: 9px; }
.z-item .cap b { display: block; color: var(--ink); font-weight: 600; }
.z-item.solo { padding: 14px; }
.note { font-size: .9rem; color: var(--ink-soft); margin-top: 12px; max-width: 75ch; }
@media (max-width: 560px) { .gallery { columns: 2; column-gap: 12px; } .gallery .z-item { margin-bottom: 12px; padding: 6px 6px 8px; } .z-item .cap { font-size: .8rem; } }

/* Diaporama (une photo à la fois) */
.slideshow { max-width: 1000px; margin: 0 auto; }
.gallery.ss-track { columns: auto; position: relative; aspect-ratio: 2048 / 1445; background: var(--paper); border: 1px solid var(--line); }
.gallery.ss-track .z-item { position: absolute; inset: 0; margin: 0; padding: 10px; border: 0; opacity: 0; visibility: hidden; transition: opacity .6s, visibility .6s; }
.gallery.ss-track .z-item:hover { transform: none; box-shadow: none; }
.gallery.ss-track .z-item.on { opacity: 1; visibility: visible; }
.gallery.ss-track img { width: 100%; height: 100%; object-fit: contain; }
.ss-ctrl { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 14px; }
.ss-ctrl button { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: var(--paper); color: var(--green); font-size: 1.1rem; cursor: pointer; }
.ss-ctrl button:hover { border-color: var(--green); }
.ss-count { min-width: 64px; text-align: center; font-variant-numeric: tabular-nums; color: var(--ink-soft); }

/* Cartes de liens */
.linkcards { display: grid; gap: 22px; margin: 28px 0; }
.linkcard { display: grid; gap: 16px; padding: 14px 14px 20px; background: var(--paper); border: 1px solid var(--line); color: inherit; text-decoration: none; transition: box-shadow .25s; }
.linkcard:hover { box-shadow: 0 14px 30px -20px rgba(38, 40, 42, .5); }
.linkcard img { width: 100%; height: auto; }
.lc-body { padding: 0 6px; }
.lc-body b { display: block; font-family: var(--serif); font-size: 1.5rem; color: var(--green); margin-bottom: 6px; }
.lc-body span { display: block; font-size: .97rem; color: var(--ink-soft); }
.lc-body small { display: block; margin-top: 10px; color: var(--wine); font-weight: 600; }
/* Visionneuse */
.lightbox { border: 0; padding: 0; background: transparent; max-width: none; max-height: none; width: 100%; height: 100%; margin: 0; overflow: hidden; }
.lightbox::backdrop { background: rgba(20, 22, 22, .92); }
.lightbox[open] { display: block; }
.lb-inner { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 64px 80px 24px; gap: 14px; }
.lb-inner img { max-width: 100%; max-height: calc(100vh - 160px); width: auto; height: auto; background: #fff; padding: 8px; }
.lb-cap { color: #EDE7DA; text-align: center; max-width: 70ch; font-size: .98rem; margin: 0; }
.lb-btn { position: fixed; background: rgba(247, 243, 234, .1); color: #fff; border: 1px solid rgba(247, 243, 234, .35); width: 48px; height: 48px; border-radius: 50%; font-size: 1.4rem; line-height: 1; cursor: pointer; display: grid; place-items: center; }
.lb-btn:hover { background: rgba(247, 243, 234, .25); }
.lb-close { top: 14px; right: 14px; }
.lb-prev { left: 14px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 14px; top: 50%; transform: translateY(-50%); }
.lightbox.single .lb-prev, .lightbox.single .lb-next { display: none; }
@media (max-width: 640px) {
  .lb-inner { padding: 68px 12px 84px; }
  .lb-inner img { max-height: calc(100vh - 200px); }
  .lb-prev, .lb-next { top: auto; bottom: 18px; transform: none; }
  .lb-prev { left: calc(50% - 60px); }
  .lb-next { right: calc(50% - 60px); }
}

/* Hier et aujourd'hui */
.compare-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 40px; }
.compare { position: relative; aspect-ratio: 3 / 2; overflow: hidden; border: 1px solid var(--line); background: var(--paper); touch-action: pan-y; }
.compare img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.compare .before { clip-path: inset(0 calc(100% - var(--pos, 50%)) 0 0); }
.compare .divider { position: absolute; top: 0; bottom: 0; left: var(--pos, 50%); width: 3px; margin-left: -1.5px; background: var(--paper); pointer-events: none; box-shadow: 0 0 0 1px rgba(0, 0, 0, .15); }
.compare .divider::after { content: "\2194"; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 40px; height: 40px; border-radius: 50%; background: var(--paper); color: var(--green); display: grid; place-items: center; font-size: 1.2rem; box-shadow: 0 2px 8px rgba(0, 0, 0, .25); }
.compare input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: ew-resize; margin: 0; }
.compare:focus-within { outline: 3px solid var(--wine); outline-offset: 3px; }
.compare .lbl { position: absolute; top: 12px; font: 600 .74rem/1 var(--sans); letter-spacing: .12em; text-transform: uppercase; background: rgba(38, 40, 42, .78); color: #fff; padding: 6px 10px; pointer-events: none; }
.compare .lbl.l { left: 12px; }
.compare .lbl.r { right: 12px; }
.compare-item h3 { margin: 18px 0 6px; }
.compare-item h3 a { color: inherit; text-decoration: none; }
.compare-item h3 a:hover { color: var(--wine); }
.compare-item p { color: var(--ink-soft); font-size: .97rem; margin: 0; }
@media (max-width: 820px) { .compare-grid { grid-template-columns: 1fr; } }

/* Mémoire */
.memory-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 5vw, 64px); align-items: start; }
.memory h2 { margin-bottom: 28px; }
.memory blockquote { margin: 0 0 28px; padding: 0 0 0 24px; border-left: 3px solid var(--wine); }
.memory blockquote p { font-family: var(--serif); font-size: 1.5rem; line-height: 1.4; font-style: italic; margin: 0; }
.memory blockquote footer { font-size: .9rem; color: var(--ink-soft); margin-top: 10px; }
.memory .btn { margin-top: 8px; }
.panels { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.panels img { border: 1px solid var(--line); }
.story-box { margin-top: 36px; background: var(--paper); border: 1px solid var(--line); padding: 26px 28px; }
.story-box h3 { font-size: 1.4rem; margin-bottom: 10px; }
.story-box h3 a { color: inherit; }
.story-box p { font-size: .97rem; color: var(--ink-soft); }
.story-box .credit { font-style: italic; margin: 0; }
@media (max-width: 900px) { .memory-grid { grid-template-columns: 1fr; } }

/* Contribution */
.contribute { background: var(--green); color: #F2EFE6; text-align: center; }
.contribute .eyebrow { color: #E7C9CD; }
.contribute h2 { color: #fff; max-width: 20ch; margin: 0 auto 18px; }
.contribute p { max-width: 56ch; margin: 0 auto 30px; color: #D8E2DB; }
.contribute .btn { background: var(--ivory); border-color: var(--ivory); color: var(--green); }
.contribute .btn:hover { background: transparent; color: #fff; }
.contribute small { display: block; margin-top: 16px; color: #BFD0C5; font-size: .88rem; }

/* ---------- Pages ---------- */
.page-head { padding: clamp(32px, 6vw, 72px) 0 clamp(36px, 6vw, 64px); border-bottom: 1px solid var(--line); }
.page-head-grid { display: grid; gap: clamp(28px, 5vw, 64px); align-items: center; }
.page-head.has-img .page-head-grid { grid-template-columns: 1.1fr 1fr; }
.page-head h1 { font-size: clamp(2.3rem, 5.4vw, 4rem); line-height: 1.05; margin: 10px 0 18px; }
.page-head .lead { margin: 0; }
.page-head .frame img { margin: 0 auto; max-height: 70vh; width: auto; }
.crumbs { font-size: .9rem; color: var(--ink-soft); margin: 0 0 22px; display: flex; flex-wrap: wrap; gap: 6px 10px; }
.crumbs a { color: var(--ink-soft); }
.crumbs a:hover { color: var(--wine); }
@media (max-width: 820px) { .page-head.has-img .page-head-grid { grid-template-columns: 1fr; } }

.article.section { padding-bottom: clamp(32px, 5vw, 64px); }
.prose { max-width: 70ch; }
.article .prose > p, .article .prose .list { font-size: 1.1rem; }
.prose h2 { font-size: clamp(1.7rem, 3.2vw, 2.3rem); margin: 1.6em 0 .5em; }
.prose .caption { font-family: var(--serif); font-size: 1.35rem; font-style: italic; color: var(--green); margin: 1.4em 0 .6em; }
.prose .list { margin: 0 0 1.2em; padding-left: 1.2em; }
.prose .list li { margin-bottom: .35em; }
.prose .list li::marker { color: var(--wine); }
.video { position: relative; aspect-ratio: 16 / 9; margin: 1.5em 0; }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.sources { margin-top: 2.4em; padding-top: 1.4em; border-top: 1px solid var(--line); }
.sources h2 { font-size: 1.4rem; margin: 0 0 .6em; }
.sources ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 24px; font-weight: 600; font-size: .95rem; }
.page-gallery { padding-top: 0; }
.sub { font-size: clamp(1.8rem, 3.4vw, 2.5rem); margin-bottom: 32px; }

.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; padding-top: 48px; padding-bottom: 56px; }
.pager a { display: block; padding: 20px 22px; background: var(--paper); border: 1px solid var(--line); text-decoration: none; color: var(--ink); font-family: var(--serif); font-size: 1.35rem; font-weight: 600; line-height: 1.2; }
.pager a:hover { border-color: var(--green); color: var(--wine); }
.pager small { display: block; font: 600 .78rem/1 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 8px; }
.pager .next { text-align: right; }
@media (max-width: 560px) { .pager { grid-template-columns: 1fr; } .pager .next { text-align: left; } }

/* ---------- Pied de page ---------- */
.site-footer { background: #1E2022; color: #CFCAC0; padding: 64px 0 40px; font-size: .94rem; }
.site-footer a { color: #E8E2D5; }
.site-footer a:hover { color: #fff; }
.foot-grid { display: grid; grid-template-columns: 1.3fr .8fr 1fr 1fr; gap: 40px; }
.foot-brand { font-family: var(--serif); font-size: 1.6rem; font-weight: 600; color: #fff; margin-bottom: 12px; }
.foot-brand span { color: #E7C9CD; }
.site-footer h2 { color: #fff; font-size: 1.3rem; margin-bottom: 12px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.foot-bottom { border-top: 1px solid #3A3C3E; margin: 44px 0 0; padding-top: 22px; font-size: .85rem; color: #A39E95; }
@media (max-width: 960px) { .foot-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .foot-grid { grid-template-columns: 1fr; gap: 32px; } }

/* ---------- Apparition légère ---------- */
.js .reveal { opacity: 0; transform: translateY(16px); transition: opacity .7s ease, transform .7s ease; }
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .card, .gallery .z-item, .btn, .menu-icon, .menu-icon::before, .menu-icon::after { transition: none; }
  .card:hover, .gallery .z-item:hover { transform: none; }
}

/* ---------- Recherche (loupe) ---------- */
.header-tools { display: flex; align-items: center; gap: 10px; order: 3; }
.search-btn { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); background: var(--paper); color: var(--ink); cursor: pointer; }
.search-btn:hover { color: var(--wine); border-color: var(--wine); }
.site-header .wrap > .nav { order: 2; margin-left: auto; }
@media (max-width: 1080px) { .header-tools { margin-left: auto; } }
.search-dlg { border: 0; padding: 0; background: transparent; width: 100%; max-width: none; height: 100%; max-height: none; margin: 0; }
.search-dlg::backdrop { background: rgba(30, 32, 34, .55); }
.search-dlg[open] { display: block; }
.search-panel { width: min(720px, calc(100% - 32px)); margin: clamp(16px, 9vh, 96px) auto 0; background: var(--ivory); border: 1px solid var(--line); box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .55); max-height: calc(100vh - clamp(32px, 12vh, 140px)); display: flex; flex-direction: column; }
.search-box { display: flex; align-items: center; gap: 12px; padding: 14px 16px 14px 20px; border-bottom: 1px solid var(--line); color: var(--ink-soft); }
.search-box input { flex: 1; min-width: 0; border: 0; background: transparent; font: 400 1.2rem var(--sans); color: var(--ink); padding: 8px 0; }
.search-box input:focus { outline: none; }
.search-box:focus-within { box-shadow: inset 0 -2px 0 var(--wine); }
.search-x { border: 0; background: none; font-size: 1.8rem; line-height: 1; color: var(--ink-soft); cursor: pointer; padding: 0 6px; }
.search-x:hover { color: var(--wine); }
.search-status { margin: 0; padding: 12px 20px; font-size: .9rem; color: var(--ink-soft); }
.search-res { list-style: none; margin: 0; padding: 0 8px 8px; overflow-y: auto; }
.search-res a { display: grid; grid-template-columns: 64px 1fr; gap: 14px; align-items: start; padding: 10px 12px; color: var(--ink); text-decoration: none; border-radius: 4px; }
.search-res a:hover, .search-res a:focus-visible, .search-res a.on { background: var(--paper); outline: 1px solid var(--line); }
.search-res .th { width: 64px; height: 48px; background: #EFE9DC; overflow: hidden; }
.search-res .th img { width: 100%; height: 100%; object-fit: cover; }
.search-res b { display: block; font-family: var(--serif); font-size: 1.2rem; font-weight: 600; line-height: 1.2; }
.search-res .tag { display: block; margin: 3px 0 4px; }
.search-res .sn { display: block; font-size: .9rem; color: var(--ink-soft); line-height: 1.45; }
.search-res mark { background: #F1DDE0; color: inherit; padding: 0 1px; }
.search-foot { margin: 0; padding: 12px 20px; border-top: 1px solid var(--line); font-size: .92rem; font-weight: 600; }

/* ---------- Index ---------- */
.idx-jump { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 28px; }
.idx-jump a { display: grid; place-items: center; min-width: 40px; height: 40px; padding: 0 8px; border: 1px solid var(--line); background: var(--paper); font: 600 1rem var(--sans); color: var(--green); text-decoration: none; }
.idx-jump a:hover { border-color: var(--wine); color: var(--wine); }
.idx.section { padding: clamp(40px, 6vw, 72px) 0; }
.idx-alpha { columns: 2 340px; column-gap: 56px; }
.idx-group { break-inside: avoid; margin-bottom: 28px; }
.idx-group h3 { font-size: 2rem; color: var(--wine); border-bottom: 1px solid var(--line); padding-bottom: 4px; margin-bottom: 10px; }
.idx ul { list-style: none; margin: 0; padding: 0; }
.idx-group li { margin-bottom: 12px; }
.idx-group li > a { font-weight: 600; font-size: 1.05rem; }
.idx-group .tag { margin-left: 8px; }
.idx-group p { margin: 2px 0 0; font-size: .93rem; color: var(--ink-soft); }
.idx-themes { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 32px; }
.idx-theme h3 { font-size: 1.4rem; margin-bottom: 10px; }
.idx-theme h3 a { color: var(--ink); text-decoration: none; }
.idx-theme h3 a:hover { color: var(--wine); }
.idx-theme li { padding: 5px 0; border-bottom: 1px dashed var(--line); }
.idx-dates { list-style: none; margin: 0; padding: 0; columns: 2 320px; column-gap: 56px; }
.idx-dates li { display: flex; gap: 16px; padding: 8px 0; border-bottom: 1px dashed var(--line); break-inside: avoid; }
.idx-year { flex: 0 0 104px; font-family: var(--serif); font-size: 1.2rem; font-weight: 600; color: var(--wine); }

/* ---------- Facebook ---------- */
.fb { display: inline-flex; align-items: center; gap: 8px; }
.ctb-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; }
.btn-line { display: inline-flex; align-items: center; gap: 8px; }
.contribute .btn-line { background: transparent; color: #fff; border-color: rgba(247, 243, 234, .6); }
.contribute .btn-line:hover { background: var(--ivory); color: var(--green); }
.search-box input::-webkit-search-cancel-button, .search-box input::-webkit-search-decoration { -webkit-appearance: none; appearance: none; }
