.imgprevs a{
  width:220px;
  max-height:150px;
}

#page .gallery{
  width:100%;
  clear:both;
  padding-bottom:20px;
  position:relative;
  text-align:center;
}

#page .gallery h3{
  clear:both;
  margin:40px 20px 15px 20px;
}

.imgprevs a{
  display:block;
  padding:0px;
  padding-bottom:0px;
  background-color:#fff;
  background-color:#ddd;
  border:1px solid #bbb;
  margin-bottom:14px;
  margin-right:13px;
  float:left;
  text-align:center;
  overflow:hidden;
}

.imgprevs a img{
  position:relative;
  margin-bottom:-10px;
}

.imgprevs{
  display:flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  clear:left;
  padding-top:0px;
  padding-left:0px;
  margin-right:-20px;
}

.img .imgprevs{
  padding-top:0px;
  margin-bottom:-6px;
  overflow:hidden;
}

.gdir{
text-align:center;
float:left;
width:104px;
height:140px;
padding-bottom:6px;
}

.gdirs{
clear:both;
width:1000px;
}

.gdir .foldername{
  font-size:.7em;
  color:#55a;
}


@media screen and (max-width: 1200px) {
  .imgprevs{
    margin-right:-16px;
    margin-left:-16px;
  }
}


@media screen and (max-width: 780px) {
  .imgprevs a{
    flex-grow: 1;
    width:46%;
    margin:0px !important;
    border:1px solid #fff !important;
    max-height:250px;
  }
  .imgprevs a img{
    width:100%;
  }
}

/* velikost screen podle thumb width */
@media screen and (max-width: 358px) {
  .imgprevs a{
    width:92%;
  }
}
