//menu
jQ(document).ready(function() {
	var easing_type = 'easeOutBounce';
	var default_dock_height = '40';
	var expanded_dock_height = jQ('#dock').height();
	var body_height = jQ(window).height() - default_dock_height;
	jQ('#dromeas').height(body_height);
	jQ('#dock').css({'height': default_dock_height, 'position':'absolute', 'top': body_height});
	jQ(window).resize(function () {
		updated_height = jQ(window).height() - default_dock_height;
		jQ('#dromeas').height(updated_height);		
		jQ('#dock').css({'top': updated_height});
	});
});
//stack slider
jQ(function(){
	counter = 0;
	countBreak = 0;
	if(jQ(".stacks_out").length){jQ("#page_holder #content:first").css({width:"auto", height:"auto"});}
	jQ(".stacks_out").addClass("page");
	jQ(".stacks_out .stacks_out").removeClass("page");
	jQ(".page").css({});
	jQ("#content").css({padding:0});
	jQ(".page").each(function(){
		jQ(".stacks_in:first", this).css({margin:2, padding:1});
		counter = counter+1;
		countBreak = countBreak+1;
		var style = '';
		if(countBreak == 4) {countBreak = 0; var style = 'margin-right:0;';}
		jQ(this).attr('id', 'pageID'+counter);
	});
	jQ("#footer").css({marginLeft:0});
	var jQpaneTarget = jQ('#holder');	
	jQ("a.navi").each( function() {
		jQ(this).click(function(){
			var thePosition = jQ(this).attr("rel");
			var jQtarget = jQpaneTarget.find('#'+thePosition);
			jQpaneTarget.stop().scrollTo(jQtarget, 600, {offset:-50});
		});	
	});	
});
jQ(function( jQ ){
	jQ.scrollTo.defaults.axis = 'xy'; 			
	jQ('div.pane').scrollTo(0);
	jQ.scrollTo(0);
});
