.row {
  display: flex;
  gap: 2rem;
  align-items: flex-start;
  margin: 1.5rem 0;
  flex-wrap: wrap;
}
.row > a {
  flex: 0 0 300px;
  max-width: 40%;
}
.profile-photo {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 8px;
  object-fit: cover;
  aspect-ratio: 4/5;
}

.profile-photo {
  transition: transform 0.25s ease;
}
.row > a {
  overflow: hidden;
  border-radius: 8px;
}
.row > a:hover .profile-photo {
  transform: scale(1.05);
}
.row > div {
  flex: 1 1 300px;
  min-width: 220px;
}

@media (max-width: 700px) {
  .row {
    flex-direction: column;
  }
  .row > a {
    max-width: 100%;
    flex: none;
  }
}

.photo-gallery {
  margin-top: 1.5rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}
.photo-gallery a {
  display: block;
  overflow: hidden;
  border-radius: 6px;
}
.gallery-photo {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  aspect-ratio: 1/1;
  transition: transform 0.25s ease;
}
.photo-gallery a:hover .gallery-photo {
  transform: scale(1.05);
}

@media (max-width: 900px) {
  .photo-gallery {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 480px) {
  .photo-gallery {
    grid-template-columns: 1fr;
  }
}
