$("#stuff").hide();$(function(){var a;var e=$("#stuff").children().length;var h;if(Modernizr.canvas){var d=$("#logoBG")[0].getContext("2d")}var g=true;function c(){if(Modernizr.canvas){d.canvas.width=h+5;d.canvas.height=h+5;d.fillStyle="#111111";d.beginPath();d.arc(h/2,h/2,h/2,0,Math.PI*2,true);d.closePath();d.fill()}else{$("#logo").css({backgroundColor:"#111111",width:h,height:h}).append('<p style="color:#FE57A1;">schade kein canvs :-(</p>')}$("#logo img").css({top:((h/2)-($("#logo img").height()/2)),left:((h/2)-($("#logo img").width()/2))});$("#stuff,#impressumText,#showImage").css("margin-left",h+50);$("#impressum").width(h+40);$("#logo").css({top:(((a/2)-h/2)-8),left:"-300px"}).delay(500).animate({left:"10px"})}function f(){a=window.innerHeight;if(typeof a=="undefined"){a=$(window).height()}h=((a-51)/3);$("#stuff").height((a-29)).width(((Math.ceil(e/3))*(h+10))+20);$("#showImage").height((a-48));$("#stuff").children().height(h).width(h);if(g){$("#stuff").fadeIn()}c()}$(document).ready(function(){f()});var b;$(window).resize(function(){window.clearTimeout(b);b=window.setTimeout(f,500)});$('a[rel="image"]').click(function(i){i.preventDefault();g=false;$("#stuff").fadeOut();$("#closeImage").show();var j=$(this).attr("href");$("#showImage").show().html('<img src="'+j+'" alt="" />').fadeIn();location.hash="!"+$(this).attr("id")});$("#closeImage").click(function(){$("#showImage").fadeOut(function(){$("#stuff").fadeIn();g=true;location.hash=""});$(this).fadeOut()});$("#stuff").children().hover(function(){$(this).find("img").stop(true,true).delay(200).animate({height:"+=20",width:"+=20",marginTop:"-=10",marginLeft:"-=10"},200)},function(){$(this).find("img").stop(true,true).animate({height:"100%",width:"100%",marginTop:"0",marginLeft:"0"},500)});$("#impressumText").hide();$("#impressum").click(function(i){i.preventDefault();location.hash="!"+$(this).attr("id");g=false;$("#stuff,#showImage,#closeImage").fadeOut(function(){$("#closeImpressum").show();$("#impressumText").fadeIn()})});$("#closeImpressum").click(function(){$("#impressumText").fadeOut(function(){$("#stuff").fadeIn();g=true;location.hash=""});$(this).fadeOut()});if(location.hash.length>0){$("#"+location.hash.substring(2)).trigger("click")}});
