/* ============================================
   Martinez Construction — Custom Styles
   ============================================ */

/* --- Base & Typography --- */
html {
    scroll-behavior: smooth;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

::selection {
    background-color: #1B5E3B;
    color: #FAF7F0;
}

/* --- Floating Card Animations --- */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-12px); }
}

@keyframes float-delayed {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-8px); }
}

.animate-float {
    animation: float 4s ease-in-out infinite;
}

.animate-float-delayed {
    animation: float-delayed 4.5s ease-in-out infinite;
    animation-delay: 0.5s;
}

/* --- Scroll Reveal (progressive enhancement) --- */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.7s ease, transform 0.7s ease;
    }
    
    .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; }
    .reveal-delay-5 { transition-delay: 0.5s; }
    .reveal-delay-6 { transition-delay: 0.6s; }
}

/* --- Navbar Scroll State --- */
.nav-scrolled {
    background: rgba(250, 247, 240, 0.95) !important;
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(27, 94, 59, 0.08);
}

.nav-scrolled .nav-link {
    color: #374151 !important;
}

.nav-scrolled .nav-link:hover {
    color: #1B5E3B !important;
}

.nav-scrolled .logo-text {
    color: #052e16 !important;
}

.nav-scrolled .logo-sub {
    color: #1B5E3B !important;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #14472C;
}

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

/* --- Button Ripple Effect --- */
button, a {
    -webkit-tap-highlight-color: transparent;
}

/* --- Smooth Image Loading --- */
img {
    opacity: 1;
    transition: opacity 0.3s ease;
}

img[data-src] {
    opacity: 0;
}

/* --- Print Styles --- */
@media print {
    nav, #contact-form, .reveal { display: none; }
    body { background: white; }
    section { page-break-inside: avoid; }
}
