/* ===== RESET & BASE ===== */
*, *::before, *::after {
    box-sizing: border-box;
}

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

body {
    margin: 0;
    overflow-x: hidden;
}

img {
    display: block;
    max-width: 100%;
}

::selection {
    background: rgba(212, 160, 23, 0.3);
    color: #1a0c20;
}

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

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

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

.nav-link:hover {
    color: #D4A017;
}

/* ===== MOBILE MENU ===== */
.mobile-link {
    position: relative;
}

/* ===== SCROLL REVEAL ===== */
.scroll-reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Reduced motion preference */
@media (prefers-reduced-motion: reduce) {
    .scroll-reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
    
    html {
        scroll-behavior: auto;
    }
    
    * {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
    }
}

/* ===== FOCUS STYLES ===== */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid #D4A017;
    outline-offset: 2px;
}

/* ===== ACCESSIBILITY ===== */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* ===== MOBILE MENU ANIMATION ===== */
#mobileMenu.menu-open {
    opacity: 1;
    pointer-events: all;
}

#mobileMenu.menu-closed {
    opacity: 0;
    pointer-events: none;
}

/* Menu lines animation */
.menu-open .menu-line:nth-child(1) {
    top: 50%;
    transform: rotate(45deg);
}

.menu-open .menu-line:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.menu-open .menu-line:nth-child(3) {
    top: 50%;
    transform: rotate(-45deg);
}

/* ===== CARD HOVER EFFECTS ===== */
.group:hover .group-hover\:scale-105 {
    transform: scale(1.05);
}

/* ===== IMAGE PLACEHOLDER FALLBACK ===== */
img {
    background: linear-gradient(135deg, #e8ddee 0%, #f5f0f7 100%);
}

/* ===== CUSTOM SCROLLBAR ===== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #FAF6F0;
}

::-webkit-scrollbar-thumb {
    background: #b995be;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #9e6fa3;
}

/* ===== LOADING STATE ===== */
.page-loaded #navbar {
    transform: translateY(0);
    opacity: 1;
}

/* ===== FORM STYLES ===== */
input::placeholder,
textarea::placeholder {
    color: #d4bfd8;
}

input:focus,
textarea:focus {
    box-shadow: 0 0 0 3px rgba(212, 160, 23, 0.15);
}

/* ===== DECORATIVE PATTERNS ===== */
.pattern-dots {
    background-image: radial-gradient(circle, rgba(212, 160, 23, 0.1) 1px, transparent 1px);
    background-size: 24px 24px;
}
