<article class="bg-white rounded-2xl overflow-hidden border border-gray-100 shadow-sm card-hover">
  <div class="<%= imgClass %> relative" style="height:160px">
    <% if (post.imageCover) { %>
      <img src="<%= post.imageCover %>" alt="" class="absolute inset-0 w-full h-full object-cover" />
    <% } %>
    <div class="absolute top-3 right-3">
      <span class="text-[9px] font-bold uppercase tracking-wider px-2.5 py-1 rounded-full text-white" style="background:rgba(0,0,0,.3)"><%= catLabel %></span>
    </div>
    <% if (post.promote === 'true') { %>
      <div class="absolute top-3 left-3">
        <span class="pulse-dot w-1.5 h-1.5 rounded-full inline-block bg-white mr-1"></span>
        <span style="font-size:9px;color:rgba(255,255,255,.8);font-weight:600">Featured</span>
      </div>
    <% } %>
  </div>
  <div class="p-5">
    <h3 class="font-bold text-navy text-sm leading-snug mb-2">
      <a href="/blog/<%= post.slug %>" class="hover:text-purple transition-colors"><%= post.name %></a>
    </h3>
    <% if (post.description) { %>
      <p class="text-xs text-gray-500 leading-relaxed mb-4 line-clamp-3"><%= post.description %></p>
    <% } %>
    <div class="flex items-center justify-between">
      <div class="flex items-center gap-2">
        <div class="w-6 h-6 rounded-full flex items-center justify-center text-white" style="font-size:8px;font-weight:700;background:#8065f8"><%= initials %></div>
        <div>
          <p style="font-size:10px" class="font-semibold text-navy"><%= post.author || 'Analytics Grade Team' %></p>
          <p style="font-size:9px" class="text-gray-400"><%= dateStr %></p>
        </div>
      </div>
      <a href="/blog/<%= post.slug %>" class="text-xs font-semibold text-purple hover:underline flex items-center gap-1">
        Read
        <svg class="w-3 h-3" fill="none" stroke="currentColor" stroke-width="2.5" viewBox="0 0 24 24">
          <path stroke-linecap="round" stroke-linejoin="round" d="M13 7l5 5-5 5M6 12h12"/>
        </svg>
      </a>
    </div>
  </div>
</article>
