/* ============================================
   Fuel Stop Nutrition — Custom Styles
   Premium Dark Luxury | Burgundy + Blush
   ============================================ */

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ---------- Selection ---------- */
::selection {
    background: rgba(201, 169, 110, 0.3);
    color: #f5f5f7;
}

/* ---------- Scrollbar ---------- */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #13131a;
}
::-webkit-scrollbar-thumb {
    background: linear-gradient(to bottom, #7B2D3B, #C9A96E);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(to bottom, #9f1538, #e2ab4a);
}

/* ---------- Scroll Indicator Animation ---------- */
@keyframes scrollIndicator {
    0% {
        top: 0;
        opacity: 1;
    }
    100% {
        top: 100%;
        opacity: 0;
    }
}

.animate-scroll-indicator {
    animation: scrollIndicator 1.5s ease-in-out infinite;
}

/* ---------- Reveal Animations ---------- */
/* Default state: visible (progressive enhancement) */
.reveal-up,
.reveal-left,
.reveal-right {
    opacity: 1;
    transform: none;
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-up {
    transform: translateY(30px);
}
.reveal-left {
    transform: translateX(-30px);
}
.reveal-right {
    transform: translateX(30px);
}

/* JS-enabled state: hidden until scrolled into view */
@media (prefers-reduced-motion: no-preference) {
    .reveal-up.is-hidden,
    .reveal-left.is-hidden,
    .reveal-right.is-hidden {
        opacity: 0;
    }
    .reveal-up.is-hidden {
        transform: translateY(40px);
    }
    .reveal-left.is-hidden {
        transform: translateX(-40px);
    }
    .reveal-right.is-hidden {
        transform: translateX(40px);
    }
}

/* ---------- Staggered Delays ---------- */
.reveal-up:nth-child(1) { transition-delay: 0.05s; }
.reveal-up:nth-child(2) { transition-delay: 0.12s; }
.reveal-up:nth-child(3) { transition-delay: 0.19s; }
.reveal-up:nth-child(4) { transition-delay: 0.26s; }
.reveal-up:nth-child(5) { transition-delay: 0.33s; }
.reveal-up:nth-child(6) { transition-delay: 0.40s; }

/* ---------- Navbar Active State ---------- */
#site-header.scrolled {
    background: rgba(19, 19, 26, 0.95) !important;
    backdrop-blur: 20px !important;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.4),
                0 0 0 1px rgba(201, 169, 110, 0.1);
}

/* ---------- Gold Shimmer on Hover ---------- */
@keyframes shimmer {
    0% {
        background-position: -200% center;
    }
    100% {
        background-position: 200% center;
    }
}

a.gold-shimmer:hover {
    background: linear-gradient(90deg, #C9A96E, #f0d78c, #C9A96E) !important;
    background-size: 200% auto !important;
    -webkit-background-clip: text !important;
    background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    animation: shimmer 3s linear infinite;
}

/* ---------- Product Card Hover Glow ---------- */
.group:hover .group-hover\:shadow-gold-500\/30,
.group:hover .group-hover\:shadow-burgundy-700\/40 {
    filter: brightness(1.1);
}

/* ---------- Button Ripple Effect ---------- */
@keyframes ripple {
    to {
        transform: scale(2.5);
        opacity: 0;
    }
}

/* ---------- Mobile Menu Transitions ---------- */
#mobile-menu {
    transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1),
                pointer-events 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

#mobile-menu.is-open {
    opacity: 1;
    pointer-events: all;
}

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

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

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

/* ---------- Hamburger Animation ---------- */
.menu-line {
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                opacity 0.2s ease;
}

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

/* ---------- Image Hover Zoom ---------- */
.group img {
    transition: transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ---------- Map Grayscale Transition ---------- */
iframe.grayscale {
    filter: grayscale(0.4) contrast(1.1);
    transition: filter 0.7s ease;
}

iframe.grayscale:hover {
    filter: grayscale(0) contrast(1);
}

/* ---------- Focus Styles ---------- */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #C9A96E;
    outline-offset: 3px;
    border-radius: 4px;
}

/* ---------- 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-up,
    .reveal-left,
    .reveal-right {
        opacity: 1;
        transform: none;
    }
}

/* ---------- Responsive Adjustments ---------- */
@media (max-width: 640px) {
    .font-display {
        line-height: 1.2;
    }
}

@media (min-width: 1024px) {
    /* Subtle parallax-like effect for hero */
    #hero {
        perspective: 1000px;
    }
}
