 // these are (ruh-roh) globals. You could wrap in an
                // immediately-Invoked Function Expression (IIFE) if you wanted to...
                var currentTallest = 0,
                    currentRowStart = 0,
                    rowDivs = new Array();
                
                function setConformingHeight(el, newHeight) {
                        // set the height to something new, but remember the original height in case things change
                        el.data("originalHeight", (el.data("originalHeight") == undefined) ? (el.height()) : (el.data("originalHeight")));
                        el.height(newHeight);
                }
                
                function getOriginalHeight(el) {
                        // if the height has changed, send the originalHeight
                        return (el.data("originalHeight") == undefined) ? (el.height()) : (el.data("originalHeight"));
                }
                
                function columnConform() {
                
                        // find the tallest DIV in the row, and set the heights of all of the DIVs to match it.
                        $('#content > div').each(function() {
                        
                                // "caching"
                                var $el = $(this);
                                
                                var topPosition = $el.position().top;
                
                                if (currentRowStart != topPosition) {
                
                                        // we just came to a new row.  Set all the heights on the completed row
                                        for(currentDiv = 0 ; currentDiv < rowDivs.length ; currentDiv++) setConformingHeight(rowDivs[currentDiv], currentTallest);
                
                                        // set the variables for the new row
                                        rowDivs.length = 0; // empty the array
                                        currentRowStart = topPosition;
                                        currentTallest = getOriginalHeight($el);
                                        rowDivs.push($el);
                
                                } else {
                
                                        // another div on the current row.  Add it to the list and check if it's taller
                                        rowDivs.push($el);
                                        currentTallest = (currentTallest < getOriginalHeight($el)) ? (getOriginalHeight($el)) : (currentTallest);
                
                                }
                                // do the last row
                                for (currentDiv = 0 ; currentDiv < rowDivs.length ; currentDiv++) setConformingHeight(rowDivs[currentDiv], currentTallest);
                
                        });
                
                }
                
                
                $(window).resize(function() {
                        columnConform();
                });
                
                // Dom Ready
                // You might also want to wait until window.onload if images are the things that
                // are unequalizing the blocks
                $(function() {
                        columnConform();
                });
				
				
				
				
				
				


$(function() {
    $(".products-slider-home").jCarouselLite({
		vertical: true,
        hoverPause: true,
        btnPrev: ".products-slider-btn-top-home",
        btnNext: ".products-slider-btn-bottom-home",
        visible: 2,
        speed: 300,
		auto: false
    });
});


$(function() {
    $(".brands-slider").jCarouselLite({
		vertical: false,
        hoverPause: true,
        btnPrev: ".brands-slider-btn-left",
        btnNext: ".brands-slider-btn-right",
        visible: 4,
        speed: 2000,
		auto: 1000
    });
});


//$(function(){
//  $('#banner-slider').bxSlider({
//  	mode: 'horizontal',
//	pause: 5000,
//    auto: true,
//    controls: true,
//	autoControls: true,
//	speed: 300,
//	pager: true,
//	easing: 'easeOutBack',
//	autoDelay: 2000
//  });
//});

$(function() {
	$('.gallery-box ul li a').lightBox();
});

$(document).ready(function(){
	$('.mod-gallery-box ul li.caption').hover(function(){
		$(".cover", this).stop().animate({top:'90px'},{queue:false,duration:160});
		}, function() {
		$(".cover", this).stop().animate({top:'122px'},{queue:false,duration:160});
	});
});
