body {
    margin: 0;
}

html {
    scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

.homebutton {
    color: black;
    font-family: "Nimbus Mono", "Courier New", monospace;
    font-size: var(--schrift-gross); /* gleich gross wie der Projekttitel */
    position: absolute;
    z-index: 2;
    top: 20px;
    left: 20px;
    text-decoration: none;
}

.homebutton:hover {
    font-style: italic;
}

.projektbutton {
    position: absolute;
    z-index: 2;
    top: 20px;
    right: 20px;
    color: black;
    font-family: "Nimbus Mono", "Courier New", monospace;
    font-size: var(--schrift-gross); /* gleich gross wie der Projekttitel */
    text-decoration: none;
}

.projektbutton:hover {
    font-style: italic;
}


.bildbereich {
    display: grid;
    min-height: 100vh;
    place-items: center;
}

.bildbereich--titelbild {
    position: relative;
}

.bildbereich__motiv {
    display: grid;
    justify-items: center;
    gap: 2.5rem; /* Abstand zwischen Titelbild und Pfeil */
}

.bildbereich__pfeil {
    position: absolute;
    bottom: 7.5vh;
    left: 50%;
    color: black;
    font-family: "Nimbus Mono", "Courier New", monospace;
    font-size: 1rem;
    line-height: 1;
    text-decoration: none;
    transform: translateX(-50%);
}

.parisbild1 {
    display: block;
    width: calc(100vw - 2rem);
    max-height: 70vh;
    height: auto;
    object-fit: contain;
    pointer-events: none;
    user-select: none;
    -webkit-user-drag: none;
}

.projektinfo {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    justify-items: center;
    align-content: start;
    min-height: 100vh;
    padding: 5rem 1rem;
}

.projektinfo__titel {
    margin: 0;
    font-family: "Nimbus Mono", "Courier New", monospace;
    font-size: var(--schrift-gross); /* gleich gross wie die Navigation */
    font-weight: normal;
    text-align: center;
}

.projektinfo__text {
    width: min(100%, 22rem);
    margin: 1.25rem 0 0;
    font-family: "Nimbus Mono", "Courier New", monospace;
    font-size: var(--schrift-text); /* Lauftext, 14 px */
    line-height: 1.4;
}

@media (min-width: 40rem) {
    .projektinfo {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .projektinfo__titel,
    .projektinfo__text {
        grid-column: 2;
    }

    .projektinfo__text {
        width: 100%;
        max-width: none;
        justify-self: start;
    }
}

.bildbereich {
    display: grid;
    min-height: 100vh;
    place-items: center;
}

.projektinfo {
    min-height: auto;
    padding: 1rem;
}

.projektinfo__text {
    margin-top: 3.5rem; /* Abstand zwischen Titel und Lauftext */
}

.projektinfo + .bildbereich {
    min-height: auto;
    margin-top: calc(15vh - 3.5rem); /* gleicht den grösseren Textabstand aus, damit die Bilder an ihrer Stelle bleiben */
}

.bildbereich--galerie {
    min-height: auto;
    margin-bottom: 1.25rem;
}

.bildbereich--galerie:last-of-type {
    position: relative;
    margin-bottom: 0;
}

.bildbereich--galerie:last-of-type .bildbereich__pfeil {
    bottom: 2rem;
}

.bildbereich__pfeil--zurueck {
    color: white;
}

/* Pfeil als Vektorgrafik (data.pfeil/pfeil.svg). Die Breite bestimmt die Grösse,
   die Höhe ergibt sich aus dem Seitenverhältnis. Die Linie bleibt immer gleich dünn.
   invert(1) macht den schwarzen Pfeil weiss. */
.bildbereich__pfeilbild {
    display: block;
    width: 1rem;
    height: auto;
    filter: invert(1);
}

/* Ebenenmodus «Differenz» wie in Photoshop: Der weisse Pfeil erscheint
   auf hellem Grund schwarz und auf dunklem Grund weiss.
   Steht auf dem Link, weil transform dort eine eigene Ebene bildet. */
.bildbereich__pfeil {
    mix-blend-mode: difference;
}

/* Beim Titelbild steht der Pfeil direkt unter dem Bild statt am Bildschirmrand.
   Der Abstand kommt vom gap in .bildbereich__motiv. */
.bildbereich--titelbild .bildbereich__pfeil {
    position: static;
    transform: none;
}

/* Der Zurück-Pfeil ist dasselbe Bild, um 180° gedreht. */
.bildbereich__pfeil--zurueck .bildbereich__pfeilbild {
    transform: rotate(180deg);
}

.parisbild2 {
    display: block;
    width: 100vw;
    height: auto;
    aspect-ratio: 1735 / 1175.94;
    object-fit: cover;
    pointer-events: none;
    user-select: none;
    -webkit-user-drag: none;
}

/* Kleine Projektinfos unter dem Lauftext (Jahr und Art des Projekts). */
.projektinfo__daten {
    width: min(100%, 22rem); /* gleich breit wie der Lauftext auf dem Handy */
    margin: 4rem 0 0; /* Abstand zum Lauftext */
    font-family: "Nimbus Mono", "Courier New", monospace;
    font-size: var(--schrift-text); /* gleich gross wie der Lauftext */
    line-height: 1.4;
}

@media (min-width: 40rem) {
    /* Gleiche Spalte wie Titel und Lauftext */
    .projektinfo__daten {
        grid-column: 2;
        width: 100%;
        justify-self: start;
    }
}
