/* Custom styles to complement Tailwind */

/* Animations */
@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

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

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

/* Animation classes */
.animate-fadeInLeft {
    animation: fadeInLeft 0.8s ease-out;
}

.animate-fadeInRight {
    animation: fadeInRight 0.8s ease-out;
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

.animate-float-delayed {
    animation: float 3s ease-in-out infinite 1.5s;
}

.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Navigation styles */
.nav-link {
    @apply text-gray-700 hover:text-forest transition-colors font-medium relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: #2E7D32;
    transition: width 0.3s ease;
}

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

/* Button styles */
.btn-primary {
    @apply bg-forest hover:bg-forest/90 text-white px-6 py-3 rounded-full font-medium inline-flex items-center transition-all duration-300 transform hover:-translate-y-1 hover:shadow-lg;
}

.btn-secondary {
    @apply border-2 border-forest text-forest hover:bg-forest hover:text-white px-6 py-3 rounded-full font-medium inline-flex items-center transition-all duration-300 transform hover:-translate-y-1 hover:shadow-lg;
}

/* Card hover effects */
.card-hover {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-hover:hover {
    transform: translateY(-5px) rotate(1deg);
}

/* Header background transition */
#header {
    background-color: transparent;
    backdrop-filter: blur(0px);
}

#header.scrolled {
    background-color: rgba(247, 247, 249, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

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

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

::-webkit-scrollbar-thumb {
    background: #2E7D32;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #1B5E20;
}

/* Focus styles for accessibility */
.focus-visible:focus-visible {
    outline: 2px solid #2E7D32;
    outline-offset: 2px;
}

/* Cookie notice */
.cookie-notice {
    position: fixed;
    bottom: 20px;
    left: 20px;
    right: 20px;
    background: rgba(51, 51, 51, 0.95);
    backdrop-filter: blur(10px);
    color: white;
    padding: 16px 20px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    max-width: 500px;
    margin: 0 auto;
    display: none;
}

.cookie-notice.show {
    display: block;
    animation: fadeInUp 0.5s ease-out;
}

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

.focus\:not-sr-only:focus {
    position: static;
    width: auto;
    height: auto;
    padding: 0.5rem 1rem;
    margin: 0;
    overflow: visible;
    clip: auto;
    white-space: normal;
}

/* Smooth transitions for better UX */
* {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

html {
    scroll-behavior: smooth;
}

/* Form enhancements */
input:focus, textarea:focus, select:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(46, 125, 50, 0.1);
}

/* Loading states */
.loading {
    opacity: 0.7;
    pointer-events: none;
}

/* Reduced motion for accessibility */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}