/* = @media queries  info 
===========================*/

/*    Basic
================*/
html,body {
  margin: 0;
  padding: 0;
  position: relative;
  height: 100%;
}

*,*:after,*:before {
  box-sizing: border-box;
}
/*  PLACEHOLDER
----------------------*/
::-webkit-input-placeholder {
  color: #FFF;
}

:-moz-placeholder {
  color: #FFF;
}

::-moz-placeholder {
  color: #FFF;
}

:-ms-input-placeholder {
  color: #FFF;
}
/*  SCROLLBAR
-------------------*/
::-webkit-scrollbar-thumb {
  background: #fff;
}

::-webkit-scrollbar-thumb:window-inactive {
  background: #fff;
}
/*  SELECTION
-------------------*/
::selection {
  background: #999;
  color: #fff;
}

::-moz-selection {
  background: #999;
  color: #fff;
}
/* === Links Styles === */
a {
  text-decoration: underline;
  -webkit-transition: 0.25s;
  -moz-transition: 0.25s;
  -o-transition: 0.25s;
  transition: 0.25s;
  -webkit-backface-visibility: hidden;
  -moz-backface-visibility: hidden;
  -ms-backface-visibility: hidden;
  -o-backface-visibility: hidden;
  backface-visibility: hidden;
}

a:hover {
  text-decoration: none;
}

a:focus {
  outline: 0;
  outline: 0 auto -webkit-focus-ring-color;
  outline-offset: 0;
}
/*	Layout
=======================*/
body {
  background: #EEE;
  overflow-X: hidden;
  font-size: 13px;
  font-family: 'Metrophobic', sans-serif;
  font-weight: 400;
}

.wrapper {
  margin: 2rem 0 0 0;
}

.wrapper:before {
  content: "";
  display: table;
}

.wrapper_inner {
  padding: 0.2em;
  margin: 0;
}

.gallery {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
}

.gallery_item {
  width: 23%;
  margin-right: 2%;
  margin-bottom: 2%;
  padding: 0.5em;
  background: #FFF;
  border: 1px solid #F3F0F0;
  position:relative;
  -webkit-box-shadow: 0 1px 2px #AFAFAF;
  -moz-box-shadow: 0 1px 2px #AFAFAF;
  box-shadow: 0 1px 2px #AFAFAF;
  -webkit-border-radius: 5px;
  -moz-border-radius: 5px;
  border-radius: 5px;
}


.gallery_item_preview {
  background: #fff;

  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}

.gallery_item_preview a {
  position: relative;
  display: inline-block;
  padding: 0;
  color: #333;
  text-decoration: none;
  overflow: hidden;

  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}

.gallery_item_preview a:hover {
  color: #777;

  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}
.gallery_item_preview a svg.gallery_top{
  position:absolute;
  top:0;
  left:0;
  width:100%;
  height:50px;
  stroke:none;
  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}
.gallery_item_preview a:hover  svg.gallery_top{
  top:-10em;
  
  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}
.gallery_hide_top{
  top:-10em !important;
  
  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}

.gallery_item_preview a:before {
  content: "點擊查看";
  position: absolute;
  top: 0.5em;
  left: -30em;
  background-color: #FFF;
  background-color: rgba(255, 255, 255, 0.99);
  color: #5BC0C7;
  padding: 0.56em 1em;

  -webkit-border-radius: 5px 0 0 0;
  -moz-border-radius: 5px 0 0 0;
  border-radius: 5px;

  -webkit-transition: all 1s ease;
  -moz-transition: all 1s ease;
  -o-transition: all 1s ease;
  transition: all 1s ease;
}

.gallery_item_preview a:hover:before {
  left: 0.5em;

  -webkit-transition: all 1s ease;
  -moz-transition: all 1s ease;
  -o-transition: all 1s ease;
  transition: all 1s ease;
}

.gallery_item_preview a h3 {
    margin: 1rem 0 0 0;
    font-size: 2rem;
}

.gallery_item_preview a img {
  display: block;
  width: 100%;
  height: 150px;

  -webkit-border-radius: 5px;
  -moz-border-radius: 5px;
  border-radius: 5px;

  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}

.gallery_item_full {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  margin: auto;
  background-color: #fff;
  background-color: rgba(0, 0, 0, 0.6);
  z-index: 100;
  overflow: hidden;
}

.gallery_item_full img {
  display: block;
  width: 100%;
}

.box {
  margin: auto;
  background: #FFF;
  padding: 2em;
  display: block;
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  overflow: auto;
  width: 50%;
  text-align: left;
  border: 1px solid #DADADA;
}

.box h3 {
  color: #5BC0C7;
}

.cl {
  position: absolute;
  top: 0.5em;
  right: 0.5em;
  color: #fff;
  text-decoration: none;
  display: inline-block;
  font-size: 2em;
}

.cl:hover {
  color: #5BC0C7;
}
/*  Responsive video 
=============================*/
.video {
  position: relative;
  padding-bottom: 56.25%;
  padding-top: 30px;
  height: 0;
  overflow: hidden;
}

.video iframe,
.video object,
.video embed {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}
/*  list style
=============================*/
.icon_list {
  width: 30px;
  height: 30px;
  display: block;
  padding: 0.5em;
  text-decoration: none;
  line-height: 0.4em;
  background: #FFF;
  color: #838383;
  border: 1px solid #C2C2C2;

  -webkit-border-radius: 4px;
  -moz-border-radius: 4px;
  border-radius: 4px;
  
  position: absolute;
  right: 0.3em;
  top: 0.3em;
  word-break: break-all;

  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}

.icon_list:hover {
  background: #2c7a80;
  color: #fff;
  border-color: #f11;

  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}

.icon_list_open {
  background: #2c7a80 !important;
  color: #fff !important;
}

.gallery_item_list {
  float: none !important;
  display: block !important;
  width: 50%;
  margin: auto;
  margin-top: 0.5em;

  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}

.gallery_line {
  width: 130px !important;
  height: 100px !important;
  display: inline-block !important;
  float: left !important;
  margin-right: 1em !important;

  -webkit-transition: all 0.5s ease;
  -moz-transition: all 0.5s ease;
  -o-transition: all 0.5s ease;
  transition: all 0.5s ease;
}
/*	Simple animation
=======================*/
.efIn {
  -webkit-animation: fx_in 0.65s 1 ease-in-out;
  -moz-animation: fx_in 0.65s 1 ease-in-out;
  -ms-animation: fx_in 0.65s 1 ease-in-out;
  -o-animation: fx_in 0.65s 1 ease-in-out;
  animation: fx_in 0.65s 1 ease-in-out;
}

.efOut {
  -webkit-animation: fx_out 0.7s 1 ease-in-out;
  -moz-animation: fx_out 0.7s 1 ease-in-out;
  -ms-animation: fx_out 0.7s 1 ease-in-out;
  -o-animation: fx_out 0.7s 1 ease-in-out;
  animation: fx_out 0.7s 1 ease-in-out;
}




/*	Keyframes
==============*/
@-webkit-keyframes fx_in {
  from {
    width: 0;
    height: 0;
    -webkit-border-radius: 100%;
    opacity: 0;
  }

  50% {
    -webkit-box-shadow: inset 0 0 0 0  #fff;
  }

  to {
    width: 100%;
    height: 100%;
    -webkit-border-radius: 0;
    opacity: 1;
  }
}

@-webkit-keyframes fx_out {
  from {
    width: 100%;
    height: 100%;
    -webkit-border-radius: 0;
    -webkit-box-shadow: inset 0 0 0 0 #fff;
    opacity: 1;
  }

  50% {
    -webkit-box-shadow: inset 0 0 0 80em  #fff;
  }

  to {
    width: 0;
    height: 0;
    -webkit-border-radius: 100%;
    opacity: 0;
  }
}

/* moz */
@-moz-keyframes fx_in {
  from {
    width: 0;
    height: 0;
    -moz-border-radius: 100%;
    opacity: 0;
  }

  50% {
    -moz-box-shadow: inset 0 0 0 0  #fff;
  }

  to {
    width: 100%;
    height: 100%;
    -moz-border-radius: 0;
    opacity: 1;
  }
}

@-moz-keyframes fx_out {
  from {
    width: 100%;
    height: 100%;
    -moz-border-radius: 0;
    -moz-box-shadow: inset 0 0 0 0 #fff;
    opacity: 1;
  }

  50% {
    -moz-box-shadow: inset 0 0 0 80em  #fff;
  }

  to {
    width: 0;
    height: 0;
    -moz-border-radius: 100%;
    opacity: 0;
  }
}

/* o */
@-o-keyframes fx_in {
  from {
    width: 0;
    height: 0;
    -o-border-radius: 100%;
    opacity: 0;
  }

  50% {
    -o-box-shadow: inset 0 0 0 0  #fff;
  }

  to {
    width: 100%;
    height: 100%;
    -o-border-radius: 0;
    opacity: 1;
  }
}

@-o-keyframes fx_out {
  from {
    width: 100%;
    height: 100%;
    -o-border-radius: 0;
    -o-box-shadow: inset 0 0 0 0 #fff;
    opacity: 1;
  }

  50% {
    -o-box-shadow: inset 0 0 0 80em  #fff;
  }

  to {
    width: 0;
    height: 0;
    -o-border-radius: 100%;
    opacity: 0;
  }
}

/* ms */
@-ms-keyframes fx_in {
  from {
    width: 0;
    height: 0;
    -ms-border-radius: 100%;
    opacity: 0;
  }

  50% {
    -ms-box-shadow: inset 0 0 0 0  #fff;
  }

  to {
    width: 100%;
    height: 100%;
    -ms-border-radius: 0;
    opacity: 1;
  }
}

@-ms-keyframes fx_out {
  from {
    width: 100%;
    height: 100%;
    -ms-border-radius: 0;
    -ms-box-shadow: inset 0 0 0 0 #fff;
    opacity: 1;
  }

  50% {
    -ms-box-shadow: inset 0 0 0 80em  #fff;
  }

  to {
    width: 0;
    height: 0;
    -ms-border-radius: 100%;
    opacity: 0;
  }
}

@keyframes fx_in {
  from {
    width: 0;
    height: 0;
    border-radius: 100%;
    opacity: 0;
  }

  50% {
    box-shadow: inset 0 0 0 0  #fff;
  }

  to {
    width: 100%;
    height: 100%;
    border-radius: 0;
    opacity: 1;
  }
}

@keyframes fx_out {
  from {
    width: 100%;
    height: 100%;
    border-radius: 0;
    box-shadow: inset 0 0 0 0 #fff;
    opacity: 1;
  }

  50% {
    box-shadow: inset 0 0 0 80em  #fff;
  }

  to {
    width: 0;
    height: 0;
    border-radius: 100%;
    opacity: 0;
  }
}
/* Large desktop */
@media (min-width: 980px) {
  .gallery_item_list {
    width: 50% !important;
  }
  .gallery_item {
    width: 23%;
  }
  .gallery_item_preview a img {
    height: 130px;
  }
  .box {
    width: 60%;
    max-height: 750px;
  }
}


/* Portrait tablet to landscape and desktop */

@media (max-width: 991px) {
  .gallery_item {
    width: 48%;
}

  .gallery_item_preview a img {
    height: auto;
}

  .box {
    width: 70%;
    max-height: 550px;
}
}
@media (max-width: 768px) {
  .box {
    padding: 1rem;
}
}
@media (max-width: 576px) {
  .gallery_item {
    width: 100%;
  }
}