/* Shared Styles for Infinity Classes */

:root {
    --radius: 0.75rem;
    
    /* Light mode - Vibrant modern palette */
    --background: 0.99 0 0;
    --foreground: 0.15 0 0;
    --card: 1 0 0;
    --popover: 1 0 0;
    --primary: 0.55 0.25 264;
    --primary-foreground: 0.99 0 0;
    --secondary: 0.96 0 0;
    --muted: 0.96 0 0;
    --muted-foreground: 0.50 0 0;
    --accent: 0.65 0.22 285;
    --accent-foreground: 0.99 0 0;
    --destructive: 0.58 0.24 27;
    --border: 0.92 0 0;
    --ring: 0.55 0.25 264;
}

.dark {
    /* Dark mode - Deep, rich colors with vibrant accents */
    --background: 0.10 0 0;
    --foreground: 0.98 0 0;
    --card: 0.15 0 0;
    --popover: 0.12 0 0;
    --primary: 0.60 0.25 264;
    --primary-foreground: 0.98 0 0;
    --secondary: 0.20 0 0;
    --muted: 0.25 0 0;
    --muted-foreground: 0.65 0 0;
    --accent: 0.65 0.22 285;
    --accent-foreground: 0.98 0 0;
    --destructive: 0.65 0.22 27;
    --border: 0.25 0 0;
    --ring: 0.60 0.25 264;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: oklch(var(--background));
    color: oklch(var(--foreground));
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
}

html {
    scroll-behavior: smooth;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: oklch(var(--background));
}

::-webkit-scrollbar-thumb {
    background: oklch(var(--muted-foreground) / 0.3);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: oklch(var(--muted-foreground) / 0.5);
}

/* Fade in animation */
.fade-in-section {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1), 
                transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.fade-in-section.animate-in {
    opacity: 1;
    transform: translateY(0);
}

/* Gradient text */
.text-gradient {
    background: linear-gradient(to right, oklch(var(--primary)), oklch(var(--accent)), oklch(var(--primary)));
    background-size: 200% 200%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.animate-gradient {
    animation: gradient 3s ease infinite;
}

/* Enhanced card hover effects with smooth animations */
.card-3d {
    transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
}

.card-3d:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 40px -10px oklch(var(--primary) / 0.4);
}

.dark .card-3d:hover {
    box-shadow: 0 20px 60px -10px oklch(var(--primary) / 0.6),
                0 0 40px oklch(var(--primary) / 0.3);
}

/* Enhanced button hover effects */
.btn-hover {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.btn-hover:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px -5px oklch(var(--primary) / 0.5);
}

.dark .btn-hover:hover {
    box-shadow: 0 10px 35px -5px oklch(var(--primary) / 0.7),
                0 0 20px oklch(var(--primary) / 0.4);
}

/* Link hover effects */
.link-hover {
    transition: all 0.3s ease;
    position: relative;
}

.link-hover::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: oklch(var(--primary));
    transition: width 0.3s ease;
}

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

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

.dark .link-hover:hover {
    text-shadow: 0 0 10px oklch(var(--primary) / 0.5);
}

/* Preloader */
#preloader {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    background: oklch(var(--background));
    transition: opacity 0.7s ease;
}

#preloader.hidden {
    opacity: 0;
    pointer-events: none;
}

/* Theme toggle button styles */
.theme-toggle {
    transition: all 0.3s ease;
}

.theme-toggle:hover {
    transform: rotate(180deg) scale(1.1);
}

/* Enhanced stat cards */
.stat-card {
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: scale(1.15);
    color: oklch(var(--primary));
}

.dark .stat-card:hover {
    text-shadow: 0 0 20px oklch(var(--primary) / 0.8);
}

/* Navigation link active state */
.nav-link {
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: oklch(var(--primary));
}

.dark .nav-link:hover {
    text-shadow: 0 0 10px oklch(var(--primary) / 0.5);
}

/* Icon hover effects */
.icon-hover {
    transition: all 0.3s ease;
}

.icon-hover:hover {
    transform: scale(1.1) rotate(5deg);
    filter: drop-shadow(0 0 10px oklch(var(--primary) / 0.6));
}

/* Social icon effects */
.social-icon {
    transition: all 0.3s ease;
}

.social-icon:hover {
    background: oklch(var(--primary));
    transform: scale(1.15) translateY(-3px);
}

.dark .social-icon:hover {
    box-shadow: 0 5px 20px oklch(var(--primary) / 0.6);
}

/* Pulse animation for badges */
.badge-pulse {
    animation: pulse-glow 2s ease-in-out infinite;
}

/* Enhanced scroll indicator */
.scroll-indicator {
    animation: bounce-slow 3s ease-in-out infinite;
}

/* 3D Infinity Animation */
.infinity-3d-svg {
    animation: infinity-spin 4s linear infinite;
}

@keyframes infinity-spin {
    0% { transform: perspective(1000px) rotateY(0deg); }
    100% { transform: perspective(1000px) rotateY(360deg); }
}

/* Animated star ratings */
.star-rating {
    animation: star-glow 2s ease-in-out infinite alternate;
}

@keyframes star-glow {
    0% { filter: brightness(1) drop-shadow(0 0 2px rgba(251, 191, 36, 0.3)); }
    100% { filter: brightness(1.1) drop-shadow(0 0 4px rgba(251, 191, 36, 0.5)); }
}

/* Gradient overlays for dark mode */
.dark .gradient-overlay {
    background: linear-gradient(135deg, 
        oklch(var(--primary) / 0.1) 0%, 
        transparent 50%, 
        oklch(var(--accent) / 0.1) 100%);
}

/* Floating particles for dark mode */
.dark .floating-particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: oklch(var(--primary) / 0.6);
    border-radius: 50%;
    animation: float-slow 10s ease-in-out infinite;
    box-shadow: 0 0 10px oklch(var(--primary) / 0.8);
}

/* Contact form styles */
.contact-form input,
.contact-form textarea,
.contact-form select {
    transition: all 0.3s ease;
    background: oklch(var(--card));
    border: 1px solid oklch(var(--border));
}

.contact-form input:focus,
.contact-form textarea:focus,
.contact-form select:focus {
    border-color: oklch(var(--primary));
    box-shadow: 0 0 0 3px oklch(var(--primary) / 0.1);
}

.dark .contact-form input:focus,
.dark .contact-form textarea:focus,
.dark .contact-form select:focus {
    box-shadow: 0 0 0 3px oklch(var(--primary) / 0.2);
}

/* Enhanced form styles */
.form-input {
    transition: all 0.3s ease;
    border: 1px solid oklch(var(--border));
    background: oklch(var(--card));
}

.form-input:focus {
    border-color: oklch(var(--primary));
    box-shadow: 0 0 0 3px oklch(var(--primary) / 0.1);
}

.dark .form-input:focus {
    box-shadow: 0 0 0 3px oklch(var(--primary) / 0.2),
                0 0 20px oklch(var(--primary) / 0.1);
}

.form-input.border-red-500, .form-select.border-red-500 {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.error-message {
    animation: shake 0.5s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

/* Timeline styles */
.timeline-item {
    position: relative;
    padding-left: 2rem;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.5rem;
    width: 0.75rem;
    height: 0.75rem;
    border-radius: 50%;
    background: oklch(var(--primary));
    border: 2px solid oklch(var(--background));
}

.timeline-item::after {
    content: '';
    position: absolute;
    left: 0.375rem;
    top: 2rem;
    width: 2px;
    height: calc(100% - 1rem);
    background: oklch(var(--border));
}

.timeline-item:last-child::after {
    display: none;
}

/* Achievement cards */
.achievement-card {
    background: oklch(var(--card));
    border: 1px solid oklch(var(--border));
    border-radius: 1rem;
    padding: 1.5rem;
    transition: all 0.3s ease;
}

.achievement-card:hover {
    border-color: oklch(var(--primary) / 0.5);
    box-shadow: 0 10px 30px -5px oklch(var(--primary) / 0.1);
}

.dark .achievement-card:hover {
    box-shadow: 0 10px 30px -5px oklch(var(--primary) / 0.2),
                0 0 20px oklch(var(--primary) / 0.1);
}

/* Success animation */
@keyframes successPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.success-animation {
    animation: successPulse 2s ease-in-out infinite;
}

/* Shine effect */
@keyframes shine {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.shine-effect {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.shine-effect::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transform: translateX(-100%);
}

.card-3d:hover .shine-effect::after {
    animation: shine 1s ease-in-out;
}

/* FAQ Card Styles */
.faq-card {
    transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.faq-card:hover {
    transform: translateY(-4px);
}

.faq-card p {
    transition: max-height 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.faq-card:hover p {
    max-height: 500px;
}

.dark .faq-card:hover {
    box-shadow: 0 10px 30px -5px oklch(var(--primary) / 0.2);
}

/* Newsletter Section Styles */
.newsletter-input {
    transition: all 0.3s ease;
    background: oklch(var(--card));
    border: 1px solid oklch(var(--border));
}

.newsletter-input:focus {
    border-color: oklch(var(--primary));
    box-shadow: 0 0 0 3px oklch(var(--primary) / 0.1);
}

.dark .newsletter-input:focus {
    box-shadow: 0 0 0 3px oklch(var(--primary) / 0.2);
}

/* Stats Section Styles */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.stat-item {
    text-align: center;
    transition: all 0.3s ease;
}

.stat-item:hover {
    transform: scale(1.05);
}

.stat-number {
    font-size: 2.5rem;
    font-weight: bold;
    background: linear-gradient(to right, oklch(var(--primary)), oklch(var(--accent)));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Responsive utilities */
@media (max-width: 768px) {
    .hide-mobile {
        display: none;
    }
}

@media (min-width: 769px) {
    .show-mobile {
        display: none;
    }
}
