/* Custom styles for Trailtown Treasures */

html {
    scroll-behavior: smooth;
}

body {
    overflow-x: hidden;
}

/* Navbar scroll effect */
.nav-scrolled {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(123, 67, 151, 0.08);
}

.nav-scrolled .nav-link {
    color: rgb(123, 67, 151) !important;
}

.nav-scrolled .font-serif {
    color: rgb(93, 50, 115) !important;
}

/* Mobile menu animations */
.mobile-link {
    position: relative;
}

.mobile-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: rgb(245, 166, 35);
    transition: width 0.3s ease;
}

.mobile-link:hover::after {
    width: 100%;
}

/* Hero image parallax-like effect */
.hero-img-container {
    transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Section reveal animations */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

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

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }
.reveal-delay-5 { transition-delay: 0.5s; }
.reveal-delay-6 { transition-delay: 0.6s; }

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

::-webkit-scrollbar-track {
    background: rgb(249, 243, 252);
}

::-webkit-scrollbar-thumb {
    background: rgb(212, 173, 239);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgb(155, 89, 182);
}

/* Input autofill style */
input:-webkit-autofill,
textarea:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 30px rgb(255, 255, 255) inset !important;
    -webkit-text-fill-color: rgb(55, 34, 77) !important;
}

/* Form focus animations */
input:focus,
textarea:focus {
    animation: focusPulse 2s ease-in-out infinite;
}

@keyframes focusPulse {
    0%, 100% { box-shadow: 0 0 0 4px rgb(243, 232, 250); }
    50% { box-shadow: 0 0 0 6px rgb(232, 208, 245); }
}

/* Floating card animation */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-8px); }
}

.floating {
    animation: float 4s ease-in-out infinite;
}

/* Decorative dot animation */
@keyframes dotPulse {
    0%, 100% { opacity: 0.6; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.2); }
}

.dot-pulse {
    animation: dotPulse 2s ease-in-out infinite;
}

.dot-pulse:nth-child(2) { animation-delay: 0.2s; }
.dot-pulse:nth-child(3) { animation-delay: 0.4s; }
.dot-pulse:nth-child(4) { animation-delay: 0.6s; }
.dot-pulse:nth-child(5) { animation-delay: 0.8s; }
.dot-pulse:nth-child(6) { animation-delay: 1s; }
.dot-pulse:nth-child(7) { animation-delay: 1.2s; }
.dot-pulse:nth-child(8) { animation-delay: 1.4s; }
.dot-pulse:nth-child(9) { animation-delay: 1.6s; }

/* Smooth hover for cards */
.group {
    transform: translateZ(0);
}

/* Subtle gradient text for special elements */
.gradient-text {
    background: linear-gradient(135deg, rgb(123, 67, 151) 0%, rgb(184, 125, 230) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Mobile menu transition */
#mobileMenu {
    max-height: 0;
    opacity: 0;
}

#mobileMenu.open {
    max-height: 300px;
    opacity: 1;
}
