/* =========================================================================
   Comptoir Numérique — feuille de style
   Direction : studio numérique B2B. Dark monochrome noir/blanc + accent bleu.
   ========================================================================= */

:root {
  /* Surfaces sombres */
  --bg:        #111111;  /* page, nav, hero */
  --bg-soft:   #0d0d0d;  /* bandeaux, footer */
  --surface:   #171717;  /* cartes */
  --surface-2: #1e1e1e;  /* survol / imbriqué */

  /* Surfaces claires (pour casser le tout-noir) */
  --light:     #f7f7f5;
  --white:     #ffffff;

  /* Texte */
  --text:      #f4f4f2;                    /* sur fond sombre */
  --muted:     rgba(244, 244, 242, 0.60);  /* secondaire sur sombre */
  --ink:       #131313;                    /* sur fond clair */
  --muted-ink: rgba(19, 19, 19, 0.62);     /* secondaire sur clair */

  /* Traits */
  --line:      rgba(244, 244, 242, 0.12);
  --line-lt:   rgba(19, 19, 19, 0.12);

  /* Accent */
  --accent:      #4f6dff;
  --accent-soft: #93a6ff;

  /* Typo */
  --display: "Bricolage Grotesque", "Segoe UI", system-ui, sans-serif;
  --body:    "Inter", system-ui, -apple-system, sans-serif;

  /* Rythme */
  --wrap: 1120px;
  --pad: clamp(20px, 5vw, 64px);
  --radius: 14px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--body);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--display);
  line-height: 1.08;
  letter-spacing: -0.015em;
  margin: 0;
}
p { margin: 0 0 1rem; }
a { color: inherit; }

.skip { position: absolute; left: -999px; }
.skip:focus {
  left: 16px; top: 16px; z-index: 100;
  background: var(--accent); color: #fff;
  padding: 10px 16px; border-radius: 8px; font-weight: 600;
}

/* ---- Boutons ----------------------------------------------------------- */

.btn {
  display: inline-block;
  font-family: var(--body);
  font-weight: 600;
  font-size: 0.98rem;
  padding: 13px 22px;
  border-radius: 10px;
  border: 1.5px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.12s ease, background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}
.btn:active { transform: translateY(1px); }

.btn--brass { background: var(--accent); color: #fff; }
.btn--brass:hover { background: #6079ff; }

.btn--ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--line);
}
.btn--ghost:hover { border-color: var(--text); }

.btn--dark { background: var(--accent); color: #fff; }
.btn--dark:hover { background: #6079ff; }

a:focus-visible, button:focus-visible, summary:focus-visible, input:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

/* ---- Navigation -------------------------------------------------------- */

.nav {
  background: rgba(17, 17, 17, 0.82);
  backdrop-filter: blur(10px);
  color: var(--text);
  position: sticky; top: 0; z-index: 40;
  border-bottom: 1px solid var(--line);
}
.nav__inner {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 14px var(--pad);
  display: flex; align-items: center; gap: 20px;
}
.brand {
  display: flex; align-items: center; gap: 12px;
  text-decoration: none;
  color: var(--text);
  font-family: var(--display); font-weight: 800;
}
.brand__name { font-size: 1.18rem; letter-spacing: -0.02em; }
.brand__mark { color: var(--text); display: flex; }

.menu { display: flex; gap: 4px; margin-left: auto; }
.menu a {
  text-decoration: none;
  color: var(--muted);
  font-weight: 500;
  padding: 8px 14px; border-radius: 8px;
  transition: color 0.15s, background 0.15s;
}
.menu a:hover { color: var(--text); background: rgba(255,255,255,0.05); }
.menu a.is-active { color: var(--text); }
.menu a.is-active::after {
  content: ""; display: block; height: 2px; margin-top: 5px;
  background: var(--accent); border-radius: 2px;
}

.nav__cta { padding: 10px 18px; white-space: nowrap; }
.nav__cta-short { display: none; }

/* ---- Hero -------------------------------------------------------------- */

.hero {
  background:
    radial-gradient(900px 480px at 82% -20%, rgba(79, 109, 255, 0.16), transparent 62%),
    var(--bg);
  color: var(--text);
  border-bottom: 1px solid var(--line);
}
.hero__inner {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: clamp(48px, 8vw, 100px) var(--pad);
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
}
.hero__kicker {
  font-weight: 600;
  color: var(--accent-soft);
  margin: 0 0 14px;
  font-size: 0.95rem;
}
.hero__title {
  font-size: clamp(2.1rem, 4.6vw, 3.7rem);
  font-weight: 800;
  color: var(--text);
  max-width: 15ch;
}
.hero__lead {
  font-size: clamp(1.05rem, 1.6vw, 1.22rem);
  color: var(--muted);
  margin: 22px 0 30px;
  max-width: 46ch;
}
.hero__cta { display: flex; gap: 14px; flex-wrap: wrap; }
.hero__note { margin-top: 20px; color: var(--muted); font-size: 0.9rem; }
.hero__art { display: flex; justify-content: center; }
.storefront {
  width: 100%; max-width: 380px;
  filter: drop-shadow(0 24px 48px rgba(0,0,0,0.55));
}

/* ---- Bandeau secteurs -------------------------------------------------- */

.strip {
  background: var(--bg-soft);
  color: var(--muted);
  border-bottom: 1px solid var(--line);
}
.strip__inner {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 18px var(--pad);
  display: flex; flex-wrap: wrap; gap: 12px 36px;
  justify-content: center;
  font-family: var(--display); font-weight: 600; font-size: 0.98rem;
}

/* ---- En-têtes de section ---------------------------------------------- */

.section__head {
  max-width: var(--wrap);
  margin: 0 auto 40px;
  padding: 0 var(--pad);
}
.section__head h2 {
  font-size: clamp(1.8rem, 3.2vw, 2.6rem);
  font-weight: 800;
  max-width: 20ch;
}
.section__head p {
  margin-top: 14px;
  color: var(--muted);
  max-width: 52ch;
  font-size: 1.05rem;
}
.section__head--light h2 { color: var(--text); }
.section__head--light p { color: var(--muted); }

/* ---- Services (section CLAIRE, pour le contraste) --------------------- */

.services {
  background: var(--light);
  color: var(--ink);
  padding: clamp(56px, 8vw, 96px) 0;
}
.services .section__head h2 { color: var(--ink); }
.services .section__head p  { color: var(--muted-ink); }
.services__grid {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 var(--pad);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.svc {
  background: var(--white);
  border: 1px solid var(--line-lt);
  border-radius: var(--radius);
  padding: 30px 28px;
  display: flex; flex-direction: column;
}
.svc--lead {
  background: var(--bg);
  color: var(--text);
  border-color: transparent;
}
.svc h3 { font-size: 1.4rem; font-weight: 700; margin-bottom: 12px; color: var(--ink); }
.svc--lead h3 { color: var(--text); }
.svc > p { color: var(--muted-ink); }
.svc--lead > p { color: var(--muted); }
.svc ul { list-style: none; padding: 0; margin: 8px 0 20px; display: grid; gap: 9px; }
.svc li { position: relative; padding-left: 26px; font-size: 0.96rem; }
.svc li::before {
  content: "";
  position: absolute; left: 4px; top: 8px;
  width: 9px; height: 5px;
  border-left: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: rotate(-45deg);
}
.svc__price {
  margin: auto 0 0;
  font-family: var(--display); font-weight: 700; font-size: 1.15rem;
  color: var(--accent);
}
.svc--lead .svc__price { color: var(--accent-soft); }

/* ---- Process (sombre) ------------------------------------------------- */

.process { background: var(--bg); padding: clamp(56px, 8vw, 96px) 0; }
.steps {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 var(--pad);
  list-style: none;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
}
.step { color: var(--text); }
.step__num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 42px; height: 42px;
  border-radius: 50%;
  border: 1.5px solid var(--accent);
  color: var(--accent-soft);
  font-family: var(--display); font-weight: 700; font-size: 1.15rem;
  margin-bottom: 16px;
}
.step h3 { font-size: 1.15rem; font-weight: 700; color: var(--text); margin-bottom: 8px; }
.step p { color: var(--muted); font-size: 0.95rem; margin: 0; }

/* ---- Bande d'appel à l'action ----------------------------------------- */

.cta-band {
  background: var(--bg-soft);
  color: var(--text);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  position: relative;
  overflow: hidden;
}
.cta-band::before {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(700px 300px at 50% 140%, rgba(79,109,255,0.18), transparent 70%);
  pointer-events: none;
}
.cta-band__inner {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: clamp(48px, 7vw, 84px) var(--pad);
  text-align: center;
  position: relative;
}
.cta-band h2 { font-size: clamp(1.8rem, 3.4vw, 2.7rem); font-weight: 800; }
.cta-band p { margin: 14px auto 26px; max-width: 48ch; color: var(--muted); font-size: 1.08rem; }
.cta-band .btn--brass { background: var(--accent); color: #fff; }
.cta-band .btn--brass:hover { background: #6079ff; }

/* ---- En-tête de page interne ------------------------------------------ */

.page-head {
  background:
    radial-gradient(800px 400px at 88% -30%, rgba(79,109,255,0.14), transparent 60%),
    var(--bg);
  color: var(--text);
  border-bottom: 1px solid var(--line);
}
.page-head__inner {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: clamp(52px, 7vw, 88px) var(--pad) clamp(40px, 6vw, 64px);
}
.page-head h1 {
  font-size: clamp(2rem, 4vw, 3.2rem);
  font-weight: 800;
  color: var(--text);
  max-width: 18ch;
  margin-top: 12px;
}
.page-head__lead { margin-top: 18px; color: var(--muted); max-width: 54ch; font-size: 1.1rem; }

/* ---- Détail services --------------------------------------------------- */

.detail {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: clamp(48px, 7vw, 88px) var(--pad);
  display: grid; gap: 28px;
}
.detail__row {
  display: grid;
  grid-template-columns: 1.6fr 0.9fr;
  gap: 40px;
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  align-items: center;
}
.detail__row--alt { background: var(--surface-2); }
.detail__text h2 { font-size: clamp(1.5rem, 2.6vw, 2rem); font-weight: 800; margin-bottom: 12px; }
.detail__text > p { color: var(--muted); }
.ticks { list-style: none; padding: 0; margin: 16px 0 0; display: grid; gap: 10px; }
.ticks li { position: relative; padding-left: 28px; color: var(--text); }
.ticks li::before {
  content: "";
  position: absolute; left: 4px; top: 8px;
  width: 10px; height: 6px;
  border-left: 2.5px solid var(--accent);
  border-bottom: 2.5px solid var(--accent);
  transform: rotate(-45deg);
}
.detail__aside {
  text-align: center;
  padding: 24px;
  background: var(--bg-soft);
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 12px;
}
.detail__price { font-family: var(--display); font-weight: 800; font-size: 2.1rem; color: var(--accent-soft); margin: 0; }
.detail__pricenote { color: var(--muted); font-size: 0.9rem; margin: 6px 0 18px; }

/* ---- FAQ --------------------------------------------------------------- */

.faq { padding: 0 0 clamp(48px, 7vw, 88px); }
.faq__list { max-width: 780px; margin: 0 auto; padding: 0 var(--pad); display: grid; gap: 12px; }
.faq details {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 6px 22px;
}
.faq summary {
  cursor: pointer;
  font-family: var(--display); font-weight: 600; font-size: 1.08rem;
  padding: 14px 0; list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; float: right; color: var(--accent); font-size: 1.4rem; line-height: 1; }
.faq details[open] summary::after { content: "\2013"; }
.faq details p { color: var(--muted); margin: 0 0 16px; }

/* ---- Réalisations ------------------------------------------------------ */

.work {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: clamp(48px, 7vw, 88px) var(--pad);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.case {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  display: flex; flex-direction: column;
  transition: border-color 0.18s ease;
}
.case:hover { border-color: rgba(79,109,255,0.5); }
.case__tag {
  align-self: flex-start;
  background: rgba(79, 109, 255, 0.14);
  color: var(--accent-soft);
  font-weight: 600; font-size: 0.82rem;
  padding: 4px 12px; border-radius: 999px;
  margin-bottom: 16px;
}
.case h2 { font-size: 1.35rem; font-weight: 700; margin-bottom: 10px; }
.case > p { color: var(--muted); font-size: 0.98rem; }
.case__stats { display: flex; gap: 28px; margin: 16px 0; }
.case__stats div { margin: 0; }
.case__stats dt { font-size: 0.78rem; color: var(--muted); }
.case__stats dd {
  margin: 2px 0 0;
  font-family: var(--display); font-weight: 800; font-size: 1.5rem;
  color: var(--text);
}
.case__what {
  margin: auto 0 0;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-weight: 600; color: var(--accent-soft); font-size: 0.92rem;
}

/* ---- Contact ----------------------------------------------------------- */

.contact { max-width: var(--wrap); margin: 0 auto; padding: clamp(48px, 7vw, 80px) var(--pad); }
.contact__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.contact__card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
}
.contact__card--wide {
  grid-column: 1 / -1;
  background:
    radial-gradient(600px 300px at 90% 0%, rgba(79,109,255,0.16), transparent 60%),
    var(--bg-soft);
  color: var(--text);
  border-color: var(--line);
  display: flex; flex-direction: column; align-items: flex-start; gap: 6px;
}
.contact__card--wide h2 { font-size: 1.6rem; font-weight: 800; color: var(--text); margin-bottom: 6px; }
.contact__card--wide p { color: var(--muted); margin-bottom: 18px; }
.contact__card h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 8px; }
.contact__card a { color: var(--accent-soft); font-weight: 600; text-decoration: none; }
.contact__card p { color: var(--muted); margin: 8px 0 0; font-size: 0.95rem; }
.ref-sample {
  font-variant-numeric: tabular-nums;
  background: rgba(79,109,255,0.16);
  color: var(--accent-soft);
  padding: 1px 8px; border-radius: 6px;
}

/* ---- Pied de page ------------------------------------------------------ */

.foot { background: var(--bg-soft); color: var(--muted); border-top: 1px solid var(--line); }
.foot__inner {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: clamp(44px, 6vw, 72px) var(--pad) 32px;
  display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px;
}
.foot__brand .brand__name { color: var(--text); font-size: 1.25rem; }
.foot__brand p { margin-top: 12px; max-width: 40ch; }
.foot__cols { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.foot__cols h3 { font-size: 0.82rem; font-weight: 600; color: var(--accent-soft); margin-bottom: 12px; letter-spacing: 0.02em; }
.foot__cols a, .foot__cols span { display: block; text-decoration: none; color: var(--muted); padding: 4px 0; }
.foot__cols a:hover { color: var(--text); }
.foot__base {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 20px var(--pad);
  border-top: 1px solid var(--line);
  display: flex; justify-content: space-between;
  font-size: 0.86rem; color: var(--muted); gap: 12px; flex-wrap: wrap;
}

/* =========================================================================
   Widget de chat
   ========================================================================= */

.chat-launcher {
  position: fixed; right: 22px; bottom: 22px; z-index: 60;
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--accent); color: #fff;
  border: none; border-radius: 999px;
  padding: 14px 20px;
  font-family: var(--body); font-weight: 600; font-size: 0.98rem;
  cursor: pointer;
  box-shadow: 0 12px 30px rgba(79, 109, 255, 0.4);
  transition: transform 0.15s ease, background 0.18s ease;
}
.chat-launcher:hover { background: #6079ff; transform: translateY(-2px); }
.chat-launcher.is-hidden { display: none; }

.chat {
  position: fixed; right: 22px; bottom: 22px; z-index: 61;
  width: min(380px, calc(100vw - 32px));
  height: min(560px, calc(100vh - 44px));
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.6);
  display: flex; flex-direction: column; overflow: hidden;
  transform-origin: bottom right;
}
.chat[hidden] { display: none; }
.chat.is-opening { animation: chat-pop 0.22s ease; }
@keyframes chat-pop {
  from { opacity: 0; transform: translateY(12px) scale(0.96); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
.chat__head {
  background: var(--bg);
  color: var(--text);
  padding: 16px 18px;
  display: flex; align-items: center; justify-content: space-between;
  border-bottom: 1px solid var(--line);
}
.chat__title { font-family: var(--display); font-weight: 700; margin: 0; color: var(--text); }
.chat__status { margin: 2px 0 0; font-size: 0.8rem; color: var(--muted); }
.chat__close { background: transparent; border: none; color: var(--muted); cursor: pointer; padding: 4px; border-radius: 8px; }
.chat__close:hover { background: rgba(255,255,255,0.08); color: var(--text); }

.chat__log { flex: 1; overflow-y: auto; padding: 18px; display: flex; flex-direction: column; gap: 10px; }
.msg { max-width: 82%; padding: 10px 14px; border-radius: 14px; font-size: 0.95rem; line-height: 1.45; white-space: pre-wrap; word-wrap: break-word; }
.msg--bot { align-self: flex-start; background: var(--surface-2); border: 1px solid var(--line); color: var(--text); border-bottom-left-radius: 4px; }
.msg--user { align-self: flex-end; background: var(--accent); color: #fff; border-bottom-right-radius: 4px; }
.msg--note {
  align-self: center;
  background: rgba(79,109,255,0.16);
  color: var(--accent-soft);
  font-size: 0.85rem; font-weight: 600;
  border-radius: 999px; padding: 6px 14px;
}
.chat__quick { display: flex; flex-wrap: wrap; gap: 8px; padding: 0 18px; }
.chat__quick:empty { padding: 0; }
.quick {
  background: transparent;
  border: 1.5px solid var(--accent);
  color: var(--accent-soft);
  border-radius: 999px; padding: 8px 14px;
  font-family: var(--body); font-size: 0.9rem; font-weight: 500;
  cursor: pointer; transition: background 0.15s, color 0.15s;
}
.quick:hover { background: var(--accent); color: #fff; }
.chat__form { display: flex; gap: 8px; padding: 14px 18px 18px; border-top: 1px solid var(--line); }
.chat__input {
  flex: 1;
  border: 1.5px solid var(--line);
  border-radius: 10px; padding: 11px 14px;
  font-family: var(--body); font-size: 0.95rem;
  background: var(--bg); color: var(--text);
}
.chat__input::placeholder { color: var(--muted); }
.chat__input:focus { border-color: var(--accent); outline: none; }
.chat__send { background: var(--accent); color: #fff; border: none; border-radius: 10px; width: 46px; display: grid; place-items: center; cursor: pointer; }
.chat__send:hover { background: #6079ff; }

.typing { display: inline-flex; gap: 4px; align-items: center; }
.typing span { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); opacity: 0.6; animation: typing 1s infinite; }
.typing span:nth-child(2) { animation-delay: 0.15s; }
.typing span:nth-child(3) { animation-delay: 0.3s; }
@keyframes typing {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.4; }
  30% { transform: translateY(-4px); opacity: 0.9; }
}

/* =========================================================================
   Responsive
   ========================================================================= */

@media (max-width: 900px) {
  .hero__inner { grid-template-columns: 1fr; }
  .hero__art { order: -1; max-width: 300px; margin: 0 auto; }
  .services__grid { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr 1fr; }
  .work { grid-template-columns: 1fr 1fr; }
  .contact__grid { grid-template-columns: 1fr 1fr; }
  .detail__row { grid-template-columns: 1fr; gap: 24px; }
  .foot__inner { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .menu { display: none; }
  .nav__cta { margin-left: auto; }
  .nav__cta-full { display: none; }
  .nav__cta-short { display: inline; }
  .brand__name { font-size: 1.05rem; }
  .steps { grid-template-columns: 1fr; }
  .work { grid-template-columns: 1fr; }
  .contact__grid { grid-template-columns: 1fr; }
  .case__stats { gap: 20px; }
  .chat-launcher__label { display: none; }
  .chat-launcher { padding: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; scroll-behavior: auto !important; }
  .btn, .chat-launcher { transition: none; }
}
