.portfolio-list {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 48px 24px;
}

.portfolio-item {
  max-width: 356px;
  width: 100%;
  cursor: pointer;
  transition: box-shadow 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.overlay {
  color: #f4f4fd;
  top: 0;
  left: 0;
  font-family: sans-serif;
  position: absolute;
  font-weight: 400;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.02em;
  padding: 40px 32px;
  width: 100%;
  height: 100%;
  background-color: #4d5ae5;
  transform: translateY(100%);
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.portfolio-item:hover .overlay {
  transform: translateY(0%);
}

.portfolio-item:hover {
  box-shadow: 0px 1px 6px rgba(46, 47, 66, 0.08),
    0px 1px 1px rgba(46, 47, 66, 0.16), 0px 2px 1px rgba(46, 47, 66, 0.08);
}

.portfolio-active {
  overflow: hidden;
  position: relative;
  width: 100%;
  margin: 0 auto;
}

.portfolio-item-content {
  border-bottom: 1px solid #e7e9fc;
  border-left: 1px solid #e7e9fc;
  border-right: 1px solid #e7e9fc;
  padding: 32px 16px;
  width: 100%;
  min-height: 120px;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  flex-direction: column;
}

.portfolio-title {
  font-weight: 500;
  font-size: 20px;
  line-height: 1.2;
  letter-spacing: 0.02em;
  color: #2e2f42;
  margin-bottom: 8px;
}

.portfolio-description {
  font-weight: 400;
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.02em;
  color: #434455;
}

@media screen and (min-width: 768px) {
  .portfolio-list {
    gap: 72px 24px;
  }

  .portfolio-item-content {
    max-width: 356px;
  }
}

@media screen and (min-width: 1158px) {
  .portfolio-list {
    gap: 48px 24px;
  }

  .portfolio-item {
    max-width: 360px;
  }

  .portfolio-item-content {
    width: 100%;
  }
}
