/* Allgemeine Reset-Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Hintergrund und Textfarben */
body {
    background-color: #1e1e1e;
    color: #ffffff;
    font-family: Arial, sans-serif;
}

/* Navigation */
header {
    width: 100%;
    background-color: #222222;
    padding: 20px 0;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

.logo a {
    color: #ffffff;
    text-decoration: none;
    font-size: 24px;
    font-weight: bold;
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin-left: 20px;
}

.nav-links a {
    color: #ffffff;
    text-decoration: none;
    font-size: 18px;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: #ff6347; /* Orange Hover-Effekt */
}

/* Sprachauswahl */
.language-select a {
    color: #ffffff;
    text-decoration: none;
    margin-left: 10px;
    font-size: 16px;
}

/* Hover für Sprachlinks */
.language-select a:hover {
    color: #ff6347;
}

/* Startseite */
.home {
    text-align: center;
    padding: 100px 20px;
}

.home h1 {
    font-size: 36px;
    margin-bottom: 20px;
}

.home p {
    font-size: 18px;
}

/* Fotogalerie */
.gallery {
    text-align: center;
    padding: 50px 20px;
}

.gallery h1 {
    font-size: 36px;
    margin-bottom: 40px;
    color: #ffffff;
}

.gallery-container {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap; /* Damit Bilder in mehreren Reihen angezeigt werden, wenn nötig */
}

.gallery-item {
    width: 300px;
    height: 200px;
    object-fit: cover;
    cursor: pointer;
    transition: transform 0.3s ease;
    margin-bottom: 20px; /* Abstand nach unten für das nächste Bild */
}

.gallery-item:hover {
    transform: scale(1.05);
}

/* Vergrößerte Ansicht */
/* Zentrierung des gesamten Modal-Containers im Fenster */
.photo-modal {
    display: none;
    position: absolute;
    margin: 0 auto;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: hidden; /* Verhindert, dass das Bild über den Container hinaus ragt */
    background-color: rgba(0, 0, 0, 0.8);
    padding: 20px;
    opacity: 0;
    transition: opacity 0.5s ease;
    display: flex;
    justify-content: center; /* Zentriert das Modal im Fenster */
    align-items: center; /* Vertikale Zentrierung */
}

.photo-modal.show {
    opacity: 1; /* Modal sichtbar machen */
}
.photo-modal-content {
    display: flex;
    margin: 0 auto;
    justify-content: center;
    background-color: #333;
    padding: 20px;
    border-radius: 10px;
    max-width: 90%; /* Der Container kann maximal 90% der Breite einnehmen */
    max-height: 90vh; /* Maximale Höhe des Containers */
    overflow: hidden; /* Verhindert Überlaufen */
    flex-wrap: wrap;
}


.photo-left,
.photo-right {
    flex: 1;
    padding: 20px;
    box-sizing: border-box;
}

.photo-left {
    flex: 0 1 60%; /* Das Bild nimmt maximal 60% der Breite ein */
    width: 50%;
    padding: 10px;
    text-align: center;
}

.photo-right {
    flex: 0 1 30%; /* Der Text nimmt maximal 35% der Breite ein */
    color: #fff;
    padding: 20px;
}

.nav-button-backward, .nav-button-forward {
    padding: 15px; /* Kleinere Pfeiltasten */
    margin-top: 50px;
    font-size: 18px;
    background: transparent;
    color: white;
    border: 1px solid transparent;
    opacity: 0.4;
    position: relative;
    width:50px;
}

.nav-button-forward  {
  left: 0px;
}


/* Das Bild im Modal richtig skalieren */
#modal-photo {
    max-width: 100%; /* Bild nimmt maximal 90% der Viewport-Breite ein */
    max-height: 80vh; /* Bild nimmt maximal 80% der Viewport-Höhe ein */
    object-fit: contain; /* Das Bild behält sein Seitenverhältnis bei */
    width: auto; /* Breite automatisch anpassen */
    height: auto; /* Höhe automatisch anpassen */
}

/* Verkleinerung auf mobilen Geräten */
@media (max-width: 768px) {
    .gallery-item {
        width: 100%; /* Galerie-Bilder nehmen volle Breite ein */
        height: auto; /* Höhe wird automatisch angepasst */
    }

    .photo-modal-content {
        flex-direction: column; /* Inhalt wird auf kleinere Bildschirme in Spalten umgewandelt */
    }

    .photo-left,
    .photo-right {
      align-items: center;
        max-width: 100%;
        padding: 10px;
    }

    #modal-photo {
        max-width: 90%; /* Bild wird maximal 90% der Container-Breite einnehmen */
        max-height: 80vh; /* Maximale Höhe des Bildes wird auf 80% der Viewport-Höhe beschränkt */
        object-fit: contain; /* Skaliert das Bild, behält aber das Seitenverhältnis bei */
    }

    .nav-button {
        padding: 15px; /* Kleinere Pfeiltasten */
        font-size: 18px;
    }

    h2 {
        font-size: 20px; /* Kleinere Schrift für den Titel */
    }

    p {
        font-size: 14px; /* Kleinere Schrift für den Text */
    }
}

/* Verkleinerung auf sehr kleinen Geräten (z.B. Smartphones) */
@media (max-width: 480px) {
    .gallery h1 {
        font-size: 28px; /* Kleinere Überschrift */
    }

    .nav-button {
        padding: 10px; /* Noch kleinere Pfeiltasten */
        font-size: 16px;
    }

    h2 {
        font-size: 18px; /* Titel weiter verkleinern */
    }

    p {
        font-size: 12px; /* Text weiter verkleinern */
    }
}
