@font-face {
  font-family: "Anek Latin";
  src: url("fonts/anek-latin-wdth.woff2") format("woff2");
  font-weight: 100 800;
  font-stretch: 75% 125%;
  font-display: swap;
}

:root {
  --nuit: #1F2326;
  --eteint: #363C41;
  --lampe: #F1F2EC;
  --rouge: #B8302A;
  --rouge-fonce: #962620;
  --enduit: #E1E3E2;
  --encre: #1C1E20;
  --gris-texte: #555A5F;
  --gris-nuit: #A9AEAC;
  --filet: #bec2c2;
}

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

html {
  scrollbar-color: var(--nuit) var(--enduit);
  -webkit-text-size-adjust: 100%;
}
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  container-type: inline-size;
  background: var(--enduit);
  color: var(--encre);
  font-family: "Anek Latin", system-ui, sans-serif;
  font-stretch: 100%;
  font-size: 1.0625rem;
  line-height: 1.55;
}

::selection { background: var(--rouge); color: #fff; }

a { color: inherit; text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
a:focus-visible { outline: 3px solid var(--rouge); outline-offset: 3px; }
.bandeau a:focus-visible, .signal a:focus-visible, .bande a:focus-visible, .pied a:focus-visible, .barre-mobile a:focus-visible { outline-color: var(--lampe); }

[id] { scroll-margin-top: 3.5rem; }

h1, h2, h3, p, ul, ol, dl, dd, figure, blockquote { margin: 0; }

.evitement {
  position: absolute; left: -9999px; top: 0.5rem; z-index: 50;
  background: #fff; color: var(--encre); padding: 0.6rem 1rem; font-weight: 700;
}
.evitement:focus { left: 0.5rem; }

/* La grille de temps : une colonne = une unité de Morse, alignée de l'accueil au pied de page */
.grille {
  --w: min(100cqw - 2rem, 80rem);
  --u: calc(var(--w) / 11);
  --ligne: rgb(28 30 32 / 0.07);
  background-image: repeating-linear-gradient(90deg, var(--ligne) 0 1px, transparent 1px var(--u));
  background-position: calc((100cqw - var(--w)) / 2) 0;
}
.signal.grille, .bande.grille, .pied.grille { --ligne: var(--eteint); }
.bande .grille, .grille .grille { background-image: none; }
.bande.grille { background-image: repeating-linear-gradient(90deg, var(--ligne) 0 1px, transparent 1px var(--u)); }

/* Le Morse : un point = 1 unité, un trait = 3, silence = 1 entre signes, 3 entre lettres */
.morse, .pied-morse, .mini, .mot-morse { display: flex; align-items: center; }
.morse i, .pied-morse i, .mini i, .mot-morse i { display: block; flex: none; width: var(--u); height: var(--u); background: currentColor; }
.morse i.t, .pied-morse i.t, .mini i.t, .mot-morse i.t { width: calc(3 * var(--u)); }
.lettre { display: flex; gap: var(--u); }

/* Bandeau du haut */
.bandeau {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  min-height: 2.75rem;
  padding: 0 1rem;
  background: var(--nuit); color: var(--gris-nuit);
  border-bottom: 1px solid var(--eteint);
  font-size: 0.88rem; font-weight: 600;
  position: relative; z-index: 20;
}
.bandeau-nav { display: none; gap: 1.6rem; }
.bandeau-nav a, .bandeau-tel { display: flex; align-items: center; min-height: 2.75rem; text-decoration: none; }
.bandeau-nav a:hover, .bandeau-tel:hover { text-decoration: underline; color: var(--lampe); }
.bandeau-tel { color: var(--lampe); font-weight: 700; white-space: nowrap; font-variant-numeric: tabular-nums; }

/* Accueil : le signal */
.signal {
  display: flex;
  min-height: calc(100svh - 2.75rem);
  background: var(--nuit);
  color: var(--lampe);
}
.signal-cadre {
  width: var(--w);
  margin-inline: auto;
  display: flex; flex-direction: column; justify-content: center;
  gap: clamp(1.6rem, 5svh, 3.5rem);
  padding: clamp(2rem, 6svh, 4.5rem) 0;
}
.morse { flex-direction: column; align-items: flex-start; gap: var(--u); }
.morse i { background: var(--lampe); }

.nom {
  font-weight: 800; font-stretch: 125%;
  text-transform: uppercase;
  font-size: calc(var(--w) / 7.3);
  line-height: 0.92;
  letter-spacing: -0.01em;
}
.nom-garage { display: block; color: var(--gris-nuit); }
.signal-bas { display: grid; gap: 1.4rem; }
.metier { color: var(--gris-nuit); font-size: clamp(1rem, 1.6vw, 1.2rem); max-width: 30em; }
.reponse-texte { font-weight: 700; font-stretch: 110%; font-size: clamp(1.25rem, 2.4vw, 1.7rem); line-height: 1.3; margin-bottom: 1rem; text-wrap: balance; }
.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }

.bouton {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 3rem; padding: 0 1.4rem;
  font-weight: 700; font-stretch: 112%;
  text-decoration: none;
  border: 2px solid transparent;
  transition: background-color 0.2s ease-out, color 0.2s ease-out;
}
.bouton-appel { background: var(--rouge); color: #fff; }
.bouton-appel:hover { background: var(--rouge-fonce); }
.bouton-trait { border-color: var(--lampe); color: var(--lampe); }
.bouton-trait:hover { background: var(--lampe); color: var(--encre); }
.bouton-trait-sombre { border-color: var(--encre); color: var(--encre); }
.bouton-trait-sombre:hover { background: var(--encre); color: #fff; }

/* Sections de lecture */
.bloc {
  max-width: 72rem;
  margin: 0 auto;
  padding: clamp(3.5rem, 8vw, 7rem) 1rem;
}
.bloc + .bloc { padding-top: 0; }
h2 {
  font-weight: 800; font-stretch: 118%;
  font-size: clamp(1.65rem, 4vw, 2.8rem);
  line-height: 1.05;
  letter-spacing: -0.01em;
  max-width: 26ch;
  margin-bottom: clamp(1.6rem, 3vw, 2.6rem);
  text-wrap: balance;
}
.lead { font-size: clamp(1.15rem, 2vw, 1.4rem); line-height: 1.45; max-width: 36em; margin: -0.6rem 0 2.4rem; }

.famille {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.4rem;
  border-top: 2px solid var(--encre);
  padding: 1.1rem 0 1.6rem;
}
.famille-nom {
  display: flex; align-items: center; flex-wrap: wrap; gap: 0.75rem;
  font-weight: 800; font-stretch: 118%;
  text-transform: uppercase;
  font-size: 1.05rem; letter-spacing: 0.02em;
}
.mini { --u: 0.42rem; gap: var(--u); color: var(--rouge); }
.ligne {
  display: grid; grid-template-columns: 1fr; gap: 0.2rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--filet);
}
.ligne:last-child { border-bottom: 0; }
.ligne dt { font-weight: 700; font-stretch: 108%; }
.ligne dd { max-width: 60ch; }

.cas { list-style: none; padding: 0; display: grid; gap: 2.2rem; }
.cas-item { border-top: 2px solid var(--encre); padding-top: 1.1rem; }
.cas-titre { font-weight: 800; font-stretch: 112%; font-size: clamp(1.2rem, 2vw, 1.5rem); line-height: 1.3; text-wrap: balance; }
.cas-suite { margin-top: 0.7rem; max-width: 46ch; }
.cas-auteur { margin-top: 0.5rem; font-weight: 600; color: var(--gris-texte); font-size: 0.92rem; }

/* Bande sombre : l'écoute, le prix, la confiance */
.bande {
  background: var(--nuit);
  color: var(--lampe);
  padding: clamp(4rem, 9vw, 8rem) 1rem;
}
.bande > * { max-width: 72rem; margin-inline: auto; }
.bande-titre-2 { margin-top: clamp(4rem, 8vw, 6.5rem); }
.ecoute { list-style: none; padding: 0; }
.ecoute li { border-top: 1px solid var(--eteint); padding: 1.4rem 0 1.6rem; }
.ecoute blockquote {
  font-weight: 600; font-stretch: 108%;
  font-size: clamp(1.35rem, 3.2vw, 2.4rem);
  line-height: 1.3;
  color: var(--gris-nuit);
  max-width: 34ch;
  text-wrap: balance;
}
.ecoute strong { color: var(--lampe); font-weight: 800; }
.bande .cas { margin-bottom: 0; }
.bande .cas-item { border-top: 1px solid var(--eteint); }
.bande .cas-auteur { color: var(--gris-nuit); }
.ecoute p { margin-top: 0.6rem; font-size: 0.92rem; font-weight: 600; color: var(--gris-nuit); }

.deux-mots { display: grid; gap: 3rem; }
.mot { container-type: inline-size; }
.mot-grand {
  font-weight: 800; font-stretch: 125%;
  text-transform: uppercase;
  font-size: min(6rem, 12cqi);
  line-height: 0.9;
}
.mot-morse { --u: calc(100cqi / 85); gap: var(--u); margin: 0.9rem 0 1.4rem; color: var(--rouge); }
.mot-morse b { display: block; flex: none; width: var(--u); }
.mot-preuves { list-style: none; padding: 0; }
.mot-preuves li { padding: 0.75rem 0; border-top: 1px solid var(--eteint); font-size: 1.1rem; }
.mot-preuves li:first-child { border-top: 0; }
.mot-preuves span { display: block; color: var(--gris-nuit); font-size: 0.9rem; margin-top: 0.15rem; }

/* Mur d'avis */
.mur-note { margin: -1rem 0 2.2rem; color: var(--gris-texte); font-size: 0.92rem; }
.mur { list-style: none; padding: 0; columns: 3 17rem; column-gap: 3rem; }
.mur li { break-inside: avoid; margin-bottom: 2.2rem; }
.mur blockquote { font-size: 1.12rem; line-height: 1.4; }
.mur li.g blockquote { font-weight: 700; font-stretch: 110%; font-size: clamp(1.45rem, 2.6vw, 2rem); line-height: 1.3; }
.mur p { margin-top: 0.45rem; font-size: 0.88rem; font-weight: 600; color: var(--gris-texte); }
.avis-lien a { font-weight: 700; }

.maintenant { margin: -1rem 0 1.6rem; font-weight: 700; }
.horaires { width: 100%; max-width: 40rem; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.horaires th, .horaires td { padding: 0.8rem 0.5rem 0.8rem 0; border-bottom: 1px solid var(--filet); text-align: left; }
.horaires th { font-weight: 700; width: 38%; }
.horaires .clos td { color: var(--gris-texte); }
.horaires tr.aujourdhui th, .horaires tr.aujourdhui td { font-weight: 800; border-bottom: 2px solid var(--rouge); }
.aujourdhui-mot { display: block; font-size: 0.8rem; font-weight: 700; color: var(--rouge); text-transform: uppercase; letter-spacing: 0.06em; }
.horaires-note { margin-top: 1.2rem; }
.horaires-note a { font-weight: 700; }

.acces { display: grid; gap: 2.5rem; }
address { font-style: normal; font-size: 1.3rem; line-height: 1.35; }
.acces-nom { display: block; font-weight: 800; font-stretch: 118%; }
.actions-clair { justify-content: flex-start; margin: 1.4rem 0 2rem; }
.pratique > div { border-top: 1px solid var(--filet); padding: 0.85rem 0; }
.pratique dt { font-weight: 700; font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--gris-texte); }
.pratique dd { margin-top: 0.2rem; max-width: 52ch; }
.acces-carte iframe { display: block; width: 100%; aspect-ratio: 4 / 3; border: 0; background: #cfd2d1; }
.vue { margin-top: 1rem; }
.vue img { display: block; width: 100%; height: auto; }
.vue figcaption { margin-top: 0.5rem; font-size: 0.88rem; color: var(--gris-texte); }

/* Pied de page : le signal en petit, la réponse en grand */
.pied {
  background: var(--nuit);
  color: var(--lampe);
  padding: clamp(3.5rem, 8vw, 6rem) 1rem clamp(3rem, 6vw, 4.5rem);
}
.pied > * { max-width: 72rem; margin-inline: auto; }
.pied-morse { --u: clamp(0.5rem, 1.4vw, 0.9rem); gap: calc(3 * var(--u)); }
.pied-tel { margin: 1.2rem auto 2.6rem; }
.pied-tel a {
  font-weight: 800; font-stretch: 125%;
  font-size: min(6rem, 10.4vw);
  line-height: 1;
  text-decoration: none;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.pied-tel a:hover { color: #fff; text-decoration: underline; text-decoration-color: var(--rouge); text-decoration-thickness: 0.06em; }
.pied-infos { display: grid; gap: 1.4rem; color: var(--gris-nuit); }
.pied-infos a { color: var(--lampe); font-weight: 600; }

/* Barre mobile */
.barre-mobile {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  display: grid; grid-template-columns: 1.3fr 1fr;
}
.barre-mobile a {
  display: flex; align-items: center; justify-content: center;
  min-height: 3.4rem;
  font-weight: 700; font-stretch: 112%;
  text-decoration: none; color: #fff;
}
.barre-appel { background: var(--rouge); }
.barre-route { background: var(--encre); }

@media (min-width: 720px) {
  .famille { grid-template-columns: 15rem 1fr; gap: 1.5rem; }
  .famille-nom { align-self: start; padding-top: 0.85rem; flex-direction: column; align-items: flex-start; gap: 0.55rem; }
  .ligne { grid-template-columns: 13rem 1fr; gap: 1.5rem; }
  .cas { grid-template-columns: repeat(3, 1fr); column-gap: 2.5rem; }
  .deux-mots { grid-template-columns: repeat(2, 1fr); gap: clamp(2.5rem, 6vw, 6rem); }
  .pied-infos { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 600px) {
  /* le SOS sur une ligne : 27 unités */
  .grille { --u: calc(var(--w) / 27); }
  .morse { flex-direction: row; gap: calc(3 * var(--u)); }
}
@media (min-width: 900px) {
  .bandeau { position: sticky; top: 0; }
  .bandeau-nav { display: flex; }
  .barre-mobile { display: none; }
  .acces { grid-template-columns: 1fr 1.25fr; gap: 4rem; }
  .signal-bas { grid-template-columns: 1fr 1fr; align-items: end; gap: 3rem; }
}
@media (max-width: 899px) {
  body { padding-bottom: 3.4rem; }
  .signal { min-height: calc(100svh - 2.75rem - 3.4rem); }
  .bandeau { font-size: 0.8rem; }
}
