/* Base & Utilities */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    overflow-x: hidden;
}

::selection {
    background: rgba(200, 164, 92, 0.2);
    color: #0F1F3D;
}

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

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

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

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

.nav-logo-text {
    transition: color 0.3s ease;
}

/* Navbar scroll state */
.nav-scrolled {
    background: rgba(255, 255, 255, 0.97) !important;
    backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(15, 31, 61, 0.06);
}

.nav-scrolled .nav-logo-text {
    color: #0F1F3D;
}

.nav-scrolled .nav-link {
    color: rgba(15, 31, 61, 0.7) !important;
}

.nav-scrolled .menu-line {
    background: #0F1F3D !important;
}

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

.mobile-menu-link {
    position: relative;
}

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

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

/* Hamburger animation */
.menu-line {
    transition: all 0.3s ease !important;
}

#mobile-menu-btn.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(3px, 3px);
}

#mobile-menu-btn.active .menu-line:nth-child(2) {
    opacity: 0;
}

#mobile-menu-btn.active .menu-line:nth-child(3) {
    width: 24px;
    transform: rotate(-45deg) translate(3px, -3px);
}

/* Hero animations */
.hero-subtitle {
    animation: fadeUp 0.8s ease forwards 0.3s;
}

.hero-title {
    animation: fadeUp 0.8s ease forwards 0.5s;
}

.hero-description {
    animation: fadeUp 0.8s ease forwards 0.7s;
}

.hero-cta {
    animation: fadeUp 0.8s ease forwards 0.9s;
}

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

/* Scroll dot animation */
@keyframes scrollDot {
    0% { top: 0; opacity: 1; }
    100% { top: 100%; opacity: 0; }
}

.scroll-dot {
    animation: scrollDot 1.5s ease-in-out infinite;
}

/* Reveal animations */
.reveal-up, .reveal-left, .reveal-right {
    opacity: 0;
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-up {
    transform: translateY(40px);
}

.reveal-left {
    transform: translateX(-40px);
}

.reveal-right {
    transform: translateX(40px);
}

.reveal-up.visible,
.reveal-left.visible,
.reveal-right.visible {
    opacity: 1;
    transform: translate(0, 0);
}

/* Staggered delays for grid children */
.reveal-up:nth-child(1) { transition-delay: 0.1s; }
.reveal-up:nth-child(2) { transition-delay: 0.2s; }
.reveal-up:nth-child(3) { transition-delay: 0.3s; }
.reveal-up:nth-child(4) { transition-delay: 0.4s; }
.reveal-up:nth-child(5) { transition-delay: 0.5s; }
.reveal-up:nth-child(6) { transition-delay: 0.6s; }

/* Input focus styles */
input:focus, textarea:focus {
    border-bottom-color: #C8A45C !important;
}

/* Form success animation */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

#form-success.show {
    animation: fadeIn 0.4s ease forwards;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.75rem;
    }
    
    .hero-title .italic {
        font-size: 2.5rem;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .hero-title {
        font-size: 4.5rem;
    }
}

@media (min-width: 1025px) {
    .hero-title {
        font-size: 5.5rem;
    }
}

/* Subtle image loading */
img {
    opacity: 1;
    transition: opacity 0.3s ease;
}

img[data-src] {
    opacity: 0;
}

/* Print styles */
@media print {
    nav, #mobile-menu-btn, .scroll-indicator {
        display: none;
    }
    
    body {
        color: #000;
        background: #fff;
    }
}
