JSFiddle - React, Tailwind, and code Playground
by luka kupunia
HTML
<button class="circle-button circle-button--golden d-block position-relative border-0"><span class="circle-button__content position-absolute ">
<div class="text-white text-center font-semibold"><span class="d-block text-h4">Geo</span></div>
</span></button>
CSS
button {
position: fixed;
z-index: 99999999999999999;
}
#k-burger {
width: 100vw;
background: #030710;
height: 100vh;
overflow: auto;
position: fixed;
top: 0;
left: 0;
z-index: 9999;
display: flex;
justify-content: center;
}
#k-burger .nav {
margin-top: 64px;
}
#k-burger .nav .menu-item {
margin-bottom: 40px;
overflow: hidden;
}
#k-burger .nav .menu-item a {
font-size: 16px;
color: grey;
transition: .6s;
text-align: center;
display: block;
text-decoration: none;
transform: translate3d(0, 110%, 0);
}
#k-burger .nav .menu-item a.active {
color: white;
}
#k-burger.active .nav .menu-item a {
transform: translate3d(0, 0, 0);
}
#k-burger .stick {
width: 200px;
height: 2px;
background: white;
transition: 0.6s;
transform: scaleX(0)
}
#k-burger.active .stick {
transform: scaleX(1);
}
#k-burger .lang-bar {
display: flex;
justify-content: center;
}
#k-burger .lang-bar .k-circle {
width: 62px;
height: 62px;
background: red;
margin-top: 42px;
transition: 0.6s;
transform: scale(0);
border-radius: 50%;
}
#k-burger.active .lang-bar .k-circle {
transform: scale(1);
}
JavaScript
$('#test').click(function() {
$('#k-burger').toggleClass('active')
})