/* Montserrat lokal einbinden */
@font-face {
  font-family: 'Montserrat';
  font-style: normal;
  font-weight: 400;
  src: url('fonts/montserrat-v25-latin-regular.woff2') format('woff2');
}
@font-face {
  font-family: 'Montserrat';
  font-style: normal;
  font-weight: 800;
  src: url('fonts/montserrat-v25-latin-800.woff2') format('woff2');
}

/* Den Rest deiner style.css wie gewohnt beibehalten */
:root {
    --text-main: #f0f0f0;
    --text-muted: #888888;
    --accent-glow: rgba(255, 255, 255, 0.2);
    --box-bg: rgba(20, 20, 20, 0.5); /* Noch edlerer Glas-Look */
    --box-border: rgba(255, 255, 255, 0.06);
    --transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1); /* Apple-artige Kurve */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Montserrat', sans-serif;
}

html {
    scroll-behavior: smooth;
}

/* --- ANIMIERTER HINTERGRUND --- */
@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

body {
    background: linear-gradient(-45deg, #050505, #151515, #0a0a0a, #1a1a1a);
    background-size: 400% 400%;
    animation: gradientBG 20s ease infinite;
    color: var(--text-main);
    line-height: 1.6;
    min-height: 100vh;
}

/* --- NEUE EXKLUSIVE ANIMATIONEN --- */
@keyframes slideBlurIn {
    0% {
        opacity: 0;
        transform: translateY(40px);
        filter: blur(10px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
        filter: blur(0);
    }
}

@keyframes subtlePulse {
    0% { box-shadow: 0 0 15px rgba(255,255,255,0.02); }
    50% { box-shadow: 0 0 30px rgba(255,255,255,0.08); }
    100% { box-shadow: 0 0 15px rgba(255,255,255,0.02); }
}

/* --- NAVIGATION & LOGO --- */
header {
    background: rgba(5, 5, 5, 0.7);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--box-border);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 1.2rem 0;
}

.nav-container {
    width: 90%;
    max-width: 1200px;
    margin: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    color: #fff;
    text-decoration: none;
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: 4px;
    text-transform: uppercase;
    transition: var(--transition);
}

.logo a:hover {
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.8);
}

.logo span {
    font-weight: 300;
    color: var(--text-muted);
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 30px;
}

.nav-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 2px;
    transition: var(--transition);
}

.nav-links a:hover, .nav-links a.active {
    color: #fff;
    text-shadow: 0 0 10px rgba(255,255,255,0.4);
}

/* --- NEUER HERO BEREICH (Startseite) --- */
/* --- NEUER HERO BEREICH (Startseite) --- */
.hero {
    min-height: 80vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0 20px;
    position: relative;
    overflow: hidden;
}

.hero-content {
    background: rgba(10, 10, 10, 0.3);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255,255,255,0.05);
    padding: 60px 40px;
    border-radius: 20px;
    max-width: 800px;
    margin: 0 auto; /* Stellt sicher, dass der Kasten exakt mittig sitzt */
    text-align: center; /* Zentriert den Text im Kasten */
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    opacity: 0;
    animation: slideBlurIn 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.hero-subtitle {
    display: block;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 4px;
    color: var(--text-muted);
    margin-bottom: 15px;
    opacity: 0;
    animation: slideBlurIn 0.6s ease forwards 0.1s;
}

.hero h1 {
    font-size: 3.5rem;
    font-weight: 300;
    letter-spacing: 2px;
    margin-bottom: 25px;
    color: #fff;
    opacity: 0;
    animation: slideBlurIn 0.6s ease forwards 0.2s;
}

.hero h1 strong {
    font-weight: 800;
}

.hero p {
    font-size: 1.1rem;
    color: #aaa;
    line-height: 1.8;
    margin-bottom: 40px;
    opacity: 0;
    animation: slideBlurIn 0.6s ease forwards 0.3s;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    opacity: 0;
    animation: slideBlurIn 0.6s ease forwards 0.4s;
}
body {
    background-color: #080808; /* Tiefes Schwarz-Grau */
    background-image:
        /* MINI Rot - Deutlich stärkerer Glow oben links */
        radial-gradient(circle at 0% 0%, rgba(213, 0, 0, 0.25) 0%, transparent 40%),
        /* BMW Blau - Deutlich stärkerer Glow unten rechts */
        radial-gradient(circle at 100% 100%, rgba(0, 102, 178, 0.25) 0%, transparent 40%),
        /* Technisches, edles Gitter-Muster (rein CSS, lädt immer!) */
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);

    /* Die Größe für das Gitter festlegen (30px Kästchen) */
    background-size: 100% 100%, 100% 100%, 30px 30px, 30px 30px;
    background-attachment: fixed;
    color: var(--text-main);
    line-height: 1.6;
    min-height: 100vh;
}
/* Premium Buttons */
.btn-primary, .btn-secondary {
    padding: 15px 35px;
    text-decoration: none;
    font-weight: 600;
    letter-spacing: 1px;
    border-radius: 6px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: #fff;
    color: #000;
    box-shadow: 0 0 15px rgba(255,255,255,0.1);
}

.btn-primary:hover {
    background: transparent;
    color: #fff;
    box-shadow: 0 0 30px rgba(255,255,255,0.4);
    border: 1px solid #fff;
    transform: translateY(-3px);
}

.btn-secondary {
    background: transparent;
    color: #fff;
    border: 1px solid rgba(255,255,255,0.3);
}

.btn-secondary:hover {
    border-color: #fff;
    background: rgba(255,255,255,0.05);
    box-shadow: 0 0 20px rgba(255,255,255,0.15);
    transform: translateY(-3px);
}

/* --- EDLE BOXEN (GLASSMORPHISM) --- */
.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto 100px;
}

.section-title {
    text-align: center;
    font-size: 2rem;
    font-weight: 300;
    letter-spacing: 5px;
    text-transform: uppercase;
    margin-bottom: 60px;
    color: #fff;
}

.section-title span {
    font-weight: 800;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.glass-box {
    background: var(--box-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--box-border);
    border-radius: 12px;
    padding: 40px 30px;
    text-align: center;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    animation: subtlePulse 4s infinite alternate;
}

.glass-box:hover {
    transform: translateY(-8px);
    border-color: rgba(255, 255, 255, 0.4);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6), 0 0 25px var(--accent-glow);
    background: rgba(30, 30, 30, 0.6);
}

.glass-box i {
    font-size: 2.5rem;
    color: #fff;
    margin-bottom: 20px;
    transition: var(--transition);
}

.glass-box:hover i {
    transform: scale(1.1);
    text-shadow: 0 0 15px rgba(255,255,255,0.5);
}

.glass-box h3 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    font-weight: 600;
    letter-spacing: 1px;
    color: #fff;
}

.glass-box p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.glass-box img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 20px;
    transition: var(--transition);
}

.glass-box:hover img {
    filter: brightness(1.1);
}

/* --- KONTAKT BOXEN --- */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.contact-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: var(--text-main);
    animation: none; /* Keine Pulse-Animation hier, da Hover reicht */
}

/* --- FOOTER --- */
footer {
    text-align: center;
    padding: 30px;
    border-top: 1px solid var(--box-border);
    color: var(--text-muted);
    font-size: 0.8rem;
    letter-spacing: 1px;
}
/* --- FIX: Kleine Icons in Fahrzeug-Details --- */
.glass-box ul i {
    font-size: 1rem !important;
    margin-bottom: 0 !important;
    transform: none !important;
    text-shadow: none !important;
}
/* --- DIGITALE PROBEFAHRT (ANIMATION) --- */
.test-drive-section {
    text-align: center;
    margin: 60px 0 20px;
    padding: 40px 0;
    position: relative;
    overflow-x: hidden; /* Verhindert, dass die Seite breiter wird, wenn das Auto rausfährt */
}

.car-wrapper {
    position: absolute;
    bottom: 20px;
    left: -150px; /* Startet unsichtbar links außerhalb des Bildschirms */
    font-size: 3.5rem;
    color: #fff;
    /* Ein sportlicher blauer BMW-Glow */
    filter: drop-shadow(0 0 15px rgba(0, 140, 255, 0.8));
    opacity: 0;
}

/* Diese Klasse wird per Klick hinzugefügt und startet die Fahrt */
.car-wrapper.drive {
    opacity: 1;
    animation: zoomAcross 8s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

@keyframes zoomAcross {
    0% {
        left: -150px;
        transform: skewX(0deg) scale(1);
    }
    15% {
        /* Beschleunigt: Lehnt sich nach vorne */
        transform: skewX(-15deg) scale(1.1);
    }
    85% {
        transform: skewX(-15deg) scale(1.1);
    }
    100% {
        left: 110%; /* Fährt rechts aus dem Bild */
        transform: skewX(0deg) scale(1);
    }
}

.btn-easteregg {
    background: transparent;
    color: var(--text-muted);
    border: 1px solid rgba(255,255,255,0.1);
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    transition: var(--transition);
    font-size: 0.8rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.btn-easteregg:hover {
    color: #fff;
    border-color: rgba(0, 140, 255, 0.5);
    box-shadow: 0 0 15px rgba(0, 140, 255, 0.2);
}
/* --- HANDY-FIX: Sichtbarkeit & Schöne Schrift --- */
@media (max-width: 768px) {
    html, body {
        overflow-x: hidden; /* Verhindert Wackeln nach links/rechts */
        width: 100%;
        margin: 0;
        padding: 0;
    }

    /* Wir nehmen die hässliche Silbentrennung wieder raus */
    p, h1, h2, h3, li, .glass-box {
        hyphens: none !important;
        -webkit-hyphens: none !important;
        word-wrap: normal;
    }

    .hero-content {
        width: 92%;           /* Nutzt fast die ganze Breite */
        margin: 20px auto;    /* Zentriert den Kasten mit Abstand oben/unten */
        padding: 30px 15px;   /* Kompakterer Innenabstand */
        box-sizing: border-box;
    }

    .hero h1 {
        /* Nutzt "vw" (Viewport Width) -> Schrift wird auf kleinen Handys automatisch kleiner */
        font-size: 8vw;
        min-size: 1.6rem;
        max-size: 2.2rem;
        line-height: 1.1;
        white-space: normal; /* Erlaubt natürlichen Zeilenumbruch */
    }

    .hero p {
        font-size: 0.95rem;
        line-height: 1.5;
        padding: 0 5px;
    }

    .glass-box {
        width: 92% !important;
        margin: 15px auto !important; /* Zentriert die Boxen auf dem Handy */
        padding: 20px;
        box-sizing: border-box;
        float: none; /* Verhindert, dass Boxen nebeneinander hängen wollen */
    }

    .glass-box ul li {
        font-size: 0.85rem;
        line-height: 1.4;
        display: block; /* Icons und Text untereinander, falls es zu eng wird */
        margin-bottom: 12px;
    }
}
/* --- Spezieller Fix für lange Wörter in Boxen --- */
@media (max-width: 768px) {

    .hero-content h1 {
        /* Nutzt etwas weniger Platz, damit links/rechts nichts anstößt */
        font-size: 7.5vw !important;
        padding: 0 5px;
    }

    /* Das hier fixiert das Wort "Gebrauchtwagen" */
    .glass-box h2,
    .glass-box h3,
    .glass-box p {
        font-size: 0.95rem !important; /* Minimal kleiner als Standard */
        letter-spacing: -0.2px;       /* Zieht die Buchstaben dezent zusammen */
        word-break: keep-all;         /* Verhindert das Zerhacken von Wörtern */
        overflow-wrap: normal;
    }

    /* Falls "Gebrauchtwagen" in einem Button oder Link steht */
    .btn-primary, .btn-secondary {
        font-size: 0.85rem !important;
        padding: 12px 20px !important;
        white-space: nowrap; /* Verhindert, dass der Button-Text umbricht */
    }
}
/* --- Fix für die Erreichbarkeit des Kontakt-Bereichs --- */
html, body {
    /* WICHTIG: Ersetze 'height: 100vh' durch 'min-height: 100vh' */
    height: auto !important;
    min-height: 100vh;
    overflow-y: visible !important; /* Stellt sicher, dass man scrollen kann */
    overflow-x: hidden; /* Verhindert Wackeln zur Seite */
}

.test-drive-section {
    /* Damit nach dem fahrenden Auto noch genug Platz für den Kontakt ist */
    margin-bottom: 60px;
}

#kontakt {
    /* Extra Abstand unten, damit der letzte Text nicht am Handy-Rand klebt */
    padding-bottom: 80px !important;
    display: block !important;
    visibility: visible !important;
}
/* --- HAMBURGER MENÜ DESIGN (HANDY) --- */

/* Versteckt den Button auf dem normalen PC-Bildschirm */
.menu-toggle {
    display: none;
    color: #fff;
    font-size: 1.8rem;
    cursor: pointer;
    transition: color 0.3s ease;
}

.menu-toggle:hover {
    color: var(--primary-color);
}

/* Regeln nur für Handys (Bildschirme kleiner als 768px) */
@media (max-width: 768px) {
    .menu-toggle {
        display: block; /* Zeigt die 3 Striche auf dem Handy */
    }

    .nav-links {
        display: none; /* Versteckt die normale Leiste */
        flex-direction: column;
        position: absolute;
        top: 70px; /* Abstand von oben (anpassen, falls es das Logo überdeckt) */
        left: 0;
        width: 100%;
        background: rgba(10, 10, 10, 0.98); /* Edler, fast schwarzer Hintergrund */
        backdrop-filter: blur(15px); /* Glas-Effekt */
        padding: 20px 0;
        border-bottom: 2px solid var(--primary-color);
        box-shadow: 0 10px 30px rgba(0,0,0,0.8);
        z-index: 1000;
    }

    .nav-links.active {
        display: flex; /* Zeigt das Menü an, wenn man draufklickt */
    }

    .nav-links li {
        margin: 15px 0;
        text-align: center;
    }

    .nav-links a {
        font-size: 1.3rem;
        display: block;
        padding: 10px;
    }
}

.emoji-car {
    display: inline-block;
    font-size: 42px;
    line-height: 1;
}

.drive-object {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 70px;
    height: 70px;
    font-size: 60px;
    line-height: 1;
    font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
    transform: scaleX(-1);
}