/* ═══════════════════════════════════════════════════════
   VIRALIX Landing Page — Premium Enhancements
   Micro-animations, Marquee, Scroll Reveal, Counters
   ═══════════════════════════════════════════════════════ */

/* ─── SCROLL REVEAL BASE ─── */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: opacity, transform;
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-60px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: opacity, transform;
}

.reveal-left.revealed {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(60px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: opacity, transform;
}

.reveal-right.revealed {
    opacity: 1;
    transform: translateX(0);
}

.reveal-scale {
    opacity: 0;
    transform: scale(0.85);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: opacity, transform;
}

.reveal-scale.revealed {
    opacity: 1;
    transform: scale(1);
}

/* Staggered children */
.reveal-stagger > * {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-stagger.revealed > *:nth-child(1) { transition-delay: 0.05s; }
.reveal-stagger.revealed > *:nth-child(2) { transition-delay: 0.15s; }
.reveal-stagger.revealed > *:nth-child(3) { transition-delay: 0.25s; }
.reveal-stagger.revealed > *:nth-child(4) { transition-delay: 0.35s; }
.reveal-stagger.revealed > *:nth-child(5) { transition-delay: 0.45s; }
.reveal-stagger.revealed > *:nth-child(6) { transition-delay: 0.55s; }

.reveal-stagger.revealed > * {
    opacity: 1;
    transform: translateY(0);
}

/* ─── INTEGRATION LOGOS MARQUEE ─── */
.integrations-section {
    padding: 48px 0 56px;
    overflow: hidden;
    position: relative;
}

.integrations-section .section-label {
    text-align: center;
    text-transform: uppercase;
    font-size: 0.72rem;
    letter-spacing: 3.5px;
    color: var(--text-secondary, #888);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    font-weight: 600;
}

.integrations-section .section-label::before,
.integrations-section .section-label::after {
    content: '';
    width: 60px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(0,242,234,0.3), transparent);
}

.marquee-track {
    display: flex;
    width: max-content;
    animation: marquee-scroll 35s linear infinite;
}

.marquee-track:hover {
    animation-play-state: paused;
}

.marquee-set {
    display: flex;
    align-items: center;
    gap: 48px;
    padding: 0 24px;
}

.marquee-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 24px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    white-space: nowrap;
    flex-shrink: 0;
    transition: all 0.3s ease;
    cursor: default;
}

.marquee-item:hover {
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(0, 242, 234, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 242, 234, 0.08);
}

.marquee-item i {
    font-size: 1.5rem;
    width: 28px;
    text-align: center;
}

.marquee-item .brand-meta { color: #1877F2; }
.marquee-item .brand-instagram {
    background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.marquee-item .brand-tiktok { color: #fff; }
.marquee-item .brand-openai { color: #10a37f; }
.marquee-item .brand-google { color: #4285F4; }
.marquee-item .brand-canva { color: #00C4CC; }
.marquee-item .brand-whatsapp { color: #25D366; }
.marquee-item .brand-youtube { color: #FF0000; }

.marquee-item span {
    font-size: 0.85rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.65);
    letter-spacing: 0.3px;
}

.marquee-item:hover span {
    color: rgba(255, 255, 255, 0.9);
}

/* Marquee edge fade */
.integrations-section::before,
.integrations-section::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    width: 120px;
    z-index: 2;
    pointer-events: none;
}

.integrations-section::before {
    left: 0;
    background: linear-gradient(90deg, var(--bg-primary, #030308) 0%, transparent 100%);
}

.integrations-section::after {
    right: 0;
    background: linear-gradient(-90deg, var(--bg-primary, #030308) 0%, transparent 100%);
}

@keyframes marquee-scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* ─── ENHANCED CARD HOVER EFFECTS ─── */
.step-card,
.testi-card,
.compare-box,
.faq-item {
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
                box-shadow 0.35s ease,
                border-color 0.35s ease !important;
}

.step-card:hover {
    transform: translateY(-6px) !important;
    box-shadow: 0 20px 60px rgba(0, 242, 234, 0.08),
                0 0 0 1px rgba(0, 242, 234, 0.15) !important;
}

.testi-card:hover {
    transform: translateY(-4px) !important;
    box-shadow: 0 16px 48px rgba(138, 79, 255, 0.1),
                0 0 0 1px rgba(138, 79, 255, 0.12) !important;
}

.compare-box:hover {
    transform: translateY(-4px) !important;
}

.compare-box.good:hover {
    box-shadow: 0 20px 60px rgba(0, 242, 234, 0.12),
                0 0 0 1px rgba(0, 242, 234, 0.2) !important;
}

.compare-box.bad:hover {
    box-shadow: 0 20px 60px rgba(255, 80, 80, 0.08),
                0 0 0 1px rgba(255, 80, 80, 0.15) !important;
}

/* ─── HERO ENHANCED ENTRANCE ─── */
@keyframes hero-fade-up {
    0% { opacity: 0; transform: translateY(30px); }
    100% { opacity: 1; transform: translateY(0); }
}

@keyframes hero-fade-right {
    0% { opacity: 0; transform: translateX(40px) scale(0.96); }
    100% { opacity: 1; transform: translateX(0) scale(1); }
}

@keyframes hero-badge-pop {
    0% { opacity: 0; transform: scale(0.7); }
    60% { transform: scale(1.05); }
    100% { opacity: 1; transform: scale(1); }
}

body.landing-public .hero-v4-copy .hero-badge {
    animation: hero-badge-pop 0.6s 0.2s cubic-bezier(0.16, 1, 0.3, 1) both;
}

body.landing-public .hero-v4-copy h1 {
    animation: hero-fade-up 0.8s 0.35s cubic-bezier(0.16, 1, 0.3, 1) both;
}

body.landing-public .hero-v4-copy > p {
    animation: hero-fade-up 0.8s 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
}

body.landing-public .hero-actions {
    animation: hero-fade-up 0.8s 0.65s cubic-bezier(0.16, 1, 0.3, 1) both;
}

body.landing-public .trust-badge-v2 {
    animation: hero-fade-up 0.8s 0.8s cubic-bezier(0.16, 1, 0.3, 1) both;
}

body.landing-public .hero-v4-showcase {
    animation: hero-fade-right 1s 0.4s cubic-bezier(0.16, 1, 0.3, 1) both;
}

/* ─── CTA BUTTON PULSE + SHIMMER ─── */
.cta-btn {
    position: relative;
    overflow: hidden;
}

.cta-btn::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -75%;
    width: 50%;
    height: 200%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.15),
        transparent
    );
    transform: skewX(-20deg);
    animation: btn-shimmer 4s ease-in-out infinite;
    pointer-events: none;
}

@keyframes btn-shimmer {
    0%, 100% { left: -75%; }
    50% { left: 125%; }
}

/* ─── HERO BADGE GLOW PULSE ─── */
.hero-badge {
    position: relative;
}

.hero-badge::before {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: inherit;
    background: linear-gradient(135deg, rgba(0, 242, 234, 0.3), rgba(138, 79, 255, 0.3));
    opacity: 0;
    animation: badge-glow 3s ease-in-out infinite;
    z-index: -1;
    filter: blur(8px);
}

@keyframes badge-glow {
    0%, 100% { opacity: 0; }
    50% { opacity: 1; }
}

/* ─── ANIMATED STAT COUNTERS ─── */
.stat-chip {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.stat-chip:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 12px 32px rgba(0, 242, 234, 0.15);
}

/* ─── SHOWCASE FLOATING ANIMATION ─── */
@keyframes gentle-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.showcase-frame {
    animation: gentle-float 5s ease-in-out infinite;
}

/* ─── SECTION LABEL ANIMATION ─── */
.section-label {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

/* ─── STICKY CTA BAR ─── */
.sticky-cta-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 990;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 12px 24px;
    background: rgba(3, 3, 8, 0.92);
    border-top: 1px solid rgba(0, 242, 234, 0.12);
    backdrop-filter: blur(20px) saturate(150%);
    -webkit-backdrop-filter: blur(20px) saturate(150%);
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.sticky-cta-bar.visible {
    transform: translateY(0);
}

.sticky-cta-bar .sticky-text {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
}

.sticky-cta-bar .sticky-text strong {
    color: var(--accent-cyan, #00f2ea);
}

.sticky-cta-bar .cta-btn {
    padding: 8px 24px;
    font-size: 0.82rem;
    border-radius: 8px;
}

/* ─── LIVE STATS SECTION ─── */
.live-stats-section {
    padding: 60px 24px;
    text-align: center;
}

.live-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    max-width: 900px;
    margin: 0 auto;
}

.live-stat-card {
    padding: 32px 16px;
    border-radius: 16px;
    background: rgba(10, 10, 28, 0.5);
    border: 1px solid rgba(0, 242, 234, 0.08);
    transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
    position: relative;
    overflow: hidden;
}

.live-stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--accent-cyan, #00f2ea), transparent);
    opacity: 0;
    transition: opacity 0.35s ease;
}

.live-stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 48px rgba(0, 242, 234, 0.08);
    border-color: rgba(0, 242, 234, 0.15);
}

.live-stat-card:hover::before {
    opacity: 1;
}

.live-stat-icon {
    font-size: 1.6rem;
    margin-bottom: 12px;
    background: linear-gradient(135deg, var(--accent-cyan, #00f2ea), var(--accent-purple, #8a4fff));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.live-stat-value {
    font-family: var(--font-head, 'Space Grotesk', sans-serif);
    font-size: 2.2rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: -0.5px;
    margin-bottom: 4px;
}

.live-stat-label {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.5);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

/* ─── ENHANCED FAQ ANIMATION ─── */
.faq-item {
    cursor: pointer;
}

.faq-item .faq-q i.fa-chevron-down {
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.faq-item.open .faq-q i.fa-chevron-down {
    transform: rotate(180deg);
}

/* ─── CONTEXTUAL CTA HOVER ─── */
.contextual-cta {
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
}

.contextual-cta:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 32px rgba(0, 242, 234, 0.2) !important;
}

.contextual-cta::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.08), transparent);
    transition: left 0.5s ease;
}

.contextual-cta:hover::before {
    left: 100%;
}

/* ─── RESPONSIVE ─── */
@media (max-width: 768px) {
    .live-stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .live-stat-value {
        font-size: 1.6rem;
    }

    .live-stat-label {
        font-size: 0.7rem;
    }

    .marquee-set {
        gap: 24px;
    }

    .marquee-item {
        padding: 8px 16px;
    }

    .marquee-item i {
        font-size: 1.2rem;
    }

    .marquee-item span {
        font-size: 0.75rem;
    }

    .sticky-cta-bar {
        padding: 10px 16px;
        gap: 10px;
    }

    .sticky-cta-bar .sticky-text {
        font-size: 0.75rem;
    }

    .sticky-cta-bar .cta-btn {
        padding: 7px 16px;
        font-size: 0.75rem;
    }

    .integrations-section::before,
    .integrations-section::after {
        width: 40px;
    }
}

@media (max-width: 480px) {
    .live-stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .live-stat-card {
        padding: 20px 10px;
    }
}

/* ─── PREFERS REDUCED MOTION ─── */
/* ─── LIVE DEMO PLAYGROUND ─── */
#demo-playground {
    padding: 60px 0;
    position: relative;
    z-index: 5;
}

.demo-playground-container {
    max-width: 600px;
    margin: 40px auto 0;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
    position: relative;
    overflow: hidden;
}

.demo-input-area {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
}

.demo-input {
    flex: 1;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 14px 20px;
    border-radius: 12px;
    color: #fff;
    font-size: 1rem;
    outline: none;
    transition: all 0.3s;
}

.demo-input:focus {
    border-color: #00f2ea;
    background: rgba(0, 242, 234, 0.05);
}

.demo-generate-btn {
    background: linear-gradient(135deg, #00f2ea 0%, #00c3bc 100%);
    color: #000;
    border: none;
    padding: 0 24px;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.demo-generate-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 242, 234, 0.3);
}

.demo-result-area {
    min-height: 200px;
    position: relative;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 24px;
}

.demo-loader {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 200px;
    color: #00f2ea;
    font-size: 1.1rem;
    gap: 12px;
}

.demo-loader i {
    font-size: 2rem;
}

.demo-mockup {
    position: relative;
}

.demo-ad-preview {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    padding: 16px;
    filter: blur(4px);
    opacity: 0.7;
    pointer-events: none;
    user-select: none;
}

.demo-ad-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.demo-ad-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
}

.demo-ad-name {
    font-weight: 600;
    font-size: 0.9rem;
}

.demo-ad-sponsor {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.5);
}

.demo-ad-text {
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 16px;
    color: rgba(255, 255, 255, 0.9);
}

.demo-ad-image-placeholder {
    height: 180px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.3);
    gap: 8px;
}

.demo-blur-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: rgba(3, 3, 8, 0.4);
    z-index: 2;
    text-align: center;
    padding: 20px;
}

.demo-blur-overlay h3 {
    font-size: 1.25rem;
    margin-bottom: 8px;
    color: #fff;
}

.demo-blur-overlay p {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 20px;
}

@media (prefers-reduced-motion: reduce) {
    .reveal,
    .reveal-left,
    .reveal-right,
    .reveal-scale {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .reveal-stagger > * {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .marquee-track {
        animation: none;
    }

    .showcase-frame {
        animation: none;
    }

    .cta-btn::after {
        animation: none;
    }

    .hero-badge::before {
        animation: none;
    }

    body.landing-public .hero-v4-copy .hero-badge,
    body.landing-public .hero-v4-copy h1,
    body.landing-public .hero-v4-copy > p,
    body.landing-public .hero-actions,
    body.landing-public .trust-badge-v2,
    body.landing-public .hero-v4-showcase {
    }
}

/* =========================================
   PREMIUM CHECKOUT MODAL (STRIPE-LIKE)
   ========================================= */
.vrx-checkout-modal {
    position: fixed;
    top: 0; left: 0; width: 100vw; height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 99999;
    opacity: 0;
    animation: modalFadeIn 0.3s forwards ease-out;
}

@keyframes modalFadeIn {
    to { opacity: 1; }
}

.vrx-checkout-backdrop {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.vrx-checkout-content {
    position: relative;
    width: 100%;
    max-width: 480px;
    background: #121214;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.7);
    overflow: hidden;
    transform: translateY(20px) scale(0.95);
    animation: modalSlideUp 0.4s 0.1s forwards cubic-bezier(0.16, 1, 0.3, 1);
    opacity: 0;
}

@keyframes modalSlideUp {
    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

.vrx-checkout-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: none;
    color: rgba(255, 255, 255, 0.6);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    transition: all 0.2s;
    z-index: 10;
}

.vrx-checkout-close:hover {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    transform: rotate(90deg);
}

.vrx-checkout-header {
    padding: 24px 24px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.vrx-checkout-header img {
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(138, 79, 255, 0.4);
}

.vrx-checkout-header span {
    font-family: var(--font-head);
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    letter-spacing: -0.02em;
}

.vrx-checkout-iframe-wrap {
    background: #fff; 
    min-height: 450px;
    width: 100%;
    border-radius: 0 0 24px 24px;
    overflow: hidden;
}
