/* ── BLOG ── */

.blog-filters-section {
  background: var(--bg-light);
  padding: 20px 0 16px;
  border-bottom: 1px solid var(--border);
}
.blog-search-wrap { position: relative; margin-bottom: 14px; }
.blog-search-wrap i {
  position: absolute; left: 16px; top: 50%; transform: translateY(-50%); color: var(--text-muted);
}
.blog-search {
  width: 100%; padding: 11px 16px 11px 44px; border: 1px solid var(--border);
  border-radius: 10px; font-size: 15px; background: #fff;
}
.blog-search:focus { outline: none; border-color: var(--purple); box-shadow: 0 0 0 3px rgba(99,102,241,.15); }
.blog-filter-group { margin-bottom: 12px; }
.blog-filter-label {
  display: block; font-size: 11px; font-weight: 700; letter-spacing: 1px;
  text-transform: uppercase; color: var(--text-muted); margin-bottom: 8px;
}
.blog-filter-row, .blog-tag-row {
  display: flex; flex-wrap: nowrap; gap: 8px; overflow-x: auto;
  -webkit-overflow-scrolling: touch; scrollbar-width: none; padding-bottom: 4px;
}
.blog-filter-row::-webkit-scrollbar, .blog-tag-row::-webkit-scrollbar { display: none; }
.blog-filter-row > *, .blog-tag-row > * { flex-shrink: 0; }
.blog-filter-btn {
  background: #fff; border: 1px solid var(--border); border-radius: 8px;
  padding: 8px 16px; font-size: 13px; font-weight: 600; cursor: pointer; white-space: nowrap;
}
.blog-filter-btn.active { background: var(--gradient); border-color: transparent; color: #fff; }
.blog-tag-pill {
  background: rgba(99,102,241,.08); border: 1px solid rgba(99,102,241,.2);
  border-radius: 20px; padding: 6px 14px; font-size: 12px; font-weight: 600;
  color: var(--purple); cursor: pointer; white-space: nowrap;
}
.blog-tag-pill.active { background: var(--purple); color: #fff; }
.blog-results-count { font-size: 13px; color: var(--text-muted); margin: 4px 0 0; }

.blog-grid-section { padding: 48px 0 64px; }
.blog-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 28px;
}
.blog-card-link {
  display: block; background: #fff; border-radius: 16px; overflow: hidden;
  border: 1px solid var(--border); height: 100%; transition: box-shadow .25s, transform .25s;
}
.blog-card-link:hover { box-shadow: 0 16px 48px rgba(99,102,241,.15); transform: translateY(-4px); }
.blog-card-img { position: relative; aspect-ratio: 16/10; overflow: hidden; }
.blog-card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.blog-card-link:hover .blog-card-img img { transform: scale(1.05); }
.blog-badge {
  position: absolute; top: 12px; left: 12px; background: var(--gradient);
  color: #fff; font-size: 11px; font-weight: 700; padding: 5px 10px; border-radius: 6px;
}
.blog-cat {
  position: absolute; bottom: 12px; left: 12px; background: rgba(11,13,23,.85);
  color: #fff; font-size: 11px; font-weight: 700; padding: 5px 10px; border-radius: 6px;
}
.blog-card-body { padding: 20px; }
.blog-card-body time { font-size: 12px; color: var(--text-muted); }
.blog-card-body h2 { font-size: 18px; font-weight: 800; margin: 8px 0; line-height: 1.3; }
.blog-card-body p {
  font-size: 14px; color: var(--text-muted); margin-bottom: 14px;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.blog-read-more { font-size: 13px; font-weight: 700; color: var(--purple); }

.blog-loading { padding: 8px 0 24px; }
.blog-skeleton-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 28px;
}
.blog-skeleton-card {
  height: 340px; border-radius: 16px;
  background: linear-gradient(90deg, #f0f0f5 25%, #e8e8f0 50%, #f0f0f5 75%);
  background-size: 200% 100%; animation: blog-shimmer 1.2s infinite;
}
@keyframes blog-shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
.blog-empty { text-align: center; padding: 60px 20px; color: var(--text-muted); }
.blog-empty i { font-size: 48px; display: block; margin-bottom: 16px; }

/* Detail */
.blog-detail { padding: 40px 0 80px; }
@media (min-width: 992px) {
  .blog-detail { padding-top: 56px; }
}
.blog-detail-title {
  font-size: clamp(1.5rem, 3.5vw, 2.5rem); font-weight: 800; line-height: 1.25; margin-bottom: 20px;
}
.blog-detail-meta { font-size: 14px; color: var(--text-muted); margin-bottom: 28px; }
.blog-detail-img { border-radius: 16px; overflow: hidden; margin-bottom: 24px; }
.blog-detail-meta i { color: var(--purple); margin-right: 4px; }
.blog-detail-img img { width: 100%; aspect-ratio: 16/9; object-fit: cover; }
.blog-detail-content {
  font-size: 16px; line-height: 1.85; color: var(--text-dark);
}
.blog-detail-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px; }
.blog-tag {
  display: inline-block; font-size: 12px; font-weight: 600; padding: 6px 12px;
  border-radius: 8px; background: rgba(99,102,241,.12); color: var(--purple);
}
.blog-sidebar-block {
  background: var(--bg-light); border: 1px solid var(--border); border-radius: 14px; padding: 20px;
}
.blog-sidebar-block h3 { font-size: 16px; font-weight: 800; margin-bottom: 10px; }
.blog-sidebar-block h3 i { color: var(--purple); margin-right: 6px; }
.blog-related { margin-top: 48px; padding-top: 32px; border-top: 1px solid var(--border); }
.blog-related-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; }
.blog-related-card {
  display: flex; flex-direction: column; border: 1px solid var(--border);
  border-radius: 12px; overflow: hidden;
}
.blog-related-card img { aspect-ratio: 16/10; object-fit: cover; }
.blog-related-card div { padding: 12px; }
.blog-related-card h4 { font-size: 14px; font-weight: 700; margin: 4px 0 0; }

@media (max-width: 767.98px) {
  .blog-filters-section { padding: 14px 0 10px; }
  .blog-filter-row, .blog-tag-row {
    margin-left: -30px; margin-right: -30px; padding-left: 30px; padding-right: 30px;
  }
  .blog-grid { grid-template-columns: 1fr; }
  .blog-grid-section { padding-top: 24px; }
}
