/* Custom styles for Teddy Foster Jr Grocers */

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0a1628;
}
::-webkit-scrollbar-thumb {
    background: #1a3a6e;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #d4a017;
}

/* Selection color */
::selection {
    background: #d4a017;
    color: #0a1628;
}

/* Navbar scroll effect */
.navbar-scrolled {
    background: rgba(10, 22, 40, 0.95) !important;
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(212, 160, 23, 0.1);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

/* Geometric shape animations */
@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(45deg); }
    50% { transform: translateY(-20px) rotate(45deg); }
}

@keyframes float-slow {
    0%, 100% { transform: translateY(0px) rotate(12deg); }
    50% { transform: translateY(-15px) rotate(12deg); }
}

/* Apply floating to decorative shapes */
.animate-float {
    animation: float 6s ease-in-out infinite;
}

.animate-float-slow {
    animation: float-slow 8s ease-in-out infinite;
}

/* Card hover glow */
.card-glow:hover {
    box-shadow: 0 0 40px rgba(212, 160, 23, 0.15);
}

/* Button ripple effect */
.btn-ripple {
    position: relative;
    overflow: hidden;
}

.btn-ripple::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn-ripple:active::after {
    width: 200px;
    height: 200px;
}

/* Image reveal animation */
.img-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

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

/* Geometric pattern overlay */
.geo-pattern {
    background-image: 
        linear-gradient(45deg, rgba(212, 160, 23, 0.03) 25%, transparent 25%),
        linear-gradient(-45deg, rgba(212, 160, 23, 0.03) 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, rgba(212, 160, 23, 0.03) 75%),
        linear-gradient(-45deg, transparent 75%, rgba(212, 160, 23, 0.03) 75%);
    background-size: 40px 40px;
    background-position: 0 0, 0 20px, 20px -20px, -20px 0px;
}

/* Mobile menu transitions */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
}

#mobile-menu.open {
    max-height: 400px;
    padding: 1rem 0;
}

/* Product card image container */
.product-img-container {
    overflow: hidden;
    position: relative;
}

.product-img-container::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 40%;
    background: linear-gradient(to top, rgba(15, 33, 64, 0.3), transparent);
    pointer-events: none;
}

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

/* Responsive adjustments */
@media (max-width: 768px) {
    .product-img-container img {
        height: 200px;
    }
    
    .img-reveal {
        opacity: 1;
        transform: translateY(0);
    }
}

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