/* Custom styles for Mel's Place */

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

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

::-webkit-scrollbar-track {
    background: #102a43;
}

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

::-webkit-scrollbar-thumb:hover {
    background: #d49a2a;
}

/* Navbar scroll state */
nav.scrolled {
    background: rgba(10, 26, 46, 0.95) !important;
    backdrop-filter: blur(20px) !important;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

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

/* Menu tabs */
.menu-tab {
    background: transparent;
    color: #627d98;
    border: 1px solid transparent;
}

.menu-tab:hover {
    color: #f5dfaa;
    border-color: rgba(212, 154, 42, 0.3);
}

.menu-tab.active {
    background: #d49a2a;
    color: #102a43;
    border-color: #d49a2a;
}

/* Menu content transitions */
.menu-content {
    animation: fadeIn 0.3s ease-in-out;
}

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

/* Mobile menu */
.mobile-link {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

#mobile-menu.open .mobile-link {
    opacity: 1;
    transform: translateY(0);
}

#mobile-menu.open .mobile-link:nth-child(1) { transition-delay: 0.05s; }
#mobile-menu.open .mobile-link:nth-child(2) { transition-delay: 0.1s; }
#mobile-menu.open .mobile-link:nth-child(3) { transition-delay: 0.15s; }
#mobile-menu.open .mobile-link:nth-child(4) { transition-delay: 0.2s; }
#mobile-menu.open .mobile-link:nth-child(5) { transition-delay: 0.25s; }

/* Mobile menu button animation */
.menu-btn.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

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

.menu-btn.active .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
    width: 1.5rem;
}

/* Floating card animations */
@keyframes float {
    0%, 100% {
        transform: translateY(0px) rotate(var(--rotate, 0deg));
    }
    50% {
        transform: translateY(-12px) rotate(var(--rotate, 0deg));
    }
}

/* Apply floating to stat cards */
#hero .absolute > div {
    animation: float 4s ease-in-out infinite;
}

#hero .absolute > div:nth-child(1) {
    --rotate: 3deg;
    animation-delay: 0s;
}

#hero .absolute > div:nth-child(2) {
    --rotate: -2deg;
    animation-delay: 1s;
}

#hero .absolute > div:nth-child(3) {
    --rotate: 1deg;
    animation-delay: 2s;
}

#hero .absolute > div:nth-child(4) {
    --rotate: -1deg;
    animation-delay: 0.5s;
}

/* Scroll reveal (below fold only) */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

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

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    
    #hero .absolute > div {
        animation: none;
    }
    
    .menu-content {
        animation: none;
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    #hero h1 {
        font-size: 2.75rem;
    }
    
    .font-serif {
        line-height: 1.1;
    }
}
