/* =============================================
   Custom CSS for Code 4 All
   Badges, filters, pagination, today's news
   ============================================= */

/* -- Sidebar Improvements -- */
.aside-author-info {
  text-align: center;
  margin-bottom: 10px;
}

.aside-subtitle {
  color: rgba(255,255,255,0.6);
  font-size: 14px;
  letter-spacing: 1px;
  margin-bottom: 0;
}

.aside-social-links {
  text-align: center;
  margin: 20px 0;
}

.aside-social-links a {
  display: inline-block;
  width: 36px;
  height: 36px;
  line-height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.7);
  margin: 0 4px;
  font-size: 16px;
  transition: all 0.3s ease;
  text-align: center;
}

.aside-social-links a:hover {
  background: #F96D00;
  color: #fff;
}

/* -- Section Title -- */
.section-title {
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  font-size: 20px;
  margin-bottom: 20px;
  color: #333;
}

/* -- Today's News Section -- */
.today-news-section {
  background: #f8f9fa;
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 30px;
  border-left: 4px solid #F96D00;
}

.today-news-section .section-title {
  margin-bottom: 15px;
}

#todayNewsContainer {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
}

.today-news-card {
  display: flex;
  background: #fff;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  width: 100%;
}

.today-news-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.12);
}

.today-news-img {
  width: 120px;
  min-height: 100px;
  background-size: cover;
  background-position: center;
  flex-shrink: 0;
}

.today-news-info {
  padding: 12px 15px;
  flex: 1;
}

.today-news-info h4 {
  font-size: 14px;
  font-weight: 600;
  margin: 4px 0 6px;
  line-height: 1.4;
}

.today-news-info h4 a {
  color: #333;
  text-decoration: none;
}

.today-news-info h4 a:hover {
  color: #F96D00;
}

.today-news-meta {
  font-size: 12px;
  color: #999;
  margin-bottom: 4px;
}

/* -- Filter Container -- */
.filter-container {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 25px;
  padding-bottom: 15px;
  border-bottom: 1px solid #eee;
}

.filter-btn {
  background: #f0f0f0;
  border: none;
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 13px;
  font-family: 'Poppins', sans-serif;
  font-weight: 500;
  color: #555;
  cursor: pointer;
  transition: all 0.3s ease;
}

.filter-btn:hover {
  background: #e0e0e0;
  color: #333;
}

.filter-btn.active {
  background: #F96D00;
  color: #fff;
}

/* -- Badges -- */
.post-badges {
  margin-bottom: 8px;
}

.badge-auto {
  display: inline-block;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 12px;
  margin-right: 6px;
  letter-spacing: 0.5px;
}

.badge-category {
  display: inline-block;
  background: #e8e8e8;
  color: #555;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 12px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

/* Category-specific badge colors */
.badge-ai { background: #e3f2fd; color: #1565c0; }
.badge-azure { background: #e0f2f1; color: #00695c; }
.badge-aks { background: #fce4ec; color: #c62828; }
.badge-vm { background: #f3e5f5; color: #6a1b9a; }
.badge-iot { background: #fff3e0; color: #e65100; }
.badge-bot-framework { background: #e8eaf6; color: #283593; }
.badge-llm { background: #e3f2fd; color: #0d47a1; }
.badge-agentes { background: #fce4ec; color: #880e4f; }
.badge-herramientas { background: #e0f7fa; color: #006064; }
.badge-github-repo { background: #efebe9; color: #3e2723; }
.badge-buenas-practicas { background: #f1f8e9; color: #33691e; }
.badge-investigacion { background: #ede7f6; color: #4527a0; }
.badge-ai-news { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); color: #fff; }

/* -- Source Link -- */
.source-link {
  display: inline-block;
  font-size: 12px;
  color: #F96D00;
  text-decoration: none;
  margin-bottom: 8px;
}

.source-link:hover {
  text-decoration: underline;
  color: #e05d00;
}

/* -- Post Tags in cards -- */
.post-tags {
  margin-bottom: 8px;
}

.post-tag {
  display: inline-block;
  background: #f5f5f5;
  color: #777;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 3px;
  margin-right: 4px;
  margin-bottom: 4px;
}

/* -- Post Meta Header (on post.html) -- */
.post-meta-header {
  margin-bottom: 10px;
  width: 100%;
}

.post-meta-header .meta {
  margin-bottom: 0;
}

.post-meta-header .meta span {
  margin-right: 15px;
  color: #999;
  font-size: 14px;
}

/* -- Auto-generated Banner -- */
.auto-gen-banner {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, #667eea20 0%, #764ba220 100%);
  border: 1px solid #667eea40;
  border-radius: 8px;
  padding: 12px 18px;
  margin-bottom: 20px;
  font-size: 14px;
  color: #555;
}

.auto-gen-banner span {
  font-size: 20px;
}

.auto-gen-banner a {
  color: #667eea;
  font-weight: 600;
  margin-left: auto;
}

.auto-gen-banner a:hover {
  color: #4a5bd6;
}

/* -- Pagination Improvements -- */
.block-27 ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  padding: 0;
  margin: 30px 0;
  list-style: none;
  gap: 4px;
}

.block-27 ul li {
  margin: 0;
}

.block-27 ul li a,
.block-27 ul li span {
  display: inline-block;
  width: 36px;
  height: 36px;
  line-height: 36px;
  text-align: center;
  border-radius: 50%;
  font-size: 14px;
  font-weight: 500;
  color: #555;
  text-decoration: none;
  transition: all 0.3s ease;
}

.block-27 ul li a:hover {
  background: #F96D00;
  color: #fff;
}

.block-27 ul li.active span {
  background: #F96D00;
  color: #fff;
}

/* -- View Counter -- */
.post-views {
  color: #999;
  font-size: 13px;
}

.post-views i {
  font-size: 14px;
}

/* -- Blog entry improvements -- */
.blog-entry .text .post-badges {
  margin-bottom: 6px;
}

/* -- Responsive tweaks -- */
@media (max-width: 767px) {
  .today-news-card {
    flex-direction: column;
  }

  .today-news-img {
    width: 100%;
    min-height: 150px;
  }

  .filter-container {
    gap: 6px;
  }

  .filter-btn {
    font-size: 12px;
    padding: 5px 12px;
  }

  .auto-gen-banner {
    flex-direction: column;
    text-align: center;
  }

  .auto-gen-banner a {
    margin-left: 0;
  }
}
