<?php get_header(); ?>
<?php
    
    thebuilders_ninzio_global_variables();

    $nz_rh_version      = (isset($GLOBALS['thebuilders_ninzio']['rh-version']) && !empty($GLOBALS['thebuilders_ninzio']['rh-version'])) ? $GLOBALS['thebuilders_ninzio']['rh-version'] : 'version1'; 
    $nz_header_version  = (isset($GLOBALS['thebuilders_ninzio']['header-version']) && !empty($GLOBALS['thebuilders_ninzio']['header-version'])) ? $GLOBALS['thebuilders_ninzio']['header-version'] : 'version1';

    $styles             = "";
    $styles_fp          = "";

    $styles_title       = "";
    $styles_breadcrumbs = "";

    $nz_text_color                = (isset( $GLOBALS['thebuilders_ninzio']['tech-text-color']) && !empty($GLOBALS['thebuilders_ninzio']['tech-text-color'])) ? $GLOBALS['thebuilders_ninzio']["tech-text-color"] : "";
    $nz_back_color                = (isset( $GLOBALS['thebuilders_ninzio']['tech-back']['background-color']) && !empty($GLOBALS['thebuilders_ninzio']['tech-back']['background-color'])) ? $GLOBALS['thebuilders_ninzio']["tech-back"]['background-color'] : "#333333";
    $nz_back_img                  = (isset( $GLOBALS['thebuilders_ninzio']['tech-back']['background-image']) && !empty($GLOBALS['thebuilders_ninzio']['tech-back']['background-image'])) ? $GLOBALS['thebuilders_ninzio']['tech-back']["background-image"] : "";
    $nz_back_img_repeat           = (isset( $GLOBALS['thebuilders_ninzio']['tech-back']['background-repeat']) && !empty($GLOBALS['thebuilders_ninzio']['tech-back']['background-repeat'])) ? $GLOBALS['thebuilders_ninzio']['tech-back']['background-repeat'] : "no-repeat";
    $nz_back_img_position         = (isset( $GLOBALS['thebuilders_ninzio']['tech-back']['background-position']) && !empty($GLOBALS['thebuilders_ninzio']['tech-back']['background-position'])) ? $GLOBALS['thebuilders_ninzio']['tech-back']['background-position'] : "left top";
    $nz_back_img_attachment       = (isset( $GLOBALS['thebuilders_ninzio']['tech-back']['background-attachment']) && !empty($GLOBALS['thebuilders_ninzio']['tech-back']['background-attachment'])) ? $GLOBALS['thebuilders_ninzio']['tech-back']['background-attachment'] : "scroll";
    $nz_back_img_size             = (isset( $GLOBALS['thebuilders_ninzio']['tech-back']['background-size']) && !empty($GLOBALS['thebuilders_ninzio']['tech-back']['background-size'])) ? $GLOBALS['thebuilders_ninzio']['tech-back']['background-size'] : "auto";
    $nz_breadcrumbs_text_color    = (isset( $GLOBALS['thebuilders_ninzio']['tech-breadcrumbs-text-color']) && !empty($GLOBALS['thebuilders_ninzio']['tech-breadcrumbs-text-color'])) ? $GLOBALS['thebuilders_ninzio']["tech-breadcrumbs-text-color"] : "#ffffff";
    $nz_tech_rh_text_border_color = (isset( $GLOBALS['thebuilders_ninzio']['tech-text-border-color']['color']) && !empty($GLOBALS['thebuilders_ninzio']['tech-text-border-color']['color'])) ? thebuilders_ninzio_hex_to_rgba($GLOBALS['thebuilders_ninzio']["tech-text-border-color"]['color'],$GLOBALS['thebuilders_ninzio']["tech-text-border-color"]['alpha']) : "rgba(255,255,255,0.1)";
    $nz_parallax                  = (isset( $GLOBALS['thebuilders_ninzio']['tech-parallax']) && $GLOBALS['thebuilders_ninzio']['tech-parallax'] == 1) ? "true" : "false";

    if (!empty($nz_back_color)) {$styles .= 'background-color:'.$nz_back_color.';';}
    if (!empty($nz_text_color)) {$styles .= 'color:'.$nz_text_color.';';}
    if (!empty($nz_back_img)) {

        if ($nz_parallax != "true" && $nz_back_img_attachment != "fixed") {
            $styles .= 'background-image:url('.$nz_back_img.');';
            $styles .= 'background-repeat:'.$nz_back_img_repeat.';';
            $styles .= 'background-position:'.$nz_back_img_position.';';
            if ($nz_back_img_size == "cover") {$styles .= '-webkit-background-size: cover;-moz-background-size: cover;background-size: cover;';}
        }

        if ($nz_parallax == "true" || $nz_back_img_attachment == "fixed") {

            $nz_back_img_repeat     = "no-repeat";
            $nz_back_img_size       = "cover";

            $styles_fp .= 'background-image:url('.$nz_back_img.');';
            $styles_fp .= 'background-repeat:'.$nz_back_img_repeat.';';
            $styles_fp .= 'background-position:'.$nz_back_img_position.';';
        }

        if ($nz_parallax == "true") {$nz_back_img_attachment = "scroll";}

    }

    if (!empty($nz_breadcrumbs_text_color)) {
        $styles_breadcrumbs .= 'color:'.$nz_breadcrumbs_text_color.';';
    }

    if ($nz_rh_version == "version2") {

        if (!empty($nz_tech_rh_text_border_color)) {
            $styles_title .= 'box-shadow:inset 0 0 0 3px '.$nz_tech_rh_text_border_color.';';
        }

    }
?>
<?php if ($nz_rh_version != "none"): ?>
	<header class="rich-header page-header <?php echo esc_attr($nz_rh_version); ?>" data-parallax="<?php echo esc_attr($nz_parallax); ?>" style="<?php echo esc_attr($styles); ?>">
		<?php if ($nz_parallax == "true"): ?>
			<div class="parallax-container" style="<?php echo esc_attr($styles_fp); ?>">&nbsp;</div>
		<?php endif ?>
		<?php if ($nz_back_img_attachment == "fixed"): ?>
			<div class="fixed-container" style="<?php echo esc_attr($styles_fp); ?>">&nbsp;</div>
		<?php endif ?>
		<div class="container nz-clearfix">

			<?php if ($nz_rh_version == "version1"): ?>
				<div class="rh-content">
					<h1 style="<?php echo esc_attr($styles_title); ?>"><?php echo esc_html__('404 Error page', 'thebuilders'); ?></h1>				
                    <div style="<?php echo esc_attr($styles_breadcrumbs); ?>" class="nz-breadcrumbs nz-clearfix"><?php thebuilders_ninzio_breadcrumbs(); ?></div>
				</div>
			<?php elseif ($nz_rh_version == "version2"): ?>
				<div class="rh-content">
					<h1 style="<?php echo esc_attr($styles_title); ?>"><?php echo esc_html__('404 Error page', 'thebuilders'); ?></h1>				
				</div>
			<?php endif ?>

		</div>
	</header>
<?php endif ?>
<div id="nz-content" class='content nz-clearfix padding-true'>
	<div class='container'>
		<div class="error404-wrap">
			<div class="error404-big">404</div>
			<h3 class="error404-title"><?php echo esc_html__("Page not found", 'thebuilders'); ?></h3>
			<a class="button button-normal grey_light full-false medium square animate-false anim-type-ghost hover-fill" href="<?php echo esc_url(home_url('/')); ?>" target="_self"><span class="txt"><?php echo esc_html__('Goto homepage', 'thebuilders'); ?></span></a>
		</div>
	</div>
</div>
<!-- container end -->
<?php get_footer(); ?>
