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

html {
  background: white;
}

body {
  background: white;
  color: black;
  font-family: Arial, Helvetica, sans-serif;
  opacity: 0;
  transition: opacity 0.35s ease;
}

body.page-loaded {
  opacity: 1;
}

body.page-leaving {
  opacity: 0;
}

/* HOME */

.home {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.home h1 {
  margin-bottom: 14px;
  font-size: 28px;
  font-weight: 400;
  letter-spacing: -0.5px;
  text-transform: lowercase;
}

.home a {
  color: black;
  font-size: 24px;
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.home a:hover {
  opacity: 0.6;
  text-decoration: none;
}

.home a:hover {
  text-decoration: underline;
}

/* BACK BUTTON */

.back {
  position: fixed;
  top: 28px;
  left: 28px;
  z-index: 999;
  color: black;
  font-size: 16px;
  text-decoration: none;
}

.back:hover {
  text-decoration: underline;
}

/* GALLERY */

.gallery {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 95px;
  padding: 80px 0 120px;
}

.gallery img {
  display: block;
  height: auto;
  max-width: 90vw;

  -webkit-filter: grayscale(100%) !important;
  filter: grayscale(100%) !important;

  transition:
    opacity 0.25s ease,
    transform 0.35s ease;
}

/* FADE IN ON SCROLL */

.gallery-image {
  opacity: 0;
  transform: translateY(20px);
  cursor: zoom-in;
}

.gallery-image.visible {
  opacity: 1;
  transform: translateY(0);
}

/* HOVER: ENLARGE ONLY */

.gallery img:hover {
  -webkit-filter: grayscale(100%) !important;
  filter: grayscale(100%) !important;
  transform: scale(1.04);
}

/* IMAGE SIZES */

.signature {
  width: 420px;
}

.landscape {
  width: 720px;
}

.square {
  width: 560px;
}

.portrait {
  width: 470px;
}

/* LIGHTBOX */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 5000;
  display: none;
  justify-content: center;
  align-items: center;
  padding: 40px;
  background: rgba(255, 255, 255, 0.97);
}

.lightbox.open {
  display: flex;
}

.lightbox img {
  width: auto;
  height: auto;
  max-width: 92vw;
  max-height: 90vh;
  object-fit: contain;

  -webkit-filter: grayscale(100%) !important;
  filter: grayscale(100%) !important;
}

.lightbox-close {
  position: fixed;
  top: 22px;
  right: 28px;
  border: none;
  background: transparent;
  color: black;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 34px;
  font-weight: 300;
  cursor: pointer;
}

body.lightbox-open {
  overflow: hidden;
}

/* MOBILE */

@media (max-width: 800px) {
  .back {
    top: 18px;
    left: 18px;
  }

  .gallery {
    gap: 45px;
    padding: 50px 0 70px;
  }

  .landscape,
  .square,
  .portrait {
    width: 90vw;
  }

  .signature {
    width: 65vw;
  }

  .lightbox {
    padding: 20px;
  }

  .lightbox-close {
    top: 14px;
    right: 18px;
  }
}
