/* Hine Design : feuille de style.
   Bleu très profond + bleu roi, clair/foncé en alternance, or réservé au curseur et à la ligne d'impression.
   Pour changer l'ambiance, modifie les variables juste en dessous. */

@font-face { font-family: "Aileron"; font-weight: 400; font-style: normal; font-display: swap;
  src: local("Aileron Regular"), local("Aileron-Regular"), url("fonts/Aileron-Regular.otf") format("opentype"); }
@font-face { font-family: "Aileron"; font-weight: 600; font-style: normal; font-display: swap;
  src: local("Aileron SemiBold"), local("Aileron-SemiBold"), url("fonts/Aileron-SemiBold.otf") format("opentype"); }
@font-face { font-family: "Aileron"; font-weight: 600; font-style: normal; font-display: swap;
  src: local("Aileron Bold"), local("Aileron-Bold"), url("fonts/Aileron-Bold.otf") format("opentype"); }
@font-face { font-family: "Aileron"; font-weight: 800; font-style: normal; font-display: swap;
  src: local("Aileron Heavy"), local("Aileron-Heavy"), url("fonts/Aileron-Heavy.otf") format("opentype"); }

:root {
  --navy: #0a2239;          /* Prussian Blue : blocs d'accent, pied de page */
  --navy-2: #07192b;
  --steel: #628395;         /* Air Force Blue */
  --brandy: #78290f;        /* Brandy */
  --accent: #ff7d00;        /* Vivid Tangerine : boutons, pointeur, ligne d'impression */
  --papaya: #ffecd1;        /* Papaya Whip */
  --ice: #ffecd1;
  --ice-2: #fff6e8;
  --ink: #0a2239;
  --ink-soft: #3f5668;
  --white: #fff;
  --line-dark: rgba(255, 236, 209, 0.22);
  --line-light: rgba(10, 34, 57, 0.16);
  --display: "Aileron", Bahnschrift, "DIN Alternate", system-ui, sans-serif;
  --body: "Aileron", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --gutter: clamp(18px, 4vw, 56px);
  --head-h: 76px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--body);
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--ice-2);
  overflow-x: hidden;
}
img, svg, canvas { max-width: 100%; }
a { color: inherit; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

h1, h2, h3 { font-family: var(--display); line-height: 1.05; margin: 0; letter-spacing: 0.01em; }
h2 { font-size: clamp(2rem, 4.6vw, 3.6rem); font-weight: 400; }
h3 { font-size: 1.15rem; font-weight: 600; }
p { margin: 0 0 1em; }

.wrap { width: 100%; max-width: 1360px; margin-inline: auto; padding-inline: var(--gutter); }

.skip-link {
  position: fixed; left: 12px; top: -60px; z-index: 200;
  background: var(--accent); color: var(--navy); padding: 10px 16px; font-weight: 600; text-decoration: none;
}
.skip-link:focus { top: 12px; }

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

/* ---------- Boutons ---------- */
.btn {
  border-radius: 10px;
  display: inline-block; border: 0; cursor: pointer; text-decoration: none;
  font: 600 0.9rem/1 var(--display); letter-spacing: 0.02em;
  color: var(--navy); background: var(--accent); padding: 17px 26px;
  transition: background 0.25s var(--ease), transform 0.25s var(--ease), color 0.25s;
}
.btn:hover { background: var(--navy); color: #fff; transform: translateY(-2px); }
.btn-small { padding: 12px 18px; font-size: 0.8rem; }

/* ---------- En-tête ---------- */
.site-header { position: fixed; inset: 0 0 auto 0; z-index: 100; color: #fff; transition: background 0.35s, backdrop-filter 0.35s; }
.site-header.is-stuck { background: rgba(10, 34, 57, 0.88); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }

.topbar { border-bottom: 1px solid var(--line-dark); font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; }
.topbar-in { display: flex; justify-content: space-between; gap: 16px; padding-block: 8px; padding-left: calc(var(--gutter) + 270px); }
.topbar a { text-decoration: none; opacity: 0.9; }
.topbar a:hover { opacity: 1; text-decoration: underline; }

.navbar { position: relative; }
.navbar-in { display: flex; justify-content: flex-end; align-items: center; min-height: 52px; padding-left: calc(var(--gutter) + 270px); }

.brand-tab {
  position: absolute; left: 0; top: -34px; z-index: 2;
  display: flex; align-items: center; gap: 12px;
  height: 128px; padding: 0 32px 0 var(--gutter);
  background: var(--navy); color: #fff; text-decoration: none;
  font: 600 1.25rem/1 var(--display); letter-spacing: 0.02em;
  border-radius: 0 0 24px 0;
}
.brand-tab .logo-mark { width: 50px; height: 58px; color: #fff; flex: none; transition: transform 0.6s var(--ease); }
.brand-tab:hover .logo-mark { transform: rotate(360deg); }
.logo-mark { fill: currentColor; display: block; }

.menu { display: flex; align-items: center; gap: clamp(14px, 2.4vw, 34px); }
.menu a:not(.btn) {
  position: relative; text-decoration: none; letter-spacing: 0.02em;
  font: 600 0.82rem/1 var(--display); padding: 8px 0;
}
.menu a:not(.btn)::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--accent);
  transform: scaleX(0); transform-origin: left; transition: transform 0.35s var(--ease);
}
.menu a:not(.btn):hover::after { transform: scaleX(1); }

.menu-toggle {
  border-radius: 10px;
  display: none; background: transparent; color: #fff; border: 1px solid var(--line-dark);
  font: 600 0.8rem/1 var(--display); letter-spacing: 0.03em; padding: 12px 16px; cursor: pointer;
}

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden; color: #fff;
  min-height: clamp(640px, 100svh, 940px);
  background:
    radial-gradient(120% 90% at 78% 40%, var(--steel) 0%, #2f5069 38%, var(--navy) 100%);
  display: flex;
}
.hero-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.hero::after { /* voile à gauche pour garder le titre lisible */
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(90deg, rgba(10, 34, 57, 0.72) 0%, rgba(10, 34, 57, 0.15) 55%, transparent 80%);
}
.hero.no-webgl .hero-canvas { display: none; }

.hero-lines { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.hl { position: absolute; background: rgba(255, 236, 209, 0.3); transition: transform 1.4s var(--ease); }
.hl-h { left: 0; right: 0; height: 1px; transform: scaleX(0); transform-origin: left; }
.hl-v { top: 0; bottom: 0; width: 1px; transform: scaleY(0); transform-origin: top; }
.hl-top { top: calc(var(--head-h) + 40px); }
.hl-bottom { bottom: 64px; transition-delay: 0.25s; }
.hl-left { left: var(--gutter); transition-delay: 0.1s; }
.hl-right { right: var(--gutter); transition-delay: 0.35s; }
.hl-card { right: calc(var(--gutter) + min(34vw, 420px)); transition-delay: 0.5s; opacity: 0.6; }
.hero-in .hl-h { transform: scaleX(1); }
.hero-in .hl-v { transform: scaleY(1); }

.hero-content { position: relative; z-index: 2; display: flex; flex-direction: column; justify-content: space-between; padding-top: calc(var(--head-h) + 60px); padding-bottom: 64px; }
.hero-tag { max-width: 360px; letter-spacing: 0.03em; font-size: 0.82rem; line-height: 1.6; opacity: 0; transform: translateY(10px); transition: opacity 0.8s 0.5s, transform 0.8s 0.5s var(--ease); }
.hero-in .hero-tag { opacity: 0.92; transform: none; }

.hero-bottom { display: flex; align-items: flex-end; justify-content: space-between; gap: 32px; }
.hero-title { text-transform: uppercase; min-width: 0; font-size: clamp(3rem, 6vw, 6.6rem); font-weight: 400; line-height: 0.92; letter-spacing: 0; }
.hero-title .line { display: block; white-space: nowrap; overflow: hidden; padding-bottom: 0.06em; }
.hero-title .line-in { display: block; transform: translateY(105%); transition: transform 1.1s var(--ease); }
.hero-in .hero-title .line:nth-child(1) .line-in { transform: none; transition-delay: 0.2s; }
.hero-in .hero-title .line:nth-child(2) .line-in { transform: none; transition-delay: 0.35s; }

.hero-card {
  border-radius: 18px; overflow: hidden;
  flex: none; width: min(34vw, 420px); background: var(--navy); color: #fff;
  padding: 28px 28px 0; display: flex; flex-direction: column; gap: 0;
  opacity: 0; transform: translateY(30px); transition: opacity 0.9s 0.7s, transform 0.9s 0.7s var(--ease);
}
.hero-in .hero-card { opacity: 1; transform: none; }
.hero-card-num { font: 400 clamp(3rem, 5.6vw, 5rem)/1 var(--display); margin: 0 0 10px; font-variant-numeric: tabular-nums; }
.hero-card-text { margin: 0 0 26px; opacity: 0.85; max-width: 26ch; }
.hero-card-btn {
  display: flex; justify-content: space-between; align-items: stretch;
  margin: 0 -28px; border-top: 1px solid var(--line-dark); text-decoration: none; color: #fff;
  font: 600 0.85rem/1 var(--display); letter-spacing: 0.03em;
}
.hero-card-btn > span:first-child { padding: 22px 28px; }
.hero-card-arrow { display: grid; place-items: center; width: 64px; color: var(--navy); background: var(--accent); transition: background 0.3s, width 0.4s var(--ease); }
.hero-card-btn:hover .hero-card-arrow { width: 84px; background: var(--papaya); color: var(--navy); }
.icon-arrow { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; }

/* ---------- Bandeau défilant ---------- */
.marquee { background: var(--navy); color: #fff; overflow: hidden; border-block: 1px solid var(--line-dark); }
.marquee-track { display: flex; width: max-content; animation: defile 38s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-set { display: flex; align-items: center; gap: 28px; padding: 20px 14px; white-space: nowrap; font: 600 1.1rem/1 var(--display); letter-spacing: 0.03em; }
.marquee-set .logo-mark { width: 16px; height: 18px; color: var(--accent); flex: none; }
@keyframes defile { to { transform: translateX(-50%); } }

/* ---------- Sections ---------- */
.section { padding-block: clamp(64px, 9vw, 130px); background: var(--ice-2); }
.section.light-2 { background: var(--ice); }
.section.on-dark, .section.contact { background: var(--navy); color: var(--papaya); }
.section-head { max-width: 760px; margin-bottom: clamp(32px, 5vw, 64px); }
.section-head p { margin: 18px 0 0; color: var(--ink-soft); font-size: 1.12rem; }
.on-dark .section-head p { color: rgba(255, 255, 255, 0.78); }

/* ---------- Estimateur ---------- */
.est-section { background: var(--ice); }
.estimator { border-radius: 22px; overflow: hidden; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); background: var(--navy); color: #fff; }
.est-left { padding: clamp(18px, 3vw, 36px); display: grid; gap: 18px; align-content: start; border-right: 1px solid var(--line-dark); }
.est-right { padding: clamp(20px, 3vw, 40px); display: grid; gap: 22px; align-content: start; }

.est-viewer {
  border-radius: 14px;
  position: relative; aspect-ratio: 4 / 3; overflow: hidden;
  background: radial-gradient(90% 90% at 50% 40%, var(--steel) 0%, #2f5069 55%, var(--navy) 100%);
  outline: 1px solid var(--line-dark);
}
.est-viewer canvas { display: block; width: 100%; height: 100%; touch-action: pan-y; cursor: grab; }
.est-viewer.is-drag canvas { cursor: grabbing; }
.est-viewer.no-webgl::after { content: "Aperçu 3D indisponible sur cet appareil : l'estimation reste calculée."; position: absolute; inset: 0; display: grid; place-items: center; padding: 24px; text-align: center; opacity: 0.85; }
.est-badge { border-radius: 6px; position: absolute; left: 14px; top: 14px; background: var(--accent); color: var(--navy); font: 600 0.72rem/1 var(--display); text-transform: uppercase; letter-spacing: 0.03em; padding: 7px 10px; }
.est-file { position: absolute; left: 14px; bottom: 12px; right: 14px; font-size: 0.85rem; opacity: 0.85; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.est-import { display: grid; gap: 10px; justify-items: start; }
.est-import-btn { cursor: pointer; }
.est-import-btn:hover { background: var(--papaya); color: var(--navy); }
#fichier3d:focus-visible + .est-import-btn { outline: 3px solid var(--accent); outline-offset: 3px; }
.est-import.is-over .est-import-btn { background: var(--papaya); color: var(--navy); }
.est-hint { margin: 0; font-size: 0.9rem; opacity: 0.75; }

.est-notice { border-radius: 0 10px 10px 0; margin: 0; padding: 12px 14px; background: rgba(255, 125, 0, 0.16); border-left: 3px solid var(--accent); font-size: 0.95rem; }

.est-measures { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 0; padding-bottom: 18px; border-bottom: 1px solid var(--line-dark); }
.est-measures div { min-width: 0; }
.est-measures dt { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.02em; opacity: 0.7; }
.est-measures dd { margin: 4px 0 0; font: 600 1.05rem/1.2 var(--display); overflow-wrap: anywhere; }

.est-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.est-right .field label { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.02em; opacity: 0.75; font-weight: 600; }
.est-right .field select, .est-right .est-table input {
  background: rgba(255, 255, 255, 0.08); color: #fff; border: 1px solid var(--line-dark);
}
.est-right option { color: var(--ink); }

.est-table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.est-table caption { text-align: left; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.02em; opacity: 0.75; padding-bottom: 8px; }
.est-table th, .est-table td { text-align: left; vertical-align: top; padding: 12px 8px; border-top: 1px solid var(--line-dark); }
.est-table thead th { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.02em; opacity: 0.7; border-top: 0; font-weight: 600; }
.est-table tbody th { font: 600 1.2rem/1.2 var(--display); }
.est-table td strong { display: block; font: 600 1.2rem/1.2 var(--display); }
.est-range { display: block; font-size: 0.8rem; opacity: 0.7; }
.est-table input { border-radius: 8px; width: 100%; max-width: 150px; font: inherit; padding: 8px 10px; }
.est-fine { margin: 10px 0 0; font-size: 0.85rem; opacity: 0.7; }
.estimator .btn { justify-self: start; }
.estimator .btn:hover { background: var(--papaya); color: var(--navy); }

/* ---------- Champs de formulaire ---------- */
.form { display: grid; gap: 18px; }
.form-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.field { display: grid; gap: 6px; }
.field label { font-weight: 600; }
.field input, .field select, .field textarea {
  width: 100%; font: inherit; color: inherit; padding: 13px 14px; border-radius: 10px;
  background: rgba(255, 255, 255, 0.06); border: 1px solid var(--line-dark);
}
.field textarea { min-height: 150px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 3px solid var(--accent); outline-offset: 0; }
.form-note { margin: 0; font-size: 0.9rem; opacity: 0.75; }

/* ---------- Services ---------- */
.services-layout { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.4fr); gap: clamp(28px, 6vw, 90px); align-items: start; }
.services-head { position: sticky; top: 110px; }
.services-head h2 { font-size: clamp(1.8rem, 3.2vw, 2.8rem); }
.services-head p { margin-top: 18px; color: var(--ink-soft); }
.services-list { border-top: 1px solid var(--line-light); }
.service {
  border-radius: 14px;
  position: relative; overflow: hidden; display: grid; grid-template-columns: minmax(0, 1fr) 40px; gap: 6px 24px;
  padding: 28px 18px; border-bottom: 1px solid var(--line-light); isolation: isolate; transition: color 0.4s;
}
.service::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--navy); transform: scaleX(0); transform-origin: left; transition: transform 0.6s var(--ease); }
.service:hover::before { transform: scaleX(1); }
.service:hover { color: #fff; }
.service h3 { font-size: 1.3rem; }
.service p { margin: 0; color: var(--ink-soft); max-width: 60ch; transition: color 0.4s; }
.service:hover p { color: rgba(255, 255, 255, 0.82); }
.service .logo-mark { grid-column: 2; grid-row: 1 / span 2; width: 26px; height: 30px; color: var(--brandy); align-self: center; transition: transform 0.7s var(--ease), color 0.4s; }
.service:hover .logo-mark { transform: rotate(180deg) scale(1.15); color: var(--accent); }

/* ---------- Réalisations ---------- */
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 14px; }
.tile { border-radius: 18px; background: var(--navy); color: #fff; padding: 30px 26px 34px; min-height: 260px; display: flex; flex-direction: column; justify-content: space-between; transition: background 0.4s, transform 0.4s var(--ease); }
.tile:hover { background: var(--brandy); transform: translateY(-6px); }
.tile-big { margin: 0 0 24px; font: 400 clamp(1.6rem, 2.7vw, 2.5rem)/1.05 var(--display); overflow-wrap: normal; hyphens: manual; }
.tile-text { margin: 0; opacity: 0.88; }

/* ---------- Pourquoi ---------- */
.claims { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); border-top: 1px solid var(--line-dark); }
.claim { padding: 30px 26px 34px 0; }
.claim + .claim { padding-left: 26px; border-left: 1px solid var(--line-dark); }
.claim h3 { font-size: 1.45rem; margin-bottom: 14px; }
.claim p { margin: 0; color: rgba(255, 255, 255, 0.78); }

/* ---------- Technologies ---------- */
.tech-table { width: 100%; border-radius: 14px; border-collapse: collapse; background: #fff; }
.tech-table caption { text-align: left; padding-bottom: 10px; color: var(--ink-soft); font-size: 0.9rem; }
.tech-table th, .tech-table td { text-align: left; vertical-align: top; padding: 20px 22px; border: 1px solid var(--line-light); }
.tech-table thead th { background: var(--navy); color: #fff; font: 600 0.9rem/1.2 var(--display); letter-spacing: 0.02em; }
.tech-table tbody th { width: 18%; font: 600 0.9rem/1.3 var(--display); letter-spacing: 0.02em; }
.tech-notes { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 28px; margin-top: 40px; }
.tech-notes h3 { margin-bottom: 8px; color: var(--brandy); }
.tech-notes p { margin: 0; color: var(--ink-soft); }

/* ---------- Pour qui ---------- */
.who { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 0 40px; border-top: 1px solid var(--line-light); }
.who li { padding: 20px 0 20px 34px; border-bottom: 1px solid var(--line-light); position: relative; }
.who li::before { content: ""; position: absolute; left: 0; top: 27px; width: 16px; height: 2px; background: var(--accent); transition: width 0.4s var(--ease); }
.who li:hover::before { width: 24px; }

/* ---------- Étapes ---------- */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 14px; counter-reset: etape; }
.steps li { border-radius: 16px; counter-increment: etape; position: relative; padding: 70px 24px 28px; background: #fff; border-top: 3px solid var(--accent); }
.steps li::before { content: "0" counter(etape); position: absolute; left: 24px; top: 18px; font: 600 2.6rem/1 var(--display); color: var(--brandy); }
.steps h3 { margin-bottom: 8px; }
.steps p { margin: 0; color: var(--ink-soft); }

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.2fr); gap: clamp(28px, 6vw, 90px); }
.contact-lede { margin-top: 20px; color: rgba(255, 255, 255, 0.8); max-width: 44ch; }
.contact-lines a { font: 600 1.3rem/1.2 var(--display); text-decoration-color: var(--accent); text-underline-offset: 6px; }

.contact .btn:hover { background: var(--papaya); color: var(--navy); }

/* ---------- Pied de page ---------- */
.site-footer { background: #06162a; color: rgba(255, 255, 255, 0.75); padding-block: 32px; font-size: 0.92rem; border-top: 1px solid var(--line-dark); }
.site-footer .wrap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.site-footer p { margin: 0; }

/* ---------- Pages simples (mentions légales) ---------- */
.legal { padding-top: calc(var(--head-h) + 70px); padding-bottom: 80px; background: var(--ice-2); }
.legal .wrap { max-width: 860px; }
.legal h1 { font-size: clamp(2rem, 5vw, 3.4rem); margin-bottom: 28px; }
.legal h2 { font-size: 1.4rem; margin: 36px 0 10px; }
.todo { background: var(--accent); color: var(--navy); padding: 0 4px; }

/* ---------- Apparition au défilement ---------- */
.js [data-reveal], .js [data-wipe] { opacity: 0; transform: translateY(26px); transition: opacity 0.8s var(--ease), transform 0.9s var(--ease); transition-delay: calc(var(--i, 0) * 90ms); }
.js [data-reveal].is-in, .js [data-wipe].is-in,
.no-wait [data-reveal], .no-wait [data-wipe] { opacity: 1; transform: none; }
.js .tech-table[data-wipe] { transform: none; }
.no-wait .hero-tag, .no-wait .hero-card { opacity: 1; transform: none; }
.no-wait .hero-title .line-in { transform: none; }
.no-wait .hl-h { transform: scaleX(1); }
.no-wait .hl-v { transform: scaleY(1); }
html:not(.js) .hero-tag, html:not(.js) .hero-card { opacity: 1; transform: none; }
html:not(.js) .hero-title .line-in { transform: none; }
html:not(.js) .hl-h { transform: scaleX(1); }
html:not(.js) .hl-v { transform: scaleY(1); }

/* ---------- Curseur logo ---------- */
.cursor-logo {
  position: fixed; left: 0; top: 0; z-index: 9999; width: 34px; height: 39px; margin: -19px 0 0 -17px;
  pointer-events: none; opacity: 0; color: var(--accent);
  filter: drop-shadow(0 0 2px var(--navy)) drop-shadow(0 0 6px rgba(10, 34, 57, 0.9));
  transition: opacity 0.25s, color 0.2s; will-change: transform;
}
.cursor-logo.is-visible { opacity: 1; }
.cursor-logo.is-hot { color: var(--papaya); }
.cursor-logo .logo-mark { width: 100%; height: 100%; }
.has-logo-cursor, .has-logo-cursor a, .has-logo-cursor button, .has-logo-cursor label, .has-logo-cursor select, .has-logo-cursor canvas { cursor: none; }
.has-logo-cursor input, .has-logo-cursor textarea { cursor: text; }

/* ---------- Mobile ---------- */
@media (max-width: 980px) {
  .estimator, .services-layout, .contact-grid { grid-template-columns: minmax(0, 1fr); }
  .est-left { border-right: 0; border-bottom: 1px solid var(--line-dark); }
  .services-head { position: static; }
  .hero-bottom { flex-direction: column; align-items: stretch; }
  .hero-card { width: 100%; max-width: 440px; }
  .hl-card { display: none; }
  .claim + .claim { padding-left: 0; border-left: 0; border-top: 1px solid var(--line-dark); }
  .claim { padding-right: 0; }
}
@media (max-width: 820px) {
  .hero::after { background: linear-gradient(180deg, rgba(10,34,57,.55) 0%, rgba(10,34,57,.1) 40%, rgba(10,34,57,.85) 100%); }
  .topbar span { display: none; }
  .topbar-in { justify-content: flex-end; padding-left: var(--gutter); }
  .navbar-in { justify-content: flex-end; padding-left: calc(var(--gutter) + 190px); }
  .brand-tab { height: 96px; top: -30px; padding-right: 22px; font-size: 1rem; }
  .brand-tab .logo-mark { width: 38px; height: 44px; }
  .menu-toggle { display: inline-block; }
  .menu {
    display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; align-items: stretch; gap: 0;
    background: var(--navy); padding: 12px var(--gutter) 22px; border-top: 1px solid var(--line-dark);
  }
  .menu.is-open { display: flex; }
  .menu a:not(.btn) { padding-block: 14px; }
  .menu .btn { text-align: center; margin-top: 10px; }
  .hero-title { font-size: clamp(2.2rem, 11vw, 4.4rem); }
  .form-row, .est-options { grid-template-columns: minmax(0, 1fr); }
  .est-measures { grid-template-columns: minmax(0, 1fr); }
  .tech-table thead { display: none; }
  .tech-table tr, .tech-table td, .tech-table th { display: block; width: 100% !important; }
  .tech-table td::before { content: attr(data-label); display: block; font: 600 0.72rem/1 var(--display); letter-spacing: 0.02em; color: var(--brandy); margin-bottom: 6px; }
}

/* ---------- Mouvement réduit ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; transition-delay: 0s !important; }
  .marquee-track { animation: none; }
  .js [data-reveal], .js [data-wipe], .hero-tag, .hero-card, .hero-title .line-in { opacity: 1; transform: none; }
  .hl-h { transform: scaleX(1); }
  .hl-v { transform: scaleY(1); }
}
strong, b { font-weight: 600; }

/* ---------- Page matières ---------- */
.page-hero { background: radial-gradient(120% 120% at 80% 0%, var(--steel) 0%, #2f5069 35%, var(--navy) 100%); color: var(--papaya); padding: calc(var(--head-h) + 110px) 0 clamp(48px, 7vw, 90px); }
.page-kicker { margin: 0 0 14px; letter-spacing: 0.08em; font-size: 0.85rem; opacity: 0.85; text-transform: uppercase; }
.page-hero h1 { font-size: clamp(2.4rem, 6vw, 5rem); font-weight: 400; text-transform: none; max-width: 16ch; }
.page-lede { margin: 22px 0 0; max-width: 60ch; font-size: 1.15rem; opacity: 0.9; }
.mat-note { margin: 22px 0 0; max-width: 78ch; color: var(--ink-soft); }
.mat-note a { text-underline-offset: 4px; }
.mat-list-wrap { display: grid; gap: 22px; }
.mat { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(22px, 4vw, 56px); padding: clamp(22px, 3.2vw, 44px); background: #fff; border: 1px solid var(--line-light); border-radius: 22px; scroll-margin-top: 110px; }
.mat-head h2 { font-size: clamp(1.8rem, 3.4vw, 2.7rem); }
.mat-acc { margin: 10px 0 22px; color: var(--ink-soft); }
.mat-chips { margin: 0 0 24px; display: grid; gap: 0; border-top: 1px solid var(--line-light); }
.mat-chips div { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; border-bottom: 1px solid var(--line-light); }
.mat-chips dt { color: var(--ink-soft); font-size: 0.92rem; }
.mat-chips dd { margin: 0; font-weight: 600; text-align: right; }
.mat-body h3 { margin: 22px 0 8px; font-size: 0.95rem; color: var(--brandy); }
.mat-body h3:first-child { margin-top: 0; }
.mat-body p { margin: 0; }
.mat-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 28px; }
.mat-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.mat-list li { position: relative; padding-left: 22px; }
.mat-list li::before { content: ""; position: absolute; left: 0; top: 0.7em; width: 12px; height: 2px; background: var(--accent); }
.mat-list.is-minus li::before { background: var(--steel); }
.js .mat[data-wipe] { transform: translateY(26px); }
.mat-compare .tech-table td, .mat-compare .tech-table th { padding: 14px 16px; }
.page-hero ~ .section.light .who { margin-top: 8px; }
@media (max-width: 980px) { .mat { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 620px) { .mat-cols { grid-template-columns: minmax(0, 1fr); } }
.mat-cols { margin-top: 22px; }
.mat-compare .tech-table th, .mat-compare .tech-table td { vertical-align: middle; }

/* ---------- Navigation plus facile à cliquer ---------- */
.menu a:not(.btn) { padding: 16px 6px; }
.menu { gap: clamp(8px, 1.6vw, 22px); }
.navbar-in { min-height: 56px; }

/* Onglets des matières : barre fixe sous l'en-tête, grandes zones de clic */
.mat-tabs { position: sticky; top: 92px; z-index: 50; background: rgba(255, 246, 232, 0.94); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--line-light); }
.mat-tabs-in { display: flex; gap: 10px; padding-block: 12px; overflow-x: auto; scrollbar-width: none; }
.mat-tabs-in::-webkit-scrollbar { display: none; }
.mat-tabs a { flex: none; display: inline-flex; align-items: center; min-height: 46px; padding: 0 22px; border-radius: 999px; border: 1px solid var(--line-light); background: #fff; color: var(--navy); text-decoration: none; font-weight: 600; transition: background 0.25s, color 0.25s, border-color 0.25s, transform 0.25s var(--ease); }
.mat-tabs a:hover { background: var(--navy); color: #fff; border-color: var(--navy); transform: translateY(-2px); }
.mat-tabs a.is-active { background: var(--accent); border-color: var(--accent); }
.mat { scroll-margin-top: 170px; }
#resine { scroll-margin-top: 170px; }
@media (max-width: 820px) { .mat-tabs { top: 84px; } .mat-tabs a { min-height: 44px; padding: 0 18px; } }
/* La languette du logo dépasse sous l'en-tête : les onglets commencent après elle */
.mat-tabs { top: 93px; }
.mat-tabs-in { padding-left: calc(var(--gutter) + 270px); }
.mat, #resine { scroll-margin-top: 190px; }
@media (max-width: 820px) {
  .mat-tabs { top: 104px; }
  .mat-tabs-in { padding-left: var(--gutter); }
  .mat, #resine { scroll-margin-top: 190px; }
}

/* ---------- Réalisations : cartes mieux ordonnées ---------- */
.works { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.work { position: relative; display: grid; align-content: start; gap: 10px; min-height: 250px; padding: clamp(24px, 3vw, 40px); background: var(--navy); color: var(--papaya); border-radius: 20px; overflow: hidden; transition: background 0.4s, transform 0.4s var(--ease); }
.work:hover { background: var(--brandy); transform: translateY(-4px); }
.work-num { position: absolute; right: clamp(20px, 2.6vw, 34px); top: clamp(14px, 2vw, 24px); margin: 0; font: 400 clamp(2.4rem, 5vw, 4.4rem)/1 var(--display); color: rgba(255, 236, 209, 0.14); }
.work-kicker { margin: 0; align-self: start; justify-self: start; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line-dark); font-size: 0.82rem; letter-spacing: 0.02em; }
.work-title { margin: 22px 0 0; max-width: 18ch; font: 400 clamp(1.6rem, 2.8vw, 2.4rem)/1.12 var(--display); color: #fff; }
.work-text { margin: 4px 0 0; max-width: 46ch; color: rgba(255, 236, 209, 0.82); }
@media (max-width: 820px) { .works { grid-template-columns: minmax(0, 1fr); } .work { min-height: 0; } }
.work-title { max-width: none; text-wrap: balance; font-size: clamp(1.5rem, 2.3vw, 2.1rem); margin-top: 18px; }
.work { min-height: 0; }
.work-text { text-wrap: pretty; }
