/* ==========================================================================
   ALPA Data — Proposition 3 · « Signal »
   Du bruit au signal — canvas génératif, typo cinétique, mono-brutal calme
   ========================================================================== */

:root {
  --nuit: #071B2B;
  --noir: #0B1015;
  --cyan: #19E7E1;
  --bleu: #38BDF8;
  --blanc: #F4F8FB;
  --gris: #9BA8B5;

  --rule: rgba(155, 168, 181, .14);

  --font-display: "Space Grotesk", sans-serif;
  --font-mono: "JetBrains Mono", monospace;

  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --gutter: clamp(20px, 6vw, 96px);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; overflow-x: clip; }

body {
  background: var(--noir);
  color: var(--blanc);
  font-family: var(--font-display);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

.mono { font-family: var(--font-mono); }
.accent { color: var(--cyan); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

::selection { background: rgba(25, 231, 225, .25); }

/* ==========================================================================
   Canvas plein écran
   ========================================================================== */

#field {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

main, .bar, .footer { position: relative; z-index: 1; }

/* ==========================================================================
   Curseur custom
   ========================================================================== */

.cursor {
  position: fixed;
  z-index: 99;
  width: 14px; height: 14px;
  border: 1.5px solid var(--cyan);
  border-radius: 50%;
  pointer-events: none;
  transform: translate(-50%, -50%);
  transition: width .3s var(--ease-out), height .3s var(--ease-out),
              background .3s, opacity .3s;
  opacity: 0;
  mix-blend-mode: screen;
}
.cursor.is-on { opacity: 1; }
.cursor.is-hover {
  width: 46px; height: 46px;
  background: rgba(25, 231, 225, .08);
}
@media (pointer: coarse) { .cursor { display: none; } }

/* ==========================================================================
   Header
   ========================================================================== */

.bar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 60;
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  padding: 16px var(--gutter);
  mix-blend-mode: normal;
  background: linear-gradient(180deg, rgba(11, 16, 21, .9) 30%, rgba(11, 16, 21, 0));
}

.bar__brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 700;
  font-size: 16px;
  letter-spacing: .01em;
}
.bar__brand img { border-radius: 8px; }
.bar__brand em { font-style: normal; color: var(--cyan); }

.bar__nav { display: flex; gap: 26px; }
.bar__nav a {
  font-size: 11px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--gris);
  transition: color .3s;
}
.bar__nav a:hover { color: var(--cyan); }

@media (max-width: 820px) {
  .bar__nav { gap: 16px; }
}

@media (max-width: 640px) {
  .bar {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding-bottom: 12px;
  }
  .bar__nav { gap: 14px; flex-wrap: wrap; }
  .bar__nav a { font-size: 10px; }
  .hero { padding-top: 140px; }
}

/* ==========================================================================
   Hero
   ========================================================================== */

.hero {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 96px var(--gutter) 30px;
}

.hero__tag {
  font-size: 10.5px;
  letter-spacing: .26em;
  color: var(--gris);
  margin-bottom: clamp(16px, 3vh, 36px);
}

/* Taille bornée par la hauteur du viewport : le titre ne déborde
   jamais sous la ligne de flottaison, y compris sur un 13 pouces. */
.hero__title {
  font-weight: 700;
  font-size: clamp(48px, min(12.5vw, 16.5vh), 180px);
  line-height: .92;
  letter-spacing: -.04em;
  text-transform: uppercase;
  margin-bottom: clamp(24px, 4vh, 48px);
}
.hero__row { display: block; overflow: hidden; padding-bottom: .04em; }
.hero__row--shift { margin-left: clamp(30px, 8vw, 160px); }

.hero__row .w {
  display: inline-block;
  transform: translateY(112%);
  animation: wRise 1.1s var(--ease-out) forwards;
}
.hero__row:nth-child(1) .w { animation-delay: .05s; }
.hero__row:nth-child(2) .w { animation-delay: .15s; }
.hero__row:nth-child(3) .w { animation-delay: .25s; }
@keyframes wRise { to { transform: translateY(0); } }

.w--ghost {
  color: transparent;
  -webkit-text-stroke: 1.5px rgba(244, 248, 251, .5);
}
.w--accent { color: var(--cyan); }

.hero__foot {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 32px;
  flex-wrap: wrap;
  border-top: 1px solid var(--rule);
  padding-top: 22px;
}

.hero__lede {
  max-width: 52ch;
  color: var(--gris);
  font-size: 16px;
}

.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; }

.hero__mention {
  margin-top: 20px;
  font-size: 9.5px;
  letter-spacing: .22em;
  color: var(--gris);
  opacity: .7;
}

/* ==========================================================================
   Boutons
   ========================================================================== */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 16px 30px;
  font-weight: 600;
  font-size: 14px;
  letter-spacing: .02em;
  border-radius: 2px;
  position: relative;
  overflow: hidden;
  transition: color .35s, transform .3s var(--ease-out), box-shadow .35s;
}

.btn--full {
  background: var(--cyan);
  color: #03211F;
  box-shadow: 0 0 0 rgba(25, 231, 225, 0);
}
.btn--full:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 34px rgba(25, 231, 225, .35);
}

.btn--hollow { border: 1px solid rgba(244, 248, 251, .3); }
.btn--hollow::before {
  content: "";
  position: absolute; inset: 0;
  background: var(--blanc);
  transform: scaleY(0);
  transform-origin: bottom;
  transition: transform .35s var(--ease-out);
  z-index: -1;
}
.btn--hollow:hover { color: var(--noir); }
.btn--hollow:hover::before { transform: scaleY(1); }

/* ==========================================================================
   Têtes de section
   ========================================================================== */

.sect {
  padding: 0 var(--gutter);
  margin-bottom: clamp(40px, 7vh, 72px);
  max-width: 1100px;
}
.sect--row {
  max-width: none;
  display: flex; align-items: flex-end; justify-content: space-between; gap: 24px;
  flex-wrap: wrap;
}
.sect__title {
  font-weight: 700;
  font-size: clamp(38px, 6.5vw, 92px);
  letter-spacing: -.03em;
  line-height: 1;
  text-transform: uppercase;
}
.sect__lede { margin-top: 20px; color: var(--gris); max-width: 52ch; font-size: 16.5px; }
.sect__lede strong { color: var(--blanc); }

/* ==========================================================================
   Le bruit
   ========================================================================== */

.noise { padding: clamp(90px, 15vh, 160px) 0; overflow-x: clip; }

.noise__belt {
  display: flex;
  flex-direction: column;
  gap: 14px;
  transform: rotate(-2deg) scale(1.02);
  margin: 10px -20px;
}

.marquee {
  overflow: hidden;
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  background: rgba(7, 27, 43, .55);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}
.marquee__track {
  display: flex;
  align-items: center;
  gap: 34px;
  width: max-content;
  padding: 18px 0;
  font-size: clamp(14px, 2vw, 22px);
  font-weight: 700;
  letter-spacing: .14em;
  color: var(--gris);
  animation: slide 26s linear infinite;
}
.marquee--reverse .marquee__track { animation-direction: reverse; }
@keyframes slide { to { transform: translateX(-50%); } }

.marquee__track span {
  text-decoration: line-through;
  text-decoration-thickness: 2px;
  text-decoration-color: rgba(25, 231, 225, .65);
  white-space: nowrap;
}
.marquee__track i {
  font-style: normal;
  color: var(--cyan);
  font-size: .7em;
}
.marquee:hover .marquee__track { animation-play-state: paused; }

.noise__counter {
  margin-top: clamp(36px, 6vh, 60px);
  padding: 0 var(--gutter);
  text-align: center;
  font-size: 10.5px;
  letter-spacing: .3em;
  color: var(--gris);
}

/* ==========================================================================
   Le signal — méthode
   ========================================================================== */

.signal { padding: clamp(90px, 15vh, 160px) 0; }

.method {
  list-style: none;
  border-top: 1px solid var(--rule);
  margin: 0 var(--gutter);
}

.method__item {
  display: grid;
  grid-template-columns: minmax(90px, 200px) minmax(0, 1fr) 100px;
  align-items: center;
  gap: clamp(20px, 4vw, 60px);
  padding: clamp(28px, 5vh, 48px) 8px;
  border-bottom: 1px solid var(--rule);
  position: relative;
  transition: background .35s;
}
.method__item::after {
  content: "";
  position: absolute; left: 0; bottom: -1px;
  height: 1px; width: 100%;
  background: var(--cyan);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .5s var(--ease-out);
}
.method__item:hover { background: rgba(56, 189, 248, .03); }
.method__item:hover::after { transform: scaleX(1); }

.method__num {
  font-weight: 700;
  font-size: clamp(64px, 9vw, 140px);
  line-height: 1;
  letter-spacing: -.04em;
  color: transparent;
  -webkit-text-stroke: 1.5px rgba(155, 168, 181, .5);
  transition: color .4s, -webkit-text-stroke-color .4s;
}
.method__item:hover .method__num {
  color: var(--cyan);
  -webkit-text-stroke-color: var(--cyan);
}

.method__title {
  font-weight: 700;
  font-size: clamp(22px, 2.6vw, 34px);
  letter-spacing: -.02em;
  margin-bottom: 8px;
}
.method__text { color: var(--gris); font-size: 15.5px; max-width: 56ch; }
.method__meta {
  font-size: 10px;
  letter-spacing: .26em;
  color: var(--gris);
  text-align: right;
}

@media (max-width: 760px) {
  .method__item { grid-template-columns: 70px 1fr; }
  .method__meta { display: none; }
}

/* ==========================================================================
   Enquêtes — rail horizontal
   ========================================================================== */

.eps { padding: clamp(90px, 15vh, 160px) 0; }

.eps__hint { font-size: 10px; letter-spacing: .3em; color: var(--gris); animation: nudge 2.4s ease-in-out infinite; }
@keyframes nudge { 50% { transform: translateX(8px); } }

.eps__rail {
  display: flex;
  gap: 18px;
  padding: 6px var(--gutter) 26px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  cursor: grab;
  scrollbar-width: none;
}
.eps__rail::-webkit-scrollbar { display: none; }
.eps__rail.is-dragging { cursor: grabbing; scroll-snap-type: none; }

.ep {
  flex: 0 0 clamp(280px, 30vw, 380px);
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  min-height: clamp(300px, 40vh, 380px);
  padding: 26px;
  border: 1px solid var(--rule);
  border-radius: 4px;
  background:
    radial-gradient(circle at 85% 12%, rgba(25, 231, 225, .07), transparent 45%),
    rgba(7, 27, 43, .72);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  transition: border-color .35s, transform .35s var(--ease-out), background .35s;
  user-select: none;
}
.ep:hover { border-color: rgba(25, 231, 225, .4); transform: translateY(-6px); }

.ep__id { font-size: 10px; letter-spacing: .2em; color: var(--cyan); margin-bottom: auto; }
.ep__title {
  font-weight: 700;
  font-size: clamp(21px, 2.2vw, 27px);
  letter-spacing: -.02em;
  line-height: 1.15;
  margin: 20px 0 12px;
}
.ep__desc { color: var(--gris); font-size: 14.5px; margin-bottom: 24px; }
.ep__status {
  font-size: 9.5px;
  letter-spacing: .22em;
  color: var(--gris);
  border: 1px solid var(--rule);
  border-radius: 2px;
  padding: 6px 10px;
  align-self: flex-start;
}
.ep__status--live {
  color: var(--cyan);
  border-color: rgba(25, 231, 225, .32);
}

.ep--cta {
  align-items: center;
  justify-content: center;
  gap: 20px;
  text-align: center;
  background: rgba(25, 231, 225, .05);
  border-color: rgba(25, 231, 225, .3);
}
.ep__more { font-weight: 700; font-size: 21px; letter-spacing: -.01em; line-height: 1.3; }
.ep--cta svg {
  width: 34px; height: 34px;
  fill: none; stroke: var(--cyan); stroke-width: 1.6;
  stroke-linecap: round; stroke-linejoin: round;
  transition: transform .35s var(--ease-out);
}
.ep--cta:hover svg { transform: translateX(8px); }

.eps__note {
  margin-top: clamp(20px, 3vh, 34px);
  padding: 0 var(--gutter);
  font-size: 10.5px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gris);
}

/* ==========================================================================
   Outil
   ========================================================================== */

.tool { padding: clamp(80px, 13vh, 150px) var(--gutter); }

.tool__box {
  max-width: 860px;
  margin: 0 auto;
  padding: clamp(36px, 6vw, 72px);
  border: 1px solid rgba(25, 231, 225, .3);
  border-radius: 6px;
  background:
    linear-gradient(160deg, rgba(25, 231, 225, .05), transparent 50%),
    rgba(7, 27, 43, .85);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  text-align: center;
  position: relative;
}
.tool__box::before, .tool__box::after {
  content: "";
  position: absolute;
  width: 18px; height: 18px;
  border: 1.5px solid var(--cyan);
}
.tool__box::before { top: -1.5px; left: -1.5px; border-right: 0; border-bottom: 0; }
.tool__box::after { bottom: -1.5px; right: -1.5px; border-left: 0; border-top: 0; }

.tool__tag { font-size: 10px; letter-spacing: .26em; color: var(--cyan); margin-bottom: 22px; }
.tool__title {
  font-weight: 700;
  font-size: clamp(30px, 4.6vw, 56px);
  letter-spacing: -.03em;
  line-height: 1.05;
  text-transform: uppercase;
}
.tool__title span { color: var(--cyan); }
.tool__lede { margin: 20px auto 32px; color: var(--gris); max-width: 50ch; font-size: 16px; }

.tool__cta { margin-top: 4px; }

.tool__form {
  display: flex; flex-wrap: wrap; gap: 12px;
  max-width: 560px;
  margin: 0 auto;
}
.tool__input {
  flex: 1;
  min-width: 220px;
  background: rgba(11, 16, 21, .7);
  border: 1px solid var(--rule);
  border-radius: 2px;
  color: var(--blanc);
  font-size: 12.5px;
  letter-spacing: .1em;
  padding: 16px 18px;
  outline: none;
  transition: border-color .3s, box-shadow .3s;
}
.tool__input::placeholder { color: var(--gris); opacity: .6; }
.tool__input:focus { border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(25, 231, 225, .12); }

.tool__note { margin-top: 18px; font-size: 9.5px; letter-spacing: .24em; color: var(--gris); }
.tool__note.is-success { color: var(--cyan); }

/* ==========================================================================
   Footer
   ========================================================================== */

.footer {
  padding: clamp(70px, 12vh, 130px) var(--gutter) 40px;
  border-top: 1px solid var(--rule);
  background: linear-gradient(180deg, transparent, rgba(7, 27, 43, .8));
}

.footer__sig {
  font-weight: 700;
  font-size: clamp(56px, 11vw, 170px);
  line-height: .92;
  letter-spacing: -.04em;
  text-transform: uppercase;
  display: flex;
  flex-direction: column;
}
.footer__sig span:nth-child(2) { margin-left: clamp(24px, 8vw, 170px); }

.footer__slogan {
  margin: 26px 0 clamp(40px, 8vh, 80px);
  font-size: 11px;
  letter-spacing: .32em;
  text-transform: uppercase;
  color: var(--gris);
}

.footer__row {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px;
  font-size: 9.5px;
  letter-spacing: .2em;
  color: var(--gris);
  border-top: 1px solid var(--rule);
  padding-top: 24px;
}
.footer__nav { display: flex; gap: 20px; }
.footer__nav a { transition: color .3s; text-transform: uppercase; }
.footer__nav a:hover { color: var(--cyan); }

/* ==========================================================================
   Révélations
   ========================================================================== */

.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .85s var(--ease-out) var(--d, 0s), transform .85s var(--ease-out) var(--d, 0s);
}
.reveal.is-in { opacity: 1; transform: none; }

/* ==========================================================================
   Reduced motion
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001s !important;
    animation-delay: 0s !important;
    transition-duration: .001s !important;
  }
  .reveal { opacity: 1; transform: none; }
  .hero__row .w { transform: none; animation: none; }
  .marquee__track { animation: none; }
  .cursor { display: none; }
}
