/* ==========================================================================
   PRIVADA — compléments propres à WordPress.
   Tout ce qui n'existait pas dans l'aperçu statique : le blogue, le contenu
   rédigé dans l'éditeur, quelques classes qui remplacent des styles en ligne.
   Les jetons (--gold, --ink, --sp-*, --step-*) viennent de style.css.
   ========================================================================== */

/* ── Remplaçants des styles en ligne de l'aperçu ─────────────────────────── */
.manifeste-inline {
  margin-top: 2rem;
  font-family: var(--font-serif);
  font-size: var(--step-2);
  line-height: 1.35;
  color: var(--cream);
}
.manifeste-inline span { color: var(--gold); }
.manifeste-inline--grand { margin-top: 0; font-size: var(--step-3); line-height: 1.3; }

.card-grid--territoire { background: transparent; border: 0; gap: var(--sp-m); }
.card--territoire { background: rgba(244, 243, 241, .05); border: 1px solid var(--border-invert); }
.card--territoire h3 { color: var(--cream); }
.card--territoire p { color: var(--text-invert-mute); }

.split--egal { grid-template-columns: 1fr 1fr; }
@media (max-width: 860px) { .split--egal { grid-template-columns: 1fr; } }

.contact-list { list-style: none; padding: 0; display: grid; gap: 1.1rem; margin-top: 1.25rem; }
.contact-list li { display: flex; gap: .7rem; align-items: flex-start; }
.contact-list svg { width: 17px; height: 17px; color: var(--gold); flex: none; margin-top: 5px; }
.contact-list__note { font-size: .86rem; color: var(--ink-mute); }
.infocard__texte { margin-top: 1.25rem; }
.infocard__texte p { color: var(--text-mute); }

.section-404 { min-height: 64svh; display: grid; align-items: center; }

/* Champ piège du formulaire : hors écran, jamais affiché */
.piege { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }

/* Logo téléversé par le client : même gabarit que le SVG du thème */
.brand img { height: 84px; width: auto; }
@media (max-width: 640px) { .brand img { height: 58px; } }

/* ── Blogue : grille de cartes ───────────────────────────────────────────── */
.post-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
  gap: var(--sp-m);
}
.post-card {
  display: flex; flex-direction: column;
  background: var(--paper, #fff);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: transform .35s ease, box-shadow .35s ease;
}
.post-card:hover { transform: translateY(-4px); box-shadow: 0 18px 40px rgba(17, 17, 17, .08); }
.post-card__media { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--ink); }
.post-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s ease; }
.post-card:hover .post-card__media img { transform: scale(1.04); }
.post-card__placeholder { display: grid; place-items: center; width: 100%; height: 100%; }
.post-card__placeholder img { width: 96px; height: 96px; object-fit: contain; opacity: .55; }
.post-card__body { display: flex; flex-direction: column; gap: .75rem; padding: 1.5rem; flex: 1; }
.post-card__meta {
  display: flex; flex-wrap: wrap; gap: .5rem; align-items: center;
  font-family: var(--font-mono); font-size: .72rem; letter-spacing: .08em; text-transform: uppercase;
  color: var(--ink-mute);
}
.post-card__cat { color: var(--gold-ink); }
.post-card__title { font-size: var(--step-1); line-height: 1.25; letter-spacing: -.01em; }
.post-card__title a { color: var(--ink); text-decoration: none; }
.post-card__title a:hover { color: var(--gold-ink); }
.post-card__excerpt { color: var(--text-mute); font-size: .95rem; flex: 1; }
.post-card__more {
  display: inline-flex; align-items: center; gap: .5rem; align-self: flex-start;
  font-weight: 600; font-size: .9rem; color: var(--ink); text-decoration: none;
  border-bottom: 1px solid var(--gold); padding-bottom: 2px;
}
.post-card__more svg { width: 14px; height: 14px; transition: transform .3s ease; }
.post-card__more:hover svg { transform: translateX(4px); }

/* Pagination de WordPress */
.pagination { margin-top: var(--sp-xl); }
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: .5rem; justify-content: center; align-items: center; }
.pagination .page-numbers {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 44px; min-height: 44px; padding: 0 .9rem;
  border: 1px solid var(--border); color: var(--ink); text-decoration: none;
  font-family: var(--font-mono); font-size: .85rem;
}
.pagination .page-numbers.current { background: var(--ink); color: var(--cream); border-color: var(--ink); }
.pagination a.page-numbers:hover { border-color: var(--gold); color: var(--gold-ink); }
.pagination .page-numbers svg { width: 16px; height: 16px; }
.pagination .page-numbers svg.is-prev { transform: rotate(180deg); }
.pagination .dots { border: 0; }

/* ── Blogue : un article ─────────────────────────────────────────────────── */
.page-head--article .container { max-width: var(--w-narrow, 48rem); }
.article__meta {
  display: flex; gap: .5rem; align-items: center;
  font-family: var(--font-mono); font-size: .74rem; letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink-mute);
}
.article__titre {
  margin-top: 1rem;
  font-size: clamp(1.9rem, 4.2vw, 3.1rem); line-height: 1.12; letter-spacing: -.02em;
  color: var(--ink); text-wrap: balance;
}
.article__image { margin-top: calc(-1 * var(--sp-l)); position: relative; z-index: 2; }
.article__image img { width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; display: block; box-shadow: 0 24px 60px rgba(17, 17, 17, .18); }
.article__tags { margin-top: var(--sp-m); display: flex; flex-wrap: wrap; gap: .5rem; }
.article__tags a { font-family: var(--font-mono); font-size: .78rem; color: var(--gold-ink); text-decoration: none; border: 1px solid var(--border); padding: .3rem .6rem; }
.article__tags a:hover { border-color: var(--gold); }
.article__partage {
  margin-top: var(--sp-m); padding-top: var(--sp-m); border-top: 1px solid var(--border);
  display: flex; flex-wrap: wrap; gap: 1rem; align-items: center;
  font-size: .9rem;
}
.article__partage > span { font-family: var(--font-mono); font-size: .74rem; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-mute); }
.article__partage a { display: inline-flex; align-items: center; gap: .4rem; color: var(--ink); text-decoration: none; font-weight: 600; }
.article__partage a:hover { color: var(--gold-ink); }
.article__partage svg { width: 16px; height: 16px; color: var(--gold); }

/* ── Contenu rédigé dans l'éditeur WordPress (articles, pages simples) ───── */
.prose--wp > * + * { margin-top: var(--sp-m); }
.prose--wp h2, .prose--wp h3, .prose--wp h4 { margin-top: var(--sp-l); color: var(--ink); }
.prose--wp h2 { font-size: var(--step-2); }
.prose--wp h3 { font-size: var(--step-1); }
.prose--wp h4 { font-size: 1.05rem; text-transform: uppercase; letter-spacing: .06em; }
.prose--wp p, .prose--wp li { color: var(--text-mute); }
.prose--wp ul, .prose--wp ol { padding-left: 1.25rem; }
.prose--wp a { color: var(--gold-ink); text-decoration: underline; text-underline-offset: 3px; }
.prose--wp img { max-width: 100%; height: auto; }
.prose--wp figure { margin: var(--sp-l) 0; }
.prose--wp figcaption, .wp-caption-text { font-size: .84rem; color: var(--ink-mute); margin-top: .5rem; text-align: center; }
.prose--wp blockquote {
  border-left: 3px solid var(--gold); padding: .25rem 0 .25rem 1.25rem;
  font-family: var(--font-serif); font-size: var(--step-1); line-height: 1.4; color: var(--ink);
}
.prose--wp blockquote cite { display: block; margin-top: .75rem; font-family: var(--font-mono); font-size: .74rem; font-style: normal; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-mute); }
.prose--wp table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.prose--wp th, .prose--wp td { border: 1px solid var(--border); padding: .6rem .8rem; text-align: left; vertical-align: top; }
.prose--wp th { background: var(--paper-2, #f4f3f1); color: var(--ink); }
.prose--wp .wp-block-table { overflow-x: auto; }
.prose--wp .wp-block-embed iframe, .prose--wp iframe { max-width: 100%; }
.prose--wp .wp-block-button__link { display: inline-block; background: var(--gold); color: var(--ink); padding: .9rem 1.4rem; text-decoration: none; font-weight: 600; }
.prose--wp .alignleft { float: left; margin: 0 var(--sp-m) var(--sp-s) 0; }
.prose--wp .alignright { float: right; margin: 0 0 var(--sp-s) var(--sp-m); }
.prose--wp .aligncenter { display: block; margin-inline: auto; }
.prose--wp .alignwide, .prose--wp .alignfull { width: 100%; }
.prose--wp .wp-block-separator { border: 0; border-top: 1px solid var(--border); margin: var(--sp-l) 0; }
.prose--wp .has-text-align-center { text-align: center; }
.prose--wp .wp-block-quote.is-style-large { font-size: var(--step-2); }
.prose--wp .wp-block-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: .75rem; }
.prose--wp .wp-block-gallery figure { margin: 0; }
.prose--wp .wp-block-details { border: 1px solid var(--border); padding: 1rem 1.25rem; }
.prose--wp .wp-block-details summary { cursor: pointer; font-weight: 600; color: var(--ink); }

/* Accessibilité : texte lu par les lecteurs d'écran seulement */
.screen-reader-text {
  border: 0; clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%);
  height: 1px; width: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute !important; word-wrap: normal !important;
}
.screen-reader-text:focus {
  background: var(--cream); color: var(--ink); clip: auto; clip-path: none;
  height: auto; width: auto; left: 5px; top: 5px; padding: 1rem; z-index: 100000; text-decoration: none;
}

/* Barre d'administration de WordPress : l'en-tête collant descend d'autant */
.admin-bar .site-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .site-header { top: 46px; } }

/* Le formulaire après envoi : le message de confirmation prend toute la place */
.form-status:only-child { margin: 0; }
