<?php
$urban_courier_logistics_custom_css = "";
$urban_courier_logistics_primary_color = get_theme_mod('urban_courier_logistics_primary_color');
$urban_courier_logistics_secondary_color = get_theme_mod('urban_courier_logistics_secondary_color');

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

if ($urban_courier_logistics_primary_color) {
  $urban_courier_logistics_custom_css .= ':root {';
  $urban_courier_logistics_custom_css .= '--primary-color: ' . esc_attr($urban_courier_logistics_primary_color) . ' !important;';
  $urban_courier_logistics_custom_css .= '} ';
}

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

if ($urban_courier_logistics_secondary_color) {
  $urban_courier_logistics_custom_css .= ':root {';
  $urban_courier_logistics_custom_css .= '--secondary-color: ' . esc_attr($urban_courier_logistics_secondary_color) . ' !important;';
  $urban_courier_logistics_custom_css .= '} ';
}

/*-------------------- Scroll Top Alignment-------------------*/

$urban_courier_logistics_scroll_top_alignment = get_theme_mod( 'urban_courier_logistics_scroll_top_alignment','right-align');

if($urban_courier_logistics_scroll_top_alignment == 'right-align'){
$urban_courier_logistics_custom_css .='#button{';
	$urban_courier_logistics_custom_css .='right: 3%;';
$urban_courier_logistics_custom_css .='}';
}else if($urban_courier_logistics_scroll_top_alignment == 'center-align'){
$urban_courier_logistics_custom_css .='#button{';
	$urban_courier_logistics_custom_css .='right:0; left:0; margin: 0 auto;';
$urban_courier_logistics_custom_css .='}';
}else if($urban_courier_logistics_scroll_top_alignment == 'left-align'){
$urban_courier_logistics_custom_css .='#button{';
	$urban_courier_logistics_custom_css .='left: 3%;';
$urban_courier_logistics_custom_css .='}';
}

/*-------------------- Archive Page Pagination Alignment-------------------*/

$urban_courier_logistics_archive_pagination_alignment = get_theme_mod( 'urban_courier_logistics_archive_pagination_alignment','left-align');

if($urban_courier_logistics_archive_pagination_alignment == 'right-align'){
$urban_courier_logistics_custom_css .='.pagination{';
	$urban_courier_logistics_custom_css .='justify-content: end;';
$urban_courier_logistics_custom_css .='}';
}else if($urban_courier_logistics_archive_pagination_alignment == 'center-align'){
$urban_courier_logistics_custom_css .='.pagination{';
	$urban_courier_logistics_custom_css .='justify-content: center;';
$urban_courier_logistics_custom_css .='}';
}else if($urban_courier_logistics_archive_pagination_alignment == 'left-align'){
$urban_courier_logistics_custom_css .='.pagination{';
	$urban_courier_logistics_custom_css .='justify-content: start;';
$urban_courier_logistics_custom_css .='}';
}

/*-------------------- Scroll Top Responsive-------------------*/

$urban_courier_logistics_resp_scroll_top = get_theme_mod( 'urban_courier_logistics_resp_scroll_top',true);
if($urban_courier_logistics_resp_scroll_top == true && get_theme_mod( 'urban_courier_logistics_scroll_to_top',true) != true){
	$urban_courier_logistics_custom_css .='#button.show{';
		$urban_courier_logistics_custom_css .='visibility:hidden !important;';
	$urban_courier_logistics_custom_css .='} ';
}
if($urban_courier_logistics_resp_scroll_top == true){
	$urban_courier_logistics_custom_css .='@media screen and (max-width:575px) {';
	$urban_courier_logistics_custom_css .='#button.show{';
		$urban_courier_logistics_custom_css .='visibility:visible !important;';
	$urban_courier_logistics_custom_css .='} }';
}else if($urban_courier_logistics_resp_scroll_top == false){
	$urban_courier_logistics_custom_css .='@media screen and (max-width:575px){';
	$urban_courier_logistics_custom_css .='#button.show{';
		$urban_courier_logistics_custom_css .='visibility:hidden !important;';
	$urban_courier_logistics_custom_css .='} }';
}

/*-------------------- Preloader Responsive-------------------*/

$urban_courier_logistics_resp_loader = get_theme_mod('urban_courier_logistics_resp_loader',false);
if($urban_courier_logistics_resp_loader == true && get_theme_mod('urban_courier_logistics_header_preloader',false) == false){
	$urban_courier_logistics_custom_css .='@media screen and (min-width:575px){
		.preloader{';
		$urban_courier_logistics_custom_css .='display:none !important;';
	$urban_courier_logistics_custom_css .='} }';
}

if($urban_courier_logistics_resp_loader == false){
	$urban_courier_logistics_custom_css .='@media screen and (max-width:575px){
		.preloader{';
		$urban_courier_logistics_custom_css .='display:none !important;';
	$urban_courier_logistics_custom_css .='} }';
}

// Scroll to top button shape 

$urban_courier_logistics_scroll_border_radius = get_theme_mod( 'urban_courier_logistics_scroll_to_top_radius','curved-box');
if($urban_courier_logistics_scroll_border_radius == 'box'){
	$urban_courier_logistics_custom_css .='#button{';
		$urban_courier_logistics_custom_css .='border-radius: 0px;';
	$urban_courier_logistics_custom_css .='}';
}else if($urban_courier_logistics_scroll_border_radius == 'curved-box'){
	$urban_courier_logistics_custom_css .='#button{';
		$urban_courier_logistics_custom_css .='border-radius: 4px;';
	$urban_courier_logistics_custom_css .='}';
}
else if($urban_courier_logistics_scroll_border_radius == 'circle'){
	$urban_courier_logistics_custom_css .='#button{';
		$urban_courier_logistics_custom_css .='border-radius: 50%;';
	$urban_courier_logistics_custom_css .='}';
}

// Footer Background Image Attachment 

$urban_courier_logistics_footer_attachment = get_theme_mod( 'urban_courier_logistics_background_attachment','scroll');
if($urban_courier_logistics_footer_attachment == 'fixed'){
	$urban_courier_logistics_custom_css .='.site-footer{';
		$urban_courier_logistics_custom_css .='background-attachment: fixed;';
	$urban_courier_logistics_custom_css .='}';
}elseif ($urban_courier_logistics_footer_attachment == 'scroll'){
	$urban_courier_logistics_custom_css .='.site-footer{';
		$urban_courier_logistics_custom_css .='background-attachment: scroll;';
	$urban_courier_logistics_custom_css .='}';
}

// Menu Hover Style	

$urban_courier_logistics_menus_item = get_theme_mod( 'urban_courier_logistics_menus_style','None');
if($urban_courier_logistics_menus_item == 'None'){
	$urban_courier_logistics_custom_css .='#site-navigation .menu ul li a:hover, .main-navigation .menu li a:hover{';
		$urban_courier_logistics_custom_css .='';
	$urban_courier_logistics_custom_css .='}';
}else if($urban_courier_logistics_menus_item == 'Zoom In'){
	$urban_courier_logistics_custom_css .='#site-navigation .menu ul li a:hover, .main-navigation .menu li a:hover{';
		$urban_courier_logistics_custom_css .='transition: all 0.3s ease-in-out !important; transform: scale(1.2) !important;';
	$urban_courier_logistics_custom_css .='}';

	$urban_courier_logistics_custom_css .= '.main-navigation ul ul li a:hover {';
	$urban_courier_logistics_custom_css .= 'margin-left: 20px;';
	$urban_courier_logistics_custom_css .= '}';
}

// Banner Background Image
$urban_courier_logistics_banner_bg = get_theme_mod('urban_courier_logistics_banner_background_image');
if ( empty( $urban_courier_logistics_banner_bg ) ) {
	$urban_courier_logistics_banner_bg = get_template_directory_uri() . '/images/background.png';
}
$urban_courier_logistics_custom_css .= "
.banner::before {
	background-image: url('{$urban_courier_logistics_banner_bg}');
	background-size: cover;
	background-position: center;
	background-repeat: no-repeat;
    position: absolute;
    width: 100%;
    min-height: 600px;
}";