#dip-overlay{
  position:fixed;
  inset:0;
  background:rgba(0,0,0,.6);
  z-index:99998;
}
#dip-modal{
  position:fixed;
  top:50%;
  left:50%;
  transform:translate(-50%,-50%);
  z-index:99999;
  background:#fff;
  border:6px solid #000;
  max-width:min(92vw,720px);
  max-height:92vh;
  box-sizing:border-box;
  padding:10px;
}
#dip-modal .dip-image{
  display:block;
  max-width:100%;
  height:auto;
}
#dip-close{
  position:absolute;
  top:6px;
  right:10px;
  border:none;
  background:transparent;
  font-size:34px;
  line-height:1;
  cursor:pointer;
}
.dip-link{ display:block; text-decoration:none; }
.dip-hidden{ display:none !important; }


/* Mobile full-width popup */
@media (max-width: 768px) {

  #dip-modal {
    width: 95vw !important;
    max-width: 95vw !important;
    height: auto;
    left: 50%;
    top: 10vh;
    bottom: auto;
    transform: translateX(-50%);
  }

  #dip-modal img {
    width: 100%;
    height: auto;
    max-height: 90vh;
  }

}
