/* Custom styles for Thomas Brownlee & Sons Market */

/* Base styles */
html {
    scroll-behavior: smooth;
}

body {
    overflow-x: hidden;
}

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

::-webkit-scrollbar-track {
    background: #102a43;
}

::-webkit-scrollbar-thumb {
    background: #334e68;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: #1e8a62;
}

/* Selection */
::selection {
    background: rgba(53, 169, 126, 0.3);
    color: #f0f4f8;
}

/* Navigation */
.nav {
    background: rgba(10, 22, 40, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(51, 78, 104, 0.3);
}

.nav.scrolled {
    background: rgba(10, 22, 40, 0.95);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: #92e0c0;
    transition: width 0.3s ease;
}

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

/* Mobile menu */
.menu-line {
    transition: all 0.3s ease;
}

#menu-btn.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(4px, 4px);
}

#menu-btn.active .menu-line:nth-child(2) {
    opacity: 0;
}

.mobile-menu {
    animation: slideDown 0.3s ease;
    background: rgba(10, 22, 40, 0.98);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(51, 78, 104, 0.3);
}

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

.mobile-nav-link {
    position: relative;
    padding-left: 0;
}

/* Hero section */
.hero {
    background: #0a1628;
}

/* Stat cards */
.stat-card {
    animation: float 6s ease-in-out infinite;
}

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

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

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

.stat-card.card-4 {
    animation-delay: 4.5s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

/* Scroll line */
.scroll-line {
    animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
    0%, 100% {
        opacity: 0.3;
        height: 48px;
    }
    50% {
        opacity: 0.8;
        height: 60px;
    }
}

/* Reveal animations */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.revealed {
    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;
    }
    
    .stat-card {
        animation: none;
    }
}

/* Focus styles */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #92e0c0;
    outline-offset: 4px;
    border-radius: 4px;
}

/* Image loading */
img {
    image-rendering: auto;
}

/* Print styles */
@media print {
    .nav,
    .scroll-indicator,
    .stat-card {
        display: none;
    }
    
    body {
        background: white;
        color: black;
    }
}
