<?php
$wp_customize->add_section(
    'features_area',
    array(
        'title' => __('Features Section', 'luzuk-premium' ),
        'panel' => 'luzuk_premium_home_panel'
    )
);
$wp_customize->add_setting(
    'features_area_disable',
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
    )
);
$wp_customize->add_control(
    new luzuk_Switch_Control(
        $wp_customize,
        'features_area_disable',
        array(
            'settings'      => 'features_area_disable',
            'section'       => 'features_area',
            'label'         => __( 'Disable Section', 'luzuk-premium' ),
            'on_off_label'  => array(
                'on' => __( 'Yes', 'luzuk-premium' ),
                'off' => __( 'No', 'luzuk-premium' )
            ),
        )
    )
);

lzCustomLable($wp_customize, 'featuresarea_padding', 'features_area', 'Set Section Padding:');

$wp_customize->add_setting(
    'features_areaTpadding',
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
        'default'           => __( '5em', 'luzuk-premium' )
    )
);
$wp_customize->add_control(
    'features_areaTpadding',
    array(
        'settings'      => 'features_areaTpadding',
        'section'       => 'features_area',
        'type'          => 'text',
        'label'         => __( 'Top Padding', 'luzuk-premium' )
    )
);
$wp_customize->add_setting(
    'features_areaBpadding',
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
        'default'           => __( '0em', 'luzuk-premium' )
    )
);
$wp_customize->add_control(
    'features_areaBpadding',
    array(
        'settings'      => 'features_areaBpadding',
        'section'       => 'features_area',
        'type'          => 'text',
        'label'         => __( 'Bottom Padding', 'luzuk-premium' )
    )
);

$wp_customize->add_setting(
    'features_areaLpadding',
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
        'default'           => __( '0px', 'luzuk-premium' )
    )
);
$wp_customize->add_control(
    'features_areaLpadding',
    array(
        'settings'      => 'features_areaLpadding',
        'section'       => 'features_area',
        'type'          => 'text',
        'label'         => __( 'Left Padding', 'luzuk-premium' )
    )
);
$wp_customize->add_setting(
    'features_areaRpadding',
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
        'default'           => __( '0px', 'luzuk-premium' )
    )
);
$wp_customize->add_control(
    'features_areaRpadding',
    array(
        'settings'      => 'features_areaRpadding',
        'section'       => 'features_area',
        'type'          => 'text',
        'label'         => __( 'Right Padding', 'luzuk-premium' )
    )
);


lzCustomLable($wp_customize, 'features_area_overlayop', 'features_area', 'Set Section Background Color:');

addColorPalatOption($wp_customize, 'featuresareasecbgOneColor', 'features_area', 'Background Color One ', '#8972ea');
addColorPalatOption($wp_customize, 'featuresareasecbgTwOColor', 'features_area', 'Background Color Two ', '#516ced');



backgroundManager($wp_customize, 'features', 'features_area', $color='#fff', get_template_directory_uri().'/images/default-gray.png', 'img');

$wp_customize->add_setting(
    'features_page_maintitle_heading',
    array(
        'sanitize_callback' => 'luzuk_sanitize_text'
    )
);
$wp_customize->add_control(
    new luzuk_Customize_Heading(
        $wp_customize,
        'features_page_maintitle_heading',
        array(
            'settings'      => 'features_page_maintitle_heading',
            'section'       => 'features_area',
            'label'         => __( 'Section Title', 'luzuk-premium' ),
        )
    )
);    
$wp_customize->add_setting(
    'features_page_maintitle',
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
        'default'           => __( 'Our Features', 'luzuk-premium' )
    )
);
$wp_customize->add_control(
    'features_page_maintitle',
    array(
        'settings'      => 'features_page_maintitle',
        'section'       => 'features_area',
        'type'          => 'text',
        'label'         => __( 'Heading for section', 'luzuk-premium' )
    )
);

addColorPalatOption($wp_customize, 'featuresarea_title_color', 'features_area', 'Heading color', '#ffffff');

addColorPalatOption($wp_customize, 'features_page_titleBorderColor', 'features_area', 'Heading Border color', '#ffffff');


$wp_customize->add_setting('features_area_lbl', array('sanitize_callback'=>'luzuk_sanitize_text'));
$wp_customize->add_control(
    new luzuk_Info_Text( 
        $wp_customize,
        'features_area_lbl',
        array(
            'settings'      => 'features_area_lbl',
            'section'       => 'features_area',
            'label'         => __( 'Note1:', 'Luzuk' ),  
            'description'   => __( 'Changes will not reflect unless you select an image for page', 'Luzuk' ),
        )
    )
);

$wp_customize->add_setting('features_area_lbl2', array('sanitize_callback'=>'luzuk_sanitize_text'));
$wp_customize->add_control(
    new luzuk_Info_Text( 
        $wp_customize,
        'features_area_lbl2',
        array(
            'settings'      => 'features_area_lbl2',
            'section'       => 'features_area',
            'label'         => __( 'Note2:', 'Luzuk' ),  
            'description'   => __( 'Kindly use images of same resolution, Recommended Image Size of height 100px', 'Luzuk' ),
        )
    )
);

$wp_customize->add_setting('features_npp_heading',array('sanitize_callback' => 'luzuk_sanitize_text'));
$wp_customize->add_control(
    new luzuk_Customize_Heading(
        $wp_customize,
        'features_npp_heading',
        array(
            'settings'      => 'features_npp_heading',
            'section'       => 'features_area',
            'label'         => __( 'Number Of Plans', 'luzuk-premium' ),
        )
    )
);    
$wp_customize->add_setting('features_npp_count',array('sanitize_callback' => 'luzuk_sanitize_text','default' => 3));
$wp_customize->add_control(
    'features_npp_count',
    array(
        'settings'      => 'features_npp_count',
        'section'       => 'features_area',
        'type'          => 'select',
        'label'         => __( 'Number of plan to show', 'luzuk-premium' ),
        'choices'=>array(1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16)
    )
);
for( $i = 1; $i <= 16; $i++ ){
    $wp_customize->add_setting(
        'features_header'.$i,
        array(
            'sanitize_callback' => 'luzuk_sanitize_text'
        )
    );
    $wp_customize->add_control(
        new luzuk_Customize_Heading(
            $wp_customize,
            'features_header'.$i,
            array(
                'settings'      => 'features_header'.$i,
                'section'       => 'features_area',
                'label'         => __( 'Page ', 'luzuk-premium' ).$i
            )
        )
    );
    lzAddImageElement($wp_customize, 'features_page_icon'.$i, 'features_area', $label="Recommended Image Size: 100X100px");

    lzAddElement($wp_customize, 'features_page_title_'.$i, 'features_area', $type = 'text', $label="Title", $callback ='luzuk_sanitize_text', $default='Design & Coding');

    lzAddElement($wp_customize, 'features_page_descr_'.$i, 'features_area', $type = 'textarea', $label="Content", $callback ='luzuk_sanitize_text', $default='Lorem ipsumst dolors consectetur adipisicing sed does');
    lzAddElement($wp_customize, 'features_page_url_'.$i, 'features_area', $type = 'text', $label="Link", $callback ='esc_url', $default='Add link here');
}

   addColorPalatOption($wp_customize, 'featuresarea_BoxiconColor', 'features_area', 'Page Image Hover Icon Color', '#fff');
     addColorPalatOption($wp_customize, 'featuresarea_BoxiconbgColor', 'features_area', 'Page Image Hover Icon Background Color', '#f72985');

    addColorPalatOption($wp_customize, 'featuresarea_BoxttlColor', 'features_area', 'Page Title Color', '#3c3c3c');
    addColorPalatOption($wp_customize, 'featuresarea_BoxtextColor', 'features_area', 'Page Content Color', '#666666');
    
        addColorPalatOption($wp_customize, 'featuresarea_BoxttlhoverColor', 'features_area', 'Page Title Hover Color', '#fff');
    addColorPalatOption($wp_customize, 'featuresarea_BoxtexthoverColor', 'features_area', 'Page Content Hover Color', '#fff');

    addColorPalatOption($wp_customize, 'featuresarea_boxbgOneColor', 'features_area', 'Box Hover Color One ', '#8972ea');
addColorPalatOption($wp_customize, 'featuresarea_boxbgTwOColor', 'features_area', 'Box Hover Color Two ', '#516ced');