/* Custom styles for Salt River Roofing */

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

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

::-webkit-scrollbar-track {
    background: #3b0764;
}

::-webkit-scrollbar-thumb {
    background: #9333ea;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a855f7;
}

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

@keyframes float-delayed {
    0%, 100% { transform: translateY(0px) rotate(-12deg); }
    50% { transform: translateY(-15px) rotate(-12deg); }
}

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

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

/* Service card hover glow */
.service-card:hover {
    box-shadow: 0 20px 60px rgba(245, 158, 11, 0.15), 0 0 0 1px rgba(245, 158, 11, 0.3);
}

/* Navbar scroll state */
.navbar-scrolled {
    background: rgba(59, 7, 100, 0.95) !important;
    backdrop-filter: blur(20px);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

/* Mobile menu transitions */
.mobile-link {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

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

.mobile-menu-open .mobile-link:nth-child(1) { transition-delay: 0.1s; }
.mobile-menu-open .mobile-link:nth-child(2) { transition-delay: 0.15s; }
.mobile-menu-open .mobile-link:nth-child(3) { transition-delay: 0.2s; }
.mobile-menu-open .mobile-link:nth-child(4) { transition-delay: 0.25s; }
.mobile-menu-open .mobile-link:nth-child(5) { transition-delay: 0.3s; }

/* Gallery hover */
.gallery-item::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 16px;
    border: 2px solid transparent;
    transition: border-color 0.5s ease;
    pointer-events: none;
}

.gallery-item:hover::after {
    border-color: rgba(251, 191, 36, 0.5);
}

/* Selection color */
::selection {
    background: rgba(245, 158, 11, 0.3);
    color: #fff;
}

/* Form select arrow */
select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23a855f7' 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;
    background-size: 1rem;
    padding-right: 2.5rem;
}

/* Intersection observer animations */
.fade-up {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger children */
.fade-up:nth-child(1) { transition-delay: 0.05s; }
.fade-up:nth-child(2) { transition-delay: 0.1s; }
.fade-up:nth-child(3) { transition-delay: 0.15s; }
.fade-up:nth-child(4) { transition-delay: 0.2s; }
.fade-up:nth-child(5) { transition-delay: 0.25s; }
.fade-up:nth-child(6) { transition-delay: 0.3s; }

/* Responsive adjustments */
@media (max-width: 768px) {
    .service-card {
        padding: 1.5rem !important;
    }
}
