
/* The Modal (background) */
.modal {
  display: table;
  position: fixed;
  border: 0;
  cellspacing: 0;
  cellpadding: 0;
  z-index: 99999999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100vh;
  padding: 0;
  margin: 0;
  opacity: 0;
  overflow: hidden;
  background-color: rgb(0,0,0);
  background-color: rgba(0,0,0,0.9);
}

/* Modal Content */
#modal-content {
  display: none;
  border: 0;
  vertical-align: middle;
  text-align: center;
  margin: 0 auto;
  padding: 80px 0;
  width: 100%;
  height: 95%;
/*
  background-color: blue;
*/
}

#modal-image {
  display: block;
/*
  border: solid 1px blue;
*/
  margin:0  auto;
  padding: 0;
  width: 100%;
  max-width: 800px;
  height: 95%;
/*
  background-color: blue;
*/
}

#caption {
  position: absolute;
  width: 85%;
  top: 30px;
  left: 7.5%;
  margin: 0 auto;
  padding: 10px 0;
  text-align: center;
  font-size: 16px;
  color: white;
  opacity: 0;
}

.zoomIn { 
  animation-name: zoomIn;
  animation-duration: 0.6s;
}
@keyframes zoomIn {
  from {transform:scale(0)} 
  to {transform:scale(1)}
}
.zoomOut { 
  animation-name: zoomOut;
  animation-duration: 0.6s;
}
@keyframes zoomOut {
  from {transform:scale(1)} 
  to {transform:scale(0); opacity:0;}
}

.close {
  position: absolute;
  top: 15px;
  right: 35px;
  color: #f1f1f1;
  font-size: 40px;
  font-weight: bold;
  transition: 0.3s;
}

.close:hover,
.close:focus {
  color: #bbb;
  text-decoration: none;
  cursor: pointer;
}

/***************************************************
タブレット用 768px～973px
***************************************************/

@media only screen and (max-width: 973px){
  width: 100%;
}

/***************************************************
スマートフォン用 ～767px
***************************************************/
@media only screen and (max-width: 767px){
#modal-image {
  width: 100%;
}
.close {
  right: 25px;
}
}
