/* Custom styles — overrides and additions beyond Tailwind */

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #020617;
}
::-webkit-scrollbar-thumb {
    background: #1e293b;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #334155;
}

/* Selection */
::selection {
    background: rgba(251, 191, 36, 0.2);
    color: #fbbf24;
}

/* Smooth scroll offset for fixed nav */
html {
    scroll-padding-top: 80px;
}

/* Hero scroll line animation */
@keyframes scrollPulse {
    0%, 100% { opacity: 0.3; transform: scaleY(0.8); }
    50% { opacity: 0.8; transform: scaleY(1.2); }
}
.scroll-line {
    animation: scrollPulse 2s ease-in-out infinite;
    transform-origin: top;
}

/* Navbar transition */
#navbar {
    transition: background-color 0.4s ease, backdrop-filter 0.4s ease, padding 0.4s ease;
}
#navbar.scrolled {
    background-color: rgba(2, 6, 23, 0.9);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(251, 191, 36, 0.08);
}

/* Nav links underline animation */
.nav-link {
    position: relative;
}
.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background: #fbbf24;
    transition: width 0.3s ease;
}
.nav-link:hover::after {
    width: 100%;
}

/* Mobile menu */
#mobile-menu.open {
    opacity: 1;
    pointer-events: all;
}

/* Feature card hover */
.feature-card {
    position: relative;
}
.feature-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, #fbbf24, transparent);
    transition: width 0.4s ease;
}
.feature-card:hover::after {
    width: 60%;
}

/* Menu card hover */
.menu-card {
    transition: border-color 0.5s ease, transform 0.5s ease, box-shadow 0.5s ease;
}
.menu-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3), 0 0 40px rgba(251, 191, 36, 0.04);
}

/* Reveal animations (progressive enhancement) */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.7s ease, transform 0.7s ease;
    }
    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
    .reveal:nth-child(2) { transition-delay: 0.1s; }
    .reveal:nth-child(3) { transition-delay: 0.2s; }
    .reveal:nth-child(4) { transition-delay: 0.3s; }
}

/* Reduced motion - ensure content is always visible */
@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
    }
    .scroll-line {
        animation: none;
        opacity: 0.5;
    }
}

/* Gold shimmer on hover for buttons */
@keyframes shimmer {
    0% { background-position: -200% center; }
    100% { background-position: 200% center; }
}

/* Subtle grain overlay */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    opacity: 0.025;
    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");
    z-index: 9999;
}

/* Image lazy load fade */
img[loading="lazy"] {
    transition: opacity 0.5s ease;
}
img[loading="lazy"]:not([src]) {
    opacity: 0;
}

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

/* Mobile menu link hover */
.mobile-menu-link {
    position: relative;
}
.mobile-menu-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 1px;
    background: #fbbf24;
    transition: width 0.3s ease;
}
.mobile-menu-link:hover::after {
    width: 100%;
}
