/* ----------Custom Properties---------- */
:root {
    --first-color: #e1bcfe;
    color: #3a3b45;
    --second-color: #494e5f; /* este color de post(#6e7692) es un poquito más claro, verde agua y lila */
    --black-color: #000;
    --white-color: #fff;
    --link-color: #438ccc;
    --white-alpha-color: rgba(255, 255, 255, 0.5);
    --black-alpha-color: rgba(0, 0, 0, 0.5);
    --font: 'Courier Prime', monospace;
    --max-width: 1200px;
    --header-height: 4rem;
}

html {
    box-sizing: border-box; /* El tamaño de la caja irá desde el borde no desde el contenido */ 
    font-family: var(--font);
    font-size: 16px;
    scroll-behavior: smooth; /* Para el efecto de transición que hay en el header, solo con css */
}

*,
*::after,
*::before {
    box-sizing: inherit; /* Que hereden el tamaño de caja, es decir del html */
}

body {
    margin: 0 auto;
    overflow-x: hidden; /* Con lo que desborda el contenedor, en x(horizontal) que oculte y evita la barra de desplazamiento */
    color: var(--second-color);
    max-width: 1440px; 
}

a {
    color: var(--link-color);
    transition: all 0.5s ease-out;
    font-size: 1.1rem;
}

a:hover {
    opacity: 0.75;
}

h1 {
    margin: 0;
    font-size: 2rem;
}

h2 {
    margin: 0;
    font-size: 1.5rem;
}

h3 {
    margin: 0;
    font-size: 1.25rem;
}

img {
    max-width: 100%; 
    height: auto;
}

p { 
    line-height: 1.6; /* Espacio interlineado */
    font-size: 1rem;
}

/* ----------Header---------- */
.header {
    position: fixed; /* estará fijo */
    left: 0;
    bottom: 0;
    z-index: 999;
    width: 100%;
    height: var(--header-height);
    padding: 1rem;
    background-color: var(--second-color);
}

.header__container {
    margin-left: auto;
    margin-right: auto;
    max-width: var(--max-width);
}

.header > .header__container { /* header container que es el hijo directo, por eso el mayor que */
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header__container__logo a {
    color: var(--first-color);
    font-family: var(--font-logo);
    font-weight: bold;
    font-size: 1rem; 
    text-decoration: none;
}

.header__container__menu__btn {
    outline: thin solid var(--second-color); /* Ese margen o linea que da el botón por defecto que sea delgado y sólido, con color */
    border: 0; /* borde por defecto */
    cursor: pointer;
    /* color */
    background-color: var(--second-color); 
}

.header__container__menu__btn svg {
    fill: var(--first-color);
}

.header__container__menu {
    background-color: var(--first-color);
    position: fixed;/* Al tener una posicion fixed pierde sus propiedades de ancho y alto */
    left: 0;
    bottom: var(--header-height);
    width: 100%;
    display: flex;
    flex-direction: column;
    pointer-events: none; /* si activamos o no la reacción a interactividad, porque por mas que la opacidad sea 0, al pasar sobre el elemento se ve la manito */
    opacity: 0; 
    transition: opacity 0.5s ease; /* transicion a la opacidad con efecto de aceleración normal */
}

.header__container__menu.is-active { /* Le añado una clase */
    opacity: 1;
    pointer-events: auto;
}
.header__container__menu a {
    padding: 1rem;
    font-size: 1.5rem;
    font-weight: bold;
    text-align: center;
    text-decoration: none;
    color: var(--second-color);
}
/* .header__container__menu a:hover {  hover en mobile?
    color: var(--first-color);
    background-color: var(--second-color);
} */

/* ----------Header - Media query---------- */
@media screen and (min-width: 1024px) {

    .header {
        /* sticky es una mezcla entre el posicionamiento relativo y el fijo, 
        y se comportará como elemento fijo a la altura que yo lo defina,
        y no se posiciona sobre ningun elemento */
        position: sticky; 
        top: 0;
        padding: 0.5rem; 
        height: calc(var(--header-height) - 0.5rem); /* se resta este 0.5rem al valor de la variable */
        background-color: var(--first-color);
    }

    .header__container__logo a {
        color: var(--second-color);
        font-size: 1rem;
    }

    .header__container__menu__btn {
        display: none;
    }

    .header__container__menu {
        position: static; /* vuelve a su valor normal */
        width: auto; /* se adapte al ancho que tengan los enlaces */
        flex-direction: row;
        opacity: 1;
        pointer-events: auto;
    }

    .header__container__menu a {
        padding: 0 1rem;
    }

    .header__container__menu a:last-child {
        padding-right: 0;
    }

    .header__container__menu a:hover {
        background-color: transparent;
    }
}
/* --- */
.none {
    display: none;
}

.section {
    padding: 2rem 1rem;
}

.btn { 
    border-radius: .5rem;
    border-top: dashed var(--white-color);
    border-bottom: dashed var(--white-color);
    border-left: dashed var(--white-color);
    border-right: dashed var(--white-color);
    padding: 1rem;
    display: inline-block; /* las a tiene las caracteristicas de elemento en linea, le saco para mejor manejo */
    width: 150px;
    font-weight: bold;
    text-align: center;
    text-decoration: none;
    color: var(--white-color);
}

.section__title {
    border-bottom: dashed var(--second-color);
    width: 250px;
    margin: 2rem auto;
    padding: .5rem 1rem;
    text-align: center;
    color: var(--second-color)
}

/* ----------Hero image---------- */
.hero__image {
    background-image: var(--hero-image); 
    /* la variable image no está en root, sino que se crea en el atributo styles que se le paso al contenedor article, y solo se define alli */
    background-repeat: no-repeat;
    background-size: cover;  /* se adapte a la altura de manera proporcional del contenedor */
    background-position: center;  
    /* background-attachment: var(--hero-attachment); */ /* si tuviera scroll se desplazará junto con el contenido */
}

.hero__image--opacity {
    width: 100%;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    background-color: var(--hero-opacity-color); /* probar la opacidad del second-color */
}

.hero__image--content {
    color: var(--white-color); 
}

.hero__image--title {
    font-size: 7.5vw; /* Fluid web design (en este caso con estas medidas no necesitaremos mas media querys para el title) */
}

.hero__image--title-h2 {
    font-size: 3vw;
}

/* ----------About---------- */
.about-article { 
    text-align: center;
}

/* ----------About - Media query---------- */
@media screen and (min-width: 1024px) {

    .about { /* en desktop tiene 2 columnas las section acerca */
        display: grid;
        grid-template-columns: repeat(2, 45%);/* se repite 2 veces al 45%, sobra 10%, eso será para el espacio entre si */
        justify-content: space-evenly;
        align-content: center;
    }

    .full-lg-screen { 
        width: 100%; 
        min-height: 100vh;
        /* background-color: var(--first-color); */
    } 
   
}

/* ----------Carousel---------- */

/* Slideshow container */
.slideshow-container {
  max-width: 400px;
  position: relative;
  margin: auto;
}

/* Hide the images by default */
.mySlides {
  display: none;
}

/* Next & previous buttons */
.prev, .next {
  cursor: pointer;
  position: absolute;
  top: 50%;
  width: auto;
  margin-top: -22px;
  padding: 16px; 
  color: white;
  font-weight: bold;
  font-size: 18px;
  transition: 0.6s ease;
  border-radius: 0 3px 3px 0;
  user-select: none;
}

/* Position the "next button" to the right */
.next {
  right: 0;
  border-radius: 3px 0 0 3px;
}

/* On hover, add a black background color with a little bit see-through */
.prev:hover, .next:hover {
  background-color: rgba(0,0,0,0.8);
}

/* Caption text */
.text {
  background-color: rgba(0,0,0,0.6);
  color: #f2f2f2;
  font-size: 15px;
  padding: 8px 12px;
  position: absolute;
  bottom: 8px;
  width: 100%;
  text-align: center;
}

/* Number text (1/3 etc) */
.numbertext {
  color: #f2f2f2;
  font-size: 12px;
  padding: 8px 12px;
  position: absolute;
  top: 0;
}

/* The dots/bullets/indicators */
.dot {
  cursor: pointer;
  height: 15px;
  width: 15px;
  margin: 0 2px;
  background-color: #bbb;
  border-radius: 50%;
  display: inline-block;
  transition: background-color 0.6s ease;
}

.active, .dot:hover {
  background-color: #717171;
}

/* ---------end carousel--------- */

/* ---------Recycled--------- */
.recycled > .recycled__container { /* tarjetas section recicled */
    display: grid;
    grid-template-columns: repeat(2, 45%); /* 2 por 45, da 90, queda 10 de margen para el justify content */
    justify-content: space-between;
    align-content: center;
}
.recycled .section__title { /* al titulo le decimos que ocupe las dos celdas, sino lo maneja como otra card, porque es hijo directo del div */
    grid-column: span 2;
}
.recycling__card {  
    margin: 1rem auto;
    padding: 1rem;
    text-align: center;  
}
.recycling__card .text-1{
    background-color: rgba(0,0,0,0.7);
    color: #f2f2f2;
    font-size: 15px;
    padding: 8px 12px;
    position: relative;
    bottom: 6px;
    width: auto;
    text-align: center;
}
/* MEDIA QUERY - 768 px */
@media screen and (min-width: 768px) { /* cuando el dispositivo sea pantalla y cuando la minima anchura sea 768*/
    .recycled > .recycled__container {
        grid-template-columns: repeat(3, 30%);
    }
    .recycled .section__title { 
        grid-column: span 3;
    }
}
/* MEDIA QUERY - 1024 px */
/* @media screen and (min-width: 1024px) {

    .recycled > .recycled__container {
        grid-template-columns: repeat(5, 18%); 
    }
    .recycled .section__title { 
        grid-column: span 5; 
    }
} */

/* ----------Contact---------- */
.contact__card {
    margin: 1rem auto;
    padding: 1rem;
    width: 100%;
    height: 144px;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    align-items: center;
}

.contact__card > svg path {
    width: 2rem;
    height: 2rem;
    fill: var(--second-color);
}

.contact__card > small {
    margin-top: -1rem;
}

/* ----------Contact - Media query---------- */
@media screen and (min-width: 768px) { /* cuando el dispositivo sea pantalla y cuando la minima anchura sea 768*/

    .contact__cards {
        display: grid;
        grid-template-columns: repeat(2, 48%);
        justify-content: space-between;
    }

}

/* ----------Contact - Media query---------- */
@media screen and (min-width: 1024px) {

    .contact__cards {
        grid-template-columns: repeat(3, 30%); 
        justify-content: space-between;
    }
 
}

/* ----------Footer---------- */
.footer {
    margin-bottom: var(--header-height);
    padding: 1rem;
    text-align: center;
    color: var(--second-color);
    background-color: var(--first-color);
}

@media screen and (min-width: 1024px) {
    .footer {
        margin-bottom: 0;
    }
}