/* Uni-Form - http://dnevnikeklektika.com/uni-form/ */
eval(function(p,a,c,k,e,d){e=function(c){return(c<a?"":e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--){d[e(c)]=k[c]||e(c)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('4.E.h=3(1){1=4.r({s:\'B\',u:\'v\',5:\'w\',a:\'x\',g:\'y, z, A\'},1);f 8.i(3(){9 6=4(8);9 e=3(d){9 2=d.2();j(p(2)==\'o\'){b(2){b(2[0]&&(2[0].m.q(1.a)>=0)){2.t(1.5);f}}2=4(2.2())}};6.7(1.g).C(3(){6.7(\'.\'+1.5).c(1.5);e(4(8))}).l(3(){6.7(\'.\'+1.5).c(1.5)})})};$(D).k(3(){4(\'6.n\').h()});',41,41,'|settings|parent|function|jQuery|focused_class|form|find|this|var|holder_class|if|removeClass|element|focusControlHolder|return|field_selector|uniform|each|while|ready|blur|className|contactForm|object|typeof|indexOf|extend|valid_class|addClass|invalid_class|invalid|focused|boxField|input|select|textarea|valid|focus|document|fn'.split('|'),0,{}))

/* Simple jQuery Slideshow Script - http://jonraasch.com/blog/a-simple-jquery-slideshow */
function slideSwitch() {
    var $active = $('#slideshow IMG.active');
    if ( $active.length == 0 ) $active = $('#slideshow IMG:last');
    // use this to pull the images in the order they appear in the markup
    var $next =  $active.next().length ? $active.next()
        : $('#slideshow IMG:first');
    // uncomment the 3 lines below to pull the images in random order
    // var $sibs  = $active.siblings();
    // var rndNum = Math.floor(Math.random() * $sibs.length );
    // var $next  = $( $sibs[ rndNum ] );
    $active.addClass('last-active');
    $next.css({opacity: 0.0})
        .addClass('active')
        .animate({opacity: 1.0}, 1000, function() {
            $active.removeClass('active last-active');
        });
}


$(function(){
	
	/* Slideshow
	-------------------------------------------------------------- */
	setInterval( "slideSwitch()", 5000 );
	
	/* Colorbox
	-------------------------------------------------------------- */
	$("a[rel='shadowbox']").colorbox();

});
