/* ============================================================
   Insights (blog) — daftar artikel & halaman detail
   Dimuat hanya pada insights.php dan insight.php.
   ============================================================ */

/* ---------- Toolbar: pencarian & filter kategori ---------- */
.insight-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow-sm);
  margin-bottom: 18px;
}

.insight-search {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1 1 280px;
  max-width: 420px;
  background: var(--light);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 6px 6px 6px 16px;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.insight-search:focus-within {
  border-color: var(--cyan-400);
  box-shadow: 0 0 0 4px rgba(56, 189, 248, 0.14);
}

.insight-search>i {
  color: var(--navy-700);
  font-size: 1rem;
}

.insight-search input {
  flex: 1;
  border: 0;
  background: transparent;
  outline: none;
  font-size: 0.94rem;
  color: var(--text);
  min-width: 0;
}

.insight-search button {
  border: 0;
  background: var(--grad-cyan);
  color: #fff;
  font-weight: 600;
  font-size: 0.86rem;
  padding: 8px 18px;
  border-radius: 999px;
  cursor: pointer;
  transition: opacity 0.25s ease;
}

.insight-search button:hover {
  opacity: 0.88;
}

.insight-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ifilter {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--text);
  font-size: 0.84rem;
  font-weight: 600;
}

.ifilter:hover {
  border-color: var(--cyan-400);
  color: var(--navy-700);
}

.ifilter.active {
  background: var(--navy-900);
  border-color: var(--navy-900);
  color: #fff;
}

.ifcount {
  font-size: 0.72rem;
  padding: 1px 7px;
  border-radius: 999px;
  background: rgba(10, 29, 63, 0.08);
}

.ifilter.active .ifcount {
  background: rgba(255, 255, 255, 0.18);
}

.insight-count {
  font-size: 0.88rem;
  color: #6b7c99;
  margin: 0 0 26px;
}

/* ---------- Kartu artikel ---------- */
.insight-card {
  height: 100%;
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}

.insight-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
  border-color: rgba(56, 189, 248, 0.5);
}

.insight-thumb {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--navy-900);
}

.insight-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.insight-card:hover .insight-thumb img {
  transform: scale(1.06);
}

.insight-cat {
  position: absolute;
  top: 14px;
  left: 14px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(4, 10, 24, 0.72);
  backdrop-filter: blur(6px);
  color: var(--cyan-300);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

.insight-pending {
  position: absolute;
  bottom: 12px;
  left: 12px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255, 248, 230, 0.95);
  color: #8a5a00;
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.3px;
  text-transform: uppercase;
}

.article-notice {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 0 0 22px;
  padding: 14px 16px;
  border: 1px solid #f2ddb0;
  border-radius: 12px;
  background: #fff8e6;
  color: #8a5a00;
  font-size: 0.88rem;
  line-height: 1.6;
}

.article-notice i {
  margin-top: 2px;
  font-size: 1.05rem;
}

.insight-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 22px 22px 24px;
}

.insight-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  font-size: 0.78rem;
  color: #7c8aa5;
  margin-bottom: 10px;
}

.insight-meta i {
  color: var(--cyan-400);
}

.insight-title {
  font-size: 1.08rem;
  line-height: 1.45;
  margin: 0 0 10px;
}

.insight-title a {
  color: var(--heading);
}

.insight-title a:hover {
  color: var(--blue-500);
}

.insight-excerpt {
  font-size: 0.9rem;
  color: var(--text);
  margin: 0 0 18px;
}

.insight-more {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 0.86rem;
  color: var(--blue-500);
}

.insight-more i {
  transition: transform 0.25s ease;
}

.insight-more:hover i {
  transform: translateX(4px);
}

/* ---------- Pagination ---------- */
.insight-pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 50px;
}

.ipage {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  height: 42px;
  padding: 0 12px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--navy-800);
  font-weight: 600;
  font-size: 0.9rem;
}

.ipage:hover {
  border-color: var(--cyan-400);
  color: var(--blue-500);
}

.ipage.active {
  background: var(--navy-900);
  border-color: var(--navy-900);
  color: #fff;
}

/* ---------- Empty state ---------- */
.insight-empty {
  text-align: center;
  padding: 70px 24px;
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  background: var(--light);
}

.insight-empty i {
  font-size: 2.6rem;
  color: var(--cyan-400);
}

.insight-empty h1 {
  margin: 16px 0 8px;
  font-size: 1.25rem;
}

.insight-empty p {
  max-width: 460px;
  margin: 0 auto 20px;
  font-size: 0.94rem;
}

/* ---------- Halaman detail artikel ---------- */
.article-hero {
  background: var(--grad-navy);
  padding: 170px 0 70px;
  position: relative;
  overflow: hidden;
}

.article-hero::after {
  content: "";
  position: absolute;
  right: -120px;
  top: -120px;
  width: 380px;
  height: 380px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.28), transparent 68%);
}

.article-crumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.62);
  margin-bottom: 22px;
}

.article-crumb a {
  color: var(--cyan-300);
}

.article-crumb .current {
  color: rgba(255, 255, 255, 0.85);
}

.article-cat {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(56, 189, 248, 0.16);
  border: 1px solid rgba(56, 189, 248, 0.4);
  color: var(--cyan-300);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.article-title {
  color: #fff;
  font-size: clamp(1.7rem, 3.4vw, 2.7rem);
  line-height: 1.28;
  max-width: 900px;
  margin: 0 0 20px;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.85rem;
}

.article-meta i {
  color: var(--cyan-400);
  margin-right: 4px;
}

.article-cover {
  margin: -50px 0 46px;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  position: relative;
  z-index: 2;
  background: var(--navy-900);
}

.article-cover img {
  width: 100%;
  max-height: 480px;
  object-fit: cover;
  display: block;
}

.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 54px;
  padding-bottom: 90px;
}

.article-content {
  font-size: 1.02rem;
  color: var(--text);
  line-height: 1.85;
}

.article-content>*:first-child {
  margin-top: 0;
}

.article-content h2 {
  font-size: 1.5rem;
  margin: 40px 0 14px;
}

.article-content h3 {
  font-size: 1.16rem;
  margin: 28px 0 10px;
}

.article-content p {
  margin-bottom: 18px;
}

.article-content ul,
.article-content ol {
  margin: 0 0 20px;
  padding-left: 22px;
}

.article-content li {
  margin-bottom: 8px;
}

.article-content a {
  color: var(--blue-500);
  text-decoration: underline;
}

.article-content blockquote {
  margin: 26px 0;
  padding: 18px 24px;
  border-left: 4px solid var(--cyan-400);
  background: var(--light);
  border-radius: 0 12px 12px 0;
  font-style: italic;
  color: var(--navy-800);
}

.article-content img {
  border-radius: 14px;
  margin: 10px 0 20px;
}

.article-share {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 44px;
  padding-top: 26px;
  border-top: 1px solid var(--border);
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--navy-800);
}

.article-share a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--light);
  color: var(--navy-800);
  border: 1px solid var(--border);
}

.article-share a:hover {
  background: var(--navy-900);
  color: #fff;
  border-color: var(--navy-900);
}

/* ---------- Sidebar artikel ---------- */
.article-side {
  display: flex;
  flex-direction: column;
  gap: 26px;
  align-self: start;
  position: sticky;
  top: 110px;
}

.article-cta {
  padding: 26px;
  border-radius: var(--radius);
  background: var(--grad-navy);
  color: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow-md);
}

.article-cta>i {
  font-size: 1.6rem;
  color: var(--cyan-400);
}

.article-cta h3 {
  color: #fff;
  font-size: 1.1rem;
  margin: 12px 0 8px;
}

.article-cta p {
  font-size: 0.88rem;
  margin-bottom: 18px;
}

.article-cta .btn-detail {
  background: #fff;
  color: var(--navy-900);
}

.article-cta .btn-detail:hover {
  background: var(--cyan-400);
  color: var(--navy-950);
}

.article-side-list {
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fff;
}

.article-side-list h4 {
  font-size: 0.95rem;
  margin: 0 0 16px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--navy-800);
}

.asl-item {
  display: flex;
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid var(--border);
}

.asl-item:first-of-type {
  border-top: 0;
  padding-top: 0;
}

.asl-item img {
  width: 64px;
  height: 64px;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
}

.asl-item span {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.asl-item strong {
  font-size: 0.85rem;
  line-height: 1.4;
  color: var(--heading);
  font-weight: 600;
}

.asl-item:hover strong {
  color: var(--blue-500);
}

.asl-item small {
  font-size: 0.74rem;
  color: #8a97ad;
}

/* ---------- Responsif ---------- */
@media (max-width: 991.98px) {
  .article-layout {
    grid-template-columns: 1fr;
    gap: 40px;
    padding-bottom: 70px;
  }

  .article-side {
    position: static;
  }

  .article-hero {
    padding: 150px 0 60px;
  }
}

@media (max-width: 575.98px) {
  .insight-toolbar {
    padding: 14px;
  }

  .insight-search {
    max-width: none;
    /* Tanpa ini, min-width:auto membuat form tidak bisa menyusut di bawah
       lebar bawaan input pencarian sehingga meluber di layar < 390px. */
    min-width: 0;
  }

  .insight-search button {
    padding: 8px 14px;
  }

  .article-cover {
    margin-top: -34px;
    border-radius: 14px;
  }

  .article-hero {
    padding: 140px 0 56px;
  }

  .article-title {
    font-size: 1.55rem;
  }
}