  $(document).ready(function(){
    var $panel = $("div#one");
	var $fly = $("div#oneContents");

//CLICKING ON THE BUTTON WILL OPEN FLYOUT
$("img#left").click(function (e) {
	
	if (!$panel.hasClass("animating") && !$panel.hasClass("open")) {
		$panel.addClass("animating");
		$("img#left").addClass("stealth");
		
      	$panel.show("slide", { direction: "right" }, 500, function() {
			$panel.removeClass("animating").addClass("open");
		});
	}
	e.stopPropagation();
});

//CLICKING ON FLYOUT WILL NOT CLOSE FLYOUT
$("#oneContents").click(function (e) {
    e.stopPropagation();
});

//CLICKING ON QUESTIONS WILL NOT CLOSE FLYOUT
$("div#faqList h3").click(function (e) {
    e.stopPropagation();
});

//CLICKING ON EXPAND ALL WILL NOT CLOSE FLYOUT
$(".trigger").click(function (e) {
    e.stopPropagation();
});

//CLICKING ON DROPDOWN WILL NOT CLOSE FLYOUT
$("#faqSelect").click(function (e) {
    e.stopPropagation();
});

//CLICKING ON BUTTON WILL CLOSE FLYOUT
$("img#right").click(function (e) {
		

	if (!$panel.hasClass("animating") && $panel.hasClass("open")) {
		$panel.removeClass("open").addClass("animating");
      	$panel.hide("slide", { direction: "right" }, 500, function() {
		$("img#left").removeClass("stealth");
		$panel.removeClass("animating");
		});
	}
    e.stopPropagation();
});

 

//MAKE THE DROPDOWN WORK WITHOUT GO BUTTON
$("#faqSelect").change(function(e) {
		var redirectTo = $(this).val();
		if ($(this).val()) {
			VISA.Analytics.redirect(redirectTo);
		}
	});


//EXPAND ACCOUNT ANSWERS
	$('div#account h3').click(function() {
		$(this).next().slideToggle('fast');
		if ($(this).hasClass('arrow-up')) {
			$(this).removeClass('arrow-up').addClass('arrow-down');
		}
		else  {
			$(this).removeClass('arrow-down').addClass('arrow-up');
		}
	});

//EXPAND ALL ACCOUNT ANSWERS
$('span#expand_account').click(function() {
            if ($('div#account h3').hasClass('arrow-up')) {
                        $('div#account h3').removeClass('arrow-up').addClass('arrow-down').next().slideDown('fast');
			var htmlStr = "Contract All";
			$('span#expand_account').text(htmlStr);
            }
            else {
                        $('div#account h3').addClass('arrow-up').removeClass('arrow-down').next().slideUp('fast');
			var htmlStr = "Expand All";
			$('span#expand_account').text(htmlStr);
            }                       
});

//EXPAND SAFETY ANSWERS
	$('div#safety h3').click(function() {
		$(this).next().slideToggle('fast');
		if ($(this).hasClass('arrow-up')) {
			$(this).removeClass('arrow-up').addClass('arrow-down');
		}
		else  {
			$(this).removeClass('arrow-down').addClass('arrow-up');
		}
	});

//EXPAND ALL SAFETY ANSWERS
$('span#expand_safety').click(function() {
            if ($('div#safety h3').hasClass('arrow-up')) {
                        $('div#safety h3').removeClass('arrow-up').addClass('arrow-down').next().slideDown('fast');
var htmlStr = "Contract All";
			$('span#expand_safety').text(htmlStr);
            }
            else {
                        $('div#safety h3').addClass('arrow-up').removeClass('arrow-down').next().slideUp('fast');
var htmlStr = "Expand All";
			$('span#expand_safety').text(htmlStr);
            }                       
});

//EXPAND HOLOGRAPHIC ANSWERS
	$('div#holographic h3').click(function() {
		$(this).next().slideToggle('fast');
		if ($(this).hasClass('arrow-up')) {
			$(this).removeClass('arrow-up').addClass('arrow-down');
		}
		else  {
			$(this).removeClass('arrow-down').addClass('arrow-up');
		}
	});


//EXPAND ALL HOLOGRAPHIC ANSWERS
$('span#expand_holographic').click(function() {
            if ($('div#holographic h3').hasClass('arrow-up')) {
                        $('div#holographic h3').removeClass('arrow-up').addClass('arrow-down').next().slideDown('fast');
var htmlStr = "Contract All";
			$('span#expand_holographic').text(htmlStr);
            }
            else {
                        $('div#holographic h3').addClass('arrow-up').removeClass('arrow-down').next().slideUp('fast');
var htmlStr = "Expand All";
			$('span#expand_holographic').text(htmlStr);
            }                       
});

//EXPAND BRAND ANSWERS
	$('div#brand h3').click(function() {
		$(this).next().slideToggle('fast');
		if ($(this).hasClass('arrow-up')) {
			$(this).removeClass('arrow-up').addClass('arrow-down');
		}
		else  {
			$(this).removeClass('arrow-down').addClass('arrow-up');
		}
	});

//EXPAND ALL BRAND ANSWERS
$('span#expand_brand').click(function() {
            if ($('div#brand h3').hasClass('arrow-up')) {
                        $('div#brand h3').removeClass('arrow-up').addClass('arrow-down').next().slideDown('fast');
var htmlStr = "Contract All";
			$('span#expand_brand').text(htmlStr);
            }
            else {
                        $('div#brand h3').addClass('arrow-up').removeClass('arrow-down').next().slideUp('fast');
var htmlStr = "Expand All";
			$('span#expand_brand').text(htmlStr);
            }                       
});






 });