@use 'utils/base' as *;

/* SNS 공통 목록 */
.sns-container {
  padding-bottom: rem(140);
}
.sns-intro {
  margin-bottom: rem(60);
}
.sns-items {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, rem(280)), 1fr));
  gap: rem(20);
  margin-bottom: rem(42);
}
.sns-item-link {
  position: relative;
  display: block;
}
.sns-item-figure {
  position: relative;
  aspect-ratio: 1/1;
}
.sns-item-content {
  display: flex;
  justify-content: space-between;
  flex-direction: column;
  position: absolute;
  inset: 0;
  padding: rem(20);
  background-color: rgba($black, 0.5);
  color: $white;
  transition: opacity 0.3s;
  opacity: 0;
  .blog-items &,
  .sns-item-link:hover & {
    opacity: 1;
  }
  .ig-items & {
    background: linear-gradient(
      30deg,
      rgba(252, 176, 69, 0.8) 0%,
      rgba(253, 29, 29, 0.8) 30%,
      rgba(131, 58, 180, 0.8) 100%
    );
  }
  .blog-items & {
    background: rgba(#63c640, 0.9);
  }
}
.sns-item-icon {
  aspect-ratio: 1/1;
  .ig-items & {
    width: rem(40);
  }
  .blog-items & {
    width: rem(20);
  }
}
.sns-item-title {
  margin-bottom: rem(10);
}
.sns-item-desc {
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}
@media screen and (max-width: $breakpoint-md) {
  .sns-container {
    padding-bottom: rem(80);
  }
  .sns-items {
    grid-template-columns: repeat(2, 1fr);
    gap: rem(10);
  }
  .sns-intro {
    margin-bottom: rem(40);
  }
}
