<?php

namespace Gigneo\Elementor\Widgets;

if ( ! defined( 'ABSPATH' ) ) {
	exit; // Exit if accessed directly.
}

use Elementor\Controls_Manager;
use Elementor\Core\Kits\Documents\Tabs\Global_Typography;
use Elementor\Group_Control_Border;
use Elementor\Group_Control_Box_Shadow;
use Elementor\Group_Control_Text_Shadow;
use Elementor\Group_Control_Typography;
use Elementor\Widget_Base;

/**
 * Gigneo Elementor Employer_Grid Widget
 *
 * @since 0.0.1
 */
class Employer_Grid extends Widget_Base {

	/**
	 * Get widget unique name.
	 *
	 * @return string
	 */
	public function get_name() {
		return 'gigneo-employer-grid';
	}

	/**
	 * Get widget title.
	 *
	 * @return string
	 */
	public function get_title() {
		return esc_html__( 'Employer Grid', 'gigneo' );
	}

	/**
	 * Get widget icon.
	 *
	 * @return string
	 */
	public function get_icon() {
		return 'eicon-gallery-grid gn-label';
	}

	/**
	 * Get widget categories.
	 *
	 * @return array
	 */
	public function get_categories() {
		return array( 'gigneo-widgets' );
	}

	/**
	 * Get widget keywords.
	 *
	 * @return array
	 */
	public function get_keywords() {
		return array( 'employer', 'employers', 'grid' );
	}

	/**
	 * Register widget controls.
	 */
	protected function register_controls() {

		$this->start_controls_section(
			'section_general',
			array(
				'label' => esc_html__( 'General', 'gigneo' ),
				'tab'   => Controls_Manager::TAB_CONTENT,
			)
		);

        $this->add_control(
            'show_save_button',
            array(
                'label'        => esc_html__( 'Save Button', 'gigneo' ),
                'type'         => Controls_Manager::SWITCHER,
                'label_on'     => esc_html__( 'Show', 'gigneo' ),
                'label_off'    => esc_html__( 'Hide', 'gigneo' ),
                'return_value' => 'yes',
                'default'      => 'yes',
            )
        );

        $this->add_control(
            'show_status',
            array(
                'label'        => esc_html__( 'Status', 'gigneo' ),
                'type'         => Controls_Manager::SWITCHER,
                'label_on'     => esc_html__( 'Show', 'gigneo' ),
                'label_off'    => esc_html__( 'Hide', 'gigneo' ),
                'return_value' => 'yes',
                'default'      => 'yes',
            )
        );

        $this->add_control(
            'show_rating',
            array(
                'label'        => esc_html__( 'Rating', 'gigneo' ),
                'type'         => Controls_Manager::SWITCHER,
                'label_on'     => esc_html__( 'Show', 'gigneo' ),
                'label_off'    => esc_html__( 'Hide', 'gigneo' ),
                'return_value' => 'yes',
                'default'      => 'yes',
            )
        );

        $this->add_control(
            'show_location',
            array(
                'label'        => esc_html__( 'Location', 'gigneo' ),
                'type'         => Controls_Manager::SWITCHER,
                'label_on'     => esc_html__( 'Show', 'gigneo' ),
                'label_off'    => esc_html__( 'Hide', 'gigneo' ),
                'return_value' => 'yes',
                'default'      => 'yes',
            )
        );

        $this->add_control(
            'show_tagline',
            array(
                'label'        => esc_html__( 'Tagline', 'gigneo' ),
                'type'         => Controls_Manager::SWITCHER,
                'label_on'     => esc_html__( 'Show', 'gigneo' ),
                'label_off'    => esc_html__( 'Hide', 'gigneo' ),
                'return_value' => 'yes',
                'default'      => 'yes',
            )
        );

        $this->add_control(
            'show_stats',
            array(
                'label'        => esc_html__( 'Stats', 'gigneo' ),
                'type'         => Controls_Manager::SWITCHER,
                'label_on'     => esc_html__( 'Show', 'gigneo' ),
                'label_off'    => esc_html__( 'Hide', 'gigneo' ),
                'return_value' => 'yes',
                'default'      => 'yes',
            )
        );

        $this->add_control(
            'show_view_profile',
            array(
                'label'        => esc_html__( 'View Profile', 'gigneo' ),
                'type'         => Controls_Manager::SWITCHER,
                'label_on'     => esc_html__( 'Show', 'gigneo' ),
                'label_off'    => esc_html__( 'Hide', 'gigneo' ),
                'return_value' => 'yes',
                'default'      => 'yes',
            )
        );

		$this->end_controls_section();

		$this->start_controls_section(
			'section_query',
			array(
				'label' => esc_html__( 'Query', 'gigneo' ),
				'tab'   => Controls_Manager::TAB_CONTENT,
			)
		);

		$query_by_options = array(
			'term'     => esc_html__( 'Term', 'gigneo' ),
			'author'   => esc_html__( 'Author', 'gigneo' ),
			'employer' => esc_html__( 'Name / ID', 'gigneo' ),
		);

		$taxonomy_labels = array(
			'gigneo_facet'    => esc_html__( 'Categories', 'gigneo' ),
			'gigneo_skill'    => esc_html__( 'Skills', 'gigneo' ),
			'gigneo_language' => esc_html__( 'Languages', 'gigneo' ),
			'gigneo_license'  => esc_html__( 'Licenses', 'gigneo' ),
		);

		$term_options = array();

		foreach ( array_keys( $taxonomy_labels ) as $taxonomy ) {
			$terms = get_terms(
				array(
					'taxonomy'   => $taxonomy,
					'hide_empty' => false,
				)
			);

			if ( is_wp_error( $terms ) || empty( $terms ) ) {
				continue;
			}

			foreach ( $terms as $term ) {
				$term_options[ $taxonomy . ':' . $term->term_id ] = $taxonomy_labels[ $taxonomy ] . ': ' . $term->name;
			}
		}

		$author_options   = array();
		$employer_options = array();
		$employer_ids     = get_posts(
			array(
				'post_type'      => 'gigneo_employer',
				'post_status'    => 'publish',
				'posts_per_page' => -1,
				'fields'         => 'ids',
			)
		);

		foreach ( $employer_ids as $post_id ) {
			$author_id = (int) get_post_field( 'post_author', $post_id );
			if ( $author_id > 0 ) {
				$author_options[ (string) $author_id ] = get_the_author_meta( 'display_name', $author_id );
			}

			$employer_options[ (string) $post_id ] = sprintf(
				'%1$s (#%2$d)',
				gigneo_profile_name( $post_id ),
				$post_id
			);
		}

		asort( $author_options );
		asort( $employer_options );

		$orderby_options = array(
			'date'        => esc_html__( 'Date', 'gigneo' ),
			'title'       => esc_html__( 'Title', 'gigneo' ),
			'menu_order'  => esc_html__( 'Menu Order', 'gigneo' ),
			'rand'        => esc_html__( 'Random', 'gigneo' ),
			'recommended' => esc_html__( 'Recommended', 'gigneo' ),
			'top_rated'   => esc_html__( 'Top Rated', 'gigneo' ),
		);

		$this->start_controls_tabs( 'query_include_exclude_tabs' );

		$this->start_controls_tab(
			'query_include_tab',
			array(
				'label' => esc_html__( 'Include', 'gigneo' ),
			)
		);

		$this->add_control(
			'include_by',
			array(
				'label'       => esc_html__( 'Include By', 'gigneo' ),
				'type'        => Controls_Manager::SELECT2,
				'multiple'    => true,
				'label_block' => true,
				'options'     => $query_by_options,
				'default'     => array(),
			)
		);

		$this->add_control(
			'include_term_ids',
			array(
				'label'       => esc_html__( 'Terms', 'gigneo' ),
				'type'        => Controls_Manager::SELECT2,
				'options'     => $term_options,
				'multiple'    => true,
				'label_block' => true,
				'condition'   => array(
					'include_by' => 'term',
				),
			)
		);

		$this->add_control(
			'include_authors',
			array(
				'label'       => esc_html__( 'Authors', 'gigneo' ),
				'type'        => Controls_Manager::SELECT2,
				'options'     => $author_options,
				'multiple'    => true,
				'label_block' => true,
				'condition'   => array(
					'include_by' => 'author',
				),
			)
		);

		$this->add_control(
			'include_employers',
			array(
				'label'       => esc_html__( 'Name / ID', 'gigneo' ),
				'type'        => Controls_Manager::SELECT2,
				'options'     => $employer_options,
				'multiple'    => true,
				'label_block' => true,
				'condition'   => array(
					'include_by' => 'employer',
				),
			)
		);

		$this->end_controls_tab();

		$this->start_controls_tab(
			'query_exclude_tab',
			array(
				'label' => esc_html__( 'Exclude', 'gigneo' ),
			)
		);

		$this->add_control(
			'exclude_by',
			array(
				'label'       => esc_html__( 'Exclude By', 'gigneo' ),
				'type'        => Controls_Manager::SELECT2,
				'multiple'    => true,
				'label_block' => true,
				'options'     => $query_by_options,
				'default'     => array(),
			)
		);

		$this->add_control(
			'exclude_term_ids',
			array(
				'label'       => esc_html__( 'Terms', 'gigneo' ),
				'type'        => Controls_Manager::SELECT2,
				'options'     => $term_options,
				'multiple'    => true,
				'label_block' => true,
				'condition'   => array(
					'exclude_by' => 'term',
				),
			)
		);

		$this->add_control(
			'exclude_authors',
			array(
				'label'       => esc_html__( 'Authors', 'gigneo' ),
				'type'        => Controls_Manager::SELECT2,
				'options'     => $author_options,
				'multiple'    => true,
				'label_block' => true,
				'condition'   => array(
					'exclude_by' => 'author',
				),
			)
		);

		$this->add_control(
			'exclude_employers',
			array(
				'label'       => esc_html__( 'Name / ID', 'gigneo' ),
				'type'        => Controls_Manager::SELECT2,
				'options'     => $employer_options,
				'multiple'    => true,
				'label_block' => true,
				'condition'   => array(
					'exclude_by' => 'employer',
				),
			)
		);

		$this->end_controls_tab();

		$this->end_controls_tabs();

		$this->add_control(
			'orderby',
			array(
				'label'     => esc_html__( 'Order By', 'gigneo' ),
				'type'      => Controls_Manager::SELECT,
				'default'   => 'date',
				'options'   => $orderby_options,
				'separator' => 'before',
			)
		);

		$this->add_control(
			'order',
			array(
				'label'   => esc_html__( 'Order', 'gigneo' ),
				'type'    => Controls_Manager::SELECT,
				'default' => 'DESC',
				'options' => array(
					'ASC'  => esc_html__( 'ASC', 'gigneo' ),
					'DESC' => esc_html__( 'DESC', 'gigneo' ),
				),
			)
		);

		$this->add_control(
			'posts_per_page',
			array(
				'label'   => esc_html__( 'Per Page', 'gigneo' ),
				'type'    => Controls_Manager::NUMBER,
				'default' => (int) gigneo_option( '_gigneo_ts_employers_per_page', 9 ),
				'min'     => 1,
				'max'     => 100,
			)
		);

		$this->end_controls_section();

		$this->start_controls_section(
			'general_style',
			array(
				'label' => esc_html__( 'General', 'gigneo' ),
				'tab'   => Controls_Manager::TAB_STYLE,
			)
		);

		$this->add_control(
			'general_bg_color',
			array(
				'label'     => esc_html__( 'Background Color', 'gigneo' ),
				'type'      => Controls_Manager::COLOR,
				'selectors' => array(
					'{{WRAPPER}} .gn-employer-card' => 'background-color: {{VALUE}};',
				),
			)
		);

		$this->add_group_control(
			Group_Control_Box_Shadow::get_type(),
			array(
				'name'     => 'general_box_shadow',
				'selector' => '{{WRAPPER}} .gn-employer-card',
			)
		);

		$this->add_responsive_control(
			'items_per_row',
			array(
				'label'     => esc_html__( 'Per Row', 'gigneo' ),
				'type'      => Controls_Manager::SELECT,
				'options'   => array(
					'1' => esc_html__( '1 Item', 'gigneo' ),
					'2' => esc_html__( '2 Items', 'gigneo' ),
					'3' => esc_html__( '3 Items', 'gigneo' ),
					'4' => esc_html__( '4 Items', 'gigneo' ),
				),
				'default'   => '3',
				'selectors' => array(
					'{{WRAPPER}} .gn-ele-employer-grid-wrapper' => 'grid-template-columns: repeat({{VALUE}}, 1fr);',
				),
			)
		);

		$this->add_responsive_control(
			'general_space_between',
			array(
				'type'       => Controls_Manager::SLIDER,
				'label'      => esc_html__( 'Space Between', 'gigneo' ),
				'size_units' => array( 'px', '%', 'em', 'rem', 'custom' ),
                'range' => [
                    'px' => [
                        'min' => 0,
                        'max' => 50,
                        'step' => 1,
                    ],
                ],
				'default'    => array(
					'unit' => 'px',
				),
				'selectors'  => array(
					'{{WRAPPER}} .gn-ele-employer-grid-wrapper' => 'gap: {{SIZE}}{{UNIT}};',
				),
			)
		);

		$this->add_group_control(
			Group_Control_Border::get_type(),
			array(
				'name'      => 'general_border',
				'separator' => 'before',
				'selector'  => '{{WRAPPER}} .gn-employer-card',
			)
		);

		$this->add_responsive_control(
			'genera_border_radius',
			array(
				'label'     => esc_html__( 'Border Radius', 'gigneo' ),
				'type'      => Controls_Manager::DIMENSIONS,
				'selectors' => array(
					'{{WRAPPER}} .gn-employer-card' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
				),
			)
		);

		$this->add_responsive_control(
			'general_padding',
			array(
				'label'      => esc_html__( 'Padding', 'gigneo' ),
				'type'       => Controls_Manager::DIMENSIONS,
				'size_units' => array( 'px', 'em', '%' ),
				'selectors'  => array(
					'{{WRAPPER}} .gn-employer-card' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
				),
			)
		);

		$this->add_responsive_control(
			'general_margin',
			array(
				'label'      => esc_html__( 'Margin', 'gigneo' ),
				'type'       => Controls_Manager::DIMENSIONS,
				'size_units' => array( 'px', 'em', '%' ),
				'selectors'  => array(
					'{{WRAPPER}} .gn-employer-card' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
				),
			)
		);

		$this->end_controls_section();

        $this->start_controls_section(
            'cover_image_style',
            array(
                'label'     => esc_html__( 'Cover', 'gigneo' ),
                'tab'       => Controls_Manager::TAB_STYLE,
            )
        );

        $this->add_responsive_control(
            'card_cover_image_height',
            array(
                'label'      => esc_html__( 'Height', 'gigneo' ),
                'type'       => Controls_Manager::SLIDER,
                'size_units' => array( 'px', '%', 'vw' ),
                'range'      => array(
                    'px' => array(
                        'min' => 50,
                        'max' => 200,
                    ),
                ),
                'default'    => array(
                    'size' => 120,
                    'unit' => 'px',
                ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-employer-card .gn-cover-wrapper .gn-cover' => 'height: {{SIZE}}{{UNIT}};',
                ),
            )
        );

        $this->add_group_control(
            Group_Control_Border::get_type(),
            array(
                'name'     => 'card_cover_image_border',
                'selector' => '{{WRAPPER}} .gn-employer-card .gn-cover-wrapper .gn-cover',
            )
        );

        $this->add_responsive_control(
            'card_cover_image_border_radius',
            array(
                'label'      => esc_html__( 'Border Radius', 'gigneo' ),
                'type'       => Controls_Manager::DIMENSIONS,
                'size_units' => array( 'px', '%' ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-employer-card .gn-cover-wrapper .gn-cover, .gn-employer-card .gn-cover-wrapper .gn-cover img' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
                ),
            )
        );

        $this->add_control(
            'archive_card_save_button_heading',
            array(
                'label'     => esc_html__( 'Save Button', 'gigneo' ),
                'type'      => Controls_Manager::HEADING,
                'separator' => 'before',
                'condition' => [
                    'show_save_button' => 'yes',
                ],
            )
        );

        $this->add_responsive_control(
            'save_btn_size',
            array(
                'label'      => __( 'Size', 'gigneo' ),
                'type'       => \Elementor\Controls_Manager::SLIDER,
                'size_units' => array( 'px', '%', 'em' ),
                'condition' => [
                    'show_save_button' => 'yes',
                ],
                'range'      => array(
                    'px' => array(
                        'min'  => 20,
                        'max'  => 50,
                        'step' => 1,
                    ),
                ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-save-btn'            => 'width: {{SIZE}}{{UNIT}}; height: {{SIZE}}{{UNIT}};',
                    '{{WRAPPER}} .gn-saved-icon svg'      => 'width: calc({{SIZE}}{{UNIT}} - 12px); height: calc({{SIZE}}{{UNIT}} - 12px);',
                    '{{WRAPPER}} button.gn-loading:after' => 'width: calc({{SIZE}}{{UNIT}} - 14px); height: calc({{SIZE}}{{UNIT}} - 14px);',
                ),
            )
        );

        $this->start_controls_tabs( 'save_btn_tabs' );

        $this->start_controls_tab(
            'save_btn_normal',
            array( 'label' => esc_html__( 'Normal', 'gigneo' ),
                'condition' => [
                    'show_save_button' => 'yes',
                ],
            )
        );

        $this->add_control(
            'save_btn_icon_color',
            array(
                'label'     => esc_html__( 'Icon Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_save_button' => 'yes',
                ],
                'selectors' => array( '{{WRAPPER}} .gn-save-btn svg path' => 'stroke: {{VALUE}};' ),
            )
        );

        $this->add_control(
            'save_btn_bg_color',
            array(
                'label'     => esc_html__( 'Background Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_save_button' => 'yes',
                ],
                'selectors' => array( '{{WRAPPER}} .gn-save-btn' => 'background-color: {{VALUE}};' ),
            )
        );

        $this->add_group_control(
            Group_Control_Box_Shadow::get_type(),
            array(
                'name'     => 'save_btn_shadow',
                'condition' => [
                    'show_save_button' => 'yes',
                ],
                'selector' => '{{WRAPPER}} .gn-save-btn',
            )
        );

        $this->end_controls_tab();

        $this->start_controls_tab(
            'save_btn_hover',
            array( 'label' => esc_html__( 'Hover', 'gigneo' ),
                'condition' => [
                    'show_save_button' => 'yes',
                ],
            )
        );

        $this->add_control(
            'save_btn_icon_color_hover',
            array(
                'label'     => esc_html__( 'Icon Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_save_button' => 'yes',
                ],
                'selectors' => array( '{{WRAPPER}} .gn-save-btn:hover svg path' => 'stroke: {{VALUE}};' ),
            )
        );

        $this->add_control(
            'save_btn_bg_color_hover',
            array(
                'label'     => esc_html__( 'Background Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_save_button' => 'yes',
                ],
                'selectors' => array( '{{WRAPPER}} .gn-save-btn:hover' => 'background-color: {{VALUE}};' ),
            )
        );

        $this->add_control(
            'save_btn_border_color_hover',
            array(
                'label'     => esc_html__( 'Border Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_save_button' => 'yes',
                ],
                'selectors' => array(
                    '.gn-save-btn:hover' => 'border-color: {{VALUE}};',
                ),
            )
        );

        $this->add_group_control(
            Group_Control_Box_Shadow::get_type(),
            array(
                'name'     => 'save_btn_shadow_hover',
                'condition' => [
                    'show_save_button' => 'yes',
                ],
                'selector' => '{{WRAPPER}} .gn-save-btn:hover',
            )
        );

        $this->end_controls_tab();

        $this->start_controls_tab(
            'save_btn_loader',
            array( 'label' => esc_html__( 'Loader', 'gigneo' ),
                'condition' => [
                    'show_save_button' => 'yes',
                ],
            )
        );

        $this->add_control(
            'fav_btn_loader_border_color',
            array(
                'label'     => __( 'Border Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_save_button' => 'yes',
                ],
                'selectors' => array(
                    '{{WRAPPER}} button.gn-loading:after' => 'border-color: {{VALUE}};',
                ),
            )
        );

        $this->add_control(
            'fav_btn_loader_border_top_color',
            array(
                'label'     => __( 'Border Top Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_save_button' => 'yes',
                ],
                'selectors' => array(
                    '{{WRAPPER}} button.gn-loading:after' => 'border-top-color: {{VALUE}};',
                ),
            )
        );

        $this->end_controls_tabs();

        $this->add_group_control(
            Group_Control_Border::get_type(),
            array(
                'name'      => 'save_btn_border',
                'separator' => 'before',
                'condition' => [
                    'show_save_button' => 'yes',
                ],
                'selector'  => '{{WRAPPER}} .gn-save-btn',
            )
        );

        $this->add_responsive_control(
            'save_btn_radius',
            array(
                'label'     => esc_html__( 'Border Radius', 'gigneo' ),
                'type'      => Controls_Manager::DIMENSIONS,
                'condition' => [
                    'show_save_button' => 'yes',
                ],
                'selectors' => array(
                    '{{WRAPPER}} .gn-save-btn' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
                ),
            )
        );

        $this->add_responsive_control(
            'save_btn_margin',
            array(
                'label'      => esc_html__( 'Margin', 'gigneo' ),
                'type'       => Controls_Manager::DIMENSIONS,
                'condition' => [
                    'show_save_button' => 'yes',
                ],
                'size_units' => array( 'px', 'em', '%' ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-save-btn' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
                ),
            )
        );

        $this->end_controls_section();

        $this->start_controls_section(
            'profile_style',
            array(
                'label'     => esc_html__( 'Profile', 'gigneo' ),
                'tab'       => Controls_Manager::TAB_STYLE,
            )
        );

        $this->add_responsive_control(
            'avatar_size',
            array(
                'label'      => __( 'Size', 'gigneo' ),
                'type'       => \Elementor\Controls_Manager::SLIDER,
                'size_units' => array( 'px', '%', 'em' ),
                'range'      => array(
                    'px' => array(
                        'min'  => 10,
                        'max'  => 80,
                        'step' => 1,
                    ),
                ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-employer-card .gn-avatar' => 'width: {{SIZE}}{{UNIT}}; height: {{SIZE}}{{UNIT}};',
                ),
            )
        );

        $this->add_group_control(
            Group_Control_Border::get_type(),
            array(
                'name'     => 'avatar_border',
                'selector' => '{{WRAPPER}} .gn-employer-card .gn-avatar',
            )
        );

        $this->add_responsive_control(
            'avatar_border_radius',
            array(
                'label'      => esc_html__( 'Border Radius', 'gigneo' ),
                'type'       => Controls_Manager::DIMENSIONS,
                'size_units' => array( 'px', '%' ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-employer-card .gn-avatar' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
                ),
            )
        );

        $this->add_responsive_control(
            'avatar_margin',
            array(
                'label'      => esc_html__( 'Margin', 'gigneo' ),
                'type'       => Controls_Manager::DIMENSIONS,
                'size_units' => array( 'px', 'em', '%' ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-employer-card .gn-avatar' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
                ),
            )
        );

        $this->add_control(
            'status_indicator',
            array(
                'label'     => esc_html__( 'Status', 'gigneo' ),
                'type'      => Controls_Manager::HEADING,
                'condition' => [
                    'show_status' => 'yes',
                ],
                'separator' => 'before',
            )
        );

        $this->add_group_control(
            Group_Control_Box_Shadow::get_type(),
            array(
                'name'     => 'status_indicator_box_shadow',
                'label'    => esc_html__( 'Box Shadow', 'gigneo' ),
                'condition' => [
                    'show_status' => 'yes',
                ],
                'selector' => '{{WRAPPER}} .gn-employer-card .gn-avatar:before',
            )
        );

        $this->add_group_control(
            Group_Control_Border::get_type(),
            array(
                'name'     => 'status_indicator_border',
                'condition' => [
                    'show_status' => 'yes',
                ],
                'selector' => '{{WRAPPER}} .gn-employer-card .gn-avatar:before',
            )
        );

        $this->add_responsive_control(
            'status_indicator_margin',
            array(
                'label'      => esc_html__( 'Margin', 'gigneo' ),
                'type'       => Controls_Manager::DIMENSIONS,
                'condition' => [
                    'show_status' => 'yes',
                ],
                'size_units' => array( 'px', 'em', '%' ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-employer-card .gn-avatar:before' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
                ),
            )
        );

        $this->add_control(
            'card_profile_name_heading',
            array(
                'label'     => esc_html__( 'Name', 'gigneo' ),
                'type'      => Controls_Manager::HEADING,
                'separator' => 'before',
            )
        );

        $this->add_group_control(
            Group_Control_Typography::get_type(),
            array(
                'name'     => 'profile_name_typography',
                'global'   => array(
                    'default' => Global_Typography::TYPOGRAPHY_PRIMARY,
                ),
                'selector' => '{{WRAPPER}} .gn-info-wrapper .gn-name',
            )
        );

        $this->add_control(
            'profile_name_color',
            array(
                'label'     => esc_html__( 'Text Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'selectors' => array(
                    '{{WRAPPER}} .gn-info-wrapper .gn-name' => 'color: {{VALUE}};',
                ),
            )
        );

        $this->add_group_control(
            Group_Control_Text_Shadow::get_type(),
            array(
                'name'     => 'profile_name_text_shadow',
                'selector' => '{{WRAPPER}} .gn-info-wrapper .gn-name',
            )
        );

        $this->add_responsive_control(
            'profile_name_margin',
            array(
                'label'      => esc_html__( 'Margin', 'gigneo' ),
                'type'       => Controls_Manager::DIMENSIONS,
                'size_units' => array( 'px', 'em', '%' ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-info-wrapper .gn-name' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
                ),
            )
        );

        $this->add_control(
            'archive_card_rating_heading',
            array(
                'label'     => esc_html__( 'Rating', 'gigneo' ),
                'type'      => Controls_Manager::HEADING,
                'condition' => [
                    'show_rating' => 'yes',
                ],
                'separator' => 'before',
            )
        );

        $this->add_group_control(
            Group_Control_Typography::get_type(),
            array(
                'name'     => 'archive_card_rating_typography',
                'condition' => [
                    'show_rating' => 'yes',
                ],
                'selector' => '{{WRAPPER}} .gn-employer-card .gn-body .gn-info-wrapper .gn-name-wrapper .gn-rating',
            )
        );

        $this->add_control(
            'archive_card_rating_text_color',
            array(
                'label'     => esc_html__( 'Text Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_rating' => 'yes',
                ],
                'default'   => '',
                'selectors' => array(
                    '{{WRAPPER}} .gn-employer-card .gn-body .gn-info-wrapper .gn-name-wrapper .gn-rating' => 'color: {{VALUE}};',
                ),
            )
        );

        $this->start_controls_tabs( 'archive_card_style_tabs' );

        $this->start_controls_tab(
            'archive_card_rating_icon_tab',
            array( 'label' => esc_html__( 'Icon', 'gigneo' ),
                'condition' => [
                    'show_rating' => 'yes',
                ],
            )
        );

        $this->add_responsive_control(
            'rating_icon_size',
            array(
                'label'      => esc_html__( 'Size', 'gigneo' ),
                'type'       => Controls_Manager::SLIDER,
                'condition' => [
                    'show_rating' => 'yes',
                ],
                'size_units' => array( 'px', 'em', 'rem' ),
                'range' => [
                    'px' => [
                        'min' => 15,
                        'max' => 30,
                        'step' => 1,
                    ],
                ],
                'selectors'  => array(
                    '{{WRAPPER}} .gn-employer-card .gn-body .gn-info-wrapper .gn-name-wrapper .gn-rating i' => 'font-size: {{SIZE}}{{UNIT}};',
                ),
            )
        );

        $this->add_control(
            'rating_icon_icon_color',
            array(
                'label'     => esc_html__( 'Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_rating' => 'yes',
                ],
                'default'   => '',
                'selectors' => array(
                    '{{WRAPPER}} .gn-employer-card .gn-body .gn-info-wrapper .gn-name-wrapper .gn-rating i' => 'color: {{VALUE}};',
                ),
            )
        );

        $this->end_controls_tab();

        $this->start_controls_tab(
            'archive_card_rating_count_tab',
            array( 'label' => esc_html__( 'Count', 'gigneo' ),
                'condition' => [
                    'show_rating' => 'yes',
                ],
            )
        );

        $this->add_control(
            'archive_card_rating_count_text_color',
            array(
                'label'     => esc_html__( 'Text Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_rating' => 'yes',
                ],
                'default'   => '',
                'selectors' => array(
                    '{{WRAPPER}} .gn-employer-card .gn-body .gn-info-wrapper .gn-name-wrapper .gn-rating .gn-count' => 'color: {{VALUE}};',
                ),
            )
        );

        $this->add_responsive_control(
            'archive_card_rating_margin',
            array(
                'label'      => esc_html__( 'Margin', 'gigneo' ),
                'type'       => Controls_Manager::DIMENSIONS,
                'condition' => [
                    'show_rating' => 'yes',
                ],
                'size_units' => array( 'px', '%', 'em' ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-employer-card .gn-body .gn-info-wrapper .gn-name-wrapper .gn-rating .gn-count' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
                ),
            )
        );

        $this->end_controls_tab();

        $this->end_controls_tabs();

        $this->end_controls_section();

        $this->start_controls_section(
            'location_style',
            array(
                'label'     => esc_html__( 'Location', 'gigneo' ),
                'tab'       => Controls_Manager::TAB_STYLE,
                'condition' => [
                    'show_location' => 'yes',
                ],
            )
        );

        $this->add_group_control(
            Group_Control_Typography::get_type(),
            array(
                'name'     => 'loc_typography',
                'global'   => array(
                    'default' => Global_Typography::TYPOGRAPHY_PRIMARY,
                ),
                'condition' => [
                    'show_location' => 'yes',
                ],
                'selector' => '{{WRAPPER}} .gn-location',
            )
        );

        $this->add_control(
            'loc_color',
            array(
                'label'     => esc_html__( 'Text Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_location' => 'yes',
                ],
                'selectors' => array(
                    '{{WRAPPER}} .gn-location, .gn-location i' => 'color: {{VALUE}};',
                ),
            )
        );

        $this->add_responsive_control(
            'location_space_between',
            array(
                'label'      => esc_html__( 'Space Between', 'gigneo' ),
                'type'       => Controls_Manager::SLIDER,
                'condition' => [
                    'show_location' => 'yes',
                ],
                'size_units' => array( 'px', '%', 'em' ),
                'range'      => array(
                    'px' => array(
                        'min' => 0,
                        'max' => 30,
                        'step'=> 1,
                    ),
                ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-employer-card .gn-location' => 'gap: {{SIZE}}{{UNIT}};',
                ),
            )
        );

        $this->add_responsive_control(
            'icon_size',
            array(
                'label'     => esc_html__( 'Icon Size', 'gigneo' ),
                'type'      => Controls_Manager::SLIDER,
                'condition' => [
                    'show_location' => 'yes',
                ],
                'range'     => array(
                    'px' => array(
                        'min' => 6,
                        'max' => 30,
                    ),
                ),
                'selectors' => array(
                    '{{WRAPPER}} .gn-location i' => 'font-size: {{SIZE}}{{UNIT}};',
                ),
            )
        );

        $this->add_responsive_control(
            'location_margin',
            array(
                'label'      => esc_html__( 'Margin', 'gigneo' ),
                'type'       => Controls_Manager::DIMENSIONS,
                'condition' => [
                    'show_location' => 'yes',
                ],
                'size_units' => array( 'px', 'em', '%' ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-employer-card .gn-location' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
                ),
            )
        );

        $this->end_controls_section();

        $this->start_controls_section(
            'tagline_style',
            array(
                'label'     => esc_html__( 'Tagline', 'gigneo' ),
                'tab'       => Controls_Manager::TAB_STYLE,
                'condition' => [
                    'show_tagline' => 'yes',
                ],
            )
        );

        $this->add_group_control(
            Group_Control_Typography::get_type(),
            array(
                'name'     => 'card_tagline_typography',
                'condition' => [
                    'show_tagline' => 'yes',
                ],
                'selector' => '{{WRAPPER}} .gn-employer-card .gn-body .gn-info-wrapper .gn-description',
            )
        );

        $this->add_control(
            'card_tagline_text_color',
            array(
                'label'     => esc_html__( 'Text Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_tagline' => 'yes',
                ],
                'default'   => '',
                'selectors' => array(
                    '{{WRAPPER}} .gn-employer-card .gn-body .gn-info-wrapper .gn-description' => 'color: {{VALUE}};',
                ),
            )
        );

        $this->add_responsive_control(
            'card_tagline_margin',
            array(
                'label'      => esc_html__( 'Margin', 'gigneo' ),
                'type'       => Controls_Manager::DIMENSIONS,
                'condition' => [
                    'show_tagline' => 'yes',
                ],
                'size_units' => array( 'px', '%', 'em' ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-employer-card .gn-body .gn-info-wrapper .gn-description' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
                ),
            )
        );

        $this->end_controls_section();

        $this->start_controls_section(
            'stats_style',
            array(
                'label'     => esc_html__( 'Stats', 'gigneo' ),
                'tab'       => Controls_Manager::TAB_STYLE,
                'condition' => [
                    'show_stats' => 'yes',
                ],
            )
        );

        $this->add_responsive_control(
            'stats_padding',
            array(
                'label'      => esc_html__( 'Padding', 'gigneo' ),
                'type'       => Controls_Manager::DIMENSIONS,
                'condition' => [
                    'show_stats' => 'yes',
                ],
                'size_units' => array( 'px', '%', 'em', 'rem', 'vw' ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-employer-card .gn-stats-wrapper' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
                ),
            )
        );

        $this->add_responsive_control(
            'stats_margin',
            array(
                'label'      => esc_html__( 'Margin', 'gigneo' ),
                'type'       => Controls_Manager::DIMENSIONS,
                'condition' => [
                    'show_stats' => 'yes',
                ],
                'size_units' => array( 'px', '%', 'em', 'rem', 'vw' ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-employer-card .gn-stats-wrapper' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
                ),
            )
        );

        $this->start_controls_tabs( 'stats_style_tabs' );

        $this->start_controls_tab(
            'stats_value_tab',
            array( 'label' => esc_html__( 'Value', 'gigneo' ),
                'condition' => [
                    'show_stats' => 'yes',
                ],
            )
        );

        $this->add_group_control(
            Group_Control_Typography::get_type(),
            array(
                'name'     => 'stat_typography',
                'global'   => array(
                    'default' => Global_Typography::TYPOGRAPHY_PRIMARY,
                ),
                'condition' => [
                    'show_stats' => 'yes',
                ],
                'selector' => '{{WRAPPER}} .gn-stat .gn-value',
            )
        );

        $this->add_control(
            'stat_color',
            array(
                'label'     => esc_html__( 'Text Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_stats' => 'yes',
                ],
                'selectors' => array(
                    '{{WRAPPER}} .gn-stat .gn-value' => 'color: {{VALUE}};',
                ),
            )
        );

        $this->end_controls_tab();

        $this->start_controls_tab(
            'stats_label_tab',
            array( 'label' => esc_html__( 'Label', 'gigneo' ),
                'condition' => [
                    'show_stats' => 'yes',
                ],
            )
        );

        $this->add_group_control(
            Group_Control_Typography::get_type(),
            array(
                'name'     => 'stat_label_typography',
                'global'   => array(
                    'default' => Global_Typography::TYPOGRAPHY_SECONDARY,
                ),
                'condition' => [
                    'show_stats' => 'yes',
                ],
                'selector' => '{{WRAPPER}} .gn-stat .gn-label',
            )
        );

        $this->add_control(
            'stat_label_color',
            array(
                'label'     => esc_html__( 'Text Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_stats' => 'yes',
                ],
                'selectors' => array(
                    '{{WRAPPER}} .gn-stat .gn-label' => 'color: {{VALUE}};',
                ),
            )
        );

        $this->add_responsive_control(
            'stat_label_margin',
            array(
                'label'      => esc_html__( 'Margin', 'gigneo' ),
                'type'       => Controls_Manager::DIMENSIONS,
                'condition' => [
                    'show_stats' => 'yes',
                ],
                'size_units' => array( 'px', '%', 'em' ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-stat .gn-label' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
                ),
            )
        );

        $this->end_controls_tab();

        $this->start_controls_tab(
            'stats_separator_tab',
            array( 'label' => esc_html__( 'Separator', 'gigneo' ),
                'condition' => [
                    'show_stats' => 'yes',
                ],
            )
        );

        $this->add_control(
            'stat_separator_border_color',
            array(
                'label'     => __( 'Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_stats' => 'yes',
                ],
                'selectors' => array(
                    '{{WRAPPER}} .gn-employer-card .gn-stats-wrapper .gn-stat ~ .gn-stat' => 'border-color: {{VALUE}};',
                ),
            )
        );

        $this->end_controls_tab();

        $this->end_controls_tabs();

        $this->end_controls_section();

        $this->start_controls_section(
            'view_profile_style',
            array(
                'label'     => esc_html__( 'Footer', 'gigneo' ),
                'tab'       => Controls_Manager::TAB_STYLE,
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
            )
        );

        $this->add_control(
            'card_footer_background_color',
            array(
                'label'     => esc_html__( 'Background Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
                'selectors' => array(
                    '{{WRAPPER}} .gn-employer-card .gn-footer' => 'background-color: {{VALUE}};',
                ),
            )
        );

        $this->add_group_control(
            Group_Control_Border::get_type(),
            array(
                'name'     => 'card_footer_border',
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
                'selector' => '{{WRAPPER}} .gn-employer-card .gn-footer',
            )
        );

        $this->add_responsive_control(
            'card_footer_border_radius',
            array(
                'label'      => esc_html__( 'Border Radius', 'gigneo' ),
                'type'       => Controls_Manager::DIMENSIONS,
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
                'size_units' => array( 'px', '%' ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-employer-card .gn-footer' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
                ),
            )
        );

        $this->add_responsive_control(
            'card_footer_padding',
            array(
                'label'      => esc_html__( 'Padding', 'gigneo' ),
                'type'       => Controls_Manager::DIMENSIONS,
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
                'size_units' => array( 'px', 'em', '%' ),
                'selectors'  => array(
                    '{{WRAPPER}} .gn-employer-card .gn-footer' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
                ),
            )
        );

        $this->add_control(
            'card_profile_button_heading',
            array(
                'label'     => esc_html__( 'Button', 'gigneo' ),
                'type'      => Controls_Manager::HEADING,
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
                'separator' => 'before',
            )
        );

        $this->add_group_control(
            Group_Control_Typography::get_type(),
            array(
                'name'     => 'view_btn_typography',
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
                'selector' => '{{WRAPPER}} .gn-view-profile',
            )
        );

        $this->add_responsive_control(
            'view_btn_icon_size',
            array(
                'label'      => esc_html__( 'Icon Size', 'gigneo' ),
                'type'       => Controls_Manager::SLIDER,
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
                'size_units' => array( 'px', 'em', 'rem' ),
                'range' => [
                    'px' => [
                        'min' => 10,
                        'max' => 30,
                        'step' => 1,
                    ],
                ],
                'selectors'  => array(
                    '{{WRAPPER}} .gn-view-profile i' => 'font-size: {{SIZE}}{{UNIT}};',
                ),
            )
        );

        $this->start_controls_tabs( 'view_btn_tabs' );

        $this->start_controls_tab(
            'view_btn_normal',
            array(
                'label' => esc_html__( 'Normal', 'gigneo' ),
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
            )
        );

        $this->add_control(
            'view_btn_text_color',
            array(
                'label'     => esc_html__( 'Text Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
                'selectors' => array(
                    '{{WRAPPER}} .gn-view-profile'   => 'color: {{VALUE}};',
                    '{{WRAPPER}} .gn-view-profile i' => 'color: {{VALUE}};',
                ),
            )
        );

        $this->add_control(
            'view_btn_bg_color',
            array(
                'label'     => esc_html__( 'Background Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
                'selectors' => array(
                    '{{WRAPPER}} .gn-view-profile' => 'background-color: {{VALUE}};',
                ),
            )
        );

        $this->add_group_control(
            Group_Control_Box_Shadow::get_type(),
            array(
                'name'     => 'view_btn_shadow',
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
                'selector' => '{{WRAPPER}} .gn-view-profile',
            )
        );

        $this->end_controls_tab();

        $this->start_controls_tab(
            'view_btn_hover',
            array(
                'label' => esc_html__( 'Hover', 'gigneo' ),
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
            )
        );

        $this->add_control(
            'view_btn_text_color_hover',
            array(
                'label'     => esc_html__( 'Text Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
                'selectors' => array(
                    '{{WRAPPER}} .gn-view-profile:hover'   => 'color: {{VALUE}};',
                    '{{WRAPPER}} .gn-view-profile:hover i' => 'color: {{VALUE}};',
                ),
            )
        );

        $this->add_control(
            'view_btn_bg_color_hover',
            array(
                'label'     => esc_html__( 'Background Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
                'selectors' => array(
                    '{{WRAPPER}} .gn-view-profile:hover' => 'background-color: {{VALUE}};',
                ),
            )
        );

        $this->add_control(
            'view_btn_border_color_hover',
            array(
                'label'     => __( 'Border Color', 'gigneo' ),
                'type'      => Controls_Manager::COLOR,
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
                'selectors' => array(
                    '{{WRAPPER}} .gn-view-profile:hover' => 'border-color: {{VALUE}};',
                ),
            )
        );

        $this->add_group_control(
            Group_Control_Box_Shadow::get_type(),
            array(
                'name'     => 'view_btn_shadow_hover',
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
                'selector' => '{{WRAPPER}} .gn-view-profile:hover',
            )
        );

        $this->end_controls_tab();

        $this->end_controls_tabs();

        $this->add_group_control(
            Group_Control_Border::get_type(),
            array(
                'name'      => 'view_btn_border',
                'separator' => 'before',
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
                'selector'  => '{{WRAPPER}} .gn-view-profile',
            )
        );

        $this->add_responsive_control(
            'view_radius',
            array(
                'label'     => esc_html__( 'Border Radius', 'gigneo' ),
                'type'      => Controls_Manager::DIMENSIONS,
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
                'selectors' => array(
                    '{{WRAPPER}} .gn-view-profile' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
                ),
            )
        );

        $this->add_responsive_control(
            'viw_btn_padding',
            array(
                'label'     => esc_html__( 'Padding', 'gigneo' ),
                'type'      => Controls_Manager::DIMENSIONS,
                'condition' => [
                    'show_view_profile' => 'yes',
                ],
                'selectors' => array(
                    '{{WRAPPER}} .gn-view-profile' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',
                ),
            )
        );

        $this->end_controls_section();
	}

	/**
	 * Render widget output on the frontend.
	 */
	protected function render() {
		require gigneo_get_template( 'elementor/widgets/employer-grid' );
	}
}
