<?php

	$real_estate_broker_custom_css ='';

	$real_estate_realtor_slider_hide = get_theme_mod('real_estate_realtor_slider_hide', false);
	if ($real_estate_realtor_slider_hide == false) {
		$real_estate_broker_custom_css .= '.page-template-home-page #header {';
		$real_estate_broker_custom_css .= 'position: static !important;';
		$real_estate_broker_custom_css .= 'background-color: var(--first-theme-color) !important;'; 
		$real_estate_broker_custom_css .= 'background: var(--first-theme-color) !important;'; 
		$real_estate_broker_custom_css .= 'padding-bottom: 10px !important;'; 
		$real_estate_broker_custom_css .= '} ';
	}	

	// slider content spacing
	$real_estate_realtor_slider_content_left_padding = get_theme_mod('real_estate_realtor_slider_content_left_padding');
	$real_estate_broker_custom_css .='#slider .carousel-caption, #slider .inner_carousel, #slider .inner_carousel h1, #slider .inner_carousel p, #slider .readbutton{';
		$real_estate_broker_custom_css .='%;left: '.esc_attr($real_estate_realtor_slider_content_left_padding).'%;right: '.esc_attr($real_estate_realtor_slider_content_left_padding).'%;';
	$real_estate_broker_custom_css .='}';

	// slider overlay
	$real_estate_realtor_enable_slider_overlay = get_theme_mod('real_estate_realtor_enable_slider_overlay', true);
	if($real_estate_realtor_enable_slider_overlay == false){
		$real_estate_broker_custom_css .='#slider image{';
			$real_estate_broker_custom_css .='opacity:1;';
		$real_estate_broker_custom_css .='}';
	} 
	$real_estate_realtor_slider_overlay_color = get_theme_mod('real_estate_realtor_slider_overlay_color');
	if($real_estate_realtor_enable_slider_overlay != ''){
		$real_estate_broker_custom_css .='#slider{';
			$real_estate_broker_custom_css .='background-color: '.esc_attr($real_estate_realtor_slider_overlay_color).';';
		$real_estate_broker_custom_css .='}';
	}

	//menu top-bottom padding
	$real_estate_realtor_menu_top_bottom_padding = get_theme_mod('real_estate_realtor_menu_top_bottom_padding');
	$real_estate_broker_custom_css .='.primary-navigation ul li{';
		$real_estate_broker_custom_css .='padding-top: '.esc_attr($real_estate_realtor_menu_top_bottom_padding).'px;';
		$real_estate_broker_custom_css .='padding-bottom: '.esc_attr($real_estate_realtor_menu_top_bottom_padding).'px;';
	$real_estate_broker_custom_css .='}';

	//menu left-right padding
	$real_estate_realtor_menu_left_right_padding = get_theme_mod('real_estate_realtor_menu_left_right_padding');
	$real_estate_broker_custom_css .='.primary-navigation ul li{';
		$real_estate_broker_custom_css .='padding-left: '.esc_attr($real_estate_realtor_menu_left_right_padding).'px;';
		$real_estate_broker_custom_css .='padding-right: '.esc_attr($real_estate_realtor_menu_left_right_padding).'px;';
	$real_estate_broker_custom_css .='}';

	//Theme Color Option
	$real_estate_realtor_first_color = get_theme_mod('real_estate_realtor_first_color');
	
	/*------------------ Global First Color -----------*/

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

	//Copyright text color
	$real_estate_realtor_copyright_text_color = get_theme_mod('real_estate_realtor_copyright_text_color');
	$real_estate_broker_custom_css .='.copyright-wrapper p, .copyright-wrapper p a{';
		$real_estate_broker_custom_css .='color: '.esc_attr($real_estate_realtor_copyright_text_color).';';
	$real_estate_broker_custom_css .='}';

	//Copyright background css
	$real_estate_realtor_copyright_text_background = get_theme_mod('real_estate_realtor_copyright_text_background');
	$real_estate_broker_custom_css .='.copyright-wrapper{';
		$real_estate_broker_custom_css .='background-color: '.esc_attr($real_estate_realtor_copyright_text_background).';';
	$real_estate_broker_custom_css .='}';

	// back to top icon color
	$real_estate_realtor_scroll_icon_color = get_theme_mod('real_estate_realtor_scroll_icon_color');
	$real_estate_broker_custom_css .='#scrollbutton i{';
		$real_estate_broker_custom_css .='color: '.esc_attr($real_estate_realtor_scroll_icon_color).';';
	$real_estate_broker_custom_css .='}';

	//Back to Top bg color
	$real_estate_realtor_scroll_icon_background = get_theme_mod('real_estate_realtor_scroll_icon_background');
	$real_estate_broker_custom_css .='#scrollbutton i{';
		$real_estate_broker_custom_css .='background-color: '.esc_attr($real_estate_realtor_scroll_icon_background).';';
		$real_estate_broker_custom_css .='border-color: '.esc_attr($real_estate_realtor_scroll_icon_background).';';
	$real_estate_broker_custom_css .='}';

	// Footer Heading Alignment
		$real_estate_realtor_footer_heading = get_theme_mod( 'real_estate_realtor_footer_heading','Left');
    if($real_estate_realtor_footer_heading == 'Left'){
		$real_estate_broker_custom_css .='.footer-wp h3, .footer-wp .wp-block-search .wp-block-search__label{';
		$real_estate_broker_custom_css .='text-align: left;';
		$real_estate_broker_custom_css .='}';
	}else if($real_estate_realtor_footer_heading == 'Center'){
		$real_estate_broker_custom_css .='.footer-wp h3, .footer-wp .wp-block-search .wp-block-search__label{';
			$real_estate_broker_custom_css .='text-align: center;';
		$real_estate_broker_custom_css .='}';
		$real_estate_broker_custom_css .='.footer-wp h3:after, .footer-wp .wp-block-heading:after{';
			$real_estate_broker_custom_css .='margin: 7px auto;';
		$real_estate_broker_custom_css .='}';
		$real_estate_broker_custom_css .='
		@media screen and (max-width:767px) {
			.footer-wp h3, .footer-wp .wp-block-search .wp-block-search__label{';
				$real_estate_broker_custom_css .='text-align: left;';
				$real_estate_broker_custom_css .='}
			.footer-wp h3:after, .footer-wp .wp-block-heading:after{';
				$real_estate_broker_custom_css .='margin: 7px 0 0;';
				$real_estate_broker_custom_css .='} }';
	}else if($real_estate_realtor_footer_heading == 'Right'){
		$real_estate_broker_custom_css .='.footer-wp h3, .footer-wp .wp-block-search .wp-block-search__label{';
			$real_estate_broker_custom_css .='text-align: right; padding-bottom: 25px;';
		$real_estate_broker_custom_css .='}';
		$real_estate_broker_custom_css .='.footer-wp .widget, .footer-wp aside{';
			$real_estate_broker_custom_css .='position: relative;';
		$real_estate_broker_custom_css .='}';
		$real_estate_broker_custom_css .='.footer-wp h3:after, .footer-wp .wp-block-heading:after{';
			$real_estate_broker_custom_css .='position: absolute; right: 0;';
		$real_estate_broker_custom_css .='}';
		$real_estate_broker_custom_css .='
		@media screen and (max-width:767px) {
			.footer-wp h3, .footer-wp .wp-block-search .wp-block-search__label{';
				$real_estate_broker_custom_css .='text-align: left;';
				$real_estate_broker_custom_css .='}
			.footer-wp h3:after, .footer-wp .wp-block-heading:after{';
				$real_estate_broker_custom_css .='left: 0;';
				$real_estate_broker_custom_css .='} }';
	}

	// Fixed Copyright
	$real_estate_realtor_fixed_copyright = get_theme_mod( 'real_estate_realtor_display_fixed_copyright',false);
	if($real_estate_realtor_fixed_copyright == true && get_theme_mod( 'real_estate_realtor_sticky_copyright',false) != true){
    	$real_estate_broker_custom_css .='.fixed-copyright{';
			$real_estate_broker_custom_css .='position:static;';
		$real_estate_broker_custom_css .='} ';
	}
    if($real_estate_realtor_fixed_copyright == true){
    	$real_estate_broker_custom_css .='@media screen and (max-width:575px) {';
		$real_estate_broker_custom_css .='.fixed-copyright{';
			$real_estate_broker_custom_css .='position:fixed;';
		$real_estate_broker_custom_css .='} }';
	}else if($real_estate_realtor_fixed_copyright == false){
		$real_estate_broker_custom_css .='@media screen and (max-width:575px){';
		$real_estate_broker_custom_css .='.fixed-copyright{';
			$real_estate_broker_custom_css .='position:static;';
		$real_estate_broker_custom_css .='} }';
	}