/* ═══════════════════════════════════════════════════════════
   LearnLogic Studio — effects.css
   Effets visuels communs à toutes les pages
   ═══════════════════════════════════════════════════════════ */

/* ── Radial glow body — lueur subtile en haut de page ── */
body.fx-loaded::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(1100px 500px at 50% -5%, rgba(13,110,253,.07), transparent 60%),
    radial-gradient(800px 400px at 90% 15%, rgba(139,92,246,.05), transparent 60%);
}

/* ── Grid bg avec mask élégant ── */
.grid-bg-mask {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(13,110,253,.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(13,110,253,.028) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse at 50% 0%, black 30%, transparent 72%);
  -webkit-mask-image: radial-gradient(ellipse at 50% 0%, black 30%, transparent 72%);
}

/* ── Dot pulsant ── */
.dot-pulse {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--ac2, #00d4aa);
  box-shadow: 0 0 0 4px rgba(0,212,170,.12), 0 0 12px rgba(0,212,170,.7);
  animation: dotPulse 2.2s ease-in-out infinite;
  flex-shrink: 0;
}
@keyframes dotPulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 4px rgba(0,212,170,.12), 0 0 12px rgba(0,212,170,.7); }
  50%       { opacity: .55; box-shadow: 0 0 0 6px rgba(0,212,170,.06), 0 0 6px rgba(0,212,170,.3); }
}

/* ── Pill avec dot ── */
.fx-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.1);
  background: rgba(255,255,255,.02);
  backdrop-filter: blur(8px);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--mu2, #94a3b8);
}

/* ── Ring glow au hover ── */
.ring-glow {
  transition: box-shadow .35s ease, border-color .35s ease, transform .35s ease;
}
.ring-glow:hover {
  box-shadow: 0 0 0 1px rgba(0,212,170,.35), 0 20px 60px -20px rgba(0,212,170,.3);
  border-color: rgba(0,212,170,.3) !important;
  transform: translateY(-2px);
}

/* ── Shine au hover sur les cartes ── */
.shine-wrap {
  position: relative;
  overflow: hidden;
}
.shine-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent 20%, rgba(255,255,255,.07) 50%, transparent 80%);
  transform: translateX(-120%);
  transition: transform .8s ease;
  pointer-events: none;
  z-index: 1;
}
.shine-wrap:hover::after {
  transform: translateX(120%);
}
.shine-wrap .shine-img {
  transition: transform .8s cubic-bezier(.2,.7,.2,1);
}
.shine-wrap:hover .shine-img {
  transform: scale(1.04);
}

/* ── Underline grow sur les liens ── */
.underline-grow {
  position: relative;
}
.underline-grow::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -3px;
  height: 1px;
  width: 100%;
  background: linear-gradient(90deg, var(--ac2, #00d4aa), transparent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .35s ease;
}
.underline-grow:hover::after {
  transform: scaleX(1);
}

/* ── H-rule — ligne lumineuse ── */
.h-rule {
  height: 1px;
  border: none;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.15), transparent);
  margin: 0;
}

/* ── Card gradient subtil ── */
.card-fx {
  background: linear-gradient(180deg, rgba(255,255,255,.025), rgba(255,255,255,.01));
  transition: background .35s ease, border-color .35s ease, transform .35s ease, box-shadow .35s ease;
}
.card-fx:hover {
  background: linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,.015));
}

/* ── Btn primary premium ── */
.btn-fx-primary {
  box-shadow: 0 1px 0 rgba(255,255,255,.15) inset, 0 12px 30px -12px rgba(0,212,170,.4);
  transition: transform .25s ease, box-shadow .25s ease;
}
.btn-fx-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 1px 0 rgba(255,255,255,.2) inset, 0 20px 50px -16px rgba(0,212,170,.6);
}

/* ── Reveal scroll animation ── */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .6s ease, transform .6s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}
.reveal-d1 { transition-delay: .1s; }
.reveal-d2 { transition-delay: .2s; }
.reveal-d3 { transition-delay: .3s; }
.reveal-d4 { transition-delay: .4s; }

/* ── Nombre animé (compteur) ── */
@keyframes countUp {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}
.count-fx {
  animation: countUp .5s ease forwards;
}

/* ── Light mode overrides ── */
body.light-mode .dot-pulse {
  box-shadow: 0 0 0 4px rgba(0,212,170,.15), 0 0 10px rgba(0,212,170,.5);
}
body.light-mode .fx-pill {
  border-color: rgba(0,0,0,.08);
  background: rgba(0,0,0,.02);
  color: var(--mu, #64748b);
}
body.light-mode .h-rule {
  background: linear-gradient(90deg, transparent, rgba(0,0,0,.1), transparent);
}
body.light-mode .shine-wrap::after {
  background: linear-gradient(120deg, transparent 20%, rgba(255,255,255,.4) 50%, transparent 80%);
}
body.light-mode .ring-glow:hover {
  box-shadow: 0 0 0 1px rgba(0,212,170,.25), 0 12px 40px -16px rgba(0,212,170,.2);
}
