JSFiddle - React, Tailwind, and code Playground
by John Doe
HTML
<div id="wrapper">
<div class="entry">
Hello there. General Kenobi?
</div>
</div>
CSS
#wrapper {
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: linear-gradient(135deg, #192e4c, #11403e);
}
#wrapper::before {
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
content: '';
background: linear-gradient(to right, #392232, #0f1922);
mask: linear-gradient(#000, transparent);
-webkit-mask: linear-gradient(#000, transparent);
}
.entry {
cursor: pointer;
position: absolute;
color: white;
border-radius: 4px;
padding: 1rem;
margin: 1rem;
border: 1px solid rgba(255, 255, 255, 0.01);
background-color: rgba(255, 255, 255, 0.05);
box-shadow: 0px 0px 10px 5px #00000020;
transition: all .5s;
z-index: 1;
}
.entry:hover {
transform: scale(1.1);
}
.entry::before {
content: '';
border-radius: 6px;
top: 0;
left: 0;
position: absolute;
width: 100%;
height: 100%;
background-color: rgba(0, 0, 0, 0.1);
}