/* Custom styles for Brookside Cottage */

/* Scroll behavior */
html {
    scroll-behavior: smooth;
}

/* Selection color */
::selection {
    background-color: #e8645a;
    color: #ffffff;
}

/* Reveal animations — progressive enhancement, only when JS is available */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(24px);
        transition: opacity 0.7s ease, transform 0.7s ease;
    }

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

    .reveal:nth-child(2) { transition-delay: 0.1s; }
    .reveal:nth-child(3) { transition-delay: 0.2s; }
}

/* Subtle focus styles for accessibility */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid #e8645a;
    outline-offset: 2px;
}

/* Smooth image loading */
img {
    image-rendering: auto;
    will-change: transform;
}

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

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

::-webkit-scrollbar-thumb {
    background: #d1d1d1;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a1a1a1;
}

/* Mobile menu transition */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

#mobile-menu.open {
    max-height: 400px;
}

/* Subtle parallax for hero background orbs */
@keyframes float {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(10px, -10px); }
}

#hero .absolute div:first-child {
    animation: float 8s ease-in-out infinite;
}

#hero .absolute div:last-child {
    animation: float 6s ease-in-out infinite reverse;
}

/* Form input autofill override */
input:-webkit-autofill,
textarea:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 30px #1a1a1a inset !important;
    -webkit-text-fill-color: #ffffff !important;
}
