/* Custom styles for Dr. Oslak Dental website */

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

/* Floating card animations */
.floating-card {
    animation: float 6s ease-in-out infinite;
}

.floating-card:nth-child(2) {
    animation-delay: -2s;
    animation-duration: 7s;
}

.floating-card:nth-child(3) {
    animation-delay: -4s;
    animation-duration: 5s;
}

.floating-card:nth-child(4) {
    animation-delay: -1s;
    animation-duration: 8s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-12px);
    }
}

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

.nav-scrolled .nav-link {
    color: #1e293b !important;
}

.nav-scrolled .nav-logo-text {
    color: #0f172a !important;
}

/* Intersection observer animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.visible {
    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; }

/* Hero section gradient overlay fix */
#hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(2, 6, 23, 0.85) 0%, rgba(2, 6, 23, 0.6) 50%, rgba(2, 6, 23, 0.4) 100%);
    z-index: 1;
}

#hero > .relative {
    position: relative;
    z-index: 2;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #64748b;
}

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

/* Mobile menu transition */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

#mobile-menu.open {
    max-height: 400px;
}

/* Service card hover glow */
.group:hover .service-glow {
    opacity: 1;
}

.service-glow {
    opacity: 0;
    transition: opacity 0.5s ease;
}

/* Back to top button */
#back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Input focus styles */
input:focus,
textarea:focus,
select:focus {
    outline: none;
}

/* Print styles */
@media print {
    nav, #back-to-top, .floating-card {
        display: none !important;
    }
    
    #hero {
        min-height: auto !important;
        padding: 2rem 0 !important;
    }
}
