:root {
  --primColor: #ffffff;
  --secoColor: #555555;
  --cornerRad: 6px;
}
body {
  background-color: var(--primColor);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 20px;
}

  article[id*=post-] {
      padding: 0 0 10px 0; /* for ie8 & below */
      padding: 0 0 1rem 0; 
      margin: 0 8% 60px 0; /* for ie8 & below */
      margin: 0 8% 6rem 0;
      word-wrap: break-word;
      border-bottom: 1px solid #ececec;
      z-index: -100;
    }

  .menu-text {
    /*font-family: 'Karla' !important;*/
    font-family: Verdana, Geneva, Tahoma, sans-serif !important;
    text-transform: none !important;
    /*font-weight:100 !important;*/
    color: #0c5aa6;
    font-size: 14px;
    text-align: center;
    height: auto;
    position: static;
    top: 20px;
    transform: translate(45px, 60px);
  }

  .main-text {
    padding-top: 10px; 
    padding-top: 1.0rem;/* /* for ie8 & below */
    /*font-family: 'Karla' !important;*/
    font-family: "Fjalla One",sans-serif;
    /*font-style:italic !important;*/
    /*text-transform: none !important;*/
    text-transform: uppercase;
    letter-spacing: 7px;
    text-align: left;
    font-weight: 100 !important;
    color: #0c5aa6;
    font-size: 25px;
    /*text-align: center;*/
    margin: 3.0vw;
    position: absolute; /*relative*/
    top: 55px;
    left: 5%;
    /*transform: translate(-5%, -50%);*/
    z-index: -1;
  }

  .main-text h1 {
    font-size: 35px;
  }
  .main-text h2 {
    font-size: 30px;
  }
  .main-text h3 {
     font-size: 13px;
     color: var(--secoColor);
     text-transform: lowercase;
  }

  .main-image {
    background-color: #fff;
    height: 15em;
    height: 150px;
    margin-bottom: 1em;
    background-position-x: 45%;
    background-position-y: 68%;
    background-repeat: no-repeat;
    background-size: auto; /* cover */
    position: relative; top: -65px; left: -15px; text-align: center;
    opacity: 0.98;
    filter: alpha(opacity=98); /* For E8 and earlier */
    z-index: 99;
  }

  .main-image:after {
    background: inherit;
    bottom: 0;
    content: '';
    display: block;
    height: 120%;
    left: 0;
    position: absolute;
    right: 0;
    transform: skewY(-4deg);
    transform-origin: 100%;
    z-index: -99;
  }

  img.logo1{width: 140px; height: auto; margin-top: 2em; margin-lef: 12px; margin-right: 12px; margin-bottom: 5px;}
  h2.heading-white {margin-top: 1em; color: white; font-size: 1.2rem;}
  h2.heading-black {height: 15px; margin-top: 15px; margin-bottom: 1em; padding-top: 15px; color: black; font-size: 1.2em;}

details {
  margin: 20px;
}
summary {
  writing-mode: vertical-lr;
  /*text-align: center;*/
  padding: 12px 10px;
  width: 23px;
  height: 17px;
  background-color: var(--primColor);
  border: 2px solid var(--secoColor);
  border-radius: var(--cornerRad);
  color: var(--secoColor);
  cursor: pointer;
  user-select: none;
  outline: none;
  transition: transform 200ms ease-in-out 1s;
}
summary::before,
summary::after {
  position: static;
  top: 0;
  left: -2em;
}
summary::before {
  content: "";
}
summary::after {
  content: "III";
  margin-top: -7px;
  margin-left: -18px;
  /*content: url("../img/nappi/menuicon2.png");*/
  letter-spacing: 0px;
}
summary:hover {
  transform: scale(1.1);
}
summary::marker {
  font-size: 0;
}
summary::-webkit-details-marker {
  display: none;
}
details[open] .menu {
  animation-name: menuAnim;
}
details[open] summary::before {
  content: "X";
}
details[open] summary::after {
  content: "";
}
.menu {
  height: 0;
  width: fit-content;
  border-radius: var(--cornerRad);
  background-color: var(--primColor);
  box-shadow: 0 4px 12px 0 rgba(0, 0, 0, 0.2);
  margin-top: 8px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  animation: closeMenu 300ms ease-in-out forwards;
}
.menu a {
  padding: 12px 24px;
  margin: 0 16px;
  color: var(--secoColor);
  border-bottom: 2px solid rgba(0, 0, 0, 0.1);
  text-decoration: none;
  text-align: center;
  transition: filter 200ms linear 0s;
}
.menu a:nth-of-type(1) {
  padding-top: 24px;
}
.menu a:nth-last-of-type(1) {
  border-bottom: none;
}
.menu a:hover {
  filter: brightness(200%);
}
details::before {
  content: "← Valikko";
  color: var(--secoColor);
  position: absolute;
  margin-left: -28em;
  padding: 10px 10px;
  opacity: 0.4;
}

details[open]::before {
  animation: fadeMe 300ms linear forwards;
}

@keyframes menuAnim {
  0% {
    height: 0;
  }
  100% {
    height: 312px;
  }
}

@keyframes fadeMe {
  0% {
    opacity: 0.4;
  }
  100% {
    opacity: 0;
  }
}
/* ----------------------------------------------------*/
@media only screen and (max-width: 980px) {

  img.logo1{width: 140px; height: auto; margin-top: 5em; margin-lef: 12px; margin-right: 12px; margin-bottom: 5px;}
  h2.heading-white {margin-top: 1em; color: white; font-size: 12px;}
  h2.heading-black {height: 10px; margin-top: 10px; margin-bottom: 1em; padding-top: 10px; color: black; font-size: 12px;}

  .main-image {
    /*height: 35vh;*/
    width: 100%;
  }
  .main-text { 
    padding-top: 30px; 
    padding-top: 3.0rem;/* /* for ie8 & below */
    top: 65px;
    left: 5%;
  }
  .main-text h1 { 
    font-size: calc(35px + 6 * ((100vw - 980px) / 680));
  }
  .main-text h2 { 
    font-size: calc(20px + 6 * ((100vw - 980px) / 680));
  }
  .main-text h3 { 
    font-size: calc(16px + 4 * ((100vw - 980px) / 680));
    text-transform: lowercase;
  }

  .menu {
    height: 0;
    width: fit-content;
    border-radius: var(--cornerRad);
    background-color: var(--primColor);
    box-shadow: 0 4px 12px 0 rgba(0, 0, 0, 0.2);
    margin-top: 30px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
    animation: closeMenu 600ms ease-in-out forwards;
  }
  .menu a {
    padding: 12px 24px;
    margin: 0 16px;
    color: var(--secoColor);
    border-bottom: 2px solid rgba(0, 0, 0, 0.1);
    text-decoration: none;
    text-align: center;
    transition: filter 200ms linear 0s;
  }
  .menu a:nth-of-type(1) {
    padding-top: 24px;
  }
  .menu a:nth-last-of-type(1) {
    border-bottom: none;
  }
  .menu a:hover {
    filter: brightness(200%);
  }
  details {
    margin: 30px;
  }

  details::before {
    content: "← Valikko";
    color: var(--secoColor);
    position: absolute;
    margin-left: -60px;
    padding: 10px 10px;
    opacity: 0.4;
  }

  summary {
    writing-mode: vertical-lr;
    text-align: center;
    padding: 12px 10px;
    width: 23px;
    height: 17px;
    background-color: var(--primColor);
    border: 2px solid var(--secoColor);
    border-radius: var(--cornerRad);
    color: var(--secoColor);
    cursor: pointer;
    user-select: none;
    outline: none;
    transition: transform 200ms ease-in-out 1s;
  }
  summary::before,
  summary::after {
    /*position: static;*/
    top: 0;
    left: 0;
  }
  summary::before {
    content: "";
  }
  summary::after {
    content: "III";
    margin-top: -7px;
    margin-left: -18px;
    /*content: url("../img/nappi/menuicon2.png");*/
    letter-spacing: 0px;
  }
  summary:hover {
    transform: scale(1.1);
  }
  summary::marker {
    font-size: 0;
  }
}
