(function( $ ) {
	wp.customize.bind( 'ready', function() {

		var optPrefix = '#customize-control-event_dining_catering_options-';
		
		// Label
		function event_dining_catering_customizer_label( id, title ) {

			// Site Identity

			if ( id === 'custom_logo' || id === 'site_icon' ) {
				$( '#customize-control-'+ id ).before('<li class="tab-title customize-control">'+ title  +'</li>');
			} else {
				$( '#customize-control-event_dining_catering_options-'+ id ).before('<li class="tab-title customize-control">'+ title +'</li>');
			}

			// Global Color Setting

			if ( id === 'event_dining_catering_global_color' || id === 'event_dining_catering_heading_color' || id === 'event_dining_catering_paragraph_color') {
				$( '#customize-control-'+ id ).before('<li class="tab-title customize-control">'+ title  +'</li>');
			} else {
				$( '#customize-control-event_dining_catering_options-'+ id ).before('<li class="tab-title customize-control">'+ title +'</li>');
			}

			// General Setting

			if ( id === 'event_dining_catering_scroll_hide' || id === 'event_dining_catering_preloader_hide' || id === 'event_dining_catering_sticky_header' || id === 'event_dining_catering_products_per_row' || id === 'event_dining_catering_scroll_top_position' || id === 'event_dining_catering_products_per_row' || id === 'event_dining_catering_width_option' || id === 'event_dining_catering_nav_menu_text_transform')  {
				$( '#customize-control-'+ id ).before('<li class="tab-title customize-control">'+ title  +'</li>');
			} else {
				$( '#customize-control-event_dining_catering_options-'+ id ).before('<li class="tab-title customize-control">'+ title +'</li>');
			}

			// Colors

			if ( id === 'event_dining_catering_theme_color' || id === 'background_color' || id === 'background_image' ) {
				$( '#customize-control-'+ id ).before('<li class="tab-title customize-control">'+ title  +'</li>');
			} else {
				$( '#customize-control-event_dining_catering_options-'+ id ).before('<li class="tab-title customize-control">'+ title +'</li>');
			}

			// Header Image

			if ( id === 'header_image' || id === 'event_dining_catering_post_layout' || id === 'event_dining_catering_404_page_main_heading' || id === 'event_dining_catering_recipe_section_setting' ) {
				$( '#customize-control-'+ id ).before('<li class="tab-title customize-control">'+ title  +'</li>');
			} else {
				$( '#customize-control-event_dining_catering_options-'+ id ).before('<li class="tab-title customize-control">'+ title +'</li>');
			}

			// Social Icon

			if ( id === 'event_dining_catering_facebook_icon' || id === 'event_dining_catering_twitter_icon' || id === 'event_dining_catering_intagram_icon'|| id === 'event_dining_catering_linkedin_icon'|| id === 'event_dining_catering_pintrest_icon' ) {
				$( '#customize-control-'+ id ).before('<li class="tab-title customize-control">'+ title  +'</li>');
			} else {
				$( '#customize-control-event_dining_catering_options-'+ id ).before('<li class="tab-title customize-control">'+ title +'</li>');
			}

			//  Header
			
			if ( id === 'event_dining_catering_phone_number' || id === 'event_dining_catering_quote_btn_text') {
				$( '#customize-control-'+ id ).before('<li class="tab-title customize-control">'+ title  +'</li>');
			} else {
				$( '#customize-control-event_dining_catering_options-'+ id ).before('<li class="tab-title customize-control">'+ title +'</li>');
			}


			// Slider

			if ( id === 'event_dining_catering_banner_section_setting' || id === 'event_dining_catering_counter_number0' || id === 'event_dining_catering_review_image' ) {
				$( '#customize-control-'+ id ).before('<li class="tab-title customize-control">'+ title  +'</li>');
			} else {
				$( '#customize-control-event_dining_catering_options-'+ id ).before('<li class="tab-title customize-control">'+ title +'</li>');
			}

			// Products

			if ( id === 'event_dining_catering_categories_section_setting' ) {
				$( '#customize-control-'+ id ).before('<li class="tab-title customize-control">'+ title  +'</li>');
			} else {
				$( '#customize-control-event_dining_catering_options-'+ id ).before('<li class="tab-title customize-control">'+ title +'</li>');
			}

			// Footer

			if ( id === 'event_dining_catering_footer_widget_content_alignment' || id === 'event_dining_catering_show_hide_copyright') {
				$( '#customize-control-'+ id ).before('<li class="tab-title customize-control">'+ title  +'</li>');
			} else {
				$( '#customize-control-event_dining_catering_options-'+ id ).before('<li class="tab-title customize-control">'+ title +'</li>');
			}

			// Post Settings

			if ( id === 'event_dining_catering_post_page_title' ) {
				$( '#customize-control-'+ id ).before('<li class="tab-title customize-control">'+ title  +'</li>');
			} else {
				$( '#customize-control-event_dining_catering_options-'+ id ).before('<li class="tab-title customize-control">'+ title +'</li>');
			}

			// Single Post Settings

			if ( id === 'event_dining_catering_single_post_page_content' ) {
				$( '#customize-control-'+ id ).before('<li class="tab-title customize-control">'+ title  +'</li>');
			} else {
				$( '#customize-control-event_dining_catering_options-'+ id ).before('<li class="tab-title customize-control">'+ title +'</li>');
			}
			
		}

	    // Site Identity
		event_dining_catering_customizer_label( 'custom_logo', 'Logo Setup' );
		event_dining_catering_customizer_label( 'site_icon', 'Favicon' );

		// Global Color Setting
		event_dining_catering_customizer_label( 'event_dining_catering_global_color', 'Global Color' );
		event_dining_catering_customizer_label( 'event_dining_catering_heading_color', 'Heading Typography' );
		event_dining_catering_customizer_label( 'event_dining_catering_paragraph_color', 'Paragraph Typography' );

		// General Setting
		event_dining_catering_customizer_label( 'event_dining_catering_preloader_hide', 'Preloader' );
		event_dining_catering_customizer_label( 'event_dining_catering_sticky_header', 'Sticky Header' );
		event_dining_catering_customizer_label( 'event_dining_catering_scroll_hide', 'Scroll To Top' );
		event_dining_catering_customizer_label( 'event_dining_catering_scroll_top_position', 'Scroll to top Position' );
		event_dining_catering_customizer_label( 'event_dining_catering_products_per_row', 'woocommerce Setting' );
		event_dining_catering_customizer_label( 'event_dining_catering_width_option', 'Site Width Layouts' );
		event_dining_catering_customizer_label( 'event_dining_catering_nav_menu_text_transform', 'Nav Menus Text Transform' );

		// Colors
		event_dining_catering_customizer_label( 'event_dining_catering_theme_color', 'Theme Color' );
		event_dining_catering_customizer_label( 'background_color', 'Colors' );
		event_dining_catering_customizer_label( 'background_image', 'Image' );

		//Header Image
		event_dining_catering_customizer_label( 'header_image', 'Header Image' );

		event_dining_catering_customizer_label( 'event_dining_catering_post_layout', 'Post Layouts Settings' );

		event_dining_catering_customizer_label( 'event_dining_catering_404_page_main_heading', '404 Page Settings' );

		event_dining_catering_customizer_label( 'event_dining_catering_recipe_section_setting', 'Recipe Section' );

		

		// Social Icon
		event_dining_catering_customizer_label( 'event_dining_catering_facebook_icon', 'Facebook' );
		event_dining_catering_customizer_label( 'event_dining_catering_twitter_icon', 'Twitter' );
		event_dining_catering_customizer_label( 'event_dining_catering_intagram_icon', 'Intagram' );
		event_dining_catering_customizer_label( 'event_dining_catering_linkedin_icon', 'Linkedin' );
		event_dining_catering_customizer_label( 'event_dining_catering_pintrest_icon', 'Pintrest' );

		// Header 
		event_dining_catering_customizer_label( 'event_dining_catering_phone_number', 'Phone Number' );
		event_dining_catering_customizer_label( 'event_dining_catering_quote_btn_text', 'Header Button' );

		//Slider
		event_dining_catering_customizer_label( 'event_dining_catering_banner_section_setting', 'Banner' );
		event_dining_catering_customizer_label( 'event_dining_catering_counter_number0', 'Counter' );
		event_dining_catering_customizer_label( 'event_dining_catering_review_image', 'Review' );

		//Products
		event_dining_catering_customizer_label( 'event_dining_catering_categories_section_setting', 'Our Team' );

		//Footer
		event_dining_catering_customizer_label( 'event_dining_catering_footer_widget_content_alignment', 'Footer' );
		event_dining_catering_customizer_label( 'event_dining_catering_show_hide_copyright', 'Copyright' );

		//Post setting
		event_dining_catering_customizer_label( 'event_dining_catering_post_page_title', 'Post Settings' );

		//Single post setting
		event_dining_catering_customizer_label( 'event_dining_catering_single_post_page_content', 'Single Post Settings' );
	

	});

})( jQuery );
