* {
  margin: 0;
  padding: 0;
}

body {
  background-color: #373f48;
  font-family: Montserrat;
}

.main-container {
  display: grid;
  height: 100vh;
  grid-template-rows: 1fr 1fr 9fr 1fr;
  grid-template-areas:
    "nav"
    "header"
    "main"
    "footer";
}

nav {
  grid-area: nav;
  display: flex;
  justify-content: center;
  align-items: center;
  background-image: linear-gradient(
    to top,
    #d5d4d0 0%,
    #d5d4d0 1%,
    #eeeeec 31%,
    #efeeec 75%,
    #e9e9e7 100%
  );
  color: rgb(67, 69, 74);
}

nav img {
  width: 100px;
}

nav a {
  color: #373f48;
  font-size: 16px;
  text-decoration: none;
  padding: 5px;
  transition: color 0.3s ease-in;
}

a:hover {
  color: rgb(216, 145, 94);
}

header {
  grid-area: header;
  justify-content: center;
  align-items: center;
  background-image: url(../img/headerpr.png);
  background-size: cover;
}

header h1 {
  color: #fdf6e8;
  text-shadow: 3px 3px 5px rgba(0, 0, 0, 0.5);
  font-size: 40px;
  justify-content: center;
  text-align: center;
  padding-top: 110px;
}

header p {
  color: #fdf6e8;
  text-shadow: 3px 3px 5px rgba(0, 0, 0, 0.5);
  font-size: 25px;
  font-weight: normal;
  text-align: center;
  padding: 10px 30px 20px 30px;
}

main {
  grid-area: main;
  display: grid;
  grid-column: 1fr;
  background-image: url(../img/hueá\ javi.png);
  background-size: cover;
}

.article1 {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.article2 {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.flip-card {
  background-color: transparent;
  width: 300px;
  height: 300px;
  perspective: 1000px;
  margin: 20px;
  display: flex;
}

.flip-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  text-align: center;
  transition: transform 0.8s;
  transform-style: preserve-3d;
}

.flip-card:hover .flip-card-inner {
  transform: rotateY(180deg);
}

.flip-card-front1 {
  position: absolute;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  border-radius: 10px;
  box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2);
  display: flex;
  justify-content: center;
  align-items: center;
  color: #fdf6e8;
  text-shadow: 3px 3px 5px rgba(0, 0, 0, 0.5);
  background-image: url(../img/laminaspr.jpg);
  background-size: cover;
}

.flip-card-front2 {
  position: absolute;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  border-radius: 10px;
  box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2);
  display: flex;
  justify-content: center;
  align-items: center;
  color: #fdf6e8;
  text-shadow: 3px 3px 5px rgba(0, 0, 0, 0.5);
  background-image: url(../img/puertaspr.jpg);
  background-size: cover;
}

.flip-card-front3 {
  position: absolute;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  border-radius: 10px;
  box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2);
  display: flex;
  justify-content: center;
  align-items: center;
  color: #fdf6e8;
  text-shadow: 3px 3px 5px rgba(0, 0, 0, 0.5);
  background-image: url(../img/marcospr.jpg);
  background-size: cover;
}

.flip-card-front4 {
  position: absolute;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  border-radius: 10px;
  box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2);
  display: flex;
  justify-content: center;
  align-items: center;
  color: #fdf6e8;
  text-shadow: 3px 3px 5px rgba(0, 0, 0, 0.5);
  background-image: url(../img/cristalpr.jpg);
  background-size: cover;
}

.flip-card-front5 {
  position: absolute;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  border-radius: 10px;
  box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2);
  display: flex;
  justify-content: center;
  align-items: center;
  color: #fdf6e8;
  text-shadow: 3px 3px 5px rgba(0, 0, 0, 0.5);
  background-image: url(../img/marcoal.jpg);
  background-size: contain;
}

.flip-card-front1 h2,
.flip-card-front2 h2,
.flip-card-front3 h2,
.flip-card-front4 h2,
.flip-card-front5 h2 {
  font-size: 28px;
  text-align: center;
  font-weight: normal;
  padding: 20px;
}

.flip-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  border-radius: 10px;
  box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2);
  display: flex;
  justify-content: center;
  align-items: center;
  color: #fdf6e8;
  background-image: linear-gradient(to right, #868f96 0%, #596164 100%);
  transform: rotateY(180deg);
}

.flip-card-back p {
  text-align: center;
  font-weight: lighter;
  padding: 20px;
}

section {
  display: flex;
  justify-content: center;
  align-items: center;
}

section h2 {
  color: #fdf6e8;
  font-size: 35px;
  margin-top: 35px;
  margin-bottom: 15px;
}

footer {
  grid-area: footer;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 10px;
  font-weight: lighter;
  background-image: linear-gradient(60deg, #29323c 0%, #485563 100%);
}

footer h3 {
  text-align: center;
  font-size: 15px;
  font-weight: lighter;
  color: #fdf6e8;
  padding-top: 10px;
}

footer p {
  text-align: center;
  color: #fdf6e8;
  margin-bottom: 0px;
}

.footer_contacto {
  margin-bottom: 10px;
}

footer a {
  color: #fdf6e8;
  text-decoration: none;
  transition: color 0.3s ease-in;
}

a:hover {
  color: rgb(216, 145, 94);
}

@media (min-width: 576px) {
  main {
    grid-area: main;
    display: grid;
    justify-content: center;
    align-items: center;
  }

  .article1 {
    display: grid;
    justify-content: center;
    align-items: center;
    grid-template-columns: 1fr 1fr 1fr;
    grid-template-rows: 1fr;
    gap: 5px;
  }
  
  .article2 {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 5px;
  }
}
