/* Nexus Documents (KB) — EmyUI-compatible */

.nav-scroller-subpages .nav-link[href*="knowledgebase"],
.full__width__secondarysidebar__menu .nav__items__wrapper.knowledgebase.categories {
  /* Keep secondary KB category panels quiet when Nexus sidebar is present */
}

.nexus-kb-hero {
  box-shadow: 0 0 1px rgb(0 0 0 / 10%), 0 2px 24px rgb(0 0 0 / 8%);
  border-radius: 12px;
  padding: 2.5rem 2rem;
  margin-bottom: 2rem;
  text-align: center;
  background: linear-gradient(135deg, #041528 0%, #0a2a4a 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #fff;
}

.nexus-kb-hero h1 {
  font-size: 1.75rem;
  font-weight: 700;
  margin: 0 0 0.5rem;
  color: #fff;
}

.nexus-kb-hero p {
  color: rgba(255, 255, 255, 0.78);
  margin: 0 0 1.25rem;
  font-size: 1rem;
}

.nexus-kb-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.nexus-kb-card {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1.25rem;
  text-decoration: none !important;
  color: #090e4e;
  background: #fff;
  border: 1px solid rgba(9, 14, 78, 0.08);
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(9, 14, 78, 0.06);
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
  height: 100%;
}

.nexus-kb-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 28px rgba(9, 14, 78, 0.1);
  color: #090e4e;
  border-color: rgba(9, 14, 78, 0.16);
}

.nexus-kb-card__icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: #f4f7fb;
  color: #336699;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.nexus-kb-card__title {
  font-weight: 600;
  font-size: 1rem;
  margin: 0;
  color: #090e4e;
}

.nexus-kb-card__desc {
  font-size: 0.875rem;
  color: rgba(9, 14, 78, 0.65);
  margin: 0;
  line-height: 1.45;
  flex: 1;
}

.nexus-kb-card__meta {
  font-size: 0.8rem;
  color: rgba(9, 14, 78, 0.45);
}

.nexus-kb-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 992px) {
  .nexus-kb-layout--with-sidebar {
    grid-template-columns: 260px 1fr;
    align-items: start;
  }
}

.nexus-kb-sidebar {
  position: sticky;
  top: 1rem;
}

.nexus-kb-sidebar .nexus-kb-panel {
  background: #fff;
  border-radius: 12px;
  border: 1px solid rgba(9, 14, 78, 0.08);
  box-shadow: 0 8px 24px rgba(9, 14, 78, 0.06);
  overflow: hidden;
}

.nexus-kb-sidebar__title {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: rgba(9, 14, 78, 0.45);
  padding: 0.75rem 1rem 0.25rem;
  margin: 0;
  font-weight: 600;
}

.nexus-kb-sidebar__list {
  list-style: none;
  margin: 0;
  padding: 0.25rem 0 0.75rem;
}

.nexus-kb-sidebar__list a {
  display: block;
  padding: 0.45rem 1rem;
  font-size: 0.9rem;
  color: #090e4e;
  text-decoration: none;
  border-left: 3px solid transparent;
}

.nexus-kb-sidebar__list a:hover {
  background: #f4f7fb;
}

.nexus-kb-sidebar__list a.active {
  border-left-color: #336699;
  background: #f4f7fb;
  font-weight: 600;
  color: #336699;
}

.nexus-kb-breadcrumb {
  font-size: 0.875rem;
  color: rgba(9, 14, 78, 0.65);
  margin-bottom: 1rem;
}

.nexus-kb-breadcrumb a {
  color: #336699;
  text-decoration: none;
}

.nexus-kb-breadcrumb a:hover {
  text-decoration: underline;
}

.nexus-kb-cat-intro p {
  color: rgba(9, 14, 78, 0.65);
  margin: 0.35rem 0 0;
}

.nexus-kb-panel {
  background: #fff;
  border-radius: 12px;
  border: 1px solid rgba(9, 14, 78, 0.08);
  box-shadow: 0 8px 24px rgba(9, 14, 78, 0.06);
  overflow: hidden;
}

.nexus-kb-panel__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid rgba(9, 14, 78, 0.08);
}

.nexus-kb-panel__body {
  padding: 1.25rem;
}

.nexus-kb-panel__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 1.25rem;
  border-top: 1px solid rgba(9, 14, 78, 0.08);
}

.nexus-kb-list-item {
  border-bottom: 1px solid rgba(9, 14, 78, 0.06);
}

.nexus-kb-list-item:last-child {
  border-bottom: 0;
}

.nexus-kb-list-item a {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.9rem 1.25rem;
  text-decoration: none;
  color: #090e4e;
}

.nexus-kb-list-item a:hover {
  background: #f4f7fb;
}

.nexus-kb-pager {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(9, 14, 78, 0.08);
}

.nexus-kb-pager a {
  font-size: 0.9rem;
  color: #336699;
  text-decoration: none;
  max-width: 45%;
}

.nexus-kb-pager a:hover {
  text-decoration: underline;
}

.nexus-kb-pager__label {
  display: block;
  font-size: 0.75rem;
  color: rgba(9, 14, 78, 0.45);
  margin-bottom: 0.15rem;
}

.knowledgebase__article__text pre {
  background: #0f172a;
  color: #e2e8f0;
  border-radius: 8px;
  padding: 1rem 1.25rem;
  overflow-x: auto;
  font-size: 0.875rem;
  line-height: 1.55;
  margin: 1rem 0;
}

.knowledgebase__article__text code {
  background: #f4f7fb;
  color: #090e4e;
  padding: 0.15em 0.4em;
  border-radius: 4px;
  font-size: 0.9em;
}

.knowledgebase__article__text pre code {
  background: transparent;
  color: inherit;
  padding: 0;
}

.knowledgebase__article__text table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
  font-size: 0.9rem;
}

.knowledgebase__article__text th,
.knowledgebase__article__text td {
  border: 1px solid rgba(9, 14, 78, 0.1);
  padding: 0.5rem 0.75rem;
  text-align: left;
}

.knowledgebase__article__text th {
  background: #f4f7fb;
  font-weight: 600;
  color: #090e4e;
}

.knowledgebase__article__text h2 {
  margin-top: 1.75rem;
  margin-bottom: 0.75rem;
  font-size: 1.25rem;
  color: #090e4e;
}

.knowledgebase__article__text h3 {
  margin-top: 1.25rem;
  margin-bottom: 0.5rem;
  font-size: 1.05rem;
  color: #090e4e;
}

.knowledgebase__article__text ul,
.knowledgebase__article__text ol {
  margin: 0.5rem 0 1rem;
  padding-left: 1.5rem;
}

.knowledgebase__article__text li {
  margin-bottom: 0.35rem;
  color: #090e4e;
}

.knowledgebase__article__text a {
  color: #336699;
}

.knowledgebase__article__text blockquote {
  border-left: 4px solid #336699;
  margin: 1rem 0;
  padding: 0.5rem 1rem;
  background: #f4f7fb;
  color: rgba(9, 14, 78, 0.65);
}
