* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: white;
  color: black;
  font-family: "Courier Prime", monospace;
}

/* TOP BAR */

.top-bar {
  position: fixed;
  top: 0;
  width: 100%;
  padding: 12px 24px;
  background: white;
  z-index: 100;
  font-size: 14px;
}

/* MAIN */

main {
  max-width: 900px;
  margin: 0 auto;
  padding-top: 10%;
  text-align: center;
}

/* INTRO */

.intro {
  margin-bottom: 220px;
}

.name {
  font-size: 16px;
  margin-bottom: 80px;
}

.portrait {
  width: 180px;
  display: block;
  margin: 0 auto 80px;
}

.description {
  font-size: 14px;
  line-height: 1.6;
}

/* TEXT */

.section-label,
.section-sub,
.about-text,
.freelance {
  font-size: 14px;
}

.section-label {
  margin-bottom: 20px;
  margin-top: 20%;
}

.section-sub {
  margin-bottom: 120px;
  
}

.about-me {
  margin-top: 120px;
}

.freelance {
  margin: 120px 0;
}

/* PROJECTS */

.project {
  width: 100%;
  margin: 0 auto 12px;
  overflow: hidden;
  cursor: pointer;
}

.project video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* RATIOS */

.vertical {
  width: 280px;
  aspect-ratio: 9 / 16;
}

.project-16x9 {
  width: 70%;
  aspect-ratio: 16 / 9;
}

.project-4x3 {
  width: 50%;
  aspect-ratio: 4 / 3;
}

/* HOVER */

.preview {
  transition: opacity 0.3s ease;
}

@media (hover: hover) {
  .project:hover .preview {
    opacity: 0.85;
  }
}

/* MODAL */

#video-modal {
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,0.96);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 999;
}

#video-modal.active {
  display: flex;
}

#video-modal iframe {
  width: 85%;
  aspect-ratio: 16 / 9;
  border: none;
}

/* REVEAL */

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.8s ease,
    transform 0.8s ease;
}

.reveal.reveal-active {
  opacity: 1;
  transform: translateY(0);
}

/* MOBILE */

@media (max-width: 768px) {

  main {
    padding-top: 100px;
    padding: 20px;
  }

  .intro {
    margin-bottom: 120px;
  }

  .vertical {
    width: 60%;
  }

  .project-16x9 {
    width: 100%;
  }

  .project-4x3 {
    width: 65%;
  }

  #video-modal iframe {
    width: 95%;
  }
}