/* Custom styles for Access Defensive Driving School */

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

/* Custom animations */
@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-12px) rotate(1deg); }
}

@keyframes float-delayed {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-8px) rotate(-1deg); }
}

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

.animate-float-delayed {
    animation: float-delayed 5s ease-in-out infinite;
    animation-delay: 1s;
}

/* Scroll reveal animations (progressive enhancement) */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    }
    
    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
    
    .reveal-delay-1 { transition-delay: 0.1s; }
    .reveal-delay-2 { transition-delay: 0.2s; }
    .reveal-delay-3 { transition-delay: 0.3s; }
    .reveal-delay-4 { transition-delay: 0.4s; }
}

/* For browsers that don't support prefers-reduced-motion, content is still visible by default */
.reveal {
    opacity: 1;
    transform: none;
}

@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
    }
}

/* Navbar scroll effect */
.navbar-scrolled {
    background: rgba(10, 5, 18, 0.95) !important;
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(180, 100, 255, 0.1);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

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

::-webkit-scrollbar-track {
    background: #0a0512;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(to bottom, #7e4a9e, #d4a017);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(to bottom, #9c6db8, #fbbf24);
}

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

/* Card hover glow effect */
.course-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 1.5rem;
    opacity: 0;
    transition: opacity 0.5s ease;
    background: radial-gradient(ellipse at top, rgba(212, 160, 23, 0.08), transparent 70%);
    pointer-events: none;
}

.course-card:hover::before {
    opacity: 1;
}

/* Gold accent line animation */
.gold-line {
    position: relative;
}

.gold-line::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #d4a017, #fbbf24);
    border-radius: 2px;
    transition: width 0.3s ease;
}

.gold-line:hover::after {
    width: 100%;
}

/* Selection color */
::selection {
    background: rgba(212, 160, 23, 0.3);
    color: #f5f0f8;
}

/* Mobile menu transition */
#mobileMenu {
    transition: max-height 0.3s ease, opacity 0.3s ease;
}

/* Testimonial card subtle hover */
.testimonial-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.testimonial-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3), 0 0 40px rgba(212, 160, 23, 0.05);
}

/* Button ripple effect */
button, a {
    position: relative;
    overflow: hidden;
}

/* Focus styles for accessibility */
input:focus, select:focus, textarea:focus {
    outline: none;
    ring: 2px solid rgba(212, 160, 23, 0.5);
}

/* Reduce motion for accessibility */
@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;
    }
    
    .reveal {
        opacity: 1;
        transform: none;
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .font-display {
        font-size: clamp(1.75rem, 5vw, 2.5rem);
    }
}

/* Print styles */
@media print {
    nav, #contact, footer, .animate-float, .animate-float-delayed {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
}
