<?php
$gymnastics_center_color_scheme_css = '';
$gymnastics_center_first_color = get_theme_mod('gymnastics_center_first_color');

/*------------------ Global First Color -----------*/

if ($gymnastics_center_first_color) {
    $gymnastics_center_color_scheme_css .= ':root {';
    $gymnastics_center_color_scheme_css .= '--first-theme-color: ' . esc_attr($gymnastics_center_first_color) . ' !important;';
    $gymnastics_center_color_scheme_css .= '} ';
}


//---------------------------------Logo-Max-height--------- 
$gymnastics_center_logo_width = get_theme_mod('gymnastics_center_logo_width', 200);
if($gymnastics_center_logo_width != false){
    $gymnastics_center_color_scheme_css .='.logo img{';
      $gymnastics_center_color_scheme_css .='width: '.esc_html($gymnastics_center_logo_width).'px;';
    $gymnastics_center_color_scheme_css .='}';
}

/*--------------------------- Woocommerce Product Image Border Radius -------------------*/

$gymnastics_center_woo_product_img_border_radius = get_theme_mod('gymnastics_center_woo_product_img_border_radius');
if($gymnastics_center_woo_product_img_border_radius != false){
    $gymnastics_center_color_scheme_css .='.woocommerce-shop.woocommerce .product-content .product-image img{';
    $gymnastics_center_color_scheme_css .='border-radius: '.esc_attr($gymnastics_center_woo_product_img_border_radius).'px;';
    $gymnastics_center_color_scheme_css .='}';
}  

/*--------------------------- Scroll to top positions -------------------*/

$gymnastics_center_scroll_position = get_theme_mod( 'gymnastics_center_scroll_position','Right');
if($gymnastics_center_scroll_position == 'Right'){
    $gymnastics_center_color_scheme_css .='#button{';
        $gymnastics_center_color_scheme_css .='right: 20px;';
    $gymnastics_center_color_scheme_css .='}';
}else if($gymnastics_center_scroll_position == 'Left'){
    $gymnastics_center_color_scheme_css .='#button{';
        $gymnastics_center_color_scheme_css .='left: 20px;';
    $gymnastics_center_color_scheme_css .='}';
}else if($gymnastics_center_scroll_position == 'Center'){
    $gymnastics_center_color_scheme_css .='#button{';
        $gymnastics_center_color_scheme_css .='right: 50%;left: 50%;';
    $gymnastics_center_color_scheme_css .='}';
}

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

$gymnastics_center_footer_bg_image = get_theme_mod('gymnastics_center_footer_bg_image');
if($gymnastics_center_footer_bg_image != false){
    $gymnastics_center_color_scheme_css .='#footer{';
        $gymnastics_center_color_scheme_css .='background: url('.esc_attr($gymnastics_center_footer_bg_image).');';
        $gymnastics_center_color_scheme_css .= 'background-size: cover;';  
    $gymnastics_center_color_scheme_css .='}';
}

/*--------------------------- Footer image position -------------------*/

$gymnastics_center_footer_img_position = get_theme_mod('gymnastics_center_footer_img_position','center center');
if($gymnastics_center_footer_img_position != false){
    $gymnastics_center_color_scheme_css .='#footer{';
        $gymnastics_center_color_scheme_css .='background-position: '.esc_attr($gymnastics_center_footer_img_position).';';
    $gymnastics_center_color_scheme_css .='}';
}	

/*--------------------------- Blog Post Page Image Box Shadow -------------------*/

$gymnastics_center_blog_post_page_image_box_shadow = get_theme_mod('gymnastics_center_blog_post_page_image_box_shadow',0);
if($gymnastics_center_blog_post_page_image_box_shadow != false){
    $gymnastics_center_color_scheme_css .='.blog-post img{';
        $gymnastics_center_color_scheme_css .='box-shadow: '.esc_attr($gymnastics_center_blog_post_page_image_box_shadow).'px '.esc_attr($gymnastics_center_blog_post_page_image_box_shadow).'px '.esc_attr($gymnastics_center_blog_post_page_image_box_shadow).'px #cccccc;';
    $gymnastics_center_color_scheme_css .='}';
}       

/*--------------------------- Single Post Page Image Box Shadow -------------------*/

$gymnastics_center_single_post_page_image_box_shadow = get_theme_mod('gymnastics_center_single_post_page_image_box_shadow',0);
if($gymnastics_center_single_post_page_image_box_shadow != false){
    $gymnastics_center_color_scheme_css .='.single-post img{';
        $gymnastics_center_color_scheme_css .='box-shadow: '.esc_attr($gymnastics_center_single_post_page_image_box_shadow).'px '.esc_attr($gymnastics_center_single_post_page_image_box_shadow).'px '.esc_attr($gymnastics_center_single_post_page_image_box_shadow).'px #cccccc;';
    $gymnastics_center_color_scheme_css .='}';
}  

/*--------------------------- Shop page pagination -------------------*/

$gymnastics_center_wooproducts_nav = get_theme_mod('gymnastics_center_wooproducts_nav', 'Yes');
if($gymnastics_center_wooproducts_nav == 'No'){
  $gymnastics_center_color_scheme_css .='.woocommerce nav.woocommerce-pagination{';
    $gymnastics_center_color_scheme_css .='display: none;';
  $gymnastics_center_color_scheme_css .='}';
}

/*--------------------------- Related Product -------------------*/

$gymnastics_center_related_product_enable = get_theme_mod('gymnastics_center_related_product_enable',true);
if($gymnastics_center_related_product_enable == false){
  $gymnastics_center_color_scheme_css .='.related.products{';
    $gymnastics_center_color_scheme_css .='display: none;';
  $gymnastics_center_color_scheme_css .='}';
}

/*--------------------------- Scroll to Top Button Shape -------------------*/

	$gymnastics_center_scroll_top_shape = get_theme_mod('gymnastics_center_scroll_top_shape', 'circle');
	if($gymnastics_center_scroll_top_shape == 'box' ){
		$gymnastics_center_color_scheme_css .='#button{';
			$gymnastics_center_color_scheme_css .=' border-radius: 0%';
		$gymnastics_center_color_scheme_css .='}';
	}elseif($gymnastics_center_scroll_top_shape == 'curved' ){
		$gymnastics_center_color_scheme_css .='#button{';
			$gymnastics_center_color_scheme_css .=' border-radius: 20%';
		$gymnastics_center_color_scheme_css .='}';
	}elseif($gymnastics_center_scroll_top_shape == 'circle' ){
		$gymnastics_center_color_scheme_css .='#button{';
			$gymnastics_center_color_scheme_css .=' border-radius: 50%;';
		$gymnastics_center_color_scheme_css .='}';
	}