/* Phone Farm Pro - Custom Styles */

/* Animation Keyframes */
@keyframes fade-in {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 0 20px rgba(var(--p), 0.3);
    }
    50% {
        box-shadow: 0 0 30px rgba(var(--p), 0.6);
    }
}

@keyframes gradient-shift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

@keyframes counter-up {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slide-in-left {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slide-in-right {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Utility Classes */
.animate-fade-in {
    animation: fade-in 0.8s ease-out forwards;
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

.animate-pulse-glow {
    animation: pulse-glow 2s ease-in-out infinite;
}

.animate-gradient {
    background: linear-gradient(45deg, var(--primary), var(--secondary), var(--accent));
    background-size: 300% 300%;
    animation: gradient-shift 3s ease infinite;
}

.animate-counter {
    animation: counter-up 1s ease-out forwards;
}

.animate-slide-left {
    animation: slide-in-left 0.8s ease-out forwards;
}

.animate-slide-right {
    animation: slide-in-right 0.8s ease-out forwards;
}

/* Custom Grid Pattern */
.bg-grid-pattern {
    background-image: 
        linear-gradient(rgba(var(--bc), 0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(var(--bc), 0.1) 1px, transparent 1px);
    background-size: 20px 20px;
}

/* Glass Effect */
.glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Gradient Text Effects */
.text-gradient-primary {
    background: linear-gradient(135deg, hsl(var(--p)) 0%, hsl(var(--s)) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.text-gradient-secondary {
    background: linear-gradient(135deg, hsl(var(--s)) 0%, hsl(var(--a)) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.text-gradient-rainbow {
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4, #feca57, #ff9ff3);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradient-shift 3s ease infinite;
}

/* Phone Mock Animation */
.phone-mock {
    position: relative;
    transition: all 0.3s ease;
}

.phone-mock:hover {
    transform: scale(1.05) rotate(2deg);
}

.phone-mock::before {
    content: '';
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    background: linear-gradient(45deg, hsl(var(--p)), hsl(var(--s)), hsl(var(--a)));
    border-radius: inherit;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.phone-mock:hover::before {
    opacity: 0.3;
    animation: pulse-glow 2s ease-in-out infinite;
}

/* Enhanced Card Effects */
.card-enhanced {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.card-enhanced::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transform: rotate(45deg);
    transition: all 0.6s ease;
    opacity: 0;
}

.card-enhanced:hover::before {
    opacity: 1;
    animation: shimmer 2s ease-in-out;
}

@keyframes shimmer {
    0% {
        transform: translateX(-100%) rotate(45deg);
    }
    100% {
        transform: translateX(100%) rotate(45deg);
    }
}

/* Pricing Card Glow */
.pricing-card-popular {
    position: relative;
    box-shadow: 0 0 30px rgba(var(--p), 0.3);
}

.pricing-card-popular::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, hsl(var(--p)), hsl(var(--s)), hsl(var(--a)));
    border-radius: inherit;
    z-index: -1;
    animation: gradient-shift 3s ease infinite;
}

/* Parallax Effect */
.parallax {
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

/* Stats Counter Animation */
.stat-counter {
    font-variant-numeric: tabular-nums;
    transition: all 0.3s ease;
}

.stat-counter:hover {
    transform: scale(1.1);
}

/* Feature Icon Hover */
.feature-icon {
    transition: all 0.3s ease;
}

.feature-icon:hover {
    transform: scale(1.1) rotate(5deg);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: hsl(var(--b1));
}

::-webkit-scrollbar-thumb {
    background: hsl(var(--p));
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: hsl(var(--pf));
}

/* Mobile Responsive Animations */
@media (max-width: 768px) {
    .animate-float {
        animation: none;
    }
    
    .phone-mock:hover {
        transform: scale(1.02);
    }
    
    .card-enhanced:hover {
        transform: translateY(-5px);
    }
}

/* Dark Mode Enhancements */
@media (prefers-color-scheme: dark) {
    .glass {
        background: rgba(0, 0, 0, 0.3);
        border: 1px solid rgba(255, 255, 255, 0.1);
    }
}

/* Loading States */
.loading-gradient {
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

/* Interactive Buttons */
.btn-enhanced {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.btn-enhanced::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn-enhanced:hover::before {
    left: 100%;
}

.btn-enhanced:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

/* Typography Enhancements */
.text-shadow {
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.text-glow {
    text-shadow: 0 0 10px currentColor;
}

/* Hero Section Enhancements */
.hero-background {
    background: radial-gradient(circle at 50% 50%, hsl(var(--p) / 0.1) 0%, transparent 50%),
                radial-gradient(circle at 20% 80%, hsl(var(--s) / 0.1) 0%, transparent 50%),
                radial-gradient(circle at 80% 20%, hsl(var(--a) / 0.1) 0%, transparent 50%);
}

/* Professional Layout */
.section-divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, hsl(var(--bc) / 0.2), transparent);
    margin: 2rem 0;
}

/* Enhanced Focus States */
.focus-enhanced:focus {
    outline: none;
    box-shadow: 0 0 0 3px hsl(var(--p) / 0.3);
    transform: scale(1.02);
}

/* Performance Optimization */
.gpu-accelerated {
    transform: translateZ(0);
    will-change: transform;
}

/* Dropdown Menu Fixes */
.dropdown-content {
    z-index: 9999 !important;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04) !important;
}

.dropdown.dropdown-open .dropdown-content {
    z-index: 9999 !important;
}

/* Ensure phone elements don't interfere with dropdowns */
.phone-mock,
.phone-illustration {
    z-index: 1;
    position: relative;
}

/* Navbar should be above content but below dropdowns */
.navbar {
    z-index: 100;
    position: relative;
}

/* Messages should be high priority */
.alert {
    z-index: 1000 !important;
}