/* ============================================================
   AFRICARRIÈRES — Main Stylesheet
   ============================================================ */

/* --- Accessibilité --- */
.afc-skip-link {
  position: absolute;
  top: -100%;
  left: 16px;
  z-index: 9999;
  padding: 10px 20px;
  background: var(--afc-accent);
  color: #fff;
  font-weight: 700;
  border-radius: 0 0 8px 8px;
  text-decoration: none;
  transition: top .15s;
}
.afc-skip-link:focus { top: 0; }

/* Card avec lien couvrant (évite button-in-a) */
.afc-opp-card--linked { cursor: pointer; }
.afc-opp-card__cover-link {
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: inherit;
}
.afc-opp-card--linked:hover { box-shadow: var(--afc-shadow-md); }

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--afc-bg);
  color: var(--afc-text);
  font-family: var(--afc-font-body);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  font-size: 16px;
  line-height: 1.5;
}

img { max-width: 100%; height: auto; display: block; }
button { font-family: inherit; }
a { color: inherit; text-decoration: none; }

/* --- Layout --- */
.afc-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 40px);
}

/* --- Typography --- */
.afc-display {
  font-family: var(--afc-font-display);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.02;
}

/* --- Animations --- */
@keyframes afcPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: .55; transform: scale(0.82); }
}
@keyframes afcFadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ============================================================
   HEADER
   ============================================================ */
.afc-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(247, 244, 239, 0.92);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid #e8e2d8;
}

.afc-header__top {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 0;
}

/* Logos dual light/dark */
.afc-logo { display: block; object-fit: contain; }
.afc-logo--light { width: var(--afc-logo-light-w, 160px); height: var(--afc-logo-light-h, 40px); }
.afc-logo--dark  { display: none; width: var(--afc-logo-dark-w, 160px); height: var(--afc-logo-dark-h, 40px); }
.afc-logo-text   { font-family: var(--afc-font-display); font-weight: 800; font-size: 22px; color: var(--afc-accent); }

.afc-header__logo-btn {
  flex: none;
  display: flex;
  align-items: center;
  gap: 9px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  text-decoration: none;
}

.afc-header__logo {
  height: clamp(28px, 5vw, 34px);
  width: auto;
}

.afc-header__nav-main {
  flex: 1;
  display: flex;
  justify-content: center;
  gap: 4px;
}

.afc-header__actions {
  flex: none;
  display: flex;
  align-items: center;
  gap: 10px;
}

.afc-header__sub-nav {
  border-top: 1px solid #ede7dd;
}

.afc-header__sub-nav .afc-container {
  display: flex;
  justify-content: center;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-top: 0;
  padding-bottom: 0;
}

.afc-header__sub-nav .afc-container::-webkit-scrollbar { display: none; }

/* Nav buttons */
.afc-nav-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  color: var(--afc-text-muted);
  padding: 8px 12px;
  border-radius: 8px;
  transition: background .15s, color .15s;
  white-space: nowrap;
  text-decoration: none;
  display: inline-block;
}
.afc-nav-btn:hover,
.afc-nav-btn.is-active {
  background: #efe9df;
  color: var(--afc-text);
}
.afc-nav-btn--active {
  background: var(--afc-accent-soft);
  color: var(--afc-accent);
}

.afc-sub-nav-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--afc-text-muted);
  padding: 11px 14px;
  border-bottom: 2px solid transparent;
  transition: color .15s, border-color .15s;
  white-space: nowrap;
  text-decoration: none;
  display: inline-block;
}
.afc-sub-nav-btn:hover,
.afc-sub-nav-btn.is-active {
  color: var(--afc-accent);
  border-bottom-color: var(--afc-accent);
}

/* ── Sélecteur d'apparence (Clair / Sombre / Système) ── */
.afc-theme-selector {
  display: flex;
  align-items: center;
  background: var(--afc-surface-2);
  border: 1px solid var(--afc-border);
  border-radius: 10px;
  padding: 3px;
  gap: 2px;
}
.afc-theme-opt {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  border-radius: 7px;
  width: 30px; height: 30px;
  cursor: pointer;
  color: var(--afc-text-muted);
  transition: background .14s, color .14s;
  font-size: 12px; font-weight: 600;
  font-family: inherit;
  flex-shrink: 0;
}
.afc-theme-opt svg { flex-shrink: 0; pointer-events: none; }
.afc-theme-opt:hover { color: var(--afc-text); background: var(--afc-border); }
.afc-theme-opt.is-active {
  background: var(--afc-surface);
  color: var(--afc-text);
  box-shadow: 0 1px 4px rgba(0,0,0,.10);
}
.afc-theme-opt:focus-visible {
  outline: 2px solid var(--afc-accent);
  outline-offset: 1px;
}

/* Version mobile (avec labels) */
.afc-theme-selector--full {
  width: 100%;
  background: var(--afc-surface-2);
  border-radius: 12px;
  padding: 4px;
  gap: 3px;
}
.afc-theme-selector--full .afc-theme-opt {
  flex: 1;
  width: auto;
  height: auto;
  padding: 8px 6px;
  font-size: 12px;
  gap: 5px;
  flex-direction: row;
}
.afc-theme-selector--full .afc-theme-opt.is-active {
  background: var(--afc-surface);
  box-shadow: 0 1px 4px rgba(0,0,0,.12);
}

/* Rétrocompat : ancien bouton toggle */
.afc-darkmode-btn {
  display: none;
}

/* Favs button */
.afc-btn-favs {
  position: relative;
  background: none;
  border: 1px solid var(--afc-border-strong);
  cursor: pointer;
  padding: 8px 11px;
  border-radius: var(--afc-radius-sm);
  display: flex; align-items: center; gap: 6px;
  font-size: 13.5px; font-weight: 600;
  color: var(--afc-text);
  transition: border-color .15s;
  white-space: nowrap;
}
.afc-btn-favs:hover { border-color: var(--afc-accent); }

/* Alert button */
.afc-btn-alert {
  background: var(--afc-accent);
  color: #fff;
  border: none;
  cursor: pointer;
  padding: 9px 15px;
  border-radius: var(--afc-radius-sm);
  font-size: 13.5px; font-weight: 600;
  transition: filter .15s;
  white-space: nowrap;
}
.afc-btn-alert:hover { filter: brightness(1.06); }

/* Hamburger — 3 barres */
.afc-hamburger {
  flex: none;
  width: 42px; height: 42px;
  border-radius: 10px;
  border: 1px solid var(--afc-border-strong);
  background: var(--afc-surface);
  cursor: pointer;
  display: none;
  flex-direction: column;
  align-items: center; justify-content: center;
  gap: 5px;
  color: var(--afc-text);
  transition: border-color .15s, background .15s;
  padding: 0;
}
.afc-hamburger:hover { border-color: var(--afc-accent); }
.afc-hamburger__bar {
  display: block;
  width: 18px; height: 2px;
  background: var(--afc-text);
  border-radius: 2px;
  transition: transform .22s, opacity .22s, background .2s;
}
/* En dark mode, les barres doivent être visibles sur fond sombre */
#page.theme-dark .afc-hamburger {
  background: var(--afc-surface-2);
  border-color: var(--afc-border-strong);
}
#page.theme-dark .afc-hamburger__bar { background: var(--afc-header-text); }

/* Overlay du drawer — voir bloc ci-dessous */

/* Overlay du drawer */
.afc-drawer-overlay {
  display: none;
  position: fixed; inset: 0;
  background: rgba(30,22,14,.50);
  z-index: 998;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}
.afc-drawer-overlay.is-visible { display: block; }
/* Overlay dark — ciblé sur html car position:fixed */
html.afc-dark-init .afc-drawer-overlay { background: rgba(0,0,0,0.68); }

/* ── DRAWER SLIDE-IN ──
   IMPORTANT : position:fixed sort du containing block de #page.
   Les CSS custom properties de #page.theme-dark ne s'héritent PAS
   automatiquement sur les éléments fixed. On utilise html.afc-dark-init
   (posé par le JS sur <html>) pour cibler le dark mode de façon fiable. */
.afc-drawer {
  position: fixed;
  top: 0; left: 0;
  width: min(320px, 90vw);
  height: 100dvh;
  background: #ffffff;          /* fond opaque solide — mode clair */
  z-index: 999;
  display: flex;
  flex-direction: column;
  transform: translateX(-100%);
  transition: transform .28s cubic-bezier(.4,0,.2,1);
  overflow-y: auto;
  overflow-x: hidden;
  box-shadow: 6px 0 40px rgba(30,22,14,.18);
}
.afc-drawer.is-open { transform: translateX(0); }

/* ── Dark mode drawer (via html.afc-dark-init) ── */
html.afc-dark-init .afc-drawer { background: #1e1c18; box-shadow: 6px 0 40px rgba(0,0,0,.45); }
html.afc-dark-init .afc-drawer__head { background: #1e1c18; border-color: #2e2b26; }
html.afc-dark-init .afc-drawer__close { background: #252320; border-color: #3d3830; color: #a89f92; }
html.afc-dark-init .afc-drawer__section { border-color: #2e2b26; }
html.afc-dark-init .afc-drawer__nav li a,
html.afc-dark-init .afc-mobile-menu__item { color: #ede7dc; border-color: #2e2b26; }
html.afc-dark-init .afc-drawer__label { color: #6b6459; }
html.afc-dark-init .afc-drawer__cat { background: #252320; border-color: #2e2b26; color: #ede7dc; }
html.afc-dark-init .afc-drawer__cat:hover { background: #2e1f16; border-color: var(--afc-accent); color: var(--afc-accent); }
html.afc-dark-init .afc-drawer__cat-icon { color: #a89f92; }
html.afc-dark-init .afc-drawer__cat:hover .afc-drawer__cat-icon { color: var(--afc-accent); }
html.afc-dark-init .afc-drawer__foot { background: #131210; border-color: #2e2b26; }
html.afc-dark-init .afc-drawer__appearance .afc-drawer__label { color: #6b6459; }
html.afc-dark-init .afc-theme-selector { background: #252320; border-color: #2e2b26; }
html.afc-dark-init .afc-theme-opt { color: #a89f92; }
html.afc-dark-init .afc-theme-opt:hover { background: #3d3830; color: #ede7dc; }
html.afc-dark-init .afc-theme-opt.is-active { background: #1e1c18; color: #ede7dc; }
/* Back-to-top fixed — même problème */
html.afc-dark-init .afc-back-to-top { background: #1e1c18; border-color: #3d3830; color: #a89f92; }
html.afc-dark-init .afc-back-to-top:hover { background: var(--afc-accent); border-color: var(--afc-accent); color: #fff; }

/* ── Header du drawer ── */
.afc-drawer__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px;
  background: var(--afc-drawer-bg);
  border-bottom: 1px solid var(--afc-border);
  flex-shrink: 0;
  position: sticky;
  top: 0;
  z-index: 2;
}
.afc-drawer__logo { text-decoration: none; }
.afc-drawer__close {
  width: 34px; height: 34px;
  border-radius: 8px;
  border: 1px solid var(--afc-border-strong);
  background: var(--afc-surface-2);
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  color: var(--afc-text-muted);
  transition: background .15s, color .15s;
}
.afc-drawer__close:hover { background: var(--afc-accent-soft); color: var(--afc-accent); }

/* ── Sections ── */
.afc-drawer__section {
  padding: 12px 18px;
  border-bottom: 1px solid var(--afc-border);
}

/* ── Nav links ── */
.afc-drawer__nav {
  list-style: none;
  margin: 0; padding: 0;
  display: flex; flex-direction: column;
}
.afc-drawer__nav li a {
  display: flex;
  align-items: center;
  font-size: 15px; font-weight: 600;
  color: var(--afc-text);
  padding: 12px 2px;
  border-bottom: 1px solid var(--afc-border);
  text-decoration: none;
  transition: color .15s;
}
.afc-drawer__nav li a:hover  { color: var(--afc-accent); }
.afc-drawer__nav li:last-child a { border-bottom: none; }
.afc-mobile-menu__item {
  display: block;
  font-size: 15px; font-weight: 600;
  color: var(--afc-text);
  padding: 12px 2px;
  border-bottom: 1px solid var(--afc-border);
  width: 100%; text-align: left;
  background: none; border-left: none; border-right: none; border-top: none;
  cursor: pointer;
}

/* ── Label section ── */
.afc-drawer__label {
  font-size: 10.5px; font-weight: 800;
  text-transform: uppercase; letter-spacing: .08em;
  color: var(--afc-text-faint);
  margin-bottom: 10px;
  display: block;
}

/* ── Grille catégories (icônes SVG monochromes) ── */
.afc-drawer__cats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.afc-drawer__cat {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 11px 12px;
  border-radius: 12px;
  background: var(--afc-surface-2);
  border: 1.5px solid var(--afc-border);
  font-size: 12.5px; font-weight: 700;
  color: var(--afc-text);
  text-decoration: none;
  transition: border-color .15s, background .15s, color .15s;
  line-height: 1.25;
}
.afc-drawer__cat:hover {
  border-color: var(--afc-accent);
  background: var(--afc-accent-soft);
  color: var(--afc-accent);
}
.afc-drawer__cat-icon {
  width: 20px; height: 20px;
  flex-shrink: 0;
  color: var(--afc-text-muted);
  display: flex; align-items: center; justify-content: center;
}
.afc-drawer__cat-icon svg { width: 18px; height: 18px; }
.afc-drawer__cat:hover .afc-drawer__cat-icon { color: var(--afc-accent); }

/* ── Pied du drawer ── */
.afc-drawer__foot {
  padding: 16px 18px 20px;
  margin-top: auto;
  border-top: 1px solid var(--afc-border);
  background: var(--afc-surface-2);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.afc-drawer__foot .afc-btn-alert {
  border-radius: 12px;
  font-size: 14px;
  width: 100%; padding: 13px;
}
.afc-drawer__appearance {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
/* Ancien darkrow — conservé pour rétrocompat, masqué */
.afc-drawer__darkrow { display: none; }

/* Dark mode overrides for drawer */
/* Drawer dark — voir bloc consolidé en bas */

/* ============================================================
   HERO SECTION
   ============================================================ */
.afc-hero {
  padding: clamp(40px, 6vw, 84px) 0 30px;
}

.afc-hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--afc-accent-soft);
  color: var(--afc-accent);
  font-size: 12.5px; font-weight: 700;
  letter-spacing: 0.04em; text-transform: uppercase;
  padding: 7px 13px;
  border-radius: 100px;
}
.afc-hero__badge-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--afc-accent);
  animation: afcPulse 2s infinite;
}

.afc-hero__title {
  font-family: var(--afc-font-display);
  font-weight: 800;
  font-size: clamp(32px, 5.5vw, 72px);
  line-height: 1.04;
  letter-spacing: -0.03em;
  margin: 20px 0 0;
  max-width: 16ch;
  text-wrap: balance;
}
.afc-hero__title em {
  font-style: normal;
  color: var(--afc-accent);
}

.afc-hero__sub {
  font-size: clamp(15px, 1.8vw, 18px);
  color: var(--afc-text-muted);
  max-width: 58ch;
  margin: 16px 0 0;
  line-height: 1.6;
}

/* Alignement centré */
.afc-hero--center { text-align: center; }
.afc-hero--center .afc-hero__title,
.afc-hero--center .afc-hero__sub   { max-width: none; }
.afc-hero--center .afc-search-bar  { margin-left: auto; margin-right: auto; }
.afc-hero--center .afc-hero__stats { justify-content: center; }
.afc-hero--center .afc-hero__badge { display: inline-flex; }

/* ── Search bar (unified pill) ── */
.afc-search-bar {
  display: flex;
  align-items: center;
  gap: 0;
  margin-top: 30px;
  max-width: 820px;
  background: var(--afc-surface);
  border: 1.5px solid #e4ddd1;
  border-radius: 16px;
  padding: 6px 6px 6px 18px;
  box-shadow: 0 2px 16px rgba(60,40,20,.07);
}
.afc-search-bar__input-wrap {
  flex: 1 1 0;
  display: flex;
  align-items: center;
  gap: 10px;
  background: none;
  border: none;
  padding: 0;
  box-shadow: none;
  min-width: 0;
}
/* Séparateurs entre champs */
.afc-search-bar__sep {
  width: 1px;
  height: 28px;
  background: #e4ddd1;
  flex-shrink: 0;
  margin: 0 6px;
}
.afc-search-bar__input {
  flex: 1; min-width: 0;
  border: none; outline: none;
  background: none;
  font-size: 15.5px;
  padding: 11px 0;
  color: var(--afc-text);
  font-family: inherit;
}
.afc-search-bar__input::placeholder { color: #9a9085; }
.afc-search-bar__input:focus { outline: none; }
.afc-search-bar__select:focus { outline: 2px solid var(--afc-accent); outline-offset: 2px; border-radius: 4px; }
.afc-search-bar__btn {
  background: var(--afc-accent);
  color: #fff;
  border: none; cursor: pointer;
  padding: 13px 22px;
  border-radius: 11px;
  font-size: 15px; font-weight: 700;
  transition: filter .15s, box-shadow .15s;
  white-space: nowrap;
  font-family: inherit;
  flex-shrink: 0;
  display: flex; align-items: center; gap: 7px;
}
.afc-search-bar__btn:hover { filter: brightness(1.08); }
.afc-search-bar__btn:focus-visible { outline: 3px solid var(--afc-focus-ring); outline-offset: 2px; }

.afc-search-bar__select {
  flex: 1 1 140px;
  min-width: 0;
  border: none;
  background: transparent;
  padding: 10px 28px 10px 8px;
  font-size: 14px; font-weight: 600;
  color: var(--afc-text);
  cursor: pointer;
  font-family: inherit;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%239a9085' stroke-width='2.5'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 6px center;
  outline: none;
}

/* Stats */
.afc-hero__stats {
  display: flex;
  gap: 30px;
  margin-top: 34px;
  flex-wrap: wrap;
  align-items: center;
}
.afc-hero__stat-num {
  font-family: var(--afc-font-display);
  font-weight: 700;
  font-size: 28px;
}
.afc-hero__stat-label {
  font-size: 13px;
  color: var(--afc-text-faint);
  font-weight: 500;
}
.afc-hero__stat-sep {
  width: 1px;
  height: 32px;
  background: #e4ddd1;
}

/* ============================================================
   SECTION TITLES
   ============================================================ */
.afc-section-title {
  font-family: var(--afc-font-display);
  font-weight: 700;
  font-size: clamp(24px, 3vw, 34px);
  letter-spacing: -0.02em;
  margin: 0 0 4px;
}
.afc-section-sub {
  color: var(--afc-text-faint);
  margin: 0 0 22px;
  font-size: 15px;
}

/* ============================================================
   URGENT STRIP
   ============================================================ */
.afc-urgent { padding: 20px 0 10px; }

.afc-urgent__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  flex-wrap: wrap;
  gap: 10px;
}
.afc-urgent__title {
  font-family: var(--afc-font-display);
  font-weight: 700;
  font-size: 20px;
  display: flex; align-items: center; gap: 9px;
  color: var(--afc-text);
}
.afc-pulse-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #c0392b;
  animation: afcPulse 1.6s infinite;
  display: inline-block;
  flex-shrink: 0;
}
.afc-btn-link {
  background: none; border: none; cursor: pointer;
  color: var(--afc-accent);
  font-weight: 600; font-size: 14px;
  padding: 0;
  transition: opacity .15s;
  text-decoration: none;
}
.afc-btn-link:hover { opacity: .75; }

/* Scroll horizontal avec snap */
.afc-urgent__scroll {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  padding-bottom: 12px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  scrollbar-color: var(--afc-border) transparent;
}
.afc-urgent__scroll::-webkit-scrollbar { height: 4px; }
.afc-urgent__scroll::-webkit-scrollbar-track { background: transparent; }
.afc-urgent__scroll::-webkit-scrollbar-thumb { background: var(--afc-border); border-radius: 4px; }

.afc-opp-card-mini {
  flex: 0 0 220px;
  scroll-snap-align: start;
  text-align: left;
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: 16px;
  padding: 16px 18px 14px;
  cursor: pointer;
  transition: border-color .18s, box-shadow .18s, transform .15s;
  display: block;
  text-decoration: none;
}
.afc-opp-card-mini:hover {
  border-color: var(--afc-accent);
  box-shadow: 0 4px 20px rgba(60,40,20,.08);
  transform: translateY(-2px);
}
.afc-opp-card-mini__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}
.afc-opp-card-mini__title {
  font-family: var(--afc-font-display);
  font-weight: 700;
  font-size: 15px;
  line-height: 1.3;
  color: var(--afc-text);
  margin-bottom: 6px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.afc-opp-card-mini__meta {
  font-size: 12.5px;
  color: var(--afc-text-faint);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ============================================================
   OPPORTUNITY CARDS
   ============================================================ */
.afc-opp-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(252px, 1fr));
  gap: 14px;
}

.afc-opp-card {
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: 15px;
  padding: 16px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  min-height: 188px;
  transition: border-color .15s, box-shadow .15s;
  text-decoration: none;
  color: inherit;
}
.afc-opp-card:hover {
  border-color: var(--afc-accent);
  box-shadow: var(--afc-shadow-md);
}

.afc-opp-card__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}
.afc-opp-card__top-badges {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  min-width: 0;
}
.afc-opp-card__title {
  font-family: var(--afc-font-display);
  font-weight: 600;
  font-size: 16px;
  line-height: 1.22;
  letter-spacing: -0.01em;
  margin: 11px 0 7px;
}
.afc-opp-card__summary {
  color: #7a7268;
  font-size: 13px;
  line-height: 1.45;
  margin: 0 0 12px;
  flex: 1;
}
.afc-opp-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid #f0ebe2;
  padding-top: 11px;
}
.afc-opp-card__country {
  font-size: 12px;
  color: var(--afc-text-faint);
  font-weight: 600;
}
.afc-opp-card__funding {
  font-size: 12px;
  font-weight: 700;
  color: #4a443c;
}

/* Organisation sous le titre */
.afc-opp-card__org {
  font-size: 12.5px;
  color: var(--afc-text-faint);
  font-weight: 600;
  margin-bottom: 6px;
}

/* ── Variante HORIZONTALE ── */
.afc-opp-card--horizontal {
  flex-direction: row;
  align-items: center;
  gap: 14px;
  min-height: auto;
  padding: 14px;
}
.afc-opp-card--horizontal .afc-opp-card__body { flex: 1; min-width: 0; }
.afc-opp-card--horizontal .afc-opp-card__title { font-size: 15px; margin: 6px 0 4px; }
.afc-opp-card__thumb {
  flex: 0 0 72px; height: 72px;
  border-radius: 10px;
  background-size: cover; background-position: center;
}
.afc-opp-card__thumb-placeholder {
  flex: 0 0 72px; height: 72px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--afc-font-display); font-weight: 800; font-size: 18px;
}

/* ── Variante COMPACTE ── */
.afc-opp-card--compact {
  flex-direction: row;
  align-items: flex-start;
  gap: 12px;
  min-height: auto;
  padding: 12px;
  border-radius: 12px;
}
.afc-opp-card--compact__icon {
  flex: 0 0 48px; height: 48px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--afc-font-display); font-weight: 800; font-size: 12px;
  text-align: center; line-height: 1.2;
}

/* ── Variante FEATURED ── */
.afc-opp-card--featured {
  min-height: auto;
  padding: 0;
  overflow: hidden;
  border-radius: var(--afc-radius-lg);
}
.afc-opp-card--featured__img {
  height: 160px;
  background-size: cover; background-position: center;
  background-color: var(--afc-accent-soft);
  display: flex; align-items: flex-end; padding: 14px;
}
.afc-opp-card--featured__body { padding: 18px; flex: 1; display: flex; flex-direction: column; }

/* Fav button */
.afc-btn-fav {
  background: none; border: none; cursor: pointer;
  padding: 3px; line-height: 0;
  color: var(--afc-accent);
  transition: transform .15s;
}
.afc-btn-fav:hover { transform: scale(1.2); }

/* Type badge */
.afc-badge {
  font-size: 11.5px;
  font-weight: 700;
  padding: 4px 9px;
  border-radius: 6px;
  display: inline-block;
}
.afc-badge--urg {
  font-size: 12px;
  font-weight: 700;
  padding: 4px 9px;
  border-radius: 6px;
  display: inline-block;
}

/* ============================================================
   CARTE PARTENAIRE
   ============================================================ */
.afc-card-partenaire {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: var(--afc-radius);
  padding: 18px;
  text-decoration: none;
  color: inherit;
  transition: border-color .15s, box-shadow .15s;
}
.afc-card-partenaire:hover {
  border-color: var(--afc-accent);
  box-shadow: var(--afc-shadow-md);
}
.afc-card-partenaire__logo {
  flex: 0 0 60px; height: 60px;
  border-radius: 12px;
  border: 1px solid var(--afc-border);
  background: var(--afc-bg);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}
.afc-card-partenaire__logo img { width: 44px; height: 44px; object-fit: contain; }
.afc-card-partenaire__body { flex: 1; min-width: 0; }
.afc-card-partenaire__nom { font-family: var(--afc-font-display); font-weight: 700; font-size: 16px; color: var(--afc-text); }
.afc-card-partenaire__desc { font-size: 13px; color: var(--afc-text-muted); margin-top: 4px; line-height: 1.4; }
.afc-card-partenaire__arrow { color: var(--afc-text-faint); flex-shrink: 0; }

/* ============================================================
   CARTE STATISTIQUE
   ============================================================ */
.afc-card-stat {
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: var(--afc-radius);
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.afc-card-stat__icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 4px;
}
.afc-card-stat__num {
  font-family: var(--afc-font-display);
  font-weight: 800; font-size: 36px;
  letter-spacing: -0.03em; line-height: 1;
}
.afc-card-stat__label { font-size: 14px; color: var(--afc-text-faint); font-weight: 500; }
.afc-card-stat__trend { font-size: 12.5px; font-weight: 700; margin-top: 4px; }
.afc-card-stat__trend.is-up  { color: #2d7a4f; }
.afc-card-stat__trend.is-down { color: #c0392b; }

/* ============================================================
   CARTE TÉMOIGNAGE
   ============================================================ */
.afc-card-temoignage {
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: var(--afc-radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.afc-card-temoignage__quote-icon { color: var(--afc-accent-soft); }
.afc-card-temoignage__stars { display: flex; gap: 2px; }
.afc-card-temoignage__text {
  font-size: 15px; line-height: 1.65;
  color: #4a443c;
  font-style: italic;
  flex: 1;
}
.afc-card-temoignage__opp {
  display: flex; align-items: center; gap: 6px;
  font-size: 12.5px; font-weight: 700;
  color: var(--afc-accent);
  background: var(--afc-accent-soft);
  padding: 6px 10px; border-radius: 7px;
  width: fit-content;
}
.afc-card-temoignage__author { display: flex; align-items: center; gap: 12px; margin-top: 4px; }
.afc-card-temoignage__avatar {
  width: 42px; height: 42px; border-radius: 50%;
  object-fit: cover; flex-shrink: 0;
}
.afc-card-temoignage__avatar-placeholder {
  width: 42px; height: 42px; border-radius: 50%;
  background: var(--afc-accent);
  color: #fff; display: flex; align-items: center; justify-content: center;
  font-family: var(--afc-font-display); font-weight: 700; font-size: 18px;
  flex-shrink: 0;
}
.afc-card-temoignage__nom { font-weight: 700; font-size: 14px; color: var(--afc-text); }
.afc-card-temoignage__pays { font-size: 12.5px; color: var(--afc-text-faint); }

/* ============================================================
   FEATURED SECTION (À la une)
   ============================================================ */
.afc-featured { padding: 34px 0 10px; }

.afc-featured__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 18px;
  align-items: stretch;
}

/* Big featured card */
.afc-feat-card {
  text-align: left;
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: var(--afc-radius-lg);
  overflow: hidden;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  transition: border-color .15s, box-shadow .2s;
  text-decoration: none;
  color: inherit;
}
.afc-feat-card:hover {
  border-color: var(--afc-accent);
  box-shadow: var(--afc-shadow-lg);
}
.afc-feat-card__img {
  height: 200px;
  background: var(--afc-accent-soft);
  position: relative;
  display: flex;
  align-items: flex-end;
  padding: 14px;
  overflow: hidden;
}
/* Image de couverture */
.afc-feat-card__img img {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}
/* Dégradé sombre en bas pour lisibilité du label */
.afc-feat-card__img::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(20,12,4,.55) 0%, transparent 55%);
  pointer-events: none;
}
/* Placeholder hachuré quand pas d'image */
.afc-feat-card__img--no-thumb {
  background: repeating-linear-gradient(
    135deg,
    var(--afc-accent-soft),
    var(--afc-accent-soft) 11px,
    var(--afc-surface) 11px,
    var(--afc-surface) 22px
  );
}
.afc-feat-card__img-label {
  position: relative;
  z-index: 2;
  font-family: var(--afc-font-display);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--afc-accent);
  background: rgba(255,253,250,.92);
  padding: 5px 9px;
  border-radius: 6px;
  font-weight: 700;
  backdrop-filter: blur(4px);
}
.afc-feat-card__body {
  padding: 20px 20px 22px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.afc-feat-card__badges {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 11px;
}
.afc-feat-card__title {
  font-family: var(--afc-font-display);
  font-weight: 700;
  font-size: 24px;
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin: 0 0 10px;
}
.afc-feat-card__summary {
  color: var(--afc-text-muted);
  font-size: 14.5px;
  line-height: 1.5;
  margin: 0 0 16px;
}
.afc-feat-card__footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.afc-feat-card__org {
  font-size: 13px;
  color: var(--afc-text-faint);
  font-weight: 500;
}
.afc-feat-card__funding {
  font-weight: 700;
  font-size: 13.5px;
  color: var(--afc-accent);
}

/* Side featured cards */
.afc-feat-side {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.afc-feat-side-card {
  text-align: left;
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: var(--afc-radius);
  padding: 16px;
  cursor: pointer;
  display: flex;
  gap: 14px;
  align-items: flex-start;
  transition: border-color .15s, box-shadow .2s;
  text-decoration: none;
  color: inherit;
}
.afc-feat-side-card:hover {
  border-color: var(--afc-accent);
  box-shadow: var(--afc-shadow-md);
}
.afc-feat-side-card__icon {
  flex: 0 0 56px;
  height: 56px;
  border-radius: 11px;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--afc-font-display);
  font-weight: 800;
  font-size: 13px;
}
.afc-feat-side-card__body { flex: 1; min-width: 0; }
.afc-feat-side-card__type { font-size: 11.5px; font-weight: 700; }
.afc-feat-side-card__title {
  font-weight: 600;
  font-size: 15.5px;
  line-height: 1.25;
  margin: 5px 0;
  color: var(--afc-text);
}
.afc-feat-side-card__meta { font-size: 12.5px; color: var(--afc-text-faint); }

/* ============================================================
   CATEGORIES GRID
   ============================================================ */
.afc-cats { padding: 40px 0 10px; }

.afc-cats__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 14px;
}

.afc-cat-card {
  text-align: left;
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: 15px;
  padding: 20px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 128px;
  transition: border-color .15s, transform .15s, box-shadow .15s;
  text-decoration: none;
  color: inherit;
}
.afc-cat-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 24px rgba(60,45,30,0.07);
  border-color: var(--color, var(--afc-accent));
}
/* Icône monochrome SVG — fond neutre, icône en couleur thème */
.afc-cat-card__icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  background: var(--afc-surface-2);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  color: var(--afc-text-muted);
  transition: background .15s, color .15s;
}
.afc-cat-card__icon svg { width: 22px; height: 22px; }
.afc-cat-card:hover .afc-cat-card__icon {
  background: var(--afc-accent-soft);
  color: var(--afc-accent);
}
.afc-cat-card__icon-inner { display: none; }
.afc-cat-card__name {
  font-family: var(--afc-font-display);
  font-weight: 600;
  font-size: 16px;
  line-height: 1.2;
  color: var(--afc-text);
}
.afc-cat-card__count { font-size: 12.5px; color: var(--afc-text-muted); margin-top: 4px; }

/* ============================================================
   CATEGORY SECTIONS (accueil)
   ============================================================ */
.afc-cat-section { margin-top: 34px; }
.afc-cat-section__header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid #e8e2d8;
}
.afc-cat-section__title-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
}
/* Icône de section — monochrome SVG, même style que cat-card */
.afc-cat-section__icon {
  width: 42px; height: 42px;
  border-radius: 11px;
  background: var(--afc-surface-2);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  color: var(--afc-accent);
}
.afc-cat-section__icon svg { width: 22px; height: 22px; }
.afc-cat-section__icon-inner { display: none; }
.afc-cat-section__title {
  font-family: var(--afc-font-display);
  font-weight: 700;
  font-size: clamp(21px, 2.6vw, 28px);
  letter-spacing: -0.02em;
}
.afc-cat-section__intro { font-size: 13px; color: #9a9085; margin-top: 2px; }

.afc-btn-outline {
  background: none;
  border: 1px solid var(--afc-border-strong);
  cursor: pointer;
  color: #4a443c;
  font-weight: 600;
  font-size: 13.5px;
  padding: 9px 15px;
  border-radius: var(--afc-radius-sm);
  transition: border-color .15s, color .15s;
  text-decoration: none;
  display: inline-block;
}
.afc-btn-outline:hover {
  border-color: var(--afc-accent);
  color: var(--afc-accent);
}

/* ============================================================
   AD PLACEHOLDER
   ============================================================ */
.afc-ad {
  border: 1.5px dashed #d8cfc0;
  border-radius: 16px;
  background: repeating-linear-gradient(
    135deg,
    #f3eee4, #f3eee4 14px,
    #f7f4ef 14px, #f7f4ef 28px
  );
  min-height: 130px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 6px;
}
.afc-ad__code {
  font-family: ui-monospace, monospace;
  font-size: 12px;
  color: #a89f92;
  letter-spacing: 0.05em;
}
.afc-ad__label { font-size: 13px; color: #9a9085; }

/* ============================================================
   ALERTS BAND
   ============================================================ */
.afc-alerts-band {
  background: var(--afc-accent);
  border-radius: 22px;
  padding: clamp(28px, 4vw, 52px);
  color: #fff;
  display: flex;
  gap: 28px;
  align-items: center;
  flex-wrap: wrap;
  position: relative;
  overflow: hidden;
  margin: 30px 0;
}
.afc-alerts-band::before {
  content: '';
  position: absolute;
  right: -40px; top: -40px;
  width: 220px; height: 220px;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
}
.afc-alerts-band::after {
  content: '';
  position: absolute;
  right: 80px; bottom: -60px;
  width: 160px; height: 160px;
  border-radius: 50%;
  background: rgba(255,255,255,0.05);
}
.afc-alerts-band__content { flex: 1 1 320px; position: relative; z-index: 1; }
.afc-alerts-band__title {
  font-family: var(--afc-font-display);
  font-weight: 700;
  font-size: clamp(22px, 2.8vw, 32px);
  letter-spacing: -0.02em;
  margin-bottom: 10px;
}
.afc-alerts-band__sub {
  font-size: 15px;
  opacity: 0.88;
  line-height: 1.5;
}
.afc-alerts-band__form {
  flex: 1 1 320px;
  position: relative;
  z-index: 1;
}
.afc-alerts-band__input-wrap {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.afc-alerts-band__input {
  width: 100%;
  border: none;
  background: rgba(255,255,255,0.15);
  border-radius: 10px;
  padding: 13px 16px;
  font-size: 15px;
  color: #fff;
  font-family: inherit;
  outline: none;
}
.afc-alerts-band__input::placeholder { color: rgba(255,255,255,.65); }
.afc-alerts-band__input:focus {
  background: rgba(255,255,255,.22);
}
.afc-alerts-band__btn {
  background: #fff;
  color: var(--afc-accent);
  border: none; cursor: pointer;
  padding: 14px 22px;
  border-radius: 10px;
  font-size: 15px; font-weight: 700;
  transition: filter .15s;
  font-family: inherit;
  width: 100%;
}
.afc-alerts-band__btn:hover { filter: brightness(0.97); }

/* ============================================================
   LISTING PAGE
   ============================================================ */
/* ============================================================
   LISTING — LAYOUT 2 COLONNES
   ============================================================ */
.afc-listing { padding: 32px 0 60px; }

/* En-tête */
.afc-listing__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 28px;
}
.afc-listing__page-title {
  font-family: var(--afc-font-display);
  font-weight: 800;
  font-size: clamp(28px, 4vw, 42px);
  letter-spacing: -.03em;
  color: var(--afc-text);
  margin: 0 0 4px;
}
.afc-listing__count {
  font-size: 14px;
  color: var(--afc-text-faint);
  font-weight: 600;
}
.afc-listing__sort {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.afc-listing__sort-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--afc-text-muted);
  white-space: nowrap;
}
.afc-sort-select {
  appearance: none;
  background: var(--afc-surface)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='13' height='13' viewBox='0 0 24 24' fill='none' stroke='%239a9085' stroke-width='2.5'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E")
    no-repeat right 12px center;
  border: 1.5px solid var(--afc-border);
  border-radius: 10px;
  padding: 9px 34px 9px 14px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--afc-text);
  cursor: pointer;
  font-family: inherit;
  outline: none;
  transition: border-color .15s;
}
.afc-sort-select:focus { border-color: var(--afc-accent); }

/* Layout 2 colonnes */
.afc-listing__layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 28px;
  align-items: start;
}

/* ── SIDEBAR FILTRES ── */
.afc-listing__sidebar {
  position: sticky;
  top: 84px;
  background: var(--afc-surface);
  border: 1.5px solid var(--afc-border);
  border-radius: 18px;
  padding: 20px 18px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.afc-filter-group { display: flex; flex-direction: column; gap: 8px; }
.afc-filter-group__label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--afc-text-faint);
}

/* Champ de recherche dans sidebar */
.afc-filter-group__search {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--afc-bg);
  border: 1.5px solid var(--afc-border);
  border-radius: 10px;
  padding: 9px 12px;
}
.afc-filter-search-input {
  border: none;
  background: none;
  outline: none;
  font-size: 14px;
  color: var(--afc-text);
  font-family: inherit;
  width: 100%;
}
.afc-filter-search-input::placeholder { color: var(--afc-text-faint); }

/* Boutons de type */
.afc-type-btns {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.afc-type-btn {
  display: flex;
  align-items: center;
  gap: 7px;
  background: none;
  border: 1.5px solid transparent;
  border-radius: 9px;
  padding: 8px 12px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--afc-text-muted);
  cursor: pointer;
  font-family: inherit;
  text-align: left;
  transition: background .14s, border-color .14s, color .14s;
}
.afc-type-btn:hover {
  background: var(--afc-bg);
  color: var(--afc-text);
}
.afc-type-btn.is-active {
  background: var(--afc-accent-soft);
  border-color: var(--afc-accent);
  color: var(--afc-accent);
}
.afc-type-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  display: inline-block;
  opacity: .85;
}
.afc-type-btn.is-active .afc-type-dot { opacity: 1; }

/* Dropdowns pays / domaine */
.afc-filter-select-wrap {
  position: relative;
}
.afc-filter-dropdown {
  appearance: none;
  width: 100%;
  background: var(--afc-bg)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='13' height='13' viewBox='0 0 24 24' fill='none' stroke='%239a9085' stroke-width='2.5'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E")
    no-repeat right 10px center;
  border: 1.5px solid var(--afc-border);
  border-radius: 10px;
  padding: 9px 32px 9px 12px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--afc-text);
  cursor: pointer;
  font-family: inherit;
  outline: none;
  transition: border-color .15s;
}
.afc-filter-dropdown:focus { border-color: var(--afc-accent); }

/* Checkbox favoris */
.afc-filter-favs-label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--afc-text-muted);
  cursor: pointer;
  padding: 2px 0;
  transition: color .15s;
}
.afc-filter-favs-label:hover { color: var(--afc-text); }
.afc-filter-favs-check { display: none; }
.afc-filter-favs-box {
  width: 20px; height: 20px;
  border: 2px solid var(--afc-border);
  border-radius: 6px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--afc-bg);
  transition: background .14s, border-color .14s;
}
.afc-filter-favs-box svg { display: none; color: #fff; }
.afc-filter-favs-check:checked + .afc-filter-favs-box {
  background: var(--afc-accent);
  border-color: var(--afc-accent);
}
.afc-filter-favs-check:checked + .afc-filter-favs-box svg { display: block; }

/* Lien réinitialiser */
.afc-reset-filters {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--afc-text-faint);
  text-decoration: none;
  padding: 6px 0;
  transition: color .15s;
  display: inline-block;
  border-top: 1px solid var(--afc-border);
  padding-top: 14px;
}
.afc-reset-filters:hover { color: var(--afc-accent); }

/* ── GRILLE RÉSULTATS ── */
.afc-listing__results { min-width: 0; }

.afc-listing__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 16px;
}

/* Slot pub dans la grille — cellule simple comme une carte */
.afc-listing__ad {
  display: flex;
  align-items: stretch;
}
.afc-listing__ad .afc-ad-slot,
.afc-listing__ad .afc-ad--placeholder {
  width: 100%;
  max-width: 300px;
  min-height: 250px;
  margin: 0 auto;
}

/* État vide */
.afc-listing__empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 60px 20px;
  color: var(--afc-text-muted);
}
.afc-listing__empty-icon { font-size: 48px; margin-bottom: 16px; }
.afc-listing__empty h3 {
  font-family: var(--afc-font-display);
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--afc-text);
}

/* ── RESPONSIVE ── */
@media (max-width: 1024px) {
  .afc-listing__layout { grid-template-columns: 210px 1fr; gap: 20px; }
  .afc-type-btn { font-size: 13px; padding: 7px 10px; }
}
@media (max-width: 768px) {
  .afc-listing__layout { grid-template-columns: 1fr; }
  .afc-listing__sidebar {
    position: static;
    border-radius: 14px;
  }
  .afc-type-btns { flex-direction: row; flex-wrap: wrap; }
  .afc-type-btn { flex: 0 0 auto; }
  .afc-listing__grid { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
}
@media (max-width: 480px) {
  .afc-listing__head { gap: 12px; }
  .afc-listing__grid { grid-template-columns: 1fr; }
}

/* Dark mode listing — voir bloc consolidé en bas */

/* Pagination */
.afc-pagination {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: 40px;
  flex-wrap: wrap;
}
.afc-page-btn {
  min-width: 40px; height: 40px;
  border-radius: 10px;
  border: 1px solid var(--afc-border-strong);
  background: var(--afc-surface);
  cursor: pointer;
  font-size: 14px; font-weight: 600;
  color: var(--afc-text-muted);
  padding: 0 12px;
  transition: border-color .15s, color .15s;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.afc-page-btn:hover { border-color: var(--afc-accent); color: var(--afc-accent); }
.afc-page-btn.is-active {
  background: var(--afc-accent);
  border-color: var(--afc-accent);
  color: #fff;
}

/* ============================================================
   DETAIL PAGE
   ============================================================ */
.afc-detail { padding: 28px 0 60px; }

.afc-detail__layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 36px;
  align-items: start;
}

.afc-detail__breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--afc-text-faint);
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.afc-detail__breadcrumb a { color: var(--afc-text-faint); transition: color .15s; }
.afc-detail__breadcrumb a:hover { color: var(--afc-accent); }
.afc-detail__breadcrumb-sep { color: #c2b9ab; }

.afc-detail__badges {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}
.afc-detail__title {
  font-family: var(--afc-font-display);
  font-weight: 700;
  font-size: clamp(26px, 4vw, 46px);
  letter-spacing: -0.025em;
  line-height: 1.06;
  margin-bottom: 18px;
}
.afc-detail__meta-row {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 24px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--afc-border);
}
.afc-detail__meta-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  color: #5a544c;
  font-weight: 600;
}
.afc-detail__meta-item svg { color: var(--afc-text-faint); }

/* Article content */
.afc-detail__content h2 {
  font-family: var(--afc-font-display);
  font-weight: 700;
  font-size: 21px;
  letter-spacing: -0.01em;
  margin: 0 0 12px;
  scroll-margin-top: 130px;
}
.afc-detail__content p {
  font-size: 16px;
  line-height: 1.65;
  color: #4a443c;
  margin: 0 0 18px;
}
.afc-detail__content ul, .afc-detail__content ol { margin: 0 0 18px 24px; }
.afc-detail__content li { font-size: 16px; line-height: 1.6; color: #4a443c; margin-bottom: 6px; }

/* Eligibility checklist */
.afc-checklist { display: flex; flex-direction: column; gap: 10px; margin-bottom: 28px; }
.afc-checklist-item {
  display: flex;
  gap: 11px;
  align-items: flex-start;
}
.afc-checklist-icon {
  flex: 0 0 22px; height: 22px;
  border-radius: 50%;
  background: var(--afc-accent-soft);
  display: flex; align-items: center; justify-content: center;
  margin-top: 1px;
}

/* Steps */
.afc-steps { display: flex; flex-direction: column; gap: 2px; margin-bottom: 28px; }
.afc-step {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 12px 0;
  border-bottom: 1px solid #f0ebe2;
}
.afc-step__num {
  flex: 0 0 28px; height: 28px;
  border-radius: 9px;
  background: var(--afc-text);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--afc-font-display);
  font-weight: 700; font-size: 14px;
}
.afc-step__text {
  font-size: 15px;
  line-height: 1.5;
  color: #4a443c;
  padding-top: 3px;
}

/* Tags */
.afc-tags { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 30px; }
.afc-tag {
  font-size: 12.5px; font-weight: 600;
  color: #6a6258;
  background: #f0ebe2;
  padding: 6px 12px;
  border-radius: 100px;
}

/* CTA box */
.afc-detail__cta-box {
  padding: 24px;
  background: var(--afc-accent-soft);
  border: 1px solid var(--afc-border);
  border-radius: 16px;
  margin-top: 30px;
}
.afc-detail__cta-title {
  font-family: var(--afc-font-display);
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.01em;
  margin: 0 0 4px;
}
.afc-detail__cta-sub {
  font-size: 14px;
  color: var(--afc-text-muted);
  margin: 0 0 16px;
  line-height: 1.5;
}
.afc-detail__cta-btns {
  display: flex;
  gap: 11px;
  flex-wrap: wrap;
}
.afc-btn-primary {
  background: var(--afc-accent-2);
  color: #fff;
  border: none; cursor: pointer;
  padding: 13px 24px;
  border-radius: 11px;
  font-size: 15px; font-weight: 700;
  display: flex; align-items: center; gap: 8px;
  transition: filter .15s;
  text-decoration: none;
  font-family: inherit;
}
.afc-btn-primary:hover { filter: brightness(1.07); }
.afc-btn-secondary {
  background: var(--afc-surface);
  color: var(--afc-text);
  border: 1px solid var(--afc-border-strong);
  cursor: pointer;
  padding: 13px 24px;
  border-radius: 11px;
  font-size: 15px; font-weight: 600;
  display: flex; align-items: center; gap: 8px;
  transition: border-color .15s, color .15s;
  text-decoration: none;
  font-family: inherit;
}
.afc-btn-secondary:hover {
  border-color: var(--afc-accent-2);
  color: var(--afc-accent-2);
}

/* Sidebar */
.afc-detail__sidebar { position: sticky; top: 90px; }

.afc-detail__sticky-box {
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: var(--afc-radius-lg);
  overflow: hidden;
  margin-bottom: 20px;
}
.afc-detail__sticky-header {
  height: 140px;
  background: repeating-linear-gradient(
    135deg,
    var(--afc-accent-soft), var(--afc-accent-soft) 10px,
    #fffdfa 10px, #fffdfa 20px
  );
  display: flex; align-items: center; justify-content: center;
}
.afc-detail__sticky-body { padding: 20px; }

.afc-deadline-box {
  background: linear-gradient(135deg, #fef3cd 0%, #fde8a8 100%);
  border: 1px solid #f5c842;
  border-radius: 12px;
  padding: 15px 18px;
  margin-bottom: 18px;
}
.afc-deadline-box__label {
  font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.06em;
  color: #8a6400; margin-bottom: 6px;
}
.afc-deadline-box__date {
  font-family: var(--afc-font-display);
  font-weight: 700; font-size: 20px; color: #6a4a00;
}
.afc-deadline-box__countdown {
  font-size: 12.5px; font-weight: 600;
  color: #c0392b; margin-top: 4px;
}

.afc-detail__info-list { list-style: none; display: flex; flex-direction: column; gap: 14px; }
.afc-detail__info-item {
  display: flex; align-items: flex-start; gap: 12px;
}
.afc-detail__info-icon {
  flex: 0 0 32px; height: 32px;
  border-radius: 9px;
  background: var(--afc-accent-soft);
  display: flex; align-items: center; justify-content: center;
  color: var(--afc-accent);
}
.afc-detail__info-label {
  font-size: 11.5px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.04em; color: var(--afc-text-faint);
  margin-bottom: 2px;
}
.afc-detail__info-val {
  font-size: 14.5px; font-weight: 600; color: var(--afc-text);
}

/* TOC */
.afc-toc {
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: var(--afc-radius-lg);
  padding: 18px 20px;
}
.afc-toc__title {
  font-size: 11.5px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.05em; color: #3a352f; margin-bottom: 12px;
}
.afc-toc__list { list-style: none; display: flex; flex-direction: column; gap: 2px; counter-reset: toc; }
.afc-toc__item a {
  display: flex; align-items: baseline; gap: 10px;
  text-decoration: none;
  padding: 7px 0;
  color: #4a443c; font-size: 15px; font-weight: 600;
  transition: color .15s;
  border-top: 1px solid #f3eee5;
}
.afc-toc__item:first-child a { border-top: none; }
.afc-toc__item a:hover { color: var(--afc-accent-2); }
.afc-toc__num {
  color: var(--afc-accent-2);
  font-weight: 700; font-size: 13px;
  flex-shrink: 0;
}

/* ============================================================
   FAVORITES PAGE
   ============================================================ */
.afc-favs { padding: 40px 0 60px; }
.afc-favs__empty {
  text-align: center;
  padding: 80px 20px;
}
.afc-favs__empty-icon {
  width: 64px; height: 64px;
  border-radius: 20px;
  background: var(--afc-accent-soft);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 20px;
  color: var(--afc-accent);
}
.afc-favs__empty-title {
  font-family: var(--afc-font-display);
  font-weight: 700; font-size: 22px;
  margin-bottom: 8px;
}
.afc-favs__empty-sub { color: var(--afc-text-faint); font-size: 15px; margin-bottom: 24px; }

/* ============================================================
   ALERT MODAL
   ============================================================ */
.afc-modal-overlay {
  position: fixed; inset: 0;
  background: rgba(30, 25, 20, 0.6);
  z-index: 200;
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
  backdrop-filter: blur(4px);
  animation: afcFadeIn .2s ease;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.afc-modal {
  background: var(--afc-surface);
  border-radius: 22px;
  max-width: 500px; width: 100%;
  padding: 32px;
  position: relative;
  box-shadow: 0 24px 60px rgba(0,0,0,0.18);
  /* Jamais plus haute que l'écran : le contenu scrolle à l'intérieur */
  max-height: calc(100vh - 40px);
  max-height: calc(100dvh - 40px);
  overflow-y: auto;
}
/* La liste des centres d'intérêt scrolle seule au-delà de ~5 rangées :
   le bouton « S'abonner » reste toujours visible */
.afc-modal__cats {
  max-height: 230px;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-right: 4px;
}
@media (max-width: 560px) {
  .afc-modal-overlay { padding: 10px; }
  .afc-modal {
    padding: 22px 18px;
    border-radius: 16px;
    max-height: calc(100vh - 20px);
    max-height: calc(100dvh - 20px);
  }
  .afc-modal__title { font-size: 20px; }
  .afc-modal__sub   { font-size: 14px; margin-bottom: 16px; }
  .afc-modal__cats  { max-height: 190px; }
  .afc-modal__cat-toggle { padding: 7px 11px; font-size: 12.5px; }
}
.afc-modal__close {
  position: absolute; top: 16px; right: 16px;
  background: #f3eee5; border: none;
  border-radius: 50%; width: 34px; height: 34px;
  cursor: pointer; display: flex; align-items: center; justify-content: center;
  color: var(--afc-text-muted); transition: background .15s;
}
.afc-modal__close:hover { background: #ece5da; }
.afc-modal__icon {
  width: 52px; height: 52px;
  border-radius: 16px;
  background: var(--afc-accent-soft);
  display: flex; align-items: center; justify-content: center;
  color: var(--afc-accent);
  margin-bottom: 18px;
}
.afc-modal__title {
  font-family: var(--afc-font-display);
  font-weight: 700; font-size: 24px;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}
.afc-modal__sub {
  color: var(--afc-text-muted); font-size: 15px; line-height: 1.5;
  margin-bottom: 24px;
}
.afc-modal__form { display: flex; flex-direction: column; gap: 12px; }
.afc-modal__input {
  width: 100%;
  border: 1.5px solid var(--afc-border);
  border-radius: 11px;
  padding: 13px 16px;
  font-size: 15px; font-family: inherit;
  color: var(--afc-text);
  background: var(--afc-bg);
  transition: border-color .15s;
  outline: none;
}
.afc-modal__input:focus { border-color: var(--afc-accent); }
.afc-modal__cats-label {
  font-size: 12.5px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.04em;
  color: var(--afc-text-faint);
  margin-bottom: 8px;
}
.afc-modal__cats {
  display: flex; flex-wrap: wrap; gap: 8px;
}
.afc-modal__cat-toggle {
  padding: 8px 14px;
  border-radius: 8px;
  border: 1.5px solid var(--afc-border);
  background: none; cursor: pointer;
  font-size: 13px; font-weight: 600;
  color: var(--afc-text-muted);
  transition: border-color .15s, color .15s, background .15s;
  font-family: inherit;
}
.afc-modal__cat-toggle.is-active,
.afc-modal__cat-toggle:hover {
  border-color: var(--afc-accent);
  color: var(--afc-accent);
  background: var(--afc-accent-soft);
}

/* ============================================================
   FOOTER
   ============================================================ */
/* !important pour résister aux surcharges CSS custom */
#page .afc-footer,
.afc-footer {
  background-color: #2a2521 !important;
  color: rgba(255,255,255,.7) !important;
  padding: 50px 0 28px;
  margin-top: 60px;
}
.afc-footer__grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}
.afc-footer__brand {}
.afc-footer__brand-logo { height: 32px; margin-bottom: 14px; }
.afc-footer__brand-desc {
  font-size: 14px; line-height: 1.6;
  max-width: 28ch;
  margin-bottom: 20px;
}
/* Social footer — défini une seule fois (bloc principal ci-dessous) */
.afc-footer__col-title {
  font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.06em;
  color: rgba(255,255,255,.4); margin-bottom: 16px;
}
.afc-footer__links { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.afc-footer__link {
  font-size: 14px; color: rgba(255,255,255,.65);
  text-decoration: none; transition: color .15s;
}
.afc-footer__link:hover { color: #fff; }
.afc-footer__bottom {
  border-top: 1px solid rgba(255,255,255,.1);
  padding-top: 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
.afc-footer__copy { font-size: 13px; color: rgba(255,255,255,.4); }
.afc-footer__bottom-links {
  display: flex; gap: 20px;
}
.afc-footer__bottom-link {
  font-size: 13px;
  color: rgba(255,255,255,.4);
  text-decoration: none;
  transition: color .15s;
}
.afc-footer__bottom-link:hover { color: rgba(255,255,255,.7); }

/* ============================================================
   RESPONSIVE
   ============================================================ */

/* ── Desktop ── */
@media (min-width: 769px) {
  .afc-hamburger        { display: none !important; }
  .afc-drawer           { display: none !important; }
  .afc-drawer-overlay   { display: none !important; }
}

/* ── Mobile ── */
@media (max-width: 768px) {
  /* Header : logo à gauche, hamburger tout à droite */
  .afc-header__top {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 12px;
  }
  .afc-header__logo-btn  { grid-column: 1; }
  .afc-header__nav-main  { display: none; }
  .afc-header__actions   { display: none; }
  .afc-hamburger {
    grid-column: 2;
    display: flex;
    margin-left: auto;
  }

  /* Sidebar repasse en colonne */
  .afc-detail__layout    { grid-template-columns: 1fr; }
  .afc-detail__sidebar   { position: static; }

  /* Footer */
  .afc-footer__grid      { grid-template-columns: 1fr 1fr; }

  /* Grille cartes */
  .afc-opp-grid          { grid-template-columns: 1fr; }

  /* ── Search bar mobile : carte compacte style Airbnb ── */
  .afc-search-bar {
    flex-direction: column !important;
    gap: 0 !important;
    padding: 0 !important;
    background: var(--afc-surface) !important;
    border: 1.5px solid var(--afc-border) !important;
    border-radius: 18px !important;
    box-shadow: 0 4px 20px rgba(60,40,20,.09) !important;
    overflow: hidden !important;
    margin-top: 20px !important;
  }
  /* Champ texte — première ligne */
  .afc-search-bar__input-wrap {
    background: none !important;
    border: none !important;
    border-bottom: 1px solid var(--afc-border) !important;
    border-radius: 0 !important;
    padding: 0 18px !important;
    height: 52px !important;
    min-height: unset !important;
    box-shadow: none !important;
  }
  /* Séparateurs verticaux → désactivés sur mobile */
  .afc-search-bar__sep { display: none !important; }
  /* Selects — hauteur fixe 48px, sans min-height */
  .afc-search-bar__select {
    width: 100% !important;
    height: 48px !important;
    min-height: 0 !important;
    max-height: 48px !important;
    background-color: transparent !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='13' height='13' viewBox='0 0 24 24' fill='none' stroke='%239a9085' stroke-width='2.5'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 16px center !important;
    border: none !important;
    border-bottom: 1px solid var(--afc-border) !important;
    border-radius: 0 !important;
    padding: 0 44px 0 18px !important;
    font-size: 15px !important;
    font-weight: 500 !important;
    box-shadow: none !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    line-height: 48px !important;
  }
  /* Bouton Explorer — pleine largeur, bien visible */
  .afc-search-bar__btn {
    width: 100% !important;
    justify-content: center !important;
    padding: 0 20px !important;
    height: 52px !important;
    min-height: unset !important;
    border-radius: 0 !important;
    font-size: 15px !important;
    border-top: none !important;
  }

  /* CTA alertes band : empile proprement */
  .afc-alerts-band {
    flex-direction: column;
    padding: 28px 20px;
    border-radius: 16px;
    gap: 20px;
  }
  .afc-alerts-band__content,
  .afc-alerts-band__form  { flex: none; width: 100%; }
  .afc-alerts-band__title { font-size: 22px; }
}

/* ============================================================
   SEARCH BAR — TABLETTE (768px–1024px)
   2 colonnes : [champ texte | catégorie] + [domaine + bouton]
   ============================================================ */
@media (min-width: 769px) and (max-width: 1024px) {
  .afc-search-bar {
    flex-wrap: wrap;
    gap: 0;
    padding: 0;
    background: var(--afc-surface);
    border: 1.5px solid var(--afc-border);
    border-radius: 16px;
    box-shadow: 0 4px 16px rgba(60,40,20,.07);
    overflow: hidden;
    margin-top: 24px;
  }
  /* Champ texte prend 55% */
  .afc-search-bar__input-wrap {
    flex: 1 1 55%;
    background: none;
    border: none;
    border-radius: 0;
    padding: 0 18px;
    height: 52px;
    box-shadow: none;
    border-bottom: 1px solid var(--afc-border);
    border-right: 1px solid var(--afc-border);
  }
  /* Séparateur vertical original → caché, les borders font le travail */
  .afc-search-bar__sep { display: none; }
  /* Catégorie prend 45% sur ligne 1 */
  .afc-search-bar__select:first-of-type {
    flex: 1 1 45%;
    height: 52px;
    background: none;
    border: none;
    border-radius: 0;
    border-bottom: 1px solid var(--afc-border);
    padding: 0 40px 0 18px;
    font-size: 15px;
    font-weight: 500;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='13' height='13' viewBox='0 0 24 24' fill='none' stroke='%239a9085' stroke-width='2.5'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    min-height: unset;
  }
  /* Domaine prend toute la largeur sur ligne 2, moins le bouton */
  .afc-search-bar__select:last-of-type {
    flex: 1 1 60%;
    height: 52px;
    background: none;
    border: none;
    border-radius: 0;
    border-right: 1px solid var(--afc-border);
    padding: 0 40px 0 18px;
    font-size: 15px;
    font-weight: 500;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='13' height='13' viewBox='0 0 24 24' fill='none' stroke='%239a9085' stroke-width='2.5'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    min-height: unset;
  }
  /* Bouton Explorer : 40% de la ligne 2, bien visible */
  .afc-search-bar__btn {
    flex: 0 0 auto;
    min-width: 140px;
    height: 52px;
    padding: 0 24px;
    border-radius: 0;
    font-size: 15px;
    justify-content: center;
  }
}

/* ============================================================
   SEARCH BAR — DARK MODE overrides (mobile + tablette)
   ============================================================ */
html.afc-dark-init .afc-search-bar {
  background: var(--afc-surface);
  border-color: var(--afc-border);
}
html.afc-dark-init .afc-search-bar__input-wrap,
html.afc-dark-init .afc-search-bar__select {
  border-color: var(--afc-border);
  color: var(--afc-text);
}
html.afc-dark-init .afc-search-bar__select option {
  background: var(--afc-surface-2);
  color: var(--afc-text);
}

@media (max-width: 480px) {
  .afc-footer__grid { grid-template-columns: 1fr; }
}

/* ============================================================
   DARK MODE — toutes les couleurs via variables CSS
   ============================================================ */

/* ── Fond global ── */
#page.theme-dark,
#page.theme-dark body { background: var(--afc-bg); color: var(--afc-text); }

/* ── Header ── */
#page.theme-dark .afc-header {
  background: var(--afc-header-bg);
  border-bottom-color: var(--afc-border);
}
#page.theme-dark .afc-header__nav-main { background: transparent; }
#page.theme-dark .afc-header__nav-main a { color: var(--afc-header-text); }
#page.theme-dark .afc-header__nav-main a:hover { color: var(--afc-accent); }
/* État actif : le fond beige clair du mode clair est remplacé par une
   surface sombre + texte accent (sinon texte clair sur pastille claire) */
#page.theme-dark .afc-nav-btn.is-active,
#page.theme-dark .afc-nav-btn:hover {
  background: var(--afc-accent-soft);
  color: var(--afc-accent);
}
#page.theme-dark .afc-darkmode-btn {
  border-color: var(--afc-border-strong);
  background: var(--afc-surface-2);
  color: var(--afc-text);
}
#page.theme-dark .afc-btn-favs { color: var(--afc-header-text); }
#page.theme-dark .afc-hamburger__bar { background: var(--afc-header-text); }

/* ── Logos ── */
.afc-logo--light { display: block; }
.afc-logo--dark  { display: none; }
#page.theme-dark .afc-logo--light { display: none; }
#page.theme-dark .afc-logo--dark  { display: block; }

/* ── Cards ── */
#page.theme-dark .afc-opp-card,
#page.theme-dark .afc-card-partenaire,
#page.theme-dark .afc-card-stat,
#page.theme-dark .afc-card-temoignage,
#page.theme-dark .afc-opp-card-mini {
  background: var(--afc-surface);
  border-color: var(--afc-border);
}
#page.theme-dark .afc-opp-card:hover,
#page.theme-dark .afc-opp-card-mini:hover {
  border-color: var(--afc-border-strong);
  box-shadow: var(--afc-shadow-md);
}
#page.theme-dark .afc-opp-card__meta,
#page.theme-dark .afc-opp-card__org { color: var(--afc-text-muted); }
#page.theme-dark .afc-opp-card__title { color: var(--afc-text); }

/* ── Sections ── */
#page.theme-dark .afc-section--bg,
#page.theme-dark .afc-hero,
#page.theme-dark .afc-urgent { background: var(--afc-surface); }
#page.theme-dark .afc-hero { border-bottom-color: var(--afc-border); }

/* ── Barre de recherche ── */
#page.theme-dark .afc-search-bar {
  background: var(--afc-surface);
  border-color: var(--afc-border);
  box-shadow: var(--afc-shadow-md);
}
#page.theme-dark .afc-search-bar__sep { background: var(--afc-border); }
#page.theme-dark .afc-search-bar__input {
  color: var(--afc-text);
  background: transparent;
}
#page.theme-dark .afc-search-bar__input::placeholder { color: var(--afc-text-faint); }
#page.theme-dark .afc-search-bar__select {
  color: var(--afc-text);
  background-color: transparent;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%236b6459' stroke-width='2.5'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
}
#page.theme-dark .afc-search-bar__select option { background: var(--afc-surface); color: var(--afc-text); }

/* ── Formulaires & inputs ── */
#page.theme-dark input,
#page.theme-dark textarea,
#page.theme-dark select {
  background: var(--afc-input-bg);
  color: var(--afc-text);
  border-color: var(--afc-border);
}
#page.theme-dark input::placeholder,
#page.theme-dark textarea::placeholder { color: var(--afc-text-faint); }
#page.theme-dark input:focus,
#page.theme-dark textarea:focus,
#page.theme-dark select:focus {
  border-color: var(--afc-accent);
  outline: none;
  box-shadow: 0 0 0 3px var(--afc-focus-ring);
}

/* ── Boutons ── */
#page.theme-dark .afc-btn-primary {
  background: var(--afc-accent);
  color: #fff;
}
#page.theme-dark .afc-btn-primary:hover { filter: brightness(1.1); }
#page.theme-dark .afc-btn-secondary {
  background: var(--afc-surface-2);
  border-color: var(--afc-border-strong);
  color: var(--afc-text);
}
#page.theme-dark .afc-btn-alert {
  background: var(--afc-accent);
  color: #fff;
}

/* Drawer mobile — géré via html.afc-dark-init (position:fixed hors flux) */

/* ── Page listing ── */
#page.theme-dark .afc-listing__sidebar {
  background: var(--afc-surface);
  border-color: var(--afc-border);
}
#page.theme-dark .afc-filter-group__search,
#page.theme-dark .afc-filter-dropdown,
#page.theme-dark .afc-sort-select {
  background: var(--afc-input-bg);
  border-color: var(--afc-border);
  color: var(--afc-text);
}
#page.theme-dark .afc-type-btn { color: var(--afc-text); border-color: var(--afc-border); }
#page.theme-dark .afc-type-btn:hover { background: var(--afc-surface-2); }
#page.theme-dark .afc-type-btn.is-active { background: var(--afc-accent-soft); border-color: var(--afc-accent); color: var(--afc-accent); }
#page.theme-dark .afc-listing__head { border-color: var(--afc-border); }
#page.theme-dark .afc-listing__page-title { color: var(--afc-text); }
#page.theme-dark .afc-listing__count { color: var(--afc-text-muted); }

/* ── Page article ── */
#page.theme-dark .afc-detail__sticky-box { background: var(--afc-surface); border-color: var(--afc-border); }
#page.theme-dark .afc-detail__meta { color: var(--afc-text-muted); }
#page.theme-dark .afc-detail__label { color: var(--afc-text-faint); }
#page.theme-dark .afc-detail__value { color: var(--afc-text); }
#page.theme-dark .afc-detail__content { color: var(--afc-text); }
#page.theme-dark .afc-detail__content h2,
#page.theme-dark .afc-detail__content h3 { color: var(--afc-text); }

/* ── Partage ── */
#page.theme-dark .afc-share { border-color: var(--afc-border); }
#page.theme-dark .afc-share__label { color: var(--afc-text-faint); }

/* ── Pagination ── */
#page.theme-dark .afc-page-btn {
  background: var(--afc-surface);
  border-color: var(--afc-border);
  color: var(--afc-text);
}
#page.theme-dark .afc-page-btn:hover { background: var(--afc-surface-2); }
#page.theme-dark .afc-page-btn--active {
  background: var(--afc-accent);
  border-color: var(--afc-accent);
  color: #fff;
}

/* ── Footer ── */
#page.theme-dark .afc-footer,
.afc-footer {
  background-color: #0d0c0a !important;
}
#page.theme-dark .afc-footer__brand-desc,
#page.theme-dark .afc-footer__link,
#page.theme-dark .afc-footer__copy { color: rgba(237,231,220,.55); }
#page.theme-dark .afc-footer__link:hover { color: var(--afc-accent); }
#page.theme-dark .afc-footer__col-title { color: rgba(237,231,220,.85); }
#page.theme-dark .afc-footer__social-btn {
  background: rgba(255,255,255,.1);
  border-color: rgba(255,255,255,.22);
  color: rgba(237,231,220,.9);
}
#page.theme-dark .afc-footer__social-btn:hover {
  background: var(--afc-accent);
  border-color: var(--afc-accent);
  color: #fff;
}

/* ── Modal ── */
#page.theme-dark .afc-modal {
  background: var(--afc-surface);
  border-color: var(--afc-border);
}
#page.theme-dark .afc-modal__overlay { background: var(--afc-overlay); }
#page.theme-dark .afc-modal__close {
  background: var(--afc-modal-close-bg);
  color: var(--afc-text);
  border-color: var(--afc-border);
}
#page.theme-dark .afc-modal__title { color: var(--afc-text); }
#page.theme-dark .afc-modal__desc { color: var(--afc-text-muted); }

/* ── Section "À la une" ── */
#page.theme-dark .afc-featured__head { border-color: var(--afc-border); }
#page.theme-dark .afc-featured__title { color: var(--afc-text); }

/* ── Publicité placeholder (dark) ── */
#page.theme-dark .afc-ad--placeholder {
  border-color: var(--afc-border-strong);
  background: repeating-linear-gradient(
    135deg, var(--afc-surface-2), var(--afc-surface-2) 13px, var(--afc-surface) 13px, var(--afc-surface) 26px
  );
}

/* ── Scrollbar ── */
#page.theme-dark { scrollbar-color: var(--afc-scrollbar) var(--afc-bg); }
#page.theme-dark ::-webkit-scrollbar-track { background: var(--afc-bg); }
#page.theme-dark ::-webkit-scrollbar-thumb { background: var(--afc-scrollbar); border-radius: 4px; }

/* ── Badges urgence / type ── */
#page.theme-dark .afc-badge { opacity: .92; }

/* ── Related posts ── */
#page.theme-dark .afc-related { background: var(--afc-surface); border-color: var(--afc-border); }
#page.theme-dark .afc-related-card { background: var(--afc-bg); border-color: var(--afc-border); }
#page.theme-dark .afc-related-card:hover { border-color: var(--afc-accent); }

/* ── Cartes catégories dark mode ── */
#page.theme-dark .afc-cat-card { background: var(--afc-surface); border-color: var(--afc-border); }
#page.theme-dark .afc-cat-card:hover { box-shadow: 0 10px 24px rgba(0,0,0,.3); }
#page.theme-dark .afc-cat-card__icon { background: var(--afc-surface-2); color: var(--afc-text-muted); }
#page.theme-dark .afc-cat-card:hover .afc-cat-card__icon { background: var(--afc-accent-soft); color: var(--afc-accent); }
#page.theme-dark .afc-cat-card__name { color: var(--afc-text); }
#page.theme-dark .afc-cat-card__count { color: var(--afc-text-faint); }
#page.theme-dark .afc-cat-section__header { border-color: var(--afc-border); }
#page.theme-dark .afc-cat-section__icon { background: var(--afc-surface-2); color: var(--afc-accent); }

/* ============================================================
   BOUTON RETOUR VERS LE HAUT
   ============================================================ */
.afc-back-to-top {
  position: fixed;
  bottom: 28px;
  right: 24px;
  z-index: 90;
  width: 42px; height: 42px;
  border-radius: 12px;
  border: 1.5px solid var(--afc-border-strong);
  background: var(--afc-surface);
  color: var(--afc-text);
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--afc-shadow-md);
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .25s ease, transform .25s ease, background .15s, border-color .15s;
  pointer-events: none;
}
.afc-back-to-top.is-visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.afc-back-to-top:hover {
  background: var(--afc-accent);
  border-color: var(--afc-accent);
  color: #fff;
}
.afc-back-to-top:focus-visible {
  outline: 2px solid var(--afc-accent);
  outline-offset: 2px;
}
@media (max-width: 480px) {
  .afc-back-to-top { bottom: 16px; right: 14px; }
}

/* Sélecteur thème dark overrides */
#page.theme-dark .afc-theme-selector {
  background: var(--afc-surface-2);
  border-color: var(--afc-border);
}
#page.theme-dark .afc-theme-opt {
  color: var(--afc-text-muted);
}
#page.theme-dark .afc-theme-opt:hover {
  color: var(--afc-text);
  background: var(--afc-border-strong);
}
#page.theme-dark .afc-theme-opt.is-active {
  background: var(--afc-surface);
  color: var(--afc-text);
}

/* Back-to-top dark mode */
#page.theme-dark .afc-back-to-top {
  background: var(--afc-surface);
  border-color: var(--afc-border-strong);
  color: var(--afc-text-muted);
}
#page.theme-dark .afc-back-to-top:hover {
  background: var(--afc-accent);
  border-color: var(--afc-accent);
  color: #fff;
}

/* ============================================================
   PUBLICITÉS — emplacements
   ============================================================ */
.afc-ad-slot {
  width: 100%;
  overflow: hidden;
  text-align: center;
}

/* Espace vertical autour de chaque pub */
.afc-ad-slot--home_banner,
.afc-ad-slot--home_mid,
.afc-ad-slot--listing_top { margin: 28px 0; }

.afc-ad-slot--article_top,
.afc-ad-slot--article_mid,
.afc-ad-slot--article_bottom { margin: 24px 0; }

.afc-ad-slot--sidebar_top { margin-bottom: 20px; }
.afc-ad-slot--sidebar_sticky { margin-top: 20px; }

/* Centrage AdSense ins */
.afc-ad-slot ins.adsbygoogle { display: block; margin: 0 auto; }

/* Dark mode search & header — voir bloc consolidé */

/* ── Placeholder visible uniquement pour les admins ── */
.afc-ad--placeholder {
  border: 2px dashed #d8cfc0;
  border-radius: 12px;
  background: repeating-linear-gradient(
    135deg, #f3eee4, #f3eee4 13px, #f7f4ef 13px, #f7f4ef 26px
  );
  min-height: 90px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px;
  margin: 20px 0;
}
.afc-ad__code {
  font-family: ui-monospace, monospace;
  font-size: 11.5px;
  color: #a89f92;
  letter-spacing: 0.05em;
}
.afc-ad__configure {
  font-size: 12px;
  font-weight: 700;
  color: var(--afc-accent);
  background: var(--afc-accent-soft);
  padding: 5px 12px;
  border-radius: 6px;
  text-decoration: none;
  transition: filter .15s;
}
.afc-ad__configure:hover { filter: brightness(.95); }

/* ============================================================
   WORDPRESS SPECIFIC
   ============================================================ */
.alignwide { max-width: 1200px; margin-left: auto; margin-right: auto; }
.alignfull { width: 100%; }

/* Screen reader text */
.screen-reader-text {
  border: 0; clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%); height: 1px; margin: -1px; overflow: hidden;
  padding: 0; position: absolute; width: 1px; word-wrap: normal !important;
}

/* ============================================================
   PARTAGE RÉSEAUX SOCIAUX (sidebar article)
   ============================================================ */
.afc-share {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--afc-border);
}
.afc-share__label {
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--afc-text-faint);
  margin-bottom: 10px;
}
.afc-share__btns {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.afc-share__btn {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--share-color, #555);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: filter .15s, transform .15s;
  flex-shrink: 0;
}
.afc-share__btn:hover {
  filter: brightness(1.12);
  transform: translateY(-2px);
}
.afc-share__btn--twitter { background: #000; }
.afc-share__btn.js-copy-link { background: var(--afc-surface-2, #e8e2d8); color: var(--afc-text-muted); }
.afc-share__btn.js-copy-link.is-copied { background: #22c55e; color: #fff; }

/* ============================================================
   FOOTER SOCIAL ICONS
   Spécificité renforcée pour écraser le CSS additionnel WP
   ============================================================ */
.afc-footer .afc-footer__social,
#page .afc-footer__social {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 8px !important;
  margin-top: 16px !important;
  width: auto !important;
  height: auto !important;
  border-radius: 0 !important;
  background: none !important;
  border: none !important;
  padding: 0 !important;
  color: inherit !important;
  text-decoration: none !important;
}
.afc-footer .afc-footer__social-btn,
#page .afc-footer__social-btn {
  width: 38px !important;
  height: 38px !important;
  border-radius: 50% !important;
  border: 1.5px solid rgba(255,255,255,.28) !important;
  background: rgba(255,255,255,.1) !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  color: #fff !important;
  text-decoration: none !important;
  flex-shrink: 0 !important;
  line-height: 0 !important;
  box-sizing: border-box !important;
  transition: border-color .18s, background .18s;
}
.afc-footer .afc-footer__social-btn:hover,
#page .afc-footer__social-btn:hover {
  border-color: rgba(255,255,255,.7) !important;
  background: rgba(255,255,255,.2) !important;
  color: #fff !important;
}
.afc-footer .afc-footer__social-btn svg,
#page .afc-footer__social-btn svg {
  display: block !important;
  flex-shrink: 0 !important;
  pointer-events: none !important;
  fill: currentColor;
}

/* ============================================================
   SECTION "À DÉCOUVRIR ÉGALEMENT" (single article)
   ============================================================ */
.afc-related {
  margin-top: 56px;
  padding-top: 40px;
  border-top: 1px solid var(--afc-border);
}

.afc-related__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 28px;
}
.afc-related__title {
  font-family: var(--afc-font-display);
  font-weight: 800;
  font-size: clamp(20px, 2.6vw, 26px);
  letter-spacing: -0.02em;
  color: var(--afc-text);
  margin: 0 0 4px;
}
.afc-related__sub {
  font-size: 14px;
  color: var(--afc-text-faint);
  margin: 0;
}

/* ── Liste des lignes ── */
.afc-related__list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.afc-related-row {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: 16px;
  padding: 18px 20px;
  text-decoration: none;
  color: inherit;
  transition: border-color .18s, box-shadow .18s, transform .18s;
}
.afc-related-row:hover {
  border-color: var(--afc-accent);
  box-shadow: 0 4px 20px rgba(60,40,20,.07);
  transform: translateY(-1px);
}

/* Badge J-XX */
.afc-related-row__badge {
  flex-shrink: 0;
  width: 54px;
  height: 54px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--afc-font-display);
  font-weight: 800;
  font-size: 12px;
  text-align: center;
  line-height: 1.2;
  letter-spacing: -.02em;
}

/* Contenu principal */
.afc-related-row__body {
  flex: 1;
  min-width: 0;
}
.afc-related-row__type {
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
  display: block;
  margin-bottom: 4px;
}
.afc-related-row__title {
  font-family: var(--afc-font-display);
  font-weight: 700;
  font-size: 16px;
  color: var(--afc-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.afc-related-row__meta {
  font-size: 12.5px;
  color: var(--afc-text-faint);
  margin-top: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Droite */
.afc-related-row__right {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 14px;
}
.afc-related-row__info {
  font-size: 13px;
  font-weight: 600;
  color: var(--afc-text-muted);
  white-space: nowrap;
}
.afc-related-row__arrow {
  color: var(--afc-text-faint);
  flex-shrink: 0;
  transition: transform .18s;
}
.afc-related-row:hover .afc-related-row__arrow {
  transform: translateX(3px);
  color: var(--afc-accent);
}

/* Mobile */
@media (max-width: 600px) {
  .afc-related-row {
    flex-wrap: wrap;
    padding: 14px 16px;
    gap: 12px;
  }
  .afc-related-row__right  { display: none; }
  .afc-related-row__title  { white-space: normal; font-size: 15px; }
  .afc-related-row__badge  { width: 46px; height: 46px; font-size: 11px; }
}

/* Dark mode */
#page.theme-dark .afc-related-row {
  background: var(--afc-surface);
  border-color: var(--afc-border);
}
#page.theme-dark .afc-related-row:hover {
  border-color: var(--afc-accent);
  box-shadow: 0 4px 24px rgba(0,0,0,.4);
}

/* search bar mobile — régi uniquement par le bloc @media (max-width: 768px) principal ci-dessus */

/* ============================================================
   BOTTOM NAVIGATION MOBILE
   Visible uniquement ≤ 899px — style LinkedIn / Airbnb / Instagram
   ============================================================ */

/* Masquée sur desktop */
.afc-bottom-nav { display: none; }

@media (max-width: 899px) {

  /* ── Décale le contenu pour éviter le chevauchement ── */
  body {
    padding-bottom: calc(66px + env(safe-area-inset-bottom, 0px));
  }

  /* ── La barre elle-même ── */
  .afc-bottom-nav {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 110;
    /* Fond translucide + blur — style Airbnb/Instagram */
    background: rgba(255, 253, 250, 0.90);
    backdrop-filter: blur(16px) saturate(1.6);
    -webkit-backdrop-filter: blur(16px) saturate(1.6);
    border-top: 1px solid rgba(60, 40, 20, .08);
    box-shadow: 0 -2px 20px rgba(60, 40, 20, .07);
    border-radius: 14px 14px 0 0;
    /* Safe area iOS (encoche / Dynamic Island) */
    padding-bottom: env(safe-area-inset-bottom, 0px);
    height: calc(66px + env(safe-area-inset-bottom, 0px));
    align-items: flex-start;
  }

  /* ── Chaque onglet ── */
  .afc-bottom-nav__item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    height: 66px;
    min-width: 44px;   /* WCAG — zone tactile minimale */
    padding: 10px 2px 8px;
    border: none;
    background: none;
    cursor: pointer;
    color: var(--afc-text-muted);
    text-decoration: none;
    font-family: inherit;
    position: relative;
    transition: color .18s ease;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    user-select: none;
  }

  /* Focus clavier visible */
  .afc-bottom-nav__item:focus-visible {
    outline: 2px solid var(--afc-accent);
    outline-offset: -3px;
    border-radius: 10px;
  }

  /* ── Onglet actif ── */
  .afc-bottom-nav__item.is-active {
    color: var(--afc-accent);
  }

  /* Indicateur trait en haut */
  .afc-bottom-nav__item.is-active::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 28px;
    height: 3px;
    background: var(--afc-accent);
    border-radius: 0 0 4px 4px;
    animation: afc-bn-slide-in .2s ease;
  }

  @keyframes afc-bn-slide-in {
    from { width: 0; opacity: 0; }
    to   { width: 28px; opacity: 1; }
  }

  /* ── Icône ── */
  .afc-bottom-nav__icon {
    width: 26px;
    height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    flex-shrink: 0;
    transition: transform .15s ease;
  }
  .afc-bottom-nav__item.is-active .afc-bottom-nav__icon {
    transform: translateY(-1px);
  }

  /* ── Libellé ── */
  .afc-bottom-nav__label {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: .01em;
    line-height: 1;
    white-space: nowrap;
    transition: font-weight .15s;
  }

  /* ── Badge favoris ── */
  .afc-bottom-nav__badge {
    position: absolute;
    top: -5px;
    right: -9px;
    background: var(--afc-accent);
    color: #fff;
    font-size: 9px;
    font-weight: 800;
    min-width: 17px;
    height: 17px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    line-height: 1;
    border: 2px solid rgba(255, 253, 250, 0.9);
    box-sizing: border-box;
  }

  /* ── Bouton Menu : toggle icônes hamburger ↔ croix ── */
  .afc-bn-icon-close { display: none; }
  #afc-bn-menu.is-active .afc-bn-icon-open  { display: none; }
  #afc-bn-menu.is-active .afc-bn-icon-close { display: block; }

  /* ── Dark mode (html.afc-dark-init — position:fixed sort du #page) ── */
  html.afc-dark-init .afc-bottom-nav {
    background: rgba(19, 18, 16, 0.92);
    border-top-color: rgba(255, 255, 255, .08);
    box-shadow: 0 -2px 20px rgba(0, 0, 0, .35);
  }
  html.afc-dark-init .afc-bottom-nav__badge {
    border-color: #131210;
  }
  html.afc-dark-init .afc-bottom-nav__item {
    color: var(--afc-text-muted);
  }
  html.afc-dark-init .afc-bottom-nav__item.is-active {
    color: var(--afc-accent);
  }
}

/* ── Ajustement : back-to-top remonte au-dessus de la bottom nav ── */
@media (max-width: 899px) {
  .afc-back-to-top {
    bottom: calc(82px + env(safe-area-inset-bottom, 0px));
  }
}

/* ============================================================
   PAGES ÉDITORIALES
   ============================================================ */

/* ── Hero band ── */
.afc-editorial-hero {
  background: var(--afc-surface-2);
  border-bottom: 1px solid var(--afc-border);
  padding: clamp(48px, 7vw, 88px) 0 clamp(36px, 5vw, 64px);
}
.afc-editorial-hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--afc-accent);
  margin-bottom: 14px;
}
.afc-editorial-hero__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--afc-accent);
  flex-shrink: 0;
}
.afc-editorial-hero__title {
  font-family: var(--afc-font-display);
  font-weight: 800;
  font-size: clamp(28px, 4.5vw, 52px);
  letter-spacing: -.025em;
  color: var(--afc-text);
  margin: 0 0 16px;
  max-width: 720px;
  line-height: 1.12;
}
.afc-editorial-hero__sub {
  font-size: clamp(15px, 2vw, 18px);
  color: var(--afc-text-muted);
  line-height: 1.6;
  max-width: 600px;
  margin: 0;
}

/* ── Corps de page ── */
.afc-editorial-page { background: var(--afc-bg); }
.afc-editorial-body { padding: clamp(32px, 5vw, 64px) 0 80px; }
.afc-editorial-h2 {
  font-family: var(--afc-font-display);
  font-weight: 700;
  font-size: clamp(20px, 2.5vw, 28px);
  letter-spacing: -.02em;
  color: var(--afc-text);
  margin: 0 0 20px;
}

/* ── À propos — mission + stats ── */
.afc-about-mission {
  display: flex;
  gap: 36px;
  flex-wrap: wrap;
  align-items: flex-start;
}
.afc-about-mission__text {
  flex: 1 1 360px;
}
.afc-about-mission__text h2 { margin-top: 0; }
.afc-about-mission__text p {
  font-size: 16px;
  line-height: 1.7;
  color: var(--afc-text-muted);
  margin: 0 0 14px;
}
.afc-about-stats {
  flex: 0 0 260px;
  min-width: 220px;
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: 18px;
  padding: 26px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}
.afc-about-stats__item { display: flex; align-items: baseline; gap: 14px; }
.afc-about-stats__num {
  font-family: var(--afc-font-display);
  font-weight: 700;
  font-size: 32px;
  color: var(--afc-accent);
  min-width: 80px;
}
.afc-about-stats__label { font-size: 13.5px; color: var(--afc-text-muted); line-height: 1.4; }

/* ── Piliers ── */
.afc-about-pillars {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}
.afc-about-pillar {
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: 16px;
  padding: 22px;
}
.afc-about-pillar__icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: var(--afc-accent-soft);
  color: var(--afc-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
}
.afc-about-pillar__title {
  font-family: var(--afc-font-display);
  font-weight: 600;
  font-size: 17px;
  margin: 0 0 7px;
  color: var(--afc-text);
}
.afc-about-pillar__body { font-size: 13.5px; color: var(--afc-text-muted); line-height: 1.55; margin: 0; }

/* ── Ressources ── */
.afc-resources-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(272px, 1fr));
  gap: 16px;
}
.afc-resource-card {
  text-decoration: none;
  color: inherit;
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: 16px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  transition: box-shadow .18s ease, transform .18s ease;
}
.afc-resource-card:hover { box-shadow: var(--afc-shadow-md); transform: translateY(-2px); }
.afc-resource-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.afc-resource-card__icon {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.afc-resource-card__tag {
  font-size: 11px;
  font-weight: 700;
  padding: 4px 9px;
  border-radius: 7px;
}
.afc-resource-card__title {
  font-family: var(--afc-font-display);
  font-weight: 600;
  font-size: 16px;
  line-height: 1.25;
  letter-spacing: -.01em;
  margin: 0 0 8px;
  color: var(--afc-text);
}
.afc-resource-card__body {
  font-size: 13.5px;
  color: var(--afc-text-muted);
  line-height: 1.5;
  margin: 0 0 16px;
  flex: 1;
}
.afc-resource-card__cta { font-size: 13px; font-weight: 600; color: var(--afc-accent); }

/* ── FAQ ── */
.afc-faq { max-width: 760px; margin: 0 auto; }
.afc-faq__item { border-bottom: 1px solid var(--afc-border); }
.afc-faq__btn {
  width: 100%;
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 20px 4px;
  text-align: left;
  font-family: var(--afc-font-body);
}
.afc-faq__question {
  font-family: var(--afc-font-display);
  font-weight: 600;
  font-size: 17px;
  letter-spacing: -.01em;
  color: var(--afc-text);
}
.afc-faq__icon {
  flex: 0 0 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--afc-surface-2);
  color: var(--afc-text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .18s, color .18s, transform .2s;
}
.afc-faq__btn.is-open .afc-faq__icon {
  background: var(--afc-accent);
  color: #fff;
  transform: rotate(45deg);
}
.afc-faq__answer {
  font-size: 15px;
  line-height: 1.7;
  color: var(--afc-text-muted);
  padding: 0 4px 22px;
  margin: 0;
}
.afc-faq__answer p { margin: 0; }

/* ── FAQ — blocs wp:details stylés en accordéon ── */
.afc-faq details.wp-block-details,
.afc-faq .wp-block-details {
  border-bottom: 1px solid var(--afc-border);
  margin: 0;
}
.afc-faq details.wp-block-details > summary,
.afc-faq .wp-block-details > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 20px 4px;
  font-family: var(--afc-font-display);
  font-weight: 600;
  font-size: 17px;
  letter-spacing: -.01em;
  color: var(--afc-text);
  cursor: pointer;
  list-style: none;
}
.afc-faq details.wp-block-details > summary::-webkit-details-marker,
.afc-faq .wp-block-details > summary::-webkit-details-marker { display: none; }
.afc-faq details.wp-block-details > summary::after,
.afc-faq .wp-block-details > summary::after {
  content: '';
  flex: 0 0 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--afc-surface-2);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%236a6258' stroke-width='2.4'%3E%3Cpath d='M12 5v14M5 12h14'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  transition: background-color .18s, transform .2s;
}
.afc-faq details.wp-block-details[open] > summary::after,
.afc-faq .wp-block-details[open] > summary::after {
  background-color: var(--afc-accent);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2.4'%3E%3Cpath d='M12 5v14M5 12h14'/%3E%3C/svg%3E");
  transform: rotate(45deg);
}
.afc-faq details.wp-block-details > p,
.afc-faq details.wp-block-details > .wp-block-paragraph,
.afc-faq .wp-block-details > p,
.afc-faq .wp-block-details > .wp-block-paragraph {
  font-size: 15px;
  line-height: 1.7;
  color: var(--afc-text-muted);
  padding: 0 4px 22px;
  margin: 0;
}

/* ── Légal — numérotation auto des H2 via CSS counter ── */
.afc-legal-content { counter-reset: legal-section; }
.afc-legal-content h2 {
  counter-increment: legal-section;
  display: flex;
  align-items: baseline;
  gap: 14px;
  font-family: var(--afc-font-display);
  font-size: clamp(18px, 2.2vw, 22px);
  font-weight: 700;
  letter-spacing: -.02em;
  color: var(--afc-text);
  margin: 40px 0 14px;
  scroll-margin-top: 90px;
}
.afc-legal-content h2::before {
  content: counter(legal-section, decimal-leading-zero);
  font-size: 13px;
  font-weight: 700;
  color: var(--afc-accent);
  flex-shrink: 0;
}
.afc-legal-content p {
  font-size: 15.5px;
  line-height: 1.75;
  color: var(--afc-text-muted);
  margin: 0 0 12px;
}

/* ── À propos — statistiques pleine largeur ── */
.afc-about-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 18px 32px;
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: var(--afc-radius);
  padding: 28px 32px;
  margin-bottom: 36px;
}
.afc-about-content .afc-about-pillars { margin-top: 8px; }

/* ── Contact ── */
.afc-contact-wrap {
  display: flex;
  gap: 26px;
  flex-wrap: wrap;
  align-items: flex-start;
}
.afc-contact-form-card {
  flex: 1 1 380px;
  min-width: 280px;
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: 18px;
  padding: clamp(22px, 3vw, 32px);
}
.afc-contact-form-card__title {
  font-family: var(--afc-font-display);
  font-weight: 700;
  font-size: 22px;
  letter-spacing: -.01em;
  margin: 0 0 4px;
  color: var(--afc-text);
}
.afc-contact-form-card__sub { font-size: 13.5px; color: var(--afc-text-muted); margin: 0 0 22px; }
.afc-contact-form { display: flex; flex-direction: column; gap: 14px; }
.afc-contact-form__row { display: flex; gap: 14px; flex-wrap: wrap; }
.afc-contact-label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--afc-text-muted);
  flex: 1 1 140px;
}
.afc-contact-input {
  width: 100%;
  border: 1px solid var(--afc-border);
  background: var(--afc-input-bg);
  border-radius: 11px;
  padding: 12px 14px;
  font-family: var(--afc-font-body);
  font-size: 15px;
  color: var(--afc-text);
  outline: none;
  transition: border-color .18s, box-shadow .18s;
}
.afc-contact-input:focus {
  border-color: var(--afc-accent);
  box-shadow: 0 0 0 3px var(--afc-focus-ring);
}
select.afc-contact-input { cursor: pointer; font-weight: 500; }
textarea.afc-contact-input { resize: vertical; }
.afc-btn--full { width: 100%; justify-content: center; }
.afc-contact-error {
  padding: 12px 16px;
  background: #fce4e7;
  color: #a12;
  border-radius: 10px;
  font-size: 14px;
  margin-bottom: 6px;
}
.afc-contact-success {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 18px;
  background: #e4efe9;
  color: #2a5c3f;
  border-radius: 14px;
}
.afc-contact-success strong { display: block; font-size: 16px; margin-bottom: 4px; }
.afc-contact-success p { font-size: 13.5px; margin: 0; }
.afc-contact-aside {
  flex: 1 1 260px;
  min-width: 240px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.afc-contact-info-card {
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: 16px;
  padding: 20px;
  display: flex;
  gap: 14px;
  align-items: flex-start;
}
.afc-contact-info-card__icon {
  flex: 0 0 40px;
  height: 40px;
  border-radius: 11px;
  background: var(--afc-accent-soft);
  color: var(--afc-accent);
  display: flex;
  align-items: center;
  justify-content: center;
}
.afc-contact-info-card__title {
  font-family: var(--afc-font-display);
  font-weight: 600;
  font-size: 15px;
  margin-bottom: 3px;
  color: var(--afc-text);
}
.afc-contact-info-card__body { font-size: 13px; color: var(--afc-text-muted); line-height: 1.5; }

/* ── Pages légales ── */
.afc-legal-wrap {
  display: flex;
  gap: 36px;
  align-items: flex-start;
  flex-wrap: wrap;
}
.afc-legal-toc {
  flex: 0 0 240px;
  position: sticky;
  top: 84px;
  align-self: flex-start;
  background: var(--afc-surface);
  border: 1px solid var(--afc-border);
  border-radius: 16px;
  padding: 18px 16px;
}
.afc-legal-toc__heading {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--afc-text-faint);
  margin-bottom: 12px;
}
.afc-legal-toc__list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 2px; }
.afc-legal-toc__link {
  display: block;
  text-decoration: none;
  font-size: 13.5px;
  color: var(--afc-text-muted);
  padding: 7px 9px;
  border-radius: 8px;
  line-height: 1.35;
  transition: background .15s, color .15s;
}
.afc-legal-toc__link:hover { background: var(--afc-surface-2); color: var(--afc-text); }
.afc-legal-toc__date {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--afc-border);
  font-size: 11.5px;
  color: var(--afc-text-faint);
  line-height: 1.5;
}
.afc-legal-toc__date strong { color: var(--afc-text-muted); }
.afc-legal-content {
  flex: 1 1 460px;
  min-width: 280px;
  max-width: 720px;
}
.afc-legal-section { scroll-margin-top: 96px; margin-bottom: 36px; }
.afc-legal-section__title {
  font-family: var(--afc-font-display);
  font-weight: 700;
  font-size: 21px;
  letter-spacing: -.015em;
  margin: 0 0 14px;
  display: flex;
  align-items: baseline;
  gap: 10px;
  color: var(--afc-text);
}
.afc-legal-section__num { font-size: 13px; color: var(--afc-accent); font-weight: 700; }
.afc-legal-section p {
  font-size: 15px;
  line-height: 1.72;
  color: var(--afc-text-muted);
  margin: 0 0 14px;
}
.afc-legal-contact-note {
  margin-top: 12px;
  padding: 20px 22px;
  background: var(--afc-accent-soft);
  border-radius: 16px;
}
.afc-legal-contact-note p { font-size: 14px; color: var(--afc-text-muted); margin: 0; line-height: 1.6; }
.afc-legal-contact-note a { color: var(--afc-accent); font-weight: 600; text-decoration: none; }

/* ── Responsive — pages éditoriales ── */
@media (max-width: 768px) {
  .afc-about-mission { flex-direction: column; }
  .afc-about-stats { flex: none; width: 100%; }
  .afc-legal-toc { display: none; }
  .afc-contact-wrap { flex-direction: column; }
  .afc-contact-aside { width: 100%; }
}

/* ============================================================
   DARK MODE — couleurs personnalisables via Customizer
   (surcharge les variables de #page.theme-dark)
   ============================================================ */
/* Les variables sont injectées inline via afc_customizer_css() */

/* ============================================================
   VUES & TENDANCE — Système de comptage (v1.9.0)
   ============================================================ */

/* ── Compteur de vues générique ── */
.afc-view-count {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  font-weight: 600;
  color: var(--afc-text-faint);
  white-space: nowrap;
  line-height: 1;
}
.afc-view-count__icon {
  width: 12px;
  height: 12px;
  flex-shrink: 0;
  opacity: .75;
}
.afc-view-count__label {
  color: var(--afc-text-faint);
  font-weight: 500;
}

/* ── Variante page détail ── */
.afc-view-count--detail {
  font-size: 13.5px;
  color: var(--afc-text-muted);
}
.afc-view-count--detail .afc-view-count__icon {
  width: 14px;
  height: 14px;
  opacity: 1;
}

/* ── Ligne date • vues sur la page détail ── */
.afc-detail__view-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 6px 0 20px;
  font-size: 13.5px;
  color: var(--afc-text-muted);
  flex-wrap: wrap;
}
.afc-detail__pub-date { font-weight: 500; }
.afc-detail__view-sep { color: var(--afc-border-strong); font-weight: 300; }

/* ── Badge tendance 🔥 ── */
.afc-badge-trending {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #fff3e0;
  color: #e65100;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 20px;
  border: 1px solid #ffe0b2;
  vertical-align: middle;
  white-space: nowrap;
}
.afc-badge-trending--sm {
  padding: 2px 6px;
  font-size: 11px;
}

/* ── Widget opportunités populaires ── */
.afc-popular-widget {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.afc-popular-widget__item {
  border-bottom: 1px solid var(--afc-divider);
}
.afc-popular-widget__item:last-child { border-bottom: none; }
.afc-popular-widget__link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 0;
  text-decoration: none;
  color: inherit;
  transition: opacity .15s;
}
.afc-popular-widget__link:hover { opacity: .78; }
.afc-popular-widget__body { flex: 1; min-width: 0; }
.afc-popular-widget__type {
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.afc-popular-widget__title {
  font-size: 13px;
  font-weight: 600;
  color: var(--afc-text);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.afc-popular-widget__meta {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
  font-size: 11.5px;
  color: var(--afc-text-faint);
}
.afc-popular-widget .afc-view-count svg {
  width: 11px;
  height: 11px;
}

/* ── Adaptations dark mode ── */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme-override]) .afc-badge-trending {
    background: rgba(230, 81, 0, .15);
    border-color: rgba(230, 81, 0, .3);
    color: #ffb74d;
  }
}
#page.theme-dark .afc-badge-trending {
  background: rgba(230, 81, 0, .15);
  border-color: rgba(230, 81, 0, .3);
  color: #ffb74d;
}

/* ── Responsive ── */
@media (max-width: 600px) {
  .afc-detail__view-row { gap: 6px; font-size: 12.5px; }
  .afc-view-count--detail { font-size: 12.5px; }
}

/* ============================================================
   PROTECTION DU CONTENU (v1.9.0)
   ============================================================ */

/* ── Désactivation sélection de texte (appliquée via JS .afc-no-select) ── */
.afc-no-select {
  -webkit-user-select: none;
  -moz-user-select:    none;
  -ms-user-select:     none;
  user-select:         none;
}
/* Toujours autoriser la sélection dans les formulaires */
.afc-no-select input,
.afc-no-select textarea,
.afc-no-select select,
.afc-no-select [contenteditable] {
  -webkit-user-select: text;
  -moz-user-select:    text;
  -ms-user-select:     text;
  user-select:         text;
}

/* ── Toast de protection — notification discrète ── */
.afc-protect-toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(16px);
  z-index: 99999;
  background: rgba(30, 25, 20, .88);
  color: #ede7dc;
  font-family: var(--afc-font-body, system-ui, sans-serif);
  font-size: 13.5px;
  font-weight: 500;
  line-height: 1.4;
  padding: 11px 20px;
  border-radius: 40px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, .28);
  max-width: min(420px, calc(100vw - 32px));
  text-align: center;
  pointer-events: none;
  opacity: 0;
  transition: opacity .22s ease, transform .22s ease;
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}
.afc-protect-toast--visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ── Dark mode ── */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme-override]) .afc-protect-toast {
    background: rgba(240, 235, 228, .92);
    color: #2a2521;
  }
}
#page.theme-dark .afc-protect-toast {
  background: rgba(240, 235, 228, .92);
  color: #2a2521;
}

/* ── Responsive ── */
@media (max-width: 480px) {
  .afc-protect-toast {
    bottom: 16px;
    font-size: 13px;
    padding: 10px 16px;
  }
}

/* ============================================================
   CLAUSE DE NON-RESPONSABILITÉ — Accordéon (v1.9.0)
   ============================================================ */

.afc-disclaimer {
  margin: 32px 0;
  border: 1px solid var(--afc-border);
  border-radius: var(--afc-radius, 14px);
  background: var(--afc-surface);
  overflow: hidden;
}

/* ── Bouton toggle ── */
.afc-disclaimer__toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  padding: 16px 20px;
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--afc-font-body, system-ui, sans-serif);
  font-size: 14.5px;
  font-weight: 700;
  color: var(--afc-text-muted);
  text-align: left;
  transition: color .18s ease, background .18s ease;
}
.afc-disclaimer__toggle:hover,
.afc-disclaimer__toggle:focus-visible {
  color: var(--afc-accent);
  background: var(--afc-accent-soft);
  outline: none;
}
.afc-disclaimer__toggle:focus-visible {
  box-shadow: inset 0 0 0 2px var(--afc-accent);
}
.afc-disclaimer__toggle-label {
  flex: 1;
}

/* ── Chevron animé ── */
.afc-disclaimer__chevron {
  flex-shrink: 0;
  color: var(--afc-text-faint);
  transition: transform .3s ease, color .18s ease;
}
.afc-disclaimer__toggle--open .afc-disclaimer__chevron,
.afc-disclaimer__toggle[aria-expanded="true"] .afc-disclaimer__chevron {
  transform: rotate(180deg);
  color: var(--afc-accent);
}

/* ── Corps accordéon ── */
.afc-disclaimer__body {
  overflow: hidden;
  max-height: none;
  transition: max-height .35s ease;
}
/* État caché : on écrase [hidden] pour préserver le DOM
   et permettre au JS de mesurer scrollHeight */
.afc-disclaimer__body[hidden] {
  display: block !important;
  max-height: 0;
  visibility: hidden;
  pointer-events: none;
}

.afc-disclaimer__inner {
  padding: 0 20px 20px;
  border-top: 1px solid var(--afc-divider);
}

/* ── Texte ── */
.afc-disclaimer__text {
  font-size: 14px;
  line-height: 1.7;
  color: var(--afc-text-muted);
  margin: 16px 0 10px;
}
.afc-disclaimer__source {
  font-size: 13px;
  font-weight: 600;
  color: var(--afc-accent);
  margin: 0;
}

/* ── Dark mode ── */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme-override]) .afc-disclaimer {
    border-color: var(--afc-border);
    background: var(--afc-surface);
  }
}
#page.theme-dark .afc-disclaimer {
  border-color: var(--afc-border);
  background: var(--afc-surface);
}

/* ── Responsive ── */
@media (max-width: 600px) {
  .afc-disclaimer__toggle { padding: 14px 16px; font-size: 13.5px; }
  .afc-disclaimer__inner  { padding: 0 16px 16px; }
  .afc-disclaimer__text   { font-size: 13.5px; }
}

/* =============================================================
   SYSTÈME DE RECOMMANDATIONS — Afri-Carrières
   Bloc in-content (.afc-reco-block) + Bloc footer (.afc-reco-footer)
   + Carte commune (.afc-reco-card)
   ============================================================= */

/* ── Bloc générique (in-content et footer) ── */
.afc-reco-block {
  margin: 2rem 0;
  padding: 1.25rem 1.5rem;
  background: var(--afc-bg-alt, #f8f9fa);
  border-left: 3px solid var(--afc-accent, #e85d04);
  border-radius: var(--afc-radius, 8px);
  font-family: var(--afc-font, inherit);
}

.afc-reco-block__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
  gap: 1rem;
}

.afc-reco-block__title {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--afc-text-muted, #6b7280);
}

.afc-reco-block__see-all {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--afc-accent, #e85d04);
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
}
.afc-reco-block__see-all:hover { text-decoration: underline; }

.afc-reco-block__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 0.75rem;
}

/* ── Carte recommandation ── */
.afc-reco-card {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  padding: 0.75rem;
  background: var(--afc-surface, #fff);
  border: 1px solid var(--afc-border, #e5e7eb);
  border-radius: calc(var(--afc-radius, 8px) - 2px);
  text-decoration: none;
  color: inherit;
  transition: box-shadow 0.18s ease, transform 0.18s ease;
}
.afc-reco-card:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,0.08);
  transform: translateY(-2px);
}

/* Miniature */
.afc-reco-card__thumb {
  flex-shrink: 0;
  width: 60px;
  height: 60px;
  border-radius: calc(var(--afc-radius, 8px) - 4px);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.afc-reco-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.afc-reco-card__thumb--placeholder {
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

/* Corps de la carte */
.afc-reco-card__body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.afc-reco-card__type {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  line-height: 1;
}

.afc-reco-card__title {
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--afc-text, #111827);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.afc-reco-card__org {
  font-size: 0.72rem;
  color: var(--afc-text-muted, #6b7280);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.afc-reco-card__footer {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 0.25rem;
}

.afc-reco-card__deadline {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 999px;
  line-height: 1.6;
}

/* Badge financement */
.afc-reco-card__funding {
  display: block;
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--afc-text-muted, #6b7280);
  margin-top: 0.1rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.afc-reco-card__funding--full {
  color: #15803d;
  font-weight: 700;
}

/* Carte en mode footer (légèrement plus grande) */
.afc-reco-card--footer .afc-reco-card__thumb {
  width: 72px;
  height: 72px;
}
.afc-reco-card--footer .afc-reco-card__title {
  font-size: 0.87rem;
}

/* ── Section footer "À découvrir" ── */
.afc-reco-footer {
  margin-top: 3rem;
  padding-top: 2.5rem;
  border-top: 1px solid var(--afc-border, #e5e7eb);
}

.afc-reco-footer__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.afc-reco-footer__title {
  font-size: clamp(1.1rem, 2.5vw, 1.4rem);
  font-weight: 800;
  color: var(--afc-text, #111827);
  margin: 0 0 0.25rem;
  line-height: 1.2;
}

.afc-reco-footer__sub {
  font-size: 0.88rem;
  color: var(--afc-text-muted, #6b7280);
  margin: 0;
}

.afc-reco-footer__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
}

/* ── Dark mode ── */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme-override]) .afc-reco-block {
    background: var(--afc-surface, #1f2937);
  }
  :root:not([data-theme-override]) .afc-reco-card {
    background: var(--afc-bg-alt, #111827);
    border-color: var(--afc-border, #374151);
  }
}
#page.theme-dark .afc-reco-block { background: var(--afc-surface); }
#page.theme-dark .afc-reco-card  { background: var(--afc-bg-alt); border-color: var(--afc-border); }

/* ── Responsive ── */
@media (max-width: 768px) {
  .afc-reco-block { padding: 1rem; }
  .afc-reco-block__grid { grid-template-columns: 1fr; }
  .afc-reco-footer__grid { grid-template-columns: 1fr; }
  .afc-reco-footer__head { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 480px) {
  .afc-reco-card__thumb { width: 48px; height: 48px; }
  .afc-reco-card--footer .afc-reco-card__thumb { width: 56px; height: 56px; }
}

/* =============================================================
   APPLICATION MOBILE PROMO — Afri-Carrières v2.1.0
   Composant 1 : Bloc footer  (.afc-app-footer)
   Composant 2 : Widget sidebar (.afc-app-widget)
   Composant 3 : Bannière mobile (.afc-app-banner)
   ============================================================= */

/* ── 1. BLOC FOOTER ── */
.afc-app-footer {
  display: flex;
  align-items: flex-start;
  gap: .875rem;
  margin-bottom: 1.25rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid rgba(255,255,255,.1);
}

.afc-app-footer__img {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  object-fit: cover;
  flex-shrink: 0;
}

.afc-app-footer__body {
  display: flex;
  flex-direction: column;
  gap: .35rem;
}

.afc-app-footer__title {
  font-size: .8rem;
  font-weight: 700;
  color: rgba(255,255,255,.95);
  margin: 0;
  line-height: 1.3;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.afc-app-footer__desc {
  font-size: .78rem;
  color: rgba(255,255,255,.6);
  margin: 0;
  line-height: 1.45;
}

.afc-app-badge {
  display: inline-block;
  margin-top: .4rem;
  transition: opacity .18s ease, transform .18s ease;
  border-radius: 7px;
  overflow: hidden;
  line-height: 0;
}
.afc-app-badge:hover  { opacity: .85; transform: translateY(-1px); }
.afc-app-badge:focus-visible {
  outline: 2px solid var(--afc-accent, #e85d04);
  outline-offset: 2px;
}
.afc-app-badge img,
.afc-app-badge svg { display: block; }

/* ── 2. WIDGET SIDEBAR ── */
.afc-app-widget {
  padding: 1.1rem 1.25rem;
  background: var(--afc-bg-alt, #f8f9fa);
  border-left: 3px solid var(--afc-accent, #e85d04);
  border-radius: var(--afc-radius, 8px);
  margin-bottom: 1.5rem;
}

.afc-app-widget__title {
  font-size: .88rem;
  font-weight: 700;
  color: var(--afc-text, #111827);
  margin: 0 0 .5rem;
  line-height: 1.3;
}

.afc-app-widget__desc {
  font-size: .82rem;
  color: var(--afc-text-muted, #6b7280);
  margin: 0 0 .875rem;
  line-height: 1.5;
}

.afc-app-widget__cta {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  font-size: .82rem;
  font-weight: 700;
  color: var(--afc-accent, #e85d04);
  text-decoration: none;
  padding: .5rem .875rem;
  border: 1.5px solid var(--afc-accent, #e85d04);
  border-radius: 999px;
  transition: background .18s ease, color .18s ease;
}
.afc-app-widget__cta:hover {
  background: var(--afc-accent, #e85d04);
  color: #fff;
}
.afc-app-widget__cta:focus-visible {
  outline: 2px solid var(--afc-accent, #e85d04);
  outline-offset: 3px;
}

/* ── Dark mode widget ── */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme-override]) .afc-app-widget {
    background: var(--afc-surface, #1f2937);
  }
}
#page.theme-dark .afc-app-widget { background: var(--afc-surface); }

/* ── 3. BANNIÈRE MOBILE ── */
.afc-app-banner {
  /* Position : fixed bottom, au-dessus de afc-bottom-nav (hauteur ~62px) */
  position: fixed;
  bottom: 62px;          /* hauteur afc-bottom-nav */
  left: 0;
  right: 0;
  z-index: 1200;

  /* Animation : glisse depuis le bas */
  transform: translateY(calc(100% + 62px));
  transition: transform .32s cubic-bezier(.4,0,.2,1);

  /* Desktop : masqué */
  display: none;
}

/* Visible uniquement sur mobile */
@media (max-width: 900px) {
  .afc-app-banner { display: block; }
}

/* État visible (classe ajoutée par JS) */
.afc-app-banner--visible {
  transform: translateY(0);
}

.afc-app-banner__inner {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .75rem 1rem;
  background: var(--afc-surface, #fff);
  border-top: 1px solid var(--afc-border, #e5e7eb);
  box-shadow: 0 -4px 20px rgba(0,0,0,.1);
}

.afc-app-banner__icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--afc-accent, #e85d04);
  color: #fff;
  border-radius: 8px;
}

.afc-app-banner__text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
  overflow: hidden;
}

.afc-app-banner__title {
  font-size: .8rem;
  font-weight: 700;
  color: var(--afc-text, #111827);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}

.afc-app-banner__desc {
  font-size: .72rem;
  color: var(--afc-text-muted, #6b7280);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}

.afc-app-banner__cta {
  flex-shrink: 0;
  font-size: .78rem;
  font-weight: 700;
  color: #fff;
  background: var(--afc-accent, #e85d04);
  padding: .45rem .875rem;
  border-radius: 999px;
  text-decoration: none;
  white-space: nowrap;
  transition: opacity .18s ease;
}
.afc-app-banner__cta:hover        { opacity: .88; }
.afc-app-banner__cta:focus-visible {
  outline: 2px solid var(--afc-accent, #e85d04);
  outline-offset: 3px;
}

.afc-app-banner__close {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  padding: 0;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--afc-text-muted, #6b7280);
  border-radius: 50%;
  transition: background .15s ease, color .15s ease;
}
.afc-app-banner__close:hover {
  background: var(--afc-bg-alt, #f3f4f6);
  color: var(--afc-text, #111827);
}

/* ── Dark mode bannière ── */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme-override]) .afc-app-banner__inner {
    background: var(--afc-surface, #1f2937);
    border-top-color: var(--afc-border, #374151);
    box-shadow: 0 -4px 20px rgba(0,0,0,.3);
  }
}
#page.theme-dark .afc-app-banner__inner {
  background: var(--afc-surface);
  border-top-color: var(--afc-border);
}

/* ── Très petit écran : version compacte ── */
@media (max-width: 380px) {
  .afc-app-banner__desc { display: none; }
  .afc-app-banner__cta  { font-size: .73rem; padding: .4rem .7rem; }
}

/* =============================================================
   CORRECTIFS — Badges favoris + image mise en avant
   ============================================================= */

/* Bouton favori sur mobile : reste aligné sur la même ligne que les badges */
@media (max-width: 640px) {
  .afc-detail__badges .afc-btn-fav {
    margin-left: 0 !important;
    margin-top: 0;
  }
  /* Sur très petit écran, le bouton fav passe en dessous à gauche — jamais seul à droite */
  .afc-detail__badges {
    row-gap: 6px;
  }
}
