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

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

body {
    overflow-x: hidden;
}

/* Selection */
::selection {
    background-color: #7f1a26;
    color: #faf5f2;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #faf5f2;
}
::-webkit-scrollbar-thumb {
    background: #b92b3a;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #9c1f2e;
}

/* Reveal Animations — Progressive Enhancement */
@media (prefers-reduced-motion: no-preference) {
    .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:nth-child(2) { transition-delay: 0.1s; }
    .reveal:nth-child(3) { transition-delay: 0.2s; }
    .reveal:nth-child(4) { transition-delay: 0.3s; }
    .reveal:nth-child(5) { transition-delay: 0.4s; }
    .reveal:nth-child(6) { transition-delay: 0.5s; }
}

/* Navbar transition */
.nav-scrolled {
    background: rgba(250, 245, 242, 0.95) !important;
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(127, 26, 38, 0.08);
}

.nav-scrolled .font-serif {
    color: #2c0a0d !important;
}

/* Smooth focus */
*:focus-visible {
    outline: 2px solid #b92b3a;
    outline-offset: 2px;
}

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

/* Button hover glow */
button:hover, a:hover {
    cursor: pointer;
}

/* Custom range for form inputs */
input:focus, select:focus, textarea:focus {
    box-shadow: 0 0 0 4px rgba(185, 43, 58, 0.1);
}

/* Print styles */
@media print {
    nav, #contact-form, .reveal { display: none; }
    body { color: #000; background: #fff; }
}
