/* Custom styles for J and A Custom Construction */

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

/* Base styles */
body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Service card hover effect */
.service-card {
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #FF6B4A, #ff9a8b);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.service-card:hover::before {
    transform: scaleX(1);
}

/* Project card overlay transition */
.group:hover .group-hover\:scale-105 {
    transition: transform 0.5s ease;
}

/* Mobile menu animation */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

#mobile-menu.active {
    max-height: 300px;
}

/* Select dropdown styling */
select option {
    background-color: #1f2937;
    color: #f3f4f6;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #4b515a;
}

/* Focus visible styles */
*:focus-visible {
    outline: 2px solid #FF6B4A;
    outline-offset: 2px;
}

/* Selection color */
::selection {
    background-color: rgba(255, 107, 74, 0.3);
    color: #f3f4f6;
}

/* Reduce motion preference */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    
    .service-card::before,
    .group:hover .group-hover\:scale-105,
    * {
        transition: none !important;
        animation: none !important;
    }
}

/* Tablet and up */
@media (min-width: 768px) {
    .font-serif {
        font-size: clamp(2rem, 4vw, 3.5rem);
    }
}

/* Project cards */
.group {
    position: relative;
    overflow: hidden;
}

/* Fade-in animation for scroll reveals */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    opacity: 0;
    animation: fadeInUp 0.6s ease forwards;
}

/* Pulse animation for dot */
@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;
}
