/* ===== PRissy's Lashes — Custom Styles ===== */

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

/* ===== Reveal Animations (progressive enhancement) ===== */
/* Default state: all content is visible (no JS required) */
.reveal {
    opacity: 1;
    transform: none;
    transition: none;
}

/* When JS runs and user prefers motion, enable animations */
.js .reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

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

/* Stagger delays */
.js .service-card:nth-child(1) { transition-delay: 0.05s; }
.js .service-card:nth-child(2) { transition-delay: 0.1s; }
.js .service-card:nth-child(3) { transition-delay: 0.15s; }
.js .service-card:nth-child(4) { transition-delay: 0.2s; }
.js .service-card:nth-child(5) { transition-delay: 0.25s; }
.js .service-card:nth-child(6) { transition-delay: 0.3s; }

/* ===== Floating Card Animations ===== */
.floating-card {
    animation: float 4s ease-in-out infinite;
}

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

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

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

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

/* ===== Navbar Scroll State ===== */
#navbar.scrolled {
    background: rgba(254, 253, 248, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(45, 106, 79, 0.08);
}

/* ===== Mobile Menu ===== */
#mobileMenu.open {
    opacity: 1;
    pointer-events: all;
}

#mobileMenu .mobile-link {
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease, color 0.2s ease;
}

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

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

/* ===== Hamburger Animation ===== */
#menuBtn.active #menuIcon span:nth-child(1) {
    transform: rotate(45deg) translate(4px, 4px);
}

#menuBtn.active #menuIcon span:nth-child(2) {
    opacity: 0;
}

#menuBtn.active #menuIcon span:nth-child(3) {
    transform: rotate(-45deg) translate(4px, -4px);
}

/* ===== Selection Color ===== */
::selection {
    background: rgba(45, 106, 79, 0.2);
    color: #1B4332;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #8ec58e;
}

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

    .floating-card {
        animation: none;
    }
}

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

/* ===== Responsive Adjustments ===== */
@media (max-width: 640px) {
    .font-serif {
        line-height: 1.15;
    }
}
