/* Custom styles for Lawrence Kramer Medical Practice */

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

/* Custom selection color */
::selection {
    background-color: #a33420;
    color: #faf8f4;
}

/* Scroll reveal base - content is visible by default */
.scroll-reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

/* Only apply animation when JS adds the class and user prefers motion */
@media (prefers-reduced-motion: no-preference) {
    .scroll-reveal.animate-in {
        opacity: 1 !important;
        transform: translateY(0) !important;
    }
    
    .scroll-reveal {
        opacity: 0;
        transform: translateY(30px);
    }
}

/* Navbar transition states */
.nav-scrolled {
    background-color: rgba(250, 248, 244, 0.97) !important;
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.08);
}

/* Mobile menu animations */
.mobile-menu-link {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

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

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

/* Hamburger to X animation */
#menu-line-1.open {
    transform: rotate(45deg) translate(5px, 5px);
}

#menu-line-2.open {
    opacity: 0;
}

#menu-line-3.open {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Subtle hover effects on cards */
.group:hover .group-hover\:bg-terra-100 {
    background-color: #f9ddd3;
}

/* Focus styles for accessibility */
input:focus,
textarea:focus,
button:focus {
    outline: 2px solid #a33420;
    outline-offset: 2px;
}

/* Form input focus border */
input:focus,
textarea:focus {
    border-color: #a33420 !important;
}

/* Button hover lift effect */
button[type="submit"]:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(163, 52, 32, 0.3);
}

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

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #b0a99e;
}

/* Print styles */
@media print {
    nav, #contact-form, .scroll-reveal {
        display: block !important;
        opacity: 1 !important;
    }
    
    .bg-warmgray-900, .bg-terra-700 {
        background-color: #3d3732 !important;
    }
}
