*, *:after, *:before {
	-webkit-box-sizing: border-box;
	-moz-box-sizing: border-box;
	box-sizing: border-box;
}

.title {
  display: -webkit-flex;
	display: -ms-flex;
	display: flex;

  -webkit-flex-wrap: wrap;
	-ms-flex-wrap: wrap;
	flex-wrap: wrap;

  margin: 0rem 2rem;
}

.container {
  display: -webkit-flex;
	display: -ms-flex;
	display: flex;

  -webkit-flex-wrap: wrap;
	-ms-flex-wrap: wrap;
	flex-wrap: wrap;

  -webkit-justify-content: space-around;
	-ms-justify-content: space-around;
	justify-content: space-around;

  margin: 0rem 2rem;
}

.main-nav {
  -webkit-flex: 1 1 5em;
	-ms-flex: 1 1 5em;
	flex: 1 1 5em;
}

.page-content {
  -webkit-flex: 2 2 15em;
	-ms-flex: 2 2 15em;
	flex: 2 2 15em;

  margin: 0rem 2rem;
}

/*MAIN NAV*/
.main-nav-container{

  display: -webkit-flex;
	display: -ms-flex;
	display: flex;

	-webkit-flex-wrap: wrap;
	-ms-flex-wrap: wrap;
	flex-wrap: wrap;

/*how to place the child elements*/
	-webkit-justify-content: flex-start;
	-ms-justify-content: flex-start;
	justify-content: flex-start;

}

.nav-item-structure{
	flex-basis:100%;
	text-align:center;
}

/*PRODUCT LISTING*/

.product-text {
  text-align:center;
}

.product-content{
  flex-direction: column;

  display: -webkit-flex;
  display: -ms-flex;
  display: flex;

  -webkit-flex-wrap: wrap;
  -ms-flex-wrap: wrap;
  flex-wrap: wrap;

  -webkit-justify-content: space-around;
  -ms-justify-content: space-around;
  justify-content: space-around;

  margin: 0rem 1.5rem;
  margin-bottom: 2rem;
}

.product-small-item-container {

  display: -webkit-flex;
  display: -ms-flex;
  display: flex;

  -webkit-flex-wrap: wrap;
  -ms-flex-wrap: wrap;
  flex-wrap: wrap;

  -webkit-justify-content: flex-start;
  -ms-justify-content: flex-start;
  justify-content: flex-start;

  margin: 0rem 0.5rem;
  margin-bottom: 2rem;
}

.product {
  position:relative;
  display: inline-block;
  flex-basis: 100%;
  text-align:center;
  overflow:hidden;
}

.product:before {
  position:absolute;
  display: block;
  content: ' ';
  opacity:0.3;
  z-index:-1;
  background-image: url("../image/product-img.jpg");
  background-size: cover;
  background-repeat: no-repeat;
  left:0;
  top:0;
  width: 100%;
  height: 100%;
}

.product-description{
  max-width:85%;
  text-align: left;
  margin: 0.8rem 1.5rem;
}

.product-small-item{
  display: inline-block;
  flex-basis:100%;
}


/*Old Code*/
/* .product-container{

  display: -webkit-flex;
  display: -ms-flex;
  display: flex;

  -webkit-flex-wrap: wrap;
  -ms-flex-wrap: wrap;
  flex-wrap: wrap;

  -webkit-justify-content: space-around;
  -ms-justify-content: space-around;
  justify-content: space-around;

}

.product-item{
  flex-basis:100%;
} */

/*Grid Structure block*/
.block {
  -ms-flex-grow: 1;
  flex-grow: 1;
}

/* media queries for product postings */
@media(min-width:56.25em){

  .product {
    margin: 0.5rem 6rem;
    text-align:right;
  }

  .product-text{
    max-width:70%;
    text-align:left;
    margin-left: 3rem;
  }

  .product-description{
    max-width:85%;
    margin: 0 6rem;
    text-align:left;
    margin-bottom:2rem;
  }


  .normal-button{
    margin-right:3rem;
  }

}

/*GRID FOR THE MAIN NAV*/
@media(min-width:37.5em) and (max-width:53.12em){

  .nav-item-structure{
    flex-basis:50%;
  }

  .product-item{
    flex-basis:50%;
  }

}

@media(min-width:53.12em){

  .nav-item-structure{
    flex-basis:20%;
  }

  .product-item{
    flex-basis:40%;
  }

}
