/* Base styles */
html {
    scroll-behavior: smooth;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: #f8f9fc;
}
::-webkit-scrollbar-thumb {
    background: #c8cde0;
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: #a3aac8;
}

/* Selection */
::selection {
    background: #d4a017;
    color: #1a2238;
}

/* Navigation */
.nav-scrolled {
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(26, 34, 56, 0.06);
}

.nav-scrolled .nav-link {
    color: #5c6a96;
}

.nav-scrolled .nav-link:hover {
    color: #1a2238;
}

.nav-scrolled .menu-line {
    background: #1a2238;
}

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

#mobile-menu.active .mobile-menu-link {
    animation: fadeInUp 0.4s ease forwards;
}

#mobile-menu.active .mobile-menu-link:nth-child(1) { animation-delay: 0.05s; }
#mobile-menu.active .mobile-menu-link:nth-child(2) { animation-delay: 0.1s; }
#mobile-menu.active .mobile-menu-link:nth-child(3) { animation-delay: 0.15s; }
#mobile-menu.active .mobile-menu-link:nth-child(4) { animation-delay: 0.2s; }

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

/* Menu toggle animation */
.menu-toggle.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(3px, 3px);
}
.menu-toggle.active .menu-line:nth-child(2) {
    opacity: 0;
}
.menu-toggle.active .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(3px, -3px);
    width: 1.5rem;
}

/* Service cards */
.service-card {
    transition: background-color 0.5s ease;
}

/* Gallery items */
.gallery-item {
    position: relative;
    cursor: pointer;
}

/* Process steps */
.process-step {
    padding-top: 1.5rem;
}

/* Form inputs */
input, select, textarea {
    transition: border-color 0.3s ease;
}

/* Focus styles */
input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: #d4a017;
}

/* Smooth image loading */
img {
    opacity: 1;
    transition: opacity 0.3s ease;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    
    .gallery-item img,
    .service-card,
    .nav-scrolled {
        transition: none;
    }
    
    .gallery-item:hover img {
        transform: none;
    }
}

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

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

@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 1;
        transform: translateY(0);
    }
}
