<?php
namespace Elementor;

class zemanatsingle extends Widget_Base {
	
	public function get_name() {
		return 'zemanatsingle';
	}
	
	public function get_title() {
		return 'ضمانت نامه';
	}
	
 public function get_icon() {
		return 'eicon eicon-check-circle';
    }
    
    public function get_categories() {
        return [ 'farnamproduct' ];
    }

	
	protected function register_controls() {


		
		
		
  $this->start_controls_section(
            'farnam_product_style_2',
            [
                'label' => esc_html__( 'تنظیمات استایل و ظاهر', 'woolentor' ),
            ]
        );


		    $this->add_control(
'sepidcolor-2',
			[
				'label' => __( 'رنگ پس زمینه', 'plugin-domain' ),
				'type' => Controls_Manager::COLOR,
			
				'selectors' => [
					'{{WRAPPER}} .zemanat-single-product' => 'background: {{VALUE}} !important',
				],
			]
           );
		      $this->add_control(
'sepidcolor-3',
			[
				'label' => __( 'رنگ متن', 'plugin-domain' ),
				'type' => Controls_Manager::COLOR,
			
				'selectors' => [
					'{{WRAPPER}} .zemanat-single-product' => 'color: {{VALUE}} !important',
				],
			]
           );
		

		  $this->add_control(
'sepidcolor-5fr132344',
			[
				'label' => __( 'رنگ پس زمینه ایکون', 'plugin-domain' ),
				'type' => Controls_Manager::COLOR,
			
				'selectors' => [
					'{{WRAPPER}} .zemanat-single-product i' => 'background: {{VALUE}} !important',
				],
			]
           );
		   
  $this->add_control(
'sepidcolor-5fr1',
			[
				'label' => __( 'رنگ ایکون', 'plugin-domain' ),
				'type' => Controls_Manager::COLOR,
			
				'selectors' => [
					'{{WRAPPER}} .zemanat-single-product i' => 'color: {{VALUE}} !important',
				],
			]
           );

 $this->add_control(
                        'titr-mehr-4555',
                        [
                            'label' => __( 'سایه دور ایکون', 'woolentor' ),
                            'type' => Controls_Manager::HEADING,
                                              ]
                    );

			$this->add_group_control(
			\Elementor\Group_Control_Box_Shadow::get_type(),
			[
				'name' => 'box_s56456hadow',
				'selector' => '{{WRAPPER}} .zemanat-single-product i',
			]
		);
		 
		 $this->add_control(
                        'titr-mehr-4',
                        [
                            'label' => __( 'سایه باکس ضمانت', 'woolentor' ),
                            'type' => Controls_Manager::HEADING,
                                              ]
                    );

			$this->add_group_control(
			\Elementor\Group_Control_Box_Shadow::get_type(),
			[
				'name' => 'box_shadow',
				'selector' => '{{WRAPPER}} .zemanat-single-product',
			]
		);
			
				  $this->add_control(
                        'titr-mehr-2',
                        [
                            'label' => __( 'کادر باکس ضمانت ', 'woolentor' ),
                            'type' => Controls_Manager::HEADING,
                                              ]
                    );
		$this->add_group_control(
			\Elementor\Group_Control_Border::get_type(),
			[
				'name' => 'border-mehr-2',
				'selector' => '{{WRAPPER}} .zemanat-single-product',
			]
		);	
				$this->add_responsive_control(
			'title_padding',
			[
				'type' => \Elementor\Controls_Manager::DIMENSIONS,
				'label' => esc_html__( 'فاصله داخلی', 'textdomain' ),
				'size_units' => [ 'px', '%', 'em', 'rem', 'custom' ],
				'selectors' => [
					'{{WRAPPER}} .zemanat-single-product' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
				],
			]
		);
					 $this->add_responsive_control(
                        'sepidborder-2',
                        [
                            'label' => esc_html__( 'گردی باکس ضمانت', 'woolentor' ),
                            'type' => Controls_Manager::DIMENSIONS,
                            'selectors' => [
                                '{{WRAPPER}} .zemanat-single-product' => 'border-radius: {{TOP}}px {{RIGHT}}px {{BOTTOM}}px {{LEFT}}px !important;',
                            ],
                        ]
                    );
					
					
					 $this->add_responsive_control(
                        'sepidborder-3',
                        [
                            'label' => esc_html__( 'گردی ایکون', 'woolentor' ),
                            'type' => Controls_Manager::DIMENSIONS,
                            'selectors' => [
                                '{{WRAPPER}} .zemanat-single-product i' => 'border-radius: {{TOP}}px {{RIGHT}}px {{BOTTOM}}px {{LEFT}}px !important;',
                            ],
                        ]
                    );
		$this->end_controls_section();
		
	}
	protected function render() {
		$settings = $this->get_settings_for_display();
defined( 'ABSPATH' ) || exit;

global $product;


				?>
 <?php $option_meta = rwmb_meta('zemanat'); if (!empty($option_meta)) { ?>

<div class="zemanat-single-product"><i class="fi fi-rr-shield-check"></i><?php echo $option_meta; ?></div><?php } ?>

		<?php


	}


	
	protected function _content_template() {

    }
	
	
}