/* Custom styles for Designer Cuts Hair Salon */

/* Hero animations */
.hero-subtitle {
    opacity: 0;
    transform: translateY(20px);
    animation: heroFadeUp 0.8s ease forwards 0.2s;
}

.hero-title {
    opacity: 0;
    transform: translateY(30px);
    animation: heroFadeUp 0.8s ease forwards 0.4s;
}

.hero-body {
    opacity: 0;
    transform: translateY(20px);
    animation: heroFadeUp 0.8s ease forwards 0.6s;
}

.hero-cta {
    opacity: 0;
    transform: translateY(20px);
    animation: heroFadeUp 0.8s ease forwards 0.8s;
}

.hero-scroll {
    opacity: 0;
    animation: heroFadeUp 0.8s ease forwards 1.2s;
}

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

/* Scroll reveal animations — progressive enhancement, only when JS runs and user prefers motion */
.reveal-section {
    /* Default: always visible, no hidden state */
}

@media (prefers-reduced-motion: no-preference) {
    .reveal-section.revealed {
        animation: revealUp 0.7s cubic-bezier(0.22, 0.61, 0.36, 1) forwards;
    }
}

@keyframes revealUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Navbar transition */
.navbar-scrolled {
    background-color: rgba(250, 249, 246, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(44, 92, 44, 0.08);
}

.navbar-scrolled .nav-link {
    color: #1c381c;
}

.navbar-scrolled .nav-link:hover {
    color: #3d7a3d;
}

/* Smooth image loading */
img {
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

/* Selection color */
::selection {
    background-color: #2c5c2c;
    color: #faf9f6;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #64a364;
}

/* Mobile menu animation */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.4s ease;
}

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

#mobile-menu.open > div {
    padding-top: 1rem;
    padding-bottom: 1rem;
}

/* Focus visible styles */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid #64a364;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Reduce 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;
    }

    .hero-subtitle,
    .hero-title,
    .hero-body,
    .hero-cta,
    .hero-scroll {
        opacity: 1;
        transform: none;
        animation: none;
    }
}
