/* HEADER E NAVEGAÇÃO */
header {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 9999;
  width: 100%;
  height: 80px;
  padding: 0 5%;
  background-color: var(--header-bg);
  color: white;
  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.3);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

header a {
  color: white;
  font-family: "Oswald", sans-serif;
  font-weight: 500;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: color 0.3s;
}

header nav ul li a:hover {
  color: var(--secondary);
}

.branding {
  display: flex;
  align-items: center;
  gap: 15px;
  font-size: 1.4rem;
  z-index: 1001;
}

.branding img {
  width: 45px;
  height: auto;
}

nav ul {
  display: flex;
  align-items: center;
  gap: 25px;
  list-style: none;
}

/* BOTÃO DE TEMA */
#btn-tema {
  width: 35px;
  height: 35px;
  background: rgba(255, 255, 255, 0.15);
  color: white;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

/* MENU MOBILE (BOTÃO HAMBÚRGUER) */
#btn-mobile {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 30px;
  height: 24px;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  z-index: 1001;
}

#btn-mobile div {
  width: 100%;
  height: 3px;
  background-color: white;
  border-radius: 2px;
  transition: 0.3s;
}

#btn-mobile.active .line1 {
  transform: translateY(10.5px) rotate(45deg);
}
#btn-mobile.active .line2 {
  opacity: 0;
}
#btn-mobile.active .line3 {
  transform: translateY(-10.5px) rotate(-45deg);
}

/* RESPONSIVIDADE */
@media (max-width: 900px) {
  header {
    height: 70px;
    padding: 0 20px;
  }

  nav ul {
    display: none;
  }

  #btn-mobile {
    display: flex;
  }

  #menu {
    position: fixed;
    top: 0;
    right: 0;
    width: 100%;
    height: 100vh;

    background: var(--header-bg);
    box-shadow: 20px 20px 40px -6px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(9.5px);
    -webkit-backdrop-filter: blur(9.5px);

    display: flex;
    flex-direction: column;
    align-items: center;
    padding-top: 100px;
    transform: translateX(100%);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    overflow-y: auto;
  }

  #menu.active {
    transform: translateX(0);
  }

  #menu li {
    width: 100%;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  }

  #menu li a {
    display: block;
    padding: 20px;
    font-size: 1.3rem;
    text-align: center;
  }

  #btn-tema {
    margin: 20px auto;
    width: 50px;
    height: 50px;
    font-size: 1.5rem;
    background-color: rgba(255, 255, 255, 0.1);
  }
}
