@import url("index.css");

/* Charities */

.charities {
  width: 100%;
  margin-bottom: 100px;
}

.charities__list {
  display: grid;
  grid-template-columns: 100%;
  gap: 20px;
}

.charities__item {
  background: #f5f5f5;
  border-radius: 16px;
  height: auto;
  width: 100%;
  padding: 40px;
  padding-right: 130px;
  box-sizing: border-box;
  display: grid;
  grid-template-columns: auto 1fr;
  position: relative;
  column-gap: 40px;
  align-content: flex-start;
}

.charities__img {
  width: 250px;
  aspect-ratio: 1 / 1;
  background: #f0eee4;
  color: #1b1029;
}

.charities__text {
  display: grid;
  grid-template-columns: 100%;
  row-gap: 10px;
  align-content: center;
}

.charities__title {
  color: #1b1029;
  white-space: nowrap;
}

.charities__description {
  color: #221632;
  display: -webkit-box;
  -webkit-line-clamp: 6;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.charities__likes {
  width: 48px;
  height: 48px;
  position: absolute;
  top: 40px;
  right: 40px;
  display: grid;
  grid-template-columns: 100%;
  row-gap: 8px;
  border-radius: 8px;
  background: linear-gradient(180deg, #ffffff 85%, #9660db 225%), #ffffff;
  border: 2px solid #ffffff;
  box-sizing: border-box;
  justify-content: center;
  align-content: center;
  text-align: center;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.charities__likes-btn-icon {
  display: block;
  height: 10px;
  width: 24px;
  margin: auto;
}

.charities__likes-number {
  font-weight: 500;
  line-height: 11px;
  color: #1b1029;
}

.charities__footer {
  margin-top: 60px;
  text-align: center;
  display: grid;
  grid-template-columns: 100%;
  justify-content: center;
  row-gap: 24px;
  justify-content: center;
}

.charities__footer-button {
  margin: auto;
}

.charities__footer-text {
  outline-style: 20px;
}

@media screen and (max-width: 768px) {
  .charities__list {
    grid-template-columns: repeat(2, 1fr);
  }

  .charities__item {
    padding: 20px 20px 40px 20px;
    grid-template-columns: 100%;
    row-gap: 20px;
  }
  
  .charities__img {
    width: 100%;
  }

  .charities__likes {
    position: static;
  }

  .charities {
    margin-bottom: 40px;
  }
}

@media screen and (max-width: 568px) {
  .charities__list {
    grid-template-columns: 100%;
  }
}