*,
*::before,
*::after {
  box-sizing: border-box;
}

:root {
  /* texts */
  --text-primary: #0a005a;
  --text-muted: #727888;
  --text-gradient: linear-gradient(180deg, #ff00b8 0%, #1500c0 100%);

  /* buttons */
  --btn-primary: #ff00b8;
  --btn-secondary: #34a5fb;

  /* labels */
  --lbl-primary: #a3dfff;
}

/* ─── Shared Badge ───────────────────────────────────────────────── */
.ni-card__badge {
  display: inline-flex;
  align-items: center;
  height: 21.6px;
  padding: 0 8px;
  border-radius: 6px;
  border: 1px solid transparent;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif !important;
  font-weight: 600;
  font-size: 12px;
  line-height: 16px;
  color: #f8fafc;
  white-space: nowrap;
  text-transform: capitalize;
}

/* Badge colours — same for listing & detail */
.ni-card__badge--news {
  background: #0284c7;
  border-color: rgba(0, 0, 0, 0.08);
}
.ni-card__badge--blog {
  background: #ff8d28;
  border-color: rgba(0, 0, 0, 0.08);
}
.ni-card__badge--announcements {
  background: #ff2d55;
  border-color: rgba(0, 0, 0, 0.08);
}
.ni-card__badge--updates {
  background: #cb30e0;
  border-color: rgba(0, 0, 0, 0.08);
}

/* ══════════════════════════════════════════════════════════════════
   LISTING PAGE
   ══════════════════════════════════════════════════════════════════ */

.ihk-news-insight {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif !important;
  color: #0f172a;
  background: #f8fafc;
}

/* ─── Header / Hero Banner ───────────────────────────────────────── */
.ni-header {
  width: 100%;
  min-height: 212px;
  background: var(--text-primary);
  display: flex;
  align-items: center;
  padding: 64px 24px;
}

.ni-header__inner {
  max-width: 1184px;
  margin: 0 auto;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.ni-header__title {
  font-weight: 700;
  font-size: 36px;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif !important;
  line-height: 40px;
  color: #ffffff;
  margin: 0;
}

.ni-header__desc {
  font-weight: 400;
  font-size: 18px;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif !important;
  line-height: 28px;
  color: rgba(255, 255, 255, 0.8);
  margin: 0;
}

/* ─── Content Area ───────────────────────────────────────────────── */
.ni-content {
  max-width: 1184px;
  margin: 0 auto;
  padding: 24px 24px 48px;
}

/* ─── Tabs ───────────────────────────────────────────────────────── */
.ni-tabs {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  height: 36px;
  background: #f5f5f5;
  border-radius: 8px;
  padding: 4px;
  margin-bottom: 32px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  max-width: 100%;
}

.ni-tabs::-webkit-scrollbar {
  display: none;
}

.ni-tabs__btn {
  flex-shrink: 0;
  height: 28px;
  padding: 0 12px;
  border: none;
  border-radius: 6px;
  background: transparent;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif !important;
  font-size: 14px;
  line-height: 20px;
  font-weight: 600;
  color: #0a0a0a;
  cursor: pointer;
  white-space: nowrap;
  transition:
    background 0.15s,
    color 0.15s,
    box-shadow 0.15s;
}

.ni-tabs__btn:hover {
  background: rgba(255, 255, 255, 0.7);
  color: #0f172a;
}

.ni-tabs__btn:focus {
  background: rgba(255, 255, 255, 0.7);
  color: #0f172a;
  box-shadow:
    0 1px 3px rgba(0, 0, 0, 0.12),
    0 1px 2px rgba(0, 0, 0, 0.08);
}

.ni-tabs__btn--active {
  background: #ffffff;
  color: #0f172a;
  font-weight: 600;
  box-shadow:
    0 1px 3px rgba(0, 0, 0, 0.12),
    0 1px 2px rgba(0, 0, 0, 0.08);
}

/* ─── Grid ───────────────────────────────────────────────────────── */
.ni-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

@media (max-width: 1024px) {
  .ni-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .ni-grid {
    grid-template-columns: 1fr;
  }
}

/* ─── Card ───────────────────────────────────────────────────────── */
.ni-card {
  border-radius: 12px;
  border: 1px solid #e5e5e5;
  background: #ffffff;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.ni-card:hover .ni-card__title {
  background: var(--text-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: transparent;
}

.ni-card__link {
  text-decoration: none;
  display: flex;
  flex-direction: column;
  height: 100%;
  color: inherit;
}

/* Thumbnail */
.ni-card__thumb {
  position: relative;
  width: 100%;
  height: 224px;
  overflow: hidden;
  border-top-left-radius: 12px;
  border-top-right-radius: 12px;
  background: #e2e8f0;
}

.ni-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Badge on thumbnail */
.ni-card__thumb .ni-card__badge {
  position: absolute;
  top: 18.8px;
  left: 16px;
}

/* Card Body */
.ni-card__body {
  flex: 1;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16.8px;
}

.ni-card__content {
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}

.ni-card__title {
  font-weight: 700;
  font-size: 20px;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif !important;
  line-height: 28px;
  color: #0f172a;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.ni-card__desc {
  font-weight: 400;
  font-size: 16px;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif !important;
  line-height: 24px;
  color: var(--text-muted);
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Card Footer */
.ni-card__footer {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

.ni-card__foot-group {
  display: flex;
  align-items: center;
}

.ni-card__foot-item {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 14px;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif !important;
  line-height: 20px;
  font-weight: 400;
  color: #64748b;
  white-space: nowrap;
}

.ni-card__foot-item svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  color: #64748b;
}

/* ─── Empty State (inline / tab filter) ─────────────────────────── */
.ni-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 64px 24px;
  text-align: center;
  max-width: 360px;
}

.ni-empty--inline {
  max-width: 100%;
  width: 100%;
}

.ni-empty__icon {
  width: 64px;
  height: 64px;
  margin-bottom: 16px;
}

.ni-empty__icon svg {
  width: 100%;
  height: 100%;
}

.ni-empty__title {
  font-size: 16px;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif !important;
  font-weight: 600;
  color: #0f172a;
  margin: 0 0 6px;
}

.ni-empty__desc {
  font-size: 14px;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif !important;
  color: #94a3b8;
  line-height: 1.6;
  margin: 0;
}

/* ─── Responsive Header ──────────────────────────────────────────── */
@media (max-width: 640px) {
  .ni-header {
    min-height: 160px;
    padding: 32px 16px;
  }
  .ni-header__title {
    font-size: 28px;
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif !important;
  }
  .ni-header__desc {
    font-size: 16px;
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif !important;
  }
  .ni-content {
    padding: 20px 16px 40px;
  }
}
