/*resetando o css para não pegar as margens do html*/
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
/*adicionando a possibilidade de variaveis ao codigo*/
:root {
  --bg-url: url(./assets/bg-mobile.jpg);
  --text-color: white;
  --stroke-color: rgba(255, 255, 255, 0.5);
  --surface-color: rgba(255, 255, 255, 0.1);
  --surface-color-hover: rgba(255, 255, 255, 0.02);
  --highlight-color: rgb(255, 255, 255, 0.2);
  --switch-bg-url: url(./assets/moon-stars.svg);
}
/*habilitando o light mode e trocando as cores dos elementos*/
.light {
  --bg-url: url(./assets/bg-mobile-light.jpg);
  --text-color: black;
  --stroke-color: rgba(0, 0, 0, 0.5);
  --surface-color: rgba(0, 0, 0, 0.1);
  --surface-color-hover: rgba(0, 0, 0, 0.02);
  --highlight-color: rgb(0, 0, 0, 0.2);
  --switch-bg-url: url(./assets/sun.svg);
}
body {
  /*Colocando o fundo no site
  background url(./assets/bg-mobile.jpg);
  background-repeat : no-repeat;
  background-position : top center;
  background-size : cover;
  */
  /*Compactando o código para ficar melhor*/
  background: var(--bg-url) no-repeat top center/cover;
  height: 100vh;
}
/*aplicando uma regra para todos os elementos do body utlizando o prefixo * */
body * {
  font-family: "Inter", sans-serif;
  color: var(--text-color);
}
/*Adicionando uma caixa para colocar os elementos da página*/
#container {
  width: 100%;
  max-width: 700px;
  margin: 56px auto;
  padding: 0 24px;
}
/*ajustando a foto de perfil*/
#profile {
  text-align: center;
  padding: 24px;
}
/*colocando a foto no site*/
#profile img {
  width: 112px;
  margin: auto;
}
/*colocando o texto com o @*/
#profile p {
  font-weight: 500;
  line-height: 24px;
  margin-top: 8px;
}
/*fazendo o switch de modo claro e escuro*/
#switch {
  position: relative;
  width: 64px;
  margin: 4px auto;
}
#switch button {
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 50%;
  background: white var(--switch-bg-url) no-repeat center;
  -webkit-backdrop-filter: blur(4px);
  position: absolute;
  top: 50%;
  z-index: 1;
  transform: translateY(-50%);
  animation: slide-back 0.4s;
}
#switch button:hover {
  outline: 8px solid var(--highlight-color);
}
.light #switch button {
  animation: slide-in 0.4s forwards;
}
/*adicionando o trtacker do switch*/
#switch span {
  display: block;
  width: 64px;
  height: 24px;
  border-radius: 9999px;
  border: 1px solid var(--stroke-color);
  background: var(--surface-color);
  -webkit-backdrop-filter: blur(4px);
}
/*lista de links*/
ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 24px 0;
}
/*ajustando a lista e aplicando efeitos*/
ul li a {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px 24px;
  background: var(--surface-color);
  border: 1px solid var(--stroke-color);
  border-radius: 8px;
  -webkit-backdrop-filter: blur(4px);
  text-decoration: none;
  font-weight: 500;
  transition: background 0.2s;
}
/*aplicando efeito quando o mouse passa por cima*/
ul li a:hover {
  background: var(--surface-color-hover);
  border: 1px solid var(--text-color);
}
/*ajeitando os icones de baixo*/
#social-links {
  display: flex;
  justify-content: center;
  padding: 24px 0;
  font-size: 24px;
}
/*alinhando os elementos para não ficarem fora do circulo*/
#social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  transition: background 0.2s;
  border-radius: 50%;
}
/*adicionando o efeito qaudn oo mouse passa por cima*/
#social-links a:hover {
  background: var(--highlight-color);
}
footer {
  padding: 24px;
  text-align: center;
  font-size: 14px;
}
/*media queris*/
@media (min-width: 700px) {
  :root {
    --bg-url: url(./assets/bg-desktop.jpg);
  }
  .light {
    --bg-url: url(./assets/bg-desktop-light.jpg);
  }
}
/*criando animaçoes*/
@keyframes slide-in {
  from {
    left: 0;
  }
  to {
    left: 50%;
  }
}
@keyframes slide-back {
  from {
    left: 50%;
  }
  to {
    left: 0;
  }
}
