/* ===== Thème The Node : noir profond et bleus du logo ===== */
:root {
  --bg: #07080b;
  --bg-2: #0b0d12;
  --surface: #10131a;
  --surface-2: #151a24;
  --line: rgba(110, 150, 230, .14);
  --line-strong: rgba(110, 150, 230, .32);
  --text: #e7e5e0;
  --muted: #9aa1ad;
  --blue: #2f6fe0;
  --blue-light: #6aa0f5;
  --brand: #004a9f;
  --radius: 14px;
  --radius-sm: 12px;
  --wrap: 1180px;
  --nav-h: 68px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--nav-h); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.6 "Poppins", system-ui, -apple-system, "Segoe UI", sans-serif;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { line-height: 1.2; margin: 0; letter-spacing: -.01em; }
p { margin: 0; }
:focus-visible { outline: 2px solid var(--blue-light); outline-offset: 3px; border-radius: 6px; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 16px; }
@media (min-width: 700px) { .wrap { padding: 0 28px; } }

.skip { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--blue); padding: 8px 14px; border-radius: 8px; }
.skip:focus { left: 8px; }

.ico { width: 1.25em; height: 1.25em; flex: none; }

/* ===== Boutons ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .6em;
  padding: .8em 1.4em; border-radius: 999px; border: 1px solid transparent;
  font-weight: 600; text-decoration: none; cursor: pointer;
  transition: transform .2s, box-shadow .2s, background .2s, border-color .2s;
}
.btn:hover { transform: translateY(-2px); }
.btn--primary {
  background: linear-gradient(135deg, var(--blue) 0%, var(--brand) 100%);
  box-shadow: 0 8px 28px -8px rgba(47, 111, 224, .65), inset 0 1px 0 rgba(255, 255, 255, .18);
  color: #fff;
}
.btn--primary:hover { box-shadow: 0 14px 40px -8px rgba(47, 111, 224, .85), inset 0 1px 0 rgba(255, 255, 255, .25); }
.btn--ghost { border-color: var(--line-strong); background: rgba(12, 15, 22, .55); backdrop-filter: blur(6px); }
.btn--ghost:hover { border-color: var(--blue-light); }
.btn--sm { padding: .55em 1.1em; font-size: .92rem; }
.btn--xl { padding: 1em 2.1em; font-size: 1.15rem; }
@media (min-width: 700px) { .btn--xl { font-size: 1.25rem; padding: 1.05em 2.4em; } }

/* ===== Navigation ===== */
.nav {
  position: fixed; inset: 0 0 auto; z-index: 50; height: var(--nav-h);
  transition: background .3s, border-color .3s;
  border-bottom: 1px solid transparent;
}
.nav.is-scrolled { background: rgba(7, 8, 11, .82); backdrop-filter: blur(12px); border-color: var(--line); }
.nav__inner { height: 100%; display: flex; align-items: center; gap: 24px; }
.nav__brand { display: flex; align-items: center; gap: 10px; font-weight: 700; text-decoration: none; font-size: 1.05rem; }
.nav__links { display: none; gap: 26px; margin-left: auto; }
.nav__links a { text-decoration: none; color: var(--muted); font-size: .95rem; transition: color .2s; }
.nav__links a:hover { color: var(--text); }
.nav .btn { margin-left: auto; }
@media (min-width: 900px) {
  .nav__links { display: flex; }
  .nav .btn { margin-left: 8px; }
}

/* ===== Accueil ===== */
.hero {
  position: relative; min-height: 100svh; display: grid; place-items: center;
  padding: calc(var(--nav-h) + 24px) 0 80px; text-align: center; isolation: isolate; overflow: hidden;
}
/* Seuil de 900px repris par les <link rel="preload"> de index.html */
.hero__bg {
  --hero-img: url("../img/fond-mobile.jpg");
  position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(ellipse 70% 55% at 50% 42%, rgba(18, 58, 122, .35), transparent 70%),
    linear-gradient(180deg, rgba(7, 8, 11, .55) 0%, rgba(7, 8, 11, .78) 60%, var(--bg) 100%),
    var(--hero-img) center / cover no-repeat;
}
@media (min-width: 900px) { .hero__bg { --hero-img: url("../img/fond.jpg"); } }
.hero__inner { max-width: 820px; padding: 0 16px; display: flex; flex-direction: column; align-items: center; }
.hero__logo {
  width: min(300px, 64vw); height: auto; margin-bottom: 8px;
  filter: drop-shadow(0 20px 50px rgba(0, 74, 159, .55));
  animation: float 7s ease-in-out infinite;
}
.hero__title { font-size: clamp(2rem, 6vw, 3.6rem); font-weight: 800; }
.hero__title span {
  background: linear-gradient(90deg, var(--blue-light), var(--blue));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero__lead { margin-top: 18px; color: #c9cdd4; font-size: clamp(1rem, 2.2vw, 1.15rem); max-width: 640px; }
.hero__cta { margin-top: 34px; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.hero__hint { margin-top: 18px; color: var(--muted); font-size: .9rem; }
.hero__scroll {
  position: absolute; bottom: 22px; left: 50%; translate: -50% 0;
  color: var(--muted); font-size: 1.6rem; animation: bob 2.2s ease-in-out infinite;
}
@keyframes float { 50% { transform: translateY(-10px); } }
@keyframes bob { 50% { transform: translateY(6px); } }

/* ===== Chiffres ===== */
.stats { border-block: 1px solid var(--line); background: var(--bg-2); }
.stats__grid { display: grid; grid-template-columns: repeat(3, 1fr); }
.stat + .stat { border-left: 1px solid var(--line); }
.stat { padding: 26px 8px; text-align: center; display: flex; flex-direction: column; gap: 2px; }
.stat strong { font-size: clamp(1.6rem, 4vw, 2.2rem); font-weight: 800; color: var(--blue-light); }
.stat span { color: var(--muted); font-size: .9rem; }
@media (max-width: 699px) { .stat span { font-size: .8rem; } }

/* ===== Sections ===== */
.section { padding: 88px 0; }
.section--alt { background: linear-gradient(180deg, var(--bg-2), var(--bg)); border-top: 1px solid var(--line); }
.section__head { max-width: 680px; margin: 0 auto 44px; text-align: center; }
.section__head h2 { font-size: clamp(1.7rem, 4.5vw, 2.6rem); font-weight: 800; }
.section__head p:not(.eyebrow) { margin-top: 14px; color: var(--muted); }
.eyebrow { color: var(--blue-light); font-weight: 600; font-size: .8rem; letter-spacing: .18em; text-transform: uppercase; margin-bottom: 10px; }

/* ===== Carte d'interconnexion ===== */
.network { display: grid; gap: 22px; align-items: start; }
@media (min-width: 900px) { .network { grid-template-columns: 1fr 1fr; gap: 40px; } }
.network__graph { max-width: 560px; width: 100%; margin: 0 auto; }
#network-svg { width: 100%; height: auto; overflow: visible; }
.net-edge { fill: none; stroke: var(--line-strong); stroke-width: 1.4; transition: stroke .25s, stroke-width .25s, opacity .25s; }
.net-edge.is-on { stroke: var(--blue-light); stroke-width: 2.4; stroke-dasharray: 7 6; animation: flow .9s linear infinite paused; }
#network-svg.is-visible .net-edge.is-on { animation-play-state: running; }
.net-edge.is-off { opacity: .18; }
@keyframes flow { to { stroke-dashoffset: -13; } }
.net-node { cursor: pointer; outline: none; }
.net-node circle { fill: var(--surface-2); stroke: var(--line-strong); stroke-width: 1.5; transition: fill .25s, stroke .25s; }
.net-node text { fill: var(--text); font: 600 17px "Poppins", sans-serif; text-anchor: middle; dominant-baseline: central; pointer-events: none; }
.net-node.is-on circle { fill: var(--brand); stroke: var(--blue-light); }
.net-node.is-near circle { stroke: var(--blue-light); }
.net-node.is-off { opacity: .45; }
.net-node:focus-visible circle { stroke: #fff; stroke-width: 2.5; }
.net-center { fill: var(--bg); stroke: var(--blue); stroke-width: 1.5; }

.network__panel {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; min-height: 260px;
}
.network__panel h3 { font-size: 1.3rem; display: flex; align-items: center; gap: 10px; }
.network__panel h3::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--blue-light); box-shadow: 0 0 12px var(--blue-light); }
.network__panel > p { color: var(--muted); margin-top: 8px; }
.network__panel ul { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 8px; align-content: start; }
.network__panel li { position: relative; padding: 9px 12px 9px 30px; border-radius: 10px; background: var(--bg-2); border: 1px solid var(--line); font-size: .93rem; }
.network__panel li::before { content: ""; position: absolute; left: 13px; top: 1.05em; width: 6px; height: 6px; border-radius: 50%; background: var(--blue-light); }

/* ===== Fonctionnalités ===== */
.chips { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-bottom: 40px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface); color: var(--muted); text-decoration: none; font-size: .88rem;
  transition: color .2s, border-color .2s;
}
.chip:hover { color: var(--text); border-color: var(--blue-light); }
.chip small { color: var(--blue-light); font-weight: 600; }

.cats { display: grid; gap: 56px; }
.cat__head { display: flex; gap: 16px; align-items: flex-start; margin-bottom: 20px; }
.cat__icon {
  flex: none; width: 48px; height: 48px; border-radius: var(--radius-sm); display: grid; place-items: center;
  background: linear-gradient(135deg, rgba(47, 111, 224, .22), rgba(0, 74, 159, .08)); border: 1px solid var(--line-strong);
  color: var(--blue-light);
}
.cat__icon svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.cat__head h3 { font-size: 1.35rem; }
.cat__head p { color: var(--muted); margin-top: 4px; font-size: .95rem; }
.cat__grid { display: grid; gap: 10px; grid-template-columns: 1fr; }
@media (min-width: 620px) { .cat__grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 980px) { .cat__grid { grid-template-columns: repeat(4, 1fr); } }
.feat {
  padding: 16px 16px 15px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--line);
  transition: border-color .2s, transform .2s, background .2s;
}
.feat:hover { border-color: var(--line-strong); background: var(--surface-2); transform: translateY(-2px); }
.feat h4 { margin: 0 0 4px; font-size: .98rem; font-weight: 600; }
.feat p { color: var(--muted); font-size: .87rem; line-height: 1.5; }

/* ===== Bandeau Discord ===== */
.cta {
  position: relative; padding: 96px 0; text-align: center; overflow: hidden;
  background:
    radial-gradient(ellipse 60% 80% at 50% 50%, rgba(47, 111, 224, .28), transparent 70%),
    linear-gradient(180deg, var(--bg), #08101f 50%, var(--bg));
  border-block: 1px solid var(--line);
}
.cta__inner { display: flex; flex-direction: column; align-items: center; gap: 18px; }
.cta__icon { width: 64px; height: 64px; color: var(--blue-light); filter: drop-shadow(0 0 24px rgba(106, 160, 245, .6)); }
.cta h2 { font-size: clamp(1.8rem, 5vw, 2.8rem); font-weight: 800; }
.cta p { color: #c9cdd4; max-width: 560px; }
.cta .btn { margin-top: 10px; }

/* ===== Galerie ===== */
.gallery { columns: 1; column-gap: 12px; }
@media (min-width: 620px) { .gallery { columns: 2; } }
@media (min-width: 980px) { .gallery { columns: 3; } }
.gallery__item {
  display: block; width: 100%; margin: 0 0 12px; padding: 0; border: 1px solid var(--line); border-radius: var(--radius-sm);
  overflow: hidden; background: var(--surface); cursor: zoom-in; break-inside: avoid;
}
.gallery__item img { width: 100%; height: auto; transition: transform .5s, filter .3s; }
.gallery__item:hover img { transform: scale(1.04); filter: brightness(1.08); }
.gallery-empty {
  max-width: 520px; margin: 0 auto; padding: 48px 24px; text-align: center; color: var(--muted);
  border: 1px dashed var(--line-strong); border-radius: var(--radius); background: var(--surface);
}
.gallery-empty .ico { width: 44px; height: 44px; color: var(--blue-light); margin: 0 auto 14px; display: block; }

.lightbox {
  width: 100vw; height: 100vh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0;
  background: rgba(4, 5, 8, .94); color: var(--text);
}
.lightbox[open] { display: grid; place-items: center; }
.lightbox::backdrop { background: rgba(0, 0, 0, .6); }
.lightbox__img { max-width: calc(100vw - 32px); max-height: calc(100vh - 110px); border-radius: 8px; object-fit: contain; }
.lightbox__btn {
  position: absolute; width: 46px; height: 46px; border-radius: 50%; border: 1px solid var(--line-strong);
  background: rgba(16, 19, 26, .8); color: var(--text); display: grid; place-items: center; cursor: pointer; font-size: 1.2rem;
}
.lightbox__btn:hover { border-color: var(--blue-light); }
.lightbox__close { top: 16px; right: 16px; }
.lightbox__prev { left: 16px; top: 50%; translate: 0 -50%; }
.lightbox__next { right: 16px; top: 50%; translate: 0 -50%; }
.lightbox__count { position: absolute; bottom: 18px; left: 0; right: 0; text-align: center; color: var(--muted); font-size: .9rem; }
@media (max-width: 699px) { .lightbox__prev, .lightbox__next { top: auto; bottom: 8px; translate: none; } }

/* ===== Nous suivre ===== */
.socials { display: flex; flex-wrap: wrap; justify-content: center; gap: 16px; }
.socials > .social { flex: 1 1 280px; max-width: 360px; }
.social {
  display: flex; align-items: center; gap: 16px; padding: 22px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--line); text-decoration: none;
  transition: border-color .2s, transform .2s, background .2s;
}
.social:hover { border-color: var(--blue-light); background: var(--surface-2); transform: translateY(-2px); }
.social__ico { width: 40px; height: 40px; flex: none; color: var(--blue-light); }
.social strong { display: block; font-size: 1.1rem; }
.social small { display: block; color: var(--muted); font-size: .88rem; line-height: 1.45; }

.vote {
  margin-top: 28px; padding: 24px; border-radius: var(--radius); border: 1px solid var(--line-strong);
  background: linear-gradient(120deg, rgba(18, 58, 122, .35), var(--surface) 60%);
  display: flex; flex-direction: column; gap: 18px; align-items: flex-start;
}
.vote h3 { font-size: 1.15rem; }
.vote p { color: var(--muted); margin-top: 6px; font-size: .95rem; max-width: 640px; }
@media (min-width: 700px) { .vote { flex-direction: row; align-items: center; justify-content: space-between; padding: 26px 30px; } }

/* ===== Pied de page ===== */
.footer { border-top: 1px solid var(--line); padding: 40px 0; background: var(--bg); }
.footer__inner { display: grid; gap: 20px; justify-items: center; text-align: center; }
.footer__brand { display: flex; align-items: center; gap: 12px; text-align: left; }
.footer__brand strong { display: block; }
.footer__brand span { color: var(--muted); font-size: .85rem; }
.footer__links { display: flex; flex-wrap: wrap; justify-content: center; gap: 22px; }
.footer__links a { color: var(--muted); text-decoration: none; font-size: .92rem; }
.footer__links a:hover { color: var(--text); }
.footer__legal { color: #6b717c; font-size: .8rem; max-width: 560px; }
@media (min-width: 900px) { .footer__inner { grid-template-columns: auto 1fr; text-align: left; justify-items: start; } .footer__links { justify-self: end; } .footer__legal { grid-column: 1 / -1; } }

/* ===== Apparition au défilement ===== */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
}
