/* Custom styles for Dr. Hirano Medical Practice */

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

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

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

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

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

/* Selection color */
::selection {
    background: rgba(212, 160, 23, 0.3);
    color: #fefdf8;
}

/* Navbar styles */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: linear-gradient(90deg, #d4a017, #e6c04d);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Mobile menu */
.mobile-link {
    position: relative;
}

/* Service cards */
.service-card {
    transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                box-shadow 0.5s ease;
}

.service-card:hover {
    transform: translateY(-4px);
}

/* Fade-in animations */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger children */
.fade-in-stagger > * {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.fade-in-stagger.visible > *:nth-child(1) { transition-delay: 0.1s; }
.fade-in-stagger.visible > *:nth-child(2) { transition-delay: 0.2s; }
.fade-in-stagger.visible > *:nth-child(3) { transition-delay: 0.3s; }
.fade-in-stagger.visible > *:nth-child(4) { transition-delay: 0.4s; }
.fade-in-stagger.visible > *:nth-child(5) { transition-delay: 0.5s; }
.fade-in-stagger.visible > *:nth-child(6) { transition-delay: 0.6s; }

.fade-in-stagger.visible > * {
    opacity: 1;
    transform: translateY(0);
}

/* Gold shimmer effect for hero */
@keyframes shimmer {
    0% { background-position: -200% center; }
    100% { background-position: 200% center; }
}

.hero-gold-text {
    background: linear-gradient(
        90deg,
        #f5d77a 0%,
        #e6c04d 25%,
        #d4a017 50%,
        #e6c04d 75%,
        #f5d77a 100%
    );
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: shimmer 4s linear infinite;
}

/* Pulse animation for scroll indicator */
@keyframes scrollPulse {
    0%, 100% { opacity: 0.4; transform: scaleY(1); }
    50% { opacity: 0.8; transform: scaleY(1.2); }
}

/* Input autofill styling */
input:-webkit-autofill,
textarea:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 30px #0a0f0d inset !important;
    -webkit-text-fill-color: #fefdf8 !important;
}

/* Image hover zoom */
img {
    transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .font-serif {
        font-size: clamp(2rem, 8vw, 3rem);
    }
}

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