/* Custom styles for Julie's Tax Service */

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

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #f0f4fa;
}
::-webkit-scrollbar-thumb {
    background: #d4a853;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #c49a3f;
}

/* Selection color */
::selection {
    background: #d4a853;
    color: #0f172a;
}

/* Navbar transition */
.navbar-scrolled {
    background: rgba(255, 255, 255, 0.97) !important;
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(15, 23, 42, 0.08);
}

.navbar-scrolled .nav-logo-text {
    color: #0f172a !important;
}

.navbar-scrolled .nav-logo-sub {
    color: #4c639f !important;
}

/* Hero animations */
.hero-content {
    animation: fadeInUp 0.8s ease-out both;
}

.hero-image {
    animation: fadeInRight 0.8s ease-out 0.2s both;
}

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

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

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

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

/* Staggered delays for grid items */
.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; }

/* Mobile menu */
#mobile-menu {
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.mobile-link {
    display: block;
    padding: 8px 0;
    border-bottom: 1px solid #f0f4fa;
    transition: color 0.2s ease, padding-left 0.2s ease;
}

.mobile-link:hover {
    color: #d4a853;
    padding-left: 8px;
}

/* Back to top button */
#back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

#back-to-top:hover {
    transform: translateY(-2px);
}

/* Focus styles for accessibility */
input:focus,
select:focus,
textarea:focus {
    outline: none;
}

/* Image hover effect */
.service-card img {
    transition: transform 0.5s ease;
}

.service-card:hover img {
    transform: scale(1.05);
}

/* Print styles */
@media print {
    nav, #back-to-top, #mobile-menu-btn {
        display: none !important;
    }
    
    body {
        color: #000;
        background: #fff;
    }
    
    .hero-content, .hero-image {
        animation: none;
    }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
    
    .scroll-reveal {
        opacity: 1;
        transform: none;
    }
}

/* Tablet adjustments */
@media (max-width: 768px) {
    .font-serif {
        font-size: clamp(1.75rem, 5vw, 2.5rem);
    }
}
