/* ============================================
   Mad Trav's Smoke Shop — Custom Styles
   Classic & Elegant · Midnight Blue + Mint
   ============================================ */

/* 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;
}

::selection {
    background: rgba(167, 196, 184, 0.25);
    color: #F5F0EB;
}

/* Font families */
.font-cormorant {
    font-family: 'Cormorant Garamond', Georgia, serif;
}

.font-montserrat {
    font-family: 'Montserrat', 'Helvetica Neue', sans-serif;
}

/* ============================================
   Hero Animations (first-load, above-the-fold)
   ============================================ */
.hero-subtitle {
    animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.1s both;
}

.hero-line {
    animation: slideUp 0.9s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.hero-line:nth-child(1) {
    animation-delay: 0.2s;
}

.hero-line:nth-child(2) {
    animation-delay: 0.35s;
}

.hero-desc {
    animation: slideUp 0.9s cubic-bezier(0.16, 1, 0.3, 1) 0.5s both;
}

.hero-cta {
    animation: slideUp 0.9s cubic-bezier(0.16, 1, 0.3, 1) 0.65s both;
}

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

/* ============================================
   Scroll Reveal (below-the-fold only)
   Progressive enhancement: content is visible
   by default; JS adds the animated state.
   ============================================ */
.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);
}

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

.reveal:not(.revealed) {
    opacity: 0;
    transform: translateY(28px);
}

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

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    html { scroll-behavior: auto; }
    .reveal:not(.revealed) {
        opacity: 1;
        transform: none;
    }
}

/* ============================================
   Navbar
   ============================================ */
#navbar {
    background: transparent;
}

#navbar.scrolled {
    background: rgba(13, 27, 42, 0.92);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(167, 196, 184, 0.08);
    box-shadow: 0 4px 40px rgba(0, 0, 0, 0.3);
}

#navbar.scrolled .menu-line {
    background: #F5F0EB;
}

/* Mobile menu button animations */
#menuBtn.active .menu-line:nth-child(1) {
    transform: translateY(5px) rotate(45deg);
}

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

#menuBtn.active .menu-line:nth-child(3) {
    transform: translateY(-5px) rotate(-45deg);
    width: 1.5rem;
}

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

.mobile-link {
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.4s ease, transform 0.4s ease, color 0.3s ease;
}

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

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

/* ============================================
   Image hover effects
   ============================================ */
img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ============================================
   Utility — subtle hover lift on cards
   ============================================ */
.group:hover .group-hover\:scale-105 {
    transform: scale(1.05);
}

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

::-webkit-scrollbar-track {
    background: #0D1B2A;
}

::-webkit-scrollbar-thumb {
    background: rgba(167, 196, 184, 0.25);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(167, 196, 184, 0.45);
}
