/* Custom styles for Merrill's Water Powered Sawmill */

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Base font rendering */
body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Selection color */
::selection {
    background-color: #C5A065;
    color: #0A1628;
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0A1628;
}
::-webkit-scrollbar-thumb {
    background: #1D3A6E;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #C5A065;
}

/* Reveal animations - progressive enhancement, only when JS runs and reduced-motion is off */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(24px);
        transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
    }
    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
    .reveal.delay-1 { transition-delay: 0.1s; }
    .reveal.delay-2 { transition-delay: 0.2s; }
    .reveal.delay-3 { transition-delay: 0.3s; }
    .reveal.delay-4 { transition-delay: 0.4s; }
}

/* Ensure content is visible even without JS */
@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
    }
}

/* Navbar scroll state */
.navbar-scrolled {
    background-color: rgba(10, 22, 40, 0.95) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05);
}

/* Mobile menu transition */
#mobile-menu {
    animation: slideDown 0.3s ease-out forwards;
}
@keyframes slideDown {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

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

/* Gold accent underline for headings */
.font-serif em {
    font-style: italic;
}

/* Focus visible styles */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
    outline: 2px solid #C5A065;
    outline-offset: 2px;
    border-radius: 2px;
}

/* Select dropdown styling */
select option {
    background-color: #0F2140;
    color: #ffffff;
    padding: 8px;
}

/* Mobile menu link hover */
.mobile-link:hover {
    color: #C5A065;
}
