<?php
/**
 * Body Classes.
 * @package Board Games
 */

if (!function_exists('board_games_body_classes')) :

    function board_games_body_classes($board_games_classes)
    {
        $board_games_defaults = board_games_get_default_theme_options();
        $board_games_layout = board_games_get_final_sidebar_layout();

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

        // Sidebar layout logic
        $board_games_classes[] = $board_games_layout;

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

        return $board_games_classes;
    }

endif;

add_filter('body_class', 'board_games_body_classes');