*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    overflow-x: hidden;
}

/* Reveal animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94), transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

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

.reveal.delay-1 { transition-delay: 0.1s; }
.reveal.delay-2 { transition-delay: 0.2s; }
.reveal.delay-3 { transition-delay: 0.3s; }

/* Navigation */
#nav {
    background: transparent;
    transition: background 0.4s ease, box-shadow 0.4s ease;
}

#nav.scrolled {
    background: rgba(250, 248, 246, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 1px 0 rgba(0,0,0,0.06);
}

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

#mobileMenu.closed {
    opacity: 0;
    pointer-events: none;
}

.menu-line {
    transition: all 0.3s ease;
}

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

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

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

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

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

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

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

/* Selection */
::selection {
    background: #fce4d4;
    color: #7a3312;
}

/* Input autofill */
input:-webkit-autofill,
textarea:-webkit-autofill,
select:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 30px #faf8f6 inset !important;
    -webkit-text-fill-color: #3d3028 !important;
}

/* Form focus styles */
input:focus,
textarea:focus,
select:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(196, 90, 31, 0.15);
}

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