/* Refonte visuelle 2026 : identité plus éditoriale, construite sur les couleurs de rubrique.
   Chargée après responsive.css ; la retirer rend le site à son apparence précédente. */

/* ---------------------------------------------------------------------------------------------
   3. Bandeau défilant : prochains départs et derniers articles
   --------------------------------------------------------------------------------------------- */
.news-ticker { display: flex; align-items: stretch; border-bottom: 1px solid var(--border-subtle); background: var(--bg-surface); font-family: var(--font-mono); font-size: .74rem; overflow: hidden; }
.news-ticker-label { flex: none; display: flex; align-items: center; gap: 8px; padding: 0 16px; background: var(--text-primary); color: var(--text-inverse); font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.news-ticker-label::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--cat-gear); animation: pulseLive 1.2s infinite; }
.news-ticker-viewport { flex: 1; min-width: 0; overflow: hidden; mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent); }
.news-ticker-track { display: flex; width: max-content; animation: defilement 60s linear infinite; }
.news-ticker:hover .news-ticker-track, .news-ticker:focus-within .news-ticker-track { animation-play-state: paused; }
.news-ticker-item { display: inline-flex; align-items: center; gap: 10px; padding: 11px 22px; color: var(--text-secondary); white-space: nowrap; text-decoration: none; border-right: 1px solid var(--border-subtle); }
.news-ticker-item:hover { color: var(--text-primary); }
.news-ticker-item strong { color: var(--text-primary); font-weight: 800; }
.news-ticker-item[data-cat]::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--cat); }
@keyframes defilement { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* Cadrage des photos : les visages sont presque toujours dans le tiers haut. Recadrer au centre
   coupait la tête des coureurs sur les photos en hauteur ; on garde le haut de l’image. */
.card-img, .lead-story-bg, .spotlight-item img { object-position: center 25%; }

/* ---------------------------------------------------------------------------------------------
   5. Typographie plus affirmée
   --------------------------------------------------------------------------------------------- */
.home-intro-title { font-size: clamp(2.2rem, 5vw, 4rem); letter-spacing: -.04em; line-height: 1.02; }
.section-title { font-size: clamp(1.9rem, 3.4vw, 3rem); letter-spacing: -.035em; line-height: 1.05; }
.countdown-clock { font-size: 1.35rem; font-variant-numeric: tabular-nums; letter-spacing: .02em; }
.gear-card-score-badge { font-size: .95rem; padding: 6px 12px; }

/* ---------------------------------------------------------------------------------------------
   1. Une façon couverture de magazine
   --------------------------------------------------------------------------------------------- */
.lead-story-card { min-height: 600px; }
.lead-story-card .lead-story-bg { transition: transform 1.2s cubic-bezier(.2, .7, .2, 1); }
.lead-story-card:hover .lead-story-bg { transform: scale(1.04); }
.lead-story-card[data-cat] .lead-story-overlay {
  background:
    linear-gradient(180deg, rgba(5, 5, 7, 0) 25%, rgba(5, 5, 7, .72) 60%, rgba(5, 5, 7, .97) 100%),
    linear-gradient(100deg, color-mix(in srgb, var(--cat) 38%, transparent) 0%, transparent 55%);
}
.lead-story-card[data-cat]::after { content: ""; position: absolute; inset: auto 0 0; height: 6px; z-index: 4; background: var(--cat); }
.lead-rubrique { display: inline-flex; align-self: flex-start; margin-bottom: 14px; padding: 6px 12px; border-radius: 3px; background: var(--cat, #fff); color: #0b0b0c; font-family: var(--font-mono); font-size: .72rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.lead-title { font-size: clamp(2.2rem, 4.2vw, 3.9rem); line-height: 1.02; letter-spacing: -.04em; max-width: 16ch; }
.lead-subtitle { font-size: 1.12rem; max-width: 56ch; }

/* ---------------------------------------------------------------------------------------------
   2. Derniers articles en mosaïque : un grand, deux petits
   --------------------------------------------------------------------------------------------- */
@media (min-width: 701px) {
  #latestArticlesGrid { grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); grid-auto-rows: auto; gap: 22px; }
  #latestArticlesGrid .article-card:first-child { grid-row: span 2; }
  #latestArticlesGrid .article-card:first-child .card-img-wrap { padding-top: 62%; }
  #latestArticlesGrid .article-card:first-child .card-title { font-size: clamp(1.5rem, 2.2vw, 2.1rem); line-height: 1.12; letter-spacing: -.02em; }
  #latestArticlesGrid .article-card:not(:first-child) { display: grid; grid-template-columns: 42% minmax(0, 1fr); }
  #latestArticlesGrid .article-card:not(:first-child) .card-img-wrap { padding-top: 0; height: 100%; min-height: 200px; }
  #latestArticlesGrid .article-card:not(:first-child) .card-badge, #latestArticlesGrid .article-card:not(:first-child) .media-credit { display: none; }
  #latestArticlesGrid .article-card:not(:first-child) .card-body { padding: 18px 20px; }
  #latestArticlesGrid .article-card:not(:first-child) .card-excerpt { -webkit-line-clamp: 2; }
}
@media (max-width: 700px) {
  #latestArticlesGrid .article-card:first-child { display: flex; flex-direction: column; }
  #latestArticlesGrid .article-card:first-child .card-img-wrap { padding-top: 58%; height: auto; min-height: 0; }
  #latestArticlesGrid .article-card:first-child .card-badge { display: inline-flex; }
  #latestArticlesGrid .article-card:first-child .card-body { padding: 16px 16px 18px; }
  #latestArticlesGrid .article-card:first-child .card-title { font-size: 1.3rem; -webkit-line-clamp: 4; }
}

/* ---------------------------------------------------------------------------------------------
   4. Couleurs de rubrique au survol et en-têtes de page illustrés
   --------------------------------------------------------------------------------------------- */
.article-card[data-cat]:hover { border-color: var(--cat); box-shadow: 0 18px 40px -18px color-mix(in srgb, var(--cat) 55%, transparent); }
.article-card[data-cat] .card-title a { text-decoration: underline; text-decoration-color: transparent; text-decoration-thickness: 2px; text-underline-offset: 5px; transition: text-decoration-color .2s ease; }
.article-card[data-cat]:hover .card-title a { text-decoration-color: var(--cat); }

#feedSection > .container > .section-head:first-child,
#calendarSection > .container > .section-head:first-child,
#nearbySection > .container > .section-head:first-child {
  position: relative; isolation: isolate; overflow: hidden; align-items: flex-end;
  min-height: 250px; margin-bottom: 30px; padding: 40px 36px 34px; border-radius: var(--radius-sm);
  background: #0b0b0c var(--page-photo) center / cover no-repeat; color: #fff;
}
#feedSection > .container > .section-head:first-child::before,
#calendarSection > .container > .section-head:first-child::before,
#nearbySection > .container > .section-head:first-child::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(90deg, rgba(5, 5, 7, .92) 0%, rgba(5, 5, 7, .6) 55%, rgba(5, 5, 7, .25) 100%);
}
#feedSection { --page-photo: url("../assets/images/rubriques/actus.jpg"); }
#calendarSection { --page-photo: url("../assets/images/rubriques/agenda.jpg"); }
#nearbySection { --page-photo: url("../assets/images/rubriques/autour-de-moi-paris.jpg"); }
.section-head .section-title { color: inherit; }
.page-hero-text { margin: 12px 0 0; max-width: 46ch; color: rgba(255, 255, 255, .82); font-size: 1.05rem; line-height: 1.5; }
.lab-hero-banner { position: relative; }
@media (max-width: 700px) {
  #feedSection > .container > .section-head:first-child,
  #calendarSection > .container > .section-head:first-child,
  #nearbySection > .container > .section-head:first-child { min-height: 190px; padding: 26px 20px 24px; margin-inline: -4px; }
  .page-hero-text { font-size: .95rem; }
}

/* ---------------------------------------------------------------------------------------------
   6. Sections qui alternent
   --------------------------------------------------------------------------------------------- */
#latestSection { background: var(--bg-surface); border-block: 1px solid var(--border-subtle); }
.contact-section { background: var(--bg-body); }

/* ---------------------------------------------------------------------------------------------
   7. Apparition douce au défilement (activée par site.js, jamais sans JavaScript)
   --------------------------------------------------------------------------------------------- */
.apparition-active .apparition { opacity: 0; transform: translateY(22px); transition: opacity .7s ease, transform .7s cubic-bezier(.2, .7, .2, 1); transition-delay: var(--delai, 0ms); }
.apparition-active .apparition.est-visible { opacity: 1; transform: none; }
.rubrique-tile svg { transition: transform .3s ease; }
.rubrique-tile:hover svg { transform: translateY(-3px); }

/* ---------------------------------------------------------------------------------------------
   8. Pages article plus confortables
   --------------------------------------------------------------------------------------------- */
article[data-cat] .article-page-deck { position: relative; margin-top: 18px; padding: 18px 22px 18px 24px; border-left: 5px solid var(--cat); background: color-mix(in srgb, var(--cat) 9%, transparent); border-radius: 0 6px 6px 0; }
article[data-cat] .article-page-deck::before { content: "L’essentiel"; display: block; margin-bottom: 6px; color: var(--cat); font-family: var(--font-mono); font-size: .7rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
article[data-cat] .article-page-content > p:first-of-type::first-letter { float: left; margin: 5px 6px 0 -2px; color: var(--cat); font-family: var(--font-display); font-size: 3.7em; font-weight: 700; line-height: .82; }
.article-page-figure img { height: clamp(320px, 46vw, 620px); object-position: center 25%; }
.article-page-header h1 { font-size: clamp(2.2rem, 4.6vw, 4rem); letter-spacing: -.04em; line-height: 1.04; }

@media (prefers-reduced-motion: reduce) {
  .news-ticker-track { animation: none; }
  .news-ticker-viewport { overflow-x: auto; scrollbar-width: none; }
  .news-ticker-viewport::-webkit-scrollbar { display: none; }
  .apparition-active .apparition { opacity: 1; transform: none; }
}

/* Téléphone : la Une reste compacte, les lecteurs mobiles ne doivent pas défiler plus longtemps. */
@media (max-width: 700px) {
  .lead-story-card { min-height: 0; }
  .lead-title { font-size: 1.85rem; max-width: none; }
  .lead-subtitle { font-size: .98rem; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
  .lead-rubrique { margin-bottom: 10px; }
}
