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

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

body {
    font-family: 'Inter', system-ui, sans-serif;
    overflow-x: hidden;
}

::selection {
    background: rgba(201, 168, 76, 0.3);
    color: #0a1628;
}

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

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

#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 fadeDown {
    from {
        opacity: 0;
        transform: translateY(-16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hamburger animation */
.menu-toggle[aria-expanded="true"] .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(4px, 4px);
}

.menu-toggle[aria-expanded="true"] .menu-line:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.menu-toggle[aria-expanded="true"] .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(4px, -4px);
    width: 1.25rem;
}

/* Hero reveal animations */
.hero-reveal {
    opacity: 0;
    transform: translateY(40px);
}

.hero-reveal.animate {
    animation: heroReveal 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.hero-reveal:nth-child(1) { animation-delay: 0.1s; }
.hero-reveal:nth-child(2) { animation-delay: 0.25s; }
.hero-reveal:nth-child(3) { animation-delay: 0.4s; }
.hero-reveal:nth-child(4) { animation-delay: 0.55s; }

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

/* Scroll reveal animations */
.reveal-up {
    opacity: 0;
    transform: translateY(32px);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-up.visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-40px);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-left.visible {
    opacity: 1;
    transform: translateX(0);
}

/* Staggered service cards */
.service-card:nth-child(1) .reveal-up { transition-delay: 0.0s; }
.service-card:nth-child(2) .reveal-up { transition-delay: 0.08s; }
.service-card:nth-child(3) .reveal-up { transition-delay: 0.16s; }
.service-card:nth-child(4) .reveal-up { transition-delay: 0.24s; }
.service-card:nth-child(5) .reveal-up { transition-delay: 0.32s; }
.service-card:nth-child(6) .reveal-up { transition-delay: 0.40s; }

/* Header scroll state */
header.scrolled {
    background: rgba(10, 22, 40, 0.95);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05);
}

header.scrolled .menu-line {
    background: #fff !important;
}

header.scrolled .menu-line:nth-child(3) {
    background: #c9a84c !important;
}

/* Back to top button */
#back-to-top.visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: all;
}

/* Custom select styling */
select option {
    background: #112240;
    color: #fff;
}

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

/* Subtle parallax on hero */
#hero img {
    will-change: transform;
}

/* Print styles */
@media print {
    header, #back-to-top, #mobile-menu {
        display: none;
    }
    body {
        color: #000;
        background: #fff;
    }
}
