/* ═══════════════════════════════════════════════
   PMEPLUS — carrousel studio navy · cyan → violet
   ═══════════════════════════════════════════════ */

:root {
  --ink: #06080d;
  --cyan: #38bdf8;
  --violet: #7c3aff;
  --accent-dim: rgba(56, 189, 248, 0.35);
  --paper: #eef2f8;
  --muted: #8a93a6;
  --sans: "Inter", -apple-system, sans-serif;
  --display: "Space Grotesk", sans-serif;
  --mono: "Space Mono", ui-monospace, monospace;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

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

body {
  background: #000;
  color: var(--paper);
  font-family: var(--sans);
  font-weight: 300;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection { background: var(--cyan); color: var(--ink); }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }

#webgl {
  position: fixed; inset: 0;
  width: 100%; height: 100%;
  display: block;
  z-index: 0;
}

/* ═══════════ GRAIN ═══════════ */
.grain {
  position: fixed; inset: -50%;
  width: 200%; height: 200%;
  pointer-events: none;
  z-index: 9000;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 8s steps(10) infinite;
}
@keyframes grain {
  0%, 100% { transform: translate(0, 0); }
  30% { transform: translate(3%, -15%); }
  60% { transform: translate(12%, 9%); }
  90% { transform: translate(-1%, 7%); }
}

/* ═══════════ PRELOADER ═══════════ */
.preloader {
  position: fixed; inset: 0;
  background: #000;
  z-index: 10000;
  display: flex; align-items: center; justify-content: center;
}
.preloader-inner { text-align: center; }
.preloader-logo { width: clamp(140px, 20vw, 200px); margin: 0 auto 2rem; }
.preloader-bar {
  width: 220px; height: 1px;
  background: rgba(56, 189, 248, 0.2);
  margin: 0 auto 1rem;
  overflow: hidden;
}
.preloader-bar span {
  display: block; height: 100%; width: 0%;
  background: linear-gradient(90deg, var(--cyan), var(--violet));
  transition: width 0.3s var(--ease-out);
}
.preloader-count {
  font-family: var(--mono);
  font-size: 0.7rem; letter-spacing: 0.4em;
  color: var(--muted);
}

/* ═══════════ NAV ═══════════ */
.nav {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 900;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.3rem clamp(1.2rem, 4vw, 3rem);
}
.nav.is-scrolled {
  background: rgba(4, 6, 11, 0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(56, 189, 248, 0.1);
}
.nav-logo-img { height: 34px; width: auto; }
.nav-right { display: flex; align-items: center; gap: 1.4rem; }

.menu-btn {
  display: flex; align-items: center; gap: 0.6rem;
  font-family: var(--mono);
  font-size: 0.66rem; letter-spacing: 0.3em;
  color: var(--paper);
}
.menu-btn-dots { display: grid; grid-template-columns: repeat(2, 4px); gap: 3px; }
.menu-btn-dots i { width: 4px; height: 4px; background: var(--cyan); border-radius: 50%; }

.btn-pill {
  display: inline-flex; align-items: center;
  padding: 0.85rem 1.8rem;
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink);
  font-size: 0.76rem; font-weight: 600;
  letter-spacing: 0.08em; text-transform: uppercase;
  transition: box-shadow 0.3s;
}
.btn-pill:hover { box-shadow: 0 0 30px rgba(238, 242, 248, 0.25); }
.btn-pill-grad {
  background: linear-gradient(120deg, var(--cyan), var(--violet));
  color: #fff;
  padding: 1rem 2.2rem;
  font-size: 0.82rem;
}
.btn-pill-grad:hover { box-shadow: 0 0 40px rgba(92, 120, 250, 0.5); }
@media (max-width: 640px) {
  .nav .btn-pill span { display: none; }
  .nav .btn-pill::after { content: "Appel gratuit"; }
}

/* ═══════════ PALCO / HUD ═══════════ */
.stage { position: relative; height: 100svh; z-index: 1; }
.stage-hud { position: absolute; inset: 0; pointer-events: none; z-index: 500; }
.tick { position: absolute; width: 14px; height: 14px; opacity: 0.5; }
.tick-tl { top: 5.2rem; left: 1.6rem; border-top: 1px solid var(--paper); border-left: 1px solid var(--paper); }
.tick-tr { top: 5.2rem; right: 1.6rem; border-top: 1px solid var(--paper); border-right: 1px solid var(--paper); }
.tick-bl { bottom: 1.6rem; left: 1.6rem; border-bottom: 1px solid var(--paper); border-left: 1px solid var(--paper); }
.tick-br { bottom: 1.6rem; right: 1.6rem; border-bottom: 1px solid var(--paper); border-right: 1px solid var(--paper); }
.stage-meta {
  position: absolute; top: 50%;
  font-family: var(--mono);
  font-size: 0.56rem; letter-spacing: 0.32em;
  color: var(--muted);
  writing-mode: vertical-rl;
  opacity: 0.65;
}
.stage-meta-l { left: 1.7rem; transform: translateY(-50%) rotate(180deg); }
.stage-meta-r { right: 1.7rem; transform: translateY(-50%); }
@media (max-width: 768px) { .stage-meta { display: none; } }

.car-arrow {
  position: absolute; top: 50%;
  transform: translateY(-50%);
  z-index: 600;
  width: 58px; height: 58px;
  border-radius: 50%;
  border: 1px solid rgba(238, 242, 248, 0.18);
  color: var(--paper);
  font-size: 1.7rem; line-height: 1;
  display: flex; align-items: center; justify-content: center;
  transition: border-color 0.3s, background 0.3s;
}
.car-arrow:hover { border-color: var(--cyan); background: rgba(56, 189, 248, 0.1); }
.car-arrow-prev { left: clamp(1.2rem, 5vw, 4.5rem); }
.car-arrow-next { right: clamp(1.2rem, 5vw, 4.5rem); }
@media (max-width: 768px) {
  .car-arrow { top: auto; bottom: 1.4rem; width: 46px; height: 46px; }
  .car-arrow-prev { left: 1.2rem; }
  .car-arrow-next { right: 1.2rem; }
}

.stage-bottom {
  position: absolute; left: 0; right: 0; bottom: 1.8rem;
  display: flex; flex-direction: column; align-items: center; gap: 0.55rem;
  text-align: center;
  z-index: 550;
  pointer-events: none;
}
.item-index {
  font-family: var(--mono);
  font-size: 0.62rem; letter-spacing: 0.42em;
  color: var(--cyan);
}
.item-label {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2.4rem, 6.5vw, 5.4rem);
  line-height: 0.98;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  text-shadow: 0 4px 60px rgba(0, 0, 0, 0.9);
  pointer-events: auto;
  transition: color 0.3s;
  background: linear-gradient(100deg, var(--paper) 30%, #b8ccff 70%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.item-label:hover { -webkit-text-fill-color: var(--cyan); }
.item-sub {
  max-width: 480px;
  padding: 0 1.2rem;
  color: var(--muted);
  font-size: 0.88rem;
}
.stage-slider {
  width: min(360px, 56vw);
  height: 2px;
  margin-top: 0.5rem;
  background: rgba(238, 242, 248, 0.14);
  position: relative;
}
.stage-slider-fill {
  position: absolute; inset: 0;
  background: linear-gradient(90deg, var(--cyan) 0%, var(--violet) 100%);
  transform: scaleX(0); transform-origin: left;
}
.stage-cue {
  font-family: var(--mono);
  font-size: 0.58rem; letter-spacing: 0.5em; text-transform: uppercase;
  color: var(--muted);
  transition: opacity 0.6s;
}
@media (max-width: 768px) { .stage-bottom { bottom: 5.6rem; } }

/* ═══════════ CONTENU ═══════════ */
.content { position: relative; z-index: 2; }
.block {
  position: relative;
  padding: clamp(4.5rem, 9vw, 7.5rem) clamp(1.5rem, 6vw, 6rem);
  background: linear-gradient(180deg, rgba(4, 6, 11, 0.88), rgba(4, 6, 11, 0.96));
  border-top: 1px solid rgba(56, 189, 248, 0.12);
}
.block-detail {
  background: linear-gradient(180deg, rgba(4, 6, 11, 0.55), rgba(4, 6, 11, 0.9));
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  overflow: hidden;
}
.ghost-word {
  position: absolute;
  top: 0.15em; right: -0.06em;
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(6rem, 18vw, 14rem);
  line-height: 1;
  text-transform: uppercase;
  color: transparent;
  -webkit-text-stroke: 1px rgba(56, 189, 248, 0.14);
  pointer-events: none;
  white-space: nowrap;
}
.block-inner { max-width: 960px; margin: 0 auto; position: relative; }
.block-eyebrow {
  font-family: var(--mono);
  font-size: 0.65rem; letter-spacing: 0.42em; text-transform: uppercase;
  color: var(--cyan);
  margin-bottom: 1.3rem;
}
.block-title {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2rem, 5vw, 3.8rem);
  line-height: 1.02;
  letter-spacing: -0.02em;
  margin-bottom: 2rem;
}
.block-title-xl { font-size: clamp(2.6rem, 7vw, 5.6rem); }
.block-title em {
  font-style: normal;
  background: linear-gradient(100deg, var(--cyan), var(--violet));
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.detail-quote {
  font-family: var(--display);
  font-weight: 500;
  font-size: clamp(1.15rem, 2.2vw, 1.6rem);
  color: var(--cyan);
  margin: -0.8rem 0 2.2rem;
}
.detail-grid {
  display: grid;
  grid-template-columns: 1fr minmax(250px, 320px);
  gap: clamp(2.5rem, 5vw, 4.5rem);
  align-items: start;
}
@media (max-width: 860px) { .detail-grid { grid-template-columns: 1fr; } }

.lead {
  font-size: clamp(1.1rem, 1.7vw, 1.3rem);
  font-weight: 300;
  line-height: 1.75;
  color: var(--paper);
  max-width: 62ch;
  margin-bottom: 1.8rem;
}
.block p { max-width: 62ch; }
.block strong { font-weight: 500; color: var(--paper); }
.accent { color: var(--cyan); }
.accent-list {
  list-style: none;
  display: grid; gap: 0.9rem;
  margin: 1.6rem 0 2rem;
  max-width: 62ch;
}
.accent-list li {
  position: relative;
  padding-left: 2rem;
  font-size: 1rem;
  line-height: 1.7;
  color: rgba(238, 242, 248, 0.85);
}
.accent-list li::before {
  content: "▸";
  position: absolute; left: 0; top: 0;
  color: var(--cyan);
}
.block-actions {
  display: flex; align-items: center; gap: 2rem; flex-wrap: wrap;
  margin-top: 2.2rem;
}
.text-link {
  font-family: var(--mono);
  font-size: 0.72rem; letter-spacing: 0.24em; text-transform: uppercase;
  color: var(--cyan);
  border-bottom: 1px solid var(--accent-dim);
  padding-bottom: 0.3rem;
  transition: color 0.3s, border-color 0.3s;
}
.text-link:hover { color: var(--paper); border-color: var(--paper); }

/* ficha projet */
.ficha {
  position: relative;
  border: 1px solid rgba(56, 189, 248, 0.3);
  background: rgba(8, 10, 16, 0.7);
  padding: 1.6rem 1.7rem 1.3rem;
}
.ficha::before, .ficha::after {
  content: "";
  position: absolute;
  width: 12px; height: 12px;
}
.ficha::before { top: -1px; left: -1px; border-top: 2px solid var(--cyan); border-left: 2px solid var(--cyan); }
.ficha::after { bottom: -1px; right: -1px; border-bottom: 2px solid var(--violet); border-right: 2px solid var(--violet); }
.ficha-head {
  display: flex; align-items: center; justify-content: space-between;
  font-family: var(--mono);
  font-size: 0.62rem; letter-spacing: 0.34em; text-transform: uppercase;
  color: var(--cyan);
  padding-bottom: 1rem;
  margin-bottom: 0.4rem;
  border-bottom: 1px solid rgba(56, 189, 248, 0.25);
}
.ficha-head span {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1rem;
  color: var(--accent-dim);
  border: 1px solid var(--accent-dim);
  padding: 0.05rem 0.5rem;
}
.ficha-rows dt {
  font-family: var(--mono);
  font-size: 0.58rem; letter-spacing: 0.3em; text-transform: uppercase;
  color: var(--muted);
  padding-top: 0.9rem;
}
.ficha-rows dd {
  font-size: 0.98rem;
  font-weight: 400;
  color: var(--paper);
  padding-bottom: 0.9rem;
  border-bottom: 1px dashed rgba(238, 242, 248, 0.12);
}
.ficha-rows dd:last-of-type { border-bottom: none; }
.ficha-foot {
  font-family: var(--mono);
  font-size: 0.56rem; letter-spacing: 0.3em;
  color: rgba(138, 147, 166, 0.65);
  margin-top: 0.9rem;
  text-align: right;
}

/* cartes services */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.2rem;
  margin-top: 2.4rem;
}
.card {
  border: 1px solid rgba(56, 189, 248, 0.16);
  background: rgba(8, 10, 16, 0.6);
  padding: 1.8rem;
  transition: border-color 0.3s, transform 0.35s var(--ease-out);
}
.card:hover { border-color: var(--accent-dim); transform: translateY(-4px); }
.card h3 {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.05rem;
  margin-bottom: 0.6rem;
}
.card p { color: var(--muted); font-size: 0.92rem; line-height: 1.7; }

/* méthode */
.steps { display: grid; gap: 2rem; margin-top: 2.4rem; }
.step { display: grid; grid-template-columns: 58px 1fr; gap: 1.5rem; align-items: start; }
.step-num {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--cyan);
  width: 52px; height: 52px;
  border: 1px solid var(--accent-dim); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}
.step h3 {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.1rem;
  margin-bottom: 0.4rem;
}
.step p { color: rgba(238, 242, 248, 0.72); line-height: 1.75; }

/* formulaire */
.form { max-width: 640px; margin-top: 2.4rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 640px) { .form-row { grid-template-columns: 1fr; } }
.form label {
  display: block;
  font-family: var(--mono);
  font-size: 0.62rem; letter-spacing: 0.24em; text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 1.1rem;
}
.form .opt { text-transform: none; letter-spacing: 0.05em; }
.form input, .form select, .form textarea {
  display: block;
  width: 100%;
  margin-top: 0.45rem;
  padding: 0.85rem 1rem;
  background: rgba(8, 10, 16, 0.8);
  border: 1px solid rgba(238, 242, 248, 0.14);
  color: var(--paper);
  font-family: var(--sans);
  font-size: 0.98rem;
  border-radius: 8px;
  transition: border-color 0.3s;
}
.form input:focus, .form select:focus, .form textarea:focus {
  outline: none;
  border-color: var(--cyan);
}
.form-error { color: #ff7d7d; font-size: 0.85rem; min-height: 1.2em; margin-bottom: 0.6rem; }
.form-note { color: var(--muted); font-size: 0.78rem; margin-top: 1.2rem; max-width: 52ch; }
.form-note a { color: var(--cyan); }
.form-success { display: none; padding: 2rem 0; }
.form-success.show { display: block; }
.form-success h3 { font-family: var(--display); font-size: 1.4rem; margin-bottom: 0.6rem; }
.form-success p { color: var(--muted); }

.foot { margin-top: 4rem; border-top: 1px solid rgba(238, 242, 248, 0.1); padding-top: 2rem; }
.foot p { color: var(--muted); font-size: 0.9rem; margin-bottom: 0.8rem; }
.foot-legal { font-family: var(--mono); font-size: 0.66rem !important; letter-spacing: 0.1em; }
.foot-legal a { color: var(--cyan); }

/* ═══════════ MENU OVERLAY ═══════════ */
.overlay {
  position: fixed; inset: 0;
  z-index: 2000;
  background: rgba(3, 4, 8, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  opacity: 0; visibility: hidden;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 3rem;
}
.overlay-close {
  position: fixed; top: 1.6rem; right: clamp(1.2rem, 4vw, 3rem);
  font-size: 2.2rem; font-weight: 300;
  color: var(--muted);
  width: 52px; height: 52px;
  border: 1px solid rgba(238, 242, 248, 0.15);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  transition: color 0.3s, border-color 0.3s, transform 0.3s;
  z-index: 10;
}
.overlay-close:hover { color: var(--paper); border-color: var(--cyan); transform: rotate(90deg); }
.menu-links { display: flex; flex-direction: column; align-items: center; gap: 0.8rem; }
.menu-link {
  display: flex; align-items: baseline; gap: 1.2rem;
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2rem, 5.5vw, 4rem);
  line-height: 1.15;
  text-transform: uppercase;
  letter-spacing: -0.01em;
  color: var(--paper);
  transition: color 0.3s;
}
.menu-link:hover { color: var(--cyan); }
.menu-link-num {
  font-family: var(--mono);
  font-size: 0.75rem; letter-spacing: 0.3em;
  color: var(--cyan);
}
.menu-foot {
  font-family: var(--mono);
  font-size: 0.62rem; letter-spacing: 0.3em; text-transform: uppercase;
  color: var(--muted);
}

/* ═══════════ REDUCED MOTION ═══════════ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001s !important; transition-duration: 0.001s !important; }
}
