/* Custom styles for Hannah House Child Development */

:root {
    --emerald-600: #059669;
    --emerald-700: #047857;
    --emerald-800: #065F46;
    --cream-50: #FDFBF7;
    --cream-100: #FAF7F0;
}

html {
    scroll-behavior: smooth;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Smooth transitions for interactive elements */
a, button {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Scroll reveal animations - progressive enhancement */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1), transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

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

/* Hero animations */
.hero-anim {
    opacity: 1;
    transform: translateY(0);
    animation: heroFadeIn 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.hero-anim:nth-child(1) { animation-delay: 0.1s; }
.hero-anim:nth-child(2) { animation-delay: 0.25s; }
.hero-anim:nth-child(3) { animation-delay: 0.4s; }
.hero-anim:nth-child(4) { animation-delay: 0.55s; }

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

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .reveal, .reveal.revealed {
        opacity: 1;
        transform: none;
        transition: none;
    }
    .hero-anim {
        animation: none;
        opacity: 1;
        transform: none;
    }
    html {
        scroll-behavior: auto;
    }
}

/* Image hover effects */
.group:hover .group-hover\:scale-105 {
    transform: scale(1.05);
}

/* Mobile menu transitions */
#mobile-menu {
    transition: opacity 0.3s ease, max-height 0.3s ease;
}

/* Focus styles */
input:focus, textarea:focus, button:focus {
    outline: none;
}

/* Selection color */
::selection {
    background-color: rgba(5, 150, 105, 0.2);
    color: #064E3B;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #6EE7B7;
}

/* Mobile menu active state */
#mobile-menu.open {
    display: block;
}

/* Navigation background transition */
#navbar.scrolled {
    background-color: rgba(253, 251, 247, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(5, 150, 105, 0.1);
}

#navbar.scrolled .nav-text {
    color: #064E3B;
}

#navbar.scrolled .nav-link {
    color: rgba(6, 78, 59, 0.7);
}

#navbar.scrolled .nav-link:hover {
    color: #059669;
}

#navbar.scrolled .nav-btn span {
    background-color: #064E3B;
}
