/* ===== CUSTOM STYLES FOR EMERALD'S SALON ===== */

/* Base styles */
html {
    scroll-behavior: smooth;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Selection color */
::selection {
    background-color: #f9d0d9;
    color: #800020;
}

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.animate-fade-in-up {
    animation: fadeInUp 0.8s ease-out forwards;
}

.animate-fade-in {
    animation: fadeIn 1s ease-out forwards;
}

/* ===== SCROLL REVEAL ===== */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}

.reveal[data-reveal="hidden"] {
    opacity: 0;
    transform: translateY(30px);
}

@media (prefers-reduced-motion: no-preference) {
    .reveal[data-reveal="hidden"] {
        opacity: 0;
        transform: translateY(30px);
    }
}

/* ===== NAVBAR ===== */
#navbar.scrolled {
    background: rgba(254, 252, 251, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 20px rgba(128, 0, 32, 0.08);
}

#navbar.scrolled .nav-link {
    color: #4b5563;
}

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

#navbar.scrolled .font-serif {
    color: #800020;
}

/* ===== MOBILE MENU ===== */
.mobile-menu-open {
    opacity: 1 !important;
    visibility: visible !important;
}

/* ===== BUTTON HOVER EFFECTS ===== */
a, button {
    -webkit-tap-highlight-color: transparent;
}

/* ===== SMOOTH SCROLL OFFSET ===== */
section[id] {
    scroll-margin-top: 80px;
}

/* ===== FORM STYLES ===== */
input:focus,
select:focus,
textarea:focus {
    border-color: #f0a8b8 !important;
    box-shadow: 0 0 0 4px rgba(244, 168, 184, 0.15) !important;
}

/* ===== GALLERY HOVER ===== */
.overflow-hidden img {
    transition: transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* ===== BACK TO TOP ===== */
#back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

/* ===== RESPONSIVE ADJUSTMENTS ===== */
@media (max-width: 768px) {
    section[id] {
        scroll-margin-top: 70px;
    }
    
    #hero h1 {
        font-size: 2.75rem;
    }
    
    #hero h1 br {
        display: none;
    }
    
    #hero h1::after {
        content: '';
        display: block;
    }
}

@media (max-width: 640px) {
    #hero h1 {
        font-size: 2.25rem;
    }
}

/* ===== ACCESSIBILITY ===== */
@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;
    }
    
    .reveal {
        opacity: 1 !important;
        transform: none !important;
    }
}

/* Focus visible for keyboard navigation */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid #800020;
    outline-offset: 2px;
    border-radius: 4px;
}
