/* 默认主题页面级样式（组件库之外的部分） */

.nx-hero {
  background:
    radial-gradient(1000px 400px at 50% -80px, var(--nx-primary-softer), transparent),
    var(--nx-bg);
  border-bottom: 1px solid var(--nx-border);
}

.nx-footer {
  border-top: 1px solid var(--nx-border);
  padding: 22px 0;
  font-size: 13.5px;
  color: var(--nx-text-2);
  background: var(--nx-card);
}

/* 文章正文排版（CMS 模块复用） */
.nx-prose { font-size: 16px; line-height: 1.85; }
.nx-prose h1, .nx-prose h2, .nx-prose h3 { line-height: 1.4; margin: 1.6em 0 .7em; }
.nx-prose h2 { font-size: 1.45em; padding-bottom: .3em; border-bottom: 1px solid var(--nx-border); }
.nx-prose h3 { font-size: 1.2em; }
.nx-prose p { margin: .9em 0; }
.nx-prose blockquote {
  margin: 1.2em 0; padding: 10px 18px;
  border-left: 3px solid var(--nx-primary);
  background: var(--nx-primary-softer);
  border-radius: 0 var(--nx-radius-sm) var(--nx-radius-sm) 0;
  color: var(--nx-text-2);
}
.nx-prose code {
  font-family: var(--nx-font-mono); font-size: .88em;
  background: var(--nx-muted); padding: 2px 6px; border-radius: 5px;
}
.nx-prose pre {
  background: var(--nx-muted); border: 1px solid var(--nx-border);
  border-radius: var(--nx-radius-sm); padding: 14px 16px; overflow-x: auto;
}
.nx-prose pre code { background: none; padding: 0; }
.nx-prose table {
  width: 100%; border-collapse: collapse; margin: 1.2em 0; font-size: .94em;
}
.nx-prose th, .nx-prose td { border: 1px solid var(--nx-border); padding: 8px 12px; }
.nx-prose th { background: var(--nx-muted); }
.nx-prose img { border-radius: var(--nx-radius-sm); }

/* CMS：文章卡片 */
.nx-post-card { display: flex; flex-direction: column; overflow: hidden; padding: 0; text-decoration: none; color: inherit; }
.nx-post-card__cover { aspect-ratio: 16 / 9; background-size: cover; background-position: center; background-color: var(--nx-muted); }
.nx-post-card__body { padding: 16px 18px 18px; display: flex; flex-direction: column; flex: 1; }
.nx-post-card__body .nx-card__title { line-height: 1.4; }

/* CMS：正文增强 */
.nx-prose .nx-code { background: var(--nx-muted); border: 1px solid var(--nx-border); border-radius: var(--nx-radius-sm); padding: 14px 16px; overflow-x: auto; }
.nx-prose .nx-code code { background: none; padding: 0; font-size: 13.5px; }
.nx-prose .nx-table-wrap { overflow-x: auto; margin: 1.2em 0; }
.nx-prose .nx-alert { margin: 1.1em 0; }
.nx-prose hr { border: 0; border-top: 1px solid var(--nx-border); margin: 2em 0; }

/* CMS：文章目录 */
.nx-toc {
  margin: 1.4em 0; padding: 14px 18px;
  background: var(--nx-primary-softer);
  border: 1px solid var(--nx-border);
  border-radius: var(--nx-radius-sm);
}
.nx-toc__title { font-weight: 600; margin-bottom: 8px; font-size: 14px; }
.nx-toc ul { list-style: none; margin: 0; padding: 0; }
.nx-toc__l3 { padding-left: 14px; }
.nx-toc__l4, .nx-toc__l5, .nx-toc__l6 { padding-left: 28px; }
.nx-toc a { display: block; padding: 3px 0; color: var(--nx-text-2); font-size: 14px; text-decoration: none; }
.nx-toc a:hover { color: var(--nx-primary); }

/* 广告：前台素材渲染 */
.nx-ad { display: inline-block; text-decoration: none; color: inherit; }
.nx-ad--image img { max-width: 100%; height: auto; display: block; border-radius: var(--nx-radius-sm); }
.nx-ad--text {
  padding: 10px 16px; border-radius: var(--nx-radius-sm);
  background: var(--nx-primary-softer); color: var(--nx-primary); font-weight: 600;
}

/* 小说：列表卡片 */
.nx-novel-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: 16px; }
.nx-novel-card {
  display: flex; flex-direction: column; overflow: hidden;
  border: 1px solid var(--nx-border); border-radius: var(--nx-radius);
  background: var(--nx-card); text-decoration: none; color: inherit;
  transition: transform .15s ease, box-shadow .15s ease;
}
.nx-novel-card:hover { transform: translateY(-2px); box-shadow: var(--nx-shadow, 0 6px 20px rgba(0, 0, 0, .08)); }
.nx-novel-card__cover {
  aspect-ratio: 3 / 4; display: grid; place-items: center; overflow: hidden;
  background: var(--nx-muted); font-size: 34px; text-decoration: none; color: inherit;
}
.nx-novel-card__cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nx-novel-card__body { padding: 10px 12px 12px; display: flex; flex-direction: column; flex: 1; gap: 2px; }
.nx-novel-card__title {
  font-weight: 600; font-size: 15px; line-height: 1.4;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

/* 小说：详情 */
.nx-novel-detail { display: flex; gap: 22px; align-items: flex-start; flex-wrap: wrap; }
.nx-novel-detail__cover {
  flex: 0 0 180px; width: 180px; aspect-ratio: 3 / 4; overflow: hidden;
  border-radius: var(--nx-radius); background: var(--nx-muted);
  border: 1px solid var(--nx-border); display: grid; place-items: center; font-size: 44px;
}
.nx-novel-detail__cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nx-novel-detail__cover--empty { width: 100%; height: 100%; display: grid; place-items: center; }
.nx-novel-detail__main { flex: 1 1 320px; min-width: 0; }
.nx-novel-detail__desc {
  font-size: 14.5px; line-height: 1.8; color: var(--nx-text-2);
  background: var(--nx-muted); border-radius: var(--nx-radius-sm); padding: 12px 14px;
}

/* 小说：目录 */
.nx-novel-toc { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 6px; }
.nx-novel-toc__item {
  display: flex; justify-content: space-between; gap: 10px; align-items: center;
  padding: 9px 12px; border: 1px solid var(--nx-border); border-radius: var(--nx-radius-sm);
  text-decoration: none; color: var(--nx-text); font-size: 14px;
}
.nx-novel-toc__item:hover { border-color: var(--nx-primary); color: var(--nx-primary); }
.nx-novel-toc__item.is-current { border-color: var(--nx-primary); background: var(--nx-primary-softer); }

/* 小说：阅读页 */
.nx-reader-toolbar {
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  flex-wrap: wrap; padding: 10px 12px; margin-bottom: 14px;
  border: 1px solid var(--nx-border); border-radius: var(--nx-radius-sm);
  background: var(--nx-card); position: sticky; top: 8px; z-index: 5;
}
.nx-reader { border-radius: var(--nx-radius); padding: 30px clamp(16px, 4vw, 44px); border: 1px solid var(--nx-border); }
.nx-reader--white { background: #fff; color: #1f2937; }
.nx-reader--sepia { background: #f6ecd9; color: #4a3f2f; border-color: #e4d7bd; }
.nx-reader--dark { background: #15181c; color: #d5dbe2; border-color: #2a3038; }
.nx-reader--dark .nx-muted,
.nx-reader--dark .nx-small.nx-muted { color: #9aa4af; }
.nx-reader__head { border-bottom: 1px dashed currentColor; padding-bottom: 14px; margin-bottom: 20px; opacity: .95; }
.nx-reader__title { font-size: 1.5em; line-height: 1.35; margin: 0; }
.nx-reader__content { white-space: normal; word-break: break-word; }
.nx-reader--dark .nx-reader__content a { color: #7dd3fc; }
.nx-reader__foot { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 30px; padding-top: 18px; border-top: 1px dashed currentColor; }
.is-disabled { opacity: .55; pointer-events: none; }

/* 小说：阅读历史 */
.nx-history-list { list-style: none; margin: 0; padding: 0; }
.nx-history-item {
  display: flex; gap: 12px; align-items: center; padding: 10px;
  border-bottom: 1px solid var(--nx-border);
}
.nx-history-item__cover {
  flex: 0 0 44px; width: 44px; height: 58px; overflow: hidden; border-radius: 4px;
  background: var(--nx-muted); display: grid; place-items: center; font-size: 20px;
}
.nx-history-item__cover img { width: 100%; height: 100%; object-fit: cover; display: block; }

@media (max-width: 640px) {
  .nx-novel-detail__cover { flex-basis: 120px; width: 120px; }
  .nx-novel-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; }
  .nx-reader-toolbar { position: static; }
}

/* 中医：首页 */
.nx-tcm-hero {
  display: flex; gap: 22px; align-items: flex-end; justify-content: space-between; flex-wrap: wrap;
  padding: 26px clamp(18px, 4vw, 34px);
  border: 1px solid var(--nx-border); border-radius: var(--nx-radius);
  background:
    radial-gradient(700px 260px at 100% 0, var(--nx-primary-softer), transparent),
    var(--nx-card);
}
.nx-tcm-search { display: flex; gap: 8px; flex-wrap: wrap; }
.nx-tcm-search input { min-width: 240px; }
.nx-tcm-counts {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px; margin-top: 18px;
}
.nx-tcm-count {
  display: flex; flex-direction: column; gap: 2px; padding: 14px 16px;
  border: 1px solid var(--nx-border); border-radius: var(--nx-radius-sm);
  background: var(--nx-card); text-decoration: none; color: inherit;
}
.nx-tcm-count:hover { border-color: var(--nx-primary); }
.nx-tcm-count strong { font-size: 24px; line-height: 1.1; color: var(--nx-primary); }
.nx-tcm-count span { font-size: 13px; color: var(--nx-text-2); }

/* 中医：文章卡片 */
.nx-tcm-article-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.nx-tcm-article-card {
  display: flex; flex-direction: column; overflow: hidden;
  border: 1px solid var(--nx-border); border-radius: var(--nx-radius);
  background: var(--nx-card); text-decoration: none; color: inherit;
  transition: transform .15s ease, box-shadow .15s ease;
}
.nx-tcm-article-card:hover { transform: translateY(-2px); box-shadow: var(--nx-shadow, 0 6px 20px rgba(0, 0, 0, .08)); }
.nx-tcm-article-card__cover { aspect-ratio: 16 / 9; overflow: hidden; background: var(--nx-muted); }
.nx-tcm-article-card__cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nx-tcm-article-card__body { padding: 14px 16px 16px; display: flex; flex-direction: column; flex: 1; gap: 7px; }
.nx-tcm-article-card__title {
  font-weight: 600; font-size: 16px; line-height: 1.45;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

/* 中医：医书 */
.nx-tcm-book-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.nx-tcm-book-card {
  display: flex; flex-direction: column; gap: 6px; padding: 16px 18px;
  border: 1px solid var(--nx-border); border-radius: var(--nx-radius);
  background: var(--nx-card); text-decoration: none; color: inherit;
}
.nx-tcm-book-card:hover { border-color: var(--nx-primary); }
.nx-tcm-book-card__cover {
  width: 100%; aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--nx-radius-sm);
  background: var(--nx-muted); margin-bottom: 4px;
}
.nx-tcm-book-card__cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nx-tcm-book-card__title { font-weight: 600; font-size: 17px; line-height: 1.4; }
.nx-tcm-book-detail { display: flex; gap: 22px; align-items: flex-start; flex-wrap: wrap; }
.nx-tcm-book-detail__cover {
  flex: 0 0 160px; width: 160px; aspect-ratio: 3 / 4; overflow: hidden;
  border-radius: var(--nx-radius); background: var(--nx-muted);
  border: 1px solid var(--nx-border); display: grid; place-items: center; font-size: 44px;
}
.nx-tcm-book-detail__cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nx-tcm-desc {
  font-size: 14.5px; line-height: 1.8; color: var(--nx-text-2);
  background: var(--nx-muted); border-radius: var(--nx-radius-sm); padding: 12px 14px; margin: 0;
}
.nx-tcm-chapter-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 6px; }
.nx-tcm-chapter-item {
  display: flex; align-items: center; gap: 10px; padding: 9px 12px;
  border: 1px solid var(--nx-border); border-radius: var(--nx-radius-sm);
  text-decoration: none; color: inherit; font-size: 14px;
}
.nx-tcm-chapter-item:hover { border-color: var(--nx-primary); color: var(--nx-primary); }
.nx-tcm-chapter-item.is-current { border-color: var(--nx-primary); background: var(--nx-primary-softer); }
.nx-tcm-chapter-item__sort {
  flex: 0 0 26px; height: 26px; display: grid; place-items: center;
  border-radius: 50%; background: var(--nx-muted); font-size: 12px; color: var(--nx-text-2);
}
.nx-tcm-chapter-item > span:nth-child(2) { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* 中医：医书阅读 */
.nx-tcm-reader { border: 1px solid var(--nx-border); border-radius: var(--nx-radius); background: var(--nx-card); padding: 28px clamp(16px, 4vw, 42px); }
.nx-tcm-reader__head { border-bottom: 1px dashed var(--nx-border); padding-bottom: 14px; margin-bottom: 20px; }
.nx-tcm-reader__title { font-size: 1.5em; line-height: 1.35; margin: 6px 0 0; }
.nx-tcm-reader__content { font-size: 16px; line-height: 1.9; word-break: break-word; }
.nx-tcm-reader__nav { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 28px; padding-top: 18px; border-top: 1px dashed var(--nx-border); }

/* 中医：方剂 / 药材 */
.nx-tcm-formula-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.nx-tcm-formula-card {
  display: flex; flex-direction: column; gap: 5px; padding: 16px 18px;
  border: 1px solid var(--nx-border); border-radius: var(--nx-radius);
  background: var(--nx-card); text-decoration: none; color: inherit;
}
.nx-tcm-formula-card:hover { border-color: var(--nx-primary); }
.nx-tcm-formula-card__name { font-weight: 600; font-size: 18px; }
.nx-tcm-herb-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.nx-tcm-herb-card {
  display: flex; gap: 12px; align-items: flex-start; padding: 12px;
  border: 1px solid var(--nx-border); border-radius: var(--nx-radius);
  background: var(--nx-card); text-decoration: none; color: inherit;
}
.nx-tcm-herb-card:hover { border-color: var(--nx-primary); }
.nx-tcm-herb-card__thumb {
  flex: 0 0 68px; width: 68px; height: 68px; overflow: hidden; border-radius: var(--nx-radius-sm);
  background: var(--nx-muted); display: grid; place-items: center; font-size: 26px;
}
.nx-tcm-herb-card__thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nx-tcm-herb-card__body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.nx-tcm-herb-card__name { font-weight: 600; font-size: 16px; }
.nx-tcm-formula-detail { display: flex; flex-direction: column; gap: 14px; }
.nx-tcm-field { border: 1px solid var(--nx-border); border-radius: var(--nx-radius-sm); overflow: hidden; background: var(--nx-card); }
.nx-tcm-field__label {
  margin: 0; padding: 9px 14px; font-size: 14px; font-weight: 600;
  background: var(--nx-muted); color: var(--nx-text-2);
}
.nx-tcm-field__body { padding: 13px 14px; font-size: 15px; line-height: 1.85; }
.nx-tcm-herb-detail { display: flex; gap: 22px; align-items: flex-start; flex-wrap: wrap; }
.nx-tcm-herb-detail__img {
  flex: 0 0 220px; width: 220px; aspect-ratio: 1 / 1; overflow: hidden;
  border-radius: var(--nx-radius); border: 1px solid var(--nx-border);
  background: var(--nx-muted); display: grid; place-items: center; font-size: 56px;
}
.nx-tcm-herb-detail__img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nx-tcm-attrs { width: 100%; border-collapse: collapse; font-size: 14px; }
.nx-tcm-attrs th, .nx-tcm-attrs td { border: 1px solid var(--nx-border); padding: 8px 12px; text-align: left; }
.nx-tcm-attrs th { width: 110px; background: var(--nx-muted); color: var(--nx-text-2); font-weight: 500; }

/* 中医：列表行 / 搜索 */
.nx-tcm-list-row {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  padding: 11px 15px; border-bottom: 1px solid var(--nx-border);
  text-decoration: none; color: inherit;
}
.nx-tcm-list-row:last-child { border-bottom: 0; }
.nx-tcm-list-row:hover { background: var(--nx-primary-softer); }
.nx-tcm-search-row {
  display: flex; flex-direction: column; gap: 3px; padding: 12px 16px;
  border-bottom: 1px solid var(--nx-border); text-decoration: none; color: inherit;
}
.nx-tcm-search-row:last-child { border-bottom: 0; }
.nx-tcm-search-row:hover { background: var(--nx-primary-softer); }

@media (max-width: 640px) {
  .nx-tcm-book-detail__cover { flex-basis: 110px; width: 110px; }
  .nx-tcm-herb-detail__img { flex-basis: 120px; width: 120px; font-size: 40px; }
  .nx-tcm-article-grid, .nx-tcm-formula-grid { grid-template-columns: 1fr; }
  .nx-tcm-book-grid, .nx-tcm-herb-grid { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
  .nx-tcm-search input { min-width: 0; flex: 1; }
}

/* ============ 学习系统 ============ */
.nx-learn-hero { display: flex; gap: 24px; align-items: center; justify-content: space-between; flex-wrap: wrap; background: linear-gradient(135deg,#eef7f1,#f7fbf8); border-radius: 16px; padding: 26px; margin-bottom: 18px; }
.nx-learn-stats { display: grid; grid-template-columns: repeat(2, minmax(96px,1fr)); gap: 10px; }
.nx-learn-stat { background: #fff; border-radius: 12px; padding: 12px 16px; text-align: center; box-shadow: 0 1px 3px rgba(16,24,16,.06); }
.nx-learn-stat strong { display: block; font-size: 22px; color: #10b981; }
.nx-learn-stat span { font-size: 12px; color: #6b7a6b; }
.nx-learn-checkin { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; background: #fff; border: 1px solid #e6efe8; border-radius: 12px; padding: 14px 18px; margin-bottom: 8px; }
.nx-learn-section-title { font-size: 19px; margin: 26px 0 14px; }
.nx-learn-course-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px,1fr)); gap: 14px; }
.nx-learn-course-card { display: flex; flex-direction: column; background: #fff; border: 1px solid #e6efe8; border-radius: 12px; overflow: hidden; color: inherit; text-decoration: none; transition: box-shadow .2s, transform .2s; }
.nx-learn-course-card:hover { box-shadow: 0 6px 18px rgba(16,24,16,.1); transform: translateY(-2px); }
.nx-learn-course-card__cover { height: 130px; background: #eef7f1; }
.nx-learn-course-card__cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nx-learn-course-card__body { display: flex; flex-direction: column; gap: 8px; padding: 14px 16px 16px; flex: 1; }
.nx-learn-course-card__title { font-weight: 700; font-size: 16px; line-height: 1.4; }
.nx-learn-course-detail { display: flex; gap: 20px; flex-wrap: wrap; background: #fff; border: 1px solid #e6efe8; border-radius: 14px; padding: 20px; margin-bottom: 8px; }
.nx-learn-course-detail__cover { flex: 0 0 200px; width: 200px; height: 150px; border-radius: 10px; overflow: hidden; background: #eef7f1; }
.nx-learn-course-detail__cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nx-learn-course-detail__placeholder { display: grid; place-items: center; height: 100%; font-size: 48px; }
.nx-learn-progress__bar { height: 8px; border-radius: 999px; background: #e6efe8; overflow: hidden; }
.nx-learn-progress__bar span { display: block; height: 100%; background: linear-gradient(90deg,#34d399,#10b981); border-radius: 999px; }
.nx-learn-lesson-list { display: flex; flex-direction: column; gap: 8px; }
.nx-learn-lesson-item { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; background: #fff; border: 1px solid #e6efe8; border-radius: 10px; padding: 12px 16px; color: inherit; text-decoration: none; }
.nx-learn-lesson-item:hover { border-color: #10b981; }
.nx-learn-lesson-item.is-done { background: #f6fcf8; }
.nx-learn-lesson-item__sort { width: 26px; height: 26px; display: grid; place-items: center; border-radius: 50%; background: #eef7f1; font-size: 12px; color: #10b981; flex: none; }
.nx-learn-lesson-item__title { font-weight: 600; }
.nx-learn-reader { background: #fff; border: 1px solid #e6efe8; border-radius: 14px; padding: 20px 22px; }
.nx-learn-reader__content { line-height: 1.9; }
.nx-learn-reader__content img { max-width: 100%; height: auto; border-radius: 8px; }
.nx-learn-exam-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px,1fr)); gap: 14px; }
.nx-learn-user-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px,1fr)); gap: 14px; }

/* ===== 资源下载 ===== */
.nx-resource-hero { display: flex; gap: 24px; align-items: center; justify-content: space-between; flex-wrap: wrap; background: linear-gradient(135deg,#eef2fb,#f8fafd); border-radius: 16px; padding: 26px; margin-bottom: 18px; }
.nx-resource-stats { display: grid; grid-template-columns: repeat(3, minmax(84px,1fr)); gap: 10px; }
.nx-resource-stat { background: #fff; border-radius: 12px; padding: 12px 16px; text-align: center; box-shadow: 0 1px 3px rgba(16,24,16,.06); }
.nx-resource-stat strong { display: block; font-size: 22px; color: #4f6bed; }
.nx-resource-stat span { font-size: 12px; color: #6b7a6b; }
.nx-resource-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px,1fr)); gap: 14px; }
.nx-resource-card { display: flex; gap: 12px; background: #fff; border: 1px solid #e8eaef; border-radius: 12px; padding: 14px 16px; color: inherit; text-decoration: none; transition: box-shadow .2s, transform .2s; }
.nx-resource-card:hover { box-shadow: 0 6px 18px rgba(16,24,16,.1); transform: translateY(-2px); }
.nx-resource-card__icon { flex: 0 0 52px; width: 52px; height: 52px; display: grid; place-items: center; background: #eef2fb; border-radius: 10px; overflow: hidden; font-size: 24px; }
.nx-resource-card__icon img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nx-resource-card__body { display: flex; flex-direction: column; gap: 6px; min-width: 0; flex: 1; }
.nx-resource-card__title { font-weight: 700; font-size: 15px; line-height: 1.4; }
.nx-resource-detail { display: flex; gap: 20px; flex-wrap: wrap; background: #fff; border: 1px solid #e8eaef; border-radius: 14px; padding: 20px; margin-bottom: 8px; }
.nx-resource-detail__icon { flex: 0 0 120px; width: 120px; height: 120px; display: grid; place-items: center; background: #eef2fb; border-radius: 14px; overflow: hidden; font-size: 52px; }
.nx-resource-detail__icon img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nx-resource-meta { display: flex; gap: 22px; flex-wrap: wrap; margin-top: 14px; }
.nx-resource-meta div { display: flex; flex-direction: column; gap: 2px; }
.nx-resource-meta strong { font-weight: 600; font-size: 14px; }
.nx-resource-section-title { font-size: 19px; margin: 26px 0 14px; }
.nx-resource-desc { line-height: 1.9; }
.nx-resource-shots { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px,1fr)); gap: 12px; }
.nx-resource-shots a { display: block; border-radius: 10px; overflow: hidden; background: #eef2fb; }
.nx-resource-shots img { width: 100%; height: 140px; object-fit: cover; display: block; }
.nx-resource-download { max-width: 560px; margin: 0 auto; text-align: center; padding: 32px 24px; }
.nx-resource-download__btn:disabled { opacity: .55; cursor: not-allowed; }
@media (max-width: 640px) {
  .nx-resource-hero { padding: 18px; }
  .nx-resource-stats { width: 100%; }
  .nx-resource-detail__icon { flex-basis: 76px; width: 76px; height: 76px; font-size: 34px; }
  .nx-resource-shots img { height: 110px; }
}

@media (max-width: 640px) {
  .nx-learn-hero { padding: 18px; }
  .nx-learn-stats { grid-template-columns: repeat(4, minmax(64px,1fr)); gap: 6px; width: 100%; }
  .nx-learn-stat { padding: 8px 6px; }
  .nx-learn-course-detail__cover { flex-basis: 120px; width: 120px; height: 100px; }
  .nx-learn-section-title { font-size: 17px; }
}

/* ===== 产品文档 ===== */
.nx-docs-hero { display: flex; gap: 24px; align-items: center; justify-content: space-between; flex-wrap: wrap; background: linear-gradient(135deg,#eef2fb,#f8fafd); border-radius: 16px; padding: 26px; }
.nx-docs-stats { display: grid; grid-template-columns: repeat(3, minmax(84px,1fr)); gap: 10px; }
.nx-docs-stat { background: #fff; border-radius: 12px; padding: 12px 16px; text-align: center; box-shadow: 0 1px 3px rgba(16,24,16,.06); }
.nx-docs-stat strong { display: block; font-size: 22px; color: #4f6bed; }
.nx-docs-stat span { font-size: 12px; color: #6b7a6b; }
.nx-docs-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px,1fr)); gap: 14px; }
.nx-docs-card { display: flex; flex-direction: column; color: inherit; text-decoration: none; }
.nx-docs-card:hover { box-shadow: 0 6px 18px rgba(16,24,16,.1); }
.nx-docs-card__head { display: flex; gap: 12px; align-items: center; }
.nx-docs-card__icon { flex: 0 0 44px; width: 44px; height: 44px; display: grid; place-items: center; background: #eef2fb; border-radius: 10px; font-size: 22px; }
.nx-docs-card__title { font-weight: 700; font-size: 15px; line-height: 1.4; }
.nx-docs-layout { display: grid; grid-template-columns: 260px minmax(0,1fr); gap: 22px; align-items: start; }
.nx-docs-sidebar { position: sticky; top: 16px; background: #fff; border: 1px solid #e8eaef; border-radius: 12px; padding: 16px; max-height: calc(100vh - 40px); overflow: auto; }
.nx-docs-sidebar__title { font-weight: 700; font-size: 14px; padding-bottom: 10px; margin-bottom: 6px; border-bottom: 1px solid #e8eaef; }
.nx-docs-tree { list-style: none; margin: 0; padding: 0; }
.nx-docs-tree .nx-docs-tree { padding-left: 14px; margin-top: 2px; }
.nx-docs-tree__link { display: block; padding: 6px 8px; border-radius: 6px; color: #45544b; text-decoration: none; font-size: 13.5px; line-height: 1.5; }
.nx-docs-tree__link:hover { background: #eef2fb; color: #2f55d4; }
.nx-docs-tree__link.is-active { background: #eef2fb; color: #2f55d4; font-weight: 600; }
.nx-docs-main { min-width: 0; }
.nx-docs-head { background: #fff; border: 1px solid #e8eaef; border-radius: 12px; padding: 20px 22px; margin-bottom: 16px; }
.nx-docs-content { background: #fff; border: 1px solid #e8eaef; border-radius: 12px; padding: 22px 24px; }
.nx-docs-section-title { font-size: 19px; margin: 0 0 14px; }
.nx-docs-crumb { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-size: 13px; color: #6b7a6b; margin-bottom: 14px; }
.nx-docs-crumb a { color: #2f55d4; text-decoration: none; }
@media (max-width: 860px) {
  .nx-docs-layout { grid-template-columns: 1fr; }
  .nx-docs-sidebar { position: static; max-height: none; }
  .nx-docs-hero { padding: 18px; }
  .nx-docs-stats { width: 100%; }
  .nx-docs-content { padding: 16px; }
}
