/* 
Theme Name: Hello Elementor Child
Theme URI: https://github.com/elementor/hello-theme/
Description: Hello Elementor Child is a child theme of Hello Elementor, created by Elementor team
Author: Elementor Team
Author URI: https://elementor.com/
Template: hello-elementor
Version: 1.0.1
Text Domain: hello-elementor-child
License: GNU General Public License v3 or later.
License URI: https://www.gnu.org/licenses/gpl-3.0.html
Tags: flexible-header, custom-colors, custom-menu, custom-logo, editor-style, featured-images, rtl-language-support, threaded-comments, translation-ready
*/

/*
    Add your custom styles here
*/
body a {
	color: #6d983f
}
.elementor-nav-menu li.temp_hide {display: none;}

.elementor-widget-container p a {
	color: #6d983f;
}
	#gform_submit_button_4, #gform_submit_button_2 {
		color: #7a7a7a;
		border-color: #7a7a7a;
	}
#gform_submit_button_4:hover, #gform_submit_button_2:hover {
	background-color: #7a7a7a;
	color: white;
}

html, body{
width:100%;
overflow-x:hidden;
}
.tg-grid-area-top2 .tg-dropdown-holder {
	padding: 0 30px;
}

/*** REMOVE LABEL ON FIELDS USING PLACEHOLDER ***/
.gform_wrapper .top_label .gfield_label,
.gform_wrapper .field_sublabel_below .ginput_complex.ginput_container label {
 display: none !important;
}
/*** FIELD STYLING ***/
input[type=text],
textarea {
 background: #eee;
 border: none;
 border-radius: 0;
 color: #999 !important;
 padding: 15px !important;
	font-size: 16px !important;
}
/*** BUTTON STYLING ***/
.gform_wrapper .gform_footer input.button {
 float: right;
 background: transparent;
 border: 2px solid #6d983f;
 font-size: 22px;
 color: #6d983f;
 padding: 12px 23px;
 border-radius: 5px;
 letter-spacing: 2px;
 cursor: pointer;
}
/*** BUTTON HOVER STYLING ***/
.gform_wrapper .gform_footer input.button:hover {
 background: rgba(0, 0, 0, 0.05);
 border: 2px solid transparent;
}
.gform_wrapper .gfield_checkbox li input, .gform_wrapper .gfield_checkbox li input[type=checkbox], .gform_wrapper .gfield_radio li input[type=radio] {
	margin-left: 5px !important;
}
.ginput_complex.ginput_container.has_street.has_street2.has_city.has_state.has_zip.has_country.ginput_container_address input {
	margin: 5px 0;
}
#input_5_3_6 {
	margin-top: 10px;
}
.dialog-close-button:hover {
transform: rotate(90deg);
-webkit-transition: -webkit-transform .2s ease-in-out;
transition: transform .2s ease-in-out;
}
.glink.nturl {
	margin-right: 5px;
}

.swiper-zoom-container img {
	background-color: white;
}

/*OMG Responsive Time*/
@media(max-width:480px) {
	.elementor embed, .elementor iframe, .elementor object, .elementor video {
		height: auto;
	}
.tg-nav-under .tg-filter-name {
    padding-left: 5px !important;
    padding-right: 5px !important;
}
	.tg-filters-holder {
		margin: 0 0px !important;
	}
	.tg-grid-area-top2 .tg-dropdown-holder {
	padding: 0 5px;
}
}
@media(max-width:767px) {
	.js-wpv-view-layout .col-md-2 {
		-ms-flex: 0 0 30.666667%;
flex: 0 0 30.666667%;
max-width: 30.666667%;
	}
    .js-wpv-view-layout .col-md-2:first-child {
        margin-left: 10px;
    }
	.tg-grid-area-top2 .tg-dropdown-holder {
	padding: 0 10px;
}
}
@media(max-width:979px) {}
@media(min-width:980px) and (max-width:1200px) {}

add_action('admin_init', function () {
	// Redirect any user trying to access comments page
	global $pagenow;

	if ($pagenow === 'edit-comments.php' || $pagenow === 'options-discussion.php') {
		wp_redirect(admin_url());
		exit;
	}

	// Remove comments metabox from dashboard
	remove_meta_box('dashboard_recent_comments', 'dashboard', 'normal');

	// Disable support for comments and trackbacks in post types
	foreach (get_post_types() as $post_type) {
		if (post_type_supports($post_type, 'comments')) {
			remove_post_type_support($post_type, 'comments');
			remove_post_type_support($post_type, 'trackbacks');
		}
	}
});

// Close comments on the front-end
add_filter('comments_open', '__return_false', 20, 2);
add_filter('pings_open', '__return_false', 20, 2);

// Hide existing comments
add_filter('comments_array', '__return_empty_array', 10, 2);

// Remove comments page in menu
add_action('admin_menu', function () {
  remove_menu_page('edit-comments.php');
	remove_submenu_page('options-general.php', 'options-discussion.php');
});

// Remove comments links from admin bar
add_action('init', function () {
	if (is_admin_bar_showing()) {
		remove_action('admin_bar_menu', 'wp_admin_bar_comments_menu', 60);
	}
});

// Remove comments icon from admin bar
add_action('wp_before_admin_bar_render', function() {
	global $wp_admin_bar;
	$wp_admin_bar->remove_menu('comments');
});

// Return a comment count of zero to hide existing comment entry link.
function zero_comment_count($count){
	return 0;
}
add_filter('get_comments_number', 'zero_comment_count');

// Multisite - Remove manage comments from admin bar
add_action( 'admin_bar_menu', 'remove_toolbar_items', PHP_INT_MAX -1 );
function remove_toolbar_items( $bar )
{
	$sites = get_blogs_of_user( get_current_user_id() );
	foreach ( $sites as $site )
	{
		$bar->remove_node( "blog-{$site->userblog_id}-c" );
	}
}