/* Custom Styles for SuperBase V Landing Page */

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

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

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

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #16a34a;
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: #15803d;
}

/* Hero section animations */
.hero-animate {
    animation: fadeIn 1s ease-out;
}

/* Gradient text */
.gradient-text {
    background: linear-gradient(135deg, #16a34a 0%, #fb923c 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Card hover effects */
.card-hover {
    transition: all 0.3s ease;
}

.card-hover:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

/* Button animations */
.btn-primary {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255,255,255,0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn-primary:hover::before {
    width: 300px;
    height: 300px;
}

/* Before/After Slider */
#compare-container {
    cursor: ew-resize;
    user-select: none;
}

#slider-handle {
    transition: opacity 0.3s ease;
}

#slider-handle:hover {
    opacity: 0.9;
}

/* FAQ Accordion */
.faq-toggle {
    transition: all 0.3s ease;
}

.faq-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
}

.faq-content.active {
    max-height: 500px;
    padding-top: 1rem;
}

.faq-toggle.active i {
    transform: rotate(180deg);
}

/* Number counter animation */
.counter {
    display: inline-block;
    animation: slideUp 1s ease-out;
}

/* Parallax effect */
.parallax {
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

/* Glow effect */
.glow {
    box-shadow: 0 0 20px rgba(22, 163, 74, 0.3);
}

.glow:hover {
    box-shadow: 0 0 30px rgba(22, 163, 74, 0.5);
}

/* Loading animation */
.loading {
    display: inline-block;
    width: 50px;
    height: 50px;
    border: 3px solid rgba(22, 163, 74, 0.3);
    border-radius: 50%;
    border-top-color: #16a34a;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .hero-section h1 {
        font-size: 2rem;
    }
    
    .feature-card {
        margin-bottom: 1rem;
    }
}

/* Print styles */
@media print {
    nav, footer, .no-print {
        display: none;
    }
    
    body {
        font-size: 12pt;
    }
}

/* Dark mode support (optional) */
@media (prefers-color-scheme: dark) {
    /* Dark mode styles can be added here if needed */
}

/* Custom utility classes */
.text-shadow {
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
}

.bg-blur {
    backdrop-filter: blur(10px);
}

.transition-all {
    transition: all 0.3s ease;
}

/* Icon animations */
.icon-bounce {
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

/* Section dividers */
.section-divider {
    position: relative;
    overflow: hidden;
}

.section-divider::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, #16a34a, transparent);
}

/* Testimonial cards */
.testimonial-card {
    background: linear-gradient(135deg, #ffffff 0%, #f9fafb 100%);
    border: 1px solid rgba(22, 163, 74, 0.1);
}

/* Stats counter */
.stat-number {
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.02em;
}

/* Mobile menu styles */
.mobile-menu {
    transform: translateX(100%);
    transition: transform 0.3s ease;
}

.mobile-menu.active {
    transform: translateX(0);
}

/* Accessibility improvements */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
    border-width: 0;
}

/* Focus styles */
button:focus,
a:focus {
    outline: 2px solid #16a34a;
    outline-offset: 2px;
}

/* Custom checkbox styles */
.custom-checkbox {
    appearance: none;
    width: 20px;
    height: 20px;
    border: 2px solid #16a34a;
    border-radius: 4px;
    position: relative;
    cursor: pointer;
}

.custom-checkbox:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #16a34a;
    font-weight: bold;
}

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

.timeline-item::before {
    content: '';
    position: absolute;
    left: 10px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: #16a34a;
}

.timeline-item::after {
    content: '';
    position: absolute;
    left: 6px;
    top: 10px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #16a34a;
}

/* Notification badge */
.notification-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #fb923c;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
}

/* Wave animation for CTA */
.wave {
    position: relative;
    overflow: hidden;
}

.wave::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255,255,255,0.3);
    transform: translate(-50%, -50%);
    animation: wave-animation 2s infinite;
}

@keyframes wave-animation {
    0% {
        width: 0;
        height: 0;
        opacity: 1;
    }
    100% {
        width: 200px;
        height: 200px;
        opacity: 0;
    }
}