/* ============================================================
   TÉLÉPATHIE — Feuille de styles
   Thème : ondes mentales / lecture des pensées
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400;600;900&family=Crimson+Pro:ital,wght@0,300;0,400;1,300;1,400&display=swap');

/* ── Variables ───────────────────────────────────────────── */
:root {
  --bg-deep:      #020408;
  --bg-mid:       #050d18;
  --bg-card:      rgba(6, 20, 40, 0.72);
  --border:       rgba(120, 200, 255, 0.12);
  --border-glow:  rgba(120, 200, 255, 0.38);
  --accent-1:     #38bdf8;   /* cyan vif */
  --accent-2:     #818cf8;   /* indigo pâle */
  --accent-3:     #e879f9;   /* fuchsia */
  --text-bright:  #e0f2fe;
  --text-dim:     #7dd3fc;
  --text-muted:   #475569;
  --glow-cyan:    0 0 24px rgba(56, 189, 248, 0.45);
  --glow-purple:  0 0 32px rgba(129, 140, 248, 0.35);
  --font-title:   'Cinzel', serif;
  --font-body:    'Crimson Pro', Georgia, serif;
}

/* ── Reset & base ────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background-color: var(--bg-deep);
  background-image:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(56,189,248,.10) 0%, transparent 70%),
    radial-gradient(ellipse 60% 40% at 80%  80%, rgba(129,140,248,.07) 0%, transparent 60%);
  color: var(--text-bright);
  font-family: var(--font-body);
  font-size: 1.1rem;
  font-weight: 300;
  line-height: 1.75;
  min-height: 100vh;
  overflow-x: hidden;
  cursor: none; /* curseur personnalisé via JS */
}

/* ── Curseur personnalisé ────────────────────────────────── */
#cursor {
  position: fixed;
  width: 12px; height: 12px;
  background: var(--accent-1);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: transform .1s, background .3s;
  box-shadow: 0 0 14px var(--accent-1), 0 0 40px rgba(56,189,248,.3);
  mix-blend-mode: screen;
}
#cursor-ring {
  position: fixed;
  width: 36px; height: 36px;
  border: 1px solid rgba(56,189,248,.5);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9998;
  transform: translate(-50%, -50%);
  transition: transform .18s ease-out, width .25s, height .25s, opacity .25s;
  opacity: .7;
}
body:hover #cursor-ring { opacity: .7; }

/* ── Canvas de fond ──────────────────────────────────────── */
#neural-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: .55;
}

/* ── Mise en page ────────────────────────────────────────── */
.wrap {
  position: relative;
  z-index: 1;
  max-width: 860px;
  margin: 0 auto;
  padding: 56px 28px 80px;
}

/* ── En-tête héroïque ────────────────────────────────────── */
.hero {
  text-align: center;
  margin-bottom: 64px;
  padding-bottom: 40px;
  border-bottom: 1px solid var(--border);
  position: relative;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -1px; left: 50%;
  transform: translateX(-50%);
  width: 120px; height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent-1), transparent);
  box-shadow: var(--glow-cyan);
}

.eye-wrapper {
  display: flex;
  justify-content: center;
  margin-bottom: 24px;
}

.eye {
  width: 72px; height: 38px;
  border: 2px solid var(--accent-1);
  border-radius: 50% / 100%;
  position: relative;
  box-shadow: var(--glow-cyan), inset 0 0 20px rgba(56,189,248,.1);
  animation: eyePulse 4s ease-in-out infinite;
}

.eye::before {            /* pupille */
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 22px; height: 22px;
  background: radial-gradient(circle, #ffffff22 0%, var(--accent-1) 45%, var(--bg-deep) 70%);
  border-radius: 50%;
  box-shadow: 0 0 12px var(--accent-1);
  animation: pupilMove 6s ease-in-out infinite;
}

.eye::after {             /* reflet */
  content: '';
  position: absolute;
  top: 6px; left: 20px;
  width: 7px; height: 7px;
  background: white;
  border-radius: 50%;
  opacity: .7;
}

@keyframes eyePulse {
  0%,100% { box-shadow: var(--glow-cyan), inset 0 0 20px rgba(56,189,248,.1); }
  50%      { box-shadow: 0 0 40px rgba(56,189,248,.7), inset 0 0 30px rgba(56,189,248,.2); }
}
@keyframes pupilMove {
  0%,100% { transform: translate(-50%,-50%) scale(1); }
  25%      { transform: translate(-60%,-50%) scale(.9); }
  75%      { transform: translate(-40%,-50%) scale(.9); }
}

h1 {
  font-family: var(--font-title);
  font-size: clamp(2.6rem, 6vw, 4.2rem);
  font-weight: 900;
  letter-spacing: .18em;
  text-transform: uppercase;
  background: linear-gradient(135deg, #e0f2fe 0%, var(--accent-1) 45%, var(--accent-2) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.1;
  animation: titleReveal .9s cubic-bezier(.22,1,.36,1) both;
}
@keyframes titleReveal {
  from { opacity:0; transform: translateY(30px) skewY(3deg); }
  to   { opacity:1; transform: none; }
}

.tagline {
  font-family: var(--font-body);
  font-style: italic;
  font-size: 1rem;
  letter-spacing: .35em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-top: 10px;
  opacity: 0;
  animation: fadeUp .7s .5s ease both;
}

/* ── Ondes mentales (EEG déco) ───────────────────────────── */
.brainwave {
  display: block;
  width: 100%;
  max-width: 420px;
  height: 40px;
  margin: 22px auto 0;
  opacity: .45;
}
.brainwave path {
  stroke: var(--accent-1);
  stroke-width: 1.5;
  fill: none;
  stroke-dasharray: 800;
  stroke-dashoffset: 800;
  animation: drawWave 2.5s 1s ease forwards, wavePulse 3s 3.5s ease-in-out infinite;
}
@keyframes drawWave {
  to { stroke-dashoffset: 0; }
}
@keyframes wavePulse {
  0%,100% { stroke: var(--accent-1); opacity:.45; }
  50%      { stroke: var(--accent-3); opacity:.8; }
}

/* ── Cartes ──────────────────────────────────────────────── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 28px 32px;
  margin: 22px 0;
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  opacity: 0;
  transform: translateY(22px);
  transition: border-color .35s, box-shadow .35s;
  animation: fadeUp .6s ease forwards;
}
.card:nth-child(1) { animation-delay: .15s; }
.card:nth-child(2) { animation-delay: .28s; }
.card:nth-child(3) { animation-delay: .41s; }
.card:nth-child(4) { animation-delay: .54s; }
.card:nth-child(5) { animation-delay: .67s; }

.card::before {           /* ligne de lumière gauche */
  content: '';
  position: absolute;
  left: 0; top: 15%; bottom: 15%;
  width: 2px;
  background: linear-gradient(to bottom, transparent, var(--accent-1), transparent);
  opacity: 0;
  transition: opacity .35s;
}
.card:hover {
  border-color: var(--border-glow);
  box-shadow: var(--glow-cyan);
}
.card:hover::before { opacity: 1; }

/* coin décoratif */
.card::after {
  content: '';
  position: absolute;
  top: 0; right: 0;
  width: 48px; height: 48px;
  border-top: 1px solid var(--border-glow);
  border-right: 1px solid var(--border-glow);
  border-radius: 0 16px 0 0;
  opacity: 0;
  transition: opacity .35s;
}
.card:hover::after { opacity: 1; }

@keyframes fadeUp {
  to { opacity:1; transform: none; }
}

/* ── Typographie cartes ──────────────────────────────────── */
h2 {
  font-family: var(--font-title);
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--accent-1);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}
h2::before {
  content: '';
  display: inline-block;
  width: 6px; height: 6px;
  background: var(--accent-1);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--accent-1);
  flex-shrink: 0;
}

p { color: var(--text-bright); margin-bottom: .6em; }
p:last-child { margin-bottom: 0; }

.note {
  font-style: italic;
  font-size: .95rem;
  color: var(--text-dim);
  padding: 10px 16px;
  border-left: 2px solid var(--accent-2);
  margin-top: 14px;
  background: rgba(129,140,248,.06);
  border-radius: 0 8px 8px 0;
}

ul {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
ul li {
  padding-left: 22px;
  position: relative;
  color: var(--text-bright);
  transition: color .2s, padding-left .2s;
}
ul li::before {
  content: '◈';
  position: absolute;
  left: 0;
  color: var(--accent-2);
  font-size: .7em;
  top: .25em;
  transition: color .2s;
}
ul li:hover { color: var(--accent-1); padding-left: 28px; }
ul li:hover::before { color: var(--accent-1); }

/* ── Toast "pensée captée" ───────────────────────────────── */
#thought-toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(80px);
  background: rgba(6,20,40,.9);
  border: 1px solid var(--border-glow);
  border-radius: 40px;
  padding: 10px 24px;
  font-family: var(--font-body);
  font-style: italic;
  font-size: .95rem;
  color: var(--accent-1);
  pointer-events: none;
  z-index: 8000;
  opacity: 0;
  transition: transform .45s cubic-bezier(.34,1.56,.64,1), opacity .45s;
  white-space: nowrap;
  box-shadow: var(--glow-cyan);
  backdrop-filter: blur(10px);
}
#thought-toast.visible {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

/* ── Barre de progression ondes ──────────────────────────── */
.wave-bar {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 28px;
  margin-top: 14px;
}
.wave-bar span {
  flex: 1;
  background: linear-gradient(to top, var(--accent-2), var(--accent-1));
  border-radius: 2px 2px 0 0;
  opacity: .6;
  animation: barDance 1.4s ease-in-out infinite;
}
.wave-bar span:nth-child(2) { animation-delay:.1s; }
.wave-bar span:nth-child(3) { animation-delay:.2s; }
.wave-bar span:nth-child(4) { animation-delay:.3s; }
.wave-bar span:nth-child(5) { animation-delay:.4s; }
.wave-bar span:nth-child(6) { animation-delay:.5s; }
.wave-bar span:nth-child(7) { animation-delay:.6s; }
.wave-bar span:nth-child(8) { animation-delay:.7s; }
.wave-bar span:nth-child(9) { animation-delay:.8s; }
.wave-bar span:nth-child(10){ animation-delay:.9s; }
@keyframes barDance {
  0%,100% { height: 20%; }
  50%      { height: 100%; }
}

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 600px) {
  .wrap  { padding: 36px 16px 60px; }
  .card  { padding: 20px 18px; }
  h1     { letter-spacing: .08em; }
  #thought-toast { font-size: .82rem; padding: 8px 18px; }
}
