<?php
/**
 * Candles Shop: Customizer
 *
 * @subpackage Candles Shop
 * @since 1.0
 */

function candles_shop_customize_register( $wp_customize ) {

	wp_enqueue_style('customizercustom_css', esc_url( get_template_directory_uri() ). '/inc/customizer/customizer.css');

	// Pro Section
 	$wp_customize->add_section('candles_shop_pro', array(
        'title'    => __('CANDLES SHOP PREMIUM', 'candles-shop'),
        'priority' => 1,
    ));
    $wp_customize->add_setting('candles_shop_pro', array(
        'default'           => null,
        'sanitize_callback' => 'sanitize_text_field',
    ));
    $wp_customize->add_control(new Candles_Shop_Pro_Control($wp_customize, 'candles_shop_pro', array(
        'label'    => __('CANDLES SHOP PREMIUM', 'candles-shop'),
        'section'  => 'candles_shop_pro',
        'settings' => 'candles_shop_pro',
        'priority' => 1,
    )));
}
add_action( 'customize_register', 'candles_shop_customize_register' );


define('CANDLES_SHOP_PRO_LINK',__('https://www.ovationthemes.com/products/candles-wordpress-theme','candles-shop'));

define('CANDLES_SHOP_BUNDLE_BTN',__('https://www.ovationthemes.com/products/wordpress-bundle','candles-shop'));

/* Pro control */
if (class_exists('WP_Customize_Control') && !class_exists('Candles_Shop_Pro_Control')):
    class Candles_Shop_Pro_Control extends WP_Customize_Control{

    public function render_content(){?>
        <label style="overflow: hidden; zoom: 1;">
	        <div class="col-md upsell-btn">
                <a href="<?php echo esc_url( CANDLES_SHOP_PRO_LINK ); ?>" target="blank" class="btn btn-success btn"><?php esc_html_e('UPGRADE CANDLES SHOP PREMIUM','candles-shop');?> </a>
	        </div>
            <div class="col-md">
                <img class="candles_shop_img_responsive " src="<?php echo esc_url(get_template_directory_uri()); ?>/screenshot.png">
            </div>
	        <div class="col-md">
                <ul style="padding-top:10px">
                    <li class="upsell-candles_shop"> <div class="dashicons dashicons-yes"></div> <?php esc_html_e('Responsive Design', 'candles-shop');?> </li>                 
                    <li class="upsell-candles_shop"> <div class="dashicons dashicons-yes"></div> <?php esc_html_e('Demo Importer', 'candles-shop');?> </li>
                    <li class="upsell-candles_shop"> <div class="dashicons dashicons-yes"></div> <?php esc_html_e('Section Reordering', 'candles-shop');?> </li>
                    <li class="upsell-candles_shop"> <div class="dashicons dashicons-yes"></div> <?php esc_html_e('Contact Page Template', 'candles-shop');?> </li>
                    <li class="upsell-candles_shop"> <div class="dashicons dashicons-yes"></div> <?php esc_html_e('Multiple Blog Layouts', 'candles-shop');?> </li>
                    <li class="upsell-candles_shop"> <div class="dashicons dashicons-yes"></div> <?php esc_html_e('Unlimited Color Options', 'candles-shop');?> </li>
                    <li class="upsell-candles_shop"> <div class="dashicons dashicons-yes"></div> <?php esc_html_e('Cross Browser Support', 'candles-shop');?> </li>
                    <li class="upsell-candles_shop"> <div class="dashicons dashicons-yes"></div> <?php esc_html_e('Detailed Documentation Included', 'candles-shop');?> </li>
                    <li class="upsell-candles_shop"> <div class="dashicons dashicons-yes"></div> <?php esc_html_e('WPML Compatible (Translation Ready)', 'candles-shop');?> </li>
                    <li class="upsell-candles_shop"> <div class="dashicons dashicons-yes"></div> <?php esc_html_e('Woo-commerce Compatible', 'candles-shop');?> </li>
                    <li class="upsell-candles_shop"> <div class="dashicons dashicons-yes"></div> <?php esc_html_e('Full Support', 'candles-shop');?> </li>
                    <li class="upsell-candles_shop"> <div class="dashicons dashicons-yes"></div> <?php esc_html_e('10+ Sections', 'candles-shop');?> </li>
                    <li class="upsell-candles_shop"> <div class="dashicons dashicons-yes"></div> <?php esc_html_e('SEO Friendly', 'candles-shop');?> </li>
                    <li class="upsell-candles_shop"> <div class="dashicons dashicons-yes"></div> <?php esc_html_e('Supper Fast', 'candles-shop');?> </li>
                </ul>
        	</div>
            <div class="col-md upsell-btn upsell-btn-bottom">
                <a href="<?php echo esc_url( CANDLES_SHOP_BUNDLE_BTN ); ?>" target="blank" class="btn btn-success btn"><?php esc_html_e('WP Theme Bundle (125+ Themes)','candles-shop');?> </a>
            </div>
        </label>
    <?php } }
endif;