/* ============================================
   Pickles and Ice Cream — Custom Styles
   Premium Dark Luxury Theme
   Teal + Slate Grey + Gold Accents
   ============================================ */

/* --- Custom Properties --- */
:root {
    --color-teal-400: #2dd4bf;
    --color-teal-500: #14b8a6;
    --color-teal-600: #0d9488;
    --color-gold-400: #fbbf24;
    --color-gold-500: #f59e0b;
    --color-slate-950: #0f172a;
    --color-slate-900: #1e293b;
    --color-slate-800: #334155;
    --color-slate-700: #475569;
    --color-slate-300: #cbd5e1;
    --color-slate-400: #94a3b8;
    --transition-smooth: cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- Base Reset & Typography --- */
*, *::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(45, 212, 191, 0.3);
    color: #f8fafc;
}

/* --- Scrollbar --- */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: var(--color-slate-950);
}
::-webkit-scrollbar-thumb {
    background: var(--color-slate-700);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--color-teal-600);
}

/* --- Navbar --- */
#navbar {
    background: transparent;
    transition: background 0.5s var(--transition-smooth), box-shadow 0.5s var(--transition-smooth), backdrop-filter 0.5s var(--transition-smooth);
}

#navbar.scrolled {
    background: rgba(15, 23, 42, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(251, 191, 36, 0.1), 0 4px 30px rgba(0, 0, 0, 0.4);
}

/* --- Mobile Menu --- */
#mobileMenu {
    animation: slideDown 0.3s var(--transition-smooth) forwards;
}

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

.mobile-link {
    position: relative;
}

.mobile-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--color-gold-400);
    transition: width 0.3s var(--transition-smooth);
}

.mobile-link:hover::after {
    width: 100%;
}

/* --- Reveal Animations (progressive enhancement) --- */
.reveal-up,
.reveal-left,
.reveal-right {
    opacity: 1;
    transform: none;
    transition: opacity 0.8s var(--transition-smooth), transform 0.8s var(--transition-smooth);
}

@media (prefers-reduced-motion: no-preference) {
    .reveal-up {
        opacity: 0;
        transform: translateY(40px);
    }
    .reveal-left {
        opacity: 0;
        transform: translateX(-40px);
    }
    .reveal-right {
        opacity: 0;
        transform: translateX(40px);
    }
    
    .reveal-up.revealed,
    .reveal-left.revealed,
    .reveal-right.revealed {
        opacity: 1;
        transform: translate(0, 0);
    }
}

/* --- Stagger children --- */
.reveal-up:nth-child(1) { transition-delay: 0.05s; }
.reveal-up:nth-child(2) { transition-delay: 0.15s; }
.reveal-up:nth-child(3) { transition-delay: 0.25s; }
.reveal-up:nth-child(4) { transition-delay: 0.35s; }
.reveal-up:nth-child(5) { transition-delay: 0.45s; }
.reveal-up:nth-child(6) { transition-delay: 0.55s; }

/* --- Gold shimmer on hover for product cards --- */
.reveal-up.group .relative::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 0.75rem;
    border: 1px solid transparent;
    transition: border-color 0.4s var(--transition-smooth);
    pointer-events: none;
    z-index: 10;
}

.reveal-up.group:hover .relative::before {
    border-color: rgba(251, 191, 36, 0.2);
}

/* --- Button ripple effect --- */
button, a {
    -webkit-tap-highlight-color: transparent;
}

/* --- Image aspect ratios --- */
img {
    display: block;
    max-width: 100%;
}

/* --- Focus styles --- */
a:focus-visible,
button:focus-visible {
    outline: 2px solid var(--color-teal-400);
    outline-offset: 2px;
    border-radius: 4px;
}

/* --- Mobile menu button animation --- */
#menuIcon {
    transition: transform 0.3s var(--transition-smooth);
}

body.menu-open #menuIcon {
    transform: rotate(90deg);
}

/* --- Subtle gold gradient text utility --- */
.text-gold-gradient {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 50%, #d97706 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* --- Parallax-like slow scroll for hero --- */
#hero img {
    will-change: transform;
}

/* --- Card hover lift --- */
.rounded-2xl {
    transition: transform 0.4s var(--transition-smooth), box-shadow 0.4s var(--transition-smooth);
}

.rounded-2xl:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(251, 191, 36, 0.1);
}

/* --- Responsive adjustments --- */
@media (max-width: 640px) {
    html {
        font-size: 15px;
    }
    
    #hero h1 {
        font-size: 2.75rem;
        line-height: 1.1;
    }
    
    .font-serif.text-4xl {
        font-size: 2.25rem;
    }
}

@media (min-width: 641px) and (max-width: 1023px) {
    html {
        font-size: 16px;
    }
}

@media (min-width: 1024px) {
    html {
        font-size: 17px;
    }
}

/* --- Print styles --- */
@media print {
    #navbar,
    #hero img,
    section:not(#hero) img {
        display: none;
    }
    
    body {
        background: white;
        color: black;
    }
}
