/* Custom styles for Terrell Construction and Flooring */

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

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #f5f0e8;
}
::-webkit-scrollbar-thumb {
    background: #c9a84c;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #b8943f;
}

/* Selection color */
::selection {
    background: #c9a84c;
    color: #0a1628;
}

/* Navbar transition */
#navbar {
    transition: background-color 0.4s ease, box-shadow 0.4s ease, padding 0.4s ease;
}

#navbar.scrolled {
    background-color: rgba(250, 248, 244, 0.97);
    box-shadow: 0 1px 20px rgba(10, 22, 40, 0.08);
    backdrop-filter: blur(10px);
}

#navbar.scrolled .nav-link {
    color: #132238;
}

#navbar.scrolled .menu-line {
    background-color: #0a1628;
}

/* Hero animations */
.hero-anim {
    animation: fadeUp 0.8s ease forwards;
    opacity: 0;
}
.hero-anim:nth-child(1) { animation-delay: 0.2s; }
.hero-anim:nth-child(2) { animation-delay: 0.4s; }
.hero-anim:nth-child(3) { animation-delay: 0.6s; }
.hero-anim:nth-child(4) { animation-delay: 0.8s; }
.hero-anim:nth-child(5) { animation-delay: 1.0s; }
.hero-anim:nth-child(6) { animation-delay: 1.2s; }

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Scroll reveal animations */
.scroll-reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

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

/* Stagger children */
.scroll-reveal.delay-1 { transition-delay: 0.1s; }
.scroll-reveal.delay-2 { transition-delay: 0.2s; }
.scroll-reveal.delay-3 { transition-delay: 0.3s; }
.scroll-reveal.delay-4 { transition-delay: 0.4s; }
.scroll-reveal.delay-5 { transition-delay: 0.5s; }
.scroll-reveal.delay-6 { transition-delay: 0.6s; }

/* Mobile menu */
#mobileMenu.open {
    opacity: 1;
    pointer-events: all;
}

#mobileMenu .mobile-link {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

#mobileMenu.open .mobile-link {
    opacity: 1;
    transform: translateY(0);
}

#mobileMenu.open .mobile-link:nth-child(1) { transition-delay: 0.1s; }
#mobileMenu.open .mobile-link:nth-child(2) { transition-delay: 0.2s; }
#mobileMenu.open .mobile-link:nth-child(3) { transition-delay: 0.3s; }
#mobileMenu.open .mobile-link:nth-child(4) { transition-delay: 0.4s; }

/* Hamburger animation */
.menu-line {
    transition: transform 0.3s ease, opacity 0.3s ease, width 0.3s ease;
}

#menuBtn.active .menu-line:nth-child(1) {
    transform: translateY(4px) rotate(45deg);
}

#menuBtn.active .menu-line:nth-child(2) {
    opacity: 0;
}

#menuBtn.active .menu-line:nth-child(3) {
    transform: translateY(-4px) rotate(-45deg);
    width: 24px;
}

/* Gold accent hover on service cards */
.group:hover .font-serif {
    color: #c9a84c;
}

/* Image lazy loading fade-in */
img {
    opacity: 1;
    transition: opacity 0.3s ease;
}

/* Form focus styles */
input:focus,
select:focus,
textarea:focus {
    outline: none;
    box-shadow: 0 0 0 1px #c9a84c;
}

/* Subtle gold shimmer on buttons */
button,
a {
    position: relative;
    overflow: hidden;
}

/* Decorative divider */
.divider-gold {
    display: flex;
    align-items: center;
    gap: 1rem;
}
.divider-gold::before,
.divider-gold::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #c9a84c;
}
