<?php
/**
 * Body Classes.
 * @package Trucking Company
 */

if (!function_exists('trucking_company_body_classes')) :

    function trucking_company_body_classes($trucking_company_classes)
    {
        $trucking_company_defaults = trucking_company_get_default_theme_options();
        $trucking_company_layout = trucking_company_get_final_sidebar_layout();

        // Adds a class of hfeed to non-singular pages.
        if (!is_singular()) {
            $trucking_company_classes[] = 'hfeed';
        }

        // Sidebar layout logic
        $trucking_company_classes[] = $trucking_company_layout;

        // Copyright alignment
        $copyright_alignment = get_theme_mod('trucking_company_copyright_alignment', 'Default');
        $trucking_company_classes[] = 'copyright-' . strtolower($copyright_alignment);

        return $trucking_company_classes;
    }

endif;

add_filter('body_class', 'trucking_company_body_classes');