j0hnik,
<div class="time"></div>
<script>
var x = 24*60*60*1000; // тоесть сутки
down = document.querySelector('.time'),
end = +new Date();
(function tick(){
var ost = end - new Date();
if(ost < 0) {end += x; ost = x};
var s = Math.floor(ost/1000),
m = Math.floor(s/60),
h = Math.floor(m/60),
d = Math.floor(h/24);
s = s%60+'';
m = m%60+'';
h = h%24+'';
d = d+'';
d = d.length == 1 ? '0'+d:d;
h = h.length == 1 ? '0'+h:h;
m = m.length == 1 ? '0'+m:m;
s = s.length == 1 ? '0'+s:s;
down.innerHTML = d+' дней '+h+' часов '+m+' минут '+s+' секунд';
requestAnimationFrame(tick)
})();
</script>