<?php 
	$business_revolution_custom_css ='';

/*----------------Related Product show/hide -------------------*/

$business_revolution_enable_related_product = get_theme_mod('business_revolution_enable_related_product',1);

	if($business_revolution_enable_related_product == 0){
		$business_revolution_custom_css .='.related.products{';
			$business_revolution_custom_css .='display: none;';
		$business_revolution_custom_css .='}';
	}

/*----------------blog post content alignment -------------------*/

$business_revolution_blog_Post_content_layout = get_theme_mod( 'business_revolution_blog_Post_content_layout','Left');
    if($business_revolution_blog_Post_content_layout == 'Left'){
		$business_revolution_custom_css .='.ct-post-wrapper .card-item {';
			$business_revolution_custom_css .='text-align:start;';
		$business_revolution_custom_css .='}';
	}else if($business_revolution_blog_Post_content_layout == 'Center'){
		$business_revolution_custom_css .='.ct-post-wrapper .card-item {';
			$business_revolution_custom_css .='text-align:center;';
		$business_revolution_custom_css .='}';
	}else if($business_revolution_blog_Post_content_layout == 'Right'){
		$business_revolution_custom_css .='.ct-post-wrapper .card-item {';
			$business_revolution_custom_css .='text-align:end;';
		$business_revolution_custom_css .='}';
	}

	/*--------------------------- Footer background image -------------------*/

    $business_revolution_footer_bg_image = get_theme_mod('business_revolution_footer_bg_image');
    if($business_revolution_footer_bg_image != false){
        $business_revolution_custom_css .='.footer-top{';
            $business_revolution_custom_css .='background: url('.esc_attr($business_revolution_footer_bg_image).');';
        $business_revolution_custom_css .='}';
    }

	/*--------------------------- Go to top positions -------------------*/

    $business_revolution_go_to_top_position = get_theme_mod( 'business_revolution_go_to_top_position','Right');
    if($business_revolution_go_to_top_position == 'Right'){
        $business_revolution_custom_css .='.footer-go-to-top{';
            $business_revolution_custom_css .='right: 20px;';
        $business_revolution_custom_css .='}';
    }else if($business_revolution_go_to_top_position == 'Left'){
        $business_revolution_custom_css .='.footer-go-to-top{';
            $business_revolution_custom_css .='left: 20px;';
        $business_revolution_custom_css .='}';
    }else if($business_revolution_go_to_top_position == 'Center'){
        $business_revolution_custom_css .='.footer-go-to-top{';
            $business_revolution_custom_css .='right: 50%;left: 50%;';
        $business_revolution_custom_css .='}';
    }

    /*-------------------- Secondary Color -------------------*/

	$business_revolution_secondary_color = get_theme_mod('business_revolution_secondary_color', '#012641'); // Add a fallback if the color isn't set

	if ($business_revolution_secondary_color) {
		$business_revolution_custom_css .= ':root {';
		$business_revolution_custom_css .= '--secondary-color: ' . esc_attr($business_revolution_secondary_color) . ';';
		$business_revolution_custom_css .= '}';
	}	

    /*-------------------- Primary Color -------------------*/

	$business_revolution_primary_color = get_theme_mod('business_revolution_primary_color', '#60b3d1'); // Add a fallback if the color isn't set

	if ($business_revolution_primary_color) {
		$business_revolution_custom_css .= ':root {';
		$business_revolution_custom_css .= '--primary-color: ' . esc_attr($business_revolution_primary_color) . ';';
		$business_revolution_custom_css .= '}';
	}	

    /*--------------------------- Woocommerce Product Sale Positions -------------------*/

    $business_revolution_product_sale = get_theme_mod( 'business_revolution_woocommerce_product_sale','Right');
    if($business_revolution_product_sale == 'Right'){
        $business_revolution_custom_css .='.woocommerce ul.products li.product .onsale{';
            $business_revolution_custom_css .='left: auto; ';
        $business_revolution_custom_css .='}';
    }else if($business_revolution_product_sale == 'Left'){
        $business_revolution_custom_css .='.woocommerce ul.products li.product .onsale{';
            $business_revolution_custom_css .='right: auto;left:0;';
        $business_revolution_custom_css .='}';
    }else if($business_revolution_product_sale == 'Center'){
        $business_revolution_custom_css .='.woocommerce ul.products li.product .onsale{';
            $business_revolution_custom_css .='right: 50%; left: 50%; ';
        $business_revolution_custom_css .='}';
    }

    /*----------------Enable/Disable Breadcrumbs -------------------*/

    $business_revolution_enable_breadcrumbs = get_theme_mod('business_revolution_enable_breadcrumbs',1);

    if($business_revolution_enable_breadcrumbs == 0){
        $business_revolution_custom_css .='.business-revolution-breadcrumbs, nav.woocommerce-breadcrumb{';
            $business_revolution_custom_css .='display: none;';
        $business_revolution_custom_css .='}';
    }