/* Custom styles for Gary W Lyman Plastering */

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

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
    background: #94a3b8;
    border-radius: 9999px;
}
::-webkit-scrollbar-thumb:hover {
    background: #64748b;
}

/* Navbar scroll state */
nav.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.08);
}

/* Selection color */
::selection {
    background: #99f6e4;
    color: #042f2e;
}

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

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    .float-card {
        animation: none !important;
    }
}

/* Scroll reveal base - content is visible by default */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

/* Only apply hidden state when JS adds the class */
.reveal.revealed {
    opacity: 0;
    transform: translateY(30px);
}

/* Only animate if user prefers motion */
@media (prefers-reduced-motion: no-preference) {
    .reveal.revealed.animated {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Floating card animations */
@keyframes float-slow {
    0%, 100% { transform: translateY(0px) rotate(2deg); }
    50% { transform: translateY(-12px) rotate(2deg); }
}
@keyframes float-medium {
    0%, 100% { transform: translateY(0px) rotate(-1deg); }
    50% { transform: translateY(-8px) rotate(-1deg); }
}
@keyframes float-fast {
    0%, 100% { transform: translateY(0px) rotate(1deg); }
    50% { transform: translateY(-10px) rotate(1deg); }
}

.float-slow { animation: float-slow 6s ease-in-out infinite; }
.float-medium { animation: float-medium 5s ease-in-out infinite; }
.float-fast { animation: float-fast 4s ease-in-out infinite; }

/* Stagger animation delays */
.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; }
.delay-500 { animation-delay: 0.5s; }

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

/* Button ripple effect */
button, a {
    position: relative;
    overflow: visible;
}

/* Image lazy load fade-in (progressive enhancement) */
img[loading="lazy"] {
    opacity: 1;
    transition: opacity 0.3s ease;
}
