html, body
{
    font-family: 'Century Gothic', Verdana, Arial, Helvetica, sans-serif;
	/*background: lightgrey;*/
}

body {
  margin: 0;
  position: relative;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: url("../img/maske2.jpg") center / cover no-repeat;
  opacity: var(--bg-opacity,1);
  z-index: 0;
}

body > * {
  position: relative;
  z-index: 1;
}


.upper-textbox {
  top: 10px;
  max-width: 1000px;
  width: 95%;        
  padding: 5px;
  background-color: lightgray;
  opacity: 0.8;
  border-radius: 15px; 
  position: relative;           /* für horizontale Zentrierung */
  left: 50%;                    /* verschiebt linke Kante auf 50% */
  transform: translateX(-50%);  /* korrigiert um die eigene Breite */
}

.lower-textbox {
  bottom: 10px;
  max-width: 1000px;
  width: 95%;        
  padding: 5px;
  display: block;
  left: 50%;                    
  transform: translateX(-50%);  
}

.viewer-scroll{
    position: relative;
    margin: 2em auto;
    padding: 0;
    width: 800px;  
    height: 620px; 
    background: lightgray;
    overflow: hidden;
    border-radius: 10px;
    box-shadow: 12px 12px 5px grey;
}

.viewer-content{
    padding: 0;
    margin: 495px auto;
    width: 785px;
    overflow: auto;
    white-space: nowrap;
}

.viewer-content .canvas{
    width: 789px;
    height: 475px;
    background: lightgray;
    background-size: cover;
	background-image: url("../img/cover.jpg");  
    position: absolute;
    text-align: center;
    color: #fff;
    left: 5px;
    top: 5px;
}


.gallery-image
{
    display: inline-block;
}

.gallery-image:hover img.preview-image{
    border: 3px solid lightgray;
}

.gallery-image img.preview-image{
    margin: 0px 0px 0px 5px;
    padding: 0px;
    height: 100px;
    border: 3px solid gray;
}

.gallery-image span{
    position: absolute;
    left: -5000px;
    overflow: hidden;
	
	display: flex;
    justify-content: center; /* Zentriert horizontal */
    align-items: center; /* Zentriert vertikal */
}

/*display huge image */
.gallery-image span img{
    max-width: 789px;
	max-height: 475px;
}

.gallery-image:hover span{
    left: 5px;
    top: 5px;
    width: 789px;
    height: 475px;
    background: lightgray;
}

@media (max-width: 1024px) {    
    .viewer-scroll {
        width: 95%;
        height: auto;
        margin: 1.5em auto;
    }

    .viewer-content {
        width: 100%;
        margin: 380px auto 0;
    }

    .viewer-content .canvas {
        width: calc(100% - 10px);
        height: 340px;
        background-repeat: no-repeat;
        background-position: center;
    }
    
    .gallery-image:hover span {
        width: 100%;
        height: 350px;
        left: 0;
        top: 0;
    }

    .gallery-image span img {
        max-width: 100%;
        max-height: 350px;
    }
}


@media (max-width: 768px) {

    .viewer-scroll {
        width: 100%;
        height: auto;
        border-radius: 0;
        box-shadow: none;
    }

    .viewer-content {
        margin: 300px auto 0;
        width: 100%;
    }

    .viewer-content .canvas {
        height: 255px;
    }

    .gallery-image img.preview-image {
        height: 70px;
        margin-left: 3px;
    }

    .gallery-image:hover span {
        height: 260px;
    }

    .gallery-image span img {
        max-width: 100%;
        max-height: 260px;
    }
}

@media (max-width: 480px) {

    .viewer-content {
        margin: 240px auto 0;
    }

    .viewer-content .canvas {
        height: 220px;
    }

    .gallery-image img.preview-image {
        height: 60px;
    }

    p, center {
        font-size: 0.9em;
    }
}

