:root {
    --color-terracotta-50: #fdf8f6;
    --color-terracotta-100: #f9ece4;
    --color-terracotta-300: #e8a88a;
    --color-terracotta-400: #dc7a52;
    --color-terracotta-500: #d4623a;
    --color-terracotta-600: #c24a28;
    --color-terracotta-700: #a1361e;
    --color-sand-50: #fcfaf8;
    --color-sand-100: #f5f0e8;
    --color-sand-200: #e8dcc8;
    --color-sand-300: #d4c0a0;
    --color-sand-400: #c0a070;
    --color-sand-500: #a8844e;
    --color-sand-600: #8c6a3c;
    --color-sand-700: #705230;
    --color-sand-800: #584128;
    --color-sand-900: #453322;
}

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

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

body {
    margin: 0;
    font-family: 'Inter', sans-serif;
    font-weight: 300;
    letter-spacing: 0.01em;
}

h1, h2, h3 {
    font-family: 'Playfair Display', serif;
    font-weight: 400;
    line-height: 1.15;
}

/* Navbar scroll state */
nav.scrolled {
    background: rgba(252, 250, 248, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(0,0,0,0.05);
}

nav.scrolled a,
nav.scrolled button {
    color: var(--color-sand-900);
}

/* Mobile menu */
.mobile-link {
    opacity: 0;
    transform: translateY(10px);
}

#mobile-menu.open .mobile-link {
    animation: fadeUp 0.4s ease forwards;
}

#mobile-menu.open .mobile-link:nth-child(1) { animation-delay: 0.05s; }
#mobile-menu.open .mobile-link:nth-child(2) { animation-delay: 0.1s; }
#mobile-menu.open .mobile-link:nth-child(3) { animation-delay: 0.15s; }
#mobile-menu.open .mobile-link:nth-child(4) { animation-delay: 0.2s; }
#mobile-menu.open .mobile-link:nth-child(5) { animation-delay: 0.25s; }

@keyframes fadeUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hamburger animation */
#menu-toggle.open #hamburger span:nth-child(1) {
    transform: rotate(45deg) translate(3px, 3px);
}
#menu-toggle.open #hamburger span:nth-child(2) {
    opacity: 0;
}
#menu-toggle.open #hamburger span:nth-child(3) {
    transform: rotate(-45deg) translate(3px, -3px);
    width: 1.5rem;
}

/* Service card hover */
.service-card {
    position: relative;
    overflow: hidden;
}

.service-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--color-terracotta-400);
    transition: all 0.4s ease;
    transform: translateX(-50%);
}

.service-card:hover::after {
    width: 60%;
}

/* Selection color */
::selection {
    background: var(--color-terracotta-200);
    color: var(--color-sand-900);
}

/* Focus styles */
input:focus, select:focus, textarea:focus {
    outline: none;
}

/* Smooth image loading */
img {
    image-rendering: -webkit-optimize-contrast;
}

/* Scroll-triggered animations */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.visible {
    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; }

/* Writing mode for vertical text */
.writing-mode-vertical {
    writing-mode: vertical-rl;
    text-orientation: mixed;
}
