html {
  font-size: 100%;
  text-align: left;
}

.container {
  display:inline-flex;
  gap: 20px;
          /* väli lokeroiden väliin */
}

.box:first-child {
  flex: 20;
}

.box:last-child {
  flex: 30;
}



.banner {
  opacity: 0;
  transform: translateY(0px);
  animation: bannerIn 3.0s ease-out forwards;
}

@keyframes bannerIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.banner2 {
  opacity: 0;
  transform: translateY(0px);
  animation: bannerIn 1.0s ease-out forwards;
}

@keyframes bannerIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

body {
  background-color: white;
  color: gery;
  font-size: 16px;


  font-family: times, Helvetica, monospace;
  padding: 0px;
  margin: 0px;
}

h3 {
  font-size: 23px;
  font-weight: normal;
  color: grey;
  margin-top: 20px;
  margin-bottom: 10px;

}

.nav {
  background-color: white;

  color: white;
  margin: 0 auto;
  background-position: center center;
}

.nav ul {
  padding: 10px;
  list-style-type: none;
  margin: 0px;
  font-size: 0px;

}

.nav a {
  text-decoration: none;  /* poistaa alleviivauksen */
  color: grey;

}


.nav ul li {
  padding: 8px;
  text-align: left;
  font-size: 1.0rem;
  border-bottom: 1.8px solid white;
  transition: backround-color 2.2s;
  border-radius: 5px;
}

.nav ul li:hover {
  background-color: #ededeb;
}

.image-area {
  background-image: url("Pekka2.jpg");

  padding-top: 480px;
  padding-bottom: 350px;

  background-size: cover;

  height: auto;
  width: 170px;


}

.centered-container {
  max-width: 1020px;
  margin: 0px auto;
  padding: 0px 16px;
}

.image-text {
  text-align: center;
  background-color: white;
  color: grey;
  font-size: 1.0rem;
  max-width: 1020px;
  font-style: italic;

}

.Intro-text {
  max-width: 1020px;
  margin: 0px auto;
  text-align: left;
  color: grey;
  font-size: 1.0rem;
  padding-top: 50px;
  padding-bottom: 50px;


}

.centered-container {

  text-align: left;
  margin-bottom: 32px;


}

.centered-container p {
  padding: 0px 16px;
  color: whitesmoke;
}

#teksti {
  transition: opacity 0.2s ease;
}

.carousel {
  position: relative;
  width: 500px;          /* säädä CV:hen sopivaksi */
  height: 500px;
  margin: 20px auto;
  overflow: hidden;
  border-radius: 8px;
}

.slide {
  position: absolute;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.slide.active {
  opacity: 1;
}

.nav2 {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.5);
  color: white;
  border: none;
  padding: 8px 12px;
  cursor: pointer;
}

.prev { left: 5px; }
.next { right: 5px; }


@media screen and (min-width: 800px) {


  .nav ul {
    text-align: left;
  }

  .nav ul li {
    display: inline-block;
    color: grey;
    border-bottom: 0px solid white;
    border-left: 2px solid white;
    border-right: 2px solid white;
    text-align: left;

  }

  .nav ul li:hover {
    background-color: #ededeb;
  }

  .centered-container {
    /*width: 50%;*/
    float: left;
  }

  .image-text {
    text-align: left;
    background-color: white;

    width: 500px;
    color: grey;
    font-size: 1.5rem;
    margin: 0px auto 30px auto;
  }

  .image-area {
    background-image: url("Pekka.jpg");
    padding-top: 500px;
    padding-bottom: 1000px;
    background-position: left;
    background-size: cover;

    height: auto;
    width: 500px;


  }

  .container {
  display:inline-flex;
       /* väli lokeroiden väliin */
}

.box:first-child {
  flex: auto;


}

.box:last-child {
  flex: auto;

}



  #teksti {
  transition: opacity 0.2s ease;
}

.carousel {
  position:  sticky;
  width: 400px;          /* säädä CV:hen sopivaksi */
  height: 300px;
  margin: 20px ;
  overflow: hidden;
  border-radius: 8px;
}

.slide {
  position: absolute;
  width: 100%;
  height: 100%;
  object-fit: contain;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.slide.active {
  opacity: 1;
}

.nav2 {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.5);
  color: white;
  border: none;
  padding: 8px 12px;
  cursor: pointer;
}

.prev { left: 5px; }
.next { right: 5px; }
}