/* Custom styles for Jones Jr B Webb DDS */

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

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #fafaf8;
}
::-webkit-scrollbar-thumb {
    background: #d6d3c8;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #b8b3a5;
}

/* Nav scroll state */
#nav.scrolled {
    background: rgba(253, 251, 247, 0.92);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(0,0,0,0.06), 0 4px 20px rgba(0,0,0,0.04);
}

/* Scroll reveal animations */
.scroll-reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s cubic-bezier(0.22, 1, 0.36, 1), transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

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

/* Staggered children */
.scroll-reveal-parent > * {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s cubic-bezier(0.22, 1, 0.36, 1), transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

.scroll-reveal-parent.revealed > *:nth-child(1) { transition-delay: 0s; opacity: 1; transform: translateY(0); }
.scroll-reveal-parent.revealed > *:nth-child(2) { transition-delay: 0.08s; opacity: 1; transform: translateY(0); }
.scroll-reveal-parent.revealed > *:nth-child(3) { transition-delay: 0.16s; opacity: 1; transform: translateY(0); }
.scroll-reveal-parent.revealed > *:nth-child(4) { transition-delay: 0.24s; opacity: 1; transform: translateY(0); }
.scroll-reveal-parent.revealed > *:nth-child(5) { transition-delay: 0.32s; opacity: 1; transform: translateY(0); }
.scroll-reveal-parent.revealed > *:nth-child(6) { transition-delay: 0.40s; opacity: 1; transform: translateY(0); }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .scroll-reveal,
    .scroll-reveal-parent > * {
        opacity: 1;
        transform: none;
        transition: none;
    }
    html {
        scroll-behavior: auto;
    }
}

/* Mobile menu */
#mobile-menu {
    animation: slideDown 0.25s cubic-bezier(0.22, 1, 0.36, 1);
}

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

/* Pulse animation for badge */
@keyframes softPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}

.animate-pulse {
    animation: softPulse 2.5s ease-in-out infinite;
}

/* Button focus styles */
button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid #C4654A;
    outline-offset: 2px;
}

/* Selection color */
::selection {
    background: #f9c7b8;
    color: #5e2a20;
}
