/* ============================================
   ANIMATIONS.CSS — Daniel.AI
   Efectos globales compartidos por toda la web
   ============================================ */

/* ── STACKING: contenido siempre encima del fondo ── */
body > *:not(.mesh-bg):not(#particles-canvas):not(#scroll-progress) {
    position: relative;
    z-index: 1;
}

/* ── SCROLL PROGRESS BAR ── */
#scroll-progress {
    position: fixed;
    top: 0; left: 0;
    width: 0%;
    height: 3px;
    background: linear-gradient(90deg, #4f6ef7, #8b5cf6);
    z-index: 9999;
    box-shadow: 0 0 10px rgba(139,92,246,0.7);
    pointer-events: none;
}

.mesh-bg { display: none; }

/* ── PARTICLES ── */
#particles-canvas { display: none; }

/* ── MOUSE SPOTLIGHT ── */
.srv-card, .met-card, .rev-card, .ig-card, .sobre-card,
.con-form, .lm-box, .faq-item, .con-item, .incluye-item,
.pilar, .area-card, .art-card, .card, .compare-item,
.cta-box, .info-box, .metric-card, .plan-card, .score-box,
.problema-card, .quien-card, .res-card, .tipo-card,
.tl-item, .step-item, .ba-card, .featured {
    --mx: 50%;
    --my: 50%;
}
.mouse-lit::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: radial-gradient(
        280px circle at var(--mx) var(--my),
        rgba(99, 130, 255, 0.10) 0%,
        rgba(139, 92, 246, 0.06) 40%,
        transparent 70%
    );
    pointer-events: none;
    z-index: 1;
    transition: opacity 0.15s ease;
}

/* ── NAV UNDERLINE ── */
.nav-links a {
    position: relative;
}
.nav-links a::after {
    content: '';
    position: absolute;
    left: 0; bottom: -3px;
    width: 100%; height: 1.5px;
    background: linear-gradient(90deg, #4f6ef7, #8b5cf6);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.28s cubic-bezier(.22,.61,.36,1);
    border-radius: 2px;
}
.nav-links a:hover::after { transform: scaleX(1); }
.nav-cta::after { display: none !important; }

/* ── LOGO WIGGLE ── */
.nav-logo { display: inline-block; }
.nav-logo:hover {
    animation: logo-wiggle 0.4s cubic-bezier(.36,.07,.19,.97);
}
@keyframes logo-wiggle {
    0%   { transform: rotate(0deg)    translateX(0); }
    20%  { transform: rotate(-2deg)   translateX(-2px); }
    40%  { transform: rotate(2deg)    translateX(2px); }
    60%  { transform: rotate(-1.5deg) translateX(-1px); }
    80%  { transform: rotate(1deg)    translateX(1px); }
    100% { transform: rotate(0deg)    translateX(0); }
}

/* ── TYPEWRITER CURSOR ── */
.type-cursor {
    display: inline-block;
    width: 8px;
    color: #4f6ef7;
    font-weight: 300;
    animation: cursor-blink 0.75s step-end infinite;
    margin-left: 1px;
    vertical-align: middle;
}
@keyframes cursor-blink {
    0%, 100% { opacity: 1; }
    50%       { opacity: 0; }
}

/* ── RIPPLE ── */
.ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255,255,255,0.3);
    transform: scale(0);
    animation: ripple-expand 0.55s cubic-bezier(.22,.61,.36,1) forwards;
    pointer-events: none;
}
@keyframes ripple-expand {
    to { transform: scale(4); opacity: 0; }
}

/* ── FLOATING LABELS ── */
.fg.fl { position: relative; margin-top: 8px; }
.fg.fl label {
    position: absolute;
    left: 15px; top: 11px;
    font-size: 0.875rem;
    text-transform: none;
    letter-spacing: 0;
    color: #7878a8;
    pointer-events: none;
    transition: top 0.22s cubic-bezier(.22,.61,.36,1),
                font-size 0.22s cubic-bezier(.22,.61,.36,1),
                color 0.22s ease,
                letter-spacing 0.22s ease;
    margin: 0;
    background: transparent;
}
.fg.fl input, .fg.fl textarea {
    padding-top: 18px;
    padding-bottom: 6px;
}
.fg.fl.active label,
.fg.fl.filled label {
    top: 4px;
    font-size: 0.62rem;
    color: #4f6ef7;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}
