body {
  opacity: 1;
  transition: opacity 1s ease;
  margin: 0;
  background-color: #08090B;
  font-family: 'Montserrat', sans-serif;
  color: white;
  line-height: 1.3;
}
  
.wrapper {
  height: 100vh;
  overflow-y: auto;
  overflow-x: hidden;
  perspective: 10px;
}

header {
  position: relative;
  display: flex;
  justify-content: center;
  flex-direction: column;
  align-items: center;
  height: 50vh;
  transform-style: preserve-3d;
  z-index: -1;
}

.background {
  transform: translateZ(-10px) scale(2.0);
  z-index: -1;
}

.foreground-exp {
  transform: translateZ(-50px) translateX(600px) translateY(-100px) scale(1.0);
  z-index: 0;
}

.foreground-work {
  transform: translateZ(-10px) translateX(-600px) translateY(100px) scale(0.8);
  z-index: 0;
}

.background,
.foreground-exp,
.foreground-work {
  position: absolute;
  height: 100vh;
  width: 100vw;
  object-fit: cover;
}

.title {
  font-size: calc(4rem + 5vw);
  color: white;
  text-shadow: 0 0 10px black;
  z-index: 1;
}
  
body.fade-out {
  opacity: 0;
}

body.fade-in {
  opacity: 0;
}

.back-link {
  position: absolute;
  top: 30px;
  left: 40px;
  font-size: 36px;
  color: white;
  text-decoration: none;
  z-index: 1;
  text-shadow: 0 0 10px black;
}

.projects {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2rem;
  padding: 2rem;
}

.project {
  width: calc(50% - 1rem);
  max-width: 500px;
  flex: 1 1 45%;
  margin: 2rem;
  transition: transform 0.3s ease;
  text-align: left;
  background-color: #1a1d2b;
  border-radius: 8px;
  padding: 1rem;
}

.project img {
  width: 100%;
  height: 350px;
  object-fit: cover;
  border-radius: 8px;
  transition: filter 0.5s;
}

.project:hover {
  transform: scale(1.05);
}

.project p, .project h3, .project h2 {
  margin: 0.5rem 0;
}

.project h2 {
  font-size: 1.8rem;
  font-weight: bold;
}

.image:hover {
  filter: brightness(60%);
}

/* Responsive Design for Mobile View */
@media (max-width: 768px) {
  .project {
    width: 100%;
    margin: 1rem 0;
  }

  .project h2 {
    font-size: 1.5rem;
  }

  .project img {
    height: 200px;
  }
}
