JSFiddle - React, Tailwind, and code Playground
HTML
<div id="cssninja">
<p><a href="http://www.thecssninja.com/xhtml/futurebox">Example from the [CSS] Ninja</a></p>
</div>
<ul>
<li><a href="#futurebox_img1"><img src="gr_ninja-attack_med.gif" width="100" height="102" alt="The CSS Ninja" id="futurebox01" /></a></li>
<li><a href="#futurebox_img2"><img src="gr_ninja-attack_med.gif" width="100" height="102" alt="The CSS Ninja" id="futurebox01" /></a></li>
<li><a href="#futurebox_img3"><img src="gr_ninja-attack_med.gif" width="100" height="102" alt="The CSS Ninja" id="futurebox01" /></a></li>
<li><a href="#futurebox_img4"><img src="gr_ninja-attack_med.gif" width="100" height="102" alt="The CSS Ninja" id="futurebox01" /></a></li>
<li><a href="#futurebox_img5"><img src="gr_ninja-attack_med.gif" width="100" height="102" alt="The CSS Ninja" id="futurebox01" /></a></li>
</ul>
<div class="overlay" id="futurebox_img1">
<a href="#close" title="Close future box"><img src="gr_cssninja_lrg.png" alt="The Css Ninja" width="469" height="500" /></a>
</div>
<div class="overlay" id="futurebox_img2">
<a href="#close" title="Close future box"><img src="gr_cssninja_lrg2.png" alt="The Css Ninja" width="469" height="500" /></a>
</div>
<div class="overlay" id="futurebox_img3">
<a href="#close" title="Close future box"><img src="gr_cssninja_lrg3.png" alt="The Css Ninja" width="469" height="500" /></a>
</div>
<div class="overlay" id="futurebox_img4">
<a href="#close" title="Close future box"><img src="gr_cssninja_lrg4.png" alt="The Css Ninja" width="469" height="500" /></a>
</div>
<div class="overlay" id="futurebox_img5">
<a href="#close" title="Close future box"><img src="gr_cssninja_lrg5.png" alt="The Css Ninja" width="469" height="500" /></a>
</div>
CSS
/* Just some base styles not needed for example to function */
*, html { font-family: Verdana, Arial, Helvetica, sans-serif; }
html, body { height: 100%; }
body, form, ul, li, p, h1, h2, h3, h4, h5
{
margin: 0;
padding: 0;
}
body { background-color: #606061; color: #ffffff; }
img { border: none; }
p
{
font-size: 1em;
margin: 0 0 1em 0;
}
/* Branding */
#cssninja
{
position: absolute;
top: 0;
left: 0;
background-color: #18191d;
width: 100%;
height: 40px;
}
#cssninja p
{
color: #ffffff;
text-align: center;
margin: 10px 0 0 0;
}
#cssninja a
{
color: #ffffff;
text-decoration: none;
background: url(../assets/ico_ninja.gif) 0 0 no-repeat;
padding: 4px 0 9px 28px;
}
#cssninja a:hover
{
text-decoration: underline;
}
/* Futurebox styles */
ul
{
padding: 60px 0 0 60px;
}
ul li
{
display: inline-block;
float: left;
list-style: none;
margin: 0 10px 0 0;
border: 3px solid #ccc;
-webkit-border-radius: 3px;
-moz-border-radius: 3px;
}
ul li a, ul li img { display: block; }
ul li:hover { border: 3px solid #1E528C; }
.overlay
{
width: 100%;
height: 100%;
position: absolute;
top: 0;
left: 0;
display: none;
z-index: 999;
background: rgba(0,0,0,0.7);
}
.overlay a
{
display: table-cell;
vertical-align: middle;
text-align: center;
}
.overlay img
{
padding: 10px;
-webkit-border-radius: 10px;
-moz-border-radius: 10px;
background: #ffffff;
}
.overlay:target { display: table; }