.detail-shimmer {
  animation: shimmer 1.5s infinite linear;
  background: linear-gradient(to right, #eeeeee 8%, #dddddd 18%, #eeeeee 33%);
  background-size: 1000px 100%;
  border-radius: 4px;
  margin-bottom: 1rem;
}

.shimmer-thumbnail {
  height: 400px;
  width: 100%;
}

.shimmer-title {
  height: 40px;
  width: 100%;
  margin-top: 20px;
}
.shimmer-excerpt {
  height: 24px;
  margin-top: 20px;
}

.shimmer-author {
  height: 60px;
  width: 60px;
  border-radius: 50%;
}

@keyframes shimmer {
  0% {
    background-position: -1000px 0;
  }
  100% {
    background-position: 1000px 0;
  }
}

.skeleton-blog {
  height: 150px; /* adjust based on your design */
  width: 100%;
  margin-top: 24px;
  border-radius: 6px;
}

/* Skeleton base */
.skeleton {
  position: relative;
  overflow: hidden;
  background: #eeeeee;
  color: transparent;
  border-radius: 4px;
  user-select: none;
}

.skeleton::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, #eeeeee 8%, #dddddd 18%, #eeeeee 33%);
  background-size: 1000px 100%;
  animation: shimmer 1.5s infinite linear;
  z-index: 1;
}

.skeleton * {
  visibility: hidden;
}

.skeleton-text {
  height: 16px;
  width: 120px;
  margin-top: 6px;
}

/* Wrapper to contain shimmer behind image */
.skeleton-wrapper {
  position: relative;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  overflow: hidden;
}

/* The shimmer layer */
.skeleton-wrapper::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, #eeeeee 8%, #dddddd 18%, #eeeeee 33%);
  background-size: 1000px 100%;
  animation: shimmer 1.5s infinite linear;
  z-index: 1;
}

/* The actual image (hidden under shimmer at first) */
.skeleton-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  z-index: 0;
  position: relative;
}

/* Remove shimmer after 3s in JS */
.skeleton-wrapper.done::before {
  display: none;
}

.skeleton-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
}
.author-img {
  width: 48px;
  height: 48px;
  border-radius: 50%;
}
.skeleton-text {
  height: 16px;
  width: 120px;
  margin-top: 4px;
}
