/* Feuille generee — variante "editorial" (polices auto-hebergees, licences OFL) */

@font-face { font-family: 'Fraunces'; src: url('/assets/fonts/fraunces-600.woff2') format('woff2'); font-weight: 600; font-style: normal; font-display: swap; }

@font-face { font-family: 'Fraunces'; src: url('/assets/fonts/fraunces-800.woff2') format('woff2'); font-weight: 800; font-style: normal; font-display: swap; }

@font-face { font-family: 'Newsreader'; src: url('/assets/fonts/newsreader-400.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }

@font-face { font-family: 'Newsreader'; src: url('/assets/fonts/newsreader-400i.woff2') format('woff2'); font-weight: 400; font-style: italic; font-display: swap; }

:root {
  --bg: #faf7f2;
  --surface: #ffffff;
  --ink: #1c1a17;
  --muted: #6f6a61;
  --accent: #a2231d;
  --accent-ink: #ffffff;
  --rule: #e2dcd1;
  --footer-bg: #1c1a17;
  --footer-ink: #f5f1e8;
  --radius: 2px;
  --radius-lg: calc(2px + 6px);
  --heading: 'Fraunces', Georgia, serif;
  --body: 'Newsreader', Georgia, serif;
  --ui: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --wrap: 1120px;
  --shadow: 0 1px 2px rgba(10, 15, 30, .05), 0 8px 26px rgba(10, 15, 30, .07);
  --shadow-lg: 0 4px 10px rgba(10, 15, 30, .08), 0 18px 46px rgba(10, 15, 30, .13);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; font-family: var(--body); font-size: 17px; line-height: 1.7; color: var(--ink); background: var(--bg); overflow-x: hidden; }
h1, h2, h3, h4 { font-family: var(--heading); color: var(--ink); line-height: 1.28; letter-spacing: -0.01em; margin: 0; text-wrap: balance; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
::selection { background: var(--accent); color: var(--accent-ink); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

.btn-pill {
  display: inline-block; font-family: var(--ui); font-weight: 700; font-size: 14.5px;
  background: var(--accent); color: var(--accent-ink); padding: 12px 26px; border-radius: 999px;
  box-shadow: var(--shadow); transition: transform .15s, box-shadow .15s, filter .15s;
}
.btn-pill:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); filter: brightness(1.06); }

/* ============ Header ============ */
.site-header { background: var(--surface); border-bottom: 1px solid var(--rule); position: sticky; top: 0; z-index: 50; }
.brand { display: flex; align-items: center; gap: 12px; }
.brand-logo { width: 46px; height: 46px; object-fit: contain; }
.brand-logo-full { height: 84px; width: auto; max-width: 320px; object-fit: contain; }
.brand-text { display: flex; flex-direction: column; gap: 3px; }
.brand-name { font-family: var(--heading); font-weight: 800; letter-spacing: -0.02em; color: var(--ink); }
.brand-tagline { font-family: var(--ui); font-size: 11.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.site-nav { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 22px; }
.site-nav a {
  font-family: var(--ui); font-size: 12.5px; font-weight: 700; color: var(--ink); padding: 6px 0;
  text-transform: uppercase; letter-spacing: 0.12em;
  border-bottom: 2px solid transparent; transition: color .15s, border-color .15s;
}
.site-nav a:hover { color: var(--accent); border-bottom-color: var(--accent); }
.site-nav .nav-cta { background: var(--accent); color: var(--accent-ink); padding: 9px 20px; border-radius: 999px; border-bottom: 0; box-shadow: var(--shadow); }
.site-nav .nav-cta:hover { color: var(--accent-ink); filter: brightness(1.08); }

.header-inner { display: flex; flex-direction: column; align-items: center; gap: 14px; padding: 22px 24px 14px; }
.brand-text { align-items: center; }
.brand-name { font-size: 34px; }
.brand-logo { width: 54px; height: 54px; }


/* ============ Hero banner (presentation du site, PLEINE LARGEUR) ============ */
.hero-banner { position: relative; overflow: hidden; background: var(--footer-bg); width: 100vw; margin-left: calc(50% - 50vw); }
.page-home .site-main { padding-top: 0; }
.page-home .hero-banner { margin-bottom: 56px; }
.hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-overlay { position: absolute; inset: 0; background: linear-gradient(160deg, rgba(8, 10, 18, .78) 0%, rgba(8, 10, 18, .55) 55%, rgba(8, 10, 18, .68) 100%); }
.hero-content { position: relative; z-index: 2; max-width: 880px; margin: 0 auto; padding: 110px 28px 140px; text-align: center; }
.hero-title { color: #fff; font-size: clamp(38px, 5.4vw, 62px); letter-spacing: -0.02em; text-shadow: 0 2px 24px rgba(0,0,0,.35); margin-bottom: 10px; }
.hero-desc { color: rgba(255,255,255,.92); font-size: clamp(17px, 2vw, 20px); line-height: 1.7; margin: 0 auto 38px; max-width: 760px; font-style: italic; }
.hero-cta { max-width: 92%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.hero-curve { position: absolute; bottom: -1px; left: 0; right: 0; z-index: 3; line-height: 0; }
.hero-curve svg { width: 100%; height: 54px; transform: scaleX(-1); }
.hero-curve path { fill: var(--bg); d: path('M0,70 L1440,10 L1440,70 L0,70 Z'); }


/* ============ Sections ============ */
.site-main { padding: 46px 24px 76px; }
.home-section { margin-bottom: 72px; }
.section-head { margin-bottom: 32px; }
.section-heading {
  font-size: 27px; position: relative; display: inline-block; padding-bottom: 14px;
  text-transform: uppercase; letter-spacing: 0.06em; font-size: 21px;
}
.section-heading::after { content: ''; position: absolute; left: 0; bottom: 0; width: 52px; height: 4px; border-radius: 999px; background: var(--accent); }
.section-intro { max-width: 780px; color: var(--muted); font-size: 15.5px; margin: 14px 0 0; font-family: var(--ui); line-height: 1.7; }
.section-more { text-align: center; margin-top: 30px; }

/* ============ Cartes ============ */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; }
.card {
  display: flex; flex-direction: column; background: var(--surface); border-radius: var(--radius-lg);
  overflow: hidden; box-shadow: var(--shadow); border: 1px solid var(--rule);
  transition: transform .2s ease, box-shadow .2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.card-media { display: block; position: relative; aspect-ratio: 3 / 2; overflow: hidden; background: var(--bg); }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.card:hover .card-media img { transform: scale(1.05); }
.card-media .ph { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-family: var(--heading); font-weight: 800; font-size: 60px; color: var(--accent-ink); }
.ph-0 { background: linear-gradient(135deg, var(--accent), color-mix(in srgb, var(--accent) 45%, #14100c)); }
.ph-1 { background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 75%, #2b3a4d), #1d2733); }
.ph-2 { background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 60%, #6d5a2e), #2e2717); }
.ph-3 { background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 70%, #3d5747), #1c2b22); }
.ph-4 { background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 65%, #533a5e), #241a29); }
.ph-5 { background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 55%, #34495e), #161d24); }
.card-chip {
  position: absolute; top: 14px; left: 14px; z-index: 2;
  background: var(--accent); color: var(--accent-ink);
  font-family: var(--ui); font-size: 11.5px; font-weight: 700; letter-spacing: 0.06em;
  padding: 6px 14px; border-radius: 999px; box-shadow: 0 2px 10px rgba(0,0,0,.22);
}
.card-body { display: flex; flex-direction: column; gap: 11px; padding: 20px 22px 18px; flex: 1; }
.card-title { font-size: 19px; line-height: 1.38; }
.card-title a { color: var(--ink); transition: color .15s; }
.card:hover .card-title a { color: var(--accent); }
.card-excerpt {
  margin: 0; font-size: 14.5px; line-height: 1.6; color: var(--muted); font-family: var(--ui);
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.card-meta { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: auto 0 0; padding-top: 10px; border-top: 1px solid var(--rule); font-family: var(--ui); font-size: 12.5px; color: var(--muted); }
.mi { display: inline-flex; align-items: center; gap: 5px; }
.mi svg { color: var(--accent); flex: none; }

/* Blocs editoriaux de presentation (texte unique home) */
.home-textblock {
  margin: 0 0 64px; padding: 34px 40px; background: var(--surface);
  border: 1px solid var(--rule); border-radius: var(--radius-lg); box-shadow: var(--shadow);
  border-top: 4px solid var(--accent);
}
.textblock-title { font-size: 23px; margin-bottom: 14px; }
.textblock-body { color: var(--muted); font-size: 15.5px; line-height: 1.75; font-family: var(--ui); }
.textblock-body p { margin: 0 0 14px; }
.textblock-body p:last-child { margin-bottom: 0; }
.textblock-body a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.textblock-body strong { color: var(--ink); }
@media (min-width: 900px) { .textblock-body.cols { column-count: 2; column-gap: 44px; } }

/* Sections alternees en rangees (rythme editorial) */
.section-rows .cards { grid-template-columns: repeat(2, 1fr); gap: 20px 30px; }
.section-rows .card { flex-direction: row; align-items: stretch; }
.section-rows .card-media { flex: none; width: 200px; aspect-ratio: auto; min-height: 100%; }
.section-rows .card-chip { display: none; }
.section-rows .card-body { padding: 14px 18px; }
.section-rows .card-title { font-size: 17px; }
.section-rows .card-excerpt { -webkit-line-clamp: 2; font-size: 13.5px; }

/* ============ Breadcrumb ============ */
.breadcrumb { font-family: var(--ui); font-size: 13px; color: var(--muted); margin-bottom: 22px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--accent); }

/* ============ Article ============ */
.article { max-width: 760px; margin: 0 auto; }
.article-header .card-chip { position: static; display: inline-block; margin-bottom: 14px; }
.article-title { font-size: clamp(30px, 4.4vw, 44px); margin: 6px 0 14px; }
.article-deck { font-size: 20px; line-height: 1.55; color: var(--muted); margin: 0 0 20px; font-style: italic; }
.article-meta { display: flex; align-items: center; gap: 14px; padding: 16px 0; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); margin-bottom: 30px; font-family: var(--ui); font-size: 13.5px; color: var(--muted); flex-wrap: wrap; }
.avatar { width: 44px; height: 44px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); display: flex; align-items: center; justify-content: center; font-family: var(--heading); font-weight: 800; font-size: 16px; flex: none; }
.byline { display: flex; flex-direction: column; gap: 1px; }
.byline .author { color: var(--ink); font-weight: 700; }
.article-meta .dates { margin-left: auto; text-align: right; display: flex; flex-direction: column; gap: 1px; }
.article-figure { margin: 0 0 30px; aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--radius-lg); background: var(--surface); box-shadow: var(--shadow); }
.article-figure img { width: 100%; height: 100%; object-fit: cover; }

.toc { background: var(--surface); border: 1px solid var(--rule); border-left: 4px solid var(--accent); border-radius: var(--radius-lg); padding: 20px 26px; margin: 0 0 32px; box-shadow: var(--shadow); }
.toc-heading { font-family: var(--ui); font-weight: 700; font-size: 13px; text-transform: uppercase; letter-spacing: 0.12em; margin: 0 0 10px; color: var(--ink); }
.toc ol { margin: 0; padding-left: 20px; font-family: var(--ui); font-size: 14.5px; column-count: 2; column-gap: 34px; }
.toc li { margin: 6px 0; break-inside: avoid; }
.toc a { color: var(--ink); }
.toc a:hover { color: var(--accent); }

.article-content { font-size: 17.5px; }
.article-content > p:first-of-type { font-size: 19px; }

.article-content > p:first-of-type::first-letter { font-family: var(--heading); font-weight: 800; font-size: 3.3em; line-height: .82; float: left; padding: 6px 10px 0 0; color: var(--accent); }

.article-content h2 { font-size: 26px; margin: 42px 0 16px; }
.article-content h3 { font-size: 21px; margin: 32px 0 12px; }
.article-content p { margin: 0 0 20px; }
.article-content a { color: var(--accent); text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--accent) 40%, transparent); text-underline-offset: 3px; }
.article-content strong { color: var(--ink); }
.article-content img { border-radius: var(--radius-lg); margin: 26px auto; box-shadow: var(--shadow); }
.article-content ul, .article-content ol { margin: 0 0 20px; padding-left: 26px; }
.article-content li { margin: 8px 0; }
.article-content li::marker { color: var(--accent); font-weight: 700; }
.article-content blockquote { border-left: 4px solid var(--accent); margin: 26px 0; padding: 12px 26px; background: var(--surface); border-radius: var(--radius); color: var(--muted); font-style: italic; font-size: 18.5px; box-shadow: var(--shadow); }
.article-content table { border-collapse: collapse; width: 100%; margin: 26px 0; font-family: var(--ui); font-size: 15px; }
.article-content th, .article-content td { border: 1px solid var(--rule); padding: 10px 14px; text-align: left; }
.article-content th { background: var(--surface); font-weight: 700; }

.article-footer { margin-top: 44px; }
.author-box { display: flex; gap: 18px; align-items: flex-start; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--radius-lg); padding: 22px 26px; box-shadow: var(--shadow); }
.author-box .avatar { width: 56px; height: 56px; font-size: 20px; }
.author-name { font-family: var(--ui); font-weight: 700; margin: 2px 0 6px; }
.author-bio { margin: 0; font-family: var(--ui); font-size: 14.5px; color: var(--muted); line-height: 1.6; }
.related { margin-top: 64px; }
.category-intro { max-width: 800px; font-size: 17px; color: var(--muted); margin: 14px 0 30px; font-family: var(--ui); }

/* ============ Pagination / pages ============ */
.pagination { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 52px; font-family: var(--ui); font-size: 14.5px; }
.page-current { color: var(--muted); }
.page-link { font-weight: 700; color: var(--accent); border: 1px solid var(--rule); border-radius: 999px; padding: 10px 20px; transition: all .15s; background: var(--surface); box-shadow: var(--shadow); }
.page-link:hover { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.page-content .article-content h2 { font-size: 22px; }

/* ============ Footer ============ */
.site-footer { background: var(--footer-bg); color: var(--footer-ink); margin-top: 40px; }
.footer-inner { padding: 46px 24px 36px; display: grid; grid-template-columns: 1.4fr 1fr; gap: 28px; align-items: start; }
.footer-brand { font-family: var(--heading); font-weight: 800; font-size: 24px; }
.footer-brand::after { content: '.'; color: var(--accent); }
.footer-blurb { font-family: var(--ui); font-size: 13.5px; color: color-mix(in srgb, var(--footer-ink) 65%, transparent); max-width: 400px; margin: 8px 0 0; line-height: 1.6; }
.footer-nav { display: flex; flex-wrap: wrap; gap: 10px 24px; font-family: var(--ui); font-size: 13.5px; justify-content: flex-end; }
.footer-nav a { color: var(--footer-ink); opacity: .82; }
.footer-nav a:hover { opacity: 1; }
.footer-copy { grid-column: 1 / -1; border-top: 1px solid color-mix(in srgb, var(--footer-ink) 18%, transparent); padding-top: 18px; margin: 10px 0 0; font-family: var(--ui); font-size: 12.5px; color: color-mix(in srgb, var(--footer-ink) 55%, transparent); }

/* ============ Responsive ============ */
@media (max-width: 960px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { grid-template-columns: 1fr; }
  .footer-nav { justify-content: flex-start; }
  .toc ol { column-count: 1; }
}
@media (max-width: 600px) {
  body { font-size: 16.5px; }
  .cards { grid-template-columns: 1fr; }
  .site-main { padding: 30px 18px 56px; }
  .hero-content { padding: 64px 20px 88px; }
  .article-title { font-size: 27px; }
  .article-meta .dates { margin-left: 0; text-align: left; }
  .header-inner { gap: 10px; }
}
