/* Base & Utilities */
*, *::before, *::after {
    box-sizing: border-box;
}

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

body {
    overflow-x: hidden;
}

::selection {
    background: rgba(212, 160, 86, 0.3);
    color: #fff;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0e0e0e;
}
::-webkit-scrollbar-thumb {
    background: #3a3a3a;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #D4A056;
}

/* Navigation */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: #D4A056;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

.nav-link:hover {
    color: #E8C46A !important;
}

/* Mobile Menu */
.mobile-link {
    position: relative;
    font-family: 'Cormorant Garamond', Georgia, serif;
}

.mobile-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 1px;
    background: #D4A056;
    transition: width 0.3s ease;
}

.mobile-link:hover::after {
    width: 100%;
}

/* Navbar Scrolled State */
.navbar-scrolled {
    background: rgba(8, 8, 8, 0.95) !important;
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(212, 160, 86, 0.1);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
}

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

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(212, 160, 86, 0.03) 0%, transparent 60%);
    opacity: 0;
    transition: opacity 0.5s ease;
    pointer-events: none;
}

.service-card:hover::before {
    opacity: 1;
}

.service-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4), 0 0 40px rgba(212, 160, 86, 0.05);
}

/* Gallery */
.gallery-item {
    cursor: pointer;
}

.gallery-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(212, 160, 86, 0.0);
    transition: background 0.3s ease;
    pointer-events: none;
}

.gallery-item:hover::after {
    background: rgba(212, 160, 86, 0.05);
}

/* Hero text shimmer */
@keyframes shimmer {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

/* Scroll reveal base - 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-delay-1 { transition-delay: 0.1s; }
    .reveal-delay-2 { transition-delay: 0.2s; }
    .reveal-delay-3 { transition-delay: 0.3s; }
    .reveal-delay-4 { transition-delay: 0.4s; }
    .reveal-delay-5 { transition-delay: 0.5s; }
    .reveal-delay-6 { transition-delay: 0.6s; }
}

/* Mobile responsive */
@media (max-width: 768px) {
    .font-serif {
        line-height: 1.1;
    }

    #hero h1 {
        font-size: 2.75rem;
    }

    .service-card {
        padding: 1.5rem;
    }

    #about .relative {
        margin-bottom: 2rem;
    }

    .floating-card {
        position: relative !important;
        bottom: auto !important;
        right: auto !important;
        margin-top: 1rem;
        max-width: 100%;
    }
}

/* Focus styles for accessibility */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
    outline: 2px solid #D4A056;
    outline-offset: 2px;
}

/* Print styles */
@media print {
    nav, #back-to-top, .gallery-item::after {
        display: none;
    }
}
