/* ============================================
   Mary Michelle Winery — Custom Styles
   ============================================ */

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

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

body {
    overflow-x: hidden;
}

/* ============================================
   Navigation
   ============================================ */
#navbar {
    transition: background-color 0.5s ease, box-shadow 0.5s ease, backdrop-filter 0.5s ease;
}

#navbar.scrolled {
    background-color: rgba(250, 250, 245, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.08);
}

#navbar.scrolled .nav-text {
    color: #0f172a;
}

#navbar.scrolled .nav-subtext {
    color: #0d9488;
}

#navbar.scrolled .nav-link {
    color: #475569;
}

#navbar.scrolled .nav-link:hover {
    color: #0d9488;
}

#navbar.scrolled .nav-btn span {
    background-color: #0f172a;
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    width: 0;
    height: 1.5px;
    background-color: #0d9488;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

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

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

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

.mobile-link {
    position: relative;
}

.mobile-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    width: 0;
    height: 1.5px;
    background-color: #0d9488;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

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

/* ============================================
   Hero Animations
   ============================================ */
.hero-subtitle {
    opacity: 0;
    transform: translateY(20px);
    animation: heroFadeUp 0.8s ease forwards 0.3s;
}

.hero-title {
    opacity: 0;
    transform: translateY(30px);
    animation: heroFadeUp 0.8s ease forwards 0.5s;
}

.hero-desc {
    opacity: 0;
    transform: translateY(20px);
    animation: heroFadeUp 0.8s ease forwards 0.7s;
}

.hero-cta {
    opacity: 0;
    transform: translateY(20px);
    animation: heroFadeUp 0.8s ease forwards 0.9s;
}

@keyframes heroFadeUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================
   Scroll Reveal Animations
   (Progressive Enhancement — content visible without JS)
   ============================================ */
@media (prefers-reduced-motion: no-preference) {
    .reveal-text,
    .reveal-image,
    .reveal-card,
    .reveal-form {
        opacity: 1;
        transform: none;
        transition: opacity 0.7s ease, transform 0.7s ease;
    }
    
    .reveal-text.js-reveal,
    .reveal-image.js-reveal,
    .reveal-card.js-reveal,
    .reveal-form.js-reveal {
        opacity: 0;
        transform: translateY(40px);
    }
    
    .reveal-image.js-reveal {
        transform: translateX(-30px);
    }
    
    .reveal-card.js-reveal:nth-child(2) {
        transition-delay: 0.15s;
    }
    
    .reveal-card.js-reveal:nth-child(3) {
        transition-delay: 0.3s;
    }
}

/* ============================================
   Typography Refinements
   ============================================ */
font-serif {
    letter-spacing: -0.01em;
}

h1, h2, h3 {
    font-weight: 700;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #0f766e;
}

/* ============================================
   Selection Color
   ============================================ */
::selection {
    background-color: #0d9488;
    color: #f0fdfa;
}

/* ============================================
   Focus Styles
   ============================================ */
:focus-visible {
    outline: 2px solid #0d9488;
    outline-offset: 2px;
}

/* ============================================
   Image Aspect Ratio Fallbacks
   ============================================ */
.aspect-\[4\/5\] {
    aspect-ratio: 4 / 5;
}

.aspect-\[3\/4\] {
    aspect-ratio: 3 / 4;
}

.aspect-\[4\/3\] {
    aspect-ratio: 4 / 3;
}

/* ============================================
   Print Styles
   ============================================ */
@media print {
    #navbar,
    .animate-bounce,
    button,
    input,
    textarea,
    select {
        display: none !important;
    }
    
    body {
        color: #000;
        background: #fff;
    }
    
    a {
        color: #000;
    }
}
