/* ============================================
   MARGARET + JAMES — Custom Styles
   ============================================ */

/* Base */
html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Karla', system-ui, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 6px;
}

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

::-webkit-scrollbar-thumb {
    background: #9bb5a5;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: #52705e;
}

/* Selection */
::selection {
    background: #3d5448;
    color: #fdfcfa;
}

/* ============================================
   NAVIGATION
   ============================================ */
.nav-link {
    color: rgba(253, 252, 250, 0.7);
}

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

.nav-btn-link {
    color: rgba(253, 252, 250, 0.7);
    border-color: rgba(155, 181, 165, 0.3);
}

.nav-btn-link:hover {
    color: #fdfcfa;
    border-color: rgba(155, 181, 165, 0.6);
}

/* Fixed nav state */
.navbar-scrolled .nav-link,
.navbar-scrolled .nav-btn-link {
    color: rgba(31, 42, 38, 0.7);
}

.navbar-scrolled .nav-link:hover,
.navbar-scrolled .nav-btn-link:hover {
    color: #1f2a26;
}

.navbar-scrolled .logo-text {
    color: #1f2a26;
}

/* ============================================
   MOBILE MENU
   ============================================ */
.mobile-nav-link {
    opacity: 1;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

/* ============================================
   HERO ANIMATIONS
   ============================================ */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.animate-fade-in-up {
    animation: fadeInUp 0.9s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.animate-fade-in {
    animation: fadeIn 1s ease forwards;
}

/* ============================================
   SCROLL REVEAL
   ============================================ */
.scroll-reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), 
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .scroll-reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
    
    .animate-fade-in-up,
    .animate-fade-in {
        animation: none;
        opacity: 1;
    }
    
    html {
        scroll-behavior: auto;
    }
}

/* ============================================
   FORM STYLES
   ============================================ */
input:focus,
textarea:focus {
    border-color: #52705e !important;
}

input::placeholder,
textarea::placeholder {
    color: #c5d5cc;
}

/* ============================================
   IMAGE TRANSITIONS
   ============================================ */
img {
    transition: opacity 0.3s ease;
}

img[loading="lazy"] {
    opacity: 0;
}

img.loaded {
    opacity: 1;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 767px) {
    .font-serif {
        word-spacing: -0.02em;
    }
}
