

	$('.style > a').click(function(e) {
	  $('.colours > p').css('display', 'none');
	  
	  $('#'+this.id.split('-')[0]+'-colours').css('display', 'block');
	  
    var colourlink = $('a', $('#'+this.id.split('-')[0]+'-colours')).first()
    colourlink.trigger('click');
	  e.preventDefault();    
	});
	
	$('.colour-link').click(function(e) {
	  $('.product-gallery').css('display', 'none');
	  
	  var gallery = $('#'+this.id.split('-')[0]+'-gallery');
	  gallery.css('display', 'block');
	  gallery.children().first().click();
	  
	  
	  e.preventDefault();
	});
	
	$('.thumb-link').click(function(e) {
	  $('#product-poster > img').attr('src',this.href);
	  e.preventDefault();
	});
	
	if (!$('.ie7').length) {
	
	$('#menu-item-24').mouseover(function(e) {
		$('#dropdown').slideDown();
		
		var entered = false;
				
		$('#dropdown').mouseenter(function(e) {
			entered = true;
		});
		
		$('#menu-item-24').mouseleave(function(e) {
			setTimeout(function() {
				if (!entered) {
					$('#dropdown').slideUp();
				}
			}, 750);
		});
		
		$('#dropdown').mouseleave(function(e) {
			$('#dropdown').slideUp();
		});
		
	});
	
	
	$('#menu-item-36').mouseover(function(e) {
		$('#support-dropdown').slideDown();
		
		var entered = false;
				
		$('#support-dropdown').mouseenter(function(e) {
			entered = true;
		});
		
		$('#menu-item-36').mouseleave(function(e) {
			setTimeout(function() {
				if (!entered) {
					$('#support-dropdown').slideUp();
				}
			}, 750);
		});
		
		$('#support-dropdown').mouseleave(function(e) {
			$('#support-dropdown').slideUp();
		});
		
	});
	
	}
	
	
	//Preload product thumbs
	$('.product-link').each(function() {
		var img = $('<img />');
		img.attr('src', this.title);
	});
	
	$('.product-link').mouseenter(function() {
		$('#rollover-thumb').attr('src', this.title);
		$('#selected-product > .prod-title').html(this.innerHTML);
	});
	$('.range h4').mouseenter(function() {
	  var item = $('.product-link',$(this).siblings('.products')).first()
	  item.mouseenter();
	});
	
	if ($('.fadebanner').length) {
	  $('.fadebanner').fadeSlideShow({
	  		PlayPauseElement: false,
	  		NextElement: false,
	  		PrevElement: false,
	  		ListElement: false,
	  		allowKeyboardCtrl: false,
	  		width: 600,
	  		height: 215,
	  		interval: 3500
	  	});
	}
	
	if ($('#home-video').length) {
		$(document).ready(function() {
			$.get(window.location+'index.php?page_id=637', function(response) {
				$('#home-video').html(response)
			})
		});
	}

