<?php

$skin_care_solutions_custom_css = "";

	$skin_care_solutions_theme_pagination_options_alignment = get_theme_mod('skin_care_solutions_theme_pagination_options_alignment', 'Center');
	if ($skin_care_solutions_theme_pagination_options_alignment == 'Center') {
		$skin_care_solutions_custom_css .= '.navigation.pagination,.navigation.posts-navigation .nav-links{';
		$skin_care_solutions_custom_css .= 'justify-content: center;margin: 0 auto;';
		$skin_care_solutions_custom_css .= '}';
	} else if ($skin_care_solutions_theme_pagination_options_alignment == 'Right') {
		$skin_care_solutions_custom_css .= '.navigation.pagination,.navigation.posts-navigation .nav-links{';
		$skin_care_solutions_custom_css .= 'justify-content: right;margin: 0 0 0 auto;';
		$skin_care_solutions_custom_css .= '}';
	} else if ($skin_care_solutions_theme_pagination_options_alignment == 'Left') {
		$skin_care_solutions_custom_css .= '.navigation.pagination,.navigation.posts-navigation .nav-links{';
		$skin_care_solutions_custom_css .= 'justify-content: left;margin: 0 auto 0 0;';
		$skin_care_solutions_custom_css .= '}';
	}

	$skin_care_solutions_theme_breadcrumb_enable = get_theme_mod('skin_care_solutions_theme_breadcrumb_enable',true);
    if($skin_care_solutions_theme_breadcrumb_enable != true){
        $skin_care_solutions_custom_css .='nav.breadcrumb-trail.breadcrumbs,nav.woocommerce-breadcrumb{';
            $skin_care_solutions_custom_css .='display: none;';
        $skin_care_solutions_custom_css .='}';
    }

	$skin_care_solutions_theme_breadcrumb_options_alignment = get_theme_mod('skin_care_solutions_theme_breadcrumb_options_alignment', 'Left');
	if ($skin_care_solutions_theme_breadcrumb_options_alignment == 'Center') {
	    $skin_care_solutions_custom_css .= '.breadcrumbs ul,nav.woocommerce-breadcrumb{';
	    $skin_care_solutions_custom_css .= 'text-align: center !important;';
	    $skin_care_solutions_custom_css .= '}';
	} else if ($skin_care_solutions_theme_breadcrumb_options_alignment == 'Right') {
	    $skin_care_solutions_custom_css .= '.breadcrumbs ul,nav.woocommerce-breadcrumb{';
	    $skin_care_solutions_custom_css .= 'text-align: Right !important;';
	    $skin_care_solutions_custom_css .= '}';
	} else if ($skin_care_solutions_theme_breadcrumb_options_alignment == 'Left') {
	    $skin_care_solutions_custom_css .= '.breadcrumbs ul,nav.woocommerce-breadcrumb{';
	    $skin_care_solutions_custom_css .= 'text-align: Left !important;';
	    $skin_care_solutions_custom_css .= '}';
	}

	$skin_care_solutions_single_page_content_alignment = get_theme_mod('skin_care_solutions_single_page_content_alignment', 'left');
	if ($skin_care_solutions_single_page_content_alignment == 'left') {
	    $skin_care_solutions_custom_css .= '#single-page .type-page,section.theme-custom-block.theme-error-sectiontheme-error-section.error-block-middle,section.theme-custom-block.theme-error-section.error-block-heading .theme-area-header{';
	    $skin_care_solutions_custom_css .= 'text-align: left !important;';
	    $skin_care_solutions_custom_css .= '}';
	} else if ($skin_care_solutions_single_page_content_alignment == 'center') {
	    $skin_care_solutions_custom_css .= '#single-page .type-page,section.theme-custom-block.theme-error-sectiontheme-error-section.error-block-middle,section.theme-custom-block.theme-error-section.error-block-heading .theme-area-header{';
	    $skin_care_solutions_custom_css .= 'text-align: center !important;';
	    $skin_care_solutions_custom_css .= '}';
	} else if ($skin_care_solutions_single_page_content_alignment == 'right') {
	    $skin_care_solutions_custom_css .= '#single-page .type-page,section.theme-custom-block.theme-error-sectiontheme-error-section.error-block-middle,section.theme-custom-block.theme-error-section.error-block-heading .theme-area-header{';
	    $skin_care_solutions_custom_css .= 'text-align: right !important;';
	    $skin_care_solutions_custom_css .= '}';
	}

	$skin_care_solutions_single_post_content_alignment = get_theme_mod('skin_care_solutions_single_post_content_alignment', 'left');
	if ($skin_care_solutions_single_post_content_alignment == 'left') {
	    $skin_care_solutions_custom_css .= '#single-page .type-post,#single-page .type-post .entry-meta,#single-page .type-post .is-layout-flex{';
	    $skin_care_solutions_custom_css .= 'text-align: left !important;justify-content: left;';
	    $skin_care_solutions_custom_css .= '}';
	} else if ($skin_care_solutions_single_post_content_alignment == 'center') {
	    $skin_care_solutions_custom_css .= '#single-page .type-post,#single-page .type-post .entry-meta,#single-page .type-post .is-layout-flex{';
	    $skin_care_solutions_custom_css .= 'text-align: center !important;justify-content: center;';
	    $skin_care_solutions_custom_css .= '}';
	} else if ($skin_care_solutions_single_post_content_alignment == 'right') {
	    $skin_care_solutions_custom_css .= '#single-page .type-post,#single-page .type-post .entry-meta,#single-page .type-post .is-layout-flex{';
	    $skin_care_solutions_custom_css .= 'text-align: right !important;justify-content: right;';
	    $skin_care_solutions_custom_css .= '}';
	}

	$skin_care_solutions_menu_text_transform = get_theme_mod('skin_care_solutions_menu_text_transform', 'Capitalize');
	if ($skin_care_solutions_menu_text_transform == 'Capitalize') {
	    $skin_care_solutions_custom_css .= '.site-navigation .primary-menu > li a{';
	    $skin_care_solutions_custom_css .= 'text-transform: Capitalize !important;';
	    $skin_care_solutions_custom_css .= '}';
	} else if ($skin_care_solutions_menu_text_transform == 'uppercase') {
	    $skin_care_solutions_custom_css .= '.site-navigation .primary-menu > li a{';
	    $skin_care_solutions_custom_css .= 'text-transform: uppercase !important;';
	    $skin_care_solutions_custom_css .= '}';
	} else if ($skin_care_solutions_menu_text_transform == 'lowercase') {
	    $skin_care_solutions_custom_css .= '.site-navigation .primary-menu > li a{';
	    $skin_care_solutions_custom_css .= 'text-transform: lowercase !important;';
	    $skin_care_solutions_custom_css .= '}';
	}

	$skin_care_solutions_footer_widget_title_alignment = get_theme_mod('skin_care_solutions_footer_widget_title_alignment', 'left');
	if ($skin_care_solutions_footer_widget_title_alignment == 'left') {
	    $skin_care_solutions_custom_css .= 'h2.widget-title{';
	    $skin_care_solutions_custom_css .= 'text-align: left !important;';
	    $skin_care_solutions_custom_css .= '}';
	} else if ($skin_care_solutions_footer_widget_title_alignment == 'center') {
	    $skin_care_solutions_custom_css .= 'h2.widget-title{';
	    $skin_care_solutions_custom_css .= 'text-align: center !important;';
	    $skin_care_solutions_custom_css .= '}';
	} else if ($skin_care_solutions_footer_widget_title_alignment == 'right') {
	    $skin_care_solutions_custom_css .= 'h2.widget-title{';
	    $skin_care_solutions_custom_css .= 'text-align: right !important;';
	    $skin_care_solutions_custom_css .= '}';
	}

    $skin_care_solutions_show_hide_related_product = get_theme_mod('skin_care_solutions_show_hide_related_product',true);
    if($skin_care_solutions_show_hide_related_product != true){
        $skin_care_solutions_custom_css .='.related.products{';
            $skin_care_solutions_custom_css .='display: none;';
        $skin_care_solutions_custom_css .='}';
    }

	$skin_care_solutions_sticky_sidebar = get_theme_mod('skin_care_solutions_sticky_sidebar',true);
    if($skin_care_solutions_sticky_sidebar != true){
        $skin_care_solutions_custom_css .='.widget-area-wrapper{';
            $skin_care_solutions_custom_css .='position: relative !important;';
        $skin_care_solutions_custom_css .='}';
    }

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

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

	if ($skin_care_solutions_global_color) {
		$skin_care_solutions_custom_css .= ':root {';
		$skin_care_solutions_custom_css .= '--global-color: ' . esc_attr($skin_care_solutions_global_color) . ';';
		$skin_care_solutions_custom_css .= '}';
	}	

	/*-------------------- Content Font -------------------*/

	$skin_care_solutions_content_typography_font = get_theme_mod('skin_care_solutions_content_typography_font', 'Inter'); // Add a fallback if the color isn't set

	if ($skin_care_solutions_content_typography_font) {
		$skin_care_solutions_custom_css .= ':root {';
		$skin_care_solutions_custom_css .= '--font-main: ' . esc_attr($skin_care_solutions_content_typography_font) . ';';
		$skin_care_solutions_custom_css .= '}';
	}

	/*-------------------- Heading Font -------------------*/

	$skin_care_solutions_heading_typography_font = get_theme_mod('skin_care_solutions_heading_typography_font', 'playfair-display'); // Add a fallback if the color isn't set

	if ($skin_care_solutions_heading_typography_font) {
		$skin_care_solutions_custom_css .= ':root {';
		$skin_care_solutions_custom_css .= '--font-head: ' . esc_attr($skin_care_solutions_heading_typography_font) . ';';
		$skin_care_solutions_custom_css .= '}';
	}

	$skin_care_solutions_columns = get_theme_mod('skin_care_solutions_posts_per_columns', 3);
	$skin_care_solutions_columns = absint($skin_care_solutions_columns);
	if ( $skin_care_solutions_columns < 1 || $skin_care_solutions_columns > 6 ) {
		$skin_care_solutions_columns = 3;
	}
	$skin_care_solutions_custom_css .= "
		.site-content .article-wraper-archive {
			grid-template-columns: repeat({$skin_care_solutions_columns}, 1fr);
		}
	";

	$skin_care_solutions_copyright_alignment = get_theme_mod( 'skin_care_solutions_copyright_alignment', 'Default' );
	if ( $skin_care_solutions_copyright_alignment === 'Reverse' ) {
		$skin_care_solutions_custom_css .= '.site-info .column-row { flex-direction: row-reverse; }';
		$skin_care_solutions_custom_css .= '.footer-credits { justify-content: flex-end; }';
		$skin_care_solutions_custom_css .= '.footer-copyright { text-align: right; }';
		$skin_care_solutions_custom_css .= '.site-info .column.column-3 { text-align: left; }';
	} elseif ( $skin_care_solutions_copyright_alignment === 'Center' ) {
		$skin_care_solutions_custom_css .= '.site-info .column-row { flex-direction: column; align-items: center; gap: 15px; }';
		$skin_care_solutions_custom_css .= '.footer-credits { justify-content: center; }';
		$skin_care_solutions_custom_css .= '.footer-copyright { text-align: center; }';
		$skin_care_solutions_custom_css .= '.site-info .column.column-3 { text-align: center; }';
	}

	$skin_care_solutions_footer_widget_background_color = get_theme_mod('skin_care_solutions_footer_widget_background_color');
	if ($skin_care_solutions_footer_widget_background_color) {

		$skin_care_solutions_custom_css .= "
			.footer-widgetarea {
				background-color: ". esc_attr($skin_care_solutions_footer_widget_background_color) .";
			}
		";
	}

	$skin_care_solutions_footer_widget_background_image = get_theme_mod('skin_care_solutions_footer_widget_background_image');
	if ($skin_care_solutions_footer_widget_background_image) {
		$skin_care_solutions_custom_css .= "
			.footer-widgetarea {
				background-image: url(" . esc_url($skin_care_solutions_footer_widget_background_image) . ");
			}
		";
	}

	$skin_care_solutions_copyright_font_size = get_theme_mod('skin_care_solutions_copyright_font_size');
	if ($skin_care_solutions_copyright_font_size) {

		$skin_care_solutions_custom_css .= "
			.footer-copyright {
				font-size: ". esc_attr($skin_care_solutions_copyright_font_size) ."px;
			}
		";
	}

	/*-------------------- Menu Color CSS -------------------*/

	$skin_care_solutions_header_menus_color = get_theme_mod('skin_care_solutions_header_menus_color');
	if($skin_care_solutions_header_menus_color != false){
		$skin_care_solutions_custom_css .='.site-navigation .primary-menu a{';
			$skin_care_solutions_custom_css .='color: '.esc_attr($skin_care_solutions_header_menus_color).'!important;';
		$skin_care_solutions_custom_css .='}';
	}

	$skin_care_solutions_header_menus_hover_color = get_theme_mod('skin_care_solutions_header_menus_hover_color');
	if($skin_care_solutions_header_menus_hover_color != false){
		$skin_care_solutions_custom_css .='.site-navigation .primary-menu a:hover{';
			$skin_care_solutions_custom_css .='color: '.esc_attr($skin_care_solutions_header_menus_hover_color).'!important;';
		$skin_care_solutions_custom_css .='}';
	}

	$skin_care_solutions_header_submenus_color = get_theme_mod('skin_care_solutions_header_submenus_color');
	if($skin_care_solutions_header_submenus_color != false){
		$skin_care_solutions_custom_css .='.site-navigation .primary-menu ul.sub-menu li a,.site-navigation .primary-menu li ul li a{';
			$skin_care_solutions_custom_css .='color: '.esc_attr($skin_care_solutions_header_submenus_color).'!important;';
		$skin_care_solutions_custom_css .='}';
	}

	$skin_care_solutions_header_submenus_hover_color = get_theme_mod('skin_care_solutions_header_submenus_hover_color');
	if($skin_care_solutions_header_submenus_hover_color != false){
		$skin_care_solutions_custom_css .='.site-navigation .primary-menu > li ul.sub-menu a:hover,.site-navigation .primary-menu li ul li a:hover{';
			$skin_care_solutions_custom_css .='color: '.esc_attr($skin_care_solutions_header_submenus_hover_color).'!important;';
		$skin_care_solutions_custom_css .='}';
	}