/* Echmun — effets : particules, grain, halos, cartes */

:root {
  --void: #040b10;
  --void-mid: #0a1620;
  --navy: #0a2e4d;
  --teal: #26a69a;
  --teal-bright: #40e0d0;
  --text: #e8f0f4;
  --muted: #8aa3b3;
  --line: rgba(38, 166, 154, 0.18);
  --measure: 32rem;
  --side: min(92vw, 42rem);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .fx-canvas,
  .fx-noise,
  .fx-gradient,
  .hero__glow,
  .hero__grid {
    animation: none !important;
  }

  .js [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
  }
}

body {
  margin: 0;
  font-family: "Inter", system-ui, sans-serif;
  font-size: 0.9375rem;
  font-weight: 400;
  line-height: 1.6;
  color: var(--text);
  background: var(--void);
  min-height: 100vh;
}

/* Calques d’ambiance */

.fx-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0.5;
}

.fx-noise {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.04;
  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='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}

.fx-gradient {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(38, 166, 154, 0.12), transparent 55%),
    radial-gradient(ellipse 60% 40% at 100% 50%, rgba(10, 46, 77, 0.45), transparent 50%),
    radial-gradient(ellipse 50% 35% at 0% 80%, rgba(64, 224, 208, 0.06), transparent 45%);
}

.skip {
  position: absolute;
  left: -99rem;
  top: 0.5rem;
  padding: 0.35rem 0.75rem;
  background: var(--teal);
  color: var(--void);
  text-decoration: none;
  font-size: 0.8125rem;
  font-weight: 600;
  border-radius: 4px;
  z-index: 100;
}

.skip:focus {
  left: 0.5rem;
}

.top,
main,
.foot {
  position: relative;
  z-index: 2;
}

/* Header */

.top {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(4, 11, 16, 0.82);
  backdrop-filter: blur(14px) saturate(1.2);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 4px 32px rgba(0, 0, 0, 0.35);
}

.top__bar {
  position: relative;
  max-width: var(--side);
  margin: 0 auto;
  padding: 0.65rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.top__brand img {
  height: 36px;
  width: auto;
  display: block;
  filter: drop-shadow(0 0 12px rgba(38, 166, 154, 0.25));
}

.top__toggle {
  display: none;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(10, 22, 32, 0.9);
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.top__toggle span {
  display: block;
  width: 16px;
  height: 1.5px;
  background: var(--text);
  border-radius: 1px;
}

.top__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  align-items: center;
}

.top__nav a {
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s ease, text-shadow 0.2s ease;
}

.top__nav a:hover {
  color: var(--teal-bright);
  text-shadow: 0 0 20px rgba(64, 224, 208, 0.25);
}

@media (max-width: 560px) {
  .top__toggle {
    display: flex;
  }

  .top__nav {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    padding: 0.75rem 1rem;
    margin: 0;
    background: rgba(6, 14, 22, 0.98);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    display: none;
  }

  .top__nav.is-open {
    display: flex;
  }

  .top__nav a {
    padding: 0.5rem 0;
  }
}

/* Hero */

.hero {
  position: relative;
  padding: clamp(2.5rem, 12vw, 5rem) 1.25rem clamp(3rem, 14vw, 6rem);
  overflow: hidden;
}

.hero__glow {
  position: absolute;
  inset: -30% -20% auto -20%;
  height: 85%;
  background: radial-gradient(ellipse 55% 45% at 50% 0%, rgba(38, 166, 154, 0.2), transparent 60%);
  filter: blur(2px);
  animation: glow-drift 18s ease-in-out infinite alternate;
  pointer-events: none;
}

@keyframes glow-drift {
  0% {
    opacity: 1;
    transform: scale(1) translate(0, 0);
  }
  100% {
    opacity: 0.85;
    transform: scale(1.05) translate(2%, 1%);
  }
}

.hero__grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(38, 166, 154, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(38, 166, 154, 0.05) 1px, transparent 1px);
  background-size: 40px 40px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 35%, black 15%, transparent 70%);
  pointer-events: none;
}

.hero__content {
  position: relative;
  max-width: var(--measure);
  margin: 0 auto;
  text-align: center;
}

.hero__mark {
  width: min(100px, 28vw);
  height: auto;
  margin: 0 auto 1.75rem;
  display: block;
  filter: drop-shadow(0 8px 32px rgba(38, 166, 154, 0.35));
  animation: logo-float 6s ease-in-out infinite;
}

@keyframes logo-float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-4px);
  }
}

.hero__title {
  margin: 0 0 0.65rem;
  font-family: "Outfit", system-ui, sans-serif;
  font-size: clamp(1.35rem, 4.2vw, 1.95rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.25;
  color: #fff;
  text-shadow: 0 0 40px rgba(38, 166, 154, 0.15);
}

.hero__line {
  margin: 0 0 1.75rem;
  font-size: 0.9375rem;
  color: var(--muted);
}

.hero__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.65rem 1.5rem;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--void);
  background: linear-gradient(135deg, var(--teal-bright), var(--teal));
  border: none;
  border-radius: 999px;
  box-shadow: 0 0 0 1px rgba(64, 224, 208, 0.35), 0 8px 28px rgba(38, 166, 154, 0.35);
  transition: transform 0.2s var(--ease), box-shadow 0.2s ease;
}

.hero__cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 0 1px rgba(64, 224, 208, 0.5), 0 12px 36px rgba(38, 166, 154, 0.45);
}

/* Blocs */

.block {
  padding: clamp(2rem, 8vw, 3.5rem) 1.25rem;
  border-top: 1px solid var(--line);
  background: rgba(8, 18, 28, 0.55);
  backdrop-filter: blur(8px);
}

.block--spread {
  padding-bottom: clamp(2.5rem, 10vw, 4rem);
}

.block__text {
  max-width: var(--measure);
  margin: 0 auto;
  color: var(--muted);
  font-size: 0.9375rem;
}

.block__text strong {
  color: var(--text);
  font-weight: 600;
}

.block__text--tight {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--line);
}

.block__text--muted {
  margin-top: 1.25rem;
  font-size: 0.875rem;
  opacity: 0.95;
}

/* Cartes avec halo souris (shine géré en JS via variables) */

.cols {
  display: grid;
  gap: 1.25rem;
  max-width: 36rem;
  margin: 0 auto;
}

@media (min-width: 620px) {
  .cols {
    grid-template-columns: repeat(3, 1fr);
    max-width: none;
    width: min(100%, 44rem);
  }
}

.fx-card {
  position: relative;
  padding: 1.35rem 1.15rem;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(10, 30, 45, 0.5);
  overflow: hidden;
  transition: transform 0.35s var(--ease), border-color 0.35s ease, box-shadow 0.35s ease;
}

.fx-card__shine {
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle 120px at var(--sx, 50%) var(--sy, 50%),
    rgba(64, 224, 208, 0.12),
    transparent 65%
  );
  opacity: 0;
  transition: opacity 0.35s ease;
  pointer-events: none;
}

.fx-card:hover {
  transform: translateY(-3px);
  border-color: rgba(38, 166, 154, 0.45);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35), 0 0 30px rgba(38, 166, 154, 0.08);
}

.fx-card:hover .fx-card__shine {
  opacity: 1;
}

.cols__label {
  position: relative;
  margin: 0 0 0.35rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--teal-bright);
  letter-spacing: 0.02em;
}

.cols__hint {
  position: relative;
  margin: 0;
  font-size: 0.8125rem;
  color: var(--muted);
  line-height: 1.5;
}

/* Contact */

.block--end {
  text-align: center;
  padding-bottom: clamp(3rem, 12vw, 5rem);
}

.block__mail {
  margin: 0 0 0.5rem;
  font-size: 1.0625rem;
  font-weight: 500;
}

.block__mail a {
  color: var(--teal-bright);
  text-decoration: none;
  text-shadow: 0 0 24px rgba(64, 224, 208, 0.2);
}

.block__mail a:hover {
  text-decoration: underline;
}

/* Footer */

.foot {
  padding: 1.25rem 1.25rem 2rem;
  text-align: center;
  border-top: 1px solid var(--line);
  background: rgba(2, 8, 14, 0.9);
}

.foot p {
  margin: 0;
  font-size: 0.75rem;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.foot__domain {
  opacity: 0.9;
}

/* Révélation au scroll */

.js [data-reveal] {
  opacity: 0;
  transform: translateY(22px);
  filter: blur(4px);
  transition:
    opacity 0.65s var(--ease),
    transform 0.7s var(--ease),
    filter 0.6s ease;
}

.js [data-reveal].is-inview {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

@media (prefers-reduced-motion: reduce) {
  .hero__mark {
    animation: none;
  }
}
