Try this :
$(document).ready(function(){
$(window).resize(function(){
$('#div') .css({'height': (($(window).height()))+'px'});
}).trigger('resize')
});
With that, you are binding an event when the screen resize. It will recalculate the window height.
the .trigger()
part is to ensure that it happen once when the DOM is ready (it trigger the event resize).