/* ========== BASE & RESET ========== */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    margin: 0;
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

::selection {
    background: #B8544E;
    color: #fefdfb;
}

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

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

@keyframes scrollDot {
    0% { transform: translateY(0); opacity: 1; }
    100% { transform: translateY(8px); opacity: 0; }
}

.animate-fade-in-up {
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

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

.animate-scroll-dot {
    animation: scrollDot 1.4s ease-in-out infinite;
}

/* ========== SCROLL REVEAL ========== */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* Reduced motion preference */
@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
    .animate-fade-in-up,
    .animate-fade-in {
        animation: none;
        opacity: 1;
    }
    .animate-scroll-dot {
        animation: none;
    }
    html {
        scroll-behavior: auto;
    }
}

/* ========== NAVBAR SCROLL STATE ========== */
#navbar.scrolled {
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.08);
}

/* ========== MOBILE MENU ========== */
#mobile-menu {
    animation: fadeIn 0.25s ease;
}

/* ========== CUSTOM SCROLLBAR ========== */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #fdf9f0;
}
::-webkit-scrollbar-thumb {
    background: #e4b772;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #B8544E;
}

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

/* ========== SELECTION FOR FORM ELEMENTS ========== */
select option {
    background: #fdf9f0;
    color: #1e1e1e;
}
