/* Custom styles for Pizza Bob's Stryker */

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

/* Scroll reveal base - content always visible by default */
.scroll-reveal {
    opacity: 1;
    transform: none;
    transition: opacity 0.6s ease, transform 0.6s ease;
}

/* Scroll reveal for above-the-fold (hero) - no animation needed */
#hero .scroll-reveal {
    opacity: 1;
    transform: none;
}

/* Scroll reveal for below-the-fold sections */
@media (prefers-reduced-motion: no-preference) {
    .scroll-reveal.animated {
        opacity: 0;
        transform: translateY(30px);
    }
    
    .scroll-reveal.animated.revealed {
        opacity: 1;
        transform: translateY(0);
    }
    
    /* Staggered delays */
    .scroll-reveal.animated:nth-child(2) { transition-delay: 0.1s; }
    .scroll-reveal.animated:nth-child(3) { transition-delay: 0.2s; }
    .scroll-reveal.animated:nth-child(4) { transition-delay: 0.3s; }
}

/* Navbar transition */
#navbar.scrolled {
    background: rgba(255, 255, 255, 0.97);
    backdrop-blur-lg;
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.08);
}

#navbar.scrolled .nav-text {
    color: #1e3a5f;
}

#navbar.scrolled .nav-subtext {
    color: #0d9488;
}

#navbar.scrolled .nav-link {
    color: #334155;
}

#navbar.scrolled .nav-link:hover {
    color: #0d9488;
}

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

#mobile-menu.open {
    max-height: 500px;
    opacity: 1;
}

/* Mobile link hover */
.mobile-link {
    display: block;
    padding: 0.5rem 0;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #0f766e;
}

/* Selection color */
::selection {
    background: #0d9488;
    color: white;
}

/* Card hover effects */
.group:hover .group-hover\:scale-110 {
    transform: scale(1.1);
}

/* Floating card animations */
@keyframes float-slow {
    0%, 100% { transform: translateY(0px) rotate(2deg); }
    50% { transform: translateY(-10px) rotate(2deg); }
}

@keyframes float-medium {
    0%, 100% { transform: translateY(0px) rotate(-1deg); }
    50% { transform: translateY(-8px) rotate(-1deg); }
}

@keyframes float-fast {
    0%, 100% { transform: translateY(0px) rotate(1deg); }
    50% { transform: translateY(-6px) rotate(1deg); }
}

/* Apply floating animations to hero stat cards */
@media (min-width: 1024px) {
    .absolute.top-0.right-0 {
        animation: float-slow 6s ease-in-out infinite;
    }
    .absolute.top-40.left-0 {
        animation: float-medium 5s ease-in-out infinite;
    }
    .absolute.bottom-8.right-8 {
        animation: float-fast 4s ease-in-out infinite;
    }
}

/* Image loading placeholder */
img {
    background-color: #e7e5e4;
}

/* Focus styles for accessibility */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #0d9488;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Reduce motion preference */
@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;
    }
}

/* Print styles */
@media print {
    nav, .scroll-reveal, #gallery {
        display: none;
    }
    
    body {
        color: #000;
        background: #fff;
    }
}
