/**
 * TransporterMarkt - Hauptstylesheet
 * Version: 2.1
 * 
 * Struktur:
 * 1. CSS Variablen (Theme)
 * 2. Reset & Basis
 * 3. Typography
 * 4. Layout & Container
 * 5. Header & Navigation
 * 6. Buttons
 * 7. Hero Section
 * 8. Search Section
 * 9. Vehicle Grid & Cards
 * 10. Empty State & Loading
 * 11. Footer
 * 12. Utilities
 * 13. Responsive
 */

/* ==========================================================================
   1. CSS VARIABLEN (THEME)
   ========================================================================== */

:root {
    /* Primärfarben */
    --color-primary: #ffffff;
    --color-primary-dark: #1a1a1a;
    
    /* Akzentfarbe (Karminrot) */
    --color-accent: #DC2626;
    --color-accent-dark: #B91C1C;
    --color-accent-light: #FEE2E2;
    
    /* Oberflächen */
    --color-surface: #f8fafc;
    --color-surface-dark: #f1f5f9;
    --color-card: #ffffff;
    
    /* Text */
    --color-text: #1e293b;
    --color-text-light: #ffffff;
    --color-text-muted: #64748b;
    
    /* Rahmen */
    --color-border: #e2e8f0;
    --color-border-dark: #cbd5e1;
    
    /* Status */
    --color-success: #16a34a;
    --color-error: #dc2626;
    --color-warning: #f59e0b;
    
    /* Schatten */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
    
    /* Abstände */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    --spacing-2xl: 48px;
    --spacing-3xl: 64px;
    
    /* Border Radius */
    --radius-sm: 6px;
    --radius: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    
    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition: 0.2s ease;
    --transition-slow: 0.3s ease;
    
    /* Z-Index */
    --z-header: 100;
    --z-modal: 200;
    --z-overlay: 1000;
}

/* ==========================================================================
   2. RESET & BASIS
   ========================================================================== */

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--color-text);
    background-color: var(--color-surface);
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

ul, ol {
    list-style: none;
}

button, input, select, textarea {
    font-family: inherit;
    font-size: inherit;
}

/* ==========================================================================
   3. TYPOGRAPHY
   ========================================================================== */

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.3;
    color: var(--color-text);
}

h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.1rem; }

/* ==========================================================================
   4. LAYOUT & CONTAINER
   ========================================================================== */

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
}

/* ==========================================================================
   5. HEADER & NAVIGATION
   ========================================================================== */

.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: var(--z-header);
    background: rgba(17, 17, 17, 0.97);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    transition: box-shadow var(--transition-slow);
}

.header.scrolled {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
}

/* Logo */
.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: #ffffff;
    font-weight: 700;
    font-size: 1.25rem;
}

.logo-icon {
    width: 44px;
    height: 44px;
    background: var(--color-accent);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-icon svg {
    width: 28px;
    height: 28px;
    fill: white;
}

.logo-text span {
    color: var(--color-accent);
}

/* Navigation */
.nav {
    display: flex;
    align-items: center;
    gap: var(--spacing-xl);
}

.nav-link {
    color: rgba(255, 255, 255, 0.75);
    font-weight: 500;
    transition: color var(--transition);
}

.nav-link:hover,
.nav-link.active {
    color: #ffffff;
}

/* ==========================================================================
   6. BUTTONS
   ========================================================================== */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
    padding: 12px 24px;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: all var(--transition);
}

.btn-primary {
    background: var(--color-accent);
    color: white;
}

.btn-primary:hover {
    background: var(--color-accent-dark);
}

.btn-secondary {
    background: var(--color-primary);
    color: var(--color-text);
    border: 1px solid var(--color-border);
}

.btn-secondary:hover {
    border-color: var(--color-border-dark);
    background: var(--color-surface);
}

.btn-lg {
    padding: 16px 48px;
    font-size: 1rem;
}

/* ==========================================================================
   7. HERO SECTION
   ========================================================================== */

.hero {
    padding: 120px 0 60px;
    text-align: center;
    background: linear-gradient(180deg, var(--color-accent-light) 0%, var(--color-surface) 100%);
}

.hero h1 {
    margin-bottom: var(--spacing-md);
}

.hero h1 span {
    color: var(--color-accent);
}

.hero-subtitle {
    color: var(--color-text-muted);
    font-size: 1.25rem;
    max-width: 600px;
    margin: 0 auto;
}

/* ==========================================================================
   8. SEARCH SECTION
   ========================================================================== */

.search-section {
    padding: 40px 0;
    margin-top: -40px;
}

.search-card {
    background: var(--color-card);
    border-radius: var(--radius-xl);
    padding: var(--spacing-xl);
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow-lg);
}

.search-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-lg);
    flex-wrap: wrap;
    gap: var(--spacing-md);
}

.search-header h2 {
    font-size: 1.25rem;
}

/* Search Tabs */
.search-tabs {
    display: flex;
    gap: var(--spacing-sm);
}

.search-tab {
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    color: var(--color-text-muted);
    cursor: pointer;
    transition: all var(--transition);
    font-size: 0.9rem;
}

.search-tab:hover {
    border-color: var(--color-border-dark);
    color: var(--color-text);
}

.search-tab.active {
    background: var(--color-accent);
    border-color: var(--color-accent);
    color: white;
}

/* Search Form */
.search-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--spacing-md);
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-group label {
    font-size: 0.85rem;
    color: var(--color-text-muted);
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 12px 16px;
    border-radius: var(--radius);
    border: 1px solid var(--color-border);
    background: var(--color-primary);
    color: var(--color-text);
    font-size: 0.95rem;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px var(--color-accent-light);
}

.form-group input::placeholder {
    color: var(--color-text-muted);
}

.form-group textarea {
    min-height: 120px;
    resize: vertical;
}

.search-actions {
    display: flex;
    gap: 12px;
    margin-top: var(--spacing-lg);
    flex-wrap: wrap;
}

.search-actions .btn {
    flex: 1;
    min-width: 150px;
}

/* Quick Search */
.quick-search {
    display: flex;
    gap: 12px;
    margin-top: var(--spacing-lg);
    padding-top: var(--spacing-lg);
    border-top: 1px solid var(--color-border);
    flex-wrap: wrap;
}

.quick-search .form-group {
    flex: 1;
    min-width: 200px;
}

.quick-search .btn {
    align-self: flex-end;
}

/* ==========================================================================
   9. VEHICLE GRID & CARDS
   ========================================================================== */

.results-section {
    padding: 40px 0 80px;
}

.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-lg);
    flex-wrap: wrap;
    gap: var(--spacing-md);
}

.results-count {
    color: var(--color-text-muted);
    font-size: 0.95rem;
}

.results-count strong {
    color: var(--color-accent);
}

.sort-select {
    padding: 10px 16px;
    border-radius: var(--radius);
    border: 1px solid var(--color-border);
    background: var(--color-card);
    color: var(--color-text);
    font-size: 0.9rem;
    cursor: pointer;
}

.sort-select:focus {
    outline: none;
    border-color: var(--color-accent);
}

/* Vehicle Grid */
.vehicle-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: var(--spacing-lg);
}

/* Vehicle Card */
.vehicle-card {
    background: var(--color-card);
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--color-border);
    transition: transform var(--transition), box-shadow var(--transition);
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    display: block;
}

.vehicle-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.vehicle-image {
    position: relative;
    aspect-ratio: 16/10;
    overflow: hidden;
    background: var(--color-surface-dark);
}

.vehicle-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.vehicle-card:hover .vehicle-image img {
    transform: scale(1.05);
}

.vehicle-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 600;
    background: var(--color-accent);
    color: white;
}

/* Kategorie-Badge (unten links) */
.category-badge {
    position: absolute;
    bottom: 12px;
    left: 12px;
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.95);
    color: var(--color-accent);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition), box-shadow var(--transition);
}

.category-badge svg {
    width: 20px;
    height: 20px;
}

.vehicle-card:hover .category-badge {
    transform: scale(1.1);
    box-shadow: var(--shadow);
}

.favorite-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition);
    box-shadow: var(--shadow-sm);
}

.favorite-btn:hover {
    background: white;
    box-shadow: var(--shadow);
}

.favorite-btn svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: var(--color-text-muted);
    stroke-width: 2;
}

.favorite-btn.active svg {
    fill: var(--color-accent);
    stroke: var(--color-accent);
}

.vehicle-content {
    padding: 20px;
}

.vehicle-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
    color: var(--color-text);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.vehicle-price {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--color-accent);
    margin-bottom: var(--spacing-md);
}

.vehicle-price .price-type {
    font-size: 0.8rem;
    font-weight: 400;
    color: var(--color-text-muted);
}

.vehicle-specs {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.spec-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.85rem;
    color: var(--color-text-muted);
}

.spec-item svg {
    width: 16px;
    height: 16px;
    color: var(--color-accent);
    opacity: 0.85;
}

/* Load More */
.load-more-container {
    text-align: center;
    margin-top: 40px;
}

/* ==========================================================================
   10. DEMO BANNER, EMPTY STATE & LOADING
   ========================================================================== */

.demo-banner {
    background: linear-gradient(90deg, var(--color-accent-light), #FEF3C7);
    border: 1px solid #FCD34D;
    border-radius: var(--radius);
    padding: 12px 20px;
    margin-bottom: var(--spacing-lg);
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.9rem;
    color: #92400E;
}

.demo-banner svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.demo-banner strong {
    color: #78350F;
}

.empty-state {
    text-align: center;
    padding: 80px 20px;
    color: var(--color-text-muted);
}

.empty-state svg {
    width: 80px;
    height: 80px;
    margin-bottom: 20px;
    opacity: 0.5;
}

.empty-state h3 {
    font-size: 1.25rem;
    margin-bottom: var(--spacing-sm);
    color: var(--color-text);
}

/* Loading Overlay */
.loading-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(255, 255, 255, 0.9);
    z-index: var(--z-overlay);
    align-items: center;
    justify-content: center;
}

.loading-overlay.active {
    display: flex;
}

.spinner {
    width: 48px;
    height: 48px;
    border: 3px solid var(--color-border);
    border-top-color: var(--color-accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ==========================================================================
   10.5 PARALLAX SECTION (Öffnungszeiten)
   ========================================================================== */

.parallax-section {
    position: relative;
    min-height: 400px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    display: flex;
    align-items: center;
}

/* iOS / Mobile: fixed-attachment ist nicht supported */
@supports (-webkit-touch-callout: none) {
    .parallax-section {
        background-attachment: scroll;
    }
}

.parallax-overlay {
    position: relative;
    width: 100%;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.parallax-content {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
    padding: 4rem 2rem;
}

.parallax-title {
    font-size: 2rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 1.5rem;
    letter-spacing: 0.02em;
    position: relative;
}

.parallax-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--color-accent);
    margin: 0.75rem auto 0;
    border-radius: 2px;
}

.parallax-text {
    font-size: 1.125rem;
    line-height: 2;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 400;
    letter-spacing: 0.01em;
}

.parallax-text strong {
    color: #ffffff;
    font-weight: 600;
}

@media (max-width: 768px) {
    .parallax-section,
    .parallax-overlay {
        min-height: 320px;
    }
    
    .parallax-content {
        padding: 3rem 1.5rem;
    }
    
    .parallax-title {
        font-size: 1.5rem;
    }
    
    .parallax-text {
        font-size: 1rem;
    }
}

/* ==========================================================================
   11. FOOTER
   ========================================================================== */

.footer {
    background: var(--color-primary-dark);
    color: var(--color-text-light);
    padding: 60px 0 30px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-col h4 {
    font-size: 1rem;
    margin-bottom: var(--spacing-md);
    color: var(--color-text-light);
}

.footer-col p,
.footer-col li {
    color: #94a3b8;
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.footer-col a {
    color: #94a3b8;
    transition: color var(--transition);
}

.footer-col a:hover {
    color: var(--color-accent);
}

/* Dealer Rating Widget */
.footer-rating {
    padding: 1.5rem 0;
    margin-top: 0.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    text-align: center;
}

.dealer-rating-widget {
    max-width: 500px;
    margin: 0 auto;
    border-radius: var(--radius);
    overflow: hidden;
}

.dealer-rating-widget iframe {
    max-width: 100%;
    border: none;
    border-radius: var(--radius);
}

.footer-bottom {
    padding-top: 30px;
    border-top: 1px solid #374151;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--spacing-md);
    color: #94a3b8;
    font-size: 0.9rem;
}

/* ==========================================================================
   12. DETAIL PAGE SPECIFIC
   ========================================================================== */

.back-link {
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-sm);
    color: var(--color-text-muted);
    text-decoration: none;
    font-weight: 500;
    transition: color var(--transition);
}

.back-link:hover {
    color: var(--color-text);
}

.back-link svg {
    width: 20px;
    height: 20px;
}

.detail-layout {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 40px;
    padding: 40px 0 80px;
}

/* Gallery */
.gallery {
    position: relative;
}

.gallery-main {
    aspect-ratio: 16/10;
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--color-border);
    margin-bottom: var(--spacing-md);
    box-shadow: var(--shadow);
}

.gallery-main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-thumbs {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: var(--spacing-sm);
}

.gallery-thumb {
    aspect-ratio: 16/10;
    border-radius: var(--radius-sm);
    overflow: hidden;
    cursor: pointer;
    border: 2px solid transparent;
    transition: border-color var(--transition);
}

.gallery-thumb.active {
    border-color: var(--color-accent);
}

.gallery-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-100%);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    color: var(--color-text);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow);
    transition: background var(--transition);
}

.gallery-nav:hover {
    background: white;
}

.gallery-nav.prev { left: 16px; }
.gallery-nav.next { right: 16px; }
.gallery-nav svg { width: 24px; height: 24px; }

/* Vehicle Info */
.vehicle-detail-title {
    font-size: 1.75rem;
    margin-bottom: var(--spacing-md);
}

.vehicle-detail-price {
    font-size: 2rem;
    font-weight: 700;
    color: var(--color-accent);
    margin-bottom: var(--spacing-lg);
}

.vehicle-detail-price .vat {
    font-size: 0.9rem;
    color: var(--color-text-muted);
    font-weight: 400;
}

/* Specs Grid */
.specs-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-xl);
}

.spec-card {
    background: var(--color-card);
    padding: var(--spacing-md);
    border-radius: var(--radius);
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow);
}

.spec-card .label {
    font-size: 0.85rem;
    color: var(--color-text-muted);
    margin-bottom: var(--spacing-xs);
}

.spec-card .value {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--color-text);
}

/* Section Title */
.section-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: var(--spacing-md);
    padding-bottom: 12px;
    border-bottom: 1px solid var(--color-border);
}

/* Description */
.description-box {
    background: var(--color-card);
    padding: var(--spacing-lg);
    border-radius: var(--radius-lg);
    margin-bottom: var(--spacing-xl);
    white-space: pre-wrap;
    color: var(--color-text-muted);
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow);
}

/* Features */
.features-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 12px;
    margin-bottom: var(--spacing-xl);
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: var(--color-card);
    border-radius: var(--radius);
    font-size: 0.95rem;
    border: 1px solid var(--color-border);
}

.feature-item svg {
    width: 18px;
    height: 18px;
    color: var(--color-success);
    flex-shrink: 0;
}

/* Sidebar (Frontend-Detailseite) */
.detail-layout > .sidebar {
    position: sticky;
    top: 92px;
    max-height: calc(100vh - 108px);
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--color-border) transparent;
}

.detail-layout > .sidebar::-webkit-scrollbar {
    width: 5px;
}

.detail-layout > .sidebar::-webkit-scrollbar-track {
    background: transparent;
}

.detail-layout > .sidebar::-webkit-scrollbar-thumb {
    background: var(--color-border);
    border-radius: 3px;
}

.detail-layout > .sidebar::-webkit-scrollbar-thumb:hover {
    background: var(--color-text-muted);
}

.contact-card {
    background: var(--color-card);
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow-lg);
}

.contact-card h3 {
    font-size: 1.1rem;
    margin-bottom: 20px;
}

.seller-info {
    margin-top: var(--spacing-lg);
    padding-top: var(--spacing-lg);
    border-top: 1px solid var(--color-border);
}

.seller-info h4 {
    font-size: 0.9rem;
    color: var(--color-text-muted);
    margin-bottom: var(--spacing-sm);
}

.seller-info p {
    font-size: 0.95rem;
    margin-bottom: var(--spacing-xs);
}

.seller-info a {
    color: var(--color-accent);
}

/* Form Messages */
.form-message {
    padding: 12px 16px;
    border-radius: var(--radius);
    margin-bottom: var(--spacing-md);
    display: none;
}

.form-message.show {
    display: block;
}

.form-message.success {
    background: rgba(22, 163, 74, 0.1);
    color: var(--color-success);
    border: 1px solid var(--color-success);
}

.form-message.error {
    background: rgba(220, 38, 38, 0.1);
    color: var(--color-accent);
    border: 1px solid var(--color-accent);
}

/* Honeypot */
.hp-field {
    position: absolute;
    left: -9999px;
}

/* ==========================================================================
   13. ERROR PAGES
   ========================================================================== */

.error-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.error-card {
    background: var(--color-card);
    padding: 60px 40px;
    border-radius: var(--radius-xl);
    text-align: center;
    max-width: 500px;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--color-border);
}

.error-code {
    font-size: 6rem;
    font-weight: 700;
    color: var(--color-accent);
    line-height: 1;
}

.error-card h1 {
    font-size: 1.5rem;
    margin: 20px 0 10px;
}

.error-card p {
    color: var(--color-text-muted);
    margin-bottom: 30px;
}

.error-suggestions {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid var(--color-border);
}

.error-suggestions h3 {
    font-size: 1rem;
    margin-bottom: 15px;
}

.error-suggestions li {
    margin: 8px 0;
}

.error-suggestions a {
    color: var(--color-accent);
}

.error-suggestions a:hover {
    text-decoration: underline;
}

/* ==========================================================================
   14. RESPONSIVE
   ========================================================================== */

@media (max-width: 968px) {
    .detail-layout {
        grid-template-columns: 1fr;
    }
    
    .sidebar {
        position: static;
        margin-top: 40px;
    }
}

@media (max-width: 768px) {
    .nav {
        display: none;
    }
    
    .nav.open {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 72px;
        left: 0;
        right: 0;
        background: #111111;
        padding: var(--spacing-lg);
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
        gap: var(--spacing-sm);
        z-index: 1000;
    }
    
    .nav.open .nav-link {
        color: rgba(255, 255, 255, 0.85);
        padding: 0.75rem 1rem;
        border-radius: 8px;
        transition: background 0.15s, color 0.15s;
    }
    
    .nav.open .nav-link:hover {
        background: rgba(255, 255, 255, 0.08);
        color: #ffffff;
    }
    
    .nav.open .btn {
        margin-top: 0.5rem;
        justify-content: center;
    }
    
    .mobile-menu-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 44px;
        height: 44px;
        background: none;
        border: none;
        cursor: pointer;
        color: #ffffff;
    }
    
    .search-form {
        grid-template-columns: 1fr;
    }
    
    .hero {
        padding: 100px 0 40px;
    }
    
    .hero h1 {
        font-size: 1.75rem;
    }
    
    .vehicle-grid {
        grid-template-columns: 1fr;
    }
    
    .specs-grid {
        grid-template-columns: 1fr;
    }
    
    .vehicle-detail-title {
        font-size: 1.4rem;
    }
    
    .vehicle-detail-price {
        font-size: 1.6rem;
    }
    
    .pagination {
        flex-wrap: wrap;
        gap: var(--spacing-sm);
    }
    
    .pagination-pages {
        order: -1;
        width: 100%;
        justify-content: center;
        margin-bottom: var(--spacing-sm);
    }
}

/* Desktop: Mobile Menu Button verstecken */
@media (min-width: 769px) {
    .mobile-menu-btn {
        display: none;
    }
}

/* ==========================================================================
   15. PAGINATION
   ========================================================================== */

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: var(--spacing-md);
    margin-top: 48px;
    padding-top: 32px;
    border-top: 1px solid var(--color-border);
}

.pagination-btn {
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: 10px 20px;
    background: var(--color-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    color: var(--color-text);
    font-weight: 500;
    font-size: 0.9rem;
    text-decoration: none;
    transition: all var(--transition);
}

.pagination-btn:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
}

.pagination-pages {
    display: flex;
    align-items: center;
    gap: 4px;
}

.pagination-page {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    background: var(--color-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    color: var(--color-text);
    font-weight: 500;
    font-size: 0.9rem;
    text-decoration: none;
    transition: all var(--transition);
}

.pagination-page:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
}

.pagination-page.active {
    background: var(--color-accent);
    border-color: var(--color-accent);
    color: white;
}

.pagination-ellipsis {
    padding: 0 8px;
    color: var(--color-text-muted);
}

/* Sort Form */
.sort-form {
    display: flex;
    align-items: center;
}

/* ==========================================================================
   16. LOAD MORE (Endless Scroll)
   ========================================================================== */

.load-more-container {
    text-align: center;
    margin-top: 48px;
    padding-top: 32px;
    border-top: 1px solid var(--color-border);
}

.load-more-container .btn {
    min-width: 250px;
}

.load-more-info {
    margin-top: 16px;
    font-size: 0.9rem;
    color: var(--color-text-muted);
}

.load-more-info span {
    font-weight: 600;
    color: var(--color-accent);
}

/* Spinner Animation */
@keyframes spin {
    to { transform: rotate(360deg); }
}

.spin-on-load {
    animation: spin 1s linear infinite;
    margin-right: 8px;
}

/* ==========================================================================
   17. FAHRZEUG-DETAILSEITE
   ========================================================================== */

/* Detail Header & Breadcrumb */
.detail-header {
    padding: 100px 0 20px;
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: var(--color-text-muted);
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.breadcrumb a {
    color: var(--color-text-muted);
    text-decoration: none;
}

.breadcrumb a:hover {
    color: var(--color-accent);
}

.breadcrumb svg {
    width: 16px;
    height: 16px;
    opacity: 0.5;
    flex-shrink: 0;
}

/* Key Facts */
.key-facts {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin: 24px 0;
    padding: 20px;
    background: var(--color-surface);
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
}

.key-fact {
    text-align: center;
}

.key-fact-icon {
    width: 40px;
    height: 40px;
    margin: 0 auto 8px;
    background: var(--color-accent-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-accent);
}

.key-fact-icon svg {
    width: 20px;
    height: 20px;
}

.key-fact-value {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--color-text);
}

.key-fact-label {
    font-size: 0.8rem;
    color: var(--color-text-muted);
}

/* Lightbox */
.lightbox {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.95);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.lightbox.active {
    display: flex;
}

.lightbox-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1001;
    transition: background 0.2s;
}

.lightbox-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.lightbox-nav:hover {
    background: rgba(255, 255, 255, 0.2);
}

.lightbox-nav.prev { left: 20px; }
.lightbox-nav.next { right: 20px; }

.lightbox-counter {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    color: white;
    font-size: 0.9rem;
    background: rgba(0, 0, 0, 0.5);
    padding: 8px 16px;
    border-radius: 20px;
}

/* Gallery Grid */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin-top: 12px;
}

.gallery-grid .gallery-thumb {
    aspect-ratio: 16/10;
    border-radius: var(--radius-sm);
    overflow: hidden;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.2s;
}

.gallery-grid .gallery-thumb:hover,
.gallery-grid .gallery-thumb.active {
    border-color: var(--color-accent);
}

.gallery-grid .gallery-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Kollabierbare Galerie */
.gallery-grid.collapsed .gallery-thumb-hidden {
    display: none;
}

.gallery-grid.expanded .gallery-thumb-hidden {
    display: block;
}

.gallery-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    margin-top: 12px;
    padding: 10px 16px;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    color: var(--color-text-muted);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition);
}

.gallery-toggle:hover {
    background: var(--color-card);
    border-color: var(--color-accent);
    color: var(--color-accent);
}

.gallery-toggle svg {
    width: 18px;
    height: 18px;
}

.gallery-toggle .icon-chevron {
    transition: transform var(--transition);
}

.gallery-toggle.expanded .icon-chevron {
    transform: rotate(180deg);
}

/* Description Formatting (CREOLE) */
.description-box .desc-hr {
    border: none;
    border-top: 1px solid var(--color-border);
    margin: 16px 0;
}

.description-box .desc-list {
    margin: 12px 0;
    padding-left: 0;
    list-style: none;
}

.description-box .desc-list li {
    padding: 4px 0 4px 20px;
    position: relative;
}

.description-box .desc-list li::before {
    content: "•";
    position: absolute;
    left: 0;
    color: var(--color-accent);
    font-weight: bold;
}

/* Similar Vehicles Section */
.similar-section {
    padding: 60px 0;
    background: var(--color-surface-dark);
}

.similar-section h2 {
    margin-bottom: 24px;
}

.similar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

/* Location / Google Maps Section */
.location-section {
    padding: 60px 0;
    background: var(--color-surface);
}

.location-section h2 {
    margin-bottom: 16px;
}

.location-address {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 24px;
    color: var(--color-text-muted);
    font-size: 1rem;
}

.location-address svg {
    color: var(--color-accent);
    flex-shrink: 0;
}

.maps-container {
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.maps-container iframe {
    display: block;
}

/* Mobile.de Link */
.mobile-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 16px;
    padding: 12px 16px;
    background: var(--color-surface);
    border-radius: var(--radius);
    font-size: 0.9rem;
    color: var(--color-text-muted);
    text-decoration: none;
    border: 1px solid var(--color-border);
    transition: all 0.2s;
}

.mobile-link:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
}

/* Responsive Detail */
@media (max-width: 768px) {
    .key-facts {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .gallery-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .lightbox-nav {
        width: 40px;
        height: 40px;
    }
    
    .lightbox-nav.prev { left: 10px; }
    .lightbox-nav.next { right: 10px; }
}

/* ==========================================================================
   Datenschutz-Checkbox & Formular-Extras
   ========================================================================== */

/* Captcha Box */
.captcha-box {
    background: #fffbeb;
    border: 1.5px solid #fbbf24;
    border-radius: var(--radius);
    padding: 1rem 1.25rem;
    margin: 0.5rem 0;
}

.captcha-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #92400e;
    font-weight: 600;
    font-size: 0.8125rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin-bottom: 0.625rem;
}

.captcha-header svg {
    color: #f59e0b;
    flex-shrink: 0;
}

.captcha-label {
    display: block;
    font-size: 0.9rem;
    color: #78350f;
    margin-bottom: 0.5rem;
}

.captcha-label strong {
    font-size: 1.1rem;
    color: #1e293b;
}

.captcha-box input[type="number"] {
    width: 100%;
    padding: 10px 14px;
    border: 1.5px solid #fbbf24;
    border-radius: var(--radius);
    font-size: 1.1rem;
    font-weight: 600;
    text-align: center;
    letter-spacing: 0.1em;
    background: #ffffff;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.captcha-box input[type="number"]:focus {
    outline: none;
    border-color: #f59e0b;
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.15);
}

.captcha-box input[type="number"]::placeholder {
    font-weight: 400;
    font-size: 0.875rem;
    letter-spacing: normal;
    color: #d4a062;
}

.form-group-check {
    margin-top: 0.5rem;
}

.check-label {
    display: flex;
    align-items: flex-start;
    gap: 0.625rem;
    cursor: pointer;
    font-size: 0.875rem;
    line-height: 1.5;
    color: var(--color-text-muted);
}

.check-label input[type="checkbox"] {
    width: 16px;
    height: 16px;
    min-width: 16px;
    margin-top: 0.15rem;
    accent-color: var(--color-accent);
    cursor: pointer;
}

.check-label a {
    color: var(--color-accent);
    text-decoration: underline;
}

.check-label a:hover {
    opacity: 0.8;
}
