jq(document).ready(function(){

      // jq('.section-portfolio-es p.documentDescription span').sifr({path: portal_url , font: 'quicksand book'});
      //       jq('.section-portfolio-en p.documentDescription span').sifr({path: portal_url , font: 'quicksand book'});
      //       jq('.section-portfolio p.documentDescription span').sifr({path: portal_url , font: 'quicksand book'});
      //       jq('.content-pillole p.documentDescription span').sifr({path: portal_url , font: 'quicksand book'});
      // jq('h1.documentFirstHeading').sifr({path: portal_url , font: 'quicksand book'});
      
      //jq('h1.documentFirstHeading span').sifr({path: portal_url , font: 'quicksand book'});
      
    /***************** pagina noi **********************/
      jq(".noi div.scrollable").scrollable({ 
         vertical:true,  
         size: 3
         // use mousewheel plugin 
      }).mousewheel();
    /***************************************************/
    jq('.content-portfolio-es #panes a', '.content-portfolio-en #panes a', '.content-portfolio #panes a').hover(function(){
        jq(this).fadeTo("fast", 0.8);
    });
    /******************** rounded border ****************/
    //jq('div.others-home-news').corners("10px #ffffff");
    //jq('div.box-navigation').corners("10px #ffffff");
    
    DD_roundies.addRule('div.others-home-news', '10px', true);
    DD_roundies.addRule('div.box-navigation', '10px 10px 0 0', true);
    
    // jq('ul#portal-globalnav li.selected a').corners("10px #ddd");
    // jq("ul#portal-globalnav li a").hover(function(){
    //     jq(this).corners("10px #ddd");
    // });
    /****************************************************/
    // jq("#portal-searchbox").click(function(){
    //    jq(this).addClass('view-search');
    //    jq('.LSBox', this).fadeIn();
    // });
    // var open = '146';
    // var close = '120';
    //     var state = '110';
    //     if (jq.browser.msie) {
    //         open = '160';
    //         close = '130';
    //     }
    //     jq('.portletCollectionAbstract .padding').addClass('close');
    // jq('.portletCollectionAbstract .collection-text').hide();
    //     jq('.portletCollectionAbstract .head').click(function() {
    //         if (jq(this.parentNode.parentNode.parentNode).height() == open){
    //             
    //             return false;
    //             // jq('.portletCollectionAbstract .collection-text').hide();
    //             //             
    //             //             jq('.portletCollectionAbstract .open').addClass('close');
    //             //             jq('.portletCollectionAbstract .open').removeClass('open');
    //             //             
    //             //             jq('.portletCollectionAbstract .portletItem').each(function(){
    //             //                 jq(this).animate({'height': state+'px'});
    //             //             });
    //         }else{
    //             jq('.portletCollectionAbstract .open').addClass('close');
    //             jq('.portletCollectionAbstract .open').removeClass('open');
    //             jq('.collection-text', this.parentNode.parentNode).toggle();
    //             jq(this.parentNode.parentNode).removeClass('close');
    //             jq(this.parentNode.parentNode).addClass('open');
    //             jq(this.parentNode.parentNode.parentNode).animate({'height': open+'px'});
    //             jq('.collection-text', this.parentNode.parentNode).addClass('view');
    //             jq('.portletCollectionAbstract .collection-text').not(".view").hide().each(function(){
    //                 jq(this.parentNode.parentNode).css('overflow','hidden');
    //                 jq(this.parentNode.parentNode).animate({'height': close+'px'});
    //             });
    //             jq('.collection-text', this.parentNode.parentNode).removeClass('view');
    //             return false;
    //         }
    //     });
});