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

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

/* Selection */
::selection {
    background-color: #C65D3E;
    color: white;
}

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

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

::-webkit-scrollbar-thumb {
    background: #C65D3E;
    border-radius: 3px;
}

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

/* Navigation */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background-color: #C65D3E;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Navbar scroll state */
.navbar-scrolled {
    background-color: rgba(250, 247, 242, 0.95) !important;
    backdrop-filter: blur(10px);
    box-shadow: 0 1px 0 rgba(26, 26, 26, 0.08);
}

/* Mobile menu */
.mobile-menu-open {
    opacity: 1 !important;
    pointer-events: all !important;
}

.mobile-link {
    position: relative;
}

/* Hero animations */
.hero-subtitle {
    animation: slideUp 0.8s ease forwards;
}

.hero-title {
    animation: slideUp 0.8s ease 0.15s forwards;
    opacity: 0;
}

.hero-text {
    animation: slideUp 0.8s ease 0.3s forwards;
    opacity: 0;
}

.hero-cta {
    animation: slideUp 0.8s ease 0.45s forwards;
    opacity: 0;
}

.hero-stats {
    animation: slideUp 0.8s ease 0.6s forwards;
    opacity: 0;
}

.hero-image-wrapper {
    animation: fadeIn 1s ease 0.3s forwards;
    opacity: 0;
}

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

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

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

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

/* Scroll indicator */
.scroll-line {
    animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
    0%, 100% {
        opacity: 0.4;
        transform: scaleY(1);
    }
    50% {
        opacity: 1;
        transform: scaleY(1.2);
    }
}

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

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

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

/* Mobile menu button */
.menu-line {
    transition: all 0.3s ease;
}

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

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

#mobile-menu-btn.active .menu-line:nth-child(3) {
    width: 24px;
    transform: rotate(-45deg) translate(4px, -4px);
}

/* Image hover effects */
img {
    transition: transform 0.7s ease;
}

/* Form focus styles */
input:focus,
textarea:focus {
    border-bottom-color: #C65D3E !important;
}

/* Button ripple effect */
button,
a {
    -webkit-tap-highlight-color: transparent;
}

/* Print styles */
@media print {
    nav,
    .scroll-indicator,
    #contact-form button {
        display: none;
    }
    
    body {
        color: #1A1A1A;
        background: white;
    }
}
