.category-webstories-container {
  background-color: var(--custom-background-dark-color);
  padding: 3rem;
  margin-top: 3rem;
  margin-bottom: 3rem;
  border-radius: 1rem;
}

.webstories-header {
  margin-bottom: 2rem;
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.webstories-header h2 {
  color: var(--custom-secondary-gray);
  font-family: var(--barlow-condensed);
  font-size: 0.875rem;
  font-style: normal;
  font-weight: 500;
  line-height: 1rem; 
  text-transform: uppercase;
}

.webstories-list {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 3rem;
}

.webstories-list-bg {
  width: 100%;
  height: 100%;
  padding: 1rem 0.5rem;
  border-radius: 0.5rem;
  background-size: cover;
  background-position: center;
  position: absolute;
  transition: transform 0.75s ease;
}

.webstories-list-item {
  width: calc(100% / 4 - 0.75rem);
  height: 27.5rem;
  position: relative;
  display: flex;
  align-items: flex-end;
  border-radius: 0.5rem;
  overflow: hidden;
}

.webstories-list-item::after {
  content: "";
  position: absolute;
  height: 100%;
  width: 100%;
  top: 0;
  left: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 1), rgba(0, 0, 0, 0));
  pointer-events: none;
  border-radius: 0.5rem;
  z-index: 4;
}

.webstories-list-item:hover .webstories-list-bg {
  transform: scale(1.03);
}

.webstories-content {
  z-index: 5;
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: end;
  padding: 1rem 0.5rem;
}

.webstories-list-item h2 {
  font-size: 1.5rem;
  color: var(--custom-primary-white);
  margin: 0.5rem 0;
}

.webstories-list-item .common-metadata i,
.webstories-list-item .common-metadata p {
  color: var(--custom-primary-white);
}

@media (max-width: 1200px) {
  .webstories-list-item {
    width: calc(100% / 3 - 0.75rem);
  } 
}

@media (max-width: 991px) {
  .webstories-list-item {
    width: calc(100% / 2 - 0.75rem);
  } 
}

@media (max-width: 768px) {
  .webstories-list-item {
    width: 100%;
  } 

  .category-webstories-container {
    padding: 1.5rem 0.5rem;
    margin-top: 1.5rem;
    margin-bottom: 1.5rem;
    border-radius: 1rem;
  }

  .webstories-header {
    margin-bottom: 1rem;
    display: flex;
    gap: 0.5rem;
    align-items: center;
  }

  .webstories-list {
    margin-bottom: 2rem;
  }
}