/* Custom styles for Modern Quality Construction */

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

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
    background: #94a3c4;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #6b82b0;
}

/* Selection color */
::selection {
    background: #D4A84B;
    color: #1B2A4A;
}

/* Navbar transition */
#navbar.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    box-shadow: 0 1px 20px rgba(27, 42, 74, 0.08);
}

/* Nav links underline effect */
.nav-link {
    position: relative;
}
.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: #D4A84B;
    transition: width 0.3s ease;
}
.nav-link:hover::after {
    width: 100%;
}

/* Service card hover effect */
.service-card {
    transform: translateY(0);
}
.service-card:hover {
    transform: translateY(-4px);
}

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

/* Mobile menu button animation */
#menuBtn.active #menuIcon span:nth-child(1) {
    transform: rotate(45deg) translate(4px, 4px);
}
#menuBtn.active #menuIcon span:nth-child(2) {
    opacity: 0;
}
#menuBtn.active #menuIcon span:nth-child(3) {
    transform: rotate(-45deg) translate(4px, -4px);
    width: 1.25rem;
}

/* Mobile link animation */
.mobile-link {
    opacity: 0;
    transform: translateY(20px);
    transition: all 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.15s; }
#mobileMenu.open .mobile-link:nth-child(3) { transition-delay: 0.2s; }
#mobileMenu.open .mobile-link:nth-child(4) { transition-delay: 0.25s; }
#mobileMenu.open .mobile-link:nth-child(5) { transition-delay: 0.3s; }

/* Scroll reveal animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}
.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered reveal for service cards */
.service-card:nth-child(1) { transition-delay: 0.05s; }
.service-card:nth-child(2) { transition-delay: 0.1s; }
.service-card:nth-child(3) { transition-delay: 0.15s; }
.service-card:nth-child(4) { transition-delay: 0.2s; }
.service-card:nth-child(5) { transition-delay: 0.25s; }
.service-card:nth-child(6) { transition-delay: 0.3s; }

/* Floating card animation */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}
.floating {
    animation: float 4s ease-in-out infinite;
}

/* Pulse dot animation */
@keyframes pulse-dot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.2); }
}
.animate-pulse {
    animation: pulse-dot 2s ease-in-out infinite;
}

/* Image hover zoom */
.group:hover .group-hover\:scale-105 {
    transition: transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Form focus styles */
input:focus, textarea:focus, select:focus {
    box-shadow: 0 0 0 3px rgba(212, 168, 75, 0.15);
}

/* Button ripple effect */
button {
    position: relative;
    overflow: hidden;
}
button::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, rgba(255,255,255,0.2) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s;
}
button:hover::after {
    opacity: 1;
}
