JSFiddle - React, Tailwind, and code Playground
HTML
<div class="box">
<div id="number"></div>
<div class="buttons">
<button type="button" id="start" onclick="start(this);">Старт</button>
<button type="button" id="random" class="hide" onclick="rand();">Ещё</button>
<button type="button" id="share" class="hide">Поделиться</button>
</div>
</div>
CSS
.box {
height: 500px;
position: relative;
background-image: url(http://eandys.ru/image.php?di=PZUV);
}
.buttons {
position: absolute;
left: 0;
bottom: 0;
width: 100%;
}
.buttons > button {
width: 156px;
height: 39px;
display: block;
margin: 3px auto;
}
#number {
text-align: center;
color: #000;
text-shadow: 0 0 3px #fff;
font-size: 70px;
padding: 180px;
}
.hide {
display: none !important;
}
JavaScript
function rand(){
document.getElementById('number').innerHTML = Math.ceil(Math.random()*1000);
}
function start(el){
var nodeList = document.querySelectorAll('.hide')
for (var i = 0; i < nodeList.length; ++i) {
nodeList[i].className = '';
}
el.className = 'hide';
rand();
}