<?php

$wp_customize->add_panel(
    'luzuk_general_panel',
    array(
        'priority' => 19,
        'title' => __('General Configuration', 'Luzuk Premium')
    )
);

//STATIC FRONT PAGE
$wp_customize->add_section( 'static_front_page', array(
    'title' => __( 'Static Front Page', 'Luzuk Premium' ),
    'panel' => 'luzuk_general_panel',
    'description' => __( 'Your theme supports a static front page.', 'Luzuk Premium'),
) );

//TITLE AND TAGLINE SETTINGS
$wp_customize->add_section( 'title_tagline', array(
    'title' => __( 'Site Logo/Title/Tagline', 'Luzuk Premium' ),
    'panel' => 'luzuk_general_panel',
) );

$wp_customize->add_setting(
    'pages_logoTopsetmaxwidth',
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
        'default'           => __( '100', 'luzuk-premium' )
    )
);
$wp_customize->add_control(
    'pages_logoTopsetmaxwidth',
    array(
        'settings'      => 'pages_logoTopsetmaxwidth',
        'section'       => 'title_tagline',
        'type'          => 'text',
        'label'         => __( 'Set Logo Max Width', 'luzuk-premium' )
    )
);

$wp_customize->add_setting(
    'pages_logoToppadding',
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
        'default'           => __( '0.5em', 'luzuk-premium' )
    )
);
$wp_customize->add_control(
    'pages_logoToppadding',
    array(
        'settings'      => 'pages_logoToppadding',
        'section'       => 'title_tagline',
        'type'          => 'text',
        'label'         => __( 'Set Logo Top Padding', 'luzuk-premium' )
    )
);
$wp_customize->add_setting(
    'pages_logobottompadding',
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
        'default'           => __( '0.5em', 'luzuk-premium' )
    )
);
$wp_customize->add_control(
    'pages_logobottompadding',
    array(
        'settings'      => 'pages_logobottompadding',
        'section'       => 'title_tagline',
        'type'          => 'text',
        'label'         => __( 'Set Logo Bottom Padding', 'luzuk-premium' )
    )
);



addColorPalatOption($wp_customize, 'header_SiteTitleColor', 'title_tagline', 'Site Title Color', '#fc9b70');
addColorPalatOption($wp_customize, 'header_SiteTaglineColor', 'title_tagline', 'Tagline Color', '#000');


//BACKGROUND IMAGE
$wp_customize->add_section( 'background_image', array(
    'title' => __( 'Background Image Setting', 'Luzuk Premium' ),
    'panel' => 'luzuk_general_panel',
) );

//Header IMAGE
$wp_customize->add_section( 'header_image', array(
    'title' => __( 'Header Image', 'Luzuk Premium' ),
    'panel' => 'luzuk_general_panel',
) );


//HEADER SETTINGS
$wp_customize->add_section(
    'header_settings',
    array(
        'title' => __( 'Header Settings', 'Luzuk Premium' ),
        'panel' => 'luzuk_general_panel',
    )
);

lzCustomLable($wp_customize, 'stickyheader_view', 'header_settings', 'Sticky Header Settings');
    //ENABLE/DISABLE STICKY HEADER
$wp_customize->add_setting(
    'luzuk_sticky_header_enable',
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
        'default' => 'off'
    )
);

$wp_customize->add_control(
    new luzuk_Switch_Control(
        $wp_customize,
        'luzuk_sticky_header_enable',
        array(
            'settings'      => 'luzuk_sticky_header_enable',
            'section'       => 'header_settings',
            'label'         => __( 'Sticky Header', 'Unboxthemes Premium' ),
            'on_off_label'  => array(
                'on' => __( 'Enable', 'luzuk-premium' ),
                'off' => __( 'Disable', 'luzuk-premium' )
            )   
        )
    )
);

$sectionHeader = 'header_settings';

lzCustomLable($wp_customize, 'header_bgColorssettings', $sectionHeader, 'Header Background Colors');

addColorPalatOption($wp_customize, 'header_completebgColor', 'header_settings', 'Navigation Bar Background Color', '#fff');

lzCustomLable($wp_customize, 'header_MenuColorssettings', $sectionHeader, 'Navigation Colors');

addColorPalatOption($wp_customize, 'header_topmenusColor', 'header_settings', 'Menus Color', '#000');
addColorPalatOption($wp_customize, 'header_topmenushoverColor', 'header_settings', 'Menus Hover Color', '#f27968');

addColorPalatOption($wp_customize, 'header_topmenushvbrdColor', 'header_settings', 'Menus Hover Border Color', '#f27968');

addColorPalatOption($wp_customize, 'header_topmenusactiveColor', 'header_settings', 'Active Menus Color', '#f27968');
addColorPalatOption($wp_customize, 'header_topsubmenusColor', 'header_settings', 'Header Sub Menus Color', '#000');
addColorPalatOption($wp_customize, 'header_topsubmenushvrColor', 'header_settings', 'Sub Menus Hover & Sub Menu Active Color', '#000');
addColorPalatOption($wp_customize, 'header_submenusbgssc1Color', 'header_settings', 'Dropdown Background Color One', '#fff');
addColorPalatOption($wp_customize, 'header_submenusbgssc2Color', 'header_settings', 'Dropdown Background Color Two', '#fff');


// Adding the Label
lzCustomLable($wp_customize, 'reservation_lblImgTxt', 'header_settings' , 'Header Button Setting');

$wp_customize->add_setting(
    'header_email',
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
        'default'           => __( 'info@gmail.com' )
    )
);
$wp_customize->add_control(
    'header_email',
    array(
        'settings'      => 'header_email',
        'section'       => 'header_settings',
        'type'          => 'text',
        'label'         => __( 'Email Id', 'Luzuk' )
    )
);


$wp_customize->add_setting(
    'header_phone',
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
        'default'           => __( '+926-3434-962' )
    )
);
$wp_customize->add_control(
    'header_phone',
    array(
        'settings'      => 'header_phone',
        'section'       => 'header_settings',
        'type'          => 'text',
        'label'         => __( 'Phone Number', 'Luzuk' )
    )
);


addColorPalatOption($wp_customize, 'headerbtn_numicnclr', 'header_settings', 'Header Email Text , Phone Number & Icon Color', '#000');

addColorPalatOption($wp_customize, 'headerbtn_numicnhvclr', 'header_settings', 'Header Email Text , Phone Number & Icon Hover Color', '#f27968');

addColorPalatOption($wp_customize, 'headerbtn_bghvclr', 'header_settings', 'Header Button Background Hover Color', '#000');

lzCustomLable($wp_customize, 'reservation_lblImgTxt', 'header_settings' , 'Social media icons');

// FACEBOOK 
$wp_customize->add_setting('header_fb', array('default'=> 'https://facebook.com', 'sanitize_callback' => 'esc_url_raw'));
$wp_customize->add_control('header_fb',
    array(
        'settings'      => 'header_fb',
        'section'       => 'header_settings',
        'type'          => 'url',
        'label'         => __( 'Facebook Url', 'luzuk-premium' )
    )
);

//Instagram
$wp_customize->add_setting('header_insta',array('default'=> 'https://www.instagram.com/','sanitize_callback' => 'esc_url_raw'));
$wp_customize->add_control('header_insta',
    array(
        'settings'      => 'header_insta',
        'section'       => 'header_settings',
        'type'          => 'url',
        'label'         => __( 'Instagram Url', 'luzuk-premium' )
    )
);

// TWITTER
$wp_customize->add_setting('header_tw', array('default'=> 'https://twitter.com', 'sanitize_callback' => 'esc_url_raw'));
$wp_customize->add_control('header_tw',
    array(
        'settings'      => 'header_tw',
        'section'       => 'header_settings',
        'type'          => 'url',
        'label'         => __( 'Twitter Url', 'luzuk-premium' )
    )
);

//linkedin
$wp_customize->add_setting('header_li',array('default'=> 'https://www.linkedin.com','sanitize_callback' => 'esc_url_raw'));
$wp_customize->add_control('header_li',
    array(
        'settings'      => 'header_li',
        'section'       => 'header_settings',
        'type'          => 'url',
        'label'         => __( 'Linkedin Url', 'luzuk-premium' )
    )
);

addColorPalatOption($wp_customize, 'header_socilicnclr', 'header_settings', 'Header Socila Icon Color', '#f27968');

addColorPalatOption($wp_customize, 'header_socilicnhvclr', 'header_settings', 'Header Socila Icon Hover Color', '#000');

lzCustomLable($wp_customize, 'header_colorsfortabandmobview', $sectionHeader, 'Responsive Header Settings');

addColorPalatOption($wp_customize, 'header_topsubgColor', 'header_settings', 'Top Header Background Color', '#cdc0c0');

addColorPalatOption($wp_customize, 'header_respnavtoggbarbgssColor', 'header_settings', 'Toggle Bar Color', '#000');

addColorPalatOption($wp_customize, 'header_respnavbsbgssColor', 'header_settings', ' Navigation Box BG Color', '#fff');

addColorPalatOption($wp_customize, 'header_navigationrespnavbrssColor', 'header_settings', 'Menus Title Color', '#000');

addColorPalatOption($wp_customize, 'header_navigationrespnavmenuttlbgColor', 'header_settings', 'Menus Title BG Color', '#d5d5d5');

addColorPalatOption($wp_customize, 'header_navigationrespnavmenuColor', 'header_settings', 'Menus Color', '#fff');

addColorPalatOption($wp_customize, 'header_navigationrespnavmenubgColor', 'header_settings', 'Menus BG Color', '#000');



// lzCustomLable($wp_customize, 'header_colorsfortabandmobview', $sectionHeader, 'Responsive Header Settings');

// addColorPalatOption($wp_customize, 'header_topsubgColor', 'header_settings', 'Top Header Background Color', '#cdc0c0');

// addColorPalatOption($wp_customize, 'header_topsubmenuiconColor', 'header_settings', 'Header Menus Dropdown Icon Color', '#000');

// addColorPalatOption($wp_customize, 'header_respnavtoggbarbgssColor', 'header_settings', 'Toggle Bar Color', '#000');

// addColorPalatOption($wp_customize, 'header_respnavbsbgssColor', 'header_settings', ' Navigation Box Background Color', '#f1f1f1');
// addColorPalatOption($wp_customize, 'header_navigationrespnavbrssColor', 'header_settings', 'Navigation Box Border Color', '#000');



//COLOR SETTINGS
$wp_customize->add_section( 'colors', array(
    'title' => __( 'Colors' , 'Luzuk Premium'),
    'panel' => 'luzuk_general_panel',
) );

    $wp_customize->add_setting('luzuk_premium_color_section_lbl', array('sanitize_callback'=>'luzuk_sanitize_text'));
$wp_customize->add_control(
    new luzuk_Info_Text( 
        $wp_customize,
        'luzuk_premium_color_section_lbl',
        array(
            'settings'      => 'luzuk_premium_color_section_lbl',
            'section'       => 'colors',
            'label'         => __( 'Note:', 'luzuk-premium' ),  
            'description'   => __( '<b>This section available only for PRO version</b><br>If you want this section click on <b>Go Pro</b>', 'luzuk-premium' ),
        )
    )
);



// //BREADCRUMB SETTINGS
// $wp_customize->add_section(
//     'luzuk_breadcrumb_settings',
//     array(
//         'title' => __( 'Breadcrumb Settings', 'Luzuk Premium' ),
//         'panel' => 'luzuk_general_panel',
//     )
// );

//for breadcrumb to show & hide button

// $wp_customize->add_setting( 'breadcrumb_button_display' , array( 'default' => true, 'transport' => 'refresh', ) ); 
// $wp_customize->add_control( 'breadcrumb_button_display', array( 'label' => 'Breadcrumb Display', 'section' => 'luzuk_breadcrumb_settings', 'settings' => 'breadcrumb_button_display', 'type' => 'radio', 'choices' => array( 'show' => 'Hide Breadcrumb', 'hide' => 'Show Breadcrumb', ), ) ); 

// $wp_customize->add_setting(
//         'luzuk_breadcrumbhometxt',
//         array(
//             'sanitize_callback' => 'luzuk_sanitize_text',
//             'default'           => __( 'Home', 'luzuk' )
//         )
//     );
//     $wp_customize->add_control(
//         'luzuk_breadcrumbhometxt',
//         array(
//             'settings'      => 'luzuk_breadcrumbhometxt',
//             'section'       => 'luzuk_breadcrumb_settings',
//             'type'          => 'text',
//             'label'         => __( 'Add Breadcrumb Text Here:', 'luzuk' )
//         )
//     );

// //Inner page breadcrumbbox title color
// addColorPalatOption($wp_customize, 'luzuk_template_innerpage_breadcrumbtitlecolor', 'luzuk_breadcrumb_settings', 'Inner page breadcrumb box title color', '#fff');
// //Inner page breadcrumbbox current title color


// // end to show & hide button

//POSTPAGEDATE SETTINGS
$wp_customize->add_section(
    'luzuk_blogpage_settings',
    array(
        'title' => __( 'Inner Blog Page Settings', 'Luzuk Premium' ),
        'panel' => 'luzuk_general_panel',
    )
);

    $wp_customize->add_setting('luzuk_premium_blog_section_lbl', array('sanitize_callback'=>'luzuk_sanitize_text'));
$wp_customize->add_control(
    new luzuk_Info_Text( 
        $wp_customize,
        'luzuk_premium_blog_section_lbl',
        array(
            'settings'      => 'luzuk_premium_blog_section_lbl',
            'section'       => 'luzuk_blogpage_settings',
            'label'         => __( 'Note:', 'luzuk-premium' ),  
            'description'   => __( '<b>This section available only for PRO version</b><br>If you want this section click on <b>Go Pro</b>', 'luzuk-premium' ),
        )
    )
);




//FOOTER COPYRIGHT SETTINGS
$wp_customize->add_section(
    'footer_area',
    array(
        'title' => __( 'Footer Settings', 'Luzuk Premium' ),
        'panel' => 'luzuk_general_panel',
    )
);

backgroundManager($wp_customize, 'footer', 'footer_area', $color='#fff', get_template_directory_uri().'/images/Footerbg.jpg', 'color');

lzCustomLable($wp_customize, 'footer_overlayop', 'footer_area', 'Section Box Overlay & Opacity settings:');

$wp_customize->add_setting(
'footer_overlay_color', array(
'default' => '#f7e7e5',
'sanitize_callback' => 'sanitize_hex_color',
)
);
$wp_customize->add_control(new WP_Customize_Color_Control($wp_customize,'footer_overlay_color',array(
'settings' => 'footer_overlay_color',
'section' => 'footer_area',
'label' => __( 'Apply Overlay Color', 'Luzuk' ),
'description' => __( 'The color used for the overlay in the banner.', 'luzuk-premium' ),
)
)
);

$wp_customize->add_setting(
'footer_template_overlay_opacity',
array(
'default' => 95,
'sanitize_callback' => 'absint',
'transport' => 'postMessage',
)
);

$wp_customize->add_control(
'footer_template_overlay_opacity',
array(
'label' => __( 'Overlay Opacity', 'luzuk-premium' ),
'description' => __( 'Make sure that the contrast is high enough so that the text is readable.', 'luzuk-premium' ),
'section' => 'footer_area',
'type' => 'range',
'input_attrs' => luzuk_customize_opacity_range(),
)
);

$wp_customize->selective_refresh->add_partial(
'footer_template_overlay_opacity',
array(
'selector' => '.cover-color-overlay',
'type' => 'cover_opacity',
)
);


lzCustomLable($wp_customize, 'footer_areaPadding', 'footer_area', 'Set Top Footer Padding:');

$wp_customize->add_setting(
    'sec_footerseTmargin', 
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
        'default'           => __( '3em', 'luzuk-premium' )
    )
);
$wp_customize->add_control(
    'sec_footerseTmargin',
    array(
        'settings'      => 'sec_footerseTmargin',
        'section'       => 'footer_area',
        'type'          => 'text',
        'label'         => __( 'Top Padding', 'luzuk-premium' )
    )
);
$wp_customize->add_setting(
    'sec_footersebottommargin',
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
        'default'           => __( '3em', 'luzuk-premium' )
    )
);
$wp_customize->add_control(
    'sec_footersebottommargin',
    array(
        'settings'      => 'sec_footersebottommargin',
        'section'       => 'footer_area',
        'type'          => 'text',
        'label'         => __( 'Bottom Padding', 'luzuk-premium' )
    )
);

lzCustomLable($wp_customize, 'footer_areabottomfPadding', 'footer_area', 'Set Bottom Footer Padding:');

$wp_customize->add_setting(
    'sec_bottomareaTmargin', 
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
        'default'           => __( '2em', 'luzuk-premium' )
    )
);
$wp_customize->add_control(
    'sec_bottomareaTmargin',
    array(
        'settings'      => 'sec_bottomareaTmargin',
        'section'       => 'footer_area',
        'type'          => 'text',
        'label'         => __( 'Top Padding', 'luzuk-premium' )
    )
);
$wp_customize->add_setting(
    'sec_bottomareabottommargin',
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
        'default'           => __( '2em', 'luzuk-premium' )
    )
);
$wp_customize->add_control(
    'sec_bottomareabottommargin',
    array(
        'settings'      => 'sec_bottomareabottommargin',
        'section'       => 'footer_area',
        'type'          => 'text',
        'label'         => __( 'Bottom Padding', 'luzuk-premium' )
    )
);

lzCustomLable($wp_customize, 'footer_copytext', 'footer_area', 'Footer Copyright Text:');

$wp_customize->add_setting(
    'footer_area_copyrighttext',
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
        'default'           => __( '© 2022 All Rights Reserved', 'Luzuk Premium' )
    )
);
$wp_customize->add_control(
    'footer_area_copyrighttext',
    array(
        'settings'      => 'footer_area_copyrighttext',
        'section'       => 'footer_area',
        'type'          => 'text',
        'label'         => __( 'Footer Copyright Text', 'Luzuk Premium' )
    )
);


addColorPalatOption($wp_customize, 'footerarea_trxbgclr', 'footer_area', 'Footer Copyright Text Background Color', '#fff');

addColorPalatOption($wp_customize, 'footerarea_title_color', 'footer_area', 'Footer Title Color', '#000');
addColorPalatOption($wp_customize, 'footerarea_text_color', 'footer_area', 'Footer Text Color', '#575352');
//addColorPalatOption($wp_customize, 'footerarea_hglightsctext_color', 'footer_area', 'Footer Hightlight Text Color', '#000');
addColorPalatOption($wp_customize, 'footerarea_scialicon_color', 'footer_area', 'Footer Social Icon Color', '#fff');
addColorPalatOption($wp_customize, 'footerarea_scialiconhv_color', 'footer_area', 'Footer Social Icon Hover Color', '#000');
addColorPalatOption($wp_customize, 'footerarea_scialiconbg_color', 'footer_area', 'Footer Social Icon Background Color', '#f27968');

addColorPalatOption($wp_customize, 'footerarea_sicon_color', 'footer_area', 'Footer Icon Color', '#f27968');
addColorPalatOption($wp_customize, 'footerarea_siconhover_color', 'footer_area', 'Footer Icon Hover Color', '#000');

addColorPalatOption($wp_customize, 'footerarea_menu_color', 'footer_area', 'Footer Menu Color', '#575352');
addColorPalatOption($wp_customize, 'footerarea_menuhover_color', 'footer_area', 'Footer Menu Hover Color', '#f27968');
addColorPalatOption($wp_customize, 'footerarea_activemenu_color', 'footer_area', 'Active Menu Color', '#f27968');

addColorPalatOption($wp_customize, 'footerarea_datext_color', 'footer_area', 'Date Text Color', '#000');
addColorPalatOption($wp_customize, 'footerarea_tableborder_color', 'footer_area', 'Border Color', '#373946');

addColorPalatOption($wp_customize, 'footerarea_formtextlabel_color', 'footer_area', 'Label Color', '#000');

addColorPalatOption($wp_customize, 'footerarea_formtext_color', 'footer_area', 'Form Text & Placeholder Text Color', '#000');

addColorPalatOption($wp_customize, 'footerarea_formbuttontext_color', 'footer_area', 'Button Text Color', '#f27968');

addColorPalatOption($wp_customize, 'footerareabutton_border_color', 'footer_area', 'Button Border Color', '#f27968');

//addColorPalatOption($wp_customize, 'footerarea_otherfbgs_color', 'footer_area', 'Other Fields Background Color', '#020a21');

//SHOP PAGE SIDEBAR SETTINGS
$wp_customize->add_section(
    'luzuk_shopsidebar_settings',
    array(
        'title' => __( 'Shop Page Sidebar Settings', 'Luzuk Premium' ),
        'panel' => 'luzuk_general_panel',
    )
);


// to show & hide button
$wp_customize->add_setting( 'cd_button_display' , array( 'default' => true, 'transport' => 'refresh', ) ); 
$wp_customize->add_control( 'cd_button_display', array( 'label' => 'Shop Sidebar Display', 'section' => 'luzuk_shopsidebar_settings', 'settings' => 'cd_button_display', 'type' => 'radio', 'choices' => array( 'show' => 'Show Sidebar', 'hide' => 'Hide Sidebar', ), ) ); 
// end to show & hide button
$wp_customize->add_setting(
    'productpages_innerpageheading2',
    array(
        'sanitize_callback' => 'luzuk_sanitize_text',
        'default'           => __( '16px', 'Luzuk Premium' )
    )
);
$wp_customize->add_control(
    'productpages_innerpageheading2',
    array(
        'settings'      => 'productpages_innerpageheading2',
        'section'       => 'luzuk_shopsidebar_settings',
        'type'          => 'text',
        'label'         => __( 'Product Font Size', 'Luzuk Premium' )
    )
);


$wp_customize->add_section(
    'luzuk_innerpageshortcode_page_settings',
    array(
        'title' => __( 'Color Setting For Shortcode Pages', 'luzuk-premium' ),
        'panel' => 'luzuk_general_panel',
    )
);

    $wp_customize->add_setting('luzuk_premium_colorsetting_section_lbl', array('sanitize_callback'=>'luzuk_sanitize_text'));
$wp_customize->add_control(
    new luzuk_Info_Text( 
        $wp_customize,
        'luzuk_premium_colorsetting_section_lbl',
        array(
            'settings'      => 'luzuk_premium_colorsetting_section_lbl',
            'section'       => 'luzuk_innerpageshortcode_page_settings',
            'label'         => __( 'Note:', 'luzuk-premium' ),  
            'description'   => __( '<b>This section available only for PRO version</b><br>If you want this section click on <b>Go Pro</b>', 'luzuk-premium' ),
        )
    )
);



$wp_customize->add_section(
    'luzuk_innerpagefont_settings',
    array(
        'title' => __( 'Inner Page Settings', 'luzuk-premium' ),
        'panel' => 'luzuk_general_panel',
    )
);

   $wp_customize->add_setting('luzuk_premium_innerpage_section_lbl', array('sanitize_callback'=>'luzuk_sanitize_text'));
$wp_customize->add_control(
    new luzuk_Info_Text( 
        $wp_customize,
        'luzuk_premium_innerpage_section_lbl',
        array(
            'settings'      => 'luzuk_premium_innerpage_section_lbl',
            'section'       => 'luzuk_innerpagefont_settings',
            'label'         => __( 'Note:', 'luzuk-premium' ),  
            'description'   => __( '<b>This section available only for PRO version</b><br>If you want this section click on <b>Go Pro</b>', 'luzuk-premium' ),
        )
    )
);

