/* Custom styles for Cowboy Corner Market */

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

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #070e12;
}
::-webkit-scrollbar-thumb {
    background: #2a3640;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #3d4f5c;
}

/* Selection color */
::selection {
    background: rgba(201, 168, 76, 0.3);
    color: #f1f5f9;
}

/* Navbar transition */
#navbar {
    transition: background-color 0.4s ease, box-shadow 0.4s ease, padding 0.4s ease;
}

#navbar.scrolled {
    background-color: rgba(7, 14, 18, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.4);
}

/* Mobile menu */
#mobile-menu {
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

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

/* Scroll reveal animations - progressive enhancement */
.scroll-reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

/* Only apply reveal animation when JS is available and user prefers motion */
@media (prefers-reduced-motion: no-preference) {
    .scroll-reveal {
        opacity: 0;
        transform: translateY(24px);
        transition: opacity 0.7s ease, transform 0.7s ease;
    }
    .scroll-reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hero image hover */
.hero-img-hover:hover {
    transform: scale(1.03);
}

/* Gold accent line animation on hover */
a.no-underline:hover {
    text-decoration: none;
}

/* Button focus states for accessibility */
button:focus-visible,
a:focus-visible {
    outline: 2px solid #c9a84c;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Image loading placeholder */
img {
    background-color: #132b31;
}

/* Subtle grain texture overlay */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 9999;
    opacity: 0.015;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
}

/* Mobile menu button animation */
#menu-btn {
    transition: transform 0.2s ease;
}
#menu-btn:active {
    transform: scale(0.95);
}

/* Card hover effects */
.bg-dark-700\/60 {
    transition: border-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
}
.bg-dark-700\/60:hover {
    border-color: rgba(201, 168, 76, 0.25);
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
}

/* Gallery image hover */
.rounded-xl.overflow-hidden {
    transition: box-shadow 0.3s ease;
}
.rounded-xl.overflow-hidden:hover {
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
}

/* Teal accent glow */
.text-teal-400 {
    text-shadow: 0 0 20px rgba(42, 157, 159, 0.3);
}

/* Gold accent glow */
.text-gold-400 {
    text-shadow: 0 0 20px rgba(201, 168, 76, 0.3);
}

/* Mobile navigation link transitions */
.mobile-link {
    transition: opacity 0.3s ease;
}

/* Ensure all interactive elements have proper touch targets on mobile */
@media (max-width: 768px) {
    a, button {
        min-height: 44px;
        min-width: 44px;
    }
}

/* Print styles */
@media print {
    #navbar, #mobile-menu, .animate-bounce {
        display: none !important;
    }
    body {
        background: white;
        color: black;
    }
}
