/* 1. GRUND-LAYOUT & SCHRIFT */
body {
    /* Verwendung von Helvetica für klare Darstellung */
    font-family: Helvetica, Arial, sans-serif; 
    line-height: 1.6;
    margin: 0;
    padding: 0;
    color: #333;
    background-color: #f4f4f4;
}

/* 2. NAVIGATION (DYNAMISCH AUS DER ANSICHT) */
nav {
    background: #2c3e50;
    padding: 1rem;
    display: flex;
    justify-content: center;
    gap: 10px;
}

nav a {
    color: white;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.1rem;
}

nav a:hover {
    color: #3498db;
    text-decoration: underline;
}

/* 3. CONTAINER FÜR DEN INHALT */
.container {
    max-width: 1000px;
    margin: 20px auto;
    padding: 30px;
    background: white;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    border-radius: 8px;
}

/* 4. TYPOGRAFIE (FLUID & IPHONE-OPTIMIERT) */
h1 {
    /* Passt sich stufenlos der Bildschirmbreite an */
    font-size: clamp(1.4rem, 5vw, 2.5rem); 
    color: #2c3e50;
    line-height: 1.2;
    margin-top: 0;
    /* Verhindert unschöne Umbrüche bei langen Titeln wie in Ettlingen */
    word-wrap: break-word;
    hyphens: auto;
}

h2 {
    font-size: clamp(1.2rem, 3vw, 1.8rem);
    color: #7f8c8d;
    margin-bottom: 20px;
}

/* 5. BILDER-GALERIE (RUNDGANG & LAGE) */
.gallery {
    display: grid;
    /* Erzeugt automatisch Spalten (mind. 300px), die sich dem Platz anpassen */
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.gallery figure {
    margin: 0;
    border: 1px solid #ddd;
    border-radius: 10px;
    overflow: hidden;
    transition: transform 0.3s ease;
}

.gallery figure:hover {
    transform: scale(1.02);
}

.gallery img {
    width: 100%;
    height: 250px;
    /* Verhindert Verzerrung bei unterschiedlichen Bildformaten */
    object-fit: cover; 
    display: block;
}

.gallery figcaption {
    padding: 12px;
    background: #fcfcfc;
    text-align: center;
    font-size: 0.95rem;
    border-top: 1px solid #eee;
}

/* 6. SPEZIFISCHE MEDIA-QUERIES FÜR MOBILE GERÄTE (IPHONE) */
@media (max-width: 600px) {
    nav {
        /* Stapelt Menüpunkte wie Mietbedingungen und Rundgang untereinander[cite: 1] */
        flex-direction: column; 
        align-items: center;
        gap: 12px;
    }

    nav a {
        width: 100%;
        text-align: center;
        padding: 8px 0;
        border-bottom: 1px solid #3e4f5f;
    }

    .container {
        width: 90%;
        margin: 10px auto;
        padding: 15px;
    }

    /* Optimierung für den Slogan und Pendler-Infos[cite: 1] */
    .hero-text {
        text-align: center;
        font-size: 1.1rem;
    }
}