/* ============================================================
   portaz-animations.css  |  Theme: Dark Command
   All motion and keyframe definitions for PORTAZ landing page
   ============================================================ */

/* ── Page Load: Fade Up ── */
.fade-up {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.55s ease, transform 0.55s ease;
}
.fade-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered delay helpers */
.fade-up-delay   { transition-delay: 0.18s; }
.fade-up-delay-2 { transition-delay: 0.34s; }
.fade-up-delay-3 { transition-delay: 0.50s; }

/* ── Eyebrow Dot Pulse ── */
@keyframes pulse-dot {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(14, 165, 233, 0.5);
        opacity: 1;
    }
    50% {
        box-shadow: 0 0 0 6px rgba(14, 165, 233, 0);
        opacity: 0.75;
    }
}

/* ── Map Node Ping ── */
@keyframes node-ping {
    0% {
        box-shadow: 0 0 0 0 rgba(14, 165, 233, 0.5);
    }
    70% {
        box-shadow: 0 0 0 8px rgba(14, 165, 233, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(14, 165, 233, 0);
    }
}
.node-active {
    animation: node-ping 2.2s ease-out infinite;
}
.node-warn {
    animation: node-ping 2.2s ease-out infinite;
    animation-name: node-ping-amber;
}
@keyframes node-ping-amber {
    0%  { box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.55); }
    70% { box-shadow: 0 0 0 8px rgba(245, 158, 11, 0); }
    100%{ box-shadow: 0 0 0 0 rgba(245, 158, 11, 0); }
}

/* ── Nav Accent Line Shimmer ── */
@keyframes nav-shimmer {
    0%   { background-position: -100% 0; }
    100% { background-position: 200% 0; }
}
.nav-accent-line {
    background: linear-gradient(
        90deg,
        transparent 0%,
        var(--cyan) 40%,
        #38BEF8 50%,
        var(--cyan) 60%,
        transparent 100%
    );
    background-size: 200% 100%;
    animation: nav-shimmer 4s linear infinite;
    opacity: 0.45;
}

/* ── Hero Grid Slow Drift ── */
@keyframes grid-drift {
    0%   { transform: translate(0, 0); }
    100% { transform: translate(72px, 72px); }
}
.hero-grid-overlay {
    animation: grid-drift 24s linear infinite;
    will-change: transform;
}

/* ── Hero Glow Breathe ── */
@keyframes glow-breathe {
    0%, 100% { opacity: 0.6; transform: scale(1); }
    50%       { opacity: 1;   transform: scale(1.08); }
}
.hero-glow {
    animation: glow-breathe 6s ease-in-out infinite;
}

/* ── CTA Glow Breathe ── */
.cta-bg-glow {
    animation: glow-breathe 5s ease-in-out infinite;
}

/* ── Stat Card Entrance ── */
@keyframes slide-in-right {
    from {
        opacity: 0;
        transform: translateX(24px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}
.hero-dashboard .dashboard-card:nth-child(1) { animation: slide-in-right 0.5s ease 0.3s both; }
.hero-dashboard .dashboard-card:nth-child(2) { animation: slide-in-right 0.5s ease 0.5s both; }
.hero-dashboard .dashboard-card:nth-child(3) { animation: slide-in-right 0.5s ease 0.7s both; }

/* ── Button Hover Glow ── */
.btn-primary {
    position: relative;
    overflow: hidden;
}
.btn-primary::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, transparent 30%, rgba(255,255,255,0.12) 50%, transparent 70%);
    transform: translateX(-100%);
    transition: transform 0.45s ease;
}
.btn-primary:hover::after {
    transform: translateX(100%);
}

/* ── Card Hover Top Accent ── */
.card::before {
    transition: opacity 0.25s ease;
}

/* ── Feature Card Icon Bounce ── */
@keyframes icon-bounce {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-4px); }
}
.feature-card:hover .feature-icon {
    animation: icon-bounce 0.5s ease;
}

/* ── Outcome Icon Spin-in ── */
@keyframes spin-in {
    from { transform: rotate(-30deg) scale(0.8); opacity: 0; }
    to   { transform: rotate(0deg)  scale(1);   opacity: 1; }
}
.outcome-item:hover .outcome-icon i {
    animation: spin-in 0.35s ease;
}

/* ── FAQ Arrow Slide ── */
.faq li a .faq-arrow {
    transition: transform 0.2s ease, color 0.2s ease;
}
.faq li a:hover .faq-arrow {
    transform: translateX(5px);
    color: var(--cyan);
}

/* ── Map Line Draw (SVG stroke animation) ── */
@keyframes line-draw {
    from { stroke-dashoffset: 200; }
    to   { stroke-dashoffset: 0; }
}
.map-lines line {
    stroke-dasharray: 200;
    animation: line-draw 1.5s ease forwards;
}
.map-lines line:nth-child(1) { animation-delay: 0.8s; }
.map-lines line:nth-child(2) { animation-delay: 1.0s; }
.map-lines line:nth-child(3) { animation-delay: 1.2s; }
.map-lines line:nth-child(4) { animation-delay: 1.4s; }
.map-lines line:nth-child(5) { animation-delay: 1.6s; }

/* ── Why / Pillar items stagger ── */
.why-item:nth-child(1) { transition-delay: 0.05s; }
.why-item:nth-child(2) { transition-delay: 0.10s; }
.why-item:nth-child(3) { transition-delay: 0.15s; }
.why-item:nth-child(4) { transition-delay: 0.20s; }
.why-item:nth-child(5) { transition-delay: 0.25s; }

/* ── Reduced Motion Overrides ── */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    .fade-up { opacity: 1; transform: none; }
}
