h1 {
    text-align: center;
}

h2 {
    font-size: 25px;
    white-space: nowrap;
    background: none;
}

h3 {
    background: none;
}

p {
    background: none;
}

#projects {
  margin-left: 10%;
}

.title {
    padding-top: 3em;
}

.UXprojects-container {
    display: flex;
    justify-content: center;
}

#uxproject-item h2{
    color: rgb(15, 15, 15);
    background-color: rgb(236, 224, 247);
    padding: 1em 5em 1em 5em;
    text-align: center;
    width: auto;
    margin: 0 7em; 
}

.project-content {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 150px; /* Adjust the gap as per your requirement */
  justify-content: space-evenly;
}

.project-wrapper {
  width: auto;
  height: 400px;
  overflow: hidden;
  position: relative;
  transition: all 0.3s ease-out;
  border-radius: 5px;
}

.portfoliopfp-wrapper,
.project-wrapper {
  width: 400px;
  height: 400px;
  overflow: hidden;
  position: relative;
  margin-right: 20px;
  transition: all .3s ease-out;
}

.portfoliopfp,
.project-wrapper img {
  width: 100%; /* Make the image fill the container */
  height: 100%; /* Make the image fill the container */
  object-fit: cover; /* Ensure the image covers the container without distortion */
  transition: all .3s ease-out;
}

.portfoliopfp-wrapper:hover,
.project-wrapper:hover {
  box-shadow: 8px 8px rgb(255, 159, 175);
}

.portfoliopfp-wrapper::after,
.project-wrapper::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(255, 0, 43, 0.208);
  opacity: 0;
  transition: opacity .3s ease-out;
  pointer-events: none;
}

.portfoliopfp-wrapper:hover::after,
.project-wrapper:hover::after {
  opacity: 0.25;
}

.portfoliopfp-wrapper:hover .portfoliopfp,
.project-wrapper:hover img {
  filter: blur(10px) grayscale(1) brightness(1.25);
  transform: scale(1.1);
  cursor: pointer;
}

.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(248, 240, 243, 0.532);
    color: rgb(49, 0, 11);
    font-weight: bold;
    display: flex;
    flex-direction: column; /* Add this line */
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    text-align: center;
  }
  .portfoliopfp-wrapper:hover .overlay,
  .project-wrapper:hover .overlay {
    opacity: 1;
  }