/* Card & content skeletons while JSON / article content loads */

@keyframes skShimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

.sk-block,
.sk-line {
  display: block;
  border-radius: 6px;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0.03) 25%,
    rgba(255, 255, 255, 0.1) 50%,
    rgba(255, 255, 255, 0.03) 75%
  );
  background-size: 220% 100%;
  animation: skShimmer 1.2s linear infinite;
}

.sk-line--tag {
  width: 4.5rem;
  height: 1.25rem;
  border-radius: 4px;
  margin-bottom: 0.65rem;
}

.sk-line--title {
  width: 92%;
  height: 1.1rem;
  margin-bottom: 0.45rem;
}

.sk-line--title-short {
  width: 68%;
  height: 1.1rem;
  margin-bottom: 0.55rem;
}

.sk-line--meta {
  width: 55%;
  height: 0.75rem;
}

.sk-line--excerpt {
  width: 100%;
  height: 0.8rem;
  margin-bottom: 0.4rem;
}

.sk-line--excerpt-short {
  width: 78%;
  height: 0.8rem;
  margin-bottom: 0.65rem;
}

/* ── Activity card skeleton ── */
.act-card--skeleton {
  pointer-events: none;
  cursor: default;
}

.act-card--skeleton:hover {
  transform: none;
  box-shadow: none;
}

.act-card--skeleton .act-img-wrap {
  background: var(--bg3);
}

.act-card--skeleton .sk-block {
  width: 100%;
  height: 100%;
  min-height: 100%;
  border-radius: 0;
}

/* ── Blog card skeleton ── */
.blog-card--skeleton {
  pointer-events: none;
  cursor: default;
}

.blog-card--skeleton:hover {
  transform: none;
  box-shadow: none;
  border-color: var(--line);
}

.blog-card--skeleton .blog-cover {
  background: var(--bg3);
}

.blog-card--skeleton .sk-block {
  width: 100%;
  height: 100%;
  min-height: 100%;
  border-radius: 0;
}

/* Stagger skeleton cards */
.act-card--skeleton:nth-child(1),
.blog-card--skeleton:nth-child(1) {
  animation-delay: 0s;
}
.act-card--skeleton:nth-child(2),
.blog-card--skeleton:nth-child(2) {
  animation-delay: 0.06s;
}
.act-card--skeleton:nth-child(3),
.blog-card--skeleton:nth-child(3) {
  animation-delay: 0.12s;
}
.act-card--skeleton:nth-child(4),
.blog-card--skeleton:nth-child(4) {
  animation-delay: 0.18s;
}
.act-card--skeleton:nth-child(5),
.blog-card--skeleton:nth-child(5) {
  animation-delay: 0.24s;
}
.act-card--skeleton:nth-child(6),
.blog-card--skeleton:nth-child(6) {
  animation-delay: 0.3s;
}
.act-card--skeleton:nth-child(n + 7),
.blog-card--skeleton:nth-child(n + 7) {
  animation-delay: 0.36s;
}

.act-grid.grid-is-loading,
.blog-grid.grid-is-loading {
  min-height: 280px;
}

/* ── Blog modal / article body skeleton ── */
.blog-body-skeleton {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  padding: 0.25rem 0;
}

.blog-body-skeleton .sk-line--heading {
  width: 48%;
  height: 1.35rem;
  margin: 0.5rem 0 0.35rem;
  border-radius: 6px;
}

.blog-body-skeleton .sk-line--para {
  width: 100%;
  height: 0.85rem;
}

.blog-body-skeleton .sk-line--para-mid {
  width: 94%;
  height: 0.85rem;
}

.blog-body-skeleton .sk-line--para-short {
  width: 72%;
  height: 0.85rem;
  margin-bottom: 0.5rem;
}

.blog-body-skeleton .sk-block--code {
  width: 100%;
  height: 7.5rem;
  border-radius: var(--radius-sm, 8px);
  margin: 0.35rem 0 0.75rem;
}

.blog-full-skeleton .blog-full-cover.sk-block {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  margin: 1.25rem 0 1.5rem;
}

@media (prefers-reduced-motion: reduce) {
  .sk-block,
  .sk-line {
    animation: none;
    background: rgba(255, 255, 255, 0.06);
  }
}
