/* Siffla · feuille de style du site
   Palette et police : design/Siffla-identite (palette.css, README.md). */

@font-face {
  font-family: "Nunito";
  src: url("/assets/fonts/nunito.woff2") format("woff2");
  font-weight: 200 1000;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light;

  /* Palette de la DA */
  --fond: #FFF9F0;
  --texte: #2D2925;
  --principale: #9B5638;
  --orange: #EBA665;
  --creme: #FFE1AB;
  --accent: #218F79;
  --blanc: #FFFFFF;

  /* Dérivés pour le web */
  --texte-doux: #5E554D;      /* 7:1 sur le fond */
  --accent-fort: #17705E;     /* vert lisible en petit texte et sur les boutons */
  --accent-fonce: #125C4D;
  --nuit: #1B3A38;            /* fond sombre de l'aperçu de la DA */
  --nuit-texte: #F3EBDD;
  --bordure: #EDE2D2;
  --creme-clair: #FFF1D6;
  --sable: #F3E3C8;
  --riviere: #9CC9D3;

  --police: "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --largeur: 1140px;
  --rayon: 22px;
  --ombre: 0 1px 2px rgba(45, 41, 37, .05), 0 10px 30px rgba(45, 41, 37, .07);
  --ombre-forte: 0 2px 6px rgba(45, 41, 37, .08), 0 24px 48px rgba(45, 41, 37, .16);
  --rebond: cubic-bezier(.3, 1.35, .5, 1);

  /* Mouvement : une seule grammaire pour tout le site.
     Les sorties sont plus rapides que les entrées ; on décélère en arrivant. */
  --duree-rapide: 140ms;
  --duree: 240ms;
  --duree-lente: 420ms;
  --entree: cubic-bezier(.2, .8, .2, 1);
  --sortie: cubic-bezier(.4, 0, 1, 1);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 88px; }
a, button, input, label, summary { touch-action: manipulation; }

body {
  margin: 0;
  background-color: var(--fond);
  /* Grain de papier, très léger */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .18 0 0 0 0 .16 0 0 0 0 .14 .07 0 0 0 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  color: var(--texte);
  font-family: var(--police);
  font-size: 1.0625rem;
  font-weight: 450;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg { max-width: 100%; height: auto; display: block; }

a {
  color: var(--accent-fort);
  text-decoration-thickness: .08em;
  text-underline-offset: .18em;
}
a:hover { color: var(--principale); }

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

h1, h2, h3 { color: var(--texte); text-wrap: balance; }
p { text-wrap: pretty; }
strong { font-weight: 800; }

.conteneur {
  width: min(100% - 32px, var(--largeur));
  margin-inline: auto;
}
.conteneur-etroit { max-width: 820px; }
.insecable { white-space: nowrap; }

.saut {
  position: absolute;
  left: -9999px;
  top: 12px;
  z-index: 20;
  background: var(--blanc);
  padding: .6rem 1rem;
  border-radius: 999px;
  font-weight: 800;
}
.saut:focus { left: 16px; }

/* ---------- En-tête ---------- */

.entete {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(255, 249, 240, .9);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid rgba(237, 226, 210, .8);
}
.entete .conteneur {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 72px;
}
.logo { display: block; flex-shrink: 0; border-radius: 10px; }
.logo img { height: 42px; width: auto; transition: transform .3s var(--rebond); }
.entete .logo:hover img { transform: rotate(-3deg) scale(1.04); }

.nav-principale ul {
  display: flex;
  align-items: center;
  gap: .15rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-principale a:not(.bouton) {
  position: relative;
  display: block;
  padding: .5rem .85rem;
  color: var(--texte);
  font-weight: 700;
  font-size: .98rem;
  text-decoration: none;
}
.nav-principale a:not(.bouton)::after {
  content: "";
  position: absolute;
  left: .85rem;
  right: .85rem;
  bottom: .3rem;
  height: 3px;
  border-radius: 3px;
  background: var(--orange);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .25s ease;
}
.nav-principale a:not(.bouton):hover::after,
.nav-principale a[aria-current="page"]::after { transform: scaleX(1); }
.nav-principale li:last-child { margin-left: .6rem; }

.menu-mobile { display: none; position: relative; }
.menu-mobile summary {
  list-style: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .55rem 1rem;
  border-radius: 999px;
  font-weight: 800;
  box-shadow: inset 0 0 0 2px var(--texte);
}
.menu-mobile summary::-webkit-details-marker { display: none; }
.menu-mobile summary svg { width: 18px; height: 18px; }
.menu-mobile[open] summary { background: var(--texte); color: var(--fond); }
.menu-mobile ul {
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  width: min(86vw, 320px);
  margin: 0;
  padding: .5rem;
  list-style: none;
  background: var(--blanc);
  border: 1px solid var(--bordure);
  border-radius: 18px;
  box-shadow: var(--ombre-forte);
  transform-origin: top right;
  animation: deplier .22s var(--rebond);
}
.menu-mobile li a {
  display: block;
  padding: .8rem 1rem;
  border-radius: 12px;
  color: var(--texte);
  font-weight: 700;
  text-decoration: none;
}
.menu-mobile li a:hover { background: var(--creme-clair); }
.menu-mobile li a[aria-current="page"] { color: var(--accent-fort); }
.menu-mobile li:last-child a { background: var(--accent-fort); color: var(--blanc); text-align: center; margin-top: .35rem; }

@keyframes deplier { from { opacity: 0; transform: scale(.94) translateY(-6px); } }

@media (max-width: 900px) {
  .nav-principale { display: none; }
  .menu-mobile { display: block; }
  .logo img { height: 36px; }
}

/* ---------- Boutons et liens ---------- */

.bouton {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  padding: .95rem 1.5rem;
  border-radius: 999px;
  font-weight: 800;
  font-size: 1.03rem;
  line-height: 1.2;
  text-decoration: none;
  transition: transform var(--duree-rapide) var(--sortie), background-color var(--duree-rapide) ease, box-shadow var(--duree-rapide) ease;
}
.bouton:hover { transform: translateY(-2px); transition-duration: var(--duree); transition-timing-function: var(--rebond); }
.bouton:active { transform: translateY(0) scale(.97); transition-duration: 80ms; }
.bouton-principal { background: var(--accent-fort); color: var(--blanc); box-shadow: 0 4px 0 var(--accent-fonce); }
.bouton-principal:hover { background: var(--accent-fonce); color: var(--blanc); box-shadow: 0 6px 0 #0D4A3E; }
.bouton-principal:active { box-shadow: 0 1px 0 #0D4A3E; }
.bouton-secondaire { color: var(--texte); box-shadow: inset 0 0 0 2px var(--texte); }
.bouton-secondaire:hover { background: var(--texte); color: var(--fond); }
.bouton-clair { background: var(--orange); color: var(--texte); box-shadow: 0 4px 0 #C98546; }
.bouton-clair:hover { background: var(--creme); color: var(--texte); }
.bouton-petit { padding: .6rem 1.1rem; font-size: .95rem; box-shadow: none; }
.bouton-petit:hover { box-shadow: none; }

.lien-fleche {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .9rem .3rem;
  color: var(--texte);
  font-weight: 800;
  text-decoration: none;
}
.lien-fleche span { transition: transform .25s var(--rebond); }
.lien-fleche:hover { color: var(--accent-fort); }
.lien-fleche:hover span { transform: translateY(4px); }

.actions { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1.25rem; margin-top: 1.9rem; }

/* ---------- Typographie commune ---------- */

.surtitre {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  margin: 0;
  color: var(--principale);
  font-size: .98rem;
  font-weight: 800;
}
.surtitre::before {
  content: "";
  width: 20px;
  height: 18px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 18'%3E%3Cpath d='M3 5 q5 4 0 8 M9 2 q9 7 0 14' fill='none' stroke='%23218F79' stroke-width='2.4' stroke-linecap='round'/%3E%3Ccircle cx='16' cy='3' r='2' fill='%23218F79'/%3E%3C/svg%3E") no-repeat center / contain;
}
h1 {
  margin: .6rem 0 1.1rem;
  font-size: clamp(2.6rem, 6vw, 4.6rem);
  font-weight: 900;
  line-height: 1.02;
  letter-spacing: -.028em;
}
h2 {
  margin: 0 0 1rem;
  font-size: clamp(2rem, 4vw, 3.1rem);
  font-weight: 900;
  line-height: 1.06;
  letter-spacing: -.022em;
}
h3 { margin: 0 0 .45rem; font-size: 1.22rem; font-weight: 800; line-height: 1.3; }
.chapo { max-width: 32em; margin: 0; color: var(--texte-doux); font-size: clamp(1.12rem, 1.6vw, 1.3rem); line-height: 1.55; }
.intro { max-width: 36em; margin: 0; color: var(--texte-doux); font-size: 1.14rem; }
.intro + .intro { margin-top: .9rem; }
.note { margin: 1.1rem 0 0; color: var(--texte-doux); font-size: .92rem; }

/* Souligné au pinceau */
.souligne { position: relative; white-space: nowrap; color: var(--accent); }
.souligne svg {
  position: absolute;
  left: -3%;
  bottom: -.14em;
  width: 106%;
  height: .3em;
  overflow: visible;
}
.souligne path {
  fill: none;
  stroke: var(--orange);
  stroke-width: 7px;
  stroke-linecap: round;
  vector-effect: non-scaling-stroke;
  stroke-dasharray: 1;
  animation: tracer .8s ease-out 1.1s both;
}
@keyframes tracer { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }

/* ---------- Héros ---------- */

.hero { padding: clamp(2rem, 5vw, 4rem) 0 clamp(3rem, 6vw, 5rem); overflow: hidden; }
.hero .conteneur {
  display: grid;
  grid-template-columns: 1fr 1.02fr;
  align-items: center;
  gap: clamp(1.5rem, 4vw, 3.5rem);
}
.hero-visuel { position: relative; }
.scene { width: 100%; overflow: visible; }

.marmotte-sort { animation: sortir 1.2s var(--rebond) .3s both; }
@keyframes sortir {
  from { transform: translateY(380px); }
  to { transform: translateY(0); }
}
.ondes {
  transform-box: fill-box;
  transform-origin: 0% 60%;
  animation: siffler 1.7s ease-in-out 1.5s 3;
}
/* Trois sifflements puis le calme (WCAG 2.2.2 : pas de mouvement automatique au-delà de 5 s).
   Survoler ou toucher la scène la fait siffler à nouveau (voir siffla.js). */
@keyframes siffler {
  0%, 100% { opacity: 1; transform: scale(1); }
  25% { opacity: .3; transform: scale(.82); }
  60% { opacity: 1; transform: scale(1.08); }
}
@keyframes siffler-encore {
  0%, 100% { opacity: 1; transform: scale(1); }
  25% { opacity: .3; transform: scale(.82); }
  60% { opacity: 1; transform: scale(1.08); }
}
.yeux {
  transform-box: fill-box;
  transform-origin: center;
  animation: cligner 4.8s ease-in-out 1.2s 1;
}
@keyframes cligner {
  0%, 93%, 100% { transform: scaleY(1); }
  96% { transform: scaleY(.08); }
}
@keyframes cligner-vite { 50% { transform: scaleY(.08); } }
.hero-visuel.calme .ondes, .hero-visuel.calme .yeux { animation: none; }
.hero-visuel.siffle .ondes { animation: siffler-encore 1.7s ease-in-out 2; }
.hero-visuel.siffle .yeux { animation: cligner-vite .45s ease-in-out .15s 1; }

.notif {
  position: absolute;
  left: -5%;
  bottom: 6%;
  width: min(330px, 92%);
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: .8rem;
  padding: .95rem 1.05rem;
  border: 1px solid var(--bordure);
  border-radius: 20px;
  background: var(--blanc);
  box-shadow: var(--ombre-forte);
  font-size: .93rem;
  line-height: 1.45;
  animation: glisser .7s var(--rebond) 1.6s both;
}
@keyframes glisser { from { opacity: 0; transform: translateY(18px) scale(.96); } }
.notif img { width: 44px; height: 44px; border-radius: 12px; background: var(--creme-clair); padding: 3px; }
.notif .notif-app { display: flex; justify-content: space-between; color: var(--texte-doux); font-size: .8rem; font-weight: 700; }
.notif p { margin: .15rem 0 0; }
.notif .prix { color: var(--accent-fort); font-weight: 850; }
.notif .notif-meta { margin-top: .35rem; color: var(--texte-doux); font-size: .82rem; }

@media (max-width: 860px) {
  .hero .conteneur { grid-template-columns: 1fr; }
  .hero-visuel { max-width: 460px; margin-inline: auto; width: 100%; }
  .notif { position: relative; left: auto; bottom: auto; margin: -3rem auto 0; }
}

/* ---------- Sections ---------- */

.section { padding: clamp(3.5rem, 8vw, 7rem) 0; }
.section-blanche { background: var(--blanc); border-block: 1px solid var(--bordure); }
.entete-section { margin-bottom: 2.5rem; }

.duo {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: clamp(2rem, 6vw, 5rem);
}
.duo .visuel { max-width: 340px; margin-inline: auto; }
@media (max-width: 860px) {
  .duo { grid-template-columns: 1fr; }
  .duo .visuel { max-width: 240px; order: -1; }
}

.grille-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
@media (max-width: 860px) { .grille-3 { grid-template-columns: 1fr; } }

.carte {
  padding: 1.75rem;
  border: 1px solid var(--bordure);
  border-radius: var(--rayon);
  background: var(--blanc);
}
.section-blanche .carte { background: var(--fond); }
.carte p { margin: 0; color: var(--texte-doux); }
.carte p + p { margin-top: .7rem; }

/* Faits courts, deux par ligne */
.faits { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem 2rem; margin: 2rem 0 0; }
.faits dt { display: flex; align-items: center; gap: .5rem; font-weight: 850; font-size: 1.08rem; }
.faits dt::before {
  content: "";
  flex-shrink: 0;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(33, 143, 121, .15);
}
.faits dd { margin: .3rem 0 0; color: var(--texte-doux); }
@media (max-width: 560px) { .faits { grid-template-columns: 1fr; } }

.liste-coches { margin: 1.25rem 0 0; padding: 0; list-style: none; }
.liste-coches li { position: relative; margin: .6rem 0; padding-left: 2rem; }
.liste-coches li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .3em;
  width: 1.25rem;
  height: 1.25rem;
  border-radius: 50%;
  background: var(--accent-fort) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5.5 10.5l3 3 6-7' fill='none' stroke='white' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 80% no-repeat;
}

.liste-etapes { margin: 1.5rem 0 0; padding: 0; list-style: none; counter-reset: etape; }
.liste-etapes li { position: relative; margin: 1.15rem 0; padding-left: 3rem; color: var(--texte-doux); counter-increment: etape; }
.liste-etapes li strong { color: var(--texte); }
.liste-etapes li::before {
  content: counter(etape);
  position: absolute;
  left: 0;
  top: -.05rem;
  display: grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: var(--texte);
  color: var(--fond);
  font-size: .95rem;
  font-weight: 900;
}

/* ---------- Démonstration : le prix qui fait le yo-yo ---------- */

.demo { background: var(--blanc); border-block: 1px solid var(--bordure); }
.demo-grille {
  display: grid;
  grid-template-columns: .82fr 1.18fr;
  align-items: center;
  gap: clamp(2rem, 5vw, 4.5rem);
}
.demo-texte p { color: var(--texte-doux); font-size: 1.1rem; }
.demo-texte p strong { color: var(--texte); }
@media (max-width: 900px) { .demo-grille { grid-template-columns: 1fr; } }

.seuil {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: .4rem 1rem;
  margin-top: 1.75rem;
  padding: 1.1rem 1.3rem 1.2rem;
  border: 2px solid var(--texte);
  border-radius: 18px;
  background: var(--fond);
}
.seuil[hidden] { display: none; }
.seuil label { font-weight: 850; }
.seuil output { color: var(--accent-fort); font-size: 1.45rem; font-weight: 900; font-variant-numeric: tabular-nums; }
.seuil input { grid-column: 1 / -1; width: 100%; margin: .3rem 0 0; accent-color: var(--accent-fort); cursor: grab; }
.seuil input:active { cursor: grabbing; }
.demo-texte .verdict { min-height: 5.2em; margin: 1rem 0 0; color: var(--texte); font-weight: 750; font-size: 1.05rem; }

.carte-graphique {
  margin: 0;
  padding: 1.1rem 1.1rem .8rem;
  border: 1px solid var(--bordure);
  border-radius: 24px;
  background: var(--fond);
}
.carte-graphique[hidden] { display: none; }
.carte-graphique figcaption { margin-top: .4rem; color: var(--texte-doux); font-size: .85rem; text-align: center; }
.graphique svg { width: 100%; font-family: var(--police); overflow: visible; }

.g-zone { fill: rgba(33, 143, 121, .08); transition: y .25s ease, height .25s ease; }
.g-grille { stroke: #EADFCF; stroke-width: 1; }
.g-axe { fill: var(--texte-doux); font-size: 13px; font-weight: 700; }
.g-seuil { transition: transform .25s ease; }
.g-seuil line { stroke: var(--accent-fort); stroke-width: 2.5; stroke-dasharray: 7 7; }
.g-etiquette rect { fill: var(--accent-fort); }
.g-etiquette text { fill: var(--blanc); font-size: 13px; font-weight: 800; }
.g-courbe { fill: none; stroke: var(--texte); stroke-width: 3.5; stroke-linejoin: round; stroke-linecap: round; }
.anime .g-courbe { transition: stroke-dashoffset 1.4s ease-in-out; }
.g-points { transition: opacity .4s ease; }
.g-points circle { fill: var(--fond); stroke: var(--texte); stroke-width: 2.5; }
.g-marqueur { transition: transform .4s var(--rebond), opacity .3s ease; }
.g-marqueur.cache { opacity: 0; }
.attente:not(.visible) .g-points,
.attente:not(.visible) .g-marqueur { opacity: 0; }
.g-point { fill: var(--accent); stroke: var(--blanc); stroke-width: 3; }
.g-onde {
  fill: none;
  stroke: var(--accent);
  stroke-width: 2;
  transform-box: fill-box;
  transform-origin: center;
}
.g-onde.pulse { animation: onde 1.8s ease-out 3; }
@keyframes onde { from { transform: scale(1); opacity: .9; } to { transform: scale(2.8); opacity: 0; } }
.g-bulle { transition: transform .4s var(--rebond); }
.g-bulle rect { fill: var(--texte); }
.g-bulle text { fill: var(--blanc); font-size: 14px; font-weight: 850; }
.etroit .g-axe { font-size: 14px; }

/* ---------- Le ticket du vrai prix ---------- */

.ticket-zone { display: grid; place-items: center; filter: drop-shadow(0 14px 24px rgba(45, 41, 37, .16)); }
.ticket {
  width: min(100%, 340px);
  padding: 1.8rem 1.6rem 2.4rem;
  background: var(--blanc);
  color: #3A342E;
  font-family: var(--mono);
  font-size: .88rem;
  line-height: 1.5;
  rotate: -2.5deg;
  -webkit-mask:
    conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / 16px 51% repeat-x,
    conic-gradient(from 135deg at top, #0000, #000 1deg 89deg, #0000 90deg) top / 16px 51% repeat-x;
  mask:
    conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / 16px 51% repeat-x,
    conic-gradient(from 135deg at top, #0000, #000 1deg 89deg, #0000 90deg) top / 16px 51% repeat-x;
  transition: rotate .4s var(--rebond);
}
.ticket:hover { rotate: 0deg; }
.ticket p { margin: 0; }
.ticket .ticket-entete { margin-bottom: 1rem; text-align: center; font-weight: 800; letter-spacing: .35em; }
.ticket-entete span { font-weight: 500; font-size: .78rem; letter-spacing: .12em; }
.ticket .ticket-produit { margin-bottom: 1rem; padding: .5rem 0; border-block: 1px dashed #CFC4B6; text-align: center; }
.ticket-offre { margin-bottom: .9rem; }
.ticket .ticket-nom { margin-bottom: .25rem; font-weight: 800; }
.ligne { display: flex; justify-content: space-between; gap: .4rem; }
.ligne span:first-child { flex: 1; display: flex; }
.ligne span:first-child::after { content: ""; flex: 1; margin: 0 .4rem .35em; border-bottom: 2px dotted #D8CDBE; }
.ticket .ligne.total { margin-top: .3rem; padding-top: .3rem; border-top: 1px solid #CFC4B6; font-weight: 800; }
.gagnante { margin: 0 -.6rem .9rem; padding: .6rem; border-radius: 8px; background: rgba(33, 143, 121, .1); }
.gagnante .total span:last-child { color: var(--accent-fort); }
.ticket .ticket-pied { margin-top: 1.2rem; color: #6B6259; font-size: .8rem; text-align: center; }

/* ---------- Ce que la marmotte ne fera jamais ---------- */

.jamais-grille {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: clamp(2rem, 6vw, 5rem);
}
@media (max-width: 860px) { .jamais-grille { grid-template-columns: 1fr; } }
.barre { margin: 0; padding: 0; list-style: none; }
.barre li {
  position: relative;
  width: fit-content;
  margin: .25rem 0;
  color: var(--texte-doux);
  font-size: clamp(1.5rem, 3.2vw, 2.25rem);
  font-weight: 850;
  line-height: 1.3;
  letter-spacing: -.01em;
}
.barre li::after {
  content: "";
  position: absolute;
  left: -4%;
  right: -4%;
  top: 30%;
  height: .5em;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 20' preserveAspectRatio='none'%3E%3Cpath d='M3 13 C 60 6, 130 15, 197 7' fill='none' stroke='%23EBA665' stroke-width='6' stroke-linecap='round'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
  transform-origin: left center;
}

/* ---------- La vallée ---------- */

.carte-vallee { margin: 0; }
.carte-vallee svg { width: 100%; border-radius: 24px; background: var(--creme-clair); font-family: var(--police); }
.carte-vallee figcaption { margin-top: .5rem; color: var(--texte-doux); font-size: .85rem; text-align: center; }
.vallee-monts { fill: var(--sable); }
.rayon { fill: rgba(33, 143, 121, .07); stroke: var(--accent); stroke-width: 2; stroke-dasharray: 6 8; }
.rayon-texte { fill: var(--accent-fort); font-size: 15px; font-weight: 800; }
.rhone { fill: none; stroke: var(--riviere); stroke-width: 7; stroke-linecap: round; }
.lieu circle { fill: var(--blanc); stroke: var(--texte); stroke-width: 4; }
.lieu text { fill: var(--texte); font-size: 19px; font-weight: 800; }
.lieu.principal circle {
  fill: var(--accent);
  transform-box: fill-box;
  transform-origin: center;
  animation: battre 2.4s ease-in-out 3;
}
.lieu.principal text { font-size: 22px; font-weight: 900; }
@keyframes battre { 50% { transform: scale(1.25); } }

/* ---------- Guides en liste ---------- */

.liste-guides { margin: 2.25rem 0 0; padding: 0; list-style: none; border-top: 2px solid var(--texte); }
.liste-guides a {
  display: grid;
  grid-template-columns: 3.5rem 1fr auto;
  align-items: baseline;
  gap: 1rem;
  padding: 1.5rem .25rem;
  border-bottom: 1px solid var(--bordure);
  color: var(--texte);
  text-decoration: none;
}
.liste-guides .num { color: var(--principale); font-weight: 900; font-variant-numeric: tabular-nums; }
.liste-guides .titre { font-size: clamp(1.2rem, 2.4vw, 1.65rem); font-weight: 850; line-height: 1.25; transition: transform .3s var(--rebond), color .2s; }
.liste-guides .duree { color: var(--texte-doux); font-size: .9rem; white-space: nowrap; }
.liste-guides a:hover .titre { transform: translateX(10px); color: var(--accent-fort); }
@media (max-width: 560px) { .liste-guides a { grid-template-columns: 2.4rem 1fr; } .liste-guides .duree { grid-column: 2; } }

/* ---------- Bande commerçants ---------- */

.commercants-accueil { padding-top: 0; }
.bande-commercants {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: clamp(1.5rem, 4vw, 2.25rem) clamp(1.5rem, 4vw, 2.5rem);
  border: 2px solid var(--texte);
  border-radius: 26px;
  color: var(--texte);
  text-decoration: none;
  transition: background-color var(--duree-rapide) ease, transform var(--duree-rapide) var(--sortie);
}
.bande-commercants:hover { background: var(--creme-clair); color: var(--texte); transform: translateY(-2px); transition-duration: var(--duree); transition-timing-function: var(--rebond); }
.bande-commercants:active, .bande-actu:active { transform: scale(.99); transition-duration: 80ms; }
.bande-texte { display: grid; gap: .3rem; }
.bande-texte strong { font-size: clamp(1.25rem, 2.6vw, 1.7rem); line-height: 1.2; }
.bande-texte span { color: var(--texte-doux); }
.bande-fleche {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 3.2rem;
  height: 3.2rem;
  border-radius: 50%;
  background: var(--texte);
  color: var(--fond);
  font-size: 1.4rem;
  font-weight: 900;
  transition: transform .3s var(--rebond);
}
.bande-commercants:hover .bande-fleche { transform: translateX(6px) rotate(-8deg); }

/* ---------- Bandeau d'actualité (accueil) ---------- */

.actu { padding: 0 0 clamp(2.5rem, 5vw, 4rem); }
.bande-actu {
  display: flex;
  align-items: center;
  gap: 1rem 1.25rem;
  padding: 1rem 1.25rem;
  border-radius: 22px;
  background: var(--creme);
  color: var(--texte);
  text-decoration: none;
  transition: background-color var(--duree-rapide) ease, transform var(--duree-rapide) var(--sortie);
}
.bande-actu:hover { background: var(--orange); color: var(--texte); transform: translateY(-2px); transition-duration: var(--duree); transition-timing-function: var(--rebond); }
.actu-icone {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 50px;
  height: 50px;
  border-radius: 15px;
  background: var(--texte);
  color: var(--creme);
}
.actu-icone svg { width: 26px; height: 26px; }
.actu-texte { flex: 1; display: grid; gap: .1rem; }
.actu-texte strong { font-size: 1.12rem; line-height: 1.3; }
.actu-texte span { color: #4A423B; }
.bande-actu .bande-fleche { width: 2.6rem; height: 2.6rem; font-size: 1.15rem; }
.bande-actu:hover .bande-fleche { transform: translateX(6px) rotate(-8deg); }
@media (max-width: 560px) { .bande-actu .bande-fleche { display: none; } }

/* ---------- Calculateur essence ---------- */

.calculateur { padding-top: clamp(2rem, 5vw, 3.5rem); }
.calc-grille {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  align-items: start;
  gap: clamp(2rem, 5vw, 4rem);
}
@media (max-width: 900px) { .calc-grille { grid-template-columns: 1fr; } }
.calc-form h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
.calc-champs { display: grid; grid-template-columns: 1fr 1fr; gap: 1.1rem 1.25rem; }
.calc-large { grid-column: 1 / -1; }
@media (max-width: 560px) { .calc-champs { grid-template-columns: 1fr; } }
.calc-champs label { display: grid; gap: .4rem; }
.calc-libelle { font-weight: 800; font-size: .98rem; }
.calc-saisie {
  display: flex;
  align-items: center;
  border: 2px solid var(--texte);
  border-radius: 14px;
  background: var(--blanc);
  transition: box-shadow .2s ease, border-color .2s ease;
}
.calc-saisie:focus-within { border-color: var(--accent-fort); box-shadow: 0 0 0 4px rgba(33, 143, 121, .22); }
.calc-saisie input {
  flex: 1;
  min-width: 0;
  padding: .75rem 1rem;
  border: 0;
  background: transparent;
  color: var(--texte);
  font: inherit;
  font-size: 1.3rem;
  font-weight: 850;
  font-variant-numeric: tabular-nums;
}
.calc-saisie input:focus { outline: none; }
.calc-saisie > span { padding-right: 1rem; color: var(--texte-doux); font-size: .9rem; font-weight: 700; white-space: nowrap; }

.calc-resultat { display: grid; gap: 1.5rem; }
@media (min-width: 901px) { .calc-resultat { position: sticky; top: 96px; } }
.calc-resultat .ticket { font-size: .98rem; }
.calc-verdict {
  display: grid;
  grid-template-columns: 88px 1fr;
  align-items: center;
  gap: 1rem;
  padding: 1.2rem 1.25rem;
  border: 1px solid var(--bordure);
  border-radius: 20px;
  background: var(--blanc);
}
.calc-verdict img { width: 88px; }
.calc-verdict p { margin: 0; color: var(--texte-doux); }
.calc-verdict .calc-verdict-titre { margin-bottom: .45rem; color: var(--texte); font-size: 1.12rem; font-weight: 850; line-height: 1.35; }

/* ---------- Pages de contenu ---------- */

.page-titre {
  padding: clamp(3rem, 6vw, 5rem) 0 calc(clamp(2rem, 4vw, 3rem) + 56px);
  background: url("/assets/img/crete-claire.svg") bottom / 100% 56px no-repeat;
}
.page-titre h1 { font-size: clamp(2.2rem, 4.6vw, 3.5rem); }
.page-titre .conteneur { max-width: 820px; }
.page-titre.large .conteneur { max-width: var(--largeur); }
.page-titre.large .conteneur > * { max-width: 820px; }
.page-titre .meta { margin-top: 1rem; color: var(--texte-doux); font-size: .92rem; }

.prose { max-width: 720px; margin-inline: auto; padding: clamp(2rem, 5vw, 3.5rem) 0 clamp(3.5rem, 7vw, 5.5rem); }
.prose h2 { margin-top: 2.8rem; font-size: clamp(1.5rem, 2.6vw, 1.9rem); }
.prose h3 { margin-top: 1.8rem; }
.prose p, .prose li { color: #3E3832; }
.prose ul, .prose ol { padding-left: 1.3rem; }
.prose li { margin: .4rem 0; }
.prose li::marker { color: var(--principale); font-weight: 800; }

.encadre {
  margin: 1.75rem 0;
  padding: 1.25rem 1.4rem;
  border-left: 4px solid var(--orange);
  border-radius: 0 14px 14px 0;
  background: var(--creme-clair);
}
.encadre p { margin: 0; }
.encadre p + p { margin-top: .6rem; }
.encadre-vert { border-left-color: var(--accent); background: rgba(33, 143, 121, .08); }

/* Les calculs des guides, façon ticket */
.calcul {
  margin: 2rem auto;
  max-width: 560px;
  padding: 1.5rem 1.5rem 2rem;
  background: var(--blanc);
  font-variant-numeric: tabular-nums;
  -webkit-mask: conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / 16px 100% repeat-x;
  mask: conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) bottom / 16px 100% repeat-x;
}
.calcul p { margin: .3rem 0; }
.calcul .total { margin-top: .8rem; padding-top: .8rem; border-top: 2px dashed var(--bordure); font-weight: 850; }

.sources { margin-top: 3rem; padding-top: 1.25rem; border-top: 1px solid var(--bordure); color: var(--texte-doux); font-size: .92rem; }
.sources h2 { margin-top: 0; font-size: 1rem; }

/* Questions fréquentes */
.faq { border-bottom: 1px solid var(--bordure); }
.faq summary {
  position: relative;
  cursor: pointer;
  list-style: none;
  padding: 1.15rem 2.5rem 1.15rem 0;
  font-size: 1.1rem;
  font-weight: 800;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: .25rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--accent-fort);
  font-size: 1.6rem;
  font-weight: 700;
  line-height: 1;
  transition: transform .25s var(--rebond);
}
.faq[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq > div { padding: 0 0 1.2rem; animation: deplier .25s ease; }
.faq > div p { margin: 0; color: var(--texte-doux); }
.faq > div p + p { margin-top: .6rem; }

/* Bandeau d'appel (pages intérieures) */
.bandeau {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 2rem;
  padding: clamp(2rem, 5vw, 3.5rem);
  border-radius: 28px;
  background: var(--nuit);
  color: var(--nuit-texte);
}
.bandeau h2 { color: var(--blanc); margin-top: 0; font-size: clamp(1.7rem, 3.4vw, 2.4rem); }
.bandeau p { margin: 0; max-width: 36em; font-size: 1.1rem; }
.bandeau img { width: 170px; }
@media (max-width: 760px) {
  .bandeau { grid-template-columns: 1fr; }
  .bandeau img { width: 130px; order: -1; }
}

/* ---------- Pied de page ---------- */

.pied { margin-top: clamp(2rem, 5vw, 4rem); color: var(--nuit-texte); }
.pied-crete { position: relative; height: 150px; overflow: hidden; }
.pied-crete .crete { position: absolute; left: 0; bottom: -1px; width: 100%; height: 90px; color: var(--nuit); }
.guetteuse {
  position: absolute;
  right: 12%;
  bottom: 22px;
  width: 112px;
}
.pied-fond { padding: 1.5rem 0 2rem; background: var(--nuit); }
.pied a { color: var(--blanc); text-decoration: none; }
.pied a:hover { color: var(--orange); text-decoration: underline; }
.pied .colonnes { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 2rem; }
.pied .logo img { height: 40px; }
.pied p { margin: 1rem 0 0; max-width: 26em; font-size: .98rem; }
.pied h2 { margin: 0 0 .8rem; color: var(--orange); font-size: .95rem; letter-spacing: 0; }
.pied ul { margin: 0; padding: 0; list-style: none; }
.pied li { margin: .45rem 0; }
.pied-appel {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem 2rem;
  margin-bottom: 2.5rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid rgba(243, 235, 221, .18);
}
.pied .pied-appel p { margin: 0; max-width: 20em; color: var(--blanc); font-size: clamp(1.45rem, 2.8vw, 2.1rem); font-weight: 900; line-height: 1.15; letter-spacing: -.015em; }
.pied .pied-appel .bouton { color: var(--texte); }
.pied .pied-appel .bouton:hover { color: var(--texte); text-decoration: none; }
.pied .bas {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: .5rem 1.5rem;
  margin-top: 2.75rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(243, 235, 221, .18);
  font-size: .88rem;
  opacity: .85;
}
@media (max-width: 760px) {
  .pied .colonnes { grid-template-columns: 1fr 1fr; }
  .pied .colonnes > div:first-child { grid-column: 1 / -1; }
  .guetteuse { width: 92px; right: 8%; }
}

/* ---------- Page introuvable ---------- */

.introuvable { padding: clamp(3rem, 8vw, 6rem) 0; text-align: center; }
.introuvable img { width: 200px; margin: 0 auto 1.5rem; animation: chercher 3s ease-in-out infinite; }
@keyframes chercher { 25% { rotate: -6deg; } 75% { rotate: 6deg; } }
.introuvable .chapo { margin-inline: auto; }
.introuvable .actions { justify-content: center; }

/* ---------- Apparitions au défilement ---------- */
/* Navigateurs récents seulement ; ailleurs, tout est simplement visible. */

@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    [data-reveal] {
      animation: apparaitre linear both;
      animation-timeline: view();
      animation-range: entry 0% cover 28%;
    }
    .barre li::after {
      animation: barrer linear both;
      animation-timeline: view();
      animation-range: entry 60% cover 45%;
    }
    .guetteuse {
      animation: surgir linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 100%;
    }
    .rhone {
      stroke-dasharray: 1;
      animation: tracer linear both;
      animation-timeline: view();
      animation-range: entry 10% cover 40%;
    }
  }
}
@keyframes apparaitre { from { opacity: 0; translate: 0 34px; } to { opacity: 1; translate: 0 0; } }
@keyframes barrer { from { scale: 0 1; } to { scale: 1 1; } }
@keyframes surgir { from { translate: 0 70px; } to { translate: 0 0; } }

/* ---------- Transitions entre les pages ---------- */
/* Fondu natif entre deux pages du site ; l'en-tête reste en place.
   Les navigateurs qui ne le connaissent pas changent simplement de page. */

@media (prefers-reduced-motion: no-preference) {
  @view-transition { navigation: auto; }
}
.entete { view-transition-name: entete; }
::view-transition-old(root) { animation: var(--duree-rapide) var(--sortie) both vt-sortie; }
::view-transition-new(root) { animation: var(--duree) var(--entree) both vt-entree; }
@keyframes vt-sortie { to { opacity: 0; } }
@keyframes vt-entree { from { opacity: 0; translate: 0 10px; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
