/* Custom styles for enhanced visual effects - OPTIMIZED */
@keyframes subtle-float {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(0, 10px); }
}

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

:root {
    --accent: #3BFFEA;
    --accent-dark: #1ADBCC;
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

body {
    position: relative;
    background-color: #000;
}

/* Background grain - optimized */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 512 512' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.08;
    pointer-events: none;
    z-index: 1;
}

/* Gradient orbs container */
.orbs-container {
    position: fixed;
    inset: 0;
    overflow: hidden;
    z-index: 0;
}

/* Gradient orbs - reduced blend mode usage */
.gradient-orb {
    position: absolute;
    border-radius: 9999px;
    filter: blur(120px);
    opacity: 0.15;
    background: radial-gradient(circle at center, var(--orb-color) 0%, transparent 70%);
    pointer-events: none;
    animation: subtle-float 8s ease-in-out infinite;
    transform: translateZ(0); /* Force GPU acceleration */
}

.gradient-orb:nth-child(2) {
    animation-delay: -2s;
}

.gradient-orb:nth-child(3) {
    animation-delay: -4s;
}

.gradient-orb.accent {
    opacity: 0.05;
}

/* Card styles - OPTIMIZED */
.product-card {
    position: relative;
    background: linear-gradient(145deg, rgba(40, 40, 40, 0.9), rgba(20, 20, 20, 0.95));
    border-radius: 24px;
    padding: 1px;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    transform: translateY(0) translateZ(0); /* GPU acceleration */
    will-change: transform;
    z-index: 2;
    contain: layout style paint; /* Limit repaints */
}

/* Simplified border effect for better performance */
.product-card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 24px;
    padding: 1px;
    background: linear-gradient(
        130deg,
        transparent,
        rgba(59, 255, 234, 0.3),
        transparent
    );
    -webkit-mask: 
        linear-gradient(#fff 0 0) content-box, 
        linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.product-card:hover::before {
    opacity: 1;
    animation: border-glow 2s ease-in-out infinite;
}

.product-card-content {
    background: linear-gradient(145deg, rgba(30, 30, 30, 0.8), rgba(10, 10, 10, 0.9));
    border-radius: 23px;
    height: 100%;
    position: relative;
    z-index: 1;
    /* Removed duplicate backdrop-filter */
}

/* Logo styles */
.logo {
    height: 40px;
    width: auto;
    margin-bottom: 1.5rem;
    transition: transform 0.3s ease;
    filter: drop-shadow(0 0 20px rgba(0, 0, 0, 0.2));
    will-change: transform;
}

.logo:hover {
    transform: scale(1.05);
}

.main-logo {
    height: 58px;
    width: auto;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
    filter: drop-shadow(0 0 25px rgba(0, 0, 0, 0.3));
    will-change: transform, filter;
}

.main-logo:hover {
    transform: scale(1.05);
    filter: drop-shadow(0 0 30px rgba(59, 255, 234, 0.1));
}

/* Card hover effect - optimized */
.product-card:hover {
    transform: translateY(-8px) translateZ(0);
    box-shadow: 
        0 20px 40px rgba(0, 0, 0, 0.3),
        0 0 30px rgba(59, 255, 234, 0.1),
        inset 0 0 0 1px rgba(59, 255, 234, 0.2);
}

/* Link styles */
.accent-link {
    position: relative;
    color: #9ca3af;
    transition: color 0.3s ease;
}

.accent-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 1px;
    bottom: -2px;
    left: 0;
    background: var(--accent);
    transition: width 0.3s ease;
    transform: translateZ(0);
}

.accent-link:hover {
    color: var(--accent);
}

.accent-link:hover::after {
    width: 100%;
}

/* Learn more link enhancement */
.learn-more-link {
    position: relative;
    transition: color 0.3s ease;
}

.learn-more-link:hover {
    color: var(--accent);
}

.learn-more-link svg {
    stroke: currentColor;
}

/* Background noise texture - removed duplicate */
.noise {
    position: fixed;
    inset: 0;
    z-index: -1;
    opacity: 0.4;
    background: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    pointer-events: none;
}

/* Enhanced gradient text effect */
.gradient-text {
    background-size: 200% auto;
    animation: gradient-shift 5s ease infinite;
}

/* Additional performance optimizations */
* {
    /* Prevent layout thrashing */
    backface-visibility: hidden;
}

/* Reduce paint areas for frequently animated elements */
.product-card,
.logo,
.main-logo {
    transform: translateZ(0);
}