/* Base styles and custom utilities */
:root {
    --font-fredoka: 'Fredoka', sans-serif;
    --font-nunito: 'Nunito', sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-nunito);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #F0FAF5;
}
::-webkit-scrollbar-thumb {
    background: #7ADFBF;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #4FD3AB;
}

/* Floating animations */
@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(3deg); }
}

@keyframes float-delayed {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-15px) rotate(-2deg); }
}

@keyframes spin-slow {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes spin-slow-reverse {
    from { transform: rotate(360deg); }
    to { transform: rotate(0deg); }
}

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

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

.animate-spin-slow {
    animation: spin-slow 20s linear infinite;
}

.animate-spin-slow-reverse {
    animation: spin-slow-reverse 25s linear infinite;
}

/* Scroll reveal animations - progressive enhancement */
.scroll-reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* For browsers that support prefers-reduced-motion, disable animations */
@media (prefers-reduced-motion: reduce) {
    .animate-float,
    .animate-float-delayed,
    .animate-spin-slow,
    .animate-spin-slow-reverse,
    .scroll-reveal {
        animation: none;
        transition: none;
    }
    html {
        scroll-behavior: auto;
    }
}

/* Mobile menu animations */
.mobile-bar {
    transition: all 0.3s ease;
}

#mobile-menu-btn.active .mobile-bar:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

#mobile-menu-btn.active .mobile-bar:nth-child(2) {
    opacity: 0;
}

#mobile-menu-btn.active .mobile-bar:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
    width: 1.25rem;
}

/* Navbar scroll state */
.nav-scrolled {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(12px);
    box-shadow: 0 4px 20px rgba(10, 35, 66, 0.08);
}

/* Link hover effects */
a {
    text-decoration: none;
}

/* Focus styles for accessibility */
a:focus-visible,
button:focus-visible {
    outline: 3px solid #7ADFBF;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Ensure images don't cause layout shift */
img {
    max-width: 100%;
    height: auto;
}
