/* NCERT Help — compact site-wide header (single row on desktop) */
.nh-site-header {
  --nh-ink: #0f172a;
  --nh-muted: #475569;
  --nh-blue: #2563eb;
  --nh-blue-dark: #1d4ed8;
  --nh-line: #e2e8f0;
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.97);
  backdrop-filter: saturate(1.2) blur(10px);
  border-bottom: 1px solid var(--nh-line);
  box-shadow: 0 2px 12px rgba(15, 23, 42, 0.05);
}
.nh-site-header-inner {
  max-width: 1320px;
  margin: 0 auto;
  padding: 6px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 52px;
}
.nh-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: var(--nh-ink);
  flex-shrink: 0;
  min-width: 0;
}
.nh-brand img {
  width: 38px;
  height: 38px;
  object-fit: contain;
  border-radius: 8px;
  flex-shrink: 0;
}
.nh-brand-text {
  font-size: 1.02rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #1d4ed8, #0ea5e9);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  white-space: nowrap;
}
.nh-primary-nav {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: flex-end;
  gap: 1px;
  flex: 1 1 auto;
  min-width: 0;
}
.nh-nav-link {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 5px 9px;
  border-radius: 999px;
  color: var(--nh-muted);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.78rem;
  line-height: 1.2;
  white-space: nowrap;
  transition: background .15s ease, color .15s ease, box-shadow .15s ease;
}
.nh-nav-link:hover,
.nh-nav-link:focus-visible {
  color: var(--nh-blue-dark);
  background: #eff6ff;
  outline: none;
}
.nh-nav-link.is-active {
  color: #fff;
  background: linear-gradient(135deg, var(--nh-blue), var(--nh-blue-dark));
  box-shadow: 0 2px 10px rgba(37, 99, 235, 0.22);
}
.nh-nav-link--muted:not(.is-active) {
  color: #64748b;
  font-weight: 500;
}
.nh-nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border: 1px solid var(--nh-line);
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  padding: 9px;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  flex-shrink: 0;
}
.nh-nav-toggle span {
  display: block;
  height: 2px;
  background: var(--nh-ink);
  border-radius: 2px;
}
@media (max-width: 1180px) {
  .nh-brand-text { display: none; }
  .nh-nav-link { padding: 5px 7px; font-size: 0.74rem; }
}
@media (max-width: 980px) {
  .nh-nav-toggle { display: inline-flex; }
  .nh-primary-nav {
    display: none;
    position: absolute;
    left: 10px;
    right: 10px;
    top: calc(100% + 4px);
    flex-direction: column;
    flex-wrap: wrap;
    align-items: stretch;
    padding: 8px;
    background: #fff;
    border: 1px solid var(--nh-line);
    border-radius: 12px;
    box-shadow: 0 16px 40px rgba(15, 23, 42, 0.12);
  }
  .nh-primary-nav.is-open { display: flex; }
  .nh-nav-link {
    width: 100%;
    justify-content: flex-start;
    border-radius: 8px;
    font-size: 0.88rem;
    padding: 10px 12px;
  }
  .nh-site-header-inner { position: relative; }
}
