/* ============================================
   David's Performance VW — Custom Styles
   Classic & Elegant · Midnight Blue + Mint
   ============================================ */

/* --- Custom Properties --- */
:root {
    --midnight-900: #0a1728;
    --midnight-800: #0f2238;
    --midnight-700: #15304d;
    --midnight-600: #1e4268;
    --midnight-500: #2d5a8a;
    --midnight-200: #a4b8d4;
    --midnight-100: #d0dbe8;
    --midnight-50: #f0f4f8;
    --mint-700: #00b37d;
    --mint-600: #00e6a3;
    --mint-500: #33ffbc;
    --mint-200: #ccffe9;
    --mint-100: #e6fff4;
}

/* --- Base Styles --- */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* --- Custom Scrollbar --- */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: var(--midnight-50);
}
::-webkit-scrollbar-thumb {
    background: var(--midnight-300);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--midnight-500);
}

/* --- Navbar Transition --- */
#navbar.scrolled {
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(10, 23, 40, 0.08);
}

#navbar.scrolled .nav-logo-text {
    color: var(--midnight-900);
}

#navbar.scrolled .nav-logo-sub {
    color: var(--midnight-500);
}

#navbar.scrolled .nav-link {
    color: var(--midnight-600);
}

#navbar.scrolled .nav-link:hover {
    color: var(--mint-700);
}

#navbar.scrolled .menu-line {
    background: var(--midnight-800);
}

/* --- Service Cards --- */
.service-card {
    position: relative;
    overflow: hidden;
}

.service-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--mint-600), var(--mint-400));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.5s ease;
}

.service-card:hover::after {
    transform: scaleX(1);
}

/* --- Gallery Items --- */
.gallery-item {
    height: 260px;
}

@media (min-width: 1024px) {
    .gallery-item {
        height: 300px;
    }
}

.gallery-item.row-span-2 {
    height: 540px;
}

@media (min-width: 1024px) {
    .gallery-item.row-span-2 {
        height: 620px;
    }
}

/* --- Mobile Menu --- */
#mobile-menu.open {
    transform: translateX(0);
}

#mobile-menu.closed {
    transform: translateX(100%);
}

/* --- Mobile Nav Links --- */
.mobile-nav-link {
    position: relative;
}

.mobile-nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 24px;
    height: 2px;
    background: var(--mint-600);
    transition: transform 0.3s ease;
}

.mobile-nav-link:hover::after {
    transform: translateX(-50%) scaleX(1);
}

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

.scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    
    .scroll-reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
    
    .service-card::after,
    .gallery-item img,
    .service-card .w-14 {
        transition: none;
    }
    
    .gallery-item:hover img {
        transform: none;
    }
}

/* --- Select Dropdown Fix --- */
select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}

/* --- Focus Visible --- */
*:focus-visible {
    outline: 2px solid var(--mint-600);
    outline-offset: 2px;
}

/* --- Selection --- */
::selection {
    background: var(--mint-200);
    color: var(--midnight-900);
}
