* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  --mainColor: #541B0B;
  font-size: 16px;
}

html {
  scroll-behavior: smooth;
  font-family: "Mulish";
  font-size: 16px;
}

/* encabezado */
/*header {
  width: 90%;
  margin: 0 auto;
  height: auto;
  background-image: url(../imagenes/headerNuevo.png);
  background-repeat: no-repeat;
  background-size: cover;
  background-attachment: fixed;
}

.nombre{
  text-align: center;
  color: #F5F5FA;
  font-weight: bold;
  font-family: "MulishBlack";
  padding-top: 100px;
  padding-bottom: 10px;
  font-size: 3rem;
}

#home>p{
  color: #F5F5FA;
  padding:20px;
  padding-left: 20%;
  padding-right: 20%;
  padding-bottom: 100px;
  text-align: center;
  font-size: 1.1rem;
}
*/

h2{
  padding-left: 2%;
}

/* barra de navegación */
.topnav {
  width: 90%;
  height: 100px;
  background-color: white;
  box-shadow: 5px 5px 8px rgba(0, 0, 0, 0.500);
  margin: 0 auto;
  overflow: hidden;
  position: sticky;
  top: 0;
  z-index: 5;

  display: flex;
  justify-content: space-evenly;
}

#myTopnav>a>img{
 width:20%;
 display: block;
}

.button {
  color: var(--mainColor);
}

.topnav a {
  float: left;
  display: block;
  color: #121921;
  text-align: center;
  padding: 14px 16px;
  text-decoration: none;
  font-size: 18px;
  align-self: center;
}

.topnav a:hover:not(:first-child) {
  background-color: #e2e2e2;
  color: var(--mainColor)
}

.topnav a.active {
  text-decoration: underline var(--mainColor) 2px;
  text-underline-offset: 5px;
}

.topnav .icon {
  display: none;
}

.topnav a:active, .topnav a:visited{
  text-decoration: underline var(--mainColor) 2px;
  text-underline-offset: 5px;
}

@media screen and (max-width: 700px) {
  .topnav {
    height:auto;
    justify-content: space-between;
  }

  .topnav a:not(:first-child) {
    display: none;
  }

  .topnav a.icon {
    float: right;
    display: block;
    padding: 12px 16px;
  }

  #logo{
    width:50%;
  }
}

@media screen and (max-width: 700px) {
  .topnav.responsive {
    flex-direction: column;
  }

  .topnav.responsive .icon {
    position: absolute; 
    right: 0;
    top: 7px;
  }

  .topnav.responsive a {
    float: none;
    display: block;
    text-align: left;
  }

  .topnav.responsive #logo{
    margin-left: 35%;
  }
}

/* sección de inicio */
.inicio {
  width: 90%;
  margin: 0 auto;
}

.main-section {
  width: 90%;
  margin: 0 auto;
  margin-top: 30px;
  padding-top: 65px;
}

/* nosotros */
.vision {
  width: 100%;
  height: auto;
  display: flex;
  margin-right: auto;
  margin-left: auto;
  flex-direction: column;
  box-shadow: rgba(0, 0, 0, 0.02) 0px 1px 3px 0px, rgba(27, 31, 35, 0.15) 0px 0px 0px 1px;
}

.about-img {
  flex-basis: 30%;
  height: auto;
}

/* sección de producto */
.producto {
  width: 100%;
  margin: 0 auto;
  height: auto;
  display: flex;
  justify-content: space-evenly;
  flex-wrap: wrap;
  margin-bottom: 30px;
}

.tarima {
  width: 50%;
  height: 250px;
  margin-top: 20px;
  display: flex;
  justify-content: space-evenly;
  align-items: center;
  border-bottom: var(--mainColor) solid 4px;
}

.foto {
  width: 45%;
  height: 150px;
  text-align: center;
}

.texto {
  width: 45%;
  height: auto;
}

/* footer */

footer {
  width: 90%;
  height: auto;
  background-color: var(--mainColor);
  color: #caa7a7;
  padding: 20px;
  margin: 0 auto;
}

.footer-sec a {
  color: #caa7a7;
  text-decoration: none;
  display: block;
}

.footer-sec a:hover {
  color: #a35c5c;
  text-decoration: underline;
}

.politica {
  width: 100%;
  height: auto;
  background-color: #380000;
  color: #caa7a7;
  padding: 30px;
  box-shadow: 10px 10px 15px rgba(0, 0, 0, 0.500);
  z-index: 2;
  display: none;
  overflow: hidden;
}

.pol-1 {
  float: left;
}

.imagen {
  width: 20%;
  text-align: center;
}

.texto-pol {
  width: 60%;
}

.cerrar {
  position: relative;
  width: 10%;
  float: right;
}

.politica .imagen img {
  filter: invert(1) opacity(50%);
  width: 80%;
}

.cerrar .fa {
  position: absolute;
  top: 0;
  right: 0;
}

.show {
  display: block;
}

/* grid-area */

.item1 {
  grid-area: header;
}

.item2 {
  grid-area: menu;
}

.item3 {
  grid-area: main;
}

.item4 {
  grid-area: right;
}

.item5{
  grid-area: footer;
}

.parent {
  display: grid;
  grid-template-areas:
    'header main right'
    'menu menu menu'
    'footer footer footer';
  grid-template-columns: 30% 30% 30%; 
  /*grid-template-rows: auto auto auto;*/
  gap: 5%;
}

/* formulario */

legend>h4{
  text-align: center;
}

/* Botón para abrir la forma de contacto*/
.boton {
background-color: white;
color: var(--mainColor);
padding: 16px 20px;
border: none;
cursor: pointer;
opacity: 0.8;
width: 100%;
margin-bottom: 40px;
}

/* Forma desplegable */
.forma {
display: none;
border: 3px solid #f1f1f1;
margin-bottom: 130px;

}
.show{
  display: block;
}

/* estilo del contenedor del formulario */
.contenedor-forma {
width: 100%;
padding: 2%;
background-color: white;
}

/* estilos de los inputs */
.contenedor-forma input[type=text], .contenedor-forma input[type=email], .contenedor-forma textarea[name=mensaje] {
width: 100%;
padding: 15px;
margin: 5px 0 22px 0;
border: none;
background: #f1f1f1;
}

/* inputs con el selector en el enfoque */
.contenedor-forma input[type=text]:focus, .contenedor-forma input[type=email]:focus, .contenedor-forma textarea[name=mensaje]:focus {
background-color: #ccbbb6;
outline: none;
}

/* estilo para el boton de envio */
.contenedor-forma .btn {
background-color: var(--mainColor);
color: white;
padding: 16px 20px;
border: none;
cursor: pointer;
width: 100%;
margin-bottom:10px;
opacity: 0.8;
}


@media screen and (max-width: 1200px) {
  .tarima {
    width: 80%;
    height: auto;
    margin-top: 20px;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-evenly;
    align-items: center;
  }

  .foto {
    width: 80%;
    height: 150px;
    text-align: center;
  }

  .texto {
    width: 80%;
    height: auto;
    margin-bottom: 40px;
  }
}

@media screen and (max-width: 1024px) {
  .vision {
    flex-direction: column;
  }

  .about-img {
    width: 50%;
    margin-left: 25%;
    margin-bottom: 20px;
    height: auto;
    border-bottom: var(--mainColor) 4px solid;
  }
}

@media screen and (max-width: 800px) {
  .parent {
    display: grid;
    grid-template-columns: auto;
    /* auto es el width, hay que cambiarlo */
    grid-template-rows: auto auto auto;
    gap: 10px;
  }

  .div-1 {
    grid-column-start: 1;
    grid-column-end: 4;
  }

  .boton{
    margin-bottom: 0;
  }

  .forma{
    margin-bottom: 0;
  }
}

@media screen and (max-width: 730px) {
  .parent {
    grid-template-areas:
      'header'
      'main'
      'right'
      'menu'
      'footer';
  }

  .nombre{
    font-size: 2.5rem;
  }
}

@media screen and (max-width: 480px) {
  header {
    width: 100%;
  }

  .topnav {
    width: 100%;
  }

  .inicio {
    width: 100%;
  }

  .tarima {
    width: 90%;
  }

  .main-section {
    width: 100%;
    margin: 0;
  }

  .nosotros {
    width: 100%;
  }

  footer {
    width: 100%;
  }
}

.img-toggle {
  background-color: white;
  width: 90%;
  margin-left: auto;
  margin-right: auto;
  margin-top: 15px;
  margin-bottom: 15px;
  overflow: hidden;
  box-shadow: rgba(0, 0, 0, 0.16) 0px 3px 6px, rgba(0, 0, 0, 0.23) 0px 3px 6px;
  transition: 1s;
  cursor: pointer;
}

.img-toggle:hover {
  box-shadow: rgba(0, 0, 0, 0.05) 0px 0px 0px 1px, rgb(209, 213, 219) 0px 0px 0px 1px inset;
}

.min-size {
  height: 80px;
}

.max-size {
  height: 230px;
}

.img>img {
  width: 100%;
}

@media screen and (min-width:320px) {
  .min-size {
      min-height: 80px;
  }

  .max-size {
      min-height: 260px;
  }
}

@media screen and (min-width:350px) {
  .min-size {
      min-height: 90px;
  }

  .max-size {
      min-height: 280px;
  }
}

@media screen and (min-width:380px) {
  .min-size {
      min-height: 100px;
  }

  .max-size {
      min-height: 300px;
  }
}

@media screen and (min-width:410px) {
  .min-size {
      min-height: 110px;
  }

  .max-size {
      min-height: 320px;
  }
}

@media screen and (min-width:440px) {
  .min-size {
      min-height: 120px;
  }

  .max-size {
      min-height: 340px;
  }
}

/*se rompió el patrón de aumentarle 30, 20 y 10px :^) *llora en perfeccionista* */

@media screen and (min-width:470px) {
  .max-size {
      min-height: 360px;
  }
}

@media screen and (min-width:500px) {
  .min-size {
      min-height: 125px;
  }

  .max-size {
      min-height: 380px;
  }
}

@media screen and (min-width:530px) {
  .min-size {
      min-height: 135px;
  }

  .max-size {
      min-height: 400px;
  }
}

@media screen and (min-width:570px) {
  .min-size {
      min-height: 145px;
  }

  .max-size {
      min-height: 420px;
  }
}

@media screen and (min-width:600px) {
  .min-size {
      min-height: 155px;
  }

  .max-size {
      min-height: 440px;
  }
}

@media screen and (min-width:630px) {
  .min-size {
      min-height: 165px;
  }

  .max-size {
      min-height: 460px;
  }
}

@media screen and (min-width:660px) {
  .min-size {
      min-height: 175px;
  }

  .max-size {
      min-height: 480px;
  }
}

@media screen and (min-width:690px) {
  .min-size {
      min-height: 185px;
  }

  .max-size {
      min-height: 500px;
  }
}

/* tablet */

@media screen and (min-width:720px) {

  /* #contenedor-imgs{
      flex-direction: row;
  } */
  .img-toggle {
      width: 50%;
      height: auto;
      cursor: default;
  }

  .min-size {
      min-height: auto;
  }
}

/* desktop */

@media screen and (min-width:900px) {
 .vision {
      flex-direction: row;
  }

  .img-toggle {
      margin-left: 1%;
      margin-right: 1%;
  }
}

/* confirma */

#confirma{
  width:90%;
  display: flex;
  flex-direction: column;
  text-align: center;
  margin-top: 55px;
  margin-right: auto;
  margin-left: auto;
  margin-bottom: 55px;
  box-shadow: rgba(0, 0, 0, 0.02) 0px 1px 3px 0px, rgba(27, 31, 35, 0.15) 0px 0px 0px 1px;
}

#confirma>h2{
  padding-top:60px;
}

#confirma>img{
  max-width: 15%;
  margin-top: 30px;
  margin-right: auto;
  margin-left: auto;
  margin-bottom: 30px;
}

#confirma>p{
  margin-bottom: 100px;
}

#confirma>p>a{
  text-decoration: none;
  color: var(--mainColor);
  padding:10px;
}

#confirma>p>a:hover{
  background-color: #e2e2e2;
}

@media screen and (max-width:600px){
  #confirma>img{
    max-width:20%;
  }
}

@media screen and (max-width:400px){
  #confirma>img{
    max-width:25%;
  }
}