window.addEvent('domready', function(){
    $$('A.ll').each(function(el){
        el.addEvent('mouseenter', function(e){
            e = new Event(e);
            new Fx.Style(this, 'padding-left', {duration: 100, transition: Fx.Transitions.linear}).start(0, 6);
            new Fx.Style(this, 'color', {duration: 100, transition: Fx.Transitions.linear}).start("#A32202", "#F85216");
            e.stop();
        });
        el.addEvent('mouseleave', function(e){
            e = new Event(e);
            new Fx.Style(this, 'padding-left', {duration: 200, transition: Fx.Transitions.linear}).start(6, 0);
            new Fx.Style(this, 'color', {duration: 200, transition: Fx.Transitions.linear}).start("#F85216", "#A32202");
            e.stop();
        });

    });
    
    $$('UL.cases A').each(function(el){
        el.addEvent('mouseenter', function(e){
            e = new Event(e);
            new Fx.Style(this, 'padding-left', {duration: 100, transition: Fx.Transitions.linear}).start(0, 6);
            new Fx.Style(this, 'color', {duration: 100, transition: Fx.Transitions.linear}).start("#A32202", "#F85216");
            e.stop();
        });
        el.addEvent('mouseleave', function(e){
            e = new Event(e);
            new Fx.Style(this, 'padding-left', {duration: 200, transition: Fx.Transitions.linear}).start(6, 0);
            new Fx.Style(this, 'color', {duration: 200, transition: Fx.Transitions.linear}).start("#F85216", "#A32202");
            e.stop();
        });

    });

    $$('.more-link').each(function(el){
        el.addEvent('mouseenter', function(e){
            e = new Event(e);
            new Fx.Style(this, 'opacity', {duration: 400, transition: Fx.Transitions.linear}).start(0.3, 1);
            e.stop();
        });
        el.addEvent('click', function(e){
            e = new Event(e);
            var thisel = this;
            $$('.more-link').each(function(el){
                if(thisel != el){
                    new Fx.Style(el, 'opacity', {duration: 400, transition: Fx.Transitions.linear}).start(1, 0.3);
                }
            });
            e.stop();
            if (thisel.href != '#' || thisel.href != '') window.location = thisel.href;
        });
    });

    $$('.sandbox-images A').each(function(el){
        el.addEvent('mouseenter', function(e){
            e = new Event(e);
            new Fx.Style(this, 'opacity', {duration: 400, transition: Fx.Transitions.linear}).start(0.3, 1);
            e.stop();
        });
        el.addEvent('click', function(e){
            e = new Event(e);
            var thisel = this;
            $$('.sandbox-images A').each(function(el){
                if(thisel != el){
                    new Fx.Style(el, 'opacity', {duration: 400, transition: Fx.Transitions.linear}).start(1, 0.3);
                }
            });
            e.stop();
        });
    });

    $$('.line-links-method A').each(function(el){
        el.addEvent('mouseenter', function(e){
            e = new Event(e);
            new Fx.Style(this, 'opacity', {duration: 400, transition: Fx.Transitions.linear}).start(0.3, 1);
            e.stop();
        });
        el.addEvent('click', function(e){
            e = new Event(e);
            var thisel = this;
            $$('.line-links-method A').each(function(el){
                if(thisel != el){
                    new Fx.Style(el, 'opacity', {duration: 400, transition: Fx.Transitions.linear}).start(1, 0.3);
                }
            });
            e.stop();
			if (thisel.href != '#' || thisel.href != '') window.location = thisel.href;            
        });
    });

    $$("UL#main-menu A").each(function(el){
        el.addEvent('mouseenter', function(e){
            e = new Event(e);
            var effects = new Fx.Styles(this, {duration: 500, transition: Fx.Transitions.linear});

            effects.start({
                'border-color': ["#FFFFFF", "#9E0B0F"],
                'color': ["#9E0B0F", "#000000"]
            });

            e.stop();
        });
        el.addEvent('mouseleave', function(e){
            e = new Event(e);
            var effects = new Fx.Styles(this, {duration: 500, transition: Fx.Transitions.linear});
            effects.start({
                'border-color': ["#9E0B0F", "#FFFFFF"],
                'color': ["#000000", "#363636"]
            });
            e.stop();
        });
    });
});