/* Base & Typography */
html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

/* Selection color */
::selection {
    background-color: #1B4332;
    color: #FDFBF7;
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #FDFBF7;
}
::-webkit-scrollbar-thumb {
    background: #aed0bc;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #7fbf9c;
}

/* Navbar transition */
#navbar {
    background: transparent;
}

#navbar.scrolled {
    background: rgba(253, 251, 247, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(27, 67, 50, 0.08);
}

#navbar.scrolled .font-serif,
#navbar.scrolled .font-sans {
    color: #1B4332 !important;
}

#navbar.scrolled a:not([href^="tel:"]) {
    color: #1B4332 !important;
}

/* Mobile menu */
#mobileMenu {
    pointer-events: none;
}
#mobileMenu.open {
    pointer-events: auto;
}

/* Service cards */
.service-card {
    will-change: transform;
}

/* Scroll reveal animations */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

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

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
    html {
        scroll-behavior: auto;
    }
    .service-card,
    a,
    button {
        transition: none;
    }
}

/* Form select arrow */
select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%231B4332' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    appearance: none;
    -webkit-appearance: none;
}

/* Smooth anchor offset for fixed nav */
section[id] {
    scroll-margin-top: 80px;
}

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