
/* ============================================================
   ARTICLE — styles complémentaires
   ------------------------------------------------------------
   Chargé APRÈS style.css. Ne redéfinit aucune règle existante :
   uniquement des classes nouvelles préfixées .art-, .toc-, .rel-,
   .read-. Les couleurs, la typographie et les transitions
   reprennent les jetons de :root définis dans style.css.
   ============================================================ */

/* ---------- 1. Barre de progression de lecture ----------
   z-index 940 : au-dessus du header (900), sous le menu mobile (950)
   et sous le bandeau cookies (9999). */
.read-progress{
  position:fixed;top:0;left:0;right:0;height:2px;
  background:rgba(200,169,110,.18);
  z-index:940;pointer-events:none;
}

.read-progress__bar{
  height:100%;width:100%;
  background:linear-gradient(90deg,var(--or-soft),var(--or));
  transform:scaleX(0);transform-origin:left center;
  will-change:transform;
}

/* ---------- 2. En-tête d'article (dérivé de .phero) ---------- */
.art-head .phero-inner{max-width:64ch}

.art-head h1{font-size:clamp(2.1rem,5vw,3.6rem);line-height:1.06}

.art-head h1 .li{padding-bottom:.06em}

.art-cat{
  display:inline-block;
  font-size:.68rem;letter-spacing:.18em;text-transform:uppercase;font-weight:700;
  color:var(--or);border:1px solid rgba(200,169,110,.45);
  border-radius:100px;padding:5px 14px;margin-bottom:22px;
}

.art-meta{
  display:flex;flex-wrap:wrap;align-items:center;gap:.6em 1.1em;
  margin-top:28px;
  font-size:.78rem;letter-spacing:.12em;text-transform:uppercase;
  color:rgba(207,203,214,.7);
}

.art-meta .dot{color:var(--or)}

/* ---------- 3. Grille contenu + sommaire ----------
   .wrap fait 1240px moins 2×--pad (max 64px) = 1112px utiles.
   720 (texte) + 80 (gouttière) + 260 (sommaire) = 1060px : la grille
   tient sans toucher à --wrap. Voir la note dans la réponse. */
.art-grid{
  display:grid;
  grid-template-columns:minmax(0,1fr) 260px;
  gap:clamp(36px,5vw,80px);
  align-items:start;
}

.art-body{max-width:70ch}

@media(max-width:980px){
  .art-grid{grid-template-columns:1fr}
  .art-body{max-width:none}
  /* Le sommaire remonte au-dessus du texte : l'ordre DOM garde le
     texte avant l'aside pour les lecteurs d'écran et les crawlers. */
  .art-figure{order:0}
  .art-aside{order:1}
  .art-body{order:2}
}

/* ---------- 4. Image à la une ---------- */
.art-figure{grid-column:1 / -1;margin-bottom:clamp(36px,5vw,64px)}

.art-figure__frame{
  position:relative;aspect-ratio:16/9;overflow:hidden;border-radius:2px;
  /* Fond de repli : si l'image manque, le cadre reste lisible */
  background:linear-gradient(120deg,var(--navy),var(--navy-deep) 60%,#242440);
}

.art-figure__frame::after{
  content:"";position:absolute;inset:0;
  background:radial-gradient(110% 90% at 85% 5%,rgba(200,169,110,.18),transparent 60%);
  pointer-events:none;
}

.art-figure img{width:100%;height:100%;object-fit:cover;position:relative;z-index:1}

.art-figure figcaption{
  margin-top:12px;font-size:.8rem;line-height:1.55;color:var(--gris);max-width:60ch;
}

/* ---------- 5. Corps de l'article ---------- */
.art-chapo{
  font-family:var(--serif);font-size:clamp(1.15rem,2vw,1.4rem);line-height:1.55;
  color:var(--navy);border-left:2px solid var(--or);
  padding:2px 0 2px 22px;margin-bottom:clamp(30px,4vw,44px);
}

.art-body h2{
  font-family:var(--serif);font-weight:400;
  font-size:clamp(1.5rem,3vw,2.15rem);line-height:1.14;letter-spacing:-.01em;
  color:var(--navy);
  margin:clamp(44px,5.5vw,72px) 0 18px;
  scroll-margin-top:110px; /* compense le header fixe lors d'un saut d'ancre */
}

.art-body h2:first-child{margin-top:0}

.art-body h3{
  font-family:var(--serif);font-weight:400;font-size:1.28rem;line-height:1.25;
  color:var(--navy);margin:32px 0 12px;scroll-margin-top:110px;
}

.art-body p{font-size:1.06rem;line-height:1.75;margin-bottom:18px;color:var(--charbon)}

.art-body p:last-child{margin-bottom:0}

.art-body strong{color:var(--navy);font-weight:700}

.art-body a:not(.btn){
  color:#8a6f3d;border-bottom:1px solid rgba(200,169,110,.45);
  transition:border-color .3s var(--ease),color .3s var(--ease);
}

.art-body a:not(.btn):hover{border-color:#8a6f3d}

.art-body hr{
  border:0;height:1px;margin:clamp(40px,5vw,60px) 0;
  background:linear-gradient(90deg,rgba(26,26,46,.18),transparent);
}

/* Encart de mise en garde / précision méthodologique */
.art-note{
  background:rgba(200,169,110,.08);
  border:1px solid rgba(200,169,110,.35);
  border-left-width:2px;border-left-color:var(--or);
  padding:clamp(20px,3vw,28px);margin:clamp(30px,4vw,44px) 0;
}

.art-note .art-note__label{
  font-size:.68rem;letter-spacing:.18em;text-transform:uppercase;font-weight:700;
  color:#8a6f3d;margin-bottom:10px;
}

.art-note p{font-size:.98rem;margin-bottom:12px}

.art-note p:last-child{margin-bottom:0}

/* Tableau simple (échéances, comparatifs) */
.art-table{width:100%;border-collapse:collapse;margin:30px 0;font-size:.96rem}

.art-table th,.art-table td{
  text-align:left;padding:14px 16px 14px 0;
  border-bottom:1px solid rgba(26,26,46,.14);vertical-align:top;
}

.art-table th{
  font-size:.68rem;letter-spacing:.16em;text-transform:uppercase;
  color:#8a6f3d;font-weight:700;border-bottom-color:rgba(26,26,46,.22);
}

.art-table td:first-child{font-family:var(--serif);color:var(--navy);white-space:nowrap;padding-right:28px}

@media(max-width:640px){
  .art-table td:first-child{white-space:normal}
}

/* Signature de fin d'article */
.art-sign{
  margin-top:clamp(44px,5vw,64px);padding-top:26px;
  border-top:1px solid rgba(26,26,46,.16);
  display:flex;flex-wrap:wrap;gap:18px 30px;align-items:baseline;justify-content:space-between;
}

.art-sign__who{font-size:.95rem;color:var(--charbon)}

.art-sign__who b{color:var(--navy)}

.art-sign__share{font-size:.72rem;letter-spacing:.16em;text-transform:uppercase;color:var(--gris)}

.art-sign__share button{
  background:none;border:0;padding:0;margin-left:12px;cursor:pointer;font:inherit;
  color:#8a6f3d;border-bottom:1px solid rgba(200,169,110,.45);transition:border-color .3s}

.art-sign__share button:hover{border-color:#8a6f3d}

/* ---------- 6. Sommaire ---------- */
/* align-self:stretch est indispensable : .art-grid porte
   align-items:start, l'aside se dimensionnait donc à la hauteur de son
   contenu et l'élément sticky n'avait aucune course pour se déplacer.
   Étiré sur toute la rangée, il suit le texte jusqu'au dernier
   paragraphe. */
.art-aside{position:relative;align-self:stretch;height:100%}

.toc{
  position:sticky;top:104px;
  max-height:calc(100vh - 150px);
  display:flex;flex-direction:column;
}

.toc__label{
  font-size:.68rem;letter-spacing:.18em;text-transform:uppercase;font-weight:700;
  color:#8a6f3d;margin-bottom:16px;
}

.toc__list{overflow-y:auto;overscroll-behavior:contain}

.toc__list a{
  display:block;padding:8px 0 8px 16px;
  border-left:1px solid rgba(26,26,46,.16);
  font-size:.86rem;line-height:1.45;color:var(--charbon);opacity:.65;
  transition:opacity .3s var(--ease),color .3s var(--ease),border-color .3s var(--ease);
}

.toc__list a:hover{opacity:1;color:var(--navy);border-left-color:rgba(200,169,110,.7)}

.toc__list a.active{
  opacity:1;color:var(--navy);font-weight:700;
  border-left-color:var(--or);
}

.toc__toggle{display:none}

/* Version repliable sur tablette/mobile */
@media(max-width:980px){
  .art-aside{
    position:sticky;top:70px;z-index:120;
    align-self:auto;height:auto;
    margin-bottom:30px;
  }
  .toc{
    position:static;max-height:none;
    background:var(--ivoire);
    border:1px solid rgba(26,26,46,.16);
    box-shadow:0 18px 40px -34px rgba(26,26,46,.6);
  }
  .toc__label{display:none}
  .toc__toggle{
    display:flex;align-items:center;justify-content:space-between;gap:12px;width:100%;
    background:none;border:0;cursor:pointer;font:inherit;
    padding:14px 18px;
    font-size:.72rem;letter-spacing:.18em;text-transform:uppercase;font-weight:700;
    color:var(--navy);
  }
  .toc__toggle .chev{
    width:9px;height:9px;border-right:1.5px solid var(--or);border-bottom:1.5px solid var(--or);
    transform:rotate(45deg) translateY(-2px);transition:transform .35s var(--ease);
  }
  .toc__toggle[aria-expanded="true"] .chev{transform:rotate(-135deg) translateY(-2px)}
  .toc__list{
    max-height:0;overflow:hidden;
    transition:max-height .4s var(--ease);
    padding-inline:18px;
  }
  .toc__list.open{max-height:52vh;overflow-y:auto;padding-bottom:16px}
  .toc__list a{padding-block:9px}
}

/* ---------- 7. Articles liés ---------- */
.rel-head{
  display:flex;justify-content:space-between;align-items:flex-end;gap:24px;flex-wrap:wrap;
  margin-bottom:clamp(30px,4vw,48px);
}

.rel-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:clamp(20px,2.6vw,34px)}

@media(max-width:980px){.rel-grid{grid-template-columns:repeat(2,1fr)}}

@media(max-width:640px){.rel-grid{grid-template-columns:1fr}}

.rel-card{
  display:flex;flex-direction:column;
  border-top:1px solid rgba(26,26,46,.18);padding-top:18px;
  opacity:0;transform:translateY(22px);
  transition:opacity .8s ease,transform .8s var(--ease);
}

.rel-card.in{opacity:1;transform:none}

.rel-card>a{display:flex;flex-direction:column;flex:1}

.rel-card__frame{
  position:relative;aspect-ratio:16/10;overflow:hidden;margin-bottom:16px;
  background:linear-gradient(120deg,var(--navy),var(--navy-deep));
}

.rel-card__frame img{
  width:100%;height:100%;object-fit:cover;
  transition:transform .7s var(--ease);
}

.rel-card:hover .rel-card__frame img{transform:scale(1.04)}

.rel-card__cat{
  font-size:.62rem;letter-spacing:.16em;text-transform:uppercase;font-weight:700;
  color:#8a6f3d;margin-bottom:8px;
}

.rel-card__title{
  font-family:var(--serif);font-weight:400;font-size:1.22rem;line-height:1.22;
  color:var(--navy);margin-bottom:10px;transition:color .3s var(--ease);
}

.rel-card:hover .rel-card__title{color:#8a6f3d}

.rel-card__excerpt{font-size:.94rem;line-height:1.6;color:var(--charbon);margin-bottom:14px}

.rel-card__meta{
  margin-top:auto;font-size:.68rem;letter-spacing:.14em;text-transform:uppercase;color:var(--gris);
}

.rel-sentinel{height:1px}

.rel-status{
  margin-top:34px;font-size:.78rem;letter-spacing:.14em;text-transform:uppercase;
  color:var(--gris);text-align:center;min-height:1.2em;
}

/* ---------- 8. Mouvement réduit ---------- */
@media(prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  .rel-card{opacity:1;transform:none}
  .read-progress__bar{background:var(--or)}
}

/* ---------- 9. Page de liste des articles ---------- */
.idx-bar{
  display:flex;align-items:center;justify-content:space-between;
  gap:20px 30px;flex-wrap:wrap;
  padding-bottom:26px;margin-bottom:clamp(34px,4.5vw,52px);
  border-bottom:1px solid rgba(26,26,46,.16);
}

.idx-filters{display:flex;flex-wrap:wrap;gap:9px}

.idx-filter{
  font-family:var(--sans);font-size:.68rem;letter-spacing:.14em;
  text-transform:uppercase;font-weight:700;
  padding:8px 16px;border-radius:100px;cursor:pointer;
  border:1px solid rgba(26,26,46,.2);background:transparent;color:var(--navy);
  transition:background .4s var(--ease),color .4s var(--ease),border-color .4s var(--ease);
}

.idx-filter:hover{border-color:var(--or)}

.idx-filter.active{background:var(--navy);color:var(--ivoire);border-color:var(--navy)}

.idx-count{
  font-size:.72rem;letter-spacing:.16em;text-transform:uppercase;
  color:var(--gris);margin:0;
}

/* Article à la une */
.idx-feature{margin-bottom:clamp(40px,5vw,64px)}

.idx-feature__link{
  display:grid;grid-template-columns:1.15fr .85fr;
  gap:clamp(24px,3.5vw,48px);align-items:center;
}

.idx-feature__frame{
  position:relative;aspect-ratio:16/9;overflow:hidden;
  background:linear-gradient(120deg,var(--navy),var(--navy-deep) 60%,#242440);
}

.idx-feature__frame::after{
  content:"";position:absolute;inset:0;
  background:radial-gradient(110% 90% at 85% 5%,rgba(200,169,110,.18),transparent 60%);
  pointer-events:none;
}

.idx-feature__frame img{
  width:100%;height:100%;object-fit:cover;position:relative;z-index:1;
  transition:transform .8s var(--ease);
}

.idx-feature__link:hover .idx-feature__frame img{transform:scale(1.03)}

.idx-feature__kicker{
  font-size:.68rem;letter-spacing:.18em;text-transform:uppercase;font-weight:700;
  color:#8a6f3d;margin-bottom:14px;
  display:inline-flex;align-items:center;gap:.7em;
}

.idx-feature__kicker::before{content:"";width:26px;height:1px;background:#8a6f3d;display:inline-block}

.idx-feature__title{
  font-family:var(--serif);font-weight:400;
  font-size:clamp(1.55rem,3.2vw,2.4rem);line-height:1.14;letter-spacing:-.01em;
  color:var(--navy);margin:0 0 14px;
  transition:color .35s var(--ease);
}

.idx-feature__link:hover .idx-feature__title{color:#8a6f3d}

.idx-feature__excerpt{
  font-size:1.02rem;line-height:1.65;color:var(--charbon);
  max-width:52ch;margin-bottom:16px;
}

@media(max-width:860px){
  .idx-feature__link{grid-template-columns:1fr;gap:20px}
}

/* La grille de la page de liste hérite de .rel-grid ; on n'ajuste
   que ce qui diffère du bloc « à lire ensuite ». */
.idx-grid{row-gap:clamp(34px,4vw,50px)}

/* ---------- 10. Conséquences de la 6e entrée de navigation ----------
   Le header passe de 5 à 6 liens. Mesure faite : brand (~180px) +
   6 entrées + 5 gouttières de 34px dépassent la largeur disponible
   entre 981px (seuil d'affichage de .nav) et ~1150px. On resserre la
   navigation sur cette plage plutôt que d'avancer le seuil du burger.
   À reporter dans style.css quand la 6e entrée sera ajoutée aux
   autres pages. */
@media(min-width:981px) and (max-width:1180px){
  .nav{gap:20px}
  .nav a{font-size:.78rem}
  .nav-cta{padding:9px 16px}
}

/* Le menu mobile compte désormais 6 liens : le 6e (nth-child(7), le
   bouton « Retour » occupant la 1re place) n'avait pas de délai et
   apparaissait en décalage du reste de la séquence. */
.menu.open a:nth-child(7){transition-delay:.48s}


.art-sign__share {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  color: var(--navy);
  background: transparent;
  transition: background 0.2s ease, color 0.2s ease;
}

.share-btn:hover,
.share-btn:focus-visible {
  background: var(--or);
  color: var(--ivoire);
}
