* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {

  --primary-color: #00856F;
  --headline: #212529;
  --paragraphs: #495057;

  --brand-beige: hsl(39,100%, 97%, 1);
  --brand-light: hsl(148, 23%, 89%);
  --brand-dark: #00453A;
  --bg-light: hsl(180, 14%,97%);
  --nav-height: 7.2rem;

  font-size: 62.5%;
}

html {
/* Scroll mais suave - Chrome */
  scroll-behavior: smooth;
}

html,
body {
  width: 100%;
  height: 100%;
}

body {
  
  background-color: var(--bg-light);
  font-family: 'DM Sans', sans-serif;
  font-size: 1.6rem;
  text-align: center;

  overflow: overlay;
}

section {
  padding-block: 10rem;
}
img {
  max-width: 100%;
}

a.button_whatsapp {
  background: var(--primary-color);
  
  border: none;
  border-radius: 4rem;

  margin-bottom: 6rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.6rem; 
  margin: auto;
  text-decoration: none;
  width: 30.2rem;
  padding: 1.6rem 0.2rem;

  color: #fff;
  text-transform: uppercase;
  font-size: 1.6rem;
  font-weight: 700;
  transition:  background 200ms;
}

a.button_whatsapp:hover {
  background-color: var(--brand-dark);
}

section header h4 {
  text-transform: uppercase;
  font-size: 1.4rem;
  line-height: 150%;
  letter-spacing: 0.08rem;
  color: var(--primary-color);
  margin-bottom: 1.4rem;

}
section header h2 {
  font-size: 3rem;
  line-height: 3.9rem;
  color: var(--headline);
  margin-bottom: 3rem;
}
section header h1 {
  font-size: 3.4rem;
  color: var(--headline);
  line-height: 130%;

  margin-bottom: 2.4rem;

}
section.content p {
  font-weight: 400;
  font-size: 1.6rem;
  line-height: 150%;
  color: var(--paragraphs);
}
#home {
  padding-top: calc(4.1rem + var(--nav-height));
}

#home h4 {
  font-size: 1.4rem;
  color: var(--primary-color);
  margin-bottom: 1.6rem;

}

#home h1 {
  font-size: 3.4rem;
  color: var(--headline);
  line-height: 130%;

  margin-bottom: 2.4rem;

}

#home p {
  font-size: 1.8rem;
  line-height: 150%;
  font-weight: 400;
  color: var(--paragraphs);

  margin-bottom: 3.2rem;
}

#home img {
  display: block;
  width: 26.4rem;
  margin-inline: auto;
  object-position: 0 2rem;
}
.stats {
  width: 100%;
  padding-top: 4rem;
  padding-bottom: 4rem;

  border:  1px solid var(--brand-light);
  border-radius: 0.6rem;

  margin-inline: auto;

  background-color: var(--brand-beige);

  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6rem;
}
.stat h3 {
  font-size: 4.8rem;
  color: var(--headline);
  line-height: 130%;

  margin-bottom: 0.4rem;
}

.stat p {
  margin: 0;
  color: var(--primary-color);
  
}

.wrapper {
  width: min(50rem, 100%);
  margin-inline: auto;
  padding-inline: 2.4rem;
  
}

header.header_home::before  {
  content: "";
  width: 100%;
  height: calc(108rem + var(--nav-height));
  background-color: var(--brand-light);
  display: block;

  position: absolute;
  top: 0;
  left: 0;
  z-index: -1;

}

ul {
  list-style: none;
}

nav {
  display: flex;
  z-index: 100;
  padding: 1.6rem 2.4rem;
  margin-top: 0;
  height: var(--nav-height);
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
}

nav .wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

nav.scroll {
  background: var(--primary-color);
  width: 100vw;
  transition:  0.5s;
}

nav.scroll svg:nth-child(1) path {
  fill: white;
}

nav.scroll button path {
  stroke: white;
}

nav button {
  background: none;
  border: none;
  cursor: pointer;
}


/* ==== Menu Expanded ==== */
nav .menu, 
nav .close-menu {
  position: fixed;
}

body.menu-expanded {
  overflow: hidden;
}

.menu,
.close-menu,
body.menu-expanded .open-menu {
  opacity: 0;
  visibility: hidden;
}

body.menu-expanded .menu,
body.menu-expanded .close-menu {
  opacity: 1;
  visibility: visible;
}

.menu {
  transform: translateY(100%);
}

body.menu-expanded .menu {  
  top: 0;
  left: 0;
  background-color: var(--primary-color);

  width: 100vw;
  height: 100vh;
  padding-top: var(--nav-height);
  transition: transform 300ms;
  transform: translateY(0%);
}

.menu ul:nth-child(1) {
  display: flex;
  flex-direction: column;
  gap: 4.8rem;

  margin-top: 6rem;

  font-weight: 700;
  font-size: 2.4rem;
  line-height: 3.1rem;
}

.menu ul a {
  color: white;
  text-decoration: none;
}

.menu .button {
  display: inline-block;

  text-transform: uppercase;
  font-weight: 700;
  font-size: 1.8rem;
  line-height: 2.3rem;
  color: var(--primary-color);
  padding: 16px 32px;
  margin-top: 4.8rem;
  margin-bottom: 8rem;
  text-decoration: none;
  /* Secondary Colors/White */

  background: #FFFFFF;
  border-radius: 4rem;
}

.menu .button:hover {
  background-color: var(--primary-color);
  color: white;
  filter: brightness(1.3);
}

.social-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3.2rem;

}

body.menu-expanded nav button,
body.menu-expanded .logo {
  position: relative;
  z-index: 10;
}

body.menu-expanded .logo path {
  fill: white;
}

body.menu-expanded button path {
  stroke: white;
}

#services header h4 {

  text-transform: uppercase;
  font-size: 1.4rem;
  line-height: 150%;
  letter-spacing: 0.08rem;
  color: var(--primary-color)
}

#services header h2 {
  font-size: 3rem;
  line-height: 3.9rem;
  color: var(--headline);
  margin-bottom: 6rem;
}

#services .cards {
  display: flex;
  flex-direction: column;
  gap: 3.2rem;
}

.card {
  padding: 2.4rem;
  text-align: left;
  background: white;

  border: 1px solid var(--brand-light);
  border-radius: .6rem; 
}

.card h3 {
  margin-block: 1.6rem;
}
/* ===== About ===== */

#about {
  text-align: left;
  background-color: var(--brand-beige);
}

#about .content p {
  margin-top: 2.4rem;
  margin-bottom: 6rem;
}


/* ==== Contact ==== */
#contact {
  text-align: left;
}

#contact header {
  margin-bottom: 3.2rem;
}

#contact ul {

  display: flex;
  flex-direction: column;
  gap: 1.6rem; 
}
#contact ul li {
  display: flex;
  align-items: center;
  gap: .8rem;
}

#contact a.button_whatsapp {
  margin-top: 3.2rem;
  margin-bottom: 3.2rem;
}

/* ==== Contact ==== */

footer {
  background-color: var(--primary-color);
  padding-block: 6rem;
  color: white;
  text-align: left;
  line-height: 2em;
}

footer .social-links {
  margin-top: 2rem;
}
footer svg {
  width: 23.6rem;
  height: 3.1rem;
  margin-bottom: 2.2rem;
}
footer path {
  fill: white;
}

#btnbackToTop {
  position: fixed;
  bottom: 1rem;
  right: 2.5rem;

  opacity: 0;
  visibility: hidden;
  
  transform: translateY(100%);
  transition: 200ms;
}

#btnbackToTop.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* ==== Desktop Device ==== */

@media (min-width: 1024px) {
  /* Reset */
  .wrapper {
    width: min(112rem, 100%);
    display: grid;
  }
  .col-a {
    grid-area: A;
    text-align: left;
    align-self: center;
  }
  .col-b {
    grid-area: B;
  } 
  section h2 {
    font-size: 4rem;
    line-height: 5.2rem;
  }
  nav .menu {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between; 
    gap: 11rem;
  }
  nav#navigation .wrapper * {
    margin: 0;
    padding: 0;
    visibility: initial;
    opacity: initial;
    flex-direction: initial;
    font-size: initial;
    transform: initial;
    color: initial;
    background-color: initial;
    font-weight: initial;
  }
  nav#navigation .social-links,
  nav#navigation .open-menu,
  nav#navigation .close-menu {
    display: none;
  }
  nav#navigation .menu ul:nth-child(1) li a {
    color: var(--primary-color);
    opacity: 0.8;
  }
  nav#navigation .menu a.button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.6rem; 
    margin: auto;
    text-decoration: none;
    width: 25.2rem;
    padding: 0.9rem 0.2rem;
    color: var(--brand-dark);
    text-transform: uppercase;
    border: solid 1px var(--brand-dark);
    opacity: 0.8;
    font-size: 1.6rem;
    font-weight: 700;
    transition:  background 200ms;
  }
  nav#navigation .menu a.button:hover {
    background-color: var(--brand-dark);
    color: white;
  }
  nav#navigation .menu li a {
    transition: opacity .4s;
  }
  nav#navigation .menu li a:active,
  nav#navigation .menu ul:nth-child(1) li a:hover {
    opacity: 1;
    font-weight: 700;
  }
  nav#navigation .menu  li a::after {
    content: '';
    width: 0%;
    height: 2px;
    background-color: var(--primary-color);
    display: block;

    position: relative;
    bottom: -2rem;
    left: -1rem;
  
    display: block;

    transition: width 0.2s;
  }
  nav#navigation .menu  li a.active::after,
  nav#navigation .menu  li a:hover::after {
    padding-inline: 1.3rem;
    width: 100%;
    
  }
  nav#navigation .menu  li a.active {
    font-weight: 700;
  }
  nav#navigation.scroll .menu li a::after {
    background-color: white;
  }

  nav#navigation.scroll .menu a.button {
    color: white;

  } 
  nav#navigation.scroll .menu ul:nth-child(1) li a {
    color: var(--brand-light);
  }
 /* Home */
 #home {
   padding-top: var(--nav-height);
 }
 header.header_home::before {
   height: calc(70rem + var(--nav-height));
 }
  #home .wrapper {
    grid-template-columns: 60.5rem 1fr;
    grid-template-areas:
    'A B'
    'C C';
  }
  
  #home .stats {
    grid-area: C;

    flex-direction: row;
    padding: 6rem;
    gap: 0;
  }
  #home .stats .stat + .stat {
    border-left: 1px solid var(--primary-color);    
  }
  #home .stats .stat {
    flex: 1;
  } 
  #home .button {
    margin: 0;
  }
  #home img {
    width: 42rem;
  }
  /* ==== Services ==== */
  #services h2 {
    width: 47rem;
    margin-inline: auto;

  }
  #services .cards {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 4rem;
  }
  #services .card {
    width: 30%;
    flex-grow: 1;
  }
  /* ==== About ==== */
  #about .wrapper {
    grid-template-columns: 1fr 1fr;
    grid-template-areas: 'B A';
  }
  /* ==== Contact ==== */
  #contact .wrapper {
    text-align: -webkit-center;
    grid-template-columns: 1fr 57.5rem;
    grid-template-areas: 'A B';
  }
   /* ==== Footer ==== */
  footer {
    padding-block: 6rem;
  }
  footer .wrapper {
    grid-template-columns: 1fr 1fr;
    grid-template-areas: 'A B';
  } 
  footer .col-a {
    align-self: center;
  }
  footer .col-b {
    align-self: center;
    justify-self: flex-end;
  }
  footer p {
    margin-bottom: 0;
  }
}