@font-face {
  src: url("https://fonts.cdnfonts.com/css/pp-neue-montreal") format("woff2");
  font-family: "PP Neue Montreal", sans-serif;
  font-weight: 400;
}

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

:root {
  --warm-off-black: #1a1917;
  --warm-off-white: #f8f5f2;
}

html,
body {
  height: 100%;
  overflow: hidden;
}

body {
  font-family: "PP Neue Montreal", sans-serif;
  font-weight: 700;
  font-size: 18px;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background-color: var(--warm-off-black);
  text-transform: uppercase;
  letter-spacing: -0.03em;
  color: var(--warm-off-white);
  position: relative;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Animated noise effect */
body::before {
  content: "";
  position: fixed;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: transparent
    url("http://assets.iceable.com/img/noise-transparent.png") repeat 0 0;
  background-size: 300px 300px;
  -webkit-animation: noise-animation 0.3s steps(5) infinite;
          animation: noise-animation 0.3s steps(5) infinite;
  opacity: 0.9;
  will-change: transform;
  z-index: 100;
  pointer-events: none;
}

@-webkit-keyframes noise-animation {
  0% {
    transform: translate(0, 0);
  }
  10% {
    transform: translate(-2%, -3%);
  }
  20% {
    transform: translate(-4%, 2%);
  }
  30% {
    transform: translate(2%, -4%);
  }
  40% {
    transform: translate(-2%, 5%);
  }
  50% {
    transform: translate(-4%, 2%);
  }
  60% {
    transform: translate(3%, 0);
  }
  70% {
    transform: translate(0, 3%);
  }
  80% {
    transform: translate(-3%, 0);
  }
  90% {
    transform: translate(2%, 2%);
  }
  100% {
    transform: translate(1%, 0);
  }
}

@keyframes noise-animation {
  0% {
    transform: translate(0, 0);
  }
  10% {
    transform: translate(-2%, -3%);
  }
  20% {
    transform: translate(-4%, 2%);
  }
  30% {
    transform: translate(2%, -4%);
  }
  40% {
    transform: translate(-2%, 5%);
  }
  50% {
    transform: translate(-4%, 2%);
  }
  60% {
    transform: translate(3%, 0);
  }
  70% {
    transform: translate(0, 3%);
  }
  80% {
    transform: translate(-3%, 0);
  }
  90% {
    transform: translate(2%, 2%);
  }
  100% {
    transform: translate(1%, 0);
  }
}

/* Container for centering */
.container {
  width: 100%;
  max-width: 1000px; /* Increased width */
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  position: relative;
}

/* Full-screen background image */
#background-image-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  overflow: hidden;
}

#background-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  -o-object-fit: cover;
     object-fit: cover;
  transform: scale(1.2); /* Start zoomed in */
  transition: transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  opacity: 0;
}

/* Projects Container */
.projects-container {
  width: 100%;
  position: relative;
  z-index: 10;
  max-height: 80vh;
  overflow-y: auto;
  padding: 20px;
  /* Hide scrollbar for Chrome, Safari and Opera */
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE and Edge */
}

/* Hide scrollbar for Chrome, Safari and Opera */
.projects-container::-webkit-scrollbar {
  display: none;
}

/* Project Item Styles */
.project-item {
  position: relative;
  display: flex;
  justify-content: space-between;
  padding: 0.7rem 0; /* Further reduced padding for smaller line height */
  border-bottom: 1px solid rgba(248, 245, 242, 0.1);
  cursor: pointer;
}

/* Project title and year */
.project-title,
.project-year {
  font-size: 1.8rem;
  position: relative;
  z-index: 2;
  mix-blend-mode: exclusion;
}

/* List view hover animation with exclusion blend mode */
.project-item::before {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 0;
  background-color: var(--warm-off-white);
  z-index: 1;
  pointer-events: none;
  transition: height 0.2s cubic-bezier(0.445, 0.05, 0.55, 0.95) 0s;
}

.project-item:hover::before {
  height: 100%;
}

.project-item:not(:hover)::before {
  transition-duration: 0.8s;
}

/* Responsive Styles */
@media (max-width: 768px) {
  .project-title,
  .project-year {
    font-size: 1.4rem;
  }
}

@media (max-width: 480px) {
  .project-item {
    flex-direction: column;
    gap: 0.5rem;
  }
}