/* ===== Custom Styles for Just Real Food ===== */

/* Base & Typography */
html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

::selection {
    background: rgba(212, 168, 83, 0.3);
    color: #f5f0e8;
}

/* ===== Floating Card Animations ===== */
.floating-card {
    animation: float 6s ease-in-out infinite;
}

.card-1 {
    animation-delay: 0s;
}

.card-2 {
    animation-delay: -2s;
}

.card-3 {
    animation-delay: -4s;
}

.card-4 {
    animation-delay: -1s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
    }
    33% {
        transform: translateY(-12px) rotate(0.5deg);
    }
    66% {
        transform: translateY(6px) rotate(-0.5deg);
    }
}

/* ===== Scroll Reveal Animations ===== */
.reveal-up {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

@media (prefers-reduced-motion: no-preference) {
    .reveal-up {
        opacity: 0;
        transform: translateY(30px);
    }

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

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

#navbar.scrolled {
    background: rgba(8, 18, 19, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(212, 168, 83, 0.1);
    box-shadow: 0 4px 40px rgba(0, 0, 0, 0.3);
}

/* ===== Mobile Menu ===== */
.menu-line {
    display: block;
}

#mobile-menu.open .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

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

#mobile-menu.open .menu-line:nth-child(3) {
    width: 24px;
    transform: rotate(-45deg) translate(5px, -5px);
}

.mobile-link {
    display: block;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(212, 168, 83, 0.08);
}

.mobile-link:last-child {
    border-bottom: none;
}

/* ===== Gold shimmer on hover for cards ===== */
.group:hover .group-hover\:scale-110 {
    transform: scale(1.1);
}

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

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

::-webkit-scrollbar-thumb {
    background: rgba(212, 168, 83, 0.3);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(212, 168, 83, 0.5);
}

/* ===== Button glow effect ===== */
a:hover {
    transition: all 0.3s ease;
}

/* ===== Image loading placeholder ===== */
img {
    background: linear-gradient(135deg, #0c1a1c 0%, #1a2f30 100%);
}

/* ===== Map dark theme overlay ===== */
iframe[title="Just Real Food location map"] {
    border-radius: 1rem;
}

/* ===== Responsive adjustments ===== */
@media (max-width: 768px) {
    .floating-card {
        display: none;
    }

    #hero {
        min-height: 100vh;
        padding-top: 6rem;
    }

    .font-serif {
        font-size: clamp(2rem, 8vw, 3.5rem);
    }
}

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

/* ===== Focus styles for accessibility ===== */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #d4a853;
    outline-offset: 3px;
    border-radius: 4px;
}

/* ===== Subtle gradient borders on product cards ===== */
.group::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 1rem;
    padding: 1px;
    background: linear-gradient(135deg, rgba(212, 168, 83, 0), rgba(212, 168, 83, 0));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
    transition: background 0.5s ease;
}
