/* Custom styles for JKN Hair Design */

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

/* Navbar scroll state */
.nav-scrolled {
    background: rgba(250, 249, 247, 0.95) !important;
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.08);
}

.nav-scrolled .font-display {
    color: #1d4728 !important;
}

/* Mobile menu animations */
.menu-line {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

#menu-toggle.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

#menu-toggle.active .menu-line:nth-child(2) {
    opacity: 0;
}

#menu-toggle.active .menu-line:nth-child(3) {
    width: 1.5rem;
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Mobile links */
.mobile-link {
    display: block;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(29, 71, 40, 0.1);
    transition: color 0.2s;
}

.mobile-link:last-child {
    border-bottom: none;
}

/* Scroll reveal animations */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1), 
                transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

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

/* Stagger children */
.reveal-grid > * {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal-grid.revealed > *:nth-child(1) { transition-delay: 0.05s; }
.reveal-grid.revealed > *:nth-child(2) { transition-delay: 0.1s; }
.reveal-grid.revealed > *:nth-child(3) { transition-delay: 0.15s; }
.reveal-grid.revealed > *:nth-child(4) { transition-delay: 0.2s; }
.reveal-grid.revealed > *:nth-child(5) { transition-delay: 0.25s; }
.reveal-grid.revealed > *:nth-child(6) { transition-delay: 0.3s; }

@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(24px);
    }
    
    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Selection color */
::selection {
    background: #97c5a3;
    color: #1d4728;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #6aad78;
}

/* Button focus styles */
a:focus-visible, button:focus-visible {
    outline: 2px solid #448f54;
    outline-offset: 2px;
    border-radius: 4px;
}
