/* ===== Base & Reset ===== */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    margin: 0;
    overflow-x: hidden;
}

::selection {
    background: #047857;
    color: #fefdf8;
}

/* ===== Hero Background Pattern ===== */
.hero-bg-pattern {
    background-image: radial-gradient(circle at 1px 1px, rgba(4, 120, 87, 0.15) 1px, transparent 0);
    background-size: 32px 32px;
}

/* ===== Specialties Pattern ===== */
.specialties-pattern {
    background-image: radial-gradient(circle at 1px 1px, rgba(255, 255, 255, 0.12) 1px, transparent 0);
    background-size: 24px 24px;
}

/* ===== Floating Card Animations ===== */
@keyframes float-slow {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-10px) rotate(0.5deg); }
}

@keyframes float-medium {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-8px) rotate(-0.5deg); }
}

@keyframes float-fast {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-6px) rotate(0.5deg); }
}

.floating-card {
    animation: float-slow 4s ease-in-out infinite;
}

.card-top-right {
    animation-delay: 0s;
    animation-duration: 4s;
}

.card-bottom-left {
    animation-delay: -1.5s;
    animation-duration: 5s;
}

.card-mid-right {
    animation-delay: -3s;
    animation-duration: 4.5s;
}

/* ===== Scroll Reveal (progressive enhancement) ===== */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(24px);
        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);
    }

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

    .product-card {
        opacity: 0;
        transform: translateY(20px);
        transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    }

    .product-card.revealed {
        opacity: 1;
        transform: translateY(0);
    }

    .specialty-card {
        opacity: 0;
        transform: translateY(16px);
        transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    }

    .specialty-card.revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== Navbar Scroll State ===== */
.navbar.scrolled {
    box-shadow: 0 1px 20px rgba(4, 78, 59, 0.08);
    background: rgba(254, 253, 248, 0.95);
}

/* ===== Mobile Menu ===== */
.mobile-menu {
    animation: slideDown 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== Form Focus Styles ===== */
input:focus,
select:focus,
textarea:focus {
    outline: none;
}

/* ===== Smooth image loading ===== */
img {
    display: block;
    max-width: 100%;
}

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

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

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

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

/* ===== Print styles ===== */
@media print {
    .navbar, .floating-card, .mobile-menu {
        display: none !important;
    }
    body {
        background: white;
        color: black;
    }
}
