$(document).ready(function(){

$("#accordion, .zubehoere").accordion();

function showContent(){
	$("#accordion").fadeIn();
}
	

$(function(){
    //Get our elements for faster access and set overlay width
    var div = $('div.sc_menu1'),
                 ul = $('ul.sc_menu1'),
                 // unordered list's left margin
                 ulPadding = 15;

    //Get menu width
    var divWidth = div.width();

    //Remove scrollbars
    div.css({overflow: 'hidden'});

    //Find last image container
    var lastLi = ul.find('li:last-child');

    //When user move mouse over menu
    div.mousemove(function(e){

      //As images are loaded ul width increases,
      //so we recalculate it each time
      var ulWidth = lastLi[0].offsetLeft + lastLi.outerWidth() + ulPadding;

      var left = (e.pageX - div.offset().left) * (ulWidth-divWidth) / divWidth;
      div.scrollLeft(left);
    });
});

$(function(){
    //Get our elements for faster access and set overlay width
    var div = $('div.sc_menu2'),
                 ul = $('ul.sc_menu2'),
                 // unordered list's left margin
                 ulPadding = 15;

    //Get menu width
    var divWidth = div.width();

    //Remove scrollbars
    div.css({overflow: 'hidden'});

    //Find last image container
    var lastLi = ul.find('li:last-child');

    //When user move mouse over menu
    div.mousemove(function(e){

      //As images are loaded ul width increases,
      //so we recalculate it each time
      var ulWidth = lastLi[0].offsetLeft + lastLi.outerWidth() + ulPadding;

      var left = (e.pageX - div.offset().left) * (ulWidth-divWidth) / divWidth;
      div.scrollLeft(left);
    });
});

$(function(){
    //Get our elements for faster access and set overlay width
    var div = $('div.sc_menu3'),
                 ul = $('ul.sc_menu3'),
                 // unordered list's left margin
                 ulPadding = 15;

    //Get menu width
    var divWidth = div.width();

    //Remove scrollbars
    div.css({overflow: 'hidden'});

    //Find last image container
    var lastLi = ul.find('li:last-child');

    //When user move mouse over menu
    div.mousemove(function(e){

      //As images are loaded ul width increases,
      //so we recalculate it each time
      var ulWidth = lastLi[0].offsetLeft + lastLi.outerWidth() + ulPadding;

      var left = (e.pageX - div.offset().left) * (ulWidth-divWidth) / divWidth;
      div.scrollLeft(left);
    });
});



	//referenzbilder dd nav
	$(".dd_navi-14").find("a").mouseenter(function() {
		var link = $(this).attr("rel");
		if(link == ''){
			var link = '../img/ft_standard.jpg';
		}
		var naame	= $(this).attr("name").split('###');
		var my_name = naame[1].replace('<br>', ', ').replace('<br />', ', ').replace('<br/>', ', ');
		var my_id = naame[0];
		// Aktive Inhalte enternen
		$(".dd_text-14").find("p").html('').parent().find("h1").html('');
		$(".dd_text-15").find("p").html('').parent().find("h1").html('');
		$(".dd_text-16").find("p").html('').parent().find("h1").html('');
		$("#wg-14-prod").html('');
		$("#wg-15-prod").html('');
		$("#wg-16-prod").html('');
		$(".dd_navi-14 a, .dd_navi-14 li").removeClass("active");
		$("#refpic-14").attr('src', link);
		$(this).addClass("active");
		$(this).parent().addClass("active").css({opacity: ''}).siblings().css({opacity: '0.3'});
		//load warengruppe
		$('.dd_text-14, .dd_wg-14').hide();
		$('.dd_text-14 p').load('include/inc.load.warengruppe.text.php?id='+my_id);
		$(".dd_text-14 h1").html(my_name + " <span style=\"float:right;font-size:12px;color:#999;display:block;width:130px;\"><a target=\"_blank\" href=\"../data/lt_wysiwyg_media/Fertigungstechnik/LET_FertigungA4_D.pdf\">Informationsunterlagen</a><br><a href=\"index.php?MAIN_RUB_ID=5\" style=\"padding-right:45px;\">Kontaktanfrage</a></span>");
		$('#wg-14').load('include/inc.load.warengruppe.php?id='+my_id);
		$('.dd_text-14, .dd_wg-14').fadeIn('100');
	});

	$(".dd_navi-15").find("a").mouseenter(function() {
		var link = $(this).attr("rel");
		if(link == ''){
			var link = '../img/st_standard.jpg';
		}
		var naame	= $(this).attr("name").split('###');
		var my_name = naame[1].replace('<br>', ', ').replace('<br />', ', ').replace('<br/>', ', ');
		var my_id = naame[0];
		// Aktive Inhalte enternen
		$(".dd_text-14").find("p").html('').parent().find("h1").html('');
		$(".dd_text-15").find("p").html('').parent().find("h1").html('');
		$(".dd_text-16").find("p").html('').parent().find("h1").html('');
		$("#wg-14-prod").html('');
		$("#wg-15-prod").html('');
		$("#wg-16-prod").html('');
		$(".dd_navi-15 a, .dd_navi-15 li").removeClass("active");
		$("#refpic-15").attr('src', link);
		$(this).addClass("active");
		$(this).parent().addClass("active").css({opacity: ''}).siblings().css({opacity: '0.3'});
		//load warengruppe
		$('.dd_text-15, .dd_wg-15').hide();
		$('.dd_text-15 p').load('include/inc.load.warengruppe.text.php?id='+my_id);
		$(".dd_text-15 h1").html(my_name + " <span style=\"float:right;font-size:12px;color:#999;display:block;width:130px;\"><a target=\"_blank\" href=\"../data/lt_wysiwyg_media/Sicherheitstechnik/LET_SicherA4_D.pdf\">Informationsunterlagen</a><br><a href=\"index.php?MAIN_RUB_ID=5\" style=\"padding-right:45px;\">Kontaktanfrage</a></span>");
		$('#wg-15').load('include/inc.load.warengruppe.php?id='+my_id);
		$('.dd_text-15, .dd_wg-15').fadeIn('100');
	});

	$(".dd_navi-16").find("a").mouseenter(function() {
		var link = $(this).attr("rel");
		if(link == ''){
			var link = '../img/kt_standard.jpg';
		}
		var naame	= $(this).attr("name").split('###');
		var my_name = naame[1].replace('<br>', ', ').replace('<br />', ', ').replace('<br/>', ', ');
		var my_id = naame[0];
		// Aktive Inhalte enternen
		$(".dd_text-14").find("p").html('').parent().find("h1").html('');
		$(".dd_text-15").find("p").html('').parent().find("h1").html('');
		$(".dd_text-16").find("p").html('').parent().find("h1").html('');
		$("#wg-14-prod").html('');
		$("#wg-15-prod").html('');
		$("#wg-16-prod").html('');
		$(".dd_navi-16 a, .dd_navi-16 li").removeClass("active");
		$("#refpic-16").attr('src', link);
		$(this).addClass("active");
		$(this).parent().addClass("active").css({opacity: ''}).siblings().css({opacity: '0.3'});
		//load warengruppe
		//load warengruppe
		$('.dd_text-16, .dd_wg-16').hide();
		$('.dd_text-16 p').load('include/inc.load.warengruppe.text.php?id='+my_id);
		$(".dd_text-16 h1").html(my_name + " <span style=\"float:right;display:block;width:130px;font-size:12px;color:#999;\"><a target=\"_blank\" href=\"../data/lt_wysiwyg_media/Kommunikationstechnik/LET_KommA4_D.pdf\">Informationsunterlagen</a><br><a href=\"index.php?MAIN_RUB_ID=5\" style=\"padding-right:45px;\">Kontaktanfrage</a></span>");
		$('#wg-16').load('include/inc.load.warengruppe.php?id='+my_id);
		$('.dd_text-16, .dd_wg-16').fadeIn('100');
	});

	$("#wg-14").delegate("a", "mouseenter", function(){
		var my_id = $(this).attr("rel");
		var my_name = $(this).attr("name");
		$(".dd_text-14 h1").html(my_name + " <span style=\"float:right;font-size:12px;color:#999;display:block;width:130px;\"><a target=\"_blank\" href=\"../data/lt_wysiwyg_media/Fertigungstechnik/LET_FertigungA4_D.pdf\">Informationsunterlagen</a><br><a href=\"index.php?MAIN_RUB_ID=5\" style=\"padding-right:45px;\">Kontaktanfrage</a></span>");
		$("#wg-14 a").removeClass("active");
		$(this).addClass("active");
		//load warengruppe-text
		$('.dd_text-14 p').load('include/inc.load.warengruppe.text.php?id='+my_id);
		//load warengruppe-produkte dieser Kategorie
		$('#wg-14-prod').load('include/inc.load.warengruppe.prod.php?id='+my_id);
		if ($('#wg-14-prod').find('a.nopicture').size() == $('#wg-14-prod').find('a:not(.linkpdf)').size()) {
			var maximumwo2	=	680 - $('#wg-14').outerWidth(true) - 100;
			$('#wg-14-prod').css({maxWidth: maximumwo2});
		} else {
			var maximumwoshort	=	695 - $('#wg-14').outerWidth(true) - 235;
			$('#wg-14-prod').css({maxWidth: maximumwoshort});
		}
	});

	$("#wg-15").delegate("a", "mouseenter", function(){
		var my_id = $(this).attr("rel");
		var my_name = $(this).attr("name");
		$(".dd_text-15 h1").html(my_name + " <span style=\"float:right;font-size:12px;color:#999;display:block;width:130px;\"><a target=\"_blank\" href=\"../data/lt_wysiwyg_media/Sicherheitstechnik/LET_SicherA4_D.pdf\">Informationsunterlagen</a><br><a href=\"index.php?MAIN_RUB_ID=5\" style=\"padding-right:45px;\">Kontaktanfrage</a></span>");
		$("#wg-15 a").removeClass("active");
		$(this).addClass("active");
		 //load warengruppe-text
		$('.dd_text-15 p').load('include/inc.load.warengruppe.text.php?id='+my_id);
		 //load warengruppe-produkte dieser Kategorie
		$('#wg-15-prod').load('include/inc.load.warengruppe.prod.php?id='+my_id);
		if ($('#wg-15-prod').find('a.nopicture').size() == $('#wg-15-prod').find('a:not(.linkpdf)').size()) {
			var maximumwo2	=	680 - $('#wg-15').outerWidth(true);
			$('#wg-15-prod').css({maxWidth: maximumwo2});
		} else {
			var maximumwoshort	=	695 - $('#wg-14').outerWidth(true) - 235;
			$('#wg-15-prod').css({maxWidth: maximumwoshort});
		}
	});

	$("#wg-16").delegate("a", "mouseenter", function(){
		var my_id = $(this).attr("rel");
		var my_name = $(this).attr("name");
		$(".dd_text-16 h1").html(my_name + " <span style=\"float:right;font-size:12px;color:#999;display:block;width:130px;\"><a target=\"_blank\" href=\"../data/lt_wysiwyg_media/Kommunikationstechnik/LET_KommA4_D.pdf\">Informationsunterlagen</a><br><a href=\"index.php?MAIN_RUB_ID=5\" style=\"padding-right:45px;\">Kontaktanfrage</a></span>");
		$("#wg-16 a").removeClass("active");
		$(this).addClass("active");
		//load warengruppe-text
		$('.dd_text-16 p').load('include/inc.load.warengruppe.text.php?id='+my_id);
		//load warengruppe-produkte dieser Kategorie
		$('#wg-16-prod').load('include/inc.load.warengruppe.prod.php?id='+my_id);
		if ($('#wg-16-prod').find('a.nopicture').size() == $('#wg-16-prod').find('a:not(.linkpdf)').size()) {
			var maximumwo2	=	680 - $('#wg-16').outerWidth(true);
			$('#wg-16-prod').css({maxWidth: maximumwo2});
		} else {
			var maximumwoshort	=	695 - $('#wg-14').outerWidth(true) - 235;
			$('#wg-16-prod').css({maxWidth: maximumwoshort});
		}
	});
	  
	$("#wg-14-prod").delegate("a:not(.nopicture)", "mouseenter", function(){
		var my_id = $(this).attr("rel");
		var my_name = $(this).attr("name");
		//load warengruppe-prod-bild
		$('.dd_pic-14').load('include/inc.load.warengruppe.prod.bild.php?objid='+my_id).show();
	}).delegate("a", "mouseleave", function(){
		$('.dd_pic-14').html('').hide();
	});

	$("#wg-15-prod").delegate("a:not(.nopicture)", "mouseenter", function(){
		var my_id = $(this).attr("rel");
		var my_name = $(this).attr("name");
		//load warengruppe-prod-bild
		$('.dd_pic-15').load('include/inc.load.warengruppe.prod.bild.php?objid='+my_id).show();
	}).delegate("a", "mouseleave", function(){
		$('.dd_pic-15').html('').hide();
	});

	$("#wg-16-prod").delegate("a:not(.nopicture)", "mouseenter", function(){
		var my_id = $(this).attr("rel");
		var my_name = $(this).attr("name");
		//load warengruppe-prod-bild
		$('.dd_pic-16').load('include/inc.load.warengruppe.prod.bild.php?objid='+my_id).show();
	}).delegate("a", "mouseleave", function(){
		$('.dd_pic-16').html('').hide();
	});


	function clearactive () {
		$(".dd_navi-15 a").removeClass("active");
		$(".dd_navi-15").removeClass("active");
		$("#wg-15").html('');
		$("#wg-15-prod").html('');
		$(".dd_navi-14 a").removeClass("active");
		$(".dd_navi-14").removeClass("active");
		$("#wg-14").html('');
		$("#wg-14-prod").html('');
		$(".dd_navi-16 a").removeClass("active");
		$(".dd_navi-16").removeClass("active");
		$("#wg-16").html('');
		$("#wg-16-prod").html('');
		$(".dd_text-14").find("p").html('').parent().find("h1").html('');
		$(".dd_text-15").find("p").html('').parent().find("h1").html('');
		$(".dd_text-16").find("p").html('').parent().find("h1").html('');
	}
		
	function getfirstactive (katid) {
		var link = $(".dd_navi-"+katid).find("a:first-child").attr("rel");
		var my_id = $(".dd_navi-"+katid).find("a:first-child").attr("name");

		$("#refpic-"+katid).attr('src', link);
		$(".dd_navi-"+katid).find("a:first-child").addClass("active");
		//load warengruppe
		$('#wg-'+katid).load('include/inc.load.warengruppe.php?id='+my_id);
	
		var my_id2 = $("#wg-"+katid).find("a:first-child").attr("rel");
		var my_name2 = $("#wg-"+katid).find("a:first-child").attr("name");
		$(".dd_text-"+katid+" h1").html(my_name2 + " <span style=\"float:right;font-size:12px;color:#999;display:block;width:130px;\"><a href=\"#\">Informationsunterlagen</a><br><a href=\"index.php?MAIN_RUB_ID=5\" style=\"padding-right:45px;\">Kontaktanfrage</a></span>");
		$("#wg-"+katid+" a").removeClass("active");
		$("#wg-"+katid).find("a:first-child").addClass("active");
		//load warengruppe-text
		$('.dd_text-'+katid+' p').load('include/inc.load.warengruppe.text.php?id='+my_id2);
		//load warengruppe-produkte dieser Kategorie
		$('#wg-'+katid+'-prod').load('include/inc.load.warengruppe.prod.php?id='+my_id2);
	}

	//globale schliessbefehle
	$("#metanavigation").mouseenter(function() {
		$("#ds_t").css({opacity: ''});
		$("#df_t").css({opacity: ''});
		$("#dk_t").css({opacity: ''});
		$('.dd_text-14, .dd_wg-14').hide();
		$('.dd_text-15, .dd_wg-15').hide();
		$('.dd_text-16, .dd_wg-16').hide();
		$("#df_on").hide();
		$("#dk_on").hide();
		$("#ds_on").hide();
		$(".dd_text-14").find("p").html('').parent().find("h1").html('');
		$(".dd_text-15").find("p").html('').parent().find("h1").html('');
		$(".dd_text-16").find("p").html('').parent().find("h1").html('');
	});

	$(".logo").mouseenter(function() {
		$("#ds_t").css({opacity: ''});
		$("#df_t").css({opacity: ''});
		$("#dk_t").css({opacity: ''});
		$('.dd_text-14, .dd_wg-14').hide();
		$('.dd_text-15, .dd_wg-15').hide();
		$('.dd_text-16, .dd_wg-16').hide();
		$("#df_on").hide();
		$("#dk_on").hide();
		$("#ds_on").hide();
		$(".dd_text-14").find("p").html('').parent().find("h1").html('');
		$(".dd_text-15").find("p").html('').parent().find("h1").html('');
		$(".dd_text-16").find("p").html('').parent().find("h1").html('');
	});

	/* DK */

	$('#dk_t').mouseenter(function() {
		clearactive();
		var my_id = '16';
		$(".dd_navi-16 li").css({opacity: ''}).removeClass('active');
		$("#dk_t").css({opacity: ''});
		$("#df_t").css({opacity: '0.3'});
		$("#ds_t").css({opacity: '0.3'});
		$('.dd_text-14, .dd_wg-14').hide();
		$('.dd_text-15, .dd_wg-15, .dd_wg-16').hide();
		$('.dd_text-16').show();
		$("#dk_on").show();
		$("#ds_on").hide();
		$("#df_on").hide();
		$(".dd_text-14").find("p").html('').parent().find("h1").html('');
		$(".dd_text-15").find("p").html('').parent().find("h1").html('');
		$('.dd_text-16 p').load('include/inc.load.text.php?id='+my_id);
		$(".dd_text-16 h1").html("Kommunikationstechnik <span style=\"float:right;font-size:12px;color:#999;display:block;width:130px;\"><a target=\"_blank\" href=\"../data/lt_wysiwyg_media/Kommunikationstechnik/LET_KommA4_D.pdf\">Informationsunterlagen</a><br><a href=\"index.php?MAIN_RUB_ID=5\" style=\"padding-right:45px;\">Kontaktanfrage</a></span>");
	}).mouseleave(function() {
		//Aktive Inhalte 'Ent-aktivieren'
		clearactive();
	});

	$('#dk_on').mouseenter(function(){
		var my_id = '16';
		$('.dd_text-16 p').load('include/inc.load.text.php?id='+my_id);
		$(".dd_text-16 h1").html("Kommunikationstechnik <span style=\"float:right;font-size:12px;color:#999;display:block;width:130px;\"><a target=\"_blank\" href=\"../data/lt_wysiwyg_media/Kommunikationstechnik/LET_KommA4_D.pdf\">Informationsunterlagen</a><br><a href=\"index.php?MAIN_RUB_ID=5\" style=\"padding-right:45px;\">Kontaktanfrage</a></span>");
	}).mouseleave(function() {
		$("#df_t").css({opacity: ''});
		$("#ds_t").css({opacity: ''});
		$('.dd_text-14, .dd_wg-14').hide();
		$('.dd_text-15, .dd_wg-15, .dd_wg-16').hide();
		$('.dd_text-16').show();
		$("#dk_on").hide();
		$("#df_on").hide();
		$("#ds_on").hide();
		//Aktive Inhalte 'Ent-aktivieren'
		$(".dd_navi-15 a").removeClass("active");
		$(".dd_navi-15").removeClass("active");
		$("#wg-15").html('');
		$("#wg-15-prod").html('');
		$(".dd_navi-14 a").removeClass("active");
		$(".dd_navi-14").removeClass("active");
		$("#wg-14").html('');
		$("#wg-14-prod").html('');
		$(".dd_text-14").find("p").html('').parent().find("h1").html('');
		$(".dd_text-15").find("p").html('').parent().find("h1").html('');
	});

	/* DS  */

	$('#ds_t').mouseenter(function() {
		clearactive();
		var my_id = '15';
		$(".dd_navi-15 li").css({opacity: ''}).removeClass('active');
		$("#ds_t").css({opacity: ''});
		$("#df_t").css({opacity: '0.3'});
		$("#dk_t").css({opacity: '0.3'});
		$('.dd_text-14, .dd_wg-14, .dd_wg-15').hide();
		$('.dd_text-15').show();
		$('.dd_text-16, .dd_wg-16').hide();
		$("#ds_on").show();
		$("#dk_on").hide();
		$("#df_on").hide();
		$(".dd_text-14").find("p").html('').parent().find("h1").html('');
		$(".dd_text-16").find("p").html('').parent().find("h1").html('');
		$('.dd_text-15 p').load('include/inc.load.text.php?id='+my_id);
		$(".dd_text-15 h1").html("Sicherheitstechnik <span style=\"float:right;display:block;width:130px;font-size:12px;color:#999;\"><a target=\"_blank\" href=\"../data/lt_wysiwyg_media/Sicherheitstechnik/LET_SicherA4_D.pdf\">Informationsunterlagen</a><br><a href=\"index.php?MAIN_RUB_ID=5\" style=\"padding-right:45px;\">Kontaktanfrage</a></span>");
	}).mouseleave(function() {
		//Aktive Inhalte 'Ent-aktivieren'
		clearactive();
	});

	$('#ds_on').mouseenter(function(){
		var my_id = '15';
		$('.dd_text-15 p').load('include/inc.load.text.php?id='+my_id);
		$(".dd_text-15 h1").html("Sicherheitstechnik <span style=\"float:right;font-size:12px;color:#999;display:block;width:130px;\"><a target=\"_blank\" href=\"../data/lt_wysiwyg_media/Sicherheitstechnik/LET_SicherA4_D.pdf\">Informationsunterlagen</a><br><a href=\"index.php?MAIN_RUB_ID=5\" style=\"padding-right:45px;\">Kontaktanfrage</a></span>");
	}).mouseleave(function() {
		$("#df_t").css({opacity: ''});
		$("#dk_t").css({opacity: ''});
		$('.dd_text-14, .dd_wg-14, .dd_wg-15').hide();
		$('.dd_text-15').show();
		$('.dd_text-16, .dd_wg-16').hide();
		$("#dk_on").hide();
		$("#df_on").hide();
		$("#ds_on").hide();
		//Aktive Inhalte 'Ent-aktivieren'
		$(".dd_navi-14 a").removeClass("active");
		$(".dd_navi-14").removeClass("active");
		$("#wg-14").html('');
		$("#wg-14-prod").html('');
		$(".dd_navi-16 a").removeClass("active");
		$(".dd_navi-16").removeClass("active");
		$("#wg-16").html('');
		$("#wg-16-prod").html('');
		$(".dd_text-14").find("p").html('').parent().find("h1").html('');
		$(".dd_text-16").find("p").html('').parent().find("h1").html('');
	});

	/* DF */

	$('#df_t').mouseenter(function() {
		clearactive();
		var my_id = '14';
		$(".dd_navi-14 li").css({opacity: ''}).removeClass('active');
		$("#df_t").css({opacity: ''});
		$("#ds_t").css({opacity: '0.3'});
		$("#dk_t").css({opacity: '0.3'});
		$('.dd_text-14').show();
		$('.dd_text-15, .dd_wg-15, .dd_wg-14').hide();
		$('.dd_text-16, .dd_wg-16').hide();
		$("#df_on").show();
		$("#dk_on").hide();
		$("#ds_on").hide();
		$(".dd_text-15").find("p").html('').parent().find("h1").html('');
		$(".dd_text-16").find("p").html('').parent().find("h1").html('');
		$('.dd_text-14 p').load('include/inc.load.text.php?id='+my_id);
		$(".dd_text-14 h1").html("Fertigungstechnik <span style=\"float:right;font-size:12px;color:#999;display:block;width:130px;\"><a target=\"_blank\" href=\"../data/lt_wysiwyg_media/Fertigungstechnik/LET_FertigungA4_D.pdf\">Informationsunterlagen</a><br><a href=\"index.php?MAIN_RUB_ID=5\" style=\"padding-right:45px;\">Kontaktanfrage</a></span>");
	}).mouseleave(function() {
		//Aktive Inhalte 'Ent-aktivieren'
		clearactive();
	});

	$('#df_on').mouseenter(function(){
		var my_id = '14';
		$('.dd_text-14 p').load('include/inc.load.text.php?id='+my_id);
		$(".dd_text-14 h1").html("Fertigungstechnik <span style=\"float:right;font-size:12px;color:#999;display:block;width:130px;\"><a target=\"_blank\" href=\"../data/lt_wysiwyg_media/Fertigungstechnik/LET_FertigungA4_D.pdf\">Informationsunterlagen</a><br><a href=\"index.php?MAIN_RUB_ID=5\" style=\"padding-right:45px;\">Kontaktanfrage</a></span>");
	}).mouseleave(function() {
		$("#ds_t").css({opacity: ''});
		$("#dk_t").css({opacity: ''});
		$('.dd_text-14').show();
		$('.dd_text-15, .dd_wg-14, .dd_wg-15').hide();
		$('.dd_text-16, .dd_wg-16').hide();
		$("#dk_on").hide();
		$("#df_on").hide();
		$("#ds_on").hide();
		//Aktive Inhalte 'Ent-aktivieren'
		$(".dd_navi-15 a").removeClass("active");
		$(".dd_navi-15").removeClass("active");
		$("#wg-15").html('');
		$("#wg-15-prod").html('');
		$(".dd_navi-16 a").removeClass("active");
		$(".dd_navi-16").removeClass("active");
		$("#wg-16").html('');
		$("#wg-16-prod").html('');
		$(".dd_text-15").find("p").html('').parent().find("h1").html('');
		$(".dd_text-16").find("p").html('').parent().find("h1").html('');
	});

	$('#sub_hnav').mouseenter(function() {
		$("#ds_t").css({opacity: ''});
		$("#df_t").css({opacity: ''});
		$("#dk_t").css({opacity: ''});
		$('.dd_text-14, .dd_wg-14').hide();
		$('.dd_text-15, .dd_wg-15').hide();
		$('.dd_text-16, .dd_wg-16').hide();
		$("#df_on").hide();
		$("#dk_on").hide();
		$("#ds_on").hide();
	});

	$("#dk_off12").hover(function(){
		$("#dk_on").show();
		/*
		$("#ssn2").attr('style', 'color:#583119');
		$("#ssn1").attr('style', 'color:#86a20b');
		$("#pic").attr('src', 'img/grundriss_eg_01.png');
		$("#vol").attr('src', 'img/volumetrie_eg_01.png');
		*/
	},
	function(){
		$("#dk_on").hide();
	});
	
	// Öffnet Login in Colorbox 
	$('#login').colorbox({top:"100px", width:"440px", height:"210px", href:"/inc/login.php"});
	$('#newsletter').colorbox({top:"100px", width:"440px", height:"210px", href:"/inc/newsletter.php"});
	$('.uebersichtsprodukt').colorbox();
	$('.ralIt').colorbox({width:"730px"});
	// Tooltip: Kursinfo bei Mouseover        
	$('a[title]').qtip({ position: { corner: { target: 'topMiddle', tooltip: 'bottomMiddle' } },  style: { width: 300, border: { width: 2, radius: 2, color: '#999999' }, tip: { color: false}, name: 'light', tip: true } });
	$('.line_on[title]').qtip({ position: { corner: { target: 'topMiddle', tooltip: 'bottomMiddle' } },  style: { width: 300, border: { width: 2, radius: 2, color: '#999999' }, tip: { color: false}, name: 'light', tip: true } });
	$('.schulungenfront span[title]').qtip({ position: { corner: { target: 'topMiddle', tooltip: 'bottomMiddle' } },  style: { width: 300, border: { width: 2, radius: 2, color: '#999999' }, tip: { color: false}, name: 'light', tip: true } });
	$(".produktebild").colorbox();
	$(".referenzbild").colorbox();
	$(".lichtmasse").colorbox({width:"1024px", height:"800px"});
	$("#accordion").accordion({
	autoHeight: true,
	navigation: true
	});
	//Height:0 > Fix in all Browsers
	$('#accordion >div').css('height', 'auto');
	$(".cadbild").colorbox();
	
	// SHOW SPAN of MERKMAL
	$('.showunderspan').mouseenter(function() {
		$(this).css({backgroundColor: '#C4DAED'}).find('span').css({zIndex: '1'}).show().parent().siblings().find('span').css({zIndex: '3'});
		var srcOld	=	$(this).find('img').attr('src');
		var srcNew	=	srcOld.replace(".jpg","_on.jpg");
		if(srcOld.indexOf("_on") == -1){
			$(this).find('img').attr('src',srcNew);
		}
	}).mouseleave(function(){
		$(this).css({backgroundColor: ''}).find('span').css({zIndex: ''}).hide().parent().siblings().find('span').css({zIndex: ''});
		var srcOld	=	$(this).find('img').attr('src');
		var srcNew	=	srcOld.replace("_on.jpg",".jpg");
		$(this).find('img').attr('src',srcNew);
	});
});


