/* ============================================
   STARBUCKS · 221 NE 122nd Ave, Portland
   Custom Styles — Terracotta & Sand Palette
   ============================================ */

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

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ============================================
   HERO ANIMATIONS (progressive enhancement)
   ============================================ */
@media (prefers-reduced-motion: no-preference) {
    .hero-circle {
        animation: float 8s ease-in-out infinite;
    }
    .c1 { animation-delay: 0s; }
    .c2 { animation-delay: -2s; }
    .c3 { animation-delay: -4s; }
    .c4 { animation-delay: -1s; }
    .c5 { animation-delay: -3s; }
    .c6 { animation-delay: -5s; }
    .c7 { animation-delay: -2.5s; }

    .hero-geo {
        animation: drift 10s ease-in-out infinite;
    }
    .g1, .geo-d1, .geo-b1, .geo-c1, .geo-v1, .geo-cta1 { animation-delay: 0s; }
    .g2, .geo-d2, .geo-b2, .geo-cta2 { animation-delay: -3s; }
    .g3 { animation-delay: -6s; }
    .geo-b3 { animation-delay: -4s; }

    @keyframes float {
        0%, 100% { transform: translate(0, 0) scale(1); }
        33% { transform: translate(12px, -18px) scale(1.03); }
        66% { transform: translate(-8px, 10px) scale(0.97); }
    }

    @keyframes drift {
        0%, 100% { transform: rotate(45deg) translate(0, 0); }
        50% { transform: rotate(55deg) translate(10px, -10px); }
    }

    /* Drink cards */
    .drink-card {
        opacity: 0;
        transform: translateY(30px);
    }
    .drink-card.revealed {
        animation: fadeUp 0.6s ease forwards;
    }
    .drink-card:nth-child(1).revealed { animation-delay: 0.1s; }
    .drink-card:nth-child(2).revealed { animation-delay: 0.25s; }
    .drink-card:nth-child(3).revealed { animation-delay: 0.4s; }

    /* Community cards */
    .community-card {
        opacity: 0;
        transform: translateY(20px);
    }
    .community-card.revealed {
        animation: fadeUp 0.5s ease forwards;
    }
    .community-card:nth-child(1).revealed { animation-delay: 0.1s; }
    .community-card:nth-child(2).revealed { animation-delay: 0.2s; }
    .community-card:nth-child(3).revealed { animation-delay: 0.3s; }

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

/* Always-visible fallback for reduced motion */
@media (prefers-reduced-motion: reduce) {
    .hero-circle, .hero-geo {
        animation: none;
    }
    .drink-card, .community-card {
        opacity: 1;
        transform: none;
    }
}

/* ============================================
   MOBILE MENU
   ============================================ */
#mobileMenu.open {
    opacity: 1;
    pointer-events: all;
}

.menu-line.active-1 {
    transform: translateY(6px) rotate(45deg);
}
.menu-line.active-2 {
    opacity: 0;
}
.menu-line.active-3 {
    transform: translateY(-6px) rotate(-45deg);
}

.mobile-link {
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}
#mobileMenu.open .mobile-link {
    opacity: 1;
    transform: translateY(0);
}
#mobileMenu.open .mobile-link:nth-child(1) { transition-delay: 0.05s; }
#mobileMenu.open .mobile-link:nth-child(2) { transition-delay: 0.1s; }
#mobileMenu.open .mobile-link:nth-child(3) { transition-delay: 0.15s; }
#mobileMenu.open .mobile-link:nth-child(4) { transition-delay: 0.2s; }
#mobileMenu.open .mobile-link:nth-child(5) { transition-delay: 0.25s; }

/* ============================================
   NAVBAR SCROLL STATE
   ============================================ */
.nav-scrolled {
    box-shadow: 0 4px 20px rgba(61, 31, 16, 0.08);
}

/* ============================================
   SCROLL REVEAL (below-the-fold only)
   ============================================ */
.reveal-section {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal-section.revealed {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
    .reveal-section {
        opacity: 1;
        transform: none;
        transition: none;
    }
}
