/* ============================================
   Sammamish Highlands Family Dentistry
   Custom Styles
   ============================================ */

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

/* Selection */
::selection {
    background-color: #FF6B5E;
    color: white;
}

/* ============================================
   Hero Animations
   ============================================ */
.hero-anim {
    opacity: 0;
    transform: translateY(24px);
    animation: heroReveal 0.9s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.hero-anim:nth-child(1) { animation-delay: 0.1s; }
.hero-anim:nth-child(2) { animation-delay: 0.25s; }
.hero-anim:nth-child(3) { animation-delay: 0.4s; }
.hero-anim:nth-child(4) { animation-delay: 0.55s; }

@keyframes heroReveal {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================
   Scroll Reveal
   ============================================ */
.reveal {
    opacity: 0;
    transform: translateY(32px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.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; }

/* ============================================
   Scroll Indicator
   ============================================ */
@keyframes scrollIndicator {
    0% { transform: translateY(-100%); }
    100% { transform: translateY(16px); }
}

.animate-scroll-indicator {
    animation: scrollIndicator 1.5s ease-in-out infinite;
}

/* ============================================
   Navbar
   ============================================ */
#navbar {
    background: rgba(255, 255, 255, 0);
    backdrop-filter: blur(0px);
    transition: background 0.4s ease, backdrop-filter 0.4s ease, box-shadow 0.4s ease;
}

#navbar.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.06);
}

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

#mobile-menu.closed {
    opacity: 0;
    pointer-events: none;
}

/* Menu lines animation */
.menu-line {
    display: block;
}

body.menu-open .menu-line:nth-child(1) {
    transform: translateY(4px) rotate(45deg);
}

body.menu-open .menu-line:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

body.menu-open .menu-line:nth-child(3) {
    width: 6px;
}

/* Mobile links */
.mobile-link {
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.4s ease, transform 0.4s ease, color 0.3s ease;
}

#mobile-menu.open .mobile-link {
    opacity: 1;
    transform: translateY(0);
}

#mobile-menu.open .mobile-link:nth-child(1) { transition-delay: 0.1s; }
#mobile-menu.open .mobile-link:nth-child(2) { transition-delay: 0.15s; }
#mobile-menu.open .mobile-link:nth-child(3) { transition-delay: 0.2s; }
#mobile-menu.open .mobile-link:nth-child(4) { transition-delay: 0.25s; }
#mobile-menu.open .mobile-link:nth-child(5) { transition-delay: 0.3s; }

/* ============================================
   Form Focus Styles
   ============================================ */
input:focus,
textarea:focus {
    outline: none;
}

input::placeholder,
textarea::placeholder {
    color: #d1d5db;
}

/* ============================================
   Smooth hover transitions for service cards
   ============================================ */
.group {
    transition: background-color 0.5s ease;
}

/* ============================================
   Image hover
   ============================================ */
.aspect-\[4\/5\] img {
    transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.aspect-\[4\/5\]:hover img {
    transform: scale(1.03);
}

/* ============================================
   Responsive adjustments
   ============================================ */
@media (max-width: 767px) {
    .aspect-\[4\/5\]:hover img {
        transform: none;
    }
    
    .absolute.-bottom-6.-right-6 {
        position: relative;
        bottom: auto;
        right: auto;
        margin-top: 1.5rem;
    }
}

/* ============================================
   Print styles
   ============================================ */
@media print {
    #navbar,
    .animate-scroll-indicator {
        display: none;
    }
    
    body {
        color: #000;
        background: #fff;
    }
}
