
/* ==========================================================
   Refonte « Relief » (novembre 2026)
   Palette : calcaire & bleu club · police unique : Hanken Grotesk
   Ce bloc passe après tout le reste et remplace l'ancien style.
   ========================================================== */
@font-face {
  font-family: "Hanken Grotesk";
  src: url("../fonts/hanken-grotesk.woff2") format("woff2");
  font-weight: 100 900; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Hanken Grotesk";
  src: url("../fonts/hanken-grotesk-italic.woff2") format("woff2");
  font-weight: 100 900; font-style: italic; font-display: swap;
}

:root {
  --paper: #f4f6f8;
  --paper-2: #e9edf1;
  --surface: #ffffff;
  --ink: #16202a;
  --ink-2: #3a4652;
  --muted: #5d6875;
  --line: #dfe4ea;
  --accent: #1b78b8;
  --accent-ink: #155f93;
  --accent-soft: #e3eef7;
  --dark: #14324a;

  --gold: #d4a12a;
  --gold-2: #ecd08a;
  --silver: #9aa3ad;
  --silver-2: #d3d8de;
  --bronze: #b0794f;
  --bronze-2: #dcb08f;

  --sans: "Hanken Grotesk", "Helvetica Neue", Arial, sans-serif;
  --serif: var(--sans);
  --radius: 12px;
  --profile-h: clamp(64px, 10vw, 120px);
}

body { font-size: 16.5px; line-height: 1.6; }
a { text-decoration-color: color-mix(in srgb, currentColor 30%, transparent); }

/* Plus de petites capitales espacées : tout en casse normale */
.kicker, .section-title, .brand, .hero-name, .results-head, .r-mention,
.recit-card-meta, .page-title, .prose h2, .facts dt, .recit-title,
.recit-gear span, .recit-nav a span, .footer-name, .footer-coach span,
.recit-result, .card-badge, .press-meta, .podium-brand, .podium-model,
.shoe-card-brand, .goals-sub, .goal-date, .year-stats li, .yh-text strong,
.shoe-usage span, .pros-col h3, .shoe-table thead th, .bib-date {
  text-transform: none;
  letter-spacing: normal;
}

/* Titres */
.section-title { font-size: clamp(1.4rem, 2.4vw, 1.7rem); font-weight: 700; letter-spacing: -0.01em; }
.page-title, .recit-title { font-weight: 700; font-size: clamp(2.2rem, 5vw, 3.4rem); line-height: 1.05; letter-spacing: -0.02em; }
.year-title { font-weight: 700; font-size: 2rem; letter-spacing: -0.01em; }
.kicker { font-size: 1rem; font-weight: 500; color: var(--muted); }
.lede, .prose, .recit-chapo, .r-comment, .recit-card-chapo, .intro-text { font-family: var(--sans); }
.prose { font-size: 1.08rem; line-height: 1.7; }
.prose h2 { font-size: 1.35rem; font-weight: 700; letter-spacing: -0.01em; margin: 2em 0 0.6em; }

/* En-tête */
.brand { font-weight: 700; font-size: 1.05rem; }
.nav nav a { font-size: 0.95rem; font-weight: 500; }
.site-header { border-bottom-color: var(--line); }

/* ---------- Bandeau photo, coupé par un profil d'altitude ---------- */
.hero { height: min(86vh, 820px); background: var(--dark); }
.hero::after { background: linear-gradient(180deg, rgba(0,0,0,0.30) 0%, rgba(0,0,0,0) 26%, rgba(0,0,0,0) 48%, rgba(0,0,0,0.55) 100%); }
.hero-profile {
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  width: 100%;
  height: var(--profile-h);
  z-index: 3;
  fill: var(--paper);
  pointer-events: none;
}
.hero-text { bottom: calc(var(--profile-h) + clamp(0.5rem, 2vw, 1.5rem)); }
.hero-text .kicker { color: rgba(255,255,255,0.92); font-size: 1.05rem; margin-bottom: 0.4rem; }
.hero-name {
  font-weight: 700;
  font-size: clamp(2.8rem, 7.5vw, 5.4rem);
  line-height: 1;
  letter-spacing: -0.025em;
}
.carousel-hero .car-dots { left: auto; right: var(--gutter); transform: none; bottom: calc(var(--profile-h) + 1.2rem); }
.carousel-hero .car-slide figcaption { bottom: calc(var(--profile-h) + 2.6rem); }
.car-dots button { width: 18px; height: 3px; border-radius: 2px; }
.car-dots button[aria-selected="true"] { width: 26px; border-radius: 2px; }

/* ---------- Intro + cotes ---------- */
.intro { padding-top: clamp(1.2rem, 3vw, 2rem); grid-template-columns: 1.1fr 1fr; }
.intro-text { font-size: clamp(1.08rem, 1.5vw, 1.2rem); line-height: 1.65; text-align: left; hyphens: manual; -webkit-hyphens: manual; }
.scores {
  background: var(--surface);
  border: 0;
  border-radius: var(--radius);
  padding: 0.35rem;
}
.scores li + li { border-left: 1px solid var(--line); }
.scores a, .scores .score-static { border-radius: 8px; padding: 0.9rem 0.4rem; }
.scores a:hover { background: var(--paper); }
.score-num { font-weight: 700; font-size: 1.6rem; letter-spacing: -0.01em; }
.scores img { height: 22px; }

/* ---------- Blocs ---------- */
.block-head { border-bottom: 0; padding-bottom: 0.7rem; }
.more { color: var(--accent); font-weight: 600; font-size: 0.95rem; text-decoration: none; }
.more:hover { text-decoration: underline; }

/* ---------- Repères de podium (trait de couleur) ---------- */
.medal {
  display: inline-block;
  width: 4px !important;
  height: 1.05em !important;
  border-radius: 2px;
  background: var(--gold);
  vertical-align: -0.12em;
  flex-shrink: 0;
}
.medal-2 { background: var(--silver); }
.medal-3 { background: var(--bronze); }

.rank-num {
  display: inline-block;
  padding-left: 9px;
  border-left: 4px solid transparent;
  line-height: 1.15;
  font-weight: 700;
  font-size: 1rem;
  color: var(--muted);
}
.rank-num.is-p1 { border-left-color: var(--gold); color: var(--ink); }
.rank-num.is-p2 { border-left-color: var(--silver); color: var(--ink); }
.rank-num.is-p3 { border-left-color: var(--bronze); color: var(--ink); }
.rank-num sup { font-size: 0.65em; }

/* ---------- Tableau des résultats ---------- */
.results li { grid-template-columns: 52px 76px minmax(0, 1fr) 132px 72px 58px 58px 64px; padding: 1rem 0; }
.results-head { font-size: 0.82rem; border-bottom: 2px solid var(--ink) !important; }
.r-rank { justify-content: flex-start; }
.r-title { font-weight: 600; font-size: 1.03rem; }
.result.is-podium .r-title { font-weight: 600; }
.r-mention { font-size: 0.75rem; color: var(--accent-ink); border-radius: 999px; padding: 1px 8px; }
.r-comment { font-size: 0.96rem; }
.r-link { color: var(--accent); }
.r-dist .sep { display: none; }
.r-dist .r-dplus { display: block; color: var(--muted); font-size: 0.85rem; }
.tag-challenge {
  font-size: 0.74rem;
  letter-spacing: 0;
  color: var(--accent-ink);
  background: var(--accent-soft);
  border-radius: 999px;
  padding: 2px 9px;
}
a.tag-challenge:hover { background: var(--accent); color: #fff; }

/* ---------- Bande photos ---------- */
.photo-band { gap: 8px; }

/* ---------- Cartes du journal ---------- */
.recit-card img, .recit-card-bib { border-radius: 10px; }
.recit-card-bib { background: var(--dark); border-top: 0; color: #fff; }
.bib-big { font-weight: 700; letter-spacing: -0.02em; }
.bib-rank { font-weight: 700; }
.bib-rank.rank-num { color: #fff; font-size: 1.15rem; }
.bib-date { color: #a9b8c6; letter-spacing: 0; }
.bib-sub { color: #c4d0db; }
.recit-card:hover .recit-card-bib { border-top-color: transparent; }
.recit-card-meta { font-size: 0.85rem; color: var(--muted); }
.recit-card-title { font-weight: 700; font-size: 1.25rem; letter-spacing: -0.01em; margin: 0.2rem 0 0.35rem; }
.recit-card-chapo { color: var(--muted); font-size: 0.97rem; line-height: 1.5; }
.card-badge {
  left: 12px; top: 12px;
  gap: 0;
  padding: 4px 10px 4px 9px;
  background: rgba(255,255,255,0.95);
  color: var(--ink);
  border-left: 4px solid var(--gold);
  border-radius: 6px;
  font-size: 0.88rem;
}
.card-badge.is-p2 { border-left-color: var(--silver); }
.card-badge.is-p3 { border-left-color: var(--bronze); }
.card-badge.is-out { border-left-color: transparent; padding-left: 10px; }
.card-badge.is-win { border-bottom: 0; }
.card-badge sup { font-size: 0.65em; }

/* ---------- Boutons, filtres ---------- */
.button { border-radius: 8px; }
.button:hover { background: var(--accent); }
.journal-filter button, .profile-links a { border-radius: 999px; }

/* ---------- Pied de page ---------- */
.site-footer { background: var(--dark); color: #c9d3dd; }
.site-footer a { color: #fff; }
.site-footer a:hover { color: var(--gold-2); }
.footer-name { font-weight: 700; font-size: 1.1rem; }
.footer-coach span { font-size: 0.82rem; color: #9fb0c0; }
.footer-bottom-line hr { border-top-color: rgba(255,255,255,0.14); }
.footer-bottom { color: #8fa1b2; }

@media (max-width: 960px) {
  .intro { grid-template-columns: 1fr; }
  .results li { grid-template-columns: 48px 64px minmax(0, 1fr) 120px 66px; }
}
@media (max-width: 640px) {
  .results li { grid-template-columns: 44px minmax(0, 1fr) auto; }
  .r-dist .r-dplus { display: inline; font-size: inherit; }
  .r-dist .r-dplus::before { content: ", "; }
  .hero-name { font-size: clamp(2.4rem, 11vw, 3.2rem); }
}

/* Accueil : espacements et mobile */
.intro { padding-bottom: clamp(1rem, 3vw, 2rem); }
@media (max-width: 640px) {
  .brand { font-size: 0.8rem; }
  .nav nav { gap: 0.7rem; }
  .nav nav a { font-size: 0.8rem; }
  .carousel-hero .car-dots { display: none; }
  .score-num { font-size: 1.25rem; }
  .scores img { height: 16px; }
}
@media (max-width: 370px) {
  .brand { font-size: 0.7rem; }
  .nav nav a { font-size: 0.74rem; }
}

/* Petit profil d'altitude sous les cartes du journal */
.card-profile { display: block; width: 100%; height: 30px; margin: -0.3rem 0 0.6rem; }
.card-profile path { fill: none; stroke: var(--accent); stroke-width: 1.6; stroke-linejoin: round; opacity: 0.85; }
.recit-card:hover .card-profile path { opacity: 1; }

/* Profil d'altitude dans les récits */
.recit-profile { margin: 1.6rem 0 0; }
.recit-profile svg { display: block; width: 100%; height: 96px; }
.rp-area { fill: var(--accent-soft); }
.rp-line { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linejoin: round; }
.recit-profile figcaption { display: flex; justify-content: space-between; gap: 1rem; margin-top: 0.45rem; font-size: 0.85rem; color: var(--muted); font-variant-numeric: tabular-nums; }
@media (max-width: 640px) { .recit-profile svg { height: 72px; } }
.recit-profile-wrap { max-width: 1000px; margin: 0 auto; }
.recit-profile-wrap .recit-profile { margin-top: 0.8rem; }
@media (max-width: 640px) { .recit-profile-wrap { padding: 0 var(--gutter); } }

/* Graphiques : peloton, tendance, rangs par tronçon */
.ch-pel { fill: var(--muted); opacity: 0.32; }
.ch-me-line { stroke: var(--accent); stroke-width: 2; }
.ch-me-line.ch-old-me { stroke: var(--muted); stroke-dasharray: 4 3; }
.ch-trend { stroke: var(--ink-2); stroke-width: 1.2; stroke-dasharray: 5 4; opacity: 0.6; }
.ch .ch-val { font-size: 13px; fill: var(--ink-2); }
.ch .ch-lab-s { font-size: 14px; font-weight: 600; fill: var(--ink); }
.rk { fill: var(--surface); stroke: var(--line); stroke-width: 1.5; }
.rk-1 { fill: var(--accent-soft); stroke: var(--accent); stroke-width: 1.5; }
.rk-bad { fill: var(--gold); stroke: var(--gold); }
.ch .rk-t { font-size: 13px; font-weight: 700; fill: var(--ink-2); }
.ch .rk-t-on { fill: var(--ink); }
.ch .ch-unit { letter-spacing: 0; }
.chart-short svg { max-height: 300px; }
@media (max-width: 640px) {
  .ch .ch-lab-s { font-size: 19px; }
  .ch .rk-t { font-size: 17px; }
}

/* Récit : liens, repères sur le profil, la course en chiffres */
.recit-links { list-style: none; display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 1.1rem 0 0; padding: 0; }
.recit-links a { display: inline-block; padding: 0.35rem 0.85rem; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); font-size: 0.88rem; font-weight: 500; text-decoration: none; color: var(--accent-ink); }
.recit-links a:hover { border-color: var(--accent); color: var(--accent); }
.rp-plot { position: relative; }
.rp-climb { fill: none; stroke: var(--dark); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; }
.rp-pt {
  position: absolute; transform: translate(-50%, -50%);
  width: 20px; height: 20px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--surface); border: 2px solid var(--accent);
  font-size: 0.7rem; font-weight: 700; color: var(--accent-ink);
}
.rp-key { margin-left: 1rem; }
.rp-key::before { content: ""; display: inline-block; width: 14px; height: 4px; border-radius: 2px; background: var(--dark); vertical-align: middle; margin-right: 0.4rem; }
.race-data { margin-top: 2.2rem; }
.race-data-title { font-size: 1.35rem; font-weight: 700; letter-spacing: -0.01em; margin: 0 0 0.9rem; }
.rp-splits { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 0.6rem; }
.rp-splits li { display: grid; grid-template-columns: auto 1fr; column-gap: 0.6rem; align-items: center; background: var(--surface); border-radius: 10px; padding: 0.7rem 0.9rem; }
.rp-n { grid-row: span 2; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; border: 2px solid var(--accent); font-size: 0.72rem; font-weight: 700; color: var(--accent-ink); }
.rp-n.is-end { border-color: var(--ink); background: var(--ink); }
.rp-where { font-size: 0.82rem; color: var(--muted); }
.rp-what { font-weight: 600; font-size: 0.95rem; }
.rp-what sup { font-size: 0.65em; }
.race-facts { list-style: none; margin: 0.8rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 0.6rem; }
.race-facts li { background: var(--surface); border-radius: 10px; padding: 0.9rem 1rem 1rem; }
.race-facts p { margin: 0; }
.rf-title { font-weight: 700; font-size: 1rem; margin-bottom: 0.3rem !important; }
.rf-text { font-size: 0.92rem; line-height: 1.5; color: var(--ink-2); }
.rf-text b { color: var(--ink); font-weight: 700; }
@media (max-width: 800px) {
  .rp-splits { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .rp-pt { width: 17px; height: 17px; font-size: 0.62rem; }
  .rp-key { display: block; margin: 0.15rem 0 0; }
}
.race-facts li.is-season { box-shadow: inset 0 3px 0 var(--gold); }
.rf-tag { font-size: 0.75rem; font-weight: 600; color: #8a6a17; margin-bottom: 0.2rem !important; }
@media (min-width: 801px) { .race-facts:has(> li:nth-child(4)) { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.rp-n { grid-row: span 3; }
.rp-time { font-size: 0.82rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.rp-note { margin: 0.45rem 0 0; font-size: 0.8rem; color: var(--muted); }
