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

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

body {
    overflow-x: hidden;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: #0d0a0a;
}
::-webkit-scrollbar-thumb {
    background: #c9972e40;
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: #c9972e60;
}

/* Selection */
::selection {
    background: rgba(201, 151, 46, 0.3);
    color: #fdf8f6;
}

/* Stat Cards */
.stat-card {
    transition: transform 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
}
.stat-card:hover {
    transform: translateY(-4px);
    border-color: rgba(201, 151, 46, 0.3);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

/* Service Cards */
.service-card {
    transition: transform 0.4s ease, border-color 0.4s ease, box-shadow 0.4s ease;
}
.service-card:hover {
    transform: translateY(-6px);
    border-color: rgba(201, 151, 46, 0.4);
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.4);
}

/* Gallery Items */
.gallery-item {
    cursor: pointer;
}
.gallery-item::after {
    content: '';
    position: absolute;
    inset: 0;
    border: 1px solid transparent;
    border-radius: inherit;
    transition: border-color 0.4s ease;
    pointer-events: none;
}
.gallery-item:hover::after {
    border-color: rgba(201, 151, 46, 0.4);
}

/* Mobile Menu */
.mobile-link {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

#mobileMenu.open .mobile-link {
    opacity: 1;
    transform: translateY(0);
}

/* Navbar */
.nav-scrolled #navbar {
    background: rgba(7, 5, 5, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(201, 151, 46, 0.1);
}

.nav-scrolled #navbar .menu-line {
    background: #c9972e;
}

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

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

/* Menu Button */
#menuBtn.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(4px, 4px);
}
#menuBtn.active .menu-line:nth-child(2) {
    opacity: 0;
}
#menuBtn.active .menu-line:nth-child(3) {
    width: 24px;
    transform: rotate(-45deg) translate(4px, -4px);
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    html {
        scroll-behavior: auto;
    }
}

/* Focus visible */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
    outline: 2px solid #c9972e;
    outline-offset: 2px;
}

/* Smooth image loading */
img {
    image-rendering: auto;
}
