/* Custom CSS for the Creative Hero Redesign - Light High-Contrast & Scroll animations */
.creative-hero-section {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: transparent; /* Let Stripe background show through */
    overflow: hidden;
    padding: 150px 2rem 100px;
    box-sizing: border-box;
    z-index: 1;
}

/* Custom mouse follower aura - adjusted to be soft on light background */
.hero-glow-aura {
    position: absolute;
    width: 600px;
    height: 600px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.09) 0%, rgba(167, 139, 250, 0.04) 50%, transparent 70%);
    filter: blur(80px);
    pointer-events: none;
    z-index: 0;
    transform: translate(-50%, -50%);
    transition: left 0.15s cubic-bezier(0.25, 1, 0.5, 1), top 0.15s cubic-bezier(0.25, 1, 0.5, 1);
    will-change: left, top;
}

/* Floating background grid - very subtle on light background */
.hero-creative-grid {
    position: absolute;
    inset: 0;
    background-image: 
        radial-gradient(rgba(99, 102, 241, 0.07) 1px, transparent 1px),
        radial-gradient(rgba(167, 139, 250, 0.05) 1px, transparent 1px);
    background-size: 40px 40px;
    background-position: 0 0, 20px 20px;
    opacity: 0.5;
    z-index: 0;
    pointer-events: none;
}

.hero-creative-container {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 4rem;
    align-items: center;
}

@media (max-width: 1024px) {
    .hero-creative-container {
        grid-template-columns: 1fr;
        gap: 3.5rem;
        text-align: center;
    }
}

@media (max-width: 768px) {
    .creative-hero-section {
        padding: 100px 1rem 60px;
    }

    .hero-creative-title {
        font-size: clamp(2rem, 8vw, 2.6rem);
        line-height: 1.12;
    }

    .hero-creative-subtitle {
        font-size: 1rem;
        line-height: 1.6;
    }

    .swiss-badge {
        margin-bottom: 1.25rem;
        padding: 0.4rem 0.9rem;
        font-size: 0.8rem;
    }

    .hero-creative-trust {
        gap: 0.75rem 1rem;
    }

    .trust-item {
        font-size: 0.78rem;
    }
}

/* Left Column: Text & CTA Content */
.hero-creative-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    will-change: transform, opacity;
}

@media (max-width: 1024px) {
    .hero-creative-content {
        align-items: center;
    }
}

/* Custom Swiss sub-badge: Light glassmorphism */
.swiss-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1.1rem;
    background: rgba(99, 102, 241, 0.05);
    border: 1px solid rgba(99, 102, 241, 0.16);
    border-radius: 9999px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #4f46e5;
    margin-bottom: 2rem;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.04);
}

/* High-Contrast Hero Typography */
.hero-creative-title {
    font-family: var(--font-display), sans-serif;
    font-size: clamp(2.4rem, 5vw, 3.8rem);
    line-height: 1.15;
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 1.5rem;
    letter-spacing: -0.03em;
    text-shadow: none;
    text-align: center;
}

@media (max-width: 1024px) {
    .hero-creative-title {
        text-align: center;
    }
}

.hero-creative-title span.highlight {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
}

.hero-creative-subtitle {
    font-family: var(--font-primary), sans-serif;
    font-size: clamp(1.05rem, 2vw, 1.25rem);
    line-height: 1.65;
    color: #334155;
    margin-bottom: 2.5rem;
    max-width: 620px;
    margin-left: auto;
    margin-right: auto;
    font-weight: 400;
    text-align: center;
}

@media (max-width: 1024px) {
    .hero-creative-subtitle {
        text-align: center;
    }
}

/* CTA Group styling */
.hero-creative-ctas {
    display: flex;
    gap: 1.25rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
    width: 100%;
    justify-content: center;
}

.btn-premium-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1.1rem 2.2rem;
    font-size: 1.05rem;
    font-weight: 600;
    border-radius: 14px;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
}

.btn-premium-cta.primary {
    background: #0f172a;
    color: #ffffff;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-premium-cta.primary:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 15px 40px rgba(15, 23, 42, 0.4);
    border-color: rgba(255, 255, 255, 0.2);
}

.btn-premium-cta.secondary {
    background: rgba(15, 23, 42, 0.03);
    border: 1px solid rgba(15, 23, 42, 0.12);
    color: #0f172a;
}

.btn-premium-cta.secondary:hover {
    background: rgba(15, 23, 42, 0.06);
    border-color: rgba(15, 23, 42, 0.25);
    transform: translateY(-2px);
}

.hero-creative-note {
    font-size: 0.8rem;
    color: #64748b;
    margin-bottom: 3rem;
}

/* Trust features list under CTAs */
.hero-creative-trust {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    padding-top: 1.75rem;
    border-top: 1px solid rgba(15, 23, 42, 0.08);
    width: 100%;
}

@media (max-width: 1024px) {
    .hero-creative-trust {
        justify-content: center;
    }
}

.trust-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.82rem;
    color: #475569;
    transition: color 0.3s ease;
}

.trust-item:hover {
    color: #0f172a;
}

.trust-item svg {
    color: #4f46e5;
}

/* Right Column: 3D Video Showcase */
.hero-creative-visual {
    display: flex;
    justify-content: center;
    align-items: center;
    perspective: 1200px; /* 3D depth */
    width: 100%;
    z-index: 5;
    will-change: transform, opacity;
}

.showcase-3d-card {
    position: relative;
    width: 100%;
    max-width: 540px;
    aspect-ratio: 16 / 10;
    border-radius: 20px;
    background: rgba(10, 10, 15, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 
        0 30px 80px rgba(15, 23, 42, 0.22),
        0 0 60px rgba(99, 102, 241, 0.08);
    transform-style: preserve-3d;
    transition: transform 0.1s ease-out; /* Smooth follow cursor */
    overflow: hidden;
}

.showcase-3d-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 20px;
    padding: 1px;
    background: linear-gradient(135deg, rgba(255,255,255,0.15) 0%, rgba(99,102,241,0.2) 50%, transparent 100%);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
    z-index: 5;
}

/* Glowing back-element */
.showcase-glow {
    position: absolute;
    inset: -20px;
    background: radial-gradient(ellipse at center, rgba(99, 102, 241, 0.2) 0%, transparent 70%);
    border-radius: 30px;
    transform: translateZ(-20px);
    pointer-events: none;
    z-index: -1;
}

/* Top Browser Bar */
.showcase-bar {
    height: 38px;
    background: rgba(255, 255, 255, 0.04);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    padding: 0 1.25rem;
    gap: 0.5rem;
    transform: translateZ(10px);
}

.showcase-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
}
.showcase-dot.red { background: #ff5f56; }
.showcase-dot.yellow { background: #ffbd2e; }
.showcase-dot.green { background: #27c93f; }

.showcase-url {
    flex: 1;
    text-align: center;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.4);
    font-family: monospace;
    letter-spacing: 0.05em;
}

/* Video inside 3D Card */
.showcase-video-container {
    position: relative;
    width: 100%;
    height: calc(100% - 38px);
    overflow: hidden;
    transform: translateZ(15px);
    background: #000;
}

.showcase-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Play/Sound Overlay controls */
.showcase-overlay-controls {
    position: absolute;
    bottom: 1rem;
    left: 1rem;
    right: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 10;
    pointer-events: none;
}

.showcase-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.1rem;
    background: rgba(10, 10, 15, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #ffffff;
    font-family: var(--font-primary), sans-serif;
    font-size: 0.8rem;
    font-weight: 500;
    border-radius: 10px;
    cursor: pointer;
    backdrop-filter: blur(8px);
    transition: all 0.2s ease;
    pointer-events: auto;
}

.showcase-btn:hover {
    background: rgba(99, 102, 241, 0.3);
    border-color: rgba(99, 102, 241, 0.5);
    transform: scale(1.05);
}

.showcase-btn svg {
    width: 15px;
    height: 15px;
    stroke: currentColor;
}

/* Staggered Reveals on Load (Framer-Motion style) */
.animate-reveal {
    opacity: 0;
    transform: translateY(30px);
    animation: spring-reveal 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.25s; }
.delay-3 { animation-delay: 0.4s; }
.delay-4 { animation-delay: 0.55s; }
.delay-5 { animation-delay: 0.7s; }

@keyframes spring-reveal {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* CSS soundwaves animate when active */
.sound-waves-icon {
    display: flex;
    align-items: flex-end;
    gap: 2px;
    height: 12px;
    width: 14px;
}

.sound-bar {
    width: 2px;
    height: 100%;
    background-color: currentColor;
    border-radius: 1px;
}

.sound-active .sound-bar {
    animation: sound-bounce 0.8s ease infinite alternate;
}

.sound-active .sound-bar:nth-child(1) { animation-delay: 0.1s; }
.sound-active .sound-bar:nth-child(2) { animation-delay: 0.3s; }
.sound-active .sound-bar:nth-child(3) { animation-delay: 0.2s; }
.sound-active .sound-bar:nth-child(4) { animation-delay: 0.4s; }

@keyframes sound-bounce {
    0% { height: 20%; }
    100% { height: 100%; }
}

/* ========================================
   SCROLL-DRIVEN ANIMATIONS (Baseline Widely Available)
   ======================================== */
@supports ((animation-timeline: view()) and (animation-range: entry)) {
    /* 1. Hero Content Scroll Fade Out */
    @keyframes heroFadeOut {
        to {
            opacity: 0;
            transform: translateY(-100px) scale(0.95);
        }
    }
    
    .hero-creative-content {
        animation: heroFadeOut linear both;
        animation-timeline: view();
        animation-range: exit 30% exit 100%;
    }

    /* 2. Hero Visual Card Scroll Parallax */
    @keyframes cardScrollParallax {
        to {
            transform: translateY(-160px) rotateX(12deg) scale(0.95);
            opacity: 0.3;
        }
    }
    
    .hero-creative-visual {
        animation: cardScrollParallax linear both;
        animation-timeline: view();
        animation-range: exit 0% exit 100%;
    }

    /* 3. Global viewport entrance reveal */
    @keyframes revealUp {
        from {
            opacity: 0;
            transform: translateY(120px) scale(0.95);
        }
        to {
            opacity: 1;
            transform: translateY(0) scale(1);
        }
    }
    
    .scroll-reveal {
        animation: revealUp linear both;
        animation-timeline: view();
        animation-range: entry 10% entry 40%;
    }
}

/* Fallback transitions for browsers without scroll-driven animation support */
@supports not ((animation-timeline: view()) and (animation-range: entry)) {
    .scroll-reveal {
        opacity: 0;
        transform: translateY(80px) scale(0.97);
        transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1), transform 1s cubic-bezier(0.16, 1, 0.3, 1);
    }
    
    .scroll-reveal.reveal-active {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Ensure no conflicts with global layout */
header {
    background: rgba(255, 255, 255, 0.85) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
}
