<?php 
/**
	 * Global Layout
	 */
	// Global Layout
	$wp_customize->add_section(
		'nuevo_blog_global_layout',
		array(
			'title' => esc_html__( 'Global Layout', 'nuevo-blog' ),
			'panel' => 'nuevo_blog_general_panel',
		)
	);

	// Global site layout setting
	$wp_customize->add_setting(
		'nuevo_blog_site_layout',
		array(
			'sanitize_callback' => 'nuevo_blog_sanitize_select',
			'default' => 'wide',
			'transport'	=> 'postMessage',
		)
	);

	$wp_customize->add_control(
		'nuevo_blog_site_layout',
		array(
			'section'		=> 'nuevo_blog_global_layout',
			'label'			=> esc_html__( 'Site layout', 'nuevo-blog' ),
			'type'			=> 'radio',
			'choices'		=> array( 
				'boxed' => esc_html__( 'Boxed', 'nuevo-blog' ), 
				'wide' => esc_html__( 'Wide', 'nuevo-blog' ), 
			),
		)
	);

	// Global archive layout setting
	$wp_customize->add_setting(
		'nuevo_blog_archive_sidebar',
		array(
			'sanitize_callback' => 'nuevo_blog_sanitize_select',
			'default' => 'right',
		)
	);

	$wp_customize->add_control(
		'nuevo_blog_archive_sidebar',
		array(
			'section'		=> 'nuevo_blog_global_layout',
			'label'			=> esc_html__( 'Archive Sidebar', 'nuevo-blog' ),
			'description'			=> esc_html__( 'This option works on all archive pages like: 404, search, date, category and so on.', 'nuevo-blog' ),
			'type'			=> 'radio',
			'choices'		=> array( 
				'left' => esc_html__( 'Left', 'nuevo-blog' ), 
				'right' => esc_html__( 'Right', 'nuevo-blog' ), 
				'no' => esc_html__( 'No Sidebar', 'nuevo-blog' ), 
			),
		)
	);

	// Blog layout setting
	$wp_customize->add_setting(
		'nuevo_blog_blog_sidebar',
		array(
			'sanitize_callback' => 'nuevo_blog_sanitize_select',
			'default' => 'no',
		)
	);

	$wp_customize->add_control(
		'nuevo_blog_blog_sidebar',
		array(
			'section'		=> 'nuevo_blog_global_layout',
			'label'			=> esc_html__( 'Blog Sidebar', 'nuevo-blog' ),
			'description'			=> esc_html__( 'This option works on blog and "Your latest posts"', 'nuevo-blog' ),
			'type'			=> 'radio',
			'choices'		=> array( 
				'left' => esc_html__( 'Left', 'nuevo-blog' ), 
				'right' => esc_html__( 'Right', 'nuevo-blog' ), 
				'no' => esc_html__( 'No Sidebar', 'nuevo-blog' ), 
			),
		)
	);

	// Global page layout setting
	$wp_customize->add_setting(
		'nuevo_blog_global_page_layout',
		array(
			'sanitize_callback' => 'nuevo_blog_sanitize_select',
			'default' => 'right',
		)
	);

	$wp_customize->add_control(
		'nuevo_blog_global_page_layout',
		array(
			'section'		=> 'nuevo_blog_global_layout',
			'label'			=> esc_html__( 'Global page sidebar', 'nuevo-blog' ),
			'description'			=> esc_html__( 'This option works only on single pages including "Posts page". This setting can be overridden for single page from the metabox too.', 'nuevo-blog' ),
			'type'			=> 'radio',
			'choices'		=> array( 
				'left' => esc_html__( 'Left', 'nuevo-blog' ),  
				'right' => esc_html__( 'Right', 'nuevo-blog' ), 
				'no' => esc_html__( 'No Sidebar', 'nuevo-blog' ), 
			),
		)
	);

	// Global post layout setting
	$wp_customize->add_setting(
		'nuevo_blog_global_post_layout',
		array(
			'sanitize_callback' => 'nuevo_blog_sanitize_select',
			'default' => 'right',
		)
	);

	$wp_customize->add_control(
		'nuevo_blog_global_post_layout',
		array(
			'section'		=> 'nuevo_blog_global_layout',
			'label'			=> esc_html__( 'Global post sidebar', 'nuevo-blog' ),
			'description'			=> esc_html__( 'This option works only on single posts. This setting can be overridden for single post from the metabox too.', 'nuevo-blog' ),
			'type'			=> 'radio',
			'choices'		=> array( 
				'left' => esc_html__( 'Left', 'nuevo-blog' ), 
				'right' => esc_html__( 'Right', 'nuevo-blog' ), 
				'no' => esc_html__( 'No Sidebar', 'nuevo-blog' ), 
			),
		)
	);
 ?>