/* ==================================================================
   FontSoft — feuille de style
   ================================================================== */

/* ---------- Polices (hébergées localement, RGPD) ---------- */
@font-face { font-family: "Archivo"; src: url("../fonts/archivo-variable.woff2") format("woff2"); font-weight: 100 900; font-stretch: 62% 125%; font-display: swap; }
@font-face { font-family: "IBM Plex Sans"; src: url("../fonts/ibm-plex-sans-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "IBM Plex Sans"; src: url("../fonts/ibm-plex-sans-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "IBM Plex Sans"; src: url("../fonts/ibm-plex-sans-600.woff2") format("woff2"); font-weight: 600 700; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("../fonts/ibm-plex-mono-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }

/* ---------- Variables ---------- */
:root {
  --ink: #0E1621;
  --panel: #16212E;
  --panel-2: #1E2B3A;
  --line-dark: #2A3848;
  --muted: #55606D;
  --soft: #C3CBD5;
  --soft-2: #9DA8B5;
  --line: #DCE1E7;
  --ground: #F4F6F8;
  --white: #FFFFFF;
  --accent: #0A7582;
  --accent-dark: #075B65;
  --accent-tint: #E2F1F3;
  --accent-on-dark: #52CFD8;

  --font-display: "Archivo", "Arial Narrow", sans-serif;
  --font-body: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, Consolas, monospace;

  --gutter: clamp(16px, 4.5vw, 64px);
  --section: clamp(64px, 8vw, 112px);
  --maxw: 1320px;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 96px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; background: var(--ground); color: var(--ink); font-family: var(--font-body); font-size: 16px; line-height: 1.6; }
img, svg, video, iframe { display: block; max-width: 100%; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: var(--accent-dark); }
h1, h2, h3 { font-family: var(--font-display); font-stretch: 90%; font-weight: 800; line-height: 1.06; margin: 0; letter-spacing: -0.01em; }
h2 { font-size: clamp(30px, 3.6vw, 46px); }
h3 { font-size: clamp(20px, 1.8vw, 23px); font-weight: 700; }
p { margin: 0; }
address { font-style: normal; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 16px; top: -100px; z-index: 100; background: var(--ink); color: var(--white); padding: 12px 18px; }
.skip-link:focus { top: 12px; color: var(--white); }

.wrap { max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
.stack { display: flex; flex-direction: column; gap: 24px; align-items: flex-start; }
.stack--tight { gap: 8px; }
.stack--lg { gap: 48px; }
.lead { font-size: clamp(17px, 1.3vw, 18px); line-height: 1.65; color: var(--muted); }
.eyebrow { font-family: var(--font-mono); font-size: 13px; font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); }
.eyebrow--on-dark { color: var(--accent-on-dark); }
.icon { flex-shrink: 0; }

/* ---------- Boutons & liens ---------- */
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 12px 24px; font: 600 16px/1.2 var(--font-body); text-decoration: none; border: 1px solid transparent; border-radius: 3px; cursor: pointer; transition: background-color .15s, color .15s, border-color .15s; }
.btn--primary { background: var(--accent); color: var(--white); }
.btn--primary:hover { background: var(--accent-dark); color: var(--white); }
.btn--ghost-dark { border-color: #4A5868; color: var(--white); }
.btn--ghost-dark:hover { border-color: var(--white); color: var(--white); }
.btn--light { background: var(--white); color: var(--ink); }
.btn--light:hover { background: var(--ground); color: var(--ink); }
.btn--outline-light { border-color: var(--white); color: var(--white); }
.btn--outline-light:hover { background: var(--white); color: var(--ink); }
.arrow-link { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; font-weight: 600; text-decoration: none; }
.arrow-link .icon { transition: transform .15s; }
.arrow-link:hover .icon { transform: translateX(3px); }

/* ---------- En-tête ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: var(--white); border-bottom: 1px solid var(--line); }
.site-header__inner { display: flex; align-items: center; gap: 40px; min-height: 80px; position: relative; }
.brand { display: flex; align-items: center; gap: 14px; color: var(--ink); text-decoration: none; margin-right: auto; }
.brand:hover { color: var(--ink); }
.brand__mark { width: 46px; height: 46px; flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; background: var(--ink); color: var(--accent-on-dark); font: 500 17px/1 var(--font-mono); border-radius: 3px; }
.brand__text { display: flex; flex-direction: column; gap: 2px; }
.brand__name { font: 800 21px/1.1 var(--font-display); font-stretch: 90%; }
.brand__tag { font-family: var(--font-mono); font-size: 12px; color: var(--muted); letter-spacing: 0.02em; }

.nav { display: flex; align-items: center; gap: 36px; }
.nav__list { display: flex; gap: 32px; list-style: none; margin: 0; padding: 0; }
.nav__link { display: block; padding: 27px 0 24px; border-bottom: 3px solid transparent; color: var(--ink); text-decoration: none; font-weight: 500; }
.nav__link:hover { color: var(--accent); }
.nav__link[aria-current="page"] { border-bottom-color: var(--accent); }
.nav__cta { min-height: 44px; padding: 10px 20px; font-size: 15px; }

.nav-toggle { display: none; width: 48px; height: 48px; align-items: center; justify-content: center; border: 0; border-radius: 3px; background: var(--ink); color: var(--white); cursor: pointer; }
.nav-toggle__open { display: inline-flex; }
.nav-toggle__close { display: none; }
.nav-toggle[aria-expanded="true"] .nav-toggle__open { display: none; }
.nav-toggle[aria-expanded="true"] .nav-toggle__close { display: inline-flex; }

/* ---------- Hero accueil ---------- */
.hero { background: var(--ink); color: var(--white); overflow: hidden;
  background-image: radial-gradient(circle at 1px 1px, rgba(157, 168, 181, 0.13) 1px, transparent 0);
  background-size: 28px 28px; }
.hero__inner { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: clamp(32px, 5vw, 80px); align-items: center; padding-block: clamp(56px, 8vw, 120px); }
.hero__text { display: flex; flex-direction: column; gap: 28px; }
.hero__title { font-size: clamp(38px, 4.8vw, 62px); line-height: 1.03; }
.hero__lead { font-size: clamp(17px, 1.4vw, 19px); line-height: 1.6; color: var(--soft); max-width: 36em; }
.hero__diagram { margin: 0; }
.hero__diagram svg { width: 100%; height: auto; }

.net-links path { fill: none; stroke: #3A4A5C; stroke-width: 2; }
.net-flow path { fill: none; stroke: var(--accent-on-dark); stroke-width: 2.5; stroke-linecap: round; stroke-dasharray: 10 400; animation: flow 3.3s linear infinite; }
.net-flow path:nth-child(2) { animation-delay: -1.1s; }
.net-flow path:nth-child(3) { animation-delay: -2.2s; }
.net-flow path:nth-child(4) { animation-delay: -0.6s; }
@keyframes flow { from { stroke-dashoffset: 410; } to { stroke-dashoffset: 0; } }
@media (prefers-reduced-motion: reduce) { .net-flow { display: none; } }
.net-node rect { fill: var(--panel); stroke: #3A4A5C; stroke-width: 1.5; }
.net-node text { fill: var(--white); font: 500 15px var(--font-body); }
.net-node .net-kicker { fill: var(--soft-2); font: 500 11px var(--font-mono); letter-spacing: 0.12em; }
.net-node--core rect { fill: var(--accent-dark); stroke: var(--accent-on-dark); }
.net-node--core .net-kicker { fill: #BDEFF2; }

/* ---------- Sections ---------- */
.section { padding-block: var(--section); }
.section--white { background: var(--white); }
.section--border { border-top: 1px solid var(--line); }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px 48px; flex-wrap: wrap; margin-bottom: 48px; }
.section-head > div { display: flex; flex-direction: column; gap: 16px; max-width: 760px; }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(40px, 6vw, 96px); align-items: center; }

/* ---------- Cartes ---------- */
.cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.card { background: var(--white); border: 1px solid var(--line); border-radius: 4px; padding: clamp(24px, 2.4vw, 32px); display: flex; flex-direction: column; align-items: flex-start; gap: 16px; }
.card p { color: var(--muted); }
.card__icon { width: 52px; height: 52px; display: inline-flex; align-items: center; justify-content: center; background: var(--accent-tint); color: var(--accent); border-radius: 4px; flex-shrink: 0; }
.card__icon--lg { width: 64px; height: 64px; }
.card__title { font-size: clamp(20px, 1.7vw, 22px); }
.card__more { margin-top: auto; }

/* ---------- Liste à coches ---------- */
.check-list { list-style: none; margin: 0; padding: 0; font-size: 17px; width: 100%; }
.check-list li { display: flex; align-items: flex-start; gap: 16px; padding: 18px 0; border-top: 1px solid var(--line); }
.check-list li:last-child { border-bottom: 1px solid var(--line); }
.check-list .icon { color: var(--accent); margin-top: 2px; }

/* ---------- Étapes ---------- */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; counter-reset: none; }
.step { display: flex; flex-direction: column; gap: 12px; padding-top: 24px; border-top: 3px solid var(--ink); }
.step p { color: var(--muted); }
.step__num { font: 500 14px/1 var(--font-mono); color: var(--accent); }

/* ---------- Technologies ---------- */
.tech { background: var(--panel); color: var(--white); padding-block: 40px; }
.tech__inner { display: flex; align-items: center; gap: 20px 40px; flex-wrap: wrap; }
.tech__list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.tech__list li { font: 500 14px/1 var(--font-mono); padding: 11px 14px; border: 1px solid var(--line-dark); border-radius: 3px; color: var(--soft); }

/* ---------- Services (page détaillée) ---------- */
.service__inner { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.service__subtitle { font: 600 14px/1.4 var(--font-body); letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }

/* ---------- En-têtes de pages ---------- */
.page-hero { background: var(--ink); color: var(--white); padding-block: clamp(56px, 7vw, 96px) clamp(48px, 6vw, 88px);
  background-image: radial-gradient(circle at 1px 1px, rgba(157, 168, 181, 0.13) 1px, transparent 0);
  background-size: 28px 28px; }
.page-hero--small { padding-block: clamp(48px, 5vw, 72px); }
.page-hero__title { font-size: clamp(38px, 4.8vw, 60px); line-height: 1.04; max-width: 18em; }
.page-hero__lead { font-size: clamp(17px, 1.4vw, 19px); color: var(--soft); max-width: 42em; }
.page-hero__split { display: flex; justify-content: space-between; align-items: flex-end; gap: 32px 64px; flex-wrap: wrap; }
.page-hero__contact { display: flex; flex-direction: column; gap: 10px; }
.page-hero__phone { color: var(--white); text-decoration: none; font: 800 clamp(28px, 3vw, 34px)/1.1 var(--font-display); font-stretch: 90%; }
.page-hero__mail { color: var(--accent-on-dark); font-size: 18px; }
.page-hero__mail:hover, .page-hero__phone:hover { color: var(--white); }
.chips { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; margin: 8px 0 0; padding: 0; }
.chips a { display: inline-flex; align-items: center; min-height: 44px; padding: 8px 16px; border: 1px solid #4A5868; border-radius: 3px; color: var(--white); text-decoration: none; font-size: 15px; }
.chips a:hover { border-color: var(--white); color: var(--white); }

/* ---------- Bandeau d'appel ---------- */
.cta-band { background: var(--accent); color: var(--white); padding-block: clamp(56px, 6vw, 88px); }
.cta-band__inner { display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.cta-band p { color: #D6F1F3; font-size: 18px; }

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 24px; align-items: start; }
.panel-dark { background: var(--panel); color: var(--white); padding: clamp(28px, 3vw, 40px); border-radius: 4px; }
.panel-dark h2 { font-size: clamp(26px, 2.4vw, 32px); }
.panel-dark a { color: var(--accent-on-dark); }
.panel-dark a:hover { color: var(--white); }
.info-line { display: flex; gap: 14px; align-items: flex-start; line-height: 1.5; }
.info-line .icon { color: var(--accent-on-dark); }
.panel-dark__note { padding-top: 20px; border-top: 1px solid var(--line-dark); font-size: 14px; color: var(--soft-2); width: 100%; }

/* ---------- Formulaire ---------- */
.form { background: var(--white); border: 1px solid var(--line); border-radius: 4px; padding: clamp(24px, 3vw, 40px); display: flex; flex-direction: column; gap: 20px; }
.form h2 { font-size: clamp(26px, 2.4vw, 32px); }
.form__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.field { display: flex; flex-direction: column; gap: 8px; }
.field label { font-size: 14px; font-weight: 600; }
.field input, .field select, .field textarea { font: inherit; min-height: 48px; padding: 10px 14px; border: 1px solid #8A95A2; border-radius: 3px; background: var(--white); color: var(--ink); width: 100%; }
.field textarea { resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 3px solid var(--accent); outline-offset: 0; border-color: var(--accent); }
.field--check { flex-direction: row; align-items: flex-start; gap: 12px; }
.field--check input { width: 20px; height: 20px; min-height: 0; margin: 2px 0 0; flex-shrink: 0; accent-color: var(--accent); }
.field--check label { font-weight: 400; color: var(--muted); }
.req { color: #B42318; }
.form__note { font-size: 13px; color: var(--muted); }
.form__hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form__status { padding: 14px 18px; font-weight: 500; border-radius: 3px; }
.form__status--ok { background: #E6F2EA; color: #1E5631; }
.form__status--error { background: #FDECEA; color: #912018; }
.field.is-invalid input, .field.is-invalid textarea { border-color: #B42318; }
.field--check.is-invalid label { color: #912018; }
.form .btn { align-self: flex-start; }

/* ---------- Texte courant ---------- */
.prose { max-width: 820px; display: flex; flex-direction: column; gap: 16px; }
.prose h2 { font-size: clamp(24px, 2.4vw, 30px); margin-top: 24px; }
.prose h2:first-child { margin-top: 0; }

/* ---------- Pied de page ---------- */
.site-footer { background: var(--ink); color: var(--soft-2); font-size: 15px; padding: 64px 0 32px; }
.site-footer a { color: var(--soft-2); text-decoration: none; }
.site-footer a:hover { color: var(--white); text-decoration: underline; }
.site-footer__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px; }
.site-footer__col { display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }
.site-footer__col address { line-height: 1.6; }
.site-footer__name { color: var(--white); font-weight: 600; }
.site-footer__title { font: 600 14px/1.4 var(--font-body); letter-spacing: 0.06em; text-transform: uppercase; color: var(--white); margin-bottom: 4px; }
.site-footer__bottom { display: flex; flex-wrap: wrap; gap: 12px 24px; margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--line-dark); font-size: 13px; color: #8C97A4; }
.site-footer__bottom a { color: #8C97A4; text-decoration: underline; }

/* ==================================================================
   Adaptatif
   ================================================================== */
@media (max-width: 1200px) {
  .cards, .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .steps { row-gap: 40px; }
}

@media (max-width: 960px) {
  .site-header__inner { gap: 12px; min-height: 72px; }
  .nav-toggle { display: inline-flex; }
  .nav { display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 0; background: var(--white); border-bottom: 1px solid var(--line); padding: 8px var(--gutter) 24px; box-shadow: 0 16px 24px -16px rgba(14, 22, 33, 0.25); }
  .nav.is-open { display: flex; }
  .nav__list { flex-direction: column; gap: 0; }
  .nav__link { padding: 16px 0; border-bottom: 1px solid var(--line); }
  .nav__link[aria-current="page"] { border-bottom-color: var(--line); color: var(--accent); }
  .nav__cta { margin-top: 20px; }

  .hero__inner, .split, .service__inner, .contact-grid { grid-template-columns: minmax(0, 1fr); }
  .hero__diagram { max-width: 560px; }
  .site-footer__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 640px) {
  .brand__mark { width: 40px; height: 40px; font-size: 15px; }
  .brand__name { font-size: 19px; }
  .brand__tag { display: none; }
  .btn-row .btn { flex-grow: 1; }
  .cards, .steps { grid-template-columns: minmax(0, 1fr); }
  .section-head { margin-bottom: 32px; }
  .form__grid { grid-template-columns: minmax(0, 1fr); }
  .form .btn { align-self: stretch; }
  .cta-band__inner .btn-row { width: 100%; }
  .site-footer__grid { grid-template-columns: minmax(0, 1fr); gap: 32px; }
}
