/* =========================================================
   POLICES (hébergées sur notre serveur, licence SIL OFL dans /fonts)
   Archivo variable : graisse 100–900 ET largeur 62–125 %, d'où font-stretch.
   Sous-ensemble « latin » : couvre le français et l'allemand (ä ö ü é è ç…).
   ========================================================= */
@font-face {
  font-family: "Archivo";
  src: url("../fonts/archivo-latin-var.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("../fonts/ibm-plex-mono-latin-400.woff2") format("woff2");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "IBM Plex Mono";
  src: url("../fonts/ibm-plex-mono-latin-600.woff2") format("woff2");
  font-weight: 600; font-style: normal; font-display: swap;
}

/* =========================================================
   TOKENS
   Le thème suit l'heure réelle (nuit 19h–7h) : un dépanneur
   travaille la nuit, le site aussi. Bascule manuelle possible.
   ========================================================= */

:root {
  --amber: #ffae00;          /* gyrophare */
  --sign-blue: #0f4c9c;      /* panneau de direction, route principale */
  --red: #d7322a;            /* triangle de panne */
  --paper: #f7f6f1;          /* papier thermique du ticket */
  --asphalt: #1b1f24;        /* fond des blocs toujours sombres */
  --font: "Archivo", system-ui, sans-serif;
  /* Titres : si Archivo ne charge pas (aperçu hors ligne, réseau filtré),
     on retombe sur une police déjà condensée plutôt que sur une police large
     qui ferait déborder les titres. */
  --display: "Archivo", "Avenir Next Condensed", "Roboto Condensed", "Arial Narrow", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --header: 68px;            /* hauteur de l'en-tête collant */
  --sec-pad: 112px;          /* marge verticale des sections */
}
:root[data-theme="night"] {
  --bg: #1b1f24; --bg-2: #232830; --ink: #eef0ee; --muted: #9aa1a6;
  --line: #333a42; --steel: #b4b8b8; --accent-ink: var(--amber);
}
:root[data-theme="day"] {
  --bg: #d9d8d2; --bg-2: #e6e5e0; --ink: #16191d; --muted: #545a5f;
  --line: #b9b8b1; --steel: #3d4246; --accent-ink: #8a5600;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: 18px; line-height: 1.5;
  overflow-x: clip; transition: background-color .5s, color .5s;
}
/* Grain d'asphalte, très léger */
body::before {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 100; opacity: .05;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}
a { color: inherit; }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 3px; }
.wrap { width: min(1220px, 100% - 32px - env(safe-area-inset-left) - env(safe-area-inset-right)); margin-inline: auto; }

/* Titres : condensés, casse normale (comme la signalisation suisse) */
h1, h2, h3 { margin: 0; font-family: var(--display); font-weight: 820; font-stretch: 66%; line-height: .92; letter-spacing: -.005em; overflow-wrap: break-word; text-wrap: balance; }

/* Ancres du menu : le titre de la section arrive juste sous l'en-tête collant
   (on compense la marge haute de la section pour ne pas laisser un grand vide). */
.sec[id] { scroll-margin-top: calc(var(--header) - var(--sec-pad) + 28px); }
.sec.flush[id] { scroll-margin-top: calc(var(--header) + 28px); }
.contact { scroll-margin-top: calc(var(--header) - 104px + 40px); }
h2 { font-size: clamp(40px, 6vw, 88px); }
p { margin: 0; }

/* ---------- Gyrophare ---------- */
.beacon {
  --s: 12px; position: relative; display: inline-block; flex: none;
  width: var(--s); height: var(--s); border-radius: 50%; overflow: hidden;
  background: #6b4300; animation: glow 1.6s ease-in-out infinite;
}
.beacon::before {
  content: ""; position: absolute; inset: -50%;
  background: conic-gradient(var(--amber) 0 80deg, transparent 80deg 180deg, var(--amber) 180deg 260deg, transparent 260deg);
  animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes glow { 50% { box-shadow: 0 0 14px 3px rgba(255,174,0,.55); } }

/* ---------- En-tête ---------- */
.top { position: sticky; top: 0; z-index: 40; background: var(--bg); border-bottom: 1px solid var(--line); transition: background-color .5s; }
.top-in { display: flex; align-items: center; gap: 28px; height: var(--header); }
/* Sprite caché sans display:none (sinon le clipPath du logo ne s'applique plus dans Firefox) */
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.badge { display: block; flex: none; height: auto; }

.logo { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.logo .badge { width: 72px; }   /* ≈ 57 px de haut : tient dans l'en-tête de 68 px */
.logo-sub { font-size: 12px; line-height: 1.15; color: var(--muted); font-stretch: 85%; padding-left: 12px; border-left: 1px solid var(--line); }
.nav { display: flex; gap: 24px; margin-left: auto; font-stretch: 85%; font-weight: 550; font-size: 16px; }
.nav a { text-decoration: none; padding-block: 4px; border-bottom: 2px solid transparent; }
.nav a:hover { border-color: var(--amber); }
/* Boutons icône de l'en-tête : 44 px minimum, la taille d'un pouce */
.icon-btn {
  display: inline-grid; place-items: center; width: 44px; height: 44px; padding: 0; flex: none; cursor: pointer;
  background: none; color: var(--ink); border: 1px solid var(--line); border-radius: 50%;
}
.icon-btn:hover { border-color: var(--ink); }
.theme svg { width: 20px; height: 20px; }
/* On montre le mode en cours : lune la nuit, soleil le jour */
:root[data-theme="night"] .i-sun, :root[data-theme="day"] .i-moon { display: none; }

/* Hamburger : trois traits qui se croisent en X à l'ouverture */
.burger { display: none; }
.burger span, .burger span::before, .burger span::after {
  display: block; width: 20px; height: 2px; background: currentColor; transition: transform .25s, background-color .25s;
}
.burger span { position: relative; }
.burger span::before, .burger span::after { content: ""; position: absolute; left: 0; }
.burger span::before { transform: translateY(-6px); }
.burger span::after { transform: translateY(6px); }
.burger[aria-expanded="true"] span { background: transparent; }
.burger[aria-expanded="true"] span::before { transform: rotate(45deg); }
.burger[aria-expanded="true"] span::after { transform: rotate(-45deg); }

/* Panneau du menu mobile, sous l'en-tête */
.mnav {
  position: fixed; z-index: 39; left: 0; right: 0; top: var(--header); bottom: 0;
  display: flex; flex-direction: column; overflow-y: auto; overscroll-behavior: contain;
  padding: 8px 16px calc(24px + env(safe-area-inset-bottom));
  background: var(--bg); border-top: 1px solid var(--line);
  visibility: hidden; opacity: 0; transform: translateY(-10px);
  transition: opacity .2s, transform .2s, visibility 0s .2s;
}
.mnav.open { visibility: visible; opacity: 1; transform: none; transition: opacity .2s, transform .2s; }
.mnav nav { display: flex; flex-direction: column; }
.mnav nav a {
  display: flex; justify-content: space-between; align-items: center; padding: 16px 2px; text-decoration: none;
  border-bottom: 1px solid var(--line);
  font-family: var(--display); font-size: 34px; font-weight: 800; font-stretch: 66%; line-height: 1;
}
.mnav nav a::after { content: ""; width: 10px; height: 10px; border-top: 2px solid var(--muted); border-right: 2px solid var(--muted); transform: rotate(45deg); }
.mnav-actions { display: grid; gap: 10px; margin-top: auto; padding-top: 28px; }
.mnav-actions .btn { justify-content: center; }
.mnav-note { margin-top: 12px; text-align: center; font-size: 15px; color: var(--muted); }
body.menu-open { overflow: hidden; }
.top-call {
  display: inline-flex; align-items: center; gap: 10px; padding: 9px 14px;
  background: var(--amber); color: #1a1a1a; text-decoration: none;
  font-weight: 800; font-stretch: 75%; font-size: 19px; letter-spacing: .01em;
}
.top-call .beacon { background: #7a4d00; }

/* ---------- Hero ---------- */
/* Le hero occupe exactement l'écran sous l'en-tête dès l'affichage.
   svh = hauteur visible sur mobile, barre d'adresse comprise (vh en secours). */
.hero {
  position: relative; overflow: hidden; display: grid;
  min-height: calc(100vh - var(--header));
  min-height: calc(100svh - var(--header));
  border-bottom: 10px solid transparent;
  border-image: repeating-linear-gradient(-45deg, var(--amber) 0 14px, var(--asphalt) 14px 28px) 10;
}

.hero-in { position: relative; isolation: isolate; display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .85fr); gap: 40px; }
.hero-copy { display: flex; flex-direction: column; justify-content: center; padding: 40px 0 56px; }

.rig-zone { position: relative; align-self: stretch; }
/* Sur grand écran, le treuil est sorti du flux : quand le câble se déroule,
   il ne pousse pas le reste de la page (sinon les ancres tombent à côté). */
@media (min-width: 1001px) {
  .rig { position: absolute; top: 0; left: 0; right: 0; width: max-content; margin-inline: auto; }
}
.status { display: flex; align-items: center; gap: 10px; color: var(--muted); font-stretch: 85%; font-size: 16px; }
.status b { color: var(--ink); font-weight: 650; }
/* Taille du titre bornée par la largeur ET la hauteur de l'écran :
   il tient dans le hero même sur un portable de 720 px de haut. */
.hero h1 { margin-top: 22px; font-size: clamp(44px, min(6.6vw, 11.5vh), 124px); font-stretch: 62%; font-weight: 860; line-height: .88; }
.hero h1 .q { display: block; margin-bottom: .14em; font-size: .46em; font-stretch: 75%; font-weight: 700; line-height: 1.05; color: var(--accent-ink); }
.clock-line { margin-top: clamp(16px, 3vh, 26px); font-size: 21px; font-stretch: 85%; }
.clock-line [data-clock] { font-weight: 800; color: var(--accent-ink); margin-right: .35em; font-variant-numeric: tabular-nums; }
.lede { margin-top: 10px; max-width: 34em; color: var(--muted); }
.cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: clamp(20px, 3.5vh, 34px); }
.btn {
  display: inline-flex; align-items: center; gap: 12px; padding: 17px 22px; cursor: pointer;
  border: 2px solid transparent; text-decoration: none;
  font: 800 19px/1 var(--font); font-stretch: 75%; letter-spacing: .01em;
}
.btn-call { background: var(--amber); color: #1a1a1a; background-size: 40px 40px; }
/* Au survol : rayures de chantier qui défilent, comme une barrière */
.btn-call:hover {
  background-image: repeating-linear-gradient(-45deg, transparent 0 10px, rgba(0,0,0,.09) 10px 20px);
  animation: stripes .7s linear infinite;
}
@keyframes stripes { to { background-position: 40px 0; } }
.btn-call .num { font-variant-numeric: tabular-nums; font-weight: 900; }
.btn-geo { background: transparent; color: var(--ink); border-color: currentColor; }
.btn-geo:hover { background: var(--ink); color: var(--bg); }
.btn-geo[aria-busy="true"] { opacity: .6; cursor: progress; }
.btn svg { width: 20px; height: 20px; flex: none; }
.fine { margin-top: 14px; font-size: 14px; color: var(--muted); max-width: 36em; }

/* ---------- Le treuil : poulie, câble, crochet, ticket ---------- */
.rig-zone { display: flex; justify-content: center; }
.rig {
  --cable: 84px;
  display: flex; flex-direction: column; align-items: center;
  transform-origin: 50% 0; animation: sway 7s ease-in-out infinite;
}
@keyframes sway { 0%,100% { transform: rotate(-1.4deg); } 50% { transform: rotate(1.4deg); } }
.pulley { width: 30px; height: 30px; border-radius: 50%; margin-top: -15px;
  background: radial-gradient(circle, var(--bg) 0 4px, var(--steel) 5px 11px, #555 12px 15px); }
.cable { width: 3px; height: var(--cable);
  background: repeating-linear-gradient(to bottom, var(--steel) 0 5px, #6c6f70 5px 7px); }
.hook { position: relative; z-index: 2; color: var(--steel); margin-bottom: -38px; display: block; }
.hook .latch { stroke: var(--amber); }

.ticket {
  position: relative; width: min(330px, 86vw); margin-left: -18px; padding: 40px 22px 18px;
  background: var(--paper); color: #1d1d1b; font-family: var(--mono); font-size: 13px; line-height: 1.55;
  transform: rotate(-1.2deg); box-shadow: 0 34px 50px -24px rgba(0,0,0,.6);
}
.ticket::before { /* trou de suspension */
  content: ""; position: absolute; top: 10px; left: 50%; width: 18px; height: 18px; margin-left: -9px;
  border-radius: 50%; background: var(--bg); box-shadow: inset 0 2px 3px rgba(0,0,0,.35);
}
.ticket::after { /* bord déchiré en dents de scie */
  content: ""; position: absolute; left: 0; right: 0; bottom: -9px; height: 9px;
  background:
    linear-gradient(135deg, var(--paper) 50%, transparent 50%) 0 0 / 14px 9px repeat-x,
    linear-gradient(225deg, var(--paper) 50%, transparent 50%) 0 0 / 14px 9px repeat-x;
}
.t-head { display: flex; justify-content: space-between; align-items: end; gap: 8px; padding-bottom: 10px; border-bottom: 1.5px dashed #1d1d1b; }
.t-logo { width: 84px; filter: grayscale(1) contrast(1.25) brightness(1.05); mix-blend-mode: multiply; }
.t-head span { font-size: 11px; text-align: right; line-height: 1.3; }
.t-rows { margin: 12px 0 0; }
.t-rows div { display: grid; grid-template-columns: auto 1fr auto; align-items: baseline; margin: 3px 0; }
.t-rows div::before { content: ""; grid-column: 2; grid-row: 1; margin: 0 6px; border-bottom: 1.5px dotted rgba(0,0,0,.35); }
.t-rows dt { grid-column: 1; grid-row: 1; }
.t-rows dd { grid-column: 3; grid-row: 1; margin: 0; font-weight: 600; text-align: right; }
.t-rows .ok { display: inline-flex; align-items: center; gap: 7px; color: #10662f; }
.t-rows .ok .beacon { --s: 9px; }
.t-barcode { height: 36px; margin-top: 14px;
  background: repeating-linear-gradient(90deg, #1d1d1b 0 2px, transparent 2px 4px, #1d1d1b 4px 5px, transparent 5px 8px, #1d1d1b 8px 11px, transparent 11px 12px, #1d1d1b 12px 13px, transparent 13px 17px); }
.t-foot { margin-top: 8px; font-size: 10.5px; opacity: .7; }

/* ---------- Sections ---------- */
.sec { padding: var(--sec-pad) 0; }
.sec.flush { padding-top: 0; }
.sec-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 26em); gap: 40px; align-items: end; margin-bottom: 52px; }
.sec-head p { color: var(--muted); }

/* Services : un tableau de bord de dispatch, pas des cartes */
.svc { border-top: 2px solid var(--ink); }
.svc-row {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr) auto; gap: 32px; align-items: baseline;
  padding: 26px 0; border-bottom: 1px solid var(--line);
}
.svc-row h3 { font-size: clamp(30px, 3.6vw, 46px); font-stretch: 68%; }
.svc-row p { color: var(--muted); max-width: 32em; }
.svc-row .cap { font-stretch: 80%; font-weight: 650; font-size: 15px; white-space: nowrap;
  padding: 4px 10px; border: 1.5px solid var(--line); border-radius: 3px; }
.svc-row:hover h3 { color: var(--accent-ink); }

/* Zone : poteau indicateur */
.zone-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 64px; align-items: start; }
.zone-text h2 { margin-bottom: 26px; }
.zone-text p + p { margin-top: 14px; }
.zone-text .muted { color: var(--muted); }

.post { position: relative; padding: 18px 0 64px; }
.pole { position: absolute; left: 50%; top: 0; bottom: 0; width: 12px; transform: translateX(-50%);
  background: linear-gradient(90deg, #6d6f70, #c3c5c3 45%, #6d6f70); }
.pole::after { content: ""; position: absolute; bottom: 0; left: 50%; width: 70px; height: 10px; transform: translateX(-50%); background: #55585a; }
.sign {
  position: relative; z-index: 1; width: calc(50% + 6px); height: 48px; margin-bottom: 10px;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  font-weight: 700; font-stretch: 80%; font-size: 18px; line-height: 1.05; transition: transform .35s;
}
.sign.r { margin-left: calc(50% - 6px); padding: 0 32px 0 16px; transform-origin: left center;
  clip-path: polygon(0 0, calc(100% - 22px) 0, 100% 50%, calc(100% - 22px) 100%, 0 100%); }
.sign.l { padding: 0 16px 0 32px; transform-origin: right center;
  clip-path: polygon(22px 0, 100% 0, 100% 100%, 22px 100%, 0 50%); }
.sign.blue { background: var(--sign-blue); color: #fff; }
.sign.white { background: #fbfbf8; color: #16191d; }
.sign.r:hover { transform: rotate(-2.5deg); }
.sign.l:hover { transform: rotate(2.5deg); }

/* Déroulement : une route, des losanges « route principale » */
.steps { position: relative; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); list-style: none; margin: 0; padding: 0; }
.steps::before { content: ""; position: absolute; left: 0; right: 0; top: 18px; height: 52px; background: var(--asphalt); }
.steps::after { content: ""; position: absolute; left: 0; right: 0; top: 43px; height: 3px;
  background: repeating-linear-gradient(90deg, #e9ebe8 0 28px, transparent 28px 52px); }
.step { position: relative; padding: 100px 28px 0 0; }
.diamond {
  position: absolute; z-index: 1; top: 22px; left: 6px; width: 44px; height: 44px;
  display: grid; place-items: center; font-weight: 900; font-stretch: 70%; font-size: 22px; color: #1a1a1a;
}
.diamond::before { content: ""; position: absolute; inset: 6px; transform: rotate(45deg);
  background: var(--amber); border: 3px solid #fff; outline: 1px solid #1a1a1a; }
.diamond span { position: relative; }
.step h3 { font-size: 30px; font-stretch: 70%; }
.step p { margin-top: 10px; color: var(--muted); }

/* ---------- Services : trois métiers avec photo, en quinconce ---------- */
.features { display: grid; gap: clamp(40px, 6vw, 80px); margin-bottom: clamp(56px, 7vw, 88px); }
.feature { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(24px, 4vw, 56px); align-items: center; }
.feature:nth-child(even) .feature-img { order: 2; }
.feature-img { margin: 0; position: relative; }
.feature-img img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; }
/* Coin de bande de chantier : rappelle le bandeau du hero, une seule touche par photo */
.feature-img::after {
  content: ""; position: absolute; left: 0; bottom: -10px; width: 34%; height: 10px;
  background: repeating-linear-gradient(-45deg, var(--amber) 0 10px, var(--asphalt) 10px 20px);
}
.feature-text h3 { font-size: clamp(34px, 4vw, 54px); font-stretch: 66%; margin-bottom: 14px; }
.feature-text p { color: var(--muted); max-width: 30em; }

/* ---------- Galerie bento ----------
   Grille de 3 colonnes à hauteur de rangée fixe : les photos (16:9) sont recadrées
   par object-fit, la grande vignette occupe 2×2. */
.bento { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-auto-rows: clamp(150px, 17vw, 240px); gap: 10px; }
.tile { position: relative; display: block; overflow: hidden; background: var(--bg-2); }
.tile img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s ease; }
.tile:hover img { transform: scale(1.03); }
.tile-xl { grid-column: span 2; grid-row: span 2; }
.tile-wide { grid-column: span 2; }
.tile-cap {
  position: absolute; left: 10px; bottom: 10px; max-width: calc(100% - 20px);
  padding: 5px 9px; background: var(--asphalt); color: #eef0ee;
  font-size: 14px; font-stretch: 85%; font-weight: 600; line-height: 1.2;
}

/* ---------- Visionneuse ---------- */
.lightbox { padding: 0; border: 0; max-width: none; max-height: none; width: 100vw; height: 100vh; height: 100dvh; background: transparent; }
.lightbox::backdrop { background: rgba(10, 12, 15, .92); }
.lightbox[open] { display: grid; place-items: center; }
.lightbox figure { margin: 0; display: grid; gap: 12px; justify-items: center; padding: 64px 16px; }
.lightbox img { max-width: min(1400px, 100%); max-height: calc(100dvh - 160px); width: auto; height: auto; display: block; }
.lightbox figcaption { color: #eef0ee; font-size: 16px; font-stretch: 85%; }
.lb-btn { position: fixed; display: grid; place-items: center; width: 48px; height: 48px; padding: 0; cursor: pointer;
  background: rgba(27,31,36,.85); color: #eef0ee; border: 1px solid #39404a; border-radius: 50%; }
.lb-btn svg { width: 22px; height: 22px; }
.lb-btn:hover { border-color: var(--amber); }
.lb-close { top: 16px; right: 16px; }
.lb-prev { left: 16px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 16px; top: 50%; transform: translateY(-50%); }
body.lb-open { overflow: hidden; }

/* ---------- Demande de prix : le bon de transport, en papier thermique ---------- */
.devis-grid { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(32px, 5vw, 72px); align-items: start; }
.devis-text h2 { margin-bottom: 22px; }
.devis-text p { color: var(--muted); max-width: 28em; }
.devis-text p + p { margin-top: 14px; }
.devis-text a { color: var(--ink); font-weight: 700; text-decoration-color: var(--amber); text-underline-offset: 4px; }
.bon {
  position: relative; background: var(--paper); color: #1d1d1b; font-family: var(--mono); font-size: 15px;
  padding: 26px clamp(18px, 3vw, 30px) 28px; box-shadow: 0 34px 50px -28px rgba(0,0,0,.55);
}
.bon::after { /* bord déchiré, comme le ticket du hero */
  content: ""; position: absolute; left: 0; right: 0; bottom: -9px; height: 9px;
  background:
    linear-gradient(135deg, var(--paper) 50%, transparent 50%) 0 0 / 14px 9px repeat-x,
    linear-gradient(225deg, var(--paper) 50%, transparent 50%) 0 0 / 14px 9px repeat-x;
}
.bon-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding-bottom: 12px; margin-bottom: 6px; border-bottom: 1.5px dashed #1d1d1b; }
.bon-head strong { font-family: var(--display); font-size: 30px; font-weight: 860; font-stretch: 66%; }
.bon-head span { font-size: 12px; }
.bon-row { display: grid; gap: 4px; padding: 10px 0; border: 0; margin: 0; border-bottom: 1.5px dotted rgba(0,0,0,.28); min-width: 0; }
.bon label, .bon legend { font-size: 12px; font-weight: 600; color: #55554f; padding: 0; }
.bon input, .bon select, .bon textarea {
  width: 100%; min-width: 0; font: 600 17px var(--mono); color: #1d1d1b; background: transparent;
  border: 0; border-radius: 0; padding: 4px 0; appearance: none; resize: vertical;
}
/* Chevron dessiné en CSS (le menu natif est masqué par appearance: none) */
.bon select { padding-right: 24px; cursor: pointer;
  background:
    linear-gradient(45deg, transparent 50%, #1d1d1b 50%) calc(100% - 10px) 55% / 6px 6px no-repeat,
    linear-gradient(-45deg, transparent 50%, #1d1d1b 50%) calc(100% - 4px) 55% / 6px 6px no-repeat; }
.bon input::placeholder, .bon textarea::placeholder { color: #9c9a90; font-weight: 400; }
.bon input:focus-visible, .bon select:focus-visible, .bon textarea:focus-visible { outline: 2px solid var(--amber); outline-offset: 2px; }
.bon input[aria-invalid="true"] { box-shadow: inset 0 -2px 0 var(--red); }
.bon-two { grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 16px; }
.bon-two > div { display: grid; gap: 4px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; padding-top: 4px; }
.chips label { position: relative; cursor: pointer; }
.chips input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.chips span { display: inline-block; padding: 7px 12px; border: 1.5px solid #1d1d1b; font: 600 14px var(--mono); color: #1d1d1b; }
.chips input:checked + span { background: #1d1d1b; color: var(--paper); }
.chips input:focus-visible + span { outline: 2px solid var(--amber); outline-offset: 2px; }
.bon-error { margin-top: 14px; color: #a3231c; font-size: 14px; font-weight: 600; }
.bon-send { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.btn-ink { background: transparent; color: #1d1d1b; border-color: #1d1d1b; }
.btn-ink:hover { background: #1d1d1b; color: var(--paper); }
/* Le SMS n'a de sens que sur téléphone */
@media (hover: hover) and (pointer: fine) { [data-send="sms"] { display: none; } }

/* Contact : toujours sombre, le numéro prend toute la largeur */
.contact { background: var(--asphalt); color: #eef0ee; padding: 104px 0 72px; }
.contact-head { display: flex; align-items: center; gap: 24px; }
.contact-head .badge { width: clamp(110px, 14vw, 170px); }
.contact h2 { font-size: clamp(28px, 3vw, 40px); font-stretch: 75%; font-weight: 700; color: #9aa1a6; }
/* La taille réelle est calculée en JS pour que le numéro remplisse
   exactement la largeur, quelle que soit la police chargée. */
.big-phone {
  display: block; width: max-content; max-width: 100%; margin: 14px 0 40px; text-decoration: none; color: var(--amber);
  font-family: var(--display); font-size: clamp(48px, 9vw, 160px); font-weight: 900; font-stretch: 62%;
  line-height: .9; letter-spacing: -.01em; white-space: nowrap; font-variant-numeric: tabular-nums;
}
/* Au survol, les chiffres s'allument l'un après l'autre comme des feux de détresse */
.big-phone span { display: inline-block; }
.big-phone:hover span { animation: hazard .5s steps(1) calc(var(--i) * 45ms) 2; }
@keyframes hazard { 0% { background: var(--amber); color: var(--asphalt); } 50% { background: transparent; color: var(--amber); } }
.contact-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px; padding-top: 28px; border-top: 1px solid #39404a; }
.contact-grid h3 { font-size: 22px; font-stretch: 75%; font-weight: 750; margin-bottom: 8px; }
.contact-grid p { color: #b3b9bd; font-size: 16px; }
.contact-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 40px; }
.contact .btn-geo { color: #eef0ee; }
.contact .btn-geo:hover { background: #eef0ee; color: var(--asphalt); }

/* =========================================================
   PAGES SECONDAIRES (mentions légales, confidentialité, 404)
   ========================================================= */
.back { margin-left: auto; font-stretch: 85%; font-weight: 600; font-size: 16px; text-decoration: none; padding: 10px 0; }
.back:hover { text-decoration: underline; text-decoration-color: var(--amber); text-underline-offset: 4px; }
.legal { padding: 64px 0 104px; }
.legal .wrap { max-width: 46rem; }   /* ~70 caractères par ligne : confortable à lire */
.legal h1 { font-size: clamp(44px, 7vw, 72px); font-stretch: 66%; margin-bottom: 12px; }
.legal .updated { color: var(--muted); font-size: 15px; margin-bottom: 40px; }
.legal h2 { font-size: 30px; font-stretch: 70%; margin: 44px 0 12px; scroll-margin-top: calc(var(--header) + 20px); }
.legal p, .legal li { line-height: 1.6; }
.legal p + p { margin-top: 12px; }
.legal ul { margin: 10px 0 0; padding-left: 1.2em; }
.legal li + li { margin-top: 6px; }
.legal dl { display: grid; grid-template-columns: minmax(0, 11em) minmax(0, 1fr); gap: 8px 20px; margin: 0; }
.legal dt { color: var(--muted); }
.legal dd { margin: 0; }
.legal a { text-decoration-color: var(--amber); text-underline-offset: 3px; }
/* Valeurs à compléter : impossibles à rater avant la mise en ligne */
.todo { background: #ffe58a; color: #3a2a00; padding: 0 .3em; border-radius: 2px; font-weight: 600; }
.notfound { min-height: calc(100svh - var(--header) - 60px); display: grid; align-content: center; padding: 48px 0; }
.notfound h1 { font-size: clamp(52px, 10vw, 120px); font-stretch: 62%; }
.notfound p { margin: 18px 0 30px; max-width: 34em; color: var(--muted); }
.notfound .cta { margin-top: 0; }
.mbar.mbar--single { grid-template-columns: 1fr; }
/* « Retour à l'accueil » prend la place libre ; le bouton thème se colle à lui */
@media (min-width: 761px) { .back ~ .theme { margin-left: 0; } }
@media (max-width: 760px) {
  .legal dl { grid-template-columns: 1fr; gap: 2px; }
  .legal dd { margin-bottom: 10px; }
  .back { display: none; }
}

.foot { background: var(--asphalt); color: #81888e; border-top: 1px solid #2c323a; padding: 22px 0; font-size: 14px; }
.foot .wrap { display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; }
.foot nav { display: flex; gap: 20px; }

/* Barre d'appel mobile + toast */
/* La barre glisse depuis le bas quand les boutons du hero sortent de l'écran :
   il y a toujours un bouton d'appel visible, jamais deux. */
.mbar {
  position: fixed; z-index: 50; left: 0; right: 0; bottom: 0; display: none; grid-template-columns: 1.6fr 1fr;
  padding-bottom: env(safe-area-inset-bottom); background: var(--asphalt);
  transform: translateY(100%); transition: transform .25s ease-out;
}
.mbar.show { transform: none; }
.mbar a, .mbar button { display: flex; align-items: center; justify-content: center; gap: 10px; height: 62px; border: 0; text-decoration: none;
  font: 800 18px var(--font); font-stretch: 75%; cursor: pointer; }
.mbar a { background: var(--amber); color: #1a1a1a; font-variant-numeric: tabular-nums; }
.mbar button, .mbar .mbar-alt { background: var(--asphalt); color: #eef0ee; border-left: 1px solid #39404a; }
.mbar svg { width: 18px; height: 18px; flex: none; }

/* Retour tactile : pas de flash bleu natif, un léger enfoncement à la place */
a, button, label { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
.btn:active, .mbar a:active, .mbar button:active, .icon-btn:active { transform: translateY(1px); filter: brightness(.94); }
.toast { position: fixed; z-index: 60; left: 50%; bottom: 84px; transform: translateX(-50%); width: min(460px, 92vw);
  background: #101317; color: #eef0ee; border-left: 4px solid var(--amber); padding: 14px 16px; font-size: 15px;
  box-shadow: 0 18px 40px -12px rgba(0,0,0,.6); }
.toast a { color: var(--amber); }

/* ---------- Responsive ---------- */
@media (max-width: 1000px) {
  .hero-in { grid-template-columns: 1fr; gap: 0; }
  /* En une colonne, c'est le bloc texte qui remplit l'écran ; le ticket vient au défilement */
  .hero-copy { padding: 32px 0 40px; min-height: calc(100vh - var(--header)); min-height: calc(100svh - var(--header)); }
  .hero h1 { font-size: clamp(42px, min(15vw, 9.5vh), 104px); }
  .rig-zone { justify-self: center; padding-bottom: 80px; }
  .rig { --cable: 40px; }
  .pulley { margin-top: 0; }
  .zone-grid, .devis-grid { grid-template-columns: 1fr; gap: 40px; }
  .feature { grid-template-columns: 1fr; gap: 22px; }
  .feature:nth-child(even) .feature-img { order: 0; }
  .contact-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
/* Le menu complet ne tient plus dans l'en-tête : place au hamburger */
@media (max-width: 960px) {
  .nav { display: none; }
  .theme { margin-left: auto; }
  .burger { display: inline-grid; }
  .top-in { gap: 10px; }
  .top-call { order: 1; margin-left: 6px; }
  .burger { order: 2; }
}
@media (min-width: 961px) { .mnav { display: none; } }

@media (max-width: 760px) {
  :root { --header: 60px; --sec-pad: 80px; }
  body { padding-bottom: calc(62px + env(safe-area-inset-bottom)); font-size: 17px; }
  .hero-copy { padding: 24px 0 28px; }
  .logo-sub { display: none; }
  .logo .badge { width: 64px; }
  .top-call { display: none; }
  /* Grain de fond coupé sur mobile : couche plein écran inutile pour la batterie */
  body::before { display: none; }
  /* Boutons du hero empilés pleine largeur, faciles à toucher */
  .cta { flex-direction: column; }
  .cta .btn { justify-content: center; padding: 20px 18px; }
  .btn-call { font-size: 21px; }
  .sec-head { grid-template-columns: 1fr; gap: 16px; }
  .svc-row { grid-template-columns: 1fr; gap: 10px; }
  .svc-row .cap { justify-self: start; }
  .steps { grid-template-columns: 1fr; }
  .steps::before { right: auto; top: 0; bottom: 0; width: 52px; height: auto; }
  .steps::after { right: auto; left: 25px; top: 0; bottom: 0; width: 3px; height: auto;
    background: repeating-linear-gradient(to bottom, #e9ebe8 0 22px, transparent 22px 40px); }
  .step { padding: 8px 0 36px 76px; }
  .diamond { top: 4px; left: 4px; }
  .sign { font-size: 15px; height: 44px; }
  .contact-grid { grid-template-columns: 1fr; gap: 22px; }
  /* Galerie : 2 colonnes, la grande photo et les panoramiques sur toute la largeur */
  .bento { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: auto; gap: 8px; }
  .tile { aspect-ratio: 4 / 3; }
  .tile-xl, .tile-wide, .tile-wide-m { grid-column: 1 / -1; grid-row: auto; aspect-ratio: 16 / 9; }
  .tile-cap { font-size: 13px; left: 8px; bottom: 8px; }
  .bon-two { grid-template-columns: 1fr; gap: 10px; }
  .bon-send .btn { flex: 1 1 100%; justify-content: center; }
  .lb-prev, .lb-next { top: auto; bottom: 16px; transform: none; }
  .mbar { display: grid; }
  .toast { bottom: calc(76px + env(safe-area-inset-bottom)); }
}
/* Très petits téléphones (≤ 600 px de haut visibles) : on garde titre, heure et boutons
   à l'écran, le texte d'appoint passe à la trappe. */
@media (max-width: 760px) and (max-height: 600px) {
  .hero .lede, .hero .fine { display: none; }
  .hero h1 { margin-top: 14px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}
