/* 
 * Linda Hair Braiding - Custom Styles
 * Classic & Elegant Design System
 */

/* Base Styles & Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Montserrat', sans-serif;
    line-height: 1.6;
    color: #0f172a;
    background-color: #fafaf9;
    overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 600;
    line-height: 1.2;
}

/* Custom Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

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

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

.animate-slide-up {
    animation: slideUp 1s ease-out 0.3s forwards;
    opacity: 0;
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

/* Scroll Reveal Animation */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.reveal.hidden {
    opacity: 0;
    transform: translateY(30px);
}

/* Navbar Styles */
.navbar {
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.navbar.scrolled {
    background-color: rgba(15, 23, 42, 0.95);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

/* Button Hover Effects */
button, a {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Card Hover Effects */
.group:hover .group-hover\:scale-110 {
    transform: scale(1.1);
}

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

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

::-webkit-scrollbar-thumb {
    background: #d4af37;
    border-radius: 5px;
}

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

/* Selection Color */
::selection {
    background-color: #d4af37;
    color: #0f172a;
}

/* Focus Styles for Accessibility */
*:focus-visible {
    outline: 2px solid #d4af37;
    outline-offset: 2px;
}

/* Mobile Menu Transitions */
#mobile-menu {
    transition: max-height 0.3s ease-in-out, opacity 0.3s ease-in-out;
}

#mobile-menu.hidden {
    max-height: 0;
    opacity: 0;
}

#mobile-menu:not(.hidden) {
    max-height: 400px;
    opacity: 1;
}

/* Image Loading Placeholder */
img {
    background: linear-gradient(90deg, #e7e5e4 25%, #d6d9db 50%, #e7e5e4 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

img[src] {
    animation: none;
    background: none;
}

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

/* High Contrast Mode Support */
@media (forced-colors: active) {
    .bg-gold-400 {
        background-color: ButtonText;
    }
    
    .text-gold-400 {
        color: ButtonText;
    }
}

/* Print Styles */
@media print {
    .no-print {
        display: none !important;
    }
    
    body {
        color: #000;
        background: #fff;
    }
    
    a {
        text-decoration: underline;
    }
}

/* Utility Classes */
.text-shadow {
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.border-gradient {
    border-image: linear-gradient(135deg, #d4af37, #b08d1f) 1;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    html {
        font-size: 15px;
    }
    
    .font-serif {
        font-size: 1.75rem;
    }
}

@media (max-width: 480px) {
    html {
        font-size: 14px;
    }
}

/* Performance Optimizations */
img, video {
    will-change: transform;
}

.reveal {
    will-change: opacity, transform;
}
