/* ========================================================
   CSS TRANG TÌM KIẾM TỔNG HỢP (TÁCH RIÊNG HOÀN TOÀN)
======================================================== */

.search-page-bg {
  min-height: 100vh;
  background-color: #f8fafc;
  padding-top: 1.5rem;
  padding-bottom: 4rem;
}

/* Thanh chuyển tab trên đầu */
.search-tabs-pill-bar {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 50px;
  padding: 4px;
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.04);
}
.search-tab-pill {
  padding: 6px 16px;
  border-radius: 50px;
  font-size: 13.5px;
  font-weight: 600;
  color: #64748b;
  text-decoration: none;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.search-tab-pill:hover {
  color: #0f172a;
  background: #f1f5f9;
}
.search-tab-pill.active {
  background: #0284c7;
  color: #ffffff;
  box-shadow: 0 4px 10px rgba(2, 132, 199, 0.25);
}

/* ========================================================
   SIDEBAR BỘ LỌC (KHÔNG DÙNG STICKY, KHÔNG CUỘN TRONG)
======================================================== */
.search-sidebar-box {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 20px;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.03);
  position: static !important;
}

.search-sidebar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 12px;
  margin-bottom: 16px;
  border-bottom: 1px solid #f1f5f9;
}

.search-sidebar-title {
  font-size: 13.5px;
  font-weight: 700;
  color: #0f172a;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.search-sidebar-title svg {
  color: #0284c7;
}

.search-sidebar-reset {
  font-size: 12px;
  font-weight: 600;
  color: #ef4444;
  background: #fef2f2;
  padding: 3px 10px;
  border-radius: 12px;
  text-decoration: none;
  transition: all 0.2s ease;
}
.search-sidebar-reset:hover {
  background: #fee2e2;
  color: #dc2626;
}

.search-filter-section {
  margin-bottom: 18px;
  padding-bottom: 16px;
  border-bottom: 1px solid #f1f5f9;
}
.search-filter-section:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.search-filter-heading {
  font-size: 12px;
  font-weight: 700;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 10px;
}

/* Danh mục chips: trực quan, bo tròn gọn gàng, tự nhiên */
.search-chips-group {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.search-chip-filter {
  display: inline-flex;
  align-items: center;
  padding: 6px 13px;
  border-radius: 20px;
  font-size: 12.5px;
  font-weight: 500;
  color: #475569;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  text-decoration: none;
  transition: all 0.18s ease;
  white-space: nowrap;
}
.search-chip-filter:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
  color: #0f172a;
}
.search-chip-filter.active {
  background: #0284c7;
  color: #ffffff;
  border-color: #0284c7;
  font-weight: 600;
  box-shadow: 0 2px 6px rgba(2, 132, 199, 0.25);
}

/* ========================================================
   KHỐI NỘI DUNG VÀ THẺ (CARDS)
======================================================== */
.search-section-box {
  margin-bottom: 2rem;
}

.search-section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 1.5px solid #eef2f6;
}

.search-section-title {
  font-size: 17px;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.search-view-all-link {
  font-size: 13px;
  font-weight: 600;
  color: #0284c7;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all 0.2s ease;
}
.search-view-all-link:hover {
  color: #0369a1;
  transform: translateX(2px);
  text-decoration: none;
}

/* Thẻ card_t dùng chung cho Flashcard, Quiz, Kingdom */
.search-page-bg .card_t {
  background: #ffffff;
  border: 1px solid #e8ecf4;
  border-radius: 12px;
  padding: 12px 14px;
  display: flex;
  gap: 12px;
  text-decoration: none;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.03);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  overflow: hidden;
}
.search-page-bg .card_t:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px -3px rgba(15, 23, 42, 0.08);
  border-color: #cbd5e1;
}

.search-page-bg .card_t-details {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.search-page-bg .card_t-title {
  font-weight: 700;
  font-size: 14px;
  line-height: 1.35;
  color: #0f172a;
  margin-bottom: 4px;
  transition: color 0.18s ease;
}
.search-page-bg .card_t:hover .card_t-title {
  color: #0284c7;
}

.search-page-bg .card_t-meta {
  font-size: 11.5px;
  margin: 2px 0 6px;
}
.search-page-bg .card_t-meta.text-main {
  color: #d97706;
  font-weight: 600;
}
.search-page-bg .card_t-meta.text-quiz {
  color: #7c3aed;
  font-weight: 600;
}
.search-page-bg .card_t-meta.text-kingdom {
  color: #0284c7;
  font-weight: 600;
}

.search-page-bg .card_t-author {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11.5px;
  color: #64748b;
  margin-top: auto;
  padding-top: 6px;
  border-top: 1px dashed #f1f5f9;
}
.search-page-bg .card_t-author img {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid #e2e8f0;
}

.search-page-bg img.thumb_fc {
  width: 62px;
  height: 62px;
  max-width: 62px;
  max-height: 62px;
  border-radius: 10px;
  object-fit: cover;
  border: 1px solid #edf2f7;
  background: #f8fafc;
  margin-top: 0;
  align-self: flex-start;
  flex-shrink: 0;
  transition: transform 0.2s ease;
}
.search-page-bg .card_t:hover img.thumb_fc {
  transform: scale(1.03);
}

/* ========================================================
   PHÂN TRANG (PAGINATION)
======================================================== */
.search-page-bg .section-pagination {
  margin-top: 18px;
}
.search-page-bg .pagination {
  display: flex;
  gap: 6px;
  list-style: none;
  padding: 0;
  margin: 0;
  align-items: center;
}
.search-page-bg .pagination .page-item a,
.search-page-bg .pagination .page-item span {
  width: 34px;
  height: 34px;
  border-radius: 50% !important;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 600;
  border: 1px solid #e2e8f0;
  background: #ffffff;
  color: #475569;
  text-decoration: none;
  transition: all 0.18s ease;
}
.search-page-bg .pagination .page-item a:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
  color: #0f172a;
}
.search-page-bg .pagination .page-item.active span {
  background: #0284c7 !important;
  border-color: #0284c7 !important;
  color: #ffffff !important;
  box-shadow: 0 4px 10px rgba(2, 132, 199, 0.3);
}
.search-page-bg .pagination .page-item.disabled span {
  opacity: 0.45;
  cursor: not-allowed;
}
