<?php

    $automobile_detailing_shop_theme_css= "";

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

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

    /*------------------ Nav Menus -------------------*/

    $automobile_detailing_shop_nav_menu = get_theme_mod( 'automobile_detailing_shop_nav_menu_text_transform','Capitalize');
    if($automobile_detailing_shop_nav_menu == 'Capitalize'){
        $automobile_detailing_shop_theme_css .='.site-navigation .primary-menu > li a{';
            $automobile_detailing_shop_theme_css .='text-transform:Capitalize;';
        $automobile_detailing_shop_theme_css .='}';
    }
    if($automobile_detailing_shop_nav_menu == 'Lowercase'){
        $automobile_detailing_shop_theme_css .='.site-navigation .primary-menu > li a{';
            $automobile_detailing_shop_theme_css .='text-transform:Lowercase;';
        $automobile_detailing_shop_theme_css .='}';
    }
    if($automobile_detailing_shop_nav_menu == 'Uppercase'){
        $automobile_detailing_shop_theme_css .='.site-navigation .primary-menu > li a{';
            $automobile_detailing_shop_theme_css .='text-transform:Uppercase;';
        $automobile_detailing_shop_theme_css .='}';
    }

    $automobile_detailing_shop_menu_font_size = get_theme_mod( 'automobile_detailing_shop_menu_font_size');
    if($automobile_detailing_shop_menu_font_size != ''){
        $automobile_detailing_shop_theme_css .='.site-navigation .primary-menu > li a{';
            $automobile_detailing_shop_theme_css .='font-size: '.esc_attr($automobile_detailing_shop_menu_font_size).'px;';
        $automobile_detailing_shop_theme_css .='}';
    }

    $automobile_detailing_shop_nav_menu_font_weight = get_theme_mod( 'automobile_detailing_shop_nav_menu_font_weight',400);
    if($automobile_detailing_shop_menu_font_size != ''){
        $automobile_detailing_shop_theme_css .='.site-navigation .primary-menu > li a{';
            $automobile_detailing_shop_theme_css .='font-weight: '.esc_attr($automobile_detailing_shop_nav_menu_font_weight).';';
        $automobile_detailing_shop_theme_css .='}';
    }

    /*--------------------------- Footer Widget Heading Alignment -------------------*/

    $automobile_detailing_shop_footer_widget_heading_alignment = get_theme_mod( 'automobile_detailing_shop_footer_widget_heading_alignment','Left');
    if($automobile_detailing_shop_footer_widget_heading_alignment == 'Left'){
        $automobile_detailing_shop_theme_css .='#colophon h5, h5.footer-column-widget-title{';
        $automobile_detailing_shop_theme_css .='text-align: left;';
        $automobile_detailing_shop_theme_css .='}';
    }else if($automobile_detailing_shop_footer_widget_heading_alignment == 'Center'){
        $automobile_detailing_shop_theme_css .='#colophon h5, h5.footer-column-widget-title{';
            $automobile_detailing_shop_theme_css .='text-align: center;';
        $automobile_detailing_shop_theme_css .='}';
    }else if($automobile_detailing_shop_footer_widget_heading_alignment == 'Right'){
        $automobile_detailing_shop_theme_css .='#colophon h5, h5.footer-column-widget-title{';
            $automobile_detailing_shop_theme_css .='text-align: right;';
        $automobile_detailing_shop_theme_css .='}';
    }

    /*--------------------------- Footer Widget Content Alignment -------------------*/

    $automobile_detailing_shop_footer_widget_content_alignment = get_theme_mod( 'automobile_detailing_shop_footer_widget_content_alignment','Left');
    if($automobile_detailing_shop_footer_widget_content_alignment == 'Left'){
        $automobile_detailing_shop_theme_css .='#colophon ul, #colophon p, .tagcloud, .widget{';
        $automobile_detailing_shop_theme_css .='text-align: left;';
        $automobile_detailing_shop_theme_css .='}';
    }else if($automobile_detailing_shop_footer_widget_content_alignment == 'Center'){
        $automobile_detailing_shop_theme_css .='#colophon ul, #colophon p, .tagcloud, .widget{';
            $automobile_detailing_shop_theme_css .='text-align: center;';
        $automobile_detailing_shop_theme_css .='}';
    }else if($automobile_detailing_shop_footer_widget_content_alignment == 'Right'){
        $automobile_detailing_shop_theme_css .='#colophon ul, #colophon p, .tagcloud, .widget{';
            $automobile_detailing_shop_theme_css .='text-align: right;';
        $automobile_detailing_shop_theme_css .='}';
    }

    /*--------------------------- Copyright Content Alignment -------------------*/

    $automobile_detailing_shop_copyright_content_alignment = get_theme_mod( 'automobile_detailing_shop_copyright_content_alignment','Center');
    if($automobile_detailing_shop_copyright_content_alignment == 'Left'){
        $automobile_detailing_shop_theme_css .='.footer-menu-left{';
        $automobile_detailing_shop_theme_css .='text-align: left !important;';
        $automobile_detailing_shop_theme_css .='}';
    }else if($automobile_detailing_shop_copyright_content_alignment == 'Center'){
        $automobile_detailing_shop_theme_css .='.footer-menu-left{';
            $automobile_detailing_shop_theme_css .='text-align: center !important;';
        $automobile_detailing_shop_theme_css .='}';
    }else if($automobile_detailing_shop_copyright_content_alignment == 'Right'){
        $automobile_detailing_shop_theme_css .='.footer-menu-left{';
            $automobile_detailing_shop_theme_css .='text-align: right !important;';
        $automobile_detailing_shop_theme_css .='}';
    }

    /*---------------------------Width Layout -------------------*/

    $automobile_detailing_shop_width_option = get_theme_mod( 'automobile_detailing_shop_width_option','Full Width');
    if($automobile_detailing_shop_width_option == 'Boxed Width'){
        $automobile_detailing_shop_theme_css .='body{';
            $automobile_detailing_shop_theme_css .='max-width: 1140px; width: 100%; padding-right: 15px; padding-left: 15px; margin-right: auto; margin-left: auto;';
        $automobile_detailing_shop_theme_css .='}';
        $automobile_detailing_shop_theme_css .='.scrollup i{';
            $automobile_detailing_shop_theme_css .='right: 100px;';
        $automobile_detailing_shop_theme_css .='}';
        $automobile_detailing_shop_theme_css .='.page-template-custom-home-page .home-page-header{';
            $automobile_detailing_shop_theme_css .='padding: 0px 40px 0 10px;';
        $automobile_detailing_shop_theme_css .='}';
    }else if($automobile_detailing_shop_width_option == 'Wide Width'){
        $automobile_detailing_shop_theme_css .='body{';
            $automobile_detailing_shop_theme_css .='width: 100%;padding-right: 15px;padding-left: 15px;margin-right: auto;margin-left: auto;';
        $automobile_detailing_shop_theme_css .='}';
        $automobile_detailing_shop_theme_css .='.scrollup i{';
            $automobile_detailing_shop_theme_css .='right: 30px;';
        $automobile_detailing_shop_theme_css .='}';
    }else if($automobile_detailing_shop_width_option == 'Full Width'){
        $automobile_detailing_shop_theme_css .='body{';
            $automobile_detailing_shop_theme_css .='max-width: 100%;';
        $automobile_detailing_shop_theme_css .='}';
    }

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

    $automobile_detailing_shop_first_color = get_theme_mod('automobile_detailing_shop_first_color');

    if ($automobile_detailing_shop_first_color) {
        $automobile_detailing_shop_theme_css .= ':root {';
        $automobile_detailing_shop_theme_css .= '--first-color: ' . esc_attr($automobile_detailing_shop_first_color) . ' !important;';
        $automobile_detailing_shop_theme_css .= '} ';
    }

    /*-------------------- Heading typography -------------------*/

    $automobile_detailing_shop_heading_color = get_theme_mod('automobile_detailing_shop_heading_color');
    $automobile_detailing_shop_heading_font_family = get_theme_mod('automobile_detailing_shop_heading_font_family');
    $automobile_detailing_shop_heading_font_size = get_theme_mod('automobile_detailing_shop_heading_font_size');
    if($automobile_detailing_shop_heading_color != false || $automobile_detailing_shop_heading_font_family != false || $automobile_detailing_shop_heading_font_size != false){
        $automobile_detailing_shop_theme_css .='h1, h2, h3, h4, h5, h6, .navbar-brand h1.site-title, h2.entry-title, h1.entry-title, h2.page-title, #latest_post h2, h2.woocommerce-loop-product__title, #top-slider .slider-inner-box h3, .featured h3.main-heading, .article-box h3.entry-title, .featured h4.main-heading, #colophon h5, .sidebar h5{';
            $automobile_detailing_shop_theme_css .='color: '.esc_attr($automobile_detailing_shop_heading_color).'!important; 
            font-family: '.esc_attr($automobile_detailing_shop_heading_font_family).'!important;
            font-size: '.esc_attr($automobile_detailing_shop_heading_font_size).'px !important;';
        $automobile_detailing_shop_theme_css .='}';
    }

    $automobile_detailing_shop_paragraph_color = get_theme_mod('automobile_detailing_shop_paragraph_color');
    $automobile_detailing_shop_paragraph_font_family = get_theme_mod('automobile_detailing_shop_paragraph_font_family');
    $automobile_detailing_shop_paragraph_font_size = get_theme_mod('automobile_detailing_shop_paragraph_font_size');
    if($automobile_detailing_shop_paragraph_color != false || $automobile_detailing_shop_paragraph_font_family != false || $automobile_detailing_shop_paragraph_font_size != false){
        $automobile_detailing_shop_theme_css .='p, p.site-title, span, .article-box p, ul, li{';
            $automobile_detailing_shop_theme_css .='color: '.esc_attr($automobile_detailing_shop_paragraph_color).'!important; 
            font-family: '.esc_attr($automobile_detailing_shop_paragraph_font_family).'!important;
            font-size: '.esc_attr($automobile_detailing_shop_paragraph_font_size).'px !important;';
        $automobile_detailing_shop_theme_css .='}';
    }

    /*---------------- Logo CSS ----------------------*/
    $automobile_detailing_shop_logo_title_font_size = get_theme_mod( 'automobile_detailing_shop_logo_title_font_size');
    $automobile_detailing_shop_logo_tagline_font_size = get_theme_mod( 'automobile_detailing_shop_logo_tagline_font_size');
    if( $automobile_detailing_shop_logo_title_font_size != '') {
        $automobile_detailing_shop_theme_css .='#masthead .navbar-brand a{';
            $automobile_detailing_shop_theme_css .='font-size: '. $automobile_detailing_shop_logo_title_font_size. 'px;';
        $automobile_detailing_shop_theme_css .='}';
    }
    if( $automobile_detailing_shop_logo_tagline_font_size != '') {
        $automobile_detailing_shop_theme_css .='#masthead .navbar-brand p{';
            $automobile_detailing_shop_theme_css .='font-size: '. $automobile_detailing_shop_logo_tagline_font_size. 'px;';
        $automobile_detailing_shop_theme_css .='}';
    }