/* ═══════════════════════════════════════════════════════════════════
   CapyCompare — maison-mère de la famille Capy
   Thème sombre, accents = les 4 couleurs de la famille + indigo hub
   ═══════════════════════════════════════════════════════════════════ */

@font-face {
  font-family: 'Nunito';
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url('../fonts/nunito-800.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --bg:        #070B18;
  --bg-2:      #0B1224;
  --surface:   rgba(255, 255, 255, 0.04);
  --border:    rgba(255, 255, 255, 0.09);
  --text:      #C6CDE2;
  --strong:    #F4F6FC;
  --muted:     #7C86A6;
  --indigo:    #6C5CE7;
  --teal:      #14B8A6;
  --lavender:  #8B93D8;
  --sky:       #0EA5E9;
  --orange:    #FF5A1F;
  --radius:    22px;
  --font-disp: 'Nunito', 'Segoe UI', system-ui, sans-serif;
  --font-body: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

::selection { background: rgba(108, 92, 231, .45); color: #fff; }

/* ── Fond aurora animé ─────────────────────────────────────────── */

.aurora {
  position: fixed; inset: 0; z-index: -2;
  overflow: hidden;
  background:
    radial-gradient(ellipse 90% 60% at 50% -10%, #131C3A 0%, transparent 60%),
    var(--bg);
}
.aurora__blob {
  position: absolute;
  width: 44vw; height: 44vw;
  min-width: 420px; min-height: 420px;
  border-radius: 50%;
  filter: blur(90px);
  opacity: .32;
  will-change: transform;
}
.aurora__blob--indigo { background: #4A3EC8; top: -12%; left: -8%;  animation: drift1 26s ease-in-out infinite alternate; }
.aurora__blob--teal   { background: #0E8577; top: 24%;  right: -14%; animation: drift2 32s ease-in-out infinite alternate; }
.aurora__blob--sky    { background: #0B6FA0; bottom: 8%; left: -10%; animation: drift3 29s ease-in-out infinite alternate; }
.aurora__blob--orange { background: #B23A0F; bottom: -18%; right: 4%; animation: drift1 36s ease-in-out infinite alternate-reverse; opacity: .22; }

@keyframes drift1 { to { transform: translate(9vw, 7vh) scale(1.15); } }
@keyframes drift2 { to { transform: translate(-7vw, -9vh) scale(1.2); } }
@keyframes drift3 { to { transform: translate(8vw, -6vh) scale(0.9); } }

.grain {
  position: fixed; inset: 0; z-index: -1;
  pointer-events: none;
  opacity: .5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.04 0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ── Typo commune ──────────────────────────────────────────────── */

.wordmark {
  font-family: var(--font-disp);
  font-weight: 800;
  font-size: 24px;
  letter-spacing: -.3px;
  white-space: nowrap;
}
.wordmark--lg { font-size: 30px; }
.wordmark__a { color: var(--strong); }
.wordmark__b {
  background: linear-gradient(100deg, var(--teal), var(--sky) 40%, var(--indigo) 75%, var(--orange));
  background-size: 260% 100%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  animation: gradShift 9s ease-in-out infinite alternate;
}

.grad {
  font-style: normal;
  background: linear-gradient(100deg, var(--teal), var(--sky) 38%, var(--indigo) 72%, var(--orange));
  background-size: 260% 100%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  animation: gradShift 9s ease-in-out infinite alternate;
}
@keyframes gradShift { to { background-position: 100% 0; } }

.eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 3.5px;
  text-transform: uppercase;
  color: var(--indigo);
  background: rgba(108, 92, 231, .12);
  border: 1px solid rgba(108, 92, 231, .3);
  border-radius: 100px;
  padding: 6px 16px;
  margin-bottom: 22px;
}

h1, h2, h3 { font-family: var(--font-disp); color: var(--strong); font-weight: 800; }

.section-head { text-align: center; max-width: 760px; margin: 0 auto 70px; padding: 0 24px; }
.section-head h2 { font-size: clamp(30px, 4.6vw, 48px); line-height: 1.15; margin-bottom: 16px; letter-spacing: -.5px; }
.section-head p { color: var(--muted); font-size: 18px; }

/* ── Boutons ───────────────────────────────────────────────────── */

.btn {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: var(--font-disp); font-weight: 800; font-size: 16px;
  padding: 14px 28px; border-radius: 100px;
  text-decoration: none;
  transition: transform .25s cubic-bezier(.2, .9, .3, 1.4), box-shadow .25s, background .25s, border-color .25s;
}
.btn:hover { transform: translateY(-3px); }
.btn:active { transform: translateY(-1px); }

.btn--primary {
  color: #fff;
  background: linear-gradient(115deg, var(--indigo), #4A9FE8);
  box-shadow: 0 8px 30px rgba(108, 92, 231, .38);
}
.btn--primary:hover { box-shadow: 0 14px 40px rgba(108, 92, 231, .55); }

.btn--ghost {
  color: var(--strong);
  border: 1px solid var(--border);
  background: var(--surface);
  backdrop-filter: blur(8px);
}
.btn--ghost:hover { border-color: rgba(255, 255, 255, .3); background: rgba(255, 255, 255, .08); }

.btn--site {
  color: #fff;
  background: linear-gradient(115deg, var(--accent), color-mix(in srgb, var(--accent) 60%, #000 12%));
  background: var(--accent);
  box-shadow: 0 8px 28px rgba(var(--accent-rgb), .35);
  margin-top: 28px;
}
.btn--site:hover { box-shadow: 0 14px 40px rgba(var(--accent-rgb), .55); }
.btn--site span { transition: transform .25s; }
.btn--site:hover span { transform: translateX(5px); }

/* ── Nav ───────────────────────────────────────────────────────── */

.nav {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; gap: 34px;
  padding: 14px clamp(20px, 4vw, 48px);
  background: rgba(7, 11, 24, .68);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(255, 255, 255, .06);
}
.nav__logo { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.nav__logo img { border-radius: 10px; }
.nav__links { display: flex; gap: 26px; margin-left: auto; }
.nav__links a {
  color: var(--text); text-decoration: none; font-weight: 600; font-size: 15.5px;
  position: relative; padding: 4px 0;
}
.nav__links a::after {
  content: ''; position: absolute; left: 0; bottom: 0; height: 2px; width: 0;
  background: linear-gradient(90deg, var(--teal), var(--indigo));
  border-radius: 2px; transition: width .3s;
}
.nav__links a:hover { color: var(--strong); }
.nav__links a:hover::after { width: 100%; }
.nav__cta { padding: 10px 20px; font-size: 14.5px; }

/* ── Hero ──────────────────────────────────────────────────────── */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  align-items: center;
  gap: clamp(30px, 5vw, 70px);
  max-width: 1240px;
  margin: 0 auto;
  padding: clamp(60px, 9vh, 110px) 24px 40px;
}
.hero__title {
  font-size: clamp(38px, 5.6vw, 66px);
  line-height: 1.06;
  letter-spacing: -1.5px;
  margin-bottom: 26px;
}
.hero__title span { display: block; }
.hero__sub { font-size: 18.5px; color: var(--text); max-width: 560px; margin-bottom: 34px; }
.hero__sub strong { color: var(--strong); }
.hero__cta { display: flex; gap: 16px; flex-wrap: wrap; }

.hero__art { position: relative; }
.hero__art::before {
  content: ''; position: absolute; inset: 8% -4% -2% -4%;
  background: radial-gradient(ellipse at 50% 60%, rgba(108, 92, 231, .28), transparent 65%);
  filter: blur(30px);
  z-index: -1;
}
.hero__art img {
  animation: floatY 7s ease-in-out infinite;
  filter: drop-shadow(0 30px 50px rgba(0, 0, 0, .5));
}
@keyframes floatY { 50% { transform: translateY(-14px); } }

.hero__stats {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  list-style: none;
  margin-top: clamp(30px, 6vh, 60px);
}
.hero__stats li {
  text-align: center;
  padding: 22px 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(8px);
  transition: transform .3s, border-color .3s;
}
.hero__stats li:hover { transform: translateY(-4px); border-color: rgba(108, 92, 231, .5); }
.stat {
  display: block;
  font-family: var(--font-disp); font-weight: 800;
  font-size: clamp(26px, 3vw, 38px);
  color: var(--strong);
  letter-spacing: -.5px;
}
.stat__label { font-size: 14px; color: var(--muted); }

/* ── Marquee ───────────────────────────────────────────────────── */

.marquee {
  overflow: hidden;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, .02);
  padding: 16px 0;
  margin: clamp(40px, 7vh, 70px) 0;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee__track {
  display: flex; align-items: center; gap: 34px;
  width: max-content;
  animation: marquee 34s linear infinite;
  font-family: var(--font-disp); font-weight: 800;
  font-size: 20px; color: var(--muted);
  white-space: nowrap;
}
.marquee__track i { font-style: normal; color: var(--indigo); font-size: 14px; }
.marquee:hover .marquee__track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ── La famille : vitrines ─────────────────────────────────────── */

.famille { padding: clamp(50px, 8vh, 90px) 0 20px; }

.show {
  display: grid;
  grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr);
  align-items: center;
  gap: clamp(34px, 5vw, 80px);
  max-width: 1280px;
  margin: 0 auto clamp(90px, 14vh, 150px);
  padding: 0 clamp(20px, 4vw, 48px);
}
.show--flip .show__text { order: 2; }
.show--flip .show__visual { order: 1; }

.show__num {
  font-family: var(--font-disp); font-weight: 800;
  font-size: 15px; letter-spacing: 4px;
  color: var(--accent);
  opacity: .85;
}
.show__brand { display: flex; align-items: center; gap: 14px; margin: 14px 0 20px; }
.show__brand img { filter: drop-shadow(0 6px 14px rgba(0, 0, 0, .4)); }

.show__text h3 {
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.2; letter-spacing: -.5px;
  margin-bottom: 16px;
}
.show__text > p { color: var(--text); margin-bottom: 20px; }
.show__text > p em { color: var(--strong); font-style: normal; font-weight: 600; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin-bottom: 22px; }
.chips li {
  font-size: 13.5px; font-weight: 700;
  color: var(--strong);
  padding: 6px 14px;
  border-radius: 100px;
  background: rgba(var(--accent-rgb), .13);
  border: 1px solid rgba(var(--accent-rgb), .35);
  transition: background .25s, transform .25s;
}
.chips li:hover { background: rgba(var(--accent-rgb), .28); transform: translateY(-2px); }

.show__feats { list-style: none; display: grid; gap: 10px; }
.show__feats li { padding-left: 28px; position: relative; color: var(--text); font-size: 15.5px; }
.show__feats li::before {
  content: '✓';
  position: absolute; left: 0; top: 0;
  width: 20px; height: 20px;
  display: grid; place-items: center;
  font-size: 12px; font-weight: 800;
  color: var(--accent);
  background: rgba(var(--accent-rgb), .15);
  border-radius: 50%;
}

/* Mockups navigateur + téléphone */

.show__visual { perspective: 1200px; }
.mock {
  position: relative;
  transform-style: preserve-3d;
  transition: transform .35s ease-out;
}
.mock::before {
  content: '';
  position: absolute; inset: 6% -6% -8% -6%;
  background: radial-gradient(ellipse at 50% 55%, rgba(var(--accent-rgb), .3), transparent 68%);
  filter: blur(36px);
  z-index: 0;
}

.mock__browser {
  position: relative; z-index: 1;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .12);
  box-shadow: 0 30px 70px rgba(0, 0, 0, .55);
  background: #10162B;
  transform: translateZ(0);
}
.mock__bar {
  display: flex; align-items: center; gap: 7px;
  padding: 10px 14px;
  background: linear-gradient(#1A2138, #141A2E);
  border-bottom: 1px solid rgba(255, 255, 255, .07);
}
.mock__bar i { width: 11px; height: 11px; border-radius: 50%; background: #3A4360; }
.mock__bar i:nth-child(1) { background: #E0655A; }
.mock__bar i:nth-child(2) { background: #E5B65A; }
.mock__bar i:nth-child(3) { background: #5BBE6B; }
.mock__bar span {
  margin: 0 auto;
  font-size: 12.5px; font-weight: 600;
  color: var(--muted);
  background: rgba(255, 255, 255, .06);
  padding: 3px 26px;
  border-radius: 7px;
}
.mock__browser img { width: 100%; }

.mock__phone {
  position: absolute; z-index: 2;
  right: -4%; bottom: -9%;
  width: 26%;
  border-radius: 22px;
  overflow: hidden;
  border: 4px solid #1B2340;
  box-shadow: 0 24px 55px rgba(0, 0, 0, .6);
  transform: translateZ(60px) rotate(3deg);
  background: #10162B;
}
.mock__phone::after {
  content: '';
  position: absolute; top: 7px; left: 50%;
  transform: translateX(-50%);
  width: 34%; height: 5px;
  background: #1B2340;
  border-radius: 100px;
}
.mock__phone img { width: 100%; }

/* ── Baru ──────────────────────────────────────────────────────── */

.baru { padding: clamp(60px, 10vh, 110px) 24px; }

.baru__values {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  max-width: 1100px;
  margin: 0 auto 70px;
}
.value {
  padding: 34px 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(8px);
  transition: transform .3s, border-color .3s, background .3s;
}
.value:hover {
  transform: translateY(-6px);
  border-color: rgba(108, 92, 231, .45);
  background: rgba(108, 92, 231, .07);
}
.value__icon { font-size: 34px; display: block; margin-bottom: 16px; }
.value h3 { font-size: 21px; margin-bottom: 10px; }
.value p { font-size: 15.5px; color: var(--muted); }

.baru__lineup {
  display: flex; justify-content: center; align-items: flex-end;
  gap: clamp(16px, 4vw, 54px);
  flex-wrap: wrap;
}
.baru__lineup figure { text-align: center; }
.baru__lineup img {
  height: clamp(110px, 14vw, 170px); width: auto;
  filter: drop-shadow(0 14px 26px rgba(0, 0, 0, .45));
  transition: transform .35s cubic-bezier(.2, .9, .3, 1.6);
}
.baru__lineup figure:hover img { transform: translateY(-12px) scale(1.06) rotate(-2deg); }
.baru__lineup figcaption {
  font-family: var(--font-disp); font-weight: 800;
  font-size: 15px; color: var(--muted);
  margin-top: 12px;
}

/* ── Le moteur ─────────────────────────────────────────────────── */

.moteur { padding: clamp(50px, 8vh, 90px) 24px; }
.moteur__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  max-width: 1180px;
  margin: 0 auto;
}
.feat {
  padding: 30px 26px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(8px);
  position: relative;
  overflow: hidden;
  transition: transform .3s, border-color .3s;
}
.feat::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, var(--teal), var(--sky), var(--indigo), var(--orange));
  opacity: 0; transition: opacity .3s;
}
.feat:hover { transform: translateY(-5px); border-color: rgba(255, 255, 255, .2); }
.feat:hover::before { opacity: 1; }
.feat__icon { font-size: 28px; display: block; margin-bottom: 14px; }
.feat h3 { font-size: 18.5px; margin-bottom: 9px; }
.feat p { font-size: 15px; color: var(--muted); }

/* ── La suite ──────────────────────────────────────────────────── */

.next { padding: clamp(40px, 7vh, 80px) 24px clamp(70px, 10vh, 110px); }
.next__card {
  max-width: 860px; margin: 0 auto;
  text-align: center;
  padding: clamp(40px, 6vw, 70px) 30px;
  border-radius: 28px;
  background:
    radial-gradient(ellipse at 20% 0%, rgba(20, 184, 166, .12), transparent 50%),
    radial-gradient(ellipse at 85% 100%, rgba(255, 90, 31, .1), transparent 50%),
    radial-gradient(ellipse at 60% 30%, rgba(108, 92, 231, .16), transparent 60%),
    var(--surface);
  border: 1px solid rgba(108, 92, 231, .3);
}
.next__card h2 { font-size: clamp(26px, 3.6vw, 40px); margin-bottom: 14px; }
.next__card p { color: var(--text); max-width: 520px; margin: 0 auto; }

/* ── Footer ────────────────────────────────────────────────────── */

.footer {
  border-top: 1px solid var(--border);
  padding: 50px 24px 40px;
  text-align: center;
  background: rgba(0, 0, 0, .25);
}
.footer__brand { display: flex; justify-content: center; align-items: center; gap: 12px; margin-bottom: 22px; }
.footer__brand img { border-radius: 9px; }
.footer__sites { display: flex; justify-content: center; flex-wrap: wrap; gap: 26px; margin-bottom: 26px; }
.footer__sites a {
  color: var(--text); text-decoration: none; font-weight: 700;
  font-family: var(--font-disp); font-size: 15.5px;
  transition: color .25s;
}
.footer__sites a:hover { color: var(--strong); }
.footer__note { max-width: 640px; margin: 0 auto 14px; font-size: 13.5px; color: var(--muted); }
.footer__copy { font-size: 13px; color: var(--muted); opacity: .7; }

/* ── Reveal au scroll ──────────────────────────────────────────── */

.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .7s ease, transform .7s cubic-bezier(.2, .7, .3, 1);
}
.reveal.is-in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: .1s; }
.reveal.d2 { transition-delay: .2s; }
.reveal.d3 { transition-delay: .3s; }
.reveal.d4 { transition-delay: .42s; }
.reveal.d5 { transition-delay: .55s; }

/* ── Responsive ────────────────────────────────────────────────── */

@media (max-width: 1020px) {
  .hero { grid-template-columns: 1fr; text-align: center; padding-top: 50px; }
  .hero__sub { margin-left: auto; margin-right: auto; }
  .hero__cta { justify-content: center; }
  .hero__art { max-width: 560px; margin: 0 auto; }
  .show { grid-template-columns: 1fr; gap: 40px; }
  .show--flip .show__text { order: 1; }
  .show--flip .show__visual { order: 2; }
  .baru__values, .moteur__grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 680px) {
  .nav__links { display: none; }
  .nav { gap: 12px; padding: 12px 16px; }
  .nav .wordmark { font-size: 19px; }
  .nav__cta { margin-left: auto; padding: 9px 14px; font-size: 13px; }
  .hero__stats { grid-template-columns: 1fr 1fr; }
  .baru__values, .moteur__grid { grid-template-columns: 1fr; }
  .mock__phone { right: 2%; }
  .wordmark--lg { font-size: 25px; }
}

/* ── Accessibilité : mouvement réduit ──────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .aurora__blob, .hero__art img, .marquee__track,
  .wordmark__b, .grad { animation: none !important; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .mock { transition: none; }
}
