/* ==========================================================================
   HALAMAN PENCARIAN TERPADU (FEDERATED GLOBAL SEARCH)
   File: public/css/pages/pencarian.css
   Institut Kesehatan Karsa Husada Garut
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. HERO BANNER PENCARIAN (Konsisten dengan Warna Landing Pages & Subpages)
   -------------------------------------------------------------------------- */
.search-page-banner {
  background-color: #09a89e;
  background: #09a89e;
  color: #ffffff;
  padding: 3.5rem 0 3rem;
  position: relative;
  overflow: hidden;
  border-bottom: 4px solid var(--accent-gold);
}

.search-page-banner::before {
  content: "";
  position: absolute;
  top: -40%;
  right: -10%;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.12) 0%, transparent 70%);
  pointer-events: none;
}

.search-banner-content {
  position: relative;
  z-index: 2;
  width: 100%;
}

.search-badge-top {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  margin-bottom: 0.85rem;
}

.search-banner-title {
  color: #ffffff !important;
  font-size: 2.35rem;
  font-weight: 800;
  line-height: 1.25;
  margin-bottom: 0.65rem;
  letter-spacing: -0.025em;
}

.search-banner-desc {
  font-size: 1.05rem;
  color: rgba(255, 255, 255, 0.95) !important;
  line-height: 1.6;
  max-width: 880px;
  margin-bottom: 1.75rem;
}

/* Form Pencarian Kapsul Putih Konsisten */
.search-banner-form {
  max-width: 900px;
  width: 100%;
}

.search-banner-input-box {
  position: relative;
  background: #ffffff;
  border-radius: 50px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
  display: flex;
  align-items: center;
  padding: 0.35rem 0.45rem 0.35rem 1.4rem;
  transition: all 0.2s ease;
  border: 2px solid transparent;
}

.search-banner-input-box:focus-within {
  border-color: var(--accent-gold);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2), 0 0 0 3px rgba(255, 184, 48, 0.35);
}

.search-banner-icon {
  color: #09a89e;
  flex-shrink: 0;
  margin-right: 0.75rem;
  display: flex;
  align-items: center;
}

.search-banner-input {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 1.05rem;
  font-weight: 500;
  color: #0f172a;
  outline: none;
  padding: 0.65rem 0;
}

.search-banner-input::placeholder {
  color: #94a3b8;
  font-weight: 400;
}

.search-banner-clear {
  background: none;
  border: none;
  color: #94a3b8;
  padding: 0.5rem;
  cursor: pointer;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.18s ease;
}

.search-banner-clear:hover {
  color: #475569;
  background: #f1f5f9;
}

.search-banner-submit {
  background: #09a89e;
  color: #ffffff;
  border: none;
  padding: 0.75rem 1.75rem;
  border-radius: 50px;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.2s ease;
  margin-left: 0.5rem;
}

.search-banner-submit:hover {
  background: #078f86;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(9, 168, 158, 0.35);
}

/* --------------------------------------------------------------------------
   2. SECTION KONTEN HASIL PENCARIAN (FULL WIDTH CONTAINER)
   -------------------------------------------------------------------------- */
.search-content-section {
  padding: 2.5rem 0 4.5rem;
  background-color: #f8fafc;
  min-height: 550px;
}

/* --------------------------------------------------------------------------
   3. FILTER KATEGORI (SEGMENTED PILLS)
   -------------------------------------------------------------------------- */
.search-filter-tabs {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.75rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  scrollbar-width: none;
}

.search-filter-tabs::-webkit-scrollbar {
  display: none;
}

.search-tab-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.5rem 1.15rem;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  color: #475569;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
  user-select: none;
}

.search-tab-pill:hover {
  border-color: #cbd5e1;
  background: #f1f5f9;
  color: #0f172a;
}

.search-tab-pill.is-active {
  background: #09a89e;
  border-color: #09a89e;
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(9, 168, 158, 0.25);
}

.search-tab-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.25rem;
  height: 1.25rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  background: #e2e8f0;
  color: #475569;
  line-height: 1;
}

.search-tab-pill.is-active .search-tab-count {
  background: rgba(255, 255, 255, 0.25);
  color: #ffffff;
}

/* --------------------------------------------------------------------------
   4. SUMMARY INFO BAR
   -------------------------------------------------------------------------- */
.search-meta-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.75rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid #e2e8f0;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.search-meta-text {
  font-size: 0.9375rem;
  color: #64748b;
}

.search-meta-text strong {
  color: #0f172a;
}

/* --------------------------------------------------------------------------
   5. SMART HIGHLIGHT (PANDUAN / HALAMAN KHUSUS)
   -------------------------------------------------------------------------- */
.smart-guide-card {
  background: #ffffff;
  border: 1px solid #ccfbf1;
  border-left: 4px solid #09a89e;
  border-radius: 10px;
  padding: 1.25rem 1.75rem;
  margin-bottom: 2rem;
  box-shadow: 0 4px 12px rgba(9, 168, 158, 0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  width: 100%;
}

.smart-guide-content {
  flex: 1;
}

.smart-guide-badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #0f766e;
  background: #f0fdfa;
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  margin-bottom: 0.35rem;
}

.smart-guide-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 0.35rem;
}

.smart-guide-desc {
  font-size: 0.9rem;
  color: #475569;
  line-height: 1.5;
  margin: 0;
}

.smart-guide-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: #09a89e;
  color: #ffffff;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.65rem 1.25rem;
  border-radius: 7px;
  text-decoration: none;
  white-space: nowrap;
  transition: all 0.18s ease;
  flex-shrink: 0;
}

.smart-guide-btn:hover {
  background: #078f86;
  color: #ffffff;
  transform: translateY(-1px);
}

/* --------------------------------------------------------------------------
   6. GRUP SECTION HASIL PENCARIAN
   -------------------------------------------------------------------------- */
.search-group-section {
  margin-bottom: 2.75rem;
  width: 100%;
}

.search-group-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #edf2f7;
}

.search-group-title {
  font-size: 1.2rem;
  font-weight: 800;
  color: #0a192f;
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.search-group-badge {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
  background: #e2e8f0;
  color: #475569;
}

.search-group-more {
  font-size: 0.875rem;
  font-weight: 600;
  color: #09a89e;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  transition: all 0.18s ease;
}

.search-group-more:hover {
  color: #078f86;
  transform: translateX(2px);
}

/* --------------------------------------------------------------------------
   7. LIST / ROW VIEW HASIL PENCARIAN (BUKAN CARD / TIDAK ADA SPACE KOSONG)
   -------------------------------------------------------------------------- */
.search-results-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  width: 100%;
}

.search-list-item {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 1.35rem 1.65rem;
  width: 100%;
  transition: all 0.2s ease;
  position: relative;
  border-left: 4px solid transparent;
}

.search-list-item:hover {
  border-color: #cbd5e1;
  border-left-color: #09a89e;
  box-shadow: 0 6px 20px rgba(10, 25, 47, 0.06);
  transform: translateY(-1px);
}

/* Top Meta Row */
.search-item-top {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 0.6rem;
}

.search-item-type-tag {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.22rem 0.6rem;
  border-radius: 4px;
  flex-shrink: 0;
}

.tag-buku {
  background: #e0f2fe;
  color: #0369a1;
}

.tag-repository {
  background: #ecfdf5;
  color: #047857;
}

.tag-ebook {
  background: #f5f3ff;
  color: #6d28d9;
}

.tag-informasi {
  background: #fff7ed;
  color: #c2410c;
}

.tag-panduan {
  background: #f0fdfa;
  color: #0f766e;
}

.search-item-meta-chips {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
  font-size: 0.8125rem;
  color: #64748b;
}

.search-item-meta-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.search-item-meta-chip svg {
  color: #94a3b8;
  flex-shrink: 0;
}

.search-item-meta-chip code {
  background: #f1f5f9;
  color: #0f172a;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  font-size: 0.8rem;
  font-weight: 600;
}

/* Item Title */
.search-item-title {
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.35;
  margin: 0 0 0.45rem;
}

.search-item-title a {
  color: #0a192f;
  text-decoration: none;
  transition: color 0.18s ease;
}

.search-item-title a:hover {
  color: #09a89e;
}

/* Item Excerpt / Deskripsi */
.search-item-desc {
  font-size: 0.9rem;
  color: #475569;
  line-height: 1.6;
  margin: 0 0 0.85rem;
  max-width: 1400px;
}

/* Bottom Action & Status Bar */
.search-item-bottom {
  padding-top: 0.85rem;
  border-top: 1px solid #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.search-item-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: #475569;
  background: #f8fafc;
  padding: 0.25rem 0.65rem;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
}

.search-item-status-badge svg {
  color: #09a89e;
}

.search-item-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.84rem;
  font-weight: 700;
  color: #09a89e;
  text-decoration: none;
  padding: 0.4rem 0.85rem;
  border-radius: 6px;
  background: #e6f7f6;
  transition: all 0.18s ease;
}

.search-item-action-btn:hover {
  background: #09a89e;
  color: #ffffff;
  transform: translateX(2px);
}

.search-item-action-btn svg {
  transition: transform 0.18s ease;
}

.search-item-action-btn:hover svg {
  transform: translateX(3px);
}

/* --------------------------------------------------------------------------
   8. EMPTY STATE (TIDAK ADA HASIL / AWAL)
   -------------------------------------------------------------------------- */
.search-empty-box {
  background: #ffffff;
  border: 1px dashed #cbd5e1;
  border-radius: 12px;
  padding: 4rem 2rem;
  text-align: center;
  margin: 1.5rem 0;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.search-empty-icon-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  margin: 0 auto 1.25rem auto;
  text-align: center;
}

.search-empty-icon {
  width: 56px;
  height: 56px;
  color: #94a3b8;
  display: block;
  margin: 0 auto;
}

.search-empty-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 0.5rem;
}

.search-empty-desc {
  font-size: 0.9375rem;
  color: #64748b;
  max-width: 620px;
  margin: 0 auto 1.5rem;
  line-height: 1.6;
}

.search-empty-tips {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 1.15rem 1.5rem;
  max-width: 580px;
  margin: 0 auto 1.75rem;
  text-align: left;
}

.search-tips-label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 0.45rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.search-tips-list {
  list-style: disc;
  padding-left: 1.25rem;
  margin: 0;
  font-size: 0.875rem;
  color: #475569;
  line-height: 1.6;
}

.search-tips-list li {
  margin-bottom: 0.25rem;
}

.search-empty-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.btn-search-outline {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.65rem 1.25rem;
  border-radius: 8px;
  border: 1px solid #cbd5e1;
  background: #ffffff;
  color: #334155;
  font-size: 0.875rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.18s ease;
}

.btn-search-outline:hover {
  background: #f8fafc;
  border-color: #94a3b8;
  color: #0f172a;
}

.btn-search-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.65rem 1.25rem;
  border-radius: 8px;
  background: #09a89e;
  color: #ffffff;
  font-size: 0.875rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.18s ease;
}

.btn-search-primary:hover {
  background: #078f86;
  color: #ffffff;
  transform: translateY(-1px);
}

/* --------------------------------------------------------------------------
   9. RESPONSIVE MOBILE
   -------------------------------------------------------------------------- */
@media (max-width: 768px) {
  .search-page-banner {
    padding: 2.5rem 0 2rem;
  }

  .search-banner-title {
    font-size: 1.65rem;
  }

  .search-banner-input-box {
    padding: 0.25rem 0.35rem 0.25rem 1rem;
  }

  .search-banner-input {
    font-size: 0.95rem;
  }

  .search-banner-submit {
    padding: 0.65rem 1.2rem;
    font-size: 0.875rem;
  }

  .smart-guide-card {
    flex-direction: column;
    align-items: flex-start;
    padding: 1.15rem;
  }

  .search-list-item {
    padding: 1.15rem 1.25rem;
  }

  .search-item-top {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.45rem;
  }

  .search-item-bottom {
    flex-direction: column;
    align-items: flex-start;
  }

  .search-item-action-btn {
    width: 100%;
    justify-content: center;
  }

  /* Empty State Responsive Mobile */
  .search-empty-box {
    padding: 2rem 1rem !important;
    margin: 1.5rem auto !important;
    border-radius: 12px !important;
  }

  .search-empty-icon-wrap {
    margin-bottom: 0.75rem !important;
  }

  .search-empty-icon {
    width: 44px !important;
    height: 44px !important;
  }

  .search-empty-title {
    font-size: 0.95rem !important;
    margin-bottom: 0.35rem !important;
  }

  .search-empty-desc {
    font-size: 0.78rem !important;
    line-height: 1.45 !important;
    margin-bottom: 1.15rem !important;
  }

  .search-empty-tips {
    padding: 0.85rem 1rem !important;
    margin-bottom: 1.25rem !important;
  }

  .search-tips-label {
    font-size: 0.72rem !important;
  }

  .search-tips-list {
    font-size: 0.75rem !important;
    line-height: 1.45 !important;
  }

  .btn-search-primary,
  .btn-search-outline {
    font-size: 0.80rem !important;
    padding: 0.55rem 1rem !important;
    width: 100% !important;
    justify-content: center !important;
  }
}

@media (max-width: 480px) {
  .search-banner-title {
    font-size: 1.25rem !important;
  }

  .search-banner-submit {
    padding: 0.5rem 1rem !important;
    font-size: 0.80rem !important;
  }
}

