/* ============================================================
   Usmotors — mécanicien mobile, Dakar
   Palette : tirage photo désaturé années 70
   ============================================================ */

:root {
  --bg:      #efe6d0;
  --bg-2:    #e6d9bd;
  --paper:   #f6efdd;
  --ink:     #3a2f1a;
  --ink-soft:#6b5c3d;
  --a:       #a67c00;  /* moutarde */
  --b:       #6b7a3a;  /* vert avocat */
  --c:       #c04e1a;  /* terre de sienne brûlée */
  --rule:    rgba(58, 47, 26, 0.22);
  --rule-2:  rgba(58, 47, 26, 0.12);

  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans:  "Bricolage Grotesque", "Helvetica Neue", Arial, sans-serif;
  --mono:  "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --pad: clamp(1.25rem, 5vw, 4.5rem);
  --spine: 4.5rem;
  --maxw: 1180px;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background-color: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: clamp(1rem, 0.55vw + 0.9rem, 1.075rem);
  line-height: 1.62;
  font-variation-settings: "opsz" 16;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* --- grain filmique sur toute la page --- */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  opacity: 0.055;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/><feColorMatrix type='saturate' values='0'/></filter><rect width='220' height='220' filter='url(%23n)'/></svg>");
}

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

a { color: inherit; }

h1, h2, h3, blockquote p {
  font-family: var(--serif);
  font-variation-settings: "opsz" 96;
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.015em;
  margin: 0;
  text-wrap: balance;
}

p { margin: 0 0 1rem; }
p:last-child { margin-bottom: 0; }

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

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--ink); color: var(--paper);
  padding: 0.6rem 1rem; z-index: 10000;
}
.skip:focus { left: 0.5rem; top: 0.5rem; }

.eyebrow {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--c);
  margin: 0 0 0.9rem;
}

/* ============================================================
   Barre de progression de lecture — élément de design
   ============================================================ */
.progress {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 5px;
  z-index: 60;
  background: var(--rule-2);
}
.progress__fill {
  display: block;
  height: 100%;
  transform-origin: 0 50%;
  transform: scaleX(0);
  background: linear-gradient(90deg, var(--a), var(--c) 55%, var(--b));
}
@supports (animation-timeline: scroll()) {
  .progress__fill {
    animation: fill linear both;
    animation-timeline: scroll(root block);
  }
}
@keyframes fill { to { transform: scaleX(1); } }

/* ============================================================
   Barre supérieure
   ============================================================ */
.topbar {
  position: sticky;
  top: 5px;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.7rem var(--pad) 0.7rem calc(var(--pad) + var(--spine));
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--rule);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  margin-right: auto;
}
.brand__mark {
  display: grid; place-items: center;
  width: 34px; height: 34px;
  background: var(--ink);
  color: var(--bg);
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
}
.brand__name {
  font-family: var(--serif);
  font-weight: 900;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}

.topbar__nav {
  display: none;
  gap: 1.4rem;
  font-size: 0.9rem;
}
.topbar__nav a {
  text-decoration: none;
  padding: 0.35rem 0;
  border-bottom: 1px solid transparent;
}
.topbar__nav a:hover { border-bottom-color: var(--c); }

.callbtn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 44px;
  padding: 0.5rem 0.95rem;
  background: var(--c);
  color: #fdf6e6;
  text-decoration: none;
  font-family: var(--mono);
  font-size: 0.82rem;
  letter-spacing: 0.02em;
  border: 1px solid var(--ink);
  transition: transform 0.15s ease, background 0.15s ease;
}
.callbtn:hover { background: var(--ink); transform: translateY(-1px); }
.callbtn__dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: #fdf6e6;
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: 0.35; transform: scale(0.7); }
}

/* ============================================================
   HÉROS
   ============================================================ */
.hero {
  position: relative;
  padding: clamp(2.5rem, 7vw, 5.5rem) var(--pad) clamp(2rem, 5vw, 4rem) calc(var(--pad) + var(--spine));
  display: grid;
  gap: clamp(2rem, 5vw, 3.5rem);
  align-items: center;
}

/* Titre vertical — colonne vertébrale de la page */
.spine {
  position: fixed;
  left: 0.9rem;
  top: 50%;
  transform: translateY(-50%);
  writing-mode: vertical-rl;
  text-orientation: mixed;
  font-size: clamp(0.72rem, 1.1vw, 0.95rem);
  font-family: var(--mono);
  font-weight: 400;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin: 0;
  z-index: 40;
  pointer-events: none;
  white-space: nowrap;
}
.spine::after {
  content: "";
  display: block;
  width: 1px;
  height: 4rem;
  margin: 1rem auto 0;
  background: var(--rule);
}

.hero__lede {
  font-family: var(--serif);
  font-variation-settings: "opsz" 96;
  font-weight: 400;
  font-size: clamp(1.35rem, 3.1vw, 2.15rem);
  line-height: 1.28;
  letter-spacing: -0.02em;
  max-width: 30ch;
  margin: 0 0 1.6rem;
}
.hero__lede::first-letter {
  color: var(--c);
  font-weight: 900;
}

/* --- visualiseur : barres animées sous le nom --- */
.viz {
  display: flex;
  align-items: flex-end;
  gap: 4px;
  height: 46px;
  margin: 0 0 1.8rem;
  max-width: 420px;
}
.viz__bar {
  flex: 1 1 auto;
  min-width: 3px;
  height: 100%;
  background: var(--b);
  transform-origin: 50% 100%;
  transform: scaleY(0.18);
  animation: bar 1.5s ease-in-out infinite alternate;
}
.viz__bar:nth-child(3n)   { background: var(--a); }
.viz__bar:nth-child(4n+1) { background: var(--c); }
.viz__bar:nth-child(1)  { animation-delay: -0.10s; animation-duration: 1.15s; }
.viz__bar:nth-child(2)  { animation-delay: -0.55s; animation-duration: 1.62s; }
.viz__bar:nth-child(3)  { animation-delay: -0.30s; animation-duration: 1.30s; }
.viz__bar:nth-child(4)  { animation-delay: -0.80s; animation-duration: 1.48s; }
.viz__bar:nth-child(5)  { animation-delay: -0.20s; animation-duration: 1.05s; }
.viz__bar:nth-child(6)  { animation-delay: -0.65s; animation-duration: 1.70s; }
.viz__bar:nth-child(7)  { animation-delay: -0.42s; animation-duration: 1.22s; }
.viz__bar:nth-child(8)  { animation-delay: -0.95s; animation-duration: 1.55s; }
.viz__bar:nth-child(9)  { animation-delay: -0.15s; animation-duration: 1.38s; }
.viz__bar:nth-child(10) { animation-delay: -0.70s; animation-duration: 1.12s; }
.viz__bar:nth-child(11) { animation-delay: -0.35s; animation-duration: 1.66s; }
.viz__bar:nth-child(12) { animation-delay: -0.88s; animation-duration: 1.28s; }
.viz__bar:nth-child(13) { animation-delay: -0.05s; animation-duration: 1.44s; }
.viz__bar:nth-child(14) { animation-delay: -0.60s; animation-duration: 1.18s; }
.viz__bar:nth-child(15) { animation-delay: -0.25s; animation-duration: 1.58s; }
.viz__bar:nth-child(16) { animation-delay: -0.75s; animation-duration: 1.34s; }
.viz__bar:nth-child(17) { animation-delay: -0.48s; animation-duration: 1.08s; }
.viz__bar:nth-child(18) { animation-delay: -0.92s; animation-duration: 1.72s; }
.viz__bar:nth-child(19) { animation-delay: -0.12s; animation-duration: 1.26s; }
.viz__bar:nth-child(20) { animation-delay: -0.68s; animation-duration: 1.50s; }
.viz__bar:nth-child(21) { animation-delay: -0.38s; animation-duration: 1.14s; }
.viz__bar:nth-child(22) { animation-delay: -0.85s; animation-duration: 1.60s; }
.viz__bar:nth-child(23) { animation-delay: -0.22s; animation-duration: 1.32s; }
.viz__bar:nth-child(24) { animation-delay: -0.58s; animation-duration: 1.20s; }
.viz__bar:nth-child(25) { animation-delay: -0.44s; animation-duration: 1.68s; }
.viz__bar:nth-child(26) { animation-delay: -0.98s; animation-duration: 1.10s; }
@keyframes bar {
  from { transform: scaleY(0.14); }
  to   { transform: scaleY(1); }
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-bottom: 2rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0.75rem 1.5rem;
  font-family: var(--mono);
  font-size: 0.84rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  border: 1px solid var(--ink);
  transition: transform 0.15s ease, background 0.15s ease, color 0.15s ease;
}
.btn--primary { background: var(--ink); color: var(--bg); }
.btn--primary:hover { background: var(--c); transform: translateY(-2px); }
.btn--ghost { background: transparent; color: var(--ink); }
.btn--ghost:hover { background: var(--ink); color: var(--bg); }
.btn--wide { width: 100%; max-width: 26rem; }

.hero__facts {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
  border-top: 1px solid var(--rule);
  padding-top: 1.2rem;
  max-width: 34rem;
}
.hero__facts li { display: flex; flex-direction: column; gap: 0.15rem; }
.hero__facts strong {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
  font-weight: 400;
}
.hero__facts span { font-family: var(--serif); font-size: 1.05rem; }

.hero__figure {
  margin: 0;
  position: relative;
}
.hero__figure img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border: 1px solid var(--ink);
  filter: saturate(0.72) contrast(1.04) sepia(0.14);
}
.hero__figure figcaption {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  color: var(--ink-soft);
  margin-top: 0.6rem;
}

/* ============================================================
   Sections — règle commune
   ============================================================ */
section { scroll-margin-top: 5rem; }

.section-head {
  max-width: 46rem;
  margin-bottom: clamp(1.8rem, 4vw, 3rem);
}
.section-head h2 {
  font-size: clamp(1.7rem, 4vw, 2.7rem);
  margin-bottom: 1rem;
}
.section-head__note {
  color: var(--ink-soft);
  font-size: 0.95rem;
  max-width: 52ch;
}

/* ============================================================
   PRESTATIONS — bloc « menu »
   ============================================================ */
.services {
  padding: clamp(3rem, 7vw, 5.5rem) var(--pad) clamp(3rem, 7vw, 5.5rem) calc(var(--pad) + var(--spine));
  background: var(--paper);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

.menu {
  display: grid;
  gap: clamp(2rem, 4vw, 3.25rem);
}
@media (min-width: 900px) {
  .menu { grid-template-columns: 1fr 1fr; column-gap: clamp(2.5rem, 6vw, 5rem); }
}

.menu__group h3 {
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink);
  border-bottom: 2px solid var(--ink);
  padding-bottom: 0.55rem;
  margin-bottom: 1.1rem;
}

.item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.4rem 1.25rem;
  align-items: baseline;
  padding: 0.85rem 0;
  border-bottom: 1px dotted var(--rule);
}
.item:last-child { border-bottom: 0; }

.item__name {
  font-family: var(--serif);
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0 0 0.2rem;
  letter-spacing: -0.01em;
}
.item__desc {
  margin: 0;
  font-size: 0.88rem;
  line-height: 1.5;
  color: var(--ink-soft);
  max-width: 42ch;
}
.item__price {
  margin: 0;
  font-family: var(--mono);
  font-size: 0.92rem;
  font-weight: 600;
  white-space: nowrap;
  color: var(--c);
  text-align: right;
}
.item__price span { font-size: 0.68rem; letter-spacing: 0.08em; color: var(--ink-soft); }
.item__unit { color: var(--ink-soft); }

.menu__foot {
  margin-top: clamp(2rem, 4vw, 3rem);
  padding-top: 1.2rem;
  border-top: 1px solid var(--rule);
  font-size: 0.88rem;
  color: var(--ink-soft);
  max-width: 60ch;
}

/* ============================================================
   ATELIER
   ============================================================ */
.atelier {
  padding: clamp(3rem, 7vw, 5.5rem) var(--pad) clamp(3rem, 7vw, 5.5rem) calc(var(--pad) + var(--spine));
}
.atelier__grid {
  display: grid;
  gap: clamp(2rem, 5vw, 3.5rem);
}
@media (min-width: 900px) {
  .atelier__grid { grid-template-columns: 1.05fr 0.95fr; align-items: start; }
}
.atelier__copy p { max-width: 58ch; }

.atelier__list {
  list-style: none;
  margin: 1.8rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.7rem;
}
.atelier__list li {
  padding-left: 1.1rem;
  position: relative;
  font-size: 0.92rem;
  color: var(--ink-soft);
}
.atelier__list li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.62em;
  width: 0.5rem; height: 2px;
  background: var(--c);
}
.atelier__list strong { color: var(--ink); }

.atelier__figures {
  display: grid;
  gap: 1.5rem;
}
.atelier__figures figure { margin: 0; }
.atelier__figures img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border: 1px solid var(--ink);
  filter: saturate(0.72) contrast(1.04) sepia(0.14);
}
.atelier__figures figcaption {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.05em;
  color: var(--ink-soft);
  margin-top: 0.5rem;
}

/* ============================================================
   CARTES : horaires / contact / zone
   ============================================================ */
.cards {
  padding: clamp(3rem, 7vw, 5.5rem) var(--pad) clamp(3rem, 7vw, 5.5rem) calc(var(--pad) + var(--spine));
  background: var(--bg-2);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  display: grid;
  gap: clamp(1.5rem, 3vw, 2.5rem);
}
@media (min-width: 860px) {
  .cards { grid-template-columns: repeat(3, 1fr); }
}

.card {
  background: var(--paper);
  border: 1px solid var(--ink);
  padding: clamp(1.3rem, 2.5vw, 1.9rem);
  display: flex;
  flex-direction: column;
}
.card h3 {
  font-family: var(--mono);
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin: 0 0 1.1rem;
  padding-bottom: 0.55rem;
  border-bottom: 2px solid var(--ink);
}
.card__lead { font-size: 0.92rem; color: var(--ink-soft); }
.card__note {
  font-size: 0.82rem;
  color: var(--ink-soft);
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px dotted var(--rule);
}

.hours { margin: 0; display: grid; gap: 0.35rem; }
.hours div {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1rem;
  font-size: 0.9rem;
  padding-bottom: 0.3rem;
  border-bottom: 1px dotted var(--rule-2);
}
.hours dt { color: var(--ink-soft); }
.hours dd { margin: 0; font-family: var(--mono); font-size: 0.82rem; }
.hours__closed dt, .hours__closed dd { color: var(--c); }

.phone-big {
  display: block;
  font-family: var(--serif);
  font-weight: 900;
  font-size: clamp(1.6rem, 4vw, 2.1rem);
  letter-spacing: -0.02em;
  text-decoration: none;
  color: var(--c);
  margin: 0.4rem 0 1.1rem;
  border-bottom: 2px solid transparent;
  transition: border-color 0.15s ease;
}
.phone-big:hover { border-bottom-color: var(--c); }

.addr {
  font-style: normal;
  font-size: 0.92rem;
  line-height: 1.6;
  color: var(--ink-soft);
  margin-bottom: 1rem;
}

.card__fig { margin: 0 0 1rem; }
.card__fig img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border: 1px solid var(--ink);
  filter: saturate(0.72) contrast(1.04) sepia(0.14);
}

.zones {
  list-style: none;
  margin: 0 0 1rem;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}
.zones li {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.28rem 0.55rem;
  border: 1px solid var(--rule);
  color: var(--ink-soft);
}

/* ============================================================
   CLÔTURE
   ============================================================ */
.closing {
  padding: clamp(3rem, 8vw, 6rem) var(--pad) clamp(3rem, 8vw, 6rem) calc(var(--pad) + var(--spine));
  display: grid;
  gap: 2rem;
  justify-items: start;
}
.closing blockquote {
  margin: 0;
  max-width: 34ch;
}
.closing blockquote p {
  font-size: clamp(1.4rem, 3.6vw, 2.3rem);
  font-style: italic;
  font-weight: 400;
}
.closing blockquote footer {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-top: 1rem;
}

/* ============================================================
   PIED DE PAGE
   ============================================================ */
.site-foot {
  background: var(--ink);
  color: var(--bg);
  padding: clamp(2rem, 4vw, 3rem) var(--pad) 4.5rem calc(var(--pad) + var(--spine));
}
.site-foot__inner { max-width: var(--maxw); }
.site-foot__brand {
  font-family: var(--serif);
  font-weight: 900;
  font-size: 1.15rem;
  margin: 0 0 0.4rem;
}
.site-foot__meta {
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.04em;
  color: color-mix(in srgb, var(--bg) 72%, transparent);
  margin: 0 0 1.4rem;
}
.site-foot__meta a { color: inherit; }

.claim-banner {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.04em;
  padding: 0.45rem 0.75rem;
  background: color-mix(in srgb, var(--bg) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--bg) 26%, transparent);
  color: color-mix(in srgb, var(--bg) 86%, transparent);
  text-decoration: none;
  margin-bottom: 1rem;
}
.claim-banner:hover {
  background: color-mix(in srgb, var(--bg) 20%, transparent);
  color: var(--bg);
}

.muted.attribution {
  margin: 0;
  font-size: 0.7rem;
  opacity: 0.6;
}
.muted.attribution a { color: inherit; }

/* ============================================================
   Écrans larges
   ============================================================ */
@media (min-width: 820px) {
  .topbar__nav { display: flex; }
  .hero {
    grid-template-columns: 1.05fr 0.95fr;
    align-items: center;
  }
  .hero__figure { align-self: stretch; }
  .hero__figure img { height: 100%; aspect-ratio: auto; min-height: 420px; }
}

@media (min-width: 1100px) {
  .hero { padding-top: clamp(3rem, 6vw, 6rem); }
}

/* ============================================================
   Petits écrans
   ============================================================ */
@media (max-width: 700px) {
  :root { --spine: 0rem; }
  .spine {
    position: static;
    writing-mode: horizontal-tb;
    transform: none;
    font-size: 0.68rem;
    letter-spacing: 0.18em;
    margin: 0 0 1.1rem;
    display: block;
  }
  .spine::after { display: none; }
  .topbar { padding-left: var(--pad); }
  .hero, .services, .atelier, .cards, .closing, .site-foot {
    padding-left: var(--pad);
  }
  .brand__name { font-size: 1rem; }
  .callbtn { font-size: 0.74rem; padding: 0.5rem 0.7rem; }
  .item { grid-template-columns: 1fr; }
  .item__price { text-align: left; margin-top: 0.25rem; }
  .viz { height: 34px; }
}

/* ============================================================
   Mouvement réduit
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .viz__bar {
    animation: none;
    transform: scaleY(0.55);
  }
  .viz__bar:nth-child(2n) { transform: scaleY(0.85); }
  .viz__bar:nth-child(3n) { transform: scaleY(0.35); }
  .callbtn__dot { animation: none; }
  .progress__fill { transform: scaleX(1); animation: none; }
  .btn:hover, .callbtn:hover { transform: none; }
}
