JSFiddle - React, Tailwind, and code Playground
HTML
<a href="#" class="open">Жми</a>
<div class="popup">
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit. Tempora provident sed ut ipsa voluptatum quisquam fugit iste incidunt numquam maxime impedit adipisci neque officiis nemo obcaecati quidem facere ullam! Dolore.</p>
</div>
<script src="http://dinbror.dk/bpopup/assets/jquery.bpopup-0.11.0.min.js"></script>
CSS
* {
margin: 0;
padding: 0;
}
html, body {
height: 100%;
}
body {
display: flex;
justify-content: center;
align-items: center;
background: url(http://goo.gl/50Xu6u) no-repeat;
background-size: cover;
font: 1em/1.2 Tahoma, sans-serif;
}
.open {
position: relative;
top: 0;
margin: 100px;
padding: 5px 25px;
background: rgba(219,87,5,1);
display: inline-block;
border-radius: 8px;
color: #fff;
font-weight: bold;
text-decoration: none;
box-shadow: 0px 6px 0px rgba(219, 31, 5, 1);
transition: all 0.1s linear
}
.open:active {
box-shadow: none;
top: 6px;
}
.popup {
display: none;
width: 50%;
background: rgba(255, 255, 255, 0.5);
padding: 10px;
border-radius: 10px;
}
.new-bg {
background: url(http://goo.gl/0virQo);
background-size: cover;
}
JavaScript
$('.open').click(function() {
$('.popup').bPopup({
onOpen: function() {
$('body').addClass('new-bg');
},
onClose: function() {
$('body').removeClass('new-bg');
}
});
});