/* ==========================================================================
   2BS — Composants ajoutés : appel Romain / Gil, équipe, note Google, logo
   ========================================================================== */

/* ------------------------- Menu d'appel (Romain / Gil) ------------------ */
.call-menu { position: relative; display: inline-flex; }
.call-caret {
  width: 14px; height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 0.5s var(--ease-out);
}
.call-menu.is-open .call-caret { transform: rotate(180deg); }

.call-pop {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  z-index: 30;
  display: grid;
  min-width: 100%;
  width: max-content;
  padding: 6px;
  border: 1px solid var(--frost);
  border-radius: var(--radius);
  background: var(--white);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: opacity 0.3s ease, transform 0.5s var(--ease-out), visibility 0s linear 0.5s;
}
.call-pop::before {
  /* Pont invisible : la souris peut passer du bouton au menu sans le fermer */
  content: "";
  position: absolute;
  left: 0; right: 0; top: -10px;
  height: 10px;
}
.call-pop--right { left: auto; right: 0; }
.call-menu.is-open .call-pop {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity 0.3s ease, transform 0.5s var(--ease-out), visibility 0s;
}
.call-pop a {
  display: grid;
  grid-template-columns: 64px auto 20px;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 3px;
  opacity: 0;
  transform: translateY(6px);
  transition: background-color 0.3s ease, opacity 0.4s ease, transform 0.5s var(--ease-out);
}
.call-menu.is-open .call-pop a { opacity: 1; transform: none; }
.call-menu.is-open .call-pop a:nth-child(2) { transition-delay: 0s, 0.06s, 0.06s; }
.call-menu.is-open .call-pop a:nth-child(3) { transition-delay: 0s, 0.12s, 0.12s; }
.call-pop a:nth-child(3) { border-top: 1px solid var(--frost); border-radius: 0 0 3px 3px; }

/* Horaires sous la serrure du Dépannage, adresse du footer, compteur d'avis */
.urgence-hours { margin: -12px 0 32px; font-size: 15px; color: rgba(255, 255, 255, 0.72); }
.urgence-hours a { color: var(--white); border-bottom: 1px solid rgba(255, 255, 255, 0.4); transition: border-color 0.3s ease; }
.urgence-hours a:hover { border-color: var(--white); }
.footer-address { font-size: 14px; line-height: 1.5; color: var(--slate); }
.avis-count { font-size: 15px; color: var(--slate); }
.call-pop a:hover, .call-pop a:focus-visible { background: var(--brand-wash); }
.call-name {
  font-size: var(--fs-caption);
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.call-num {
  font-size: 19px;
  letter-spacing: -0.01em;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  transition: color 0.3s ease;
}
.call-go {
  color: var(--accent);
  opacity: 0;
  transform: translateX(-6px);
  transition: opacity 0.3s ease, transform 0.45s var(--ease-out);
}
.call-pop a:hover .call-num { color: var(--brand); }
.call-pop a:hover .call-go { opacity: 1; transform: none; }

/* --------- Hero : grand « 2BS » dans l'écriture du logo, souligné rouge ---------- */
.hero-grid { z-index: 1; }
/* Sous la carte (colonne de droite), calé à droite, en entier (plus coupé par le bas du hero) */
.hero-word {
  position: relative;
  z-index: 0;
  display: flex;
  justify-content: flex-end;
  margin-top: clamp(20px, 2.2vw, 32px);
  pointer-events: none;
  user-select: none;
}
/* Lora gras italique (proche du logo), bleu marine ; police hébergée sur le site (base.css) */
.hw-letters {
  position: relative;
  display: inline-flex;
  margin-right: -0.12em;             /* le « S » s'aligne sur le bord droit de la carte ; marges pour l'italique : rien n'est rogné */
  padding: 0.04em 0.12em 0.2em 0.06em;
  font-family: "Lora", Georgia, "Times New Roman", serif;
  font-size: clamp(100px, 10.5vw, 170px);
  /* Ordinateur : se réduit aussi selon la hauteur de l'écran pour tenir en entier sous la carte */
  font-size: clamp(64px, min(10.5vw, (100svh - 700px) * 0.98), 170px);
  font-style: italic;
  font-weight: 700;
  line-height: 0.78;
  letter-spacing: -0.02em;
  color: var(--brand);
  overflow: hidden;                  /* les lettres montent depuis leur ligne de base */
  will-change: transform;
}
.hw-letters > span { display: inline-block; will-change: transform; }
/* Trait rouge dessous, comme la clé du logo */
.hw-letters::after {
  content: "";
  position: absolute;
  left: 0.16em;
  right: 0.16em;
  bottom: 0.04em;
  height: 0.06em;
  border-radius: 0.03em;
  background: var(--accent);
}
/* Animé : il se dessine une fois les lettres arrivées, reste, puis s'efface vers la droite, en boucle */
.js-anim .hw-letters::after { clip-path: inset(0 100% 0 0); }
.js-anim .hw-letters.is-drawn::after { animation: hw-line 7s cubic-bezier(0.65, 0, 0.35, 1) infinite; }
@keyframes hw-line {
  0% { clip-path: inset(0 100% 0 0); }
  20%, 82% { clip-path: inset(0 0 0 0); }
  96%, 100% { clip-path: inset(0 0 0 100%); }
}
/* Écran d'ordinateur trop bas : pas la place de l'afficher en entier, il est masqué plutôt que coupé */
@media (min-width: 961px) and (max-height: 769px) {
  .hero-word { display: none; }
}
@media (max-width: 960px) {
  .hero-word { margin-top: var(--s-48); }
  .hw-letters { font-size: clamp(96px, 28vw, 200px); }
}

/* ---------------------------- Note Google ------------------------------- */
.stars { display: inline-flex; gap: 2px; }
.stars svg { width: 14px; height: 14px; fill: var(--accent); }
.hero-rating a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
}
.hero-rating strong { font-weight: 400; }
.hero-rating .chev { color: var(--brand); transition: transform 0.45s var(--ease-out); }
.hero-rating a:hover .chev { transform: translateX(4px); }

/* « Un artisan au bout du fil » : les visages de Romain et Gil + flèche rouge vers l'équipe */
.hero-team a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  transition: color 0.3s ease;
}
.hero-team a:hover { color: var(--brand); }
.hero-avatars { display: inline-flex; flex: none; }
.hero-avatars img {
  width: 24px; height: 24px;
  border-radius: 50%;
  object-fit: cover;
  border: 1.5px solid var(--white);
  transition: margin 0.45s var(--ease-out), transform 0.45s var(--ease-out);
}
.hero-avatars img + img { margin-left: -8px; }
.hero-team a:hover .hero-avatars img + img { margin-left: -2px; }
.hero-team a:hover .hero-avatars img:first-child { transform: rotate(-6deg); }
.hero-team-text { text-decoration: underline; text-decoration-color: var(--brand-line); text-underline-offset: 3px; transition: text-decoration-color 0.3s ease; }
.hero-team a:hover .hero-team-text { text-decoration-color: var(--brand); }
.hero-team-go {
  color: var(--accent);
  font-size: 15px;
  animation: nudge 1.8s var(--ease-in-out) infinite;   /* la flèche invite à cliquer */
}
.hero-team a:hover .hero-team-go { animation-duration: 0.9s; }

.stat-stars { display: inline-flex; gap: 4px; margin-left: 12px; vertical-align: middle; }
.stat-stars svg { width: clamp(16px, 1.6vw, 22px); height: auto; fill: var(--accent); }
.stat-label .u-link { white-space: nowrap; }

/* ------------------------- Carte « autre besoin » ----------------------- */
.card--cta { background: var(--brand); color: var(--white); }
.card--cta::before { background: radial-gradient(360px circle at var(--mx, 50%) var(--my, 0%), rgba(255, 255, 255, 0.10), transparent 70%); }
.card--cta:hover { background: var(--brand-deep); }
.card--cta .card-index { color: rgba(255, 255, 255, 0.6); }
.card--cta .card-label { color: rgba(255, 255, 255, 0.72); }
.card--cta .card-text { color: rgba(255, 255, 255, 0.82); margin-bottom: var(--s-24); }
/* Logo en grand sur une plaque blanche, comme sur le camion (le bleu du logo reste lisible) */
.card-logo {
  margin-top: auto;
  padding: 18px 20px;
  border-radius: var(--radius);
  background: var(--white);
  transition: transform 0.6s var(--ease-out);
}
.card-logo img { display: block; width: 100%; height: auto; }
.card--cta:hover .card-logo { transform: translateY(-4px); }

.ic-glass .ic-move { transform-box: view-box; }
.card:hover .ic-glass .ic-move { transform: translate(1.5px, -1.5px); }
.card:hover .ic-metal .ic-move { animation: bars 1s var(--ease-in-out); }
@keyframes bars { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(1.6px); } }

/* ------------------------------ Équipe ---------------------------------- */
.equipe { border-top: 1px solid var(--frost); }
.team-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--s-24);
  align-items: start;
}
.team-grid .team-photo:nth-child(2) { margin-top: var(--s-64); }
.team-grid .team-photo:nth-child(3) { margin-top: var(--s-32); }
.team-photo, .contact-photo { margin: 0; }
.team-frame {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--frost);
  border-radius: var(--radius);
  background: var(--mist);
}
.team-frame img {
  display: block;
  width: 100%;
  height: auto;
  transition: transform 1.2s var(--ease-out);
}
.team-frame::after {
  /* Filet rouge au survol */
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 3px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: right center;
  transition: transform 0.7s var(--ease-out);
}
.team-photo:hover .team-frame img, .contact-photo:hover .team-frame img { transform: scale(1.05); }
.team-photo:hover .team-frame::after, .contact-photo:hover .team-frame::after { transform: scaleX(1); transform-origin: left center; }
.team-photo figcaption {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding-top: 14px;
  font-size: 15px;
  color: var(--steel);
}
.team-fig {
  flex: none;
  font-size: var(--fs-caption);
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.js-anim [data-photo] .team-frame { clip-path: inset(100% 0% 0% 0%); }

/* ------------------------------- Avis ----------------------------------- */
.avis { border-top: 1px solid var(--frost); }
.avis-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: var(--s-48);
  align-items: end;
  margin-bottom: var(--s-64);
}
.avis-head .section-head { margin-bottom: 0; }
.avis-score { display: grid; justify-items: end; gap: 12px; text-align: right; }
.avis-score-value {
  font-size: clamp(64px, 1rem + 6vw, 120px);
  line-height: 0.9;
  letter-spacing: -0.05em;
  font-weight: 300;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.avis-score-value small { margin-left: 6px; font-size: 0.3em; letter-spacing: -0.02em; color: var(--muted); }
.avis-score .stat-stars { margin-left: 0; }

.avis-feature { margin: 0; padding: var(--s-48) 0; border-top: 1px solid var(--frost); }
.avis-feature blockquote { margin: 0; }
.avis-feature-text {
  max-width: 1080px;
  font-size: clamp(28px, 0.8rem + 2.8vw, 54px);
  line-height: 1.12;
  letter-spacing: -0.03em;
  font-weight: 300;
  color: var(--ink);
}
.js-anim .avis-feature-text .sw { color: var(--brand-line-soft); }
.avis-feature figcaption { margin-top: 20px; font-size: 14px; color: var(--slate); }

/* Fond bleu 2BS derrière les cartes d'avis, d'un bord à l'autre de l'écran ;
   il s'élargit au scroll comme le bloc Dépannage (--inset, --round) */
.avis { padding-bottom: 0; }
.avis-wall {
  --inset: 0px;
  --round: 0px;
  position: relative;
  isolation: isolate;
  padding-block: var(--s-80) var(--section-gap);
}
.avis-wall::before {
  content: "";
  position: absolute;
  inset: 0 calc(50% - 50vw);
  z-index: -1;
  background:
    radial-gradient(900px 600px at 12% 0%, var(--brand-hover), transparent 72%),
    radial-gradient(760px 520px at 92% 100%, var(--brand-deep), transparent 72%),
    var(--brand);
  clip-path: inset(0 var(--inset) round var(--round));
}

.avis-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--s-24);
  align-items: start;
}
.avis-col { display: grid; gap: var(--s-24); }
.avis-col:nth-child(2) { margin-top: var(--s-48); }
.avis-card {
  position: relative;
  display: grid;
  gap: 18px;
  margin: 0;
  padding: var(--s-32);
  border: 1px solid var(--frost);
  border-radius: var(--radius);
  background: var(--white);
  overflow: hidden;
  isolation: isolate;
  transition: border-color 0.4s ease, background-color 0.4s ease;
}
.avis-card::before {
  content: "\201C";
  position: absolute;
  top: -14px; right: 18px;
  z-index: -1;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 128px;
  line-height: 1;
  color: var(--brand-wash);
  transition: transform 0.8s var(--ease-out), color 0.4s ease;
}
.avis-card:hover { border-color: var(--brand-line); background: var(--mist); }
.avis-card:hover::before { transform: translateY(8px) rotate(-8deg); color: var(--accent-wash); }
.avis-card-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.avis-card .stars svg { width: 15px; height: 15px; }
.avis-tag {
  padding: 3px 10px;
  border-radius: var(--pill);
  background: var(--brand-wash);
  color: var(--brand);
  font-size: 12px;
  font-weight: 400;
  white-space: nowrap;
}
.avis-card blockquote { margin: 0; }
.avis-card blockquote p { font-size: 16px; line-height: 1.55; color: var(--steel); }
.avis-card figcaption {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 16px;
  border-top: 1px solid var(--frost);
}
.avis-avatar {
  flex: none;
  display: grid;
  place-items: center;
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--brand);
  color: var(--white);
  font-size: 15px;
  font-weight: 400;
  transition: transform 0.5s var(--ease-out), background-color 0.3s ease;
}
.avis-card:hover .avis-avatar { transform: rotate(-10deg) scale(1.08); background: var(--accent); }
.avis-card figcaption strong { display: block; font-size: 15px; font-weight: 400; color: var(--ink); }
.avis-card figcaption small { display: block; font-size: 12px; letter-spacing: 0.02em; color: var(--muted); }
.js-anim [data-review] { opacity: 0; }

/* ------------------------ Carte : base de l'atelier --------------------- */
.z-base .z-dot { fill: var(--accent); stroke: var(--white); stroke-width: 2; }
.z-label--base { opacity: 1; fill: var(--accent); font-size: 13px; }
.z-base-ring {
  fill: none;
  stroke: var(--accent);
  stroke-width: 1.25;
  transform-box: fill-box;
  transform-origin: center;
  animation: ring-pulse 2.2s var(--ease-out) infinite;
}
.z-edge { stroke: var(--brand-line); }

/* ---------------------- Avatars de Romain et Gil ------------------------ */
.call-pop a { grid-template-columns: 36px 64px auto 20px; }
.call-avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  object-fit: cover;
  transition: transform 0.5s var(--ease-out);
}
.call-avatar--logo { padding: 3px; background: var(--white); border: 1px solid var(--frost); }
.call-pop a:hover .call-avatar { transform: scale(1.08) rotate(-4deg); }

/* Légendes des photos : seulement le prénom */
.team-cap strong { font-weight: 400; color: var(--ink); }

/* Picto « persiennes » au survol */
.card:hover .ic-persienne .ic-move { transform: translateY(1.6px); }

/* Bouton « Lire les avis » sous la grille */
.avis-more { display: flex; justify-content: center; margin-top: var(--s-64); }

/* Noms des départements sur la carte */
.z-dept {
  fill: var(--muted);
  font-family: var(--font);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* ----------------------- Nos métiers en images -------------------------- */
.metiers { margin-top: var(--s-80); }
.metiers-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-16);
  margin-bottom: var(--s-24);
}
.metiers-hint { display: none; font-size: var(--fs-body-sm); color: var(--brand); }
.metiers-hint span { display: inline-block; animation: nudge 1.6s var(--ease-in-out) infinite; }
.metiers-viewport {
  /* Pleine largeur d'écran, alignée à gauche sur le contenu */
  margin-inline: calc(50% - 50vw);
  padding-inline: max(var(--gutter), calc((100vw - var(--max)) / 2));
  overflow: hidden;
}
.metiers-track {
  display: flex;
  gap: var(--s-24);
  width: max-content;
  will-change: transform;
}
.metier {
  flex: none;
  width: clamp(230px, 22vw, 300px);
  margin: 0;
}
.metier .team-frame img { aspect-ratio: 4 / 5; object-fit: cover; }
.metier:hover .team-frame img { transform: scale(1.06); }
.metier:hover .team-frame::after { transform: scaleX(1); transform-origin: left center; }
.metier figcaption { display: grid; gap: 4px; padding-top: 14px; }
.metier-label {
  font-size: var(--fs-caption);
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}
.metier-title {
  font-size: 17px;
  line-height: 1.35;
  letter-spacing: -0.01em;
  color: var(--ink);
  transition: color 0.3s ease;
}
.metier:hover .metier-title { color: var(--brand); }

@media (max-width: 960px) {
  .metiers-hint { display: inline-flex; gap: 8px; }
  .metiers-viewport {
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: var(--gutter);
    scrollbar-width: none;
  }
  .metiers-viewport::-webkit-scrollbar { display: none; }
  .metier { width: min(68vw, 280px); scroll-snap-align: start; }
}

/* ------------------------------ Contact --------------------------------- */
.contact-photo { width: 100%; }

/* ------------------------------- Footer --------------------------------- */
.footer-logo { display: inline-block; }
.footer-logo img {
  display: block;
  width: min(300px, 100%);
  height: auto;
  transition: transform 0.6s var(--ease-out);
}
.footer-logo:hover img { transform: scale(1.02); }
.footer-contacts { display: grid; gap: 10px; }
.footer-contacts .link-chevron { font-size: 16px; font-variant-numeric: tabular-nums; }
.footer-name {
  width: 64px;
  font-size: var(--fs-caption);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.footer-mail { justify-self: start; font-size: 15px; }

/* -------------------------- Menu mobile & barre ------------------------- */
.menu-ctas {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--s-8);
  margin-top: auto;
}
.menu-ctas .btn { flex-direction: column; gap: 4px; min-height: 64px; font-variant-numeric: tabular-nums; }
.menu-cta-name { font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.75; }
.menu-cta-wide { grid-column: 1 / -1; }

.callbar .btn { padding-inline: 10px; gap: 6px; min-height: 46px; }
.callbar .btn:last-child { flex: 0.8; }

/* ----------------------------- Responsive ------------------------------- */
@media (max-width: 960px) {
  .avis-head { grid-template-columns: minmax(0, 1fr); align-items: start; gap: var(--s-32); }
  .avis-score { justify-items: start; text-align: left; }
  .avis-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .avis-col { display: contents; }
  .team-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .team-grid .team-photo:first-child { grid-column: 1 / -1; }
  /* Photo de Romain et Gil sur toute la largeur : cadrage carré calé en haut, les têtes restent entières */
  .team-grid .team-photo:first-child .team-frame img { aspect-ratio: 1 / 1; object-fit: cover; object-position: 50% 4%; }
  .team-grid .team-photo:nth-child(2) { margin-top: 0; }
  .team-grid .team-photo:nth-child(3) { margin-top: 0; }
}
@media (max-width: 640px) {
  .avis-grid { grid-template-columns: minmax(0, 1fr); }
  .avis-card { padding: var(--s-24); }
  .avis-feature { padding: var(--s-32) 0; }
  .avis-wall { padding-top: var(--s-48); }
  .team-grid { grid-template-columns: minmax(0, 1fr); }
  /* Téléphone : photo entière, comme les deux autres (place réservée avant le chargement : pas de saut de page) */
  .team-grid .team-photo:first-child .team-frame img { aspect-ratio: auto 618 / 825; }
}
