/* =========================================================
   LES ACTUALITÉS

   Une actualité se lit d'abord avec les yeux : l'image porte
   l'information avant le titre. Les cartes sont donc des images
   d'abord, et la première est plus grande que les autres — il y a
   toujours une actualité qui compte plus que les cinq suivantes.
   ========================================================= */

.nv-grille {
  display: grid; gap: 1rem;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  margin-top: 1.6rem;
}

.nv-carte {
  display: flex; flex-direction: column; min-width: 0;
  background: var(--surface, #fff);
  border-radius: var(--r-lg, 18px); overflow: hidden;
  box-shadow: inset 0 0 0 1px var(--trait);
  text-decoration: none; color: inherit;
  transition: transform .2s var(--ease-doux), box-shadow .2s;
}
.nv-carte:hover {
  transform: translateY(-3px);
  box-shadow: inset 0 0 0 1px var(--trait), var(--ombre-2);
}

/* La une : deux colonnes sur la largeur entière, image à gauche. */
.nv-carte--une { grid-column: 1 / -1; flex-direction: row; }
.nv-carte--une .nv-carte__img { flex: 1 1 54%; aspect-ratio: auto; }
.nv-carte--une .nv-carte__txt { flex: 1 1 46%; justify-content: center; padding: 1.6rem 1.7rem; }
.nv-carte--une h3 { font-size: 1.9rem; }
.nv-carte--une p { font-size: var(--fs-sm); -webkit-line-clamp: 4; }

.nv-carte__img {
  position: relative; display: block; overflow: hidden;
  aspect-ratio: 16 / 10; background: var(--bg-alt, #eef2ec);
}
.nv-carte__img img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform .5s var(--ease-doux);
}
.nv-carte:hover .nv-carte__img img { transform: scale(1.04); }

/* Pas d'image : un aplat aux couleurs de la commune plutôt qu'un
   rectangle gris. Une carte sans visuel doit rester une carte. */
.nv-carte__sans {
  position: absolute; inset: 0;
  background: linear-gradient(140deg, var(--c-vert), var(--c-bleu));
  opacity: .9;
}

.nv-carte__txt { display: flex; flex-direction: column; gap: .35rem; padding: .95rem 1.05rem 1.15rem; flex: 1; }
.nv-carte__txt h3 {
  margin: 0; font-family: var(--f-titre, inherit);
  font-size: 1.3rem; line-height: 1.15; letter-spacing: .02em;
}
.nv-carte__txt p {
  margin: 0; color: var(--texte-doux); font-size: .84rem; line-height: 1.5;
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden;
}
.nv-carte__txt time {
  margin-top: auto; padding-top: .4rem;
  font-size: var(--fs-xs); color: var(--texte-doux);
}

/* ---------- La pastille de rubrique ----------
   Un chantier et une fête n'ont pas la même urgence : l'œil doit
   pouvoir trier avant de lire. */
.nv-pastille {
  align-self: flex-start;
  padding: .16rem .55rem; border-radius: var(--r-pill, 99px);
  font-size: .66rem; font-weight: 800; letter-spacing: .09em;
  text-transform: uppercase; color: #fff;
  background: var(--c-vert);
}
.nv-pastille--trv { background: #b8730f; }
.nv-pastille--evt { background: #8a3fa0; }
.nv-pastille--vmu { background: var(--c-vert, #3f6c5b); }
.nv-pastille--sol { background: #1f6f8b; }
.nv-pastille--env { background: #2f7d3a; }
.nv-pastille--jeu { background: #c2450c; }
.nv-pastille--alr { background: #b4291f; }

.nv-vide {
  margin: 1.4rem 0 0; padding: 1.1rem 1.2rem;
  border: 1px dashed var(--trait); border-radius: var(--r-md, 14px);
  color: var(--texte-doux); font-size: var(--fs-sm); line-height: 1.6;
}

/* =========================================================
   LA VUE : liste complète et article
   ========================================================= */
.vue--actus { background: var(--bg); min-height: 100svh; padding-bottom: var(--sp-5); }

.nv-tete { padding: var(--sp-4) 0 .4rem; }
.nv-tete h1 { margin: .1rem 0 0; }
.nv-tete__s { margin: .35rem 0 0; color: var(--texte-doux); font-size: var(--fs-sm); }

.nv-an { margin-top: var(--sp-4); }
.nv-an h2 {
  margin: 0; font-size: 1.3rem;
  padding-bottom: .4rem; border-bottom: 1px solid var(--trait);
}

/* ---------- L'article ----------
   Une colonne étroite : au-delà de soixante-dix signes par ligne,
   l'œil perd le début de la ligne suivante. */
.nv-art { max-width: 46rem; margin: 0 auto; padding: var(--sp-4) 0 0; }
.nv-art__fil { margin: 0 0 .9rem; font-size: var(--fs-sm); }
.nv-art__fil a { color: var(--texte-doux); }
.nv-art h1 { margin: .5rem 0 .3rem; }
.nv-art__date { margin: 0 0 1rem; font-size: var(--fs-sm); color: var(--texte-doux); }
.nv-art__chapo {
  margin: 0 0 1.4rem; font-size: 1.1rem; line-height: 1.6; font-weight: 500;
}
.nv-art__img { margin: 0 0 1.6rem; }
.nv-art__img img {
  width: 100%; height: auto; display: block;
  border-radius: var(--r-lg, 18px); box-shadow: var(--ombre-1);
}
.nv-art__corps p { margin: 0 0 1.1rem; line-height: 1.75; }
.nv-art__fb { margin: 1.6rem 0 0; font-size: var(--fs-sm); }

.nv-suite {
  display: grid; gap: .8rem; grid-template-columns: 1fr 1fr;
  max-width: 46rem; margin: var(--sp-4) auto 0;
}
.nv-suite a {
  display: block; padding: .9rem 1rem;
  border-radius: var(--r-md, 14px); background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--trait);
  text-decoration: none; color: inherit;
}
.nv-suite a:hover { box-shadow: inset 0 0 0 2px var(--c-vert); }
.nv-suite small {
  display: block; font-size: var(--fs-xs); color: var(--texte-doux);
  letter-spacing: .08em; text-transform: uppercase;
}
.nv-suite b { display: block; margin-top: .2rem; font-size: .95rem; line-height: 1.25; }

/* ---------- Téléphone ----------
   La une repasse en colonne : une image et un texte côte à côte sur
   neuf centimètres, ce sont deux moitiés illisibles. */
@media (max-width: 760px) {
  .nv-carte--une { flex-direction: column; }
  .nv-carte--une .nv-carte__img { aspect-ratio: 16 / 10; }
  .nv-carte--une .nv-carte__txt { padding: .95rem 1.05rem 1.15rem; }
  .nv-carte--une h3 { font-size: 1.45rem; }
  .nv-suite { grid-template-columns: 1fr; }
  .nv-art__chapo { font-size: 1rem; }
}
@media (max-width: 430px) {
  .nv-grille { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  .nv-carte, .nv-carte__img img { transition: none; }
  .nv-carte:hover { transform: none; }
  .nv-carte:hover .nv-carte__img img { transform: none; }
}
