In The Press

var docHeight = Math.max( document.body.scrollHeight, document.documentElement.scrollHeight ); if ( scrollPos >= docHeight - threshold ) { icon.style.marginBottom = '80px'; ada.style.marginBottom = '80px'; } else { icon.style.marginBottom = '0'; ada.style.marginBottom = '0'; } } window.addEventListener('scroll', toggleMargin); window.addEventListener('resize', toggleMargin); toggleMargin(); // apel inițial });