main {
  display: flex;
  width: 100vw;
  height: 100vh;
  flex-direction: column;
  align-items: center;
  background-image: url(../images/bg_galeria.png);
  background-size: cover;
  overflow: hidden;
}

#gallery {
  display: flex;
  flex-direction: column;
  width: 100vw;
  height: 100vh;
  padding: 40px;
  box-sizing: border-box;
}

nav {
  display: flex;
  width: 100%;
  position: relative;
}

#grid {
  display: flex;
  overflow-x: auto;
  overflow-y: hidden;
  width: 100vw;
  height: 0;
  padding: 20px 0;
  background: transparent;
  scroll-behavior: smooth;
  transition: 0.7s;
}

#grid.active {
  height: 75vh;
}

#fotos {
  display: flex;
  gap: 10px;
  min-width: max-content;
  height: 100%;
}

.full {
  display: flex;
  width: 380px;
  height: 100%;
}

.full img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: bottom;
  user-select: none;
  -webkit-user-drag: none;
}

.half {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 302px;
  height: 100%;
}

.half img {
  height: 50%;
  object-fit: cover;
  width: 100%;
  user-select: none;
  -webkit-user-drag: none;
}

#lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
}

#lightbox.hidden {
  display: none;
}

#lightbox .overlay {
  position: absolute;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.8);
}

#lightbox .conteudo {
  position: relative;
  max-width: 90vw;
  max-height: 90vh;
  z-index: 1;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

#lightbox .conteudo img {
  max-width: 100%;
  max-height: 100%;
  border-radius: 10px;
  transition: 0.4s;
  cursor: pointer;
}

#lightbox .conteudo img:hover {
  opacity: 0.7;
}

#lightbox .fechar {
  position: absolute;
  top: -20px;
  right: -20px;
  background: #fff;
  border: none;
  border-radius: 50%;
  font-size: 20px;
  width: 40px;
  height: 40px;
  cursor: pointer;
}

button {
  background: transparent;
  border: none;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  transition: 0.4s;
  cursor: pointer;
}

button:hover {
  opacity: 0.7;
}

button img {
  width: 50px;
}

button span {
  font-weight: bold;
  letter-spacing: 1px;
}

#shows {
  display: flex;
  flex-direction: column;
  flex-wrap: nowrap;
  align-content: flex-start;
  gap: 10px;
}

#lightbox .top-bar {
  position: absolute;
  top: 0;
  right: 0;
  display: flex;
  gap: 30px;
}

#lightbox .top-bar img {
  width: auto;
  object-fit: contain;
  object-position: center;
  max-width: 30px;
}

#lightbox .navegar {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  font-size: 30px;
  cursor: pointer;
  padding: 10px;
  border-radius: 5px;
}

#lightbox .navegar.esquerda {
  left: 0px;
}

#lightbox .navegar.direita {
  right: 0px;
}

.logo {
  width: 75px;
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1;
}

.bg-dark {
  position: absolute;
  z-index: 0;
  width: 100%;
  height: 100dvh;
  top: 0;
  background: #0000008c;
}

nav a {
  position: absolute;
  right: 20px;
  font-weight: bold;
  top: 50%;
  transform: translateY(-50%);
}

#grid::-webkit-scrollbar {
  width: 10px;
  height: 10px;
  border-radius: 34px;
}

/* Track */
#grid::-webkit-scrollbar-track {
  background: linear-gradient(
    to right,
    transparent 10px,
    #f1f1f13b 10px,
    #f1f1f13b calc(100% - 10px),
    transparent calc(100% - 10px)
  );
  border-radius: 50px;
}

/* Handle */
#grid::-webkit-scrollbar-thumb {
  background: white;
  border-radius: 80px;
  height: 80px !important;
  min-height: 80px;
  max-height: 80px;
}

/* Handle on hover */
#grid::-webkit-scrollbar-thumb:hover {
  background: #ffffffd4;
  border-radius: 16px;
}

@media screen and (max-width: 800px) {
  * {
    font-size: 14px;
  }

  button img {
    width: 40px;
  }

  button span {
    text-align: left;
    max-width: 225px;
  }

  #gallery {
    padding: 40px 20px;
  }

  #lightbox .top-bar img {
    width: 25px;
  }

  /* #lightbox .conteudo img {
    max-height: 500px;
  } */

  #lightbox .navegar {
    top: 100%;
  }

  #lightbox .navegar.direita {
    right: 30%;
  }

  #lightbox .navegar.esquerda {
    left: 30%;
  }

  .logo {
    width: 75px;
  }
}
