/* Custom styles for Mary Irene Gardens */

html {
    scroll-behavior: smooth;
}

body {
    overflow-x: hidden;
}

/* Scroll reveal base — content is visible by default, JS adds animation */
.scroll-reveal {
    opacity: 1;
    transform: none;
    transition: opacity 0.7s ease, transform 0.7s ease;
}

@media (prefers-reduced-motion: no-preference) {
    .scroll-reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }

    .scroll-reveal:not(.revealed) {
        opacity: 0;
        transform: translateY(24px);
    }
}

/* Navbar scroll state */
.navbar-scrolled {
    box-shadow: 0 1px 20px rgba(10, 22, 40, 0.06);
}

/* Custom selection color */
::selection {
    background-color: rgba(74, 222, 128, 0.2);
    color: #0f2035;
}

/* Subtle line animations */
div[class*="h-px"] {
    transition: width 0.6s ease;
}

/* Smooth image loading */
img {
    image-rendering: -webkit-optimize-contrast;
}

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

#mobile-menu.hidden {
    max-height: 0;
    opacity: 0;
    overflow: hidden;
}

#mobile-menu:not(.hidden) {
    max-height: 300px;
    opacity: 1;
}

/* Focus visible for accessibility */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid rgba(74, 222, 128, 0.6);
    outline-offset: 2px;
}

/* Prevent layout shift on images */
img {
    max-width: 100%;
    height: auto;
}

/* Ensure all text meets contrast */
.font-serif {
    letter-spacing: -0.01em;
}

.font-sans {
    letter-spacing: 0.01em;
}
