/* ============ La Thônaise — identité visuelle 2027 ============
   Forêt #1B3D34 · Sauge #8CA88B · Crème #F7F7EE · Terracotta #E67E42 · Charbon #2E2E2E
   Titres : Montserrat · Textes : DM Sans (auto-hébergées, sous-ensemble latin) */

@font-face { font-family: "Montserrat"; src: url("../fonts/montserrat-var.woff2") format("woff2"); font-weight: 500 900; font-style: normal; font-display: swap; }
@font-face { font-family: "DM Sans"; src: url("../fonts/dmsans-var.woff2") format("woff2"); font-weight: 400 700; font-style: normal; font-display: swap; }
@font-face { font-family: "DM Sans"; src: url("../fonts/dmsans-italic-var.woff2") format("woff2"); font-weight: 400 700; font-style: italic; font-display: swap; }

:root {
  --foret: #1b3d34;
  --foret-2: #24503f;
  --sauge: #8ca88b;
  --sauge-pale: #e3ebe0;
  --creme: #f7f7ee;
  --creme-2: #efeee2;
  --terra: #e67e42;
  --terra-fonce: #b9561d; /* texte terracotta lisible sur crème (AA) */
  --terra-titre: #c9622a; /* grands titres terracotta sur fond clair (AA grand texte, 3,7:1) */
  --terra-clair: #f4b38a; /* texte terracotta sur fond forêt (AA, 7:1) */
  --charbon: #2e2e2e;
  --gris: #5d625e;
  --ligne: #d9dccf;
  --blanc: #ffffff;
  --rouge: #b3261e;
  --radius: 18px;
  --radius-sm: 12px;
  --ombre: 0 1px 2px rgba(27, 61, 52, .06), 0 8px 24px rgba(27, 61, 52, .08);
  --ombre-forte: 0 2px 4px rgba(27, 61, 52, .08), 0 16px 40px rgba(27, 61, 52, .14);
  --titre: "Montserrat", "Segoe UI", system-ui, sans-serif;
  --texte: "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --header-h: 76px;
  --topo: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='600' height='300' viewBox='0 0 600 300' fill='none' stroke='%238CA88B' stroke-width='1.2' opacity='.32'%3E%3Cpath d='M-10 60c80-40 160 30 240 0s160-50 240-10 100 20 140 0'/%3E%3Cpath d='M-10 95c90-35 150 30 250 2s150-45 240-8 90 18 130 2'/%3E%3Cpath d='M-10 130c100-30 140 30 260 4s140-40 240-6 80 16 120 4'/%3E%3Cpath d='M-10 200c70 30 170-20 250 6s170 40 250 8 80-12 110-4'/%3E%3Cpath d='M-10 235c80 26 160-18 260 8s160 34 240 6 70-10 110-2'/%3E%3Cpath d='M-10 270c90 22 150-16 270 10s150 28 230 4 60-8 110 0'/%3E%3C/svg%3E");
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition: none !important; animation: none !important; } }
body { margin: 0; font-family: var(--texte); color: var(--charbon); background: var(--creme); line-height: 1.65; font-size: 17px; text-rendering: optimizeLegibility; }
img, svg, video, iframe { max-width: 100%; display: block; }
img { height: auto; }
a { color: var(--foret); font-weight: 600; text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
a:hover { color: var(--terra-fonce); }
:focus-visible { outline: 3px solid var(--terra); outline-offset: 2px; border-radius: 6px; }

h1, h2, h3, h4 { font-family: var(--titre); font-weight: 800; color: var(--foret); line-height: 1.15; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(2.3rem, 5.5vw, 4rem); font-weight: 900; text-transform: uppercase; letter-spacing: -.005em; }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); }
h3 { font-size: 1.3rem; }
h4 { font-size: 1.1rem; }
p { margin: 0 0 1em; }

.container { width: min(1180px, 92%); margin: 0 auto; }
.etroit { max-width: 860px; }
section { padding: clamp(56px, 8vw, 96px) 0; position: relative; }
.section-alt { background: var(--creme-2); }
.section-topo { background-color: var(--creme); background-image: var(--topo); background-size: 600px 300px; }
.section-foret { background: var(--foret); color: var(--creme); }
.section-foret h2, .section-foret h3 { color: var(--creme); }
.section-foret a:not(.btn) { color: #f4b38a; }
.center { text-align: center; }
.muted { color: var(--gris); }
.small { font-size: .9rem; }
.cache { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 3000; background: var(--foret); color: var(--creme); padding: 10px 16px; border-radius: 10px; }
.skip:focus { top: 12px; color: var(--creme); }

/* Sur-titre façon logo : TRAIL • ENVIRONNEMENT • TCA */
.kicker { display: inline-flex; align-items: center; gap: 10px; font-family: var(--titre); font-weight: 700; font-size: .8rem; letter-spacing: .22em; text-transform: uppercase; color: var(--foret); margin-bottom: 14px; }
.kicker .point, .baseline .point { width: 6px; height: 6px; border-radius: 50%; background: var(--terra); display: inline-block; }
.section-foret .kicker { color: var(--sauge); }

.titre-section { text-align: center; margin: 0 auto 44px; max-width: 720px; }
.titre-section h2 { margin-bottom: 12px; }
.titre-section p { color: var(--gris); margin: 0; }
.titre-section.gauche { text-align: left; margin-left: 0; }
.section-foret .titre-section p { color: #cfdccd; }
.trait { display: block; width: 64px; height: 4px; border-radius: 4px; background: var(--terra); margin: 14px auto 0; }
.titre-section.gauche .trait { margin-left: 0; }

/* ---------------- Header ---------------- */
#header { min-height: var(--header-h); } /* réserve la place : pas de saut de mise en page */
.site-header { position: sticky; top: 0; z-index: 1000; background: rgba(247, 247, 238, .92); backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--ligne); }
.site-header .container { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); gap: 16px; }
.logo img { height: 54px; width: auto; }
.nav { display: flex; gap: 2px; align-items: center; }
.nav a { text-decoration: none; color: var(--charbon); padding: 8px 11px; border-radius: 10px; font-weight: 600; font-size: .94rem; white-space: nowrap; }
.nav a:hover, .nav a.actif { color: var(--foret); background: var(--sauge-pale); }
.nav a.actif { box-shadow: inset 0 -2px 0 var(--terra); border-radius: 10px 10px 4px 4px; }
.nav .nav-actions { display: flex; gap: 8px; margin-left: 10px; }
.nav .nav-actions a.btn { padding: 9px 16px; }
.burger { display: none; background: none; border: 1.5px solid var(--foret); color: var(--foret); border-radius: 10px; width: 44px; height: 44px; cursor: pointer; place-items: center; }
.burger svg { width: 22px; height: 22px; }

@media (max-width: 1180px) {
  .burger { display: grid; }
  .nav { display: none; position: absolute; top: var(--header-h); left: 0; right: 0; flex-direction: column; align-items: stretch; background: var(--creme); border-bottom: 1px solid var(--ligne); padding: 12px 4% 18px; box-shadow: var(--ombre-forte); max-height: calc(100vh - var(--header-h)); overflow-y: auto; }
  .nav.ouvert { display: flex; }
  .nav a { padding: 12px 14px; font-size: 1rem; }
  .nav .nav-actions { margin: 10px 0 0; }
  .nav .nav-actions a.btn { flex: 1; text-align: center; }
}

/* ---------------- Boutons ---------------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; font-family: var(--titre); font-weight: 700; font-size: .95rem; letter-spacing: .04em; text-transform: uppercase; padding: 13px 24px; border: 2px solid var(--terra); border-radius: 999px; cursor: pointer; background: var(--terra); color: var(--charbon) !important; text-decoration: none; transition: transform .15s, box-shadow .15s, background .15s, color .15s; line-height: 1.2; }
.btn:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(230, 126, 66, .35); background: #ec8f58; border-color: #ec8f58; } /* plus clair : le texte charbon reste lisible (AA) */
.btn:active { transform: translateY(0); box-shadow: none; }
.btn-foret { background: var(--foret); border-color: var(--foret); color: var(--creme) !important; }
.btn-foret:hover { background: var(--foret-2); border-color: var(--foret-2); box-shadow: 0 8px 20px rgba(27, 61, 52, .3); }
.btn-ligne { background: transparent; color: var(--foret) !important; border-color: var(--foret); }
.btn-ligne:hover { background: var(--foret); color: var(--creme) !important; border-color: var(--foret); box-shadow: none; }
.btn-creme { background: var(--creme); color: var(--foret) !important; border-color: var(--creme); }
.btn-creme:hover { background: var(--blanc); border-color: var(--blanc); box-shadow: 0 8px 20px rgba(0, 0, 0, .2); }
.btn-ligne-creme { background: transparent; color: var(--creme) !important; border-color: var(--creme); }
.btn-ligne-creme:hover { background: var(--creme); color: var(--foret) !important; box-shadow: none; }
.btn-sm { font-size: .8rem; padding: 9px 16px; }
.btn[disabled], .btn.desactive { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; pointer-events: none; }
.btn svg { width: 18px; height: 18px; flex: none; }
.lien-fleche { font-family: var(--titre); font-weight: 700; font-size: .9rem; text-transform: uppercase; letter-spacing: .06em; text-decoration: none; }
.lien-fleche::after { content: " →"; transition: margin .15s; }
.lien-fleche:hover::after { margin-left: 4px; }

/* ---------------- Hero ---------------- */
.hero { padding: clamp(36px, 6vw, 72px) 0 clamp(120px, 14vw, 190px); background-color: var(--creme); background-image: var(--topo); background-size: 600px 300px; overflow: hidden; }
.hero .container { display: grid; grid-template-columns: 1fr 1.05fr; gap: clamp(24px, 4vw, 56px); align-items: center; position: relative; z-index: 2; }
.hero-badge { display: inline-block; background: var(--foret); color: var(--creme); font-family: var(--titre); font-weight: 700; font-size: .8rem; letter-spacing: .14em; text-transform: uppercase; padding: 7px 14px; border-radius: 999px; margin-bottom: 18px; }
.hero h1 { margin-bottom: 14px; }
.hero h1 .accent { color: var(--terra-titre); }
.hero .chapo { font-size: 1.2rem; color: var(--gris); margin-bottom: 26px; max-width: 34em; }
.hero-infos { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 26px; }
.pill { display: inline-flex; align-items: center; gap: 8px; background: var(--blanc); border: 1px solid var(--ligne); border-radius: 999px; padding: 8px 16px; font-weight: 600; box-shadow: var(--ombre); }
.pill svg { width: 18px; height: 18px; color: var(--terra); flex: none; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px 24px; align-items: center; }
.actions-centre { align-items: center; }
.hero-visuel img { width: 100%; max-width: 640px; margin: 0 auto; }
.montagnes { position: absolute; left: 0; right: 0; bottom: -1px; width: 100%; height: clamp(90px, 12vw, 170px); z-index: 1; pointer-events: none; }
@media (max-width: 880px) {
  .hero .container { grid-template-columns: 1fr; text-align: center; }
  .hero-visuel { order: -1; }
  .hero-visuel img { max-width: 460px; }
  .hero .chapo { margin-left: auto; margin-right: auto; }
  .hero-infos, .hero-actions, .hero .countdown { justify-content: center; }
}

/* ---------------- Compte à rebours ---------------- */
.countdown { display: flex; gap: 10px; margin-bottom: 28px; flex-wrap: wrap; }
.countdown div { background: var(--foret); color: var(--creme); border-radius: 14px; padding: 10px 12px; min-width: 76px; text-align: center; }
.countdown b { display: block; font-family: var(--titre); font-weight: 800; font-size: 1.9rem; line-height: 1.1; font-variant-numeric: tabular-nums; }
.countdown small { font-size: .7rem; text-transform: uppercase; letter-spacing: .14em; color: var(--sauge); }
@media (max-width: 420px) { .countdown { gap: 6px; } .countdown div { min-width: 0; flex: 1; padding: 8px 4px; } .countdown b { font-size: 1.5rem; } }

/* ---------------- Bandeau chiffres ---------------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; text-align: center; }
.stat b { display: block; font-family: var(--titre); font-weight: 900; font-size: clamp(2rem, 4vw, 2.8rem); color: var(--creme); line-height: 1.05; }
.stat b .unite { font-size: .5em; font-weight: 700; color: var(--terra); margin-left: 2px; }
.stat span { font-size: .92rem; color: #cfdccd; }
.bande-stats { padding: 44px 0; }
@media (max-width: 760px) { .stats { grid-template-columns: repeat(2, 1fr); row-gap: 28px; } }

/* ---------------- Grilles & cartes ---------------- */
.grille { display: grid; gap: 24px; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); }
.grille-3 { display: grid; gap: 24px; grid-template-columns: repeat(auto-fill, minmax(min(310px, 100%), 1fr)); }
.grille-2 { display: grid; gap: 32px; grid-template-columns: repeat(auto-fit, minmax(min(360px, 100%), 1fr)); }
.carte { background: var(--blanc); border: 1px solid var(--ligne); border-radius: var(--radius); padding: 26px; box-shadow: var(--ombre); }
.carte h3 { margin-top: 0; }
.carte > :last-child { margin-bottom: 0; }
.carte-icone { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 14px; background: var(--sauge-pale); color: var(--foret); margin-bottom: 14px; }
.carte-icone svg { width: 28px; height: 28px; }

.carte-course { display: flex; flex-direction: column; overflow: hidden; padding: 0; transition: transform .2s, box-shadow .2s; }
.carte-course:hover { transform: translateY(-4px); box-shadow: var(--ombre-forte); }
.carte-course .bandeau { position: relative; background: var(--foret); color: var(--creme); padding: 22px 24px 46px; overflow: hidden; }
.carte-course .bandeau::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 38px; background: var(--blanc); clip-path: polygon(0 100%, 0 70%, 12% 40%, 22% 62%, 38% 10%, 52% 55%, 63% 30%, 78% 66%, 90% 36%, 100% 58%, 100% 100%); }
.carte-course:nth-child(3n+2) .bandeau { background: var(--sauge); color: var(--foret); }
.carte-course:nth-child(3n+2) .bandeau h3 { color: var(--foret); }
.carte-course:nth-child(3n) .bandeau { background: var(--terra); color: var(--charbon); }
.carte-course:nth-child(3n) .bandeau h3 { color: var(--foret); }
.carte-course .bandeau h3 { margin: 0; color: var(--creme); font-size: 1.35rem; }
.carte-course .format { font-family: var(--titre); font-weight: 700; font-size: .75rem; letter-spacing: .18em; text-transform: uppercase; opacity: .9; }
.carte-course .corps { padding: 6px 24px 24px; display: flex; flex-direction: column; flex: 1; }
.carte-course .corps p { flex: 1; color: var(--gris); }
.carte-course .pied { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.carte-course .prix { font-family: var(--titre); font-weight: 800; font-size: 1.3rem; color: var(--foret); }
.chiffres { display: flex; gap: 10px; margin: 0 0 16px; flex-wrap: wrap; }
.chiffre { background: var(--creme); border-radius: 12px; padding: 8px 10px; text-align: center; flex: 1; min-width: 72px; }
.chiffre b { display: block; font-family: var(--titre); font-weight: 800; font-size: 1.35rem; line-height: 1.1; color: var(--foret); }
.chiffre small { font-size: .75rem; color: var(--gris); font-weight: 600; }

/* Deux causes */
.causes { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
@media (max-width: 760px) { .causes { grid-template-columns: 1fr; } }
.cause { border-radius: var(--radius); padding: 32px; position: relative; overflow: hidden; display: flex; flex-direction: column; }
.cause p { flex: 1; }
.cause-env { background: var(--foret); color: var(--creme); }
.cause-env h3 { color: var(--creme); }
.cause-tca { background: var(--blanc); border: 1px solid var(--ligne); box-shadow: var(--ombre); }
.cause .pourcent { font-family: var(--titre); font-weight: 900; font-size: 3rem; line-height: 1; color: var(--terra); margin-bottom: 6px; }
.cause-tca .pourcent { color: var(--terra-titre); }
.cause .actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 8px; }
.cause-deco { position: absolute; right: -12px; bottom: -12px; width: 150px; height: 150px; opacity: .14; pointer-events: none; }

/* ---------------- Tableaux ---------------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--ligne); border-radius: var(--radius); box-shadow: var(--ombre); background: var(--blanc); }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 14px 18px; text-align: left; border-bottom: 1px solid var(--ligne); }
th { background: var(--foret); color: var(--creme); font-family: var(--titre); font-weight: 700; font-size: .85rem; letter-spacing: .06em; text-transform: uppercase; }
tr:last-child td { border-bottom: none; }
tbody tr:hover { background: var(--creme); }
.carte table td { padding: 10px 0; }

/* ---------------- Listes ---------------- */
.liste-check { list-style: none; padding: 0; margin: 0; }
.liste-check li { padding: 7px 0 7px 34px; position: relative; }
.liste-check li::before { content: ""; position: absolute; left: 0; top: 10px; width: 22px; height: 22px; border-radius: 50%; background: var(--foret) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23F7F7EE' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4 8-9'/%3E%3C/svg%3E") center/14px no-repeat; }
.liste-check.terra li::before { background: var(--terra) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3.2' stroke-linecap='round'%3E%3Cpath d='M12 6v12M6 12h12'/%3E%3C/svg%3E") center/13px no-repeat; }
.section-foret .liste-check li::before { background-color: var(--terra); }

/* ---------------- Onglets courses ---------------- */
.onglets { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-bottom: 32px; }
.onglet { font-family: var(--titre); font-weight: 700; font-size: .9rem; padding: 11px 20px; border: 1.5px solid var(--foret); border-radius: 999px; background: transparent; color: var(--foret); cursor: pointer; transition: background .15s, color .15s; }
.onglet:hover { background: var(--sauge-pale); }
.onglet.actif { background: var(--foret); color: var(--creme); }

/* ---------------- Carte Leaflet + profil ---------------- */
/* Sélecteur de calques Leaflet : neutralise les styles de formulaire du site */
.leaflet-control-layers label { display: block; margin: 0; font-weight: 500; font-size: .85rem; line-height: 1.5; cursor: pointer; }
.leaflet-control-layers input { width: auto; padding: 0; margin: 0 6px 0 0; border: 0; border-radius: 0; box-shadow: none; vertical-align: -1px; accent-color: var(--foret); }
.leaflet-control-layers-expanded { padding: 8px 12px; border-radius: 10px; }
.legende-carte { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 12px 0 0; font-size: .9rem; }
.legende-carte a { color: var(--charbon); text-decoration: none; }
.legende-carte a:hover { text-decoration: underline; }
.legende-carte i { display: inline-block; width: 18px; height: 5px; border-radius: 3px; margin-right: 7px; vertical-align: middle; }
.map { height: 440px; border-radius: var(--radius); box-shadow: var(--ombre); z-index: 1; background: var(--creme-2); border: 1px solid var(--ligne); }
.profil-wrap { position: relative; margin-top: 24px; background: var(--blanc); border: 1px solid var(--ligne); border-radius: var(--radius); box-shadow: var(--ombre); padding: 18px 18px 10px; }
.profil-wrap h3 { font-size: 1.1rem; margin: 0 0 6px; }
.profil-svg { width: 100%; height: 220px; display: block; }
.profil-svg .grid line { stroke: var(--ligne); stroke-width: 1; }
.profil-tooltip { position: absolute; pointer-events: none; background: var(--foret); color: var(--creme); font-size: .85rem; padding: 6px 10px; border-radius: 8px; white-space: nowrap; transform: translate(-50%, -115%); display: none; }
.vide-parcours { border: 2px dashed var(--sauge); border-radius: var(--radius); padding: 50px 20px; text-align: center; color: var(--gris); background: var(--blanc); }

/* ---------------- Formulaires ---------------- */
form .champ { margin-bottom: 16px; }
form label { display: block; font-weight: 600; margin-bottom: 6px; }
input, select, textarea { width: 100%; font: inherit; color: inherit; padding: 12px 14px; border: 1.5px solid #858b80; /* bordure contrastée 3:1 (WCAG 1.4.11) */ border-radius: 12px; background: var(--blanc); transition: border-color .15s, box-shadow .15s; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--foret); box-shadow: 0 0 0 4px rgba(140, 168, 139, .35); }
.ligne { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 560px) { .ligne { grid-template-columns: 1fr; } }
.radios { display: flex; gap: 8px; flex-wrap: wrap; }
.radios label { font-weight: 600; border: 1.5px solid #858b80; border-radius: 999px; padding: 8px 16px; cursor: pointer; margin: 0; background: var(--blanc); transition: all .15s; }
.radios input { position: absolute; opacity: 0; pointer-events: none; }
.radios label:has(input:checked) { background: var(--foret); color: var(--creme); border-color: var(--foret); }
.radios label:has(input:focus-visible) { outline: 3px solid var(--terra); outline-offset: 2px; }
.checkbox { display: flex; gap: 10px; align-items: flex-start; font-weight: 400 !important; }
.checkbox input { width: auto; margin-top: 5px; accent-color: var(--foret); }
input[aria-invalid="true"], select[aria-invalid="true"], textarea[aria-invalid="true"] { border-color: var(--rouge); background: #fff8f7; }
.checkbox input[aria-invalid="true"] { outline: 2px solid var(--rouge); outline-offset: 2px; }
.alerte ul { margin: 6px 0 0; padding-left: 1.2em; }
/* Champ piège anti-robots : invisible pour les humains et les lecteurs d'écran */
.piege { position: absolute !important; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.autocomplete { position: relative; }
.suggestions { position: absolute; top: 100%; left: 0; right: 0; z-index: 50; background: var(--blanc); border: 1.5px solid var(--foret); border-top: none; border-radius: 0 0 12px 12px; list-style: none; margin: 0; padding: 0; max-height: 220px; overflow-y: auto; box-shadow: var(--ombre); }
.suggestions li { padding: 9px 14px; cursor: pointer; }
.suggestions li:hover, .suggestions li.focus { background: var(--sauge-pale); }

/* ---------------- Alertes ---------------- */
.alerte { border-radius: var(--radius-sm); padding: 14px 18px; margin-bottom: 20px; background: var(--blanc); border-left: 5px solid var(--sauge); }
.alerte.info { background: #eef3ec; border-color: var(--foret); }
.alerte.ok { background: var(--sauge-pale); border-color: var(--foret); }
.alerte.warn { background: #fdf0e6; border-color: var(--terra); }
.alerte.err { background: #fbe9e7; border-color: var(--rouge); }

/* ---------------- Covoiturage ---------------- */
.covoit-layout { display: grid; grid-template-columns: 390px 1fr; gap: 28px; align-items: start; }
@media (max-width: 920px) { .covoit-layout { grid-template-columns: 1fr; } }
.covoit-form { position: sticky; top: calc(var(--header-h) + 16px); }
@media (max-width: 920px) { .covoit-form { position: static; } }
.filtres { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 18px; align-items: center; }
.filtres > * { width: auto; flex: 1; min-width: 150px; }
.stats-covoit { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 20px; }
.stats-covoit .chiffre { background: var(--blanc); border: 1px solid var(--ligne); }
.trajets { display: grid; gap: 16px; }
.trajet { background: var(--blanc); border: 1px solid var(--ligne); border-radius: var(--radius); padding: 18px 20px; box-shadow: var(--ombre); display: grid; grid-template-columns: 1fr auto; gap: 10px 16px; }
.trajet.demande { border-style: dashed; border-color: var(--sauge); }
.trajet .type { display: inline-block; font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; padding: 3px 10px; border-radius: 999px; margin-right: 6px; }
.type.offre { background: var(--foret); color: var(--creme); }
.type.demande { background: var(--terra); color: var(--charbon); }
.type.sens { background: var(--creme-2); }
.trajet h4 { margin: 8px 0 4px; font-size: 1.15rem; }
.trajet .meta { color: var(--gris); font-size: .92rem; display: flex; flex-wrap: wrap; gap: 4px 16px; }
.trajet .places { text-align: center; }
.trajet .places b { font-family: var(--titre); font-weight: 800; font-size: 2rem; display: block; line-height: 1; color: var(--foret); }
.trajet .places.complet b { color: var(--rouge); }
.trajet .actions { grid-column: 1 / -1; display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.trajet .contact-revele { background: var(--sauge-pale); border-radius: 10px; padding: 8px 12px; font-weight: 600; }
.trajet .comment { grid-column: 1 / -1; font-style: italic; margin: 0; }
.distance-badge { background: var(--foret); color: var(--creme); border-radius: 8px; padding: 1px 8px; font-weight: 700; font-size: .85rem; }

/* ---------------- Modal ---------------- */
.modal-fond { position: fixed; inset: 0; background: rgba(27, 61, 52, .55); z-index: 2000; display: none; align-items: center; justify-content: center; padding: 20px; }
.modal-fond.ouvert { display: flex; }
.modal { max-width: 460px; width: 100%; }

/* ---------------- FAQ (details) ---------------- */
details { background: var(--blanc); border: 1px solid var(--ligne); border-radius: var(--radius-sm); margin-bottom: 12px; box-shadow: var(--ombre); }
summary { cursor: pointer; padding: 16px 52px 16px 20px; font-weight: 700; list-style: none; position: relative; }
summary::-webkit-details-marker { display: none; }
summary::after { content: ""; position: absolute; right: 20px; top: 50%; width: 12px; height: 12px; border-right: 2.5px solid var(--terra); border-bottom: 2.5px solid var(--terra); transform: translateY(-70%) rotate(45deg); transition: transform .2s; }
details[open] summary::after { transform: translateY(-30%) rotate(-135deg); }
details > div { padding: 0 20px 18px; }

/* ---------------- Partenaires ---------------- */
.partenaires { display: flex; flex-wrap: wrap; gap: 20px; justify-content: center; align-items: center; }
.partenaire { background: var(--blanc); border: 1px solid var(--ligne); border-radius: var(--radius-sm); padding: 16px; width: 180px; height: 116px; display: grid; place-items: center; box-shadow: var(--ombre); text-decoration: none; color: var(--charbon); text-align: center; }
.partenaire { transition: transform .2s, box-shadow .2s; }
.partenaire:hover { transform: translateY(-3px); }
.partenaire img { width: 100%; height: 100%; max-height: 80px; object-fit: contain; }
.bandeau-soutiens .partenaire { width: 220px; height: 130px; padding: 18px 22px; }
.actions-centre { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 32px; }
.pack { display: flex; flex-direction: column; }
.pack .tarif { font-family: var(--titre); font-weight: 900; font-size: 2.2rem; color: var(--terra-fonce); line-height: 1; margin: 4px 0 16px; }
.pack.majeur { border: 2px solid var(--terra); position: relative; }
.pack.majeur::before { content: "Partenaire majeur"; position: absolute; top: -13px; left: 24px; background: var(--terra); color: var(--charbon); font-family: var(--titre); font-weight: 700; font-size: .7rem; letter-spacing: .12em; text-transform: uppercase; padding: 4px 10px; border-radius: 999px; }

/* ---------------- En-tête de page ---------------- */
.page-header { background: var(--foret); color: var(--creme); padding: clamp(44px, 6vw, 72px) 0 clamp(80px, 9vw, 120px); text-align: center; position: relative; overflow: hidden; }
.page-header::before { content: ""; position: absolute; inset: 0; background-image: var(--topo); background-size: 600px 300px; opacity: .35; }
.page-header .container { position: relative; z-index: 2; }
.page-header h1 { color: var(--creme); font-size: clamp(2rem, 5vw, 3.3rem); margin-bottom: 10px; }
.page-header p { font-size: 1.15rem; margin: 0 auto; color: #d6e2d4; max-width: 640px; }
.page-header .kicker { color: var(--sauge); }
.page-header .montagnes { height: clamp(50px, 7vw, 90px); }

/* ---------------- Bandeau CTA ---------------- */
.cta { background: var(--terra); color: var(--charbon); text-align: center; overflow: hidden; }
.cta h2 { color: var(--foret); margin-bottom: 10px; }
.cta p { max-width: 620px; margin: 0 auto 22px; font-weight: 500; }

/* ---------------- Actus ---------------- */
.actu { display: flex; flex-direction: column; overflow: hidden; padding: 0; }
.actu .vignette { aspect-ratio: 16 / 9; background: var(--sauge-pale); overflow: hidden; }
.actu .vignette img { width: 100%; height: 100%; object-fit: cover; }
.actu .vignette.vide { display: grid; place-items: center; background: var(--foret) var(--topo); background-size: 600px 300px; }
.actu .vignette.vide img { width: 64px; height: 64px; object-fit: contain; border-radius: 14px; }
.actu .corps { padding: 22px 24px 24px; display: flex; flex-direction: column; flex: 1; }
.actu .meta { display: flex; gap: 10px; align-items: center; font-size: .82rem; color: var(--gris); margin-bottom: 8px; }
.tag { background: var(--sauge-pale); color: var(--foret); font-weight: 700; font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; padding: 3px 10px; border-radius: 999px; }
.actu h3 { font-size: 1.2rem; }
.actu p { color: var(--gris); flex: 1; }
.actu-longue { display: grid; grid-template-columns: 340px 1fr; gap: 0; }
.actu-longue .vignette { aspect-ratio: auto; min-height: 100%; }
.actu-longue p { flex: none; }
@media (max-width: 760px) { .actu-longue { grid-template-columns: 1fr; } .actu-longue .vignette { aspect-ratio: 16 / 9; } }
.liste-actus { display: grid; gap: 24px; }

/* ---------------- Réseaux sociaux ---------------- */
.reseaux-liens { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }
.reseau-btn { display: inline-flex; align-items: center; gap: 10px; padding: 12px 20px; border-radius: 999px; background: var(--blanc); border: 1px solid var(--ligne); color: var(--foret); text-decoration: none; font-weight: 700; box-shadow: var(--ombre); transition: transform .15s, box-shadow .15s; }
.reseau-btn:hover { transform: translateY(-2px); box-shadow: var(--ombre-forte); color: var(--foret); }
.reseau-btn svg { width: 22px; height: 22px; }
.reseau-btn small { font-weight: 500; color: var(--gris); }
.section-foret a.reseau-btn { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .18); color: var(--creme); box-shadow: none; }
.section-foret .reseau-btn small { color: var(--sauge); }
.section-foret a.reseau-btn:hover { background: rgba(255, 255, 255, .16); color: var(--creme); }
.bloc-reseau { margin-bottom: 56px; }
.bloc-reseau:last-child { margin-bottom: 0; }
.bloc-reseau-tete { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.bloc-reseau-tete h3 { display: flex; align-items: center; gap: 12px; margin: 0; font-size: 1.5rem; }
.bloc-reseau-tete h3 svg { width: 32px; height: 32px; }
.grille-insta { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(200px, 46%), 1fr)); gap: 12px; }
.grille-insta a { position: relative; aspect-ratio: 1; border-radius: 14px; overflow: hidden; background: var(--sauge-pale); }
.grille-insta img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.grille-insta a:hover img { transform: scale(1.05); }
.grille-insta .badge-video { position: absolute; top: 8px; right: 8px; background: rgba(0,0,0,.55); color: #fff; border-radius: 8px; padding: 2px 6px; font-size: .75rem; }
.embeds { display: grid; gap: 20px; grid-template-columns: repeat(auto-fill, minmax(min(330px, 100%), 1fr)); align-items: start; }
.embeds blockquote { margin: 0 !important; }
.consentement { border: 2px dashed var(--sauge); border-radius: var(--radius); background: var(--blanc); padding: 36px 24px; text-align: center; }
.consentement p { max-width: 560px; margin: 0 auto 16px; color: var(--gris); font-size: .95rem; }
.consentement .checkbox { justify-content: center; margin-top: 14px; font-size: .9rem; }

/* ---------------- Vidéos (façade légère : rien n'est chargé avant le clic) ---------------- */
.video { position: relative; aspect-ratio: 16 / 9; border-radius: 14px; overflow: hidden; background: var(--foret); }
.video button { all: unset; cursor: pointer; position: absolute; inset: 0; display: block; }
.video img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s, filter .3s; }
.video button:hover img { transform: scale(1.04); filter: brightness(.85); }
.video .play { position: absolute; left: 50%; top: 50%; width: 68px; height: 68px; transform: translate(-50%, -50%); border-radius: 50%; background: var(--terra); display: grid; place-items: center; box-shadow: 0 6px 20px rgba(0,0,0,.35); transition: transform .2s; }
.video button:hover .play, .video button:focus-visible .play { transform: translate(-50%, -50%) scale(1.08); }
.video .play svg { width: 28px; height: 28px; margin-left: 4px; color: #fff; }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video .mention { position: absolute; left: 10px; bottom: 10px; background: rgba(0,0,0,.6); color: #fff; font-size: .72rem; padding: 3px 8px; border-radius: 6px; }
.carte-video { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.carte-video .video { border-radius: 0; }
.carte-video .corps { padding: 18px 20px 22px; }
.carte-video h4 { margin-bottom: 4px; }
.carte-video .source { font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--terra-fonce); margin-bottom: 8px; display: block; }
.carte-video p { color: var(--gris); font-size: .95rem; margin: 0; }

/* ---------------- Ressources ---------------- */
.sommaire { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.liste-liens { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr)); }
.liste-liens a { display: flex; align-items: center; gap: 14px; padding: 14px 18px; background: var(--blanc); border: 1px solid var(--ligne); border-radius: var(--radius-sm); text-decoration: none; color: var(--charbon); transition: border-color .15s, transform .15s; height: 100%; }
.liste-liens a:hover { border-color: var(--sauge); transform: translateX(3px); }
.liste-liens .ico { flex: none; width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; background: var(--sauge-pale); color: var(--foret); font-family: Georgia, serif; font-weight: 700; font-size: 1.1rem; }
.liste-liens b { display: block; color: var(--foret); line-height: 1.3; }
.liste-liens small { color: var(--gris); font-weight: 400; }
.aide { background: var(--blanc); border: 2px solid var(--terra); border-radius: var(--radius); padding: 28px; }
.aide h3 { display: flex; align-items: center; gap: 10px; }
.numeros { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); margin-top: 8px; }
.numero { background: var(--creme); border-radius: var(--radius-sm); padding: 16px 18px; }
.numero a.tel { display: block; font-family: var(--titre); font-weight: 800; font-size: 1.5rem; color: var(--terra-fonce); text-decoration: none; margin: 2px 0 4px; }
.numero p { margin: 0; font-size: .9rem; color: var(--gris); }
.sous-titre { display: flex; align-items: center; gap: 12px; margin: 48px 0 20px; font-size: 1.35rem; }
.sous-titre::after { content: ""; flex: 1; height: 1px; background: var(--ligne); }

/* ---------------- Dons ---------------- */
.asso { display: flex; flex-direction: column; padding: 0; overflow: hidden; }
.asso .tete { padding: 28px 28px 22px; display: flex; gap: 18px; align-items: center; }
.asso-env .tete { background: var(--foret); color: var(--creme); }
.asso-env .tete h3 { color: var(--creme); }
.asso-tca .tete { background: var(--sauge-pale); }
.asso .logo-asso { width: 76px; height: 76px; flex: none; border-radius: 16px; background: var(--blanc); display: grid; place-items: center; overflow: hidden; color: var(--foret); }
.asso .logo-asso img { width: 100%; height: 100%; object-fit: contain; padding: 6px; }
.asso .logo-asso svg { width: 40px; height: 40px; }
.asso .tete h3 { margin: 2px 0 0; font-size: 1.4rem; }
.asso .cause-tag { font-family: var(--titre); font-weight: 700; font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; color: var(--terra-fonce); }
.asso-env .cause-tag { color: var(--terra-clair); }
.asso-tca .cause-tag { color: #a24a17; } /* 4,9:1 sur sauge pâle (AA) */
.asso .corps { padding: 24px 28px 28px; display: flex; flex-direction: column; flex: 1; }
.asso .corps p { flex: 1; }
.asso .actions { display: flex; flex-wrap: wrap; gap: 10px 22px; align-items: center; }
.asso .widget { margin-top: 18px; }
.asso .widget iframe { width: 100%; height: 760px; border: 0; border-radius: 12px; }
.repartition { display: flex; height: 18px; border-radius: 999px; overflow: hidden; margin: 18px 0 10px; }
.repartition span { display: block; height: 100%; }
.legende { display: flex; flex-wrap: wrap; gap: 6px 22px; font-size: .9rem; color: #cfdccd; }
.legende i { display: inline-block; width: 12px; height: 12px; border-radius: 4px; margin-right: 6px; vertical-align: -1px; }
.calc { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: center; }
@media (max-width: 760px) { .calc { grid-template-columns: 1fr; } }
.montants { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.montants button { font: inherit; font-weight: 700; padding: 10px 18px; border-radius: 999px; border: 1.5px solid var(--foret); background: transparent; color: var(--foret); cursor: pointer; }
.montants button.actif, .montants button:hover { background: var(--foret); color: var(--creme); }
.resultat-calc { background: var(--foret); color: var(--creme); border-radius: var(--radius); padding: 26px; text-align: center; }
.resultat-calc b { display: block; font-family: var(--titre); font-weight: 900; font-size: 3rem; line-height: 1; color: var(--terra); margin: 6px 0; }

/* ---------------- Footer ---------------- */
.site-footer { background: var(--foret); color: #d6e2d4; padding: 0 0 26px; position: relative; }
.site-footer .montagnes { position: absolute; top: -69px; left: 0; height: 70px; }
.site-footer a { color: var(--creme); font-weight: 500; text-decoration: none; }
.site-footer a:hover { color: var(--terra-clair); text-decoration: underline; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 32px; padding: 40px 0 34px; }
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; } }
.site-footer h4 { font-family: var(--titre); font-weight: 700; color: var(--creme); font-size: .85rem; letter-spacing: .16em; text-transform: uppercase; margin: 0 0 14px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 7px; }
.footer-marque { display: flex; gap: 16px; align-items: center; margin-bottom: 14px; }
.footer-marque img { width: 72px; height: 72px; border-radius: 16px; }
.footer-marque img.footer-logo { width: 200px; height: auto; border-radius: 14px; background: var(--creme); padding: 10px 14px; }
.footer-marque b { font-family: var(--titre); font-weight: 900; font-size: 1.35rem; color: var(--creme); text-transform: uppercase; line-height: 1.1; display: block; }
.footer-marque .baseline { font-size: .7rem; letter-spacing: .16em; text-transform: uppercase; color: var(--sauge); display: flex; align-items: center; gap: 6px; margin-top: 4px; }
.footer-reseaux { display: flex; gap: 10px; margin-top: 16px; }
.footer-reseaux a { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .16); }
.footer-reseaux a:hover { background: var(--terra); border-color: var(--terra); text-decoration: none; color: var(--blanc); }
.footer-reseaux svg { width: 20px; height: 20px; }
.footer-bas { border-top: 1px solid rgba(255, 255, 255, .12); padding-top: 20px; font-size: .85rem; color: #a9bba8; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; }
.footer-legal { display: flex; flex-wrap: wrap; gap: 6px 18px; }

/* ---------------- Bandeau cookies ---------------- */
.bandeau-cookies { position: fixed; left: 0; right: 0; bottom: 0; z-index: 2500; background: var(--blanc); border-top: 3px solid var(--foret); box-shadow: 0 -8px 30px rgba(27, 61, 52, .18); padding: 18px 0; max-height: 80vh; overflow-y: auto; }
.bandeau-cookies p { margin: 0 0 10px; font-size: .95rem; }
.cookies-choix { display: grid; gap: 8px; margin: 6px 0 14px; font-size: .92rem; }
.cookies-choix .checkbox { margin: 0; }
.cookies-actions { display: flex; flex-wrap: wrap; gap: 10px; }
@media (max-width: 560px) {
  .bandeau-cookies { padding: 14px 0; }
  .bandeau-cookies p { font-size: .88rem; line-height: 1.5; }
  .cookies-actions .btn { flex: 1 1 40%; padding: 10px 8px; }
  .cookies-actions [data-ck="perso"], .cookies-actions [data-ck="enregistrer"] { flex-basis: 100%; }
}

/* ---------------- Divers ---------------- */
.timeline { border-left: 2px solid var(--sauge); margin-left: 8px; padding-left: 26px; }
.timeline h3 { font-size: 1rem; text-transform: uppercase; letter-spacing: .12em; color: var(--terra-fonce); }
.timeline .etape { position: relative; margin-bottom: 16px; }
.timeline .etape::before { content: ""; position: absolute; left: -34px; top: 5px; width: 14px; height: 14px; border-radius: 50%; background: var(--creme); border: 3px solid var(--foret); }
.timeline .heure { font-family: var(--titre); font-weight: 800; color: var(--foret); font-size: 1.02rem; }
.prose h3 { margin-top: 1.6em; }
.prose ul { padding-left: 1.2em; }
.tel-lien { white-space: nowrap; }
[data-ico] { display: inline-flex; }
.aide h3 [data-ico] svg { width: 26px; height: 26px; }
.liste-liens .ico svg { width: 20px; height: 20px; }
