<?php include '../config.php'; ?>
<style>

/* MENÚ INFERIOR */

		nav.menu {
	background: transparent;
	position: relative;
	/*min-height: 45px;*/
	height: 100%;
	margin-top: 90px;		
}

.menu > ul > li {
	list-style: none;
	display: inline-block;
	color: #2b4365;
	/*line-height: 45px;*/
	
}
.menu > ul li a, .xs-menu li a {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    color: #fff;
    font-size: 12px;
    text-decoration: none;
    color: #2b4365;
    display: block;
    padding: 5px 18px;
}
.menu > ul li a:hover {
	background: transparent;
	color: #48aa42;
	transition-duration: 0.3s;
	-moz-transition-duration: 0.3s;
	-webkit-transition-duration: 0.3s;
}
.active{
	color:#48aa42 !important;
	
}
.displaynone{
	display: none;
}
.xs-menu-cont{
display:none;
}
.xs-menu-cont > a {
    background: none repeat scroll 0 0 #ff7f50;
    border-radius: 3px;
    padding: 3px 6px;
	display: block;
	border-bottom:1px solid #E67248;
	    box-shadow: 0 1px 2px #e67248;
		-webkit-box-shadow: 0 1px 2px #e67248;
		-moz-box-shadow: 0 1px 2px #e67248;
}
.xs-menu-cont > a:hover{
 cursor: pointer;
}
  
.xs-menu li {
color: #fff;
padding: 14px 30px;
border-bottom: 1px solid #ccc;
background: #FF7F50;

}
.xs-menu  a{
text-decoration:none;
}

.mega-menu {
   background: none repeat scroll 0 0 #fff;
    left: 0;
    margin-top: 3px;
    position: absolute;
    width: 100%;
	padding:15px;
	display:none;
	 transition-duration: 0.9s;
	-webkit-box-shadow: 0px 7px 6px 0px rgba(0,0,0,0.33);
-moz-box-shadow: 0px 7px 6px 0px rgba(0,0,0,0.33);
box-shadow: 0px 7px 6px 0px rgba(0,0,0,0.33);
	z-index: 9999;
	line-height: 2rem;
    
}
#menutoggle i {
    font-size: 23px;
    margin: 0;
    padding: 0;
}

	/*--column--*/
.mm-6column:after, .mm-6column:before, .mm-3column:after, .mm-3column:before{
content:"";
display:table;
clear:both;


}
.mm-6column, .mm-3column {
 float: left;
 position: relative;
 }
.mm-6column {
    width: 50%;
}
.mm-3column {
        width: 25%;
}
.responsive-img {
    display: block;
    max-width: 100%;

}
.left-images{
margin-right:25px;
}
 .left-images, .left-categories-list {
   float: left;
}
.categories-list li {
    display: block;
    line-height: normal;
    margin: 0;
    padding: 5px 0;
}
.categories-list li :hover{
		background:inherit !important;
}
.left-images > p {
    background: none repeat scroll 0 0 #ff7f50;
    display: block;
    font-size: 18px;
    line-height: normal;
    margin: 0;
    padding: 5px 14px;
}
.categories-list span {
    font-size: 18px;
    padding-bottom: 5px;
    text-transform: uppercase;
}
.mm-view-more{
	background: none repeat scroll 0 0 #ff7f50;
    color: #fff;
    display: inline !important;
    line-height: normal;
    padding: 5px 8px !important;
	margin-top:10px;
}
.display-on{
display:block;
 transition-duration: 0.9s;
}
.drop-down > a:after{
content:"\f0d7";
font-family: FontAwesome;
color:#48aa42;	
font-style: normal;
margin-left: 5px; 
 

}
 /*MediaQuerys*/
 @media (max-width: 600px) {

 .xs-menu li a {

	 padding:0px;
}
 .xs-menu-cont{
 display:block ;
 }
 }


/*Animation--*/

.animated {
  -webkit-animation-duration: 1s;
  animation-duration: 1s;
  -webkit-animation-fill-mode: both;
  animation-fill-mode: both;
}
@-webkit-keyframes fadeIn {
  0% {
    opacity: 0;
  }

  100% {
    opacity: 1;
  }
}

@keyframes fadeIn {
  0% {
    opacity: 0;
  }

  100% {
    opacity: 1;
  }
}

.fadeIn {
  -webkit-animation-name: fadeIn;
  animation-name: fadeIn;
}

/* END MENÚ INFERIOR */
.mega-menu.fadeIn.animated a {
	width: 33%;
}
	
</style>

<!-- Navigation-->
        <nav class="navbar navbar-expand-lg navbar-dark fixed-top" id="mainNav">
            <div class="container">
                <a class="navbar-brand js-scroll-trigger" href="/indeval/"><img src="<?php echo $logoIndeval; ?>" alt="" /></a>
                <button class="navbar-toggler navbar-toggler-right" type="button" data-toggle="collapse" data-target="#navbarResponsive" aria-controls="navbarResponsive" aria-expanded="false" aria-label="Toggle navigation">
                    Menu
                    <i class="fas fa-bars ml-1"></i>
                </button>
                <div class="collapse navbar-collapse" id="navbarResponsive">
                  <ul class="navbar-nav ml-auto">
                        <li class="nav-item"><a class="nav-link js-scroll-trigger" href="#services">Búsqueda
						<span>
                            <i class="fas fa-search"></i>
                        </span>
							</a></li>
						<li class="nav-item"><a class="nav-link js-scroll-trigger" href="#contact">Contáctanos
						<span>
                            <i class="far fa-envelope"></i>
                        </span>
							</a></li>
                            
                    </ul>
                </div>
                

		</div>
			
    </nav>
		
		<div class="container">
		
						<div class="xs-menu-cont">
			<a id="menutoggle"><i class="fa fa-align-justify"></i> </a>
				
			</div>
			<nav class="menu text-center">
				<ul>

                <?php
                
                    
                    foreach ($array['data']['enlacesMenuSuperior'] as $item) {
                     

                            foreach ($item['localizations'] as $subitem) {

                                if($subitem['tituloEnlace'] == 'Productos y Servicios'){
                                    echo '
                                    <li class="drop-down">
                                        <a href="'.$subitem['enlace'].'">'.$subitem['tituloEnlace'].'</a>
                                    
                                        <div class="mega-menu fadeIn animated">
                                            
                                        <div class="container">
                                            <div class="row text-left">
                                                <div class="col-md-12">
                                                    <h6>Productos</h6>
                                                    <hr>
                                                </div>
                                                ';
                                                foreach ($array['data']['enlacesMenuSuperior'] as $item2) {
                                                    foreach ($item2['localizations'] as $subitem2) {
                                                        if($item2['padre']=='Productos'){
                                                            echo '
                                                            <a href="'.$subitem2['enlace'].'">'.$subitem2['tituloEnlace'].'</a>
                                                            ';
                                                        }
                                                    }
                                                }
                                                echo'<br>
                                                
                                                <div class="col-md-12">
                                                    <h6>Servicios</h6>
                                                    <hr>
                                                </div>
                                                ';
                                                foreach ($array['data']['enlacesMenuSuperior'] as $item2) {
                                                    foreach ($item2['localizations'] as $subitem2) {
                                                        if($item2['padre']=='Servicios'){
                                                            echo '
                                                            <a href="'.$subitem2['enlace'].'">'.$subitem2['tituloEnlace'].'</a>
                                                            ';
                                                        }
                                                    }
                                                }
                                                
                                                echo'						
                                            </div>	
                                        </div>
                                    </div>
                            
                                    </li>
                                ';
                                }
                                else{

                                    if(strlen($item['padre'])<2){
                                        echo '
                                        <li>
                                                <a href="'.$subitem['enlace'].'">'.$subitem['tituloEnlace'].'</a>
                                            </li>
                                        ';

                                    }
                                    
                                }
                                
                            }
                        }
                        
                    
                ?>
				</ul>
			</nav>
			
		</div>