/* Countryroad Farmstand — Custom Styles */

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

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #fdf9f0;
}
::-webkit-scrollbar-thumb {
    background: #065f46;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #047857;
}

/* Selection color */
::selection {
    background: #065f46;
    color: #fefdf8;
}

/* Base animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Scroll reveal — progressive enhancement, only active with JS */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 1;
        transform: translateY(0);
        transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
    }
    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Image loading placeholder */
img {
    background-color: #d1fae5;
}

/* Focus visible for accessibility */
:focus-visible {
    outline: 2px solid #059669;
    outline-offset: 2px;
}

/* Navbar transition states */
.nav-scrolled {
    background: rgba(254, 253, 248, 0.95) !important;
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(6, 95, 70, 0.08);
}

/* Mobile menu transition */
#mobile-menu {
    animation: fadeIn 0.2s ease-out;
}

/* Card hover lift */
.group:hover {
    transform: translateY(-2px);
}

/* Subtle pattern overlay for sections */
.pattern-grid {
    background-image: linear-gradient(rgba(6, 95, 70, 0.03) 1px, transparent 1px),
                      linear-gradient(90deg, rgba(6, 95, 70, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
}

/* Input autofill styling */
input:-webkit-autofill,
textarea:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 30px #fefdf8 inset !important;
    caret-color: #0f172a;
}

/* Print styles */
@media print {
    header, #contact, .cta-banner {
        display: none;
    }
    body {
        color: #000;
        background: #fff;
    }
}
