/* Custom styles for Exceptional Driver Training */

:root {
    --charcoal-900: #0d0d0d;
    --charcoal-800: #1a1a1a;
    --charcoal-700: #2a2a2a;
    --coral-500: #e07a5f;
    --coral-400: #e8956f;
    --gold-400: #d4a574;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

/* Scroll reveal base - content always visible */
.scroll-reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

/* Reduced motion preference */
@media (prefers-reduced-motion: no-preference) {
    .scroll-reveal {
        opacity: 0;
        transform: translateY(30px);
    }
    
    .scroll-reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Navbar scroll effect */
nav.scrolled {
    background: rgba(13, 13, 13, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(212, 165, 116, 0.1);
}

nav.scrolled .font-display {
    text-shadow: 0 0 40px rgba(212, 165, 116, 0.3);
}

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

::-webkit-scrollbar-track {
    background: var(--charcoal-900);
}

::-webkit-scrollbar-thumb {
    background: var(--charcoal-700);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--gold-400);
}

/* Selection color */
::selection {
    background: rgba(224, 122, 95, 0.3);
    color: #fff;
}

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

/* Subtle card hover glow */
.group:hover .group-hover\:border-gold-400\/30 {
    border-color: rgba(212, 165, 116, 0.3);
}

/* Mobile menu transition */
#menu-overlay {
    animation: menuFadeIn 0.3s ease forwards;
}

@keyframes menuFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Menu link hover effect */
.menu-link {
    position: relative;
}

.menu-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--coral-500), var(--gold-400));
    transition: width 0.3s ease;
}

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

/* Input autofill styling for dark theme */
input:-webkit-autofill,
textarea:-webkit-autofill,
select:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 30px #1a1a1a inset !important;
    -webkit-text-fill-color: #fff !important;
}

/* Focus visible for accessibility */
button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: 2px solid var(--gold-400);
    outline-offset: 2px;
}

/* Smooth image loading */
img {
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

/* Prevent layout shift on images */
img {
    content-visibility: auto;
}
